@cuvp1225/antd 0.3.69 → 0.3.71
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/designer.js +37 -37
- package/dist/index.js +37 -37
- package/lib/cjs/components/anchor.js +2 -2
- package/lib/cjs/components/auto-complete.js +2 -2
- package/lib/cjs/components/avatar.js +2 -2
- package/lib/cjs/components/badge.js +2 -2
- package/lib/cjs/components/calendar.js +2 -2
- package/lib/cjs/components/card.js +2 -2
- package/lib/cjs/components/carousel.js +2 -2
- package/lib/cjs/components/checkbox.js +4 -3
- package/lib/cjs/components/collapse.js +2 -2
- package/lib/cjs/components/comment.js +2 -2
- package/lib/cjs/components/date-picker.js +2 -2
- package/lib/cjs/components/descriptions.js +2 -2
- package/lib/cjs/components/divider.js +2 -2
- package/lib/cjs/components/empty.js +2 -2
- package/lib/cjs/components/image.js +2 -2
- package/lib/cjs/components/mentions.js +2 -2
- package/lib/cjs/components/pageheader.js +2 -2
- package/lib/cjs/components/pagination.js +2 -2
- package/lib/cjs/components/popconfirm.js +2 -2
- package/lib/cjs/components/popover.js +2 -2
- package/lib/cjs/components/radio.js +4 -3
- package/lib/cjs/components/rate.js +2 -2
- package/lib/cjs/components/result.js +2 -2
- package/lib/cjs/components/skeleton.js +2 -2
- package/lib/cjs/components/slider.js +2 -2
- package/lib/cjs/components/spin.js +2 -2
- package/lib/cjs/components/statistic.js +2 -2
- package/lib/cjs/components/switch.js +1 -1
- package/lib/cjs/components/table.js +2 -2
- package/lib/cjs/components/tabs.js +2 -2
- package/lib/cjs/components/tag.js +2 -2
- package/lib/cjs/components/time-picker.js +2 -2
- package/lib/cjs/components/timeline.js +2 -2
- package/lib/cjs/components/tooltip.js +2 -2
- package/lib/cjs/components/transfer.js +2 -2
- package/lib/cjs/components/tree-select.js +2 -2
- package/lib/cjs/components/upload.js +2 -2
- package/lib/esm/components/anchor.js +2 -2
- package/lib/esm/components/auto-complete.js +2 -2
- package/lib/esm/components/avatar.js +2 -2
- package/lib/esm/components/badge.js +2 -2
- package/lib/esm/components/calendar.js +2 -2
- package/lib/esm/components/card.js +2 -2
- package/lib/esm/components/carousel.js +2 -2
- package/lib/esm/components/checkbox.js +4 -3
- package/lib/esm/components/collapse.js +2 -2
- package/lib/esm/components/comment.js +2 -2
- package/lib/esm/components/date-picker.js +2 -2
- package/lib/esm/components/descriptions.js +2 -2
- package/lib/esm/components/divider.js +2 -2
- package/lib/esm/components/empty.js +2 -2
- package/lib/esm/components/image.js +2 -2
- package/lib/esm/components/mentions.js +2 -2
- package/lib/esm/components/pageheader.js +2 -2
- package/lib/esm/components/pagination.js +2 -2
- package/lib/esm/components/popconfirm.js +2 -2
- package/lib/esm/components/popover.js +2 -2
- package/lib/esm/components/radio.js +4 -3
- package/lib/esm/components/rate.js +2 -2
- package/lib/esm/components/result.js +2 -2
- package/lib/esm/components/skeleton.js +2 -2
- package/lib/esm/components/slider.js +2 -2
- package/lib/esm/components/spin.js +2 -2
- package/lib/esm/components/statistic.js +2 -2
- package/lib/esm/components/switch.js +1 -1
- package/lib/esm/components/table.js +2 -2
- package/lib/esm/components/tabs.js +2 -2
- package/lib/esm/components/tag.js +2 -2
- package/lib/esm/components/time-picker.js +2 -2
- package/lib/esm/components/timeline.js +2 -2
- package/lib/esm/components/tooltip.js +2 -2
- package/lib/esm/components/transfer.js +2 -2
- package/lib/esm/components/tree-select.js +2 -2
- package/lib/esm/components/upload.js +2 -2
- package/package.json +2 -2
@@ -10,7 +10,7 @@ function TimelineDesigner(_a) {
|
|
10
10
|
var { children } = _a, _b = tango_helpers_1.SLOT.dnd, dataDnd = _a[_b], _c = tango_helpers_1.SLOT.id, dataId = _a[_c], { style } = _a, rest = tslib_1.__rest(_a, ["children", typeof _b === "symbol" ? _b : _b + "", typeof _c === "symbol" ? _c : _c + "", "style"]);
|
11
11
|
(0, react_1.useEffect)(() => {
|
12
12
|
Promise.resolve().then(() => {
|
13
|
-
const popoverNode = document.querySelector(
|
13
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
14
14
|
console.log('spinNode', popoverNode);
|
15
15
|
if (popoverNode) {
|
16
16
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -19,7 +19,7 @@ function TimelineDesigner(_a) {
|
|
19
19
|
}
|
20
20
|
});
|
21
21
|
}, [dataDnd, dataId]);
|
22
|
-
return (react_1.default.createElement(antd_1.Timeline, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children));
|
22
|
+
return (react_1.default.createElement(antd_1.Timeline, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children));
|
23
23
|
}
|
24
24
|
exports.Timeline = (0, tango_boot_1.defineComponent)(antd_1.Timeline, {
|
25
25
|
name: 'Timeline',
|
@@ -15,7 +15,7 @@ function TooltipDesigner(_a) {
|
|
15
15
|
if (visible) {
|
16
16
|
// 使用微任务确保弹层已渲染
|
17
17
|
Promise.resolve().then(() => {
|
18
|
-
const popoverNode = document.querySelector(
|
18
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
19
19
|
console.log('popoverNode', popoverNode);
|
20
20
|
if (popoverNode) {
|
21
21
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -26,7 +26,7 @@ function TooltipDesigner(_a) {
|
|
26
26
|
}
|
27
27
|
};
|
28
28
|
return (react_1.default.createElement("div", { ref: tooltipRef },
|
29
|
-
react_1.default.createElement(antd_1.Tooltip, Object.assign({ title: title, onOpenChange: handleVisibleChange }, rest), children)));
|
29
|
+
react_1.default.createElement(antd_1.Tooltip, Object.assign({ title: title, className: dataId, onOpenChange: handleVisibleChange }, rest), children)));
|
30
30
|
}
|
31
31
|
exports.Tooltip = (0, tango_boot_1.defineComponent)(antd_1.Tooltip, {
|
32
32
|
name: 'Tooltip',
|
@@ -26,7 +26,7 @@ function TransferDesigner(_a) {
|
|
26
26
|
// };
|
27
27
|
(0, react_1.useEffect)(() => {
|
28
28
|
Promise.resolve().then(() => {
|
29
|
-
const popoverNode = document.querySelector(
|
29
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
30
30
|
console.log('rate', popoverNode);
|
31
31
|
if (popoverNode) {
|
32
32
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -36,7 +36,7 @@ function TransferDesigner(_a) {
|
|
36
36
|
});
|
37
37
|
}, [dataDnd, dataId]);
|
38
38
|
return (react_1.default.createElement("div", { ref: transferRef },
|
39
|
-
react_1.default.createElement(antd_1.Transfer, Object.assign({ "data-dnd": dataDnd, "data-id": dataId }, rest))));
|
39
|
+
react_1.default.createElement(antd_1.Transfer, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId }, rest))));
|
40
40
|
}
|
41
41
|
exports.Transfer = (0, tango_boot_1.defineComponent)(antd_1.Transfer, {
|
42
42
|
name: 'Transfer',
|
@@ -11,7 +11,7 @@ function TreeSelectDesigner(_a) {
|
|
11
11
|
const treeselectRef = (0, react_1.useRef)(null);
|
12
12
|
(0, react_1.useEffect)(() => {
|
13
13
|
Promise.resolve().then(() => {
|
14
|
-
const popoverNode = document.querySelector(
|
14
|
+
const popoverNode = document.querySelector(`${dataId}`);
|
15
15
|
// console.log('spinNode', popoverNode);
|
16
16
|
if (popoverNode) {
|
17
17
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -21,7 +21,7 @@ function TreeSelectDesigner(_a) {
|
|
21
21
|
});
|
22
22
|
}, [dataDnd, dataId]);
|
23
23
|
return (react_1.default.createElement("div", { ref: treeselectRef },
|
24
|
-
react_1.default.createElement(antd_1.TreeSelect, Object.assign({ className:
|
24
|
+
react_1.default.createElement(antd_1.TreeSelect, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest))));
|
25
25
|
}
|
26
26
|
exports.TreeSelect = (0, tango_boot_1.defineComponent)(antd_1.TreeSelect, {
|
27
27
|
name: 'TreeSelect',
|
@@ -11,7 +11,7 @@ function UploadDesigner(_a) {
|
|
11
11
|
const uploadRef = (0, react_1.useRef)(null);
|
12
12
|
(0, react_1.useEffect)(() => {
|
13
13
|
Promise.resolve().then(() => {
|
14
|
-
const popoverNode = document.querySelector(
|
14
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
15
15
|
console.log('uploadNode', popoverNode);
|
16
16
|
if (popoverNode) {
|
17
17
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -35,7 +35,7 @@ function UploadDesigner(_a) {
|
|
35
35
|
// }
|
36
36
|
// };
|
37
37
|
return (react_1.default.createElement("div", { ref: uploadRef },
|
38
|
-
react_1.default.createElement(antd_1.Upload, Object.assign({ "data-dnd": dataDnd, "data-id": dataId }, rest), children)));
|
38
|
+
react_1.default.createElement(antd_1.Upload, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId }, rest), children)));
|
39
39
|
}
|
40
40
|
exports.Upload = (0, tango_boot_1.defineComponent)(antd_1.Upload, {
|
41
41
|
name: 'Upload',
|
@@ -9,7 +9,7 @@ function AnchorDesigner(_a) {
|
|
9
9
|
const anchorRef = useRef(null);
|
10
10
|
useEffect(() => {
|
11
11
|
Promise.resolve().then(() => {
|
12
|
-
const popoverNode = document.querySelector(
|
12
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
13
13
|
console.log('spinNode', popoverNode);
|
14
14
|
if (popoverNode) {
|
15
15
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -31,7 +31,7 @@ function AnchorDesigner(_a) {
|
|
31
31
|
});
|
32
32
|
};
|
33
33
|
return (React.createElement("div", { ref: anchorRef, draggable: 'true' },
|
34
|
-
React.createElement(AntAnchor, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), renderLinks(items))));
|
34
|
+
React.createElement(AntAnchor, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), renderLinks(items))));
|
35
35
|
}
|
36
36
|
export const Anchor = defineComponent(AntAnchor, {
|
37
37
|
name: 'Anchor',
|
@@ -8,7 +8,7 @@ function AutoCompleteDesigner(_a) {
|
|
8
8
|
const autocompleteRef = useRef(null);
|
9
9
|
useEffect(() => {
|
10
10
|
Promise.resolve().then(() => {
|
11
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
12
12
|
// console.log('spinNode', popoverNode);
|
13
13
|
if (popoverNode) {
|
14
14
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -18,7 +18,7 @@ function AutoCompleteDesigner(_a) {
|
|
18
18
|
});
|
19
19
|
}, [dataDnd, dataId]);
|
20
20
|
return (React.createElement("div", { ref: autocompleteRef },
|
21
|
-
React.createElement(AntAutoComplete, Object.assign({ className:
|
21
|
+
React.createElement(AntAutoComplete, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
22
22
|
}
|
23
23
|
export const AutoComplete = defineComponent(AntAutoComplete, {
|
24
24
|
name: 'AutoComplete',
|
@@ -8,7 +8,7 @@ function AvatarDesigner(_a) {
|
|
8
8
|
const avatarRef = useRef(null);
|
9
9
|
useEffect(() => {
|
10
10
|
Promise.resolve().then(() => {
|
11
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
12
12
|
// console.log('spinNode', popoverNode);
|
13
13
|
if (popoverNode) {
|
14
14
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -18,7 +18,7 @@ function AvatarDesigner(_a) {
|
|
18
18
|
});
|
19
19
|
}, [dataDnd, dataId]);
|
20
20
|
return (React.createElement("div", { ref: avatarRef },
|
21
|
-
React.createElement(AntAvatar, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
21
|
+
React.createElement(AntAvatar, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
22
22
|
}
|
23
23
|
export const Avatar = defineComponent(AntAvatar, {
|
24
24
|
name: 'Avatar',
|
@@ -8,7 +8,7 @@ function BadgeDesigner(_a) {
|
|
8
8
|
const badgeRef = useRef(null);
|
9
9
|
useEffect(() => {
|
10
10
|
Promise.resolve().then(() => {
|
11
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
12
12
|
// console.log('spinNode', popoverNode);
|
13
13
|
if (popoverNode) {
|
14
14
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -18,7 +18,7 @@ function BadgeDesigner(_a) {
|
|
18
18
|
});
|
19
19
|
}, [dataDnd, dataId]);
|
20
20
|
return (React.createElement("div", { ref: badgeRef, draggable: 'true' },
|
21
|
-
React.createElement(AntBadge, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
21
|
+
React.createElement(AntBadge, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
22
22
|
}
|
23
23
|
export const Badge = defineComponent(AntBadge, {
|
24
24
|
name: 'Badge',
|
@@ -8,7 +8,7 @@ function CalendarDesigner(_a) {
|
|
8
8
|
const calendarRef = useRef(null);
|
9
9
|
useEffect(() => {
|
10
10
|
Promise.resolve().then(() => {
|
11
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
12
12
|
console.log('spinNode', popoverNode);
|
13
13
|
if (popoverNode) {
|
14
14
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -18,7 +18,7 @@ function CalendarDesigner(_a) {
|
|
18
18
|
});
|
19
19
|
}, [dataDnd, dataId]);
|
20
20
|
return (React.createElement("div", { ref: calendarRef },
|
21
|
-
React.createElement(AntCalendar, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest))));
|
21
|
+
React.createElement(AntCalendar, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest))));
|
22
22
|
}
|
23
23
|
export const Calendar = defineComponent(AntCalendar, {
|
24
24
|
name: 'Calendar',
|
@@ -8,7 +8,7 @@ function CardDesigner(_a) {
|
|
8
8
|
const cardRef = useRef(null);
|
9
9
|
useEffect(() => {
|
10
10
|
Promise.resolve().then(() => {
|
11
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
12
12
|
// console.log('spinNode', popoverNode);
|
13
13
|
if (popoverNode) {
|
14
14
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -18,7 +18,7 @@ function CardDesigner(_a) {
|
|
18
18
|
});
|
19
19
|
}, [dataDnd, dataId]);
|
20
20
|
return (React.createElement("div", { ref: cardRef },
|
21
|
-
React.createElement(AntCard, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
21
|
+
React.createElement(AntCard, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
22
22
|
}
|
23
23
|
export const Card = defineComponent(AntCard, {
|
24
24
|
name: 'Card',
|
@@ -7,7 +7,7 @@ function CarouselDesigner(_a) {
|
|
7
7
|
var { children } = _a, _b = SLOT.dnd, dataDnd = _a[_b], _c = SLOT.id, dataId = _a[_c], { style } = _a, rest = __rest(_a, ["children", typeof _b === "symbol" ? _b : _b + "", typeof _c === "symbol" ? _c : _c + "", "style"]);
|
8
8
|
useEffect(() => {
|
9
9
|
Promise.resolve().then(() => {
|
10
|
-
const popoverNode = document.querySelector(
|
10
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
11
11
|
console.log('spinNode', popoverNode);
|
12
12
|
if (popoverNode) {
|
13
13
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -16,7 +16,7 @@ function CarouselDesigner(_a) {
|
|
16
16
|
}
|
17
17
|
});
|
18
18
|
}, [dataDnd, dataId]);
|
19
|
-
return (React.createElement(AntCarousel, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children));
|
19
|
+
return (React.createElement(AntCarousel, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children));
|
20
20
|
}
|
21
21
|
export const Carousel = defineComponent(AntCarousel, {
|
22
22
|
name: 'Carousel',
|
@@ -1,13 +1,14 @@
|
|
1
1
|
import { __rest } from "tslib";
|
2
2
|
import { defineComponent } from '@music163/tango-boot';
|
3
|
+
import { SLOT } from '@music163/tango-helpers';
|
3
4
|
import { Checkbox as AntCheckbox } from 'antd';
|
4
5
|
import React, { useRef, useEffect } from 'react';
|
5
6
|
function CheckboxDesigner(_a) {
|
6
|
-
var { style } = _a, rest = __rest(_a, ["style"]);
|
7
|
+
var { style } = _a, _b = SLOT.dnd, dataDnd = _a[_b], _c = SLOT.id, dataId = _a[_c], rest = __rest(_a, ["style", typeof _b === "symbol" ? _b : _b + "", typeof _c === "symbol" ? _c : _c + ""]);
|
7
8
|
const checkBoxRef = useRef(null);
|
8
9
|
useEffect(() => {
|
9
10
|
Promise.resolve().then(() => {
|
10
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
11
12
|
// console.log('spinNode', popoverNode);
|
12
13
|
if (popoverNode) {
|
13
14
|
popoverNode.setAttribute('draggable', 'true');
|
@@ -15,7 +16,7 @@ function CheckboxDesigner(_a) {
|
|
15
16
|
});
|
16
17
|
}, []);
|
17
18
|
return (React.createElement("div", { ref: checkBoxRef },
|
18
|
-
React.createElement(AntCheckbox, Object.assign({}, rest, { style: style }), rest.label)));
|
19
|
+
React.createElement(AntCheckbox, Object.assign({}, rest, { style: style, className: dataId }), rest.label)));
|
19
20
|
}
|
20
21
|
export const Checkbox = defineComponent(AntCheckbox, {
|
21
22
|
name: 'Checkbox',
|
@@ -7,7 +7,7 @@ function CollapseDesigner(_a) {
|
|
7
7
|
var { children } = _a, _b = SLOT.dnd, dataDnd = _a[_b], _c = SLOT.id, dataId = _a[_c], { style } = _a, rest = __rest(_a, ["children", typeof _b === "symbol" ? _b : _b + "", typeof _c === "symbol" ? _c : _c + "", "style"]);
|
8
8
|
useEffect(() => {
|
9
9
|
Promise.resolve().then(() => {
|
10
|
-
const popoverNode = document.querySelector(
|
10
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
11
11
|
console.log('spinNode', popoverNode);
|
12
12
|
if (popoverNode) {
|
13
13
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -16,7 +16,7 @@ function CollapseDesigner(_a) {
|
|
16
16
|
}
|
17
17
|
});
|
18
18
|
}, [dataDnd, dataId]);
|
19
|
-
return (React.createElement(AntCollapse, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children));
|
19
|
+
return (React.createElement(AntCollapse, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children));
|
20
20
|
}
|
21
21
|
export const Collapse = defineComponent(AntCollapse, {
|
22
22
|
name: 'Collapse',
|
@@ -9,7 +9,7 @@ function CommentDesigner(_a) {
|
|
9
9
|
const commentRef = useRef(null);
|
10
10
|
useEffect(() => {
|
11
11
|
Promise.resolve().then(() => {
|
12
|
-
const popoverNode = document.querySelector(
|
12
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
13
13
|
// console.log('spinNode', popoverNode);
|
14
14
|
if (popoverNode) {
|
15
15
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -19,7 +19,7 @@ function CommentDesigner(_a) {
|
|
19
19
|
});
|
20
20
|
}, [dataDnd, dataId]);
|
21
21
|
return (React.createElement("div", { ref: commentRef },
|
22
|
-
React.createElement(AntComment, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, content: content, style: style }, rest), children)));
|
22
|
+
React.createElement(AntComment, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, content: content, style: style }, rest), children)));
|
23
23
|
}
|
24
24
|
export const Comment = defineComponent(AntComment, {
|
25
25
|
name: 'Comment',
|
@@ -71,7 +71,7 @@ function DataPickerDesigner(_a) {
|
|
71
71
|
const dateRef = useRef(null);
|
72
72
|
useEffect(() => {
|
73
73
|
Promise.resolve().then(() => {
|
74
|
-
const popoverNode = document.querySelector(
|
74
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
75
75
|
console.log('spinNode', popoverNode);
|
76
76
|
if (popoverNode) {
|
77
77
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -83,7 +83,7 @@ function DataPickerDesigner(_a) {
|
|
83
83
|
return (
|
84
84
|
// <div ref={dateRef}>
|
85
85
|
React.createElement(ConfigProvider, { locale: locale },
|
86
|
-
React.createElement(AntDataPicker, Object.assign({ className:
|
86
|
+
React.createElement(AntDataPicker, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style, locale: local }, rest)))
|
87
87
|
// </div>
|
88
88
|
);
|
89
89
|
}
|
@@ -7,7 +7,7 @@ function DescriptionsDesigner(_a) {
|
|
7
7
|
var { children } = _a, _b = SLOT.dnd, dataDnd = _a[_b], _c = SLOT.id, dataId = _a[_c], { style } = _a, rest = __rest(_a, ["children", typeof _b === "symbol" ? _b : _b + "", typeof _c === "symbol" ? _c : _c + "", "style"]);
|
8
8
|
useEffect(() => {
|
9
9
|
Promise.resolve().then(() => {
|
10
|
-
const popoverNode = document.querySelector(
|
10
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
11
11
|
console.log('spinNode', popoverNode);
|
12
12
|
if (popoverNode) {
|
13
13
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -16,7 +16,7 @@ function DescriptionsDesigner(_a) {
|
|
16
16
|
}
|
17
17
|
});
|
18
18
|
}, [dataDnd, dataId]);
|
19
|
-
return (React.createElement(AntDescriptions, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children));
|
19
|
+
return (React.createElement(AntDescriptions, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children));
|
20
20
|
}
|
21
21
|
export const Descriptions = defineComponent(AntDescriptions, {
|
22
22
|
name: 'Descriptions',
|
@@ -8,7 +8,7 @@ function DividerDesigner(_a) {
|
|
8
8
|
const dividerRef = useRef(null);
|
9
9
|
useEffect(() => {
|
10
10
|
Promise.resolve().then(() => {
|
11
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
12
12
|
// console.log('spinNode', popoverNode);
|
13
13
|
if (popoverNode) {
|
14
14
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -18,7 +18,7 @@ function DividerDesigner(_a) {
|
|
18
18
|
});
|
19
19
|
}, [dataDnd, dataId]);
|
20
20
|
return (React.createElement("div", { ref: dividerRef },
|
21
|
-
React.createElement(AntDivider, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
21
|
+
React.createElement(AntDivider, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
22
22
|
}
|
23
23
|
export const Divider = defineComponent(AntDivider, {
|
24
24
|
name: 'Divider',
|
@@ -8,7 +8,7 @@ function EmptyDesigner(_a) {
|
|
8
8
|
const emptyRef = useRef(null);
|
9
9
|
useEffect(() => {
|
10
10
|
Promise.resolve().then(() => {
|
11
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
12
12
|
// console.log('spinNode', popoverNode);
|
13
13
|
if (popoverNode) {
|
14
14
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -18,7 +18,7 @@ function EmptyDesigner(_a) {
|
|
18
18
|
});
|
19
19
|
}, [dataDnd, dataId]);
|
20
20
|
return (React.createElement("div", { ref: emptyRef },
|
21
|
-
React.createElement(AntEmpty, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
21
|
+
React.createElement(AntEmpty, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
22
22
|
}
|
23
23
|
export const Empty = defineComponent(AntEmpty, {
|
24
24
|
name: 'Empty',
|
@@ -8,7 +8,7 @@ function ImageDesigner(_a) {
|
|
8
8
|
const imageRef = useRef(null);
|
9
9
|
useEffect(() => {
|
10
10
|
Promise.resolve().then(() => {
|
11
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
12
12
|
// console.log('spinNode', popoverNode);
|
13
13
|
if (popoverNode) {
|
14
14
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -18,7 +18,7 @@ function ImageDesigner(_a) {
|
|
18
18
|
});
|
19
19
|
}, [dataDnd, dataId]);
|
20
20
|
return (React.createElement("div", { ref: imageRef },
|
21
|
-
React.createElement(AntImage, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest))));
|
21
|
+
React.createElement(AntImage, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest))));
|
22
22
|
}
|
23
23
|
export const Image = defineComponent(AntImage, {
|
24
24
|
name: 'Image',
|
@@ -8,7 +8,7 @@ function MentionsDesigner(_a) {
|
|
8
8
|
const mentionsRef = useRef(null);
|
9
9
|
useEffect(() => {
|
10
10
|
Promise.resolve().then(() => {
|
11
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
12
12
|
// console.log('spinNode', popoverNode);
|
13
13
|
if (popoverNode) {
|
14
14
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -18,7 +18,7 @@ function MentionsDesigner(_a) {
|
|
18
18
|
});
|
19
19
|
}, [dataDnd, dataId]);
|
20
20
|
return (React.createElement("div", { ref: mentionsRef },
|
21
|
-
React.createElement(AntMentions, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest))));
|
21
|
+
React.createElement(AntMentions, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest))));
|
22
22
|
}
|
23
23
|
export const Mentions = defineComponent(AntMentions, {
|
24
24
|
name: 'Mentions',
|
@@ -23,7 +23,7 @@ function PageHeaderDesigner(_a) {
|
|
23
23
|
// };
|
24
24
|
useEffect(() => {
|
25
25
|
Promise.resolve().then(() => {
|
26
|
-
const popoverNode = document.querySelector(
|
26
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
27
27
|
console.log('pageHeader', popoverNode);
|
28
28
|
if (popoverNode) {
|
29
29
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -33,7 +33,7 @@ function PageHeaderDesigner(_a) {
|
|
33
33
|
});
|
34
34
|
}, [dataDnd, dataId]);
|
35
35
|
return (React.createElement("div", { ref: pageHeaderRef },
|
36
|
-
React.createElement(AntPageHeader, Object.assign({ title: title, "data-dnd": dataDnd, "data-id": dataId }, rest), children)));
|
36
|
+
React.createElement(AntPageHeader, Object.assign({ title: title, "data-dnd": dataDnd, "data-id": dataId, className: dataId }, rest), children)));
|
37
37
|
}
|
38
38
|
export const PageHeader = defineComponent(AntPageHeader, {
|
39
39
|
name: 'PageHeader',
|
@@ -8,7 +8,7 @@ function PaginationDesigner(_a) {
|
|
8
8
|
const paginationRef = useRef(null);
|
9
9
|
useEffect(() => {
|
10
10
|
Promise.resolve().then(() => {
|
11
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
12
12
|
// console.log('spinNode', popoverNode);
|
13
13
|
if (popoverNode) {
|
14
14
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -18,7 +18,7 @@ function PaginationDesigner(_a) {
|
|
18
18
|
});
|
19
19
|
}, [dataDnd, dataId]);
|
20
20
|
return (React.createElement("div", { ref: paginationRef },
|
21
|
-
React.createElement(AntPagination, Object.assign({ "data-dnd": dataDnd, "data-id": dataId, style: style }, rest))));
|
21
|
+
React.createElement(AntPagination, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest))));
|
22
22
|
}
|
23
23
|
export const Pagination = defineComponent(AntPagination, {
|
24
24
|
name: 'Pagination',
|
@@ -12,7 +12,7 @@ function PopconfirmDesigner(_a) {
|
|
12
12
|
if (visible) {
|
13
13
|
// 使用微任务确保弹层已渲染
|
14
14
|
Promise.resolve().then(() => {
|
15
|
-
const popoverNode = document.querySelector(
|
15
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
16
16
|
console.log('popoverNode', popoverNode);
|
17
17
|
if (popoverNode) {
|
18
18
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -23,7 +23,7 @@ function PopconfirmDesigner(_a) {
|
|
23
23
|
}
|
24
24
|
};
|
25
25
|
return (React.createElement("div", { ref: popconfirmRef },
|
26
|
-
React.createElement(AntPopconfirm, Object.assign({ title: title, onOpenChange: handleVisibleChange }, rest), children)));
|
26
|
+
React.createElement(AntPopconfirm, Object.assign({ className: dataId, title: title, onOpenChange: handleVisibleChange }, rest), children)));
|
27
27
|
}
|
28
28
|
export const Popconfirm = defineComponent(AntPopconfirm, {
|
29
29
|
name: 'Popconfirm',
|
@@ -12,7 +12,7 @@ function PopoverDesigner(_a) {
|
|
12
12
|
if (visible) {
|
13
13
|
// 使用微任务确保弹层已渲染
|
14
14
|
Promise.resolve().then(() => {
|
15
|
-
const popoverNode = document.querySelector(
|
15
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
16
16
|
console.log('popoverNode', popoverNode);
|
17
17
|
if (popoverNode) {
|
18
18
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -23,7 +23,7 @@ function PopoverDesigner(_a) {
|
|
23
23
|
}
|
24
24
|
};
|
25
25
|
return (React.createElement("div", { ref: popoverRef },
|
26
|
-
React.createElement(AntPopover, Object.assign({ title: title, onOpenChange: handleVisibleChange }, rest), children)));
|
26
|
+
React.createElement(AntPopover, Object.assign({ className: dataId, title: title, onOpenChange: handleVisibleChange }, rest), children)));
|
27
27
|
}
|
28
28
|
export const Popover = defineComponent(AntPopover, {
|
29
29
|
name: 'Popover',
|
@@ -1,13 +1,14 @@
|
|
1
1
|
import { __rest } from "tslib";
|
2
2
|
import { defineComponent } from '@music163/tango-boot';
|
3
|
+
import { SLOT } from '@music163/tango-helpers';
|
3
4
|
import { Radio as AntRadio } from 'antd';
|
4
5
|
import React, { useEffect } from 'react';
|
5
6
|
function RadioDesigner(_a) {
|
6
|
-
var { children, style } = _a, rest = __rest(_a, ["children", "style"]);
|
7
|
+
var { children, style } = _a, _b = SLOT.dnd, dataDnd = _a[_b], _c = SLOT.id, dataId = _a[_c], rest = __rest(_a, ["children", "style", typeof _b === "symbol" ? _b : _b + "", typeof _c === "symbol" ? _c : _c + ""]);
|
7
8
|
// const radioRef = useRef<HTMLDivElement>(null);
|
8
9
|
useEffect(() => {
|
9
10
|
Promise.resolve().then(() => {
|
10
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
11
12
|
console.log('popoverNode', popoverNode);
|
12
13
|
if (popoverNode) {
|
13
14
|
popoverNode.setAttribute('draggable', 'true');
|
@@ -22,7 +23,7 @@ function RadioDesigner(_a) {
|
|
22
23
|
// </div>
|
23
24
|
// );
|
24
25
|
// }
|
25
|
-
return (React.createElement(AntRadio, Object.assign({}, rest, { style: style }), children));
|
26
|
+
return (React.createElement(AntRadio, Object.assign({}, rest, { style: style, className: dataId }), children));
|
26
27
|
}
|
27
28
|
export const Radio = defineComponent(AntRadio, {
|
28
29
|
name: 'Radio',
|
@@ -23,7 +23,7 @@ function RateDesigner(_a) {
|
|
23
23
|
// };
|
24
24
|
useEffect(() => {
|
25
25
|
Promise.resolve().then(() => {
|
26
|
-
const popoverNode = document.querySelector(
|
26
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
27
27
|
console.log('rate', popoverNode);
|
28
28
|
if (popoverNode) {
|
29
29
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -33,7 +33,7 @@ function RateDesigner(_a) {
|
|
33
33
|
});
|
34
34
|
}, [dataDnd, dataId]);
|
35
35
|
return (React.createElement("div", { ref: rateRef },
|
36
|
-
React.createElement(AntRate, Object.assign({ "data-dnd": dataDnd, "data-id": dataId }, rest))));
|
36
|
+
React.createElement(AntRate, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId }, rest))));
|
37
37
|
}
|
38
38
|
export const Rate = defineComponent(AntRate, {
|
39
39
|
name: 'Rate',
|
@@ -8,7 +8,7 @@ function ResultDesigner(_a) {
|
|
8
8
|
const resultRef = useRef(null);
|
9
9
|
useEffect(() => {
|
10
10
|
Promise.resolve().then(() => {
|
11
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
12
12
|
console.log('popoverNode', popoverNode);
|
13
13
|
if (popoverNode) {
|
14
14
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -33,7 +33,7 @@ function ResultDesigner(_a) {
|
|
33
33
|
// }
|
34
34
|
// };
|
35
35
|
return (React.createElement("div", { ref: resultRef },
|
36
|
-
React.createElement(AntResult, Object.assign({ title: title, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
36
|
+
React.createElement(AntResult, Object.assign({ className: dataId, title: title, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
37
37
|
}
|
38
38
|
export const Result = defineComponent(AntResult, {
|
39
39
|
name: 'Result',
|
@@ -23,7 +23,7 @@ function SkeletonDesigner(_a) {
|
|
23
23
|
// };
|
24
24
|
useEffect(() => {
|
25
25
|
Promise.resolve().then(() => {
|
26
|
-
const popoverNode = document.querySelector(
|
26
|
+
const popoverNode = document.querySelector(`.${dataId}}`);
|
27
27
|
console.log('ant-skeleton', popoverNode);
|
28
28
|
if (popoverNode) {
|
29
29
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -33,7 +33,7 @@ function SkeletonDesigner(_a) {
|
|
33
33
|
});
|
34
34
|
}, [dataDnd, dataId]);
|
35
35
|
return (React.createElement("div", { ref: skeletonRef },
|
36
|
-
React.createElement(AntSkeleton, Object.assign({ "data-dnd": dataDnd, "data-id": dataId }, rest), children)));
|
36
|
+
React.createElement(AntSkeleton, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId }, rest), children)));
|
37
37
|
}
|
38
38
|
export const Skeleton = defineComponent(AntSkeleton, {
|
39
39
|
name: 'Skeleton',
|
@@ -23,7 +23,7 @@ function SliderDesigner(_a) {
|
|
23
23
|
// };
|
24
24
|
useEffect(() => {
|
25
25
|
Promise.resolve().then(() => {
|
26
|
-
const popoverNode = document.querySelector(
|
26
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
27
27
|
console.log('rate', popoverNode);
|
28
28
|
if (popoverNode) {
|
29
29
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -33,7 +33,7 @@ function SliderDesigner(_a) {
|
|
33
33
|
});
|
34
34
|
}, [dataDnd, dataId]);
|
35
35
|
return (React.createElement("div", { ref: rateRef },
|
36
|
-
React.createElement(AntSlider, Object.assign({ "data-dnd": dataDnd, "data-id": dataId }, rest))));
|
36
|
+
React.createElement(AntSlider, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId }, rest))));
|
37
37
|
}
|
38
38
|
export const Slider = defineComponent(AntSlider, {
|
39
39
|
name: 'Slider',
|
@@ -8,7 +8,7 @@ function SpinDesigner(_a) {
|
|
8
8
|
const spinRef = useRef(null);
|
9
9
|
useEffect(() => {
|
10
10
|
Promise.resolve().then(() => {
|
11
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
12
12
|
// console.log('spinNode', popoverNode);
|
13
13
|
if (popoverNode) {
|
14
14
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -18,7 +18,7 @@ function SpinDesigner(_a) {
|
|
18
18
|
});
|
19
19
|
}, [dataDnd, dataId]);
|
20
20
|
return (React.createElement("div", { ref: spinRef },
|
21
|
-
React.createElement(AntSpin, Object.assign({ spinning: spinning, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
21
|
+
React.createElement(AntSpin, Object.assign({ className: dataId, spinning: spinning, "data-dnd": dataDnd, "data-id": dataId, style: style }, rest), children)));
|
22
22
|
}
|
23
23
|
export const Spin = defineComponent(AntSpin, {
|
24
24
|
name: 'Spin',
|
@@ -23,7 +23,7 @@ function StatisticDesigner(_a) {
|
|
23
23
|
// };
|
24
24
|
useEffect(() => {
|
25
25
|
Promise.resolve().then(() => {
|
26
|
-
const popoverNode = document.querySelector(
|
26
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
27
27
|
console.log('rate', popoverNode);
|
28
28
|
if (popoverNode) {
|
29
29
|
popoverNode.setAttribute('data-dnd', dataDnd);
|
@@ -34,7 +34,7 @@ function StatisticDesigner(_a) {
|
|
34
34
|
}, [dataDnd, dataId]);
|
35
35
|
return (
|
36
36
|
// <div ref={statisticRef}>
|
37
|
-
React.createElement(AntStatistic, Object.assign({ "data-dnd": dataDnd, "data-id": dataId }, rest))
|
37
|
+
React.createElement(AntStatistic, Object.assign({ className: dataId, "data-dnd": dataDnd, "data-id": dataId }, rest))
|
38
38
|
// </div>
|
39
39
|
);
|
40
40
|
}
|
@@ -8,7 +8,7 @@ function SwitchDesigner(_a) {
|
|
8
8
|
const switchRef = useRef(null);
|
9
9
|
useEffect(() => {
|
10
10
|
Promise.resolve().then(() => {
|
11
|
-
const popoverNode = document.querySelector(
|
11
|
+
const popoverNode = document.querySelector(`.${dataId}`);
|
12
12
|
// console.log('spinNode', popoverNode);
|
13
13
|
if (popoverNode) {
|
14
14
|
popoverNode.setAttribute('data-dnd', dataDnd);
|