decantr 0.9.0
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/AGENTS.md +868 -0
- package/CHANGELOG.md +255 -0
- package/CLAUDE.md +178 -0
- package/LICENSE +21 -0
- package/README.md +229 -0
- package/cli/art.js +127 -0
- package/cli/commands/a11y.js +61 -0
- package/cli/commands/audit.js +225 -0
- package/cli/commands/build.js +38 -0
- package/cli/commands/dev.js +18 -0
- package/cli/commands/doctor.js +197 -0
- package/cli/commands/figma-sync.js +48 -0
- package/cli/commands/figma-tokens.js +55 -0
- package/cli/commands/generate.js +26 -0
- package/cli/commands/init.js +116 -0
- package/cli/commands/lint.js +209 -0
- package/cli/commands/mcp.js +530 -0
- package/cli/commands/migrate.js +175 -0
- package/cli/commands/test.js +38 -0
- package/cli/commands/validate.js +354 -0
- package/cli/index.js +113 -0
- package/package.json +95 -0
- package/reference/atoms.md +517 -0
- package/reference/behaviors.md +384 -0
- package/reference/build-tooling.md +275 -0
- package/reference/color-guidelines.md +965 -0
- package/reference/component-lifecycle.md +137 -0
- package/reference/compound-spacing.md +95 -0
- package/reference/decantation-process.md +499 -0
- package/reference/dev-server-routes.md +93 -0
- package/reference/form-system.md +253 -0
- package/reference/i18n.md +336 -0
- package/reference/icons.md +576 -0
- package/reference/llm-primer.md +953 -0
- package/reference/plugins.md +252 -0
- package/reference/registry-consumption.md +76 -0
- package/reference/router.md +217 -0
- package/reference/shells.md +116 -0
- package/reference/spatial-guidelines.md +541 -0
- package/reference/ssr.md +234 -0
- package/reference/state-data.md +215 -0
- package/reference/state-patterns.md +166 -0
- package/reference/state.md +194 -0
- package/reference/style-system.md +110 -0
- package/reference/tokens.md +460 -0
- package/src/app.js +19 -0
- package/src/chart/_animate.js +266 -0
- package/src/chart/_base.js +109 -0
- package/src/chart/_data.js +209 -0
- package/src/chart/_format.js +106 -0
- package/src/chart/_interact.js +364 -0
- package/src/chart/_palette.js +105 -0
- package/src/chart/_renderer.js +52 -0
- package/src/chart/_scene.js +262 -0
- package/src/chart/_shared.js +371 -0
- package/src/chart/index.js +637 -0
- package/src/chart/layouts/_layout-base.js +328 -0
- package/src/chart/layouts/cartesian.js +148 -0
- package/src/chart/layouts/hierarchy.js +562 -0
- package/src/chart/layouts/polar.js +101 -0
- package/src/chart/renderers/canvas.js +179 -0
- package/src/chart/renderers/svg.js +256 -0
- package/src/chart/renderers/webgpu.js +715 -0
- package/src/chart/types/_type-base.js +26 -0
- package/src/chart/types/area.js +134 -0
- package/src/chart/types/bar.js +173 -0
- package/src/chart/types/box-plot.js +125 -0
- package/src/chart/types/bubble.js +63 -0
- package/src/chart/types/candlestick.js +115 -0
- package/src/chart/types/chord.js +85 -0
- package/src/chart/types/combination.js +108 -0
- package/src/chart/types/funnel.js +68 -0
- package/src/chart/types/gauge.js +163 -0
- package/src/chart/types/heatmap.js +98 -0
- package/src/chart/types/histogram.js +71 -0
- package/src/chart/types/line.js +111 -0
- package/src/chart/types/org-chart.js +93 -0
- package/src/chart/types/pie.js +81 -0
- package/src/chart/types/radar.js +96 -0
- package/src/chart/types/radial.js +68 -0
- package/src/chart/types/range-area.js +55 -0
- package/src/chart/types/range-bar.js +61 -0
- package/src/chart/types/sankey.js +73 -0
- package/src/chart/types/scatter.js +66 -0
- package/src/chart/types/sparkline.js +81 -0
- package/src/chart/types/sunburst.js +69 -0
- package/src/chart/types/swimlane.js +88 -0
- package/src/chart/types/treemap.js +62 -0
- package/src/chart/types/waterfall.js +100 -0
- package/src/components/_base.js +1658 -0
- package/src/components/_behaviors.js +1140 -0
- package/src/components/_primitives.js +534 -0
- package/src/components/_qr-encoder.js +539 -0
- package/src/components/accordion.js +207 -0
- package/src/components/affix.js +62 -0
- package/src/components/alert-dialog.js +75 -0
- package/src/components/alert.js +47 -0
- package/src/components/aspect-ratio.js +24 -0
- package/src/components/avatar-group.js +55 -0
- package/src/components/avatar.js +38 -0
- package/src/components/back-top.js +75 -0
- package/src/components/badge.js +74 -0
- package/src/components/banner.js +68 -0
- package/src/components/breadcrumb.js +162 -0
- package/src/components/button.js +115 -0
- package/src/components/calendar.js +131 -0
- package/src/components/card.js +192 -0
- package/src/components/carousel.js +98 -0
- package/src/components/cascader.js +261 -0
- package/src/components/checkbox.js +80 -0
- package/src/components/chip.js +81 -0
- package/src/components/code-block.js +82 -0
- package/src/components/collapsible.js +50 -0
- package/src/components/color-palette.js +438 -0
- package/src/components/color-picker.js +314 -0
- package/src/components/combobox.js +181 -0
- package/src/components/command.js +174 -0
- package/src/components/comment.js +206 -0
- package/src/components/context-menu.js +76 -0
- package/src/components/data-table.js +724 -0
- package/src/components/date-picker.js +217 -0
- package/src/components/date-range-picker.js +244 -0
- package/src/components/datetime-picker.js +271 -0
- package/src/components/descriptions.js +68 -0
- package/src/components/drawer.js +179 -0
- package/src/components/dropdown.js +88 -0
- package/src/components/empty.js +41 -0
- package/src/components/float-button.js +90 -0
- package/src/components/form.js +106 -0
- package/src/components/hover-card.js +49 -0
- package/src/components/icon.js +87 -0
- package/src/components/image.js +97 -0
- package/src/components/index.js +117 -0
- package/src/components/input-group.js +75 -0
- package/src/components/input-number.js +155 -0
- package/src/components/input-otp.js +178 -0
- package/src/components/input.js +91 -0
- package/src/components/kbd.js +36 -0
- package/src/components/label.js +25 -0
- package/src/components/list.js +118 -0
- package/src/components/masked-input.js +236 -0
- package/src/components/mentions.js +165 -0
- package/src/components/menu.js +259 -0
- package/src/components/message.js +80 -0
- package/src/components/modal.js +147 -0
- package/src/components/navigation-menu.js +166 -0
- package/src/components/notification.js +84 -0
- package/src/components/pagination.js +104 -0
- package/src/components/placeholder.js +132 -0
- package/src/components/popconfirm.js +70 -0
- package/src/components/popover.js +58 -0
- package/src/components/progress.js +61 -0
- package/src/components/qrcode.js +251 -0
- package/src/components/radiogroup.js +120 -0
- package/src/components/range-slider.js +176 -0
- package/src/components/rate.js +186 -0
- package/src/components/resizable.js +83 -0
- package/src/components/result.js +57 -0
- package/src/components/scroll-area.js +43 -0
- package/src/components/segmented.js +97 -0
- package/src/components/select.js +165 -0
- package/src/components/separator.js +31 -0
- package/src/components/shell.js +407 -0
- package/src/components/skeleton.js +39 -0
- package/src/components/slider.js +141 -0
- package/src/components/sortable-list.js +176 -0
- package/src/components/space.js +42 -0
- package/src/components/spinner.js +112 -0
- package/src/components/splitter.js +147 -0
- package/src/components/statistic.js +136 -0
- package/src/components/steps.js +99 -0
- package/src/components/switch.js +95 -0
- package/src/components/table.js +44 -0
- package/src/components/tabs.js +216 -0
- package/src/components/tag.js +115 -0
- package/src/components/textarea.js +82 -0
- package/src/components/time-picker.js +153 -0
- package/src/components/time-range-picker.js +170 -0
- package/src/components/timeline.js +226 -0
- package/src/components/toast.js +71 -0
- package/src/components/toggle.js +213 -0
- package/src/components/tooltip.js +57 -0
- package/src/components/tour.js +159 -0
- package/src/components/transfer.js +163 -0
- package/src/components/tree-select.js +274 -0
- package/src/components/tree.js +141 -0
- package/src/components/typography.js +136 -0
- package/src/components/upload.js +118 -0
- package/src/components/visually-hidden.js +20 -0
- package/src/components/watermark.js +124 -0
- package/src/core/index.js +539 -0
- package/src/core/lifecycle.js +69 -0
- package/src/css/atoms.js +651 -0
- package/src/css/components.js +940 -0
- package/src/css/derive.js +1296 -0
- package/src/css/index.js +265 -0
- package/src/css/runtime.js +268 -0
- package/src/css/styles/addons/bioluminescent.js +93 -0
- package/src/css/styles/addons/clay.js +70 -0
- package/src/css/styles/addons/clean.js +57 -0
- package/src/css/styles/addons/command-center.js +143 -0
- package/src/css/styles/addons/dopamine.js +83 -0
- package/src/css/styles/addons/editorial.js +80 -0
- package/src/css/styles/addons/glassmorphism.js +99 -0
- package/src/css/styles/addons/liquid-glass.js +105 -0
- package/src/css/styles/addons/prismatic.js +100 -0
- package/src/css/styles/addons/retro.js +63 -0
- package/src/css/styles/auradecantism.js +96 -0
- package/src/css/theme-registry.js +444 -0
- package/src/data/entity.js +281 -0
- package/src/data/index.js +13 -0
- package/src/data/persist.js +225 -0
- package/src/data/query.js +839 -0
- package/src/data/realtime.js +299 -0
- package/src/data/url.js +177 -0
- package/src/data/worker.js +134 -0
- package/src/explorer/archetypes.js +243 -0
- package/src/explorer/atoms.js +228 -0
- package/src/explorer/charts.js +497 -0
- package/src/explorer/components.js +129 -0
- package/src/explorer/foundations.js +949 -0
- package/src/explorer/icons.js +178 -0
- package/src/explorer/patterns.js +247 -0
- package/src/explorer/recipes.js +194 -0
- package/src/explorer/shared/pattern-examples.js +1337 -0
- package/src/explorer/shared/showcase-renderer.js +958 -0
- package/src/explorer/shared/spec-table.js +41 -0
- package/src/explorer/shared/usage-links.js +87 -0
- package/src/explorer/shell-config.js +10 -0
- package/src/explorer/shells.js +551 -0
- package/src/explorer/styles.js +161 -0
- package/src/explorer/tokens.js +262 -0
- package/src/explorer/tools.js +525 -0
- package/src/form/index.js +804 -0
- package/src/i18n/index.js +251 -0
- package/src/icons/essential.js +479 -0
- package/src/icons/index.js +53 -0
- package/src/plugins/index.js +282 -0
- package/src/registry/archetypes/content-site.json +71 -0
- package/src/registry/archetypes/docs-explorer.json +23 -0
- package/src/registry/archetypes/ecommerce.json +104 -0
- package/src/registry/archetypes/financial-dashboard.json +77 -0
- package/src/registry/archetypes/index.json +41 -0
- package/src/registry/archetypes/portfolio.json +82 -0
- package/src/registry/archetypes/recipe-community.json +159 -0
- package/src/registry/archetypes/saas-dashboard.json +86 -0
- package/src/registry/architect/cross-cutting.json +45 -0
- package/src/registry/architect/domains/ecommerce.json +294 -0
- package/src/registry/architect/domains/financial-services.json +302 -0
- package/src/registry/architect/index.json +26 -0
- package/src/registry/architect/traits.json +379 -0
- package/src/registry/atoms.json +16 -0
- package/src/registry/chart-showcase.json +160 -0
- package/src/registry/chart.json +136 -0
- package/src/registry/components.json +8616 -0
- package/src/registry/core.json +216 -0
- package/src/registry/css.json +319 -0
- package/src/registry/data.json +135 -0
- package/src/registry/foundations.json +11 -0
- package/src/registry/icons.json +463 -0
- package/src/registry/index.json +101 -0
- package/src/registry/patterns/activity-feed.json +37 -0
- package/src/registry/patterns/article-content.json +27 -0
- package/src/registry/patterns/auth-form.json +37 -0
- package/src/registry/patterns/author-card.json +20 -0
- package/src/registry/patterns/card-grid.json +127 -0
- package/src/registry/patterns/category-nav.json +26 -0
- package/src/registry/patterns/chart-grid.json +36 -0
- package/src/registry/patterns/chat-interface.json +37 -0
- package/src/registry/patterns/checklist-card.json +55 -0
- package/src/registry/patterns/comparison-panel.json +27 -0
- package/src/registry/patterns/component-showcase.json +24 -0
- package/src/registry/patterns/contact-form.json +31 -0
- package/src/registry/patterns/cta-section.json +20 -0
- package/src/registry/patterns/data-table.json +37 -0
- package/src/registry/patterns/detail-header.json +83 -0
- package/src/registry/patterns/detail-panel.json +27 -0
- package/src/registry/patterns/explorer-shell.json +22 -0
- package/src/registry/patterns/filter-bar.json +33 -0
- package/src/registry/patterns/filter-sidebar.json +27 -0
- package/src/registry/patterns/form-sections.json +110 -0
- package/src/registry/patterns/goal-tracker.json +27 -0
- package/src/registry/patterns/hero.json +107 -0
- package/src/registry/patterns/index.json +47 -0
- package/src/registry/patterns/kpi-grid.json +36 -0
- package/src/registry/patterns/media-gallery.json +20 -0
- package/src/registry/patterns/order-history.json +20 -0
- package/src/registry/patterns/pagination.json +19 -0
- package/src/registry/patterns/photo-to-recipe.json +36 -0
- package/src/registry/patterns/pipeline-tracker.json +28 -0
- package/src/registry/patterns/post-list.json +27 -0
- package/src/registry/patterns/pricing-table.json +32 -0
- package/src/registry/patterns/scorecard.json +28 -0
- package/src/registry/patterns/search-bar.json +20 -0
- package/src/registry/patterns/specimen-grid.json +19 -0
- package/src/registry/patterns/stat-card.json +55 -0
- package/src/registry/patterns/stats-bar.json +55 -0
- package/src/registry/patterns/steps-card.json +55 -0
- package/src/registry/patterns/table-of-contents.json +19 -0
- package/src/registry/patterns/testimonials.json +21 -0
- package/src/registry/patterns/timeline.json +27 -0
- package/src/registry/patterns/token-inspector.json +21 -0
- package/src/registry/patterns/wizard.json +27 -0
- package/src/registry/recipe-auradecantism.json +69 -0
- package/src/registry/recipe-clean.json +65 -0
- package/src/registry/recipe-command-center.json +78 -0
- package/src/registry/router.json +73 -0
- package/src/registry/schema/README.md +197 -0
- package/src/registry/skeletons.json +259 -0
- package/src/registry/state.json +137 -0
- package/src/registry/tokens.json +40 -0
- package/src/router/hash.js +17 -0
- package/src/router/history.js +18 -0
- package/src/router/index.js +598 -0
- package/src/ssr/index.js +922 -0
- package/src/state/arrays.js +181 -0
- package/src/state/devtools.js +647 -0
- package/src/state/index.js +498 -0
- package/src/state/middleware.js +288 -0
- package/src/state/scheduler.js +206 -0
- package/src/state/store.js +300 -0
- package/src/tags/index.js +19 -0
- package/src/tannins/auth.js +396 -0
- package/src/test/dom.js +352 -0
- package/src/test/index.js +62 -0
- package/src/test/state.js +306 -0
- package/tools/a11y-audit.js +487 -0
- package/tools/analyzer.js +315 -0
- package/tools/audit.js +706 -0
- package/tools/builder.js +1422 -0
- package/tools/css-extract.js +188 -0
- package/tools/dev-server.js +316 -0
- package/tools/dts-gen.js +1260 -0
- package/tools/figma-components.js +329 -0
- package/tools/figma-patterns.js +516 -0
- package/tools/figma-plugin/code.js +453 -0
- package/tools/figma-plugin/manifest.json +14 -0
- package/tools/figma-plugin/ui.html +268 -0
- package/tools/figma-render.js +293 -0
- package/tools/figma-tokens.js +712 -0
- package/tools/figma-upload.js +318 -0
- package/tools/generate.js +738 -0
- package/tools/icons.js +133 -0
- package/tools/init-templates.js +265 -0
- package/tools/install-hooks.sh +5 -0
- package/tools/migrations/0.5.0.js +53 -0
- package/tools/migrations/0.6.0.js +95 -0
- package/tools/minify.js +170 -0
- package/tools/pre-commit +4 -0
- package/tools/registry.js +662 -0
- package/tools/reset-playground.js +61 -0
- package/tools/starter-templates/content-site/app.js +49 -0
- package/tools/starter-templates/content-site/essence.js +19 -0
- package/tools/starter-templates/content-site/pages.js +31 -0
- package/tools/starter-templates/ecommerce/app.js +50 -0
- package/tools/starter-templates/ecommerce/essence.js +19 -0
- package/tools/starter-templates/ecommerce/pages.js +31 -0
- package/tools/starter-templates/landing-page/app.js +38 -0
- package/tools/starter-templates/landing-page/essence.js +18 -0
- package/tools/starter-templates/landing-page/pages.js +21 -0
- package/tools/starter-templates/portfolio/app.js +45 -0
- package/tools/starter-templates/portfolio/essence.js +19 -0
- package/tools/starter-templates/portfolio/pages.js +33 -0
- package/tools/starter-templates/saas-dashboard/app.js +70 -0
- package/tools/starter-templates/saas-dashboard/essence.js +19 -0
- package/tools/starter-templates/saas-dashboard/pages.js +31 -0
- package/tools/verify-pack.js +203 -0
- package/types/chart.d.ts +77 -0
- package/types/components.d.ts +587 -0
- package/types/core.d.ts +89 -0
- package/types/css.d.ts +149 -0
- package/types/data.d.ts +238 -0
- package/types/form.d.ts +164 -0
- package/types/i18n.d.ts +51 -0
- package/types/icons.d.ts +27 -0
- package/types/index.d.ts +13 -0
- package/types/router.d.ts +116 -0
- package/types/ssr.d.ts +102 -0
- package/types/state.d.ts +83 -0
- package/types/tags.d.ts +62 -0
- package/types/tannins.d.ts +63 -0
- package/types/test.d.ts +48 -0
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v1.json",
|
|
3
|
+
"id": "pipeline-tracker",
|
|
4
|
+
"name": "Pipeline Tracker",
|
|
5
|
+
"description": "Stage-based progression visualization with summary metrics per stage, funnel or horizontal bar visualization, and drill-down data table for items in each stage.",
|
|
6
|
+
"components": ["Chart", "Badge", "DataTable", "Tabs", "Statistic", "Select"],
|
|
7
|
+
"default_blend": {
|
|
8
|
+
"layout": "stack",
|
|
9
|
+
"atoms": "_flex _flexCol _gap4 _p4",
|
|
10
|
+
"slots": {
|
|
11
|
+
"header": "Section title with _heading4, stage filter Select, period selector",
|
|
12
|
+
"summary": "Horizontal row of stage cards (_flex _gap3): stage name, item count (Badge), total value (Statistic)",
|
|
13
|
+
"visualization": "Chart({ type: 'funnel' }) or Chart({ type: 'bar' }) showing stage volumes with conversion rate annotations between stages",
|
|
14
|
+
"detail": "Tabbed DataTable showing items in selected stage with drill-down"
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
"recipe_overrides": {
|
|
18
|
+
"command-center": {
|
|
19
|
+
"wrapper": "cc-frame",
|
|
20
|
+
"atoms": "cc-scanline cc-grid",
|
|
21
|
+
"notes": "Stage cards use cc-bar. Chart segments get cc-glow on hover. DataTable gets cc-scanline. Stage counts use cc-data."
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
"code": {
|
|
25
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { createSignal } from 'decantr/state';\nimport { css } from 'decantr/css';\nimport { Badge, DataTable, Tabs, Statistic, Select } from 'decantr/components';\nimport { Chart } from 'decantr/chart';",
|
|
26
|
+
"example": "function PipelineTracker() {\n const { div, h3, span } = tags;\n const stages = [\n { id: 'prospect', name: 'Prospect', value: 240000, count: 42 },\n { id: 'qualified', name: 'Qualified', value: 180000, count: 28 },\n { id: 'proposal', name: 'Proposal', value: 95000, count: 12 },\n { id: 'negotiation', name: 'Negotiation', value: 62000, count: 6 },\n { id: 'closed', name: 'Closed Won', value: 48000, count: 4 }\n ];\n const items = [\n { name: 'Acme Corp', value: 45000, stage: 'proposal', owner: 'Alice' },\n { name: 'Globex Inc', value: 32000, stage: 'qualified', owner: 'Bob' },\n { name: 'Initech', value: 28000, stage: 'negotiation', owner: 'Carol' },\n { name: 'Umbrella Co', value: 18000, stage: 'prospect', owner: 'Dan' }\n ];\n const [activeStage, setActiveStage] = createSignal('all');\n\n return div({ class: css('_flex _col _gap4 _p4') },\n h3({ class: css('_heading4') }, 'Pipeline'),\n div({ class: css('_flex _gap3 _overflow[auto]') },\n ...stages.map(s =>\n div({ class: css('_flex _col _gap1 _p3 _b1 _r4 _minw[140px] _tc _pointer'),\n onclick: () => setActiveStage(s.id) },\n span({ class: css('_textsm _fgmuted') }, s.name),\n Statistic({ value: s.value, prefix: '$' }),\n Badge({ variant: 'default' }, `${s.count} deals`)\n )\n )\n ),\n Chart({ type: 'funnel', data: stages, x: 'name', y: 'value', title: 'Conversion Funnel', height: 260 }),\n DataTable({\n columns: [\n { key: 'name', label: 'Deal', sortable: true },\n { key: 'value', label: 'Value', sortable: true },\n { key: 'stage', label: 'Stage' },\n { key: 'owner', label: 'Owner' }\n ],\n data: () => activeStage() === 'all' ? items : items.filter(i => i.stage === activeStage()),\n sortable: true, paginate: true\n })\n );\n}"
|
|
27
|
+
}
|
|
28
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v1.json",
|
|
3
|
+
"id": "post-list",
|
|
4
|
+
"name": "Post List",
|
|
5
|
+
"description": "List of article preview cards with title, excerpt, author, date, and category. Used for blogs, news feeds, and content indexes.",
|
|
6
|
+
"components": ["Card", "Card.Body", "Avatar", "Badge", "Chip", "Pagination", "Button"],
|
|
7
|
+
"default_blend": {
|
|
8
|
+
"layout": "stack",
|
|
9
|
+
"atoms": "_flex _flexCol _gap4 _p4",
|
|
10
|
+
"slots": {
|
|
11
|
+
"category-filter": "Optional row of Chip filters at top for filtering by topic",
|
|
12
|
+
"posts": "Card list with each Card.Body containing title, excerpt, Avatar author, date Badge, and category Chip",
|
|
13
|
+
"pagination": "Bottom pagination controls or load-more Button via _flex _justifyCenter"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"recipe_overrides": {
|
|
17
|
+
"command-center": {
|
|
18
|
+
"wrapper": "cc-frame",
|
|
19
|
+
"atoms": "cc-scanline",
|
|
20
|
+
"notes": "Category pills use cc-label. Post dates use cc-data. Featured posts get cc-glow border. List area uses cc-scanline."
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"code": {
|
|
24
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { css } from 'decantr/css';\nimport { Card, Badge, Avatar } from 'decantr/components';\nimport { link } from 'decantr/router';",
|
|
25
|
+
"example": "function PostList() {\n const { div, h3, p, span, time } = tags;\n const posts = [\n { slug: 'design-systems', category: 'Design', readTime: '5 min', title: 'Building Design Systems at Scale', excerpt: 'How to create and maintain design systems that grow with your organization.', author: { avatar: '', name: 'Alice Chen' }, date: 'Mar 10, 2026' },\n { slug: 'reactive-state', category: 'Engineering', readTime: '8 min', title: 'Reactive State Management Patterns', excerpt: 'Exploring signals, stores, and effects for predictable UI state.', author: { avatar: '', name: 'Bob Patel' }, date: 'Mar 8, 2026' },\n { slug: 'accessibility', category: 'Design', readTime: '6 min', title: 'Accessibility Beyond Compliance', excerpt: 'Moving past checklists to create truly inclusive experiences.', author: { avatar: '', name: 'Carol Liu' }, date: 'Mar 5, 2026' }\n ];\n\n return div({ class: css('_flex _col _gap4 _p4') },\n ...posts.map(post =>\n link({ href: `/blog/${post.slug}`, class: css('_nounder') },\n Card({ class: css('_flex _col _gap3') },\n Card.Body({},\n div({ class: css('_flex _aic _gap2 _mb2') },\n Badge({}, post.category),\n span({ class: css('_textxs _fgmuted') }, post.readTime)\n ),\n h3({ class: css('_heading5') }, post.title),\n p({ class: css('_textsm _fgmuted _clamp2') }, post.excerpt),\n div({ class: css('_flex _aic _gap2 _mt3') },\n Avatar({ src: post.author.avatar, name: post.author.name, size: 'sm' }),\n span({ class: css('_textsm') }, post.author.name),\n time({ class: css('_textsm _fgmuted _mla') }, post.date)\n )\n )\n )\n )\n )\n );\n}"
|
|
26
|
+
}
|
|
27
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v1.json",
|
|
3
|
+
"id": "pricing-table",
|
|
4
|
+
"name": "Pricing Table",
|
|
5
|
+
"description": "Comparison pricing cards with features list, pricing tiers, and CTA buttons.",
|
|
6
|
+
"components": ["Card", "Button", "Badge", "Separator", "List"],
|
|
7
|
+
"default_blend": {
|
|
8
|
+
"layout": "grid",
|
|
9
|
+
"atoms": "_grid _gc3 _gap6 _aic",
|
|
10
|
+
"slots": {
|
|
11
|
+
"pricing-card": "Card per tier with price, name, and highlighted Badge",
|
|
12
|
+
"features-list": "Checklist of included features separated by Separator",
|
|
13
|
+
"cta": "Primary action Button per pricing tier"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"recipe_overrides": {
|
|
17
|
+
"auradecantism": {
|
|
18
|
+
"wrapper": "",
|
|
19
|
+
"atoms": "",
|
|
20
|
+
"notes": "Featured plan card uses d-glass-strong. Plan name uses d-gradient-text. CTA button on featured plan gets aura-glow."
|
|
21
|
+
},
|
|
22
|
+
"clean": {
|
|
23
|
+
"wrapper": "",
|
|
24
|
+
"atoms": "",
|
|
25
|
+
"notes": "Standard card layout. Featured plan has primary border. No extra decoration."
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"code": {
|
|
29
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { css } from 'decantr/css';\nimport { Card, Button, Badge, Separator, icon } from 'decantr/components';",
|
|
30
|
+
"example": "function PricingTable() {\n const { div, span, h3, ul, li } = tags;\n const plans = [\n { name: 'Starter', price: 9, featured: false, features: ['5 projects', '1 GB storage', 'Email support'] },\n { name: 'Pro', price: 29, featured: true, features: ['Unlimited projects', '10 GB storage', 'Priority support', 'API access', 'Custom domain'] },\n { name: 'Enterprise', price: 99, featured: false, features: ['Everything in Pro', '100 GB storage', 'Dedicated support', 'SSO', 'Audit logs', 'SLA'] }\n ];\n\n return div({ class: css('_grid _gc3 _gap6 _p4 _aic') },\n ...plans.map(plan =>\n Card({ class: css(plan.featured ? '_b2 _bcprimary' : '') },\n Card.Header({ class: css('_tc') },\n plan.featured ? Badge({ variant: 'primary', class: css('_mb2') }, 'Popular') : null,\n h3({ class: css('_heading4') }, plan.name),\n div({ class: css('_mt2') },\n span({ class: css('_heading1') }, `$${plan.price}`),\n span({ class: css('_fgmuted') }, '/month')\n )\n ),\n Separator(),\n Card.Body({},\n ul({ class: css('_flex _col _gap2') },\n ...plan.features.map(f =>\n li({ class: css('_flex _aic _gap2 _textsm') }, icon('check', { class: css('_fgsuccess') }), f)\n )\n )\n ),\n Card.Footer({},\n Button({ variant: plan.featured ? 'primary' : 'outline', class: css('_wfull') }, 'Get Started')\n )\n )\n )\n );\n}"
|
|
31
|
+
}
|
|
32
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v1.json",
|
|
3
|
+
"id": "scorecard",
|
|
4
|
+
"name": "Scorecard",
|
|
5
|
+
"description": "Grouped metric tracking grid for OKR, initiative, or performance review tracking. Rows grouped by category, each showing metric label, current value, target, progress bar, status badge, and optional owner.",
|
|
6
|
+
"components": ["DataTable", "Progress", "Badge", "Text", "Separator", "Avatar"],
|
|
7
|
+
"default_blend": {
|
|
8
|
+
"layout": "stack",
|
|
9
|
+
"atoms": "_flex _flexCol _gap6 _p4",
|
|
10
|
+
"slots": {
|
|
11
|
+
"header": "Section title with _heading4, period selector, export Button",
|
|
12
|
+
"groups": "Repeating group sections separated by Separator. Category heading (Text _heading5) + metric rows",
|
|
13
|
+
"metric-row": "Each row: label, current value, target, Progress bar, delta Badge (ahead/behind), optional Avatar owner",
|
|
14
|
+
"footer": "Overall score summary or aggregate progress"
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
"recipe_overrides": {
|
|
18
|
+
"command-center": {
|
|
19
|
+
"wrapper": "cc-frame",
|
|
20
|
+
"atoms": "cc-scanline",
|
|
21
|
+
"notes": "Group headers use cc-bar with cc-label. Metric values use cc-data. Behind-target rows get cc-glow warning. Progress bars use cc-bar."
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
"code": {
|
|
25
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { css } from 'decantr/css';\nimport { Statistic, Progress, Badge } from 'decantr/components';",
|
|
26
|
+
"example": "function Scorecard() {\n const { div, h3, span } = tags;\n const groups = [\n { name: 'Revenue', metrics: [\n { label: 'Monthly Revenue', value: 142, target: 150, unit: 'K', status: 'on-track' },\n { label: 'ARR Growth', value: 24, target: 30, unit: '%', status: 'behind' }\n ]},\n { name: 'Product', metrics: [\n { label: 'Active Users', value: 84, target: 100, unit: 'K', status: 'at-risk' },\n { label: 'NPS Score', value: 72, target: 75, unit: '', status: 'on-track' }\n ]}\n ];\n\n return div({ class: css('_flex _col _gap6 _p4') },\n ...groups.map(group =>\n div({ class: css('_flex _col _gap3') },\n h3({ class: css('_heading5') }, group.name),\n div({ class: css('_grid _gc3 _gap4') },\n ...group.metrics.map(m =>\n div({ class: css('_flex _col _gap2 _p4 _b1 _r4') },\n div({ class: css('_flex _aic _jcsb') },\n span({ class: css('_textsm _bold') }, m.label),\n Badge({ variant: m.status === 'on-track' ? 'success' : m.status === 'behind' ? 'error' : 'warning' }, m.status)\n ),\n Statistic({ value: m.value, suffix: m.unit }),\n Progress({ value: (m.value / m.target) * 100 }),\n span({ class: css('_textxs _fgmuted') }, `Target: ${m.target}${m.unit}`)\n )\n )\n )\n )\n )\n );\n}"
|
|
27
|
+
}
|
|
28
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v1.json",
|
|
3
|
+
"id": "search-bar",
|
|
4
|
+
"name": "Search Bar",
|
|
5
|
+
"description": "Search input with optional filters and real-time suggestions.",
|
|
6
|
+
"components": ["Input", "Button", "Dropdown"],
|
|
7
|
+
"default_blend": {
|
|
8
|
+
"layout": "row",
|
|
9
|
+
"atoms": "_flex _gap2 _aic",
|
|
10
|
+
"slots": {
|
|
11
|
+
"search-input": "Primary search Input with icon and placeholder",
|
|
12
|
+
"filter-controls": "Optional filter Buttons or Dropdown toggles",
|
|
13
|
+
"suggestions": "Real-time suggestion list below the input"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"code": {
|
|
17
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { createSignal } from 'decantr/state';\nimport { css } from 'decantr/css';\nimport { Input, Button, icon } from 'decantr/components';",
|
|
18
|
+
"example": "function SearchBar() {\n const { div } = tags;\n const [query, setQuery] = createSignal('');\n\n return div({ class: css('_flex _gap2 _aic') },\n Input({\n placeholder: 'Search...',\n value: query,\n onchange: e => setQuery(e.target.value),\n class: css('_flex1')\n }),\n Button({ variant: 'primary' }, icon('search'), 'Search')\n );\n}"
|
|
19
|
+
}
|
|
20
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v1.json",
|
|
3
|
+
"id": "specimen-grid",
|
|
4
|
+
"name": "Specimen Grid",
|
|
5
|
+
"description": "Auto-fill grid of design specimens — atom previews, icon tiles, color swatches. Each cell shows a labeled visual sample.",
|
|
6
|
+
"components": ["Card", "Badge", "Chip"],
|
|
7
|
+
"default_blend": {
|
|
8
|
+
"layout": "grid",
|
|
9
|
+
"atoms": "_grid _gcaf180 _gap3",
|
|
10
|
+
"slots": {
|
|
11
|
+
"specimen-card": "Individual specimen cell with preview area + name label + optional value",
|
|
12
|
+
"filter-bar": "Optional filter Input at top to narrow visible specimens"
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
"code": {
|
|
16
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { css } from 'decantr/css';\nimport { Card } from 'decantr/components';",
|
|
17
|
+
"example": "function SpecimenGrid() {\n const { div, span, code } = tags;\n const specimens = [\n { name: 'Primary', value: '--d-primary', style: 'background:var(--d-primary)', preview: null },\n { name: 'Secondary', value: '--d-secondary', style: 'background:var(--d-secondary)', preview: null },\n { name: 'Accent', value: '--d-accent', style: 'background:var(--d-accent)', preview: null },\n { name: 'Muted', value: '--d-muted', style: 'background:var(--d-muted)', preview: null },\n { name: 'Background', value: '--d-bg', style: 'background:var(--d-bg)', preview: null },\n { name: 'Surface', value: '--d-surface-0', style: 'background:var(--d-surface-0)', preview: null }\n ];\n\n return div({ class: css('_grid _gcaf200 _gap4 _p4') },\n ...specimens.map(s =>\n Card({ class: css('_flex _col') },\n div({ class: css('_flex _center _p6 _bgmuted _r4'), style: s.style },\n s.preview\n ),\n Card.Body({ class: css('_flex _col _gap1') },\n span({ class: css('_textsm _bold') }, s.name),\n code({ class: css('_textxs _fgmuted _fontmono') }, s.value)\n )\n )\n )\n );\n}"
|
|
18
|
+
}
|
|
19
|
+
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v2.json",
|
|
3
|
+
"id": "stat-card",
|
|
4
|
+
"name": "Stat Card",
|
|
5
|
+
"description": "Compact grid of key statistics displayed in a Card. Used for nutrition facts, project metrics, and summary data blocks.",
|
|
6
|
+
"components": ["Card", "Card.Header", "Card.Body", "Statistic", "icon"],
|
|
7
|
+
"default_preset": "compact-grid",
|
|
8
|
+
"presets": {
|
|
9
|
+
"compact-grid": {
|
|
10
|
+
"description": "2x2 grid of Statistic items inside a Card. For nutrition facts, key metrics summaries.",
|
|
11
|
+
"components": ["Card", "Card.Header", "Card.Body", "Statistic", "icon"],
|
|
12
|
+
"blend": {
|
|
13
|
+
"layout": "grid",
|
|
14
|
+
"atoms": "_grid _gc2 _gap3",
|
|
15
|
+
"slots": {
|
|
16
|
+
"header": "Card.Header with title",
|
|
17
|
+
"stats": "2x2 grid of Statistic components with icon, value, and unit"
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"code": {
|
|
21
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { css } from 'decantr/css';\nimport { Card, Statistic, icon } from 'decantr/components';",
|
|
22
|
+
"example": "function StatCard({ title, stats }) {\n const { div, h3 } = tags;\n\n return Card({},\n Card.Header({},\n h3({ class: css('_heading5') }, icon('heart-pulse'), ` ${title}`)\n ),\n Card.Body({ class: css('_grid _gc2 _gap3') },\n ...stats.map(s =>\n Statistic({ label: s.label, value: s.value, suffix: s.unit })\n )\n )\n );\n}"
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
"default_blend": {
|
|
27
|
+
"layout": "grid",
|
|
28
|
+
"atoms": "_grid _gc2 _gap3",
|
|
29
|
+
"slots": {
|
|
30
|
+
"header": "Card.Header with title",
|
|
31
|
+
"stats": "Grid of Statistic components"
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
"recipe_overrides": {
|
|
35
|
+
"command-center": {
|
|
36
|
+
"wrapper": "cc-frame-sm",
|
|
37
|
+
"atoms": "",
|
|
38
|
+
"notes": "Card uses cc-frame-sm. Values use cc-data with cc-glow on high values."
|
|
39
|
+
},
|
|
40
|
+
"auradecantism": {
|
|
41
|
+
"wrapper": "d-glass",
|
|
42
|
+
"atoms": "_r4",
|
|
43
|
+
"notes": "Card on glass background. Values use d-gradient-text."
|
|
44
|
+
},
|
|
45
|
+
"clean": {
|
|
46
|
+
"wrapper": "",
|
|
47
|
+
"atoms": "_b1 _r4",
|
|
48
|
+
"notes": "Simple bordered card with clean stat display."
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
"code": {
|
|
52
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { css } from 'decantr/css';\nimport { Card, Statistic, icon } from 'decantr/components';",
|
|
53
|
+
"example": "function StatCard({ title, stats }) {\n const { div, h3 } = tags;\n\n return Card({},\n Card.Header({},\n h3({ class: css('_heading5') }, icon('heart-pulse'), ` ${title}`)\n ),\n Card.Body({ class: css('_grid _gc2 _gap3') },\n Statistic({ label: 'Calories', value: 450, suffix: ' kcal' }),\n Statistic({ label: 'Protein', value: 32, suffix: 'g' }),\n Statistic({ label: 'Carbs', value: 48, suffix: 'g' }),\n Statistic({ label: 'Fat', value: 18, suffix: 'g' })\n )\n );\n}"
|
|
54
|
+
}
|
|
55
|
+
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v2.json",
|
|
3
|
+
"id": "stats-bar",
|
|
4
|
+
"name": "Stats Bar",
|
|
5
|
+
"description": "Horizontal stats row showing key metrics with icon + label + value pairs and action buttons. Used for recipe details, project summaries, and content metadata.",
|
|
6
|
+
"components": ["Button", "Separator", "Badge", "icon"],
|
|
7
|
+
"default_preset": "default",
|
|
8
|
+
"presets": {
|
|
9
|
+
"default": {
|
|
10
|
+
"description": "Horizontal row of icon + label + value pairs with action buttons on the right.",
|
|
11
|
+
"components": ["Button", "Separator", "Badge", "icon"],
|
|
12
|
+
"blend": {
|
|
13
|
+
"layout": "stack",
|
|
14
|
+
"atoms": "_flex _aic _jcsb _gap4 _py3 _px4 _borderb _bordert",
|
|
15
|
+
"slots": {
|
|
16
|
+
"stats": "Horizontal row of icon + label + value pairs separated by vertical Separators",
|
|
17
|
+
"actions": "Action buttons on the right side (bookmark, share, etc.)"
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"code": {
|
|
21
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { css } from 'decantr/css';\nimport { Button, Badge, Separator, icon } from 'decantr/components';",
|
|
22
|
+
"example": "function StatsBar({ stats, actions }) {\n const { div, span } = tags;\n\n const stat = (ic, label, value) =>\n div({ class: css('_flex _aic _gap2') },\n icon(ic),\n span({ class: css('_textsm _fgmuted') }, label),\n span({ class: css('_textsm _fontBold') }, value)\n );\n\n return div({ class: css('_flex _aic _jcsb _gap4 _py3 _px4 _bordert _borderb') },\n div({ class: css('_flex _aic _gap6') },\n stat('timer', 'Prep', '15 min'),\n Separator({ orientation: 'vertical' }),\n stat('flame', 'Cook', '30 min'),\n Separator({ orientation: 'vertical' }),\n stat('users', 'Servings', '4'),\n Separator({ orientation: 'vertical' }),\n Badge({ variant: 'success' }, 'Easy')\n ),\n div({ class: css('_flex _gap2') },\n Button({ variant: 'outline', size: 'sm' }, icon('git-fork'), 'Fork'),\n Button({ variant: 'outline', size: 'sm' }, icon('bookmark'), 'Save'),\n Button({ variant: 'outline', size: 'sm' }, icon('share'), 'Share')\n )\n );\n}"
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
"default_blend": {
|
|
27
|
+
"layout": "stack",
|
|
28
|
+
"atoms": "_flex _aic _jcsb _gap4 _py3 _px4 _borderb _bordert",
|
|
29
|
+
"slots": {
|
|
30
|
+
"stats": "Horizontal row of icon + label + value pairs",
|
|
31
|
+
"actions": "Action buttons"
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
"recipe_overrides": {
|
|
35
|
+
"command-center": {
|
|
36
|
+
"wrapper": "cc-bar",
|
|
37
|
+
"atoms": "",
|
|
38
|
+
"notes": "Stats use cc-data styling. Action buttons use cc-glow. Badge uses cc-label."
|
|
39
|
+
},
|
|
40
|
+
"auradecantism": {
|
|
41
|
+
"wrapper": "d-glass",
|
|
42
|
+
"atoms": "_r4",
|
|
43
|
+
"notes": "Stats bar on glass background. Values use d-gradient-text for emphasis."
|
|
44
|
+
},
|
|
45
|
+
"clean": {
|
|
46
|
+
"wrapper": "",
|
|
47
|
+
"atoms": "_bgmuted _r4",
|
|
48
|
+
"notes": "Simple bordered stats row on muted background. Standard icon + text pairs."
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
"code": {
|
|
52
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { css } from 'decantr/css';\nimport { Button, Badge, Separator, icon } from 'decantr/components';",
|
|
53
|
+
"example": "function StatsBar({ stats, actions }) {\n const { div, span } = tags;\n\n const stat = (ic, label, value) =>\n div({ class: css('_flex _aic _gap2') },\n icon(ic),\n span({ class: css('_textsm _fgmuted') }, label),\n span({ class: css('_textsm _fontBold') }, value)\n );\n\n return div({ class: css('_flex _aic _jcsb _gap4 _py3 _px4 _bordert _borderb') },\n div({ class: css('_flex _aic _gap6') },\n stat('timer', 'Prep', '15 min'),\n Separator({ orientation: 'vertical' }),\n stat('flame', 'Cook', '30 min')\n ),\n div({ class: css('_flex _gap2') },\n Button({ variant: 'outline', size: 'sm' }, icon('bookmark'), 'Save'),\n Button({ variant: 'outline', size: 'sm' }, icon('share'), 'Share')\n )\n );\n}"
|
|
54
|
+
}
|
|
55
|
+
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v2.json",
|
|
3
|
+
"id": "steps-card",
|
|
4
|
+
"name": "Steps Card",
|
|
5
|
+
"description": "Numbered step-by-step instructions displayed in a Card. Each step has a circle number badge, text content, and optional timer/metadata.",
|
|
6
|
+
"components": ["Card", "Card.Header", "Card.Body", "Badge", "icon"],
|
|
7
|
+
"default_preset": "default",
|
|
8
|
+
"presets": {
|
|
9
|
+
"default": {
|
|
10
|
+
"description": "Ordered list of steps, each with circle Badge number, text, and optional timer.",
|
|
11
|
+
"components": ["Card", "Card.Header", "Card.Body", "Badge", "icon"],
|
|
12
|
+
"blend": {
|
|
13
|
+
"layout": "stack",
|
|
14
|
+
"atoms": "_flex _col _gap0",
|
|
15
|
+
"slots": {
|
|
16
|
+
"header": "Card.Header with title and step count",
|
|
17
|
+
"steps": "Ordered list of steps, each with circle Badge number, text, and optional timer icon"
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"code": {
|
|
21
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { css } from 'decantr/css';\nimport { Card, Badge, icon } from 'decantr/components';",
|
|
22
|
+
"example": "function StepsCard({ title, steps }) {\n const { div, h3, p, span } = tags;\n\n return Card({},\n Card.Header({},\n div({ class: css('_flex _aic _jcsb') },\n h3({ class: css('_heading5') }, icon('chef-hat'), ` ${title}`),\n span({ class: css('_textsm _fgmuted') }, `${steps.length} steps`)\n )\n ),\n Card.Body({ class: css('_flex _col _gap4') },\n ...steps.map((step, i) =>\n div({ class: css('_flex _gap3') },\n Badge({ variant: 'outline', class: css('_rfull _w[32px] _h[32px] _flex _aic _jcc _shrink0') }, `${i + 1}`),\n div({ class: css('_flex _col _gap1 _flex1') },\n p({}, step.text),\n step.time ? span({ class: css('_textsm _fgmuted') }, icon('timer'), ` ${step.time} min`) : null\n )\n )\n )\n )\n );\n}"
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
"default_blend": {
|
|
27
|
+
"layout": "stack",
|
|
28
|
+
"atoms": "_flex _col _gap0",
|
|
29
|
+
"slots": {
|
|
30
|
+
"header": "Card.Header with title and step count",
|
|
31
|
+
"steps": "Ordered list of steps with numbered badges"
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
"recipe_overrides": {
|
|
35
|
+
"command-center": {
|
|
36
|
+
"wrapper": "cc-frame-sm",
|
|
37
|
+
"atoms": "",
|
|
38
|
+
"notes": "Card uses cc-frame-sm. Step badges use cc-glow. Timer indicators use cc-data."
|
|
39
|
+
},
|
|
40
|
+
"auradecantism": {
|
|
41
|
+
"wrapper": "d-glass",
|
|
42
|
+
"atoms": "_r4",
|
|
43
|
+
"notes": "Card on glass background. Step numbers use d-gradient-text. Active step highlighted."
|
|
44
|
+
},
|
|
45
|
+
"clean": {
|
|
46
|
+
"wrapper": "",
|
|
47
|
+
"atoms": "_b1 _r4",
|
|
48
|
+
"notes": "Simple bordered card. Circle number badges with muted background."
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
"code": {
|
|
52
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { css } from 'decantr/css';\nimport { Card, Badge, icon } from 'decantr/components';",
|
|
53
|
+
"example": "function StepsCard({ title, steps }) {\n const { div, h3, p, span } = tags;\n\n return Card({},\n Card.Header({},\n div({ class: css('_flex _aic _jcsb') },\n h3({ class: css('_heading5') }, icon('chef-hat'), ` ${title}`),\n span({ class: css('_textsm _fgmuted') }, `${steps.length} steps`)\n )\n ),\n Card.Body({ class: css('_flex _col _gap4') },\n ...steps.map((step, i) =>\n div({ class: css('_flex _gap3') },\n Badge({ variant: 'outline', class: css('_rfull _w[32px] _h[32px] _flex _aic _jcc _shrink0') }, `${i + 1}`),\n div({ class: css('_flex _col _gap1 _flex1') },\n p({}, step.text),\n step.time ? span({ class: css('_textsm _fgmuted') }, icon('timer'), ` ${step.time} min`) : null\n )\n )\n )\n )\n );\n}"
|
|
54
|
+
}
|
|
55
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v1.json",
|
|
3
|
+
"id": "table-of-contents",
|
|
4
|
+
"name": "Table of Contents",
|
|
5
|
+
"description": "Hierarchical content navigation with active state tracking and scroll spy.",
|
|
6
|
+
"components": ["List", "Link"],
|
|
7
|
+
"default_blend": {
|
|
8
|
+
"layout": "stack",
|
|
9
|
+
"atoms": "_flex _col _gap1 _sticky _top4",
|
|
10
|
+
"slots": {
|
|
11
|
+
"toc-list": "Nested list of section headings with indentation levels",
|
|
12
|
+
"toc-item": "Individual heading link with active state highlight"
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
"code": {
|
|
16
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { createSignal } from 'decantr/state';\nimport { css } from 'decantr/css';",
|
|
17
|
+
"example": "function TableOfContents() {\n const { nav, ul, li, a } = tags;\n const headings = [\n { id: 'introduction', text: 'Introduction' },\n { id: 'getting-started', text: 'Getting Started' },\n { id: 'configuration', text: 'Configuration' },\n { id: 'api-reference', text: 'API Reference' },\n { id: 'examples', text: 'Examples' }\n ];\n const [activeId] = createSignal('introduction');\n\n return nav({ class: css('_flex _col _gap1 _p4 _sticky _top0') },\n ul({ class: css('_flex _col _gap1 _borderL') },\n ...headings.map(h =>\n li({},\n a({\n href: `#${h.id}`,\n class: css(`_flex _py1 _pl4 _textsm _nounder _trans ${activeId() === h.id ? '_fgprimary _bold _borderL _bcprimary' : '_fgmuted'}`)\n }, h.text)\n )\n )\n )\n );\n}"
|
|
18
|
+
}
|
|
19
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v1.json",
|
|
3
|
+
"id": "testimonials",
|
|
4
|
+
"name": "Testimonials",
|
|
5
|
+
"description": "Customer testimonial cards in a responsive grid with avatar, quote, and attribution.",
|
|
6
|
+
"components": ["Card", "Avatar", "Badge", "Text"],
|
|
7
|
+
"default_blend": {
|
|
8
|
+
"layout": "grid",
|
|
9
|
+
"atoms": "_grid _gc3 _gap6 _py8",
|
|
10
|
+
"slots": {
|
|
11
|
+
"testimonial-card": "Card container for each testimonial entry",
|
|
12
|
+
"avatar": "Avatar image of the testimonial author",
|
|
13
|
+
"quote": "Quoted text content of the testimonial",
|
|
14
|
+
"attribution": "Author name, role, and optional company badge"
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
"code": {
|
|
18
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { css } from 'decantr/css';\nimport { Card, Avatar } from 'decantr/components';",
|
|
19
|
+
"example": "function Testimonials() {\n const { div, p, span } = tags;\n const items = [\n { quote: 'This product transformed our workflow completely.', avatar: '', name: 'Sarah Johnson', role: 'CTO at TechCorp' },\n { quote: 'The best investment we made this year.', avatar: '', name: 'Mike Chen', role: 'Product Lead at Acme' },\n { quote: 'Incredible support team and amazing features.', avatar: '', name: 'Lisa Park', role: 'Engineering Manager at Globex' }\n ];\n\n return div({ class: css('_grid _gc3 _gap4 _p4') },\n ...items.map(t =>\n Card({ class: css('_flex _col _gap4') },\n Card.Body({},\n p({ class: css('_italic _fgmuted') }, `\\\"${t.quote}\\\"`),\n div({ class: css('_flex _aic _gap3 _mt3') },\n Avatar({ src: t.avatar, name: t.name }),\n div({},\n span({ class: css('_textsm _bold') }, t.name),\n span({ class: css('_textxs _fgmuted _block') }, t.role)\n )\n )\n )\n )\n )\n );\n}"
|
|
20
|
+
}
|
|
21
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v1.json",
|
|
3
|
+
"id": "timeline",
|
|
4
|
+
"name": "Timeline",
|
|
5
|
+
"description": "Vertical timeline of events with dates, descriptions, and status icons. Used for changelogs, order tracking, project milestones, and historical records.",
|
|
6
|
+
"components": ["Timeline", "Card", "Card.Body", "Badge", "Avatar", "icon", "Separator"],
|
|
7
|
+
"default_blend": {
|
|
8
|
+
"layout": "stack",
|
|
9
|
+
"atoms": "_flex _flexCol _gap0 _p4 _relative",
|
|
10
|
+
"slots": {
|
|
11
|
+
"header": "Optional section title with _heading4 and date range filter",
|
|
12
|
+
"event": "Repeating item: icon dot on vertical line + Card with date (_caption cc-data), title (_heading6), description (_body), and optional Badge status",
|
|
13
|
+
"connector": "Vertical line connecting events via absolute-positioned border-left on the timeline track"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"recipe_overrides": {
|
|
17
|
+
"command-center": {
|
|
18
|
+
"wrapper": "cc-frame",
|
|
19
|
+
"atoms": "cc-scanline",
|
|
20
|
+
"notes": "Timeline connector line uses cc-glow subtle. Event dots use cc-glow for completed items. Dates use cc-data. Event titles use cc-label. Background uses cc-scanline."
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"code": {
|
|
24
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { css } from 'decantr/css';\nimport { Badge } from 'decantr/components';",
|
|
25
|
+
"example": "function TimelinePattern() {\n const { div, span, h4, p, time } = tags;\n const events = [\n { title: 'Project launched', status: 'completed', description: 'Initial release deployed to production.', date: 'Mar 1, 2026' },\n { title: 'Beta testing', status: 'completed', description: 'Invited 500 users for beta feedback.', date: 'Feb 15, 2026' },\n { title: 'Design review', status: 'completed', description: 'Final design review with stakeholders.', date: 'Feb 1, 2026' },\n { title: 'Development started', status: null, description: 'Sprint 1 kicked off with core features.', date: 'Jan 15, 2026' }\n ];\n\n return div({ class: css('_flex _col _gap0 _p4 _borderL _ml4') },\n ...events.map(e =>\n div({ class: css('_flex _gap4 _pb6 _relative') },\n div({ class: css('_absolute _left[-9px] _w[16px] _h[16px] _r[9999px] _bgprimary _b2 _bcborder') }),\n div({ class: css('_flex _col _gap1 _pl4') },\n div({ class: css('_flex _aic _gap2') },\n h4({ class: css('_textsm _bold') }, e.title),\n e.status ? Badge({ variant: e.status === 'completed' ? 'success' : 'default', size: 'sm' }, e.status) : null\n ),\n p({ class: css('_textsm _fgmuted') }, e.description),\n time({ class: css('_textxs _fgmuted') }, e.date)\n )\n )\n )\n );\n}"
|
|
26
|
+
}
|
|
27
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v1.json",
|
|
3
|
+
"id": "token-inspector",
|
|
4
|
+
"name": "Token Inspector",
|
|
5
|
+
"description": "Live design token visualization grouped by category — color swatches, typography samples, spacing bars, elevation boxes. Values update reactively when style or mode changes.",
|
|
6
|
+
"components": ["Card", "Separator"],
|
|
7
|
+
"default_blend": {
|
|
8
|
+
"layout": "stack",
|
|
9
|
+
"atoms": "_flex _col _gap8",
|
|
10
|
+
"slots": {
|
|
11
|
+
"section-block": "Per-category section with title and rendered token visualizations",
|
|
12
|
+
"swatch-grid": "Grid of color swatches for palette/neutral/surface tokens",
|
|
13
|
+
"type-samples": "Stacked typography samples at each scale",
|
|
14
|
+
"spacing-bars": "Horizontal bars showing spacing token values"
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
"code": {
|
|
18
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { css } from 'decantr/css';\nimport { Card } from 'decantr/components';",
|
|
19
|
+
"example": "function TokenInspector() {\n const { div, span, code } = tags;\n const tokens = {\n 'Colors': [\n { variable: '--d-primary', computed: '#6366f1' },\n { variable: '--d-secondary', computed: '#8b5cf6' },\n { variable: '--d-bg', computed: '#09090b' },\n { variable: '--d-fg', computed: '#fafafa' }\n ],\n 'Surfaces': [\n { variable: '--d-surface-0', computed: '#18181b' },\n { variable: '--d-surface-1', computed: '#27272a' },\n { variable: '--d-surface-2', computed: '#3f3f46' }\n ]\n };\n\n return div({ class: css('_flex _col _gap4 _p4') },\n ...Object.entries(tokens).map(([category, items]) =>\n div({ class: css('_flex _col _gap2') },\n span({ class: css('_heading5') }, category),\n div({ class: css('_grid _gc3 _gap3') },\n ...items.map(t =>\n Card({ class: css('_flex _aic _gap3 _p3') },\n div({ class: css('_w[40px] _h[40px] _r4 _b1'), style: `background:var(${t.variable})` }),\n div({ class: css('_flex _col') },\n code({ class: css('_textsm _fontmono') }, t.variable),\n span({ class: css('_textxs _fgmuted') }, t.computed)\n )\n )\n )\n )\n )\n )\n );\n}"
|
|
20
|
+
}
|
|
21
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/pattern.v1.json",
|
|
3
|
+
"id": "wizard",
|
|
4
|
+
"name": "Wizard",
|
|
5
|
+
"description": "Multi-step form with progress indicator and prev/next navigation. Each step contains a form section with validation before advancing.",
|
|
6
|
+
"components": ["Button", "Progress", "Input", "Select", "Checkbox", "Switch", "Separator"],
|
|
7
|
+
"default_blend": {
|
|
8
|
+
"layout": "stack",
|
|
9
|
+
"atoms": "_flex _flexCol _gap6 _p6 _mxAuto",
|
|
10
|
+
"slots": {
|
|
11
|
+
"progress": "Step indicator using Progress or numbered Breadcrumb-style dots with _flex _gap2 _justifyCenter",
|
|
12
|
+
"step-content": "Active step form fields, swapped via cond(). Each step is a form-sections pattern subset",
|
|
13
|
+
"navigation": "Bottom bar with prev/next Buttons via _flex _justifyBetween, separated by Separator"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"recipe_overrides": {
|
|
17
|
+
"command-center": {
|
|
18
|
+
"wrapper": "cc-frame",
|
|
19
|
+
"atoms": "cc-grid",
|
|
20
|
+
"notes": "Step indicator uses cc-bar with cc-data for step numbers. Active step gets cc-glow. Navigation bar uses cc-bar. Background uses cc-grid."
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"code": {
|
|
24
|
+
"imports": "import { tags } from 'decantr/tags';\nimport { createSignal } from 'decantr/state';\nimport { css } from 'decantr/css';\nimport { Steps, Button, Card } from 'decantr/components';",
|
|
25
|
+
"example": "function Wizard() {\n const { div, p } = tags;\n const steps = [\n { title: 'Account', content: () => div({ class: css('_flex _col _gap3 _p4') }, p({}, 'Enter your account details.')) },\n { title: 'Profile', content: () => div({ class: css('_flex _col _gap3 _p4') }, p({}, 'Complete your profile information.')) },\n { title: 'Confirm', content: () => div({ class: css('_flex _col _gap3 _p4') }, p({}, 'Review and confirm your details.')) }\n ];\n const [current, setCurrent] = createSignal(0);\n\n return Card({ class: css('_flex _col _gap6 _p6') },\n Steps({ current: current, items: steps.map(s => ({ title: s.title })) }),\n div({ class: css('_flex _col _gap4 _py4') },\n steps[current()]?.content()\n ),\n div({ class: css('_flex _jcsb') },\n current() > 0\n ? Button({ variant: 'outline', onclick: () => setCurrent(current() - 1) }, 'Back')\n : div(),\n current() < steps.length - 1\n ? Button({ variant: 'primary', onclick: () => setCurrent(current() + 1) }, 'Next')\n : Button({ variant: 'primary', onclick: () => {} }, 'Submit')\n )\n );\n}"
|
|
26
|
+
}
|
|
27
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://decantr.ai/schemas/recipe.v1.json",
|
|
3
|
+
"id": "auradecantism",
|
|
4
|
+
"name": "Auradecantism",
|
|
5
|
+
"style": "auradecantism",
|
|
6
|
+
"mode": "dark",
|
|
7
|
+
"description": "Luminous glass visual language. Mesh gradient backgrounds, frosted glass surfaces, gradient text, vibrant purple/cyan/pink palette, pill radius, bouncy motion. The signature Decantr aesthetic.",
|
|
8
|
+
"setup": "import { setStyle, setMode } from 'decantr/css';\nsetStyle('auradecantism');\nsetMode('dark');",
|
|
9
|
+
"decorators": {
|
|
10
|
+
"d-mesh": "Radial mesh gradient background with pink, cyan, and purple overlays. Apply to page-level containers.",
|
|
11
|
+
"d-glass": "Frosted glass panel — backdrop-blur, semi-transparent bg, subtle border highlight. Apply to cards and panels.",
|
|
12
|
+
"d-glass-strong": "Stronger glass effect with more opacity and thicker blur. For elevated overlays and modals.",
|
|
13
|
+
"d-gradient-text": "Gradient text using primary brand colors (pink → cyan). Apply to headings and hero text.",
|
|
14
|
+
"d-gradient-text-alt": "Alternate gradient text (purple → pink → cyan). For secondary headings and accents.",
|
|
15
|
+
"aura-glow": "Soft glow shadow using primary color. Apply to featured cards or active elements.",
|
|
16
|
+
"aura-glow-strong": "Intense glow for hero KPIs and primary CTAs. 20px spread.",
|
|
17
|
+
"aura-ring": "Animated ring highlight on focus/active state. Pill-shaped glow border.",
|
|
18
|
+
"aura-orb": "Floating decorative gradient orb. Position absolutely as background decoration.",
|
|
19
|
+
"aura-shimmer": "Subtle shimmer animation across surface. Use sparingly for loading or premium feel."
|
|
20
|
+
},
|
|
21
|
+
"compositions": {
|
|
22
|
+
"panel": {
|
|
23
|
+
"description": "Glass panel with subtle border and backdrop blur.",
|
|
24
|
+
"example": "const { div, span } = tags;\ndiv({ class: css('d-glass _r4 _p0') },\n div({ class: css('_flex _aic _jcsb _px4 _py3 _borderB') },\n span({ class: css('_textsm _bold _fgmutedfg') }, 'PANEL TITLE')\n ),\n div({ class: css('_p4') },\n // content here\n )\n)"
|
|
25
|
+
},
|
|
26
|
+
"card": {
|
|
27
|
+
"wraps": "Card",
|
|
28
|
+
"description": "Card with glass surface and glow on hover.",
|
|
29
|
+
"example": "const { div } = tags;\ndiv({ class: css('d-glass _r4') },\n Card({},\n Card.Header({},\n span({ class: css('_heading5') }, 'Feature')\n ),\n Card.Body({},\n p({ class: css('_fgmuted') }, 'Description text here')\n )\n )\n)"
|
|
30
|
+
},
|
|
31
|
+
"kpi": {
|
|
32
|
+
"wraps": "Statistic",
|
|
33
|
+
"description": "KPI metric with glass background and gradient value text.",
|
|
34
|
+
"example": "const { div, span } = tags;\ndiv({ class: css('d-glass _r4 _p4') },\n Statistic({\n label: 'Total Revenue',\n value: 2450000,\n prefix: '$',\n trend: 'up',\n trendValue: '+18.2%',\n class: css('_bg[transparent]')\n }),\n span({ class: css('d-gradient-text _textxs _bold') }, 'ALL TIME HIGH')\n)"
|
|
35
|
+
},
|
|
36
|
+
"table": {
|
|
37
|
+
"wraps": "DataTable",
|
|
38
|
+
"description": "DataTable with glass wrapper and subtle border.",
|
|
39
|
+
"example": "const { div, span } = tags;\ndiv({ class: css('d-glass _r4 _overflow[hidden]') },\n div({ class: css('_flex _aic _jcsb _px4 _py3 _borderB') },\n span({ class: css('_heading5') }, 'Transactions'),\n span({ class: css('_textsm _fgmuted') }, '248 records')\n ),\n DataTable({ columns, data, sortable: true, paginate: true })\n)"
|
|
40
|
+
},
|
|
41
|
+
"form": {
|
|
42
|
+
"description": "Form in a glass card with gradient submit button.",
|
|
43
|
+
"example": "const { div, h2 } = tags;\ndiv({ class: css('d-glass _r4 _p6 _flex _col _gap4') },\n h2({ class: css('d-gradient-text _heading4') }, 'Sign In'),\n Input({ label: 'Email', type: 'email' }),\n Input({ label: 'Password', type: 'password' }),\n Button({ variant: 'primary', class: css('_wfull') }, 'Continue')\n)"
|
|
44
|
+
},
|
|
45
|
+
"sidebar": {
|
|
46
|
+
"description": "Glass sidebar with gradient brand and nav items.",
|
|
47
|
+
"example": "const { div, aside, nav, span } = tags;\naside({ class: css('d-glass _flex _col _h[100vh] _w[240px] _borderR _p3') },\n span({ class: css('d-gradient-text _heading5 _mb6 _px3') }, 'Brand'),\n nav({ class: css('_flex _col _gap1') },\n // nav items with icon + label, _p2 _px3 _r4 _trans\n )\n)"
|
|
48
|
+
},
|
|
49
|
+
"layout": {
|
|
50
|
+
"description": "Full page layout with mesh background, glass sidebar, and content area.",
|
|
51
|
+
"example": "const { div, main, header, span } = tags;\ndiv({ class: css('d-mesh _grid _h[100vh]'), style: 'grid-template-columns:240px 1fr' },\n // glass sidebar\n // ...,\n div({ class: css('_flex _col _overflow[hidden]') },\n header({ class: css('_flex _aic _jcsb _px6 _py3 _borderB d-glass') },\n span({ class: css('_heading4') }, 'Dashboard')\n ),\n main({ class: css('_flex _col _gap4 _p6 _overflow[auto]') },\n // page content\n )\n )\n)"
|
|
52
|
+
},
|
|
53
|
+
"alert": {
|
|
54
|
+
"wraps": "Alert",
|
|
55
|
+
"description": "Alert with glass background.",
|
|
56
|
+
"example": "const { div } = tags;\ndiv({ class: css('d-glass _r4') },\n Alert({ variant: 'info' },\n 'Your subscription renews in 3 days.'\n )\n)"
|
|
57
|
+
},
|
|
58
|
+
"modal": {
|
|
59
|
+
"wraps": "Modal",
|
|
60
|
+
"description": "Modal with strong glass backdrop and gradient title.",
|
|
61
|
+
"example": "const { div, h2 } = tags;\nModal({\n visible: showModal,\n onClose: () => setShowModal(false),\n class: css('d-glass-strong _r4')\n},\n h2({ class: css('d-gradient-text _heading4 _mb4') }, 'Confirm'),\n div({ class: css('_flex _col _gap4 _p4') },\n // modal content\n )\n)"
|
|
62
|
+
},
|
|
63
|
+
"chart": {
|
|
64
|
+
"wraps": "Chart",
|
|
65
|
+
"description": "Chart in glass panel with gradient title.",
|
|
66
|
+
"example": "const { div, span } = tags;\ndiv({ class: css('d-glass _r4 _overflow[hidden]') },\n div({ class: css('_flex _aic _jcsb _px4 _py3 _borderB') },\n span({ class: css('d-gradient-text _bold') }, 'Revenue Trend'),\n span({ class: css('_textxs _fgmuted') }, 'Last 30 days')\n ),\n Chart({ type: 'area', data: revenueData, x: 'date', y: 'amount', height: 300 })\n)"
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}
|