@uipath/apollo-react 4.31.0 → 4.32.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.
@@ -7,6 +7,7 @@ import { memo, useCallback, useEffect, useMemo, useRef, useState } from "react";
7
7
  import react_markdown from "react-markdown";
8
8
  import remark_breaks from "remark-breaks";
9
9
  import remark_gfm from "remark-gfm";
10
+ import { useSafeLingui } from "../../../i18n/index.js";
10
11
  import { GRID_SPACING } from "../../constants.js";
11
12
  import { NodeViewportOverlay } from "../NodeViewportOverlay.js";
12
13
  import { NodeToolbar } from "../Toolbar/index.js";
@@ -20,6 +21,7 @@ import { useScrollCapture } from "./useScrollCapture.js";
20
21
  const minWidth = 8 * GRID_SPACING;
21
22
  const minHeight = 8 * GRID_SPACING;
22
23
  const StickyNoteNodeComponent = ({ id, data, selected, dragging, placeholder = 'Add text', renderPlaceholderOnSelect = false, readOnly = false, onContentChange, onColorChange, onResize })=>{
24
+ const { _ } = useSafeLingui();
23
25
  const { updateNodeData, deleteElements } = useReactFlow();
24
26
  const [isEditing, setIsEditing] = useState(!readOnly && (data.autoFocus ?? false));
25
27
  const [isResizing, setIsResizing] = useState(false);
@@ -224,7 +226,10 @@ const StickyNoteNodeComponent = ({ id, data, selected, dragging, placeholder = '
224
226
  icon: "trash",
225
227
  size: 14
226
228
  }),
227
- label: 'Delete',
229
+ label: _({
230
+ id: 'sticky-note.toolbar.delete',
231
+ message: 'Delete'
232
+ }),
228
233
  onAction: handleDelete
229
234
  },
230
235
  {
@@ -233,7 +238,10 @@ const StickyNoteNodeComponent = ({ id, data, selected, dragging, placeholder = '
233
238
  icon: "pencil",
234
239
  size: 14
235
240
  }),
236
- label: 'Edit',
241
+ label: _({
242
+ id: 'sticky-note.toolbar.edit',
243
+ message: 'Edit'
244
+ }),
237
245
  onAction: handleEditClick
238
246
  },
239
247
  {
@@ -251,7 +259,10 @@ const StickyNoteNodeComponent = ({ id, data, selected, dragging, placeholder = '
251
259
  border: '1px solid transparent'
252
260
  }
253
261
  }),
254
- label: 'Color',
262
+ label: _({
263
+ id: 'sticky-note.toolbar.color',
264
+ message: 'Color'
265
+ }),
255
266
  onAction: handleToggleColorPicker
256
267
  }
257
268
  ];
@@ -263,6 +274,7 @@ const StickyNoteNodeComponent = ({ id, data, selected, dragging, placeholder = '
263
274
  align: 'center'
264
275
  };
265
276
  }, [
277
+ _,
266
278
  handleEditClick,
267
279
  handleToggleColorPicker,
268
280
  color,
@@ -26,7 +26,7 @@ __webpack_require__.r(__webpack_exports__);
26
26
  __webpack_require__.d(__webpack_exports__, {
27
27
  messages: ()=>messages
28
28
  });
29
- const messages = JSON.parse("{\"stage-node.add-first-task\":[\"Add first task\"],\"stage-node.add-task\":[\"Add task\"],\"stage-node.add-task-to-parallel-group-above\":[\"Add task to parallel group above\"],\"stage-node.add-task-to-parallel-group-below\":[\"Add task to parallel group below\"],\"stage-node.adhoc-tasks\":[\"Ad hoc tasks\"],\"stage-node.create-parallel-group-with-task-above\":[\"Create parallel group with task above\"],\"stage-node.create-parallel-group-with-task-below\":[\"Create parallel group with task below\"],\"stage-node.delete-task\":[\"Delete task\"],\"stage-node.event-driven-tasks\":[\"Event-driven tasks\"],\"stage-node.move-down\":[\"Move down\"],\"stage-node.move-up\":[\"Move up\"],\"stage-node.no-tasks\":[\"No tasks\"],\"stage-node.parallel\":[\"Parallel\"],\"stage-node.remove-from-parallel-group\":[\"Remove from parallel group\"],\"stage-node.remove-group-from-stage\":[\"Remove group from stage\"],\"stage-node.replace-task\":[\"Replace task\"],\"stage-node.ungroup-parallel-tasks\":[\"Ungroup parallel tasks\"],\"stage-node.untitled-stage\":[\"Untitled stage\"],\"sticky-note.formatting.bold\":[\"Bold (\",[\"boldShortcut\"],\")\"],\"sticky-note.formatting.bullet-list\":[\"Bullet list\"],\"sticky-note.formatting.italic\":[\"Italic (\",[\"italicShortcut\"],\")\"],\"sticky-note.formatting.numbered-list\":[\"Numbered list\"],\"sticky-note.formatting.strikethrough\":[\"Strikethrough (\",[\"strikethroughShortcut\"],\")\"],\"sticky-note.formatting.toolbar\":[\"Text formatting\"],\"toolbox.search\":[\"Search\"]}");
29
+ const messages = JSON.parse("{\"stage-node.add-first-task\":[\"Add first task\"],\"stage-node.add-task\":[\"Add task\"],\"stage-node.add-task-to-parallel-group-above\":[\"Add task to parallel group above\"],\"stage-node.add-task-to-parallel-group-below\":[\"Add task to parallel group below\"],\"stage-node.adhoc-tasks\":[\"Ad hoc tasks\"],\"stage-node.create-parallel-group-with-task-above\":[\"Create parallel group with task above\"],\"stage-node.create-parallel-group-with-task-below\":[\"Create parallel group with task below\"],\"stage-node.delete-task\":[\"Delete task\"],\"stage-node.event-driven-tasks\":[\"Event-driven tasks\"],\"stage-node.move-down\":[\"Move down\"],\"stage-node.move-up\":[\"Move up\"],\"stage-node.no-tasks\":[\"No tasks\"],\"stage-node.parallel\":[\"Parallel\"],\"stage-node.remove-from-parallel-group\":[\"Remove from parallel group\"],\"stage-node.remove-group-from-stage\":[\"Remove group from stage\"],\"stage-node.replace-task\":[\"Replace task\"],\"stage-node.status.cancelled\":[\"Cancelled\"],\"stage-node.status.completed\":[\"Completed\"],\"stage-node.status.failed\":[\"Failed\"],\"stage-node.status.in-progress\":[\"In progress\"],\"stage-node.status.not-executed\":[\"Not started\"],\"stage-node.status.paused\":[\"Paused\"],\"stage-node.status.terminated\":[\"Terminated\"],\"stage-node.status.warning\":[\"Warning\"],\"stage-node.ungroup-parallel-tasks\":[\"Ungroup parallel tasks\"],\"stage-node.untitled-stage\":[\"Untitled stage\"],\"sticky-note.formatting.bold\":[\"Bold (\",[\"boldShortcut\"],\")\"],\"sticky-note.formatting.bullet-list\":[\"Bullet list\"],\"sticky-note.formatting.italic\":[\"Italic (\",[\"italicShortcut\"],\")\"],\"sticky-note.formatting.numbered-list\":[\"Numbered list\"],\"sticky-note.formatting.strikethrough\":[\"Strikethrough (\",[\"strikethroughShortcut\"],\")\"],\"sticky-note.formatting.toolbar\":[\"Text formatting\"],\"sticky-note.toolbar.color\":[\"Color\"],\"sticky-note.toolbar.delete\":[\"Delete\"],\"sticky-note.toolbar.edit\":[\"Edit\"],\"toolbox.search\":[\"Search\"]}");
30
30
  exports.messages = __webpack_exports__.messages;
31
31
  for(var __rspack_i in __webpack_exports__)if (-1 === [
32
32
  "messages"
@@ -1 +1 @@
1
- {"version":3,"file":"en.d.ts","sourceRoot":"","sources":["../../../src/canvas/locales/en.ts"],"names":[],"mappings":"AAAkB,OAAO,KAAI,EAAC,QAAQ,EAAC,MAAI,cAAc,CAAC;AAAA,eAAO,MAAM,QAAQ,EAAsgD,QAAQ,CAAC"}
1
+ {"version":3,"file":"en.d.ts","sourceRoot":"","sources":["../../../src/canvas/locales/en.ts"],"names":[],"mappings":"AAAkB,OAAO,KAAI,EAAC,QAAQ,EAAC,MAAI,cAAc,CAAC;AAAA,eAAO,MAAM,QAAQ,EAA+/D,QAAQ,CAAC"}
@@ -1,2 +1,2 @@
1
- const messages = JSON.parse("{\"stage-node.add-first-task\":[\"Add first task\"],\"stage-node.add-task\":[\"Add task\"],\"stage-node.add-task-to-parallel-group-above\":[\"Add task to parallel group above\"],\"stage-node.add-task-to-parallel-group-below\":[\"Add task to parallel group below\"],\"stage-node.adhoc-tasks\":[\"Ad hoc tasks\"],\"stage-node.create-parallel-group-with-task-above\":[\"Create parallel group with task above\"],\"stage-node.create-parallel-group-with-task-below\":[\"Create parallel group with task below\"],\"stage-node.delete-task\":[\"Delete task\"],\"stage-node.event-driven-tasks\":[\"Event-driven tasks\"],\"stage-node.move-down\":[\"Move down\"],\"stage-node.move-up\":[\"Move up\"],\"stage-node.no-tasks\":[\"No tasks\"],\"stage-node.parallel\":[\"Parallel\"],\"stage-node.remove-from-parallel-group\":[\"Remove from parallel group\"],\"stage-node.remove-group-from-stage\":[\"Remove group from stage\"],\"stage-node.replace-task\":[\"Replace task\"],\"stage-node.ungroup-parallel-tasks\":[\"Ungroup parallel tasks\"],\"stage-node.untitled-stage\":[\"Untitled stage\"],\"sticky-note.formatting.bold\":[\"Bold (\",[\"boldShortcut\"],\")\"],\"sticky-note.formatting.bullet-list\":[\"Bullet list\"],\"sticky-note.formatting.italic\":[\"Italic (\",[\"italicShortcut\"],\")\"],\"sticky-note.formatting.numbered-list\":[\"Numbered list\"],\"sticky-note.formatting.strikethrough\":[\"Strikethrough (\",[\"strikethroughShortcut\"],\")\"],\"sticky-note.formatting.toolbar\":[\"Text formatting\"],\"toolbox.search\":[\"Search\"]}");
1
+ const messages = JSON.parse("{\"stage-node.add-first-task\":[\"Add first task\"],\"stage-node.add-task\":[\"Add task\"],\"stage-node.add-task-to-parallel-group-above\":[\"Add task to parallel group above\"],\"stage-node.add-task-to-parallel-group-below\":[\"Add task to parallel group below\"],\"stage-node.adhoc-tasks\":[\"Ad hoc tasks\"],\"stage-node.create-parallel-group-with-task-above\":[\"Create parallel group with task above\"],\"stage-node.create-parallel-group-with-task-below\":[\"Create parallel group with task below\"],\"stage-node.delete-task\":[\"Delete task\"],\"stage-node.event-driven-tasks\":[\"Event-driven tasks\"],\"stage-node.move-down\":[\"Move down\"],\"stage-node.move-up\":[\"Move up\"],\"stage-node.no-tasks\":[\"No tasks\"],\"stage-node.parallel\":[\"Parallel\"],\"stage-node.remove-from-parallel-group\":[\"Remove from parallel group\"],\"stage-node.remove-group-from-stage\":[\"Remove group from stage\"],\"stage-node.replace-task\":[\"Replace task\"],\"stage-node.status.cancelled\":[\"Cancelled\"],\"stage-node.status.completed\":[\"Completed\"],\"stage-node.status.failed\":[\"Failed\"],\"stage-node.status.in-progress\":[\"In progress\"],\"stage-node.status.not-executed\":[\"Not started\"],\"stage-node.status.paused\":[\"Paused\"],\"stage-node.status.terminated\":[\"Terminated\"],\"stage-node.status.warning\":[\"Warning\"],\"stage-node.ungroup-parallel-tasks\":[\"Ungroup parallel tasks\"],\"stage-node.untitled-stage\":[\"Untitled stage\"],\"sticky-note.formatting.bold\":[\"Bold (\",[\"boldShortcut\"],\")\"],\"sticky-note.formatting.bullet-list\":[\"Bullet list\"],\"sticky-note.formatting.italic\":[\"Italic (\",[\"italicShortcut\"],\")\"],\"sticky-note.formatting.numbered-list\":[\"Numbered list\"],\"sticky-note.formatting.strikethrough\":[\"Strikethrough (\",[\"strikethroughShortcut\"],\")\"],\"sticky-note.formatting.toolbar\":[\"Text formatting\"],\"sticky-note.toolbar.color\":[\"Color\"],\"sticky-note.toolbar.delete\":[\"Delete\"],\"sticky-note.toolbar.edit\":[\"Edit\"],\"toolbox.search\":[\"Search\"]}");
2
2
  export { messages };