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

Delete unnecessary navigator delay #920

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
70 changes: 31 additions & 39 deletions src/components/DocumentationLayout.vue
Original file line number Diff line number Diff line change
Expand Up @@ -37,40 +37,38 @@
:showQuickNavigationModal.sync="showQuickNavigationModal"
:technology="technology ? technology.title : ''"
/>
<transition name="delay-hiding">
<slot
name="navigator"
v-bind="{
scrollLockID,
breakpoint,
sidenavVisibleOnMobile,
handleToggleSidenav,
enableQuickNavigation,
openQuickNavigationModal,
}"
<slot
name="navigator"
v-bind="{
scrollLockID,
breakpoint,
sidenavVisibleOnMobile,
handleToggleSidenav,
enableQuickNavigation,
openQuickNavigationModal,
}"
>
<Navigator
key="base-navigator"
v-show="sidenavVisibleOnMobile || breakpoint === BreakpointName.large"
v-bind="{ ...navigatorProps, technologyProps }"
:parent-topic-identifiers="parentTopicIdentifiers"
:references="references"
:scrollLockID="scrollLockID"
:render-filter-on-top="breakpoint !== BreakpointName.large"
@close="handleToggleSidenav(breakpoint)"
>
<Navigator
key="base-navigator"
v-show="sidenavVisibleOnMobile || breakpoint === BreakpointName.large"
v-bind="{ ...navigatorProps, technologyProps }"
:parent-topic-identifiers="parentTopicIdentifiers"
:references="references"
:scrollLockID="scrollLockID"
:render-filter-on-top="breakpoint !== BreakpointName.large"
@close="handleToggleSidenav(breakpoint)"
>
<template v-if="enableQuickNavigation" #filter>
<QuickNavigationButton @click.native="openQuickNavigationModal" />
</template>
<template #above-navigator-head>
<slot name="above-navigator-head"/>
</template>
<template #navigator-head="{ className }">
<slot name="nav-title" :className="className" />
</template>
</Navigator>
</slot>
</transition>
<template v-if="enableQuickNavigation" #filter>
<QuickNavigationButton @click.native="openQuickNavigationModal" />
</template>
<template #above-navigator-head>
<slot name="above-navigator-head"/>
</template>
<template #navigator-head="{ className }">
<slot name="nav-title" :className="className" />
</template>
</Navigator>
</slot>
</div>
</template>
<slot name="content" />
Expand Down Expand Up @@ -245,15 +243,9 @@ export default {
}

.documentation-layout {
--delay: 1s;
display: flex;
flex-flow: column;
background: var(--colors-text-background, var(--color-text-background));

.delay-hiding-leave-active {
// don't hide navigator until delay time has passed
transition: display var(--delay);
}
}

.documentation-layout-aside {
Expand Down