@redneckz/wildless-cms-uni-blocks 0.14.672 → 0.14.674
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/bundle.umd.js +24 -11
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/ui-kit/YandexMap/YandexMap.d.ts +1 -0
- package/dist/components/CreditCardForm/CreditCardForm.js +1 -1
- package/dist/components/CreditCardForm/CreditCardForm.js.map +1 -1
- package/dist/components/CreditCardForm/StepsNavigationButtons.js +2 -2
- package/dist/components/CreditCardForm/StepsNavigationButtons.js.map +1 -1
- package/dist/components/CreditForm/CreditForm.js +1 -1
- package/dist/components/CreditForm/CreditForm.js.map +1 -1
- package/dist/components/CreditForm/StepsNavigationButtons.js +2 -2
- package/dist/components/CreditForm/StepsNavigationButtons.js.map +1 -1
- package/dist/ui-kit/FormField/Fields/AddressRetailField.js +1 -1
- package/dist/ui-kit/FormField/Fields/AddressRetailField.js.map +1 -1
- package/dist/ui-kit/FormField/validators.js +4 -2
- package/dist/ui-kit/FormField/validators.js.map +1 -1
- package/dist/ui-kit/YandexMap/YandexMap.d.ts +1 -0
- package/dist/ui-kit/YandexMap/YandexMap.js +11 -2
- package/dist/ui-kit/YandexMap/YandexMap.js.map +1 -1
- package/lib/components/CreditCardForm/CreditCardForm.js +1 -1
- package/lib/components/CreditCardForm/CreditCardForm.js.map +1 -1
- package/lib/components/CreditCardForm/StepsNavigationButtons.js +2 -2
- package/lib/components/CreditCardForm/StepsNavigationButtons.js.map +1 -1
- package/lib/components/CreditForm/CreditForm.js +1 -1
- package/lib/components/CreditForm/CreditForm.js.map +1 -1
- package/lib/components/CreditForm/StepsNavigationButtons.js +2 -2
- package/lib/components/CreditForm/StepsNavigationButtons.js.map +1 -1
- package/lib/ui-kit/FormField/Fields/AddressRetailField.js +1 -1
- package/lib/ui-kit/FormField/Fields/AddressRetailField.js.map +1 -1
- package/lib/ui-kit/FormField/validators.js +4 -2
- package/lib/ui-kit/FormField/validators.js.map +1 -1
- package/lib/ui-kit/YandexMap/YandexMap.d.ts +1 -0
- package/lib/ui-kit/YandexMap/YandexMap.js +11 -2
- package/lib/ui-kit/YandexMap/YandexMap.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +24 -11
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/ui-kit/YandexMap/YandexMap.d.ts +1 -0
- package/mobile/dist/components/CreditCardForm/CreditCardForm.js +1 -1
- package/mobile/dist/components/CreditCardForm/CreditCardForm.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/StepsNavigationButtons.js +2 -2
- package/mobile/dist/components/CreditCardForm/StepsNavigationButtons.js.map +1 -1
- package/mobile/dist/components/CreditForm/CreditForm.js +1 -1
- package/mobile/dist/components/CreditForm/CreditForm.js.map +1 -1
- package/mobile/dist/components/CreditForm/StepsNavigationButtons.js +2 -2
- package/mobile/dist/components/CreditForm/StepsNavigationButtons.js.map +1 -1
- package/mobile/dist/ui-kit/FormField/Fields/AddressRetailField.js +1 -1
- package/mobile/dist/ui-kit/FormField/Fields/AddressRetailField.js.map +1 -1
- package/mobile/dist/ui-kit/FormField/validators.js +4 -2
- package/mobile/dist/ui-kit/FormField/validators.js.map +1 -1
- package/mobile/dist/ui-kit/YandexMap/YandexMap.d.ts +1 -0
- package/mobile/dist/ui-kit/YandexMap/YandexMap.js +11 -2
- package/mobile/dist/ui-kit/YandexMap/YandexMap.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/CreditCardForm.js +1 -1
- package/mobile/lib/components/CreditCardForm/CreditCardForm.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/StepsNavigationButtons.js +2 -2
- package/mobile/lib/components/CreditCardForm/StepsNavigationButtons.js.map +1 -1
- package/mobile/lib/components/CreditForm/CreditForm.js +1 -1
- package/mobile/lib/components/CreditForm/CreditForm.js.map +1 -1
- package/mobile/lib/components/CreditForm/StepsNavigationButtons.js +2 -2
- package/mobile/lib/components/CreditForm/StepsNavigationButtons.js.map +1 -1
- package/mobile/lib/ui-kit/FormField/Fields/AddressRetailField.js +1 -1
- package/mobile/lib/ui-kit/FormField/Fields/AddressRetailField.js.map +1 -1
- package/mobile/lib/ui-kit/FormField/validators.js +4 -2
- package/mobile/lib/ui-kit/FormField/validators.js.map +1 -1
- package/mobile/lib/ui-kit/YandexMap/YandexMap.d.ts +1 -0
- package/mobile/lib/ui-kit/YandexMap/YandexMap.js +11 -2
- package/mobile/lib/ui-kit/YandexMap/YandexMap.js.map +1 -1
- package/mobile/src/components/ApplicationLeadForm/ApplicationLeadForm.example.json +4 -5
- package/mobile/src/components/CreditCardForm/CreditCardForm.tsx +1 -1
- package/mobile/src/components/CreditCardForm/StepsNavigationButtons.tsx +3 -11
- package/mobile/src/components/CreditForm/CreditForm.tsx +1 -1
- package/mobile/src/components/CreditForm/StepsNavigationButtons.tsx +4 -12
- package/mobile/src/ui-kit/FormField/Fields/AddressRetailField.tsx +6 -1
- package/mobile/src/ui-kit/FormField/validators.ts +10 -5
- package/mobile/src/ui-kit/YandexMap/YandexMap.tsx +58 -45
- package/package.json +1 -1
- package/src/components/ApplicationForm/ApplicationForm.fixture.tsx +1 -1
- package/src/components/ApplicationLeadForm/ApplicationLeadForm.example.json +4 -5
- package/src/components/ApplicationLeadForm/ApplicationLeadForm.fixture.tsx +1 -1
- package/src/components/CreditCardForm/CreditCardForm.tsx +1 -1
- package/src/components/CreditCardForm/StepsNavigationButtons.tsx +3 -11
- package/src/components/CreditForm/CreditForm.tsx +1 -1
- package/src/components/CreditForm/StepsNavigationButtons.tsx +4 -12
- package/src/ui-kit/FormField/Fields/AddressRetailField.tsx +6 -1
- package/src/ui-kit/FormField/validators.ts +10 -5
- package/src/ui-kit/YandexMap/YandexMap.tsx +58 -45
|
@@ -16,6 +16,7 @@ interface YandexMapProps {
|
|
|
16
16
|
className?: string;
|
|
17
17
|
zoom?: number;
|
|
18
18
|
isLoad?: boolean;
|
|
19
|
+
selectedAddress?: string;
|
|
19
20
|
}
|
|
20
21
|
|
|
21
22
|
export const DEFAULT_CENTER_COORDS = [55.753995, 37.614069];
|
|
@@ -24,59 +25,71 @@ export const DEFAULT_CENTER_COORDS = [55.753995, 37.614069];
|
|
|
24
25
|
// Сейчас реализован поиск среди тестовых данных
|
|
25
26
|
// TODO: Также выяснить что делать когда ничего не найдено
|
|
26
27
|
// TODO: На макетах также когда есть поле поиска нет кнопки открыть на карте.
|
|
27
|
-
export const YandexMap = JSX<YandexMapProps>(
|
|
28
|
-
|
|
28
|
+
export const YandexMap = JSX<YandexMapProps>(
|
|
29
|
+
({ points, className = '', zoom = 5, isLoad, selectedAddress }) => {
|
|
30
|
+
const map = useRef<ymaps.Map | null>(null);
|
|
29
31
|
|
|
30
|
-
|
|
32
|
+
const parentDiv = useRef<HTMLElement>(null);
|
|
31
33
|
|
|
32
|
-
|
|
34
|
+
const yandexMaps = useYandexMaps();
|
|
33
35
|
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
36
|
+
useEffect(() => {
|
|
37
|
+
if (map.current) {
|
|
38
|
+
renderClusterer({ yandexMaps, map: map.current, points, isLoad });
|
|
39
|
+
} else {
|
|
40
|
+
yandexMaps?.ready(() => {
|
|
41
|
+
// Ready function may be called few times, but must be called once
|
|
42
|
+
if (map.current) {
|
|
43
|
+
renderClusterer({ yandexMaps, map: map.current, points, isLoad });
|
|
44
|
+
|
|
45
|
+
return;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
map.current = new yandexMaps.Map(parentDiv.current, {
|
|
49
|
+
center: getCenterPoint(points),
|
|
50
|
+
zoom,
|
|
51
|
+
controls: [],
|
|
52
|
+
suppressMapOpenBlock: true,
|
|
53
|
+
});
|
|
45
54
|
|
|
46
|
-
|
|
47
|
-
center: getCenterPoint(points),
|
|
48
|
-
zoom,
|
|
49
|
-
controls: [],
|
|
50
|
-
suppressMapOpenBlock: true,
|
|
55
|
+
renderClusterer({ yandexMaps, map: map.current, points, isLoad });
|
|
51
56
|
});
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
// zoom к выбранному отделению банка в рамках задачи по retail
|
|
60
|
+
if (map.current && selectedAddress) {
|
|
61
|
+
yandexMaps?.geocode(selectedAddress).then((res) => {
|
|
62
|
+
const firstGeoObject = res.geoObjects.get(0);
|
|
63
|
+
const coords = firstGeoObject.geometry.getCoordinates() as number[];
|
|
64
|
+
map.current.setCenter(coords);
|
|
65
|
+
map.current.setZoom(18);
|
|
66
|
+
});
|
|
67
|
+
}
|
|
68
|
+
}, [yandexMaps, points, zoom, isLoad, selectedAddress]);
|
|
52
69
|
|
|
53
|
-
|
|
54
|
-
|
|
70
|
+
if (!yandexMaps) {
|
|
71
|
+
return null;
|
|
55
72
|
}
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
return
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
)}
|
|
72
|
-
>
|
|
73
|
-
<ZoomButton yandexMaps={map} />
|
|
74
|
-
<ZoomButton yandexMaps={map} direction="out" />
|
|
73
|
+
|
|
74
|
+
const zIndex = 'z-10';
|
|
75
|
+
|
|
76
|
+
return (
|
|
77
|
+
<div ref={parentDiv} className={style('relative', 'w-full', className)}>
|
|
78
|
+
{isLoad ? <Loader /> : null}
|
|
79
|
+
<div
|
|
80
|
+
className={style(
|
|
81
|
+
'absolute right-2 top-52 z-10 w-12 overflow-hidden border border-transparent rounded-md',
|
|
82
|
+
zIndex,
|
|
83
|
+
)}
|
|
84
|
+
>
|
|
85
|
+
<ZoomButton yandexMaps={map} />
|
|
86
|
+
<ZoomButton yandexMaps={map} direction="out" />
|
|
87
|
+
</div>
|
|
88
|
+
{renderUserGeolocation(map, yandexMaps, style('right-2 top-80', zIndex))}
|
|
75
89
|
</div>
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
});
|
|
90
|
+
);
|
|
91
|
+
},
|
|
92
|
+
);
|
|
80
93
|
|
|
81
94
|
const getCenterPoint = (points?: BalloonPoints[]) => {
|
|
82
95
|
const centerCoords = [
|
package/package.json
CHANGED
|
@@ -34,7 +34,7 @@ export default {
|
|
|
34
34
|
sections={[
|
|
35
35
|
{
|
|
36
36
|
inputs: [
|
|
37
|
-
{ fieldType: 'common', name: '
|
|
37
|
+
{ fieldType: 'common', name: 'surname', required: true },
|
|
38
38
|
{ fieldType: 'common', name: 'middleName' },
|
|
39
39
|
{ fieldType: 'common', name: 'consentDataProcessing', required: true },
|
|
40
40
|
],
|
|
@@ -57,17 +57,16 @@
|
|
|
57
57
|
},
|
|
58
58
|
{
|
|
59
59
|
"fieldType": "common",
|
|
60
|
-
"name": "
|
|
60
|
+
"name": "consentOthersFlg",
|
|
61
|
+
"required": true
|
|
61
62
|
},
|
|
62
63
|
{
|
|
63
64
|
"fieldType": "common",
|
|
64
|
-
"name": "consentInformFlg"
|
|
65
|
-
"required": true
|
|
65
|
+
"name": "consentInformFlg"
|
|
66
66
|
},
|
|
67
67
|
{
|
|
68
68
|
"fieldType": "common",
|
|
69
|
-
"name": "
|
|
70
|
-
"required": true
|
|
69
|
+
"name": "consentPfrFlg"
|
|
71
70
|
}
|
|
72
71
|
]
|
|
73
72
|
}
|
|
@@ -32,9 +32,9 @@ export default {
|
|
|
32
32
|
{
|
|
33
33
|
inputs: [
|
|
34
34
|
{ fieldType: 'common', name: 'processPersonalDataFlg', required: true },
|
|
35
|
-
{ fieldType: 'common', name: 'consentInformFlg', required: true },
|
|
36
35
|
{ fieldType: 'common', name: 'consentProviderFlg', required: true },
|
|
37
36
|
{ fieldType: 'common', name: 'consentOthersFlg', required: true },
|
|
37
|
+
{ fieldType: 'common', name: 'consentInformFlg' },
|
|
38
38
|
{ fieldType: 'common', name: 'consentPfrFlg' },
|
|
39
39
|
],
|
|
40
40
|
},
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { JSX } from '@redneckz/uni-jsx';
|
|
2
2
|
import { Button } from '../../ui-kit/Button/Button';
|
|
3
|
-
import { style } from '../../utils/style';
|
|
4
3
|
|
|
5
4
|
export interface StepsNavigationButtonsProps {
|
|
6
5
|
step: number;
|
|
@@ -9,21 +8,14 @@ export interface StepsNavigationButtonsProps {
|
|
|
9
8
|
|
|
10
9
|
export const StepsNavigationButtons = JSX<StepsNavigationButtonsProps>(({ step, onPrevStep }) => {
|
|
11
10
|
const isFirstStep = step === 0;
|
|
11
|
+
const isFinalStep = step === 6;
|
|
12
12
|
|
|
13
13
|
return (
|
|
14
14
|
<div className="flex justify-between gap-m">
|
|
15
|
-
<Button
|
|
16
|
-
onClick={onPrevStep}
|
|
17
|
-
className={style('w-full @xl:w-auto')}
|
|
18
|
-
type="button"
|
|
19
|
-
version="secondary"
|
|
20
|
-
disabled={isFirstStep}
|
|
21
|
-
>
|
|
15
|
+
<Button onClick={onPrevStep} type="button" version="secondary" disabled={isFirstStep}>
|
|
22
16
|
Назад
|
|
23
17
|
</Button>
|
|
24
|
-
<Button
|
|
25
|
-
Далее
|
|
26
|
-
</Button>
|
|
18
|
+
<Button type="submit">{isFinalStep ? 'Отправить заявку' : 'Далее'}</Button>
|
|
27
19
|
</div>
|
|
28
20
|
);
|
|
29
21
|
});
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { JSX } from '@redneckz/uni-jsx';
|
|
2
2
|
import { Button } from '../../ui-kit/Button/Button';
|
|
3
|
-
import { style } from '../../utils/style';
|
|
4
3
|
|
|
5
4
|
export interface StepsNavigationButtonsProps {
|
|
6
5
|
step: number;
|
|
@@ -9,21 +8,14 @@ export interface StepsNavigationButtonsProps {
|
|
|
9
8
|
|
|
10
9
|
export const StepsNavigationButtons = JSX<StepsNavigationButtonsProps>(({ step, onPrevStep }) => {
|
|
11
10
|
const isFirstStep = step === 0;
|
|
11
|
+
const isFinalStep = step === 5;
|
|
12
12
|
|
|
13
13
|
return (
|
|
14
|
-
<div className={'flex justify-between'}>
|
|
15
|
-
<Button
|
|
16
|
-
onClick={onPrevStep}
|
|
17
|
-
className={style('w-full @xl:w-auto')}
|
|
18
|
-
type="button"
|
|
19
|
-
version="secondary"
|
|
20
|
-
disabled={isFirstStep}
|
|
21
|
-
>
|
|
14
|
+
<div className={'flex justify-between gap-m'}>
|
|
15
|
+
<Button onClick={onPrevStep} type="button" version="secondary" disabled={isFirstStep}>
|
|
22
16
|
Назад
|
|
23
17
|
</Button>
|
|
24
|
-
<Button
|
|
25
|
-
Далее
|
|
26
|
-
</Button>
|
|
18
|
+
<Button type="submit">{isFinalStep ? 'Отправить заявку' : 'Далее'}</Button>
|
|
27
19
|
</div>
|
|
28
20
|
);
|
|
29
21
|
});
|
|
@@ -56,7 +56,12 @@ export const AddressRetailField = JSX<CustomFieldProps>(({ field, input }) => {
|
|
|
56
56
|
/>
|
|
57
57
|
<div className="h-[600px]">
|
|
58
58
|
<ClientOnly>
|
|
59
|
-
<YandexMap
|
|
59
|
+
<YandexMap
|
|
60
|
+
points={points}
|
|
61
|
+
isLoad={!data}
|
|
62
|
+
className="h-full"
|
|
63
|
+
selectedAddress={fieldBranch?.value?.text}
|
|
64
|
+
/>
|
|
60
65
|
</ClientOnly>
|
|
61
66
|
</div>
|
|
62
67
|
</div>
|
|
@@ -16,7 +16,9 @@ export const jobNumberValidator = (errorMsg?: string) =>
|
|
|
16
16
|
);
|
|
17
17
|
|
|
18
18
|
export const nameValidator = (errorMsg?: string) =>
|
|
19
|
-
validator((_) => typeof _ === 'string' && _.length > 1
|
|
19
|
+
validator((_) => typeof _ === 'string' && _.length > 1 && isCyrillic(_))(
|
|
20
|
+
errorMsg ?? ERROR_MESSAGE,
|
|
21
|
+
);
|
|
20
22
|
|
|
21
23
|
export const lengthStringValidator = (inputLength: number, errorMsg?: string) =>
|
|
22
24
|
validator((_) => typeof _ === 'string' && _.length >= 1 && _.length <= inputLength)(
|
|
@@ -78,7 +80,10 @@ export const addressOrganizationValidator = () =>
|
|
|
78
80
|
);
|
|
79
81
|
|
|
80
82
|
export const codeWordValidator = (errorMsg?: string) =>
|
|
81
|
-
validator(
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
83
|
+
validator((_) => typeof _ === 'string' && _.length >= 3 && _.length <= 21 && isCyrillic(_))(
|
|
84
|
+
errorMsg ?? ERROR_MESSAGE,
|
|
85
|
+
);
|
|
86
|
+
|
|
87
|
+
const cyrillicPattern = /^[\u0400-\u04FF\d]+$/u;
|
|
88
|
+
|
|
89
|
+
const isCyrillic = (_ = '') => cyrillicPattern.test(_);
|
|
@@ -16,6 +16,7 @@ interface YandexMapProps {
|
|
|
16
16
|
className?: string;
|
|
17
17
|
zoom?: number;
|
|
18
18
|
isLoad?: boolean;
|
|
19
|
+
selectedAddress?: string;
|
|
19
20
|
}
|
|
20
21
|
|
|
21
22
|
export const DEFAULT_CENTER_COORDS = [55.753995, 37.614069];
|
|
@@ -24,59 +25,71 @@ export const DEFAULT_CENTER_COORDS = [55.753995, 37.614069];
|
|
|
24
25
|
// Сейчас реализован поиск среди тестовых данных
|
|
25
26
|
// TODO: Также выяснить что делать когда ничего не найдено
|
|
26
27
|
// TODO: На макетах также когда есть поле поиска нет кнопки открыть на карте.
|
|
27
|
-
export const YandexMap = JSX<YandexMapProps>(
|
|
28
|
-
|
|
28
|
+
export const YandexMap = JSX<YandexMapProps>(
|
|
29
|
+
({ points, className = '', zoom = 5, isLoad, selectedAddress }) => {
|
|
30
|
+
const map = useRef<ymaps.Map | null>(null);
|
|
29
31
|
|
|
30
|
-
|
|
32
|
+
const parentDiv = useRef<HTMLElement>(null);
|
|
31
33
|
|
|
32
|
-
|
|
34
|
+
const yandexMaps = useYandexMaps();
|
|
33
35
|
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
36
|
+
useEffect(() => {
|
|
37
|
+
if (map.current) {
|
|
38
|
+
renderClusterer({ yandexMaps, map: map.current, points, isLoad });
|
|
39
|
+
} else {
|
|
40
|
+
yandexMaps?.ready(() => {
|
|
41
|
+
// Ready function may be called few times, but must be called once
|
|
42
|
+
if (map.current) {
|
|
43
|
+
renderClusterer({ yandexMaps, map: map.current, points, isLoad });
|
|
44
|
+
|
|
45
|
+
return;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
map.current = new yandexMaps.Map(parentDiv.current, {
|
|
49
|
+
center: getCenterPoint(points),
|
|
50
|
+
zoom,
|
|
51
|
+
controls: [],
|
|
52
|
+
suppressMapOpenBlock: true,
|
|
53
|
+
});
|
|
45
54
|
|
|
46
|
-
|
|
47
|
-
center: getCenterPoint(points),
|
|
48
|
-
zoom,
|
|
49
|
-
controls: [],
|
|
50
|
-
suppressMapOpenBlock: true,
|
|
55
|
+
renderClusterer({ yandexMaps, map: map.current, points, isLoad });
|
|
51
56
|
});
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
// zoom к выбранному отделению банка в рамках задачи по retail
|
|
60
|
+
if (map.current && selectedAddress) {
|
|
61
|
+
yandexMaps?.geocode(selectedAddress).then((res) => {
|
|
62
|
+
const firstGeoObject = res.geoObjects.get(0);
|
|
63
|
+
const coords = firstGeoObject.geometry.getCoordinates() as number[];
|
|
64
|
+
map.current.setCenter(coords);
|
|
65
|
+
map.current.setZoom(18);
|
|
66
|
+
});
|
|
67
|
+
}
|
|
68
|
+
}, [yandexMaps, points, zoom, isLoad, selectedAddress]);
|
|
52
69
|
|
|
53
|
-
|
|
54
|
-
|
|
70
|
+
if (!yandexMaps) {
|
|
71
|
+
return null;
|
|
55
72
|
}
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
return
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
)}
|
|
72
|
-
>
|
|
73
|
-
<ZoomButton yandexMaps={map} />
|
|
74
|
-
<ZoomButton yandexMaps={map} direction="out" />
|
|
73
|
+
|
|
74
|
+
const zIndex = 'z-10';
|
|
75
|
+
|
|
76
|
+
return (
|
|
77
|
+
<div ref={parentDiv} className={style('relative', 'w-full', className)}>
|
|
78
|
+
{isLoad ? <Loader /> : null}
|
|
79
|
+
<div
|
|
80
|
+
className={style(
|
|
81
|
+
'absolute right-2 top-52 z-10 w-12 overflow-hidden border border-transparent rounded-md',
|
|
82
|
+
zIndex,
|
|
83
|
+
)}
|
|
84
|
+
>
|
|
85
|
+
<ZoomButton yandexMaps={map} />
|
|
86
|
+
<ZoomButton yandexMaps={map} direction="out" />
|
|
87
|
+
</div>
|
|
88
|
+
{renderUserGeolocation(map, yandexMaps, style('right-2 top-80', zIndex))}
|
|
75
89
|
</div>
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
});
|
|
90
|
+
);
|
|
91
|
+
},
|
|
92
|
+
);
|
|
80
93
|
|
|
81
94
|
const getCenterPoint = (points?: BalloonPoints[]) => {
|
|
82
95
|
const centerCoords = [
|