@particle-network/ui-react 0.4.0-beta.2 → 0.4.0-beta.20

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/ProgressWrapper/index.d.ts +1 -1
  2. package/dist/components/ProgressWrapper/index.js +18 -3
  3. package/dist/components/UXAutocomplete/index.d.ts +5 -0
  4. package/dist/components/UXAutocomplete/index.js +72 -0
  5. package/dist/components/UXDrawer/index.d.ts +9 -0
  6. package/dist/components/UXDrawer/index.js +89 -0
  7. package/dist/components/UXDropdown/dropdown-item.js +1 -1
  8. package/dist/components/UXEmpty/index.js +3 -1
  9. package/dist/components/UXInput/index.d.ts +28 -28
  10. package/dist/components/UXInput/input.extend.d.ts +28 -28
  11. package/dist/components/UXModal/index.js +3 -1
  12. package/dist/components/UXSelect/index.js +2 -2
  13. package/dist/components/UXSwitch/index.d.ts +17 -17
  14. package/dist/components/UXSwitch/switch.extend.d.ts +17 -17
  15. package/dist/components/UXTable/index.d.ts +17 -17
  16. package/dist/components/UXTable/table.extend.d.ts +17 -17
  17. package/dist/components/UXTabs/tabs.classes.js +7 -7
  18. package/dist/components/UXThemeSwitch/index.d.ts +0 -1
  19. package/dist/components/UXThemeSwitch/index.js +0 -1
  20. package/dist/components/UXThemeSwitch/theme-item.d.ts +1 -1
  21. package/dist/components/UXThemeSwitch/theme-item.js +5 -4
  22. package/dist/components/UXThemeSwitch/theme-switch.js +72 -86
  23. package/dist/components/UXThemeSwitch/use-color-scheme.d.ts +1 -1
  24. package/dist/components/UXThemeSwitch/use-theme-color.d.ts +1 -19
  25. package/dist/components/UXThemeSwitch/use-theme-store.d.ts +1 -6
  26. package/dist/components/UXThemeSwitch/use-theme-store.js +2 -6
  27. package/dist/components/UXThemeSwitch/use-theme.d.ts +2 -4
  28. package/dist/components/UXThemeSwitch/use-theme.js +65 -50
  29. package/dist/components/UXToast/index.d.ts +7 -4
  30. package/dist/components/UXToast/index.js +21 -17
  31. package/dist/components/UXTooltip/tooltip.extend.d.ts +19 -19
  32. package/dist/components/index.d.ts +2 -0
  33. package/dist/components/index.js +2 -0
  34. package/package.json +6 -7
  35. package/tailwind-preset.js +162 -63
  36. package/dist/components/UXThemeSwitch/theme-data.d.ts +0 -29
  37. package/dist/components/UXThemeSwitch/theme-data.js +0 -304
@@ -24,7 +24,7 @@ export interface ProgressWrapperProps extends React.HTMLAttributes<HTMLDivElemen
24
24
  /**
25
25
  * 进度条颜色
26
26
  */
27
- color?: UXForegroundColor | 'transparent';
27
+ color?: UXForegroundColor | 'transparent' | `#${string}`;
28
28
  /**
29
29
  * 进度条 SVG 样式
30
30
  */
@@ -2,10 +2,12 @@
2
2
  import { jsx, jsxs } from "react/jsx-runtime";
3
3
  import { useMemo, useRef } from "react";
4
4
  import { cn } from "@heroui/theme";
5
- import { getHexColorFromCSSVariable, radiusMap } from "@particle-network/ui-shared";
5
+ import { radiusMap } from "@particle-network/ui-shared";
6
6
  import { useSize } from "ahooks";
7
7
  import { Center } from "../layout/index.js";
8
+ import { useThemeColor } from "../UXThemeSwitch/use-theme-color.js";
8
9
  const ProgressWrapper = ({ className, value = 0, width, height, radius = 'sm', strokeWidth = 1, color = 'primary', children, svgClassName, ...restProps })=>{
10
+ const uxColors = useThemeColor();
9
11
  const autoLayout = !width && !height;
10
12
  const containerRef = useRef(null);
11
13
  const { width: childWidth, height: childHeight } = useSize(containerRef) ?? {
@@ -34,8 +36,21 @@ const ProgressWrapper = ({ className, value = 0, width, height, radius = 'sm', s
34
36
  const rectXY = strokeWidth / 2;
35
37
  const perimeter = 2 * (rectWidth + rectHeight);
36
38
  const strokeDashoffset = perimeter * (1 - clampedProgress / 100);
37
- const colorValue = 'transparent' === color ? 'transparent' : getHexColorFromCSSVariable(color);
38
- const trackColor = 'transparent' === color ? 'transparent' : `${colorValue}40`;
39
+ const colorValue = useMemo(()=>{
40
+ if ('transparent' === color) return 'transparent';
41
+ if (color.startsWith('#')) return color;
42
+ return uxColors[color];
43
+ }, [
44
+ color,
45
+ uxColors
46
+ ]);
47
+ const trackColor = useMemo(()=>{
48
+ if ('transparent' === color) return 'transparent';
49
+ return `${colorValue}40`;
50
+ }, [
51
+ color,
52
+ colorValue
53
+ ]);
39
54
  const radiusValue = 'number' == typeof radius ? radius : radiusMap[radius];
40
55
  const createPathData = (x, y, w, h, r)=>{
41
56
  if (0 === r) return `
@@ -0,0 +1,5 @@
1
+ import React from 'react';
2
+ import { type AutocompleteProps } from '@heroui/autocomplete';
3
+ export type UXAutocompleteProps = AutocompleteProps;
4
+ export declare const UXAutocomplete: React.FC<UXAutocompleteProps>;
5
+ export { AutocompleteItem as UXAutocompleteItem, AutocompleteSection as UXAutocompleteSection, } from '@heroui/autocomplete';
@@ -0,0 +1,72 @@
1
+ import { jsx } from "react/jsx-runtime";
2
+ import "react";
3
+ import { Autocomplete, AutocompleteItem, AutocompleteSection } from "@heroui/autocomplete";
4
+ import { ChevronDownIcon } from "../../icons/index.js";
5
+ const UXAutocomplete = (props)=>{
6
+ const { fullWidth = false, classNames = {}, radius = 'sm', labelPlacement = 'outside-top', ...restProps } = props;
7
+ const { base, popoverContent, selectorButton, endContentWrapper, clearButton, listboxWrapper } = classNames;
8
+ return /*#__PURE__*/ jsx(Autocomplete, {
9
+ fullWidth: fullWidth,
10
+ classNames: {
11
+ base: [
12
+ 'ux-base',
13
+ base
14
+ ],
15
+ popoverContent: [
16
+ 'ux-popover-content',
17
+ popoverContent
18
+ ],
19
+ selectorButton: [
20
+ 'ux-selector-button w-[30px] h-[30px] min-w-[30px] min-h-[30px] rounded-small text-secondary',
21
+ selectorButton
22
+ ],
23
+ endContentWrapper: [
24
+ 'ux-end-content-wrapper',
25
+ endContentWrapper
26
+ ],
27
+ clearButton: [
28
+ 'ux-clear-button',
29
+ clearButton
30
+ ],
31
+ listboxWrapper: [
32
+ 'ux-listbox-wrapper p-0',
33
+ listboxWrapper
34
+ ]
35
+ },
36
+ labelPlacement: labelPlacement,
37
+ selectorIcon: /*#__PURE__*/ jsx(ChevronDownIcon, {}),
38
+ inputProps: {
39
+ classNames: {
40
+ label: 'text-tiny text-foreground-300',
41
+ inputWrapper: 'text-tiny h-[30px] min-h-[30px] rounded-small px-2.5',
42
+ input: 'text-tiny !outline-none',
43
+ clearButton: 'text-large'
44
+ }
45
+ },
46
+ popoverProps: {
47
+ isOpen: true,
48
+ classNames: {
49
+ base: 'before:bg-content1 before:shadow-box',
50
+ content: 'bg-content1 text-foreground-300 shadow-box text-tiny antialiased p-0'
51
+ }
52
+ },
53
+ listboxProps: {
54
+ classNames: {
55
+ base: 'p-md',
56
+ list: 'gap-0 [&_[data-slot="heading"]]:text-small [&_[data-slot="heading"]]:font-medium'
57
+ },
58
+ itemClasses: {
59
+ base: '!outline-none min-h-8 px-md rounded-small text-foreground-300 !outline-none data-[hover=true]:bg-background-200 data-[focus-visible=true]:bg-background-200 data-[focus-visible=true]:dark:bg-background-200 data-[hover=true]:text-default-foreground data-[selectable=true]:focus:!bg-background-200 data-[selectable=true]:focus:dark:!bg-background-200 gap-1',
60
+ title: 'text-tiny font-medium antialiased',
61
+ selectedIcon: '[&>svg>polyline]:stroke-[2.5]'
62
+ }
63
+ },
64
+ scrollShadowProps: {
65
+ isEnabled: false
66
+ },
67
+ radius: radius,
68
+ ...restProps
69
+ });
70
+ };
71
+ UXAutocomplete.displayName = 'UX.Autocomplete';
72
+ export { UXAutocomplete, AutocompleteItem as UXAutocompleteItem, AutocompleteSection as UXAutocompleteSection };
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ import { type DrawerProps } from '@heroui/drawer';
3
+ export type UXDrawerProps = Omit<DrawerProps, 'closeButton'> & {
4
+ title?: React.ReactNode;
5
+ footer?: React.ReactNode;
6
+ tip?: React.ReactNode;
7
+ titleAlign?: 'left' | 'center';
8
+ };
9
+ export declare const UXDrawer: React.FC<UXDrawerProps>;
@@ -0,0 +1,89 @@
1
+ import { jsx, jsxs } from "react/jsx-runtime";
2
+ import "react";
3
+ import { Drawer, DrawerBody, DrawerContent, DrawerFooter, DrawerHeader } from "@heroui/drawer";
4
+ import CloseIcon from "@particle-network/icons/web/CloseIcon";
5
+ import { Center, Circle, Flex } from "../layout/index.js";
6
+ import { Text } from "../typography/Text.js";
7
+ import { UXButton } from "../UXButton/index.js";
8
+ const UXDrawer = (props)=>{
9
+ const { title, footer, backdrop, scrollBehavior = 'inside', children, titleAlign = 'left', classNames, tip, ...restProps } = props;
10
+ return /*#__PURE__*/ jsx(Drawer, {
11
+ backdrop: backdrop,
12
+ scrollBehavior: scrollBehavior,
13
+ classNames: {
14
+ wrapper: [
15
+ classNames?.wrapper
16
+ ],
17
+ base: [
18
+ 'py-6 gap-5 shadow-box',
19
+ 'max-md:rounded-none',
20
+ classNames?.base
21
+ ],
22
+ backdrop: [
23
+ 'backdrop-blur-[1px] bg-black/50 dark:bg-black/70',
24
+ classNames?.backdrop
25
+ ],
26
+ header: [
27
+ 'px-lg py-0 max-md:text-h3',
28
+ 'md:px-6 md:text-h2',
29
+ 'center' === titleAlign && 'justify-center',
30
+ classNames?.header
31
+ ],
32
+ body: [
33
+ 'px-lg md:px-6 py-0 no-scrollbar',
34
+ classNames?.body
35
+ ],
36
+ footer: [
37
+ 'gap-lg px-lg md:px-6 py-0 flex-col items-stretch',
38
+ classNames?.footer
39
+ ],
40
+ closeButton: [
41
+ 'top-5 end-4 text-foreground',
42
+ classNames?.closeButton
43
+ ]
44
+ },
45
+ closeButton: /*#__PURE__*/ jsx(UXButton, {
46
+ isIconOnly: true,
47
+ variant: "light",
48
+ children: /*#__PURE__*/ jsx(CloseIcon, {
49
+ size: 24
50
+ })
51
+ }),
52
+ ...restProps,
53
+ children: /*#__PURE__*/ jsxs(DrawerContent, {
54
+ children: [
55
+ title ? /*#__PURE__*/ jsx(DrawerHeader, {
56
+ className: "capitalize",
57
+ children: title
58
+ }) : null,
59
+ /*#__PURE__*/ jsx(DrawerBody, {
60
+ children: children
61
+ }),
62
+ footer ? /*#__PURE__*/ jsx(DrawerFooter, {
63
+ children: footer
64
+ }) : null,
65
+ tip ? /*#__PURE__*/ jsx(DrawerFooter, {
66
+ className: "-mt-md",
67
+ children: /*#__PURE__*/ jsxs(Flex, {
68
+ gap: 2,
69
+ children: [
70
+ /*#__PURE__*/ jsx(Center, {
71
+ className: "h-4",
72
+ children: /*#__PURE__*/ jsx(Circle, {
73
+ className: "bg-foreground-300 h-[5px] w-[5px]"
74
+ })
75
+ }),
76
+ /*#__PURE__*/ jsx(Text, {
77
+ body2: true,
78
+ color: "secondary",
79
+ children: tip
80
+ })
81
+ ]
82
+ })
83
+ }) : null
84
+ ]
85
+ })
86
+ });
87
+ };
88
+ UXDrawer.displayName = 'UX.Drawer';
89
+ export { UXDrawer };
@@ -177,7 +177,7 @@ const classes = {
177
177
  variant: 'flat',
178
178
  color: 'default',
179
179
  class: {
180
- base: 'data-[hover=true]:bg-background-200 data-[hover=true]:text-default-foreground'
180
+ base: 'data-[hover=true]:bg-background-200 data-[focus-visible=true]:bg-background-200 data-[focus-visible=true]:dark:bg-background-200 data-[hover=true]:text-default-foreground data-[selectable=true]:focus:!bg-background-200 data-[selectable=true]:focus:dark:!bg-background-200'
181
181
  }
182
182
  },
183
183
  {
@@ -1,17 +1,19 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import "react";
3
3
  import { forwardRef } from "@heroui/system";
4
+ import { cn } from "@heroui/theme";
4
5
  import { useI18n } from "../../hooks/useI18n.js";
5
6
  import { EmptyIcon } from "../../icons/index.js";
6
7
  import { VStack } from "../layout/index.js";
7
8
  import { Text } from "../typography/Text.js";
8
9
  const UXEmpty = forwardRef((props, ref)=>{
9
10
  const i18n = useI18n();
10
- const { text = i18n.table.emptyContent, iconProps, ...restProps } = props;
11
+ const { text = i18n.table.emptyContent, iconProps, className, ...restProps } = props;
11
12
  return /*#__PURE__*/ jsxs(VStack, {
12
13
  ref: ref,
13
14
  center: true,
14
15
  gap: 1,
16
+ className: cn('w-full h-full', className),
15
17
  ...restProps,
16
18
  children: [
17
19
  /*#__PURE__*/ jsx(EmptyIcon, {
@@ -43,7 +43,7 @@ export declare const UXInput: React.ForwardRefExoticComponent<Omit<Omit<{
43
43
  vocab?: string | undefined;
44
44
  autoCorrect?: string | undefined;
45
45
  autoSave?: string | undefined;
46
- color?: "default" | "secondary" | "primary" | "success" | "danger" | "warning" | "bullish" | "bearish" | undefined;
46
+ color?: "default" | "success" | "secondary" | "primary" | "danger" | "warning" | "bullish" | "bearish" | undefined;
47
47
  itemProp?: string | undefined;
48
48
  itemScope?: boolean | undefined;
49
49
  itemType?: string | undefined;
@@ -300,46 +300,46 @@ export declare const UXInput: React.ForwardRefExoticComponent<Omit<Omit<{
300
300
  name?: string | undefined;
301
301
  type?: string | undefined;
302
302
  key?: React.Key | null | undefined;
303
- labelPlacement?: "inside" | "outside" | "outside-left" | "outside-top" | undefined;
304
- label?: React.ReactNode;
305
- disableAnimation?: boolean | undefined;
303
+ isClearable?: boolean | undefined;
304
+ classNames?: import("@heroui/theme").SlotsToClasses<"description" | "errorMessage" | "label" | "base" | "input" | "clearButton" | "mainWrapper" | "inputWrapper" | "innerWrapper" | "helperWrapper"> | undefined;
306
305
  isDisabled?: boolean | undefined;
307
- pattern?: string | undefined;
308
- as?: import("@heroui/system-rsc").As<any> | undefined;
306
+ isReadOnly?: boolean | undefined;
307
+ isRequired?: boolean | undefined;
308
+ isInvalid?: boolean | undefined;
309
+ validationState?: import("@react-types/shared").ValidationState | undefined;
310
+ validationBehavior?: "aria" | "native" | undefined;
311
+ validate?: ((value: string) => import("@react-types/shared").ValidationError | true | null | undefined) | undefined;
312
+ description?: React.ReactNode;
313
+ errorMessage?: React.ReactNode | ((v: import("@react-types/shared").ValidationResult) => React.ReactNode);
309
314
  onFocusChange?: ((isFocused: boolean) => void) | undefined;
310
- formAction?: string | ((formData: FormData) => void | Promise<void>) | undefined;
311
- formEncType?: string | undefined;
312
- formMethod?: string | undefined;
313
- formNoValidate?: boolean | undefined;
314
- formTarget?: string | undefined;
315
+ placeholder?: string | undefined;
316
+ label?: React.ReactNode;
315
317
  excludeFromTabOrder?: boolean | undefined;
316
- startContent?: React.ReactNode;
317
- endContent?: React.ReactNode;
318
- onClear?: (() => void) | undefined;
319
318
  autoComplete?: string | undefined;
320
- alt?: string | undefined;
321
319
  maxLength?: number | undefined;
322
320
  minLength?: number | undefined;
321
+ pattern?: string | undefined;
322
+ labelPlacement?: "inside" | "outside" | "outside-left" | "outside-top" | undefined;
323
+ disableAnimation?: boolean | undefined;
324
+ as?: import("@heroui/system-rsc").As<any> | undefined;
323
325
  accept?: string | undefined;
326
+ alt?: string | undefined;
324
327
  capture?: boolean | "user" | "environment" | undefined;
325
328
  checked?: boolean | undefined;
326
- src?: string | undefined;
327
- classNames?: import("@heroui/theme").SlotsToClasses<"label" | "inputWrapper" | "base" | "input" | "errorMessage" | "helperWrapper" | "description" | "innerWrapper" | "mainWrapper" | "clearButton"> | undefined;
328
- isReadOnly?: boolean | undefined;
329
- validationState?: import("@react-types/shared").ValidationState | undefined;
330
- isInvalid?: boolean | undefined;
331
- errorMessage?: React.ReactNode | ((v: import("@react-types/shared").ValidationResult) => React.ReactNode);
332
- placeholder?: string | undefined;
329
+ formAction?: string | ((formData: FormData) => void | Promise<void>) | undefined;
330
+ formEncType?: string | undefined;
331
+ formMethod?: string | undefined;
332
+ formNoValidate?: boolean | undefined;
333
+ formTarget?: string | undefined;
333
334
  readOnly?: boolean | undefined;
334
335
  required?: boolean | undefined;
335
- onValueChange?: ((value: string) => void) | undefined;
336
- isRequired?: boolean | undefined;
337
- validationBehavior?: "aria" | "native" | undefined;
338
- validate?: ((value: string) => import("@react-types/shared").ValidationError | true | null | undefined) | undefined;
339
- description?: React.ReactNode;
340
- isClearable?: boolean | undefined;
336
+ src?: string | undefined;
341
337
  baseRef?: React.Ref<HTMLDivElement> | undefined;
342
338
  wrapperRef?: React.Ref<HTMLDivElement> | undefined;
343
339
  innerWrapperRef?: React.Ref<HTMLDivElement> | undefined;
340
+ startContent?: React.ReactNode;
341
+ endContent?: React.ReactNode;
342
+ onClear?: (() => void) | undefined;
343
+ onValueChange?: ((value: string) => void) | undefined;
344
344
  textAlign?: "center" | "left" | "right" | undefined;
345
345
  }, "ref"> & React.RefAttributes<React.ReactElement<unknown, string | React.JSXElementConstructor<any>>>, "ref"> & React.RefAttributes<HTMLInputElement>>;
@@ -40,7 +40,7 @@ declare const ExtendedInput: import("react").ForwardRefExoticComponent<Omit<{
40
40
  vocab?: string | undefined;
41
41
  autoCorrect?: string | undefined;
42
42
  autoSave?: string | undefined;
43
- color?: "default" | "secondary" | "primary" | "success" | "danger" | "warning" | "bullish" | "bearish" | undefined;
43
+ color?: "default" | "success" | "secondary" | "primary" | "danger" | "warning" | "bullish" | "bearish" | undefined;
44
44
  itemProp?: string | undefined;
45
45
  itemScope?: boolean | undefined;
46
46
  itemType?: string | undefined;
@@ -297,47 +297,47 @@ declare const ExtendedInput: import("react").ForwardRefExoticComponent<Omit<{
297
297
  name?: string | undefined;
298
298
  type?: string | undefined;
299
299
  key?: import("react").Key | null | undefined;
300
- labelPlacement?: "inside" | "outside" | "outside-left" | "outside-top" | undefined;
301
- label?: import("react").ReactNode;
302
- disableAnimation?: boolean | undefined;
300
+ isClearable?: boolean | undefined;
301
+ classNames?: import("@heroui/theme").SlotsToClasses<"description" | "errorMessage" | "label" | "base" | "input" | "clearButton" | "mainWrapper" | "inputWrapper" | "innerWrapper" | "helperWrapper"> | undefined;
303
302
  isDisabled?: boolean | undefined;
304
- pattern?: string | undefined;
305
- as?: import("@heroui/system-rsc").As<any> | undefined;
303
+ isReadOnly?: boolean | undefined;
304
+ isRequired?: boolean | undefined;
305
+ isInvalid?: boolean | undefined;
306
+ validationState?: import("@react-types/shared").ValidationState | undefined;
307
+ validationBehavior?: "aria" | "native" | undefined;
308
+ validate?: ((value: string) => import("@react-types/shared").ValidationError | true | null | undefined) | undefined;
309
+ description?: import("react").ReactNode;
310
+ errorMessage?: import("react").ReactNode | ((v: import("@react-types/shared").ValidationResult) => import("react").ReactNode);
306
311
  onFocusChange?: ((isFocused: boolean) => void) | undefined;
307
- formAction?: string | ((formData: FormData) => void | Promise<void>) | undefined;
308
- formEncType?: string | undefined;
309
- formMethod?: string | undefined;
310
- formNoValidate?: boolean | undefined;
311
- formTarget?: string | undefined;
312
+ placeholder?: string | undefined;
313
+ label?: import("react").ReactNode;
312
314
  excludeFromTabOrder?: boolean | undefined;
313
- startContent?: import("react").ReactNode;
314
- endContent?: import("react").ReactNode;
315
- onClear?: (() => void) | undefined;
316
315
  autoComplete?: string | undefined;
317
- alt?: string | undefined;
318
316
  maxLength?: number | undefined;
319
317
  minLength?: number | undefined;
318
+ pattern?: string | undefined;
319
+ labelPlacement?: "inside" | "outside" | "outside-left" | "outside-top" | undefined;
320
+ disableAnimation?: boolean | undefined;
321
+ as?: import("@heroui/system-rsc").As<any> | undefined;
320
322
  accept?: string | undefined;
323
+ alt?: string | undefined;
321
324
  capture?: boolean | "user" | "environment" | undefined;
322
325
  checked?: boolean | undefined;
323
- src?: string | undefined;
324
- classNames?: import("@heroui/theme").SlotsToClasses<"label" | "inputWrapper" | "base" | "input" | "errorMessage" | "helperWrapper" | "description" | "innerWrapper" | "mainWrapper" | "clearButton"> | undefined;
325
- isReadOnly?: boolean | undefined;
326
- validationState?: import("@react-types/shared").ValidationState | undefined;
327
- isInvalid?: boolean | undefined;
328
- errorMessage?: import("react").ReactNode | ((v: import("@react-types/shared").ValidationResult) => import("react").ReactNode);
329
- placeholder?: string | undefined;
326
+ formAction?: string | ((formData: FormData) => void | Promise<void>) | undefined;
327
+ formEncType?: string | undefined;
328
+ formMethod?: string | undefined;
329
+ formNoValidate?: boolean | undefined;
330
+ formTarget?: string | undefined;
330
331
  readOnly?: boolean | undefined;
331
332
  required?: boolean | undefined;
332
- onValueChange?: ((value: string) => void) | undefined;
333
- isRequired?: boolean | undefined;
334
- validationBehavior?: "aria" | "native" | undefined;
335
- validate?: ((value: string) => import("@react-types/shared").ValidationError | true | null | undefined) | undefined;
336
- description?: import("react").ReactNode;
337
- isClearable?: boolean | undefined;
333
+ src?: string | undefined;
338
334
  baseRef?: import("react").Ref<HTMLDivElement> | undefined;
339
335
  wrapperRef?: import("react").Ref<HTMLDivElement> | undefined;
340
336
  innerWrapperRef?: import("react").Ref<HTMLDivElement> | undefined;
337
+ startContent?: import("react").ReactNode;
338
+ endContent?: import("react").ReactNode;
339
+ onClear?: (() => void) | undefined;
340
+ onValueChange?: ((value: string) => void) | undefined;
341
341
  textAlign?: "center" | "left" | "right" | undefined;
342
342
  }, "ref"> & import("react").RefAttributes<import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>>>>;
343
343
  export default ExtendedInput;
@@ -1,8 +1,10 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import { forwardRef } from "react";
3
3
  import { Modal, ModalBody, ModalContent, ModalFooter, ModalHeader } from "@heroui/modal";
4
- import { Center, Circle, Flex, Text, UXButton } from "../index.js";
5
4
  import { CloseIcon } from "../../icons/index.js";
5
+ import { Center, Circle, Flex } from "../layout/index.js";
6
+ import { Text } from "../typography/Text.js";
7
+ import { UXButton } from "../UXButton/index.js";
6
8
  const UXModal = /*#__PURE__*/ forwardRef((props, ref)=>{
7
9
  const { title, footer, backdrop, scrollBehavior = 'inside', children, titleAlign = 'left', classNames, tip, ...restProps } = props;
8
10
  return /*#__PURE__*/ jsx(Modal, {
@@ -18,7 +18,7 @@ const UXSelect = /*#__PURE__*/ forwardRef((props, ref)=>{
18
18
  selectorIcon
19
19
  ],
20
20
  trigger: [
21
- 'h-[30px] min-h-[30px] px-md bg-background-200',
21
+ 'h-[30px] min-h-[30px] px-md bg-background-200 data-[hover=true]:bg-background-200 data-[hover=true]:opacity-hover',
22
22
  trigger
23
23
  ],
24
24
  value: [
@@ -34,7 +34,7 @@ const UXSelect = /*#__PURE__*/ forwardRef((props, ref)=>{
34
34
  list: 'gap-0 [&_[data-slot="heading"]]:text-small [&_[data-slot="heading"]]:font-medium'
35
35
  },
36
36
  itemClasses: {
37
- base: '!outline-none min-h-8 px-md rounded-small text-foreground-300 !outline-none data-[hover=true]:bg-background-200 data-[selected=true]:text-foreground gap-1',
37
+ base: '!outline-none min-h-8 px-md rounded-small text-foreground-300 !outline-none data-[hover=true]:bg-background-200 data-[focus-visible=true]:bg-background-200 data-[focus-visible=true]:dark:bg-background-200 data-[hover=true]:text-default-foreground data-[selectable=true]:focus:!bg-background-200 data-[selectable=true]:focus:dark:!bg-background-200 gap-1',
38
38
  title: 'text-tiny font-medium antialiased',
39
39
  selectedIcon: '[&>svg>polyline]:stroke-[2.5]'
40
40
  }
@@ -42,7 +42,7 @@ export declare const UXSwitch: React.ForwardRefExoticComponent<Omit<Omit<{
42
42
  vocab?: string | undefined;
43
43
  autoCorrect?: string | undefined;
44
44
  autoSave?: string | undefined;
45
- color?: "default" | "secondary" | "primary" | "success" | "danger" | "warning" | "bullish" | "bearish" | "contrast" | undefined;
45
+ color?: "default" | "success" | "secondary" | "primary" | "danger" | "warning" | "bullish" | "bearish" | "contrast" | undefined;
46
46
  itemProp?: string | undefined;
47
47
  itemScope?: boolean | undefined;
48
48
  itemType?: string | undefined;
@@ -297,34 +297,34 @@ export declare const UXSwitch: React.ForwardRefExoticComponent<Omit<Omit<{
297
297
  name?: string | undefined;
298
298
  type?: React.HTMLInputTypeAttribute | undefined;
299
299
  key?: React.Key | null | undefined;
300
- disableAnimation?: boolean | undefined;
300
+ classNames?: import("@heroui/theme").SlotsToClasses<"label" | "base" | "startContent" | "endContent" | "wrapper" | "hiddenInput" | "thumb" | "thumbIcon"> | undefined;
301
301
  isDisabled?: boolean | undefined;
302
- isSelected?: boolean | undefined;
303
- pattern?: string | undefined;
304
- as?: import("@heroui/system-rsc").As<any> | undefined;
302
+ isReadOnly?: boolean | undefined;
305
303
  onFocusChange?: ((isFocused: boolean) => void) | undefined;
306
- formAction?: string | ((formData: FormData) => void | Promise<void>) | undefined;
307
- formEncType?: string | undefined;
308
- formMethod?: string | undefined;
309
- formNoValidate?: boolean | undefined;
310
- formTarget?: string | undefined;
304
+ placeholder?: string | undefined;
311
305
  excludeFromTabOrder?: boolean | undefined;
312
- startContent?: React.ReactNode;
313
- endContent?: React.ReactNode;
314
306
  autoComplete?: React.HTMLInputAutoCompleteAttribute | undefined;
315
- alt?: string | undefined;
316
307
  maxLength?: number | undefined;
317
308
  minLength?: number | undefined;
309
+ pattern?: string | undefined;
310
+ disableAnimation?: boolean | undefined;
311
+ as?: import("@heroui/system-rsc").As<any> | undefined;
318
312
  accept?: string | undefined;
313
+ alt?: string | undefined;
319
314
  capture?: boolean | "user" | "environment" | undefined;
320
315
  checked?: boolean | undefined;
321
- src?: string | undefined;
322
- classNames?: import("@heroui/theme").SlotsToClasses<"label" | "base" | "startContent" | "endContent" | "wrapper" | "hiddenInput" | "thumb" | "thumbIcon"> | undefined;
323
- isReadOnly?: boolean | undefined;
324
- placeholder?: string | undefined;
316
+ formAction?: string | ((formData: FormData) => void | Promise<void>) | undefined;
317
+ formEncType?: string | undefined;
318
+ formMethod?: string | undefined;
319
+ formNoValidate?: boolean | undefined;
320
+ formTarget?: string | undefined;
325
321
  readOnly?: boolean | undefined;
326
322
  required?: boolean | undefined;
323
+ src?: string | undefined;
324
+ startContent?: React.ReactNode;
325
+ endContent?: React.ReactNode;
327
326
  onValueChange?: ((isSelected: boolean) => void) | undefined;
327
+ isSelected?: boolean | undefined;
328
328
  defaultSelected?: boolean | undefined;
329
329
  thumbIcon?: React.ReactNode | ((props: import("@heroui/switch").SwitchThumbIconProps) => React.ReactNode);
330
330
  }, "ref"> & React.RefAttributes<React.ReactElement<unknown, string | React.JSXElementConstructor<any>>>, "ref"> & React.RefAttributes<HTMLInputElement>>;
@@ -39,7 +39,7 @@ declare const ExtendedSwitch: import("react").ForwardRefExoticComponent<Omit<{
39
39
  vocab?: string | undefined;
40
40
  autoCorrect?: string | undefined;
41
41
  autoSave?: string | undefined;
42
- color?: "default" | "secondary" | "primary" | "success" | "danger" | "warning" | "bullish" | "bearish" | "contrast" | undefined;
42
+ color?: "default" | "success" | "secondary" | "primary" | "danger" | "warning" | "bullish" | "bearish" | "contrast" | undefined;
43
43
  itemProp?: string | undefined;
44
44
  itemScope?: boolean | undefined;
45
45
  itemType?: string | undefined;
@@ -294,34 +294,34 @@ declare const ExtendedSwitch: import("react").ForwardRefExoticComponent<Omit<{
294
294
  name?: string | undefined;
295
295
  type?: import("react").HTMLInputTypeAttribute | undefined;
296
296
  key?: import("react").Key | null | undefined;
297
- disableAnimation?: boolean | undefined;
297
+ classNames?: import("@heroui/theme").SlotsToClasses<"label" | "base" | "startContent" | "endContent" | "wrapper" | "hiddenInput" | "thumb" | "thumbIcon"> | undefined;
298
298
  isDisabled?: boolean | undefined;
299
- isSelected?: boolean | undefined;
300
- pattern?: string | undefined;
301
- as?: import("@heroui/system-rsc").As<any> | undefined;
299
+ isReadOnly?: boolean | undefined;
302
300
  onFocusChange?: ((isFocused: boolean) => void) | undefined;
303
- formAction?: string | ((formData: FormData) => void | Promise<void>) | undefined;
304
- formEncType?: string | undefined;
305
- formMethod?: string | undefined;
306
- formNoValidate?: boolean | undefined;
307
- formTarget?: string | undefined;
301
+ placeholder?: string | undefined;
308
302
  excludeFromTabOrder?: boolean | undefined;
309
- startContent?: import("react").ReactNode;
310
- endContent?: import("react").ReactNode;
311
303
  autoComplete?: import("react").HTMLInputAutoCompleteAttribute | undefined;
312
- alt?: string | undefined;
313
304
  maxLength?: number | undefined;
314
305
  minLength?: number | undefined;
306
+ pattern?: string | undefined;
307
+ disableAnimation?: boolean | undefined;
308
+ as?: import("@heroui/system-rsc").As<any> | undefined;
315
309
  accept?: string | undefined;
310
+ alt?: string | undefined;
316
311
  capture?: boolean | "user" | "environment" | undefined;
317
312
  checked?: boolean | undefined;
318
- src?: string | undefined;
319
- classNames?: import("@heroui/theme").SlotsToClasses<"label" | "base" | "startContent" | "endContent" | "wrapper" | "hiddenInput" | "thumb" | "thumbIcon"> | undefined;
320
- isReadOnly?: boolean | undefined;
321
- placeholder?: string | undefined;
313
+ formAction?: string | ((formData: FormData) => void | Promise<void>) | undefined;
314
+ formEncType?: string | undefined;
315
+ formMethod?: string | undefined;
316
+ formNoValidate?: boolean | undefined;
317
+ formTarget?: string | undefined;
322
318
  readOnly?: boolean | undefined;
323
319
  required?: boolean | undefined;
320
+ src?: string | undefined;
321
+ startContent?: import("react").ReactNode;
322
+ endContent?: import("react").ReactNode;
324
323
  onValueChange?: ((isSelected: boolean) => void) | undefined;
324
+ isSelected?: boolean | undefined;
325
325
  defaultSelected?: boolean | undefined;
326
326
  thumbIcon?: import("react").ReactNode | ((props: import("@heroui/switch").SwitchThumbIconProps) => import("react").ReactNode);
327
327
  }, "ref"> & import("react").RefAttributes<import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>>>>;
@@ -43,7 +43,7 @@ export declare const UXTable: import("@heroui/system-rsc").InternalForwardRefRen
43
43
  vocab?: string | undefined;
44
44
  autoCorrect?: string | undefined;
45
45
  autoSave?: string | undefined;
46
- color?: "default" | "secondary" | "primary" | "success" | "danger" | "warning" | undefined;
46
+ color?: "default" | "success" | "secondary" | "primary" | "danger" | "warning" | undefined;
47
47
  itemProp?: string | undefined;
48
48
  itemScope?: boolean | undefined;
49
49
  itemType?: string | undefined;
@@ -291,32 +291,32 @@ export declare const UXTable: import("@heroui/system-rsc").InternalForwardRefRen
291
291
  layout?: "auto" | "fixed" | undefined;
292
292
  border?: number | undefined;
293
293
  key?: React.Key | null | undefined;
294
+ classNames?: import("@heroui/theme").SlotsToClasses<"table" | "base" | "tbody" | "td" | "tfoot" | "th" | "thead" | "tr" | "wrapper" | "sortIcon" | "emptyWrapper" | "loadingWrapper"> | undefined;
294
295
  disableAnimation?: boolean | undefined;
295
- shadow?: "sm" | "md" | "lg" | "none" | undefined;
296
296
  summary?: string | undefined;
297
297
  as?: import("@heroui/system-rsc").As<any> | undefined;
298
- bgcolor?: string | undefined;
299
- cellPadding?: string | number | undefined;
300
- cellSpacing?: string | number | undefined;
301
- frame?: boolean | undefined;
302
- rules?: "none" | "all" | "rows" | "groups" | "columns" | undefined;
303
- classNames?: import("@heroui/theme").SlotsToClasses<"table" | "base" | "tbody" | "td" | "tfoot" | "th" | "thead" | "tr" | "wrapper" | "sortIcon" | "emptyWrapper" | "loadingWrapper"> | undefined;
304
- topContent?: React.ReactNode;
305
- bottomContent?: React.ReactNode;
298
+ baseRef?: import("@heroui/react-utils").ReactRef<HTMLElement | null> | undefined;
299
+ disallowEmptySelection?: boolean | undefined;
300
+ onSelectionChange?: ((keys: import("@react-types/shared").Selection) => void) | undefined;
301
+ disabledKeys?: Iterable<import("@react-types/shared").Key> | undefined;
306
302
  scrollRef?: import("@react-types/shared").RefObject<HTMLElement | null> | undefined;
307
303
  isVirtualized?: boolean | undefined;
304
+ shadow?: "sm" | "md" | "lg" | "none" | undefined;
305
+ topContent?: React.ReactNode;
306
+ bottomContent?: React.ReactNode;
307
+ keyboardDelegate?: import("@react-types/shared").KeyboardDelegate | undefined;
308
+ selectionBehavior?: "replace" | "toggle" | undefined;
309
+ shouldSelectOnPressUp?: boolean | undefined;
308
310
  escapeKeyBehavior?: "none" | "clearSelection" | undefined;
309
- disabledKeys?: Iterable<import("@react-types/shared").Key> | undefined;
310
311
  selectionMode?: import("@react-types/shared").SelectionMode | undefined;
311
- disallowEmptySelection?: boolean | undefined;
312
312
  selectedKeys?: "all" | Iterable<import("@react-types/shared").Key> | undefined;
313
313
  defaultSelectedKeys?: "all" | Iterable<import("@react-types/shared").Key> | undefined;
314
- onSelectionChange?: ((keys: import("@react-types/shared").Selection) => void) | undefined;
315
- baseRef?: import("@heroui/react-utils").ReactRef<HTMLElement | null> | undefined;
314
+ bgcolor?: string | undefined;
315
+ cellPadding?: string | number | undefined;
316
+ cellSpacing?: string | number | undefined;
317
+ frame?: boolean | undefined;
318
+ rules?: "none" | "all" | "rows" | "groups" | "columns" | undefined;
316
319
  isCompact?: boolean | undefined;
317
- keyboardDelegate?: import("@react-types/shared").KeyboardDelegate | undefined;
318
- selectionBehavior?: "replace" | "toggle" | undefined;
319
- shouldSelectOnPressUp?: boolean | undefined;
320
320
  hideHeader?: boolean | undefined;
321
321
  isStriped?: boolean | undefined;
322
322
  isHeaderSticky?: boolean | undefined;