mimir-ui-kit 1.26.1 → 1.26.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -1 +1 @@
1
- ._item_1k68o_2{display:flex;flex-direction:column;gap:var(--accordion-item-space);font-size:var(--accordion-item-font-size);border:none}._m_1k68o_10{--accordion-item-space: var(--space-xs);--accordion-item-font-size: var(--size-text-l)}._l_1k68o_15{--accordion-item-space: var(--space-2xs);--accordion-item-font-size: var(--size-text-m)}
1
+ ._item_fo923_2{display:flex;flex-direction:column;gap:var(--accordion-item-space);font-size:var(--accordion-item-font-size);border:none}._m_fo923_10{--accordion-item-space: var(--space-xs);--accordion-item-font-size: var(--size-text-l)}._s_fo923_15{--accordion-item-space: var(--space-2xs);--accordion-item-font-size: var(--size-text-m)}
@@ -7,7 +7,7 @@ export type TAccordionProps = {
7
7
  /** Содержимое аккордеона */
8
8
  children: ReactNode;
9
9
  /** Размер аккордеона */
10
- size?: EAccordionSize;
10
+ size?: EAccordionSize | `${EAccordionSize}`;
11
11
  /** Преобразование заголовка в верхний регистр */
12
12
  titleUppercase?: boolean;
13
13
  /** Тип кнопки аккордеона */
@@ -3,6 +3,6 @@ import { EAccordionSize } from '../constants';
3
3
 
4
4
  export type TAccordionItemProps = {
5
5
  children: React.ReactNode;
6
- size: EAccordionSize;
6
+ size: EAccordionSize | `${EAccordionSize}`;
7
7
  };
8
8
  export declare const AccordionItem: FC<TAccordionItemProps>;
@@ -1,12 +1,12 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { c as classNames } from "../../../index-CweZ_OcN.js";
3
- import '../../../assets/AccordionItem.css';const item = "_item_1k68o_2";
4
- const m = "_m_1k68o_10";
5
- const l = "_l_1k68o_15";
3
+ import '../../../assets/AccordionItem.css';const item = "_item_fo923_2";
4
+ const m = "_m_fo923_10";
5
+ const s = "_s_fo923_15";
6
6
  const cls = {
7
7
  item,
8
8
  m,
9
- l
9
+ s
10
10
  };
11
11
  const AccordionItem = ({ children, size }) => {
12
12
  return /* @__PURE__ */ jsx("div", { className: classNames(cls.item, cls[size]), children });
@@ -52,9 +52,13 @@ type TProps = {
52
52
  * Дополнительный класс для inner.
53
53
  */
54
54
  classNameInner?: string;
55
+ /**
56
+ * Дополнительный класс для footer.
57
+ */
58
+ classNameFooter?: string;
55
59
  };
56
60
  /**
57
61
  * Компонент шторки, который может выезжать слева, справа или внизу.
58
62
  */
59
- export declare const Drawer: ({ isOpen, onClose, title, className, unmount, isLoading, stickyHeader, fullBottomHeight, position, paddingRight, footer, children, classNameInner }: PropsWithChildren<TProps>) => import("react/jsx-runtime").JSX.Element | null;
63
+ export declare const Drawer: ({ isOpen, onClose, title, className, unmount, isLoading, stickyHeader, fullBottomHeight, position, paddingRight, footer, children, classNameInner, classNameFooter }: PropsWithChildren<TProps>) => import("react/jsx-runtime").JSX.Element | null;
60
64
  export {};
@@ -61,7 +61,8 @@ const Drawer = ({
61
61
  paddingRight = 8,
62
62
  footer: footer2,
63
63
  children,
64
- classNameInner
64
+ classNameInner,
65
+ classNameFooter
65
66
  }) => {
66
67
  const [isClosing, setIsClosing] = useState(false);
67
68
  const [isMounted, setIsMounted] = useState(false);
@@ -152,7 +153,7 @@ const Drawer = ({
152
153
  }
153
154
  ),
154
155
  /* @__PURE__ */ jsx("div", { className: classNames(cls.inner, classNameInner), children }),
155
- /* @__PURE__ */ jsx("footer", { className: cls.footer, children: typeof footer2 === "function" ? footer2({ handleClose }) : footer2 || /* @__PURE__ */ jsx(
156
+ /* @__PURE__ */ jsx("footer", { className: classNames(cls.footer, classNameFooter), children: typeof footer2 === "function" ? footer2({ handleClose }) : footer2 || /* @__PURE__ */ jsx(
156
157
  Button,
157
158
  {
158
159
  size: isMobile ? EButtonSize.M : EButtonSize.XXL,
@@ -3821,8 +3821,13 @@ const SelectSearch = forwardRef(
3821
3821
  ) : items;
3822
3822
  }, [inputValue, items, value, filterOnSearch]);
3823
3823
  const handleOneChange = (newValue) => {
3824
- setInputValue(newValue.name);
3825
- onChange == null ? void 0 : onChange(newValue);
3824
+ if (newValue) {
3825
+ setInputValue(newValue.name);
3826
+ onChange == null ? void 0 : onChange(newValue);
3827
+ } else {
3828
+ setInputValue("");
3829
+ onChange == null ? void 0 : onChange({ id: "", name: "" });
3830
+ }
3826
3831
  };
3827
3832
  const handleInputChange = useCallback(
3828
3833
  (event) => {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "mimir-ui-kit",
3
3
  "private": false,
4
- "version": "1.26.1",
4
+ "version": "1.26.3",
5
5
  "type": "module",
6
6
  "exports": {
7
7
  ".": {