aha-components 1.8.1 → 1.8.2
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/Input.esm.js +1 -1
- package/dist/Input.esm.js.map +1 -1
- package/dist/Input.js +1 -1
- package/dist/Input.js.map +1 -1
- package/dist/Pagination.esm.js +1 -1
- package/dist/Pagination.esm.js.map +1 -1
- package/dist/Pagination.js +1 -1
- package/dist/Pagination.js.map +1 -1
- package/dist/Table.esm.js +1 -1
- package/dist/Table.esm.js.map +1 -1
- package/dist/Table.js +1 -1
- package/dist/Table.js.map +1 -1
- package/dist/Textarea.esm.js +1 -1
- package/dist/Textarea.esm.js.map +1 -1
- package/dist/Textarea.js +1 -1
- package/dist/Textarea.js.map +1 -1
- package/dist/components/Checkbox/Checkbox.stories 2.d.ts +12 -0
- package/dist/components/Checkbox/index 2.d.ts +12 -0
- package/dist/components/DatePicker/DatePicker.stories 2.d.ts +25 -0
- package/dist/components/DatePicker/index 2.d.ts +96 -0
- package/dist/components/Drawer/Drawer.stories 2.d.ts +9 -0
- package/dist/components/Drawer/index 2.d.ts +58 -0
- package/dist/components/Form/Form.stories 2.d.ts +15 -0
- package/dist/components/Form/FormContext 2.d.ts +41 -0
- package/dist/components/Form/FormItem 2.d.ts +58 -0
- package/dist/components/Form/index 2.d.ts +85 -0
- package/dist/components/Input/Input.stories 2.d.ts +16 -0
- package/dist/components/Input/Input.stories.d.ts +7 -4
- package/dist/components/Input/InputGroup.d.ts +25 -0
- package/dist/components/Input/InputTags.d.ts +17 -0
- package/dist/components/Input/index 2.d.ts +41 -0
- package/dist/components/Input/index.d.ts +7 -18
- package/dist/components/Loading/Loading.stories 2.d.ts +11 -0
- package/dist/components/Loading/index 2.d.ts +10 -0
- package/dist/components/MenuList/MenuList.stories 2.d.ts +17 -0
- package/dist/components/MenuList/MenuList.test 2.d.ts +1 -0
- package/dist/components/MenuList/index 2.d.ts +85 -0
- package/dist/components/Pagination/Pagination.stories 2.d.ts +16 -0
- package/dist/components/Pagination/index 2.d.ts +27 -0
- package/dist/components/Popover/Popover.stories 2.d.ts +11 -0
- package/dist/components/Popover/index 2.d.ts +31 -0
- package/dist/components/Progress/Progress.stories 2.d.ts +18 -0
- package/dist/components/Progress/Progress.test 2.d.ts +1 -0
- package/dist/components/Progress/index 2.d.ts +33 -0
- package/dist/components/Radio/Radio.stories 2.d.ts +10 -0
- package/dist/components/Radio/index 2.d.ts +13 -0
- package/dist/components/Select/Select.stories 2.d.ts +17 -0
- package/dist/components/Select/index 2.d.ts +74 -0
- package/dist/components/Switch/Switch.stories 2.d.ts +14 -0
- package/dist/components/Switch/index 2.d.ts +27 -0
- package/dist/components/Tab/Tab.stories 2.d.ts +19 -0
- package/dist/components/Tab/index 2.d.ts +26 -0
- package/dist/components/Table/Table.stories 2.d.ts +21 -0
- package/dist/components/Table/index 2.d.ts +167 -0
- package/dist/components/Textarea/Textarea.stories 2.d.ts +15 -0
- package/dist/components/Textarea/Textarea.stories.d.ts +3 -6
- package/dist/components/Textarea/TextareaTags.d.ts +8 -0
- package/dist/components/Textarea/index 2.d.ts +38 -0
- package/dist/components/Textarea/index.d.ts +6 -17
- package/dist/components/Tooltip/Tooltip.stories 2.d.ts +20 -0
- package/dist/components/Tooltip/index 2.d.ts +35 -0
- package/dist/icons/index 2.d.ts +33 -0
- package/dist/index.css +962 -1
- package/dist/index.d.ts +54 -36
- package/dist/index.esm.css +962 -1
- package/dist/index.esm.js +1 -1
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/stories/DesignTokens.stories 2.d.ts +5 -0
- package/dist/theme/Theme.stories 2.d.ts +10 -0
- package/dist/theme/ThemeContext 2.d.ts +11 -0
- package/dist/theme/utils 2.d.ts +10 -0
- package/dist/tokens.d.ts +2 -0
- package/package.json +1 -1
- package/dist/AlertComponent.esm.js +0 -2
- package/dist/AlertComponent.esm.js.map +0 -1
- package/dist/AlertComponent.js +0 -2
- package/dist/AlertComponent.js.map +0 -1
- package/dist/Card.esm.js +0 -2
- package/dist/Card.esm.js.map +0 -1
- package/dist/Card.js +0 -2
- package/dist/Card.js.map +0 -1
- package/dist/TestComponent.esm.js +0 -2
- package/dist/TestComponent.esm.js.map +0 -1
- package/dist/TestComponent.js +0 -2
- package/dist/TestComponent.js.map +0 -1
- package/dist/Toast.css +0 -1
- package/dist/Toast.esm.css +0 -1
- package/dist/components/AlertComponent/index.d.ts +0 -9
- package/dist/components/Card/index.d.ts +0 -10
- package/dist/components/TestComponent/index.d.ts +0 -7
package/dist/index.d.ts
CHANGED
|
@@ -398,46 +398,77 @@ interface ProgressProps {
|
|
|
398
398
|
}
|
|
399
399
|
declare const Progress: React.FC<ProgressProps>;
|
|
400
400
|
|
|
401
|
+
interface InputGroupProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'size' | 'prefix' | 'suffix'> {
|
|
402
|
+
size?: 'small' | 'mediumSmall' | 'medium' | 'large';
|
|
403
|
+
error?: boolean;
|
|
404
|
+
readOnly?: boolean;
|
|
405
|
+
disabled?: boolean;
|
|
406
|
+
prefix?: React.ReactNode;
|
|
407
|
+
suffix?: React.ReactNode;
|
|
408
|
+
/** Text addon on the left (e.g. "https://") — auto-styled with correct padding */
|
|
409
|
+
leadingText?: React.ReactNode;
|
|
410
|
+
/** Text addon on the right (e.g. "USD") — auto-styled with correct padding */
|
|
411
|
+
trailingText?: React.ReactNode;
|
|
412
|
+
/** Raw ReactNode on the left (dropdown, icon button, etc.) — no padding added */
|
|
413
|
+
leadingAddon?: React.ReactNode;
|
|
414
|
+
/** Raw ReactNode on the right (button, select, etc.) — no padding added */
|
|
415
|
+
trailingAddon?: React.ReactNode;
|
|
416
|
+
onPressEnter?: (e: React.KeyboardEvent<HTMLInputElement>) => void;
|
|
417
|
+
className?: string;
|
|
418
|
+
style?: React.CSSProperties;
|
|
419
|
+
label?: string;
|
|
420
|
+
required?: boolean;
|
|
421
|
+
hintText?: string;
|
|
422
|
+
}
|
|
423
|
+
declare const InputGroup: React.ForwardRefExoticComponent<InputGroupProps & React.RefAttributes<HTMLInputElement>>;
|
|
424
|
+
|
|
425
|
+
interface InputTagsProps {
|
|
426
|
+
value?: string[];
|
|
427
|
+
defaultValue?: string[];
|
|
428
|
+
onChange?: (tags: string[]) => void;
|
|
429
|
+
placeholder?: string;
|
|
430
|
+
disabled?: boolean;
|
|
431
|
+
error?: boolean;
|
|
432
|
+
size?: 'small' | 'mediumSmall' | 'medium' | 'large';
|
|
433
|
+
className?: string;
|
|
434
|
+
style?: React.CSSProperties;
|
|
435
|
+
label?: string;
|
|
436
|
+
required?: boolean;
|
|
437
|
+
hintText?: string;
|
|
438
|
+
}
|
|
439
|
+
declare const InputTags: React.FC<InputTagsProps>;
|
|
440
|
+
|
|
401
441
|
interface InputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'size' | 'prefix' | 'suffix'> {
|
|
402
|
-
/** 输入框大小 */
|
|
403
442
|
size?: 'small' | 'mediumSmall' | 'medium' | 'large';
|
|
404
|
-
/** 是否禁用 */
|
|
405
443
|
disabled?: boolean;
|
|
406
|
-
/** 是否显示错误状态 */
|
|
407
444
|
error?: boolean;
|
|
408
|
-
/** 是否只读 */
|
|
409
445
|
readOnly?: boolean;
|
|
410
|
-
/** 输入框前缀图标 */
|
|
411
446
|
prefix?: React.ReactNode;
|
|
412
|
-
/** 输入框后缀图标 */
|
|
413
447
|
suffix?: React.ReactNode;
|
|
414
|
-
/** 允许清除 */
|
|
415
448
|
allowClear?: boolean;
|
|
416
|
-
/** 清除回调 */
|
|
417
449
|
onClear?: () => void;
|
|
418
|
-
/** 自定义类名 */
|
|
419
450
|
className?: string;
|
|
420
|
-
/** 自定义样式 */
|
|
421
451
|
style?: React.CSSProperties;
|
|
422
|
-
/** 输入框类型 */
|
|
423
452
|
type?: string;
|
|
424
|
-
/** 占位符 */
|
|
425
453
|
placeholder?: string;
|
|
426
|
-
/** 值 */
|
|
427
454
|
value?: string;
|
|
428
|
-
/** 默认值 */
|
|
429
455
|
defaultValue?: string;
|
|
430
|
-
/** 变化回调 */
|
|
431
456
|
onChange?: (e: React.ChangeEvent<HTMLInputElement>) => void;
|
|
432
|
-
/** 聚焦回调 */
|
|
433
457
|
onFocus?: (e: React.FocusEvent<HTMLInputElement>) => void;
|
|
434
|
-
/** 失焦回调 */
|
|
435
458
|
onBlur?: (e: React.FocusEvent<HTMLInputElement>) => void;
|
|
436
|
-
/** 按下回车回调 */
|
|
437
459
|
onPressEnter?: (e: React.KeyboardEvent<HTMLInputElement>) => void;
|
|
460
|
+
label?: string;
|
|
461
|
+
required?: boolean;
|
|
462
|
+
hintText?: string;
|
|
438
463
|
}
|
|
439
464
|
declare const Input: React.ForwardRefExoticComponent<InputProps & React.RefAttributes<HTMLInputElement>>;
|
|
440
465
|
|
|
466
|
+
interface TextareaTagsProps extends Omit<InputTagsProps, 'size'> {
|
|
467
|
+
minHeight?: number;
|
|
468
|
+
helpIcon?: React.ReactNode;
|
|
469
|
+
}
|
|
470
|
+
declare const TextareaTags: React.FC<TextareaTagsProps>;
|
|
471
|
+
|
|
441
472
|
interface LinkifyOptions {
|
|
442
473
|
validate?: (url: string) => boolean;
|
|
443
474
|
className?: string;
|
|
@@ -446,43 +477,30 @@ interface LinkifyOptions {
|
|
|
446
477
|
allowedTlds?: string[];
|
|
447
478
|
}
|
|
448
479
|
interface TextareaProps extends Omit<React.TextareaHTMLAttributes<HTMLTextAreaElement>, 'size'> {
|
|
449
|
-
/** 是否禁用 */
|
|
450
480
|
disabled?: boolean;
|
|
451
|
-
/** 是否显示错误状态 */
|
|
452
481
|
error?: boolean;
|
|
453
|
-
/** 是否只读 */
|
|
454
482
|
readOnly?: boolean;
|
|
455
|
-
/** 是否显示字符计数 */
|
|
456
483
|
showCount?: boolean;
|
|
457
|
-
/** 最大字符数 */
|
|
458
484
|
maxLength?: number;
|
|
459
|
-
/** 自定义类名 */
|
|
460
485
|
className?: string;
|
|
461
|
-
/** 自定义样式 */
|
|
462
486
|
style?: React.CSSProperties;
|
|
463
|
-
/** 占位符 */
|
|
464
487
|
placeholder?: string;
|
|
465
|
-
/** 值 */
|
|
466
488
|
value?: string;
|
|
467
|
-
/** 默认值 */
|
|
468
489
|
defaultValue?: string;
|
|
469
|
-
/** 行数 */
|
|
470
490
|
rows?: number;
|
|
471
|
-
/** 是否自动调整高度 */
|
|
472
491
|
autoSize?: boolean | {
|
|
473
492
|
minRows?: number;
|
|
474
493
|
maxRows?: number;
|
|
475
494
|
};
|
|
476
|
-
/** 变化回调 */
|
|
477
495
|
onChange?: (e: React.ChangeEvent<HTMLTextAreaElement>) => void;
|
|
478
|
-
/** 聚焦回调 */
|
|
479
496
|
onFocus?: (e: React.FocusEvent<HTMLTextAreaElement>) => void;
|
|
480
|
-
/** 失焦回调 */
|
|
481
497
|
onBlur?: (e: React.FocusEvent<HTMLTextAreaElement>) => void;
|
|
482
|
-
/** 是否启用实时链接识别 */
|
|
483
498
|
linkify?: boolean;
|
|
484
|
-
/** 链接识别配置 */
|
|
485
499
|
linkifyOptions?: LinkifyOptions;
|
|
500
|
+
label?: string;
|
|
501
|
+
required?: boolean;
|
|
502
|
+
hintText?: string;
|
|
503
|
+
helpIcon?: React.ReactNode;
|
|
486
504
|
}
|
|
487
505
|
declare const Textarea: React.ForwardRefExoticComponent<TextareaProps & React.RefAttributes<HTMLTextAreaElement>>;
|
|
488
506
|
|
|
@@ -1154,4 +1172,4 @@ declare const MinusIcon: React.FC<{
|
|
|
1154
1172
|
style?: React.CSSProperties;
|
|
1155
1173
|
}>;
|
|
1156
1174
|
|
|
1157
|
-
export { Alert, AlertProps, Avatar, AvatarLabelGroup, AvatarLabelGroupProps, AvatarProps, AvatarSize, Badge, BadgeColor, BadgeIcon, BadgeIconComponent, BadgeIconProps, BadgeProps, BadgeSize, BadgeVariant, BadgeWithButton, BadgeWithButtonProps, BadgeWithDot, BadgeWithDotProps, BadgeWithIcon, BadgeWithIconProps, BadgeWithImage, BadgeWithImageProps, Button, ButtonProps, CheckIcon, Checkbox, CheckboxProps, ColumnType, DatePicker, DatePickerProps, DateRange, Drawer, DrawerPlacement, DrawerProps, FormWithItem as Form, FormInstance, FormItemProps, FormProps, Input, InputProps, Loading, LoadingProps, MenuGroupType, MenuItemType, MenuList, MenuListProps, MinusIcon, Pagination, PaginationProps, Popover, PopoverPlacement, PopoverProps, PopoverTrigger, Progress, ProgressProps, ProgressStatus, ProgressType, Radio, RadioProps, Select, SelectOption, SelectProps, SortOrder, SorterResult, Switch, SwitchProps, Tab, TabItem, TabLayout, TabProps, TabVariant, Table, TableCurrentDataSource, TableLayout, TableProps, TableRowSelection, TableSize, Tag, TagProps, Textarea, TextareaProps, ThemeConfig, ThemeProvider, ThemeProviderProps, Toast, ToastPosition, ToastProps, ToastProvider, ToastType, Tooltip, TooltipPosition, TooltipProps, UserProfileType, clearAllToasts, closeToast, debugToast, toast, toastError, toastInfo, toastQuestion, toastSuccess, useTheme };
|
|
1175
|
+
export { Alert, AlertProps, Avatar, AvatarLabelGroup, AvatarLabelGroupProps, AvatarProps, AvatarSize, Badge, BadgeColor, BadgeIcon, BadgeIconComponent, BadgeIconProps, BadgeProps, BadgeSize, BadgeVariant, BadgeWithButton, BadgeWithButtonProps, BadgeWithDot, BadgeWithDotProps, BadgeWithIcon, BadgeWithIconProps, BadgeWithImage, BadgeWithImageProps, Button, ButtonProps, CheckIcon, Checkbox, CheckboxProps, ColumnType, DatePicker, DatePickerProps, DateRange, Drawer, DrawerPlacement, DrawerProps, FormWithItem as Form, FormInstance, FormItemProps, FormProps, Input, InputGroup, InputGroupProps, InputProps, InputTags, InputTagsProps, Loading, LoadingProps, MenuGroupType, MenuItemType, MenuList, MenuListProps, MinusIcon, Pagination, PaginationProps, Popover, PopoverPlacement, PopoverProps, PopoverTrigger, Progress, ProgressProps, ProgressStatus, ProgressType, Radio, RadioProps, Select, SelectOption, SelectProps, SortOrder, SorterResult, Switch, SwitchProps, Tab, TabItem, TabLayout, TabProps, TabVariant, Table, TableCurrentDataSource, TableLayout, TableProps, TableRowSelection, TableSize, Tag, TagProps, Textarea, TextareaProps, TextareaTags, TextareaTagsProps, ThemeConfig, ThemeProvider, ThemeProviderProps, Toast, ToastPosition, ToastProps, ToastProvider, ToastType, Tooltip, TooltipPosition, TooltipProps, UserProfileType, clearAllToasts, closeToast, debugToast, toast, toastError, toastInfo, toastQuestion, toastSuccess, useTheme };
|