@konstructio/ui 0.0.12-alpha.9 → 0.0.13-alpha.1

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 (144) hide show
  1. package/dist/{Modal-B-E9uaA6.js → Modal-i7eolhYH.js} +311 -307
  2. package/dist/components/Alert/Alert.js +24 -29
  3. package/dist/components/Alert/Alert.variants.js +9 -15
  4. package/dist/components/AlertDialog/AlertDialog.js +59 -46
  5. package/dist/components/AlertDialog/components/AlertDialogTrigger.js +2 -2
  6. package/dist/components/AlertDialog/components/index.js +1 -1
  7. package/dist/components/Autocomplete/Autocomplete.js +76 -72
  8. package/dist/components/Autocomplete/Autocomplete.variants.js +11 -20
  9. package/dist/components/Autocomplete/components/List/List.js +28 -30
  10. package/dist/components/Autocomplete/components/List/List.variants.js +34 -40
  11. package/dist/components/Breadcrumb/Breadcrumb.js +47 -56
  12. package/dist/components/Breadcrumb/Breadcrumb.variants.js +6 -26
  13. package/dist/components/Breadcrumb/components/Item/Item.js +29 -41
  14. package/dist/components/Breadcrumb/components/Item/Item.variants.js +2 -20
  15. package/dist/components/Button/Button.js +33 -37
  16. package/dist/components/Button/Button.variants.js +138 -195
  17. package/dist/components/Card/Card.js +32 -37
  18. package/dist/components/Card/Card.variants.js +18 -53
  19. package/dist/components/Checkbox/Checkbox.js +65 -68
  20. package/dist/components/Checkbox/Checkbox.variants.js +11 -35
  21. package/dist/components/Command/Command.js +33 -25
  22. package/dist/components/Command/Command.variants.js +47 -94
  23. package/dist/components/Command/components/Command.js +1 -1
  24. package/dist/components/Command/components/CommandEmpty.js +1 -1
  25. package/dist/components/Command/components/CommandGroup.js +1 -1
  26. package/dist/components/Command/components/CommandInput.js +1 -1
  27. package/dist/components/Command/components/CommandItem.js +1 -1
  28. package/dist/components/Command/components/CommandList.js +1 -1
  29. package/dist/components/Command/components/CommandSeparator.js +1 -1
  30. package/dist/components/Command/components/DialogContent.js +1 -1
  31. package/dist/components/Command/components/DialogOverlay.js +8 -8
  32. package/dist/components/Divider/Divider.js +3 -2
  33. package/dist/components/Divider/Divider.variants.js +12 -9
  34. package/dist/components/Dropdown/Dropdown.js +6 -6
  35. package/dist/components/Dropdown/Dropdown.variants.js +31 -38
  36. package/dist/components/Dropdown/components/List/List.js +17 -15
  37. package/dist/components/Dropdown/components/List/List.variants.js +22 -32
  38. package/dist/components/Dropdown/components/ListItem/ListItem.js +20 -19
  39. package/dist/components/Dropdown/components/ListItem/ListItem.variants.js +18 -30
  40. package/dist/components/Dropdown/components/Wrapper.js +127 -90
  41. package/dist/components/Dropdown/contexts/dropdown.context.js +1 -1
  42. package/dist/components/Dropdown/contexts/dropdown.provider.js +9 -9
  43. package/dist/components/Input/Input.js +37 -37
  44. package/dist/components/Input/Input.variants.js +8 -13
  45. package/dist/components/Loading/Loading.js +60 -58
  46. package/dist/components/Loading/Loading.variants.js +9 -15
  47. package/dist/components/Modal/Modal.js +2 -2
  48. package/dist/components/Modal/components/Body/Body.js +1 -1
  49. package/dist/components/Modal/components/Footer/Footer.js +2 -2
  50. package/dist/components/Modal/components/Header/Header.js +3 -3
  51. package/dist/components/Modal/components/Wrapper/Wrapper.js +3 -4
  52. package/dist/components/Modal/components/Wrapper/Wrapper.variants.js +32 -46
  53. package/dist/components/Modal/components/index.js +1 -1
  54. package/dist/components/NumberInput/NumberInput.js +93 -111
  55. package/dist/components/NumberInput/NumberInput.variants.js +30 -51
  56. package/dist/components/ProgressBar/ProgressBar.js +25 -29
  57. package/dist/components/ProgressBar/ProgressBar.variants.js +10 -31
  58. package/dist/components/Radio/Radio.js +45 -46
  59. package/dist/components/Radio/Radio.variants.js +4 -13
  60. package/dist/components/RadioCard/RadioCard.js +31 -37
  61. package/dist/components/RadioCard/RadioCard.variants.js +8 -17
  62. package/dist/components/RadioCardGroup/RadioCardGroup.js +22 -23
  63. package/dist/components/RadioCardGroup/RadioCardGroup.variants.js +3 -9
  64. package/dist/components/RadioGroup/RadioGroup.js +30 -31
  65. package/dist/components/RadioGroup/RadioGroup.variants.js +2 -8
  66. package/dist/components/Range/Range.js +28 -34
  67. package/dist/components/Range/Range.variants.js +21 -53
  68. package/dist/components/Sidebar/Sidebar.js +12 -13
  69. package/dist/components/Sidebar/Sidebar.variants.js +30 -56
  70. package/dist/components/Sidebar/components/Footer/Footer.js +5 -17
  71. package/dist/components/Sidebar/components/Footer/Footer.variants.js +9 -16
  72. package/dist/components/Sidebar/components/Logo/Logo.js +5 -15
  73. package/dist/components/Sidebar/components/Logo/Logo.variants.js +20 -36
  74. package/dist/components/Sidebar/components/Navigation/Navigation.js +15 -28
  75. package/dist/components/Sidebar/components/Navigation/Navigation.variants.js +3 -17
  76. package/dist/components/Sidebar/components/NavigationGroup/NavigationGroup.js +21 -34
  77. package/dist/components/Sidebar/components/NavigationGroup/NavigationGroup.variants.js +2 -13
  78. package/dist/components/Sidebar/components/NavigationOption/NavigationOption.js +21 -27
  79. package/dist/components/Sidebar/components/NavigationOption/NavigationOption.variants.js +7 -17
  80. package/dist/components/Sidebar/components/NavigationSeparator/NavigationSeparator.js +7 -19
  81. package/dist/components/Sidebar/components/NavigationSeparator/NavigationSeparator.variants.js +6 -16
  82. package/dist/components/Sidebar/components/NavigationTitle/NavigationTitle.js +8 -21
  83. package/dist/components/Sidebar/components/NavigationTitle/NavigationTitle.variants.js +11 -20
  84. package/dist/components/Sidebar/components/Wrapper/Wrapper.js +41 -44
  85. package/dist/components/Slider/Slider.js +26 -27
  86. package/dist/components/Slider/Slider.variants.js +22 -34
  87. package/dist/components/Switch/Switch.js +103 -106
  88. package/dist/components/Switch/Switch.variants.js +28 -53
  89. package/dist/components/Table/Table.js +27 -0
  90. package/dist/components/Table/Table.variants.js +40 -0
  91. package/dist/components/Table/components/Body.js +18 -0
  92. package/dist/components/Table/components/Filter.js +9 -0
  93. package/dist/components/Table/components/Head.js +18 -0
  94. package/dist/components/Table/components/Row.js +28 -0
  95. package/dist/components/Table/components/index.js +10 -0
  96. package/dist/components/Tag/Tag.js +1 -1
  97. package/dist/components/TagSelect/TagSelect.variants.js +23 -55
  98. package/dist/components/TagSelect/components/Item/Item.js +12 -14
  99. package/dist/components/TagSelect/components/Item/Item.variants.js +11 -10
  100. package/dist/components/TagSelect/components/List/List.js +9 -10
  101. package/dist/components/TagSelect/components/List/List.variants.js +21 -35
  102. package/dist/components/TagSelect/components/Wrapper/Wrapper.js +46 -48
  103. package/dist/components/TextArea/TextArea.js +20 -23
  104. package/dist/components/TextArea/TextArea.variants.js +19 -31
  105. package/dist/components/Toast/Toast.js +110 -116
  106. package/dist/components/Toast/Toast.variants.js +42 -70
  107. package/dist/components/Tooltip/Tooltip.js +21 -27
  108. package/dist/components/Tooltip/Tooltip.variants.js +61 -62
  109. package/dist/components/Typography/Typography.js +23 -19
  110. package/dist/components/Typography/Typography.variants.js +1 -7
  111. package/dist/components/index.js +22 -20
  112. package/dist/contexts/theme.provider.js +37 -39
  113. package/dist/domain/theme.js +0 -0
  114. package/dist/index-AM3avohj.js +133 -0
  115. package/dist/{index-BzaHYXkt.js → index-BOx5P4tS.js} +5 -5
  116. package/dist/index-Bk324h27.js +82 -0
  117. package/dist/{index-4ecjw_Aj.js → index-Bry5AFQ2.js} +1 -1
  118. package/dist/{index-CbTU3cnP.js → index-CWKdynYu.js} +1 -1
  119. package/dist/index-D9BbbgUq.js +47 -0
  120. package/dist/{index-DyKo5ZJT.js → index-DvFiic6N.js} +45 -45
  121. package/dist/{index-Dj1pom3_.js → index-G_6jG4Qc.js} +2 -2
  122. package/dist/{index-D_76wh4w.js → index-YaQrdkGE.js} +3 -3
  123. package/dist/{index-Cva-e5M4.js → index-bYyfdsls.js} +9 -9
  124. package/dist/index-dRxIWVBr.js +313 -0
  125. package/dist/{index-D7QNmo_D.js → index-g-TFwd6Y.js} +41 -41
  126. package/dist/index.d.ts +115 -98
  127. package/dist/index.js +30 -30
  128. package/dist/package.json +37 -36
  129. package/dist/styles.css +1 -1
  130. package/dist/ui/kubefirst-theme.css +296 -0
  131. package/dist/ui/theme.css +6 -0
  132. package/dist/ui/utilities.css +165 -0
  133. package/dist/utils/index.js +675 -424
  134. package/package.json +37 -36
  135. package/dist/components/AlertDialog/AlertDialog.variants.js +0 -15
  136. package/dist/index-B_6_jmOO.js +0 -68
  137. package/dist/index-BbsJ0VIJ.js +0 -47
  138. package/dist/index-CzSBQN5S.js +0 -432
  139. package/dist/index-DUA6Y_AE.js +0 -126
  140. package/dist/plugins/index.js +0 -4
  141. package/dist/plugins/konstruct.js +0 -118
  142. package/dist/plugins/utils/animation.styles.js +0 -162
  143. package/dist/plugins/utils/colors.js +0 -331
  144. package/dist/plugins/utils/index.js +0 -7
package/dist/index.d.ts CHANGED
@@ -1,14 +1,11 @@
1
1
  import { ButtonHTMLAttributes } from 'react';
2
2
  import { ClassProp } from 'class-variance-authority/types';
3
- import { Config } from 'tailwindcss/types/config';
4
3
  import { Context } from 'react';
5
4
  import { FC } from 'react';
6
5
  import { ForwardRefExoticComponent } from 'react';
7
- import { FunctionComponent } from 'react';
8
6
  import { HTMLAttributes } from 'react';
9
7
  import { HtmlHTMLAttributes } from 'react';
10
8
  import { InputHTMLAttributes } from 'react';
11
- import { PluginCreator } from 'tailwindcss/types/config';
12
9
  import { PropsWithChildren } from 'react';
13
10
  import { ReactNode } from 'react';
14
11
  import { RefAttributes } from 'react';
@@ -19,15 +16,16 @@ export declare const Alert: FC<AlertProps>;
19
16
 
20
17
  export declare const AlertDialog: FC<AlertDialogProps>;
21
18
 
22
- declare interface AlertDialogProps extends PropsWithChildren, VariantProps<typeof buttonAlertDialogVariants> {
19
+ declare interface AlertDialogProps extends PropsWithChildren {
23
20
  buttonCancelClassName?: string;
24
21
  buttonCancelText?: string;
25
22
  buttonConfirmClassName?: string;
26
23
  buttonConfirmText?: string;
27
24
  buttonText?: string;
25
+ buttonTriggerClassName?: string;
28
26
  className?: string;
29
27
  description?: string;
30
- o?: string;
28
+ theme?: Theme;
31
29
  title?: string;
32
30
  onConfirm?: () => void;
33
31
  }
@@ -37,10 +35,10 @@ declare interface AlertProps extends VariantProps<typeof alertVariants> {
37
35
  content: string | ReactNode;
38
36
  isVisible?: boolean;
39
37
  showCloseButton?: boolean;
38
+ theme?: Theme;
40
39
  }
41
40
 
42
41
  declare const alertVariants: (props?: ({
43
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
44
42
  type?: "sucess" | "info" | "warning" | "danger" | null | undefined;
45
43
  isVisible?: boolean | null | undefined;
46
44
  } & ClassProp) | undefined) => string;
@@ -54,44 +52,45 @@ declare interface AutocompleteProps extends VariantProps<typeof autocompleteVari
54
52
  labelClassName?: string;
55
53
  name?: string;
56
54
  options: Option_2[];
55
+ placeholder?: string;
57
56
  placeHolderEmptyValues?: string | ReactNode;
58
57
  placeHolderEmptyValuesClassName?: string;
59
- placeholder?: string;
58
+ theme?: Theme;
60
59
  onChange(value: string): void;
61
60
  }
62
61
 
63
62
  declare const autocompleteVariants: (props?: ({
64
63
  variant?: "default" | null | undefined;
65
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
66
64
  } & ClassProp) | undefined) => string;
67
65
 
66
+ declare interface BodyProps extends React.HTMLAttributes<HTMLTableSectionElement>, PropsWithChildren, VariantProps<typeof bodyVariants> {
67
+ }
68
+
69
+ declare const bodyVariants: (props?: ClassProp | undefined) => string;
70
+
68
71
  export declare const Breadcrumb: FC<BreadcrumbProps>;
69
72
 
70
73
  declare interface BreadcrumbProps extends VariantProps<typeof breadcrumbVariants>, HTMLAttributes<HTMLOListElement> {
71
74
  steps: Step[];
72
75
  wrapperClassName?: string;
76
+ theme?: Theme;
73
77
  }
74
78
 
75
79
  declare const breadcrumbVariants: (props?: ({
76
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
77
80
  size?: "base" | "sm" | "lg" | "xl" | null | undefined;
78
81
  } & ClassProp) | undefined) => string;
79
82
 
80
83
  export declare const Button: FC<ButtonProps>;
81
84
 
82
- declare const buttonAlertDialogVariants: (props?: ({
83
- theme?: "kubefirst" | "colony" | null | undefined;
84
- } & ClassProp) | undefined) => string;
85
-
86
85
  declare interface ButtonProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'disabled'>, VariantProps<typeof buttonVariants> {
87
86
  asChild?: boolean;
88
87
  disabled?: boolean;
88
+ theme?: Theme;
89
89
  }
90
90
 
91
91
  declare const buttonVariants: (props?: ({
92
92
  variant?: "danger" | "circle" | "text" | "primary" | "secondary" | null | undefined;
93
93
  version?: "default" | "alternate" | null | undefined;
94
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
95
94
  disabled?: boolean | null | undefined;
96
95
  size?: "medium" | "large" | null | undefined;
97
96
  } & ClassProp) | undefined) => string;
@@ -99,13 +98,13 @@ declare const buttonVariants: (props?: ({
99
98
  export declare const Card: FC<CardProps>;
100
99
 
101
100
  declare interface CardProps extends HTMLAttributes<HTMLDivElement>, VariantProps<typeof cardVariants>, PropsWithChildren {
102
- isActive?: boolean;
103
101
  canHover?: boolean;
102
+ isActive?: boolean;
103
+ theme?: Theme;
104
104
  wrapperClassName?: string;
105
105
  }
106
106
 
107
107
  declare const cardVariants: (props?: ({
108
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
109
108
  isActive?: boolean | null | undefined;
110
109
  canHover?: boolean | null | undefined;
111
110
  } & ClassProp) | undefined) => string;
@@ -121,31 +120,34 @@ declare interface CheckboxProps extends Omit<InputHTMLAttributes<HTMLInputElemen
121
120
  label?: string;
122
121
  labelClassName?: string;
123
122
  name?: string;
123
+ theme?: Theme;
124
124
  onChange?: () => void;
125
125
  }
126
126
 
127
127
  declare const checkboxVariants: (props?: ({
128
128
  variant?: "default" | null | undefined;
129
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
130
129
  checked?: boolean | null | undefined;
131
130
  } & ClassProp) | undefined) => string;
132
131
 
133
- export declare const Divider: FunctionComponent<HTMLAttributes<HTMLDivElement>>;
132
+ export declare const Divider: FC<HTMLAttributes<HTMLDivElement>>;
134
133
 
135
134
  export declare const Dropdown: FC<DropdownProps>;
136
135
 
137
- declare interface DropdownProps extends VariantProps<typeof dropdownVariants> {
138
- defaultValue?: string;
136
+ declare interface DropdownProps extends VariantProps<typeof dropdownVariants>, Omit<React.InputHTMLAttributes<HTMLInputElement>, 'value' | 'onChange'> {
137
+ isLoading?: boolean;
139
138
  label?: string;
140
- name?: string;
139
+ labelClassName?: string;
141
140
  options: Option_3[];
142
- placeholder?: string;
143
- onChange?: (value: Option_3) => void;
141
+ theme?: Theme;
142
+ value?: string;
143
+ onChange?: OnChangeFn;
144
144
  }
145
145
 
146
- declare const dropdownVariants: (props?: ({
147
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
148
- } & ClassProp) | undefined) => string;
146
+ declare const dropdownVariants: (props?: ClassProp | undefined) => string;
147
+
148
+ declare interface FilterProps extends React.InputHTMLAttributes<HTMLInputElement>, PropsWithChildren {
149
+ placeholder?: string;
150
+ }
149
151
 
150
152
  export declare const Footer: FC<FooterProps>;
151
153
 
@@ -153,37 +155,35 @@ declare interface FooterProps extends PropsWithChildren, VariantProps<typeof foo
153
155
  className?: string;
154
156
  }
155
157
 
156
- declare const footerVariants: (props?: ({
157
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
158
- } & ClassProp) | undefined) => string;
158
+ declare const footerVariants: (props?: ClassProp | undefined) => string;
159
159
 
160
160
  declare type HeadingTag = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
161
161
 
162
+ declare interface HeadProps extends React.HTMLAttributes<HTMLTableSectionElement>, PropsWithChildren, VariantProps<typeof headVariants> {
163
+ }
164
+
165
+ declare const headVariants: (props?: ClassProp | undefined) => string;
166
+
162
167
  export declare const Input: ForwardRefExoticComponent<InputProps & RefAttributes<HTMLInputElement>>;
163
168
 
164
169
  declare interface InputProps extends InputHTMLAttributes<HTMLInputElement>, VariantProps<typeof inputVariants> {
170
+ error?: string;
165
171
  label?: string | ReactNode;
166
172
  labelClassName?: string;
167
- error?: string;
173
+ theme?: Theme;
168
174
  }
169
175
 
170
176
  declare const inputVariants: (props?: ({
171
177
  variant?: "error" | "default" | null | undefined;
172
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
173
178
  } & ClassProp) | undefined) => string;
174
179
 
175
- export declare const konstructPlugin: {
176
- handler: PluginCreator;
177
- config?: Partial<Config>;
178
- };
179
-
180
- export declare const Loading: FunctionComponent<LoadingProps>;
180
+ export declare const Loading: FC<LoadingProps>;
181
181
 
182
- declare type LoadingProps = InputHTMLAttributes<SVGSVGElement> & VariantProps<typeof loadingVariants>;
182
+ declare type LoadingProps = InputHTMLAttributes<SVGSVGElement> & VariantProps<typeof loadingVariants> & {
183
+ theme?: Theme;
184
+ };
183
185
 
184
- declare const loadingVariants: (props?: ({
185
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
186
- } & ClassProp) | undefined) => string;
186
+ declare const loadingVariants: (props?: ClassProp | undefined) => string;
187
187
 
188
188
  export declare const Logo: FC<LogoProps>;
189
189
 
@@ -191,9 +191,7 @@ declare interface LogoProps extends PropsWithChildren, VariantProps<typeof logoV
191
191
  className?: string;
192
192
  }
193
193
 
194
- declare const logoVariants: (props?: ({
195
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
196
- } & ClassProp) | undefined) => string;
194
+ declare const logoVariants: (props?: ClassProp | undefined) => string;
197
195
 
198
196
  export declare const Modal: FC<ModalProps> & {
199
197
  Header: FC<ModalChildProps>;
@@ -208,15 +206,14 @@ declare type ModalChildProps = {
208
206
  };
209
207
 
210
208
  declare interface ModalProps extends PropsWithChildren, VariantProps<typeof modalVariants> {
211
- className?: string;
212
209
  buttonCloseClassName?: string;
210
+ className?: string;
213
211
  isOpen?: boolean;
212
+ theme?: Theme;
214
213
  onClose?: () => void;
215
214
  }
216
215
 
217
- declare const modalVariants: (props?: ({
218
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
219
- } & ClassProp) | undefined) => string;
216
+ declare const modalVariants: (props?: ClassProp | undefined) => string;
220
217
 
221
218
  export declare const Navigation: FC<NavigationProps> & NavigationChildrenProps;
222
219
 
@@ -235,9 +232,7 @@ declare interface NavigationGroupProps extends PropsWithChildren, VariantProps<t
235
232
  isVisible?: boolean;
236
233
  }
237
234
 
238
- declare const navigationGroupsVariants: (props?: ({
239
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
240
- } & ClassProp) | undefined) => string;
235
+ declare const navigationGroupsVariants: (props?: ClassProp | undefined) => string;
241
236
 
242
237
  export declare const NavigationOption: FC<NavigationOptionProps>;
243
238
 
@@ -257,7 +252,6 @@ declare type NavigationOptionProps = NavigationOption_2 & ({
257
252
  });
258
253
 
259
254
  declare const navigationOptionVariants: (props?: ({
260
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
261
255
  isActive?: boolean | null | undefined;
262
256
  } & ClassProp) | undefined) => string;
263
257
 
@@ -270,9 +264,7 @@ export declare const NavigationSeparator: FC<NavigationSeparatorProps>;
270
264
  declare interface NavigationSeparatorProps extends Pick<HTMLAttributes<HTMLDivElement>, 'className' | 'style'>, VariantProps<typeof navigationSeparatorVariant> {
271
265
  }
272
266
 
273
- declare const navigationSeparatorVariant: (props?: ({
274
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
275
- } & ClassProp) | undefined) => string;
267
+ declare const navigationSeparatorVariant: (props?: ClassProp | undefined) => string;
276
268
 
277
269
  declare interface NavigationTitleProps extends VariantProps<typeof navigationTitleVariants>, Pick<HtmlHTMLAttributes<HTMLHeadingElement>, 'className'> {
278
270
  title: string;
@@ -280,29 +272,36 @@ declare interface NavigationTitleProps extends VariantProps<typeof navigationTit
280
272
  isVisible?: boolean;
281
273
  }
282
274
 
283
- declare const navigationTitleVariants: (props?: ({
284
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
285
- } & ClassProp) | undefined) => string;
275
+ declare const navigationTitleVariants: (props?: ClassProp | undefined) => string;
286
276
 
287
- declare const navigationVariants: (props?: ({
288
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
289
- } & ClassProp) | undefined) => string;
277
+ declare const navigationVariants: (props?: ClassProp | undefined) => string;
290
278
 
291
279
  export declare const NumberInput: FC<NumberInputProps>;
292
280
 
293
281
  declare interface NumberInputProps extends VariantProps<typeof numberInputVariants> {
294
282
  className?: string;
295
283
  init?: number;
296
- label?: string;
284
+ label?: string | ReactNode;
297
285
  max?: number;
298
286
  min?: number;
299
287
  name?: string;
300
- onChange?: (value: number) => void;
288
+ value?: number;
289
+ theme?: Theme;
290
+ onChange?: ({ target: { value } }: {
291
+ target: {
292
+ value: number;
293
+ };
294
+ }) => void;
301
295
  }
302
296
 
303
- declare const numberInputVariants: (props?: ({
304
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
305
- } & ClassProp) | undefined) => string;
297
+ declare const numberInputVariants: (props?: ClassProp | undefined) => string;
298
+
299
+ declare type OnChangeFn = (params: {
300
+ target: {
301
+ value: string;
302
+ name: string;
303
+ };
304
+ }) => void;
306
305
 
307
306
  declare type Option_2 = {
308
307
  value: string;
@@ -320,12 +319,11 @@ declare interface ProgressBarProps extends VariantProps<typeof progressBarVarian
320
319
  className?: string;
321
320
  label?: string;
322
321
  percent: number;
322
+ theme?: Theme;
323
323
  status?: 'success' | 'progress';
324
324
  }
325
325
 
326
- declare const progressBarVariants: (props?: ({
327
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
328
- } & ClassProp) | undefined) => string;
326
+ declare const progressBarVariants: (props?: ClassProp | undefined) => string;
329
327
 
330
328
  export declare const Radio: FC<RadioProps>;
331
329
 
@@ -340,13 +338,14 @@ declare type RadioCardGroupProps = {
340
338
  direction?: 'row' | 'col';
341
339
  name: string;
342
340
  options: Omit<RadioCardProps, 'name' | 'checked' | 'defaultChecked'>[];
343
- theme?: RadioCardProps['theme'];
341
+ theme?: Theme;
344
342
  wrapperClassName?: string;
345
343
  onValueChange?: (value: string) => void;
346
344
  };
347
345
 
348
346
  declare type RadioCardProps = Omit<CardProps, 'canHover' | 'isActive'> & Pick<RadioProps, 'name' | 'value' | 'checked' | 'onChange' | 'label' | 'disabled' | 'defaultChecked' | 'labelTextClassName'> & {
349
347
  labelWrapperClassName?: string;
348
+ theme?: Theme;
350
349
  };
351
350
 
352
351
  export declare const RadioGroup: FC<RadioGroupProps>;
@@ -359,7 +358,7 @@ declare interface RadioGroupProps {
359
358
  label?: string | ReactNode;
360
359
  name: string;
361
360
  options: Omit<RadioProps, 'name' | 'checked' | 'defaultChecked'>[];
362
- theme?: RadioProps['theme'];
361
+ theme?: Theme;
363
362
  wrapperClassName?: string;
364
363
  onValueChange?: (value: string) => void;
365
364
  }
@@ -373,11 +372,11 @@ declare interface RadioProps extends Omit<InputHTMLAttributes<HTMLInputElement>,
373
372
  name: string;
374
373
  value: string;
375
374
  wrapperClassName?: string;
375
+ theme?: Theme;
376
376
  onChange?: (value: string) => void;
377
377
  }
378
378
 
379
379
  declare const radioVariants: (props?: ({
380
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
381
380
  disabled?: boolean | null | undefined;
382
381
  checked?: boolean | null | undefined;
383
382
  } & ClassProp) | undefined) => string;
@@ -394,10 +393,19 @@ declare interface RangeProps extends VariantProps<typeof rangeVariants> {
394
393
  name?: string;
395
394
  showValue?: boolean;
396
395
  size?: 'sm' | 'md' | 'lg';
396
+ theme?: Theme;
397
+ }
398
+
399
+ declare const rangeVariants: (props?: ClassProp | undefined) => string;
400
+
401
+ declare interface RowProps extends React.HTMLAttributes<HTMLTableRowElement>, PropsWithChildren, VariantProps<typeof rowVariants> {
402
+ width?: string;
403
+ isSelected?: boolean;
404
+ onSelect?: () => void;
397
405
  }
398
406
 
399
- declare const rangeVariants: (props?: ({
400
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
407
+ declare const rowVariants: (props?: ({
408
+ isSelected?: boolean | null | undefined;
401
409
  } & ClassProp) | undefined) => string;
402
410
 
403
411
  export declare const Sidebar: FC<SidebarProps> & SidebarChildrenProps;
@@ -416,6 +424,7 @@ declare interface SidebarProps extends VariantProps<typeof wrapperSiderbarVarian
416
424
  minWith?: number;
417
425
  maxWith?: number;
418
426
  canResize?: boolean;
427
+ theme?: Theme;
419
428
  }
420
429
 
421
430
  export declare const Slider: FC<SliderProps_2>;
@@ -429,11 +438,10 @@ declare interface SliderProps_2 extends VariantProps<typeof sliderVariants> {
429
438
  name?: string;
430
439
  showValue?: boolean;
431
440
  size?: 'sm' | 'md' | 'lg';
441
+ theme?: Theme;
432
442
  }
433
443
 
434
- declare const sliderVariants: (props?: ({
435
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
436
- } & ClassProp) | undefined) => string;
444
+ declare const sliderVariants: (props?: ClassProp | undefined) => string;
437
445
 
438
446
  declare type Step = {
439
447
  label: string;
@@ -450,12 +458,26 @@ declare interface SwitchProps extends VariantProps<typeof switchVariants> {
450
458
  defaultChecked?: boolean;
451
459
  label?: string;
452
460
  name?: string;
461
+ theme?: Theme;
453
462
  thumbClassName?: string;
463
+ value?: boolean;
464
+ onChange?: (e: boolean) => void;
454
465
  }
455
466
 
456
- declare const switchVariants: (props?: ({
457
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
458
- } & ClassProp) | undefined) => string;
467
+ declare const switchVariants: (props?: ClassProp | undefined) => string;
468
+
469
+ export declare const Table: FC<TableProps> & {
470
+ Head: FC<HeadProps>;
471
+ Row: FC<RowProps>;
472
+ Filter: FC<FilterProps>;
473
+ Body: FC<BodyProps>;
474
+ };
475
+
476
+ declare interface TableProps extends React.HTMLAttributes<HTMLTableElement>, PropsWithChildren, VariantProps<typeof tableVariants> {
477
+ theme?: Theme;
478
+ }
479
+
480
+ declare const tableVariants: (props?: ClassProp | undefined) => string;
459
481
 
460
482
  export declare const Tag: FC<TagProps>;
461
483
 
@@ -482,9 +504,7 @@ declare interface TagSelectProps extends VariantProps<typeof tagSelectVariants>
482
504
  multiselect?: boolean;
483
505
  }
484
506
 
485
- declare const tagSelectVariants: (props?: ({
486
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
487
- } & ClassProp) | undefined) => string;
507
+ declare const tagSelectVariants: (props?: ClassProp | undefined) => string;
488
508
 
489
509
  export declare const TextArea: FC<TextAreaProps>;
490
510
 
@@ -493,13 +513,12 @@ declare interface TextAreaProps extends InputHTMLAttributes<HTMLTextAreaElement>
493
513
  label?: string | ReactNode;
494
514
  name?: string;
495
515
  initialValue?: string;
516
+ theme?: Theme;
496
517
  }
497
518
 
498
- declare const textAreaVariants: (props?: ({
499
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
500
- } & ClassProp) | undefined) => string;
519
+ declare const textAreaVariants: (props?: ClassProp | undefined) => string;
501
520
 
502
- export declare type Theme = 'kubefirst' | 'colony' | 'civo' | undefined;
521
+ declare type Theme = 'kubefirst' | 'colony' | 'civo' | 'kubefirst-dark' | 'colony-dark' | 'civo-dark' | undefined;
503
522
 
504
523
  export declare const ThemeContext: Context<ThemeContextType>;
505
524
 
@@ -523,20 +542,19 @@ export declare const Toast: FC<ToastProps>;
523
542
 
524
543
  declare interface ToastProps extends PropsWithChildren, VariantProps<typeof toastVariants> {
525
544
  className?: string;
545
+ closeButtonClassName?: string;
526
546
  description: string | ReactNode;
527
547
  descriptionClassName?: string;
528
548
  duration?: number;
549
+ open: boolean;
529
550
  showCloseButton?: boolean;
551
+ theme?: Theme;
530
552
  title: string | ReactNode;
531
553
  titleClassName?: string;
532
- open: boolean;
533
554
  setOpen: (open: boolean) => void;
534
- closeButtonClassName?: string;
535
555
  }
536
556
 
537
- declare const toastVariants: (props?: ({
538
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
539
- } & ClassProp) | undefined) => string;
557
+ declare const toastVariants: (props?: ClassProp | undefined) => string;
540
558
 
541
559
  export declare const Tooltip: FC<TooltipProps>;
542
560
 
@@ -544,31 +562,30 @@ declare interface TooltipProps extends PropsWithChildren, VariantProps<typeof to
544
562
  content: ReactNode | string;
545
563
  className?: string;
546
564
  wrapperClassName?: string;
565
+ theme?: Theme;
547
566
  }
548
567
 
549
568
  declare const tooltipVariants: (props?: ({
550
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
551
569
  position?: "left" | "right" | "top" | "bottom" | null | undefined;
552
570
  } & ClassProp) | undefined) => string;
553
571
 
554
- export declare const Typography: FunctionComponent<TypographyProps>;
572
+ export declare const Typography: FC<TypographyProps>;
555
573
 
556
574
  declare interface TypographyProps extends InputHTMLAttributes<HTMLParagraphElement>, VariantProps<typeof typographyVariants> {
575
+ asChild?: boolean;
557
576
  children: ReactNode;
558
577
  component?: HeadingTag | 'p' | 'span';
578
+ theme?: Theme;
559
579
  }
560
580
 
561
581
  declare const typographyVariants: (props?: ({
562
582
  variant?: "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "tooltip" | "subtitle1" | "subtitle2" | "subtitle3" | "labelLarge" | "labelMedium" | "labelSmall" | "buttonSmall" | "body1" | "body2" | "body3" | null | undefined;
563
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
564
583
  } & ClassProp) | undefined) => string;
565
584
 
566
585
  export declare const useTheme: () => ThemeProps;
567
586
 
568
587
  export declare const useToggle: (initialState?: boolean) => [boolean, (value?: boolean) => void];
569
588
 
570
- declare const wrapperSiderbarVariants: (props?: ({
571
- theme?: "kubefirst" | "colony" | "civo" | null | undefined;
572
- } & ClassProp) | undefined) => string;
589
+ declare const wrapperSiderbarVariants: (props?: ClassProp | undefined) => string;
573
590
 
574
591
  export { }
package/dist/index.js CHANGED
@@ -4,17 +4,17 @@ import { Autocomplete as x } from "./components/Autocomplete/Autocomplete.js";
4
4
  import { Breadcrumb as a } from "./components/Breadcrumb/Breadcrumb.js";
5
5
  import { Button as d } from "./components/Button/Button.js";
6
6
  import { Card as n } from "./components/Card/Card.js";
7
- import { Checkbox as l } from "./components/Checkbox/Checkbox.js";
8
- import { Dropdown as s } from "./components/Dropdown/Dropdown.js";
9
- import { Input as h } from "./components/Input/Input.js";
10
- import { M as C } from "./Modal-B-E9uaA6.js";
11
- import { NumberInput as R } from "./components/NumberInput/NumberInput.js";
12
- import { ProgressBar as b } from "./components/ProgressBar/ProgressBar.js";
7
+ import { Checkbox as T } from "./components/Checkbox/Checkbox.js";
8
+ import { Dropdown as h } from "./components/Dropdown/Dropdown.js";
9
+ import { Input as v } from "./components/Input/Input.js";
10
+ import { M as c } from "./Modal-i7eolhYH.js";
11
+ import { NumberInput as N } from "./components/NumberInput/NumberInput.js";
12
+ import { ProgressBar as S } from "./components/ProgressBar/ProgressBar.js";
13
13
  import { Radio as B } from "./components/Radio/Radio.js";
14
14
  import { RadioCard as G } from "./components/RadioCard/RadioCard.js";
15
- import { RadioCardGroup as k } from "./components/RadioCardGroup/RadioCardGroup.js";
16
- import { RadioGroup as y } from "./components/RadioGroup/RadioGroup.js";
17
- import { Range as L } from "./components/Range/Range.js";
15
+ import { RadioCardGroup as y } from "./components/RadioCardGroup/RadioCardGroup.js";
16
+ import { RadioGroup as L } from "./components/RadioGroup/RadioGroup.js";
17
+ import { Range as P } from "./components/Range/Range.js";
18
18
  import { Footer as F } from "./components/Sidebar/components/Footer/Footer.js";
19
19
  import { Logo as j } from "./components/Sidebar/components/Logo/Logo.js";
20
20
  import { Navigation as z } from "./components/Sidebar/components/Navigation/Navigation.js";
@@ -31,12 +31,12 @@ import { Toast as xo } from "./components/Toast/Toast.js";
31
31
  import { Tooltip as ao } from "./components/Tooltip/Tooltip.js";
32
32
  import { Loading as go } from "./components/Loading/Loading.js";
33
33
  import { Typography as uo } from "./components/Typography/Typography.js";
34
- import { Divider as To } from "./components/Divider/Divider.js";
35
- import { ThemeContext as co } from "./contexts/theme.context.js";
36
- import { useTheme as vo } from "./contexts/theme.hook.js";
37
- import { ThemeProvider as No } from "./contexts/theme.provider.js";
38
- import { useToggle as So } from "./hooks/useToggle.js";
39
- import { konstructPlugin as Ao } from "./plugins/konstruct.js";
34
+ import { Divider as lo } from "./components/Divider/Divider.js";
35
+ import { Table as so } from "./components/Table/Table.js";
36
+ import { ThemeContext as bo } from "./contexts/theme.context.js";
37
+ import { useTheme as Co } from "./contexts/theme.hook.js";
38
+ import { ThemeProvider as Ro } from "./contexts/theme.provider.js";
39
+ import { useToggle as Ao } from "./hooks/useToggle.js";
40
40
  export {
41
41
  e as Alert,
42
42
  p as AlertDialog,
@@ -44,37 +44,37 @@ export {
44
44
  a as Breadcrumb,
45
45
  d as Button,
46
46
  n as Card,
47
- l as Checkbox,
48
- To as Divider,
49
- s as Dropdown,
47
+ T as Checkbox,
48
+ lo as Divider,
49
+ h as Dropdown,
50
50
  F as Footer,
51
- h as Input,
51
+ v as Input,
52
52
  go as Loading,
53
53
  j as Logo,
54
- C as Modal,
54
+ c as Modal,
55
55
  z as Navigation,
56
56
  H as NavigationGroup,
57
57
  K as NavigationOption,
58
58
  U as NavigationSeparator,
59
- R as NumberInput,
60
- b as ProgressBar,
59
+ N as NumberInput,
60
+ S as ProgressBar,
61
61
  B as Radio,
62
62
  G as RadioCard,
63
- k as RadioCardGroup,
64
- y as RadioGroup,
65
- L as Range,
63
+ y as RadioCardGroup,
64
+ L as RadioGroup,
65
+ P as Range,
66
66
  W as Sidebar,
67
67
  Y as Slider,
68
68
  _ as Switch,
69
+ so as Table,
69
70
  oo as Tag,
70
71
  eo as TagSelect,
71
72
  po as TextArea,
72
- co as ThemeContext,
73
- No as ThemeProvider,
73
+ bo as ThemeContext,
74
+ Ro as ThemeProvider,
74
75
  xo as Toast,
75
76
  ao as Tooltip,
76
77
  uo as Typography,
77
- Ao as konstructPlugin,
78
- vo as useTheme,
79
- So as useToggle
78
+ Co as useTheme,
79
+ Ao as useToggle
80
80
  };