@webstudio-is/sdk-components-react-radix 0.95.0 → 0.97.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 (63) hide show
  1. package/lib/components.js +278 -35
  2. package/lib/hooks.js +475 -11
  3. package/lib/metas.js +4616 -58
  4. package/lib/props.js +23280 -57
  5. package/lib/types/theme/tailwind-classes.d.ts +4 -4
  6. package/package.json +9 -9
  7. package/lib/__generated__/accordion.props.js +0 -2619
  8. package/lib/__generated__/checkbox.props.js +0 -1080
  9. package/lib/__generated__/collapsible.props.js +0 -1026
  10. package/lib/__generated__/dialog.props.js +0 -2595
  11. package/lib/__generated__/label.props.js +0 -519
  12. package/lib/__generated__/navigation-menu.props.js +0 -2557
  13. package/lib/__generated__/popover.props.js +0 -558
  14. package/lib/__generated__/radio-group.props.js +0 -1623
  15. package/lib/__generated__/select.props.js +0 -3674
  16. package/lib/__generated__/sheet.props.js +0 -2614
  17. package/lib/__generated__/switch.props.js +0 -1080
  18. package/lib/__generated__/tabs.props.js +0 -2119
  19. package/lib/__generated__/tooltip.props.js +0 -569
  20. package/lib/accordion.js +0 -51
  21. package/lib/accordion.stories.js +0 -18
  22. package/lib/accordion.ws.js +0 -259
  23. package/lib/checkbox.js +0 -10
  24. package/lib/checkbox.stories.js +0 -19
  25. package/lib/checkbox.ws.js +0 -148
  26. package/lib/collapsible.js +0 -31
  27. package/lib/collapsible.stories.js +0 -18
  28. package/lib/collapsible.ws.js +0 -103
  29. package/lib/dialog.js +0 -53
  30. package/lib/dialog.stories.js +0 -18
  31. package/lib/dialog.ws.js +0 -289
  32. package/lib/label.js +0 -7
  33. package/lib/label.stories.js +0 -19
  34. package/lib/label.ws.js +0 -44
  35. package/lib/navigation-menu.js +0 -76
  36. package/lib/navigation-menu.stories.js +0 -18
  37. package/lib/navigation-menu.ws.js +0 -486
  38. package/lib/popover.js +0 -58
  39. package/lib/popover.stories.js +0 -18
  40. package/lib/popover.ws.js +0 -110
  41. package/lib/props-descriptions.js +0 -34
  42. package/lib/radio-group.js +0 -7
  43. package/lib/radio-group.stories.js +0 -19
  44. package/lib/radio-group.ws.js +0 -166
  45. package/lib/select.js +0 -65
  46. package/lib/select.stories.js +0 -18
  47. package/lib/select.ws.js +0 -321
  48. package/lib/sheet.js +0 -59
  49. package/lib/sheet.stories.js +0 -18
  50. package/lib/sheet.ws.js +0 -225
  51. package/lib/switch.js +0 -4
  52. package/lib/switch.stories.js +0 -19
  53. package/lib/switch.ws.js +0 -140
  54. package/lib/tabs.js +0 -38
  55. package/lib/tabs.stories.js +0 -18
  56. package/lib/tabs.ws.js +0 -169
  57. package/lib/theme/__generated__/tailwind-theme.js +0 -517
  58. package/lib/theme/styles.js +0 -63
  59. package/lib/theme/tailwind-classes.js +0 -651
  60. package/lib/theme/tailwind-colors.js +0 -23
  61. package/lib/tooltip.js +0 -55
  62. package/lib/tooltip.stories.js +0 -18
  63. package/lib/tooltip.ws.js +0 -111
@@ -12,7 +12,7 @@ type StringEnumToNumeric<T extends string> = T extends `${infer Z extends number
12
12
  type NonNumeric<T extends string> = T extends `${infer Z extends number}` ? never : T;
13
13
  export declare const border: (borderWidthOrColor?: StringEnumToNumeric<keyof typeof theme.borderWidth> | keyof typeof theme.colors) => EmbedTemplateStyleDecl[];
14
14
  export declare const borderB: (borderWidthOrColor?: StringEnumToNumeric<keyof typeof theme.borderWidth> | keyof typeof theme.colors) => EmbedTemplateStyleDecl[];
15
- declare const paddingProperty: (property: "paddingTop" | "paddingRight" | "paddingBottom" | "paddingLeft") => (padding: 0 | "px" | 2 | 4 | 6 | 8 | 1 | 14 | 3 | 5 | 7 | 9 | 10 | 11 | 12 | 16 | 32 | 80 | 0.5 | 1.5 | 2.5 | 3.5 | 20 | 24 | 40 | 60 | 28 | 36 | 48 | 56 | 64 | 72 | 44 | 52 | 96) => EmbedTemplateStyleDecl[];
15
+ declare const paddingProperty: (property: "paddingTop" | "paddingRight" | "paddingBottom" | "paddingLeft") => (padding: 0 | "px" | 2 | 4 | 6 | 8 | 1 | 14 | 3 | 5 | 7 | 9 | 10 | 11 | 12 | 16 | 32 | 48 | 64 | 96 | 80 | 0.5 | 1.5 | 2.5 | 3.5 | 20 | 24 | 40 | 60 | 28 | 36 | 56 | 72 | 44 | 52) => EmbedTemplateStyleDecl[];
16
16
  export declare const pt: ReturnType<typeof paddingProperty>;
17
17
  export declare const pb: ReturnType<typeof paddingProperty>;
18
18
  export declare const pl: ReturnType<typeof paddingProperty>;
@@ -20,7 +20,7 @@ export declare const pr: ReturnType<typeof paddingProperty>;
20
20
  export declare const px: ReturnType<typeof paddingProperty>;
21
21
  export declare const py: ReturnType<typeof paddingProperty>;
22
22
  export declare const p: ReturnType<typeof paddingProperty>;
23
- declare const marginProperty: (property: "marginTop" | "marginRight" | "marginBottom" | "marginLeft") => (margin: 0 | "px" | 2 | 4 | 6 | 8 | 1 | 14 | 3 | "auto" | 5 | 7 | 9 | 10 | 11 | 12 | 16 | 32 | 80 | 0.5 | 1.5 | 2.5 | 3.5 | 20 | 24 | 40 | 60 | 28 | 36 | 48 | 56 | 64 | 72 | 44 | 52 | 96) => EmbedTemplateStyleDecl[];
23
+ declare const marginProperty: (property: "marginTop" | "marginRight" | "marginBottom" | "marginLeft") => (margin: 0 | "px" | 2 | 4 | 6 | 8 | 1 | 14 | 3 | "auto" | 5 | 7 | 9 | 10 | 11 | 12 | 16 | 32 | 48 | 64 | 96 | 80 | 0.5 | 1.5 | 2.5 | 3.5 | 20 | 24 | 40 | 60 | 28 | 36 | 56 | 72 | 44 | 52) => EmbedTemplateStyleDecl[];
24
24
  export declare const ml: ReturnType<typeof marginProperty>;
25
25
  export declare const mr: ReturnType<typeof marginProperty>;
26
26
  export declare const mt: ReturnType<typeof marginProperty>;
@@ -31,8 +31,8 @@ export declare const m: ReturnType<typeof marginProperty>;
31
31
  export declare const w: (spacing: StringEnumToNumeric<keyof typeof theme.width> | NonNumeric<keyof typeof theme.width>) => EmbedTemplateStyleDecl[];
32
32
  export declare const h: (spacing: StringEnumToNumeric<keyof typeof theme.height> | NonNumeric<keyof typeof theme.height>) => EmbedTemplateStyleDecl[];
33
33
  export declare const minH: (spacing: StringEnumToNumeric<keyof typeof theme.minHeight>) => EmbedTemplateStyleDecl[];
34
- export declare const opacity: (opacity: 0 | 5 | 10 | 100 | 80 | 75 | 20 | 50 | 25 | 40 | 60 | 30 | 70 | 90 | 95) => EmbedTemplateStyleDecl[];
35
- export declare const cursor: (cursor: "default" | "auto" | "none" | "progress" | "text" | "copy" | "cell" | "move" | "pointer" | "wait" | "help" | "not-allowed" | "context-menu" | "crosshair" | "vertical-text" | "alias" | "no-drop" | "grab" | "grabbing" | "all-scroll" | "col-resize" | "row-resize" | "n-resize" | "e-resize" | "s-resize" | "w-resize" | "ne-resize" | "nw-resize" | "se-resize" | "sw-resize" | "ew-resize" | "ns-resize" | "nesw-resize" | "nwse-resize" | "zoom-in" | "zoom-out") => EmbedTemplateStyleDecl[];
34
+ export declare const opacity: (opacity: 0 | 5 | 10 | 80 | 100 | 75 | 20 | 50 | 25 | 40 | 60 | 30 | 70 | 90 | 95) => EmbedTemplateStyleDecl[];
35
+ export declare const cursor: (cursor: "default" | "auto" | "none" | "progress" | "text" | "cell" | "copy" | "move" | "pointer" | "wait" | "help" | "not-allowed" | "context-menu" | "crosshair" | "vertical-text" | "alias" | "no-drop" | "grab" | "grabbing" | "all-scroll" | "col-resize" | "row-resize" | "n-resize" | "e-resize" | "s-resize" | "w-resize" | "ne-resize" | "nw-resize" | "se-resize" | "sw-resize" | "ew-resize" | "ns-resize" | "nesw-resize" | "nwse-resize" | "zoom-in" | "zoom-out") => EmbedTemplateStyleDecl[];
36
36
  export declare const maxW: (spacing: StringEnumToNumeric<keyof typeof theme.maxWidth> | NonNumeric<keyof typeof theme.maxWidth>) => EmbedTemplateStyleDecl[];
37
37
  export declare const top: (spacing: StringEnumToNumeric<keyof typeof theme.inset> | NonNumeric<keyof typeof theme.inset>) => EmbedTemplateStyleDecl[];
38
38
  export declare const right: (spacing: StringEnumToNumeric<keyof typeof theme.inset> | NonNumeric<keyof typeof theme.inset>) => EmbedTemplateStyleDecl[];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webstudio-is/sdk-components-react-radix",
3
- "version": "0.95.0",
3
+ "version": "0.97.0",
4
4
  "description": "Webstudio wrapper for radix library",
5
5
  "author": "Webstudio <github@webstudio.is>",
6
6
  "homepage": "https://webstudio.is",
@@ -55,9 +55,9 @@
55
55
  "@radix-ui/react-switch": "^1.0.3",
56
56
  "@radix-ui/react-tabs": "^1.0.4",
57
57
  "@radix-ui/react-tooltip": "^1.0.6",
58
- "@webstudio-is/css-engine": "^0.95.0",
59
- "@webstudio-is/icons": "^0.95.0",
60
- "@webstudio-is/react-sdk": "^0.95.0"
58
+ "@webstudio-is/css-engine": "^0.97.0",
59
+ "@webstudio-is/icons": "^0.97.0",
60
+ "@webstudio-is/react-sdk": "^0.97.0"
61
61
  },
62
62
  "devDependencies": {
63
63
  "@storybook/react": "^7.4.0",
@@ -67,15 +67,15 @@
67
67
  "react-dom": "^18.2.0",
68
68
  "tailwindcss": "^3.3.3",
69
69
  "typescript": "^5.2.2",
70
- "@webstudio-is/css-data": "^0.95.0",
71
- "@webstudio-is/generate-arg-types": "^0.95.0",
72
- "@webstudio-is/sdk-components-react": "^0.95.0",
70
+ "@webstudio-is/css-data": "^0.97.0",
71
+ "@webstudio-is/generate-arg-types": "^0.97.0",
72
+ "@webstudio-is/sdk-components-react": "^0.97.0",
73
73
  "@webstudio-is/storybook-config": "^0.0.0",
74
74
  "@webstudio-is/tsconfig": "^1.0.7"
75
75
  },
76
76
  "scripts": {
77
- "dev": "pnpm build --watch",
78
- "build": "rm -rf lib && esbuild 'src/**/*.ts' 'src/**/*.tsx' --outdir=lib",
77
+ "dev": "rm -rf lib && esbuild 'src/**/*.ts' 'src/**/*.tsx' --outdir=lib --watch",
78
+ "build": "rm -rf lib && esbuild src/components.ts src/metas.ts src/props.ts src/hooks.ts --outdir=lib --bundle --format=esm --packages=external",
79
79
  "build:args": "NODE_OPTIONS=--conditions=source generate-arg-types './src/*.tsx !./src/*.stories.tsx !./src/*.ws.tsx' -e asChild -e modal -e defaultValue -e defaultOpen -e defaultChecked && prettier --write \"**/*.props.ts\"",
80
80
  "build:tailwind": "tsx scripts/generate-tailwind-theme.ts && prettier --write src/theme/__generated__",
81
81
  "dts": "tsc --project tsconfig.dts.json",