@azerion/bunosaurus-theme-common 0.0.0-stage → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/lib/components/Collapsible/index.d.ts +59 -0
- package/lib/components/Collapsible/index.d.ts.map +1 -0
- package/lib/components/Collapsible/index.js +145 -0
- package/lib/components/Collapsible/index.js.map +1 -0
- package/lib/components/Details/index.d.ts +20 -0
- package/lib/components/Details/index.d.ts.map +1 -0
- package/lib/components/Details/index.js +86 -0
- package/lib/components/Details/index.js.map +1 -0
- package/lib/components/Details/styles.module.css +66 -0
- package/lib/components/ThemedComponent/index.d.ts +31 -0
- package/lib/components/ThemedComponent/index.d.ts.map +1 -0
- package/lib/components/ThemedComponent/index.js +47 -0
- package/lib/components/ThemedComponent/index.js.map +1 -0
- package/lib/components/ThemedComponent/styles.module.css +26 -0
- package/lib/contexts/announcementBar.d.ts +21 -0
- package/lib/contexts/announcementBar.d.ts.map +1 -0
- package/lib/contexts/announcementBar.js +72 -0
- package/lib/contexts/announcementBar.js.map +1 -0
- package/lib/contexts/colorMode.d.ts +23 -0
- package/lib/contexts/colorMode.d.ts.map +1 -0
- package/lib/contexts/colorMode.js +163 -0
- package/lib/contexts/colorMode.js.map +1 -0
- package/lib/contexts/navbarMobileSidebar.d.ts +31 -0
- package/lib/contexts/navbarMobileSidebar.d.ts.map +1 -0
- package/lib/contexts/navbarMobileSidebar.js +65 -0
- package/lib/contexts/navbarMobileSidebar.js.map +1 -0
- package/lib/contexts/navbarSecondaryMenu/content.d.ts +37 -0
- package/lib/contexts/navbarSecondaryMenu/content.d.ts.map +1 -0
- package/lib/contexts/navbarSecondaryMenu/content.js +50 -0
- package/lib/contexts/navbarSecondaryMenu/content.js.map +1 -0
- package/lib/contexts/navbarSecondaryMenu/display.d.ts +24 -0
- package/lib/contexts/navbarSecondaryMenu/display.d.ts.map +1 -0
- package/lib/contexts/navbarSecondaryMenu/display.js +62 -0
- package/lib/contexts/navbarSecondaryMenu/display.js.map +1 -0
- package/lib/hooks/useBackToTopButton.d.ts +27 -0
- package/lib/hooks/useBackToTopButton.d.ts.map +1 -0
- package/lib/hooks/useBackToTopButton.js +50 -0
- package/lib/hooks/useBackToTopButton.js.map +1 -0
- package/lib/hooks/useCodeWordWrap.d.ts +15 -0
- package/lib/hooks/useCodeWordWrap.d.ts.map +1 -0
- package/lib/hooks/useCodeWordWrap.js +67 -0
- package/lib/hooks/useCodeWordWrap.js.map +1 -0
- package/lib/hooks/useHideableNavbar.d.ts +17 -0
- package/lib/hooks/useHideableNavbar.d.ts.map +1 -0
- package/lib/hooks/useHideableNavbar.js +65 -0
- package/lib/hooks/useHideableNavbar.js.map +1 -0
- package/lib/hooks/useLockBodyScroll.d.ts +12 -0
- package/lib/hooks/useLockBodyScroll.d.ts.map +1 -0
- package/lib/hooks/useLockBodyScroll.js +20 -0
- package/lib/hooks/useLockBodyScroll.js.map +1 -0
- package/lib/hooks/useMutationObserver.d.ts +4 -0
- package/lib/hooks/useMutationObserver.d.ts.map +1 -0
- package/lib/hooks/useMutationObserver.js +29 -0
- package/lib/hooks/useMutationObserver.js.map +1 -0
- package/lib/hooks/usePrismTheme.d.ts +13 -0
- package/lib/hooks/usePrismTheme.d.ts.map +1 -0
- package/lib/hooks/usePrismTheme.js +21 -0
- package/lib/hooks/usePrismTheme.js.map +1 -0
- package/lib/hooks/useTOCHighlight.d.ts +25 -0
- package/lib/hooks/useTOCHighlight.d.ts.map +1 -0
- package/lib/hooks/useTOCHighlight.js +130 -0
- package/lib/hooks/useTOCHighlight.js.map +1 -0
- package/lib/hooks/useWindowSize.d.ts +27 -0
- package/lib/hooks/useWindowSize.d.ts.map +1 -0
- package/lib/hooks/useWindowSize.js +49 -0
- package/lib/hooks/useWindowSize.js.map +1 -0
- package/lib/index.d.ts +30 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +37 -0
- package/lib/index.js.map +1 -0
- package/lib/internal.d.ts +35 -0
- package/lib/internal.d.ts.map +1 -0
- package/lib/internal.js +45 -0
- package/lib/internal.js.map +1 -0
- package/lib/translations/blogTranslations.d.ts +20 -0
- package/lib/translations/blogTranslations.d.ts.map +1 -0
- package/lib/translations/blogTranslations.js +52 -0
- package/lib/translations/blogTranslations.js.map +1 -0
- package/lib/translations/contentVisibilityTranslations.d.ts +12 -0
- package/lib/translations/contentVisibilityTranslations.d.ts.map +1 -0
- package/lib/translations/contentVisibilityTranslations.js +30 -0
- package/lib/translations/contentVisibilityTranslations.js.map +1 -0
- package/lib/translations/docsTranslations.d.ts +8 -0
- package/lib/translations/docsTranslations.d.ts.map +1 -0
- package/lib/translations/docsTranslations.js +17 -0
- package/lib/translations/docsTranslations.js.map +1 -0
- package/lib/utils/IntlUtils.d.ts +2 -0
- package/lib/utils/IntlUtils.d.ts.map +1 -0
- package/lib/utils/IntlUtils.js +20 -0
- package/lib/utils/IntlUtils.js.map +1 -0
- package/lib/utils/ThemeClassNames.d.ts +99 -0
- package/lib/utils/ThemeClassNames.d.ts.map +1 -0
- package/lib/utils/ThemeClassNames.js +107 -0
- package/lib/utils/ThemeClassNames.js.map +1 -0
- package/lib/utils/accessibilityUtils.d.ts +8 -0
- package/lib/utils/accessibilityUtils.d.ts.map +1 -0
- package/lib/utils/accessibilityUtils.js +10 -0
- package/lib/utils/accessibilityUtils.js.map +1 -0
- package/lib/utils/admonitionUtils.d.ts +12 -0
- package/lib/utils/admonitionUtils.d.ts.map +1 -0
- package/lib/utils/admonitionUtils.js +32 -0
- package/lib/utils/admonitionUtils.js.map +1 -0
- package/lib/utils/anchorUtils.d.ts +16 -0
- package/lib/utils/anchorUtils.d.ts.map +1 -0
- package/lib/utils/anchorUtils.js +26 -0
- package/lib/utils/anchorUtils.js.map +1 -0
- package/lib/utils/anchorUtils.module.css +14 -0
- package/lib/utils/codeBlockUtils.d.ts +101 -0
- package/lib/utils/codeBlockUtils.d.ts.map +1 -0
- package/lib/utils/codeBlockUtils.js +310 -0
- package/lib/utils/codeBlockUtils.js.map +1 -0
- package/lib/utils/emojiUtils.d.ts +20 -0
- package/lib/utils/emojiUtils.d.ts.map +1 -0
- package/lib/utils/emojiUtils.js +32 -0
- package/lib/utils/emojiUtils.js.map +1 -0
- package/lib/utils/errorBoundaryUtils.d.ts +31 -0
- package/lib/utils/errorBoundaryUtils.d.ts.map +1 -0
- package/lib/utils/errorBoundaryUtils.js +48 -0
- package/lib/utils/errorBoundaryUtils.js.map +1 -0
- package/lib/utils/errorBoundaryUtils.module.css +16 -0
- package/lib/utils/footerUtils.d.ts +13 -0
- package/lib/utils/footerUtils.d.ts.map +1 -0
- package/lib/utils/footerUtils.js +14 -0
- package/lib/utils/footerUtils.js.map +1 -0
- package/lib/utils/historyUtils.d.ts +39 -0
- package/lib/utils/historyUtils.d.ts.map +1 -0
- package/lib/utils/historyUtils.js +148 -0
- package/lib/utils/historyUtils.js.map +1 -0
- package/lib/utils/jsUtils.d.ts +24 -0
- package/lib/utils/jsUtils.d.ts.map +1 -0
- package/lib/utils/jsUtils.js +43 -0
- package/lib/utils/jsUtils.js.map +1 -0
- package/lib/utils/metadataUtils.d.ts +38 -0
- package/lib/utils/metadataUtils.d.ts.map +1 -0
- package/lib/utils/metadataUtils.js +87 -0
- package/lib/utils/metadataUtils.js.map +1 -0
- package/lib/utils/navbarUtils.d.ts +21 -0
- package/lib/utils/navbarUtils.d.ts.map +1 -0
- package/lib/utils/navbarUtils.js +35 -0
- package/lib/utils/navbarUtils.js.map +1 -0
- package/lib/utils/reactUtils.d.ts +60 -0
- package/lib/utils/reactUtils.d.ts.map +1 -0
- package/lib/utils/reactUtils.js +91 -0
- package/lib/utils/reactUtils.js.map +1 -0
- package/lib/utils/regexpUtils.d.ts +12 -0
- package/lib/utils/regexpUtils.d.ts.map +1 -0
- package/lib/utils/regexpUtils.js +18 -0
- package/lib/utils/regexpUtils.js.map +1 -0
- package/lib/utils/routesUtils.d.ts +26 -0
- package/lib/utils/routesUtils.d.ts.map +1 -0
- package/lib/utils/routesUtils.js +54 -0
- package/lib/utils/routesUtils.js.map +1 -0
- package/lib/utils/scrollUtils.d.ts +83 -0
- package/lib/utils/scrollUtils.d.ts.map +1 -0
- package/lib/utils/scrollUtils.js +201 -0
- package/lib/utils/scrollUtils.js.map +1 -0
- package/lib/utils/searchUtils.d.ts +8 -0
- package/lib/utils/searchUtils.d.ts.map +1 -0
- package/lib/utils/searchUtils.js +8 -0
- package/lib/utils/searchUtils.js.map +1 -0
- package/lib/utils/skipToContentUtils.d.ts +20 -0
- package/lib/utils/skipToContentUtils.d.ts.map +1 -0
- package/lib/utils/skipToContentUtils.js +75 -0
- package/lib/utils/skipToContentUtils.js.map +1 -0
- package/lib/utils/storageUtils.d.ts +36 -0
- package/lib/utils/storageUtils.d.ts.map +1 -0
- package/lib/utils/storageUtils.js +193 -0
- package/lib/utils/storageUtils.js.map +1 -0
- package/lib/utils/tabsUtils.d.ts +55 -0
- package/lib/utils/tabsUtils.d.ts.map +1 -0
- package/lib/utils/tabsUtils.js +179 -0
- package/lib/utils/tabsUtils.js.map +1 -0
- package/lib/utils/tagsUtils.d.ts +20 -0
- package/lib/utils/tagsUtils.d.ts.map +1 -0
- package/lib/utils/tagsUtils.js +41 -0
- package/lib/utils/tagsUtils.js.map +1 -0
- package/lib/utils/titleFormatterUtils.d.ts +59 -0
- package/lib/utils/titleFormatterUtils.d.ts.map +1 -0
- package/lib/utils/titleFormatterUtils.js +49 -0
- package/lib/utils/titleFormatterUtils.js.map +1 -0
- package/lib/utils/tocUtils.d.ts +36 -0
- package/lib/utils/tocUtils.d.ts.map +1 -0
- package/lib/utils/tocUtils.js +84 -0
- package/lib/utils/tocUtils.js.map +1 -0
- package/lib/utils/useAlternatePageUtils.d.ts +32 -0
- package/lib/utils/useAlternatePageUtils.d.ts.map +1 -0
- package/lib/utils/useAlternatePageUtils.js +42 -0
- package/lib/utils/useAlternatePageUtils.js.map +1 -0
- package/lib/utils/useLocalPathname.d.ts +13 -0
- package/lib/utils/useLocalPathname.d.ts.map +1 -0
- package/lib/utils/useLocalPathname.js +19 -0
- package/lib/utils/useLocalPathname.js.map +1 -0
- package/lib/utils/useLocationChange.d.ts +17 -0
- package/lib/utils/useLocationChange.d.ts.map +1 -0
- package/lib/utils/useLocationChange.js +31 -0
- package/lib/utils/useLocationChange.js.map +1 -0
- package/lib/utils/usePluralForm.d.ts +21 -0
- package/lib/utils/usePluralForm.d.ts.map +1 -0
- package/lib/utils/usePluralForm.js +93 -0
- package/lib/utils/usePluralForm.js.map +1 -0
- package/lib/utils/useThemeConfig.d.ts +120 -0
- package/lib/utils/useThemeConfig.d.ts.map +1 -0
- package/lib/utils/useThemeConfig.js +14 -0
- package/lib/utils/useThemeConfig.js.map +1 -0
- package/package.json +58 -4
- package/src/components/Collapsible/index.tsx +250 -0
- package/src/components/Details/index.tsx +130 -0
- package/src/components/Details/styles.module.css +66 -0
- package/src/components/ThemedComponent/index.tsx +75 -0
- package/src/components/ThemedComponent/styles.module.css +26 -0
- package/src/contexts/announcementBar.tsx +117 -0
- package/src/contexts/colorMode.tsx +257 -0
- package/src/contexts/navbarMobileSidebar.tsx +119 -0
- package/src/contexts/navbarSecondaryMenu/content.tsx +100 -0
- package/src/contexts/navbarSecondaryMenu/display.tsx +102 -0
- package/src/hooks/useBackToTopButton.ts +73 -0
- package/src/hooks/useCodeWordWrap.ts +107 -0
- package/src/hooks/useHideableNavbar.ts +81 -0
- package/src/hooks/useLockBodyScroll.ts +21 -0
- package/src/hooks/useMutationObserver.ts +38 -0
- package/src/hooks/usePrismTheme.ts +24 -0
- package/src/hooks/useTOCHighlight.ts +189 -0
- package/src/hooks/useWindowSize.ts +67 -0
- package/src/index.ts +112 -0
- package/src/internal.ts +107 -0
- package/src/translations/blogTranslations.tsx +89 -0
- package/src/translations/contentVisibilityTranslations.tsx +51 -0
- package/src/translations/docsTranslations.tsx +28 -0
- package/src/types.d.ts +8 -0
- package/src/utils/IntlUtils.ts +27 -0
- package/src/utils/ThemeClassNames.ts +119 -0
- package/src/utils/accessibilityUtils.ts +10 -0
- package/src/utils/admonitionUtils.tsx +44 -0
- package/src/utils/anchorUtils.module.css +14 -0
- package/src/utils/anchorUtils.ts +31 -0
- package/src/utils/codeBlockUtils.tsx +494 -0
- package/src/utils/emojiUtils.ts +40 -0
- package/src/utils/errorBoundaryUtils.module.css +16 -0
- package/src/utils/errorBoundaryUtils.tsx +71 -0
- package/src/utils/footerUtils.ts +18 -0
- package/src/utils/historyUtils.ts +199 -0
- package/src/utils/jsUtils.ts +54 -0
- package/src/utils/metadataUtils.tsx +145 -0
- package/src/utils/navbarUtils.tsx +45 -0
- package/src/utils/reactUtils.tsx +120 -0
- package/src/utils/regexpUtils.ts +24 -0
- package/src/utils/routesUtils.ts +75 -0
- package/src/utils/scrollUtils.tsx +303 -0
- package/src/utils/searchUtils.ts +8 -0
- package/src/utils/skipToContentUtils.tsx +108 -0
- package/src/utils/storageUtils.ts +260 -0
- package/src/utils/tabsUtils.tsx +307 -0
- package/src/utils/tagsUtils.tsx +61 -0
- package/src/utils/titleFormatterUtils.tsx +120 -0
- package/src/utils/tocUtils.ts +119 -0
- package/src/utils/useAlternatePageUtils.ts +80 -0
- package/src/utils/useLocalPathname.ts +22 -0
- package/src/utils/useLocationChange.ts +41 -0
- package/src/utils/usePluralForm.ts +131 -0
- package/src/utils/useThemeConfig.ts +147 -0
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
export * from './index';
|
|
8
|
+
export { AnnouncementBarProvider, useAnnouncementBar, } from './contexts/announcementBar';
|
|
9
|
+
export { sanitizeTabsChildren, TabsProvider, useTabs, useTabsContextValue, } from './utils/tabsUtils';
|
|
10
|
+
export type { TabValue, TabsProps, TabItemProps } from './utils/tabsUtils';
|
|
11
|
+
export { useNavbarMobileSidebar } from './contexts/navbarMobileSidebar';
|
|
12
|
+
export { useNavbarSecondaryMenu } from './contexts/navbarSecondaryMenu/display';
|
|
13
|
+
export { ColorModeProvider } from './contexts/colorMode';
|
|
14
|
+
export { useAlternatePageUtils } from './utils/useAlternatePageUtils';
|
|
15
|
+
export { type CodeBlockMetadata, createCodeBlockMetadata, getPrismCssVariables, CodeBlockContextProvider, useCodeBlockContext, } from './utils/codeBlockUtils';
|
|
16
|
+
export { DEFAULT_SEARCH_TAG } from './utils/searchUtils';
|
|
17
|
+
export { TitleFormatterProvider, useTitleFormatter, } from './utils/titleFormatterUtils';
|
|
18
|
+
export { useLocationChange } from './utils/useLocationChange';
|
|
19
|
+
export { useLocalPathname } from './utils/useLocalPathname';
|
|
20
|
+
export { useHistoryPopHandler, useHistorySelector, useQueryStringValue, } from './utils/historyUtils';
|
|
21
|
+
export { useFilteredAndTreeifiedTOC, useTreeifiedTOC, type TOCTreeNode, } from './utils/tocUtils';
|
|
22
|
+
export { ScrollControllerProvider, useScrollController, useScrollPosition, useScrollPositionBlocker, useSmoothScrollTo, } from './utils/scrollUtils';
|
|
23
|
+
export { useHomePageRoute, isSamePath } from './utils/routesUtils';
|
|
24
|
+
export { PluginHtmlClassNameProvider } from './utils/metadataUtils';
|
|
25
|
+
export { splitNavbarItems, NavbarProvider } from './utils/navbarUtils';
|
|
26
|
+
export { extractLeadingEmoji } from './utils/emojiUtils';
|
|
27
|
+
export { useTOCHighlight, type TOCHighlightConfig, } from './hooks/useTOCHighlight';
|
|
28
|
+
export { useDateTimeFormat } from './utils/IntlUtils';
|
|
29
|
+
export { useHideableNavbar } from './hooks/useHideableNavbar';
|
|
30
|
+
export { useLockBodyScroll } from './hooks/useLockBodyScroll';
|
|
31
|
+
export { useCodeWordWrap } from './hooks/useCodeWordWrap';
|
|
32
|
+
export { useBackToTopButton } from './hooks/useBackToTopButton';
|
|
33
|
+
export { useDocCardDescriptionCategoryItemsPlural } from './translations/docsTranslations';
|
|
34
|
+
export { useBlogTagsPostsPageTitle, useBlogAuthorPageTitle, translateBlogAuthorsListPageTitle, BlogAuthorsListViewAllLabel, BlogAuthorNoPostsLabel, } from './translations/blogTranslations';
|
|
35
|
+
//# sourceMappingURL=internal.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../src/internal.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAaH,cAAc,SAAS,CAAC;AAExB,OAAO,EACL,uBAAuB,EACvB,kBAAkB,GACnB,MAAM,4BAA4B,CAAC;AAEpC,OAAO,EACL,oBAAoB,EACpB,YAAY,EACZ,OAAO,EACP,mBAAmB,GACpB,MAAM,mBAAmB,CAAC;AAC3B,YAAY,EAAC,QAAQ,EAAE,SAAS,EAAE,YAAY,EAAC,MAAM,mBAAmB,CAAC;AAEzE,OAAO,EAAC,sBAAsB,EAAC,MAAM,gCAAgC,CAAC;AACtE,OAAO,EAAC,sBAAsB,EAAC,MAAM,wCAAwC,CAAC;AAE9E,OAAO,EAAC,iBAAiB,EAAC,MAAM,sBAAsB,CAAC;AAEvD,OAAO,EAAC,qBAAqB,EAAC,MAAM,+BAA+B,CAAC;AAEpE,OAAO,EACL,KAAK,iBAAiB,EACtB,uBAAuB,EACvB,oBAAoB,EACpB,wBAAwB,EACxB,mBAAmB,GACpB,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EAAC,kBAAkB,EAAC,MAAM,qBAAqB,CAAC;AAEvD,OAAO,EACL,sBAAsB,EACtB,iBAAiB,GAClB,MAAM,6BAA6B,CAAC;AAErC,OAAO,EAAC,iBAAiB,EAAC,MAAM,2BAA2B,CAAC;AAE5D,OAAO,EAAC,gBAAgB,EAAC,MAAM,0BAA0B,CAAC;AAE1D,OAAO,EACL,oBAAoB,EACpB,kBAAkB,EAClB,mBAAmB,GACpB,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EACL,0BAA0B,EAC1B,eAAe,EACf,KAAK,WAAW,GACjB,MAAM,kBAAkB,CAAC;AAE1B,OAAO,EACL,wBAAwB,EACxB,mBAAmB,EACnB,iBAAiB,EACjB,wBAAwB,EACxB,iBAAiB,GAClB,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EAAC,gBAAgB,EAAE,UAAU,EAAC,MAAM,qBAAqB,CAAC;AAEjE,OAAO,EAAC,2BAA2B,EAAC,MAAM,uBAAuB,CAAC;AAElE,OAAO,EAAC,gBAAgB,EAAE,cAAc,EAAC,MAAM,qBAAqB,CAAC;AAErE,OAAO,EAAC,mBAAmB,EAAC,MAAM,oBAAoB,CAAC;AAEvD,OAAO,EACL,eAAe,EACf,KAAK,kBAAkB,GACxB,MAAM,yBAAyB,CAAC;AAEjC,OAAO,EAAC,iBAAiB,EAAC,MAAM,mBAAmB,CAAC;AAEpD,OAAO,EAAC,iBAAiB,EAAC,MAAM,2BAA2B,CAAC;AAC5D,OAAO,EAAC,iBAAiB,EAAC,MAAM,2BAA2B,CAAC;AAC5D,OAAO,EAAC,eAAe,EAAC,MAAM,yBAAyB,CAAC;AACxD,OAAO,EAAC,kBAAkB,EAAC,MAAM,4BAA4B,CAAC;AAE9D,OAAO,EAAC,wCAAwC,EAAC,MAAM,iCAAiC,CAAC;AACzF,OAAO,EACL,yBAAyB,EACzB,sBAAsB,EACtB,iCAAiC,EACjC,2BAA2B,EAC3B,sBAAsB,GACvB,MAAM,iCAAiC,CAAC"}
|
package/lib/internal.js
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
// This re-export permits to handle some level of retro-compatibility. Users
|
|
8
|
+
// might swizzle unsafe components and expose these internal imports. When we
|
|
9
|
+
// move an API from internal to public, former internal imports should keep
|
|
10
|
+
// working, so that the change doesn't become breaking.
|
|
11
|
+
//
|
|
12
|
+
// Important: this line is removed from build output with the
|
|
13
|
+
// "removeThemeInternalReexport" script for CI checks. This ensures that none of
|
|
14
|
+
// our internal code relies on this re-export and that we don't forget to
|
|
15
|
+
// migrate theme internal imports to public imports.
|
|
16
|
+
//
|
|
17
|
+
// eslint-disable-next-line no-restricted-syntax
|
|
18
|
+
export * from './index';
|
|
19
|
+
export { AnnouncementBarProvider, useAnnouncementBar, } from './contexts/announcementBar';
|
|
20
|
+
export { sanitizeTabsChildren, TabsProvider, useTabs, useTabsContextValue, } from './utils/tabsUtils';
|
|
21
|
+
export { useNavbarMobileSidebar } from './contexts/navbarMobileSidebar';
|
|
22
|
+
export { useNavbarSecondaryMenu } from './contexts/navbarSecondaryMenu/display';
|
|
23
|
+
export { ColorModeProvider } from './contexts/colorMode';
|
|
24
|
+
export { useAlternatePageUtils } from './utils/useAlternatePageUtils';
|
|
25
|
+
export { createCodeBlockMetadata, getPrismCssVariables, CodeBlockContextProvider, useCodeBlockContext, } from './utils/codeBlockUtils';
|
|
26
|
+
export { DEFAULT_SEARCH_TAG } from './utils/searchUtils';
|
|
27
|
+
export { TitleFormatterProvider, useTitleFormatter, } from './utils/titleFormatterUtils';
|
|
28
|
+
export { useLocationChange } from './utils/useLocationChange';
|
|
29
|
+
export { useLocalPathname } from './utils/useLocalPathname';
|
|
30
|
+
export { useHistoryPopHandler, useHistorySelector, useQueryStringValue, } from './utils/historyUtils';
|
|
31
|
+
export { useFilteredAndTreeifiedTOC, useTreeifiedTOC, } from './utils/tocUtils';
|
|
32
|
+
export { ScrollControllerProvider, useScrollController, useScrollPosition, useScrollPositionBlocker, useSmoothScrollTo, } from './utils/scrollUtils';
|
|
33
|
+
export { useHomePageRoute, isSamePath } from './utils/routesUtils';
|
|
34
|
+
export { PluginHtmlClassNameProvider } from './utils/metadataUtils';
|
|
35
|
+
export { splitNavbarItems, NavbarProvider } from './utils/navbarUtils';
|
|
36
|
+
export { extractLeadingEmoji } from './utils/emojiUtils';
|
|
37
|
+
export { useTOCHighlight, } from './hooks/useTOCHighlight';
|
|
38
|
+
export { useDateTimeFormat } from './utils/IntlUtils';
|
|
39
|
+
export { useHideableNavbar } from './hooks/useHideableNavbar';
|
|
40
|
+
export { useLockBodyScroll } from './hooks/useLockBodyScroll';
|
|
41
|
+
export { useCodeWordWrap } from './hooks/useCodeWordWrap';
|
|
42
|
+
export { useBackToTopButton } from './hooks/useBackToTopButton';
|
|
43
|
+
export { useDocCardDescriptionCategoryItemsPlural } from './translations/docsTranslations';
|
|
44
|
+
export { useBlogTagsPostsPageTitle, useBlogAuthorPageTitle, translateBlogAuthorsListPageTitle, BlogAuthorsListViewAllLabel, BlogAuthorNoPostsLabel, } from './translations/blogTranslations';
|
|
45
|
+
//# sourceMappingURL=internal.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"internal.js","sourceRoot":"","sources":["../src/internal.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,4EAA4E;AAC5E,6EAA6E;AAC7E,2EAA2E;AAC3E,uDAAuD;AACvD,EAAE;AACF,6DAA6D;AAC7D,gFAAgF;AAChF,yEAAyE;AACzE,oDAAoD;AACpD,EAAE;AACF,gDAAgD;AAChD,cAAc,SAAS,CAAC;AAExB,OAAO,EACL,uBAAuB,EACvB,kBAAkB,GACnB,MAAM,4BAA4B,CAAC;AAEpC,OAAO,EACL,oBAAoB,EACpB,YAAY,EACZ,OAAO,EACP,mBAAmB,GACpB,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EAAC,sBAAsB,EAAC,MAAM,gCAAgC,CAAC;AACtE,OAAO,EAAC,sBAAsB,EAAC,MAAM,wCAAwC,CAAC;AAE9E,OAAO,EAAC,iBAAiB,EAAC,MAAM,sBAAsB,CAAC;AAEvD,OAAO,EAAC,qBAAqB,EAAC,MAAM,+BAA+B,CAAC;AAEpE,OAAO,EAEL,uBAAuB,EACvB,oBAAoB,EACpB,wBAAwB,EACxB,mBAAmB,GACpB,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EAAC,kBAAkB,EAAC,MAAM,qBAAqB,CAAC;AAEvD,OAAO,EACL,sBAAsB,EACtB,iBAAiB,GAClB,MAAM,6BAA6B,CAAC;AAErC,OAAO,EAAC,iBAAiB,EAAC,MAAM,2BAA2B,CAAC;AAE5D,OAAO,EAAC,gBAAgB,EAAC,MAAM,0BAA0B,CAAC;AAE1D,OAAO,EACL,oBAAoB,EACpB,kBAAkB,EAClB,mBAAmB,GACpB,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EACL,0BAA0B,EAC1B,eAAe,GAEhB,MAAM,kBAAkB,CAAC;AAE1B,OAAO,EACL,wBAAwB,EACxB,mBAAmB,EACnB,iBAAiB,EACjB,wBAAwB,EACxB,iBAAiB,GAClB,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EAAC,gBAAgB,EAAE,UAAU,EAAC,MAAM,qBAAqB,CAAC;AAEjE,OAAO,EAAC,2BAA2B,EAAC,MAAM,uBAAuB,CAAC;AAElE,OAAO,EAAC,gBAAgB,EAAE,cAAc,EAAC,MAAM,qBAAqB,CAAC;AAErE,OAAO,EAAC,mBAAmB,EAAC,MAAM,oBAAoB,CAAC;AAEvD,OAAO,EACL,eAAe,GAEhB,MAAM,yBAAyB,CAAC;AAEjC,OAAO,EAAC,iBAAiB,EAAC,MAAM,mBAAmB,CAAC;AAEpD,OAAO,EAAC,iBAAiB,EAAC,MAAM,2BAA2B,CAAC;AAC5D,OAAO,EAAC,iBAAiB,EAAC,MAAM,2BAA2B,CAAC;AAC5D,OAAO,EAAC,eAAe,EAAC,MAAM,yBAAyB,CAAC;AACxD,OAAO,EAAC,kBAAkB,EAAC,MAAM,4BAA4B,CAAC;AAE9D,OAAO,EAAC,wCAAwC,EAAC,MAAM,iCAAiC,CAAC;AACzF,OAAO,EACL,yBAAyB,EACzB,sBAAsB,EACtB,iCAAiC,EACjC,2BAA2B,EAC3B,sBAAsB,GACvB,MAAM,iCAAiC,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
import type { ReactNode } from 'react';
|
|
8
|
+
export declare function useBlogTagsPostsPageTitle(tag: {
|
|
9
|
+
label: string;
|
|
10
|
+
count: number;
|
|
11
|
+
}): string;
|
|
12
|
+
export declare function useBlogAuthorPageTitle(author: {
|
|
13
|
+
key: string;
|
|
14
|
+
name?: string;
|
|
15
|
+
count: number;
|
|
16
|
+
}): string;
|
|
17
|
+
export declare const translateBlogAuthorsListPageTitle: () => string;
|
|
18
|
+
export declare function BlogAuthorsListViewAllLabel(): ReactNode;
|
|
19
|
+
export declare function BlogAuthorNoPostsLabel(): ReactNode;
|
|
20
|
+
//# sourceMappingURL=blogTranslations.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"blogTranslations.d.ts","sourceRoot":"","sources":["../../src/translations/blogTranslations.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAC,SAAS,EAAC,MAAM,OAAO,CAAC;AAsBrC,wBAAgB,yBAAyB,CAAC,GAAG,EAAE;IAC7C,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;CACf,GAAG,MAAM,CAUT;AAED,wBAAgB,sBAAsB,CAAC,MAAM,EAAE;IAC7C,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;CACf,GAAG,MAAM,CAaT;AAED,eAAO,MAAM,iCAAiC,QAAO,MAKjD,CAAC;AAEL,wBAAgB,2BAA2B,IAAI,SAAS,CAQvD;AAED,wBAAgB,sBAAsB,IAAI,SAAS,CAQlD"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
import Translate, { translate } from '@docusaurus/Translate';
|
|
8
|
+
import { usePluralForm } from '../utils/usePluralForm';
|
|
9
|
+
// Only used locally
|
|
10
|
+
function useBlogPostsPlural() {
|
|
11
|
+
const { selectMessage } = usePluralForm();
|
|
12
|
+
return (count) => selectMessage(count, translate({
|
|
13
|
+
id: 'theme.blog.post.plurals',
|
|
14
|
+
description: 'Pluralized label for "{count} posts". Use as much plural forms (separated by "|") as your language support (see https://www.unicode.org/cldr/cldr-aux/charts/34/supplemental/language_plural_rules.html)',
|
|
15
|
+
message: 'One post|{count} posts',
|
|
16
|
+
}, { count }));
|
|
17
|
+
}
|
|
18
|
+
export function useBlogTagsPostsPageTitle(tag) {
|
|
19
|
+
const blogPostsPlural = useBlogPostsPlural();
|
|
20
|
+
return translate({
|
|
21
|
+
id: 'theme.blog.tagTitle',
|
|
22
|
+
description: 'The title of the page for a blog tag',
|
|
23
|
+
message: '{nPosts} tagged with "{tagName}"',
|
|
24
|
+
}, { nPosts: blogPostsPlural(tag.count), tagName: tag.label });
|
|
25
|
+
}
|
|
26
|
+
export function useBlogAuthorPageTitle(author) {
|
|
27
|
+
const blogPostsPlural = useBlogPostsPlural();
|
|
28
|
+
return translate({
|
|
29
|
+
id: 'theme.blog.author.pageTitle',
|
|
30
|
+
description: 'The title of the page for a blog author',
|
|
31
|
+
message: '{authorName} - {nPosts}',
|
|
32
|
+
}, {
|
|
33
|
+
nPosts: blogPostsPlural(author.count),
|
|
34
|
+
authorName: author.name || author.key,
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
export const translateBlogAuthorsListPageTitle = () => translate({
|
|
38
|
+
id: 'theme.blog.authorsList.pageTitle',
|
|
39
|
+
message: 'Authors',
|
|
40
|
+
description: 'The title of the authors page',
|
|
41
|
+
});
|
|
42
|
+
export function BlogAuthorsListViewAllLabel() {
|
|
43
|
+
return (<Translate id="theme.blog.authorsList.viewAll" description="The label of the link targeting the blog authors page">
|
|
44
|
+
View all authors
|
|
45
|
+
</Translate>);
|
|
46
|
+
}
|
|
47
|
+
export function BlogAuthorNoPostsLabel() {
|
|
48
|
+
return (<Translate id="theme.blog.author.noPosts" description="The text for authors with 0 blog post">
|
|
49
|
+
This author has not written any posts yet.
|
|
50
|
+
</Translate>);
|
|
51
|
+
}
|
|
52
|
+
//# sourceMappingURL=blogTranslations.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"blogTranslations.js","sourceRoot":"","sources":["../../src/translations/blogTranslations.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,SAAS,EAAE,EAAC,SAAS,EAAC,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EAAC,aAAa,EAAC,MAAM,wBAAwB,CAAC;AAErD,oBAAoB;AACpB,SAAS,kBAAkB;IACzB,MAAM,EAAC,aAAa,EAAC,GAAG,aAAa,EAAE,CAAC;IACxC,OAAO,CAAC,KAAa,EAAE,EAAE,CACvB,aAAa,CACX,KAAK,EACL,SAAS,CACP;QACE,EAAE,EAAE,yBAAyB;QAC7B,WAAW,EACT,0MAA0M;QAC5M,OAAO,EAAE,wBAAwB;KAClC,EACD,EAAC,KAAK,EAAC,CACR,CACF,CAAC;AACN,CAAC;AAED,MAAM,UAAU,yBAAyB,CAAC,GAGzC;IACC,MAAM,eAAe,GAAG,kBAAkB,EAAE,CAAC;IAC7C,OAAO,SAAS,CACd;QACE,EAAE,EAAE,qBAAqB;QACzB,WAAW,EAAE,sCAAsC;QACnD,OAAO,EAAE,kCAAkC;KAC5C,EACD,EAAC,MAAM,EAAE,eAAe,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE,OAAO,EAAE,GAAG,CAAC,KAAK,EAAC,CACzD,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,sBAAsB,CAAC,MAItC;IACC,MAAM,eAAe,GAAG,kBAAkB,EAAE,CAAC;IAC7C,OAAO,SAAS,CACd;QACE,EAAE,EAAE,6BAA6B;QACjC,WAAW,EAAE,yCAAyC;QACtD,OAAO,EAAE,yBAAyB;KACnC,EACD;QACE,MAAM,EAAE,eAAe,CAAC,MAAM,CAAC,KAAK,CAAC;QACrC,UAAU,EAAE,MAAM,CAAC,IAAI,IAAI,MAAM,CAAC,GAAG;KACtC,CACF,CAAC;AACJ,CAAC;AAED,MAAM,CAAC,MAAM,iCAAiC,GAAG,GAAW,EAAE,CAC5D,SAAS,CAAC;IACR,EAAE,EAAE,kCAAkC;IACtC,OAAO,EAAE,SAAS;IAClB,WAAW,EAAE,+BAA+B;CAC7C,CAAC,CAAC;AAEL,MAAM,UAAU,2BAA2B;IACzC,OAAO,CACL,CAAC,SAAS,CACR,EAAE,CAAC,gCAAgC,CACnC,WAAW,CAAC,uDAAuD,CACnE;;IACF,EAAE,SAAS,CAAC,CACb,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,sBAAsB;IACpC,OAAO,CACL,CAAC,SAAS,CACR,EAAE,CAAC,2BAA2B,CAC9B,WAAW,CAAC,uCAAuC,CACnD;;IACF,EAAE,SAAS,CAAC,CACb,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
import type { ReactNode } from 'react';
|
|
8
|
+
export declare function UnlistedBannerTitle(): ReactNode;
|
|
9
|
+
export declare function UnlistedBannerMessage(): ReactNode;
|
|
10
|
+
export declare function DraftBannerTitle(): ReactNode;
|
|
11
|
+
export declare function DraftBannerMessage(): ReactNode;
|
|
12
|
+
//# sourceMappingURL=contentVisibilityTranslations.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"contentVisibilityTranslations.d.ts","sourceRoot":"","sources":["../../src/translations/contentVisibilityTranslations.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAC,SAAS,EAAC,MAAM,OAAO,CAAC;AAGrC,wBAAgB,mBAAmB,IAAI,SAAS,CAQ/C;AAED,wBAAgB,qBAAqB,IAAI,SAAS,CASjD;AAED,wBAAgB,gBAAgB,IAAI,SAAS,CAQ5C;AAED,wBAAgB,kBAAkB,IAAI,SAAS,CAS9C"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
import Translate from '@docusaurus/Translate';
|
|
8
|
+
export function UnlistedBannerTitle() {
|
|
9
|
+
return (<Translate id="theme.contentVisibility.unlistedBanner.title" description="The unlisted content banner title">
|
|
10
|
+
Unlisted page
|
|
11
|
+
</Translate>);
|
|
12
|
+
}
|
|
13
|
+
export function UnlistedBannerMessage() {
|
|
14
|
+
return (<Translate id="theme.contentVisibility.unlistedBanner.message" description="The unlisted content banner message">
|
|
15
|
+
This page is unlisted. Search engines will not index it, and only users
|
|
16
|
+
having a direct link can access it.
|
|
17
|
+
</Translate>);
|
|
18
|
+
}
|
|
19
|
+
export function DraftBannerTitle() {
|
|
20
|
+
return (<Translate id="theme.contentVisibility.draftBanner.title" description="The draft content banner title">
|
|
21
|
+
Draft page
|
|
22
|
+
</Translate>);
|
|
23
|
+
}
|
|
24
|
+
export function DraftBannerMessage() {
|
|
25
|
+
return (<Translate id="theme.contentVisibility.draftBanner.message" description="The draft content banner message">
|
|
26
|
+
This page is a draft. It will only be visible in dev and be excluded from
|
|
27
|
+
the production build.
|
|
28
|
+
</Translate>);
|
|
29
|
+
}
|
|
30
|
+
//# sourceMappingURL=contentVisibilityTranslations.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"contentVisibilityTranslations.js","sourceRoot":"","sources":["../../src/translations/contentVisibilityTranslations.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,SAAS,MAAM,uBAAuB,CAAC;AAE9C,MAAM,UAAU,mBAAmB;IACjC,OAAO,CACL,CAAC,SAAS,CACR,EAAE,CAAC,8CAA8C,CACjD,WAAW,CAAC,mCAAmC,CAC/C;;IACF,EAAE,SAAS,CAAC,CACb,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,qBAAqB;IACnC,OAAO,CACL,CAAC,SAAS,CACR,EAAE,CAAC,gDAAgD,CACnD,WAAW,CAAC,qCAAqC,CACjD;;;IAEF,EAAE,SAAS,CAAC,CACb,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,gBAAgB;IAC9B,OAAO,CACL,CAAC,SAAS,CACR,EAAE,CAAC,2CAA2C,CAC9C,WAAW,CAAC,gCAAgC,CAC5C;;IACF,EAAE,SAAS,CAAC,CACb,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,kBAAkB;IAChC,OAAO,CACL,CAAC,SAAS,CACR,EAAE,CAAC,6CAA6C,CAChD,WAAW,CAAC,kCAAkC,CAC9C;;;IAEF,EAAE,SAAS,CAAC,CACb,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
export declare function useDocCardDescriptionCategoryItemsPlural(): (count: number) => string;
|
|
8
|
+
//# sourceMappingURL=docsTranslations.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"docsTranslations.d.ts","sourceRoot":"","sources":["../../src/translations/docsTranslations.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AAKH,wBAAgB,wCAAwC,IAAI,CAC1D,KAAK,EAAE,MAAM,KACV,MAAM,CAeV"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
import { translate } from '@docusaurus/Translate';
|
|
8
|
+
import { usePluralForm } from '../utils/usePluralForm';
|
|
9
|
+
export function useDocCardDescriptionCategoryItemsPlural() {
|
|
10
|
+
const { selectMessage } = usePluralForm();
|
|
11
|
+
return (count) => selectMessage(count, translate({
|
|
12
|
+
message: '1 item|{count} items',
|
|
13
|
+
id: 'theme.docs.DocCard.categoryDescription.plurals',
|
|
14
|
+
description: 'The default description for a category card in the generated index about how many items this category includes',
|
|
15
|
+
}, { count }));
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=docsTranslations.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"docsTranslations.js","sourceRoot":"","sources":["../../src/translations/docsTranslations.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAC,SAAS,EAAC,MAAM,uBAAuB,CAAC;AAChD,OAAO,EAAC,aAAa,EAAC,MAAM,wBAAwB,CAAC;AAErD,MAAM,UAAU,wCAAwC;IAGtD,MAAM,EAAC,aAAa,EAAC,GAAG,aAAa,EAAE,CAAC;IACxC,OAAO,CAAC,KAAa,EAAE,EAAE,CACvB,aAAa,CACX,KAAK,EACL,SAAS,CACP;QACE,OAAO,EAAE,sBAAsB;QAC/B,EAAE,EAAE,gDAAgD;QACpD,WAAW,EACT,gHAAgH;KACnH,EACD,EAAC,KAAK,EAAC,CACR,CACF,CAAC;AACN,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IntlUtils.d.ts","sourceRoot":"","sources":["../../src/utils/IntlUtils.ts"],"names":[],"mappings":"AAeA,wBAAgB,iBAAiB,CAC/B,OAAO,GAAE,IAAI,CAAC,qBAA0B,GACvC,IAAI,CAAC,cAAc,CASrB"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
import useDocusaurusContext from '@docusaurus/useDocusaurusContext';
|
|
8
|
+
function useCalendar() {
|
|
9
|
+
const { i18n: { currentLocale, localeConfigs }, } = useDocusaurusContext();
|
|
10
|
+
return localeConfigs[currentLocale].calendar;
|
|
11
|
+
}
|
|
12
|
+
export function useDateTimeFormat(options = {}) {
|
|
13
|
+
const { i18n: { currentLocale }, } = useDocusaurusContext();
|
|
14
|
+
const calendar = useCalendar();
|
|
15
|
+
return new Intl.DateTimeFormat(currentLocale, {
|
|
16
|
+
calendar,
|
|
17
|
+
...options,
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=IntlUtils.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IntlUtils.js","sourceRoot":"","sources":["../../src/utils/IntlUtils.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,oBAAoB,MAAM,kCAAkC,CAAC;AAEpE,SAAS,WAAW;IAClB,MAAM,EACJ,IAAI,EAAE,EAAC,aAAa,EAAE,aAAa,EAAC,GACrC,GAAG,oBAAoB,EAAE,CAAC;IAC3B,OAAO,aAAa,CAAC,aAAa,CAAE,CAAC,QAAQ,CAAC;AAChD,CAAC;AAED,MAAM,UAAU,iBAAiB,CAC/B,OAAO,GAA+B,EAAE;IAExC,MAAM,EACJ,IAAI,EAAE,EAAC,aAAa,EAAC,GACtB,GAAG,oBAAoB,EAAE,CAAC;IAC3B,MAAM,QAAQ,GAAG,WAAW,EAAE,CAAC;IAC/B,OAAO,IAAI,IAAI,CAAC,cAAc,CAAC,aAAa,EAAE;QAC5C,QAAQ;QACR,GAAG,OAAO;KACX,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* These class names are used to style page layouts in Docusaurus, meant to be
|
|
9
|
+
* targeted by user-provided custom CSS selectors.
|
|
10
|
+
*/
|
|
11
|
+
export declare const ThemeClassNames: {
|
|
12
|
+
readonly page: {
|
|
13
|
+
readonly blogListPage: 'blog-list-page';
|
|
14
|
+
readonly blogPostPage: 'blog-post-page';
|
|
15
|
+
readonly blogTagsListPage: 'blog-tags-list-page';
|
|
16
|
+
readonly blogTagPostListPage: 'blog-tags-post-list-page';
|
|
17
|
+
readonly blogAuthorsListPage: 'blog-authors-list-page';
|
|
18
|
+
readonly blogAuthorsPostsPage: 'blog-authors-posts-page';
|
|
19
|
+
readonly docsDocPage: 'docs-doc-page';
|
|
20
|
+
readonly docsTagsListPage: 'docs-tags-list-page';
|
|
21
|
+
readonly docsTagDocListPage: 'docs-tags-doc-list-page';
|
|
22
|
+
readonly mdxPage: 'mdx-page';
|
|
23
|
+
};
|
|
24
|
+
readonly wrapper: {
|
|
25
|
+
readonly main: 'main-wrapper';
|
|
26
|
+
readonly blogPages: 'blog-wrapper';
|
|
27
|
+
readonly docsPages: 'docs-wrapper';
|
|
28
|
+
readonly mdxPages: 'mdx-wrapper';
|
|
29
|
+
};
|
|
30
|
+
readonly common: {
|
|
31
|
+
readonly editThisPage: 'theme-edit-this-page';
|
|
32
|
+
readonly lastUpdated: 'theme-last-updated';
|
|
33
|
+
readonly backToTopButton: 'theme-back-to-top-button';
|
|
34
|
+
readonly codeBlock: 'theme-code-block';
|
|
35
|
+
readonly admonition: 'theme-admonition';
|
|
36
|
+
readonly unlistedBanner: 'theme-unlisted-banner';
|
|
37
|
+
readonly draftBanner: 'theme-draft-banner';
|
|
38
|
+
readonly admonitionType: (type: string) => string;
|
|
39
|
+
};
|
|
40
|
+
readonly announcementBar: {
|
|
41
|
+
readonly container: 'theme-announcement-bar';
|
|
42
|
+
};
|
|
43
|
+
readonly tabs: {
|
|
44
|
+
readonly container: 'theme-tabs-container';
|
|
45
|
+
};
|
|
46
|
+
readonly layout: {
|
|
47
|
+
readonly navbar: {
|
|
48
|
+
readonly container: 'theme-layout-navbar';
|
|
49
|
+
readonly containerLeft: 'theme-layout-navbar-left';
|
|
50
|
+
readonly containerRight: 'theme-layout-navbar-right';
|
|
51
|
+
readonly mobileSidebar: {
|
|
52
|
+
readonly container: 'theme-layout-navbar-sidebar';
|
|
53
|
+
readonly panel: 'theme-layout-navbar-sidebar-panel';
|
|
54
|
+
};
|
|
55
|
+
};
|
|
56
|
+
readonly main: {
|
|
57
|
+
readonly container: 'theme-layout-main';
|
|
58
|
+
};
|
|
59
|
+
readonly footer: {
|
|
60
|
+
readonly container: 'theme-layout-footer';
|
|
61
|
+
readonly column: 'theme-layout-footer-column';
|
|
62
|
+
};
|
|
63
|
+
};
|
|
64
|
+
/**
|
|
65
|
+
* Follows the naming convention "theme-{blog,doc,version,page}?-<suffix>"
|
|
66
|
+
*/
|
|
67
|
+
readonly docs: {
|
|
68
|
+
readonly docVersionBanner: 'theme-doc-version-banner';
|
|
69
|
+
readonly docVersionBadge: 'theme-doc-version-badge';
|
|
70
|
+
readonly docBreadcrumbs: 'theme-doc-breadcrumbs';
|
|
71
|
+
readonly docMarkdown: 'theme-doc-markdown';
|
|
72
|
+
readonly docTocMobile: 'theme-doc-toc-mobile';
|
|
73
|
+
readonly docTocDesktop: 'theme-doc-toc-desktop';
|
|
74
|
+
readonly docFooter: 'theme-doc-footer';
|
|
75
|
+
readonly docFooterTagsRow: 'theme-doc-footer-tags-row';
|
|
76
|
+
readonly docFooterEditMetaRow: 'theme-doc-footer-edit-meta-row';
|
|
77
|
+
readonly docSidebarContainer: 'theme-doc-sidebar-container';
|
|
78
|
+
readonly docSidebarMenu: 'theme-doc-sidebar-menu';
|
|
79
|
+
readonly docSidebarItemCategory: 'theme-doc-sidebar-item-category';
|
|
80
|
+
readonly docSidebarItemLink: 'theme-doc-sidebar-item-link';
|
|
81
|
+
readonly docSidebarItemCategoryLevel: (level: number) => `theme-doc-sidebar-item-category-level-${number}`;
|
|
82
|
+
readonly docSidebarItemLinkLevel: (level: number) => `theme-doc-sidebar-item-link-level-${number}`;
|
|
83
|
+
readonly docCard: {
|
|
84
|
+
readonly container: 'theme-doc-card-container';
|
|
85
|
+
readonly heading: 'theme-doc-card-heading';
|
|
86
|
+
readonly icon: 'theme-doc-card-icon';
|
|
87
|
+
readonly title: 'theme-doc-card-title';
|
|
88
|
+
readonly description: 'theme-doc-card-description';
|
|
89
|
+
};
|
|
90
|
+
};
|
|
91
|
+
readonly blog: {
|
|
92
|
+
readonly blogFooterTagsRow: 'theme-blog-footer-tags-row';
|
|
93
|
+
readonly blogFooterEditMetaRow: 'theme-blog-footer-edit-meta-row';
|
|
94
|
+
};
|
|
95
|
+
readonly pages: {
|
|
96
|
+
readonly pageFooterEditMetaRow: 'theme-pages-footer-edit-meta-row';
|
|
97
|
+
};
|
|
98
|
+
};
|
|
99
|
+
//# sourceMappingURL=ThemeClassNames.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ThemeClassNames.d.ts","sourceRoot":"","sources":["../../src/utils/ThemeClassNames.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAKH;;;GAGG;AACH,eAAO,MAAM,eAAe;aAC1B,IAAI;iBACF,YAAY,EAAE,gBAAgB;iBAC9B,YAAY,EAAE,gBAAgB;iBAC9B,gBAAgB,EAAE,qBAAqB;iBACvC,mBAAmB,EAAE,0BAA0B;iBAC/C,mBAAmB,EAAE,wBAAwB;iBAC7C,oBAAoB,EAAE,yBAAyB;iBAE/C,WAAW,EAAE,eAAe;iBAC5B,gBAAgB,EAAE,qBAAqB;iBACvC,kBAAkB,EAAE,yBAAyB;iBAE7C,OAAO,EAAE,UAAU;;aAIrB,OAAO;iBACL,IAAI,EAAE,cAAc;iBAIpB,SAAS,EAAE,cAAc;iBACzB,SAAS,EAAE,cAAc;iBACzB,QAAQ,EAAE,aAAa;;aAGzB,MAAM;iBACJ,YAAY,EAAE,sBAAsB;iBACpC,WAAW,EAAE,oBAAoB;iBACjC,eAAe,EAAE,0BAA0B;iBAC3C,SAAS,EAAE,kBAAkB;iBAC7B,UAAU,EAAE,kBAAkB;iBAC9B,cAAc,EAAE,uBAAuB;iBACvC,WAAW,EAAE,oBAAoB;iBAEjC,cAAc,SAAS,MAAM;;aAG/B,eAAe;iBACb,SAAS,EAAE,wBAAwB;;aAGrC,IAAI;iBACF,SAAS,EAAE,sBAAsB;;aAGnC,MAAM;iBACJ,MAAM;qBACJ,SAAS,EAAE,qBAAqB;qBAChC,aAAa,EAAE,0BAA0B;qBACzC,cAAc,EAAE,2BAA2B;qBAC3C,aAAa;yBACX,SAAS,EAAE,6BAA6B;yBACxC,KAAK,EAAE,mCAAmC;;;iBAG9C,IAAI;qBACF,SAAS,EAAE,mBAAmB;;iBAEhC,MAAM;qBACJ,SAAS,EAAE,qBAAqB;qBAChC,MAAM,EAAE,4BAA4B;;;IAIxC;;OAEG;aACH,IAAI;iBACF,gBAAgB,EAAE,0BAA0B;iBAC5C,eAAe,EAAE,yBAAyB;iBAC1C,cAAc,EAAE,uBAAuB;iBACvC,WAAW,EAAE,oBAAoB;iBACjC,YAAY,EAAE,sBAAsB;iBACpC,aAAa,EAAE,uBAAuB;iBACtC,SAAS,EAAE,kBAAkB;iBAC7B,gBAAgB,EAAE,2BAA2B;iBAC7C,oBAAoB,EAAE,gCAAgC;iBACtD,mBAAmB,EAAE,6BAA6B;iBAClD,cAAc,EAAE,wBAAwB;iBACxC,sBAAsB,EAAE,iCAAiC;iBACzD,kBAAkB,EAAE,6BAA6B;iBACjD,2BAA2B,UAAU,MAAM;iBAE3C,uBAAuB,UAAU,MAAM;iBAGvC,OAAO;qBACL,SAAS,EAAE,0BAA0B;qBACrC,OAAO,EAAE,wBAAwB;qBACjC,IAAI,EAAE,qBAAqB;qBAC3B,KAAK,EAAE,sBAAsB;qBAC7B,WAAW,EAAE,4BAA4B;;;aAG7C,IAAI;iBAEF,iBAAiB,EAAE,4BAA4B;iBAC/C,qBAAqB,EAAE,iCAAiC;;aAE1D,KAAK;iBACH,qBAAqB,EAAE,kCAAkC;;CAEnD,CAAC"}
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
// Please do not modify the classnames! This is a breaking change, and annoying
|
|
8
|
+
// for users!
|
|
9
|
+
/**
|
|
10
|
+
* These class names are used to style page layouts in Docusaurus, meant to be
|
|
11
|
+
* targeted by user-provided custom CSS selectors.
|
|
12
|
+
*/
|
|
13
|
+
export const ThemeClassNames = {
|
|
14
|
+
page: {
|
|
15
|
+
blogListPage: 'blog-list-page',
|
|
16
|
+
blogPostPage: 'blog-post-page',
|
|
17
|
+
blogTagsListPage: 'blog-tags-list-page',
|
|
18
|
+
blogTagPostListPage: 'blog-tags-post-list-page',
|
|
19
|
+
blogAuthorsListPage: 'blog-authors-list-page',
|
|
20
|
+
blogAuthorsPostsPage: 'blog-authors-posts-page',
|
|
21
|
+
docsDocPage: 'docs-doc-page',
|
|
22
|
+
docsTagsListPage: 'docs-tags-list-page',
|
|
23
|
+
docsTagDocListPage: 'docs-tags-doc-list-page',
|
|
24
|
+
mdxPage: 'mdx-page',
|
|
25
|
+
},
|
|
26
|
+
// TODO Docusaurus v4: remove old classes?
|
|
27
|
+
wrapper: {
|
|
28
|
+
main: 'main-wrapper', // replaced by theme-layout-main
|
|
29
|
+
// TODO these wrapper class names are now quite useless
|
|
30
|
+
// TODO do breaking change later in 3.0
|
|
31
|
+
// we already add plugin name/id class on <html>: that's enough
|
|
32
|
+
blogPages: 'blog-wrapper',
|
|
33
|
+
docsPages: 'docs-wrapper',
|
|
34
|
+
mdxPages: 'mdx-wrapper',
|
|
35
|
+
},
|
|
36
|
+
common: {
|
|
37
|
+
editThisPage: 'theme-edit-this-page',
|
|
38
|
+
lastUpdated: 'theme-last-updated',
|
|
39
|
+
backToTopButton: 'theme-back-to-top-button',
|
|
40
|
+
codeBlock: 'theme-code-block',
|
|
41
|
+
admonition: 'theme-admonition',
|
|
42
|
+
unlistedBanner: 'theme-unlisted-banner',
|
|
43
|
+
draftBanner: 'theme-draft-banner',
|
|
44
|
+
admonitionType: (type) => `theme-admonition-${type}`,
|
|
45
|
+
},
|
|
46
|
+
announcementBar: {
|
|
47
|
+
container: 'theme-announcement-bar',
|
|
48
|
+
},
|
|
49
|
+
tabs: {
|
|
50
|
+
container: 'theme-tabs-container',
|
|
51
|
+
},
|
|
52
|
+
layout: {
|
|
53
|
+
navbar: {
|
|
54
|
+
container: 'theme-layout-navbar',
|
|
55
|
+
containerLeft: 'theme-layout-navbar-left',
|
|
56
|
+
containerRight: 'theme-layout-navbar-right',
|
|
57
|
+
mobileSidebar: {
|
|
58
|
+
container: 'theme-layout-navbar-sidebar',
|
|
59
|
+
panel: 'theme-layout-navbar-sidebar-panel',
|
|
60
|
+
},
|
|
61
|
+
},
|
|
62
|
+
main: {
|
|
63
|
+
container: 'theme-layout-main',
|
|
64
|
+
},
|
|
65
|
+
footer: {
|
|
66
|
+
container: 'theme-layout-footer',
|
|
67
|
+
column: 'theme-layout-footer-column',
|
|
68
|
+
},
|
|
69
|
+
},
|
|
70
|
+
/**
|
|
71
|
+
* Follows the naming convention "theme-{blog,doc,version,page}?-<suffix>"
|
|
72
|
+
*/
|
|
73
|
+
docs: {
|
|
74
|
+
docVersionBanner: 'theme-doc-version-banner',
|
|
75
|
+
docVersionBadge: 'theme-doc-version-badge',
|
|
76
|
+
docBreadcrumbs: 'theme-doc-breadcrumbs',
|
|
77
|
+
docMarkdown: 'theme-doc-markdown',
|
|
78
|
+
docTocMobile: 'theme-doc-toc-mobile',
|
|
79
|
+
docTocDesktop: 'theme-doc-toc-desktop',
|
|
80
|
+
docFooter: 'theme-doc-footer',
|
|
81
|
+
docFooterTagsRow: 'theme-doc-footer-tags-row',
|
|
82
|
+
docFooterEditMetaRow: 'theme-doc-footer-edit-meta-row',
|
|
83
|
+
docSidebarContainer: 'theme-doc-sidebar-container',
|
|
84
|
+
docSidebarMenu: 'theme-doc-sidebar-menu',
|
|
85
|
+
docSidebarItemCategory: 'theme-doc-sidebar-item-category',
|
|
86
|
+
docSidebarItemLink: 'theme-doc-sidebar-item-link',
|
|
87
|
+
docSidebarItemCategoryLevel: (level) => `theme-doc-sidebar-item-category-level-${level}`,
|
|
88
|
+
docSidebarItemLinkLevel: (level) => `theme-doc-sidebar-item-link-level-${level}`,
|
|
89
|
+
// TODO add other stable classNames here
|
|
90
|
+
docCard: {
|
|
91
|
+
container: 'theme-doc-card-container',
|
|
92
|
+
heading: 'theme-doc-card-heading',
|
|
93
|
+
icon: 'theme-doc-card-icon',
|
|
94
|
+
title: 'theme-doc-card-title',
|
|
95
|
+
description: 'theme-doc-card-description',
|
|
96
|
+
},
|
|
97
|
+
},
|
|
98
|
+
blog: {
|
|
99
|
+
// TODO add other stable classNames here
|
|
100
|
+
blogFooterTagsRow: 'theme-blog-footer-tags-row',
|
|
101
|
+
blogFooterEditMetaRow: 'theme-blog-footer-edit-meta-row',
|
|
102
|
+
},
|
|
103
|
+
pages: {
|
|
104
|
+
pageFooterEditMetaRow: 'theme-pages-footer-edit-meta-row',
|
|
105
|
+
},
|
|
106
|
+
};
|
|
107
|
+
//# sourceMappingURL=ThemeClassNames.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ThemeClassNames.js","sourceRoot":"","sources":["../../src/utils/ThemeClassNames.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,+EAA+E;AAC/E,aAAa;AAEb;;;GAGG;AACH,MAAM,CAAC,MAAM,eAAe,GAAG;IAC7B,IAAI,EAAE;QACJ,YAAY,EAAE,gBAAgB;QAC9B,YAAY,EAAE,gBAAgB;QAC9B,gBAAgB,EAAE,qBAAqB;QACvC,mBAAmB,EAAE,0BAA0B;QAC/C,mBAAmB,EAAE,wBAAwB;QAC7C,oBAAoB,EAAE,yBAAyB;QAE/C,WAAW,EAAE,eAAe;QAC5B,gBAAgB,EAAE,qBAAqB;QACvC,kBAAkB,EAAE,yBAAyB;QAE7C,OAAO,EAAE,UAAU;KACpB;IAED,0CAA0C;IAC1C,OAAO,EAAE;QACP,IAAI,EAAE,cAAc,EAAE,gCAAgC;QACtD,uDAAuD;QACvD,uCAAuC;QACvC,+DAA+D;QAC/D,SAAS,EAAE,cAAc;QACzB,SAAS,EAAE,cAAc;QACzB,QAAQ,EAAE,aAAa;KACxB;IAED,MAAM,EAAE;QACN,YAAY,EAAE,sBAAsB;QACpC,WAAW,EAAE,oBAAoB;QACjC,eAAe,EAAE,0BAA0B;QAC3C,SAAS,EAAE,kBAAkB;QAC7B,UAAU,EAAE,kBAAkB;QAC9B,cAAc,EAAE,uBAAuB;QACvC,WAAW,EAAE,oBAAoB;QAEjC,cAAc,EAAE,CAAC,IAAY,EAAE,EAAE,CAAC,oBAAoB,IAAI,EAAE;KAC7D;IAED,eAAe,EAAE;QACf,SAAS,EAAE,wBAAwB;KACpC;IAED,IAAI,EAAE;QACJ,SAAS,EAAE,sBAAsB;KAClC;IAED,MAAM,EAAE;QACN,MAAM,EAAE;YACN,SAAS,EAAE,qBAAqB;YAChC,aAAa,EAAE,0BAA0B;YACzC,cAAc,EAAE,2BAA2B;YAC3C,aAAa,EAAE;gBACb,SAAS,EAAE,6BAA6B;gBACxC,KAAK,EAAE,mCAAmC;aAC3C;SACF;QACD,IAAI,EAAE;YACJ,SAAS,EAAE,mBAAmB;SAC/B;QACD,MAAM,EAAE;YACN,SAAS,EAAE,qBAAqB;YAChC,MAAM,EAAE,4BAA4B;SACrC;KACF;IAED;;OAEG;IACH,IAAI,EAAE;QACJ,gBAAgB,EAAE,0BAA0B;QAC5C,eAAe,EAAE,yBAAyB;QAC1C,cAAc,EAAE,uBAAuB;QACvC,WAAW,EAAE,oBAAoB;QACjC,YAAY,EAAE,sBAAsB;QACpC,aAAa,EAAE,uBAAuB;QACtC,SAAS,EAAE,kBAAkB;QAC7B,gBAAgB,EAAE,2BAA2B;QAC7C,oBAAoB,EAAE,gCAAgC;QACtD,mBAAmB,EAAE,6BAA6B;QAClD,cAAc,EAAE,wBAAwB;QACxC,sBAAsB,EAAE,iCAAiC;QACzD,kBAAkB,EAAE,6BAA6B;QACjD,2BAA2B,EAAE,CAAC,KAAa,EAAE,EAAE,CAC7C,yCAAyC,KAAK,EAAW;QAC3D,uBAAuB,EAAE,CAAC,KAAa,EAAE,EAAE,CACzC,qCAAqC,KAAK,EAAW;QACvD,wCAAwC;QACxC,OAAO,EAAE;YACP,SAAS,EAAE,0BAA0B;YACrC,OAAO,EAAE,wBAAwB;YACjC,IAAI,EAAE,qBAAqB;YAC3B,KAAK,EAAE,sBAAsB;YAC7B,WAAW,EAAE,4BAA4B;SAC1C;KACF;IACD,IAAI,EAAE;QACJ,wCAAwC;QACxC,iBAAiB,EAAE,4BAA4B;QAC/C,qBAAqB,EAAE,iCAAiC;KACzD;IACD,KAAK,EAAE;QACL,qBAAqB,EAAE,kCAAkC;KAC1D;CACO,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
export declare function prefersReducedMotion(): boolean;
|
|
8
|
+
//# sourceMappingURL=accessibilityUtils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"accessibilityUtils.d.ts","sourceRoot":"","sources":["../../src/utils/accessibilityUtils.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,wBAAgB,oBAAoB,IAAI,OAAO,CAE9C"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
export function prefersReducedMotion() {
|
|
8
|
+
return window.matchMedia('(prefers-reduced-motion: reduce)').matches;
|
|
9
|
+
}
|
|
10
|
+
//# sourceMappingURL=accessibilityUtils.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"accessibilityUtils.js","sourceRoot":"","sources":["../../src/utils/accessibilityUtils.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,UAAU,oBAAoB;IAClC,OAAO,MAAM,CAAC,UAAU,CAAC,kCAAkC,CAAC,CAAC,OAAO,CAAC;AACvE,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
import { type ReactNode } from 'react';
|
|
8
|
+
export declare function processAdmonitionProps<Props extends {
|
|
9
|
+
readonly children: ReactNode;
|
|
10
|
+
readonly title?: ReactNode;
|
|
11
|
+
}>(props: Props): Props;
|
|
12
|
+
//# sourceMappingURL=admonitionUtils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"admonitionUtils.d.ts","sourceRoot":"","sources":["../../src/utils/admonitionUtils.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAc,EAAC,KAAK,SAAS,EAAoB,MAAM,OAAO,CAAC;AAuB/D,wBAAgB,sBAAsB,CACpC,KAAK,SAAS;IAAC,QAAQ,CAAC,QAAQ,EAAE,SAAS,CAAC;IAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,SAAS,CAAA;CAAC,EACxE,KAAK,EAAE,KAAK,GAAG,KAAK,CAWrB"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
import React from 'react';
|
|
8
|
+
// Workaround because it's difficult in MDX v1 to provide a MDX title as props
|
|
9
|
+
// See https://github.com/facebook/docusaurus/pull/7152#issuecomment-1145779682
|
|
10
|
+
function extractMDXAdmonitionTitle(children) {
|
|
11
|
+
const items = React.Children.toArray(children);
|
|
12
|
+
const mdxAdmonitionTitleWrapper = items.find((item) => React.isValidElement(item) && item.type === 'mdxAdmonitionTitle');
|
|
13
|
+
const rest = items.filter((item) => item !== mdxAdmonitionTitleWrapper);
|
|
14
|
+
const mdxAdmonitionTitle = mdxAdmonitionTitleWrapper?.props.children;
|
|
15
|
+
return {
|
|
16
|
+
mdxAdmonitionTitle,
|
|
17
|
+
rest: rest.length > 0 ? <>{rest}</> : null,
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
export function processAdmonitionProps(props) {
|
|
21
|
+
const { mdxAdmonitionTitle, rest } = extractMDXAdmonitionTitle(props.children);
|
|
22
|
+
const title = props.title ?? mdxAdmonitionTitle;
|
|
23
|
+
return {
|
|
24
|
+
...props,
|
|
25
|
+
// Do not return "title: undefined" prop
|
|
26
|
+
// this might create unwanted props overrides when merging props
|
|
27
|
+
// For example: {...default,...props}
|
|
28
|
+
...(title && { title }),
|
|
29
|
+
children: rest,
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
//# sourceMappingURL=admonitionUtils.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"admonitionUtils.js","sourceRoot":"","sources":["../../src/utils/admonitionUtils.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAA0C,MAAM,OAAO,CAAC;AAE/D,8EAA8E;AAC9E,+EAA+E;AAC/E,SAAS,yBAAyB,CAAC,QAAmB;IAIpD,MAAM,KAAK,GAAG,KAAK,CAAC,QAAQ,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC;IAC/C,MAAM,yBAAyB,GAAG,KAAK,CAAC,IAAI,CAC1C,CAAC,IAAI,EAAE,EAAE,CAAC,KAAK,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,IAAI,CAAC,IAAI,KAAK,oBAAoB,CACxB,CAAC;IAErD,MAAM,IAAI,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,KAAK,yBAAyB,CAAC,CAAC;IAExE,MAAM,kBAAkB,GAAG,yBAAyB,EAAE,KAAK,CAAC,QAAQ,CAAC;IAErE,OAAO;QACL,kBAAkB;QAClB,IAAI,EAAE,IAAI,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI;KAC3C,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,sBAAsB,CAEpC,KAAY;IACZ,MAAM,EAAC,kBAAkB,EAAE,IAAI,EAAC,GAAG,yBAAyB,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC;IAC7E,MAAM,KAAK,GAAG,KAAK,CAAC,KAAK,IAAI,kBAAkB,CAAC;IAChD,OAAO;QACL,GAAG,KAAK;QACR,wCAAwC;QACxC,gEAAgE;QAChE,qCAAqC;QACrC,GAAG,CAAC,KAAK,IAAI,EAAC,KAAK,EAAC,CAAC;QACrB,QAAQ,EAAE,IAAI;KACf,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* When the navbar is sticky, this ensures that when clicking a hash link,
|
|
9
|
+
* we do not navigate to an anchor that will appear below the navbar.
|
|
10
|
+
* This happens in particular for MDX headings and footnotes.
|
|
11
|
+
*
|
|
12
|
+
* See https://github.com/facebook/docusaurus/issues/11232
|
|
13
|
+
* See also headings case https://x.com/JoshWComeau/status/1332015868725891076
|
|
14
|
+
*/
|
|
15
|
+
export declare function useAnchorTargetClassName(id: string | undefined): string | undefined;
|
|
16
|
+
//# sourceMappingURL=anchorUtils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"anchorUtils.d.ts","sourceRoot":"","sources":["../../src/utils/anchorUtils.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAKH;;;;;;;GAOG;AACH,wBAAgB,wBAAwB,CACtC,EAAE,EAAE,MAAM,GAAG,SAAS,GACrB,MAAM,GAAG,SAAS,CAUpB"}
|