@onewelcome/react-lib-components 0.1.3-alpha → 0.1.4-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.
@@ -1 +1 @@
1
- {"version":3,"file":"react-lib-components.cjs.production.min.js","sources":["../src/_BaseStyling_/BaseStyling.tsx","../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/Form/Input/Input.tsx","../src/hooks/useBodyClick.ts","../src/util/helper.tsx","../src/Form/Select/Select.tsx","../src/Form/Select/Option.tsx","../src/Pagination/Pagination.tsx","../src/Form/Label/Label.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/Notifications/Dialog/Dialog.tsx","../src/Notifications/BaseModal/BaseModalHeader/BaseModalHeader.tsx","../src/Notifications/DiscardChangesModal/DiscardChangesDialog/DiscardChangesDialog.tsx","../src/hooks/usePosition.ts","../src/Popover/Popover.tsx","../src/TextEllipsis/TextEllipsis.tsx","../src/Tooltip/Tooltip.tsx","../src/Tiles/Tile.tsx","../src/Tiles/Tiles.tsx","../src/ContextMenu/ContextMenu.tsx","../src/Breadcrumbs/Breadcrumbs.tsx","../src/Notifications/Snackbar/SnackbarProvider/SnackbarStateProvider.tsx","../src/Notifications/Snackbar/SnackbarContainer/SnackbarContainer.tsx","../src/hooks/useAnimation.ts","../src/Notifications/Snackbar/SnackbarItem/SnackbarItem.tsx","../src/hooks/useFormSelector.ts","../src/Form/FormHelperText/FormHelperText.tsx","../src/Form/FormSelectorWrapper/FormSelectorWrapper.tsx","../src/Form/Radio/Radio.tsx","../src/Form/Checkbox/Checkbox.tsx","../src/Form/Textarea/Textarea.tsx","../src/Form/Toggle/Toggle.tsx","../src/Form/FormControl/FormControl.tsx","../src/Form/FormGroup/FormGroup.tsx","../src/Form/Wrapper/Wrapper/Wrapper.tsx","../src/hooks/useWrapper.ts","../src/Form/Wrapper/InputWrapper/InputWrapper.tsx","../src/Form/Wrapper/SelectWrapper/SelectWrapper.tsx","../src/Form/Wrapper/TextareaWrapper/TextareaWrapper.tsx","../src/Form/Fieldset/Fieldset.tsx","../src/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.tsx","../src/Form/Wrapper/RadioWrapper/RadioWrapper.tsx","../src/Wizard/BaseWizardSteps/BaseWizardSteps.tsx","../src/Wizard/wizardStateReducer.ts","../src/Wizard/WizardStateProvider.tsx","../src/Wizard/WizardSteps/WizardSteps.tsx","../src/Wizard/Wizard.tsx","../src/ContextMenu/ContextMenuItem.tsx","../src/Notifications/DiscardChangesModal/DiscardChangesModal.tsx","../src/Form/Form.tsx","../src/Notifications/Snackbar/SnackbarProvider/SnackbarProvider.tsx","../src/Wizard/WizardActions/WizardActions.tsx","../src/hooks/useRepeater.ts","../src/Notifications/Snackbar/useSnackbar.ts"],"sourcesContent":["import React, { Fragment, HTMLAttributes, ReactChild, useEffect, useState } from 'react';\n\ninterface CSSProperties {\n colorFocus?: string;\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 inputBackgroundColor?: 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 tabsBackgroundColor?: string;\n tabBorderWidth?: string;\n tabBorderStyle?: string;\n tablistBorderWidth?: string;\n tablistBorderStyle?: string;\n tablistBorderColor?: string;\n tabTextColor?: 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 colorFocus: '#0085f2',\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 inputBackgroundColor: '#FFF',\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 tabsBackgroundColor: '#FFF',\n tabBorderWidth: '2px',\n tabBorderStyle: 'solid',\n tablistBorderWidth: '1px',\n tablistBorderStyle: 'solid',\n tablistBorderColor: '#C3C3C7',\n tabTextColor: '#0f0f1e',\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.replace(/([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","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\nexport type 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, { ComponentPropsWithRef, 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\ntype Tags =\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\n/** I couldn't find anything on the internet that indicated that ComponentPropsWithRef can take multiple tags. Since the TagName can be many different things I have to use any here. Using a mix of tags (like the Tags type) will throw an error. */\nexport interface Props extends ComponentPropsWithRef<any> {\n children: ReactNode;\n variant: Variant;\n tag?: Tags;\n spacing?: Spacing;\n}\n\nexport const Typography = React.forwardRef<any, Props>(\n ({ children, variant, tag, style, spacing, className = '', ...rest }: Props, ref) => {\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 ref={ref}\n style={styleWithSpacing}\n className={`${classes['typography_style_' + variant]} ${className}`}\n >\n {children}\n </TagName>\n );\n }\n);\n","import React, { ComponentPropsWithRef } from 'react';\nimport classes from './BaseButton.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'button'> {\n type?: 'submit' | 'button' | 'reset';\n disabled?: boolean;\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 from 'react';\nimport { BaseButton, Props as BaseButtonProps } from './BaseButton';\nimport classes from './Button.module.scss';\n\nexport interface Props extends BaseButtonProps {\n startIcon?: React.ReactNode | false;\n endIcon?: React.ReactNode | false;\n children?: React.ReactNode;\n variant?: 'text' | 'fill' | 'outline';\n}\n\nexport const Button = React.forwardRef<HTMLButtonElement, Props>(\n (\n {\n children,\n variant = 'fill',\n color = 'primary',\n startIcon = false,\n endIcon = false,\n className,\n ...rest\n },\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 if (className) {\n additionalClasses.push(className);\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, { ComponentPropsWithRef, ForwardRefExoticComponent, RefAttributes } from 'react';\nimport classes from './Link.module.scss';\nimport { LinkProps } from './types';\n\ntype AnchorType = 'external' | 'internal' | 'download';\n\nexport interface Props extends ComponentPropsWithRef<'a'> {\n children?: string;\n color?: 'primary' | 'secondary' | 'tertiary';\n type?: AnchorType;\n to: string;\n disabled?: boolean;\n component?: ForwardRefExoticComponent<LinkProps & RefAttributes<HTMLAnchorElement>>;\n}\n\nexport const Link = React.forwardRef<HTMLAnchorElement, Props>(\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\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 } 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 BaseButtonProps {\n children?: React.ReactNode;\n iconSize?: 's' | 'm' | 'l';\n className?: string;\n title?: string;\n}\n\nexport const IconButton = React.forwardRef<HTMLButtonElement, Props>(\n ({ children, color = 'primary', iconSize = 'm', title, className, ...rest }, ref) => {\n if (!title) {\n console.error(\"Please make sure to specify a 'title' prop to your IconButton component! \");\n }\n\n const iconButtonClasses = [\n classes['icon-button'],\n classes[color],\n classes['button-' + iconSize],\n ];\n\n if (className) {\n iconButtonClasses.push(className);\n }\n\n return (\n <BaseButton {...rest} ref={ref} className={iconButtonClasses.join(' ')}>\n <Fragment>\n {children}\n <span className={readyclasses['sr-only']}>{title}</span>\n </Fragment>\n </BaseButton>\n );\n }\n);\n","import React, { ComponentPropsWithRef } from 'react';\nimport classes from './Icon.module.scss';\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 Error = 'error-circle',\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 ComponentPropsWithRef<'div'> {\n icon: Icons;\n color?: string;\n size?: string;\n tag?: Tag;\n}\n\nexport const Icon = React.forwardRef<HTMLDivElement, Props>(\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}\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","import React, { ComponentPropsWithRef, Ref, useEffect, useState } from 'react';\nimport classes from './Input.module.scss';\nimport readyclasses from '../../readyclasses.module.scss';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { FormElement } from '../form.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 ComponentPropsWithRef<'input'>, FormElement {\n wrapperProps?: ComponentPropsWithRef<'div'>;\n labeledBy?: string;\n type: Type;\n suffix?: string;\n prefix?: string;\n}\n\nexport const Input = React.forwardRef(\n (\n {\n error = false,\n className,\n name,\n style,\n wrapperProps,\n type,\n labeledBy,\n prefix,\n suffix,\n disabled,\n onFocus,\n onBlur,\n ...rest\n }: Props,\n ref: Ref<HTMLInputElement>\n ) => {\n const [focus, setFocus] = useState(false);\n\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\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 const wrapperClasses = [classes['input-wrapper']];\n\n wrapperProps?.className && wrapperClasses.push(wrapperProps.className);\n type === 'hidden' && wrapperClasses.push(readyclasses['hidden']);\n prefix && wrapperClasses.push(classes['prefix']);\n suffix && wrapperClasses.push(classes['suffix']);\n disabled && wrapperClasses.push(classes['disabled']);\n error && wrapperClasses.push(classes['error']);\n focus && wrapperClasses.push(classes['focus']);\n\n return (\n <div\n {...wrapperProps}\n style={{ ...style }}\n className={`${classes['input-wrapper']} ${wrapperClasses.join(' ')}`}\n >\n {prefix && (\n <div data-prefix className={classes['prefix']}>\n <span>{prefix}</span>\n </div>\n )}\n <input\n {...rest}\n ref={ref}\n onFocus={(event) => {\n setFocus(true);\n onFocus && onFocus(event);\n }}\n onBlur={(event) => {\n setFocus(false);\n onBlur && onBlur(event);\n }}\n aria-labelledby={labeledBy}\n type={type}\n name={name}\n disabled={disabled}\n className={inputClassNames.join(' ')}\n />\n {suffix && (\n <div data-suffix className={classes['suffix']}>\n <span>{suffix}</span>\n </div>\n )}\n {error && <Icon className={iconClassNames.join(' ')} icon={Icons.Error} />}\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","type KeyValuePair = { [key: string]: unknown };\n\nexport 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\nexport const filterProps = (props: any, regexPattern: RegExp, returnFiltered: boolean = true) => {\n if (returnFiltered) {\n return Object.keys(props).reduce((acc: KeyValuePair, key) => {\n if (regexPattern.test(key)) {\n acc[key] = props[key];\n }\n\n return acc;\n }, {});\n } else {\n return Object.entries(props)\n .filter(([key]) => !regexPattern.test(key))\n .reduce(\n (prevObj, currKeyValPair) => ({ ...prevObj, [currKeyValPair[0]]: currKeyValPair[1] }),\n {}\n );\n }\n};\n","import classes from './Select.module.scss';\n\nimport React, {\n ComponentPropsWithRef,\n Fragment,\n ReactElement,\n RefObject,\n useEffect,\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 readyclasses from '../../readyclasses.module.scss';\nimport { filterProps } from '../../util/helper';\n\nexport interface Props extends ComponentPropsWithRef<'select'>, FormElement {\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\ntype Position = {\n top: 0 | 'initial';\n bottom: 0 | 'initial';\n};\n\nexport const Select = React.forwardRef<HTMLSelectElement, Props>(\n (\n {\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 ref\n ) => {\n const [expanded, setExpanded] = useState(false);\n const [opacity, setOpacity] = useState(0); // We set opacity because other wise if we calculate the max height you see the list full height for a split second and then it shortens.\n const [filter, setFilter] = useState('');\n const [display, setDisplay] = useState('');\n const [listPosition, setListPosition] = useState<Partial<Position>>({});\n const [optionsListMaxHeight, setOptionsListMaxHeight] = useState('none');\n const containerReference = useRef<HTMLDivElement>(null);\n const optionListReference = useRef<HTMLDivElement>(null);\n\n const nativeSelect = useRef<HTMLSelectElement>(null);\n\n const syncDisplayValue = (val: string) => {\n React.Children.forEach(children, (child) => {\n if (child.props.value === val) {\n setDisplay(child.props.children);\n }\n });\n };\n\n const rePositionList = () => {\n if (!expanded || !optionListReference.current || !containerReference.current) {\n return;\n }\n\n // Check whether there is more space above or below the select\n // Check space between the bottom of select and top of viewport\n const spaceOnTopOfSelect = containerReference.current.getBoundingClientRect().bottom;\n\n // Check space between the top of the select and bottom of viewport\n const spaceOnBottomOfSelect =\n window.innerHeight - containerReference.current.getBoundingClientRect().top;\n\n // Set position as if there's more space on the bottom\n let position: Position = { top: 0, bottom: 'initial' };\n\n // Set the position of the select\n if (spaceOnTopOfSelect > spaceOnBottomOfSelect) {\n position = { top: 'initial', bottom: 0 };\n }\n\n setListPosition(position);\n\n // Calculate the potential max height of the options list\n calculateOptionListMaxHeight(position);\n };\n\n const calculateOptionListMaxHeight = (position: Position) => {\n // Calculate max height if there's more space below the select\n const listHeight = optionListReference.current!.getBoundingClientRect().height;\n const transformOrigin = position.top !== 'initial' ? 'top' : 'bottom';\n\n const availableSpace =\n transformOrigin === 'top'\n ? window.innerHeight -\n containerReference.current!.getBoundingClientRect()[transformOrigin] -\n 16\n : containerReference.current!.getBoundingClientRect()[transformOrigin] - 16;\n\n if (availableSpace < listHeight) {\n setOptionsListMaxHeight(`${availableSpace}px`);\n setOpacity(100);\n return;\n }\n\n setOptionsListMaxHeight('none');\n setOpacity(100);\n };\n\n const onOptionChangeHandler = (event: React.MouseEvent<HTMLLIElement>) => {\n // We need to set value and the fire change event. If a custom ref has been given we pass that value, otherwise we use the ref we've created ourselves when the component was instantiated.\n if (nativeSelect.current) {\n nativeSelect.current.value = event.currentTarget.dataset.value!;\n nativeSelect.current.dispatchEvent(new Event('change', { bubbles: true }));\n } else if (ref) {\n (ref as RefObject<HTMLSelectElement>).current!.value = event.currentTarget.dataset.value!;\n (ref as RefObject<HTMLSelectElement>).current!.dispatchEvent(\n new Event('change', { bubbles: true })\n );\n }\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,\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\n if (value?.length !== 0 && onClear) {\n return (\n <Icon\n tag=\"div\"\n data-clear\n icon={Icons.TimesThin}\n onClick={(e: React.MouseEvent<HTMLDivElement, MouseEvent>) => {\n e.preventDefault();\n e.stopPropagation();\n onClear(e);\n }}\n />\n );\n }\n return null;\n };\n\n const nativeOnChangeHandler = (event: React.ChangeEvent<HTMLSelectElement>) => {\n onChange && onChange(event);\n };\n\n useEffect(() => {\n syncDisplayValue(value);\n }, [value]);\n\n useEffect(() => {\n rePositionList();\n }, [expanded]);\n\n useBodyClick(\n (event: MouseEvent) => !(event.target as Element).closest('.custom-select') && expanded,\n () => {\n setExpanded(!expanded);\n setListPosition({ top: 0, bottom: 'initial' });\n setOpacity(0);\n },\n expanded\n );\n\n const additionalClasses = [];\n expanded && additionalClasses.push(classes.expanded);\n error && additionalClasses.push(classes.error);\n disabled && additionalClasses.push(classes.disabled);\n className && additionalClasses.push(className);\n\n /** The native select is purely for external form libraries. We use it to emit an onChange with native select event object so they know exactly what's happening. */\n return (\n <Fragment>\n <select\n {...filterProps(rest, /^data-/, false)}\n tabIndex={-1}\n aria-hidden=\"true\"\n ref={ref || nativeSelect}\n name={name}\n onChange={nativeOnChangeHandler}\n className={readyclasses['sr-only']}\n >\n <option value=\"\"></option>\n {React.Children.map(children, (child) => (\n <option value={child.props.value}></option>\n ))}\n </select>\n <div\n {...filterProps(rest, /^data-/)}\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 && 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={{\n display: expanded ? 'block' : 'none',\n opacity: opacity,\n maxHeight: optionsListMaxHeight,\n ...listPosition,\n }}\n >\n {Array.isArray(children) && children.length > 10 && renderSearch()}\n <ul role=\"listbox\" tabIndex={-1}>\n {renderOptions()}\n </ul>\n </div>\n </div>\n </Fragment>\n );\n }\n);\n","import React, { ComponentPropsWithRef, useEffect, useState } from 'react';\nimport classes from './Select.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'li'> {\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 = React.forwardRef<HTMLLIElement, Props>(\n (\n {\n children,\n className,\n selected = false,\n onOptionSelect,\n disabled,\n filter,\n value,\n ...rest\n }: Props,\n ref\n ) => {\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 ref={ref}\n data-value={value}\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);\n","import React, { ComponentPropsWithRef, Fragment, useState } from 'react';\nimport classes from './Pagination.module.scss';\nimport readyclasses from '../readyclasses.module.scss';\nimport { IconButton } from '../Button/IconButton';\nimport { Icons, Icon } from '../Icon/Icon';\nimport { Input } from '../Form/Input/Input';\nimport { Select } from '../Form/Select/Select';\nimport { Option } from '../Form/Select/Option';\nimport { Label } from '../Form/Label/Label';\n\nexport type PaginationTranslations = {\n totalItems: string;\n itemsPerPage: string;\n itemsPerPageLabel: string;\n currentPage: string;\n currentPageLabel: string;\n};\n\nexport type PageChangeLabels = 'next' | 'previous' | 'first' | 'last';\n\nenum DefaultTranslations {\n totalItems = 'Total items',\n itemsPerPage = 'Items per page',\n currentPage = 'Page %1 of %2',\n itemsPerPageLabel = 'Select how many items per page you want to see.',\n currentPageLabel = 'What page you are currently on.',\n}\n\nexport type PageSize = 10 | 25 | 50;\n\nexport interface Props extends Omit<ComponentPropsWithRef<'div'>, 'translate'> {\n currentPage?: number;\n totalElements?: number;\n pageSize?: PageSize;\n translate?: PaginationTranslations;\n onPageChange: (pageToGoTo: number) => void;\n onPageSizeChange: (pageSize: PageSize) => void;\n}\n\nexport const Pagination = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n totalElements,\n pageSize = 10,\n translate = DefaultTranslations,\n currentPage,\n className,\n onPageChange,\n onPageSizeChange,\n ...rest\n }: Props,\n ref\n ) => {\n /** We use an internal state variable, because we don't want to fire onCurrentPageChange whenever onChange fires on the input. Rather, only when the Enter key is pressed. */\n const [internalCurrentPage, setInternalCurrentPage] = useState(currentPage?.toString() || '1');\n const calculateAmountOfPages = () => (totalElements ? Math.ceil(totalElements / pageSize) : 0);\n\n const onEnterListener = (event: React.KeyboardEvent<HTMLInputElement>) => {\n if (event.code === 'Enter') {\n onPageChange(Number(internalCurrentPage));\n }\n };\n\n const renderCurrentPageTranslation = () => {\n const amountOfPages = calculateAmountOfPages();\n\n if (amountOfPages) {\n const splitCurrentPageTranslation = translate.currentPage.split(' ');\n\n return splitCurrentPageTranslation.map((string) => {\n if (string.includes('%1')) {\n return (\n <Fragment key={string}>\n <Label\n id=\"current-value-input-label\"\n htmlFor=\"current-value-input\"\n className={readyclasses['sr-only']}\n >\n {translate.currentPageLabel}\n </Label>\n <Input\n aria-labelledby=\"current-value-input-label\"\n key=\"input\"\n id=\"current-value-input\"\n type=\"text\"\n size={currentPage?.toString().length}\n max={calculateAmountOfPages()}\n wrapperProps={{ className: classes['current-value-input'] }}\n onKeyUp={onEnterListener}\n onBlur={(event: React.ChangeEvent<HTMLInputElement>) =>\n onPageChange(Number(event.target.value))\n }\n onChange={(e: React.ChangeEvent<HTMLInputElement>) =>\n setInternalCurrentPage(e.target.value)\n }\n name=\"current-value-input\"\n value={internalCurrentPage}\n className={`${classes['form-element']} ${classes['current-page-input']}`}\n />\n </Fragment>\n );\n }\n\n if (string.includes('%2')) {\n return <div key={string}>{string.replace('%2', amountOfPages.toString())}&nbsp;</div>;\n }\n\n return <div key={string}>{string}&nbsp;</div>;\n });\n }\n\n return null;\n };\n\n const onPageSizeChangeHandler = (event: React.ChangeEvent<HTMLSelectElement>) => {\n const pageSizeNumber = Number(event.target.value) as PageSize;\n onPageSizeChange(pageSizeNumber);\n };\n\n const onPageChangeHandler = (pageToGoTo: number) => {\n onPageChange(pageToGoTo);\n };\n\n return (\n <div\n {...rest}\n ref={ref}\n className={`${classes['pagination-wrapper']} ${className ? className : ''}`}\n >\n {totalElements && (\n <div className={classes['total']}>\n <span tabIndex={0}>\n {translate.totalItems}: <span>{totalElements}</span>\n </span>\n </div>\n )}\n <div className={classes['pagination']}>\n {totalElements && pageSize && (\n <div className={classes['per-page']}>\n <Label id=\"page-size-select-label\">{translate.itemsPerPage}</Label>\n <Select\n labeledBy=\"page-size-select-label\"\n className={`${classes['form-element']} ${classes['page-size-select']}`}\n value={pageSize.toString()}\n onChange={onPageSizeChangeHandler}\n >\n <Option value=\"10\">10</Option>\n <Option value=\"25\">25</Option>\n <Option value=\"50\">50</Option>\n </Select>\n </div>\n )}\n <Fragment>\n {((currentPage && currentPage > 2) || (currentPage && currentPage > 1)) && (\n <div className={classes['previous']}>\n {currentPage > 2 && (\n <IconButton\n title=\"first\"\n onClick={() => onPageChangeHandler(0)}\n data-paginate=\"first\"\n >\n <Icon icon={Icons.NavigationFirst} />\n </IconButton>\n )}\n {currentPage > 1 && (\n <IconButton\n title=\"previous\"\n onClick={() => onPageChangeHandler(currentPage - 1)}\n data-paginate=\"previous\"\n >\n <Icon icon={Icons.ChevronLeft} />\n </IconButton>\n )}\n </div>\n )}\n {totalElements && (\n <div className={classes['page']}>{renderCurrentPageTranslation()}</div>\n )}\n <div className={classes['next']}>\n {((currentPage && currentPage < calculateAmountOfPages()) ||\n (currentPage && !totalElements)) && (\n <IconButton\n title=\"next\"\n onClick={() => onPageChangeHandler(currentPage + 1)}\n data-paginate=\"next\"\n >\n <Icon icon={Icons.ChevronRight} />\n </IconButton>\n )}\n {currentPage && totalElements && currentPage < calculateAmountOfPages()! - 1 && (\n <IconButton\n title=\"last\"\n onClick={() => onPageChangeHandler(totalElements / pageSize)}\n data-paginate=\"last\"\n >\n <Icon icon={Icons.NavigationLast} />\n </IconButton>\n )}\n </div>\n </Fragment>\n </div>\n </div>\n );\n }\n);\n","import React, { ComponentPropsWithRef, ReactNode } from 'react';\nimport classes from './Label.module.scss';\nimport readyclasses from '../../readyclasses.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'label'> {\n children?: ReactNode;\n}\n\nexport const Label = React.forwardRef<HTMLLabelElement, Props>(\n ({ children, className, hidden = false, ...rest }: Props, ref) => {\n return (\n <label\n {...rest}\n ref={ref}\n className={`${hidden ? readyclasses['sr-only'] : ''} ${classes['label']} ${\n className ?? ''\n }`}\n >\n {children}\n </label>\n );\n }\n);\n","export const labelId = (id: string) => `${id}-label`;\nexport const descriptionId = (id: string) => `${id}-description`;\n","import React, { ComponentPropsWithRef, useEffect } from 'react';\nimport { createPortal } from 'react-dom';\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 ComponentPropsWithRef<'div'> {\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 = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ...rest\n }: Props,\n ref\n ) => {\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 {...rest}\n ref={ref}\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);\n","import React, { ComponentPropsWithRef, createRef, useEffect } from 'react';\nimport classes from './BaseModalContent.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n id?: string;\n children: React.ReactNode;\n className?: string;\n disableAutoFocus?: boolean;\n}\n\nexport const BaseModalContent = React.forwardRef<HTMLDivElement, Props>(\n ({ id, children, className = '', disableAutoFocus = false, ...rest }: Props, ref) => {\n const contentRef = createRef<HTMLDivElement>();\n\n useEffect(() => {\n if (!disableAutoFocus && ref) {\n (ref as React.RefObject<HTMLDivElement>).current?.focus();\n } else if (!disableAutoFocus) {\n contentRef.current?.focus();\n }\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 {...rest}\n ref={ref || contentRef}\n id={id}\n className={`${classes['content']} ${className}`}\n tabIndex={-1}\n >\n {children}\n </div>\n );\n }\n);\n","import React, { ComponentPropsWithRef } from 'react';\nimport classes from './BaseModalActions.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'footer'> {\n children?: React.ReactNode;\n}\n\nexport const BaseModalActions = React.forwardRef<HTMLElement, Props>(\n ({ children, className = '', ...rest }: Props, ref) => {\n return (\n <footer {...rest} ref={ref} className={`${classes['actions']} ${className}`}>\n {children}\n </footer>\n );\n }\n);\n","import React, { ComponentPropsWithRef } 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 ComponentPropsWithRef<any>, BaseModalActionsProps {\n align: 'left' | 'right';\n}\n\nexport const DialogActions = React.forwardRef<HTMLElement, Props>(\n ({ children, align, ...rest }: Props, ref) => {\n return (\n <BaseModalActions\n {...rest}\n ref={ref}\n className={`${classes['actions']}${align === 'left' ? ' ' + classes['left'] : ''}`}\n >\n {children}\n </BaseModalActions>\n );\n }\n);\n","import React, { ComponentPropsWithRef } from 'react';\nimport { Typography } from '../../../Typography/Typography';\nimport classes from './DialogTitle.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n id: string;\n title: string;\n}\n\nexport const DialogTitle = React.forwardRef<HTMLDivElement, Props>(\n ({ id, title, ...rest }: Props, ref) => {\n return (\n <div {...rest} ref={ref} className={classes['header']}>\n <Typography id={id} className={classes['title']} tag=\"h1\" variant=\"h4\">\n {title}\n </Typography>\n </div>\n );\n }\n);\n","import React, { ComponentPropsWithRef, 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 ComponentPropsWithRef<'div'> {\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 = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n id,\n open,\n children,\n alignActions,\n onClose,\n title,\n primaryAction,\n secondaryAction,\n zIndex,\n disableEscapeKeyDown = true,\n ...rest\n }: Props,\n ref\n ) => {\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 {...rest}\n ref={ref}\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);\n","import React, { ComponentPropsWithRef } 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 ComponentPropsWithRef<'div'> {\n id: string;\n title: string;\n children?: React.ReactNode;\n onClose: (event: React.MouseEvent<HTMLButtonElement>) => void;\n}\n\nexport const BaseModalHeader = React.forwardRef<HTMLDivElement, Props>(\n ({ id, title, children, onClose, ...rest }: Props, ref) => {\n return (\n <div {...rest} ref={ref} 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);\n","import React, { ComponentPropsWithRef } from 'react';\nimport { Dialog } from '../../Dialog/Dialog';\nimport { Typography } from '../../../Typography/Typography';\nimport { DataAttributeKey } from '../../../interfaces';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n open: boolean;\n discardChangesButtonLabel: string;\n keepEditingButtonLabel: string;\n contentLabel: string;\n titleLabel: string;\n [dataAttribute: DataAttributeKey]: any;\n onKeepEditing: () => void;\n onDiscardChanges: () => void;\n}\n\nexport const DiscardChangesDialog = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n open,\n onKeepEditing,\n onDiscardChanges,\n discardChangesButtonLabel,\n keepEditingButtonLabel,\n contentLabel,\n titleLabel,\n ...rest\n }: Props,\n ref\n ) => {\n return (\n <Dialog\n {...rest}\n ref={ref}\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);\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, { ComponentPropsWithRef, ReactNode, RefObject, useEffect, useRef } from 'react';\nimport { usePosition, Offset, Placement } from '../hooks/usePosition';\nimport classes from './Popover.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n children?: ReactNode;\n show?: boolean;\n anchorEl?: RefObject<HTMLOrSVGElement>;\n placement?: Placement;\n offset?: Offset;\n transformOrigin?: Placement;\n}\n\nexport const Popover = React.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 React, { useRef, MouseEventHandler, useState, ComponentPropsWithRef } from 'react';\nimport { Popover } from '../Popover/Popover';\nimport classes from './TextEllipsis.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n children?: string;\n popoverClassName?: string;\n}\n\nexport const TextEllipsis = React.forwardRef<HTMLDivElement, Props>(\n ({ children, popoverClassName, className, ...rest }: Props, ref) => {\n const [showPopover, setShowPopover] = useState(false);\n const textContainer = useRef<HTMLDivElement>(null);\n\n const ellipsisVisible = () => {\n if (\n textContainer.current &&\n textContainer.current.offsetWidth < textContainer.current.scrollWidth\n ) {\n return true;\n }\n return false;\n };\n\n const onMouseEnter: MouseEventHandler<HTMLDivElement> = () => {\n ellipsisVisible() && setShowPopover(true);\n };\n\n const onMouseLeave: MouseEventHandler<HTMLDivElement> = () => {\n ellipsisVisible() && setShowPopover(false);\n };\n\n return (\n <div\n {...rest}\n onMouseEnter={onMouseEnter}\n onMouseLeave={onMouseLeave}\n className={`${classes['text-ellipsis']} ${className ?? ''}`}\n ref={ref || textContainer}\n >\n {children}\n <Popover\n aria-hidden={true}\n data-hidden={!showPopover}\n show={showPopover}\n role=\"tooltip\"\n anchorEl={textContainer}\n className={`${classes.popover} ${popoverClassName ?? ''}`}\n >\n {children}\n </Popover>\n </div>\n );\n }\n);\n","import React, {\n ComponentPropsWithRef,\n ReactNode,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} 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 ComponentPropsWithRef<'div'> {\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 = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ref\n ) => {\n const [identifier] = useState(generateID());\n const [visible, setVisible] = useState(false);\n\n const relativeElement = useRef<HTMLDivElement>(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} ref={ref} 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);\n","import React, { ComponentPropsWithRef, 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 ComponentPropsWithRef<'div'> {\n title: string;\n imageProps?: ImageProps;\n enabled?: boolean;\n loading?: boolean;\n tileAction?: ReactElement<ContextMenuProps> | ReactElement<IconButtonProps>;\n}\n\nexport const Tile = React.forwardRef<HTMLDivElement, Props>(\n ({ title, imageProps, enabled, className, loading, tileAction, ...rest }: Props, ref) => {\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 {...rest}\n tabIndex={0}\n aria-labelledby={tileDescriptionID}\n ref={ref}\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']}>\n {!loading && <img {...imageProps} alt=\"\" />}\n </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);\n","import React, { ComponentPropsWithRef, ReactNode } from 'react';\nimport classes from './Tiles.module.scss';\nimport { Tile } from './Tile';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n children: ReactNode;\n loading?: boolean;\n}\n\nexport const Tiles = React.forwardRef<HTMLDivElement, Props>(\n ({ children, className, loading = false, ...rest }: Props, ref) => {\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 ref={ref}\n className={`${classes['tiles']} ${className ?? ''}`}\n aria-live=\"polite\"\n aria-busy={loading}\n >\n {renderChildren()}\n </div>\n );\n }\n);\n","import React, { ComponentPropsWithRef, 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 ComponentPropsWithRef<'div'> {\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 = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ref\n ) => {\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} ref={ref} 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);\n","import React, { ComponentPropsWithRef, Fragment, 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 ComponentPropsWithRef<'div'> {\n children: ChildrenType | ChildrenType[];\n 'aria-label': string;\n}\n\nexport const Breadcrumbs = React.forwardRef<HTMLDivElement, Props>(\n ({ children, 'aria-label': ariaLabel, className = '', ...rest }: Props, ref) => {\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\n {...rest}\n ref={ref}\n aria-label={ariaLabel}\n className={`${classes['breadcrumbs']} ${className}`}\n >\n {items}\n </nav>\n );\n }\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.Error;\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 { 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, { ComponentPropsWithRef, ReactNode } from 'react';\nimport classes from './FormHelperText.module.scss';\nimport { Typography } from '../../Typography/Typography';\nimport { FormElement } from '../form.interfaces';\n\nexport interface Props extends ComponentPropsWithRef<'div'>, FormElement {\n children?: ReactNode;\n}\n\nexport const FormHelperText = React.forwardRef<HTMLDivElement, Props>(\n ({ children, error, className, ...rest }: Props, ref) => {\n return (\n <Typography\n {...rest}\n ref={ref}\n variant=\"sub-text\"\n tag=\"div\"\n className={`${classes['form-helper-text']} ${error ? classes.error : ''} ${\n className ?? ''\n }`}\n >\n {children}\n </Typography>\n );\n }\n);\n","import React, { ComponentPropsWithRef, createRef, ReactNode } from 'react';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { KeyValuePair } from '../../interfaces';\nimport { FormSelector } from '../form.interfaces';\nimport { FormHelperText, Props as FormHelperTextProps } from '../FormHelperText/FormHelperText';\nimport classes from './FormSelectorWrapper.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'>, FormSelector {\n children?: ReactNode;\n nestedChildren?: ReactNode;\n containerProps?: ComponentPropsWithRef<'div'> & KeyValuePair;\n helperProps?: FormHelperTextProps;\n disabled?: boolean;\n errorId?: string;\n identifier?: string;\n}\n\nexport const FormSelectorWrapper = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ref\n ) => {\n const helperRef = helperProps?.ref || createRef();\n\n return (\n <div\n {...rest}\n ref={ref}\n className={`${error ? classes['error'] : ''} ${disabled ? classes['disabled'] : ''} ${\n className ?? ''\n }`}\n >\n <div {...containerProps}>{children}</div>\n {(helperText || (helperProps && helperProps.children)) &&\n (!error || parentErrorId || !errorMessage) && (\n <FormHelperText\n {...helperProps}\n ref={helperRef}\n id={`${identifier}`}\n className={`${classes['helper-text']} ${helperProps?.className ?? ''} ${\n error ? classes['error'] : ''\n }`}\n >\n {(helperProps && helperProps.children) || helperText}\n </FormHelperText>\n )}\n {errorMessage && !parentErrorId && error && (\n <span className={classes['error-message']}>\n <Icon className={classes['error-icon']} icon={Icons.Error} />\n <span id={errorId}>{errorMessage}</span>\n </span>\n )}\n {nestedChildren}\n </div>\n );\n }\n);\n","import React, { ComponentPropsWithRef } 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 {\n FormSelectorWrapper,\n Props as FormSelectorWrapperProps,\n} from '../FormSelectorWrapper/FormSelectorWrapper';\n\nexport interface Props extends ComponentPropsWithRef<'input'>, FormSelector {\n children: string;\n value: string;\n formSelectorWrapperProps?: FormSelectorWrapperProps;\n helperProps?: HelperProps;\n}\n\nexport const Radio = React.forwardRef<HTMLInputElement, Props>(\n (\n {\n children,\n disabled,\n className,\n value,\n name,\n helperText,\n parentErrorId,\n parentHelperId,\n error,\n errorMessage,\n checked = false,\n formSelectorWrapperProps,\n helperProps,\n onChange,\n ...rest\n }: Props,\n ref\n ) => {\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 {...formSelectorWrapperProps}\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 ref={ref}\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);\n","import React, { ComponentPropsWithRef, 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 {\n FormSelectorWrapper,\n Props as FormSelectorWrapperProps,\n} from '../FormSelectorWrapper/FormSelectorWrapper';\nimport { FormSelector } from '../form.interfaces';\n\nconst isToggle = (children: ReactNode) => (children as ReactElement)?.props?.['data-toggle'];\n\nexport interface CheckboxProps extends ComponentPropsWithRef<'input'>, FormSelector {\n children: ReactNode;\n label?: string;\n indeterminate?: boolean;\n helperProps?: FormHelperTextProps;\n formSelectorWrapperProps?: FormSelectorWrapperProps;\n onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;\n}\n\nexport const Checkbox = React.forwardRef<HTMLInputElement, CheckboxProps>(\n (\n {\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 formSelectorWrapperProps,\n onChange,\n ...rest\n }: CheckboxProps,\n ref\n ) => {\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 {...formSelectorWrapperProps}\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 ref={ref}\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 && (\n <Icon className={iconClasses.join(' ')} icon={Icons.Square} />\n )}\n <label htmlFor={`${identifier}-checkbox`}>{determineLabel()}</label>\n </FormSelectorWrapper>\n );\n }\n);\n","import React, { ComponentPropsWithRef } from 'react';\nimport { Icon, Props as IconProps, Icons } from '../../Icon/Icon';\nimport classes from './Textarea.module.scss';\nimport { FormElement } from '../form.interfaces';\n\ninterface IconPropsPartial extends Omit<Partial<IconProps>, 'ref'> {}\n\nexport interface Props extends ComponentPropsWithRef<'textarea'>, FormElement {\n wrapperProps?: ComponentPropsWithRef<'div'>;\n errorProps?: IconPropsPartial;\n}\n\nexport const Textarea = React.forwardRef<HTMLTextAreaElement, Props>(\n (\n {\n error = false,\n disabled = false,\n className,\n rows = 4,\n wrapperProps,\n errorProps,\n ...rest\n }: Props,\n ref\n ) => {\n return (\n <div\n {...wrapperProps}\n className={`${classes['textarea-wrapper']} ${wrapperProps?.className ?? ''}`}\n >\n <textarea\n {...rest}\n ref={ref}\n rows={rows}\n className={`${error ? classes['error'] : ''} ${classes['textarea']} ${className ?? ''}`}\n disabled={disabled}\n />\n {error && (\n <Icon\n {...errorProps}\n className={`${classes['warning']} ${errorProps?.className ?? ''}`}\n icon={Icons.Error}\n />\n )}\n </div>\n );\n }\n);\n","import React, { ComponentPropsWithRef } from 'react';\nimport { Checkbox, CheckboxProps } from '../Checkbox/Checkbox';\nimport classes from './Toggle.module.scss';\n\nexport interface Props\n extends ComponentPropsWithRef<'input'>,\n Omit<CheckboxProps, 'indeterminate' | 'errorMessage' | 'error' | 'children' | 'label'> {\n children: string;\n}\n\nexport const Toggle = React.forwardRef<HTMLInputElement, Props>(\n ({ children, checked, disabled, ...rest }: Props, ref) => (\n <div className={classes['toggle-wrapper']}>\n <Checkbox\n {...rest}\n ref={ref}\n checked={checked}\n className={classes['checkbox']}\n helperProps={{ className: classes['toggle-helper'] }}\n disabled={disabled}\n label={children}\n >\n <span\n data-toggle\n aria-hidden=\"true\"\n className={`${classes['toggle']} ${checked ? classes['checked'] : ''} ${\n disabled ? classes['disabled'] : ''\n } `}\n ></span>\n </Checkbox>\n </div>\n )\n);\n","import React, { ComponentPropsWithRef, ReactElement } from 'react';\nimport classes from './FormControl.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n children?: ReactElement | ReactElement[];\n grid?: 1 | 2 | 3;\n align?: 'top' | 'start' | 'middle' | 'center' | 'bottom' | 'end' | 'stretch';\n error?: boolean;\n disabled?: boolean;\n}\n\nexport const FormControl = React.forwardRef<HTMLDivElement, Props>(\n ({ children, disabled, error, className, grid, align = 'center', ...rest }: Props, ref) => {\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 (\n <div className={`${classes['col-' + grid]} ${classes.column}`}>{childElement}</div>\n );\n }\n\n return childElement;\n });\n\n return (\n <div\n {...rest}\n ref={ref}\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);\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, { ComponentPropsWithRef, ReactChild } from 'react';\nimport classes from './FormGroup.module.scss';\nimport { FormHelperText, Props as HelperProps } from '../FormHelperText/FormHelperText';\nimport { Icon, Icons } from '../../Icon/Icon';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\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 disabled?: boolean;\n}\n\nexport const FormGroup = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ref\n ) => {\n return (\n <div\n {...rest}\n ref={ref}\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 {(helperProps && helperProps.children) || 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);\n","import React, { ComponentPropsWithRef, 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 { FormElement } from '../../form.interfaces';\n\nexport interface Props extends ComponentPropsWithRef<'div'>, FormGroupProps {\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 FormElement {\n errorMessage?: string;\n helperText?: string;\n helperProps?: HelperProps;\n label?: string;\n name: string;\n required?: boolean;\n disabled?: boolean;\n}\n\nexport const Wrapper = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ref\n ) => {\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} ref={ref} 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);\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 (\n (value?.length && value.length > 0) ||\n placeholder ||\n type === 'datetime-local' ||\n type === 'time'\n ) {\n setFloatingLabelActive(true);\n }\n }, []);\n\n useEffect(() => {\n if ((value?.length && value.length > 0) || 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, { ComponentPropsWithRef, useEffect, useRef, useState } 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 PartialInputProps extends Partial<InputProps> {}\n\nexport interface Props extends ComponentPropsWithRef<'div'>, WrapperProps {\n label: string;\n type: Type;\n name: string;\n inputProps?: PartialInputProps;\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\nconst useLabelOffset = (\n wrapper: React.RefObject<HTMLDivElement>,\n input: React.RefObject<HTMLInputElement>,\n floatingLabelActive: boolean,\n prefix?: string\n) => {\n const [labelOffset, setLabelOffset] = useState({});\n\n const resetLabelOffset = () => setLabelOffset({ left: undefined });\n\n useEffect(() => {\n if (wrapper.current && input.current && prefix) {\n if (floatingLabelActive) {\n resetLabelOffset();\n } else {\n const prefixDifference =\n input.current.getBoundingClientRect().left -\n wrapper.current.getBoundingClientRect().left +\n 4;\n\n setLabelOffset({ left: `${prefixDifference}px` });\n }\n }\n }, [wrapper.current, input.current, prefix, floatingLabelActive]);\n\n return { labelOffset };\n};\n\nexport const InputWrapper = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n type,\n name,\n inputProps,\n helperText,\n helperProps,\n value,\n className,\n error,\n onChange,\n onBlur,\n onFocus,\n ...rest\n }: Props,\n ref\n ) => {\n const {\n errorId,\n floatingLabelActive,\n setFloatingLabelActive,\n hasFocus,\n setHasFocus,\n helperId,\n labelId,\n } = useWrapper(value, inputProps?.placeholder, type);\n const { prefix, suffix } = inputProps || {};\n const wrapper = useRef<HTMLDivElement>(null);\n const input = useRef<HTMLInputElement>(null);\n const hasValueOrActiveFloatingLabel = !!value || floatingLabelActive;\n const labelClasses = [classes['input-label']];\n const { labelOffset } = useLabelOffset(\n (ref as React.RefObject<HTMLDivElement>) || wrapper,\n (inputProps && (inputProps.ref as React.RefObject<HTMLInputElement>)) || input,\n floatingLabelActive,\n prefix\n );\n\n hasFocus && labelClasses.push(classes['focus']);\n\n return (\n <Wrapper\n {...rest}\n ref={ref || wrapper}\n name={name}\n className={`${classes['input-wrapper']} ${className ?? ''}`}\n labelProps={{\n id: labelId,\n className: labelClasses.join(' '),\n style: { ...labelOffset },\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 prefix={hasValueOrActiveFloatingLabel ? prefix : ''}\n suffix={hasValueOrActiveFloatingLabel ? suffix : ''}\n wrapperProps={{\n className: `${floatingLabelActive ? classes['floating-label-active'] : ''} ${\n inputProps?.wrapperProps?.className ?? ''\n }`,\n }}\n ref={(inputProps && inputProps.ref) || input}\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 e.target.placeholder ||\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 inputProps?.className ?? ''\n }`}\n name={name}\n error={error}\n id={name}\n value={value}\n type={type}\n />\n </Wrapper>\n );\n }\n);\n","import React, { ComponentPropsWithRef, 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\ninterface PartialSelectProps extends Partial<SelectProps> {}\n\nexport interface Props\n extends Omit<ComponentPropsWithRef<'div'>, 'onChange'>,\n Omit<WrapperProps, 'onChange' | 'error'> {\n children: ReactChild | ReactChild[];\n placeholder?: string;\n value: string;\n error?: boolean;\n selectProps?: PartialSelectProps;\n onChange?: (event: React.ChangeEvent<HTMLSelectElement>) => void;\n onClear?: () => void;\n}\n\nexport const SelectWrapper = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n children,\n error,\n value,\n placeholder,\n selectProps,\n helperProps,\n onChange,\n onClear,\n ...rest\n }: Props,\n ref\n ) => {\n const { errorId, floatingLabelActive, helperId, labelId } = useWrapper(value, placeholder);\n\n return (\n <Wrapper\n {...rest}\n ref={ref}\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);\n","import React, { ComponentPropsWithRef, 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<\n ComponentPropsWithRef<'div'>,\n 'onFocus' | 'onChange' | 'onBlur' | 'onMouseEnter' | 'onMouseLeave'\n >,\n 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 = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ref\n ) => {\n const {\n errorId,\n floatingLabelActive,\n setFloatingLabelActive,\n hasFocus,\n setHasFocus,\n helperId,\n labelId,\n } = useWrapper(value, placeholder);\n const [hover, setHover] = useState(false);\n\n const optionalClasses: string[] = [];\n\n hasFocus && optionalClasses.push(classes['focus']);\n hover && optionalClasses.push(classes['hover']);\n disabled && optionalClasses.push(classes['disabled']);\n error && optionalClasses.push(classes['error']);\n\n return (\n <Wrapper\n {...rest}\n ref={ref}\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 name={name}\n id={name}\n value={value}\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 || e.target.placeholder || 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 wrapperProps={{\n className: `${classes['textarea-wrapper']}} ${optionalClasses.join(' ')}`,\n }}\n errorProps={{ className: classes['error-icon'] }}\n />\n </Wrapper>\n );\n }\n);\n","import React, { ComponentPropsWithRef, ReactNode, ReactElement } from 'react';\nimport readyclasses from '../../readyclasses.module.scss';\nimport classes from './Fieldset.module.scss';\nimport { Typography, Variant } from '../../Typography/Typography';\nimport { Input } from '../Input/Input';\nimport { Select } from '../Select/Select';\nimport { Radio } from '../Radio/Radio';\nimport { Checkbox } from '../Checkbox/Checkbox';\nimport { Textarea } from '../Textarea/Textarea';\nimport { Toggle } from '../Toggle/Toggle';\nimport { Label } from '../Label/Label';\nimport { FormControl } from '../FormControl/FormControl';\nimport { FormSelectorWrapper } from '../FormSelectorWrapper/FormSelectorWrapper';\nimport { FormHelperText } from '../FormHelperText/FormHelperText';\nimport { InputWrapper } from '../Wrapper/InputWrapper/InputWrapper';\nimport { SelectWrapper } from '../Wrapper/SelectWrapper/SelectWrapper';\nimport { TextareaWrapper } from '../Wrapper/TextareaWrapper/TextareaWrapper';\n\nexport interface Props extends ComponentPropsWithRef<'fieldset'> {\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 disablePropagation?: boolean;\n}\n\nexport const Fieldset = React.forwardRef<HTMLFieldSetElement, Props>(\n (\n {\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 disablePropagation = false,\n ...rest\n }: Props,\n ref\n ) => {\n const renderChildren = () => {\n if (!children) return;\n\n /* All right, so the issue is that whenever we try to add disabled and error to a component that doesn't accept it, \n React will throw an error. However, it might occur that we want a component inside of Fieldset because of aesthetic purposes \n (fieldset applies a sort of container with white background and if we want to display it inside of this container... then yea).\n So instead we supply an array of components that we want to add the disabled and error prop to and check if child.type equals one of these. */\n const allowedComponents: ReactNode[] = [\n Input,\n Select,\n Radio,\n Checkbox,\n Textarea,\n Toggle,\n Label,\n FormControl,\n FormSelectorWrapper,\n FormHelperText,\n InputWrapper,\n SelectWrapper,\n TextareaWrapper,\n ];\n\n return React.Children.map(children, (child: ReactElement) => {\n if (allowedComponents.includes(child.type) && !disablePropagation) {\n return React.cloneElement(child, {\n disabled: child.props.disabled ?? disabled,\n error: child.props.error ?? error,\n });\n }\n\n return child;\n });\n };\n\n return (\n <fieldset\n {...rest}\n ref={ref}\n disabled={disabled}\n style={{ backgroundColor: background, ...rest.style }}\n className={`${classes.fieldset} ${noPadding ? classes['no-padding'] : ''} ${\n className ?? ''\n }`}\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);\n","import React, { ComponentPropsWithRef, 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 ComponentPropsWithRef<'div'>, WrapperProps {\n children: ReactElement[] | ReactElement;\n fieldsetProps: FieldsetProps;\n onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;\n}\n\nexport const CheckboxWrapper = React.forwardRef<HTMLDivElement, Props>(\n ({ children, error = false, helperText, helperProps, fieldsetProps, ...rest }: Props, ref) => {\n const { errorId, helperId } = useWrapper();\n\n useEffect(() => {\n if (fieldsetProps.legend === undefined) {\n console.error(\n `You should give your Fieldset component a legend prop so a legend element is rendered. This error was thrown in CheckboxWrapper. You can add this legend prop through the fieldsetProps prop by passing an object (fieldsetProps={{ legend: \"legend 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} error={error} required={rest.required}>\n <Wrapper\n {...rest}\n ref={ref}\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.Error}\n errorId={errorId}\n >\n {renderChildren()}\n </Wrapper>\n </Fieldset>\n );\n }\n);\n","import React, { ComponentPropsWithRef, 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 ComponentPropsWithRef<'div'>, WrapperProps {\n children: ReactElement | ReactElement[];\n fieldsetProps: FieldsetProps;\n value: string;\n onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;\n}\n\nexport const RadioWrapper = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n children,\n error,\n name,\n helperText,\n helperProps,\n fieldsetProps,\n value,\n onChange,\n disabled,\n ...rest\n }: Props,\n ref\n ) => {\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 legend prop so a legend element is rendered. This error was thrown in RadioWrapper. You can add this legend prop through the fieldsetProps prop by passing an object (fieldsetProps={{ legend: \"legend 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} error={error} disabled={disabled}>\n <Wrapper\n {...rest}\n ref={ref}\n disabled={disabled}\n name={name}\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.Error}\n floatingLabel={false}\n >\n {renderChildren()}\n </Wrapper>\n </Fieldset>\n );\n }\n);\n","import React, { ComponentPropsWithRef, 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<ComponentPropsWithRef<'div'>, 'onClick'> {\n steps: Step[];\n currentStepNo: number;\n onClick?: (stepNo: number) => void;\n futureStepsClickable?: boolean;\n stepScreenReaderLabel: string;\n}\n\nexport const BaseWizardSteps = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n steps,\n currentStepNo,\n onClick,\n futureStepsClickable = false,\n stepScreenReaderLabel,\n ...rest\n }: Props,\n ref\n ) => {\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 {...rest} ref={ref} className={classes['wizard']}>\n {generatedSteps}\n </div>\n );\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, { ComponentPropsWithRef, useContext } from 'react';\nimport { WizardStateContext } from '../WizardStateProvider';\nimport { BaseWizardSteps } from '../BaseWizardSteps/BaseWizardSteps';\nimport { changeCurrentStepNo } from '../wizardStateReducer';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n onStepClick: (currentStepNo: number, selectedStepNo: number) => boolean;\n}\n\nexport const WizardSteps = React.forwardRef<HTMLDivElement, Props>(\n ({ onStepClick, ...rest }: Props, ref) => {\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 {...rest}\n ref={ref}\n onClick={onClick}\n steps={steps}\n currentStepNo={currentStepNo}\n stepScreenReaderLabel={stepScreenReaderLabel}\n futureStepsClickable={mode === 'edit'}\n />\n );\n }\n);\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, { 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 modalRef?: React.RefObject<HTMLDivElement>;\n dialogRef?: React.RefObject<HTMLDivElement>;\n}\n\nexport const DiscardChangesModal = ({\n id,\n children,\n headerProps,\n discardChangedDialogProps,\n modalRef,\n dialogRef,\n onClose,\n hasUnsavedChanges,\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} ref={modalRef} onClose={onCloseWrapper} {...rest}>\n <ModalHeader {...headerProps} id={`${id}-label`} onClose={onCloseWrapper} />\n {children}\n </Modal>\n <DiscardChangesDialog\n {...discardChangedDialogProps}\n ref={dialogRef}\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, { 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, { 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, { useEffect, useState } from 'react';\nimport { generateID } from '../util/helper';\n\ninterface Arguments {\n componentToRepeat: React.ReactElement;\n}\n\nexport const useRepeater = <T>({ componentToRepeat }: Arguments) => {\n const [repeatedComponents, setRepeatedComponents] = useState<JSX.Element[]>([]);\n\n useEffect(() => {\n repeat();\n }, []);\n\n const repeat = () => {\n const clonedComponent = React.cloneElement(componentToRepeat, { key: generateID(20) });\n\n setRepeatedComponents((prevState) => [...prevState, clonedComponent]);\n };\n\n const remove = (componentToRemove: React.ReactElement<T>) => {\n const newRepeatedComponents = repeatedComponents.filter(\n (component) => component !== componentToRemove\n );\n\n setRepeatedComponents(newRepeatedComponents);\n };\n\n return {\n repeatedComponents,\n repeat,\n remove,\n };\n};\n","import { useContext } from 'react';\nimport { SnackbarContext } from './SnackbarProvider/SnackbarStateProvider';\n\nexport const useSnackbar = () => useContext(SnackbarContext);\n"],"names":["BaseStyling","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","React","forwardRef","ref","children","variant","tag","style","spacing","_ref$className","_ref","className","rest","_objectWithoutPropertiesLoose","_excluded","includes","Error","styleWithSpacing","spacingProps","entries","reduce","prev","_extends2","matches","String","matchAll","cssSpacingValue","Array","from","map","_ref2","Number","join","_extends","useSpacing","classes","BaseButton","_ref$type","type","Button","_ref$variant","_ref$color","color","_ref$startIcon","startIcon","_ref$endIcon","endIcon","additionalClasses","Link","_ref$disabled","disabled","to","component","classNames","download","rel","undefined","href","target","IconButton","_ref$iconSize","iconSize","title","console","error","iconButtonClasses","Fragment","readyclasses","Icons","Icon","icon","size","_ref$tag","fontSize","dateTypes","Input","_ref$error","name","wrapperProps","labeledBy","prefix","suffix","onFocus","onBlur","useState","focus","_useState","setFocus","useEffect","inputClassNames","iconClassNames","wrapperClasses","event","useBodyClick","checkFunction","callbackFunction","dependingStateVariable","bodyClickListener","window","addEventListener","removeEventListener","generateID","stringToWeaveIn","hashCharacters","id","test","Math","floor","random","slice","filterProps","props","regexPattern","returnFiltered","acc","key","filter","prevObj","currKeyValPair","Select","placeholder","describedBy","_ref$searchPlaceholde","searchPlaceholder","value","onChange","onClear","expanded","setExpanded","opacity","_useState2","setOpacity","_useState3","setFilter","display","_useState4","setDisplay","listPosition","_useState5","setListPosition","optionsListMaxHeight","_useState6","setOptionsListMaxHeight","containerReference","useRef","optionListReference","nativeSelect","onOptionChangeHandler","current","currentTarget","dataset","dispatchEvent","Event","bubbles","val","Children","forEach","child","position","top","bottom","getBoundingClientRect","innerHeight","listHeight","height","transformOrigin","availableSpace","calculateOptionListMaxHeight","rePositionList","closest","tabIndex","onClick","Warning","TimesThin","preventDefault","stopPropagation","TriangleDown","maxHeight","isArray","autoFocus","role","cloneElement","onOptionSelect","selected","Option","_ref$selected","showOption","setShowOption","onSelectHandler","toLowerCase","match","onKeyPress","DefaultTranslations","Label","_ref$hidden","hidden","Pagination","amountOfPages","totalElements","_ref$pageSize","pageSize","_ref$translate","translate","currentPage","onPageChange","onPageSizeChange","toString","internalCurrentPage","setInternalCurrentPage","calculateAmountOfPages","ceil","onEnterListener","code","onPageChangeHandler","pageToGoTo","totalItems","itemsPerPage","pageSizeNumber","NavigationFirst","ChevronLeft","split","string","htmlFor","currentPageLabel","max","onKeyUp","replace","ChevronRight","NavigationLast","labelId","descriptionId","BaseModal","open","onClose","_ref$containerClassNa","containerClassName","labelledby","describedby","_ref$disableEscapeKey","disableEscapeKeyDown","_ref$disableBackdrop","disableBackdrop","zIndex","_ref$domRoot","domRoot","body","querySelectorAll","removeProperty","useSetBodyScroll","createPortal","onKeyDown","BaseModalContent","_ref$disableAutoFocus","disableAutoFocus","contentRef","createRef","_ref$current","_contentRef$current","BaseModalActions","DialogActions","align","DialogTitle","Dialog","secondaryLabel","restOfSecondaryAction","alignActions","primaryAction","secondaryAction","dialogId","primaryLabel","label","restOfPrimaryAction","_excluded2","PrimaryButton","TertiaryButton","_excluded3","width","maxLength","BaseModalHeader","Times","DiscardChangesDialog","onKeepEditing","onDiscardChanges","discardChangesButtonLabel","keepEditingButtonLabel","contentLabel","titleLabel","margin","defaultConfigObject","relativeElement","elementToBePositioned","horizontal","vertical","placement","offset","right","left","usePosition","providedConfigObject","configObject","setPosition","_calculatePlacement","relEl","elDimensions","axis","_configObject$transfo","_configObject$transfo2","placementValue","requestedReturnValue","placementOriginDefinition","_determineCenteredPlacementOrigin","_calculateInitialPlacementValue","valueWithOffset","_configObject$offset","_configObject$offset2","_configObject$offset7","_configObject$offset8","_configObject$offset3","_configObject$offset4","_configObject$offset5","_configObject$offset6","_configObject$offset9","_configObject$offset10","_configObject$offset11","_configObject$offset12","returnValue","_applyOffsetToPlacementValue","valueCorrectionForViewportOverflow","innerWidth","_fixPossibleViewportOverflow","_calculatePlacementValue","direction","oppositeDirection","prevState","calculatePosition","_configObject$relativ","relativeElRect","elementToBePositionedDimensions","offsetHeight","offsetWidth","clonedRelEl","center","centerv","centerh","x","y","Popover","show","anchorEl","elToBePositioned","_usePosition","TextEllipsis","popoverClassName","showPopover","setShowPopover","textContainer","ellipsisVisible","scrollWidth","onMouseEnter","onMouseLeave","defaultPosition","Tooltip","_ref$placement","_ref$offset","_ref$transformOrigin","identifier","visible","setVisible","escapePressHandler","useLayoutEffect","isValidElement","InfoCircle","Tile","imageProps","enabled","loading","tileAction","tileDescriptionID","justifyContent","Checkmark","Forbidden","readyClasses","src","alt","Image","Tiles","_ref$loading","ContextMenu","trigger","_ref$show","onShow","showContextMenu","setShowContextMenu","Breadcrumbs","ariaLabel","items","index","SnackbarContext","createContext","enqueueSnackbar","enqueueSuccessSnackbar","enqueueErrorSnackbar","SnackbarContextProvider","Provider","initialState","SnackbarContainer","SnackbarItem","duration","content","_ref$actions","actions","closeButtonTitle","timerHandler","useAnimation","callback","animatedObjectRef","animationStarted","setAnimationStarted","onAnimationEnd","_animatedObjectRef$cu","_animatedObjectRef$cu2","startAnimation","setTimeout","clearTimeout","actionButtons","actionProp","CheckmarkCircleBreakout","useFormSelector","setDescribedBy","errorId","errorMessage","parentErrorId","helperText","parentHelperId","FormHelperText","FormSelectorWrapper","_helperProps$classNam","nestedChildren","containerProps","helperProps","helperRef","Radio","_ref$checked","checked","formSelectorWrapperProps","_useFormSelector","onChangeHandler","nativeEvent","clonedEvent","constructor","defineProperty","writable","Circle","isToggle","_children$props","Checkbox","indeterminate","iconClasses","toArray","MinusSquare","CheckmarkSquare","Square","determineLabel","Textarea","_wrapperProps$classNa","_errorProps$className","_ref$rows","rows","errorProps","Toggle","FormControl","grid","_ref$align","childElement","column","FormGroup","errorMessageIcon","_ref$errorMessageIcon","errorMessageIconPosition","helperId","helperIndent","marginLeft","message","Wrapper","_ref$floatingLabel","floatingLabel","floatingLabelActive","required","labelProps","innerClassName","labelClasses","wrapper","useWrapper","setFloatingLabelActive","hasFocus","setHasFocus","InputWrapper","_inputProps$wrapperPr","_inputProps$wrapperPr2","_inputProps$className","inputProps","input","hasValueOrActiveFloatingLabel","labelOffset","setLabelOffset","prefixDifference","useLabelOffset","_inputProps$placehold","SelectWrapper","_selectProps$classNam","selectProps","_useWrapper","TextareaWrapper","textareaProps","hover","setHover","optionalClasses","_textareaProps$placeh","Fieldset","legend","_ref$legendStyle","legendStyle","_ref$hideLegend","hideLegend","_ref$background","background","noBackground","_ref$noPadding","noPadding","_ref$required","_ref$disablePropagati","disablePropagation","backgroundColor","allowedComponents","_child$props$disabled","_child$props$error","renderChildren","CheckboxWrapper","fieldsetProps","RadioWrapper","BaseWizardSteps","steps","currentStepNo","_ref$futureStepsClick","futureStepsClickable","stepScreenReaderLabel","generatedSteps","step","stepNo","stepState","disabledStyleClassName","clickableClassName","stepNumberString","getStepContent","changeCurrentStepNo","payload","reducer","state","action","WizardStateContext","dispatch","WizardStateProvider","_useReducer","useReducer","WizardSteps","onStepClick","useContext","_useContext$state","_useContext","selectedStepNo","mode","WizardContent","onStepChange","setWizardState","useStepChanging","_ref$properties","properties","defaultProperties","colorFocus","colorPrimary","colorSecondary","colorTertiary","defaultLineHeight","buttonBorderRadius","buttonBorderWidth","buttonFontSize","buttonBorderStyle","buttonFillTextColor","buttonFillBackgroundColor","buttonOutlineHoverTextColor","inputBorderColor","inputBorderRadius","inputBorderWidth","inputBorderStyle","inputBackgroundColor","modalShadowColor","modalBackgroundColor","modalHeaderBackgroundColor","snackbarTextColor","snackbarInfoBackgroundColor","snackbarSuccessBackgroundColor","snackbarErrorBackgroundColor","snackbarBorderRadius","tabsBackgroundColor","tabBorderWidth","tabBorderStyle","tablistBorderWidth","tablistBorderStyle","tablistBorderColor","tabTextColor","default","success","greyedOut","warning","fontFamily","fontFamilyCode","fontSizeH1","fontSizeH2","fontSizeH3","fontSizeH4","fontSizeSub","fontSizeCode","isLoading","setIsLoading","setCSSProperties","CSSPropertiesObject","_i","_Object$entries","_Object$entries$_i","formattedPropertyName","documentElement","setProperty","mergedState","headerProps","discardChangedDialogProps","modalRef","dialogRef","hasUnsavedChanges","openDiscardChangesDialog","setOpenDiscardChangesDialog","onCloseWrapper","Modal","ModalHeader","_temp","_ref$autoHideDuration","autoHideDuration","long","short","_ref$stackSize","stackSize","setSnackbars","options","item","_options$variant","_options$duration","getDuration","onItemClosed","snackbarList","snackbarPortal","initialStepNo","_props$initialStepNo","onCancel","onNext","onPrevious","onSaveAndClose","cancelButtonLabel","previousButtonLabel","nextButtonLabel","saveAndCloseButtonLabel","nextStepNo","useMemo","findIndex","calculateNextStepNo","useNextStepNo","hasNextStep","previousStepNo","reversedCurrentStepNo","reversedPrevStepNo","reverse","calculatePrevStepNo","usePreviousStepNo","hasPreviousStep","isLastStepOrEditMode","changeStepNo","componentToRepeat","repeatedComponents","setRepeatedComponents","repeat","clonedComponent","remove","componentToRemove","newRepeatedComponents"],"mappings":"6iBAyDaA,ICzDTC,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,S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2I,CAAkB9G,EAAM5B,EAAeD,GACxD4I,GAAsC,IAApBN,EAClBO,GAAwBR,GAAwB,SAATxG,EAEvCiH,EAAe,SAAChW,GACF,YAAdA,EACFuV,GAAelH,EAASN,GAAoBmH,IAE5CY,GAAmBzH,EAASN,GAAoByH,KAiBpD,OACElqB,EAAAA,sBAACiE,EAADA,SAAS,KACPjE,EAAC,QAAAV,cAAAgD,EAAO,CAAAlC,QAAQ,OAAOsK,QAAS0e,GAC7BI,GAEFgB,GACCxqB,EAAAA,QAACV,cAAAgD,GAAOlC,QAAQ,UAAUsK,QAfN,WACxB4e,GAAcA,IACdoB,EAAa,cAcNjB,GAGJQ,GACCjqB,EAAAA,QAAAV,cAACgD,EAAM,CAAClC,QAAkB,SAATqjB,EAAkB,UAAY,OAAQ/Y,QAxBvC,WACpB2e,EAAOxH,IAAkB6I,EAAa,aAwB/BhB,GAGJe,GACCzqB,EAAAA,QAACV,cAAAgD,GAAOoI,QApBgB,WAC5B6e,EAAe1H,KAmB8B8H,qECxFtB,SAAwClpB,GAAA,IAAlCkqB,IAAAA,kBACqBxlB,EAAAA,EAAQA,SAAgB,IAArEylB,EAAPvlB,EAAA,GAA2BwlB,EAA3BxlB,EAAA,GAEAE,EAAAA,WAAU,WACRulB,MACC,IAEH,IAAMA,EAAS,WACb,IAAMC,EAAkB/qB,EAAAA,QAAMoL,aAAauf,EAAmB,CAAEzjB,IAAKd,EAAW,MAEhFykB,GAAsB,SAACjW,GAAD,MAAmBA,GAAAA,OAAAA,GAAWmW,QAWtD,MAAO,CACLH,mBAAAA,EACAE,OAAAA,EACAE,OAXa,SAACC,GACd,IAAMC,EAAwBN,EAAmBzjB,QAC/C,SAAChE,GAAD,OAAeA,IAAc8nB,KAG/BJ,EAAsBK,0BCtBC,WAAA,OAAM7H,EAAAA,WAAWzK"}
1
+ {"version":3,"file":"react-lib-components.cjs.production.min.js","sources":["../src/_BaseStyling_/BaseStyling.tsx","../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/Form/Input/Input.tsx","../src/hooks/useBodyClick.ts","../src/util/helper.tsx","../src/Form/Select/Select.tsx","../src/Form/Select/Option.tsx","../src/Pagination/Pagination.tsx","../src/Form/Label/Label.tsx","../src/Tabs/TabButton.tsx","../src/Tabs/TabPanel.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/Notifications/Dialog/Dialog.tsx","../src/Notifications/BaseModal/BaseModalHeader/BaseModalHeader.tsx","../src/Notifications/DiscardChangesModal/DiscardChangesDialog/DiscardChangesDialog.tsx","../src/hooks/usePosition.ts","../src/Popover/Popover.tsx","../src/TextEllipsis/TextEllipsis.tsx","../src/Tooltip/Tooltip.tsx","../src/Tiles/Tile.tsx","../src/Tiles/Tiles.tsx","../src/ContextMenu/ContextMenu.tsx","../src/Breadcrumbs/Breadcrumbs.tsx","../src/Notifications/Snackbar/SnackbarProvider/SnackbarStateProvider.tsx","../src/Notifications/Snackbar/SnackbarContainer/SnackbarContainer.tsx","../src/hooks/useAnimation.ts","../src/Notifications/Snackbar/SnackbarItem/SnackbarItem.tsx","../src/hooks/useFormSelector.ts","../src/Form/FormHelperText/FormHelperText.tsx","../src/Form/FormSelectorWrapper/FormSelectorWrapper.tsx","../src/Form/Radio/Radio.tsx","../src/Form/Checkbox/Checkbox.tsx","../src/Form/Textarea/Textarea.tsx","../src/Form/Toggle/Toggle.tsx","../src/Form/FormControl/FormControl.tsx","../src/Form/FormGroup/FormGroup.tsx","../src/Form/Wrapper/Wrapper/Wrapper.tsx","../src/hooks/useWrapper.ts","../src/Form/Wrapper/InputWrapper/InputWrapper.tsx","../src/Form/Wrapper/SelectWrapper/SelectWrapper.tsx","../src/Form/Wrapper/TextareaWrapper/TextareaWrapper.tsx","../src/Form/Fieldset/Fieldset.tsx","../src/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.tsx","../src/Form/Wrapper/RadioWrapper/RadioWrapper.tsx","../src/Wizard/BaseWizardSteps/BaseWizardSteps.tsx","../src/Wizard/wizardStateReducer.ts","../src/Wizard/WizardStateProvider.tsx","../src/Wizard/WizardSteps/WizardSteps.tsx","../src/Wizard/Wizard.tsx","../src/ContextMenu/ContextMenuItem.tsx","../src/Notifications/DiscardChangesModal/DiscardChangesModal.tsx","../src/Form/Form.tsx","../src/Notifications/Snackbar/SnackbarProvider/SnackbarProvider.tsx","../src/Tabs/Tab.tsx","../src/Tabs/Tabs.tsx","../src/Wizard/WizardActions/WizardActions.tsx","../src/hooks/useRepeater.ts","../src/Notifications/Snackbar/useSnackbar.ts"],"sourcesContent":["import React, { Fragment, HTMLAttributes, ReactChild, useEffect, useState } from 'react';\n\ninterface CSSProperties {\n colorFocus?: string;\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 inputBackgroundColor?: 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 tabsBackgroundColor?: string;\n tabBorderWidth?: string;\n tabBorderStyle?: string;\n tablistBorderWidth?: string;\n tablistBorderStyle?: string;\n tablistBorderColor?: string;\n tabTextColor?: 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 colorFocus: '#0085f2',\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 inputBackgroundColor: '#FFF',\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 tabsBackgroundColor: '#FFF',\n tabBorderWidth: '2px',\n tabBorderStyle: 'solid',\n tablistBorderWidth: '1px',\n tablistBorderStyle: 'solid',\n tablistBorderColor: '#C3C3C7',\n tabTextColor: '#0f0f1e',\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.replace(/([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","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\nexport type 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, { ComponentPropsWithRef, 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\ntype Tags =\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\n/** I couldn't find anything on the internet that indicated that ComponentPropsWithRef can take multiple tags. Since the TagName can be many different things I have to use any here. Using a mix of tags (like the Tags type) will throw an error. */\nexport interface Props extends ComponentPropsWithRef<any> {\n children: ReactNode;\n variant: Variant;\n tag?: Tags;\n spacing?: Spacing;\n}\n\nexport const Typography = React.forwardRef<any, Props>(\n ({ children, variant, tag, style, spacing, className = '', ...rest }: Props, ref) => {\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 ref={ref}\n style={styleWithSpacing}\n className={`${classes['typography_style_' + variant]} ${className}`}\n >\n {children}\n </TagName>\n );\n }\n);\n","import React, { ComponentPropsWithRef } from 'react';\nimport classes from './BaseButton.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'button'> {\n type?: 'submit' | 'button' | 'reset';\n disabled?: boolean;\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 from 'react';\nimport { BaseButton, Props as BaseButtonProps } from './BaseButton';\nimport classes from './Button.module.scss';\n\nexport interface Props extends BaseButtonProps {\n startIcon?: React.ReactNode | false;\n endIcon?: React.ReactNode | false;\n children?: React.ReactNode;\n variant?: 'text' | 'fill' | 'outline';\n}\n\nexport const Button = React.forwardRef<HTMLButtonElement, Props>(\n (\n {\n children,\n variant = 'fill',\n color = 'primary',\n startIcon = false,\n endIcon = false,\n className,\n ...rest\n },\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 if (className) {\n additionalClasses.push(className);\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, {\n ComponentPropsWithRef,\n ForwardRefExoticComponent,\n ReactNode,\n RefAttributes,\n} from 'react';\nimport classes from './Link.module.scss';\nimport { LinkProps } from './types';\n\ntype AnchorType = 'external' | 'internal' | 'download';\n\nexport interface Props extends ComponentPropsWithRef<'a'> {\n children?: ReactNode;\n color?: 'primary' | 'secondary' | 'tertiary';\n type?: AnchorType;\n to: string;\n disabled?: boolean;\n component?: ForwardRefExoticComponent<LinkProps & RefAttributes<HTMLAnchorElement>>;\n}\n\nexport const Link = React.forwardRef<HTMLAnchorElement, Props>(\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\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 } 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 BaseButtonProps {\n children?: React.ReactNode;\n iconSize?: 's' | 'm' | 'l';\n className?: string;\n title?: string;\n}\n\nexport const IconButton = React.forwardRef<HTMLButtonElement, Props>(\n ({ children, color = 'primary', iconSize = 'm', title, className, ...rest }, ref) => {\n if (!title) {\n console.error(\"Please make sure to specify a 'title' prop to your IconButton component! \");\n }\n\n const iconButtonClasses = [\n classes['icon-button'],\n classes[color],\n classes['button-' + iconSize],\n ];\n\n if (className) {\n iconButtonClasses.push(className);\n }\n\n return (\n <BaseButton {...rest} ref={ref} className={iconButtonClasses.join(' ')}>\n <Fragment>\n {children}\n <span className={readyclasses['sr-only']}>{title}</span>\n </Fragment>\n </BaseButton>\n );\n }\n);\n","import React, { ComponentPropsWithRef } from 'react';\nimport classes from './Icon.module.scss';\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 Error = 'error-circle',\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 ComponentPropsWithRef<'div'> {\n icon: Icons;\n color?: string;\n size?: string;\n tag?: Tag;\n}\n\nexport const Icon = React.forwardRef<HTMLDivElement, Props>(\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}\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","import React, { ComponentPropsWithRef, Ref, useEffect, useState } from 'react';\nimport classes from './Input.module.scss';\nimport readyclasses from '../../readyclasses.module.scss';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { FormElement } from '../form.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 ComponentPropsWithRef<'input'>, FormElement {\n wrapperProps?: ComponentPropsWithRef<'div'>;\n labeledBy?: string;\n type: Type;\n suffix?: string;\n prefix?: string;\n}\n\nexport const Input = React.forwardRef(\n (\n {\n error = false,\n className,\n name,\n style,\n wrapperProps,\n type,\n labeledBy,\n prefix,\n suffix,\n disabled,\n onFocus,\n onBlur,\n ...rest\n }: Props,\n ref: Ref<HTMLInputElement>\n ) => {\n const [focus, setFocus] = useState(false);\n\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\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 const wrapperClasses = [classes['input-wrapper']];\n\n wrapperProps?.className && wrapperClasses.push(wrapperProps.className);\n type === 'hidden' && wrapperClasses.push(readyclasses['hidden']);\n prefix && wrapperClasses.push(classes['prefix']);\n suffix && wrapperClasses.push(classes['suffix']);\n disabled && wrapperClasses.push(classes['disabled']);\n error && wrapperClasses.push(classes['error']);\n focus && wrapperClasses.push(classes['focus']);\n\n return (\n <div\n {...wrapperProps}\n style={{ ...style }}\n className={`${classes['input-wrapper']} ${wrapperClasses.join(' ')}`}\n >\n {prefix && (\n <div data-prefix className={classes['prefix']}>\n <span>{prefix}</span>\n </div>\n )}\n <input\n {...rest}\n ref={ref}\n onFocus={(event) => {\n setFocus(true);\n onFocus && onFocus(event);\n }}\n onBlur={(event) => {\n setFocus(false);\n onBlur && onBlur(event);\n }}\n aria-labelledby={labeledBy}\n type={type}\n name={name}\n disabled={disabled}\n className={inputClassNames.join(' ')}\n />\n {suffix && (\n <div data-suffix className={classes['suffix']}>\n <span>{suffix}</span>\n </div>\n )}\n {error && <Icon className={iconClassNames.join(' ')} icon={Icons.Error} />}\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","type KeyValuePair = { [key: string]: unknown };\n\nexport 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\nexport const filterProps = (props: any, regexPattern: RegExp, returnFiltered: boolean = true) => {\n if (returnFiltered) {\n return Object.keys(props).reduce((acc: KeyValuePair, key) => {\n if (regexPattern.test(key)) {\n acc[key] = props[key];\n }\n\n return acc;\n }, {});\n } else {\n return Object.entries(props)\n .filter(([key]) => !regexPattern.test(key))\n .reduce(\n (prevObj, currKeyValPair) => ({ ...prevObj, [currKeyValPair[0]]: currKeyValPair[1] }),\n {}\n );\n }\n};\n","import classes from './Select.module.scss';\n\nimport React, {\n ComponentPropsWithRef,\n Fragment,\n ReactElement,\n RefObject,\n useEffect,\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 readyclasses from '../../readyclasses.module.scss';\nimport { filterProps } from '../../util/helper';\n\nexport interface Props extends ComponentPropsWithRef<'select'>, FormElement {\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\ntype Position = {\n top: 0 | 'initial';\n bottom: 0 | 'initial';\n};\n\nexport const Select = React.forwardRef<HTMLSelectElement, Props>(\n (\n {\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 ref\n ) => {\n const [expanded, setExpanded] = useState(false);\n const [opacity, setOpacity] = useState(0); // We set opacity because other wise if we calculate the max height you see the list full height for a split second and then it shortens.\n const [filter, setFilter] = useState('');\n const [display, setDisplay] = useState('');\n const [listPosition, setListPosition] = useState<Partial<Position>>({});\n const [optionsListMaxHeight, setOptionsListMaxHeight] = useState('none');\n const containerReference = useRef<HTMLDivElement>(null);\n const optionListReference = useRef<HTMLDivElement>(null);\n\n const nativeSelect = useRef<HTMLSelectElement>(null);\n\n const syncDisplayValue = (val: string) => {\n React.Children.forEach(children, (child) => {\n if (child.props.value === val) {\n setDisplay(child.props.children);\n }\n });\n };\n\n const rePositionList = () => {\n if (!expanded || !optionListReference.current || !containerReference.current) {\n return;\n }\n\n // Check whether there is more space above or below the select\n // Check space between the bottom of select and top of viewport\n const spaceOnTopOfSelect = containerReference.current.getBoundingClientRect().bottom;\n\n // Check space between the top of the select and bottom of viewport\n const spaceOnBottomOfSelect =\n window.innerHeight - containerReference.current.getBoundingClientRect().top;\n\n // Set position as if there's more space on the bottom\n let position: Position = { top: 0, bottom: 'initial' };\n\n // Set the position of the select\n if (spaceOnTopOfSelect > spaceOnBottomOfSelect) {\n position = { top: 'initial', bottom: 0 };\n }\n\n setListPosition(position);\n\n // Calculate the potential max height of the options list\n calculateOptionListMaxHeight(position);\n };\n\n const calculateOptionListMaxHeight = (position: Position) => {\n // Calculate max height if there's more space below the select\n const listHeight = optionListReference.current!.getBoundingClientRect().height;\n const transformOrigin = position.top !== 'initial' ? 'top' : 'bottom';\n\n const availableSpace =\n transformOrigin === 'top'\n ? window.innerHeight -\n containerReference.current!.getBoundingClientRect()[transformOrigin] -\n 16\n : containerReference.current!.getBoundingClientRect()[transformOrigin] - 16;\n\n if (availableSpace < listHeight) {\n setOptionsListMaxHeight(`${availableSpace}px`);\n setOpacity(100);\n return;\n }\n\n setOptionsListMaxHeight('none');\n setOpacity(100);\n };\n\n const onOptionChangeHandler = (event: React.MouseEvent<HTMLLIElement>) => {\n // We need to set value and the fire change event. If a custom ref has been given we pass that value, otherwise we use the ref we've created ourselves when the component was instantiated.\n if (nativeSelect.current) {\n nativeSelect.current.value = event.currentTarget.dataset.value!;\n nativeSelect.current.dispatchEvent(new Event('change', { bubbles: true }));\n } else if (ref) {\n (ref as RefObject<HTMLSelectElement>).current!.value = event.currentTarget.dataset.value!;\n (ref as RefObject<HTMLSelectElement>).current!.dispatchEvent(\n new Event('change', { bubbles: true })\n );\n }\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,\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\n if (value?.length !== 0 && onClear) {\n return (\n <Icon\n tag=\"div\"\n data-clear\n icon={Icons.TimesThin}\n onClick={(e: React.MouseEvent<HTMLDivElement, MouseEvent>) => {\n e.preventDefault();\n e.stopPropagation();\n onClear(e);\n }}\n />\n );\n }\n return null;\n };\n\n const nativeOnChangeHandler = (event: React.ChangeEvent<HTMLSelectElement>) => {\n onChange && onChange(event);\n };\n\n useEffect(() => {\n syncDisplayValue(value);\n }, [value]);\n\n useEffect(() => {\n rePositionList();\n }, [expanded]);\n\n useBodyClick(\n (event: MouseEvent) => !(event.target as Element).closest('.custom-select') && expanded,\n () => {\n setExpanded(!expanded);\n setListPosition({ top: 0, bottom: 'initial' });\n setOpacity(0);\n },\n expanded\n );\n\n const additionalClasses = [];\n expanded && additionalClasses.push(classes.expanded);\n error && additionalClasses.push(classes.error);\n disabled && additionalClasses.push(classes.disabled);\n className && additionalClasses.push(className);\n\n /** The native select is purely for external form libraries. We use it to emit an onChange with native select event object so they know exactly what's happening. */\n return (\n <Fragment>\n <select\n {...filterProps(rest, /^data-/, false)}\n tabIndex={-1}\n aria-hidden=\"true\"\n ref={ref || nativeSelect}\n name={name}\n onChange={nativeOnChangeHandler}\n className={readyclasses['sr-only']}\n >\n <option value=\"\"></option>\n {React.Children.map(children, (child) => (\n <option value={child.props.value}></option>\n ))}\n </select>\n <div\n {...filterProps(rest, /^data-/)}\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 && 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={{\n display: expanded ? 'block' : 'none',\n opacity: opacity,\n maxHeight: optionsListMaxHeight,\n ...listPosition,\n }}\n >\n {Array.isArray(children) && children.length > 10 && renderSearch()}\n <ul role=\"listbox\" tabIndex={-1}>\n {renderOptions()}\n </ul>\n </div>\n </div>\n </Fragment>\n );\n }\n);\n","import React, { ComponentPropsWithRef, useEffect, useState } from 'react';\nimport classes from './Select.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'li'> {\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 = React.forwardRef<HTMLLIElement, Props>(\n (\n {\n children,\n className,\n selected = false,\n onOptionSelect,\n disabled,\n filter,\n value,\n ...rest\n }: Props,\n ref\n ) => {\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 ref={ref}\n data-value={value}\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);\n","import React, { ComponentPropsWithRef, Fragment, useState } from 'react';\nimport classes from './Pagination.module.scss';\nimport readyclasses from '../readyclasses.module.scss';\nimport { IconButton } from '../Button/IconButton';\nimport { Icons, Icon } from '../Icon/Icon';\nimport { Input } from '../Form/Input/Input';\nimport { Select } from '../Form/Select/Select';\nimport { Option } from '../Form/Select/Option';\nimport { Label } from '../Form/Label/Label';\n\nexport type PaginationTranslations = {\n totalItems: string;\n itemsPerPage: string;\n itemsPerPageLabel: string;\n currentPage: string;\n currentPageLabel: string;\n};\n\nexport type PageChangeLabels = 'next' | 'previous' | 'first' | 'last';\n\nenum DefaultTranslations {\n totalItems = 'Total items',\n itemsPerPage = 'Items per page',\n currentPage = 'Page %1 of %2',\n itemsPerPageLabel = 'Select how many items per page you want to see.',\n currentPageLabel = 'What page you are currently on.',\n}\n\nexport type PageSize = 10 | 25 | 50;\n\nexport interface Props extends Omit<ComponentPropsWithRef<'div'>, 'translate'> {\n currentPage?: number;\n totalElements?: number;\n pageSize?: PageSize;\n translate?: PaginationTranslations;\n onPageChange: (pageToGoTo: number) => void;\n onPageSizeChange: (pageSize: PageSize) => void;\n}\n\nexport const Pagination = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n totalElements,\n pageSize = 10,\n translate = DefaultTranslations,\n currentPage,\n className,\n onPageChange,\n onPageSizeChange,\n ...rest\n }: Props,\n ref\n ) => {\n /** We use an internal state variable, because we don't want to fire onCurrentPageChange whenever onChange fires on the input. Rather, only when the Enter key is pressed. */\n const [internalCurrentPage, setInternalCurrentPage] = useState(currentPage?.toString() || '1');\n const calculateAmountOfPages = () => (totalElements ? Math.ceil(totalElements / pageSize) : 0);\n\n const onEnterListener = (event: React.KeyboardEvent<HTMLInputElement>) => {\n if (event.code === 'Enter') {\n onPageChange(Number(internalCurrentPage));\n }\n };\n\n const renderCurrentPageTranslation = () => {\n const amountOfPages = calculateAmountOfPages();\n\n if (amountOfPages) {\n const splitCurrentPageTranslation = translate.currentPage.split(' ');\n\n return splitCurrentPageTranslation.map((string) => {\n if (string.includes('%1')) {\n return (\n <Fragment key={string}>\n <Label\n id=\"current-value-input-label\"\n htmlFor=\"current-value-input\"\n className={readyclasses['sr-only']}\n >\n {translate.currentPageLabel}\n </Label>\n <Input\n aria-labelledby=\"current-value-input-label\"\n key=\"input\"\n id=\"current-value-input\"\n type=\"text\"\n size={currentPage?.toString().length}\n max={calculateAmountOfPages()}\n wrapperProps={{ className: classes['current-value-input'] }}\n onKeyUp={onEnterListener}\n onBlur={(event: React.ChangeEvent<HTMLInputElement>) =>\n onPageChange(Number(event.target.value))\n }\n onChange={(e: React.ChangeEvent<HTMLInputElement>) =>\n setInternalCurrentPage(e.target.value)\n }\n name=\"current-value-input\"\n value={internalCurrentPage}\n className={`${classes['form-element']} ${classes['current-page-input']}`}\n />\n </Fragment>\n );\n }\n\n if (string.includes('%2')) {\n return <div key={string}>{string.replace('%2', amountOfPages.toString())}&nbsp;</div>;\n }\n\n return <div key={string}>{string}&nbsp;</div>;\n });\n }\n\n return null;\n };\n\n const onPageSizeChangeHandler = (event: React.ChangeEvent<HTMLSelectElement>) => {\n const pageSizeNumber = Number(event.target.value) as PageSize;\n onPageSizeChange(pageSizeNumber);\n };\n\n const onPageChangeHandler = (pageToGoTo: number) => {\n onPageChange(pageToGoTo);\n };\n\n return (\n <div\n {...rest}\n ref={ref}\n className={`${classes['pagination-wrapper']} ${className ? className : ''}`}\n >\n {totalElements && (\n <div className={classes['total']}>\n <span tabIndex={0}>\n {translate.totalItems}: <span>{totalElements}</span>\n </span>\n </div>\n )}\n <div className={classes['pagination']}>\n {totalElements && pageSize && (\n <div className={classes['per-page']}>\n <Label id=\"page-size-select-label\">{translate.itemsPerPage}</Label>\n <Select\n labeledBy=\"page-size-select-label\"\n className={`${classes['form-element']} ${classes['page-size-select']}`}\n value={pageSize.toString()}\n onChange={onPageSizeChangeHandler}\n >\n <Option value=\"10\">10</Option>\n <Option value=\"25\">25</Option>\n <Option value=\"50\">50</Option>\n </Select>\n </div>\n )}\n <Fragment>\n {((currentPage && currentPage > 2) || (currentPage && currentPage > 1)) && (\n <div className={classes['previous']}>\n {currentPage > 2 && (\n <IconButton\n title=\"first\"\n onClick={() => onPageChangeHandler(0)}\n data-paginate=\"first\"\n >\n <Icon icon={Icons.NavigationFirst} />\n </IconButton>\n )}\n {currentPage > 1 && (\n <IconButton\n title=\"previous\"\n onClick={() => onPageChangeHandler(currentPage - 1)}\n data-paginate=\"previous\"\n >\n <Icon icon={Icons.ChevronLeft} />\n </IconButton>\n )}\n </div>\n )}\n {totalElements && (\n <div className={classes['page']}>{renderCurrentPageTranslation()}</div>\n )}\n <div className={classes['next']}>\n {((currentPage && currentPage < calculateAmountOfPages()) ||\n (currentPage && !totalElements)) && (\n <IconButton\n title=\"next\"\n onClick={() => onPageChangeHandler(currentPage + 1)}\n data-paginate=\"next\"\n >\n <Icon icon={Icons.ChevronRight} />\n </IconButton>\n )}\n {currentPage && totalElements && currentPage < calculateAmountOfPages()! - 1 && (\n <IconButton\n title=\"last\"\n onClick={() => onPageChangeHandler(totalElements / pageSize)}\n data-paginate=\"last\"\n >\n <Icon icon={Icons.NavigationLast} />\n </IconButton>\n )}\n </div>\n </Fragment>\n </div>\n </div>\n );\n }\n);\n","import React, { ComponentPropsWithRef, ReactNode } from 'react';\nimport classes from './Label.module.scss';\nimport readyclasses from '../../readyclasses.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'label'> {\n children?: ReactNode;\n}\n\nexport const Label = React.forwardRef<HTMLLabelElement, Props>(\n ({ children, className, hidden = false, ...rest }: Props, ref) => {\n return (\n <label\n {...rest}\n ref={ref}\n className={`${hidden ? readyclasses['sr-only'] : ''} ${classes['label']} ${\n className ?? ''\n }`}\n >\n {children}\n </label>\n );\n }\n);\n","import React, { ComponentPropsWithRef, useEffect } from 'react';\nimport classes from './TabButton.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'button'> {\n children?: string;\n selected?: boolean;\n focussed?: boolean;\n tabId?: string;\n tabPanelId?: string;\n onTabButtonClick?: () => void;\n}\n\nexport const TabButton = React.forwardRef<HTMLButtonElement, Props>(\n (\n {\n children,\n selected = false,\n focussed = false,\n tabId,\n tabPanelId,\n className,\n onTabButtonClick,\n ...rest\n }: Props,\n ref\n ) => {\n useEffect(() => {\n if (focussed && ref) {\n (ref as React.MutableRefObject<HTMLButtonElement>).current.focus();\n }\n }, [focussed]);\n\n const classNames = [classes['tabbutton']];\n\n selected && classNames.push(classes['selected']);\n focussed && !selected && classNames.push(classes['focussed']);\n className && classNames.push(className);\n\n return (\n <button\n {...rest}\n aria-selected={selected}\n key={tabId}\n className={classNames.join(' ')}\n ref={ref}\n role=\"tab\"\n tabIndex={selected ? 0 : -1}\n type=\"button\"\n aria-controls={tabPanelId}\n id={tabId}\n onClick={onTabButtonClick}\n >\n <span aria-hidden=\"true\">{children}</span>\n {children}\n </button>\n );\n }\n);\n","import React, { ComponentPropsWithRef } from 'react';\nimport classes from './TabPanel.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n children: React.ReactNode;\n tabId: string;\n tabPanelId: string;\n selected?: boolean;\n}\n\nexport const TabPanel = React.forwardRef<HTMLDivElement, Props>(\n ({ children, tabId, tabPanelId, selected = false, className, ...rest }: Props, ref) => (\n <div\n {...rest}\n ref={ref}\n aria-labelledby={tabId}\n className={`${classes['tabpanel']} ${selected ? classes['selected'] : ''} ${className ?? ''}`}\n id={tabPanelId}\n role=\"tabpanel\"\n tabIndex={0}\n hidden={!selected || undefined}\n aria-hidden={!selected}\n >\n {children}\n </div>\n )\n);\n","export const labelId = (id: string) => `${id}-label`;\nexport const descriptionId = (id: string) => `${id}-description`;\n","import React, { ComponentPropsWithRef, useEffect } from 'react';\nimport { createPortal } from 'react-dom';\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 ComponentPropsWithRef<'div'> {\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 = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ...rest\n }: Props,\n ref\n ) => {\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 {...rest}\n ref={ref}\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);\n","import React, { ComponentPropsWithRef, createRef, useEffect } from 'react';\nimport classes from './BaseModalContent.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n id?: string;\n children: React.ReactNode;\n className?: string;\n disableAutoFocus?: boolean;\n}\n\nexport const BaseModalContent = React.forwardRef<HTMLDivElement, Props>(\n ({ id, children, className = '', disableAutoFocus = false, ...rest }: Props, ref) => {\n const contentRef = createRef<HTMLDivElement>();\n\n useEffect(() => {\n if (!disableAutoFocus && ref) {\n (ref as React.RefObject<HTMLDivElement>).current?.focus();\n } else if (!disableAutoFocus) {\n contentRef.current?.focus();\n }\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 {...rest}\n ref={ref || contentRef}\n id={id}\n className={`${classes['content']} ${className}`}\n tabIndex={-1}\n >\n {children}\n </div>\n );\n }\n);\n","import React, { ComponentPropsWithRef } from 'react';\nimport classes from './BaseModalActions.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'footer'> {\n children?: React.ReactNode;\n}\n\nexport const BaseModalActions = React.forwardRef<HTMLElement, Props>(\n ({ children, className = '', ...rest }: Props, ref) => {\n return (\n <footer {...rest} ref={ref} className={`${classes['actions']} ${className}`}>\n {children}\n </footer>\n );\n }\n);\n","import React, { ComponentPropsWithRef } 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 ComponentPropsWithRef<any>, BaseModalActionsProps {\n align: 'left' | 'right';\n}\n\nexport const DialogActions = React.forwardRef<HTMLElement, Props>(\n ({ children, align, ...rest }: Props, ref) => {\n return (\n <BaseModalActions\n {...rest}\n ref={ref}\n className={`${classes['actions']}${align === 'left' ? ' ' + classes['left'] : ''}`}\n >\n {children}\n </BaseModalActions>\n );\n }\n);\n","import React, { ComponentPropsWithRef } from 'react';\nimport { Typography } from '../../../Typography/Typography';\nimport classes from './DialogTitle.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n id: string;\n title: string;\n}\n\nexport const DialogTitle = React.forwardRef<HTMLDivElement, Props>(\n ({ id, title, ...rest }: Props, ref) => {\n return (\n <div {...rest} ref={ref} className={classes['header']}>\n <Typography id={id} className={classes['title']} tag=\"h1\" variant=\"h4\">\n {title}\n </Typography>\n </div>\n );\n }\n);\n","import React, { ComponentPropsWithRef, 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 ComponentPropsWithRef<'div'> {\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 = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n id,\n open,\n children,\n alignActions,\n onClose,\n title,\n primaryAction,\n secondaryAction,\n zIndex,\n disableEscapeKeyDown = true,\n ...rest\n }: Props,\n ref\n ) => {\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 {...rest}\n ref={ref}\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);\n","import React, { ComponentPropsWithRef } 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 ComponentPropsWithRef<'div'> {\n id: string;\n title: string;\n children?: React.ReactNode;\n onClose: (event: React.MouseEvent<HTMLButtonElement>) => void;\n}\n\nexport const BaseModalHeader = React.forwardRef<HTMLDivElement, Props>(\n ({ id, title, children, onClose, ...rest }: Props, ref) => {\n return (\n <div {...rest} ref={ref} 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);\n","import React, { ComponentPropsWithRef } from 'react';\nimport { Dialog } from '../../Dialog/Dialog';\nimport { Typography } from '../../../Typography/Typography';\nimport { DataAttributeKey } from '../../../interfaces';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n open: boolean;\n discardChangesButtonLabel: string;\n keepEditingButtonLabel: string;\n contentLabel: string;\n titleLabel: string;\n [dataAttribute: DataAttributeKey]: any;\n onKeepEditing: () => void;\n onDiscardChanges: () => void;\n}\n\nexport const DiscardChangesDialog = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n open,\n onKeepEditing,\n onDiscardChanges,\n discardChangesButtonLabel,\n keepEditingButtonLabel,\n contentLabel,\n titleLabel,\n ...rest\n }: Props,\n ref\n ) => {\n return (\n <Dialog\n {...rest}\n ref={ref}\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);\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, { ComponentPropsWithRef, ReactNode, RefObject, useEffect, useRef } from 'react';\nimport { usePosition, Offset, Placement } from '../hooks/usePosition';\nimport classes from './Popover.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n children?: ReactNode;\n show?: boolean;\n anchorEl?: RefObject<HTMLOrSVGElement>;\n placement?: Placement;\n offset?: Offset;\n transformOrigin?: Placement;\n}\n\nexport const Popover = React.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 React, { useRef, MouseEventHandler, useState, ComponentPropsWithRef } from 'react';\nimport { Popover } from '../Popover/Popover';\nimport classes from './TextEllipsis.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n children?: string;\n popoverClassName?: string;\n}\n\nexport const TextEllipsis = React.forwardRef<HTMLDivElement, Props>(\n ({ children, popoverClassName, className, ...rest }: Props, ref) => {\n const [showPopover, setShowPopover] = useState(false);\n const textContainer = useRef<HTMLDivElement>(null);\n\n const ellipsisVisible = () => {\n if (\n textContainer.current &&\n textContainer.current.offsetWidth < textContainer.current.scrollWidth\n ) {\n return true;\n }\n return false;\n };\n\n const onMouseEnter: MouseEventHandler<HTMLDivElement> = () => {\n ellipsisVisible() && setShowPopover(true);\n };\n\n const onMouseLeave: MouseEventHandler<HTMLDivElement> = () => {\n ellipsisVisible() && setShowPopover(false);\n };\n\n return (\n <div\n {...rest}\n onMouseEnter={onMouseEnter}\n onMouseLeave={onMouseLeave}\n className={`${classes['text-ellipsis']} ${className ?? ''}`}\n ref={ref || textContainer}\n >\n {children}\n <Popover\n aria-hidden={true}\n data-hidden={!showPopover}\n show={showPopover}\n role=\"tooltip\"\n anchorEl={textContainer}\n className={`${classes.popover} ${popoverClassName ?? ''}`}\n >\n {children}\n </Popover>\n </div>\n );\n }\n);\n","import React, {\n ComponentPropsWithRef,\n ReactNode,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} 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 ComponentPropsWithRef<'div'> {\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 = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ref\n ) => {\n const [identifier] = useState(generateID());\n const [visible, setVisible] = useState(false);\n\n const relativeElement = useRef<HTMLDivElement>(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} ref={ref} 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);\n","import React, { ComponentPropsWithRef, 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 ComponentPropsWithRef<'div'> {\n title: string;\n imageProps?: ImageProps;\n enabled?: boolean;\n loading?: boolean;\n tileAction?: ReactElement<ContextMenuProps> | ReactElement<IconButtonProps>;\n}\n\nexport const Tile = React.forwardRef<HTMLDivElement, Props>(\n ({ title, imageProps, enabled, className, loading, tileAction, ...rest }: Props, ref) => {\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 {...rest}\n tabIndex={0}\n aria-labelledby={tileDescriptionID}\n ref={ref}\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']}>\n {!loading && <img {...imageProps} alt=\"\" />}\n </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);\n","import React, { ComponentPropsWithRef, ReactNode } from 'react';\nimport classes from './Tiles.module.scss';\nimport { Tile } from './Tile';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n children: ReactNode;\n loading?: boolean;\n}\n\nexport const Tiles = React.forwardRef<HTMLDivElement, Props>(\n ({ children, className, loading = false, ...rest }: Props, ref) => {\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 ref={ref}\n className={`${classes['tiles']} ${className ?? ''}`}\n aria-live=\"polite\"\n aria-busy={loading}\n >\n {renderChildren()}\n </div>\n );\n }\n);\n","import React, { ComponentPropsWithRef, 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 ComponentPropsWithRef<'div'> {\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 = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ref\n ) => {\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} ref={ref} 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);\n","import React, { ComponentPropsWithRef, Fragment, 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 ComponentPropsWithRef<'div'> {\n children: ChildrenType | ChildrenType[];\n 'aria-label': string;\n}\n\nexport const Breadcrumbs = React.forwardRef<HTMLDivElement, Props>(\n ({ children, 'aria-label': ariaLabel, className = '', ...rest }: Props, ref) => {\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\n {...rest}\n ref={ref}\n aria-label={ariaLabel}\n className={`${classes['breadcrumbs']} ${className}`}\n >\n {items}\n </nav>\n );\n }\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.Error;\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 { 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, { ComponentPropsWithRef, ReactNode } from 'react';\nimport classes from './FormHelperText.module.scss';\nimport { Typography } from '../../Typography/Typography';\nimport { FormElement } from '../form.interfaces';\n\nexport interface Props extends ComponentPropsWithRef<'div'>, FormElement {\n children?: ReactNode;\n}\n\nexport const FormHelperText = React.forwardRef<HTMLDivElement, Props>(\n ({ children, error, className, ...rest }: Props, ref) => {\n return (\n <Typography\n {...rest}\n ref={ref}\n variant=\"sub-text\"\n tag=\"div\"\n className={`${classes['form-helper-text']} ${error ? classes.error : ''} ${\n className ?? ''\n }`}\n >\n {children}\n </Typography>\n );\n }\n);\n","import React, { ComponentPropsWithRef, createRef, ReactNode } from 'react';\nimport { Icon, Icons } from '../../Icon/Icon';\nimport { KeyValuePair } from '../../interfaces';\nimport { FormSelector } from '../form.interfaces';\nimport { FormHelperText, Props as FormHelperTextProps } from '../FormHelperText/FormHelperText';\nimport classes from './FormSelectorWrapper.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'>, FormSelector {\n children?: ReactNode;\n nestedChildren?: ReactNode;\n containerProps?: ComponentPropsWithRef<'div'> & KeyValuePair;\n helperProps?: FormHelperTextProps;\n disabled?: boolean;\n errorId?: string;\n identifier?: string;\n}\n\nexport const FormSelectorWrapper = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ref\n ) => {\n const helperRef = helperProps?.ref || createRef();\n\n return (\n <div\n {...rest}\n ref={ref}\n className={`${error ? classes['error'] : ''} ${disabled ? classes['disabled'] : ''} ${\n className ?? ''\n }`}\n >\n <div {...containerProps}>{children}</div>\n {(helperText || (helperProps && helperProps.children)) &&\n (!error || parentErrorId || !errorMessage) && (\n <FormHelperText\n {...helperProps}\n ref={helperRef}\n id={`${identifier}`}\n className={`${classes['helper-text']} ${helperProps?.className ?? ''} ${\n error ? classes['error'] : ''\n }`}\n >\n {(helperProps && helperProps.children) || helperText}\n </FormHelperText>\n )}\n {errorMessage && !parentErrorId && error && (\n <span className={classes['error-message']}>\n <Icon className={classes['error-icon']} icon={Icons.Error} />\n <span id={errorId}>{errorMessage}</span>\n </span>\n )}\n {nestedChildren}\n </div>\n );\n }\n);\n","import React, { ComponentPropsWithRef } 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 {\n FormSelectorWrapper,\n Props as FormSelectorWrapperProps,\n} from '../FormSelectorWrapper/FormSelectorWrapper';\n\nexport interface Props extends ComponentPropsWithRef<'input'>, FormSelector {\n children: string;\n value: string;\n formSelectorWrapperProps?: FormSelectorWrapperProps;\n helperProps?: HelperProps;\n}\n\nexport const Radio = React.forwardRef<HTMLInputElement, Props>(\n (\n {\n children,\n disabled,\n className,\n value,\n name,\n helperText,\n parentErrorId,\n parentHelperId,\n error,\n errorMessage,\n checked = false,\n formSelectorWrapperProps,\n helperProps,\n onChange,\n ...rest\n }: Props,\n ref\n ) => {\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 {...formSelectorWrapperProps}\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 ref={ref}\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);\n","import React, { ComponentPropsWithRef, 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 {\n FormSelectorWrapper,\n Props as FormSelectorWrapperProps,\n} from '../FormSelectorWrapper/FormSelectorWrapper';\nimport { FormSelector } from '../form.interfaces';\n\nconst isToggle = (children: ReactNode) => (children as ReactElement)?.props?.['data-toggle'];\n\nexport interface CheckboxProps extends ComponentPropsWithRef<'input'>, FormSelector {\n children: ReactNode;\n label?: string;\n indeterminate?: boolean;\n helperProps?: FormHelperTextProps;\n formSelectorWrapperProps?: FormSelectorWrapperProps;\n onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;\n}\n\nexport const Checkbox = React.forwardRef<HTMLInputElement, CheckboxProps>(\n (\n {\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 formSelectorWrapperProps,\n onChange,\n ...rest\n }: CheckboxProps,\n ref\n ) => {\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 {...formSelectorWrapperProps}\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 ref={ref}\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 && (\n <Icon className={iconClasses.join(' ')} icon={Icons.Square} />\n )}\n <label htmlFor={`${identifier}-checkbox`}>{determineLabel()}</label>\n </FormSelectorWrapper>\n );\n }\n);\n","import React, { ComponentPropsWithRef } from 'react';\nimport { Icon, Props as IconProps, Icons } from '../../Icon/Icon';\nimport classes from './Textarea.module.scss';\nimport { FormElement } from '../form.interfaces';\n\ninterface IconPropsPartial extends Omit<Partial<IconProps>, 'ref'> {}\n\nexport interface Props extends ComponentPropsWithRef<'textarea'>, FormElement {\n wrapperProps?: ComponentPropsWithRef<'div'>;\n errorProps?: IconPropsPartial;\n}\n\nexport const Textarea = React.forwardRef<HTMLTextAreaElement, Props>(\n (\n {\n error = false,\n disabled = false,\n className,\n rows = 4,\n wrapperProps,\n errorProps,\n ...rest\n }: Props,\n ref\n ) => {\n return (\n <div\n {...wrapperProps}\n className={`${classes['textarea-wrapper']} ${wrapperProps?.className ?? ''}`}\n >\n <textarea\n {...rest}\n ref={ref}\n rows={rows}\n className={`${error ? classes['error'] : ''} ${classes['textarea']} ${className ?? ''}`}\n disabled={disabled}\n />\n {error && (\n <Icon\n {...errorProps}\n className={`${classes['warning']} ${errorProps?.className ?? ''}`}\n icon={Icons.Error}\n />\n )}\n </div>\n );\n }\n);\n","import React, { ComponentPropsWithRef } from 'react';\nimport { Checkbox, CheckboxProps } from '../Checkbox/Checkbox';\nimport classes from './Toggle.module.scss';\n\nexport interface Props\n extends ComponentPropsWithRef<'input'>,\n Omit<CheckboxProps, 'indeterminate' | 'errorMessage' | 'error' | 'children' | 'label'> {\n children: string;\n}\n\nexport const Toggle = React.forwardRef<HTMLInputElement, Props>(\n ({ children, checked, disabled, ...rest }: Props, ref) => (\n <div className={classes['toggle-wrapper']}>\n <Checkbox\n {...rest}\n ref={ref}\n checked={checked}\n className={classes['checkbox']}\n helperProps={{ className: classes['toggle-helper'] }}\n disabled={disabled}\n label={children}\n >\n <span\n data-toggle\n aria-hidden=\"true\"\n className={`${classes['toggle']} ${checked ? classes['checked'] : ''} ${\n disabled ? classes['disabled'] : ''\n } `}\n ></span>\n </Checkbox>\n </div>\n )\n);\n","import React, { ComponentPropsWithRef, ReactElement } from 'react';\nimport classes from './FormControl.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n children?: ReactElement | ReactElement[];\n grid?: 1 | 2 | 3;\n align?: 'top' | 'start' | 'middle' | 'center' | 'bottom' | 'end' | 'stretch';\n error?: boolean;\n disabled?: boolean;\n}\n\nexport const FormControl = React.forwardRef<HTMLDivElement, Props>(\n ({ children, disabled, error, className, grid, align = 'center', ...rest }: Props, ref) => {\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 (\n <div className={`${classes['col-' + grid]} ${classes.column}`}>{childElement}</div>\n );\n }\n\n return childElement;\n });\n\n return (\n <div\n {...rest}\n ref={ref}\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);\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, { ComponentPropsWithRef, ReactChild } from 'react';\nimport classes from './FormGroup.module.scss';\nimport { FormHelperText, Props as HelperProps } from '../FormHelperText/FormHelperText';\nimport { Icon, Icons } from '../../Icon/Icon';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\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 disabled?: boolean;\n}\n\nexport const FormGroup = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ref\n ) => {\n return (\n <div\n {...rest}\n ref={ref}\n className={`${classes['form-group']} ${error ? classes.error : ''} ${className ?? ''}`}\n >\n {children}\n\n {(helperText || (errorMessage && error)) && (\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 {(helperProps && helperProps.children) || 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);\n","import React, { ComponentPropsWithRef, 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 { FormElement } from '../../form.interfaces';\n\nexport interface Props extends ComponentPropsWithRef<'div'>, FormGroupProps {\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 FormElement {\n errorMessage?: string;\n helperText?: string;\n helperProps?: HelperProps;\n label?: string;\n name: string;\n required?: boolean;\n disabled?: boolean;\n}\n\nexport const Wrapper = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ref\n ) => {\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} ref={ref} 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);\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 (\n (value?.length && value.length > 0) ||\n placeholder ||\n type === 'datetime-local' ||\n type === 'time'\n ) {\n setFloatingLabelActive(true);\n }\n }, []);\n\n useEffect(() => {\n if ((value?.length && value.length > 0) || 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, { ComponentPropsWithRef, useEffect, useRef, useState } 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 PartialInputProps extends Partial<InputProps> {}\n\nexport interface Props extends ComponentPropsWithRef<'div'>, WrapperProps {\n label: string;\n type: Type;\n name: string;\n inputProps?: PartialInputProps;\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\nconst useLabelOffset = (\n wrapper: React.RefObject<HTMLDivElement>,\n input: React.RefObject<HTMLInputElement>,\n floatingLabelActive: boolean,\n prefix?: string\n) => {\n const [labelOffset, setLabelOffset] = useState({});\n\n const resetLabelOffset = () => setLabelOffset({ left: undefined });\n\n useEffect(() => {\n if (wrapper.current && input.current && prefix) {\n if (floatingLabelActive) {\n resetLabelOffset();\n } else {\n const prefixDifference =\n input.current.getBoundingClientRect().left -\n wrapper.current.getBoundingClientRect().left +\n 4;\n\n setLabelOffset({ left: `${prefixDifference}px` });\n }\n }\n }, [wrapper.current, input.current, prefix, floatingLabelActive]);\n\n return { labelOffset };\n};\n\nexport const InputWrapper = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n type,\n name,\n inputProps,\n helperText,\n helperProps,\n value,\n className,\n error,\n onChange,\n onBlur,\n onFocus,\n ...rest\n }: Props,\n ref\n ) => {\n const {\n errorId,\n floatingLabelActive,\n setFloatingLabelActive,\n hasFocus,\n setHasFocus,\n helperId,\n labelId,\n } = useWrapper(value, inputProps?.placeholder, type);\n const { prefix, suffix } = inputProps || {};\n const wrapper = useRef<HTMLDivElement>(null);\n const input = useRef<HTMLInputElement>(null);\n const hasValueOrActiveFloatingLabel = !!value || floatingLabelActive;\n const labelClasses = [classes['input-label']];\n const { labelOffset } = useLabelOffset(\n (ref as React.RefObject<HTMLDivElement>) || wrapper,\n (inputProps && (inputProps.ref as React.RefObject<HTMLInputElement>)) || input,\n floatingLabelActive,\n prefix\n );\n\n hasFocus && labelClasses.push(classes['focus']);\n\n return (\n <Wrapper\n {...rest}\n ref={ref || wrapper}\n name={name}\n className={`${classes['input-wrapper']} ${className ?? ''}`}\n labelProps={{\n id: labelId,\n className: labelClasses.join(' '),\n style: { ...labelOffset },\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 prefix={hasValueOrActiveFloatingLabel ? prefix : ''}\n suffix={hasValueOrActiveFloatingLabel ? suffix : ''}\n wrapperProps={{\n className: `${floatingLabelActive ? classes['floating-label-active'] : ''} ${\n inputProps?.wrapperProps?.className ?? ''\n }`,\n }}\n ref={(inputProps && inputProps.ref) || input}\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 e.target.placeholder ||\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 inputProps?.className ?? ''\n }`}\n name={name}\n error={error}\n id={name}\n value={value}\n type={type}\n />\n </Wrapper>\n );\n }\n);\n","import React, { ComponentPropsWithRef, 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\ninterface PartialSelectProps extends Partial<SelectProps> {}\n\nexport interface Props\n extends Omit<ComponentPropsWithRef<'div'>, 'onChange'>,\n Omit<WrapperProps, 'onChange' | 'error'> {\n children: ReactChild | ReactChild[];\n placeholder?: string;\n value: string;\n error?: boolean;\n selectProps?: PartialSelectProps;\n onChange?: (event: React.ChangeEvent<HTMLSelectElement>) => void;\n onClear?: () => void;\n}\n\nexport const SelectWrapper = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n children,\n error,\n value,\n placeholder,\n selectProps,\n helperProps,\n onChange,\n onClear,\n ...rest\n }: Props,\n ref\n ) => {\n const { errorId, floatingLabelActive, helperId, labelId } = useWrapper(value, placeholder);\n\n return (\n <Wrapper\n {...rest}\n ref={ref}\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);\n","import React, { ComponentPropsWithRef, 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<\n ComponentPropsWithRef<'div'>,\n 'onFocus' | 'onChange' | 'onBlur' | 'onMouseEnter' | 'onMouseLeave'\n >,\n 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 = React.forwardRef<HTMLDivElement, Props>(\n (\n {\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 ref\n ) => {\n const {\n errorId,\n floatingLabelActive,\n setFloatingLabelActive,\n hasFocus,\n setHasFocus,\n helperId,\n labelId,\n } = useWrapper(value, placeholder);\n const [hover, setHover] = useState(false);\n\n const optionalClasses: string[] = [];\n\n hasFocus && optionalClasses.push(classes['focus']);\n hover && optionalClasses.push(classes['hover']);\n disabled && optionalClasses.push(classes['disabled']);\n error && optionalClasses.push(classes['error']);\n\n return (\n <Wrapper\n {...rest}\n ref={ref}\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 name={name}\n id={name}\n value={value}\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 || e.target.placeholder || 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 wrapperProps={{\n className: `${classes['textarea-wrapper']}} ${optionalClasses.join(' ')}`,\n }}\n errorProps={{ className: classes['error-icon'] }}\n />\n </Wrapper>\n );\n }\n);\n","import React, { ComponentPropsWithRef, ReactNode, ReactElement } from 'react';\nimport readyclasses from '../../readyclasses.module.scss';\nimport classes from './Fieldset.module.scss';\nimport { Typography, Variant } from '../../Typography/Typography';\nimport { Input } from '../Input/Input';\nimport { Select } from '../Select/Select';\nimport { Radio } from '../Radio/Radio';\nimport { Checkbox } from '../Checkbox/Checkbox';\nimport { Textarea } from '../Textarea/Textarea';\nimport { Toggle } from '../Toggle/Toggle';\nimport { Label } from '../Label/Label';\nimport { FormControl } from '../FormControl/FormControl';\nimport { FormSelectorWrapper } from '../FormSelectorWrapper/FormSelectorWrapper';\nimport { FormHelperText } from '../FormHelperText/FormHelperText';\nimport { InputWrapper } from '../Wrapper/InputWrapper/InputWrapper';\nimport { SelectWrapper } from '../Wrapper/SelectWrapper/SelectWrapper';\nimport { TextareaWrapper } from '../Wrapper/TextareaWrapper/TextareaWrapper';\n\nexport interface Props extends ComponentPropsWithRef<'fieldset'> {\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 disablePropagation?: boolean;\n}\n\nexport const Fieldset = React.forwardRef<HTMLFieldSetElement, Props>(\n (\n {\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 disablePropagation = false,\n ...rest\n }: Props,\n ref\n ) => {\n const renderChildren = () => {\n if (!children) return;\n\n /* All right, so the issue is that whenever we try to add disabled and error to a component that doesn't accept it, \n React will throw an error. However, it might occur that we want a component inside of Fieldset because of aesthetic purposes \n (fieldset applies a sort of container with white background and if we want to display it inside of this container... then yea).\n So instead we supply an array of components that we want to add the disabled and error prop to and check if child.type equals one of these. */\n const allowedComponents: ReactNode[] = [\n Input,\n Select,\n Radio,\n Checkbox,\n Textarea,\n Toggle,\n Label,\n FormControl,\n FormSelectorWrapper,\n FormHelperText,\n InputWrapper,\n SelectWrapper,\n TextareaWrapper,\n ];\n\n return React.Children.map(children, (child: ReactElement) => {\n if (allowedComponents.includes(child.type) && !disablePropagation) {\n return React.cloneElement(child, {\n disabled: child.props.disabled ?? disabled,\n error: child.props.error ?? error,\n });\n }\n\n return child;\n });\n };\n\n return (\n <fieldset\n {...rest}\n ref={ref}\n disabled={disabled}\n style={{ backgroundColor: background, ...rest.style }}\n className={`${classes.fieldset} ${noPadding ? classes['no-padding'] : ''} ${\n className ?? ''\n }`}\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);\n","import React, { ComponentPropsWithRef, 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 ComponentPropsWithRef<'div'>, WrapperProps {\n children: ReactElement[] | ReactElement;\n fieldsetProps: FieldsetProps;\n onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;\n}\n\nexport const CheckboxWrapper = React.forwardRef<HTMLDivElement, Props>(\n ({ children, error = false, helperText, helperProps, fieldsetProps, ...rest }: Props, ref) => {\n const { errorId, helperId } = useWrapper();\n\n useEffect(() => {\n if (fieldsetProps.legend === undefined) {\n console.error(\n `You should give your Fieldset component a legend prop so a legend element is rendered. This error was thrown in CheckboxWrapper. You can add this legend prop through the fieldsetProps prop by passing an object (fieldsetProps={{ legend: \"legend 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} error={error} required={rest.required}>\n <Wrapper\n {...rest}\n ref={ref}\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.Error}\n errorId={errorId}\n >\n {renderChildren()}\n </Wrapper>\n </Fieldset>\n );\n }\n);\n","import React, { ComponentPropsWithRef, 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 ComponentPropsWithRef<'div'>, WrapperProps {\n children: ReactElement | ReactElement[];\n fieldsetProps: FieldsetProps;\n value: string;\n onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;\n}\n\nexport const RadioWrapper = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n children,\n error,\n name,\n helperText,\n helperProps,\n fieldsetProps,\n value,\n onChange,\n disabled,\n ...rest\n }: Props,\n ref\n ) => {\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 legend prop so a legend element is rendered. This error was thrown in RadioWrapper. You can add this legend prop through the fieldsetProps prop by passing an object (fieldsetProps={{ legend: \"legend 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} error={error} disabled={disabled}>\n <Wrapper\n {...rest}\n ref={ref}\n disabled={disabled}\n name={name}\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.Error}\n floatingLabel={false}\n >\n {renderChildren()}\n </Wrapper>\n </Fieldset>\n );\n }\n);\n","import React, { ComponentPropsWithRef, 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<ComponentPropsWithRef<'div'>, 'onClick'> {\n steps: Step[];\n currentStepNo: number;\n onClick?: (stepNo: number) => void;\n futureStepsClickable?: boolean;\n stepScreenReaderLabel: string;\n}\n\nexport const BaseWizardSteps = React.forwardRef<HTMLDivElement, Props>(\n (\n {\n steps,\n currentStepNo,\n onClick,\n futureStepsClickable = false,\n stepScreenReaderLabel,\n ...rest\n }: Props,\n ref\n ) => {\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 {...rest} ref={ref} className={classes['wizard']}>\n {generatedSteps}\n </div>\n );\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, { ComponentPropsWithRef, useContext } from 'react';\nimport { WizardStateContext } from '../WizardStateProvider';\nimport { BaseWizardSteps } from '../BaseWizardSteps/BaseWizardSteps';\nimport { changeCurrentStepNo } from '../wizardStateReducer';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n onStepClick: (currentStepNo: number, selectedStepNo: number) => boolean;\n}\n\nexport const WizardSteps = React.forwardRef<HTMLDivElement, Props>(\n ({ onStepClick, ...rest }: Props, ref) => {\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 {...rest}\n ref={ref}\n onClick={onClick}\n steps={steps}\n currentStepNo={currentStepNo}\n stepScreenReaderLabel={stepScreenReaderLabel}\n futureStepsClickable={mode === 'edit'}\n />\n );\n }\n);\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, { 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 modalRef?: React.RefObject<HTMLDivElement>;\n dialogRef?: React.RefObject<HTMLDivElement>;\n}\n\nexport const DiscardChangesModal = ({\n id,\n children,\n headerProps,\n discardChangedDialogProps,\n modalRef,\n dialogRef,\n onClose,\n hasUnsavedChanges,\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} ref={modalRef} onClose={onCloseWrapper} {...rest}>\n <ModalHeader {...headerProps} id={`${id}-label`} onClose={onCloseWrapper} />\n {children}\n </Modal>\n <DiscardChangesDialog\n {...discardChangedDialogProps}\n ref={dialogRef}\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, { 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 from 'react';\n\nexport interface Props {\n title: string;\n children?: React.ReactNode;\n selected?: boolean;\n focussed?: boolean;\n buttonRef?: React.RefObject<HTMLButtonElement>;\n panelRef?: React.RefObject<HTMLDivElement>;\n onTabButtonClick?: () => void;\n}\n\nexport const Tab = (args: Props) => {\n return (\n <div {...args}>{`A <Tab /> component should only be used inside the <Tabs /> component.`}</div>\n );\n};\n","import React, {\n ComponentPropsWithRef,\n createRef,\n MutableRefObject,\n useEffect,\n useRef,\n useState,\n} from 'react';\nimport { generateID } from '../util/helper';\nimport { Props as TabProps } from './Tab';\nimport { TabButton } from './TabButton';\nimport { TabPanel } from './TabPanel';\nimport classes from './Tabs.module.scss';\n\nexport interface Props extends ComponentPropsWithRef<'div'> {\n children: React.ReactElement<TabProps> | React.ReactElement<TabProps>[];\n selected?: number;\n 'aria-label'?: string;\n onTabChange?: (index: number) => void;\n}\n\nexport const Tabs = ({\n children,\n selected = 0,\n 'aria-label': ariaLabel,\n onTabChange,\n className,\n ...rest\n}: Props) => {\n const indicatorRef = useRef<HTMLDivElement>(null);\n const [indicatorPosition, setIndicatorPosition] = useState({ left: 0, top: 0 });\n const [indicatorWidth, setIndicatorWidth] = useState(0);\n\n const [max] = useState(React.Children.count(children) - 1);\n const min = 0;\n\n const [selectedTab, setSelectedTab] = useState(Math.min(max, Math.max(min, selected)));\n const [focussedTab, setFocussedTab] = useState(-1);\n const [tabIds] = useState([...Array(max)].map(() => generateID()));\n const [tabPanelIds] = useState([...Array(max)].map(() => generateID()));\n\n useEffect(() => {\n setSelectedTab(Math.min(max, Math.max(min, selected)));\n setFocussedTab(-1);\n }, [selected]);\n\n useEffect(() => {\n calculateIndicatorPosition();\n }, [selectedTab]);\n\n const calculateIndicatorPosition = () => {\n const selectedTabButton = (\n tabButtons[selectedTab].ref as MutableRefObject<HTMLButtonElement | null>\n ).current as HTMLButtonElement;\n\n setIndicatorPosition({\n left: selectedTabButton.offsetLeft,\n top:\n selectedTabButton.offsetTop +\n selectedTabButton.offsetHeight -\n indicatorRef.current!.offsetHeight,\n });\n setIndicatorWidth(selectedTabButton.offsetWidth);\n };\n\n const handleKeyDown = (e: React.KeyboardEvent<HTMLElement>) => {\n // do not show focus unless we came here before\n let currentFocussedTab = focussedTab === -1 ? selectedTab : focussedTab;\n\n switch (e.code) {\n case 'ArrowLeft':\n setFocussedTab(currentFocussedTab === min ? max : currentFocussedTab - 1);\n break;\n case 'ArrowRight':\n setFocussedTab(currentFocussedTab === max ? min : currentFocussedTab + 1);\n break;\n case 'Home':\n setFocussedTab(min);\n break;\n case 'End':\n setFocussedTab(max);\n break;\n case 'Space':\n case 'Enter':\n activateTab(currentFocussedTab);\n break;\n }\n };\n\n const handleBlur = () => {\n setFocussedTab(selectedTab);\n };\n\n const activateTab = (index: number) => {\n setSelectedTab(index);\n setFocussedTab(index);\n onTabChange && onTabChange(index);\n };\n\n const tabButtons = React.Children.map(children, (child, index) =>\n React.createElement(TabButton, {\n ref: child.props.buttonRef || createRef<HTMLButtonElement>(),\n key: generateID(),\n tabId: tabIds[index],\n tabPanelId: tabPanelIds[index],\n selected: selectedTab === index,\n focussed: focussedTab === index,\n onTabButtonClick: () => activateTab(index),\n children: child.props.title,\n })\n );\n\n const tabPanels = React.Children.map(children, (child, index) =>\n React.createElement(TabPanel, {\n ref: child.props.panelRef || createRef<HTMLDivElement>(),\n key: generateID(),\n selected: selectedTab === index,\n tabId: tabIds[index],\n tabPanelId: tabPanelIds[index],\n children: child.props.children,\n })\n );\n\n return (\n <div {...rest} className={`${classes['tabs']} ${className ?? ''}`}>\n <div\n role=\"tablist\"\n onKeyDown={handleKeyDown}\n onBlur={handleBlur}\n aria-label={ariaLabel}\n className={classes['tablist']}\n >\n <div className={classes['tabdivider']} />\n {tabButtons}\n <div\n className={classes['indicator']}\n ref={indicatorRef}\n aria-hidden=\"true\"\n tabIndex={-1}\n style={{\n width: indicatorWidth,\n ...indicatorPosition,\n }}\n />\n </div>\n <div className={classes['tabpanels']}>{tabPanels}</div>\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, { useEffect, useState } from 'react';\nimport { generateID } from '../util/helper';\n\ninterface Arguments {\n componentToRepeat: React.ReactElement;\n}\n\nexport const useRepeater = <T>({ componentToRepeat }: Arguments) => {\n const [repeatedComponents, setRepeatedComponents] = useState<JSX.Element[]>([]);\n\n useEffect(() => {\n repeat();\n }, []);\n\n const repeat = () => {\n const clonedComponent = React.cloneElement(componentToRepeat, { key: generateID(20) });\n\n setRepeatedComponents((prevState) => [...prevState, clonedComponent]);\n };\n\n const remove = (componentToRemove: React.ReactElement<T>) => {\n const newRepeatedComponents = repeatedComponents.filter(\n (component) => component !== componentToRemove\n );\n\n setRepeatedComponents(newRepeatedComponents);\n };\n\n return {\n repeatedComponents,\n repeat,\n remove,\n };\n};\n","import { useContext } from 'react';\nimport { SnackbarContext } from './SnackbarProvider/SnackbarStateProvider';\n\nexport const useSnackbar = () => useContext(SnackbarContext);\n"],"names":["BaseStyling","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","React","forwardRef","ref","children","variant","tag","style","spacing","_ref$className","_ref","className","rest","_objectWithoutPropertiesLoose","_excluded","includes","Error","styleWithSpacing","spacingProps","entries","reduce","prev","_extends2","matches","String","matchAll","cssSpacingValue","Array","from","map","_ref2","Number","join","_extends","useSpacing","classes","BaseButton","_ref$type","type","Button","_ref$variant","_ref$color","color","_ref$startIcon","startIcon","_ref$endIcon","endIcon","additionalClasses","Link","_ref$disabled","disabled","to","component","classNames","download","rel","undefined","href","target","IconButton","_ref$iconSize","iconSize","title","console","error","iconButtonClasses","Fragment","readyclasses","Icons","Icon","icon","size","_ref$tag","fontSize","dateTypes","Input","_ref$error","name","wrapperProps","labeledBy","prefix","suffix","onFocus","onBlur","useState","focus","_useState","setFocus","useEffect","inputClassNames","iconClassNames","wrapperClasses","event","useBodyClick","checkFunction","callbackFunction","dependingStateVariable","bodyClickListener","window","addEventListener","removeEventListener","generateID","stringToWeaveIn","hashCharacters","id","test","Math","floor","random","slice","filterProps","props","regexPattern","returnFiltered","acc","key","filter","prevObj","currKeyValPair","Select","placeholder","describedBy","_ref$searchPlaceholde","searchPlaceholder","value","onChange","onClear","expanded","setExpanded","opacity","_useState2","setOpacity","_useState3","setFilter","display","_useState4","setDisplay","listPosition","_useState5","setListPosition","optionsListMaxHeight","_useState6","setOptionsListMaxHeight","containerReference","useRef","optionListReference","nativeSelect","onOptionChangeHandler","current","currentTarget","dataset","dispatchEvent","Event","bubbles","val","Children","forEach","child","position","top","bottom","getBoundingClientRect","innerHeight","listHeight","height","transformOrigin","availableSpace","calculateOptionListMaxHeight","rePositionList","closest","tabIndex","onClick","Warning","TimesThin","preventDefault","stopPropagation","TriangleDown","maxHeight","isArray","autoFocus","role","cloneElement","onOptionSelect","selected","Option","_ref$selected","showOption","setShowOption","onSelectHandler","toLowerCase","match","onKeyPress","DefaultTranslations","Label","_ref$hidden","hidden","Pagination","amountOfPages","totalElements","_ref$pageSize","pageSize","_ref$translate","translate","currentPage","onPageChange","onPageSizeChange","toString","internalCurrentPage","setInternalCurrentPage","calculateAmountOfPages","ceil","onEnterListener","code","onPageChangeHandler","pageToGoTo","totalItems","itemsPerPage","pageSizeNumber","NavigationFirst","ChevronLeft","split","string","htmlFor","currentPageLabel","max","onKeyUp","replace","ChevronRight","NavigationLast","TabButton","_ref$focussed","focussed","tabId","tabPanelId","onTabButtonClick","TabPanel","labelId","descriptionId","BaseModal","open","onClose","_ref$containerClassNa","containerClassName","labelledby","describedby","_ref$disableEscapeKey","disableEscapeKeyDown","_ref$disableBackdrop","disableBackdrop","zIndex","_ref$domRoot","domRoot","body","querySelectorAll","removeProperty","useSetBodyScroll","createPortal","onKeyDown","BaseModalContent","_ref$disableAutoFocus","disableAutoFocus","contentRef","createRef","_ref$current","_contentRef$current","BaseModalActions","DialogActions","align","DialogTitle","Dialog","secondaryLabel","restOfSecondaryAction","alignActions","primaryAction","secondaryAction","dialogId","primaryLabel","label","restOfPrimaryAction","_excluded2","PrimaryButton","TertiaryButton","_excluded3","width","maxLength","BaseModalHeader","Times","DiscardChangesDialog","onKeepEditing","onDiscardChanges","discardChangesButtonLabel","keepEditingButtonLabel","contentLabel","titleLabel","margin","defaultConfigObject","relativeElement","elementToBePositioned","horizontal","vertical","placement","offset","right","left","usePosition","providedConfigObject","configObject","setPosition","_calculatePlacement","relEl","elDimensions","axis","_configObject$transfo","_configObject$transfo2","placementValue","requestedReturnValue","placementOriginDefinition","_determineCenteredPlacementOrigin","_calculateInitialPlacementValue","valueWithOffset","_configObject$offset","_configObject$offset2","_configObject$offset7","_configObject$offset8","_configObject$offset3","_configObject$offset4","_configObject$offset5","_configObject$offset6","_configObject$offset9","_configObject$offset10","_configObject$offset11","_configObject$offset12","returnValue","_applyOffsetToPlacementValue","valueCorrectionForViewportOverflow","innerWidth","_fixPossibleViewportOverflow","_calculatePlacementValue","direction","oppositeDirection","prevState","calculatePosition","_configObject$relativ","relativeElRect","elementToBePositionedDimensions","offsetHeight","offsetWidth","clonedRelEl","center","centerv","centerh","x","y","Popover","show","anchorEl","elToBePositioned","_usePosition","TextEllipsis","popoverClassName","showPopover","setShowPopover","textContainer","ellipsisVisible","scrollWidth","onMouseEnter","onMouseLeave","defaultPosition","Tooltip","_ref$placement","_ref$offset","_ref$transformOrigin","identifier","visible","setVisible","escapePressHandler","useLayoutEffect","isValidElement","InfoCircle","Tile","imageProps","enabled","loading","tileAction","tileDescriptionID","justifyContent","Checkmark","Forbidden","readyClasses","src","alt","Image","Tiles","_ref$loading","ContextMenu","trigger","_ref$show","onShow","showContextMenu","setShowContextMenu","Breadcrumbs","ariaLabel","items","index","SnackbarContext","createContext","enqueueSnackbar","enqueueSuccessSnackbar","enqueueErrorSnackbar","SnackbarContextProvider","Provider","initialState","SnackbarContainer","SnackbarItem","duration","content","_ref$actions","actions","closeButtonTitle","timerHandler","useAnimation","callback","animatedObjectRef","animationStarted","setAnimationStarted","onAnimationEnd","_animatedObjectRef$cu","_animatedObjectRef$cu2","startAnimation","setTimeout","clearTimeout","actionButtons","actionProp","CheckmarkCircleBreakout","useFormSelector","setDescribedBy","errorId","errorMessage","parentErrorId","helperText","parentHelperId","FormHelperText","FormSelectorWrapper","_helperProps$classNam","nestedChildren","containerProps","helperProps","helperRef","Radio","_ref$checked","checked","formSelectorWrapperProps","_useFormSelector","onChangeHandler","nativeEvent","clonedEvent","constructor","defineProperty","writable","Circle","isToggle","_children$props","Checkbox","indeterminate","iconClasses","toArray","MinusSquare","CheckmarkSquare","Square","determineLabel","Textarea","_wrapperProps$classNa","_errorProps$className","_ref$rows","rows","errorProps","Toggle","FormControl","grid","_ref$align","childElement","column","FormGroup","errorMessageIcon","_ref$errorMessageIcon","errorMessageIconPosition","helperId","helperIndent","marginLeft","message","Wrapper","_ref$floatingLabel","floatingLabel","floatingLabelActive","required","labelProps","innerClassName","labelClasses","wrapper","useWrapper","setFloatingLabelActive","hasFocus","setHasFocus","InputWrapper","_inputProps$wrapperPr","_inputProps$wrapperPr2","_inputProps$className","inputProps","input","hasValueOrActiveFloatingLabel","labelOffset","setLabelOffset","prefixDifference","useLabelOffset","_inputProps$placehold","SelectWrapper","_selectProps$classNam","selectProps","_useWrapper","TextareaWrapper","textareaProps","hover","setHover","optionalClasses","_textareaProps$placeh","Fieldset","legend","_ref$legendStyle","legendStyle","_ref$hideLegend","hideLegend","_ref$background","background","noBackground","_ref$noPadding","noPadding","_ref$required","_ref$disablePropagati","disablePropagation","backgroundColor","allowedComponents","_child$props$disabled","_child$props$error","renderChildren","CheckboxWrapper","fieldsetProps","RadioWrapper","BaseWizardSteps","steps","currentStepNo","_ref$futureStepsClick","futureStepsClickable","stepScreenReaderLabel","generatedSteps","step","stepNo","stepState","disabledStyleClassName","clickableClassName","stepNumberString","getStepContent","changeCurrentStepNo","payload","reducer","state","action","WizardStateContext","dispatch","WizardStateProvider","_useReducer","useReducer","WizardSteps","onStepClick","useContext","_useContext$state","_useContext","selectedStepNo","mode","WizardContent","onStepChange","setWizardState","useStepChanging","_ref$properties","properties","defaultProperties","colorFocus","colorPrimary","colorSecondary","colorTertiary","defaultLineHeight","buttonBorderRadius","buttonBorderWidth","buttonFontSize","buttonBorderStyle","buttonFillTextColor","buttonFillBackgroundColor","buttonOutlineHoverTextColor","inputBorderColor","inputBorderRadius","inputBorderWidth","inputBorderStyle","inputBackgroundColor","modalShadowColor","modalBackgroundColor","modalHeaderBackgroundColor","snackbarTextColor","snackbarInfoBackgroundColor","snackbarSuccessBackgroundColor","snackbarErrorBackgroundColor","snackbarBorderRadius","tabsBackgroundColor","tabBorderWidth","tabBorderStyle","tablistBorderWidth","tablistBorderStyle","tablistBorderColor","tabTextColor","default","success","greyedOut","warning","fontFamily","fontFamilyCode","fontSizeH1","fontSizeH2","fontSizeH3","fontSizeH4","fontSizeSub","fontSizeCode","isLoading","setIsLoading","setCSSProperties","CSSPropertiesObject","_i","_Object$entries","_Object$entries$_i","formattedPropertyName","documentElement","setProperty","mergedState","headerProps","discardChangedDialogProps","modalRef","dialogRef","hasUnsavedChanges","openDiscardChangesDialog","setOpenDiscardChangesDialog","onCloseWrapper","Modal","ModalHeader","_temp","_ref$autoHideDuration","autoHideDuration","long","short","_ref$stackSize","stackSize","setSnackbars","options","item","_options$variant","_options$duration","getDuration","onItemClosed","snackbarList","snackbarPortal","args","onTabChange","indicatorRef","indicatorPosition","setIndicatorPosition","indicatorWidth","setIndicatorWidth","count","min","selectedTab","setSelectedTab","focussedTab","setFocussedTab","tabIds","tabPanelIds","calculateIndicatorPosition","selectedTabButton","tabButtons","offsetLeft","offsetTop","activateTab","buttonRef","tabPanels","panelRef","currentFocussedTab","initialStepNo","_props$initialStepNo","onCancel","onNext","onPrevious","onSaveAndClose","cancelButtonLabel","previousButtonLabel","nextButtonLabel","saveAndCloseButtonLabel","nextStepNo","useMemo","findIndex","calculateNextStepNo","useNextStepNo","hasNextStep","previousStepNo","reversedCurrentStepNo","reversedPrevStepNo","reverse","calculatePrevStepNo","usePreviousStepNo","hasPreviousStep","isLastStepOrEditMode","changeStepNo","componentToRepeat","repeatedComponents","setRepeatedComponents","repeat","clonedComponent","remove","componentToRemove","newRepeatedComponents"],"mappings":"6iBAyDaA,ICzDTC,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,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