@sustaina/shared-ui 1.51.0 → 1.52.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +23 -5
- package/dist/index.d.ts +23 -5
- package/dist/index.js +493 -231
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +497 -235
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1290,6 +1290,8 @@ type RichTextProps<T = DefaultMentionItem$1> = {
|
|
|
1290
1290
|
onImageDialogUploadError?: (error: unknown) => void;
|
|
1291
1291
|
acceptImageMimeTypes?: string;
|
|
1292
1292
|
allowImageUrlInsert?: boolean;
|
|
1293
|
+
/** Maximum number of characters allowed in the editor */
|
|
1294
|
+
maxLength?: number;
|
|
1293
1295
|
/** Array of mention items that will be suggested */
|
|
1294
1296
|
mentions?: T[];
|
|
1295
1297
|
/** Configuration for mapping mention item fields. If not provided, assumes default structure {id, name, fieldName} */
|
|
@@ -1300,7 +1302,7 @@ type RichTextProps<T = DefaultMentionItem$1> = {
|
|
|
1300
1302
|
plainTextMentions?: boolean;
|
|
1301
1303
|
} & Omit<React.HTMLAttributes<HTMLDivElement>, "onChange">;
|
|
1302
1304
|
|
|
1303
|
-
declare function RichTextInner<T = DefaultMentionItem$1>({ value, defaultValue, onChange, onHtmlChange, onTextChange, placeholder, readOnly, disabled, editorClassName, toolbarClassName, autoFocus, onImageUpload, onImageUploadError, onImageDialogUpload, onImageDialogUploadError, acceptImageMimeTypes, allowImageUrlInsert, mentions, mentionConfig, mentionTrigger, plainTextMentions, className, id, ...rest }: RichTextProps<T>, ref: React.Ref<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
1305
|
+
declare function RichTextInner<T = DefaultMentionItem$1>({ value, defaultValue, onChange, onHtmlChange, onTextChange, placeholder, readOnly, disabled, editorClassName, toolbarClassName, autoFocus, onImageUpload, onImageUploadError, onImageDialogUpload, onImageDialogUploadError, acceptImageMimeTypes, allowImageUrlInsert, maxLength, mentions, mentionConfig, mentionTrigger, plainTextMentions, className, id, ...rest }: RichTextProps<T>, ref: React.Ref<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
1304
1306
|
declare const RichText: <T = DefaultMentionItem$1>(props: RichTextProps<T> & {
|
|
1305
1307
|
ref?: React.Ref<HTMLDivElement>;
|
|
1306
1308
|
}) => ReturnType<typeof RichTextInner>;
|
|
@@ -1593,15 +1595,25 @@ declare function SidebarLayout({ sidebar, children, layoutProps, sidebarProps, i
|
|
|
1593
1595
|
|
|
1594
1596
|
interface TimePickerProps {
|
|
1595
1597
|
id?: string;
|
|
1596
|
-
value?: string;
|
|
1597
|
-
/** Callback with
|
|
1598
|
-
onChange?: (
|
|
1598
|
+
value?: Date | string | null;
|
|
1599
|
+
/** Callback with Date object */
|
|
1600
|
+
onChange?: (date?: Date) => void;
|
|
1601
|
+
/** Callback with string value (HH:mm format by default) */
|
|
1602
|
+
onValueChange?: (value?: string) => void;
|
|
1599
1603
|
disabled?: boolean;
|
|
1600
1604
|
className?: string;
|
|
1605
|
+
buttonClassName?: string;
|
|
1606
|
+
wrapperClassName?: string;
|
|
1601
1607
|
placeholder?: string;
|
|
1602
1608
|
use24Hour?: boolean;
|
|
1603
1609
|
iconPosition?: "start" | "end" | "none";
|
|
1604
1610
|
icon?: React$1.ReactNode;
|
|
1611
|
+
allowClear?: boolean;
|
|
1612
|
+
clearAriaLabel?: string;
|
|
1613
|
+
displayFormatter?: (date: Date, use24Hour: boolean) => string;
|
|
1614
|
+
valueFormatter?: (date: Date) => string;
|
|
1615
|
+
valueParser?: (value: string) => Date | undefined;
|
|
1616
|
+
invalid?: boolean;
|
|
1605
1617
|
}
|
|
1606
1618
|
declare const TimePicker: React$1.ForwardRefExoticComponent<TimePickerProps & React$1.RefAttributes<HTMLInputElement>>;
|
|
1607
1619
|
|
|
@@ -1805,6 +1817,10 @@ type ComboboxProps<TData extends OptionData> = React$1.AriaAttributes & Omit<Vir
|
|
|
1805
1817
|
onOpenChange?: (isOpen: boolean) => void;
|
|
1806
1818
|
showValueWhenNoMatch?: boolean;
|
|
1807
1819
|
virtual?: boolean;
|
|
1820
|
+
isLoading?: boolean;
|
|
1821
|
+
loadingContent?: React$1.ReactNode;
|
|
1822
|
+
popoverProps?: Omit<React$1.ComponentProps<typeof Popover>, "open" | "onOpenChange">;
|
|
1823
|
+
popoverContentProps?: Omit<React$1.ComponentProps<typeof PopoverContent>, "children">;
|
|
1808
1824
|
};
|
|
1809
1825
|
declare const Combobox: <TData extends OptionData>(props: ComboboxProps<TData> & React$1.RefAttributes<HTMLButtonElement>) => React$1.ReactElement | null;
|
|
1810
1826
|
|
|
@@ -1862,6 +1878,8 @@ type InputMentionProps<T = DefaultMentionItem> = {
|
|
|
1862
1878
|
disabled?: boolean;
|
|
1863
1879
|
editorClassName?: string;
|
|
1864
1880
|
autoFocus?: boolean;
|
|
1881
|
+
/** Maximum number of characters allowed in the editor */
|
|
1882
|
+
maxLength?: number;
|
|
1865
1883
|
/** Array of mention items that will be suggested */
|
|
1866
1884
|
mentions?: T[];
|
|
1867
1885
|
/** Configuration for mapping mention item fields. If not provided, assumes default structure {id, name, fieldName} */
|
|
@@ -1872,7 +1890,7 @@ type InputMentionProps<T = DefaultMentionItem> = {
|
|
|
1872
1890
|
plainTextMentions?: boolean;
|
|
1873
1891
|
} & Omit<React.HTMLAttributes<HTMLDivElement>, "onChange">;
|
|
1874
1892
|
|
|
1875
|
-
declare function InputMentionInner<T = DefaultMentionItem>({ value, onChange, placeholder, readOnly, disabled, editorClassName, autoFocus, mentions, mentionConfig, mentionTrigger, plainTextMentions, className, id, ...rest }: InputMentionProps<T>, ref: React.Ref<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
1893
|
+
declare function InputMentionInner<T = DefaultMentionItem>({ value, onChange, placeholder, readOnly, disabled, editorClassName, autoFocus, maxLength, mentions, mentionConfig, mentionTrigger, plainTextMentions, className, id, ...rest }: InputMentionProps<T>, ref: React.Ref<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
1876
1894
|
declare const InputMention: <T = DefaultMentionItem>(props: InputMentionProps<T> & {
|
|
1877
1895
|
ref?: React.Ref<HTMLDivElement>;
|
|
1878
1896
|
}) => ReturnType<typeof InputMentionInner>;
|
package/dist/index.d.ts
CHANGED
|
@@ -1290,6 +1290,8 @@ type RichTextProps<T = DefaultMentionItem$1> = {
|
|
|
1290
1290
|
onImageDialogUploadError?: (error: unknown) => void;
|
|
1291
1291
|
acceptImageMimeTypes?: string;
|
|
1292
1292
|
allowImageUrlInsert?: boolean;
|
|
1293
|
+
/** Maximum number of characters allowed in the editor */
|
|
1294
|
+
maxLength?: number;
|
|
1293
1295
|
/** Array of mention items that will be suggested */
|
|
1294
1296
|
mentions?: T[];
|
|
1295
1297
|
/** Configuration for mapping mention item fields. If not provided, assumes default structure {id, name, fieldName} */
|
|
@@ -1300,7 +1302,7 @@ type RichTextProps<T = DefaultMentionItem$1> = {
|
|
|
1300
1302
|
plainTextMentions?: boolean;
|
|
1301
1303
|
} & Omit<React.HTMLAttributes<HTMLDivElement>, "onChange">;
|
|
1302
1304
|
|
|
1303
|
-
declare function RichTextInner<T = DefaultMentionItem$1>({ value, defaultValue, onChange, onHtmlChange, onTextChange, placeholder, readOnly, disabled, editorClassName, toolbarClassName, autoFocus, onImageUpload, onImageUploadError, onImageDialogUpload, onImageDialogUploadError, acceptImageMimeTypes, allowImageUrlInsert, mentions, mentionConfig, mentionTrigger, plainTextMentions, className, id, ...rest }: RichTextProps<T>, ref: React.Ref<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
1305
|
+
declare function RichTextInner<T = DefaultMentionItem$1>({ value, defaultValue, onChange, onHtmlChange, onTextChange, placeholder, readOnly, disabled, editorClassName, toolbarClassName, autoFocus, onImageUpload, onImageUploadError, onImageDialogUpload, onImageDialogUploadError, acceptImageMimeTypes, allowImageUrlInsert, maxLength, mentions, mentionConfig, mentionTrigger, plainTextMentions, className, id, ...rest }: RichTextProps<T>, ref: React.Ref<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
1304
1306
|
declare const RichText: <T = DefaultMentionItem$1>(props: RichTextProps<T> & {
|
|
1305
1307
|
ref?: React.Ref<HTMLDivElement>;
|
|
1306
1308
|
}) => ReturnType<typeof RichTextInner>;
|
|
@@ -1593,15 +1595,25 @@ declare function SidebarLayout({ sidebar, children, layoutProps, sidebarProps, i
|
|
|
1593
1595
|
|
|
1594
1596
|
interface TimePickerProps {
|
|
1595
1597
|
id?: string;
|
|
1596
|
-
value?: string;
|
|
1597
|
-
/** Callback with
|
|
1598
|
-
onChange?: (
|
|
1598
|
+
value?: Date | string | null;
|
|
1599
|
+
/** Callback with Date object */
|
|
1600
|
+
onChange?: (date?: Date) => void;
|
|
1601
|
+
/** Callback with string value (HH:mm format by default) */
|
|
1602
|
+
onValueChange?: (value?: string) => void;
|
|
1599
1603
|
disabled?: boolean;
|
|
1600
1604
|
className?: string;
|
|
1605
|
+
buttonClassName?: string;
|
|
1606
|
+
wrapperClassName?: string;
|
|
1601
1607
|
placeholder?: string;
|
|
1602
1608
|
use24Hour?: boolean;
|
|
1603
1609
|
iconPosition?: "start" | "end" | "none";
|
|
1604
1610
|
icon?: React$1.ReactNode;
|
|
1611
|
+
allowClear?: boolean;
|
|
1612
|
+
clearAriaLabel?: string;
|
|
1613
|
+
displayFormatter?: (date: Date, use24Hour: boolean) => string;
|
|
1614
|
+
valueFormatter?: (date: Date) => string;
|
|
1615
|
+
valueParser?: (value: string) => Date | undefined;
|
|
1616
|
+
invalid?: boolean;
|
|
1605
1617
|
}
|
|
1606
1618
|
declare const TimePicker: React$1.ForwardRefExoticComponent<TimePickerProps & React$1.RefAttributes<HTMLInputElement>>;
|
|
1607
1619
|
|
|
@@ -1805,6 +1817,10 @@ type ComboboxProps<TData extends OptionData> = React$1.AriaAttributes & Omit<Vir
|
|
|
1805
1817
|
onOpenChange?: (isOpen: boolean) => void;
|
|
1806
1818
|
showValueWhenNoMatch?: boolean;
|
|
1807
1819
|
virtual?: boolean;
|
|
1820
|
+
isLoading?: boolean;
|
|
1821
|
+
loadingContent?: React$1.ReactNode;
|
|
1822
|
+
popoverProps?: Omit<React$1.ComponentProps<typeof Popover>, "open" | "onOpenChange">;
|
|
1823
|
+
popoverContentProps?: Omit<React$1.ComponentProps<typeof PopoverContent>, "children">;
|
|
1808
1824
|
};
|
|
1809
1825
|
declare const Combobox: <TData extends OptionData>(props: ComboboxProps<TData> & React$1.RefAttributes<HTMLButtonElement>) => React$1.ReactElement | null;
|
|
1810
1826
|
|
|
@@ -1862,6 +1878,8 @@ type InputMentionProps<T = DefaultMentionItem> = {
|
|
|
1862
1878
|
disabled?: boolean;
|
|
1863
1879
|
editorClassName?: string;
|
|
1864
1880
|
autoFocus?: boolean;
|
|
1881
|
+
/** Maximum number of characters allowed in the editor */
|
|
1882
|
+
maxLength?: number;
|
|
1865
1883
|
/** Array of mention items that will be suggested */
|
|
1866
1884
|
mentions?: T[];
|
|
1867
1885
|
/** Configuration for mapping mention item fields. If not provided, assumes default structure {id, name, fieldName} */
|
|
@@ -1872,7 +1890,7 @@ type InputMentionProps<T = DefaultMentionItem> = {
|
|
|
1872
1890
|
plainTextMentions?: boolean;
|
|
1873
1891
|
} & Omit<React.HTMLAttributes<HTMLDivElement>, "onChange">;
|
|
1874
1892
|
|
|
1875
|
-
declare function InputMentionInner<T = DefaultMentionItem>({ value, onChange, placeholder, readOnly, disabled, editorClassName, autoFocus, mentions, mentionConfig, mentionTrigger, plainTextMentions, className, id, ...rest }: InputMentionProps<T>, ref: React.Ref<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
1893
|
+
declare function InputMentionInner<T = DefaultMentionItem>({ value, onChange, placeholder, readOnly, disabled, editorClassName, autoFocus, maxLength, mentions, mentionConfig, mentionTrigger, plainTextMentions, className, id, ...rest }: InputMentionProps<T>, ref: React.Ref<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
1876
1894
|
declare const InputMention: <T = DefaultMentionItem>(props: InputMentionProps<T> & {
|
|
1877
1895
|
ref?: React.Ref<HTMLDivElement>;
|
|
1878
1896
|
}) => ReturnType<typeof InputMentionInner>;
|