@ornikar/kitt-universal 32.7.0 → 32.8.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/CHANGELOG.md +9 -0
- package/dist/definitions/ReadMore/ReadMore.d.ts +10 -0
- package/dist/definitions/ReadMore/ReadMore.d.ts.map +1 -0
- package/dist/definitions/index.d.ts +2 -0
- package/dist/definitions/index.d.ts.map +1 -1
- package/dist/index-metro.es.android.js +105 -65
- package/dist/index-metro.es.android.js.map +1 -1
- package/dist/index-metro.es.ios.js +105 -65
- package/dist/index-metro.es.ios.js.map +1 -1
- package/dist/index-node-22.17.cjs.js +94 -51
- package/dist/index-node-22.17.cjs.js.map +1 -1
- package/dist/index-node-22.17.cjs.web.js +101 -57
- package/dist/index-node-22.17.cjs.web.js.map +1 -1
- package/dist/index-node-22.17.es.mjs +95 -53
- package/dist/index-node-22.17.es.mjs.map +1 -1
- package/dist/index-node-22.17.es.web.mjs +101 -58
- package/dist/index-node-22.17.es.web.mjs.map +1 -1
- package/dist/index.es.js +107 -61
- package/dist/index.es.js.map +1 -1
- package/dist/index.es.web.js +114 -67
- package/dist/index.es.web.js.map +1 -1
- package/dist/tsbuildinfo +1 -1
- package/package.json +1 -1
- package/translations/fr-FR.json +3 -1
|
@@ -17,7 +17,7 @@ import * as WebBrowser from 'expo-web-browser';
|
|
|
17
17
|
import Downshift from 'downshift';
|
|
18
18
|
import Svg, { Path, Circle as Circle$1, Ellipse } from 'react-native-svg';
|
|
19
19
|
import DateTimePicker, { DateTimePickerAndroid } from '@react-native-community/datetimepicker';
|
|
20
|
-
import { FormattedMessage } from 'react-intl';
|
|
20
|
+
import { FormattedMessage, defineMessages } from 'react-intl';
|
|
21
21
|
import { getDocumentAsync } from 'expo-document-picker';
|
|
22
22
|
import { launchImageLibraryAsync } from 'expo-image-picker';
|
|
23
23
|
import { useDebouncedCallback } from 'use-debounce';
|
|
@@ -12503,6 +12503,101 @@ Picker.Option = PickerOption;
|
|
|
12503
12503
|
*/
|
|
12504
12504
|
Picker.UnsafeInternalItem = PickerItem;
|
|
12505
12505
|
|
|
12506
|
+
const _excluded$8 = ["children"];
|
|
12507
|
+
function TypographyLinkWebWrapper(_ref) {
|
|
12508
|
+
let {
|
|
12509
|
+
children
|
|
12510
|
+
} = _ref;
|
|
12511
|
+
_objectWithoutProperties(_ref, _excluded$8);
|
|
12512
|
+
return children;
|
|
12513
|
+
}
|
|
12514
|
+
|
|
12515
|
+
const _excluded$7 = ["children", "disabled", "noUnderline", "href", "hrefAttrs", "onPress"];
|
|
12516
|
+
const TypographyLink = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
12517
|
+
let {
|
|
12518
|
+
children,
|
|
12519
|
+
disabled,
|
|
12520
|
+
noUnderline,
|
|
12521
|
+
href,
|
|
12522
|
+
hrefAttrs,
|
|
12523
|
+
onPress
|
|
12524
|
+
} = _ref,
|
|
12525
|
+
otherProps = _objectWithoutProperties(_ref, _excluded$7);
|
|
12526
|
+
return /*#__PURE__*/jsx(TypographyLinkWebWrapper, {
|
|
12527
|
+
hasNoUnderline: noUnderline,
|
|
12528
|
+
children: /*#__PURE__*/jsx(Typography, _objectSpread(_objectSpread({
|
|
12529
|
+
ref: ref,
|
|
12530
|
+
underline: !noUnderline,
|
|
12531
|
+
color: disabled ? 'black-disabled' : undefined,
|
|
12532
|
+
href: href,
|
|
12533
|
+
hrefAttrs: hrefAttrs,
|
|
12534
|
+
accessibilityRole: "link",
|
|
12535
|
+
dataSet: {
|
|
12536
|
+
// remove data-kitt-universal when we delete kitt web. See :global(a) in Link styles.module.css
|
|
12537
|
+
'kitt-universal': 'true'
|
|
12538
|
+
},
|
|
12539
|
+
_web: {
|
|
12540
|
+
// @ts-expect-error: This is only used on web where 'not-allowed' and 'pointer' are valid cursor values
|
|
12541
|
+
cursor: disabled ? 'not-allowed' : 'pointer',
|
|
12542
|
+
transitionProperty: 'color',
|
|
12543
|
+
transitionDuration: '0.2s',
|
|
12544
|
+
transitionTimingFunction: 'ease-in-out'
|
|
12545
|
+
}
|
|
12546
|
+
// TODO[native-base@>=3.4.19] this currently does not work. Retest when updating native-base.
|
|
12547
|
+
// _active={{
|
|
12548
|
+
// underline: !!noUnderline,
|
|
12549
|
+
// }}
|
|
12550
|
+
// _hover={{
|
|
12551
|
+
// underline: !!noUnderline,
|
|
12552
|
+
// }}
|
|
12553
|
+
,
|
|
12554
|
+
onPress: disabled ? undefined : onPress
|
|
12555
|
+
}, otherProps), {}, {
|
|
12556
|
+
children: children
|
|
12557
|
+
}))
|
|
12558
|
+
});
|
|
12559
|
+
});
|
|
12560
|
+
|
|
12561
|
+
const messages = defineMessages({
|
|
12562
|
+
seeMore: {
|
|
12563
|
+
id: "shared.components.ReadMore.seeMore"
|
|
12564
|
+
},
|
|
12565
|
+
seeLess: {
|
|
12566
|
+
id: "shared.components.ReadMore.seeLess"
|
|
12567
|
+
}
|
|
12568
|
+
});
|
|
12569
|
+
function ReadMore({
|
|
12570
|
+
lines,
|
|
12571
|
+
children,
|
|
12572
|
+
textColor = 'bumper.content.base.hi',
|
|
12573
|
+
noUnderline = false
|
|
12574
|
+
}) {
|
|
12575
|
+
const [isExpanded, setIsExpanded] = useState(false);
|
|
12576
|
+
const nbOfLines = isExpanded ? undefined : lines;
|
|
12577
|
+
const messageProps = isExpanded ? messages.seeLess : messages.seeMore;
|
|
12578
|
+
return /*#__PURE__*/jsxs(Fragment, {
|
|
12579
|
+
children: [/*#__PURE__*/jsx(View, {
|
|
12580
|
+
flexShrink: 1,
|
|
12581
|
+
children: /*#__PURE__*/jsx(Typography.Text, {
|
|
12582
|
+
textAlign: "left",
|
|
12583
|
+
numberOfLines: nbOfLines,
|
|
12584
|
+
ellipsizeMode: "tail",
|
|
12585
|
+
children: children
|
|
12586
|
+
})
|
|
12587
|
+
}), lines ? /*#__PURE__*/jsx(View, {
|
|
12588
|
+
children: /*#__PURE__*/jsx(TypographyLink, {
|
|
12589
|
+
noUnderline: noUnderline,
|
|
12590
|
+
color: textColor,
|
|
12591
|
+
variant: "bold",
|
|
12592
|
+
onPress: () => {
|
|
12593
|
+
setIsExpanded(prev => !prev);
|
|
12594
|
+
},
|
|
12595
|
+
children: /*#__PURE__*/jsx(FormattedMessage, _objectSpread({}, messageProps))
|
|
12596
|
+
})
|
|
12597
|
+
}) : null]
|
|
12598
|
+
});
|
|
12599
|
+
}
|
|
12600
|
+
|
|
12506
12601
|
const SvgStripesinline = props => /*#__PURE__*/jsx(Svg, _objectSpread(_objectSpread({
|
|
12507
12602
|
viewBox: "0 0 453 71",
|
|
12508
12603
|
fill: "none",
|
|
@@ -12600,7 +12695,7 @@ function SkeletonContent({
|
|
|
12600
12695
|
});
|
|
12601
12696
|
}
|
|
12602
12697
|
|
|
12603
|
-
const _excluded$
|
|
12698
|
+
const _excluded$6 = ["isLoading", "style"],
|
|
12604
12699
|
_excluded2$1 = ["size"],
|
|
12605
12700
|
_excluded3$1 = ["size"],
|
|
12606
12701
|
_excluded4$1 = ["size"];
|
|
@@ -12609,7 +12704,7 @@ function Skeleton(_ref) {
|
|
|
12609
12704
|
isLoading = false,
|
|
12610
12705
|
style
|
|
12611
12706
|
} = _ref,
|
|
12612
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
12707
|
+
props = _objectWithoutProperties(_ref, _excluded$6);
|
|
12613
12708
|
const [width, setWidth] = useState(0);
|
|
12614
12709
|
return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread({}, props), {}, {
|
|
12615
12710
|
overflow: "hidden",
|
|
@@ -12791,7 +12886,7 @@ function getShouldDisplay2x() {
|
|
|
12791
12886
|
return currentDevicePixelRatio > 1;
|
|
12792
12887
|
}
|
|
12793
12888
|
|
|
12794
|
-
const _excluded$
|
|
12889
|
+
const _excluded$5 = ["width", "height", "alt", "apiToken", "mapId", "marker", "center", "onLoaded", "onError"];
|
|
12795
12890
|
const mapBoxMaxPictureWidth = 1280;
|
|
12796
12891
|
|
|
12797
12892
|
// Mapbox requestable width for image is between 1 - 1280px
|
|
@@ -12810,7 +12905,7 @@ function StaticMap(_ref) {
|
|
|
12810
12905
|
onLoaded,
|
|
12811
12906
|
onError
|
|
12812
12907
|
} = _ref,
|
|
12813
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
12908
|
+
props = _objectWithoutProperties(_ref, _excluded$5);
|
|
12814
12909
|
const [currentWidth, setCurrentWidth] = useState(getPictureWidth(width));
|
|
12815
12910
|
const [isLoading, setIsLoading] = useState(true);
|
|
12816
12911
|
const [hasError, setHasError] = useState(false);
|
|
@@ -12980,13 +13075,13 @@ function Sticker({
|
|
|
12980
13075
|
});
|
|
12981
13076
|
}
|
|
12982
13077
|
|
|
12983
|
-
const _excluded$
|
|
13078
|
+
const _excluded$4 = ["direction", "wrap"];
|
|
12984
13079
|
function Flex(_ref) {
|
|
12985
13080
|
let {
|
|
12986
13081
|
direction,
|
|
12987
13082
|
wrap = 'wrap'
|
|
12988
13083
|
} = _ref,
|
|
12989
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
13084
|
+
props = _objectWithoutProperties(_ref, _excluded$4);
|
|
12990
13085
|
return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread({}, props), {}, {
|
|
12991
13086
|
flexDirection: direction,
|
|
12992
13087
|
flexWrap: wrap
|
|
@@ -13128,7 +13223,7 @@ function Story({
|
|
|
13128
13223
|
});
|
|
13129
13224
|
}
|
|
13130
13225
|
|
|
13131
|
-
const _excluded$
|
|
13226
|
+
const _excluded$3 = ["title", "children", "internalIsDemoSection"],
|
|
13132
13227
|
_excluded2 = ["title", "children"],
|
|
13133
13228
|
_excluded3 = ["title", "children"],
|
|
13134
13229
|
_excluded4 = ["children"];
|
|
@@ -13138,7 +13233,7 @@ function StorySection(_ref) {
|
|
|
13138
13233
|
children,
|
|
13139
13234
|
internalIsDemoSection
|
|
13140
13235
|
} = _ref,
|
|
13141
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
13236
|
+
props = _objectWithoutProperties(_ref, _excluded$3);
|
|
13142
13237
|
if (title === 'Demo' && !internalIsDemoSection) throw new Error('Use StorySection.Demo instead');
|
|
13143
13238
|
return /*#__PURE__*/jsxs(View, _objectSpread(_objectSpread({
|
|
13144
13239
|
marginBottom: "kitt.8"
|
|
@@ -14168,61 +14263,6 @@ function TypographyEmoji({
|
|
|
14168
14263
|
});
|
|
14169
14264
|
}
|
|
14170
14265
|
|
|
14171
|
-
const _excluded$4 = ["children"];
|
|
14172
|
-
function TypographyLinkWebWrapper(_ref) {
|
|
14173
|
-
let {
|
|
14174
|
-
children
|
|
14175
|
-
} = _ref;
|
|
14176
|
-
_objectWithoutProperties(_ref, _excluded$4);
|
|
14177
|
-
return children;
|
|
14178
|
-
}
|
|
14179
|
-
|
|
14180
|
-
const _excluded$3 = ["children", "disabled", "noUnderline", "href", "hrefAttrs", "onPress"];
|
|
14181
|
-
const TypographyLink = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
14182
|
-
let {
|
|
14183
|
-
children,
|
|
14184
|
-
disabled,
|
|
14185
|
-
noUnderline,
|
|
14186
|
-
href,
|
|
14187
|
-
hrefAttrs,
|
|
14188
|
-
onPress
|
|
14189
|
-
} = _ref,
|
|
14190
|
-
otherProps = _objectWithoutProperties(_ref, _excluded$3);
|
|
14191
|
-
return /*#__PURE__*/jsx(TypographyLinkWebWrapper, {
|
|
14192
|
-
hasNoUnderline: noUnderline,
|
|
14193
|
-
children: /*#__PURE__*/jsx(Typography, _objectSpread(_objectSpread({
|
|
14194
|
-
ref: ref,
|
|
14195
|
-
underline: !noUnderline,
|
|
14196
|
-
color: disabled ? 'black-disabled' : undefined,
|
|
14197
|
-
href: href,
|
|
14198
|
-
hrefAttrs: hrefAttrs,
|
|
14199
|
-
accessibilityRole: "link",
|
|
14200
|
-
dataSet: {
|
|
14201
|
-
// remove data-kitt-universal when we delete kitt web. See :global(a) in Link styles.module.css
|
|
14202
|
-
'kitt-universal': 'true'
|
|
14203
|
-
},
|
|
14204
|
-
_web: {
|
|
14205
|
-
// @ts-expect-error: This is only used on web where 'not-allowed' and 'pointer' are valid cursor values
|
|
14206
|
-
cursor: disabled ? 'not-allowed' : 'pointer',
|
|
14207
|
-
transitionProperty: 'color',
|
|
14208
|
-
transitionDuration: '0.2s',
|
|
14209
|
-
transitionTimingFunction: 'ease-in-out'
|
|
14210
|
-
}
|
|
14211
|
-
// TODO[native-base@>=3.4.19] this currently does not work. Retest when updating native-base.
|
|
14212
|
-
// _active={{
|
|
14213
|
-
// underline: !!noUnderline,
|
|
14214
|
-
// }}
|
|
14215
|
-
// _hover={{
|
|
14216
|
-
// underline: !!noUnderline,
|
|
14217
|
-
// }}
|
|
14218
|
-
,
|
|
14219
|
-
onPress: disabled ? undefined : onPress
|
|
14220
|
-
}, otherProps), {}, {
|
|
14221
|
-
children: children
|
|
14222
|
-
}))
|
|
14223
|
-
});
|
|
14224
|
-
});
|
|
14225
|
-
|
|
14226
14266
|
const ChromaticReducedMotionDecorator = makeDecorator({
|
|
14227
14267
|
name: 'ChromaticReducedMotionDecorator',
|
|
14228
14268
|
parameterName: 'chromaticReducedMotion',
|
|
@@ -14595,5 +14635,5 @@ function VerticalSteps(_ref) {
|
|
|
14595
14635
|
VerticalSteps.Step = Step;
|
|
14596
14636
|
VerticalSteps.BorderlessStep = BorderlessStep;
|
|
14597
14637
|
|
|
14598
|
-
export { ActionCard, Actions, Autocomplete, Avatar, BottomSheet, Button, ButtonBadge, CardModal, Center, Checkbox, ChoicesElements, ChromaticReducedMotionDecorator, CloseIconButton, DatePicker, DialogModal, DocumentPicker, Emoji, ExternalAppLink, ExternalLink, FilePicker, FlatList, Flex, FullscreenModal, GoogleMapsApiKeyProvider, GoogleMapsAutocompleteProvider, GroupTags, HStack, Highlight, Icon, IconButton, Image, ImagePicker, InfoCard, InputAddress, InputAddressLegacy, InputEmail, InputFeedback, InputField, InputIban, InputIcon, InputNumber, InputPassword, InputPhone, InputPressable, InputTag, InputText, KittBreakpointNameEnum, KittBreakpoints, KittBreakpointsMax, KittMapConfigProvider, KittNativeBaseProvider, KittThemeDecorator, KittThemeProvider, Label, ListItem, LoaderIcon, MapMarker, MapMarkerVariantEnum, MatchWindowSize, Message, ModalBehaviour, FlatList as NativeOnlyFlatList, NavigationBottomSheet, NavigationModal, Notification, Overlay, PageLoader, Picker, Pressable, RadioWithRef as Radio, RadioButtonGroup, ScrollView, DeprecatedSection as Section, SectionList, SegmentedProgressBar, Skeleton, SpinningIcon, Stack, StaticMap, Sticker, Story, StoryBlock, StoryContainer, StoryDecorator, StoryGrid, StorySection, StoryTitle, StyleWebWrapper, SwitchBreakpoints, TabBar, Tag, TextArea, TimePicker, ToastComponent, Toggle, Tooltip, TopNavBar, Typography, TypographyEmoji, TypographyIcon, TypographyLink, VStack, VerticalSteps, View, createChoicesComponent, createResponsiveStyleFromProp, getStaticMapImageUrl, getValueForBreakpoint, hex2rgba, matchWindowSize, storyPadding, theme, useBottomSheet, useBreakpointValue, useCurrentBreakpointName, useGetStaticMapImageUrl, useKittMapConfig, useKittTheme, useMatchWindowSize, useOpenExternalLink, useStaticBottomSheet, useStoryBlockColor, useTheme };
|
|
14638
|
+
export { ActionCard, Actions, Autocomplete, Avatar, BottomSheet, Button, ButtonBadge, CardModal, Center, Checkbox, ChoicesElements, ChromaticReducedMotionDecorator, CloseIconButton, DatePicker, DialogModal, DocumentPicker, Emoji, ExternalAppLink, ExternalLink, FilePicker, FlatList, Flex, FullscreenModal, GoogleMapsApiKeyProvider, GoogleMapsAutocompleteProvider, GroupTags, HStack, Highlight, Icon, IconButton, Image, ImagePicker, InfoCard, InputAddress, InputAddressLegacy, InputEmail, InputFeedback, InputField, InputIban, InputIcon, InputNumber, InputPassword, InputPhone, InputPressable, InputTag, InputText, KittBreakpointNameEnum, KittBreakpoints, KittBreakpointsMax, KittMapConfigProvider, KittNativeBaseProvider, KittThemeDecorator, KittThemeProvider, Label, ListItem, LoaderIcon, MapMarker, MapMarkerVariantEnum, MatchWindowSize, Message, ModalBehaviour, FlatList as NativeOnlyFlatList, NavigationBottomSheet, NavigationModal, Notification, Overlay, PageLoader, Picker, Pressable, RadioWithRef as Radio, RadioButtonGroup, ReadMore, ScrollView, DeprecatedSection as Section, SectionList, SegmentedProgressBar, Skeleton, SpinningIcon, Stack, StaticMap, Sticker, Story, StoryBlock, StoryContainer, StoryDecorator, StoryGrid, StorySection, StoryTitle, StyleWebWrapper, SwitchBreakpoints, TabBar, Tag, TextArea, TimePicker, ToastComponent, Toggle, Tooltip, TopNavBar, Typography, TypographyEmoji, TypographyIcon, TypographyLink, VStack, VerticalSteps, View, createChoicesComponent, createResponsiveStyleFromProp, getStaticMapImageUrl, getValueForBreakpoint, hex2rgba, matchWindowSize, storyPadding, theme, useBottomSheet, useBreakpointValue, useCurrentBreakpointName, useGetStaticMapImageUrl, useKittMapConfig, useKittTheme, useMatchWindowSize, useOpenExternalLink, useStaticBottomSheet, useStoryBlockColor, useTheme };
|
|
14599
14639
|
//# sourceMappingURL=index-metro.es.ios.js.map
|