aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGrigorii K. Shartsev <me@shgk.me>2024-09-06 16:48:05 +0200
committernfebe <fenn25.fn@gmail.com>2024-12-09 02:45:33 +0100
commitb96661bd585534126082c97a0d318a1f647abc74 (patch)
treed9d3fc3396688712c22ec89c4aca7578f0eaa7da
parent301a7dacf19d9888dbce3495fd80b755732f40ee (diff)
downloadnextcloud-server-b96661bd585534126082c97a0d318a1f647abc74.tar.gz
nextcloud-server-b96661bd585534126082c97a0d318a1f647abc74.zip
fix(files_sharing): add accessible labels in link share creation
Signed-off-by: Grigorii K. Shartsev <me@shgk.me>
-rw-r--r--apps/files_sharing/src/components/SharingEntryLink.vue27
1 files changed, 13 insertions, 14 deletions
diff --git a/apps/files_sharing/src/components/SharingEntryLink.vue b/apps/files_sharing/src/components/SharingEntryLink.vue
index f62a0358072..cda056a4dca 100644
--- a/apps/files_sharing/src/components/SharingEntryLink.vue
+++ b/apps/files_sharing/src/components/SharingEntryLink.vue
@@ -65,27 +65,26 @@
</NcActionText>
<!-- password -->
- <NcActionText v-if="pendingEnforcedPassword" icon="icon-password">
- {{ t('files_sharing', 'Password protection (enforced)') }}
- </NcActionText>
- <NcActionCheckbox v-else-if="pendingPassword"
+ <NcActionCheckbox v-if="pendingPassword"
:checked.sync="isPasswordProtected"
:disabled="config.enforcePasswordForPublicLink || saving"
class="share-link-password-checkbox"
@uncheck="onPasswordDisable">
- {{ t('files_sharing', 'Password protection') }}
+ {{ config.enforcePasswordForPublicLink ? t('files_sharing', 'Password protection (enforced)') : t('files_sharing', 'Password protection') }}
</NcActionCheckbox>
<NcActionInput v-if="pendingEnforcedPassword || share.password"
class="share-link-password"
+ :label="t('files_sharing', 'Enter a password')"
:value.sync="share.password"
:disabled="saving"
:required="config.enableLinkPasswordByDefault || config.enforcePasswordForPublicLink"
:minlength="isPasswordPolicyEnabled && config.passwordPolicy.minLength"
- icon=""
autocomplete="new-password"
@submit="onNewLinkShare">
- {{ t('files_sharing', 'Enter a password') }}
+ <template #icon>
+ <LockIcon :size="20" />
+ </template>
</NcActionInput>
<NcActionCheckbox v-if="hasDefaultExpirationDate"
@@ -97,11 +96,9 @@
</NcActionCheckbox>
<!-- expiration date -->
- <NcActionText v-if="pendingExpirationDate" icon="icon-calendar-dark">
- {{ t('files_sharing', 'Expiration date (enforced)') }}
- </NcActionText>
<NcActionInput v-if="pendingExpirationDate"
class="share-link-expire-date"
+ :label="t('files_sharing', 'Expiration date (enforced)')"
:disabled="saving"
:is-native-picker="true"
:hide-label="true"
@@ -109,10 +106,10 @@
type="date"
:min="dateTomorrow"
:max="maxExpirationDateEnforced"
- @input="onExpirationChange">
- <!-- let's not submit when picked, the user
- might want to still edit or copy the password -->
- {{ t('files_sharing', 'Enter a date') }}
+ @input="onExpirationChange /* let's not submit when picked, the user might want to still edit or copy the password */">
+ <template #icon>
+ <IconCalendarBlank :size="20" />
+ </template>
</NcActionInput>
<NcActionButton icon="icon-checkmark" @click.prevent.stop="onNewLinkShare">
@@ -207,6 +204,7 @@ import NcActions from '@nextcloud/vue/dist/Components/NcActions.js'
import NcAvatar from '@nextcloud/vue/dist/Components/NcAvatar.js'
import Tune from 'vue-material-design-icons/Tune.vue'
+import IconCalendarBlank from 'vue-material-design-icons/CalendarBlank.vue'
import SharingEntryQuickShareSelect from './SharingEntryQuickShareSelect.vue'
@@ -231,6 +229,7 @@ export default {
NcActionSeparator,
NcAvatar,
Tune,
+ IconCalendarBlank,
SharingEntryQuickShareSelect,
},