@opengovsg/oui 0.0.58 → 0.0.59

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.
@@ -50,7 +50,7 @@ const AvatarGroup = utils.forwardRef((props, ref) => {
50
50
  remainingCount,
51
51
  renderCount
52
52
  ]);
53
- return /* @__PURE__ */ jsxRuntime.jsx(Component, { ...getAvatarGroupProps(), children: /* @__PURE__ */ jsxRuntime.jsxs(avatarGroupContext.AvatarGroupProvider, { value: context, children: [
53
+ return /* @__PURE__ */ jsxRuntime.jsx(Component, { ...getAvatarGroupProps(), children: /* @__PURE__ */ jsxRuntime.jsxs(avatarGroupContext.AvatarGroupProvider.Provider, { value: context, children: [
54
54
  clones,
55
55
  renderedCount
56
56
  ] }) });
@@ -48,7 +48,7 @@ const AvatarRoot = utils.forwardRef(
48
48
  const [imageLoadingStatus, setImageLoadingStatus] = $670gB$react.useState("idle");
49
49
  const Component = as || "span";
50
50
  return /* @__PURE__ */ jsxRuntime.jsx(
51
- avatarContext.AvatarContext,
51
+ avatarContext.AvatarContext.Provider,
52
52
  {
53
53
  value: {
54
54
  imageLoadingStatus,
@@ -26,12 +26,40 @@ function MenuInner(originalProps, ref) {
26
26
  originalProps,
27
27
  ouiTheme.menuStyles.variantKeys
28
28
  );
29
- const { className, classNames, placement, ...rest } = props;
29
+ const {
30
+ className,
31
+ classNames,
32
+ placement,
33
+ boundaryElement,
34
+ scrollRef,
35
+ shouldFlip,
36
+ maxHeight,
37
+ containerPadding,
38
+ offset,
39
+ crossOffset,
40
+ shouldUpdatePosition,
41
+ arrowBoundaryOffset,
42
+ triggerRef,
43
+ ...rest
44
+ } = props;
45
+ const popoverProps = {
46
+ placement,
47
+ boundaryElement,
48
+ scrollRef,
49
+ shouldFlip,
50
+ maxHeight,
51
+ containerPadding,
52
+ offset,
53
+ crossOffset,
54
+ shouldUpdatePosition,
55
+ arrowBoundaryOffset,
56
+ triggerRef
57
+ };
30
58
  const styles = ouiTheme.menuStyles(variantProps);
31
59
  return /* @__PURE__ */ jsxRuntime.jsx(reactAriaComponents.Provider, { values: [[MenuVariantContext, variantProps]], children: /* @__PURE__ */ jsxRuntime.jsx(
32
60
  popover.Popover,
33
61
  {
34
- placement,
62
+ ...popoverProps,
35
63
  className: styles.popover({ className: classNames?.popover }),
36
64
  children: /* @__PURE__ */ jsxRuntime.jsx(
37
65
  reactAriaComponents.Menu,
@@ -34,7 +34,7 @@ const Navbar = utils.forwardRef((props, ref) => {
34
34
  /* @__PURE__ */ jsxRuntime.jsx("header", { ...context.getWrapperProps(), children: childrenWithoutMenu }),
35
35
  menu
36
36
  ] });
37
- return /* @__PURE__ */ jsxRuntime.jsx(navbarContext.NavbarProvider, { value: context, children: /* @__PURE__ */ jsxRuntime.jsx(reactAria.FocusScope, { contain: context.isMenuOpen, children: context.shouldShowOnScrollUp ? /* @__PURE__ */ jsxRuntime.jsx(react.LazyMotion, { features: react.domAnimation, children: /* @__PURE__ */ jsxRuntime.jsx(
37
+ return /* @__PURE__ */ jsxRuntime.jsx(navbarContext.NavbarProvider.Provider, { value: context, children: /* @__PURE__ */ jsxRuntime.jsx(reactAria.FocusScope, { contain: context.isMenuOpen, children: context.shouldShowOnScrollUp ? /* @__PURE__ */ jsxRuntime.jsx(react.LazyMotion, { features: react.domAnimation, children: /* @__PURE__ */ jsxRuntime.jsx(
38
38
  react.m.nav,
39
39
  {
40
40
  animate: context.isNavbarHidden ? "hidden" : "visible",
@@ -3,52 +3,9 @@
3
3
  'use strict';
4
4
 
5
5
  var jsxRuntime = require('react/jsx-runtime');
6
- var $670gB$react = require('react');
7
6
  var reactAriaComponents = require('react-aria-components');
8
7
  var ouiTheme = require('@opengovsg/oui-theme');
9
8
 
10
- const REFLOW_INTERVAL_MS = 50;
11
- const REFLOW_MAX_ATTEMPTS = 20;
12
- const useReflowOnContentChange = () => {
13
- const cleanupRef = $670gB$react.useRef(null);
14
- return $670gB$react.useCallback((el) => {
15
- cleanupRef.current?.();
16
- cleanupRef.current = null;
17
- if (!el) return;
18
- let timer = 0;
19
- let attempts = 0;
20
- let observer = null;
21
- const settle = () => {
22
- observer?.disconnect();
23
- observer = null;
24
- };
25
- const poll = () => {
26
- if (el.offsetHeight > 0) return settle();
27
- window.dispatchEvent(new Event("resize"));
28
- attempts += 1;
29
- if (el.offsetHeight > 0) return settle();
30
- if (attempts >= REFLOW_MAX_ATTEMPTS) return;
31
- timer = window.setTimeout(poll, REFLOW_INTERVAL_MS);
32
- };
33
- const start = () => {
34
- clearTimeout(timer);
35
- attempts = 0;
36
- timer = window.setTimeout(poll, 0);
37
- };
38
- start();
39
- observer = new MutationObserver(start);
40
- observer.observe(el, {
41
- childList: true,
42
- subtree: true,
43
- characterData: true
44
- });
45
- cleanupRef.current = () => {
46
- clearTimeout(timer);
47
- observer?.disconnect();
48
- observer = null;
49
- };
50
- }, []);
51
- };
52
9
  const Popover = ({
53
10
  children,
54
11
  showArrow,
@@ -60,32 +17,33 @@ const Popover = ({
60
17
  const isSubmenu = popoverContext?.trigger === "SubmenuTrigger";
61
18
  let offset = showArrow ? 12 : 8;
62
19
  offset = isSubmenu ? offset - 6 : offset;
63
- const reflowRef = useReflowOnContentChange();
64
- return /* @__PURE__ */ jsxRuntime.jsxs(
65
- reactAriaComponents.Popover,
66
- {
67
- ref: reflowRef,
68
- offset,
69
- ...props,
70
- className: reactAriaComponents.composeRenderProps(
71
- className ?? classNames?.base,
72
- (className2, renderProps) => ouiTheme.popoverStyles({ ...renderProps, className: className2 })
73
- ),
74
- children: [
75
- showArrow && /* @__PURE__ */ jsxRuntime.jsx(reactAriaComponents.OverlayArrow, { className: "group", children: /* @__PURE__ */ jsxRuntime.jsx(
76
- "svg",
77
- {
78
- width: 12,
79
- height: 12,
80
- viewBox: "0 0 12 12",
81
- className: ouiTheme.popoverArrowStyles({ className: classNames?.arrow }),
82
- children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M0 0 L6 6 L12 0" })
83
- }
84
- ) }),
85
- children
86
- ]
87
- }
20
+ const wrapperClassName = reactAriaComponents.composeRenderProps(
21
+ className ?? classNames?.base,
22
+ (className2) => ouiTheme.popoverStyles({ className: className2 })
88
23
  );
24
+ return /* @__PURE__ */ jsxRuntime.jsx(reactAriaComponents.Popover, { offset, ...props, className: ouiTheme.popoverOverlayStyles(), children: reactAriaComponents.composeRenderProps(children, (children2, renderProps) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
25
+ showArrow && /* @__PURE__ */ jsxRuntime.jsx(reactAriaComponents.OverlayArrow, { className: "group", children: /* @__PURE__ */ jsxRuntime.jsx(
26
+ "svg",
27
+ {
28
+ width: 12,
29
+ height: 12,
30
+ viewBox: "0 0 12 12",
31
+ className: ouiTheme.popoverArrowStyles({ className: classNames?.arrow }),
32
+ children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M0 0 L6 6 L12 0" })
33
+ }
34
+ ) }),
35
+ /* @__PURE__ */ jsxRuntime.jsx(
36
+ "div",
37
+ {
38
+ "data-placement": renderProps.placement,
39
+ className: typeof wrapperClassName === "function" ? wrapperClassName({
40
+ ...renderProps,
41
+ defaultClassName: void 0
42
+ }) : wrapperClassName,
43
+ children: children2
44
+ }
45
+ )
46
+ ] })) });
89
47
  };
90
48
 
91
49
  exports.Popover = Popover;
@@ -48,7 +48,7 @@ const AvatarGroup = forwardRef((props, ref) => {
48
48
  remainingCount,
49
49
  renderCount
50
50
  ]);
51
- return /* @__PURE__ */ jsx(Component, { ...getAvatarGroupProps(), children: /* @__PURE__ */ jsxs(AvatarGroupProvider, { value: context, children: [
51
+ return /* @__PURE__ */ jsx(Component, { ...getAvatarGroupProps(), children: /* @__PURE__ */ jsxs(AvatarGroupProvider.Provider, { value: context, children: [
52
52
  clones,
53
53
  renderedCount
54
54
  ] }) });
@@ -46,7 +46,7 @@ const AvatarRoot = forwardRef(
46
46
  const [imageLoadingStatus, setImageLoadingStatus] = useState("idle");
47
47
  const Component = as || "span";
48
48
  return /* @__PURE__ */ jsx(
49
- AvatarContext,
49
+ AvatarContext.Provider,
50
50
  {
51
51
  value: {
52
52
  imageLoadingStatus,
@@ -24,12 +24,40 @@ function MenuInner(originalProps, ref) {
24
24
  originalProps,
25
25
  menuStyles.variantKeys
26
26
  );
27
- const { className, classNames, placement, ...rest } = props;
27
+ const {
28
+ className,
29
+ classNames,
30
+ placement,
31
+ boundaryElement,
32
+ scrollRef,
33
+ shouldFlip,
34
+ maxHeight,
35
+ containerPadding,
36
+ offset,
37
+ crossOffset,
38
+ shouldUpdatePosition,
39
+ arrowBoundaryOffset,
40
+ triggerRef,
41
+ ...rest
42
+ } = props;
43
+ const popoverProps = {
44
+ placement,
45
+ boundaryElement,
46
+ scrollRef,
47
+ shouldFlip,
48
+ maxHeight,
49
+ containerPadding,
50
+ offset,
51
+ crossOffset,
52
+ shouldUpdatePosition,
53
+ arrowBoundaryOffset,
54
+ triggerRef
55
+ };
28
56
  const styles = menuStyles(variantProps);
29
57
  return /* @__PURE__ */ jsx(Provider, { values: [[MenuVariantContext, variantProps]], children: /* @__PURE__ */ jsx(
30
58
  Popover,
31
59
  {
32
- placement,
60
+ ...popoverProps,
33
61
  className: styles.popover({ className: classNames?.popover }),
34
62
  children: /* @__PURE__ */ jsx(
35
63
  Menu$1,
@@ -32,7 +32,7 @@ const Navbar = forwardRef((props, ref) => {
32
32
  /* @__PURE__ */ jsx("header", { ...context.getWrapperProps(), children: childrenWithoutMenu }),
33
33
  menu
34
34
  ] });
35
- return /* @__PURE__ */ jsx(NavbarProvider, { value: context, children: /* @__PURE__ */ jsx(FocusScope, { contain: context.isMenuOpen, children: context.shouldShowOnScrollUp ? /* @__PURE__ */ jsx(LazyMotion, { features: domAnimation, children: /* @__PURE__ */ jsx(
35
+ return /* @__PURE__ */ jsx(NavbarProvider.Provider, { value: context, children: /* @__PURE__ */ jsx(FocusScope, { contain: context.isMenuOpen, children: context.shouldShowOnScrollUp ? /* @__PURE__ */ jsx(LazyMotion, { features: domAnimation, children: /* @__PURE__ */ jsx(
36
36
  m.nav,
37
37
  {
38
38
  animate: context.isNavbarHidden ? "hidden" : "visible",
@@ -1,52 +1,9 @@
1
1
  "use strict";
2
2
  "use client";
3
- import { jsxs, jsx } from 'react/jsx-runtime';
4
- import { useRef, useCallback } from 'react';
5
- import { useSlottedContext, PopoverContext, Popover as Popover$1, OverlayArrow, composeRenderProps } from 'react-aria-components';
6
- import { popoverArrowStyles, popoverStyles } from '@opengovsg/oui-theme';
3
+ import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
4
+ import { useSlottedContext, PopoverContext, composeRenderProps, Popover as Popover$1, OverlayArrow } from 'react-aria-components';
5
+ import { popoverStyles, popoverArrowStyles, popoverOverlayStyles } from '@opengovsg/oui-theme';
7
6
 
8
- const REFLOW_INTERVAL_MS = 50;
9
- const REFLOW_MAX_ATTEMPTS = 20;
10
- const useReflowOnContentChange = () => {
11
- const cleanupRef = useRef(null);
12
- return useCallback((el) => {
13
- cleanupRef.current?.();
14
- cleanupRef.current = null;
15
- if (!el) return;
16
- let timer = 0;
17
- let attempts = 0;
18
- let observer = null;
19
- const settle = () => {
20
- observer?.disconnect();
21
- observer = null;
22
- };
23
- const poll = () => {
24
- if (el.offsetHeight > 0) return settle();
25
- window.dispatchEvent(new Event("resize"));
26
- attempts += 1;
27
- if (el.offsetHeight > 0) return settle();
28
- if (attempts >= REFLOW_MAX_ATTEMPTS) return;
29
- timer = window.setTimeout(poll, REFLOW_INTERVAL_MS);
30
- };
31
- const start = () => {
32
- clearTimeout(timer);
33
- attempts = 0;
34
- timer = window.setTimeout(poll, 0);
35
- };
36
- start();
37
- observer = new MutationObserver(start);
38
- observer.observe(el, {
39
- childList: true,
40
- subtree: true,
41
- characterData: true
42
- });
43
- cleanupRef.current = () => {
44
- clearTimeout(timer);
45
- observer?.disconnect();
46
- observer = null;
47
- };
48
- }, []);
49
- };
50
7
  const Popover = ({
51
8
  children,
52
9
  showArrow,
@@ -58,32 +15,33 @@ const Popover = ({
58
15
  const isSubmenu = popoverContext?.trigger === "SubmenuTrigger";
59
16
  let offset = showArrow ? 12 : 8;
60
17
  offset = isSubmenu ? offset - 6 : offset;
61
- const reflowRef = useReflowOnContentChange();
62
- return /* @__PURE__ */ jsxs(
63
- Popover$1,
64
- {
65
- ref: reflowRef,
66
- offset,
67
- ...props,
68
- className: composeRenderProps(
69
- className ?? classNames?.base,
70
- (className2, renderProps) => popoverStyles({ ...renderProps, className: className2 })
71
- ),
72
- children: [
73
- showArrow && /* @__PURE__ */ jsx(OverlayArrow, { className: "group", children: /* @__PURE__ */ jsx(
74
- "svg",
75
- {
76
- width: 12,
77
- height: 12,
78
- viewBox: "0 0 12 12",
79
- className: popoverArrowStyles({ className: classNames?.arrow }),
80
- children: /* @__PURE__ */ jsx("path", { d: "M0 0 L6 6 L12 0" })
81
- }
82
- ) }),
83
- children
84
- ]
85
- }
18
+ const wrapperClassName = composeRenderProps(
19
+ className ?? classNames?.base,
20
+ (className2) => popoverStyles({ className: className2 })
86
21
  );
22
+ return /* @__PURE__ */ jsx(Popover$1, { offset, ...props, className: popoverOverlayStyles(), children: composeRenderProps(children, (children2, renderProps) => /* @__PURE__ */ jsxs(Fragment, { children: [
23
+ showArrow && /* @__PURE__ */ jsx(OverlayArrow, { className: "group", children: /* @__PURE__ */ jsx(
24
+ "svg",
25
+ {
26
+ width: 12,
27
+ height: 12,
28
+ viewBox: "0 0 12 12",
29
+ className: popoverArrowStyles({ className: classNames?.arrow }),
30
+ children: /* @__PURE__ */ jsx("path", { d: "M0 0 L6 6 L12 0" })
31
+ }
32
+ ) }),
33
+ /* @__PURE__ */ jsx(
34
+ "div",
35
+ {
36
+ "data-placement": renderProps.placement,
37
+ className: typeof wrapperClassName === "function" ? wrapperClassName({
38
+ ...renderProps,
39
+ defaultClassName: void 0
40
+ }) : wrapperClassName,
41
+ children: children2
42
+ }
43
+ )
44
+ ] })) });
87
45
  };
88
46
 
89
47
  export { Popover };
@@ -3,8 +3,14 @@ import { MenuTrigger as AriaMenuTrigger } from "react-aria-components";
3
3
  import type { ListBoxItemVariantProps, MenuItemVariantSlots, MenuSectionVariantProps, MenuSectionVariantSlots, MenuVariantProps, MenuVariantSlots, SlotsToClasses } from "@opengovsg/oui-theme";
4
4
  import type { PopoverProps } from "../popover";
5
5
  export declare const MenuVariantContext: import("react").Context<ContextValue<MenuVariantProps, any>>, useMenuVariantContext: () => ContextValue<MenuVariantProps, any>;
6
- export interface MenuProps<T> extends AriaMenuProps<T>, MenuVariantProps {
7
- placement?: PopoverProps["placement"];
6
+ /**
7
+ * Popover positioning props forwarded from `Menu` to its underlying `Popover`.
8
+ * These let consumers bound where/how the menu flips — most importantly
9
+ * `boundaryElement`/`scrollRef`, which constrain flipping to a scroll container
10
+ * rather than the whole viewport.
11
+ */
12
+ type ForwardedPopoverProps = Pick<PopoverProps, "placement" | "boundaryElement" | "scrollRef" | "shouldFlip" | "maxHeight" | "containerPadding" | "offset" | "crossOffset" | "shouldUpdatePosition" | "arrowBoundaryOffset" | "triggerRef">;
13
+ export interface MenuProps<T> extends AriaMenuProps<T>, MenuVariantProps, ForwardedPopoverProps {
8
14
  classNames?: SlotsToClasses<MenuVariantSlots>;
9
15
  }
10
16
  export declare const Menu: <T extends object>(props: MenuProps<T> & import("react").RefAttributes<HTMLDivElement>) => React.ReactNode;
@@ -35,4 +41,5 @@ export interface MenuSectionProps<T> extends AriaMenuSectionProps<T>, MenuSectio
35
41
  export declare const MenuSection: <T extends object>(props: MenuSectionProps<T> & import("react").RefAttributes<HTMLElement>) => React.ReactNode;
36
42
  export declare const MenuTrigger: typeof AriaMenuTrigger;
37
43
  export declare const SubmenuTrigger: (props: import("react-aria-components").SubmenuTriggerProps & React.RefAttributes<HTMLDivElement>) => import("react").ReactElement | null;
44
+ export {};
38
45
  //# sourceMappingURL=menu.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"menu.d.ts","sourceRoot":"","sources":["../../../src/menu/menu.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK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Ac,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AACxE,OAAO,EAAsB,aAAa,EAAE,MAAM,sBAAsB,CAAA;AAExE,MAAM,WAAW,YACf,SAAQ,IAAI,CAAC,gBAAgB,EAAE,UAAU,CAAC,EACxC,YAAY,CAAC,OAAO,aAAa,CAAC;IACpC,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;IAEzB;;;;;;;;;;OAUG;IACH,UAAU,CAAC,EAAE,cAAc,CAAC,OAAO,GAAG,MAAM,CAAC,CAAA;CAC9C;AA4FD,eAAO,MAAM,OAAO,6DAMjB,YAAY,4CAgCd,CAAA"}
1
+ {"version":3,"file":"popover.d.ts","sourceRoot":"","sources":["../../../src/popover/popover.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,IAAI,gBAAgB,EAAE,MAAM,uBAAuB,CAAA;AAS7E,OAAO,KAAK,EAAE,cAAc,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AACxE,OAAO,EAGL,aAAa,EACd,MAAM,sBAAsB,CAAA;AAE7B,MAAM,WAAW,YACf,SAAQ,IAAI,CAAC,gBAAgB,EAAE,UAAU,CAAC,EACxC,YAAY,CAAC,OAAO,aAAa,CAAC;IACpC,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;IAEzB;;;;;;;;;;OAUG;IACH,UAAU,CAAC,EAAE,cAAc,CAAC,OAAO,GAAG,MAAM,CAAC,CAAA;CAC9C;AAED,eAAO,MAAM,OAAO,6DAMjB,YAAY,4CAgDd,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opengovsg/oui",
3
- "version": "0.0.58",
3
+ "version": "0.0.59",
4
4
  "sideEffects": false,
5
5
  "license": "SEE LICENSE IN LICENSE.md",
6
6
  "type": "module",
@@ -36,7 +36,7 @@
36
36
  "./package.json": "./package.json"
37
37
  },
38
38
  "devDependencies": {
39
- "@storybook/react-vite": "10.2.10",
39
+ "@storybook/react-vite": "10.4.5",
40
40
  "@types/lodash-es": "^4.17.12",
41
41
  "@types/prop-types": "^15.7.15",
42
42
  "@types/react": "^19.2.9",
@@ -48,14 +48,14 @@
48
48
  "prettier": "^3.5.3",
49
49
  "react": "^19.2.3",
50
50
  "react-aria-components": "^1.14.0",
51
- "storybook": "10.2.10",
51
+ "storybook": "10.4.5",
52
52
  "tsx": "^4.21.0",
53
53
  "typescript": "5.7.3",
54
54
  "@oui/chromatic": "0.0.0",
55
- "@opengovsg/oui-theme": "0.0.58",
56
55
  "@oui/eslint-config": "0.0.0",
56
+ "@oui/prettier-config": "0.0.0",
57
57
  "@oui/typescript-config": "0.0.0",
58
- "@oui/prettier-config": "0.0.0"
58
+ "@opengovsg/oui-theme": "0.0.59"
59
59
  },
60
60
  "dependencies": {
61
61
  "@internationalized/date": "^3.10.1",
@@ -75,7 +75,7 @@
75
75
  "downshift": "^9.0.9",
76
76
  "fuzzysort": "^3.1.0",
77
77
  "lodash-es": "^4.18.1",
78
- "nanoid": "^5.1.5",
78
+ "nanoid": "^5.1.11",
79
79
  "react-aria": "^3.41.1",
80
80
  "react-dropzone": "^14.3.8",
81
81
  "react-phone-number-input": "^3.4.14",
@@ -91,7 +91,7 @@
91
91
  "motion": ">=11.12.0 || >=12.0.0-alpha.1",
92
92
  "react": ">= 18",
93
93
  "react-aria-components": "^1.14.0",
94
- "@opengovsg/oui-theme": "0.0.58"
94
+ "@opengovsg/oui-theme": "0.0.59"
95
95
  },
96
96
  "scripts": {
97
97
  "build": "tsx ../../tooling/build-scripts/main.ts --dts --clean",