@nexus-cross/design-system 1.0.13 → 1.1.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/claude-rules/nexus/CLAUDE.md +85 -0
- package/claude-rules/nexus/commands/nexus-audit.md +79 -0
- package/claude-rules/nexus/commands/nexus-component-map.md +85 -0
- package/claude-rules/nexus/commands/nexus-token-check.md +68 -0
- package/claude-rules/nexus/skills/nexus-design-system/SKILL.md +92 -0
- package/cursor-rules/nexus-ui-api.mdc +824 -41
- package/cursor-rules/nexus-ui-decisions.mdc +259 -0
- package/dist/accordion.js +0 -1
- package/dist/accordion.mjs +0 -1
- package/dist/alert.js +0 -1
- package/dist/alert.mjs +0 -1
- package/dist/avatar.js +0 -1
- package/dist/avatar.mjs +0 -1
- package/dist/badge.js +0 -1
- package/dist/badge.mjs +0 -1
- package/dist/breadcrumb.js +0 -1
- package/dist/breadcrumb.mjs +0 -1
- package/dist/button.js +0 -1
- package/dist/button.mjs +0 -1
- package/dist/carousel.js +0 -1
- package/dist/carousel.mjs +0 -1
- package/dist/checkbox.js +0 -1
- package/dist/checkbox.mjs +0 -1
- package/dist/chip.js +0 -1
- package/dist/chip.mjs +0 -1
- package/dist/chunks/chunk-2Z52NPWB.js +78 -0
- package/dist/chunks/chunk-46P52MFM.mjs +56 -0
- package/dist/chunks/{chunk-X3CTJ7TD.js → chunk-4KBFVIKX.js} +41 -11
- package/dist/chunks/chunk-56ZOOQFE.mjs +514 -0
- package/dist/chunks/chunk-5ASTWFJW.js +538 -0
- package/dist/chunks/{chunk-33UFQJIO.mjs → chunk-BJMXZJWO.mjs} +16 -5
- package/dist/chunks/chunk-EILXBLEV.mjs +5 -0
- package/dist/chunks/chunk-G3RLK2HS.js +7 -0
- package/dist/chunks/{chunk-YZV6FWE7.js → chunk-JLDQNDFT.js} +16 -5
- package/dist/chunks/{chunk-K574BYHQ.js → chunk-K3CK7NTP.js} +22 -4
- package/dist/chunks/{chunk-Z4YM7LU3.mjs → chunk-PIGHBDK5.mjs} +22 -4
- package/dist/chunks/{chunk-PEIEVKD5.js → chunk-RCIBLLSF.js} +11 -12
- package/dist/chunks/{chunk-MMCA33FW.mjs → chunk-RSFLNWOM.mjs} +41 -11
- package/dist/chunks/{chunk-K2TBLM3F.mjs → chunk-THBE27U3.mjs} +11 -12
- package/dist/client-only.js +0 -1
- package/dist/client-only.mjs +0 -1
- package/dist/combobox.js +16 -0
- package/dist/combobox.mjs +3 -0
- package/dist/components/Combobox.d.ts +48 -0
- package/dist/components/Combobox.d.ts.map +1 -0
- package/dist/components/DataGrid.d.ts +44 -0
- package/dist/components/DataGrid.d.ts.map +1 -0
- package/dist/components/DataList.d.ts +3 -1
- package/dist/components/DataList.d.ts.map +1 -1
- package/dist/components/RadioGroup.d.ts +4 -0
- package/dist/components/RadioGroup.d.ts.map +1 -1
- package/dist/components/Stepper.d.ts.map +1 -1
- package/dist/components/ToggleGroup.d.ts +2 -1
- package/dist/components/ToggleGroup.d.ts.map +1 -1
- package/dist/countdown.js +0 -1
- package/dist/countdown.mjs +0 -1
- package/dist/counter.js +0 -1
- package/dist/counter.mjs +0 -1
- package/dist/data-grid.js +14 -0
- package/dist/data-grid.mjs +5 -0
- package/dist/data-list.js +2 -3
- package/dist/data-list.mjs +1 -2
- package/dist/date-picker.js +0 -1
- package/dist/date-picker.mjs +0 -1
- package/dist/divider.js +0 -1
- package/dist/divider.mjs +0 -1
- package/dist/drawer.js +0 -1
- package/dist/drawer.mjs +0 -1
- package/dist/dropdown-menu.js +0 -1
- package/dist/dropdown-menu.mjs +0 -1
- package/dist/ellipsis.js +0 -1
- package/dist/ellipsis.mjs +0 -1
- package/dist/empty-state.js +0 -1
- package/dist/empty-state.mjs +0 -1
- package/dist/error-boundary.js +0 -1
- package/dist/error-boundary.mjs +0 -1
- package/dist/hooks/useCheckDevice.js +0 -1
- package/dist/hooks/useCheckDevice.mjs +0 -1
- package/dist/hooks/useClickOutside.js +0 -1
- package/dist/hooks/useClickOutside.mjs +0 -1
- package/dist/hooks/useDraggableBottomSheet.js +0 -1
- package/dist/hooks/useDraggableBottomSheet.mjs +0 -1
- package/dist/hooks/useDraggableWindow.js +0 -1
- package/dist/hooks/useDraggableWindow.mjs +0 -1
- package/dist/hooks/useInView.js +0 -1
- package/dist/hooks/useInView.mjs +0 -1
- package/dist/hooks/useModal.js +0 -1
- package/dist/hooks/useModal.mjs +0 -1
- package/dist/image-upload.js +0 -1
- package/dist/image-upload.mjs +0 -1
- package/dist/index.d.ts +4 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +92 -88
- package/dist/index.mjs +12 -12
- package/dist/infinite-scroll.js +0 -1
- package/dist/infinite-scroll.mjs +0 -1
- package/dist/marquee.js +0 -1
- package/dist/marquee.mjs +0 -1
- package/dist/modal/index.js +11 -12
- package/dist/modal/index.mjs +2 -3
- package/dist/number-input.js +0 -1
- package/dist/number-input.mjs +0 -1
- package/dist/nx-image.js +0 -1
- package/dist/nx-image.mjs +0 -1
- package/dist/pagination.js +0 -1
- package/dist/pagination.mjs +0 -1
- package/dist/popover.js +0 -1
- package/dist/popover.mjs +0 -1
- package/dist/price-input.js +0 -1
- package/dist/price-input.mjs +0 -1
- package/dist/progress.js +0 -1
- package/dist/progress.mjs +0 -1
- package/dist/radio-group.js +5 -6
- package/dist/radio-group.mjs +1 -2
- package/dist/schemas/_all.json +308 -117
- package/dist/schemas/accordion.d.ts.map +1 -1
- package/dist/schemas/accordion.json +1 -1
- package/dist/schemas/alert.d.ts.map +1 -1
- package/dist/schemas/alert.json +1 -1
- package/dist/schemas/avatar.d.ts.map +1 -1
- package/dist/schemas/avatar.json +1 -1
- package/dist/schemas/badge.d.ts.map +1 -1
- package/dist/schemas/badge.json +1 -1
- package/dist/schemas/breadcrumb.d.ts.map +1 -1
- package/dist/schemas/breadcrumb.json +1 -1
- package/dist/schemas/button.d.ts.map +1 -1
- package/dist/schemas/button.json +1 -1
- package/dist/schemas/carousel.d.ts.map +1 -1
- package/dist/schemas/carousel.json +1 -1
- package/dist/schemas/checkBox.json +1 -1
- package/dist/schemas/checkbox.d.ts.map +1 -1
- package/dist/schemas/chip.d.ts.map +1 -1
- package/dist/schemas/chip.json +1 -1
- package/dist/schemas/client-only.d.ts.map +1 -1
- package/dist/schemas/clientOnly.json +1 -1
- package/dist/schemas/combobox.d.ts +85 -0
- package/dist/schemas/combobox.d.ts.map +1 -0
- package/dist/schemas/combobox.json +98 -0
- package/dist/schemas/comboboxOption.json +30 -0
- package/dist/schemas/countdown.d.ts.map +1 -1
- package/dist/schemas/countdown.json +1 -1
- package/dist/schemas/counter.d.ts.map +1 -1
- package/dist/schemas/counter.json +1 -1
- package/dist/schemas/data-grid.d.ts +74 -0
- package/dist/schemas/data-grid.d.ts.map +1 -0
- package/dist/schemas/data-list.d.ts.map +1 -1
- package/dist/schemas/dataGrid.json +102 -0
- package/dist/schemas/dataList.json +1 -1
- package/dist/schemas/date-picker.d.ts.map +1 -1
- package/dist/schemas/datePicker.json +1 -1
- package/dist/schemas/divider.d.ts.map +1 -1
- package/dist/schemas/divider.json +1 -1
- package/dist/schemas/drawer.d.ts.map +1 -1
- package/dist/schemas/drawer.json +1 -1
- package/dist/schemas/dropdown-menu.d.ts.map +1 -1
- package/dist/schemas/dropdownMenu.json +1 -1
- package/dist/schemas/ellipsis.d.ts.map +1 -1
- package/dist/schemas/ellipsis.json +1 -1
- package/dist/schemas/empty-state.d.ts.map +1 -1
- package/dist/schemas/emptyState.json +1 -1
- package/dist/schemas/error-boundary.d.ts.map +1 -1
- package/dist/schemas/errorBoundary.json +1 -1
- package/dist/schemas/image-upload.d.ts.map +1 -1
- package/dist/schemas/imageUpload.json +1 -1
- package/dist/schemas/index.d.ts +2 -1
- package/dist/schemas/index.d.ts.map +1 -1
- package/dist/schemas/infinite-scroll.d.ts.map +1 -1
- package/dist/schemas/infiniteScroll.json +1 -1
- package/dist/schemas/marquee.d.ts.map +1 -1
- package/dist/schemas/marquee.json +1 -1
- package/dist/schemas/modal.d.ts.map +1 -1
- package/dist/schemas/modalTemplate.json +1 -1
- package/dist/schemas/number-input.d.ts.map +1 -1
- package/dist/schemas/numberInput.json +1 -1
- package/dist/schemas/nx-image.d.ts.map +1 -1
- package/dist/schemas/nxImage.json +1 -1
- package/dist/schemas/pagination.d.ts.map +1 -1
- package/dist/schemas/pagination.json +1 -1
- package/dist/schemas/popover.d.ts.map +1 -1
- package/dist/schemas/popover.json +1 -1
- package/dist/schemas/price-input.d.ts.map +1 -1
- package/dist/schemas/priceInput.json +1 -1
- package/dist/schemas/progress.d.ts.map +1 -1
- package/dist/schemas/progress.json +1 -1
- package/dist/schemas/radio-group.d.ts +9 -0
- package/dist/schemas/radio-group.d.ts.map +1 -1
- package/dist/schemas/radioGroup.json +10 -1
- package/dist/schemas/radioItem.json +11 -0
- package/dist/schemas/select.d.ts.map +1 -1
- package/dist/schemas/select.json +1 -1
- package/dist/schemas/skeleton.d.ts.map +1 -1
- package/dist/schemas/skeleton.json +1 -1
- package/dist/schemas/slider.d.ts.map +1 -1
- package/dist/schemas/slider.json +1 -1
- package/dist/schemas/spinner.d.ts.map +1 -1
- package/dist/schemas/spinner.json +1 -1
- package/dist/schemas/stepper.d.ts.map +1 -1
- package/dist/schemas/stepper.json +1 -1
- package/dist/schemas/switch.d.ts.map +1 -1
- package/dist/schemas/switch.json +1 -1
- package/dist/schemas/tab.d.ts.map +1 -1
- package/dist/schemas/tab.json +1 -1
- package/dist/schemas/table.d.ts.map +1 -1
- package/dist/schemas/table.json +1 -1
- package/dist/schemas/tableRow.json +1 -1
- package/dist/schemas/tag-input.d.ts.map +1 -1
- package/dist/schemas/tagInput.json +1 -1
- package/dist/schemas/tdColumn.json +1 -1
- package/dist/schemas/text-area.d.ts.map +1 -1
- package/dist/schemas/text-input.d.ts +2 -2
- package/dist/schemas/text-input.d.ts.map +1 -1
- package/dist/schemas/textArea.json +1 -1
- package/dist/schemas/textInput.json +1 -1
- package/dist/schemas/toast.d.ts.map +1 -1
- package/dist/schemas/toastOptions.json +1 -1
- package/dist/schemas/toaster.json +1 -1
- package/dist/schemas/toggle-group.d.ts +6 -3
- package/dist/schemas/toggle-group.d.ts.map +1 -1
- package/dist/schemas/toggleGroup.json +9 -3
- package/dist/schemas/tooltip.d.ts.map +1 -1
- package/dist/schemas/tooltip.json +1 -1
- package/dist/schemas/virtual-scroll.d.ts.map +1 -1
- package/dist/schemas/virtualGrid.json +1 -1
- package/dist/schemas/virtualList.json +1 -1
- package/dist/schemas.js +867 -66
- package/dist/schemas.mjs +865 -66
- package/dist/select.js +0 -1
- package/dist/select.mjs +0 -1
- package/dist/skeleton.js +0 -1
- package/dist/skeleton.mjs +0 -1
- package/dist/slider.js +0 -1
- package/dist/slider.mjs +0 -1
- package/dist/spinner.js +0 -1
- package/dist/spinner.mjs +0 -1
- package/dist/stepper.js +3 -4
- package/dist/stepper.mjs +1 -2
- package/dist/styles/.generated/built.d.ts +1 -1
- package/dist/styles/.generated/built.d.ts.map +1 -1
- package/dist/styles/layer.js +2 -3
- package/dist/styles/layer.mjs +1 -2
- package/dist/styles.css +554 -51
- package/dist/styles.js +2 -3
- package/dist/styles.layered.css +554 -51
- package/dist/styles.mjs +1 -2
- package/dist/switch.js +0 -1
- package/dist/switch.mjs +0 -1
- package/dist/tab.js +0 -1
- package/dist/tab.mjs +0 -1
- package/dist/table.js +0 -1
- package/dist/table.mjs +0 -1
- package/dist/tag-input.js +0 -1
- package/dist/tag-input.mjs +0 -1
- package/dist/text-area.js +0 -1
- package/dist/text-area.mjs +0 -1
- package/dist/text-input.js +0 -1
- package/dist/text-input.mjs +0 -1
- package/dist/toast.js +0 -1
- package/dist/toast.mjs +0 -1
- package/dist/toggle-group.js +3 -4
- package/dist/toggle-group.mjs +1 -2
- package/dist/tooltip.js +0 -1
- package/dist/tooltip.mjs +0 -1
- package/dist/utils/cn.js +0 -1
- package/dist/utils/cn.mjs +0 -1
- package/dist/utils/scroll.js +0 -1
- package/dist/utils/scroll.mjs +0 -1
- package/dist/virtual-scroll.js +0 -1
- package/dist/virtual-scroll.mjs +0 -1
- package/package.json +14 -8
- package/scripts/setup-cursor-rules.cjs +164 -27
- package/dist/chunks/chunk-22ULI3BF.js +0 -21
- package/dist/chunks/chunk-6ECGMUT6.mjs +0 -5
- package/dist/chunks/chunk-CVYXRSXT.mjs +0 -8
- package/dist/chunks/chunk-I252NERB.mjs +0 -21
- package/dist/chunks/chunk-JNMCYWGY.js +0 -10
- package/dist/chunks/chunk-V35IEPRL.js +0 -7
- package/dist/components/ThemeProvider.d.ts +0 -25
- package/dist/components/ThemeProvider.d.ts.map +0 -1
- package/dist/schemas/theme-provider.d.ts +0 -36
- package/dist/schemas/theme-provider.d.ts.map +0 -1
- package/dist/schemas/themeProvider.json +0 -65
- package/dist/theme-provider.js +0 -15
- package/dist/theme-provider.mjs +0 -2
- package/dist/chunks/{chunk-CWMLTXOH.mjs → chunk-5ZVPTIL3.mjs} +1 -1
- package/dist/chunks/{chunk-HFBTS42N.js → chunk-7F4SOLAC.js} +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-area.d.ts","sourceRoot":"","sources":["../../src/schemas/text-area.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"text-area.d.ts","sourceRoot":"","sources":["../../src/schemas/text-area.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAyC7B,CAAC"}
|
|
@@ -42,13 +42,13 @@ export declare const textInputPropsSchema: z.ZodObject<{
|
|
|
42
42
|
onChange?: any;
|
|
43
43
|
onValueChange?: any;
|
|
44
44
|
placeholder?: string | undefined;
|
|
45
|
+
clearable?: boolean | undefined;
|
|
45
46
|
autoComplete?: string | undefined;
|
|
46
47
|
maxLength?: number | undefined;
|
|
47
48
|
readOnly?: boolean | undefined;
|
|
48
49
|
prefixIcon?: any;
|
|
49
50
|
suffixIcon?: any;
|
|
50
51
|
showCount?: boolean | undefined;
|
|
51
|
-
clearable?: boolean | undefined;
|
|
52
52
|
}, {
|
|
53
53
|
name?: string | undefined;
|
|
54
54
|
className?: string | undefined;
|
|
@@ -67,12 +67,12 @@ export declare const textInputPropsSchema: z.ZodObject<{
|
|
|
67
67
|
onChange?: any;
|
|
68
68
|
onValueChange?: any;
|
|
69
69
|
placeholder?: string | undefined;
|
|
70
|
+
clearable?: boolean | undefined;
|
|
70
71
|
autoComplete?: string | undefined;
|
|
71
72
|
maxLength?: number | undefined;
|
|
72
73
|
readOnly?: boolean | undefined;
|
|
73
74
|
prefixIcon?: any;
|
|
74
75
|
suffixIcon?: any;
|
|
75
76
|
showCount?: boolean | undefined;
|
|
76
|
-
clearable?: boolean | undefined;
|
|
77
77
|
}>;
|
|
78
78
|
//# sourceMappingURL=text-input.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-input.d.ts","sourceRoot":"","sources":["../../src/schemas/text-input.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"text-input.d.ts","sourceRoot":"","sources":["../../src/schemas/text-input.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAwC9B,CAAC"}
|
|
@@ -95,7 +95,7 @@
|
|
|
95
95
|
}
|
|
96
96
|
},
|
|
97
97
|
"additionalProperties": false,
|
|
98
|
-
"description": "Multi-line text input
|
|
98
|
+
"description": "Multi-line text input. Always prefer over native <textarea>.\n\nWHEN TO USE:\n • Long-form text — comments, descriptions, memos, bios\n • Single-line input → TextInput\n • Numeric → NumberInput\n\nresize=\"auto\" auto-grows with content (great for chat input). resize=\"none\" locks size for fixed UI.\n\nANTI-PATTERNS:\n ✗ Native <textarea> + custom counter → showCount + maxLength\n ✗ <TextArea> for short labels — use TextInput (smaller affordance)\n ✗ Wrapping with custom <label>/<p> → use built-in label/description props (auto a11y binding)"
|
|
99
99
|
}
|
|
100
100
|
},
|
|
101
101
|
"$schema": "http://json-schema.org/draft-07/schema#"
|
|
@@ -100,7 +100,7 @@
|
|
|
100
100
|
}
|
|
101
101
|
},
|
|
102
102
|
"additionalProperties": false,
|
|
103
|
-
"description": "
|
|
103
|
+
"description": "Single-line text input (always prefer over native <input type=\"text\">).\n\nWHEN TO USE: any short text — name, email, search, URL, password.\nUse the built-in label/description props instead of wrapping with your own <label>/<p> tags (auto-binds htmlFor/aria-describedby for accessibility).\nFor numeric input use NumberInput; for currency PriceInput; for long text TextArea; for date DatePicker.\n\nANTI-PATTERNS:\n ✗ <TextInput type=\"number\"> → <NumberInput> (gives unit, step, ↑↓ keys)\n ✗ <label>Email <input ...></label> + <p>helper</p> → <TextInput label=\"Email\" description=\"helper\">\n ✗ Custom red border for error → use error prop (auto aria-invalid + token color)\n ✗ Manual character counter → use showCount + maxLength\n ✗ Manual clear X button → use clearable prop"
|
|
104
104
|
}
|
|
105
105
|
},
|
|
106
106
|
"$schema": "http://json-schema.org/draft-07/schema#"
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toast.d.ts","sourceRoot":"","sources":["../../src/schemas/toast.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"toast.d.ts","sourceRoot":"","sources":["../../src/schemas/toast.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAyF5B,CAAC;AAEJ,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAkE5B,CAAC"}
|
|
@@ -74,7 +74,7 @@
|
|
|
74
74
|
}
|
|
75
75
|
},
|
|
76
76
|
"additionalProperties": false,
|
|
77
|
-
"description": "toast()
|
|
77
|
+
"description": "toast() options. Used as toast(message, options) / toast.success / .error / .warning / .info / .promise / .custom(jsx).\n\nWHEN TO USE TOAST:\n • Transient feedback after user action: \"Saved\", \"Copied\", \"Network error\"\n • Persistent in-page banner → Alert\n • Critical destructive confirmation → Modal (toast can be missed)\n • Form field error → use error/description prop on the input\n\nrichColors=true gives strong success/error/warning/info colors. Use action for \"Undo\" patterns.\n\nANTI-PATTERNS:\n ✗ Toast for confirmation that user MUST acknowledge → Modal\n ✗ Stacking many toasts → set visibleToasts on Toaster\n ✗ Long-form content in toast (toast is for short messages)"
|
|
78
78
|
}
|
|
79
79
|
},
|
|
80
80
|
"$schema": "http://json-schema.org/draft-07/schema#"
|
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
}
|
|
70
70
|
},
|
|
71
71
|
"additionalProperties": false,
|
|
72
|
-
"description": "Toaster
|
|
72
|
+
"description": "Toaster — toast container. Mount ONCE at app root. Then call toast() anywhere. Based on sonner.\n\nWHEN TO USE:\n • Mount in app shell (layout.tsx / _app.tsx) — exactly one instance globally\n • Set position once here; per-toast position only when needed\n • Provide visibleToasts cap to avoid stacking\n\nANTI-PATTERNS:\n ✗ Multiple Toasters across pages — only one global Toaster\n ✗ Mounting Toaster inside conditional render — toasts vanish on remount\n ✗ Forgetting Toaster mount — toast() calls do nothing"
|
|
73
73
|
}
|
|
74
74
|
},
|
|
75
75
|
"$schema": "http://json-schema.org/draft-07/schema#"
|
|
@@ -23,15 +23,16 @@ export declare const toggleGroupPropsSchema: z.ZodObject<{
|
|
|
23
23
|
value: z.ZodOptional<z.ZodAny>;
|
|
24
24
|
defaultValue: z.ZodOptional<z.ZodAny>;
|
|
25
25
|
onValueChange: z.ZodOptional<z.ZodAny>;
|
|
26
|
-
variant: z.ZodDefault<z.ZodEnum<["default", "primary", "secondary"]>>;
|
|
26
|
+
variant: z.ZodDefault<z.ZodEnum<["default", "primary", "secondary", "outline"]>>;
|
|
27
27
|
size: z.ZodDefault<z.ZodEnum<["sm", "md", "lg"]>>;
|
|
28
|
+
fullWidth: z.ZodDefault<z.ZodBoolean>;
|
|
28
29
|
disabled: z.ZodOptional<z.ZodBoolean>;
|
|
29
30
|
required: z.ZodDefault<z.ZodBoolean>;
|
|
30
31
|
className: z.ZodOptional<z.ZodString>;
|
|
31
32
|
}, "strip", z.ZodTypeAny, {
|
|
32
33
|
type: "multiple" | "single";
|
|
33
34
|
size: "lg" | "md" | "sm";
|
|
34
|
-
variant: "primary" | "secondary" | "default";
|
|
35
|
+
variant: "primary" | "secondary" | "default" | "outline";
|
|
35
36
|
items: {
|
|
36
37
|
value: string;
|
|
37
38
|
className?: string | undefined;
|
|
@@ -39,6 +40,7 @@ export declare const toggleGroupPropsSchema: z.ZodObject<{
|
|
|
39
40
|
icon?: any;
|
|
40
41
|
disabled?: boolean | undefined;
|
|
41
42
|
}[];
|
|
43
|
+
fullWidth: boolean;
|
|
42
44
|
required: boolean;
|
|
43
45
|
className?: string | undefined;
|
|
44
46
|
value?: any;
|
|
@@ -58,9 +60,10 @@ export declare const toggleGroupPropsSchema: z.ZodObject<{
|
|
|
58
60
|
value?: any;
|
|
59
61
|
size?: "lg" | "md" | "sm" | undefined;
|
|
60
62
|
disabled?: boolean | undefined;
|
|
61
|
-
variant?: "primary" | "secondary" | "default" | undefined;
|
|
63
|
+
variant?: "primary" | "secondary" | "default" | "outline" | undefined;
|
|
62
64
|
defaultValue?: any;
|
|
63
65
|
onValueChange?: any;
|
|
66
|
+
fullWidth?: boolean | undefined;
|
|
64
67
|
required?: boolean | undefined;
|
|
65
68
|
}>;
|
|
66
69
|
//# sourceMappingURL=toggle-group.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toggle-group.d.ts","sourceRoot":"","sources":["../../src/schemas/toggle-group.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAUxB,eAAO,MAAM,sBAAsB
|
|
1
|
+
{"version":3,"file":"toggle-group.d.ts","sourceRoot":"","sources":["../../src/schemas/toggle-group.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAUxB,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA4ChC,CAAC"}
|
|
@@ -58,10 +58,11 @@
|
|
|
58
58
|
"enum": [
|
|
59
59
|
"default",
|
|
60
60
|
"primary",
|
|
61
|
-
"secondary"
|
|
61
|
+
"secondary",
|
|
62
|
+
"outline"
|
|
62
63
|
],
|
|
63
64
|
"default": "default",
|
|
64
|
-
"description": "Style variant (default=slider, primary=accent filled,
|
|
65
|
+
"description": "Style variant (default=slider, primary/secondary=accent filled, outline=bordered buttons with no background)"
|
|
65
66
|
},
|
|
66
67
|
"size": {
|
|
67
68
|
"type": "string",
|
|
@@ -73,6 +74,11 @@
|
|
|
73
74
|
"default": "md",
|
|
74
75
|
"description": "Size"
|
|
75
76
|
},
|
|
77
|
+
"fullWidth": {
|
|
78
|
+
"type": "boolean",
|
|
79
|
+
"default": false,
|
|
80
|
+
"description": "Stretch the group to parent width and split items equally"
|
|
81
|
+
},
|
|
76
82
|
"disabled": {
|
|
77
83
|
"type": "boolean",
|
|
78
84
|
"description": "Disable all items"
|
|
@@ -91,7 +97,7 @@
|
|
|
91
97
|
"items"
|
|
92
98
|
],
|
|
93
99
|
"additionalProperties": false,
|
|
94
|
-
"description": "Toggle group / Segment control. Based on Radix ToggleGroup."
|
|
100
|
+
"description": "Toggle group / Segment control for immediate-effect option selection. Based on Radix ToggleGroup.\n\nWHEN TO USE:\n • Sort order, view mode (grid/list), filter chips — selection takes effect immediately\n • Visual comparison important (icons or short labels)\n • Form field that submits later → RadioGroup or CheckBox instead\n • Page area switching (settings tabs) → Tab instead\n\nVARIANTS:\n • default — slider-style background (sleek)\n • primary / secondary — accent-filled selected state\n • outline — bordered buttons with no background (button-style toolbar)\n\nfullWidth=true distributes items equally across parent width (use with outline variant for button-row look).\n\ntype=\"single\" requires at least one selection by default (required=true). Set required=false to allow deselection.\n\nANTI-PATTERNS:\n ✗ Using ToggleGroup for content tabs → Tab\n ✗ Using ToggleGroup as form field submitted later → RadioGroup (semantics + a11y)\n ✗ Mixing icons and text labels of different sizes — keep visual rhythm consistent"
|
|
95
101
|
}
|
|
96
102
|
},
|
|
97
103
|
"$schema": "http://json-schema.org/draft-07/schema#"
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tooltip.d.ts","sourceRoot":"","sources":["../../src/schemas/tooltip.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"tooltip.d.ts","sourceRoot":"","sources":["../../src/schemas/tooltip.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAiC5B,CAAC"}
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
}
|
|
61
61
|
},
|
|
62
62
|
"additionalProperties": false,
|
|
63
|
-
"description": "Tooltip. Based on Radix Tooltip.
|
|
63
|
+
"description": "Tooltip — short text hint shown on hover/focus. Based on Radix Tooltip. Provider built-in.\n\nWHEN TO USE:\n • Brief explanation of an icon button or truncated label\n • Hover-only, non-interactive content (text only)\n • Need clickable content inside → Popover (not Tooltip)\n • Action menu → DropdownMenu\n • Force user attention → Modal\n\nANTI-PATTERNS:\n ✗ Buttons/links inside content → use Popover (Tooltip not focusable)\n ✗ Long paragraphs in tooltip → consider Popover or Drawer\n ✗ Tooltip on disabled buttons (won't show in some browsers) — wrap in span instead\n ✗ Critical info only in tooltip — duplicate visible elsewhere for mobile/touch"
|
|
64
64
|
}
|
|
65
65
|
},
|
|
66
66
|
"$schema": "http://json-schema.org/draft-07/schema#"
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"virtual-scroll.d.ts","sourceRoot":"","sources":["../../src/schemas/virtual-scroll.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"virtual-scroll.d.ts","sourceRoot":"","sources":["../../src/schemas/virtual-scroll.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAiChC,CAAC;AAEJ,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA4BhC,CAAC"}
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"columns"
|
|
56
56
|
],
|
|
57
57
|
"additionalProperties": false,
|
|
58
|
-
"description": "
|
|
58
|
+
"description": "VirtualGrid — performant grid for huge lists. Based on @tanstack/react-virtual.\n\nWHEN TO USE:\n • Image gallery / card grid with 200+ items\n • Fixed column count (responsive via JS — recompute columns on breakpoint)\n • Small grid → DataGrid (no virtualization, simpler API)\n • Single-column list → VirtualList\n\nANTI-PATTERNS:\n ✗ VirtualGrid with <50 items — DataGrid is simpler\n ✗ Cards with hover-expanding height (breaks virtualization)\n ✗ Forgetting to recompute columns on resize → visible empty space"
|
|
59
59
|
}
|
|
60
60
|
},
|
|
61
61
|
"$schema": "http://json-schema.org/draft-07/schema#"
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"items"
|
|
51
51
|
],
|
|
52
52
|
"additionalProperties": false,
|
|
53
|
-
"description": "
|
|
53
|
+
"description": "VirtualList — performant rendering of huge lists (1000+ items). Based on @tanstack/react-virtual.\n\nWHEN TO USE:\n • Large datasets (>200 rows): chat history, transactions, logs, leaderboard\n • Stable item height (or measurable per-item via estimateSize fn)\n • Small list (<100 items) → DataList (much simpler API)\n • Grid layout → VirtualGrid\n • Server-side pagination → InfiniteScroll wrapping plain list\n\nestimateSize is critical — wrong values cause scroll jumps. Pair with onEndReached for server pagination.\n\nANTI-PATTERNS:\n ✗ VirtualList for short lists (DataList is simpler and renders faster)\n ✗ Variable estimateSize for uniform items — use a single number\n ✗ Putting interactive overlays inside virtual rows (mounted/unmounted on scroll)"
|
|
54
54
|
}
|
|
55
55
|
},
|
|
56
56
|
"$schema": "http://json-schema.org/draft-07/schema#"
|