rizzo-css 0.0.84 → 0.0.86
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 +1 -1
- package/bin/rizzo-css.js +5 -1
- package/package.json +1 -1
- package/scaffold/landing/favicon.svg +18 -0
- package/scaffold/landing/index.html +20 -0
- package/scaffold/minimal/favicon.svg +18 -0
- package/scaffold/minimal/index.html +17 -0
- package/scaffold/react/base/index.html +1 -0
- package/scaffold/react/base/package.json +1 -1
- package/scaffold/react/base/public/favicon.svg +18 -0
- package/scaffold/react/variants/full/package.json +1 -1
- package/scaffold/react/variants/full/src/App.tsx +11 -1
- package/scaffold/react/variants/full/src/config/componentCategories.ts +2 -2
- package/scaffold/react/variants/full/src/index.css +113 -0
- package/scaffold/react/variants/full/src/layouts/DocsLayout.tsx +29 -1
- package/scaffold/react/variants/full/src/views/DocsComponents.tsx +0 -1
- package/scaffold/react/variants/full/src/views/DocsGettingStarted.tsx +0 -1
- package/scaffold/react/variants/full/src/views/DocsIndex.tsx +0 -1
- package/scaffold/shared/favicon.svg +18 -0
- package/scaffold/svelte/base/src/app.html +1 -0
- package/scaffold/svelte/base/src/routes/+layout.svelte +10 -1
- package/scaffold/svelte/base/static/favicon.svg +18 -0
- package/scaffold/svelte/variants/full/README-RIZZO.md +4 -0
- package/scaffold/svelte/variants/full/src/app.html +1 -0
- package/scaffold/svelte/variants/full/src/config/componentCategories.ts +2 -2
- package/scaffold/svelte/variants/full/src/routes/+layout.svelte +15 -2
- package/scaffold/svelte/variants/full/src/routes/docs/+layout.svelte +117 -3
- package/scaffold/svelte/variants/full/src/routes/docs/+layout.ts +3 -0
- package/scaffold/svelte/variants/full/src/routes/docs/+page.svelte +0 -1
- package/scaffold/svelte/variants/full/src/routes/docs/+page.ts +7 -0
- package/scaffold/svelte/variants/full/src/routes/docs/components/+page.svelte +0 -5
- package/scaffold/svelte/variants/full/src/routes/docs/components/+page.ts +6 -0
- package/scaffold/svelte/variants/full/src/routes/docs/getting-started/+page.svelte +0 -5
- package/scaffold/svelte/variants/full/src/routes/docs/getting-started/+page.ts +6 -0
- package/scaffold/svelte/variants/full/src/routes/docs/overview/+page.ts +6 -0
- package/scaffold/svelte/variants/full/src/routes/themes/+page.svelte +0 -7
- package/scaffold/svelte/variants/full/static/favicon.svg +18 -0
- package/scaffold/vanilla/README-RIZZO.md +1 -1
- package/scaffold/vanilla/components/accordion.html +23 -0
- package/scaffold/vanilla/components/alert-dialog.html +23 -0
- package/scaffold/vanilla/components/alert.html +23 -0
- package/scaffold/vanilla/components/aspect-ratio.html +23 -0
- package/scaffold/vanilla/components/avatar.html +23 -0
- package/scaffold/vanilla/components/back-to-top.html +23 -0
- package/scaffold/vanilla/components/badge.html +23 -0
- package/scaffold/vanilla/components/breadcrumb.html +23 -0
- package/scaffold/vanilla/components/button-group.html +23 -0
- package/scaffold/vanilla/components/button.html +23 -0
- package/scaffold/vanilla/components/calendar.html +23 -0
- package/scaffold/vanilla/components/cards.html +23 -0
- package/scaffold/vanilla/components/carousel.html +23 -0
- package/scaffold/vanilla/components/chart.html +23 -0
- package/scaffold/vanilla/components/collapsible.html +23 -0
- package/scaffold/vanilla/components/command.html +23 -0
- package/scaffold/vanilla/components/context-menu.html +23 -0
- package/scaffold/vanilla/components/copy-to-clipboard.html +23 -0
- package/scaffold/vanilla/components/dashboard.html +23 -0
- package/scaffold/vanilla/components/direction.html +23 -0
- package/scaffold/vanilla/components/divider.html +23 -0
- package/scaffold/vanilla/components/docs-sidebar.html +23 -0
- package/scaffold/vanilla/components/dropdown.html +23 -0
- package/scaffold/vanilla/components/empty.html +23 -0
- package/scaffold/vanilla/components/font-switcher.html +23 -0
- package/scaffold/vanilla/components/footer.html +23 -0
- package/scaffold/vanilla/components/forms.html +23 -0
- package/scaffold/vanilla/components/hover-card.html +23 -0
- package/scaffold/vanilla/components/icons.html +23 -0
- package/scaffold/vanilla/components/index.html +23 -0
- package/scaffold/vanilla/components/input-group.html +23 -0
- package/scaffold/vanilla/components/input-otp.html +23 -0
- package/scaffold/vanilla/components/kbd.html +23 -0
- package/scaffold/vanilla/components/label.html +23 -0
- package/scaffold/vanilla/components/menubar.html +23 -0
- package/scaffold/vanilla/components/modal.html +23 -0
- package/scaffold/vanilla/components/navbar.html +23 -0
- package/scaffold/vanilla/components/pagination.html +23 -0
- package/scaffold/vanilla/components/popover.html +23 -0
- package/scaffold/vanilla/components/progress-bar.html +23 -0
- package/scaffold/vanilla/components/range-calendar.html +23 -0
- package/scaffold/vanilla/components/resizable.html +23 -0
- package/scaffold/vanilla/components/scroll-area.html +23 -0
- package/scaffold/vanilla/components/search.html +23 -0
- package/scaffold/vanilla/components/separator.html +23 -0
- package/scaffold/vanilla/components/settings.html +23 -0
- package/scaffold/vanilla/components/sheet.html +23 -0
- package/scaffold/vanilla/components/skeleton.html +23 -0
- package/scaffold/vanilla/components/slider.html +23 -0
- package/scaffold/vanilla/components/sound-effects.html +23 -0
- package/scaffold/vanilla/components/spinner.html +23 -0
- package/scaffold/vanilla/components/switch.html +23 -0
- package/scaffold/vanilla/components/table.html +23 -0
- package/scaffold/vanilla/components/tabs.html +23 -0
- package/scaffold/vanilla/components/theme-switcher.html +23 -0
- package/scaffold/vanilla/components/toast.html +23 -0
- package/scaffold/vanilla/components/toggle-group.html +23 -0
- package/scaffold/vanilla/components/toggle.html +23 -0
- package/scaffold/vanilla/components/tooltip.html +23 -0
- package/scaffold/vanilla/favicon.svg +18 -0
- package/scaffold/vanilla/index.html +23 -0
- package/scaffold/vanilla/variants/dashboard/favicon.svg +18 -0
- package/scaffold/vanilla/variants/dashboard/index.html +1 -0
- package/scaffold/vanilla/variants/docs/favicon.svg +18 -0
- package/scaffold/vanilla/variants/docs/index.html +1 -0
- package/scaffold/vanilla/variants/full/favicon.svg +18 -0
- package/scaffold/vanilla/variants/full/index.html +19 -0
- package/scaffold/vue/Footer.vue +43 -4
- package/scaffold/vue/base/index.html +1 -0
- package/scaffold/vue/base/package.json +1 -1
- package/scaffold/vue/base/public/favicon.svg +18 -0
- package/scaffold/vue/variants/full/package.json +1 -1
- package/scaffold/vue/variants/full/src/App.vue +13 -1
- package/scaffold/vue/variants/full/src/config/componentCategories.ts +2 -2
- package/scaffold/vue/variants/full/src/layouts/DocsLayout.vue +116 -2
- package/scaffold/vue/variants/full/src/router/index.ts +31 -4
- package/scaffold/vue/variants/full/src/views/DocsComponents.vue +0 -1
- package/scaffold/vue/variants/full/src/views/DocsGettingStarted.vue +0 -1
- package/scaffold/vue/variants/full/src/views/DocsIndex.vue +0 -1
package/README.md
CHANGED
|
@@ -72,7 +72,7 @@ import 'rizzo-css';
|
|
|
72
72
|
**Without a bundler (plain HTML):** Use a CDN. Both unpkg and jsDelivr resolve the package root to the built CSS (via the `unpkg` / `jsdelivr` fields in this package). For reliability or to pin a version, use the explicit path:
|
|
73
73
|
|
|
74
74
|
```html
|
|
75
|
-
<!-- unpkg (pin version: replace @latest with @0.0.
|
|
75
|
+
<!-- unpkg (pin version: replace @latest with @0.0.86 or any version) -->
|
|
76
76
|
<link rel="stylesheet" href="https://unpkg.com/rizzo-css@latest/dist/rizzo.min.css" />
|
|
77
77
|
|
|
78
78
|
<!-- or jsDelivr -->
|
package/bin/rizzo-css.js
CHANGED
|
@@ -737,6 +737,9 @@ function hasFullVariant(framework) {
|
|
|
737
737
|
return getVariantDir(framework, 'full') !== null;
|
|
738
738
|
}
|
|
739
739
|
|
|
740
|
+
/** Components imported by Svelte full variant routes (themes, layout, docs, blocks). Ensures these are always copied so Vite dep-scan does not fail. */
|
|
741
|
+
const SVELTE_FULL_VARIANT_REQUIRED = ['ThemeIcon', 'ThemeSwitcher', 'Card', 'CopyToClipboard', 'Navbar', 'Footer', 'Settings', 'BackToTop', 'DocsSidebar'];
|
|
742
|
+
|
|
740
743
|
/** Copy variant overlay onto project (after base). Applies replacements. Overwrites matching paths. */
|
|
741
744
|
function copyVariantOverlay(projectDir, framework, variation, replacements) {
|
|
742
745
|
const variantDir = getVariantDir(framework, variation);
|
|
@@ -2759,7 +2762,8 @@ async function cmdInit(argv) {
|
|
|
2759
2762
|
const fullDir = getVariantDir('svelte', 'full');
|
|
2760
2763
|
copyDirRecursiveWithReplacements(fullDir, projectDir, replacements);
|
|
2761
2764
|
copyRizzoCssAndFontsForSvelte(projectDir, cssSource);
|
|
2762
|
-
|
|
2765
|
+
const svelteFullComponents = [...new Set([...componentsToCopy, ...SVELTE_FULL_VARIANT_REQUIRED])];
|
|
2766
|
+
copySvelteComponents(projectDir, expandWithDeps('svelte', svelteFullComponents));
|
|
2763
2767
|
cssTarget = join(projectDir, 'static', 'css', 'rizzo.min.css');
|
|
2764
2768
|
if (existsSync(cssTarget) && statSync(cssTarget).size < 5000) {
|
|
2765
2769
|
console.warn('\nWarning: rizzo.min.css is very small. From repo root run: pnpm build:css');
|
package/package.json
CHANGED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 128 128">
|
|
2
|
+
<g>
|
|
3
|
+
<path d="M47.7 107.1c-5.5-5-7.2-15.7-4.9-23.4 4 4.9 9.6 6.4 15.4 7.3 8.9 1.3 17.6.8 25.9-3.2l2.8-1.7a18 18 0 0 1-7.2 20l-5.5 3.8c-5.6 3.8-7.2 8.2-5 14.7l.2.7a14 14 0 0 1-6.6-5.6 15.8 15.8 0 0 1-2.6-8.6c0-1.5 0-3-.2-4.5-.5-3.7-2.2-5.3-5.5-5.4-3.3-.1-5.9 2-6.6 5.2l-.2.7ZM16 82.4s16.5-8 33-8l12.4-38.3c.5-2 1.8-3.2 3.3-3.2 1.6 0 3 1.3 3.4 3.2l12.4 38.3c19.6 0 33 8 33 8l-28-76c-.8-2.3-2.2-3.7-4-3.7H48c-1.8 0-3.1 1.4-4 3.7l-28 76Z"/>
|
|
4
|
+
</g>
|
|
5
|
+
<path fill="url(#a)" d="M47.7 107.1c-5.5-5-7.2-15.7-4.9-23.4 4 4.9 9.6 6.4 15.4 7.3 8.9 1.3 17.6.8 25.9-3.2l2.8-1.7a18 18 0 0 1-7.2 20l-5.5 3.8c-5.6 3.8-7.2 8.2-5 14.7l.2.7a14 14 0 0 1-6.6-5.6 15.8 15.8 0 0 1-2.6-8.6c0-1.5 0-3-.2-4.5-.5-3.7-2.2-5.3-5.5-5.4-3.3-.1-5.9 2-6.6 5.2l-.2.7Z"/>
|
|
6
|
+
<defs>
|
|
7
|
+
<linearGradient id="a" x1="64.7" x2="77.4" y1="119.2" y2="77.4" gradientUnits="userSpaceOnUse">
|
|
8
|
+
<stop stop-color="#D83333"/>
|
|
9
|
+
<stop offset="1" stop-color="#F041FF"/>
|
|
10
|
+
</linearGradient>
|
|
11
|
+
</defs>
|
|
12
|
+
<style>
|
|
13
|
+
g { fill: #000; }
|
|
14
|
+
@media (prefers-color-scheme: dark) {
|
|
15
|
+
g { fill: #FFF; }
|
|
16
|
+
}
|
|
17
|
+
</style>
|
|
18
|
+
</svg>
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
<meta charset="UTF-8" />
|
|
5
5
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
6
6
|
<title>{{TITLE}}</title>
|
|
7
|
+
<link rel="icon" type="image/svg+xml" href="favicon.svg" />
|
|
7
8
|
<link rel="stylesheet" href="{{LINK_HREF}}" />
|
|
8
9
|
</head>
|
|
9
10
|
<body>
|
|
@@ -34,5 +35,24 @@
|
|
|
34
35
|
</ul>
|
|
35
36
|
</section>
|
|
36
37
|
</main>
|
|
38
|
+
<footer class="footer" role="contentinfo">
|
|
39
|
+
<div class="footer__container">
|
|
40
|
+
<div class="footer__inner">
|
|
41
|
+
<p class="footer__copyright">
|
|
42
|
+
<span class="footer__site-name">Your Product</span> · <span class="footer__year">© 2026</span>
|
|
43
|
+
</p>
|
|
44
|
+
<nav class="footer__nav" aria-label="Footer">
|
|
45
|
+
<ul class="footer__links">
|
|
46
|
+
<li class="footer__link-item"><a class="footer__link" href="#">Get started</a></li>
|
|
47
|
+
<li class="footer__link-item"><a class="footer__link" href="#">Docs</a></li>
|
|
48
|
+
<li class="footer__link-item"><a class="footer__link" href="#">Components</a></li>
|
|
49
|
+
<li class="footer__link-item"><a class="footer__link" href="#">GitHub</a></li>
|
|
50
|
+
<li class="footer__link-item"><a class="footer__link" href="#">Privacy</a></li>
|
|
51
|
+
<li class="footer__link-item"><a class="footer__link" href="#">Terms</a></li>
|
|
52
|
+
</ul>
|
|
53
|
+
</nav>
|
|
54
|
+
</div>
|
|
55
|
+
</div>
|
|
56
|
+
</footer>
|
|
37
57
|
</body>
|
|
38
58
|
</html>
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 128 128">
|
|
2
|
+
<g>
|
|
3
|
+
<path d="M47.7 107.1c-5.5-5-7.2-15.7-4.9-23.4 4 4.9 9.6 6.4 15.4 7.3 8.9 1.3 17.6.8 25.9-3.2l2.8-1.7a18 18 0 0 1-7.2 20l-5.5 3.8c-5.6 3.8-7.2 8.2-5 14.7l.2.7a14 14 0 0 1-6.6-5.6 15.8 15.8 0 0 1-2.6-8.6c0-1.5 0-3-.2-4.5-.5-3.7-2.2-5.3-5.5-5.4-3.3-.1-5.9 2-6.6 5.2l-.2.7ZM16 82.4s16.5-8 33-8l12.4-38.3c.5-2 1.8-3.2 3.3-3.2 1.6 0 3 1.3 3.4 3.2l12.4 38.3c19.6 0 33 8 33 8l-28-76c-.8-2.3-2.2-3.7-4-3.7H48c-1.8 0-3.1 1.4-4 3.7l-28 76Z"/>
|
|
4
|
+
</g>
|
|
5
|
+
<path fill="url(#a)" d="M47.7 107.1c-5.5-5-7.2-15.7-4.9-23.4 4 4.9 9.6 6.4 15.4 7.3 8.9 1.3 17.6.8 25.9-3.2l2.8-1.7a18 18 0 0 1-7.2 20l-5.5 3.8c-5.6 3.8-7.2 8.2-5 14.7l.2.7a14 14 0 0 1-6.6-5.6 15.8 15.8 0 0 1-2.6-8.6c0-1.5 0-3-.2-4.5-.5-3.7-2.2-5.3-5.5-5.4-3.3-.1-5.9 2-6.6 5.2l-.2.7Z"/>
|
|
6
|
+
<defs>
|
|
7
|
+
<linearGradient id="a" x1="64.7" x2="77.4" y1="119.2" y2="77.4" gradientUnits="userSpaceOnUse">
|
|
8
|
+
<stop stop-color="#D83333"/>
|
|
9
|
+
<stop offset="1" stop-color="#F041FF"/>
|
|
10
|
+
</linearGradient>
|
|
11
|
+
</defs>
|
|
12
|
+
<style>
|
|
13
|
+
g { fill: #000; }
|
|
14
|
+
@media (prefers-color-scheme: dark) {
|
|
15
|
+
g { fill: #FFF; }
|
|
16
|
+
}
|
|
17
|
+
</style>
|
|
18
|
+
</svg>
|
|
@@ -4,10 +4,27 @@
|
|
|
4
4
|
<meta charset="UTF-8" />
|
|
5
5
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
6
6
|
<title>{{TITLE}}</title>
|
|
7
|
+
<link rel="icon" type="image/svg+xml" href="favicon.svg" />
|
|
7
8
|
<link rel="stylesheet" href="{{LINK_HREF}}" />
|
|
8
9
|
</head>
|
|
9
10
|
<body>
|
|
10
11
|
<h1>Hello, Rizzo CSS</h1>
|
|
11
12
|
<p>Edit this file and add components. Docs: <a href="https://rizzo-css.vercel.app">rizzo-css.vercel.app</a></p>
|
|
13
|
+
<footer class="footer" role="contentinfo">
|
|
14
|
+
<div class="footer__container">
|
|
15
|
+
<div class="footer__inner">
|
|
16
|
+
<p class="footer__copyright">
|
|
17
|
+
<span class="footer__site-name">My App</span> · <span class="footer__year">© 2026</span>
|
|
18
|
+
</p>
|
|
19
|
+
<nav class="footer__nav" aria-label="Footer">
|
|
20
|
+
<ul class="footer__links">
|
|
21
|
+
<li class="footer__link-item"><a class="footer__link" href="https://rizzo-css.vercel.app">Docs</a></li>
|
|
22
|
+
<li class="footer__link-item"><a class="footer__link" href="#">About</a></li>
|
|
23
|
+
<li class="footer__link-item"><a class="footer__link" href="#">Contact</a></li>
|
|
24
|
+
</ul>
|
|
25
|
+
</nav>
|
|
26
|
+
</div>
|
|
27
|
+
</div>
|
|
28
|
+
</footer>
|
|
12
29
|
</body>
|
|
13
30
|
</html>
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
(function(){try{var s=localStorage.getItem('theme');var d='{{DEFAULT_DARK}}';var l='{{DEFAULT_LIGHT}}';var initial=document.documentElement.getAttribute('data-theme');var r=!s?((initial&&initial!=='system')?initial:(matchMedia('(prefers-color-scheme: dark)').matches?d:l)):s==='system'?(matchMedia('(prefers-color-scheme: dark)').matches?d:l):s;document.documentElement.setAttribute('data-theme',r);}catch(e){}})();
|
|
8
8
|
</script>
|
|
9
9
|
<link rel="stylesheet" href="/css/rizzo.min.css" />
|
|
10
|
+
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
|
|
10
11
|
<title>{{TITLE}}</title>
|
|
11
12
|
</head>
|
|
12
13
|
<body>
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 128 128">
|
|
2
|
+
<g>
|
|
3
|
+
<path d="M47.7 107.1c-5.5-5-7.2-15.7-4.9-23.4 4 4.9 9.6 6.4 15.4 7.3 8.9 1.3 17.6.8 25.9-3.2l2.8-1.7a18 18 0 0 1-7.2 20l-5.5 3.8c-5.6 3.8-7.2 8.2-5 14.7l.2.7a14 14 0 0 1-6.6-5.6 15.8 15.8 0 0 1-2.6-8.6c0-1.5 0-3-.2-4.5-.5-3.7-2.2-5.3-5.5-5.4-3.3-.1-5.9 2-6.6 5.2l-.2.7ZM16 82.4s16.5-8 33-8l12.4-38.3c.5-2 1.8-3.2 3.3-3.2 1.6 0 3 1.3 3.4 3.2l12.4 38.3c19.6 0 33 8 33 8l-28-76c-.8-2.3-2.2-3.7-4-3.7H48c-1.8 0-3.1 1.4-4 3.7l-28 76Z"/>
|
|
4
|
+
</g>
|
|
5
|
+
<path fill="url(#a)" d="M47.7 107.1c-5.5-5-7.2-15.7-4.9-23.4 4 4.9 9.6 6.4 15.4 7.3 8.9 1.3 17.6.8 25.9-3.2l2.8-1.7a18 18 0 0 1-7.2 20l-5.5 3.8c-5.6 3.8-7.2 8.2-5 14.7l.2.7a14 14 0 0 1-6.6-5.6 15.8 15.8 0 0 1-2.6-8.6c0-1.5 0-3-.2-4.5-.5-3.7-2.2-5.3-5.5-5.4-3.3-.1-5.9 2-6.6 5.2l-.2.7Z"/>
|
|
6
|
+
<defs>
|
|
7
|
+
<linearGradient id="a" x1="64.7" x2="77.4" y1="119.2" y2="77.4" gradientUnits="userSpaceOnUse">
|
|
8
|
+
<stop stop-color="#D83333"/>
|
|
9
|
+
<stop offset="1" stop-color="#F041FF"/>
|
|
10
|
+
</linearGradient>
|
|
11
|
+
</defs>
|
|
12
|
+
<style>
|
|
13
|
+
g { fill: #000; }
|
|
14
|
+
@media (prefers-color-scheme: dark) {
|
|
15
|
+
g { fill: #FFF; }
|
|
16
|
+
}
|
|
17
|
+
</style>
|
|
18
|
+
</svg>
|
|
@@ -33,7 +33,17 @@ export default function App() {
|
|
|
33
33
|
<Route path="/themes" element={<Themes />} />
|
|
34
34
|
</Routes>
|
|
35
35
|
</main>
|
|
36
|
-
<Footer
|
|
36
|
+
<Footer
|
|
37
|
+
siteName="Rizzo CSS"
|
|
38
|
+
links={[
|
|
39
|
+
{ href: '/docs/getting-started', label: 'Getting Started' },
|
|
40
|
+
{ href: '/docs', label: 'Docs' },
|
|
41
|
+
{ href: '/docs/components', label: 'Components' },
|
|
42
|
+
{ href: '/blocks', label: 'Blocks' },
|
|
43
|
+
{ href: '/themes', label: 'Themes' },
|
|
44
|
+
{ href: 'https://github.com', label: 'GitHub' },
|
|
45
|
+
]}
|
|
46
|
+
/>
|
|
37
47
|
<BackToTop />
|
|
38
48
|
<Settings />
|
|
39
49
|
</>
|
|
@@ -21,7 +21,7 @@ function slugToTitle(slug: string): string {
|
|
|
21
21
|
.join(' ');
|
|
22
22
|
}
|
|
23
23
|
|
|
24
|
-
const
|
|
24
|
+
export const COMPONENT_CATEGORIES: { id: string; label: string; slugs: string[] }[] = [
|
|
25
25
|
{ id: 'layout', label: 'Layout', slugs: ['navbar', 'docs-sidebar', 'dashboard', 'resizable', 'footer'] },
|
|
26
26
|
{ id: 'forms', label: 'Forms & inputs', slugs: ['button', 'button-group', 'forms', 'switch', 'slider', 'toggle', 'toggle-group', 'divider', 'separator', 'label', 'kbd'] },
|
|
27
27
|
{ id: 'data', label: 'Data display', slugs: ['cards', 'table', 'badge', 'pagination', 'aspect-ratio', 'empty', 'scroll-area', 'alert', 'skeleton', 'spinner', 'progress-bar', 'toast'] },
|
|
@@ -31,7 +31,7 @@ const CATEGORIES: { id: string; label: string; slugs: string[] }[] = [
|
|
|
31
31
|
|
|
32
32
|
export function getComponentsByCategory(): CategoryWithItems[] {
|
|
33
33
|
const pathPrefix = '/docs/components';
|
|
34
|
-
return
|
|
34
|
+
return COMPONENT_CATEGORIES.map((cat) => ({
|
|
35
35
|
id: cat.id,
|
|
36
36
|
label: cat.label,
|
|
37
37
|
items: cat.slugs.map((slug) => ({
|
|
@@ -9,12 +9,125 @@
|
|
|
9
9
|
margin: 0 auto;
|
|
10
10
|
padding: 0 var(--content-padding-x);
|
|
11
11
|
}
|
|
12
|
+
.docs__header {
|
|
13
|
+
margin-bottom: var(--section-spacing-lg);
|
|
14
|
+
padding-bottom: var(--spacing-8);
|
|
15
|
+
border-bottom: 1px solid var(--border);
|
|
16
|
+
}
|
|
17
|
+
.docs__title {
|
|
18
|
+
font-size: var(--font-size-5xl);
|
|
19
|
+
font-weight: var(--font-weight-bold);
|
|
20
|
+
color: var(--text);
|
|
21
|
+
margin: 0 0 var(--spacing-4) 0;
|
|
22
|
+
line-height: var(--line-height-tight);
|
|
23
|
+
}
|
|
24
|
+
.docs__description {
|
|
25
|
+
font-size: var(--font-size-xl);
|
|
26
|
+
color: var(--text);
|
|
27
|
+
margin: 0;
|
|
28
|
+
line-height: var(--line-height-relaxed);
|
|
29
|
+
}
|
|
12
30
|
.docs__content {
|
|
13
31
|
width: 100%;
|
|
14
32
|
min-width: 0;
|
|
15
33
|
color: var(--text);
|
|
16
34
|
line-height: var(--line-height-relaxed);
|
|
17
35
|
}
|
|
36
|
+
.docs__content h2,
|
|
37
|
+
.docs__content h3 {
|
|
38
|
+
scroll-margin-top: var(--scroll-margin-below-header);
|
|
39
|
+
}
|
|
40
|
+
.docs__content h2 {
|
|
41
|
+
font-size: var(--font-size-4xl);
|
|
42
|
+
font-weight: var(--font-weight-bold);
|
|
43
|
+
margin-top: var(--section-spacing-lg);
|
|
44
|
+
margin-bottom: var(--spacing-6);
|
|
45
|
+
color: var(--text);
|
|
46
|
+
padding-bottom: var(--spacing-2);
|
|
47
|
+
border-bottom: 1px solid var(--border);
|
|
48
|
+
}
|
|
49
|
+
.docs__content h3 {
|
|
50
|
+
font-size: var(--font-size-3xl);
|
|
51
|
+
font-weight: var(--font-weight-semibold);
|
|
52
|
+
margin-top: var(--spacing-8);
|
|
53
|
+
margin-bottom: var(--spacing-4);
|
|
54
|
+
color: var(--text);
|
|
55
|
+
}
|
|
56
|
+
.docs__content h4 {
|
|
57
|
+
font-size: var(--font-size-2xl);
|
|
58
|
+
font-weight: var(--font-weight-semibold);
|
|
59
|
+
margin-top: var(--spacing-6);
|
|
60
|
+
margin-bottom: var(--spacing-3);
|
|
61
|
+
color: var(--text);
|
|
62
|
+
}
|
|
63
|
+
.docs__content p {
|
|
64
|
+
font-size: var(--font-size-base);
|
|
65
|
+
margin-bottom: var(--spacing-5);
|
|
66
|
+
}
|
|
67
|
+
.docs__content ul,
|
|
68
|
+
.docs__content ol {
|
|
69
|
+
margin-bottom: var(--spacing-5);
|
|
70
|
+
padding-left: var(--spacing-8);
|
|
71
|
+
}
|
|
72
|
+
.docs__content li {
|
|
73
|
+
margin-bottom: var(--spacing-2);
|
|
74
|
+
}
|
|
75
|
+
.docs__content blockquote {
|
|
76
|
+
border-left: var(--spacing-1) solid var(--accent);
|
|
77
|
+
padding-left: var(--spacing-6);
|
|
78
|
+
margin: var(--spacing-6) 0;
|
|
79
|
+
color: var(--text-dim);
|
|
80
|
+
font-style: italic;
|
|
81
|
+
}
|
|
82
|
+
.docs__content table {
|
|
83
|
+
width: 100%;
|
|
84
|
+
border-collapse: collapse;
|
|
85
|
+
margin-bottom: var(--spacing-6);
|
|
86
|
+
}
|
|
87
|
+
.docs__content th,
|
|
88
|
+
.docs__content td {
|
|
89
|
+
padding: var(--spacing-3);
|
|
90
|
+
text-align: left;
|
|
91
|
+
border-bottom: 1px solid var(--border);
|
|
92
|
+
}
|
|
93
|
+
.docs__content th {
|
|
94
|
+
font-weight: var(--font-weight-semibold);
|
|
95
|
+
background-color: var(--background-alt);
|
|
96
|
+
}
|
|
97
|
+
.docs__content a:not(.docs-sidebar__link):not(.docs-sidebar__sublink):not(.component-card-link):not(.block-card-link) {
|
|
98
|
+
color: var(--accent-fg);
|
|
99
|
+
text-decoration: underline;
|
|
100
|
+
text-underline-offset: 0.15em;
|
|
101
|
+
}
|
|
102
|
+
.docs__content a:not(.docs-sidebar__link):not(.docs-sidebar__sublink):not(.component-card-link):not(.block-card-link):hover {
|
|
103
|
+
color: var(--accent-fg-hover);
|
|
104
|
+
}
|
|
105
|
+
.docs__content hr {
|
|
106
|
+
border: none;
|
|
107
|
+
border-top: 1px solid var(--border);
|
|
108
|
+
margin: var(--spacing-8) 0;
|
|
109
|
+
}
|
|
110
|
+
.docs__content .example {
|
|
111
|
+
background-color: var(--background-alt);
|
|
112
|
+
border: 1px solid var(--border);
|
|
113
|
+
border-radius: var(--radius-lg);
|
|
114
|
+
padding: var(--spacing-6);
|
|
115
|
+
margin: var(--spacing-6) 0;
|
|
116
|
+
}
|
|
117
|
+
.docs__content section {
|
|
118
|
+
margin-bottom: var(--section-spacing-lg);
|
|
119
|
+
}
|
|
120
|
+
.docs__content section:last-child {
|
|
121
|
+
margin-bottom: 0;
|
|
122
|
+
}
|
|
123
|
+
@media (width <= 640px) {
|
|
124
|
+
.docs__title {
|
|
125
|
+
font-size: var(--font-size-4xl);
|
|
126
|
+
}
|
|
127
|
+
.docs__description {
|
|
128
|
+
font-size: var(--font-size-lg);
|
|
129
|
+
}
|
|
130
|
+
}
|
|
18
131
|
|
|
19
132
|
.home__container { width: 100%; max-width: var(--container-default); margin: 0 auto; padding: 0 var(--content-padding-x); }
|
|
20
133
|
.home__hero { text-align: center; padding: var(--spacing-10) 0; }
|
|
@@ -1,9 +1,29 @@
|
|
|
1
|
-
import { useEffect } from 'react';
|
|
1
|
+
import { useEffect, useMemo } from 'react';
|
|
2
2
|
import { Outlet, useLocation } from 'react-router-dom';
|
|
3
3
|
import DocsSidebar from '@/components/rizzo/DocsSidebar';
|
|
4
4
|
import BackToTop from '@/components/rizzo/BackToTop';
|
|
5
5
|
import { DOCS_NAV } from '@/config/docsNav';
|
|
6
6
|
|
|
7
|
+
const DOCS_PAGE_META: Record<string, { title: string; description: string }> = {
|
|
8
|
+
'/docs': {
|
|
9
|
+
title: 'Docs overview',
|
|
10
|
+
description:
|
|
11
|
+
'Rizzo CSS is a design system built on semantic theming and 14 themes. One CSS codebase, 53 accessible BEM components — for Vanilla JS, Astro, Svelte, React, and Vue.',
|
|
12
|
+
},
|
|
13
|
+
'/docs/overview': {
|
|
14
|
+
title: 'Overview',
|
|
15
|
+
description: 'Introduction to Rizzo CSS and the design system',
|
|
16
|
+
},
|
|
17
|
+
'/docs/getting-started': {
|
|
18
|
+
title: 'Getting Started',
|
|
19
|
+
description: 'Installation, project structure, and quick start guide',
|
|
20
|
+
},
|
|
21
|
+
'/docs/components': {
|
|
22
|
+
title: 'Components',
|
|
23
|
+
description: 'Browse all components by category',
|
|
24
|
+
},
|
|
25
|
+
};
|
|
26
|
+
|
|
7
27
|
function openSidebar() {
|
|
8
28
|
const docs = document.querySelector('[data-docs]');
|
|
9
29
|
const toggle = document.querySelector('[data-docs-sidebar-toggle]');
|
|
@@ -31,6 +51,10 @@ function toggleSidebar() {
|
|
|
31
51
|
export default function DocsLayout() {
|
|
32
52
|
const location = useLocation();
|
|
33
53
|
const currentPath = location.pathname;
|
|
54
|
+
const { title, description } = useMemo(() => {
|
|
55
|
+
const meta = DOCS_PAGE_META[currentPath.replace(/\/$/, '') || '/docs'];
|
|
56
|
+
return meta ?? { title: 'Docs', description: '' };
|
|
57
|
+
}, [currentPath]);
|
|
34
58
|
|
|
35
59
|
useEffect(() => {
|
|
36
60
|
const w = typeof window !== 'undefined' ? window.innerWidth : 1025;
|
|
@@ -82,6 +106,10 @@ export default function DocsLayout() {
|
|
|
82
106
|
</div>
|
|
83
107
|
<div className="docs__main">
|
|
84
108
|
<div className="docs__container">
|
|
109
|
+
<header className="docs__header">
|
|
110
|
+
<h1 className="docs__title">{title}</h1>
|
|
111
|
+
{description ? <p className="docs__description">{description}</p> : null}
|
|
112
|
+
</header>
|
|
85
113
|
<div className="docs__content">
|
|
86
114
|
<Outlet />
|
|
87
115
|
</div>
|
|
@@ -9,7 +9,6 @@ export default function DocsComponents() {
|
|
|
9
9
|
return (
|
|
10
10
|
<div>
|
|
11
11
|
<section className="docs-components-intro">
|
|
12
|
-
<h1 className="docs__title">Components</h1>
|
|
13
12
|
<p className="docs-components-intro__tagline">
|
|
14
13
|
Browse the collection of accessible, themeable components. Same CSS and BEM for Astro, Svelte, React, and Vanilla.
|
|
15
14
|
</p>
|
|
@@ -3,7 +3,6 @@ import { Link } from 'react-router-dom';
|
|
|
3
3
|
export default function DocsGettingStarted() {
|
|
4
4
|
return (
|
|
5
5
|
<div>
|
|
6
|
-
<h1 className="docs__title">Getting started</h1>
|
|
7
6
|
<p>This project was created with the <strong>Full</strong> template. You have the home page, docs overview, components index, blocks, and themes.</p>
|
|
8
7
|
|
|
9
8
|
<h2 id="installation">Installation</h2>
|
|
@@ -3,7 +3,6 @@ import { Link } from 'react-router-dom';
|
|
|
3
3
|
export default function DocsIndex() {
|
|
4
4
|
return (
|
|
5
5
|
<section className="docs-overview">
|
|
6
|
-
<h1 className="docs__title">Docs overview</h1>
|
|
7
6
|
<p className="docs-overview__intro">
|
|
8
7
|
Rizzo CSS is a design system built on semantic theming and 14 themes. One CSS codebase, 58 accessible BEM components — for <strong>Vanilla JS</strong>, <strong>Astro</strong>, <strong>Svelte</strong>, <strong>React</strong>, and <strong>Vue</strong>.
|
|
9
8
|
</p>
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 128 128">
|
|
2
|
+
<g>
|
|
3
|
+
<path d="M47.7 107.1c-5.5-5-7.2-15.7-4.9-23.4 4 4.9 9.6 6.4 15.4 7.3 8.9 1.3 17.6.8 25.9-3.2l2.8-1.7a18 18 0 0 1-7.2 20l-5.5 3.8c-5.6 3.8-7.2 8.2-5 14.7l.2.7a14 14 0 0 1-6.6-5.6 15.8 15.8 0 0 1-2.6-8.6c0-1.5 0-3-.2-4.5-.5-3.7-2.2-5.3-5.5-5.4-3.3-.1-5.9 2-6.6 5.2l-.2.7ZM16 82.4s16.5-8 33-8l12.4-38.3c.5-2 1.8-3.2 3.3-3.2 1.6 0 3 1.3 3.4 3.2l12.4 38.3c19.6 0 33 8 33 8l-28-76c-.8-2.3-2.2-3.7-4-3.7H48c-1.8 0-3.1 1.4-4 3.7l-28 76Z"/>
|
|
4
|
+
</g>
|
|
5
|
+
<path fill="url(#a)" d="M47.7 107.1c-5.5-5-7.2-15.7-4.9-23.4 4 4.9 9.6 6.4 15.4 7.3 8.9 1.3 17.6.8 25.9-3.2l2.8-1.7a18 18 0 0 1-7.2 20l-5.5 3.8c-5.6 3.8-7.2 8.2-5 14.7l.2.7a14 14 0 0 1-6.6-5.6 15.8 15.8 0 0 1-2.6-8.6c0-1.5 0-3-.2-4.5-.5-3.7-2.2-5.3-5.5-5.4-3.3-.1-5.9 2-6.6 5.2l-.2.7Z"/>
|
|
6
|
+
<defs>
|
|
7
|
+
<linearGradient id="a" x1="64.7" x2="77.4" y1="119.2" y2="77.4" gradientUnits="userSpaceOnUse">
|
|
8
|
+
<stop stop-color="#D83333"/>
|
|
9
|
+
<stop offset="1" stop-color="#F041FF"/>
|
|
10
|
+
</linearGradient>
|
|
11
|
+
</defs>
|
|
12
|
+
<style>
|
|
13
|
+
g { fill: #000; }
|
|
14
|
+
@media (prefers-color-scheme: dark) {
|
|
15
|
+
g { fill: #FFF; }
|
|
16
|
+
}
|
|
17
|
+
</style>
|
|
18
|
+
</svg>
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
(function(){try{var s=localStorage.getItem('theme');var d='{{DEFAULT_DARK}}';var l='{{DEFAULT_LIGHT}}';var initial=document.documentElement.getAttribute('data-theme');var r=!s?((initial&&initial!=='system')?initial:(matchMedia('(prefers-color-scheme: dark)').matches?d:l)):s==='system'?(matchMedia('(prefers-color-scheme: dark)').matches?d:l):s;document.documentElement.setAttribute('data-theme',r);}catch(e){}})();
|
|
8
8
|
</script>
|
|
9
9
|
<link rel="stylesheet" href="/css/rizzo.min.css" />
|
|
10
|
+
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
|
|
10
11
|
{{RIZZO_SOUND_SCRIPT}}
|
|
11
12
|
%sveltekit.head%
|
|
12
13
|
</head>
|
|
@@ -14,6 +14,15 @@
|
|
|
14
14
|
|
|
15
15
|
<Navbar siteName="Site" {menuLinks} />
|
|
16
16
|
<slot />
|
|
17
|
-
<Footer
|
|
17
|
+
<Footer
|
|
18
|
+
siteName="Site"
|
|
19
|
+
links={[
|
|
20
|
+
{ href: '/#about', label: 'About' },
|
|
21
|
+
{ href: '/#contact', label: 'Contact' },
|
|
22
|
+
{ href: '/docs', label: 'Docs' },
|
|
23
|
+
{ href: 'https://github.com', label: 'GitHub' },
|
|
24
|
+
{ href: 'https://twitter.com', label: 'Twitter' },
|
|
25
|
+
]}
|
|
26
|
+
/>
|
|
18
27
|
<BackToTop />
|
|
19
28
|
<Settings />
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 128 128">
|
|
2
|
+
<g>
|
|
3
|
+
<path d="M47.7 107.1c-5.5-5-7.2-15.7-4.9-23.4 4 4.9 9.6 6.4 15.4 7.3 8.9 1.3 17.6.8 25.9-3.2l2.8-1.7a18 18 0 0 1-7.2 20l-5.5 3.8c-5.6 3.8-7.2 8.2-5 14.7l.2.7a14 14 0 0 1-6.6-5.6 15.8 15.8 0 0 1-2.6-8.6c0-1.5 0-3-.2-4.5-.5-3.7-2.2-5.3-5.5-5.4-3.3-.1-5.9 2-6.6 5.2l-.2.7ZM16 82.4s16.5-8 33-8l12.4-38.3c.5-2 1.8-3.2 3.3-3.2 1.6 0 3 1.3 3.4 3.2l12.4 38.3c19.6 0 33 8 33 8l-28-76c-.8-2.3-2.2-3.7-4-3.7H48c-1.8 0-3.1 1.4-4 3.7l-28 76Z"/>
|
|
4
|
+
</g>
|
|
5
|
+
<path fill="url(#a)" d="M47.7 107.1c-5.5-5-7.2-15.7-4.9-23.4 4 4.9 9.6 6.4 15.4 7.3 8.9 1.3 17.6.8 25.9-3.2l2.8-1.7a18 18 0 0 1-7.2 20l-5.5 3.8c-5.6 3.8-7.2 8.2-5 14.7l.2.7a14 14 0 0 1-6.6-5.6 15.8 15.8 0 0 1-2.6-8.6c0-1.5 0-3-.2-4.5-.5-3.7-2.2-5.3-5.5-5.4-3.3-.1-5.9 2-6.6 5.2l-.2.7Z"/>
|
|
6
|
+
<defs>
|
|
7
|
+
<linearGradient id="a" x1="64.7" x2="77.4" y1="119.2" y2="77.4" gradientUnits="userSpaceOnUse">
|
|
8
|
+
<stop stop-color="#D83333"/>
|
|
9
|
+
<stop offset="1" stop-color="#F041FF"/>
|
|
10
|
+
</linearGradient>
|
|
11
|
+
</defs>
|
|
12
|
+
<style>
|
|
13
|
+
g { fill: #000; }
|
|
14
|
+
@media (prefers-color-scheme: dark) {
|
|
15
|
+
g { fill: #FFF; }
|
|
16
|
+
}
|
|
17
|
+
</style>
|
|
18
|
+
</svg>
|
|
@@ -56,4 +56,8 @@ SvelteKit project with Rizzo CSS. Scaffolded with `npx rizzo-css init` when you
|
|
|
56
56
|
- `pnpm build` — Build for production
|
|
57
57
|
- `pnpm preview` — Preview production build
|
|
58
58
|
|
|
59
|
+
## Troubleshooting
|
|
60
|
+
|
|
61
|
+
If the dev server shows **Failed to run dependency scan** or an error about a missing file under `src/lib/rizzo/` (e.g. `ThemeIcon.svelte`), the CLI may have omitted a required component. Upgrade to the latest **rizzo-css** and re-scaffold, or run `npx rizzo-css add` and add the missing component (e.g. ThemeIcon) into an existing project. The Full template requires ThemeIcon, ThemeSwitcher, Card, CopyToClipboard, Navbar, Footer, Settings, BackToTop, and DocsSidebar.
|
|
62
|
+
|
|
59
63
|
Docs: [rizzo-css.vercel.app](https://rizzo-css.vercel.app)
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
(function(){try{var s=localStorage.getItem('theme');var d='{{DEFAULT_DARK}}';var l='{{DEFAULT_LIGHT}}';var initial=document.documentElement.getAttribute('data-theme');var r=!s?((initial&&initial!=='system')?initial:(matchMedia('(prefers-color-scheme: dark)').matches?d:l)):s==='system'?(matchMedia('(prefers-color-scheme: dark)').matches?d:l):s;document.documentElement.setAttribute('data-theme',r);}catch(e){}})();
|
|
8
8
|
</script>
|
|
9
9
|
<link rel="stylesheet" href="/css/rizzo.min.css" />
|
|
10
|
+
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
|
|
10
11
|
{{RIZZO_SOUND_SCRIPT}}
|
|
11
12
|
%sveltekit.head%
|
|
12
13
|
</head>
|
|
@@ -21,7 +21,7 @@ function slugToTitle(slug: string): string {
|
|
|
21
21
|
.join(' ');
|
|
22
22
|
}
|
|
23
23
|
|
|
24
|
-
const
|
|
24
|
+
export const COMPONENT_CATEGORIES: { id: string; label: string; slugs: string[] }[] = [
|
|
25
25
|
{ id: 'layout', label: 'Layout', slugs: ['navbar', 'docs-sidebar', 'dashboard', 'resizable', 'footer'] },
|
|
26
26
|
{ id: 'forms', label: 'Forms & inputs', slugs: ['button', 'button-group', 'forms', 'switch', 'slider', 'toggle', 'toggle-group', 'divider', 'separator', 'label', 'kbd'] },
|
|
27
27
|
{ id: 'data', label: 'Data display', slugs: ['cards', 'table', 'badge', 'pagination', 'aspect-ratio', 'empty', 'scroll-area', 'alert', 'skeleton', 'spinner', 'progress-bar', 'toast'] },
|
|
@@ -31,7 +31,7 @@ const CATEGORIES: { id: string; label: string; slugs: string[] }[] = [
|
|
|
31
31
|
|
|
32
32
|
export function getComponentsByCategory(): CategoryWithItems[] {
|
|
33
33
|
const pathPrefix = '/docs/components';
|
|
34
|
-
return
|
|
34
|
+
return COMPONENT_CATEGORIES.map((cat) => ({
|
|
35
35
|
id: cat.id,
|
|
36
36
|
label: cat.label,
|
|
37
37
|
items: cat.slugs.map((slug) => ({
|
|
@@ -8,8 +8,21 @@
|
|
|
8
8
|
let { children }: { children: Snippet } = $props();
|
|
9
9
|
</script>
|
|
10
10
|
|
|
11
|
+
<a href="#main-content" class="skip-link">Skip to main content</a>
|
|
11
12
|
<Navbar siteName="Rizzo CSS" />
|
|
12
|
-
|
|
13
|
-
|
|
13
|
+
<main id="main-content">
|
|
14
|
+
{@render children()}
|
|
15
|
+
</main>
|
|
16
|
+
<Footer
|
|
17
|
+
siteName="Rizzo CSS"
|
|
18
|
+
links={[
|
|
19
|
+
{ href: '/docs/getting-started', label: 'Getting Started' },
|
|
20
|
+
{ href: '/docs', label: 'Docs' },
|
|
21
|
+
{ href: '/docs/components', label: 'Components' },
|
|
22
|
+
{ href: '/blocks', label: 'Blocks' },
|
|
23
|
+
{ href: '/themes', label: 'Themes' },
|
|
24
|
+
{ href: 'https://github.com', label: 'GitHub' },
|
|
25
|
+
]}
|
|
26
|
+
/>
|
|
14
27
|
<BackToTop />
|
|
15
28
|
<Settings />
|