@particle-network/ui-react 0.4.0-beta.13 → 0.4.0-beta.15
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.
- package/dist/components/UXAutocomplete/index.d.ts +5 -0
- package/dist/components/UXAutocomplete/index.js +72 -0
- package/dist/components/UXEmpty/index.d.ts +1 -1
- package/dist/components/UXHint/index.d.ts +1 -1
- package/dist/components/UXInput/index.d.ts +28 -28
- package/dist/components/UXInput/input.extend.d.ts +28 -28
- package/dist/components/UXSwitch/index.d.ts +17 -17
- package/dist/components/UXSwitch/switch.extend.d.ts +17 -17
- package/dist/components/UXTable/index.d.ts +17 -17
- package/dist/components/UXTable/table.extend.d.ts +17 -17
- package/dist/components/UXThemeSwitch/index.d.ts +0 -1
- package/dist/components/UXThemeSwitch/index.js +0 -1
- package/dist/components/UXThemeSwitch/theme-item.d.ts +1 -1
- package/dist/components/UXThemeSwitch/theme-switch.js +1 -1
- package/dist/components/UXThemeSwitch/use-color-scheme.d.ts +1 -1
- package/dist/components/UXThemeSwitch/use-theme-store.d.ts +1 -1
- package/dist/components/UXThemeSwitch/use-theme-store.js +1 -1
- package/dist/components/UXThemeSwitch/use-theme.d.ts +1 -1
- package/dist/components/UXThemeSwitch/use-theme.js +1 -1
- package/dist/components/UXToast/index.d.ts +6 -4
- package/dist/components/UXToast/index.js +19 -15
- package/dist/components/UXTooltip/tooltip.extend.d.ts +19 -19
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +1 -0
- package/package.json +3 -3
- package/tailwind-preset.js +108 -36
- package/dist/components/UXThemeSwitch/theme-data.d.ts +0 -12
- package/dist/components/UXThemeSwitch/theme-data.js +0 -340
|
@@ -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 };
|
|
@@ -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" | "
|
|
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
|
-
|
|
304
|
-
|
|
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
|
-
|
|
308
|
-
|
|
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
|
-
|
|
311
|
-
|
|
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
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
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
|
-
|
|
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" | "
|
|
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
|
-
|
|
301
|
-
|
|
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
|
-
|
|
305
|
-
|
|
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
|
-
|
|
308
|
-
|
|
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
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
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
|
-
|
|
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;
|
|
@@ -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" | "
|
|
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
|
-
|
|
300
|
+
classNames?: import("@heroui/theme").SlotsToClasses<"label" | "base" | "startContent" | "endContent" | "wrapper" | "hiddenInput" | "thumb" | "thumbIcon"> | undefined;
|
|
301
301
|
isDisabled?: boolean | undefined;
|
|
302
|
-
|
|
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
|
-
|
|
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
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
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" | "
|
|
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
|
-
|
|
297
|
+
classNames?: import("@heroui/theme").SlotsToClasses<"label" | "base" | "startContent" | "endContent" | "wrapper" | "hiddenInput" | "thumb" | "thumbIcon"> | undefined;
|
|
298
298
|
isDisabled?: boolean | undefined;
|
|
299
|
-
|
|
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
|
-
|
|
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
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
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" | "
|
|
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
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
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
|
-
|
|
315
|
-
|
|
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;
|
|
@@ -40,7 +40,7 @@ declare const ExtendedTable: import("react").ForwardRefExoticComponent<Omit<{
|
|
|
40
40
|
vocab?: string | undefined;
|
|
41
41
|
autoCorrect?: string | undefined;
|
|
42
42
|
autoSave?: string | undefined;
|
|
43
|
-
color?: "default" | "
|
|
43
|
+
color?: "default" | "success" | "secondary" | "primary" | "danger" | "warning" | undefined;
|
|
44
44
|
itemProp?: string | undefined;
|
|
45
45
|
itemScope?: boolean | undefined;
|
|
46
46
|
itemType?: string | undefined;
|
|
@@ -288,32 +288,32 @@ declare const ExtendedTable: import("react").ForwardRefExoticComponent<Omit<{
|
|
|
288
288
|
layout?: "auto" | "fixed" | undefined;
|
|
289
289
|
border?: number | undefined;
|
|
290
290
|
key?: import("react").Key | null | undefined;
|
|
291
|
+
classNames?: import("@heroui/theme").SlotsToClasses<"table" | "base" | "tbody" | "td" | "tfoot" | "th" | "thead" | "tr" | "wrapper" | "sortIcon" | "emptyWrapper" | "loadingWrapper"> | undefined;
|
|
291
292
|
disableAnimation?: boolean | undefined;
|
|
292
|
-
shadow?: "sm" | "md" | "lg" | "none" | undefined;
|
|
293
293
|
summary?: string | undefined;
|
|
294
294
|
as?: import("@heroui/system-rsc").As<any> | undefined;
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
rules?: "none" | "all" | "rows" | "groups" | "columns" | undefined;
|
|
300
|
-
classNames?: import("@heroui/theme").SlotsToClasses<"table" | "base" | "tbody" | "td" | "tfoot" | "th" | "thead" | "tr" | "wrapper" | "sortIcon" | "emptyWrapper" | "loadingWrapper"> | undefined;
|
|
301
|
-
topContent?: import("react").ReactNode;
|
|
302
|
-
bottomContent?: import("react").ReactNode;
|
|
295
|
+
baseRef?: import("@heroui/react-utils").ReactRef<HTMLElement | null> | undefined;
|
|
296
|
+
disallowEmptySelection?: boolean | undefined;
|
|
297
|
+
onSelectionChange?: ((keys: import("@react-types/shared").Selection) => void) | undefined;
|
|
298
|
+
disabledKeys?: Iterable<import("@react-types/shared").Key> | undefined;
|
|
303
299
|
scrollRef?: import("@react-types/shared").RefObject<HTMLElement | null> | undefined;
|
|
304
300
|
isVirtualized?: boolean | undefined;
|
|
301
|
+
shadow?: "sm" | "md" | "lg" | "none" | undefined;
|
|
302
|
+
topContent?: import("react").ReactNode;
|
|
303
|
+
bottomContent?: import("react").ReactNode;
|
|
304
|
+
keyboardDelegate?: import("@react-types/shared").KeyboardDelegate | undefined;
|
|
305
|
+
selectionBehavior?: "replace" | "toggle" | undefined;
|
|
306
|
+
shouldSelectOnPressUp?: boolean | undefined;
|
|
305
307
|
escapeKeyBehavior?: "none" | "clearSelection" | undefined;
|
|
306
|
-
disabledKeys?: Iterable<import("@react-types/shared").Key> | undefined;
|
|
307
308
|
selectionMode?: import("@react-types/shared").SelectionMode | undefined;
|
|
308
|
-
disallowEmptySelection?: boolean | undefined;
|
|
309
309
|
selectedKeys?: "all" | Iterable<import("@react-types/shared").Key> | undefined;
|
|
310
310
|
defaultSelectedKeys?: "all" | Iterable<import("@react-types/shared").Key> | undefined;
|
|
311
|
-
|
|
312
|
-
|
|
311
|
+
bgcolor?: string | undefined;
|
|
312
|
+
cellPadding?: string | number | undefined;
|
|
313
|
+
cellSpacing?: string | number | undefined;
|
|
314
|
+
frame?: boolean | undefined;
|
|
315
|
+
rules?: "none" | "all" | "rows" | "groups" | "columns" | undefined;
|
|
313
316
|
isCompact?: boolean | undefined;
|
|
314
|
-
keyboardDelegate?: import("@react-types/shared").KeyboardDelegate | undefined;
|
|
315
|
-
selectionBehavior?: "replace" | "toggle" | undefined;
|
|
316
|
-
shouldSelectOnPressUp?: boolean | undefined;
|
|
317
317
|
hideHeader?: boolean | undefined;
|
|
318
318
|
isStriped?: boolean | undefined;
|
|
319
319
|
isHeaderSticky?: boolean | undefined;
|
|
@@ -3,6 +3,7 @@ import "react";
|
|
|
3
3
|
import { Drawer, DrawerBody, DrawerContent, DrawerFooter, DrawerHeader } from "@heroui/drawer";
|
|
4
4
|
import { useDisclosure } from "@heroui/use-disclosure";
|
|
5
5
|
import { ChartColorSwitchIcon } from "@particle-network/icons/web";
|
|
6
|
+
import { themeData } from "@particle-network/ui-shared";
|
|
6
7
|
import { useI18n } from "../../hooks/index.js";
|
|
7
8
|
import { Flex, HStack, VStack } from "../layout/index.js";
|
|
8
9
|
import { Text } from "../typography/Text.js";
|
|
@@ -10,7 +11,6 @@ import { UXButton } from "../UXButton/index.js";
|
|
|
10
11
|
import { UXDivider } from "../UXDivider/index.js";
|
|
11
12
|
import { UXInput } from "../UXInput/index.js";
|
|
12
13
|
import { UXSpinner } from "../UXSpinner/index.js";
|
|
13
|
-
import { themeData } from "./theme-data.js";
|
|
14
14
|
import { ThemeItem } from "./theme-item.js";
|
|
15
15
|
import { useTheme } from "./use-theme.js";
|
|
16
16
|
const UXThemeSwitchDrawer = ({ isOpen, onClose, onOpenChange, ...props })=>{
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { themeData } from "@particle-network/ui-shared";
|
|
1
2
|
import { create } from "zustand";
|
|
2
3
|
import { createJSONStorage, persist } from "zustand/middleware";
|
|
3
|
-
import { themeData } from "./theme-data.js";
|
|
4
4
|
const useThemeStore = create()(persist((set)=>({
|
|
5
5
|
selectedTheme: themeData["0"],
|
|
6
6
|
savedTheme: themeData["0"],
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useEffect } from "react";
|
|
2
|
+
import { themeKeys } from "@particle-network/ui-shared";
|
|
2
3
|
import { useDebounceFn } from "ahooks";
|
|
3
|
-
import { themeKeys } from "./theme-data.js";
|
|
4
4
|
import { useThemeStore } from "./use-theme-store.js";
|
|
5
5
|
const DEFAULT_FONT_FAMILY = 'ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji';
|
|
6
6
|
const applyTheme = (theme)=>{
|
|
@@ -1,13 +1,15 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
1
2
|
import type { ToastProps } from '@heroui/toast';
|
|
2
|
-
export type UXToastType = 'success' | 'error' | 'loading';
|
|
3
|
+
export type UXToastType = 'success' | 'error' | 'loading' | 'info';
|
|
3
4
|
export type UXToastProps = Partial<ToastProps> & {
|
|
4
5
|
type: UXToastType;
|
|
5
6
|
};
|
|
6
7
|
export declare const UXToastProvider: () => import("react/jsx-runtime").JSX.Element;
|
|
7
8
|
export declare const toast: {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
info: (message: ReactNode, props?: Partial<ToastProps>) => string | null;
|
|
10
|
+
success: (message: ReactNode, props?: Partial<ToastProps>) => string | null;
|
|
11
|
+
error: (message: ReactNode, props?: Partial<ToastProps>) => string | null;
|
|
12
|
+
loading: (message: ReactNode, props?: Partial<ToastProps>) => string | null;
|
|
11
13
|
show: (props?: Partial<ToastProps> & {
|
|
12
14
|
type: UXToastType;
|
|
13
15
|
}) => string | null;
|