Skip to content

Commit

Permalink
fixup! feat(federation): provide UI toggles in Admin settings for fed…
Browse files Browse the repository at this point in the history
…eration options

Signed-off-by: Maksim Sukharev <antreesy.web@gmail.com>
  • Loading branch information
Antreesy committed Feb 19, 2024
1 parent 8b326e7 commit 1e21d26
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/components/AdminSettings/Federation.vue
Original file line number Diff line number Diff line change
Expand Up @@ -55,21 +55,25 @@
:disabled="loading"
type="switch"
@update:checked="saveFederationOnlyTrustedServersEnabled">
{{ t('spreed', 'Allow only federation with trusted servers') }}
{{ t('spreed', 'Only allow to federate with trusted servers') }}
</NcCheckboxRadioSwitch>
<!-- eslint-disable-next-line vue/no-v-html -->
<p class="settings-hint additional-top-margin" v-html="trustedServersLink" />

<h3>{{ t('spreed', 'Limit to groups') }}</h3>

<p class="settings-hint additional-top-margin">
{{ t('spreed', 'When at least one group is selected, only people of the listed groups can invite federated users to conversations.') }}
</p>

<div class="form">
<NcSelect v-model="allowedGroups"
input-id="allow_groups_invite_federated"
:input-label="t('spreed', 'Limit invite federated users')"
:input-label="t('spreed', 'Groups allowed to invite federated users')"
name="allow_groups_invite_federated"
class="form__select"
:options="groups"
:placeholder="t('spreed', 'Limit invite federated users')"
:placeholder="t('spreed', 'Select groups …')"
:disabled="loading"
multiple
searchable
Expand Down Expand Up @@ -136,7 +140,7 @@ export default {
computed: {
trustedServersLink() {
const href = generateUrl('/settings/admin/sharing#ocFederationSettings')
return t('spreed', 'Trusted servers could be configured at {linkstart}Sharing settings page{linkend}.')
return t('spreed', 'Trusted servers can be configured at {linkstart}Sharing settings page{linkend}.')
.replace('{linkstart}', `<a target="_blank" rel="noreferrer nofollow" class="external" href="${href}">`)
.replaceAll('{linkend}', ' ↗</a>')
},
Expand Down

0 comments on commit 1e21d26

Please sign in to comment.