@sanity/ui 3.0.0-static.16 → 3.0.0-static.17

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 (94) hide show
  1. package/README.md +2 -4
  2. package/bin/{ui.js → sanity-ui.cjs} +1 -1
  3. package/dist/_chunks-cjs/{_visual-editing.js → _visual-editing.cjs} +4 -4
  4. package/dist/_chunks-cjs/_visual-editing.cjs.map +1 -0
  5. package/dist/_chunks-cjs/{buildCommand.js → buildCommand.cjs} +26 -10
  6. package/dist/_chunks-cjs/buildCommand.cjs.map +1 -0
  7. package/dist/_chunks-cjs/{refractor.js → refractor.cjs} +1 -1
  8. package/dist/_chunks-cjs/refractor.cjs.map +1 -0
  9. package/dist/_chunks-es/{_visual-editing.mjs → _visual-editing.js} +4 -4
  10. package/dist/_chunks-es/_visual-editing.js.map +1 -0
  11. package/dist/_chunks-es/{refractor.mjs → refractor.js} +1 -1
  12. package/dist/_chunks-es/refractor.js.map +1 -0
  13. package/dist/_visual-editing.cjs +30 -0
  14. package/dist/_visual-editing.cjs.map +1 -0
  15. package/dist/_visual-editing.js +29 -29
  16. package/dist/_visual-editing.js.map +1 -1
  17. package/dist/{cli.js → cli.cjs} +4 -4
  18. package/dist/cli.cjs.map +1 -0
  19. package/dist/{css.mjs → css.cjs} +490 -499
  20. package/dist/css.cjs.map +1 -0
  21. package/dist/{css.d.mts → css.d.cts} +19 -23
  22. package/dist/css.d.ts +19 -23
  23. package/dist/css.js +490 -497
  24. package/dist/css.js.map +1 -1
  25. package/dist/{index.mjs → index.cjs} +368 -367
  26. package/dist/{index.mjs.map → index.cjs.map} +1 -1
  27. package/dist/index.js +366 -367
  28. package/dist/index.js.map +1 -1
  29. package/dist/{theme.mjs → theme.cjs} +219 -196
  30. package/dist/theme.cjs.map +1 -0
  31. package/dist/{theme.d.mts → theme.d.cts} +2 -0
  32. package/dist/theme.d.ts +2 -0
  33. package/dist/theme.js +218 -195
  34. package/dist/theme.js.map +1 -1
  35. package/dist/{sanity-palette.css → ui-palette.css} +1 -1
  36. package/dist/ui-palette.min.css +1 -0
  37. package/dist/{system.css → ui-system.css} +258 -140
  38. package/dist/ui-system.min.css +1 -0
  39. package/dist/{sanity-theme.css → ui-theme.css} +199 -199
  40. package/dist/ui-theme.min.css +1 -0
  41. package/dist/ui.css +29152 -0
  42. package/dist/ui.min.css +1 -0
  43. package/package.json +20 -20
  44. package/src/cli/buildCommand.ts +55 -20
  45. package/src/cli/index.ts +1 -1
  46. package/src/core/StyleTags.tsx +4 -4
  47. package/src/core/components/autocomplete/__workshop__/async.tsx +2 -2
  48. package/src/core/components/autocomplete/__workshop__/custom.tsx +2 -2
  49. package/src/core/components/autocomplete/__workshop__/focusAndBlur.tsx +3 -3
  50. package/src/core/primitives/button/__workshop__/custom.tsx +18 -41
  51. package/src/core/primitives/button/button.tsx +3 -1
  52. package/src/core/primitives/card/__workshop__/asButton.tsx +0 -9
  53. package/src/core/primitives/card/__workshop__/interactive.tsx +0 -1
  54. package/src/core/primitives/card/__workshop__/props.tsx +0 -3
  55. package/src/core/primitives/card/__workshop__/selected.tsx +6 -37
  56. package/src/core/primitives/heading/__workshop__/opticalAlignment.tsx +1 -1
  57. package/src/core/primitives/heading/__workshop__/plain.tsx +1 -8
  58. package/src/core/primitives/label/__workshop__/plain.tsx +1 -9
  59. package/src/core/primitives/text/__workshop__/example.tsx +1 -9
  60. package/src/css/{compilePalette.ts → _compilePalette.ts} +2 -2
  61. package/src/css/{compileSystem.ts → _compileSystem.ts} +1 -1
  62. package/src/css/{compileTheme.ts → _compileTheme.ts} +3 -3
  63. package/src/css/{compileTheme_v3.ts → _compileTheme_v3.ts} +7 -1
  64. package/src/css/_system.style.ts +1 -0
  65. package/src/css/index.ts +3 -3
  66. package/src/css/primitives/button/button.style.ts +23 -9
  67. package/src/css/primitives/button/button.ts +1 -12
  68. package/src/css/primitives/button/types.ts +1 -6
  69. package/src/css/primitives/card/card.style.ts +12 -21
  70. package/src/css/primitives/kbd/kbd.style.ts +3 -6
  71. package/src/css/types.ts +9 -9
  72. package/src/theme/v3/color/buildColor_v3.ts +53 -25
  73. package/src/theme/v3/color/card.ts +0 -42
  74. package/src/theme/v3/color/renderColor.test.ts +1 -0
  75. package/src/theme/v3/color/renderColor.ts +9 -2
  76. package/src/theme/v3/color/token.ts +1 -0
  77. package/src/theme/v3/defaultTokens.ts +7 -2
  78. package/dist/_chunks-cjs/_visual-editing.js.map +0 -1
  79. package/dist/_chunks-cjs/buildCommand.js.map +0 -1
  80. package/dist/_chunks-cjs/refractor.js.map +0 -1
  81. package/dist/_chunks-es/_visual-editing.mjs.map +0 -1
  82. package/dist/_chunks-es/refractor.mjs.map +0 -1
  83. package/dist/_visual-editing.mjs +0 -30
  84. package/dist/_visual-editing.mjs.map +0 -1
  85. package/dist/cli.js.map +0 -1
  86. package/dist/css.mjs.map +0 -1
  87. package/dist/sanity-palette.min.css +0 -1
  88. package/dist/sanity-theme.min.css +0 -1
  89. package/dist/system.min.css +0 -1
  90. package/dist/theme.mjs.map +0 -1
  91. package/src/css/primitives/button/_constants.ts +0 -17
  92. /package/dist/{_visual-editing.d.mts → _visual-editing.d.cts} +0 -0
  93. /package/dist/{cli.d.ts → cli.d.cts} +0 -0
  94. /package/dist/{index.d.mts → index.d.cts} +0 -0
@@ -14,7 +14,6 @@ import {Shadow} from '@sanity/ui/theme'
14
14
  import {Space} from '@sanity/ui/theme'
15
15
  import {ThemeBoxShadow} from '@sanity/ui/theme'
16
16
  import {ThemeColorAvatarColorKey} from '@sanity/ui/theme'
17
- import {ThemeColorButtonModeKey} from '@sanity/ui/theme'
18
17
  import {ThemeColorCardToneKey} from '@sanity/ui/theme'
19
18
  import {ThemeColorSchemeKey} from '@sanity/ui/theme'
20
19
  import {ThemeColorStateToneKey} from '@sanity/ui/theme'
@@ -151,10 +150,7 @@ export declare interface ButtonStyleProps
151
150
  extends DisplayStyleProps,
152
151
  FlexItemStyleProps,
153
152
  RadiusStyleProps,
154
- WidthStyleProps {
155
- mode?: ThemeColorButtonModeKey
156
- tone?: ThemeColorStateToneKey
157
- }
153
+ WidthStyleProps {}
158
154
 
159
155
  /** @public */
160
156
  export declare function card(props: CardStyleProps): string | undefined
@@ -629,13 +625,13 @@ export declare interface ColorVariantVars
629
625
  export declare type Columns = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12
630
626
 
631
627
  /** @internal */
632
- export declare function compilePalette(): string
628
+ export declare function _compilePalette(): string
633
629
 
634
630
  /** @internal */
635
- export declare function compileSystem(): string
631
+ export declare function _compileSystem(): string
636
632
 
637
633
  /** @internal */
638
- export declare function compileTheme(theme: RootTheme): string
634
+ export declare function _compileTheme(theme: RootTheme): string
639
635
 
640
636
  /** @public */
641
637
  export declare function composeClassNames(
@@ -1467,6 +1463,21 @@ export declare type VarName =
1467
1463
 
1468
1464
  /** @public */
1469
1465
  export declare interface VarNames {
1466
+ avatar: {
1467
+ distance: VarName
1468
+ focusRing: {
1469
+ offset: VarName
1470
+ width: VarName
1471
+ }
1472
+ size: VarName
1473
+ sizes: Record<
1474
+ AvatarSize,
1475
+ {
1476
+ distance: VarName
1477
+ size: VarName
1478
+ }
1479
+ >
1480
+ }
1470
1481
  button: {
1471
1482
  border: {
1472
1483
  width: VarName
@@ -1485,21 +1496,6 @@ export declare interface VarNames {
1485
1496
  ScopedColorVarNames &
1486
1497
  Record<ThemeColorCardToneKey, ColorCardVarNames>
1487
1498
  container: Record<Exclude<ContainerWidth, 'auto'>, VarName>
1488
- avatar: {
1489
- distance: VarName
1490
- focusRing: {
1491
- offset: VarName
1492
- width: VarName
1493
- }
1494
- size: VarName
1495
- sizes: Record<
1496
- AvatarSize,
1497
- {
1498
- distance: VarName
1499
- size: VarName
1500
- }
1501
- >
1502
- }
1503
1499
  font: {
1504
1500
  code: FontVarNames<FontCodeSize>
1505
1501
  heading: FontVarNames<FontHeadingSize>
package/dist/css.d.ts CHANGED
@@ -14,7 +14,6 @@ import {Shadow} from '@sanity/ui/theme'
14
14
  import {Space} from '@sanity/ui/theme'
15
15
  import {ThemeBoxShadow} from '@sanity/ui/theme'
16
16
  import {ThemeColorAvatarColorKey} from '@sanity/ui/theme'
17
- import {ThemeColorButtonModeKey} from '@sanity/ui/theme'
18
17
  import {ThemeColorCardToneKey} from '@sanity/ui/theme'
19
18
  import {ThemeColorSchemeKey} from '@sanity/ui/theme'
20
19
  import {ThemeColorStateToneKey} from '@sanity/ui/theme'
@@ -151,10 +150,7 @@ export declare interface ButtonStyleProps
151
150
  extends DisplayStyleProps,
152
151
  FlexItemStyleProps,
153
152
  RadiusStyleProps,
154
- WidthStyleProps {
155
- mode?: ThemeColorButtonModeKey
156
- tone?: ThemeColorStateToneKey
157
- }
153
+ WidthStyleProps {}
158
154
 
159
155
  /** @public */
160
156
  export declare function card(props: CardStyleProps): string | undefined
@@ -629,13 +625,13 @@ export declare interface ColorVariantVars
629
625
  export declare type Columns = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12
630
626
 
631
627
  /** @internal */
632
- export declare function compilePalette(): string
628
+ export declare function _compilePalette(): string
633
629
 
634
630
  /** @internal */
635
- export declare function compileSystem(): string
631
+ export declare function _compileSystem(): string
636
632
 
637
633
  /** @internal */
638
- export declare function compileTheme(theme: RootTheme): string
634
+ export declare function _compileTheme(theme: RootTheme): string
639
635
 
640
636
  /** @public */
641
637
  export declare function composeClassNames(
@@ -1467,6 +1463,21 @@ export declare type VarName =
1467
1463
 
1468
1464
  /** @public */
1469
1465
  export declare interface VarNames {
1466
+ avatar: {
1467
+ distance: VarName
1468
+ focusRing: {
1469
+ offset: VarName
1470
+ width: VarName
1471
+ }
1472
+ size: VarName
1473
+ sizes: Record<
1474
+ AvatarSize,
1475
+ {
1476
+ distance: VarName
1477
+ size: VarName
1478
+ }
1479
+ >
1480
+ }
1470
1481
  button: {
1471
1482
  border: {
1472
1483
  width: VarName
@@ -1485,21 +1496,6 @@ export declare interface VarNames {
1485
1496
  ScopedColorVarNames &
1486
1497
  Record<ThemeColorCardToneKey, ColorCardVarNames>
1487
1498
  container: Record<Exclude<ContainerWidth, 'auto'>, VarName>
1488
- avatar: {
1489
- distance: VarName
1490
- focusRing: {
1491
- offset: VarName
1492
- width: VarName
1493
- }
1494
- size: VarName
1495
- sizes: Record<
1496
- AvatarSize,
1497
- {
1498
- distance: VarName
1499
- size: VarName
1500
- }
1501
- >
1502
- }
1503
1499
  font: {
1504
1500
  code: FontVarNames<FontCodeSize>
1505
1501
  heading: FontVarNames<FontHeadingSize>