@incodetech/welcome 1.85.0-20251216195123.0 → 1.85.0-20251217155726.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.
@@ -24,3 +24,7 @@ export declare const VERIFICATION_STATES: {
24
24
  };
25
25
  export declare const COUNTRIES_WITH_CNPJ_VALIDATION: readonly ["BR"];
26
26
  export declare const COUNTRIES_WITH_SPECIAL_TAX_ID_RULES: readonly ["NG", "CM", "KE"];
27
+ export declare const BUSINESS_NAME_OPTIONAL_COUNTRIES: string[];
28
+ export declare const ADDRESS_OPTIONAL_COUNTRIES: string[];
29
+ export declare const UBO_OPTIONAL_COUNTRIES: string[];
30
+ export declare const ADDRESS_FIELDS: string[];
@@ -6,3 +6,4 @@ export declare function getFieldName(moduleName: string): string;
6
6
  * Filters and sorts modules based on custom order
7
7
  */
8
8
  export declare function sortModulesByOrder(modules: string[], customOrder: readonly string[]): string[];
9
+ export declare const isFieldOptional: (fieldName: string, countryCode: string) => boolean;
@@ -7699,7 +7699,7 @@ function getProfile(Be) {
7699
7699
  throw new Error(`Profile not found for type: ${Be}`);
7700
7700
  return Le;
7701
7701
  }
7702
- const wasmVersion = "v2.12.44";
7702
+ const wasmVersion = "v2.12.45";
7703
7703
  function generateBundle() {
7704
7704
  const Be = getFeatureFlag("id_text_barcode_readability") ? PipelineProfileName.IdCapture_3_02 : getFeatureFlag("id_model_hebrew_back_id") ? PipelineProfileName.IdCapture_2_02 : PipelineProfileName.IdCapture_2_01, Le = PipelineProfileName.SelfieWithQualityMetrics, Ye = PipelineProfileName.SelfieVideoSelfie, tt = PipelineProfileName.IdVideoSelfie_2_01;
7705
7705
  return [
@@ -8282,7 +8282,7 @@ class MlWasmJSApi {
8282
8282
  );
8283
8283
  }
8284
8284
  }
8285
- const MlWasmJSApi$1 = MlWasmJSApi.getInstance(), version$4 = "1.85.0-20251216195123.0";
8285
+ const MlWasmJSApi$1 = MlWasmJSApi.getInstance(), version$4 = "1.85.0-20251217155726.0";
8286
8286
  function e$2(Be, Le) {
8287
8287
  return function(Ye, tt) {
8288
8288
  return Object.prototype.hasOwnProperty.call(Ye, tt);
@@ -354780,7 +354780,14 @@ const UBO_INPUT_LIMIT = 8, FIELD_ORDER = [
354780
354780
  VERIFYING: "verifying...",
354781
354781
  SUCCESS: "success",
354782
354782
  FAILED: "failed"
354783
- }, COUNTRIES_WITH_CNPJ_VALIDATION = ["BR"], COUNTRIES_WITH_SPECIAL_TAX_ID_RULES = ["NG", "CM", "KE"], CNPJ_FORMATTED_LENGTH = 18, CNPJ_CLEAN_LENGTH = 14, INVALID_CNPJ_PATTERNS = [
354783
+ }, COUNTRIES_WITH_CNPJ_VALIDATION = ["BR"], COUNTRIES_WITH_SPECIAL_TAX_ID_RULES = ["NG", "CM", "KE"], BUSINESS_NAME_OPTIONAL_COUNTRIES = ["BR"], ADDRESS_OPTIONAL_COUNTRIES = ["GB", "BR", "FR"], UBO_OPTIONAL_COUNTRIES = ["GB", "BR", "FR"], ADDRESS_FIELDS = [
354784
+ "street",
354785
+ "houseNo",
354786
+ "addressLine2",
354787
+ "city",
354788
+ "state",
354789
+ "postalCode"
354790
+ ], CNPJ_FORMATTED_LENGTH = 18, CNPJ_CLEAN_LENGTH = 14, INVALID_CNPJ_PATTERNS = [
354784
354791
  "00000000000000",
354785
354792
  "11111111111111",
354786
354793
  "22222222222222",
@@ -354990,7 +354997,7 @@ function sortModulesByOrder(Be, Le) {
354990
354997
  return nt !== -1 && ft !== -1 ? nt - ft : nt !== -1 ? -1 : ft !== -1 ? 1 : 0;
354991
354998
  });
354992
354999
  }
354993
- const sharedStyle$1 = lt`
355000
+ const isFieldOptional = (Be, Le) => Be === "businessName" ? BUSINESS_NAME_OPTIONAL_COUNTRIES.includes(Le) : ADDRESS_FIELDS.includes(Be) ? ADDRESS_OPTIONAL_COUNTRIES.includes(Le) : Be === "ubo" ? UBO_OPTIONAL_COUNTRIES.includes(Le) : !1, sharedStyle$1 = lt`
354994
355001
  background-color: transparent;
354995
355002
  width: 100%;
354996
355003
  border: none;
@@ -355085,7 +355092,7 @@ const sharedStyle$1 = lt`
355085
355092
  flow: Ye,
355086
355093
  token: tt
355087
355094
  }) => {
355088
- var $t;
355095
+ var Lt;
355089
355096
  const [nt, ft] = useState(
355090
355097
  VERIFICATION_STATES.IDLE
355091
355098
  ), { uboCount: ht, handleAddUbo: gt, extractUboNames: At } = useUboManagement(), {
@@ -355121,25 +355128,25 @@ const sharedStyle$1 = lt`
355121
355128
  screen: "EKYB",
355122
355129
  token: tt
355123
355130
  });
355124
- const Dt = Le ? Le.filter((Kt) => Kt === "ubos-user_input" ? (wt = !0, !1) : !0) : ($t = Ye == null ? void 0 : Ye.modules) == null ? void 0 : $t.filter(
355125
- (Kt) => Kt.includes("user_input") && !Kt.includes("socure") && Kt !== "ubos-user_input"
355126
- ), Pt = sortModulesByOrder(Dt || [], FIELD_ORDER), Nt = async (Kt) => {
355131
+ const Dt = Le ? Le.filter((Wt) => Wt === "ubos-user_input" ? (wt = !0, !1) : !0) : (Lt = Ye == null ? void 0 : Ye.modules) == null ? void 0 : Lt.filter(
355132
+ (Wt) => Wt.includes("user_input") && !Wt.includes("socure") && Wt !== "ubos-user_input"
355133
+ ), Pt = sortModulesByOrder(Dt || [], FIELD_ORDER), Nt = async (Wt) => {
355127
355134
  ft(VERIFICATION_STATES.VERIFYING);
355128
- const Vt = At(Kt), Ut = {
355129
- ...Kt,
355135
+ const $t = At(Wt), Kt = {
355136
+ ...Wt,
355130
355137
  plugins: ["ekyb"],
355131
- uboNames: Vt
355138
+ uboNames: $t
355132
355139
  };
355133
355140
  try {
355134
355141
  await sendEkyb({
355135
355142
  token: tt,
355136
- body: Ut
355143
+ body: Kt
355137
355144
  }), ft(VERIFICATION_STATES.SUCCESS);
355138
355145
  } catch {
355139
355146
  ft(VERIFICATION_STATES.FAILED);
355140
355147
  }
355141
355148
  Be();
355142
- }, Lt = Tt === "GB", Wt = Tt === "GB";
355149
+ };
355143
355150
  return /* @__PURE__ */ jsxRuntimeExports.jsxs(VerificationContainer, { children: [
355144
355151
  /* @__PURE__ */ jsxRuntimeExports.jsx(InformationVerificationTitle, { children: It("ekyb.title") }),
355145
355152
  /* @__PURE__ */ jsxRuntimeExports.jsxs(
@@ -355156,12 +355163,12 @@ const sharedStyle$1 = lt`
355156
355163
  errors: yt
355157
355164
  }
355158
355165
  ),
355159
- Pt.map((Kt) => {
355160
- const Vt = getFieldName(Kt);
355166
+ Pt.map((Wt) => {
355167
+ const $t = getFieldName(Wt), Kt = isFieldOptional($t, Tt);
355161
355168
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
355162
355169
  FieldInput,
355163
355170
  {
355164
- name: Vt,
355171
+ name: $t,
355165
355172
  country: Tt,
355166
355173
  state: Rt,
355167
355174
  isUnitedStates: Bt,
@@ -355169,9 +355176,9 @@ const sharedStyle$1 = lt`
355169
355176
  setValue: Ct,
355170
355177
  trigger: vt,
355171
355178
  errors: yt,
355172
- optional: Wt
355179
+ optional: Kt
355173
355180
  },
355174
- Vt
355181
+ $t
355175
355182
  );
355176
355183
  }),
355177
355184
  wt && /* @__PURE__ */ jsxRuntimeExports.jsx(
@@ -355180,7 +355187,7 @@ const sharedStyle$1 = lt`
355180
355187
  uboCount: ht,
355181
355188
  register: xt,
355182
355189
  errors: yt,
355183
- optional: Lt
355190
+ optional: isFieldOptional("ubo", Tt)
355184
355191
  }
355185
355192
  ),
355186
355193
  /* @__PURE__ */ jsxRuntimeExports.jsxs(ButtonsContainer$1, { children: [