@instruments/materia-ui 0.1.0 → 0.3.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.
Files changed (55) hide show
  1. package/agent-docs.md +4 -3
  2. package/dist/components/animated-number/number-digit.d.ts +5 -3
  3. package/dist/components/animated-number/number-digit.js +39 -16
  4. package/dist/components/animated-number/number-section.d.ts +7 -5
  5. package/dist/components/animated-number/number-section.js +81 -65
  6. package/dist/components/animated-number/number-symbol.js +2 -0
  7. package/dist/components/animated-number/target-widths.d.ts +7 -0
  8. package/dist/components/animated-number/target-widths.js +13 -1
  9. package/dist/components/button/button-variants.js +53 -8
  10. package/dist/components/button-group/button-group-root.js +8 -6
  11. package/dist/components/calendar/calendar-root.js +39 -13
  12. package/dist/components/chart/chart-tooltip.js +7 -5
  13. package/dist/components/empty/empty-media.js +5 -5
  14. package/dist/components/input-group/input-group-textarea.d.ts +3 -2
  15. package/dist/components/input-group/input-group-textarea.js +8 -4
  16. package/dist/components/pill/pill-variants.js +21 -10
  17. package/dist/components/progress/progress-root.d.ts +7 -5
  18. package/dist/components/progress/progress-root.js +26 -5
  19. package/dist/components/radio-group/radio-group-root.d.ts +7 -3
  20. package/dist/components/radio-group/radio-group-root.js +14 -4
  21. package/dist/components/segmented-control/segmented-control-indicator.js +1 -1
  22. package/dist/components/segmented-control/segmented-control-item.js +1 -1
  23. package/dist/components/segmented-control/segmented-control-root.js +1 -1
  24. package/dist/components/segmented-control/segmented-control-variants.js +1 -1
  25. package/dist/components/stepper/stepper-item.js +6 -2
  26. package/dist/components/stepper/stepper-variants.d.ts +1 -0
  27. package/dist/components/stepper/stepper-variants.js +11 -1
  28. package/dist/components/tab-navigation/tab-navigation-link.js +1 -1
  29. package/dist/components/tabs/tabs-indicator.js +1 -1
  30. package/dist/components/tabs/tabs-trigger.js +1 -1
  31. package/dist/components/tabs/tabs-variants.js +1 -1
  32. package/dist/components/textarea/textarea-root.d.ts +1 -1
  33. package/dist/components/textarea/textarea-root.js +6 -9
  34. package/dist/components/textarea/use-textarea-rows.d.ts +22 -0
  35. package/dist/components/textarea/use-textarea-rows.js +43 -0
  36. package/dist/compositions/data-grid-pagination/data-grid-pagination-root.d.ts +8 -6
  37. package/dist/compositions/data-grid-pagination/data-grid-pagination-root.js +11 -20
  38. package/dist/compositions/product-card/product-card-color-count.js +26 -26
  39. package/dist/compositions/product-card/product-card-compact-arm.js +2 -2
  40. package/dist/compositions/product-card/product-card-content-types.d.ts +5 -0
  41. package/dist/compositions/product-card/product-card-full-arm.js +2 -2
  42. package/dist/compositions/product-card/product-card-provider-types.d.ts +10 -0
  43. package/dist/compositions/product-card/product-card-provider.js +1 -1
  44. package/dist/compositions/product-card/product-card-swatch-selector.js +4 -3
  45. package/dist/data/docs-manifest.d.ts +1 -1
  46. package/dist/data/docs-manifest.js +29 -74
  47. package/dist/styles/index.css +17 -6
  48. package/dist/{components/segmented/segmented-variants.d.ts → tokens/segmented.d.ts} +12 -1
  49. package/dist/{components/segmented/segmented-variants.js → tokens/segmented.js} +11 -0
  50. package/lint/tokens.mjs +1 -0
  51. package/package.json +5 -5
  52. package/dist/components/segmented/segmented-root.d.ts +0 -12
  53. package/dist/components/segmented/segmented-root.js +0 -12
  54. package/dist/components/segmented.d.ts +0 -1
  55. package/dist/components/segmented.js +0 -1
@@ -1,4 +1,15 @@
1
- import type { ComponentSize } from "../../tokens/size.js";
1
+ /**
2
+ * The segmented "pill" visual language: shell, padding, gap, trigger text and
3
+ * active-indicator class strings, with size-to-class maps.
4
+ *
5
+ * SegmentedControl, Tabs and TabNavigation all consume these, so they render
6
+ * an identical shell at any size. They are class strings, not components:
7
+ * apply them through `className`. For an actual segmented UI, use
8
+ * `SegmentedControl`.
9
+ *
10
+ * @module
11
+ */
12
+ import type { ComponentSize } from "./size.js";
2
13
  /**
3
14
  * Shared shell classes for segmented controls (Tabs default, ToggleGroup pill).
4
15
  *
@@ -1,3 +1,14 @@
1
+ /**
2
+ * The segmented "pill" visual language: shell, padding, gap, trigger text and
3
+ * active-indicator class strings, with size-to-class maps.
4
+ *
5
+ * SegmentedControl, Tabs and TabNavigation all consume these, so they render
6
+ * an identical shell at any size. They are class strings, not components:
7
+ * apply them through `className`. For an actual segmented UI, use
8
+ * `SegmentedControl`.
9
+ *
10
+ * @module
11
+ */
1
12
  /**
2
13
  * Shared shell classes for segmented controls (Tabs default, ToggleGroup pill).
3
14
  *
package/lint/tokens.mjs CHANGED
@@ -40,6 +40,7 @@ export const colorTokens = [
40
40
  "brand-accent",
41
41
  "brand-foreground",
42
42
  "brand-soft",
43
+ "brand-strong",
43
44
  "card",
44
45
  "card-background",
45
46
  "card-border",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@instruments/materia-ui",
3
- "version": "0.1.0",
3
+ "version": "0.3.0",
4
4
  "description": "Materia design system: React components, tokens and Tailwind v4 styles.",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "repository": {
@@ -392,10 +392,6 @@
392
392
  "types": "./dist/components/section.d.ts",
393
393
  "default": "./dist/components/section.js"
394
394
  },
395
- "./components/segmented": {
396
- "types": "./dist/components/segmented.d.ts",
397
- "default": "./dist/components/segmented.js"
398
- },
399
395
  "./components/segmented-control": {
400
396
  "types": "./dist/components/segmented-control.d.ts",
401
397
  "default": "./dist/components/segmented-control.js"
@@ -792,6 +788,10 @@
792
788
  "types": "./dist/tokens/radius-tokens.d.ts",
793
789
  "default": "./dist/tokens/radius-tokens.js"
794
790
  },
791
+ "./tokens/segmented": {
792
+ "types": "./dist/tokens/segmented.d.ts",
793
+ "default": "./dist/tokens/segmented.js"
794
+ },
795
795
  "./tokens/shadows": {
796
796
  "types": "./dist/tokens/shadows.d.ts",
797
797
  "default": "./dist/tokens/shadows.js"
@@ -1,12 +0,0 @@
1
- /**
2
- * Shared class-name token primitives for the segmented-control visual language.
3
- *
4
- * Consumed by SegmentedControl, Tabs, and TabNavigation so they render an
5
- * identical shell, padding, gap, and active indicator at any size.
6
- * Not components - these are Tailwind class strings and size→class maps.
7
- *
8
- * @bestPractice These are class-name strings and size→class maps, not components - apply them via `className`, never render them as JSX.
9
- * @bestPractice Reuse these tokens to give a custom control the segmented "pill" shell; for actual segmented UIs prefer `SegmentedControl`; `Tabs` and `TabNavigation` consume the same tokens for panel and navigation switching.
10
- * @category forms
11
- */
12
- export { SEGMENTED_GAP, SEGMENTED_INDICATOR_ACTIVE_CLASS, SEGMENTED_INDICATOR_CLASS, SEGMENTED_SHELL_BASE, SEGMENTED_SHELL_PADDING, SEGMENTED_TRIGGER_PADDING, SEGMENTED_TRIGGER_TEXT, } from "./segmented-variants.js";
@@ -1,12 +0,0 @@
1
- /**
2
- * Shared class-name token primitives for the segmented-control visual language.
3
- *
4
- * Consumed by SegmentedControl, Tabs, and TabNavigation so they render an
5
- * identical shell, padding, gap, and active indicator at any size.
6
- * Not components - these are Tailwind class strings and size→class maps.
7
- *
8
- * @bestPractice These are class-name strings and size→class maps, not components - apply them via `className`, never render them as JSX.
9
- * @bestPractice Reuse these tokens to give a custom control the segmented "pill" shell; for actual segmented UIs prefer `SegmentedControl`; `Tabs` and `TabNavigation` consume the same tokens for panel and navigation switching.
10
- * @category forms
11
- */
12
- export { SEGMENTED_GAP, SEGMENTED_INDICATOR_ACTIVE_CLASS, SEGMENTED_INDICATOR_CLASS, SEGMENTED_SHELL_BASE, SEGMENTED_SHELL_PADDING, SEGMENTED_TRIGGER_PADDING, SEGMENTED_TRIGGER_TEXT, } from "./segmented-variants.js";
@@ -1 +0,0 @@
1
- export { SEGMENTED_GAP, SEGMENTED_INDICATOR_ACTIVE_CLASS, SEGMENTED_INDICATOR_CLASS, SEGMENTED_SHELL_BASE, SEGMENTED_SHELL_PADDING, SEGMENTED_TRIGGER_PADDING, } from "./segmented/segmented-variants.js";
@@ -1 +0,0 @@
1
- export { SEGMENTED_GAP, SEGMENTED_INDICATOR_ACTIVE_CLASS, SEGMENTED_INDICATOR_CLASS, SEGMENTED_SHELL_BASE, SEGMENTED_SHELL_PADDING, SEGMENTED_TRIGGER_PADDING, } from "./segmented/segmented-variants.js";