@douyinfe/semi-ui 2.20.6 → 2.20.8

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.
@@ -10,7 +10,7 @@ import { CheckboxProps } from '../checkbox/index';
10
10
  import { RadioProps } from '../radio/index';
11
11
  import { ReactFieldError as FieldError } from './errorMessage';
12
12
  import { LabelProps } from './label';
13
- export { FormState, FormApi, WithFieldOption };
13
+ export { FormState, FormApi, WithFieldOption, RuleItem };
14
14
  export declare type CommonFieldProps = {
15
15
  /** Field is required (except Form. Checkbox within the Group, Form. Radio) */
16
16
  field: string;
@@ -4,6 +4,7 @@ import { ImageProps, ImageStates } from "./interface";
4
4
  import PropTypes from "prop-types";
5
5
  import { PreviewContextProps } from "./previewContext";
6
6
  import ImageFoundation, { ImageAdapter } from '@douyinfe/semi-foundation/lib/cjs/image/imageFoundation';
7
+ import '@douyinfe/semi-foundation/lib/cjs/image/image.css';
7
8
  export default class Image extends BaseComponent<ImageProps, ImageStates> {
8
9
  static isSemiImage: boolean;
9
10
  static contextType: React.Context<PreviewContextProps>;
@@ -29,6 +29,8 @@ var _localeConsumer = _interopRequireDefault(require("../locale/localeConsumer")
29
29
 
30
30
  var _skeleton = _interopRequireDefault(require("../skeleton"));
31
31
 
32
+ require("@douyinfe/semi-foundation/lib/cjs/image/image.css");
33
+
32
34
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
33
35
 
34
36
  /* eslint-disable jsx-a11y/click-events-have-key-events */
@@ -4,6 +4,7 @@ import PropTypes from "prop-types";
4
4
  import { PreviewProps, PreviewState } from "./interface";
5
5
  import PreviewInner from "./previewInner";
6
6
  import PreviewFoundation from '@douyinfe/semi-foundation/lib/cjs/image/previewFoundation';
7
+ import '@douyinfe/semi-foundation/lib/cjs/image/image.css';
7
8
  export default class Preview extends BaseComponent<PreviewProps, PreviewState> {
8
9
  static propTypes: {
9
10
  style: PropTypes.Requireable<object>;
@@ -23,6 +23,8 @@ var _uuid = require("@douyinfe/semi-foundation/lib/cjs/utils/uuid");
23
23
 
24
24
  var _constants = require("@douyinfe/semi-foundation/lib/cjs/image/constants");
25
25
 
26
+ require("@douyinfe/semi-foundation/lib/cjs/image/image.css");
27
+
26
28
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
27
29
 
28
30
  var __rest = void 0 && (void 0).__rest || function (s, e) {
@@ -6,9 +6,9 @@ import BaseComponent, { ValidateStatus } from '../_base/baseComponent';
6
6
  import { InputProps } from '../input/index';
7
7
  import Option, { OptionProps } from './option';
8
8
  import OptionGroup from './optionGroup';
9
- import { Subtract } from 'utility-types';
10
9
  import '@douyinfe/semi-foundation/lib/cjs/select/select.css';
11
- import { Position, TooltipProps } from '../tooltip';
10
+ import type { Position, TooltipProps } from '../tooltip';
11
+ import type { Subtract } from 'utility-types';
12
12
  export type { OptionProps } from './option';
13
13
  export type { OptionGroupProps } from './optionGroup';
14
14
  export type { VirtualRowProps } from './virtualRow';
@@ -679,7 +679,7 @@ class Select extends _baseComponent.default {
679
679
  // eslint-disable-next-line jsx-a11y/no-static-element-interactions
680
680
  _react.default.createElement("div", {
681
681
  id: "".concat(prefixcls, "-").concat(this.selectOptionListID),
682
- className: dropdownClassName,
682
+ className: (0, _classnames.default)("".concat(prefixcls, "-option-list-wrapper"), dropdownClassName),
683
683
  style: style,
684
684
  ref: this.setOptionContainerEl,
685
685
  onKeyDown: e => this.foundation.handleContainerKeyDown(e)
@@ -1190,7 +1190,7 @@ Select.defaultProps = {
1190
1190
  onBlur: _noop2.default,
1191
1191
  onClear: _noop2.default,
1192
1192
  onListScroll: _noop2.default,
1193
- maxHeight: 300,
1193
+ maxHeight: _constants.numbers.LIST_HEIGHT,
1194
1194
  dropdownMatchSelectWidth: true,
1195
1195
  defaultActiveFirstOption: true,
1196
1196
  showArrow: true,
@@ -10,7 +10,7 @@ import { CheckboxProps } from '../checkbox/index';
10
10
  import { RadioProps } from '../radio/index';
11
11
  import { ReactFieldError as FieldError } from './errorMessage';
12
12
  import { LabelProps } from './label';
13
- export { FormState, FormApi, WithFieldOption };
13
+ export { FormState, FormApi, WithFieldOption, RuleItem };
14
14
  export declare type CommonFieldProps = {
15
15
  /** Field is required (except Form. Checkbox within the Group, Form. Radio) */
16
16
  field: string;
@@ -4,6 +4,7 @@ import { ImageProps, ImageStates } from "./interface";
4
4
  import PropTypes from "prop-types";
5
5
  import { PreviewContextProps } from "./previewContext";
6
6
  import ImageFoundation, { ImageAdapter } from '@douyinfe/semi-foundation/lib/es/image/imageFoundation';
7
+ import '@douyinfe/semi-foundation/lib/es/image/image.css';
7
8
  export default class Image extends BaseComponent<ImageProps, ImageStates> {
8
9
  static isSemiImage: boolean;
9
10
  static contextType: React.Context<PreviewContextProps>;
@@ -14,6 +14,7 @@ import { PreviewContext } from "./previewContext";
14
14
  import ImageFoundation from '@douyinfe/semi-foundation/lib/es/image/imageFoundation';
15
15
  import LocaleConsumer from "../locale/localeConsumer";
16
16
  import Skeleton from "../skeleton";
17
+ import '@douyinfe/semi-foundation/lib/es/image/image.css';
17
18
  const prefixCls = cssClasses.PREFIX;
18
19
  export default class Image extends BaseComponent {
19
20
  constructor(props) {
@@ -4,6 +4,7 @@ import PropTypes from "prop-types";
4
4
  import { PreviewProps, PreviewState } from "./interface";
5
5
  import PreviewInner from "./previewInner";
6
6
  import PreviewFoundation from '@douyinfe/semi-foundation/lib/es/image/previewFoundation';
7
+ import '@douyinfe/semi-foundation/lib/es/image/image.css';
7
8
  export default class Preview extends BaseComponent<PreviewProps, PreviewState> {
8
9
  static propTypes: {
9
10
  style: PropTypes.Requireable<object>;
@@ -19,6 +19,7 @@ import PreviewInner from "./previewInner";
19
19
  import PreviewFoundation from '@douyinfe/semi-foundation/lib/es/image/previewFoundation';
20
20
  import { getUuidShort } from '@douyinfe/semi-foundation/lib/es/utils/uuid';
21
21
  import { cssClasses } from '@douyinfe/semi-foundation/lib/es/image/constants';
22
+ import '@douyinfe/semi-foundation/lib/es/image/image.css';
22
23
  const prefixCls = cssClasses.PREFIX;
23
24
  export default class Preview extends BaseComponent {
24
25
  constructor(props) {
@@ -6,9 +6,9 @@ import BaseComponent, { ValidateStatus } from '../_base/baseComponent';
6
6
  import { InputProps } from '../input/index';
7
7
  import Option, { OptionProps } from './option';
8
8
  import OptionGroup from './optionGroup';
9
- import { Subtract } from 'utility-types';
10
9
  import '@douyinfe/semi-foundation/lib/es/select/select.css';
11
- import { Position, TooltipProps } from '../tooltip';
10
+ import type { Position, TooltipProps } from '../tooltip';
11
+ import type { Subtract } from 'utility-types';
12
12
  export type { OptionProps } from './option';
13
13
  export type { OptionGroupProps } from './optionGroup';
14
14
  export type { VirtualRowProps } from './virtualRow';
@@ -633,7 +633,7 @@ class Select extends BaseComponent {
633
633
  // eslint-disable-next-line jsx-a11y/no-static-element-interactions
634
634
  React.createElement("div", {
635
635
  id: "".concat(prefixcls, "-").concat(this.selectOptionListID),
636
- className: dropdownClassName,
636
+ className: cls("".concat(prefixcls, "-option-list-wrapper"), dropdownClassName),
637
637
  style: style,
638
638
  ref: this.setOptionContainerEl,
639
639
  onKeyDown: e => this.foundation.handleContainerKeyDown(e)
@@ -1145,7 +1145,7 @@ Select.defaultProps = {
1145
1145
  onBlur: _noop,
1146
1146
  onClear: _noop,
1147
1147
  onListScroll: _noop,
1148
- maxHeight: 300,
1148
+ maxHeight: numbers.LIST_HEIGHT,
1149
1149
  dropdownMatchSelectWidth: true,
1150
1150
  defaultActiveFirstOption: true,
1151
1151
  showArrow: true,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@douyinfe/semi-ui",
3
- "version": "2.20.6",
3
+ "version": "2.20.8",
4
4
  "description": "",
5
5
  "main": "lib/cjs/index.js",
6
6
  "module": "lib/es/index.js",
@@ -18,11 +18,11 @@
18
18
  ],
19
19
  "dependencies": {
20
20
  "@douyinfe/semi-animation": "2.12.0",
21
- "@douyinfe/semi-animation-react": "2.20.6",
22
- "@douyinfe/semi-foundation": "2.20.6",
23
- "@douyinfe/semi-icons": "2.20.6",
21
+ "@douyinfe/semi-animation-react": "2.20.8",
22
+ "@douyinfe/semi-foundation": "2.20.8",
23
+ "@douyinfe/semi-icons": "2.20.8",
24
24
  "@douyinfe/semi-illustrations": "2.15.0",
25
- "@douyinfe/semi-theme-default": "2.20.6",
25
+ "@douyinfe/semi-theme-default": "2.20.8",
26
26
  "async-validator": "^3.5.0",
27
27
  "classnames": "^2.2.6",
28
28
  "copy-text-to-clipboard": "^2.1.1",
@@ -69,13 +69,13 @@
69
69
  ],
70
70
  "author": "",
71
71
  "license": "MIT",
72
- "gitHead": "a3ff44756182c53fb1216ab4fd974edea4473bcd",
72
+ "gitHead": "9e94c35ebc88ffd1ed06cc5057ed90f94132a8f2",
73
73
  "devDependencies": {
74
74
  "@babel/plugin-proposal-decorators": "^7.15.8",
75
75
  "@babel/plugin-transform-runtime": "^7.15.8",
76
76
  "@babel/preset-env": "^7.15.8",
77
77
  "@babel/preset-react": "^7.14.5",
78
- "@douyinfe/semi-scss-compile": "2.20.6",
78
+ "@douyinfe/semi-scss-compile": "2.20.8",
79
79
  "@storybook/addon-knobs": "^6.3.1",
80
80
  "@types/lodash": "^4.14.176",
81
81
  "@types/react": ">=16.0.0",