@ornikar/kitt-universal 2.2.0 → 3.0.0-beta.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.
Files changed (163) hide show
  1. package/CHANGELOG.md +131 -0
  2. package/dist/definitions/Avatar/Avatar.d.ts.map +1 -1
  3. package/dist/definitions/Button/Button.d.ts +5 -2
  4. package/dist/definitions/Button/Button.d.ts.map +1 -1
  5. package/dist/definitions/Button/ButtonContent.d.ts.map +1 -1
  6. package/dist/definitions/Button/ButtonPressable.d.ts +13 -0
  7. package/dist/definitions/Button/ButtonPressable.d.ts.map +1 -0
  8. package/dist/definitions/Card/Card.d.ts.map +1 -1
  9. package/dist/definitions/Emoji/Emoji.d.ts +8 -0
  10. package/dist/definitions/Emoji/Emoji.d.ts.map +1 -0
  11. package/dist/definitions/ExternalLink/ExternalLink.d.ts +18 -0
  12. package/dist/definitions/ExternalLink/ExternalLink.d.ts.map +1 -0
  13. package/dist/definitions/ExternalLink/ExternalLink.web.d.ts +4 -0
  14. package/dist/definitions/ExternalLink/ExternalLink.web.d.ts.map +1 -0
  15. package/dist/definitions/ExternalLink/ExternalLinkOpenLinkBehavior.d.ts +24 -0
  16. package/dist/definitions/ExternalLink/ExternalLinkOpenLinkBehavior.d.ts.map +1 -0
  17. package/dist/definitions/FullScreenModal/Body.d.ts.map +1 -1
  18. package/dist/definitions/FullScreenModal/FullScreenModal.d.ts.map +1 -1
  19. package/dist/definitions/FullScreenModal/Header.d.ts.map +1 -1
  20. package/dist/definitions/Icon/Icon.d.ts.map +1 -1
  21. package/dist/definitions/Icon/SpinningIcon.web.d.ts +3 -2
  22. package/dist/definitions/Icon/SpinningIcon.web.d.ts.map +1 -1
  23. package/dist/definitions/IconButton/IconButton.d.ts.map +1 -1
  24. package/dist/definitions/IconButton/PressableAnimatedContainer.d.ts.map +1 -1
  25. package/dist/definitions/IconButton/PressableAnimatedContainer.web.d.ts.map +1 -1
  26. package/dist/definitions/IconButton/PressableIconButton.d.ts +4 -4
  27. package/dist/definitions/IconButton/PressableIconButton.d.ts.map +1 -1
  28. package/dist/definitions/ListItem/ListItem.d.ts +3 -4
  29. package/dist/definitions/ListItem/ListItem.d.ts.map +1 -1
  30. package/dist/definitions/ListItem/ListItemContent.d.ts +2 -2
  31. package/dist/definitions/ListItem/ListItemContent.d.ts.map +1 -1
  32. package/dist/definitions/ListItem/ListItemSideContent.d.ts +3 -4
  33. package/dist/definitions/ListItem/ListItemSideContent.d.ts.map +1 -1
  34. package/dist/definitions/Loader/LargeLoader.d.ts.map +1 -1
  35. package/dist/definitions/Loader/LargeLoader.web.d.ts.map +1 -1
  36. package/dist/definitions/Loader/Loader.d.ts.map +1 -1
  37. package/dist/definitions/Loader/Loader.web.d.ts.map +1 -1
  38. package/dist/definitions/Message/Message.d.ts.map +1 -1
  39. package/dist/definitions/Modal/Body.d.ts.map +1 -1
  40. package/dist/definitions/Modal/Footer.d.ts.map +1 -1
  41. package/dist/definitions/Modal/Header.d.ts.map +1 -1
  42. package/dist/definitions/Modal/Modal.d.ts.map +1 -1
  43. package/dist/definitions/Notification/Notification.d.ts.map +1 -1
  44. package/dist/definitions/Overlay/Overlay.d.ts +2 -2
  45. package/dist/definitions/Overlay/Overlay.d.ts.map +1 -1
  46. package/dist/definitions/Tag/Tag.d.ts.map +1 -1
  47. package/dist/definitions/TimePicker/ModalDateTimePicker.d.ts +12 -0
  48. package/dist/definitions/TimePicker/ModalDateTimePicker.d.ts.map +1 -0
  49. package/dist/definitions/TimePicker/TimePicker.d.ts +15 -0
  50. package/dist/definitions/TimePicker/TimePicker.d.ts.map +1 -0
  51. package/dist/definitions/TimePicker/TimePicker.web.d.ts +3 -0
  52. package/dist/definitions/TimePicker/TimePicker.web.d.ts.map +1 -0
  53. package/dist/definitions/TimePicker/useTimePicker.d.ts +14 -0
  54. package/dist/definitions/TimePicker/useTimePicker.d.ts.map +1 -0
  55. package/dist/definitions/Tooltip/Tooltip.d.ts +23 -3
  56. package/dist/definitions/Tooltip/Tooltip.d.ts.map +1 -1
  57. package/dist/definitions/Tooltip/Tooltip.web.d.ts +8 -0
  58. package/dist/definitions/Tooltip/Tooltip.web.d.ts.map +1 -0
  59. package/dist/definitions/Tooltip/TooltipView.d.ts +8 -0
  60. package/dist/definitions/Tooltip/TooltipView.d.ts.map +1 -0
  61. package/dist/definitions/Tooltip/tooltipUtils.d.ts +5 -0
  62. package/dist/definitions/Tooltip/tooltipUtils.d.ts.map +1 -0
  63. package/dist/definitions/forms/InputFeedback/InputFeedback.d.ts.map +1 -1
  64. package/dist/definitions/forms/InputField/InputField.d.ts.map +1 -1
  65. package/dist/definitions/forms/InputText/InputText.d.ts +3 -2
  66. package/dist/definitions/forms/InputText/InputText.d.ts.map +1 -1
  67. package/dist/definitions/forms/Label/Label.d.ts.map +1 -1
  68. package/dist/definitions/forms/Radio/Radio.d.ts.map +1 -1
  69. package/dist/definitions/forms/TextArea/TextArea.d.ts.map +1 -1
  70. package/dist/definitions/index.d.ts +9 -13
  71. package/dist/definitions/index.d.ts.map +1 -1
  72. package/dist/definitions/story-components/Flex.d.ts +2 -2
  73. package/dist/definitions/story-components/Flex.d.ts.map +1 -1
  74. package/dist/definitions/story-components/Story.d.ts.map +1 -1
  75. package/dist/definitions/story-components/StoryBlock.d.ts +1 -2
  76. package/dist/definitions/story-components/StoryBlock.d.ts.map +1 -1
  77. package/dist/definitions/story-components/StoryContainer.d.ts.map +1 -1
  78. package/dist/definitions/story-components/StoryContainer.web.d.ts.map +1 -1
  79. package/dist/definitions/story-components/StoryDecorator.d.ts +3 -3
  80. package/dist/definitions/story-components/StoryDecorator.d.ts.map +1 -1
  81. package/dist/definitions/story-components/StoryGrid.d.ts.map +1 -1
  82. package/dist/definitions/story-components/StorySection.d.ts +7 -9
  83. package/dist/definitions/story-components/StorySection.d.ts.map +1 -1
  84. package/dist/definitions/story-components/StoryTitle.d.ts.map +1 -1
  85. package/dist/definitions/themes/default.d.ts +3 -6
  86. package/dist/definitions/themes/default.d.ts.map +1 -1
  87. package/dist/definitions/themes/late-ocean/colorsLateOceanTheme.d.ts +1 -0
  88. package/dist/definitions/themes/late-ocean/colorsLateOceanTheme.d.ts.map +1 -1
  89. package/dist/definitions/themes/late-ocean/tooltip.d.ts +10 -0
  90. package/dist/definitions/themes/late-ocean/tooltip.d.ts.map +1 -0
  91. package/dist/definitions/themes/late-ocean/typographyLateOceanTheme.d.ts +6 -8
  92. package/dist/definitions/themes/late-ocean/typographyLateOceanTheme.d.ts.map +1 -1
  93. package/dist/definitions/typography/Typography.d.ts +19 -7
  94. package/dist/definitions/typography/Typography.d.ts.map +1 -1
  95. package/dist/definitions/typography/TypographyEmoji.d.ts +7 -0
  96. package/dist/definitions/typography/TypographyEmoji.d.ts.map +1 -0
  97. package/dist/definitions/typography/TypographyIcon.d.ts.map +1 -1
  98. package/dist/definitions/typography/TypographyLink.d.ts +9 -9
  99. package/dist/definitions/typography/TypographyLink.d.ts.map +1 -1
  100. package/dist/definitions/useKittTheme.d.ts +8 -1
  101. package/dist/definitions/useKittTheme.d.ts.map +1 -1
  102. package/dist/definitions/utils/StyleWebWrapper.d.ts +7 -0
  103. package/dist/definitions/utils/StyleWebWrapper.d.ts.map +1 -0
  104. package/dist/definitions/utils/storybook/{decorators/KittThemeDecorator.d.ts → KittThemeDecorator.d.ts} +1 -1
  105. package/dist/definitions/utils/storybook/KittThemeDecorator.d.ts.map +1 -0
  106. package/dist/definitions/utils/tests/renderWithProvidersUtils.d.ts +2 -2
  107. package/dist/definitions/utils/tests/renderWithProvidersUtils.d.ts.map +1 -1
  108. package/dist/definitions/utils/tests/styled-component-typing-test.d.ts +1 -0
  109. package/dist/definitions/utils/tests/styled-component-typing-test.d.ts.map +1 -1
  110. package/dist/definitions/utils/windowSize/MatchWindowSize.d.ts.map +1 -1
  111. package/dist/definitions/utils/windowSize/createWindowSizeHelper.d.ts +2 -2
  112. package/dist/definitions/utils/withTheme.d.ts +7 -0
  113. package/dist/definitions/utils/withTheme.d.ts.map +1 -0
  114. package/dist/index-browser-all.es.android.js +1437 -652
  115. package/dist/index-browser-all.es.android.js.map +1 -1
  116. package/dist/index-browser-all.es.css +2 -0
  117. package/dist/index-browser-all.es.ios.js +1437 -652
  118. package/dist/index-browser-all.es.ios.js.map +1 -1
  119. package/dist/index-browser-all.es.js +1403 -724
  120. package/dist/index-browser-all.es.js.map +1 -1
  121. package/dist/index-browser-all.es.web.js +1249 -837
  122. package/dist/index-browser-all.es.web.js.map +1 -1
  123. package/dist/index-node-14.17.cjs.css +2 -0
  124. package/dist/index-node-14.17.cjs.js +1244 -634
  125. package/dist/index-node-14.17.cjs.js.map +1 -1
  126. package/dist/styles.css +4 -0
  127. package/dist/tsbuildinfo +1 -1
  128. package/package.json +19 -7
  129. package/translations/es-ES.json +3 -0
  130. package/translations/fr-FR.json +3 -0
  131. package/dist/definitions/Button/ButtonContainer.d.ts +0 -12
  132. package/dist/definitions/Button/ButtonContainer.d.ts.map +0 -1
  133. package/dist/definitions/Button/useButton.d.ts +0 -6
  134. package/dist/definitions/Button/useButton.d.ts.map +0 -1
  135. package/dist/definitions/primitives/PrimitiveLink.d.ts +0 -11
  136. package/dist/definitions/primitives/PrimitiveLink.d.ts.map +0 -1
  137. package/dist/definitions/primitives/PrimitiveLink.web.d.ts +0 -4
  138. package/dist/definitions/primitives/PrimitiveLink.web.d.ts.map +0 -1
  139. package/dist/definitions/primitives/PrimitivePressable.d.ts +0 -16
  140. package/dist/definitions/primitives/PrimitivePressable.d.ts.map +0 -1
  141. package/dist/definitions/primitives/PrimitivePressable.web.d.ts +0 -4
  142. package/dist/definitions/primitives/PrimitivePressable.web.d.ts.map +0 -1
  143. package/dist/definitions/primitives/PrimitiveScrollView.d.ts +0 -8
  144. package/dist/definitions/primitives/PrimitiveScrollView.d.ts.map +0 -1
  145. package/dist/definitions/primitives/PrimitiveScrollView.web.d.ts +0 -4
  146. package/dist/definitions/primitives/PrimitiveScrollView.web.d.ts.map +0 -1
  147. package/dist/definitions/primitives/PrimitiveText.d.ts +0 -14
  148. package/dist/definitions/primitives/PrimitiveText.d.ts.map +0 -1
  149. package/dist/definitions/primitives/PrimitiveText.web.d.ts +0 -6
  150. package/dist/definitions/primitives/PrimitiveText.web.d.ts.map +0 -1
  151. package/dist/definitions/primitives/PrimitiveView.d.ts +0 -21
  152. package/dist/definitions/primitives/PrimitiveView.d.ts.map +0 -1
  153. package/dist/definitions/primitives/PrimitiveView.web.d.ts +0 -23
  154. package/dist/definitions/primitives/PrimitiveView.web.d.ts.map +0 -1
  155. package/dist/definitions/primitives/helpers.d.ts +0 -7
  156. package/dist/definitions/primitives/helpers.d.ts.map +0 -1
  157. package/dist/definitions/primitives/reset.d.ts +0 -2
  158. package/dist/definitions/primitives/reset.d.ts.map +0 -1
  159. package/dist/definitions/utils/storybook/decorators/KittThemeDecorator.d.ts.map +0 -1
  160. package/dist/definitions/utils/storybook/decorators/SafeAreaProviderDecorator.d.ts +0 -2
  161. package/dist/definitions/utils/storybook/decorators/SafeAreaProviderDecorator.d.ts.map +0 -1
  162. package/dist/definitions/utils/storybook/setup-global-decorators.d.ts +0 -2
  163. package/dist/definitions/utils/storybook/setup-global-decorators.d.ts.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"index-node-14.17.cjs.js","sources":["../src/primitives/PrimitiveView.tsx","../src/Icon/SpinningIcon.tsx","../src/Icon/Icon.tsx","../src/primitives/PrimitiveText.tsx","../src/typography/Typography.tsx","../src/Avatar/Avatar.tsx","../src/primitives/PrimitivePressable.tsx","../src/Button/ButtonContainer.tsx","../src/typography/TypographyIcon.tsx","../src/Button/ButtonContent.tsx","../src/Button/useButton.ts","../src/Button/Button.tsx","../src/Card/Card.tsx","../src/forms/InputFeedback/InputFeedback.tsx","../src/KittBreakpoints.ts","../src/forms/InputField/InputField.tsx","../src/forms/InputText/useInputText.ts","../src/forms/InputText/InputText.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/IconButton/PressableIconButton.tsx","../src/IconButton/PressableAnimatedContainer.tsx","../src/IconButton/IconButton.tsx","../src/ListItem/ListItemContent.tsx","../src/ListItem/ListItemSideContent.tsx","../src/ListItem/ListItem.tsx","../src/Loader/Loader.tsx","../src/Loader/LargeLoader.tsx","../src/Message/Message.tsx","../src/Overlay/Overlay.tsx","../src/primitives/PrimitiveScrollView.tsx","../src/Modal/Body.tsx","../src/Modal/Footer.tsx","../src/Modal/OnCloseContext.ts","../src/Modal/Header.tsx","../src/Modal/Modal.tsx","../src/Notification/Notification.tsx","../src/primitives/PrimitiveLink.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/themes/palettes/lateOceanColorPalette.ts","../src/themes/late-ocean/avatarLateOceanTheme.ts","../src/themes/late-ocean/buttonLateOceanTheme.ts","../src/themes/late-ocean/cardLateOceanTheme.ts","../src/themes/late-ocean/colorsLateOceanTheme.ts","../src/themes/late-ocean/feedbackMessageLateOceanTheme.ts","../src/themes/late-ocean/inputFieldLateOceanTheme.ts","../src/themes/late-ocean/inputLateOceanTheme.ts","../src/themes/late-ocean/radioLateOceanTheme.ts","../src/themes/late-ocean/formLateOceanTheme.ts","../src/themes/late-ocean/fullScreenModalLateOceanTheme.ts","../src/themes/late-ocean/iconButton.ts","../src/themes/late-ocean/listItemLateOceanTheme.ts","../src/themes/late-ocean/shadowsLateOceanTheme.ts","../src/themes/late-ocean/tagLateOceanTheme.ts","../src/themes/late-ocean/typographyLateOceanTheme.ts","../src/themes/default.ts","../src/Tooltip/Tooltip.tsx","../src/typography/TypographyLink.tsx","../src/utils/windowSize/useMatchWindowSize.ts","../src/utils/windowSize/createWindowSizeHelper.ts","../src/useKittTheme.tsx","../src/utils/storybook/decorators/KittThemeDecorator.tsx","../src/utils/storybook/decorators/SafeAreaProviderDecorator.tsx","../src/utils/windowSize/MatchWindowSize.tsx"],"sourcesContent":["import type { FunctionComponent, ReactNode } from 'react';\nimport type { ViewProps as NativeViewProps } from 'react-native';\nimport { View as NativeView } from 'react-native';\n\nexport interface PrimitiveViewProps {\n /**\n * Use internally to pass all styles to our implementation with styled-components\n * @private\n */\n className?: string;\n children?: ReactNode;\n accessibilityRole?: Extract<NativeViewProps['accessibilityRole'], 'button' | 'radio' | 'none'>;\n testID?: NativeViewProps['testID'];\n nativeID?: NativeViewProps['nativeID'];\n /**\n * Use internally to pass all styles from PrimitiveScrollView\n * @private\n */\n style?: NativeViewProps['style'];\n // native only\n onLayout?: NativeViewProps['onLayout'];\n}\n\nexport const PrimitiveView = NativeView as unknown as FunctionComponent<PrimitiveViewProps>;\n","import type { ReactElement, ReactNode } from 'react';\nimport React, { useEffect, useRef } from 'react';\nimport { Animated, Easing } from 'react-native';\n\nexport interface SpinningIconProps {\n children: ReactNode;\n}\n\nexport function SpinningIcon({ children }: SpinningIconProps): ReactElement {\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.TESTS) 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.TESTS) return undefined;\n\n animation.stop();\n return undefined;\n };\n }, []);\n\n return <Animated.View style={{ transform: [{ rotate: rotation }] }}>{children}</Animated.View>;\n}\n","import type { ReactElement } from 'react';\nimport React from 'react';\nimport type { ViewStyle } from 'react-native';\nimport styled from 'styled-components';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\nimport { SpinningIcon } from './SpinningIcon';\n\nexport interface IconProps {\n icon: ReactElement;\n size?: number;\n color: string;\n spin?: boolean;\n align?: ViewStyle['alignSelf'];\n testID?: ViewStyle['testID'];\n}\n\ninterface IconContainerProps {\n size?: number;\n color: string;\n align?: ViewStyle['alignSelf'];\n}\n\nconst IconContainer = styled(PrimitiveView)<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 = 20, spin, align, color }: IconProps): ReactElement {\n const clonedIcon = React.cloneElement(icon, { color });\n\n return (\n <IconContainer align={align} size={size} color={color}>\n {spin ? <SpinningIcon>{clonedIcon}</SpinningIcon> : clonedIcon}\n </IconContainer>\n );\n}\n","import type { FunctionComponent, ReactNode } from 'react';\nimport { Text as NativeText } from 'react-native';\nimport type { TextProps } from 'react-native';\n\nexport interface PrimitiveTextProps {\n className?: string;\n children?: ReactNode;\n accessibilityRole?: Extract<TextProps['accessibilityRole'], 'header' | 'none'> | 'paragraph';\n accessibilityLevel?: number;\n accessibilityRoleDescription?: string;\n testID?: TextProps['testID'];\n numberOfLines?: TextProps['numberOfLines'];\n selectable?: TextProps['selectable'];\n // href?: string;\n}\n\nexport const PrimitiveText = NativeText as unknown as FunctionComponent<PrimitiveTextProps>;\n","import type { FC, ReactElement, ReactNode } from 'react';\nimport React, { createContext, useContext } from 'react';\nimport styled from 'styled-components';\nimport type { Except, SetOptional } from 'type-fest';\nimport type { PrimitiveTextProps } from '../primitives/PrimitiveText';\nimport { PrimitiveText } from '../primitives/PrimitiveText';\n\ntype TypographyHeaderType = `header${'1' | '2' | '3' | '4' | '5'}`;\ntype TypographyBodyType = 'body' | `body-${'large' | 'medium' | 'small' | 'xsmall'}`;\ntype TypographyType = TypographyHeaderType | TypographyBodyType;\ntype TypographyVariant = 'regular' | 'bold';\nexport type TypographyColor =\n | 'black'\n | 'black-light'\n | 'white'\n | 'white-light'\n | 'primary'\n | 'primary-light'\n | 'accent'\n | 'success'\n | 'danger';\n\nconst TypographyTypeContext = createContext<TypographyType | undefined>(undefined);\nconst TypographyColorContext = createContext<TypographyColor>('black');\n\nexport function useTypographyColor(): TypographyColor {\n return useContext(TypographyColorContext);\n}\n\ninterface StyledTypographyProps {\n isHeader: boolean;\n type?: TypographyType;\n variant: TypographyVariant;\n color?: TypographyColor;\n}\n\nconst StyledTypography = styled(PrimitiveText)<StyledTypographyProps>`\n /* font */\n ${({ theme, isHeader, type, variant }) => {\n const { headers, bodies } = theme.kitt.typography.types;\n\n return `\n /* type */\n ${\n !type\n ? ''\n : `\n font-family: ${isHeader ? headers.fontFamily[variant] : bodies.fontFamily[variant]};\n font-size: ${\n isHeader\n ? headers.configs[type as TypographyHeaderType].baseAndSmall.fontSize\n : bodies.configs[type as TypographyBodyType].baseAndSmall.fontSize\n };\n line-height: ${\n isHeader\n ? headers.configs[type as TypographyHeaderType].baseAndSmall.lineHeight\n : bodies.configs[type as TypographyBodyType].baseAndSmall.lineHeight\n };\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 !color\n ? ''\n : `\n color: ${theme.kitt.typography.colors[color]};\n text-decoration-color: ${theme.kitt.typography.colors[color]};\n `}\n`;\n\nexport interface TypographyProps extends Except<PrimitiveTextProps, 'accessibilityRole'> {\n // Find mapping for web here: https://www.w3.org/TR/html-aria/\n accessibilityRole: NonNullable<PrimitiveTextProps['accessibilityRole']> | null;\n /** base type. Inherited from parent Typography if not specified */\n base?: TypographyType;\n small?: TypographyType;\n medium?: TypographyType;\n large?: TypographyType;\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\nconst isTypeHeader = (type: TypographyType): boolean => type.startsWith('header');\nconst isTypographyHeader = (base: TypographyType | undefined, typeInContext: TypographyType | undefined): boolean => {\n if (base) return isTypeHeader(base);\n if (typeInContext) return isTypeHeader(typeInContext);\n\n throw new Error('You must set a \"base\" prop or wrap this Typography in one that does.');\n};\n\nexport function Typography({\n accessibilityRole,\n base,\n variant,\n color,\n ...otherProps\n}: TypographyProps): ReactElement | null {\n const typeInContext = useContext(TypographyTypeContext);\n const isHeader = isTypographyHeader(base, typeInContext);\n const nonNullableVariant: TypographyVariant = variant ?? (isHeader ? 'bold' : 'regular');\n const colorWithDefaultToBlack: TypographyColor | undefined = color ?? (typeInContext ? undefined : 'black');\n\n const content = base ? (\n // use the type and pass the type to the context for children\n <TypographyTypeContext.Provider value={base}>\n <StyledTypography\n color={colorWithDefaultToBlack}\n isHeader={isHeader}\n type={base}\n variant={nonNullableVariant}\n accessibilityRole={accessibilityRole || undefined}\n {...otherProps}\n />\n </TypographyTypeContext.Provider>\n ) : (\n <StyledTypography\n color={colorWithDefaultToBlack}\n isHeader={isHeader}\n variant={nonNullableVariant}\n accessibilityRole={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 return <Typography accessibilityRole=\"paragraph\" {...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 React from 'react';\nimport { Image } from 'react-native';\nimport styled from 'styled-components';\nimport { Icon } from '../Icon/Icon';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\nimport { Typography } from '../typography/Typography';\n\nconst getFirstCharacter = (string: string): string => (string ? string[0] : '');\n\nconst getInitials = (firstname: string, lastname: string): string =>\n (getFirstCharacter(firstname) + getFirstCharacter(lastname)).toUpperCase();\n\nexport interface AvatarProps {\n size?: number;\n src?: string | null;\n firstname?: string | null;\n lastname?: string | null;\n round?: boolean;\n light?: boolean;\n}\n\nexport interface StyledAvatarViewProps extends Pick<AvatarProps, 'round' | 'light'> {\n size: number;\n}\n\nconst StyledAvatarView = styled(PrimitiveView)<StyledAvatarViewProps>`\n border-radius: ${({ round, size }) => (round ? size / 2 : 10)}px;\n background-color: ${({ theme, light }) =>\n light ? 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\nfunction AvatarContent({ size = 40, src, firstname, lastname, light }: AvatarProps): ReactElement {\n if (src) {\n return <Image source={{ uri: src }} style={{ width: size, height: size }} />;\n }\n\n if (firstname && lastname) {\n return (\n <Typography.Text base=\"body-small\" variant=\"bold\" color={light ? 'black' : 'white'}>\n {getInitials(firstname, lastname)}\n </Typography.Text>\n );\n }\n\n return <Icon icon={<UserIcon />} color={light ? 'black' : 'white'} size={size / 2} />;\n}\n\nexport function Avatar({ size = 40, ...rest }: AvatarProps): ReactElement {\n return (\n <StyledAvatarView {...rest} size={size}>\n <AvatarContent {...rest} size={size} />\n </StyledAvatarView>\n );\n}\n","import type { FunctionComponent, ReactNode } from 'react';\nimport { Pressable as NativePressable } from 'react-native';\nimport type { PressableProps } from 'react-native';\n\nexport interface PrimitivePressableProps {\n className?: string;\n children?: ReactNode;\n testID?: PressableProps['testID'];\n disabled?: PressableProps['disabled'];\n focusable?: PressableProps['focusable'];\n nativeID?: PressableProps['nativeID'];\n accessibilityRole: Extract<PressableProps['accessibilityRole'], 'button' | 'radio' | 'none'>;\n onPress?: NonNullable<PressableProps['onPress']>;\n // native only\n onPressIn?: PressableProps['onPressIn'];\n // native only\n onPressOut?: PressableProps['onPressOut'];\n}\n\nexport const PrimitivePressable = NativePressable as unknown as FunctionComponent<PrimitivePressableProps>;\n","import styled from 'styled-components';\nimport type { PrimitivePressableProps } from '../primitives/PrimitivePressable';\nimport { PrimitivePressable } from '../primitives/PrimitivePressable';\nimport type { ButtonType } from './Button';\n\ninterface ButtonContainerProps extends PrimitivePressableProps {\n type: ButtonType;\n isPressed?: boolean;\n disabled?: boolean;\n stretch?: boolean;\n}\n\nexport const ButtonContainer = styled(PrimitivePressable)<ButtonContainerProps>`\n min-width: ${({ theme }) => theme.kitt.button.minWidth};\n max-width: ${({ theme, stretch }) => (stretch ? 'auto' : theme.kitt.button.maxWidth)};\n width: ${({ stretch }) => (stretch ? '100%' : 'auto')};\n min-height: ${({ theme }) => theme.kitt.button.minHeight};\n background-color: ${({ theme, isPressed, disabled, type }) => {\n if (disabled) {\n return theme.kitt.button[type].disabledBackgroundColor;\n }\n\n return isPressed ? theme.kitt.button[type].pressedBackgroundColor : theme.kitt.button[type].backgroundColor;\n }};\n padding: ${({ theme }) => theme.kitt.button.contentPadding.default};\n flex-direction: row;\n\n /* Emulate inline-* css display by making the button taking only its necessary space */\n align-self: flex-start;\n border-radius: ${({ theme }) => theme.kitt.button.borderRadius};\n border-color: ${({ theme, disabled, type }) =>\n disabled ? theme.kitt.button[type].disabledBorderColor : 'transparent'};\n border-width: ${({ theme }) => theme.kitt.button.borderWidth};\n`;\n","import type { ReactElement } from 'react';\nimport React from 'react';\nimport { useTheme } from 'styled-components';\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'];\n}\n\nfunction TypographyIconInheritColor(props: TypographyIconProps): ReactElement {\n const color = useTypographyColor();\n const theme = useTheme();\n return <Icon {...props} color={theme.kitt.typography.colors[color]} />;\n}\n\nfunction TypographyIconSpecifiedColor({\n color,\n ...otherProps\n}: SetNonNullable<TypographyIconProps, 'color'>): ReactElement {\n const theme = useTheme();\n return <Icon {...otherProps} color={theme.kitt.typography.colors[color]} />;\n}\n\nexport function TypographyIcon({ color, ...otherProps }: TypographyIconProps): ReactElement {\n if (color) {\n return <TypographyIconSpecifiedColor color={color} {...otherProps} />;\n }\n\n return <TypographyIconInheritColor {...otherProps} />;\n}\n","import type { ReactElement } from 'react';\nimport React from 'react';\nimport styled, { useTheme } from 'styled-components';\nimport type { Except } from 'type-fest';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\nimport type { TypographyColor } from '../typography/Typography';\nimport { Typography } from '../typography/Typography';\nimport { TypographyIcon } from '../typography/TypographyIcon';\nimport type { ButtonProps, ButtonType } from './Button';\n\nconst getTextColorByType = (type: ButtonType, isPressed: boolean, disabled: boolean): TypographyColor => {\n if (disabled) return 'black-light';\n switch (type) {\n case 'primary':\n return 'white';\n case 'subtle':\n return isPressed ? 'primary-light' : 'primary';\n case 'subtle-dark':\n return isPressed ? 'black-light' : 'black';\n case 'secondary':\n default:\n return 'black';\n }\n};\n\nconst ButtonText = styled(Typography.Text)`\n /* On native code, this is the only way to ensure that the text is centered */\n text-align: center;\n`;\n\ninterface ContentProps {\n stretch?: boolean;\n iconOnly?: boolean;\n}\n\nconst Content = styled(PrimitiveView)<ContentProps>`\n flex-direction: row;\n align-items: center;\n justify-content: center;\n\n /*\n On native code flex grow does not work as expected which cause an issue with the flex props.\n In order to occupy only the needed space, we enable flex grow only when stretched\n */\n flex: ${({ stretch, iconOnly }) => `${stretch || iconOnly ? 1 : 0} 1 auto`};\n`;\n\ninterface IconContainerProps {\n iconPosition?: ButtonProps['iconPosition'];\n}\n\nconst IconContainer = styled(PrimitiveView)<IconContainerProps>`\n ${({ theme, iconPosition }) => {\n const value = theme.kitt.spacing * 3;\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 spin: ButtonProps['iconSpin'];\n color: TypographyColor;\n size: number;\n iconPosition: ButtonContentProps['iconPosition'];\n testID?: string;\n}\n\nfunction ButtonIcon({ icon, spin, color, size, iconPosition, testID }: ButtonIconProps): ReactElement | null {\n return (\n <IconContainer iconPosition={iconPosition}>\n <TypographyIcon icon={icon} spin={spin} color={color} size={size} testID={testID} />\n </IconContainer>\n );\n}\n\ninterface ButtonContentProps extends Except<ButtonProps, 'onPress'> {\n isPressed?: boolean;\n type: NonNullable<ButtonType>;\n}\n\nexport function ButtonContent({\n type,\n isPressed,\n stretch,\n icon,\n iconPosition,\n iconSpin,\n disabled,\n children,\n}: ButtonContentProps): ReactElement | null {\n const color = getTextColorByType(type, Boolean(isPressed), Boolean(disabled));\n const theme = useTheme();\n\n const sharedIconProps = {\n spin: iconSpin,\n color,\n size: theme.kitt.button.iconSize,\n };\n\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 if (!children) {\n return (\n <Content iconOnly stretch={stretch}>\n {/* eslint-disable-next-line @typescript-eslint/no-non-null-assertion */}\n <TypographyIcon {...sharedIconProps} icon={icon!} />\n </Content>\n );\n }\n\n return (\n <Content stretch={stretch}>\n {icon && iconPosition === 'left' ? (\n <ButtonIcon {...sharedIconProps} icon={icon} iconPosition={iconPosition} testID=\"button-left-icon\" />\n ) : null}\n\n <ButtonText base=\"body\" color={color} variant=\"bold\">\n {children}\n </ButtonText>\n\n {icon && iconPosition === 'right' ? (\n <ButtonIcon {...sharedIconProps} icon={icon} iconPosition={iconPosition} />\n ) : null}\n </Content>\n );\n}\n","import { useState } from 'react';\n\nexport const useButton = (): {\n isPressed: boolean;\n handleButtonPressIn: () => void;\n handleButtonPressOut: () => void;\n} => {\n const [isPressed, setIsPressed] = useState<boolean>(false);\n\n const handleButtonPressIn = (): void => setIsPressed(true);\n const handleButtonPressOut = (): void => setIsPressed(false);\n\n return { isPressed, handleButtonPressIn, handleButtonPressOut };\n};\n","import type { ReactElement, ReactNode } from 'react';\nimport React from 'react';\nimport { ButtonContainer } from './ButtonContainer';\nimport { ButtonContent } from './ButtonContent';\nimport { useButton } from './useButton';\n\nexport type ButtonType = 'primary' | 'secondary' | 'subtle' | 'subtle-dark';\n\ntype IconPosition = 'right' | 'left';\n\nexport interface ButtonProps {\n children?: ReactNode;\n type?: ButtonType;\n disabled?: boolean;\n icon?: ReactElement;\n iconPosition?: IconPosition;\n iconSpin?: boolean;\n stretch?: boolean;\n testID?: string;\n onPress?: () => void;\n}\n\nexport function Button({\n children,\n type = 'secondary',\n icon,\n iconPosition = 'left',\n iconSpin,\n stretch,\n disabled,\n onPress,\n testID,\n}: ButtonProps): ReactElement {\n const { isPressed, handleButtonPressIn, handleButtonPressOut } = useButton();\n\n const sharedProps = {\n type,\n stretch,\n disabled,\n };\n\n return (\n <ButtonContainer\n // eslint-disable-next-line unicorn/expiring-todo-comments\n // TODO: When designs are defined, update with the proper onPress styles to mimic TouchableHighlight\n // underlayColor={globalTheme.button[type].pressedBackgroundColor}\n {...sharedProps}\n isPressed={isPressed}\n accessibilityRole=\"button\"\n testID={testID}\n onPress={onPress}\n onPressIn={handleButtonPressIn}\n onPressOut={handleButtonPressOut}\n >\n <ButtonContent {...sharedProps} icon={icon} iconPosition={iconPosition} iconSpin={iconSpin}>\n {children}\n </ButtonContent>\n </ButtonContainer>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport React from 'react';\nimport styled from 'styled-components';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\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(PrimitiveView)<ContainerProps>`\n background-color: ${({ theme, type }) => theme.kitt.card[type].backgroundColor};\n padding: ${({ theme }) => theme.kitt.card.padding};\n border-radius: ${({ theme }) => theme.kitt.card.borderRadius};\n border-width: ${({ theme }) => theme.kitt.card.borderWidth};\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, ReactNode } from 'react';\nimport React from 'react';\nimport type { TypographyColor, TypographyProps } from '../../typography/Typography';\nimport { Typography } from '../../typography/Typography';\nimport type { InputFormState } from '../InputFormState';\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 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","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 React from 'react';\nimport type { ReactElement, ReactNode } from 'react';\nimport styled from 'styled-components';\nimport { KittBreakpoints } from '../../KittBreakpoints';\nimport { PrimitiveView } from '../../primitives/PrimitiveView';\n\nconst FieldContainer = styled(PrimitiveView)`\n padding: 5px 0 10px;\n`;\n\nconst FeedbackContainer = styled(PrimitiveView)`\n ${({ theme }) =>\n theme.responsive.ifWindowSizeMatches({ minWidth: KittBreakpoints.SMALL }, 'padding-top: 10px', 'padding-top: 5px')};\n`;\n\nconst FieldLabelContainer = styled(PrimitiveView)`\n flex-direction: row;\n align-items: center;\n padding-bottom: ${({ theme }) => theme.kitt.forms.inputField.labelContainerPaddingBottom}px;\n`;\n\nconst LabelContainer = styled(PrimitiveView)`\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 { useState } from 'react';\n\nexport const useInputText = (): {\n isFocused: boolean;\n handleInputFocus: () => void;\n handleInputBlur: () => void;\n isPasswordVisible: boolean;\n togglePasswordVisibility: () => void;\n} => {\n const [isFocused, setIsFocused] = useState<boolean>(false);\n const [isPasswordVisible, setIsPasswordVisible] = useState<boolean>(false);\n\n const handleInputFocus = (): void => setIsFocused(true);\n const handleInputBlur = (): void => setIsFocused(false);\n\n const togglePasswordVisibility = (): void => setIsPasswordVisible((isVisible) => !isVisible);\n\n return { isFocused, handleInputFocus, handleInputBlur, togglePasswordVisibility, isPasswordVisible };\n};\n","import { EyeIcon, EyeOffIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement } from 'react';\nimport React, { forwardRef } from 'react';\nimport type { KeyboardTypeOptions, TextInput as RNTextInput, TextInputProps as RNTextInputProps } from 'react-native';\nimport { Platform, TextInput } from 'react-native';\nimport styled, { css, useTheme } from 'styled-components';\nimport { PrimitivePressable } from '../../primitives/PrimitivePressable';\nimport { PrimitiveView } from '../../primitives/PrimitiveView';\nimport { TypographyIcon } from '../../typography/TypographyIcon';\nimport type { InputFormState } from '../InputFormState';\nimport { useInputText } from './useInputText';\n\ntype InputTextType = 'text' | 'email' | 'password' | 'username';\nexport type InputTextState = 'default' | 'invalid' | 'disabled' | 'hover' | 'focus';\n\nexport interface InputTextProps extends Exclude<RNTextInputProps, 'nativeID'> {\n id?: string;\n name?: string;\n disabled?: boolean;\n type: InputTextType;\n minHeight?: number;\n state?: InputFormState;\n /** @internal */\n internalForceState?: InputTextState;\n}\n\nexport interface TextInputMixinProps {\n state: InputTextState;\n}\ninterface InputProps extends TextInputMixinProps {\n minHeight: number;\n}\n\nexport const styledTextInputMixin = css<TextInputMixinProps>`\n /* stylelint-disable declaration-property-value-allowed-list */\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 border-width: ${({ theme }) => theme.kitt.forms.input.borderWidth};\n border-radius: ${({ theme }) => theme.kitt.forms.input.borderRadius};\n border-color: ${({ theme, state }) => theme.kitt.forms.input.states[state].borderColor};\n font-size: ${({ theme }) => theme.kitt.typography.types.bodies.configs.body.baseAndSmall.fontSize};\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\nconst Input = styled(TextInput)<InputProps>`\n /* stylelint-disable declaration-bang-space-before */\n /* stylelint-disable comment-word-disallowed-list */\n\n /* FIXME: text input is not vertically centered on iOS because of bigger line-height */\n ${styledTextInputMixin}\n padding: ${({ theme, multiline }) =>\n !multiline && Platform.OS === 'ios' ? theme.kitt.forms.input.paddingSingleLineIOS : theme.kitt.forms.input.padding};\n line-height: ${({ theme, multiline }) =>\n !multiline && Platform.OS === 'ios' ? 0 : theme.kitt.typography.types.bodies.configs.body.baseAndSmall.lineHeight};\n min-height: ${({ minHeight }) => minHeight}px;\n`;\n\nconst Container = styled(PrimitiveView)`\n margin-top: ${({ theme }) => theme.kitt.forms.input.marginTop};\n margin-bottom: ${({ theme }) => theme.kitt.forms.input.marginBottom};\n`;\n\nconst PasswordButtonContainer = styled(PrimitivePressable)`\n position: absolute;\n right: 0;\n top: 0;\n bottom: 0;\n justify-content: center;\n padding: ${({ theme }) => theme.kitt.forms.input.passwordButtonIconSize / 2}px;\n`;\n\nconst getInputState = ({\n isDisabled,\n isFocused,\n formState,\n}: {\n isFocused: boolean;\n formState: InputFormState;\n isDisabled: boolean;\n}): InputTextState => {\n if (isDisabled) return 'disabled';\n if (isFocused) return 'focus';\n if (formState === 'invalid') return 'invalid';\n return 'default';\n};\n\nconst keyboardTypeByTextInputType: Record<InputTextType, KeyboardTypeOptions> = {\n text: 'default',\n email: 'email-address',\n password: 'default',\n username: 'default',\n};\n\nconst autoCompleteTypeByType: Record<InputTextType, 'off' | 'email' | 'password' | 'name'> = {\n text: 'off',\n email: 'email',\n password: 'password',\n username: 'name',\n};\n\nconst autoCorrectByType: Record<InputTextType, boolean> = {\n text: true,\n email: false,\n password: false,\n username: false,\n};\n\nconst textContentTypeByType: Record<InputTextType, 'none' | 'emailAddress' | 'password' | 'username'> = {\n text: 'none',\n email: 'emailAddress',\n password: 'password',\n username: 'username',\n};\n\nexport const InputText = forwardRef<RNTextInput, InputTextProps>(\n (\n {\n id,\n minHeight = 0,\n type,\n state: formState,\n internalForceState,\n disabled = false,\n onFocus,\n onBlur,\n ...props\n }: InputTextProps,\n ref,\n ): ReactElement => {\n const { isFocused, handleInputBlur, handleInputFocus, isPasswordVisible, togglePasswordVisibility } =\n useInputText();\n const theme = useTheme();\n const state = internalForceState || getInputState({ isFocused, isDisabled: disabled, formState });\n return (\n <Container>\n <Input\n ref={ref}\n nativeID={id}\n editable={!disabled}\n keyboardType={keyboardTypeByTextInputType[type]}\n autoCompleteType={autoCompleteTypeByType[type]}\n autoCorrect={autoCorrectByType[type]}\n minHeight={minHeight}\n textContentType={textContentTypeByType[type]}\n placeholderTextColor={theme.kitt.typography.colors[theme.kitt.forms.input.placeholderColor]}\n selectionColor={theme.kitt.forms.input.selectionColor}\n secureTextEntry={type === 'password' && !isPasswordVisible}\n {...props}\n state={state}\n onFocus={(e) => {\n handleInputFocus();\n if (onFocus) onFocus(e);\n }}\n onBlur={(e) => {\n handleInputBlur();\n if (onBlur) onBlur(e);\n }}\n />\n {type === 'password' && !disabled && (\n <PasswordButtonContainer accessibilityRole=\"button\" onPress={togglePasswordVisibility}>\n <TypographyIcon\n icon={isPasswordVisible ? <EyeIcon /> : <EyeOffIcon />}\n size={theme.kitt.forms.input.passwordButtonIconSize}\n color={theme.kitt.forms.input.states[state].passwordButtonIconColor}\n />\n </PasswordButtonContainer>\n )}\n </Container>\n );\n },\n);\n","import type { ReactElement, ReactNode } from 'react';\nimport React 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 React from 'react';\nimport type { PressableProps } from 'react-native';\nimport styled from 'styled-components';\nimport { PrimitivePressable } from '../../primitives/PrimitivePressable';\nimport { PrimitiveView } from '../../primitives/PrimitiveView';\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(PrimitiveView)<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};\n border-color: ${({ theme, disabled }) => theme.kitt.forms.radio[disabled ? 'disabled' : 'unchecked'].borderColor};\n`;\nconst SelectedOuterRadio = styled(PrimitiveView)`\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(PrimitiveView)`\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(PrimitivePressable)`\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 React from 'react';\nimport { useTheme } from 'styled-components';\nimport type { InputTextProps } from '../InputText/InputText';\nimport { InputText } from '../InputText/InputText';\n\nexport interface TextAreaProps extends Omit<InputTextProps, 'type'> {}\n\nexport function TextArea({ ...props }: TextAreaProps): ReactElement {\n const theme = useTheme();\n return <InputText multiline {...props} type=\"text\" minHeight={theme.kitt.forms.input.textAreaMinHeight} />;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport React from 'react';\nimport styled from 'styled-components';\nimport { KittBreakpoints } from '../KittBreakpoints';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\n\nconst Body = styled(PrimitiveView)`\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 React, { 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';\nimport { KittBreakpoints } from '../KittBreakpoints';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\n\ninterface SideContainerProps {\n side?: 'left' | 'right';\n}\n\nconst SideContainer = styled(PrimitiveView)<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(PrimitiveView)<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(PrimitiveView)<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 React from 'react';\nimport styled from 'styled-components';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\nimport { FullScreenModalBody } from './Body';\nimport { FullScreenModalHeader } from './Header';\n\nconst Container = styled(PrimitiveView)`\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 { Platform } from 'react-native';\nimport styled from 'styled-components';\nimport type { PrimitivePressableProps } from '../primitives/PrimitivePressable';\nimport { PrimitivePressable } from '../primitives/PrimitivePressable';\nimport type { IconButtonContentProps } from './IconButton';\n\nexport interface PressableIconButtonProps extends PrimitivePressableProps {\n color: IconButtonContentProps['color'];\n}\n\nexport const PressableIconButton = styled(PrimitivePressable)<PressableIconButtonProps>`\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, color, disabled }) => {\n const { iconButton } = theme.kitt;\n\n if (Platform.OS !== 'web') {\n return undefined;\n }\n\n const { transition, scale } = 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 &:hover,\n .kitt-hover & {\n @media (hover: none) and (pointer: coarse) {\n transform: scale(${scale.base.hover});\n }\n\n @media(${theme.breakpoints.min.mediumBreakpoint}) {\n transform: scale(${scale.medium.hover});\n }\n }\n\n &:active,\n .kitt-active & {\n transform: scale(${scale.base.active});\n }\n\n &:hover,\n .kitt-hover &,\n &:focus,\n .kitt-focus &,\n &:active,\n .kitt-active & {\n background-color: ${\n color === 'white' ? iconButton.white.pressedBackgroundColor : iconButton.default.pressedBackgroundColor\n };\n }\n `;\n }};\n`;\n","import React from 'react';\nimport type { ReactElement, ReactNode } from 'react';\nimport Animated, { useAnimatedStyle, useSharedValue, withSpring } from 'react-native-reanimated';\nimport styled, { useTheme } from 'styled-components';\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 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 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=\"button\"\n disabled={disabled}\n color={color}\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 React from 'react';\nimport styled from 'styled-components';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\nimport { TypographyIcon } from '../typography/TypographyIcon';\nimport { PressableAnimatedContainer } from './PressableAnimatedContainer';\n\ninterface IconButtonContentBorderProps {\n disabled?: boolean;\n}\n\nconst IconButtonContentBorder = styled(PrimitiveView)<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}\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({ icon, color, disabled, onPress }: IconButtonProps): ReactElement {\n return (\n <PressableAnimatedContainer color={color} disabled={disabled} onPress={onPress}>\n <IconButtonContent disabled={disabled} color={color} icon={icon} />\n </PressableAnimatedContainer>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport React from 'react';\nimport styled from 'styled-components';\nimport type { PrimitiveViewProps } from '../primitives/PrimitiveView';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\n\nexport interface ListItemContentProps extends PrimitiveViewProps {\n children: NonNullable<ReactNode>;\n}\n\nconst ContentView = styled(PrimitiveView)`\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 React from 'react';\nimport type { ViewStyle } from 'react-native';\nimport styled from 'styled-components';\nimport type { PrimitiveViewProps } from '../primitives/PrimitiveView';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\n\nexport interface ListItemSideContainerProps extends PrimitiveViewProps {\n children: NonNullable<ReactNode>;\n side?: 'left' | 'right';\n}\n\nconst SideContainerView = styled(PrimitiveView)<ListItemSideContainerProps>`\n flex-direction: row;\n margin-left: ${({ theme, side }) => (side === 'right' ? theme.kitt.listItem.innerMargin : 0)};\n margin-right: ${({ theme, side }) => (side === 'left' ? theme.kitt.listItem.innerMargin : 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 PrimitiveViewProps {\n children: NonNullable<ReactNode>;\n align?: ViewStyle['alignSelf'];\n}\n\nconst SideContentView = styled(PrimitiveView)<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 React, { Fragment } from 'react';\nimport styled from 'styled-components';\nimport type { PrimitivePressableProps } from '../primitives/PrimitivePressable';\nimport { PrimitivePressable } from '../primitives/PrimitivePressable';\nimport type { PrimitiveViewProps } from '../primitives/PrimitiveView';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\nimport { ListItemContent } from './ListItemContent';\nimport { ListItemSideContainer, ListItemSideContent } from './ListItemSideContent';\n\ntype Borders = 'top' | 'bottom' | 'both';\n\nexport interface ListItemProps extends PrimitiveViewProps {\n children: NonNullable<ReactNode>;\n left?: ReactNode;\n right?: ReactNode;\n borders?: Borders;\n withPadding?: boolean;\n onPress?: PrimitivePressableProps['onPress'];\n}\n\ninterface ContainerViewProps extends Pick<ListItemProps, 'borders' | 'withPadding'> {}\n\nconst ContainerView = styled(PrimitiveView)<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}`;\n }\n\n if (borders === 'bottom') {\n return `border-bottom-width: ${borderWidth}`;\n }\n\n if (borders === 'both') {\n return `border-top-width: ${borderWidth}; border-bottom-width: ${borderWidth}`;\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 ? PrimitivePressable : 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 type { ReactElement } from 'react';\nimport React from 'react';\nimport { ActivityIndicator, Platform } from 'react-native';\nimport { useTheme } from 'styled-components';\nimport type { TypographyIconProps } from '../typography/TypographyIcon';\n\nexport interface LoaderProps {\n color?: TypographyIconProps['color'];\n size?: TypographyIconProps['size'];\n}\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 Loader({ color = 'primary', size = 20 }: LoaderProps): ReactElement {\n const theme = useTheme();\n const colorHex = theme.kitt.typography.colors[color];\n return <ActivityIndicator testID=\"ActivityIndicator\" color={colorHex} size={getActivityIndicatorSize(size)} />;\n}\n","import type { ReactElement } from 'react';\nimport React from 'react';\nimport type { LoaderProps } from './Loader';\nimport { Loader } from './Loader';\n\nexport interface LargeLoaderProps {\n color?: LoaderProps['color'];\n}\n\nexport function LargeLoader({ color = 'primary' }: LargeLoaderProps): ReactElement {\n return <Loader color={color} size={60} />;\n}\n","import { AlertCircleIcon, AlertTriangleIcon, CheckIcon, InfoIcon, XIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement, ReactNode } from 'react';\nimport React from 'react';\nimport { TouchableOpacity } from 'react-native';\nimport styled from 'styled-components';\nimport { Icon } from '../Icon/Icon';\nimport { PrimitiveText } from '../primitives/PrimitiveText';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\nimport type { TypographyColor } from '../typography/Typography';\nimport { Typography } from '../typography/Typography';\n\nexport type MessageType = 'success' | 'warning' | 'danger' | 'info';\n\nconst xIconSize = 14;\nconst mainIconSize = 20;\n\nexport interface MessageProps {\n type?: MessageType;\n children: NonNullable<ReactNode>;\n noRadius?: boolean;\n centeredText?: boolean;\n insets?: { top?: number };\n onDismiss?: () => void;\n}\n\ninterface ContainerProps {\n type: MessageType;\n noRadius: boolean;\n insets: MessageProps['insets'];\n}\n\nconst Container = styled(PrimitiveView)<ContainerProps>`\n border-radius: ${({ theme, noRadius }) => (noRadius ? 0 : theme.kitt.spacing * 5)}px;\n background-color: ${({ theme, type }) => theme.kitt.feedbackMessage.backgroundColors[type]};\n padding-bottom: ${({ theme }) => theme.kitt.spacing * 4}px;\n padding-left: ${({ theme }) => theme.kitt.spacing * 4}px;\n padding-right: ${({ theme }) => theme.kitt.spacing * 4}px;\n padding-top: ${({ theme, insets }) => (insets?.top ?? 0) + theme.kitt.spacing * 4}px;\n flex-direction: row;\n align-items: flex-start;\n justify-content: space-between;\n`;\n\nconst CloseContainer = styled(TouchableOpacity)`\n margin-left: ${({ theme }) => theme.kitt.spacing * 4}px;\n padding: ${({ theme }) => theme.kitt.spacing}px;\n`;\n\nconst IconContainer = styled(PrimitiveView)`\n margin-right: ${({ theme }) => theme.kitt.spacing * 4}px;\n`;\n\ninterface ContentProps {\n type: MessageType;\n centeredText: boolean;\n}\n\nconst Content = styled(PrimitiveText)<ContentProps>`\n text-align: ${({ centeredText }) => (centeredText ? 'center' : 'left')};\n flex: 1;\n`;\n\nconst 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\nfunction getIconContent(type: MessageType): ReactElement {\n switch (type) {\n case 'warning':\n return <AlertCircleIcon />;\n case 'success':\n return <CheckIcon />;\n case 'danger':\n return <AlertTriangleIcon />;\n default:\n return <InfoIcon />;\n }\n}\n\nexport function Message({\n type = 'info',\n children,\n noRadius = false,\n centeredText = false,\n onDismiss,\n insets,\n}: MessageProps): ReactElement {\n const color = getColorByType(type);\n\n return (\n <Container type={type} noRadius={noRadius} insets={insets}>\n {!centeredText ? (\n <IconContainer>\n <Icon size={mainIconSize} color={color} icon={getIconContent(type)} />\n </IconContainer>\n ) : null}\n <Content type={type} centeredText={centeredText}>\n <Typography.Text base=\"body-small\" color={color}>\n {children}\n </Typography.Text>\n </Content>\n {onDismiss ? (\n <CloseContainer onPress={onDismiss}>\n <Icon icon={<XIcon />} size={xIconSize} color={color} />\n </CloseContainer>\n ) : null}\n </Container>\n );\n}\n","import type { ReactElement } from 'react';\nimport React from 'react';\nimport { StyleSheet } from 'react-native';\nimport styled from 'styled-components';\nimport type { PrimitivePressableProps } from '../primitives/PrimitivePressable';\nimport { PrimitivePressable } from '../primitives/PrimitivePressable';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\n\ninterface OverlayProps {\n onPress: PrimitivePressableProps['onPress'];\n}\n\nconst OverlayPressable = styled(PrimitivePressable)(({ theme }) => ({\n ...StyleSheet.absoluteFillObject,\n backgroundColor: theme.kitt.colors.overlay.dark,\n}));\n\nexport function Overlay({ onPress }: OverlayProps): ReactElement {\n return (\n <OverlayPressable accessibilityRole=\"none\" onPress={onPress}>\n <PrimitiveView />\n </OverlayPressable>\n );\n}\n","import type { FunctionComponent } from 'react';\nimport type { ScrollViewProps } from 'react-native';\nimport { ScrollView } from 'react-native';\nimport type { PrimitiveViewProps } from './PrimitiveView';\n\nexport interface PrimitiveScrollViewProps extends PrimitiveViewProps {\n contentContainerStyle?: ScrollViewProps['contentContainerStyle'];\n}\n\nexport const PrimitiveScrollView = ScrollView as unknown as FunctionComponent<PrimitiveScrollViewProps>;\n","import type { ReactElement, ReactNode } from 'react';\nimport React from 'react';\nimport styled from 'styled-components';\nimport { PrimitiveScrollView } from '../primitives/PrimitiveScrollView';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\n\nconst BodyView = styled(PrimitiveView)`\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 <PrimitiveScrollView>\n <BodyView>{children}</BodyView>\n </PrimitiveScrollView>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport React from 'react';\nimport styled from 'styled-components';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\n\nexport interface FooterProps {\n children: NonNullable<ReactNode>;\n}\n\nconst FooterView = styled(PrimitiveView)`\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 { createContext } from 'react';\n\nexport const OnCloseContext = createContext<() => void>(() => {});\n","import { XIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement, ReactNode } from 'react';\nimport React, { useContext } from 'react';\nimport styled from 'styled-components';\nimport { Button } from '../Button/Button';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\nimport { OnCloseContext } from './OnCloseContext';\n\nexport interface HeaderProps {\n children: NonNullable<ReactNode>;\n left?: ReactNode;\n right?: ReactNode;\n}\n\nconst HeaderView = styled(PrimitiveView)`\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(PrimitiveView)`\n align-self: flex-start;\n margin-right: ${({ theme }) => theme.kitt.spacing * 2}px;\n`;\n\nconst RightIconView = styled(PrimitiveView)`\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(PrimitiveView)<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 <Button type=\"subtle-dark\" icon={<XIcon />} onPress={onClose} />\n </RightIconView>\n )}\n </HeaderView>\n );\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport React from 'react';\nimport { Modal as NativeModal } from 'react-native';\nimport styled from 'styled-components';\nimport { Overlay } from '../Overlay/Overlay';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\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(PrimitiveView)`\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(PrimitiveView)`\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};\n background-color: ${({ theme }) => theme.kitt.palettes.lateOcean.white};\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 type { ReactElement, ReactNode } from 'react';\nimport React from 'react';\nimport { useSafeAreaInsets } from 'react-native-safe-area-context';\nimport type { MessageProps } from '../Message/Message';\nimport { Message } from '../Message/Message';\n\nexport interface NotificationProps {\n children: NonNullable<ReactNode>;\n type?: MessageProps['type'];\n centeredText?: MessageProps['centeredText'];\n onDelete?: MessageProps['onDismiss'];\n}\n\nexport function Notification({ type, children, centeredText, onDelete }: NotificationProps): ReactElement {\n const { top } = useSafeAreaInsets();\n return (\n <Message noRadius type={type} centeredText={centeredText} insets={{ top }} onDismiss={onDelete}>\n {children}\n </Message>\n );\n}\n","import type { FunctionComponent, ReactNode } from 'react';\nimport { Text as NativeText } from 'react-native';\nimport type { TextProps } from 'react-native';\n\nexport interface PrimitiveLinkProps {\n className?: string;\n children?: ReactNode;\n accessibilityRole?: Extract<TextProps['accessibilityRole'], 'link'>;\n selectable?: TextProps['selectable'];\n onPress?: TextProps['onPress'];\n}\n\nexport const PrimitiveLink = NativeText as unknown as FunctionComponent<PrimitiveLinkProps>;\n","import type { ViewStyle } from 'react-native';\nimport styled from 'styled-components';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\n\ninterface FlexProps {\n direction: ViewStyle['flexDirection'];\n padding?: number;\n}\n\nexport const Flex = styled(PrimitiveView).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 React, { createContext, useContext } from 'react';\nimport type { DefaultTheme } from 'styled-components';\nimport styled from 'styled-components';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\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(PrimitiveView)<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 React from 'react';\nimport styled from 'styled-components';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\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(PrimitiveView)`\n margin-bottom: 30px;\n`;\n\nconst StorySubTitleContainer = styled(PrimitiveView)`\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 React from 'react';\nimport type { ScrollViewProps } from 'react-native';\nimport styled from 'styled-components';\nimport { PrimitiveScrollView } from '../primitives/PrimitiveScrollView';\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(PrimitiveScrollView)`\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 React from 'react';\nimport styled from 'styled-components';\nimport type { PrimitiveViewProps } from '../primitives/PrimitiveView';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\nimport { StoryTitle } from './StoryTitle';\n\ninterface StyledSectionProps extends PrimitiveViewProps {}\n\nconst StyledSection = styled(PrimitiveView)<StyledSectionProps>`\n margin-bottom: 32px;\n`;\n\nexport interface StorySectionProps extends PrimitiveViewProps {\n title: ReactNode;\n className?: string;\n children: ReactNode;\n /** @private */\n internalIsDemoSection?: boolean;\n}\n\nexport function StorySection({\n title,\n className,\n children,\n internalIsDemoSection,\n ...props\n}: 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(PrimitiveView)`\n margin-bottom: 16px;\n`;\n\nfunction SubSection({ title, className, 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(PrimitiveView)`\n margin-bottom: 16px;\n`;\n\nfunction BlockSection({ title, className, 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(PrimitiveView)`\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 React 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, StoryFn } from '@storybook/addons';\nimport type { ReactNode } from 'react';\nimport React from 'react';\nimport { Story } from './Story';\n\nexport function StoryDecorator(storyFn: StoryFn<ReactNode>, context: StoryContext): ReturnType<StoryFn<ReactNode>> {\n return <Story title={context.name}>{storyFn()}</Story>;\n}\n","import type { ReactElement, ReactNode } from 'react';\nimport React from 'react';\nimport { Platform, useWindowDimensions } from 'react-native';\nimport styled from 'styled-components';\nimport type { TypographyProps } from '..';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\nimport { StoryTitle } from './StoryTitle';\n\nconst SmallScreenRow = styled(PrimitiveView)`\n flex-direction: column;\n margin: 0;\n`;\n\nconst SmallScreenCol = styled(PrimitiveView)`\n padding: 8px 0 16px;\n`;\n\nconst FlexRow = styled(PrimitiveView)`\n flex-direction: row;\n margin: 0 -4px 16px;\n`;\n\nconst FlexCol = styled(PrimitiveView)`\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 {React.Children.map(children, (child) => (\n <SmallScreenCol>{child}</SmallScreenCol>\n ))}\n </SmallScreenRow>\n );\n }\n\n return (\n <FlexRow>\n {React.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 React from 'react';\nimport styled from 'styled-components';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\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(PrimitiveView)<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};\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};\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","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 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 avatarLateOceanTheme = {\n default: {\n color: lateOceanColorPalette.white,\n backgroundColor: lateOceanColorPalette.lateOcean,\n },\n light: {\n color: lateOceanColorPalette.black1000,\n backgroundColor: lateOceanColorPalette.black100,\n },\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const buttonLateOceanTheme = {\n borderRadius: '30px',\n borderWidth: '2px',\n minHeight: '42px',\n minWidth: '40px',\n maxWidth: '335px',\n iconSize: 18,\n contentPadding: {\n default: '8px 16px',\n },\n primary: {\n backgroundColor: lateOceanColorPalette.lateOcean,\n disabledBackgroundColor: lateOceanColorPalette.black50,\n pressedBackgroundColor: lateOceanColorPalette.lateOceanLight1,\n disabledBorderColor: lateOceanColorPalette.black100,\n },\n secondary: {\n backgroundColor: 'rgba(0, 0, 0, 0.05)',\n disabledBackgroundColor: lateOceanColorPalette.black50,\n pressedBackgroundColor: 'rgba(0, 0, 0, 0.1)',\n disabledBorderColor: lateOceanColorPalette.black100,\n },\n subtle: {\n backgroundColor: lateOceanColorPalette.transparent,\n disabledBackgroundColor: lateOceanColorPalette.transparent,\n pressedBackgroundColor: lateOceanColorPalette.transparent,\n disabledBorderColor: lateOceanColorPalette.transparent,\n },\n 'subtle-dark': {\n backgroundColor: lateOceanColorPalette.transparent,\n disabledBackgroundColor: lateOceanColorPalette.transparent,\n pressedBackgroundColor: lateOceanColorPalette.transparent,\n disabledBorderColor: lateOceanColorPalette.transparent,\n },\n white: {\n backgroundColor: 'rgba(255, 255, 255, 0.05)',\n disabledBackgroundColor: lateOceanColorPalette.transparent,\n hoverBackgroundColor: 'rgba(255, 255, 255, 0.1)',\n pressedBackgroundColor: 'rgba(255, 255, 255, 0.1)',\n focusBorderColor: 'rgba(255, 255, 255, 0.1)',\n disabledBorderColor: lateOceanColorPalette.transparent,\n },\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const cardLateOceanTheme = {\n borderRadius: '20px',\n borderWidth: '2px',\n padding: '16px',\n primary: {\n backgroundColor: lateOceanColorPalette.white,\n borderColor: lateOceanColorPalette.lateOcean,\n },\n secondary: {\n backgroundColor: lateOceanColorPalette.white,\n borderColor: lateOceanColorPalette.black100,\n },\n subtle: {\n backgroundColor: lateOceanColorPalette.black50,\n borderColor: lateOceanColorPalette.black100,\n },\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const colorsLateOceanTheme = {\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 separator: lateOceanColorPalette.black100,\n hover: lateOceanColorPalette.black100,\n uiBackground: lateOceanColorPalette.black25,\n uiBackgroundLight: lateOceanColorPalette.white,\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';\n\nexport const feedbackMessageLateOceanTheme = {\n backgroundColors: {\n success: lateOceanColorPalette.viride,\n danger: lateOceanColorPalette.englishVermillon,\n warning: lateOceanColorPalette.goldCrayola,\n info: lateOceanColorPalette.aero,\n },\n};\n","export const inputFieldLateOceanTheme = {\n labelContainerPaddingBottom: 5,\n iconMarginLeft: 6,\n};\n","import type { InputTextState } from '../../forms/InputText/InputText';\nimport { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport type { typographyLateOceanTheme } from './typographyLateOceanTheme';\n\nexport type TypographyColor = keyof typeof typographyLateOceanTheme.colors;\nexport interface InputStateStyle {\n backgroundColor?: string;\n borderColor: string;\n color: TypographyColor;\n passwordButtonIconColor: TypographyColor;\n}\n\nconst inputStatesStyle: Record<InputTextState, InputStateStyle> = {\n default: {\n backgroundColor: lateOceanColorPalette.white,\n borderColor: lateOceanColorPalette.black100,\n color: 'black',\n passwordButtonIconColor: 'black',\n },\n hover: {\n borderColor: lateOceanColorPalette.black200,\n color: 'black',\n passwordButtonIconColor: 'black',\n },\n focus: {\n borderColor: lateOceanColorPalette.lateOcean,\n color: 'black',\n passwordButtonIconColor: 'black',\n },\n disabled: {\n backgroundColor: lateOceanColorPalette.black50,\n borderColor: lateOceanColorPalette.black100,\n color: 'black-light',\n passwordButtonIconColor: 'black-light',\n },\n invalid: {\n borderColor: lateOceanColorPalette.englishVermillon,\n color: 'black',\n passwordButtonIconColor: 'black',\n },\n};\n\nexport const inputLateOceanTheme = {\n marginTop: '2px',\n marginBottom: '4px',\n borderWidth: '2px',\n borderRadius: '10px',\n passwordButtonIconSize: 20,\n padding: '7px 16px',\n paddingSingleLineIOS: '12px 16px',\n selectionColor: lateOceanColorPalette.lateOcean,\n placeholderColor: 'black-light' as const,\n textAreaMinHeight: 120,\n states: inputStatesStyle,\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const radioLateOceanTheme = {\n size: 18,\n unchecked: {\n backgroundColor: lateOceanColorPalette.white,\n borderWidth: '2px',\n borderColor: lateOceanColorPalette.black200,\n },\n checked: {\n backgroundColor: lateOceanColorPalette.lateOcean,\n innerSize: 5,\n innerBackgroundColor: lateOceanColorPalette.white,\n },\n disabled: {\n backgroundColor: lateOceanColorPalette.black50,\n borderColor: lateOceanColorPalette.black100,\n },\n};\n","import { inputFieldLateOceanTheme } from './inputFieldLateOceanTheme';\nimport { inputLateOceanTheme } from './inputLateOceanTheme';\nimport { radioLateOceanTheme } from './radioLateOceanTheme';\n\nexport const formsLateOceanTheme = {\n input: inputLateOceanTheme,\n radio: radioLateOceanTheme,\n inputField: inputFieldLateOceanTheme,\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const fullScreenModalLateOceanTheme = {\n header: {\n paddingVertical: 12,\n paddingHorizontal: 16,\n borderColor: lateOceanColorPalette.black100,\n },\n};\n","import { buttonLateOceanTheme } from './buttonLateOceanTheme';\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: buttonLateOceanTheme.secondary.disabledBackgroundColor,\n borderColor: buttonLateOceanTheme.secondary.disabledBorderColor,\n },\n default: {\n pressedBackgroundColor: buttonLateOceanTheme.secondary.pressedBackgroundColor,\n },\n white: {\n pressedBackgroundColor: buttonLateOceanTheme.white.hoverBackgroundColor,\n },\n};\n","import { colorsLateOceanTheme } from './colorsLateOceanTheme';\n\nexport const listItemLateOceanTheme = {\n padding: '12px 16px',\n borderColor: colorsLateOceanTheme.separator,\n borderWidth: '1px',\n innerMargin: '8px',\n};\n","export const shadowsLateOceanTheme = {\n medium: '0px 10px 20px rgba(41, 48, 51, 0.25)',\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colorsLateOceanTheme } from './colorsLateOceanTheme';\n\nexport const tagLateOceanTheme = {\n borderRadius: '10px',\n padding: '2px 12px',\n primary: {\n fill: {\n backgroundColor: lateOceanColorPalette.moonPurpleLight1,\n borderWidth: '0',\n borderColor: lateOceanColorPalette.transparent,\n },\n outline: {\n backgroundColor: lateOceanColorPalette.transparent,\n borderWidth: '1px',\n borderColor: lateOceanColorPalette.lateOcean,\n },\n },\n default: {\n fill: {\n backgroundColor: lateOceanColorPalette.black50,\n borderWidth: '0',\n borderColor: lateOceanColorPalette.transparent,\n },\n outline: {\n backgroundColor: lateOceanColorPalette.transparent,\n borderWidth: '1px',\n borderColor: lateOceanColorPalette.black1000,\n },\n },\n danger: {\n fill: {\n backgroundColor: lateOceanColorPalette.warmEmbrace,\n borderWidth: '0',\n borderColor: lateOceanColorPalette.transparent,\n },\n outline: {\n backgroundColor: lateOceanColorPalette.transparent,\n borderWidth: '1px',\n borderColor: colorsLateOceanTheme.danger,\n },\n },\n};\n","import { Platform } from 'react-native';\nimport { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nconst calcLineHeight = (fontSize: number, lineHeightMultiplier: number): number =>\n Math.round(fontSize * lineHeightMultiplier);\n\nexport interface TypographyTypeConfig {\n baseAndSmall: {\n fontSize: string;\n lineHeight: string;\n };\n mediumAndWide: {\n fontSize: string;\n lineHeight: string;\n };\n}\n\nconst createTypographyTypeConfig = (\n lineHeightMultiplier: number,\n baseAndSmallFontSize: number,\n mediumAndWideFontSize: number,\n): TypographyTypeConfig => ({\n baseAndSmall: {\n fontSize: `${baseAndSmallFontSize}px`,\n lineHeight: `${calcLineHeight(lineHeightMultiplier, baseAndSmallFontSize)}px`,\n },\n mediumAndWide: {\n fontSize: `${mediumAndWideFontSize}px`,\n lineHeight: `${calcLineHeight(lineHeightMultiplier, baseAndSmallFontSize)}px`,\n },\n});\n\nexport const typographyLateOceanTheme = {\n colors: {\n black: lateOceanColorPalette.black1000,\n 'black-light': lateOceanColorPalette.black555,\n white: lateOceanColorPalette.white,\n 'white-light': lateOceanColorPalette.white,\n primary: lateOceanColorPalette.lateOcean,\n 'primary-light': lateOceanColorPalette.lateOceanLight1,\n accent: lateOceanColorPalette.warmEmbrace,\n success: lateOceanColorPalette.viride,\n danger: lateOceanColorPalette.englishVermillon,\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 { WindowSizeHelper } from '../utils/windowSize/createWindowSizeHelper';\nimport { avatarLateOceanTheme } from './late-ocean/avatarLateOceanTheme';\nimport { buttonLateOceanTheme } from './late-ocean/buttonLateOceanTheme';\nimport { cardLateOceanTheme } from './late-ocean/cardLateOceanTheme';\nimport { colorsLateOceanTheme } from './late-ocean/colorsLateOceanTheme';\nimport { feedbackMessageLateOceanTheme } from './late-ocean/feedbackMessageLateOceanTheme';\nimport { formsLateOceanTheme } from './late-ocean/formLateOceanTheme';\nimport { fullScreenModalLateOceanTheme } from './late-ocean/fullScreenModalLateOceanTheme';\nimport { iconButton } from './late-ocean/iconButton';\nimport { listItemLateOceanTheme } from './late-ocean/listItemLateOceanTheme';\nimport { shadowsLateOceanTheme } from './late-ocean/shadowsLateOceanTheme';\nimport { tagLateOceanTheme } from './late-ocean/tagLateOceanTheme';\nimport { typographyLateOceanTheme } from './late-ocean/typographyLateOceanTheme';\nimport { lateOceanColorPalette } from './palettes/lateOceanColorPalette';\n\nexport const 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: colorsLateOceanTheme,\n palettes: { lateOcean: lateOceanColorPalette },\n avatar: avatarLateOceanTheme,\n button: buttonLateOceanTheme,\n card: cardLateOceanTheme,\n feedbackMessage: feedbackMessageLateOceanTheme,\n forms: formsLateOceanTheme,\n typography: typographyLateOceanTheme,\n tag: tagLateOceanTheme,\n shadows: shadowsLateOceanTheme,\n fullScreenModal: fullScreenModalLateOceanTheme,\n iconButton,\n listItem: listItemLateOceanTheme,\n};\n\nexport type KittTheme = {\n kitt: typeof theme;\n responsive: WindowSizeHelper;\n breakpoints: typeof breakpoints;\n} & Record<string, unknown>;\n","import type { ReactElement, ReactNode } from 'react';\nimport React from 'react';\nimport { PrimitiveView } from '../primitives/PrimitiveView';\n\nexport type TooltipPosition = 'bottom' | 'top' | 'left' | 'right';\n\nexport interface TooltipProps {\n children: NonNullable<ReactNode>;\n content: NonNullable<ReactNode>;\n defaultVisible?: boolean;\n fullWidth?: boolean;\n position: TooltipPosition;\n}\n\nexport function Tooltip({ children }: TooltipProps): ReactElement {\n return <PrimitiveView>{children}</PrimitiveView>;\n}\n","import type { ReactElement } from 'react';\nimport React from 'react';\nimport { Platform } from 'react-native';\nimport styled from 'styled-components';\nimport type { PrimitiveLinkProps } from '../primitives/PrimitiveLink';\nimport { PrimitiveLink } from '../primitives/PrimitiveLink';\nimport type { TypographyPropsWithoutRole } from './Typography';\nimport { Typography } from './Typography';\n\ninterface StyledLinkProps {\n disabled?: boolean;\n noUnderline?: boolean;\n}\n\nconst StyledLink = styled(PrimitiveLink).withConfig({\n shouldForwardProp: (prop, defaultValidatorFn) => !['disabled', 'noUnderline'].includes(prop),\n})<StyledLinkProps & PrimitiveLinkProps>`\n text-decoration: ${({ noUnderline }) => (noUnderline ? 'none' : 'underline')};\n\n ${({ disabled, theme, noUnderline }) => `\n ${disabled ? `color: ${theme.kitt.typography.link.disabledColor};` : ''}\n ${\n Platform.OS === 'web'\n ? `\n text-decoration-color: inherit;\n transition: color 0.2s ease-in-out;\n cursor: ${disabled ? 'not-allowed' : 'pointer'};\n\n\n &:hover, &:active, .kitt-hover & {\n text-decoration: ${noUnderline ? 'underline' : 'none'};\n }\n `\n : ''\n }`}\n`;\n\nexport interface TypographyLinkProps extends StyledLinkProps, TypographyPropsWithoutRole {\n variant: NonNullable<TypographyPropsWithoutRole['variant']>;\n href?: string;\n onPress: PrimitiveLinkProps['onPress'];\n}\n\nexport function TypographyLink({\n children,\n disabled,\n noUnderline,\n onPress,\n ...otherProps\n}: TypographyLinkProps): ReactElement {\n return (\n <Typography {...otherProps} accessibilityRole=\"none\">\n <StyledLink\n disabled={disabled}\n noUnderline={noUnderline}\n accessibilityRole=\"link\"\n onPress={disabled ? undefined : onPress}\n >\n {children}\n </StyledLink>\n </Typography>\n );\n}\n","import { useWindowDimensions } from 'react-native';\n\nexport interface MatchWindowSizeOptions {\n minWidth: number;\n maxWidth?: number;\n}\nexport function matchWindowSize(currentWidth: number, { minWidth, maxWidth }: MatchWindowSizeOptions): boolean {\n return currentWidth >= minWidth && (!maxWidth || currentWidth <= maxWidth);\n}\n\nexport function useMatchWindowSize(options: MatchWindowSizeOptions): boolean {\n const { width } = useWindowDimensions();\n return matchWindowSize(width, options);\n}\n","import 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(PrimitiveView)`\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 | null>(options: MatchWindowSizeOptions, valueIfTrue: T, valueIfFalse: T) => T;\n\n /**\n *\n * @example\n * ```typescript\n * const Container = styled(PrimitiveView)`\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 function createWindowSizeHelper(currentWidth: number): WindowSizeHelper {\n return {\n matchWindowSize: (options) => matchWindowSize(currentWidth, options),\n\n ifWindowSizeMatches: (options, valueIfTrue, valueIfFalse) =>\n matchWindowSize(currentWidth, 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]) =>\n matchWindowSize(currentWidth, { minWidth: Number(minWidth) }),\n );\n if (!found) return null;\n return found[1];\n },\n };\n}\n","import { useMemo } from 'react';\nimport type { KittTheme } from './themes/default';\nimport { breakpoints, theme as kittTheme } from './themes/default';\nimport { createWindowSizeHelper } from './utils/windowSize/createWindowSizeHelper';\nimport { useWindowSize } from './utils/windowSize/useWindowSize';\n\nexport function useKittTheme(): KittTheme {\n const { width } = useWindowSize();\n return useMemo(() => {\n return { kitt: kittTheme, responsive: createWindowSizeHelper(width), breakpoints };\n }, [width]);\n}\n","import { makeDecorator } from '@storybook/addons';\nimport type { ReactElement, ReactNode } from 'react';\nimport React from 'react';\nimport { ThemeProvider } from 'styled-components';\nimport type { KittTheme } from '../../../themes/default';\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)}</KittThemeProvider>;\n },\n});\n","import { makeDecorator } from '@storybook/addons';\nimport React from 'react';\nimport { SafeAreaProvider } from 'react-native-safe-area-context';\n\nexport const SafeAreaProviderDecorator = makeDecorator({\n name: 'SafeAreaProviderDecorator',\n parameterName: 'safeAreaProvider',\n wrapper: (storyFn, context, { options = {}, parameters = {} }) => {\n return <SafeAreaProvider>{storyFn(context)}</SafeAreaProvider>;\n },\n});\n","import React from 'react';\nimport 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}</>;\n}\n"],"names":["PrimitiveView","NativeView","SpinningIcon","children","animationRef","useRef","Animated","Value","rotation","current","interpolate","inputRange","outputRange","useEffect","process","env","TESTS","undefined","animation","loop","timing","toValue","duration","easing","Easing","linear","useNativeDriver","start","stop","React","transform","rotate","IconContainer","styled","color","size","align","Icon","icon","spin","clonedIcon","cloneElement","PrimitiveText","NativeText","TypographyTypeContext","createContext","TypographyColorContext","useTypographyColor","useContext","StyledTypography","theme","isHeader","type","variant","headers","bodies","kitt","typography","types","fontFamily","configs","baseAndSmall","fontSize","lineHeight","fontWeight","fontStyle","colors","isTypeHeader","startsWith","isTypographyHeader","base","typeInContext","Error","Typography","accessibilityRole","otherProps","nonNullableVariant","colorWithDefaultToBlack","content","TypographyText","props","TypographyParagraph","createHeading","level","defaultBase","TypographyHeading","displayName","Text","Paragraph","Header1","Header2","Header3","Header4","Header5","Header6","h1","h2","h3","h4","h5","getFirstCharacter","string","getInitials","firstname","lastname","toUpperCase","StyledAvatarView","round","light","avatar","backgroundColor","default","AvatarContent","src","Image","uri","width","height","UserIcon","Avatar","rest","PrimitivePressable","NativePressable","ButtonContainer","button","minWidth","stretch","maxWidth","minHeight","isPressed","disabled","disabledBackgroundColor","pressedBackgroundColor","contentPadding","borderRadius","disabledBorderColor","borderWidth","TypographyIconInheritColor","useTheme","TypographyIconSpecifiedColor","TypographyIcon","getTextColorByType","ButtonText","Content","iconOnly","iconPosition","value","spacing","ButtonIcon","testID","ButtonContent","iconSpin","Boolean","sharedIconProps","iconSize","useButton","setIsPressed","useState","handleButtonPressIn","handleButtonPressOut","Button","onPress","sharedProps","Container","card","padding","borderColor","Card","getColorFromState","state","InputFeedback","KittBreakpoints","BASE","SMALL","MEDIUM","LARGE","WIDE","KittBreakpointsMax","FieldContainer","FeedbackContainer","responsive","ifWindowSizeMatches","FieldLabelContainer","forms","inputField","labelContainerPaddingBottom","LabelContainer","iconMarginLeft","InputField","label","labelFeedback","input","feedback","useInputText","isFocused","setIsFocused","isPasswordVisible","setIsPasswordVisible","handleInputFocus","handleInputBlur","togglePasswordVisibility","isVisible","styledTextInputMixin","css","states","body","regular","Input","TextInput","multiline","Platform","OS","paddingSingleLineIOS","marginTop","marginBottom","PasswordButtonContainer","passwordButtonIconSize","getInputState","isDisabled","formState","keyboardTypeByTextInputType","text","email","password","username","autoCompleteTypeByType","autoCorrectByType","textContentTypeByType","InputText","forwardRef","id","internalForceState","onFocus","onBlur","ref","placeholderColor","selectionColor","e","EyeIcon","EyeOffIcon","passwordButtonIconColor","Label","htmlFor","OuterRadio","radio","unchecked","SelectedOuterRadio","checked","SelectedInnerRadio","innerBackgroundColor","innerSize","Radio","onChange","TextArea","textAreaMinHeight","Body","uiBackgroundLight","FullScreenModalBody","SideContainer","side","getHeaderHorizontalMediumPadding","Header","insetTop","paddingTop","fullScreenModal","header","paddingVertical","paddingHorizontal","HeaderContent","leftWidth","rightWidth","windowWidth","sideElementMaxWidth","Math","max","parentHorizontalPadding","parentHorizontalPaddingMedium","computeWidth","breakpointPadding","deltaMargin","abs","FullScreenModalHeader","right","left","top","useSafeAreaInsets","dimensions","useWindowDimensions","setLeftWidth","setRightWidth","handleLayoutChange","event","persist","nativeEvent","layout","uiBackground","FullScreenModal","PressableIconButton","iconButton","transition","scale","property","timingFunction","hover","breakpoints","min","mediumBreakpoint","medium","active","white","AnimatedIconButtonBackground","View","AnimatedViewContainer","PressableAnimatedContainer","pressed","useSharedValue","opacityStyles","useAnimatedStyle","opacity","withSpring","scaleStyles","IconButtonContentBorder","IconButtonContent","IconButton","ContentView","ListItemContent","SideContainerView","listItem","innerMargin","ListItemSideContainer","SideContentView","ListItemSideContent","ContainerView","withPadding","borders","ListItem","Wrapper","Fragment","wrapperProps","containerProps","SideContent","getActivityIndicatorSize","Loader","colorHex","ActivityIndicator","LargeLoader","xIconSize","mainIconSize","noRadius","feedbackMessage","backgroundColors","insets","CloseContainer","TouchableOpacity","centeredText","getColorByType","getIconContent","AlertCircleIcon","CheckIcon","AlertTriangleIcon","InfoIcon","Message","onDismiss","XIcon","OverlayPressable","StyleSheet","absoluteFillObject","overlay","dark","Overlay","PrimitiveScrollView","ScrollView","BodyView","ModalBody","FooterView","separator","ModalFooter","OnCloseContext","HeaderView","LeftIconView","RightIconView","TitleView","isIconLeft","ModalHeader","onClose","ModalView","palettes","lateOcean","Modal","visible","onEntered","onExited","NativeModal","Footer","Notification","onDelete","PrimitiveLink","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","title","contentContainerStyle","StyledSection","StorySection","className","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","tag","getLabelColor","Tag","lateOceanColorPalette","lateOceanLight1","lateOceanLight2","lateOceanLight3","warmEmbrace","warmEmbraceLight1","black1000","black555","black200","black100","black50","black25","viride","englishVermillon","goldCrayola","aero","transparent","moonPurple","moonPurpleLight1","avatarLateOceanTheme","buttonLateOceanTheme","primary","secondary","subtle","hoverBackgroundColor","focusBorderColor","cardLateOceanTheme","colorsLateOceanTheme","primaryLight","accent","accentLight","success","correct","danger","fullscreenLoader","feedbackMessageLateOceanTheme","warning","info","inputFieldLateOceanTheme","inputStatesStyle","focus","invalid","inputLateOceanTheme","radioLateOceanTheme","formsLateOceanTheme","fullScreenModalLateOceanTheme","listItemLateOceanTheme","shadowsLateOceanTheme","tagLateOceanTheme","fill","outline","calcLineHeight","lineHeightMultiplier","createTypographyTypeConfig","baseAndSmallFontSize","mediumAndWideFontSize","mediumAndWide","typographyLateOceanTheme","black","bold","header1","header2","header3","header4","header5","link","disabledColor","values","small","large","wide","smallBreakpoint","largeBreakpoint","wideBreakpoint","shadows","Tooltip","StyledLink","noUnderline","TypographyLink","matchWindowSize","currentWidth","useMatchWindowSize","options","createWindowSizeHelper","valueIfTrue","valueIfFalse","mapWindowWidth","widthList","slice","forEach","index","previousMinWidth","found","find","Number","useKittTheme","useWindowSize","useMemo","kittTheme","KittThemeProvider","ThemeProvider","KittThemeDecorator","makeDecorator","parameterName","wrapper","parameters","SafeAreaProviderDecorator","SafeAreaProvider","MatchWindowSize","matchWindowSizeOptions","match"],"mappings":";;;;;;;;;;;;;;;;;;;;MAuBaA,aAAa,GAAGC;;ACftB,SAASC,YAAT,CAAsB;AAAEC,EAAAA;AAAF,CAAtB,EAAqE;AAC1E,QAAMC,YAAY,GAAGC,YAAM,CAAC,IAAIC,oBAAQ,CAACC,KAAb,CAAmB,CAAnB,CAAD,CAA3B;AAEA,QAAMC,QAAQ,GAAGJ,YAAY,CAACK,OAAb,CAAqBC,WAArB,CAAiC;AAChDC,IAAAA,UAAU,EAAE,CAAC,CAAD,EAAI,CAAJ,CADoC;AAEhDC,IAAAA,WAAW,EAAE,CAAC,MAAD,EAAS,QAAT;AAFmC,GAAjC,CAAjB;AAKAC,EAAAA,eAAS,CAAC,MAAM;AACd,QAAIC,OAAO,CAACC,GAAR,CAAYC,KAAhB,EAAuB,OAAOC,SAAP;AAEvB,UAAMC,SAAS,GAAGZ,oBAAQ,CAACa,IAAT,CAChBb,oBAAQ,CAACc,MAAT,CAAgBhB,YAAY,CAACK,OAA7B,EAAsC;AACpCY,MAAAA,OAAO,EAAE,CAD2B;AAEpCC,MAAAA,QAAQ,EAAE,IAF0B;AAGpCC,MAAAA,MAAM,EAAEC,kBAAM,CAACC,MAHqB;AAIpCC,MAAAA,eAAe,EAAE;AAJmB,KAAtC,CADgB,CAAlB;AAQAR,IAAAA,SAAS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x","../src/Icon/Icon.tsx","../src/KittBreakpoints.ts","../src/typography/Typography.tsx","../src/Avatar/Avatar.tsx","../src/typography/TypographyIcon.tsx","../src/Button/ButtonContent.tsx","../src/Button/ButtonPressable.tsx","../src/Button/Button.tsx","../src/Card/Card.tsx","../src/Emoji/Emoji.tsx","../src/ExternalLink/ExternalLinkOpenLinkBehavior.ts","../src/ExternalLink/ExternalLink.tsx","../src/forms/InputFeedback/InputFeedback.tsx","../src/forms/InputField/InputField.tsx","../src/forms/InputText/useInputText.ts","../src/forms/InputText/InputText.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/utils/StyleWebWrapper.tsx","../src/utils/withTheme.tsx","../src/IconButton/PressableIconButton.tsx","../src/IconButton/PressableAnimatedContainer.tsx","../src/IconButton/IconButton.tsx","../src/ListItem/ListItemContent.tsx","../src/ListItem/ListItemSideContent.tsx","../src/ListItem/ListItem.tsx","../src/Loader/Loader.tsx","../src/Loader/LargeLoader.tsx","../src/Message/Message.tsx","../src/Overlay/Overlay.tsx","../src/Modal/Body.tsx","../src/Modal/Footer.tsx","../src/Modal/OnCloseContext.ts","../src/Modal/Header.tsx","../src/Modal/Modal.tsx","../src/Notification/Notification.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/themes/palettes/lateOceanColorPalette.ts","../src/themes/late-ocean/avatarLateOceanTheme.ts","../src/themes/late-ocean/buttonLateOceanTheme.ts","../src/themes/late-ocean/cardLateOceanTheme.ts","../src/themes/late-ocean/colorsLateOceanTheme.ts","../src/themes/late-ocean/feedbackMessageLateOceanTheme.ts","../src/themes/late-ocean/inputFieldLateOceanTheme.ts","../src/themes/late-ocean/inputLateOceanTheme.ts","../src/themes/late-ocean/radioLateOceanTheme.ts","../src/themes/late-ocean/formLateOceanTheme.ts","../src/themes/late-ocean/fullScreenModalLateOceanTheme.ts","../src/themes/late-ocean/iconButton.ts","../src/themes/late-ocean/listItemLateOceanTheme.ts","../src/themes/late-ocean/shadowsLateOceanTheme.ts","../src/themes/late-ocean/tagLateOceanTheme.ts","../src/themes/late-ocean/tooltip.ts","../src/themes/late-ocean/typographyLateOceanTheme.ts","../src/themes/default.ts","../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/windowSize/useMatchWindowSize.ts","../src/utils/windowSize/createWindowSizeHelper.ts","../src/useKittTheme.tsx","../src/utils/storybook/KittThemeDecorator.tsx","../src/utils/windowSize/MatchWindowSize.tsx"],"sourcesContent":["import type { ReactElement, ReactNode } from 'react';\nimport { useEffect, useRef } from 'react';\nimport { Animated, Easing } from 'react-native';\n\nexport interface SpinningIconProps {\n children: ReactNode;\n}\n\nexport function SpinningIcon({ children }: SpinningIconProps): ReactElement {\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.TESTS) 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.TESTS) return undefined;\n\n animation.stop();\n return undefined;\n };\n }, []);\n\n return <Animated.View style={{ transform: [{ rotate: rotation }] }}>{children}</Animated.View>;\n}\n","import type { ReactElement } from 'react';\nimport { cloneElement } from 'react';\nimport type { ViewStyle } from 'react-native';\nimport styled from 'styled-components/native';\nimport { SpinningIcon } from './SpinningIcon';\n\nexport interface IconProps {\n icon: ReactElement;\n size?: number;\n color: string;\n spin?: boolean;\n align?: ViewStyle['alignSelf'];\n testID?: ViewStyle['testID'];\n}\n\ninterface IconContainerProps {\n size?: number;\n color: string;\n align?: ViewStyle['alignSelf'];\n}\n\nconst 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 = 20, spin, align, color }: IconProps): ReactElement {\n const clonedIcon = cloneElement(icon, { color });\n\n return (\n <IconContainer align={align} size={size} color={color}>\n {spin ? <SpinningIcon>{clonedIcon}</SpinningIcon> : 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 { useWindowDimensions } from 'react-native';\nimport type { DefaultTheme } from 'styled-components/native';\nimport styled from 'styled-components/native';\nimport type { Except, SetOptional } from 'type-fest';\nimport { KittBreakpoints } from '../KittBreakpoints';\nimport type { TypographyTypeConfig } from '../themes/late-ocean/typographyLateOceanTheme';\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-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 };\n line-height: ${\n $isHeader\n ? headers.configs[$typeForCurrentWindowSize as TypographyHeaderType][typeConfigKey].lineHeight\n : bodies.configs[$typeForCurrentWindowSize as TypographyBodyType][typeConfigKey].lineHeight\n };\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 !$color\n ? ''\n : `\n color: ${theme.kitt.typography.colors[$color]};\n text-decoration-color: ${theme.kitt.typography.colors[$color]};\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\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 typeForCurrentWindowSize = useTypographyTypeForCurrentWindowSize(base, small, medium, large);\n const isHeader = isTypographyHeader(typeForCurrentWindowSize, isHeaderTypographyInContext);\n const nonNullableVariant: TypographyVariant = variant ?? (isHeader ? 'bold' : 'regular');\n // if isHeaderTypographyInContext exists, it means we are inside another typography so we don't want to\n // redefine the color, just inherit from it\n const colorWithDefaultToBlack: TypographyColor | undefined =\n color ?? (isHeaderTypographyInContext !== undefined ? undefined : 'black');\n\n const content = base ? (\n <IsHeaderTypographyContext.Provider value={isHeader}>\n <StyledTypography\n $color={colorWithDefaultToBlack}\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={colorWithDefaultToBlack}\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 return <Typography accessibilityRole=\"paragraph\" {...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 getFirstCharacter = (string: string): string => (string ? string[0] : '');\n\nconst getInitials = (firstname: string, lastname: string): string =>\n (getFirstCharacter(firstname) + getFirstCharacter(lastname)).toUpperCase();\n\nexport interface AvatarProps {\n size?: number;\n src?: string | null;\n firstname?: string | null;\n lastname?: string | null;\n round?: boolean;\n light?: boolean;\n}\n\nexport interface StyledAvatarViewProps extends Pick<AvatarProps, 'round' | 'light'> {\n size: number;\n}\n\nconst StyledAvatarView = styled.View<StyledAvatarViewProps>`\n border-radius: ${({ round, size }) => (round ? size / 2 : 10)}px;\n background-color: ${({ theme, light }) =>\n light ? 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\nfunction AvatarContent({ size = 40, src, firstname, lastname, light }: AvatarProps): ReactElement {\n if (src) {\n return <Image source={{ uri: src }} style={{ width: size, height: size }} />;\n }\n\n if (firstname && lastname) {\n return (\n <Typography.Text base=\"body-small\" variant=\"bold\" color={light ? 'black' : 'white'}>\n {getInitials(firstname, lastname)}\n </Typography.Text>\n );\n }\n\n return <Icon icon={<UserIcon />} color={light ? 'black' : 'white'} size={size / 2} />;\n}\n\nexport function Avatar({ size = 40, ...rest }: AvatarProps): ReactElement {\n return (\n <StyledAvatarView {...rest} size={size}>\n <AvatarContent {...rest} size={size} />\n </StyledAvatarView>\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'];\n}\n\nfunction TypographyIconInheritColor(props: TypographyIconProps): ReactElement {\n const color = useTypographyColor();\n const theme = useTheme();\n return <Icon {...props} color={theme.kitt.typography.colors[color]} />;\n}\n\nfunction TypographyIconSpecifiedColor({\n color,\n ...otherProps\n}: SetNonNullable<TypographyIconProps, 'color'>): ReactElement {\n const theme = useTheme();\n return <Icon {...otherProps} color={theme.kitt.typography.colors[color]} />;\n}\n\nexport function TypographyIcon({ color, ...otherProps }: TypographyIconProps): ReactElement {\n if (color) {\n return <TypographyIconSpecifiedColor color={color} {...otherProps} />;\n }\n\n return <TypographyIconInheritColor {...otherProps} />;\n}\n","import type { ReactElement } from 'react';\nimport styled, { useTheme } from 'styled-components/native';\nimport type { Except } from 'type-fest';\nimport type { TypographyColor } from '../typography/Typography';\nimport { Typography } from '../typography/Typography';\nimport { TypographyIcon } from '../typography/TypographyIcon';\nimport type { ButtonProps, ButtonType } from './Button';\n\nconst getTextColorByType = (type: ButtonType, isPressed: boolean, disabled: boolean): TypographyColor => {\n if (disabled) return 'black-light';\n switch (type) {\n case 'primary':\n return 'white';\n case 'subtle':\n return isPressed ? 'primary-light' : 'primary';\n case 'subtle-dark':\n return isPressed ? 'black-light' : 'black';\n case 'secondary':\n default:\n return 'black';\n }\n};\n\nconst ButtonText = styled(Typography.Text)`\n /* On native code, this is the only way to ensure that the text is centered */\n text-align: center;\n`;\n\ninterface ContentProps {\n stretch?: boolean;\n iconOnly?: boolean;\n}\n\nconst Content = styled.View<ContentProps>`\n flex-direction: row;\n align-items: center;\n justify-content: center;\n\n /*\n On native code flex grow does not work as expected which cause an issue with the flex props.\n In order to occupy only the needed space, we enable flex grow only when stretched\n */\n flex: ${({ stretch, iconOnly }) => `${stretch || iconOnly ? 1 : 0} 1 auto`};\n`;\n\ninterface IconContainerProps {\n iconPosition?: ButtonProps['iconPosition'];\n}\n\nconst IconContainer = styled.View<IconContainerProps>`\n ${({ theme, iconPosition }) => {\n const value = theme.kitt.spacing * 3;\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 spin: ButtonProps['iconSpin'];\n color: TypographyColor;\n size: number;\n iconPosition: ButtonContentProps['iconPosition'];\n testID?: string;\n}\n\nfunction ButtonIcon({ icon, spin, color, size, iconPosition, testID }: ButtonIconProps): ReactElement | null {\n return (\n <IconContainer iconPosition={iconPosition}>\n <TypographyIcon icon={icon} spin={spin} color={color} size={size} testID={testID} />\n </IconContainer>\n );\n}\n\ninterface ButtonContentProps extends Except<ButtonProps, 'onPress'> {\n isPressed?: boolean;\n type: NonNullable<ButtonType>;\n}\n\nexport function ButtonContent({\n type,\n isPressed,\n stretch,\n icon,\n iconPosition,\n iconSpin,\n disabled,\n children,\n}: ButtonContentProps): ReactElement | null {\n const color = getTextColorByType(type, Boolean(isPressed), Boolean(disabled));\n const theme = useTheme();\n\n const sharedIconProps = {\n spin: iconSpin,\n color,\n size: theme.kitt.button.iconSize,\n };\n\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 if (!children) {\n return (\n <Content iconOnly stretch={stretch}>\n {/* eslint-disable-next-line @typescript-eslint/no-non-null-assertion */}\n <TypographyIcon {...sharedIconProps} icon={icon!} />\n </Content>\n );\n }\n\n return (\n <Content stretch={stretch}>\n {icon && iconPosition === 'left' ? (\n <ButtonIcon {...sharedIconProps} icon={icon} iconPosition={iconPosition} testID=\"button-left-icon\" />\n ) : null}\n\n <ButtonText base=\"body\" color={color} variant=\"bold\">\n {children}\n </ButtonText>\n\n {icon && iconPosition === 'right' ? (\n <ButtonIcon {...sharedIconProps} icon={icon} iconPosition={iconPosition} />\n ) : null}\n </Content>\n );\n}\n","import type { PressableProps } from 'react-native';\nimport styled from 'styled-components/native';\nimport type { ButtonType } from './Button';\n\ninterface ButtonPressableProps extends PressableProps {\n type: ButtonType;\n isPressed?: boolean;\n disabled?: boolean;\n stretch?: boolean;\n}\n\nexport const ButtonPressable = styled.Pressable<ButtonPressableProps>`\n min-width: ${({ theme }) => theme.kitt.button.minWidth};\n max-width: ${({ theme, stretch }) => (stretch ? 'auto' : theme.kitt.button.maxWidth)};\n width: ${({ stretch }) => (stretch ? '100%' : 'auto')};\n min-height: ${({ theme }) => theme.kitt.button.minHeight};\n background-color: ${({ theme, isPressed, disabled, type }) => {\n if (disabled) {\n return theme.kitt.button[type].disabledBackgroundColor;\n }\n\n return isPressed ? theme.kitt.button[type].pressedBackgroundColor : theme.kitt.button[type].backgroundColor;\n }};\n padding: ${({ theme }) => theme.kitt.button.contentPadding.default};\n flex-direction: row;\n\n /* Emulate inline-* css display by making the button taking only its necessary space */\n align-self: flex-start;\n border-radius: ${({ theme }) => theme.kitt.button.borderRadius};\n border-color: ${({ theme, disabled, type }) =>\n disabled ? theme.kitt.button[type].disabledBorderColor : 'transparent'};\n border-width: ${({ theme }) => theme.kitt.button.borderWidth};\n`;\n","import type { ReactElement, ReactNode } from 'react';\nimport { useState } from 'react';\nimport type { PressableProps } from 'react-native';\nimport { ButtonContent } from './ButtonContent';\nimport { ButtonPressable } from './ButtonPressable';\n\nexport type ButtonType = 'primary' | 'secondary' | 'subtle' | 'subtle-dark';\n\ntype IconPosition = 'right' | 'left';\n\nexport interface ButtonProps {\n children?: ReactNode;\n type?: ButtonType;\n disabled?: boolean;\n icon?: ReactElement;\n iconPosition?: IconPosition;\n iconSpin?: boolean;\n stretch?: boolean;\n testID?: PressableProps['testID'];\n href?: PressableProps['href'];\n hrefAttrs?: PressableProps['hrefAttrs'];\n onPress?: () => void;\n}\n\nexport function Button({\n children,\n type = 'secondary',\n icon,\n iconPosition = 'left',\n iconSpin,\n stretch,\n disabled,\n testID,\n href,\n hrefAttrs,\n onPress,\n}: ButtonProps): ReactElement {\n const [isPressed, setIsPressed] = useState<boolean>(false);\n\n const handleButtonPressIn = (): void => setIsPressed(true);\n const handleButtonPressOut = (): void => setIsPressed(false);\n\n const sharedProps = {\n type,\n stretch,\n disabled,\n };\n\n return (\n <ButtonPressable\n // eslint-disable-next-line unicorn/expiring-todo-comments\n // TODO: When designs are defined, update with the proper onPress styles to mimic TouchableHighlight\n // underlayColor={globalTheme.button[type].pressedBackgroundColor}\n {...sharedProps}\n isPressed={isPressed}\n accessibilityRole=\"button\"\n testID={testID}\n href={href}\n hrefAttrs={hrefAttrs}\n onPress={onPress}\n onPressIn={handleButtonPressIn}\n onPressOut={handleButtonPressOut}\n >\n <ButtonContent {...sharedProps} icon={icon} iconPosition={iconPosition} iconSpin={iconSpin}>\n {children}\n </ButtonContent>\n </ButtonPressable>\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.card.padding};\n border-radius: ${({ theme }) => theme.kitt.card.borderRadius};\n border-width: ${({ theme }) => theme.kitt.card.borderWidth};\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 { 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?: () => void;\n}\n\nexport interface ExternalLinkProps<C extends VoidFunctionComponent<any>> {\n as: C;\n openLinkBehavior?: ExternalLinkOpenLinkBehavior;\n href?: string;\n onPress?: () => void;\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 = () => {\n if (onPress) onPress();\n if (!href) return;\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","import type { ReactElement, ReactNode } from 'react';\nimport type { TypographyColor, TypographyProps } from '../../typography/Typography';\nimport { Typography } from '../../typography/Typography';\nimport type { InputFormState } from '../InputFormState';\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 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 { useState } from 'react';\n\nexport const useInputText = (): {\n isFocused: boolean;\n handleInputFocus: () => void;\n handleInputBlur: () => void;\n isPasswordVisible: boolean;\n togglePasswordVisibility: () => void;\n} => {\n const [isFocused, setIsFocused] = useState<boolean>(false);\n const [isPasswordVisible, setIsPasswordVisible] = useState<boolean>(false);\n\n const handleInputFocus = (): void => setIsFocused(true);\n const handleInputBlur = (): void => setIsFocused(false);\n\n const togglePasswordVisibility = (): void => setIsPasswordVisible((isVisible) => !isVisible);\n\n return { isFocused, handleInputFocus, handleInputBlur, togglePasswordVisibility, isPasswordVisible };\n};\n","import { EyeIcon, EyeOffIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement } from 'react';\nimport { forwardRef } from 'react';\nimport type { KeyboardTypeOptions, TextInput as RNTextInput, TextInputProps as RNTextInputProps } from 'react-native';\nimport { Platform, TextInput } from 'react-native';\nimport styled, { css, useTheme } from 'styled-components/native';\nimport { getTypographyTypeConfigKey } from '../../typography/Typography';\nimport { TypographyIcon } from '../../typography/TypographyIcon';\nimport type { InputFormState } from '../InputFormState';\nimport { useInputText } from './useInputText';\n\ntype InputTextType = 'text' | 'email' | 'password' | 'username';\nexport type InputTextState = 'default' | 'invalid' | 'disabled' | 'hover' | 'focus';\n\nexport interface InputTextProps extends Exclude<RNTextInputProps, 'nativeID'> {\n id?: string;\n name?: string;\n disabled?: boolean;\n type: InputTextType;\n minHeight?: number;\n state?: InputFormState;\n /** @internal */\n internalForceState?: InputTextState;\n}\n\nexport interface TextInputMixinProps {\n state: InputTextState;\n}\ninterface InputProps extends TextInputMixinProps {\n minHeight: number;\n}\n\nexport const styledTextInputMixin = css<TextInputMixinProps>`\n /* stylelint-disable declaration-property-value-allowed-list */\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 border-width: ${({ theme }) => theme.kitt.forms.input.borderWidth};\n border-radius: ${({ theme }) => theme.kitt.forms.input.borderRadius};\n border-color: ${({ theme, state }) => theme.kitt.forms.input.states[state].borderColor};\n font-size: ${({ theme }) => {\n const typeConfigKey = getTypographyTypeConfigKey(theme);\n return theme.kitt.typography.types.bodies.configs.body[typeConfigKey].fontSize;\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\nconst Input = styled(TextInput)<InputProps>`\n /* stylelint-disable declaration-bang-space-before */\n /* stylelint-disable comment-word-disallowed-list */\n\n /* FIXME: text input is not vertically centered on iOS because of bigger line-height */\n ${styledTextInputMixin}\n padding: ${({ theme, multiline }) =>\n !multiline && Platform.OS === 'ios' ? theme.kitt.forms.input.paddingSingleLineIOS : theme.kitt.forms.input.padding};\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;\n }};\n min-height: ${({ minHeight }) => minHeight}px;\n`;\n\nconst Container = styled.View`\n margin-top: ${({ theme }) => theme.kitt.forms.input.marginTop};\n margin-bottom: ${({ theme }) => theme.kitt.forms.input.marginBottom};\n`;\n\nconst PasswordButtonContainer = styled.Pressable`\n position: absolute;\n right: 0;\n top: 0;\n bottom: 0;\n justify-content: center;\n padding: ${({ theme }) => theme.kitt.forms.input.passwordButtonIconSize / 2}px;\n`;\n\nconst getInputState = ({\n isDisabled,\n isFocused,\n formState,\n}: {\n isFocused: boolean;\n formState: InputFormState;\n isDisabled: boolean;\n}): InputTextState => {\n if (isDisabled) return 'disabled';\n if (isFocused) return 'focus';\n if (formState === 'invalid') return 'invalid';\n return 'default';\n};\n\nconst keyboardTypeByTextInputType: Record<InputTextType, KeyboardTypeOptions> = {\n text: 'default',\n email: 'email-address',\n password: 'default',\n username: 'default',\n};\n\nconst autoCompleteTypeByType: Record<InputTextType, 'off' | 'email' | 'password' | 'name'> = {\n text: 'off',\n email: 'email',\n password: 'password',\n username: 'name',\n};\n\nconst autoCorrectByType: Record<InputTextType, boolean> = {\n text: true,\n email: false,\n password: false,\n username: false,\n};\n\nconst textContentTypeByType: Record<InputTextType, 'none' | 'emailAddress' | 'password' | 'username'> = {\n text: 'none',\n email: 'emailAddress',\n password: 'password',\n username: 'username',\n};\n\nexport const InputText = forwardRef<RNTextInput, InputTextProps>(\n (\n {\n id,\n minHeight = 0,\n type,\n state: formState,\n internalForceState,\n disabled = false,\n onFocus,\n onBlur,\n ...props\n }: InputTextProps,\n ref,\n ): ReactElement => {\n const { isFocused, handleInputBlur, handleInputFocus, isPasswordVisible, togglePasswordVisibility } =\n useInputText();\n const theme = useTheme();\n const state = internalForceState || getInputState({ isFocused, isDisabled: disabled, formState });\n return (\n <Container>\n <Input\n ref={ref}\n nativeID={id}\n editable={!disabled}\n keyboardType={keyboardTypeByTextInputType[type]}\n autoCompleteType={autoCompleteTypeByType[type]}\n autoCorrect={autoCorrectByType[type]}\n minHeight={minHeight}\n textContentType={textContentTypeByType[type]}\n placeholderTextColor={theme.kitt.typography.colors[theme.kitt.forms.input.placeholderColor]}\n selectionColor={theme.kitt.forms.input.selectionColor}\n secureTextEntry={type === 'password' && !isPasswordVisible}\n {...props}\n state={state}\n onFocus={(e) => {\n handleInputFocus();\n if (onFocus) onFocus(e);\n }}\n onBlur={(e) => {\n handleInputBlur();\n if (onBlur) onBlur(e);\n }}\n />\n {type === 'password' && !disabled && (\n <PasswordButtonContainer accessibilityRole=\"button\" onPress={togglePasswordVisibility}>\n <TypographyIcon\n icon={isPasswordVisible ? <EyeIcon /> : <EyeOffIcon />}\n size={theme.kitt.forms.input.passwordButtonIconSize}\n color={theme.kitt.forms.input.states[state].passwordButtonIconColor}\n />\n </PasswordButtonContainer>\n )}\n </Container>\n );\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};\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 Omit<InputTextProps, 'type'> {}\n\nexport function TextArea({ ...props }: TextAreaProps): ReactElement {\n const theme = useTheme();\n return <InputText multiline {...props} type=\"text\" minHeight={theme.kitt.forms.input.textAreaMinHeight} />;\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 { ComponentProps, ElementType, ReactElement, ReactNode } from 'react';\nimport { Platform } from 'react-native';\n\nexport interface StyleWebWrapperProps<T extends ElementType> {\n as: T;\n // className?: string;\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);\n return <Component {...(props as any)}>{children}</Component>;\n}\n","import type { ComponentType } from 'react';\nimport { useTheme } from 'styled-components/native';\nimport type { DefaultTheme } from 'styled-components/native';\nimport type { SetOptional } 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 }>(\n // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\n WrappedComponent: any,\n): ComponentType<SetOptional<Props, 'theme'>> {\n return function ThemedComponent(props) {\n const theme = useTheme();\n\n return (<WrappedComponent theme={theme} {...(props as any)} />) 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 styled from 'styled-components/native';\nimport { StyleWebWrapper } from '../utils/StyleWebWrapper';\nimport { withTheme } from '../utils/withTheme';\nimport type { IconButtonContentProps } from './IconButton';\n\nconst PressableIconButtonWebWrapper = withTheme(styledLinaria.div`\n & > *:hover,\n .kitt-hover & > * {\n @media (hover: none) and (pointer: coarse) {\n transform: scale(${({ theme }) => theme.kitt.iconButton.scale.base.hover});\n }\n\n @media (${({ theme }) => theme.breakpoints.min.mediumBreakpoint}) {\n transform: scale(${({ theme }) => theme.kitt.iconButton.scale.medium.hover});\n }\n }\n\n & > *:active,\n .kitt-active & > * {\n transform: scale(${({ theme }) => theme.kitt.iconButton.scale.base.active});\n }\n\n & > *:hover,\n .kitt-hover & > *,\n & > *:focus,\n .kitt-focus & > *,\n & > *:active,\n .kitt-active & > * {\n background-color: ${({ theme }) => theme.kitt.iconButton.default.pressedBackgroundColor};\n }\n\n &[data-color-white] > *:hover,\n .kitt-hover &[data-color-white] > *,\n &[data-color-white] > *:focus,\n .kitt-focus &[data-color-white] > *,\n &[data-color-white] > *:active,\n .kitt-active &[data-color-white] > * {\n background-color: ${({ theme }) => theme.kitt.iconButton.white.pressedBackgroundColor};\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, ...props }: PressableIconButtonProps): ReactElement {\n return (\n <StyleWebWrapper as={PressableIconButtonWebWrapper} data-color-white={color === 'white'}>\n <StyledPressableIconButton {...props} />\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 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 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=\"button\"\n disabled={disabled}\n color={color}\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 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}\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({ icon, color, disabled, onPress }: IconButtonProps): ReactElement {\n return (\n <PressableAnimatedContainer color={color} disabled={disabled} onPress={onPress}>\n <IconButtonContent disabled={disabled} color={color} icon={icon} />\n </PressableAnimatedContainer>\n );\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 : 0)};\n margin-right: ${({ theme, side }) => (side === 'left' ? theme.kitt.listItem.innerMargin : 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 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}`;\n }\n\n if (borders === 'bottom') {\n return `border-bottom-width: ${borderWidth}`;\n }\n\n if (borders === 'both') {\n return `border-top-width: ${borderWidth}; border-bottom-width: ${borderWidth}`;\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 type { ReactElement } from 'react';\nimport { ActivityIndicator, Platform } from 'react-native';\nimport { useTheme } from 'styled-components/native';\nimport type { TypographyIconProps } from '../typography/TypographyIcon';\n\nexport interface LoaderProps {\n color?: TypographyIconProps['color'];\n size?: TypographyIconProps['size'];\n}\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 Loader({ color = 'primary', size = 20 }: LoaderProps): ReactElement {\n const theme = useTheme();\n const colorHex = theme.kitt.typography.colors[color];\n return <ActivityIndicator testID=\"ActivityIndicator\" color={colorHex} size={getActivityIndicatorSize(size)} />;\n}\n","import type { ReactElement } from 'react';\nimport type { LoaderProps } from './Loader';\nimport { Loader } from './Loader';\n\nexport interface LargeLoaderProps {\n color?: LoaderProps['color'];\n}\n\nexport function LargeLoader({ color = 'primary' }: LargeLoaderProps): ReactElement {\n return <Loader color={color} size={60} />;\n}\n","import { AlertCircleIcon, AlertTriangleIcon, CheckIcon, InfoIcon, XIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement, ReactNode } from 'react';\nimport { TouchableOpacity } from 'react-native';\nimport styled from 'styled-components/native';\nimport { Icon } from '../Icon/Icon';\nimport type { TypographyColor } from '../typography/Typography';\nimport { Typography } from '../typography/Typography';\n\nexport type MessageType = 'success' | 'warning' | 'danger' | 'info';\n\nconst xIconSize = 14;\nconst mainIconSize = 20;\n\nexport interface MessageProps {\n type?: MessageType;\n children: NonNullable<ReactNode>;\n noRadius?: boolean;\n centeredText?: boolean;\n insets?: { top?: number };\n onDismiss?: () => void;\n}\n\ninterface ContainerProps {\n type: MessageType;\n noRadius: boolean;\n insets: MessageProps['insets'];\n}\n\nconst Container = styled.View<ContainerProps>`\n border-radius: ${({ theme, noRadius }) => (noRadius ? 0 : theme.kitt.spacing * 5)}px;\n background-color: ${({ theme, type }) => theme.kitt.feedbackMessage.backgroundColors[type]};\n padding-bottom: ${({ theme }) => theme.kitt.spacing * 4}px;\n padding-left: ${({ theme }) => theme.kitt.spacing * 4}px;\n padding-right: ${({ theme }) => theme.kitt.spacing * 4}px;\n padding-top: ${({ theme, insets }) => (insets?.top ?? 0) + theme.kitt.spacing * 4}px;\n flex-direction: row;\n align-items: flex-start;\n justify-content: space-between;\n`;\n\nconst CloseContainer = styled(TouchableOpacity)`\n margin-left: ${({ theme }) => theme.kitt.spacing * 4}px;\n padding: ${({ theme }) => theme.kitt.spacing}px;\n`;\n\nconst IconContainer = styled.View`\n margin-right: ${({ theme }) => theme.kitt.spacing * 4}px;\n`;\n\ninterface ContentProps {\n type: MessageType;\n centeredText: boolean;\n}\n\nconst Content = styled.Text<ContentProps>`\n text-align: ${({ centeredText }) => (centeredText ? 'center' : 'left')};\n flex: 1;\n`;\n\nconst 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\nfunction getIconContent(type: MessageType): ReactElement {\n switch (type) {\n case 'warning':\n return <AlertCircleIcon />;\n case 'success':\n return <CheckIcon />;\n case 'danger':\n return <AlertTriangleIcon />;\n default:\n return <InfoIcon />;\n }\n}\n\nexport function Message({\n type = 'info',\n children,\n noRadius = false,\n centeredText = false,\n onDismiss,\n insets,\n}: MessageProps): ReactElement {\n const color = getColorByType(type);\n\n return (\n <Container type={type} noRadius={noRadius} insets={insets}>\n {!centeredText ? (\n <IconContainer>\n <Icon size={mainIconSize} color={color} icon={getIconContent(type)} />\n </IconContainer>\n ) : null}\n <Content type={type} centeredText={centeredText}>\n <Typography.Text base=\"body-small\" color={color}>\n {children}\n </Typography.Text>\n </Content>\n {onDismiss ? (\n <CloseContainer onPress={onDismiss}>\n <Icon icon={<XIcon />} size={xIconSize} color={color} />\n </CloseContainer>\n ) : null}\n </Container>\n );\n}\n","import type { ReactElement } from 'react';\nimport type { PressableProps } from 'react-native';\nimport { StyleSheet, View } from 'react-native';\nimport styled from 'styled-components/native';\n\ninterface OverlayProps {\n onPress: PressableProps['onPress'];\n}\n\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 (\n <OverlayPressable accessibilityRole=\"none\" onPress={onPress}>\n <View />\n </OverlayPressable>\n );\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 { 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 { Button } from '../Button/Button';\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 <Button type=\"subtle-dark\" 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};\n background-color: ${({ theme }) => theme.kitt.palettes.lateOcean.white};\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 type { ReactElement, ReactNode } from 'react';\nimport { useSafeAreaInsets } from 'react-native-safe-area-context';\nimport type { MessageProps } from '../Message/Message';\nimport { Message } from '../Message/Message';\n\nexport interface NotificationProps {\n children: NonNullable<ReactNode>;\n type?: MessageProps['type'];\n centeredText?: MessageProps['centeredText'];\n onDelete?: MessageProps['onDismiss'];\n}\n\nexport function Notification({ type, children, centeredText, onDelete }: NotificationProps): ReactElement {\n const { top } = useSafeAreaInsets();\n return (\n <Message noRadius type={type} centeredText={centeredText} insets={{ top }} onDismiss={onDelete}>\n {children}\n </Message>\n );\n}\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};\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};\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","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 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 avatarLateOceanTheme = {\n default: {\n color: lateOceanColorPalette.white,\n backgroundColor: lateOceanColorPalette.lateOcean,\n },\n light: {\n color: lateOceanColorPalette.black1000,\n backgroundColor: lateOceanColorPalette.black100,\n },\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const buttonLateOceanTheme = {\n borderRadius: '30px',\n borderWidth: '2px',\n minHeight: '42px',\n minWidth: '40px',\n maxWidth: '335px',\n iconSize: 18,\n contentPadding: {\n default: '8px 16px',\n },\n primary: {\n backgroundColor: lateOceanColorPalette.lateOcean,\n disabledBackgroundColor: lateOceanColorPalette.black50,\n pressedBackgroundColor: lateOceanColorPalette.lateOceanLight1,\n disabledBorderColor: lateOceanColorPalette.black100,\n },\n secondary: {\n backgroundColor: 'rgba(0, 0, 0, 0.05)',\n disabledBackgroundColor: lateOceanColorPalette.black50,\n pressedBackgroundColor: 'rgba(0, 0, 0, 0.1)',\n disabledBorderColor: lateOceanColorPalette.black100,\n },\n subtle: {\n backgroundColor: lateOceanColorPalette.transparent,\n disabledBackgroundColor: lateOceanColorPalette.transparent,\n pressedBackgroundColor: lateOceanColorPalette.transparent,\n disabledBorderColor: lateOceanColorPalette.transparent,\n },\n 'subtle-dark': {\n backgroundColor: lateOceanColorPalette.transparent,\n disabledBackgroundColor: lateOceanColorPalette.transparent,\n pressedBackgroundColor: lateOceanColorPalette.transparent,\n disabledBorderColor: lateOceanColorPalette.transparent,\n },\n white: {\n backgroundColor: 'rgba(255, 255, 255, 0.05)',\n disabledBackgroundColor: lateOceanColorPalette.transparent,\n hoverBackgroundColor: 'rgba(255, 255, 255, 0.1)',\n pressedBackgroundColor: 'rgba(255, 255, 255, 0.1)',\n focusBorderColor: 'rgba(255, 255, 255, 0.1)',\n disabledBorderColor: lateOceanColorPalette.transparent,\n },\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const cardLateOceanTheme = {\n borderRadius: '20px',\n borderWidth: '2px',\n padding: '16px',\n primary: {\n backgroundColor: lateOceanColorPalette.white,\n borderColor: lateOceanColorPalette.lateOcean,\n },\n secondary: {\n backgroundColor: lateOceanColorPalette.white,\n borderColor: lateOceanColorPalette.black100,\n },\n subtle: {\n backgroundColor: lateOceanColorPalette.black50,\n borderColor: lateOceanColorPalette.black100,\n },\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const colorsLateOceanTheme = {\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 separator: lateOceanColorPalette.black100,\n hover: lateOceanColorPalette.black100,\n black: lateOceanColorPalette.black1000,\n uiBackground: lateOceanColorPalette.black25,\n uiBackgroundLight: lateOceanColorPalette.white,\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';\n\nexport const feedbackMessageLateOceanTheme = {\n backgroundColors: {\n success: lateOceanColorPalette.viride,\n danger: lateOceanColorPalette.englishVermillon,\n warning: lateOceanColorPalette.goldCrayola,\n info: lateOceanColorPalette.aero,\n },\n};\n","export const inputFieldLateOceanTheme = {\n labelContainerPaddingBottom: 5,\n iconMarginLeft: 6,\n};\n","import type { InputTextState } from '../../forms/InputText/InputText';\nimport { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport type { typographyLateOceanTheme } from './typographyLateOceanTheme';\n\nexport type TypographyColor = keyof typeof typographyLateOceanTheme.colors;\nexport interface InputStateStyle {\n backgroundColor?: string;\n borderColor: string;\n color: TypographyColor;\n passwordButtonIconColor: TypographyColor;\n}\n\nconst inputStatesStyle: Record<InputTextState, InputStateStyle> = {\n default: {\n backgroundColor: lateOceanColorPalette.white,\n borderColor: lateOceanColorPalette.black100,\n color: 'black',\n passwordButtonIconColor: 'black',\n },\n hover: {\n borderColor: lateOceanColorPalette.black200,\n color: 'black',\n passwordButtonIconColor: 'black',\n },\n focus: {\n borderColor: lateOceanColorPalette.lateOcean,\n color: 'black',\n passwordButtonIconColor: 'black',\n },\n disabled: {\n backgroundColor: lateOceanColorPalette.black50,\n borderColor: lateOceanColorPalette.black100,\n color: 'black-light',\n passwordButtonIconColor: 'black-light',\n },\n invalid: {\n borderColor: lateOceanColorPalette.englishVermillon,\n color: 'black',\n passwordButtonIconColor: 'black',\n },\n};\n\nexport const inputLateOceanTheme = {\n marginTop: '2px',\n marginBottom: '4px',\n borderWidth: '2px',\n borderRadius: '10px',\n passwordButtonIconSize: 20,\n padding: '7px 16px',\n paddingSingleLineIOS: '12px 16px',\n selectionColor: lateOceanColorPalette.lateOcean,\n placeholderColor: 'black-light' as const,\n textAreaMinHeight: 120,\n states: inputStatesStyle,\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const radioLateOceanTheme = {\n size: 18,\n unchecked: {\n backgroundColor: lateOceanColorPalette.white,\n borderWidth: '2px',\n borderColor: lateOceanColorPalette.black200,\n },\n checked: {\n backgroundColor: lateOceanColorPalette.lateOcean,\n innerSize: 5,\n innerBackgroundColor: lateOceanColorPalette.white,\n },\n disabled: {\n backgroundColor: lateOceanColorPalette.black50,\n borderColor: lateOceanColorPalette.black100,\n },\n};\n","import { inputFieldLateOceanTheme } from './inputFieldLateOceanTheme';\nimport { inputLateOceanTheme } from './inputLateOceanTheme';\nimport { radioLateOceanTheme } from './radioLateOceanTheme';\n\nexport const formsLateOceanTheme = {\n input: inputLateOceanTheme,\n radio: radioLateOceanTheme,\n inputField: inputFieldLateOceanTheme,\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nexport const fullScreenModalLateOceanTheme = {\n header: {\n paddingVertical: 12,\n paddingHorizontal: 16,\n borderColor: lateOceanColorPalette.black100,\n },\n};\n","import { buttonLateOceanTheme } from './buttonLateOceanTheme';\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: buttonLateOceanTheme.secondary.disabledBackgroundColor,\n borderColor: buttonLateOceanTheme.secondary.disabledBorderColor,\n },\n default: {\n pressedBackgroundColor: buttonLateOceanTheme.secondary.pressedBackgroundColor,\n },\n white: {\n pressedBackgroundColor: buttonLateOceanTheme.white.hoverBackgroundColor,\n },\n};\n","import { colorsLateOceanTheme } from './colorsLateOceanTheme';\n\nexport const listItemLateOceanTheme = {\n padding: '12px 16px',\n borderColor: colorsLateOceanTheme.separator,\n borderWidth: '1px',\n innerMargin: '8px',\n};\n","export const shadowsLateOceanTheme = {\n medium: '0px 10px 20px rgba(41, 48, 51, 0.25)',\n};\n","import { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\nimport { colorsLateOceanTheme } from './colorsLateOceanTheme';\n\nexport const tagLateOceanTheme = {\n borderRadius: '10px',\n padding: '2px 12px',\n primary: {\n fill: {\n backgroundColor: lateOceanColorPalette.moonPurpleLight1,\n borderWidth: '0',\n borderColor: lateOceanColorPalette.transparent,\n },\n outline: {\n backgroundColor: lateOceanColorPalette.transparent,\n borderWidth: '1px',\n borderColor: lateOceanColorPalette.lateOcean,\n },\n },\n default: {\n fill: {\n backgroundColor: lateOceanColorPalette.black50,\n borderWidth: '0',\n borderColor: lateOceanColorPalette.transparent,\n },\n outline: {\n backgroundColor: lateOceanColorPalette.transparent,\n borderWidth: '1px',\n borderColor: lateOceanColorPalette.black1000,\n },\n },\n danger: {\n fill: {\n backgroundColor: lateOceanColorPalette.warmEmbrace,\n borderWidth: '0',\n borderColor: lateOceanColorPalette.transparent,\n },\n outline: {\n backgroundColor: lateOceanColorPalette.transparent,\n borderWidth: '1px',\n borderColor: colorsLateOceanTheme.danger,\n },\n },\n};\n","import { colorsLateOceanTheme } from './colorsLateOceanTheme';\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: colorsLateOceanTheme.black,\n borderRadius: 10,\n opacity: 0.95,\n horizontalPadding: 16,\n verticalPadding: 4,\n floatingPadding: 8,\n};\n","import { Platform } from 'react-native';\nimport { lateOceanColorPalette } from '../palettes/lateOceanColorPalette';\n\nconst calcLineHeight = (fontSize: number, lineHeightMultiplier: number): number =>\n Math.round(fontSize * lineHeightMultiplier);\n\nexport interface TypographyTypeBreakpointRangeConfig {\n fontSize: string;\n lineHeight: string;\n}\n\nexport interface TypographyTypeConfig {\n baseAndSmall: TypographyTypeBreakpointRangeConfig;\n mediumAndWide: TypographyTypeBreakpointRangeConfig;\n}\n\nconst createTypographyTypeConfig = (\n lineHeightMultiplier: number,\n baseAndSmallFontSize: number,\n mediumAndWideFontSize: number,\n): TypographyTypeConfig => ({\n baseAndSmall: {\n fontSize: `${baseAndSmallFontSize}px`,\n lineHeight: `${calcLineHeight(lineHeightMultiplier, baseAndSmallFontSize)}px`,\n },\n mediumAndWide: {\n fontSize: `${mediumAndWideFontSize}px`,\n lineHeight: `${calcLineHeight(lineHeightMultiplier, baseAndSmallFontSize)}px`,\n },\n});\n\nexport const typographyLateOceanTheme = {\n colors: {\n black: lateOceanColorPalette.black1000,\n 'black-light': lateOceanColorPalette.black555,\n white: lateOceanColorPalette.white,\n 'white-light': lateOceanColorPalette.white,\n primary: lateOceanColorPalette.lateOcean,\n 'primary-light': lateOceanColorPalette.lateOceanLight1,\n accent: lateOceanColorPalette.warmEmbrace,\n success: lateOceanColorPalette.viride,\n danger: lateOceanColorPalette.englishVermillon,\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 { avatarLateOceanTheme } from './late-ocean/avatarLateOceanTheme';\nimport { buttonLateOceanTheme } from './late-ocean/buttonLateOceanTheme';\nimport { cardLateOceanTheme } from './late-ocean/cardLateOceanTheme';\nimport { colorsLateOceanTheme } from './late-ocean/colorsLateOceanTheme';\nimport { feedbackMessageLateOceanTheme } from './late-ocean/feedbackMessageLateOceanTheme';\nimport { formsLateOceanTheme } from './late-ocean/formLateOceanTheme';\nimport { fullScreenModalLateOceanTheme } from './late-ocean/fullScreenModalLateOceanTheme';\nimport { iconButton } from './late-ocean/iconButton';\nimport { listItemLateOceanTheme } from './late-ocean/listItemLateOceanTheme';\nimport { shadowsLateOceanTheme } from './late-ocean/shadowsLateOceanTheme';\nimport { tagLateOceanTheme } from './late-ocean/tagLateOceanTheme';\nimport { tooltip } from './late-ocean/tooltip';\nimport { typographyLateOceanTheme } from './late-ocean/typographyLateOceanTheme';\nimport { lateOceanColorPalette } from './palettes/lateOceanColorPalette';\n\nexport const 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: colorsLateOceanTheme,\n palettes: { lateOcean: lateOceanColorPalette },\n avatar: avatarLateOceanTheme,\n button: buttonLateOceanTheme,\n card: cardLateOceanTheme,\n feedbackMessage: feedbackMessageLateOceanTheme,\n forms: formsLateOceanTheme,\n typography: typographyLateOceanTheme,\n tag: tagLateOceanTheme,\n shadows: shadowsLateOceanTheme,\n fullScreenModal: fullScreenModalLateOceanTheme,\n iconButton,\n listItem: listItemLateOceanTheme,\n tooltip,\n};\n\nexport type Theme = typeof theme;\n","import type { Event } 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: Event, 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 { InputTextState } from '@ornikar/kitt-universal';\nimport { useMemo, useState } from 'react';\n\nexport const timePickerPlaceholder = '--:--';\ntype TimePickerState = InputTextState;\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: TimePickerState;\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 =\n value === null\n ? timePickerPlaceholder\n : Intl.DateTimeFormat('fr-FR', { minute: 'numeric', hour: 'numeric' }).format(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 { Event } 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/InputText/InputText';\nimport { Typography } from '../typography/Typography';\nimport { ModalDateTimePicker } from './ModalDateTimePicker';\nimport { timePickerPlaceholder, useTimePicker } from './useTimePicker';\n\nconst Container = styled.Pressable`\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: Event, 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 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';\nimport Arrow from './arrow.inline.svg';\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 <Arrow 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 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 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 if (__DEV__) {\n if (!fontSize.endsWith('px')) throw new Error(`Unexpected font-size value: ${fontSize}`);\n }\n\n return <StyledTypographyEmoji size={parseInt(fontSize.slice(0, -2), 10)} 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 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\nconst TypographyLinkWebWrapper = withTheme(styledLinaria.span`\n & > *:hover,\n & > *:active,\n .kitt-hover & > * {\n text-decoration: underline;\n }\n\n &[data-nounderline] > *:hover,\n &[data-nounderline] > *:active,\n .kitt-hover &[data-nounderline] > * {\n text-decoration: none;\n }\n`);\n\ninterface StyledLinkProps {\n $disabled?: boolean;\n $noUnderline?: boolean;\n}\n\nconst StyledLink = styled.Text<StyledLinkProps & TextProps>`\n text-decoration: ${({ $noUnderline }) => ($noUnderline ? '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} data-nounderline={noUnderline}>\n <StyledLink\n $disabled={disabled}\n $noUnderline={noUnderline}\n href={href}\n hrefAttrs={hrefAttrs}\n accessibilityRole=\"link\"\n onPress={disabled ? undefined : onPress}\n >\n {children}\n </StyledLink>\n </StyleWebWrapper>\n </Typography>\n );\n}\n","import { useWindowDimensions } from 'react-native';\n\nexport interface MatchWindowSizeOptions {\n minWidth: number;\n maxWidth?: number;\n}\nexport function matchWindowSize(currentWidth: number, { minWidth, maxWidth }: MatchWindowSizeOptions): boolean {\n return currentWidth >= minWidth && (!maxWidth || currentWidth <= maxWidth);\n}\n\nexport function useMatchWindowSize(options: MatchWindowSizeOptions): boolean {\n const { width } = useWindowDimensions();\n return matchWindowSize(width, options);\n}\n","import 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 | null>(options: MatchWindowSizeOptions, valueIfTrue: T, valueIfFalse: T) => T;\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 function createWindowSizeHelper(currentWidth: number): WindowSizeHelper {\n return {\n matchWindowSize: (options) => matchWindowSize(currentWidth, options),\n\n ifWindowSizeMatches: (options, valueIfTrue, valueIfFalse) =>\n matchWindowSize(currentWidth, 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]) =>\n matchWindowSize(currentWidth, { minWidth: Number(minWidth) }),\n );\n if (!found) return null;\n return found[1];\n },\n };\n}\n","import { useMemo } from 'react';\nimport type { Theme } from './themes/default';\nimport { breakpoints, 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 breakpoints: typeof breakpoints;\n}\n\nexport function useKittTheme(): KittTheme {\n const { width } = useWindowSize();\n return useMemo(() => {\n return { kitt: kittTheme, responsive: createWindowSizeHelper(width), breakpoints };\n }, [width]);\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}</>;\n}\n"],"names":["SpinningIcon","children","animationRef","useRef","Animated","Value","rotation","current","interpolate","inputRange","outputRange","useEffect","process","env","TESTS","undefined","animation","loop","timing","toValue","duration","easing","Easing","linear","useNativeDriver","start","stop","_jsx","transform","rotate","IconContainer","styled","View","color","size","align","Icon","icon","spin","clonedIcon","cloneElement","KittBreakpoints","BASE","SMALL","MEDIUM","LARGE","WIDE","KittBreakpointsMax","IsHeaderTypographyContext","createContext","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","$color","colors","useTypographyTypeForCurrentWindowSize","base","small","medium","large","width","useWindowDimensions","Typography","accessibilityRole","variant","otherProps","isHeaderTypographyInContext","typeForCurrentWindowSize","isHeader","nonNullableVariant","colorWithDefaultToBlack","content","TypographyText","props","TypographyParagraph","createHeading","level","defaultBase","TypographyHeading","displayName","Paragraph","Header1","Header2","Header3","Header4","Header5","Header6","h1","h2","h3","h4","h5","getFirstCharacter","string","getInitials","firstname","lastname","toUpperCase","StyledAvatarView","round","light","avatar","backgroundColor","default","AvatarContent","src","Image","uri","height","UserIcon","Avatar","rest","TypographyIconInheritColor","useTheme","TypographyIconSpecifiedColor","TypographyIcon","getTextColorByType","isPressed","disabled","ButtonText","Content","stretch","iconOnly","iconPosition","value","spacing","ButtonIcon","testID","ButtonContent","iconSpin","Boolean","sharedIconProps","button","iconSize","_jsxs","ButtonPressable","Pressable","maxWidth","minHeight","disabledBackgroundColor","pressedBackgroundColor","contentPadding","borderRadius","disabledBorderColor","borderWidth","Button","href","hrefAttrs","onPress","setIsPressed","useState","sharedProps","Container","card","padding","borderColor","Card","StyledEmoji","Emoji","emoji","style","emojiData","useMemo","parse","assetType","text","url","defaultOpenLinkBehavior","native","web","ExternalLink","as","Component","openLinkBehavior","WebBrowser","catch","err","console","error","Linking","openURL","getColorFromState","state","InputFeedback","FieldContainer","FeedbackContainer","ifWindowSizeMatches","FieldLabelContainer","forms","inputField","labelContainerPaddingBottom","LabelContainer","iconMarginLeft","InputField","label","labelFeedback","input","feedback","useInputText","isFocused","setIsFocused","isPasswordVisible","setIsPasswordVisible","handleInputFocus","handleInputBlur","togglePasswordVisibility","isVisible","styledTextInputMixin","css","states","body","regular","Input","TextInput","multiline","paddingSingleLineIOS","marginTop","marginBottom","PasswordButtonContainer","passwordButtonIconSize","getInputState","isDisabled","formState","keyboardTypeByTextInputType","email","password","username","autoCompleteTypeByType","autoCorrectByType","textContentTypeByType","InputText","forwardRef","id","internalForceState","onFocus","onBlur","ref","placeholderColor","selectionColor","e","EyeIcon","EyeOffIcon","passwordButtonIconColor","Label","htmlFor","OuterRadio","radio","unchecked","SelectedOuterRadio","checked","SelectedInnerRadio","innerBackgroundColor","innerSize","Radio","onChange","TextArea","textAreaMinHeight","Body","uiBackgroundLight","FullScreenModalBody","SideContainer","side","getHeaderHorizontalMediumPadding","Header","insetTop","paddingTop","fullScreenModal","header","paddingVertical","paddingHorizontal","HeaderContent","leftWidth","rightWidth","windowWidth","sideElementMaxWidth","Math","max","parentHorizontalPadding","parentHorizontalPaddingMedium","computeWidth","breakpointPadding","deltaMargin","abs","FullScreenModalHeader","right","left","top","useSafeAreaInsets","dimensions","setLeftWidth","setRightWidth","handleLayoutChange","event","persist","nativeEvent","layout","uiBackground","FullScreenModal","StyleWebWrapper","withTheme","WrappedComponent","PressableIconButtonWebWrapper","iconButton","scale","hover","breakpoints","min","mediumBreakpoint","active","white","StyledPressableIconButton","transition","property","timingFunction","PressableIconButton","AnimatedIconButtonBackground","AnimatedViewContainer","PressableAnimatedContainer","pressed","useSharedValue","opacityStyles","useAnimatedStyle","opacity","withSpring","scaleStyles","IconButtonContentBorder","IconButtonContent","IconButton","ContentView","ListItemContent","SideContainerView","listItem","innerMargin","ListItemSideContainer","SideContentView","ListItemSideContent","ContainerView","withPadding","borders","ListItem","Wrapper","Fragment","wrapperProps","containerProps","SideContent","getActivityIndicatorSize","Loader","colorHex","ActivityIndicator","LargeLoader","xIconSize","mainIconSize","noRadius","feedbackMessage","backgroundColors","insets","CloseContainer","TouchableOpacity","centeredText","getColorByType","getIconContent","AlertCircleIcon","CheckIcon","AlertTriangleIcon","InfoIcon","Message","onDismiss","XIcon","OverlayPressable","StyleSheet","absoluteFillObject","overlay","dark","Overlay","BodyView","ModalBody","ScrollView","FooterView","separator","ModalFooter","OnCloseContext","HeaderView","LeftIconView","RightIconView","TitleView","isIconLeft","ModalHeader","onClose","ModalView","palettes","lateOcean","Modal","visible","onEntered","onExited","NativeModal","Footer","Notification","onDelete","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","title","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","StoryGrid","Row","Col","tag","getLabelColor","Tag","lateOceanColorPalette","lateOceanLight1","lateOceanLight2","lateOceanLight3","warmEmbrace","warmEmbraceLight1","black1000","black555","black200","black100","black50","black25","viride","englishVermillon","goldCrayola","aero","transparent","moonPurple","moonPurpleLight1","avatarLateOceanTheme","buttonLateOceanTheme","primary","secondary","subtle","hoverBackgroundColor","focusBorderColor","cardLateOceanTheme","colorsLateOceanTheme","primaryLight","accent","accentLight","success","correct","danger","black","fullscreenLoader","feedbackMessageLateOceanTheme","warning","info","inputFieldLateOceanTheme","inputStatesStyle","focus","invalid","inputLateOceanTheme","radioLateOceanTheme","formsLateOceanTheme","fullScreenModalLateOceanTheme","listItemLateOceanTheme","shadowsLateOceanTheme","tagLateOceanTheme","fill","outline","tooltip","horizontalPadding","verticalPadding","floatingPadding","calcLineHeight","lineHeightMultiplier","createTypographyTypeConfig","baseAndSmallFontSize","mediumAndWideFontSize","baseAndSmall","mediumAndWide","typographyLateOceanTheme","bold","header1","header2","header3","header4","header5","link","disabledColor","values","wide","smallBreakpoint","largeBreakpoint","wideBreakpoint","shadows","Title","ModalDateTimePicker","validateButtonLabel","currentValue","setCurrentValue","DateTimePicker","_event","date","prev","FormattedMessage","timePickerPlaceholder","useTimePicker","defaultValue","isTimePickerModalVisible","setIsTimePickerModalVisible","todayAtNoon","now","Date","getFullYear","getMonth","getDay","defaultDate","dateTimePickerValue","displayedValue","Intl","DateTimeFormat","minute","hour","format","timePickerState","handleInputPress","handleTimeChange","handleModalClose","TimePicker","forceDefaultValue","Arrow","StyledTooltipView","StyledTooltipContent","ArrowView","StyledArrow","$position","TooltipView","position","tooltipDefaultPosition","TooltipContainer","Tooltip","defaultVisible","onUpdate","x","y","reference","floating","update","refs","middlewareData","useFloating","placement","middleware","offset","shift","flip","strategy","bottom","StyledTypographyEmoji","TypographyEmoji","typeConfig","endsWith","parseInt","slice","TypographyLinkWebWrapper","StyledLink","$noUnderline","$disabled","TypographyLink","noUnderline","currentWidth","useMatchWindowSize","options","createWindowSizeHelper","valueIfTrue","valueIfFalse","mapWindowWidth","widthList","forEach","index","previousMinWidth","found","find","Number","useKittTheme","useWindowSize","kittTheme","KittThemeProvider","ThemeProvider","KittThemeDecorator","makeDecorator","parameterName","wrapper","parameters","MatchWindowSize","matchWindowSizeOptions","match"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAQO,SAASA,YAAT,CAAsB;AAAEC,EAAAA;AAAF,CAAtB,EAAqE;AAC1E,QAAMC,YAAY,GAAGC,YAAM,CAAC,IAAIC,oBAAQ,CAACC,KAAb,CAAmB,CAAnB,CAAD,CAA3B;AAEA,QAAMC,QAAQ,GAAGJ,YAAY,CAACK,OAAb,CAAqBC,WAArB,CAAiC;AAChDC,IAAAA,UAAU,EAAE,CAAC,CAAD,EAAI,CAAJ,CADoC;AAEhDC,IAAAA,WAAW,EAAE,CAAC,MAAD,EAAS,QAAT;AAFmC,GAAjC,CAAjB;AAKAC,EAAAA,eAAS,CAAC,MAAM;AACd,QAAIC,OAAO,CAACC,GAAR,CAAYC,KAAhB,EAAuB,OAAOC,SAAP;AAEvB,UAAMC,SAAS,GAAGZ,oBAAQ,CAACa,IAAT,CAChBb,oBAAQ,CAACc,MAAT,CAAgBhB,YAAY,CAACK,OAA7B,EAAsC;AACpCY,MAAAA,OAAO,EAAE,CAD2B;AAEpCC,MAAAA,QAAQ,EAAE,IAF0B;AAGpCC,MAAAA,MAAM,EAAEC,kBAAM,CAACC,MAHqB;AAIpCC,MAAAA,eAAe,EAAE;AAJmB,KAAtC,CADgB,CAAlB;AAQAR,IAAAA,SAAS,CAACS,KAAV;AACA,WAAO,MAAM;AACX,UAAIb,OAAO,CAACC,GAAR,CAAYC,KAAhB,EAAuB,OAAOC,SAAP;AAEvBC,MAAAA,SAAS,CAACU,IAAV;AACA,aAAOX,SAAP;AACD,KALD;AAMD,GAlBQ,EAkBN,EAlBM,CAAT;AAoBA,sBAAOY,eAACvB,oBAAD,CAAU,IAAV;AAAe,IAAA,KAAK,EAAE;AAAEwB,MAAAA,SAAS,EAAE,CAAC;AAAE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