@uipath/apollo-react 3.51.2 → 3.52.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.
@@ -391,8 +391,14 @@ const BaseNodeComponent = (props)=>{
391
391
  backgroundColor: displayBackground,
392
392
  hasFooter: !!displayFooter,
393
393
  footerVariant: displayFooterVariant,
394
+ "aria-busy": data.loading || void 0,
394
395
  children: [
395
- Icon && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_BaseNode_styles_cjs_namespaceObject.BaseIconWrapper, {
396
+ data.loading ? /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_BaseNode_styles_cjs_namespaceObject.BaseSkeletonIcon, {
397
+ variant: "rectangle",
398
+ shape: displayShape,
399
+ nodeHeight: displayFooter ? void 0 : height,
400
+ nodeWidth: displayFooter ? void 0 : width ?? height
401
+ }) : Icon && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_BaseNode_styles_cjs_namespaceObject.BaseIconWrapper, {
396
402
  shape: displayShape,
397
403
  color: displayColor,
398
404
  backgroundColor: displayIconBackground,
@@ -1 +1 @@
1
- {"version":3,"file":"BaseNode.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/BaseNode/BaseNode.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,SAAS,EAAkB,MAAM,0CAA0C,CAAC;AAkChG,OAAO,KAAK,EACV,YAAY,EAIb,MAAM,kBAAkB,CAAC;AA2gB1B,eAAO,MAAM,QAAQ,8CArgBa,SAAS,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC,6CAqgBhB,CAAC"}
1
+ {"version":3,"file":"BaseNode.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/BaseNode/BaseNode.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,SAAS,EAAkB,MAAM,0CAA0C,CAAC;AAmChG,OAAO,KAAK,EACV,YAAY,EAIb,MAAM,kBAAkB,CAAC;AAuhB1B,eAAO,MAAM,QAAQ,8CAjhBa,SAAS,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC,6CAihBhB,CAAC"}
@@ -17,7 +17,7 @@ import { useSelectionState } from "../BaseCanvas/SelectionStateContext.js";
17
17
  import { SmartHandle, SmartHandleProvider } from "../ButtonHandle/SmartHandle.js";
18
18
  import { useButtonHandles } from "../ButtonHandle/useButtonHandles.js";
19
19
  import { NodeToolbar } from "../Toolbar/index.js";
20
- import { BaseBadgeSlot, BaseContainer, BaseHeader, BaseIconWrapper, BaseSubHeader, BaseTextContainer } from "./BaseNode.styles.js";
20
+ import { BaseBadgeSlot, BaseContainer, BaseHeader, BaseIconWrapper, BaseSkeletonIcon, BaseSubHeader, BaseTextContainer } from "./BaseNode.styles.js";
21
21
  import { useBaseNodeOverrideConfig } from "./BaseNodeConfigContext.js";
22
22
  import { NodeLabel } from "./NodeLabel.js";
23
23
  const selectIsConnecting = (state)=>!!state.connectionClickStartHandle;
@@ -363,8 +363,14 @@ const BaseNodeComponent = (props)=>{
363
363
  backgroundColor: displayBackground,
364
364
  hasFooter: !!displayFooter,
365
365
  footerVariant: displayFooterVariant,
366
+ "aria-busy": data.loading || void 0,
366
367
  children: [
367
- Icon && /*#__PURE__*/ jsx(BaseIconWrapper, {
368
+ data.loading ? /*#__PURE__*/ jsx(BaseSkeletonIcon, {
369
+ variant: "rectangle",
370
+ shape: displayShape,
371
+ nodeHeight: displayFooter ? void 0 : height,
372
+ nodeWidth: displayFooter ? void 0 : width ?? height
373
+ }) : Icon && /*#__PURE__*/ jsx(BaseIconWrapper, {
368
374
  shape: displayShape,
369
375
  color: displayColor,
370
376
  backgroundColor: displayIconBackground,
@@ -25,6 +25,7 @@ var __webpack_exports__ = {};
25
25
  __webpack_require__.r(__webpack_exports__);
26
26
  __webpack_require__.d(__webpack_exports__, {
27
27
  CustomizedSizes: ()=>CustomizedSizes,
28
+ Loading: ()=>Loading,
28
29
  ValidationStates: ()=>ValidationStates,
29
30
  Default: ()=>Default,
30
31
  default: ()=>BaseNode_stories,
@@ -267,6 +268,34 @@ const sampleManifest = {
267
268
  ]
268
269
  }
269
270
  ]
271
+ },
272
+ {
273
+ nodeType: 'uipath.control-flow.terminate',
274
+ version: '1.0.0',
275
+ category: 'control',
276
+ tags: [
277
+ 'control',
278
+ 'terminate'
279
+ ],
280
+ sortOrder: 6,
281
+ display: {
282
+ label: 'Terminate',
283
+ icon: 'git-branch',
284
+ shape: 'circle'
285
+ },
286
+ handleConfiguration: [
287
+ {
288
+ position: 'right',
289
+ handles: [
290
+ {
291
+ id: 'out',
292
+ type: 'source',
293
+ handleType: 'output',
294
+ label: 'Output'
295
+ }
296
+ ]
297
+ }
298
+ ]
270
299
  }
271
300
  ]
272
301
  };
@@ -821,6 +850,65 @@ function DynamicHandlesStory() {
821
850
  ]
822
851
  });
823
852
  }
853
+ function createLoadingGrid() {
854
+ const shapes = [
855
+ {
856
+ type: 'uipath.blank-node',
857
+ shape: 'square',
858
+ label: 'Square'
859
+ },
860
+ {
861
+ type: 'uipath.control-flow.terminate',
862
+ shape: 'circle',
863
+ label: 'Circle'
864
+ },
865
+ {
866
+ type: 'uipath.agent',
867
+ shape: 'rectangle',
868
+ label: 'Rectangle'
869
+ }
870
+ ];
871
+ return shapes.map((config, index)=>(0, external_storybook_utils_index_cjs_namespaceObject.createNode)({
872
+ id: `loading-${config.shape}`,
873
+ type: config.type,
874
+ position: {
875
+ x: 96 + 192 * index,
876
+ y: 96
877
+ },
878
+ data: {
879
+ nodeType: config.type,
880
+ version: '1.0.0',
881
+ loading: true,
882
+ display: {
883
+ label: config.label,
884
+ subLabel: 'Loading...',
885
+ shape: config.shape
886
+ }
887
+ }
888
+ }));
889
+ }
890
+ function LoadingStory() {
891
+ const initialNodes = (0, external_react_namespaceObject.useMemo)(()=>createLoadingGrid(), []);
892
+ const { canvasProps } = (0, external_storybook_utils_index_cjs_namespaceObject.useCanvasStory)({
893
+ initialNodes
894
+ });
895
+ return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(external_BaseCanvas_index_cjs_namespaceObject.BaseCanvas, {
896
+ ...canvasProps,
897
+ mode: "design",
898
+ children: [
899
+ /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(react_cjs_namespaceObject.Panel, {
900
+ position: "bottom-right",
901
+ children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_CanvasPositionControls_cjs_namespaceObject.CanvasPositionControls, {
902
+ translations: external_types_cjs_namespaceObject.DefaultCanvasTranslations
903
+ })
904
+ }),
905
+ /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_storybook_utils_index_cjs_namespaceObject.StoryInfoPanel, {
906
+ title: "Loading State",
907
+ description: "Nodes in skeleton loading state for circle, square, and rectangle shapes."
908
+ })
909
+ ]
910
+ });
911
+ }
824
912
  const Default = {
825
913
  name: 'Default',
826
914
  render: ()=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(DefaultStory, {})
@@ -939,15 +1027,21 @@ const ValidationStates = {
939
1027
  ],
940
1028
  render: ()=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(ValidationStatesStory, {})
941
1029
  };
1030
+ const Loading = {
1031
+ name: 'Loading',
1032
+ render: ()=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(LoadingStory, {})
1033
+ };
942
1034
  exports.CustomizedSizes = __webpack_exports__.CustomizedSizes;
943
1035
  exports.Default = __webpack_exports__.Default;
944
1036
  exports.DynamicHandles = __webpack_exports__.DynamicHandles;
1037
+ exports.Loading = __webpack_exports__.Loading;
945
1038
  exports.ValidationStates = __webpack_exports__.ValidationStates;
946
1039
  exports["default"] = __webpack_exports__["default"];
947
1040
  for(var __rspack_i in __webpack_exports__)if (-1 === [
948
1041
  "CustomizedSizes",
949
1042
  "Default",
950
1043
  "DynamicHandles",
1044
+ "Loading",
951
1045
  "ValidationStates",
952
1046
  "default"
953
1047
  ].indexOf(__rspack_i)) exports[__rspack_i] = __webpack_exports__[__rspack_i];
@@ -7,4 +7,5 @@ export declare const Default: Story;
7
7
  export declare const CustomizedSizes: Story;
8
8
  export declare const DynamicHandles: Story;
9
9
  export declare const ValidationStates: Story;
10
+ export declare const Loading: Story;
10
11
  //# sourceMappingURL=BaseNode.stories.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"BaseNode.stories.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/BaseNode/BaseNode.stories.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAmBvD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAuLrD,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,YAAY,CAqB5B,CAAC;AAEF,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,IAAI,CAAC,CAAC;AAmZnC,eAAO,MAAM,OAAO,EAAE,KAGrB,CAAC;AAEF,eAAO,MAAM,eAAe,EAAE,KAG7B,CAAC;AAEF,eAAO,MAAM,cAAc,EAAE,KAG5B,CAAC;AAmEF,eAAO,MAAM,gBAAgB,EAAE,KAuC9B,CAAC"}
1
+ {"version":3,"file":"BaseNode.stories.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/BaseNode/BaseNode.stories.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAmBvD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAyMrD,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,YAAY,CAqB5B,CAAC;AAEF,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,IAAI,CAAC,CAAC;AAkcnC,eAAO,MAAM,OAAO,EAAE,KAGrB,CAAC;AAEF,eAAO,MAAM,eAAe,EAAE,KAG7B,CAAC;AAEF,eAAO,MAAM,cAAc,EAAE,KAG5B,CAAC;AAmEF,eAAO,MAAM,gBAAgB,EAAE,KAuC9B,CAAC;AAEF,eAAO,MAAM,OAAO,EAAE,KAGrB,CAAC"}
@@ -235,6 +235,34 @@ const sampleManifest = {
235
235
  ]
236
236
  }
237
237
  ]
238
+ },
239
+ {
240
+ nodeType: 'uipath.control-flow.terminate',
241
+ version: '1.0.0',
242
+ category: 'control',
243
+ tags: [
244
+ 'control',
245
+ 'terminate'
246
+ ],
247
+ sortOrder: 6,
248
+ display: {
249
+ label: 'Terminate',
250
+ icon: 'git-branch',
251
+ shape: 'circle'
252
+ },
253
+ handleConfiguration: [
254
+ {
255
+ position: 'right',
256
+ handles: [
257
+ {
258
+ id: 'out',
259
+ type: 'source',
260
+ handleType: 'output',
261
+ label: 'Output'
262
+ }
263
+ ]
264
+ }
265
+ ]
238
266
  }
239
267
  ]
240
268
  };
@@ -789,6 +817,65 @@ function DynamicHandlesStory() {
789
817
  ]
790
818
  });
791
819
  }
820
+ function createLoadingGrid() {
821
+ const shapes = [
822
+ {
823
+ type: 'uipath.blank-node',
824
+ shape: 'square',
825
+ label: 'Square'
826
+ },
827
+ {
828
+ type: 'uipath.control-flow.terminate',
829
+ shape: 'circle',
830
+ label: 'Circle'
831
+ },
832
+ {
833
+ type: 'uipath.agent',
834
+ shape: 'rectangle',
835
+ label: 'Rectangle'
836
+ }
837
+ ];
838
+ return shapes.map((config, index)=>createNode({
839
+ id: `loading-${config.shape}`,
840
+ type: config.type,
841
+ position: {
842
+ x: 96 + 192 * index,
843
+ y: 96
844
+ },
845
+ data: {
846
+ nodeType: config.type,
847
+ version: '1.0.0',
848
+ loading: true,
849
+ display: {
850
+ label: config.label,
851
+ subLabel: 'Loading...',
852
+ shape: config.shape
853
+ }
854
+ }
855
+ }));
856
+ }
857
+ function LoadingStory() {
858
+ const initialNodes = useMemo(()=>createLoadingGrid(), []);
859
+ const { canvasProps } = useCanvasStory({
860
+ initialNodes
861
+ });
862
+ return /*#__PURE__*/ jsxs(BaseCanvas, {
863
+ ...canvasProps,
864
+ mode: "design",
865
+ children: [
866
+ /*#__PURE__*/ jsx(Panel, {
867
+ position: "bottom-right",
868
+ children: /*#__PURE__*/ jsx(CanvasPositionControls, {
869
+ translations: DefaultCanvasTranslations
870
+ })
871
+ }),
872
+ /*#__PURE__*/ jsx(StoryInfoPanel, {
873
+ title: "Loading State",
874
+ description: "Nodes in skeleton loading state for circle, square, and rectangle shapes."
875
+ })
876
+ ]
877
+ });
878
+ }
792
879
  const Default = {
793
880
  name: 'Default',
794
881
  render: ()=>/*#__PURE__*/ jsx(DefaultStory, {})
@@ -907,4 +994,8 @@ const ValidationStates = {
907
994
  ],
908
995
  render: ()=>/*#__PURE__*/ jsx(ValidationStatesStory, {})
909
996
  };
910
- export { CustomizedSizes, Default, DynamicHandles, ValidationStates, BaseNode_stories as default };
997
+ const Loading = {
998
+ name: 'Loading',
999
+ render: ()=>/*#__PURE__*/ jsx(LoadingStory, {})
1000
+ };
1001
+ export { CustomizedSizes, Default, DynamicHandles, Loading, ValidationStates, BaseNode_stories as default };
@@ -37,19 +37,35 @@ __webpack_require__.d(__webpack_exports__, {
37
37
  BaseContainer: ()=>BaseContainer,
38
38
  BaseTextContainer: ()=>BaseTextContainer,
39
39
  BaseBadgeSlot: ()=>BaseBadgeSlot,
40
+ EditableLabel: ()=>EditableLabel,
40
41
  BaseSubHeader: ()=>BaseSubHeader,
41
42
  EmptyLabelPlaceholder: ()=>EmptyLabelPlaceholder,
42
- EditableLabel: ()=>EditableLabel,
43
- BaseHeader: ()=>BaseHeader
43
+ BaseHeader: ()=>BaseHeader,
44
+ BaseSkeletonIcon: ()=>BaseSkeletonIcon
44
45
  });
45
46
  const react_namespaceObject = require("@emotion/react");
46
47
  const styled_namespaceObject = require("@emotion/styled");
47
48
  var styled_default = /*#__PURE__*/ __webpack_require__.n(styled_namespaceObject);
49
+ const index_cjs_namespaceObject = require("../../../material/components/ap-skeleton/index.cjs");
48
50
  const GRID_UNIT = 16;
49
51
  const NODE_HEIGHT_DEFAULT = 6 * GRID_UNIT;
50
52
  const NODE_HEIGHT_FOOTER_BUTTON = 9 * GRID_UNIT;
51
53
  const NODE_HEIGHT_FOOTER_SINGLE = 10 * GRID_UNIT;
52
54
  const NODE_HEIGHT_FOOTER_DOUBLE = 11 * GRID_UNIT;
55
+ const getIconDimensions = (shape, nodeHeight, nodeWidth)=>{
56
+ const height = nodeHeight ?? 96;
57
+ const width = nodeWidth ?? 96;
58
+ const widthDimension = height !== width && 'rectangle' === shape ? height : width;
59
+ const widthScaleFactor = widthDimension / 96;
60
+ const iconWidth = 72 * widthScaleFactor;
61
+ const heightScaleFactor = height / 96;
62
+ const isExpandable = height !== width && 'rectangle' !== shape;
63
+ const iconHeight = isExpandable ? 84 * heightScaleFactor : 72 * heightScaleFactor;
64
+ return {
65
+ iconWidth,
66
+ iconHeight
67
+ };
68
+ };
53
69
  const pulseAnimation = (cssVar)=>(0, react_namespaceObject.keyframes)`
54
70
  0% {
55
71
  box-shadow: 0 0 0 0 color-mix(in srgb, var(${cssVar}) 20%, transparent);
@@ -230,15 +246,13 @@ const BaseContainer = styled_default().div`
230
246
  }}
231
247
  `;
232
248
  const BaseIconWrapper = styled_default().div`
233
- width: ${({ height, width, shape })=>{
234
- const dimension = height !== width && 'rectangle' === shape ? height : width;
235
- const scaleFactor = dimension ? dimension / 96 : 1;
236
- return `${72 * scaleFactor}px`;
237
- }};
238
- height: ${({ height, width, shape })=>{
239
- const scaleFactor = height ? height / 96 : 1;
240
- return height !== width && 'rectangle' !== shape ? `${84 * scaleFactor}px` : `${72 * scaleFactor}px`;
241
- }};
249
+ ${({ height, width, shape })=>{
250
+ const { iconWidth, iconHeight } = getIconDimensions(shape, height, width);
251
+ return (0, react_namespaceObject.css)`
252
+ width: ${iconWidth}px;
253
+ height: ${iconHeight}px;
254
+ `;
255
+ }}
242
256
  display: flex;
243
257
  align-items: center;
244
258
  justify-content: center;
@@ -399,10 +413,26 @@ const BaseBadgeSlot = styled_default().div`
399
413
  }
400
414
  }}
401
415
  `;
416
+ const BaseSkeletonIcon = styled_default()(index_cjs_namespaceObject.ApSkeleton, {
417
+ shouldForwardProp: (prop)=>'shape' !== prop && 'nodeHeight' !== prop && 'nodeWidth' !== prop
418
+ })`
419
+ flex-grow: 0;
420
+ flex-shrink: 0;
421
+ ${({ shape, nodeHeight, nodeWidth })=>{
422
+ const { iconWidth, iconHeight } = getIconDimensions(shape, nodeHeight, nodeWidth);
423
+ const isCircle = 'circle' === shape;
424
+ return (0, react_namespaceObject.css)`
425
+ width: ${iconWidth}px;
426
+ height: ${iconHeight}px;
427
+ border-radius: ${isCircle ? '50%' : '8px'};
428
+ `;
429
+ }}
430
+ `;
402
431
  exports.BaseBadgeSlot = __webpack_exports__.BaseBadgeSlot;
403
432
  exports.BaseContainer = __webpack_exports__.BaseContainer;
404
433
  exports.BaseHeader = __webpack_exports__.BaseHeader;
405
434
  exports.BaseIconWrapper = __webpack_exports__.BaseIconWrapper;
435
+ exports.BaseSkeletonIcon = __webpack_exports__.BaseSkeletonIcon;
406
436
  exports.BaseSubHeader = __webpack_exports__.BaseSubHeader;
407
437
  exports.BaseTextContainer = __webpack_exports__.BaseTextContainer;
408
438
  exports.EditableLabel = __webpack_exports__.EditableLabel;
@@ -412,6 +442,7 @@ for(var __rspack_i in __webpack_exports__)if (-1 === [
412
442
  "BaseContainer",
413
443
  "BaseHeader",
414
444
  "BaseIconWrapper",
445
+ "BaseSkeletonIcon",
415
446
  "BaseSubHeader",
416
447
  "BaseTextContainer",
417
448
  "EditableLabel",
@@ -65,4 +65,11 @@ export declare const BaseBadgeSlot: import("@emotion/styled").StyledComponent<{
65
65
  position: "top-left" | "top-right" | "bottom-left" | "bottom-right";
66
66
  shape?: NodeShape;
67
67
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
68
+ export declare const BaseSkeletonIcon: import("@emotion/styled").StyledComponent<import("../../..").ApSkeletonProps & import("react").RefAttributes<HTMLDivElement> & {
69
+ theme?: import("@emotion/react").Theme;
70
+ } & {
71
+ shape?: NodeShape;
72
+ nodeHeight?: number;
73
+ nodeWidth?: number;
74
+ }, {}, {}>;
68
75
  //# sourceMappingURL=BaseNode.styles.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"BaseNode.styles.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/BaseNode/BaseNode.styles.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAyItD,eAAO,MAAM,aAAa;;;;eACb,OAAO;sBACA,MAAM;YAChB,SAAS;sBACC,MAAM;uBACL,MAAM;uBACN,MAAM;qBACR,MAAM;YACf,MAAM;aACL,MAAM;gBACH,OAAO;oBACH,aAAa;yGAuE9B,CAAC;AAEF,eAAO,MAAM,eAAe;;;;YAClB,MAAM;sBACI,MAAM;YAChB,SAAS;aACR,MAAM;YACP,MAAM;yGAgDf,CAAC;AAEF,eAAO,MAAM,iBAAiB;;;;uBAAmC,OAAO;YAAU,SAAS;yGAiC1F,CAAC;AAEF,eAAO,MAAM,UAAU;;;;YAAwB,SAAS;sBAAoB,MAAM;yGAwBjF,CAAC;AAEF,eAAO,MAAM,aAAa;;;;YAAwB,SAAS;yGAe1D,CAAC;AAEF,eAAO,MAAM,aAAa;;;;YAChB,SAAS;sBACC,MAAM;aACf,QAAQ,GAAG,SAAS;2HA+B9B,CAAC;AAEF,eAAO,MAAM,qBAAqB;;;yGAkBjC,CAAC;AAEF,eAAO,MAAM,aAAa;;;;cACd,UAAU,GAAG,WAAW,GAAG,aAAa,GAAG,cAAc;YAC3D,SAAS;yGAsBlB,CAAC"}
1
+ {"version":3,"file":"BaseNode.styles.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/BaseNode/BaseNode.styles.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAkKtD,eAAO,MAAM,aAAa;;;;eACb,OAAO;sBACA,MAAM;YAChB,SAAS;sBACC,MAAM;uBACL,MAAM;uBACN,MAAM;qBACR,MAAM;YACf,MAAM;aACL,MAAM;gBACH,OAAO;oBACH,aAAa;yGAuE9B,CAAC;AAEF,eAAO,MAAM,eAAe;;;;YAClB,MAAM;sBACI,MAAM;YAChB,SAAS;aACR,MAAM;YACP,MAAM;yGA0Cf,CAAC;AAEF,eAAO,MAAM,iBAAiB;;;;uBAAmC,OAAO;YAAU,SAAS;yGAiC1F,CAAC;AAEF,eAAO,MAAM,UAAU;;;;YAAwB,SAAS;sBAAoB,MAAM;yGAwBjF,CAAC;AAEF,eAAO,MAAM,aAAa;;;;YAAwB,SAAS;yGAe1D,CAAC;AAEF,eAAO,MAAM,aAAa;;;;YAChB,SAAS;sBACC,MAAM;aACf,QAAQ,GAAG,SAAS;2HA+B9B,CAAC;AAEF,eAAO,MAAM,qBAAqB;;;yGAkBjC,CAAC;AAEF,eAAO,MAAM,aAAa;;;;cACd,UAAU,GAAG,WAAW,GAAG,aAAa,GAAG,cAAc;YAC3D,SAAS;yGAsBlB,CAAC;AAKF,eAAO,MAAM,gBAAgB;;;YAGnB,SAAS;iBACJ,MAAM;gBACP,MAAM;UAcnB,CAAC"}
@@ -1,10 +1,25 @@
1
1
  import { css, keyframes } from "@emotion/react";
2
2
  import styled from "@emotion/styled";
3
+ import { ApSkeleton } from "../../../material/components/ap-skeleton/index.js";
3
4
  const GRID_UNIT = 16;
4
5
  const NODE_HEIGHT_DEFAULT = 6 * GRID_UNIT;
5
6
  const NODE_HEIGHT_FOOTER_BUTTON = 9 * GRID_UNIT;
6
7
  const NODE_HEIGHT_FOOTER_SINGLE = 10 * GRID_UNIT;
7
8
  const NODE_HEIGHT_FOOTER_DOUBLE = 11 * GRID_UNIT;
9
+ const getIconDimensions = (shape, nodeHeight, nodeWidth)=>{
10
+ const height = nodeHeight ?? 96;
11
+ const width = nodeWidth ?? 96;
12
+ const widthDimension = height !== width && 'rectangle' === shape ? height : width;
13
+ const widthScaleFactor = widthDimension / 96;
14
+ const iconWidth = 72 * widthScaleFactor;
15
+ const heightScaleFactor = height / 96;
16
+ const isExpandable = height !== width && 'rectangle' !== shape;
17
+ const iconHeight = isExpandable ? 84 * heightScaleFactor : 72 * heightScaleFactor;
18
+ return {
19
+ iconWidth,
20
+ iconHeight
21
+ };
22
+ };
8
23
  const pulseAnimation = (cssVar)=>keyframes`
9
24
  0% {
10
25
  box-shadow: 0 0 0 0 color-mix(in srgb, var(${cssVar}) 20%, transparent);
@@ -185,15 +200,13 @@ const BaseContainer = styled.div`
185
200
  }}
186
201
  `;
187
202
  const BaseIconWrapper = styled.div`
188
- width: ${({ height, width, shape })=>{
189
- const dimension = height !== width && 'rectangle' === shape ? height : width;
190
- const scaleFactor = dimension ? dimension / 96 : 1;
191
- return `${72 * scaleFactor}px`;
192
- }};
193
- height: ${({ height, width, shape })=>{
194
- const scaleFactor = height ? height / 96 : 1;
195
- return height !== width && 'rectangle' !== shape ? `${84 * scaleFactor}px` : `${72 * scaleFactor}px`;
196
- }};
203
+ ${({ height, width, shape })=>{
204
+ const { iconWidth, iconHeight } = getIconDimensions(shape, height, width);
205
+ return css`
206
+ width: ${iconWidth}px;
207
+ height: ${iconHeight}px;
208
+ `;
209
+ }}
197
210
  display: flex;
198
211
  align-items: center;
199
212
  justify-content: center;
@@ -354,4 +367,19 @@ const BaseBadgeSlot = styled.div`
354
367
  }
355
368
  }}
356
369
  `;
357
- export { BaseBadgeSlot, BaseContainer, BaseHeader, BaseIconWrapper, BaseSubHeader, BaseTextContainer, EditableLabel, EmptyLabelPlaceholder };
370
+ const BaseSkeletonIcon = styled(ApSkeleton, {
371
+ shouldForwardProp: (prop)=>'shape' !== prop && 'nodeHeight' !== prop && 'nodeWidth' !== prop
372
+ })`
373
+ flex-grow: 0;
374
+ flex-shrink: 0;
375
+ ${({ shape, nodeHeight, nodeWidth })=>{
376
+ const { iconWidth, iconHeight } = getIconDimensions(shape, nodeHeight, nodeWidth);
377
+ const isCircle = 'circle' === shape;
378
+ return css`
379
+ width: ${iconWidth}px;
380
+ height: ${iconHeight}px;
381
+ border-radius: ${isCircle ? '50%' : '8px'};
382
+ `;
383
+ }}
384
+ `;
385
+ export { BaseBadgeSlot, BaseContainer, BaseHeader, BaseIconWrapper, BaseSkeletonIcon, BaseSubHeader, BaseTextContainer, EditableLabel, EmptyLabelPlaceholder };
@@ -16,6 +16,7 @@ export interface BaseNodeData extends Record<string, unknown> {
16
16
  };
17
17
  useSmartHandles?: boolean;
18
18
  isCollapsed?: boolean;
19
+ loading?: boolean;
19
20
  }
20
21
  export interface NodeAdornments {
21
22
  topLeft?: React.ReactNode;
@@ -1 +1 @@
1
- {"version":3,"file":"BaseNode.types.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/BaseNode/BaseNode.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAE9D,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,QAAQ,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAEpE,MAAM,WAAW,YAAa,SAAQ,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAC3D,OAAO,CAAC,EAAE;QACR,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,KAAK,CAAC,EAAE,SAAS,CAAC;QAClB,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,cAAc,CAAC,EAAE,MAAM,CAAC;QACxB,kBAAkB,CAAC,EAAE,MAAM,CAAC;QAC5B,SAAS,CAAC,EAAE,MAAM,CAAC;KACpB,CAAC;IAOF,eAAe,CAAC,EAAE,OAAO,CAAC;IAM1B,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AAED,MAAM,WAAW,cAAc;IAC7B,OAAO,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,UAAU,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC7B,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC/B;AAED,MAAM,WAAW,iBAAiB;IAChC,MAAM,EAAE,MAAM,CAAC;IACf,cAAc,CAAC,EAAE,cAAc,CAAC;IAChC,eAAe,CAAC,EAAE,eAAe,CAAC;IAClC,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB"}
1
+ {"version":3,"file":"BaseNode.types.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/BaseNode/BaseNode.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAE9D,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,QAAQ,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAEpE,MAAM,WAAW,YAAa,SAAQ,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAC3D,OAAO,CAAC,EAAE;QACR,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,KAAK,CAAC,EAAE,SAAS,CAAC;QAClB,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,cAAc,CAAC,EAAE,MAAM,CAAC;QACxB,kBAAkB,CAAC,EAAE,MAAM,CAAC;QAC5B,SAAS,CAAC,EAAE,MAAM,CAAC;KACpB,CAAC;IAOF,eAAe,CAAC,EAAE,OAAO,CAAC;IAM1B,WAAW,CAAC,EAAE,OAAO,CAAC;IAOtB,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAED,MAAM,WAAW,cAAc;IAC7B,OAAO,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,UAAU,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC7B,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC/B;AAED,MAAM,WAAW,iBAAiB;IAChC,MAAM,EAAE,MAAM,CAAC;IACf,cAAc,CAAC,EAAE,cAAc,CAAC;IAChC,eAAe,CAAC,EAAE,eAAe,CAAC;IAClC,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uipath/apollo-react",
3
- "version": "3.51.2",
3
+ "version": "3.52.0",
4
4
  "description": "Apollo Design System - React component library with Material UI theming",
5
5
  "repository": {
6
6
  "type": "git",
@@ -201,7 +201,7 @@
201
201
  "zod": "^4.3.5",
202
202
  "zustand": "^5.0.9",
203
203
  "@uipath/apollo-core": "5.7.1",
204
- "@uipath/apollo-wind": "0.13.0"
204
+ "@uipath/apollo-wind": "0.14.0"
205
205
  },
206
206
  "devDependencies": {
207
207
  "@lingui/cli": "^5.6.1",