@onewelcome/react-lib-components 0.1.0-alpha → 0.1.1-alpha

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 (100) hide show
  1. package/dist/Button/IconButton.d.ts +1 -1
  2. package/dist/Form/Fieldset/Fieldset.d.ts +6 -4
  3. package/dist/Form/FormControl/FormControl.d.ts +2 -1
  4. package/dist/Form/Wrapper/SelectWrapper/SelectWrapper.d.ts +2 -1
  5. package/dist/{BaseModal → Notifications/BaseModal}/BaseModal.d.ts +4 -2
  6. package/dist/{BaseModal → Notifications/BaseModal}/BaseModalActions/BaseModalActions.d.ts +0 -0
  7. package/dist/{BaseModal → Notifications/BaseModal}/BaseModalContent/BaseModalContent.d.ts +0 -0
  8. package/dist/{BaseModal → Notifications/BaseModal}/BaseModalContext.d.ts +0 -0
  9. package/dist/{BaseModal → Notifications/BaseModal}/BaseModalHeader/BaseModalHeader.d.ts +1 -1
  10. package/dist/{Dialog → Notifications/Dialog}/Dialog.d.ts +4 -3
  11. package/dist/{Dialog → Notifications/Dialog}/DialogActions/DialogActions.d.ts +0 -0
  12. package/dist/{Dialog → Notifications/Dialog}/DialogTitle/DialogTitle.d.ts +0 -0
  13. package/dist/Notifications/DiscardChangesModal/DiscardChangesDialog/DiscardChangesDialog.d.ts +12 -0
  14. package/dist/Notifications/DiscardChangesModal/DiscardChangesModal.d.ts +11 -0
  15. package/dist/{Modal → Notifications/Modal}/Modal.d.ts +0 -0
  16. package/dist/{Modal → Notifications/Modal}/ModalActions/ModalActions.d.ts +0 -0
  17. package/dist/{Modal → Notifications/Modal}/ModalContent/ModalContent.d.ts +0 -0
  18. package/dist/{Modal → Notifications/Modal}/ModalHeader/ModalHeader.d.ts +0 -0
  19. package/dist/{Snackbar → Notifications/Snackbar}/SnackbarContainer/SnackbarContainer.d.ts +0 -0
  20. package/dist/{Snackbar → Notifications/Snackbar}/SnackbarItem/SnackbarItem.d.ts +0 -0
  21. package/dist/{Snackbar → Notifications/Snackbar}/SnackbarProvider/SnackbarProvider.d.ts +1 -1
  22. package/dist/{Snackbar → Notifications/Snackbar}/SnackbarProvider/SnackbarStateProvider.d.ts +0 -0
  23. package/dist/{Snackbar → Notifications/Snackbar}/interfaces.d.ts +0 -0
  24. package/dist/{Snackbar → Notifications/Snackbar}/useSnackbar.d.ts +0 -0
  25. package/dist/Tiles/Tile.d.ts +4 -5
  26. package/dist/index.d.ts +8 -7
  27. package/dist/react-lib-components.cjs.development.js +226 -125
  28. package/dist/react-lib-components.cjs.development.js.map +1 -1
  29. package/dist/react-lib-components.cjs.production.min.js +1 -1
  30. package/dist/react-lib-components.cjs.production.min.js.map +1 -1
  31. package/dist/react-lib-components.esm.js +226 -126
  32. package/dist/react-lib-components.esm.js.map +1 -1
  33. package/package.json +1 -1
  34. package/src/Button/IconButton.tsx +8 -4
  35. package/src/Form/Checkbox/Checkbox.module.scss +4 -0
  36. package/src/Form/Checkbox/Checkbox.tsx +11 -6
  37. package/src/Form/Fieldset/Fieldset.module.scss +11 -1
  38. package/src/Form/Fieldset/Fieldset.test.tsx +2 -2
  39. package/src/Form/Fieldset/Fieldset.tsx +22 -10
  40. package/src/Form/FormControl/FormControl.tsx +3 -0
  41. package/src/Form/Radio/Radio.module.scss +4 -0
  42. package/src/Form/Radio/Radio.tsx +12 -2
  43. package/src/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.test.tsx +1 -1
  44. package/src/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.tsx +1 -1
  45. package/src/Form/Wrapper/RadioWrapper/RadioWrapper.test.tsx +1 -1
  46. package/src/Form/Wrapper/RadioWrapper/RadioWrapper.tsx +1 -1
  47. package/src/Form/Wrapper/SelectWrapper/SelectWrapper.tsx +2 -1
  48. package/src/{BaseModal → Notifications/BaseModal}/BaseModal.module.scss +0 -0
  49. package/src/{BaseModal → Notifications/BaseModal}/BaseModal.test.tsx +8 -15
  50. package/src/{BaseModal → Notifications/BaseModal}/BaseModal.tsx +11 -24
  51. package/src/{BaseModal → Notifications/BaseModal}/BaseModalActions/BaseModalActions.module.scss +0 -0
  52. package/src/{BaseModal → Notifications/BaseModal}/BaseModalActions/BaseModalActions.test.tsx +0 -0
  53. package/src/{BaseModal → Notifications/BaseModal}/BaseModalActions/BaseModalActions.tsx +0 -0
  54. package/src/{BaseModal → Notifications/BaseModal}/BaseModalContent/BaseModalContent.module.scss +0 -0
  55. package/src/{BaseModal → Notifications/BaseModal}/BaseModalContent/BaseModalContent.test.tsx +0 -0
  56. package/src/{BaseModal → Notifications/BaseModal}/BaseModalContent/BaseModalContent.tsx +0 -0
  57. package/src/{BaseModal → Notifications/BaseModal}/BaseModalContext.ts +0 -0
  58. package/src/{BaseModal → Notifications/BaseModal}/BaseModalHeader/BaseModalHeader.module.scss +0 -0
  59. package/src/{BaseModal → Notifications/BaseModal}/BaseModalHeader/BaseModalHeader.test.tsx +0 -0
  60. package/src/{BaseModal → Notifications/BaseModal}/BaseModalHeader/BaseModalHeader.tsx +6 -6
  61. package/src/{Dialog → Notifications/Dialog}/Dialog.module.scss +0 -0
  62. package/src/{Dialog → Notifications/Dialog}/Dialog.test.tsx +13 -16
  63. package/src/{Dialog → Notifications/Dialog}/Dialog.tsx +17 -6
  64. package/src/{Dialog → Notifications/Dialog}/DialogActions/DialogActions.module.scss +0 -0
  65. package/src/{Dialog → Notifications/Dialog}/DialogActions/DialogActions.test.tsx +0 -0
  66. package/src/{Dialog → Notifications/Dialog}/DialogActions/DialogActions.tsx +0 -0
  67. package/src/{Dialog → Notifications/Dialog}/DialogTitle/DialogTitle.module.scss +0 -0
  68. package/src/{Dialog → Notifications/Dialog}/DialogTitle/DialogTitle.test.tsx +0 -0
  69. package/src/{Dialog → Notifications/Dialog}/DialogTitle/DialogTitle.tsx +3 -3
  70. package/src/Notifications/DiscardChangesModal/DiscardChangesDialog/DiscardChangesDialog.test.tsx +55 -0
  71. package/src/Notifications/DiscardChangesModal/DiscardChangesDialog/DiscardChangesDialog.tsx +48 -0
  72. package/src/Notifications/DiscardChangesModal/DiscardChangesModal.test.tsx +111 -0
  73. package/src/Notifications/DiscardChangesModal/DiscardChangesModal.tsx +56 -0
  74. package/src/{Modal → Notifications/Modal}/Modal.test.tsx +0 -0
  75. package/src/{Modal → Notifications/Modal}/Modal.tsx +0 -0
  76. package/src/{Modal → Notifications/Modal}/ModalActions/ModalActions.tsx +0 -0
  77. package/src/{Modal → Notifications/Modal}/ModalContent/ModalContent.tsx +0 -0
  78. package/src/{Modal → Notifications/Modal}/ModalHeader/ModalHeader.tsx +0 -0
  79. package/src/{Snackbar → Notifications/Snackbar}/SnackbarContainer/SnackbarContainer.module.scss +0 -0
  80. package/src/{Snackbar → Notifications/Snackbar}/SnackbarContainer/SnackbarContainer.test.tsx +0 -0
  81. package/src/{Snackbar → Notifications/Snackbar}/SnackbarContainer/SnackbarContainer.tsx +0 -0
  82. package/src/{Snackbar → Notifications/Snackbar}/SnackbarItem/SnackbarItem.module.scss +1 -1
  83. package/src/{Snackbar → Notifications/Snackbar}/SnackbarItem/SnackbarItem.test.tsx +0 -0
  84. package/src/{Snackbar → Notifications/Snackbar}/SnackbarItem/SnackbarItem.tsx +5 -6
  85. package/src/{Snackbar → Notifications/Snackbar}/SnackbarProvider/SnackbarProvider.test.tsx +0 -0
  86. package/src/{Snackbar → Notifications/Snackbar}/SnackbarProvider/SnackbarProvider.tsx +2 -2
  87. package/src/{Snackbar → Notifications/Snackbar}/SnackbarProvider/SnackbarStateProvider.tsx +0 -0
  88. package/src/{Snackbar → Notifications/Snackbar}/interfaces.ts +0 -0
  89. package/src/{Snackbar → Notifications/Snackbar}/useSnackbar.ts +0 -0
  90. package/src/Popover/Popover.test.tsx +3 -3
  91. package/src/Tiles/Tile.module.scss +1 -1
  92. package/src/Tiles/Tile.test.tsx +21 -11
  93. package/src/Tiles/Tile.tsx +52 -15
  94. package/src/Tiles/Tiles.test.tsx +11 -9
  95. package/src/Tiles/Tiles.tsx +3 -3
  96. package/src/Wizard/BaseWizardSteps/BaseWizardSteps.tsx +3 -3
  97. package/src/Wizard/Wizard.tsx +2 -2
  98. package/src/Wizard/WizardActions/WizardActions.tsx +3 -3
  99. package/src/hooks/usePosition.test.tsx +3 -3
  100. package/src/index.ts +8 -7
@@ -1 +1 @@
1
- {"version":3,"file":"react-lib-components.cjs.production.min.js","sources":["../node_modules/rollup-plugin-styles/dist/runtime/inject-css.js","../src/hooks/useSpacing.ts","../src/Typography/Typography.tsx","../src/Button/BaseButton.tsx","../src/Button/Button.tsx","../src/Link/Link.tsx","../src/Button/IconButton.tsx","../src/Icon/Icon.tsx","../src/BaseModal/BaseModalContext.ts","../src/BaseModal/BaseModal.tsx","../src/BaseModal/BaseModalContent/BaseModalContent.tsx","../src/BaseModal/BaseModalActions/BaseModalActions.tsx","../src/Dialog/DialogActions/DialogActions.tsx","../src/Dialog/DialogTitle/DialogTitle.tsx","../src/util/helper.tsx","../src/hooks/usePosition.ts","../src/Tooltip/Tooltip.tsx","../src/Tiles/Tile.tsx","../src/Popover/Popover.tsx","../src/hooks/useBodyClick.ts","../src/Snackbar/SnackbarProvider/SnackbarStateProvider.tsx","../src/Snackbar/SnackbarContainer/SnackbarContainer.tsx","../src/hooks/useAnimation.ts","../src/Snackbar/SnackbarItem/SnackbarItem.tsx","../src/Form/Fieldset/Fieldset.tsx","../src/Form/FormHelperText/FormHelperText.tsx","../src/Form/FormGroup/FormGroup.tsx","../src/Form/Label/Label.tsx","../src/Form/Input/Input.tsx","../src/Form/Select/Select.tsx","../src/hooks/useScroll.ts","../src/Form/Textarea/Textarea.tsx","../src/hooks/useWrapper.ts","../src/Form/Wrapper/Wrapper/Wrapper.tsx","../src/hooks/useFormSelector.ts","../src/Form/FormSelectorWrapper/FormSelectorWrapper.tsx","../src/Form/Checkbox/Checkbox.tsx","../src/Wizard/BaseWizardSteps/BaseWizardSteps.tsx","../src/Wizard/wizardStateReducer.ts","../src/Wizard/WizardStateProvider.tsx","../src/Wizard/Wizard.tsx","../src/_BaseStyling_/BaseStyling.tsx","../src/Breadcrumbs/Breadcrumbs.tsx","../src/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.tsx","../src/ContextMenu/ContextMenu.tsx","../src/ContextMenu/ContextMenuItem.tsx","../src/Dialog/Dialog.tsx","../src/Form/Form.tsx","../src/Form/FormControl/FormControl.tsx","../src/Form/Wrapper/InputWrapper/InputWrapper.tsx","../src/BaseModal/BaseModalHeader/BaseModalHeader.tsx","../src/Form/Select/Option.tsx","../src/Form/Radio/Radio.tsx","../src/Form/Wrapper/RadioWrapper/RadioWrapper.tsx","../src/Form/Wrapper/SelectWrapper/SelectWrapper.tsx","../src/Snackbar/SnackbarProvider/SnackbarProvider.tsx","../src/Form/Wrapper/TextareaWrapper/TextareaWrapper.tsx","../src/Tiles/Tiles.tsx","../src/Wizard/WizardActions/WizardActions.tsx","../src/Wizard/WizardSteps/WizardSteps.tsx","../src/Snackbar/useSnackbar.ts"],"sourcesContent":["var e=[],t=[];function n(n,r){if(n&&\"undefined\"!=typeof document){var a,s=!0===r.prepend?\"prepend\":\"append\",d=!0===r.singleTag,i=\"string\"==typeof r.container?document.querySelector(r.container):document.getElementsByTagName(\"head\")[0];if(d){var u=e.indexOf(i);-1===u&&(u=e.push(i)-1,t[u]={}),a=t[u]&&t[u][s]?t[u][s]:t[u][s]=c()}else a=c();65279===n.charCodeAt(0)&&(n=n.substring(1)),a.styleSheet?a.styleSheet.cssText+=n:a.appendChild(document.createTextNode(n))}function c(){var e=document.createElement(\"style\");if(e.setAttribute(\"type\",\"text/css\"),r.attributes)for(var t=Object.keys(r.attributes),n=0;n<t.length;n++)e.setAttribute(t[n],r.attributes[t[n]]);var a=\"prepend\"===s?\"afterbegin\":\"beforeend\";return i.insertAdjacentElement(a,e),e}}export{n as default};\n","import { CSSProperties } from 'react';\n\ntype SpacingMultiplier = 0 | 0.5 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8;\ntype SpacingMultiplierStringOrNumber = `${SpacingMultiplier}` | SpacingMultiplier;\ntype MultiValueSpacingMultiplier =\n | `${SpacingMultiplier} ${SpacingMultiplier} ${SpacingMultiplier} ${SpacingMultiplier}`\n | `${SpacingMultiplier} ${SpacingMultiplier} ${SpacingMultiplier}`\n | `${SpacingMultiplier} ${SpacingMultiplier}`\n | SpacingMultiplierStringOrNumber;\n\nexport interface Spacing {\n padding?: MultiValueSpacingMultiplier;\n paddingTop?: SpacingMultiplierStringOrNumber;\n paddingBottom?: SpacingMultiplierStringOrNumber;\n paddingLeft?: SpacingMultiplierStringOrNumber;\n paddingRight?: SpacingMultiplierStringOrNumber;\n margin?: MultiValueSpacingMultiplier;\n marginTop?: SpacingMultiplierStringOrNumber;\n marginBottom?: SpacingMultiplierStringOrNumber;\n marginLeft?: SpacingMultiplierStringOrNumber;\n marginRight?: SpacingMultiplierStringOrNumber;\n}\n\nconst defaultFactor = 0.25;\nconst defaultUnit = 'rem';\nconst spacingNumberRegex = /(\\d+\\.?\\d*)+/g;\n\nexport const useSpacing = (\n spacingProps?: Spacing,\n style?: CSSProperties\n): CSSProperties | undefined => {\n if (spacingProps) {\n return Object.entries(spacingProps).reduce<CSSProperties>((prev, [spacing, multiplier]) => {\n const matches = String(multiplier).matchAll(spacingNumberRegex);\n const cssSpacingValue = Array.from(matches)\n .map(([multiplierValue]) => `${Number(multiplierValue) * defaultFactor}${defaultUnit}`)\n .join(' ');\n return { ...prev, [spacing]: cssSpacingValue };\n }, style ?? {});\n }\n return style;\n};\n","import React, { HTMLAttributes, ReactNode } from 'react';\nimport classes from './Typography.module.scss';\nimport { Spacing, useSpacing } from '../hooks/useSpacing';\n\nconst validVariants = ['h1', 'h2', 'h3', 'h4', 'body', 'body-bold', 'sub-text', 'code'] as const;\nexport type Variant = typeof validVariants[number];\n\nexport interface Props extends HTMLAttributes<HTMLElement> {\n children: ReactNode;\n variant: Variant;\n tag?:\n | 'h1'\n | 'h2'\n | 'h3'\n | 'h4'\n | 'p'\n | 'div'\n | 'code'\n | 'span'\n | 'sup'\n | 'sub'\n | 'strong'\n | 'em'\n | 'small'\n | 'mark'\n | 'del'\n | 'ins'\n | 'blockquote';\n spacing?: Spacing;\n}\n\nexport const Typography = ({\n children,\n variant,\n tag,\n style,\n spacing,\n className = '',\n ...rest\n}: Props) => {\n if (!validVariants.includes(variant)) {\n throw new Error(\n `You entered an invalid variant. You can choose from: ${validVariants}, you entered: ${variant}`\n );\n }\n\n const styleWithSpacing = useSpacing(spacing, style);\n\n if (!tag) {\n switch (variant) {\n case 'h1':\n case 'h2':\n case 'h3':\n case 'h4':\n case 'code':\n tag = variant;\n break;\n case 'body':\n tag = 'p';\n break;\n case 'body-bold':\n tag = 'p';\n break;\n case 'sub-text':\n tag = 'span';\n break;\n default:\n tag = 'div';\n break;\n }\n }\n\n let TagName = tag;\n\n return (\n <TagName\n {...rest}\n style={styleWithSpacing}\n className={`${classes['typography_style_' + variant]} ${className}`}\n >\n {children}\n </TagName>\n );\n};\n","import React, { RefObject } from 'react';\nimport classes from './BaseButton.module.scss';\n\nexport interface Props extends Omit<React.HTMLProps<HTMLButtonElement>, 'ref'> {\n type?: 'submit' | 'button' | 'reset';\n disabled?: boolean;\n ref?: RefObject<HTMLButtonElement>;\n color?: 'primary' | 'secondary' | 'tertiary' | 'default';\n}\n\nexport const BaseButton = React.forwardRef<HTMLButtonElement, Props>(\n ({ children, type = 'button', className, ...rest }, ref) => {\n const validTypes = ['submit', 'button', 'reset'];\n\n if (!validTypes.includes(type))\n throw new Error(\n `You have entered an invalid button type. Expected 'submit', 'button' or 'reset' got ${type}`\n );\n\n return (\n <button\n {...rest}\n ref={ref}\n type={type}\n className={`${classes.button} ${className ? className : ''}`}\n >\n {children}\n </button>\n );\n }\n);\n","import React, { RefObject } from 'react';\nimport { BaseButton, Props as BaseButtonProps } from './BaseButton';\nimport classes from './Button.module.scss';\n\nexport interface Props extends Omit<BaseButtonProps, 'ref'> {\n startIcon?: React.ReactNode | false;\n endIcon?: React.ReactNode | false;\n children?: React.ReactNode;\n variant?: 'text' | 'fill' | 'outline';\n ref?: RefObject<HTMLButtonElement>;\n}\n\nexport const Button = React.forwardRef<HTMLButtonElement, Props>(\n (\n { children, variant = 'fill', color = 'primary', startIcon = false, endIcon = false, ...rest },\n ref\n ) => {\n const additionalClasses = [];\n\n if (startIcon || endIcon) {\n additionalClasses.push(classes['has-icon']);\n }\n\n if (startIcon) {\n additionalClasses.push(classes['start-icon']);\n }\n\n if (endIcon) {\n additionalClasses.push(classes['end-icon']);\n }\n\n return (\n <BaseButton\n {...rest}\n ref={ref}\n className={`${classes[color]} ${classes[variant]} ${additionalClasses.join(' ')}`}\n >\n {startIcon && <i>{startIcon}&nbsp;</i>}\n <span>{children}</span>\n {endIcon && <i>&nbsp;{endIcon}</i>}\n </BaseButton>\n );\n }\n);\n","import React, { ForwardRefExoticComponent, Ref, RefAttributes } from 'react';\nimport { HTMLProps } from '../interfaces';\nimport classes from './Link.module.scss';\nimport { LinkProps } from './types';\n\ntype AnchorType = 'external' | 'internal' | 'download';\n\nexport interface Props extends HTMLProps<HTMLAnchorElement> {\n children?: string;\n color?: 'primary' | 'secondary' | 'tertiary';\n type?: AnchorType;\n to: string;\n disabled?: boolean;\n component?: ForwardRefExoticComponent<LinkProps & RefAttributes<HTMLAnchorElement>>;\n ref?: Ref<HTMLAnchorElement>;\n}\n\nexport const Link = React.forwardRef(\n (\n {\n children,\n className,\n disabled = false,\n to,\n color = 'primary',\n type = 'internal',\n component,\n ...rest\n }: Props,\n ref: Ref<HTMLAnchorElement>\n ) => {\n const determineTarget = () => {\n if (rest.target) {\n return rest.target;\n }\n\n if (type === 'external') {\n return '_blank';\n }\n\n return '';\n };\n\n const classNames = [classes['link'], classes[color]];\n disabled && classNames.push(classes['disabled']);\n className && classNames.push(className);\n\n if (component) {\n return React.createElement(component, {\n ...rest,\n ref: ref,\n to: to,\n className: classNames.join(' '),\n 'aria-disabled': disabled,\n style: {\n ...rest.style,\n },\n children: children,\n });\n }\n\n return (\n <a\n {...rest}\n ref={ref}\n download={type === 'download'}\n rel={type === 'external' ? 'noopener noreferer' : undefined}\n href={!disabled ? to : undefined}\n className={classNames.join(' ')}\n aria-disabled={disabled}\n target={determineTarget()}\n style={{\n ...rest.style,\n }}\n >\n {children}\n </a>\n );\n }\n);\n","import React, { RefObject } from 'react';\nimport { BaseButton, Props as BaseButtonProps } from './BaseButton';\nimport classes from './IconButton.module.scss';\nimport readyclasses from '../readyclasses.module.scss';\n\nexport interface Props extends Omit<BaseButtonProps, 'ref'> {\n children?: React.ReactNode;\n iconSize?: 's' | 'm' | 'l';\n className?: string;\n title: string;\n ref?: RefObject<HTMLButtonElement>;\n}\n\nexport const IconButton = React.forwardRef<HTMLButtonElement, Props>(\n ({ children, color = 'primary', iconSize = 'm', title, ...rest }, ref) => {\n return (\n <BaseButton\n {...rest}\n ref={ref}\n className={`${classes['icon-button']} ${classes[color]} ${classes['button-' + iconSize]}`}\n >\n <>\n {children}\n <span className={readyclasses['sr-only']}>{title}</span>\n </>\n </BaseButton>\n );\n }\n);\n","import React from 'react';\nimport classes from './Icon.module.scss';\nimport { HTMLAttributes } from '../interfaces';\n\nexport enum Icons {\n Bell = 'bell',\n BellAlt = 'bell-alt',\n Bookmark = 'bookmark',\n BookmarkAlt = 'bookmark-alt',\n Build = 'build',\n Calendar = 'calendar',\n Change = 'change',\n Checkmark = 'checkmark',\n CheckmarkCircle = 'checkmark-circle',\n CheckmarkCircleAlt = 'checkmark-circle-alt',\n CheckmarkCircleBreakout = 'checkmark-circle-breakout',\n CheckmarkSquare = 'checkmark-square',\n ChevronUp = 'chevron-up',\n ChevronDown = 'chevron-down',\n ChevronLeft = 'chevron-left',\n ChevronRight = 'chevron-right',\n Circle = 'circle',\n Clock = 'clock',\n Copy = 'copy',\n Edit = 'edit',\n Ellipsis = 'ellipsis',\n EllipsisAlt = 'ellipsis-alt',\n Equal = 'equal',\n Eye = 'eye',\n Filter = 'filter',\n FilterAlt = 'filter-alt',\n FilterAltArrow = 'filter-alt-arrow',\n FilterAltTimes = 'filter-alt-times',\n Forbidden = 'forbidden',\n Fullscreen = 'fullscreen',\n FullscreenExit = 'fullscreen-exit',\n Gearwheel = 'gearwheel',\n Grid = 'grid',\n Hamburger = 'hamburger',\n Heart = 'heart',\n Image = 'image',\n InfoBell = 'info-bell',\n InfoCircle = 'info-circle',\n Link = 'link',\n MinusSquare = 'minus-square',\n NavigationFirst = 'navigation-first',\n NavigationLast = 'navigation-last',\n Plus = 'plus',\n Radio = 'radio',\n Refresh = 'refresh',\n Search = 'search',\n Share = 'share',\n Square = 'square',\n Star = 'star',\n StarAlt = 'star-alt',\n Times = 'times',\n TimesCircle = 'times-circle',\n TimesCircleAlt = 'times-circle-alt',\n TimesThin = 'times-thin',\n Trash = 'trash',\n TriangleDown = 'triangle-down',\n TriangleDownCircle = 'triangle-down-circle',\n TriangleLeft = 'triangle-left',\n TriangleRight = 'triangle-right',\n TriangleUp = 'triangle-up',\n Undo = 'undo',\n Warning = 'warning',\n}\n\ntype Tag = 'span' | 'div' | 'i';\n\nexport interface Props extends Omit<HTMLAttributes<HTMLOrSVGElement>, 'size'> {\n icon: Icons;\n color?: string;\n size?: string;\n tag?: Tag;\n}\n\nexport const Icon = React.forwardRef(\n ({ icon, color, className, style, size, tag = 'span', ...rest }: Props, ref) => {\n const Component = tag;\n\n return (\n <Component\n {...rest}\n ref={ref as React.LegacyRef<HTMLDivElement>}\n style={{ color: color, ...style, fontSize: size }}\n data-icon\n aria-hidden=\"true\"\n className={`${classes['icon']} ${classes['icon-' + icon]} ${className ? className : ''}`}\n />\n );\n }\n);\n","export const labelId = (id: string) => `${id}-label`;\nexport const descriptionId = (id: string) => `${id}-description`;\n","import React, { HTMLAttributes, useEffect, useRef } from 'react';\nimport classes from './BaseModal.module.scss';\nimport { labelId, descriptionId } from './BaseModalContext';\n\nconst SCROLL_PROPERTY_NAME = 'overflow';\nconst SCROLL_PROPERTY_VALUE = 'hidden';\n\nexport interface Props extends HTMLAttributes<HTMLDivElement> {\n id: string;\n children: React.ReactNode;\n open: boolean;\n onClose?: (event?: React.MouseEvent<HTMLElement>) => unknown;\n className?: string;\n containerClassName?: string;\n labelledby?: string;\n describedby?: string;\n disableEscapeKeyDown?: boolean;\n disableBackdrop?: boolean;\n zIndex?: number;\n}\n\nconst useBackdropOnCloseClick = (\n disableBackdrop: boolean,\n onClose?: (event?: React.MouseEvent<HTMLElement>) => unknown\n) => {\n const backdropRef = useRef<HTMLDivElement>(null);\n const onBackdropClick = () => onClose && onClose();\n\n useEffect(() => {\n !disableBackdrop && backdropRef.current?.addEventListener('click', onBackdropClick);\n return () => {\n !disableBackdrop && backdropRef.current?.removeEventListener('click', onBackdropClick);\n };\n }, []);\n\n return {\n backdropRef,\n };\n};\n\nexport const useSetBodyScroll = (open: boolean) => {\n const hideBodyScroll = () => {\n document.body.style[SCROLL_PROPERTY_NAME] = SCROLL_PROPERTY_VALUE;\n };\n\n const showBodyScroll = () => {\n const allModalsClosed =\n document.querySelectorAll('[role=dialog][data-hidden=false]').length === 0;\n if (allModalsClosed) {\n document.body.style.removeProperty(SCROLL_PROPERTY_NAME);\n }\n };\n\n useEffect(() => {\n if (open) {\n hideBodyScroll();\n } else {\n showBodyScroll();\n }\n }, [open]);\n};\n\nexport const BaseModal = ({\n id,\n children,\n open,\n onClose,\n className = '',\n containerClassName = '',\n labelledby,\n describedby,\n disableEscapeKeyDown = false,\n disableBackdrop = false,\n zIndex,\n ...restProps\n}: Props) => {\n const { backdropRef } = useBackdropOnCloseClick(disableBackdrop, onClose);\n useSetBodyScroll(open);\n\n const handleEscKeyPress = (event: React.KeyboardEvent<HTMLDivElement>) => {\n if (!disableEscapeKeyDown && event.key === 'Escape') {\n event.stopPropagation();\n onClose && onClose();\n }\n };\n\n return (\n <div\n {...restProps}\n id={id}\n className={`${classes['modal']} ${open && classes['visible']} ${className}`}\n role=\"dialog\"\n aria-modal=\"true\"\n aria-labelledby={labelledby || labelId(id)}\n aria-describedby={describedby || descriptionId(id)}\n aria-hidden={!open}\n tabIndex={-1}\n data-hidden={!open}\n onKeyDown={handleEscKeyPress}\n style={{ zIndex }}\n >\n <div ref={backdropRef} className={classes['backdrop']}></div>\n {open && (\n <div\n style={{ zIndex: zIndex && zIndex + 1 }}\n className={`${classes['container']} ${containerClassName}`}\n >\n {children}\n </div>\n )}\n </div>\n );\n};\n","import React, { HTMLAttributes, useEffect, useRef } from 'react';\nimport classes from './BaseModalContent.module.scss';\n\nexport interface Props extends HTMLAttributes<HTMLDivElement> {\n id?: string;\n children: React.ReactNode;\n className?: string;\n disableAutoFocus?: boolean;\n}\n\nexport const BaseModalContent = ({\n id,\n children,\n className = '',\n disableAutoFocus = false,\n ...restProps\n}: Props) => {\n const contentRef = useRef<HTMLDivElement>(null);\n useEffect(() => {\n !disableAutoFocus && contentRef.current?.focus();\n }, []);\n\n /**tabIndex is set to be able to do focus on that element which we need for catching keyDown events */\n return (\n <div\n {...restProps}\n ref={contentRef}\n id={id}\n className={`${classes['content']} ${className}`}\n tabIndex={-1}\n >\n {children}\n </div>\n );\n};\n","import React, { HTMLAttributes } from 'react';\nimport classes from './BaseModalActions.module.scss';\n\nexport interface Props extends HTMLAttributes<HTMLElement> {\n children?: React.ReactNode;\n}\n\nexport const BaseModalActions = ({ children, className = '', ...restProps }: Props) => {\n return (\n <footer {...restProps} className={`${classes['actions']} ${className}`}>\n {children}\n </footer>\n );\n};\n","import React from 'react';\nimport {\n BaseModalActions,\n Props as BaseModalActionsProps,\n} from '../../BaseModal/BaseModalActions/BaseModalActions';\nimport classes from './DialogActions.module.scss';\n\nexport interface Props extends BaseModalActionsProps {\n align: 'left' | 'right';\n}\n\nexport const DialogActions = ({ children, align, ...restProps }: Props) => {\n return (\n <BaseModalActions\n {...restProps}\n className={`${classes['actions']}${align === 'left' ? ' ' + classes['left'] : ''}`}\n >\n {children}\n </BaseModalActions>\n );\n};\n","import React from 'react';\nimport { Typography } from '../../Typography/Typography';\nimport classes from './DialogTitle.module.scss';\n\nexport interface Props {\n id: string;\n title: string;\n}\n\nexport const DialogTitle = ({ id, title }: Props) => {\n return (\n <header className={classes['header']}>\n <Typography id={id} className={classes['title']} tag=\"h1\" variant=\"h4\">\n {title}\n </Typography>\n </header>\n );\n};\n","export const generateID = (length = 15, stringToWeaveIn?: string) => {\n /** We will make sure to mesh the generate id and name property together to basically create a unique ID */\n let hashCharacters = [\n '1',\n '2',\n '3',\n '4',\n '5',\n '6',\n '7',\n '8',\n '9',\n '0',\n 'A',\n 'B',\n 'C',\n 'D',\n 'E',\n 'F',\n 'G',\n 'H',\n 'I',\n 'J',\n 'K',\n 'L',\n 'M',\n 'N',\n 'O',\n 'P',\n 'Q',\n 'R',\n 'S',\n 'T',\n 'U',\n 'V',\n 'W',\n 'X',\n 'Y',\n 'Z',\n 'a',\n 'b',\n 'c',\n 'd',\n 'e',\n 'f',\n 'g',\n 'h',\n 'i',\n 'j',\n 'k',\n 'l',\n 'm',\n 'n',\n 'o',\n 'p',\n 'q',\n 'r',\n 's',\n 't',\n 'u',\n 'v',\n 'w',\n 'x',\n 'y',\n 'z',\n ];\n\n let id = '';\n\n /** Generate an id of x characters in length */\n for (let i = 0; i < length && id.length < length; i++) {\n let stringCharacter =\n stringToWeaveIn && stringToWeaveIn[i] !== undefined && !/\\s/.test(stringToWeaveIn[i])\n ? stringToWeaveIn[i]\n : '';\n id = id + stringCharacter + hashCharacters[Math.floor(Math.random() * hashCharacters.length)];\n }\n\n return id.slice(0, length);\n};\n","import React, { useState } from 'react';\n\nexport interface ConfigObject {\n relativeElement: RefElement;\n elementToBePositioned: RefElement;\n transformOrigin?: Placement;\n placement?: Placement;\n offset?: Offset;\n}\n\nexport type HorizontalPlacment = 'left' | 'center' | 'centerh' | 'right';\nexport type VerticalPlacement = 'top' | 'center' | 'centerv' | 'bottom';\n\ntype Axis = 'vertical' | 'horizontal';\ntype RefElement = React.RefObject<HTMLOrSVGElement> | undefined;\n\ninterface DomRectObject {\n top: number;\n right: number;\n bottom: number;\n left: number;\n center: number;\n centerh: number;\n centerv: number;\n width: number;\n height: number;\n x: number;\n y: number;\n}\n\nexport interface Placement {\n horizontal: HorizontalPlacment;\n vertical: VerticalPlacement;\n}\n\nexport interface Offset {\n top: number;\n right: number;\n bottom: number;\n left: number;\n}\n\nexport interface Position {\n top: PositionType;\n right: PositionType;\n bottom: PositionType;\n left: PositionType;\n}\n\ninterface Dimensions {\n height: number;\n width: number;\n}\n\ntype PositionType = number | 'initial';\n\nconst defaultConfigObject: ConfigObject = {\n relativeElement: undefined,\n elementToBePositioned: undefined,\n transformOrigin: {\n horizontal: 'left',\n vertical: 'top',\n },\n placement: {\n horizontal: 'left',\n vertical: 'top',\n },\n offset: {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0,\n },\n};\n\nexport const usePosition = (providedConfigObject: ConfigObject = defaultConfigObject) => {\n const configObject = { ...defaultConfigObject, ...providedConfigObject };\n\n if (configObject.transformOrigin === undefined) {\n configObject.transformOrigin = defaultConfigObject.transformOrigin;\n }\n\n if (configObject.placement === undefined) {\n configObject.placement = defaultConfigObject.placement;\n }\n\n if (configObject.offset === undefined) {\n configObject.offset = defaultConfigObject.offset;\n }\n\n const [position, setPosition] = useState<Position>({\n left: 0,\n top: 0,\n right: 'initial',\n bottom: 'initial',\n });\n\n const _fixPossibleViewportOverflow = (\n value: number,\n transformOrigin: Placement,\n requestedReturnValue: Axis,\n elDimensions: Dimensions\n ) => {\n let returnValue = value;\n\n if (\n (transformOrigin[requestedReturnValue] === 'left' && returnValue < 0) ||\n (transformOrigin[requestedReturnValue] === 'top' && returnValue < 0) ||\n (transformOrigin[requestedReturnValue] === 'center' && returnValue < 0) ||\n (transformOrigin[requestedReturnValue] === 'bottom' && returnValue < 0)\n ) {\n returnValue = 0;\n }\n\n if (\n (transformOrigin[requestedReturnValue] === 'left' &&\n returnValue > window.innerWidth - elDimensions.width) ||\n (transformOrigin[requestedReturnValue] === 'center' &&\n requestedReturnValue === 'horizontal' &&\n returnValue > window.innerWidth - elDimensions.width)\n ) {\n returnValue = window.innerWidth - elDimensions.width;\n }\n\n if (\n (transformOrigin[requestedReturnValue] === 'top' &&\n returnValue > window.innerHeight - elDimensions.height) ||\n (transformOrigin[requestedReturnValue] === 'center' &&\n requestedReturnValue === 'vertical' &&\n returnValue > window.innerHeight - elDimensions.height)\n ) {\n returnValue = window.innerHeight - elDimensions.height;\n }\n\n if (\n transformOrigin[requestedReturnValue] === 'right' &&\n returnValue > window.innerWidth - elDimensions.width\n ) {\n returnValue = window.innerWidth - elDimensions.width;\n }\n\n if (\n transformOrigin[requestedReturnValue] === 'bottom' &&\n returnValue > window.innerHeight - elDimensions.height\n ) {\n returnValue = window.innerHeight - elDimensions.height;\n }\n\n return returnValue;\n };\n\n const _applyOffsetToPlacementValue = (\n value: number,\n requestedReturnValue: Axis,\n transformOrigin: Placement\n ) => {\n let returnValue = value;\n if (\n (requestedReturnValue === 'horizontal' && configObject.offset?.left !== 0) ||\n (requestedReturnValue === 'horizontal' && configObject.offset?.right !== 0)\n ) {\n if (\n transformOrigin[requestedReturnValue] === 'left' ||\n transformOrigin[requestedReturnValue] === 'center'\n ) {\n returnValue += configObject.offset?.left!;\n returnValue -= configObject.offset?.right!;\n }\n\n if (transformOrigin[requestedReturnValue] === 'right') {\n returnValue -= configObject.offset?.left!;\n returnValue += configObject.offset?.right!;\n }\n }\n\n if (\n (requestedReturnValue === 'vertical' && configObject.offset?.top !== 0) ||\n (requestedReturnValue === 'vertical' && configObject.offset?.bottom !== 0)\n ) {\n if (\n transformOrigin[requestedReturnValue] === 'top' ||\n transformOrigin[requestedReturnValue] === 'center'\n ) {\n returnValue += configObject.offset?.top!;\n returnValue -= configObject.offset?.bottom!;\n }\n\n if (transformOrigin[requestedReturnValue] === 'bottom') {\n returnValue -= configObject.offset?.top!;\n returnValue += configObject.offset?.bottom!;\n }\n }\n\n return returnValue;\n };\n\n const _calculateInitialPlacementValue = (\n transformOrigin: Placement,\n requestedReturnValue: Axis,\n relEl: DomRectObject,\n placementOriginDefinition: HorizontalPlacment | VerticalPlacement,\n elDimensions: Dimensions\n ) => {\n let value = 0;\n\n if (\n transformOrigin[requestedReturnValue] === 'left' ||\n transformOrigin[requestedReturnValue] === 'top'\n ) {\n value = relEl[placementOriginDefinition];\n } else if (transformOrigin[requestedReturnValue] === 'center') {\n value =\n relEl[placementOriginDefinition] -\n elDimensions[requestedReturnValue === 'horizontal' ? 'width' : 'height'] / 2;\n } else if (\n transformOrigin[requestedReturnValue] === 'right' ||\n transformOrigin[requestedReturnValue] === 'bottom'\n ) {\n value =\n window[requestedReturnValue === 'horizontal' ? 'innerWidth' : 'innerHeight'] -\n relEl[placementOriginDefinition];\n }\n\n return value;\n };\n\n /**\n *\n * @param requestedReturnValue whether the requested return value is for the horizontal or vertical axis\n * @returns either the horizontally centered placement definition (centerh) or the vertically centered one (centerv)\n */\n const _determineCenteredPlacementOrigin = (requestedReturnValue: Axis) => {\n if (requestedReturnValue === 'horizontal') {\n return 'centerh';\n } else if (requestedReturnValue === 'vertical') {\n return 'centerv';\n }\n throw new Error(\n `the requested return value isn\\'t \"vertical\" or \"horizontal\" ${requestedReturnValue} was given.`\n );\n };\n\n const _calculatePlacementValue = (\n transformOrigin: Placement,\n placement: HorizontalPlacment | VerticalPlacement,\n requestedReturnValue: Axis,\n relEl: DomRectObject,\n elDimensions: Dimensions\n ): number => {\n const placementOriginDefinition =\n placement === 'center' ? _determineCenteredPlacementOrigin(requestedReturnValue) : placement;\n\n const value = _calculateInitialPlacementValue(\n transformOrigin,\n requestedReturnValue,\n relEl,\n placementOriginDefinition,\n elDimensions\n );\n\n const valueWithOffset = _applyOffsetToPlacementValue(\n value,\n requestedReturnValue,\n transformOrigin\n );\n\n const valueCorrectionForViewportOverflow = _fixPossibleViewportOverflow(\n valueWithOffset,\n transformOrigin,\n requestedReturnValue,\n elDimensions\n );\n\n return valueCorrectionForViewportOverflow;\n };\n\n const _calculatePlacement = (relEl: DomRectObject, elDimensions: Dimensions, axis: Axis) => {\n const placementValue = _calculatePlacementValue(\n configObject.transformOrigin!,\n configObject.placement![axis]!,\n axis,\n relEl,\n elDimensions\n );\n\n let direction = 'left';\n let oppositeDirection = 'right';\n\n if (axis === 'horizontal' && configObject.transformOrigin?.horizontal === 'right') {\n direction = 'right';\n oppositeDirection = 'left';\n } else if (axis === 'horizontal') {\n direction = 'left';\n oppositeDirection = 'right';\n }\n\n if (axis === 'vertical' && configObject.transformOrigin?.vertical === 'bottom') {\n direction = 'bottom';\n oppositeDirection = 'top';\n } else if (axis === 'vertical') {\n direction = 'top';\n oppositeDirection = 'bottom';\n }\n\n setPosition((prevState) => ({\n ...prevState,\n [direction]: placementValue,\n [oppositeDirection]: 'initial',\n }));\n };\n\n const calculatePosition = () => {\n if (!configObject.relativeElement?.current) return;\n const relativeElRect = (configObject.relativeElement!\n .current as HTMLElement)!.getBoundingClientRect();\n const elementToBePositionedDimensions: Dimensions = {\n height: (configObject.elementToBePositioned!.current as HTMLElement).offsetHeight,\n width: (configObject.elementToBePositioned!.current as HTMLElement).offsetWidth,\n };\n\n /** We want to add a center (horizontal and vertical) property to the DOMRect object. Since it's a special object we can't modify so we clone it and add it. */\n const clonedRelEl = {\n top: relativeElRect.top,\n right: relativeElRect.right,\n bottom: relativeElRect.bottom,\n center: 0,\n centerv: relativeElRect.top + relativeElRect.height / 2,\n centerh: relativeElRect.left + relativeElRect.width / 2,\n left: relativeElRect.left,\n width: relativeElRect.width,\n height: relativeElRect.height,\n x: relativeElRect.x,\n y: relativeElRect.y,\n };\n\n _calculatePlacement(clonedRelEl, elementToBePositionedDimensions, 'horizontal');\n _calculatePlacement(clonedRelEl, elementToBePositionedDimensions, 'vertical');\n };\n\n return {\n top: position.top,\n bottom: position.bottom,\n left: position.left,\n right: position.right,\n calculatePosition,\n };\n};\n","import React, { HTMLProps, ReactNode, useEffect, useLayoutEffect, useRef, useState } from 'react';\nimport { Icon, Icons } from '../Icon/Icon';\nimport classes from './Tooltip.module.scss';\nimport { generateID } from '../util/helper';\nimport { Offset, Placement, usePosition } from '../hooks/usePosition';\nimport { createPortal } from 'react-dom';\n\nexport interface Props extends Omit<HTMLProps<HTMLDivElement>, 'label'> {\n label: string | ReactNode;\n children: string;\n placement?: Placement;\n offset?: Offset;\n transformOrigin?: Placement;\n domRoot?: HTMLElement;\n}\n\ninterface DefaultPosition {\n placement: Placement;\n offset: Offset;\n transformOrigin: Placement;\n}\n\nconst defaultPosition: DefaultPosition = {\n placement: { horizontal: 'right', vertical: 'center' },\n offset: { left: 16, right: 0, top: 0, bottom: 0 },\n transformOrigin: { horizontal: 'left', vertical: 'center' },\n};\n\nexport const Tooltip = ({\n children,\n className,\n placement = defaultPosition.placement,\n offset = defaultPosition.offset,\n transformOrigin = defaultPosition.transformOrigin,\n domRoot = document.body,\n label,\n ...rest\n}: Props) => {\n const [identifier] = useState(generateID());\n const [visible, setVisible] = useState(false);\n\n const relativeElement = useRef<HTMLOrSVGElement>(null);\n const elementToBePositioned = useRef<HTMLDivElement>(null);\n\n const { top, bottom, right, left, calculatePosition } = usePosition({\n relativeElement: relativeElement,\n elementToBePositioned: elementToBePositioned,\n placement: placement,\n offset: offset,\n transformOrigin: transformOrigin,\n });\n\n useEffect(() => {\n if (!visible) return;\n\n function escapePressHandler(event: KeyboardEvent) {\n if (event.key === 'Escape') {\n setVisible(false);\n }\n }\n\n document.addEventListener('keyup', escapePressHandler);\n\n return () => {\n document.removeEventListener('keyup', escapePressHandler);\n };\n }, [visible]);\n\n useLayoutEffect(() => {\n calculatePosition();\n }, [visible]);\n\n const renderChildren = () => {\n if (React.isValidElement(label)) {\n return React.cloneElement(label, {\n onFocus: () => setVisible(true),\n onBlur: () => setVisible(false),\n 'aria-describedby': identifier,\n tabIndex: 0,\n className: classes['label'],\n });\n }\n\n return (\n <span\n className={classes['label']}\n tabIndex={0}\n onFocus={() => setVisible(true)}\n onBlur={() => setVisible(false)}\n aria-describedby={identifier}\n >\n {label}\n </span>\n );\n };\n\n return (\n <div {...rest} className={`${classes.wrapper} ${className ?? ''}`}>\n {renderChildren()}\n <div className={`${classes['tooltip-wrapper']}`}>\n <Icon\n ref={relativeElement}\n tag=\"div\"\n onMouseEnter={() => setVisible(true)}\n onMouseLeave={() => setVisible(false)}\n icon={Icons.InfoCircle}\n className={classes.icon}\n />\n {createPortal(\n <div\n ref={elementToBePositioned}\n style={{\n ...rest.style,\n top: top,\n left: left,\n right: right,\n bottom: bottom,\n }}\n aria-hidden={!visible}\n id={identifier}\n className={`${classes.tooltip} ${visible ? classes.visible : ''}`}\n >\n {children}\n </div>,\n domRoot\n )}\n </div>\n </div>\n );\n};\n","import React, { HTMLProps, ReactElement } from 'react';\nimport { Icon, Icons, Props as IconProps } from '../Icon/Icon';\nimport classes from './Tile.module.scss';\n\nimport { Props as ContextMenuProps } from '../ContextMenu/ContextMenu';\n\ninterface ImageProps {\n src: string;\n alt: string;\n}\n\nexport interface Props extends Omit<HTMLProps<HTMLDivElement>, 'contextMenu'> {\n title: string;\n imageProps?: ImageProps;\n iconProps?: IconProps;\n loading?: boolean;\n menu?: ReactElement<ContextMenuProps>;\n}\n\nexport const Tile = ({\n title,\n imageProps,\n iconProps,\n className,\n loading,\n menu,\n ...rest\n}: Props) => {\n if (!title) {\n throw new Error('Please make sure to pass a title prop to your Tile component.');\n }\n\n return (\n <div {...rest} className={`${classes['tile']} ${loading ? classes['loading'] : ''}`}>\n <header>\n {iconProps && <Icon {...iconProps} className={`${classes['icon']} ${className ?? ''}`} />}\n {menu ?? null}\n </header>\n <div className={classes['content']}>\n {imageProps && imageProps.src && imageProps.alt && (\n <figure className={classes['image']}>{!loading && <img {...imageProps} />}</figure>\n )}\n {!imageProps && <Icon className={classes['placeholder']} icon={Icons.Image} />}\n <span className={classes['title']}>{title}</span>\n </div>\n </div>\n );\n};\n","import React, { forwardRef, HTMLProps, ReactNode, RefObject, useEffect, useRef } from 'react';\nimport { usePosition, Offset, Placement } from '../hooks/usePosition';\nimport classes from './Popover.module.scss';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n children?: ReactNode;\n show?: boolean;\n anchorEl?: RefObject<HTMLOrSVGElement>;\n placement?: Placement;\n offset?: Offset;\n transformOrigin?: Placement;\n}\n\nexport const Popover = forwardRef<HTMLDivElement, Props>(\n ({ children, className, show, placement, offset, transformOrigin, anchorEl, ...rest }, ref) => {\n const elToBePositioned = useRef<HTMLDivElement>(null);\n\n if (show === undefined) {\n throw new Error('Please make sure to define the \"show\" property on your Popover component');\n }\n\n const { top, left, right, bottom, calculatePosition } = usePosition({\n elementToBePositioned: elToBePositioned,\n relativeElement: anchorEl,\n offset: offset,\n placement: placement,\n transformOrigin: transformOrigin,\n });\n\n useEffect(() => {\n calculatePosition();\n }, [show]);\n\n return (\n <div ref={ref} {...rest}>\n <div\n ref={elToBePositioned}\n className={`${classes.popover} ${className ?? ''} ${show ? classes.show : ''}`}\n style={{ top: top, left: left, right: right, bottom: bottom }}\n >\n {children}\n </div>\n </div>\n );\n }\n);\n","import { useEffect } from 'react';\n\nexport const useBodyClick = (\n checkFunction: (event: MouseEvent) => boolean,\n callbackFunction: (...args: unknown[]) => unknown,\n dependingStateVariable: React.ComponentState | React.ComponentState[]\n) => {\n function bodyClickListener(event: MouseEvent) {\n if (checkFunction(event)) {\n callbackFunction();\n }\n }\n useEffect(() => {\n window.addEventListener('click', bodyClickListener);\n\n return () => {\n window.removeEventListener('click', bodyClickListener);\n };\n }, [dependingStateVariable]);\n};\n","import React, { createContext } from 'react';\nimport { SnackbarOptionsProps } from '../interfaces';\n\ninterface SnackbarContextProps {\n enqueueSnackbar: (title: string, content?: string, options?: SnackbarOptionsProps) => void;\n enqueueSuccessSnackbar: (title: string, content?: string, options?: SnackbarOptionsProps) => void;\n enqueueErrorSnackbar: (title: string, content?: string, options?: SnackbarOptionsProps) => void;\n}\n\nconst SnackbarContext = createContext<SnackbarContextProps>({\n enqueueSnackbar: () => null,\n enqueueSuccessSnackbar: () => null,\n enqueueErrorSnackbar: () => null,\n});\n\ninterface Props {\n initialState: SnackbarContextProps;\n children?: React.ReactNode;\n}\n\nconst SnackbarContextProvider = ({ children, initialState }: Props) => {\n return <SnackbarContext.Provider value={initialState}>{children}</SnackbarContext.Provider>;\n};\n\nexport { SnackbarContextProvider, SnackbarContext, SnackbarContextProps };\n","import React from 'react';\nimport classes from './SnackbarContainer.module.scss';\n\nexport interface Placement {\n vertical: 'top' | 'bottom';\n horizontal: 'start' | 'center' | 'end';\n}\n\nexport interface Props {\n placement: Placement;\n children?: React.ReactNode;\n zIndex?: number;\n className?: string;\n}\n\nexport const SnackbarContainer = ({ placement, children, zIndex, className, ...rest }: Props) => {\n return (\n <div\n {...rest}\n style={{ zIndex }}\n className={`${classes['snackbars']} ${classes[placement.horizontal]} ${\n classes[placement.vertical]\n } ${className ?? ''}`}\n >\n {children}\n </div>\n );\n};\n","import { useEffect, useRef, useState } from 'react';\n\nexport const useAnimation = <RefElement extends HTMLElement>(callback: () => void) => {\n const animatedObjectRef = useRef<RefElement>(null);\n /** We need to store flag that says us when to call the callback */\n const [animationStarted, setAnimationStarted] = useState(false);\n\n const onAnimationEnd = () => animationStarted && callback();\n\n useEffect(() => {\n animatedObjectRef.current?.addEventListener('animationend', onAnimationEnd);\n return () => animatedObjectRef.current?.removeEventListener('animationend', onAnimationEnd);\n }, [animationStarted]);\n\n return {\n ref: animatedObjectRef,\n animationStarted,\n startAnimation: () => setAnimationStarted(true),\n };\n};\n","import React, { useEffect, useRef } from 'react';\nimport { IconButton } from '../../Button/IconButton';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { Variant, Actions } from '../interfaces';\nimport classes from './SnackbarItem.module.scss';\nimport readyclasses from '../../readyclasses.module.scss';\nimport { useAnimation } from '../../hooks/useAnimation';\nimport { Typography } from '../../Typography/Typography';\n\nconst textColor = 'var(--snackbar-text-color)';\n\nexport interface Props {\n id: string;\n title: string;\n duration: number;\n variant: Variant;\n onClose: (key: string) => void;\n closeButtonTitle: string;\n content?: string;\n actions?: Actions;\n}\n\nexport const SnackbarItem = ({\n id,\n title,\n duration,\n variant,\n content,\n actions = [],\n onClose,\n closeButtonTitle,\n}: Props) => {\n const timerHandler = useRef<ReturnType<typeof setTimeout>>();\n const onAnimationEnd = () => onClose(id);\n const { ref, animationStarted, startAnimation } = useAnimation<HTMLDivElement>(onAnimationEnd);\n\n useEffect(() => {\n timerHandler.current = setTimeout(() => startAnimation(), duration);\n return () => {\n timerHandler.current && clearTimeout(timerHandler.current);\n };\n }, []);\n\n const onMouseEnter = () => {\n timerHandler.current && clearTimeout(timerHandler.current);\n };\n\n const onMouseLeave = () => {\n timerHandler.current = setTimeout(() => startAnimation(), duration);\n };\n\n const getVariantIcon = () => {\n if (variant === 'error') {\n return Icons.TimesCircleAlt;\n }\n return variant === 'success' ? Icons.CheckmarkCircleBreakout : Icons.InfoCircle;\n };\n\n const actionButtons = actions.map((actionProp, index) => (\n <button\n key={index}\n {...actionProp}\n onClick={(e) => {\n onClose(id);\n actionProp.onClick && actionProp.onClick(e);\n }}\n children={actionProp.label}\n className={classes['action-button']}\n ></button>\n ));\n\n return (\n <div\n ref={ref}\n className={`${classes['snackbar']} ${classes[variant]} ${\n animationStarted ? readyclasses['slide-out'] : readyclasses['slide-in']\n }`}\n onMouseEnter={onMouseEnter}\n onMouseLeave={onMouseLeave}\n >\n <Icon icon={getVariantIcon()} className={classes['icon']} />\n <div className={classes['container']}>\n <div className={classes['headline']}>\n <Typography className={classes['title']} variant=\"h4\" tag=\"span\">\n {title}\n </Typography>\n <IconButton\n onClick={() => startAnimation()}\n className={classes['close-btn']}\n title={closeButtonTitle}\n >\n <Icon icon={Icons.Times} color={textColor} />\n </IconButton>\n </div>\n {/* @TODO: change it to Typography*/}\n {!!content && (\n <Typography className={classes['content']} variant=\"body\">\n {content}\n </Typography>\n )}\n {actionButtons.length > 0 && <div className={classes['actions']}>{actionButtons}</div>}\n </div>\n </div>\n );\n};\n","import React, { ReactElement } from 'react';\nimport readyclasses from '../../readyclasses.module.scss';\nimport classes from './Fieldset.module.scss';\nimport { HTMLProps } from '../../interfaces';\nimport { Typography, Variant } from '../../Typography/Typography';\n\nexport interface Props extends HTMLProps<HTMLFieldSetElement> {\n children?: ReactElement | ReactElement[];\n title: string;\n titleVariant?: Variant;\n hideTitle?: boolean;\n background?: string;\n noPadding?: boolean;\n noBackground?: boolean;\n}\n\nexport const Fieldset = ({\n children,\n className,\n title,\n titleVariant = 'body',\n hideTitle = false,\n noBackground,\n background = noBackground ? '' : '#FFF',\n noPadding = false,\n disabled = false,\n ...rest\n}: Props) => {\n const renderChildren = () => {\n if (!children) return;\n\n return React.Children.map(children, (child: ReactElement) =>\n React.cloneElement(child, {\n disabled: child.props.disabled !== undefined ? child.props.disabled : disabled,\n })\n );\n };\n\n return (\n <fieldset\n {...rest}\n disabled={disabled}\n style={{ backgroundColor: background, ...rest.style }}\n className={`${classes.fieldset} ${noPadding ? classes['no-padding'] : ''} ${className ?? ''}`}\n >\n {title && <legend className={readyclasses['sr-only']}>{title}</legend>}\n {title && !hideTitle && (\n <Typography variant={titleVariant} tag=\"span\" aria-hidden=\"true\" className={classes.title}>\n {title}\n </Typography>\n )}\n {renderChildren()}\n </fieldset>\n );\n};\n","import React, { ReactNode } from 'react';\nimport classes from './FormHelperText.module.scss';\nimport { HTMLProps } from '../../interfaces';\nimport { Typography } from '../../Typography/Typography';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n children?: ReactNode;\n error?: boolean;\n}\n\nexport const FormHelperText = ({ children, error, className, ...rest }: Props) => {\n return (\n <Typography\n {...rest}\n variant=\"sub-text\"\n tag=\"div\"\n className={`${classes['form-helper-text']} ${error ? classes.error : ''} ${className ?? ''}`}\n >\n {children}\n </Typography>\n );\n};\n","/** The empty className property on FormHelperText is on purpose! We want to basically \"filter\" out the className from helperProps because we're adding this to the surrounding div. This makes it so also the errormessage receives this styling. */\n\nimport React, { ReactChild } from 'react';\nimport classes from './FormGroup.module.scss';\nimport { FormHelperText, Props as HelperProps } from '../FormHelperText/FormHelperText';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { HTMLProps } from '../../interfaces';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n children: ReactChild[] | ReactChild;\n error?: boolean;\n errorMessageIcon?: Icons;\n errorMessageIconPosition?: 'before' | 'after';\n errorMessage?: string;\n errorId?: string;\n helperIndent?: number;\n helperText?: string;\n helperId?: string;\n helperProps?: HelperProps;\n}\n\nexport const FormGroup = ({\n children,\n className,\n error,\n errorMessage,\n errorId,\n errorMessageIcon,\n errorMessageIconPosition = 'before',\n helperText,\n helperId,\n helperProps,\n helperIndent,\n ...rest\n}: Props) => {\n return (\n <div\n {...rest}\n className={`${classes['form-group']} ${error ? classes.error : ''} ${className ?? ''}`}\n >\n {children}\n\n {(helperText || errorMessage) && (\n <div\n style={{ marginLeft: `${helperIndent}px` }}\n className={`${classes['default-helper']} ${\n helperProps?.className ? helperProps.className : ''\n }`}\n >\n {helperText && !error && (\n <FormHelperText {...helperProps} className={''} id={helperId}>\n {helperText}\n </FormHelperText>\n )}\n {error && errorMessage && (\n <span className={classes['error-message']}>\n <span className={classes.message} id={errorId}>\n {errorMessageIcon && errorMessageIconPosition === 'before' && (\n <Icon\n className={`${classes['error-icon']} ${classes['error-icon-before']}`}\n icon={errorMessageIcon}\n />\n )}\n {errorMessage}\n {errorMessageIcon && errorMessageIconPosition === 'after' && (\n <Icon\n className={`${classes['error-icon']} ${classes['error-icon-after']}`}\n icon={errorMessageIcon}\n />\n )}\n </span>\n </span>\n )}\n </div>\n )}\n </div>\n );\n};\n","import React from 'react';\nimport classes from './Label.module.scss';\nimport readyclasses from '../../readyclasses.module.scss';\nimport { HTMLProps } from '../../interfaces';\n\nexport interface Props extends HTMLProps<HTMLLabelElement> {\n children?: string;\n}\n\nexport const Label = ({ children, className, hidden = false, ...rest }: Props) => {\n return (\n <label\n {...rest}\n className={`${hidden ? readyclasses['sr-only'] : ''} ${classes['label']} ${className ?? ''}`}\n >\n {children}\n </label>\n );\n};\n","import React, { useEffect } from 'react';\nimport classes from './Input.module.scss';\nimport readyclasses from '../../readyclasses.module.scss';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { HTMLProps } from '../../interfaces';\n\nconst dateTypes = ['date', 'time', 'datetime-local'] as const;\n\nexport type Type =\n | 'text'\n | 'email'\n | 'file'\n | 'number'\n | 'password'\n | 'search'\n | 'tel'\n | 'url'\n | 'hidden'\n | typeof dateTypes[number];\n\nexport interface Props extends HTMLProps<HTMLInputElement> {\n wrapperProps?: HTMLProps<HTMLInputElement>;\n labeledBy?: string;\n type: Type;\n error?: boolean;\n}\n\nexport const Input = ({\n error = false,\n className,\n name,\n style,\n wrapperProps,\n type,\n labeledBy,\n ...rest\n}: Props) => {\n useEffect(() => {\n if (name === undefined) {\n throw new Error(\"Please give your <Input /> component a 'name' attribute\");\n }\n }, []);\n\n const inputClassNames = [classes['input']];\n error && inputClassNames.push(classes['error']);\n (dateTypes as ReadonlyArray<string>).includes(type) &&\n inputClassNames.push(classes['remove-extra-indent']);\n className && inputClassNames.push(className);\n\n const iconClassNames = [classes['warning']];\n (dateTypes as ReadonlyArray<string>).includes(type) &&\n iconClassNames.push(classes['extra-indent']);\n\n return (\n <div\n {...wrapperProps}\n style={{ ...style }}\n className={`${classes['input-wrapper']} ${wrapperProps?.className ?? ''} ${\n type === 'hidden' ? readyclasses['hidden'] : ''\n }`}\n >\n <input\n {...rest}\n aria-labelledby={labeledBy}\n type={type}\n name={name}\n className={inputClassNames.join(' ')}\n />\n {error && <Icon className={iconClassNames.join(' ')} icon={Icons.Warning} />}\n </div>\n );\n};\n","import classes from './Select.module.scss';\n\nimport React, {\n HTMLProps,\n ReactElement,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\nimport { Input } from '../Input/Input';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { FormElement } from '../form.interfaces';\nimport { useBodyClick } from '../../hooks/useBodyClick';\nimport { Position } from '../../hooks/usePosition';\nimport { useScroll } from '../../hooks/useScroll';\n\nexport interface Props extends FormElement<HTMLSelectElement> {\n children: ReactElement[];\n name?: string;\n labeledBy?: string;\n describedBy?: string;\n placeholder?: string;\n searchPlaceholder?: string;\n className?: string;\n value?: string;\n onChange?: (event: React.ChangeEvent<HTMLSelectElement>, child?: ReactElement) => void;\n onClear?: (event: React.MouseEvent<HTMLDivElement>) => void;\n}\n\nexport const Select = ({\n children,\n name,\n disabled = false,\n labeledBy,\n placeholder,\n describedBy,\n searchPlaceholder = 'Search item',\n className,\n error = false,\n value = '',\n onChange,\n onClear,\n ...rest\n}: Props) => {\n const [expanded, setExpanded] = useState(false);\n const [filter, setFilter] = useState('');\n const [display, setDisplay] = useState('');\n const [listPosition, setListPosition] = useState<Partial<Position>>({});\n const containerReference = useRef<HTMLDivElement>(null);\n const optionListReference = useRef<HTMLDivElement>(null);\n\n useBodyClick(\n (event: MouseEvent) => !(event.target as Element).closest('.custom-select') && expanded,\n () => {\n setExpanded(!expanded);\n },\n expanded\n );\n\n const rePositionList = () => {\n if (!expanded || !optionListReference.current || !containerReference.current) {\n return;\n }\n const windowHeight = window.innerHeight;\n const containerTopWithListHeight =\n containerReference.current.getBoundingClientRect().bottom -\n containerReference.current.getBoundingClientRect().height +\n optionListReference.current.getBoundingClientRect().height;\n\n if (containerTopWithListHeight > windowHeight) {\n setListPosition({ top: 'initial', bottom: 0 });\n } else {\n setListPosition({ top: 0, bottom: 'initial' });\n }\n };\n\n useScroll(rePositionList, [expanded]);\n\n useLayoutEffect(() => {\n rePositionList();\n }, [expanded]);\n\n const onOptionChangeHandler = (child: ReactElement) => (event: React.ChangeEvent) => {\n /**\n * We expose this to the outside inside of the onChange function as a parameter along with an optional second\n * parameter of the option that was clicked.\n */\n\n setDisplay(child.props.children);\n\n let newValue;\n let multiple = false; // Potential support for future multiple select. This should be a prop obviously.\n\n if (multiple) {\n /** We will implement the mulitple select in the next iteration */\n } else {\n newValue = child.props.value;\n }\n\n if (onChange) {\n // Redefine target to allow name and value to be read.\n // This allows seamless integration with the most popular form libraries.\n // Clone the event to not override `target` of the original event.\n // Don't know how to fix this any.. compiler whines that it can't construct it otherwise.\n const nativeEvent: any = event.nativeEvent || event;\n const clonedEvent = new nativeEvent.constructor(nativeEvent.type, nativeEvent);\n\n Object.defineProperty(clonedEvent as React.ChangeEvent<HTMLSelectElement>, 'target', {\n writable: true,\n value: { value: newValue },\n });\n\n onChange(clonedEvent as React.ChangeEvent<HTMLSelectElement>, child);\n }\n\n setDisplay((event.currentTarget as HTMLElement).innerText);\n setExpanded(false);\n };\n\n /**\n * @description We have to modify the children (Option component) to have a additional props that allows us to keep track of which one is selected at all times and if a filter is active.\n * The `children` prop can be either a single object (1 child) or an array of multiple children.\n */\n const renderOptions = () =>\n React.Children.map(children, (child) =>\n React.cloneElement(child, {\n onOptionSelect: onOptionChangeHandler(child),\n selected: child.props.value === value,\n filter: filter,\n })\n );\n\n const renderSearch = () => (\n <Input\n autoFocus\n onChange={filterResults}\n className={classes['select-search']}\n wrapperProps={{ className: classes['select-search-wrapper'] }}\n type=\"text\"\n name=\"search-option\"\n placeholder={searchPlaceholder}\n />\n );\n\n const filterResults = (event: React.ChangeEvent<HTMLInputElement>) => {\n setFilter(event.currentTarget.value);\n };\n\n const statusIcon = () => {\n if (error) {\n return <Icon className={classes['warning']} icon={Icons.Warning} />;\n }\n if (value.length !== 0 && onClear) {\n return <Icon tag=\"div\" icon={Icons.TimesThin} onClick={onClear} />;\n }\n return null;\n };\n\n /** Set initial display value */\n useEffect(() => {\n for (let child of children) {\n if (child.props.value === value) {\n setDisplay(child.props.children);\n }\n }\n }, []);\n\n const additionalClasses = [];\n expanded && additionalClasses.push(classes.expanded);\n error && additionalClasses.push(classes.error);\n disabled && additionalClasses.push(classes.disabled);\n\n return (\n <div\n {...(rest as HTMLProps<HTMLDivElement>)}\n ref={containerReference}\n className={`custom-select ${classes.select} ${additionalClasses.join(' ')} ${\n className ?? ''\n }`}\n >\n <button\n onClick={() => setExpanded(!expanded)}\n type=\"button\"\n name={name}\n disabled={disabled}\n aria-disabled={disabled}\n aria-invalid={error}\n aria-expanded={expanded}\n aria-haspopup=\"listbox\"\n aria-labelledby={labeledBy}\n aria-describedby={describedBy}\n >\n <div data-display className={classes['selected']}>\n {value.length === 0 && placeholder && (\n <span className={classes['placeholder']}>{placeholder}</span>\n )}\n {value.length > 0 && <span>{display}</span>}\n </div>\n <div className={classes['status']}>\n {statusIcon()}\n <Icon className={classes['triangle-down']} icon={Icons.TriangleDown} />\n </div>\n </button>\n <div\n ref={optionListReference}\n className={`list-wrapper ${classes['list-wrapper']}`}\n style={{ display: expanded ? 'block' : 'none', ...listPosition }}\n >\n {Array.isArray(children) && children.length > 10 && renderSearch()}\n <ul role=\"listbox\" tabIndex={-1}>\n {renderOptions()}\n </ul>\n </div>\n </div>\n );\n};\n","import React, { useLayoutEffect } from 'react';\n\nexport const useScroll = (\n callbackFunction: (event: Event) => unknown,\n dependingStateVariable: React.ComponentState[] = []\n) => {\n const scrollListener = (event: Event) => callbackFunction(event);\n\n useLayoutEffect(() => {\n window.addEventListener('scroll', scrollListener);\n\n return () => {\n window.removeEventListener('scroll', scrollListener);\n };\n }, [...dependingStateVariable]);\n};\n","import React from 'react';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { FormElement } from '../form.interfaces';\nimport classes from './Textarea.module.scss';\n\nexport interface Props extends FormElement<HTMLTextAreaElement> {\n wrapperClassName?: string;\n errorClassName?: string;\n}\n\nexport const Textarea = ({\n error = false,\n disabled = false,\n className,\n rows = 4,\n wrapperClassName,\n errorClassName,\n ...rest\n}: Props) => {\n return (\n <div className={`${classes['textarea-wrapper']} ${wrapperClassName ? wrapperClassName : ''}`}>\n <textarea\n {...rest}\n rows={rows}\n className={`${error ? classes['error'] : ''} ${classes['textarea']} ${className ?? ''}`}\n disabled={disabled}\n />\n {error && (\n <Icon className={`${classes['warning']} ${errorClassName ?? ''}`} icon={Icons.Warning} />\n )}\n </div>\n );\n};\n","import { useEffect, useState } from 'react';\nimport { generateID } from '../util/helper';\nimport { Type as InputTypes } from '../Form/Input/Input';\n\nexport const useWrapper = (value?: string, placeholder?: string, type?: InputTypes) => {\n const [helperId] = useState(generateID(20));\n const [errorId] = useState(generateID(20));\n const [labelId] = useState(generateID(20));\n const [floatingLabelActive, setFloatingLabelActive] = useState(false);\n const [hasFocus, setHasFocus] = useState(false);\n\n useEffect(() => {\n if (value?.length || placeholder || type === 'datetime-local' || type === 'time') {\n setFloatingLabelActive(true);\n }\n }, []);\n\n useEffect(() => {\n if (value?.length || hasFocus) {\n setFloatingLabelActive(true);\n } else if (!placeholder && !hasFocus && type !== 'datetime-local' && type !== 'time') {\n setFloatingLabelActive(false);\n }\n }, [value, placeholder, type, hasFocus]);\n\n return {\n helperId,\n errorId,\n labelId,\n floatingLabelActive,\n setFloatingLabelActive,\n hasFocus,\n setHasFocus,\n };\n};\n","import React, { ReactElement } from 'react';\nimport { FormGroup, Props as FormGroupProps } from '../../FormGroup/FormGroup';\nimport { Label, Props as LabelProps } from '../../Label/Label';\nimport classes from './Wrapper.module.scss';\nimport { Props as HelperProps } from '../../FormHelperText/FormHelperText';\nimport { HTMLProps } from '../../../interfaces';\n\nexport interface Props extends Omit<FormGroupProps, 'children'> {\n children: ReactElement | ReactElement[];\n floatingLabelActive?: boolean;\n floatingLabel?: boolean;\n helperIndent?: number;\n label?: string;\n labelProps?: LabelProps;\n name: string;\n /** This does NOT add validation! It simply adds an asterix on the Label! */\n required?: boolean;\n innerClassName?: string;\n}\n\n/** For components that extend this component we create an interface (InputWrapper, SelectWrapper, etc.) */\nexport interface WrapperProps extends HTMLProps<HTMLDivElement> {\n errorMessage?: string;\n error: boolean;\n helperText?: string;\n helperProps?: HelperProps;\n label?: string;\n name: string;\n required?: boolean;\n}\n\nexport const Wrapper = ({\n children,\n className,\n error,\n errorMessage,\n errorId,\n errorMessageIcon,\n errorMessageIconPosition,\n helperText,\n helperId,\n floatingLabel = true,\n floatingLabelActive,\n required,\n helperProps,\n helperIndent,\n labelProps,\n label,\n disabled,\n name,\n innerClassName,\n ...rest\n}: Props) => {\n const renderChildren = () =>\n React.Children.map(children, (child) =>\n React.cloneElement(child, {\n disabled,\n })\n );\n\n const labelClasses = [];\n\n floatingLabel && labelClasses.push(classes['floating-label']);\n floatingLabel && floatingLabelActive && labelClasses.push(classes['floating-label-active']);\n labelProps?.className && labelClasses.push(labelProps.className);\n required && labelClasses.push(classes['required']);\n error && labelClasses.push(classes['error']);\n\n return (\n <div {...rest} className={`${classes.wrapper} ${className ? className : ''}`}>\n <FormGroup\n error={error}\n errorMessage={errorMessage}\n errorId={errorId}\n errorMessageIcon={errorMessageIcon}\n errorMessageIconPosition={errorMessageIconPosition}\n helperText={helperText}\n helperId={helperId}\n helperProps={helperProps}\n helperIndent={helperIndent}\n >\n <div\n className={`${floatingLabel ? classes['floating-wrapper'] : ''} ${\n innerClassName ? innerClassName : ''\n }`}\n >\n {label && (\n <Label\n {...labelProps}\n className={`${classes.label} ${labelClasses.join(' ')}`}\n htmlFor={name}\n >\n {label}\n </Label>\n )}\n {renderChildren()}\n </div>\n </FormGroup>\n </div>\n );\n};\n","import { useEffect, useState } from 'react';\nimport { generateID } from '../util/helper';\n\nexport interface ConfigObject {\n name: string | undefined;\n errorMessage?: string;\n error?: boolean;\n parentErrorId?: string;\n helperText?: string;\n parentHelperId?: string;\n}\n\nexport const useFormSelector = (configObject: ConfigObject) => {\n const [identifier] = useState(generateID(15, configObject.name));\n const [describedBy, setDescribedBy] = useState('');\n const [errorId] = useState(generateID(15, configObject.errorMessage));\n\n useEffect(() => {\n if (configObject.error && configObject.parentErrorId) {\n setDescribedBy(configObject.parentErrorId);\n }\n\n if (\n (!configObject.error && configObject.helperText) ||\n (!configObject.parentErrorId && !configObject.errorMessage && configObject.helperText)\n ) {\n setDescribedBy(`${identifier}`);\n }\n\n if (\n (!configObject.error && !configObject.helperText && configObject.parentHelperId) ||\n (!configObject.parentErrorId && !configObject.errorMessage && configObject.parentHelperId)\n ) {\n setDescribedBy(`${configObject.parentHelperId}`);\n }\n\n if (configObject.errorMessage && !configObject.parentErrorId && configObject.error) {\n setDescribedBy(errorId);\n }\n }, [identifier, configObject.error, configObject.parentErrorId]);\n\n return {\n describedBy,\n errorId,\n identifier,\n };\n};\n","import React, { ReactNode } from 'react';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { HTMLProps } from '../../interfaces';\nimport { FormHelperText, Props as FormHelperTextProps } from '../FormHelperText/FormHelperText';\nimport classes from './FormSelectorWrapper.module.scss';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n children?: ReactNode;\n nestedChildren?: ReactNode;\n containerProps: HTMLProps<HTMLDivElement>;\n helperProps?: FormHelperTextProps;\n error?: boolean;\n disabled?: boolean;\n helperText?: string;\n errorMessage?: string;\n parentHelperId?: string;\n parentErrorId?: string;\n errorId: string;\n identifier: string;\n}\n\nexport const FormSelectorWrapper = ({\n children,\n className,\n nestedChildren,\n containerProps,\n helperProps,\n error,\n disabled,\n helperText,\n errorMessage,\n parentErrorId,\n errorId,\n identifier,\n ...rest\n}: Props) => {\n return (\n <div\n {...rest}\n className={`${error ? classes['error'] : ''} ${disabled ? classes['disabled'] : ''} ${\n className ?? ''\n }`}\n >\n <div {...containerProps}>{children}</div>\n {helperText && (!error || parentErrorId || !errorMessage) && (\n <FormHelperText\n {...helperProps}\n id={`${identifier}`}\n className={`${classes['helper-text']} ${helperProps?.className ?? ''} ${\n error ? classes['error'] : ''\n }`}\n >\n {helperText}\n </FormHelperText>\n )}\n {errorMessage && !parentErrorId && error && (\n <span className={classes['error-message']}>\n <Icon className={classes['error-icon']} icon={Icons.Warning} />\n <span id={errorId}>{errorMessage}</span>\n </span>\n )}\n {nestedChildren}\n </div>\n );\n};\n","import React, { ReactElement, ReactNode, useEffect } from 'react';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { Props as FormHelperTextProps } from '../FormHelperText/FormHelperText';\nimport classes from './Checkbox.module.scss';\nimport { useFormSelector } from '../../hooks/useFormSelector';\nimport { FormSelector } from '../form.interfaces';\nimport { HTMLProps } from '../../interfaces';\nimport { FormSelectorWrapper } from '../FormSelectorWrapper/FormSelectorWrapper';\n\nconst isToggle = (children: ReactNode) => (children as ReactElement)?.props?.['data-toggle'];\n\nexport interface CheckboxProps extends FormSelector<HTMLInputElement> {\n children: ReactNode;\n label?: string;\n indeterminate?: boolean;\n helperProps?: FormHelperTextProps;\n wrapperProps?: HTMLProps<HTMLDivElement>;\n onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;\n}\n\nexport const Checkbox = ({\n children,\n name,\n helperText,\n helperProps,\n indeterminate,\n parentErrorId,\n errorMessage,\n disabled,\n label,\n parentHelperId,\n className,\n error,\n checked = false,\n wrapperProps,\n onChange,\n ...rest\n}: CheckboxProps) => {\n const { errorId, identifier, describedBy } = useFormSelector({\n name,\n helperText,\n parentErrorId,\n errorMessage,\n error,\n parentHelperId,\n });\n\n useEffect(() => {\n if (!name) {\n console.error(\"Please pass a 'name' prop to your <Checkbox> component.\");\n }\n\n if (typeof children === 'object' && !isToggle(children) && indeterminate === undefined) {\n throw new Error(\n 'If you have nested checkboxes you have to manage the indeterminate state by passing a boolean to the `indeterminate` prop.'\n );\n }\n }, []);\n\n const determineLabel = () => {\n if (label) {\n return label;\n } else if (children === undefined) {\n throw new Error(\n 'Please make sure to pass either a string or more Checkbox components as a child of your Checkbox component.'\n );\n }\n\n if (typeof children === 'string') {\n return children;\n }\n\n throw new Error(\n 'If you pass Checkboxes as a child component (to create nested checkbox tree) you need to pass a label to the parent checkbox.'\n );\n };\n\n const renderNestedCheckboxes = () => (\n <ul className={classes['checkbox-list']}>\n {React.Children.map(children as ReactElement[], (child) => {\n return (\n <li>\n <Checkbox\n {...child.props}\n parentHelperId={parentHelperId}\n parentErrorId={parentErrorId}\n error={error}\n >\n {child.props.children}\n </Checkbox>\n </li>\n );\n })}\n </ul>\n );\n\n const onChangeHandler = (event: React.ChangeEvent<HTMLInputElement>) => {\n if (disabled) {\n return;\n }\n onChange && onChange(event);\n };\n\n const renderToggle = () => React.Children.toArray(children).filter(isToggle);\n\n /** Default return value is the default checkbox */\n return (\n <FormSelectorWrapper\n {...wrapperProps}\n className={`${classes['checkbox-wrapper']} ${className ? className : ''}`}\n containerProps={{ className: classes['checkbox-container'] }}\n helperText={helperText}\n helperProps={helperProps}\n parentErrorId={parentErrorId}\n errorId={errorId}\n errorMessage={errorMessage}\n error={error}\n disabled={disabled}\n identifier={identifier}\n nestedChildren={\n typeof children === 'object' && !isToggle(children) && renderNestedCheckboxes()\n }\n >\n <input\n {...rest}\n disabled={disabled}\n className={`${classes['native-input']} ${error ? classes['error'] : ''}`}\n checked={checked}\n onChange={onChangeHandler}\n aria-invalid={error as boolean}\n aria-checked={indeterminate ? 'mixed' : checked}\n aria-describedby={describedBy}\n id={`${identifier}-checkbox`}\n name={name}\n type=\"checkbox\"\n />\n {renderToggle()}\n\n {indeterminate && <Icon className={classes.input} icon={Icons.MinusSquare} />}\n {checked && !indeterminate && <Icon className={classes.input} icon={Icons.CheckmarkSquare} />}\n {!checked && !indeterminate && <Icon className={classes.input} icon={Icons.Square} />}\n <label htmlFor={`${identifier}-checkbox`}>{determineLabel()}</label>\n </FormSelectorWrapper>\n );\n};\n","import React from 'react';\nimport classes from './BaseWizardSteps.module.scss';\nimport readyclasses from '../../readyclasses.module.scss';\nimport { Icon, Icons } from '../../Icon/Icon';\n\ntype StepState = 'finished' | 'current' | 'future';\n\nexport interface Step {\n label: string;\n disabled?: boolean;\n}\n\nexport interface Props extends Omit<React.HTMLProps<HTMLDivElement>, 'onClick'> {\n steps: Step[];\n currentStepNo: number;\n onClick?: (stepNo: number) => void;\n futureStepsClickable?: boolean;\n stepScreenReaderLabel: string;\n}\n\nexport const BaseWizardSteps = ({\n steps,\n currentStepNo,\n onClick,\n futureStepsClickable = false,\n stepScreenReaderLabel,\n ...restProps\n}: Props) => {\n const getStepState = (stepNo: number): StepState => {\n if (currentStepNo === stepNo) {\n return 'current';\n } else if (stepNo < currentStepNo) {\n return 'finished';\n }\n return 'future';\n };\n\n const getStepContent = (stepState: StepState, index: number, disabled?: boolean) => {\n const stepNumberString = String(index + 1);\n if (stepState === 'finished') {\n return disabled ? null : <Icon className={classes['checkmark']} icon={Icons.Checkmark} />;\n } else {\n return (\n <>\n <span className={readyclasses['sr-only']}>{stepScreenReaderLabel} </span>\n {stepNumberString}\n </>\n );\n }\n };\n\n const generatedSteps = steps.map((step, index) => {\n const stepState = getStepState(index);\n const disabledStyleClassName = step.disabled ? classes['disabled'] : '';\n const clickableClassName = futureStepsClickable ? classes['clickable'] : '';\n\n return (\n <button\n key={step.label.toLowerCase().replace(/\\s/, '-')}\n disabled={\n step.disabled ||\n (stepState === 'future' && !futureStepsClickable) ||\n stepState === 'current'\n }\n aria-current={stepState === 'current' ? 'step' : undefined}\n onClick={() => onClick && onClick(index)}\n className={`${classes['wizard-element']} ${classes[stepState]} ${clickableClassName} ${disabledStyleClassName}`}\n >\n <div className={classes['number-wrapper']}>\n <span className={classes['number']}>\n {getStepContent(stepState, index, step.disabled)}\n </span>\n </div>\n <div className={classes['two-line-text-overflow']}>\n <span className={classes['label']}>{step.label}</span>\n </div>\n </button>\n );\n });\n\n return (\n <div {...restProps} className={classes['wizard']}>\n {generatedSteps}\n </div>\n );\n};\n","import { Reducer } from 'react';\nimport { Step } from './BaseWizardSteps/BaseWizardSteps';\nimport { WizardMode } from './Wizard';\n\ntype WizardStateType = {\n steps: Step[];\n currentStepNo: number;\n mode: WizardMode;\n stepScreenReaderLabel: string;\n};\n\ninterface SetWizardStateAction {\n type: 'SET_STATE';\n payload: {\n steps: Step[];\n mode: WizardMode;\n stepScreenReaderLabel: string;\n };\n}\n\ninterface ChangeCurrentStepNoAction {\n type: 'CHANGE_CURRENT_STEP_NO';\n payload: number;\n}\n\nconst setWizardState = (\n steps: Step[],\n mode: WizardMode,\n stepScreenReaderLabel: string\n): SetWizardStateAction => {\n return { type: 'SET_STATE', payload: { steps, mode, stepScreenReaderLabel } };\n};\n\nconst changeCurrentStepNo = (currentStepNo: number): ChangeCurrentStepNoAction => {\n return { type: 'CHANGE_CURRENT_STEP_NO', payload: currentStepNo };\n};\n\ntype WizardActions = SetWizardStateAction | ChangeCurrentStepNoAction;\n\nconst reducer: Reducer<WizardStateType, WizardActions> = (state, action) => {\n switch (action.type) {\n case 'SET_STATE':\n return { ...state, ...action.payload };\n case 'CHANGE_CURRENT_STEP_NO':\n return { ...state, currentStepNo: action.payload };\n default:\n return state;\n }\n};\n\nexport { setWizardState, changeCurrentStepNo, reducer, WizardActions, WizardStateType };\n","import React, { createContext, Dispatch, useReducer } from 'react';\nimport { WizardActions, WizardStateType, reducer } from './wizardStateReducer';\n\nconst WizardStateContext = createContext<{\n state: WizardStateType;\n dispatch: Dispatch<WizardActions>;\n}>({\n state: {} as WizardStateType,\n dispatch: () => null,\n});\n\nexport interface Props {\n initialState: WizardStateType;\n children?: React.ReactNode;\n}\n\nconst WizardStateProvider = ({ children, initialState }: Props) => {\n const [state, dispatch] = useReducer(reducer, initialState);\n return (\n <WizardStateContext.Provider value={{ state, dispatch }}>\n {children}\n </WizardStateContext.Provider>\n );\n};\n\nexport { WizardStateProvider, WizardStateContext };\n","import React, { useContext, useEffect } from 'react';\nimport { Step } from './BaseWizardSteps/BaseWizardSteps';\nimport { WizardStateContext, WizardStateProvider } from './WizardStateProvider';\nimport { setWizardState } from './wizardStateReducer';\n\nexport type WizardMode = 'add' | 'edit';\n\nexport interface Props {\n steps: Step[];\n mode: WizardMode;\n initialStepNo?: number;\n onStepChange: (stepNo: number) => void;\n stepScreenReaderLabel: string;\n children: React.ReactNode;\n}\n\nconst useSetWizardState = (steps: Step[], mode: WizardMode, stepScreenReaderLabel: string) => {\n const { dispatch } = useContext(WizardStateContext);\n\n useEffect(() => {\n dispatch(setWizardState(steps, mode, stepScreenReaderLabel));\n }, [steps, mode, stepScreenReaderLabel]);\n};\n\nconst useStepChanging = (onStepChange: (stepNo: number) => void) => {\n const {\n state: { currentStepNo },\n } = useContext(WizardStateContext);\n\n useEffect(() => {\n onStepChange(currentStepNo);\n }, [currentStepNo]);\n};\n\nconst WizardContent = ({ steps, mode, stepScreenReaderLabel, onStepChange, children }: Props) => {\n useSetWizardState(steps, mode, stepScreenReaderLabel);\n useStepChanging(onStepChange);\n\n return <>{children}</>;\n};\n\nexport const Wizard = (props: Props) => {\n const { steps, initialStepNo: currentStepNo = 0, mode, stepScreenReaderLabel } = props;\n return (\n <WizardStateProvider initialState={{ steps, currentStepNo, mode, stepScreenReaderLabel }}>\n <WizardContent {...props} />\n </WizardStateProvider>\n );\n};\n","import React, { Fragment, HTMLAttributes, ReactChild, useEffect, useState } from 'react';\n\ninterface CSSProperties {\n colorPrimary?: string;\n colorSecondary?: string;\n colorTertiary?: string;\n defaultLineHeight?: string;\n buttonBorderRadius?: string;\n buttonBorderWidth?: string;\n buttonFontSize?: string;\n buttonBorderStyle?: string;\n buttonFillTextColor?: string;\n buttonFillBackgroundColor?: string;\n buttonOutlineHoverTextColor?: string;\n inputBorderColor?: string;\n inputBorderRadius?: string;\n inputBorderWidth?: string;\n inputBorderStyle?: string;\n modalShadowColor?: string;\n modalBackgroundColor?: string;\n modalHeaderBackgroundColor?: string;\n snackbarTextColor?: string;\n snackbarInfoBackgroundColor?: string;\n snackbarSuccessBackgroundColor?: string;\n snackbarErrorBackgroundColor?: string;\n snackbarBorderRadius?: string;\n default?: string;\n success?: string;\n error?: string;\n disabled?: string;\n greyedOut?: string;\n warning?: string;\n fontFamily?: string;\n fontFamilyCode?: string;\n fontSize?: string;\n fontSizeH1?: string;\n fontSizeH2?: string;\n fontSizeH3?: string;\n fontSizeH4?: string;\n fontSizeSub?: string;\n fontSizeCode?: string;\n}\n\nexport interface Props extends HTMLAttributes<HTMLDivElement> {\n children?: ReactChild;\n properties?: CSSProperties;\n}\n\nexport const BaseStyling = ({ children, properties = {} }: Props) => {\n const defaultProperties: CSSProperties = {\n colorPrimary: '#9e006b',\n colorSecondary: '#003b5e',\n colorTertiary: '#ff1e4e',\n defaultLineHeight: '26px',\n buttonBorderRadius: '20px',\n buttonBorderWidth: '2px',\n buttonFontSize: '1rem',\n buttonBorderStyle: 'solid',\n buttonFillTextColor: '#FFF',\n buttonFillBackgroundColor: '#FFF',\n buttonOutlineHoverTextColor: '#FFF',\n inputBorderColor: '#e9e9eb',\n inputBorderRadius: '8px',\n inputBorderWidth: '1px',\n inputBorderStyle: 'solid',\n modalShadowColor: 'rgba(0, 0, 0, 0.16)',\n modalBackgroundColor: '#F5F8F8',\n modalHeaderBackgroundColor: '#FFF',\n snackbarTextColor: '#fff',\n snackbarInfoBackgroundColor: '#003b5e',\n snackbarSuccessBackgroundColor: '#008a28',\n snackbarErrorBackgroundColor: '#e22a1d',\n snackbarBorderRadius: '8px',\n default: '#0f0f1e',\n success: '#008a28',\n error: '#e22a1d',\n disabled: '#e9e9eb',\n greyedOut: '#6f6f76',\n warning: '#ff6105',\n fontFamily: \"'Red Hat Display', sans-serif\",\n fontFamilyCode: \"'Red Hat Mono', sans-serif\",\n fontSize: '1rem',\n fontSizeH1: '2.5rem',\n fontSizeH2: '1.625rem',\n fontSizeH3: '1.5rem',\n fontSizeH4: '1.25rem',\n fontSizeSub: '.75rem',\n fontSizeCode: '1rem',\n };\n\n /** We need a loading state, because otherwise you see the colors flash from the default to the possible overridden ones. */\n const [isLoading, setIsLoading] = useState(true);\n\n /** Set the actual CSS properties on the HTML :root object */\n const setCSSProperties = (CSSPropertiesObject: CSSProperties) => {\n for (const [key, value] of Object.entries(CSSPropertiesObject)) {\n const formattedPropertyName = key.replaceAll(/([A-Z])/g, (val) => `-${val.toLowerCase()}`);\n document.documentElement.style.setProperty(`--${formattedPropertyName}`, value);\n }\n };\n\n /** Check if the properties prop object is filled with anything. If it is, we want to shallow merge it with the default BaseStyling. */\n useEffect(() => {\n if (Object.keys(properties).length !== 0) {\n const mergedState = { ...defaultProperties, ...properties };\n setCSSProperties(mergedState);\n } else {\n setCSSProperties(defaultProperties);\n }\n setIsLoading(false);\n }, [properties]);\n\n /** Only render if we're not loading */\n return !isLoading ? <Fragment>{children}</Fragment> : null;\n};\n","import React, { Fragment, HTMLProps, ReactElement } from 'react';\nimport { Icon, Icons } from '../Icon/Icon';\nimport { Link, Props as LinkProps } from '../Link/Link';\nimport { Typography } from '../Typography/Typography';\nimport classes from './Breadcrumbs.module.scss';\n\ntype ChildrenType = ReactElement<LinkProps, typeof Link>;\n\nexport interface Props extends HTMLProps<HTMLElement> {\n children: ChildrenType | ChildrenType[];\n 'aria-label': string;\n}\n\nexport const Breadcrumbs = ({\n children,\n 'aria-label': ariaLabel,\n className = '',\n ...rest\n}: Props) => {\n const items = React.Children.map(children, (child, index) => {\n const isLastElement = Array.isArray(children) ? index === children.length - 1 : true;\n if (isLastElement) {\n return (\n <Typography\n key={child.key}\n variant=\"body\"\n tag=\"span\"\n className={classes['last']}\n aria-current=\"page\"\n >\n {child.props.children}\n </Typography>\n );\n } else {\n return (\n <Fragment key={child.key}>\n {React.cloneElement(child)}\n <Icon icon={Icons.ChevronRight} className={classes['icon']} />\n </Fragment>\n );\n }\n });\n return (\n <nav {...rest} aria-label={ariaLabel} className={`${classes['breadcrumbs']} ${className}`}>\n {items}\n </nav>\n );\n};\n","import React, { ReactElement, useEffect } from 'react';\nimport classes from './CheckboxWrapper.module.scss';\nimport { useWrapper } from '../../../hooks/useWrapper';\nimport { Wrapper, WrapperProps } from '../Wrapper/Wrapper';\nimport { Icons } from '../../../Icon/Icon';\nimport { Fieldset, Props as FieldsetProps } from '../../../Form/Fieldset/Fieldset';\n\nexport interface Props extends WrapperProps {\n children: ReactElement[] | ReactElement;\n fieldsetProps: FieldsetProps;\n}\n\nexport const CheckboxWrapper = ({\n children,\n error = false,\n helperText,\n helperProps,\n fieldsetProps,\n ...rest\n}: Props) => {\n const { errorId, helperId } = useWrapper();\n\n useEffect(() => {\n if (fieldsetProps.title === undefined) {\n console.error(\n `You should give your Fieldset component a title prop so a legend element is rendered. This error was thrown in CheckboxWrapper. You can add this title prop through the fieldsetProps prop by passing an object (fieldsetProps={{ title: \"title here\" }})`\n );\n }\n }, []);\n\n const renderChildren = () =>\n React.Children.map(children, (child) =>\n React.cloneElement(child, {\n parentErrorId: errorId,\n error: error,\n parentHelperId: helperText ? helperId : false,\n disabled: rest.disabled,\n })\n );\n\n return (\n <Fieldset {...fieldsetProps}>\n <Wrapper\n {...rest}\n label=\"\"\n helperId={helperId}\n helperText={helperText}\n helperProps={{\n ...helperProps,\n className: `${classes['checkbox-wrapper-helper']} ${\n error ? classes['checkbox-wrapper-error'] : ''\n } ${helperProps?.className ?? ''}`,\n }}\n error={error}\n errorMessageIcon={Icons.Warning}\n errorId={errorId}\n >\n {renderChildren()}\n </Wrapper>\n </Fieldset>\n );\n};\n","import React, { HTMLProps, ReactElement, useEffect, useRef, useState } from 'react';\nimport { Props as ButtonProps } from '../Button/Button';\nimport { Props as IconButtonProps } from '../Button/IconButton';\nimport { Popover } from '../Popover/Popover';\nimport { Placement, Offset } from '../hooks/usePosition';\nimport { Props as ContextMenuItemProps } from './ContextMenuItem';\nimport classes from './ContextMenu.module.scss';\nimport { useBodyClick } from '../hooks/useBodyClick';\nimport { createPortal } from 'react-dom';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n trigger: ReactElement<ButtonProps> | ReactElement<IconButtonProps>;\n children: ReactElement<ContextMenuItemProps> | ReactElement<ContextMenuItemProps>[];\n placement?: Placement;\n transformOrigin?: Placement;\n offset?: Offset;\n id: string;\n show?: boolean;\n domRoot?: HTMLElement;\n onShow?: () => void;\n onClose?: () => void;\n}\n\nexport const ContextMenu = ({\n trigger,\n children,\n id,\n show = false,\n onShow,\n onClose,\n placement = { horizontal: 'right', vertical: 'top' },\n offset = { top: 0, bottom: 0, left: 0, right: 0 },\n transformOrigin = { horizontal: 'left', vertical: 'top' },\n domRoot = document.body,\n ...rest\n}: Props) => {\n const anchorEl = useRef<HTMLButtonElement>(null);\n const [showContextMenu, setShowContextMenu] = useState(show);\n\n if (!id) {\n throw new Error('You need to provide an ID to the context menu');\n }\n\n useBodyClick(\n (event) => {\n return showContextMenu && anchorEl.current !== event.target;\n },\n () => {\n setShowContextMenu(false);\n },\n showContextMenu\n );\n\n useEffect(() => {\n if (showContextMenu === true) {\n onShow && onShow();\n } else {\n onClose && onClose();\n }\n }, [showContextMenu]);\n\n const renderTrigger = () =>\n React.cloneElement(trigger, {\n id: id,\n ['aria-haspopup']: 'true',\n ['aria-controls']: `${id}-menu`,\n ['aria-expanded']: show,\n onClick: () => setShowContextMenu(!showContextMenu),\n ref: anchorEl,\n });\n\n return (\n <div {...rest} className={classes['context-menu']}>\n {renderTrigger()}\n {createPortal(\n <Popover\n placement={placement}\n transformOrigin={transformOrigin}\n offset={offset}\n anchorEl={anchorEl}\n show={showContextMenu}\n >\n <ul className={classes.menu} id={`${id}-menu`} aria-describedby={id} role=\"menu\">\n {children}\n </ul>\n </Popover>,\n domRoot\n )}\n </div>\n );\n};\n","import React, { HTMLProps } from 'react';\nimport classes from './ContextMenuItem.module.scss';\n\nexport interface Props extends Omit<HTMLProps<HTMLLIElement>, 'onClick'> {\n children?: string;\n onClick?: (event: React.MouseEvent<HTMLButtonElement>) => void;\n}\n\nexport const ContextMenuItem = ({ children, onClick, ...rest }: Props) => {\n return (\n <li {...rest} role=\"menuitem\" className={classes['context-menu-item']}>\n <button onClick={(event) => onClick && onClick(event)}>{children}</button>\n </li>\n );\n};\n","import React, { HTMLAttributes } from 'react';\nimport { BaseModal } from '../BaseModal/BaseModal';\nimport { BaseModalContent } from '../BaseModal/BaseModalContent/BaseModalContent';\nimport { DialogActions } from './DialogActions/DialogActions';\nimport classes from './Dialog.module.scss';\nimport { DialogTitle } from './DialogTitle/DialogTitle';\nimport { Button, Props as ButtonProps } from '../Button/Button';\nimport { labelId, descriptionId } from '../BaseModal/BaseModalContext';\n\nexport interface Props extends HTMLAttributes<HTMLDivElement> {\n id: string;\n open: boolean;\n children: React.ReactNode;\n alignActions: 'left' | 'right';\n onClose: () => void;\n title: string;\n primaryAction: Action;\n secondaryAction?: Action;\n zIndex?: number;\n}\n\nexport interface Action extends Omit<ButtonProps, 'variant' | 'ref'> {\n label: string;\n onClick: (event?: React.MouseEvent<HTMLButtonElement>) => unknown;\n}\n\nexport const Dialog = ({\n id,\n open,\n children,\n alignActions,\n onClose,\n title,\n primaryAction,\n secondaryAction,\n zIndex,\n ...restProps\n}: Props) => {\n const { label: primaryLabel, ...restOfPrimaryAction } = primaryAction;\n const PrimaryButton = (\n <Button key=\"primary\" {...restOfPrimaryAction}>\n {primaryLabel}\n </Button>\n );\n const TertiaryButton =\n secondaryAction &&\n (function () {\n const { label: secondaryLabel, ...restOfSecondaryAction } = secondaryAction;\n return (\n <Button key=\"tertiary\" variant=\"text\" {...restOfSecondaryAction}>\n {secondaryLabel}\n </Button>\n );\n })();\n\n const onHiddenInputKeyPress = (event: React.KeyboardEvent<HTMLInputElement>) => {\n /** It has to be here because then we will need to check if user doesn't click tab to select action button and want to do another action then primary one? */\n if (event.key === 'Enter') {\n primaryAction.onClick();\n }\n };\n\n return (\n <BaseModal\n {...restProps}\n id={id}\n className={classes['dialog']}\n containerClassName={classes['container']}\n open={open}\n disableBackdrop\n onClose={onClose}\n zIndex={zIndex}\n >\n <DialogTitle id={labelId(id)} title={title} />\n <BaseModalContent id={descriptionId(id)} className={classes['content']} disableAutoFocus>\n {children}\n </BaseModalContent>\n <DialogActions align={alignActions}>\n {alignActions === 'left'\n ? [PrimaryButton, TertiaryButton]\n : [TertiaryButton, PrimaryButton]}\n </DialogActions>\n <input\n autoFocus\n style={{\n position: 'absolute',\n width: 0,\n height: 0,\n opacity: 0,\n }}\n tabIndex={-1}\n onKeyPress={onHiddenInputKeyPress}\n />\n </BaseModal>\n );\n};\n","import React, { HTMLProps, ReactNode } from 'react';\nimport classes from './Form.module.scss';\n\nexport interface Props extends HTMLProps<HTMLFormElement> {\n children?: ReactNode;\n}\n\nexport const Form = ({ children, className, ...rest }: Props) => {\n return (\n <form className={`${classes.form} ${className ?? ''}`} {...rest}>\n {children}\n </form>\n );\n};\n","import React, { ReactElement } from 'react';\nimport classes from './FormControl.module.scss';\nimport { HTMLProps } from '../../interfaces';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n children: ReactElement | ReactElement[];\n grid?: 1 | 2 | 3;\n align?: 'top' | 'start' | 'middle' | 'center' | 'bottom' | 'end' | 'stretch';\n}\n\nexport const FormControl = ({\n children,\n disabled,\n className,\n grid,\n align = 'center',\n ...rest\n}: Props) => {\n const renderChildren = () =>\n React.Children.map(children, (child) => {\n if (!child) {\n return null;\n }\n\n const childElement = React.cloneElement(child, {\n disabled: child.props.disabled !== undefined ? child.props.disabled : disabled,\n });\n\n if (grid && grid > 1) {\n return <div className={`${classes['col-' + grid]} ${classes.column}`}>{childElement}</div>;\n }\n\n return childElement;\n });\n\n return (\n <div\n {...rest}\n data-formcontrol\n className={`${classes['form-control']} ${className ? className : ''} ${\n grid && grid > 1 ? `${classes.grid} ${classes['grid-' + grid]}` : ''\n } ${classes[align]}`}\n >\n {renderChildren()}\n </div>\n );\n};\n","import React from 'react';\nimport { Input, Type, Props as InputProps } from '../../Input/Input';\nimport classes from './InputWrapper.module.scss';\nimport { Wrapper, WrapperProps } from '../Wrapper/Wrapper';\nimport { useWrapper } from '../../../hooks/useWrapper';\n\ninterface OptionalInputProps extends Omit<InputProps, 'type'> {}\n\nexport interface Props extends WrapperProps {\n label: string;\n type: Type;\n name: string;\n inputProps?: OptionalInputProps;\n value: string;\n onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;\n onBlur?: (event: React.FocusEvent<HTMLInputElement>) => void;\n onFocus?: (event: React.FocusEvent<HTMLInputElement>) => void;\n}\n\nexport const InputWrapper = ({\n type,\n name,\n inputProps,\n helperText,\n helperProps,\n value,\n error,\n onChange,\n onBlur,\n onFocus,\n ...rest\n}: Props) => {\n const {\n errorId,\n floatingLabelActive,\n setFloatingLabelActive,\n hasFocus,\n setHasFocus,\n helperId,\n labelId,\n } = useWrapper(value, inputProps?.placeholder, type);\n\n return (\n <Wrapper\n {...rest}\n name={name}\n className={classes['input-wrapper']}\n labelProps={{\n id: labelId,\n className: `${classes['input-label']} ${hasFocus ? classes['focus'] : ''}`,\n }}\n floatingLabelActive={floatingLabelActive}\n errorId={errorId}\n error={error}\n helperId={helperId}\n helperText={helperText}\n helperProps={{\n ...helperProps,\n className: `${classes['input-wrapper-helper']} ${helperProps?.className ?? ''} `,\n }}\n helperIndent={20}\n >\n <Input\n {...inputProps}\n aria-labelledby={labelId}\n aria-describedby={error ? errorId : helperId}\n onChange={onChange}\n onFocus={(e) => {\n onFocus && onFocus(e);\n setHasFocus(true);\n setFloatingLabelActive(true);\n }}\n onBlur={(e) => {\n onBlur && onBlur(e);\n setHasFocus(false);\n e.target.value ||\n inputProps?.placeholder?.length ||\n type === 'datetime-local' ||\n type === 'time'\n ? setFloatingLabelActive(true)\n : setFloatingLabelActive(false);\n }}\n className={floatingLabelActive ? classes['floating-label'] : ''}\n name={name}\n error={error}\n id={name}\n value={value}\n type={type}\n />\n </Wrapper>\n );\n};\n","import React, { HTMLAttributes } from 'react';\nimport classes from './BaseModalHeader.module.scss';\nimport { IconButton } from '../../Button/IconButton';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { Typography } from '../../Typography/Typography';\n\nexport interface Props extends HTMLAttributes<HTMLElement> {\n id: string;\n title: string;\n children?: React.ReactNode;\n onClose: (event: React.MouseEvent<HTMLButtonElement>) => void;\n}\n\nexport const BaseModalHeader = ({ id, title, children, onClose, ...restProps }: Props) => {\n return (\n <header {...restProps} className={classes['header']}>\n <div className={classes['headline']}>\n <Typography id={id} className={classes['title']} tag=\"h1\" variant=\"h4\">\n {title}\n </Typography>\n <IconButton onClick={onClose} className={classes['closeBtn']} title=\"close modal\">\n <Icon icon={Icons.Times} />\n </IconButton>\n </div>\n {children}\n </header>\n );\n};\n","import React, { useEffect, useState } from 'react';\nimport classes from './Select.module.scss';\nimport { HTMLProps } from '../../interfaces';\n\nexport interface Props extends HTMLProps<HTMLLIElement> {\n children: string;\n value: string;\n disabled?: boolean;\n selected?: boolean;\n label?: string;\n filter?: string;\n onOptionSelect?: (event: React.SyntheticEvent<HTMLLIElement>) => void;\n}\n\nexport const Option = ({\n children,\n className,\n selected = false,\n onOptionSelect,\n disabled,\n filter,\n ...rest\n}: Props) => {\n const [showOption, setShowOption] = useState(true);\n\n const onSelectHandler = (event: React.SyntheticEvent<HTMLLIElement>) => {\n if (onOptionSelect) onOptionSelect(event);\n };\n\n useEffect(() => {\n if (filter) {\n setShowOption(children.toLowerCase().match(filter.toLowerCase()) !== null);\n } else {\n setShowOption(true);\n }\n }, [filter]);\n\n if (!showOption) return null;\n\n return (\n <li\n {...rest}\n className={`${selected ? classes['selected-option'] : ''} ${\n disabled ? classes.disabled : ''\n } ${className ?? ''}`}\n onClick={onSelectHandler}\n onKeyPress={(e) => {\n e.key === 'Enter' && onSelectHandler(e);\n }}\n aria-selected={selected}\n role=\"option\"\n tabIndex={disabled ? -1 : 0}\n >\n {children}\n </li>\n );\n};\n","import React from 'react';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { Props as HelperProps } from '../FormHelperText/FormHelperText';\nimport classes from './Radio.module.scss';\nimport { useFormSelector } from '../../hooks/useFormSelector';\nimport { FormSelector } from '../form.interfaces';\nimport { HTMLProps } from '../../interfaces';\nimport { FormSelectorWrapper } from '../FormSelectorWrapper/FormSelectorWrapper';\n\nexport interface Props extends FormSelector<HTMLInputElement> {\n children: string;\n value: string;\n wrapperProps?: HTMLProps<HTMLDivElement>;\n helperProps?: HelperProps;\n}\n\nexport const Radio = ({\n children,\n disabled,\n className,\n value,\n name,\n helperText,\n parentErrorId,\n parentHelperId,\n error,\n errorMessage,\n checked = false,\n wrapperProps,\n helperProps,\n onChange,\n ...rest\n}: Props) => {\n const { errorId, identifier, describedBy } = useFormSelector({\n name,\n helperText,\n parentErrorId,\n errorMessage,\n error,\n parentHelperId,\n });\n\n const onChangeHandler = (event: React.ChangeEvent<HTMLInputElement> | React.MouseEvent) => {\n if (disabled) {\n return;\n }\n /** We have to clone the native event we got here and change the \"target\" property to the value. Otherwise, this regular event has \"on\" as it's event.target.value, which is useless. */\n const nativeEvent: any = event.nativeEvent || event;\n const clonedEvent = new nativeEvent.constructor(nativeEvent.type, nativeEvent);\n\n Object.defineProperty(clonedEvent, 'target', {\n writable: true,\n value: { value: value },\n });\n\n onChange && onChange(clonedEvent);\n };\n\n /** Default return value is the default radio */\n return (\n <FormSelectorWrapper\n {...wrapperProps}\n className={`${classes['radio-wrapper']} ${className ?? ''}`}\n containerProps={{ className: classes['radio-container'] }}\n helperText={helperText}\n helperProps={helperProps}\n parentErrorId={parentErrorId}\n errorId={errorId}\n errorMessage={errorMessage}\n error={error}\n disabled={disabled}\n identifier={identifier}\n >\n <input\n {...rest}\n disabled={disabled}\n tabIndex={0}\n className={`${classes['native-input']} ${error ? classes['error'] : ''}`}\n onChange={onChangeHandler}\n checked={checked}\n aria-invalid={error ? true : false}\n aria-checked={checked}\n aria-describedby={describedBy}\n name={name}\n value={value}\n id={`${identifier}-radio`}\n type=\"radio\"\n />\n\n {checked && <Icon className={classes.input} icon={Icons.Radio} />}\n {!checked && <Icon className={classes.input} icon={Icons.Circle} />}\n\n <label onClick={onChangeHandler} htmlFor={`${identifier}-radio`}>\n {children}\n </label>\n </FormSelectorWrapper>\n );\n};\n","import React, { ReactElement, useEffect } from 'react';\nimport classes from './RadioWrapper.module.scss';\nimport { Wrapper, WrapperProps } from '../Wrapper/Wrapper';\nimport { useWrapper } from '../../../hooks/useWrapper';\nimport { Icons } from '../../../Icon/Icon';\nimport { Fieldset, Props as FieldsetProps } from '../../../Form/Fieldset/Fieldset';\n\nexport interface Props extends WrapperProps {\n children: ReactElement | ReactElement[];\n fieldsetProps: FieldsetProps;\n value: string;\n onChange: (event: React.ChangeEvent<HTMLInputElement>) => void;\n}\n\nexport const RadioWrapper = ({\n children,\n error,\n name,\n helperText,\n helperProps,\n fieldsetProps,\n value,\n onChange,\n disabled,\n ...rest\n}: Props) => {\n const { errorId, helperId } = useWrapper(value);\n\n useEffect(() => {\n if (fieldsetProps.title === undefined) {\n console.error(\n `You should give your Fieldset component a title prop so a legend element is rendered. This error was thrown in RadioWrapper. You can add this title prop through the fieldsetProps prop by passing an object (fieldsetProps={{ title: \"title here\" }})`\n );\n }\n }, []);\n\n const renderChildren = () =>\n React.Children.map(children, (child) =>\n React.cloneElement(child, {\n parentErrorId: errorId,\n error: error,\n checked: child.props.value === value,\n name: name,\n parentHelperId: helperText ? helperId : false,\n onChange: onChange,\n disabled: child.props.disabled !== undefined ? child.props.disabled : disabled,\n })\n );\n\n return (\n <Fieldset {...fieldsetProps}>\n <Wrapper\n {...rest}\n disabled={disabled}\n name={name}\n label=\"\"\n helperId={helperId}\n helperText={helperText}\n helperProps={{\n ...helperProps,\n className: `${classes['radio-wrapper-helper']} ${\n error ? classes['radio-wrapper-error'] : ''\n } ${helperProps?.className ?? ''}`,\n }}\n error={error}\n errorId={errorId}\n errorMessageIcon={Icons.Warning}\n floatingLabel={false}\n >\n {renderChildren()}\n </Wrapper>\n </Fieldset>\n );\n};\n","import React, { ReactChild, ReactElement } from 'react';\nimport classes from './SelectWrapper.module.scss';\nimport { Wrapper, WrapperProps } from '../Wrapper/Wrapper';\nimport { Select, Props as SelectProps } from '../../Select/Select';\nimport { useWrapper } from '../../../hooks/useWrapper';\n\nexport interface Props extends Omit<WrapperProps, 'onChange'> {\n children: ReactChild | ReactChild[];\n placeholder?: string;\n value: string;\n selectProps?: SelectProps;\n onChange?: (event: React.ChangeEvent<HTMLSelectElement>) => void;\n onClear?: () => void;\n}\n\nexport const SelectWrapper = ({\n children,\n error,\n value,\n placeholder,\n selectProps,\n helperProps,\n onChange,\n onClear,\n ...rest\n}: Props) => {\n const { errorId, floatingLabelActive, helperId, labelId } = useWrapper(value, placeholder);\n\n return (\n <Wrapper\n {...rest}\n floatingLabelActive={floatingLabelActive}\n errorId={errorId}\n helperId={helperId}\n labelProps={{ id: labelId, className: classes['select-label'] }}\n helperProps={{\n ...helperProps,\n className: `${classes['select-helper-text']} ${helperProps?.className ?? ''}`,\n }}\n error={error}\n >\n <Select\n {...selectProps}\n value={value}\n labeledBy={labelId}\n error={error}\n describedBy={error ? errorId : helperId}\n onChange={onChange}\n onClear={onClear}\n placeholder={placeholder}\n className={`${floatingLabelActive ? classes['floating-label-active'] : ''} ${\n selectProps?.className ?? ''\n }`}\n >\n {children as ReactElement[]}\n </Select>\n </Wrapper>\n );\n};\n","import React, { ReactNode, useState } from 'react';\nimport { createPortal } from 'react-dom';\nimport { SnackbarContextProvider } from './SnackbarStateProvider';\nimport { Actions, SnackbarOptionsProps, Variant } from '../interfaces';\nimport { Placement, SnackbarContainer } from '../SnackbarContainer/SnackbarContainer';\nimport { generateID } from '../../util/helper';\nimport { SnackbarItem } from '../SnackbarItem/SnackbarItem';\n\n/** Short msg is when only title is provided. Long one when content or/and actions are provided (or type is error). */\ninterface Duration {\n long: number;\n short: number;\n}\n\nexport interface Props {\n closeButtonTitle: string;\n children?: ReactNode | ReactNode[];\n placement?: Placement;\n stackSize?: number;\n domRoot?: HTMLElement;\n autoHideDuration?: Duration;\n className?: string;\n}\n\ninterface Item {\n id: string;\n title: string;\n duration: number;\n variant: Variant;\n content?: string;\n actions?: Actions;\n}\n\nexport const SnackbarProvider = (\n {\n closeButtonTitle,\n placement = { vertical: 'bottom', horizontal: 'center' },\n autoHideDuration = { long: 8000, short: 4000 },\n stackSize = 3,\n domRoot = document.body,\n children,\n className,\n }: Props = { closeButtonTitle: '' }\n) => {\n const [snackbars, setSnackbars] = useState<Item[]>([]);\n\n const addSnackbar = (item: Item) => {\n setSnackbars((items) => [...items, item]);\n };\n\n const getDuration = (variant: Variant, actions?: Actions, content?: string) => {\n const hasError = variant === 'error';\n const hasContentOrActions = content || actions;\n if (hasError || hasContentOrActions) {\n return autoHideDuration.long;\n }\n return autoHideDuration.short;\n };\n\n const enqueueSnackbar = (\n title: string,\n content?: string,\n options: SnackbarOptionsProps = {}\n ): void => {\n const {\n variant = 'info',\n actions,\n duration = getDuration(variant, actions, content),\n } = options;\n const item: Item = {\n title,\n content,\n variant,\n actions,\n duration,\n id: generateID(15, title),\n };\n addSnackbar(item);\n };\n\n const enqueueSuccessSnackbar = (\n title: string,\n content?: string,\n options?: SnackbarOptionsProps\n ): void => {\n enqueueSnackbar(title, content, { ...options, variant: 'success' });\n };\n\n const enqueueErrorSnackbar = (\n title: string,\n content?: string,\n options?: SnackbarOptionsProps\n ): void => {\n enqueueSnackbar(title, content, { ...options, variant: 'error' });\n };\n\n const onItemClosed = (id: string) => {\n setSnackbars((items) => [...items].filter((item) => item.id !== id));\n };\n\n const snackbarList = snackbars.map((item, index) =>\n index < stackSize ? (\n <SnackbarItem\n {...item}\n key={item.id}\n onClose={onItemClosed}\n closeButtonTitle={closeButtonTitle}\n />\n ) : null\n );\n\n const snackbarPortal = createPortal(\n <SnackbarContainer placement={placement} className={className}>\n {snackbarList}\n </SnackbarContainer>,\n domRoot\n );\n\n return (\n <SnackbarContextProvider\n initialState={{ enqueueSnackbar, enqueueSuccessSnackbar, enqueueErrorSnackbar }}\n >\n {children}\n {snackbarPortal}\n </SnackbarContextProvider>\n );\n};\n","import React, { useState } from 'react';\nimport classes from './TextareaWrapper.module.scss';\nimport { Wrapper, WrapperProps } from '../Wrapper/Wrapper';\nimport { Textarea, Props as TextareaProps } from '../../Textarea/Textarea';\nimport { useWrapper } from '../../../hooks/useWrapper';\n\nexport interface Props\n extends Omit<WrapperProps, 'onFocus' | 'onChange' | 'onBlur' | 'onMouseEnter' | 'onMouseLeave'> {\n placeholder?: string;\n textareaProps?: TextareaProps;\n value: string;\n onFocus?: (event: React.FocusEvent<HTMLTextAreaElement>) => void;\n onChange?: (event: React.ChangeEvent<HTMLTextAreaElement>) => void;\n onBlur?: (event: React.FocusEvent<HTMLTextAreaElement>) => void;\n onMouseEnter?: (event: React.MouseEvent<HTMLTextAreaElement>) => void;\n onMouseLeave?: (event: React.MouseEvent<HTMLTextAreaElement>) => void;\n}\n\nexport const TextareaWrapper = ({\n name,\n error,\n value,\n label,\n placeholder,\n textareaProps,\n helperProps,\n onChange,\n onFocus,\n onBlur,\n onMouseEnter,\n onMouseLeave,\n disabled,\n ...rest\n}: Props) => {\n const {\n errorId,\n floatingLabelActive,\n setFloatingLabelActive,\n hasFocus,\n setHasFocus,\n helperId,\n labelId,\n } = useWrapper(value, placeholder);\n\n const [focus, setFocus] = useState(false);\n const [hover, setHover] = useState(false);\n\n return (\n <Wrapper\n {...rest}\n disabled={disabled}\n labelProps={{\n id: labelId,\n className: `${classes['textarea-label']} ${hasFocus ? classes['focus'] : ''}`,\n }}\n name={name}\n label={label}\n helperId={helperId}\n helperProps={{\n ...helperProps,\n className: classes['textarea-helper-text'],\n }}\n error={error}\n floatingLabelActive={floatingLabelActive}\n errorId={errorId}\n >\n <Textarea\n {...textareaProps}\n error={error}\n aria-labelledby={label && labelId}\n aria-describedby={error ? errorId : helperId}\n placeholder={placeholder}\n value={value}\n onChange={onChange}\n onFocus={(e) => {\n onFocus && onFocus(e);\n setHasFocus(true);\n setFloatingLabelActive(true);\n setFocus(true);\n }}\n onBlur={(e) => {\n onBlur && onBlur(e);\n setHasFocus(false);\n setFocus(false);\n e.target.value || textareaProps?.placeholder?.length\n ? setFloatingLabelActive(true)\n : setFloatingLabelActive(false);\n }}\n onMouseEnter={(e) => {\n onMouseEnter && onMouseEnter(e);\n setHover(true);\n }}\n onMouseLeave={(e) => {\n onMouseLeave && onMouseLeave(e);\n setHover(false);\n }}\n className={classes['textarea']}\n wrapperClassName={`${classes['textarea-wrapper']} ${focus ? classes['focus'] : ''} ${\n hover ? classes['hover'] : ''\n } ${disabled ? classes['disabled'] : ''} ${error ? classes['error'] : ''}`}\n errorClassName={classes['error-icon']}\n />\n </Wrapper>\n );\n};\n","import React, { HTMLProps, ReactNode } from 'react';\nimport classes from './Tiles.module.scss';\nimport { Tile } from './Tile';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n children: ReactNode;\n loading?: boolean;\n}\n\nexport const Tiles = ({ children, className, loading = false, ...rest }: Props) => {\n const renderChildren = () => {\n if (loading) {\n return [\n <Tile\n key=\"placeholder1\"\n title=\"placeholder\"\n imageProps={{ src: 'placeholder', alt: 'placeholder' }}\n loading={true}\n />,\n <Tile\n key=\"placeholder2\"\n title=\"placeholder\"\n imageProps={{ src: 'placeholder', alt: 'placeholder' }}\n loading={true}\n />,\n <Tile\n key=\"placeholder3\"\n title=\"placeholder\"\n imageProps={{ src: 'placeholder', alt: 'placeholder' }}\n loading={true}\n />,\n ];\n }\n\n return children;\n };\n\n return (\n <div\n {...rest}\n className={`${classes['tiles']} ${className ?? ''}`}\n aria-live=\"polite\"\n aria-busy={loading}\n >\n {renderChildren()}\n </div>\n );\n};\n","import React, { useContext, useMemo } from 'react';\nimport { Button } from '../../Button/Button';\nimport { Step } from '../BaseWizardSteps/BaseWizardSteps';\nimport { WizardMode } from '../Wizard';\nimport { WizardStateContext } from '../WizardStateProvider';\nimport { changeCurrentStepNo } from '../wizardStateReducer';\n\nexport interface Props extends React.HTMLProps<HTMLDivElement> {\n cancelButtonLabel: string;\n previousButtonLabel: string;\n nextButtonLabel: string;\n saveAndCloseButtonLabel: string;\n onCancel: () => void;\n onNext: (currentStepNo: number) => boolean;\n onPrevious?: () => void;\n onSaveAndClose: (currentStepNo: number) => void;\n}\n\nconst calculateNextStepNo = (steps: Step[], currentStepNo: number) => () =>\n steps.findIndex((step, stepNo) => stepNo > currentStepNo && !step.disabled);\n\nconst calculatePrevStepNo = (steps: Step[], currentStepNo: number) => () => {\n const reversedCurrentStepNo = steps.length - 1 - currentStepNo;\n const reversedPrevStepNo = [...steps]\n .reverse()\n .findIndex((step, stepNo) => stepNo > reversedCurrentStepNo && !step.disabled);\n if (reversedPrevStepNo > 0) {\n return steps.length - 1 - reversedPrevStepNo;\n }\n return -1;\n};\n\nconst useNextStepNo = (mode: WizardMode, currentStepNo: number, steps: Step[]) =>\n useMemo(calculateNextStepNo(steps, currentStepNo), [mode, currentStepNo, steps]);\n\nconst usePreviousStepNo = (mode: WizardMode, currentStepNo: number, steps: Step[]) =>\n useMemo(calculatePrevStepNo(steps, currentStepNo), [mode, currentStepNo, steps]);\n\nexport const WizardActions = ({\n onCancel,\n onNext,\n onPrevious,\n onSaveAndClose,\n cancelButtonLabel,\n previousButtonLabel,\n nextButtonLabel,\n saveAndCloseButtonLabel,\n}: Props) => {\n const {\n state: { mode, steps, currentStepNo },\n dispatch,\n } = useContext(WizardStateContext);\n const nextStepNo = useNextStepNo(mode, currentStepNo, steps);\n const hasNextStep = nextStepNo !== -1;\n const previousStepNo = usePreviousStepNo(mode, currentStepNo, steps);\n const hasPreviousStep = previousStepNo !== -1;\n const isLastStepOrEditMode = !hasNextStep || mode === 'edit';\n\n const changeStepNo = (direction: 'forward' | 'backward') => {\n if (direction === 'forward') {\n hasNextStep && dispatch(changeCurrentStepNo(nextStepNo));\n } else {\n hasPreviousStep && dispatch(changeCurrentStepNo(previousStepNo));\n }\n };\n\n const onNextWrapper = () => {\n onNext(currentStepNo) && changeStepNo('forward');\n };\n\n const onPreviousWrapper = () => {\n onPrevious && onPrevious();\n changeStepNo('backward');\n };\n\n const onSaveAndCloseWrapper = () => {\n onSaveAndClose(currentStepNo);\n };\n\n return (\n <>\n <Button variant=\"text\" onClick={onCancel}>\n {cancelButtonLabel}\n </Button>\n {hasPreviousStep && (\n <Button variant=\"outline\" onClick={onPreviousWrapper}>\n {previousButtonLabel}\n </Button>\n )}\n {hasNextStep && (\n <Button variant={mode === 'edit' ? 'outline' : 'fill'} onClick={onNextWrapper}>\n {nextButtonLabel}\n </Button>\n )}\n {isLastStepOrEditMode && (\n <Button onClick={onSaveAndCloseWrapper}>{saveAndCloseButtonLabel}</Button>\n )}\n </>\n );\n};\n","import React, { useContext } from 'react';\nimport { WizardStateContext } from '../WizardStateProvider';\nimport { BaseWizardSteps } from '../BaseWizardSteps/BaseWizardSteps';\nimport { changeCurrentStepNo } from '../wizardStateReducer';\n\nexport interface Props extends Omit<React.HTMLProps<HTMLDivElement>, 'onClick'> {\n onStepClick: (currentStepNo: number, selectedStepNo: number) => boolean;\n}\n\nexport const WizardSteps = ({ onStepClick, ...restProps }: Props) => {\n const {\n state: { currentStepNo, mode, stepScreenReaderLabel, steps },\n dispatch,\n } = useContext(WizardStateContext);\n\n const onClick = (selectedStepNo: number) => {\n onStepClick(currentStepNo, selectedStepNo) && dispatch(changeCurrentStepNo(selectedStepNo));\n };\n\n return (\n <BaseWizardSteps\n {...restProps}\n onClick={onClick}\n steps={steps}\n currentStepNo={currentStepNo}\n stepScreenReaderLabel={stepScreenReaderLabel}\n futureStepsClickable={mode === 'edit'}\n />\n );\n};\n","import { useContext } from 'react';\nimport { SnackbarContext } from './SnackbarProvider/SnackbarStateProvider';\n\nexport const useSnackbar = () => useContext(SnackbarContext);\n"],"names":["e","t","n","r","document","a","s","prepend","d","singleTag","i","container","querySelector","getElementsByTagName","u","indexOf","push","c","charCodeAt","substring","styleSheet","cssText","appendChild","createTextNode","createElement","setAttribute","attributes","Object","keys","length","insertAdjacentElement","spacingNumberRegex","validVariants","Typography","children","variant","tag","style","spacing","className","rest","includes","Error","styleWithSpacing","spacingProps","entries","reduce","prev","matches","String","matchAll","cssSpacingValue","Array","from","map","Number","join","useSpacing","React","classes","BaseButton","forwardRef","ref","type","Button","color","startIcon","endIcon","additionalClasses","Link","disabled","to","component","classNames","download","rel","undefined","href","target","IconButton","iconSize","title","Icons","Icon","icon","size","fontSize","labelId","id","descriptionId","BaseModal","open","onClose","containerClassName","labelledby","describedby","disableEscapeKeyDown","disableBackdrop","zIndex","restProps","backdropRef","useRef","onBackdropClick","useEffect","current","_backdropRef$current","addEventListener","_backdropRef$current2","removeEventListener","useBackdropOnCloseClick","body","querySelectorAll","removeProperty","useSetBodyScroll","role","tabIndex","onKeyDown","event","key","stopPropagation","BaseModalContent","disableAutoFocus","contentRef","_contentRef$current","focus","BaseModalActions","DialogActions","align","DialogTitle","generateID","stringToWeaveIn","hashCharacters","test","Math","floor","random","slice","defaultConfigObject","relativeElement","elementToBePositioned","transformOrigin","horizontal","vertical","placement","offset","top","right","bottom","left","usePosition","providedConfigObject","configObject","useState","position","setPosition","_calculatePlacement","relEl","elDimensions","axis","placementValue","requestedReturnValue","placementOriginDefinition","_determineCenteredPlacementOrigin","value","window","_calculateInitialPlacementValue","valueWithOffset","returnValue","_configObject$offset3","_configObject$offset4","_configObject$offset5","_configObject$offset6","_configObject$offset9","_configObject$offset10","_configObject$offset11","_configObject$offset12","_applyOffsetToPlacementValue","valueCorrectionForViewportOverflow","innerWidth","width","innerHeight","height","_fixPossibleViewportOverflow","_calculatePlacementValue","direction","oppositeDirection","prevState","calculatePosition","_configObject$relativ","relativeElRect","getBoundingClientRect","elementToBePositionedDimensions","offsetHeight","offsetWidth","clonedRelEl","center","centerv","centerh","x","y","defaultPosition","Tile","imageProps","iconProps","loading","menu","src","alt","Image","Popover","show","anchorEl","elToBePositioned","useBodyClick","checkFunction","callbackFunction","dependingStateVariable","bodyClickListener","SnackbarContext","createContext","enqueueSnackbar","enqueueSuccessSnackbar","enqueueErrorSnackbar","SnackbarContextProvider","Provider","initialState","SnackbarContainer","SnackbarItem","duration","content","actions","closeButtonTitle","timerHandler","callback","animatedObjectRef","animationStarted","setAnimationStarted","onAnimationEnd","_animatedObjectRef$cu2","startAnimation","useAnimation","setTimeout","clearTimeout","actionButtons","actionProp","index","onClick","label","onMouseEnter","onMouseLeave","TimesCircleAlt","CheckmarkCircleBreakout","InfoCircle","Times","Fieldset","titleVariant","hideTitle","background","noBackground","noPadding","backgroundColor","Children","child","cloneElement","props","renderChildren","FormHelperText","error","FormGroup","errorMessage","errorId","errorMessageIcon","errorMessageIconPosition","helperText","helperId","helperProps","helperIndent","marginLeft","message","Label","hidden","dateTypes","Input","name","wrapperProps","labeledBy","inputClassNames","iconClassNames","Warning","Select","placeholder","describedBy","searchPlaceholder","onChange","onClear","expanded","setExpanded","filter","setFilter","display","setDisplay","listPosition","setListPosition","containerReference","optionListReference","closest","rePositionList","windowHeight","containerTopWithListHeight","scrollListener","useLayoutEffect","useScroll","onOptionChangeHandler","newValue","nativeEvent","clonedEvent","constructor","defineProperty","writable","currentTarget","innerText","TimesThin","TriangleDown","isArray","autoFocus","onOptionSelect","selected","Textarea","rows","wrapperClassName","errorClassName","useWrapper","floatingLabelActive","setFloatingLabelActive","hasFocus","setHasFocus","Wrapper","floatingLabel","required","labelProps","innerClassName","labelClasses","wrapper","htmlFor","useFormSelector","identifier","setDescribedBy","parentErrorId","parentHelperId","FormSelectorWrapper","nestedChildren","containerProps","isToggle","_children$props","BaseWizardSteps","steps","currentStepNo","futureStepsClickable","stepScreenReaderLabel","generatedSteps","step","stepNo","stepState","disabledStyleClassName","clickableClassName","toLowerCase","replace","stepNumberString","Checkmark","getStepContent","changeCurrentStepNo","payload","reducer","state","action","WizardStateContext","dispatch","WizardStateProvider","useReducer","WizardContent","mode","onStepChange","useContext","setWizardState","useStepChanging","properties","defaultProperties","colorPrimary","colorSecondary","colorTertiary","defaultLineHeight","buttonBorderRadius","buttonBorderWidth","buttonFontSize","buttonBorderStyle","buttonFillTextColor","buttonFillBackgroundColor","buttonOutlineHoverTextColor","inputBorderColor","inputBorderRadius","inputBorderWidth","inputBorderStyle","modalShadowColor","modalBackgroundColor","modalHeaderBackgroundColor","snackbarTextColor","snackbarInfoBackgroundColor","snackbarSuccessBackgroundColor","snackbarErrorBackgroundColor","snackbarBorderRadius","success","greyedOut","warning","fontFamily","fontFamilyCode","fontSizeH1","fontSizeH2","fontSizeH3","fontSizeH4","fontSizeSub","fontSizeCode","isLoading","setIsLoading","setCSSProperties","CSSPropertiesObject","formattedPropertyName","replaceAll","val","documentElement","setProperty","mergedState","Fragment","ariaLabel","items","ChevronRight","Checkbox","indeterminate","checked","console","toArray","MinusSquare","CheckmarkSquare","Square","determineLabel","fieldsetProps","trigger","onShow","domRoot","showContextMenu","setShowContextMenu","createPortal","secondaryLabel","restOfSecondaryAction","alignActions","primaryAction","secondaryAction","primaryLabel","restOfPrimaryAction","PrimaryButton","TertiaryButton","opacity","onKeyPress","grid","childElement","column","inputProps","onBlur","onFocus","_inputProps$placehold","showOption","setShowOption","onSelectHandler","match","onChangeHandler","Radio","Circle","selectProps","autoHideDuration","stackSize","setSnackbars","options","item","getDuration","onItemClosed","snackbarList","snackbarPortal","textareaProps","setFocus","hover","setHover","_textareaProps$placeh","visible","setVisible","escapePressHandler","isValidElement","initialStepNo","onCancel","onNext","onPrevious","onSaveAndClose","cancelButtonLabel","previousButtonLabel","nextButtonLabel","saveAndCloseButtonLabel","nextStepNo","useMemo","findIndex","calculateNextStepNo","useNextStepNo","hasNextStep","previousStepNo","reversedCurrentStepNo","reversedPrevStepNo","reverse","calculatePrevStepNo","usePreviousStepNo","hasPreviousStep","isLastStepOrEditMode","changeStepNo","onStepClick","selectedStepNo"],"mappings":"uoBAAIA,EAAE,GAAGC,EAAE,GAAG,SAASC,EAAEA,EAAEC,GAAG,GAAGD,GAAG,oBAAoBE,SAAS,CAAC,IAAIC,EAAEC,GAAE,IAAKH,EAAEI,QAAQ,UAAU,SAASC,GAAE,IAAKL,EAAEM,UAAUC,EAAE,iBAAiBP,EAAEQ,UAAUP,SAASQ,cAAcT,EAAEQ,WAAWP,SAASS,qBAAqB,QAAQ,GAAG,GAAGL,EAAE,CAAC,IAAIM,EAAEd,EAAEe,QAAQL,IAAI,IAAII,IAAIA,EAAEd,EAAEgB,KAAKN,GAAG,EAAET,EAAEa,GAAG,IAAIT,EAAEJ,EAAEa,IAAIb,EAAEa,GAAGR,GAAGL,EAAEa,GAAGR,GAAGL,EAAEa,GAAGR,GAAGW,SAASZ,EAAEY,IAAI,QAAQf,EAAEgB,WAAW,KAAKhB,EAAEA,EAAEiB,UAAU,IAAId,EAAEe,WAAWf,EAAEe,WAAWC,SAASnB,EAAEG,EAAEiB,YAAYlB,SAASmB,eAAerB,IAAI,SAASe,IAAI,IAAIjB,EAAEI,SAASoB,cAAc,SAAS,G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B,QAAQ,UAAUmN,QAfN,WACxB4P,GAAcA,IACdoB,EAAa,cAcNjB,GAGJQ,GACCnc,wBAACM,GAAO7B,QAAkB,SAATyV,EAAkB,UAAY,OAAQtI,QAxBvC,WACpB2P,EAAO7I,IAAkBkK,EAAa,aAwB/BhB,GAGJe,GACC3c,wBAACM,GAAOsL,QApBgB,WAC5B6P,EAAe/I,KAmB8BmJ,yBCtFtB,gBAAGgB,IAAAA,YAAgBpa,YAIxC2R,aAAWP,QAFbF,MAASjB,IAAAA,cACToB,IAAAA,gBAQA9T,wBAACwS,QACK/P,GACJmJ,QAPY,SAACkR,GACfD,EAAYnK,EAAeoK,IAAmBhJ,EAASN,GAAoBsJ,KAOzErK,QAZmDA,MAanDC,cAAeA,EACfE,wBAd4BA,sBAe5BD,qBAA+B,WAfTuB,6BCRD,kBAAME,aAAWpK"}
1
+ {"version":3,"file":"react-lib-components.cjs.production.min.js","sources":["../node_modules/rollup-plugin-styles/dist/runtime/inject-css.js","../src/hooks/useSpacing.ts","../src/Typography/Typography.tsx","../src/Button/BaseButton.tsx","../src/Button/Button.tsx","../src/Link/Link.tsx","../src/Button/IconButton.tsx","../src/Icon/Icon.tsx","../src/Notifications/BaseModal/BaseModalContext.ts","../src/Notifications/BaseModal/BaseModal.tsx","../src/Notifications/BaseModal/BaseModalContent/BaseModalContent.tsx","../src/Notifications/BaseModal/BaseModalActions/BaseModalActions.tsx","../src/Notifications/Dialog/DialogActions/DialogActions.tsx","../src/Notifications/Dialog/DialogTitle/DialogTitle.tsx","../src/util/helper.tsx","../src/Notifications/Dialog/Dialog.tsx","../src/Notifications/BaseModal/BaseModalHeader/BaseModalHeader.tsx","../src/Notifications/DiscardChangesModal/DiscardChangesDialog/DiscardChangesDialog.tsx","../src/hooks/usePosition.ts","../src/Tooltip/Tooltip.tsx","../src/Tiles/Tile.tsx","../src/Popover/Popover.tsx","../src/hooks/useBodyClick.ts","../src/Notifications/Snackbar/SnackbarProvider/SnackbarStateProvider.tsx","../src/Notifications/Snackbar/SnackbarContainer/SnackbarContainer.tsx","../src/hooks/useAnimation.ts","../src/Notifications/Snackbar/SnackbarItem/SnackbarItem.tsx","../src/Form/Fieldset/Fieldset.tsx","../src/Form/FormHelperText/FormHelperText.tsx","../src/Form/FormGroup/FormGroup.tsx","../src/Form/Label/Label.tsx","../src/Form/Input/Input.tsx","../src/Form/Select/Select.tsx","../src/hooks/useScroll.ts","../src/Form/Textarea/Textarea.tsx","../src/hooks/useWrapper.ts","../src/Form/Wrapper/Wrapper/Wrapper.tsx","../src/hooks/useFormSelector.ts","../src/Form/FormSelectorWrapper/FormSelectorWrapper.tsx","../src/Form/Checkbox/Checkbox.tsx","../src/Wizard/BaseWizardSteps/BaseWizardSteps.tsx","../src/Wizard/wizardStateReducer.ts","../src/Wizard/WizardStateProvider.tsx","../src/Wizard/Wizard.tsx","../src/_BaseStyling_/BaseStyling.tsx","../src/Breadcrumbs/Breadcrumbs.tsx","../src/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.tsx","../src/ContextMenu/ContextMenu.tsx","../src/ContextMenu/ContextMenuItem.tsx","../src/Notifications/DiscardChangesModal/DiscardChangesModal.tsx","../src/Form/Form.tsx","../src/Form/FormControl/FormControl.tsx","../src/Form/Wrapper/InputWrapper/InputWrapper.tsx","../src/Form/Select/Option.tsx","../src/Form/Radio/Radio.tsx","../src/Form/Wrapper/RadioWrapper/RadioWrapper.tsx","../src/Form/Wrapper/SelectWrapper/SelectWrapper.tsx","../src/Notifications/Snackbar/SnackbarProvider/SnackbarProvider.tsx","../src/Form/Wrapper/TextareaWrapper/TextareaWrapper.tsx","../src/Tiles/Tiles.tsx","../src/Wizard/WizardActions/WizardActions.tsx","../src/Wizard/WizardSteps/WizardSteps.tsx","../src/Notifications/Snackbar/useSnackbar.ts"],"sourcesContent":["var e=[],t=[];function n(n,r){if(n&&\"undefined\"!=typeof document){var a,s=!0===r.prepend?\"prepend\":\"append\",d=!0===r.singleTag,i=\"string\"==typeof r.container?document.querySelector(r.container):document.getElementsByTagName(\"head\")[0];if(d){var u=e.indexOf(i);-1===u&&(u=e.push(i)-1,t[u]={}),a=t[u]&&t[u][s]?t[u][s]:t[u][s]=c()}else a=c();65279===n.charCodeAt(0)&&(n=n.substring(1)),a.styleSheet?a.styleSheet.cssText+=n:a.appendChild(document.createTextNode(n))}function c(){var e=document.createElement(\"style\");if(e.setAttribute(\"type\",\"text/css\"),r.attributes)for(var t=Object.keys(r.attributes),n=0;n<t.length;n++)e.setAttribute(t[n],r.attributes[t[n]]);var a=\"prepend\"===s?\"afterbegin\":\"beforeend\";return i.insertAdjacentElement(a,e),e}}export{n as default};\n","import { CSSProperties } from 'react';\n\ntype SpacingMultiplier = 0 | 0.5 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8;\ntype SpacingMultiplierStringOrNumber = `${SpacingMultiplier}` | SpacingMultiplier;\ntype MultiValueSpacingMultiplier =\n | `${SpacingMultiplier} ${SpacingMultiplier} ${SpacingMultiplier} ${SpacingMultiplier}`\n | `${SpacingMultiplier} ${SpacingMultiplier} ${SpacingMultiplier}`\n | `${SpacingMultiplier} ${SpacingMultiplier}`\n | SpacingMultiplierStringOrNumber;\n\nexport interface Spacing {\n padding?: MultiValueSpacingMultiplier;\n paddingTop?: SpacingMultiplierStringOrNumber;\n paddingBottom?: SpacingMultiplierStringOrNumber;\n paddingLeft?: SpacingMultiplierStringOrNumber;\n paddingRight?: SpacingMultiplierStringOrNumber;\n margin?: MultiValueSpacingMultiplier;\n marginTop?: SpacingMultiplierStringOrNumber;\n marginBottom?: SpacingMultiplierStringOrNumber;\n marginLeft?: SpacingMultiplierStringOrNumber;\n marginRight?: SpacingMultiplierStringOrNumber;\n}\n\nconst defaultFactor = 0.25;\nconst defaultUnit = 'rem';\nconst spacingNumberRegex = /(\\d+\\.?\\d*)+/g;\n\nexport const useSpacing = (\n spacingProps?: Spacing,\n style?: CSSProperties\n): CSSProperties | undefined => {\n if (spacingProps) {\n return Object.entries(spacingProps).reduce<CSSProperties>((prev, [spacing, multiplier]) => {\n const matches = String(multiplier).matchAll(spacingNumberRegex);\n const cssSpacingValue = Array.from(matches)\n .map(([multiplierValue]) => `${Number(multiplierValue) * defaultFactor}${defaultUnit}`)\n .join(' ');\n return { ...prev, [spacing]: cssSpacingValue };\n }, style ?? {});\n }\n return style;\n};\n","import React, { HTMLAttributes, ReactNode } from 'react';\nimport classes from './Typography.module.scss';\nimport { Spacing, useSpacing } from '../hooks/useSpacing';\n\nconst validVariants = ['h1', 'h2', 'h3', 'h4', 'body', 'body-bold', 'sub-text', 'code'] as const;\nexport type Variant = typeof validVariants[number];\n\nexport interface Props extends HTMLAttributes<HTMLElement> {\n children: ReactNode;\n variant: Variant;\n tag?:\n | 'h1'\n | 'h2'\n | 'h3'\n | 'h4'\n | 'p'\n | 'div'\n | 'code'\n | 'span'\n | 'sup'\n | 'sub'\n | 'strong'\n | 'em'\n | 'small'\n | 'mark'\n | 'del'\n | 'ins'\n | 'blockquote';\n spacing?: Spacing;\n}\n\nexport const Typography = ({\n children,\n variant,\n tag,\n style,\n spacing,\n className = '',\n ...rest\n}: Props) => {\n if (!validVariants.includes(variant)) {\n throw new Error(\n `You entered an invalid variant. You can choose from: ${validVariants}, you entered: ${variant}`\n );\n }\n\n const styleWithSpacing = useSpacing(spacing, style);\n\n if (!tag) {\n switch (variant) {\n case 'h1':\n case 'h2':\n case 'h3':\n case 'h4':\n case 'code':\n tag = variant;\n break;\n case 'body':\n tag = 'p';\n break;\n case 'body-bold':\n tag = 'p';\n break;\n case 'sub-text':\n tag = 'span';\n break;\n default:\n tag = 'div';\n break;\n }\n }\n\n let TagName = tag;\n\n return (\n <TagName\n {...rest}\n style={styleWithSpacing}\n className={`${classes['typography_style_' + variant]} ${className}`}\n >\n {children}\n </TagName>\n );\n};\n","import React, { RefObject } from 'react';\nimport classes from './BaseButton.module.scss';\n\nexport interface Props extends Omit<React.HTMLProps<HTMLButtonElement>, 'ref'> {\n type?: 'submit' | 'button' | 'reset';\n disabled?: boolean;\n ref?: RefObject<HTMLButtonElement>;\n color?: 'primary' | 'secondary' | 'tertiary' | 'default';\n}\n\nexport const BaseButton = React.forwardRef<HTMLButtonElement, Props>(\n ({ children, type = 'button', className, ...rest }, ref) => {\n const validTypes = ['submit', 'button', 'reset'];\n\n if (!validTypes.includes(type))\n throw new Error(\n `You have entered an invalid button type. Expected 'submit', 'button' or 'reset' got ${type}`\n );\n\n return (\n <button\n {...rest}\n ref={ref}\n type={type}\n className={`${classes.button} ${className ? className : ''}`}\n >\n {children}\n </button>\n );\n }\n);\n","import React, { RefObject } from 'react';\nimport { BaseButton, Props as BaseButtonProps } from './BaseButton';\nimport classes from './Button.module.scss';\n\nexport interface Props extends Omit<BaseButtonProps, 'ref'> {\n startIcon?: React.ReactNode | false;\n endIcon?: React.ReactNode | false;\n children?: React.ReactNode;\n variant?: 'text' | 'fill' | 'outline';\n ref?: RefObject<HTMLButtonElement>;\n}\n\nexport const Button = React.forwardRef<HTMLButtonElement, Props>(\n (\n { children, variant = 'fill', color = 'primary', startIcon = false, endIcon = false, ...rest },\n ref\n ) => {\n const additionalClasses = [];\n\n if (startIcon || endIcon) {\n additionalClasses.push(classes['has-icon']);\n }\n\n if (startIcon) {\n additionalClasses.push(classes['start-icon']);\n }\n\n if (endIcon) {\n additionalClasses.push(classes['end-icon']);\n }\n\n return (\n <BaseButton\n {...rest}\n ref={ref}\n className={`${classes[color]} ${classes[variant]} ${additionalClasses.join(' ')}`}\n >\n {startIcon && <i>{startIcon}&nbsp;</i>}\n <span>{children}</span>\n {endIcon && <i>&nbsp;{endIcon}</i>}\n </BaseButton>\n );\n }\n);\n","import React, { ForwardRefExoticComponent, Ref, RefAttributes } from 'react';\nimport { HTMLProps } from '../interfaces';\nimport classes from './Link.module.scss';\nimport { LinkProps } from './types';\n\ntype AnchorType = 'external' | 'internal' | 'download';\n\nexport interface Props extends HTMLProps<HTMLAnchorElement> {\n children?: string;\n color?: 'primary' | 'secondary' | 'tertiary';\n type?: AnchorType;\n to: string;\n disabled?: boolean;\n component?: ForwardRefExoticComponent<LinkProps & RefAttributes<HTMLAnchorElement>>;\n ref?: Ref<HTMLAnchorElement>;\n}\n\nexport const Link = React.forwardRef(\n (\n {\n children,\n className,\n disabled = false,\n to,\n color = 'primary',\n type = 'internal',\n component,\n ...rest\n }: Props,\n ref: Ref<HTMLAnchorElement>\n ) => {\n const determineTarget = () => {\n if (rest.target) {\n return rest.target;\n }\n\n if (type === 'external') {\n return '_blank';\n }\n\n return '';\n };\n\n const classNames = [classes['link'], classes[color]];\n disabled && classNames.push(classes['disabled']);\n className && classNames.push(className);\n\n if (component) {\n return React.createElement(component, {\n ...rest,\n ref: ref,\n to: to,\n className: classNames.join(' '),\n 'aria-disabled': disabled,\n style: {\n ...rest.style,\n },\n children: children,\n });\n }\n\n return (\n <a\n {...rest}\n ref={ref}\n download={type === 'download'}\n rel={type === 'external' ? 'noopener noreferer' : undefined}\n href={!disabled ? to : undefined}\n className={classNames.join(' ')}\n aria-disabled={disabled}\n target={determineTarget()}\n style={{\n ...rest.style,\n }}\n >\n {children}\n </a>\n );\n }\n);\n","import React, { Fragment, RefObject } from 'react';\nimport { BaseButton, Props as BaseButtonProps } from './BaseButton';\nimport classes from './IconButton.module.scss';\nimport readyclasses from '../readyclasses.module.scss';\n\nexport interface Props extends Omit<BaseButtonProps, 'ref'> {\n children?: React.ReactNode;\n iconSize?: 's' | 'm' | 'l';\n className?: string;\n title?: string;\n ref?: RefObject<HTMLButtonElement>;\n}\n\nexport const IconButton = React.forwardRef<HTMLButtonElement, Props>(\n ({ children, color = 'primary', iconSize = 'm', title, ...rest }, ref) => {\n if (!title) {\n console.error(\"Please make sure to specify a 'title' prop to your IconButton component! \");\n }\n\n return (\n <BaseButton\n {...rest}\n ref={ref}\n className={`${classes['icon-button']} ${classes[color]} ${classes['button-' + iconSize]}`}\n >\n <Fragment>\n {children}\n <span className={readyclasses['sr-only']}>{title}</span>\n </Fragment>\n </BaseButton>\n );\n }\n);\n","import React from 'react';\nimport classes from './Icon.module.scss';\nimport { HTMLAttributes } from '../interfaces';\n\nexport enum Icons {\n Bell = 'bell',\n BellAlt = 'bell-alt',\n Bookmark = 'bookmark',\n BookmarkAlt = 'bookmark-alt',\n Build = 'build',\n Calendar = 'calendar',\n Change = 'change',\n Checkmark = 'checkmark',\n CheckmarkCircle = 'checkmark-circle',\n CheckmarkCircleAlt = 'checkmark-circle-alt',\n CheckmarkCircleBreakout = 'checkmark-circle-breakout',\n CheckmarkSquare = 'checkmark-square',\n ChevronUp = 'chevron-up',\n ChevronDown = 'chevron-down',\n ChevronLeft = 'chevron-left',\n ChevronRight = 'chevron-right',\n Circle = 'circle',\n Clock = 'clock',\n Copy = 'copy',\n Edit = 'edit',\n Ellipsis = 'ellipsis',\n EllipsisAlt = 'ellipsis-alt',\n Equal = 'equal',\n Eye = 'eye',\n Filter = 'filter',\n FilterAlt = 'filter-alt',\n FilterAltArrow = 'filter-alt-arrow',\n FilterAltTimes = 'filter-alt-times',\n Forbidden = 'forbidden',\n Fullscreen = 'fullscreen',\n FullscreenExit = 'fullscreen-exit',\n Gearwheel = 'gearwheel',\n Grid = 'grid',\n Hamburger = 'hamburger',\n Heart = 'heart',\n Image = 'image',\n InfoBell = 'info-bell',\n InfoCircle = 'info-circle',\n Link = 'link',\n MinusSquare = 'minus-square',\n NavigationFirst = 'navigation-first',\n NavigationLast = 'navigation-last',\n Plus = 'plus',\n Radio = 'radio',\n Refresh = 'refresh',\n Search = 'search',\n Share = 'share',\n Square = 'square',\n Star = 'star',\n StarAlt = 'star-alt',\n Times = 'times',\n TimesCircle = 'times-circle',\n TimesCircleAlt = 'times-circle-alt',\n TimesThin = 'times-thin',\n Trash = 'trash',\n TriangleDown = 'triangle-down',\n TriangleDownCircle = 'triangle-down-circle',\n TriangleLeft = 'triangle-left',\n TriangleRight = 'triangle-right',\n TriangleUp = 'triangle-up',\n Undo = 'undo',\n Warning = 'warning',\n}\n\ntype Tag = 'span' | 'div' | 'i';\n\nexport interface Props extends Omit<HTMLAttributes<HTMLOrSVGElement>, 'size'> {\n icon: Icons;\n color?: string;\n size?: string;\n tag?: Tag;\n}\n\nexport const Icon = React.forwardRef(\n ({ icon, color, className, style, size, tag = 'span', ...rest }: Props, ref) => {\n const Component = tag;\n\n return (\n <Component\n {...rest}\n ref={ref as React.LegacyRef<HTMLDivElement>}\n style={{ color: color, ...style, fontSize: size }}\n data-icon\n aria-hidden=\"true\"\n className={`${classes['icon']} ${classes['icon-' + icon]} ${className ? className : ''}`}\n />\n );\n }\n);\n","export const labelId = (id: string) => `${id}-label`;\nexport const descriptionId = (id: string) => `${id}-description`;\n","import React, { useEffect } from 'react';\nimport { createPortal } from 'react-dom';\nimport { HTMLAttributes } from '../../interfaces';\nimport classes from './BaseModal.module.scss';\nimport { labelId, descriptionId } from './BaseModalContext';\n\nconst SCROLL_PROPERTY_NAME = 'overflow';\nconst SCROLL_PROPERTY_VALUE = 'hidden';\n\nexport interface Props extends HTMLAttributes<HTMLDivElement> {\n id: string;\n children: React.ReactNode;\n open: boolean;\n onClose?: (event?: React.MouseEvent<HTMLElement>) => unknown;\n className?: string;\n containerClassName?: string;\n labelledby?: string;\n describedby?: string;\n disableEscapeKeyDown?: boolean;\n disableBackdrop?: boolean;\n zIndex?: number;\n domRoot?: HTMLElement;\n}\n\nexport const useSetBodyScroll = (open: boolean) => {\n const hideBodyScroll = () => {\n document.body.style[SCROLL_PROPERTY_NAME] = SCROLL_PROPERTY_VALUE;\n };\n\n const showBodyScroll = () => {\n const allModalsClosed =\n document.querySelectorAll('[role=dialog][data-hidden=false]').length === 0;\n if (allModalsClosed) {\n document.body.style.removeProperty(SCROLL_PROPERTY_NAME);\n }\n };\n\n useEffect(() => {\n if (open) {\n hideBodyScroll();\n } else {\n showBodyScroll();\n }\n }, [open]);\n};\n\nexport const BaseModal = ({\n id,\n children,\n open,\n onClose,\n className = '',\n containerClassName = '',\n labelledby,\n describedby,\n disableEscapeKeyDown = false,\n disableBackdrop = false,\n zIndex,\n domRoot = document.body,\n ...restProps\n}: Props) => {\n useSetBodyScroll(open);\n\n const handleEscKeyPress = (event: React.KeyboardEvent<HTMLDivElement>) => {\n if (!disableEscapeKeyDown && event.key === 'Escape') {\n event.stopPropagation();\n onClose && onClose();\n }\n };\n\n const handleBackdropClick = () => !disableBackdrop && onClose && onClose();\n\n return createPortal(\n <div\n {...restProps}\n id={id}\n className={`${classes['modal']} ${open && classes['visible']} ${className}`}\n role=\"dialog\"\n aria-modal=\"true\"\n aria-labelledby={labelledby || labelId(id)}\n aria-describedby={describedby || descriptionId(id)}\n aria-hidden={!open}\n tabIndex={-1}\n data-hidden={!open}\n onKeyDown={handleEscKeyPress}\n style={{ zIndex }}\n >\n <div className={classes['backdrop']} onClick={handleBackdropClick}></div>\n {open && (\n <div\n style={{ zIndex: zIndex && zIndex + 1 }}\n className={`${classes['container']} ${containerClassName}`}\n >\n {children}\n </div>\n )}\n </div>,\n domRoot\n );\n};\n","import React, { HTMLAttributes, useEffect, useRef } from 'react';\nimport classes from './BaseModalContent.module.scss';\n\nexport interface Props extends HTMLAttributes<HTMLDivElement> {\n id?: string;\n children: React.ReactNode;\n className?: string;\n disableAutoFocus?: boolean;\n}\n\nexport const BaseModalContent = ({\n id,\n children,\n className = '',\n disableAutoFocus = false,\n ...restProps\n}: Props) => {\n const contentRef = useRef<HTMLDivElement>(null);\n useEffect(() => {\n !disableAutoFocus && contentRef.current?.focus();\n }, []);\n\n /**tabIndex is set to be able to do focus on that element which we need for catching keyDown events */\n return (\n <div\n {...restProps}\n ref={contentRef}\n id={id}\n className={`${classes['content']} ${className}`}\n tabIndex={-1}\n >\n {children}\n </div>\n );\n};\n","import React, { HTMLAttributes } from 'react';\nimport classes from './BaseModalActions.module.scss';\n\nexport interface Props extends HTMLAttributes<HTMLElement> {\n children?: React.ReactNode;\n}\n\nexport const BaseModalActions = ({ children, className = '', ...restProps }: Props) => {\n return (\n <footer {...restProps} className={`${classes['actions']} ${className}`}>\n {children}\n </footer>\n );\n};\n","import React from 'react';\nimport {\n BaseModalActions,\n Props as BaseModalActionsProps,\n} from '../../BaseModal/BaseModalActions/BaseModalActions';\nimport classes from './DialogActions.module.scss';\n\nexport interface Props extends BaseModalActionsProps {\n align: 'left' | 'right';\n}\n\nexport const DialogActions = ({ children, align, ...restProps }: Props) => {\n return (\n <BaseModalActions\n {...restProps}\n className={`${classes['actions']}${align === 'left' ? ' ' + classes['left'] : ''}`}\n >\n {children}\n </BaseModalActions>\n );\n};\n","import React from 'react';\nimport { Typography } from '../../../Typography/Typography';\nimport classes from './DialogTitle.module.scss';\n\nexport interface Props {\n id: string;\n title: string;\n}\n\nexport const DialogTitle = ({ id, title }: Props) => {\n return (\n <div className={classes['header']}>\n <Typography id={id} className={classes['title']} tag=\"h1\" variant=\"h4\">\n {title}\n </Typography>\n </div>\n );\n};\n","export const generateID = (length = 15, stringToWeaveIn?: string) => {\n /** We will make sure to mesh the generate id and name property together to basically create a unique ID */\n let hashCharacters = [\n '1',\n '2',\n '3',\n '4',\n '5',\n '6',\n '7',\n '8',\n '9',\n '0',\n 'A',\n 'B',\n 'C',\n 'D',\n 'E',\n 'F',\n 'G',\n 'H',\n 'I',\n 'J',\n 'K',\n 'L',\n 'M',\n 'N',\n 'O',\n 'P',\n 'Q',\n 'R',\n 'S',\n 'T',\n 'U',\n 'V',\n 'W',\n 'X',\n 'Y',\n 'Z',\n 'a',\n 'b',\n 'c',\n 'd',\n 'e',\n 'f',\n 'g',\n 'h',\n 'i',\n 'j',\n 'k',\n 'l',\n 'm',\n 'n',\n 'o',\n 'p',\n 'q',\n 'r',\n 's',\n 't',\n 'u',\n 'v',\n 'w',\n 'x',\n 'y',\n 'z',\n ];\n\n let id = '';\n\n /** Generate an id of x characters in length */\n for (let i = 0; i < length && id.length < length; i++) {\n let stringCharacter =\n stringToWeaveIn && stringToWeaveIn[i] !== undefined && !/\\s/.test(stringToWeaveIn[i])\n ? stringToWeaveIn[i]\n : '';\n id = id + stringCharacter + hashCharacters[Math.floor(Math.random() * hashCharacters.length)];\n }\n\n return id.slice(0, length);\n};\n","import React, { HTMLAttributes, useState } from 'react';\nimport { BaseModal } from '../BaseModal/BaseModal';\nimport { BaseModalContent } from '../BaseModal/BaseModalContent/BaseModalContent';\nimport { DialogActions } from './DialogActions/DialogActions';\nimport classes from './Dialog.module.scss';\nimport { DialogTitle } from './DialogTitle/DialogTitle';\nimport { Button, Props as ButtonProps } from '../../Button/Button';\nimport { labelId, descriptionId } from '../BaseModal/BaseModalContext';\nimport { generateID } from '../../util/helper';\n\nexport interface Props extends HTMLAttributes<HTMLDivElement> {\n id?: string;\n open: boolean;\n children: React.ReactNode;\n alignActions: 'left' | 'right';\n onClose: () => void;\n title: string;\n primaryAction: Action;\n secondaryAction?: Action;\n zIndex?: number;\n disableEscapeKeyDown?: boolean;\n}\n\nexport interface Action extends Omit<ButtonProps, 'variant' | 'ref'> {\n label: string;\n onClick: (event?: React.MouseEvent<HTMLButtonElement>) => unknown;\n}\n\nexport const Dialog = ({\n id,\n open,\n children,\n alignActions,\n onClose,\n title,\n primaryAction,\n secondaryAction,\n zIndex,\n disableEscapeKeyDown = true,\n ...restProps\n}: Props) => {\n const [dialogId] = useState(id ?? generateID(20));\n const { label: primaryLabel, ...restOfPrimaryAction } = primaryAction;\n const PrimaryButton = (\n <Button key=\"primary\" {...restOfPrimaryAction}>\n {primaryLabel}\n </Button>\n );\n const TertiaryButton =\n secondaryAction &&\n (function () {\n const { label: secondaryLabel, ...restOfSecondaryAction } = secondaryAction;\n return (\n <Button key=\"tertiary\" variant=\"text\" {...restOfSecondaryAction}>\n {secondaryLabel}\n </Button>\n );\n })();\n\n const onHiddenInputKeyPress = (event: React.KeyboardEvent<HTMLInputElement>) => {\n /** It has to be here because then we will need to check if user doesn't click tab to select action button and want to do another action then primary one? */\n if (event.key === 'Enter') {\n primaryAction.onClick();\n }\n };\n\n return (\n <BaseModal\n {...restProps}\n id={dialogId}\n className={classes['dialog']}\n containerClassName={classes['container']}\n open={open}\n disableBackdrop\n onClose={onClose}\n zIndex={zIndex}\n disableEscapeKeyDown={disableEscapeKeyDown}\n >\n <DialogTitle id={labelId(dialogId)} title={title} />\n <BaseModalContent\n id={descriptionId(dialogId)}\n className={classes['content']}\n disableAutoFocus\n >\n {children}\n </BaseModalContent>\n <DialogActions align={alignActions}>\n {alignActions === 'left'\n ? [PrimaryButton, TertiaryButton]\n : [TertiaryButton, PrimaryButton]}\n </DialogActions>\n <input\n autoFocus\n aria-hidden={true}\n style={{\n position: 'absolute',\n width: 0,\n height: 0,\n opacity: 0,\n }}\n maxLength={0}\n tabIndex={-1}\n onKeyPress={onHiddenInputKeyPress}\n />\n </BaseModal>\n );\n};\n","import React, { HTMLAttributes } from 'react';\nimport classes from './BaseModalHeader.module.scss';\nimport { IconButton } from '../../../Button/IconButton';\nimport { Icon, Icons } from '../../../Icon/Icon';\nimport { Typography } from '../../../Typography/Typography';\n\nexport interface Props extends HTMLAttributes<HTMLDivElement> {\n id: string;\n title: string;\n children?: React.ReactNode;\n onClose: (event: React.MouseEvent<HTMLButtonElement>) => void;\n}\n\nexport const BaseModalHeader = ({ id, title, children, onClose, ...restProps }: Props) => {\n return (\n <div {...restProps} className={classes['header']}>\n <div className={classes['headline']}>\n <Typography id={id} className={classes['title']} tag=\"h1\" variant=\"h4\">\n {title}\n </Typography>\n <IconButton onClick={onClose} className={classes['closeBtn']} title=\"close modal\">\n <Icon icon={Icons.Times} />\n </IconButton>\n </div>\n {children}\n </div>\n );\n};\n","import React from 'react';\nimport { Dialog } from '../../Dialog/Dialog';\nimport { HTMLProps } from '../../../interfaces';\nimport { Typography } from '../../../Typography/Typography';\n\nexport interface Props extends Omit<HTMLProps<HTMLDivElement>, 'children'> {\n open: boolean;\n discardChangesButtonLabel: string;\n keepEditingButtonLabel: string;\n contentLabel: string;\n titleLabel: string;\n onKeepEditing: () => void;\n onDiscardChanges: () => void;\n}\n\nexport const DiscardChangesDialog = ({\n open,\n onKeepEditing,\n onDiscardChanges,\n discardChangesButtonLabel,\n keepEditingButtonLabel,\n contentLabel,\n titleLabel,\n ...rest\n}: Props) => {\n return (\n <Dialog\n {...rest}\n open={open}\n alignActions=\"left\"\n title={titleLabel}\n onClose={onKeepEditing}\n primaryAction={{\n label: discardChangesButtonLabel,\n onClick: onDiscardChanges,\n }}\n secondaryAction={{\n label: keepEditingButtonLabel,\n onClick: onKeepEditing,\n }}\n disableEscapeKeyDown={false}\n >\n <Typography variant=\"body\" spacing={{ margin: 0 }}>\n {contentLabel}\n </Typography>\n </Dialog>\n );\n};\n","import React, { useState } from 'react';\n\nexport interface ConfigObject {\n relativeElement: RefElement;\n elementToBePositioned: RefElement;\n transformOrigin?: Placement;\n placement?: Placement;\n offset?: Offset;\n}\n\nexport type HorizontalPlacment = 'left' | 'center' | 'centerh' | 'right';\nexport type VerticalPlacement = 'top' | 'center' | 'centerv' | 'bottom';\n\ntype Axis = 'vertical' | 'horizontal';\ntype RefElement = React.RefObject<HTMLOrSVGElement> | undefined;\n\ninterface DomRectObject {\n top: number;\n right: number;\n bottom: number;\n left: number;\n center: number;\n centerh: number;\n centerv: number;\n width: number;\n height: number;\n x: number;\n y: number;\n}\n\nexport interface Placement {\n horizontal: HorizontalPlacment;\n vertical: VerticalPlacement;\n}\n\nexport interface Offset {\n top: number;\n right: number;\n bottom: number;\n left: number;\n}\n\nexport interface Position {\n top: PositionType;\n right: PositionType;\n bottom: PositionType;\n left: PositionType;\n}\n\ninterface Dimensions {\n height: number;\n width: number;\n}\n\ntype PositionType = number | 'initial';\n\nconst defaultConfigObject: ConfigObject = {\n relativeElement: undefined,\n elementToBePositioned: undefined,\n transformOrigin: {\n horizontal: 'left',\n vertical: 'top',\n },\n placement: {\n horizontal: 'left',\n vertical: 'top',\n },\n offset: {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0,\n },\n};\n\nexport const usePosition = (providedConfigObject: ConfigObject = defaultConfigObject) => {\n const configObject = { ...defaultConfigObject, ...providedConfigObject };\n\n if (configObject.transformOrigin === undefined) {\n configObject.transformOrigin = defaultConfigObject.transformOrigin;\n }\n\n if (configObject.placement === undefined) {\n configObject.placement = defaultConfigObject.placement;\n }\n\n if (configObject.offset === undefined) {\n configObject.offset = defaultConfigObject.offset;\n }\n\n const [position, setPosition] = useState<Position>({\n left: 0,\n top: 0,\n right: 'initial',\n bottom: 'initial',\n });\n\n const _fixPossibleViewportOverflow = (\n value: number,\n transformOrigin: Placement,\n requestedReturnValue: Axis,\n elDimensions: Dimensions\n ) => {\n let returnValue = value;\n\n if (\n (transformOrigin[requestedReturnValue] === 'left' && returnValue < 0) ||\n (transformOrigin[requestedReturnValue] === 'top' && returnValue < 0) ||\n (transformOrigin[requestedReturnValue] === 'center' && returnValue < 0) ||\n (transformOrigin[requestedReturnValue] === 'bottom' && returnValue < 0)\n ) {\n returnValue = 0;\n }\n\n if (\n (transformOrigin[requestedReturnValue] === 'left' &&\n returnValue > window.innerWidth - elDimensions.width) ||\n (transformOrigin[requestedReturnValue] === 'center' &&\n requestedReturnValue === 'horizontal' &&\n returnValue > window.innerWidth - elDimensions.width)\n ) {\n returnValue = window.innerWidth - elDimensions.width;\n }\n\n if (\n (transformOrigin[requestedReturnValue] === 'top' &&\n returnValue > window.innerHeight - elDimensions.height) ||\n (transformOrigin[requestedReturnValue] === 'center' &&\n requestedReturnValue === 'vertical' &&\n returnValue > window.innerHeight - elDimensions.height)\n ) {\n returnValue = window.innerHeight - elDimensions.height;\n }\n\n if (\n transformOrigin[requestedReturnValue] === 'right' &&\n returnValue > window.innerWidth - elDimensions.width\n ) {\n returnValue = window.innerWidth - elDimensions.width;\n }\n\n if (\n transformOrigin[requestedReturnValue] === 'bottom' &&\n returnValue > window.innerHeight - elDimensions.height\n ) {\n returnValue = window.innerHeight - elDimensions.height;\n }\n\n return returnValue;\n };\n\n const _applyOffsetToPlacementValue = (\n value: number,\n requestedReturnValue: Axis,\n transformOrigin: Placement\n ) => {\n let returnValue = value;\n if (\n (requestedReturnValue === 'horizontal' && configObject.offset?.left !== 0) ||\n (requestedReturnValue === 'horizontal' && configObject.offset?.right !== 0)\n ) {\n if (\n transformOrigin[requestedReturnValue] === 'left' ||\n transformOrigin[requestedReturnValue] === 'center'\n ) {\n returnValue += configObject.offset?.left!;\n returnValue -= configObject.offset?.right!;\n }\n\n if (transformOrigin[requestedReturnValue] === 'right') {\n returnValue -= configObject.offset?.left!;\n returnValue += configObject.offset?.right!;\n }\n }\n\n if (\n (requestedReturnValue === 'vertical' && configObject.offset?.top !== 0) ||\n (requestedReturnValue === 'vertical' && configObject.offset?.bottom !== 0)\n ) {\n if (\n transformOrigin[requestedReturnValue] === 'top' ||\n transformOrigin[requestedReturnValue] === 'center'\n ) {\n returnValue += configObject.offset?.top!;\n returnValue -= configObject.offset?.bottom!;\n }\n\n if (transformOrigin[requestedReturnValue] === 'bottom') {\n returnValue -= configObject.offset?.top!;\n returnValue += configObject.offset?.bottom!;\n }\n }\n\n return returnValue;\n };\n\n const _calculateInitialPlacementValue = (\n transformOrigin: Placement,\n requestedReturnValue: Axis,\n relEl: DomRectObject,\n placementOriginDefinition: HorizontalPlacment | VerticalPlacement,\n elDimensions: Dimensions\n ) => {\n let value = 0;\n\n if (\n transformOrigin[requestedReturnValue] === 'left' ||\n transformOrigin[requestedReturnValue] === 'top'\n ) {\n value = relEl[placementOriginDefinition];\n } else if (transformOrigin[requestedReturnValue] === 'center') {\n value =\n relEl[placementOriginDefinition] -\n elDimensions[requestedReturnValue === 'horizontal' ? 'width' : 'height'] / 2;\n } else if (\n transformOrigin[requestedReturnValue] === 'right' ||\n transformOrigin[requestedReturnValue] === 'bottom'\n ) {\n value =\n window[requestedReturnValue === 'horizontal' ? 'innerWidth' : 'innerHeight'] -\n relEl[placementOriginDefinition];\n }\n\n return value;\n };\n\n /**\n *\n * @param requestedReturnValue whether the requested return value is for the horizontal or vertical axis\n * @returns either the horizontally centered placement definition (centerh) or the vertically centered one (centerv)\n */\n const _determineCenteredPlacementOrigin = (requestedReturnValue: Axis) => {\n if (requestedReturnValue === 'horizontal') {\n return 'centerh';\n } else if (requestedReturnValue === 'vertical') {\n return 'centerv';\n }\n throw new Error(\n `the requested return value isn\\'t \"vertical\" or \"horizontal\" ${requestedReturnValue} was given.`\n );\n };\n\n const _calculatePlacementValue = (\n transformOrigin: Placement,\n placement: HorizontalPlacment | VerticalPlacement,\n requestedReturnValue: Axis,\n relEl: DomRectObject,\n elDimensions: Dimensions\n ): number => {\n const placementOriginDefinition =\n placement === 'center' ? _determineCenteredPlacementOrigin(requestedReturnValue) : placement;\n\n const value = _calculateInitialPlacementValue(\n transformOrigin,\n requestedReturnValue,\n relEl,\n placementOriginDefinition,\n elDimensions\n );\n\n const valueWithOffset = _applyOffsetToPlacementValue(\n value,\n requestedReturnValue,\n transformOrigin\n );\n\n const valueCorrectionForViewportOverflow = _fixPossibleViewportOverflow(\n valueWithOffset,\n transformOrigin,\n requestedReturnValue,\n elDimensions\n );\n\n return valueCorrectionForViewportOverflow;\n };\n\n const _calculatePlacement = (relEl: DomRectObject, elDimensions: Dimensions, axis: Axis) => {\n const placementValue = _calculatePlacementValue(\n configObject.transformOrigin!,\n configObject.placement![axis]!,\n axis,\n relEl,\n elDimensions\n );\n\n let direction = 'left';\n let oppositeDirection = 'right';\n\n if (axis === 'horizontal' && configObject.transformOrigin?.horizontal === 'right') {\n direction = 'right';\n oppositeDirection = 'left';\n } else if (axis === 'horizontal') {\n direction = 'left';\n oppositeDirection = 'right';\n }\n\n if (axis === 'vertical' && configObject.transformOrigin?.vertical === 'bottom') {\n direction = 'bottom';\n oppositeDirection = 'top';\n } else if (axis === 'vertical') {\n direction = 'top';\n oppositeDirection = 'bottom';\n }\n\n setPosition((prevState) => ({\n ...prevState,\n [direction]: placementValue,\n [oppositeDirection]: 'initial',\n }));\n };\n\n const calculatePosition = () => {\n if (!configObject.relativeElement?.current) return;\n const relativeElRect = (configObject.relativeElement!\n .current as HTMLElement)!.getBoundingClientRect();\n const elementToBePositionedDimensions: Dimensions = {\n height: (configObject.elementToBePositioned!.current as HTMLElement).offsetHeight,\n width: (configObject.elementToBePositioned!.current as HTMLElement).offsetWidth,\n };\n\n /** We want to add a center (horizontal and vertical) property to the DOMRect object. Since it's a special object we can't modify so we clone it and add it. */\n const clonedRelEl = {\n top: relativeElRect.top,\n right: relativeElRect.right,\n bottom: relativeElRect.bottom,\n center: 0,\n centerv: relativeElRect.top + relativeElRect.height / 2,\n centerh: relativeElRect.left + relativeElRect.width / 2,\n left: relativeElRect.left,\n width: relativeElRect.width,\n height: relativeElRect.height,\n x: relativeElRect.x,\n y: relativeElRect.y,\n };\n\n _calculatePlacement(clonedRelEl, elementToBePositionedDimensions, 'horizontal');\n _calculatePlacement(clonedRelEl, elementToBePositionedDimensions, 'vertical');\n };\n\n return {\n top: position.top,\n bottom: position.bottom,\n left: position.left,\n right: position.right,\n calculatePosition,\n };\n};\n","import React, { HTMLProps, ReactNode, useEffect, useLayoutEffect, useRef, useState } from 'react';\nimport { Icon, Icons } from '../Icon/Icon';\nimport classes from './Tooltip.module.scss';\nimport { generateID } from '../util/helper';\nimport { Offset, Placement, usePosition } from '../hooks/usePosition';\nimport { createPortal } from 'react-dom';\n\nexport interface Props extends Omit<HTMLProps<HTMLDivElement>, 'label'> {\n label: string | ReactNode;\n children: string;\n placement?: Placement;\n offset?: Offset;\n transformOrigin?: Placement;\n domRoot?: HTMLElement;\n}\n\ninterface DefaultPosition {\n placement: Placement;\n offset: Offset;\n transformOrigin: Placement;\n}\n\nconst defaultPosition: DefaultPosition = {\n placement: { horizontal: 'right', vertical: 'center' },\n offset: { left: 16, right: 0, top: 0, bottom: 0 },\n transformOrigin: { horizontal: 'left', vertical: 'center' },\n};\n\nexport const Tooltip = ({\n children,\n className,\n placement = defaultPosition.placement,\n offset = defaultPosition.offset,\n transformOrigin = defaultPosition.transformOrigin,\n domRoot = document.body,\n label,\n ...rest\n}: Props) => {\n const [identifier] = useState(generateID());\n const [visible, setVisible] = useState(false);\n\n const relativeElement = useRef<HTMLOrSVGElement>(null);\n const elementToBePositioned = useRef<HTMLDivElement>(null);\n\n const { top, bottom, right, left, calculatePosition } = usePosition({\n relativeElement: relativeElement,\n elementToBePositioned: elementToBePositioned,\n placement: placement,\n offset: offset,\n transformOrigin: transformOrigin,\n });\n\n useEffect(() => {\n if (!visible) return;\n\n function escapePressHandler(event: KeyboardEvent) {\n if (event.key === 'Escape') {\n setVisible(false);\n }\n }\n\n document.addEventListener('keyup', escapePressHandler);\n\n return () => {\n document.removeEventListener('keyup', escapePressHandler);\n };\n }, [visible]);\n\n useLayoutEffect(() => {\n calculatePosition();\n }, [visible]);\n\n const renderChildren = () => {\n if (React.isValidElement(label)) {\n return React.cloneElement(label, {\n onFocus: () => setVisible(true),\n onBlur: () => setVisible(false),\n 'aria-describedby': identifier,\n tabIndex: 0,\n className: classes['label'],\n });\n }\n\n return (\n <span\n className={classes['label']}\n tabIndex={0}\n onFocus={() => setVisible(true)}\n onBlur={() => setVisible(false)}\n aria-describedby={identifier}\n >\n {label}\n </span>\n );\n };\n\n return (\n <div {...rest} className={`${classes.wrapper} ${className ?? ''}`}>\n {renderChildren()}\n <div className={`${classes['tooltip-wrapper']}`}>\n <Icon\n ref={relativeElement}\n tag=\"div\"\n onMouseEnter={() => setVisible(true)}\n onMouseLeave={() => setVisible(false)}\n icon={Icons.InfoCircle}\n className={classes.icon}\n />\n {createPortal(\n <div\n ref={elementToBePositioned}\n style={{\n ...rest.style,\n top: top,\n left: left,\n right: right,\n bottom: bottom,\n }}\n aria-hidden={!visible}\n id={identifier}\n className={`${classes.tooltip} ${visible ? classes.visible : ''}`}\n >\n {children}\n </div>,\n domRoot\n )}\n </div>\n </div>\n );\n};\n","import React, { HTMLProps, ReactElement, useState } from 'react';\nimport { Icon, Icons } from '../Icon/Icon';\nimport classes from './Tile.module.scss';\nimport readyClasses from '../readyclasses.module.scss';\n\nimport { Props as ContextMenuProps } from '../ContextMenu/ContextMenu';\nimport { generateID } from '../util/helper';\nimport { Props as IconButtonProps } from '../Button/IconButton';\n\ninterface ImageProps {\n src: string;\n}\n\nexport interface Props extends Omit<HTMLProps<HTMLDivElement>, 'contextMenu'> {\n title: string;\n imageProps?: ImageProps;\n enabled?: boolean;\n loading?: boolean;\n tileAction?: ReactElement<ContextMenuProps> | ReactElement<IconButtonProps>;\n}\n\nexport const Tile = ({\n title,\n imageProps,\n enabled,\n className,\n loading,\n tileAction,\n ...rest\n}: Props) => {\n const [tileDescriptionID] = useState(generateID(20));\n\n if (!title) {\n throw new Error('Please make sure to pass a title prop to your Tile component.');\n }\n\n const statusMessage = () => {\n if (enabled) {\n return 'Status: enabled';\n }\n\n return 'Status: disabled';\n };\n\n return (\n <article\n tabIndex={0}\n aria-labelledby={tileDescriptionID}\n {...rest}\n className={`${classes['tile']} ${loading ? classes['loading'] : ''}`}\n >\n <header style={{ justifyContent: enabled === undefined ? 'flex-end' : 'space-between' }}>\n {enabled === true && (\n <Icon\n color=\"var(--success)\"\n icon={Icons.Checkmark}\n className={`${classes['icon']} ${className ?? ''}`}\n />\n )}\n {enabled === false && (\n <Icon\n color=\"var(--greyed-out)\"\n icon={Icons.Forbidden}\n className={`${classes['icon']} ${className ?? ''}`}\n />\n )}\n {enabled !== undefined && (\n <span id={tileDescriptionID} className={readyClasses['sr-only']}>\n {`${title}. ${statusMessage()}`}\n </span>\n )}\n {tileAction ?? null}\n </header>\n <div className={classes['content']}>\n {imageProps && imageProps.src.length > 0 && (\n <figure className={classes['image']}>{!loading && <img {...imageProps} alt=\"\" />}</figure>\n )}\n {(!imageProps || imageProps.src.length === 0) && (\n <Icon className={classes['placeholder']} icon={Icons.Image} />\n )}\n <span className={classes['title']}>{title}</span>\n </div>\n </article>\n );\n};\n","import React, { forwardRef, HTMLProps, ReactNode, RefObject, useEffect, useRef } from 'react';\nimport { usePosition, Offset, Placement } from '../hooks/usePosition';\nimport classes from './Popover.module.scss';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n children?: ReactNode;\n show?: boolean;\n anchorEl?: RefObject<HTMLOrSVGElement>;\n placement?: Placement;\n offset?: Offset;\n transformOrigin?: Placement;\n}\n\nexport const Popover = forwardRef<HTMLDivElement, Props>(\n ({ children, className, show, placement, offset, transformOrigin, anchorEl, ...rest }, ref) => {\n const elToBePositioned = useRef<HTMLDivElement>(null);\n\n if (show === undefined) {\n throw new Error('Please make sure to define the \"show\" property on your Popover component');\n }\n\n const { top, left, right, bottom, calculatePosition } = usePosition({\n elementToBePositioned: elToBePositioned,\n relativeElement: anchorEl,\n offset: offset,\n placement: placement,\n transformOrigin: transformOrigin,\n });\n\n useEffect(() => {\n calculatePosition();\n }, [show]);\n\n return (\n <div ref={ref} {...rest}>\n <div\n ref={elToBePositioned}\n className={`${classes.popover} ${className ?? ''} ${show ? classes.show : ''}`}\n style={{ top: top, left: left, right: right, bottom: bottom }}\n >\n {children}\n </div>\n </div>\n );\n }\n);\n","import { useEffect } from 'react';\n\nexport const useBodyClick = (\n checkFunction: (event: MouseEvent) => boolean,\n callbackFunction: (...args: unknown[]) => unknown,\n dependingStateVariable: React.ComponentState | React.ComponentState[]\n) => {\n function bodyClickListener(event: MouseEvent) {\n if (checkFunction(event)) {\n callbackFunction();\n }\n }\n useEffect(() => {\n window.addEventListener('click', bodyClickListener);\n\n return () => {\n window.removeEventListener('click', bodyClickListener);\n };\n }, [dependingStateVariable]);\n};\n","import React, { createContext } from 'react';\nimport { SnackbarOptionsProps } from '../interfaces';\n\ninterface SnackbarContextProps {\n enqueueSnackbar: (title: string, content?: string, options?: SnackbarOptionsProps) => void;\n enqueueSuccessSnackbar: (title: string, content?: string, options?: SnackbarOptionsProps) => void;\n enqueueErrorSnackbar: (title: string, content?: string, options?: SnackbarOptionsProps) => void;\n}\n\nconst SnackbarContext = createContext<SnackbarContextProps>({\n enqueueSnackbar: () => null,\n enqueueSuccessSnackbar: () => null,\n enqueueErrorSnackbar: () => null,\n});\n\ninterface Props {\n initialState: SnackbarContextProps;\n children?: React.ReactNode;\n}\n\nconst SnackbarContextProvider = ({ children, initialState }: Props) => {\n return <SnackbarContext.Provider value={initialState}>{children}</SnackbarContext.Provider>;\n};\n\nexport { SnackbarContextProvider, SnackbarContext, SnackbarContextProps };\n","import React from 'react';\nimport classes from './SnackbarContainer.module.scss';\n\nexport interface Placement {\n vertical: 'top' | 'bottom';\n horizontal: 'start' | 'center' | 'end';\n}\n\nexport interface Props {\n placement: Placement;\n children?: React.ReactNode;\n zIndex?: number;\n className?: string;\n}\n\nexport const SnackbarContainer = ({ placement, children, zIndex, className, ...rest }: Props) => {\n return (\n <div\n {...rest}\n style={{ zIndex }}\n className={`${classes['snackbars']} ${classes[placement.horizontal]} ${\n classes[placement.vertical]\n } ${className ?? ''}`}\n >\n {children}\n </div>\n );\n};\n","import { useEffect, useRef, useState } from 'react';\n\nexport const useAnimation = <RefElement extends HTMLElement>(callback: () => void) => {\n const animatedObjectRef = useRef<RefElement>(null);\n /** We need to store flag that says us when to call the callback */\n const [animationStarted, setAnimationStarted] = useState(false);\n\n const onAnimationEnd = () => animationStarted && callback();\n\n useEffect(() => {\n animatedObjectRef.current?.addEventListener('animationend', onAnimationEnd);\n return () => animatedObjectRef.current?.removeEventListener('animationend', onAnimationEnd);\n }, [animationStarted]);\n\n return {\n ref: animatedObjectRef,\n animationStarted,\n startAnimation: () => setAnimationStarted(true),\n };\n};\n","import React, { useEffect, useRef } from 'react';\nimport { IconButton } from '../../../Button/IconButton';\nimport { Icon, Icons } from '../../../Icon/Icon';\nimport { Variant, Actions } from '../interfaces';\nimport classes from './SnackbarItem.module.scss';\nimport readyclasses from '../../../readyclasses.module.scss';\nimport { useAnimation } from '../../../hooks/useAnimation';\nimport { Typography } from '../../../Typography/Typography';\n\nconst textColor = 'var(--snackbar-text-color)';\n\nexport interface Props {\n id: string;\n title: string;\n duration: number;\n variant: Variant;\n onClose: (key: string) => void;\n closeButtonTitle: string;\n content?: string;\n actions?: Actions;\n}\n\nexport const SnackbarItem = ({\n id,\n title,\n duration,\n variant,\n content,\n actions = [],\n onClose,\n closeButtonTitle,\n}: Props) => {\n const timerHandler = useRef<ReturnType<typeof setTimeout>>();\n const onAnimationEnd = () => onClose(id);\n const { ref, animationStarted, startAnimation } = useAnimation<HTMLDivElement>(onAnimationEnd);\n\n useEffect(() => {\n timerHandler.current = setTimeout(() => startAnimation(), duration);\n return () => {\n timerHandler.current && clearTimeout(timerHandler.current);\n };\n }, []);\n\n const onMouseEnter = () => {\n timerHandler.current && clearTimeout(timerHandler.current);\n };\n\n const onMouseLeave = () => {\n timerHandler.current = setTimeout(() => startAnimation(), duration);\n };\n\n const getVariantIcon = () => {\n if (variant === 'error') {\n return Icons.TimesCircleAlt;\n }\n return variant === 'success' ? Icons.CheckmarkCircleBreakout : Icons.InfoCircle;\n };\n\n const actionButtons = actions.map((actionProp, index) => (\n <button\n key={index}\n {...actionProp}\n onClick={(e) => {\n onClose(id);\n actionProp.onClick && actionProp.onClick(e);\n }}\n children={actionProp.label}\n className={classes['action-button']}\n ></button>\n ));\n\n return (\n <div\n ref={ref}\n className={`${classes['snackbar']} ${classes[variant]} ${\n animationStarted ? readyclasses['slide-out'] : readyclasses['slide-in']\n }`}\n onMouseEnter={onMouseEnter}\n onMouseLeave={onMouseLeave}\n >\n <Icon icon={getVariantIcon()} className={classes['icon']} />\n <div className={classes['container']}>\n <div className={classes['headline']}>\n <Typography className={classes['title']} variant=\"h4\" tag=\"span\">\n {title}\n </Typography>\n <IconButton\n onClick={() => startAnimation()}\n className={classes['close-btn']}\n title={closeButtonTitle}\n >\n <Icon icon={Icons.Times} color={textColor} />\n </IconButton>\n </div>\n {!!content && (\n <Typography className={classes['content']} variant=\"body\">\n {content}\n </Typography>\n )}\n {actionButtons.length > 0 && <div className={classes['actions']}>{actionButtons}</div>}\n </div>\n </div>\n );\n};\n","import React, { ReactElement } from 'react';\nimport readyclasses from '../../readyclasses.module.scss';\nimport classes from './Fieldset.module.scss';\nimport { HTMLProps } from '../../interfaces';\nimport { Typography, Variant } from '../../Typography/Typography';\n\nexport interface Props extends HTMLProps<HTMLFieldSetElement> {\n children?: ReactElement | ReactElement[];\n legend: string;\n legendStyle?: Variant;\n hideLegend?: boolean;\n background?: string;\n noPadding?: boolean;\n noBackground?: boolean;\n required?: boolean;\n error?: boolean;\n}\n\nexport const Fieldset = ({\n children,\n className,\n legend,\n legendStyle = 'body',\n hideLegend = false,\n noBackground,\n background = noBackground ? '' : '#FFF',\n noPadding = false,\n disabled = false,\n required = false,\n error = false,\n ...rest\n}: Props) => {\n const renderChildren = () => {\n if (!children) return;\n\n return React.Children.map(children, (child: ReactElement) =>\n React.cloneElement(child, {\n disabled: child.props.disabled !== undefined ? child.props.disabled : disabled,\n error: child.props.error !== undefined ? child.props.error : error,\n })\n );\n };\n\n return (\n <fieldset\n {...rest}\n disabled={disabled}\n style={{ backgroundColor: background, ...rest.style }}\n className={`${classes.fieldset} ${noPadding ? classes['no-padding'] : ''} ${className ?? ''}`}\n >\n {legend && <legend className={readyclasses['sr-only']}>{legend}</legend>}\n {legend && !hideLegend && (\n <Typography\n variant={legendStyle}\n tag=\"span\"\n aria-hidden=\"true\"\n className={`${classes['legend']} ${required ? classes['required'] : ''} ${\n error ? classes['error'] : ''\n }`}\n >\n {legend}\n </Typography>\n )}\n {renderChildren()}\n </fieldset>\n );\n};\n","import React, { ReactNode } from 'react';\nimport classes from './FormHelperText.module.scss';\nimport { HTMLProps } from '../../interfaces';\nimport { Typography } from '../../Typography/Typography';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n children?: ReactNode;\n error?: boolean;\n}\n\nexport const FormHelperText = ({ children, error, className, ...rest }: Props) => {\n return (\n <Typography\n {...rest}\n variant=\"sub-text\"\n tag=\"div\"\n className={`${classes['form-helper-text']} ${error ? classes.error : ''} ${className ?? ''}`}\n >\n {children}\n </Typography>\n );\n};\n","/** The empty className property on FormHelperText is on purpose! We want to basically \"filter\" out the className from helperProps because we're adding this to the surrounding div. This makes it so also the errormessage receives this styling. */\n\nimport React, { ReactChild } from 'react';\nimport classes from './FormGroup.module.scss';\nimport { FormHelperText, Props as HelperProps } from '../FormHelperText/FormHelperText';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { HTMLProps } from '../../interfaces';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n children: ReactChild[] | ReactChild;\n error?: boolean;\n errorMessageIcon?: Icons;\n errorMessageIconPosition?: 'before' | 'after';\n errorMessage?: string;\n errorId?: string;\n helperIndent?: number;\n helperText?: string;\n helperId?: string;\n helperProps?: HelperProps;\n}\n\nexport const FormGroup = ({\n children,\n className,\n error,\n errorMessage,\n errorId,\n errorMessageIcon,\n errorMessageIconPosition = 'before',\n helperText,\n helperId,\n helperProps,\n helperIndent,\n ...rest\n}: Props) => {\n return (\n <div\n {...rest}\n className={`${classes['form-group']} ${error ? classes.error : ''} ${className ?? ''}`}\n >\n {children}\n\n {(helperText || errorMessage) && (\n <div\n style={{ marginLeft: `${helperIndent}px` }}\n className={`${classes['default-helper']} ${\n helperProps?.className ? helperProps.className : ''\n }`}\n >\n {helperText && !error && (\n <FormHelperText {...helperProps} className={''} id={helperId}>\n {helperText}\n </FormHelperText>\n )}\n {error && errorMessage && (\n <span className={classes['error-message']}>\n <span className={classes.message} id={errorId}>\n {errorMessageIcon && errorMessageIconPosition === 'before' && (\n <Icon\n className={`${classes['error-icon']} ${classes['error-icon-before']}`}\n icon={errorMessageIcon}\n />\n )}\n {errorMessage}\n {errorMessageIcon && errorMessageIconPosition === 'after' && (\n <Icon\n className={`${classes['error-icon']} ${classes['error-icon-after']}`}\n icon={errorMessageIcon}\n />\n )}\n </span>\n </span>\n )}\n </div>\n )}\n </div>\n );\n};\n","import React from 'react';\nimport classes from './Label.module.scss';\nimport readyclasses from '../../readyclasses.module.scss';\nimport { HTMLProps } from '../../interfaces';\n\nexport interface Props extends HTMLProps<HTMLLabelElement> {\n children?: string;\n}\n\nexport const Label = ({ children, className, hidden = false, ...rest }: Props) => {\n return (\n <label\n {...rest}\n className={`${hidden ? readyclasses['sr-only'] : ''} ${classes['label']} ${className ?? ''}`}\n >\n {children}\n </label>\n );\n};\n","import React, { useEffect } from 'react';\nimport classes from './Input.module.scss';\nimport readyclasses from '../../readyclasses.module.scss';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { HTMLProps } from '../../interfaces';\n\nconst dateTypes = ['date', 'time', 'datetime-local'] as const;\n\nexport type Type =\n | 'text'\n | 'email'\n | 'file'\n | 'number'\n | 'password'\n | 'search'\n | 'tel'\n | 'url'\n | 'hidden'\n | typeof dateTypes[number];\n\nexport interface Props extends HTMLProps<HTMLInputElement> {\n wrapperProps?: HTMLProps<HTMLInputElement>;\n labeledBy?: string;\n type: Type;\n error?: boolean;\n}\n\nexport const Input = ({\n error = false,\n className,\n name,\n style,\n wrapperProps,\n type,\n labeledBy,\n ...rest\n}: Props) => {\n useEffect(() => {\n if (name === undefined) {\n throw new Error(\"Please give your <Input /> component a 'name' attribute\");\n }\n }, []);\n\n const inputClassNames = [classes['input']];\n error && inputClassNames.push(classes['error']);\n (dateTypes as ReadonlyArray<string>).includes(type) &&\n inputClassNames.push(classes['remove-extra-indent']);\n className && inputClassNames.push(className);\n\n const iconClassNames = [classes['warning']];\n (dateTypes as ReadonlyArray<string>).includes(type) &&\n iconClassNames.push(classes['extra-indent']);\n\n return (\n <div\n {...wrapperProps}\n style={{ ...style }}\n className={`${classes['input-wrapper']} ${wrapperProps?.className ?? ''} ${\n type === 'hidden' ? readyclasses['hidden'] : ''\n }`}\n >\n <input\n {...rest}\n aria-labelledby={labeledBy}\n type={type}\n name={name}\n className={inputClassNames.join(' ')}\n />\n {error && <Icon className={iconClassNames.join(' ')} icon={Icons.Warning} />}\n </div>\n );\n};\n","import classes from './Select.module.scss';\n\nimport React, {\n HTMLProps,\n ReactElement,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\nimport { Input } from '../Input/Input';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { FormElement } from '../form.interfaces';\nimport { useBodyClick } from '../../hooks/useBodyClick';\nimport { Position } from '../../hooks/usePosition';\nimport { useScroll } from '../../hooks/useScroll';\n\nexport interface Props extends FormElement<HTMLSelectElement> {\n children: ReactElement[];\n name?: string;\n labeledBy?: string;\n describedBy?: string;\n placeholder?: string;\n searchPlaceholder?: string;\n className?: string;\n value?: string;\n onChange?: (event: React.ChangeEvent<HTMLSelectElement>, child?: ReactElement) => void;\n onClear?: (event: React.MouseEvent<HTMLDivElement>) => void;\n}\n\nexport const Select = ({\n children,\n name,\n disabled = false,\n labeledBy,\n placeholder,\n describedBy,\n searchPlaceholder = 'Search item',\n className,\n error = false,\n value = '',\n onChange,\n onClear,\n ...rest\n}: Props) => {\n const [expanded, setExpanded] = useState(false);\n const [filter, setFilter] = useState('');\n const [display, setDisplay] = useState('');\n const [listPosition, setListPosition] = useState<Partial<Position>>({});\n const containerReference = useRef<HTMLDivElement>(null);\n const optionListReference = useRef<HTMLDivElement>(null);\n\n useBodyClick(\n (event: MouseEvent) => !(event.target as Element).closest('.custom-select') && expanded,\n () => {\n setExpanded(!expanded);\n },\n expanded\n );\n\n const rePositionList = () => {\n if (!expanded || !optionListReference.current || !containerReference.current) {\n return;\n }\n const windowHeight = window.innerHeight;\n const containerTopWithListHeight =\n containerReference.current.getBoundingClientRect().bottom -\n containerReference.current.getBoundingClientRect().height +\n optionListReference.current.getBoundingClientRect().height;\n\n if (containerTopWithListHeight > windowHeight) {\n setListPosition({ top: 'initial', bottom: 0 });\n } else {\n setListPosition({ top: 0, bottom: 'initial' });\n }\n };\n\n useScroll(rePositionList, [expanded]);\n\n useLayoutEffect(() => {\n rePositionList();\n }, [expanded]);\n\n const onOptionChangeHandler = (child: ReactElement) => (event: React.ChangeEvent) => {\n /**\n * We expose this to the outside inside of the onChange function as a parameter along with an optional second\n * parameter of the option that was clicked.\n */\n\n setDisplay(child.props.children);\n\n let newValue;\n let multiple = false; // Potential support for future multiple select. This should be a prop obviously.\n\n if (multiple) {\n /** We will implement the mulitple select in the next iteration */\n } else {\n newValue = child.props.value;\n }\n\n if (onChange) {\n // Redefine target to allow name and value to be read.\n // This allows seamless integration with the most popular form libraries.\n // Clone the event to not override `target` of the original event.\n // Don't know how to fix this any.. compiler whines that it can't construct it otherwise.\n const nativeEvent: any = event.nativeEvent || event;\n const clonedEvent = new nativeEvent.constructor(nativeEvent.type, nativeEvent);\n\n Object.defineProperty(clonedEvent as React.ChangeEvent<HTMLSelectElement>, 'target', {\n writable: true,\n value: { value: newValue },\n });\n\n onChange(clonedEvent as React.ChangeEvent<HTMLSelectElement>, child);\n }\n\n setDisplay((event.currentTarget as HTMLElement).innerText);\n setExpanded(false);\n };\n\n /**\n * @description We have to modify the children (Option component) to have a additional props that allows us to keep track of which one is selected at all times and if a filter is active.\n * The `children` prop can be either a single object (1 child) or an array of multiple children.\n */\n const renderOptions = () =>\n React.Children.map(children, (child) =>\n React.cloneElement(child, {\n onOptionSelect: onOptionChangeHandler(child),\n selected: child.props.value === value,\n filter: filter,\n })\n );\n\n const renderSearch = () => (\n <Input\n autoFocus\n onChange={filterResults}\n className={classes['select-search']}\n wrapperProps={{ className: classes['select-search-wrapper'] }}\n type=\"text\"\n name=\"search-option\"\n placeholder={searchPlaceholder}\n />\n );\n\n const filterResults = (event: React.ChangeEvent<HTMLInputElement>) => {\n setFilter(event.currentTarget.value);\n };\n\n const statusIcon = () => {\n if (error) {\n return <Icon className={classes['warning']} icon={Icons.Warning} />;\n }\n if (value.length !== 0 && onClear) {\n return <Icon tag=\"div\" icon={Icons.TimesThin} onClick={onClear} />;\n }\n return null;\n };\n\n /** Set initial display value */\n useEffect(() => {\n for (let child of children) {\n if (child.props.value === value) {\n setDisplay(child.props.children);\n }\n }\n }, []);\n\n const additionalClasses = [];\n expanded && additionalClasses.push(classes.expanded);\n error && additionalClasses.push(classes.error);\n disabled && additionalClasses.push(classes.disabled);\n\n return (\n <div\n {...(rest as HTMLProps<HTMLDivElement>)}\n ref={containerReference}\n className={`custom-select ${classes.select} ${additionalClasses.join(' ')} ${\n className ?? ''\n }`}\n >\n <button\n onClick={() => setExpanded(!expanded)}\n type=\"button\"\n name={name}\n disabled={disabled}\n aria-disabled={disabled}\n aria-invalid={error}\n aria-expanded={expanded}\n aria-haspopup=\"listbox\"\n aria-labelledby={labeledBy}\n aria-describedby={describedBy}\n >\n <div data-display className={classes['selected']}>\n {value.length === 0 && placeholder && (\n <span className={classes['placeholder']}>{placeholder}</span>\n )}\n {value.length > 0 && <span>{display}</span>}\n </div>\n <div className={classes['status']}>\n {statusIcon()}\n <Icon className={classes['triangle-down']} icon={Icons.TriangleDown} />\n </div>\n </button>\n <div\n ref={optionListReference}\n className={`list-wrapper ${classes['list-wrapper']}`}\n style={{ display: expanded ? 'block' : 'none', ...listPosition }}\n >\n {Array.isArray(children) && children.length > 10 && renderSearch()}\n <ul role=\"listbox\" tabIndex={-1}>\n {renderOptions()}\n </ul>\n </div>\n </div>\n );\n};\n","import React, { useLayoutEffect } from 'react';\n\nexport const useScroll = (\n callbackFunction: (event: Event) => unknown,\n dependingStateVariable: React.ComponentState[] = []\n) => {\n const scrollListener = (event: Event) => callbackFunction(event);\n\n useLayoutEffect(() => {\n window.addEventListener('scroll', scrollListener);\n\n return () => {\n window.removeEventListener('scroll', scrollListener);\n };\n }, [...dependingStateVariable]);\n};\n","import React from 'react';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { FormElement } from '../form.interfaces';\nimport classes from './Textarea.module.scss';\n\nexport interface Props extends FormElement<HTMLTextAreaElement> {\n wrapperClassName?: string;\n errorClassName?: string;\n}\n\nexport const Textarea = ({\n error = false,\n disabled = false,\n className,\n rows = 4,\n wrapperClassName,\n errorClassName,\n ...rest\n}: Props) => {\n return (\n <div className={`${classes['textarea-wrapper']} ${wrapperClassName ? wrapperClassName : ''}`}>\n <textarea\n {...rest}\n rows={rows}\n className={`${error ? classes['error'] : ''} ${classes['textarea']} ${className ?? ''}`}\n disabled={disabled}\n />\n {error && (\n <Icon className={`${classes['warning']} ${errorClassName ?? ''}`} icon={Icons.Warning} />\n )}\n </div>\n );\n};\n","import { useEffect, useState } from 'react';\nimport { generateID } from '../util/helper';\nimport { Type as InputTypes } from '../Form/Input/Input';\n\nexport const useWrapper = (value?: string, placeholder?: string, type?: InputTypes) => {\n const [helperId] = useState(generateID(20));\n const [errorId] = useState(generateID(20));\n const [labelId] = useState(generateID(20));\n const [floatingLabelActive, setFloatingLabelActive] = useState(false);\n const [hasFocus, setHasFocus] = useState(false);\n\n useEffect(() => {\n if (value?.length || placeholder || type === 'datetime-local' || type === 'time') {\n setFloatingLabelActive(true);\n }\n }, []);\n\n useEffect(() => {\n if (value?.length || hasFocus) {\n setFloatingLabelActive(true);\n } else if (!placeholder && !hasFocus && type !== 'datetime-local' && type !== 'time') {\n setFloatingLabelActive(false);\n }\n }, [value, placeholder, type, hasFocus]);\n\n return {\n helperId,\n errorId,\n labelId,\n floatingLabelActive,\n setFloatingLabelActive,\n hasFocus,\n setHasFocus,\n };\n};\n","import React, { ReactElement } from 'react';\nimport { FormGroup, Props as FormGroupProps } from '../../FormGroup/FormGroup';\nimport { Label, Props as LabelProps } from '../../Label/Label';\nimport classes from './Wrapper.module.scss';\nimport { Props as HelperProps } from '../../FormHelperText/FormHelperText';\nimport { HTMLProps } from '../../../interfaces';\n\nexport interface Props extends Omit<FormGroupProps, 'children'> {\n children: ReactElement | ReactElement[];\n floatingLabelActive?: boolean;\n floatingLabel?: boolean;\n helperIndent?: number;\n label?: string;\n labelProps?: LabelProps;\n name: string;\n /** This does NOT add validation! It simply adds an asterix on the Label! */\n required?: boolean;\n innerClassName?: string;\n}\n\n/** For components that extend this component we create an interface (InputWrapper, SelectWrapper, etc.) */\nexport interface WrapperProps extends HTMLProps<HTMLDivElement> {\n errorMessage?: string;\n error: boolean;\n helperText?: string;\n helperProps?: HelperProps;\n label?: string;\n name: string;\n required?: boolean;\n}\n\nexport const Wrapper = ({\n children,\n className,\n error,\n errorMessage,\n errorId,\n errorMessageIcon,\n errorMessageIconPosition,\n helperText,\n helperId,\n floatingLabel = true,\n floatingLabelActive,\n required,\n helperProps,\n helperIndent,\n labelProps,\n label,\n disabled,\n name,\n innerClassName,\n ...rest\n}: Props) => {\n const renderChildren = () =>\n React.Children.map(children, (child) =>\n React.cloneElement(child, {\n disabled,\n })\n );\n\n const labelClasses = [];\n\n floatingLabel && labelClasses.push(classes['floating-label']);\n floatingLabel && floatingLabelActive && labelClasses.push(classes['floating-label-active']);\n labelProps?.className && labelClasses.push(labelProps.className);\n required && labelClasses.push(classes['required']);\n error && labelClasses.push(classes['error']);\n\n return (\n <div {...rest} className={`${classes.wrapper} ${className ? className : ''}`}>\n <FormGroup\n error={error}\n errorMessage={errorMessage}\n errorId={errorId}\n errorMessageIcon={errorMessageIcon}\n errorMessageIconPosition={errorMessageIconPosition}\n helperText={helperText}\n helperId={helperId}\n helperProps={helperProps}\n helperIndent={helperIndent}\n >\n <div\n className={`${floatingLabel ? classes['floating-wrapper'] : ''} ${\n innerClassName ? innerClassName : ''\n }`}\n >\n {label && (\n <Label\n {...labelProps}\n className={`${classes.label} ${labelClasses.join(' ')}`}\n htmlFor={name}\n >\n {label}\n </Label>\n )}\n {renderChildren()}\n </div>\n </FormGroup>\n </div>\n );\n};\n","import { useEffect, useState } from 'react';\nimport { generateID } from '../util/helper';\n\nexport interface ConfigObject {\n name: string | undefined;\n errorMessage?: string;\n error?: boolean;\n parentErrorId?: string;\n helperText?: string;\n parentHelperId?: string;\n}\n\nexport const useFormSelector = (configObject: ConfigObject) => {\n const [identifier] = useState(generateID(15, configObject.name));\n const [describedBy, setDescribedBy] = useState('');\n const [errorId] = useState(generateID(15, configObject.errorMessage));\n\n useEffect(() => {\n if (configObject.error && configObject.parentErrorId) {\n setDescribedBy(configObject.parentErrorId);\n }\n\n if (\n (!configObject.error && configObject.helperText) ||\n (!configObject.parentErrorId && !configObject.errorMessage && configObject.helperText)\n ) {\n setDescribedBy(`${identifier}`);\n }\n\n if (\n (!configObject.error && !configObject.helperText && configObject.parentHelperId) ||\n (!configObject.parentErrorId && !configObject.errorMessage && configObject.parentHelperId)\n ) {\n setDescribedBy(`${configObject.parentHelperId}`);\n }\n\n if (configObject.errorMessage && !configObject.parentErrorId && configObject.error) {\n setDescribedBy(errorId);\n }\n }, [identifier, configObject.error, configObject.parentErrorId]);\n\n return {\n describedBy,\n errorId,\n identifier,\n };\n};\n","import React, { ReactNode } from 'react';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { HTMLProps } from '../../interfaces';\nimport { FormHelperText, Props as FormHelperTextProps } from '../FormHelperText/FormHelperText';\nimport classes from './FormSelectorWrapper.module.scss';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n children?: ReactNode;\n nestedChildren?: ReactNode;\n containerProps: HTMLProps<HTMLDivElement>;\n helperProps?: FormHelperTextProps;\n error?: boolean;\n disabled?: boolean;\n helperText?: string;\n errorMessage?: string;\n parentHelperId?: string;\n parentErrorId?: string;\n errorId: string;\n identifier: string;\n}\n\nexport const FormSelectorWrapper = ({\n children,\n className,\n nestedChildren,\n containerProps,\n helperProps,\n error,\n disabled,\n helperText,\n errorMessage,\n parentErrorId,\n errorId,\n identifier,\n ...rest\n}: Props) => {\n return (\n <div\n {...rest}\n className={`${error ? classes['error'] : ''} ${disabled ? classes['disabled'] : ''} ${\n className ?? ''\n }`}\n >\n <div {...containerProps}>{children}</div>\n {helperText && (!error || parentErrorId || !errorMessage) && (\n <FormHelperText\n {...helperProps}\n id={`${identifier}`}\n className={`${classes['helper-text']} ${helperProps?.className ?? ''} ${\n error ? classes['error'] : ''\n }`}\n >\n {helperText}\n </FormHelperText>\n )}\n {errorMessage && !parentErrorId && error && (\n <span className={classes['error-message']}>\n <Icon className={classes['error-icon']} icon={Icons.Warning} />\n <span id={errorId}>{errorMessage}</span>\n </span>\n )}\n {nestedChildren}\n </div>\n );\n};\n","import React, { ReactElement, ReactNode, useEffect } from 'react';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { Props as FormHelperTextProps } from '../FormHelperText/FormHelperText';\nimport classes from './Checkbox.module.scss';\nimport { useFormSelector } from '../../hooks/useFormSelector';\nimport { FormSelector } from '../form.interfaces';\nimport { HTMLProps } from '../../interfaces';\nimport { FormSelectorWrapper } from '../FormSelectorWrapper/FormSelectorWrapper';\n\nconst isToggle = (children: ReactNode) => (children as ReactElement)?.props?.['data-toggle'];\n\nexport interface CheckboxProps extends FormSelector<HTMLInputElement> {\n children: ReactNode;\n label?: string;\n indeterminate?: boolean;\n helperProps?: FormHelperTextProps;\n wrapperProps?: HTMLProps<HTMLDivElement>;\n onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;\n}\n\nexport const Checkbox = ({\n children,\n name,\n helperText,\n helperProps,\n indeterminate,\n parentErrorId,\n errorMessage,\n disabled,\n label,\n parentHelperId,\n className,\n error,\n checked = false,\n wrapperProps,\n onChange,\n ...rest\n}: CheckboxProps) => {\n const { errorId, identifier, describedBy } = useFormSelector({\n name,\n helperText,\n parentErrorId,\n errorMessage,\n error,\n parentHelperId,\n });\n\n useEffect(() => {\n if (!name) {\n console.error(\"Please pass a 'name' prop to your <Checkbox> component.\");\n }\n\n if (typeof children === 'object' && !isToggle(children) && indeterminate === undefined) {\n throw new Error(\n 'If you have nested checkboxes you have to manage the indeterminate state by passing a boolean to the `indeterminate` prop.'\n );\n }\n }, []);\n\n const determineLabel = () => {\n if (label) {\n return label;\n } else if (children === undefined) {\n throw new Error(\n 'Please make sure to pass either a string or more Checkbox components as a child of your Checkbox component.'\n );\n }\n\n if (typeof children === 'string') {\n return children;\n }\n\n throw new Error(\n 'If you pass Checkboxes as a child component (to create nested checkbox tree) you need to pass a label to the parent checkbox.'\n );\n };\n\n const renderNestedCheckboxes = () => (\n <ul className={classes['checkbox-list']}>\n {React.Children.map(children as ReactNode[], (child) => {\n return (\n <li>\n <Checkbox\n {...(child as ReactElement).props}\n parentHelperId={parentHelperId}\n parentErrorId={parentErrorId}\n error={error}\n disabled={disabled ? disabled : (child as CheckboxProps).disabled}\n >\n {(child as ReactElement).props.children}\n </Checkbox>\n </li>\n );\n })}\n </ul>\n );\n\n const onChangeHandler = (event: React.ChangeEvent<HTMLInputElement>) => {\n if (disabled) {\n return;\n }\n onChange && onChange(event);\n };\n\n const renderToggle = () => React.Children.toArray(children).filter(isToggle);\n\n const iconClasses = [classes['input'], disabled ? classes['disabled'] : ''];\n\n /** Default return value is the default checkbox */\n return (\n <FormSelectorWrapper\n {...wrapperProps}\n className={`${classes['checkbox-wrapper']} ${className ? className : ''}`}\n containerProps={{ className: classes['checkbox-container'] }}\n helperText={helperText}\n helperProps={helperProps}\n parentErrorId={parentErrorId}\n errorId={errorId}\n errorMessage={errorMessage}\n error={error}\n disabled={disabled}\n identifier={identifier}\n nestedChildren={\n typeof children === 'object' && !isToggle(children) && renderNestedCheckboxes()\n }\n >\n <input\n {...rest}\n disabled={disabled}\n className={`${classes['native-input']} ${error ? classes['error'] : ''}`}\n checked={checked}\n onChange={onChangeHandler}\n aria-invalid={error as boolean}\n aria-checked={indeterminate ? 'mixed' : checked}\n aria-describedby={describedBy}\n id={`${identifier}-checkbox`}\n name={name}\n type=\"checkbox\"\n />\n {renderToggle()}\n\n {indeterminate && <Icon className={iconClasses.join(' ')} icon={Icons.MinusSquare} />}\n {checked && !indeterminate && (\n <Icon className={iconClasses.join(' ')} icon={Icons.CheckmarkSquare} />\n )}\n {!checked && !indeterminate && <Icon className={iconClasses.join(' ')} icon={Icons.Square} />}\n <label htmlFor={`${identifier}-checkbox`}>{determineLabel()}</label>\n </FormSelectorWrapper>\n );\n};\n","import React, { Fragment } from 'react';\nimport classes from './BaseWizardSteps.module.scss';\nimport readyclasses from '../../readyclasses.module.scss';\nimport { Icon, Icons } from '../../Icon/Icon';\n\ntype StepState = 'finished' | 'current' | 'future';\n\nexport interface Step {\n label: string;\n disabled?: boolean;\n}\n\nexport interface Props extends Omit<React.HTMLProps<HTMLDivElement>, 'onClick'> {\n steps: Step[];\n currentStepNo: number;\n onClick?: (stepNo: number) => void;\n futureStepsClickable?: boolean;\n stepScreenReaderLabel: string;\n}\n\nexport const BaseWizardSteps = ({\n steps,\n currentStepNo,\n onClick,\n futureStepsClickable = false,\n stepScreenReaderLabel,\n ...restProps\n}: Props) => {\n const getStepState = (stepNo: number): StepState => {\n if (currentStepNo === stepNo) {\n return 'current';\n } else if (stepNo < currentStepNo) {\n return 'finished';\n }\n return 'future';\n };\n\n const getStepContent = (stepState: StepState, index: number, disabled?: boolean) => {\n const stepNumberString = String(index + 1);\n if (stepState === 'finished') {\n return disabled ? null : <Icon className={classes['checkmark']} icon={Icons.Checkmark} />;\n } else {\n return (\n <Fragment>\n <span className={readyclasses['sr-only']}>{stepScreenReaderLabel} </span>\n {stepNumberString}\n </Fragment>\n );\n }\n };\n\n const generatedSteps = steps.map((step, index) => {\n const stepState = getStepState(index);\n const disabledStyleClassName = step.disabled ? classes['disabled'] : '';\n const clickableClassName = futureStepsClickable ? classes['clickable'] : '';\n\n return (\n <button\n key={step.label.toLowerCase().replace(/\\s/, '-')}\n disabled={\n step.disabled ||\n (stepState === 'future' && !futureStepsClickable) ||\n stepState === 'current'\n }\n aria-current={stepState === 'current' ? 'step' : undefined}\n onClick={() => onClick && onClick(index)}\n className={`${classes['wizard-element']} ${classes[stepState]} ${clickableClassName} ${disabledStyleClassName}`}\n >\n <div className={classes['number-wrapper']}>\n <span className={classes['number']}>\n {getStepContent(stepState, index, step.disabled)}\n </span>\n </div>\n <div className={classes['two-line-text-overflow']}>\n <span className={classes['label']}>{step.label}</span>\n </div>\n </button>\n );\n });\n\n return (\n <div {...restProps} className={classes['wizard']}>\n {generatedSteps}\n </div>\n );\n};\n","import { Reducer } from 'react';\nimport { Step } from './BaseWizardSteps/BaseWizardSteps';\nimport { WizardMode } from './Wizard';\n\ntype WizardStateType = {\n steps: Step[];\n currentStepNo: number;\n mode: WizardMode;\n stepScreenReaderLabel: string;\n};\n\ninterface SetWizardStateAction {\n type: 'SET_STATE';\n payload: {\n steps: Step[];\n mode: WizardMode;\n stepScreenReaderLabel: string;\n };\n}\n\ninterface ChangeCurrentStepNoAction {\n type: 'CHANGE_CURRENT_STEP_NO';\n payload: number;\n}\n\nconst setWizardState = (\n steps: Step[],\n mode: WizardMode,\n stepScreenReaderLabel: string\n): SetWizardStateAction => {\n return { type: 'SET_STATE', payload: { steps, mode, stepScreenReaderLabel } };\n};\n\nconst changeCurrentStepNo = (currentStepNo: number): ChangeCurrentStepNoAction => {\n return { type: 'CHANGE_CURRENT_STEP_NO', payload: currentStepNo };\n};\n\ntype WizardActions = SetWizardStateAction | ChangeCurrentStepNoAction;\n\nconst reducer: Reducer<WizardStateType, WizardActions> = (state, action) => {\n switch (action.type) {\n case 'SET_STATE':\n return { ...state, ...action.payload };\n case 'CHANGE_CURRENT_STEP_NO':\n return { ...state, currentStepNo: action.payload };\n default:\n return state;\n }\n};\n\nexport { setWizardState, changeCurrentStepNo, reducer, WizardActions, WizardStateType };\n","import React, { createContext, Dispatch, useReducer } from 'react';\nimport { WizardActions, WizardStateType, reducer } from './wizardStateReducer';\n\nconst WizardStateContext = createContext<{\n state: WizardStateType;\n dispatch: Dispatch<WizardActions>;\n}>({\n state: {} as WizardStateType,\n dispatch: () => null,\n});\n\nexport interface Props {\n initialState: WizardStateType;\n children?: React.ReactNode;\n}\n\nconst WizardStateProvider = ({ children, initialState }: Props) => {\n const [state, dispatch] = useReducer(reducer, initialState);\n return (\n <WizardStateContext.Provider value={{ state, dispatch }}>\n {children}\n </WizardStateContext.Provider>\n );\n};\n\nexport { WizardStateProvider, WizardStateContext };\n","import React, { Fragment, useContext, useEffect } from 'react';\nimport { Step } from './BaseWizardSteps/BaseWizardSteps';\nimport { WizardStateContext, WizardStateProvider } from './WizardStateProvider';\nimport { setWizardState } from './wizardStateReducer';\n\nexport type WizardMode = 'add' | 'edit';\n\nexport interface Props {\n steps: Step[];\n mode: WizardMode;\n initialStepNo?: number;\n onStepChange: (stepNo: number) => void;\n stepScreenReaderLabel: string;\n children: React.ReactNode;\n}\n\nconst useSetWizardState = (steps: Step[], mode: WizardMode, stepScreenReaderLabel: string) => {\n const { dispatch } = useContext(WizardStateContext);\n\n useEffect(() => {\n dispatch(setWizardState(steps, mode, stepScreenReaderLabel));\n }, [steps, mode, stepScreenReaderLabel]);\n};\n\nconst useStepChanging = (onStepChange: (stepNo: number) => void) => {\n const {\n state: { currentStepNo },\n } = useContext(WizardStateContext);\n\n useEffect(() => {\n onStepChange(currentStepNo);\n }, [currentStepNo]);\n};\n\nconst WizardContent = ({ steps, mode, stepScreenReaderLabel, onStepChange, children }: Props) => {\n useSetWizardState(steps, mode, stepScreenReaderLabel);\n useStepChanging(onStepChange);\n\n return <Fragment>{children}</Fragment>;\n};\n\nexport const Wizard = (props: Props) => {\n const { steps, initialStepNo: currentStepNo = 0, mode, stepScreenReaderLabel } = props;\n return (\n <WizardStateProvider initialState={{ steps, currentStepNo, mode, stepScreenReaderLabel }}>\n <WizardContent {...props} />\n </WizardStateProvider>\n );\n};\n","import React, { Fragment, HTMLAttributes, ReactChild, useEffect, useState } from 'react';\n\ninterface CSSProperties {\n colorPrimary?: string;\n colorSecondary?: string;\n colorTertiary?: string;\n defaultLineHeight?: string;\n buttonBorderRadius?: string;\n buttonBorderWidth?: string;\n buttonFontSize?: string;\n buttonBorderStyle?: string;\n buttonFillTextColor?: string;\n buttonFillBackgroundColor?: string;\n buttonOutlineHoverTextColor?: string;\n inputBorderColor?: string;\n inputBorderRadius?: string;\n inputBorderWidth?: string;\n inputBorderStyle?: string;\n modalShadowColor?: string;\n modalBackgroundColor?: string;\n modalHeaderBackgroundColor?: string;\n snackbarTextColor?: string;\n snackbarInfoBackgroundColor?: string;\n snackbarSuccessBackgroundColor?: string;\n snackbarErrorBackgroundColor?: string;\n snackbarBorderRadius?: string;\n default?: string;\n success?: string;\n error?: string;\n disabled?: string;\n greyedOut?: string;\n warning?: string;\n fontFamily?: string;\n fontFamilyCode?: string;\n fontSize?: string;\n fontSizeH1?: string;\n fontSizeH2?: string;\n fontSizeH3?: string;\n fontSizeH4?: string;\n fontSizeSub?: string;\n fontSizeCode?: string;\n}\n\nexport interface Props extends HTMLAttributes<HTMLDivElement> {\n children?: ReactChild;\n properties?: CSSProperties;\n}\n\nexport const BaseStyling = ({ children, properties = {} }: Props) => {\n const defaultProperties: CSSProperties = {\n colorPrimary: '#9e006b',\n colorSecondary: '#003b5e',\n colorTertiary: '#ff1e4e',\n defaultLineHeight: '26px',\n buttonBorderRadius: '20px',\n buttonBorderWidth: '2px',\n buttonFontSize: '1rem',\n buttonBorderStyle: 'solid',\n buttonFillTextColor: '#FFF',\n buttonFillBackgroundColor: '#FFF',\n buttonOutlineHoverTextColor: '#FFF',\n inputBorderColor: '#e9e9eb',\n inputBorderRadius: '8px',\n inputBorderWidth: '1px',\n inputBorderStyle: 'solid',\n modalShadowColor: 'rgba(0, 0, 0, 0.16)',\n modalBackgroundColor: '#F5F8F8',\n modalHeaderBackgroundColor: '#FFF',\n snackbarTextColor: '#fff',\n snackbarInfoBackgroundColor: '#003b5e',\n snackbarSuccessBackgroundColor: '#008a28',\n snackbarErrorBackgroundColor: '#e22a1d',\n snackbarBorderRadius: '8px',\n default: '#0f0f1e',\n success: '#008a28',\n error: '#e22a1d',\n disabled: '#e9e9eb',\n greyedOut: '#6f6f76',\n warning: '#ff6105',\n fontFamily: \"'Red Hat Display', sans-serif\",\n fontFamilyCode: \"'Red Hat Mono', sans-serif\",\n fontSize: '1rem',\n fontSizeH1: '2.5rem',\n fontSizeH2: '1.625rem',\n fontSizeH3: '1.5rem',\n fontSizeH4: '1.25rem',\n fontSizeSub: '.75rem',\n fontSizeCode: '1rem',\n };\n\n /** We need a loading state, because otherwise you see the colors flash from the default to the possible overridden ones. */\n const [isLoading, setIsLoading] = useState(true);\n\n /** Set the actual CSS properties on the HTML :root object */\n const setCSSProperties = (CSSPropertiesObject: CSSProperties) => {\n for (const [key, value] of Object.entries(CSSPropertiesObject)) {\n const formattedPropertyName = key.replaceAll(/([A-Z])/g, (val) => `-${val.toLowerCase()}`);\n document.documentElement.style.setProperty(`--${formattedPropertyName}`, value);\n }\n };\n\n /** Check if the properties prop object is filled with anything. If it is, we want to shallow merge it with the default BaseStyling. */\n useEffect(() => {\n if (Object.keys(properties).length !== 0) {\n const mergedState = { ...defaultProperties, ...properties };\n setCSSProperties(mergedState);\n } else {\n setCSSProperties(defaultProperties);\n }\n setIsLoading(false);\n }, [properties]);\n\n /** Only render if we're not loading */\n return !isLoading ? <Fragment>{children}</Fragment> : null;\n};\n","import React, { Fragment, HTMLProps, ReactElement } from 'react';\nimport { Icon, Icons } from '../Icon/Icon';\nimport { Link, Props as LinkProps } from '../Link/Link';\nimport { Typography } from '../Typography/Typography';\nimport classes from './Breadcrumbs.module.scss';\n\ntype ChildrenType = ReactElement<LinkProps, typeof Link>;\n\nexport interface Props extends HTMLProps<HTMLElement> {\n children: ChildrenType | ChildrenType[];\n 'aria-label': string;\n}\n\nexport const Breadcrumbs = ({\n children,\n 'aria-label': ariaLabel,\n className = '',\n ...rest\n}: Props) => {\n const items = React.Children.map(children, (child, index) => {\n const isLastElement = Array.isArray(children) ? index === children.length - 1 : true;\n if (isLastElement) {\n return (\n <Typography\n key={child.key}\n variant=\"body\"\n tag=\"span\"\n className={classes['last']}\n aria-current=\"page\"\n >\n {child.props.children}\n </Typography>\n );\n } else {\n return (\n <Fragment key={child.key}>\n {React.cloneElement(child)}\n <Icon icon={Icons.ChevronRight} className={classes['icon']} />\n </Fragment>\n );\n }\n });\n return (\n <nav {...rest} aria-label={ariaLabel} className={`${classes['breadcrumbs']} ${className}`}>\n {items}\n </nav>\n );\n};\n","import React, { ReactElement, useEffect } from 'react';\nimport classes from './CheckboxWrapper.module.scss';\nimport { useWrapper } from '../../../hooks/useWrapper';\nimport { Wrapper, WrapperProps } from '../Wrapper/Wrapper';\nimport { Icons } from '../../../Icon/Icon';\nimport { Fieldset, Props as FieldsetProps } from '../../../Form/Fieldset/Fieldset';\n\nexport interface Props extends WrapperProps {\n children: ReactElement[] | ReactElement;\n fieldsetProps: FieldsetProps;\n}\n\nexport const CheckboxWrapper = ({\n children,\n error = false,\n helperText,\n helperProps,\n fieldsetProps,\n ...rest\n}: Props) => {\n const { errorId, helperId } = useWrapper();\n\n useEffect(() => {\n if (fieldsetProps.legend === undefined) {\n console.error(\n `You should give your Fieldset component a title prop so a legend element is rendered. This error was thrown in CheckboxWrapper. You can add this title prop through the fieldsetProps prop by passing an object (fieldsetProps={{ title: \"title here\" }})`\n );\n }\n }, []);\n\n const renderChildren = () =>\n React.Children.map(children, (child) =>\n React.cloneElement(child, {\n parentErrorId: errorId,\n error: error,\n parentHelperId: helperText ? helperId : false,\n disabled: rest.disabled,\n })\n );\n\n return (\n <Fieldset {...fieldsetProps}>\n <Wrapper\n {...rest}\n label=\"\"\n helperId={helperId}\n helperText={helperText}\n helperProps={{\n ...helperProps,\n className: `${classes['checkbox-wrapper-helper']} ${\n error ? classes['checkbox-wrapper-error'] : ''\n } ${helperProps?.className ?? ''}`,\n }}\n error={error}\n errorMessageIcon={Icons.Warning}\n errorId={errorId}\n >\n {renderChildren()}\n </Wrapper>\n </Fieldset>\n );\n};\n","import React, { HTMLProps, ReactElement, useEffect, useRef, useState } from 'react';\nimport { Props as ButtonProps } from '../Button/Button';\nimport { Props as IconButtonProps } from '../Button/IconButton';\nimport { Popover } from '../Popover/Popover';\nimport { Placement, Offset } from '../hooks/usePosition';\nimport { Props as ContextMenuItemProps } from './ContextMenuItem';\nimport classes from './ContextMenu.module.scss';\nimport { useBodyClick } from '../hooks/useBodyClick';\nimport { createPortal } from 'react-dom';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n trigger: ReactElement<ButtonProps> | ReactElement<IconButtonProps>;\n children: ReactElement<ContextMenuItemProps> | ReactElement<ContextMenuItemProps>[];\n placement?: Placement;\n transformOrigin?: Placement;\n offset?: Offset;\n id: string;\n show?: boolean;\n domRoot?: HTMLElement;\n onShow?: () => void;\n onClose?: () => void;\n}\n\nexport const ContextMenu = ({\n trigger,\n children,\n id,\n show = false,\n onShow,\n onClose,\n placement = { horizontal: 'right', vertical: 'top' },\n offset = { top: 0, bottom: 0, left: 0, right: 0 },\n transformOrigin = { horizontal: 'left', vertical: 'top' },\n domRoot = document.body,\n ...rest\n}: Props) => {\n const anchorEl = useRef<HTMLButtonElement>(null);\n const [showContextMenu, setShowContextMenu] = useState(show);\n\n if (!id) {\n throw new Error('You need to provide an ID to the context menu');\n }\n\n useBodyClick(\n (event) => {\n return showContextMenu && anchorEl.current !== event.target;\n },\n () => {\n setShowContextMenu(false);\n },\n showContextMenu\n );\n\n useEffect(() => {\n if (showContextMenu === true) {\n onShow && onShow();\n } else {\n onClose && onClose();\n }\n }, [showContextMenu]);\n\n const renderTrigger = () =>\n React.cloneElement(trigger, {\n id: id,\n ['aria-haspopup']: 'true',\n ['aria-controls']: `${id}-menu`,\n ['aria-expanded']: show,\n onClick: () => setShowContextMenu(!showContextMenu),\n ref: anchorEl,\n });\n\n return (\n <div {...rest} className={classes['context-menu']}>\n {renderTrigger()}\n {createPortal(\n <Popover\n placement={placement}\n transformOrigin={transformOrigin}\n offset={offset}\n anchorEl={anchorEl}\n show={showContextMenu}\n >\n <ul className={classes.menu} id={`${id}-menu`} aria-describedby={id} role=\"menu\">\n {children}\n </ul>\n </Popover>,\n domRoot\n )}\n </div>\n );\n};\n","import React, { HTMLProps } from 'react';\nimport classes from './ContextMenuItem.module.scss';\n\nexport interface Props extends Omit<HTMLProps<HTMLLIElement>, 'onClick'> {\n children?: string;\n onClick?: (event: React.MouseEvent<HTMLButtonElement>) => void;\n}\n\nexport const ContextMenuItem = ({ children, onClick, ...rest }: Props) => {\n return (\n <li {...rest} role=\"menuitem\" className={classes['context-menu-item']}>\n <button onClick={(event) => onClick && onClick(event)}>{children}</button>\n </li>\n );\n};\n","import React, { Fragment, useState } from 'react';\nimport { Modal, Props as ModalProps } from '../Modal/Modal';\nimport { ModalHeader, Props as ModalHeaderProps } from '../Modal/ModalHeader/ModalHeader';\nimport {\n DiscardChangesDialog,\n Props as DiscardChangesDialogProps,\n} from './DiscardChangesDialog/DiscardChangesDialog';\n\nexport interface Props extends Omit<ModalProps, 'onClose'> {\n hasUnsavedChanges: () => boolean;\n onClose: (event?: React.MouseEvent<HTMLElement>) => unknown;\n headerProps: Omit<ModalHeaderProps, 'onClose' | 'id'>;\n discardChangedDialogProps: Omit<\n DiscardChangesDialogProps,\n 'open' | 'onKeepEditing' | 'onDiscardChanges'\n >;\n}\n\nexport const DiscardChangesModal = ({\n id,\n onClose,\n children,\n hasUnsavedChanges,\n headerProps,\n discardChangedDialogProps,\n ...rest\n}: Props) => {\n const [openDiscardChangesDialog, setOpenDiscardChangesDialog] = useState(false);\n\n const onCloseWrapper = () =>\n hasUnsavedChanges() ? setOpenDiscardChangesDialog(true) : onClose();\n\n const onDialogKeepEditing = () => {\n setOpenDiscardChangesDialog(false);\n };\n\n const onDialogDiscardChanges = () => {\n setOpenDiscardChangesDialog(false);\n onClose();\n };\n\n return (\n <Fragment>\n <Modal id={id} onClose={onCloseWrapper} {...rest}>\n <ModalHeader {...headerProps} id={`${id}-label`} onClose={onCloseWrapper} />\n {children}\n </Modal>\n <DiscardChangesDialog\n {...discardChangedDialogProps}\n open={openDiscardChangesDialog}\n onKeepEditing={onDialogKeepEditing}\n onDiscardChanges={onDialogDiscardChanges}\n />\n </Fragment>\n );\n};\n","import React, { HTMLProps, ReactNode } from 'react';\nimport classes from './Form.module.scss';\n\nexport interface Props extends HTMLProps<HTMLFormElement> {\n children?: ReactNode;\n}\n\nexport const Form = ({ children, className, ...rest }: Props) => {\n return (\n <form className={`${classes.form} ${className ?? ''}`} {...rest}>\n {children}\n </form>\n );\n};\n","import React, { ReactElement } from 'react';\nimport classes from './FormControl.module.scss';\nimport { HTMLProps } from '../../interfaces';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n children: ReactElement | ReactElement[];\n grid?: 1 | 2 | 3;\n align?: 'top' | 'start' | 'middle' | 'center' | 'bottom' | 'end' | 'stretch';\n error?: boolean;\n}\n\nexport const FormControl = ({\n children,\n disabled,\n error,\n className,\n grid,\n align = 'center',\n ...rest\n}: Props) => {\n const renderChildren = () =>\n React.Children.map(children, (child) => {\n if (!child) {\n return null;\n }\n\n const childElement = React.cloneElement(child, {\n disabled: child.props.disabled !== undefined ? child.props.disabled : disabled,\n error: child.props.error !== undefined ? child.props.error : error,\n });\n\n if (grid && grid > 1) {\n return <div className={`${classes['col-' + grid]} ${classes.column}`}>{childElement}</div>;\n }\n\n return childElement;\n });\n\n return (\n <div\n {...rest}\n data-formcontrol\n className={`${classes['form-control']} ${className ? className : ''} ${\n grid && grid > 1 ? `${classes.grid} ${classes['grid-' + grid]}` : ''\n } ${classes[align]}`}\n >\n {renderChildren()}\n </div>\n );\n};\n","import React from 'react';\nimport { Input, Type, Props as InputProps } from '../../Input/Input';\nimport classes from './InputWrapper.module.scss';\nimport { Wrapper, WrapperProps } from '../Wrapper/Wrapper';\nimport { useWrapper } from '../../../hooks/useWrapper';\n\ninterface OptionalInputProps extends Omit<InputProps, 'type'> {}\n\nexport interface Props extends WrapperProps {\n label: string;\n type: Type;\n name: string;\n inputProps?: OptionalInputProps;\n value: string;\n onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;\n onBlur?: (event: React.FocusEvent<HTMLInputElement>) => void;\n onFocus?: (event: React.FocusEvent<HTMLInputElement>) => void;\n}\n\nexport const InputWrapper = ({\n type,\n name,\n inputProps,\n helperText,\n helperProps,\n value,\n error,\n onChange,\n onBlur,\n onFocus,\n ...rest\n}: Props) => {\n const {\n errorId,\n floatingLabelActive,\n setFloatingLabelActive,\n hasFocus,\n setHasFocus,\n helperId,\n labelId,\n } = useWrapper(value, inputProps?.placeholder, type);\n\n return (\n <Wrapper\n {...rest}\n name={name}\n className={classes['input-wrapper']}\n labelProps={{\n id: labelId,\n className: `${classes['input-label']} ${hasFocus ? classes['focus'] : ''}`,\n }}\n floatingLabelActive={floatingLabelActive}\n errorId={errorId}\n error={error}\n helperId={helperId}\n helperText={helperText}\n helperProps={{\n ...helperProps,\n className: `${classes['input-wrapper-helper']} ${helperProps?.className ?? ''} `,\n }}\n helperIndent={20}\n >\n <Input\n {...inputProps}\n aria-labelledby={labelId}\n aria-describedby={error ? errorId : helperId}\n onChange={onChange}\n onFocus={(e) => {\n onFocus && onFocus(e);\n setHasFocus(true);\n setFloatingLabelActive(true);\n }}\n onBlur={(e) => {\n onBlur && onBlur(e);\n setHasFocus(false);\n e.target.value ||\n inputProps?.placeholder?.length ||\n type === 'datetime-local' ||\n type === 'time'\n ? setFloatingLabelActive(true)\n : setFloatingLabelActive(false);\n }}\n className={floatingLabelActive ? classes['floating-label'] : ''}\n name={name}\n error={error}\n id={name}\n value={value}\n type={type}\n />\n </Wrapper>\n );\n};\n","import React, { useEffect, useState } from 'react';\nimport classes from './Select.module.scss';\nimport { HTMLProps } from '../../interfaces';\n\nexport interface Props extends HTMLProps<HTMLLIElement> {\n children: string;\n value: string;\n disabled?: boolean;\n selected?: boolean;\n label?: string;\n filter?: string;\n onOptionSelect?: (event: React.SyntheticEvent<HTMLLIElement>) => void;\n}\n\nexport const Option = ({\n children,\n className,\n selected = false,\n onOptionSelect,\n disabled,\n filter,\n ...rest\n}: Props) => {\n const [showOption, setShowOption] = useState(true);\n\n const onSelectHandler = (event: React.SyntheticEvent<HTMLLIElement>) => {\n if (onOptionSelect) onOptionSelect(event);\n };\n\n useEffect(() => {\n if (filter) {\n setShowOption(children.toLowerCase().match(filter.toLowerCase()) !== null);\n } else {\n setShowOption(true);\n }\n }, [filter]);\n\n if (!showOption) return null;\n\n return (\n <li\n {...rest}\n className={`${selected ? classes['selected-option'] : ''} ${\n disabled ? classes.disabled : ''\n } ${className ?? ''}`}\n onClick={onSelectHandler}\n onKeyPress={(e) => {\n e.key === 'Enter' && onSelectHandler(e);\n }}\n aria-selected={selected}\n role=\"option\"\n tabIndex={disabled ? -1 : 0}\n >\n {children}\n </li>\n );\n};\n","import React from 'react';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { Props as HelperProps } from '../FormHelperText/FormHelperText';\nimport classes from './Radio.module.scss';\nimport { useFormSelector } from '../../hooks/useFormSelector';\nimport { FormSelector } from '../form.interfaces';\nimport { HTMLProps } from '../../interfaces';\nimport { FormSelectorWrapper } from '../FormSelectorWrapper/FormSelectorWrapper';\n\nexport interface Props extends FormSelector<HTMLInputElement> {\n children: string;\n value: string;\n wrapperProps?: HTMLProps<HTMLDivElement>;\n helperProps?: HelperProps;\n}\n\nexport const Radio = ({\n children,\n disabled,\n className,\n value,\n name,\n helperText,\n parentErrorId,\n parentHelperId,\n error,\n errorMessage,\n checked = false,\n wrapperProps,\n helperProps,\n onChange,\n ...rest\n}: Props) => {\n const { errorId, identifier, describedBy } = useFormSelector({\n name,\n helperText,\n parentErrorId,\n errorMessage,\n error,\n parentHelperId,\n });\n\n const onChangeHandler = (event: React.ChangeEvent<HTMLInputElement> | React.MouseEvent) => {\n if (disabled) {\n return;\n }\n /** We have to clone the native event we got here and change the \"target\" property to the value. Otherwise, this regular event has \"on\" as it's event.target.value, which is useless. */\n const nativeEvent: any = event.nativeEvent || event;\n const clonedEvent = new nativeEvent.constructor(nativeEvent.type, nativeEvent);\n\n Object.defineProperty(clonedEvent, 'target', {\n writable: true,\n value: { value: value },\n });\n\n onChange && onChange(clonedEvent);\n };\n\n /** Default return value is the default radio */\n return (\n <FormSelectorWrapper\n {...wrapperProps}\n className={`${classes['radio-wrapper']} ${className ?? ''}`}\n containerProps={{ className: classes['radio-container'] }}\n helperText={helperText}\n helperProps={helperProps}\n parentErrorId={parentErrorId}\n errorId={errorId}\n errorMessage={errorMessage}\n error={error}\n disabled={disabled}\n identifier={identifier}\n >\n <input\n {...rest}\n disabled={disabled}\n tabIndex={0}\n className={`${classes['native-input']} ${error ? classes['error'] : ''}`}\n onChange={onChangeHandler}\n checked={checked}\n aria-invalid={error ? true : false}\n aria-checked={checked}\n aria-describedby={describedBy}\n name={name}\n value={value}\n id={`${identifier}-radio`}\n type=\"radio\"\n />\n\n {checked && (\n <Icon\n className={`${classes['input']} ${disabled ? classes['disabled'] : ''}`}\n icon={Icons.Radio}\n />\n )}\n {!checked && (\n <Icon\n className={`${classes['input']} ${disabled ? classes['disabled'] : ''}`}\n icon={Icons.Circle}\n />\n )}\n\n <label onClick={onChangeHandler} htmlFor={`${identifier}-radio`}>\n {children}\n </label>\n </FormSelectorWrapper>\n );\n};\n","import React, { ReactElement, useEffect } from 'react';\nimport classes from './RadioWrapper.module.scss';\nimport { Wrapper, WrapperProps } from '../Wrapper/Wrapper';\nimport { useWrapper } from '../../../hooks/useWrapper';\nimport { Icons } from '../../../Icon/Icon';\nimport { Fieldset, Props as FieldsetProps } from '../../../Form/Fieldset/Fieldset';\n\nexport interface Props extends WrapperProps {\n children: ReactElement | ReactElement[];\n fieldsetProps: FieldsetProps;\n value: string;\n onChange: (event: React.ChangeEvent<HTMLInputElement>) => void;\n}\n\nexport const RadioWrapper = ({\n children,\n error,\n name,\n helperText,\n helperProps,\n fieldsetProps,\n value,\n onChange,\n disabled,\n ...rest\n}: Props) => {\n const { errorId, helperId } = useWrapper(value);\n\n useEffect(() => {\n if (fieldsetProps.legend === undefined) {\n console.error(\n `You should give your Fieldset component a title prop so a legend element is rendered. This error was thrown in RadioWrapper. You can add this title prop through the fieldsetProps prop by passing an object (fieldsetProps={{ title: \"title here\" }})`\n );\n }\n }, []);\n\n const renderChildren = () =>\n React.Children.map(children, (child) =>\n React.cloneElement(child, {\n parentErrorId: errorId,\n error: error,\n checked: child.props.value === value,\n name: name,\n parentHelperId: helperText ? helperId : false,\n onChange: onChange,\n disabled: child.props.disabled !== undefined ? child.props.disabled : disabled,\n })\n );\n\n return (\n <Fieldset {...fieldsetProps}>\n <Wrapper\n {...rest}\n disabled={disabled}\n name={name}\n label=\"\"\n helperId={helperId}\n helperText={helperText}\n helperProps={{\n ...helperProps,\n className: `${classes['radio-wrapper-helper']} ${\n error ? classes['radio-wrapper-error'] : ''\n } ${helperProps?.className ?? ''}`,\n }}\n error={error}\n errorId={errorId}\n errorMessageIcon={Icons.Warning}\n floatingLabel={false}\n >\n {renderChildren()}\n </Wrapper>\n </Fieldset>\n );\n};\n","import React, { ReactChild, ReactElement } from 'react';\nimport classes from './SelectWrapper.module.scss';\nimport { Wrapper, WrapperProps } from '../Wrapper/Wrapper';\nimport { Select, Props as SelectProps } from '../../Select/Select';\nimport { useWrapper } from '../../../hooks/useWrapper';\n\nexport interface Props extends Omit<WrapperProps, 'onChange' | 'error'> {\n children: ReactChild | ReactChild[];\n placeholder?: string;\n value: string;\n error?: boolean;\n selectProps?: SelectProps;\n onChange?: (event: React.ChangeEvent<HTMLSelectElement>) => void;\n onClear?: () => void;\n}\n\nexport const SelectWrapper = ({\n children,\n error,\n value,\n placeholder,\n selectProps,\n helperProps,\n onChange,\n onClear,\n ...rest\n}: Props) => {\n const { errorId, floatingLabelActive, helperId, labelId } = useWrapper(value, placeholder);\n\n return (\n <Wrapper\n {...rest}\n floatingLabelActive={floatingLabelActive}\n errorId={errorId}\n helperId={helperId}\n labelProps={{ id: labelId, className: classes['select-label'] }}\n helperProps={{\n ...helperProps,\n className: `${classes['select-helper-text']} ${helperProps?.className ?? ''}`,\n }}\n error={error}\n >\n <Select\n {...selectProps}\n value={value}\n labeledBy={labelId}\n error={error}\n describedBy={error ? errorId : helperId}\n onChange={onChange}\n onClear={onClear}\n placeholder={placeholder}\n className={`${floatingLabelActive ? classes['floating-label-active'] : ''} ${\n selectProps?.className ?? ''\n }`}\n >\n {children as ReactElement[]}\n </Select>\n </Wrapper>\n );\n};\n","import React, { ReactNode, useState } from 'react';\nimport { createPortal } from 'react-dom';\nimport { SnackbarContextProvider } from './SnackbarStateProvider';\nimport { Actions, SnackbarOptionsProps, Variant } from '../interfaces';\nimport { Placement, SnackbarContainer } from '../SnackbarContainer/SnackbarContainer';\nimport { generateID } from '../../../util/helper';\nimport { SnackbarItem } from '../SnackbarItem/SnackbarItem';\n\n/** Short msg is when only title is provided. Long one when content or/and actions are provided (or type is error). */\ninterface Duration {\n long: number;\n short: number;\n}\n\nexport interface Props {\n closeButtonTitle: string;\n children?: ReactNode;\n placement?: Placement;\n stackSize?: number;\n domRoot?: HTMLElement;\n autoHideDuration?: Duration;\n className?: string;\n}\n\ninterface Item {\n id: string;\n title: string;\n duration: number;\n variant: Variant;\n content?: string;\n actions?: Actions;\n}\n\nexport const SnackbarProvider = (\n {\n closeButtonTitle,\n placement = { vertical: 'bottom', horizontal: 'center' },\n autoHideDuration = { long: 8000, short: 4000 },\n stackSize = 3,\n domRoot = document.body,\n children,\n className,\n }: Props = { closeButtonTitle: '' }\n) => {\n const [snackbars, setSnackbars] = useState<Item[]>([]);\n\n const addSnackbar = (item: Item) => {\n setSnackbars((items) => [...items, item]);\n };\n\n const getDuration = (variant: Variant, actions?: Actions, content?: string) => {\n const hasError = variant === 'error';\n const hasContentOrActions = content || actions;\n if (hasError || hasContentOrActions) {\n return autoHideDuration.long;\n }\n return autoHideDuration.short;\n };\n\n const enqueueSnackbar = (\n title: string,\n content?: string,\n options: SnackbarOptionsProps = {}\n ): void => {\n const {\n variant = 'info',\n actions,\n duration = getDuration(variant, actions, content),\n } = options;\n const item: Item = {\n title,\n content,\n variant,\n actions,\n duration,\n id: generateID(15, title),\n };\n addSnackbar(item);\n };\n\n const enqueueSuccessSnackbar = (\n title: string,\n content?: string,\n options?: SnackbarOptionsProps\n ): void => {\n enqueueSnackbar(title, content, { ...options, variant: 'success' });\n };\n\n const enqueueErrorSnackbar = (\n title: string,\n content?: string,\n options?: SnackbarOptionsProps\n ): void => {\n enqueueSnackbar(title, content, { ...options, variant: 'error' });\n };\n\n const onItemClosed = (id: string) => {\n setSnackbars((items) => [...items].filter((item) => item.id !== id));\n };\n\n const snackbarList = snackbars.map((item, index) =>\n index < stackSize ? (\n <SnackbarItem\n {...item}\n key={item.id}\n onClose={onItemClosed}\n closeButtonTitle={closeButtonTitle}\n />\n ) : null\n );\n\n const snackbarPortal = createPortal(\n <SnackbarContainer placement={placement} className={className}>\n {snackbarList}\n </SnackbarContainer>,\n domRoot\n );\n\n return (\n <SnackbarContextProvider\n initialState={{ enqueueSnackbar, enqueueSuccessSnackbar, enqueueErrorSnackbar }}\n >\n {children}\n {snackbarPortal}\n </SnackbarContextProvider>\n );\n};\n","import React, { useState } from 'react';\nimport classes from './TextareaWrapper.module.scss';\nimport { Wrapper, WrapperProps } from '../Wrapper/Wrapper';\nimport { Textarea, Props as TextareaProps } from '../../Textarea/Textarea';\nimport { useWrapper } from '../../../hooks/useWrapper';\n\nexport interface Props\n extends Omit<WrapperProps, 'onFocus' | 'onChange' | 'onBlur' | 'onMouseEnter' | 'onMouseLeave'> {\n placeholder?: string;\n textareaProps?: TextareaProps;\n value: string;\n onFocus?: (event: React.FocusEvent<HTMLTextAreaElement>) => void;\n onChange?: (event: React.ChangeEvent<HTMLTextAreaElement>) => void;\n onBlur?: (event: React.FocusEvent<HTMLTextAreaElement>) => void;\n onMouseEnter?: (event: React.MouseEvent<HTMLTextAreaElement>) => void;\n onMouseLeave?: (event: React.MouseEvent<HTMLTextAreaElement>) => void;\n}\n\nexport const TextareaWrapper = ({\n name,\n error,\n value,\n label,\n placeholder,\n textareaProps,\n helperProps,\n onChange,\n onFocus,\n onBlur,\n onMouseEnter,\n onMouseLeave,\n disabled,\n ...rest\n}: Props) => {\n const {\n errorId,\n floatingLabelActive,\n setFloatingLabelActive,\n hasFocus,\n setHasFocus,\n helperId,\n labelId,\n } = useWrapper(value, placeholder);\n\n const [focus, setFocus] = useState(false);\n const [hover, setHover] = useState(false);\n\n return (\n <Wrapper\n {...rest}\n disabled={disabled}\n labelProps={{\n id: labelId,\n className: `${classes['textarea-label']} ${hasFocus ? classes['focus'] : ''}`,\n }}\n name={name}\n label={label}\n helperId={helperId}\n helperProps={{\n ...helperProps,\n className: classes['textarea-helper-text'],\n }}\n error={error}\n floatingLabelActive={floatingLabelActive}\n errorId={errorId}\n >\n <Textarea\n {...textareaProps}\n error={error}\n aria-labelledby={label && labelId}\n aria-describedby={error ? errorId : helperId}\n placeholder={placeholder}\n value={value}\n onChange={onChange}\n onFocus={(e) => {\n onFocus && onFocus(e);\n setHasFocus(true);\n setFloatingLabelActive(true);\n setFocus(true);\n }}\n onBlur={(e) => {\n onBlur && onBlur(e);\n setHasFocus(false);\n setFocus(false);\n e.target.value || textareaProps?.placeholder?.length\n ? setFloatingLabelActive(true)\n : setFloatingLabelActive(false);\n }}\n onMouseEnter={(e) => {\n onMouseEnter && onMouseEnter(e);\n setHover(true);\n }}\n onMouseLeave={(e) => {\n onMouseLeave && onMouseLeave(e);\n setHover(false);\n }}\n className={classes['textarea']}\n wrapperClassName={`${classes['textarea-wrapper']} ${focus ? classes['focus'] : ''} ${\n hover ? classes['hover'] : ''\n } ${disabled ? classes['disabled'] : ''} ${error ? classes['error'] : ''}`}\n errorClassName={classes['error-icon']}\n />\n </Wrapper>\n );\n};\n","import React, { HTMLProps, ReactNode } from 'react';\nimport classes from './Tiles.module.scss';\nimport { Tile } from './Tile';\n\nexport interface Props extends HTMLProps<HTMLDivElement> {\n children: ReactNode;\n loading?: boolean;\n}\n\nexport const Tiles = ({ children, className, loading = false, ...rest }: Props) => {\n const renderChildren = () => {\n if (loading) {\n return [\n <Tile\n key=\"placeholder1\"\n title=\"placeholder\"\n imageProps={{ src: 'placeholder' }}\n loading={true}\n />,\n <Tile\n key=\"placeholder2\"\n title=\"placeholder\"\n imageProps={{ src: 'placeholder' }}\n loading={true}\n />,\n <Tile\n key=\"placeholder3\"\n title=\"placeholder\"\n imageProps={{ src: 'placeholder' }}\n loading={true}\n />,\n ];\n }\n\n return children;\n };\n\n return (\n <div\n {...rest}\n className={`${classes['tiles']} ${className ?? ''}`}\n aria-live=\"polite\"\n aria-busy={loading}\n >\n {renderChildren()}\n </div>\n );\n};\n","import React, { Fragment, useContext, useMemo } from 'react';\nimport { Button } from '../../Button/Button';\nimport { Step } from '../BaseWizardSteps/BaseWizardSteps';\nimport { WizardMode } from '../Wizard';\nimport { WizardStateContext } from '../WizardStateProvider';\nimport { changeCurrentStepNo } from '../wizardStateReducer';\n\nexport interface Props extends React.HTMLProps<HTMLDivElement> {\n cancelButtonLabel: string;\n previousButtonLabel: string;\n nextButtonLabel: string;\n saveAndCloseButtonLabel: string;\n onCancel: () => void;\n onNext: (currentStepNo: number) => boolean;\n onPrevious?: () => void;\n onSaveAndClose: (currentStepNo: number) => void;\n}\n\nconst calculateNextStepNo = (steps: Step[], currentStepNo: number) => () =>\n steps.findIndex((step, stepNo) => stepNo > currentStepNo && !step.disabled);\n\nconst calculatePrevStepNo = (steps: Step[], currentStepNo: number) => () => {\n const reversedCurrentStepNo = steps.length - 1 - currentStepNo;\n const reversedPrevStepNo = [...steps]\n .reverse()\n .findIndex((step, stepNo) => stepNo > reversedCurrentStepNo && !step.disabled);\n if (reversedPrevStepNo > 0) {\n return steps.length - 1 - reversedPrevStepNo;\n }\n return -1;\n};\n\nconst useNextStepNo = (mode: WizardMode, currentStepNo: number, steps: Step[]) =>\n useMemo(calculateNextStepNo(steps, currentStepNo), [mode, currentStepNo, steps]);\n\nconst usePreviousStepNo = (mode: WizardMode, currentStepNo: number, steps: Step[]) =>\n useMemo(calculatePrevStepNo(steps, currentStepNo), [mode, currentStepNo, steps]);\n\nexport const WizardActions = ({\n onCancel,\n onNext,\n onPrevious,\n onSaveAndClose,\n cancelButtonLabel,\n previousButtonLabel,\n nextButtonLabel,\n saveAndCloseButtonLabel,\n}: Props) => {\n const {\n state: { mode, steps, currentStepNo },\n dispatch,\n } = useContext(WizardStateContext);\n const nextStepNo = useNextStepNo(mode, currentStepNo, steps);\n const hasNextStep = nextStepNo !== -1;\n const previousStepNo = usePreviousStepNo(mode, currentStepNo, steps);\n const hasPreviousStep = previousStepNo !== -1;\n const isLastStepOrEditMode = !hasNextStep || mode === 'edit';\n\n const changeStepNo = (direction: 'forward' | 'backward') => {\n if (direction === 'forward') {\n hasNextStep && dispatch(changeCurrentStepNo(nextStepNo));\n } else {\n hasPreviousStep && dispatch(changeCurrentStepNo(previousStepNo));\n }\n };\n\n const onNextWrapper = () => {\n onNext(currentStepNo) && changeStepNo('forward');\n };\n\n const onPreviousWrapper = () => {\n onPrevious && onPrevious();\n changeStepNo('backward');\n };\n\n const onSaveAndCloseWrapper = () => {\n onSaveAndClose(currentStepNo);\n };\n\n return (\n <Fragment>\n <Button variant=\"text\" onClick={onCancel}>\n {cancelButtonLabel}\n </Button>\n {hasPreviousStep && (\n <Button variant=\"outline\" onClick={onPreviousWrapper}>\n {previousButtonLabel}\n </Button>\n )}\n {hasNextStep && (\n <Button variant={mode === 'edit' ? 'outline' : 'fill'} onClick={onNextWrapper}>\n {nextButtonLabel}\n </Button>\n )}\n {isLastStepOrEditMode && (\n <Button onClick={onSaveAndCloseWrapper}>{saveAndCloseButtonLabel}</Button>\n )}\n </Fragment>\n );\n};\n","import React, { useContext } from 'react';\nimport { WizardStateContext } from '../WizardStateProvider';\nimport { BaseWizardSteps } from '../BaseWizardSteps/BaseWizardSteps';\nimport { changeCurrentStepNo } from '../wizardStateReducer';\n\nexport interface Props extends Omit<React.HTMLProps<HTMLDivElement>, 'onClick'> {\n onStepClick: (currentStepNo: number, selectedStepNo: number) => boolean;\n}\n\nexport const WizardSteps = ({ onStepClick, ...restProps }: Props) => {\n const {\n state: { currentStepNo, mode, stepScreenReaderLabel, steps },\n dispatch,\n } = useContext(WizardStateContext);\n\n const onClick = (selectedStepNo: number) => {\n onStepClick(currentStepNo, selectedStepNo) && dispatch(changeCurrentStepNo(selectedStepNo));\n };\n\n return (\n <BaseWizardSteps\n {...restProps}\n onClick={onClick}\n steps={steps}\n currentStepNo={currentStepNo}\n stepScreenReaderLabel={stepScreenReaderLabel}\n futureStepsClickable={mode === 'edit'}\n />\n );\n};\n","import { useContext } from 'react';\nimport { SnackbarContext } from './SnackbarProvider/SnackbarStateProvider';\n\nexport const useSnackbar = () => useContext(SnackbarContext);\n"],"names":["e","t","n","r","document","a","s","prepend","d","singleTag","i","container","querySelector","getElementsByTagName","u","indexOf","push","c","charCodeAt","substring","styleSheet","cssText","appendChild","createTextNode","createElement","setAttribute","attributes","Object","keys","length","insertAdjacentElement","spacingNumberRegex","validVariants","Typography","children","variant","tag","style","spacing","className","rest","includes","Error","styleWithSpacing","spacingProps","entries","reduce","prev","matches","String","matchAll","cssSpacingValue","Array","from","map","Number","join","useSpacing","React","classes","BaseButton","forwardRef","ref","type","Button","color","startIcon","endIcon","additionalClasses","Link","disabled","to","component","classNames","download","rel","undefined","href","target","IconButton","iconSize","title","console","error","Fragment","readyclasses","Icons","Icon","icon","size","fontSize","labelId","id","descriptionId","BaseModal","open","onClose","containerClassName","labelledby","describedby","disableEscapeKeyDown","disableBackdrop","zIndex","domRoot","body","restProps","useEffect","querySelectorAll","removeProperty","useSetBodyScroll","createPortal","role","tabIndex","onKeyDown","event","key","stopPropagation","onClick","BaseModalContent","disableAutoFocus","contentRef","useRef","current","_contentRef$current","focus","BaseModalActions","DialogActions","align","DialogTitle","generateID","stringToWeaveIn","hashCharacters","test","Math","floor","random","slice","Dialog","secondaryLabel","restOfSecondaryAction","alignActions","primaryAction","secondaryAction","dialogId","useState","primaryLabel","label","restOfPrimaryAction","PrimaryButton","TertiaryButton","autoFocus","position","width","height","opacity","maxLength","onKeyPress","BaseModalHeader","Times","DiscardChangesDialog","onKeepEditing","onDiscardChanges","discardChangesButtonLabel","keepEditingButtonLabel","contentLabel","titleLabel","margin","defaultConfigObject","relativeElement","elementToBePositioned","transformOrigin","horizontal","vertical","placement","offset","top","right","bottom","left","usePosition","providedConfigObject","configObject","setPosition","_calculatePlacement","relEl","elDimensions","axis","placementValue","requestedReturnValue","placementOriginDefinition","_determineCenteredPlacementOrigin","value","window","_calculateInitialPlacementValue","valueWithOffset","returnValue","_configObject$offset3","_configObject$offset4","_configObject$offset5","_configObject$offset6","_configObject$offset9","_configObject$offset10","_configObject$offset11","_configObject$offset12","_applyOffsetToPlacementValue","valueCorrectionForViewportOverflow","innerWidth","innerHeight","_fixPossibleViewportOverflow","_calculatePlacementValue","direction","oppositeDirection","prevState","calculatePosition","_configObject$relativ","relativeElRect","getBoundingClientRect","elementToBePositionedDimensions","offsetHeight","offsetWidth","clonedRelEl","center","centerv","centerh","x","y","defaultPosition","Tile","imageProps","enabled","loading","tileAction","tileDescriptionID","justifyContent","Checkmark","Forbidden","readyClasses","src","alt","Image","Popover","show","anchorEl","elToBePositioned","useBodyClick","checkFunction","callbackFunction","dependingStateVariable","bodyClickListener","addEventListener","removeEventListener","SnackbarContext","createContext","enqueueSnackbar","enqueueSuccessSnackbar","enqueueErrorSnackbar","SnackbarContextProvider","Provider","initialState","SnackbarContainer","SnackbarItem","duration","content","actions","closeButtonTitle","timerHandler","callback","animatedObjectRef","animationStarted","setAnimationStarted","onAnimationEnd","_animatedObjectRef$cu2","startAnimation","useAnimation","setTimeout","clearTimeout","actionButtons","actionProp","index","onMouseEnter","onMouseLeave","TimesCircleAlt","CheckmarkCircleBreakout","InfoCircle","Fieldset","legend","legendStyle","hideLegend","background","noBackground","noPadding","required","backgroundColor","Children","child","cloneElement","props","renderChildren","FormHelperText","FormGroup","errorMessage","errorId","errorMessageIcon","errorMessageIconPosition","helperText","helperId","helperProps","helperIndent","marginLeft","message","Label","hidden","dateTypes","Input","name","wrapperProps","labeledBy","inputClassNames","iconClassNames","Warning","Select","placeholder","describedBy","searchPlaceholder","onChange","onClear","expanded","setExpanded","filter","setFilter","display","setDisplay","listPosition","setListPosition","containerReference","optionListReference","closest","rePositionList","windowHeight","containerTopWithListHeight","scrollListener","useLayoutEffect","useScroll","onOptionChangeHandler","newValue","nativeEvent","clonedEvent","constructor","defineProperty","writable","currentTarget","innerText","TimesThin","TriangleDown","isArray","onOptionSelect","selected","Textarea","rows","wrapperClassName","errorClassName","useWrapper","floatingLabelActive","setFloatingLabelActive","hasFocus","setHasFocus","Wrapper","floatingLabel","labelProps","innerClassName","labelClasses","wrapper","htmlFor","useFormSelector","identifier","setDescribedBy","parentErrorId","parentHelperId","FormSelectorWrapper","nestedChildren","containerProps","isToggle","_children$props","BaseWizardSteps","steps","currentStepNo","futureStepsClickable","stepScreenReaderLabel","generatedSteps","step","stepNo","stepState","disabledStyleClassName","clickableClassName","toLowerCase","replace","stepNumberString","getStepContent","changeCurrentStepNo","payload","reducer","state","action","WizardStateContext","dispatch","WizardStateProvider","useReducer","WizardContent","mode","onStepChange","useContext","setWizardState","useStepChanging","properties","defaultProperties","colorPrimary","colorSecondary","colorTertiary","defaultLineHeight","buttonBorderRadius","buttonBorderWidth","buttonFontSize","buttonBorderStyle","buttonFillTextColor","buttonFillBackgroundColor","buttonOutlineHoverTextColor","inputBorderColor","inputBorderRadius","inputBorderWidth","inputBorderStyle","modalShadowColor","modalBackgroundColor","modalHeaderBackgroundColor","snackbarTextColor","snackbarInfoBackgroundColor","snackbarSuccessBackgroundColor","snackbarErrorBackgroundColor","snackbarBorderRadius","success","greyedOut","warning","fontFamily","fontFamilyCode","fontSizeH1","fontSizeH2","fontSizeH3","fontSizeH4","fontSizeSub","fontSizeCode","isLoading","setIsLoading","setCSSProperties","CSSPropertiesObject","formattedPropertyName","replaceAll","val","documentElement","setProperty","mergedState","ariaLabel","items","ChevronRight","Checkbox","indeterminate","checked","iconClasses","toArray","MinusSquare","CheckmarkSquare","Square","determineLabel","fieldsetProps","trigger","onShow","showContextMenu","setShowContextMenu","hasUnsavedChanges","headerProps","discardChangedDialogProps","openDiscardChangesDialog","setOpenDiscardChangesDialog","onCloseWrapper","Modal","ModalHeader","grid","childElement","column","inputProps","onBlur","onFocus","_inputProps$placehold","showOption","setShowOption","onSelectHandler","match","onChangeHandler","Radio","Circle","selectProps","autoHideDuration","stackSize","setSnackbars","options","item","getDuration","onItemClosed","snackbarList","snackbarPortal","textareaProps","setFocus","hover","setHover","_textareaProps$placeh","visible","setVisible","escapePressHandler","isValidElement","initialStepNo","onCancel","onNext","onPrevious","onSaveAndClose","cancelButtonLabel","previousButtonLabel","nextButtonLabel","saveAndCloseButtonLabel","nextStepNo","useMemo","findIndex","calculateNextStepNo","useNextStepNo","hasNextStep","previousStepNo","reversedCurrentStepNo","reversedPrevStepNo","reverse","calculatePrevStepNo","usePreviousStepNo","hasPreviousStep","isLastStepOrEditMode","changeStepNo","onStepClick","selectedStepNo"],"mappings":"uoBAAIA,EAAE,GAAGC,EAAE,GAAG,SAASC,EAAEA,EAAEC,GAAG,GAAGD,GAAG,oBAAoBE,SAAS,CAAC,IAAIC,EAAEC,GAAE,IAAKH,EAAEI,QAAQ,UAAU,SAASC,GAAE,IAAKL,EAAEM,UAAUC,EAAE,iBAAiBP,EAAEQ,UAAUP,SAASQ,cAAcT,EAAEQ,WAAWP,SAASS,qBAAqB,QAAQ,GAAG,GAAGL,EAAE,CAAC,IAAIM,EAAEd,EAAEe,QAAQL,IAAI,IAAII,IAAIA,EAAEd,EAAEgB,KAAKN,GAAG,EAAET,EAAEa,GAAG,IAAIT,EAAEJ,EAAEa,IAAIb,EAAEa,GAAGR,GAAGL,EAAEa,GAAGR,GAAGL,EAAEa,GAAGR,GAAGW,SAASZ,EAAEY,IAAI,QAAQf,EAAEgB,WAAW,KAAKhB,EAAEA,EAAEiB,UAAU,IAAId,EAAEe,WAAWf,EAAEe,WAAWC,SAASnB,EAAEG,EAAEiB,YAAYlB,SAASmB,eAAerB,IAAI,SAASe,IAAI,IAAIjB,EAAEI,SAASoB,cAAc,SAAS,GAAGxB,EAAEyB,aAAa,OAAO,YAAYtB,EAAEuB,WAAW,IAAI,IAAIzB,EAAE0B,OAAOC,KAAKzB,EAAEuB,YAAYxB,EAAE,EAAEA,EAAED,EAAE4B,OAAO3B,IAAIF,EAAEyB,aAAaxB,EAAEC,GAAGC,EAAEuB,WAAWzB,EAAEC,KAAkD,OAAOQ,EAAEoB,sBAAhD,YAAYxB,EAAE,aAAa,YAA6CN,GAAGA,4mGCuBnuB,IAEM+B,EAAqB,6ECrBrBC,EAAgB,CAAC,KAAM,KAAM,KAAM,KAAM,OAAQ,YAAa,WAAY,QA2BnEC,EAAa,gBACxBC,I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