@redneckz/wildless-cms-uni-blocks 0.14.15 → 0.14.16
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/bundle/blocks.schema.json +1 -1
- package/bundle/bundle.umd.js +108 -74
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/Depository/DepositoryItem.d.ts +1 -1
- package/bundle/components/OfficesAtmsMap/AtmsMap.d.ts +6 -0
- package/bundle/components/OfficesAtmsMap/OfficesAtmsMapLayout.d.ts +14 -0
- package/bundle/components/OfficesAtmsMap/{useOfficesAtmsMap.d.ts → OfficesAtmsMapProps.d.ts} +1 -8
- package/bundle/components/OfficesAtmsMap/OfficesMap.d.ts +4 -0
- package/bundle/components/OfficesAtmsMap/renderAtmCard.d.ts +1 -1
- package/bundle/components/OfficesAtmsMap/renderFiltrationForm.d.ts +6 -0
- package/bundle/components/OfficesAtmsMap/renderOfficeCard.d.ts +1 -1
- package/bundle/components/OfficesAtmsMap/useAtms.d.ts +2 -0
- package/bundle/components/OfficesAtmsMap/useOffices.d.ts +2 -0
- package/bundle/icons/IconName.d.ts +4 -2
- package/bundle/model/AlignJustifyStyle.d.ts +2 -0
- package/bundle/ui-kit/BaseFiltration/BaseFiltrationInner.d.ts +2 -2
- package/cosmos-static/icons/MagnifierIcon.svg +1 -0
- package/dist/components/ButtonsBlock/ButtonsBlock.js +2 -6
- package/dist/components/ButtonsBlock/ButtonsBlock.js.map +1 -1
- package/dist/components/Calculator/Calculator.js +2 -6
- package/dist/components/Calculator/Calculator.js.map +1 -1
- package/dist/components/Depository/DepositoryItem.d.ts +1 -1
- package/dist/components/Depository/DepositoryItem.js +1 -1
- package/dist/components/Depository/DepositoryItem.js.map +1 -1
- package/dist/components/Footer/Footer.mobile.js +1 -1
- package/dist/components/Footer/Footer.mobile.js.map +1 -1
- package/dist/components/OfficesAtmsMap/AtmsMap.d.ts +6 -0
- package/dist/components/OfficesAtmsMap/AtmsMap.js +39 -0
- package/dist/components/OfficesAtmsMap/AtmsMap.js.map +1 -0
- package/dist/components/OfficesAtmsMap/OfficesAtmsMap.js +4 -60
- package/dist/components/OfficesAtmsMap/OfficesAtmsMap.js.map +1 -1
- package/dist/components/OfficesAtmsMap/OfficesAtmsMapLayout.d.ts +14 -0
- package/dist/components/OfficesAtmsMap/OfficesAtmsMapLayout.js +26 -0
- package/dist/components/OfficesAtmsMap/OfficesAtmsMapLayout.js.map +1 -0
- package/dist/components/OfficesAtmsMap/{useOfficesAtmsMap.d.ts → OfficesAtmsMapProps.d.ts} +1 -8
- package/dist/components/OfficesAtmsMap/OfficesAtmsMapProps.js +2 -0
- package/dist/components/OfficesAtmsMap/OfficesAtmsMapProps.js.map +1 -0
- package/dist/components/OfficesAtmsMap/OfficesMap.d.ts +4 -0
- package/dist/components/OfficesAtmsMap/OfficesMap.js +27 -0
- package/dist/components/OfficesAtmsMap/OfficesMap.js.map +1 -0
- package/dist/components/OfficesAtmsMap/renderAtmCard.d.ts +1 -1
- package/dist/components/OfficesAtmsMap/renderFiltrationForm.d.ts +6 -0
- package/dist/components/OfficesAtmsMap/renderFiltrationForm.js +17 -0
- package/dist/components/OfficesAtmsMap/renderFiltrationForm.js.map +1 -0
- package/dist/components/OfficesAtmsMap/renderOfficeCard.d.ts +1 -1
- package/dist/components/OfficesAtmsMap/useAtms.d.ts +2 -0
- package/dist/components/OfficesAtmsMap/useAtms.js +15 -0
- package/dist/components/OfficesAtmsMap/useAtms.js.map +1 -0
- package/dist/components/OfficesAtmsMap/useOffices.d.ts +2 -0
- package/dist/components/OfficesAtmsMap/useOffices.js +15 -0
- package/dist/components/OfficesAtmsMap/useOffices.js.map +1 -0
- package/dist/components/StickyBottomMenu/StickyBottomMenu.mobile.js +2 -1
- package/dist/components/StickyBottomMenu/StickyBottomMenu.mobile.js.map +1 -1
- package/dist/icons/IconName.d.ts +4 -2
- package/dist/icons/IconName.js +3 -1
- package/dist/icons/IconName.js.map +1 -1
- package/dist/model/AlignJustifyStyle.d.ts +2 -0
- package/dist/model/AlignJustifyStyle.js +8 -0
- package/dist/model/AlignJustifyStyle.js.map +1 -0
- package/dist/ui-kit/BaseFiltration/BaseFiltrationInner.d.ts +2 -2
- package/dist/ui-kit/BaseFiltration/BaseFiltrationInner.js +4 -4
- package/dist/ui-kit/BaseFiltration/BaseFiltrationInner.js.map +1 -1
- package/dist/ui-kit/BaseTile/BaseTile.js +6 -6
- package/dist/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/dist/ui-kit/Select/SelectPopup.js +1 -1
- package/dist/ui-kit/Select/SelectPopup.js.map +1 -1
- package/dist/ui-kit/YandexMap/YandexMap.js +5 -1
- package/dist/ui-kit/YandexMap/YandexMap.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/ButtonsBlock/ButtonsBlock.js +2 -6
- package/lib/components/ButtonsBlock/ButtonsBlock.js.map +1 -1
- package/lib/components/Calculator/Calculator.js +2 -6
- package/lib/components/Calculator/Calculator.js.map +1 -1
- package/lib/components/Depository/DepositoryItem.d.ts +1 -1
- package/lib/components/Depository/DepositoryItem.js +1 -1
- package/lib/components/Depository/DepositoryItem.js.map +1 -1
- package/lib/components/Footer/Footer.mobile.js +1 -1
- package/lib/components/Footer/Footer.mobile.js.map +1 -1
- package/lib/components/OfficesAtmsMap/AtmsMap.d.ts +6 -0
- package/lib/components/OfficesAtmsMap/AtmsMap.js +37 -0
- package/lib/components/OfficesAtmsMap/AtmsMap.js.map +1 -0
- package/lib/components/OfficesAtmsMap/OfficesAtmsMap.js +5 -61
- package/lib/components/OfficesAtmsMap/OfficesAtmsMap.js.map +1 -1
- package/lib/components/OfficesAtmsMap/OfficesAtmsMapLayout.d.ts +14 -0
- package/lib/components/OfficesAtmsMap/OfficesAtmsMapLayout.js +24 -0
- package/lib/components/OfficesAtmsMap/OfficesAtmsMapLayout.js.map +1 -0
- package/lib/components/OfficesAtmsMap/{useOfficesAtmsMap.d.ts → OfficesAtmsMapProps.d.ts} +1 -8
- package/lib/components/OfficesAtmsMap/OfficesAtmsMapProps.js +2 -0
- package/lib/components/OfficesAtmsMap/OfficesAtmsMapProps.js.map +1 -0
- package/lib/components/OfficesAtmsMap/OfficesMap.d.ts +4 -0
- package/lib/components/OfficesAtmsMap/OfficesMap.js +25 -0
- package/lib/components/OfficesAtmsMap/OfficesMap.js.map +1 -0
- package/lib/components/OfficesAtmsMap/renderAtmCard.d.ts +1 -1
- package/lib/components/OfficesAtmsMap/renderFiltrationForm.d.ts +6 -0
- package/lib/components/OfficesAtmsMap/renderFiltrationForm.js +14 -0
- package/lib/components/OfficesAtmsMap/renderFiltrationForm.js.map +1 -0
- package/lib/components/OfficesAtmsMap/renderOfficeCard.d.ts +1 -1
- package/lib/components/OfficesAtmsMap/useAtms.d.ts +2 -0
- package/lib/components/OfficesAtmsMap/useAtms.js +12 -0
- package/lib/components/OfficesAtmsMap/useAtms.js.map +1 -0
- package/lib/components/OfficesAtmsMap/useOffices.d.ts +2 -0
- package/lib/components/OfficesAtmsMap/useOffices.js +12 -0
- package/lib/components/OfficesAtmsMap/useOffices.js.map +1 -0
- package/lib/components/StickyBottomMenu/StickyBottomMenu.mobile.js +2 -1
- package/lib/components/StickyBottomMenu/StickyBottomMenu.mobile.js.map +1 -1
- package/lib/icons/IconName.d.ts +4 -2
- package/lib/icons/IconName.js +3 -1
- package/lib/icons/IconName.js.map +1 -1
- package/lib/model/AlignJustifyStyle.d.ts +2 -0
- package/lib/model/AlignJustifyStyle.js +6 -0
- package/lib/model/AlignJustifyStyle.js.map +1 -0
- package/lib/ui-kit/BaseFiltration/BaseFiltrationInner.d.ts +2 -2
- package/lib/ui-kit/BaseFiltration/BaseFiltrationInner.js +4 -4
- package/lib/ui-kit/BaseFiltration/BaseFiltrationInner.js.map +1 -1
- package/lib/ui-kit/BaseTile/BaseTile.js +6 -6
- package/lib/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/lib/ui-kit/Select/SelectPopup.js +1 -1
- package/lib/ui-kit/Select/SelectPopup.js.map +1 -1
- package/lib/ui-kit/YandexMap/YandexMap.js +5 -1
- package/lib/ui-kit/YandexMap/YandexMap.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +20 -16
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/Depository/DepositoryItem.d.ts +1 -1
- package/mobile/bundle/components/OfficesAtmsMap/AtmsMap.d.ts +6 -0
- package/mobile/bundle/components/OfficesAtmsMap/OfficesAtmsMapLayout.d.ts +14 -0
- package/mobile/bundle/components/OfficesAtmsMap/{useOfficesAtmsMap.d.ts → OfficesAtmsMapProps.d.ts} +1 -8
- package/mobile/bundle/components/OfficesAtmsMap/OfficesMap.d.ts +4 -0
- package/mobile/bundle/components/OfficesAtmsMap/renderAtmCard.d.ts +1 -1
- package/mobile/bundle/components/OfficesAtmsMap/renderFiltrationForm.d.ts +6 -0
- package/mobile/bundle/components/OfficesAtmsMap/renderOfficeCard.d.ts +1 -1
- package/mobile/bundle/components/OfficesAtmsMap/useAtms.d.ts +2 -0
- package/mobile/bundle/components/OfficesAtmsMap/useOffices.d.ts +2 -0
- package/mobile/bundle/icons/IconName.d.ts +4 -2
- package/mobile/bundle/model/AlignJustifyStyle.d.ts +2 -0
- package/mobile/bundle/ui-kit/BaseFiltration/BaseFiltrationInner.d.ts +2 -2
- package/mobile/dist/components/ButtonsBlock/ButtonsBlock.js +2 -6
- package/mobile/dist/components/ButtonsBlock/ButtonsBlock.js.map +1 -1
- package/mobile/dist/components/Depository/DepositoryItem.d.ts +1 -1
- package/mobile/dist/components/Depository/DepositoryItem.js +1 -1
- package/mobile/dist/components/Depository/DepositoryItem.js.map +1 -1
- package/mobile/dist/components/Footer/Footer.js +1 -1
- package/mobile/dist/components/Footer/Footer.js.map +1 -1
- package/mobile/dist/components/OfficesAtmsMap/AtmsMap.d.ts +6 -0
- package/mobile/dist/components/OfficesAtmsMap/AtmsMap.js +39 -0
- package/mobile/dist/components/OfficesAtmsMap/AtmsMap.js.map +1 -0
- package/mobile/dist/components/OfficesAtmsMap/OfficesAtmsMap.js +4 -60
- package/mobile/dist/components/OfficesAtmsMap/OfficesAtmsMap.js.map +1 -1
- package/mobile/dist/components/OfficesAtmsMap/OfficesAtmsMapLayout.d.ts +14 -0
- package/mobile/dist/components/OfficesAtmsMap/OfficesAtmsMapLayout.js +26 -0
- package/mobile/dist/components/OfficesAtmsMap/OfficesAtmsMapLayout.js.map +1 -0
- package/mobile/dist/components/OfficesAtmsMap/OfficesAtmsMapProps.d.ts +83 -0
- package/mobile/dist/components/OfficesAtmsMap/OfficesAtmsMapProps.js +2 -0
- package/mobile/dist/components/OfficesAtmsMap/OfficesAtmsMapProps.js.map +1 -0
- package/mobile/dist/components/OfficesAtmsMap/OfficesMap.d.ts +4 -0
- package/mobile/dist/components/OfficesAtmsMap/OfficesMap.js +27 -0
- package/mobile/dist/components/OfficesAtmsMap/OfficesMap.js.map +1 -0
- package/mobile/dist/components/OfficesAtmsMap/renderAtmCard.d.ts +1 -1
- package/mobile/dist/components/OfficesAtmsMap/renderFiltrationForm.d.ts +6 -0
- package/mobile/dist/components/OfficesAtmsMap/renderFiltrationForm.js +17 -0
- package/mobile/dist/components/OfficesAtmsMap/renderFiltrationForm.js.map +1 -0
- package/mobile/dist/components/OfficesAtmsMap/renderOfficeCard.d.ts +1 -1
- package/mobile/dist/components/OfficesAtmsMap/useAtms.d.ts +2 -0
- package/mobile/dist/components/OfficesAtmsMap/useAtms.js +15 -0
- package/mobile/dist/components/OfficesAtmsMap/useAtms.js.map +1 -0
- package/mobile/dist/components/OfficesAtmsMap/useOffices.d.ts +2 -0
- package/mobile/dist/components/OfficesAtmsMap/useOffices.js +15 -0
- package/mobile/dist/components/OfficesAtmsMap/useOffices.js.map +1 -0
- package/mobile/dist/components/StickyBottomMenu/StickyBottomMenu.js +2 -1
- package/mobile/dist/components/StickyBottomMenu/StickyBottomMenu.js.map +1 -1
- package/mobile/dist/icons/IconName.d.ts +4 -2
- package/mobile/dist/icons/IconName.js +3 -1
- package/mobile/dist/icons/IconName.js.map +1 -1
- package/mobile/dist/model/AlignJustifyStyle.d.ts +2 -0
- package/mobile/dist/model/AlignJustifyStyle.js +8 -0
- package/mobile/dist/model/AlignJustifyStyle.js.map +1 -0
- package/mobile/dist/ui-kit/BaseFiltration/BaseFiltrationInner.d.ts +2 -2
- package/mobile/dist/ui-kit/BaseFiltration/BaseFiltrationInner.js +4 -4
- package/mobile/dist/ui-kit/BaseFiltration/BaseFiltrationInner.js.map +1 -1
- package/mobile/dist/ui-kit/BaseTile/BaseTile.js +6 -6
- package/mobile/dist/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/mobile/dist/ui-kit/Select/SelectPopup.js +1 -1
- package/mobile/dist/ui-kit/Select/SelectPopup.js.map +1 -1
- package/mobile/dist/ui-kit/YandexMap/YandexMap.js +5 -1
- package/mobile/dist/ui-kit/YandexMap/YandexMap.js.map +1 -1
- package/mobile/lib/common.css +1 -1
- package/mobile/lib/components/ButtonsBlock/ButtonsBlock.js +2 -6
- package/mobile/lib/components/ButtonsBlock/ButtonsBlock.js.map +1 -1
- package/mobile/lib/components/Depository/DepositoryItem.d.ts +1 -1
- package/mobile/lib/components/Depository/DepositoryItem.js +1 -1
- package/mobile/lib/components/Depository/DepositoryItem.js.map +1 -1
- package/mobile/lib/components/Footer/Footer.js +1 -1
- package/mobile/lib/components/Footer/Footer.js.map +1 -1
- package/mobile/lib/components/OfficesAtmsMap/AtmsMap.d.ts +6 -0
- package/mobile/lib/components/OfficesAtmsMap/AtmsMap.js +37 -0
- package/mobile/lib/components/OfficesAtmsMap/AtmsMap.js.map +1 -0
- package/mobile/lib/components/OfficesAtmsMap/OfficesAtmsMap.js +5 -61
- package/mobile/lib/components/OfficesAtmsMap/OfficesAtmsMap.js.map +1 -1
- package/mobile/lib/components/OfficesAtmsMap/OfficesAtmsMapLayout.d.ts +14 -0
- package/mobile/lib/components/OfficesAtmsMap/OfficesAtmsMapLayout.js +24 -0
- package/mobile/lib/components/OfficesAtmsMap/OfficesAtmsMapLayout.js.map +1 -0
- package/mobile/lib/components/OfficesAtmsMap/OfficesAtmsMapProps.d.ts +83 -0
- package/mobile/lib/components/OfficesAtmsMap/OfficesAtmsMapProps.js +2 -0
- package/mobile/lib/components/OfficesAtmsMap/OfficesAtmsMapProps.js.map +1 -0
- package/mobile/lib/components/OfficesAtmsMap/OfficesMap.d.ts +4 -0
- package/mobile/lib/components/OfficesAtmsMap/OfficesMap.js +25 -0
- package/mobile/lib/components/OfficesAtmsMap/OfficesMap.js.map +1 -0
- package/mobile/lib/components/OfficesAtmsMap/renderAtmCard.d.ts +1 -1
- package/mobile/lib/components/OfficesAtmsMap/renderFiltrationForm.d.ts +6 -0
- package/mobile/lib/components/OfficesAtmsMap/renderFiltrationForm.js +14 -0
- package/mobile/lib/components/OfficesAtmsMap/renderFiltrationForm.js.map +1 -0
- package/mobile/lib/components/OfficesAtmsMap/renderOfficeCard.d.ts +1 -1
- package/mobile/lib/components/OfficesAtmsMap/useAtms.d.ts +2 -0
- package/mobile/lib/components/OfficesAtmsMap/useAtms.js +12 -0
- package/mobile/lib/components/OfficesAtmsMap/useAtms.js.map +1 -0
- package/mobile/lib/components/OfficesAtmsMap/useOffices.d.ts +2 -0
- package/mobile/lib/components/OfficesAtmsMap/useOffices.js +12 -0
- package/mobile/lib/components/OfficesAtmsMap/useOffices.js.map +1 -0
- package/mobile/lib/components/StickyBottomMenu/StickyBottomMenu.js +2 -1
- package/mobile/lib/components/StickyBottomMenu/StickyBottomMenu.js.map +1 -1
- package/mobile/lib/icons/IconName.d.ts +4 -2
- package/mobile/lib/icons/IconName.js +3 -1
- package/mobile/lib/icons/IconName.js.map +1 -1
- package/mobile/lib/model/AlignJustifyStyle.d.ts +2 -0
- package/mobile/lib/model/AlignJustifyStyle.js +6 -0
- package/mobile/lib/model/AlignJustifyStyle.js.map +1 -0
- package/mobile/lib/ui-kit/BaseFiltration/BaseFiltrationInner.d.ts +2 -2
- package/mobile/lib/ui-kit/BaseFiltration/BaseFiltrationInner.js +4 -4
- package/mobile/lib/ui-kit/BaseFiltration/BaseFiltrationInner.js.map +1 -1
- package/mobile/lib/ui-kit/BaseTile/BaseTile.js +6 -6
- package/mobile/lib/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/mobile/lib/ui-kit/Select/SelectPopup.js +1 -1
- package/mobile/lib/ui-kit/Select/SelectPopup.js.map +1 -1
- package/mobile/lib/ui-kit/YandexMap/YandexMap.js +5 -1
- package/mobile/lib/ui-kit/YandexMap/YandexMap.js.map +1 -1
- package/mobile/src/components/ButtonsBlock/ButtonsBlock.tsx +2 -8
- package/mobile/src/components/Depository/DepositoryItem.tsx +2 -2
- package/mobile/src/components/Footer/Footer.tsx +1 -1
- package/mobile/src/components/OfficesAtmsMap/AtmsMap.tsx +61 -0
- package/mobile/src/components/OfficesAtmsMap/OfficesAtmsMap.tsx +5 -145
- package/mobile/src/components/OfficesAtmsMap/OfficesAtmsMapLayout.tsx +97 -0
- package/mobile/src/components/OfficesAtmsMap/{useOfficesAtmsMap.ts → OfficesAtmsMapProps.tsx} +1 -26
- package/mobile/src/components/OfficesAtmsMap/OfficesMap.tsx +45 -0
- package/mobile/src/components/OfficesAtmsMap/renderAtmCard.tsx +1 -1
- package/mobile/src/components/OfficesAtmsMap/renderFiltrationForm.tsx +35 -0
- package/mobile/src/components/OfficesAtmsMap/renderOfficeCard.tsx +1 -1
- package/mobile/src/components/OfficesAtmsMap/useAtms.ts +20 -0
- package/mobile/src/components/OfficesAtmsMap/useOffices.ts +20 -0
- package/mobile/src/components/StickyBottomMenu/StickyBottomMenu.tsx +3 -1
- package/mobile/src/icons/IconName.ts +5 -5
- package/mobile/src/icons/MagnifierIcon.svg +39 -0
- package/mobile/src/model/AlignJustifyStyle.ts +7 -0
- package/mobile/src/ui-kit/BaseFiltration/BaseFiltrationInner.tsx +19 -12
- package/mobile/src/ui-kit/BaseTile/BaseTile.tsx +11 -6
- package/mobile/src/ui-kit/Select/SelectPopup.tsx +1 -1
- package/mobile/src/ui-kit/YandexMap/YandexMap.tsx +6 -1
- package/package.json +2 -2
- package/src/components/ButtonsBlock/ButtonsBlock.tsx +2 -8
- package/src/components/Calculator/Calculator.tsx +2 -7
- package/src/components/Depository/DepositoryItem.tsx +2 -2
- package/src/components/Footer/Footer.mobile.tsx +1 -1
- package/src/components/OfficesAtmsMap/AtmsMap.tsx +61 -0
- package/src/components/OfficesAtmsMap/OfficesAtmsMap.tsx +5 -145
- package/src/components/OfficesAtmsMap/OfficesAtmsMapLayout.tsx +97 -0
- package/src/components/OfficesAtmsMap/{useOfficesAtmsMap.ts → OfficesAtmsMapProps.tsx} +1 -26
- package/src/components/OfficesAtmsMap/OfficesMap.tsx +45 -0
- package/src/components/OfficesAtmsMap/renderAtmCard.tsx +1 -1
- package/src/components/OfficesAtmsMap/renderFiltrationForm.tsx +35 -0
- package/src/components/OfficesAtmsMap/renderOfficeCard.tsx +1 -1
- package/src/components/OfficesAtmsMap/useAtms.ts +20 -0
- package/src/components/OfficesAtmsMap/useOffices.ts +20 -0
- package/src/components/StickyBottomMenu/StickyBottomMenu.mobile.tsx +3 -1
- package/src/icons/IconName.ts +5 -5
- package/src/icons/MagnifierIcon.svg +39 -0
- package/src/model/AlignJustifyStyle.ts +7 -0
- package/src/ui-kit/BaseFiltration/BaseFiltrationInner.tsx +19 -12
- package/src/ui-kit/BaseTile/BaseTile.tsx +11 -6
- package/src/ui-kit/Select/SelectPopup.tsx +1 -1
- package/src/ui-kit/YandexMap/YandexMap.tsx +6 -1
- package/dist/components/OfficesAtmsMap/useOfficesAtmsMap.js +0 -19
- package/dist/components/OfficesAtmsMap/useOfficesAtmsMap.js.map +0 -1
- package/lib/components/OfficesAtmsMap/useOfficesAtmsMap.js +0 -16
- package/lib/components/OfficesAtmsMap/useOfficesAtmsMap.js.map +0 -1
- package/mobile/dist/components/OfficesAtmsMap/useOfficesAtmsMap.d.ts +0 -90
- package/mobile/dist/components/OfficesAtmsMap/useOfficesAtmsMap.js +0 -19
- package/mobile/dist/components/OfficesAtmsMap/useOfficesAtmsMap.js.map +0 -1
- package/mobile/lib/components/OfficesAtmsMap/useOfficesAtmsMap.d.ts +0 -90
- package/mobile/lib/components/OfficesAtmsMap/useOfficesAtmsMap.js +0 -16
- package/mobile/lib/components/OfficesAtmsMap/useOfficesAtmsMap.js.map +0 -1
package/bundle/bundle.umd.js
CHANGED
|
@@ -513,10 +513,10 @@
|
|
|
513
513
|
}
|
|
514
514
|
|
|
515
515
|
const REGIONS_URL$1 = '/api/v1/regions';
|
|
516
|
-
const EMPTY_VALUE$
|
|
516
|
+
const EMPTY_VALUE$5 = [];
|
|
517
517
|
function useGetRegions() {
|
|
518
518
|
const { data } = useAsyncData(REGIONS_URL$1, fetchJSONUnsafe);
|
|
519
|
-
return data || EMPTY_VALUE$
|
|
519
|
+
return data || EMPTY_VALUE$5;
|
|
520
520
|
}
|
|
521
521
|
|
|
522
522
|
const useDialogManager = () => ({
|
|
@@ -832,7 +832,7 @@
|
|
|
832
832
|
return options.filter((_) => _.text?.toLocaleLowerCase().includes(query?.trim().toLocaleLowerCase()));
|
|
833
833
|
};
|
|
834
834
|
|
|
835
|
-
const SelectPopup = JSX(({ popupRef, options, value, query, onChange }) => options?.length ? (jsx("div", { className: "bg-white text-l max-h-64 overflow-y-auto overflow-x-hidden rounded-md
|
|
835
|
+
const SelectPopup = JSX(({ popupRef, options, value, query, onChange }) => options?.length ? (jsx("div", { className: "bg-white text-l max-h-64 overflow-y-auto overflow-x-hidden rounded-md", role: "listbox", ref: popupRef, children: filterOptions(options, query).map((option) => (jsxs("div", { className: "flex px-m py-s cursor-pointer hover:bg-main-divider pr-5xl relative", role: "option", "aria-selected": option.key === value?.key, onClick: () => onChange && onChange(option), children: [jsx("span", { className: "min-h-6", children: formatOption(option) }), jsx(Icon, { name: "DoneSimpleIcon", width: "16", height: "16", className: style('absolute right-4 pt-3xs', option.key === value?.key ? '' : 'hidden') })] }, option.key))) })) : null);
|
|
836
836
|
|
|
837
837
|
function useSelectPopup({ isOpen, options, value, query, onChange, onClose, }) {
|
|
838
838
|
const popup = usePopupManager();
|
|
@@ -972,14 +972,14 @@
|
|
|
972
972
|
});
|
|
973
973
|
|
|
974
974
|
const BRANCHES_URL = '/api/v1/branches';
|
|
975
|
-
const EMPTY_VALUE$
|
|
975
|
+
const EMPTY_VALUE$4 = [];
|
|
976
976
|
function useBranches(regionCode) {
|
|
977
977
|
const { data } = useAsyncData(regionCode ? `${BRANCHES_URL}?regionCode=${regionCode}` : null, fetchSafeBoxes$1);
|
|
978
|
-
return data || EMPTY_VALUE$
|
|
978
|
+
return data || EMPTY_VALUE$4;
|
|
979
979
|
}
|
|
980
980
|
const fetchSafeBoxes$1 = async (url) => {
|
|
981
981
|
const result = await fetchJSON(url, { method: 'GET' });
|
|
982
|
-
return result || EMPTY_VALUE$
|
|
982
|
+
return result || EMPTY_VALUE$4;
|
|
983
983
|
};
|
|
984
984
|
|
|
985
985
|
const MIN_CREDIT_AMOUNT = 1000;
|
|
@@ -1124,15 +1124,15 @@
|
|
|
1124
1124
|
return (jsxs("form", { className: "container", onSubmit: formProps.onSubmit, children: [jsx(Heading, { headingType: "h6", title: "\u041E\u0441\u0442\u0430\u0432\u044C\u0442\u0435 \u0437\u0430\u044F\u0432\u043A\u0443 \u0438 \u043C\u044B \u043E\u0442\u0432\u0435\u0442\u0438\u043C \u043D\u0430 \u043B\u044E\u0431\u044B\u0435 \u0432\u043E\u043F\u0440\u043E\u0441\u044B \u043F\u043E \u0434\u0435\u043F\u043E\u0437\u0438\u0442\u0430\u043C", className: "@xl:text-center mb-m" }), jsxs("div", { className: "max-w-[560px] m-auto space-y-s", children: [jsx(InputControl, { className: "shrink-0 w-full", label: "\u0418\u043C\u044F", ...withValidator(field('name'), nameValidator) }), jsx(PhoneInputControl, { className: "shrink-0 w-full", label: "\u0422\u0435\u043B\u0435\u0444\u043E\u043D", ...withValidator(field('phone'), phoneValidator) })] }), jsxs("div", { className: "flex justify-between flex-col-reverse @xl:items-center @xl:flex-row max-w-[560px] m-auto", children: [jsx("div", { className: "flex-1", children: jsx(Footnote, { link: link }) }), renderSubmitButton(button)] })] }));
|
|
1125
1125
|
});
|
|
1126
1126
|
|
|
1127
|
-
const EMPTY_VALUE$
|
|
1127
|
+
const EMPTY_VALUE$3 = {};
|
|
1128
1128
|
const DEFAULT_FOLDER_NAME = 'wcms-resources';
|
|
1129
1129
|
function useSWRResource(filename, options = {}) {
|
|
1130
|
-
const { fallback = EMPTY_VALUE$
|
|
1130
|
+
const { fallback = EMPTY_VALUE$3, folderName = DEFAULT_FOLDER_NAME, setBasePath = false } = options;
|
|
1131
1131
|
const path = joinPath('/', setBasePath ? projectSettings.BASE_PATH : '', folderName, `${filename}.json`);
|
|
1132
1132
|
const { data } = useAsyncData(filename ? path : null, fetchJSONUnsafe, {
|
|
1133
1133
|
fallback,
|
|
1134
1134
|
});
|
|
1135
|
-
return data || EMPTY_VALUE$
|
|
1135
|
+
return data || EMPTY_VALUE$3;
|
|
1136
1136
|
}
|
|
1137
1137
|
|
|
1138
1138
|
const ApplicationFormGrantSupport = JSX((props) => {
|
|
@@ -1438,13 +1438,14 @@
|
|
|
1438
1438
|
|
|
1439
1439
|
const BusinessBlock = JSX(({ className, title, cards, ...rest }) => (jsxs(BlockWrapper, { className: className, defaultPadding: "p-6xl space-y-3xl", ...rest, children: [jsx(Heading, { headingType: "h3", title: title, className: "text-center" }), jsx("div", { className: "flex gap-lg", children: cards?.length ? cards.map((_, i) => jsx(BusinessCard, { ..._ }, String(i))) : null })] })));
|
|
1440
1440
|
|
|
1441
|
-
const
|
|
1441
|
+
const AlignJustifyStyle = {
|
|
1442
1442
|
start: 'justify-start',
|
|
1443
1443
|
center: 'justify-center',
|
|
1444
1444
|
end: 'justify-end',
|
|
1445
1445
|
};
|
|
1446
|
+
|
|
1446
1447
|
const ButtonsBlock = JSX(({ buttons, className = '', align, ...rest }) => {
|
|
1447
|
-
const alignStyle = align ? style('flex',
|
|
1448
|
+
const alignStyle = align ? style('flex', AlignJustifyStyle[align]) : '';
|
|
1448
1449
|
return (jsx(BlockWrapper, { className: style('!bg-transparent', alignStyle, className), defaultPadding: "p-0", ...rest, children: renderButtonsSection(buttons) }));
|
|
1449
1450
|
});
|
|
1450
1451
|
|
|
@@ -2208,11 +2209,6 @@
|
|
|
2208
2209
|
return (jsx("section", { className: "box-border relative bg-white flex shrink-0 self-start basis-full", role: "listitem", children: jsxs("div", { className: "box-border p-4xl w-full space-y-xl", children: [block?.title ? jsx(Heading, { className: "text-center", title: block.title }) : null, jsx(EmbeddedBlock, { ...block })] }) }, String(i)));
|
|
2209
2210
|
};
|
|
2210
2211
|
|
|
2211
|
-
const alignStyleMap = {
|
|
2212
|
-
start: 'justify-start',
|
|
2213
|
-
center: 'justify-center',
|
|
2214
|
-
end: 'justify-end',
|
|
2215
|
-
};
|
|
2216
2212
|
const Calculator = JSX(({ className = '', tabAlign, calculatorTabs = [], ...rest }) => {
|
|
2217
2213
|
const tabsNav = calculatorTabs.map((_) => _.nav || {});
|
|
2218
2214
|
const calculatorBlocks = calculatorTabs.map(({ calculatorBlock }) => calculatorBlock || {});
|
|
@@ -2255,7 +2251,7 @@
|
|
|
2255
2251
|
}
|
|
2256
2252
|
function renderTabs$1({ activeIndex, tabsNav, tabAlign, slideIndexShift, onClick }) {
|
|
2257
2253
|
const CARD_SHIFT = 388;
|
|
2258
|
-
const alignStyle = tabAlign ?
|
|
2254
|
+
const alignStyle = tabAlign ? AlignJustifyStyle[tabAlign] : '';
|
|
2259
2255
|
return (jsxs("div", { children: [jsx("div", { style: { transform: `translateX(-${activeIndex * CARD_SHIFT}px)` }, className: "flex flex-col justify-end items-center h-32 pt-4xl box-border duration-1000", children: jsx("div", { className: style('w-full flex flex-nowrap items-end gap-xs', alignStyle), children: tabsNav.map((tab, i) => renderNavButton$3({
|
|
2260
2256
|
tab,
|
|
2261
2257
|
i,
|
|
@@ -2624,13 +2620,13 @@
|
|
|
2624
2620
|
center: '@xl:self-center',
|
|
2625
2621
|
end: '@xl:self-end',
|
|
2626
2622
|
};
|
|
2627
|
-
const BaseTile = JSX(({ className, defaultPadding, padding, title = '', insetTitle = '', buttons, leftImage, rightImage, imageAlign, isImageAlwaysOnRight = false, isImageSecondary = false, children, }) => (jsxs("div", { className: style('relative flex flex-col gap-3xl font-sans overflow-hidden', padding || defaultPadding, className), children: [title ? jsx("div", { className: "relative", children: title }) : null, jsxs("div", { className: style('grow relative flex flex-col-reverse @xl:flex-row justify-around @xl:justify-between items-stretch gap-3xl'), children: [renderImageContainer(leftImage, { imageAlign }), jsxs("div", { className: style('grid gap-3xl', rightImage ? '@xl:grid-cols-2' : '', leftImage ? '' : 'grow'), children: [jsxs("div", { className: "grow space-y-lg", children: [insetTitle, children] }), renderImageContainer(rightImage, {
|
|
2628
|
-
className: style('@xl:justify-self-end @xl:
|
|
2623
|
+
const BaseTile = JSX(({ className, defaultPadding, padding, title = '', insetTitle = '', buttons, leftImage, rightImage, imageAlign, isImageAlwaysOnRight = false, isImageSecondary = false, children, }) => (jsxs("div", { className: style('relative flex flex-col gap-3xl font-sans overflow-hidden', padding || defaultPadding, className), children: [title ? jsx("div", { className: "relative", children: title }) : null, jsxs("div", { className: style('grow relative flex flex-col-reverse @xl:flex-row justify-around @xl:justify-between items-stretch gap-3xl'), children: [renderImageContainer(leftImage, { imageAlign }), jsxs("div", { className: style('grid gap-3xl', rightImage ? '@xl:grid-cols-2' : '', leftImage ? '' : 'grow'), children: [jsxs("div", { className: "grow space-y-lg min-w-fit", children: [insetTitle, children] }), renderImageContainer(rightImage, {
|
|
2624
|
+
className: style('@xl:justify-self-end @xl:col-start-2', buttons ? rowSpanStyle(isImageAlwaysOnRight) : '', positionStyle(isImageAlwaysOnRight), isImageSecondary ? 'hidden @xl:block' : ''),
|
|
2629
2625
|
imageAlign,
|
|
2630
|
-
}),
|
|
2631
|
-
const
|
|
2632
|
-
|
|
2633
|
-
|
|
2626
|
+
}), renderButtons(buttons)] })] })] })));
|
|
2627
|
+
const rowSpanStyle = (isImageAlwaysOnRight) => isImageAlwaysOnRight ? 'row-span-2' : '@xl:row-span-2';
|
|
2628
|
+
const positionStyle = (isImageAlwaysOnRight) => isImageAlwaysOnRight ? 'justify-self-end col-start-2 self-center' : '';
|
|
2629
|
+
const renderButtons = (buttons) => buttons ? jsx("div", { className: "self-end", children: buttons }) : null;
|
|
2634
2630
|
const renderImageContainer = (image, { className, imageAlign }) => image ? (jsx("div", { className: style('shrink-1/2 justify-self-center', imageAlign && imageAlignmentMap[imageAlign], className), children: image })) : null;
|
|
2635
2631
|
|
|
2636
2632
|
const cardStyleMap = {
|
|
@@ -2968,9 +2964,7 @@
|
|
|
2968
2964
|
return (jsx(FoldableSection, { className: style(resultsGridStyle), isUnfolded: isUnfolded, children: renderBlocksList(hiddenBlocks, { ...rest.options, parent: block }) }));
|
|
2969
2965
|
}, renderFoldButton: ({ isUnfolded, onToggle }) => (jsx(DefaultFoldButton, { className: style(topItemsCount < 1 ? 'hidden' : ''), disabled: !hiddenBlocks?.length, label: label, icon: ICONS[Number(isUnfolded)], dataTheme: rest.options?.page?.colorPalette, onClick: onToggle })) })] })] }));
|
|
2970
2966
|
});
|
|
2971
|
-
|
|
2972
|
-
return (jsx("div", { className: "bg-white py-20", children: jsx(Headline, { title: title, description: description, headlineVersion: "S", isEmbedded: true }) }));
|
|
2973
|
-
}
|
|
2967
|
+
const renderNotFound = ({ title, description }) => (jsxs("div", { className: "bg-white p-6xl py-20 flex gap-s flex-col @xl:items-center", children: [jsx(Img, { image: { icon: 'MagnifierIcon' }, width: "120", height: "120" }), jsx(Headline, { title: title, description: description, headlineVersion: "S", isEmbedded: true, align: AlignStyles })] }));
|
|
2974
2968
|
|
|
2975
2969
|
const isEmpty = (v) => v === null ||
|
|
2976
2970
|
v === undefined ||
|
|
@@ -3157,7 +3151,7 @@
|
|
|
3157
3151
|
const formatDate$1 = (date) => date.split('-').reverse().join('.');
|
|
3158
3152
|
|
|
3159
3153
|
const DepositoryItem = ({ title, timestamp = '', publicId }) => {
|
|
3160
|
-
const link = useLink();
|
|
3154
|
+
const link = useLink({ basePath: '/' });
|
|
3161
3155
|
const { href } = link({ href: `/api/v1/depository/${publicId}/file` });
|
|
3162
3156
|
return (jsxs("div", { className: "grid grid-cols-12 py-lg border-gray border-opacity-50 border-b", children: [jsx("div", { className: "col-span-2 text-m", children: jsx("span", { children: formatDate$1(timestamp) }) }), jsx("div", { className: "col-span-10 text-h6 hover:text-primary-active", children: jsx("a", { href: href, download: true, "aria-label": "\u0421\u043A\u0430\u0447\u0430\u0442\u044C", children: title }) })] }, publicId));
|
|
3163
3157
|
};
|
|
@@ -4396,6 +4390,10 @@
|
|
|
4396
4390
|
useEffect(() => {
|
|
4397
4391
|
if (!map?.current) {
|
|
4398
4392
|
yandexMaps?.ready(() => {
|
|
4393
|
+
// Ready function may be called few times, but must be called once
|
|
4394
|
+
if (map.current) {
|
|
4395
|
+
return;
|
|
4396
|
+
}
|
|
4399
4397
|
map.current = new yandexMaps.Map('map', {
|
|
4400
4398
|
center: pointsCenter,
|
|
4401
4399
|
zoom,
|
|
@@ -4411,7 +4409,7 @@
|
|
|
4411
4409
|
map.current.setCenter(DEFAULT_CENTER_COORDS);
|
|
4412
4410
|
}
|
|
4413
4411
|
}
|
|
4414
|
-
}, [yandexMaps, map, points]);
|
|
4412
|
+
}, [yandexMaps, map, points, pointsCenter, zoom]);
|
|
4415
4413
|
if (!yandexMaps) {
|
|
4416
4414
|
return null;
|
|
4417
4415
|
}
|
|
@@ -4435,6 +4433,29 @@
|
|
|
4435
4433
|
const mapByIndex = (arr, index) => arr.map((a) => a[index]);
|
|
4436
4434
|
const getArraySumAndAverage = (arr) => arr.length && arr.reduce((a, b) => a + b) / arr.length;
|
|
4437
4435
|
|
|
4436
|
+
const FILTRATION_LABELS = {
|
|
4437
|
+
safeBoxCaseVolumes: 'Аренда индивидуальных сейфовых ячеек',
|
|
4438
|
+
workingSaturday: 'Открыты по субботам',
|
|
4439
|
+
terminalTypeAtms: 'Банкоматы',
|
|
4440
|
+
terminalTypeTerm: 'Терминалы',
|
|
4441
|
+
workAllTime: 'Круглосуточно',
|
|
4442
|
+
billAcceptorEnable: 'Прием наличных',
|
|
4443
|
+
};
|
|
4444
|
+
const renderFiltrationForm = (filters, { field, reset }) => (jsxs("div", { className: "pb-2xl", children: [filters?.length ? (jsx("div", { className: "flex flex-wrap gap-3xl pb-2xl", children: filters.map((key) => (jsx(Checkbox, { text: FILTRATION_LABELS[key], ...field(key) }, key))) })) : null, jsx(Button, { version: "transparent", className: "text-secondary-text [&>*]:p-0", onClick: reset, text: "\u041E\u0447\u0438\u0441\u0442\u0438\u0442\u044C \u0444\u0438\u043B\u044C\u0442\u0440", appendRight: jsx(Icon, { name: "CloseIcon", width: "16", height: "16" }) })] }));
|
|
4445
|
+
|
|
4446
|
+
const defaultRenderCard = () => null;
|
|
4447
|
+
const defaultFilterItems = () => [];
|
|
4448
|
+
const OfficesAtmsMapLayout = JSX(({ className, data = [], renderCard = defaultRenderCard, filterItems = defaultFilterItems, initFilterState = {}, descriptionData, title, }) => {
|
|
4449
|
+
const [filtrationState, { field, reset }] = useForm(initFilterState);
|
|
4450
|
+
const filteredItems = filterItems(data, filtrationState);
|
|
4451
|
+
const points = filteredItems
|
|
4452
|
+
.map((_) => [_.gpsLatitude, _.gpsLongitude].filter(Boolean))
|
|
4453
|
+
.filter((_) => _ && _.length === 2);
|
|
4454
|
+
const lengthItems = filteredItems.length;
|
|
4455
|
+
return (jsxs("div", { className: style('space-y-1', className), children: [jsxs("div", { className: "bg-white", children: [jsxs("div", { className: "pt-6xl px-6xl", children: [jsxs("div", { className: "flex gap-xs pb-2xl", children: [jsx(Heading, { headingType: "h2", children: title }), lengthItems ? (jsx(Text, { size: "text-h2", color: "text-secondary-text", children: `(${lengthItems})` })) : null] }), descriptionData ? renderDescriptionBlock$1(descriptionData) : null, renderFiltrationForm(Object.keys(initFilterState), { field, reset })] }), jsx("div", { className: "h-[600px]", children: jsx(ClientOnly, { children: jsx(YandexMap, { points: points, className: "h-full" }) }) })] }), filteredItems.map(renderCard)] }));
|
|
4456
|
+
});
|
|
4457
|
+
const renderDescriptionBlock$1 = (data) => (jsxs("div", { className: "p-xl mb-2xl border border-gray rounded-md", children: [data?.description ? (jsx(Paragraph, { size: "text-l", font: "font-light", children: data.description })) : null, data?.list?.length ? (jsx("div", { className: "flex gap-2xl flex-wrap pt-xs", children: data.list.map((item, i) => (jsxs("div", { className: "flex gap-xs items-center", children: [item?.image ? jsx(Img, { image: item.image }) : null, item?.text ? (jsx(Text, { size: "text-m", font: "font-light", children: item.text })) : null] }, String(i)))) })) : null] }));
|
|
4458
|
+
|
|
4438
4459
|
const colorStyle = {
|
|
4439
4460
|
yellow: { border: 'border-yellow-light', text: 'text-yellow' },
|
|
4440
4461
|
green: { border: 'border-green-light', text: 'text-green-dark' },
|
|
@@ -4475,6 +4496,47 @@
|
|
|
4475
4496
|
const renderInfo = (item, index) => (jsx(CardCell, { ...item }, String(index)));
|
|
4476
4497
|
const capitalizedFirstLetter = (text) => text ? `${text?.charAt(0)?.toUpperCase()}${text?.slice(1)}` : '';
|
|
4477
4498
|
|
|
4499
|
+
const EMPTY_VALUE$2 = [];
|
|
4500
|
+
function useAtms(regionCode) {
|
|
4501
|
+
const { data = EMPTY_VALUE$2 } = useAsyncData(`/api/v1/atms?regionCode=${regionCode}`, fetchMap$1);
|
|
4502
|
+
return data;
|
|
4503
|
+
}
|
|
4504
|
+
const fetchMap$1 = async (url) => {
|
|
4505
|
+
const result = await fetchJSON(url, { method: 'GET' });
|
|
4506
|
+
return result || EMPTY_VALUE$2;
|
|
4507
|
+
};
|
|
4508
|
+
|
|
4509
|
+
const INITIAL_FILTRATION_STATE$1 = {
|
|
4510
|
+
terminalTypeAtms: true,
|
|
4511
|
+
terminalTypeTerm: false,
|
|
4512
|
+
workAllTime: false,
|
|
4513
|
+
billAcceptorEnable: false,
|
|
4514
|
+
};
|
|
4515
|
+
const FILTRATION_PREDICATES$1 = {
|
|
4516
|
+
terminalTypeAtms: (item) => item.terminalType?.toLowerCase() === 'банкомат',
|
|
4517
|
+
terminalTypeTerm: (item) => item.terminalType?.toLowerCase() === 'терминал',
|
|
4518
|
+
workAllTime: (item) => item.workTime?.toLowerCase() === 'круглосуточно',
|
|
4519
|
+
billAcceptorEnable: (item) => Boolean(item.billAcceptorEnable),
|
|
4520
|
+
};
|
|
4521
|
+
const AtmsMap = JSX(({ data, className }) => {
|
|
4522
|
+
const [currentLocation] = useLocation();
|
|
4523
|
+
const regionCode = currentLocation?.code ?? '000';
|
|
4524
|
+
const officesData = useAtms(regionCode);
|
|
4525
|
+
return (jsx(OfficesAtmsMapLayout, { className: className, filterItems: filterItems$1, data: officesData, initFilterState: INITIAL_FILTRATION_STATE$1, renderCard: renderAtmCard, title: `Банкоматы филиала ${currentLocation?.name}`, descriptionData: data }));
|
|
4526
|
+
});
|
|
4527
|
+
const filterItems$1 = (data, filtrationState) => {
|
|
4528
|
+
const truthyFilters = Object.keys(filtrationState).filter((key) => filtrationState[key]);
|
|
4529
|
+
const filtersOR = truthyFilters.filter((_) => _.startsWith('terminalType'));
|
|
4530
|
+
const filtersAND = truthyFilters.filter((_) => !filtersOR.includes(_));
|
|
4531
|
+
return data.filter((item) => {
|
|
4532
|
+
const resultAND = filtersAND.every((_) => FILTRATION_PREDICATES$1[_](item));
|
|
4533
|
+
const resultOR = filtersOR.length
|
|
4534
|
+
? filtersOR.some((_) => FILTRATION_PREDICATES$1[_](item))
|
|
4535
|
+
: true;
|
|
4536
|
+
return resultAND && resultOR;
|
|
4537
|
+
});
|
|
4538
|
+
};
|
|
4539
|
+
|
|
4478
4540
|
const WEEKDAY_MAP = [
|
|
4479
4541
|
['Понедельник', 'workingMonday'],
|
|
4480
4542
|
['Вторник', 'workingTuesday'],
|
|
@@ -4513,67 +4575,39 @@
|
|
|
4513
4575
|
};
|
|
4514
4576
|
const renderDay = ({ title, status, workTime, lunchHour, hasLunch }, index) => (jsx(CardCell, { label: title, value: status && workTime ? workTime : '', subText: !status ? 'Выходной' : lunchHour, subColor: !status || hasLunch ? 'text-error' : 'text-green-dark' }, String(index)));
|
|
4515
4577
|
|
|
4516
|
-
const MAP_URL = {
|
|
4517
|
-
offices: '/api/v1/branches',
|
|
4518
|
-
atms: '/api/v1/atms',
|
|
4519
|
-
};
|
|
4520
4578
|
const EMPTY_VALUE$1 = [];
|
|
4521
|
-
function
|
|
4522
|
-
const { data } = useAsyncData(
|
|
4523
|
-
return data
|
|
4579
|
+
function useOffices(regionCode) {
|
|
4580
|
+
const { data = EMPTY_VALUE$1 } = useAsyncData(`/api/v1/branches?regionCode=${regionCode}`, fetchMap);
|
|
4581
|
+
return data;
|
|
4524
4582
|
}
|
|
4525
4583
|
const fetchMap = async (url) => {
|
|
4526
4584
|
const result = await fetchJSON(url, { method: 'GET' });
|
|
4527
4585
|
return result || EMPTY_VALUE$1;
|
|
4528
4586
|
};
|
|
4529
4587
|
|
|
4530
|
-
const
|
|
4531
|
-
safeBoxCaseVolumes: false,
|
|
4588
|
+
const INITIAL_FILTRATION_STATE = {
|
|
4589
|
+
//safeBoxCaseVolumes: false, //TODO: temp hide
|
|
4532
4590
|
workingSaturday: false,
|
|
4533
4591
|
};
|
|
4534
|
-
const INITIAL_FILTRATION_ATMS_STATE = {
|
|
4535
|
-
terminalTypeAtms: true,
|
|
4536
|
-
terminalTypeTerm: false,
|
|
4537
|
-
workAllTime: false,
|
|
4538
|
-
billAcceptorEnable: false,
|
|
4539
|
-
};
|
|
4540
|
-
const FILTRATION_LABELS = {
|
|
4541
|
-
safeBoxCaseVolumes: 'Аренда индивидуальных сейфовых ячеек',
|
|
4542
|
-
workingSaturday: 'Открыты по субботам',
|
|
4543
|
-
terminalTypeAtms: 'Банкоматы',
|
|
4544
|
-
terminalTypeTerm: 'Терминалы',
|
|
4545
|
-
workAllTime: 'Круглосуточно',
|
|
4546
|
-
billAcceptorEnable: 'Прием наличных',
|
|
4547
|
-
};
|
|
4548
4592
|
const FILTRATION_PREDICATES = {
|
|
4549
|
-
safeBoxCaseVolumes: (item) => Boolean(item.safeBoxCaseVolumes),
|
|
4593
|
+
//safeBoxCaseVolumes: (item: Branch) => Boolean(item.safeBoxCaseVolumes), //TODO: temp hide
|
|
4550
4594
|
workingSaturday: (item) => Boolean(item.workSchedule?.workingSaturday),
|
|
4551
|
-
terminalTypeAtms: (item) => item.terminalType?.toLowerCase() === 'банкомат',
|
|
4552
|
-
terminalTypeTerm: (item) => item.terminalType?.toLowerCase() === 'терминал',
|
|
4553
|
-
workAllTime: (item) => item.workTime?.toLowerCase() === 'круглосуточно',
|
|
4554
|
-
billAcceptorEnable: (item) => Boolean(item.billAcceptorEnable),
|
|
4555
4595
|
};
|
|
4556
|
-
const
|
|
4557
|
-
const dataType = data?.dataType ?? 'offices';
|
|
4558
|
-
const initialState = dataType === 'offices' ? INITIAL_FILTRATION_OFFICES_STATE : INITIAL_FILTRATION_ATMS_STATE;
|
|
4559
|
-
const [filtrationState, { field, reset }] = useForm(initialState);
|
|
4596
|
+
const OfficesMap = JSX(({ className }) => {
|
|
4560
4597
|
const [currentLocation] = useLocation();
|
|
4561
|
-
const
|
|
4562
|
-
const
|
|
4563
|
-
|
|
4564
|
-
const lengthOfficesAtms = filteredOfficesAtmsData.length;
|
|
4565
|
-
const points = filteredOfficesAtmsData
|
|
4566
|
-
.map((_) => [_.gpsLatitude, _.gpsLongitude].filter(Boolean))
|
|
4567
|
-
.filter((_) => _ && _.length === 2);
|
|
4568
|
-
return (jsxs(BlockWrapper, { version: "transparent", className: style('grid grid-cols-12 gap-1', className), defaultPadding: "p-0", ...rest, children: [jsxs("div", { className: "col-span-12 bg-white", children: [jsxs("div", { className: "pt-6xl px-6xl", children: [jsxs("div", { className: "flex gap-2 pb-2xl", children: [jsx(Heading, { headingType: "h2", children: title }), lengthOfficesAtms ? (jsx(Text, { size: "text-h2", color: "text-secondary-text", children: `(${lengthOfficesAtms})` })) : null] }), data && 'description' in data ? renderDescriptionBlock$1(data) : null, renderFiltrationForm(Object.keys(initialState), { field, reset })] }), jsx("div", { className: "h-[600px]", children: jsx(ClientOnly, { children: jsx(YandexMap, { points: points, className: "h-full" }) }) })] }), filteredOfficesAtmsData.map(dataType === 'offices' ? renderOfficeCard : renderAtmCard)] }));
|
|
4598
|
+
const regionCode = currentLocation?.code ?? '000';
|
|
4599
|
+
const officesData = useOffices(regionCode);
|
|
4600
|
+
return (jsx(OfficesAtmsMapLayout, { className: className, filterItems: filterItems, data: officesData, initFilterState: INITIAL_FILTRATION_STATE, renderCard: renderOfficeCard, title: `Офисы филиала ${currentLocation?.name}` }));
|
|
4569
4601
|
});
|
|
4570
|
-
const
|
|
4602
|
+
const filterItems = (data, filtrationState) => {
|
|
4571
4603
|
const truthyFilters = Object.keys(filtrationState).filter((key) => filtrationState[key]);
|
|
4572
|
-
return data.filter((item) => truthyFilters.every((
|
|
4604
|
+
return data.filter((item) => truthyFilters.every((_) => FILTRATION_PREDICATES[_](item)));
|
|
4573
4605
|
};
|
|
4574
|
-
|
|
4575
|
-
const
|
|
4576
|
-
|
|
4606
|
+
|
|
4607
|
+
const OfficesAtmsMap = JSX(({ data, className, ...rest }) => {
|
|
4608
|
+
const dataType = data?.dataType ?? 'offices';
|
|
4609
|
+
return (jsx(BlockWrapper, { version: "transparent", className: style(className), defaultPadding: "p-0", ...rest, children: dataType === 'offices' ? jsx(OfficesMap, {}) : jsx(AtmsMap, { data: data }) }));
|
|
4610
|
+
});
|
|
4577
4611
|
|
|
4578
4612
|
const ParagraphBlock = JSX(({ text, size, align, font, children, ...rest }) => (jsx(BlockWrapper, { defaultPadding: "p-0", ...rest, children: jsx(Paragraph, { size: size, align: align, font: font, children: text || children }) })));
|
|
4579
4613
|
|
|
@@ -5449,7 +5483,7 @@
|
|
|
5449
5483
|
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" }) }));
|
|
5450
5484
|
}
|
|
5451
5485
|
|
|
5452
|
-
const packageVersion = "0.14.
|
|
5486
|
+
const packageVersion = "0.14.16";
|
|
5453
5487
|
|
|
5454
5488
|
exports.Blocks = Blocks;
|
|
5455
5489
|
exports.ContentPage = ContentPage;
|