mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-01 19:27:48 +02:00
feat(theme-classic): add stable class for DocSidebarContainer (#6466)
This commit is contained in:
parent
d73b4f8674
commit
d0fc31c8ae
2 changed files with 8 additions and 3 deletions
|
@ -70,9 +70,13 @@ function DocPageContent({
|
||||||
|
|
||||||
{sidebar && (
|
{sidebar && (
|
||||||
<aside
|
<aside
|
||||||
className={clsx(styles.docSidebarContainer, {
|
className={clsx(
|
||||||
|
ThemeClassNames.docs.docSidebarContainer,
|
||||||
|
styles.docSidebarContainer,
|
||||||
|
{
|
||||||
[styles.docSidebarContainerHidden]: hiddenSidebarContainer,
|
[styles.docSidebarContainerHidden]: hiddenSidebarContainer,
|
||||||
})}
|
},
|
||||||
|
)}
|
||||||
onTransitionEnd={(e) => {
|
onTransitionEnd={(e) => {
|
||||||
if (
|
if (
|
||||||
!e.currentTarget.classList.contains(styles.docSidebarContainer)
|
!e.currentTarget.classList.contains(styles.docSidebarContainer)
|
||||||
|
|
|
@ -48,6 +48,7 @@ export const ThemeClassNames = {
|
||||||
docFooter: 'theme-doc-footer',
|
docFooter: 'theme-doc-footer',
|
||||||
docFooterTagsRow: 'theme-doc-footer-tags-row',
|
docFooterTagsRow: 'theme-doc-footer-tags-row',
|
||||||
docFooterEditMetaRow: 'theme-doc-footer-edit-meta-row',
|
docFooterEditMetaRow: 'theme-doc-footer-edit-meta-row',
|
||||||
|
docSidebarContainer: 'theme-doc-sidebar-container',
|
||||||
docSidebarMenu: 'theme-doc-sidebar-menu',
|
docSidebarMenu: 'theme-doc-sidebar-menu',
|
||||||
docSidebarItemCategory: 'theme-doc-sidebar-item-category',
|
docSidebarItemCategory: 'theme-doc-sidebar-item-category',
|
||||||
docSidebarItemLink: 'theme-doc-sidebar-item-link',
|
docSidebarItemLink: 'theme-doc-sidebar-item-link',
|
||||||
|
|
Loading…
Add table
Reference in a new issue