@wise/dynamic-flow-client 3.26.1 → 3.27.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.mjs CHANGED
@@ -706,7 +706,7 @@ var hu_default = {
706
706
  "dynamicFlows.ExternalConfirmation.open": "Megnyit\xE1s \xFAj lapon",
707
707
  "dynamicFlows.ExternalConfirmation.title": "Meger\u0151s\xEDt\xE9s",
708
708
  "dynamicFlows.FileUploadSchema.maxFileSizeError": "Sajnos ez a f\xE1jl t\xFAl nagy. K\xE9r\xFCnk, t\xF6lts fel egy kisebb f\xE1jlt.",
709
- "dynamicFlows.FileUploadSchema.wrongFileTypeError": "Sorry, that file format is not supported. Please upload a different file.",
709
+ "dynamicFlows.FileUploadSchema.wrongFileTypeError": "Sajnos ez a f\xE1jlform\xE1tum nem t\xE1mogatott. K\xE9r\xFCnk, t\xF6lts fel egy m\xE1sik f\xE1jlt.",
710
710
  "dynamicFlows.Help.ariaLabel": "Kattints ide tov\xE1bbi inform\xE1ci\xF3\xE9rt.",
711
711
  "dynamicFlows.MultiSelect.summary": "{first} \xE9s tov\xE1bbi {count}",
712
712
  "dynamicFlows.MultipleFileUploadSchema.maxFileSizeError": "Sajnos ez a f\xE1jl t\xFAl nagy. K\xE9r\xFCnk, t\xF6lts fel egy kisebb f\xE1jlt.",
@@ -918,7 +918,7 @@ var pl_default = {
918
918
  "dynamicFlows.ExternalConfirmation.open": "Otw\xF3rz w nowej zak\u0142adce",
919
919
  "dynamicFlows.ExternalConfirmation.title": "Potwierd\u017A",
920
920
  "dynamicFlows.FileUploadSchema.maxFileSizeError": "Przepraszamy, ten plik jest zbyt du\u017Cy. Prze\u015Blij mniejszy plik.",
921
- "dynamicFlows.FileUploadSchema.wrongFileTypeError": "Sorry, that file format is not supported. Please upload a different file.",
921
+ "dynamicFlows.FileUploadSchema.wrongFileTypeError": "Przepraszamy, ten format pliku nie jest obs\u0142ugiwany. Prosimy przes\u0142a\u0107 inny plik.",
922
922
  "dynamicFlows.Help.ariaLabel": "Kliknij tutaj, \u017Ceby uzyska\u0107 wi\u0119cej informacji.",
923
923
  "dynamicFlows.MultiSelect.summary": "{first} oraz {count} wi\u0119cej",
924
924
  "dynamicFlows.MultipleFileUploadSchema.maxFileSizeError": "Przepraszamy, ten plik jest zbyt du\u017Cy. Prze\u015Blij mniejszy plik.",
@@ -1183,7 +1183,7 @@ var tr_default = {
1183
1183
  "dynamicFlows.ExternalConfirmation.open": "Yeni sekmede a\xE7",
1184
1184
  "dynamicFlows.ExternalConfirmation.title": "L\xFCtfen onaylay\u0131n",
1185
1185
  "dynamicFlows.FileUploadSchema.maxFileSizeError": "\xDCzg\xFCn\xFCz, bu dosya \xE7ok b\xFCy\xFCk. L\xFCtfen daha k\xFC\xE7\xFCk bir dosya y\xFCkleyin.",
1186
- "dynamicFlows.FileUploadSchema.wrongFileTypeError": "Sorry, that file format is not supported. Please upload a different file.",
1186
+ "dynamicFlows.FileUploadSchema.wrongFileTypeError": "\xDCzg\xFCn\xFCz, bu dosya bi\xE7imi desteklenmiyor. L\xFCtfen farkl\u0131 bir dosya y\xFCkleyin.",
1187
1187
  "dynamicFlows.Help.ariaLabel": "Ayr\u0131nt\u0131lar i\xE7in t\u0131klay\u0131n.",
1188
1188
  "dynamicFlows.MultiSelect.summary": "{first} ve {count} daha",
1189
1189
  "dynamicFlows.MultipleFileUploadSchema.maxFileSizeError": "\xDCzg\xFCn\xFCz, bu dosya \xE7ok b\xFCy\xFCk. L\xFCtfen daha k\xFC\xE7\xFCk bir dosya y\xFCkleyin.",
@@ -12172,6 +12172,7 @@ function MultiSelectInputRendererComponent(props) {
12172
12172
  const [stagedIndices, setStagedIndices] = useState5();
12173
12173
  const {
12174
12174
  id,
12175
+ autoComplete,
12175
12176
  description,
12176
12177
  disabled,
12177
12178
  label,
@@ -12210,6 +12211,7 @@ function MultiSelectInputRendererComponent(props) {
12210
12211
  };
12211
12212
  return /* @__PURE__ */ jsx34(SelectInputOptionContent, __spreadValues({}, contentProps));
12212
12213
  };
12214
+ const extraProps = { autoComplete };
12213
12215
  return /* @__PURE__ */ jsx34(
12214
12216
  FieldInput_default,
12215
12217
  {
@@ -12220,7 +12222,7 @@ function MultiSelectInputRendererComponent(props) {
12220
12222
  validation: validationState,
12221
12223
  children: /* @__PURE__ */ jsx34(
12222
12224
  SelectInput,
12223
- {
12225
+ __spreadValues({
12224
12226
  id,
12225
12227
  items: options.map((option, index) => {
12226
12228
  var _a, _b, _c;
@@ -12249,7 +12251,7 @@ function MultiSelectInputRendererComponent(props) {
12249
12251
  setStagedIndices(void 0);
12250
12252
  }
12251
12253
  }
12252
- }
12254
+ }, extraProps)
12253
12255
  )
12254
12256
  }
12255
12257
  );
@@ -12951,20 +12953,26 @@ function SelectTriggerMedia({ icon, image }) {
12951
12953
  if (image == null ? void 0 : image.url) {
12952
12954
  return null;
12953
12955
  }
12954
- if (icon && "name" in icon) {
12956
+ if (isFlagIcon2(icon)) {
12955
12957
  return /* @__PURE__ */ jsx46(Avatar3, { type: AvatarType3.ICON, size: 24, children: /* @__PURE__ */ jsx46(DynamicIcon_default, { name: icon.name }) });
12956
12958
  }
12959
+ if (isNamedIcon2(icon)) {
12960
+ return /* @__PURE__ */ jsx46(DynamicIcon_default, { name: icon.name });
12961
+ }
12957
12962
  if (icon && "text" in icon) {
12958
12963
  return /* @__PURE__ */ jsx46(Avatar3, { type: AvatarType3.ICON, size: 24, children: icon.text });
12959
12964
  }
12960
12965
  return null;
12961
12966
  }
12967
+ var isNamedIcon2 = (icon) => icon ? "name" in icon : false;
12968
+ var isFlagIcon2 = (icon) => isNamedIcon2(icon) && icon.name.startsWith("flag-");
12962
12969
 
12963
12970
  // ../renderers/src/SelectInputRenderer/SelectInputRendererComponent.tsx
12964
12971
  import { Fragment as Fragment8, jsx as jsx47, jsxs as jsxs16 } from "react/jsx-runtime";
12965
12972
  function SelectInputRendererComponent(props) {
12966
12973
  const {
12967
12974
  id,
12975
+ autoComplete,
12968
12976
  children,
12969
12977
  description,
12970
12978
  disabled,
@@ -13004,6 +13012,7 @@ function SelectInputRendererComponent(props) {
13004
13012
  };
13005
13013
  return /* @__PURE__ */ jsx47(SelectInputOptionContent2, __spreadValues({}, contentProps));
13006
13014
  };
13015
+ const extraProps = { autoComplete };
13007
13016
  return /* @__PURE__ */ jsxs16(Fragment8, { children: [
13008
13017
  /* @__PURE__ */ jsx47(
13009
13018
  FieldInput_default,
@@ -13015,7 +13024,7 @@ function SelectInputRendererComponent(props) {
13015
13024
  validation: validationState,
13016
13025
  children: /* @__PURE__ */ jsx47(
13017
13026
  SelectInput2,
13018
- {
13027
+ __spreadValues({
13019
13028
  name: id,
13020
13029
  placeholder,
13021
13030
  items,
@@ -13025,7 +13034,7 @@ function SelectInputRendererComponent(props) {
13025
13034
  filterable: items.length >= 8,
13026
13035
  onChange: onSelect,
13027
13036
  onClear: required ? void 0 : () => onSelect(null)
13028
- }
13037
+ }, extraProps)
13029
13038
  )
13030
13039
  }
13031
13040
  ),
@@ -15040,9 +15049,9 @@ import { Avatar as Avatar5, AvatarType as AvatarType4 } from "@transferwise/comp
15040
15049
 
15041
15050
  // src/legacy/layout/icon/FlagIcon.tsx
15042
15051
  import { jsx as jsx66 } from "react/jsx-runtime";
15043
- var isFlagIcon2 = (name) => name.startsWith("flag-");
15052
+ var isFlagIcon3 = (name) => name.startsWith("flag-");
15044
15053
  function FlagIcon2({ name }) {
15045
- if (!isFlagIcon2(name)) {
15054
+ if (!isFlagIcon3(name)) {
15046
15055
  return null;
15047
15056
  }
15048
15057
  const code = name.substring(5);
@@ -15052,12 +15061,12 @@ function FlagIcon2({ name }) {
15052
15061
  // src/legacy/layout/icon/NamedIcon.tsx
15053
15062
  import * as icons2 from "@transferwise/icons";
15054
15063
  import { jsx as jsx67 } from "react/jsx-runtime";
15055
- var isNamedIcon2 = (name) => {
15064
+ var isNamedIcon3 = (name) => {
15056
15065
  const iconName = toCapitalisedCamelCase2(name);
15057
15066
  return Object.keys(icons2).includes(iconName);
15058
15067
  };
15059
15068
  function NamedIcon2({ name }) {
15060
- if (!isNamedIcon2(name)) {
15069
+ if (!isNamedIcon3(name)) {
15061
15070
  return null;
15062
15071
  }
15063
15072
  const iconName = toCapitalisedCamelCase2(name);
@@ -15070,16 +15079,16 @@ var capitaliseFirstChar2 = (value) => `${value[0].toUpperCase()}${value.slice(1)
15070
15079
  // src/legacy/layout/icon/DynamicIcon.tsx
15071
15080
  import { jsx as jsx68 } from "react/jsx-runtime";
15072
15081
  function DynamicIcon2({ type }) {
15073
- if (isFlagIcon2(type)) {
15082
+ if (isFlagIcon3(type)) {
15074
15083
  return /* @__PURE__ */ jsx68(FlagIcon2, { name: type });
15075
15084
  }
15076
- if (isNamedIcon2(type)) {
15085
+ if (isNamedIcon3(type)) {
15077
15086
  return /* @__PURE__ */ jsx68(NamedIcon2, { name: type });
15078
15087
  }
15079
15088
  return null;
15080
15089
  }
15081
15090
  function isValidIconName(name) {
15082
- return isNamedIcon2(name) || isFlagIcon2(name);
15091
+ return isNamedIcon3(name) || isFlagIcon3(name);
15083
15092
  }
15084
15093
  var DynamicIcon_default2 = DynamicIcon2;
15085
15094
 
@@ -15822,7 +15831,7 @@ var mapImage = (image) => {
15822
15831
  return null;
15823
15832
  };
15824
15833
  var getIconPropertyForSelectOption = (icon) => {
15825
- if ((icon == null ? void 0 : icon.name) && isFlagIcon2(icon.name)) {
15834
+ if ((icon == null ? void 0 : icon.name) && isFlagIcon3(icon.name)) {
15826
15835
  return {
15827
15836
  icon: /* @__PURE__ */ jsx80(Flag, { code: icon.name.substring(5), intrinsicSize: 24 })
15828
15837
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wise/dynamic-flow-client",
3
- "version": "3.26.1",
3
+ "version": "3.27.0",
4
4
  "description": "Dynamic Flow web client",
5
5
  "license": "Apache-2.0",
6
6
  "main": "./build/main.min.js",
@@ -83,8 +83,8 @@
83
83
  "tsx": "4.19.2",
84
84
  "typescript": "5.6.3",
85
85
  "webpack": "5.96.1",
86
- "@wise/dynamic-flow-renderers": "0.0.0",
87
- "@wise/dynamic-flow-fixtures": "0.0.1"
86
+ "@wise/dynamic-flow-fixtures": "0.0.1",
87
+ "@wise/dynamic-flow-renderers": "0.0.0"
88
88
  },
89
89
  "peerDependencies": {
90
90
  "@transferwise/components": "^46.31",