Expose instance feed config option in the API and show it on About page

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel
2021-04-19 12:40:51 +02:00
parent cd874e1bfc
commit bcf52ccdf7
8 changed files with 62 additions and 3 deletions

View File

@@ -42,9 +42,13 @@
<table class="table is-fullwidth">
<tr>
<td>{{ $t("Instance languages") }}</td>
<td :title="this.config ? this.config.languages.join(', ') : ''">
<td
v-if="config.languages.length > 0"
:title="this.config ? this.config.languages.join(', ') : ''"
>
{{ formattedLanguageList }}
</td>
<td v-else>{{ $t("No information") }}</td>
</tr>
<tr>
<td>{{ $t("Mobilizon version") }}</td>
@@ -72,6 +76,29 @@
</td>
<td v-else>{{ $t("Disabled") }}</td>
</tr>
<tr class="instance-feeds">
<td>{{ $t("Instance feeds") }}</td>
<td v-if="config.instanceFeeds.enabled" class="buttons">
<b-button
tag="a"
size="is-small"
icon-left="rss"
href="/feed/instance/atom"
target="_blank"
>{{ $t("RSS/Atom Feed") }}</b-button
>
<b-button
tag="a"
size="is-small"
icon-left="calendar-sync"
href="/feed/instance/ics"
target="_blank"
>{{ $t("ICS/WebCal Feed") }}</b-button
>
</td>
<td v-else>{{ $t("Disabled") }}</td>
</tr>
</table>
</section>
</div>
@@ -177,5 +204,14 @@ section {
}
}
}
tr.instance-feeds {
height: 3rem;
td:first-child {
vertical-align: middle;
}
td:last-child {
height: 3rem;
}
}
}
</style>