kui-complex 0.0.143 → 0.0.145

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.
package/index.d.ts CHANGED
@@ -143,7 +143,7 @@ declare const InputDropdown: React.ForwardRefExoticComponent<Pick<{
143
143
  children: React.ReactNode | React.ReactNode[];
144
144
  endComponent?: React.ReactNode;
145
145
  strategy?: _floating_ui_utils.Strategy | undefined;
146
- } & kui_basic.GridProps, "color" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "input" | "alignContent" | "alignItems" | "direction" | "xs" | "sm" | "md" | "lg" | "endComponent" | "spacing" | "item" | "container" | "justify" | "wrap" | "xl" | "isOpen" | "handleClose" | "buttonRef" | "strategy"> & React.RefAttributes<HTMLDivElement>>;
146
+ } & kui_basic.GridProps, "color" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "input" | "alignContent" | "alignItems" | "direction" | "xs" | "sm" | "md" | "lg" | "endComponent" | "isOpen" | "handleClose" | "buttonRef" | "strategy" | "spacing" | "item" | "container" | "justify" | "wrap" | "xl"> & React.RefAttributes<HTMLDivElement>>;
147
147
 
148
148
  interface InputWithMaskProps
149
149
  extends Omit<InputWithMaskProps$1, "form"> {
package/index.js CHANGED
@@ -1,12 +1,13 @@
1
1
  import 'react-datepicker/dist/react-datepicker.css';
2
- import { jsx as jsx$1, jsxs, Fragment } from '@emotion/react/jsx-runtime';
2
+ import { jsx as jsx$1, jsxs as jsxs$1, Fragment } from '@emotion/react/jsx-runtime';
3
3
  import styled from '@emotion/styled';
4
4
  import { css, Global } from '@emotion/react';
5
5
  import * as React from 'react';
6
- import { forwardRef, useEffect, useState, useRef } from 'react';
7
- import { jsx, jsxs as jsxs$1, Fragment as Fragment$1 } from 'react/jsx-runtime';
8
- import { Caption, theme, Button, Grid, Container, Tooltip as Tooltip$1, InputWithAdornments, Heading, InputWithMask as InputWithMask$1, IconButton, LinearProgress, Divider, Modal, Switch as Switch$1, InputWithCountryDropdown, Checkbox, Radio, InputMessage, CircularProgress, Box } from 'kui-basic';
9
- import { updateQueryParams, useForkRef, strongPasswordRegExp, mediumPasswordRegExp, simplePasswordRegExp, useToggle, isValidWithMaskExp, useWindowWidth } from 'kui-utils';
6
+ import { forwardRef, useRef, useEffect, useState } from 'react';
7
+ import { jsx, jsxs, Fragment as Fragment$1 } from 'react/jsx-runtime';
8
+ import { Caption, theme, Button, Container, Tooltip as Tooltip$1, Grid, InputWithAdornments, Heading, InputWithMask as InputWithMask$1, IconButton, LinearProgress, Divider, Modal, Switch as Switch$1, InputWithCountryDropdown, Checkbox, Radio, InputMessage, CircularProgress, Box } from 'kui-basic';
9
+ import { useWindowWidth, updateQueryParams, useForkRef, strongPasswordRegExp, mediumPasswordRegExp, simplePasswordRegExp, useToggle, isValidWithMaskExp } from 'kui-utils';
10
+ import Swiper from 'kui-swiper';
10
11
  import classNames from 'classnames';
11
12
  import { HalfArrowIcon, PrevArrowIcon, NextArrowIcon, CalendarIcon, ArrowBackIcon, ArrowNextIcon, ClosedEyeIcon, OpenEyeIcon, CheckIcon, PlusIcon, FileIcon, EditIcon, TrashIcon } from 'kui-icon';
12
13
  import _ from 'lodash';
@@ -16,7 +17,6 @@ import { scroller, Events, Link as Link$1, animateScroll, Element } from 'react-
16
17
  import { DateTime } from 'luxon';
17
18
  import ru from 'date-fns/locale/ru';
18
19
  import { useNavigate, useLocation } from 'react-router-dom';
19
- import Swiper from 'kui-swiper';
20
20
  import * as ReactDOM from 'react-dom';
21
21
  import { Loader } from '@googlemaps/js-api-loader';
22
22
 
@@ -131,10 +131,10 @@ var Avatar = forwardRef(function (props, ref) {
131
131
  return (jsx$1(Wrapper$7, __assign({ css: sizeStyles[size], ref: ref }, otherProps, { children: imageUrl ? (jsx$1(StyledImage, { "data-testid": "avatar_image", src: imageUrl, alt: "avatar" })) : (jsx$1(StyledUndefinedAvatar, { label: fullName, avatarSize: size })) })));
132
132
  });
133
133
  var Wrapper$7 = styled.div(templateObject_1$H || (templateObject_1$H = __makeTemplateObject(["\n border-radius: 50%;\n overflow: hidden;\n cursor: pointer;\n"], ["\n border-radius: 50%;\n overflow: hidden;\n cursor: pointer;\n"])));
134
- var StyledImage = styled.img(templateObject_2$q || (templateObject_2$q = __makeTemplateObject(["\n width: 100%;\n height: 100%;\n border-radius: 50%;\n object-fit: cover;\n"], ["\n width: 100%;\n height: 100%;\n border-radius: 50%;\n object-fit: cover;\n"])));
134
+ var StyledImage = styled.img(templateObject_2$p || (templateObject_2$p = __makeTemplateObject(["\n width: 100%;\n height: 100%;\n border-radius: 50%;\n object-fit: cover;\n"], ["\n width: 100%;\n height: 100%;\n border-radius: 50%;\n object-fit: cover;\n"])));
135
135
  var largeAvatarCSS = function (_a) {
136
136
  var avatarSize = _a.avatarSize;
137
- return avatarSize === "lg" && css(templateObject_3$d || (templateObject_3$d = __makeTemplateObject(["\n font-size: 32px;\n "], ["\n font-size: 32px;\n "])));
137
+ return avatarSize === "lg" && css(templateObject_3$c || (templateObject_3$c = __makeTemplateObject(["\n font-size: 32px;\n "], ["\n font-size: 32px;\n "])));
138
138
  };
139
139
  var StyledUndefinedAvatar = styled(UndefinedAvatar, {
140
140
  shouldForwardProp: function (prop) { return prop !== "size"; },
@@ -145,31 +145,58 @@ var sizeStyles = {
145
145
  md: css(templateObject_7$1 || (templateObject_7$1 = __makeTemplateObject(["\n min-width: 40px;\n width: 40px;\n height: 40px;\n @media (max-width: 600px) {\n min-width: 32px;\n width: 32px;\n height: 32px;\n }\n "], ["\n min-width: 40px;\n width: 40px;\n height: 40px;\n @media (max-width: 600px) {\n min-width: 32px;\n width: 32px;\n height: 32px;\n }\n "]))),
146
146
  lg: css(templateObject_8$1 || (templateObject_8$1 = __makeTemplateObject(["\n min-width: 80px;\n width: 80px;\n height: 80px;\n "], ["\n min-width: 80px;\n width: 80px;\n height: 80px;\n "]))),
147
147
  };
148
- var templateObject_1$H, templateObject_2$q, templateObject_3$d, templateObject_4$8, templateObject_5$4, templateObject_6$1, templateObject_7$1, templateObject_8$1;
148
+ var templateObject_1$H, templateObject_2$p, templateObject_3$c, templateObject_4$8, templateObject_5$4, templateObject_6$1, templateObject_7$1, templateObject_8$1;
149
149
 
150
150
  var ButtonTabElement = forwardRef(function (props, ref) {
151
151
  var index = props.index, onClick = props.onClick, isActive = props.isActive, label = props.label, disabled = props.disabled;
152
152
  var handleClick = function () {
153
153
  onClick(index);
154
154
  };
155
- return (jsx$1(StyledButton$1, __assign({ disabled: disabled, variant: isActive ? "orange" : "white", captionWeight: isActive ? 600 : 400, onClick: handleClick, css: !isActive && inactiveStyles, size: "s", ref: ref, className: classNames("KUI-ButtonTab", isActive && "KUI-ButtonTab_active") }, { children: label })));
155
+ return (jsx$1(StyledButton$1, __assign({ disabled: disabled, variant: isActive ? "orange" : "white", captionWeight: 400, onClick: handleClick, css: !isActive && inactiveStyles, size: "s", ref: ref, className: classNames("KUI-ButtonTab", isActive && "KUI-ButtonTab_active") }, { children: label })));
156
156
  });
157
- var StyledButton$1 = styled(Button)(templateObject_1$G || (templateObject_1$G = __makeTemplateObject(["\n margin-right: 24px;\n &:last-of-type {\n margin-right: 0;\n }\n"], ["\n margin-right: 24px;\n &:last-of-type {\n margin-right: 0;\n }\n"])));
158
- var inactiveStyles = css(templateObject_2$p || (templateObject_2$p = __makeTemplateObject(["\n p {\n color: ", ";\n }\n"], ["\n p {\n color: ", ";\n }\n"])), theme.palette.grey.seventy);
159
- var templateObject_1$G, templateObject_2$p;
157
+ var StyledButton$1 = styled(Button)(templateObject_1$G || (templateObject_1$G = __makeTemplateObject(["\n margin-right: 24px;\n &.KUI-ButtonTab_active {\n p {\n text-shadow: 0.2px 0 0 currentColor, -0.2px 0 0 currentColor;\n }\n }\n &:last-of-type {\n margin-right: 0;\n }\n"], ["\n margin-right: 24px;\n &.KUI-ButtonTab_active {\n p {\n text-shadow: 0.2px 0 0 currentColor, -0.2px 0 0 currentColor;\n }\n }\n &:last-of-type {\n margin-right: 0;\n }\n"])));
158
+ var inactiveStyles = css(templateObject_2$o || (templateObject_2$o = __makeTemplateObject(["\n p {\n color: ", ";\n }\n"], ["\n p {\n color: ", ";\n }\n"])), theme.palette.grey.seventy);
159
+ var templateObject_1$G, templateObject_2$o;
160
160
 
161
161
  var ButtonTab = forwardRef(function (props, ref) {
162
162
  var renderTabWrapper = props.renderTabWrapper, label = props.label, other = __rest(props, ["renderTabWrapper", "label"]);
163
163
  if (!renderTabWrapper)
164
164
  return jsx$1(ButtonTabElement, __assign({ ref: ref, label: label }, other));
165
165
  return renderTabWrapper(label, jsx$1(ButtonTabElement, __assign({ ref: ref, label: label }, other)));
166
- });
167
- styled(Button)(templateObject_1$F || (templateObject_1$F = __makeTemplateObject(["\n margin-right: 24px;\n &:last-of-type {\n margin-right: 0;\n }\n"], ["\n margin-right: 24px;\n &:last-of-type {\n margin-right: 0;\n }\n"])));
168
- css(templateObject_2$o || (templateObject_2$o = __makeTemplateObject(["\n p {\n color: ", ";\n }\n"], ["\n p {\n color: ", ";\n }\n"])), theme.palette.grey.seventy);
169
- var templateObject_1$F, templateObject_2$o;
166
+ });
167
+
168
+ var ButtonsTabs = function (props) {
169
+ var startComponent = props.startComponent, endComponent = props.endComponent, tabs = props.tabs, renderTabWrapper = props.renderTabWrapper;
170
+ var handleChange = props.handleChange, value = props.value;
171
+ var swiperRef = useRef(null);
172
+ var settings = {
173
+ spaceBetween: 8,
174
+ slidesPerView: "auto",
175
+ slideToClickedSlide: true,
176
+ injectStyles: [
177
+ "\n .swiper {\n padding: 8px 16px 24px 16px;\n margin: -8px -16px -24px -16px;\n }\n ",
178
+ ],
179
+ breakpoints: {
180
+ 600: {
181
+ spaceBetween: 16,
182
+ },
183
+ },
184
+ };
185
+ var slideTo = function (index) {
186
+ setTimeout(function () {
187
+ var _a, _b;
188
+ (_b = (_a = swiperRef.current) === null || _a === void 0 ? void 0 : _a.swiper) === null || _b === void 0 ? void 0 : _b.slideTo(index);
189
+ }, 16);
190
+ handleChange(index);
191
+ };
192
+ return (jsxs(Container, __assign({ className: "KUI-ButtonTabs" }, { children: [startComponent, jsx(StyledSlider, __assign({}, settings, { ref: swiperRef }, { children: tabs.map(function (tab, index) { return (jsx(ButtonTab, { index: index, onClick: slideTo, isActive: index === value, label: tab, renderTabWrapper: renderTabWrapper }, tab)); }) })), endComponent] })));
193
+ };
194
+ var StyledSlider = styled(Swiper)(templateObject_1$F || (templateObject_1$F = __makeTemplateObject(["\n swiper-slide {\n width: fit-content;\n }\n"], ["\n swiper-slide {\n width: fit-content;\n }\n"])));
195
+ var templateObject_1$F;
170
196
 
171
197
  var ButtonsPanel = forwardRef(function (_a, ref) {
172
198
  var tabs = _a.tabs, tabPanels = _a.tabPanels, paths = _a.paths, activeTab = _a.activeTab, isSticky = _a.isSticky, onChange = _a.onChange, startComponent = _a.startComponent, endComponent = _a.endComponent, navigate = _a.navigate, renderTabWrapper = _a.renderTabWrapper, otherProps = __rest(_a, ["tabs", "tabPanels", "paths", "activeTab", "isSticky", "onChange", "startComponent", "endComponent", "navigate", "renderTabWrapper"]);
199
+ var width = useWindowWidth();
173
200
  var _b = React.useState(Number(activeTab)), value = _b[0], setValue = _b[1];
174
201
  var handleChange = function (newValue) {
175
202
  setValue(newValue);
@@ -186,15 +213,17 @@ var ButtonsPanel = forwardRef(function (_a, ref) {
186
213
  useEffect(function () {
187
214
  setValue(Number(activeTab));
188
215
  }, [activeTab]);
189
- return (jsxs(Fragment, { children: [jsx$1(StyledContainer$2, __assign({ css: isSticky && { position: "sticky" }, ref: ref }, otherProps, { children: jsxs(StyledWrapper$9, __assign({ className: "KUI-ButtonTabs" }, { children: [startComponent, jsx$1(Grid, __assign({ container: true, alignItems: "center" }, { children: tabs.map(function (item, index) { return (jsx$1(ButtonTab, { index: index, onClick: handleChange, isActive: index === value, label: item, renderTabWrapper: renderTabWrapper }, item)); }) })), endComponent] })) })), jsx$1(Content, __assign({ role: "tabpanel" }, { children: tabPanels[value] }))] }));
216
+ if (width === 0) {
217
+ return null;
218
+ }
219
+ return (jsxs$1(Fragment, { children: [jsx$1(StyledContainer$2, __assign({ css: isSticky && { position: "sticky" }, ref: ref }, otherProps, { children: jsx$1(ButtonsTabs, { value: value, tabs: tabs, handleChange: handleChange, endComponent: endComponent, startComponent: startComponent, renderTabWrapper: renderTabWrapper }) })), jsx$1(Content, __assign({ role: "tabpanel" }, { children: tabPanels[value] }))] }));
190
220
  });
191
221
  ButtonsPanel.defaultProps = {
192
222
  isSticky: false,
193
223
  };
194
224
  var Content = styled.div(templateObject_1$E || (templateObject_1$E = __makeTemplateObject(["\n height: 100%;\n"], ["\n height: 100%;\n"])));
195
225
  var StyledContainer$2 = styled.div(templateObject_2$n || (templateObject_2$n = __makeTemplateObject(["\n background: ", ";\n top: 80px;\n z-index: 4;\n padding-top: 16px;\n padding-bottom: 24px;\n @media (max-width: 1200px) {\n padding-bottom: 18px;\n }\n @media (max-width: 600px) {\n top: 48px;\n }\n"], ["\n background: ", ";\n top: 80px;\n z-index: 4;\n padding-top: 16px;\n padding-bottom: 24px;\n @media (max-width: 1200px) {\n padding-bottom: 18px;\n }\n @media (max-width: 600px) {\n top: 48px;\n }\n"])), theme.palette.grey.zero);
196
- var StyledWrapper$9 = styled(Container)(templateObject_3$c || (templateObject_3$c = __makeTemplateObject(["\n display: flex;\n align-items: center;\n"], ["\n display: flex;\n align-items: center;\n"])));
197
- var templateObject_1$E, templateObject_2$n, templateObject_3$c;
226
+ var templateObject_1$E, templateObject_2$n;
198
227
 
199
228
  var InputDropdown = forwardRef(function (props, ref) {
200
229
  var isOpen = props.isOpen, handleClose = props.handleClose, buttonRef = props.buttonRef, children = props.children, endComponent = props.endComponent, input = props.input, className = props.className, strategy = props.strategy, onScroll = props.onScroll, otherProps = __rest(props, ["isOpen", "handleClose", "buttonRef", "children", "endComponent", "input", "className", "strategy", "onScroll"]);
@@ -222,7 +251,7 @@ var InputDropdown = forwardRef(function (props, ref) {
222
251
  ref.current = elem;
223
252
  dropdownRef.current = elem;
224
253
  };
225
- return (jsx(StyledTooltip, __assign({ fullWidth: true, withoutMobile: true, open: isOpen, onChange: handleChange, toggleMethod: "controlled", strategy: strategy || "fixed", placement: "bottom", className: className, content: jsxs$1(StyledDropdown$2, __assign({ "data-testid": "input_dropdown", container: true, ref: forwardedRef }, otherProps, { children: [jsx(StyledWrapper$8, __assign({ isScrollable: isScrollable }, { children: jsx(ScrollingContainer, __assign({ onScroll: onScroll, isScrollable: isScrollable, className: "KUI-InputDropdown_scroll" }, { children: children })) })), endComponent] })) }, { children: input })));
254
+ return (jsx(StyledTooltip, __assign({ fullWidth: true, withoutMobile: true, open: isOpen, onChange: handleChange, toggleMethod: "controlled", strategy: strategy || "fixed", placement: "bottom", className: className, content: jsxs(StyledDropdown$2, __assign({ "data-testid": "input_dropdown", container: true, ref: forwardedRef }, otherProps, { children: [jsx(StyledWrapper$8, __assign({ isScrollable: isScrollable }, { children: jsx(ScrollingContainer, __assign({ onScroll: onScroll, isScrollable: isScrollable, className: "KUI-InputDropdown_scroll" }, { children: children })) })), endComponent] })) }, { children: input })));
226
255
  });
227
256
  var StyledTooltip = styled(Tooltip$1)(templateObject_1$D || (templateObject_1$D = __makeTemplateObject(["\n width: 100%;\n > div {\n z-index: unset;\n width: 100%;\n > div {\n z-index: unset;\n width: 100%;\n > div {\n width: 100%;\n }\n }\n }\n .KUI-Popper {\n max-width: unset;\n > div {\n user-select: none;\n padding: 0;\n border-radius: 0 0 8px 8px;\n box-shadow: 0px 26px 34px 0px #0000001a;\n }\n &.top > div {\n border-radius: 8px 8px 0 0;\n }\n }\n"], ["\n width: 100%;\n > div {\n z-index: unset;\n width: 100%;\n > div {\n z-index: unset;\n width: 100%;\n > div {\n width: 100%;\n }\n }\n }\n .KUI-Popper {\n max-width: unset;\n > div {\n user-select: none;\n padding: 0;\n border-radius: 0 0 8px 8px;\n box-shadow: 0px 26px 34px 0px #0000001a;\n }\n &.top > div {\n border-radius: 8px 8px 0 0;\n }\n }\n"])));
228
257
  var StyledDropdown$2 = styled(Grid)(templateObject_2$m || (templateObject_2$m = __makeTemplateObject(["\n width: 100%;\n user-select: none;\n"], ["\n width: 100%;\n user-select: none;\n"])));
@@ -277,7 +306,7 @@ var InputSelectBase = forwardRef(function (_a, ref) {
277
306
  handleChange(option);
278
307
  handleCloseDropdown();
279
308
  };
280
- return (jsxs(Wrapper$6, { children: [jsx$1("input", { name: name, autoComplete: "off", hidden: true }), jsx$1(InputSelectDropdown, { options: options, inputRef: {
309
+ return (jsxs$1(Wrapper$6, { children: [jsx$1("input", { name: name, autoComplete: "off", hidden: true }), jsx$1(InputSelectDropdown, { options: options, inputRef: {
281
310
  current: (_b = inputRef === null || inputRef === void 0 ? void 0 : inputRef.current) === null || _b === void 0 ? void 0 : _b.parentElement,
282
311
  }, isOpenDropdown: isDropdownOpen, handleCloseDropdown: handleCloseDropdown, handleSelect: handleSelect, selectedValue: selectedValue, renderOption: renderOption, input: jsx$1(StyledInput$3, __assign({ onClick: handleOpenDropdown, ref: forwardedRef, disabled: disabled, readOnly: true, value: selectedLabel, message: error, isLabelShrink: Boolean(selectedValue) || selectedValue === 0 }, inputProps, { endIcon: !disabled && (jsx$1(StyledIcon$1, __assign({ width: 12, height: 13, css: [
283
312
  { transition: "all linear .2s" },
@@ -353,7 +382,7 @@ var CalendarHeaderWithSelect = forwardRef(function (_a, ref) {
353
382
  var month = date.getMonth();
354
383
  var minMonth = (min === null || min === void 0 ? void 0 : min.year) === year && (min === null || min === void 0 ? void 0 : min.month) ? min.month - 1 : 0;
355
384
  var maxMonth = (max === null || max === void 0 ? void 0 : max.year) === year ? max === null || max === void 0 ? void 0 : max.month : 11;
356
- return (jsx(Wrapper$5, __assign({ ref: ref }, { children: jsxs$1(Grid, __assign({ container: true, spacing: 2 }, { children: [jsx(Grid, __assign({ item: true, xs: 6 }, { children: jsx(SelectYear, { min: min === null || min === void 0 ? void 0 : min.year, max: max === null || max === void 0 ? void 0 : max.year, yearOptions: yearOptions, value: year, handleChange: changeYear }) })), jsx(Grid, __assign({ item: true, xs: 6 }, { children: jsx(SelectMonth, { min: (Number(min === null || min === void 0 ? void 0 : min.year) >= year && minMonth), max: (Number(max === null || max === void 0 ? void 0 : max.year) <= year && maxMonth), value: month, handleChange: changeMonth }) }))] })) })));
385
+ return (jsx(Wrapper$5, __assign({ ref: ref }, { children: jsxs(Grid, __assign({ container: true, spacing: 2 }, { children: [jsx(Grid, __assign({ item: true, xs: 6 }, { children: jsx(SelectYear, { min: min === null || min === void 0 ? void 0 : min.year, max: max === null || max === void 0 ? void 0 : max.year, yearOptions: yearOptions, value: year, handleChange: changeYear }) })), jsx(Grid, __assign({ item: true, xs: 6 }, { children: jsx(SelectMonth, { min: (Number(min === null || min === void 0 ? void 0 : min.year) >= year && minMonth), max: (Number(max === null || max === void 0 ? void 0 : max.year) <= year && maxMonth), value: month, handleChange: changeMonth }) }))] })) })));
357
386
  });
358
387
  var Wrapper$5 = styled.div(templateObject_1$z || (templateObject_1$z = __makeTemplateObject(["\n margin-bottom: 24px;\n @media (max-width: 900px) {\n padding: 0 18px;\n margin-bottom: 20px;\n }\n"], ["\n margin-bottom: 24px;\n @media (max-width: 900px) {\n padding: 0 18px;\n margin-bottom: 20px;\n }\n"])));
359
388
  var templateObject_1$z;
@@ -368,7 +397,7 @@ var templateObject_1$y;
368
397
  var CalendarStandardHeader = forwardRef(function (_a, ref) {
369
398
  var decreaseMonth = _a.decreaseMonth, increaseMonth = _a.increaseMonth, nextMonthButtonDisabled = _a.nextMonthButtonDisabled, prevMonthButtonDisabled = _a.prevMonthButtonDisabled, date = _a.date;
370
399
  var title = _.capitalize(date.toLocaleString("ru", { month: "long", year: "numeric" })).slice(0, -3);
371
- return (jsxs$1(HeaderWrapper, __assign({ container: true, alignItems: "center", justify: "space-between", ref: ref }, { children: [jsx(Grid, __assign({ item: true }, { children: jsx(StyledHeading, __assign({ size: "h4" }, { children: title })) })), jsx(Grid, __assign({ item: true }, { children: jsxs$1(Grid, __assign({ container: true, spacing: 2 }, { children: [jsx(Grid, __assign({ item: true }, { children: jsx(CircleButtonStyled, __assign({ isCircle: true, size: "xs", "data-testid": "prev_month_button", variant: "white", disabled: prevMonthButtonDisabled, onClick: decreaseMonth }, { children: jsx(PrevArrowIcon, { width: 10, height: 10 }) })) })), jsx(Grid, __assign({ item: true }, { children: jsx(CircleButtonStyled, __assign({ isCircle: true, size: "xs", variant: "white", disabled: nextMonthButtonDisabled, onClick: increaseMonth }, { children: jsx(NextArrowIcon, { width: 10, height: 10 }) })) }))] })) }))] })));
400
+ return (jsxs(HeaderWrapper, __assign({ container: true, alignItems: "center", justify: "space-between", ref: ref }, { children: [jsx(Grid, __assign({ item: true }, { children: jsx(StyledHeading, __assign({ size: "h4" }, { children: title })) })), jsx(Grid, __assign({ item: true }, { children: jsxs(Grid, __assign({ container: true, spacing: 2 }, { children: [jsx(Grid, __assign({ item: true }, { children: jsx(CircleButtonStyled, __assign({ isCircle: true, size: "xs", "data-testid": "prev_month_button", variant: "white", disabled: prevMonthButtonDisabled, onClick: decreaseMonth }, { children: jsx(PrevArrowIcon, { width: 10, height: 10 }) })) })), jsx(Grid, __assign({ item: true }, { children: jsx(CircleButtonStyled, __assign({ isCircle: true, size: "xs", variant: "white", disabled: nextMonthButtonDisabled, onClick: increaseMonth }, { children: jsx(NextArrowIcon, { width: 10, height: 10 }) })) }))] })) }))] })));
372
401
  });
373
402
  var HeaderWrapper = styled(Grid)(templateObject_1$x || (templateObject_1$x = __makeTemplateObject(["\n padding: 0 6px 34px;\n @media (max-width: 600px) {\n h2 {\n font-size: 16px;\n }\n }\n"], ["\n padding: 0 6px 34px;\n @media (max-width: 600px) {\n h2 {\n font-size: 16px;\n }\n }\n"])));
374
403
  var StyledHeading = styled(Heading)(templateObject_2$j || (templateObject_2$j = __makeTemplateObject(["\n @media (max-width: 600px) {\n font-weight: 700;\n }\n"], ["\n @media (max-width: 600px) {\n font-weight: 700;\n }\n"])));
@@ -405,7 +434,7 @@ var templateObject_1$v;
405
434
 
406
435
  var MonthPickerHeader = forwardRef(function (_a, ref) {
407
436
  var decreaseYear = _a.decreaseYear, increaseYear = _a.increaseYear, nextYearButtonDisabled = _a.nextYearButtonDisabled, prevYearButtonDisabled = _a.prevYearButtonDisabled, date = _a.date;
408
- return (jsxs$1(StyledHeader, __assign({ container: true, alignItems: "center", justify: "space-between", ref: ref }, { children: [jsx(Grid, __assign({ item: true }, { children: jsx(StyledIconButton, __assign({ disabled: prevYearButtonDisabled, onClick: decreaseYear, type: "button" }, { children: jsx(ArrowBackIcon, { width: 14, height: 12 }) })) })), jsx(Grid, __assign({ item: true }, { children: jsx(Caption, __assign({ size: "sm", weight: 600 }, { children: date.getFullYear() })) })), jsx(Grid, __assign({ item: true }, { children: jsx(StyledIconButton, __assign({ disabled: nextYearButtonDisabled, onClick: increaseYear, type: "button" }, { children: jsx(ArrowNextIcon, { width: 14, height: 12 }) })) }))] })));
437
+ return (jsxs(StyledHeader, __assign({ container: true, alignItems: "center", justify: "space-between", ref: ref }, { children: [jsx(Grid, __assign({ item: true }, { children: jsx(StyledIconButton, __assign({ disabled: prevYearButtonDisabled, onClick: decreaseYear, type: "button" }, { children: jsx(ArrowBackIcon, { width: 14, height: 12 }) })) })), jsx(Grid, __assign({ item: true }, { children: jsx(Caption, __assign({ size: "sm", weight: 600 }, { children: date.getFullYear() })) })), jsx(Grid, __assign({ item: true }, { children: jsx(StyledIconButton, __assign({ disabled: nextYearButtonDisabled, onClick: increaseYear, type: "button" }, { children: jsx(ArrowNextIcon, { width: 14, height: 12 }) })) }))] })));
409
438
  });
410
439
  var StyledIconButton = styled(IconButton)(templateObject_1$u || (templateObject_1$u = __makeTemplateObject(["\n height: 36px;\n &:disabled {\n opacity: 0;\n }\n"], ["\n height: 36px;\n &:disabled {\n opacity: 0;\n }\n"])));
411
440
  var StyledHeader = styled(Grid)(templateObject_2$i || (templateObject_2$i = __makeTemplateObject(["\n background: #fff;\n padding: 4px 16px;\n border-radius: 12px 12px 0 0;\n"], ["\n background: #fff;\n padding: 4px 16px;\n border-radius: 12px 12px 0 0;\n"])));
@@ -545,7 +574,7 @@ var PassportStrengthBar = forwardRef(function (_a, ref) {
545
574
  var strengthKey = strength
546
575
  ? strengthCoefficients[strength]
547
576
  : -1;
548
- return (jsxs(Wrapper$2, __assign({ "data-testid": "strength_bar", className: String(!strength && "hidden"), ref: ref }, { children: [jsx$1(ReliabilityLevelWrapper, { children: Object.keys(strengthCoefficients).map(function (item, key) { return (jsx$1(ReliabilityLevel, { children: jsx$1(StyledLinearProgress, { "data-testid": "progress_item_".concat(item), value: strengthKey >= key ? 100 : 0, color: color }) }, item)); }) }), jsx$1(Caption, __assign({ "data-testid": "strength_bar_explanation", size: "s", css: { color: color } }, { children: strength && strengthTexts[strength] })), jsx$1(Description, __assign({ size: "s", color: "fiftyP" }, { children: "\u041F\u0430\u0440\u043E\u043B\u044C \u0434\u043E\u043B\u0436\u0435\u043D \u0441\u043E\u0441\u0442\u043E\u044F\u0442\u044C \u0438\u0437 10 \u0441\u0438\u043C\u0432\u043E\u043B\u043E\u0432, \u0441\u043E\u0434\u0435\u0440\u0436\u0430\u0442\u044C \u0446\u0438\u0444\u0440\u044B, \u0431\u043E\u043B\u044C\u0448\u0438\u0435 \u0438 \u0441\u0442\u0440\u043E\u0447\u043D\u044B\u0435 \u043B\u0430\u0442\u0438\u043D\u0441\u043A\u0438\u0435 \u0431\u0443\u0432\u044B" }))] })));
577
+ return (jsxs$1(Wrapper$2, __assign({ "data-testid": "strength_bar", className: String(!strength && "hidden"), ref: ref }, { children: [jsx$1(ReliabilityLevelWrapper, { children: Object.keys(strengthCoefficients).map(function (item, key) { return (jsx$1(ReliabilityLevel, { children: jsx$1(StyledLinearProgress, { "data-testid": "progress_item_".concat(item), value: strengthKey >= key ? 100 : 0, color: color }) }, item)); }) }), jsx$1(Caption, __assign({ "data-testid": "strength_bar_explanation", size: "s", css: { color: color } }, { children: strength && strengthTexts[strength] })), jsx$1(Description, __assign({ size: "s", color: "fiftyP" }, { children: "\u041F\u0430\u0440\u043E\u043B\u044C \u0434\u043E\u043B\u0436\u0435\u043D \u0441\u043E\u0441\u0442\u043E\u044F\u0442\u044C \u0438\u0437 10 \u0441\u0438\u043C\u0432\u043E\u043B\u043E\u0432, \u0441\u043E\u0434\u0435\u0440\u0436\u0430\u0442\u044C \u0446\u0438\u0444\u0440\u044B, \u0431\u043E\u043B\u044C\u0448\u0438\u0435 \u0438 \u0441\u0442\u0440\u043E\u0447\u043D\u044B\u0435 \u043B\u0430\u0442\u0438\u043D\u0441\u043A\u0438\u0435 \u0431\u0443\u0432\u044B" }))] })));
549
578
  });
550
579
  var Wrapper$2 = styled.div(templateObject_1$q || (templateObject_1$q = __makeTemplateObject(["\n margin-top: 16px;\n min-height: 86px;\n @media (max-width: 900px) {\n min-height: unset;\n }\n &.hidden {\n opacity: 0;\n @media (max-width: 900px) {\n display: none;\n }\n }\n"], ["\n margin-top: 16px;\n min-height: 86px;\n @media (max-width: 900px) {\n min-height: unset;\n }\n &.hidden {\n opacity: 0;\n @media (max-width: 900px) {\n display: none;\n }\n }\n"])));
551
580
  var ReliabilityLevelWrapper = styled.div(templateObject_2$g || (templateObject_2$g = __makeTemplateObject(["\n display: flex;\n margin-bottom: 8px;\n"], ["\n display: flex;\n margin-bottom: 8px;\n"])));
@@ -614,19 +643,19 @@ var InputPassword = forwardRef(function (props, ref) {
614
643
  checkPasswordStrength(fieldValue);
615
644
  }
616
645
  }, []);
617
- return (jsxs$1(Fragment$1, { children: [jsx(InputWithController, __assign({ type: showPassword ? "text" : "password", autoComplete: "new_password", onChange: handleChange, "data-testid": "input_password", ref: ref, endIcon: jsx(EyeIconWrapper, __assign({ "data-testid": "show_value_btn", onClick: handleShowChange }, { children: showPassword ? jsx(ClosedEyeIcon, {}) : jsx(OpenEyeIcon, {}) })) }, props)), jsx(PassportStrengthBar, { strength: strength })] }));
646
+ return (jsxs(Fragment$1, { children: [jsx(InputWithController, __assign({ type: showPassword ? "text" : "password", autoComplete: "new_password", onChange: handleChange, "data-testid": "input_password", ref: ref, endIcon: jsx(EyeIconWrapper, __assign({ "data-testid": "show_value_btn", onClick: handleShowChange }, { children: showPassword ? jsx(ClosedEyeIcon, {}) : jsx(OpenEyeIcon, {}) })) }, props)), jsx(PassportStrengthBar, { strength: strength })] }));
618
647
  });
619
648
  var EyeIconWrapper = styled.div(templateObject_1$p || (templateObject_1$p = __makeTemplateObject(["\n height: 18px;\n display: flex;\n align-items: center;\n cursor: pointer;\n"], ["\n height: 18px;\n display: flex;\n align-items: center;\n cursor: pointer;\n"])));
620
649
  var templateObject_1$p;
621
650
 
622
- var InputTextAreaMobile = forwardRef(function (props) { return (jsxs$1(Fragment$1, { children: [jsx(InputWrapper$1, { children: jsx(InputWithController, __assign({}, props)) }), jsx(TextAreaWrapper, { children: jsx(InputWithController, __assign({ isTextArea: true }, props)) })] })); });
651
+ var InputTextAreaMobile = forwardRef(function (props) { return (jsxs(Fragment$1, { children: [jsx(InputWrapper$1, { children: jsx(InputWithController, __assign({}, props)) }), jsx(TextAreaWrapper, { children: jsx(InputWithController, __assign({ isTextArea: true }, props)) })] })); });
623
652
  var InputWrapper$1 = styled.div(templateObject_1$o || (templateObject_1$o = __makeTemplateObject(["\n @media (max-width: 900px) {\n display: none;\n }\n"], ["\n @media (max-width: 900px) {\n display: none;\n }\n"])));
624
653
  var TextAreaWrapper = styled.div(templateObject_2$f || (templateObject_2$f = __makeTemplateObject(["\n @media (min-width: 901px) {\n display: none;\n }\n"], ["\n @media (min-width: 901px) {\n display: none;\n }\n"])));
625
654
  var templateObject_1$o, templateObject_2$f;
626
655
 
627
656
  var ModalFooter = forwardRef(function (_a, ref) {
628
657
  var label = _a.label, button = _a.button, otherProps = __rest(_a, ["label", "button"]);
629
- return (jsxs$1(StyledFooter, __assign({ ref: ref }, { children: [jsx(Divider, {}), jsx(ButtonWrapper$1, { children: button || (jsx(ButtonStyled, __assign({ fullWidth: true, size: "s", endIcon: jsx(CheckIcon, {}) }, otherProps, { children: label }))) })] })));
658
+ return (jsxs(StyledFooter, __assign({ ref: ref }, { children: [jsx(Divider, {}), jsx(ButtonWrapper$1, { children: button || (jsx(ButtonStyled, __assign({ fullWidth: true, size: "s", endIcon: jsx(CheckIcon, {}) }, otherProps, { children: label }))) })] })));
630
659
  });
631
660
  var StyledFooter = styled.div(templateObject_1$n || (templateObject_1$n = __makeTemplateObject(["\n background: ", ";\n border-radius: 0 0 12px 12px;\n z-index: 10;\n position: sticky;\n bottom: 0;\n left: 0;\n"], ["\n background: ", ";\n border-radius: 0 0 12px 12px;\n z-index: 10;\n position: sticky;\n bottom: 0;\n left: 0;\n"])), theme.palette.grey.zero);
632
661
  var ButtonWrapper$1 = styled.div(templateObject_2$e || (templateObject_2$e = __makeTemplateObject(["\n display: flex;\n justify-content: flex-end;\n padding: 24px 40px;\n @media (max-width: 600px) {\n padding: 24px 16px;\n }\n"], ["\n display: flex;\n justify-content: flex-end;\n padding: 24px 40px;\n @media (max-width: 600px) {\n padding: 24px 16px;\n }\n"])));
@@ -701,7 +730,13 @@ var InputWithDatePicker = forwardRef(function (_a, ref) {
701
730
  setDate(newDate);
702
731
  };
703
732
  var forwardedRef = useForkRef(ref, field.ref);
704
- return (jsxs(Fragment, { children: [jsx$1(InputForDatepicker, __assign({ mask: "00.00.0000", name: name, handleClick: handleModalOpen, value: formattedValue || value, onChange: handleChange, disabled: disabled, message: error, ref: forwardedRef }, props)), jsxs(StyledModal, __assign({ title: title, description: description, isOpen: isModalOpen, handleClose: handleModalClose, alignTitle: alignTitle }, { children: [jsx$1(ContentWrapper$2, { children: jsx$1(DatePicker, __assign({ inline: true, selected: date || formattedDate, onChange: handleDateChange, calendarContainer: StyledCalendarStandardContainer, renderCustomHeader: function (headProps) { return (jsx$1(CalendarHeaderWithSelect, __assign({ yearOptions: yearList, max: max, min: min }, headProps))); }, renderDayContents: function (day) { return (jsx$1(DayContent, { children: day })); }, maxDate: max === null || max === void 0 ? void 0 : max.toJSDate(), minDate: min === null || min === void 0 ? void 0 : min.toJSDate() }, datePickerProps)) }), jsx$1(ModalFooter, { fullWidth: true, disabled: !formattedDate && !date, onClick: acceptWithDateSelected, label: footerLabel })] }))] }));
733
+ useEffect(function () {
734
+ setValue(formattedValue);
735
+ }, [formattedValue]);
736
+ useEffect(function () {
737
+ setDate(formattedDate);
738
+ }, [formattedDate]);
739
+ return (jsxs$1(Fragment, { children: [jsx$1(InputForDatepicker, __assign({ mask: "00.00.0000", name: name, handleClick: handleModalOpen, value: formattedValue || value, onChange: handleChange, disabled: disabled, message: error, ref: forwardedRef }, props)), jsxs$1(StyledModal, __assign({ title: title, description: description, isOpen: isModalOpen, handleClose: handleModalClose, alignTitle: alignTitle }, { children: [jsx$1(ContentWrapper$2, { children: jsx$1(DatePicker, __assign({ inline: true, selected: date || formattedDate, onChange: handleDateChange, calendarContainer: StyledCalendarStandardContainer, renderCustomHeader: function (headProps) { return (jsx$1(CalendarHeaderWithSelect, __assign({ yearOptions: yearList, max: max, min: min }, headProps))); }, renderDayContents: function (day) { return (jsx$1(DayContent, { children: day })); }, maxDate: max === null || max === void 0 ? void 0 : max.toJSDate(), minDate: min === null || min === void 0 ? void 0 : min.toJSDate() }, datePickerProps)) }), jsx$1(ModalFooter, { fullWidth: true, disabled: !formattedDate && !date, onClick: acceptWithDateSelected, label: footerLabel })] }))] }));
705
740
  });
706
741
  InputWithDatePicker.defaultProps = {
707
742
  alignTitle: "center",
@@ -774,13 +809,13 @@ var MobileInputWithMonthPicker = forwardRef(function (_a, ref) {
774
809
  field === null || field === void 0 ? void 0 : field.onChange({ target: { value: date, name: name }, type: "change" });
775
810
  handleModalClose();
776
811
  };
777
- return (jsxs$1(Wrapper$1, __assign({ ref: ref }, { children: [jsx(InputForDatepicker, __assign({ mask: "00.0000", name: name, handleCLick: handleModalOpen, value: value, onChange: handleChange, disabled: disabled, message: error, isLabelShrink: Boolean(field.value) }, props)), jsxs$1(Modal, __assign({ title: title, isOpen: isModalOpen, handleClose: handleModalClose }, { children: [jsx(ContentWrapper$1, { children: jsx(DatePicker, __assign({ inline: true, showMonthYearPicker: true, dateFormat: "MM.yyyy", selected: date, onChange: function (newDate) { return setDate(newDate); }, locale: ruCustom, calendarContainer: MonthPickerContainer, renderCustomHeader: function (headProps) { return (jsx(MonthPickerHeader, __assign({}, headProps))); } }, datePickerProps)) }), jsx(ModalFooter, { fullWidth: true, disabled: !date, onClick: acceptWithDateSelected, label: "\u041F\u043E\u0434\u0442\u0432\u0435\u0440\u0434\u0438\u0442\u044C" })] }))] })));
812
+ return (jsxs(Wrapper$1, __assign({ ref: ref }, { children: [jsx(InputForDatepicker, __assign({ mask: "00.0000", name: name, handleCLick: handleModalOpen, value: value, onChange: handleChange, disabled: disabled, message: error, isLabelShrink: Boolean(field.value) }, props)), jsxs(Modal, __assign({ title: title, isOpen: isModalOpen, handleClose: handleModalClose }, { children: [jsx(ContentWrapper$1, { children: jsx(DatePicker, __assign({ inline: true, showMonthYearPicker: true, dateFormat: "MM.yyyy", selected: date, onChange: function (newDate) { return setDate(newDate); }, locale: ruCustom, calendarContainer: MonthPickerContainer, renderCustomHeader: function (headProps) { return (jsx(MonthPickerHeader, __assign({}, headProps))); } }, datePickerProps)) }), jsx(ModalFooter, { fullWidth: true, disabled: !date, onClick: acceptWithDateSelected, label: "\u041F\u043E\u0434\u0442\u0432\u0435\u0440\u0434\u0438\u0442\u044C" })] }))] })));
778
813
  });
779
814
  var Wrapper$1 = styled.div(templateObject_1$l || (templateObject_1$l = __makeTemplateObject(["\n @media (min-width: 601px) {\n display: none;\n }\n"], ["\n @media (min-width: 601px) {\n display: none;\n }\n"])));
780
815
  var ContentWrapper$1 = styled.div(templateObject_2$c || (templateObject_2$c = __makeTemplateObject(["\n @media (max-width: 600px) {\n padding: 16px 16px 8px;\n }\n"], ["\n @media (max-width: 600px) {\n padding: 16px 16px 8px;\n }\n"])));
781
816
  var templateObject_1$l, templateObject_2$c;
782
817
 
783
- var InputWithMonthPicker = function (props) { return (jsxs$1(Fragment$1, { children: [jsx(DesktopInputWithMonthPicker, __assign({}, props)), jsx(MobileInputWithMonthPicker, __assign({}, props))] })); };
818
+ var InputWithMonthPicker = function (props) { return (jsxs(Fragment$1, { children: [jsx(DesktopInputWithMonthPicker, __assign({}, props)), jsx(MobileInputWithMonthPicker, __assign({}, props))] })); };
784
819
 
785
820
  var MobileMenuPanel = forwardRef(function (_a, ref) {
786
821
  var tabs = _a.tabs, handleClick = _a.handleClick, variant = _a.variant, other = __rest(_a, ["tabs", "handleClick", "variant"]);
@@ -826,7 +861,7 @@ var MenuPanel = forwardRef(function (_a, ref) {
826
861
  if (width === 0) {
827
862
  return null;
828
863
  }
829
- return (jsxs("div", __assign({ ref: ref }, { children: [width > 765 ? (jsx$1(DesktopMenuPanel, { tabs: tabs, active: value, handleClick: handleClick, variant: variant, isScrolling: isScrolling, setIsScrolling: setIsScrolling })) : (jsx$1(MobileMenuPanel, { tabs: tabs, active: value, handleClick: handleClick, variant: variant, isScrolling: isScrolling, setIsScrolling: setIsScrolling })), tabPanels.map(function (item, index) { return (jsx$1("div", __assign({ css: index === tabPanels.length - 1 && fullHeightStyles }, { children: jsx$1(StyledElement, __assign({ name: tabs[index], "data-index": index }, { children: item }), index) }), index)); })] })));
864
+ return (jsxs$1("div", __assign({ ref: ref }, { children: [width > 765 ? (jsx$1(DesktopMenuPanel, { tabs: tabs, active: value, handleClick: handleClick, variant: variant, isScrolling: isScrolling, setIsScrolling: setIsScrolling })) : (jsx$1(MobileMenuPanel, { tabs: tabs, active: value, handleClick: handleClick, variant: variant, isScrolling: isScrolling, setIsScrolling: setIsScrolling })), tabPanels.map(function (item, index) { return (jsx$1("div", __assign({ css: index === tabPanels.length - 1 && fullHeightStyles }, { children: jsx$1(StyledElement, __assign({ name: tabs[index], "data-index": index }, { children: item }), index) }), index)); })] })));
830
865
  });
831
866
  MenuPanel.defaultProps = {
832
867
  variant: "grey",
@@ -987,7 +1022,7 @@ var PopperWithPortal = forwardRef(function (props, ref) {
987
1022
  // TODO подумать как реализовать правильное расположение подсказки под contentRef в зависимости от placement
988
1023
  // Автоматом менять положение (верх-низ) в зависимости от того помещается или нет
989
1024
  // Распожить стрелочку к контенту посередине контента
990
- return ReactDOM.createPortal(jsxs$1(Fragment$1, { children: [jsx(Global, { styles: css(templateObject_1$e || (templateObject_1$e = __makeTemplateObject(["\n body {\n position: relative;\n }\n "], ["\n body {\n position: relative;\n }\n "]))) }), jsx(PopperBase, __assign({ ref: forwardedRef, style: position }, other))] }), document.body);
1025
+ return ReactDOM.createPortal(jsxs(Fragment$1, { children: [jsx(Global, { styles: css(templateObject_1$e || (templateObject_1$e = __makeTemplateObject(["\n body {\n position: relative;\n }\n "], ["\n body {\n position: relative;\n }\n "]))) }), jsx(PopperBase, __assign({ ref: forwardedRef, style: position }, other))] }), document.body);
991
1026
  });
992
1027
  var templateObject_1$e;
993
1028
 
@@ -1071,7 +1106,7 @@ var Tooltip = forwardRef(function (props, ref) {
1071
1106
  useEffect(function () {
1072
1107
  setOpen(open);
1073
1108
  }, [open]);
1074
- return (jsxs$1(StyledWrapper$7, __assign({ className: className, onMouseLeave: handleClose, ref: ref }, { children: [jsx(StyledContentWrapper, __assign({ onMouseEnter: handleOpen, onTouchEnd: handleOpen, ref: elemRef, cursor: cursor }, { children: jsx(StyledContent$1, __assign({ className: "Tooltip_content" }, { children: children })) })), jsx(Popper, __assign({ open: isOpen }, popper, { contentRef: elemRef }, { children: content }))] })));
1109
+ return (jsxs(StyledWrapper$7, __assign({ className: className, onMouseLeave: handleClose, ref: ref }, { children: [jsx(StyledContentWrapper, __assign({ onMouseEnter: handleOpen, onTouchEnd: handleOpen, ref: elemRef, cursor: cursor }, { children: jsx(StyledContent$1, __assign({ className: "Tooltip_content" }, { children: children })) })), jsx(Popper, __assign({ open: isOpen }, popper, { contentRef: elemRef }, { children: content }))] })));
1075
1110
  });
1076
1111
  var containerCSS = css(templateObject_1$d || (templateObject_1$d = __makeTemplateObject(["\n display: inline-flex;\n width: 100%;\n height: fit-content;\n"], ["\n display: inline-flex;\n width: 100%;\n height: fit-content;\n"])));
1077
1112
  var StyledWrapper$7 = styled.div(templateObject_2$9 || (templateObject_2$9 = __makeTemplateObject(["\n ", ";\n position: relative;\n"], ["\n ", ";\n position: relative;\n"])), containerCSS);
@@ -1234,7 +1269,7 @@ function RadioGroupWithLabel(props) {
1234
1269
  name: name,
1235
1270
  }).fieldState;
1236
1271
  var errorMessage = (_a = fieldState.error) === null || _a === void 0 ? void 0 : _a.message;
1237
- return (jsxs$1(StyledContainer, { children: [jsxs$1(StyledWrapper$6, __assign({ container: true, alignItems: direction === "vertical" ? "flex-start" : "center", justify: "space-between", direction: direction === "vertical" ? "column" : "row", hasError: !!errorMessage, className: className, withTitle: !!title }, { children: [title && (jsx(StyledTitle, __assign({ direction: direction, size: "xs", weight: 600 }, { children: title.toUpperCase() }))), jsx(Grid, __assign({ item: true, xs: direction === "vertical" ? 12 : "auto" }, { children: jsx(RadioButtonsWithController, __assign({ form: form, name: name }, otherProps)) }))] })), errorMessage && jsx(InputMessage, { variant: "error", msg: errorMessage })] }));
1272
+ return (jsxs(StyledContainer, { children: [jsxs(StyledWrapper$6, __assign({ container: true, alignItems: direction === "vertical" ? "flex-start" : "center", justify: "space-between", direction: direction === "vertical" ? "column" : "row", hasError: !!errorMessage, className: className, withTitle: !!title }, { children: [title && (jsx(StyledTitle, __assign({ direction: direction, size: "xs", weight: 600 }, { children: title.toUpperCase() }))), jsx(Grid, __assign({ item: true, xs: direction === "vertical" ? 12 : "auto" }, { children: jsx(RadioButtonsWithController, __assign({ form: form, name: name }, otherProps)) }))] })), errorMessage && jsx(InputMessage, { variant: "error", msg: errorMessage })] }));
1238
1273
  }
1239
1274
  var StyledContainer = styled.div(templateObject_1$a || (templateObject_1$a = __makeTemplateObject(["\n position: relative;\n"], ["\n position: relative;\n"])));
1240
1275
  var columnDirectionCSS = function (_a) {
@@ -1285,7 +1320,7 @@ function CreatingEntityFromDropdown(_a) {
1285
1320
  return null;
1286
1321
  }
1287
1322
  var handleModalWrapperClick = function (e) { return e.stopPropagation(); };
1288
- return (jsxs$1(Fragment$1, { children: [jsxs$1(StyledWrapper$4, __assign({ container: true, onClick: handleModalOpen, alignItems: "center" }, { children: [jsx(StyledPlusIcon, { width: 12, height: 12 }), jsx(Caption, __assign({ color: "fiftyP", size: "xs", weight: 500 }, { children: creatingLabel }))] })), jsx(StyledModalWrapper, __assign({ onClick: handleModalWrapperClick }, { children: renderCreatingModal({
1323
+ return (jsxs(Fragment$1, { children: [jsxs(StyledWrapper$4, __assign({ container: true, onClick: handleModalOpen, alignItems: "center" }, { children: [jsx(StyledPlusIcon, { width: 12, height: 12 }), jsx(Caption, __assign({ color: "fiftyP", size: "xs", weight: 500 }, { children: creatingLabel }))] })), jsx(StyledModalWrapper, __assign({ onClick: handleModalWrapperClick }, { children: renderCreatingModal({
1289
1324
  open: isModalOpen,
1290
1325
  handleClose: handleModalClose,
1291
1326
  }) }))] }));
@@ -1316,7 +1351,7 @@ function AutocompleteDropdown(props) {
1316
1351
  handleScrollEnd();
1317
1352
  }
1318
1353
  };
1319
- return (jsxs$1(StyledDropdown, __assign({ input: input, buttonRef: inputRef, isOpen: isOpenDropdown, handleClose: handleCloseDropdown, onScroll: handleScroll, endComponent: jsx(CreatingEntityFromDropdown, { creatingLabel: creatingLabel, renderCreatingModal: renderCreatingModal }) }, { children: [options.map(function (option, key) { return (jsx(AutocompleteOption$1, { option: option, renderOption: renderOption, handleSelect: handleSelect, index: key }, key)); }), isLoading && jsx(StyledLoading, { height: "auto" })] })));
1354
+ return (jsxs(StyledDropdown, __assign({ input: input, buttonRef: inputRef, isOpen: isOpenDropdown, handleClose: handleCloseDropdown, onScroll: handleScroll, endComponent: jsx(CreatingEntityFromDropdown, { creatingLabel: creatingLabel, renderCreatingModal: renderCreatingModal }) }, { children: [options.map(function (option, key) { return (jsx(AutocompleteOption$1, { option: option, renderOption: renderOption, handleSelect: handleSelect, index: key }, key)); }), isLoading && jsx(StyledLoading, { height: "auto" })] })));
1320
1355
  }
1321
1356
  var StyledDropdown = styled(InputDropdown)(templateObject_1$6 || (templateObject_1$6 = __makeTemplateObject(["\n .KUI-InputDropdown_scroll {\n max-height: 142px;\n padding: 0 4px;\n }\n"], ["\n .KUI-InputDropdown_scroll {\n max-height: 142px;\n padding: 0 4px;\n }\n"])));
1322
1357
  var StyledLoading = styled(Loading)(templateObject_2$4 || (templateObject_2$4 = __makeTemplateObject(["\n position: sticky;\n bottom: 30px;\n"], ["\n position: sticky;\n bottom: 30px;\n"])));
@@ -1367,9 +1402,9 @@ function InputWithAutocomplete(_a) {
1367
1402
  onOpen(isOpenDropdown);
1368
1403
  }, [isOpenDropdown]);
1369
1404
  var forwardRef = useForkRef(inputRef, inputRefProps);
1370
- return (jsxs(StyledWrapper$3, { children: [isLabelLoading && (jsx$1(StyledLoadingWrapper, { children: jsx$1(Loading, { height: "100%" }) })), jsx$1(AutocompleteDropdown, { renderOption: renderOption, options: options, inputRef: {
1405
+ return (jsxs$1(StyledWrapper$3, { children: [isLabelLoading && (jsx$1(StyledLoadingWrapper, { children: jsx$1(Loading, { height: "100%" }) })), jsx$1(AutocompleteDropdown, { renderOption: renderOption, options: options, inputRef: {
1371
1406
  current: (_b = inputRef.current) === null || _b === void 0 ? void 0 : _b.parentElement,
1372
- }, isOpenDropdown: isOpenDropdown, handleCloseDropdown: handleCloseDropdown, handleSelect: handleSelect, isLoading: isLoading, handleScrollEnd: handleScrollEnd, creatingLabel: creatingLabel, renderCreatingModal: renderCreatingModal, input: jsx$1(StyledInput$2, __assign({ form: form, onInput: handleSearch, onFocus: handleOpenDropdown, name: name, disabled: disabled, ref: forwardRef, isDropdownOpen: isOpenDropdown }, inputProps, { endIcon: !disabled && (jsxs(Grid, __assign({ container: true, alignItems: "center", onClick: handleDropdownToggle }, { children: [jsx$1(Box, __assign({ mr: 2 }, { children: endComponent })), inputProps.endIcon ||
1407
+ }, isOpenDropdown: isOpenDropdown, handleCloseDropdown: handleCloseDropdown, handleSelect: handleSelect, isLoading: isLoading, handleScrollEnd: handleScrollEnd, creatingLabel: creatingLabel, renderCreatingModal: renderCreatingModal, input: jsx$1(StyledInput$2, __assign({ form: form, onInput: handleSearch, onFocus: handleOpenDropdown, name: name, disabled: disabled, ref: forwardRef, isDropdownOpen: isOpenDropdown }, inputProps, { endIcon: !disabled && (jsxs$1(Grid, __assign({ container: true, alignItems: "center", onClick: handleDropdownToggle }, { children: [jsx$1(Box, __assign({ mr: 2 }, { children: endComponent })), inputProps.endIcon ||
1373
1408
  (!disabled && (jsx$1(StyledIcon, { width: 12, height: 13, css: [
1374
1409
  isOpenDropdown && { transform: "rotate(180deg)" },
1375
1410
  ] })))] }))) })) })] }));
@@ -1447,8 +1482,8 @@ function FileItem(_a) {
1447
1482
  setSelectedFile(index !== null && index !== void 0 ? index : 1);
1448
1483
  }
1449
1484
  };
1450
- return (jsxs$1(Fragment$1, { children: [jsxs$1(FileWrapper, __assign({ selected: (selectedFile !== null && selectedFile !== void 0 ? selectedFile : -1) === index, error: (limitTitle && title.length > limitTitle) || !!error, onClick: handleClick, disabled: !!disabled, className: "FileWrapper ".concat(className || "") }, otherProps, { children: [jsx(FileIconWrapper, __assign({ className: "FileIcon_wrapper" }, { children: icon || jsx(FileIcon, {}) })), jsxs$1(ContentWrapper, __assign({ className: "FileContent_wrapper" }, { children: [jsxs$1(InputWrapper, { children: [jsx(Link, __assign({ href: file.url, openInNewWindow: true }, { children: jsx(InputPlaceholder, { children: title }) })), jsx(StyledInput$1, { "data-testid": "file_name", ref: inputRef, disabled: !isEditing, value: title, onChange: handleChange, onBlur: handleBlur, maxLength: 100 })] }), subtitle ||
1451
- (String(file.size) && (jsxs$1(Caption, __assign({ "data-testid": "file_size", size: "xs", color: "fiftyP" }, { children: [Number(file.size), " mb"] }))))] })), jsxs$1(ButtonWrapper, __assign({ className: "FileButtons_wrapper" }, { children: [!disabled && onChange && (jsx(Button, __assign({ isCircle: true, "data-testid": "edit_file_name_btn", size: "xs", variant: "transparentLight", onClick: toggleEdit }, { children: isEditing ? jsx(CheckIcon, {}) : jsx(EditIcon, { width: 18, height: 18 }) }))), onDelete && !disabled && (jsx(Button, __assign({ isCircle: true, "data-testid": "delete_file_btn", size: "xs", variant: "transparentLight", onClick: handleDelete }, { children: jsx(TrashIcon, { width: 18, height: 18 }) })))] }))] })), ((limitTitle && title.length > limitTitle) || error) && (jsx(Box, __assign({ mb: 1 }, { children: jsx(Caption, __assign({ size: "xs", colorGroup: "red", weight: 500 }, { children: error ||
1485
+ return (jsxs(Fragment$1, { children: [jsxs(FileWrapper, __assign({ selected: (selectedFile !== null && selectedFile !== void 0 ? selectedFile : -1) === index, error: (limitTitle && title.length > limitTitle) || !!error, onClick: handleClick, disabled: !!disabled, className: "FileWrapper ".concat(className || "") }, otherProps, { children: [jsx(FileIconWrapper, __assign({ className: "FileIcon_wrapper" }, { children: icon || jsx(FileIcon, {}) })), jsxs(ContentWrapper, __assign({ className: "FileContent_wrapper" }, { children: [jsxs(InputWrapper, { children: [jsx(Link, __assign({ href: file.url, openInNewWindow: true }, { children: jsx(InputPlaceholder, { children: title }) })), jsx(StyledInput$1, { "data-testid": "file_name", ref: inputRef, disabled: !isEditing, value: title, onChange: handleChange, onBlur: handleBlur, maxLength: 100 })] }), subtitle ||
1486
+ (String(file.size) && (jsxs(Caption, __assign({ "data-testid": "file_size", size: "xs", color: "fiftyP" }, { children: [Number(file.size), " mb"] }))))] })), jsxs(ButtonWrapper, __assign({ className: "FileButtons_wrapper" }, { children: [!disabled && onChange && (jsx(Button, __assign({ isCircle: true, "data-testid": "edit_file_name_btn", size: "xs", variant: "transparentLight", onClick: toggleEdit }, { children: isEditing ? jsx(CheckIcon, {}) : jsx(EditIcon, { width: 18, height: 18 }) }))), onDelete && !disabled && (jsx(Button, __assign({ isCircle: true, "data-testid": "delete_file_btn", size: "xs", variant: "transparentLight", onClick: handleDelete }, { children: jsx(TrashIcon, { width: 18, height: 18 }) })))] }))] })), ((limitTitle && title.length > limitTitle) || error) && (jsx(Box, __assign({ mb: 1 }, { children: jsx(Caption, __assign({ size: "xs", colorGroup: "red", weight: 500 }, { children: error ||
1452
1487
  "File upload error. The number of characters in the file name should not exceed 100" })) })))] }));
1453
1488
  }
1454
1489
  FileItem.defaultProps = {
@@ -1584,7 +1619,7 @@ var InputFile = forwardRef(function (props, ref) {
1584
1619
  }
1585
1620
  inputRef.current = elem;
1586
1621
  };
1587
- return (jsxs$1(StyledWrapper$1, { children: [jsx(StyledInput, __assign({ type: "file", onInput: handleChange }, otherProps, { ref: forwardedRef })), file || defaultFileURL ? (jsx(FileItem, { file: formattedFile, onDelete: handleDelete, onChange: withEdit && changeName, error: error, disabled: disabled })) : (jsxs$1(Fragment$1, { children: [jsxs$1(StyledLabel, __assign({ error: !!error, disabled: disabled, container: true, justify: "space-between", alignItems: "center" }, { children: [jsx(StyledContent, __assign({ item: true }, { children: jsxs$1(Caption, __assign({ size: "s", color: "fiftyP" }, { children: [label, isRequired ? " *" : ""] })) })), jsx(Grid, __assign({ item: true }, { children: jsx(StyledButton, __assign({ disabled: disabled, size: "s", onClick: handleClick }, { children: uploadLabel || "Upload" })) }))] })), error && jsx(InputMessage, { variant: "error", msg: error })] }))] }));
1622
+ return (jsxs(StyledWrapper$1, { children: [jsx(StyledInput, __assign({ type: "file", onInput: handleChange }, otherProps, { ref: forwardedRef })), file || defaultFileURL ? (jsx(FileItem, { file: formattedFile, onDelete: handleDelete, onChange: withEdit && changeName, error: error, disabled: disabled })) : (jsxs(Fragment$1, { children: [jsxs(StyledLabel, __assign({ error: !!error, disabled: disabled, container: true, justify: "space-between", alignItems: "center" }, { children: [jsx(StyledContent, __assign({ item: true }, { children: jsxs(Caption, __assign({ size: "s", color: "fiftyP" }, { children: [label, isRequired ? " *" : ""] })) })), jsx(Grid, __assign({ item: true }, { children: jsx(StyledButton, __assign({ disabled: disabled, size: "s", onClick: handleClick }, { children: uploadLabel || "Upload" })) }))] })), error && jsx(InputMessage, { variant: "error", msg: error })] }))] }));
1588
1623
  });
1589
1624
  InputFile.defaultProps = {
1590
1625
  withEdit: true,
@@ -1624,7 +1659,7 @@ var CheckboxWithController = forwardRef(function (props, ref) {
1624
1659
 
1625
1660
  function CheckboxGroupWithTitle(_a) {
1626
1661
  var title = _a.title, options = _a.options, form = _a.form; _a.name; var otherProps = __rest(_a, ["title", "options", "form", "name"]);
1627
- return (jsxs$1(StyledWrapper, __assign({ container: true, alignItems: "center", justify: "space-between" }, { children: [jsx(Grid, __assign({ item: true }, { children: jsx(Caption, __assign({ size: "s", weight: 500, color: "fiftyP" }, { children: title })) })), jsx(Grid, __assign({ item: true }, { children: jsx(Grid, __assign({ container: true }, { children: options.map(function (option) { return (jsx(StyledCheckbox, __assign({ name: option.name, label: jsx(Caption, __assign({ size: "s", color: "fiftyP", weight: 500 }, { children: option.label })), form: form, testId: option.name }, otherProps), option.name)); }) })) }))] })));
1662
+ return (jsxs(StyledWrapper, __assign({ container: true, alignItems: "center", justify: "space-between" }, { children: [jsx(Grid, __assign({ item: true }, { children: jsx(Caption, __assign({ size: "s", weight: 500, color: "fiftyP" }, { children: title })) })), jsx(Grid, __assign({ item: true }, { children: jsx(Grid, __assign({ container: true }, { children: options.map(function (option) { return (jsx(StyledCheckbox, __assign({ name: option.name, label: jsx(Caption, __assign({ size: "s", color: "fiftyP", weight: 500 }, { children: option.label })), form: form, testId: option.name }, otherProps), option.name)); }) })) }))] })));
1628
1663
  }
1629
1664
  var StyledCheckbox = styled(CheckboxWithController)(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n &:not(:last-child) {\n margin-right: 22px;\n }\n"], ["\n &:not(:last-child) {\n margin-right: 22px;\n }\n"])));
1630
1665
  var StyledWrapper = styled(Grid)(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n padding: 3px 16px;\n border: 1px solid ", ";\n border-radius: 66px;\n height: 40px;\n background: white;\n"], ["\n padding: 3px 16px;\n border: 1px solid ", ";\n border-radius: 66px;\n height: 40px;\n background: white;\n"])), theme.palette.grey.fifteenB);