Skip to content

Commit a95a427

Browse files
committed
feat: cleanup file tree in sidebar
1 parent 8a99f9b commit a95a427

File tree

6 files changed

+12
-9
lines changed

6 files changed

+12
-9
lines changed

.vitepress/theme/style.css

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.vitepress/theme/vitepress-theme.d.ts

+2
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,10 @@ export declare type NSSidebarGroup = DefaultTheme.SidebarItem & {
1111

1212
export declare type NSSidebarItem = DefaultTheme.SidebarItem & {
1313
icon?: string;
14+
hidden?: boolean;
1415
collapsible?: boolean;
1516
hideChildren?: boolean;
17+
type?: string;
1618
};
1719

1820
export declare type NSThemeConfig = DefaultTheme.Config & {

.vitepress/theme/vitepress-theme.mjs

+3-3
Original file line numberDiff line numberDiff line change
@@ -3926,7 +3926,7 @@ const ar = /* @__PURE__ */ jt($p, [["render", Cp]]), Ap = {
39263926
h("div", Dp, [
39273927
P(u) ? (g(), ue(Mn(P(u)), {
39283928
key: 0,
3929-
class: "mr-2"
3929+
class: "relative -top-0.5 mr-1.5 h-5 w-5"
39303930
})) : K("", !0),
39313931
h("div", {
39323932
innerHTML: P(i),
@@ -3948,12 +3948,12 @@ const ar = /* @__PURE__ */ jt($p, [["render", Cp]]), Ap = {
39483948
P(s) ? qt((g(), b("ul", {
39493949
key: 2,
39503950
class: te({
3951-
"border-l-2 border-slate-200 dark:border-slate-800": e.depth === 0
3951+
"border-l-2 border-slate-200 dark:border-slate-800": e.depth === 0 && e.item.type !== "filetree"
39523952
})
39533953
}, [
39543954
(g(!0), b(z, null, ne(P(s), (S) => (g(), ue(y, {
39553955
item: S,
3956-
depth: e.depth + 1
3956+
depth: e.item.type === "filetree" ? 0 : e.depth + 1
39573957
}, null, 8, ["item", "depth"]))), 256))
39583958
], 2)), [
39593959
[dr, !c.value]

content/project-structure/src/app-css-scss.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
title: The app.css or app.scss
2+
title: app.css (or app.scss)
33
contributors:
44
- rigor789
55
---
+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: main.(js|ts)
2+
title: main.js (or main.ts)
33
contributors:
44
- rigor789
55
---
66

7-
The `main.(js|ts)` file is the entry point to your application. You can use this file to initialize plugins, your app services and initial data.
7+
The `main.js` (or `main.ts`) file is the entry point to your application. You can use this file to initialize plugins, your app services and initial data.

content/sidebar.ts

+3-2
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ export default [
4848
},
4949
{
5050
text: 'Project Structure',
51+
type: 'filetree',
5152
items: [
5253
{
5354
text: 'App_Resources/',
@@ -66,12 +67,12 @@ export default [
6667
icon: 'folder',
6768
},
6869
{
69-
text: 'app.(css|scss)',
70+
text: 'app.cssscss',
7071
link: '/project-structure/src/app-css-scss',
7172
icon: 'file',
7273
},
7374
{
74-
text: 'main.(js|ts)',
75+
text: 'main.js•ts',
7576
link: '/project-structure/src/main-js-ts',
7677
icon: 'file',
7778
},

0 commit comments

Comments
 (0)