@luminati-io/uikit 3.0.15 → 3.0.16

Sign up to get free protection for your applications and to get access to all the features.
@@ -27143,7 +27143,7 @@ var StyledWrapper = styled_components__WEBPACK_IMPORTED_MODULE_2___default()(_la
27143
27143
  displayName: "StyledWrapper",
27144
27144
  componentId: "sc-1nggvo0-0"
27145
27145
  })(["background-color:", ";border-radius:", ";display:grid;grid-tempalte-rows:1fr auto 1fr;font-family:", ";min-width:200px;max-width:", ";width:", ";"], _theme__WEBPACK_IMPORTED_MODULE_4__["default"].color.white, _theme__WEBPACK_IMPORTED_MODULE_4__["default"].spacing['02'], _theme__WEBPACK_IMPORTED_MODULE_4__["default"].font_family.sans, MODAL_WIDTHS.full, function (props) {
27146
- return MODAL_WIDTHS[props.size];
27146
+ return MODAL_WIDTHS[props.$size];
27147
27147
  });
27148
27148
  var StyledHeaderWrapper = styled_components__WEBPACK_IMPORTED_MODULE_2___default()(_layout__WEBPACK_IMPORTED_MODULE_3__.Flex).attrs({
27149
27149
  padding: "".concat(_theme__WEBPACK_IMPORTED_MODULE_4__["default"].spacing['06'], " ").concat(_theme__WEBPACK_IMPORTED_MODULE_4__["default"].spacing['05'], " 0 ").concat(_theme__WEBPACK_IMPORTED_MODULE_4__["default"].spacing['07']),
@@ -27158,13 +27158,17 @@ var StyledContentWrapper = styled_components__WEBPACK_IMPORTED_MODULE_2___defaul
27158
27158
  }).withConfig({
27159
27159
  displayName: "StyledContentWrapper",
27160
27160
  componentId: "sc-1nggvo0-2"
27161
- })(["overflow-y:auto;::-webkit-scrollbar{width:", ";}::-webkit-scrollbar-thumb{background-color:", ";border-radius:", ";border:", " solid transparent;background-clip:content-box;}"], _theme__WEBPACK_IMPORTED_MODULE_4__["default"].spacing['06'], _theme__WEBPACK_IMPORTED_MODULE_4__["default"].color.gray_8, _theme__WEBPACK_IMPORTED_MODULE_4__["default"].spacing['06'], _theme__WEBPACK_IMPORTED_MODULE_4__["default"].spacing['03']);
27161
+ })(["overflow-y:auto;", " ", " ", ""], _theme__WEBPACK_IMPORTED_MODULE_4__["default"].scrollbars.thin, function (props) {
27162
+ return props.$borders && props.$borders.top ? "border-top: 1px solid ".concat(_theme__WEBPACK_IMPORTED_MODULE_4__["default"].color.gray_4, ";") : '';
27163
+ }, function (props) {
27164
+ return props.$borders && props.$borders.bottom ? "border-bottom: 1px solid ".concat(_theme__WEBPACK_IMPORTED_MODULE_4__["default"].color.gray_4, ";") : '';
27165
+ });
27162
27166
  var StyledFooterWrapper = styled_components__WEBPACK_IMPORTED_MODULE_2___default()(_layout__WEBPACK_IMPORTED_MODULE_3__.Flex).attrs({
27163
27167
  padding: "".concat(_theme__WEBPACK_IMPORTED_MODULE_4__["default"].spacing['04'], " ").concat(_theme__WEBPACK_IMPORTED_MODULE_4__["default"].spacing['07'])
27164
27168
  }).withConfig({
27165
27169
  displayName: "StyledFooterWrapper",
27166
27170
  componentId: "sc-1nggvo0-3"
27167
- })(["border-top:1px solid ", ";"], _theme__WEBPACK_IMPORTED_MODULE_4__["default"].color.gray_4);
27171
+ })([""]);
27168
27172
  var ModalBase = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_1__.forwardRef)(function (props, ref) {
27169
27173
  var id = props.id,
27170
27174
  className = props.className,
@@ -27173,15 +27177,21 @@ var ModalBase = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_1__.forwardRef)(f
27173
27177
  content = props.content,
27174
27178
  footer = props.footer,
27175
27179
  size = props.size,
27176
- shadow = props.shadow;
27180
+ shadow = props.shadow,
27181
+ _props$borders = props.borders,
27182
+ borders = _props$borders === void 0 ? {
27183
+ bottom: true
27184
+ } : _props$borders;
27177
27185
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(StyledWrapper, {
27178
27186
  id: id,
27179
27187
  className: className,
27180
- size: size,
27188
+ $size: size,
27181
27189
  box_shadow: shadow,
27182
27190
  "data-testid": testId,
27183
27191
  ref: ref
27184
- }, header && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(StyledHeaderWrapper, null, header), content && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(StyledContentWrapper, null, content), footer && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(StyledFooterWrapper, null, footer));
27192
+ }, header && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(StyledHeaderWrapper, null, header), content && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(StyledContentWrapper, {
27193
+ $borders: borders
27194
+ }, content), footer && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_1___default().createElement(StyledFooterWrapper, null, footer));
27185
27195
  });
27186
27196
  ModalBase.displayName = 'ModalBase';
27187
27197
  ModalBase.propTypes = {
@@ -27498,8 +27508,7 @@ var withBackdrop = function withBackdrop(Comp) {
27498
27508
  _props$zIndex = props.zIndex,
27499
27509
  zIndex = _props$zIndex === void 0 ? _constants__WEBPACK_IMPORTED_MODULE_6__.Z_INDEX.backdrop : _props$zIndex,
27500
27510
  onOutsideClick = props.onOutsideClick,
27501
- _props$swallowOutside = props.swallowOutsideClick,
27502
- swallowOutsideClick = _props$swallowOutside === void 0 ? true : _props$swallowOutside,
27511
+ swallowOutsideClick = props.swallowOutsideClick,
27503
27512
  restProps = _objectWithoutProperties(props, _excluded);
27504
27513
  var popperElement = (0,react__WEBPACK_IMPORTED_MODULE_0__.useRef)(null);
27505
27514
  var _useState = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(false),
@@ -27531,22 +27540,20 @@ var withBackdrop = function withBackdrop(Comp) {
27531
27540
  }, [show]);
27532
27541
  var hideAndStopEvt = (0,react__WEBPACK_IMPORTED_MODULE_0__.useCallback)(function (evt) {
27533
27542
  if (!visible) return;
27534
- if (swallowOutsideClick) {
27535
- evt.stopPropagation();
27536
- evt.preventDefault();
27537
- }
27538
27543
  if (onOutsideClick) onOutsideClick(evt);
27544
+ if (!swallowOutsideClick) return;
27545
+ evt.stopPropagation();
27546
+ evt.preventDefault();
27539
27547
  }, [visible, swallowOutsideClick, onOutsideClick]);
27540
27548
  (0,_hooks__WEBPACK_IMPORTED_MODULE_5__.useOutsideClick)(popperElement.current, hideAndStopEvt);
27541
- console.log(popperElement);
27542
27549
  if (!mount) return null;
27543
27550
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(PopupContainer, {
27544
- zIndex: zIndex
27551
+ $zIndex: zIndex
27545
27552
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(StyledBackdrop, {
27546
- show: visible
27553
+ $show: visible
27547
27554
  }), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(CompContainer, {
27548
- show: visible,
27549
- zIndex: zIndex + 1
27555
+ $show: visible,
27556
+ $zIndex: zIndex + 1
27550
27557
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(Comp, _extends({
27551
27558
  ref: popperElement
27552
27559
  }, restProps))));
@@ -27558,13 +27565,13 @@ var StyledBackdrop = styled_components__WEBPACK_IMPORTED_MODULE_1___default()(_l
27558
27565
  displayName: "StyledBackdrop",
27559
27566
  componentId: "sc-upusus-0"
27560
27567
  })(["width:100%;height:100%;background-color:", ";opacity:", ";transition:opacity .15s linear;"], _theme__WEBPACK_IMPORTED_MODULE_3__["default"].color.black, function (props) {
27561
- return props.show ? 0.5 : 0;
27568
+ return props.$show ? 0.5 : 0;
27562
27569
  });
27563
27570
  var PopupContainer = styled_components__WEBPACK_IMPORTED_MODULE_1___default()(_layout__WEBPACK_IMPORTED_MODULE_2__.Box).withConfig({
27564
27571
  displayName: "PopupContainer",
27565
27572
  componentId: "sc-upusus-1"
27566
27573
  })(["position:realtive;position:fixed;top:0;right:0;bottom:0;left:0;z-index:", ";"], function (props) {
27567
- return props.zIndex;
27574
+ return props.$zIndex;
27568
27575
  });
27569
27576
  var CompContainer = styled_components__WEBPACK_IMPORTED_MODULE_1___default()(_layout__WEBPACK_IMPORTED_MODULE_2__.Flex).attrs({
27570
27577
  justify_content: 'center',
@@ -27573,11 +27580,11 @@ var CompContainer = styled_components__WEBPACK_IMPORTED_MODULE_1___default()(_la
27573
27580
  displayName: "CompContainer",
27574
27581
  componentId: "sc-upusus-2"
27575
27582
  })(["position:absolute;top:10vh;max-height:80vh;z-index:", ";opacity:", ";transform:translate(0,", ");transition:opacity 0.15s linear,transform 0.3s ease-out;"], function (props) {
27576
- return props.zIndex;
27583
+ return props.$zIndex;
27577
27584
  }, function (props) {
27578
- return props.show ? 1 : 0;
27585
+ return props.$show ? 1 : 0;
27579
27586
  }, function (props) {
27580
- return props.show ? '0' : '-25%';
27587
+ return props.$show ? '0' : '-25%';
27581
27588
  });
27582
27589
  /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (withBackdrop);
27583
27590