Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(NcAppSettingsDialog): Remove navigation instead of hiding and fix styles #4865

Merged
merged 2 commits into from Nov 23, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
23 changes: 8 additions & 15 deletions src/components/NcAppSettingsDialog/NcAppSettingsDialog.vue
Expand Up @@ -144,9 +144,9 @@ export default {
v-bind="dialogProperties"
@update:open="handleCloseModal">
<template #navigation="{ isCollapsed }">
<ul :aria-label="settingsNavigationAriaLabel"
v-show="!isCollapsed"
:class="{ 'navigation-list': true, 'navigation-list--collapsed': isCollapsed }"
<ul v-if="!isCollapsed"
:aria-label="settingsNavigationAriaLabel"
class="navigation-list"
role="tablist">
<li v-for="section in sections" :key="section.id">
<a :aria-selected="section.id === selectedSection"
Expand Down Expand Up @@ -405,20 +405,19 @@ export default {
&:deep(.dialog) {
min-height: 256px;
}
&__navigation {
:deep &__navigation {
min-width: 200px;
margin-right: 20px;
overflow-x: hidden;
overflow-y: auto;
position: relative;
height: 100%;
}
&__content {
max-width: 100vw;
:deep &__content {
box-sizing: border-box;

overflow-y: auto;
overflow-x: hidden;
padding: 24px;
width: 100%;
padding-inline: 20px;
min-height: 256px;
}
}
Expand All @@ -429,12 +428,6 @@ export default {
overflow-y: auto;
padding: 12px;

&--collapsed {
display: flex;
flex-direction: row;
gap: 6px;
}

&__link {
display: flex;
align-content: center;
Expand Down
2 changes: 1 addition & 1 deletion src/components/NcDialog/NcDialog.vue
Expand Up @@ -180,7 +180,7 @@
/**
* Size of the underlying NcModal
* @default 'small'
* @values 'small', 'normal', 'large', 'full'

Check warning on line 183 in src/components/NcDialog/NcDialog.vue

View workflow job for this annotation

GitHub Actions / eslint

Invalid JSDoc tag name "values"
*/
size: {
type: String,
Expand Down Expand Up @@ -272,7 +272,7 @@
/**
* We use the dialog width to decide if we collapse the navigation (flex direction row)
*/
const { width: dialogWidth } = useElementSize(wrapper)
const { width: dialogWidth } = useElementSize(wrapper, { width: 900 })

/**
* Whether the navigation is collapsed due to dialog and window size
Expand Down