@abgov/react-components 5.0.0-alpha.10 → 5.0.0-alpha.11

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/index.mjs CHANGED
@@ -7,6 +7,7 @@ function GoAAccordion({
7
7
  headingSize,
8
8
  secondaryText,
9
9
  headingContent,
10
+ iconPosition,
10
11
  maxWidth,
11
12
  testid,
12
13
  children,
@@ -22,6 +23,7 @@ function GoAAccordion({
22
23
  headingSize,
23
24
  heading,
24
25
  secondaryText,
26
+ iconposition: iconPosition,
25
27
  maxwidth: maxWidth,
26
28
  testid,
27
29
  mt,
@@ -41,16 +43,36 @@ function GoAAppHeader({
41
43
  maxContentWidth,
42
44
  fullMenuBreakpoint,
43
45
  testId,
44
- children
46
+ children,
47
+ onMenuClick
45
48
  }) {
49
+ const el = useRef(null);
50
+ useEffect(() => {
51
+ if (!el.current) {
52
+ return;
53
+ }
54
+ if (!onMenuClick) {
55
+ return;
56
+ }
57
+ const current = el.current;
58
+ const listener = () => {
59
+ onMenuClick();
60
+ };
61
+ current.addEventListener("_menuClick", listener);
62
+ return () => {
63
+ current.removeEventListener("_menuClick", listener);
64
+ };
65
+ }, [el, onMenuClick]);
46
66
  return /* @__PURE__ */ jsx(
47
67
  "goa-app-header",
48
68
  {
69
+ ref: el,
49
70
  heading,
50
71
  url,
51
72
  fullmenubreakpoint: fullMenuBreakpoint,
52
73
  maxcontentwidth: maxContentWidth,
53
74
  testid: testId,
75
+ hasmenuclickhandler: !!onMenuClick,
54
76
  children
55
77
  }
56
78
  );
@@ -324,6 +346,7 @@ function GoACalendar({
324
346
  const GoACallout = ({
325
347
  heading,
326
348
  type = "information",
349
+ iconTheme = "outline",
327
350
  size = "large",
328
351
  maxWidth,
329
352
  testId,
@@ -342,6 +365,7 @@ const GoACallout = ({
342
365
  size,
343
366
  maxwidth: maxWidth,
344
367
  arialive: ariaLive,
368
+ icontheme: iconTheme,
345
369
  mt,
346
370
  mr,
347
371
  mb,
@@ -3216,7 +3240,12 @@ function GoASideMenuGroup(props) {
3216
3240
  "goa-side-menu-group",
3217
3241
  {
3218
3242
  heading: props.heading,
3243
+ icon: props.icon,
3219
3244
  testid: props.testId,
3245
+ mt: props.mt,
3246
+ mr: props.mr,
3247
+ mb: props.mb,
3248
+ ml: props.ml,
3220
3249
  children: props.children
3221
3250
  }
3222
3251
  );