Skip to content

Commit 72959f6

Browse files
authored
Merge pull request #59490 from nextcloud/backport/59423/stable32
[stable32] fix(settings): hide list of webauthn devices if empty
2 parents 302505d + d95ebff commit 72959f6

3 files changed

Lines changed: 15 additions & 12 deletions

File tree

apps/settings/src/components/WebAuthn/Section.vue

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,19 +9,22 @@
99
<p class="settings-hint hidden-when-empty">
1010
{{ t('settings', 'Set up your account for passwordless authentication following the FIDO2 standard.') }}
1111
</p>
12+
1213
<NcNoteCard v-if="devices.length === 0" type="info">
1314
{{ t('settings', 'No devices configured.') }}
1415
</NcNoteCard>
1516

16-
<h3 v-else id="security-webauthn__active-devices">
17-
{{ t('settings', 'The following devices are configured for your account:') }}
18-
</h3>
19-
<ul aria-labelledby="security-webauthn__active-devices" class="security-webauthn__device-list">
20-
<Device v-for="device in sortedDevices"
21-
:key="device.id"
22-
:name="device.name"
23-
@delete="deleteDevice(device.id)" />
24-
</ul>
17+
<template v-else>
18+
<h3 id="security-webauthn__active-devices">
19+
{{ t('settings', 'The following devices are configured for your account:') }}
20+
</h3>
21+
<ul aria-labelledby="security-webauthn__active-devices" class="security-webauthn__device-list">
22+
<Device v-for="device in sortedDevices"
23+
:key="device.id"
24+
:name="device.name"
25+
@delete="deleteDevice(device.id)" />
26+
</ul>
27+
</template>
2528

2629
<NcNoteCard v-if="!supportsWebauthn" type="warning">
2730
{{ t('settings', 'Your browser does not support WebAuthn.') }}

dist/settings-vue-settings-personal-webauthn.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/settings-vue-settings-personal-webauthn.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)