@ssa-ui-kit/core 2.20.3 → 2.20.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,3 +1,3 @@
1
1
  import { ModalProps } from './types';
2
- declare const Modal: ({ isOpen: isInitOpen, ...rest }: ModalProps) => import("@emotion/react/jsx-runtime").JSX.Element;
2
+ declare const Modal: ({ isOpen, ...rest }: ModalProps) => import("@emotion/react/jsx-runtime").JSX.Element;
3
3
  export default Modal;
package/dist/index.js CHANGED
@@ -5230,12 +5230,17 @@ const ModalContext = /*#__PURE__*/(0,external_react_namespaceObject.createContex
5230
5230
 
5231
5231
 
5232
5232
  const Modal = ({
5233
- isOpen: isInitOpen,
5233
+ isOpen,
5234
5234
  ...rest
5235
5235
  }) => {
5236
- const [isOpen, setIsOpen] = (0,external_react_namespaceObject.useState)(isInitOpen || false);
5236
+ const [modalIsOpen, setModalIsOpen] = (0,external_react_namespaceObject.useState)(isOpen || false);
5237
+ (0,external_react_namespaceObject.useEffect)(() => {
5238
+ if (isOpen !== undefined && isOpen !== modalIsOpen) {
5239
+ setModalIsOpen(isOpen);
5240
+ }
5241
+ }, [isOpen]);
5237
5242
  return (0,jsx_runtime_namespaceObject.jsx)(ModalContext.Provider, {
5238
- value: [isOpen, setIsOpen],
5243
+ value: [modalIsOpen, setModalIsOpen],
5239
5244
  ...rest
5240
5245
  });
5241
5246
  };
@@ -7495,7 +7500,7 @@ const TableCell = /*#__PURE__*/base_default()("td", true ? {
7495
7500
  target: "e9xnb9j0"
7496
7501
  } : 0)("display:table-cell;vertical-align:inherit;text-align:", ({
7497
7502
  align
7498
- }) => align ? align : 'left', ";border:none;padding:0 16px;background:#fff;font-size:12px;font-weight:500;white-space:nowrap;height:44px;& a{display:flex;align-items:center;height:44px;padding:0 18px;}&:first-of-type a{padding-left:16px;}", ({
7503
+ }) => align ? align : 'left', ";border:none;padding:0 16px;background:#fff;font-size:12px;font-weight:500;white-space:nowrap;height:44px;", ({
7499
7504
  theme
7500
7505
  }) => theme.mediaQueries.lg, "{font-size:14px;}" + ( true ? "" : 0));
7501
7506
  /* harmony default export */ const TableCell_TableCell = (TableCell);