@douyinfe/semi-ui 2.38.1 → 2.38.2-alpha.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.
@@ -138,7 +138,7 @@ declare class Form<Values extends Record<string, any> = any> extends BaseCompone
138
138
  preventScroll?: boolean;
139
139
  showRestTagsPopover?: boolean;
140
140
  restTagsPopoverProps?: import("../popover").PopoverProps;
141
- } & Pick<import("../tooltip").TooltipProps, "stopPropagation" | "motion" | "getPopupContainer" | "spacing" | "mouseEnterDelay" | "autoAdjustOverflow" | "mouseLeaveDelay"> & React.RefAttributes<any> & import("./interface").CommonFieldProps, import("./interface").CommonexcludeType>> & import("./interface").SelectStatic;
141
+ } & Pick<import("../tooltip").TooltipProps, "stopPropagation" | "motion" | "spacing" | "mouseEnterDelay" | "autoAdjustOverflow" | "mouseLeaveDelay" | "getPopupContainer"> & React.RefAttributes<any> & import("./interface").CommonFieldProps, import("./interface").CommonexcludeType>> & import("./interface").SelectStatic;
142
142
  static Checkbox: React.ComponentType<import("utility-types").Subtract<import("./interface").CommonFieldProps, import("./interface").RadioCheckboxExcludeProps> & import("../checkbox").CheckboxProps & import("./interface").RCIncludeType>;
143
143
  static CheckboxGroup: React.ComponentType<import("utility-types").Subtract<import("../checkbox").CheckboxGroupProps, import("./interface").CommonexcludeType> & import("./interface").CommonFieldProps & React.RefAttributes<any>>;
144
144
  static Radio: React.ComponentType<import("utility-types").Subtract<import("./interface").CommonFieldProps, import("./interface").RadioCheckboxExcludeProps> & import("../radio").RadioProps & import("./interface").RCIncludeType>;
@@ -86,7 +86,7 @@ declare const FormSelect: import("react").ComponentType<import("utility-types").
86
86
  preventScroll?: boolean;
87
87
  showRestTagsPopover?: boolean;
88
88
  restTagsPopoverProps?: import("../popover").PopoverProps;
89
- } & Pick<import("../tooltip").TooltipProps, "stopPropagation" | "motion" | "getPopupContainer" | "spacing" | "mouseEnterDelay" | "autoAdjustOverflow" | "mouseLeaveDelay"> & import("react").RefAttributes<any> & import("./interface").CommonFieldProps, import("./interface").CommonexcludeType>> & import("./interface").SelectStatic;
89
+ } & Pick<import("../tooltip").TooltipProps, "stopPropagation" | "motion" | "spacing" | "mouseEnterDelay" | "autoAdjustOverflow" | "mouseLeaveDelay" | "getPopupContainer"> & import("react").RefAttributes<any> & import("./interface").CommonFieldProps, import("./interface").CommonexcludeType>> & import("./interface").SelectStatic;
90
90
  declare const FormCheckboxGroup: import("react").ComponentType<import("utility-types").Subtract<import("../checkbox/checkboxGroup").CheckboxGroupProps, import("./interface").CommonexcludeType> & import("./interface").CommonFieldProps & import("react").RefAttributes<any>>;
91
91
  declare const FormCheckbox: import("react").ComponentType<import("utility-types").Subtract<import("./interface").CommonFieldProps, import("./interface").RadioCheckboxExcludeProps> & import("../checkbox/checkbox").CheckboxProps & import("./interface").RCIncludeType>;
92
92
  declare const FormRadioGroup: import("react").ComponentType<import("utility-types").Subtract<import("../radio/radioGroup").RadioGroupProps, import("./interface").CommonexcludeType> & import("./interface").CommonFieldProps & import("react").RefAttributes<any>>;
@@ -130,7 +130,7 @@ class TextArea extends _baseComponent.default {
130
130
  this._resizeListener && window.removeEventListener('resize', this._resizeListener);
131
131
  }
132
132
  componentDidUpdate(prevProps, prevState) {
133
- if (this.props.value !== prevProps.value && this.props.autosize) {
133
+ if ((this.props.value !== prevProps.value || this.props.placeholder !== prevProps.placeholder) && this.props.autosize) {
134
134
  this.foundation.resizeTextarea();
135
135
  }
136
136
  }
@@ -146,20 +146,20 @@ export declare function withError(props: ModalReactProps): {
146
146
  style?: React.CSSProperties;
147
147
  className?: string;
148
148
  motion?: boolean;
149
- getPopupContainer?: () => HTMLElement;
150
- footer?: React.ReactNode;
151
- header?: React.ReactNode;
152
- direction?: any;
153
149
  width?: string | number;
154
150
  height?: string | number;
151
+ footer?: React.ReactNode;
152
+ header?: React.ReactNode;
155
153
  mask?: boolean;
156
154
  visible?: boolean;
157
155
  content?: React.ReactNode;
158
156
  icon: string | number | boolean | React.ReactFragment | JSX.Element;
159
157
  onCancel?: (e: React.MouseEvent<Element, MouseEvent>) => void | Promise<any>;
158
+ direction?: any;
160
159
  zIndex?: number;
161
160
  closeOnEsc?: boolean;
162
161
  preventScroll?: boolean;
162
+ getPopupContainer?: () => HTMLElement;
163
163
  afterClose?: () => void;
164
164
  keepDOM?: boolean;
165
165
  cancelText?: string;
@@ -503,7 +503,7 @@ class Body extends _baseComponent.default {
503
503
  if (props.virtualized) {
504
504
  getVirtualizedListRef(this.listRef);
505
505
  } else {
506
- console.warn('getVirtualizedListRef only works with virtualized. ' + 'See https://semi.design/zh-CN/show/table for more information.');
506
+ console.warn('getVirtualizedListRef only works with virtualized. ' + 'See https://semi.design/en-US/show/table for more information.');
507
507
  }
508
508
  }
509
509
  this.foundation = new _bodyFoundation.default(this.adapter);
@@ -537,6 +537,13 @@ class Tooltip extends _baseComponent.default {
537
537
  this.setState({
538
538
  id: (0, _uuid.getUuidShort)()
539
539
  });
540
+ },
541
+ getTriggerDOM: () => {
542
+ if (this.triggerEl.current) {
543
+ return _reactDom.default.findDOMNode(this.triggerEl.current);
544
+ } else {
545
+ return null;
546
+ }
540
547
  }
541
548
  });
542
549
  }
@@ -138,7 +138,7 @@ declare class Form<Values extends Record<string, any> = any> extends BaseCompone
138
138
  preventScroll?: boolean;
139
139
  showRestTagsPopover?: boolean;
140
140
  restTagsPopoverProps?: import("../popover").PopoverProps;
141
- } & Pick<import("../tooltip").TooltipProps, "stopPropagation" | "motion" | "getPopupContainer" | "spacing" | "mouseEnterDelay" | "autoAdjustOverflow" | "mouseLeaveDelay"> & React.RefAttributes<any> & import("./interface").CommonFieldProps, import("./interface").CommonexcludeType>> & import("./interface").SelectStatic;
141
+ } & Pick<import("../tooltip").TooltipProps, "stopPropagation" | "motion" | "spacing" | "mouseEnterDelay" | "autoAdjustOverflow" | "mouseLeaveDelay" | "getPopupContainer"> & React.RefAttributes<any> & import("./interface").CommonFieldProps, import("./interface").CommonexcludeType>> & import("./interface").SelectStatic;
142
142
  static Checkbox: React.ComponentType<import("utility-types").Subtract<import("./interface").CommonFieldProps, import("./interface").RadioCheckboxExcludeProps> & import("../checkbox").CheckboxProps & import("./interface").RCIncludeType>;
143
143
  static CheckboxGroup: React.ComponentType<import("utility-types").Subtract<import("../checkbox").CheckboxGroupProps, import("./interface").CommonexcludeType> & import("./interface").CommonFieldProps & React.RefAttributes<any>>;
144
144
  static Radio: React.ComponentType<import("utility-types").Subtract<import("./interface").CommonFieldProps, import("./interface").RadioCheckboxExcludeProps> & import("../radio").RadioProps & import("./interface").RCIncludeType>;
@@ -86,7 +86,7 @@ declare const FormSelect: import("react").ComponentType<import("utility-types").
86
86
  preventScroll?: boolean;
87
87
  showRestTagsPopover?: boolean;
88
88
  restTagsPopoverProps?: import("../popover").PopoverProps;
89
- } & Pick<import("../tooltip").TooltipProps, "stopPropagation" | "motion" | "getPopupContainer" | "spacing" | "mouseEnterDelay" | "autoAdjustOverflow" | "mouseLeaveDelay"> & import("react").RefAttributes<any> & import("./interface").CommonFieldProps, import("./interface").CommonexcludeType>> & import("./interface").SelectStatic;
89
+ } & Pick<import("../tooltip").TooltipProps, "stopPropagation" | "motion" | "spacing" | "mouseEnterDelay" | "autoAdjustOverflow" | "mouseLeaveDelay" | "getPopupContainer"> & import("react").RefAttributes<any> & import("./interface").CommonFieldProps, import("./interface").CommonexcludeType>> & import("./interface").SelectStatic;
90
90
  declare const FormCheckboxGroup: import("react").ComponentType<import("utility-types").Subtract<import("../checkbox/checkboxGroup").CheckboxGroupProps, import("./interface").CommonexcludeType> & import("./interface").CommonFieldProps & import("react").RefAttributes<any>>;
91
91
  declare const FormCheckbox: import("react").ComponentType<import("utility-types").Subtract<import("./interface").CommonFieldProps, import("./interface").RadioCheckboxExcludeProps> & import("../checkbox/checkbox").CheckboxProps & import("./interface").RCIncludeType>;
92
92
  declare const FormRadioGroup: import("react").ComponentType<import("utility-types").Subtract<import("../radio/radioGroup").RadioGroupProps, import("./interface").CommonexcludeType> & import("./interface").CommonFieldProps & import("react").RefAttributes<any>>;
@@ -122,7 +122,7 @@ class TextArea extends BaseComponent {
122
122
  this._resizeListener && window.removeEventListener('resize', this._resizeListener);
123
123
  }
124
124
  componentDidUpdate(prevProps, prevState) {
125
- if (this.props.value !== prevProps.value && this.props.autosize) {
125
+ if ((this.props.value !== prevProps.value || this.props.placeholder !== prevProps.placeholder) && this.props.autosize) {
126
126
  this.foundation.resizeTextarea();
127
127
  }
128
128
  }
@@ -146,20 +146,20 @@ export declare function withError(props: ModalReactProps): {
146
146
  style?: React.CSSProperties;
147
147
  className?: string;
148
148
  motion?: boolean;
149
- getPopupContainer?: () => HTMLElement;
150
- footer?: React.ReactNode;
151
- header?: React.ReactNode;
152
- direction?: any;
153
149
  width?: string | number;
154
150
  height?: string | number;
151
+ footer?: React.ReactNode;
152
+ header?: React.ReactNode;
155
153
  mask?: boolean;
156
154
  visible?: boolean;
157
155
  content?: React.ReactNode;
158
156
  icon: string | number | boolean | React.ReactFragment | JSX.Element;
159
157
  onCancel?: (e: React.MouseEvent<Element, MouseEvent>) => void | Promise<any>;
158
+ direction?: any;
160
159
  zIndex?: number;
161
160
  closeOnEsc?: boolean;
162
161
  preventScroll?: boolean;
162
+ getPopupContainer?: () => HTMLElement;
163
163
  afterClose?: () => void;
164
164
  keepDOM?: boolean;
165
165
  cancelText?: string;
@@ -496,7 +496,7 @@ class Body extends BaseComponent {
496
496
  if (props.virtualized) {
497
497
  getVirtualizedListRef(this.listRef);
498
498
  } else {
499
- console.warn('getVirtualizedListRef only works with virtualized. ' + 'See https://semi.design/zh-CN/show/table for more information.');
499
+ console.warn('getVirtualizedListRef only works with virtualized. ' + 'See https://semi.design/en-US/show/table for more information.');
500
500
  }
501
501
  }
502
502
  this.foundation = new BodyFoundation(this.adapter);
@@ -527,6 +527,13 @@ export default class Tooltip extends BaseComponent {
527
527
  this.setState({
528
528
  id: getUuidShort()
529
529
  });
530
+ },
531
+ getTriggerDOM: () => {
532
+ if (this.triggerEl.current) {
533
+ return ReactDOM.findDOMNode(this.triggerEl.current);
534
+ } else {
535
+ return null;
536
+ }
530
537
  }
531
538
  });
532
539
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@douyinfe/semi-ui",
3
- "version": "2.38.1",
3
+ "version": "2.38.2-alpha.2",
4
4
  "description": "",
5
5
  "main": "lib/cjs/index.js",
6
6
  "module": "lib/es/index.js",
@@ -17,12 +17,12 @@
17
17
  "lib/*"
18
18
  ],
19
19
  "dependencies": {
20
- "@douyinfe/semi-animation": "2.38.1",
21
- "@douyinfe/semi-animation-react": "2.38.1",
22
- "@douyinfe/semi-foundation": "2.38.1",
23
- "@douyinfe/semi-icons": "2.38.1",
24
- "@douyinfe/semi-illustrations": "2.38.1",
25
- "@douyinfe/semi-theme-default": "2.38.1",
20
+ "@douyinfe/semi-animation": "2.38.2-alpha.2",
21
+ "@douyinfe/semi-animation-react": "2.38.2-alpha.2",
22
+ "@douyinfe/semi-foundation": "2.38.2-alpha.2",
23
+ "@douyinfe/semi-icons": "2.38.2-alpha.2",
24
+ "@douyinfe/semi-illustrations": "2.38.2-alpha.2",
25
+ "@douyinfe/semi-theme-default": "2.38.2-alpha.2",
26
26
  "async-validator": "^3.5.0",
27
27
  "classnames": "^2.2.6",
28
28
  "copy-text-to-clipboard": "^2.1.1",
@@ -69,7 +69,7 @@
69
69
  ],
70
70
  "author": "",
71
71
  "license": "MIT",
72
- "gitHead": "aaad3c86114e9bd2d9a61c8b78260e18ffc0eec6",
72
+ "gitHead": "8fb732d3d44b16a0bda607843c72b625bd7929af",
73
73
  "devDependencies": {
74
74
  "@babel/plugin-proposal-decorators": "^7.15.8",
75
75
  "@babel/plugin-transform-runtime": "^7.15.8",