@e1011/es-kit 1.0.110 → 1.0.114

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (84) hide show
  1. package/dist/hooks/esm/index.css +106 -0
  2. package/dist/hooks/index.css +106 -0
  3. package/dist/lib/cjs/_virtual/_rollupPluginBabelHelpers.js +1 -1
  4. package/dist/lib/cjs/index.css +106 -0
  5. package/dist/lib/cjs/node_modules/core-js/modules/es.array.index-of.js +2 -0
  6. package/dist/lib/cjs/node_modules/core-js/modules/es.array.index-of.js.map +1 -0
  7. package/dist/lib/cjs/src/core/ui/components/container/CollapsibleContainer.js +2 -0
  8. package/dist/lib/cjs/src/core/ui/components/container/CollapsibleContainer.js.map +1 -0
  9. package/dist/lib/cjs/src/core/ui/components/container/CollapsibleContainer.module.scss.js +2 -0
  10. package/dist/lib/cjs/src/core/ui/components/container/CollapsibleContainer.module.scss.js.map +1 -0
  11. package/dist/lib/cjs/src/core/ui/components/container/CollapsibleContainerS.js +2 -0
  12. package/dist/lib/cjs/src/core/ui/components/container/CollapsibleContainerS.js.map +1 -0
  13. package/dist/lib/cjs/src/core/ui/components/container/Flex.js +2 -0
  14. package/dist/lib/cjs/src/core/ui/components/container/Flex.js.map +1 -0
  15. package/dist/lib/cjs/src/core/ui/components/container/LayoutBox.js +2 -0
  16. package/dist/lib/cjs/src/core/ui/components/container/LayoutBox.js.map +1 -0
  17. package/dist/lib/cjs/src/core/ui/components/container/Placeholder.js +2 -0
  18. package/dist/lib/cjs/src/core/ui/components/container/Placeholder.js.map +1 -0
  19. package/dist/lib/cjs/src/core/ui/components/container/ResizableContainer.js +2 -0
  20. package/dist/lib/cjs/src/core/ui/components/container/ResizableContainer.js.map +1 -0
  21. package/dist/lib/cjs/src/core/ui/components/container/layoutBox.module.scss.js +2 -0
  22. package/dist/lib/cjs/src/core/ui/components/container/layoutBox.module.scss.js.map +1 -0
  23. package/dist/lib/cjs/src/core/ui/components/dividers/DividerLine.js +2 -0
  24. package/dist/lib/cjs/src/core/ui/components/dividers/DividerLine.js.map +1 -0
  25. package/dist/lib/cjs/src/core/ui/components/dividers/divider.module.scss.js +2 -0
  26. package/dist/lib/cjs/src/core/ui/components/dividers/divider.module.scss.js.map +1 -0
  27. package/dist/lib/cjs/src/core/ui/components/field/Field.js +2 -0
  28. package/dist/lib/cjs/src/core/ui/components/field/Field.js.map +1 -0
  29. package/dist/lib/cjs/src/core/ui/components/icon/Icon.js +2 -0
  30. package/dist/lib/cjs/src/core/ui/components/icon/Icon.js.map +1 -0
  31. package/dist/lib/cjs/src/core/ui/components/icon/IconBase.js +2 -0
  32. package/dist/lib/cjs/src/core/ui/components/icon/IconBase.js.map +1 -0
  33. package/dist/lib/cjs/src/core/ui/components/icon/IconWC.js +2 -0
  34. package/dist/lib/cjs/src/core/ui/components/icon/IconWC.js.map +1 -0
  35. package/dist/lib/cjs/src/core/ui/components/icon/icon.module.scss.js +2 -0
  36. package/dist/lib/cjs/src/core/ui/components/icon/icon.module.scss.js.map +1 -0
  37. package/dist/lib/cjs/src/core/ui/utils/style.js +2 -0
  38. package/dist/lib/cjs/src/core/ui/utils/style.js.map +1 -0
  39. package/dist/lib/cjs/src/index.js +1 -1
  40. package/dist/lib/esm/_virtual/_rollupPluginBabelHelpers.js +1 -1
  41. package/dist/lib/esm/index.css +106 -0
  42. package/dist/lib/esm/node_modules/core-js/modules/es.array.index-of.js +2 -0
  43. package/dist/lib/esm/node_modules/core-js/modules/es.array.index-of.js.map +1 -0
  44. package/dist/lib/esm/src/core/ui/components/container/CollapsibleContainer.js +2 -0
  45. package/dist/lib/esm/src/core/ui/components/container/CollapsibleContainer.js.map +1 -0
  46. package/dist/lib/esm/src/core/ui/components/container/CollapsibleContainer.module.scss.js +2 -0
  47. package/dist/lib/esm/src/core/ui/components/container/CollapsibleContainer.module.scss.js.map +1 -0
  48. package/dist/lib/esm/src/core/ui/components/container/CollapsibleContainerS.js +2 -0
  49. package/dist/lib/esm/src/core/ui/components/container/CollapsibleContainerS.js.map +1 -0
  50. package/dist/lib/esm/src/core/ui/components/container/Flex.js +2 -0
  51. package/dist/lib/esm/src/core/ui/components/container/Flex.js.map +1 -0
  52. package/dist/lib/esm/src/core/ui/components/container/LayoutBox.js +2 -0
  53. package/dist/lib/esm/src/core/ui/components/container/LayoutBox.js.map +1 -0
  54. package/dist/lib/esm/src/core/ui/components/container/Placeholder.js +2 -0
  55. package/dist/lib/esm/src/core/ui/components/container/Placeholder.js.map +1 -0
  56. package/dist/lib/esm/src/core/ui/components/container/ResizableContainer.js +2 -0
  57. package/dist/lib/esm/src/core/ui/components/container/ResizableContainer.js.map +1 -0
  58. package/dist/lib/esm/src/core/ui/components/container/layoutBox.module.scss.js +2 -0
  59. package/dist/lib/esm/src/core/ui/components/container/layoutBox.module.scss.js.map +1 -0
  60. package/dist/lib/esm/src/core/ui/components/dividers/DividerLine.js +2 -0
  61. package/dist/lib/esm/src/core/ui/components/dividers/DividerLine.js.map +1 -0
  62. package/dist/lib/esm/src/core/ui/components/dividers/divider.module.scss.js +2 -0
  63. package/dist/lib/esm/src/core/ui/components/dividers/divider.module.scss.js.map +1 -0
  64. package/dist/lib/esm/src/core/ui/components/field/Field.js +2 -0
  65. package/dist/lib/esm/src/core/ui/components/field/Field.js.map +1 -0
  66. package/dist/lib/esm/src/core/ui/components/icon/Icon.js +2 -0
  67. package/dist/lib/esm/src/core/ui/components/icon/Icon.js.map +1 -0
  68. package/dist/lib/esm/src/core/ui/components/icon/IconBase.js +2 -0
  69. package/dist/lib/esm/src/core/ui/components/icon/IconBase.js.map +1 -0
  70. package/dist/lib/esm/src/core/ui/components/icon/IconWC.js +2 -0
  71. package/dist/lib/esm/src/core/ui/components/icon/IconWC.js.map +1 -0
  72. package/dist/lib/esm/src/core/ui/components/icon/icon.module.scss.js +2 -0
  73. package/dist/lib/esm/src/core/ui/components/icon/icon.module.scss.js.map +1 -0
  74. package/dist/lib/esm/src/core/ui/utils/style.js +2 -0
  75. package/dist/lib/esm/src/core/ui/utils/style.js.map +1 -0
  76. package/dist/lib/esm/src/index.js +1 -1
  77. package/dist/lib/src/core/index.js +1 -0
  78. package/dist/lib/src/core/index.js.map +1 -1
  79. package/dist/lib/tsconfig.tsbuildinfo +1 -1
  80. package/dist/types/src/core/index.d.ts +1 -0
  81. package/dist/types/src/core/index.d.ts.map +1 -1
  82. package/dist/utils/esm/index.css +106 -0
  83. package/dist/utils/index.css +106 -0
  84. package/package.json +1 -1
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Field.js","sources":["../../../../../../../../src/core/ui/components/field/Field.tsx"],"sourcesContent":["/* eslint-disable react/jsx-props-no-spreading */\n/* eslint-disable jsx-a11y/no-static-element-interactions */\n/* eslint-disable jsx-a11y/click-events-have-key-events */\nimport { FC, ReactNode, memo, useMemo, useCallback, PropsWithChildren } from 'react'\nimport styled from 'styled-components'\n\nimport type { FieldError, IconComponentType } from './types'\n\nlet iconColor: string | (() => string) = () => '#000000'\n\nexport const setIconColor = (color: string | (() => string)): void => {\n iconColor = color\n}\n\nlet IconComponent: IconComponentType = memo(function IconComponent() { return <span /> })\n\nexport const setIconComponent = (component: IconComponentType): void => {\n IconComponent = component\n}\n\nexport type FileWrapperProps = PropsWithChildren<unknown> & {\n className?: string\n error?: boolean\n disabled?: boolean\n userDisabled?: boolean\n css?: string\n}\n\nexport const FieldWrapper: FC<FileWrapperProps> = styled.div<FileWrapperProps>`\n opacity: ${({ disabled, userDisabled }) => (disabled || userDisabled ? 0.5 : 1)};\n pointer-events: ${({ disabled, userDisabled }) => (disabled || userDisabled ? 'none' : 'auto')};\n flex: 1 1 auto;\n width: 100%;\n @media (min-width: 400px) {\n flex: 1;\n }\n .label {\n font-size: 0.8rem !important;\n font-weight: normal;\n }\n\n .help {\n text-align: left;\n }\n\n .mainControl {\n flex: 1;\n border-radius: 6px;\n box-shadow: 0 0 6px 1px rgba(0, 0, 0, 0.06);\n will-change: box-shadow;\n transition: box-shadow 250ms ease-in-out;\n &:hover {\n box-shadow: 0 0 8px 2px rgba(0, 0, 0, 0.1);\n }\n }\n button {\n box-shadow: 0 0 8px 2px rgba(0, 0, 0, 0.1);\n }\n .select {\n width: 100%;\n flex: 1;\n &::after {\n border-color: #000000 !important;\n }\n }\n\n .icon {\n &.is-action {\n cursor: pointer;\n pointer-events: initial !important;\n }\n }\n\n /* Chrome, Safari, Edge, Opera */\n input::-webkit-outer-spin-button,\n input::-webkit-inner-spin-button {\n -webkit-appearance: none;\n margin: 0;\n }\n\n /* Firefox */\n input[type=number] {\n -moz-appearance: textfield;\n }\n\n .input[type=date]::-webkit-calendar-picker-indicator {\n opacity:0;\n -webkit-appearance: none;\n position: absolute;\n left: 0;\n top: 0;\n width: 40px;\n height: 100%;\n margin: 0;\n padding: 0;\n cursor: pointer;\n }\n\n textarea {\n resize: none;\n }\n`\n\ntype EventType = { target: any; type?: any } & Partial<Event>\nexport interface FieldProps {\n label?: string\n name?: string\n type?: string\n min?: number | string | Date | any\n max?: number | string | Date | any\n value?: string | number | readonly string[] | undefined\n defaultValue?: string | number | readonly string[] | undefined\n placeholder?: string\n inputRef?: ReactHookFormRef\n error?: boolean\n errors?: FieldError\n disabled?: boolean\n userDisabled?: boolean\n helpTextInfo?: string\n helpText?: string\n iconLeft?: string\n iconRight?: string\n withoutComponent?: boolean\n addon?: ReactNode\n children?: ReactNode\n className?: string\n onChange?: (event?: EventType) => unknown\n // TODO, rename... something like changeHandler or valueDecorator\n onChangeInner?: (value: string | number) => string | number\n onBlur?: (event?: EventType) => void\n onFocus?: (event?: EventType | undefined) => void\n rightIconClick?: (event?: EventType) => void\n leftIconClick?: (event?: EventType) => void\n options?: any[] | null\n creatable?: boolean\n async?: boolean\n css?: string\n [key: string]: any\n}\n\ninterface SelectProps extends FieldProps {\n id?: string\n}\n\ntype OptionObj = { label: string | number | undefined; value: string | number | undefined }\ntype Option = OptionObj | string | number\n\nexport const Select: FC<SelectProps>\n= memo<SelectProps>(\n function Select({ options, value, inputRef, ...props }: SelectProps) {\n return (\n <div className='select'>\n <select {...props} ref={inputRef} defaultValue={value}>\n {options?.map((option: Option) => (\n <option\n key={`${JSON.stringify(option)}`}\n value={typeof option === 'object' ? (option as OptionObj)?.value : option}\n >\n {typeof option === 'object' ? (option as OptionObj)?.label : option}\n </option>\n ))}\n </select>\n </div>\n )\n },\n)\n\nconst InputComponent = styled.input``\nconst TextAreaComponent = styled.textarea``\nconst StyledFieldLabel = styled.label`\n text-align: left;\n`\n\nexport const Field: FC<FieldProps> = memo<FieldProps>(({\n label,\n name,\n type = 'text',\n value,\n defaultValue,\n placeholder,\n inputRef,\n error,\n disabled,\n userDisabled,\n withoutComponent,\n helpTextInfo,\n helpText,\n children,\n iconLeft,\n iconRight,\n addon,\n className,\n onChange,\n onChangeInner,\n onBlur,\n onFocus,\n rightIconClick,\n leftIconClick,\n options,\n css,\n ...props\n}: FieldProps) => {\n let Component: FC<any> = InputComponent\n\n if (!children && type === 'textarea') {\n Component = TextAreaComponent\n }\n const handleFocus = useCallback((event: Event | EventType | undefined) => {\n if (userDisabled) {\n event?.preventDefault?.()\n } else {\n onFocus && onFocus(event)\n }\n }, [userDisabled, onFocus])\n\n const handleChange = useCallback((event: { target: { value: string } }) => {\n if (userDisabled) {\n return\n }\n if (onChangeInner && event?.target) {\n // eslint-disable-next-line no-param-reassign\n event.target.value = onChangeInner((event.target.value as string)) as string\n onChange && onChange(event as EventType)\n } else {\n onChange && onChange(event as EventType)\n }\n }, [onChangeInner, onChange, userDisabled])\n\n const valueProps = useMemo(() => {\n if (value === undefined) {\n return { defaultValue }\n }\n return { value }\n }, [value, defaultValue])\n\n return (\n <FieldWrapper\n className={`field ${className}`}\n error={error}\n disabled={disabled}\n userDisabled={userDisabled}\n css={css}\n >\n <StyledFieldLabel htmlFor={name} className='label'>{label}</StyledFieldLabel>\n <div className={`field ${addon ? 'has-addons' : ''}`}>\n <div\n className={`control mainControl ${iconLeft && !withoutComponent\n ? 'has-icons-left' : ''} ${iconRight ? 'has-icons-right' : ''}`}\n >\n {!withoutComponent && ((!children && (type === 'select' || options))\n ? (\n <Select\n name={name}\n id={name}\n inputRef={inputRef}\n className={`input ${error ? 'is-danger' : ''}`}\n type='select'\n placeholder={placeholder}\n value={value}\n options={options}\n // TODO also handle change but value versus event.target.value issue\n onChange={onChange}\n onBlur={onBlur}\n onFocus={handleFocus}\n onKeyDown={handleFocus}\n autoComplete='off'\n disabled={disabled}\n {...props}\n />\n )\n : (\n !children && <Component\n name={name}\n id={name}\n ref={inputRef}\n className={`input ${error ? 'is-danger' : ''}`}\n type={type}\n placeholder={placeholder}\n {...valueProps}\n onChange={handleChange}\n onBlur={onBlur}\n onFocus={handleFocus}\n onKeyDown={handleFocus}\n autoComplete='off'\n disabled={disabled}\n {...props}\n />))}\n\n {iconLeft && !withoutComponent && (\n <span\n className={`iconLeft icon is-small is-left ${leftIconClick ? 'is-action' : ''}`}\n onClick={leftIconClick}\n >\n <IconComponent\n iconName={iconLeft}\n color={iconColor}\n />\n </span>\n )}\n {iconRight && (\n <span\n className={`iconRight icon is-small is-right ${rightIconClick ? 'is-action' : ''}`}\n onClick={rightIconClick}\n >\n <IconComponent\n iconName={iconRight}\n color={iconColor}\n />\n </span>\n )}\n {children && children}\n </div>\n {addon && addon}\n </div>\n {helpTextInfo && <p className='help'>{helpTextInfo}</p>}\n {helpText && <p className={`help ${error ? 'is-danger' : ''}`}>{helpText}</p>}\n </FieldWrapper>\n )\n})\n\nField.displayName = 'Field'\n"],"names":["iconColor","IconComponent","memo","React","createElement","FieldWrapper","styled","div","withConfig","displayName","componentId","_ref","disabled","userDisabled","_ref2","_StyledFieldWrapper","p","$_css","Select","_ref3","options","value","inputRef","props","_objectWithoutProperties","objectWithoutProperties","_excluded","className","_extends","ref","defaultValue","map","option","key","concat","JSON","stringify","_typeof","label","InputComponent","input","TextAreaComponent","textarea","StyledFieldLabel","Field","_ref4","name","_ref4$type","type","placeholder","error","withoutComponent","helpTextInfo","helpText","children","iconLeft","iconRight","addon","onChange","onChangeInner","onBlur","onFocus","rightIconClick","leftIconClick","css","_excluded2","Component","handleFocus","useCallback","event","_event$preventDefault","preventDefault","call","handleChange","target","valueProps","useMemo","undefined","htmlFor","id","onKeyDown","autoComplete","onClick","iconName","color","component"],"mappings":"mvBAQIA,EAAqC,WAAA,MAAM,SAAS,EAMpDC,EAAmCC,EAAAA,MAAK,WAA2B,OAAOC,MAAAC,cAAA,OAAA,KAAS,IAc1EC,EAAqCC,EAAAA,QAAOC,IAAGC,WAAA,CAAAC,YAAA,sBAAAC,YAAA,eAAVJ,CAAU,CAAA,WAAA,mBAAA,61BAC/C,SAAAK,GAAA,IAAGC,EAAQD,EAARC,SAAUC,EAAYF,EAAZE,aAAY,OAAQD,GAAYC,EAAe,GAAM,CAAC,IAC5D,SAAAC,GAAA,IAAGF,EAAQE,EAARF,SAAUC,EAAYC,EAAZD,aAAY,OAAQD,GAAYC,EAAe,OAAS,MAAM,IAuE9FE,EAAAT,EAAA,QAAAD,GAAAG,WAAA,CAAAC,YAAA,6BAAAC,YAAA,eAAAJ,CAAA,CAAA,GAAA,KAAA,SAAAU,GAAA,OAAAA,EAAAC,KAAA,IA8CYC,EACXhB,EAAIA,MACJ,SAAeiB,GAAsD,IAAnDC,EAAOD,EAAPC,QAASC,EAAKF,EAALE,MAAOC,EAAQH,EAARG,SAAaC,EAAKC,EAAAC,wBAAAN,EAAAO,GAClD,OACEvB,MAAAC,cAAA,MAAA,CAAKuB,UAAU,UACbxB,MAAAC,cAAAwB,SAAAA,EAAAA,WAAYL,EAAK,CAAEM,IAAKP,EAAUQ,aAAcT,IAC7CD,aAAO,EAAPA,EAASW,KAAI,SAACC,GAAc,OAC3B7B,MAAAC,cAAA,SAAA,CACE6B,IAAG,GAAAC,OAAKC,KAAKC,UAAUJ,IACvBX,MAAyB,WAAlBgB,EAAAA,OAAOL,GAAuBA,aAAM,EAANA,EAAsBX,MAAQW,GAEhD,WAAlBK,EAAA,OAAOL,GAAuBA,eAAAA,EAAsBM,MAA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gC,IAAaJ,GACZhD,MAAAC,cAAA,OAAA,CACEuB,UAAS,kCAAAO,OAAoC6B,EAAgB,YAAc,IAC3EmB,QAASnB,GAET5D,MAAAC,cAACH,EAAa,CACZkF,SAAU5B,EACV6B,MAAOpF,KAIZwD,GACCrD,MAAAC,cAAA,OAAA,CACEuB,UAAS,oCAAAO,OAAsC4B,EAAiB,YAAc,IAC9EoB,QAASpB,GAET3D,MAAAC,cAACH,EAAa,CACZkF,SAAU3B,EACV4B,MAAOpF,KAIZsD,GAAYA,GAEdG,GAASA,GAEXL,GAAgBjD,MAAAC,cAAA,IAAA,CAAGuB,UAAU,QAAQyB,GACrCC,GAAYlD,MAAAC,cAAA,IAAA,CAAGuB,kBAASO,OAAUgB,EAAQ,YAAc,KAAOG,GAGtE,IAEAT,EAAMnC,YAAc,qFAtTQ,SAAC2E,GAC3BpF,EAAYoF,CACd,2BAIgC,SAACC,GAC/BpF,EAAgBoF,CAClB"}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),require("../../../../../node_modules/core-js/modules/es.array.concat.js");var e=require("react").memo((function(e){var a=e.icon,c=e.className,o=e.color,r=void 0===o?"currentColor":o;return React.createElement("svg",{"aria-hidden":"true",focusable:"false","data-prefix":a.prefix,"data-icon":a.iconName,className:"svg-inline--fa fa-".concat(a.iconName," ").concat(c),role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 ".concat(a.icon[0]," ").concat(a.icon[1])},React.createElement("path",{fill:r,d:a.icon[4]}))}));e.displayName="Icon",exports.Icon=e;
2
+ //# sourceMappingURL=Icon.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Icon.js","sources":["../../../../../../../../src/core/ui/components/icon/Icon.tsx"],"sourcesContent":["import { memo } from 'react'\n\ntype IconType = {\n icon: {\n prefix: string\n iconName: string\n icon: any[]\n }\n className?: string\n color?: string\n}\n\nexport const Icon = memo<IconType>(({ icon, className, color = 'currentColor' }: IconType) => (\n <svg\n aria-hidden='true'\n focusable='false'\n data-prefix={icon.prefix}\n data-icon={icon.iconName}\n className={`svg-inline--fa fa-${icon.iconName} ${className}`}\n role='img'\n xmlns='http://www.w3.org/2000/svg'\n viewBox={`0 0 ${icon.icon[0]} ${icon.icon[1]}`}\n >\n <path\n fill={color}\n d={icon.icon[4]}\n />\n </svg>\n))\n\nIcon.displayName = 'Icon'\n"],"names":["Icon","memo","_ref","icon","className","_ref$color","color","React","createElement","focusable","prefix","iconName","concat","role","xmlns","viewBox","fill","d","displayName"],"mappings":"kJAYaA,mBAAOC,MAAe,SAAAC,GAAA,IAAGC,EAAID,EAAJC,KAAMC,EAASF,EAATE,UAASC,EAAAH,EAAEI,MAAAA,OAAQ,IAAHD,EAAG,eAAcA,EAAA,OAC3EE,MAAAC,cAAA,MAAA,CACE,cAAY,OACZC,UAAU,QACV,cAAaN,EAAKO,OAClB,YAAWP,EAAKQ,SAChBP,UAAS,qBAAAQ,OAAuBT,EAAKQ,SAAQC,KAAAA,OAAIR,GACjDS,KAAK,MACLC,MAAM,6BACNC,eAAOH,OAAST,EAAKA,KAAK,GAAE,KAAAS,OAAIT,EAAKA,KAAK,KAE1CI,MAAAC,cAAA,OAAA,CACEQ,KAAMV,EACNW,EAAGd,EAAKA,KAAK,KAEX,IAGRH,EAAKkB,YAAc"}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../../../../_virtual/_rollupPluginBabelHelpers.js");require("../../../../../node_modules/core-js/modules/es.array.concat.js");var o=require("react"),t=require("./icon.module.scss.js"),r=["iconUrl","minWidth","minHeight","size","fontSize","width","height","color","className","children","style"],i=o.memo((function(i){var c=i.iconUrl,n=i.minWidth,s=i.minHeight,a=i.size,l=i.fontSize,u=i.width,d=i.height,h=i.color,m=void 0===h?"currentColor":h,p=i.className,j=void 0===p?"":p,b=i.children,f=i.style,g=e.objectWithoutProperties(i,r),v=o.useMemo((function(){return e.objectSpread2(e.objectSpread2(e.objectSpread2(e.objectSpread2({"--min-width":n||a||u||"auto","--min-height":s||a||d||"auto","--width":a||u||"1rem","--height":a||d||"1rem"},l?{fontSize:l}:{}),c?{"--icon-url":"url(".concat(c,")")}:{}),c?{"--icon-color":m}:{"--icon-content-color":m}),f)}),[n,a,u,s,d,l,c,m,f]);return React.createElement("span",e.extends({},g,{className:"".concat(t.default["icon-base"]," icon-base ").concat(j),style:v}),!c&&b&&b)}));i.displayName="IconBase",exports.IconBase=i;
2
+ //# sourceMappingURL=IconBase.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"IconBase.js","sources":["../../../../../../../../src/core/ui/components/icon/IconBase.tsx"],"sourcesContent":["import { CSSProperties, memo, useMemo, FC, PropsWithChildren } from 'react'\n\nimport classes from './icon.module.scss'\n\nexport type IconBaseType = PropsWithChildren<unknown> & {\n id?: string\n iconUrl?: string\n minWidth?: string\n minHeight?: string\n width?: string\n height?: string\n size?: string\n fontSize?: string\n color?: string\n className?: string\n style?: CSSProperties\n}\n\nexport const IconBase: FC<IconBaseType> = memo<IconBaseType>(({\n iconUrl, minWidth, minHeight, size,\n fontSize, width, height, color = 'currentColor', className = '', children, style, ...props\n}: IconBaseType) => {\n const styles = useMemo(() => (\n {\n '--min-width': minWidth || size || width || 'auto',\n '--min-height': minHeight || size || height || 'auto',\n '--width': size || width || '1rem',\n '--height': size || height || '1rem',\n ...(fontSize ? { fontSize } : {}),\n ...(iconUrl ? { '--icon-url': `url(${iconUrl})` } : {}),\n ...(iconUrl ? { '--icon-color': color } : { '--icon-content-color': color }),\n ...style,\n }\n ), [minWidth, size, width, minHeight, height, fontSize, iconUrl, color, style])\n\n return (\n <span\n {...props}\n className={`${classes['icon-base']} icon-base ${className}`}\n style={styles as CSSProperties}\n >\n {(!iconUrl && children) && children}\n </span>\n )\n})\n\nIconBase.displayName = 'IconBase'\n"],"names":["IconBase","memo","_ref","iconUrl","minWidth","minHeight","size","fontSize","width","height","_ref$color","color","_ref$className","className","children","style","props","_objectWithoutProperties","objectWithoutProperties","_excluded","styles","useMemo","_objectSpread","objectSpread2","concat","React","createElement","_extends","classes","displayName"],"mappings":"6XAkBaA,EAA6BC,EAAAA,MAAmB,SAAAC,GAGzC,IAFlBC,EAAOD,EAAPC,QAASC,EAAQF,EAARE,SAAUC,EAASH,EAATG,UAAWC,EAAIJ,EAAJI,KAC9BC,EAAQL,EAARK,SAAUC,EAAKN,EAALM,MAAOC,EAAMP,EAANO,OAAMC,EAAAR,EAAES,MAAAA,OAAQ,IAAHD,EAAG,eAAcA,EAAAE,EAAAV,EAAEW,UAAAA,OAAY,IAAHD,EAAG,GAAEA,EAAEE,EAAQZ,EAARY,SAAUC,EAAKb,EAALa,MAAUC,EAAKC,EAAAC,wBAAAhB,EAAAiB,GAEpFC,EAASC,EAAAA,SAAQ,WAAA,OAAAC,gBAAAA,EAAAA,cAAAA,EAAAC,cAAAD,gBAAA,CAEnB,cAAelB,GAAYE,GAAQE,GAAS,OAC5C,eAAgBH,GAAaC,GAAQG,GAAU,OAC/C,UAAWH,GAAQE,GAAS,OAC5B,WAAYF,GAAQG,GAAU,QAC1BF,EAAW,CAAEA,SAAAA,GAAa,CAAA,GAC1BJ,EAAU,CAAE,aAAY,OAAAqB,OAASrB,EAAO,MAAQ,CAAA,GAChDA,EAAU,CAAE,eAAgBQ,GAAU,CAAE,uBAAwBA,IACjEI,EAEN,GAAE,CAACX,EAAUE,EAAME,EAAOH,EAAWI,EAAQF,EAAUJ,EAASQ,EAAOI,IAExE,OACEU,MAAAC,cAAAC,OAAAA,EAAAA,WACMX,EAAK,CACTH,UAAS,GAAAW,OAAKI,EAAO,QAAC,aAAYJ,eAAAA,OAAcX,GAChDE,MAAOK,KAEJjB,GAAWW,GAAaA,EAGjC,IAEAd,EAAS6B,YAAc"}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../../../../_virtual/_rollupPluginBabelHelpers.js");require("../../../../../node_modules/core-js/modules/es.array.concat.js"),require("../../../../../node_modules/core-js/modules/es.array.map.js"),require("../../../../../node_modules/core-js/modules/es.object.entries.js");var t,i=require("../../../utils/webComponents/webComponent.utils.js"),n=require("./icon.module.scss.js"),o=document.createElement("template");o.innerHTML='<span class="icon-base"></span>';var r=i.ced("icon-base")(t=function(t){e.inherits(s,t);var r=e.createSuper(s);function s(){var t;e.classCallCheck(this,s);for(var i=arguments.length,o=new Array(i),c=0;c<i;c++)o[c]=arguments[c];return(t=r.call.apply(r,[this].concat(o))).content=void 0,t.mainElement=void 0,t.iconUrl=void 0,t.minWidth=void 0,t.minHeight=void 0,t.width=void 0,t.height=void 0,t.size=void 0,t.fontSize=void 0,t.color=void 0,t.render=function(){if(t.mainElement=t.mainElement||t.querySelector(".icon-base"),t.mainElement){t.classList.add(n.default["icon-base-parent"]),t.mainElement.classList.add(n.default["icon-base"]);var i=e.objectSpread2(e.objectSpread2(e.objectSpread2({"--min-width":t.minWidth||t.size||t.width||"auto","--min-height":t.minHeight||t.size||t.height||"auto","--width":t.size||t.width||"1rem","--height":t.size||t.height||"1rem"},t.fontSize?{"font-size":t.fontSize||"unset"}:{}),t.iconUrl?{"--icon-url":"url(".concat(t.iconUrl,")")}:{}),t.iconUrl?{"--icon-color":t.color}:{"--icon-content-color":t.color});t.mainElement.innerHTML=t.iconUrl?"":t.content||"",t.mainElement.setAttribute("style",Object.entries(i).map((function(t){var i=e.slicedToArray(t,2),n=i[0],o=i[1];return"".concat(n,": ").concat(o,";")})).join(" "))}},t}return e.createClass(s,[{key:"connectedCallback",value:function(){(this.content||this.innerHTML)&&(this.content=this.content||this.innerHTML||this.getAttribute("content")),this.innerHTML=o.innerHTML,i.resolveAttributes(this,s.observedAttributes),this.render()}},{key:"attributeChangedCallback",value:function(e,t,i){"className"!==e&&"classname"!==e&&"class"!==e||"string"==typeof i&&(this.classList.remove(i),this.classList.add(i)),this.color||(this.color="currentColor"),this[e]=i||"",this.render()}}],[{key:"observedAttributes",get:function(){return["iconUrl","minWidth","minHeight","width","height","size","fontSize","color","className"]}}]),s}(e.wrapNativeSuper(HTMLElement)))||t,s={VCIconBase:r};exports.VCIcon=r,exports.VCIconBase=s;
2
+ //# sourceMappingURL=IconWC.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"IconWC.js","sources":["../../../../../../../../src/core/ui/components/icon/IconWC.ts"],"sourcesContent":["import { ced, resolveAttributes } from '../../../utils/webComponents/webComponent.utils'\n\nimport classes from './icon.module.scss'\n\n\nconst template = document.createElement('template')\n\ntemplate.innerHTML = '<span class=\"icon-base\"></span>'\n\nexport type IconBaseWCType = {\n iconUrl?: string\n minWidth?: string\n minHeight?: string\n width?: string\n height?: string\n size?: string\n fontSize?: string\n color?: string\n className?: string\n}\n\n@ced('icon-base')\nexport class VCIcon extends HTMLElement {\n content: string | null\n\n mainElement: HTMLElement\n\n iconUrl?: string | null\n\n minWidth?: string | null\n\n minHeight?: string | null\n\n width?: string | null\n\n height?: string | null\n\n size?: string | null\n\n fontSize?: string | null\n\n color?: string | null\n\n static get observedAttributes() {\n return ['iconUrl', 'minWidth', 'minHeight', 'width', 'height', 'size', 'fontSize', 'color', 'className']\n }\n\n connectedCallback() {\n if (this.content || this.innerHTML) {\n this.content = this.content || this.innerHTML || this.getAttribute('content')\n }\n\n this.innerHTML = template.innerHTML\n\n resolveAttributes(this, VCIcon.observedAttributes)\n\n this.render()\n }\n\n attributeChangedCallback(attrName: string, oldVal: string | number | null, newVal: string | number | null) {\n if (attrName === 'className' || attrName === 'classname' || attrName === 'class') {\n if (typeof newVal === 'string') {\n this.classList.remove(newVal as string)\n this.classList.add(newVal as string)\n }\n }\n if (!this.color) {\n this.color = 'currentColor'\n }\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n this[attrName] = (newVal as string) || ''\n this.render()\n }\n\n render = () => {\n this.mainElement = this.mainElement || this.querySelector('.icon-base') as HTMLElement\n if (!this.mainElement) {\n return\n }\n this.classList.add(classes['icon-base-parent'])\n this.mainElement.classList.add(classes['icon-base'])\n\n const styles = {\n '--min-width': this.minWidth || this.size || this.width || 'auto',\n '--min-height': this.minHeight || this.size || this.height || 'auto',\n '--width': this.size || this.width || '1rem',\n '--height': this.size || this.height || '1rem',\n ...(this.fontSize ? { 'font-size': this.fontSize || 'unset' } : {}),\n ...(this.iconUrl ? { '--icon-url': `url(${this.iconUrl})` } : {}),\n ...(this.iconUrl ? { '--icon-color': this.color } : { '--icon-content-color': this.color }),\n }\n\n this.mainElement.innerHTML = this.iconUrl ? '' : (this.content || '')\n\n this.mainElement.setAttribute('style', Object.entries(styles).map(([key, value]) => `${key}: ${value};`).join(' '))\n }\n}\n\ndeclare global {\n // eslint-disable-next-line @typescript-eslint/no-namespace\n namespace JSX {\n interface IntrinsicElements {\n 'icon-base': any\n }\n }\n}\n\nexport const VCIconBase = {\n VCIconBase: VCIcon,\n}\n"],"names":["template","document","createElement","innerHTML","VCIcon","ced","_dec","_class","_HTMLElement","_inherits","_super","_createSuper","_this","_classCallCheck","_len","arguments","length","args","Array","_key","call","apply","this","concat","content","mainElement","iconUrl","minWidth","minHeight","width","height","size","fontSize","color","render","querySelector","classList","add","classes","styles","_objectSpread","objectSpread2","setAttribute","Object","entries","map","_ref","_ref2","_slicedToArray","key","value","join","_createClass","createClass","getAttribute","resolveAttributes","observedAttributes","attrName","oldVal","newVal","remove","get","_wrapNativeSuper","HTMLElement","VCIconBase"],"mappings":"gdAKMA,EAAWC,SAASC,cAAc,YAExCF,EAASG,UAAY,kCAcrB,IACaC,EADZC,MAAI,YAAYC,CAAAC,WAAAC,GAAAC,WAAAL,EAAAI,GAAA,IAAAE,EAAAC,cAAAP,GAAA,SAAAA,IAAA,IAAAQ,EAAAC,sBAAAT,GAAA,IAAA,IAAAU,EAAAC,UAAAC,OAAAC,EAAAC,IAAAA,MAAAJ,GAAAK,EAAA,EAAAA,EAAAL,EAAAK,IAAAF,EAAAE,GAAAJ,UAAAI,GA2Ed,OA3EcP,EAAAF,EAAAU,KAAAC,MA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AiBDvC,CAAA,CAnDA,OAmDAwC,EAAAC,YAAAjD,EAAA,CAAA,CAAA6C,IAAA,oBAAAC,MAjDD,YACM5B,KAAKE,SAAWF,KAAKnB,aACvBmB,KAAKE,QAAUF,KAAKE,SAAWF,KAAKnB,WAAamB,KAAKgC,aAAa,YAGrEhC,KAAKnB,UAAYH,EAASG,UAE1BoD,EAAAA,kBAAkBjC,KAAMlB,EAAOoD,oBAE/BlC,KAAKY,QACP,GAAC,CAAAe,IAAA,2BAAAC,MAED,SAAyBO,EAAkBC,EAAgCC,GACxD,cAAbF,GAAyC,cAAbA,GAAyC,UAAbA,GACpC,iBAAXE,IACTrC,KAAKc,UAAUwB,OAAOD,GACtBrC,KAAKc,UAAUC,IAAIsB,IAGlBrC,KAAKW,QACRX,KAAKW,MAAQ,gBAIfX,KAAKmC,GAAaE,GAAqB,GACvCrC,KAAKY,QACP,IAAC,CAAA,CAAAe,IAAA,qBAAAY,IA9BD,WACE,MAAO,CAAC,UAAW,WAAY,YAAa,QAAS,SAAU,OAAQ,WAAY,QAAS,YAC9F,KAACzD,CAAA,EAAA0D,kBAvByBC,gBAAWxD,EAsF1ByD,EAAa,CACxBA,WAAY5D"}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.default={"icon-base-parent":"icon-module_icon-base-parent__nOMvW","icon-base":"icon-module_icon-base__S0tHf"};
2
+ //# sourceMappingURL=icon.module.scss.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"icon.module.scss.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),require("../../../../node_modules/core-js/modules/es.array.concat.js"),require("../../../../node_modules/core-js/modules/es.object.to-string.js"),require("../../../../node_modules/core-js/modules/es.regexp.to-string.js"),require("../../../../node_modules/core-js/modules/es.string.pad-start.js"),require("../../../../node_modules/core-js/modules/es.regexp.exec.js"),require("../../../../node_modules/core-js/modules/es.string.replace.js"),require("../../../../node_modules/core-js/modules/es.parse-int.js"),require("../../../../node_modules/core-js/modules/es.array.index-of.js"),require("../../../../node_modules/core-js/modules/es.array.map.js"),exports.defaultFontSize=16;var e=function(e){return e/exports.defaultFontSize},r=function(e){return(e=e.toString(16)).padStart(2,"0")},t=function(e,t){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:.5;0===e.indexOf("#")&&(e=e.substr(1)),0===t.indexOf("#")&&(t=t.substr(1));var s=Math.ceil(parseInt(t.substring(0,2),16)*o+parseInt(e.substring(0,2),16)*(1-o)),n=Math.ceil(parseInt(t.substring(2,4),16)*o+parseInt(e.substring(2,4),16)*(1-o)),c=Math.ceil(parseInt(t.substring(4,6),16)*o+parseInt(e.substring(4,6),16)*(1-o));return"#".concat(r(s)+r(n)+r(c))};exports.calculateColors=function(e,r){for(var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10,s=o/(o+1)/o,n=[],c=s;o--;)n.push(c),c+=s;return n.map((function(o){return t(e,r,o)}))},exports.calculatePercColor=t,exports.convertHex=function(e,t){var o=arguments.length>2&&void 0!==arguments[2]&&arguments[2],s=e.replace("#",""),n=s.substring(0,2),c=s.substring(2,4),u=s.substring(4,6),a=parseInt(n,16),i=parseInt(c,16),d=parseInt(u,16),l=t<=1?t:t/100;return(o?"rgba(".concat(a,",").concat(i,",").concat(d,",").concat(l,")"):"#".concat(n).concat(c).concat(u).concat(r(Math.round(255*(t<=1?t:t/100))))).toLowerCase()},exports.convertRGB=function(e,t,o,s){return"#".concat(r(e)).concat(r(t)).concat(r(o)).concat(r(Math.round(255*(s<=1?s:s/100))))},exports.pxToRem=e,exports.resolveStyleValue=function(r){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"rem";return"string"==typeof r?r:"px"===t?"".concat(e(r),"rem"):"".concat(r).concat(t)},exports.setDefaultFontSize=function(e){exports.defaultFontSize=e},exports.toHex=r;
2
+ //# sourceMappingURL=style.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"style.js","sources":["../../../../../../../src/core/ui/utils/style.ts"],"sourcesContent":["// eslint-disable-next-line import/no-mutable-exports\nexport let defaultFontSize = 16\nexport const setDefaultFontSize = (fontSize: number) => {\n defaultFontSize = fontSize\n}\n\nexport const pxToRem = (px: number): number => px / defaultFontSize\n\nexport const resolveStyleValue = (\n value: string | number,\n units = 'rem',\n): string => {\n if (typeof value === 'string') {\n return value as string\n }\n\n if (units === 'px') {\n return `${pxToRem(value)}rem`\n }\n\n return `${value}${units}`\n}\n\n/* eslint-disable no-param-reassign */\nexport const toHex = (x: number | string): string => {\n x = x.toString(16)\n return x.padStart(2, '0')\n}\n\nexport const convertHex = (hex: string, opacity: number, rgba = false): string => {\n const hexValue = hex.replace('#', '')\n const rValue = hexValue.substring(0, 2)\n const gValue = hexValue.substring(2, 4)\n const bValue = hexValue.substring(4, 6)\n const r = parseInt(rValue, 16)\n const g = parseInt(gValue, 16)\n const b = parseInt(bValue, 16)\n\n const a = opacity <= 1 ? opacity : (opacity / 100)\n\n return (rgba\n ? `rgba(${r},${g},${b},${a})`\n : `#${rValue}${gValue}${bValue}${toHex(Math.round((opacity <= 1 ? opacity : (opacity / 100)) * 255))}`)\n .toLowerCase()\n}\n\nexport const convertRGB = (\n r: number, g: number, b: number, opacity: number,\n): string => `#${toHex(r)}${toHex(g)}${toHex(b)}${toHex(Math.round((opacity <= 1 ? opacity : (opacity / 100)) * 255))}`\n\nexport const calculatePercColor = (startColor: string, endColor: string, ratio = 0.5): string => {\n if (startColor.indexOf('#') === 0) {\n startColor = startColor.substr(1)\n }\n if (endColor.indexOf('#') === 0) {\n endColor = endColor.substr(1)\n }\n\n const r = Math.ceil(parseInt(endColor.substring(0, 2), 16) * ratio\n + parseInt(startColor.substring(0, 2), 16) * (1 - ratio))\n const g = Math.ceil(parseInt(endColor.substring(2, 4), 16) * ratio\n + parseInt(startColor.substring(2, 4), 16) * (1 - ratio))\n const b = Math.ceil(parseInt(endColor.substring(4, 6), 16) * ratio\n + parseInt(startColor.substring(4, 6), 16) * (1 - ratio))\n\n return `#${toHex(r) + toHex(g) + toHex(b)}`\n}\n\nexport const calculateColors = (startColor: string, endColor: string, num = 10): string[] => {\n const ratioIterator = (num / (num + 1)) / num\n const ratios = []\n let ratio = ratioIterator\n\n // eslint-disable-next-line no-plusplus\n while (num--) {\n ratios.push(ratio)\n ratio += ratioIterator\n }\n\n return ratios.map((rat) => calculatePercColor(startColor, endColor, rat))\n}\n"],"names":["defaultFontSize","pxToRem","px","toHex","x","toString","padStart","calculatePercColor","startColor","endColor","ratio","arguments","length","undefined","indexOf","substr","r","Math","ceil","parseInt","substring","g","b","concat","num","ratioIterator","ratios","push","map","rat","hex","opacity","rgba","hexValue","replace","rValue","gValue","bValue","a","round","toLowerCase","value","units","fontSize"],"mappings":"4sBACWA,QAAAA,gBAAkB,OAKhBC,EAAU,SAACC,GAAU,OAAaA,EAAKF,QAAAA,eAAe,EAkBtDG,EAAQ,SAACC,GAEpB,OADAA,EAAIA,EAAEC,SAAS,KACNC,SAAS,EAAG,IACvB,EAuBaC,EAAqB,SAACC,EAAoBC,GAA0C,IAAxBC,EAAKC,UAAAC,OAAA,QAAAC,IAAAF,UAAA,GAAAA,UAAA,GAAG,GAC/C,IAA5BH,EAAWM,QAAQ,OACrBN,EAAaA,EAAWO,OAAO,IAEH,IAA1BN,EAASK,QAAQ,OACnBL,EAAWA,EAASM,OAAO,IAG7B,IAAMC,EAAIC,KAAKC,KAAKC,SAASV,EAASW,UAAU,EAAG,GAAI,IAAMV,EACzDS,SAASX,EAAWY,UAAU,EAAG,GAAI,KAAO,EAAIV,IAC9CW,EAAIJ,KAAKC,KAAKC,SAASV,EAASW,UAAU,EAAG,GAAI,IAAMV,EACzDS,SAASX,EAAWY,UAAU,EAAG,GAAI,KAAO,EAAIV,IAC9CY,EAAIL,KAAKC,KAAKC,SAASV,EAASW,UAAU,EAAG,GAAI,IAAMV,EACzDS,SAASX,EAAWY,UAAU,EAAG,GA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AC,IAAAF,UAAA,GAAAA,UAAA,GAAG,MAER,MAAqB,iBAAV8B,EACFA,EAGK,OAAVC,EACF,GAAAnB,OAAUtB,EAAQwC,GAAM,OAG1B,GAAAlB,OAAUkB,GAAKlB,OAAGmB,EACpB,6BAnBkC,SAACC,GACjC3C,QAAAA,gBAAkB2C,CACpB"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./core/hooks/useApi.js"),r=require("./core/hooks/useToggle.js"),t=require("./core/hooks/useTranslations.js"),s=require("./core/hooks/useOutsideClick.js"),o=require("./core/hooks/useResize.js"),a=require("./core/hooks/useClassNames.js"),i=require("./core/hooks/useParseProps.js"),p=require("./core/utils/helpers/birthnumber.validator.js"),l=require("./core/utils/helpers/birthnumberCZSKvalidator.js"),u=require("./core/utils/helpers/fileValidator.js"),n=require("./core/utils/helpers/date.js"),c=require("./core/utils/helpers/deviceInfo.js"),x=require("./core/utils/helpers/emailMatcher.js"),m=require("./core/utils/helpers/file.js"),d=require("./core/utils/helpers/objectOperations.js"),T=require("./core/utils/helpers/other.js"),h=require("./core/utils/helpers/textValueOperations.js"),j=require("./core/utils/helpers/valueOperations.js"),S=require("./core/utils/helpers/cancelableDelayedFunction.js"),g=require("./core/utils/helpers/ui.js"),v=require("./core/utils/keyExtractor.js"),b=require("./core/utils/date.js"),C=require("./core/utils/webComponents/webComponent.utils.js"),q=require("./core/utils/appState/store/store.vanillajs.js"),f=require("./core/utils/appState/store/store.vanillajs.templates.js"),F=require("./core/utils/appState/store/useStore.react.js"),O=require("./core/constants/ui.constants.js");exports.useApi=e.useApi,exports.useToggle=r.useToggle,exports.createSafeT=t.createSafeT,exports.setUseTranslation=t.setUseTranslation,exports.useTranslations=t.useTranslations,exports.outsideClickHandler=s.outsideClickHandler,exports.useOutsideClick=s.useOutsideClick,exports.useResize=o.useResize,exports.useClassNames=a.useClassNames,exports.useParseProps=i.useParseProps,exports.isBirthNumberValid=p.isBirthNumberValid,exports.getMatch=l.getMatch,exports.isValidFormat=l.isValidFormat,exports.isValidModulo11=l.isValidModulo11,exports.parse=l.parse,exports.regex=l.regex,exports.parseCSVdata=u.parseCSVdata,exports.validateCSVFile=u.validateCSVFile,exports.validateCSVlines=u.validateCSVlines,exports.validateJSONFile=u.validateJSONFile,exports.validateLineCellTrimmed=u.validateLineCellTrimmed,exports.validateLineNumColumns=u.validateLineNumColumns,exports.validateSDFFile=u.validateSDFFile,exports.DATE_FORMAT=n.DATE_FORMAT,exports.formatDateToTimestamp=n.formatDateToTimestamp,exports.getDate=n.getDate,exports.getDeviceId=c.getDeviceId,exports.emailMatch=x.emailMatch,exports.emailMatcher=x.emailMatcher,exports.regexBuilder=x.regexBuilder,exports.cleanCsvLines=m.cleanCsvLines,exports.formatFilePath=m.formatFilePath,exports.arrayToObjectTree=d.arrayToObjectTree,exports.chunkArray=d.chunkArray,exports.duplicatesInArray=d.duplicatesInArray,exports.formatJsonString=d.formatJsonString,exports.formatObj=d.formatObj,exports.formatObj2=d.formatObj2,exports.debounce=T.debounce,exports.delay=T.delay,exports.memoize=T.memoize,exports.memoizeComplex=T.memoizeComplex,exports.memoizer=T.memoizer,exports.nestedTernary=T.nestedTernary,exports.escapeRegExp=h.escapeRegExp,exports.fileNameExt=h.fileNameExt,exports.findStringInText=h.findStringInText,exports.normalizeString=h.normalizeString,exports.removeWhitespaces=h.removeWhitespaces,exports.sanitizeId=h.sanitizeId,exports.sanitizePathId=h.sanitizePathId,exports.toLowerCase=h.toLowerCase,exports.toUpperCase=h.toUpperCase,exports.truncateText=h.truncateText,exports.Operation=j.Operation,exports.decrementValue=j.decrementValue,exports.incerementValue=j.incerementValue,exports.numberDefined=j.numberDefined,exports.numberOperation=j.numberOperation,exports.restrictNumberInLimits=j.restrictNumberInLimits,exports.setValue=j.setValue,exports.cancelableSetInterval=S.cancelableSetInterval,exports.cancelableSetTimeout=S.cancelableSetTimeout,exports.classNames=g.classNames,exports.mapSerReplacer=g.mapSerReplacer,exports.noop=g.noop,exports.parseProps=g.parseProps,exports.keyExtractor=v.keyExtractor,exports.keyExtractorFunction=v.keyExtractorFunction,exports.dateRangeFormat=b.dateRangeFormat,exports.getDateTime=b.getDateTime,exports.getTimeFromNow=b.getTimeFromNow,exports.getTimeFromNowOriginal=b.getTimeFromNowOriginal,exports.getTimeTo=b.getTimeTo,exports.ced=C.ced,exports.createResolveAttribute=C.createResolveAttribute,exports.customElementDefine=C.customElementDefine,exports.resolveAttributes=C.resolveAttributes,exports.createStore=q.createStore,exports.createDataStore=f.createDataStore,exports.useStore=F.useStore,exports.useStoreApi=F.useStoreApi,exports.EventName=O.EventName;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./core/hooks/useApi.js"),r=require("./core/hooks/useToggle.js"),t=require("./core/hooks/useTranslations.js"),o=require("./core/hooks/useOutsideClick.js"),s=require("./core/hooks/useResize.js"),i=require("./core/hooks/useClassNames.js"),a=require("./core/hooks/useParseProps.js"),l=require("./core/utils/helpers/birthnumber.validator.js"),p=require("./core/utils/helpers/birthnumberCZSKvalidator.js"),n=require("./core/utils/helpers/fileValidator.js"),c=require("./core/utils/helpers/date.js"),u=require("./core/utils/helpers/deviceInfo.js"),x=require("./core/utils/helpers/emailMatcher.js"),m=require("./core/utils/helpers/file.js"),d=require("./core/utils/helpers/objectOperations.js"),C=require("./core/utils/helpers/other.js"),j=require("./core/utils/helpers/textValueOperations.js"),S=require("./core/utils/helpers/valueOperations.js"),v=require("./core/utils/helpers/cancelableDelayedFunction.js"),T=require("./core/utils/helpers/ui.js"),h=require("./core/utils/keyExtractor.js"),b=require("./core/utils/date.js"),g=require("./core/utils/webComponents/webComponent.utils.js"),F=require("./core/utils/appState/store/store.vanillajs.js"),q=require("./core/utils/appState/store/store.vanillajs.templates.js"),f=require("./core/utils/appState/store/useStore.react.js"),I=require("./core/constants/ui.constants.js"),D=require("./core/ui/utils/style.js"),V=require("./core/ui/components/container/LayoutBox.js"),y=require("./core/ui/components/container/Flex.js"),z=require("./core/ui/components/container/Placeholder.js"),O=require("./core/ui/components/container/CollapsibleContainerS.js"),N=require("./core/ui/components/container/CollapsibleContainer.js"),R=require("./core/ui/components/container/ResizableContainer.js"),k=require("./core/ui/components/field/Field.js"),P=require("./core/ui/components/dividers/DividerLine.js"),A=require("./core/ui/components/icon/IconBase.js"),L=require("./core/ui/components/icon/Icon.js"),E=require("./core/ui/components/icon/IconWC.js");exports.useApi=e.useApi,exports.useToggle=r.useToggle,exports.createSafeT=t.createSafeT,exports.setUseTranslation=t.setUseTranslation,exports.useTranslations=t.useTranslations,exports.outsideClickHandler=o.outsideClickHandler,exports.useOutsideClick=o.useOutsideClick,exports.useResize=s.useResize,exports.useClassNames=i.useClassNames,exports.useParseProps=a.useParseProps,exports.isBirthNumberValid=l.isBirthNumberValid,exports.getMatch=p.getMatch,exports.isValidFormat=p.isValidFormat,exports.isValidModulo11=p.isValidModulo11,exports.parse=p.parse,exports.regex=p.regex,exports.parseCSVdata=n.parseCSVdata,exports.validateCSVFile=n.validateCSVFile,exports.validateCSVlines=n.validateCSVlines,exports.validateJSONFile=n.validateJSONFile,exports.validateLineCellTrimmed=n.validateLineCellTrimmed,exports.validateLineNumColumns=n.validateLineNumColumns,exports.validateSDFFile=n.validateSDFFile,exports.DATE_FORMAT=c.DATE_FORMAT,exports.formatDateToTimestamp=c.formatDateToTimestamp,exports.getDate=c.getDate,exports.getDeviceId=u.getDeviceId,exports.emailMatch=x.emailMatch,exports.emailMatcher=x.emailMatcher,exports.regexBuilder=x.regexBuilder,exports.cleanCsvLines=m.cleanCsvLines,exports.formatFilePath=m.formatFilePath,exports.arrayToObjectTree=d.arrayToObjectTree,exports.chunkArray=d.chunkArray,exports.duplicatesInArray=d.duplicatesInArray,exports.formatJsonString=d.formatJsonString,exports.formatObj=d.formatObj,exports.formatObj2=d.formatObj2,exports.debounce=C.debounce,exports.delay=C.delay,exports.memoize=C.memoize,exports.memoizeComplex=C.memoizeComplex,exports.memoizer=C.memoizer,exports.nestedTernary=C.nestedTernary,exports.escapeRegExp=j.escapeRegExp,exports.fileNameExt=j.fileNameExt,exports.findStringInText=j.findStringInText,exports.normalizeString=j.normalizeString,exports.removeWhitespaces=j.removeWhitespaces,exports.sanitizeId=j.sanitizeId,exports.sanitizePathId=j.sanitizePathId,exports.toLowerCase=j.toLowerCase,exports.toUpperCase=j.toUpperCase,exports.truncateText=j.truncateText,exports.Operation=S.Operation,exports.decrementValue=S.decrementValue,exports.incerementValue=S.incerementValue,exports.numberDefined=S.numberDefined,exports.numberOperation=S.numberOperation,exports.restrictNumberInLimits=S.restrictNumberInLimits,exports.setValue=S.setValue,exports.cancelableSetInterval=v.cancelableSetInterval,exports.cancelableSetTimeout=v.cancelableSetTimeout,exports.classNames=T.classNames,exports.mapSerReplacer=T.mapSerReplacer,exports.noop=T.noop,exports.parseProps=T.parseProps,exports.keyExtractor=h.keyExtractor,exports.keyExtractorFunction=h.keyExtractorFunction,exports.dateRangeFormat=b.dateRangeFormat,exports.getDateTime=b.getDateTime,exports.getTimeFromNow=b.getTimeFromNow,exports.getTimeFromNowOriginal=b.getTimeFromNowOriginal,exports.getTimeTo=b.getTimeTo,exports.ced=g.ced,exports.createResolveAttribute=g.createResolveAttribute,exports.customElementDefine=g.customElementDefine,exports.resolveAttributes=g.resolveAttributes,exports.createStore=F.createStore,exports.createDataStore=q.createDataStore,exports.useStore=f.useStore,exports.useStoreApi=f.useStoreApi,exports.EventName=I.EventName,exports.calculateColors=D.calculateColors,exports.calculatePercColor=D.calculatePercColor,exports.convertHex=D.convertHex,exports.convertRGB=D.convertRGB,Object.defineProperty(exports,"defaultFontSize",{enumerable:!0,get:function(){return D.defaultFontSize}}),exports.pxToRem=D.pxToRem,exports.resolveStyleValue=D.resolveStyleValue,exports.setDefaultFontSize=D.setDefaultFontSize,exports.toHex=D.toHex,exports.LayoutBox=V.LayoutBox,exports.Flex=y.Flex,exports.FlexTight=y.FlexTight,exports.FlexTightStyled=y.FlexTightStyled,exports.FlexWrapper=y.FlexWrapper,exports.Placeholder=z.Placeholder,exports.ContainerS=O.ContainerS,exports.CollapsibleContainer=N.CollapsibleContainer,exports.ResizableContainer=R.ResizableContainer,exports.Field=k.Field,exports.FieldWrapper=k.FieldWrapper,exports.Select=k.Select,exports.setIconColor=k.setIconColor,exports.setIconComponent=k.setIconComponent,exports.DividerHorizontal=P.DividerHorizontal,exports.DividerLine=P.DividerLine,exports.DividerVertical=P.DividerVertical,exports.IconBase=A.IconBase,exports.Icon=L.Icon,exports.VCIcon=E.VCIcon,exports.VCIconBase=E.VCIconBase;
2
2
  //# sourceMappingURL=index.js.map
@@ -1,2 +1,2 @@
1
- function t(t,r){var e=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=e){var n,o,i,a,u=[],c=!0,l=!1;try{if(i=(e=e.call(t)).next,0===r){if(Object(e)!==e)return;c=!1}else for(;!(c=(n=i.call(e)).done)&&(u.push(n.value),u.length!==r);c=!0);}catch(t){l=!0,o=t}finally{try{if(!c&&null!=e.return&&(a=e.return(),Object(a)!==a))return}finally{if(l)throw o}}return u}}function r(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);r&&(n=n.filter((function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable}))),e.push.apply(e,n)}return e}function e(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?r(Object(n),!0).forEach((function(r){u(t,r,n[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))}))}return t}function n(){n=function(){return t};var t={},r=Object.prototype,e=r.hasOwnProperty,o=Object.defineProperty||function(t,r,e){t[r]=e.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",u=i.asyncIterator||"@@asyncIterator",c=i.toStringTag||"@@toStringTag";function l(t,r,e){return Object.defineProperty(t,r,{value:e,enumerable:!0,configurable:!0,writable:!0}),t[r]}try{l({},"")}catch(t){l=function(t,r,e){return t[r]=e}}function f(t,r,e,n){var i=r&&r.prototype instanceof h?r:h,a=Object.create(i.prototype),u=new E(n||[]);return o(a,"_invoke",{value:j(t,e,u)}),a}function s(t,r,e){try{return{type:"normal",arg:t.call(r,e)}}catch(t){return{type:"throw",arg:t}}}t.wrap=f;var y={};function h(){}function p(){}function v(){}var d={};l(d,a,(function(){return this}));var m=Object.getPrototypeOf,b=m&&m(m(P([])));b&&b!==r&&e.call(b,a)&&(d=b);var g=v.prototype=h.prototype=Object.create(d);function w(t){["next","throw","return"].forEach((function(r){l(t,r,(function(t){return this._invoke(r,t)}))}))}function O(t,r){function n(o,i,a,u){var c=s(t[o],t,i);if("throw"!==c.type){var l=c.arg,f=l.value;return f&&"object"==typeof f&&e.call(f,"__await")?r.resolve(f.__await).then((function(t){n("next",t,a,u)}),(function(t){n("throw",t,a,u)})):r.resolve(f).then((function(t){l.value=t,a(l)}),(function(t){return n("throw",t,a,u)}))}u(c.arg)}var i;o(this,"_invoke",{value:function(t,e){function o(){return new r((function(r,o){n(t,e,r,o)}))}return i=i?i.then(o,o):o()}})}function j(t,r,e){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return A()}for(e.method=o,e.arg=i;;){var a=e.delegate;if(a){var u=x(a,e);if(u){if(u===y)continue;return u}}if("next"===e.method)e.sent=e._sent=e.arg;else if("throw"===e.method){if("suspendedStart"===n)throw n="completed",e.arg;e.dispatchException(e.arg)}else"return"===e.method&&e.abrupt("return",e.arg);n="executing";var c=s(t,r,e);if("normal"===c.type){if(n=e.done?"completed":"suspendedYield",c.arg===y)continue;return{value:c.arg,done:e.done}}"throw"===c.type&&(n="completed",e.method="throw",e.arg=c.arg)}}}function x(t,r){var e=r.method,n=t.iterator[e];if(void 0===n)return r.delegate=null,"throw"===e&&t.iterator.return&&(r.method="return",r.arg=void 0,x(t,r),"throw"===r.method)||"return"!==e&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+e+"' method")),y;var o=s(n,t.iterator,r.arg);if("throw"===o.type)return r.method="throw",r.arg=o.arg,r.delegate=null,y;var i=o.arg;return i?i.done?(r[t.resultName]=i.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=void 0),r.delegate=null,y):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y)}function S(t){var r={tryLoc:t[0]};1 in t&&(r.catchLoc=t[1]),2 in t&&(r.finallyLoc=t[2],r.afterLoc=t[3]),this.tryEntries.push(r)}function L(t){var r=t.completion||{};r.type="normal",delete r.arg,t.completion=r}function E(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(S,this),this.reset(!0)}function P(t){if(t){var r=t[a];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function r(){for(;++n<t.length;)if(e.call(t,n))return r.value=t[n],r.done=!1,r;return r.value=void 0,r.done=!0,r};return o.next=o}}return{next:A}}function A(){return{value:void 0,done:!0}}return p.prototype=v,o(g,"constructor",{value:v,configurable:!0}),o(v,"constructor",{value:p,configurable:!0}),p.displayName=l(v,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var r="function"==typeof t&&t.constructor;return!!r&&(r===p||"GeneratorFunction"===(r.displayName||r.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,v):(t.__proto__=v,l(t,c,"GeneratorFunction")),t.prototype=Object.create(g),t},t.awrap=function(t){return{__await:t}},w(O.prototype),l(O.prototype,u,(function(){return this})),t.AsyncIterator=O,t.async=function(r,e,n,o,i){void 0===i&&(i=Promise);var a=new O(f(r,e,n,o),i);return t.isGeneratorFunction(e)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(g),l(g,c,"Generator"),l(g,a,(function(){return this})),l(g,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var r=Object(t),e=[];for(var n in r)e.push(n);return e.reverse(),function t(){for(;e.length;){var n=e.pop();if(n in r)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=P,E.prototype={constructor:E,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(L),!t)for(var r in this)"t"===r.charAt(0)&&e.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function n(e,n){return a.type="throw",a.arg=t,r.next=e,n&&(r.method="next",r.arg=void 0),!!n}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var u=e.call(i,"catchLoc"),c=e.call(i,"finallyLoc");if(u&&c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(u){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,r){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&e.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=r&&r<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=r,i?(this.method="next",this.next=i.finallyLoc,y):this.complete(a)},complete:function(t,r){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&r&&(this.next=r),y},finish:function(t){for(var r=this.tryEntries.length-1;r>=0;--r){var e=this.tryEntries[r];if(e.finallyLoc===t)return this.complete(e.completion,e.afterLoc),L(e),y}},catch:function(t){for(var r=this.tryEntries.length-1;r>=0;--r){var e=this.tryEntries[r];if(e.tryLoc===t){var n=e.completion;if("throw"===n.type){var o=n.arg;L(e)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,r,e){return this.delegate={iterator:P(t),resultName:r,nextLoc:e},"next"===this.method&&(this.arg=void 0),y}},t}function o(t){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},o(t)}function i(t,r,e,n,o,i,a){try{var u=t[i](a),c=u.value}catch(t){return void e(t)}u.done?r(c):Promise.resolve(c).then(n,o)}function a(t){return function(){var r=this,e=arguments;return new Promise((function(n,o){var a=t.apply(r,e);function u(t){i(a,n,o,u,c,"next",t)}function c(t){i(a,n,o,u,c,"throw",t)}u(void 0)}))}}function u(t,r,e){return(r=O(r))in t?Object.defineProperty(t,r,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[r]=e,t}function c(t,r){if(null==t)return{};var e,n,o={},i=Object.keys(t);for(n=0;n<i.length;n++)e=i[n],r.indexOf(e)>=0||(o[e]=t[e]);return o}function l(t,r){if(null==t)return{};var e,n,o=c(t,r);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);for(n=0;n<i.length;n++)e=i[n],r.indexOf(e)>=0||Object.prototype.propertyIsEnumerable.call(t,e)&&(o[e]=t[e])}return o}function f(r,e){return h(r)||t(r,e)||v(r,e)||b()}function s(t){return y(t)||p(t)||v(t)||m()}function y(t){if(Array.isArray(t))return d(t)}function h(t){if(Array.isArray(t))return t}function p(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function v(t,r){if(t){if("string"==typeof t)return d(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);return"Object"===e&&t.constructor&&(e=t.constructor.name),"Map"===e||"Set"===e?Array.from(t):"Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?d(t,r):void 0}}function d(t,r){(null==r||r>t.length)&&(r=t.length);for(var e=0,n=new Array(r);e<r;e++)n[e]=t[e];return n}function m(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function b(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function g(t,r){var e="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=v(t))||r&&t&&"number"==typeof t.length){e&&(t=e);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){e=e.call(t)},n:function(){var t=e.next();return a=t.done,t},e:function(t){u=!0,i=t},f:function(){try{a||null==e.return||e.return()}finally{if(u)throw i}}}}function w(t,r){if("object"!=typeof t||null===t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,r||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===r?String:Number)(t)}function O(t){var r=w(t,"string");return"symbol"==typeof r?r:String(r)}export{d as arrayLikeToArray,h as arrayWithHoles,y as arrayWithoutHoles,a as asyncToGenerator,g as createForOfIteratorHelper,u as defineProperty,p as iterableToArray,t as iterableToArrayLimit,b as nonIterableRest,m as nonIterableSpread,e as objectSpread2,l as objectWithoutProperties,c as objectWithoutPropertiesLoose,n as regeneratorRuntime,f as slicedToArray,s as toConsumableArray,w as toPrimitive,O as toPropertyKey,o as typeof,v as unsupportedIterableToArray};
1
+ function t(t,r){var e=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=e){var n,o,i,a,u=[],c=!0,f=!1;try{if(i=(e=e.call(t)).next,0===r){if(Object(e)!==e)return;c=!1}else for(;!(c=(n=i.call(e)).done)&&(u.push(n.value),u.length!==r);c=!0);}catch(t){f=!0,o=t}finally{try{if(!c&&null!=e.return&&(a=e.return(),Object(a)!==a))return}finally{if(f)throw o}}return u}}function r(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);r&&(n=n.filter((function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable}))),e.push.apply(e,n)}return e}function e(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?r(Object(n),!0).forEach((function(r){l(t,r,n[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))}))}return t}function n(){n=function(){return t};var t={},r=Object.prototype,e=r.hasOwnProperty,o=Object.defineProperty||function(t,r,e){t[r]=e.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",u=i.asyncIterator||"@@asyncIterator",c=i.toStringTag||"@@toStringTag";function f(t,r,e){return Object.defineProperty(t,r,{value:e,enumerable:!0,configurable:!0,writable:!0}),t[r]}try{f({},"")}catch(t){f=function(t,r,e){return t[r]=e}}function l(t,r,e,n){var i=r&&r.prototype instanceof y?r:y,a=Object.create(i.prototype),u=new E(n||[]);return o(a,"_invoke",{value:j(t,e,u)}),a}function s(t,r,e){try{return{type:"normal",arg:t.call(r,e)}}catch(t){return{type:"throw",arg:t}}}t.wrap=l;var p={};function y(){}function h(){}function v(){}var d={};f(d,a,(function(){return this}));var b=Object.getPrototypeOf,m=b&&b(b(L([])));m&&m!==r&&e.call(m,a)&&(d=m);var g=v.prototype=y.prototype=Object.create(d);function w(t){["next","throw","return"].forEach((function(r){f(t,r,(function(t){return this._invoke(r,t)}))}))}function O(t,r){function n(o,i,a,u){var c=s(t[o],t,i);if("throw"!==c.type){var f=c.arg,l=f.value;return l&&"object"==typeof l&&e.call(l,"__await")?r.resolve(l.__await).then((function(t){n("next",t,a,u)}),(function(t){n("throw",t,a,u)})):r.resolve(l).then((function(t){f.value=t,a(f)}),(function(t){return n("throw",t,a,u)}))}u(c.arg)}var i;o(this,"_invoke",{value:function(t,e){function o(){return new r((function(r,o){n(t,e,r,o)}))}return i=i?i.then(o,o):o()}})}function j(t,r,e){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return _()}for(e.method=o,e.arg=i;;){var a=e.delegate;if(a){var u=P(a,e);if(u){if(u===p)continue;return u}}if("next"===e.method)e.sent=e._sent=e.arg;else if("throw"===e.method){if("suspendedStart"===n)throw n="completed",e.arg;e.dispatchException(e.arg)}else"return"===e.method&&e.abrupt("return",e.arg);n="executing";var c=s(t,r,e);if("normal"===c.type){if(n=e.done?"completed":"suspendedYield",c.arg===p)continue;return{value:c.arg,done:e.done}}"throw"===c.type&&(n="completed",e.method="throw",e.arg=c.arg)}}}function P(t,r){var e=r.method,n=t.iterator[e];if(void 0===n)return r.delegate=null,"throw"===e&&t.iterator.return&&(r.method="return",r.arg=void 0,P(t,r),"throw"===r.method)||"return"!==e&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+e+"' method")),p;var o=s(n,t.iterator,r.arg);if("throw"===o.type)return r.method="throw",r.arg=o.arg,r.delegate=null,p;var i=o.arg;return i?i.done?(r[t.resultName]=i.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=void 0),r.delegate=null,p):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,p)}function x(t){var r={tryLoc:t[0]};1 in t&&(r.catchLoc=t[1]),2 in t&&(r.finallyLoc=t[2],r.afterLoc=t[3]),this.tryEntries.push(r)}function S(t){var r=t.completion||{};r.type="normal",delete r.arg,t.completion=r}function E(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(x,this),this.reset(!0)}function L(t){if(t){var r=t[a];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function r(){for(;++n<t.length;)if(e.call(t,n))return r.value=t[n],r.done=!1,r;return r.value=void 0,r.done=!0,r};return o.next=o}}return{next:_}}function _(){return{value:void 0,done:!0}}return h.prototype=v,o(g,"constructor",{value:v,configurable:!0}),o(v,"constructor",{value:h,configurable:!0}),h.displayName=f(v,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var r="function"==typeof t&&t.constructor;return!!r&&(r===h||"GeneratorFunction"===(r.displayName||r.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,v):(t.__proto__=v,f(t,c,"GeneratorFunction")),t.prototype=Object.create(g),t},t.awrap=function(t){return{__await:t}},w(O.prototype),f(O.prototype,u,(function(){return this})),t.AsyncIterator=O,t.async=function(r,e,n,o,i){void 0===i&&(i=Promise);var a=new O(l(r,e,n,o),i);return t.isGeneratorFunction(e)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(g),f(g,c,"Generator"),f(g,a,(function(){return this})),f(g,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var r=Object(t),e=[];for(var n in r)e.push(n);return e.reverse(),function t(){for(;e.length;){var n=e.pop();if(n in r)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=L,E.prototype={constructor:E,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(S),!t)for(var r in this)"t"===r.charAt(0)&&e.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function n(e,n){return a.type="throw",a.arg=t,r.next=e,n&&(r.method="next",r.arg=void 0),!!n}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var u=e.call(i,"catchLoc"),c=e.call(i,"finallyLoc");if(u&&c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(u){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,r){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&e.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=r&&r<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=r,i?(this.method="next",this.next=i.finallyLoc,p):this.complete(a)},complete:function(t,r){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&r&&(this.next=r),p},finish:function(t){for(var r=this.tryEntries.length-1;r>=0;--r){var e=this.tryEntries[r];if(e.finallyLoc===t)return this.complete(e.completion,e.afterLoc),S(e),p}},catch:function(t){for(var r=this.tryEntries.length-1;r>=0;--r){var e=this.tryEntries[r];if(e.tryLoc===t){var n=e.completion;if("throw"===n.type){var o=n.arg;S(e)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,r,e){return this.delegate={iterator:L(t),resultName:r,nextLoc:e},"next"===this.method&&(this.arg=void 0),p}},t}function o(t){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},o(t)}function i(t,r,e,n,o,i,a){try{var u=t[i](a),c=u.value}catch(t){return void e(t)}u.done?r(c):Promise.resolve(c).then(n,o)}function a(t){return function(){var r=this,e=arguments;return new Promise((function(n,o){var a=t.apply(r,e);function u(t){i(a,n,o,u,c,"next",t)}function c(t){i(a,n,o,u,c,"throw",t)}u(void 0)}))}}function u(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")}function c(t,r){for(var e=0;e<r.length;e++){var n=r[e];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,F(n.key),n)}}function f(t,r,e){return r&&c(t.prototype,r),e&&c(t,e),Object.defineProperty(t,"prototype",{writable:!1}),t}function l(t,r,e){return(r=F(r))in t?Object.defineProperty(t,r,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[r]=e,t}function s(){return s=Object.assign?Object.assign.bind():function(t){for(var r=1;r<arguments.length;r++){var e=arguments[r];for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])}return t},s.apply(this,arguments)}function p(t,r){if("function"!=typeof r&&null!==r)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(r&&r.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),r&&h(t,r)}function y(t){return y=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},y(t)}function h(t,r){return h=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,r){return t.__proto__=r,t},h(t,r)}function v(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function d(t,r,e){return d=v()?Reflect.construct.bind():function(t,r,e){var n=[null];n.push.apply(n,r);var o=new(Function.bind.apply(t,n));return e&&h(o,e.prototype),o},d.apply(null,arguments)}function b(t){return-1!==Function.toString.call(t).indexOf("[native code]")}function m(t){var r="function"==typeof Map?new Map:void 0;return m=function(t){if(null===t||!b(t))return t;if("function"!=typeof t)throw new TypeError("Super expression must either be null or a function");if(void 0!==r){if(r.has(t))return r.get(t);r.set(t,e)}function e(){return d(t,arguments,y(this).constructor)}return e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),h(e,t)},m(t)}function g(t,r){if(null==t)return{};var e,n,o={},i=Object.keys(t);for(n=0;n<i.length;n++)e=i[n],r.indexOf(e)>=0||(o[e]=t[e]);return o}function w(t,r){if(null==t)return{};var e,n,o=g(t,r);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);for(n=0;n<i.length;n++)e=i[n],r.indexOf(e)>=0||Object.prototype.propertyIsEnumerable.call(t,e)&&(o[e]=t[e])}return o}function O(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function j(t,r){if(r&&("object"==typeof r||"function"==typeof r))return r;if(void 0!==r)throw new TypeError("Derived constructors may only return object or undefined");return O(t)}function P(t){var r=v();return function(){var e,n=y(t);if(r){var o=y(this).constructor;e=Reflect.construct(n,arguments,o)}else e=n.apply(this,arguments);return j(this,e)}}function x(r,e){return L(r)||t(r,e)||T(r,e)||k()}function S(t){return E(t)||_(t)||T(t)||I()}function E(t){if(Array.isArray(t))return A(t)}function L(t){if(Array.isArray(t))return t}function _(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function T(t,r){if(t){if("string"==typeof t)return A(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);return"Object"===e&&t.constructor&&(e=t.constructor.name),"Map"===e||"Set"===e?Array.from(t):"Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?A(t,r):void 0}}function A(t,r){(null==r||r>t.length)&&(r=t.length);for(var e=0,n=new Array(r);e<r;e++)n[e]=t[e];return n}function I(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function k(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function N(t,r){var e="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=T(t))||r&&t&&"number"==typeof t.length){e&&(t=e);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){e=e.call(t)},n:function(){var t=e.next();return a=t.done,t},e:function(t){u=!0,i=t},f:function(){try{a||null==e.return||e.return()}finally{if(u)throw i}}}}function R(t,r){if("object"!=typeof t||null===t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,r||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===r?String:Number)(t)}function F(t){var r=R(t,"string");return"symbol"==typeof r?r:String(r)}export{A as arrayLikeToArray,L as arrayWithHoles,E as arrayWithoutHoles,O as assertThisInitialized,a as asyncToGenerator,u as classCallCheck,d as construct,f as createClass,N as createForOfIteratorHelper,P as createSuper,l as defineProperty,s as extends,y as getPrototypeOf,p as inherits,b as isNativeFunction,v as isNativeReflectConstruct,_ as iterableToArray,t as iterableToArrayLimit,k as nonIterableRest,I as nonIterableSpread,e as objectSpread2,w as objectWithoutProperties,g as objectWithoutPropertiesLoose,j as possibleConstructorReturn,n as regeneratorRuntime,h as setPrototypeOf,x as slicedToArray,S as toConsumableArray,R as toPrimitive,F as toPropertyKey,o as typeof,T as unsupportedIterableToArray,m as wrapNativeSuper};
2
2
  //# sourceMappingURL=_rollupPluginBabelHelpers.js.map
@@ -0,0 +1,106 @@
1
+ .layoutBox-module_flexible-box__Q8zyl {
2
+ display: flex;
3
+ position: relative;
4
+ flex-direction: row;
5
+ flex: 0;
6
+ flex-grow: 0;
7
+ flex-shrink: 0;
8
+ flex-basis: auto;
9
+ flex-wrap: nowrap;
10
+ gap: 0;
11
+ text-align: left;
12
+ justify-content: flex-start;
13
+ align-items: flex-start;
14
+ align-self: auto;
15
+ margin: 0;
16
+ padding: 0;
17
+ width: auto;
18
+ height: auto;
19
+ max-width: none;
20
+ max-height: none;
21
+ min-width: 0;
22
+ min-height: 0;
23
+ border-radius: initial;
24
+ }
25
+ .CollapsibleContainer-module_collapsible-container__u0Jmm {
26
+ transform-origin: 0% 0%;
27
+ opacity: 0;
28
+ overflow: clip;
29
+ }
30
+ .CollapsibleContainer-module_collapsible-container__u0Jmm.CollapsibleContainer-module_vertical__w7MVN {
31
+ transition: opacity 0.2s ease-in-out, height 0.2s ease-in-out, max-height 0.2s ease-in-out;
32
+ will-change: opacity, height, max-height;
33
+ }
34
+ .CollapsibleContainer-module_collapsible-container__u0Jmm.CollapsibleContainer-module_vertical__w7MVN.CollapsibleContainer-module_collapsed__q8fs8 {
35
+ height: 0;
36
+ max-height: 0;
37
+ opacity: 0;
38
+ }
39
+ .CollapsibleContainer-module_collapsible-container__u0Jmm.CollapsibleContainer-module_vertical__w7MVN.CollapsibleContainer-module_expanded__O6Vh8 {
40
+ height: var(--prop-value);
41
+ max-height: var(--prop-value);
42
+ opacity: 1;
43
+ }
44
+ .CollapsibleContainer-module_collapsible-container__u0Jmm.CollapsibleContainer-module_horizontal__QJWI- {
45
+ transition: opacity 0.2s ease-in-out, width 0.2s ease-in-out, max-width 0.2s ease-in-out;
46
+ will-change: opacity, width, max-width;
47
+ }
48
+ .CollapsibleContainer-module_collapsible-container__u0Jmm.CollapsibleContainer-module_horizontal__QJWI-.CollapsibleContainer-module_collapsed__q8fs8 {
49
+ width: 0;
50
+ max-width: 0;
51
+ opacity: 0;
52
+ }
53
+ .CollapsibleContainer-module_collapsible-container__u0Jmm.CollapsibleContainer-module_horizontal__QJWI-.CollapsibleContainer-module_expanded__O6Vh8 {
54
+ width: var(--prop-value);
55
+ max-width: var(--prop-value);
56
+ opacity: 1;
57
+ }
58
+ .divider-module_divider-line__6CesR {
59
+ position: relative;
60
+ display: block;
61
+ transition: opacity, width, height 250ms ease-in-out;
62
+ background-color: var(--color);
63
+ opacity: var(--opacity);
64
+ }
65
+ .divider-module_divider-line__6CesR.divider-module_vertical__qSVWD {
66
+ height: var(--length);
67
+ left: var(--left);
68
+ width: var(--width);
69
+ margin: var(--margin);
70
+ }
71
+ .divider-module_divider-line__6CesR.divider-module_horizontal__Gz-Oj {
72
+ width: var(--length);
73
+ left: var(--left);
74
+ height: var(--height);
75
+ margin: var(--margin);
76
+ }
77
+ .icon-module_icon-base-parent__nOMvW {
78
+ line-height: 1px !important;
79
+ }
80
+
81
+ .icon-module_icon-base__S0tHf {
82
+ min-width: var(--min-width);
83
+ min-height: var(--min-height);
84
+ width: var(--width) !important;
85
+ height: var(--height) !important;
86
+ line-height: 1px !important;
87
+ background-color: var(--icon-color);
88
+ color: var(--icon-content-color);
89
+ background-repeat: no-repeat;
90
+ mask-image: var(--icon-url);
91
+ -webkit-mask-image: var(--icon-url);
92
+ mask-repeat: no-repeat;
93
+ -webkit-mask-repeat: no-repeat;
94
+ mask-size: contain;
95
+ -webkit-mask-size: contain;
96
+ mask-position: center;
97
+ -webkit-mask-position: center;
98
+ display: inline-block;
99
+ will-change: transform;
100
+ transform: translate3d(0, 0, 0);
101
+ }
102
+ .icon-module_icon-base__S0tHf svg {
103
+ fill: var(--icon-content-color);
104
+ width: var(--height);
105
+ height: var(--width);
106
+ }
@@ -0,0 +1,2 @@
1
+ import{_ as r}from"../internals/export.js";import{f as t}from"../internals/function-uncurry-this-clause.js";import{a as i}from"../internals/array-includes.js";import{a as n}from"../internals/array-method-is-strict.js";var a=r,s=t,e=i.indexOf,o=n,f=s([].indexOf),m=!!f&&1/f([1],1,-0)<0;a({target:"Array",proto:!0,forced:m||!o("indexOf")},{indexOf:function(r){var t=arguments.length>1?arguments[1]:void 0;return m?f(this,r,t)||0:e(this,r,t)}});
2
+ //# sourceMappingURL=es.array.index-of.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"es.array.index-of.js","sources":["../../../../../../node_modules/core-js/modules/es.array.index-of.js"],"sourcesContent":["'use strict';\n/* eslint-disable es/no-array-prototype-indexof -- required for testing */\nvar $ = require('../internals/export');\nvar uncurryThis = require('../internals/function-uncurry-this-clause');\nvar $indexOf = require('../internals/array-includes').indexOf;\nvar arrayMethodIsStrict = require('../internals/array-method-is-strict');\n\nvar nativeIndexOf = uncurryThis([].indexOf);\n\nvar NEGATIVE_ZERO = !!nativeIndexOf && 1 / nativeIndexOf([1], 1, -0) < 0;\nvar FORCED = NEGATIVE_ZERO || !arrayMethodIsStrict('indexOf');\n\n// `Array.prototype.indexOf` method\n// https://tc39.es/ecma262/#sec-array.prototype.indexof\n$({ target: 'Array', proto: true, forced: FORCED }, {\n indexOf: function indexOf(searchElement /* , fromIndex = 0 */) {\n var fromIndex = arguments.length > 1 ? arguments[1] : undefined;\n return NEGATIVE_ZERO\n // convert -0 to +0\n ? nativeIndexOf(this, searchElement, fromIndex) || 0\n : $indexOf(this, searchElement, fromIndex);\n }\n});\n"],"names":["$","require$$0","uncurryThis","require$$1","$indexOf","require$$2","indexOf","arrayMethodIsStrict","require$$3","nativeIndexOf","NEGATIVE_ZERO","target","proto","forced","searchElement","fromIndex","arguments","length","undefined","this"],"mappings":"0NAEA,IAAIA,EAAIC,EACJC,EAAcC,EACdC,EAAWC,EAAuCC,QAClDC,EAAsBC,EAEtBC,EAAgBP,EAAY,GAAGI,SAE/BI,IAAkBD,GAAiB,EAAIA,EAAc,CAAC,GAAI,GAAI,GAAK,EAKvET,EAAE,CAAEW,OAAQ,QAASC,OAAO,EAAMC,OAJrBH,IAAkBH,EAAoB,YAIC,CAClDD,QAAS,SAAiBQ,GACxB,IAAIC,EAAYC,UAAUC,OAAS,EAAID,UAAU,QAAKE,EACtD,OAAOR,EAEHD,EAAcU,KAAML,EAAeC,IAAc,EACjDX,EAASe,KAAML,EAAeC,EACnC"}
@@ -0,0 +1,2 @@
1
+ import{objectWithoutProperties as e,slicedToArray as o,objectSpread2 as r,extends as a}from"../../../../../_virtual/_rollupPluginBabelHelpers.js";import"../../../../../node_modules/core-js/modules/es.array.concat.js";import{memo as l,useRef as t,useState as n,useEffect as s,useLayoutEffect as i,useMemo as c}from"react";import{useParseProps as p}from"../../../hooks/useParseProps.js";import d from"./CollapsibleContainer.module.scss.js";var u=["collapsed","collapseHandler","children","horizontal","className"],h={width:"scrollWidth",height:"scrollHeight"},m=l((function(l){var m=l.collapsed,v=void 0!==m&&m,f=l.collapseHandler,j=l.children,x=l.horizontal,b=void 0!==x&&x,g=l.className,P=void 0===g?"":g,w=e(l,u),y=t(null),C=n(0),H=o(C,2),N=H[0],z=H[1],_=p(w),W=_.dataProps,k=_.restProps,A=!b;s((function(){null==f||f(v)}),[f,v]),i((function(){if(null!=y&&y.current){var e=A?"height":"width";z(y.current[h[e]])}}),[y,A]);var B=c((function(){return r({"--prop-name":A?"height":"width","--prop-max-name":A?"max-height":"max-width","--prop-value":"".concat(N,"px")},k)}),[A,k,N]),E=c((function(){var e=[A?d.vertical:d.horizontal];return v&&N&&null!=N&&e.push(d.collapsed),!v&&N&&null!=N&&e.push(d.expanded),e.join(" ")}),[v,N,A]);return React.createElement("div",a({className:"".concat(d["collapsible-container"]," ").concat(E," ").concat(P," "),ref:y,style:B},W),j)}));m.displayName="CollapsibleContainer";export{m as CollapsibleContainer};
2
+ //# sourceMappingURL=CollapsibleContainer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CollapsibleContainer.js","sources":["../../../../../../../../src/core/ui/components/container/CollapsibleContainer.tsx"],"sourcesContent":["import { FC, useRef, useState, memo, ReactNode, useEffect, useLayoutEffect, useMemo, CSSProperties } from 'react'\n\nimport { useParseProps } from '../../../hooks/useParseProps'\n\nimport classes from './CollapsibleContainer.module.scss'\n\n\nconst elementPropNameMap: Record<string, string> = {\n width: 'scrollWidth',\n height: 'scrollHeight',\n}\n\nexport type CollapsibleContainerProps = {\n collapsed?: boolean\n collapseHandler?: (collapsed: boolean) => void\n children?: ReactNode\n className?: string\n horizontal?: boolean\n} & CSSProperties\n\nexport const CollapsibleContainer: FC<CollapsibleContainerProps> = memo(({\n collapsed = false, collapseHandler, children, horizontal = false, className = '', ...props\n}: CollapsibleContainerProps) => {\n const containerRef = useRef<HTMLDivElement>(null)\n const [contentProp, setContentProp] = useState(0)\n\n const { dataProps, restProps: style } = useParseProps(props)\n\n const vertical = !horizontal\n\n useEffect(() => {\n collapseHandler?.(collapsed)\n }, [collapseHandler, collapsed])\n\n useLayoutEffect(() => {\n if (containerRef?.current) {\n const propName = vertical ? 'height' : 'width'\n\n setContentProp((containerRef.current as any)[elementPropNameMap[propName]])\n }\n }, [containerRef, vertical])\n\n const styleProps: CSSProperties = useMemo(() => ({\n '--prop-name': vertical ? 'height' : 'width',\n '--prop-max-name': vertical ? 'max-height' : 'max-width',\n '--prop-value': `${contentProp}px`,\n ...style,\n } as CSSProperties), [vertical, style, contentProp])\n\n const classNames = useMemo(() => {\n const classNames = [vertical ? classes.vertical : classes.horizontal]\n\n if (collapsed && contentProp && contentProp !== undefined && contentProp !== null) {\n classNames.push(classes.collapsed)\n }\n if (!collapsed && contentProp && contentProp !== undefined && contentProp !== null) {\n classNames.push(classes.expanded)\n }\n return classNames.join(' ')\n }, [collapsed, contentProp, vertical])\n\n return (\n <div\n className={`${classes['collapsible-container']} ${classNames} ${className} `}\n ref={containerRef}\n style={styleProps}\n {...dataProps}\n >\n {children}\n </div>\n )\n})\n\nCollapsibleContainer.displayName = 'CollapsibleContainer'\n"],"names":["elementPropNameMap","width","height","CollapsibleContainer","memo","_ref","_ref$collapsed","collapsed","collapseHandler","children","_ref$horizontal","horizontal","_ref$className","className","props","_objectWithoutProperties","_excluded","containerRef","useRef","_useState","useState","_useState2","_slicedToArray","contentProp","setContentProp","_useParseProps","useParseProps","dataProps","style","restProps","vertical","useEffect","useLayoutEffect","current","propName","styleProps","useMemo","_objectSpread","concat","classNames","classes","push","expanded","join","React","createElement","_extends","ref","displayName"],"mappings":"ggBAOMA,EAA6C,CACjDC,MAAO,cACPC,OAAQ,gBAWGC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,KAAAD,OAAIzB,EAAa,KAC7EkC,IAAK9B,EACLW,MAAOO,GACHR,GAEHlB,EAGP,IAEAN,EAAqB6C,YAAc"}
@@ -0,0 +1,2 @@
1
+ var l={"collapsible-container":"CollapsibleContainer-module_collapsible-container__u0Jmm",vertical:"CollapsibleContainer-module_vertical__w7MVN",collapsed:"CollapsibleContainer-module_collapsed__q8fs8",expanded:"CollapsibleContainer-module_expanded__O6Vh8",horizontal:"CollapsibleContainer-module_horizontal__QJWI-"};export{l as default};
2
+ //# sourceMappingURL=CollapsibleContainer.module.scss.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CollapsibleContainer.module.scss.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ import{objectWithoutProperties as e,slicedToArray as o,extends as n}from"../../../../../_virtual/_rollupPluginBabelHelpers.js";import a from"styled-components";import"../../../../../node_modules/core-js/modules/es.array.concat.js";import{memo as t,useRef as l,useState as r,useEffect as i}from"react";var c=["collapsed","collapseHandler","children","propName","className","css"],s={width:"scrollWidth",height:"scrollHeight"},p=function(e){return e.propName},d=t(a.div.withConfig({displayName:"CollapsibleContainerS__StyledContainer",componentId:"sc-fj3lnl-0"})(["transform-origin:0% 0%;transition:opacity 0.2s ease-in-out,"," 0.2s ease-in-out,max-"," 0.2s ease-in-out;will-change:opacity,",",max-",";overflow:hidden;opacity:0;&.Collapsible__container__collapsed{",":0;max-",":0;opacity:0;}&.Collapsible__container__expanded{",":",";max-",":",";opacity:1;}"],p,p,p,p,p,p,p,(function(e){var o=e.contentProp;return"".concat(o,"px")}),p,(function(e){var o=e.contentProp;return"".concat(o,"px")}))),m=a(d).withConfig({displayName:"CollapsibleContainerS___StyledStyledContainer",componentId:"sc-fj3lnl-1"})(["",""],(function(e){return e.$_css})),u=t((function(a){var t=a.collapsed,p=void 0!==t&&t,d=a.collapseHandler,u=a.children,_=a.propName,f=void 0===_?"height":_,h=a.className,y=a.css,C=e(a,c),v=l(),x=r(0),N=o(x,2),b=N[0],g=N[1];i((function(){null==d||d(p)}),[d,p]),i((function(){null!=v&&v.current&&g(v.current[s[f]])}),[v,f]);var j="";return p&&b&&null!=b&&(j="Collapsible__container__collapsed"),!p&&b&&null!=b&&(j="Collapsible__container__expanded"),React.createElement(m,n({className:"".concat(h," ").concat(j),ref:v,contentProp:b,propName:f},C,{$_css:y}),u)}));u.displayName="ContainerS";export{u as ContainerS};
2
+ //# sourceMappingURL=CollapsibleContainerS.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CollapsibleContainerS.js","sources":["../../../../../../../../src/core/ui/components/container/CollapsibleContainerS.tsx"],"sourcesContent":["import { FC, useRef, useState, memo, ReactNode, useEffect } from 'react'\nimport styled from 'styled-components'\n\ntype StyledContainerProps = { propName: string; className: string; [key: string]: any }\n\nconst elementPropNameMap: Record<string, string> = {\n width: 'scrollWidth',\n height: 'scrollHeight',\n}\n\nconst propNameFunc = ({ propName }: { propName: StyledContainerProps['propName']}) => propName\n\nconst StyledContainer: FC<StyledContainerProps> = memo(styled.div<StyledContainerProps>`\n transform-origin: 0% 0%;\n transition: opacity 0.2s ease-in-out, ${propNameFunc} 0.2s ease-in-out, max-${propNameFunc} 0.2s ease-in-out;\n will-change: opacity, ${propNameFunc}, max-${propNameFunc};\n overflow: hidden;\n opacity: 0;\n\n &.Collapsible__container__collapsed {\n ${propNameFunc}: 0;\n max-${propNameFunc}: 0;\n opacity: 0;\n }\n\n &.Collapsible__container__expanded {\n ${propNameFunc}: ${({ contentProp }: Partial<StyledContainerProps>) => `${contentProp}px`};\n max-${propNameFunc}: ${({ contentProp }: Partial<StyledContainerProps>) => `${contentProp}px`};\n opacity: 1;\n }\n`)\n\nexport type ContainerProps = {\n collapsed?: boolean\n collapseHandler?: (collapsed: boolean) => void\n children?: ReactNode\n propName?: string\n className?: string\n css?: string\n}\nexport const ContainerS: FC<ContainerProps> = memo(({\n collapsed = false, collapseHandler, children, propName = 'height', className, css, ...props\n}: ContainerProps) => {\n const containerRef = useRef<HTMLDivElement>()\n const [contentProp, setContentProp] = useState(0)\n\n useEffect(() => {\n collapseHandler?.(collapsed)\n }, [collapseHandler, collapsed])\n\n useEffect(() => {\n if (containerRef?.current) {\n setContentProp((containerRef.current as any)[elementPropNameMap[propName]])\n }\n }, [containerRef, propName])\n\n let resolvedClassName = ''\n\n if (collapsed && contentProp && contentProp !== undefined && contentProp !== null) {\n resolvedClassName = 'Collapsible__container__collapsed'\n }\n if (!collapsed && contentProp && contentProp !== undefined && contentProp !== null) {\n resolvedClassName = 'Collapsible__container__expanded'\n }\n\n return (\n <StyledContainer\n className={`${className} ${resolvedClassName}`}\n ref={containerRef}\n contentProp={contentProp}\n propName={propName}\n css={css}\n {...props}\n >\n {children}\n </StyledContainer>\n )\n})\n\nContainerS.displayName = 'ContainerS'\n"],"names":["elementPropNameMap","width","height","propNameFunc","_ref","propName","StyledContainer","memo","styled","div","withConfig","displayName","componentId","_ref2","contentProp","concat","_ref3","_StyledStyledContainer","p","$_css","ContainerS","_ref4","_ref4$collapsed","collapsed","collapseHandler","children","_ref4$propName","className","css","props","_objectWithoutProperties","_excluded","containerRef","useRef","_useState","useState","_useState2","_slicedToArray","setContentProp","useEffect","current","resolvedClassName","React","createElement","_extends","ref"],"mappings":"2XAKMA,EAA6C,CACjDC,MAAO,cACPC,OAAQ,gBAGJC,EAAe,SAAHC,GAAc,OAAAA,EAARC,QAAsE,EAExFC,EAA4CC,EAAKC,EAAOC,IAAGC,WAAA,CAAAC,YAAA,yCAAAC,YAAA,eAAVJ,CAAU,CAAA,8DAAA,yBAAA,yCAAA,QAAA,kEAAA,UAAA,oDAAA,IAAA,QAAA,IAAA,gBAEvBL,EAAsCA,EACtDA,EAAqBA,EAKzCA,EACIA,EAKJA,GAAiB,SAAAU,GAAA,IAAGC,EAAWD,EAAXC,YAAW,MAAAC,GAAAA,OAAyCD,EAAW,KAAA,GAC/EX,GAAiB,SAAAa,GAAA,IAAGF,EAAWE,EAAXF,YAAW,MAAAC,GAAAA,OAAyCD,EAAW,KAAA,KAG3FG,EAAAT,EAAAF,GAAAI,WAAA,CAAAC,YAAA,gDAAAC,YAAA,eAAAJ,CAAA,CAAA,GAAA,KAAA,SAAAU,GAAA,OAAAA,EAAAC,KAAA,IAUWC,EAAiCb,GAAK,SAAAc,GAE7B,IAAAC,EAAAD,EADpBE,UAAAA,OAAY,IAAHD,GAAQA,EAAEE,EAAeH,EAAfG,gBAAiBC,EAAQJ,EAARI,SAAQC,EAAAL,EAAEhB,SAAAA,OAAW,IAAHqB,EAAG,SAAQA,EAAEC,EAASN,EAATM,UAAWC,EAAGP,EAAHO,IAAQC,EAAKC,EAAAT,EAAAU,GAErFC,EAAeC,IACrBC,EAAsCC,EAAS,GAAEC,EAAAC,EAAAH,EAAA,GAA1CpB,EAAWsB,EAAA,GAAEE,EAAcF,EAAA,GAElCG,GAAU,WACRf,SAAAA,EAAkBD,EACpB,GAAG,CAACC,EAAiBD,IAErBgB,GAAU,WACJP,SAAAA,EAAcQ,SAChBF,EAAgBN,EAAaQ,QAAgBxC,EAAmBK,IAEpE,GAAG,CAAC2B,EAAc3B,IAElB,IAAIoC,EAAoB,GASxB,OAPIlB,GAAaT,GAAbS,MAA4BT,IAC9B2B,EAAoB,sCAEjBlB,GAAaT,GAAd,MAA6BA,IAC/B2B,EAAoB,oCAIpBC,MAAAC,cAAA1B,EAAA2B,EAAA,CACEjB,UAAS,GAAAZ,OAAKY,OAASZ,OAAI0B,GAC3BI,IAAKb,EACLlB,YAAaA,EACbT,SAAUA,GAENwB,EAAK,CAAAV,MADJS,IAGJH,EAGP,IAEAL,EAAWT,YAAc"}
@@ -0,0 +1,2 @@
1
+ import{objectSpread2 as t}from"../../../../../_virtual/_rollupPluginBabelHelpers.js";import{memo as n}from"react";import i from"styled-components";var e={start:"flex-start","flex-start":"flex-start",end:"flex-end","flex-end":"flex-end"},r=function(t){return t&&e[t]||t},o=n(i.div.withConfig({displayName:"Flex",componentId:"sc-19vq3db-0"})(["display:flex;position:relative;flex-direction:",";flex:",";flex-grow:",";flex-shrink:",";flex-basis:",";flex-wrap:",";gap:",";text-align:",";justify-content:",";align-items:",";align-self:",";margin:",";padding:",";width:",";height:",";max-width:",";max-height:",";min-width:",";min-height:",";border-radius:",";"],(function(t){return t.direction||"row"}),(function(t){var n=t.flex;return void 0!==n?n:"0"}),(function(t){var n=t.flexGrow;return void 0!==n?n:"0"}),(function(t){var n=t.flexShrink;return void 0!==n?n:"0"}),(function(t){return t.flexBasis||"auto"}),(function(t){return t.flexWrap||"nowrap"}),(function(t){var n=t.gap;return void 0!==n?n:"0"}),(function(t){return t.alignText||"left"}),(function(t){var n=t.justify;return r(n)||"flex-start"}),(function(t){var n=t.align;return r(n)||"flex-start"}),(function(t){return t.alignSelf||"auto"}),(function(t){return t.margin||"0"}),(function(t){return t.padding||"0"}),(function(t){return t.width||"auto"}),(function(t){return t.height||"auto"}),(function(t){return t.maxWidth||"none"}),(function(t){return t.maxHeight||"none"}),(function(t){var n=t.minWidth;return n||"0"===n?n:"0"}),(function(t){return t.minHeight||"0"}),(function(t){return t.borderRadius||"initial"}))),a=n(i(o).attrs((function(n){return t({width:n.width||"100%",height:n.height||"100%",justify:n.justify||"center",align:n.align||"center"},n)})).withConfig({displayName:"Flex__FlexWrapper",componentId:"sc-19vq3db-1"})([""])),u=n(i(o).attrs((function(n){return t({width:"initial"},n)})).withConfig({displayName:"Flex__FlexTight",componentId:"sc-19vq3db-2"})([""])),f=n(i(o).attrs((function(n){return t({width:"initial",style:{text:"blue",padding:"1rem",border:"1px solid green"}},n)})).withConfig({displayName:"Flex__FlexTightStyled",componentId:"sc-19vq3db-3"})([""]));export{o as Flex,u as FlexTight,f as FlexTightStyled,a as FlexWrapper};
2
+ //# sourceMappingURL=Flex.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Flex.js","sources":["../../../../../../../../src/core/ui/components/container/Flex.ts"],"sourcesContent":["import { memo } from 'react'\nimport styled from 'styled-components'\n\nexport type FlexProps = {\n flex?: string\n flexGrow?: string | number\n alignText?: 'center' | 'right' | 'left'\n direction?: string\n flexShrink?: string | number\n flexBasis?: string\n flexWrap?: string\n justify?: string\n align?: string\n alignSelf?: string\n margin?: string\n padding?: string\n width?: string\n height?: string\n maxWidth?: string\n maxHeight?: string\n minWidth?: string\n minHeight?: string\n gap?: string\n css?: string\n borderRadius?: string\n}\n\nconst flexValueMap: Record<string, string> = {\n start: 'flex-start',\n 'flex-start': 'flex-start',\n end: 'flex-end',\n 'flex-end': 'flex-end',\n}\n\nconst resolveFlexProps = (value?: string): string | undefined => (value ? (flexValueMap[value] || value) : value)\n\nexport const Flex = memo(styled.div<FlexProps>`\n display: flex;\n position: relative;\n flex-direction: ${({ direction }: Partial<FlexProps>) => direction || 'row'};\n flex: ${({ flex }: Partial<FlexProps>) => (flex !== undefined ? flex : '0')};\n flex-grow: ${({ flexGrow }: Partial<FlexProps>) => (flexGrow !== undefined ? flexGrow : '0')};\n flex-shrink: ${({ flexShrink }: Partial<FlexProps>) => (flexShrink !== undefined ? flexShrink : '0')};\n flex-basis: ${({ flexBasis }: Partial<FlexProps>) => flexBasis || 'auto'};\n flex-wrap: ${({ flexWrap }: Partial<FlexProps>) => flexWrap || 'nowrap'};\n gap: ${({ gap }: Partial<FlexProps>) => (gap !== undefined ? gap : '0')};\n text-align: ${({ alignText }: Partial<FlexProps>) => alignText || 'left'};\n justify-content: ${({ justify }: Partial<FlexProps>) => resolveFlexProps(justify) || 'flex-start'};\n align-items: ${({ align }: Partial<FlexProps>) => resolveFlexProps(align) || 'flex-start'};\n align-self: ${({ alignSelf }: Partial<FlexProps>) => alignSelf || 'auto'};\n margin: ${({ margin }: Partial<FlexProps>) => margin || '0'};\n padding: ${({ padding }: Partial<FlexProps>) => padding || '0'};\n width: ${({ width }: Partial<FlexProps>) => width || 'auto'};\n height: ${({ height }: Partial<FlexProps>) => height || 'auto'};\n max-width: ${({ maxWidth }: Partial<FlexProps>) => maxWidth || 'none'};\n max-height: ${({ maxHeight }: Partial<FlexProps>) => maxHeight || 'none'};\n min-width: ${({ minWidth }: Partial<FlexProps>) => ((minWidth || minWidth === '0') ? minWidth : '0')};\n min-height: ${({ minHeight }: Partial<FlexProps>) => minHeight || '0'};\n border-radius: ${({ borderRadius }: Partial<FlexProps>) => borderRadius || 'initial'};\n`)\n\n// default flex centralized, 100% width and height\nexport const FlexWrapper = memo(styled(Flex).attrs((props: Partial<FlexProps>) => (\n {\n width: props.width || '100%',\n height: props.height || '100%',\n justify: props.justify || 'center',\n align: props.align || 'center',\n ...props,\n }\n))``)\n\nexport const FlexTight = memo(styled(Flex).attrs((props: Partial<FlexProps>) => ({\n width: 'initial',\n ...props,\n}))``)\n\nexport const FlexTightStyled = memo(styled(Flex).attrs((props: Partial<FlexProps>) => ({\n width: 'initial',\n style: {\n text: 'blue',\n padding: '1rem',\n border: '1px solid green',\n },\n ...props,\n}))``)\n"],"names":["flexValueMap","start","end","resolveFlexProps","value","Flex","memo","styled","div","withConfig","displayName","componentId","_ref","direction","_ref2","flex","undefined","_ref3","flexGrow","_ref4","flexShrink","_ref5","flexBasis","_ref6","flexWrap","_ref7","gap","_ref8","alignText","_ref9","justify","_ref10","align","_ref11","alignSelf","_ref12","margin","_ref13","padding","_ref14","width","_ref15","height","_ref16","maxWidth","_ref17","maxHeight","_ref18","minWidth","_ref19","minHeight","_ref20","borderRadius","FlexWrapper","attrs","props","_objectSpread","FlexTight","FlexTightStyled","style","text","border"],"mappings":"mJA2BA,IAAMA,EAAuC,CAC3CC,MAAO,aACP,aAAc,aACdC,IAAK,WACL,WAAY,YAGRC,EAAmB,SAACC,GAAc,OAA0BA,GAASJ,EAAaI,IAAmBA,CAAK,EAEnGC,EAAOC,EAAKC,EAAOC,IAAGC,WAAA,CAAAC,YAAA,OAAAC,YAAA,gBAAVJ,CAAU,CAAA,iDAAA,SAAA,cAAA,gBAAA,eAAA,cAAA,QAAA,eAAA,oBAAA,gBAAA,eAAA,WAAA,YAAA,UAAA,WAA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EAAKC,EAAOF,GAAMiD,OAAM,SAACC,GAAyB,OAAAC,EAAA,CAEzEhB,MAAOe,EAAMf,OAAS,OACtBE,OAAQa,EAAMb,QAAU,OACxBZ,QAASyB,EAAMzB,SAAW,SAC1BE,MAAOuB,EAAMvB,OAAS,UACnBuB,EAAK,IAEV9C,WAAA,CAAAC,YAAA,oBAAAC,YAAA,gBAR8BJ,CAQ9B,CAAA,MAEWkD,EAAYnD,EAAKC,EAAOF,GAAMiD,OAAM,SAACC,GAAyB,OAAAC,EAAA,CACzEhB,MAAO,WACJe,EAAK,IACP9C,WAAA,CAAAC,YAAA,kBAAAC,YAAA,gBAH2BJ,CAG3B,CAAA,MAEUmD,EAAkBpD,EAAKC,EAAOF,GAAMiD,OAAM,SAACC,GAAyB,OAAAC,EAAA,CAC/EhB,MAAO,UACPmB,MAAO,CACLC,KAAM,OACNtB,QAAS,OACTuB,OAAQ,oBAEPN,EAAK,IACP9C,WAAA,CAAAC,YAAA,wBAAAC,YAAA,gBARiCJ,CAQjC,CAAA"}
@@ -0,0 +1,2 @@
1
+ import{objectWithoutProperties as e,objectSpread2 as t,extends as r}from"../../../../../_virtual/_rollupPluginBabelHelpers.js";import"../../../../../node_modules/core-js/modules/es.array.concat.js";import{memo as a,forwardRef as o,useMemo as s}from"react";import{useParseProps as l}from"../../../hooks/useParseProps.js";import n from"./layoutBox.module.scss.js";var i=["style","children","tabIndex","className"],c={start:"flex-start","flex-start":"flex-start",end:"flex-end","flex-end":"flex-end"},d=function(e){return e&&c[e]||e},f=o((function(a,o){var c=a.style,f=a.children,u=a.tabIndex,m=a.className,x=void 0===m?"":m,p=e(a,i),y=l(p),j=y.dataProps,b=y.restProps,v=s((function(){return t(t(t(t(t({},b),b.align?{alignItems:d(b.align)}:{}),b.justify?{justifyContent:d(b.justify)}:{}),b.direction?{flexDirection:b.direction}:{}),c)}),[b,c]);return React.createElement("div",r({ref:o,tabIndex:u,className:"".concat(n["flexible-box"]," ").concat(x),style:v},j),f)}));f.displayName="LayoutBoxRefForwarded";var u=a(f);u.displayName="LayoutBox";export{u as LayoutBox};
2
+ //# sourceMappingURL=LayoutBox.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LayoutBox.js","sources":["../../../../../../../../src/core/ui/components/container/LayoutBox.tsx"],"sourcesContent":["import { memo, FC, useMemo, CSSProperties, forwardRef, LegacyRef } from 'react'\n\nimport { useParseProps } from '../../../hooks/useParseProps'\n\nimport { LayoutBoxProps } from './layoutBox.types'\nimport classes from './layoutBox.module.scss'\n\n\nconst flexValueMap: Record<string, string> = {\n start: 'flex-start',\n 'flex-start': 'flex-start',\n end: 'flex-end',\n 'flex-end': 'flex-end',\n}\n\nconst resolveFlexProps = (value?: string): string | undefined => (value ? (flexValueMap[value] || value) : value)\n\n\nconst LayoutBoxRefForwarded = forwardRef(({\n style, children, tabIndex, className = '', ...props\n}: LayoutBoxProps, ref: LegacyRef<HTMLDivElement> | undefined) => {\n const { dataProps, restProps } = useParseProps(props)\n\n const styles = useMemo(() => (\n {\n ...restProps,\n ...(restProps.align ? { alignItems: resolveFlexProps(restProps.align as string) } : {}),\n ...(restProps.justify ? { justifyContent: resolveFlexProps(restProps.justify as string) } : {}),\n ...(restProps.direction ? { flexDirection: restProps.direction } : {}),\n ...style,\n }\n ), [restProps, style])\n\n return (\n <div\n ref={ref}\n tabIndex={tabIndex}\n className={`${(classes as any)['flexible-box']} ${className}`}\n style={styles as CSSProperties}\n {...dataProps}\n >\n {children}\n </div>\n )\n})\n\nLayoutBoxRefForwarded.displayName = 'LayoutBoxRefForwarded'\n\nexport const LayoutBox: FC<LayoutBoxProps> = memo<LayoutBoxProps>(LayoutBoxRefForwarded)\n\n\nLayoutBox.displayName = 'LayoutBox'\n\n\n// default flex centralized, 100% width and height\n// export const FlexWrapper = memo(styled(Flex).attrs((props: Partial<FlexProps>) => (\n// {\n// width: props.width || '100%',\n// height: props.height || '100%',\n// justify: props.justify || 'center',\n// align: props.align || 'center',\n// ...props,\n// }\n// ))``)\n\n// export const FlexTight = memo(styled(Flex).attrs((props: Partial<FlexProps>) => ({\n// size: 'unset',\n// width: 'initial',\n// ...props,\n// }))``)\n\n// export const FlexTightStyled = memo(styled(Flex).attrs((props: Partial<FlexProps>) => ({\n// size: 'unset',\n// width: 'initial',\n// style: {\n// text: 'blue',\n// padding: '1rem',\n// border: '1px solid green',\n// },\n// ...props,\n// }))``)\n"],"names":["flexValueMap","start","end","resolveFlexProps","value","LayoutBoxRefForwarded","forwardRef","_ref","ref","style","children","tabIndex","_ref$className","className","props","_objectWithoutProperties","_excluded","_useParseProps","useParseProps","dataProps","restProps","styles","useMemo","_objectSpread","align","alignItems","justify","justifyContent","direction","flexDirection","React","createElement","_extends","concat","classes","displayName","LayoutBox","memo"],"mappings":"4ZAQMA,EAAuC,CAC3CC,MAAO,aACP,aAAc,aACdC,IAAK,WACL,WAAY,YAGRC,EAAmB,SAACC,GAAc,OAA0BA,GAASJ,EAAaI,IAAmBA,CAAK,EAG1GC,EAAwBC,GAAW,SAAAC,EAEtBC,GAA+C,IADhEC,EAAKF,EAALE,MAAOC,EAAQH,EAARG,SAAUC,EAAQJ,EAARI,SAAQC,EAAAL,EAAEM,UAAAA,OAAY,IAAHD,EAAG,GAAEA,EAAKE,EAAKC,EAAAR,EAAAS,GAEnDC,EAAiCC,EAAcJ,GAAvCK,EAASF,EAATE,UAAWC,EAASH,EAATG,UAEbC,EAASC,GAAQ,WAAA,OAAAC,EAAAA,EAAAA,EAAAA,EAAAA,KAEhBH,GACCA,EAAUI,MAAQ,CAAEC,WAAYtB,EAAiBiB,EAAUI,QAAqB,CAAE,GAClFJ,EAAUM,QAAU,CAAEC,eAAgBxB,EAAiBiB,EAAUM,UAAuB,CAAE,GAC1FN,EAAUQ,UAAY,CAAEC,cAAeT,EAAUQ,WAAc,CAAE,GAClEnB,EAAK,GAET,CAACW,EAAWX,IAEf,OACEqB,MAAAC,cAAA,MAAAC,EAAA,CACExB,IAAKA,EACLG,SAAUA,EACVE,UAAS,GAAAoB,OAAMC,EAAgB,gBAAeD,KAAAA,OAAIpB,GAClDJ,MAAOY,GACHF,GAEHT,EAGP,IAEAL,EAAsB8B,YAAc,4BAEvBC,EAAgCC,EAAqBhC,GAGlE+B,EAAUD,YAAc"}
@@ -0,0 +1,2 @@
1
+ import{objectWithoutProperties as r,extends as e}from"../../../../../_virtual/_rollupPluginBabelHelpers.js";import o from"styled-components";import{memo as t}from"react";import{FlexWrapper as c}from"./Flex.js";var n=["title","border","background","onClick","cssProp","children"],l=t((function(o){var t=o.title,c=o.border,l=o.background,i=o.onClick,a=o.cssProp,d=o.children,p=r(o,n);return React.createElement(s,e({onClick:i},p,{$_css:c||"border: 1px solid #999999;",$_css2:l||"background-color: rgba(0, 120, 255, 0.2);",$_css3:a}),t&&React.createElement("h2",null,t),d&&d)}));l.displayName="Placeholder";var s=o(c).withConfig({displayName:"Placeholder___StyledFlexWrapper",componentId:"sc-ozx0bx-0"})([""," "," ",""],(function(r){return r.$_css}),(function(r){return r.$_css2}),(function(r){return r.$_css3}));export{l as Placeholder};
2
+ //# sourceMappingURL=Placeholder.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Placeholder.js","sources":["../../../../../../../../src/core/ui/components/container/Placeholder.tsx"],"sourcesContent":["import { FC, memo, PropsWithChildren } from 'react'\n\nimport { FlexWrapper, FlexProps } from './Flex'\n\nexport type PlaceholderProps = FlexProps & PropsWithChildren<unknown> & {\n title?: string\n cssProp?: string\n background?: string\n border?: string\n onClick?: () => void\n}\n\nexport const Placeholder: FC<PlaceholderProps>\n= memo<PlaceholderProps>(({ title, border, background, onClick, cssProp, children, ...props }: PlaceholderProps) => (\n <FlexWrapper\n css={`\n ${border || 'border: 1px solid #999999;'}\n ${background || 'background-color: rgba(0, 120, 255, 0.2);'}\n ${cssProp}\n `}\n onClick={onClick}\n // eslint-disable-next-line react/jsx-props-no-spreading\n {...props}\n >\n {title && (<h2>{title}</h2>)}\n {children && children}\n </FlexWrapper>\n))\n\nPlaceholder.displayName = 'Placeholder'\n"],"names":["Placeholder","memo","_ref","title","border","background","onClick","cssProp","children","props","_objectWithoutProperties","_excluded","React","createElement","_StyledFlexWrapper","_extends","$_css","$_css2","$_css3","displayName","_styled","FlexWrapper","withConfig","componentId","p"],"mappings":"uRAYaA,EACXC,GAAuB,SAAAC,GAAA,IAAGC,EAAKD,EAALC,MAAOC,EAAMF,EAANE,OAAQC,EAAUH,EAAVG,WAAYC,EAAOJ,EAAPI,QAASC,EAAOL,EAAPK,QAASC,EAAQN,EAARM,SAAaC,EAAKC,EAAAR,EAAAS,GAAA,OACzFC,MAAAC,cAAAC,EAAAC,EAAA,CAMET,QAASA,GAELG,EAAK,CAAAO,MANLZ,GAAU,6BAA4Ba,OACtCZ,GAAc,4CAA2Ca,OACzDX,IAMHJ,GAAUS,MAAAC,cAAA,KAAA,KAAKV,GACfK,GAAYA,EACD,IAGhBR,EAAYmB,YAAc,cAAa,IAAAL,EAAAM,EAAAC,GAAAC,WAAA,CAAAH,YAAA,kCAAAI,YAAA,eAAAH,CAAA,CAAA,GAAA,IAAA,IAAA,KAAA,SAAAI,GAAA,OAAAA,EAAAR,KAAA,IAAA,SAAAQ,GAAA,OAAAA,EAAAP,MAAA,IAAA,SAAAO,GAAA,OAAAA,EAAAN,MAAA"}
@@ -0,0 +1,2 @@
1
+ import{objectWithoutProperties as e,slicedToArray as t,extends as i}from"../../../../../_virtual/_rollupPluginBabelHelpers.js";import{memo as n,useRef as l,useState as o,useMemo as r,useLayoutEffect as d}from"react";import h from"../../../../../node_modules/lodash-es/debounce.js";import{LayoutBox as u}from"./LayoutBox.js";var c=["children","debounceDelay"],a={main:{position:"absolute",zIndex:111,left:0,pointerEvents:"none"},empty:{pointerEvents:"none"}},v=n((function(n){var v=n.children,s=n.debounceDelay,m=void 0===s?250:s,g=e(n,c),p=l(),w=l({width:0,height:0}),f=o({width:void 0,height:void 0}),b=t(f,2),x=b[0],y=b[1],R=r((function(){return h((function(e){var t,i,n,l,o=e[0].contentRect.width,r=e[0].contentRect.height;(null===(t=w.current)||void 0===t?void 0:t.width)===o&&(null===(i=w.current)||void 0===i?void 0:i.height)===r||(w.current={width:o,height:r},y({width:null==p||null===(n=p.current)||void 0===n?void 0:n.clientWidth,height:null==p||null===(l=p.current)||void 0===l?void 0:l.clientHeight}))}),m)}),[m]);return d((function(){var e,t,i,n;null!=p&&p.current&&(t=null==p?void 0:p.current,(e=new ResizeObserver(R)).observe(t),y({width:null==p||null===(i=p.current)||void 0===i?void 0:i.clientWidth,height:null==p||null===(n=p.current)||void 0===n?void 0:n.clientHeight}));return function(){var i,n;null===(i=e)||void 0===i||null===(n=i.unobserve)||void 0===n||n.call(i,t)}}),[R,p]),React.createElement(u,i({width:"100%",height:"100%",justify:"center",align:"center",direction:"column"},g),React.createElement(u,{style:a.main,width:"100%",height:"100%",ref:p}),!v&&React.createElement(u,{width:"".concat(Math.max((null==x?void 0:x.width)||200,200)||200,"px"),height:"".concat(Math.max((null==x?void 0:x.height)||200,200)||200,"px"),style:a.empty}),v&&(null==v?void 0:v({height:"".concat((null==x?void 0:x.height)||200,"px"),width:"".concat((null==x?void 0:x.width)||200,"px"),measured:!(null==x||!x.height)})))}));v.displayName="ResizableContainer";export{v as ResizableContainer};
2
+ //# sourceMappingURL=ResizableContainer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ResizableContainer.js","sources":["../../../../../../../../src/core/ui/components/container/ResizableContainer.tsx"],"sourcesContent":["import { memo, useState, useRef, useMemo, useLayoutEffect, RefObject, PropsWithChildren } from 'react'\nimport debounce from 'lodash-es/debounce'\n\nimport { LayoutBox } from './LayoutBox'\nimport { LayoutBoxProps } from './layoutBox.types'\n\nexport type ResizableContainerProps = LayoutBoxProps & PropsWithChildren<any> & {\n debounceDelay?: number\n}\n\nexport type ResizableContainerRenderProps = {\n width: number | string\n height: number | string\n measured: boolean\n}\n\ntype WrapperSize = {width: undefined | number; height: undefined | number}\n\nconst styles = {\n main: {\n position: 'absolute',\n zIndex: 111,\n left: 0,\n pointerEvents: 'none',\n // backgroundColor: '#FF000040',\n },\n empty: {\n pointerEvents: 'none',\n // background: '#FF000040',\n // border: '1px solid #0000FF40',\n },\n}\n\nexport const ResizableContainer = memo<ResizableContainerProps>(\n ({ children, debounceDelay = 250, ...props }: ResizableContainerProps) => {\n const containerRef = useRef<HTMLDivElement>()\n\n const lastResizeWidthRef = useRef<{ width: number; height: number }>({ width: 0, height: 0 })\n\n const [containerSize, setContainerSize]\n = useState<WrapperSize>({ width: undefined, height: undefined })\n\n const debouncedResizeWrapper = useMemo(() => debounce((entries) => {\n const newResizeWidth = entries[0].contentRect.width\n const newResizeHeight = entries[0].contentRect.height\n\n if (lastResizeWidthRef.current?.width === newResizeWidth\n && lastResizeWidthRef.current?.height === newResizeHeight) {\n return\n }\n lastResizeWidthRef.current = { width: newResizeWidth, height: newResizeHeight }\n\n setContainerSize({\n width: containerRef?.current?.clientWidth,\n height: containerRef?.current?.clientHeight,\n })\n }, debounceDelay), [debounceDelay])\n\n useLayoutEffect(() => {\n let resizeObserver: ResizeObserver\n let containerElement: HTMLElement\n\n if (containerRef?.current) {\n containerElement = containerRef?.current\n resizeObserver = new ResizeObserver(debouncedResizeWrapper)\n resizeObserver.observe(containerElement as Element)\n\n setContainerSize({\n width: containerRef?.current?.clientWidth,\n height: containerRef?.current?.clientHeight,\n })\n }\n return () => {\n resizeObserver?.unobserve?.(containerElement as Element)\n }\n }, [debouncedResizeWrapper, containerRef])\n\n // END RESIZING\n\n return (\n <LayoutBox\n width='100%'\n height='100%'\n justify='center'\n align='center'\n direction='column'\n {...props}\n >\n <LayoutBox\n style={styles.main}\n width='100%'\n height='100%'\n ref={containerRef as RefObject<HTMLDivElement>}\n />\n {!children && (<LayoutBox\n width={`${Math.max(containerSize?.width || 200, 200) || 200}px`}\n height={`${Math.max(containerSize?.height || 200, 200) || 200}px`}\n style={styles.empty}\n />)}\n {children && children?.({\n height: `${containerSize?.height || 200}px`,\n width: `${containerSize?.width || 200}px`,\n measured: !!containerSize?.height,\n } as ResizableContainerRenderProps)}\n </LayoutBox>\n )\n },\n)\n\nResizableContainer.displayName = 'ResizableContainer'\n\n"],"names":["styles","main","position","zIndex","left","pointerEvents","empty","ResizableContainer","memo","_ref","children","_ref$debounceDelay","debounceDelay","props","_objectWithoutProperties","_excluded","containerRef","useRef","lastResizeWidthRef","width","height","_useState","useState","undefined","_useState2","_slicedToArray","containerSize","setContainerSize","debouncedResizeWrapper","useMemo","debounce","entries","_lastResizeWidthRef$c","_lastResizeWidthRef$c2","_containerRef$current","_containerRef$current2","newResizeWidth","contentRect","newResizeHeight","current","clientWidth","clientHeight","useLayoutEffect","resizeObserver","containerElement","_containerRef$current3","_containerRef$current4","ResizeObserver","observe","_resizeObserver","_resizeObserver$unobs","unobserve","call","React","createElement","LayoutBox","_extends","justify","align","direction","style","ref","concat","Math","max","measured","displayName"],"mappings":"uWAkBMA,EAAS,CACbC,KAAM,CACJC,SAAU,WACVC,OAAQ,IACRC,KAAM,EACNC,cAAe,QAGjBC,MAAO,CACLD,cAAe,SAMNE,EAAqBC,GAChC,SAAAC,GAA0E,IAAvEC,EAAQD,EAARC,SAAQC,EAAAF,EAAEG,cAAAA,OAAgB,IAAHD,EAAG,IAAGA,EAAKE,EAAKC,EAAAL,EAAAM,GAClCC,EAAeC,IAEfC,EAAqBD,EAA0C,CAAEE,MAAO,EAAGC,OAAQ,IAEzFC,EACEC,EAAsB,CAAEH,WAAOI,EAAWH,YAAQG,IAAYC,EAAAC,EAAAJ,EAAA,GADzDK,EAAaF,EAAA,GAAEG,EAAgBH,EAAA,GAGhCI,EAAyBC,GAAQ,WAAA,OAAMC,GAAS,SAACC,GAAY,IAAAC,EAAAC,EAAAC,EAAAC,EAC3DC,EAAiBL,EAAQ,GAAGM,YAAYlB,MACxCmB,EAAkBP,EAAQ,GAAGM,YAAYjB,QAEjBY,QAA1BA,EAAAd,EAAmBqB,eAAnBP,IAA0BA,OAA1BA,EAAAA,EAA4Bb,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U,IAAK,MAAQ,IAAQ,MAClEwC,MAAO5D,EAAOM,QAEfI,IAAYA,aAAAA,EAAAA,EAAW,CACtBU,OAAM0C,GAAAA,QAAKpC,aAAa,EAAbA,EAAeN,SAAU,IAAO,MAC3CD,MAAK2C,GAAAA,QAAKpC,aAAa,EAAbA,EAAeP,QAAS,IAAO,MACzC8C,WAAYvC,UAAAA,EAAeN,WAInC,IAGFb,EAAmB2D,YAAc"}
@@ -0,0 +1,2 @@
1
+ var l={"flexible-box":"layoutBox-module_flexible-box__Q8zyl"};export{l as default};
2
+ //# sourceMappingURL=layoutBox.module.scss.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"layoutBox.module.scss.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ import{extends as e}from"../../../../../_virtual/_rollupPluginBabelHelpers.js";import"../../../../../node_modules/core-js/modules/es.array.concat.js";import{memo as t,useMemo as i}from"react";import r from"./divider.module.scss.js";var a=t((function(e){var t=e.orientation,a=e.vertical,o=e.color,n=void 0===o?"#999999":o,l=e.opacity,c=e.length,d=void 0===c?"80%":c,s=e.left,v=void 0===s?"0":s,m=e.width,u=void 0===m?"1px":m,p=e.height,h=void 0===p?"1px":p,f=e.margin,g=e.className,y=void 0===g?"":g,N=i((function(){return"vertical"===t||!0===a}),[t,a]),j=i((function(){return{"--width":u,"--height":h,"--length":d,"--opacity":l,"--color":n,"--left":v,"--margin":f||(N?"auto 0":"0 auto")}}),[u,h,d,l,n,v,f,N]),x=N?r.vertical:r.horizontal;return React.createElement("div",{className:"".concat(r["divider-line"]," ").concat(x," ").concat(y),style:j})}));a.displayName="DividerLine";var o=t((function(t){return React.createElement(a,e({vertical:!0,length:"100%"},t))}));o.displayName="DividerVertical";var n=t((function(t){return React.createElement(a,e({length:"100%"},t))}));n.displayName="DividerHorizontal";export{n as DividerHorizontal,a as DividerLine,o as DividerVertical};
2
+ //# sourceMappingURL=DividerLine.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DividerLine.js","sources":["../../../../../../../../src/core/ui/components/dividers/DividerLine.tsx"],"sourcesContent":["/* eslint-disable react/jsx-props-no-spreading */\nimport { memo, FC, CSSProperties, useMemo } from 'react'\n\nimport classes from './divider.module.scss'\n\ntype DividerProps = {\n orientation?: string\n margin?: string\n vertical?: boolean\n length?: string\n color?: string\n opacity?: number\n left?: string\n width?: string\n height?: string\n className?: string\n}\n\nexport const DividerLine: FC<DividerProps> = memo<DividerProps>(({\n orientation, vertical,\n color = '#999999',\n opacity,\n length = '80%', left = '0',\n width = '1px', height = '1px',\n margin,\n className = '',\n}: DividerProps) => {\n const isVertical = useMemo(() => orientation === 'vertical' || vertical === true, [orientation, vertical])\n\n const styles = useMemo(() => (\n {\n '--width': width,\n '--height': height,\n '--length': length,\n '--opacity': opacity,\n '--color': color,\n '--left': left,\n '--margin': margin || (isVertical ? 'auto 0' : '0 auto'),\n }\n ), [width, height, length, opacity, color, left, margin, isVertical])\n\n const verHorClass = isVertical ? classes.vertical : classes.horizontal\n\n return (\n <div\n className={`${(classes as any)['divider-line']} ${verHorClass} ${className}`}\n style={styles as CSSProperties}\n />\n )\n})\n\nDividerLine.displayName = 'DividerLine'\n\nexport const DividerVertical: FC<DividerProps>\n = memo((props) => <DividerLine vertical length='100%' {...props} />)\nDividerVertical.displayName = 'DividerVertical'\n\nexport const DividerHorizontal: FC<DividerProps>\n = memo((props) => <DividerLine length='100%' {...props} />)\nDividerHorizontal.displayName = 'DividerHorizontal'\n"],"names":["DividerLine","memo","_ref","orientation","vertical","_ref$color","color","opacity","_ref$length","length","_ref$left","left","_ref$width","width","_ref$height","height","margin","_ref$className","className","isVertical","useMemo","styles","verHorClass","classes","horizontal","React","createElement","concat","style","displayName","DividerVertical","props","_extends","DividerHorizontal"],"mappings":"4OAkBaA,EAAgCC,GAAmB,SAAAC,GAQ5C,IAPlBC,EAAWD,EAAXC,YAAaC,EAAQF,EAARE,SAAQC,EAAAH,EACrBI,MAAAA,OAAQ,IAAHD,EAAG,UAASA,EACjBE,EAAOL,EAAPK,QAAOC,EAAAN,EACPO,OAAAA,OAAS,IAAHD,EAAG,MAAKA,EAAAE,EAAAR,EAAES,KAAAA,OAAO,IAAHD,EAAG,IAAGA,EAAAE,EAAAV,EAC1BW,MAAAA,OAAQ,IAAHD,EAAG,MAAKA,EAAAE,EAAAZ,EAAEa,OAAAA,OAAS,IAAHD,EAAG,MAAKA,EAC7BE,EAAMd,EAANc,OAAMC,EAAAf,EACNgB,UAAAA,OAAY,IAAHD,EAAG,GAAEA,EAERE,EAAaC,GAAQ,WAAA,MAAsB,aAAhBjB,IAA2C,IAAbC,CAAiB,GAAE,CAACD,EAAaC,IAE1FiB,EAASD,GAAQ,WAAA,MACrB,CACE,UAAWP,EACX,WAAYE,EACZ,WAAYN,EACZ,YAAaF,EACb,UAAWD,EACX,SAAUK,EACV,WAAYK,IAAWG,EAAa,SAAW,UAChD,GACA,CAACN,EAAOE,EAAQN,EAAQF,EAASD,EAAOK,EAAMK,EAAQG,IAEnDG,EAAcH,EAAaI,EAAQnB,SAAWmB,EAAQC,WAE5D,OACEC,MAAAC,cAAA,MAAA,CACER,UAASS,GAAAA,OAAMJ,EAAgB,gBAAeI,KAAAA,OAAIL,EAAW,KAAAK,OAAIT,GACjEU,MAAOP,GAGb,IAEArB,EAAY6B,YAAc,kBAEbC,EACT7B,GAAK,SAAC8B,GAAK,OAAKN,MAAAC,cAAC1B,EAAWgC,EAAA,CAAC5B,UAAQ,EAACK,OAAO,QAAWsB,GAAS,IACrED,EAAgBD,YAAc,sBAEjBI,EACThC,GAAK,SAAC8B,GAAK,OAAKN,MAAAC,cAAC1B,EAAWgC,EAAA,CAACvB,OAAO,QAAWsB,GAAS,IAC5DE,EAAkBJ,YAAc"}
@@ -0,0 +1,2 @@
1
+ var i={"divider-line":"divider-module_divider-line__6CesR",vertical:"divider-module_vertical__qSVWD",horizontal:"divider-module_horizontal__Gz-Oj"};export{i as default};
2
+ //# sourceMappingURL=divider.module.scss.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"divider.module.scss.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ import{objectWithoutProperties as e,extends as t,typeof as n}from"../../../../../_virtual/_rollupPluginBabelHelpers.js";import a from"styled-components";import"../../../../../node_modules/core-js/modules/es.array.map.js";import"../../../../../node_modules/core-js/modules/es.array.concat.js";import{memo as o,useCallback as i,useMemo as l}from"react";var c=["options","value","inputRef"],r=["label","name","type","value","defaultValue","placeholder","inputRef","error","disabled","userDisabled","withoutComponent","helpTextInfo","helpText","children","iconLeft","iconRight","addon","className","onChange","onChangeInner","onBlur","onFocus","rightIconClick","leftIconClick","options","css"],s=function(){return"#000000"},p=function(e){s=e},d=o((function(){return React.createElement("span",null)})),u=function(e){d=e},m=a.div.withConfig({displayName:"Field__FieldWrapper",componentId:"sc-i8c0jy-0"})(["opacity:",";pointer-events:",";flex:1 1 auto;width:100%;@media (min-width:400px){flex:1;}.label{font-size:0.8rem !important;font-weight:normal;}.help{text-align:left;}.mainControl{flex:1;border-radius:6px;box-shadow:0 0 6px 1px rgba(0,0,0,0.06);will-change:box-shadow;transition:box-shadow 250ms ease-in-out;&:hover{box-shadow:0 0 8px 2px rgba(0,0,0,0.1);}}button{box-shadow:0 0 8px 2px rgba(0,0,0,0.1);}.select{width:100%;flex:1;&::after{border-color:#000000 !important;}}.icon{&.is-action{cursor:pointer;pointer-events:initial !important;}}input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0;}input[type=number]{-moz-appearance:textfield;}.input[type=date]::-webkit-calendar-picker-indicator{opacity:0;-webkit-appearance:none;position:absolute;left:0;top:0;width:40px;height:100%;margin:0;padding:0;cursor:pointer;}textarea{resize:none;}"],(function(e){var t=e.disabled,n=e.userDisabled;return t||n?.5:1}),(function(e){var t=e.disabled,n=e.userDisabled;return t||n?"none":"auto"})),f=a(m).withConfig({displayName:"Field___StyledFieldWrapper",componentId:"sc-i8c0jy-1"})(["",""],(function(e){return e.$_css})),h=o((function(a){var o=a.options,i=a.value,l=a.inputRef,r=e(a,c);return React.createElement("div",{className:"select"},React.createElement("select",t({},r,{ref:l,defaultValue:i}),null==o?void 0:o.map((function(e){return React.createElement("option",{key:"".concat(JSON.stringify(e)),value:"object"===n(e)?null==e?void 0:e.value:e},"object"===n(e)?null==e?void 0:e.label:e)}))))})),b=a.input.withConfig({displayName:"Field__InputComponent",componentId:"sc-i8c0jy-2"})([""]),g=a.textarea.withConfig({displayName:"Field__TextAreaComponent",componentId:"sc-i8c0jy-3"})([""]),v=a.label.withConfig({displayName:"Field__StyledFieldLabel",componentId:"sc-i8c0jy-4"})(["text-align:left;"]),x=o((function(n){var a=n.label,o=n.name,c=n.type,p=void 0===c?"text":c,u=n.value,m=n.defaultValue,x=n.placeholder,y=n.inputRef,w=n.error,C=n.disabled,R=n.userDisabled,N=n.withoutComponent,_=n.helpTextInfo,E=n.helpText,F=n.children,I=n.iconLeft,j=n.iconRight,k=n.addon,D=n.className,B=n.onChange,T=n.onChangeInner,L=n.onBlur,V=n.onFocus,z=n.rightIconClick,S=n.leftIconClick,W=n.options,K=n.css,P=e(n,r),$=b;F||"textarea"!==p||($=g);var A=i((function(e){var t;R?null==e||null===(t=e.preventDefault)||void 0===t||t.call(e):V&&V(e)}),[R,V]),H=i((function(e){R||(T&&null!=e&&e.target?(e.target.value=T(e.target.value),B&&B(e)):B&&B(e))}),[T,B,R]),J=l((function(){return void 0===u?{defaultValue:m}:{value:u}}),[u,m]);return React.createElement(f,{className:"field ".concat(D),error:w,disabled:C,userDisabled:R,$_css:K},React.createElement(v,{htmlFor:o,className:"label"},a),React.createElement("div",{className:"field ".concat(k?"has-addons":"")},React.createElement("div",{className:"control mainControl ".concat(I&&!N?"has-icons-left":""," ").concat(j?"has-icons-right":"")},!N&&(F||"select"!==p&&!W?!F&&React.createElement($,t({name:o,id:o,ref:y,className:"input ".concat(w?"is-danger":""),type:p,placeholder:x},J,{onChange:H,onBlur:L,onFocus:A,onKeyDown:A,autoComplete:"off",disabled:C},P)):React.createElement(h,t({name:o,id:o,inputRef:y,className:"input ".concat(w?"is-danger":""),type:"select",placeholder:x,value:u,options:W,onChange:B,onBlur:L,onFocus:A,onKeyDown:A,autoComplete:"off",disabled:C},P))),I&&!N&&React.createElement("span",{className:"iconLeft icon is-small is-left ".concat(S?"is-action":""),onClick:S},React.createElement(d,{iconName:I,color:s})),j&&React.createElement("span",{className:"iconRight icon is-small is-right ".concat(z?"is-action":""),onClick:z},React.createElement(d,{iconName:j,color:s})),F&&F),k&&k),_&&React.createElement("p",{className:"help"},_),E&&React.createElement("p",{className:"help ".concat(w?"is-danger":"")},E))}));x.displayName="Field";export{x as Field,m as FieldWrapper,h as Select,p as setIconColor,u as setIconComponent};
2
+ //# sourceMappingURL=Field.js.map