@redneckz/wildless-cms-uni-blocks 0.14.96 → 0.14.98

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.
Files changed (48) hide show
  1. package/bundle/bundle.umd.js +5 -5
  2. package/bundle/bundle.umd.min.js +1 -1
  3. package/bundle/components/Calculator/constants.d.ts +1 -1
  4. package/dist/components/Calculator/DepositCalculatorForm.js +2 -2
  5. package/dist/components/Calculator/DepositCalculatorForm.js.map +1 -1
  6. package/dist/components/Calculator/constants.d.ts +1 -1
  7. package/dist/components/Calculator/constants.js +1 -1
  8. package/dist/components/Calculator/constants.js.map +1 -1
  9. package/dist/components/Calculator/useDepositCalculatorParams.js +1 -1
  10. package/dist/components/StickyBottomMenu/StickyBottomMenuItem.js +1 -3
  11. package/dist/components/StickyBottomMenu/StickyBottomMenuItem.js.map +1 -1
  12. package/lib/components/Calculator/DepositCalculatorForm.js +2 -2
  13. package/lib/components/Calculator/DepositCalculatorForm.js.map +1 -1
  14. package/lib/components/Calculator/constants.d.ts +1 -1
  15. package/lib/components/Calculator/constants.js +1 -1
  16. package/lib/components/Calculator/constants.js.map +1 -1
  17. package/lib/components/Calculator/useDepositCalculatorParams.js +1 -1
  18. package/lib/components/StickyBottomMenu/StickyBottomMenuItem.js +1 -3
  19. package/lib/components/StickyBottomMenu/StickyBottomMenuItem.js.map +1 -1
  20. package/mobile/bundle/bundle.umd.js +6 -7
  21. package/mobile/bundle/bundle.umd.min.js +1 -1
  22. package/mobile/bundle/components/Calculator/constants.d.ts +1 -1
  23. package/mobile/dist/components/Calculator/DepositCalculatorForm.js +2 -2
  24. package/mobile/dist/components/Calculator/DepositCalculatorForm.js.map +1 -1
  25. package/mobile/dist/components/Calculator/constants.d.ts +1 -1
  26. package/mobile/dist/components/Calculator/constants.js +1 -1
  27. package/mobile/dist/components/Calculator/constants.js.map +1 -1
  28. package/mobile/dist/components/Calculator/useDepositCalculatorParams.js +1 -1
  29. package/mobile/dist/components/StickyBottomMenu/StickyBottomMenuItem.js +1 -3
  30. package/mobile/dist/components/StickyBottomMenu/StickyBottomMenuItem.js.map +1 -1
  31. package/mobile/lib/components/Calculator/DepositCalculatorForm.js +2 -2
  32. package/mobile/lib/components/Calculator/DepositCalculatorForm.js.map +1 -1
  33. package/mobile/lib/components/Calculator/constants.d.ts +1 -1
  34. package/mobile/lib/components/Calculator/constants.js +1 -1
  35. package/mobile/lib/components/Calculator/constants.js.map +1 -1
  36. package/mobile/lib/components/Calculator/useDepositCalculatorParams.js +1 -1
  37. package/mobile/lib/components/StickyBottomMenu/StickyBottomMenuItem.js +1 -3
  38. package/mobile/lib/components/StickyBottomMenu/StickyBottomMenuItem.js.map +1 -1
  39. package/mobile/src/components/Calculator/DepositCalculatorForm.tsx +2 -3
  40. package/mobile/src/components/Calculator/constants.ts +1 -1
  41. package/mobile/src/components/Calculator/useDepositCalculatorParams.ts +1 -1
  42. package/mobile/src/components/StickyBottomMenu/StickyBottomMenuItem.tsx +1 -5
  43. package/package.json +1 -1
  44. package/src/components/Calculator/Calculator.fixture.tsx +3 -0
  45. package/src/components/Calculator/DepositCalculatorForm.tsx +2 -3
  46. package/src/components/Calculator/constants.ts +1 -1
  47. package/src/components/Calculator/useDepositCalculatorParams.ts +1 -1
  48. package/src/components/StickyBottomMenu/StickyBottomMenuItem.tsx +1 -5
@@ -1863,7 +1863,7 @@
1863
1863
  const REFINANCING_EXTRA_MIN_SUM = 0;
1864
1864
  const REFINANCING_EXTRA_MAX_SUM = 500000;
1865
1865
  const DEPOSIT_DEFAULT_SUM = 20000;
1866
- const DEFAULT_MIN_MONTHS = 13;
1866
+ const DEFAULT_MIN_MONTHS = 1;
1867
1867
  const DEFAULT_REFINANCING_MIN_MONTHS = 13;
1868
1868
  const DEFAULT_REFINANCING_MONTHS = 48;
1869
1869
  const DEFAULT_MAX_MONTHS = 60;
@@ -2335,7 +2335,7 @@
2335
2335
  const data = useCalculatorParams(sourceBookDir || DEPOSIT_CALC_DEFAULT_DIR);
2336
2336
  const defaultMonth = data?.rateRows?.[0]
2337
2337
  ? getMiddleMonth(data.rateRows[0].minMonths, data.rateRows[0].maxMonths)
2338
- : 1;
2338
+ : 0;
2339
2339
  const isExcludeMonthlyInterestPayment = !paramsViewSettings?.isShowMonthlyInterestPayment;
2340
2340
  const isExcludeRemoteRegistration = !paramsViewSettings?.isShowRemoteRegistration;
2341
2341
  const depositCalculatorSourceBookParams = data?.rateRows?.find((row) => checkRowByParam({
@@ -2385,7 +2385,7 @@
2385
2385
  const DepositCalculatorForm = JSX(({ className, sourceBookDir, buttons, footnote, paramsViewSettings, defaultParams }) => {
2386
2386
  const [userInputParams, { field }] = useForm({
2387
2387
  moneyValue: getMoneyDefaultValue(defaultParams, DEPOSIT_DEFAULT_SUM),
2388
- monthsValue: getMonthsDefaultValue(defaultParams, 0),
2388
+ monthsValue: getMonthsDefaultValue(defaultParams),
2389
2389
  isMonthlyInterestPayment: Boolean(defaultParams?.isMonthlyInterestPayment),
2390
2390
  isRemoteRegistration: Boolean(defaultParams?.isRemoteRegistration),
2391
2391
  });
@@ -2393,7 +2393,7 @@
2393
2393
  const { defaultMonth, rate, income, finalSum } = calculatorParams;
2394
2394
  const { onChange: setMonthsValue } = field('monthsValue');
2395
2395
  useEffect(() => {
2396
- setMonthsValue && setMonthsValue(defaultMonth);
2396
+ !userInputParams.monthsValue && setMonthsValue && setMonthsValue(defaultMonth);
2397
2397
  }, [defaultMonth]);
2398
2398
  return (jsxs("section", { className: style('flex flex-col justify-between @5xl:flex-row gap-m', className), children: [jsxs("div", { className: "flex flex-col gap-y-m sm:max-w-md gap-2xl", children: [renderWantedSumInput({
2399
2399
  title: 'Сумма, ₽',
@@ -5791,7 +5791,7 @@
5791
5791
  return (jsx("div", { className: "flex items-end absolute bottom-0 right-0 h-full pointer-events-none", children: jsx(LikeControl, { className: "rounded-tl-3xl sticky bottom-0 pointer-events-auto" }) }));
5792
5792
  }
5793
5793
 
5794
- const packageVersion = "0.14.95";
5794
+ const packageVersion = "0.14.97";
5795
5795
 
5796
5796
  exports.Blocks = Blocks;
5797
5797
  exports.ContentPage = ContentPage;