datastake-daf 0.6.359 → 0.6.360
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/components/index.js
CHANGED
|
@@ -51038,7 +51038,6 @@ function PrimaryNode({
|
|
|
51038
51038
|
}
|
|
51039
51039
|
}), /*#__PURE__*/jsxRuntime.jsxs(Style$f, {
|
|
51040
51040
|
className: "flex",
|
|
51041
|
-
$isPdf: data?.isPdf,
|
|
51042
51041
|
children: [/*#__PURE__*/jsxRuntime.jsx("div", {
|
|
51043
51042
|
className: "left flex flex-column justify-center",
|
|
51044
51043
|
style: {
|
|
@@ -51149,7 +51148,6 @@ function PrimaryNode({
|
|
|
51149
51148
|
}
|
|
51150
51149
|
const Style$f = dt.div`
|
|
51151
51150
|
width: ${MAIN_NODE_WIDTH}px;
|
|
51152
|
-
height: ${props => props.$isPdf ? `${MAIN_NODE_HEIGHT}px` : 'auto'};
|
|
51153
51151
|
display: flex;
|
|
51154
51152
|
background: white;
|
|
51155
51153
|
border-radius: 8px;
|
|
@@ -51169,7 +51167,7 @@ const Style$f = dt.div`
|
|
|
51169
51167
|
flex: 1;
|
|
51170
51168
|
|
|
51171
51169
|
.top {
|
|
51172
|
-
padding:
|
|
51170
|
+
padding: 16px 12px;
|
|
51173
51171
|
border-bottom: 1px solid var(--base-gray-30);
|
|
51174
51172
|
|
|
51175
51173
|
span {
|
|
@@ -51196,7 +51194,7 @@ const Style$f = dt.div`
|
|
|
51196
51194
|
}
|
|
51197
51195
|
|
|
51198
51196
|
.bottom {
|
|
51199
|
-
padding:
|
|
51197
|
+
padding: 16px;
|
|
51200
51198
|
display: flex;
|
|
51201
51199
|
margin-top: 6px;
|
|
51202
51200
|
margin-bottom: 6px;
|
|
@@ -52661,8 +52659,7 @@ function positionDataNodes(_ref2) {
|
|
|
52661
52659
|
total,
|
|
52662
52660
|
mainNode,
|
|
52663
52661
|
type,
|
|
52664
|
-
hasContent
|
|
52665
|
-
isPdf = false
|
|
52662
|
+
hasContent
|
|
52666
52663
|
} = _ref2;
|
|
52667
52664
|
const DATA_NODE_WIDTH = DATA_NODE_SIZE[type].width;
|
|
52668
52665
|
const DATA_NODE_HEIGHT = DATA_NODE_SIZE[type].height;
|
|
@@ -52684,7 +52681,7 @@ function positionDataNodes(_ref2) {
|
|
|
52684
52681
|
const X_SPACE_FROM_ICON_NODE = 130;
|
|
52685
52682
|
const MIN_SPACE_REQUIRED = Y_SPACE_FROM_SIBLINGS + DATA_NODE_HEIGHT;
|
|
52686
52683
|
const totalHeight = total * MIN_SPACE_REQUIRED;
|
|
52687
|
-
const iconNodeCenterY =
|
|
52684
|
+
const iconNodeCenterY = iconNode.position.y + ICON_NODE_HEIGHT / 2 + (hasContent ? 26.5 : type === "primaryNode" ? 15 : 16.5);
|
|
52688
52685
|
const startY = iconNodeCenterY - totalHeight / 2;
|
|
52689
52686
|
const END_Y = startY + totalHeight;
|
|
52690
52687
|
const yOffset = index * MIN_SPACE_REQUIRED;
|
|
@@ -52760,8 +52757,7 @@ function StakeholderMappings(_ref3) {
|
|
|
52760
52757
|
onClick: (data === null || data === void 0 ? void 0 : data.onClick) || undefined,
|
|
52761
52758
|
totalSources: data === null || data === void 0 ? void 0 : data.totalSources,
|
|
52762
52759
|
backgroundColor: (data === null || data === void 0 ? void 0 : data.backgroundColor) || "#ade9e1",
|
|
52763
|
-
iconColor: (data === null || data === void 0 ? void 0 : data.iconColor) || "#08949a"
|
|
52764
|
-
isPdf
|
|
52760
|
+
iconColor: (data === null || data === void 0 ? void 0 : data.iconColor) || "#08949a"
|
|
52765
52761
|
},
|
|
52766
52762
|
position: {
|
|
52767
52763
|
x: centerX - MAIN_NODE_WIDTH / 2,
|
|
@@ -52783,7 +52779,6 @@ function StakeholderMappings(_ref3) {
|
|
|
52783
52779
|
order: child.order,
|
|
52784
52780
|
isLeftSide: child.order % 2 !== 0,
|
|
52785
52781
|
emptyName: child.emptyName,
|
|
52786
|
-
isPdf,
|
|
52787
52782
|
onSelect: !isSelectable ? undefined : nodeId => {
|
|
52788
52783
|
if (selectedIconNodes.includes(nodeId)) {
|
|
52789
52784
|
setSelectedIconNodes(prev => prev.filter(id => id !== nodeId));
|
|
@@ -52846,8 +52841,7 @@ function StakeholderMappings(_ref3) {
|
|
|
52846
52841
|
total: 1,
|
|
52847
52842
|
mainNode,
|
|
52848
52843
|
type: "nameNode",
|
|
52849
|
-
hasContent: (node === null || node === void 0 || (_node$data4 = node.data) === null || _node$data4 === void 0 ? void 0 : _node$data4.content) !== undefined && (node === null || node === void 0 || (_node$data5 = node.data) === null || _node$data5 === void 0 ? void 0 : _node$data5.content) !== null ? true : false
|
|
52850
|
-
isPdf
|
|
52844
|
+
hasContent: (node === null || node === void 0 || (_node$data4 = node.data) === null || _node$data4 === void 0 ? void 0 : _node$data4.content) !== undefined && (node === null || node === void 0 || (_node$data5 = node.data) === null || _node$data5 === void 0 ? void 0 : _node$data5.content) !== null ? true : false
|
|
52851
52845
|
})
|
|
52852
52846
|
}];
|
|
52853
52847
|
}
|
|
@@ -52861,8 +52855,7 @@ function StakeholderMappings(_ref3) {
|
|
|
52861
52855
|
data: {
|
|
52862
52856
|
name: node === null || node === void 0 || (_node$data6 = node.data) === null || _node$data6 === void 0 ? void 0 : _node$data6.name,
|
|
52863
52857
|
content: node === null || node === void 0 || (_node$data7 = node.data) === null || _node$data7 === void 0 ? void 0 : _node$data7.content,
|
|
52864
|
-
isOnlyOne: true
|
|
52865
|
-
isPdf: true
|
|
52858
|
+
isOnlyOne: true
|
|
52866
52859
|
},
|
|
52867
52860
|
targetHandle: node.data.order % 2 === 0 ? "left-handle-target" : "right-handle-target"
|
|
52868
52861
|
});
|
|
@@ -52941,8 +52934,7 @@ function StakeholderMappings(_ref3) {
|
|
|
52941
52934
|
total,
|
|
52942
52935
|
mainNode,
|
|
52943
52936
|
type: child.type || "primaryNode",
|
|
52944
|
-
hasContent: node !== null && node !== void 0 && (_node$data15 = node.data) !== null && _node$data15 !== void 0 && _node$data15.content ? true : false
|
|
52945
|
-
isPdf
|
|
52937
|
+
hasContent: node !== null && node !== void 0 && (_node$data15 = node.data) !== null && _node$data15 !== void 0 && _node$data15.content ? true : false
|
|
52946
52938
|
})
|
|
52947
52939
|
};
|
|
52948
52940
|
});
|
package/package.json
CHANGED
|
@@ -72,7 +72,6 @@ function positionDataNodes({
|
|
|
72
72
|
mainNode,
|
|
73
73
|
type,
|
|
74
74
|
hasContent,
|
|
75
|
-
isPdf = false,
|
|
76
75
|
}) {
|
|
77
76
|
const DATA_NODE_WIDTH = DATA_NODE_SIZE[type].width;
|
|
78
77
|
const DATA_NODE_HEIGHT = DATA_NODE_SIZE[type].height;
|
|
@@ -96,11 +95,10 @@ function positionDataNodes({
|
|
|
96
95
|
|
|
97
96
|
const totalHeight = total * MIN_SPACE_REQUIRED;
|
|
98
97
|
|
|
99
|
-
const iconNodeCenterY =
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
(hasContent ? 26.5 : type === "primaryNode" ? 15 : 16.5);
|
|
98
|
+
const iconNodeCenterY =
|
|
99
|
+
iconNode.position.y +
|
|
100
|
+
ICON_NODE_HEIGHT / 2 +
|
|
101
|
+
(hasContent ? 26.5 : type === "primaryNode" ? 15 : 16.5);
|
|
104
102
|
const startY = iconNodeCenterY - totalHeight / 2;
|
|
105
103
|
const END_Y = startY + totalHeight;
|
|
106
104
|
|
|
@@ -185,7 +183,6 @@ function StakeholderMappings({
|
|
|
185
183
|
totalSources: data?.totalSources,
|
|
186
184
|
backgroundColor: data?.backgroundColor || "#ade9e1",
|
|
187
185
|
iconColor: data?.iconColor || "#08949a",
|
|
188
|
-
isPdf,
|
|
189
186
|
},
|
|
190
187
|
position: {
|
|
191
188
|
x: centerX - MAIN_NODE_WIDTH / 2,
|
|
@@ -209,7 +206,6 @@ function StakeholderMappings({
|
|
|
209
206
|
order: child.order,
|
|
210
207
|
isLeftSide: child.order % 2 !== 0,
|
|
211
208
|
emptyName: child.emptyName,
|
|
212
|
-
isPdf,
|
|
213
209
|
onSelect: !isSelectable
|
|
214
210
|
? undefined
|
|
215
211
|
: (nodeId) => {
|
|
@@ -289,8 +285,7 @@ function StakeholderMappings({
|
|
|
289
285
|
hasContent:
|
|
290
286
|
node?.data?.content !== undefined && node?.data?.content !== null
|
|
291
287
|
? true
|
|
292
|
-
|
|
293
|
-
isPdf,
|
|
288
|
+
: false,
|
|
294
289
|
}),
|
|
295
290
|
},
|
|
296
291
|
];
|
|
@@ -306,7 +301,6 @@ function StakeholderMappings({
|
|
|
306
301
|
name: node?.data?.name,
|
|
307
302
|
content: node?.data?.content,
|
|
308
303
|
isOnlyOne: true,
|
|
309
|
-
isPdf: true,
|
|
310
304
|
},
|
|
311
305
|
targetHandle:
|
|
312
306
|
node.data.order % 2 === 0 ? "left-handle-target" : "right-handle-target",
|
|
@@ -377,7 +371,7 @@ function StakeholderMappings({
|
|
|
377
371
|
|
|
378
372
|
return {
|
|
379
373
|
id: `${child.id}-${iconNodeId}`,
|
|
380
|
-
|
|
374
|
+
type: child.type || "primaryNode",
|
|
381
375
|
data: {
|
|
382
376
|
name: child.name,
|
|
383
377
|
id: child.id,
|
|
@@ -397,8 +391,7 @@ function StakeholderMappings({
|
|
|
397
391
|
total,
|
|
398
392
|
mainNode,
|
|
399
393
|
type: child.type || "primaryNode",
|
|
400
|
-
|
|
401
|
-
isPdf,
|
|
394
|
+
hasContent: node?.data?.content ? true : false,
|
|
402
395
|
}),
|
|
403
396
|
};
|
|
404
397
|
});
|
|
@@ -30,7 +30,7 @@ export default function PrimaryNode({ id, data }) {
|
|
|
30
30
|
opacity: 0,
|
|
31
31
|
}}
|
|
32
32
|
/>
|
|
33
|
-
<Style className="flex"
|
|
33
|
+
<Style className="flex">
|
|
34
34
|
<div
|
|
35
35
|
className="left flex flex-column justify-center"
|
|
36
36
|
style={{
|
|
@@ -133,7 +133,6 @@ export default function PrimaryNode({ id, data }) {
|
|
|
133
133
|
|
|
134
134
|
const Style = styled.div`
|
|
135
135
|
width: ${MAIN_NODE_WIDTH}px;
|
|
136
|
-
height: ${(props) => (props.$isPdf ? `${MAIN_NODE_HEIGHT}px` : 'auto')};
|
|
137
136
|
display: flex;
|
|
138
137
|
background: white;
|
|
139
138
|
border-radius: 8px;
|
|
@@ -153,7 +152,7 @@ const Style = styled.div`
|
|
|
153
152
|
flex: 1;
|
|
154
153
|
|
|
155
154
|
.top {
|
|
156
|
-
padding:
|
|
155
|
+
padding: 16px 12px;
|
|
157
156
|
border-bottom: 1px solid var(--base-gray-30);
|
|
158
157
|
|
|
159
158
|
span {
|
|
@@ -180,7 +179,7 @@ const Style = styled.div`
|
|
|
180
179
|
}
|
|
181
180
|
|
|
182
181
|
.bottom {
|
|
183
|
-
padding:
|
|
182
|
+
padding: 16px;
|
|
184
183
|
display: flex;
|
|
185
184
|
margin-top: 6px;
|
|
186
185
|
margin-bottom: 6px;
|