Merge pull request #59491 from nextcloud/backport/59423/stable33

[stable33] fix(settings): hide list of webauthn devices if empty
This commit is contained in:
Andy Scherzinger 2026-04-20 17:55:39 +02:00 committed by GitHub
commit 6aaad2bd7d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 16 additions and 14 deletions

View file

@ -9,20 +9,22 @@
<p class="settings-hint hidden-when-empty">
{{ t('settings', 'Set up your account for passwordless authentication following the FIDO2 standard.') }}
</p>
<NcNoteCard v-if="devices.length === 0" type="info">
{{ t('settings', 'No devices configured.') }}
</NcNoteCard>
<h3 v-else id="security-webauthn__active-devices">
{{ t('settings', 'The following devices are configured for your account:') }}
</h3>
<ul aria-labelledby="security-webauthn__active-devices" class="security-webauthn__device-list">
<WebAuthnDevice
v-for="device in sortedDevices"
:key="device.id"
:name="device.name"
@delete="deleteDevice(device.id)" />
</ul>
<template v-else>
<h3 id="security-webauthn__active-devices">
{{ t('settings', 'The following devices are configured for your account:') }}
</h3>
<ul aria-labelledby="security-webauthn__active-devices" class="security-webauthn__device-list">
<WebAuthnDevice
v-for="device in sortedDevices"
:key="device.id"
:name="device.name"
@delete="deleteDevice(device.id)" />
</ul>
</template>
<NcNoteCard v-if="!supportsWebauthn" type="warning">
{{ t('settings', 'Your browser does not support WebAuthn.') }}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long