Skip to content

Commit

Permalink
Merge pull request #42646 from nextcloud/backport/42634/stable28
Browse files Browse the repository at this point in the history
[stable28] Include grid view toggle in accessibility switch
  • Loading branch information
JuliaKirschenheuter committed Jan 9, 2024
2 parents a4ed172 + cb5c29b commit 2ef0940
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
5 changes: 4 additions & 1 deletion apps/files/src/views/Settings.vue
Expand Up @@ -38,7 +38,8 @@
@update:checked="setConfig('crop_image_previews', $event)">
{{ t('files', 'Crop image previews') }}
</NcCheckboxRadioSwitch>
<NcCheckboxRadioSwitch :checked="userConfig.grid_view"
<NcCheckboxRadioSwitch v-if="enableGridView"
:checked="userConfig.grid_view"
@update:checked="setConfig('grid_view', $event)">
{{ t('files', 'Enable the grid view') }}
</NcCheckboxRadioSwitch>
Expand Down Expand Up @@ -99,6 +100,7 @@ import { generateRemoteUrl, generateUrl } from '@nextcloud/router'
import { getCurrentUser } from '@nextcloud/auth'
import { showError, showSuccess } from '@nextcloud/dialogs'
import { translate } from '@nextcloud/l10n'
import { loadState } from '@nextcloud/initial-state'
import { useUserConfigStore } from '../store/userconfig.ts'
export default {
Expand Down Expand Up @@ -136,6 +138,7 @@ export default {
webdavDocs: 'https://docs.nextcloud.com/server/stable/go.php?to=user-webdav',
appPasswordUrl: generateUrl('/settings/user/security#generate-app-token-section'),
webdavUrlCopied: false,
enableGridView: (loadState('core', 'config', [])['enable_non-accessible_features'] ?? true),
}
},
Expand Down
4 changes: 2 additions & 2 deletions dist/files-main.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/files-main.js.map

Large diffs are not rendered by default.

0 comments on commit 2ef0940

Please sign in to comment.