@next-bricks/advanced 0.42.9 → 0.43.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.
Files changed (35) hide show
  1. package/dist/bricks.json +13 -12
  2. package/dist/chunks/7157.c0454af3.js +2 -0
  3. package/dist/chunks/7157.c0454af3.js.map +1 -0
  4. package/dist/chunks/eo-cascader.12cb6d0c.js +2 -0
  5. package/dist/chunks/eo-cascader.12cb6d0c.js.map +1 -0
  6. package/dist/chunks/eo-table.2d3928a8.js +2 -0
  7. package/dist/chunks/eo-table.2d3928a8.js.map +1 -0
  8. package/dist/chunks/eo-workbench-layout-v2.4b7795b6.js +2 -0
  9. package/dist/chunks/eo-workbench-layout-v2.4b7795b6.js.map +1 -0
  10. package/dist/chunks/main.bee2d32d.js +2 -0
  11. package/dist/chunks/{main.04e42902.js.map → main.bee2d32d.js.map} +1 -1
  12. package/dist/examples.json +3 -3
  13. package/dist/index.20a36066.js +2 -0
  14. package/dist/index.20a36066.js.map +1 -0
  15. package/dist/manifest.json +231 -231
  16. package/dist/types.json +191 -276
  17. package/dist-types/interfaces/index.d.ts +1 -0
  18. package/dist-types/interfaces/workbench.d.ts +9 -0
  19. package/dist-types/workbench-layout-v2/DraggableComponentMenuItem.d.ts +7 -0
  20. package/dist-types/workbench-layout-v2/DraggableComponentMenuItem.spec.d.ts +1 -0
  21. package/dist-types/workbench-layout-v2/DroppableComponentLayoutItem.d.ts +9 -0
  22. package/dist-types/workbench-layout-v2/DroppableComponentLayoutItem.spec.d.ts +1 -0
  23. package/dist-types/workbench-layout-v2/index.d.ts +3 -10
  24. package/package.json +2 -2
  25. package/dist/chunks/2197.018fe597.js +0 -2
  26. package/dist/chunks/2197.018fe597.js.map +0 -1
  27. package/dist/chunks/eo-cascader.9ed2476a.js +0 -2
  28. package/dist/chunks/eo-cascader.9ed2476a.js.map +0 -1
  29. package/dist/chunks/eo-table.be1334ae.js +0 -2
  30. package/dist/chunks/eo-table.be1334ae.js.map +0 -1
  31. package/dist/chunks/eo-workbench-layout-v2.f1289e80.js +0 -2
  32. package/dist/chunks/eo-workbench-layout-v2.f1289e80.js.map +0 -1
  33. package/dist/chunks/main.04e42902.js +0 -2
  34. package/dist/index.006ff28e.js +0 -2
  35. package/dist/index.006ff28e.js.map +0 -1
package/dist/types.json CHANGED
@@ -1,280 +1,4 @@
1
1
  {
2
- "eo-workbench-layout-v2": {
3
- "properties": [
4
- {
5
- "name": "cardTitle",
6
- "annotation": {
7
- "type": "keyword",
8
- "value": "string"
9
- }
10
- },
11
- {
12
- "name": "isEdit",
13
- "annotation": {
14
- "type": "keyword",
15
- "value": "boolean"
16
- }
17
- },
18
- {
19
- "name": "layouts",
20
- "annotation": {
21
- "type": "array",
22
- "elementType": {
23
- "type": "reference",
24
- "typeName": {
25
- "type": "identifier",
26
- "name": "Layout"
27
- }
28
- }
29
- }
30
- },
31
- {
32
- "name": "toolbarBricks",
33
- "annotation": {
34
- "type": "typeLiteral",
35
- "members": [
36
- {
37
- "type": "propertySignature",
38
- "key": {
39
- "type": "identifier",
40
- "name": "useBrick"
41
- },
42
- "annotation": {
43
- "type": "array",
44
- "elementType": {
45
- "type": "reference",
46
- "typeName": {
47
- "type": "identifier",
48
- "name": "UseSingleBrickConf"
49
- }
50
- }
51
- },
52
- "computed": false
53
- }
54
- ]
55
- }
56
- },
57
- {
58
- "name": "componentList",
59
- "annotation": {
60
- "type": "array",
61
- "elementType": {
62
- "type": "reference",
63
- "typeName": {
64
- "type": "identifier",
65
- "name": "Item"
66
- }
67
- }
68
- }
69
- },
70
- {
71
- "name": "showSettingButton",
72
- "annotation": {
73
- "type": "keyword",
74
- "value": "boolean"
75
- }
76
- }
77
- ],
78
- "events": [
79
- {
80
- "name": "change",
81
- "detail": {
82
- "annotation": {
83
- "type": "array",
84
- "elementType": {
85
- "type": "reference",
86
- "typeName": {
87
- "type": "identifier",
88
- "name": "Layout"
89
- }
90
- }
91
- }
92
- }
93
- },
94
- {
95
- "name": "save",
96
- "detail": {
97
- "annotation": {
98
- "type": "array",
99
- "elementType": {
100
- "type": "reference",
101
- "typeName": {
102
- "type": "identifier",
103
- "name": "Layout"
104
- }
105
- }
106
- }
107
- }
108
- },
109
- {
110
- "name": "cancel",
111
- "detail": {
112
- "annotation": {
113
- "type": "keyword",
114
- "value": "void"
115
- }
116
- }
117
- },
118
- {
119
- "name": "setting",
120
- "detail": {
121
- "annotation": {
122
- "type": "keyword",
123
- "value": "void"
124
- }
125
- }
126
- },
127
- {
128
- "name": "action.click",
129
- "detail": {
130
- "annotation": {
131
- "type": "typeLiteral",
132
- "members": [
133
- {
134
- "type": "propertySignature",
135
- "key": {
136
- "type": "identifier",
137
- "name": "action"
138
- },
139
- "annotation": {
140
- "type": "reference",
141
- "typeName": {
142
- "type": "identifier",
143
- "name": "SimpleAction"
144
- }
145
- },
146
- "computed": false
147
- },
148
- {
149
- "type": "propertySignature",
150
- "key": {
151
- "type": "identifier",
152
- "name": "layouts"
153
- },
154
- "annotation": {
155
- "type": "array",
156
- "elementType": {
157
- "type": "reference",
158
- "typeName": {
159
- "type": "identifier",
160
- "name": "Layout"
161
- }
162
- }
163
- },
164
- "computed": false
165
- }
166
- ]
167
- }
168
- }
169
- }
170
- ],
171
- "methods": [
172
- {
173
- "name": "setLayouts",
174
- "params": [
175
- {
176
- "name": "layouts",
177
- "annotation": {
178
- "type": "array",
179
- "elementType": {
180
- "type": "reference",
181
- "typeName": {
182
- "type": "identifier",
183
- "name": "Layout"
184
- }
185
- }
186
- }
187
- }
188
- ],
189
- "returns": {}
190
- }
191
- ],
192
- "types": [
193
- {
194
- "type": "interface",
195
- "name": "Item",
196
- "body": [
197
- {
198
- "type": "propertySignature",
199
- "key": {
200
- "type": "identifier",
201
- "name": "position"
202
- },
203
- "annotation": {
204
- "type": "reference",
205
- "typeName": {
206
- "type": "identifier",
207
- "name": "Layout"
208
- }
209
- },
210
- "computed": false
211
- },
212
- {
213
- "type": "propertySignature",
214
- "key": {
215
- "type": "identifier",
216
- "name": "key"
217
- },
218
- "annotation": {
219
- "type": "keyword",
220
- "value": "string"
221
- },
222
- "computed": false
223
- },
224
- {
225
- "type": "propertySignature",
226
- "key": {
227
- "type": "identifier",
228
- "name": "title"
229
- },
230
- "annotation": {
231
- "type": "keyword",
232
- "value": "string"
233
- },
234
- "computed": false
235
- },
236
- {
237
- "type": "propertySignature",
238
- "key": {
239
- "type": "identifier",
240
- "name": "style"
241
- },
242
- "annotation": {
243
- "type": "reference",
244
- "typeName": {
245
- "type": "qualifiedName",
246
- "left": {
247
- "type": "identifier",
248
- "name": "React"
249
- },
250
- "right": {
251
- "type": "identifier",
252
- "name": "CSSProperties"
253
- }
254
- }
255
- },
256
- "optional": true,
257
- "computed": false
258
- },
259
- {
260
- "type": "propertySignature",
261
- "key": {
262
- "type": "identifier",
263
- "name": "useBrick"
264
- },
265
- "annotation": {
266
- "type": "reference",
267
- "typeName": {
268
- "type": "identifier",
269
- "name": "UseSingleBrickConf"
270
- }
271
- },
272
- "computed": false
273
- }
274
- ]
275
- }
276
- ]
277
- },
278
2
  "eo-workbench-layout": {
279
3
  "properties": [
280
4
  {
@@ -1764,6 +1488,197 @@
1764
1488
  }
1765
1489
  ]
1766
1490
  },
1491
+ "eo-workbench-layout-v2": {
1492
+ "properties": [
1493
+ {
1494
+ "name": "cardTitle",
1495
+ "annotation": {
1496
+ "type": "keyword",
1497
+ "value": "string"
1498
+ }
1499
+ },
1500
+ {
1501
+ "name": "isEdit",
1502
+ "annotation": {
1503
+ "type": "keyword",
1504
+ "value": "boolean"
1505
+ }
1506
+ },
1507
+ {
1508
+ "name": "layouts",
1509
+ "annotation": {
1510
+ "type": "array",
1511
+ "elementType": {
1512
+ "type": "reference",
1513
+ "typeName": {
1514
+ "type": "identifier",
1515
+ "name": "Layout"
1516
+ }
1517
+ }
1518
+ }
1519
+ },
1520
+ {
1521
+ "name": "toolbarBricks",
1522
+ "annotation": {
1523
+ "type": "typeLiteral",
1524
+ "members": [
1525
+ {
1526
+ "type": "propertySignature",
1527
+ "key": {
1528
+ "type": "identifier",
1529
+ "name": "useBrick"
1530
+ },
1531
+ "annotation": {
1532
+ "type": "array",
1533
+ "elementType": {
1534
+ "type": "reference",
1535
+ "typeName": {
1536
+ "type": "identifier",
1537
+ "name": "UseSingleBrickConf"
1538
+ }
1539
+ }
1540
+ },
1541
+ "computed": false
1542
+ }
1543
+ ]
1544
+ }
1545
+ },
1546
+ {
1547
+ "name": "componentList",
1548
+ "annotation": {
1549
+ "type": "array",
1550
+ "elementType": {
1551
+ "type": "reference",
1552
+ "typeName": {
1553
+ "type": "identifier",
1554
+ "name": "WorkbenchComponent"
1555
+ }
1556
+ }
1557
+ }
1558
+ },
1559
+ {
1560
+ "name": "showSettingButton",
1561
+ "annotation": {
1562
+ "type": "keyword",
1563
+ "value": "boolean"
1564
+ }
1565
+ }
1566
+ ],
1567
+ "events": [
1568
+ {
1569
+ "name": "change",
1570
+ "detail": {
1571
+ "annotation": {
1572
+ "type": "array",
1573
+ "elementType": {
1574
+ "type": "reference",
1575
+ "typeName": {
1576
+ "type": "identifier",
1577
+ "name": "Layout"
1578
+ }
1579
+ }
1580
+ }
1581
+ }
1582
+ },
1583
+ {
1584
+ "name": "save",
1585
+ "detail": {
1586
+ "annotation": {
1587
+ "type": "array",
1588
+ "elementType": {
1589
+ "type": "reference",
1590
+ "typeName": {
1591
+ "type": "identifier",
1592
+ "name": "Layout"
1593
+ }
1594
+ }
1595
+ }
1596
+ }
1597
+ },
1598
+ {
1599
+ "name": "cancel",
1600
+ "detail": {
1601
+ "annotation": {
1602
+ "type": "keyword",
1603
+ "value": "void"
1604
+ }
1605
+ }
1606
+ },
1607
+ {
1608
+ "name": "setting",
1609
+ "detail": {
1610
+ "annotation": {
1611
+ "type": "keyword",
1612
+ "value": "void"
1613
+ }
1614
+ }
1615
+ },
1616
+ {
1617
+ "name": "action.click",
1618
+ "detail": {
1619
+ "annotation": {
1620
+ "type": "typeLiteral",
1621
+ "members": [
1622
+ {
1623
+ "type": "propertySignature",
1624
+ "key": {
1625
+ "type": "identifier",
1626
+ "name": "action"
1627
+ },
1628
+ "annotation": {
1629
+ "type": "reference",
1630
+ "typeName": {
1631
+ "type": "identifier",
1632
+ "name": "SimpleAction"
1633
+ }
1634
+ },
1635
+ "computed": false
1636
+ },
1637
+ {
1638
+ "type": "propertySignature",
1639
+ "key": {
1640
+ "type": "identifier",
1641
+ "name": "layouts"
1642
+ },
1643
+ "annotation": {
1644
+ "type": "array",
1645
+ "elementType": {
1646
+ "type": "reference",
1647
+ "typeName": {
1648
+ "type": "identifier",
1649
+ "name": "Layout"
1650
+ }
1651
+ }
1652
+ },
1653
+ "computed": false
1654
+ }
1655
+ ]
1656
+ }
1657
+ }
1658
+ }
1659
+ ],
1660
+ "methods": [
1661
+ {
1662
+ "name": "setLayouts",
1663
+ "params": [
1664
+ {
1665
+ "name": "layouts",
1666
+ "annotation": {
1667
+ "type": "array",
1668
+ "elementType": {
1669
+ "type": "reference",
1670
+ "typeName": {
1671
+ "type": "identifier",
1672
+ "name": "Layout"
1673
+ }
1674
+ }
1675
+ }
1676
+ }
1677
+ ],
1678
+ "returns": {}
1679
+ }
1680
+ ]
1681
+ },
1767
1682
  "eo-table": {
1768
1683
  "properties": [
1769
1684
  {
@@ -0,0 +1 @@
1
+ export * from "./workbench";
@@ -0,0 +1,9 @@
1
+ import { UseSingleBrickConf } from "@next-core/types";
2
+ import { Layout } from "react-grid-layout";
3
+ export type WorkbenchComponent = {
4
+ position: Layout;
5
+ key: string;
6
+ title: string;
7
+ style?: React.CSSProperties;
8
+ useBrick: UseSingleBrickConf;
9
+ };
@@ -0,0 +1,7 @@
1
+ import React from "react";
2
+ import { WorkbenchComponent } from "../interfaces";
3
+ export interface DraggableComponentMenuItemProps {
4
+ component: WorkbenchComponent;
5
+ onClick?(): void;
6
+ }
7
+ export declare function DraggableComponentMenuItem(props: DraggableComponentMenuItemProps): React.ReactElement;
@@ -0,0 +1 @@
1
+ import "@testing-library/jest-dom";
@@ -0,0 +1,9 @@
1
+ import React from "react";
2
+ import { WorkbenchComponent } from "../interfaces";
3
+ export interface DroppableComponentLayoutItemProps {
4
+ component: WorkbenchComponent;
5
+ isEdit?: boolean;
6
+ onDrop?(component: WorkbenchComponent): void;
7
+ onDelete?(): void;
8
+ }
9
+ export declare function DroppableComponentLayoutItem(props: DroppableComponentLayoutItemProps): React.ReactElement;
@@ -0,0 +1 @@
1
+ import "@testing-library/jest-dom";
@@ -4,21 +4,15 @@ import { UseSingleBrickConf } from "@next-core/types";
4
4
  import { Layout } from "react-grid-layout";
5
5
  import "@next-core/theme";
6
6
  import { SimpleAction } from "@next-bricks/basic/actions";
7
+ import { WorkbenchComponent } from "../interfaces";
7
8
  import "./styles.css";
8
- type Item = {
9
- position: Layout;
10
- key: string;
11
- title: string;
12
- style?: React.CSSProperties;
13
- useBrick: UseSingleBrickConf;
14
- };
15
9
  export interface EoWorkbenchLayoutV2Props {
16
10
  cardTitle?: string;
17
11
  layouts?: Layout[];
18
12
  toolbarBricks?: {
19
13
  useBrick: UseSingleBrickConf[];
20
14
  };
21
- componentList?: Item[];
15
+ componentList?: WorkbenchComponent[];
22
16
  isEdit?: boolean;
23
17
  showSettingButton?: boolean;
24
18
  }
@@ -44,7 +38,7 @@ export declare class EoWorkbenchLayoutV2 extends ReactNextElement {
44
38
  accessor toolbarBricks: {
45
39
  useBrick: UseSingleBrickConf[];
46
40
  } | undefined;
47
- accessor componentList: Item[] | undefined;
41
+ accessor componentList: WorkbenchComponent[] | undefined;
48
42
  /**
49
43
  * description: 用于设置页面样式和布局的按钮
50
44
  */
@@ -53,4 +47,3 @@ export declare class EoWorkbenchLayoutV2 extends ReactNextElement {
53
47
  connectedCallback(): void;
54
48
  render(): React.JSX.Element;
55
49
  }
56
- export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@next-bricks/advanced",
3
- "version": "0.42.9",
3
+ "version": "0.43.1",
4
4
  "homepage": "https://github.com/easyops-cn/next-advanced-bricks/tree/master/bricks/advanced",
5
5
  "repository": {
6
6
  "type": "git",
@@ -45,5 +45,5 @@
45
45
  "@next-bricks/icons": "*",
46
46
  "@next-bricks/markdown": "*"
47
47
  },
48
- "gitHead": "5a318e8e2c109d5617e874c15f67e64f4dc5aac1"
48
+ "gitHead": "a21e7080d6d390074c7825acb6609c3c30fa85d8"
49
49
  }