@loomhq/lens 11.10.0 → 11.11.0

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 (2) hide show
  1. package/dist/index.js +13 -5
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -3466,7 +3466,7 @@ function SvgClose(props) {
3466
3466
 
3467
3467
  // src/components/modal/modal.tsx
3468
3468
  import styled19 from "@emotion/styled";
3469
- var modalCardHeight = "70vh";
3469
+ var DEFAULT_MODAL_CARD_HEIGHT = "70vh";
3470
3470
  var ContentWrapper = styled19.div`
3471
3471
  display: grid;
3472
3472
  grid-template-rows: ${(props) => props.rows};
@@ -3539,19 +3539,26 @@ var ChildrenSection2 = styled19.div`
3539
3539
  `;
3540
3540
  var ModalCardChildrenSection = styled19.div`
3541
3541
  overflow: auto;
3542
- max-height: ${modalCardHeight};
3542
+
3543
+ ${(props) => getMaxHeight(props.maxHeight)};
3543
3544
 
3544
3545
  & > * {
3545
- max-height: ${modalCardHeight};
3546
+ ${(props) => getMaxHeight(props.maxHeight)};
3546
3547
  }
3547
3548
  `;
3549
+ var getMaxHeight = (maxHeight) => {
3550
+ if (typeof maxHeight === "number") {
3551
+ return getSize("max-height", maxHeight);
3552
+ }
3553
+ return "max-height: " + maxHeight;
3554
+ };
3548
3555
  var ModalCard = (_a) => {
3549
3556
  var _b = _a, {
3550
3557
  children,
3551
3558
  onCloseClick,
3552
3559
  isOpen,
3553
3560
  maxWidth = 60,
3554
- maxHeight = "70vh",
3561
+ maxHeight = DEFAULT_MODAL_CARD_HEIGHT,
3555
3562
  placement = "center",
3556
3563
  ariaLabel,
3557
3564
  ref,
@@ -3613,7 +3620,8 @@ var ModalCard = (_a) => {
3613
3620
  /* @__PURE__ */ React25.createElement(
3614
3621
  ModalCardChildrenSection,
3615
3622
  {
3616
- tabIndex: removeClose ? 0 : -1
3623
+ tabIndex: removeClose ? 0 : -1,
3624
+ maxHeight
3617
3625
  },
3618
3626
  children
3619
3627
  )
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@loomhq/lens",
3
- "version": "11.10.0",
3
+ "version": "11.11.0",
4
4
  "engines": {
5
5
  "pnpm": "^8.9.2"
6
6
  },