@adyen/kyc-components 2.7.0 → 2.7.1

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.
@@ -20706,11 +20706,16 @@ function PayoutDetailsDropinComponent({
20706
20706
  } = useStateContext();
20707
20707
  const formValidity = currentState.validityByForm;
20708
20708
  useEffect(() => {
20709
- var _a2, _b2;
20709
+ var _a2, _b2, _c2, _d;
20710
+ const currentCountry = ((_b2 = (_a2 = currentState == null ? void 0 : currentState.data) == null ? void 0 : _a2.payoutVerificationMethod) == null ? void 0 : _b2.bankCountry) ?? defaultPayoutCountry;
20710
20711
  setData({
20711
- ...currentState.data
20712
+ ...currentState.data,
20713
+ payoutAccountDetails: {
20714
+ ...(_c2 = currentState.data) == null ? void 0 : _c2.payoutAccountDetails,
20715
+ currency: (_d = currencyByCountry[currentCountry]) == null ? void 0 : _d[0]
20716
+ }
20712
20717
  });
20713
- setBankAccountCountry(((_b2 = (_a2 = currentState == null ? void 0 : currentState.data) == null ? void 0 : _a2.payoutVerificationMethod) == null ? void 0 : _b2.bankCountry) ?? defaultPayoutCountry);
20718
+ setBankAccountCountry(currentCountry);
20714
20719
  onChange == null ? void 0 : onChange(currentState);
20715
20720
  }, [currentState, onChange]);
20716
20721
  const forms = useMemo(() => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adyen/kyc-components",
3
- "version": "2.7.0",
3
+ "version": "2.7.1",
4
4
  "description": "",
5
5
  "license": "MIT",
6
6
  "files": [