Skip to content

Commit 87592f6

Browse files
committed
feat: reorganized documentation to be more targeted
1 parent da4a460 commit 87592f6

File tree

20 files changed

+1423
-217
lines changed

20 files changed

+1423
-217
lines changed

.vitepress/config/sidebar.ts

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,22 +4,22 @@ const sidebar = [
44
// collapsible: true,
55
// collapsed: true,
66
items: [
7-
{ text: 'Installation', link: '/docs/installation' },
7+
// { text: 'Installation', link: '/docs/installation' },
8+
{ text: 'Leaf CLI', link: '/docs/cli/' },
89
{ text: 'Migration Guide', link: '/docs/migrating' },
910
// { text: 'Functional Mode', link: '/docs/config/functional-mode' },
1011
{ text: 'Modules', link: '/docs/modules' },
1112
],
1213
},
13-
{
14-
text: 'Leaf CLI',
15-
// collapsible: true,
16-
// collapsed: true,
17-
items: [
18-
{ text: 'CLI Intro', link: '/docs/cli/' },
19-
{ text: 'Creating apps', link: '/docs/cli/creating-an-app' },
20-
{ text: 'Managing apps', link: '/docs/cli/managing-apps' },
21-
],
22-
},
14+
// {
15+
// text: 'Leaf CLI',
16+
// // collapsible: true,
17+
// // collapsed: true,
18+
// items: [
19+
// { text: 'Creating apps', link: '/docs/cli/creating-an-app' },
20+
// { text: 'Managing apps', link: '/docs/cli/managing-apps' },
21+
// ],
22+
// },
2323
{
2424
text: 'Routing',
2525
// collapsible: true,

.vitepress/theme/components/shared/SidebarLinks.vue

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@ const links = [
77
{
88
name: 'Documentation',
99
href: '/docs/',
10-
color: 'text-sky-500 dark:text-sky-400 group-hover:shadow-sky-200 dark:group-hover:bg-sky-500 dark:bg-sky-500 dark:highlight-white/10',
10+
color: 'group-hover:shadow-[var(--vp-c-brand)] dark:group-hover:bg-[var(--vp-c-brand)] dark:bg-[var(--vp-c-brand)] dark:highlight-white/10',
1111
icon: `<svg class="h-6 w-6" viewBox="0 0 24 24" fill="none">
1212
<path fill-rule="evenodd" clip-rule="evenodd"
1313
d="M8.5 7c1.093 0 2.117.27 3 .743V17a6.345 6.345 0 0 0-3-.743c-1.093 0-2.617.27-3.5.743V7.743C5.883 7.27 7.407 7 8.5 7Z"
14-
class="fill-sky-200 group-hover:fill-sky-500 dark:fill-sky-300 dark:group-hover:fill-sky-300"></path>
14+
class="fill-[var(--vp-c-brand)] group-hover:fill-green-500 dark:fill-[var(--vp-c-brand)] dark:group-hover:fill-[var(--vp-c-brand)]"></path>
1515
<path fill-rule="evenodd" clip-rule="evenodd"
1616
d="M15.5 7c1.093 0 2.617.27 3.5.743V17c-.883-.473-2.407-.743-3.5-.743s-2.117.27-3 .743V7.743a6.344 6.344 0 0 1 3-.743Z"
17-
class="fill-sky-400 group-hover:fill-sky-500 dark:fill-sky-200 dark:group-hover:fill-sky-200"></path>
17+
class="fill-green-400 group-hover:fill-green-500 dark:fill-[var(--vp-c-brand)] dark:group-hover:fill-[var(--vp-c-brand)]"></path>
1818
</svg>`
1919
},
2020
{
@@ -33,8 +33,8 @@ const links = [
3333
</svg>`
3434
},
3535
{
36-
name: 'Templates',
37-
href: 'https://tailwindui.com/templates?ref=sidebar',
36+
name: 'Learn',
37+
href: '/learn/',
3838
color: 'group-hover:shadow-fuchsia-200 dark:group-hover:bg-fuchsia-600',
3939
icon: `<svg class="h-6 w-6" viewBox="0 0 24 24" fill="none">
4040
<path fill-rule="evenodd" clip-rule="evenodd"
@@ -111,10 +111,11 @@ const links = [
111111
<template>
112112
<ul class="pt-4">
113113
<li v-for="link in links" :key="link.name">
114-
<a class="group flex items-center lg:text-sm lg:leading-6 mb-4 font-semibold text-sky-500 dark:text-sky-400"
115-
href="/docs/installation">
114+
<a class="group flex items-center lg:text-sm lg:leading-6 mb-4 font-semibold"
115+
:class="pathname.startsWith(link.href) ? 'text-[var(--vp-c-brand)]' : ''"
116+
:href="link.href">
116117
<div
117-
class="mr-4 rounded-md ring-1 ring-slate-900/5 shadow-sm group-hover:shadow group-hover:ring-slate-900/10 dark:ring-0 dark:shadow-none dark:group-hover:shadow-none dark:group-hover:highlight-white/10 group-hover:shadow-sky-200 dark:group-hover:bg-sky-500 dark:bg-sky-500 dark:highlight-white/10"
118+
class="mr-4 rounded-md ring-1 ring-slate-900/5 shadow-sm group-hover:shadow group-hover:ring-slate-900/10 dark:ring-0 dark:shadow-none dark:group-hover:shadow-none dark:group-hover:highlight-white/10 group-hover:shadow-sky-200 dark:group-hover:bg-black dark:bg-[var(--vp-c-bg)] dark:highlight-white/10"
118119
v-html="link.icon">
119120
</div>
120121
{{ link.name }}

src/codelabs/index.md

Lines changed: 0 additions & 33 deletions
This file was deleted.

src/docs/cli/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ Leaf CLI is a command line tool that helps you create, manage and deploy Leaf ap
2121
videoUrl="https://www.youtube.com/embed/jqkear8zue8"
2222
/>
2323

24-
*This guide will assume that your system meets all the [technical requirements](/docs/installation#technical-requirements).*
24+
*This guide will assume that your system meets all the [technical requirements](/docs/#creating-a-new-app).*
2525

2626
You can verify that composer is installed by running:
2727

0 commit comments

Comments
 (0)