vitepress 2.0.0-alpha.2 → 2.0.0-alpha.21
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 +34 -2
- package/THIRD-PARTY-NOTICES.md +1736 -0
- package/bin/vitepress.js +14 -0
- package/client.d.ts +9 -0
- package/dist/client/app/components/ClientOnly.d.ts +5 -0
- package/dist/client/app/components/ClientOnly.js +11 -10
- package/dist/client/app/components/Content.d.ts +17 -0
- package/dist/client/app/components/Content.js +25 -22
- package/dist/client/app/composables/codeGroups.d.ts +3 -0
- package/dist/client/app/composables/codeGroups.js +36 -39
- package/dist/client/app/composables/copyCode.d.ts +3 -0
- package/dist/client/app/composables/copyCode.js +59 -70
- package/dist/client/app/composables/head.d.ts +5 -0
- package/dist/client/app/composables/head.js +56 -74
- package/dist/client/app/composables/icon.d.ts +12 -0
- package/dist/client/app/composables/icon.js +56 -0
- package/dist/client/app/composables/preFetch.d.ts +3 -0
- package/dist/client/app/composables/preFetch.js +64 -96
- package/dist/client/app/data.d.ts +9 -0
- package/dist/client/app/data.js +34 -59
- package/dist/client/app/devtools.d.ts +7 -0
- package/dist/client/app/devtools.js +29 -28
- package/dist/client/app/index.d.ts +11 -0
- package/dist/client/app/index.js +106 -131
- package/dist/client/app/router.d.ts +49 -0
- package/dist/client/app/router.js +198 -239
- package/dist/client/app/ssr.d.ts +4 -0
- package/dist/client/app/ssr.js +14 -9
- package/dist/client/app/theme.d.ts +24 -0
- package/dist/client/app/theme.js +0 -1
- package/dist/client/app/utils.d.ts +35 -0
- package/dist/client/app/utils.js +77 -110
- package/dist/client/index.d.ts +21 -137
- package/dist/client/index.js +8 -9
- package/dist/client/shared.d.ts +88 -0
- package/dist/client/shared.js +265 -141
- package/dist/client/theme-default/Layout.d.vue.ts +79 -0
- package/dist/client/theme-default/Layout.vue +33 -36
- package/dist/client/theme-default/NotFound.d.vue.ts +3 -0
- package/dist/client/theme-default/NotFound.vue +33 -35
- package/dist/client/theme-default/components/VPAlgoliaSearchBox.d.vue.ts +11 -0
- package/dist/client/theme-default/components/VPAlgoliaSearchBox.vue +202 -70
- package/dist/client/theme-default/components/VPBackdrop.d.vue.ts +6 -0
- package/dist/client/theme-default/components/VPBackdrop.vue +8 -12
- package/dist/client/theme-default/components/VPBadge.d.vue.ts +19 -0
- package/dist/client/theme-default/components/VPBadge.vue +49 -26
- package/dist/client/theme-default/components/VPButton.d.vue.ts +25 -0
- package/dist/client/theme-default/components/VPButton.vue +53 -36
- package/dist/client/theme-default/components/VPCarbonAds.d.vue.ts +7 -0
- package/dist/client/theme-default/components/VPCarbonAds.vue +51 -52
- package/dist/client/theme-default/components/VPContent.d.vue.ts +59 -0
- package/dist/client/theme-default/components/VPContent.vue +27 -26
- package/dist/client/theme-default/components/VPDoc.d.vue.ts +33 -0
- package/dist/client/theme-default/components/VPDoc.vue +52 -48
- package/dist/client/theme-default/components/VPDocAside.d.vue.ts +23 -0
- package/dist/client/theme-default/components/VPDocAside.vue +7 -8
- package/dist/client/theme-default/components/VPDocAsideCarbonAds.d.vue.ts +7 -0
- package/dist/client/theme-default/components/VPDocAsideCarbonAds.vue +7 -11
- package/dist/client/theme-default/components/VPDocAsideOutline.d.vue.ts +3 -0
- package/dist/client/theme-default/components/VPDocAsideOutline.vue +22 -38
- package/dist/client/theme-default/components/VPDocAsideSponsors.d.vue.ts +10 -0
- package/dist/client/theme-default/components/VPDocAsideSponsors.vue +17 -11
- package/dist/client/theme-default/components/VPDocFooter.d.vue.ts +13 -0
- package/dist/client/theme-default/components/VPDocFooter.vue +38 -45
- package/dist/client/theme-default/components/VPDocFooterLastUpdated.d.vue.ts +3 -0
- package/dist/client/theme-default/components/VPDocFooterLastUpdated.vue +30 -29
- package/dist/client/theme-default/components/VPDocOutlineItem.d.vue.ts +8 -0
- package/dist/client/theme-default/components/VPDocOutlineItem.vue +20 -19
- package/dist/client/theme-default/components/VPFeature.d.vue.ts +13 -0
- package/dist/client/theme-default/components/VPFeature.vue +62 -36
- package/dist/client/theme-default/components/VPFeatures.d.vue.ts +16 -0
- package/dist/client/theme-default/components/VPFeatures.vue +35 -48
- package/dist/client/theme-default/components/VPFlyout.d.vue.ts +26 -0
- package/dist/client/theme-default/components/VPFlyout.vue +111 -47
- package/dist/client/theme-default/components/VPFooter.d.vue.ts +3 -0
- package/dist/client/theme-default/components/VPFooter.vue +22 -15
- package/dist/client/theme-default/components/VPHero.d.vue.ts +38 -0
- package/dist/client/theme-default/components/VPHero.vue +109 -99
- package/dist/client/theme-default/components/VPHome.d.vue.ts +31 -0
- package/dist/client/theme-default/components/VPHome.vue +15 -15
- package/dist/client/theme-default/components/VPHomeContent.d.vue.ts +13 -0
- package/dist/client/theme-default/components/VPHomeContent.vue +9 -27
- package/dist/client/theme-default/components/VPHomeFeatures.d.vue.ts +3 -0
- package/dist/client/theme-default/components/VPHomeFeatures.vue +4 -5
- package/dist/client/theme-default/components/VPHomeHero.d.vue.ts +23 -0
- package/dist/client/theme-default/components/VPHomeHero.vue +5 -5
- package/dist/client/theme-default/components/VPHomeSponsors.d.vue.ts +21 -0
- package/dist/client/theme-default/components/VPHomeSponsors.vue +42 -43
- package/dist/client/theme-default/components/VPIcon.d.vue.ts +8 -0
- package/dist/client/theme-default/components/VPIcon.vue +29 -0
- package/dist/client/theme-default/components/VPImage.d.vue.ts +8 -0
- package/dist/client/theme-default/components/VPImage.vue +20 -14
- package/dist/client/theme-default/components/VPLink.d.vue.ts +23 -0
- package/dist/client/theme-default/components/VPLink.vue +42 -23
- package/dist/client/theme-default/components/VPLocalNav.d.vue.ts +10 -0
- package/dist/client/theme-default/components/VPLocalNav.vue +69 -86
- package/dist/client/theme-default/components/VPLocalNavOutlineDropdown.d.vue.ts +8 -0
- package/dist/client/theme-default/components/VPLocalNavOutlineDropdown.vue +98 -96
- package/dist/client/theme-default/components/VPLocalSearchBox.d.vue.ts +7 -0
- package/dist/client/theme-default/components/VPLocalSearchBox.vue +391 -454
- package/dist/client/theme-default/components/VPMenu.d.vue.ts +23 -0
- package/dist/client/theme-default/components/VPMenu.vue +19 -31
- package/dist/client/theme-default/components/VPMenuGroup.d.vue.ts +22 -0
- package/dist/client/theme-default/components/VPMenuGroup.vue +72 -18
- package/dist/client/theme-default/components/VPMenuLink.d.vue.ts +22 -0
- package/dist/client/theme-default/components/VPMenuLink.vue +65 -31
- package/dist/client/theme-default/components/VPNav.d.vue.ts +23 -0
- package/dist/client/theme-default/components/VPNav.vue +18 -24
- package/dist/client/theme-default/components/VPNavAppearance.d.vue.ts +9 -0
- package/dist/client/theme-default/components/VPNavAppearance.vue +88 -0
- package/dist/client/theme-default/components/VPNavBar.d.vue.ts +26 -0
- package/dist/client/theme-default/components/VPNavBar.vue +170 -142
- package/dist/client/theme-default/components/VPNavBarAskAiButton.d.vue.ts +3 -0
- package/dist/client/theme-default/components/VPNavBarAskAiButton.vue +31 -0
- package/dist/client/theme-default/components/VPNavBarExtra.d.vue.ts +3 -0
- package/dist/client/theme-default/components/VPNavBarExtra.vue +51 -73
- package/dist/client/theme-default/components/VPNavBarHamburger.d.vue.ts +10 -0
- package/dist/client/theme-default/components/VPNavBarHamburger.vue +38 -28
- package/dist/client/theme-default/components/VPNavBarSearch.d.vue.ts +3 -0
- package/dist/client/theme-default/components/VPNavBarSearch.vue +129 -160
- package/dist/client/theme-default/components/VPNavBarSearchButton.d.vue.ts +6 -0
- package/dist/client/theme-default/components/VPNavBarSearchButton.vue +48 -182
- package/dist/client/theme-default/components/VPNavBarTitle.d.vue.ts +15 -0
- package/dist/client/theme-default/components/VPNavBarTitle.vue +39 -38
- package/dist/client/theme-default/components/VPNavMenu.d.vue.ts +6 -0
- package/dist/client/theme-default/components/VPNavMenu.vue +76 -0
- package/dist/client/theme-default/components/VPNavMenuGroup.d.vue.ts +11 -0
- package/dist/client/theme-default/components/VPNavMenuGroup.vue +140 -0
- package/dist/client/theme-default/components/VPNavMenuLink.d.vue.ts +8 -0
- package/dist/client/theme-default/components/VPNavMenuLink.vue +69 -0
- package/dist/client/theme-default/components/VPNavScreen.d.vue.ts +18 -0
- package/dist/client/theme-default/components/VPNavScreen.vue +36 -34
- package/dist/client/theme-default/components/VPNavSocialLinks.d.vue.ts +6 -0
- package/dist/client/theme-default/components/VPNavSocialLinks.vue +36 -0
- package/dist/client/theme-default/components/VPNavTranslations.d.vue.ts +9 -0
- package/dist/client/theme-default/components/VPNavTranslations.vue +170 -0
- package/dist/client/theme-default/components/VPPage.d.vue.ts +15 -0
- package/dist/client/theme-default/components/VPSidebar.d.vue.ts +18 -0
- package/dist/client/theme-default/components/VPSidebar.vue +40 -53
- package/dist/client/theme-default/components/VPSidebarGroup.d.vue.ts +7 -0
- package/dist/client/theme-default/components/VPSidebarGroup.vue +24 -29
- package/dist/client/theme-default/components/VPSidebarItem.d.vue.ts +8 -0
- package/dist/client/theme-default/components/VPSidebarItem.vue +60 -93
- package/dist/client/theme-default/components/VPSkipLink.d.vue.ts +6 -0
- package/dist/client/theme-default/components/VPSkipLink.vue +23 -42
- package/dist/client/theme-default/components/VPSocialLink.d.vue.ts +11 -0
- package/dist/client/theme-default/components/VPSocialLink.vue +42 -49
- package/dist/client/theme-default/components/VPSocialLinks.d.vue.ts +10 -0
- package/dist/client/theme-default/components/VPSocialLinks.vue +26 -16
- package/dist/client/theme-default/components/VPSponsors.d.vue.ts +18 -0
- package/dist/client/theme-default/components/VPSponsors.vue +34 -33
- package/dist/client/theme-default/components/VPSponsorsGrid.d.vue.ts +15 -0
- package/dist/client/theme-default/components/VPSponsorsGrid.vue +23 -26
- package/dist/client/theme-default/components/VPSwitch.d.vue.ts +13 -0
- package/dist/client/theme-default/components/VPSwitch.vue +12 -13
- package/dist/client/theme-default/components/VPSwitchAppearance.d.vue.ts +3 -0
- package/dist/client/theme-default/components/VPSwitchAppearance.vue +16 -21
- package/dist/client/theme-default/components/VPTeamMembers.d.vue.ts +10 -0
- package/dist/client/theme-default/components/VPTeamMembers.vue +59 -32
- package/dist/client/theme-default/components/VPTeamMembersItem.d.vue.ts +10 -0
- package/dist/client/theme-default/components/VPTeamMembersItem.vue +62 -58
- package/dist/client/theme-default/components/VPTeamPage.d.vue.ts +13 -0
- package/dist/client/theme-default/components/VPTeamPage.vue +14 -14
- package/dist/client/theme-default/components/VPTeamPageSection.d.vue.ts +17 -0
- package/dist/client/theme-default/components/VPTeamPageSection.vue +20 -19
- package/dist/client/theme-default/components/VPTeamPageTitle.d.vue.ts +15 -0
- package/dist/client/theme-default/components/VPTeamPageTitle.vue +22 -22
- package/dist/client/theme-default/composables/data.d.ts +5 -0
- package/dist/client/theme-default/composables/data.js +5 -2
- package/dist/client/theme-default/composables/edit-link.d.ts +6 -0
- package/dist/client/theme-default/composables/edit-link.js +17 -15
- package/dist/client/theme-default/composables/flyout.d.ts +10 -0
- package/dist/client/theme-default/composables/flyout.js +33 -32
- package/dist/client/theme-default/composables/langs.d.ts +44 -0
- package/dist/client/theme-default/composables/langs.js +48 -24
- package/dist/client/theme-default/composables/layout.d.ts +13 -0
- package/dist/client/theme-default/composables/layout.js +68 -0
- package/dist/client/theme-default/composables/nav-overflow.d.ts +54 -0
- package/dist/client/theme-default/composables/nav-overflow.js +179 -0
- package/dist/client/theme-default/composables/nav.d.ts +25 -0
- package/dist/client/theme-default/composables/nav.js +58 -29
- package/dist/client/theme-default/composables/outline.d.ts +8 -0
- package/dist/client/theme-default/composables/outline.js +144 -166
- package/dist/client/theme-default/composables/prev-next.d.ts +16 -0
- package/dist/client/theme-default/composables/prev-next.js +34 -56
- package/dist/client/theme-default/composables/scroll-lock.d.ts +4 -0
- package/dist/client/theme-default/composables/scroll-lock.js +95 -0
- package/dist/client/theme-default/composables/sidebar.d.ts +25 -0
- package/dist/client/theme-default/composables/sidebar.js +96 -133
- package/dist/client/theme-default/composables/sponsor-grid.d.ts +10 -0
- package/dist/client/theme-default/composables/sponsor-grid.js +69 -76
- package/dist/client/theme-default/fonts/inter-italic-cyrillic-ext.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-italic-cyrillic.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-italic-greek-ext.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-italic-greek.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-italic-latin-ext.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-italic-latin.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-italic-symbols.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-italic-vietnamese.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-roman-cyrillic-ext.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-roman-cyrillic.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-roman-greek-ext.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-roman-greek.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-roman-latin-ext.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-roman-latin.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-roman-symbols.woff2 +0 -0
- package/dist/client/theme-default/fonts/inter-roman-vietnamese.woff2 +0 -0
- package/dist/client/theme-default/index.d.ts +3 -0
- package/dist/client/theme-default/index.js +4 -3
- package/dist/client/theme-default/styles/base.css +279 -211
- package/dist/client/theme-default/styles/components/custom-block.css +12 -7
- package/dist/client/theme-default/styles/components/vp-code-group.css +13 -16
- package/dist/client/theme-default/styles/components/vp-code.css +10 -2
- package/dist/client/theme-default/styles/components/vp-doc.css +188 -142
- package/dist/client/theme-default/styles/components/vp-sponsor.css +48 -37
- package/dist/client/theme-default/styles/docsearch.css +138 -0
- package/dist/client/theme-default/styles/fonts.css +216 -55
- package/dist/client/theme-default/styles/icons.css +42 -22
- package/dist/client/theme-default/styles/vars.css +111 -46
- package/dist/client/theme-default/support/docsearch.d.ts +57 -0
- package/dist/client/theme-default/support/docsearch.js +145 -0
- package/dist/client/theme-default/support/local-search.d.ts +9 -0
- package/dist/client/theme-default/support/local-search.js +31 -0
- package/dist/client/theme-default/support/lru.d.ts +11 -0
- package/dist/client/theme-default/support/lru.js +30 -33
- package/dist/client/theme-default/support/reactivity.d.ts +4 -0
- package/dist/client/theme-default/support/reactivity.js +10 -0
- package/dist/client/theme-default/support/sidebar.d.ts +27 -0
- package/dist/client/theme-default/support/sidebar.js +69 -80
- package/dist/client/theme-default/support/translation.d.ts +6 -0
- package/dist/client/theme-default/support/translation.js +33 -47
- package/dist/client/theme-default/support/utils.d.ts +7 -0
- package/dist/client/theme-default/support/utils.js +39 -30
- package/dist/client/theme-default/without-fonts.d.ts +25 -0
- package/dist/client/theme-default/without-fonts.js +37 -36
- package/dist/node/chunk-BjrVv9r8.js +28627 -0
- package/dist/node/cli.d.ts +1 -0
- package/dist/node/cli.js +160 -423
- package/dist/node/index.d.ts +1761 -2476
- package/dist/node/index.js +1 -121
- package/dist/web-types.json +75 -0
- package/package.json +89 -98
- package/template/.vitepress/config.js +3 -1
- package/template/.vitepress/theme/style.css +3 -11
- package/theme.d.ts +30 -23
- package/types/default-theme.d.ts +109 -113
- package/types/docsearch.d.ts +61 -142
- package/types/shared.d.ts +469 -50
- package/dist/client/theme-default/components/VPNavBarAppearance.vue +0 -32
- package/dist/client/theme-default/components/VPNavBarMenu.vue +0 -40
- package/dist/client/theme-default/components/VPNavBarMenuGroup.vue +0 -42
- package/dist/client/theme-default/components/VPNavBarMenuLink.vue +0 -53
- package/dist/client/theme-default/components/VPNavBarSocialLinks.vue +0 -27
- package/dist/client/theme-default/components/VPNavBarTranslations.vue +0 -47
- package/dist/client/theme-default/components/VPNavScreenAppearance.vue +0 -40
- package/dist/client/theme-default/components/VPNavScreenMenu.vue +0 -26
- package/dist/client/theme-default/components/VPNavScreenMenuGroup.vue +0 -112
- package/dist/client/theme-default/components/VPNavScreenMenuGroupLink.vue +0 -40
- package/dist/client/theme-default/components/VPNavScreenMenuGroupSection.vue +0 -34
- package/dist/client/theme-default/components/VPNavScreenMenuLink.vue +0 -43
- package/dist/client/theme-default/components/VPNavScreenSocialLinks.vue +0 -14
- package/dist/client/theme-default/components/VPNavScreenTranslations.vue +0 -73
- package/dist/client/theme-default/components/icons/VPIconAlignJustify.vue +0 -8
- package/dist/client/theme-default/components/icons/VPIconAlignLeft.vue +0 -8
- package/dist/client/theme-default/components/icons/VPIconAlignRight.vue +0 -8
- package/dist/client/theme-default/components/icons/VPIconArrowLeft.vue +0 -7
- package/dist/client/theme-default/components/icons/VPIconArrowRight.vue +0 -7
- package/dist/client/theme-default/components/icons/VPIconChevronDown.vue +0 -5
- package/dist/client/theme-default/components/icons/VPIconChevronLeft.vue +0 -5
- package/dist/client/theme-default/components/icons/VPIconChevronRight.vue +0 -5
- package/dist/client/theme-default/components/icons/VPIconChevronUp.vue +0 -5
- package/dist/client/theme-default/components/icons/VPIconEdit.vue +0 -6
- package/dist/client/theme-default/components/icons/VPIconHeart.vue +0 -5
- package/dist/client/theme-default/components/icons/VPIconLanguages.vue +0 -9
- package/dist/client/theme-default/components/icons/VPIconMinus.vue +0 -5
- package/dist/client/theme-default/components/icons/VPIconMinusSquare.vue +0 -6
- package/dist/client/theme-default/components/icons/VPIconMoon.vue +0 -5
- package/dist/client/theme-default/components/icons/VPIconMoreHorizontal.vue +0 -7
- package/dist/client/theme-default/components/icons/VPIconPlus.vue +0 -5
- package/dist/client/theme-default/components/icons/VPIconPlusSquare.vue +0 -6
- package/dist/client/theme-default/components/icons/VPIconSun.vue +0 -13
- package/dist/client/theme-default/composables/aside.js +0 -17
- package/dist/client/theme-default/composables/local-nav.js +0 -18
- package/dist/node/chunk-C-d2RJOW.js +0 -470
- package/dist/node/chunk-CxQfvv8o.js +0 -49065
- package/dist/node/worker_shikiResolveLang.js +0 -13
|
@@ -1,43 +1,40 @@
|
|
|
1
|
-
<script
|
|
2
|
-
import { useWindowScroll } from
|
|
3
|
-
import {
|
|
4
|
-
import { useData } from
|
|
5
|
-
import {
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import VPNavBarSearch from
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
defineEmits
|
|
20
|
-
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
const
|
|
24
|
-
const {
|
|
25
|
-
const { frontmatter } = useData()
|
|
26
|
-
|
|
27
|
-
const classes = ref<Record<string, boolean>>({})
|
|
28
|
-
|
|
29
|
-
watchPostEffect(() => {
|
|
30
|
-
classes.value = {
|
|
31
|
-
'has-sidebar': hasSidebar.value,
|
|
32
|
-
'home': frontmatter.value.layout === 'home',
|
|
33
|
-
'top': y.value === 0,
|
|
34
|
-
'screen-open': props.isScreenOpen
|
|
35
|
-
}
|
|
36
|
-
})
|
|
1
|
+
<script setup>
|
|
2
|
+
import { useWindowScroll } from "@vueuse/core";
|
|
3
|
+
import { computed } from "vue";
|
|
4
|
+
import { useData } from "../composables/data";
|
|
5
|
+
import { useLayout } from "../composables/layout";
|
|
6
|
+
import { provideNavOverflow } from "../composables/nav-overflow";
|
|
7
|
+
import VPNavAppearance from "./VPNavAppearance.vue";
|
|
8
|
+
import VPNavBarExtra from "./VPNavBarExtra.vue";
|
|
9
|
+
import VPNavBarHamburger from "./VPNavBarHamburger.vue";
|
|
10
|
+
import VPNavBarSearch from "./VPNavBarSearch.vue";
|
|
11
|
+
import VPNavBarTitle from "./VPNavBarTitle.vue";
|
|
12
|
+
import VPNavMenu from "./VPNavMenu.vue";
|
|
13
|
+
import VPNavSocialLinks from "./VPNavSocialLinks.vue";
|
|
14
|
+
import VPNavTranslations from "./VPNavTranslations.vue";
|
|
15
|
+
defineProps({ isScreenOpen: {
|
|
16
|
+
type: Boolean,
|
|
17
|
+
required: true
|
|
18
|
+
} });
|
|
19
|
+
defineEmits(["toggle-screen"]);
|
|
20
|
+
const { theme } = useData();
|
|
21
|
+
const { isHome, hasSidebar, hasLocalNav } = useLayout();
|
|
22
|
+
const { y } = useWindowScroll();
|
|
23
|
+
const isTop = computed(() => y.value <= 0);
|
|
24
|
+
const overflow = provideNavOverflow({ itemsKey: () => JSON.stringify(theme.value.nav ?? null) });
|
|
37
25
|
</script>
|
|
38
26
|
|
|
39
27
|
<template>
|
|
40
|
-
<div
|
|
28
|
+
<div
|
|
29
|
+
class="VPNavBar"
|
|
30
|
+
:class="{
|
|
31
|
+
'has-sidebar': hasSidebar,
|
|
32
|
+
'has-local-nav': !isHome && hasLocalNav,
|
|
33
|
+
'home': isHome,
|
|
34
|
+
'top': isTop,
|
|
35
|
+
'screen-open': isScreenOpen
|
|
36
|
+
}"
|
|
37
|
+
>
|
|
41
38
|
<div class="wrapper">
|
|
42
39
|
<div class="container">
|
|
43
40
|
<div class="title">
|
|
@@ -48,16 +45,23 @@ watchPostEffect(() => {
|
|
|
48
45
|
</div>
|
|
49
46
|
|
|
50
47
|
<div class="content">
|
|
51
|
-
<div
|
|
48
|
+
<div
|
|
49
|
+
class="content-body"
|
|
50
|
+
:ref="(el) => overflow.setContainerEl(el)"
|
|
51
|
+
>
|
|
52
52
|
<slot name="nav-bar-content-before" />
|
|
53
53
|
<VPNavBarSearch class="search" />
|
|
54
|
-
<
|
|
55
|
-
<
|
|
56
|
-
<
|
|
57
|
-
<
|
|
54
|
+
<VPNavMenu class="menu" />
|
|
55
|
+
<VPNavTranslations class="translations" />
|
|
56
|
+
<VPNavAppearance class="appearance" />
|
|
57
|
+
<VPNavSocialLinks class="social-links" />
|
|
58
58
|
<VPNavBarExtra class="extra" />
|
|
59
59
|
<slot name="nav-bar-content-after" />
|
|
60
|
-
<VPNavBarHamburger
|
|
60
|
+
<VPNavBarHamburger
|
|
61
|
+
class="hamburger"
|
|
62
|
+
:active="isScreenOpen"
|
|
63
|
+
@click="$emit('toggle-screen')"
|
|
64
|
+
/>
|
|
61
65
|
</div>
|
|
62
66
|
</div>
|
|
63
67
|
</div>
|
|
@@ -72,45 +76,79 @@ watchPostEffect(() => {
|
|
|
72
76
|
<style scoped>
|
|
73
77
|
.VPNavBar {
|
|
74
78
|
position: relative;
|
|
79
|
+
z-index: 1;
|
|
75
80
|
height: var(--vp-nav-height);
|
|
76
81
|
pointer-events: none;
|
|
77
82
|
white-space: nowrap;
|
|
78
|
-
|
|
83
|
+
/* inline-start edge of the background surface and divider — on doc pages the
|
|
84
|
+
sidebar column paints its own surface up to this offset */
|
|
85
|
+
--vp-nav-col-offset: 0px;
|
|
79
86
|
}
|
|
80
87
|
|
|
81
|
-
|
|
82
|
-
|
|
88
|
+
/* the single background surface — every state change below is color-only,
|
|
89
|
+
so nothing ever moves */
|
|
90
|
+
.VPNavBar::before {
|
|
91
|
+
content: "";
|
|
92
|
+
position: absolute;
|
|
93
|
+
top: 0;
|
|
94
|
+
bottom: 0;
|
|
95
|
+
inset-inline: var(--vp-nav-col-offset) 0;
|
|
96
|
+
z-index: -1;
|
|
83
97
|
background-color: var(--vp-nav-bg-color);
|
|
84
|
-
|
|
98
|
+
backdrop-filter: var(--vp-nav-backdrop-filter);
|
|
99
|
+
transition: background-color 0.25s;
|
|
85
100
|
}
|
|
86
101
|
|
|
87
|
-
|
|
88
|
-
|
|
102
|
+
/* below 60rem the bar scrolls with the page, so home stays transparent */
|
|
103
|
+
.VPNavBar.home::before {
|
|
104
|
+
background-color: transparent;
|
|
89
105
|
}
|
|
90
106
|
|
|
91
|
-
@media (min-width:
|
|
92
|
-
.VPNavBar
|
|
93
|
-
background-color:
|
|
107
|
+
@media (min-width: 60rem) {
|
|
108
|
+
.VPNavBar.home::before {
|
|
109
|
+
background-color: var(--vp-nav-bg-color);
|
|
94
110
|
}
|
|
95
111
|
|
|
96
|
-
.VPNavBar
|
|
97
|
-
background-color: var(--vp-nav-bg-color);
|
|
112
|
+
.VPNavBar.home.top::before {
|
|
113
|
+
background-color: var(--vp-nav-home-bg-color);
|
|
114
|
+
backdrop-filter: none;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.VPNavBar.has-sidebar {
|
|
118
|
+
--vp-nav-col-offset: var(--vp-sidebar-width);
|
|
98
119
|
}
|
|
99
120
|
}
|
|
100
121
|
|
|
101
|
-
|
|
102
|
-
|
|
122
|
+
@media (min-width: 90rem) {
|
|
123
|
+
.VPNavBar.has-sidebar {
|
|
124
|
+
--vp-nav-col-offset: calc(
|
|
125
|
+
(100% - var(--vp-layout-max-width)) / 2 + var(--vp-sidebar-width)
|
|
126
|
+
);
|
|
127
|
+
}
|
|
103
128
|
}
|
|
104
129
|
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
130
|
+
.VPNavBar.screen-open::before {
|
|
131
|
+
transition: none;
|
|
132
|
+
background-color: var(--vp-nav-bg-color);
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
/* between 60rem and 80rem the local nav is pinned right under the bar and
|
|
136
|
+
its surface extends up behind it, carrying the paint for both bars */
|
|
137
|
+
@media (60rem <= width < 80rem) {
|
|
138
|
+
.VPNavBar.has-local-nav::before {
|
|
139
|
+
background-color: transparent;
|
|
140
|
+
backdrop-filter: none;
|
|
108
141
|
}
|
|
109
142
|
}
|
|
110
143
|
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
144
|
+
.wrapper {
|
|
145
|
+
padding-block: 0;
|
|
146
|
+
padding-inline: 1.5rem 0.5rem;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
@media (min-width: 48rem) {
|
|
150
|
+
.wrapper {
|
|
151
|
+
padding: 0 2rem;
|
|
114
152
|
}
|
|
115
153
|
}
|
|
116
154
|
|
|
@@ -118,7 +156,7 @@ watchPostEffect(() => {
|
|
|
118
156
|
display: flex;
|
|
119
157
|
justify-content: space-between;
|
|
120
158
|
margin: 0 auto;
|
|
121
|
-
max-width: calc(var(--vp-layout-max-width) -
|
|
159
|
+
max-width: calc(var(--vp-layout-max-width) - 4rem);
|
|
122
160
|
height: var(--vp-nav-height);
|
|
123
161
|
pointer-events: none;
|
|
124
162
|
}
|
|
@@ -132,143 +170,133 @@ watchPostEffect(() => {
|
|
|
132
170
|
pointer-events: auto;
|
|
133
171
|
}
|
|
134
172
|
|
|
135
|
-
@media (min-width: 960px) {
|
|
136
|
-
.VPNavBar.has-sidebar .container {
|
|
137
|
-
max-width: 100%;
|
|
138
|
-
}
|
|
139
|
-
}
|
|
140
|
-
|
|
141
173
|
.title {
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
174
|
+
/* below the overflow engine's range the title is the only shrinkable
|
|
175
|
+
piece, truncating instead of running over search and the hamburger */
|
|
176
|
+
min-width: 0;
|
|
145
177
|
}
|
|
146
178
|
|
|
147
|
-
@media (min-width:
|
|
148
|
-
.
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
left: 0;
|
|
152
|
-
z-index: 2;
|
|
153
|
-
padding: 0 32px;
|
|
154
|
-
width: var(--vp-sidebar-width);
|
|
155
|
-
height: var(--vp-nav-height);
|
|
156
|
-
background-color: transparent;
|
|
179
|
+
@media (min-width: 48rem) {
|
|
180
|
+
.title {
|
|
181
|
+
/* the overflow engine measures fixed occupancy around a rigid title */
|
|
182
|
+
flex-shrink: 0;
|
|
157
183
|
}
|
|
158
184
|
}
|
|
159
185
|
|
|
160
|
-
@media (min-width:
|
|
186
|
+
@media (min-width: 60rem) {
|
|
187
|
+
/* reserve the sidebar column only when it is present; otherwise the title
|
|
188
|
+
keeps its natural width and search sits right next to it */
|
|
161
189
|
.VPNavBar.has-sidebar .title {
|
|
162
|
-
|
|
163
|
-
width: calc(
|
|
190
|
+
min-width: calc(var(--vp-sidebar-width) - 2rem);
|
|
191
|
+
max-width: calc(var(--vp-sidebar-width) - 2rem);
|
|
164
192
|
}
|
|
165
193
|
}
|
|
166
194
|
|
|
167
195
|
.content {
|
|
168
196
|
flex-grow: 1;
|
|
197
|
+
/* below the engine's range the controls stay rigid and the title absorbs
|
|
198
|
+
all the shrink */
|
|
199
|
+
flex-shrink: 0;
|
|
169
200
|
}
|
|
170
201
|
|
|
171
|
-
@media (min-width:
|
|
172
|
-
.
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
padding-right: 32px;
|
|
176
|
-
padding-left: var(--vp-sidebar-width);
|
|
177
|
-
}
|
|
178
|
-
}
|
|
179
|
-
|
|
180
|
-
@media (min-width: 1440px) {
|
|
181
|
-
.VPNavBar.has-sidebar .content {
|
|
182
|
-
padding-right: calc((100vw - var(--vp-layout-max-width)) / 2 + 32px);
|
|
183
|
-
padding-left: calc((100vw - var(--vp-layout-max-width)) / 2 + var(--vp-sidebar-width));
|
|
202
|
+
@media (min-width: 48rem) {
|
|
203
|
+
.content {
|
|
204
|
+
flex-shrink: 1;
|
|
205
|
+
min-width: 0;
|
|
184
206
|
}
|
|
185
207
|
}
|
|
186
208
|
|
|
187
209
|
.content-body {
|
|
210
|
+
position: relative;
|
|
188
211
|
display: flex;
|
|
189
212
|
justify-content: flex-end;
|
|
190
213
|
align-items: center;
|
|
191
214
|
height: var(--vp-nav-height);
|
|
192
|
-
transition: background-color 0.5s;
|
|
193
215
|
}
|
|
194
216
|
|
|
195
|
-
@media (min-width:
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
.VPNavBar:not(.has-sidebar):not(.home.top) .content-body {
|
|
202
|
-
background-color: transparent;
|
|
217
|
+
@media (min-width: 48rem) {
|
|
218
|
+
/* keeps search on the title's side when there is no nav menu to grow
|
|
219
|
+
into the middle; with a menu present its flex-grow wins and this
|
|
220
|
+
margin resolves to zero */
|
|
221
|
+
.content-body > .search {
|
|
222
|
+
margin-inline-end: auto;
|
|
203
223
|
}
|
|
204
224
|
}
|
|
205
225
|
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
226
|
+
/* collapsed into the `⋯` menu — kept mounted (hidden, out of the a11y tree
|
|
227
|
+
and tab order) so its natural width stays measurable */
|
|
228
|
+
.content-body > .collapsed {
|
|
229
|
+
visibility: hidden;
|
|
230
|
+
position: absolute;
|
|
231
|
+
top: 0;
|
|
232
|
+
inset-inline-start: 0;
|
|
233
|
+
max-width: 100%;
|
|
234
|
+
overflow: hidden;
|
|
210
235
|
}
|
|
211
236
|
|
|
212
|
-
|
|
213
|
-
.menu + .appearance::before
|
|
214
|
-
|
|
215
|
-
.translations + .appearance::before,
|
|
216
|
-
.appearance + .social-links::before {
|
|
217
|
-
margin-right: 8px;
|
|
218
|
-
margin-left: 8px;
|
|
237
|
+
/* separators between whichever cluster units are currently in the bar */
|
|
238
|
+
.content-body > :where(.menu, .translations, .appearance, .social-links) + :where(.translations, .appearance, .social-links)::before {
|
|
239
|
+
margin-inline: 0.5rem;
|
|
219
240
|
width: 1px;
|
|
220
|
-
height:
|
|
241
|
+
height: 1.5rem;
|
|
221
242
|
background-color: var(--vp-c-divider);
|
|
222
243
|
content: "";
|
|
223
244
|
}
|
|
224
245
|
|
|
225
|
-
.menu + .appearance::before
|
|
226
|
-
|
|
227
|
-
margin-right: 16px;
|
|
246
|
+
.content-body > :where(.menu, .translations) + .appearance::before {
|
|
247
|
+
margin-inline-end: 1rem;
|
|
228
248
|
}
|
|
229
249
|
|
|
230
|
-
.appearance + .social-links::before {
|
|
231
|
-
margin-
|
|
250
|
+
.content-body > .appearance + .social-links::before {
|
|
251
|
+
margin-inline-start: 1rem;
|
|
232
252
|
}
|
|
233
253
|
|
|
234
254
|
.social-links {
|
|
235
|
-
margin-
|
|
255
|
+
margin-inline-end: -0.5rem;
|
|
236
256
|
}
|
|
237
257
|
|
|
238
258
|
.divider {
|
|
259
|
+
position: relative;
|
|
260
|
+
/* above the background surface, below the bar's content — an open flyout
|
|
261
|
+
panel overlaps the bar's bottom edge and must cover the rule */
|
|
262
|
+
z-index: -1;
|
|
263
|
+
/* own layer — Safari otherwise sorts the rule behind the sticky local
|
|
264
|
+
nav's surface in their overlapping row (#5399) */
|
|
265
|
+
transform: translateZ(0);
|
|
239
266
|
width: 100%;
|
|
240
267
|
height: 1px;
|
|
268
|
+
padding-inline-start: var(--vp-nav-col-offset);
|
|
241
269
|
}
|
|
242
270
|
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
271
|
+
/* the sidebar-column segment of the bottom rule — inset from the column
|
|
272
|
+
edges so it lines up with the sidebar's own group dividers */
|
|
273
|
+
.VPNavBar.has-sidebar .divider::before {
|
|
274
|
+
content: "";
|
|
275
|
+
position: absolute;
|
|
276
|
+
top: 0;
|
|
277
|
+
inset-inline-start: calc(var(--vp-nav-col-offset) - var(--vp-sidebar-width) + 2rem);
|
|
278
|
+
width: calc(var(--vp-sidebar-width) - 4rem);
|
|
279
|
+
height: 1px;
|
|
280
|
+
background-color: var(--vp-c-divider);
|
|
253
281
|
}
|
|
254
282
|
|
|
255
283
|
.divider-line {
|
|
256
284
|
width: 100%;
|
|
257
285
|
height: 1px;
|
|
258
|
-
transition: background-color 0.
|
|
286
|
+
transition: background-color 0.25s;
|
|
259
287
|
}
|
|
260
288
|
|
|
261
289
|
.VPNavBar:not(.home) .divider-line {
|
|
262
|
-
background-color: var(--vp-
|
|
290
|
+
background-color: var(--vp-nav-divider-color);
|
|
263
291
|
}
|
|
264
292
|
|
|
265
|
-
@media (min-width:
|
|
293
|
+
@media (min-width: 60rem) {
|
|
266
294
|
.VPNavBar:not(.home.top) .divider-line {
|
|
267
|
-
background-color: var(--vp-
|
|
295
|
+
background-color: var(--vp-nav-divider-color);
|
|
268
296
|
}
|
|
297
|
+
}
|
|
269
298
|
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
}
|
|
299
|
+
.VPNavBar.screen-open .divider-line {
|
|
300
|
+
background-color: var(--vp-c-divider);
|
|
273
301
|
}
|
|
274
302
|
</style>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
declare const _default: typeof __VLS_export;
|
|
3
|
+
export default _default;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<button type="button" class="VPNavBarAskAiButton">
|
|
3
|
+
<span class="vpi-sparkles" aria-hidden="true"></span>
|
|
4
|
+
</button>
|
|
5
|
+
</template>
|
|
6
|
+
|
|
7
|
+
<style scoped>
|
|
8
|
+
.VPNavBarAskAiButton {
|
|
9
|
+
display: flex;
|
|
10
|
+
align-items: center;
|
|
11
|
+
height: var(--vp-nav-height);
|
|
12
|
+
padding: 0.5rem 0.875rem;
|
|
13
|
+
font-size: 1.25rem;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
@media (min-width: 48rem) {
|
|
17
|
+
.VPNavBarAskAiButton {
|
|
18
|
+
height: auto;
|
|
19
|
+
padding: 0.71875rem;
|
|
20
|
+
transition: color 0.3s ease;
|
|
21
|
+
background-color: var(--vp-c-bg-alt);
|
|
22
|
+
border-radius: 0.5rem;
|
|
23
|
+
font-size: 0.9375rem;
|
|
24
|
+
color: var(--vp-c-text-2);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.VPNavBarAskAiButton:hover {
|
|
28
|
+
color: var(--vp-c-brand-1);
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
</style>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
declare const _default: typeof __VLS_export;
|
|
3
|
+
export default _default;
|
|
@@ -1,59 +1,60 @@
|
|
|
1
|
-
<script
|
|
2
|
-
import { computed } from
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
const
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
)
|
|
1
|
+
<script setup>
|
|
2
|
+
import { computed } from "vue";
|
|
3
|
+
import { useData } from "../composables/data";
|
|
4
|
+
import { useLangs } from "../composables/langs";
|
|
5
|
+
import { useAppearanceSwitch } from "../composables/nav";
|
|
6
|
+
import { useNavOverflow } from "../composables/nav-overflow";
|
|
7
|
+
import VPFlyout from "./VPFlyout.vue";
|
|
8
|
+
import VPMenuGroup from "./VPMenuGroup.vue";
|
|
9
|
+
import VPMenuLink from "./VPMenuLink.vue";
|
|
10
|
+
import VPNavAppearance from "./VPNavAppearance.vue";
|
|
11
|
+
import VPNavTranslations from "./VPNavTranslations.vue";
|
|
12
|
+
import VPSocialLinks from "./VPSocialLinks.vue";
|
|
13
|
+
const { theme } = useData();
|
|
14
|
+
const { localeLinks, currentLang } = useLangs({ linkToCorrespondingPage: true });
|
|
15
|
+
const hasAppearanceSwitch = useAppearanceSwitch();
|
|
16
|
+
const overflow = useNavOverflow();
|
|
17
|
+
// nav items the priority+ engine pushed out of the bar (contiguous suffix)
|
|
18
|
+
const overflowItems = computed(() => {
|
|
19
|
+
const count = overflow?.state.visibleItemCount ?? Infinity;
|
|
20
|
+
if (count === Infinity || !theme.value.nav) return [];
|
|
21
|
+
return theme.value.nav.slice(count);
|
|
22
|
+
});
|
|
23
|
+
const showTranslations = computed(() => !!(localeLinks.value.length && currentLang.value.label) && !(overflow?.state.translations ?? true));
|
|
24
|
+
const showAppearance = computed(() => hasAppearanceSwitch.value && !(overflow?.state.appearance ?? true));
|
|
25
|
+
const showSocialLinks = computed(() => !!theme.value.socialLinks && !(overflow?.state.socialLinks ?? true));
|
|
26
|
+
const hasContent = computed(() => overflowItems.value.length > 0 || showTranslations.value || showAppearance.value || showSocialLinks.value);
|
|
19
27
|
</script>
|
|
20
28
|
|
|
21
29
|
<template>
|
|
22
30
|
<VPFlyout
|
|
23
|
-
v-if="
|
|
31
|
+
v-if="hasContent"
|
|
24
32
|
class="VPNavBarExtra"
|
|
25
|
-
label="
|
|
33
|
+
:label="theme.extraMenuLabel || 'More options'"
|
|
34
|
+
:ref="(inst) => overflow?.setExtraEl(inst?.$el ?? null)"
|
|
26
35
|
>
|
|
27
|
-
<
|
|
28
|
-
v-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
36
|
+
<ul v-if="overflowItems.length" class="group overflow-items">
|
|
37
|
+
<template v-for="item in overflowItems" :key="JSON.stringify(item)">
|
|
38
|
+
<VPMenuLink v-if="'link' in item" :item />
|
|
39
|
+
<!-- a menu panel is a vertical list context — components must
|
|
40
|
+
render a flat list here, not a nested floating flyout -->
|
|
41
|
+
<component
|
|
42
|
+
v-else-if="'component' in item"
|
|
43
|
+
:is="item.component"
|
|
44
|
+
v-bind="item.props"
|
|
45
|
+
menu
|
|
46
|
+
/>
|
|
47
|
+
<VPMenuGroup v-else :text="item.text" :items="item.items" />
|
|
35
48
|
</template>
|
|
36
|
-
</
|
|
49
|
+
</ul>
|
|
37
50
|
|
|
38
|
-
<
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
site.appearance !== 'force-auto'
|
|
43
|
-
"
|
|
44
|
-
class="group"
|
|
45
|
-
>
|
|
46
|
-
<div class="item appearance">
|
|
47
|
-
<p class="label">
|
|
48
|
-
{{ theme.darkModeSwitchLabel || 'Appearance' }}
|
|
49
|
-
</p>
|
|
50
|
-
<div class="appearance-action">
|
|
51
|
-
<VPSwitchAppearance />
|
|
52
|
-
</div>
|
|
53
|
-
</div>
|
|
51
|
+
<VPNavTranslations v-if="showTranslations" menu />
|
|
52
|
+
|
|
53
|
+
<div v-if="showAppearance" class="group">
|
|
54
|
+
<VPNavAppearance row />
|
|
54
55
|
</div>
|
|
55
56
|
|
|
56
|
-
<div v-if="
|
|
57
|
+
<div v-if="showSocialLinks" class="group">
|
|
57
58
|
<div class="item social-links">
|
|
58
59
|
<VPSocialLinks class="social-links-list" :links="theme.socialLinks" />
|
|
59
60
|
</div>
|
|
@@ -64,45 +65,22 @@ const hasExtraContent = computed(
|
|
|
64
65
|
<style scoped>
|
|
65
66
|
.VPNavBarExtra {
|
|
66
67
|
display: none;
|
|
67
|
-
margin-
|
|
68
|
+
margin-inline-end: -0.75rem;
|
|
68
69
|
}
|
|
69
70
|
|
|
70
|
-
@media (min-width:
|
|
71
|
+
@media (min-width: 48rem) {
|
|
71
72
|
.VPNavBarExtra {
|
|
72
73
|
display: block;
|
|
73
74
|
}
|
|
74
75
|
}
|
|
75
76
|
|
|
76
|
-
@media (min-width: 1280px) {
|
|
77
|
-
.VPNavBarExtra {
|
|
78
|
-
display: none;
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
.trans-title {
|
|
83
|
-
padding: 0 24px 0 12px;
|
|
84
|
-
line-height: 32px;
|
|
85
|
-
font-size: 14px;
|
|
86
|
-
font-weight: 700;
|
|
87
|
-
color: var(--vp-c-text-1);
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
.item.appearance,
|
|
91
77
|
.item.social-links {
|
|
92
78
|
display: flex;
|
|
93
79
|
align-items: center;
|
|
94
|
-
padding: 0
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
.item.appearance {
|
|
98
|
-
min-width: 176px;
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
.appearance-action {
|
|
102
|
-
margin-right: -2px;
|
|
80
|
+
padding: 0 0.75rem;
|
|
103
81
|
}
|
|
104
82
|
|
|
105
83
|
.social-links-list {
|
|
106
|
-
margin: -
|
|
84
|
+
margin: -0.25rem -0.5rem;
|
|
107
85
|
}
|
|
108
86
|
</style>
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
active: boolean;
|
|
3
|
+
};
|
|
4
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
5
|
+
click: () => any;
|
|
6
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
7
|
+
onClick?: (() => any) | undefined;
|
|
8
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
9
|
+
declare const _default: typeof __VLS_export;
|
|
10
|
+
export default _default;
|