@particle-network/ui-react 0.4.5-beta.2 → 0.4.5-beta.21

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 (37) hide show
  1. package/dist/components/UXButton/button-theme.d.ts +3 -0
  2. package/dist/components/UXButton/button-theme.js +36 -9
  3. package/dist/components/UXButton/use-button.js +2 -1
  4. package/dist/components/UXChip/chip.extend.d.ts +1 -1
  5. package/dist/components/UXChip/chip.extend.js +17 -2
  6. package/dist/components/UXChip/index.d.ts +1 -1
  7. package/dist/components/UXInput/index.d.ts +2 -0
  8. package/dist/components/UXInput/input.extend.d.ts +2 -0
  9. package/dist/components/UXModal/index.js +2 -5
  10. package/dist/components/UXNumberInput/number-input.extend.d.ts +1 -0
  11. package/dist/components/UXSlider/index.d.ts +5 -0
  12. package/dist/components/UXSlider/index.js +3 -0
  13. package/dist/components/UXSlider/slider-theme.d.ts +521 -0
  14. package/dist/components/UXSlider/slider-theme.js +464 -0
  15. package/dist/components/UXSlider/slider-thumb.d.ts +4 -0
  16. package/dist/components/UXSlider/slider-thumb.js +33 -0
  17. package/dist/components/UXSlider/slider.d.ts +4 -0
  18. package/dist/components/UXSlider/slider.js +77 -0
  19. package/dist/components/UXSlider/use-slider-thumb.d.ts +61 -0
  20. package/dist/components/UXSlider/use-slider-thumb.js +79 -0
  21. package/dist/components/UXSlider/use-slider.d.ts +182 -0
  22. package/dist/components/UXSlider/use-slider.js +277 -0
  23. package/dist/components/UXTabSwitch/index.d.ts +2 -0
  24. package/dist/components/UXTabSwitch/index.js +3 -1
  25. package/dist/components/UXTabs/tabs.classes.js +4 -4
  26. package/dist/components/UXThemeSwitch/theme-switch.d.ts +4 -2
  27. package/dist/components/UXThemeSwitch/theme-switch.js +11 -8
  28. package/dist/components/UXToast/index.js +2 -2
  29. package/dist/components/UXTooltip/index.d.ts +2 -2
  30. package/dist/components/index.d.ts +1 -0
  31. package/dist/components/index.js +1 -0
  32. package/dist/utils/classes.d.ts +11 -0
  33. package/dist/utils/classes.js +12 -1
  34. package/dist/utils/input-classes.d.ts +37 -2
  35. package/dist/utils/input-classes.js +65 -6
  36. package/package.json +5 -5
  37. package/tailwind-preset.js +1 -1
@@ -44,7 +44,7 @@ const show = (props)=>{
44
44
  base
45
45
  ],
46
46
  description: [
47
- 'text-foreground text-xs font-medium me-0 leading-4 line-clamp-4',
47
+ 'text-tertiary-foreground text-xs font-medium me-0 leading-4 line-clamp-4',
48
48
  'flat' === variant && 'text-white',
49
49
  hasLongWord(description) && 'break-all',
50
50
  descriptionClassName
@@ -72,7 +72,7 @@ const show = (props)=>{
72
72
  icon: icon ?? getIcon(type),
73
73
  hideIcon: !icon && !getIcon(type),
74
74
  closeIcon: /*#__PURE__*/ jsx(CloseIcon, {
75
- className: 'flat' === variant ? 'text-white' : 'text-foreground'
75
+ className: 'flat' === variant ? 'text-white' : 'text-tertiary-foreground'
76
76
  }),
77
77
  loadingComponent: /*#__PURE__*/ jsx(UXSpinner, {
78
78
  size: 18
@@ -1,4 +1,4 @@
1
1
  import React from 'react';
2
- import ExtendedTooltip from './tooltip.extend';
3
- export type UXTooltipProps = React.ComponentPropsWithRef<typeof ExtendedTooltip>;
2
+ import type { TooltipProps } from '@heroui/tooltip';
3
+ export type UXTooltipProps = TooltipProps;
4
4
  export declare const UXTooltip: React.FC<UXTooltipProps>;
@@ -21,6 +21,7 @@ export * from './UXPagination';
21
21
  export * from './UXPopover';
22
22
  export * from './UXRadio';
23
23
  export * from './UXSelect';
24
+ export * from './UXSlider';
24
25
  export * from './UXSpinner';
25
26
  export * from './UXSwitch';
26
27
  export * from './UXTable';
@@ -21,6 +21,7 @@ export * from "./UXPagination/index.js";
21
21
  export * from "./UXPopover/index.js";
22
22
  export * from "./UXRadio/index.js";
23
23
  export * from "./UXSelect/index.js";
24
+ export * from "./UXSlider/index.js";
24
25
  export * from "./UXSpinner/index.js";
25
26
  export * from "./UXSwitch/index.js";
26
27
  export * from "./UXTable/index.js";
@@ -33,3 +33,14 @@ export declare const collapseAdjacentVariantBorders: {
33
33
  bearish: string[];
34
34
  };
35
35
  export declare const hiddenInputClasses: string[];
36
+ export declare const bgWithTextColorClasses: {
37
+ readonly foreground: "bg-foreground text-background";
38
+ readonly primary: "bg-primary text-primary-foreground";
39
+ readonly secondary: "bg-secondary text-secondary-foreground";
40
+ readonly success: "bg-success text-success-foreground";
41
+ readonly warning: "bg-warning text-warning-foreground";
42
+ readonly alert: "bg-alert text-alert-foreground";
43
+ readonly danger: "bg-danger text-danger-foreground";
44
+ readonly bullish: "bg-bullish text-bullish-foreground";
45
+ readonly bearish: "bg-bearish text-bearish-foreground";
46
+ };
@@ -84,4 +84,15 @@ const hiddenInputClasses = [
84
84
  'cursor-pointer',
85
85
  'disabled:cursor-default'
86
86
  ];
87
- export { absoluteFullClasses, baseStyles, collapseAdjacentVariantBorders, dataFocusVisibleClasses, focusVisibleClasses, groupDataFocusVisibleClasses, hiddenInputClasses, ringClasses, translateCenterClasses };
87
+ const bgWithTextColorClasses = {
88
+ foreground: 'bg-foreground text-background',
89
+ primary: 'bg-primary text-primary-foreground',
90
+ secondary: 'bg-secondary text-secondary-foreground',
91
+ success: 'bg-success text-success-foreground',
92
+ warning: 'bg-warning text-warning-foreground',
93
+ alert: 'bg-alert text-alert-foreground',
94
+ danger: 'bg-danger text-danger-foreground',
95
+ bullish: 'bg-bullish text-bullish-foreground',
96
+ bearish: 'bg-bearish text-bearish-foreground'
97
+ };
98
+ export { absoluteFullClasses, baseStyles, bgWithTextColorClasses, collapseAdjacentVariantBorders, dataFocusVisibleClasses, focusVisibleClasses, groupDataFocusVisibleClasses, hiddenInputClasses, ringClasses, translateCenterClasses };
@@ -8,6 +8,7 @@ export declare const inputClasses: {
8
8
  isDisabled: boolean;
9
9
  hideStepper: boolean;
10
10
  textAlign: string;
11
+ isColorText: boolean;
11
12
  };
12
13
  variants: {
13
14
  variant: {
@@ -29,10 +30,13 @@ export declare const inputClasses: {
29
30
  input: string;
30
31
  };
31
32
  };
33
+ isColorText: {
34
+ true: {};
35
+ false: {};
36
+ };
32
37
  color: {
33
38
  default: {
34
39
  inputWrapper: string;
35
- input: string;
36
40
  };
37
41
  primary: {
38
42
  inputWrapper: string;
@@ -40,7 +44,6 @@ export declare const inputClasses: {
40
44
  };
41
45
  secondary: {
42
46
  inputWrapper: string;
43
- input: string;
44
47
  };
45
48
  success: {
46
49
  inputWrapper: string;
@@ -166,6 +169,7 @@ export declare const inputClasses: {
166
169
  variant?: undefined;
167
170
  color?: undefined;
168
171
  isInvalid?: undefined;
172
+ isColorText?: undefined;
169
173
  labelPlacement?: undefined;
170
174
  radius?: undefined;
171
175
  disableAnimation?: undefined;
@@ -182,6 +186,7 @@ export declare const inputClasses: {
182
186
  stepperButton?: undefined;
183
187
  };
184
188
  size?: undefined;
189
+ isColorText?: undefined;
185
190
  labelPlacement?: undefined;
186
191
  radius?: undefined;
187
192
  disableAnimation?: undefined;
@@ -198,6 +203,24 @@ export declare const inputClasses: {
198
203
  stepperButton?: undefined;
199
204
  };
200
205
  size?: undefined;
206
+ isColorText?: undefined;
207
+ labelPlacement?: undefined;
208
+ radius?: undefined;
209
+ disableAnimation?: undefined;
210
+ isMultiline?: undefined;
211
+ } | {
212
+ isColorText: boolean;
213
+ color: string;
214
+ class: {
215
+ input: string;
216
+ inputWrapper?: undefined;
217
+ label?: undefined;
218
+ innerWrapper?: undefined;
219
+ stepperButton?: undefined;
220
+ };
221
+ size?: undefined;
222
+ variant?: undefined;
223
+ isInvalid?: undefined;
201
224
  labelPlacement?: undefined;
202
225
  radius?: undefined;
203
226
  disableAnimation?: undefined;
@@ -215,6 +238,7 @@ export declare const inputClasses: {
215
238
  size?: undefined;
216
239
  variant?: undefined;
217
240
  isInvalid?: undefined;
241
+ isColorText?: undefined;
218
242
  radius?: undefined;
219
243
  disableAnimation?: undefined;
220
244
  isMultiline?: undefined;
@@ -231,6 +255,7 @@ export declare const inputClasses: {
231
255
  variant?: undefined;
232
256
  color?: undefined;
233
257
  isInvalid?: undefined;
258
+ isColorText?: undefined;
234
259
  labelPlacement?: undefined;
235
260
  disableAnimation?: undefined;
236
261
  isMultiline?: undefined;
@@ -247,6 +272,7 @@ export declare const inputClasses: {
247
272
  variant?: undefined;
248
273
  color?: undefined;
249
274
  isInvalid?: undefined;
275
+ isColorText?: undefined;
250
276
  labelPlacement?: undefined;
251
277
  disableAnimation?: undefined;
252
278
  isMultiline?: undefined;
@@ -263,6 +289,7 @@ export declare const inputClasses: {
263
289
  size?: undefined;
264
290
  color?: undefined;
265
291
  isInvalid?: undefined;
292
+ isColorText?: undefined;
266
293
  labelPlacement?: undefined;
267
294
  radius?: undefined;
268
295
  isMultiline?: undefined;
@@ -279,6 +306,7 @@ export declare const inputClasses: {
279
306
  variant?: undefined;
280
307
  color?: undefined;
281
308
  isInvalid?: undefined;
309
+ isColorText?: undefined;
282
310
  radius?: undefined;
283
311
  disableAnimation?: undefined;
284
312
  isMultiline?: undefined;
@@ -295,6 +323,7 @@ export declare const inputClasses: {
295
323
  };
296
324
  color?: undefined;
297
325
  isInvalid?: undefined;
326
+ isColorText?: undefined;
298
327
  radius?: undefined;
299
328
  disableAnimation?: undefined;
300
329
  isMultiline?: undefined;
@@ -311,6 +340,7 @@ export declare const inputClasses: {
311
340
  variant?: undefined;
312
341
  color?: undefined;
313
342
  isInvalid?: undefined;
343
+ isColorText?: undefined;
314
344
  radius?: undefined;
315
345
  disableAnimation?: undefined;
316
346
  isMultiline?: undefined;
@@ -327,6 +357,7 @@ export declare const inputClasses: {
327
357
  variant?: undefined;
328
358
  color?: undefined;
329
359
  isInvalid?: undefined;
360
+ isColorText?: undefined;
330
361
  radius?: undefined;
331
362
  disableAnimation?: undefined;
332
363
  isMultiline?: undefined;
@@ -343,6 +374,7 @@ export declare const inputClasses: {
343
374
  size?: undefined;
344
375
  color?: undefined;
345
376
  isInvalid?: undefined;
377
+ isColorText?: undefined;
346
378
  radius?: undefined;
347
379
  disableAnimation?: undefined;
348
380
  isMultiline?: undefined;
@@ -359,6 +391,7 @@ export declare const inputClasses: {
359
391
  variant?: undefined;
360
392
  color?: undefined;
361
393
  isInvalid?: undefined;
394
+ isColorText?: undefined;
362
395
  radius?: undefined;
363
396
  disableAnimation?: undefined;
364
397
  isMultiline?: undefined;
@@ -375,6 +408,7 @@ export declare const inputClasses: {
375
408
  };
376
409
  color?: undefined;
377
410
  isInvalid?: undefined;
411
+ isColorText?: undefined;
378
412
  radius?: undefined;
379
413
  disableAnimation?: undefined;
380
414
  isMultiline?: undefined;
@@ -392,6 +426,7 @@ export declare const inputClasses: {
392
426
  };
393
427
  color?: undefined;
394
428
  isInvalid?: undefined;
429
+ isColorText?: undefined;
395
430
  radius?: undefined;
396
431
  disableAnimation?: undefined;
397
432
  })[];
@@ -7,7 +7,8 @@ const inputClasses = {
7
7
  labelPlacement: 'outside',
8
8
  isDisabled: false,
9
9
  hideStepper: true,
10
- textAlign: 'left'
10
+ textAlign: 'left',
11
+ isColorText: false
11
12
  },
12
13
  variants: {
13
14
  variant: {
@@ -38,18 +39,20 @@ const inputClasses = {
38
39
  input: 'text-right'
39
40
  }
40
41
  },
42
+ isColorText: {
43
+ true: {},
44
+ false: {}
45
+ },
41
46
  color: {
42
47
  default: {
43
- inputWrapper: 'caret-foreground',
44
- input: 'text-foreground'
48
+ inputWrapper: 'caret-foreground'
45
49
  },
46
50
  primary: {
47
51
  inputWrapper: 'caret-primary',
48
52
  stepperButton: 'text-primary'
49
53
  },
50
54
  secondary: {
51
- inputWrapper: 'caret-foreground',
52
- input: 'text-secondary'
55
+ inputWrapper: 'caret-foreground'
53
56
  },
54
57
  success: {
55
58
  inputWrapper: 'caret-success',
@@ -190,7 +193,7 @@ const inputClasses = {
190
193
  class: {
191
194
  inputWrapper: 'bg-background-200 text-tertiary font-medium',
192
195
  label: 'font-medium',
193
- input: '!outline-none placeholder:text-tertiary dark:placeholder:text-tertiary placeholder:font-medium font-medium text-foreground'
196
+ input: '!outline-none placeholder:text-tertiary placeholder:font-medium font-medium text-foreground'
194
197
  }
195
198
  },
196
199
  {
@@ -353,6 +356,62 @@ const inputClasses = {
353
356
  ]
354
357
  }
355
358
  },
359
+ {
360
+ isColorText: true,
361
+ color: 'default',
362
+ class: {
363
+ input: 'text-foreground'
364
+ }
365
+ },
366
+ {
367
+ isColorText: true,
368
+ color: 'primary',
369
+ class: {
370
+ input: 'text-primary'
371
+ }
372
+ },
373
+ {
374
+ isColorText: true,
375
+ color: 'secondary',
376
+ class: {
377
+ input: 'text-secondary'
378
+ }
379
+ },
380
+ {
381
+ isColorText: true,
382
+ color: 'success',
383
+ class: {
384
+ input: 'text-success'
385
+ }
386
+ },
387
+ {
388
+ isColorText: true,
389
+ color: 'warning',
390
+ class: {
391
+ input: 'text-warning'
392
+ }
393
+ },
394
+ {
395
+ isColorText: true,
396
+ color: 'danger',
397
+ class: {
398
+ input: 'text-danger'
399
+ }
400
+ },
401
+ {
402
+ isColorText: true,
403
+ color: 'bullish',
404
+ class: {
405
+ input: 'text-bullish'
406
+ }
407
+ },
408
+ {
409
+ isColorText: true,
410
+ color: 'bearish',
411
+ class: {
412
+ input: 'text-bearish'
413
+ }
414
+ },
356
415
  {
357
416
  labelPlacement: 'inside',
358
417
  color: 'default',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@particle-network/ui-react",
3
- "version": "0.4.5-beta.2",
3
+ "version": "0.4.5-beta.21",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": {
@@ -38,8 +38,8 @@
38
38
  "@rslib/core": "^0.12.3",
39
39
  "@types/react": "^19.1.10",
40
40
  "react": "^19.1.0",
41
- "@particle-network/eslint-config": "0.3.0",
42
- "@particle-network/lintstaged-config": "0.1.0"
41
+ "@particle-network/lintstaged-config": "0.1.0",
42
+ "@particle-network/eslint-config": "0.3.0"
43
43
  },
44
44
  "peerDependencies": {
45
45
  "react": ">=16.9.0",
@@ -49,8 +49,8 @@
49
49
  "ahooks": "^3.9.4",
50
50
  "copy-to-clipboard": "^3.3.3",
51
51
  "zustand": "^5.0.8",
52
- "@particle-network/icons": "0.4.2-beta.2",
53
- "@particle-network/ui-shared": "0.3.2-beta.2"
52
+ "@particle-network/icons": "0.4.2-beta.9",
53
+ "@particle-network/ui-shared": "0.3.2-beta.5"
54
54
  },
55
55
  "scripts": {
56
56
  "build": "rslib build",
@@ -1094,7 +1094,7 @@ module.exports = {
1094
1094
  },
1095
1095
  },
1096
1096
  },
1097
- custom: {
1097
+ 'product-test': {
1098
1098
  extend: 'dark',
1099
1099
  colors: {
1100
1100
  default: {