@nutui/nutui-react-taro 1.4.0 → 1.4.1
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/CHANGELOG.md +13 -0
- package/dist/esm/Audio.js +3 -3
- package/dist/esm/Icon/style/index.js +1 -2
- package/dist/esm/ImagePreview.js +3 -3
- package/dist/esm/Input.js +2 -2
- package/dist/esm/Range.js +2 -2
- package/dist/esm/Swiper.js +2 -2
- package/dist/esm/{audio.taro-c94fc58b.js → audio.taro-20890c93.js} +1 -1
- package/dist/esm/{imagepreview.taro-69d47ab0.js → imagepreview.taro-68e776f5.js} +1 -1
- package/dist/esm/{input.taro-eef88020.js → input.taro-65db24c3.js} +3 -3
- package/dist/esm/nutui-react.es.js +5 -5
- package/dist/esm/{range.taro-3e610b5c.js → range.taro-4cbe2469.js} +1 -4
- package/dist/esm/{swiper.taro-f314d67a.js → swiper.taro-852f6615.js} +8 -4
- package/dist/esm/types/src/packages/actionsheet/actionsheet.d.ts +1 -1
- package/dist/esm/types/src/packages/actionsheet/actionsheet.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/animate/type.d.ts +2 -2
- package/dist/esm/types/src/packages/animatingnumbers/animatingnumbers.d.ts +1 -1
- package/dist/esm/types/src/packages/animatingnumbers/animatingnumbers.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/avatar/avatar.d.ts +1 -1
- package/dist/esm/types/src/packages/avatar/avatar.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/badge/badge.d.ts +1 -1
- package/dist/esm/types/src/packages/badge/badge.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/button/button.d.ts +3 -3
- package/dist/esm/types/src/packages/button/button.taro.d.ts +4 -4
- package/dist/esm/types/src/packages/calendar/calendar.d.ts +1 -1
- package/dist/esm/types/src/packages/calendaritem/calendaritem.d.ts +2 -2
- package/dist/esm/types/src/packages/calendaritem/calendaritem.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/cascader/types.d.ts +1 -1
- package/dist/esm/types/src/packages/col/col.d.ts +1 -1
- package/dist/esm/types/src/packages/col/col.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/dialog/Mask.d.ts +1 -1
- package/dist/esm/types/src/packages/dialog/config.d.ts +2 -2
- package/dist/esm/types/src/packages/dialog/dialog.d.ts +1 -1
- package/dist/esm/types/src/packages/dialog/dialog.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/divider/divider.d.ts +2 -2
- package/dist/esm/types/src/packages/divider/divider.taro.d.ts +2 -2
- package/dist/esm/types/src/packages/ellipsis/ellipsis.d.ts +1 -1
- package/dist/esm/types/src/packages/ellipsis/ellipsis.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/fixednav/fixednav.d.ts +2 -2
- package/dist/esm/types/src/packages/fixednav/fixednav.taro.d.ts +2 -2
- package/dist/esm/types/src/packages/form/types.d.ts +2 -2
- package/dist/esm/types/src/packages/formitem/formitem.d.ts +2 -2
- package/dist/esm/types/src/packages/formitem/formitem.taro.d.ts +2 -2
- package/dist/esm/types/src/packages/formitem/types.d.ts +2 -2
- package/dist/esm/types/src/packages/grid/grid.d.ts +1 -1
- package/dist/esm/types/src/packages/grid/grid.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/griditem/griditem.d.ts +1 -1
- package/dist/esm/types/src/packages/griditem/griditem.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/image/image.d.ts +2 -2
- package/dist/esm/types/src/packages/image/image.taro.d.ts +2 -2
- package/dist/esm/types/src/packages/input/input.d.ts +5 -5
- package/dist/esm/types/src/packages/input/input.taro.d.ts +5 -5
- package/dist/esm/types/src/packages/popover/popover.d.ts +2 -2
- package/dist/esm/types/src/packages/popover/popover.taro.d.ts +2 -2
- package/dist/esm/types/src/packages/popup/popup.d.ts +1 -1
- package/dist/esm/types/src/packages/popup/popup.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/progress/progress.d.ts +2 -2
- package/dist/esm/types/src/packages/progress/progress.taro.d.ts +2 -2
- package/dist/esm/types/src/packages/pulltorefresh/pulltorefresh.d.ts +1 -1
- package/dist/esm/types/src/packages/pulltorefresh/pulltorefresh.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/radio/radio.d.ts +2 -2
- package/dist/esm/types/src/packages/radio/radio.taro.d.ts +2 -2
- package/dist/esm/types/src/packages/radiogroup/radiogroup.d.ts +2 -2
- package/dist/esm/types/src/packages/radiogroup/radiogroup.taro.d.ts +2 -2
- package/dist/esm/types/src/packages/range/range.d.ts +1 -2
- package/dist/esm/types/src/packages/range/range.taro.d.ts +1 -2
- package/dist/esm/types/src/packages/row/row.d.ts +1 -1
- package/dist/esm/types/src/packages/row/row.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/sidenavbar/sidenavbar.d.ts +1 -1
- package/dist/esm/types/src/packages/sidenavbar/sidenavbar.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/sidenavbar/type.d.ts +3 -3
- package/dist/esm/types/src/packages/sidenavbaritem/sidenavbaritem.d.ts +1 -1
- package/dist/esm/types/src/packages/sidenavbaritem/sidenavbaritem.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/skeleton/skeleton.d.ts +1 -1
- package/dist/esm/types/src/packages/skeleton/skeleton.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/subsidenavbar/subsidenavbar.d.ts +1 -1
- package/dist/esm/types/src/packages/subsidenavbar/subsidenavbar.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/swipe/swipe.d.ts +2 -2
- package/dist/esm/types/src/packages/swipe/swipe.taro.d.ts +2 -2
- package/dist/esm/types/src/packages/swiper/swiper.d.ts +2 -1
- package/dist/esm/types/src/packages/swiper/swiper.taro.d.ts +2 -1
- package/dist/esm/types/src/packages/table/table.d.ts +1 -1
- package/dist/esm/types/src/packages/table/table.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/tabs/tabs.d.ts +1 -1
- package/dist/esm/types/src/packages/tabs/tabs.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/tag/tag.d.ts +1 -1
- package/dist/esm/types/src/packages/tag/tag.taro.d.ts +1 -1
- package/dist/esm/types/src/packages/uploader/uploader.d.ts +2 -2
- package/dist/esm/types/src/packages/uploader/uploader.taro.d.ts +2 -2
- package/dist/esm/types/src/packages/virtuallist/type.d.ts +1 -1
- package/dist/esm/types/src/packages/virtuallist/virtuallist.d.ts +1 -1
- package/dist/esm/types/src/packages/virtuallist/virtuallist.taro.d.ts +1 -1
- package/dist/esm/types/src/utils/get-scroll-parent.d.ts +1 -1
- package/dist/esm/types/src/utils/render.d.ts +1 -1
- package/dist/esm/types/src/utils/useTouch.d.ts +1 -1
- package/dist/esm/types/src/utils/useWatch.d.ts +2 -2
- package/dist/locales/base.js +1 -1
- package/dist/locales/en-US.js +1 -1
- package/dist/locales/id-ID.js +1 -1
- package/dist/locales/zh-CN.js +1 -1
- package/dist/locales/zh-TW.js +1 -1
- package/dist/locales/zh-UG.js +1 -1
- package/dist/nutui.react.es.js +89 -77
- package/dist/nutui.react.umd.js +89 -77
- package/dist/packages/input/input.scss +15 -0
- package/dist/packages/searchbar/searchbar.scss +6 -13
- package/dist/packages/swiper/swiper.scss +0 -3
- package/dist/style.css +1 -1
- package/dist/style.es.js +1 -1
- package/dist/styles/themes/default.scss +1 -0
- package/dist/styles/variables.scss +8 -4
- package/dist/types/index.d.ts +55 -55
- package/package.json +2 -1
package/dist/style.es.js
CHANGED
|
@@ -83,6 +83,10 @@ $divider-color: $gray9 !default;
|
|
|
83
83
|
$font-family: PingFang SC, Microsoft YaHei, Helvetica, Hiragino Sans GB, SimSun,
|
|
84
84
|
sans-serif !default;
|
|
85
85
|
|
|
86
|
+
// --- z-index ----
|
|
87
|
+
$mask-z-index: 1000;
|
|
88
|
+
$mask-content-z-index: 1200;
|
|
89
|
+
|
|
86
90
|
// ---- Animation ----
|
|
87
91
|
$animation-duration: 0.25s !default;
|
|
88
92
|
$animation-timing-fun: cubic-bezier(0.55, 0.085, 0.68, 0.53) !default;
|
|
@@ -533,9 +537,9 @@ $dialog-header-height: 20px !default;
|
|
|
533
537
|
$dialog-content-margin: 20px 0 !default;
|
|
534
538
|
$dialog-content-max-height: 268px !default;
|
|
535
539
|
$dialog-content-line-height: 16px !default;
|
|
536
|
-
$dialog-mask-z-index:
|
|
540
|
+
$dialog-mask-z-index: $mask-z-index !default;
|
|
537
541
|
$dialog-mask-background-color: $mask-color !default;
|
|
538
|
-
$dialog-outer-z-index:
|
|
542
|
+
$dialog-outer-z-index: $mask-content-z-index !default;
|
|
539
543
|
$dialog-outer-bordder-radius: 20px !default;
|
|
540
544
|
$dialog-vertical-footer-ok-margin-top: 10px !default;
|
|
541
545
|
$dialog-footer-button-min-width: 100px !default;
|
|
@@ -794,7 +798,7 @@ $menu-item-option-padding-bottom: 12px !default;
|
|
|
794
798
|
$menu-item-option-i-margin-right: 6px !default;
|
|
795
799
|
$menu-bar-box-shadow: 0 2px 12px rgba(89, 89, 89, 0.12) !default;
|
|
796
800
|
$menu-scroll-fixed-top: 0 !default;
|
|
797
|
-
$menu-scroll-fixed-z-index:
|
|
801
|
+
$menu-scroll-fixed-z-index: $mask-z-index !default;
|
|
798
802
|
$menu-active-item-font-weight: 500 !default;
|
|
799
803
|
$menu-item-content-bg-color: $gray6 !default;
|
|
800
804
|
|
|
@@ -1061,7 +1065,7 @@ $comment-shop-color: $primary-color !default;
|
|
|
1061
1065
|
$ellipsis-expand-collapse-color: #3460fa !default;
|
|
1062
1066
|
|
|
1063
1067
|
// WaterMark(✅ todo:react版本该组件暂无,将变量先迁过来)
|
|
1064
|
-
$watermark-z-index:
|
|
1068
|
+
$watermark-z-index: $mask-content-z-index !default;
|
|
1065
1069
|
|
|
1066
1070
|
// invoice(✅ todo:react版本该组件暂无,将变量先迁过来)
|
|
1067
1071
|
$invoice-padding: 10px 10px 20px !default;
|
package/dist/types/index.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ interface BasicComponent {
|
|
|
11
11
|
children?: ReactNode;
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
-
|
|
14
|
+
type OmitMiniProgramButtonProps = Omit<ButtonProps$1, 'size' | 'type' | 'onClick'>;
|
|
15
15
|
interface ButtonProps extends BasicComponent, OmitMiniProgramButtonProps {
|
|
16
16
|
className: string;
|
|
17
17
|
color: string;
|
|
@@ -27,9 +27,9 @@ interface ButtonProps extends BasicComponent, OmitMiniProgramButtonProps {
|
|
|
27
27
|
children: any;
|
|
28
28
|
onClick: (e: MouseEvent) => void;
|
|
29
29
|
}
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
30
|
+
type ButtonType = 'default' | 'primary' | 'info' | 'success' | 'warning' | 'danger';
|
|
31
|
+
type ButtonSize = 'large' | 'normal' | 'small';
|
|
32
|
+
type ButtonShape = 'square' | 'round';
|
|
33
33
|
declare const Button: FunctionComponent<Partial<ButtonProps>>;
|
|
34
34
|
|
|
35
35
|
interface CellProps extends BasicComponent {
|
|
@@ -92,7 +92,7 @@ interface OverlayProps {
|
|
|
92
92
|
}
|
|
93
93
|
declare const Overlay: FunctionComponent<Partial<OverlayProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
94
94
|
|
|
95
|
-
|
|
95
|
+
type Teleport = HTMLElement | (() => HTMLElement) | null;
|
|
96
96
|
interface PopupProps extends OverlayProps, BasicComponent {
|
|
97
97
|
position: string;
|
|
98
98
|
transition: string;
|
|
@@ -270,15 +270,15 @@ interface ImageProps {
|
|
|
270
270
|
onLoad?: () => void;
|
|
271
271
|
onError?: () => void;
|
|
272
272
|
}
|
|
273
|
-
|
|
274
|
-
|
|
273
|
+
type ImageFit = 'contain' | 'cover' | 'fill' | 'none' | 'scale-down' | string;
|
|
274
|
+
type ImagePosition = 'center' | 'top' | 'right' | 'bottom' | 'left' | string;
|
|
275
275
|
declare const Image: FunctionComponent<Partial<ImageProps> & Omit<React__default.HTMLAttributes<HTMLDivElement>, 'onClick' | 'onLoad' | 'onError'>>;
|
|
276
276
|
|
|
277
277
|
interface LayoutProps {
|
|
278
278
|
}
|
|
279
279
|
declare const Layout: FunctionComponent<Partial<LayoutProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
280
280
|
|
|
281
|
-
|
|
281
|
+
type EventType$1 = 'row' | 'col';
|
|
282
282
|
interface ColProps {
|
|
283
283
|
span: string | number;
|
|
284
284
|
offset: string | number;
|
|
@@ -287,7 +287,7 @@ interface ColProps {
|
|
|
287
287
|
}
|
|
288
288
|
declare const Col: FunctionComponent<Partial<ColProps> & Omit<React__default.HTMLAttributes<HTMLDivElement>, 'onClick'>>;
|
|
289
289
|
|
|
290
|
-
|
|
290
|
+
type EventType = 'row' | 'col';
|
|
291
291
|
interface RowProps {
|
|
292
292
|
type: string;
|
|
293
293
|
justify: string;
|
|
@@ -298,8 +298,8 @@ interface RowProps {
|
|
|
298
298
|
}
|
|
299
299
|
declare const Row: FunctionComponent<Partial<RowProps> & Omit<React__default.HTMLAttributes<HTMLDivElement>, 'onClick'>>;
|
|
300
300
|
|
|
301
|
-
|
|
302
|
-
|
|
301
|
+
type ContentPositionType = 'left' | 'center' | 'right';
|
|
302
|
+
type DirectionType = 'horizontal' | 'vertical';
|
|
303
303
|
interface DividerProps {
|
|
304
304
|
contentPosition: ContentPositionType;
|
|
305
305
|
dashed: boolean;
|
|
@@ -310,7 +310,7 @@ interface DividerProps {
|
|
|
310
310
|
}
|
|
311
311
|
declare const Divider: FunctionComponent<Partial<DividerProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
312
312
|
|
|
313
|
-
|
|
313
|
+
type GridDirection$1 = 'horizontal' | 'vertical';
|
|
314
314
|
interface GridItemProps extends BasicComponent {
|
|
315
315
|
text: string | ReactNode;
|
|
316
316
|
icon: string | ReactNode;
|
|
@@ -329,7 +329,7 @@ interface GridItemProps extends BasicComponent {
|
|
|
329
329
|
}
|
|
330
330
|
declare const GridItem: FunctionComponent<Partial<GridItemProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
331
331
|
|
|
332
|
-
|
|
332
|
+
type GridDirection = 'horizontal' | 'vertical';
|
|
333
333
|
interface GridProps {
|
|
334
334
|
columnNum: string | number;
|
|
335
335
|
border: boolean;
|
|
@@ -371,8 +371,8 @@ interface NavBarProps$1 extends BasicComponent {
|
|
|
371
371
|
}
|
|
372
372
|
declare const NavBar: FunctionComponent<Partial<NavBarProps$1>>;
|
|
373
373
|
|
|
374
|
-
|
|
375
|
-
|
|
374
|
+
type Direction$1 = 'right' | 'left';
|
|
375
|
+
type Position$2 = {
|
|
376
376
|
top?: string;
|
|
377
377
|
bottom?: string;
|
|
378
378
|
};
|
|
@@ -470,7 +470,7 @@ declare class Title {
|
|
|
470
470
|
index: number;
|
|
471
471
|
constructor();
|
|
472
472
|
}
|
|
473
|
-
|
|
473
|
+
type TabsSize = 'large' | 'normal' | 'small';
|
|
474
474
|
interface TabsProps extends BasicComponent {
|
|
475
475
|
className: string;
|
|
476
476
|
style: React__default.CSSProperties;
|
|
@@ -517,7 +517,7 @@ interface IndicatorProps {
|
|
|
517
517
|
}
|
|
518
518
|
declare const Indicator: FunctionComponent<Partial<IndicatorProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
519
519
|
|
|
520
|
-
|
|
520
|
+
type NavBarProps = {
|
|
521
521
|
showhead?: boolean;
|
|
522
522
|
};
|
|
523
523
|
interface SideNavBarProps extends React__default.HTMLAttributes<HTMLDivElement>, NavBarProps {
|
|
@@ -531,7 +531,7 @@ interface SideNavBarProps extends React__default.HTMLAttributes<HTMLDivElement>,
|
|
|
531
531
|
}
|
|
532
532
|
declare const SideNavBar: FunctionComponent<SideNavBarProps>;
|
|
533
533
|
|
|
534
|
-
|
|
534
|
+
type SubSideNavBarProps = {
|
|
535
535
|
title: string;
|
|
536
536
|
ikey: string | number;
|
|
537
537
|
open?: boolean;
|
|
@@ -544,7 +544,7 @@ declare type SubSideNavBarProps = {
|
|
|
544
544
|
};
|
|
545
545
|
declare const SubSideNavBar: FunctionComponent<SubSideNavBarProps>;
|
|
546
546
|
|
|
547
|
-
|
|
547
|
+
type SideNavBarItemProps = {
|
|
548
548
|
title: string;
|
|
549
549
|
ikey: string | number;
|
|
550
550
|
onClick?: ({ title, ikey }: {
|
|
@@ -590,7 +590,7 @@ interface MenuItemProps extends BasicComponent {
|
|
|
590
590
|
}
|
|
591
591
|
declare const MenuItem: React__default.ForwardRefExoticComponent<Partial<MenuItemProps> & React__default.RefAttributes<unknown>>;
|
|
592
592
|
|
|
593
|
-
|
|
593
|
+
type SliderValue = number | number[];
|
|
594
594
|
interface RangeProps {
|
|
595
595
|
className: string;
|
|
596
596
|
style: CSSProperties;
|
|
@@ -611,7 +611,6 @@ interface RangeProps {
|
|
|
611
611
|
button: React__default.ReactNode;
|
|
612
612
|
vertical: boolean;
|
|
613
613
|
marks: Record<string, unknown>;
|
|
614
|
-
change?: (value: number) => void;
|
|
615
614
|
dragStart?: () => void;
|
|
616
615
|
dragEnd?: () => void;
|
|
617
616
|
onChange?: (value: number) => void;
|
|
@@ -727,10 +726,10 @@ interface InputNumberProps extends BasicComponent {
|
|
|
727
726
|
}
|
|
728
727
|
declare const InputNumber: FunctionComponent<Partial<InputNumberProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
729
728
|
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
729
|
+
type InputAlignType = 'left' | 'center' | 'right';
|
|
730
|
+
type InputFormatTrigger = 'onChange' | 'onBlur';
|
|
731
|
+
type InputType = HTMLInputTypeAttribute;
|
|
732
|
+
type InputRule = {
|
|
734
733
|
pattern?: RegExp;
|
|
735
734
|
message?: string;
|
|
736
735
|
required?: boolean;
|
|
@@ -792,8 +791,8 @@ interface InputProps extends BasicComponent {
|
|
|
792
791
|
}
|
|
793
792
|
declare const Input: FunctionComponent<Partial<InputProps> & Omit<React__default.HTMLAttributes<HTMLDivElement>, 'onChange' | 'onBlur' | 'onFocus' | 'onClick'>>;
|
|
794
793
|
|
|
795
|
-
|
|
796
|
-
|
|
794
|
+
type Position$1 = 'left' | 'right';
|
|
795
|
+
type Direction = 'horizontal' | 'vertical';
|
|
797
796
|
interface RadioGroupProps {
|
|
798
797
|
value: string | number | boolean | null;
|
|
799
798
|
textPosition: Position$1;
|
|
@@ -803,8 +802,8 @@ interface RadioGroupProps {
|
|
|
803
802
|
}
|
|
804
803
|
declare const RadioGroup: React__default.ForwardRefExoticComponent<Partial<RadioGroupProps> & Omit<React__default.HTMLAttributes<HTMLDivElement>, "onChange"> & React__default.RefAttributes<unknown>>;
|
|
805
804
|
|
|
806
|
-
|
|
807
|
-
|
|
805
|
+
type Shape = 'button' | 'round';
|
|
806
|
+
type Position = 'right' | 'left';
|
|
808
807
|
interface RadioProps extends BasicComponent {
|
|
809
808
|
className: string;
|
|
810
809
|
style: React__default.CSSProperties;
|
|
@@ -839,7 +838,7 @@ interface RateProps extends BasicComponent {
|
|
|
839
838
|
}
|
|
840
839
|
declare const Rate: FunctionComponent<Partial<RateProps>>;
|
|
841
840
|
|
|
842
|
-
|
|
841
|
+
type InputDate = string | string[];
|
|
843
842
|
interface CalendarItemProps {
|
|
844
843
|
type?: string;
|
|
845
844
|
isAutoBackFill?: boolean;
|
|
@@ -936,10 +935,10 @@ declare class UploadOptions {
|
|
|
936
935
|
beforeXhrUpload?: Function;
|
|
937
936
|
}
|
|
938
937
|
|
|
939
|
-
|
|
938
|
+
type FileType$1<T> = {
|
|
940
939
|
[key: string]: T;
|
|
941
940
|
};
|
|
942
|
-
|
|
941
|
+
type FileItemStatus = 'ready' | 'uploading' | 'success' | 'error' | 'removed';
|
|
943
942
|
/** 图片的尺寸 */
|
|
944
943
|
interface sizeType {
|
|
945
944
|
/** 原图 */
|
|
@@ -1172,7 +1171,7 @@ interface ConfigConsumerProps {
|
|
|
1172
1171
|
}
|
|
1173
1172
|
declare const FormItemContext: React$1.Context<ConfigConsumerProps>;
|
|
1174
1173
|
|
|
1175
|
-
|
|
1174
|
+
type TextAlign = 'start' | 'end' | 'left' | 'right' | 'center' | 'justify' | 'match-parent';
|
|
1176
1175
|
interface FormItemProps extends BasicComponent, BaseFormField {
|
|
1177
1176
|
labelWidth: string | number;
|
|
1178
1177
|
errorMessageAlign: TextAlign;
|
|
@@ -1180,7 +1179,7 @@ interface FormItemProps extends BasicComponent, BaseFormField {
|
|
|
1180
1179
|
showErrorMessage: boolean;
|
|
1181
1180
|
}
|
|
1182
1181
|
declare const defaultProps: FormItemProps;
|
|
1183
|
-
|
|
1182
|
+
type FieldProps = typeof defaultProps & Partial<BaseFormField>;
|
|
1184
1183
|
declare class FormItem extends React__default.Component<FieldProps> {
|
|
1185
1184
|
static defaultProps: FormItemProps;
|
|
1186
1185
|
static contextType: any;
|
|
@@ -1229,7 +1228,7 @@ declare const Form: FunctionComponent<Partial<FormProps> & React__default.HTMLAt
|
|
|
1229
1228
|
Item: typeof FormItem;
|
|
1230
1229
|
};
|
|
1231
1230
|
|
|
1232
|
-
|
|
1231
|
+
type ItemType<T> = {
|
|
1233
1232
|
[key: string]: T;
|
|
1234
1233
|
};
|
|
1235
1234
|
interface ActionSheetProps {
|
|
@@ -1278,7 +1277,7 @@ interface DragProps {
|
|
|
1278
1277
|
}
|
|
1279
1278
|
declare const Drag: FunctionComponent<Partial<DragProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
1280
1279
|
|
|
1281
|
-
|
|
1280
|
+
type DialogConfigType = {
|
|
1282
1281
|
prefixCls?: string;
|
|
1283
1282
|
simple?: boolean;
|
|
1284
1283
|
};
|
|
@@ -1307,7 +1306,7 @@ interface BasicDialogProps {
|
|
|
1307
1306
|
onClickSelf?: () => void;
|
|
1308
1307
|
onConfirm?: (e?: MouseEvent) => Promise<() => void> | void;
|
|
1309
1308
|
}
|
|
1310
|
-
|
|
1309
|
+
type DialogReturnProps = {
|
|
1311
1310
|
update: (newConfig: ConfirmProps) => void;
|
|
1312
1311
|
close: () => void;
|
|
1313
1312
|
};
|
|
@@ -1324,7 +1323,7 @@ interface DialogComponent extends ForwardRefExoticComponent<PropsWithChildren<Ba
|
|
|
1324
1323
|
destroyAll: () => void;
|
|
1325
1324
|
}
|
|
1326
1325
|
|
|
1327
|
-
|
|
1326
|
+
type DialogProps = BasicDialogProps;
|
|
1328
1327
|
declare const Dialog: DialogComponent;
|
|
1329
1328
|
|
|
1330
1329
|
interface InfiniteloadingProps extends BasicComponent {
|
|
@@ -1399,8 +1398,8 @@ interface ToastProps {
|
|
|
1399
1398
|
}
|
|
1400
1399
|
declare const Toast: FunctionComponent<Partial<ToastProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
1401
1400
|
|
|
1402
|
-
|
|
1403
|
-
|
|
1401
|
+
type SwipeSide = 'left' | 'right';
|
|
1402
|
+
type SwipePosition = SwipeSide | 'cell' | 'outside';
|
|
1404
1403
|
interface SwipeInstance {
|
|
1405
1404
|
open: (side: SwipeSide) => void;
|
|
1406
1405
|
close: () => void;
|
|
@@ -1440,7 +1439,7 @@ interface SwipeProps {
|
|
|
1440
1439
|
}
|
|
1441
1440
|
declare const Swipe: React__default.ForwardRefExoticComponent<Partial<SwipeProps> & React__default.HTMLAttributes<HTMLDivElement> & React__default.RefAttributes<SwipeInstance>>;
|
|
1442
1441
|
|
|
1443
|
-
|
|
1442
|
+
type PullStatus = 'pulling' | 'canRelease' | 'refreshing' | 'complete';
|
|
1444
1443
|
interface PullToRefreshProps {
|
|
1445
1444
|
className: string;
|
|
1446
1445
|
style: React__default.CSSProperties;
|
|
@@ -1519,7 +1518,7 @@ interface StepProps extends BasicComponent {
|
|
|
1519
1518
|
}
|
|
1520
1519
|
declare const Step: FunctionComponent<Partial<StepProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
1521
1520
|
|
|
1522
|
-
|
|
1521
|
+
type SwiperRef = {
|
|
1523
1522
|
to: (index: number) => void;
|
|
1524
1523
|
next: () => void;
|
|
1525
1524
|
prev: () => void;
|
|
@@ -1532,6 +1531,7 @@ interface SwiperProps {
|
|
|
1532
1531
|
autoPlay: number | string;
|
|
1533
1532
|
direction: 'horizontal' | 'vertical';
|
|
1534
1533
|
paginationColor: string;
|
|
1534
|
+
paginationBgColor: string;
|
|
1535
1535
|
paginationVisible: boolean;
|
|
1536
1536
|
loop: boolean;
|
|
1537
1537
|
touchable: boolean;
|
|
@@ -1566,7 +1566,7 @@ interface AvatarProps extends BasicComponent {
|
|
|
1566
1566
|
onActiveAvatar: (e: MouseEvent) => void;
|
|
1567
1567
|
onError: (e: any) => void;
|
|
1568
1568
|
}
|
|
1569
|
-
|
|
1569
|
+
type AvatarShape = 'round' | 'square';
|
|
1570
1570
|
declare const Avatar: FunctionComponent<Partial<AvatarProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
1571
1571
|
|
|
1572
1572
|
interface AvatarGroupProps {
|
|
@@ -1622,11 +1622,11 @@ interface TagProps extends BasicComponent {
|
|
|
1622
1622
|
onClose: (e?: any) => void;
|
|
1623
1623
|
children?: React__default.ReactNode;
|
|
1624
1624
|
}
|
|
1625
|
-
|
|
1625
|
+
type TagType = 'default' | 'primary' | 'success' | 'warning' | 'danger';
|
|
1626
1626
|
declare const Tag: FunctionComponent<Partial<TagProps>>;
|
|
1627
1627
|
|
|
1628
|
-
|
|
1629
|
-
|
|
1628
|
+
type PopoverTheme = 'light' | 'dark';
|
|
1629
|
+
type PopoverLocation = 'bottom' | 'top' | 'left' | 'right' | 'top-start' | 'top-end' | 'bottom-start' | 'bottom-end' | 'left-start' | 'left-end' | 'right-start' | 'right-end';
|
|
1630
1630
|
interface List {
|
|
1631
1631
|
name: string;
|
|
1632
1632
|
icon?: string;
|
|
@@ -1646,7 +1646,7 @@ interface PopoverProps extends BasicComponent {
|
|
|
1646
1646
|
}
|
|
1647
1647
|
declare const Popover: FunctionComponent<Partial<PopoverProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
1648
1648
|
|
|
1649
|
-
|
|
1649
|
+
type avatarShape = 'round' | 'square';
|
|
1650
1650
|
interface SkeletonProps {
|
|
1651
1651
|
width: string;
|
|
1652
1652
|
height: string;
|
|
@@ -1727,7 +1727,7 @@ interface CountUpProps {
|
|
|
1727
1727
|
|
|
1728
1728
|
interface AnimatingNumbersProps {
|
|
1729
1729
|
}
|
|
1730
|
-
|
|
1730
|
+
type AnimatingNumbersStates = {};
|
|
1731
1731
|
declare class AnimatingNumbers extends Component<AnimatingNumbersProps, AnimatingNumbersStates> {
|
|
1732
1732
|
static defaultProps: AnimatingNumbersProps;
|
|
1733
1733
|
static displayName: string;
|
|
@@ -1744,7 +1744,7 @@ interface EmptyProps {
|
|
|
1744
1744
|
}
|
|
1745
1745
|
declare const Empty: FunctionComponent<Partial<EmptyProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
1746
1746
|
|
|
1747
|
-
|
|
1747
|
+
type Data = any;
|
|
1748
1748
|
interface BasicVirtualListProps {
|
|
1749
1749
|
className?: string;
|
|
1750
1750
|
style?: React.CSSProperties;
|
|
@@ -1763,7 +1763,7 @@ interface BasicVirtualListProps {
|
|
|
1763
1763
|
};
|
|
1764
1764
|
}
|
|
1765
1765
|
|
|
1766
|
-
|
|
1766
|
+
type VirtualListProps = BasicVirtualListProps;
|
|
1767
1767
|
declare const VirtualList: FunctionComponent<VirtualListProps & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
1768
1768
|
|
|
1769
1769
|
interface BasicTableProps extends BasicComponent {
|
|
@@ -1785,7 +1785,7 @@ interface TableColumnProps {
|
|
|
1785
1785
|
render?: (rowData?: any, rowIndex?: number) => string | React__default.ReactNode;
|
|
1786
1786
|
}
|
|
1787
1787
|
|
|
1788
|
-
|
|
1788
|
+
type TableProps = BasicTableProps;
|
|
1789
1789
|
declare const Table: FunctionComponent<Partial<TableProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
1790
1790
|
|
|
1791
1791
|
interface VideoProps$1 {
|
|
@@ -1812,8 +1812,8 @@ interface VideoProps$1 {
|
|
|
1812
1812
|
}
|
|
1813
1813
|
declare const Video: FunctionComponent<Partial<VideoProps$1> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
1814
1814
|
|
|
1815
|
-
|
|
1816
|
-
|
|
1815
|
+
type ProgressSize = 'small' | 'base' | 'large';
|
|
1816
|
+
type TextType = 'icon' | 'text';
|
|
1817
1817
|
interface ProgressProps extends BasicComponent {
|
|
1818
1818
|
className: string;
|
|
1819
1819
|
style: CSSProperties;
|
|
@@ -1920,8 +1920,8 @@ interface WaterMarkProps {
|
|
|
1920
1920
|
}
|
|
1921
1921
|
declare const WaterMark: FunctionComponent<Partial<WaterMarkProps> & React__default.HTMLAttributes<HTMLDivElement>>;
|
|
1922
1922
|
|
|
1923
|
-
|
|
1924
|
-
|
|
1923
|
+
type AnimateType = 'shake' | 'ripple' | 'breath' | 'float' | 'slide-right' | 'slide-left' | 'slide-top' | 'slide-bottom' | 'jump' | 'twinkle' | 'flicker';
|
|
1924
|
+
type AnimateAction = 'initial' | 'click';
|
|
1925
1925
|
|
|
1926
1926
|
interface AnimateProps {
|
|
1927
1927
|
type: AnimateType;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nutui/nutui-react-taro",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.1",
|
|
4
4
|
"style": "dist/style.css",
|
|
5
5
|
"main": "dist/nutui.react.umd.js",
|
|
6
6
|
"module": "dist/esm/nutui-react.es.js",
|
|
@@ -163,6 +163,7 @@
|
|
|
163
163
|
"react-color": "^2.19.3",
|
|
164
164
|
"react-dom": "^18.2.0",
|
|
165
165
|
"react-markdown": "^7.1.2",
|
|
166
|
+
"react-router-dom": "^5.3.4",
|
|
166
167
|
"react-syntax-highlighter": "^15.4.5",
|
|
167
168
|
"react-test-renderer": "^18.2.0",
|
|
168
169
|
"reactcss": "^1.2.3",
|