@ornikar/kitt-universal 9.26.0 → 9.28.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.
- package/babel-plugin-csf-to-jest.js +121 -0
- package/dist/definitions/Avatar/Avatar.d.ts +1 -7
- package/dist/definitions/Avatar/Avatar.d.ts.map +1 -1
- package/dist/definitions/Avatar/utils/getCurrentRadius.d.ts +9 -0
- package/dist/definitions/Avatar/utils/getCurrentRadius.d.ts.map +1 -0
- package/dist/definitions/Avatar/utils/getCurrentSize.d.ts +8 -0
- package/dist/definitions/Avatar/utils/getCurrentSize.d.ts.map +1 -0
- package/dist/definitions/Avatar/utils/getIconSize.d.ts +3 -0
- package/dist/definitions/Avatar/utils/getIconSize.d.ts.map +1 -0
- package/dist/definitions/Avatar/utils/getInitials.d.ts +2 -0
- package/dist/definitions/Avatar/utils/getInitials.d.ts.map +1 -0
- package/dist/definitions/KittMapConfigProvider/KittMapConfigProvider.d.ts +13 -0
- package/dist/definitions/KittMapConfigProvider/KittMapConfigProvider.d.ts.map +1 -0
- package/dist/definitions/KittMapConfigProvider/hooks/useKittMapConfig.d.ts +3 -0
- package/dist/definitions/KittMapConfigProvider/hooks/useKittMapConfig.d.ts.map +1 -0
- package/dist/definitions/MapMarker/MapMarker.d.ts +15 -0
- package/dist/definitions/MapMarker/MapMarker.d.ts.map +1 -0
- package/dist/definitions/ModalBehaviour/ModalBehaviourPortal.web.d.ts.map +1 -1
- package/dist/definitions/Skeleton/Skeleton.d.ts +15 -6
- package/dist/definitions/Skeleton/Skeleton.d.ts.map +1 -1
- package/dist/definitions/StaticMap/StaticMap.d.ts +34 -0
- package/dist/definitions/StaticMap/StaticMap.d.ts.map +1 -0
- package/dist/definitions/StaticMap/StaticMapError.d.ts +7 -0
- package/dist/definitions/StaticMap/StaticMapError.d.ts.map +1 -0
- package/dist/definitions/StaticMap/StaticMapImage.d.ts +12 -0
- package/dist/definitions/StaticMap/StaticMapImage.d.ts.map +1 -0
- package/dist/definitions/StaticMap/StaticMapLoader.d.ts +3 -0
- package/dist/definitions/StaticMap/StaticMapLoader.d.ts.map +1 -0
- package/dist/definitions/StaticMap/StaticMapMarker.d.ts +8 -0
- package/dist/definitions/StaticMap/StaticMapMarker.d.ts.map +1 -0
- package/dist/definitions/StaticMap/hooks/useGetStaticMapImageUrl.d.ts +8 -0
- package/dist/definitions/StaticMap/hooks/useGetStaticMapImageUrl.d.ts.map +1 -0
- package/dist/definitions/StaticMap/utils/getRangedWidthValue.d.ts +2 -0
- package/dist/definitions/StaticMap/utils/getRangedWidthValue.d.ts.map +1 -0
- package/dist/definitions/StaticMap/utils/getShouldDisplay2x.d.ts +2 -0
- package/dist/definitions/StaticMap/utils/getShouldDisplay2x.d.ts.map +1 -0
- package/dist/definitions/StaticMap/utils/getShouldDisplay2x.web.d.ts +2 -0
- package/dist/definitions/StaticMap/utils/getShouldDisplay2x.web.d.ts.map +1 -0
- package/dist/definitions/StaticMap/utils/getStaticMapImageUrl.d.ts +15 -0
- package/dist/definitions/StaticMap/utils/getStaticMapImageUrl.d.ts.map +1 -0
- package/dist/definitions/index.d.ts +9 -0
- package/dist/definitions/index.d.ts.map +1 -1
- package/dist/definitions/native-base/KittNativeBaseProvider.d.ts +121 -0
- package/dist/definitions/native-base/KittNativeBaseProvider.d.ts.map +1 -1
- package/dist/definitions/native-base/primitives.d.ts +17 -1
- package/dist/definitions/native-base/primitives.d.ts.map +1 -1
- package/dist/definitions/themes/late-ocean/avatar.d.ts +8 -0
- package/dist/definitions/themes/late-ocean/avatar.d.ts.map +1 -1
- package/dist/definitions/themes/late-ocean/skeleton.d.ts +6 -0
- package/dist/definitions/themes/late-ocean/skeleton.d.ts.map +1 -1
- package/dist/index-browser-all.es.android.js +796 -235
- package/dist/index-browser-all.es.android.js.map +1 -1
- package/dist/index-browser-all.es.ios.js +796 -235
- package/dist/index-browser-all.es.ios.js.map +1 -1
- package/dist/index-browser-all.es.js +852 -232
- package/dist/index-browser-all.es.js.map +1 -1
- package/dist/index-browser-all.es.web.js +865 -245
- package/dist/index-browser-all.es.web.js.map +1 -1
- package/dist/index-node-14.17.cjs.js +739 -134
- package/dist/index-node-14.17.cjs.js.map +1 -1
- package/dist/index-node-14.17.cjs.web.js +746 -136
- package/dist/index-node-14.17.cjs.web.js.map +1 -1
- package/dist/linaria-themes-browser-all.es.android.js +24 -2
- package/dist/linaria-themes-browser-all.es.android.js.map +1 -1
- package/dist/linaria-themes-browser-all.es.ios.js +24 -2
- package/dist/linaria-themes-browser-all.es.ios.js.map +1 -1
- package/dist/linaria-themes-browser-all.es.js +24 -2
- package/dist/linaria-themes-browser-all.es.js.map +1 -1
- package/dist/linaria-themes-browser-all.es.web.js +24 -2
- package/dist/linaria-themes-browser-all.es.web.js.map +1 -1
- package/dist/linaria-themes-node-14.17.cjs.js +24 -2
- package/dist/linaria-themes-node-14.17.cjs.js.map +1 -1
- package/dist/linaria-themes-node-14.17.cjs.web.js +24 -2
- package/dist/linaria-themes-node-14.17.cjs.web.js.map +1 -1
- package/dist/tsbuildinfo +1 -1
- package/package.json +2 -2
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import _objectSpread from '@babel/runtime/helpers/objectSpread2';
|
|
2
2
|
import _objectWithoutProperties from '@babel/runtime/helpers/objectWithoutProperties';
|
|
3
|
-
import { Stack as Stack$1, VStack as VStack$1, HStack as HStack$1, Center as Center$1, View as View$1, ScrollView as ScrollView$1, Pressable as Pressable$1, Image as Image$1, Text as Text$1, Input, NativeBaseProvider, extendTheme, useBreakpointValue } from 'native-base';
|
|
3
|
+
import { Stack as Stack$1, VStack as VStack$1, HStack as HStack$1, Center as Center$1, View as View$1, ScrollView as ScrollView$1, Pressable as Pressable$1, Image as Image$1, FlatList as FlatList$1, SectionList as SectionList$1, Text as Text$1, Input, NativeBaseProvider, extendTheme, useBreakpointValue } from 'native-base';
|
|
4
4
|
export { useBreakpointValue, useClipboard, useToken } from 'native-base';
|
|
5
5
|
import _extends from '@babel/runtime/helpers/extends';
|
|
6
6
|
import React, { useContext, createContext, cloneElement, forwardRef, useRef, useEffect, useState, useMemo, Children, Fragment as Fragment$1, useCallback } from 'react';
|
|
@@ -8,11 +8,11 @@ import Animated, { withSpring, useSharedValue, useAnimatedStyle, interpolateColo
|
|
|
8
8
|
import styled, { useTheme, css, withTheme as withTheme$1, ThemeProvider } from 'styled-components/native';
|
|
9
9
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
10
10
|
import _slicedToArray from '@babel/runtime/helpers/slicedToArray';
|
|
11
|
-
import { Platform, Animated as Animated$1, Easing, useWindowDimensions,
|
|
11
|
+
import { Platform, Animated as Animated$1, Easing, useWindowDimensions, View as View$2, Pressable as Pressable$2, StyleSheet, Modal as Modal$1, ScrollView as ScrollView$2, Linking, Text as Text$2, PixelRatio } from 'react-native';
|
|
12
12
|
export { useWindowDimensions as useWindowSize } from 'react-native';
|
|
13
13
|
import _asyncToGenerator from '@babel/runtime/helpers/asyncToGenerator';
|
|
14
14
|
import _regeneratorRuntime from '@babel/runtime/regenerator';
|
|
15
|
-
import { ArcIcon, UserIcon, CheckboxMark, XIcon, EyeOffIcon, EyeIcon, InfoIcon, AlertTriangleIcon, CheckIcon, AlertCircleIcon, TooltipArrowIcon } from '@ornikar/kitt-icons';
|
|
15
|
+
import { ArcIcon, UserIcon, CheckboxMark, XIcon, EyeOffIcon, EyeIcon, InfoIcon, AlertTriangleIcon, CheckIcon, AlertCircleIcon, RotateCCWIcon, TooltipArrowIcon } from '@ornikar/kitt-icons';
|
|
16
16
|
export * from '@ornikar/kitt-icons';
|
|
17
17
|
import { BottomSheetScrollView, BottomSheetView, useBottomSheetDynamicSnapPoints, BottomSheetModal, BottomSheetHandle, BottomSheetBackdrop } from '@gorhom/bottom-sheet';
|
|
18
18
|
import { SafeAreaView, useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
@@ -20,9 +20,9 @@ import { parse } from 'twemoji-parser';
|
|
|
20
20
|
import { openBrowserAsync } from 'expo-web-browser';
|
|
21
21
|
import DateTimePicker, { DateTimePickerAndroid } from '@react-native-community/datetimepicker';
|
|
22
22
|
import { FormattedMessage } from 'react-intl';
|
|
23
|
-
import Svg, { Circle as Circle$1 } from 'react-native-svg';
|
|
23
|
+
import Svg, { LinearGradient, Stop, Mask, Path, G, Defs, Circle as Circle$1 } from 'react-native-svg';
|
|
24
24
|
import { Picker as Picker$1 } from '@react-native-picker/picker';
|
|
25
|
-
import { LinearGradient } from 'expo-linear-gradient';
|
|
25
|
+
import { LinearGradient as LinearGradient$1 } from 'expo-linear-gradient';
|
|
26
26
|
import { useFloating, offset, autoPlacement } from '@floating-ui/react-native';
|
|
27
27
|
import { makeDecorator } from '@storybook/addons';
|
|
28
28
|
|
|
@@ -35,6 +35,10 @@ var View = View$1;
|
|
|
35
35
|
var ScrollView = ScrollView$1;
|
|
36
36
|
var Pressable = Pressable$1;
|
|
37
37
|
var Image = Image$1;
|
|
38
|
+
// See: https://fettblog.eu/typescript-react-generic-forward-refs/
|
|
39
|
+
var FlatList = FlatList$1;
|
|
40
|
+
// See: https://fettblog.eu/typescript-react-generic-forward-refs/
|
|
41
|
+
var SectionList = SectionList$1;
|
|
38
42
|
|
|
39
43
|
function createResponsiveStyleFromProp(responsiveBooleanValue, valueIfTrue, valueIfFalse) {
|
|
40
44
|
// Handles simple boolean values
|
|
@@ -141,7 +145,7 @@ var KittBreakpointNameEnum;
|
|
|
141
145
|
KittBreakpointNameEnum["WIDE"] = "wide";
|
|
142
146
|
})(KittBreakpointNameEnum || (KittBreakpointNameEnum = {}));
|
|
143
147
|
|
|
144
|
-
var _excluded$
|
|
148
|
+
var _excluded$y = ["accessibilityRole", "base", "small", "medium", "large", "wide", "type", "variant", "color"];
|
|
145
149
|
var IsHeaderTypographyContext = /*#__PURE__*/createContext(undefined);
|
|
146
150
|
var TypographyColorContext = /*#__PURE__*/createContext('black');
|
|
147
151
|
function useTypographyColor() {
|
|
@@ -213,7 +217,7 @@ function Typography(_ref) {
|
|
|
213
217
|
} : _ref$type,
|
|
214
218
|
variant = _ref.variant,
|
|
215
219
|
color = _ref.color,
|
|
216
|
-
otherProps = _objectWithoutProperties(_ref, _excluded$
|
|
220
|
+
otherProps = _objectWithoutProperties(_ref, _excluded$y);
|
|
217
221
|
|
|
218
222
|
var isHeaderTypographyInContext = useContext(IsHeaderTypographyContext);
|
|
219
223
|
var defaultColor = useTypographyDefaultColor();
|
|
@@ -346,12 +350,12 @@ function Icon(_ref5) {
|
|
|
346
350
|
});
|
|
347
351
|
}
|
|
348
352
|
|
|
349
|
-
var _excluded$
|
|
350
|
-
_excluded2$
|
|
353
|
+
var _excluded$x = ["color"],
|
|
354
|
+
_excluded2$5 = ["color"];
|
|
351
355
|
|
|
352
356
|
function TypographyIconSpecifiedColor(_ref) {
|
|
353
357
|
var color = _ref.color,
|
|
354
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
358
|
+
props = _objectWithoutProperties(_ref, _excluded$x);
|
|
355
359
|
|
|
356
360
|
var theme = /*#__PURE__*/useTheme();
|
|
357
361
|
return /*#__PURE__*/jsx(Icon, _objectSpread(_objectSpread({}, props), {}, {
|
|
@@ -368,7 +372,7 @@ function TypographyIconInheritColor(props) {
|
|
|
368
372
|
|
|
369
373
|
function TypographyIcon(_ref2) {
|
|
370
374
|
var color = _ref2.color,
|
|
371
|
-
props = _objectWithoutProperties(_ref2, _excluded2$
|
|
375
|
+
props = _objectWithoutProperties(_ref2, _excluded2$5);
|
|
372
376
|
|
|
373
377
|
if (color) {
|
|
374
378
|
return /*#__PURE__*/jsx(TypographyIconSpecifiedColor, _objectSpread({
|
|
@@ -403,7 +407,7 @@ var getTextColorByType = function (type, variant, isHovered, isPressed) {
|
|
|
403
407
|
}
|
|
404
408
|
};
|
|
405
409
|
|
|
406
|
-
var _excluded$
|
|
410
|
+
var _excluded$w = ["type", "variant", "isDisabled", "icon", "children", "isHovered", "isPressed", "isFocused"];
|
|
407
411
|
|
|
408
412
|
function ButtonIcon(_ref) {
|
|
409
413
|
var icon = _ref.icon,
|
|
@@ -481,7 +485,7 @@ function ButtonContent(_ref3) {
|
|
|
481
485
|
isHovered = _ref3.isHovered,
|
|
482
486
|
isPressed = _ref3.isPressed;
|
|
483
487
|
_ref3.isFocused;
|
|
484
|
-
var props = _objectWithoutProperties(_ref3, _excluded$
|
|
488
|
+
var props = _objectWithoutProperties(_ref3, _excluded$w);
|
|
485
489
|
|
|
486
490
|
var color = isDisabled ? 'black-light' : getTextColorByType(type, variant, isHovered, isPressed);
|
|
487
491
|
return /*#__PURE__*/jsx(View, {
|
|
@@ -832,7 +836,7 @@ function useMatchWindowSize(options) {
|
|
|
832
836
|
}, options);
|
|
833
837
|
}
|
|
834
838
|
|
|
835
|
-
var _excluded$
|
|
839
|
+
var _excluded$v = ["as", "onPress", "disabled", "icon", "stretch"];
|
|
836
840
|
|
|
837
841
|
function getCurrentStretchValue(isStretch, isMedium) {
|
|
838
842
|
// Stretch will follow the value passed from the component occurence if defined
|
|
@@ -846,7 +850,7 @@ function ActionsItem(_ref) {
|
|
|
846
850
|
disabled = _ref.disabled,
|
|
847
851
|
icon = _ref.icon,
|
|
848
852
|
stretch = _ref.stretch,
|
|
849
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
853
|
+
props = _objectWithoutProperties(_ref, _excluded$v);
|
|
850
854
|
|
|
851
855
|
var isMedium = useMatchWindowSize({
|
|
852
856
|
minWidth: KittBreakpoints.MEDIUM
|
|
@@ -936,7 +940,7 @@ function ActionsButton(_ref) {
|
|
|
936
940
|
}, props));
|
|
937
941
|
}
|
|
938
942
|
|
|
939
|
-
var _excluded$
|
|
943
|
+
var _excluded$u = ["children", "layout"];
|
|
940
944
|
|
|
941
945
|
function getCurrentLayout(layout) {
|
|
942
946
|
if (!layout) return {
|
|
@@ -959,7 +963,7 @@ function getCurrentDirection(layout) {
|
|
|
959
963
|
function Actions(_ref) {
|
|
960
964
|
var children = _ref.children,
|
|
961
965
|
layout = _ref.layout,
|
|
962
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
966
|
+
props = _objectWithoutProperties(_ref, _excluded$u);
|
|
963
967
|
|
|
964
968
|
var currentAlignItems = getCurrentLayout(layout);
|
|
965
969
|
var currentDirection = getCurrentDirection(layout);
|
|
@@ -975,51 +979,131 @@ function Actions(_ref) {
|
|
|
975
979
|
Actions.Button = ActionsButton;
|
|
976
980
|
Actions.Item = ActionsItem;
|
|
977
981
|
|
|
978
|
-
var
|
|
982
|
+
var lateOceanColorPalette = {
|
|
983
|
+
lateOcean: '#4C34E0',
|
|
984
|
+
lateOceanLight1: '#705DE6',
|
|
985
|
+
lateOceanLight2: '#9485EC',
|
|
986
|
+
lateOceanLight3: '#D6BAF9',
|
|
987
|
+
warmEmbrace: '#F4D3CE',
|
|
988
|
+
warmEmbraceLight1: '#FFEDE6',
|
|
989
|
+
black1000: '#000000',
|
|
990
|
+
black800: '#333333',
|
|
991
|
+
black555: '#737373',
|
|
992
|
+
black400: '#999999',
|
|
993
|
+
black200: '#CCCCCC',
|
|
994
|
+
black100: '#E5E5E5',
|
|
995
|
+
black50: '#F2F2F2',
|
|
996
|
+
black25: '#F9F9F9',
|
|
997
|
+
white: '#FFFFFF',
|
|
998
|
+
viride: '#38836D',
|
|
999
|
+
englishVermillon: '#D44148',
|
|
1000
|
+
goldCrayola: '#F8C583',
|
|
1001
|
+
aero: '#89BDDD',
|
|
1002
|
+
transparent: 'transparent',
|
|
1003
|
+
moonPurple: '#DBD6F9',
|
|
1004
|
+
moonPurpleLight1: '#EDEBFC'
|
|
1005
|
+
};
|
|
979
1006
|
|
|
980
|
-
var
|
|
981
|
-
|
|
1007
|
+
var colors = {
|
|
1008
|
+
primary: lateOceanColorPalette.lateOcean,
|
|
1009
|
+
primaryLight: lateOceanColorPalette.lateOceanLight1,
|
|
1010
|
+
accent: lateOceanColorPalette.warmEmbrace,
|
|
1011
|
+
accentLight: lateOceanColorPalette.warmEmbraceLight1,
|
|
1012
|
+
success: lateOceanColorPalette.viride,
|
|
1013
|
+
correct: lateOceanColorPalette.viride,
|
|
1014
|
+
danger: lateOceanColorPalette.englishVermillon,
|
|
1015
|
+
info: lateOceanColorPalette.aero,
|
|
1016
|
+
warning: lateOceanColorPalette.goldCrayola,
|
|
1017
|
+
separator: lateOceanColorPalette.black100,
|
|
1018
|
+
hover: lateOceanColorPalette.black100,
|
|
1019
|
+
white: lateOceanColorPalette.white,
|
|
1020
|
+
black: lateOceanColorPalette.black1000,
|
|
1021
|
+
blackDisabled: lateOceanColorPalette.black400,
|
|
1022
|
+
blackLight: lateOceanColorPalette.black555,
|
|
1023
|
+
blackAnthracite: lateOceanColorPalette.black800,
|
|
1024
|
+
uiBackground: lateOceanColorPalette.black25,
|
|
1025
|
+
uiBackgroundLight: lateOceanColorPalette.white,
|
|
1026
|
+
transparent: lateOceanColorPalette.transparent,
|
|
1027
|
+
disabled: lateOceanColorPalette.black50,
|
|
1028
|
+
overlay: {
|
|
1029
|
+
dark: 'rgba(41, 48, 51, 0.25)',
|
|
1030
|
+
light: 'rgba(255, 255, 255, 0.90)'
|
|
1031
|
+
}
|
|
982
1032
|
};
|
|
983
1033
|
|
|
984
|
-
var
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
},
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
}
|
|
1034
|
+
var defaultAvatarSize = 40;
|
|
1035
|
+
var defaultAvatarIconSize = 20;
|
|
1036
|
+
var largeAvatarSize = 120;
|
|
1037
|
+
var largeAvatarIconSize = 30;
|
|
1038
|
+
var avatar = {
|
|
1039
|
+
borderRadius: 10,
|
|
1040
|
+
size: defaultAvatarSize,
|
|
1041
|
+
iconSize: defaultAvatarIconSize,
|
|
1042
|
+
"default": {
|
|
1043
|
+
backgroundColor: colors.primary
|
|
1044
|
+
},
|
|
1045
|
+
light: {
|
|
1046
|
+
backgroundColor: lateOceanColorPalette.black100
|
|
1047
|
+
},
|
|
1048
|
+
large: {
|
|
1049
|
+
borderRadius: 30,
|
|
1050
|
+
size: largeAvatarSize,
|
|
1051
|
+
iconSize: largeAvatarIconSize
|
|
1052
|
+
}
|
|
1053
|
+
};
|
|
1004
1054
|
|
|
1005
|
-
function
|
|
1006
|
-
var size =
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1055
|
+
function getCurrentRadius(_ref) {
|
|
1056
|
+
var size = _ref.size,
|
|
1057
|
+
sizeVariant = _ref.sizeVariant,
|
|
1058
|
+
round = _ref.round;
|
|
1059
|
+
|
|
1060
|
+
if (round) {
|
|
1061
|
+
if (size) return size * 0.5;
|
|
1062
|
+
if (sizeVariant === 'large') return largeAvatarSize * 0.5;
|
|
1063
|
+
return defaultAvatarSize * 0.5;
|
|
1064
|
+
}
|
|
1065
|
+
|
|
1066
|
+
if (sizeVariant === 'large') return 'kitt.avatar.large.borderRadius';
|
|
1067
|
+
return 'kitt.avatar.borderRadius';
|
|
1068
|
+
}
|
|
1069
|
+
|
|
1070
|
+
function getCurrentSize(_ref) {
|
|
1071
|
+
var size = _ref.size,
|
|
1072
|
+
sizeVariant = _ref.sizeVariant;
|
|
1073
|
+
if (size) return size;
|
|
1074
|
+
if (sizeVariant === 'large') return 'kitt.avatar.large.size';
|
|
1075
|
+
return 'kitt.avatar.size';
|
|
1076
|
+
}
|
|
1077
|
+
|
|
1078
|
+
function getIconSize(size, sizeVariant) {
|
|
1079
|
+
if (typeof size === 'number') return size * 0.5;
|
|
1080
|
+
if (sizeVariant === 'large') return largeAvatarIconSize;
|
|
1081
|
+
return defaultAvatarIconSize;
|
|
1082
|
+
}
|
|
1083
|
+
|
|
1084
|
+
function getInitials(firstname, lastname) {
|
|
1085
|
+
return "".concat(firstname[0]).concat(lastname[0]).toUpperCase();
|
|
1086
|
+
}
|
|
1087
|
+
|
|
1088
|
+
var _excluded$t = ["size", "round", "light", "sizeVariant"];
|
|
1089
|
+
|
|
1090
|
+
function AvatarContent(_ref) {
|
|
1091
|
+
var size = _ref.size,
|
|
1092
|
+
src = _ref.src,
|
|
1093
|
+
firstname = _ref.firstname,
|
|
1094
|
+
lastname = _ref.lastname,
|
|
1095
|
+
alt = _ref.alt,
|
|
1096
|
+
isLight = _ref.isLight,
|
|
1097
|
+
sizeVariant = _ref.sizeVariant;
|
|
1013
1098
|
|
|
1014
1099
|
if (src) {
|
|
1015
|
-
return /*#__PURE__*/jsx(Image
|
|
1100
|
+
return /*#__PURE__*/jsx(Image, {
|
|
1016
1101
|
source: {
|
|
1017
1102
|
uri: src
|
|
1018
1103
|
},
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
},
|
|
1104
|
+
width: size,
|
|
1105
|
+
height: size,
|
|
1106
|
+
alt: alt,
|
|
1023
1107
|
accessibilityLabel: alt
|
|
1024
1108
|
});
|
|
1025
1109
|
}
|
|
@@ -1036,25 +1120,36 @@ function AvatarContent(_ref5) {
|
|
|
1036
1120
|
return /*#__PURE__*/jsx(Icon, {
|
|
1037
1121
|
icon: /*#__PURE__*/jsx(UserIcon, {}),
|
|
1038
1122
|
color: isLight ? 'black' : 'white',
|
|
1039
|
-
size: size
|
|
1123
|
+
size: getIconSize(size, sizeVariant)
|
|
1040
1124
|
});
|
|
1041
1125
|
}
|
|
1042
1126
|
|
|
1043
|
-
function Avatar(
|
|
1044
|
-
var
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
props = _objectWithoutProperties(_ref6, _excluded$r);
|
|
1127
|
+
function Avatar(_ref2) {
|
|
1128
|
+
var size = _ref2.size,
|
|
1129
|
+
round = _ref2.round,
|
|
1130
|
+
light = _ref2.light,
|
|
1131
|
+
sizeVariant = _ref2.sizeVariant,
|
|
1132
|
+
props = _objectWithoutProperties(_ref2, _excluded$t);
|
|
1050
1133
|
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1134
|
+
var currentSize = getCurrentSize({
|
|
1135
|
+
size: size,
|
|
1136
|
+
sizeVariant: sizeVariant
|
|
1137
|
+
});
|
|
1138
|
+
var currentBorderRadius = getCurrentRadius({
|
|
1139
|
+
size: size,
|
|
1140
|
+
sizeVariant: sizeVariant,
|
|
1141
|
+
round: round
|
|
1142
|
+
});
|
|
1143
|
+
return /*#__PURE__*/jsx(View, {
|
|
1144
|
+
overflow: "hidden",
|
|
1145
|
+
alignItems: "center",
|
|
1146
|
+
justifyContent: "center",
|
|
1147
|
+
width: currentSize,
|
|
1148
|
+
height: currentSize,
|
|
1149
|
+
borderRadius: currentBorderRadius,
|
|
1150
|
+
backgroundColor: "kitt.avatar.".concat(light ? 'light' : 'default', ".backgroundColor"),
|
|
1056
1151
|
children: /*#__PURE__*/jsx(AvatarContent, _objectSpread({
|
|
1057
|
-
size:
|
|
1152
|
+
size: currentSize,
|
|
1058
1153
|
isLight: light,
|
|
1059
1154
|
sizeVariant: sizeVariant
|
|
1060
1155
|
}, props))
|
|
@@ -1468,12 +1563,12 @@ function CardModalAnimation(_ref) {
|
|
|
1468
1563
|
});
|
|
1469
1564
|
}
|
|
1470
1565
|
|
|
1471
|
-
var _excluded$
|
|
1472
|
-
_excluded2$
|
|
1566
|
+
var _excluded$s = ["children"],
|
|
1567
|
+
_excluded2$4 = ["children", "visible", "onClose", "onExited"];
|
|
1473
1568
|
|
|
1474
1569
|
function ScrollContainer(_ref) {
|
|
1475
1570
|
var children = _ref.children,
|
|
1476
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
1571
|
+
props = _objectWithoutProperties(_ref, _excluded$s);
|
|
1477
1572
|
|
|
1478
1573
|
if (Platform.OS !== 'web') {
|
|
1479
1574
|
return /*#__PURE__*/jsx(View, {
|
|
@@ -1491,7 +1586,7 @@ function CardModalBehaviour(_ref2) {
|
|
|
1491
1586
|
visible = _ref2.visible,
|
|
1492
1587
|
onClose = _ref2.onClose,
|
|
1493
1588
|
onExited = _ref2.onExited,
|
|
1494
|
-
props = _objectWithoutProperties(_ref2, _excluded2$
|
|
1589
|
+
props = _objectWithoutProperties(_ref2, _excluded2$4);
|
|
1495
1590
|
|
|
1496
1591
|
var _useState = useState(visible),
|
|
1497
1592
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -1524,7 +1619,7 @@ function CardModalBehaviour(_ref2) {
|
|
|
1524
1619
|
});
|
|
1525
1620
|
}
|
|
1526
1621
|
|
|
1527
|
-
var _excluded$
|
|
1622
|
+
var _excluded$r = ["children", "paddingX", "paddingY"];
|
|
1528
1623
|
function CardModalBody(_ref) {
|
|
1529
1624
|
var children = _ref.children,
|
|
1530
1625
|
_ref$paddingX = _ref.paddingX,
|
|
@@ -1534,7 +1629,7 @@ function CardModalBody(_ref) {
|
|
|
1534
1629
|
} : _ref$paddingX,
|
|
1535
1630
|
_ref$paddingY = _ref.paddingY,
|
|
1536
1631
|
paddingY = _ref$paddingY === void 0 ? 'kitt.4' : _ref$paddingY,
|
|
1537
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
1632
|
+
props = _objectWithoutProperties(_ref, _excluded$r);
|
|
1538
1633
|
|
|
1539
1634
|
return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread({
|
|
1540
1635
|
paddingX: paddingX,
|
|
@@ -1544,7 +1639,7 @@ function CardModalBody(_ref) {
|
|
|
1544
1639
|
}));
|
|
1545
1640
|
}
|
|
1546
1641
|
|
|
1547
|
-
var _excluded$
|
|
1642
|
+
var _excluded$q = ["children", "padding", "hasSeparator"];
|
|
1548
1643
|
function CardModalFooter(_ref) {
|
|
1549
1644
|
var children = _ref.children,
|
|
1550
1645
|
_ref$padding = _ref.padding,
|
|
@@ -1554,7 +1649,7 @@ function CardModalFooter(_ref) {
|
|
|
1554
1649
|
} : _ref$padding,
|
|
1555
1650
|
_ref$hasSeparator = _ref.hasSeparator,
|
|
1556
1651
|
hasSeparator = _ref$hasSeparator === void 0 ? true : _ref$hasSeparator,
|
|
1557
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
1652
|
+
props = _objectWithoutProperties(_ref, _excluded$q);
|
|
1558
1653
|
|
|
1559
1654
|
return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread({}, props), {}, {
|
|
1560
1655
|
marginTop: "kitt.2",
|
|
@@ -1569,7 +1664,7 @@ function CardModalFooter(_ref) {
|
|
|
1569
1664
|
}));
|
|
1570
1665
|
}
|
|
1571
1666
|
|
|
1572
|
-
var _excluded$
|
|
1667
|
+
var _excluded$p = ["children", "title", "paddingBottom", "hasSeparator", "right", "left"];
|
|
1573
1668
|
function CardModalHeader(_ref) {
|
|
1574
1669
|
var children = _ref.children,
|
|
1575
1670
|
title = _ref.title,
|
|
@@ -1582,7 +1677,7 @@ function CardModalHeader(_ref) {
|
|
|
1582
1677
|
hasSeparator = _ref$hasSeparator === void 0 ? true : _ref$hasSeparator,
|
|
1583
1678
|
right = _ref.right,
|
|
1584
1679
|
left = _ref.left,
|
|
1585
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
1680
|
+
props = _objectWithoutProperties(_ref, _excluded$p);
|
|
1586
1681
|
|
|
1587
1682
|
var defaultContainerPadding = {
|
|
1588
1683
|
base: 'kitt.4',
|
|
@@ -1621,7 +1716,7 @@ function CardModalHeader(_ref) {
|
|
|
1621
1716
|
}));
|
|
1622
1717
|
}
|
|
1623
1718
|
|
|
1624
|
-
var _excluded$
|
|
1719
|
+
var _excluded$o = ["children", "backgroundColor", "maxWidth", "withoutShadow"];
|
|
1625
1720
|
function CardModal(_ref) {
|
|
1626
1721
|
var children = _ref.children,
|
|
1627
1722
|
_ref$backgroundColor = _ref.backgroundColor,
|
|
@@ -1629,7 +1724,7 @@ function CardModal(_ref) {
|
|
|
1629
1724
|
_ref$maxWidth = _ref.maxWidth,
|
|
1630
1725
|
maxWidth = _ref$maxWidth === void 0 ? 'kitt.cardModal.maxWidth' : _ref$maxWidth,
|
|
1631
1726
|
withoutShadow = _ref.withoutShadow,
|
|
1632
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
1727
|
+
props = _objectWithoutProperties(_ref, _excluded$o);
|
|
1633
1728
|
|
|
1634
1729
|
return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread({}, props), {}, {
|
|
1635
1730
|
overflow: "hidden",
|
|
@@ -1903,11 +1998,11 @@ var ChoiceItemContainer = /*#__PURE__*/styled(View$2).withConfig({
|
|
|
1903
1998
|
return css(["margin-bottom:", "px;"], $isLast ? 0 : column);
|
|
1904
1999
|
});
|
|
1905
2000
|
|
|
1906
|
-
var _excluded$
|
|
2001
|
+
var _excluded$n = ["direction"];
|
|
1907
2002
|
|
|
1908
2003
|
function ChoicesContainer(_ref) {
|
|
1909
2004
|
var direction = _ref.direction,
|
|
1910
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
2005
|
+
props = _objectWithoutProperties(_ref, _excluded$n);
|
|
1911
2006
|
|
|
1912
2007
|
if (direction === 'row') {
|
|
1913
2008
|
return /*#__PURE__*/jsx(ScrollView$2, _objectSpread({
|
|
@@ -2219,13 +2314,13 @@ function DialogModalAnimation(_ref) {
|
|
|
2219
2314
|
});
|
|
2220
2315
|
}
|
|
2221
2316
|
|
|
2222
|
-
var _excluded$
|
|
2317
|
+
var _excluded$m = ["children", "visible", "onClose", "onExited"];
|
|
2223
2318
|
function DialogModalBehaviour(_ref) {
|
|
2224
2319
|
var children = _ref.children,
|
|
2225
2320
|
visible = _ref.visible,
|
|
2226
2321
|
onClose = _ref.onClose,
|
|
2227
2322
|
onExited = _ref.onExited,
|
|
2228
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
2323
|
+
props = _objectWithoutProperties(_ref, _excluded$m);
|
|
2229
2324
|
|
|
2230
2325
|
var _useState = useState(visible),
|
|
2231
2326
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -2258,7 +2353,7 @@ function DialogModalBehaviour(_ref) {
|
|
|
2258
2353
|
});
|
|
2259
2354
|
}
|
|
2260
2355
|
|
|
2261
|
-
var _excluded$
|
|
2356
|
+
var _excluded$l = ["stretch"];
|
|
2262
2357
|
function DialogModal(_ref) {
|
|
2263
2358
|
var illustration = _ref.illustration,
|
|
2264
2359
|
title = _ref.title,
|
|
@@ -2300,7 +2395,7 @@ DialogModal.ModalBehaviour = DialogModalBehaviour;
|
|
|
2300
2395
|
function DialogModalButton(_ref2) {
|
|
2301
2396
|
var _ref2$stretch = _ref2.stretch,
|
|
2302
2397
|
stretch = _ref2$stretch === void 0 ? true : _ref2$stretch,
|
|
2303
|
-
props = _objectWithoutProperties(_ref2, _excluded$
|
|
2398
|
+
props = _objectWithoutProperties(_ref2, _excluded$l);
|
|
2304
2399
|
|
|
2305
2400
|
return /*#__PURE__*/jsx(Actions.Button, _objectSpread({
|
|
2306
2401
|
stretch: stretch
|
|
@@ -2339,17 +2434,17 @@ function Emoji(_ref) {
|
|
|
2339
2434
|
});
|
|
2340
2435
|
}
|
|
2341
2436
|
|
|
2342
|
-
var _excluded$
|
|
2343
|
-
_excluded2$
|
|
2344
|
-
_excluded3$
|
|
2345
|
-
_excluded4 = ["emailAddress", "children"];
|
|
2437
|
+
var _excluded$k = ["as", "appScheme", "appValue", "onPress", "onOpenAppError"],
|
|
2438
|
+
_excluded2$3 = ["phoneNumber", "children"],
|
|
2439
|
+
_excluded3$2 = ["phoneNumber", "children"],
|
|
2440
|
+
_excluded4$1 = ["emailAddress", "children"];
|
|
2346
2441
|
function ExternalAppLink(_ref) {
|
|
2347
2442
|
var Component = _ref.as,
|
|
2348
2443
|
appScheme = _ref.appScheme,
|
|
2349
2444
|
appValue = _ref.appValue,
|
|
2350
2445
|
onPress = _ref.onPress,
|
|
2351
2446
|
onOpenAppError = _ref.onOpenAppError,
|
|
2352
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
2447
|
+
rest = _objectWithoutProperties(_ref, _excluded$k);
|
|
2353
2448
|
|
|
2354
2449
|
var href = "".concat(appScheme, ":").concat(appValue);
|
|
2355
2450
|
|
|
@@ -2429,7 +2524,7 @@ function ExternalAppLink(_ref) {
|
|
|
2429
2524
|
ExternalAppLink.Sms = function (_ref3) {
|
|
2430
2525
|
var phoneNumber = _ref3.phoneNumber,
|
|
2431
2526
|
children = _ref3.children,
|
|
2432
|
-
rest = _objectWithoutProperties(_ref3, _excluded2$
|
|
2527
|
+
rest = _objectWithoutProperties(_ref3, _excluded2$3);
|
|
2433
2528
|
|
|
2434
2529
|
return /*#__PURE__*/jsx(ExternalAppLink, _objectSpread(_objectSpread({}, rest), {}, {
|
|
2435
2530
|
appScheme: "sms",
|
|
@@ -2441,7 +2536,7 @@ ExternalAppLink.Sms = function (_ref3) {
|
|
|
2441
2536
|
ExternalAppLink.Tel = function (_ref4) {
|
|
2442
2537
|
var phoneNumber = _ref4.phoneNumber,
|
|
2443
2538
|
children = _ref4.children,
|
|
2444
|
-
rest = _objectWithoutProperties(_ref4, _excluded3$
|
|
2539
|
+
rest = _objectWithoutProperties(_ref4, _excluded3$2);
|
|
2445
2540
|
|
|
2446
2541
|
return /*#__PURE__*/jsx(ExternalAppLink, _objectSpread(_objectSpread({}, rest), {}, {
|
|
2447
2542
|
appScheme: "tel",
|
|
@@ -2453,7 +2548,7 @@ ExternalAppLink.Tel = function (_ref4) {
|
|
|
2453
2548
|
ExternalAppLink.Mail = function (_ref5) {
|
|
2454
2549
|
var emailAddress = _ref5.emailAddress,
|
|
2455
2550
|
children = _ref5.children,
|
|
2456
|
-
rest = _objectWithoutProperties(_ref5, _excluded4);
|
|
2551
|
+
rest = _objectWithoutProperties(_ref5, _excluded4$1);
|
|
2457
2552
|
|
|
2458
2553
|
return /*#__PURE__*/jsx(ExternalAppLink, _objectSpread(_objectSpread({}, rest), {}, {
|
|
2459
2554
|
appScheme: "mailto",
|
|
@@ -2467,14 +2562,14 @@ var defaultOpenLinkBehavior = {
|
|
|
2467
2562
|
web: 'targetBlank'
|
|
2468
2563
|
};
|
|
2469
2564
|
|
|
2470
|
-
var _excluded$
|
|
2565
|
+
var _excluded$j = ["as", "href", "openLinkBehavior", "onPress"];
|
|
2471
2566
|
function ExternalLink(_ref) {
|
|
2472
2567
|
var Component = _ref.as,
|
|
2473
2568
|
href = _ref.href,
|
|
2474
2569
|
_ref$openLinkBehavior = _ref.openLinkBehavior,
|
|
2475
2570
|
openLinkBehavior = _ref$openLinkBehavior === void 0 ? defaultOpenLinkBehavior : _ref$openLinkBehavior,
|
|
2476
2571
|
onPress = _ref.onPress,
|
|
2477
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
2572
|
+
rest = _objectWithoutProperties(_ref, _excluded$j);
|
|
2478
2573
|
|
|
2479
2574
|
return /*#__PURE__*/jsx(Component, _objectSpread(_objectSpread({}, rest), {}, {
|
|
2480
2575
|
onPress: function handleOnPress(e) {
|
|
@@ -2509,71 +2604,6 @@ function ExternalLink(_ref) {
|
|
|
2509
2604
|
}));
|
|
2510
2605
|
}
|
|
2511
2606
|
|
|
2512
|
-
var lateOceanColorPalette = {
|
|
2513
|
-
lateOcean: '#4C34E0',
|
|
2514
|
-
lateOceanLight1: '#705DE6',
|
|
2515
|
-
lateOceanLight2: '#9485EC',
|
|
2516
|
-
lateOceanLight3: '#D6BAF9',
|
|
2517
|
-
warmEmbrace: '#F4D3CE',
|
|
2518
|
-
warmEmbraceLight1: '#FFEDE6',
|
|
2519
|
-
black1000: '#000000',
|
|
2520
|
-
black800: '#333333',
|
|
2521
|
-
black555: '#737373',
|
|
2522
|
-
black400: '#999999',
|
|
2523
|
-
black200: '#CCCCCC',
|
|
2524
|
-
black100: '#E5E5E5',
|
|
2525
|
-
black50: '#F2F2F2',
|
|
2526
|
-
black25: '#F9F9F9',
|
|
2527
|
-
white: '#FFFFFF',
|
|
2528
|
-
viride: '#38836D',
|
|
2529
|
-
englishVermillon: '#D44148',
|
|
2530
|
-
goldCrayola: '#F8C583',
|
|
2531
|
-
aero: '#89BDDD',
|
|
2532
|
-
transparent: 'transparent',
|
|
2533
|
-
moonPurple: '#DBD6F9',
|
|
2534
|
-
moonPurpleLight1: '#EDEBFC'
|
|
2535
|
-
};
|
|
2536
|
-
|
|
2537
|
-
var colors = {
|
|
2538
|
-
primary: lateOceanColorPalette.lateOcean,
|
|
2539
|
-
primaryLight: lateOceanColorPalette.lateOceanLight1,
|
|
2540
|
-
accent: lateOceanColorPalette.warmEmbrace,
|
|
2541
|
-
accentLight: lateOceanColorPalette.warmEmbraceLight1,
|
|
2542
|
-
success: lateOceanColorPalette.viride,
|
|
2543
|
-
correct: lateOceanColorPalette.viride,
|
|
2544
|
-
danger: lateOceanColorPalette.englishVermillon,
|
|
2545
|
-
info: lateOceanColorPalette.aero,
|
|
2546
|
-
warning: lateOceanColorPalette.goldCrayola,
|
|
2547
|
-
separator: lateOceanColorPalette.black100,
|
|
2548
|
-
hover: lateOceanColorPalette.black100,
|
|
2549
|
-
white: lateOceanColorPalette.white,
|
|
2550
|
-
black: lateOceanColorPalette.black1000,
|
|
2551
|
-
blackDisabled: lateOceanColorPalette.black400,
|
|
2552
|
-
blackLight: lateOceanColorPalette.black555,
|
|
2553
|
-
blackAnthracite: lateOceanColorPalette.black800,
|
|
2554
|
-
uiBackground: lateOceanColorPalette.black25,
|
|
2555
|
-
uiBackgroundLight: lateOceanColorPalette.white,
|
|
2556
|
-
transparent: lateOceanColorPalette.transparent,
|
|
2557
|
-
disabled: lateOceanColorPalette.black50,
|
|
2558
|
-
overlay: {
|
|
2559
|
-
dark: 'rgba(41, 48, 51, 0.25)',
|
|
2560
|
-
light: 'rgba(255, 255, 255, 0.90)'
|
|
2561
|
-
}
|
|
2562
|
-
};
|
|
2563
|
-
|
|
2564
|
-
var avatar = {
|
|
2565
|
-
borderRadius: 10,
|
|
2566
|
-
"default": {
|
|
2567
|
-
backgroundColor: colors.primary
|
|
2568
|
-
},
|
|
2569
|
-
light: {
|
|
2570
|
-
backgroundColor: lateOceanColorPalette.black100
|
|
2571
|
-
},
|
|
2572
|
-
large: {
|
|
2573
|
-
borderRadius: 30
|
|
2574
|
-
}
|
|
2575
|
-
};
|
|
2576
|
-
|
|
2577
2607
|
var spacing = 4;
|
|
2578
2608
|
|
|
2579
2609
|
var bottomSheet = {
|
|
@@ -3235,7 +3265,21 @@ var shadows = {
|
|
|
3235
3265
|
var skeleton = {
|
|
3236
3266
|
backgroundColor: lateOceanColorPalette.black100,
|
|
3237
3267
|
flareColor: lateOceanColorPalette.black200,
|
|
3238
|
-
animationDuration: 1000
|
|
3268
|
+
animationDuration: 1000,
|
|
3269
|
+
shape: {
|
|
3270
|
+
bar: {
|
|
3271
|
+
size: 8,
|
|
3272
|
+
borderRadius: 4
|
|
3273
|
+
},
|
|
3274
|
+
circle: {
|
|
3275
|
+
size: 48,
|
|
3276
|
+
borderRadius: 24
|
|
3277
|
+
},
|
|
3278
|
+
square: {
|
|
3279
|
+
size: 48,
|
|
3280
|
+
borderRadius: 6
|
|
3281
|
+
}
|
|
3282
|
+
}
|
|
3239
3283
|
};
|
|
3240
3284
|
|
|
3241
3285
|
var tag = {
|
|
@@ -3652,7 +3696,7 @@ function DatePickerInputs(_ref4) {
|
|
|
3652
3696
|
});
|
|
3653
3697
|
}
|
|
3654
3698
|
|
|
3655
|
-
var _excluded$
|
|
3699
|
+
var _excluded$i = ["onBlur", "onFocus", "pickerDefaultDate", "pickerUITestID", "isDefaultVisible", "setIsFocused", "currentValue", "setCurrentValue", "onChange", "isFocused"];
|
|
3656
3700
|
function DatePickerAndroid(_ref) {
|
|
3657
3701
|
var onBlur = _ref.onBlur,
|
|
3658
3702
|
onFocus = _ref.onFocus,
|
|
@@ -3664,7 +3708,7 @@ function DatePickerAndroid(_ref) {
|
|
|
3664
3708
|
setCurrentValue = _ref.setCurrentValue,
|
|
3665
3709
|
_onChange = _ref.onChange,
|
|
3666
3710
|
isFocused = _ref.isFocused,
|
|
3667
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
3711
|
+
props = _objectWithoutProperties(_ref, _excluded$i);
|
|
3668
3712
|
|
|
3669
3713
|
var handleClose = function () {
|
|
3670
3714
|
if (onBlur) onBlur();
|
|
@@ -3737,11 +3781,11 @@ function ModalFooter(_ref3) {
|
|
|
3737
3781
|
});
|
|
3738
3782
|
}
|
|
3739
3783
|
|
|
3740
|
-
var _excluded$
|
|
3784
|
+
var _excluded$h = ["as", "children"];
|
|
3741
3785
|
function StyleWebWrapper(_ref) {
|
|
3742
3786
|
var as = _ref.as,
|
|
3743
3787
|
children = _ref.children,
|
|
3744
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
3788
|
+
props = _objectWithoutProperties(_ref, _excluded$h);
|
|
3745
3789
|
|
|
3746
3790
|
if (Platform.OS !== 'web') return children;
|
|
3747
3791
|
// as or default to div. If as is undefined, T is div but typescript is not sure
|
|
@@ -3754,7 +3798,7 @@ function PressableIconButtonWebWrapperWithTheme() {
|
|
|
3754
3798
|
throw new Error('This component is not supposed to be called in native');
|
|
3755
3799
|
}
|
|
3756
3800
|
|
|
3757
|
-
var _excluded$
|
|
3801
|
+
var _excluded$g = ["color", "disabled"];
|
|
3758
3802
|
var PressableIconButtonWebWrapper = /*#__PURE__*/withTheme$1(PressableIconButtonWebWrapperWithTheme);
|
|
3759
3803
|
var StyledPressableIconButton = /*#__PURE__*/styled.Pressable.withConfig({
|
|
3760
3804
|
displayName: "PressableIconButton__StyledPressableIconButton"
|
|
@@ -3787,7 +3831,7 @@ var StyledPressableIconButton = /*#__PURE__*/styled.Pressable.withConfig({
|
|
|
3787
3831
|
function PressableIconButton(_ref5) {
|
|
3788
3832
|
var color = _ref5.color,
|
|
3789
3833
|
disabled = _ref5.disabled,
|
|
3790
|
-
props = _objectWithoutProperties(_ref5, _excluded$
|
|
3834
|
+
props = _objectWithoutProperties(_ref5, _excluded$g);
|
|
3791
3835
|
|
|
3792
3836
|
return /*#__PURE__*/jsx(StyleWebWrapper, {
|
|
3793
3837
|
as: PressableIconButtonWebWrapper,
|
|
@@ -4102,7 +4146,7 @@ function PlatformDateTimePicker(_ref) {
|
|
|
4102
4146
|
}));
|
|
4103
4147
|
}
|
|
4104
4148
|
|
|
4105
|
-
var _excluded$
|
|
4149
|
+
var _excluded$f = ["title", "isVisible", "value", "validateButtonLabel", "onClose", "onChange"];
|
|
4106
4150
|
|
|
4107
4151
|
function ModalTitle(_ref) {
|
|
4108
4152
|
var children = _ref.children;
|
|
@@ -4122,7 +4166,7 @@ function ModalPlatformDateTimePicker(_ref2) {
|
|
|
4122
4166
|
validateButtonLabel = _ref2.validateButtonLabel,
|
|
4123
4167
|
onClose = _ref2.onClose,
|
|
4124
4168
|
onChange = _ref2.onChange,
|
|
4125
|
-
props = _objectWithoutProperties(_ref2, _excluded$
|
|
4169
|
+
props = _objectWithoutProperties(_ref2, _excluded$f);
|
|
4126
4170
|
|
|
4127
4171
|
var _useState = useState(value),
|
|
4128
4172
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -4166,7 +4210,7 @@ function ModalPlatformDateTimePicker(_ref2) {
|
|
|
4166
4210
|
});
|
|
4167
4211
|
}
|
|
4168
4212
|
|
|
4169
|
-
var _excluded$
|
|
4213
|
+
var _excluded$e = ["value", "pickerUITestID", "pickerUITitle", "pickerUIValidateButtonLabel", "isDefaultVisible", "onChange", "onFocus", "onBlur", "pickerDefaultDate"];
|
|
4170
4214
|
function DatePicker(_ref) {
|
|
4171
4215
|
var value = _ref.value,
|
|
4172
4216
|
pickerUITestID = _ref.pickerUITestID,
|
|
@@ -4177,7 +4221,7 @@ function DatePicker(_ref) {
|
|
|
4177
4221
|
onFocus = _ref.onFocus,
|
|
4178
4222
|
onBlur = _ref.onBlur,
|
|
4179
4223
|
pickerDefaultDate = _ref.pickerDefaultDate,
|
|
4180
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
4224
|
+
props = _objectWithoutProperties(_ref, _excluded$e);
|
|
4181
4225
|
|
|
4182
4226
|
var _useState = useState(isDefaultVisible),
|
|
4183
4227
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -4244,7 +4288,7 @@ var InputTextContainer = /*#__PURE__*/styled.View.withConfig({
|
|
|
4244
4288
|
displayName: "InputTextContainer"
|
|
4245
4289
|
})(["position:relative;"]);
|
|
4246
4290
|
|
|
4247
|
-
var _excluded$
|
|
4291
|
+
var _excluded$d = ["id", "right", "state", "variant", "internalForceState", "disabled", "autoCorrect", "textContentType", "autoComplete", "keyboardType", "multiline", "onSubmitEditing"];
|
|
4248
4292
|
var InputText = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
4249
4293
|
var id = _ref.id,
|
|
4250
4294
|
right = _ref.right;
|
|
@@ -4264,7 +4308,7 @@ var InputText = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
4264
4308
|
keyboardType = _ref$keyboardType === void 0 ? 'default' : _ref$keyboardType,
|
|
4265
4309
|
multiline = _ref.multiline,
|
|
4266
4310
|
onSubmitEditing = _ref.onSubmitEditing,
|
|
4267
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
4311
|
+
props = _objectWithoutProperties(_ref, _excluded$d);
|
|
4268
4312
|
|
|
4269
4313
|
var theme = /*#__PURE__*/useTheme();
|
|
4270
4314
|
var fontSizeForNativeBase = createNativeBaseFontSize({
|
|
@@ -4398,11 +4442,11 @@ function InputPressable(_ref) {
|
|
|
4398
4442
|
return /*#__PURE__*/jsx(Pressable$2, _objectSpread({}, props));
|
|
4399
4443
|
}
|
|
4400
4444
|
|
|
4401
|
-
var _excluded$
|
|
4445
|
+
var _excluded$c = ["isPasswordDefaultVisible", "right"];
|
|
4402
4446
|
function InputPassword(_ref) {
|
|
4403
4447
|
var isPasswordDefaultVisible = _ref.isPasswordDefaultVisible,
|
|
4404
4448
|
right = _ref.right,
|
|
4405
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
4449
|
+
props = _objectWithoutProperties(_ref, _excluded$c);
|
|
4406
4450
|
|
|
4407
4451
|
var _useState = useState(Boolean(isPasswordDefaultVisible)),
|
|
4408
4452
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -4846,7 +4890,7 @@ function RadioButton(_ref) {
|
|
|
4846
4890
|
});
|
|
4847
4891
|
}
|
|
4848
4892
|
|
|
4849
|
-
var _excluded$
|
|
4893
|
+
var _excluded$b = ["children", "stretch", "value", "disabled", "onFocus", "onBlur", "onChange"];
|
|
4850
4894
|
|
|
4851
4895
|
function RadioButtonGroupItem(_ref) {
|
|
4852
4896
|
var props = _extends({}, _ref);
|
|
@@ -4862,7 +4906,7 @@ function RadioButtonGroup(_ref2) {
|
|
|
4862
4906
|
onFocus = _ref2.onFocus,
|
|
4863
4907
|
onBlur = _ref2.onBlur,
|
|
4864
4908
|
onChange = _ref2.onChange,
|
|
4865
|
-
props = _objectWithoutProperties(_ref2, _excluded$
|
|
4909
|
+
props = _objectWithoutProperties(_ref2, _excluded$b);
|
|
4866
4910
|
|
|
4867
4911
|
var _useState = useState(value),
|
|
4868
4912
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -4924,21 +4968,48 @@ function Highlight(_ref) {
|
|
|
4924
4968
|
});
|
|
4925
4969
|
}
|
|
4926
4970
|
|
|
4927
|
-
var
|
|
4971
|
+
var KittMapConfigProviderContext = /*#__PURE__*/createContext(undefined);
|
|
4972
|
+
function KittMapConfigProvider(_ref) {
|
|
4973
|
+
var children = _ref.children,
|
|
4974
|
+
mapId = _ref.mapId,
|
|
4975
|
+
apiToken = _ref.apiToken;
|
|
4976
|
+
var providerValue = useMemo(function () {
|
|
4977
|
+
return {
|
|
4978
|
+
mapId: mapId,
|
|
4979
|
+
apiToken: apiToken
|
|
4980
|
+
};
|
|
4981
|
+
}, [mapId, apiToken]);
|
|
4982
|
+
return /*#__PURE__*/jsx(KittMapConfigProviderContext.Provider, {
|
|
4983
|
+
value: providerValue,
|
|
4984
|
+
children: children
|
|
4985
|
+
});
|
|
4986
|
+
}
|
|
4987
|
+
|
|
4988
|
+
function useKittMapConfig() {
|
|
4989
|
+
var context = useContext(KittMapConfigProviderContext);
|
|
4990
|
+
|
|
4991
|
+
if (!context) {
|
|
4992
|
+
throw new Error('<KittMapConfigProvider> missing in the react tree');
|
|
4993
|
+
}
|
|
4994
|
+
|
|
4995
|
+
return context;
|
|
4996
|
+
}
|
|
4997
|
+
|
|
4998
|
+
var _excluded$a = ["children"];
|
|
4928
4999
|
var ContentView = /*#__PURE__*/styled.View.withConfig({
|
|
4929
5000
|
displayName: "ListItemContent__ContentView"
|
|
4930
5001
|
})(["flex:1 0 0%;align-self:center;"]);
|
|
4931
5002
|
function ListItemContent(_ref) {
|
|
4932
5003
|
var children = _ref.children,
|
|
4933
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
5004
|
+
rest = _objectWithoutProperties(_ref, _excluded$a);
|
|
4934
5005
|
|
|
4935
5006
|
return /*#__PURE__*/jsx(ContentView, _objectSpread(_objectSpread({}, rest), {}, {
|
|
4936
5007
|
children: children
|
|
4937
5008
|
}));
|
|
4938
5009
|
}
|
|
4939
5010
|
|
|
4940
|
-
var _excluded$
|
|
4941
|
-
_excluded2$
|
|
5011
|
+
var _excluded$9 = ["children", "side"],
|
|
5012
|
+
_excluded2$2 = ["children", "align"];
|
|
4942
5013
|
var SideContainerView = /*#__PURE__*/styled.View.withConfig({
|
|
4943
5014
|
displayName: "ListItemSideContent__SideContainerView"
|
|
4944
5015
|
})(["flex-direction:row;margin-left:", ";margin-right:", ";"], function (_ref) {
|
|
@@ -4955,7 +5026,7 @@ function ListItemSideContainer(_ref3) {
|
|
|
4955
5026
|
var children = _ref3.children,
|
|
4956
5027
|
_ref3$side = _ref3.side,
|
|
4957
5028
|
side = _ref3$side === void 0 ? 'left' : _ref3$side,
|
|
4958
|
-
rest = _objectWithoutProperties(_ref3, _excluded$
|
|
5029
|
+
rest = _objectWithoutProperties(_ref3, _excluded$9);
|
|
4959
5030
|
|
|
4960
5031
|
return /*#__PURE__*/jsx(SideContainerView, _objectSpread(_objectSpread({
|
|
4961
5032
|
side: side
|
|
@@ -4973,7 +5044,7 @@ function ListItemSideContent(_ref5) {
|
|
|
4973
5044
|
var children = _ref5.children,
|
|
4974
5045
|
_ref5$align = _ref5.align,
|
|
4975
5046
|
align = _ref5$align === void 0 ? 'auto' : _ref5$align,
|
|
4976
|
-
rest = _objectWithoutProperties(_ref5, _excluded2$
|
|
5047
|
+
rest = _objectWithoutProperties(_ref5, _excluded2$2);
|
|
4977
5048
|
|
|
4978
5049
|
return /*#__PURE__*/jsx(SideContentView, _objectSpread(_objectSpread({
|
|
4979
5050
|
align: align
|
|
@@ -4982,7 +5053,7 @@ function ListItemSideContent(_ref5) {
|
|
|
4982
5053
|
}));
|
|
4983
5054
|
}
|
|
4984
5055
|
|
|
4985
|
-
var _excluded$
|
|
5056
|
+
var _excluded$8 = ["children", "withPadding", "borders", "left", "right", "onPress"];
|
|
4986
5057
|
var ContainerView = /*#__PURE__*/styled.View.withConfig({
|
|
4987
5058
|
displayName: "ListItem__ContainerView"
|
|
4988
5059
|
})(["flex-direction:row;padding:", ";", ";border-color:", ";background-color:", ";"], function (_ref) {
|
|
@@ -5021,7 +5092,7 @@ function ListItem(_ref5) {
|
|
|
5021
5092
|
left = _ref5.left,
|
|
5022
5093
|
right = _ref5.right,
|
|
5023
5094
|
onPress = _ref5.onPress,
|
|
5024
|
-
rest = _objectWithoutProperties(_ref5, _excluded$
|
|
5095
|
+
rest = _objectWithoutProperties(_ref5, _excluded$8);
|
|
5025
5096
|
|
|
5026
5097
|
var Wrapper = onPress ? Pressable$2 : Fragment$1;
|
|
5027
5098
|
var wrapperProps = onPress ? _objectSpread({
|
|
@@ -5050,6 +5121,172 @@ ListItem.Content = ListItemContent;
|
|
|
5050
5121
|
ListItem.SideContent = ListItemSideContent;
|
|
5051
5122
|
ListItem.SideContainer = ListItemSideContainer;
|
|
5052
5123
|
|
|
5124
|
+
var SvgMarkerLargeinline = function SvgMarkerLargeinline(props) {
|
|
5125
|
+
return /*#__PURE__*/jsxs(Svg, _objectSpread(_objectSpread({
|
|
5126
|
+
fill: "none",
|
|
5127
|
+
viewBox: "0 0 54 56",
|
|
5128
|
+
width: 54,
|
|
5129
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
5130
|
+
}, props), {}, {
|
|
5131
|
+
children: [/*#__PURE__*/jsxs(LinearGradient, {
|
|
5132
|
+
id: "marker-large_inline_svg__b",
|
|
5133
|
+
gradientUnits: "userSpaceOnUse",
|
|
5134
|
+
x1: 26.828,
|
|
5135
|
+
x2: 7.181,
|
|
5136
|
+
y1: 5.072,
|
|
5137
|
+
y2: 39.102,
|
|
5138
|
+
children: [/*#__PURE__*/jsx(Stop, {
|
|
5139
|
+
offset: 0,
|
|
5140
|
+
stopOpacity: 0.01
|
|
5141
|
+
}), /*#__PURE__*/jsx(Stop, {
|
|
5142
|
+
offset: 1
|
|
5143
|
+
})]
|
|
5144
|
+
}), /*#__PURE__*/jsx(Mask, {
|
|
5145
|
+
id: "marker-large_inline_svg__c",
|
|
5146
|
+
height: 43,
|
|
5147
|
+
maskUnits: "userSpaceOnUse",
|
|
5148
|
+
width: 31,
|
|
5149
|
+
x: 3,
|
|
5150
|
+
y: 3,
|
|
5151
|
+
children: /*#__PURE__*/jsx(Path, {
|
|
5152
|
+
d: "M16.303 44.99a3.002 3.002 0 004.394 0C29.631 35.38 34 26.678 34 18.938 34 10.12 27.04 3 18.5 3S3 10.12 3 18.938c0 7.74 4.369 16.442 13.303 26.052z",
|
|
5153
|
+
fill: "#fff"
|
|
5154
|
+
})
|
|
5155
|
+
}), /*#__PURE__*/jsx(G, {
|
|
5156
|
+
filter: "url(#marker-large_inline_svg__a)",
|
|
5157
|
+
opacity: 0.25,
|
|
5158
|
+
children: /*#__PURE__*/jsx(Path, {
|
|
5159
|
+
d: "M24.022 48.149c-3.018 1.02-6.128-.775-6.753-3.899-1.372-6.862-2.799-18.548 1.348-25.73C22.966 10.985 32.545 8.374 40 12.678c7.454 4.303 9.982 13.903 5.63 21.44-4.146 7.182-14.98 11.79-21.608 14.032z",
|
|
5160
|
+
fill: "url(#marker-large_inline_svg__b)"
|
|
5161
|
+
})
|
|
5162
|
+
}), /*#__PURE__*/jsx(G, {
|
|
5163
|
+
mask: "url(#marker-large_inline_svg__c)",
|
|
5164
|
+
children: /*#__PURE__*/jsx(Path, {
|
|
5165
|
+
d: "M3 3h31v43H3z",
|
|
5166
|
+
fill: "#4c34e0"
|
|
5167
|
+
})
|
|
5168
|
+
}), /*#__PURE__*/jsx(Path, {
|
|
5169
|
+
d: "M15.677 46.315c-2.682-3.029-6.253-7.443-9.145-12.356C3.622 29.015 1.5 23.735 1.5 18.938 1.5 9.27 9.152 1.5 18.5 1.5c9.349 0 17 7.771 17 17.438 0 4.797-2.122 10.077-5.032 15.02-2.892 4.914-6.463 9.328-9.145 12.357-1.536 1.735-4.11 1.735-5.646 0z",
|
|
5170
|
+
stroke: "#fff",
|
|
5171
|
+
strokeWidth: 3
|
|
5172
|
+
})]
|
|
5173
|
+
}));
|
|
5174
|
+
};
|
|
5175
|
+
|
|
5176
|
+
var SvgMarkerinline = function SvgMarkerinline(props) {
|
|
5177
|
+
return /*#__PURE__*/jsxs(Svg, _objectSpread(_objectSpread({
|
|
5178
|
+
viewBox: "0 0 40 39",
|
|
5179
|
+
fill: "none",
|
|
5180
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
5181
|
+
}, props), {}, {
|
|
5182
|
+
children: [/*#__PURE__*/jsx(Path, {
|
|
5183
|
+
d: "M16.417 33.38c-2.3.776-4.668-.592-5.146-2.971-1.059-5.274-2.171-14.297 1.027-19.837 3.348-5.798 10.717-7.806 16.452-4.495 5.735 3.31 7.68 10.697 4.333 16.495-3.198 5.54-11.57 9.088-16.666 10.808z",
|
|
5184
|
+
fill: "url(#marker_inline_svg__a)",
|
|
5185
|
+
opacity: 0.25,
|
|
5186
|
+
filter: "url(#marker_inline_svg__b)"
|
|
5187
|
+
}), /*#__PURE__*/jsx(Path, {
|
|
5188
|
+
d: "M10.89 29.536a2.81 2.81 0 004.22 0C20.428 23.492 23 18.054 23 13.256 23 7.58 18.507 3 13 3S3 7.58 3 13.256c0 4.798 2.572 10.236 7.89 16.28z",
|
|
5189
|
+
fill: "#4C34E0"
|
|
5190
|
+
}), /*#__PURE__*/jsx(Mask, {
|
|
5191
|
+
id: "marker_inline_svg__c",
|
|
5192
|
+
style: {
|
|
5193
|
+
maskType: "alpha"
|
|
5194
|
+
},
|
|
5195
|
+
maskUnits: "userSpaceOnUse",
|
|
5196
|
+
x: 3,
|
|
5197
|
+
y: 3,
|
|
5198
|
+
width: 20,
|
|
5199
|
+
height: 28,
|
|
5200
|
+
children: /*#__PURE__*/jsx(Path, {
|
|
5201
|
+
d: "M10.89 29.536a2.81 2.81 0 004.22 0C20.428 23.492 23 18.054 23 13.256 23 7.58 18.507 3 13 3S3 7.58 3 13.256c0 4.798 2.572 10.236 7.89 16.28z",
|
|
5202
|
+
fill: "#fff"
|
|
5203
|
+
})
|
|
5204
|
+
}), /*#__PURE__*/jsx(G, {
|
|
5205
|
+
mask: "url(#marker_inline_svg__c)",
|
|
5206
|
+
children: /*#__PURE__*/jsx(Path, {
|
|
5207
|
+
fill: "#4C34E0",
|
|
5208
|
+
d: "M3 3h20v27H3z"
|
|
5209
|
+
})
|
|
5210
|
+
}), /*#__PURE__*/jsx(Path, {
|
|
5211
|
+
d: "M10.374 31c-1.884-2.216-4.125-5.144-5.888-8.307C2.71 19.505 1.5 16.22 1.5 13.256 1.5 6.734 6.681 1.5 13 1.5s11.5 5.234 11.5 11.756c0 2.964-1.21 6.249-2.986 9.437-1.763 3.163-4.004 6.091-5.888 8.307-1.414 1.662-3.838 1.662-5.252 0z",
|
|
5212
|
+
stroke: "#fff",
|
|
5213
|
+
strokeWidth: 3
|
|
5214
|
+
}), /*#__PURE__*/jsx(Defs, {
|
|
5215
|
+
children: /*#__PURE__*/jsxs(LinearGradient, {
|
|
5216
|
+
id: "marker_inline_svg__a",
|
|
5217
|
+
x1: 18.616,
|
|
5218
|
+
y1: 0.226,
|
|
5219
|
+
x2: 3.501,
|
|
5220
|
+
y2: 26.405,
|
|
5221
|
+
gradientUnits: "userSpaceOnUse",
|
|
5222
|
+
children: [/*#__PURE__*/jsx(Stop, {
|
|
5223
|
+
stopOpacity: 0.01
|
|
5224
|
+
}), /*#__PURE__*/jsx(Stop, {
|
|
5225
|
+
offset: 1
|
|
5226
|
+
})]
|
|
5227
|
+
})
|
|
5228
|
+
})]
|
|
5229
|
+
}));
|
|
5230
|
+
};
|
|
5231
|
+
|
|
5232
|
+
var SvgPositionMarkerinline = function SvgPositionMarkerinline(props) {
|
|
5233
|
+
return /*#__PURE__*/jsxs(Svg, _objectSpread(_objectSpread({
|
|
5234
|
+
viewBox: "0 0 47 47",
|
|
5235
|
+
fill: "none",
|
|
5236
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
5237
|
+
}, props), {}, {
|
|
5238
|
+
children: [/*#__PURE__*/jsx(Path, {
|
|
5239
|
+
fillRule: "evenodd",
|
|
5240
|
+
clipRule: "evenodd",
|
|
5241
|
+
d: "M23.5 36C30.404 36 36 30.404 36 23.5S30.404 11 23.5 11 11 16.596 11 23.5 16.596 36 23.5 36z",
|
|
5242
|
+
fill: "#38836D",
|
|
5243
|
+
opacity: 0.8,
|
|
5244
|
+
filter: "url(#position-marker_inline_svg__a)"
|
|
5245
|
+
}), /*#__PURE__*/jsx(Path, {
|
|
5246
|
+
d: "M31 18.5a7.5 7.5 0 11-15 0 7.5 7.5 0 0115 0z",
|
|
5247
|
+
fill: "#fff",
|
|
5248
|
+
stroke: "#38836D",
|
|
5249
|
+
strokeWidth: 10
|
|
5250
|
+
}), /*#__PURE__*/jsx(Circle$1, {
|
|
5251
|
+
cx: 23.5,
|
|
5252
|
+
cy: 18.5,
|
|
5253
|
+
r: 2.5,
|
|
5254
|
+
fill: "#fff"
|
|
5255
|
+
}), /*#__PURE__*/jsx(Defs, {})]
|
|
5256
|
+
}));
|
|
5257
|
+
};
|
|
5258
|
+
|
|
5259
|
+
function MapMarkerSimple(_ref) {
|
|
5260
|
+
var _ref$width = _ref.width,
|
|
5261
|
+
width = _ref$width === void 0 ? 40 : _ref$width,
|
|
5262
|
+
_ref$height = _ref.height,
|
|
5263
|
+
height = _ref$height === void 0 ? 39 : _ref$height;
|
|
5264
|
+
return /*#__PURE__*/jsx(SvgMarkerinline, {
|
|
5265
|
+
width: width,
|
|
5266
|
+
height: height
|
|
5267
|
+
});
|
|
5268
|
+
}
|
|
5269
|
+
function MapMarkerLarge(_ref2) {
|
|
5270
|
+
var _ref2$width = _ref2.width,
|
|
5271
|
+
width = _ref2$width === void 0 ? 54 : _ref2$width,
|
|
5272
|
+
_ref2$height = _ref2.height,
|
|
5273
|
+
height = _ref2$height === void 0 ? 56 : _ref2$height;
|
|
5274
|
+
return /*#__PURE__*/jsx(SvgMarkerLargeinline, {
|
|
5275
|
+
width: width,
|
|
5276
|
+
height: height
|
|
5277
|
+
});
|
|
5278
|
+
}
|
|
5279
|
+
function MapMarkerPosition(_ref3) {
|
|
5280
|
+
var _ref3$width = _ref3.width,
|
|
5281
|
+
width = _ref3$width === void 0 ? 47 : _ref3$width,
|
|
5282
|
+
_ref3$height = _ref3.height,
|
|
5283
|
+
height = _ref3$height === void 0 ? 47 : _ref3$height;
|
|
5284
|
+
return /*#__PURE__*/jsx(SvgPositionMarkerinline, {
|
|
5285
|
+
width: width,
|
|
5286
|
+
height: height
|
|
5287
|
+
});
|
|
5288
|
+
}
|
|
5289
|
+
|
|
5053
5290
|
function IconContent(_ref) {
|
|
5054
5291
|
var type = _ref.type,
|
|
5055
5292
|
color = _ref.color;
|
|
@@ -5222,6 +5459,14 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
|
|
|
5222
5459
|
var extendedTheme = extendTheme({
|
|
5223
5460
|
colors: {
|
|
5224
5461
|
kitt: _objectSpread(_objectSpread({}, theme.colors), {}, {
|
|
5462
|
+
avatar: {
|
|
5463
|
+
"default": {
|
|
5464
|
+
backgroundColor: theme.colors.primary
|
|
5465
|
+
},
|
|
5466
|
+
light: {
|
|
5467
|
+
backgroundColor: theme.palettes.lateOcean.black100
|
|
5468
|
+
}
|
|
5469
|
+
},
|
|
5225
5470
|
button: {
|
|
5226
5471
|
"default": theme.button["default"],
|
|
5227
5472
|
primary: theme.button.primary,
|
|
@@ -5241,13 +5486,30 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
|
|
|
5241
5486
|
borderColor: theme.forms.radioButtonGroup.item.borderColor,
|
|
5242
5487
|
backgroundColor: theme.forms.radioButtonGroup.item.backgroundColor
|
|
5243
5488
|
}
|
|
5489
|
+
},
|
|
5490
|
+
skeleton: {
|
|
5491
|
+
backgroundColor: theme.skeleton.backgroundColor,
|
|
5492
|
+
flareColor: theme.skeleton.flareColor
|
|
5244
5493
|
}
|
|
5245
5494
|
}
|
|
5246
5495
|
}),
|
|
5247
5496
|
app: appTheme === null || appTheme === void 0 ? void 0 : appTheme.colors
|
|
5248
5497
|
},
|
|
5249
|
-
radii: {
|
|
5498
|
+
radii: _objectSpread(_objectSpread({
|
|
5499
|
+
// Make original native base values unsusable
|
|
5500
|
+
lg: Number.MAX_SAFE_INTEGER,
|
|
5501
|
+
md: Number.MAX_SAFE_INTEGER,
|
|
5502
|
+
sm: Number.MAX_SAFE_INTEGER,
|
|
5503
|
+
xl: Number.MAX_SAFE_INTEGER,
|
|
5504
|
+
xs: Number.MAX_SAFE_INTEGER
|
|
5505
|
+
}, spaces), {}, {
|
|
5250
5506
|
kitt: {
|
|
5507
|
+
avatar: {
|
|
5508
|
+
borderRadius: theme.avatar.borderRadius,
|
|
5509
|
+
large: {
|
|
5510
|
+
borderRadius: theme.avatar.large.borderRadius
|
|
5511
|
+
}
|
|
5512
|
+
},
|
|
5251
5513
|
borderRadius: theme.card.borderRadius,
|
|
5252
5514
|
button: {
|
|
5253
5515
|
borderRadius: theme.button.borderRadius
|
|
@@ -5270,10 +5532,23 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
|
|
|
5270
5532
|
},
|
|
5271
5533
|
tooltip: {
|
|
5272
5534
|
borderRadius: theme.tooltip.borderRadius
|
|
5535
|
+
},
|
|
5536
|
+
skeleton: {
|
|
5537
|
+
shape: {
|
|
5538
|
+
bar: {
|
|
5539
|
+
borderRadius: theme.skeleton.shape.bar.borderRadius
|
|
5540
|
+
},
|
|
5541
|
+
circle: {
|
|
5542
|
+
borderRadius: theme.skeleton.shape.circle.borderRadius
|
|
5543
|
+
},
|
|
5544
|
+
square: {
|
|
5545
|
+
borderRadius: theme.skeleton.shape.square.borderRadius
|
|
5546
|
+
}
|
|
5547
|
+
}
|
|
5273
5548
|
}
|
|
5274
5549
|
},
|
|
5275
5550
|
app: appTheme === null || appTheme === void 0 ? void 0 : appTheme.radii
|
|
5276
|
-
},
|
|
5551
|
+
}),
|
|
5277
5552
|
borderWidths: {
|
|
5278
5553
|
kitt: {
|
|
5279
5554
|
button: {
|
|
@@ -5299,6 +5574,14 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
|
|
|
5299
5574
|
},
|
|
5300
5575
|
sizes: _objectSpread(_objectSpread(_objectSpread({}, spaces), overridenNativeBaseSizeandSpaceScale), {}, {
|
|
5301
5576
|
kitt: {
|
|
5577
|
+
avatar: {
|
|
5578
|
+
size: theme.avatar.size,
|
|
5579
|
+
iconSize: theme.avatar.iconSize,
|
|
5580
|
+
large: {
|
|
5581
|
+
size: theme.avatar.large.size,
|
|
5582
|
+
iconSize: theme.avatar.large.iconSize
|
|
5583
|
+
}
|
|
5584
|
+
},
|
|
5302
5585
|
button: {
|
|
5303
5586
|
minWidth: theme.button.minWidth,
|
|
5304
5587
|
maxWidth: theme.button.maxWidth,
|
|
@@ -5330,6 +5613,19 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
|
|
|
5330
5613
|
width: theme.tooltip.arrow.width,
|
|
5331
5614
|
height: theme.tooltip.arrow.height
|
|
5332
5615
|
}
|
|
5616
|
+
},
|
|
5617
|
+
skeleton: {
|
|
5618
|
+
shape: {
|
|
5619
|
+
bar: {
|
|
5620
|
+
size: theme.skeleton.shape.bar.size
|
|
5621
|
+
},
|
|
5622
|
+
circle: {
|
|
5623
|
+
size: theme.skeleton.shape.circle.size
|
|
5624
|
+
},
|
|
5625
|
+
square: {
|
|
5626
|
+
size: theme.skeleton.shape.square.size
|
|
5627
|
+
}
|
|
5628
|
+
}
|
|
5333
5629
|
}
|
|
5334
5630
|
},
|
|
5335
5631
|
app: appTheme === null || appTheme === void 0 ? void 0 : appTheme.sizes
|
|
@@ -5602,7 +5898,7 @@ function KittNativeBaseProvider(_ref) {
|
|
|
5602
5898
|
});
|
|
5603
5899
|
}
|
|
5604
5900
|
|
|
5605
|
-
var _excluded$
|
|
5901
|
+
var _excluded$7 = ["children"];
|
|
5606
5902
|
var ViewWithPadding = /*#__PURE__*/styled(View$2).withConfig({
|
|
5607
5903
|
displayName: "ContentPadding__ViewWithPadding"
|
|
5608
5904
|
})(["padding:", ";"], function (_ref) {
|
|
@@ -5611,14 +5907,14 @@ var ViewWithPadding = /*#__PURE__*/styled(View$2).withConfig({
|
|
|
5611
5907
|
});
|
|
5612
5908
|
function ContentPadding(_ref2) {
|
|
5613
5909
|
var children = _ref2.children,
|
|
5614
|
-
props = _objectWithoutProperties(_ref2, _excluded$
|
|
5910
|
+
props = _objectWithoutProperties(_ref2, _excluded$7);
|
|
5615
5911
|
|
|
5616
5912
|
return /*#__PURE__*/jsx(ViewWithPadding, _objectSpread(_objectSpread({}, props), {}, {
|
|
5617
5913
|
children: children
|
|
5618
5914
|
}));
|
|
5619
5915
|
}
|
|
5620
5916
|
|
|
5621
|
-
var _excluded$
|
|
5917
|
+
var _excluded$6 = ["children", "shouldHandleBottomNotch", "style"];
|
|
5622
5918
|
var StyledViewWithPadding = /*#__PURE__*/styled(ContentPadding).withConfig({
|
|
5623
5919
|
displayName: "Body__StyledViewWithPadding"
|
|
5624
5920
|
})(["padding-top:", "px;padding-bottom:", "px;"], function (_ref) {
|
|
@@ -5633,7 +5929,7 @@ function Body(_ref3) {
|
|
|
5633
5929
|
var children = _ref3.children,
|
|
5634
5930
|
shouldHandleBottomNotch = _ref3.shouldHandleBottomNotch,
|
|
5635
5931
|
style = _ref3.style,
|
|
5636
|
-
props = _objectWithoutProperties(_ref3, _excluded$
|
|
5932
|
+
props = _objectWithoutProperties(_ref3, _excluded$6);
|
|
5637
5933
|
|
|
5638
5934
|
var _useSafeAreaInsets = useSafeAreaInsets(),
|
|
5639
5935
|
bottom = _useSafeAreaInsets.bottom;
|
|
@@ -5994,13 +6290,13 @@ function NavigationModalAnimation(_ref) {
|
|
|
5994
6290
|
});
|
|
5995
6291
|
}
|
|
5996
6292
|
|
|
5997
|
-
var _excluded$
|
|
6293
|
+
var _excluded$5 = ["children", "visible", "onClose", "onExited"];
|
|
5998
6294
|
function NavigationModalBehaviour(_ref) {
|
|
5999
6295
|
var children = _ref.children,
|
|
6000
6296
|
visible = _ref.visible,
|
|
6001
6297
|
onClose = _ref.onClose,
|
|
6002
6298
|
onExited = _ref.onExited,
|
|
6003
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
6299
|
+
props = _objectWithoutProperties(_ref, _excluded$5);
|
|
6004
6300
|
|
|
6005
6301
|
var _useState = useState(visible),
|
|
6006
6302
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -6368,7 +6664,7 @@ var Container$2 = /*#__PURE__*/styled.View.withConfig({
|
|
|
6368
6664
|
var theme = _ref2.theme;
|
|
6369
6665
|
return theme.kitt.skeleton.flareColor;
|
|
6370
6666
|
});
|
|
6371
|
-
var AnimatedLinearGradient = Animated.createAnimatedComponent(LinearGradient);
|
|
6667
|
+
var AnimatedLinearGradient = Animated.createAnimatedComponent(LinearGradient$1);
|
|
6372
6668
|
function SkeletonContent(_ref3) {
|
|
6373
6669
|
var isLoading = _ref3.isLoading,
|
|
6374
6670
|
width = _ref3.width;
|
|
@@ -6419,19 +6715,23 @@ function SkeletonContent(_ref3) {
|
|
|
6419
6715
|
});
|
|
6420
6716
|
}
|
|
6421
6717
|
|
|
6422
|
-
var
|
|
6423
|
-
|
|
6424
|
-
|
|
6718
|
+
var _excluded$4 = ["isLoading", "style"],
|
|
6719
|
+
_excluded2$1 = ["size"],
|
|
6720
|
+
_excluded3$1 = ["size"],
|
|
6721
|
+
_excluded4 = ["size"];
|
|
6425
6722
|
function Skeleton(_ref) {
|
|
6426
|
-
var isLoading = _ref.isLoading,
|
|
6427
|
-
|
|
6723
|
+
var _ref$isLoading = _ref.isLoading,
|
|
6724
|
+
isLoading = _ref$isLoading === void 0 ? false : _ref$isLoading,
|
|
6725
|
+
style = _ref.style,
|
|
6726
|
+
props = _objectWithoutProperties(_ref, _excluded$4);
|
|
6428
6727
|
|
|
6429
6728
|
var _useState = useState(0),
|
|
6430
6729
|
_useState2 = _slicedToArray(_useState, 2),
|
|
6431
6730
|
width = _useState2[0],
|
|
6432
6731
|
setWidth = _useState2[1];
|
|
6433
6732
|
|
|
6434
|
-
return /*#__PURE__*/jsx(
|
|
6733
|
+
return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread({}, props), {}, {
|
|
6734
|
+
overflow: "hidden",
|
|
6435
6735
|
style: style,
|
|
6436
6736
|
onLayout: function onLayout(_ref2) {
|
|
6437
6737
|
var nativeEvent = _ref2.nativeEvent;
|
|
@@ -6441,45 +6741,306 @@ function Skeleton(_ref) {
|
|
|
6441
6741
|
isLoading: isLoading,
|
|
6442
6742
|
width: width
|
|
6443
6743
|
})
|
|
6444
|
-
});
|
|
6744
|
+
}));
|
|
6445
6745
|
}
|
|
6446
|
-
|
|
6447
|
-
|
|
6448
|
-
|
|
6449
|
-
|
|
6450
|
-
|
|
6451
|
-
|
|
6452
|
-
|
|
6453
|
-
|
|
6454
|
-
|
|
6455
|
-
|
|
6456
|
-
|
|
6457
|
-
}
|
|
6458
|
-
|
|
6459
|
-
|
|
6460
|
-
|
|
6461
|
-
|
|
6462
|
-
|
|
6463
|
-
|
|
6464
|
-
var
|
|
6465
|
-
return
|
|
6466
|
-
|
|
6467
|
-
|
|
6468
|
-
|
|
6469
|
-
})
|
|
6470
|
-
|
|
6471
|
-
|
|
6472
|
-
|
|
6473
|
-
var
|
|
6474
|
-
|
|
6475
|
-
|
|
6476
|
-
var
|
|
6477
|
-
|
|
6478
|
-
})
|
|
6746
|
+
|
|
6747
|
+
function Bar(_ref3) {
|
|
6748
|
+
var size = _ref3.size,
|
|
6749
|
+
props = _objectWithoutProperties(_ref3, _excluded2$1);
|
|
6750
|
+
|
|
6751
|
+
var currentBorderRadius = size ? size * 0.5 : 'kitt.skeleton.shape.bar.borderRadius';
|
|
6752
|
+
return /*#__PURE__*/jsx(Skeleton, _objectSpread(_objectSpread({}, props), {}, {
|
|
6753
|
+
width: "100%",
|
|
6754
|
+
height: size || 'kitt.skeleton.shape.bar.size',
|
|
6755
|
+
borderRadius: currentBorderRadius
|
|
6756
|
+
}));
|
|
6757
|
+
}
|
|
6758
|
+
|
|
6759
|
+
function Circle(_ref4) {
|
|
6760
|
+
var size = _ref4.size,
|
|
6761
|
+
props = _objectWithoutProperties(_ref4, _excluded3$1);
|
|
6762
|
+
|
|
6763
|
+
var currentSize = size || 'kitt.skeleton.shape.circle.size';
|
|
6764
|
+
var currentBorderRadius = size ? size * 0.5 : 'kitt.skeleton.shape.circle.borderRadius';
|
|
6765
|
+
return /*#__PURE__*/jsx(Skeleton, _objectSpread(_objectSpread({}, props), {}, {
|
|
6766
|
+
width: currentSize,
|
|
6767
|
+
height: currentSize,
|
|
6768
|
+
borderRadius: currentBorderRadius
|
|
6769
|
+
}));
|
|
6770
|
+
}
|
|
6771
|
+
|
|
6772
|
+
function Square(_ref5) {
|
|
6773
|
+
var size = _ref5.size,
|
|
6774
|
+
props = _objectWithoutProperties(_ref5, _excluded4);
|
|
6775
|
+
|
|
6776
|
+
var currentSize = size || 'kitt.skeleton.shape.square.size';
|
|
6777
|
+
var currentBorderRadius = size ? size * 0.5 : 'kitt.skeleton.shape.square.borderRadius';
|
|
6778
|
+
return /*#__PURE__*/jsx(Skeleton, _objectSpread(_objectSpread({}, props), {}, {
|
|
6779
|
+
width: currentSize,
|
|
6780
|
+
height: currentSize,
|
|
6781
|
+
borderRadius: currentBorderRadius
|
|
6782
|
+
}));
|
|
6783
|
+
}
|
|
6784
|
+
|
|
6479
6785
|
Skeleton.Bar = Bar;
|
|
6480
6786
|
Skeleton.Circle = Circle;
|
|
6481
6787
|
Skeleton.Square = Square;
|
|
6482
6788
|
|
|
6789
|
+
function getStaticMapImageUrl(_ref) {
|
|
6790
|
+
var mapId = _ref.mapId,
|
|
6791
|
+
apiToken = _ref.apiToken,
|
|
6792
|
+
mapWidth = _ref.mapWidth,
|
|
6793
|
+
mapHeight = _ref.mapHeight,
|
|
6794
|
+
center = _ref.center,
|
|
6795
|
+
is2x = _ref.is2x;
|
|
6796
|
+
var width = Math.round(mapWidth);
|
|
6797
|
+
var height = Math.round(mapHeight);
|
|
6798
|
+
var centerPart = "".concat(center["long"], ",").concat(center.lat, ",").concat(center.zoom, "/");
|
|
6799
|
+
var sizePart = "".concat(width, "x").concat(height);
|
|
6800
|
+
var urlParts = ["https://api.mapbox.com/styles/v1/ornikar/".concat(mapId, "/static/"), centerPart, sizePart, is2x ? '@2x' : ''];
|
|
6801
|
+
var mapImageUrl = new URL(urlParts.join(''));
|
|
6802
|
+
mapImageUrl.searchParams.append('access_token', apiToken);
|
|
6803
|
+
return mapImageUrl.toString();
|
|
6804
|
+
}
|
|
6805
|
+
|
|
6806
|
+
function useGetStaticMapImageUrl(_ref) {
|
|
6807
|
+
var forceMapId = _ref.forceMapId,
|
|
6808
|
+
forceApiToken = _ref.forceApiToken,
|
|
6809
|
+
mapWidth = _ref.mapWidth,
|
|
6810
|
+
mapHeight = _ref.mapHeight,
|
|
6811
|
+
center = _ref.center,
|
|
6812
|
+
is2x = _ref.is2x;
|
|
6813
|
+
|
|
6814
|
+
var _useKittMapConfig = useKittMapConfig(),
|
|
6815
|
+
mapId = _useKittMapConfig.mapId,
|
|
6816
|
+
apiToken = _useKittMapConfig.apiToken;
|
|
6817
|
+
|
|
6818
|
+
var _useState = useState(''),
|
|
6819
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
6820
|
+
currentUrl = _useState2[0],
|
|
6821
|
+
setCurrentUrl = _useState2[1];
|
|
6822
|
+
|
|
6823
|
+
var currentMapIdRef = useRef(forceMapId || mapId);
|
|
6824
|
+
var currentApiTokenRef = useRef(forceApiToken || apiToken);
|
|
6825
|
+
useEffect(function () {
|
|
6826
|
+
var newUrl = getStaticMapImageUrl({
|
|
6827
|
+
center: center,
|
|
6828
|
+
is2x: is2x,
|
|
6829
|
+
mapHeight: mapHeight,
|
|
6830
|
+
mapWidth: mapWidth,
|
|
6831
|
+
mapId: currentMapIdRef.current,
|
|
6832
|
+
apiToken: currentApiTokenRef.current
|
|
6833
|
+
});
|
|
6834
|
+
setCurrentUrl(newUrl);
|
|
6835
|
+
}, [mapHeight, mapWidth, center, is2x]);
|
|
6836
|
+
return currentUrl;
|
|
6837
|
+
}
|
|
6838
|
+
|
|
6839
|
+
function StaticMapError(_ref) {
|
|
6840
|
+
var onReload = _ref.onReload;
|
|
6841
|
+
return /*#__PURE__*/jsx(View, {
|
|
6842
|
+
alignItems: "center",
|
|
6843
|
+
justifyContent: "center",
|
|
6844
|
+
height: "100%",
|
|
6845
|
+
backgroundColor: "kitt.separator",
|
|
6846
|
+
children: /*#__PURE__*/jsx(IconButton, {
|
|
6847
|
+
icon: /*#__PURE__*/jsx(RotateCCWIcon, {}),
|
|
6848
|
+
onPress: onReload
|
|
6849
|
+
})
|
|
6850
|
+
});
|
|
6851
|
+
}
|
|
6852
|
+
|
|
6853
|
+
function StaticMapImage(_ref) {
|
|
6854
|
+
var url = _ref.url,
|
|
6855
|
+
alt = _ref.alt,
|
|
6856
|
+
width = _ref.width,
|
|
6857
|
+
height = _ref.height,
|
|
6858
|
+
onLoadEnd = _ref.onLoadEnd,
|
|
6859
|
+
onError = _ref.onError;
|
|
6860
|
+
return /*#__PURE__*/jsx(Image, {
|
|
6861
|
+
source: {
|
|
6862
|
+
uri: url
|
|
6863
|
+
},
|
|
6864
|
+
width: width,
|
|
6865
|
+
height: height,
|
|
6866
|
+
alt: alt,
|
|
6867
|
+
onError: onError,
|
|
6868
|
+
onLoadEnd: onLoadEnd
|
|
6869
|
+
});
|
|
6870
|
+
}
|
|
6871
|
+
|
|
6872
|
+
function StaticMapLoader() {
|
|
6873
|
+
return /*#__PURE__*/jsx(View, {
|
|
6874
|
+
alignItems: "center",
|
|
6875
|
+
justifyContent: "center",
|
|
6876
|
+
height: "100%",
|
|
6877
|
+
children: /*#__PURE__*/jsx(Skeleton, {
|
|
6878
|
+
isLoading: true,
|
|
6879
|
+
width: "100%",
|
|
6880
|
+
height: "100%"
|
|
6881
|
+
})
|
|
6882
|
+
});
|
|
6883
|
+
}
|
|
6884
|
+
|
|
6885
|
+
function getMarkerPosition(variant) {
|
|
6886
|
+
if (variant === 'position') return [{
|
|
6887
|
+
translateX: -2
|
|
6888
|
+
}, {
|
|
6889
|
+
translateY: 8
|
|
6890
|
+
}];
|
|
6891
|
+
if (variant === 'large') return [{
|
|
6892
|
+
translateX: 8
|
|
6893
|
+
}, {
|
|
6894
|
+
translateY: -20
|
|
6895
|
+
}];
|
|
6896
|
+
return [{
|
|
6897
|
+
translateX: 6
|
|
6898
|
+
}, {
|
|
6899
|
+
translateY: -15
|
|
6900
|
+
}];
|
|
6901
|
+
}
|
|
6902
|
+
|
|
6903
|
+
function StaticMapMarker(_ref) {
|
|
6904
|
+
var _ref$variant = _ref.variant,
|
|
6905
|
+
variant = _ref$variant === void 0 ? 'simple' : _ref$variant;
|
|
6906
|
+
return /*#__PURE__*/jsx(View, {
|
|
6907
|
+
position: "absolute",
|
|
6908
|
+
top: "0",
|
|
6909
|
+
left: "0",
|
|
6910
|
+
width: "100%",
|
|
6911
|
+
height: "100%",
|
|
6912
|
+
children: /*#__PURE__*/jsxs(View, {
|
|
6913
|
+
justifyContent: "center",
|
|
6914
|
+
alignItems: "center",
|
|
6915
|
+
height: "100%",
|
|
6916
|
+
style: {
|
|
6917
|
+
transform: getMarkerPosition(variant)
|
|
6918
|
+
},
|
|
6919
|
+
children: [variant === 'position' ? /*#__PURE__*/jsx(MapMarkerPosition, {}) : null, variant === 'large' ? /*#__PURE__*/jsx(MapMarkerLarge, {}) : null, variant === 'simple' ? /*#__PURE__*/jsx(MapMarkerSimple, {}) : null]
|
|
6920
|
+
})
|
|
6921
|
+
});
|
|
6922
|
+
}
|
|
6923
|
+
|
|
6924
|
+
function getRangedWidthValue(nextWidth, maxValue) {
|
|
6925
|
+
var rangedMapWidth = Math.max(1, Math.min(nextWidth, maxValue));
|
|
6926
|
+
return rangedMapWidth;
|
|
6927
|
+
}
|
|
6928
|
+
|
|
6929
|
+
function getShouldDisplay2x() {
|
|
6930
|
+
var currentDevicePixelRatio = PixelRatio.get();
|
|
6931
|
+
return currentDevicePixelRatio > 1;
|
|
6932
|
+
}
|
|
6933
|
+
|
|
6934
|
+
var _excluded$3 = ["width", "height", "alt", "apiToken", "mapId", "marker", "center", "onLoaded", "onError"];
|
|
6935
|
+
var mapBoxMaxPictureWidth = 1280; // Mapbox requestable width for image is between 1 - 1280px
|
|
6936
|
+
|
|
6937
|
+
function getPictureWidth(nextWidth) {
|
|
6938
|
+
return getRangedWidthValue(nextWidth, mapBoxMaxPictureWidth);
|
|
6939
|
+
}
|
|
6940
|
+
|
|
6941
|
+
function StaticMap(_ref) {
|
|
6942
|
+
var _ref$width = _ref.width,
|
|
6943
|
+
width = _ref$width === void 0 ? 0 : _ref$width,
|
|
6944
|
+
height = _ref.height,
|
|
6945
|
+
alt = _ref.alt,
|
|
6946
|
+
apiToken = _ref.apiToken,
|
|
6947
|
+
mapId = _ref.mapId,
|
|
6948
|
+
marker = _ref.marker,
|
|
6949
|
+
center = _ref.center,
|
|
6950
|
+
onLoaded = _ref.onLoaded,
|
|
6951
|
+
onError = _ref.onError,
|
|
6952
|
+
props = _objectWithoutProperties(_ref, _excluded$3);
|
|
6953
|
+
|
|
6954
|
+
var _useState = useState(getPictureWidth(width)),
|
|
6955
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
6956
|
+
currentWidth = _useState2[0],
|
|
6957
|
+
setCurrentWidth = _useState2[1];
|
|
6958
|
+
|
|
6959
|
+
var _useState3 = useState(true),
|
|
6960
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
6961
|
+
isLoading = _useState4[0],
|
|
6962
|
+
setIsLoading = _useState4[1];
|
|
6963
|
+
|
|
6964
|
+
var _useState5 = useState(false),
|
|
6965
|
+
_useState6 = _slicedToArray(_useState5, 2),
|
|
6966
|
+
hasError = _useState6[0],
|
|
6967
|
+
setHasError = _useState6[1];
|
|
6968
|
+
|
|
6969
|
+
var _useState7 = useState(0),
|
|
6970
|
+
_useState8 = _slicedToArray(_useState7, 2),
|
|
6971
|
+
currentMapKey = _useState8[0],
|
|
6972
|
+
setCurrentMapKey = _useState8[1];
|
|
6973
|
+
|
|
6974
|
+
var shouldDisplay2xImage = getShouldDisplay2x();
|
|
6975
|
+
var mapUrl = useGetStaticMapImageUrl({
|
|
6976
|
+
forceApiToken: apiToken,
|
|
6977
|
+
forceMapId: mapId,
|
|
6978
|
+
mapWidth: currentWidth,
|
|
6979
|
+
mapHeight: height,
|
|
6980
|
+
center: center,
|
|
6981
|
+
is2x: shouldDisplay2xImage
|
|
6982
|
+
});
|
|
6983
|
+
return /*#__PURE__*/jsxs(View, _objectSpread(_objectSpread({
|
|
6984
|
+
position: "relative",
|
|
6985
|
+
maxWidth: mapBoxMaxPictureWidth,
|
|
6986
|
+
height: height,
|
|
6987
|
+
onLayout: function handleParentLayout(event) {
|
|
6988
|
+
var nativeEvent = event.nativeEvent;
|
|
6989
|
+
var rangedMapWidth = getPictureWidth(nativeEvent.layout.width);
|
|
6990
|
+
setCurrentWidth(rangedMapWidth);
|
|
6991
|
+
}
|
|
6992
|
+
}, props), {}, {
|
|
6993
|
+
"data-chromatic": process.env.KITT_MAP_CHROMATIC_IGNORE === 'true' ? 'ignore' : undefined,
|
|
6994
|
+
children: [currentWidth > 1 && mapUrl ? /*#__PURE__*/jsx(StaticMapImage, {
|
|
6995
|
+
url: mapUrl,
|
|
6996
|
+
width: currentWidth,
|
|
6997
|
+
height: height,
|
|
6998
|
+
alt: alt,
|
|
6999
|
+
onLoadEnd: function handleImageLoadEnd() {
|
|
7000
|
+
setIsLoading(false);
|
|
7001
|
+
if (onLoaded) onLoaded();
|
|
7002
|
+
},
|
|
7003
|
+
onError: function handleError() {
|
|
7004
|
+
setHasError(true);
|
|
7005
|
+
if (onError) onError();
|
|
7006
|
+
}
|
|
7007
|
+
}, "map-key-".concat(currentMapKey)) : null, marker && !isLoading && !hasError ? /*#__PURE__*/jsx(View, {
|
|
7008
|
+
position: "absolute",
|
|
7009
|
+
top: "0",
|
|
7010
|
+
left: "0",
|
|
7011
|
+
width: "100%",
|
|
7012
|
+
height: "100%",
|
|
7013
|
+
children: marker
|
|
7014
|
+
}) : null, isLoading ? /*#__PURE__*/jsx(View, {
|
|
7015
|
+
position: "absolute",
|
|
7016
|
+
top: "0",
|
|
7017
|
+
left: "0",
|
|
7018
|
+
width: "100%",
|
|
7019
|
+
height: "100%",
|
|
7020
|
+
children: /*#__PURE__*/jsx(StaticMapLoader, {})
|
|
7021
|
+
}) : null, hasError ? /*#__PURE__*/jsx(View, {
|
|
7022
|
+
position: "absolute",
|
|
7023
|
+
top: "0",
|
|
7024
|
+
left: "0",
|
|
7025
|
+
width: "100%",
|
|
7026
|
+
height: "100%",
|
|
7027
|
+
children: /*#__PURE__*/jsx(StaticMapError, {
|
|
7028
|
+
onReload: function handleReload() {
|
|
7029
|
+
setHasError(false);
|
|
7030
|
+
setIsLoading(true);
|
|
7031
|
+
setCurrentMapKey(function (prev) {
|
|
7032
|
+
return prev + 1;
|
|
7033
|
+
});
|
|
7034
|
+
}
|
|
7035
|
+
})
|
|
7036
|
+
}) : null]
|
|
7037
|
+
}));
|
|
7038
|
+
}
|
|
7039
|
+
StaticMap.Image = StaticMapImage;
|
|
7040
|
+
StaticMap.Loader = StaticMapLoader;
|
|
7041
|
+
StaticMap.Error = StaticMapError;
|
|
7042
|
+
StaticMap.Marker = StaticMapMarker;
|
|
7043
|
+
|
|
6483
7044
|
var Flex = /*#__PURE__*/styled.View.withConfig({
|
|
6484
7045
|
shouldForwardProp: function shouldForwardProp(prop, defaultValidatorFn) {
|
|
6485
7046
|
return !['direction', 'padding'].includes(prop) && defaultValidatorFn(prop);
|
|
@@ -7522,5 +8083,5 @@ function withTheme(WrappedComponent) {
|
|
|
7522
8083
|
});
|
|
7523
8084
|
}
|
|
7524
8085
|
|
|
7525
|
-
export { Actions, Avatar, BottomSheet, Button, CardModal, Center, Checkbox, ChoicesElements, DatePicker, DialogModal, Emoji, ExternalAppLink, ExternalLink, Flex, HStack, Highlight, Icon, IconButton, Image, InputEmail, InputFeedback, InputField, InputIcon, InputPassword, InputPhone, InputPressable, InputTag, InputText, KittBreakpointNameEnum, KittBreakpoints, KittBreakpointsMax, KittNativeBaseProvider, KittThemeDecorator, KittThemeProvider, Label, ListItem, LoaderIcon, MatchWindowSize, Message, Modal, ModalBehaviour, NavigationModal, Notification, Overlay, PageLoader, Picker, Pressable, Radio, RadioButtonGroup, ScrollView, DeprecatedSection as Section, Skeleton, SpinningIcon, Stack, Story, StoryBlock, StoryContainer, StoryDecorator, StoryGrid, StorySection, StoryTitle, StyleWebWrapper, Tag, TextArea, TimePicker, Tooltip, Typography, TypographyEmoji, TypographyIcon, TypographyLink, VStack, View, createChoicesComponent, createResponsiveStyleFromProp, createWindowSizeHelper, hex2rgba, matchWindowSize, theme, useBottomSheet, useCurrentBreakpointName, useKittTheme, useMatchWindowSize, useStaticBottomSheet, useStoryBlockColor, withTheme };
|
|
8086
|
+
export { Actions, Avatar, BottomSheet, Button, CardModal, Center, Checkbox, ChoicesElements, DatePicker, DialogModal, Emoji, ExternalAppLink, ExternalLink, FlatList, Flex, HStack, Highlight, Icon, IconButton, Image, InputEmail, InputFeedback, InputField, InputIcon, InputPassword, InputPhone, InputPressable, InputTag, InputText, KittBreakpointNameEnum, KittBreakpoints, KittBreakpointsMax, KittMapConfigProvider, KittNativeBaseProvider, KittThemeDecorator, KittThemeProvider, Label, ListItem, LoaderIcon, MapMarkerLarge, MapMarkerPosition, MapMarkerSimple, MatchWindowSize, Message, Modal, ModalBehaviour, NavigationModal, Notification, Overlay, PageLoader, Picker, Pressable, Radio, RadioButtonGroup, ScrollView, DeprecatedSection as Section, SectionList, Skeleton, SpinningIcon, Stack, StaticMap, Story, StoryBlock, StoryContainer, StoryDecorator, StoryGrid, StorySection, StoryTitle, StyleWebWrapper, Tag, TextArea, TimePicker, Tooltip, Typography, TypographyEmoji, TypographyIcon, TypographyLink, VStack, View, createChoicesComponent, createResponsiveStyleFromProp, createWindowSizeHelper, getStaticMapImageUrl, hex2rgba, matchWindowSize, theme, useBottomSheet, useCurrentBreakpointName, useGetStaticMapImageUrl, useKittMapConfig, useKittTheme, useMatchWindowSize, useStaticBottomSheet, useStoryBlockColor, withTheme };
|
|
7526
8087
|
//# sourceMappingURL=index-browser-all.es.android.js.map
|