@ornikar/kitt-universal 7.2.0 → 7.3.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/dist/definitions/Button/BaseStyledButtonPressable.d.ts +1 -0
- package/dist/definitions/Button/BaseStyledButtonPressable.d.ts.map +1 -1
- package/dist/definitions/Button/Button.d.ts +1 -0
- package/dist/definitions/Button/Button.d.ts.map +1 -1
- package/dist/definitions/Button/ButtonContent.d.ts.map +1 -1
- package/dist/definitions/PageLoader/AnimatedBackgroundCircle.d.ts +3 -0
- package/dist/definitions/PageLoader/AnimatedBackgroundCircle.d.ts.map +1 -0
- package/dist/definitions/PageLoader/AnimatedFillCircle.d.ts +3 -0
- package/dist/definitions/PageLoader/AnimatedFillCircle.d.ts.map +1 -0
- package/dist/definitions/PageLoader/AnimatedFillCircleContainer.d.ts +8 -0
- package/dist/definitions/PageLoader/AnimatedFillCircleContainer.d.ts.map +1 -0
- package/dist/definitions/PageLoader/AnimatedLoaderCircle.d.ts +10 -0
- package/dist/definitions/PageLoader/AnimatedLoaderCircle.d.ts.map +1 -0
- package/dist/definitions/PageLoader/PageLoader.d.ts.map +1 -1
- package/dist/definitions/PageLoader/PageLoader.web.d.ts.map +1 -1
- package/dist/definitions/forms/DatePicker/DatePickerInputPart.d.ts.map +1 -1
- package/dist/definitions/forms/InputText/InputText.d.ts.map +1 -1
- package/dist/definitions/themes/late-ocean/button.d.ts +2 -1
- package/dist/definitions/themes/late-ocean/button.d.ts.map +1 -1
- package/dist/definitions/themes/late-ocean/input.d.ts +2 -2
- package/dist/definitions/themes/late-ocean/input.d.ts.map +1 -1
- package/dist/definitions/themes/late-ocean/pageLoader.d.ts +13 -0
- package/dist/definitions/themes/late-ocean/pageLoader.d.ts.map +1 -1
- package/dist/index-browser-all.es.android.js +218 -29
- package/dist/index-browser-all.es.android.js.map +1 -1
- package/dist/index-browser-all.es.ios.js +218 -29
- package/dist/index-browser-all.es.ios.js.map +1 -1
- package/dist/index-browser-all.es.js +218 -29
- package/dist/index-browser-all.es.js.map +1 -1
- package/dist/index-browser-all.es.web.js +113 -35
- package/dist/index-browser-all.es.web.js.map +1 -1
- package/dist/index-node-14.17.cjs.js +213 -24
- package/dist/index-node-14.17.cjs.js.map +1 -1
- package/dist/index-node-14.17.cjs.web.css +1 -1
- package/dist/index-node-14.17.cjs.web.js +102 -29
- package/dist/index-node-14.17.cjs.web.js.map +1 -1
- package/dist/linaria-themes-browser-all.es.android.js +26 -3
- package/dist/linaria-themes-browser-all.es.android.js.map +1 -1
- package/dist/linaria-themes-browser-all.es.ios.js +26 -3
- package/dist/linaria-themes-browser-all.es.ios.js.map +1 -1
- package/dist/linaria-themes-browser-all.es.js +26 -3
- package/dist/linaria-themes-browser-all.es.js.map +1 -1
- package/dist/linaria-themes-browser-all.es.web.js +26 -3
- package/dist/linaria-themes-browser-all.es.web.js.map +1 -1
- package/dist/linaria-themes-node-14.17.cjs.js +26 -3
- package/dist/linaria-themes-node-14.17.cjs.js.map +1 -1
- package/dist/linaria-themes-node-14.17.cjs.web.js +26 -3
- package/dist/linaria-themes-node-14.17.cjs.web.js.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/tsbuildinfo +1 -1
- package/package.json +9 -4
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index-node-14.17.cjs.js","sources":["../src/Icon/Icon.tsx","../src/KittBreakpoints.ts","../src/typography/Typography.tsx","../src/Avatar/Avatar.tsx","../src/Button/getVariantValuesIfExist.ts","../src/Button/AnimatedButtonPressable.tsx","../src/Button/BaseStyledButtonPressable.tsx","../src/typography/TypographyIcon.tsx","../src/Button/isSubtle.ts","../src/Button/ButtonContent.tsx","../src/Button/StyledDisabled.tsx","../src/Button/Button.tsx","../src/Card/Card.tsx","../src/Emoji/Emoji.tsx","../src/ExternalLink/ExternalLinkOpenLinkBehavior.ts","../src/ExternalLink/ExternalLink.tsx","../src/themes/palettes/lateOceanColorPalette.ts","../src/themes/late-ocean/colors.ts","../src/themes/late-ocean/avatar.ts","../src/themes/late-ocean/button.ts","../src/themes/late-ocean/card.ts","../src/themes/late-ocean/feedback.ts","../src/themes/late-ocean/checkbox.ts","../src/themes/late-ocean/datePicker.ts","../src/themes/late-ocean/typography.ts","../src/themes/late-ocean/input.ts","../src/themes/late-ocean/inputField.ts","../src/themes/late-ocean/inputTag.ts","../src/themes/late-ocean/radio.ts","../src/themes/late-ocean/textArea.ts","../src/themes/late-ocean/forms.ts","../src/themes/late-ocean/fullScreenModal.ts","../src/themes/late-ocean/iconButton.ts","../src/themes/late-ocean/listItem.ts","../src/themes/late-ocean/pageLoader.ts","../src/themes/late-ocean/shadows.ts","../src/themes/late-ocean/skeleton.ts","../src/themes/late-ocean/tag.ts","../src/themes/late-ocean/tooltip.ts","../src/themes/default.ts","../src/utils/windowSize/useMatchWindowSize.ts","../src/utils/windowSize/createWindowSizeHelper.ts","../src/useKittTheme.tsx","../src/forms/Checkbox/Checkbox.tsx","../src/forms/utils.ts","../src/forms/styledTextInputMixin.ts","../src/forms/DatePicker/DatePickerInputPart.tsx","../src/forms/DatePicker/DatePickerInputs.tsx","../src/forms/DatePicker/DatePickerAndroid.tsx","../src/Overlay/Overlay.tsx","../src/Modal/Body.tsx","../src/Modal/Footer.tsx","../src/utils/StyleWebWrapper.tsx","../src/utils/withTheme.tsx","../src/IconButton/PressableIconButton.tsx","../src/IconButton/PressableAnimatedContainer.tsx","../src/IconButton/IconButton.tsx","../src/Modal/OnCloseContext.ts","../src/Modal/Header.tsx","../src/Modal/Modal.tsx","../src/forms/DatePicker/PlatformDateTimePicker.tsx","../src/forms/DatePicker/ModalPlatformDateTimePicker.tsx","../src/forms/DatePicker/DatePicker.tsx","../src/forms/InputText/InputTextContainer.tsx","../src/forms/InputText/InputText.tsx","../src/forms/InputEmail/InputEmail.tsx","../src/forms/InputFeedback/InputFeedback.tsx","../src/forms/InputField/InputField.tsx","../src/forms/InputIcon/InputIcon.tsx","../src/forms/InputPressable/InputPressable.tsx","../src/forms/InputPassword/InputPassword.tsx","../src/forms/InputPhone/InputPhone.tsx","../src/forms/InputTag/InputTag.tsx","../src/forms/Label/Label.tsx","../src/forms/Radio/Radio.tsx","../src/forms/TextArea/TextArea.tsx","../src/FullScreenModal/Body.tsx","../src/FullScreenModal/Header.tsx","../src/FullScreenModal/FullScreenModal.tsx","../src/Icon/SpinningIcon.tsx","../src/ListItem/ListItemContent.tsx","../src/ListItem/ListItemSideContent.tsx","../src/ListItem/ListItem.tsx","../src/LoaderIcon/LoaderIcon.tsx","../src/BaseMessage/IconContent.tsx","../src/BaseMessage/helper.ts","../src/BaseMessage/BaseMessage.tsx","../src/Message/Message.tsx","../src/Notification/Notification.tsx","../src/PageLoader/PageLoader.tsx","../src/Skeleton/SkeletonContent.tsx","../src/Skeleton/Skeleton.tsx","../src/story-components/Flex.tsx","../src/story-components/theme.ts","../src/story-components/StoryBlock.tsx","../src/story-components/StoryTitle.tsx","../src/story-components/Story.tsx","../src/story-components/StorySection.tsx","../src/story-components/StoryContainer.tsx","../src/story-components/StoryDecorator.tsx","../src/story-components/StoryGrid.tsx","../src/Tag/Tag.tsx","../src/TimePicker/ModalDateTimePicker.tsx","../src/TimePicker/useTimePicker.ts","../src/TimePicker/TimePicker.tsx","../src/Tooltip/TooltipView.tsx","../src/Tooltip/tooltipUtils.ts","../src/Tooltip/Tooltip.tsx","../src/typography/TypographyEmoji.tsx","../src/typography/TypographyLink.tsx","../src/utils/hexToRgba.ts","../src/utils/storybook/KittThemeDecorator.tsx","../src/utils/windowSize/MatchWindowSize.tsx"],"sourcesContent":["import type { ReactElement } from 'react';\nimport { cloneElement } from 'react';\nimport type { ViewStyle } from 'react-native';\nimport styled from 'styled-components/native';\n\nexport interface IconProps {\n icon: ReactElement;\n size?: number;\n color: string;\n align?: ViewStyle['alignSelf'];\n testID?: ViewStyle['testID'];\n}\n\ninterface IconContainerProps {\n $align?: ViewStyle['alignSelf'];\n $size: number;\n $color: string;\n}\n\nexport const defaultIconSize = 20;\n\nexport const IconContainer = styled.View<IconContainerProps>`\n color: ${({ $color }) => $color};\n width: ${({ $size }) => $size}px;\n height: ${({ $size }) => $size}px;\n align-self: ${({ $align = 'auto' }) => $align};\n`;\n\nexport function Icon({ icon, size = defaultIconSize, align, color }: IconProps): ReactElement {\n const clonedIcon = cloneElement(icon, { color });\n\n return (\n <IconContainer $align={align} $size={size} $color={color}>\n {clonedIcon}\n </IconContainer>\n );\n}\n","export const KittBreakpoints = {\n /**\n * min-width: 0\n */\n BASE: 0,\n /**\n * min-width: 480px\n */\n SMALL: 480,\n /**\n * min-width: 768px\n */\n MEDIUM: 768,\n /**\n * min-width: 1024px\n */\n LARGE: 1024,\n /**\n * min-width: 1280px\n */\n WIDE: 1280,\n};\n\nexport const KittBreakpointsMax = {\n /**\n * max-width: 479px\n */\n BASE: KittBreakpoints.SMALL - 1,\n /**\n * max-width: 767px\n */\n SMALL: KittBreakpoints.MEDIUM - 1,\n /**\n * max-width: 1023px\n */\n MEDIUM: KittBreakpoints.LARGE - 1,\n /**\n * max-width: 1279px\n */\n LARGE: KittBreakpoints.WIDE - 1,\n};\n\nexport type KittBreakpoint = typeof KittBreakpoints[keyof typeof KittBreakpoints];\nexport type KittBreakpointMax = typeof KittBreakpointsMax[keyof typeof KittBreakpointsMax];\n","import type { FC, ReactElement, ReactNode } from 'react';\nimport { createContext, useContext } from 'react';\nimport type { TextProps } from 'react-native';\nimport { Platform, useWindowDimensions } from 'react-native';\nimport type { DefaultTheme } from 'styled-components/native';\nimport styled, { css } from 'styled-components/native';\nimport type { Except, SetOptional } from 'type-fest';\nimport { KittBreakpoints } from '../KittBreakpoints';\nimport type { TypographyTypeConfig } from '../themes/late-ocean/typography';\nimport type { KittTheme } from '../useKittTheme';\n\nexport type TypographyHeaderType = `header${'1' | '2' | '3' | '4' | '5'}`;\nexport type TypographyBodyType = 'body' | `body-${'large' | 'medium' | 'small' | 'xsmall'}`;\nexport type TypographyType = TypographyHeaderType | TypographyBodyType;\ntype TypographyVariant = 'regular' | 'bold';\nexport type TypographyColor =\n | 'black'\n | 'black-anthracite'\n | 'black-light'\n | 'white'\n | 'white-light'\n | 'primary'\n | 'primary-light'\n | 'accent'\n | 'success'\n | 'danger';\n\nconst IsHeaderTypographyContext = createContext<boolean | undefined>(undefined);\nconst TypographyColorContext = createContext<TypographyColor>('black');\n\nexport function useTypographyColor(): TypographyColor {\n return useContext(TypographyColorContext);\n}\n\nexport const getTypographyTypeConfigKey = (theme: KittTheme): keyof TypographyTypeConfig => {\n const isMediumOrAbove = theme.responsive.matchWindowSize({ minWidth: KittBreakpoints.MEDIUM });\n return isMediumOrAbove ? 'mediumAndWide' : 'baseAndSmall';\n};\n\nconst isTypeHeader = (type: TypographyType): type is TypographyHeaderType => type.startsWith('header');\nexport const isTypographyHeader = (\n type: TypographyType | undefined,\n typographyIsHeaderInContext: boolean | undefined,\n): type is TypographyHeaderType => {\n if (type) return isTypeHeader(type);\n if (typographyIsHeaderInContext != null) return typographyIsHeaderInContext;\n throw new Error('You must set a \"base\" prop or wrap this Typography in one that does.');\n};\n\nexport function getTypographyTypeConfig(type: TypographyType, theme: DefaultTheme): TypographyTypeConfig {\n if (isTypographyHeader(type, undefined)) {\n return theme.kitt.typography.types.headers.configs[type];\n }\n\n return theme.kitt.typography.types.bodies.configs[type];\n}\n\ninterface StyledTypographyProps {\n accessibilityRole: TextProps['accessibilityRole'] | 'paragraph';\n $isHeader: boolean;\n $typeForCurrentWindowSize?: TypographyType;\n $variant: TypographyVariant;\n $color?: TypographyColor;\n}\n\nconst StyledTypography = styled.Text<StyledTypographyProps>`\n /* font */\n ${({ theme, $isHeader, $typeForCurrentWindowSize, $variant }) => {\n const { headers, bodies } = theme.kitt.typography.types;\n const typeConfigKey = getTypographyTypeConfigKey(theme);\n\n return `\n /* type */\n ${\n !$typeForCurrentWindowSize\n ? ''\n : `\n font-family: ${$isHeader ? headers.fontFamily[$variant] : bodies.fontFamily[$variant]};\n font-size: ${\n $isHeader\n ? headers.configs[$typeForCurrentWindowSize as TypographyHeaderType][typeConfigKey].fontSize\n : bodies.configs[$typeForCurrentWindowSize as TypographyBodyType][typeConfigKey].fontSize\n }px;\n line-height: ${\n $isHeader\n ? headers.configs[$typeForCurrentWindowSize as TypographyHeaderType][typeConfigKey].lineHeight\n : bodies.configs[$typeForCurrentWindowSize as TypographyBodyType][typeConfigKey].lineHeight\n }px;\n `\n }\n\n /* variant */\n font-weight: ${$isHeader ? headers.fontWeight : bodies.fontWeight[$variant]};\n font-style: ${$isHeader ? headers.fontStyle : bodies.fontStyle[$variant]};\n `;\n }}\n\n /* color */\n ${({ theme, $color }) => {\n if (!$color) return '';\n\n return css`\n color: ${theme.kitt.typography.colors[$color]};\n text-decoration-color: ${theme.kitt.typography.colors[$color]};\n `;\n }}\n`;\n\nexport interface TypographyBreakpointTypesProps {\n /** base type. Inherited from parent Typography if not specified */\n base?: TypographyType;\n /** small type. use base if undefined */\n small?: TypographyType;\n /** medium type. use small or base if undefined */\n medium?: TypographyType;\n /** large type. use medium or small or base if undefined */\n large?: TypographyType;\n}\n\nexport interface TypographyProps extends TypographyBreakpointTypesProps, Except<TextProps, 'accessibilityRole'> {\n // Find mapping for web here: https://www.w3.org/TR/html-aria/\n accessibilityRole: NonNullable<TextProps['accessibilityRole']> | 'paragraph' | null;\n /** Default to regular for bodies and bold of headers. Is not inherited. */\n variant?: TypographyVariant;\n /** Inherited from parent Typography if not specified, or black if no Typography parent found. */\n color?: TypographyColor;\n children: ReactNode;\n}\nexport type TypographyPropsWithoutRole = Except<TypographyProps, 'accessibilityRole'>;\n\nexport function useTypographyTypeForCurrentWindowSize(\n base: TypographyType | undefined,\n small: TypographyType | undefined,\n medium: TypographyType | undefined,\n large: TypographyType | undefined,\n): TypographyType | undefined {\n const { width } = useWindowDimensions();\n if (large && width >= KittBreakpoints.LARGE) return large;\n if (medium && width >= KittBreakpoints.MEDIUM) return medium;\n if (small && width >= KittBreakpoints.SMALL) return small;\n return base;\n}\n\ntype GetTypographyInheritedOrDefaultValuesBasedOnExistingAncestorsProps = Pick<TypographyProps, 'base' | 'color'>;\n\nexport function getTypographyInheritedOrDefaultValuesBasedOnExistingAncestors(\n hasTypographyAncestor: boolean,\n { base, color }: GetTypographyInheritedOrDefaultValuesBasedOnExistingAncestorsProps,\n): GetTypographyInheritedOrDefaultValuesBasedOnExistingAncestorsProps {\n // return the props set or undefined. In case of undefined, the value will be inherited from its parents.\n if (hasTypographyAncestor) return { base, color };\n\n return {\n base: base ?? 'body',\n color: color ?? 'black',\n };\n}\n\nexport function Typography({\n accessibilityRole,\n base,\n small,\n medium,\n large,\n variant,\n color,\n ...otherProps\n}: TypographyProps): ReactElement | null {\n const isHeaderTypographyInContext = useContext(IsHeaderTypographyContext);\n const hasTypographyAncestor = isHeaderTypographyInContext !== undefined;\n const { base: baseOrDefaultToBody, color: colorOrDefaultToBlack } =\n getTypographyInheritedOrDefaultValuesBasedOnExistingAncestors(hasTypographyAncestor, {\n base,\n color,\n });\n const typeForCurrentWindowSize = useTypographyTypeForCurrentWindowSize(baseOrDefaultToBody, small, medium, large);\n const isHeader = isTypographyHeader(typeForCurrentWindowSize, isHeaderTypographyInContext);\n const nonNullableVariant: TypographyVariant = variant ?? (isHeader ? 'bold' : 'regular');\n\n const content = baseOrDefaultToBody ? (\n <IsHeaderTypographyContext.Provider value={isHeader}>\n <StyledTypography\n $color={colorOrDefaultToBlack}\n $isHeader={isHeader}\n $typeForCurrentWindowSize={typeForCurrentWindowSize}\n $variant={nonNullableVariant}\n accessibilityRole={(accessibilityRole as TextProps['accessibilityRole']) || undefined}\n {...otherProps}\n />\n </IsHeaderTypographyContext.Provider>\n ) : (\n <StyledTypography\n $color={colorOrDefaultToBlack}\n $isHeader={isHeader}\n $variant={nonNullableVariant}\n accessibilityRole={(accessibilityRole as TextProps['accessibilityRole']) || undefined}\n {...otherProps}\n />\n );\n\n return color ? <TypographyColorContext.Provider value={color}>{content}</TypographyColorContext.Provider> : content;\n}\n\nexport type TypographyTextProps = SetOptional<TypographyProps, 'accessibilityRole'>;\nfunction TypographyText(props: TypographyTextProps): ReactElement {\n return <Typography accessibilityRole={null} {...props} />;\n}\n\nfunction TypographyParagraph(props: TypographyTextProps): ReactElement {\n // role 'paragraph' does not exist in native, it's a web feature only.\n return <Typography accessibilityRole={Platform.OS === 'web' ? 'paragraph' : null} {...props} />;\n}\n\nexport type TypographyHeadingProps = TypographyPropsWithoutRole;\n\nconst createHeading = (\n level: number,\n /** @deprecated accessibility and design should be independent */\n defaultBase?: TypographyHeadingProps['base'],\n): FC<TypographyHeadingProps> => {\n // https://github.com/necolas/react-native-web/issues/401\n function TypographyHeading(props: TypographyHeadingProps): ReactElement {\n return <Typography accessibilityRole=\"header\" base={defaultBase} {...props} accessibilityLevel={level} />;\n }\n TypographyHeading.displayName = `TypographyHeading${level}`;\n return TypographyHeading;\n};\n\nTypography.Text = TypographyText;\nTypography.Paragraph = TypographyParagraph;\nTypography.Header1 = createHeading(1);\nTypography.Header2 = createHeading(2);\nTypography.Header3 = createHeading(3);\nTypography.Header4 = createHeading(4);\nTypography.Header5 = createHeading(5);\nTypography.Header6 = createHeading(6);\n\n/** @deprecated use Typography.Header1 */\nTypography.h1 = createHeading(1, 'header1');\n/** @deprecated use Typography.Header2 */\nTypography.h2 = createHeading(2, 'header2');\n/** @deprecated use Typography.Header3 */\nTypography.h3 = createHeading(3, 'header3');\n/** @deprecated use Typography.Header4 */\nTypography.h4 = createHeading(4, 'header4');\n/** @deprecated use Typography.Header6 */\nTypography.h5 = createHeading(5, 'header5');\n","import { UserIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement } from 'react';\nimport { Image } from 'react-native';\nimport styled from 'styled-components/native';\nimport { Icon } from '../Icon/Icon';\nimport { Typography } from '../typography/Typography';\n\nconst getInitials = (firstname: string, lastname: string): string => `${firstname[0]}${lastname[0]}`.toUpperCase();\n\nexport type AvatarSizeVariant = 'large';\n\nexport interface StyledAvatarViewProps {\n $size: number;\n $isRound?: boolean;\n $isLight?: boolean;\n $sizeVariant?: AvatarSizeVariant;\n}\n\nconst StyledAvatarView = styled.View<StyledAvatarViewProps>`\n border-radius: ${({ theme, $isRound, $size, $sizeVariant }) => {\n if ($isRound) return `${$size / 2}px`;\n\n return `${$sizeVariant === 'large' ? theme.kitt.avatar.large.borderRadius : theme.kitt.avatar.borderRadius}px`;\n }};\n background-color: ${({ theme, $isLight }) =>\n $isLight ? theme.kitt.avatar.light.backgroundColor : theme.kitt.avatar.default.backgroundColor};\n height: ${({ $size }) => $size}px;\n width: ${({ $size }) => $size}px;\n overflow: hidden;\n align-items: center;\n justify-content: center;\n`;\n\ninterface AvatarContentProps extends Exclude<AvatarProps, 'light | round'> {\n size: NonNullable<number>;\n isLight?: boolean;\n sizeVariant?: AvatarSizeVariant;\n}\n\nfunction AvatarContent({\n size,\n src,\n firstname,\n lastname,\n alt,\n isLight,\n sizeVariant,\n}: AvatarContentProps): ReactElement {\n if (src) {\n return <Image source={{ uri: src }} style={{ width: size, height: size }} accessibilityLabel={alt} />;\n }\n\n if (firstname && lastname) {\n return (\n <Typography.Text\n base={sizeVariant === 'large' ? 'body-large' : 'body-small'}\n variant={sizeVariant === 'large' ? 'bold' : 'regular'}\n color={isLight ? 'black' : 'white'}\n >\n {getInitials(firstname, lastname)}\n </Typography.Text>\n );\n }\n\n return <Icon icon={<UserIcon />} color={isLight ? 'black' : 'white'} size={size / 2} />;\n}\nexport interface AvatarProps {\n size?: number;\n src?: string | null;\n alt?: string;\n firstname?: string | null;\n lastname?: string | null;\n round?: boolean;\n light?: boolean;\n sizeVariant?: AvatarSizeVariant;\n}\n\nexport function Avatar({ size = 40, round, light, sizeVariant, ...props }: AvatarProps): ReactElement {\n return (\n <StyledAvatarView $size={size} $isRound={round} $isLight={light} $sizeVariant={sizeVariant}>\n <AvatarContent size={size} isLight={light} sizeVariant={sizeVariant} {...props} />\n </StyledAvatarView>\n );\n}\n","import type { DefaultTheme } from 'styled-components/native';\nimport type { BaseButtonTheme, BaseButtonWithVariant } from '../themes/late-ocean/button';\nimport type { ButtonType, ButtonVariant } from './Button';\n\nconst hasVariant = (button: BaseButtonTheme, variant: ButtonVariant): button is BaseButtonWithVariant => {\n return variant in button;\n};\n\nexport function getVariantValuesIfExist<V extends ButtonVariant>(\n theme: DefaultTheme,\n type: ButtonType,\n variant: ButtonVariant,\n): BaseButtonTheme['default'] | BaseButtonWithVariant[V] {\n const button = theme.kitt.button[type];\n\n if (hasVariant(button, variant)) {\n return button[variant];\n }\n\n return theme.kitt.button[type].default;\n}\n","import type { ReactElement } from 'react';\nimport { forwardRef } from 'react';\nimport type { PressableProps, View } from 'react-native';\nimport Animated, { interpolateColor, useAnimatedStyle, useSharedValue, withSpring } from 'react-native-reanimated';\nimport styled, { useTheme } from 'styled-components/native';\nimport type { ButtonType, ButtonVariant } from './Button';\nimport { getVariantValuesIfExist } from './getVariantValuesIfExist';\n\nexport interface StyledPressableProps extends PressableProps {\n $isStretch?: boolean;\n $type: ButtonType;\n}\n\nconst StyledPressable = styled.Pressable<StyledPressableProps>`\n ${({ $isStretch }) => {\n if ($isStretch) return undefined;\n\n return 'align-self: flex-start;';\n }}\n`;\n\nconst StyledAnimatedView = styled(Animated.View)`\n border-radius: ${({ theme }) => theme.kitt.button.borderRadius}px;\n`;\n\nexport interface AnimatedButtonPressableProps extends PressableProps {\n accessibilityRole: NonNullable<PressableProps['accessibilityRole']>;\n $type: ButtonType;\n $variant: ButtonVariant;\n $isStretch?: boolean;\n}\n\nexport const AnimatedButtonPressable = forwardRef<View, AnimatedButtonPressableProps>(\n (\n {\n children,\n disabled,\n accessibilityRole,\n $type,\n $variant,\n $isStretch,\n href,\n hrefAttrs,\n testID,\n onPress,\n }: AnimatedButtonPressableProps,\n ref,\n ): ReactElement => {\n const theme = useTheme();\n const pressed = useSharedValue<0 | 1>(0);\n const color = useSharedValue(0);\n\n const { backgroundColor, pressedBackgroundColor } = getVariantValuesIfExist(theme, $type, $variant);\n const { scale } = theme.kitt.button;\n\n const scaleStyles = useAnimatedStyle(() => {\n return {\n backgroundColor: interpolateColor(color.value, [0, 1], [backgroundColor, pressedBackgroundColor]),\n transform: [\n {\n scale: withSpring(pressed.value ? scale.base.active : scale.base.default),\n },\n ],\n };\n });\n\n const handlePressInOut = (pressIn: boolean): void => {\n color.value = withSpring(pressIn ? 1 : 0);\n pressed.value = pressIn ? 1 : 0;\n };\n\n return (\n <StyledPressable\n ref={ref}\n disabled={disabled}\n accessibilityRole={accessibilityRole}\n testID={testID}\n href={href}\n hrefAttrs={hrefAttrs}\n $isStretch={$isStretch}\n $type={$type}\n onPress={onPress}\n onPressIn={() => {\n handlePressInOut(true);\n }}\n onPressOut={() => {\n handlePressInOut(false);\n }}\n >\n <StyledAnimatedView style={disabled ? [{ transform: [{ scale: 1 }] }] : [scaleStyles]}>\n {children}\n </StyledAnimatedView>\n </StyledPressable>\n );\n },\n);\n","import type { ViewProps } from 'react-native';\nimport { Platform } from 'react-native';\nimport styled from 'styled-components/native';\nimport type { ButtonType, ButtonVariant } from './Button';\nimport { getVariantValuesIfExist } from './getVariantValuesIfExist';\n\nexport interface BaseStyledButtonPressableProps extends ViewProps {\n $type: ButtonType;\n $variant: ButtonVariant;\n $isLarge?: boolean;\n $isStretch?: boolean;\n $isDisabled?: boolean;\n}\n\nexport const BaseStyledButtonPressable = styled.View<BaseStyledButtonPressableProps>`\n position: relative;\n min-width: ${({ theme }) => theme.kitt.button.minWidth}px;\n max-width: ${({ theme, $isStretch }) => ($isStretch ? '100%' : `${theme.kitt.button.maxWidth}px`)};\n width: ${({ $isStretch }) => ($isStretch ? '100%' : 'auto')};\n min-height: ${({ theme }) => theme.kitt.button.minHeight}px;\n border-radius: ${({ theme }) => theme.kitt.button.borderRadius}px;\n flex-direction: row;\n align-items: center;\n justify-content: center;\n\n /* Emulate inline-* css display by making the button taking only its necessary space */\n align-self: flex-start;\n\n background-color: ${({ theme, $isDisabled, $type, $variant }) => {\n if ($isDisabled) return theme.kitt.button.disabled.default.backgroundColor;\n\n if (Platform.OS !== 'web') return 'transparent';\n\n return getVariantValuesIfExist(theme, $type, $variant).backgroundColor;\n }};\n\n padding: ${({ theme, $isLarge, $isDisabled }) => {\n const { large, default: defaultPadding, disabled: disabledPadding } = theme.kitt.button.contentPadding;\n\n if ($isLarge) return large;\n if ($isDisabled) return disabledPadding;\n\n return defaultPadding;\n }};\n`;\n","import type { ReactElement } from 'react';\nimport { useTheme } from 'styled-components/native';\nimport type { Except } from 'type-fest';\nimport type { IconProps } from '../Icon/Icon';\nimport { Icon } from '../Icon/Icon';\nimport type { SetNonNullable } from '../utils/typeUtils';\nimport type { TypographyProps } from './Typography';\nimport { useTypographyColor } from './Typography';\n\nexport interface TypographyIconProps extends Except<IconProps, 'color'> {\n color?: TypographyProps['color'] | 'inherit';\n}\n\nfunction TypographyIconSpecifiedColor({ color, ...props }: SetNonNullable<TypographyIconProps, 'color'>): ReactElement {\n const theme = useTheme();\n return <Icon {...props} color={color === 'inherit' ? 'inherit' : theme.kitt.typography.colors[color]} />;\n}\n\nfunction TypographyIconInheritColor(props: TypographyIconProps): ReactElement {\n const color = useTypographyColor();\n\n return <TypographyIconSpecifiedColor color={color} {...props} />;\n}\n\nexport function TypographyIcon({ color, ...props }: TypographyIconProps): ReactElement {\n if (color) {\n return <TypographyIconSpecifiedColor color={color} {...props} />;\n }\n\n return <TypographyIconInheritColor {...props} />;\n}\n","import type { ButtonType, SubtleButtonType } from './Button';\n\nexport function isSubtle(type: ButtonType): type is SubtleButtonType {\n return type.startsWith('subtle');\n}\n","import type { ReactElement } from 'react';\nimport { Platform } from 'react-native';\nimport styled from 'styled-components/native';\nimport type { Except } from 'type-fest';\nimport type { TypographyColor, TypographyTextProps } from '../typography/Typography';\nimport { Typography } from '../typography/Typography';\nimport type { TypographyIconProps } from '../typography/TypographyIcon';\nimport { TypographyIcon } from '../typography/TypographyIcon';\nimport type { ButtonProps, ButtonType, ButtonVariant } from './Button';\nimport { isSubtle } from './isSubtle';\n\nconst getTextColorByType = (type: ButtonType, variant: ButtonVariant): TypographyColor => {\n switch (type) {\n case 'primary':\n return variant === 'ghost' ? 'primary' : 'white';\n case 'white':\n return 'white';\n case 'subtle':\n return 'primary';\n case 'subtle-dark':\n return 'black';\n default:\n return 'black';\n }\n};\n\ninterface StyledButtonTextProps extends TypographyTextProps {\n $type: ButtonType;\n $isDisabled?: boolean;\n}\n\nconst StyledButtonText = styled(Typography.Text)<StyledButtonTextProps>`\n /* On native code, this is the only way to ensure that the text is centered */\n text-align: center;\n\n ${() => {\n // Make the multilines case work properly on native\n // Breaks the web implem\n if (Platform.OS === 'web') return undefined;\n\n return `\n flex-shrink: 1;\n `;\n }}\n\n ${({ $type, $isDisabled }) => {\n /* For subltes button, color changes when hovered.\n * We don't want to use a mouse event handler with a react state to handle it\n * For this precise case, we've decided to work outside the typography logic\n */\n if (Platform.OS !== 'web' || $isDisabled || !isSubtle($type)) return undefined;\n return 'color: inherit';\n }}\n`;\n\ninterface StyledIconContainerProps {\n $iconPosition?: ButtonProps['iconPosition'];\n}\n\nconst StyledIconContainer = styled.View<StyledIconContainerProps>`\n ${({ theme, $iconPosition }) => {\n const value = theme.kitt.spacing * 2;\n\n if ($iconPosition === 'left') {\n return `margin: 0 ${value}px 0 0;`;\n }\n\n return `margin: 0 0 0 ${value}px;`;\n }}\n`;\n\ninterface ButtonIconProps {\n icon: NonNullable<ButtonContentProps['icon']>;\n iconPosition: ButtonContentProps['iconPosition'];\n color: TypographyIconProps['color'];\n testID?: string;\n}\n\nfunction ButtonIcon({ icon, color, iconPosition, testID }: ButtonIconProps): ReactElement | null {\n return (\n <StyledIconContainer $iconPosition={iconPosition}>\n <TypographyIcon icon={icon} testID={testID} color={color} />\n </StyledIconContainer>\n );\n}\n\ninterface ButtonContentProps extends Except<ButtonProps, 'onPress' | 'disabled' | 'stretch'> {\n isDisabled?: boolean;\n type: NonNullable<ButtonType>;\n variant: NonNullable<ButtonVariant>;\n $isStretch: ButtonProps['stretch'];\n}\n\ninterface ButtonContentChildrenProps extends Except<ButtonProps, 'onPress' | 'disabled' | 'stretch'> {\n isDisabled?: boolean;\n type: NonNullable<ButtonType>;\n color: TypographyColor;\n}\n\nconst StyledChildrenWithIcon = styled.View`\n align-items: center;\n justify-content: center;\n flex-direction: row;\n`;\n\nexport function ButtonContentChildren({\n type,\n icon,\n iconPosition,\n isDisabled,\n color,\n children,\n}: ButtonContentChildrenProps): ReactElement | null {\n if (__DEV__) {\n if (!(children || icon)) {\n throw new Error('kitt(Button): You should provide at least a children or a icon');\n }\n }\n\n const isWebSubtle = isSubtle(type) && Platform.OS === 'web' && !isDisabled;\n\n if (!children) {\n return (\n <TypographyIcon\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n icon={icon!}\n color={isWebSubtle ? 'inherit' : color}\n />\n );\n }\n\n const buttonIconSharedProps = {\n type,\n iconPosition,\n color: isWebSubtle ? 'inherit' : (color as TypographyIconProps['color']),\n };\n\n return (\n <StyledChildrenWithIcon>\n {icon && iconPosition === 'left' ? (\n <ButtonIcon {...buttonIconSharedProps} testID=\"button-left-icon\" icon={icon} />\n ) : null}\n\n <StyledButtonText\n base=\"body\"\n variant=\"bold\"\n $type={type}\n $isDisabled={isDisabled}\n // set to color: inherit via styled components\n color={isWebSubtle ? undefined : color}\n >\n {children}\n </StyledButtonText>\n\n {icon && iconPosition === 'right' ? <ButtonIcon {...buttonIconSharedProps} icon={icon} /> : null}\n </StyledChildrenWithIcon>\n );\n}\n\ninterface ButtonContentContainerProps {\n $isSubtle?: boolean;\n $isStretch?: boolean;\n $isIconOnly?: boolean;\n}\n\nconst ButtonContentContainer = styled.View<ButtonContentContainerProps>`\n line-height: 16px;\n\n ${({ $isStretch, $isIconOnly }) => {\n // Make the multilines case work properly on web\n // Breaks the native implem\n if (Platform.OS !== 'web') return undefined;\n\n return `\n flex: ${$isStretch || $isIconOnly ? 1 : 0} 1 auto;\n `;\n }}\n\n ${({ $isSubtle }) => {\n if (Platform.OS !== 'web' || !$isSubtle) return undefined;\n // Needed for subtle type\n return 'color: inherit';\n }};\n`;\n\nexport function ButtonContent({\n type,\n variant,\n isDisabled,\n $isStretch,\n icon,\n children,\n ...props\n}: ButtonContentProps): ReactElement {\n const color = isDisabled ? 'black-light' : getTextColorByType(type, variant);\n\n return (\n <ButtonContentContainer $isSubtle={isSubtle(type)} $isStretch={$isStretch} $isIconOnly={Boolean(!children && icon)}>\n <ButtonContentChildren icon={icon} type={type} isDisabled={isDisabled} color={color} {...props}>\n {children}\n </ButtonContentChildren>\n </ButtonContentContainer>\n );\n}\n","import styled from 'styled-components/native';\n\nexport const StyledDisabled = styled.View`\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n border: ${({ theme }) => {\n const { borderWidth, disabled } = theme.kitt.button;\n return `${borderWidth.disabled}px solid ${disabled.default.borderColor}`;\n }};\n border-radius: ${({ theme }) => theme.kitt.button.borderRadius}px;\n`;\n","import type { ReactElement, ReactNode } from 'react';\nimport { forwardRef } from 'react';\nimport type { PressableProps, View } from 'react-native';\nimport { Platform } from 'react-native';\nimport { AnimatedButtonPressable } from './AnimatedButtonPressable';\nimport { BaseStyledButtonPressable } from './BaseStyledButtonPressable';\nimport { ButtonContent } from './ButtonContent';\nimport { StyledDisabled } from './StyledDisabled';\n\nexport type SubtleButtonType = 'subtle' | 'subtle-dark';\nexport type ButtonType = 'primary' | 'default' | SubtleButtonType | 'white';\n\nexport type ButtonVariant = 'default' | 'ghost';\n\ntype IconPosition = 'right' | 'left';\n\nexport interface ButtonProps {\n children?: ReactNode;\n type?: ButtonType;\n variant?: ButtonVariant;\n disabled?: boolean;\n stretch?: boolean;\n large?: boolean;\n icon?: ReactElement;\n iconPosition?: IconPosition;\n testID?: PressableProps['testID'];\n href?: PressableProps['href'];\n hrefAttrs?: PressableProps['hrefAttrs'];\n accessibilityRole?: PressableProps['accessibilityRole'];\n className?: string;\n style?: PressableProps['style'];\n onPress?: PressableProps['onPress'];\n}\n\nexport const Button = forwardRef<View, ButtonProps>(\n (\n {\n children,\n type = 'default',\n variant = 'default',\n disabled,\n stretch,\n large,\n icon,\n iconPosition = 'left',\n testID,\n href,\n hrefAttrs,\n accessibilityRole = 'button',\n onPress,\n }: ButtonProps,\n ref,\n ): ReactElement => {\n if (__DEV__ && variant === 'ghost' && type !== 'primary') {\n throw new Error('variant=ghost is only allowed with type=primary');\n }\n\n return (\n <AnimatedButtonPressable\n ref={ref}\n accessibilityRole={accessibilityRole}\n testID={testID}\n href={href}\n hrefAttrs={hrefAttrs}\n disabled={disabled}\n $isStretch={stretch}\n $type={type}\n $variant={variant}\n onPress={onPress}\n >\n <BaseStyledButtonPressable\n $type={type}\n $variant={variant}\n $isStretch={stretch}\n $isLarge={large}\n $isDisabled={disabled}\n >\n <ButtonContent\n type={type}\n variant={variant}\n $isStretch={stretch}\n isDisabled={disabled}\n icon={icon}\n iconPosition={iconPosition}\n >\n {children}\n </ButtonContent>\n {Platform.OS !== 'web' && disabled ? <StyledDisabled /> : null}\n </BaseStyledButtonPressable>\n </AnimatedButtonPressable>\n );\n },\n);\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\n\ntype CardType = 'primary' | 'secondary' | 'subtle';\n\nexport interface CardProps {\n children: NonNullable<ReactNode>;\n type: CardType;\n}\ninterface ContainerProps {\n type: CardType;\n}\n\nconst Container = styled.View<ContainerProps>`\n background-color: ${({ theme, type }) => theme.kitt.card[type].backgroundColor};\n padding: ${({ theme }) => theme.kitt.spacing * 4}px;\n border-radius: ${({ theme }) => theme.kitt.card.borderRadius}px;\n border-width: ${({ theme }) => theme.kitt.card.borderWidth}px;\n border-color: ${({ theme, type }) => theme.kitt.card[type].borderColor};\n`;\n\nexport function Card({ children, type }: CardProps): ReactElement {\n return <Container type={type}>{children}</Container>;\n}\n","import type { ReactElement } from 'react';\nimport { useMemo } from 'react';\nimport type { ImageProps } from 'react-native';\nimport { Platform } from 'react-native';\nimport styled from 'styled-components/native';\nimport { parse } from 'twemoji-parser';\n\ninterface StyledEmojiProps {\n size: number;\n}\n\nconst StyledEmoji = styled.Image<StyledEmojiProps>`\n width: ${({ size }) => size}px;\n height: ${({ size }) => size}px;\n`;\n\nexport interface EmojiProps extends Pick<ImageProps, 'style'> {\n emoji: string;\n size: number;\n}\n\nexport function Emoji({ emoji, size, style }: EmojiProps): ReactElement | null {\n const [emojiData] = useMemo(\n () =>\n parse(emoji, {\n // on native plaforms, you can't display svg as Image\n assetType: Platform.OS === 'web' ? 'svg' : 'png',\n }),\n [emoji],\n );\n\n if (!emojiData) return null;\n\n return <StyledEmoji size={size} accessibilityLabel={emojiData.text} source={{ uri: emojiData.url }} style={style} />;\n}\n","export interface ExternalLinkOpenLinkBehavior {\n /**\n * @default 'openInModal'\n *\n * @description open link behavior in native\n *\n * \"openInModal\": open via [expo-web-browser](https://docs.expo.dev/versions/latest/sdk/webbrowser/)\n *\n * \"openBrowserApp\": open via [Linking](https://docs.expo.dev/guides/linking/#opening-links-from-your-app)\n */\n native?: 'openInModal' | 'openBrowserApp';\n\n /**\n * @default 'targetBlank'\n *\n * @description open link behavior in native\n *\n * \"targetSelf\": no dom attributes added, behave like `target=\"_self\"`\n *\n * \"targetBlank\": dome attributes: `target=\"_blank\" rel=\"noopener noreferrer\"`\n */\n web?: 'targetSelf' | 'targetBlank';\n}\n\nexport const defaultOpenLinkBehavior: ExternalLinkOpenLinkBehavior = {\n native: 'openInModal',\n web: 'targetBlank',\n};\n","import * as WebBrowser from 'expo-web-browser';\nimport type { ComponentProps, ReactElement, VoidFunctionComponent } from 'react';\nimport type { PressableProps, TextProps } from 'react-native';\nimport { Linking } from 'react-native';\nimport type { ExternalLinkOpenLinkBehavior } from './ExternalLinkOpenLinkBehavior';\nimport { defaultOpenLinkBehavior } from './ExternalLinkOpenLinkBehavior';\n\nexport interface ExternalLinkAsComponentMinimumRequiredProps {\n href?: TextProps['href'];\n hrefAttrs?: TextProps['hrefAttrs'];\n onPress?: PressableProps['onPress'];\n}\n\nexport interface ExternalLinkProps<C extends VoidFunctionComponent<any>> {\n as: C;\n openLinkBehavior?: ExternalLinkOpenLinkBehavior;\n href?: string;\n onPress?: PressableProps['onPress'];\n}\n\n/** @internal for ExternalLink.web.tsx only */\n// eslint-disable-next-line @typescript-eslint/ban-types\nexport type ExternalLinkSendableComponentProps<C extends VoidFunctionComponent<any>> = Omit<\n ComponentProps<C>,\n keyof ExternalLinkProps<C> & keyof ExternalLinkAsComponentMinimumRequiredProps\n>;\n\nexport function ExternalLink<C extends VoidFunctionComponent<any>>({\n as: Component,\n href,\n openLinkBehavior = defaultOpenLinkBehavior,\n onPress,\n ...rest\n}: ExternalLinkProps<C> & ExternalLinkSendableComponentProps<C>): ReactElement {\n const handleOnPress: PressableProps['onPress'] = (e) => {\n if (onPress) {\n onPress(e);\n if (e?.defaultPrevented) return;\n }\n\n if (!href) return;\n\n switch (openLinkBehavior.native) {\n case 'openInModal':\n case undefined:\n WebBrowser.openBrowserAsync(href).catch((err) => {\n console.error(`An error occurred while opening ${href}`, err);\n });\n break;\n case 'openBrowserApp':\n Linking.openURL(href).catch((err) => {\n console.error(`An error occurred while opening ${href}`, err);\n });\n break;\n default:\n if (__DEV__) {\n throw new Error(`Invalid ExternalLink native behavior: ${openLinkBehavior.native as string}`);\n }\n }\n };\n\n return <Component {...(rest as any)} onPress={handleOnPress} />;\n}\n","export const lateOceanColorPalette = {\n lateOcean: '#4C34E0',\n lateOceanLight1: '#705DE6',\n lateOceanLight2: '#9485EC',\n lateOceanLight3: '#D6BAF9',\n\n warmEmbrace: '#F4D3CE',\n warmEmbraceLight1: '#FFEDE6',\n\n black1000: '#000000',\n black800: '#2C293D',\n black555: '#737373',\n black200: '#CCCCCC',\n black100: '#E5E5E5',\n black50: '#F2F2F2',\n black25: '#F9F9F9',\n white: '#FFFFFF',\n\n viride: '#38836D',\n englishVermillon: '#D44148',\n goldCrayola: '#F8C583',\n aero: '#89BDDD',\n\n transparent: 'transparent',\n\n moonPurple: '#DBD6F9',\n moonPurpleLight1: '#EDEBFC',\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const colors = {\n primary: lateOceanColorPalette.lateOcean,\n primaryLight: lateOceanColorPalette.lateOceanLight1,\n accent: lateOceanColorPalette.warmEmbrace,\n accentLight: lateOceanColorPalette.warmEmbraceLight1,\n success: lateOceanColorPalette.viride,\n correct: lateOceanColorPalette.viride,\n danger: lateOceanColorPalette.englishVermillon,\n info: lateOceanColorPalette.aero,\n warning: lateOceanColorPalette.goldCrayola,\n separator: lateOceanColorPalette.black100,\n hover: lateOceanColorPalette.black100,\n white: lateOceanColorPalette.white,\n black: lateOceanColorPalette.black1000,\n blackAnthracite: lateOceanColorPalette.black800,\n uiBackground: lateOceanColorPalette.black25,\n uiBackgroundLight: lateOceanColorPalette.white,\n transparent: lateOceanColorPalette.transparent,\n disabled: lateOceanColorPalette.black50,\n overlay: {\n dark: 'rgba(41, 48, 51, 0.25)',\n light: 'rgba(255, 255, 255, 0.90)',\n fullscreenLoader: 'rgba(0, 0, 0, 0.25)',\n },\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\n\nexport interface AvatarThemeColorVariant {\n backgroundColor: string;\n}\n\nexport interface AvatarThemeSizeVariant {\n borderRadius: number;\n}\n\nexport interface AvatarTheme {\n borderRadius: number;\n default: AvatarThemeColorVariant;\n light: AvatarThemeColorVariant;\n large: AvatarThemeSizeVariant;\n}\n\nexport const avatar: AvatarTheme = {\n borderRadius: 10,\n default: {\n backgroundColor: colors.primary,\n },\n light: {\n backgroundColor: lateOceanColorPalette.black100,\n },\n large: {\n borderRadius: 30,\n },\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\n\nexport interface BaseVariantTheme {\n backgroundColor: string;\n pressedBackgroundColor: string;\n hoverBackgroundColor: string;\n focusBorderColor: string;\n}\n\nexport interface GhostVariantTheme extends BaseVariantTheme {\n color: string;\n hoverColor: string;\n activeColor: string;\n}\nexport interface BaseButtonTheme {\n default: BaseVariantTheme;\n}\n\nexport interface BaseButtonWithVariant extends BaseButtonTheme {\n ghost: GhostVariantTheme;\n}\n\nexport interface SubtleBaseVariantTheme extends BaseVariantTheme {\n color: string;\n hoverColor: string;\n activeColor: string;\n}\n\nexport interface SubtleButtonTheme extends BaseButtonTheme {\n default: SubtleBaseVariantTheme;\n}\n\nexport interface DisabledBaseVariantTheme extends BaseVariantTheme {\n borderColor: string;\n}\n\nexport interface DisabledButtonTheme extends BaseButtonTheme {\n default: DisabledBaseVariantTheme;\n}\n\nexport interface ButtonTheme {\n borderRadius: number;\n borderWidth: {\n disabled: number;\n focus: number;\n };\n minHeight: number;\n minWidth: number;\n maxWidth: number;\n scale: {\n base: {\n default: number;\n hover: number;\n active: number;\n };\n medium: {\n hover: number;\n };\n };\n contentPadding: {\n default: string;\n large: string;\n disabled: string;\n };\n transition: {\n duration: string;\n timingFunction: string;\n };\n default: BaseButtonTheme;\n primary: BaseButtonWithVariant;\n white: BaseButtonTheme;\n subtle: SubtleButtonTheme;\n 'subtle-dark': SubtleButtonTheme;\n disabled: DisabledButtonTheme;\n}\n\nexport const button: ButtonTheme = {\n borderRadius: 30,\n borderWidth: {\n disabled: 2,\n focus: 3,\n },\n minHeight: 40,\n minWidth: 40,\n maxWidth: 335,\n scale: {\n base: {\n default: 1,\n hover: 0.95,\n active: 0.95,\n },\n medium: {\n hover: 1.05,\n },\n },\n contentPadding: {\n default: '7px 16px 7px',\n large: '11px 24px 11px',\n disabled: '5px 14px 5px',\n },\n transition: {\n duration: '200ms',\n timingFunction: 'cubic-bezier(0.645, 0.045, 0.355, 1)',\n },\n default: {\n default: {\n backgroundColor: 'rgba(0, 0, 0, 0.05)',\n pressedBackgroundColor: 'rgba(0, 0, 0, 0.1)',\n hoverBackgroundColor: 'rgba(0, 0, 0, 0.1)',\n focusBorderColor: 'rgba(0, 0, 0, 0.1)',\n },\n },\n primary: {\n default: {\n backgroundColor: colors.primary,\n pressedBackgroundColor: colors.primaryLight,\n hoverBackgroundColor: colors.primaryLight,\n focusBorderColor: 'rgba(76, 52, 224, 0.2)',\n },\n ghost: {\n backgroundColor: colors.uiBackgroundLight,\n pressedBackgroundColor: colors.uiBackground,\n hoverBackgroundColor: colors.hover,\n focusBorderColor: 'rgba(255,255,255, 0.4)',\n color: colors.primary,\n hoverColor: colors.hover,\n activeColor: colors.hover,\n },\n },\n white: {\n default: {\n backgroundColor: 'rgba(255, 255, 255, 0.05)',\n pressedBackgroundColor: 'rgba(255, 255, 255, 0.1)',\n hoverBackgroundColor: 'rgba(255, 255, 255, 0.1)',\n focusBorderColor: 'rgba(255, 255, 255, 0.1)',\n },\n },\n subtle: {\n default: {\n backgroundColor: colors.transparent,\n pressedBackgroundColor: colors.transparent,\n hoverBackgroundColor: colors.transparent,\n focusBorderColor: 'rgba(76, 52, 224, 0.2)',\n color: colors.primary,\n hoverColor: 'rgba(76, 52, 224, 0.8)',\n activeColor: 'rgba(76, 52, 224, 0.8)',\n },\n },\n 'subtle-dark': {\n default: {\n backgroundColor: colors.transparent,\n pressedBackgroundColor: colors.transparent,\n hoverBackgroundColor: colors.transparent,\n focusBorderColor: 'rgba(0, 0, 0, 0.1)',\n color: colors.black,\n hoverColor: 'rgba(0, 0, 0, 0.8)',\n activeColor: 'rgba(0, 0, 0, 0.8)',\n },\n },\n disabled: {\n default: {\n backgroundColor: colors.disabled,\n pressedBackgroundColor: colors.disabled,\n hoverBackgroundColor: colors.disabled,\n focusBorderColor: lateOceanColorPalette.black100,\n borderColor: lateOceanColorPalette.black100,\n },\n },\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\n\nexport interface CardThemeType {\n backgroundColor: string;\n borderColor: string;\n}\nexport interface CardTheme {\n borderRadius: number;\n borderWidth: number;\n primary: CardThemeType;\n secondary: CardThemeType;\n subtle: CardThemeType;\n}\n\nexport const card: CardTheme = {\n borderRadius: 20,\n borderWidth: 2,\n primary: {\n backgroundColor: colors.uiBackgroundLight,\n borderColor: colors.primary,\n },\n secondary: {\n backgroundColor: colors.uiBackgroundLight,\n borderColor: colors.separator,\n },\n subtle: {\n backgroundColor: lateOceanColorPalette.black50,\n borderColor: colors.separator,\n },\n};\n","import { colors } from './colors';\n\nexport interface FeedbackMessageVariantTheme {\n backgroundColor: string;\n}\n\nexport interface FeedbackMessageTheme {\n danger: FeedbackMessageVariantTheme;\n info: FeedbackMessageVariantTheme;\n success: FeedbackMessageVariantTheme;\n warning: FeedbackMessageVariantTheme;\n}\n\nexport const feedbackMessage: FeedbackMessageTheme = {\n danger: {\n backgroundColor: colors.danger,\n },\n success: {\n backgroundColor: colors.success,\n },\n info: {\n backgroundColor: colors.info,\n },\n warning: {\n backgroundColor: colors.warning,\n },\n};\n","import { colors } from './colors';\n\nexport const checkbox = {\n borderWidth: 2,\n borderRadius: 5,\n height: 20,\n width: 20,\n iconSize: 14,\n borderColor: colors.separator,\n backgroundColor: colors.uiBackgroundLight,\n checkedBorderColor: colors.primary,\n checkedBackgroundColor: colors.primary,\n markColor: colors.uiBackgroundLight,\n};\n","interface DatePickerPartTheme {\n minWidth: number;\n}\n\nexport interface DatePickerTheme {\n day: DatePickerPartTheme;\n month: DatePickerPartTheme;\n year: DatePickerPartTheme;\n}\n\nexport const datePicker: DatePickerTheme = {\n day: {\n minWidth: 64,\n },\n month: {\n minWidth: 64,\n },\n year: {\n minWidth: 82,\n },\n};\n","import { Platform } from 'react-native';\nimport { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors as kittColors } from './colors';\n\nexport const calcLineHeight = (fontSize: number, lineHeightMultiplier: number): number =>\n Math.round(fontSize * lineHeightMultiplier);\n\nexport interface TypographyTypeBreakpointRangeConfig {\n fontSize: number;\n lineHeight: number;\n}\n\nexport interface TypographyTypeConfig {\n baseAndSmall: TypographyTypeBreakpointRangeConfig;\n mediumAndWide: TypographyTypeBreakpointRangeConfig;\n}\n\nexport const createTypographyTypeConfig = (\n lineHeightMultiplier: number,\n baseAndSmallFontSize: number,\n mediumAndWideFontSize: number,\n): TypographyTypeConfig => ({\n baseAndSmall: {\n fontSize: baseAndSmallFontSize,\n lineHeight: calcLineHeight(baseAndSmallFontSize, lineHeightMultiplier),\n },\n mediumAndWide: {\n fontSize: mediumAndWideFontSize,\n lineHeight: calcLineHeight(mediumAndWideFontSize, lineHeightMultiplier),\n },\n});\n\nexport const typography = {\n colors: {\n black: kittColors.black,\n 'black-anthracite': kittColors.blackAnthracite,\n 'black-light': lateOceanColorPalette.black555,\n white: kittColors.white,\n 'white-light': kittColors.white,\n primary: kittColors.primary,\n 'primary-light': kittColors.primaryLight,\n accent: kittColors.accent,\n success: kittColors.success,\n danger: kittColors.danger,\n },\n types: {\n headers: {\n fontFamily: {\n regular: Platform.OS === 'web' ? 'Moderat' : 'Moderat-Extended-Bold',\n bold: Platform.OS === 'web' ? 'Moderat' : 'Moderat-Extended-Bold',\n },\n fontWeight: 400,\n fontStyle: 'normal',\n configs: {\n // also known as xxlarge\n header1: createTypographyTypeConfig(1.3, 38, 62),\n // also known as xlarge\n header2: createTypographyTypeConfig(1.3, 32, 48),\n // also known as medium\n header3: createTypographyTypeConfig(1.3, 24, 36),\n // also known as xsmall\n header4: createTypographyTypeConfig(1.3, 18, 24),\n // also known as xxsmall\n header5: createTypographyTypeConfig(1.3, 18, 18),\n },\n },\n bodies: {\n fontFamily: {\n regular: Platform.OS === 'web' ? 'Noto Sans' : 'NotoSans',\n bold: Platform.OS === 'web' ? 'Noto Sans' : 'NotoSans-Bold',\n },\n fontWeight: {\n regular: 400,\n bold: 700,\n },\n fontStyle: {\n regular: 'normal',\n bold: 'normal',\n },\n configs: {\n 'body-large': createTypographyTypeConfig(1.6, 18, 24),\n 'body-medium': createTypographyTypeConfig(1.6, 18, 18),\n body: createTypographyTypeConfig(1.6, 16, 16),\n 'body-small': createTypographyTypeConfig(1.6, 14, 14),\n 'body-xsmall': createTypographyTypeConfig(1.6, 12, 12),\n },\n },\n },\n link: {\n disabledColor: lateOceanColorPalette.black200,\n },\n};\n","import type { InputUIState } from '../../forms/utils';\nimport { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\nimport { typography } from './typography';\n\nexport interface InputStateStyle {\n backgroundColor?: string;\n borderColor: string;\n color: keyof typeof typography.colors;\n}\n\nexport type InputStateTheme = Record<InputUIState, InputStateStyle>;\n\nconst inputStatesStyle: InputStateTheme = {\n default: {\n backgroundColor: colors.uiBackgroundLight,\n borderColor: colors.separator,\n color: 'black',\n },\n pending: {\n backgroundColor: colors.uiBackgroundLight,\n borderColor: colors.separator,\n color: 'black',\n },\n valid: {\n backgroundColor: colors.uiBackgroundLight,\n borderColor: lateOceanColorPalette.black100,\n color: 'black',\n },\n hover: {\n borderColor: lateOceanColorPalette.black200,\n color: 'black',\n },\n focus: {\n borderColor: colors.primary,\n color: 'black',\n },\n disabled: {\n backgroundColor: colors.disabled,\n borderColor: colors.separator,\n color: 'black-light',\n },\n invalid: {\n borderColor: colors.separator,\n color: 'black',\n },\n};\n\nexport interface InputTheme {\n minHeight: number;\n color: {\n selection: string;\n placeholder: string;\n };\n borderWidth: number;\n borderRadius: number;\n icon: {\n size: number;\n };\n padding: {\n default: string;\n iOSSingleLine: string;\n };\n transition: {\n property: string;\n duration: string;\n timingFunction: string;\n };\n states: InputStateTheme;\n}\n\nexport const input: InputTheme = {\n minHeight: 40,\n color: {\n selection: colors.primary,\n placeholder: typography.colors['black-light'],\n },\n borderWidth: 2,\n borderRadius: 10,\n icon: {\n size: 20,\n },\n padding: {\n default: '5px 16px',\n iOSSingleLine: '7px 16px',\n },\n transition: {\n property: 'border-color',\n duration: '200ms',\n timingFunction: 'ease-in-out',\n },\n states: inputStatesStyle,\n};\n","export const inputField = {\n labelContainerPaddingBottom: 5,\n iconMarginLeft: 6,\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\n\ninterface InputTagTypeTheme {\n backgroundColor: string;\n labelColor: string;\n}\nexport interface InputTagTheme {\n borderRadius: number;\n iconSize: number;\n default: InputTagTypeTheme;\n success: InputTagTypeTheme;\n danger: InputTagTypeTheme;\n}\n\nexport const inputTag: InputTagTheme = {\n success: {\n backgroundColor: colors.success,\n labelColor: colors.uiBackgroundLight,\n },\n danger: {\n backgroundColor: colors.danger,\n labelColor: colors.uiBackgroundLight,\n },\n default: {\n backgroundColor: lateOceanColorPalette.black50,\n labelColor: colors.black,\n },\n borderRadius: 10,\n iconSize: 13.5,\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\n\nexport interface RadioTheme {\n size: number;\n unchecked: {\n backgroundColor: string;\n borderColor: string;\n borderWidth: number;\n };\n checked: {\n backgroundColor: string;\n innerBackgroundColor: string;\n innerSize: number;\n };\n disabled: {\n backgroundColor: string;\n borderColor: string;\n };\n}\n\nexport const radio: RadioTheme = {\n size: 18,\n unchecked: {\n backgroundColor: colors.uiBackgroundLight,\n borderWidth: 2,\n borderColor: lateOceanColorPalette.black200,\n },\n checked: {\n backgroundColor: colors.primary,\n innerSize: 5,\n innerBackgroundColor: colors.uiBackgroundLight,\n },\n disabled: {\n backgroundColor: colors.disabled,\n borderColor: colors.separator,\n },\n};\n","export interface TextAreaTheme {\n minHeight: number;\n}\n\nexport const textArea: TextAreaTheme = {\n minHeight: 120,\n};\n","import { checkbox } from './checkbox';\nimport { datePicker } from './datePicker';\nimport { input } from './input';\nimport { inputField } from './inputField';\nimport { inputTag } from './inputTag';\nimport { radio } from './radio';\nimport { textArea } from './textArea';\n\nexport const forms = {\n datePicker,\n input,\n radio,\n inputField,\n textArea,\n checkbox,\n inputTag,\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const fullScreenModal = {\n header: {\n paddingVertical: 12,\n paddingHorizontal: 16,\n borderColor: lateOceanColorPalette.black100,\n },\n};\n","import { button } from './button';\n\ninterface IconButtonVariationValues {\n pressedBackgroundColor: string;\n}\n\nexport interface IconButtonTheme {\n backgroundColor: string;\n width: number;\n height: number;\n borderRadius: number;\n borderWidth: number;\n borderColor: string;\n transition: {\n property: string;\n duration: string;\n timingFunction: string;\n };\n scale: {\n base: {\n default: number;\n hover: number;\n active: number;\n };\n medium: {\n hover: number;\n };\n };\n disabled: {\n scale: number;\n backgroundColor: string;\n borderColor: string;\n };\n default: IconButtonVariationValues;\n white: IconButtonVariationValues;\n}\n\nexport const iconButton: IconButtonTheme = {\n backgroundColor: 'transparent',\n width: 40,\n height: 40,\n borderRadius: 20,\n borderWidth: 2,\n borderColor: 'transparent',\n transition: {\n property: 'all',\n duration: '200ms',\n timingFunction: 'cubic-bezier(0.645, 0.045, 0.355, 1);',\n },\n scale: {\n base: {\n default: 1,\n hover: 0.95,\n active: 0.95,\n },\n medium: {\n hover: 1.05,\n },\n },\n disabled: {\n scale: 1,\n backgroundColor: button.disabled.default.backgroundColor,\n borderColor: button.disabled.default.borderColor,\n },\n default: {\n pressedBackgroundColor: button.default.default.pressedBackgroundColor,\n },\n white: {\n pressedBackgroundColor: button.white.default.hoverBackgroundColor,\n },\n};\n","import { colors } from './colors';\n\nexport interface ListItemTheme {\n padding: string;\n borderColor: string;\n borderWidth: number;\n innerMargin: number;\n}\n\nexport const listItem: ListItemTheme = {\n padding: '12px 16px',\n borderColor: colors.separator,\n borderWidth: 1,\n innerMargin: 8,\n};\n","export interface PageLoaderTheme {\n size: number;\n}\n\nexport const pageLoader: PageLoaderTheme = {\n size: 60,\n};\n","export const shadows = {\n medium: '0px 10px 20px rgba(41, 48, 51, 0.25)',\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport interface SkeletonTheme {\n backgroundColor: string;\n flareColor: string;\n animationDuration: number;\n}\n\nexport const skeleton: SkeletonTheme = {\n backgroundColor: lateOceanColorPalette.black100,\n flareColor: lateOceanColorPalette.black200,\n animationDuration: 1000,\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\n\nexport interface TagVariantTheme {\n borderWidth: number;\n backgroundColor: string;\n borderColor: string;\n}\n\nexport interface TagTypeTheme {\n fill: TagVariantTheme;\n outline: TagVariantTheme;\n}\n\nexport interface TagTheme {\n borderRadius: number;\n padding: string;\n primary: TagTypeTheme;\n default: TagTypeTheme;\n danger: TagTypeTheme;\n}\n\nexport const tag: TagTheme = {\n borderRadius: 10,\n padding: '2px 12px',\n primary: {\n fill: {\n backgroundColor: lateOceanColorPalette.moonPurpleLight1,\n borderWidth: 0,\n borderColor: colors.transparent,\n },\n outline: {\n backgroundColor: colors.transparent,\n borderWidth: 1,\n borderColor: colors.primary,\n },\n },\n default: {\n fill: {\n backgroundColor: lateOceanColorPalette.black50,\n borderWidth: 0,\n borderColor: colors.transparent,\n },\n outline: {\n backgroundColor: colors.transparent,\n borderWidth: 1,\n borderColor: colors.black,\n },\n },\n danger: {\n fill: {\n backgroundColor: lateOceanColorPalette.warmEmbrace,\n borderWidth: 0,\n borderColor: colors.transparent,\n },\n outline: {\n backgroundColor: colors.transparent,\n borderWidth: 1,\n borderColor: colors.danger,\n },\n },\n};\n","import { colors } from './colors';\n\nexport interface TooltipTheme {\n backgroundColor: string;\n borderRadius: number;\n opacity: number;\n horizontalPadding: number;\n verticalPadding: number;\n floatingPadding: number;\n}\n\nexport const tooltip: TooltipTheme = {\n backgroundColor: colors.black,\n borderRadius: 10,\n opacity: 0.95,\n horizontalPadding: 16,\n verticalPadding: 4,\n floatingPadding: 8,\n};\n","import { avatar } from './late-ocean/avatar';\nimport { button } from './late-ocean/button';\nimport { card } from './late-ocean/card';\nimport { colors } from './late-ocean/colors';\nimport { feedbackMessage } from './late-ocean/feedback';\nimport { forms } from './late-ocean/forms';\nimport { fullScreenModal } from './late-ocean/fullScreenModal';\nimport { iconButton } from './late-ocean/iconButton';\nimport { listItem } from './late-ocean/listItem';\nimport { pageLoader } from './late-ocean/pageLoader';\nimport { shadows } from './late-ocean/shadows';\nimport { skeleton } from './late-ocean/skeleton';\nimport { tag } from './late-ocean/tag';\nimport { tooltip } from './late-ocean/tooltip';\nimport { typography } from './late-ocean/typography';\nimport { lateOceanColorPalette } from './palettes/lateOceanColorPalette';\n\nconst breakpoints = {\n values: {\n base: 0,\n small: 480,\n medium: 768,\n large: 1024,\n wide: 1280,\n },\n min: {\n smallBreakpoint: 'min-width: 480px',\n mediumBreakpoint: 'min-width: 768px',\n largeBreakpoint: 'min-width: 1024px',\n wideBreakpoint: 'min-width: 1280px',\n },\n max: {\n smallBreakpoint: 'max-width: 479px',\n mediumBreakpoint: 'max-width: 767px',\n largeBreakpoint: 'max-width: 1023px',\n wideBreakpoint: 'max-width: 1279px',\n },\n};\n\n// eslint-disable-next-line unicorn/expiring-todo-comments\n// TODO : seperate brand color usage definition from proper theme definition and add typings - https://ornikar.atlassian.net/browse/CME-156\nexport const theme = {\n spacing: 4,\n colors,\n palettes: { lateOcean: lateOceanColorPalette },\n avatar,\n breakpoints,\n button,\n card,\n feedbackMessage,\n forms,\n fullScreenModal,\n iconButton,\n listItem,\n pageLoader,\n shadows,\n skeleton,\n tag,\n tooltip,\n typography,\n};\n\nexport type Theme = typeof theme;\n","import { useWindowDimensions } from 'react-native';\nimport type { WindowDimensions } from './createWindowSizeHelper';\n\nexport interface MatchWindowSizeOptions {\n minWidth?: number;\n maxWidth?: number;\n minHeight?: number;\n maxHeight?: number;\n}\nexport function matchWindowSize(\n { width, height }: WindowDimensions,\n { minWidth, maxWidth, minHeight, maxHeight }: MatchWindowSizeOptions,\n): boolean {\n const hasWidthMatched = width ? (!minWidth || width >= minWidth) && (!maxWidth || width <= maxWidth) : true;\n const hasHeightMatched = height ? (!minHeight || height >= minHeight) && (!maxHeight || height <= maxHeight) : true;\n return hasWidthMatched && hasHeightMatched;\n}\n\nexport function useMatchWindowSize(options: MatchWindowSizeOptions): boolean {\n const { width, height } = useWindowDimensions();\n return matchWindowSize({ width, height }, options);\n}\n","// eslint-disable-next-line no-restricted-imports\nimport type { FlattenSimpleInterpolation } from 'styled-components';\nimport type { MatchWindowSizeOptions } from './useMatchWindowSize';\nimport { matchWindowSize } from './useMatchWindowSize';\n\nexport interface WindowSizeHelper {\n /** Prefer using if or map variants, at it should be more web friendly */\n matchWindowSize: (options: MatchWindowSizeOptions) => boolean;\n\n /**\n * @example\n * ```typescript\n * const Container = styled.View`\n * ${({ theme }) =>\n * theme.responsive.ifWindowSizeMatches(\n * { minWidth: KittBreakpoints.SMALL },\n * 'padding: 5px 0 10px;'\n * )\n * )};\n * `;\n * ```\n */\n ifWindowSizeMatches: <T extends string | FlattenSimpleInterpolation | null>(\n options: MatchWindowSizeOptions,\n valueIfTrue: T,\n valueIfFalse?: T,\n ) => T | undefined;\n\n /**\n *\n * @example\n * ```typescript\n * const Container = styled.View`\n * ${({ theme }) =>\n * theme.responsive.mapWindowWidth(\n * [KittBreakpoints.BASE, 'padding: 5px 0 10px;'],\n * [KittBreakpoints.SMALL, 'padding: 10px 0;'],\n * )\n * )};\n * `;\n * ```\n */\n mapWindowWidth: <V extends string>(...widthList: [number, V][]) => V | null;\n}\n\nexport interface WindowDimensions {\n width?: number;\n height?: number;\n}\n\nexport function createWindowSizeHelper(dimensions: WindowDimensions): WindowSizeHelper {\n return {\n matchWindowSize: (options) => matchWindowSize(dimensions, options),\n\n ifWindowSizeMatches: (options, valueIfTrue, valueIfFalse) =>\n matchWindowSize(dimensions, options) ? valueIfTrue : valueIfFalse,\n\n mapWindowWidth: <V extends string>(...widthList: [number, V][]): V | null => {\n if (__DEV__) {\n widthList.slice(1).forEach(([minWidth], index) => {\n const previousMinWidth = widthList[index][0];\n if (previousMinWidth > minWidth) {\n throw new Error(\n `mapWindowWidth: sort your values to be mobile first. ${minWidth} is < ${previousMinWidth}, so ${minWidth} should be before ${previousMinWidth}.`,\n );\n }\n });\n }\n const found = widthList.find(([minWidth, value]) => matchWindowSize(dimensions, { minWidth: Number(minWidth) }));\n if (!found) return null;\n return found[1];\n },\n };\n}\n","import { useMemo } from 'react';\nimport type { Theme } from './themes/default';\nimport { theme as kittTheme } from './themes/default';\nimport type { WindowSizeHelper } from './utils/windowSize/createWindowSizeHelper';\nimport { createWindowSizeHelper } from './utils/windowSize/createWindowSizeHelper';\nimport { useWindowSize } from './utils/windowSize/useWindowSize';\n\nexport interface KittTheme {\n kitt: Theme;\n responsive: WindowSizeHelper;\n}\n\nexport function useKittTheme(): KittTheme {\n const dimensions = useWindowSize();\n return useMemo(() => {\n return { kitt: kittTheme, responsive: createWindowSizeHelper(dimensions) };\n }, [dimensions]);\n}\n","import { CheckboxMark } from '@ornikar/kitt-icons';\nimport type { ReactElement, ReactNode } from 'react';\nimport type { GestureResponderEvent, PressableProps } from 'react-native';\nimport styled, { css } from 'styled-components/native';\nimport { Icon } from '../../Icon/Icon';\nimport { useKittTheme } from '../../useKittTheme';\n\ninterface CheckboxContainerProps {\n $isChecked: boolean;\n $hasLabel: boolean;\n}\n\nconst CheckboxAndLabelPressableWrapper = styled.Pressable`\n display: flex;\n flex-direction: row;\n`;\n\nconst CheckboxContainer = styled.View<CheckboxContainerProps>`\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: center;\n\n height: ${({ theme }) => theme.kitt.forms.checkbox.height}px;\n width: ${({ theme }) => theme.kitt.forms.checkbox.width}px;\n position: relative;\n border-radius: ${({ theme }) => theme.kitt.forms.checkbox.borderRadius}px;\n\n ${({ $isChecked, theme }) => {\n const { checkedBackgroundColor, checkedBorderColor, borderColor, borderWidth, backgroundColor } =\n theme.kitt.forms.checkbox;\n if ($isChecked) {\n return css`\n background-color: ${checkedBackgroundColor};\n border: ${`${borderWidth}px solid ${checkedBorderColor}`};\n `;\n }\n return css`\n background-color: ${backgroundColor};\n border: ${`${borderWidth}px solid ${borderColor}`};\n `;\n }}\n\n margin-right: ${({ theme, $hasLabel }) => {\n if (!$hasLabel) return '0px';\n return `${theme.kitt.spacing * 2.5}px;`;\n }};\n`;\n\nexport interface CheckboxProps {\n onChange: (checked: boolean, e: GestureResponderEvent) => void;\n onBlur?: (e: any) => void;\n onFocus?: (e: any) => void;\n checked: boolean;\n hitSlop?: number;\n id?: PressableProps['testID'];\n children?: ReactNode;\n}\n\nexport function Checkbox({\n onChange,\n onBlur,\n onFocus,\n checked,\n hitSlop = 40,\n id,\n children,\n}: CheckboxProps): ReactElement {\n const theme = useKittTheme();\n\n const handlePress = (e: GestureResponderEvent): void => {\n if (onFocus) onFocus(e);\n if (onChange) onChange(!checked, e);\n if (onBlur) onBlur(e);\n };\n\n return (\n <CheckboxAndLabelPressableWrapper\n accessibilityRole=\"checkbox\"\n accessibilityState={{ checked }}\n hitSlop={hitSlop}\n onPress={handlePress}\n >\n <CheckboxContainer $isChecked={checked} $hasLabel={!!children} testID={id}>\n {checked ? (\n <Icon\n align=\"center\"\n color={theme.kitt.forms.checkbox.markColor}\n size={theme.kitt.forms.checkbox.iconSize}\n icon={<CheckboxMark />}\n />\n ) : null}\n </CheckboxContainer>\n\n {children}\n </CheckboxAndLabelPressableWrapper>\n );\n}\n","export type InputFormState = undefined | 'valid' | 'invalid' | 'pending';\n\nexport type InputUIState = NonNullable<InputFormState> | 'default' | 'disabled' | 'hover' | 'focus';\n\ninterface GetInputStateConfig {\n isFocused: boolean;\n isDisabled: boolean;\n formState: InputFormState;\n}\n\nexport function getInputUIState({ isFocused, isDisabled, formState }: GetInputStateConfig): InputUIState {\n if (isDisabled) return 'disabled';\n\n if (isFocused) return 'focus';\n\n if (formState === 'invalid') return 'invalid';\n\n return 'default';\n}\n","import { css } from 'styled-components/native';\nimport { getTypographyTypeConfigKey } from '../typography/Typography';\nimport type { InputUIState } from './utils';\n\nexport interface TextInputMixinProps {\n $state: InputUIState;\n}\n\nexport const styledTextInputMixin = css<TextInputMixinProps>`\n background-color: ${({ theme, $state }) =>\n $state === 'disabled'\n ? theme.kitt.forms.input.states.disabled.backgroundColor\n : theme.kitt.forms.input.states.default.backgroundColor};\n\n border-width: ${({ theme }) => theme.kitt.forms.input.borderWidth}px;\n border-radius: ${({ theme }) => theme.kitt.forms.input.borderRadius}px;\n border-color: ${({ theme, $state }) => theme.kitt.forms.input.states[$state].borderColor};\n\n font-size: ${({ theme }) => {\n const typeConfigKey = getTypographyTypeConfigKey(theme);\n return `${theme.kitt.typography.types.bodies.configs.body[typeConfigKey].fontSize}px`;\n }};\n\n color: ${({ theme, $state }) => theme.kitt.typography.colors[theme.kitt.forms.input.states[$state].color]};\n font-family: ${({ theme }) => theme.kitt.typography.types.bodies.fontFamily.regular};\n`;\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\nimport { Typography } from '../../typography/Typography';\nimport type { TextInputMixinProps } from '../styledTextInputMixin';\nimport { styledTextInputMixin } from '../styledTextInputMixin';\n\ntype PartName = 'year' | 'month' | 'day';\n\nconst StyledTypographyText = styled(Typography.Text)`\n text-align: center;\n`;\n\ninterface ViewInputProps extends TextInputMixinProps {\n $partName?: PartName;\n}\n\nconst ViewInput = styled.View<ViewInputProps>`\n ${styledTextInputMixin}\n padding: ${({ theme }) => theme.kitt.forms.input.padding.default};\n min-height: ${({ theme }) => theme.kitt.forms.input.minHeight}px;\n min-width: ${({ theme, $partName }) => {\n if (!$partName) {\n return undefined;\n }\n\n return `${theme.kitt.forms.datePicker[$partName].minWidth}px`;\n }};\n`;\n\ninterface DatePickerInputPartProps extends TextInputMixinProps {\n disabled?: boolean;\n partName?: 'year' | 'month' | 'day';\n placeholder?: string;\n value?: ReactNode;\n}\n\nexport function DatePickerInputPart({\n $state,\n placeholder,\n value,\n partName,\n disabled,\n}: DatePickerInputPartProps): ReactElement {\n const hasContent = placeholder || value;\n\n return (\n <ViewInput $state={$state} $partName={partName}>\n {hasContent ? (\n <StyledTypographyText color={!value || disabled ? 'black-light' : undefined}>\n {value || placeholder}\n </StyledTypographyText>\n ) : null}\n </ViewInput>\n );\n}\n","import type { ReactElement } from 'react';\nimport styled, { css } from 'styled-components/native';\nimport { getInputUIState } from '../utils';\nimport { DatePickerInputPart } from './DatePickerInputPart';\nimport type { DatePickerInputsProps } from './types';\n\nfunction prefixWithZero(value: number): string {\n return `${value}`.padStart(2, '0');\n}\n\ninterface PartContainerProps {\n $isLast?: boolean;\n $isStretch?: boolean;\n}\n\nconst PartContainer = styled.View<PartContainerProps>`\n margin-right: ${({ theme, $isLast }) => (!$isLast ? `${theme.kitt.spacing * 2}px` : 0)};\n ${({ $isStretch }) =>\n $isStretch\n ? css`\n flex: 0.33;\n flex-grow: 1;\n `\n : undefined};\n`;\n\ninterface DatePickerPressableProps {\n $isStretch?: boolean;\n}\n\nconst DatePickerPressable = styled.Pressable<DatePickerPressableProps>`\n display: flex;\n flex-direction: row;\n ${({ $isStretch }) => {\n if ($isStretch) {\n return css`\n width: 100%;\n `;\n }\n\n return css`\n align-self: baseline;\n `;\n }};\n`;\n\nexport interface DatePickerPlaceholder {\n day: string;\n month: string;\n year: string;\n}\n\nexport function DatePickerInputs({\n state,\n internalForceState,\n isFocused,\n disabled,\n stretch,\n id,\n testID,\n handleModalOpen,\n currentValue,\n placeholder,\n}: DatePickerInputsProps): ReactElement {\n const currentState =\n internalForceState || getInputUIState({ isFocused, isDisabled: Boolean(disabled), formState: state });\n\n const sharedPartProps = {\n disabled,\n $state: currentState,\n };\n\n return (\n <DatePickerPressable\n $isStretch={stretch}\n nativeID={id}\n disabled={disabled}\n testID={testID}\n onPress={handleModalOpen}\n >\n <PartContainer $isStretch={stretch}>\n <DatePickerInputPart\n {...sharedPartProps}\n partName=\"day\"\n value={currentValue ? prefixWithZero(currentValue.getDate()) : undefined}\n placeholder={placeholder?.day}\n />\n </PartContainer>\n\n <PartContainer $isStretch={stretch}>\n <DatePickerInputPart\n {...sharedPartProps}\n partName=\"month\"\n value={currentValue ? prefixWithZero(currentValue.getMonth() + 1) : undefined}\n placeholder={placeholder?.month}\n />\n </PartContainer>\n\n <PartContainer $isLast $isStretch={stretch}>\n <DatePickerInputPart\n {...sharedPartProps}\n partName=\"year\"\n value={currentValue ? currentValue.getFullYear() : undefined}\n placeholder={placeholder?.year}\n />\n </PartContainer>\n </DatePickerPressable>\n );\n}\n","import { DateTimePickerAndroid } from '@react-native-community/datetimepicker';\nimport type { ReactElement } from 'react';\nimport type { Except } from 'type-fest';\nimport { DatePickerInputs } from './DatePickerInputs';\nimport type { DatePickerProps } from './types';\n\ninterface DatePickerAndroidProps\n extends Except<DatePickerProps, 'pickerUITitle' | 'pickerUIValidateButtonLabel' | 'value'> {\n isFocused: boolean;\n setIsFocused: (isFocused: boolean) => void;\n currentValue: Date | undefined;\n setCurrentValue: (value: Date | undefined) => void;\n}\n\nexport function DatePickerAndroid({\n onBlur,\n onFocus,\n pickerDefaultDate,\n pickerUITestID,\n setIsFocused,\n currentValue,\n setCurrentValue,\n onChange,\n isFocused,\n ...props\n}: DatePickerAndroidProps): ReactElement {\n const handleClose = (): void => {\n if (onBlur) onBlur();\n };\n\n const handleModalOpen = (): void => {\n setIsFocused(true);\n if (onFocus) onFocus();\n\n DateTimePickerAndroid.open({\n testID: pickerUITestID,\n value: currentValue || pickerDefaultDate || new Date(Date.now()),\n onChange: (e) => {\n setIsFocused(false);\n const { timestamp } = e.nativeEvent;\n if (timestamp) {\n const date = new Date(timestamp);\n\n setCurrentValue(date);\n onChange(date);\n handleClose();\n }\n },\n onTouchCancel: handleClose,\n });\n };\n\n return (\n <DatePickerInputs handleModalOpen={handleModalOpen} currentValue={currentValue} isFocused={isFocused} {...props} />\n );\n}\n","import type { ReactElement } from 'react';\nimport type { PressableProps } from 'react-native';\nimport { Pressable, StyleSheet } from 'react-native';\nimport styled from 'styled-components/native';\n\ninterface OverlayProps extends Pick<PressableProps, 'onPress'> {}\n\n// Don't use styled.Pressable here - babel-plugin-styled-components-react-native-web only supports tagged templates\nconst OverlayPressable = styled(Pressable)(({ theme }) => ({\n ...StyleSheet.absoluteFillObject,\n backgroundColor: theme.kitt.colors.overlay.dark,\n}));\n\nexport function Overlay({ onPress }: OverlayProps): ReactElement {\n return <OverlayPressable accessibilityRole=\"none\" onPress={onPress} />;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { ScrollView } from 'react-native';\nimport styled from 'styled-components/native';\n\nconst BodyView = styled.View`\n padding: ${({ theme }) => theme.kitt.spacing * 6}px ${({ theme }) => theme.kitt.spacing * 4}px;\n`;\n\nexport interface BodyProps {\n children: NonNullable<ReactNode>;\n}\n\nexport function ModalBody({ children }: BodyProps): ReactElement {\n return (\n <ScrollView>\n <BodyView>{children}</BodyView>\n </ScrollView>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\n\nexport interface FooterProps {\n children: NonNullable<ReactNode>;\n}\n\nconst FooterView = styled.View`\n flex: 0 0 auto;\n padding: ${({ theme }) => theme.kitt.spacing * 4}px;\n border-top-width: 1px;\n border-top-color: ${({ theme }) => theme.kitt.colors.separator};\n`;\n\nexport function ModalFooter({ children }: FooterProps): ReactElement {\n return <FooterView>{children}</FooterView>;\n}\n","import type { ComponentProps, ElementType, ReactElement, ReactNode } from 'react';\nimport { Platform } from 'react-native';\n\nexport interface StyleWebWrapperProps<T extends ElementType> {\n as: T;\n children: ReactNode;\n}\n\nexport function StyleWebWrapper<T extends ElementType = 'div'>({\n as,\n children,\n ...props\n}: StyleWebWrapperProps<T> & ComponentProps<T>): ReactElement {\n if (Platform.OS !== 'web') return children as ReactElement;\n const Component: T = as || ('div' as T); // as or default to div. If as is undefined, T is div but typescript is not sure\n return <Component {...(props as any)}>{children}</Component>;\n}\n","import type { ComponentType, ForwardRefExoticComponent, PropsWithoutRef, RefAttributes } from 'react';\nimport { forwardRef } from 'react';\nimport { useTheme } from 'styled-components/native';\nimport type { DefaultTheme } from 'styled-components/native';\nimport type { Except } from 'type-fest';\n\n// type $Without<T, K extends keyof any> = T extends any ? Pick<T, Exclude<keyof T, K>> : never;\n// type $DeepPartial<T> = { [P in keyof T]?: $DeepPartial<T[P]> };\n\n// export function withTheme<Props extends { theme: DefaultTheme }, C>(\n// WrappedComponent: ComponentType<Props> & C,\n// ): ComponentType<SetOptional<Props, 'theme'>> & hoistNonReactStatics.NonReactStatics<typeof WrappedComponent> {\n// return function ThemedComponent(props) {\n// const theme = useTheme();\n\n// return (<WrappedComponent theme={theme} {...(props as any)} />) as any;\n// };\n// }\n\nexport function withTheme<Props extends { theme: DefaultTheme }, T>(\n WrappedComponent: ComponentType<Props>,\n): ForwardRefExoticComponent<PropsWithoutRef<Except<Props, 'theme'>> & RefAttributes<T>> {\n // eslint-disable-next-line prefer-arrow-callback\n return forwardRef<T, Except<Props, 'theme'>>(function ThemedComponent(props, ref) {\n const theme = useTheme();\n\n return <WrappedComponent ref={ref} theme={theme} {...(props as any)} />;\n });\n}\n","import { styled as styledLinaria } from '@linaria/react';\nimport type { ReactElement } from 'react';\nimport type { PressableProps } from 'react-native';\nimport { Platform } from 'react-native';\nimport type { DefaultTheme } from 'styled-components/native';\nimport styled from 'styled-components/native';\nimport { theme as kittTheme } from '../themes/default';\nimport { StyleWebWrapper } from '../utils/StyleWebWrapper';\nimport { withTheme } from '../utils/withTheme';\nimport type { IconButtonContentProps } from './IconButton';\n\ninterface PressableIconButtonWebWrapperProps {\n theme: DefaultTheme;\n $isWhite?: boolean;\n $isDisabled?: boolean;\n}\n\nconst PressableIconButtonWebWrapper = withTheme(styledLinaria.div<PressableIconButtonWebWrapperProps>`\n & > *:hover,\n .kitt-hover & > * {\n @media (hover: none) and (pointer: coarse) {\n transform: scale(${({ theme, $isDisabled }) => ($isDisabled ? 1 : theme.kitt.iconButton.scale.base.hover)});\n }\n\n @media (${kittTheme.breakpoints.min.mediumBreakpoint}) {\n transform: scale(${({ theme, $isDisabled }) => ($isDisabled ? 1 : theme.kitt.iconButton.scale.medium.hover)});\n }\n }\n\n & > *:active,\n .kitt-active & > * {\n transform: scale(${({ theme, $isDisabled }) => ($isDisabled ? 1 : theme.kitt.iconButton.scale.base.active)});\n }\n\n &,\n & > [data-focusvisible-polyfill] {\n outline: none;\n }\n\n & > *:hover,\n .kitt-hover & > *,\n & > *:focus,\n .kitt-focus & > *,\n & > [data-focusvisible-polyfill],\n & > *:active,\n .kitt-active & > * {\n background-color: ${({ theme, $isWhite, $isDisabled }) => {\n if ($isDisabled) return theme.kitt.iconButton.disabled.backgroundColor;\n\n const { white, default: defaultIconButton } = theme.kitt.iconButton;\n\n if ($isWhite) return white.pressedBackgroundColor;\n return defaultIconButton.pressedBackgroundColor;\n }};\n }\n`);\n\nconst StyledPressableIconButton = styled.Pressable`\n border-radius: ${({ theme }) => theme.kitt.iconButton.borderRadius}px;\n width: ${({ theme }) => theme.kitt.iconButton.width}px;\n height: ${({ theme }) => theme.kitt.iconButton.height}px;\n align-items: center;\n justify-content: center;\n position: relative;\n background-color: transparent;\n\n ${({ theme, disabled }) => {\n const { iconButton } = theme.kitt;\n\n if (Platform.OS !== 'web') {\n return undefined;\n }\n\n const { transition } = iconButton;\n\n if (disabled) {\n return `\n background-color: ${iconButton.disabled.backgroundColor};\n `;\n }\n\n return `\n transition: ${transition.property} ${transition.duration} ${transition.timingFunction};\n `;\n }};\n`;\n\nexport interface PressableIconButtonProps extends PressableProps {\n color: IconButtonContentProps['color'];\n}\n\nexport function PressableIconButton({ color, disabled, ...props }: PressableIconButtonProps): ReactElement {\n return (\n <StyleWebWrapper as={PressableIconButtonWebWrapper} $isWhite={color === 'white'} $isDisabled={Boolean(disabled)}>\n <StyledPressableIconButton {...props} disabled={disabled} />\n </StyleWebWrapper>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport Animated, { useAnimatedStyle, useSharedValue, withSpring } from 'react-native-reanimated';\nimport styled, { useTheme } from 'styled-components/native';\nimport type { IconButtonContentProps } from './IconButton';\nimport type { PressableIconButtonProps } from './PressableIconButton';\nimport { PressableIconButton } from './PressableIconButton';\n\nexport interface PressableAnimatedContainerProps {\n children: NonNullable<ReactNode>;\n disabled?: boolean;\n color: IconButtonContentProps['color'];\n testID?: IconButtonContentProps['testID'];\n accessibilityLabel?: IconButtonContentProps['accessibilityLabel'];\n accessibilityRole?: IconButtonContentProps['accessibilityRole'];\n onPress: NonNullable<PressableIconButtonProps['onPress']>;\n}\n\ninterface AnimatedIconButtonBackgroundProps {\n color: IconButtonContentProps['color'];\n disabled?: boolean;\n}\n\nconst AnimatedIconButtonBackground = styled(Animated.View)<AnimatedIconButtonBackgroundProps>`\n background-color: ${({ theme, color, disabled }) => {\n const { iconButton } = theme.kitt;\n if (disabled) return iconButton.disabled.backgroundColor;\n\n if (color === 'white') return iconButton.white.pressedBackgroundColor;\n\n return iconButton.default.pressedBackgroundColor;\n }};\n border-radius: ${({ theme }) => theme.kitt.iconButton.borderRadius}px;\n width: ${({ theme }) => theme.kitt.iconButton.width}px;\n height: ${({ theme }) => theme.kitt.iconButton.height}px;\n position: absolute;\n bottom: 0;\n left: 0;\n`;\n\nconst AnimatedViewContainer = styled(Animated.View)`\n position: relative;\n align-items: center;\n justify-content: center;\n width: 100%;\n height: 100%;\n`;\n\nexport function PressableAnimatedContainer({\n disabled,\n color = 'black',\n testID,\n accessibilityRole = 'button',\n accessibilityLabel,\n children,\n onPress,\n}: PressableAnimatedContainerProps): ReactElement {\n const theme = useTheme();\n const pressed = useSharedValue(false);\n\n const opacityStyles = useAnimatedStyle(() => {\n return {\n opacity: withSpring(pressed.value ? 1 : 0),\n };\n });\n\n const scaleStyles = useAnimatedStyle(() => {\n return {\n transform: [\n {\n scale: withSpring(\n pressed.value ? theme.kitt.iconButton.scale.base.active : theme.kitt.iconButton.scale.base.default,\n ),\n },\n ],\n };\n });\n\n return (\n <PressableIconButton\n accessibilityRole={accessibilityRole}\n disabled={disabled}\n color={color}\n testID={testID}\n accessibilityLabel={accessibilityLabel}\n onPress={onPress}\n onPressIn={() => {\n pressed.value = true;\n }}\n onPressOut={() => {\n pressed.value = false;\n }}\n >\n <AnimatedViewContainer style={disabled ? [{ transform: [{ scale: 1 }] }] : [scaleStyles]}>\n <AnimatedIconButtonBackground\n disabled={disabled}\n color={color}\n style={disabled ? [{ opacity: 1 }] : [opacityStyles]}\n />\n {children}\n </AnimatedViewContainer>\n </PressableIconButton>\n );\n}\n","import type { ReactElement } from 'react';\nimport type { AccessibilityRole } from 'react-native';\nimport styled from 'styled-components/native';\nimport { TypographyIcon } from '../typography/TypographyIcon';\nimport { PressableAnimatedContainer } from './PressableAnimatedContainer';\n\ninterface IconButtonContentBorderProps {\n disabled?: boolean;\n}\n\nconst IconButtonContentBorder = styled.View<IconButtonContentBorderProps>`\n border: ${({ theme }) => `${theme.kitt.iconButton.borderWidth}px solid`};\n border-color: ${({ theme, disabled }) =>\n disabled ? theme.kitt.iconButton.disabled.borderColor : theme.kitt.iconButton.borderColor};\n width: ${({ theme }) => theme.kitt.iconButton.width - theme.kitt.iconButton.borderWidth}px;\n height: ${({ theme }) => theme.kitt.iconButton.height - theme.kitt.iconButton.borderWidth}px;\n align-items: center;\n justify-content: center;\n border-radius: ${({ theme }) => theme.kitt.iconButton.borderRadius}px;\n`;\nexport interface IconButtonContentProps {\n icon: NonNullable<ReactElement>;\n color?: 'black' | 'white';\n disabled?: boolean;\n testID?: string;\n accessibilityLabel?: string;\n accessibilityRole?: AccessibilityRole;\n}\n\nfunction IconButtonContent({ disabled, color, icon }: IconButtonContentProps): ReactElement {\n return (\n <IconButtonContentBorder disabled={disabled}>\n <TypographyIcon color={disabled ? 'black-light' : color} icon={icon} />\n </IconButtonContentBorder>\n );\n}\n\nexport interface IconButtonProps extends IconButtonContentProps {\n onPress: () => void;\n}\n\nexport function IconButton({\n icon,\n color,\n disabled,\n testID,\n accessibilityLabel,\n accessibilityRole,\n onPress,\n}: IconButtonProps): ReactElement {\n return (\n <PressableAnimatedContainer\n color={color}\n disabled={disabled}\n testID={testID}\n accessibilityLabel={accessibilityLabel}\n accessibilityRole={accessibilityRole}\n onPress={onPress}\n >\n <IconButtonContent disabled={disabled} color={color} icon={icon} />\n </PressableAnimatedContainer>\n );\n}\n","import { createContext } from 'react';\n\nexport const OnCloseContext = createContext<() => void>(() => {});\n","import { XIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement, ReactNode } from 'react';\nimport { useContext } from 'react';\nimport styled from 'styled-components/native';\nimport { IconButton } from '../IconButton/IconButton';\nimport { OnCloseContext } from './OnCloseContext';\n\nexport interface HeaderProps {\n children: NonNullable<ReactNode>;\n left?: ReactNode;\n right?: ReactNode;\n}\n\nconst HeaderView = styled.View`\n position: relative;\n padding: ${({ theme }) => theme.kitt.spacing * 2}px;\n display: flex;\n flex: 0 0 auto;\n flex-direction: row;\n justify-content: space-between;\n align-items: center;\n border-bottom-width: 1px;\n border-bottom-color: ${({ theme }) => theme.kitt.colors.separator};\n min-height: 57px;\n`;\n\nconst LeftIconView = styled.View`\n align-self: flex-start;\n margin-right: ${({ theme }) => theme.kitt.spacing * 2}px;\n`;\n\nconst RightIconView = styled.View`\n align-self: flex-start;\n margin-left: ${({ theme }) => theme.kitt.spacing * 2}px;\n`;\n\ninterface TitleViewProps {\n isIconLeft?: boolean;\n}\n\nconst TitleView = styled.View<TitleViewProps>`\n padding-left: ${({ theme, isIconLeft }) => (isIconLeft ? 0 : theme.kitt.spacing * 2)}px;\n flex-shrink: 1;\n`;\n\nexport function ModalHeader({ left, right, children }: HeaderProps): ReactElement {\n const onClose = useContext(OnCloseContext);\n\n const isIconLeft = !!left;\n\n return (\n <HeaderView>\n {isIconLeft && <LeftIconView>{left}</LeftIconView>}\n\n <TitleView isIconLeft={isIconLeft}>{children}</TitleView>\n\n {right !== undefined ? (\n right\n ) : (\n <RightIconView>\n <IconButton icon={<XIcon />} onPress={onClose} />\n </RightIconView>\n )}\n </HeaderView>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { Modal as NativeModal } from 'react-native';\nimport styled from 'styled-components/native';\nimport { Overlay } from '../Overlay/Overlay';\nimport { ModalBody } from './Body';\nimport { ModalFooter } from './Footer';\nimport { ModalHeader } from './Header';\nimport { OnCloseContext } from './OnCloseContext';\n\nexport interface ModalProps {\n visible: boolean;\n children: ReactNode;\n onClose: () => void;\n onEntered?: () => void;\n onExited?: () => void;\n}\n\nconst ModalView = styled.View`\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n\n display: flex;\n align-items: center;\n justify-content: center;\n padding: ${({ theme }) => theme.kitt.spacing * 20}px ${({ theme }) => theme.kitt.spacing * 4}px;\n`;\n\nconst ContentView = styled.View`\n position: relative;\n display: flex;\n flex-direction: column;\n max-height: 100%;\n max-width: 540px;\n height: auto;\n width: 100%;\n border-radius: ${({ theme }) => theme.kitt.card.borderRadius}px;\n background-color: ${({ theme }) => theme.kitt.colors.uiBackgroundLight};\n`;\n\nexport function Modal({ visible, children, onClose, onEntered, onExited }: ModalProps): ReactElement {\n return (\n <OnCloseContext.Provider value={onClose}>\n <NativeModal\n transparent\n animationType=\"fade\"\n visible={visible}\n onShow={onEntered}\n onDismiss={onExited}\n onRequestClose={onClose}\n >\n <ModalView>\n <Overlay onPress={onClose} />\n\n <ContentView>{children}</ContentView>\n </ModalView>\n </NativeModal>\n </OnCloseContext.Provider>\n );\n}\n\nModal.Header = ModalHeader;\nModal.Body = ModalBody;\nModal.Footer = ModalFooter;\n","import DateTimePicker from '@react-native-community/datetimepicker';\nimport type { DateTimePickerEvent } from '@react-native-community/datetimepicker';\nimport type { ComponentProps, ReactElement } from 'react';\nimport { Platform } from 'react-native';\nimport { useTheme } from 'styled-components/native';\n\ntype DateTimePickerProps = ComponentProps<typeof DateTimePicker>;\n\nfunction getDatePickerDisplayMode(): DateTimePickerProps['display'] {\n if (Platform.OS === 'android') return 'calendar';\n\n if (Platform.OS === 'ios') return 'spinner';\n\n return 'default';\n}\n\nexport interface PlatformDateTimePickerProps {\n value?: Date;\n defaultDate?: Date;\n maximumDate?: DateTimePickerProps['maximumDate'];\n minimuDate?: DateTimePickerProps['minimumDate'];\n testID?: DateTimePickerProps['testID'];\n onChange: (newDate?: Date) => void;\n}\n\nexport function PlatformDateTimePicker({\n value,\n defaultDate = new Date(),\n maximumDate,\n minimuDate,\n testID,\n onChange,\n}: PlatformDateTimePickerProps): ReactElement {\n const theme = useTheme();\n const displayMode = getDatePickerDisplayMode();\n\n const iosProps = Platform.OS === 'ios' ? { textColor: theme.kitt.colors.primary } : {};\n\n return (\n <DateTimePicker\n is24Hour\n testID={testID}\n value={value || defaultDate}\n mode=\"date\"\n maximumDate={maximumDate}\n minimumDate={minimuDate}\n display={displayMode}\n {...iosProps}\n onChange={(_event: DateTimePickerEvent, date?: Date | undefined) => onChange(date)}\n />\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { useState } from 'react';\nimport { FormattedMessage } from 'react-intl';\nimport { Text } from 'react-native';\nimport { Button } from '../../Button/Button';\nimport { Modal } from '../../Modal/Modal';\nimport { Typography } from '../../typography/Typography';\nimport type { PlatformDateTimePickerProps } from './PlatformDateTimePicker';\nimport { PlatformDateTimePicker } from './PlatformDateTimePicker';\n\ninterface ModalTitleProps {\n children: NonNullable<ReactNode>;\n}\n\nfunction ModalTitle({ children }: ModalTitleProps): ReactElement {\n return (\n <Modal.Header>\n <Typography.Text base=\"body\" variant=\"bold\">\n {children}\n </Typography.Text>\n </Modal.Header>\n );\n}\n\ninterface ModalPlatformDateTimePickerProps extends PlatformDateTimePickerProps {\n title?: ReactNode;\n isVisible?: boolean;\n validateButtonLabel?: string;\n onClose: () => void;\n}\n\nexport function ModalPlatformDateTimePicker({\n title,\n isVisible,\n value,\n validateButtonLabel,\n onClose,\n onChange,\n ...props\n}: ModalPlatformDateTimePickerProps): ReactElement {\n const [currentValue, setCurrentValue] = useState(value);\n\n // Prevent unsynced value between the modal and its parent state\n const handleClose = (): void => {\n setCurrentValue(value);\n onClose();\n };\n\n const handleSubmit = (): void => {\n onChange(currentValue);\n };\n\n const handleChange = (newDate?: Date): void => {\n setCurrentValue((prev) => {\n return newDate || prev;\n });\n };\n\n return (\n <Modal visible={Boolean(isVisible)} onClose={handleClose}>\n {isVisible ? (\n <>\n {title ? <ModalTitle>{title}</ModalTitle> : null}\n\n <Modal.Body>\n <PlatformDateTimePicker {...props} value={currentValue} onChange={handleChange} />\n </Modal.Body>\n\n <Modal.Footer>\n <Button stretch type=\"primary\" onPress={handleSubmit}>\n {validateButtonLabel ? (\n <Text>{validateButtonLabel}</Text>\n ) : (\n <FormattedMessage id=\"kitt-universal.ModalDateTimePicker.confirm\" defaultMessage=\"Valider\" />\n )}\n </Button>\n </Modal.Footer>\n </>\n ) : null}\n </Modal>\n );\n}\n","import type { ReactElement } from 'react';\nimport { useState } from 'react';\nimport { Platform } from 'react-native';\nimport { DatePickerAndroid } from './DatePickerAndroid';\nimport { DatePickerInputs } from './DatePickerInputs';\nimport { ModalPlatformDateTimePicker } from './ModalPlatformDateTimePicker';\nimport type { DatePickerProps } from './types';\n\nexport function DatePicker({\n value,\n pickerUITestID,\n pickerUITitle,\n pickerUIValidateButtonLabel,\n onChange,\n onFocus,\n onBlur,\n pickerDefaultDate,\n ...props\n}: DatePickerProps): ReactElement {\n const [isPickerUIVisible, setIsPickerUIVisible] = useState(false);\n const [isFocused, setIsFocused] = useState(false);\n const [currentValue, setCurrentValue] = useState<Date | undefined>(value);\n\n if (Platform.OS === 'android') {\n return (\n <DatePickerAndroid\n pickerDefaultDate={pickerDefaultDate}\n pickerUITestID={pickerUITestID}\n currentValue={currentValue}\n setCurrentValue={setCurrentValue}\n isFocused={isFocused}\n setIsFocused={setIsFocused}\n onChange={onChange}\n onBlur={onBlur}\n {...props}\n />\n );\n }\n\n const handleModalOpen = (): void => {\n if (onFocus) onFocus();\n\n setIsPickerUIVisible(true);\n\n setIsFocused(true);\n };\n\n const handleModalClose = (): void => {\n if (onBlur) onBlur();\n\n setIsPickerUIVisible(false);\n\n setIsFocused(false);\n };\n\n const handleChange = (newDate?: Date): void => {\n setCurrentValue(newDate);\n\n onChange(newDate);\n\n handleModalClose();\n };\n return (\n <>\n <DatePickerInputs\n handleModalOpen={handleModalOpen}\n currentValue={currentValue}\n isFocused={isFocused}\n {...props}\n />\n <ModalPlatformDateTimePicker\n testID={pickerUITestID}\n value={currentValue}\n isVisible={isPickerUIVisible}\n title={pickerUITitle}\n validateButtonLabel={pickerUIValidateButtonLabel}\n defaultDate={pickerDefaultDate}\n onClose={handleModalClose}\n onChange={handleChange}\n />\n </>\n );\n}\n","import type { ReactNode } from 'react';\nimport styled from 'styled-components/native';\n\nexport interface InputTextContainerProps {\n children: NonNullable<ReactNode>;\n $isDisabled?: boolean;\n}\n\nexport const InputTextContainer = styled.View<InputTextContainerProps>`\n position: relative;\n`;\n","import type { ReactElement, ReactNode } from 'react';\nimport { forwardRef, useState } from 'react';\nimport type { TextInput as RNTextInput, TextInputProps as RNTextInputProps } from 'react-native';\nimport { Platform, TextInput } from 'react-native';\nimport styled, { useTheme } from 'styled-components/native';\nimport { getTypographyTypeConfigKey } from '../../typography/Typography';\nimport type { TextInputMixinProps } from '../styledTextInputMixin';\nimport { styledTextInputMixin } from '../styledTextInputMixin';\nimport type { InputFormState, InputUIState } from '../utils';\nimport { getInputUIState } from '../utils';\nimport { InputTextContainer } from './InputTextContainer';\n\nexport interface InputTextProps extends Exclude<RNTextInputProps, 'nativeID'> {\n id?: string;\n name?: string;\n disabled?: boolean;\n minHeight?: number;\n state?: InputFormState;\n right?: ReactNode;\n /** @internal */\n internalForceState?: InputUIState;\n}\n\ninterface StyledTextInputProps extends TextInputMixinProps {\n $minHeight: number;\n}\n\nconst StyledTextInput = styled(TextInput)<StyledTextInputProps>`\n /* FIXME: text input is not vertically centered on iOS because of bigger line-height */\n ${styledTextInputMixin}\n padding: ${({ theme, multiline }) => {\n if (!multiline && Platform.OS === 'ios') {\n return theme.kitt.forms.input.padding.iOSSingleLine;\n }\n\n return theme.kitt.forms.input.padding.default;\n }};\n line-height: ${({ theme, multiline }) => {\n if (!multiline && Platform.OS === 'ios') return 0;\n const typeConfigKey = getTypographyTypeConfigKey(theme);\n return `${theme.kitt.typography.types.bodies.configs.body[typeConfigKey].lineHeight}px`;\n }};\n width: 100%;\n min-height: ${({ $minHeight }) => $minHeight}px;\n`;\n\nconst RightInputContainer = styled.View`\n position: absolute;\n right: 0;\n top: 0;\n bottom: 0;\n justify-content: center;\n padding: 10px;\n`;\n\nexport const InputText = forwardRef<RNTextInput, InputTextProps>(\n (\n {\n id,\n right,\n minHeight = 0,\n state: formState,\n internalForceState,\n disabled = false,\n autoCorrect = true,\n textContentType = 'none',\n autoCompleteType = 'off',\n keyboardType = 'default',\n multiline,\n onSubmitEditing,\n onFocus,\n onBlur,\n ...props\n }: InputTextProps,\n ref,\n ): ReactElement => {\n const theme = useTheme();\n const [isFocused, setIsFocused] = useState<boolean>(false);\n\n const state = internalForceState || getInputUIState({ isFocused, isDisabled: disabled, formState });\n\n return (\n <InputTextContainer $isDisabled={disabled}>\n <StyledTextInput\n ref={ref}\n multiline={multiline}\n nativeID={id}\n editable={!disabled}\n keyboardType={keyboardType}\n autoCompleteType={autoCompleteType}\n autoCorrect={autoCorrect}\n $minHeight={minHeight}\n textContentType={textContentType}\n placeholderTextColor={theme.kitt.forms.input.color.placeholder}\n selectionColor={theme.kitt.forms.input.color.selection}\n {...props}\n $state={state}\n onFocus={(e) => {\n setIsFocused(true);\n if (onFocus) onFocus(e);\n }}\n onBlur={(e) => {\n setIsFocused(false);\n if (onBlur) onBlur(e);\n }}\n onSubmitEditing={multiline ? () => null : onSubmitEditing}\n />\n {right ? <RightInputContainer>{right}</RightInputContainer> : null}\n </InputTextContainer>\n );\n },\n);\n","import type { ReactElement } from 'react';\nimport type { Except } from 'type-fest';\nimport type { InputTextProps } from '../InputText/InputText';\nimport { InputText } from '../InputText/InputText';\n\nexport interface InputEmailProps\n extends Except<InputTextProps, 'autoCompleteType' | 'keyboardType' | 'textContentType' | 'autoCapitalize'> {}\n\nexport function InputEmail(props: InputEmailProps): ReactElement {\n return (\n <InputText\n autoCompleteType=\"email\"\n keyboardType=\"email-address\"\n textContentType=\"emailAddress\"\n autoCapitalize=\"none\"\n {...props}\n />\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport type { TypographyColor, TypographyProps } from '../../typography/Typography';\nimport { Typography } from '../../typography/Typography';\nimport type { InputFormState } from '../utils';\n\nexport interface InputFeedbackProps {\n state?: InputFormState;\n testID?: TypographyProps['testID'];\n children: NonNullable<ReactNode>;\n}\n\nconst getColorFromState = (state?: InputFormState): TypographyColor => {\n switch (state) {\n case 'invalid':\n return 'danger';\n case 'valid':\n default:\n return 'black-light';\n }\n};\n\nexport function InputFeedback({ state, testID, children }: InputFeedbackProps): ReactElement {\n return (\n <Typography.Text base=\"body-small\" color={getColorFromState(state)} testID={testID}>\n {children}\n </Typography.Text>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\nimport { KittBreakpoints } from '../../KittBreakpoints';\n\nconst FieldContainer = styled.View`\n padding: 5px 0 10px;\n`;\n\nconst FeedbackContainer = styled.View`\n ${({ theme }) =>\n theme.responsive.ifWindowSizeMatches({ minWidth: KittBreakpoints.SMALL }, 'padding-top: 10px', 'padding-top: 5px')};\n`;\n\nconst FieldLabelContainer = styled.View`\n flex-direction: row;\n align-items: center;\n padding-bottom: ${({ theme }) => theme.kitt.forms.inputField.labelContainerPaddingBottom}px;\n`;\n\nconst LabelContainer = styled.View`\n margin-right: ${({ theme }) => theme.kitt.forms.inputField.iconMarginLeft}px;\n`;\n\nexport interface InputFieldProps {\n label?: ReactNode;\n labelFeedback?: ReactNode;\n input: NonNullable<ReactNode>;\n feedback?: ReactNode;\n}\n\nexport function InputField({ label, labelFeedback, input, feedback }: InputFieldProps): ReactElement {\n return (\n <FieldContainer>\n {label ? (\n <FieldLabelContainer>\n <LabelContainer>{label}</LabelContainer>\n {labelFeedback}\n </FieldLabelContainer>\n ) : null}\n {input}\n {feedback ? <FeedbackContainer>{feedback}</FeedbackContainer> : null}\n </FieldContainer>\n );\n}\n","import type { ReactElement } from 'react';\nimport { useTheme } from 'styled-components/native';\nimport type { InputFormState } from 'forms/utils';\nimport type { TypographyIconProps } from '../../typography/TypographyIcon';\nimport { TypographyIcon } from '../../typography/TypographyIcon';\n\nfunction getIconColor(state?: InputFormState, disabled?: boolean): TypographyIconProps['color'] {\n if (disabled) return 'black-light';\n\n switch (state) {\n case 'invalid':\n return 'danger';\n case 'valid':\n return 'success';\n default:\n return undefined;\n }\n}\n\nexport interface InputIconProps {\n icon: NonNullable<ReactElement>;\n disabled?: boolean;\n state?: InputFormState;\n}\n\nexport function InputIcon({ icon, state, disabled }: InputIconProps): ReactElement {\n const theme = useTheme();\n\n const color = getIconColor(state, disabled);\n\n return <TypographyIcon color={color} icon={icon} size={theme.kitt.forms.input.icon.size} />;\n}\n","import type { ReactElement } from 'react';\nimport type { PressableProps } from 'react-native';\nimport { Pressable } from 'react-native';\n\nexport interface InputPressableProps extends PressableProps {}\n\nexport function InputPressable({ ...props }: InputPressableProps): ReactElement {\n return <Pressable {...props} />;\n}\n","import { EyeIcon, EyeOffIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement } from 'react';\nimport { useState } from 'react';\nimport { InputIcon } from '../InputIcon/InputIcon';\nimport { InputPressable } from '../InputPressable/InputPressable';\nimport type { InputTextProps } from '../InputText/InputText';\nimport { InputText } from '../InputText/InputText';\n\nexport interface InputPasswordProps extends InputTextProps {\n isPasswordDefaultVisible?: boolean;\n}\n\nexport function InputPassword({ isPasswordDefaultVisible, right, ...props }: InputPasswordProps): ReactElement {\n const [isVisible, setIsVisible] = useState(Boolean(isPasswordDefaultVisible));\n\n return (\n <InputText\n {...props}\n textContentType=\"password\"\n autoCompleteType=\"password\"\n autoCorrect={false}\n secureTextEntry={!isVisible}\n right={\n right || (\n <InputPressable accessibilityRole=\"button\" onPress={() => setIsVisible((prev) => !prev)}>\n <InputIcon icon={isVisible ? <EyeOffIcon /> : <EyeIcon />} />\n </InputPressable>\n )\n }\n />\n );\n}\n","import type { ReactElement } from 'react';\nimport type { Except } from 'type-fest';\nimport type { InputTextProps } from '../InputText/InputText';\nimport { InputText } from '../InputText/InputText';\n\nexport interface InputPhoneProps\n extends Except<InputTextProps, 'autoCompleteType' | 'keyboardType' | 'textContentType'> {}\n\nexport function InputPhone(props: InputPhoneProps): ReactElement {\n return <InputText {...props} autoCompleteType=\"tel\" keyboardType=\"number-pad\" textContentType=\"telephoneNumber\" />;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { View } from 'react-native';\nimport styled from 'styled-components/native';\nimport type { TypographyColor } from '../../typography/Typography';\nimport { Typography } from '../../typography/Typography';\nimport { TypographyIcon } from '../../typography/TypographyIcon';\nimport { useKittTheme } from '../../useKittTheme';\n\ntype InputTagType = 'success' | 'danger';\n\nconst getTypographyColor = (type: InputTagType | undefined): TypographyColor => (type ? 'white' : 'black');\n\ninterface InputTagContainerProps {\n type?: InputTagType;\n}\n\nconst InputTagContainer = styled(View)<InputTagContainerProps>`\n align-items: center;\n justify-content: center;\n flex-direction: row;\n align-self: flex-start;\n overflow: hidden;\n padding-horizontal: ${({ theme }) => theme.kitt.spacing * 2}px;\n\n background-color: ${({ theme, type }) => {\n if (type === 'success') {\n return theme.kitt.forms.inputTag.success.backgroundColor;\n }\n if (type === 'danger') {\n return theme.kitt.forms.inputTag.danger.backgroundColor;\n }\n\n return theme.kitt.forms.inputTag.default.backgroundColor;\n }};\n border-radius: ${({ theme }) => theme.kitt.forms.inputTag.borderRadius}px;\n`;\n\nconst IconContainer = styled(View)`\n margin-right: ${({ theme }) => theme.kitt.spacing}px;\n`;\n\nexport interface InputTagProps {\n type?: InputTagType;\n children: ReactNode;\n icon?: ReactElement;\n}\n\nexport function InputTag({ children, type, icon }: InputTagProps): ReactElement {\n const typographyColor = getTypographyColor(type);\n const theme = useKittTheme();\n\n return (\n <InputTagContainer type={type}>\n {icon && (\n <IconContainer>\n <TypographyIcon icon={icon} size={theme.kitt.forms.inputTag.iconSize} color={typographyColor} />\n </IconContainer>\n )}\n <Typography.Text base=\"body-small\" color={typographyColor}>\n {children}\n </Typography.Text>\n </InputTagContainer>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { Platform } from 'react-native';\nimport { Typography } from '../../typography/Typography';\n\nexport interface LabelProps {\n htmlFor: string;\n children: NonNullable<ReactNode>;\n}\n\nexport function Label({ htmlFor, children }: LabelProps): ReactElement {\n return (\n <Typography.Text base=\"body\">\n {Platform.OS === 'web' ? <label htmlFor={htmlFor}>{children}</label> : children}\n </Typography.Text>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport type { PressableProps } from 'react-native';\nimport styled from 'styled-components/native';\nimport { Typography } from '../../typography/Typography';\n\nexport interface RadioProps {\n id: string;\n name: string;\n checked?: boolean;\n disabled?: boolean;\n right?: boolean;\n children?: NonNullable<ReactNode>;\n value: string;\n onChange: (newValue: string) => void;\n}\n\ninterface OuterRadioProps {\n disabled: boolean;\n}\n\nconst OuterRadio = styled.View<OuterRadioProps>`\n background-color: ${({ theme, disabled }) =>\n theme.kitt.forms.radio[disabled ? 'disabled' : 'unchecked'].backgroundColor};\n width: ${({ theme }) => theme.kitt.forms.radio.size}px;\n height: ${({ theme }) => theme.kitt.forms.radio.size}px;\n border-radius: ${({ theme }) => theme.kitt.forms.radio.size / 2}px;\n border-width: ${({ theme }) => theme.kitt.forms.radio.unchecked.borderWidth}px;\n border-color: ${({ theme, disabled }) => theme.kitt.forms.radio[disabled ? 'disabled' : 'unchecked'].borderColor};\n`;\nconst SelectedOuterRadio = styled.View`\n background-color: ${({ theme }) => theme.kitt.forms.radio.checked.backgroundColor};\n width: ${({ theme }) => theme.kitt.forms.radio.size}px;\n height: ${({ theme }) => theme.kitt.forms.radio.size}px;\n border-radius: ${({ theme }) => theme.kitt.forms.radio.size / 2}px;\n justify-content: center;\n align-items: center;\n`;\nconst SelectedInnerRadio = styled.View`\n background-color: ${({ theme }) => theme.kitt.forms.radio.checked.innerBackgroundColor};\n width: ${({ theme }) => theme.kitt.forms.radio.checked.innerSize}px;\n height: ${({ theme }) => theme.kitt.forms.radio.checked.innerSize}px;\n border-radius: ${({ theme }) => theme.kitt.forms.radio.checked.innerSize / 2}px;\n`;\nconst Container = styled.Pressable`\n flex-direction: row;\n align-items: center;\n`;\n\nconst Text = styled(Typography.Text)`\n margin-left: ${({ theme }) => theme.kitt.spacing * 2}px;\n`;\n\nexport function Radio({ id, checked, onChange, value, disabled = false, children }: RadioProps): ReactElement {\n const handlePress: PressableProps['onPress'] = () => {\n onChange(value);\n };\n\n return (\n <Container\n nativeID={id}\n disabled={disabled}\n accessibilityRole=\"radio\"\n aria-checked={checked}\n focusable={checked && !disabled}\n onPress={handlePress}\n >\n {checked && !disabled ? (\n <SelectedOuterRadio>\n <SelectedInnerRadio />\n </SelectedOuterRadio>\n ) : (\n <OuterRadio disabled={disabled} />\n )}\n\n <Text base=\"body\" color={disabled ? 'black-light' : 'black'}>\n {children}\n </Text>\n </Container>\n );\n}\n","import type { ReactElement } from 'react';\nimport { useTheme } from 'styled-components/native';\nimport type { InputTextProps } from '../InputText/InputText';\nimport { InputText } from '../InputText/InputText';\n\nexport interface TextAreaProps extends InputTextProps {}\n\nexport function TextArea({ ...props }: TextAreaProps): ReactElement {\n const theme = useTheme();\n\n return <InputText multiline textAlignVertical=\"top\" minHeight={theme.kitt.forms.textArea.minHeight} {...props} />;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\nimport { KittBreakpoints } from '../KittBreakpoints';\n\nconst Body = styled.View`\n ${({ theme }) =>\n theme.responsive.ifWindowSizeMatches(\n { minWidth: KittBreakpoints.MEDIUM },\n `padding-right: ${theme.kitt.spacing * 12}px;\n padding-left: ${theme.kitt.spacing * 12}px;`,\n `padding-right: ${theme.kitt.spacing * 6}px;\n padding-left: ${theme.kitt.spacing * 6}px;`,\n )}\n background-color: ${({ theme }) => theme.kitt.colors.uiBackgroundLight};\n flex: 1;\n`;\n\ninterface BodyProps {\n children: NonNullable<ReactNode>;\n}\n\nexport function FullScreenModalBody({ children }: BodyProps): ReactElement {\n return <Body>{children}</Body>;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { useState } from 'react';\nimport type { LayoutChangeEvent } from 'react-native';\nimport { Platform, useWindowDimensions } from 'react-native';\nimport { useSafeAreaInsets } from 'react-native-safe-area-context';\nimport styled from 'styled-components/native';\nimport { KittBreakpoints } from '../KittBreakpoints';\n\ninterface SideContainerProps {\n side?: 'left' | 'right';\n}\n\nconst SideContainer = styled.View<SideContainerProps>`\n ${({ theme, side = 'left' }) => {\n const padding = theme.kitt.spacing * 2;\n\n if (side === 'left') {\n return `padding-right: ${padding}px;`;\n }\n\n return `padding-left: ${padding}px;`;\n }}\n`;\n\nfunction getHeaderHorizontalMediumPadding(spacing: number): number {\n return spacing * 6;\n}\n\ninterface HeaderProps {\n insetTop?: number;\n}\n\nconst Header = styled.View<HeaderProps>`\n ${({ theme, insetTop = 0 }) => {\n const paddingTop = insetTop + theme.kitt.fullScreenModal.header.paddingVertical;\n const { paddingVertical, paddingHorizontal } = theme.kitt.fullScreenModal.header;\n\n return theme.responsive.ifWindowSizeMatches(\n { minWidth: KittBreakpoints.MEDIUM },\n `padding: ${paddingTop}px ${getHeaderHorizontalMediumPadding(theme.kitt.spacing)}px ${paddingVertical}px;`,\n `padding: ${paddingTop}px ${paddingHorizontal}px ${paddingVertical}px;`,\n );\n }};\n border-bottom-color: ${({ theme }) => theme.kitt.fullScreenModal.header.borderColor};\n border-bottom-width: 1px;\n flex-direction: row;\n align-items: center;\n`;\n\ninterface HeaderContentProps {\n windowWidth: number;\n leftWidth: number;\n rightWidth: number;\n}\n\nconst HeaderContent = styled.View<HeaderContentProps>`\n ${({ theme, leftWidth, rightWidth, windowWidth }) => {\n /*\n * Since we don't have controll over the rendered left and right elements,\n * we must apply some logic to give the title all the available space\n */\n const sideElementMaxWidth = Math.max(leftWidth, rightWidth);\n\n const parentHorizontalPadding = theme.kitt.fullScreenModal.header.paddingHorizontal * 2;\n const parentHorizontalPaddingMedium = getHeaderHorizontalMediumPadding(theme.kitt.spacing) * 2;\n\n const computeWidth = (breakpointPadding: number): number =>\n windowWidth - breakpointPadding - sideElementMaxWidth * 2;\n\n return theme.responsive.ifWindowSizeMatches(\n { minWidth: KittBreakpoints.MEDIUM },\n `width: ${computeWidth(parentHorizontalPaddingMedium)}px;`,\n `width: ${computeWidth(parentHorizontalPadding)}px;`,\n );\n }};\n ${({ leftWidth, rightWidth }) => {\n // Depending of the wider element, we must add a margin to fill the diff in space between elements\n const deltaMargin = Math.abs(leftWidth - rightWidth);\n\n if (leftWidth > rightWidth) {\n return `margin-right: ${deltaMargin}px;`;\n }\n\n return `margin-left: ${deltaMargin}px;`;\n }};\n justify-content: center;\n align-items: center;\n`;\n\nexport interface FullScreenModalHeaderProps {\n children: NonNullable<ReactNode>;\n right?: ReactNode;\n left?: ReactNode;\n}\n\nexport function FullScreenModalHeader({ children, right, left }: FullScreenModalHeaderProps): ReactElement {\n const { top } = useSafeAreaInsets();\n const dimensions = useWindowDimensions();\n const [leftWidth, setLeftWidth] = useState(0);\n const [rightWidth, setRightWidth] = useState(0);\n\n const handleLayoutChange = (event: LayoutChangeEvent, side: 'left' | 'right'): void => {\n // Prevents react to nullify event on rerenders\n event.persist();\n\n if (side === 'left') {\n setLeftWidth(event.nativeEvent.layout.width);\n return;\n }\n\n setRightWidth(event.nativeEvent.layout.width);\n };\n\n return (\n <Header insetTop={Platform.OS === 'ios' ? undefined : top}>\n {left ? <SideContainer onLayout={(e) => handleLayoutChange(e, 'left')}>{left}</SideContainer> : null}\n\n <HeaderContent windowWidth={dimensions.width} leftWidth={leftWidth} rightWidth={rightWidth}>\n {children}\n </HeaderContent>\n\n {right ? (\n <SideContainer side=\"right\" onLayout={(e) => handleLayoutChange(e, 'right')}>\n {right}\n </SideContainer>\n ) : null}\n </Header>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\nimport { FullScreenModalBody } from './Body';\nimport { FullScreenModalHeader } from './Header';\n\nconst Container = styled.View`\n flex: 1;\n background-color: ${({ theme }) => theme.kitt.colors.uiBackground};\n`;\n\nexport interface FullScreenModalProps {\n children: ReactNode;\n}\n\nexport function FullScreenModal({ children }: FullScreenModalProps): ReactElement {\n return <Container>{children}</Container>;\n}\n\nFullScreenModal.Header = FullScreenModalHeader;\nFullScreenModal.Body = FullScreenModalBody;\n","import type { ReactElement } from 'react';\nimport { cloneElement, useEffect, useRef } from 'react';\nimport { Animated, Easing } from 'react-native';\n\nexport interface SpinningIconProps {\n icon: ReactElement;\n color?: string;\n}\n\nexport function SpinningIcon({ icon, color }: SpinningIconProps): ReactElement {\n if (process.env.NODE_ENV !== 'production' && !color) {\n throw new Error(`Invalid color passed to SpinningIcon: ${String(color)}`);\n }\n const clonedIcon = cloneElement(icon, { color });\n const animationRef = useRef(new Animated.Value(0));\n\n const rotation = animationRef.current.interpolate({\n inputRange: [0, 1],\n outputRange: ['0deg', '360deg'],\n });\n\n useEffect(() => {\n if (process.env.NODE_ENV === 'test') return undefined;\n\n const animation = Animated.loop(\n Animated.timing(animationRef.current, {\n toValue: 1,\n duration: 1100,\n easing: Easing.linear,\n useNativeDriver: true,\n }),\n );\n animation.start();\n return () => {\n if (process.env.NODE_ENV === 'test') return undefined;\n\n animation.stop();\n return undefined;\n };\n }, []);\n\n return <Animated.View style={{ transform: [{ rotate: rotation }] }}>{clonedIcon}</Animated.View>;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport type { ViewProps } from 'react-native';\nimport styled from 'styled-components/native';\n\nexport interface ListItemContentProps extends ViewProps {\n children: NonNullable<ReactNode>;\n}\n\nconst ContentView = styled.View`\n flex: 1 0 0%;\n align-self: center;\n`;\n\nexport function ListItemContent({ children, ...rest }: ListItemContentProps): ReactElement {\n return <ContentView {...rest}>{children}</ContentView>;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport type { ViewProps, ViewStyle } from 'react-native';\nimport styled from 'styled-components/native';\n\nexport interface ListItemSideContainerProps extends ViewProps {\n children: NonNullable<ReactNode>;\n side?: 'left' | 'right';\n}\n\nconst SideContainerView = styled.View<ListItemSideContainerProps>`\n flex-direction: row;\n margin-left: ${({ theme, side }) => (side === 'right' ? `${theme.kitt.listItem.innerMargin}px` : 0)};\n margin-right: ${({ theme, side }) => (side === 'left' ? `${theme.kitt.listItem.innerMargin}px` : 0)};\n`;\n\n// Handles the vertical alignment of the side elements of the list item\nexport function ListItemSideContainer({ children, side = 'left', ...rest }: ListItemSideContainerProps): ReactElement {\n return (\n <SideContainerView side={side} {...rest}>\n {children}\n </SideContainerView>\n );\n}\n\nexport interface ListItemSideContentProps extends ViewProps {\n children: NonNullable<ReactNode>;\n align?: ViewStyle['alignSelf'];\n}\n\nconst SideContentView = styled.View<ListItemSideContentProps>`\n align-self: ${({ align }) => align};\n`;\n\nexport function ListItemSideContent({ children, align = 'auto', ...rest }: ListItemSideContentProps): ReactElement {\n return (\n <SideContentView align={align} {...rest}>\n {children}\n </SideContentView>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { Fragment } from 'react';\nimport type { PressableProps, ViewProps } from 'react-native';\nimport { Pressable } from 'react-native';\nimport styled, { css } from 'styled-components/native';\nimport { ListItemContent } from './ListItemContent';\nimport { ListItemSideContainer, ListItemSideContent } from './ListItemSideContent';\n\ntype Borders = 'top' | 'bottom' | 'both';\n\nexport interface ListItemProps extends ViewProps {\n children: NonNullable<ReactNode>;\n left?: ReactNode;\n right?: ReactNode;\n borders?: Borders;\n withPadding?: boolean;\n onPress?: PressableProps['onPress'];\n}\n\ninterface ContainerViewProps extends Pick<ListItemProps, 'borders' | 'withPadding'> {}\n\nconst ContainerView = styled.View<ContainerViewProps>`\n flex-direction: row;\n padding: ${({ withPadding, theme }) => (withPadding ? theme.kitt.listItem.padding : 0)};\n ${({ theme, borders }) => {\n const { borderWidth } = theme.kitt.listItem;\n\n if (borders === 'top') {\n return `border-top-width: ${borderWidth}px`;\n }\n\n if (borders === 'bottom') {\n return `border-bottom-width: ${borderWidth}px`;\n }\n\n if (borders === 'both') {\n return css`\n border-top-width: ${borderWidth}px;\n border-bottom-width: ${borderWidth}px;\n `;\n }\n\n return 'border: none';\n }};\n border-color: ${({ theme }) => theme.kitt.listItem.borderColor};\n background-color: ${({ theme }) => theme.kitt.colors.uiBackgroundLight};\n`;\n\nexport function ListItem({\n children,\n withPadding,\n borders,\n left,\n right,\n onPress,\n ...rest\n}: ListItemProps): ReactElement {\n const Wrapper = onPress ? Pressable : Fragment;\n const wrapperProps = onPress ? { accessibilityRole: 'button', onPress, ...rest } : undefined;\n const containerProps = onPress ? undefined : rest;\n\n return (\n <Wrapper {...(wrapperProps as any)}>\n <ContainerView withPadding={withPadding} borders={borders} {...containerProps}>\n {left ? <ListItemSideContainer side=\"left\">{left}</ListItemSideContainer> : null}\n\n <ListItemContent>{children}</ListItemContent>\n\n {right ? <ListItemSideContainer side=\"right\">{right}</ListItemSideContainer> : null}\n </ContainerView>\n </Wrapper>\n );\n}\n\nListItem.Content = ListItemContent;\nListItem.SideContent = ListItemSideContent;\nListItem.SideContainer = ListItemSideContainer;\n","import { ArcIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement } from 'react';\nimport type { SpinningIconProps } from '../Icon/SpinningIcon';\nimport { SpinningIcon } from '../Icon/SpinningIcon';\n\nexport interface LoaderIconProps {\n color?: SpinningIconProps['color'];\n}\n\nexport function LoaderIcon({ color }: LoaderIconProps): ReactElement {\n return <SpinningIcon color={color} icon={<ArcIcon />} />;\n}\n","import { AlertCircleIcon, AlertTriangleIcon, CheckIcon, InfoIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement } from 'react';\nimport type { TypographyColor } from '../typography/Typography';\nimport type { MessageType } from './BaseMessage';\n\ninterface IconContentProps {\n type: MessageType;\n color: TypographyColor;\n}\n\nexport function IconContent({ type, color }: IconContentProps): ReactElement {\n switch (type) {\n case 'warning':\n return <AlertCircleIcon color={color} />;\n case 'success':\n return <CheckIcon color={color} />;\n case 'danger':\n return <AlertTriangleIcon color={color} />;\n default:\n return <InfoIcon color={color} />;\n }\n}\n","import type { IconButtonProps } from '../IconButton/IconButton';\nimport type { TypographyColor } from '../typography/Typography';\nimport type { MessageType } from './BaseMessage';\n\nexport const getColorByType = (type: MessageType): TypographyColor => {\n switch (type) {\n case 'success':\n return 'white';\n case 'danger':\n return 'white';\n case 'warning':\n default:\n return 'black';\n }\n};\n\nexport const getIconButtonColor = (messageType: MessageType): IconButtonProps['color'] => {\n switch (messageType) {\n case 'success':\n case 'danger':\n return 'white';\n case 'warning':\n default:\n return 'black';\n }\n};\n","import { XIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement, ReactNode } from 'react';\nimport type { EdgeInsets } from 'react-native-safe-area-context';\nimport styled from 'styled-components/native';\nimport { Icon } from '../Icon/Icon';\nimport { IconButton } from '../IconButton/IconButton';\nimport { Typography } from '../typography/Typography';\nimport { IconContent } from './IconContent';\nimport { getColorByType, getIconButtonColor } from './helper';\n\nexport type MessageType = 'success' | 'warning' | 'danger' | 'info';\n\ninterface StyledMessageContainerProps {\n $type: MessageType;\n $hasNoRadius?: boolean;\n $insets?: EdgeInsets;\n}\n\nconst StyledMessageContainer = styled.View<StyledMessageContainerProps>`\n flex-direction: row;\n align-items: flex-start;\n justify-content: space-between;\n min-height: 60px;\n padding-top: ${({ $insets }) => $insets?.top ?? 0}px;\n border-radius: ${({ theme, $hasNoRadius }) => ($hasNoRadius ? 0 : theme.kitt.spacing * 5)}px;\n background-color: ${({ theme, $type }) => theme.kitt.feedbackMessage[$type].backgroundColor};\n`;\n\nconst StyledDismissWrapper = styled.View`\n align-items: center;\n align-items: flex-start;\n margin: ${({ theme }) => {\n const { spacing } = theme.kitt;\n return `${spacing * 2.5}px ${spacing * 2}px 0 ${spacing * 5}px`;\n }};\n`;\n\nconst StyledIconContainer = styled.View`\n margin: ${({ theme }) => {\n const { spacing } = theme.kitt;\n return `${spacing}px ${spacing * 5}px 0 0`;\n }};\n`;\n\ninterface StyledTextContentProps {\n $isCenteredText?: boolean;\n}\n\nconst StyledTextContent = styled(Typography.Text)<StyledTextContentProps>`\n flex: 1;\n text-align: ${({ $isCenteredText }) => ($isCenteredText ? 'center' : 'left')};\n`;\n\nconst StyledMessageContent = styled.View`\n display: flex;\n flex-direction: row;\n flex-grow: 1;\n align-self: center;\n align-items: flex-start;\n flex-shrink: 1;\n padding: ${({ theme }) => {\n const { spacing } = theme.kitt;\n return `${spacing * 4}px ${spacing * 5}px`;\n }};\n`;\n\nexport interface BaseMessageProps {\n type?: MessageType;\n children: NonNullable<ReactNode>;\n /**\n * @internal for styling between Message and Notification\n */\n hasNoRadius?: boolean;\n centeredText?: boolean;\n insets?: EdgeInsets;\n onDismiss?: () => void;\n}\n\nexport function BaseMessage({\n type = 'info',\n children,\n hasNoRadius,\n centeredText,\n insets,\n onDismiss,\n}: BaseMessageProps): ReactElement {\n const color = getColorByType(type);\n\n return (\n <StyledMessageContainer $type={type} $hasNoRadius={hasNoRadius} $insets={insets}>\n <StyledMessageContent>\n {centeredText ? null : (\n <StyledIconContainer>\n <Icon color={color} icon={<IconContent type={type} color={color} />} />\n </StyledIconContainer>\n )}\n <StyledTextContent $isCenteredText={centeredText} base=\"body\" color={color}>\n {children}\n </StyledTextContent>\n </StyledMessageContent>\n\n {onDismiss ? (\n <StyledDismissWrapper>\n <IconButton color={getIconButtonColor(type)} icon={<XIcon />} onPress={onDismiss} />\n </StyledDismissWrapper>\n ) : null}\n </StyledMessageContainer>\n );\n}\n","import type { ReactElement } from 'react';\nimport type { BaseMessageProps } from '../BaseMessage/BaseMessage';\nimport { BaseMessage } from '../BaseMessage/BaseMessage';\n\nexport interface MessageProps extends BaseMessageProps {}\n\nexport function Message({\n type = 'info',\n children,\n hasNoRadius,\n centeredText,\n insets,\n onDismiss,\n}: MessageProps): ReactElement {\n return (\n <BaseMessage\n insets={insets}\n hasNoRadius={hasNoRadius}\n type={type}\n centeredText={centeredText}\n onDismiss={onDismiss}\n >\n {children}\n </BaseMessage>\n );\n}\n","import type { ReactElement } from 'react';\nimport { BaseMessage } from '../BaseMessage/BaseMessage';\nimport type { BaseMessageProps } from '../BaseMessage/BaseMessage';\n\nexport interface NotificationProps extends BaseMessageProps {\n /**\n * @deprecated use onDismiss instead\n */\n onDelete?: BaseMessageProps['onDismiss'];\n}\n\nexport function Notification({\n type,\n children,\n centeredText,\n insets,\n onDelete,\n onDismiss,\n}: NotificationProps): ReactElement {\n if (__DEV__) {\n if (onDelete) {\n throw new Error('onDelete is deprecated us onDismiss instead');\n }\n }\n\n return (\n <BaseMessage hasNoRadius type={type} centeredText={centeredText} insets={insets} onDismiss={onDismiss}>\n {children}\n </BaseMessage>\n );\n}\n","import type { ReactElement } from 'react';\nimport { ActivityIndicator, Platform } from 'react-native';\nimport { useTheme } from 'styled-components/native';\n\nexport type PageLoaderProps = Record<string, never>;\n\nfunction getActivityIndicatorSize(size: number): number | 'small' | 'large' {\n if (Platform.OS === 'android') return size;\n return size < 36 ? 'small' : 'large';\n}\n\nexport function PageLoader(props: PageLoaderProps): ReactElement {\n const theme = useTheme();\n const { size } = theme.kitt.pageLoader;\n const colorHex = theme.kitt.typography.colors.primary;\n return <ActivityIndicator testID=\"ActivityIndicator\" color={colorHex} size={getActivityIndicatorSize(size)} />;\n}\n","import { LinearGradient } from 'expo-linear-gradient';\nimport type { ReactElement } from 'react';\nimport { useEffect } from 'react';\nimport { StyleSheet } from 'react-native';\nimport Animated, {\n Easing,\n interpolate,\n useAnimatedStyle,\n useSharedValue,\n withRepeat,\n withTiming,\n} from 'react-native-reanimated';\nimport styled, { useTheme } from 'styled-components/native';\n\ninterface SkeletonProps {\n isLoading?: boolean;\n width: number;\n}\n\nconst Container = styled.View`\n background-color: ${({ theme }) => theme.kitt.skeleton.backgroundColor};\n border-color: ${({ theme }) => theme.kitt.skeleton.flareColor};\n height: 100%;\n width: 100%;\n`;\nconst AnimatedLinearGradient = Animated.createAnimatedComponent(LinearGradient);\n\nexport function SkeletonContent({ isLoading, width }: SkeletonProps): ReactElement {\n const theme = useTheme();\n const sharedX = useSharedValue(0);\n\n useEffect(() => {\n if (isLoading) {\n sharedX.value = withRepeat(\n withTiming(1, { duration: theme.kitt.skeleton.animationDuration, easing: Easing.inOut(Easing.ease) }),\n -1,\n );\n }\n }, [sharedX, width, isLoading, theme]);\n\n const linearGradientStyle = useAnimatedStyle(() => {\n return {\n transform: [{ translateX: interpolate(sharedX.value, [0, 1], [-width, width]) }],\n };\n });\n\n return (\n <Container>\n <AnimatedLinearGradient\n colors={[\n theme.kitt.skeleton.backgroundColor,\n theme.kitt.skeleton.flareColor,\n theme.kitt.skeleton.backgroundColor,\n ]}\n locations={[0.1, 0.5, 0.9]}\n start={{ x: 0, y: 0 }}\n end={{ x: 1, y: 0 }}\n style={[StyleSheet.absoluteFill, linearGradientStyle]}\n />\n </Container>\n );\n}\n","import type { ReactElement } from 'react';\nimport { useState } from 'react';\nimport type { StyleProp, ViewStyle } from 'react-native';\nimport { View } from 'react-native';\nimport styled from 'styled-components/native';\nimport { SkeletonContent } from './SkeletonContent';\n\nconst SkeletonContainer = styled(View)`\n overflow: hidden;\n`;\nexport interface SkeletonProps {\n isLoading?: boolean;\n style?: StyleProp<ViewStyle>;\n}\n\nexport function Skeleton({ isLoading, style }: SkeletonProps): ReactElement {\n const [width, setWidth] = useState(0);\n\n return (\n <SkeletonContainer style={style} onLayout={({ nativeEvent }) => setWidth(nativeEvent.layout.width)}>\n <SkeletonContent isLoading={isLoading} width={width} />\n </SkeletonContainer>\n );\n}\n\nconst Bar = styled(Skeleton)`\n width: 100%;\n height: ${({ theme }) => theme.kitt.spacing * 2}px;\n border-radius: ${({ theme }) => theme.kitt.spacing * 2}px;\n`;\n\nconst Circle = styled(Skeleton)`\n width: ${({ theme }) => theme.kitt.spacing * 12}px;\n height: ${({ theme }) => theme.kitt.spacing * 12}px;\n border-radius: ${({ theme }) => theme.kitt.spacing * 6}px;\n`;\n\nconst Square = styled(Skeleton)`\n width: ${({ theme }) => theme.kitt.spacing * 12}px;\n height: ${({ theme }) => theme.kitt.spacing * 12}px;\n border-radius: ${({ theme }) => theme.kitt.spacing * 1.5}px;\n`;\n\nSkeleton.Bar = Bar;\nSkeleton.Circle = Circle;\nSkeleton.Square = Square;\n","import type { ViewStyle } from 'react-native';\nimport styled from 'styled-components/native';\n\ninterface FlexProps {\n direction: ViewStyle['flexDirection'];\n padding?: number;\n}\n\nexport const Flex = styled.View.withConfig<FlexProps>({\n shouldForwardProp: (prop, defaultValidatorFn) => !['direction', 'padding'].includes(prop) && defaultValidatorFn(prop),\n})`\n display: flex;\n flex-direction: ${({ direction }) => direction};\n flex-wrap: wrap;\n padding: ${({ theme, padding = 0 }) => padding * theme.kitt.spacing}px;\n`;\n","export const storyPadding = 16;\n","import type { ReactElement, ReactNode } from 'react';\nimport { createContext, useContext } from 'react';\nimport type { DefaultTheme } from 'styled-components/native';\nimport styled from 'styled-components/native';\nimport type { TypographyColor } from '../typography/Typography';\nimport { storyPadding } from './theme';\n\nexport interface StoryBlockProps {\n background?: 'dark' | 'light' | 'primary' | 'transparent';\n children: ReactNode;\n}\n\nconst getBackgroundColorFromBlockColor = (\n theme: DefaultTheme,\n color: StoryBlockProps['background'] = 'transparent',\n): string => {\n switch (color) {\n case 'dark':\n return '#293033';\n case 'light':\n return '#ffffff';\n case 'primary':\n return theme.kitt.palettes.lateOcean.lateOcean;\n default:\n return 'transparent';\n }\n};\n\nconst getTypographyColorFromBlockColor = (color: StoryBlockProps['background'] = 'transparent'): TypographyColor => {\n switch (color) {\n case 'dark':\n case 'primary':\n return 'white';\n case 'light':\n default:\n return 'black';\n }\n};\n\nexport const StoryBlockBackgroundContext = createContext<StoryBlockProps['background']>('transparent');\nconst StoryBlockColorContext = createContext<TypographyColor>('black');\n\nexport const useStoryBlockColor = (color?: TypographyColor | undefined): TypographyColor => {\n const storyBlockColor = useContext(StoryBlockColorContext);\n return color || storyBlockColor;\n};\n\nconst StyledStoryBlockView = styled.View<StoryBlockProps>`\n padding: 16px ${storyPadding}px 0;\n margin: 0 -${storyPadding}px;\n background: ${({ theme, background }) => getBackgroundColorFromBlockColor(theme, background)};\n`;\n\nexport function StoryBlock({ children, background }: StoryBlockProps): ReactElement {\n return (\n <StyledStoryBlockView background={background}>\n <StoryBlockColorContext.Provider value={getTypographyColorFromBlockColor(background)}>\n <StoryBlockBackgroundContext.Provider value={background}>{children}</StoryBlockBackgroundContext.Provider>\n </StoryBlockColorContext.Provider>\n </StyledStoryBlockView>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\nimport type { TypographyProps } from '../typography/Typography';\nimport { Typography } from '../typography/Typography';\nimport { useStoryBlockColor } from './StoryBlock';\n\ninterface StoryTitleProps {\n color?: TypographyProps['color'];\n numberOfLines?: TypographyProps['numberOfLines'];\n children: ReactNode;\n}\n\nconst StoryTitleContainer = styled.View`\n margin-bottom: 30px;\n`;\n\nconst StorySubTitleContainer = styled.View`\n margin-bottom: 10px;\n`;\n\nexport function StoryTitle({ color, children, numberOfLines }: StoryTitleProps): ReactElement {\n return (\n <StoryTitleContainer>\n <Typography.Header1 variant=\"bold\" base=\"header1\" color={useStoryBlockColor(color)} numberOfLines={numberOfLines}>\n {children}\n </Typography.Header1>\n </StoryTitleContainer>\n );\n}\n\nfunction StoryTitleLevel2({ color, children, numberOfLines }: StoryTitleProps): ReactElement {\n return (\n <StoryTitleContainer>\n <Typography.Header2 variant=\"bold\" base=\"header2\" color={useStoryBlockColor(color)} numberOfLines={numberOfLines}>\n {children}\n </Typography.Header2>\n </StoryTitleContainer>\n );\n}\n\nStoryTitleLevel2.displayName = 'StoryTitle.Level2';\n\nfunction StoryTitleLevel3({ color, children, numberOfLines }: StoryTitleProps): ReactElement {\n return (\n <StorySubTitleContainer>\n <Typography.Header3\n variant=\"bold\"\n base=\"header3\"\n medium=\"header4\"\n color={useStoryBlockColor(color)}\n numberOfLines={numberOfLines}\n >\n {children}\n </Typography.Header3>\n </StorySubTitleContainer>\n );\n}\n\nStoryTitleLevel3.displayName = 'StoryTitle.Level3';\n\nfunction StoryTitleLevel4({ color, children, numberOfLines }: StoryTitleProps): ReactElement {\n return (\n <StorySubTitleContainer>\n <Typography.Header4\n variant=\"bold\"\n base=\"header4\"\n medium=\"header5\"\n color={useStoryBlockColor(color)}\n numberOfLines={numberOfLines}\n >\n {children}\n </Typography.Header4>\n </StorySubTitleContainer>\n );\n}\n\nStoryTitleLevel4.displayName = 'StoryTitle.Level3';\n\nStoryTitle.Level2 = StoryTitleLevel2;\nStoryTitle.Level3 = StoryTitleLevel3;\nStoryTitle.Level4 = StoryTitleLevel4;\n","import type { ReactElement, ReactNode } from 'react';\nimport type { ScrollViewProps } from 'react-native';\nimport styled from 'styled-components/native';\nimport { StoryTitle } from './StoryTitle';\nimport { storyPadding } from './theme';\n\nexport interface StoryProps {\n title: ReactNode;\n children: ReactNode;\n contentContainerStyle?: ScrollViewProps['contentContainerStyle'];\n}\n\nconst StoryContainer = styled.ScrollView`\n padding: ${storyPadding}px;\n`;\n\nexport function Story({ title, contentContainerStyle, children }: StoryProps): ReactElement {\n return (\n <StoryContainer contentContainerStyle={contentContainerStyle}>\n <StoryTitle>{title}</StoryTitle>\n {children}\n </StoryContainer>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport type { ViewProps } from 'react-native';\nimport styled from 'styled-components/native';\nimport { StoryTitle } from './StoryTitle';\n\ninterface StyledSectionProps extends ViewProps {}\n\nconst StyledSection = styled.View<StyledSectionProps>`\n margin-bottom: 32px;\n`;\n\nexport interface StorySectionProps extends ViewProps {\n title: ReactNode;\n children: ReactNode;\n /** @private */\n internalIsDemoSection?: boolean;\n}\n\nexport function StorySection({ title, children, internalIsDemoSection, ...props }: StorySectionProps): ReactElement {\n if (title === 'Demo' && !internalIsDemoSection) throw new Error('Use StorySection.Demo instead');\n return (\n <StyledSection {...props}>\n <StoryTitle.Level2>{title}</StoryTitle.Level2>\n {children}\n </StyledSection>\n );\n}\n\nconst StyledSubSection = styled.View`\n margin-bottom: 16px;\n`;\n\nfunction SubSection({ title, children, ...props }: StorySectionProps): ReactElement {\n return (\n <StyledSubSection {...props}>\n <StoryTitle.Level3>{title}</StoryTitle.Level3>\n {children}\n </StyledSubSection>\n );\n}\n\nconst StyledBlockSection = styled.View`\n margin-bottom: 16px;\n`;\n\nfunction BlockSection({ title, children, ...props }: StorySectionProps): ReactElement {\n return (\n <StyledBlockSection {...props}>\n <StoryTitle.Level4>{title}</StoryTitle.Level4>\n {children}\n </StyledBlockSection>\n );\n}\n\nexport interface DemoSectionProps {\n children: ReactNode;\n}\n\nconst StyledDemoSection = styled.View`\n margin-bottom: 64px;\n`;\n\nfunction DemoSection({ children }: DemoSectionProps): ReactElement {\n return (\n <StyledDemoSection>\n <StorySection internalIsDemoSection title=\"Demo\">\n {children}\n </StorySection>\n </StyledDemoSection>\n );\n}\n\nStorySection.SubSection = SubSection;\nStorySection.BlockSection = BlockSection;\n/** @deprecated use StorySection.Demo instead */\nStorySection.DemoSection = DemoSection;\nStorySection.Demo = DemoSection;\n\n/** @deprecated use StorySection instead */\nexport const DeprecatedSection = StorySection;\n","import type { ReactElement, ReactNode } from 'react';\nimport { StorySection } from './StorySection';\n\nexport interface StoryContainerProps {\n children: NonNullable<ReactNode>;\n state?: 'none' | 'active' | 'hover' | 'focus';\n platform?: 'all' | 'native' | 'web';\n title?: ReactNode;\n}\n\nexport function StoryContainer({\n children,\n title,\n state = 'none',\n platform = 'all',\n}: StoryContainerProps): ReactElement | null {\n if (platform === 'web') return null;\n\n return (\n <StorySection.BlockSection testID={state} title={title}>\n {children}\n </StorySection.BlockSection>\n );\n}\n","import type { StoryContext } from '@storybook/addons';\nimport type { ReactElement, ReactNode } from 'react';\nimport { Story as StoryContainer } from './Story';\n\nexport function StoryDecorator(storyFn: () => ReactNode, context: StoryContext): ReactElement {\n return <StoryContainer title={context.name}>{storyFn()}</StoryContainer>;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { Children } from 'react';\nimport { Platform, useWindowDimensions } from 'react-native';\nimport styled from 'styled-components/native';\nimport type { TypographyProps } from '..';\nimport { StoryTitle } from './StoryTitle';\n\nconst SmallScreenRow = styled.View`\n flex-direction: column;\n margin: 0;\n`;\n\nconst SmallScreenCol = styled.View`\n padding: 8px 0 16px;\n`;\n\nconst FlexRow = styled.View`\n flex-direction: row;\n margin: 0 -4px 16px;\n`;\n\nconst FlexCol = styled.View`\n flex-grow: 1;\n flex-basis: 0;\n margin: 0 8px;\n`;\n\nexport interface StoryGridRowProps {\n children: NonNullable<ReactNode>;\n breakpoint?: 'small' | 'medium';\n}\n\nfunction StoryGridRow({ children, breakpoint = 'small' }: StoryGridRowProps): ReactElement {\n // eslint-disable-next-line unicorn/expiring-todo-comments\n // TODO use useBreakpoint instead\n const { width } = useWindowDimensions();\n const breakpointValue = breakpoint === 'small' ? 480 : 768;\n\n if (width < breakpointValue) {\n return (\n <SmallScreenRow>\n {Children.map(children, (child) => (\n <SmallScreenCol>{child}</SmallScreenCol>\n ))}\n </SmallScreenRow>\n );\n }\n\n return (\n <FlexRow>\n {Children.map(children, (child) => (\n <FlexCol>{child}</FlexCol>\n ))}\n </FlexRow>\n );\n}\n\nexport interface StoryGridColProps {\n children: NonNullable<ReactNode>;\n title?: string;\n titleColor?: TypographyProps['color'];\n platform?: 'all' | 'native' | 'web';\n}\n\nfunction StoryGridCol({ title, titleColor, children, platform = 'all' }: StoryGridColProps): ReactElement | null {\n const isNative = Platform.OS === 'ios' || Platform.OS === 'android';\n\n if (Platform.OS === 'web' && platform === 'native') {\n return null;\n }\n\n if (isNative && platform === 'web') {\n return null;\n }\n\n return (\n <>\n {title ? (\n <StoryTitle.Level4 numberOfLines={1} color={titleColor}>\n {title}\n </StoryTitle.Level4>\n ) : null}\n {children}\n </>\n );\n}\n\nexport const StoryGrid = {\n Row: StoryGridRow,\n Col: StoryGridCol,\n};\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\nimport type { TypographyColor } from '../typography/Typography';\nimport { Typography } from '../typography/Typography';\n\nexport type TagType = 'primary' | 'default' | 'danger';\n\nexport type TagVariant = 'outline' | 'fill';\n\nexport interface TagProps {\n label: ReactNode;\n type?: TagType;\n variant?: TagVariant;\n}\n\ninterface ContainerProps {\n type: TagType;\n variant: TagVariant;\n}\n\nconst Container = styled.View<ContainerProps>`\n background-color: ${({ theme, type, variant }) => theme.kitt.tag[type][variant].backgroundColor};\n border-width: ${({ theme, type, variant }) => theme.kitt.tag[type][variant].borderWidth}px;\n border-color: ${({ theme, type, variant }) => theme.kitt.tag[type][variant].borderColor};\n padding: ${({ theme }) => theme.kitt.tag.padding};\n border-radius: ${({ theme }) => theme.kitt.tag.borderRadius}px;\n align-self: flex-start;\n`;\n\nexport const getLabelColor = (type: TagType, variant: TagVariant): TypographyColor => {\n switch (type) {\n case 'danger': {\n return variant === 'outline' ? 'danger' : 'black';\n }\n case 'primary': {\n return 'primary';\n }\n case 'default': {\n return 'black';\n }\n default: {\n return 'black';\n }\n }\n};\n\nexport function Tag({ label, type = 'default', variant = 'fill' }: TagProps): ReactElement {\n return (\n <Container type={type} variant={variant}>\n <Typography.Text base=\"body-xsmall\" color={getLabelColor(type, variant)}>\n {label}\n </Typography.Text>\n </Container>\n );\n}\n","import type { DateTimePickerEvent } from '@react-native-community/datetimepicker';\nimport DateTimePicker from '@react-native-community/datetimepicker';\nimport type { ReactElement, ReactNode } from 'react';\nimport { useState } from 'react';\nimport { FormattedMessage } from 'react-intl';\nimport { Platform, Text } from 'react-native';\nimport { Button } from '../Button/Button';\nimport { Modal } from '../Modal/Modal';\nimport { Typography } from '../typography/Typography';\n\ninterface TitleProps {\n children: NonNullable<ReactNode>;\n}\n\nfunction Title({ children }: TitleProps): ReactElement {\n return (\n <Modal.Header>\n <Typography.Text base=\"body\" variant=\"bold\">\n {children}\n </Typography.Text>\n </Modal.Header>\n );\n}\n\ninterface ModalDateTimePickerProps {\n title?: ReactNode;\n visible?: boolean;\n value: Date;\n validateButtonLabel?: string;\n onClose: () => void;\n onChange: (newDate: Date) => void;\n}\n\nexport function ModalDateTimePicker({\n title,\n visible,\n value,\n validateButtonLabel,\n onChange,\n onClose,\n}: ModalDateTimePickerProps): ReactElement {\n const [currentValue, setCurrentValue] = useState(value);\n\n // Prevent unsynced value between the modal and its parent state\n const handleClose = (): void => {\n setCurrentValue(value);\n onClose();\n };\n\n const handleSubmit = (): void => {\n onChange(currentValue);\n };\n\n return (\n <Modal visible={Boolean(visible)} onClose={handleClose}>\n {visible ? (\n <>\n {title ? <Title>{title}</Title> : null}\n\n <Modal.Body>\n <DateTimePicker\n is24Hour\n testID=\"date-picker-native-element\"\n value={currentValue}\n mode=\"time\"\n display={Platform.OS === 'ios' ? 'spinner' : 'default'}\n onChange={(_event: DateTimePickerEvent, date?: Date) =>\n setCurrentValue((prev) => {\n return date || prev;\n })\n }\n />\n </Modal.Body>\n <Modal.Footer>\n <Button stretch type=\"primary\" onPress={handleSubmit}>\n {validateButtonLabel ? (\n <Text>{validateButtonLabel}</Text>\n ) : (\n <FormattedMessage id=\"kitt-universal.ModalDateTimePicker.confirm\" defaultMessage=\"Valider\" />\n )}\n </Button>\n </Modal.Footer>\n </>\n ) : null}\n </Modal>\n );\n}\n","import type { InputUIState } from '@ornikar/kitt-universal';\nimport { useMemo, useState } from 'react';\n\nexport const timePickerPlaceholder = '--:--';\n\nexport const formatNumberToTimeString = (time: number): string => `${String(time).padStart(2, '0')}`;\n\nexport const formatDateToTimeString = (date: Date): string =>\n `${formatNumberToTimeString(date.getHours())}:${formatNumberToTimeString(date.getMinutes())}`;\n\nexport const useTimePicker = (\n value: Date | null,\n onChange: (time?: Date | null) => void,\n onBlur: () => void,\n disabled: boolean,\n defaultValue?: Date | null,\n): {\n displayedValue: string;\n dateTimePickerValue: Date;\n timePickerState: InputUIState;\n isTimePickerModalVisible: boolean;\n handleInputPress: () => void;\n handleModalClose: () => void;\n handleTimeChange: (date?: Date) => void;\n} => {\n const [isTimePickerModalVisible, setIsTimePickerModalVisible] = useState<boolean>(false);\n\n const todayAtNoon = useMemo(() => {\n const now = new Date(2000, 0, 1, 12);\n return new Date(now.getFullYear(), now.getMonth(), now.getDay(), 12);\n }, []);\n\n const defaultDate = defaultValue || todayAtNoon;\n const handleInputPress = (): void => {\n if (disabled) {\n return;\n }\n setIsTimePickerModalVisible(true);\n };\n\n const handleTimeChange = (date?: Date | null): void => {\n setIsTimePickerModalVisible(false);\n\n onChange(date || defaultDate);\n onBlur();\n };\n\n const dateTimePickerValue = value || defaultDate;\n const displayedValue = value === null ? timePickerPlaceholder : formatDateToTimeString(dateTimePickerValue);\n const timePickerState = isTimePickerModalVisible ? 'focus' : 'default';\n\n return {\n dateTimePickerValue,\n displayedValue,\n timePickerState,\n isTimePickerModalVisible,\n handleInputPress,\n handleTimeChange,\n handleModalClose: () => setIsTimePickerModalVisible(false),\n };\n};\n","import type { TextInputMixinProps } from '@ornikar/kitt-universal';\nimport type { DateTimePickerEvent } from '@react-native-community/datetimepicker';\nimport DateTimePicker from '@react-native-community/datetimepicker';\nimport type { ReactElement, ReactNode } from 'react';\nimport { Platform } from 'react-native';\nimport styled from 'styled-components/native';\nimport { styledTextInputMixin } from '../forms/styledTextInputMixin';\nimport { Typography } from '../typography/Typography';\nimport { ModalDateTimePicker } from './ModalDateTimePicker';\nimport { timePickerPlaceholder, useTimePicker } from './useTimePicker';\n\ninterface ContainerProps extends TextInputMixinProps {}\n\nconst Container = styled.Pressable<ContainerProps>`\n ${styledTextInputMixin}\n width: 100px;\n height: 40px;\n justify-content: center;\n align-items: center;\n`;\n\nexport type TimePickerValue = Date | null | undefined;\n\nexport interface TimePickerProps {\n title?: ReactNode;\n state?: TextInputMixinProps['$state'];\n disabled?: boolean;\n forceDefaultValue?: TimePickerValue;\n value?: Date | '' | null;\n validateButtonLabel?: string;\n onChange: (time: TimePickerValue) => void;\n onBlur: () => void;\n}\n\nexport function TimePicker({\n title,\n state = 'default',\n disabled = false,\n forceDefaultValue,\n value,\n validateButtonLabel,\n onChange,\n onBlur,\n}: TimePickerProps): ReactElement {\n const {\n dateTimePickerValue,\n displayedValue,\n timePickerState,\n handleInputPress,\n handleModalClose,\n handleTimeChange,\n isTimePickerModalVisible,\n } = useTimePicker(value || null, onChange, onBlur, disabled, forceDefaultValue);\n\n return (\n <Container\n $state={timePickerState === 'default' ? state : timePickerState}\n accessibilityRole=\"button\"\n onPress={handleInputPress}\n >\n <Typography.Text base=\"body\" color={displayedValue === timePickerPlaceholder ? 'black-light' : 'black'}>\n {displayedValue}\n </Typography.Text>\n\n {Platform.OS === 'android' && isTimePickerModalVisible ? (\n <DateTimePicker\n is24Hour\n testID=\"date-picker-native-element\"\n value={dateTimePickerValue}\n mode=\"time\"\n display=\"default\"\n onChange={(_event: DateTimePickerEvent, date?: Date) => handleTimeChange(date)}\n />\n ) : null}\n\n {Platform.OS !== 'android' ? (\n <ModalDateTimePicker\n title={title}\n visible={isTimePickerModalVisible}\n value={dateTimePickerValue}\n validateButtonLabel={validateButtonLabel}\n onChange={handleTimeChange}\n onClose={handleModalClose}\n />\n ) : null}\n </Container>\n );\n}\n","import { TooltipArrowIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement, ReactNode } from 'react';\nimport type { ViewProps } from 'react-native';\nimport { View } from 'react-native';\nimport styled, { useTheme } from 'styled-components/native';\nimport { Typography } from '../typography/Typography';\nimport type { TooltipPosition } from './Tooltip';\n\nconst StyledTooltipView = styled.View`\n align-items: center;\n`;\n\nconst StyledTooltipContent = styled.View`\n background-color: ${({ theme }) => theme.kitt.tooltip.backgroundColor};\n border-radius: ${({ theme }) => theme.kitt.tooltip.borderRadius}px;\n opacity: ${({ theme }) => theme.kitt.tooltip.opacity};\n padding: ${({ theme }) => `${theme.kitt.tooltip.verticalPadding}px ${theme.kitt.tooltip.horizontalPadding}px`};\n`;\n\ninterface StyledArrowProps {\n $position: TooltipPosition;\n}\n\nfunction ArrowView(props: ViewProps): ReactElement {\n const theme = useTheme();\n return (\n <View {...props}>\n <TooltipArrowIcon color={theme.kitt.tooltip.backgroundColor} />\n </View>\n );\n}\n\nconst StyledArrow = styled(ArrowView)<StyledArrowProps>`\n color: ${({ theme }) => theme.kitt.tooltip.backgroundColor};\n transform: ${({ $position }) => `rotate(${$position === 'bottom' ? 180 : 0}deg)`};\n`;\n\nexport interface TooltipViewProps {\n children: NonNullable<ReactNode>;\n position: TooltipPosition;\n}\n\nexport function TooltipView({ children, position }: TooltipViewProps): ReactElement {\n return (\n <StyledTooltipView>\n {position === 'bottom' ? <StyledArrow $position={position} /> : null}\n <StyledTooltipContent>\n <Typography.Text base=\"body\" color=\"white\">\n {children}\n </Typography.Text>\n </StyledTooltipContent>\n {position === 'top' ? <StyledArrow $position={position} /> : null}\n </StyledTooltipView>\n );\n}\n","import type { TooltipProps } from '..';\nimport type { TooltipPosition } from './Tooltip';\n\nexport const tooltipDefaultPosition: TooltipPosition = 'top';\nexport const tooltipDefaultFloatingStrategy: TooltipProps['floatingStrategy'] = {\n web: 'absolute',\n};\n","import { flip, offset, shift, useFloating } from '@floating-ui/react-native';\nimport type { ReactElement, ReactNode } from 'react';\nimport { useEffect } from 'react';\nimport { Pressable, StyleSheet, View } from 'react-native';\nimport Animated, { useAnimatedStyle, useSharedValue, withSpring } from 'react-native-reanimated';\nimport styled, { useTheme } from 'styled-components/native';\nimport { TooltipView } from './TooltipView';\nimport { tooltipDefaultPosition } from './tooltipUtils';\n\nexport type TooltipPosition = 'bottom' | 'top';\nexport type WebFloatingPosition = 'fixed' | 'absolute';\n\n// Since the tooltip use absolute positionning, we need a parent to provide the relative root\nconst TooltipContainer = styled.View`\n position: relative;\n align-self: baseline;\n`;\n\nexport interface TooltipProps {\n children: NonNullable<ReactNode>;\n content: NonNullable<ReactNode>;\n floatingPadding?: number;\n position?: TooltipPosition;\n /**\n * @description\n * This value init the internal visibile state of the tooltip. This is mainly used for testing purpose.\n */\n defaultVisible?: boolean;\n // eslint-disable-next-line react/no-unused-prop-types\n fullWidth?: boolean;\n /**\n * @default absolute\n * @description\n * Specific position strategy to apply to the tooltip.\n * Might be usefull when dealing with edge case (see https://floating-ui.com/docs/misc#z-index-stacking).\n */\n // eslint-disable-next-line react/no-unused-prop-types\n floatingStrategy?: {\n web: WebFloatingPosition;\n };\n onUpdate?: (tooltipConfig: any) => void;\n}\n\n// eslint-disable-next-line unicorn/expiring-todo-comments\n// TODO : update position on scroll in future iteration\nexport function Tooltip({\n children,\n defaultVisible,\n position = tooltipDefaultPosition,\n content,\n floatingPadding,\n onUpdate,\n}: TooltipProps): ReactElement {\n const theme = useTheme();\n const padding = floatingPadding || theme.kitt.tooltip.floatingPadding;\n\n const pressed = useSharedValue(defaultVisible);\n\n const opacityStyles = useAnimatedStyle(() => {\n return {\n opacity: withSpring(pressed.value ? theme.kitt.tooltip.opacity : 0),\n };\n });\n\n const handlePress = (): void => {\n pressed.value = !pressed.value;\n };\n\n const { x, y, reference, floating, update, refs, middlewareData } = useFloating({\n placement: position,\n middleware: [offset(padding), shift(), flip({ padding })],\n });\n\n useEffect(() => {\n if (!onUpdate) return;\n onUpdate({\n x,\n y,\n reference,\n floating,\n strategy: 'absolute',\n update,\n refs,\n middlewareData,\n });\n }, [x, y, reference, floating, update, refs, middlewareData, onUpdate]);\n\n return (\n <TooltipContainer>\n <View ref={reference}>\n <Pressable accessibilityRole=\"button\" onPress={handlePress}>\n {children}\n </Pressable>\n </View>\n\n <View\n ref={floating}\n accessibilityElementsHidden={!pressed.value}\n importantForAccessibility={pressed.value === true ? 'auto' : 'no-hide-descendants'}\n style={{\n ...StyleSheet.absoluteFillObject,\n top: y && position === 'bottom' ? y : undefined,\n bottom: y && position === 'top' ? y : undefined,\n left: x ?? 0,\n }}\n >\n <Animated.View style={[opacityStyles]}>\n <TooltipView position={position}>{content}</TooltipView>\n </Animated.View>\n </View>\n </TooltipContainer>\n );\n}\n\nTooltip.View = TooltipView;\n","import type { ReactElement } from 'react';\nimport { Platform } from 'react-native';\nimport styled, { useTheme } from 'styled-components/native';\nimport { Emoji } from '../Emoji/Emoji';\nimport type { TypographyBreakpointTypesProps } from './Typography';\nimport {\n getTypographyTypeConfig,\n getTypographyTypeConfigKey,\n useTypographyTypeForCurrentWindowSize,\n} from './Typography';\n\nconst StyledTypographyEmoji = styled(Emoji)`\n align-self: center;\n\n ${({ size }) => {\n if (Platform.OS !== 'web') return undefined;\n\n /* Style Twemoji: https://github.com/twitter/twemoji#inline-styles */\n return `\n margin: 0 ${size / 20}px 0 ${size / 10}px;\n transform: translateY(${(size / 10) * 2}px);\n `;\n }}\n`;\n\nexport interface TypographyEmojiProps extends TypographyBreakpointTypesProps {\n emoji: string;\n}\n\nexport function TypographyEmoji({ emoji, base, small, medium, large }: TypographyEmojiProps): ReactElement {\n const theme = useTheme();\n const typeForCurrentWindowSize = useTypographyTypeForCurrentWindowSize(base, small, medium, large);\n const typeConfig = getTypographyTypeConfig(typeForCurrentWindowSize || 'body', theme);\n const typeConfigKey = getTypographyTypeConfigKey(theme);\n const { fontSize } = typeConfig[typeConfigKey];\n\n return <StyledTypographyEmoji size={fontSize} emoji={emoji} />;\n}\n","import { styled as styledLinaria } from '@linaria/react';\nimport type { ReactElement, ReactNode } from 'react';\nimport type { TextProps } from 'react-native';\nimport { Platform } from 'react-native';\nimport type { DefaultTheme } from 'styled-components/native';\nimport styled from 'styled-components/native';\nimport type { Except } from 'type-fest';\nimport { StyleWebWrapper } from '../utils/StyleWebWrapper';\nimport { withTheme } from '../utils/withTheme';\nimport type { TypographyPropsWithoutRole } from './Typography';\nimport { Typography } from './Typography';\n\ninterface TypographyLinkWebWrapperProps {\n theme: DefaultTheme;\n $hasNoUnderline?: boolean;\n}\n\nconst TypographyLinkWebWrapper = withTheme(styledLinaria.span<TypographyLinkWebWrapperProps>`\n & > *:hover,\n & > *:active,\n .kitt-hover & > * {\n text-decoration: none;\n }\n\n & > *:hover,\n & > *:active,\n .kitt-hover & > * {\n text-decoration: ${({ $hasNoUnderline }) => ($hasNoUnderline ? 'underline' : 'none')}\n }\n`);\n\ninterface StyledLinkProps {\n $disabled?: boolean;\n $hasNoUnderline?: boolean;\n}\n\nconst StyledLink = styled.Text<StyledLinkProps & TextProps>`\n text-decoration: ${({ $hasNoUnderline }) => ($hasNoUnderline ? 'none' : 'underline')};\n\n ${({ $disabled }) => {\n if (Platform.OS !== 'web') return undefined;\n\n return `\n text-decoration-color: inherit;\n transition: color 0.2s ease-in-out;\n cursor: ${$disabled ? 'not-allowed' : 'pointer'};\n `;\n }};\n\n ${({ $disabled, theme }) => {\n if (!$disabled) return undefined;\n return `color: ${theme.kitt.typography.link.disabledColor};`;\n }};\n`;\n\nexport interface TypographyLinkProps extends Except<TypographyPropsWithoutRole, 'children'> {\n children: NonNullable<ReactNode>;\n disabled?: boolean;\n noUnderline?: boolean;\n variant: NonNullable<TypographyPropsWithoutRole['variant']>;\n href?: TextProps['href'];\n hrefAttrs?: TextProps['hrefAttrs'];\n onPress: TextProps['onPress'];\n}\n\nexport function TypographyLink({\n children,\n disabled,\n noUnderline,\n href,\n hrefAttrs,\n onPress,\n ...otherProps\n}: TypographyLinkProps): ReactElement {\n return (\n <Typography {...otherProps} accessibilityRole=\"none\">\n <StyleWebWrapper as={TypographyLinkWebWrapper} $hasNoUnderline={noUnderline}>\n <StyledLink\n $disabled={disabled}\n $hasNoUnderline={noUnderline}\n href={href}\n hrefAttrs={hrefAttrs}\n accessibilityRole=\"link\"\n dataSet={{\n // remove data-kitt-universal when we delete kitt web. See See :global(a) in Link styles.module.css\n 'kitt-universal': 'true',\n }}\n onPress={disabled ? undefined : onPress}\n >\n {children}\n </StyledLink>\n </StyleWebWrapper>\n </Typography>\n );\n}\n","export const hex2rgba = (hex: string, alpha = 1): string => {\n const r = parseInt(hex.slice(1, 3), 16);\n const g = parseInt(hex.slice(3, 5), 16);\n const b = parseInt(hex.slice(5, 7), 16);\n\n return `rgba(${r}, ${g}, ${b}, ${alpha})`;\n};\n","import { makeDecorator } from '@storybook/addons';\nimport type { ReactElement, ReactNode } from 'react';\nimport { ThemeProvider } from 'styled-components/native';\nimport type { KittTheme } from '../../useKittTheme';\nimport { useKittTheme } from '../../useKittTheme';\n\ndeclare module 'styled-components' {\n export interface DefaultTheme extends KittTheme {}\n}\n\ninterface KittThemeProviderProps {\n children: ReactNode;\n}\n\nexport function KittThemeProvider({ children }: KittThemeProviderProps): ReactElement {\n const theme = useKittTheme();\n return <ThemeProvider theme={theme}>{children}</ThemeProvider>;\n}\n\nexport const KittThemeDecorator = makeDecorator({\n name: 'ThemeDecorator',\n parameterName: 'theme',\n wrapper: (storyFn, context, { options = {}, parameters = {} }) => {\n return <KittThemeProvider>{storyFn(context) as ReactNode}</KittThemeProvider>;\n },\n});\n","import type { ReactElement, ReactNode } from 'react';\nimport type { MatchWindowSizeOptions } from './useMatchWindowSize';\nimport { useMatchWindowSize } from './useMatchWindowSize';\n\ninterface MatchWindowSizeProps extends MatchWindowSizeOptions {\n children: ReactNode;\n}\n\nexport function MatchWindowSize({ children, ...matchWindowSizeOptions }: MatchWindowSizeProps): ReactElement | null {\n const match = useMatchWindowSize(matchWindowSizeOptions);\n if (!match) return null;\n return children as ReactElement;\n}\n"],"names":["defaultIconSize","IconContainer","styled","View","$color","$size","$align","Icon","icon","size","align","color","clonedIcon","cloneElement","_jsx","KittBreakpoints","BASE","SMALL","MEDIUM","LARGE","WIDE","KittBreakpointsMax","IsHeaderTypographyContext","createContext","undefined","TypographyColorContext","useTypographyColor","useContext","getTypographyTypeConfigKey","theme","isMediumOrAbove","responsive","matchWindowSize","minWidth","isTypeHeader","type","startsWith","isTypographyHeader","typographyIsHeaderInContext","Error","getTypographyTypeConfig","kitt","typography","types","headers","configs","bodies","StyledTypography","Text","$isHeader","$typeForCurrentWindowSize","$variant","typeConfigKey","fontFamily","fontSize","lineHeight","fontWeight","fontStyle","css","colors","useTypographyTypeForCurrentWindowSize","base","small","medium","large","width","useWindowDimensions","getTypographyInheritedOrDefaultValuesBasedOnExistingAncestors","hasTypographyAncestor","Typography","accessibilityRole","variant","otherProps","isHeaderTypographyInContext","baseOrDefaultToBody","colorOrDefaultToBlack","typeForCurrentWindowSize","isHeader","nonNullableVariant","content","TypographyText","props","TypographyParagraph","Platform","OS","createHeading","level","defaultBase","TypographyHeading","displayName","Paragraph","Header1","Header2","Header3","Header4","Header5","Header6","h1","h2","h3","h4","h5","getInitials","firstname","lastname","toUpperCase","StyledAvatarView","$isRound","$sizeVariant","avatar","borderRadius","$isLight","light","backgroundColor","default","AvatarContent","src","alt","isLight","sizeVariant","Image","uri","height","UserIcon","Avatar","round","hasVariant","button","getVariantValuesIfExist","StyledPressable","Pressable","$isStretch","StyledAnimatedView","Animated","AnimatedButtonPressable","forwardRef","children","disabled","$type","href","hrefAttrs","testID","onPress","ref","useTheme","pressed","useSharedValue","pressedBackgroundColor","scale","scaleStyles","useAnimatedStyle","interpolateColor","value","transform","withSpring","active","handlePressInOut","pressIn","BaseStyledButtonPressable","maxWidth","minHeight","$isDisabled","$isLarge","defaultPadding","disabledPadding","contentPadding","TypographyIconSpecifiedColor","TypographyIconInheritColor","TypographyIcon","isSubtle","getTextColorByType","StyledButtonText","StyledIconContainer","$iconPosition","spacing","ButtonIcon","iconPosition","StyledChildrenWithIcon","ButtonContentChildren","isDisabled","isWebSubtle","buttonIconSharedProps","_jsxs","ButtonContentContainer","$isIconOnly","$isSubtle","ButtonContent","Boolean","StyledDisabled","borderWidth","borderColor","Button","stretch","__DEV__","Container","card","Card","StyledEmoji","Emoji","emoji","style","emojiData","useMemo","parse","assetType","text","url","defaultOpenLinkBehavior","native","web","ExternalLink","as","Component","openLinkBehavior","rest","e","defaultPrevented","WebBrowser","catch","err","console","error","Linking","openURL","lateOceanColorPalette","lateOcean","lateOceanLight1","lateOceanLight2","lateOceanLight3","warmEmbrace","warmEmbraceLight1","black1000","black800","black555","black200","black100","black50","black25","white","viride","englishVermillon","goldCrayola","aero","transparent","moonPurple","moonPurpleLight1","primary","primaryLight","accent","accentLight","success","correct","danger","info","warning","separator","hover","black","blackAnthracite","uiBackground","uiBackgroundLight","overlay","dark","fullscreenLoader","focus","transition","duration","timingFunction","hoverBackgroundColor","focusBorderColor","ghost","hoverColor","activeColor","subtle","secondary","feedbackMessage","checkbox","iconSize","checkedBorderColor","checkedBackgroundColor","markColor","datePicker","day","month","year","calcLineHeight","lineHeightMultiplier","Math","createTypographyTypeConfig","baseAndSmallFontSize","mediumAndWideFontSize","baseAndSmall","mediumAndWide","kittColors","regular","bold","header1","header2","header3","header4","header5","body","link","disabledColor","inputStatesStyle","pending","valid","invalid","input","selection","placeholder","padding","iOSSingleLine","property","states","inputField","labelContainerPaddingBottom","iconMarginLeft","inputTag","labelColor","radio","unchecked","checked","innerSize","innerBackgroundColor","textArea","forms","fullScreenModal","header","paddingVertical","paddingHorizontal","iconButton","listItem","innerMargin","pageLoader","shadows","skeleton","flareColor","animationDuration","tag","fill","outline","tooltip","opacity","horizontalPadding","verticalPadding","floatingPadding","breakpoints","values","wide","min","smallBreakpoint","mediumBreakpoint","largeBreakpoint","wideBreakpoint","max","palettes","maxHeight","hasWidthMatched","hasHeightMatched","useMatchWindowSize","options","createWindowSizeHelper","dimensions","ifWindowSizeMatches","valueIfTrue","valueIfFalse","mapWindowWidth","widthList","slice","forEach","index","previousMinWidth","found","find","Number","useKittTheme","useWindowSize","kittTheme","CheckboxAndLabelPressableWrapper","CheckboxContainer","$isChecked","$hasLabel","Checkbox","onChange","onBlur","onFocus","hitSlop","id","CheckboxMark","getInputUIState","isFocused","formState","styledTextInputMixin","$state","StyledTypographyText","ViewInput","$partName","DatePickerInputPart","partName","prefixWithZero","padStart","PartContainer","$isLast","DatePickerPressable","DatePickerInputs","state","internalForceState","handleModalOpen","currentValue","currentState","sharedPartProps","getDate","getMonth","getFullYear","DatePickerAndroid","pickerDefaultDate","pickerUITestID","setIsFocused","setCurrentValue","handleClose","DateTimePickerAndroid","open","Date","now","timestamp","nativeEvent","date","onTouchCancel","OverlayPressable","StyleSheet","absoluteFillObject","Overlay","BodyView","ModalBody","ScrollView","FooterView","ModalFooter","StyleWebWrapper","withTheme","WrappedComponent","PressableIconButtonWebWrapper","$isWhite","defaultIconButton","StyledPressableIconButton","PressableIconButton","AnimatedIconButtonBackground","AnimatedViewContainer","PressableAnimatedContainer","accessibilityLabel","opacityStyles","IconButtonContentBorder","IconButtonContent","IconButton","OnCloseContext","HeaderView","LeftIconView","RightIconView","TitleView","isIconLeft","ModalHeader","left","right","onClose","XIcon","ModalView","ContentView","Modal","visible","onEntered","onExited","NativeModal","Header","Body","Footer","getDatePickerDisplayMode","PlatformDateTimePicker","defaultDate","maximumDate","minimuDate","displayMode","iosProps","textColor","DateTimePicker","_event","ModalTitle","ModalPlatformDateTimePicker","title","isVisible","validateButtonLabel","useState","newDate","prev","FormattedMessage","DatePicker","pickerUITitle","pickerUIValidateButtonLabel","isPickerUIVisible","setIsPickerUIVisible","handleModalClose","InputTextContainer","StyledTextInput","TextInput","multiline","$minHeight","RightInputContainer","InputText","autoCorrect","textContentType","autoCompleteType","keyboardType","onSubmitEditing","InputEmail","getColorFromState","InputFeedback","FieldContainer","FeedbackContainer","FieldLabelContainer","LabelContainer","InputField","label","labelFeedback","feedback","getIconColor","InputIcon","InputPressable","InputPassword","isPasswordDefaultVisible","setIsVisible","EyeOffIcon","EyeIcon","InputPhone","getTypographyColor","InputTagContainer","InputTag","typographyColor","Label","htmlFor","OuterRadio","SelectedOuterRadio","SelectedInnerRadio","Radio","TextArea","FullScreenModalBody","SideContainer","side","getHeaderHorizontalMediumPadding","insetTop","paddingTop","HeaderContent","leftWidth","rightWidth","windowWidth","sideElementMaxWidth","parentHorizontalPadding","parentHorizontalPaddingMedium","computeWidth","breakpointPadding","deltaMargin","abs","FullScreenModalHeader","top","useSafeAreaInsets","setLeftWidth","setRightWidth","handleLayoutChange","event","persist","layout","FullScreenModal","SpinningIcon","process","env","NODE_ENV","String","animationRef","useRef","Value","rotation","current","interpolate","inputRange","outputRange","useEffect","animation","loop","timing","toValue","easing","Easing","linear","useNativeDriver","start","stop","rotate","ListItemContent","SideContainerView","ListItemSideContainer","SideContentView","ListItemSideContent","ContainerView","withPadding","borders","ListItem","Wrapper","Fragment","wrapperProps","containerProps","Content","SideContent","LoaderIcon","ArcIcon","IconContent","AlertCircleIcon","CheckIcon","AlertTriangleIcon","InfoIcon","getColorByType","getIconButtonColor","messageType","StyledMessageContainer","$insets","$hasNoRadius","StyledDismissWrapper","StyledTextContent","$isCenteredText","StyledMessageContent","BaseMessage","hasNoRadius","centeredText","insets","onDismiss","Message","Notification","onDelete","getActivityIndicatorSize","PageLoader","colorHex","ActivityIndicator","AnimatedLinearGradient","createAnimatedComponent","LinearGradient","SkeletonContent","isLoading","sharedX","withRepeat","withTiming","inOut","ease","linearGradientStyle","translateX","x","y","absoluteFill","SkeletonContainer","Skeleton","setWidth","Bar","Circle","Square","Flex","withConfig","shouldForwardProp","prop","defaultValidatorFn","includes","direction","storyPadding","getBackgroundColorFromBlockColor","getTypographyColorFromBlockColor","StoryBlockBackgroundContext","StoryBlockColorContext","useStoryBlockColor","storyBlockColor","StyledStoryBlockView","background","StoryBlock","StoryTitleContainer","StorySubTitleContainer","StoryTitle","numberOfLines","StoryTitleLevel2","StoryTitleLevel3","StoryTitleLevel4","Level2","Level3","Level4","StoryContainer","Story","contentContainerStyle","StyledSection","StorySection","internalIsDemoSection","StyledSubSection","SubSection","StyledBlockSection","BlockSection","StyledDemoSection","DemoSection","Demo","DeprecatedSection","platform","StoryDecorator","storyFn","context","name","SmallScreenRow","SmallScreenCol","FlexRow","FlexCol","StoryGridRow","breakpoint","breakpointValue","Children","map","child","StoryGridCol","titleColor","isNative","StoryGrid","Row","Col","getLabelColor","Tag","Title","ModalDateTimePicker","timePickerPlaceholder","formatNumberToTimeString","time","formatDateToTimeString","getHours","getMinutes","useTimePicker","defaultValue","isTimePickerModalVisible","setIsTimePickerModalVisible","todayAtNoon","getDay","dateTimePickerValue","displayedValue","timePickerState","handleInputPress","handleTimeChange","TimePicker","forceDefaultValue","StyledTooltipView","StyledTooltipContent","ArrowView","TooltipArrowIcon","StyledArrow","$position","TooltipView","position","tooltipDefaultPosition","TooltipContainer","Tooltip","defaultVisible","onUpdate","reference","floating","update","refs","middlewareData","useFloating","placement","middleware","offset","shift","flip","strategy","bottom","StyledTypographyEmoji","TypographyEmoji","typeConfig","TypographyLinkWebWrapper","$hasNoUnderline","StyledLink","$disabled","TypographyLink","noUnderline","hex2rgba","hex","alpha","r","parseInt","g","b","KittThemeProvider","ThemeProvider","KittThemeDecorator","makeDecorator","parameterName","wrapper","parameters","MatchWindowSize","matchWindowSizeOptions","match"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAmBO,MAAMA,eAAe,GAAG,EAAxB;AAEA,MAAMC,eAAa,gBAAGC,eAAM,CAACC,IAAV;AAAA;AAAA;AAAA,+DACf,CAAC;AAAEC,EAAAA;AAAF,CAAD,KAAgBA,MADD,EAEf,CAAC;AAAEC,EAAAA;AAAF,CAAD,KAAeA,KAFA,EAGd,CAAC;AAAEA,EAAAA;AAAF,CAAD,KAAeA,KAHD,EAIV,CAAC;AAAEC,EAAAA,MAAM,GAAG;AAAX,CAAD,KAAyBA,MAJf,CAAnB;AAOA,SAASC,IAAT,CAAc;AAAEC,EAAAA,IAAF;AAAQC,EAAAA,IAAI,GAAGT,eAAf;AAAgCU,EAAAA,KAAhC;AAAuCC,EAAAA;AAAvC,CAAd,EAAuF;AAC5F,QAAMC,UAAU,gBAAGC,kBAAY,CAACL,IAAD,EAAO;AAAEG,IAAAA;AAAF,GAAP,CAA/B;AAEA,sBACEG,eAACb,eAAD;AAAe,IAAA,MAAM,EAAES,KAAvB;AAA8B,IAAA,KAAK,EAAED,IAArC;AAA2C,IAAA,MAAM,EAAEE,KAAnD;AAAA,cACGC;AADH,IADF;AAKD;;MCpCYG,eAAe,GAAG;AAC7B;AACF;AACA;AACEC,EAAAA,IAAI,EAAE,CAJuB;;AAK7B;AACF;AACA;AACEC,EAAAA,KAAK,EAAE,GARsB;;AAS7B;AACF;AACA;AACEC,EAAAA,MAAM,EAAE,GAZqB;;AAa7B;AACF;AACA;AACEC,EAAAA,KAAK,EAAE,IAhBsB;;AAiB7B;AACF;AACA;AACEC,EAAAA,IAAI,EAAE;AApBuB;MAuBlBC,kBAAkB,GAAG;AAChC;AACF;AACA;AAC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akpoints.ts","../src/typography/Typography.tsx","../src/Avatar/Avatar.tsx","../src/Button/getVariantValuesIfExist.ts","../src/Button/AnimatedButtonPressable.tsx","../src/Button/BaseStyledButtonPressable.tsx","../src/typography/TypographyIcon.tsx","../src/Button/isSubtle.ts","../src/Button/ButtonContent.tsx","../src/Button/StyledDisabled.tsx","../src/Button/Button.tsx","../src/Card/Card.tsx","../src/Emoji/Emoji.tsx","../src/ExternalLink/ExternalLinkOpenLinkBehavior.ts","../src/ExternalLink/ExternalLink.tsx","../src/themes/palettes/lateOceanColorPalette.ts","../src/themes/late-ocean/colors.ts","../src/themes/late-ocean/avatar.ts","../src/themes/late-ocean/button.ts","../src/themes/late-ocean/card.ts","../src/themes/late-ocean/feedback.ts","../src/themes/late-ocean/checkbox.ts","../src/themes/late-ocean/datePicker.ts","../src/themes/late-ocean/typography.ts","../src/themes/late-ocean/input.ts","../src/themes/late-ocean/inputField.ts","../src/themes/late-ocean/inputTag.ts","../src/themes/late-ocean/radio.ts","../src/themes/late-ocean/textArea.ts","../src/themes/late-ocean/forms.ts","../src/themes/late-ocean/fullScreenModal.ts","../src/themes/late-ocean/iconButton.ts","../src/themes/late-ocean/listItem.ts","../src/themes/late-ocean/pageLoader.ts","../src/themes/late-ocean/shadows.ts","../src/themes/late-ocean/skeleton.ts","../src/themes/late-ocean/tag.ts","../src/themes/late-ocean/tooltip.ts","../src/themes/default.ts","../src/utils/windowSize/useMatchWindowSize.ts","../src/utils/windowSize/createWindowSizeHelper.ts","../src/useKittTheme.tsx","../src/forms/Checkbox/Checkbox.tsx","../src/forms/utils.ts","../src/forms/styledTextInputMixin.ts","../src/forms/DatePicker/DatePickerInputPart.tsx","../src/forms/DatePicker/DatePickerInputs.tsx","../src/forms/DatePicker/DatePickerAndroid.tsx","../src/Overlay/Overlay.tsx","../src/Modal/Body.tsx","../src/Modal/Footer.tsx","../src/utils/StyleWebWrapper.tsx","../src/utils/withTheme.tsx","../src/IconButton/PressableIconButton.tsx","../src/IconButton/PressableAnimatedContainer.tsx","../src/IconButton/IconButton.tsx","../src/Modal/OnCloseContext.ts","../src/Modal/Header.tsx","../src/Modal/Modal.tsx","../src/forms/DatePicker/PlatformDateTimePicker.tsx","../src/forms/DatePicker/ModalPlatformDateTimePicker.tsx","../src/forms/DatePicker/DatePicker.tsx","../src/forms/InputText/InputTextContainer.tsx","../src/forms/InputText/InputText.tsx","../src/forms/InputEmail/InputEmail.tsx","../src/forms/InputFeedback/InputFeedback.tsx","../src/forms/InputField/InputField.tsx","../src/forms/InputIcon/InputIcon.tsx","../src/forms/InputPressable/InputPressable.tsx","../src/forms/InputPassword/InputPassword.tsx","../src/forms/InputPhone/InputPhone.tsx","../src/forms/InputTag/InputTag.tsx","../src/forms/Label/Label.tsx","../src/forms/Radio/Radio.tsx","../src/forms/TextArea/TextArea.tsx","../src/FullScreenModal/Body.tsx","../src/FullScreenModal/Header.tsx","../src/FullScreenModal/FullScreenModal.tsx","../src/Icon/SpinningIcon.tsx","../src/ListItem/ListItemContent.tsx","../src/ListItem/ListItemSideContent.tsx","../src/ListItem/ListItem.tsx","../src/LoaderIcon/LoaderIcon.tsx","../src/BaseMessage/IconContent.tsx","../src/BaseMessage/helper.ts","../src/BaseMessage/BaseMessage.tsx","../src/Message/Message.tsx","../src/Notification/Notification.tsx","../src/PageLoader/AnimatedLoaderCircle.tsx","../src/PageLoader/AnimatedBackgroundCircle.tsx","../src/PageLoader/AnimatedFillCircleContainer.tsx","../src/PageLoader/AnimatedFillCircle.tsx","../src/PageLoader/PageLoader.tsx","../src/Skeleton/SkeletonContent.tsx","../src/Skeleton/Skeleton.tsx","../src/story-components/Flex.tsx","../src/story-components/theme.ts","../src/story-components/StoryBlock.tsx","../src/story-components/StoryTitle.tsx","../src/story-components/Story.tsx","../src/story-components/StorySection.tsx","../src/story-components/StoryContainer.tsx","../src/story-components/StoryDecorator.tsx","../src/story-components/StoryGrid.tsx","../src/Tag/Tag.tsx","../src/TimePicker/ModalDateTimePicker.tsx","../src/TimePicker/useTimePicker.ts","../src/TimePicker/TimePicker.tsx","../src/Tooltip/TooltipView.tsx","../src/Tooltip/tooltipUtils.ts","../src/Tooltip/Tooltip.tsx","../src/typography/TypographyEmoji.tsx","../src/typography/TypographyLink.tsx","../src/utils/hexToRgba.ts","../src/utils/storybook/KittThemeDecorator.tsx","../src/utils/windowSize/MatchWindowSize.tsx"],"sourcesContent":["import type { ReactElement } from 'react';\nimport { cloneElement } from 'react';\nimport type { ViewStyle } from 'react-native';\nimport styled from 'styled-components/native';\n\nexport interface IconProps {\n icon: ReactElement;\n size?: number;\n color: string;\n align?: ViewStyle['alignSelf'];\n testID?: ViewStyle['testID'];\n}\n\ninterface IconContainerProps {\n $align?: ViewStyle['alignSelf'];\n $size: number;\n $color: string;\n}\n\nexport const defaultIconSize = 20;\n\nexport const IconContainer = styled.View<IconContainerProps>`\n color: ${({ $color }) => $color};\n width: ${({ $size }) => $size}px;\n height: ${({ $size }) => $size}px;\n align-self: ${({ $align = 'auto' }) => $align};\n`;\n\nexport function Icon({ icon, size = defaultIconSize, align, color }: IconProps): ReactElement {\n const clonedIcon = cloneElement(icon, { color });\n\n return (\n <IconContainer $align={align} $size={size} $color={color}>\n {clonedIcon}\n </IconContainer>\n );\n}\n","export const KittBreakpoints = {\n /**\n * min-width: 0\n */\n BASE: 0,\n /**\n * min-width: 480px\n */\n SMALL: 480,\n /**\n * min-width: 768px\n */\n MEDIUM: 768,\n /**\n * min-width: 1024px\n */\n LARGE: 1024,\n /**\n * min-width: 1280px\n */\n WIDE: 1280,\n};\n\nexport const KittBreakpointsMax = {\n /**\n * max-width: 479px\n */\n BASE: KittBreakpoints.SMALL - 1,\n /**\n * max-width: 767px\n */\n SMALL: KittBreakpoints.MEDIUM - 1,\n /**\n * max-width: 1023px\n */\n MEDIUM: KittBreakpoints.LARGE - 1,\n /**\n * max-width: 1279px\n */\n LARGE: KittBreakpoints.WIDE - 1,\n};\n\nexport type KittBreakpoint = typeof KittBreakpoints[keyof typeof KittBreakpoints];\nexport type KittBreakpointMax = typeof KittBreakpointsMax[keyof typeof KittBreakpointsMax];\n","import type { FC, ReactElement, ReactNode } from 'react';\nimport { createContext, useContext } from 'react';\nimport type { TextProps } from 'react-native';\nimport { Platform, useWindowDimensions } from 'react-native';\nimport type { DefaultTheme } from 'styled-components/native';\nimport styled, { css } from 'styled-components/native';\nimport type { Except, SetOptional } from 'type-fest';\nimport { KittBreakpoints } from '../KittBreakpoints';\nimport type { TypographyTypeConfig } from '../themes/late-ocean/typography';\nimport type { KittTheme } from '../useKittTheme';\n\nexport type TypographyHeaderType = `header${'1' | '2' | '3' | '4' | '5'}`;\nexport type TypographyBodyType = 'body' | `body-${'large' | 'medium' | 'small' | 'xsmall'}`;\nexport type TypographyType = TypographyHeaderType | TypographyBodyType;\ntype TypographyVariant = 'regular' | 'bold';\nexport type TypographyColor =\n | 'black'\n | 'black-anthracite'\n | 'black-light'\n | 'white'\n | 'white-light'\n | 'primary'\n | 'primary-light'\n | 'accent'\n | 'success'\n | 'danger';\n\nconst IsHeaderTypographyContext = createContext<boolean | undefined>(undefined);\nconst TypographyColorContext = createContext<TypographyColor>('black');\n\nexport function useTypographyColor(): TypographyColor {\n return useContext(TypographyColorContext);\n}\n\nexport const getTypographyTypeConfigKey = (theme: KittTheme): keyof TypographyTypeConfig => {\n const isMediumOrAbove = theme.responsive.matchWindowSize({ minWidth: KittBreakpoints.MEDIUM });\n return isMediumOrAbove ? 'mediumAndWide' : 'baseAndSmall';\n};\n\nconst isTypeHeader = (type: TypographyType): type is TypographyHeaderType => type.startsWith('header');\nexport const isTypographyHeader = (\n type: TypographyType | undefined,\n typographyIsHeaderInContext: boolean | undefined,\n): type is TypographyHeaderType => {\n if (type) return isTypeHeader(type);\n if (typographyIsHeaderInContext != null) return typographyIsHeaderInContext;\n throw new Error('You must set a \"base\" prop or wrap this Typography in one that does.');\n};\n\nexport function getTypographyTypeConfig(type: TypographyType, theme: DefaultTheme): TypographyTypeConfig {\n if (isTypographyHeader(type, undefined)) {\n return theme.kitt.typography.types.headers.configs[type];\n }\n\n return theme.kitt.typography.types.bodies.configs[type];\n}\n\ninterface StyledTypographyProps {\n accessibilityRole: TextProps['accessibilityRole'] | 'paragraph';\n $isHeader: boolean;\n $typeForCurrentWindowSize?: TypographyType;\n $variant: TypographyVariant;\n $color?: TypographyColor;\n}\n\nconst StyledTypography = styled.Text<StyledTypographyProps>`\n /* font */\n ${({ theme, $isHeader, $typeForCurrentWindowSize, $variant }) => {\n const { headers, bodies } = theme.kitt.typography.types;\n const typeConfigKey = getTypographyTypeConfigKey(theme);\n\n return `\n /* type */\n ${\n !$typeForCurrentWindowSize\n ? ''\n : `\n font-family: ${$isHeader ? headers.fontFamily[$variant] : bodies.fontFamily[$variant]};\n font-size: ${\n $isHeader\n ? headers.configs[$typeForCurrentWindowSize as TypographyHeaderType][typeConfigKey].fontSize\n : bodies.configs[$typeForCurrentWindowSize as TypographyBodyType][typeConfigKey].fontSize\n }px;\n line-height: ${\n $isHeader\n ? headers.configs[$typeForCurrentWindowSize as TypographyHeaderType][typeConfigKey].lineHeight\n : bodies.configs[$typeForCurrentWindowSize as TypographyBodyType][typeConfigKey].lineHeight\n }px;\n `\n }\n\n /* variant */\n font-weight: ${$isHeader ? headers.fontWeight : bodies.fontWeight[$variant]};\n font-style: ${$isHeader ? headers.fontStyle : bodies.fontStyle[$variant]};\n `;\n }}\n\n /* color */\n ${({ theme, $color }) => {\n if (!$color) return '';\n\n return css`\n color: ${theme.kitt.typography.colors[$color]};\n text-decoration-color: ${theme.kitt.typography.colors[$color]};\n `;\n }}\n`;\n\nexport interface TypographyBreakpointTypesProps {\n /** base type. Inherited from parent Typography if not specified */\n base?: TypographyType;\n /** small type. use base if undefined */\n small?: TypographyType;\n /** medium type. use small or base if undefined */\n medium?: TypographyType;\n /** large type. use medium or small or base if undefined */\n large?: TypographyType;\n}\n\nexport interface TypographyProps extends TypographyBreakpointTypesProps, Except<TextProps, 'accessibilityRole'> {\n // Find mapping for web here: https://www.w3.org/TR/html-aria/\n accessibilityRole: NonNullable<TextProps['accessibilityRole']> | 'paragraph' | null;\n /** Default to regular for bodies and bold of headers. Is not inherited. */\n variant?: TypographyVariant;\n /** Inherited from parent Typography if not specified, or black if no Typography parent found. */\n color?: TypographyColor;\n children: ReactNode;\n}\nexport type TypographyPropsWithoutRole = Except<TypographyProps, 'accessibilityRole'>;\n\nexport function useTypographyTypeForCurrentWindowSize(\n base: TypographyType | undefined,\n small: TypographyType | undefined,\n medium: TypographyType | undefined,\n large: TypographyType | undefined,\n): TypographyType | undefined {\n const { width } = useWindowDimensions();\n if (large && width >= KittBreakpoints.LARGE) return large;\n if (medium && width >= KittBreakpoints.MEDIUM) return medium;\n if (small && width >= KittBreakpoints.SMALL) return small;\n return base;\n}\n\ntype GetTypographyInheritedOrDefaultValuesBasedOnExistingAncestorsProps = Pick<TypographyProps, 'base' | 'color'>;\n\nexport function getTypographyInheritedOrDefaultValuesBasedOnExistingAncestors(\n hasTypographyAncestor: boolean,\n { base, color }: GetTypographyInheritedOrDefaultValuesBasedOnExistingAncestorsProps,\n): GetTypographyInheritedOrDefaultValuesBasedOnExistingAncestorsProps {\n // return the props set or undefined. In case of undefined, the value will be inherited from its parents.\n if (hasTypographyAncestor) return { base, color };\n\n return {\n base: base ?? 'body',\n color: color ?? 'black',\n };\n}\n\nexport function Typography({\n accessibilityRole,\n base,\n small,\n medium,\n large,\n variant,\n color,\n ...otherProps\n}: TypographyProps): ReactElement | null {\n const isHeaderTypographyInContext = useContext(IsHeaderTypographyContext);\n const hasTypographyAncestor = isHeaderTypographyInContext !== undefined;\n const { base: baseOrDefaultToBody, color: colorOrDefaultToBlack } =\n getTypographyInheritedOrDefaultValuesBasedOnExistingAncestors(hasTypographyAncestor, {\n base,\n color,\n });\n const typeForCurrentWindowSize = useTypographyTypeForCurrentWindowSize(baseOrDefaultToBody, small, medium, large);\n const isHeader = isTypographyHeader(typeForCurrentWindowSize, isHeaderTypographyInContext);\n const nonNullableVariant: TypographyVariant = variant ?? (isHeader ? 'bold' : 'regular');\n\n const content = baseOrDefaultToBody ? (\n <IsHeaderTypographyContext.Provider value={isHeader}>\n <StyledTypography\n $color={colorOrDefaultToBlack}\n $isHeader={isHeader}\n $typeForCurrentWindowSize={typeForCurrentWindowSize}\n $variant={nonNullableVariant}\n accessibilityRole={(accessibilityRole as TextProps['accessibilityRole']) || undefined}\n {...otherProps}\n />\n </IsHeaderTypographyContext.Provider>\n ) : (\n <StyledTypography\n $color={colorOrDefaultToBlack}\n $isHeader={isHeader}\n $variant={nonNullableVariant}\n accessibilityRole={(accessibilityRole as TextProps['accessibilityRole']) || undefined}\n {...otherProps}\n />\n );\n\n return color ? <TypographyColorContext.Provider value={color}>{content}</TypographyColorContext.Provider> : content;\n}\n\nexport type TypographyTextProps = SetOptional<TypographyProps, 'accessibilityRole'>;\nfunction TypographyText(props: TypographyTextProps): ReactElement {\n return <Typography accessibilityRole={null} {...props} />;\n}\n\nfunction TypographyParagraph(props: TypographyTextProps): ReactElement {\n // role 'paragraph' does not exist in native, it's a web feature only.\n return <Typography accessibilityRole={Platform.OS === 'web' ? 'paragraph' : null} {...props} />;\n}\n\nexport type TypographyHeadingProps = TypographyPropsWithoutRole;\n\nconst createHeading = (\n level: number,\n /** @deprecated accessibility and design should be independent */\n defaultBase?: TypographyHeadingProps['base'],\n): FC<TypographyHeadingProps> => {\n // https://github.com/necolas/react-native-web/issues/401\n function TypographyHeading(props: TypographyHeadingProps): ReactElement {\n return <Typography accessibilityRole=\"header\" base={defaultBase} {...props} accessibilityLevel={level} />;\n }\n TypographyHeading.displayName = `TypographyHeading${level}`;\n return TypographyHeading;\n};\n\nTypography.Text = TypographyText;\nTypography.Paragraph = TypographyParagraph;\nTypography.Header1 = createHeading(1);\nTypography.Header2 = createHeading(2);\nTypography.Header3 = createHeading(3);\nTypography.Header4 = createHeading(4);\nTypography.Header5 = createHeading(5);\nTypography.Header6 = createHeading(6);\n\n/** @deprecated use Typography.Header1 */\nTypography.h1 = createHeading(1, 'header1');\n/** @deprecated use Typography.Header2 */\nTypography.h2 = createHeading(2, 'header2');\n/** @deprecated use Typography.Header3 */\nTypography.h3 = createHeading(3, 'header3');\n/** @deprecated use Typography.Header4 */\nTypography.h4 = createHeading(4, 'header4');\n/** @deprecated use Typography.Header6 */\nTypography.h5 = createHeading(5, 'header5');\n","import { UserIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement } from 'react';\nimport { Image } from 'react-native';\nimport styled from 'styled-components/native';\nimport { Icon } from '../Icon/Icon';\nimport { Typography } from '../typography/Typography';\n\nconst getInitials = (firstname: string, lastname: string): string => `${firstname[0]}${lastname[0]}`.toUpperCase();\n\nexport type AvatarSizeVariant = 'large';\n\nexport interface StyledAvatarViewProps {\n $size: number;\n $isRound?: boolean;\n $isLight?: boolean;\n $sizeVariant?: AvatarSizeVariant;\n}\n\nconst StyledAvatarView = styled.View<StyledAvatarViewProps>`\n border-radius: ${({ theme, $isRound, $size, $sizeVariant }) => {\n if ($isRound) return `${$size / 2}px`;\n\n return `${$sizeVariant === 'large' ? theme.kitt.avatar.large.borderRadius : theme.kitt.avatar.borderRadius}px`;\n }};\n background-color: ${({ theme, $isLight }) =>\n $isLight ? theme.kitt.avatar.light.backgroundColor : theme.kitt.avatar.default.backgroundColor};\n height: ${({ $size }) => $size}px;\n width: ${({ $size }) => $size}px;\n overflow: hidden;\n align-items: center;\n justify-content: center;\n`;\n\ninterface AvatarContentProps extends Exclude<AvatarProps, 'light | round'> {\n size: NonNullable<number>;\n isLight?: boolean;\n sizeVariant?: AvatarSizeVariant;\n}\n\nfunction AvatarContent({\n size,\n src,\n firstname,\n lastname,\n alt,\n isLight,\n sizeVariant,\n}: AvatarContentProps): ReactElement {\n if (src) {\n return <Image source={{ uri: src }} style={{ width: size, height: size }} accessibilityLabel={alt} />;\n }\n\n if (firstname && lastname) {\n return (\n <Typography.Text\n base={sizeVariant === 'large' ? 'body-large' : 'body-small'}\n variant={sizeVariant === 'large' ? 'bold' : 'regular'}\n color={isLight ? 'black' : 'white'}\n >\n {getInitials(firstname, lastname)}\n </Typography.Text>\n );\n }\n\n return <Icon icon={<UserIcon />} color={isLight ? 'black' : 'white'} size={size / 2} />;\n}\nexport interface AvatarProps {\n size?: number;\n src?: string | null;\n alt?: string;\n firstname?: string | null;\n lastname?: string | null;\n round?: boolean;\n light?: boolean;\n sizeVariant?: AvatarSizeVariant;\n}\n\nexport function Avatar({ size = 40, round, light, sizeVariant, ...props }: AvatarProps): ReactElement {\n return (\n <StyledAvatarView $size={size} $isRound={round} $isLight={light} $sizeVariant={sizeVariant}>\n <AvatarContent size={size} isLight={light} sizeVariant={sizeVariant} {...props} />\n </StyledAvatarView>\n );\n}\n","import type { DefaultTheme } from 'styled-components/native';\nimport type { BaseButtonTheme, BaseButtonWithVariant } from '../themes/late-ocean/button';\nimport type { ButtonType, ButtonVariant } from './Button';\n\nconst hasVariant = (button: BaseButtonTheme, variant: ButtonVariant): button is BaseButtonWithVariant => {\n return variant in button;\n};\n\nexport function getVariantValuesIfExist<V extends ButtonVariant>(\n theme: DefaultTheme,\n type: ButtonType,\n variant: ButtonVariant,\n): BaseButtonTheme['default'] | BaseButtonWithVariant[V] {\n const button = theme.kitt.button[type];\n\n if (hasVariant(button, variant)) {\n return button[variant];\n }\n\n return theme.kitt.button[type].default;\n}\n","import type { ReactElement } from 'react';\nimport { forwardRef } from 'react';\nimport type { PressableProps, View } from 'react-native';\nimport Animated, { interpolateColor, useAnimatedStyle, useSharedValue, withSpring } from 'react-native-reanimated';\nimport styled, { useTheme } from 'styled-components/native';\nimport type { ButtonType, ButtonVariant } from './Button';\nimport { getVariantValuesIfExist } from './getVariantValuesIfExist';\n\nexport interface StyledPressableProps extends PressableProps {\n $isStretch?: boolean;\n $type: ButtonType;\n}\n\nconst StyledPressable = styled.Pressable<StyledPressableProps>`\n ${({ $isStretch }) => {\n if ($isStretch) return undefined;\n\n return 'align-self: flex-start;';\n }}\n`;\n\nconst StyledAnimatedView = styled(Animated.View)`\n border-radius: ${({ theme }) => theme.kitt.button.borderRadius}px;\n`;\n\nexport interface AnimatedButtonPressableProps extends PressableProps {\n accessibilityRole: NonNullable<PressableProps['accessibilityRole']>;\n $type: ButtonType;\n $variant: ButtonVariant;\n $isStretch?: boolean;\n}\n\nexport const AnimatedButtonPressable = forwardRef<View, AnimatedButtonPressableProps>(\n (\n {\n children,\n disabled,\n accessibilityRole,\n $type,\n $variant,\n $isStretch,\n href,\n hrefAttrs,\n testID,\n onPress,\n }: AnimatedButtonPressableProps,\n ref,\n ): ReactElement => {\n const theme = useTheme();\n const pressed = useSharedValue<0 | 1>(0);\n const color = useSharedValue(0);\n\n const { backgroundColor, pressedBackgroundColor } = getVariantValuesIfExist(theme, $type, $variant);\n const { scale } = theme.kitt.button;\n\n const scaleStyles = useAnimatedStyle(() => {\n return {\n backgroundColor: interpolateColor(color.value, [0, 1], [backgroundColor, pressedBackgroundColor]),\n transform: [\n {\n scale: withSpring(pressed.value ? scale.base.active : scale.base.default),\n },\n ],\n };\n });\n\n const handlePressInOut = (pressIn: boolean): void => {\n color.value = withSpring(pressIn ? 1 : 0);\n pressed.value = pressIn ? 1 : 0;\n };\n\n return (\n <StyledPressable\n ref={ref}\n disabled={disabled}\n accessibilityRole={accessibilityRole}\n testID={testID}\n href={href}\n hrefAttrs={hrefAttrs}\n $isStretch={$isStretch}\n $type={$type}\n onPress={onPress}\n onPressIn={() => {\n handlePressInOut(true);\n }}\n onPressOut={() => {\n handlePressInOut(false);\n }}\n >\n <StyledAnimatedView style={disabled ? [{ transform: [{ scale: 1 }] }] : [scaleStyles]}>\n {children}\n </StyledAnimatedView>\n </StyledPressable>\n );\n },\n);\n","import type { ViewProps } from 'react-native';\nimport { Platform } from 'react-native';\nimport styled from 'styled-components/native';\nimport type { ButtonType, ButtonVariant } from './Button';\nimport { getVariantValuesIfExist } from './getVariantValuesIfExist';\n\nexport interface BaseStyledButtonPressableProps extends ViewProps {\n $type: ButtonType;\n $variant: ButtonVariant;\n $isLarge?: boolean;\n $isXLarge?: boolean;\n $isStretch?: boolean;\n $isDisabled?: boolean;\n}\n\nexport const BaseStyledButtonPressable = styled.View<BaseStyledButtonPressableProps>`\n position: relative;\n min-width: ${({ theme }) => theme.kitt.button.minWidth}px;\n max-width: ${({ theme, $isStretch }) => ($isStretch ? '100%' : `${theme.kitt.button.maxWidth}px`)};\n width: ${({ $isStretch }) => ($isStretch ? '100%' : 'auto')};\n min-height: ${({ theme }) => theme.kitt.button.minHeight}px;\n border-radius: ${({ theme }) => theme.kitt.button.borderRadius}px;\n flex-direction: row;\n align-items: center;\n justify-content: center;\n\n /* Emulate inline-* css display by making the button taking only its necessary space */\n align-self: flex-start;\n\n background-color: ${({ theme, $isDisabled, $type, $variant }) => {\n if ($isDisabled) return theme.kitt.button.disabled.default.backgroundColor;\n\n if (Platform.OS !== 'web') return 'transparent';\n\n return getVariantValuesIfExist(theme, $type, $variant).backgroundColor;\n }};\n\n padding: ${({ theme, $isLarge, $isXLarge, $isDisabled }) => {\n const { large, default: defaultPadding, disabled: disabledPadding, xLarge } = theme.kitt.button.contentPadding;\n\n if ($isXLarge) return xLarge;\n if ($isLarge) return large;\n if ($isDisabled) return disabledPadding;\n\n return defaultPadding;\n }};\n`;\n","import type { ReactElement } from 'react';\nimport { useTheme } from 'styled-components/native';\nimport type { Except } from 'type-fest';\nimport type { IconProps } from '../Icon/Icon';\nimport { Icon } from '../Icon/Icon';\nimport type { SetNonNullable } from '../utils/typeUtils';\nimport type { TypographyProps } from './Typography';\nimport { useTypographyColor } from './Typography';\n\nexport interface TypographyIconProps extends Except<IconProps, 'color'> {\n color?: TypographyProps['color'] | 'inherit';\n}\n\nfunction TypographyIconSpecifiedColor({ color, ...props }: SetNonNullable<TypographyIconProps, 'color'>): ReactElement {\n const theme = useTheme();\n return <Icon {...props} color={color === 'inherit' ? 'inherit' : theme.kitt.typography.colors[color]} />;\n}\n\nfunction TypographyIconInheritColor(props: TypographyIconProps): ReactElement {\n const color = useTypographyColor();\n\n return <TypographyIconSpecifiedColor color={color} {...props} />;\n}\n\nexport function TypographyIcon({ color, ...props }: TypographyIconProps): ReactElement {\n if (color) {\n return <TypographyIconSpecifiedColor color={color} {...props} />;\n }\n\n return <TypographyIconInheritColor {...props} />;\n}\n","import type { ButtonType, SubtleButtonType } from './Button';\n\nexport function isSubtle(type: ButtonType): type is SubtleButtonType {\n return type.startsWith('subtle');\n}\n","import type { ReactElement } from 'react';\nimport { Platform } from 'react-native';\nimport styled from 'styled-components/native';\nimport type { Except } from 'type-fest';\nimport type { TypographyColor, TypographyTextProps } from '../typography/Typography';\nimport { Typography } from '../typography/Typography';\nimport type { TypographyIconProps } from '../typography/TypographyIcon';\nimport { TypographyIcon } from '../typography/TypographyIcon';\nimport type { ButtonProps, ButtonType, ButtonVariant } from './Button';\nimport { isSubtle } from './isSubtle';\n\nconst getTextColorByType = (type: ButtonType, variant: ButtonVariant): TypographyColor => {\n switch (type) {\n case 'primary':\n return variant === 'ghost' ? 'primary' : 'white';\n case 'white':\n return 'white';\n case 'subtle':\n return 'primary';\n case 'subtle-dark':\n return 'black';\n case 'default':\n return variant === 'ghost' ? 'white' : 'black';\n default:\n return 'black';\n }\n};\n\ninterface StyledButtonTextProps extends TypographyTextProps {\n $type: ButtonType;\n $isDisabled?: boolean;\n}\n\nconst StyledButtonText = styled(Typography.Text)<StyledButtonTextProps>`\n /* On native code, this is the only way to ensure that the text is centered */\n text-align: center;\n\n ${() => {\n // Make the multilines case work properly on native\n // Breaks the web implem\n if (Platform.OS === 'web') return undefined;\n\n return `\n flex-shrink: 1;\n `;\n }}\n\n ${({ $type, $isDisabled }) => {\n /* For subltes button, color changes when hovered.\n * We don't want to use a mouse event handler with a react state to handle it\n * For this precise case, we've decided to work outside the typography logic\n */\n if (Platform.OS !== 'web' || $isDisabled || !isSubtle($type)) return undefined;\n return 'color: inherit';\n }}\n`;\n\ninterface StyledIconContainerProps {\n $iconPosition?: ButtonProps['iconPosition'];\n}\n\nconst StyledIconContainer = styled.View<StyledIconContainerProps>`\n ${({ theme, $iconPosition }) => {\n const value = theme.kitt.spacing * 2;\n\n if ($iconPosition === 'left') {\n return `margin: 0 ${value}px 0 0;`;\n }\n\n return `margin: 0 0 0 ${value}px;`;\n }}\n`;\n\ninterface ButtonIconProps {\n icon: NonNullable<ButtonContentProps['icon']>;\n iconPosition: ButtonContentProps['iconPosition'];\n color: TypographyIconProps['color'];\n testID?: string;\n}\n\nfunction ButtonIcon({ icon, color, iconPosition, testID }: ButtonIconProps): ReactElement | null {\n return (\n <StyledIconContainer $iconPosition={iconPosition}>\n <TypographyIcon icon={icon} testID={testID} color={color} />\n </StyledIconContainer>\n );\n}\n\ninterface ButtonContentProps extends Except<ButtonProps, 'onPress' | 'disabled' | 'stretch'> {\n isDisabled?: boolean;\n type: NonNullable<ButtonType>;\n variant: NonNullable<ButtonVariant>;\n $isStretch: ButtonProps['stretch'];\n}\n\ninterface ButtonContentChildrenProps extends Except<ButtonProps, 'onPress' | 'disabled' | 'stretch'> {\n isDisabled?: boolean;\n type: NonNullable<ButtonType>;\n color: TypographyColor;\n}\n\nconst StyledChildrenWithIcon = styled.View`\n align-items: center;\n justify-content: center;\n flex-direction: row;\n`;\n\nexport function ButtonContentChildren({\n type,\n icon,\n iconPosition,\n isDisabled,\n color,\n children,\n}: ButtonContentChildrenProps): ReactElement | null {\n if (__DEV__) {\n if (!(children || icon)) {\n throw new Error('kitt(Button): You should provide at least a children or a icon');\n }\n }\n\n const isWebSubtle = isSubtle(type) && Platform.OS === 'web' && !isDisabled;\n\n if (!children) {\n return (\n <TypographyIcon\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n icon={icon!}\n color={isWebSubtle ? 'inherit' : color}\n />\n );\n }\n\n const buttonIconSharedProps = {\n type,\n iconPosition,\n color: isWebSubtle ? 'inherit' : (color as TypographyIconProps['color']),\n };\n\n return (\n <StyledChildrenWithIcon>\n {icon && iconPosition === 'left' ? (\n <ButtonIcon {...buttonIconSharedProps} testID=\"button-left-icon\" icon={icon} />\n ) : null}\n\n <StyledButtonText\n base=\"body\"\n variant=\"bold\"\n $type={type}\n $isDisabled={isDisabled}\n // set to color: inherit via styled components\n color={isWebSubtle ? undefined : color}\n >\n {children}\n </StyledButtonText>\n\n {icon && iconPosition === 'right' ? <ButtonIcon {...buttonIconSharedProps} icon={icon} /> : null}\n </StyledChildrenWithIcon>\n );\n}\n\ninterface ButtonContentContainerProps {\n $isSubtle?: boolean;\n $isStretch?: boolean;\n $isIconOnly?: boolean;\n}\n\nconst ButtonContentContainer = styled.View<ButtonContentContainerProps>`\n line-height: 16px;\n\n ${({ $isStretch, $isIconOnly }) => {\n // Make the multilines case work properly on web\n // Breaks the native implem\n if (Platform.OS !== 'web') return undefined;\n\n return `\n flex: ${$isStretch || $isIconOnly ? 1 : 0} 1 auto;\n `;\n }}\n\n ${({ $isSubtle }) => {\n if (Platform.OS !== 'web' || !$isSubtle) return undefined;\n // Needed for subtle type\n return 'color: inherit';\n }};\n`;\n\nexport function ButtonContent({\n type,\n variant,\n isDisabled,\n $isStretch,\n icon,\n children,\n ...props\n}: ButtonContentProps): ReactElement {\n const color = isDisabled ? 'black-light' : getTextColorByType(type, variant);\n\n return (\n <ButtonContentContainer $isSubtle={isSubtle(type)} $isStretch={$isStretch} $isIconOnly={Boolean(!children && icon)}>\n <ButtonContentChildren icon={icon} type={type} isDisabled={isDisabled} color={color} {...props}>\n {children}\n </ButtonContentChildren>\n </ButtonContentContainer>\n );\n}\n","import styled from 'styled-components/native';\n\nexport const StyledDisabled = styled.View`\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n border: ${({ theme }) => {\n const { borderWidth, disabled } = theme.kitt.button;\n return `${borderWidth.disabled}px solid ${disabled.default.borderColor}`;\n }};\n border-radius: ${({ theme }) => theme.kitt.button.borderRadius}px;\n`;\n","import type { ReactElement, ReactNode } from 'react';\nimport { forwardRef } from 'react';\nimport type { PressableProps, View } from 'react-native';\nimport { Platform } from 'react-native';\nimport { AnimatedButtonPressable } from './AnimatedButtonPressable';\nimport { BaseStyledButtonPressable } from './BaseStyledButtonPressable';\nimport { ButtonContent } from './ButtonContent';\nimport { StyledDisabled } from './StyledDisabled';\n\nexport type SubtleButtonType = 'subtle' | 'subtle-dark';\nexport type ButtonType = 'primary' | 'default' | SubtleButtonType | 'white';\n\nexport type ButtonVariant = 'default' | 'ghost';\n\ntype IconPosition = 'right' | 'left';\n\nconst allowedGhostTypes = ['primary', 'default'];\n\nexport interface ButtonProps {\n children?: ReactNode;\n type?: ButtonType;\n variant?: ButtonVariant;\n disabled?: boolean;\n stretch?: boolean;\n large?: boolean;\n xLarge?: boolean;\n icon?: ReactElement;\n iconPosition?: IconPosition;\n testID?: PressableProps['testID'];\n href?: PressableProps['href'];\n hrefAttrs?: PressableProps['hrefAttrs'];\n accessibilityRole?: PressableProps['accessibilityRole'];\n className?: string;\n style?: PressableProps['style'];\n onPress?: PressableProps['onPress'];\n}\n\nexport const Button = forwardRef<View, ButtonProps>(\n (\n {\n children,\n type = 'default',\n variant = 'default',\n disabled,\n stretch,\n large,\n xLarge,\n icon,\n iconPosition = 'left',\n testID,\n href,\n hrefAttrs,\n accessibilityRole = 'button',\n onPress,\n }: ButtonProps,\n ref,\n ): ReactElement => {\n if (__DEV__ && variant === 'ghost' && !allowedGhostTypes.includes(type)) {\n throw new Error('variant=ghost is only allowed with type=primary or default');\n }\n\n return (\n <AnimatedButtonPressable\n ref={ref}\n accessibilityRole={accessibilityRole}\n testID={testID}\n href={href}\n hrefAttrs={hrefAttrs}\n disabled={disabled}\n $isStretch={stretch}\n $type={type}\n $variant={variant}\n onPress={onPress}\n >\n <BaseStyledButtonPressable\n $type={type}\n $variant={variant}\n $isStretch={stretch}\n $isLarge={large}\n $isXLarge={xLarge}\n $isDisabled={disabled}\n >\n <ButtonContent\n type={type}\n variant={variant}\n $isStretch={stretch}\n isDisabled={disabled}\n icon={icon}\n iconPosition={iconPosition}\n >\n {children}\n </ButtonContent>\n {Platform.OS !== 'web' && disabled ? <StyledDisabled /> : null}\n </BaseStyledButtonPressable>\n </AnimatedButtonPressable>\n );\n },\n);\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\n\ntype CardType = 'primary' | 'secondary' | 'subtle';\n\nexport interface CardProps {\n children: NonNullable<ReactNode>;\n type: CardType;\n}\ninterface ContainerProps {\n type: CardType;\n}\n\nconst Container = styled.View<ContainerProps>`\n background-color: ${({ theme, type }) => theme.kitt.card[type].backgroundColor};\n padding: ${({ theme }) => theme.kitt.spacing * 4}px;\n border-radius: ${({ theme }) => theme.kitt.card.borderRadius}px;\n border-width: ${({ theme }) => theme.kitt.card.borderWidth}px;\n border-color: ${({ theme, type }) => theme.kitt.card[type].borderColor};\n`;\n\nexport function Card({ children, type }: CardProps): ReactElement {\n return <Container type={type}>{children}</Container>;\n}\n","import type { ReactElement } from 'react';\nimport { useMemo } from 'react';\nimport type { ImageProps } from 'react-native';\nimport { Platform } from 'react-native';\nimport styled from 'styled-components/native';\nimport { parse } from 'twemoji-parser';\n\ninterface StyledEmojiProps {\n size: number;\n}\n\nconst StyledEmoji = styled.Image<StyledEmojiProps>`\n width: ${({ size }) => size}px;\n height: ${({ size }) => size}px;\n`;\n\nexport interface EmojiProps extends Pick<ImageProps, 'style'> {\n emoji: string;\n size: number;\n}\n\nexport function Emoji({ emoji, size, style }: EmojiProps): ReactElement | null {\n const [emojiData] = useMemo(\n () =>\n parse(emoji, {\n // on native plaforms, you can't display svg as Image\n assetType: Platform.OS === 'web' ? 'svg' : 'png',\n }),\n [emoji],\n );\n\n if (!emojiData) return null;\n\n return <StyledEmoji size={size} accessibilityLabel={emojiData.text} source={{ uri: emojiData.url }} style={style} />;\n}\n","export interface ExternalLinkOpenLinkBehavior {\n /**\n * @default 'openInModal'\n *\n * @description open link behavior in native\n *\n * \"openInModal\": open via [expo-web-browser](https://docs.expo.dev/versions/latest/sdk/webbrowser/)\n *\n * \"openBrowserApp\": open via [Linking](https://docs.expo.dev/guides/linking/#opening-links-from-your-app)\n */\n native?: 'openInModal' | 'openBrowserApp';\n\n /**\n * @default 'targetBlank'\n *\n * @description open link behavior in native\n *\n * \"targetSelf\": no dom attributes added, behave like `target=\"_self\"`\n *\n * \"targetBlank\": dome attributes: `target=\"_blank\" rel=\"noopener noreferrer\"`\n */\n web?: 'targetSelf' | 'targetBlank';\n}\n\nexport const defaultOpenLinkBehavior: ExternalLinkOpenLinkBehavior = {\n native: 'openInModal',\n web: 'targetBlank',\n};\n","import * as WebBrowser from 'expo-web-browser';\nimport type { ComponentProps, ReactElement, VoidFunctionComponent } from 'react';\nimport type { PressableProps, TextProps } from 'react-native';\nimport { Linking } from 'react-native';\nimport type { ExternalLinkOpenLinkBehavior } from './ExternalLinkOpenLinkBehavior';\nimport { defaultOpenLinkBehavior } from './ExternalLinkOpenLinkBehavior';\n\nexport interface ExternalLinkAsComponentMinimumRequiredProps {\n href?: TextProps['href'];\n hrefAttrs?: TextProps['hrefAttrs'];\n onPress?: PressableProps['onPress'];\n}\n\nexport interface ExternalLinkProps<C extends VoidFunctionComponent<any>> {\n as: C;\n openLinkBehavior?: ExternalLinkOpenLinkBehavior;\n href?: string;\n onPress?: PressableProps['onPress'];\n}\n\n/** @internal for ExternalLink.web.tsx only */\n// eslint-disable-next-line @typescript-eslint/ban-types\nexport type ExternalLinkSendableComponentProps<C extends VoidFunctionComponent<any>> = Omit<\n ComponentProps<C>,\n keyof ExternalLinkProps<C> & keyof ExternalLinkAsComponentMinimumRequiredProps\n>;\n\nexport function ExternalLink<C extends VoidFunctionComponent<any>>({\n as: Component,\n href,\n openLinkBehavior = defaultOpenLinkBehavior,\n onPress,\n ...rest\n}: ExternalLinkProps<C> & ExternalLinkSendableComponentProps<C>): ReactElement {\n const handleOnPress: PressableProps['onPress'] = (e) => {\n if (onPress) {\n onPress(e);\n if (e?.defaultPrevented) return;\n }\n\n if (!href) return;\n\n switch (openLinkBehavior.native) {\n case 'openInModal':\n case undefined:\n WebBrowser.openBrowserAsync(href).catch((err) => {\n console.error(`An error occurred while opening ${href}`, err);\n });\n break;\n case 'openBrowserApp':\n Linking.openURL(href).catch((err) => {\n console.error(`An error occurred while opening ${href}`, err);\n });\n break;\n default:\n if (__DEV__) {\n throw new Error(`Invalid ExternalLink native behavior: ${openLinkBehavior.native as string}`);\n }\n }\n };\n\n return <Component {...(rest as any)} onPress={handleOnPress} />;\n}\n","export const lateOceanColorPalette = {\n lateOcean: '#4C34E0',\n lateOceanLight1: '#705DE6',\n lateOceanLight2: '#9485EC',\n lateOceanLight3: '#D6BAF9',\n\n warmEmbrace: '#F4D3CE',\n warmEmbraceLight1: '#FFEDE6',\n\n black1000: '#000000',\n black800: '#2C293D',\n black555: '#737373',\n black200: '#CCCCCC',\n black100: '#E5E5E5',\n black50: '#F2F2F2',\n black25: '#F9F9F9',\n white: '#FFFFFF',\n\n viride: '#38836D',\n englishVermillon: '#D44148',\n goldCrayola: '#F8C583',\n aero: '#89BDDD',\n\n transparent: 'transparent',\n\n moonPurple: '#DBD6F9',\n moonPurpleLight1: '#EDEBFC',\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const colors = {\n primary: lateOceanColorPalette.lateOcean,\n primaryLight: lateOceanColorPalette.lateOceanLight1,\n accent: lateOceanColorPalette.warmEmbrace,\n accentLight: lateOceanColorPalette.warmEmbraceLight1,\n success: lateOceanColorPalette.viride,\n correct: lateOceanColorPalette.viride,\n danger: lateOceanColorPalette.englishVermillon,\n info: lateOceanColorPalette.aero,\n warning: lateOceanColorPalette.goldCrayola,\n separator: lateOceanColorPalette.black100,\n hover: lateOceanColorPalette.black100,\n white: lateOceanColorPalette.white,\n black: lateOceanColorPalette.black1000,\n blackAnthracite: lateOceanColorPalette.black800,\n uiBackground: lateOceanColorPalette.black25,\n uiBackgroundLight: lateOceanColorPalette.white,\n transparent: lateOceanColorPalette.transparent,\n disabled: lateOceanColorPalette.black50,\n overlay: {\n dark: 'rgba(41, 48, 51, 0.25)',\n light: 'rgba(255, 255, 255, 0.90)',\n fullscreenLoader: 'rgba(0, 0, 0, 0.25)',\n },\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\n\nexport interface AvatarThemeColorVariant {\n backgroundColor: string;\n}\n\nexport interface AvatarThemeSizeVariant {\n borderRadius: number;\n}\n\nexport interface AvatarTheme {\n borderRadius: number;\n default: AvatarThemeColorVariant;\n light: AvatarThemeColorVariant;\n large: AvatarThemeSizeVariant;\n}\n\nexport const avatar: AvatarTheme = {\n borderRadius: 10,\n default: {\n backgroundColor: colors.primary,\n },\n light: {\n backgroundColor: lateOceanColorPalette.black100,\n },\n large: {\n borderRadius: 30,\n },\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\n\nexport interface BaseVariantTheme {\n backgroundColor: string;\n pressedBackgroundColor: string;\n hoverBackgroundColor: string;\n focusBorderColor: string;\n}\n\nexport interface GhostVariantTheme extends BaseVariantTheme {\n color: string;\n hoverColor: string;\n activeColor: string;\n}\nexport interface BaseButtonTheme {\n default: BaseVariantTheme;\n}\n\nexport interface BaseButtonWithVariant extends BaseButtonTheme {\n ghost: GhostVariantTheme;\n}\n\nexport interface SubtleBaseVariantTheme extends BaseVariantTheme {\n color: string;\n hoverColor: string;\n activeColor: string;\n}\n\nexport interface SubtleButtonTheme extends BaseButtonTheme {\n default: SubtleBaseVariantTheme;\n}\n\nexport interface DisabledBaseVariantTheme extends BaseVariantTheme {\n borderColor: string;\n}\n\nexport interface DisabledButtonTheme extends BaseButtonTheme {\n default: DisabledBaseVariantTheme;\n}\n\nexport interface ButtonTheme {\n borderRadius: number;\n borderWidth: {\n disabled: number;\n focus: number;\n };\n minHeight: number;\n minWidth: number;\n maxWidth: number;\n scale: {\n base: {\n default: number;\n hover: number;\n active: number;\n };\n medium: {\n hover: number;\n };\n };\n contentPadding: {\n default: string;\n large: string;\n xLarge: string;\n disabled: string;\n };\n transition: {\n duration: string;\n timingFunction: string;\n };\n default: BaseButtonWithVariant;\n primary: BaseButtonWithVariant;\n white: BaseButtonTheme;\n subtle: SubtleButtonTheme;\n 'subtle-dark': SubtleButtonTheme;\n disabled: DisabledButtonTheme;\n}\n\nexport const button: ButtonTheme = {\n borderRadius: 30,\n borderWidth: {\n disabled: 2,\n focus: 3,\n },\n minHeight: 40,\n minWidth: 40,\n maxWidth: 335,\n scale: {\n base: {\n default: 1,\n hover: 0.95,\n active: 0.95,\n },\n medium: {\n hover: 1.05,\n },\n },\n contentPadding: {\n default: '7px 16px 7px',\n large: '11px 24px 11px',\n xLarge: '15px 24px 15px',\n disabled: '5px 14px 5px',\n },\n transition: {\n duration: '200ms',\n timingFunction: 'cubic-bezier(0.645, 0.045, 0.355, 1)',\n },\n default: {\n default: {\n backgroundColor: 'rgba(0, 0, 0, 0.05)',\n pressedBackgroundColor: 'rgba(0, 0, 0, 0.1)',\n hoverBackgroundColor: 'rgba(0, 0, 0, 0.1)',\n focusBorderColor: 'rgba(0, 0, 0, 0.1)',\n },\n ghost: {\n backgroundColor: 'rgba(255, 255, 255, 0.1)',\n pressedBackgroundColor: 'rgba(255, 255, 255, 0.05)',\n hoverBackgroundColor: 'rgba(255, 255, 255, 0.05)',\n focusBorderColor: 'rgba(255, 255, 255, 0.4)',\n color: lateOceanColorPalette.white,\n hoverColor: lateOceanColorPalette.white,\n activeColor: lateOceanColorPalette.white,\n },\n },\n primary: {\n default: {\n backgroundColor: colors.primary,\n pressedBackgroundColor: colors.primaryLight,\n hoverBackgroundColor: colors.primaryLight,\n focusBorderColor: 'rgba(76, 52, 224, 0.2)',\n },\n ghost: {\n backgroundColor: colors.uiBackgroundLight,\n pressedBackgroundColor: colors.uiBackground,\n hoverBackgroundColor: colors.hover,\n focusBorderColor: 'rgba(255,255,255, 0.4)',\n color: colors.primary,\n hoverColor: colors.hover,\n activeColor: colors.hover,\n },\n },\n white: {\n default: {\n backgroundColor: 'rgba(255, 255, 255, 0.05)',\n pressedBackgroundColor: 'rgba(255, 255, 255, 0.1)',\n hoverBackgroundColor: 'rgba(255, 255, 255, 0.1)',\n focusBorderColor: 'rgba(255, 255, 255, 0.1)',\n },\n },\n subtle: {\n default: {\n backgroundColor: colors.transparent,\n pressedBackgroundColor: colors.transparent,\n hoverBackgroundColor: colors.transparent,\n focusBorderColor: 'rgba(76, 52, 224, 0.2)',\n color: colors.primary,\n hoverColor: 'rgba(76, 52, 224, 0.8)',\n activeColor: 'rgba(76, 52, 224, 0.8)',\n },\n },\n 'subtle-dark': {\n default: {\n backgroundColor: colors.transparent,\n pressedBackgroundColor: colors.transparent,\n hoverBackgroundColor: colors.transparent,\n focusBorderColor: 'rgba(0, 0, 0, 0.1)',\n color: colors.black,\n hoverColor: 'rgba(0, 0, 0, 0.8)',\n activeColor: 'rgba(0, 0, 0, 0.8)',\n },\n },\n disabled: {\n default: {\n backgroundColor: colors.disabled,\n pressedBackgroundColor: colors.disabled,\n hoverBackgroundColor: colors.disabled,\n focusBorderColor: lateOceanColorPalette.black100,\n borderColor: lateOceanColorPalette.black100,\n },\n },\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\n\nexport interface CardThemeType {\n backgroundColor: string;\n borderColor: string;\n}\nexport interface CardTheme {\n borderRadius: number;\n borderWidth: number;\n primary: CardThemeType;\n secondary: CardThemeType;\n subtle: CardThemeType;\n}\n\nexport const card: CardTheme = {\n borderRadius: 20,\n borderWidth: 2,\n primary: {\n backgroundColor: colors.uiBackgroundLight,\n borderColor: colors.primary,\n },\n secondary: {\n backgroundColor: colors.uiBackgroundLight,\n borderColor: colors.separator,\n },\n subtle: {\n backgroundColor: lateOceanColorPalette.black50,\n borderColor: colors.separator,\n },\n};\n","import { colors } from './colors';\n\nexport interface FeedbackMessageVariantTheme {\n backgroundColor: string;\n}\n\nexport interface FeedbackMessageTheme {\n danger: FeedbackMessageVariantTheme;\n info: FeedbackMessageVariantTheme;\n success: FeedbackMessageVariantTheme;\n warning: FeedbackMessageVariantTheme;\n}\n\nexport const feedbackMessage: FeedbackMessageTheme = {\n danger: {\n backgroundColor: colors.danger,\n },\n success: {\n backgroundColor: colors.success,\n },\n info: {\n backgroundColor: colors.info,\n },\n warning: {\n backgroundColor: colors.warning,\n },\n};\n","import { colors } from './colors';\n\nexport const checkbox = {\n borderWidth: 2,\n borderRadius: 5,\n height: 20,\n width: 20,\n iconSize: 14,\n borderColor: colors.separator,\n backgroundColor: colors.uiBackgroundLight,\n checkedBorderColor: colors.primary,\n checkedBackgroundColor: colors.primary,\n markColor: colors.uiBackgroundLight,\n};\n","interface DatePickerPartTheme {\n minWidth: number;\n}\n\nexport interface DatePickerTheme {\n day: DatePickerPartTheme;\n month: DatePickerPartTheme;\n year: DatePickerPartTheme;\n}\n\nexport const datePicker: DatePickerTheme = {\n day: {\n minWidth: 64,\n },\n month: {\n minWidth: 64,\n },\n year: {\n minWidth: 82,\n },\n};\n","import { Platform } from 'react-native';\nimport { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors as kittColors } from './colors';\n\nexport const calcLineHeight = (fontSize: number, lineHeightMultiplier: number): number =>\n Math.round(fontSize * lineHeightMultiplier);\n\nexport interface TypographyTypeBreakpointRangeConfig {\n fontSize: number;\n lineHeight: number;\n}\n\nexport interface TypographyTypeConfig {\n baseAndSmall: TypographyTypeBreakpointRangeConfig;\n mediumAndWide: TypographyTypeBreakpointRangeConfig;\n}\n\nexport const createTypographyTypeConfig = (\n lineHeightMultiplier: number,\n baseAndSmallFontSize: number,\n mediumAndWideFontSize: number,\n): TypographyTypeConfig => ({\n baseAndSmall: {\n fontSize: baseAndSmallFontSize,\n lineHeight: calcLineHeight(baseAndSmallFontSize, lineHeightMultiplier),\n },\n mediumAndWide: {\n fontSize: mediumAndWideFontSize,\n lineHeight: calcLineHeight(mediumAndWideFontSize, lineHeightMultiplier),\n },\n});\n\nexport const typography = {\n colors: {\n black: kittColors.black,\n 'black-anthracite': kittColors.blackAnthracite,\n 'black-light': lateOceanColorPalette.black555,\n white: kittColors.white,\n 'white-light': kittColors.white,\n primary: kittColors.primary,\n 'primary-light': kittColors.primaryLight,\n accent: kittColors.accent,\n success: kittColors.success,\n danger: kittColors.danger,\n },\n types: {\n headers: {\n fontFamily: {\n regular: Platform.OS === 'web' ? 'Moderat' : 'Moderat-Extended-Bold',\n bold: Platform.OS === 'web' ? 'Moderat' : 'Moderat-Extended-Bold',\n },\n fontWeight: 400,\n fontStyle: 'normal',\n configs: {\n // also known as xxlarge\n header1: createTypographyTypeConfig(1.3, 38, 62),\n // also known as xlarge\n header2: createTypographyTypeConfig(1.3, 32, 48),\n // also known as medium\n header3: createTypographyTypeConfig(1.3, 24, 36),\n // also known as xsmall\n header4: createTypographyTypeConfig(1.3, 18, 24),\n // also known as xxsmall\n header5: createTypographyTypeConfig(1.3, 18, 18),\n },\n },\n bodies: {\n fontFamily: {\n regular: Platform.OS === 'web' ? 'Noto Sans' : 'NotoSans',\n bold: Platform.OS === 'web' ? 'Noto Sans' : 'NotoSans-Bold',\n },\n fontWeight: {\n regular: 400,\n bold: 700,\n },\n fontStyle: {\n regular: 'normal',\n bold: 'normal',\n },\n configs: {\n 'body-large': createTypographyTypeConfig(1.6, 18, 24),\n 'body-medium': createTypographyTypeConfig(1.6, 18, 18),\n body: createTypographyTypeConfig(1.6, 16, 16),\n 'body-small': createTypographyTypeConfig(1.6, 14, 14),\n 'body-xsmall': createTypographyTypeConfig(1.6, 12, 12),\n },\n },\n },\n link: {\n disabledColor: lateOceanColorPalette.black200,\n },\n};\n","import type { InputUIState } from '../../forms/utils';\nimport { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\nimport { typography } from './typography';\n\nexport interface InputStateStyle {\n backgroundColor?: string;\n borderColor: string;\n color: keyof typeof typography.colors;\n}\n\nexport type InputStateTheme = Record<InputUIState, InputStateStyle>;\n\nconst inputStatesStyle: InputStateTheme = {\n default: {\n backgroundColor: colors.uiBackgroundLight,\n borderColor: colors.separator,\n color: 'black',\n },\n pending: {\n backgroundColor: colors.uiBackgroundLight,\n borderColor: colors.separator,\n color: 'black',\n },\n valid: {\n backgroundColor: colors.uiBackgroundLight,\n borderColor: lateOceanColorPalette.black100,\n color: 'black',\n },\n hover: {\n borderColor: lateOceanColorPalette.black200,\n color: 'black',\n },\n focus: {\n borderColor: colors.primary,\n color: 'black',\n },\n disabled: {\n backgroundColor: colors.disabled,\n borderColor: colors.separator,\n color: 'black-light',\n },\n invalid: {\n borderColor: colors.separator,\n color: 'black',\n },\n};\n\nexport interface InputTheme {\n minHeight: number;\n color: {\n selection: string;\n placeholder: string;\n };\n borderWidth: number;\n borderRadius: number;\n icon: {\n size: number;\n };\n padding: {\n horizontal: number;\n vertical: number;\n };\n transition: {\n property: string;\n duration: string;\n timingFunction: string;\n };\n states: InputStateTheme;\n}\n\nexport const input: InputTheme = {\n minHeight: 40,\n color: {\n selection: colors.primary,\n placeholder: typography.colors['black-light'],\n },\n borderWidth: 2,\n borderRadius: 10,\n icon: {\n size: 20,\n },\n padding: {\n horizontal: 16,\n vertical: 5,\n },\n transition: {\n property: 'border-color',\n duration: '200ms',\n timingFunction: 'ease-in-out',\n },\n states: inputStatesStyle,\n};\n","export const inputField = {\n labelContainerPaddingBottom: 5,\n iconMarginLeft: 6,\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\n\ninterface InputTagTypeTheme {\n backgroundColor: string;\n labelColor: string;\n}\nexport interface InputTagTheme {\n borderRadius: number;\n iconSize: number;\n default: InputTagTypeTheme;\n success: InputTagTypeTheme;\n danger: InputTagTypeTheme;\n}\n\nexport const inputTag: InputTagTheme = {\n success: {\n backgroundColor: colors.success,\n labelColor: colors.uiBackgroundLight,\n },\n danger: {\n backgroundColor: colors.danger,\n labelColor: colors.uiBackgroundLight,\n },\n default: {\n backgroundColor: lateOceanColorPalette.black50,\n labelColor: colors.black,\n },\n borderRadius: 10,\n iconSize: 13.5,\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\n\nexport interface RadioTheme {\n size: number;\n unchecked: {\n backgroundColor: string;\n borderColor: string;\n borderWidth: number;\n };\n checked: {\n backgroundColor: string;\n innerBackgroundColor: string;\n innerSize: number;\n };\n disabled: {\n backgroundColor: string;\n borderColor: string;\n };\n}\n\nexport const radio: RadioTheme = {\n size: 18,\n unchecked: {\n backgroundColor: colors.uiBackgroundLight,\n borderWidth: 2,\n borderColor: lateOceanColorPalette.black200,\n },\n checked: {\n backgroundColor: colors.primary,\n innerSize: 5,\n innerBackgroundColor: colors.uiBackgroundLight,\n },\n disabled: {\n backgroundColor: colors.disabled,\n borderColor: colors.separator,\n },\n};\n","export interface TextAreaTheme {\n minHeight: number;\n}\n\nexport const textArea: TextAreaTheme = {\n minHeight: 120,\n};\n","import { checkbox } from './checkbox';\nimport { datePicker } from './datePicker';\nimport { input } from './input';\nimport { inputField } from './inputField';\nimport { inputTag } from './inputTag';\nimport { radio } from './radio';\nimport { textArea } from './textArea';\n\nexport const forms = {\n datePicker,\n input,\n radio,\n inputField,\n textArea,\n checkbox,\n inputTag,\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const fullScreenModal = {\n header: {\n paddingVertical: 12,\n paddingHorizontal: 16,\n borderColor: lateOceanColorPalette.black100,\n },\n};\n","import { button } from './button';\n\ninterface IconButtonVariationValues {\n pressedBackgroundColor: string;\n}\n\nexport interface IconButtonTheme {\n backgroundColor: string;\n width: number;\n height: number;\n borderRadius: number;\n borderWidth: number;\n borderColor: string;\n transition: {\n property: string;\n duration: string;\n timingFunction: string;\n };\n scale: {\n base: {\n default: number;\n hover: number;\n active: number;\n };\n medium: {\n hover: number;\n };\n };\n disabled: {\n scale: number;\n backgroundColor: string;\n borderColor: string;\n };\n default: IconButtonVariationValues;\n white: IconButtonVariationValues;\n}\n\nexport const iconButton: IconButtonTheme = {\n backgroundColor: 'transparent',\n width: 40,\n height: 40,\n borderRadius: 20,\n borderWidth: 2,\n borderColor: 'transparent',\n transition: {\n property: 'all',\n duration: '200ms',\n timingFunction: 'cubic-bezier(0.645, 0.045, 0.355, 1);',\n },\n scale: {\n base: {\n default: 1,\n hover: 0.95,\n active: 0.95,\n },\n medium: {\n hover: 1.05,\n },\n },\n disabled: {\n scale: 1,\n backgroundColor: button.disabled.default.backgroundColor,\n borderColor: button.disabled.default.borderColor,\n },\n default: {\n pressedBackgroundColor: button.default.default.pressedBackgroundColor,\n },\n white: {\n pressedBackgroundColor: button.white.default.hoverBackgroundColor,\n },\n};\n","import { colors } from './colors';\n\nexport interface ListItemTheme {\n padding: string;\n borderColor: string;\n borderWidth: number;\n innerMargin: number;\n}\n\nexport const listItem: ListItemTheme = {\n padding: '12px 16px',\n borderColor: colors.separator,\n borderWidth: 1,\n innerMargin: 8,\n};\n","import { colors } from './colors';\n\nexport interface PageLoaderTheme {\n size: number;\n strokeWidth: number;\n colors: {\n base: string;\n fill: string;\n };\n animation: {\n delay: number;\n circleBackgroundFillDuration: number;\n filledCircleFillDuration: number;\n groupFilledCircleRotationDuration: number;\n filledCircleRotationDuration: number;\n fillEasingFunction: [number, number, number, number];\n };\n}\n\nexport const pageLoader: PageLoaderTheme = {\n size: 60,\n strokeWidth: 3,\n colors: {\n base: colors.separator,\n fill: colors.primary,\n },\n animation: {\n delay: 500,\n circleBackgroundFillDuration: 1000,\n filledCircleFillDuration: 1800,\n groupFilledCircleRotationDuration: 1800,\n filledCircleRotationDuration: 2160,\n fillEasingFunction: [0.39, 0.575, 0.565, 1],\n },\n};\n","export const shadows = {\n medium: '0px 10px 20px rgba(41, 48, 51, 0.25)',\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport interface SkeletonTheme {\n backgroundColor: string;\n flareColor: string;\n animationDuration: number;\n}\n\nexport const skeleton: SkeletonTheme = {\n backgroundColor: lateOceanColorPalette.black100,\n flareColor: lateOceanColorPalette.black200,\n animationDuration: 1000,\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colors } from './colors';\n\nexport interface TagVariantTheme {\n borderWidth: number;\n backgroundColor: string;\n borderColor: string;\n}\n\nexport interface TagTypeTheme {\n fill: TagVariantTheme;\n outline: TagVariantTheme;\n}\n\nexport interface TagTheme {\n borderRadius: number;\n padding: string;\n primary: TagTypeTheme;\n default: TagTypeTheme;\n danger: TagTypeTheme;\n}\n\nexport const tag: TagTheme = {\n borderRadius: 10,\n padding: '2px 12px',\n primary: {\n fill: {\n backgroundColor: lateOceanColorPalette.moonPurpleLight1,\n borderWidth: 0,\n borderColor: colors.transparent,\n },\n outline: {\n backgroundColor: colors.transparent,\n borderWidth: 1,\n borderColor: colors.primary,\n },\n },\n default: {\n fill: {\n backgroundColor: lateOceanColorPalette.black50,\n borderWidth: 0,\n borderColor: colors.transparent,\n },\n outline: {\n backgroundColor: colors.transparent,\n borderWidth: 1,\n borderColor: colors.black,\n },\n },\n danger: {\n fill: {\n backgroundColor: lateOceanColorPalette.warmEmbrace,\n borderWidth: 0,\n borderColor: colors.transparent,\n },\n outline: {\n backgroundColor: colors.transparent,\n borderWidth: 1,\n borderColor: colors.danger,\n },\n },\n};\n","import { colors } from './colors';\n\nexport interface TooltipTheme {\n backgroundColor: string;\n borderRadius: number;\n opacity: number;\n horizontalPadding: number;\n verticalPadding: number;\n floatingPadding: number;\n}\n\nexport const tooltip: TooltipTheme = {\n backgroundColor: colors.black,\n borderRadius: 10,\n opacity: 0.95,\n horizontalPadding: 16,\n verticalPadding: 4,\n floatingPadding: 8,\n};\n","import { avatar } from './late-ocean/avatar';\nimport { button } from './late-ocean/button';\nimport { card } from './late-ocean/card';\nimport { colors } from './late-ocean/colors';\nimport { feedbackMessage } from './late-ocean/feedback';\nimport { forms } from './late-ocean/forms';\nimport { fullScreenModal } from './late-ocean/fullScreenModal';\nimport { iconButton } from './late-ocean/iconButton';\nimport { listItem } from './late-ocean/listItem';\nimport { pageLoader } from './late-ocean/pageLoader';\nimport { shadows } from './late-ocean/shadows';\nimport { skeleton } from './late-ocean/skeleton';\nimport { tag } from './late-ocean/tag';\nimport { tooltip } from './late-ocean/tooltip';\nimport { typography } from './late-ocean/typography';\nimport { lateOceanColorPalette } from './palettes/lateOceanColorPalette';\n\nconst breakpoints = {\n values: {\n base: 0,\n small: 480,\n medium: 768,\n large: 1024,\n wide: 1280,\n },\n min: {\n smallBreakpoint: 'min-width: 480px',\n mediumBreakpoint: 'min-width: 768px',\n largeBreakpoint: 'min-width: 1024px',\n wideBreakpoint: 'min-width: 1280px',\n },\n max: {\n smallBreakpoint: 'max-width: 479px',\n mediumBreakpoint: 'max-width: 767px',\n largeBreakpoint: 'max-width: 1023px',\n wideBreakpoint: 'max-width: 1279px',\n },\n};\n\n// eslint-disable-next-line unicorn/expiring-todo-comments\n// TODO : seperate brand color usage definition from proper theme definition and add typings - https://ornikar.atlassian.net/browse/CME-156\nexport const theme = {\n spacing: 4,\n colors,\n palettes: { lateOcean: lateOceanColorPalette },\n avatar,\n breakpoints,\n button,\n card,\n feedbackMessage,\n forms,\n fullScreenModal,\n iconButton,\n listItem,\n pageLoader,\n shadows,\n skeleton,\n tag,\n tooltip,\n typography,\n};\n\nexport type Theme = typeof theme;\n","import { useWindowDimensions } from 'react-native';\nimport type { WindowDimensions } from './createWindowSizeHelper';\n\nexport interface MatchWindowSizeOptions {\n minWidth?: number;\n maxWidth?: number;\n minHeight?: number;\n maxHeight?: number;\n}\nexport function matchWindowSize(\n { width, height }: WindowDimensions,\n { minWidth, maxWidth, minHeight, maxHeight }: MatchWindowSizeOptions,\n): boolean {\n const hasWidthMatched = width ? (!minWidth || width >= minWidth) && (!maxWidth || width <= maxWidth) : true;\n const hasHeightMatched = height ? (!minHeight || height >= minHeight) && (!maxHeight || height <= maxHeight) : true;\n return hasWidthMatched && hasHeightMatched;\n}\n\nexport function useMatchWindowSize(options: MatchWindowSizeOptions): boolean {\n const { width, height } = useWindowDimensions();\n return matchWindowSize({ width, height }, options);\n}\n","// eslint-disable-next-line no-restricted-imports\nimport type { FlattenSimpleInterpolation } from 'styled-components';\nimport type { MatchWindowSizeOptions } from './useMatchWindowSize';\nimport { matchWindowSize } from './useMatchWindowSize';\n\nexport interface WindowSizeHelper {\n /** Prefer using if or map variants, at it should be more web friendly */\n matchWindowSize: (options: MatchWindowSizeOptions) => boolean;\n\n /**\n * @example\n * ```typescript\n * const Container = styled.View`\n * ${({ theme }) =>\n * theme.responsive.ifWindowSizeMatches(\n * { minWidth: KittBreakpoints.SMALL },\n * 'padding: 5px 0 10px;'\n * )\n * )};\n * `;\n * ```\n */\n ifWindowSizeMatches: <T extends string | FlattenSimpleInterpolation | null>(\n options: MatchWindowSizeOptions,\n valueIfTrue: T,\n valueIfFalse?: T,\n ) => T | undefined;\n\n /**\n *\n * @example\n * ```typescript\n * const Container = styled.View`\n * ${({ theme }) =>\n * theme.responsive.mapWindowWidth(\n * [KittBreakpoints.BASE, 'padding: 5px 0 10px;'],\n * [KittBreakpoints.SMALL, 'padding: 10px 0;'],\n * )\n * )};\n * `;\n * ```\n */\n mapWindowWidth: <V extends string>(...widthList: [number, V][]) => V | null;\n}\n\nexport interface WindowDimensions {\n width?: number;\n height?: number;\n}\n\nexport function createWindowSizeHelper(dimensions: WindowDimensions): WindowSizeHelper {\n return {\n matchWindowSize: (options) => matchWindowSize(dimensions, options),\n\n ifWindowSizeMatches: (options, valueIfTrue, valueIfFalse) =>\n matchWindowSize(dimensions, options) ? valueIfTrue : valueIfFalse,\n\n mapWindowWidth: <V extends string>(...widthList: [number, V][]): V | null => {\n if (__DEV__) {\n widthList.slice(1).forEach(([minWidth], index) => {\n const previousMinWidth = widthList[index][0];\n if (previousMinWidth > minWidth) {\n throw new Error(\n `mapWindowWidth: sort your values to be mobile first. ${minWidth} is < ${previousMinWidth}, so ${minWidth} should be before ${previousMinWidth}.`,\n );\n }\n });\n }\n const found = widthList.find(([minWidth, value]) => matchWindowSize(dimensions, { minWidth: Number(minWidth) }));\n if (!found) return null;\n return found[1];\n },\n };\n}\n","import { useMemo } from 'react';\nimport type { Theme } from './themes/default';\nimport { theme as kittTheme } from './themes/default';\nimport type { WindowSizeHelper } from './utils/windowSize/createWindowSizeHelper';\nimport { createWindowSizeHelper } from './utils/windowSize/createWindowSizeHelper';\nimport { useWindowSize } from './utils/windowSize/useWindowSize';\n\nexport interface KittTheme {\n kitt: Theme;\n responsive: WindowSizeHelper;\n}\n\nexport function useKittTheme(): KittTheme {\n const dimensions = useWindowSize();\n return useMemo(() => {\n return { kitt: kittTheme, responsive: createWindowSizeHelper(dimensions) };\n }, [dimensions]);\n}\n","import { CheckboxMark } from '@ornikar/kitt-icons';\nimport type { ReactElement, ReactNode } from 'react';\nimport type { GestureResponderEvent, PressableProps } from 'react-native';\nimport styled, { css } from 'styled-components/native';\nimport { Icon } from '../../Icon/Icon';\nimport { useKittTheme } from '../../useKittTheme';\n\ninterface CheckboxContainerProps {\n $isChecked: boolean;\n $hasLabel: boolean;\n}\n\nconst CheckboxAndLabelPressableWrapper = styled.Pressable`\n display: flex;\n flex-direction: row;\n`;\n\nconst CheckboxContainer = styled.View<CheckboxContainerProps>`\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: center;\n\n height: ${({ theme }) => theme.kitt.forms.checkbox.height}px;\n width: ${({ theme }) => theme.kitt.forms.checkbox.width}px;\n position: relative;\n border-radius: ${({ theme }) => theme.kitt.forms.checkbox.borderRadius}px;\n\n ${({ $isChecked, theme }) => {\n const { checkedBackgroundColor, checkedBorderColor, borderColor, borderWidth, backgroundColor } =\n theme.kitt.forms.checkbox;\n if ($isChecked) {\n return css`\n background-color: ${checkedBackgroundColor};\n border: ${`${borderWidth}px solid ${checkedBorderColor}`};\n `;\n }\n return css`\n background-color: ${backgroundColor};\n border: ${`${borderWidth}px solid ${borderColor}`};\n `;\n }}\n\n margin-right: ${({ theme, $hasLabel }) => {\n if (!$hasLabel) return '0px';\n return `${theme.kitt.spacing * 2.5}px;`;\n }};\n`;\n\nexport interface CheckboxProps {\n onChange: (checked: boolean, e: GestureResponderEvent) => void;\n onBlur?: (e: any) => void;\n onFocus?: (e: any) => void;\n checked: boolean;\n hitSlop?: number;\n id?: PressableProps['testID'];\n children?: ReactNode;\n}\n\nexport function Checkbox({\n onChange,\n onBlur,\n onFocus,\n checked,\n hitSlop = 40,\n id,\n children,\n}: CheckboxProps): ReactElement {\n const theme = useKittTheme();\n\n const handlePress = (e: GestureResponderEvent): void => {\n if (onFocus) onFocus(e);\n if (onChange) onChange(!checked, e);\n if (onBlur) onBlur(e);\n };\n\n return (\n <CheckboxAndLabelPressableWrapper\n accessibilityRole=\"checkbox\"\n accessibilityState={{ checked }}\n hitSlop={hitSlop}\n onPress={handlePress}\n >\n <CheckboxContainer $isChecked={checked} $hasLabel={!!children} testID={id}>\n {checked ? (\n <Icon\n align=\"center\"\n color={theme.kitt.forms.checkbox.markColor}\n size={theme.kitt.forms.checkbox.iconSize}\n icon={<CheckboxMark />}\n />\n ) : null}\n </CheckboxContainer>\n\n {children}\n </CheckboxAndLabelPressableWrapper>\n );\n}\n","export type InputFormState = undefined | 'valid' | 'invalid' | 'pending';\n\nexport type InputUIState = NonNullable<InputFormState> | 'default' | 'disabled' | 'hover' | 'focus';\n\ninterface GetInputStateConfig {\n isFocused: boolean;\n isDisabled: boolean;\n formState: InputFormState;\n}\n\nexport function getInputUIState({ isFocused, isDisabled, formState }: GetInputStateConfig): InputUIState {\n if (isDisabled) return 'disabled';\n\n if (isFocused) return 'focus';\n\n if (formState === 'invalid') return 'invalid';\n\n return 'default';\n}\n","import { css } from 'styled-components/native';\nimport { getTypographyTypeConfigKey } from '../typography/Typography';\nimport type { InputUIState } from './utils';\n\nexport interface TextInputMixinProps {\n $state: InputUIState;\n}\n\nexport const styledTextInputMixin = css<TextInputMixinProps>`\n background-color: ${({ theme, $state }) =>\n $state === 'disabled'\n ? theme.kitt.forms.input.states.disabled.backgroundColor\n : theme.kitt.forms.input.states.default.backgroundColor};\n\n border-width: ${({ theme }) => theme.kitt.forms.input.borderWidth}px;\n border-radius: ${({ theme }) => theme.kitt.forms.input.borderRadius}px;\n border-color: ${({ theme, $state }) => theme.kitt.forms.input.states[$state].borderColor};\n\n font-size: ${({ theme }) => {\n const typeConfigKey = getTypographyTypeConfigKey(theme);\n return `${theme.kitt.typography.types.bodies.configs.body[typeConfigKey].fontSize}px`;\n }};\n\n color: ${({ theme, $state }) => theme.kitt.typography.colors[theme.kitt.forms.input.states[$state].color]};\n font-family: ${({ theme }) => theme.kitt.typography.types.bodies.fontFamily.regular};\n`;\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\nimport { Typography } from '../../typography/Typography';\nimport type { TextInputMixinProps } from '../styledTextInputMixin';\nimport { styledTextInputMixin } from '../styledTextInputMixin';\n\ntype PartName = 'year' | 'month' | 'day';\n\nconst StyledTypographyText = styled(Typography.Text)`\n text-align: center;\n`;\n\ninterface ViewInputProps extends TextInputMixinProps {\n $partName?: PartName;\n}\n\nconst ViewInput = styled.View<ViewInputProps>`\n ${styledTextInputMixin}\n padding: ${({ theme }) =>\n `${theme.kitt.forms.input.padding.vertical}px ${theme.kitt.forms.input.padding.horizontal}px`};\n\n min-height: ${({ theme }) => theme.kitt.forms.input.minHeight}px;\n min-width: ${({ theme, $partName }) => {\n if (!$partName) {\n return undefined;\n }\n\n return `${theme.kitt.forms.datePicker[$partName].minWidth}px`;\n }};\n`;\n\ninterface DatePickerInputPartProps extends TextInputMixinProps {\n disabled?: boolean;\n partName?: 'year' | 'month' | 'day';\n placeholder?: string;\n value?: ReactNode;\n}\n\nexport function DatePickerInputPart({\n $state,\n placeholder,\n value,\n partName,\n disabled,\n}: DatePickerInputPartProps): ReactElement {\n const hasContent = placeholder || value;\n\n return (\n <ViewInput $state={$state} $partName={partName}>\n {hasContent ? (\n <StyledTypographyText color={!value || disabled ? 'black-light' : undefined}>\n {value || placeholder}\n </StyledTypographyText>\n ) : null}\n </ViewInput>\n );\n}\n","import type { ReactElement } from 'react';\nimport styled, { css } from 'styled-components/native';\nimport { getInputUIState } from '../utils';\nimport { DatePickerInputPart } from './DatePickerInputPart';\nimport type { DatePickerInputsProps } from './types';\n\nfunction prefixWithZero(value: number): string {\n return `${value}`.padStart(2, '0');\n}\n\ninterface PartContainerProps {\n $isLast?: boolean;\n $isStretch?: boolean;\n}\n\nconst PartContainer = styled.View<PartContainerProps>`\n margin-right: ${({ theme, $isLast }) => (!$isLast ? `${theme.kitt.spacing * 2}px` : 0)};\n ${({ $isStretch }) =>\n $isStretch\n ? css`\n flex: 0.33;\n flex-grow: 1;\n `\n : undefined};\n`;\n\ninterface DatePickerPressableProps {\n $isStretch?: boolean;\n}\n\nconst DatePickerPressable = styled.Pressable<DatePickerPressableProps>`\n display: flex;\n flex-direction: row;\n ${({ $isStretch }) => {\n if ($isStretch) {\n return css`\n width: 100%;\n `;\n }\n\n return css`\n align-self: baseline;\n `;\n }};\n`;\n\nexport interface DatePickerPlaceholder {\n day: string;\n month: string;\n year: string;\n}\n\nexport function DatePickerInputs({\n state,\n internalForceState,\n isFocused,\n disabled,\n stretch,\n id,\n testID,\n handleModalOpen,\n currentValue,\n placeholder,\n}: DatePickerInputsProps): ReactElement {\n const currentState =\n internalForceState || getInputUIState({ isFocused, isDisabled: Boolean(disabled), formState: state });\n\n const sharedPartProps = {\n disabled,\n $state: currentState,\n };\n\n return (\n <DatePickerPressable\n $isStretch={stretch}\n nativeID={id}\n disabled={disabled}\n testID={testID}\n onPress={handleModalOpen}\n >\n <PartContainer $isStretch={stretch}>\n <DatePickerInputPart\n {...sharedPartProps}\n partName=\"day\"\n value={currentValue ? prefixWithZero(currentValue.getDate()) : undefined}\n placeholder={placeholder?.day}\n />\n </PartContainer>\n\n <PartContainer $isStretch={stretch}>\n <DatePickerInputPart\n {...sharedPartProps}\n partName=\"month\"\n value={currentValue ? prefixWithZero(currentValue.getMonth() + 1) : undefined}\n placeholder={placeholder?.month}\n />\n </PartContainer>\n\n <PartContainer $isLast $isStretch={stretch}>\n <DatePickerInputPart\n {...sharedPartProps}\n partName=\"year\"\n value={currentValue ? currentValue.getFullYear() : undefined}\n placeholder={placeholder?.year}\n />\n </PartContainer>\n </DatePickerPressable>\n );\n}\n","import { DateTimePickerAndroid } from '@react-native-community/datetimepicker';\nimport type { ReactElement } from 'react';\nimport type { Except } from 'type-fest';\nimport { DatePickerInputs } from './DatePickerInputs';\nimport type { DatePickerProps } from './types';\n\ninterface DatePickerAndroidProps\n extends Except<DatePickerProps, 'pickerUITitle' | 'pickerUIValidateButtonLabel' | 'value'> {\n isFocused: boolean;\n setIsFocused: (isFocused: boolean) => void;\n currentValue: Date | undefined;\n setCurrentValue: (value: Date | undefined) => void;\n}\n\nexport function DatePickerAndroid({\n onBlur,\n onFocus,\n pickerDefaultDate,\n pickerUITestID,\n setIsFocused,\n currentValue,\n setCurrentValue,\n onChange,\n isFocused,\n ...props\n}: DatePickerAndroidProps): ReactElement {\n const handleClose = (): void => {\n if (onBlur) onBlur();\n };\n\n const handleModalOpen = (): void => {\n setIsFocused(true);\n if (onFocus) onFocus();\n\n DateTimePickerAndroid.open({\n testID: pickerUITestID,\n value: currentValue || pickerDefaultDate || new Date(Date.now()),\n onChange: (e) => {\n setIsFocused(false);\n const { timestamp } = e.nativeEvent;\n if (timestamp) {\n const date = new Date(timestamp);\n\n setCurrentValue(date);\n onChange(date);\n handleClose();\n }\n },\n onTouchCancel: handleClose,\n });\n };\n\n return (\n <DatePickerInputs handleModalOpen={handleModalOpen} currentValue={currentValue} isFocused={isFocused} {...props} />\n );\n}\n","import type { ReactElement } from 'react';\nimport type { PressableProps } from 'react-native';\nimport { Pressable, StyleSheet } from 'react-native';\nimport styled from 'styled-components/native';\n\ninterface OverlayProps extends Pick<PressableProps, 'onPress'> {}\n\n// Don't use styled.Pressable here - babel-plugin-styled-components-react-native-web only supports tagged templates\nconst OverlayPressable = styled(Pressable)(({ theme }) => ({\n ...StyleSheet.absoluteFillObject,\n backgroundColor: theme.kitt.colors.overlay.dark,\n}));\n\nexport function Overlay({ onPress }: OverlayProps): ReactElement {\n return <OverlayPressable accessibilityRole=\"none\" onPress={onPress} />;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { ScrollView } from 'react-native';\nimport styled from 'styled-components/native';\n\nconst BodyView = styled.View`\n padding: ${({ theme }) => theme.kitt.spacing * 6}px ${({ theme }) => theme.kitt.spacing * 4}px;\n`;\n\nexport interface BodyProps {\n children: NonNullable<ReactNode>;\n}\n\nexport function ModalBody({ children }: BodyProps): ReactElement {\n return (\n <ScrollView>\n <BodyView>{children}</BodyView>\n </ScrollView>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\n\nexport interface FooterProps {\n children: NonNullable<ReactNode>;\n}\n\nconst FooterView = styled.View`\n flex: 0 0 auto;\n padding: ${({ theme }) => theme.kitt.spacing * 4}px;\n border-top-width: 1px;\n border-top-color: ${({ theme }) => theme.kitt.colors.separator};\n`;\n\nexport function ModalFooter({ children }: FooterProps): ReactElement {\n return <FooterView>{children}</FooterView>;\n}\n","import type { ComponentProps, ElementType, ReactElement, ReactNode } from 'react';\nimport { Platform } from 'react-native';\n\nexport interface StyleWebWrapperProps<T extends ElementType> {\n as: T;\n children: ReactNode;\n}\n\nexport function StyleWebWrapper<T extends ElementType = 'div'>({\n as,\n children,\n ...props\n}: StyleWebWrapperProps<T> & ComponentProps<T>): ReactElement {\n if (Platform.OS !== 'web') return children as ReactElement;\n const Component: T = as || ('div' as T); // as or default to div. If as is undefined, T is div but typescript is not sure\n return <Component {...(props as any)}>{children}</Component>;\n}\n","import type { ComponentType, ForwardRefExoticComponent, PropsWithoutRef, RefAttributes } from 'react';\nimport { forwardRef } from 'react';\nimport { useTheme } from 'styled-components/native';\nimport type { DefaultTheme } from 'styled-components/native';\nimport type { Except } from 'type-fest';\n\n// type $Without<T, K extends keyof any> = T extends any ? Pick<T, Exclude<keyof T, K>> : never;\n// type $DeepPartial<T> = { [P in keyof T]?: $DeepPartial<T[P]> };\n\n// export function withTheme<Props extends { theme: DefaultTheme }, C>(\n// WrappedComponent: ComponentType<Props> & C,\n// ): ComponentType<SetOptional<Props, 'theme'>> & hoistNonReactStatics.NonReactStatics<typeof WrappedComponent> {\n// return function ThemedComponent(props) {\n// const theme = useTheme();\n\n// return (<WrappedComponent theme={theme} {...(props as any)} />) as any;\n// };\n// }\n\nexport function withTheme<Props extends { theme: DefaultTheme }, T>(\n WrappedComponent: ComponentType<Props>,\n): ForwardRefExoticComponent<PropsWithoutRef<Except<Props, 'theme'>> & RefAttributes<T>> {\n // eslint-disable-next-line prefer-arrow-callback\n return forwardRef<T, Except<Props, 'theme'>>(function ThemedComponent(props, ref) {\n const theme = useTheme();\n\n return <WrappedComponent ref={ref} theme={theme} {...(props as any)} />;\n });\n}\n","import { styled as styledLinaria } from '@linaria/react';\nimport type { ReactElement } from 'react';\nimport type { PressableProps } from 'react-native';\nimport { Platform } from 'react-native';\nimport type { DefaultTheme } from 'styled-components/native';\nimport styled from 'styled-components/native';\nimport { theme as kittTheme } from '../themes/default';\nimport { StyleWebWrapper } from '../utils/StyleWebWrapper';\nimport { withTheme } from '../utils/withTheme';\nimport type { IconButtonContentProps } from './IconButton';\n\ninterface PressableIconButtonWebWrapperProps {\n theme: DefaultTheme;\n $isWhite?: boolean;\n $isDisabled?: boolean;\n}\n\nconst PressableIconButtonWebWrapper = withTheme(styledLinaria.div<PressableIconButtonWebWrapperProps>`\n & > *:hover,\n .kitt-hover & > * {\n @media (hover: none) and (pointer: coarse) {\n transform: scale(${({ theme, $isDisabled }) => ($isDisabled ? 1 : theme.kitt.iconButton.scale.base.hover)});\n }\n\n @media (${kittTheme.breakpoints.min.mediumBreakpoint}) {\n transform: scale(${({ theme, $isDisabled }) => ($isDisabled ? 1 : theme.kitt.iconButton.scale.medium.hover)});\n }\n }\n\n & > *:active,\n .kitt-active & > * {\n transform: scale(${({ theme, $isDisabled }) => ($isDisabled ? 1 : theme.kitt.iconButton.scale.base.active)});\n }\n\n &,\n & > [data-focusvisible-polyfill] {\n outline: none;\n }\n\n & > *:hover,\n .kitt-hover & > *,\n & > *:focus,\n .kitt-focus & > *,\n & > [data-focusvisible-polyfill],\n & > *:active,\n .kitt-active & > * {\n background-color: ${({ theme, $isWhite, $isDisabled }) => {\n if ($isDisabled) return theme.kitt.iconButton.disabled.backgroundColor;\n\n const { white, default: defaultIconButton } = theme.kitt.iconButton;\n\n if ($isWhite) return white.pressedBackgroundColor;\n return defaultIconButton.pressedBackgroundColor;\n }};\n }\n`);\n\nconst StyledPressableIconButton = styled.Pressable`\n border-radius: ${({ theme }) => theme.kitt.iconButton.borderRadius}px;\n width: ${({ theme }) => theme.kitt.iconButton.width}px;\n height: ${({ theme }) => theme.kitt.iconButton.height}px;\n align-items: center;\n justify-content: center;\n position: relative;\n background-color: transparent;\n\n ${({ theme, disabled }) => {\n const { iconButton } = theme.kitt;\n\n if (Platform.OS !== 'web') {\n return undefined;\n }\n\n const { transition } = iconButton;\n\n if (disabled) {\n return `\n background-color: ${iconButton.disabled.backgroundColor};\n `;\n }\n\n return `\n transition: ${transition.property} ${transition.duration} ${transition.timingFunction};\n `;\n }};\n`;\n\nexport interface PressableIconButtonProps extends PressableProps {\n color: IconButtonContentProps['color'];\n}\n\nexport function PressableIconButton({ color, disabled, ...props }: PressableIconButtonProps): ReactElement {\n return (\n <StyleWebWrapper as={PressableIconButtonWebWrapper} $isWhite={color === 'white'} $isDisabled={Boolean(disabled)}>\n <StyledPressableIconButton {...props} disabled={disabled} />\n </StyleWebWrapper>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport Animated, { useAnimatedStyle, useSharedValue, withSpring } from 'react-native-reanimated';\nimport styled, { useTheme } from 'styled-components/native';\nimport type { IconButtonContentProps } from './IconButton';\nimport type { PressableIconButtonProps } from './PressableIconButton';\nimport { PressableIconButton } from './PressableIconButton';\n\nexport interface PressableAnimatedContainerProps {\n children: NonNullable<ReactNode>;\n disabled?: boolean;\n color: IconButtonContentProps['color'];\n testID?: IconButtonContentProps['testID'];\n accessibilityLabel?: IconButtonContentProps['accessibilityLabel'];\n accessibilityRole?: IconButtonContentProps['accessibilityRole'];\n onPress: NonNullable<PressableIconButtonProps['onPress']>;\n}\n\ninterface AnimatedIconButtonBackgroundProps {\n color: IconButtonContentProps['color'];\n disabled?: boolean;\n}\n\nconst AnimatedIconButtonBackground = styled(Animated.View)<AnimatedIconButtonBackgroundProps>`\n background-color: ${({ theme, color, disabled }) => {\n const { iconButton } = theme.kitt;\n if (disabled) return iconButton.disabled.backgroundColor;\n\n if (color === 'white') return iconButton.white.pressedBackgroundColor;\n\n return iconButton.default.pressedBackgroundColor;\n }};\n border-radius: ${({ theme }) => theme.kitt.iconButton.borderRadius}px;\n width: ${({ theme }) => theme.kitt.iconButton.width}px;\n height: ${({ theme }) => theme.kitt.iconButton.height}px;\n position: absolute;\n bottom: 0;\n left: 0;\n`;\n\nconst AnimatedViewContainer = styled(Animated.View)`\n position: relative;\n align-items: center;\n justify-content: center;\n width: 100%;\n height: 100%;\n`;\n\nexport function PressableAnimatedContainer({\n disabled,\n color = 'black',\n testID,\n accessibilityRole = 'button',\n accessibilityLabel,\n children,\n onPress,\n}: PressableAnimatedContainerProps): ReactElement {\n const theme = useTheme();\n const pressed = useSharedValue(false);\n\n const opacityStyles = useAnimatedStyle(() => {\n return {\n opacity: withSpring(pressed.value ? 1 : 0),\n };\n });\n\n const scaleStyles = useAnimatedStyle(() => {\n return {\n transform: [\n {\n scale: withSpring(\n pressed.value ? theme.kitt.iconButton.scale.base.active : theme.kitt.iconButton.scale.base.default,\n ),\n },\n ],\n };\n });\n\n return (\n <PressableIconButton\n accessibilityRole={accessibilityRole}\n disabled={disabled}\n color={color}\n testID={testID}\n accessibilityLabel={accessibilityLabel}\n onPress={onPress}\n onPressIn={() => {\n pressed.value = true;\n }}\n onPressOut={() => {\n pressed.value = false;\n }}\n >\n <AnimatedViewContainer style={disabled ? [{ transform: [{ scale: 1 }] }] : [scaleStyles]}>\n <AnimatedIconButtonBackground\n disabled={disabled}\n color={color}\n style={disabled ? [{ opacity: 1 }] : [opacityStyles]}\n />\n {children}\n </AnimatedViewContainer>\n </PressableIconButton>\n );\n}\n","import type { ReactElement } from 'react';\nimport type { AccessibilityRole } from 'react-native';\nimport styled from 'styled-components/native';\nimport { TypographyIcon } from '../typography/TypographyIcon';\nimport { PressableAnimatedContainer } from './PressableAnimatedContainer';\n\ninterface IconButtonContentBorderProps {\n disabled?: boolean;\n}\n\nconst IconButtonContentBorder = styled.View<IconButtonContentBorderProps>`\n border: ${({ theme }) => `${theme.kitt.iconButton.borderWidth}px solid`};\n border-color: ${({ theme, disabled }) =>\n disabled ? theme.kitt.iconButton.disabled.borderColor : theme.kitt.iconButton.borderColor};\n width: ${({ theme }) => theme.kitt.iconButton.width - theme.kitt.iconButton.borderWidth}px;\n height: ${({ theme }) => theme.kitt.iconButton.height - theme.kitt.iconButton.borderWidth}px;\n align-items: center;\n justify-content: center;\n border-radius: ${({ theme }) => theme.kitt.iconButton.borderRadius}px;\n`;\nexport interface IconButtonContentProps {\n icon: NonNullable<ReactElement>;\n color?: 'black' | 'white';\n disabled?: boolean;\n testID?: string;\n accessibilityLabel?: string;\n accessibilityRole?: AccessibilityRole;\n}\n\nfunction IconButtonContent({ disabled, color, icon }: IconButtonContentProps): ReactElement {\n return (\n <IconButtonContentBorder disabled={disabled}>\n <TypographyIcon color={disabled ? 'black-light' : color} icon={icon} />\n </IconButtonContentBorder>\n );\n}\n\nexport interface IconButtonProps extends IconButtonContentProps {\n onPress: () => void;\n}\n\nexport function IconButton({\n icon,\n color,\n disabled,\n testID,\n accessibilityLabel,\n accessibilityRole,\n onPress,\n}: IconButtonProps): ReactElement {\n return (\n <PressableAnimatedContainer\n color={color}\n disabled={disabled}\n testID={testID}\n accessibilityLabel={accessibilityLabel}\n accessibilityRole={accessibilityRole}\n onPress={onPress}\n >\n <IconButtonContent disabled={disabled} color={color} icon={icon} />\n </PressableAnimatedContainer>\n );\n}\n","import { createContext } from 'react';\n\nexport const OnCloseContext = createContext<() => void>(() => {});\n","import { XIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement, ReactNode } from 'react';\nimport { useContext } from 'react';\nimport styled from 'styled-components/native';\nimport { IconButton } from '../IconButton/IconButton';\nimport { OnCloseContext } from './OnCloseContext';\n\nexport interface HeaderProps {\n children: NonNullable<ReactNode>;\n left?: ReactNode;\n right?: ReactNode;\n}\n\nconst HeaderView = styled.View`\n position: relative;\n padding: ${({ theme }) => theme.kitt.spacing * 2}px;\n display: flex;\n flex: 0 0 auto;\n flex-direction: row;\n justify-content: space-between;\n align-items: center;\n border-bottom-width: 1px;\n border-bottom-color: ${({ theme }) => theme.kitt.colors.separator};\n min-height: 57px;\n`;\n\nconst LeftIconView = styled.View`\n align-self: flex-start;\n margin-right: ${({ theme }) => theme.kitt.spacing * 2}px;\n`;\n\nconst RightIconView = styled.View`\n align-self: flex-start;\n margin-left: ${({ theme }) => theme.kitt.spacing * 2}px;\n`;\n\ninterface TitleViewProps {\n isIconLeft?: boolean;\n}\n\nconst TitleView = styled.View<TitleViewProps>`\n padding-left: ${({ theme, isIconLeft }) => (isIconLeft ? 0 : theme.kitt.spacing * 2)}px;\n flex-shrink: 1;\n`;\n\nexport function ModalHeader({ left, right, children }: HeaderProps): ReactElement {\n const onClose = useContext(OnCloseContext);\n\n const isIconLeft = !!left;\n\n return (\n <HeaderView>\n {isIconLeft && <LeftIconView>{left}</LeftIconView>}\n\n <TitleView isIconLeft={isIconLeft}>{children}</TitleView>\n\n {right !== undefined ? (\n right\n ) : (\n <RightIconView>\n <IconButton icon={<XIcon />} onPress={onClose} />\n </RightIconView>\n )}\n </HeaderView>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { Modal as NativeModal } from 'react-native';\nimport styled from 'styled-components/native';\nimport { Overlay } from '../Overlay/Overlay';\nimport { ModalBody } from './Body';\nimport { ModalFooter } from './Footer';\nimport { ModalHeader } from './Header';\nimport { OnCloseContext } from './OnCloseContext';\n\nexport interface ModalProps {\n visible: boolean;\n children: ReactNode;\n onClose: () => void;\n onEntered?: () => void;\n onExited?: () => void;\n}\n\nconst ModalView = styled.View`\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n\n display: flex;\n align-items: center;\n justify-content: center;\n padding: ${({ theme }) => theme.kitt.spacing * 20}px ${({ theme }) => theme.kitt.spacing * 4}px;\n`;\n\nconst ContentView = styled.View`\n position: relative;\n display: flex;\n flex-direction: column;\n max-height: 100%;\n max-width: 540px;\n height: auto;\n width: 100%;\n border-radius: ${({ theme }) => theme.kitt.card.borderRadius}px;\n background-color: ${({ theme }) => theme.kitt.colors.uiBackgroundLight};\n`;\n\nexport function Modal({ visible, children, onClose, onEntered, onExited }: ModalProps): ReactElement {\n return (\n <OnCloseContext.Provider value={onClose}>\n <NativeModal\n transparent\n animationType=\"fade\"\n visible={visible}\n onShow={onEntered}\n onDismiss={onExited}\n onRequestClose={onClose}\n >\n <ModalView>\n <Overlay onPress={onClose} />\n\n <ContentView>{children}</ContentView>\n </ModalView>\n </NativeModal>\n </OnCloseContext.Provider>\n );\n}\n\nModal.Header = ModalHeader;\nModal.Body = ModalBody;\nModal.Footer = ModalFooter;\n","import DateTimePicker from '@react-native-community/datetimepicker';\nimport type { DateTimePickerEvent } from '@react-native-community/datetimepicker';\nimport type { ComponentProps, ReactElement } from 'react';\nimport { Platform } from 'react-native';\nimport { useTheme } from 'styled-components/native';\n\ntype DateTimePickerProps = ComponentProps<typeof DateTimePicker>;\n\nfunction getDatePickerDisplayMode(): DateTimePickerProps['display'] {\n if (Platform.OS === 'android') return 'calendar';\n\n if (Platform.OS === 'ios') return 'spinner';\n\n return 'default';\n}\n\nexport interface PlatformDateTimePickerProps {\n value?: Date;\n defaultDate?: Date;\n maximumDate?: DateTimePickerProps['maximumDate'];\n minimuDate?: DateTimePickerProps['minimumDate'];\n testID?: DateTimePickerProps['testID'];\n onChange: (newDate?: Date) => void;\n}\n\nexport function PlatformDateTimePicker({\n value,\n defaultDate = new Date(),\n maximumDate,\n minimuDate,\n testID,\n onChange,\n}: PlatformDateTimePickerProps): ReactElement {\n const theme = useTheme();\n const displayMode = getDatePickerDisplayMode();\n\n const iosProps = Platform.OS === 'ios' ? { textColor: theme.kitt.colors.primary } : {};\n\n return (\n <DateTimePicker\n is24Hour\n testID={testID}\n value={value || defaultDate}\n mode=\"date\"\n maximumDate={maximumDate}\n minimumDate={minimuDate}\n display={displayMode}\n {...iosProps}\n onChange={(_event: DateTimePickerEvent, date?: Date | undefined) => onChange(date)}\n />\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { useState } from 'react';\nimport { FormattedMessage } from 'react-intl';\nimport { Text } from 'react-native';\nimport { Button } from '../../Button/Button';\nimport { Modal } from '../../Modal/Modal';\nimport { Typography } from '../../typography/Typography';\nimport type { PlatformDateTimePickerProps } from './PlatformDateTimePicker';\nimport { PlatformDateTimePicker } from './PlatformDateTimePicker';\n\ninterface ModalTitleProps {\n children: NonNullable<ReactNode>;\n}\n\nfunction ModalTitle({ children }: ModalTitleProps): ReactElement {\n return (\n <Modal.Header>\n <Typography.Text base=\"body\" variant=\"bold\">\n {children}\n </Typography.Text>\n </Modal.Header>\n );\n}\n\ninterface ModalPlatformDateTimePickerProps extends PlatformDateTimePickerProps {\n title?: ReactNode;\n isVisible?: boolean;\n validateButtonLabel?: string;\n onClose: () => void;\n}\n\nexport function ModalPlatformDateTimePicker({\n title,\n isVisible,\n value,\n validateButtonLabel,\n onClose,\n onChange,\n ...props\n}: ModalPlatformDateTimePickerProps): ReactElement {\n const [currentValue, setCurrentValue] = useState(value);\n\n // Prevent unsynced value between the modal and its parent state\n const handleClose = (): void => {\n setCurrentValue(value);\n onClose();\n };\n\n const handleSubmit = (): void => {\n onChange(currentValue);\n };\n\n const handleChange = (newDate?: Date): void => {\n setCurrentValue((prev) => {\n return newDate || prev;\n });\n };\n\n return (\n <Modal visible={Boolean(isVisible)} onClose={handleClose}>\n {isVisible ? (\n <>\n {title ? <ModalTitle>{title}</ModalTitle> : null}\n\n <Modal.Body>\n <PlatformDateTimePicker {...props} value={currentValue} onChange={handleChange} />\n </Modal.Body>\n\n <Modal.Footer>\n <Button stretch type=\"primary\" onPress={handleSubmit}>\n {validateButtonLabel ? (\n <Text>{validateButtonLabel}</Text>\n ) : (\n <FormattedMessage id=\"kitt-universal.ModalDateTimePicker.confirm\" defaultMessage=\"Valider\" />\n )}\n </Button>\n </Modal.Footer>\n </>\n ) : null}\n </Modal>\n );\n}\n","import type { ReactElement } from 'react';\nimport { useState } from 'react';\nimport { Platform } from 'react-native';\nimport { DatePickerAndroid } from './DatePickerAndroid';\nimport { DatePickerInputs } from './DatePickerInputs';\nimport { ModalPlatformDateTimePicker } from './ModalPlatformDateTimePicker';\nimport type { DatePickerProps } from './types';\n\nexport function DatePicker({\n value,\n pickerUITestID,\n pickerUITitle,\n pickerUIValidateButtonLabel,\n onChange,\n onFocus,\n onBlur,\n pickerDefaultDate,\n ...props\n}: DatePickerProps): ReactElement {\n const [isPickerUIVisible, setIsPickerUIVisible] = useState(false);\n const [isFocused, setIsFocused] = useState(false);\n const [currentValue, setCurrentValue] = useState<Date | undefined>(value);\n\n if (Platform.OS === 'android') {\n return (\n <DatePickerAndroid\n pickerDefaultDate={pickerDefaultDate}\n pickerUITestID={pickerUITestID}\n currentValue={currentValue}\n setCurrentValue={setCurrentValue}\n isFocused={isFocused}\n setIsFocused={setIsFocused}\n onChange={onChange}\n onBlur={onBlur}\n {...props}\n />\n );\n }\n\n const handleModalOpen = (): void => {\n if (onFocus) onFocus();\n\n setIsPickerUIVisible(true);\n\n setIsFocused(true);\n };\n\n const handleModalClose = (): void => {\n if (onBlur) onBlur();\n\n setIsPickerUIVisible(false);\n\n setIsFocused(false);\n };\n\n const handleChange = (newDate?: Date): void => {\n setCurrentValue(newDate);\n\n onChange(newDate);\n\n handleModalClose();\n };\n return (\n <>\n <DatePickerInputs\n handleModalOpen={handleModalOpen}\n currentValue={currentValue}\n isFocused={isFocused}\n {...props}\n />\n <ModalPlatformDateTimePicker\n testID={pickerUITestID}\n value={currentValue}\n isVisible={isPickerUIVisible}\n title={pickerUITitle}\n validateButtonLabel={pickerUIValidateButtonLabel}\n defaultDate={pickerDefaultDate}\n onClose={handleModalClose}\n onChange={handleChange}\n />\n </>\n );\n}\n","import type { ReactNode } from 'react';\nimport styled from 'styled-components/native';\n\nexport interface InputTextContainerProps {\n children: NonNullable<ReactNode>;\n $isDisabled?: boolean;\n}\n\nexport const InputTextContainer = styled.View<InputTextContainerProps>`\n position: relative;\n`;\n","import type { ReactElement, ReactNode } from 'react';\nimport { forwardRef, useState } from 'react';\nimport type { TextInput as RNTextInput, TextInputProps as RNTextInputProps } from 'react-native';\nimport { Platform, TextInput } from 'react-native';\nimport styled, { useTheme } from 'styled-components/native';\nimport { getTypographyTypeConfigKey } from '../../typography/Typography';\nimport type { TextInputMixinProps } from '../styledTextInputMixin';\nimport { styledTextInputMixin } from '../styledTextInputMixin';\nimport type { InputFormState, InputUIState } from '../utils';\nimport { getInputUIState } from '../utils';\nimport { InputTextContainer } from './InputTextContainer';\n\nexport interface InputTextProps extends Exclude<RNTextInputProps, 'nativeID'> {\n id?: string;\n name?: string;\n disabled?: boolean;\n minHeight?: number;\n state?: InputFormState;\n right?: ReactNode;\n /** @internal */\n internalForceState?: InputUIState;\n}\n\ninterface StyledTextInputProps extends TextInputMixinProps {\n $minHeight?: number;\n}\n\nconst StyledTextInput = styled(TextInput)<StyledTextInputProps>`\n ${styledTextInputMixin}\n\n padding: ${({ theme, multiline }) => {\n if (!multiline && Platform.OS !== 'web') return `0 ${theme.kitt.forms.input.padding.horizontal}px`;\n\n return `${theme.kitt.forms.input.padding.vertical}px ${theme.kitt.forms.input.padding.horizontal}px`;\n }};\n\n line-height: ${({ theme, multiline }) => {\n if (!multiline && Platform.OS !== 'web') return 0;\n\n const typeConfigKey = getTypographyTypeConfigKey(theme);\n return `${theme.kitt.typography.types.bodies.configs.body[typeConfigKey].lineHeight}px`;\n }};\n\n width: 100%;\n min-height: ${({ theme, $minHeight = theme.kitt.forms.input.minHeight }) => $minHeight}px;\n`;\n\nconst RightInputContainer = styled.View`\n position: absolute;\n right: 0;\n top: 0;\n bottom: 0;\n justify-content: center;\n padding: 10px;\n`;\n\nexport const InputText = forwardRef<RNTextInput, InputTextProps>(\n (\n {\n id,\n right,\n minHeight,\n state: formState,\n internalForceState,\n disabled = false,\n autoCorrect = true,\n textContentType = 'none',\n autoCompleteType = 'off',\n keyboardType = 'default',\n multiline,\n onSubmitEditing,\n onFocus,\n onBlur,\n ...props\n }: InputTextProps,\n ref,\n ): ReactElement => {\n const theme = useTheme();\n const [isFocused, setIsFocused] = useState<boolean>(false);\n\n const state = internalForceState || getInputUIState({ isFocused, isDisabled: disabled, formState });\n\n return (\n <InputTextContainer $isDisabled={disabled}>\n <StyledTextInput\n ref={ref}\n multiline={multiline}\n nativeID={id}\n editable={!disabled}\n keyboardType={keyboardType}\n autoCompleteType={autoCompleteType}\n autoCorrect={autoCorrect}\n $minHeight={minHeight}\n textContentType={textContentType}\n placeholderTextColor={theme.kitt.forms.input.color.placeholder}\n selectionColor={theme.kitt.forms.input.color.selection}\n {...props}\n $state={state}\n onFocus={(e) => {\n setIsFocused(true);\n if (onFocus) onFocus(e);\n }}\n onBlur={(e) => {\n setIsFocused(false);\n if (onBlur) onBlur(e);\n }}\n onSubmitEditing={multiline ? () => null : onSubmitEditing}\n />\n {right ? <RightInputContainer>{right}</RightInputContainer> : null}\n </InputTextContainer>\n );\n },\n);\n","import type { ReactElement } from 'react';\nimport type { Except } from 'type-fest';\nimport type { InputTextProps } from '../InputText/InputText';\nimport { InputText } from '../InputText/InputText';\n\nexport interface InputEmailProps\n extends Except<InputTextProps, 'autoCompleteType' | 'keyboardType' | 'textContentType' | 'autoCapitalize'> {}\n\nexport function InputEmail(props: InputEmailProps): ReactElement {\n return (\n <InputText\n autoCompleteType=\"email\"\n keyboardType=\"email-address\"\n textContentType=\"emailAddress\"\n autoCapitalize=\"none\"\n {...props}\n />\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport type { TypographyColor, TypographyProps } from '../../typography/Typography';\nimport { Typography } from '../../typography/Typography';\nimport type { InputFormState } from '../utils';\n\nexport interface InputFeedbackProps {\n state?: InputFormState;\n testID?: TypographyProps['testID'];\n children: NonNullable<ReactNode>;\n}\n\nconst getColorFromState = (state?: InputFormState): TypographyColor => {\n switch (state) {\n case 'invalid':\n return 'danger';\n case 'valid':\n default:\n return 'black-light';\n }\n};\n\nexport function InputFeedback({ state, testID, children }: InputFeedbackProps): ReactElement {\n return (\n <Typography.Text base=\"body-small\" color={getColorFromState(state)} testID={testID}>\n {children}\n </Typography.Text>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\nimport { KittBreakpoints } from '../../KittBreakpoints';\n\nconst FieldContainer = styled.View`\n padding: 5px 0 10px;\n`;\n\nconst FeedbackContainer = styled.View`\n ${({ theme }) =>\n theme.responsive.ifWindowSizeMatches({ minWidth: KittBreakpoints.SMALL }, 'padding-top: 10px', 'padding-top: 5px')};\n`;\n\nconst FieldLabelContainer = styled.View`\n flex-direction: row;\n align-items: center;\n padding-bottom: ${({ theme }) => theme.kitt.forms.inputField.labelContainerPaddingBottom}px;\n`;\n\nconst LabelContainer = styled.View`\n margin-right: ${({ theme }) => theme.kitt.forms.inputField.iconMarginLeft}px;\n`;\n\nexport interface InputFieldProps {\n label?: ReactNode;\n labelFeedback?: ReactNode;\n input: NonNullable<ReactNode>;\n feedback?: ReactNode;\n}\n\nexport function InputField({ label, labelFeedback, input, feedback }: InputFieldProps): ReactElement {\n return (\n <FieldContainer>\n {label ? (\n <FieldLabelContainer>\n <LabelContainer>{label}</LabelContainer>\n {labelFeedback}\n </FieldLabelContainer>\n ) : null}\n {input}\n {feedback ? <FeedbackContainer>{feedback}</FeedbackContainer> : null}\n </FieldContainer>\n );\n}\n","import type { ReactElement } from 'react';\nimport { useTheme } from 'styled-components/native';\nimport type { InputFormState } from 'forms/utils';\nimport type { TypographyIconProps } from '../../typography/TypographyIcon';\nimport { TypographyIcon } from '../../typography/TypographyIcon';\n\nfunction getIconColor(state?: InputFormState, disabled?: boolean): TypographyIconProps['color'] {\n if (disabled) return 'black-light';\n\n switch (state) {\n case 'invalid':\n return 'danger';\n case 'valid':\n return 'success';\n default:\n return undefined;\n }\n}\n\nexport interface InputIconProps {\n icon: NonNullable<ReactElement>;\n disabled?: boolean;\n state?: InputFormState;\n}\n\nexport function InputIcon({ icon, state, disabled }: InputIconProps): ReactElement {\n const theme = useTheme();\n\n const color = getIconColor(state, disabled);\n\n return <TypographyIcon color={color} icon={icon} size={theme.kitt.forms.input.icon.size} />;\n}\n","import type { ReactElement } from 'react';\nimport type { PressableProps } from 'react-native';\nimport { Pressable } from 'react-native';\n\nexport interface InputPressableProps extends PressableProps {}\n\nexport function InputPressable({ ...props }: InputPressableProps): ReactElement {\n return <Pressable {...props} />;\n}\n","import { EyeIcon, EyeOffIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement } from 'react';\nimport { useState } from 'react';\nimport { InputIcon } from '../InputIcon/InputIcon';\nimport { InputPressable } from '../InputPressable/InputPressable';\nimport type { InputTextProps } from '../InputText/InputText';\nimport { InputText } from '../InputText/InputText';\n\nexport interface InputPasswordProps extends InputTextProps {\n isPasswordDefaultVisible?: boolean;\n}\n\nexport function InputPassword({ isPasswordDefaultVisible, right, ...props }: InputPasswordProps): ReactElement {\n const [isVisible, setIsVisible] = useState(Boolean(isPasswordDefaultVisible));\n\n return (\n <InputText\n {...props}\n textContentType=\"password\"\n autoCompleteType=\"password\"\n autoCorrect={false}\n secureTextEntry={!isVisible}\n right={\n right || (\n <InputPressable accessibilityRole=\"button\" onPress={() => setIsVisible((prev) => !prev)}>\n <InputIcon icon={isVisible ? <EyeOffIcon /> : <EyeIcon />} />\n </InputPressable>\n )\n }\n />\n );\n}\n","import type { ReactElement } from 'react';\nimport type { Except } from 'type-fest';\nimport type { InputTextProps } from '../InputText/InputText';\nimport { InputText } from '../InputText/InputText';\n\nexport interface InputPhoneProps\n extends Except<InputTextProps, 'autoCompleteType' | 'keyboardType' | 'textContentType'> {}\n\nexport function InputPhone(props: InputPhoneProps): ReactElement {\n return <InputText {...props} autoCompleteType=\"tel\" keyboardType=\"number-pad\" textContentType=\"telephoneNumber\" />;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { View } from 'react-native';\nimport styled from 'styled-components/native';\nimport type { TypographyColor } from '../../typography/Typography';\nimport { Typography } from '../../typography/Typography';\nimport { TypographyIcon } from '../../typography/TypographyIcon';\nimport { useKittTheme } from '../../useKittTheme';\n\ntype InputTagType = 'success' | 'danger';\n\nconst getTypographyColor = (type: InputTagType | undefined): TypographyColor => (type ? 'white' : 'black');\n\ninterface InputTagContainerProps {\n type?: InputTagType;\n}\n\nconst InputTagContainer = styled(View)<InputTagContainerProps>`\n align-items: center;\n justify-content: center;\n flex-direction: row;\n align-self: flex-start;\n overflow: hidden;\n padding-horizontal: ${({ theme }) => theme.kitt.spacing * 2}px;\n\n background-color: ${({ theme, type }) => {\n if (type === 'success') {\n return theme.kitt.forms.inputTag.success.backgroundColor;\n }\n if (type === 'danger') {\n return theme.kitt.forms.inputTag.danger.backgroundColor;\n }\n\n return theme.kitt.forms.inputTag.default.backgroundColor;\n }};\n border-radius: ${({ theme }) => theme.kitt.forms.inputTag.borderRadius}px;\n`;\n\nconst IconContainer = styled(View)`\n margin-right: ${({ theme }) => theme.kitt.spacing}px;\n`;\n\nexport interface InputTagProps {\n type?: InputTagType;\n children: ReactNode;\n icon?: ReactElement;\n}\n\nexport function InputTag({ children, type, icon }: InputTagProps): ReactElement {\n const typographyColor = getTypographyColor(type);\n const theme = useKittTheme();\n\n return (\n <InputTagContainer type={type}>\n {icon && (\n <IconContainer>\n <TypographyIcon icon={icon} size={theme.kitt.forms.inputTag.iconSize} color={typographyColor} />\n </IconContainer>\n )}\n <Typography.Text base=\"body-small\" color={typographyColor}>\n {children}\n </Typography.Text>\n </InputTagContainer>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { Platform } from 'react-native';\nimport { Typography } from '../../typography/Typography';\n\nexport interface LabelProps {\n htmlFor: string;\n children: NonNullable<ReactNode>;\n}\n\nexport function Label({ htmlFor, children }: LabelProps): ReactElement {\n return (\n <Typography.Text base=\"body\">\n {Platform.OS === 'web' ? <label htmlFor={htmlFor}>{children}</label> : children}\n </Typography.Text>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport type { PressableProps } from 'react-native';\nimport styled from 'styled-components/native';\nimport { Typography } from '../../typography/Typography';\n\nexport interface RadioProps {\n id: string;\n name: string;\n checked?: boolean;\n disabled?: boolean;\n right?: boolean;\n children?: NonNullable<ReactNode>;\n value: string;\n onChange: (newValue: string) => void;\n}\n\ninterface OuterRadioProps {\n disabled: boolean;\n}\n\nconst OuterRadio = styled.View<OuterRadioProps>`\n background-color: ${({ theme, disabled }) =>\n theme.kitt.forms.radio[disabled ? 'disabled' : 'unchecked'].backgroundColor};\n width: ${({ theme }) => theme.kitt.forms.radio.size}px;\n height: ${({ theme }) => theme.kitt.forms.radio.size}px;\n border-radius: ${({ theme }) => theme.kitt.forms.radio.size / 2}px;\n border-width: ${({ theme }) => theme.kitt.forms.radio.unchecked.borderWidth}px;\n border-color: ${({ theme, disabled }) => theme.kitt.forms.radio[disabled ? 'disabled' : 'unchecked'].borderColor};\n`;\nconst SelectedOuterRadio = styled.View`\n background-color: ${({ theme }) => theme.kitt.forms.radio.checked.backgroundColor};\n width: ${({ theme }) => theme.kitt.forms.radio.size}px;\n height: ${({ theme }) => theme.kitt.forms.radio.size}px;\n border-radius: ${({ theme }) => theme.kitt.forms.radio.size / 2}px;\n justify-content: center;\n align-items: center;\n`;\nconst SelectedInnerRadio = styled.View`\n background-color: ${({ theme }) => theme.kitt.forms.radio.checked.innerBackgroundColor};\n width: ${({ theme }) => theme.kitt.forms.radio.checked.innerSize}px;\n height: ${({ theme }) => theme.kitt.forms.radio.checked.innerSize}px;\n border-radius: ${({ theme }) => theme.kitt.forms.radio.checked.innerSize / 2}px;\n`;\nconst Container = styled.Pressable`\n flex-direction: row;\n align-items: center;\n`;\n\nconst Text = styled(Typography.Text)`\n margin-left: ${({ theme }) => theme.kitt.spacing * 2}px;\n`;\n\nexport function Radio({ id, checked, onChange, value, disabled = false, children }: RadioProps): ReactElement {\n const handlePress: PressableProps['onPress'] = () => {\n onChange(value);\n };\n\n return (\n <Container\n nativeID={id}\n disabled={disabled}\n accessibilityRole=\"radio\"\n aria-checked={checked}\n focusable={checked && !disabled}\n onPress={handlePress}\n >\n {checked && !disabled ? (\n <SelectedOuterRadio>\n <SelectedInnerRadio />\n </SelectedOuterRadio>\n ) : (\n <OuterRadio disabled={disabled} />\n )}\n\n <Text base=\"body\" color={disabled ? 'black-light' : 'black'}>\n {children}\n </Text>\n </Container>\n );\n}\n","import type { ReactElement } from 'react';\nimport { useTheme } from 'styled-components/native';\nimport type { InputTextProps } from '../InputText/InputText';\nimport { InputText } from '../InputText/InputText';\n\nexport interface TextAreaProps extends InputTextProps {}\n\nexport function TextArea({ ...props }: TextAreaProps): ReactElement {\n const theme = useTheme();\n\n return <InputText multiline textAlignVertical=\"top\" minHeight={theme.kitt.forms.textArea.minHeight} {...props} />;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\nimport { KittBreakpoints } from '../KittBreakpoints';\n\nconst Body = styled.View`\n ${({ theme }) =>\n theme.responsive.ifWindowSizeMatches(\n { minWidth: KittBreakpoints.MEDIUM },\n `padding-right: ${theme.kitt.spacing * 12}px;\n padding-left: ${theme.kitt.spacing * 12}px;`,\n `padding-right: ${theme.kitt.spacing * 6}px;\n padding-left: ${theme.kitt.spacing * 6}px;`,\n )}\n background-color: ${({ theme }) => theme.kitt.colors.uiBackgroundLight};\n flex: 1;\n`;\n\ninterface BodyProps {\n children: NonNullable<ReactNode>;\n}\n\nexport function FullScreenModalBody({ children }: BodyProps): ReactElement {\n return <Body>{children}</Body>;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { useState } from 'react';\nimport type { LayoutChangeEvent } from 'react-native';\nimport { Platform, useWindowDimensions } from 'react-native';\nimport { useSafeAreaInsets } from 'react-native-safe-area-context';\nimport styled from 'styled-components/native';\nimport { KittBreakpoints } from '../KittBreakpoints';\n\ninterface SideContainerProps {\n side?: 'left' | 'right';\n}\n\nconst SideContainer = styled.View<SideContainerProps>`\n ${({ theme, side = 'left' }) => {\n const padding = theme.kitt.spacing * 2;\n\n if (side === 'left') {\n return `padding-right: ${padding}px;`;\n }\n\n return `padding-left: ${padding}px;`;\n }}\n`;\n\nfunction getHeaderHorizontalMediumPadding(spacing: number): number {\n return spacing * 6;\n}\n\ninterface HeaderProps {\n insetTop?: number;\n}\n\nconst Header = styled.View<HeaderProps>`\n ${({ theme, insetTop = 0 }) => {\n const paddingTop = insetTop + theme.kitt.fullScreenModal.header.paddingVertical;\n const { paddingVertical, paddingHorizontal } = theme.kitt.fullScreenModal.header;\n\n return theme.responsive.ifWindowSizeMatches(\n { minWidth: KittBreakpoints.MEDIUM },\n `padding: ${paddingTop}px ${getHeaderHorizontalMediumPadding(theme.kitt.spacing)}px ${paddingVertical}px;`,\n `padding: ${paddingTop}px ${paddingHorizontal}px ${paddingVertical}px;`,\n );\n }};\n border-bottom-color: ${({ theme }) => theme.kitt.fullScreenModal.header.borderColor};\n border-bottom-width: 1px;\n flex-direction: row;\n align-items: center;\n`;\n\ninterface HeaderContentProps {\n windowWidth: number;\n leftWidth: number;\n rightWidth: number;\n}\n\nconst HeaderContent = styled.View<HeaderContentProps>`\n ${({ theme, leftWidth, rightWidth, windowWidth }) => {\n /*\n * Since we don't have controll over the rendered left and right elements,\n * we must apply some logic to give the title all the available space\n */\n const sideElementMaxWidth = Math.max(leftWidth, rightWidth);\n\n const parentHorizontalPadding = theme.kitt.fullScreenModal.header.paddingHorizontal * 2;\n const parentHorizontalPaddingMedium = getHeaderHorizontalMediumPadding(theme.kitt.spacing) * 2;\n\n const computeWidth = (breakpointPadding: number): number =>\n windowWidth - breakpointPadding - sideElementMaxWidth * 2;\n\n return theme.responsive.ifWindowSizeMatches(\n { minWidth: KittBreakpoints.MEDIUM },\n `width: ${computeWidth(parentHorizontalPaddingMedium)}px;`,\n `width: ${computeWidth(parentHorizontalPadding)}px;`,\n );\n }};\n ${({ leftWidth, rightWidth }) => {\n // Depending of the wider element, we must add a margin to fill the diff in space between elements\n const deltaMargin = Math.abs(leftWidth - rightWidth);\n\n if (leftWidth > rightWidth) {\n return `margin-right: ${deltaMargin}px;`;\n }\n\n return `margin-left: ${deltaMargin}px;`;\n }};\n justify-content: center;\n align-items: center;\n`;\n\nexport interface FullScreenModalHeaderProps {\n children: NonNullable<ReactNode>;\n right?: ReactNode;\n left?: ReactNode;\n}\n\nexport function FullScreenModalHeader({ children, right, left }: FullScreenModalHeaderProps): ReactElement {\n const { top } = useSafeAreaInsets();\n const dimensions = useWindowDimensions();\n const [leftWidth, setLeftWidth] = useState(0);\n const [rightWidth, setRightWidth] = useState(0);\n\n const handleLayoutChange = (event: LayoutChangeEvent, side: 'left' | 'right'): void => {\n // Prevents react to nullify event on rerenders\n event.persist();\n\n if (side === 'left') {\n setLeftWidth(event.nativeEvent.layout.width);\n return;\n }\n\n setRightWidth(event.nativeEvent.layout.width);\n };\n\n return (\n <Header insetTop={Platform.OS === 'ios' ? undefined : top}>\n {left ? <SideContainer onLayout={(e) => handleLayoutChange(e, 'left')}>{left}</SideContainer> : null}\n\n <HeaderContent windowWidth={dimensions.width} leftWidth={leftWidth} rightWidth={rightWidth}>\n {children}\n </HeaderContent>\n\n {right ? (\n <SideContainer side=\"right\" onLayout={(e) => handleLayoutChange(e, 'right')}>\n {right}\n </SideContainer>\n ) : null}\n </Header>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\nimport { FullScreenModalBody } from './Body';\nimport { FullScreenModalHeader } from './Header';\n\nconst Container = styled.View`\n flex: 1;\n background-color: ${({ theme }) => theme.kitt.colors.uiBackground};\n`;\n\nexport interface FullScreenModalProps {\n children: ReactNode;\n}\n\nexport function FullScreenModal({ children }: FullScreenModalProps): ReactElement {\n return <Container>{children}</Container>;\n}\n\nFullScreenModal.Header = FullScreenModalHeader;\nFullScreenModal.Body = FullScreenModalBody;\n","import type { ReactElement } from 'react';\nimport { cloneElement, useEffect, useRef } from 'react';\nimport { Animated, Easing } from 'react-native';\n\nexport interface SpinningIconProps {\n icon: ReactElement;\n color?: string;\n}\n\nexport function SpinningIcon({ icon, color }: SpinningIconProps): ReactElement {\n if (process.env.NODE_ENV !== 'production' && !color) {\n throw new Error(`Invalid color passed to SpinningIcon: ${String(color)}`);\n }\n const clonedIcon = cloneElement(icon, { color });\n const animationRef = useRef(new Animated.Value(0));\n\n const rotation = animationRef.current.interpolate({\n inputRange: [0, 1],\n outputRange: ['0deg', '360deg'],\n });\n\n useEffect(() => {\n if (process.env.NODE_ENV === 'test') return undefined;\n\n const animation = Animated.loop(\n Animated.timing(animationRef.current, {\n toValue: 1,\n duration: 1100,\n easing: Easing.linear,\n useNativeDriver: true,\n }),\n );\n animation.start();\n return () => {\n if (process.env.NODE_ENV === 'test') return undefined;\n\n animation.stop();\n return undefined;\n };\n }, []);\n\n return <Animated.View style={{ transform: [{ rotate: rotation }] }}>{clonedIcon}</Animated.View>;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport type { ViewProps } from 'react-native';\nimport styled from 'styled-components/native';\n\nexport interface ListItemContentProps extends ViewProps {\n children: NonNullable<ReactNode>;\n}\n\nconst ContentView = styled.View`\n flex: 1 0 0%;\n align-self: center;\n`;\n\nexport function ListItemContent({ children, ...rest }: ListItemContentProps): ReactElement {\n return <ContentView {...rest}>{children}</ContentView>;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport type { ViewProps, ViewStyle } from 'react-native';\nimport styled from 'styled-components/native';\n\nexport interface ListItemSideContainerProps extends ViewProps {\n children: NonNullable<ReactNode>;\n side?: 'left' | 'right';\n}\n\nconst SideContainerView = styled.View<ListItemSideContainerProps>`\n flex-direction: row;\n margin-left: ${({ theme, side }) => (side === 'right' ? `${theme.kitt.listItem.innerMargin}px` : 0)};\n margin-right: ${({ theme, side }) => (side === 'left' ? `${theme.kitt.listItem.innerMargin}px` : 0)};\n`;\n\n// Handles the vertical alignment of the side elements of the list item\nexport function ListItemSideContainer({ children, side = 'left', ...rest }: ListItemSideContainerProps): ReactElement {\n return (\n <SideContainerView side={side} {...rest}>\n {children}\n </SideContainerView>\n );\n}\n\nexport interface ListItemSideContentProps extends ViewProps {\n children: NonNullable<ReactNode>;\n align?: ViewStyle['alignSelf'];\n}\n\nconst SideContentView = styled.View<ListItemSideContentProps>`\n align-self: ${({ align }) => align};\n`;\n\nexport function ListItemSideContent({ children, align = 'auto', ...rest }: ListItemSideContentProps): ReactElement {\n return (\n <SideContentView align={align} {...rest}>\n {children}\n </SideContentView>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { Fragment } from 'react';\nimport type { PressableProps, ViewProps } from 'react-native';\nimport { Pressable } from 'react-native';\nimport styled, { css } from 'styled-components/native';\nimport { ListItemContent } from './ListItemContent';\nimport { ListItemSideContainer, ListItemSideContent } from './ListItemSideContent';\n\ntype Borders = 'top' | 'bottom' | 'both';\n\nexport interface ListItemProps extends ViewProps {\n children: NonNullable<ReactNode>;\n left?: ReactNode;\n right?: ReactNode;\n borders?: Borders;\n withPadding?: boolean;\n onPress?: PressableProps['onPress'];\n}\n\ninterface ContainerViewProps extends Pick<ListItemProps, 'borders' | 'withPadding'> {}\n\nconst ContainerView = styled.View<ContainerViewProps>`\n flex-direction: row;\n padding: ${({ withPadding, theme }) => (withPadding ? theme.kitt.listItem.padding : 0)};\n ${({ theme, borders }) => {\n const { borderWidth } = theme.kitt.listItem;\n\n if (borders === 'top') {\n return `border-top-width: ${borderWidth}px`;\n }\n\n if (borders === 'bottom') {\n return `border-bottom-width: ${borderWidth}px`;\n }\n\n if (borders === 'both') {\n return css`\n border-top-width: ${borderWidth}px;\n border-bottom-width: ${borderWidth}px;\n `;\n }\n\n return 'border: none';\n }};\n border-color: ${({ theme }) => theme.kitt.listItem.borderColor};\n background-color: ${({ theme }) => theme.kitt.colors.uiBackgroundLight};\n`;\n\nexport function ListItem({\n children,\n withPadding,\n borders,\n left,\n right,\n onPress,\n ...rest\n}: ListItemProps): ReactElement {\n const Wrapper = onPress ? Pressable : Fragment;\n const wrapperProps = onPress ? { accessibilityRole: 'button', onPress, ...rest } : undefined;\n const containerProps = onPress ? undefined : rest;\n\n return (\n <Wrapper {...(wrapperProps as any)}>\n <ContainerView withPadding={withPadding} borders={borders} {...containerProps}>\n {left ? <ListItemSideContainer side=\"left\">{left}</ListItemSideContainer> : null}\n\n <ListItemContent>{children}</ListItemContent>\n\n {right ? <ListItemSideContainer side=\"right\">{right}</ListItemSideContainer> : null}\n </ContainerView>\n </Wrapper>\n );\n}\n\nListItem.Content = ListItemContent;\nListItem.SideContent = ListItemSideContent;\nListItem.SideContainer = ListItemSideContainer;\n","import { ArcIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement } from 'react';\nimport type { SpinningIconProps } from '../Icon/SpinningIcon';\nimport { SpinningIcon } from '../Icon/SpinningIcon';\n\nexport interface LoaderIconProps {\n color?: SpinningIconProps['color'];\n}\n\nexport function LoaderIcon({ color }: LoaderIconProps): ReactElement {\n return <SpinningIcon color={color} icon={<ArcIcon />} />;\n}\n","import { AlertCircleIcon, AlertTriangleIcon, CheckIcon, InfoIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement } from 'react';\nimport type { TypographyColor } from '../typography/Typography';\nimport type { MessageType } from './BaseMessage';\n\ninterface IconContentProps {\n type: MessageType;\n color: TypographyColor;\n}\n\nexport function IconContent({ type, color }: IconContentProps): ReactElement {\n switch (type) {\n case 'warning':\n return <AlertCircleIcon color={color} />;\n case 'success':\n return <CheckIcon color={color} />;\n case 'danger':\n return <AlertTriangleIcon color={color} />;\n default:\n return <InfoIcon color={color} />;\n }\n}\n","import type { IconButtonProps } from '../IconButton/IconButton';\nimport type { TypographyColor } from '../typography/Typography';\nimport type { MessageType } from './BaseMessage';\n\nexport const getColorByType = (type: MessageType): TypographyColor => {\n switch (type) {\n case 'success':\n return 'white';\n case 'danger':\n return 'white';\n case 'warning':\n default:\n return 'black';\n }\n};\n\nexport const getIconButtonColor = (messageType: MessageType): IconButtonProps['color'] => {\n switch (messageType) {\n case 'success':\n case 'danger':\n return 'white';\n case 'warning':\n default:\n return 'black';\n }\n};\n","import { XIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement, ReactNode } from 'react';\nimport type { EdgeInsets } from 'react-native-safe-area-context';\nimport styled from 'styled-components/native';\nimport { Icon } from '../Icon/Icon';\nimport { IconButton } from '../IconButton/IconButton';\nimport { Typography } from '../typography/Typography';\nimport { IconContent } from './IconContent';\nimport { getColorByType, getIconButtonColor } from './helper';\n\nexport type MessageType = 'success' | 'warning' | 'danger' | 'info';\n\ninterface StyledMessageContainerProps {\n $type: MessageType;\n $hasNoRadius?: boolean;\n $insets?: EdgeInsets;\n}\n\nconst StyledMessageContainer = styled.View<StyledMessageContainerProps>`\n flex-direction: row;\n align-items: flex-start;\n justify-content: space-between;\n min-height: 60px;\n padding-top: ${({ $insets }) => $insets?.top ?? 0}px;\n border-radius: ${({ theme, $hasNoRadius }) => ($hasNoRadius ? 0 : theme.kitt.spacing * 5)}px;\n background-color: ${({ theme, $type }) => theme.kitt.feedbackMessage[$type].backgroundColor};\n`;\n\nconst StyledDismissWrapper = styled.View`\n align-items: center;\n align-items: flex-start;\n margin: ${({ theme }) => {\n const { spacing } = theme.kitt;\n return `${spacing * 2.5}px ${spacing * 2}px 0 ${spacing * 5}px`;\n }};\n`;\n\nconst StyledIconContainer = styled.View`\n margin: ${({ theme }) => {\n const { spacing } = theme.kitt;\n return `${spacing}px ${spacing * 5}px 0 0`;\n }};\n`;\n\ninterface StyledTextContentProps {\n $isCenteredText?: boolean;\n}\n\nconst StyledTextContent = styled(Typography.Text)<StyledTextContentProps>`\n flex: 1;\n text-align: ${({ $isCenteredText }) => ($isCenteredText ? 'center' : 'left')};\n`;\n\nconst StyledMessageContent = styled.View`\n display: flex;\n flex-direction: row;\n flex-grow: 1;\n align-self: center;\n align-items: flex-start;\n flex-shrink: 1;\n padding: ${({ theme }) => {\n const { spacing } = theme.kitt;\n return `${spacing * 4}px ${spacing * 5}px`;\n }};\n`;\n\nexport interface BaseMessageProps {\n type?: MessageType;\n children: NonNullable<ReactNode>;\n /**\n * @internal for styling between Message and Notification\n */\n hasNoRadius?: boolean;\n centeredText?: boolean;\n insets?: EdgeInsets;\n onDismiss?: () => void;\n}\n\nexport function BaseMessage({\n type = 'info',\n children,\n hasNoRadius,\n centeredText,\n insets,\n onDismiss,\n}: BaseMessageProps): ReactElement {\n const color = getColorByType(type);\n\n return (\n <StyledMessageContainer $type={type} $hasNoRadius={hasNoRadius} $insets={insets}>\n <StyledMessageContent>\n {centeredText ? null : (\n <StyledIconContainer>\n <Icon color={color} icon={<IconContent type={type} color={color} />} />\n </StyledIconContainer>\n )}\n <StyledTextContent $isCenteredText={centeredText} base=\"body\" color={color}>\n {children}\n </StyledTextContent>\n </StyledMessageContent>\n\n {onDismiss ? (\n <StyledDismissWrapper>\n <IconButton color={getIconButtonColor(type)} icon={<XIcon />} onPress={onDismiss} />\n </StyledDismissWrapper>\n ) : null}\n </StyledMessageContainer>\n );\n}\n","import type { ReactElement } from 'react';\nimport type { BaseMessageProps } from '../BaseMessage/BaseMessage';\nimport { BaseMessage } from '../BaseMessage/BaseMessage';\n\nexport interface MessageProps extends BaseMessageProps {}\n\nexport function Message({\n type = 'info',\n children,\n hasNoRadius,\n centeredText,\n insets,\n onDismiss,\n}: MessageProps): ReactElement {\n return (\n <BaseMessage\n insets={insets}\n hasNoRadius={hasNoRadius}\n type={type}\n centeredText={centeredText}\n onDismiss={onDismiss}\n >\n {children}\n </BaseMessage>\n );\n}\n","import type { ReactElement } from 'react';\nimport { BaseMessage } from '../BaseMessage/BaseMessage';\nimport type { BaseMessageProps } from '../BaseMessage/BaseMessage';\n\nexport interface NotificationProps extends BaseMessageProps {\n /**\n * @deprecated use onDismiss instead\n */\n onDelete?: BaseMessageProps['onDismiss'];\n}\n\nexport function Notification({\n type,\n children,\n centeredText,\n insets,\n onDelete,\n onDismiss,\n}: NotificationProps): ReactElement {\n if (__DEV__) {\n if (onDelete) {\n throw new Error('onDelete is deprecated us onDismiss instead');\n }\n }\n\n return (\n <BaseMessage hasNoRadius type={type} centeredText={centeredText} insets={insets} onDismiss={onDismiss}>\n {children}\n </BaseMessage>\n );\n}\n","import type { ReactElement } from 'react';\nimport Animated, { useAnimatedProps } from 'react-native-reanimated';\nimport type { CircleProps } from 'react-native-svg';\nimport { Circle } from 'react-native-svg';\nimport { useTheme } from 'styled-components/native';\n\nconst AnimatedCircle = Animated.createAnimatedComponent(Circle);\n\ninterface PageLoaderCircleProps {\n color: CircleProps['stroke'];\n progress: Animated.SharedValue<number>;\n}\n\nexport function AnimatedLoaderCircle({ color, progress }: PageLoaderCircleProps): ReactElement {\n const theme = useTheme();\n\n const { strokeWidth, size } = theme.kitt.pageLoader;\n\n const centerCoord = size * 0.5;\n const radius = centerCoord - strokeWidth;\n const circlePerimeter = 2 * Math.PI * (size * 0.5 - strokeWidth);\n\n const strokeAnimation = useAnimatedProps(() => {\n return {\n strokeDashoffset: circlePerimeter - circlePerimeter * progress.value,\n };\n });\n\n return (\n <AnimatedCircle\n transform-origin=\"center center\"\n strokeWidth={strokeWidth}\n stroke={color}\n strokeLinecap=\"round\"\n cx={centerCoord}\n cy={centerCoord}\n r={radius}\n fill=\"none\"\n strokeDasharray={circlePerimeter}\n animatedProps={strokeAnimation}\n />\n );\n}\n","import type { ReactElement } from 'react';\nimport { useEffect } from 'react';\nimport { Easing, useSharedValue, withDelay, withTiming } from 'react-native-reanimated';\nimport Svg from 'react-native-svg';\nimport { useTheme } from 'styled-components/native';\nimport { AnimatedLoaderCircle } from './AnimatedLoaderCircle';\n\nexport function AnimatedBackgroundCircle(): ReactElement {\n const theme = useTheme();\n const progress = useSharedValue(0);\n\n const { animation, colors, size } = theme.kitt.pageLoader;\n\n useEffect(() => {\n const { delay, circleBackgroundFillDuration, fillEasingFunction } = animation;\n const [x1, y1, x2, y2] = fillEasingFunction;\n\n progress.value = withDelay(\n delay,\n withTiming(1, { duration: circleBackgroundFillDuration, easing: Easing.bezier(x1, y1, x2, y2) }),\n );\n }, [progress, animation]);\n\n return (\n <Svg width={size} height={size} viewBox={`0 0 ${size} ${size}`}>\n <AnimatedLoaderCircle color={colors.base} progress={progress} />\n </Svg>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { useEffect } from 'react';\nimport { StyleSheet } from 'react-native';\nimport Animated, {\n Easing,\n useAnimatedStyle,\n useSharedValue,\n withDelay,\n withRepeat,\n withTiming,\n} from 'react-native-reanimated';\nimport { useTheme } from 'styled-components/native';\n\nconst isInfinitAnimation = -1;\n\ninterface AnimatedFillCircleContainerProps {\n children: NonNullable<ReactNode>;\n duration: number;\n}\n\nexport function AnimatedFillCircleContainer({ children, duration }: AnimatedFillCircleContainerProps): ReactElement {\n const theme = useTheme();\n const progress = useSharedValue(0);\n\n const { animation } = theme.kitt.pageLoader;\n\n useEffect(() => {\n const { delay } = animation;\n\n progress.value = withDelay(\n delay,\n withRepeat(withTiming(1, { duration, easing: Easing.linear }), isInfinitAnimation),\n );\n }, [progress, animation, duration]);\n\n const rotationStyles = useAnimatedStyle(() => {\n return {\n transform: [\n {\n rotate: `${360 * progress.value}deg`,\n },\n ],\n };\n });\n\n return <Animated.View style={[StyleSheet.absoluteFill, rotationStyles]}>{children}</Animated.View>;\n}\n","import type { ReactElement } from 'react';\nimport { useEffect } from 'react';\nimport { Easing, useSharedValue, withDelay, withRepeat, withTiming } from 'react-native-reanimated';\nimport Svg from 'react-native-svg';\nimport { useTheme } from 'styled-components/native';\nimport { AnimatedFillCircleContainer } from './AnimatedFillCircleContainer';\nimport { AnimatedLoaderCircle } from './AnimatedLoaderCircle';\n\nconst isInfinitAnimation = -1;\nconst shouldReverse = true;\n\nexport function AnimatedFilledCircle(): ReactElement {\n const theme = useTheme();\n const progress = useSharedValue(0);\n\n const { size, animation, colors } = theme.kitt.pageLoader;\n\n useEffect(() => {\n const { delay, filledCircleFillDuration, fillEasingFunction } = animation;\n const [x1, y1, x2, y2] = fillEasingFunction;\n\n progress.value = withDelay(\n delay,\n withRepeat(\n withTiming(0.8, { duration: filledCircleFillDuration, easing: Easing.bezier(x1, y1, x2, y2) }),\n isInfinitAnimation,\n shouldReverse,\n ),\n );\n }, [progress, animation]);\n\n return (\n <AnimatedFillCircleContainer duration={animation.groupFilledCircleRotationDuration}>\n <AnimatedFillCircleContainer duration={animation.filledCircleRotationDuration}>\n <Svg width={size} height={size} viewBox={`0 0 ${size} ${size}`}>\n <AnimatedLoaderCircle color={colors.fill} progress={progress} />\n </Svg>\n </AnimatedFillCircleContainer>\n </AnimatedFillCircleContainer>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\nimport { AnimatedBackgroundCircle } from './AnimatedBackgroundCircle';\nimport { AnimatedFilledCircle } from './AnimatedFillCircle';\n\ninterface PageLoaderContainerProps {\n children: NonNullable<ReactNode>;\n}\n\nconst PageLoaderContainer = styled.View<PageLoaderContainerProps>`\n /* Needed to make the animation starting from the top of the circles */\n transform: scale(-1) rotate(90deg);\n position: relative;\n width: ${({ theme }) => theme.kitt.pageLoader.size}px;\n height: ${({ theme }) => theme.kitt.pageLoader.size}px;\n`;\n\nexport type PageLoaderProps = Record<string, never>;\n\nexport function PageLoader(props: PageLoaderProps): ReactElement {\n return (\n <PageLoaderContainer>\n <AnimatedBackgroundCircle />\n <AnimatedFilledCircle />\n </PageLoaderContainer>\n );\n}\n","import { LinearGradient } from 'expo-linear-gradient';\nimport type { ReactElement } from 'react';\nimport { useEffect } from 'react';\nimport { StyleSheet } from 'react-native';\nimport Animated, {\n Easing,\n interpolate,\n useAnimatedStyle,\n useSharedValue,\n withRepeat,\n withTiming,\n} from 'react-native-reanimated';\nimport styled, { useTheme } from 'styled-components/native';\n\ninterface SkeletonProps {\n isLoading?: boolean;\n width: number;\n}\n\nconst Container = styled.View`\n background-color: ${({ theme }) => theme.kitt.skeleton.backgroundColor};\n border-color: ${({ theme }) => theme.kitt.skeleton.flareColor};\n height: 100%;\n width: 100%;\n`;\nconst AnimatedLinearGradient = Animated.createAnimatedComponent(LinearGradient);\n\nexport function SkeletonContent({ isLoading, width }: SkeletonProps): ReactElement {\n const theme = useTheme();\n const sharedX = useSharedValue(0);\n\n useEffect(() => {\n if (isLoading) {\n sharedX.value = withRepeat(\n withTiming(1, { duration: theme.kitt.skeleton.animationDuration, easing: Easing.inOut(Easing.ease) }),\n -1,\n );\n }\n }, [sharedX, width, isLoading, theme]);\n\n const linearGradientStyle = useAnimatedStyle(() => {\n return {\n transform: [{ translateX: interpolate(sharedX.value, [0, 1], [-width, width]) }],\n };\n });\n\n return (\n <Container>\n <AnimatedLinearGradient\n colors={[\n theme.kitt.skeleton.backgroundColor,\n theme.kitt.skeleton.flareColor,\n theme.kitt.skeleton.backgroundColor,\n ]}\n locations={[0.1, 0.5, 0.9]}\n start={{ x: 0, y: 0 }}\n end={{ x: 1, y: 0 }}\n style={[StyleSheet.absoluteFill, linearGradientStyle]}\n />\n </Container>\n );\n}\n","import type { ReactElement } from 'react';\nimport { useState } from 'react';\nimport type { StyleProp, ViewStyle } from 'react-native';\nimport { View } from 'react-native';\nimport styled from 'styled-components/native';\nimport { SkeletonContent } from './SkeletonContent';\n\nconst SkeletonContainer = styled(View)`\n overflow: hidden;\n`;\nexport interface SkeletonProps {\n isLoading?: boolean;\n style?: StyleProp<ViewStyle>;\n}\n\nexport function Skeleton({ isLoading, style }: SkeletonProps): ReactElement {\n const [width, setWidth] = useState(0);\n\n return (\n <SkeletonContainer style={style} onLayout={({ nativeEvent }) => setWidth(nativeEvent.layout.width)}>\n <SkeletonContent isLoading={isLoading} width={width} />\n </SkeletonContainer>\n );\n}\n\nconst Bar = styled(Skeleton)`\n width: 100%;\n height: ${({ theme }) => theme.kitt.spacing * 2}px;\n border-radius: ${({ theme }) => theme.kitt.spacing * 2}px;\n`;\n\nconst Circle = styled(Skeleton)`\n width: ${({ theme }) => theme.kitt.spacing * 12}px;\n height: ${({ theme }) => theme.kitt.spacing * 12}px;\n border-radius: ${({ theme }) => theme.kitt.spacing * 6}px;\n`;\n\nconst Square = styled(Skeleton)`\n width: ${({ theme }) => theme.kitt.spacing * 12}px;\n height: ${({ theme }) => theme.kitt.spacing * 12}px;\n border-radius: ${({ theme }) => theme.kitt.spacing * 1.5}px;\n`;\n\nSkeleton.Bar = Bar;\nSkeleton.Circle = Circle;\nSkeleton.Square = Square;\n","import type { ViewStyle } from 'react-native';\nimport styled from 'styled-components/native';\n\ninterface FlexProps {\n direction: ViewStyle['flexDirection'];\n padding?: number;\n}\n\nexport const Flex = styled.View.withConfig<FlexProps>({\n shouldForwardProp: (prop, defaultValidatorFn) => !['direction', 'padding'].includes(prop) && defaultValidatorFn(prop),\n})`\n display: flex;\n flex-direction: ${({ direction }) => direction};\n flex-wrap: wrap;\n padding: ${({ theme, padding = 0 }) => padding * theme.kitt.spacing}px;\n`;\n","export const storyPadding = 16;\n","import type { ReactElement, ReactNode } from 'react';\nimport { createContext, useContext } from 'react';\nimport type { DefaultTheme } from 'styled-components/native';\nimport styled from 'styled-components/native';\nimport type { TypographyColor } from '../typography/Typography';\nimport { storyPadding } from './theme';\n\nexport interface StoryBlockProps {\n background?: 'dark' | 'light' | 'primary' | 'transparent';\n children: ReactNode;\n}\n\nconst getBackgroundColorFromBlockColor = (\n theme: DefaultTheme,\n color: StoryBlockProps['background'] = 'transparent',\n): string => {\n switch (color) {\n case 'dark':\n return '#293033';\n case 'light':\n return '#ffffff';\n case 'primary':\n return theme.kitt.palettes.lateOcean.lateOcean;\n default:\n return 'transparent';\n }\n};\n\nconst getTypographyColorFromBlockColor = (color: StoryBlockProps['background'] = 'transparent'): TypographyColor => {\n switch (color) {\n case 'dark':\n case 'primary':\n return 'white';\n case 'light':\n default:\n return 'black';\n }\n};\n\nexport const StoryBlockBackgroundContext = createContext<StoryBlockProps['background']>('transparent');\nconst StoryBlockColorContext = createContext<TypographyColor>('black');\n\nexport const useStoryBlockColor = (color?: TypographyColor | undefined): TypographyColor => {\n const storyBlockColor = useContext(StoryBlockColorContext);\n return color || storyBlockColor;\n};\n\nconst StyledStoryBlockView = styled.View<StoryBlockProps>`\n padding: 16px ${storyPadding}px 0;\n margin: 0 -${storyPadding}px;\n background: ${({ theme, background }) => getBackgroundColorFromBlockColor(theme, background)};\n`;\n\nexport function StoryBlock({ children, background }: StoryBlockProps): ReactElement {\n return (\n <StyledStoryBlockView background={background}>\n <StoryBlockColorContext.Provider value={getTypographyColorFromBlockColor(background)}>\n <StoryBlockBackgroundContext.Provider value={background}>{children}</StoryBlockBackgroundContext.Provider>\n </StoryBlockColorContext.Provider>\n </StyledStoryBlockView>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\nimport type { TypographyProps } from '../typography/Typography';\nimport { Typography } from '../typography/Typography';\nimport { useStoryBlockColor } from './StoryBlock';\n\ninterface StoryTitleProps {\n color?: TypographyProps['color'];\n numberOfLines?: TypographyProps['numberOfLines'];\n children: ReactNode;\n}\n\nconst StoryTitleContainer = styled.View`\n margin-bottom: 30px;\n`;\n\nconst StorySubTitleContainer = styled.View`\n margin-bottom: 10px;\n`;\n\nexport function StoryTitle({ color, children, numberOfLines }: StoryTitleProps): ReactElement {\n return (\n <StoryTitleContainer>\n <Typography.Header1 variant=\"bold\" base=\"header1\" color={useStoryBlockColor(color)} numberOfLines={numberOfLines}>\n {children}\n </Typography.Header1>\n </StoryTitleContainer>\n );\n}\n\nfunction StoryTitleLevel2({ color, children, numberOfLines }: StoryTitleProps): ReactElement {\n return (\n <StoryTitleContainer>\n <Typography.Header2 variant=\"bold\" base=\"header2\" color={useStoryBlockColor(color)} numberOfLines={numberOfLines}>\n {children}\n </Typography.Header2>\n </StoryTitleContainer>\n );\n}\n\nStoryTitleLevel2.displayName = 'StoryTitle.Level2';\n\nfunction StoryTitleLevel3({ color, children, numberOfLines }: StoryTitleProps): ReactElement {\n return (\n <StorySubTitleContainer>\n <Typography.Header3\n variant=\"bold\"\n base=\"header3\"\n medium=\"header4\"\n color={useStoryBlockColor(color)}\n numberOfLines={numberOfLines}\n >\n {children}\n </Typography.Header3>\n </StorySubTitleContainer>\n );\n}\n\nStoryTitleLevel3.displayName = 'StoryTitle.Level3';\n\nfunction StoryTitleLevel4({ color, children, numberOfLines }: StoryTitleProps): ReactElement {\n return (\n <StorySubTitleContainer>\n <Typography.Header4\n variant=\"bold\"\n base=\"header4\"\n medium=\"header5\"\n color={useStoryBlockColor(color)}\n numberOfLines={numberOfLines}\n >\n {children}\n </Typography.Header4>\n </StorySubTitleContainer>\n );\n}\n\nStoryTitleLevel4.displayName = 'StoryTitle.Level3';\n\nStoryTitle.Level2 = StoryTitleLevel2;\nStoryTitle.Level3 = StoryTitleLevel3;\nStoryTitle.Level4 = StoryTitleLevel4;\n","import type { ReactElement, ReactNode } from 'react';\nimport type { ScrollViewProps } from 'react-native';\nimport styled from 'styled-components/native';\nimport { StoryTitle } from './StoryTitle';\nimport { storyPadding } from './theme';\n\nexport interface StoryProps {\n title: ReactNode;\n children: ReactNode;\n contentContainerStyle?: ScrollViewProps['contentContainerStyle'];\n}\n\nconst StoryContainer = styled.ScrollView`\n padding: ${storyPadding}px;\n`;\n\nexport function Story({ title, contentContainerStyle, children }: StoryProps): ReactElement {\n return (\n <StoryContainer contentContainerStyle={contentContainerStyle}>\n <StoryTitle>{title}</StoryTitle>\n {children}\n </StoryContainer>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport type { ViewProps } from 'react-native';\nimport styled from 'styled-components/native';\nimport { StoryTitle } from './StoryTitle';\n\ninterface StyledSectionProps extends ViewProps {}\n\nconst StyledSection = styled.View<StyledSectionProps>`\n margin-bottom: 32px;\n`;\n\nexport interface StorySectionProps extends ViewProps {\n title: ReactNode;\n children: ReactNode;\n /** @private */\n internalIsDemoSection?: boolean;\n}\n\nexport function StorySection({ title, children, internalIsDemoSection, ...props }: StorySectionProps): ReactElement {\n if (title === 'Demo' && !internalIsDemoSection) throw new Error('Use StorySection.Demo instead');\n return (\n <StyledSection {...props}>\n <StoryTitle.Level2>{title}</StoryTitle.Level2>\n {children}\n </StyledSection>\n );\n}\n\nconst StyledSubSection = styled.View`\n margin-bottom: 16px;\n`;\n\nfunction SubSection({ title, children, ...props }: StorySectionProps): ReactElement {\n return (\n <StyledSubSection {...props}>\n <StoryTitle.Level3>{title}</StoryTitle.Level3>\n {children}\n </StyledSubSection>\n );\n}\n\nconst StyledBlockSection = styled.View`\n margin-bottom: 16px;\n`;\n\nfunction BlockSection({ title, children, ...props }: StorySectionProps): ReactElement {\n return (\n <StyledBlockSection {...props}>\n <StoryTitle.Level4>{title}</StoryTitle.Level4>\n {children}\n </StyledBlockSection>\n );\n}\n\nexport interface DemoSectionProps {\n children: ReactNode;\n}\n\nconst StyledDemoSection = styled.View`\n margin-bottom: 64px;\n`;\n\nfunction DemoSection({ children }: DemoSectionProps): ReactElement {\n return (\n <StyledDemoSection>\n <StorySection internalIsDemoSection title=\"Demo\">\n {children}\n </StorySection>\n </StyledDemoSection>\n );\n}\n\nStorySection.SubSection = SubSection;\nStorySection.BlockSection = BlockSection;\n/** @deprecated use StorySection.Demo instead */\nStorySection.DemoSection = DemoSection;\nStorySection.Demo = DemoSection;\n\n/** @deprecated use StorySection instead */\nexport const DeprecatedSection = StorySection;\n","import type { ReactElement, ReactNode } from 'react';\nimport { StorySection } from './StorySection';\n\nexport interface StoryContainerProps {\n children: NonNullable<ReactNode>;\n state?: 'none' | 'active' | 'hover' | 'focus';\n platform?: 'all' | 'native' | 'web';\n title?: ReactNode;\n}\n\nexport function StoryContainer({\n children,\n title,\n state = 'none',\n platform = 'all',\n}: StoryContainerProps): ReactElement | null {\n if (platform === 'web') return null;\n\n return (\n <StorySection.BlockSection testID={state} title={title}>\n {children}\n </StorySection.BlockSection>\n );\n}\n","import type { StoryContext } from '@storybook/addons';\nimport type { ReactElement, ReactNode } from 'react';\nimport { Story as StoryContainer } from './Story';\n\nexport function StoryDecorator(storyFn: () => ReactNode, context: StoryContext): ReactElement {\n return <StoryContainer title={context.name}>{storyFn()}</StoryContainer>;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport { Children } from 'react';\nimport { Platform, useWindowDimensions } from 'react-native';\nimport styled from 'styled-components/native';\nimport type { TypographyProps } from '..';\nimport { StoryTitle } from './StoryTitle';\n\nconst SmallScreenRow = styled.View`\n flex-direction: column;\n margin: 0;\n`;\n\nconst SmallScreenCol = styled.View`\n padding: 8px 0 16px;\n`;\n\nconst FlexRow = styled.View`\n flex-direction: row;\n margin: 0 -4px 16px;\n`;\n\nconst FlexCol = styled.View`\n flex-grow: 1;\n flex-basis: 0;\n margin: 0 8px;\n`;\n\nexport interface StoryGridRowProps {\n children: NonNullable<ReactNode>;\n breakpoint?: 'small' | 'medium';\n}\n\nfunction StoryGridRow({ children, breakpoint = 'small' }: StoryGridRowProps): ReactElement {\n // eslint-disable-next-line unicorn/expiring-todo-comments\n // TODO use useBreakpoint instead\n const { width } = useWindowDimensions();\n const breakpointValue = breakpoint === 'small' ? 480 : 768;\n\n if (width < breakpointValue) {\n return (\n <SmallScreenRow>\n {Children.map(children, (child) => (\n <SmallScreenCol>{child}</SmallScreenCol>\n ))}\n </SmallScreenRow>\n );\n }\n\n return (\n <FlexRow>\n {Children.map(children, (child) => (\n <FlexCol>{child}</FlexCol>\n ))}\n </FlexRow>\n );\n}\n\nexport interface StoryGridColProps {\n children: NonNullable<ReactNode>;\n title?: string;\n titleColor?: TypographyProps['color'];\n platform?: 'all' | 'native' | 'web';\n}\n\nfunction StoryGridCol({ title, titleColor, children, platform = 'all' }: StoryGridColProps): ReactElement | null {\n const isNative = Platform.OS === 'ios' || Platform.OS === 'android';\n\n if (Platform.OS === 'web' && platform === 'native') {\n return null;\n }\n\n if (isNative && platform === 'web') {\n return null;\n }\n\n return (\n <>\n {title ? (\n <StoryTitle.Level4 numberOfLines={1} color={titleColor}>\n {title}\n </StoryTitle.Level4>\n ) : null}\n {children}\n </>\n );\n}\n\nexport const StoryGrid = {\n Row: StoryGridRow,\n Col: StoryGridCol,\n};\n","import type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components/native';\nimport type { TypographyColor } from '../typography/Typography';\nimport { Typography } from '../typography/Typography';\n\nexport type TagType = 'primary' | 'default' | 'danger';\n\nexport type TagVariant = 'outline' | 'fill';\n\nexport interface TagProps {\n label: ReactNode;\n type?: TagType;\n variant?: TagVariant;\n}\n\ninterface ContainerProps {\n type: TagType;\n variant: TagVariant;\n}\n\nconst Container = styled.View<ContainerProps>`\n background-color: ${({ theme, type, variant }) => theme.kitt.tag[type][variant].backgroundColor};\n border-width: ${({ theme, type, variant }) => theme.kitt.tag[type][variant].borderWidth}px;\n border-color: ${({ theme, type, variant }) => theme.kitt.tag[type][variant].borderColor};\n padding: ${({ theme }) => theme.kitt.tag.padding};\n border-radius: ${({ theme }) => theme.kitt.tag.borderRadius}px;\n align-self: flex-start;\n`;\n\nexport const getLabelColor = (type: TagType, variant: TagVariant): TypographyColor => {\n switch (type) {\n case 'danger': {\n return variant === 'outline' ? 'danger' : 'black';\n }\n case 'primary': {\n return 'primary';\n }\n case 'default': {\n return 'black';\n }\n default: {\n return 'black';\n }\n }\n};\n\nexport function Tag({ label, type = 'default', variant = 'fill' }: TagProps): ReactElement {\n return (\n <Container type={type} variant={variant}>\n <Typography.Text base=\"body-xsmall\" color={getLabelColor(type, variant)}>\n {label}\n </Typography.Text>\n </Container>\n );\n}\n","import type { DateTimePickerEvent } from '@react-native-community/datetimepicker';\nimport DateTimePicker from '@react-native-community/datetimepicker';\nimport type { ReactElement, ReactNode } from 'react';\nimport { useState } from 'react';\nimport { FormattedMessage } from 'react-intl';\nimport { Platform, Text } from 'react-native';\nimport { Button } from '../Button/Button';\nimport { Modal } from '../Modal/Modal';\nimport { Typography } from '../typography/Typography';\n\ninterface TitleProps {\n children: NonNullable<ReactNode>;\n}\n\nfunction Title({ children }: TitleProps): ReactElement {\n return (\n <Modal.Header>\n <Typography.Text base=\"body\" variant=\"bold\">\n {children}\n </Typography.Text>\n </Modal.Header>\n );\n}\n\ninterface ModalDateTimePickerProps {\n title?: ReactNode;\n visible?: boolean;\n value: Date;\n validateButtonLabel?: string;\n onClose: () => void;\n onChange: (newDate: Date) => void;\n}\n\nexport function ModalDateTimePicker({\n title,\n visible,\n value,\n validateButtonLabel,\n onChange,\n onClose,\n}: ModalDateTimePickerProps): ReactElement {\n const [currentValue, setCurrentValue] = useState(value);\n\n // Prevent unsynced value between the modal and its parent state\n const handleClose = (): void => {\n setCurrentValue(value);\n onClose();\n };\n\n const handleSubmit = (): void => {\n onChange(currentValue);\n };\n\n return (\n <Modal visible={Boolean(visible)} onClose={handleClose}>\n {visible ? (\n <>\n {title ? <Title>{title}</Title> : null}\n\n <Modal.Body>\n <DateTimePicker\n is24Hour\n testID=\"date-picker-native-element\"\n value={currentValue}\n mode=\"time\"\n display={Platform.OS === 'ios' ? 'spinner' : 'default'}\n onChange={(_event: DateTimePickerEvent, date?: Date) =>\n setCurrentValue((prev) => {\n return date || prev;\n })\n }\n />\n </Modal.Body>\n <Modal.Footer>\n <Button stretch type=\"primary\" onPress={handleSubmit}>\n {validateButtonLabel ? (\n <Text>{validateButtonLabel}</Text>\n ) : (\n <FormattedMessage id=\"kitt-universal.ModalDateTimePicker.confirm\" defaultMessage=\"Valider\" />\n )}\n </Button>\n </Modal.Footer>\n </>\n ) : null}\n </Modal>\n );\n}\n","import type { InputUIState } from '@ornikar/kitt-universal';\nimport { useMemo, useState } from 'react';\n\nexport const timePickerPlaceholder = '--:--';\n\nexport const formatNumberToTimeString = (time: number): string => `${String(time).padStart(2, '0')}`;\n\nexport const formatDateToTimeString = (date: Date): string =>\n `${formatNumberToTimeString(date.getHours())}:${formatNumberToTimeString(date.getMinutes())}`;\n\nexport const useTimePicker = (\n value: Date | null,\n onChange: (time?: Date | null) => void,\n onBlur: () => void,\n disabled: boolean,\n defaultValue?: Date | null,\n): {\n displayedValue: string;\n dateTimePickerValue: Date;\n timePickerState: InputUIState;\n isTimePickerModalVisible: boolean;\n handleInputPress: () => void;\n handleModalClose: () => void;\n handleTimeChange: (date?: Date) => void;\n} => {\n const [isTimePickerModalVisible, setIsTimePickerModalVisible] = useState<boolean>(false);\n\n const todayAtNoon = useMemo(() => {\n const now = new Date(2000, 0, 1, 12);\n return new Date(now.getFullYear(), now.getMonth(), now.getDay(), 12);\n }, []);\n\n const defaultDate = defaultValue || todayAtNoon;\n const handleInputPress = (): void => {\n if (disabled) {\n return;\n }\n setIsTimePickerModalVisible(true);\n };\n\n const handleTimeChange = (date?: Date | null): void => {\n setIsTimePickerModalVisible(false);\n\n onChange(date || defaultDate);\n onBlur();\n };\n\n const dateTimePickerValue = value || defaultDate;\n const displayedValue = value === null ? timePickerPlaceholder : formatDateToTimeString(dateTimePickerValue);\n const timePickerState = isTimePickerModalVisible ? 'focus' : 'default';\n\n return {\n dateTimePickerValue,\n displayedValue,\n timePickerState,\n isTimePickerModalVisible,\n handleInputPress,\n handleTimeChange,\n handleModalClose: () => setIsTimePickerModalVisible(false),\n };\n};\n","import type { TextInputMixinProps } from '@ornikar/kitt-universal';\nimport type { DateTimePickerEvent } from '@react-native-community/datetimepicker';\nimport DateTimePicker from '@react-native-community/datetimepicker';\nimport type { ReactElement, ReactNode } from 'react';\nimport { Platform } from 'react-native';\nimport styled from 'styled-components/native';\nimport { styledTextInputMixin } from '../forms/styledTextInputMixin';\nimport { Typography } from '../typography/Typography';\nimport { ModalDateTimePicker } from './ModalDateTimePicker';\nimport { timePickerPlaceholder, useTimePicker } from './useTimePicker';\n\ninterface ContainerProps extends TextInputMixinProps {}\n\nconst Container = styled.Pressable<ContainerProps>`\n ${styledTextInputMixin}\n width: 100px;\n height: 40px;\n justify-content: center;\n align-items: center;\n`;\n\nexport type TimePickerValue = Date | null | undefined;\n\nexport interface TimePickerProps {\n title?: ReactNode;\n state?: TextInputMixinProps['$state'];\n disabled?: boolean;\n forceDefaultValue?: TimePickerValue;\n value?: Date | '' | null;\n validateButtonLabel?: string;\n onChange: (time: TimePickerValue) => void;\n onBlur: () => void;\n}\n\nexport function TimePicker({\n title,\n state = 'default',\n disabled = false,\n forceDefaultValue,\n value,\n validateButtonLabel,\n onChange,\n onBlur,\n}: TimePickerProps): ReactElement {\n const {\n dateTimePickerValue,\n displayedValue,\n timePickerState,\n handleInputPress,\n handleModalClose,\n handleTimeChange,\n isTimePickerModalVisible,\n } = useTimePicker(value || null, onChange, onBlur, disabled, forceDefaultValue);\n\n return (\n <Container\n $state={timePickerState === 'default' ? state : timePickerState}\n accessibilityRole=\"button\"\n onPress={handleInputPress}\n >\n <Typography.Text base=\"body\" color={displayedValue === timePickerPlaceholder ? 'black-light' : 'black'}>\n {displayedValue}\n </Typography.Text>\n\n {Platform.OS === 'android' && isTimePickerModalVisible ? (\n <DateTimePicker\n is24Hour\n testID=\"date-picker-native-element\"\n value={dateTimePickerValue}\n mode=\"time\"\n display=\"default\"\n onChange={(_event: DateTimePickerEvent, date?: Date) => handleTimeChange(date)}\n />\n ) : null}\n\n {Platform.OS !== 'android' ? (\n <ModalDateTimePicker\n title={title}\n visible={isTimePickerModalVisible}\n value={dateTimePickerValue}\n validateButtonLabel={validateButtonLabel}\n onChange={handleTimeChange}\n onClose={handleModalClose}\n />\n ) : null}\n </Container>\n );\n}\n","import { TooltipArrowIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement, ReactNode } from 'react';\nimport type { ViewProps } from 'react-native';\nimport { View } from 'react-native';\nimport styled, { useTheme } from 'styled-components/native';\nimport { Typography } from '../typography/Typography';\nimport type { TooltipPosition } from './Tooltip';\n\nconst StyledTooltipView = styled.View`\n align-items: center;\n`;\n\nconst StyledTooltipContent = styled.View`\n background-color: ${({ theme }) => theme.kitt.tooltip.backgroundColor};\n border-radius: ${({ theme }) => theme.kitt.tooltip.borderRadius}px;\n opacity: ${({ theme }) => theme.kitt.tooltip.opacity};\n padding: ${({ theme }) => `${theme.kitt.tooltip.verticalPadding}px ${theme.kitt.tooltip.horizontalPadding}px`};\n`;\n\ninterface StyledArrowProps {\n $position: TooltipPosition;\n}\n\nfunction ArrowView(props: ViewProps): ReactElement {\n const theme = useTheme();\n return (\n <View {...props}>\n <TooltipArrowIcon color={theme.kitt.tooltip.backgroundColor} />\n </View>\n );\n}\n\nconst StyledArrow = styled(ArrowView)<StyledArrowProps>`\n color: ${({ theme }) => theme.kitt.tooltip.backgroundColor};\n transform: ${({ $position }) => `rotate(${$position === 'bottom' ? 180 : 0}deg)`};\n`;\n\nexport interface TooltipViewProps {\n children: NonNullable<ReactNode>;\n position: TooltipPosition;\n}\n\nexport function TooltipView({ children, position }: TooltipViewProps): ReactElement {\n return (\n <StyledTooltipView>\n {position === 'bottom' ? <StyledArrow $position={position} /> : null}\n <StyledTooltipContent>\n <Typography.Text base=\"body\" color=\"white\">\n {children}\n </Typography.Text>\n </StyledTooltipContent>\n {position === 'top' ? <StyledArrow $position={position} /> : null}\n </StyledTooltipView>\n );\n}\n","import type { TooltipProps } from '..';\nimport type { TooltipPosition } from './Tooltip';\n\nexport const tooltipDefaultPosition: TooltipPosition = 'top';\nexport const tooltipDefaultFloatingStrategy: TooltipProps['floatingStrategy'] = {\n web: 'absolute',\n};\n","import { flip, offset, shift, useFloating } from '@floating-ui/react-native';\nimport type { ReactElement, ReactNode } from 'react';\nimport { useEffect } from 'react';\nimport { Pressable, StyleSheet, View } from 'react-native';\nimport Animated, { useAnimatedStyle, useSharedValue, withSpring } from 'react-native-reanimated';\nimport styled, { useTheme } from 'styled-components/native';\nimport { TooltipView } from './TooltipView';\nimport { tooltipDefaultPosition } from './tooltipUtils';\n\nexport type TooltipPosition = 'bottom' | 'top';\nexport type WebFloatingPosition = 'fixed' | 'absolute';\n\n// Since the tooltip use absolute positionning, we need a parent to provide the relative root\nconst TooltipContainer = styled.View`\n position: relative;\n align-self: baseline;\n`;\n\nexport interface TooltipProps {\n children: NonNullable<ReactNode>;\n content: NonNullable<ReactNode>;\n floatingPadding?: number;\n position?: TooltipPosition;\n /**\n * @description\n * This value init the internal visibile state of the tooltip. This is mainly used for testing purpose.\n */\n defaultVisible?: boolean;\n // eslint-disable-next-line react/no-unused-prop-types\n fullWidth?: boolean;\n /**\n * @default absolute\n * @description\n * Specific position strategy to apply to the tooltip.\n * Might be usefull when dealing with edge case (see https://floating-ui.com/docs/misc#z-index-stacking).\n */\n // eslint-disable-next-line react/no-unused-prop-types\n floatingStrategy?: {\n web: WebFloatingPosition;\n };\n onUpdate?: (tooltipConfig: any) => void;\n}\n\n// eslint-disable-next-line unicorn/expiring-todo-comments\n// TODO : update position on scroll in future iteration\nexport function Tooltip({\n children,\n defaultVisible,\n position = tooltipDefaultPosition,\n content,\n floatingPadding,\n onUpdate,\n}: TooltipProps): ReactElement {\n const theme = useTheme();\n const padding = floatingPadding || theme.kitt.tooltip.floatingPadding;\n\n const pressed = useSharedValue(defaultVisible);\n\n const opacityStyles = useAnimatedStyle(() => {\n return {\n opacity: withSpring(pressed.value ? theme.kitt.tooltip.opacity : 0),\n };\n });\n\n const handlePress = (): void => {\n pressed.value = !pressed.value;\n };\n\n const { x, y, reference, floating, update, refs, middlewareData } = useFloating({\n placement: position,\n middleware: [offset(padding), shift(), flip({ padding })],\n });\n\n useEffect(() => {\n if (!onUpdate) return;\n onUpdate({\n x,\n y,\n reference,\n floating,\n strategy: 'absolute',\n update,\n refs,\n middlewareData,\n });\n }, [x, y, reference, floating, update, refs, middlewareData, onUpdate]);\n\n return (\n <TooltipContainer>\n <View ref={reference}>\n <Pressable accessibilityRole=\"button\" onPress={handlePress}>\n {children}\n </Pressable>\n </View>\n\n <View\n ref={floating}\n accessibilityElementsHidden={!pressed.value}\n importantForAccessibility={pressed.value === true ? 'auto' : 'no-hide-descendants'}\n style={{\n ...StyleSheet.absoluteFillObject,\n top: y && position === 'bottom' ? y : undefined,\n bottom: y && position === 'top' ? y : undefined,\n left: x ?? 0,\n }}\n >\n <Animated.View style={[opacityStyles]}>\n <TooltipView position={position}>{content}</TooltipView>\n </Animated.View>\n </View>\n </TooltipContainer>\n );\n}\n\nTooltip.View = TooltipView;\n","import type { ReactElement } from 'react';\nimport { Platform } from 'react-native';\nimport styled, { useTheme } from 'styled-components/native';\nimport { Emoji } from '../Emoji/Emoji';\nimport type { TypographyBreakpointTypesProps } from './Typography';\nimport {\n getTypographyTypeConfig,\n getTypographyTypeConfigKey,\n useTypographyTypeForCurrentWindowSize,\n} from './Typography';\n\nconst StyledTypographyEmoji = styled(Emoji)`\n align-self: center;\n\n ${({ size }) => {\n if (Platform.OS !== 'web') return undefined;\n\n /* Style Twemoji: https://github.com/twitter/twemoji#inline-styles */\n return `\n margin: 0 ${size / 20}px 0 ${size / 10}px;\n transform: translateY(${(size / 10) * 2}px);\n `;\n }}\n`;\n\nexport interface TypographyEmojiProps extends TypographyBreakpointTypesProps {\n emoji: string;\n}\n\nexport function TypographyEmoji({ emoji, base, small, medium, large }: TypographyEmojiProps): ReactElement {\n const theme = useTheme();\n const typeForCurrentWindowSize = useTypographyTypeForCurrentWindowSize(base, small, medium, large);\n const typeConfig = getTypographyTypeConfig(typeForCurrentWindowSize || 'body', theme);\n const typeConfigKey = getTypographyTypeConfigKey(theme);\n const { fontSize } = typeConfig[typeConfigKey];\n\n return <StyledTypographyEmoji size={fontSize} emoji={emoji} />;\n}\n","import { styled as styledLinaria } from '@linaria/react';\nimport type { ReactElement, ReactNode } from 'react';\nimport type { TextProps } from 'react-native';\nimport { Platform } from 'react-native';\nimport type { DefaultTheme } from 'styled-components/native';\nimport styled from 'styled-components/native';\nimport type { Except } from 'type-fest';\nimport { StyleWebWrapper } from '../utils/StyleWebWrapper';\nimport { withTheme } from '../utils/withTheme';\nimport type { TypographyPropsWithoutRole } from './Typography';\nimport { Typography } from './Typography';\n\ninterface TypographyLinkWebWrapperProps {\n theme: DefaultTheme;\n $hasNoUnderline?: boolean;\n}\n\nconst TypographyLinkWebWrapper = withTheme(styledLinaria.span<TypographyLinkWebWrapperProps>`\n & > *:hover,\n & > *:active,\n .kitt-hover & > * {\n text-decoration: none;\n }\n\n & > *:hover,\n & > *:active,\n .kitt-hover & > * {\n text-decoration: ${({ $hasNoUnderline }) => ($hasNoUnderline ? 'underline' : 'none')}\n }\n`);\n\ninterface StyledLinkProps {\n $disabled?: boolean;\n $hasNoUnderline?: boolean;\n}\n\nconst StyledLink = styled.Text<StyledLinkProps & TextProps>`\n text-decoration: ${({ $hasNoUnderline }) => ($hasNoUnderline ? 'none' : 'underline')};\n\n ${({ $disabled }) => {\n if (Platform.OS !== 'web') return undefined;\n\n return `\n text-decoration-color: inherit;\n transition: color 0.2s ease-in-out;\n cursor: ${$disabled ? 'not-allowed' : 'pointer'};\n `;\n }};\n\n ${({ $disabled, theme }) => {\n if (!$disabled) return undefined;\n return `color: ${theme.kitt.typography.link.disabledColor};`;\n }};\n`;\n\nexport interface TypographyLinkProps extends Except<TypographyPropsWithoutRole, 'children'> {\n children: NonNullable<ReactNode>;\n disabled?: boolean;\n noUnderline?: boolean;\n variant: NonNullable<TypographyPropsWithoutRole['variant']>;\n href?: TextProps['href'];\n hrefAttrs?: TextProps['hrefAttrs'];\n onPress: TextProps['onPress'];\n}\n\nexport function TypographyLink({\n children,\n disabled,\n noUnderline,\n href,\n hrefAttrs,\n onPress,\n ...otherProps\n}: TypographyLinkProps): ReactElement {\n return (\n <Typography {...otherProps} accessibilityRole=\"none\">\n <StyleWebWrapper as={TypographyLinkWebWrapper} $hasNoUnderline={noUnderline}>\n <StyledLink\n $disabled={disabled}\n $hasNoUnderline={noUnderline}\n href={href}\n hrefAttrs={hrefAttrs}\n accessibilityRole=\"link\"\n dataSet={{\n // remove data-kitt-universal when we delete kitt web. See See :global(a) in Link styles.module.css\n 'kitt-universal': 'true',\n }}\n onPress={disabled ? undefined : onPress}\n >\n {children}\n </StyledLink>\n </StyleWebWrapper>\n </Typography>\n );\n}\n","export const hex2rgba = (hex: string, alpha = 1): string => {\n const r = parseInt(hex.slice(1, 3), 16);\n const g = parseInt(hex.slice(3, 5), 16);\n const b = parseInt(hex.slice(5, 7), 16);\n\n return `rgba(${r}, ${g}, ${b}, ${alpha})`;\n};\n","import { makeDecorator } from '@storybook/addons';\nimport type { ReactElement, ReactNode } from 'react';\nimport { ThemeProvider } from 'styled-components/native';\nimport type { KittTheme } from '../../useKittTheme';\nimport { useKittTheme } from '../../useKittTheme';\n\ndeclare module 'styled-components' {\n export interface DefaultTheme extends KittTheme {}\n}\n\ninterface KittThemeProviderProps {\n children: ReactNode;\n}\n\nexport function KittThemeProvider({ children }: KittThemeProviderProps): ReactElement {\n const theme = useKittTheme();\n return <ThemeProvider theme={theme}>{children}</ThemeProvider>;\n}\n\nexport const KittThemeDecorator = makeDecorator({\n name: 'ThemeDecorator',\n parameterName: 'theme',\n wrapper: (storyFn, context, { options = {}, parameters = {} }) => {\n return <KittThemeProvider>{storyFn(context) as ReactNode}</KittThemeProvider>;\n },\n});\n","import type { ReactElement, ReactNode } from 'react';\nimport type { MatchWindowSizeOptions } from './useMatchWindowSize';\nimport { useMatchWindowSize } from './useMatchWindowSize';\n\ninterface MatchWindowSizeProps extends MatchWindowSizeOptions {\n children: ReactNode;\n}\n\nexport function MatchWindowSize({ children, ...matchWindowSizeOptions }: MatchWindowSizeProps): ReactElement | null {\n const match = useMatchWindowSize(matchWindowSizeOptions);\n if (!match) return null;\n return children as ReactElement;\n}\n"],"names":["defaultIconSize","IconContainer","styled","View","$color","$size","$align","Icon","icon","size","align","color","clonedIcon","cloneElement","_jsx","KittBreakpoints","BASE","SMALL","MEDIUM","LARGE","WIDE","KittBreakpointsMax","IsHeaderTypographyContext","createContext","undefined","TypographyColorContext","useTypographyColor","useContext","getTypographyTypeConfigKey","theme","isMediumOrAbove","responsive","matchWindowSize","minWidth","isTypeHeader","type","startsWith","isTypographyHeader","typographyIsHeaderInContext","Error","getTypographyTypeConfig","kitt","typography","types","headers","configs","bodies","StyledTypography","Text","$isHeader","$typeForCurrentWindowSize","$variant","typeConfigKey","fontFamily","fontSize","lineHeight","fontWeight","fontStyle","css","colors","useTypographyTypeForCurrentWindowSize","base","small","medium","large","width","useWindowDimensions","getTypographyInheritedOrDefaultValuesBasedOnExistingAncestors","hasTypographyAncestor","Typography","accessibilityRole","variant","otherProps","isHeaderTypographyInContext","baseOrDefaultToBody","colorOrDefaultToBlack","typeForCurrentWindowSize","isHeader","nonNullableVariant","content","TypographyText","props","TypographyParagraph","Platform","OS","createHeading","level","defaultBase","TypographyHeading","displayName","Paragraph","Header1","Header2","Header3","Header4","Header5","Header6","h1","h2","h3","h4","h5","getInitials","firstname","lastname","toUpperCase","StyledAvatarView","$isRound","$sizeVariant","avatar","borderRadius","$isLight","light","backgroundColor","default","AvatarContent","src","alt","isLight","sizeVariant","Image","uri","height","UserIcon","Avatar","round","hasVariant","button","getVariantValuesIfExist","StyledPressable","Pressable","$isStretch","StyledAnimatedView","Animated","AnimatedButtonPressable","forwardRef","children","disabled","$type","href","hrefAttrs","testID","onPress","ref","useTheme","pressed","useSharedValue","pressedBackgroundColor","scale","scaleStyles","useAnimatedStyle","interpolateColor","value","transform","withSpring","active","handlePressInOut","pressIn","BaseStyledButtonPressable","maxWidth","minHeight","$isDisabled","$isLarge","$isXLarge","defaultPadding","disabledPadding","xLarge","contentPadding","TypographyIconSpecifiedColor","TypographyIconInheritColor","TypographyIcon","isSubtle","getTextColorByType","StyledButtonText","StyledIconContainer","$iconPosition","spacing","ButtonIcon","iconPosition","StyledChildrenWithIcon","ButtonContentChildren","isDisabled","isWebSubtle","buttonIconSharedProps","_jsxs","ButtonContentContainer","$isIconOnly","$isSubtle","ButtonContent","Boolean","StyledDisabled","borderWidth","borderColor","allowedGhostTypes","Button","stretch","__DEV__","includes","Container","card","Card","StyledEmoji","Emoji","emoji","style","emojiData","useMemo","parse","assetType","text","url","defaultOpenLinkBehavior","native","web","ExternalLink","as","Component","openLinkBehavior","rest","e","defaultPrevented","WebBrowser","catch","err","console","error","Linking","openURL","lateOceanColorPalette","lateOcean","lateOceanLight1","lateOceanLight2","lateOceanLight3","warmEmbrace","warmEmbraceLight1","black1000","black800","black555","black200","black100","black50","black25","white","viride","englishVermillon","goldCrayola","aero","transparent","moonPurple","moonPurpleLight1","primary","primaryLight","accent","accentLight","success","correct","danger","info","warning","separator","hover","black","blackAnthracite","uiBackground","uiBackgroundLight","overlay","dark","fullscreenLoader","focus","transition","duration","timingFunction","hoverBackgroundColor","focusBorderColor","ghost","hoverColor","activeColor","subtle","secondary","feedbackMessage","checkbox","iconSize","checkedBorderColor","checkedBackgroundColor","markColor","datePicker","day","month","year","calcLineHeight","lineHeightMultiplier","Math","createTypographyTypeConfig","baseAndSmallFontSize","mediumAndWideFontSize","baseAndSmall","mediumAndWide","kittColors","regular","bold","header1","header2","header3","header4","header5","body","link","disabledColor","inputStatesStyle","pending","valid","invalid","input","selection","placeholder","padding","horizontal","vertical","property","states","inputField","labelContainerPaddingBottom","iconMarginLeft","inputTag","labelColor","radio","unchecked","checked","innerSize","innerBackgroundColor","textArea","forms","fullScreenModal","header","paddingVertical","paddingHorizontal","iconButton","listItem","innerMargin","pageLoader","strokeWidth","fill","animation","delay","circleBackgroundFillDuration","filledCircleFillDuration","groupFilledCircleRotationDuration","filledCircleRotationDuration","fillEasingFunction","shadows","skeleton","flareColor","animationDuration","tag","outline","tooltip","opacity","horizontalPadding","verticalPadding","floatingPadding","breakpoints","values","wide","min","smallBreakpoint","mediumBreakpoint","largeBreakpoint","wideBreakpoint","max","palettes","maxHeight","hasWidthMatched","hasHeightMatched","useMatchWindowSize","options","createWindowSizeHelper","dimensions","ifWindowSizeMatches","valueIfTrue","valueIfFalse","mapWindowWidth","widthList","slice","forEach","index","previousMinWidth","found","find","Number","useKittTheme","useWindowSize","kittTheme","CheckboxAndLabelPressableWrapper","CheckboxContainer","$isChecked","$hasLabel","Checkbox","onChange","onBlur","onFocus","hitSlop","id","CheckboxMark","getInputUIState","isFocused","formState","styledTextInputMixin","$state","StyledTypographyText","ViewInput","$partName","DatePickerInputPart","partName","prefixWithZero","padStart","PartContainer","$isLast","DatePickerPressable","DatePickerInputs","state","internalForceState","handleModalOpen","currentValue","currentState","sharedPartProps","getDate","getMonth","getFullYear","DatePickerAndroid","pickerDefaultDate","pickerUITestID","setIsFocused","setCurrentValue","handleClose","DateTimePickerAndroid","open","Date","now","timestamp","nativeEvent","date","onTouchCancel","OverlayPressable","StyleSheet","absoluteFillObject","Overlay","BodyView","ModalBody","ScrollView","FooterView","ModalFooter","StyleWebWrapper","withTheme","WrappedComponent","PressableIconButtonWebWrapper","$isWhite","defaultIconButton","StyledPressableIconButton","PressableIconButton","AnimatedIconButtonBackground","AnimatedViewContainer","PressableAnimatedContainer","accessibilityLabel","opacityStyles","IconButtonContentBorder","IconButtonContent","IconButton","OnCloseContext","HeaderView","LeftIconView","RightIconView","TitleView","isIconLeft","ModalHeader","left","right","onClose","XIcon","ModalView","ContentView","Modal","visible","onEntered","onExited","NativeModal","Header","Body","Footer","getDatePickerDisplayMode","PlatformDateTimePicker","defaultDate","maximumDate","minimuDate","displayMode","iosProps","textColor","DateTimePicker","_event","ModalTitle","ModalPlatformDateTimePicker","title","isVisible","validateButtonLabel","useState","newDate","prev","FormattedMessage","DatePicker","pickerUITitle","pickerUIValidateButtonLabel","isPickerUIVisible","setIsPickerUIVisible","handleModalClose","InputTextContainer","StyledTextInput","TextInput","multiline","$minHeight","RightInputContainer","InputText","autoCorrect","textContentType","autoCompleteType","keyboardType","onSubmitEditing","InputEmail","getColorFromState","InputFeedback","FieldContainer","FeedbackContainer","FieldLabelContainer","LabelContainer","InputField","label","labelFeedback","feedback","getIconColor","InputIcon","InputPressable","InputPassword","isPasswordDefaultVisible","setIsVisible","EyeOffIcon","EyeIcon","InputPhone","getTypographyColor","InputTagContainer","InputTag","typographyColor","Label","htmlFor","OuterRadio","SelectedOuterRadio","SelectedInnerRadio","Radio","TextArea","FullScreenModalBody","SideContainer","side","getHeaderHorizontalMediumPadding","insetTop","paddingTop","HeaderContent","leftWidth","rightWidth","windowWidth","sideElementMaxWidth","parentHorizontalPadding","parentHorizontalPaddingMedium","computeWidth","breakpointPadding","deltaMargin","abs","FullScreenModalHeader","top","useSafeAreaInsets","setLeftWidth","setRightWidth","handleLayoutChange","event","persist","layout","FullScreenModal","SpinningIcon","process","env","NODE_ENV","String","animationRef","useRef","Value","rotation","current","interpolate","inputRange","outputRange","useEffect","loop","timing","toValue","easing","Easing","linear","useNativeDriver","start","stop","rotate","ListItemContent","SideContainerView","ListItemSideContainer","SideContentView","ListItemSideContent","ContainerView","withPadding","borders","ListItem","Wrapper","Fragment","wrapperProps","containerProps","Content","SideContent","LoaderIcon","ArcIcon","IconContent","AlertCircleIcon","CheckIcon","AlertTriangleIcon","InfoIcon","getColorByType","getIconButtonColor","messageType","StyledMessageContainer","$insets","$hasNoRadius","StyledDismissWrapper","StyledTextContent","$isCenteredText","StyledMessageContent","BaseMessage","hasNoRadius","centeredText","insets","onDismiss","Message","Notification","onDelete","AnimatedCircle","createAnimatedComponent","Circle","AnimatedLoaderCircle","progress","centerCoord","circlePerimeter","PI","strokeAnimation","useAnimatedProps","strokeDashoffset","AnimatedBackgroundCircle","x1","y1","x2","y2","withDelay","withTiming","bezier","Svg","isInfinitAnimation","AnimatedFillCircleContainer","withRepeat","rotationStyles","absoluteFill","shouldReverse","AnimatedFilledCircle","PageLoaderContainer","PageLoader","AnimatedLinearGradient","LinearGradient","SkeletonContent","isLoading","sharedX","inOut","ease","linearGradientStyle","translateX","x","y","SkeletonContainer","Skeleton","setWidth","Bar","Square","Flex","withConfig","shouldForwardProp","prop","defaultValidatorFn","direction","storyPadding","getBackgroundColorFromBlockColor","getTypographyColorFromBlockColor","StoryBlockBackgroundContext","StoryBlockColorContext","useStoryBlockColor","storyBlockColor","StyledStoryBlockView","background","StoryBlock","StoryTitleContainer","StorySubTitleContainer","StoryTitle","numberOfLines","StoryTitleLevel2","StoryTitleLevel3","StoryTitleLevel4","Level2","Level3","Level4","StoryContainer","Story","contentContainerStyle","StyledSection","StorySection","internalIsDemoSection","StyledSubSection","SubSection","StyledBlockSection","BlockSection","StyledDemoSection","DemoSection","Demo","DeprecatedSection","platform","StoryDecorator","storyFn","context","name","SmallScreenRow","SmallScreenCol","FlexRow","FlexCol","StoryGridRow","breakpoint","breakpointValue","Children","map","child","StoryGridCol","titleColor","isNative","StoryGrid","Row","Col","getLabelColor","Tag","Title","ModalDateTimePicker","timePickerPlaceholder","formatNumberToTimeString","time","formatDateToTimeString","getHours","getMinutes","useTimePicker","defaultValue","isTimePickerModalVisible","setIsTimePickerModalVisible","todayAtNoon","getDay","dateTimePickerValue","displayedValue","timePickerState","handleInputPress","handleTimeChange","TimePicker","forceDefaultValue","StyledTooltipView","StyledTooltipContent","ArrowView","TooltipArrowIcon","StyledArrow","$position","TooltipView","position","tooltipDefaultPosition","TooltipContainer","Tooltip","defaultVisible","onUpdate","reference","floating","update","refs","middlewareData","useFloating","placement","middleware","offset","shift","flip","strategy","bottom","StyledTypographyEmoji","TypographyEmoji","typeConfig","TypographyLinkWebWrapper","$hasNoUnderline","StyledLink","$disabled","TypographyLink","noUnderline","hex2rgba","hex","alpha","r","parseInt","g","b","KittThemeProvider","ThemeProvider","KittThemeDecorator","makeDecorator","parameterName","wrapper","parameters","MatchWindowSize","matchWindowSizeOptions","match"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAmBO,MAAMA,eAAe,GAAG,EAAxB;AAEA,MAAMC,eAAa,gBAAGC,eAAM,CAACC,IAAV;AAAA;AAAA;AAAA,+DACf,CAAC;AAAEC,EAAAA;AAAF,CAAD,KAAgBA,MADD,EAEf,CAAC;AAAEC,EAAAA;AAAF,CAAD,KAAeA,KAFA,EAGd,CAAC;AAAEA,EAAAA;AAAF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