@ornikar/kitt-universal 2.2.0 → 2.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/dist/definitions/Button/Button.d.ts +5 -2
  2. package/dist/definitions/Button/Button.d.ts.map +1 -1
  3. package/dist/definitions/Button/{ButtonContainer.d.ts → ButtonPressable.d.ts} +3 -3
  4. package/dist/definitions/Button/{ButtonContainer.d.ts.map → ButtonPressable.d.ts.map} +1 -1
  5. package/dist/definitions/ExternalLink/ExternalLink.d.ts +18 -0
  6. package/dist/definitions/ExternalLink/ExternalLink.d.ts.map +1 -0
  7. package/dist/definitions/ExternalLink/ExternalLink.web.d.ts +4 -0
  8. package/dist/definitions/ExternalLink/ExternalLink.web.d.ts.map +1 -0
  9. package/dist/definitions/ExternalLink/ExternalLinkOpenLinkBehavior.d.ts +24 -0
  10. package/dist/definitions/ExternalLink/ExternalLinkOpenLinkBehavior.d.ts.map +1 -0
  11. package/dist/definitions/index.d.ts +3 -1
  12. package/dist/definitions/index.d.ts.map +1 -1
  13. package/dist/definitions/primitives/PrimitiveLink.d.ts +3 -1
  14. package/dist/definitions/primitives/PrimitiveLink.d.ts.map +1 -1
  15. package/dist/definitions/primitives/PrimitiveLink.web.d.ts +1 -1
  16. package/dist/definitions/primitives/PrimitiveLink.web.d.ts.map +1 -1
  17. package/dist/definitions/primitives/PrimitivePressable.d.ts +2 -0
  18. package/dist/definitions/primitives/PrimitivePressable.d.ts.map +1 -1
  19. package/dist/definitions/primitives/PrimitivePressable.web.d.ts.map +1 -1
  20. package/dist/definitions/primitives/PrimitiveView.d.ts +2 -0
  21. package/dist/definitions/primitives/PrimitiveView.d.ts.map +1 -1
  22. package/dist/definitions/primitives/PrimitiveView.web.d.ts +6 -2
  23. package/dist/definitions/primitives/PrimitiveView.web.d.ts.map +1 -1
  24. package/dist/definitions/typography/TypographyLink.d.ts +7 -4
  25. package/dist/definitions/typography/TypographyLink.d.ts.map +1 -1
  26. package/dist/index-browser-all.es.android.js +117 -78
  27. package/dist/index-browser-all.es.android.js.map +1 -1
  28. package/dist/index-browser-all.es.ios.js +117 -78
  29. package/dist/index-browser-all.es.ios.js.map +1 -1
  30. package/dist/index-browser-all.es.js +117 -78
  31. package/dist/index-browser-all.es.js.map +1 -1
  32. package/dist/index-browser-all.es.web.js +203 -146
  33. package/dist/index-browser-all.es.web.js.map +1 -1
  34. package/dist/index-node-14.17.cjs.js +94 -55
  35. package/dist/index-node-14.17.cjs.js.map +1 -1
  36. package/dist/tsbuildinfo +1 -1
  37. package/package.json +3 -2
  38. package/dist/definitions/Button/useButton.d.ts +0 -6
  39. package/dist/definitions/Button/useButton.d.ts.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"index-browser-all.es.web.js","sources":["../src/primitives/reset.ts","../src/primitives/PrimitiveText.web.tsx","../src/primitives/helpers.ts","../src/primitives/PrimitiveView.web.tsx","../src/Icon/SpinningIcon.web.tsx","../src/Icon/Icon.tsx","../src/typography/Typography.tsx","../src/Avatar/Avatar.tsx","../src/primitives/PrimitivePressable.web.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.web.tsx","../src/IconButton/IconButton.tsx","../src/ListItem/ListItemContent.tsx","../src/ListItem/ListItemSideContent.tsx","../src/ListItem/ListItem.tsx","../src/Loader/LargeLoader.web.tsx","../src/Loader/Loader.web.tsx","../src/Message/Message.tsx","../src/Overlay/Overlay.tsx","../src/primitives/PrimitiveScrollView.web.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.web.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.web.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 { css } from 'styled-components';\n\nexport const resetMixin = css`\n border: 0 solid black;\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n`;\n","import type { AriaRole, ReactElement } from 'react';\nimport React, { createContext, forwardRef } from 'react';\nimport styled, { css } from 'styled-components';\nimport type { PrimitiveTextProps } from './PrimitiveText';\nimport { resetMixin } from './reset';\n\nconst mapAccessibilityRoleToAriaRole: Record<NonNullable<PrimitiveTextProps['accessibilityRole']>, AriaRole> = {\n header: 'heading',\n none: 'presentation',\n paragraph: 'paragraph',\n};\n\ntype HtmlHeaderComponents = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';\n\nexport const PrimitiveTextAncestorContext = createContext(false);\n\nconst PrimitiveTextWithClassName = forwardRef<HTMLDivElement, PrimitiveTextProps>(\n (\n {\n children,\n className,\n accessibilityRole,\n accessibilityRoleDescription,\n accessibilityLevel,\n selectable,\n numberOfLines,\n },\n ref,\n ): ReactElement => {\n const hasTextAncestor = React.useContext(PrimitiveTextAncestorContext);\n\n let Component: 'span' | 'div' | HtmlHeaderComponents = hasTextAncestor ? 'span' : 'div';\n if (accessibilityRole === 'header' && accessibilityLevel && accessibilityLevel < 7) {\n Component = `h${accessibilityLevel}` as HtmlHeaderComponents;\n // eslint-disable-next-line no-param-reassign\n accessibilityRole = undefined;\n // eslint-disable-next-line no-param-reassign\n accessibilityLevel = undefined;\n }\n\n const element = (\n <Component\n ref={ref}\n className={className}\n role={accessibilityRole ? mapAccessibilityRoleToAriaRole[accessibilityRole] : undefined}\n aria-roledescription={accessibilityRoleDescription}\n aria-level={accessibilityLevel}\n >\n {children}\n </Component>\n );\n\n return hasTextAncestor ? (\n element\n ) : (\n <PrimitiveTextAncestorContext.Provider value>{element}</PrimitiveTextAncestorContext.Provider>\n );\n },\n);\n\nexport const textResetMixin = css`\n ${resetMixin}\n display: inline;\n white-space: pre-wrap;\n word-wrap: break-word;\n color: inherit;\n font: inherit;\n`;\n\nexport const PrimitiveText = styled(PrimitiveTextWithClassName)`\n ${textResetMixin}\n ${({ selectable }) => (selectable == null ? undefined : `user-select: ${selectable ? 'text' : 'none'}`)};\n ${({ numberOfLines }) =>\n numberOfLines\n ? `\n display: -webkit-box;\n max-width: 100%;\n overflow: hidden;\n text-overflow: ellipsis;\n -webkit-line-clamp: ${numberOfLines};\n -webkit-box-orient: vertical;\n line-clamp: ${numberOfLines};\n `\n : ''}\n`;\n","import type { KeyboardEvent, KeyboardEventHandler, MouseEventHandler } from 'react';\nimport type { GestureResponderEvent } from 'react-native';\n\ntype OnPress = (event: GestureResponderEvent) => void;\n\nexport function createPressClickHandler<T = HTMLElement>(\n onPress: OnPress | MouseEventHandler<T> | undefined,\n): MouseEventHandler<T> | undefined {\n if (!onPress) return undefined;\n return (event) => {\n event.stopPropagation();\n onPress(event as any);\n };\n}\n\nconst isValidKeyPress = <T = HTMLElement>({ key, target }: KeyboardEvent<T>): boolean => {\n const role = (target as HTMLDivElement).getAttribute('role');\n const isSpacebar = key === ' ' || key === 'Spacebar';\n\n return key === 'Enter' || (isSpacebar && role === 'button');\n};\n\n// https://github.com/necolas/react-native-web/blob/b2eb3ca03ffc4b8570591b6c2082c6e4edae0e7f/packages/react-native-web/src/modules/usePressEvents/PressResponder.js#L300-L322\nexport function createPressKeyUpHandler<T = HTMLElement>(\n onPress: OnPress | MouseEventHandler<T> | undefined,\n): KeyboardEventHandler<T> | undefined {\n if (!onPress) return undefined;\n return (event) => {\n if (isValidKeyPress(event)) {\n onPress(event as any);\n }\n };\n}\n","import type { ComponentProps, MouseEventHandler, ReactElement } from 'react';\nimport React, { forwardRef } from 'react';\nimport styled from 'styled-components';\nimport type { Except } from 'type-fest';\nimport { PrimitiveTextAncestorContext } from './PrimitiveText.web';\nimport type { PrimitiveViewProps } from './PrimitiveView';\nimport { createPressClickHandler, createPressKeyUpHandler } from './helpers';\nimport { resetMixin } from './reset';\n\nexport interface BaseWebPrimitiveViewProps extends Except<PrimitiveViewProps, 'accessibilityRole'> {\n tabIndex?: HTMLDivElement['tabIndex'];\n}\n\ninterface WebPrimitiveViewPropsWithOnPress extends BaseWebPrimitiveViewProps {\n accessibilityRole: NonNullable<PrimitiveViewProps['accessibilityRole']>;\n onPress: (e?: MouseEventHandler<HTMLDivElement> | any) => void;\n}\n\ninterface WebPrimitiveViewPropsWithoutOnPress extends BaseWebPrimitiveViewProps {\n accessibilityRole?: NonNullable<PrimitiveViewProps['accessibilityRole']>;\n onPress?: never;\n}\n\nexport type WebPrimitiveViewProps = WebPrimitiveViewPropsWithOnPress | WebPrimitiveViewPropsWithoutOnPress;\n\ninterface StyledDivProps extends ComponentProps<'div'> {\n hasTextAncestor: boolean;\n}\n\nexport const StyledDiv = styled('div')<StyledDivProps>`\n ${resetMixin}\n align-items: stretch;\n display: ${({ hasTextAncestor }) => (hasTextAncestor ? 'inline-flex' : 'flex')};\n flex-basis: auto;\n flex-direction: column;\n flex-shrink: 0;\n min-height: 0;\n min-width: 0;\n position: 'relative';\n z-index: 0;\n`;\n\nexport const PrimitiveView = forwardRef<HTMLDivElement, WebPrimitiveViewProps>(\n ({ children, className, style, accessibilityRole, nativeID, testID, tabIndex, onPress }, ref): ReactElement => {\n const hasTextAncestor = React.useContext(PrimitiveTextAncestorContext);\n return (\n <StyledDiv\n ref={ref}\n hasTextAncestor={hasTextAncestor}\n id={nativeID}\n className={className}\n style={style as any}\n data-testid={testID}\n role={accessibilityRole}\n tabIndex={tabIndex}\n onClick={createPressClickHandler(onPress)}\n onKeyUp={createPressKeyUpHandler(onPress)}\n >\n {children}\n </StyledDiv>\n );\n },\n);\n","import styled, { keyframes } from 'styled-components';\nimport { PrimitiveView } from 'primitives/PrimitiveView';\n\nconst spin = keyframes`\n 0% {\n transform: rotate(-1deg);\n }\n\n 100% {\n transform: rotate(359deg);\n }\n`;\n\nexport const SpinningIcon = styled(PrimitiveView)`\n animation: ${spin} 1.1s infinite linear;\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 { 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 { MouseEventHandler, ReactElement } from 'react';\nimport React, { forwardRef } from 'react';\nimport styled from 'styled-components';\nimport type { PrimitivePressableProps } from './PrimitivePressable';\nimport { PrimitiveView } from './PrimitiveView.web';\n\n// https://github.com/necolas/react-native-web/blob/b2eb3ca03ffc4b8570591b6c2082c6e4edae0e7f/packages/react-native-web/src/modules/createDOMProps/index.js#L339-L371\nconst getTabIndex = ({ focusable, disabled }: { focusable?: boolean; disabled?: boolean | null }): 0 | -1 => {\n if (disabled) return -1;\n if (focusable === false) return -1;\n return 0;\n};\n\nconst handlePressPreventDefault: MouseEventHandler<HTMLDivElement> = (e) => {\n e.preventDefault();\n};\n\nconst PrimitivePressableWithClassName = forwardRef<HTMLDivElement, PrimitivePressableProps>(\n ({ disabled, focusable, children, className, accessibilityRole, nativeID, testID, onPress }, ref): ReactElement => {\n return (\n <PrimitiveView\n ref={ref}\n nativeID={nativeID}\n testID={testID}\n className={className}\n aria-disabled={!!disabled}\n accessibilityRole={accessibilityRole}\n /* https://necolas.github.io/react-native-web/docs/accessibility/#keyboard-focus */\n tabIndex={getTabIndex({ focusable, disabled })}\n onPress={disabled ? handlePressPreventDefault : onPress}\n >\n {children}\n </PrimitiveView>\n );\n },\n);\n\nexport const PrimitivePressable = styled(PrimitivePressableWithClassName)`\n cursor: ${({ disabled }) => (disabled ? 'not-allowed' : 'pointer')};\n touch-action: ${({ disabled }) => (disabled ? 'none' : 'manipulation')};\n`;\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 } from 'react';\nimport type { PressableAnimatedContainerProps } from './PressableAnimatedContainer';\nimport { PressableIconButton } from './PressableIconButton';\n\nexport function PressableAnimatedContainer({\n children,\n color,\n disabled,\n onPress,\n}: PressableAnimatedContainerProps): ReactElement {\n return (\n <PressableIconButton accessibilityRole=\"button\" color={color} disabled={disabled} onPress={onPress}>\n {children}\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 styled, { css, keyframes } from 'styled-components';\n\nconst init = keyframes`\n /**\n * 169.64 is the perimeter of each svg circle with a 27 radius\n * P = 2 * Pi * radius\n */\n 0% {\n stroke-dashoffset: 169.64px;\n }\n\n /* Edges needs a px value */\n 100% {\n /* stylelint-disable */\n stroke-dashoffset: 0;\n /* stylelint-enable */\n }\n`;\n\nconst offset = keyframes`\n0% {\n stroke-dashoffset: 169.64px;\n}\n\n/**\n * 34 equals 20% of this radius and represent the min offset part of the animated circle\n */\n100% {\n stroke-dashoffset: 34px;\n}\n`;\n\nconst rotate = keyframes`\n0% {\n transform: rotate(0deg);\n}\n\n100% {\n transform: rotate(360deg);\n}\n`;\n\nconst LargeLoaderContainer = styled.div`\n width: 60px;\n height: 60px;\n\n /* Needed to make the animation starting from the top of the circles */\n transform: scale(-1) rotate(90deg);\n`;\n\nconst LargeLoaderCircleMixin = css`\n transform-origin: center center;\n stroke-width: 3px;\n stroke-dasharray: 169.64px;\n stroke-dashoffset: 169.64px;\n stroke-linecap: round;\n`;\n\nconst LargeLoaderFill = styled.g`\n transform-origin: center center;\n animation: ${rotate} 1.8s linear 0.5s infinite;\n`;\n\nconst LargeLoaderBase = styled.g`\n transform-origin: center center;\n`;\n\nconst LargeLoaderBaseCircle = styled.circle`\n ${LargeLoaderCircleMixin}\n stroke: #ccc;\n animation: ${init} 1s cubic-bezier(0.39, 0.575, 0.565, 1) 0.5s forwards;\n`;\n\nconst LargeLoaderFillCircle = styled.circle`\n ${LargeLoaderCircleMixin}\n stroke: ${({ theme }) => theme.kitt.colors.primary};\n animation: ${offset} 1.8s cubic-bezier(0.39, 0.575, 0.565, 1) 0.5s infinite alternate,\n ${rotate} 2.16s linear 0.5s infinite;\n`;\n\nexport function LargeLoader(props: Record<string, never>): ReactElement {\n return (\n <LargeLoaderContainer>\n <svg width=\"60\" height=\"60\">\n <LargeLoaderBase>\n <LargeLoaderBaseCircle cx=\"30\" cy=\"30\" r=\"27\" fill=\"none\" />\n </LargeLoaderBase>\n <LargeLoaderFill>\n <LargeLoaderFillCircle cx=\"30\" cy=\"30\" r=\"27\" fill=\"none\" />\n </LargeLoaderFill>\n </svg>\n </LargeLoaderContainer>\n );\n}\n","import { LoaderIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement } from 'react';\nimport React from 'react';\nimport type { TypographyIconProps } from '../typography/TypographyIcon';\nimport { TypographyIcon } from '../typography/TypographyIcon';\n\nexport interface LoaderProps {\n color?: TypographyIconProps['color'];\n size?: TypographyIconProps['size'];\n}\n\nexport function Loader({ color = 'primary', size = 20 }: LoaderProps): ReactElement {\n return <TypographyIcon spin color={color} size={size} icon={<LoaderIcon />} />;\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 React, { forwardRef } from 'react';\nimport type { ReactElement } from 'react';\nimport type { PrimitiveScrollViewProps } from './PrimitiveScrollView';\nimport { PrimitiveView } from './PrimitiveView.web';\n\nexport const PrimitiveScrollView = forwardRef<HTMLDivElement, PrimitiveScrollViewProps>(\n ({ contentContainerStyle, children, ...props }: PrimitiveScrollViewProps, ref): ReactElement => {\n return (\n <PrimitiveView ref={ref} {...props}>\n <PrimitiveView style={contentContainerStyle}>{children}</PrimitiveView>\n </PrimitiveView>\n );\n },\n);\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 { ReactElement } from 'react';\nimport React, { forwardRef } from 'react';\nimport styled from 'styled-components';\nimport type { PrimitiveLinkProps } from './PrimitiveLink';\nimport { textResetMixin } from './PrimitiveText.web';\nimport { createPressClickHandler, createPressKeyUpHandler } from './helpers';\n\nconst PrimitiveTextWithClassName = forwardRef<HTMLSpanElement, PrimitiveLinkProps>(\n ({ children, className /* href */, onPress }, ref): ReactElement => {\n // https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/master/docs/rules/anchor-is-valid.md\n // if (href) {\n // return (\n // <a ref={ref} href={href} className={className}>\n // {children}\n // </a>\n // );\n // }\n\n return (\n <span\n ref={ref}\n role=\"button\"\n className={className}\n tabIndex={onPress ? 0 : -1}\n onClick={createPressClickHandler<HTMLSpanElement>(onPress)}\n onKeyUp={createPressKeyUpHandler<HTMLSpanElement>(onPress)}\n >\n {children}\n </span>\n );\n },\n);\n\nexport const PrimitiveLink = styled(PrimitiveTextWithClassName)`\n /* text reset */\n ${textResetMixin}\n\n /* a/button reset */\n background-color: transparent;\n color: inherit;\n font: inherit;\n list-style: none;\n text-align: inherit;\n text-decoration: none;\n\n /* link */\n ${({ selectable }) => (selectable == null ? undefined : `user-select: ${selectable ? 'none' : 'text'}`)};\n ${({ onPress }) => (onPress ? 'cursor: pointer;' : undefined)};\n`;\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 } from 'react';\nimport React from 'react';\nimport type { StoryContainerProps } from './StoryContainer';\nimport { StorySection } from './StorySection';\n\nexport function StoryContainer({ children, state, title, platform }: StoryContainerProps): ReactElement | null {\n if (platform === 'native') return null;\n\n return (\n <StorySection.BlockSection testID={state} title={title}>\n <div className={state ? `kitt-${state}` : undefined}>{children}</div>\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":["resetMixin","css","mapAccessibilityRoleToAriaRole","header","none","paragraph","PrimitiveTextAncestorContext","createContext","PrimitiveTextWithClassName","forwardRef","ref","children","className","accessibilityRole","accessibilityRoleDescription","accessibilityLevel","selectable","numberOfLines","hasTextAncestor","React","useContext","Component","undefined","element","textResetMixin","PrimitiveText","styled","createPressClickHandler","onPress","event","stopPropagation","isValidKeyPress","key","target","role","getAttribute","createPressKeyUpHandler","StyledDiv","PrimitiveView","style","nativeID","testID","tabIndex","spin","keyframes","SpinningIcon","IconContainer","color","size","align","Icon","icon","clonedIcon","cloneElement","TypographyTypeContext","TypographyColorContext","useTypographyColor","StyledTypography","theme","isHeader","type","variant","kitt","typography","types","headers","bodies","fontFamily","configs","baseAndSmall","fontSize","lineHeight","fontWeight","fontStyle","colors","isTypeHeader","startsWith","isTypographyHeader","base","typeInContext","Error","Typography","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","AvatarContent","src","uri","width","height","Avatar","rest","getTabIndex","focusable","disabled","handlePressPreventDefault","e","preventDefault","PrimitivePressableWithClassName","PrimitivePressable","ButtonContainer","button","minWidth","stretch","maxWidth","minHeight","isPressed","disabledBackgroundColor","pressedBackgroundColor","contentPadding","borderRadius","disabledBorderColor","borderWidth","TypographyIconInheritColor","useTheme","TypographyIconSpecifiedColor","TypographyIcon","getTextColorByType","ButtonText","Content","iconOnly","iconPosition","value","spacing","ButtonIcon","ButtonContent","iconSpin","Boolean","sharedIconProps","iconSize","useButton","useState","setIsPressed","handleButtonPressIn","handleButtonPressOut","Button","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","states","body","regular","Input","TextInput","multiline","paddingSingleLineIOS","marginTop","marginBottom","PasswordButtonContainer","passwordButtonIconSize","getInputState","isDisabled","formState","keyboardTypeByTextInputType","text","email","password","username","autoCompleteTypeByType","autoCorrectByType","textContentTypeByType","InputText","id","internalForceState","onFocus","onBlur","placeholderColor","selectionColor","passwordButtonIconColor","Label","htmlFor","OuterRadio","radio","unchecked","SelectedOuterRadio","checked","SelectedInnerRadio","innerBackgroundColor","innerSize","Radio","onChange","handlePress","TextArea","textAreaMinHeight","Body","uiBackgroundLight","FullScreenModalBody","SideContainer","side","getHeaderHorizontalMediumPadding","Header","insetTop","paddingTop","fullScreenModal","paddingVertical","paddingHorizontal","HeaderContent","leftWidth","rightWidth","windowWidth","sideElementMaxWidth","Math","max","parentHorizontalPadding","parentHorizontalPaddingMedium","computeWidth","breakpointPadding","deltaMargin","abs","FullScreenModalHeader","right","left","useSafeAreaInsets","top","dimensions","useWindowDimensions","setLeftWidth","setRightWidth","handleLayoutChange","persist","nativeEvent","layout","uiBackground","FullScreenModal","PressableIconButton","iconButton","transition","scale","property","duration","timingFunction","hover","breakpoints","min","mediumBreakpoint","medium","active","white","PressableAnimatedContainer","IconButtonContentBorder","IconButtonContent","IconButton","ContentView","ListItemContent","SideContainerView","listItem","innerMargin","ListItemSideContainer","SideContentView","ListItemSideContent","ContainerView","withPadding","borders","ListItem","Wrapper","Fragment","wrapperProps","containerProps","SideContent","init","offset","rotate","LargeLoaderContainer","div","LargeLoaderCircleMixin","LargeLoaderFill","g","LargeLoaderBase","LargeLoaderBaseCircle","circle","LargeLoaderFillCircle","primary","LargeLoader","Loader","xIconSize","mainIconSize","noRadius","feedbackMessage","backgroundColors","insets","CloseContainer","TouchableOpacity","centeredText","getColorByType","getIconContent","Message","onDismiss","OverlayPressable","StyleSheet","absoluteFillObject","overlay","dark","Overlay","PrimitiveScrollView","contentContainerStyle","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","StoryTitleLevel2","StoryTitleLevel3","StoryTitleLevel4","Level2","Level3","Level4","StoryContainer","Story","title","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","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","KittThemeDecorator","makeDecorator","parameterName","wrapper","parameters","SafeAreaProviderDecorator","MatchWindowSize","matchWindowSizeOptions","match"],"mappings":";;;;;;;;;;;;;AAEO,IAAMA,UAAU,gBAAGC,GAAH,oEAAhB;;ACIP,IAAMC,8BAAsG,GAAG;AAC7GC,EAAAA,MAAM,EAAE,SADqG;AAE7GC,EAAAA,IAAI,EAAE,cAFuG;AAG7GC,EAAAA,SAAS,EAAE;AAHkG,CAA/G;AAQO,IAAMC,4BAA4B,gBAAGC,aAAa,CAAC,KAAD,CAAlD;AAEP,IAAMC,4BAA0B,gBAAG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A,MAAI,CAACC,KAAL,EAAY,OAAO,IAAP;AACZ,sBAAO,0CAAGtiB,QAAH,CAAP;AACD;;;;"}
1
+ {"version":3,"file":"index-browser-all.es.web.js","sources":["../src/primitives/reset.ts","../src/primitives/PrimitiveText.web.tsx","../src/primitives/helpers.ts","../src/primitives/PrimitiveView.web.tsx","../src/Icon/SpinningIcon.web.tsx","../src/Icon/Icon.tsx","../src/typography/Typography.tsx","../src/Avatar/Avatar.tsx","../src/typography/TypographyIcon.tsx","../src/Button/ButtonContent.tsx","../src/primitives/PrimitivePressable.web.tsx","../src/Button/ButtonPressable.tsx","../src/Button/Button.tsx","../src/Card/Card.tsx","../src/ExternalLink/ExternalLinkOpenLinkBehavior.ts","../src/ExternalLink/ExternalLink.web.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.web.tsx","../src/IconButton/IconButton.tsx","../src/ListItem/ListItemContent.tsx","../src/ListItem/ListItemSideContent.tsx","../src/ListItem/ListItem.tsx","../src/Loader/LargeLoader.web.tsx","../src/Loader/Loader.web.tsx","../src/Message/Message.tsx","../src/Overlay/Overlay.tsx","../src/primitives/PrimitiveScrollView.web.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.web.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.web.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 { css } from 'styled-components';\n\nexport const resetMixin = css`\n border: 0 solid black;\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n`;\n","import type { AriaRole, ReactElement } from 'react';\nimport React, { createContext, forwardRef } from 'react';\nimport styled, { css } from 'styled-components';\nimport type { PrimitiveTextProps } from './PrimitiveText';\nimport { resetMixin } from './reset';\n\nconst mapAccessibilityRoleToAriaRole: Record<NonNullable<PrimitiveTextProps['accessibilityRole']>, AriaRole> = {\n header: 'heading',\n none: 'presentation',\n paragraph: 'paragraph',\n};\n\ntype HtmlHeaderComponents = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';\n\nexport const PrimitiveTextAncestorContext = createContext(false);\n\nconst PrimitiveTextWithClassName = forwardRef<HTMLDivElement, PrimitiveTextProps>(\n (\n {\n children,\n className,\n accessibilityRole,\n accessibilityRoleDescription,\n accessibilityLevel,\n selectable,\n numberOfLines,\n },\n ref,\n ): ReactElement => {\n const hasTextAncestor = React.useContext(PrimitiveTextAncestorContext);\n\n let Component: 'span' | 'div' | HtmlHeaderComponents = hasTextAncestor ? 'span' : 'div';\n if (accessibilityRole === 'header' && accessibilityLevel && accessibilityLevel < 7) {\n Component = `h${accessibilityLevel}` as HtmlHeaderComponents;\n // eslint-disable-next-line no-param-reassign\n accessibilityRole = undefined;\n // eslint-disable-next-line no-param-reassign\n accessibilityLevel = undefined;\n }\n\n const element = (\n <Component\n ref={ref}\n className={className}\n role={accessibilityRole ? mapAccessibilityRoleToAriaRole[accessibilityRole] : undefined}\n aria-roledescription={accessibilityRoleDescription}\n aria-level={accessibilityLevel}\n >\n {children}\n </Component>\n );\n\n return hasTextAncestor ? (\n element\n ) : (\n <PrimitiveTextAncestorContext.Provider value>{element}</PrimitiveTextAncestorContext.Provider>\n );\n },\n);\n\nexport const textResetMixin = css`\n ${resetMixin}\n display: inline;\n white-space: pre-wrap;\n word-wrap: break-word;\n color: inherit;\n font: inherit;\n`;\n\nexport const PrimitiveText = styled(PrimitiveTextWithClassName)`\n ${textResetMixin}\n ${({ selectable }) => (selectable == null ? undefined : `user-select: ${selectable ? 'text' : 'none'}`)};\n ${({ numberOfLines }) =>\n numberOfLines\n ? `\n display: -webkit-box;\n max-width: 100%;\n overflow: hidden;\n text-overflow: ellipsis;\n -webkit-line-clamp: ${numberOfLines};\n -webkit-box-orient: vertical;\n line-clamp: ${numberOfLines};\n `\n : ''}\n`;\n","import type { KeyboardEvent, KeyboardEventHandler, MouseEventHandler } from 'react';\nimport type { GestureResponderEvent } from 'react-native';\n\ntype OnPress = (event: GestureResponderEvent) => void;\n\nexport function createPressClickHandler<T = HTMLElement>(\n onPress: OnPress | MouseEventHandler<T> | undefined,\n): MouseEventHandler<T> | undefined {\n if (!onPress) return undefined;\n return (event) => {\n event.stopPropagation();\n onPress(event as any);\n };\n}\n\nconst isValidKeyPress = <T = HTMLElement>({ key, target }: KeyboardEvent<T>): boolean => {\n const role = (target as HTMLDivElement).getAttribute('role');\n const isSpacebar = key === ' ' || key === 'Spacebar';\n\n return key === 'Enter' || (isSpacebar && role === 'button');\n};\n\n// https://github.com/necolas/react-native-web/blob/b2eb3ca03ffc4b8570591b6c2082c6e4edae0e7f/packages/react-native-web/src/modules/usePressEvents/PressResponder.js#L300-L322\nexport function createPressKeyUpHandler<T = HTMLElement>(\n onPress: OnPress | MouseEventHandler<T> | undefined,\n): KeyboardEventHandler<T> | undefined {\n if (!onPress) return undefined;\n return (event) => {\n if (isValidKeyPress(event)) {\n onPress(event as any);\n }\n };\n}\n","import type { ComponentProps, ForwardedRef, MouseEventHandler, ReactElement } from 'react';\nimport React, { forwardRef } from 'react';\nimport styled, { css } from 'styled-components';\nimport type { Except } from 'type-fest';\nimport { PrimitiveTextAncestorContext } from './PrimitiveText.web';\nimport type { PrimitiveViewProps } from './PrimitiveView';\nimport { createPressClickHandler, createPressKeyUpHandler } from './helpers';\nimport { resetMixin } from './reset';\n\nexport interface BaseWebPrimitiveViewProps extends Except<PrimitiveViewProps, 'accessibilityRole'> {\n tabIndex?: HTMLDivElement['tabIndex'];\n}\n\ninterface WebPrimitiveViewPropsWithOnPress extends BaseWebPrimitiveViewProps {\n accessibilityRole: NonNullable<PrimitiveViewProps['accessibilityRole']>;\n onPress: (e?: MouseEventHandler<HTMLDivElement | HTMLAnchorElement> | any) => void;\n}\n\ninterface WebPrimitiveViewPropsWithoutOnPress extends BaseWebPrimitiveViewProps {\n accessibilityRole?: NonNullable<PrimitiveViewProps['accessibilityRole']>;\n onPress?: never;\n}\n\nexport type WebPrimitiveViewProps = WebPrimitiveViewPropsWithOnPress | WebPrimitiveViewPropsWithoutOnPress;\n\ninterface StyledDivProps extends ComponentProps<'div'> {\n hasTextAncestor: boolean;\n}\ninterface StyledAnchorProps extends ComponentProps<'a'> {\n hasTextAncestor: boolean;\n}\n\nconst resetPrimitiveViewMixin = css`\n ${resetMixin}\n align-items: stretch;\n flex-basis: auto;\n flex-direction: column;\n flex-shrink: 0;\n min-height: 0;\n min-width: 0;\n position: 'relative';\n z-index: 0;\n`;\n\nexport const StyledDiv = styled('div')<StyledDivProps>`\n ${resetPrimitiveViewMixin}\n display: ${({ hasTextAncestor }) => (hasTextAncestor ? 'inline-flex' : 'flex')};\n`;\n\nexport const StyledAnchor = styled('a')<StyledAnchorProps>`\n ${resetPrimitiveViewMixin}\n display: ${({ hasTextAncestor }) => (hasTextAncestor ? 'inline-flex' : 'flex')};\n text-decoration: none;\n`;\n\nexport const PrimitiveView = forwardRef<HTMLDivElement | HTMLAnchorElement, WebPrimitiveViewProps>(\n (\n { children, className, style, accessibilityRole, nativeID, testID, tabIndex, href, hrefAttrs, onPress },\n ref,\n ): ReactElement => {\n const hasTextAncestor = React.useContext(PrimitiveTextAncestorContext);\n if (href != null) {\n return (\n <StyledAnchor\n ref={ref as ForwardedRef<HTMLAnchorElement>}\n hasTextAncestor={hasTextAncestor}\n id={nativeID}\n className={className}\n style={style as any}\n data-testid={testID}\n role={accessibilityRole}\n tabIndex={tabIndex}\n href={href}\n {...hrefAttrs}\n onClick={createPressClickHandler(onPress)}\n onKeyUp={createPressKeyUpHandler(onPress)}\n >\n {children}\n </StyledAnchor>\n );\n }\n return (\n <StyledDiv\n ref={ref as ForwardedRef<HTMLDivElement>}\n hasTextAncestor={hasTextAncestor}\n id={nativeID}\n className={className}\n style={style as any}\n data-testid={testID}\n role={accessibilityRole}\n tabIndex={tabIndex}\n onClick={createPressClickHandler(onPress)}\n onKeyUp={createPressKeyUpHandler(onPress)}\n >\n {children}\n </StyledDiv>\n );\n },\n);\n","import styled, { keyframes } from 'styled-components';\nimport { PrimitiveView } from 'primitives/PrimitiveView';\n\nconst spin = keyframes`\n 0% {\n transform: rotate(-1deg);\n }\n\n 100% {\n transform: rotate(359deg);\n }\n`;\n\nexport const SpinningIcon = styled(PrimitiveView)`\n animation: ${spin} 1.1s infinite linear;\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 { 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 { 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 type { MouseEventHandler, ReactElement } from 'react';\nimport React, { forwardRef } from 'react';\nimport styled from 'styled-components';\nimport type { PrimitivePressableProps } from './PrimitivePressable';\nimport { PrimitiveView } from './PrimitiveView.web';\n\n// https://github.com/necolas/react-native-web/blob/b2eb3ca03ffc4b8570591b6c2082c6e4edae0e7f/packages/react-native-web/src/modules/createDOMProps/index.js#L339-L371\nconst getTabIndex = ({ focusable, disabled }: { focusable?: boolean; disabled?: boolean | null }): 0 | -1 => {\n if (disabled) return -1;\n if (focusable === false) return -1;\n return 0;\n};\n\nconst handlePressPreventDefault: MouseEventHandler<HTMLDivElement> = (e) => {\n e.preventDefault();\n};\n\nconst PrimitivePressableWithClassName = forwardRef<HTMLDivElement, PrimitivePressableProps>(\n (\n { disabled, focusable, children, className, accessibilityRole, nativeID, testID, href, hrefAttrs, onPress },\n ref,\n ): ReactElement => {\n return (\n <PrimitiveView\n ref={ref}\n nativeID={nativeID}\n testID={testID}\n className={className}\n href={href}\n hrefAttrs={hrefAttrs}\n accessibilityRole={accessibilityRole}\n aria-disabled={!!disabled}\n /* https://necolas.github.io/react-native-web/docs/accessibility/#keyboard-focus */\n tabIndex={getTabIndex({ focusable, disabled })}\n onPress={disabled ? handlePressPreventDefault : onPress}\n >\n {children}\n </PrimitiveView>\n );\n },\n);\n\nexport const PrimitivePressable = styled(PrimitivePressableWithClassName)`\n cursor: ${({ disabled }) => (disabled ? 'not-allowed' : 'pointer')};\n touch-action: ${({ disabled }) => (disabled ? 'none' : 'manipulation')};\n`;\n","import styled from 'styled-components';\nimport type { PrimitivePressableProps } from '../primitives/PrimitivePressable';\nimport { PrimitivePressable } from '../primitives/PrimitivePressable';\nimport type { ButtonType } from './Button';\n\ninterface ButtonPressableProps extends PrimitivePressableProps {\n type: ButtonType;\n isPressed?: boolean;\n disabled?: boolean;\n stretch?: boolean;\n}\n\nexport const ButtonPressable = styled(PrimitivePressable)<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 React, { useState } from 'react';\nimport type { PrimitivePressableProps } from '..';\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?: PrimitivePressableProps['testID'];\n href?: PrimitivePressableProps['href'];\n hrefAttrs?: PrimitivePressableProps['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 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","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 type { ReactElement, VoidFunctionComponent } from 'react';\nimport React from 'react';\nimport type { ExternalLinkProps, ExternalLinkSendableComponentProps } from './ExternalLink';\nimport { defaultOpenLinkBehavior } from './ExternalLinkOpenLinkBehavior';\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 return (\n <Component\n {...(rest as any)}\n href={href}\n hrefAttrs={openLinkBehavior?.web === 'targetSelf' ? undefined : { target: '_blank', rel: 'noopener noreferrer' }}\n onPress={onPress}\n />\n );\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 } from 'react';\nimport type { PressableAnimatedContainerProps } from './PressableAnimatedContainer';\nimport { PressableIconButton } from './PressableIconButton';\n\nexport function PressableAnimatedContainer({\n children,\n color,\n disabled,\n onPress,\n}: PressableAnimatedContainerProps): ReactElement {\n return (\n <PressableIconButton accessibilityRole=\"button\" color={color} disabled={disabled} onPress={onPress}>\n {children}\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 styled, { css, keyframes } from 'styled-components';\n\nconst init = keyframes`\n /**\n * 169.64 is the perimeter of each svg circle with a 27 radius\n * P = 2 * Pi * radius\n */\n 0% {\n stroke-dashoffset: 169.64px;\n }\n\n /* Edges needs a px value */\n 100% {\n /* stylelint-disable */\n stroke-dashoffset: 0;\n /* stylelint-enable */\n }\n`;\n\nconst offset = keyframes`\n0% {\n stroke-dashoffset: 169.64px;\n}\n\n/**\n * 34 equals 20% of this radius and represent the min offset part of the animated circle\n */\n100% {\n stroke-dashoffset: 34px;\n}\n`;\n\nconst rotate = keyframes`\n0% {\n transform: rotate(0deg);\n}\n\n100% {\n transform: rotate(360deg);\n}\n`;\n\nconst LargeLoaderContainer = styled.div`\n width: 60px;\n height: 60px;\n\n /* Needed to make the animation starting from the top of the circles */\n transform: scale(-1) rotate(90deg);\n`;\n\nconst LargeLoaderCircleMixin = css`\n transform-origin: center center;\n stroke-width: 3px;\n stroke-dasharray: 169.64px;\n stroke-dashoffset: 169.64px;\n stroke-linecap: round;\n`;\n\nconst LargeLoaderFill = styled.g`\n transform-origin: center center;\n animation: ${rotate} 1.8s linear 0.5s infinite;\n`;\n\nconst LargeLoaderBase = styled.g`\n transform-origin: center center;\n`;\n\nconst LargeLoaderBaseCircle = styled.circle`\n ${LargeLoaderCircleMixin}\n stroke: #ccc;\n animation: ${init} 1s cubic-bezier(0.39, 0.575, 0.565, 1) 0.5s forwards;\n`;\n\nconst LargeLoaderFillCircle = styled.circle`\n ${LargeLoaderCircleMixin}\n stroke: ${({ theme }) => theme.kitt.colors.primary};\n animation: ${offset} 1.8s cubic-bezier(0.39, 0.575, 0.565, 1) 0.5s infinite alternate,\n ${rotate} 2.16s linear 0.5s infinite;\n`;\n\nexport function LargeLoader(props: Record<string, never>): ReactElement {\n return (\n <LargeLoaderContainer>\n <svg width=\"60\" height=\"60\">\n <LargeLoaderBase>\n <LargeLoaderBaseCircle cx=\"30\" cy=\"30\" r=\"27\" fill=\"none\" />\n </LargeLoaderBase>\n <LargeLoaderFill>\n <LargeLoaderFillCircle cx=\"30\" cy=\"30\" r=\"27\" fill=\"none\" />\n </LargeLoaderFill>\n </svg>\n </LargeLoaderContainer>\n );\n}\n","import { LoaderIcon } from '@ornikar/kitt-icons';\nimport type { ReactElement } from 'react';\nimport React from 'react';\nimport type { TypographyIconProps } from '../typography/TypographyIcon';\nimport { TypographyIcon } from '../typography/TypographyIcon';\n\nexport interface LoaderProps {\n color?: TypographyIconProps['color'];\n size?: TypographyIconProps['size'];\n}\n\nexport function Loader({ color = 'primary', size = 20 }: LoaderProps): ReactElement {\n return <TypographyIcon spin color={color} size={size} icon={<LoaderIcon />} />;\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 React, { forwardRef } from 'react';\nimport type { ReactElement } from 'react';\nimport type { PrimitiveScrollViewProps } from './PrimitiveScrollView';\nimport { PrimitiveView } from './PrimitiveView.web';\n\nexport const PrimitiveScrollView = forwardRef<HTMLDivElement, PrimitiveScrollViewProps>(\n ({ contentContainerStyle, children, ...props }: PrimitiveScrollViewProps, ref): ReactElement => {\n return (\n <PrimitiveView ref={ref} {...props}>\n <PrimitiveView style={contentContainerStyle}>{children}</PrimitiveView>\n </PrimitiveView>\n );\n },\n);\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 { ForwardedRef, ReactElement } from 'react';\nimport React, { forwardRef } from 'react';\nimport styled from 'styled-components';\nimport type { PrimitiveLinkProps } from './PrimitiveLink';\nimport { textResetMixin } from './PrimitiveText.web';\nimport { createPressClickHandler, createPressKeyUpHandler } from './helpers';\n\nconst PrimitiveLinkWithClassName = forwardRef<HTMLSpanElement | HTMLAnchorElement, PrimitiveLinkProps>(\n ({ children, className, href, hrefAttrs, onPress }, ref): ReactElement => {\n if (href != null) {\n return (\n <a\n ref={ref as ForwardedRef<HTMLAnchorElement>}\n href={href}\n {...hrefAttrs}\n className={className}\n onClick={createPressClickHandler<HTMLAnchorElement>(onPress)}\n onKeyUp={createPressKeyUpHandler<HTMLAnchorElement>(onPress)}\n >\n {children}\n </a>\n );\n }\n\n return (\n <span\n ref={ref as ForwardedRef<HTMLSpanElement>}\n role=\"button\"\n className={className}\n tabIndex={onPress ? 0 : -1}\n onClick={createPressClickHandler<HTMLSpanElement>(onPress)}\n onKeyUp={createPressKeyUpHandler<HTMLSpanElement>(onPress)}\n >\n {children}\n </span>\n );\n },\n);\n\nexport const PrimitiveLink = styled(PrimitiveLinkWithClassName)`\n /* text reset */\n ${textResetMixin}\n\n /* a/button reset */\n background-color: transparent;\n color: inherit;\n font: inherit !important; /* remove !important when we delete kitt. See :global(a) in Link styles.module.css */\n list-style: none;\n text-align: inherit;\n text-decoration: none;\n\n /* link */\n ${({ selectable }) => (selectable == null ? undefined : `user-select: ${selectable ? 'text' : 'none'}`)};\n ${({ onPress }) => (onPress ? 'cursor: pointer;' : undefined)};\n`;\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 } from 'react';\nimport React from 'react';\nimport type { StoryContainerProps } from './StoryContainer';\nimport { StorySection } from './StorySection';\n\nexport function StoryContainer({ children, state, title, platform }: StoryContainerProps): ReactElement | null {\n if (platform === 'native') return null;\n\n return (\n <StorySection.BlockSection testID={state} title={title}>\n <div className={state ? `kitt-${state}` : undefined}>{children}</div>\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, ReactNode } from 'react';\nimport React from 'react';\nimport { Platform } from 'react-native';\nimport styled from 'styled-components';\nimport type { Except } from 'type-fest';\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, Except<TypographyPropsWithoutRole, 'children'> {\n children: NonNullable<ReactNode>;\n variant: NonNullable<TypographyPropsWithoutRole['variant']>;\n href?: PrimitiveLinkProps['href'];\n hrefAttrs?: PrimitiveLinkProps['hrefAttrs'];\n onPress: PrimitiveLinkProps['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 <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 </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":["resetMixin","css","mapAccessibilityRoleToAriaRole","header","none","paragraph","PrimitiveTextAncestorContext","createContext","PrimitiveTextWithClassName","forwardRef","ref","children","className","accessibilityRole","accessibilityRoleDescription","accessibilityLevel","selectable","numberOfLines","hasTextAncestor","React","useContext","Component","undefined","element","textResetMixin","PrimitiveText","styled","createPressClickHandler","onPress","event","stopPropagation","isValidKeyPress","key","target","role","getAttribute","createPressKeyUpHandler","resetPrimitiveViewMixin","StyledDiv","StyledAnchor","PrimitiveView","style","nativeID","testID","tabIndex","href","hrefAttrs","spin","keyframes","SpinningIcon","IconContainer","color","size","align","Icon","icon","clonedIcon","cloneElement","TypographyTypeContext","TypographyColorContext","useTypographyColor","StyledTypography","theme","isHeader","type","variant","kitt","typography","types","headers","bodies","fontFamily","configs","baseAndSmall","fontSize","lineHeight","fontWeight","fontStyle","colors","isTypeHeader","startsWith","isTypographyHeader","base","typeInContext","Error","Typography","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","AvatarContent","src","uri","width","height","Avatar","rest","TypographyIconInheritColor","useTheme","TypographyIconSpecifiedColor","TypographyIcon","getTextColorByType","isPressed","disabled","ButtonText","Content","stretch","iconOnly","iconPosition","value","spacing","ButtonIcon","ButtonContent","iconSpin","Boolean","sharedIconProps","button","iconSize","getTabIndex","focusable","handlePressPreventDefault","e","preventDefault","PrimitivePressableWithClassName","PrimitivePressable","ButtonPressable","minWidth","maxWidth","minHeight","disabledBackgroundColor","pressedBackgroundColor","contentPadding","borderRadius","disabledBorderColor","borderWidth","Button","useState","setIsPressed","sharedProps","handleButtonPressIn","handleButtonPressOut","Container","card","padding","borderColor","Card","defaultOpenLinkBehavior","web","ExternalLink","as","openLinkBehavior","rel","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","states","body","regular","Input","TextInput","multiline","paddingSingleLineIOS","marginTop","marginBottom","PasswordButtonContainer","passwordButtonIconSize","getInputState","isDisabled","formState","keyboardTypeByTextInputType","text","email","password","username","autoCompleteTypeByType","autoCorrectByType","textContentTypeByType","InputText","id","internalForceState","onFocus","onBlur","placeholderColor","selectionColor","passwordButtonIconColor","Label","htmlFor","OuterRadio","radio","unchecked","SelectedOuterRadio","checked","SelectedInnerRadio","innerBackgroundColor","innerSize","Radio","onChange","handlePress","TextArea","textAreaMinHeight","Body","uiBackgroundLight","FullScreenModalBody","SideContainer","side","getHeaderHorizontalMediumPadding","Header","insetTop","paddingTop","fullScreenModal","paddingVertical","paddingHorizontal","HeaderContent","leftWidth","rightWidth","windowWidth","sideElementMaxWidth","Math","max","parentHorizontalPadding","parentHorizontalPaddingMedium","computeWidth","breakpointPadding","deltaMargin","abs","FullScreenModalHeader","right","left","useSafeAreaInsets","top","dimensions","useWindowDimensions","setLeftWidth","setRightWidth","handleLayoutChange","persist","nativeEvent","layout","uiBackground","FullScreenModal","PressableIconButton","iconButton","transition","scale","property","duration","timingFunction","hover","breakpoints","min","mediumBreakpoint","medium","active","white","PressableAnimatedContainer","IconButtonContentBorder","IconButtonContent","IconButton","ContentView","ListItemContent","SideContainerView","listItem","innerMargin","ListItemSideContainer","SideContentView","ListItemSideContent","ContainerView","withPadding","borders","ListItem","Wrapper","Fragment","wrapperProps","containerProps","SideContent","init","offset","rotate","LargeLoaderContainer","div","LargeLoaderCircleMixin","LargeLoaderFill","g","LargeLoaderBase","LargeLoaderBaseCircle","circle","LargeLoaderFillCircle","primary","LargeLoader","Loader","xIconSize","mainIconSize","noRadius","feedbackMessage","backgroundColors","insets","CloseContainer","TouchableOpacity","centeredText","getColorByType","getIconContent","Message","onDismiss","OverlayPressable","StyleSheet","absoluteFillObject","overlay","dark","Overlay","PrimitiveScrollView","contentContainerStyle","BodyView","ModalBody","FooterView","separator","ModalFooter","OnCloseContext","HeaderView","LeftIconView","RightIconView","TitleView","isIconLeft","ModalHeader","onClose","ModalView","palettes","lateOcean","Modal","visible","onEntered","onExited","NativeModal","Footer","Notification","onDelete","PrimitiveLinkWithClassName","PrimitiveLink","Flex","withConfig","shouldForwardProp","prop","defaultValidatorFn","includes","direction","storyPadding","getBackgroundColorFromBlockColor","getTypographyColorFromBlockColor","StoryBlockBackgroundContext","StoryBlockColorContext","useStoryBlockColor","storyBlockColor","StyledStoryBlockView","background","StoryBlock","StoryTitleContainer","StorySubTitleContainer","StoryTitle","StoryTitleLevel2","StoryTitleLevel3","StoryTitleLevel4","Level2","Level3","Level4","StoryContainer","Story","title","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","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","KittThemeDecorator","makeDecorator","parameterName","wr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