@estiva-app/ui 0.12.4 → 0.12.5

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/dist/Popover.d.ts CHANGED
@@ -90,6 +90,27 @@ export interface PopoverProps {
90
90
  children: ReactNode;
91
91
  /** On the panel's surface — its width, its internal rhythm. */
92
92
  className?: string;
93
+ /**
94
+ * A cap on the scrolling box, as a class — `max-h-[360px]`. Without one the
95
+ * panel grows to the room the positioner has, which is the right default for
96
+ * a panel that is as tall as its content.
97
+ *
98
+ * **It cannot go on `className`.** That lands on the panel, and the panel's
99
+ * children sit inside a `ScrollArea` whose viewport carries its own cap — so
100
+ * a `max-h` on the panel is overrun by the viewport and the content draws
101
+ * straight through the panel's border (measured with Peek's `/` menu,
102
+ * 2026-09-12: a 400px panel with 559px of rows hanging out of it). The cap
103
+ * belongs on the viewport, as `DialogShell` takes `bodyMaxHeight`.
104
+ *
105
+ * **When a panel needs one.** A panel taller than the room above *and* below
106
+ * its anchor is not flipped by the positioner — it is moved to the side of
107
+ * the anchor, which for a type-ahead over a caret is not where it belongs.
108
+ * A cap keeps the choice between above and below.
109
+ *
110
+ * It replaces the available-height cap rather than adding to it, so a caller
111
+ * that sets one owns it.
112
+ */
113
+ maxHeight?: string;
93
114
  }
94
- export declare function Popover({ trigger, anchor, align, side, open, onOpenChange, finalFocus, actionsRef, ariaLabel, children, className }: PopoverProps): import("react").JSX.Element;
115
+ export declare function Popover({ trigger, anchor, align, side, open, onOpenChange, finalFocus, actionsRef, ariaLabel, children, className, maxHeight }: PopoverProps): import("react").JSX.Element;
95
116
  //# sourceMappingURL=Popover.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Popover.d.ts","sourceRoot":"","sources":["../src/Popover.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAW,KAAK,YAAY,EAAE,KAAK,SAAS,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAOlF;;;;;;;;;;;;;;;;;;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3B;;;;;;;;OAQG;IACH,OAAO,CAAC,EAAE,YAAY,CAAA;IACtB;;;;;;;;;;OAUG;IACH,MAAM,CAAC,EAAE,WAAW,GAAG,OAAO,GAAG,IAAI,CAAA;IACrC;;;;;;;;;OASG;IACH,KAAK,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,CAAA;IACnC;;;;;;;;OAQG;IACH,IAAI,CAAC,EAAE,KAAK,GAAG,QAAQ,CAAA;IACvB;kFAC8E;IAC9E,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI,CAAA;IACtC;;;;;;OAMG;IACH,UAAU,CAAC,EAAE,SAAS,CAAC,WAAW,GAAG,IAAI,CAAC,CAAA;IAC1C;kEAC8D;IAC9D,UAAU,CAAC,EAAE,SAAS,CAAC;QAAE,KAAK,EAAE,MAAM,IAAI,CAAC;QAAC,OAAO,EAAE,MAAM,IAAI,CAAA;KAAE,GAAG,IAAI,CAAC,CAAA;IACzE;uDACmD;IACnD,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,QAAQ,EAAE,SAAS,CAAA;IACnB,+DAA+D;IAC/D,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB;;;;;;;;;;;;;;;;;;;OAmBG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAOD,wBAAgB,OAAO,CAAC,EAAE,OAAO,EAAE,MAAM,EAAE,KAAc,EAAE,IAAe,EAAE,IAAI,EAAE,YAAY,EAAE,UAAU,EAAE,UAAU,EAAE,SAAS,EAAE,QAAQ,EAAE,SAAS,EAAE,SAAS,EAAE,EAAE,YAAY,+BAsEhL"}
package/dist/index.js CHANGED
@@ -1598,7 +1598,7 @@ import { Popover as BasePopover } from "@base-ui/react/popover";
1598
1598
  import { jsx as jsx31, jsxs as jsxs22 } from "react/jsx-runtime";
1599
1599
  var GAP5 = 4;
1600
1600
  var VIEWPORT_PAD4 = 8;
1601
- function Popover({ trigger, anchor, align = "left", side = "bottom", open, onOpenChange, finalFocus, actionsRef, ariaLabel, children, className }) {
1601
+ function Popover({ trigger, anchor, align = "left", side = "bottom", open, onOpenChange, finalFocus, actionsRef, ariaLabel, children, className, maxHeight }) {
1602
1602
  const anchorTarget = useMemo2(() => {
1603
1603
  if (!anchor) return void 0;
1604
1604
  if (anchor instanceof Element) return anchor;
@@ -1630,7 +1630,14 @@ function Popover({ trigger, anchor, align = "left", side = "bottom", open, onOpe
1630
1630
  finalFocus,
1631
1631
  className: cn("min-w-[180px] outline-none", className),
1632
1632
  render: /* @__PURE__ */ jsx31(MenuPanel, {}),
1633
- children: /* @__PURE__ */ jsx31(ScrollArea, { viewportClassName: "max-h-[calc(var(--available-height)_-_1rem)]", contentClassName: "flex flex-col [&>[role=separator]]:mx-0", children })
1633
+ children: /* @__PURE__ */ jsx31(
1634
+ ScrollArea,
1635
+ {
1636
+ viewportClassName: maxHeight ?? "max-h-[calc(var(--available-height)_-_1rem)]",
1637
+ contentClassName: "flex flex-col [&>[role=separator]]:mx-0",
1638
+ children
1639
+ }
1640
+ )
1634
1641
  }
1635
1642
  )
1636
1643
  }