@douyinfe/semi-ui 2.50.0 → 2.51.0-beta.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/css/semi.css +173 -0
- package/dist/css/semi.min.css +1 -1
- package/dist/umd/semi-ui.js +81 -64
- package/dist/umd/semi-ui.js.map +1 -1
- package/dist/umd/semi-ui.min.js +1 -1
- package/dist/umd/semi-ui.min.js.map +1 -1
- package/lib/cjs/cascader/index.d.ts +1 -1
- package/lib/cjs/cascader/index.js +16 -28
- package/lib/cjs/dropdown/dropdownItem.js +1 -1
- package/lib/cjs/image/image.d.ts +1 -0
- package/lib/cjs/image/image.js +6 -1
- package/lib/cjs/image/interface.d.ts +6 -0
- package/lib/cjs/image/preview.d.ts +3 -0
- package/lib/cjs/image/preview.js +10 -2
- package/lib/cjs/image/previewHeader.js +3 -2
- package/lib/cjs/image/previewInner.d.ts +1 -1
- package/lib/cjs/image/previewInner.js +5 -6
- package/lib/cjs/tree/treeNode.js +1 -0
- package/lib/es/cascader/index.d.ts +1 -1
- package/lib/es/cascader/index.js +17 -29
- package/lib/es/dropdown/dropdownItem.js +1 -1
- package/lib/es/image/image.d.ts +1 -0
- package/lib/es/image/image.js +6 -1
- package/lib/es/image/interface.d.ts +6 -0
- package/lib/es/image/preview.d.ts +3 -0
- package/lib/es/image/preview.js +10 -2
- package/lib/es/image/previewHeader.js +3 -2
- package/lib/es/image/previewInner.d.ts +1 -1
- package/lib/es/image/previewInner.js +5 -6
- package/lib/es/tree/treeNode.js +1 -0
- package/package.json +8 -8
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import BaseComponent from "../_base/baseComponent";
|
|
3
|
-
import {
|
|
3
|
+
import { PreviewInnerProps, PreviewInnerStates } from "./interface";
|
|
4
4
|
import PropTypes from "prop-types";
|
|
5
5
|
import PreviewInnerFoundation, { PreviewInnerAdapter, RatioType } from '@douyinfe/semi-foundation/lib/es/image/previewInnerFoundation';
|
|
6
6
|
import { PreviewContextProps } from "./previewContext";
|
|
@@ -263,6 +263,7 @@ export default class PreviewInner extends BaseComponent {
|
|
|
263
263
|
render() {
|
|
264
264
|
const {
|
|
265
265
|
getPopupContainer,
|
|
266
|
+
closable,
|
|
266
267
|
zIndex,
|
|
267
268
|
visible,
|
|
268
269
|
className,
|
|
@@ -309,13 +310,10 @@ export default class PreviewInner extends BaseComponent {
|
|
|
309
310
|
const total = imgSrc.length;
|
|
310
311
|
const showPrev = total !== 1 && (infinite || currentIndex !== 0);
|
|
311
312
|
const showNext = total !== 1 && (infinite || currentIndex !== total - 1);
|
|
312
|
-
return /*#__PURE__*/React.createElement(Portal, {
|
|
313
|
+
return visible && /*#__PURE__*/React.createElement(Portal, {
|
|
313
314
|
getPopupContainer: getPopupContainer,
|
|
314
315
|
style: wrapperStyle
|
|
315
|
-
},
|
|
316
|
-
/*#__PURE__*/
|
|
317
|
-
// eslint-disable-next-line jsx-a11y/mouse-events-have-key-events,jsx-a11y/no-static-element-interactions
|
|
318
|
-
React.createElement("div", {
|
|
316
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
319
317
|
className: previewWrapperCls,
|
|
320
318
|
style: style,
|
|
321
319
|
onMouseDown: this.handleMouseDown,
|
|
@@ -326,7 +324,8 @@ export default class PreviewInner extends BaseComponent {
|
|
|
326
324
|
ref: this.headerRef,
|
|
327
325
|
className: cls(hideViewerCls),
|
|
328
326
|
onClose: this.handlePreviewClose,
|
|
329
|
-
renderHeader: renderHeader
|
|
327
|
+
renderHeader: renderHeader,
|
|
328
|
+
closable: closable
|
|
330
329
|
}), /*#__PURE__*/React.createElement(PreviewImage, {
|
|
331
330
|
src: imgSrc[currentIndex],
|
|
332
331
|
onZoom: this.handleZoomImage,
|
package/lib/es/tree/treeNode.js
CHANGED
|
@@ -373,6 +373,7 @@ export default class TreeNode extends PureComponent {
|
|
|
373
373
|
const dragOverGapBottom = dragOverNodeKey === eventKey && dropPosition === 1;
|
|
374
374
|
const nodeCls = cls(prefixcls, {
|
|
375
375
|
[`${prefixcls}-level-${level + 1}`]: true,
|
|
376
|
+
[`${prefixcls}-fullLabel-level-${level + 1}`]: renderFullLabel,
|
|
376
377
|
[`${prefixcls}-collapsed`]: !expanded,
|
|
377
378
|
[`${prefixcls}-disabled`]: Boolean(disabled),
|
|
378
379
|
[`${prefixcls}-selected`]: selected,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@douyinfe/semi-ui",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.51.0-beta.0",
|
|
4
4
|
"description": "A modern, comprehensive, flexible design system and UI library. Connect DesignOps & DevOps. Quickly build beautiful React apps. Maintained by Douyin-fe team.",
|
|
5
5
|
"main": "lib/cjs/index.js",
|
|
6
6
|
"module": "lib/es/index.js",
|
|
@@ -20,12 +20,12 @@
|
|
|
20
20
|
"@dnd-kit/core": "^6.0.8",
|
|
21
21
|
"@dnd-kit/sortable": "^7.0.2",
|
|
22
22
|
"@dnd-kit/utilities": "^3.2.1",
|
|
23
|
-
"@douyinfe/semi-animation": "2.
|
|
24
|
-
"@douyinfe/semi-animation-react": "2.
|
|
25
|
-
"@douyinfe/semi-foundation": "2.
|
|
26
|
-
"@douyinfe/semi-icons": "2.
|
|
27
|
-
"@douyinfe/semi-illustrations": "2.
|
|
28
|
-
"@douyinfe/semi-theme-default": "2.
|
|
23
|
+
"@douyinfe/semi-animation": "2.51.0-beta.0",
|
|
24
|
+
"@douyinfe/semi-animation-react": "2.51.0-beta.0",
|
|
25
|
+
"@douyinfe/semi-foundation": "2.51.0-beta.0",
|
|
26
|
+
"@douyinfe/semi-icons": "2.51.0-beta.0",
|
|
27
|
+
"@douyinfe/semi-illustrations": "2.51.0-beta.0",
|
|
28
|
+
"@douyinfe/semi-theme-default": "2.51.0-beta.0",
|
|
29
29
|
"async-validator": "^3.5.0",
|
|
30
30
|
"classnames": "^2.2.6",
|
|
31
31
|
"copy-text-to-clipboard": "^2.1.1",
|
|
@@ -75,7 +75,7 @@
|
|
|
75
75
|
],
|
|
76
76
|
"author": "",
|
|
77
77
|
"license": "MIT",
|
|
78
|
-
"gitHead": "
|
|
78
|
+
"gitHead": "35dcd5c5793fbe9c564eeac62486a402b84f4075",
|
|
79
79
|
"devDependencies": {
|
|
80
80
|
"@babel/plugin-proposal-decorators": "^7.15.8",
|
|
81
81
|
"@babel/plugin-transform-runtime": "^7.15.8",
|