@wise/dynamic-flow-client 3.17.0 → 3.18.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.
package/build/main.js CHANGED
@@ -144,10 +144,10 @@ var init_clsx = __esm({
144
144
  }
145
145
  });
146
146
 
147
- // ../../node_modules/.pnpm/@wise+art@2.14.0_@transferwise+neptune-css@14.15.0_@types+react@18.3.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wise/art/dist/index-93a0c34e.esm.js
147
+ // ../../node_modules/.pnpm/@wise+art@2.14.0_@transferwise+neptune-css@14.18.0_@types+react@18.3.4_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wise/art/dist/index-93a0c34e.esm.js
148
148
  var import_react7, import_jsx_runtime17, unknownFlagName, Flag, Sizes, ImageSizes, imageSizes, Assets, RenderMode;
149
149
  var init_index_93a0c34e_esm = __esm({
150
- "../../node_modules/.pnpm/@wise+art@2.14.0_@transferwise+neptune-css@14.15.0_@types+react@18.3.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wise/art/dist/index-93a0c34e.esm.js"() {
150
+ "../../node_modules/.pnpm/@wise+art@2.14.0_@transferwise+neptune-css@14.18.0_@types+react@18.3.4_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wise/art/dist/index-93a0c34e.esm.js"() {
151
151
  "use strict";
152
152
  init_clsx();
153
153
  import_react7 = require("react");
@@ -1652,9 +1652,9 @@ var markdownComponentToProps = ({
1652
1652
  });
1653
1653
 
1654
1654
  // src/revamp/renderers/mappers/modalComponentToProps.ts
1655
- var modalComponentToProps = ({ control, margin, trigger }, components) => ({
1655
+ var modalComponentToProps = ({ content, control, margin, trigger }, components) => ({
1656
1656
  type: "modal",
1657
- content: { components },
1657
+ content: { components, title: content.title },
1658
1658
  control,
1659
1659
  margin,
1660
1660
  trigger
@@ -9940,13 +9940,14 @@ var createModalComponent = (modalProps) => __spreadProps(__spreadValues({
9940
9940
 
9941
9941
  // src/revamp/domain/mappers/layout/modalLayoutToComponent.ts
9942
9942
  var modalLayoutToComponent = (uid, { content, control, margin = "md", trigger }, mapperProps) => {
9943
- const { components } = content;
9943
+ const { components, title } = content;
9944
9944
  return createModalComponent({
9945
9945
  uid,
9946
9946
  content: {
9947
9947
  components: components.map(
9948
9948
  (component, index) => mapLayoutToComponent(`${uid}.modal-${index}`, component, mapperProps)
9949
- )
9949
+ ),
9950
+ title
9950
9951
  },
9951
9952
  control,
9952
9953
  margin,
@@ -11310,7 +11311,7 @@ var DateInputRenderer_default = DateInputRenderer;
11310
11311
  // ../renderers/src/DecisionRenderer.tsx
11311
11312
  var import_components9 = require("@transferwise/components");
11312
11313
 
11313
- // ../../node_modules/.pnpm/@wise+art@2.14.0_@transferwise+neptune-css@14.15.0_@types+react@18.3.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wise/art/dist/index.esm.js
11314
+ // ../../node_modules/.pnpm/@wise+art@2.14.0_@transferwise+neptune-css@14.18.0_@types+react@18.3.4_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wise/art/dist/index.esm.js
11314
11315
  init_index_93a0c34e_esm();
11315
11316
  init_clsx();
11316
11317
  var import_react8 = require("react");
@@ -11647,6 +11648,7 @@ var ModalRenderer = {
11647
11648
  var ModalRenderer_default = ModalRenderer;
11648
11649
  function DFModal({ content, margin, trigger }) {
11649
11650
  const [visible, setVisible] = (0, import_react10.useState)(false);
11651
+ const { components, title } = content;
11650
11652
  return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("div", { className: getMargin(margin), children: [
11651
11653
  /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_components17.Button, { priority: "tertiary", block: true, onClick: () => setVisible(true), children: trigger.title }),
11652
11654
  /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
@@ -11655,7 +11657,8 @@ function DFModal({ content, margin, trigger }) {
11655
11657
  scroll: "content",
11656
11658
  open: visible,
11657
11659
  size: "lg",
11658
- body: content.components,
11660
+ title,
11661
+ body: components,
11659
11662
  onClose: () => setVisible(false)
11660
11663
  }
11661
11664
  )
@@ -18087,6 +18090,7 @@ function DynamicModal(props) {
18087
18090
  scroll: "content",
18088
18091
  open: visible,
18089
18092
  size: "lg",
18093
+ title: component.content.title,
18090
18094
  body: /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(
18091
18095
  DynamicLayout_default,
18092
18096
  __spreadProps(__spreadValues({}, props), {