Skip to content

Commit 37eec0e

Browse files
committed
docs: update layout
1 parent b8756f2 commit 37eec0e

File tree

3 files changed

+12
-3
lines changed

3 files changed

+12
-3
lines changed

packages/docs/.vuepress/src/client/components/ScssDocs.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ export default defineComponent({
2222
}
2323
2424
const files = import.meta.glob(`../../../../../../node_modules/@coreui/coreui/scss/**/*.scss`, {
25-
as: 'raw',
25+
query: '?raw',
2626
eager: true,
2727
})
2828
const file = files[`../../../../../../node_modules/@coreui/coreui/scss/${props.file}`]

packages/docs/.vuepress/src/client/layouts/Layout.vue

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,15 @@
1313
<main class="docs-main order-1">
1414
<div class="docs-intro ps-lg-4">
1515
<Banner />
16-
<h1 className="docs-title" id="content">{{ title }}</h1>
17-
<p class="docs-lead">{{ description }}</p>
16+
<div v-if="name && name !== title" class="d-flex flex-column">
17+
<h1 class="order-2 h5 mb-4 text-body-secondary" id="content">
18+
{{ title }}
19+
</h1>
20+
<h2 class="docs-title order-1 h1">{{ name }}</h2>
21+
</div>
22+
<h1 v-else class="docs-title" id="content">
23+
{{ title }}
24+
</h1>
1825
<Ads />
1926
<OtherFrameworks />
2027
</div>
@@ -56,6 +63,7 @@ const scrollPromise = useScrollPromise()
5663
const onBeforeEnter = scrollPromise.resolve
5764
const onBeforeLeave = scrollPromise.pending
5865
66+
const name = frontmatter.value.name
5967
const title = frontmatter.value.title
6068
const description = frontmatter.value.description
6169

packages/docs/.vuepress/src/shared/page.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ export interface DefaultThemePageFrontmatter {
99
home?: boolean
1010
navbar?: boolean
1111
pageClass?: string
12+
name?: string
1213
}
1314

1415
export interface DefaultThemeHomePageFrontmatter

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy