@bug-on/m3-expressive 1.3.2 → 1.3.3

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.
@@ -3,7 +3,7 @@ import { AnimatePresence, m, LazyMotion, domMax, useMotionValue, animate, useAni
3
3
  import { clsx } from 'clsx';
4
4
  import { twMerge } from 'tailwind-merge';
5
5
  import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
6
- import * as React38 from 'react';
6
+ import * as React39 from 'react';
7
7
  import { useRef, useEffect, useState } from 'react';
8
8
  import * as RxContextMenu from '@radix-ui/react-context-menu';
9
9
  import * as RadixScrollArea from '@radix-ui/react-scroll-area';
@@ -294,7 +294,7 @@ function AppBarItemButton({ item }) {
294
294
  }
295
295
  );
296
296
  }
297
- var ScrollArea = React38.forwardRef(
297
+ var ScrollArea = React39.forwardRef(
298
298
  (_a, ref) => {
299
299
  var _b = _a, {
300
300
  className,
@@ -315,15 +315,15 @@ var ScrollArea = React38.forwardRef(
315
315
  "viewportRef",
316
316
  "viewportProps"
317
317
  ]);
318
- const [isTouchDevice, setIsTouchDevice] = React38.useState(false);
319
- React38.useEffect(() => {
318
+ const [isTouchDevice, setIsTouchDevice] = React39.useState(false);
319
+ React39.useEffect(() => {
320
320
  if (typeof window !== "undefined") {
321
321
  setIsTouchDevice(
322
322
  "ontouchstart" in window || navigator.maxTouchPoints > 0
323
323
  );
324
324
  }
325
325
  }, []);
326
- const resolvedType = React38.useMemo(() => {
326
+ const resolvedType = React39.useMemo(() => {
327
327
  if (type === "hover" && isTouchDevice) {
328
328
  return "scroll";
329
329
  }
@@ -374,7 +374,7 @@ var ScrollArea = React38.forwardRef(
374
374
  }
375
375
  );
376
376
  ScrollArea.displayName = "ScrollArea";
377
- var ScrollAreaScrollbar = React38.forwardRef((_a, ref) => {
377
+ var ScrollAreaScrollbar = React39.forwardRef((_a, ref) => {
378
378
  var _b = _a, { className, orientation = "vertical" } = _b, props = __objRest(_b, ["className", "orientation"]);
379
379
  return /* @__PURE__ */ jsx(
380
380
  RadixScrollArea.Scrollbar,
@@ -404,7 +404,7 @@ var ScrollAreaScrollbar = React38.forwardRef((_a, ref) => {
404
404
  );
405
405
  });
406
406
  ScrollAreaScrollbar.displayName = RadixScrollArea.Scrollbar.displayName;
407
- var ScrollAreaCorner = React38.forwardRef((_a, ref) => {
407
+ var ScrollAreaCorner = React39.forwardRef((_a, ref) => {
408
408
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
409
409
  return /* @__PURE__ */ jsx(
410
410
  RadixScrollArea.Corner,
@@ -473,7 +473,7 @@ var SUBMENU_CONTAINER_VARIANTS = {
473
473
  transition: FAST_EFFECTS_TRANSITION
474
474
  }
475
475
  };
476
- var MenuContext = React38.createContext({
476
+ var MenuContext = React39.createContext({
477
477
  variant: "baseline",
478
478
  colorVariant: "standard",
479
479
  density: 0,
@@ -491,7 +491,7 @@ function MenuProvider({
491
491
  onOpenChange,
492
492
  children
493
493
  }) {
494
- const value = React38.useMemo(
494
+ const value = React39.useMemo(
495
495
  () => ({
496
496
  variant,
497
497
  colorVariant,
@@ -505,8 +505,8 @@ function MenuProvider({
505
505
  return /* @__PURE__ */ jsx(MenuContext.Provider, { value, children });
506
506
  }
507
507
  function useMenuContext() {
508
- const ctx = React38.useContext(MenuContext);
509
- return React38.useMemo(
508
+ const ctx = React39.useContext(MenuContext);
509
+ return React39.useMemo(
510
510
  () => Object.assign(ctx, {
511
511
  get isStatic() {
512
512
  return ctx.menuPrimitive === "static";
@@ -626,10 +626,10 @@ var VIBRANT_COLORS = {
626
626
  var DIVIDER_PADDING = "mx-3 my-0.5";
627
627
  var DIVIDER_COLOR = "bg-m3-outline-variant";
628
628
  function flattenChildren(nodes) {
629
- return React38.Children.toArray(nodes).reduce(
629
+ return React39.Children.toArray(nodes).reduce(
630
630
  (acc, child) => {
631
- if (!React38.isValidElement(child)) return acc;
632
- if (child.type === React38.Fragment) {
631
+ if (!React39.isValidElement(child)) return acc;
632
+ if (child.type === React39.Fragment) {
633
633
  return acc.concat(
634
634
  flattenChildren(
635
635
  child.props.children
@@ -647,7 +647,7 @@ function ContextMenu({
647
647
  variant = "baseline",
648
648
  colorVariant = "standard"
649
649
  }) {
650
- const [open, setOpen] = React38.useState(false);
650
+ const [open, setOpen] = React39.useState(false);
651
651
  return /* @__PURE__ */ jsx(
652
652
  MenuProvider,
653
653
  {
@@ -661,12 +661,12 @@ function ContextMenu({
661
661
  );
662
662
  }
663
663
  ContextMenu.displayName = "ContextMenu";
664
- var ContextMenuTrigger = React38.forwardRef((_a, ref) => {
664
+ var ContextMenuTrigger = React39.forwardRef((_a, ref) => {
665
665
  var _b = _a, { children, asChild = true } = _b, props = __objRest(_b, ["children", "asChild"]);
666
666
  return /* @__PURE__ */ jsx(RxContextMenu.Trigger, __spreadProps(__spreadValues({ ref, asChild }, props), { children }));
667
667
  });
668
668
  ContextMenuTrigger.displayName = "ContextMenuTrigger";
669
- var ContextMenuContent = React38.forwardRef(
669
+ var ContextMenuContent = React39.forwardRef(
670
670
  (_a, ref) => {
671
671
  var _b = _a, {
672
672
  children,
@@ -695,7 +695,7 @@ var ContextMenuContent = React38.forwardRef(
695
695
  const colorVariant = propColorVariant != null ? propColorVariant : contextColorVariant;
696
696
  const colors = variant === "baseline" ? BASELINE_COLORS : colorVariant === "vibrant" ? VIBRANT_COLORS : STANDARD_COLORS;
697
697
  const isExpressiveGap = variant === "expressive" && separatorStyle === "gap";
698
- const setViewportNode = React38.useCallback(
698
+ const setViewportNode = React39.useCallback(
699
699
  (node) => {
700
700
  if (typeof viewportRef === "function") {
701
701
  viewportRef(node);
@@ -706,7 +706,7 @@ var ContextMenuContent = React38.forwardRef(
706
706
  },
707
707
  [viewportRef, onViewportRef]
708
708
  );
709
- const containerClassName = React38.useMemo(
709
+ const containerClassName = React39.useMemo(
710
710
  () => variant === "expressive" ? cn(
711
711
  "z-50 flex flex-col w-full",
712
712
  MENU_MIN_WIDTH,
@@ -733,12 +733,12 @@ var ContextMenuContent = React38.forwardRef(
733
733
  ),
734
734
  [variant, isExpressiveGap, hasOverflow, className, colors.containerBg]
735
735
  );
736
- const renderedChildren = React38.useMemo(() => {
736
+ const renderedChildren = React39.useMemo(() => {
737
737
  if (variant !== "expressive") return children;
738
738
  const validChildren = flattenChildren(children);
739
739
  const groupCount = validChildren.length;
740
740
  const enhanced = validChildren.map(
741
- (child, i) => React38.cloneElement(
741
+ (child, i) => React39.cloneElement(
742
742
  child,
743
743
  { index: i, count: groupCount, isGapVariant: isExpressiveGap }
744
744
  )
@@ -807,12 +807,12 @@ function Menu(_a) {
807
807
  ]);
808
808
  var _a2;
809
809
  const resolvedVariant = (_a2 = variant != null ? variant : menuVariant) != null ? _a2 : "baseline";
810
- const [internalOpen, setInternalOpen] = React38.useState(
810
+ const [internalOpen, setInternalOpen] = React39.useState(
811
811
  () => defaultOpen != null ? defaultOpen : false
812
812
  );
813
813
  const isControlled = controlledOpen !== void 0;
814
814
  const open = isControlled ? controlledOpen : internalOpen;
815
- const handleOpenChange = React38.useCallback(
815
+ const handleOpenChange = React39.useCallback(
816
816
  (next) => {
817
817
  if (!isControlled) setInternalOpen(next);
818
818
  controlledOnOpenChange == null ? void 0 : controlledOnOpenChange(next);
@@ -840,12 +840,12 @@ function Menu(_a) {
840
840
  );
841
841
  }
842
842
  Menu.displayName = "Menu";
843
- var MenuTrigger = React38.forwardRef((_a, ref) => {
843
+ var MenuTrigger = React39.forwardRef((_a, ref) => {
844
844
  var _b = _a, { children, asChild = true } = _b, props = __objRest(_b, ["children", "asChild"]);
845
845
  return /* @__PURE__ */ jsx(DropdownMenu.Trigger, __spreadProps(__spreadValues({ ref, asChild }, props), { children }));
846
846
  });
847
847
  MenuTrigger.displayName = "MenuTrigger";
848
- var MenuContent = React38.forwardRef(
848
+ var MenuContent = React39.forwardRef(
849
849
  (_a, ref) => {
850
850
  var _b = _a, {
851
851
  children,
@@ -882,7 +882,7 @@ var MenuContent = React38.forwardRef(
882
882
  const colorVariant = propColorVariant != null ? propColorVariant : contextColorVariant;
883
883
  const colors = variant === "baseline" ? BASELINE_COLORS : colorVariant === "vibrant" ? VIBRANT_COLORS : STANDARD_COLORS;
884
884
  const isExpressiveGap = variant === "expressive" && separatorStyle === "gap";
885
- const setViewportNode = React38.useCallback(
885
+ const setViewportNode = React39.useCallback(
886
886
  (node) => {
887
887
  if (typeof viewportRef === "function") {
888
888
  viewportRef(node);
@@ -893,7 +893,7 @@ var MenuContent = React38.forwardRef(
893
893
  },
894
894
  [viewportRef, onViewportRef]
895
895
  );
896
- const containerClassName = React38.useMemo(() => {
896
+ const containerClassName = React39.useMemo(() => {
897
897
  const widthClass = matchTriggerWidth ? "w-[var(--radix-dropdown-menu-trigger-width)]" : cn(MENU_MIN_WIDTH, MENU_MAX_WIDTH);
898
898
  return variant === "expressive" ? cn(
899
899
  "z-50 flex flex-col",
@@ -926,7 +926,7 @@ var MenuContent = React38.forwardRef(
926
926
  className,
927
927
  colors.containerBg
928
928
  ]);
929
- const renderedChildren = React38.useMemo(() => {
929
+ const renderedChildren = React39.useMemo(() => {
930
930
  if (variant !== "expressive") return children;
931
931
  const validChildren = flattenChildren(children);
932
932
  const groupCount = validChildren.length;
@@ -935,7 +935,7 @@ var MenuContent = React38.forwardRef(
935
935
  if (typeof child.type === "string") return child;
936
936
  const defaultItemPosition = groupCount === 1 ? "standalone" : i === 0 ? "leading" : i === groupCount - 1 ? "trailing" : "middle";
937
937
  const itemPosition = (_a2 = child.props.itemPosition) != null ? _a2 : defaultItemPosition;
938
- return React38.cloneElement(
938
+ return React39.cloneElement(
939
939
  child,
940
940
  {
941
941
  index: i,
@@ -1001,7 +1001,7 @@ var MenuContent = React38.forwardRef(
1001
1001
  }
1002
1002
  );
1003
1003
  MenuContent.displayName = "MenuContent";
1004
- var MenuDivider = React38.forwardRef(
1004
+ var MenuDivider = React39.forwardRef(
1005
1005
  (_a, ref) => {
1006
1006
  var _b = _a, { className, isGapVariant: _isGapVariant } = _b, props = __objRest(_b, ["className", "isGapVariant"]);
1007
1007
  const { menuVariant } = useMenuContext();
@@ -1032,7 +1032,7 @@ function getGroupPosition(index, count) {
1032
1032
  function getGroupActiveShape(position) {
1033
1033
  return GROUP_SHAPES[`${position}Active`];
1034
1034
  }
1035
- var MenuGroup = React38.forwardRef(
1035
+ var MenuGroup = React39.forwardRef(
1036
1036
  (_a, ref) => {
1037
1037
  var _b = _a, {
1038
1038
  children,
@@ -1058,7 +1058,7 @@ var MenuGroup = React38.forwardRef(
1058
1058
  const colors = menuVariant === "baseline" ? BASELINE_COLORS : colorVariant === "vibrant" ? VIBRANT_COLORS : STANDARD_COLORS;
1059
1059
  const position = getGroupPosition(index, count);
1060
1060
  const currentShape = getGroupActiveShape(position);
1061
- const enhancedChildren = React38.useMemo(() => {
1061
+ const enhancedChildren = React39.useMemo(() => {
1062
1062
  const valid = flattenChildren(children);
1063
1063
  const itemCount = valid.length;
1064
1064
  return valid.map((child, i) => {
@@ -1066,7 +1066,7 @@ var MenuGroup = React38.forwardRef(
1066
1066
  if (typeof child.type === "string") return child;
1067
1067
  const defaultItemPosition = itemCount === 1 ? "standalone" : i === 0 ? "leading" : i === itemCount - 1 ? "trailing" : "middle";
1068
1068
  const itemPosition2 = (_a2 = child.props.itemPosition) != null ? _a2 : defaultItemPosition;
1069
- return React38.cloneElement(child, {
1069
+ return React39.cloneElement(child, {
1070
1070
  itemPosition: itemPosition2,
1071
1071
  colorVariant
1072
1072
  });
@@ -1129,7 +1129,7 @@ var VARIANT_FONT = {
1129
1129
  rounded: "'Material Symbols Rounded'",
1130
1130
  sharp: "'Material Symbols Sharp'"
1131
1131
  };
1132
- var IconComponent = React38.forwardRef(
1132
+ var IconComponent = React39.forwardRef(
1133
1133
  (_a, ref) => {
1134
1134
  var _b = _a, {
1135
1135
  name,
@@ -1195,14 +1195,14 @@ var IconComponent = React38.forwardRef(
1195
1195
  }
1196
1196
  );
1197
1197
  IconComponent.displayName = "Icon";
1198
- var Icon = React38.memo(IconComponent);
1198
+ var Icon = React39.memo(IconComponent);
1199
1199
  function getItemShapeClass(position, selected, isStatic = false, menuVariant = "expressive") {
1200
1200
  if (menuVariant === "baseline") return BASELINE_ITEM_SHAPE;
1201
1201
  if (selected) return ITEM_SHAPE_CLASSES.selected;
1202
1202
  if (isStatic && position === "standalone") return "rounded-[12px]";
1203
1203
  return ITEM_SHAPE_CLASSES[position];
1204
1204
  }
1205
- var MenuItem = React38.forwardRef(
1205
+ var MenuItem = React39.forwardRef(
1206
1206
  (_a, ref) => {
1207
1207
  var _b = _a, {
1208
1208
  children,
@@ -1411,31 +1411,31 @@ function SubMenu({
1411
1411
  }) {
1412
1412
  const { colorVariant: contextColorVariant, menuPrimitive } = useMenuContext();
1413
1413
  const colorVariant = propColorVariant != null ? propColorVariant : contextColorVariant;
1414
- const [open, setOpen] = React38.useState(false);
1415
- const openTimerRef = React38.useRef(null);
1416
- const closeTimerRef = React38.useRef(
1414
+ const [open, setOpen] = React39.useState(false);
1415
+ const openTimerRef = React39.useRef(null);
1416
+ const closeTimerRef = React39.useRef(
1417
1417
  null
1418
1418
  );
1419
- const clearTimers = React38.useCallback(() => {
1419
+ const clearTimers = React39.useCallback(() => {
1420
1420
  if (openTimerRef.current) clearTimeout(openTimerRef.current);
1421
1421
  if (closeTimerRef.current) clearTimeout(closeTimerRef.current);
1422
1422
  }, []);
1423
- const handleTriggerPointerEnter = React38.useCallback(() => {
1423
+ const handleTriggerPointerEnter = React39.useCallback(() => {
1424
1424
  clearTimers();
1425
1425
  openTimerRef.current = setTimeout(() => setOpen(true), hoverOpenDelay);
1426
1426
  }, [hoverOpenDelay, clearTimers]);
1427
- const handleTriggerPointerLeave = React38.useCallback(() => {
1427
+ const handleTriggerPointerLeave = React39.useCallback(() => {
1428
1428
  clearTimers();
1429
1429
  closeTimerRef.current = setTimeout(() => setOpen(false), hoverCloseDelay);
1430
1430
  }, [hoverCloseDelay, clearTimers]);
1431
- const handleContentPointerEnter = React38.useCallback(() => {
1431
+ const handleContentPointerEnter = React39.useCallback(() => {
1432
1432
  clearTimers();
1433
1433
  }, [clearTimers]);
1434
- const handleContentPointerLeave = React38.useCallback(() => {
1434
+ const handleContentPointerLeave = React39.useCallback(() => {
1435
1435
  clearTimers();
1436
1436
  closeTimerRef.current = setTimeout(() => setOpen(false), hoverCloseDelay);
1437
1437
  }, [hoverCloseDelay, clearTimers]);
1438
- React38.useEffect(() => () => clearTimers(), [clearTimers]);
1438
+ React39.useEffect(() => () => clearTimers(), [clearTimers]);
1439
1439
  const Sub3 = menuPrimitive === "context" ? RxContextMenu.Sub : DropdownMenu.Sub;
1440
1440
  const SubTrigger3 = menuPrimitive === "context" ? RxContextMenu.SubTrigger : DropdownMenu.SubTrigger;
1441
1441
  const SubContent3 = menuPrimitive === "context" ? RxContextMenu.SubContent : DropdownMenu.SubContent;
@@ -1447,7 +1447,7 @@ function SubMenu({
1447
1447
  className: "w-full outline-none",
1448
1448
  onPointerEnter: handleTriggerPointerEnter,
1449
1449
  onPointerLeave: handleTriggerPointerLeave,
1450
- children: React38.isValidElement(trigger) ? React38.cloneElement(trigger, {
1450
+ children: React39.isValidElement(trigger) ? React39.cloneElement(trigger, {
1451
1451
  isSubTrigger: true,
1452
1452
  // Auto-add chevron if missing
1453
1453
  trailingIcon: trigger.props.trailingIcon || /* @__PURE__ */ jsx(Icon, { name: "chevron_right", size: 20 })
@@ -1524,7 +1524,7 @@ function SubMenuContent({
1524
1524
  );
1525
1525
  }
1526
1526
  SubMenuContent.displayName = "SubMenuContent";
1527
- var VerticalMenuDivider = React38.forwardRef((_a, ref) => {
1527
+ var VerticalMenuDivider = React39.forwardRef((_a, ref) => {
1528
1528
  var _b = _a, { className, index, count, isGapVariant } = _b, props = __objRest(_b, ["className", "index", "count", "isGapVariant"]);
1529
1529
  return /* @__PURE__ */ jsx(
1530
1530
  "hr",
@@ -1544,7 +1544,7 @@ var VerticalMenuDivider = React38.forwardRef((_a, ref) => {
1544
1544
  });
1545
1545
  VerticalMenuDivider.displayName = "VerticalMenuDivider";
1546
1546
  var VerticalMenuGroup = MenuGroup;
1547
- var VerticalMenuContent = React38.forwardRef(
1547
+ var VerticalMenuContent = React39.forwardRef(
1548
1548
  (_a, ref) => {
1549
1549
  var _b = _a, {
1550
1550
  children,
@@ -1560,7 +1560,7 @@ var VerticalMenuContent = React38.forwardRef(
1560
1560
  const { colorVariant: contextColorVariant } = useMenuContext();
1561
1561
  const colorVariant = propColorVariant != null ? propColorVariant : contextColorVariant;
1562
1562
  const colors = colorVariant === "vibrant" ? VIBRANT_COLORS : STANDARD_COLORS;
1563
- const renderedChildren = React38.useMemo(() => {
1563
+ const renderedChildren = React39.useMemo(() => {
1564
1564
  const valid = flattenChildren(children);
1565
1565
  const groupCount = valid.length;
1566
1566
  const enhanced = valid.map((child, i) => {
@@ -1568,7 +1568,7 @@ var VerticalMenuContent = React38.forwardRef(
1568
1568
  if (typeof child.type === "string") return child;
1569
1569
  const defaultItemPosition = groupCount === 1 ? "standalone" : i === 0 ? "leading" : i === groupCount - 1 ? "trailing" : "middle";
1570
1570
  const itemPosition = (_a2 = child.props.itemPosition) != null ? _a2 : defaultItemPosition;
1571
- return React38.cloneElement(
1571
+ return React39.cloneElement(
1572
1572
  child,
1573
1573
  {
1574
1574
  index: i,
@@ -1611,13 +1611,13 @@ var VerticalMenuContent = React38.forwardRef(
1611
1611
  }
1612
1612
  );
1613
1613
  VerticalMenuContent.displayName = "VerticalMenuContent";
1614
- var VerticalMenu = React38.forwardRef((_a, ref) => {
1614
+ var VerticalMenu = React39.forwardRef((_a, ref) => {
1615
1615
  var _b = _a, { children, colorVariant = "standard", className } = _b, props = __objRest(_b, ["children", "colorVariant", "className"]);
1616
- const noop = React38.useCallback(() => {
1616
+ const noop = React39.useCallback(() => {
1617
1617
  }, []);
1618
1618
  const colors = colorVariant === "vibrant" ? VIBRANT_COLORS : STANDARD_COLORS;
1619
- const containerRef = React38.useRef(null);
1620
- const mergedRef = React38.useCallback(
1619
+ const containerRef = React39.useRef(null);
1620
+ const mergedRef = React39.useCallback(
1621
1621
  (node) => {
1622
1622
  containerRef.current = node;
1623
1623
  if (typeof ref === "function") ref(node);
@@ -1626,7 +1626,7 @@ var VerticalMenu = React38.forwardRef((_a, ref) => {
1626
1626
  },
1627
1627
  [ref]
1628
1628
  );
1629
- const handleKeyDown = React38.useCallback(
1629
+ const handleKeyDown = React39.useCallback(
1630
1630
  (e) => {
1631
1631
  var _a2;
1632
1632
  if (!containerRef.current) return;
@@ -1709,7 +1709,7 @@ var VerticalMenu = React38.forwardRef((_a, ref) => {
1709
1709
  });
1710
1710
  VerticalMenu.displayName = "VerticalMenu";
1711
1711
  function detectSeparatorStyle(children) {
1712
- const child = React38.Children.toArray(children).find(React38.isValidElement);
1712
+ const child = React39.Children.toArray(children).find(React39.isValidElement);
1713
1713
  if (child) {
1714
1714
  const style = child.props.separatorStyle;
1715
1715
  if (style) return style;
@@ -1790,11 +1790,11 @@ function AppBarColumn({
1790
1790
  maxItemCount,
1791
1791
  className
1792
1792
  }) {
1793
- const containerRef = React38.useRef(null);
1794
- const [visibleCount, setVisibleCount] = React38.useState(
1793
+ const containerRef = React39.useRef(null);
1794
+ const [visibleCount, setVisibleCount] = React39.useState(
1795
1795
  maxItemCount != null ? maxItemCount : items.length
1796
1796
  );
1797
- React38.useEffect(() => {
1797
+ React39.useEffect(() => {
1798
1798
  if (maxItemCount !== void 0) {
1799
1799
  setVisibleCount(Math.min(maxItemCount, items.length));
1800
1800
  return;
@@ -1842,11 +1842,11 @@ function AppBarColumn({
1842
1842
  );
1843
1843
  }
1844
1844
  function AppBarRow({ items, maxItemCount, className }) {
1845
- const containerRef = React38.useRef(null);
1846
- const [visibleCount, setVisibleCount] = React38.useState(
1845
+ const containerRef = React39.useRef(null);
1846
+ const [visibleCount, setVisibleCount] = React39.useState(
1847
1847
  maxItemCount != null ? maxItemCount : items.length
1848
1848
  );
1849
- React38.useEffect(() => {
1849
+ React39.useEffect(() => {
1850
1850
  if (maxItemCount !== void 0) {
1851
1851
  setVisibleCount(Math.min(maxItemCount, items.length));
1852
1852
  return;
@@ -1900,12 +1900,12 @@ function useAppBarScroll({
1900
1900
  collapsedHeight = 64,
1901
1901
  expandedHeight = 112
1902
1902
  } = {}) {
1903
- const [isScrolled, setIsScrolled] = React38.useState(false);
1904
- const [collapsedFraction, setCollapsedFraction] = React38.useState(0);
1905
- const [isHidden, setIsHidden] = React38.useState(false);
1906
- const prevScrollYRef = React38.useRef(0);
1903
+ const [isScrolled, setIsScrolled] = React39.useState(false);
1904
+ const [collapsedFraction, setCollapsedFraction] = React39.useState(0);
1905
+ const [isHidden, setIsHidden] = React39.useState(false);
1906
+ const prevScrollYRef = React39.useRef(0);
1907
1907
  const hideThreshold = 64;
1908
- React38.useEffect(() => {
1908
+ React39.useEffect(() => {
1909
1909
  var _a;
1910
1910
  const scrollDistance = expandedHeight - collapsedHeight;
1911
1911
  const getScrollY = () => {
@@ -2040,7 +2040,7 @@ function useFlexibleAppBar({
2040
2040
  expandedHeight
2041
2041
  });
2042
2042
  const scrollProgress = useMotionValue(0);
2043
- React38.useEffect(() => {
2043
+ React39.useEffect(() => {
2044
2044
  scrollProgress.set(
2045
2045
  shouldReduceMotion ? collapsedFraction > 0.5 ? 1 : 0 : collapsedFraction
2046
2046
  );
@@ -2418,7 +2418,7 @@ function SearchAppBar({
2418
2418
  }) {
2419
2419
  var _a, _b;
2420
2420
  const shouldReduceMotion = useReducedMotion();
2421
- const [isSearchOpen, setIsSearchOpen] = React38.useState(false);
2421
+ const [isSearchOpen, setIsSearchOpen] = React39.useState(false);
2422
2422
  const { isScrolled } = useAppBarScroll({
2423
2423
  scrollElement,
2424
2424
  behavior: scrollBehavior === "exitUntilCollapsed" ? "pinned" : scrollBehavior
@@ -2559,8 +2559,8 @@ function SearchView({
2559
2559
  className
2560
2560
  }) {
2561
2561
  const shouldReduceMotion = useReducedMotion();
2562
- const inputRef = React38.useRef(null);
2563
- React38.useEffect(() => {
2562
+ const inputRef = React39.useRef(null);
2563
+ React39.useEffect(() => {
2564
2564
  const timer = window.setTimeout(() => {
2565
2565
  var _a;
2566
2566
  (_a = inputRef.current) == null ? void 0 : _a.focus();
@@ -2851,7 +2851,7 @@ function SmallAppBar({
2851
2851
  "small-app-bar"
2852
2852
  ) });
2853
2853
  }
2854
- var RippleItem = React38.memo(function RippleItem2({
2854
+ var RippleItem = React39.memo(function RippleItem2({
2855
2855
  ripple,
2856
2856
  onDone
2857
2857
  }) {
@@ -2895,8 +2895,8 @@ function Ripple({
2895
2895
  }
2896
2896
  function useRippleState(options = {}) {
2897
2897
  const { disabled = false } = options;
2898
- const [ripples, setRipples] = React38.useState([]);
2899
- const onPointerDown = React38.useCallback(
2898
+ const [ripples, setRipples] = React39.useState([]);
2899
+ const onPointerDown = React39.useCallback(
2900
2900
  (e) => {
2901
2901
  if (disabled) return;
2902
2902
  const rect = e.currentTarget.getBoundingClientRect();
@@ -2913,7 +2913,7 @@ function useRippleState(options = {}) {
2913
2913
  },
2914
2914
  [disabled]
2915
2915
  );
2916
- const removeRipple = React38.useCallback((id) => {
2916
+ const removeRipple = React39.useCallback((id) => {
2917
2917
  setRipples((prev) => prev.filter((r) => r.id !== id));
2918
2918
  }, []);
2919
2919
  return { ripples, onPointerDown, removeRipple };
@@ -3626,8 +3626,8 @@ var RoundedPolygon = class _RoundedPolygon {
3626
3626
  );
3627
3627
  const mid = c.pointOnCurve(0.5);
3628
3628
  const md = distanceSquared(mid.x - this.centerX, mid.y - this.centerY);
3629
- const m31 = Math.max(ad, md);
3630
- if (m31 > maxDistSq) maxDistSq = m31;
3629
+ const m33 = Math.max(ad, md);
3630
+ if (m33 > maxDistSq) maxDistSq = m33;
3631
3631
  }
3632
3632
  const d = Math.sqrt(maxDistSq);
3633
3633
  return [
@@ -4843,11 +4843,11 @@ function getNavigationShapeStyle(shape, width = 56, height = 56) {
4843
4843
  function isSquareShape(shape) {
4844
4844
  return Boolean(shape && shape !== "pill");
4845
4845
  }
4846
- var NavigationBarContext = React38.createContext({ variant: "flexible" });
4846
+ var NavigationBarContext = React39.createContext({ variant: "flexible" });
4847
4847
  function cloneIconWithFill(icon, selected) {
4848
- if (!React38.isValidElement(icon)) return icon;
4848
+ if (!React39.isValidElement(icon)) return icon;
4849
4849
  if (icon.type === Icon) {
4850
- return React38.cloneElement(
4850
+ return React39.cloneElement(
4851
4851
  icon,
4852
4852
  { fill: selected ? 1 : 0, animateFill: true }
4853
4853
  );
@@ -4859,7 +4859,7 @@ function ActivePill({
4859
4859
  width = 56,
4860
4860
  height = 32
4861
4861
  }) {
4862
- const { activeIndicatorTransition } = React38.useContext(NavigationBarContext);
4862
+ const { activeIndicatorTransition } = React39.useContext(NavigationBarContext);
4863
4863
  const shapeStyle = getNavigationShapeStyle(shape, width, height);
4864
4864
  return /* @__PURE__ */ jsx(
4865
4865
  m.div,
@@ -4931,7 +4931,7 @@ function IconContainer({ selected, badge, children }) {
4931
4931
  }
4932
4932
  );
4933
4933
  }
4934
- var NavigationBarItemComponent = React38.forwardRef(
4934
+ var NavigationBarItemComponent = React39.forwardRef(
4935
4935
  ({
4936
4936
  selected,
4937
4937
  icon,
@@ -4955,7 +4955,7 @@ var NavigationBarItemComponent = React38.forwardRef(
4955
4955
  labelVisibility: contextLabelVisibility,
4956
4956
  shapeSize: contextShapeSize,
4957
4957
  itemClassName: contextItemClassName
4958
- } = React38.useContext(NavigationBarContext);
4958
+ } = React39.useContext(NavigationBarContext);
4959
4959
  const activeShape = (_a = shapeProp != null ? shapeProp : contextShape) != null ? _a : "pill";
4960
4960
  const isSquare = isSquareShape(activeShape);
4961
4961
  const resolvedShapeSize = (_b = shapeSizeProp != null ? shapeSizeProp : contextShapeSize) != null ? _b : 56;
@@ -4969,7 +4969,7 @@ var NavigationBarItemComponent = React38.forwardRef(
4969
4969
  const { ripples, onPointerDown, removeRipple } = useRippleState({
4970
4970
  disabled
4971
4971
  });
4972
- const handleClick = React38.useCallback(
4972
+ const handleClick = React39.useCallback(
4973
4973
  (e) => {
4974
4974
  if (disabled) {
4975
4975
  e.preventDefault();
@@ -4996,7 +4996,7 @@ var NavigationBarItemComponent = React38.forwardRef(
4996
4996
  const iconPillWidth = isSquare ? resolvedShapeSize : 56;
4997
4997
  const iconPillHeight = isSquare ? resolvedShapeSize : 32;
4998
4998
  if (asChild && children) {
4999
- const child = React38.Children.only(children);
4999
+ const child = React39.Children.only(children);
5000
5000
  const innerContent = /* @__PURE__ */ jsxs(Fragment, { children: [
5001
5001
  /* @__PURE__ */ jsxs(
5002
5002
  "div",
@@ -5121,7 +5121,7 @@ var NavigationBarItemComponent = React38.forwardRef(
5121
5121
  onClick: handleClick,
5122
5122
  onPointerDown,
5123
5123
  className: itemClassName,
5124
- children: React38.cloneElement(child, { children: innerContent })
5124
+ children: React39.cloneElement(child, { children: innerContent })
5125
5125
  }
5126
5126
  );
5127
5127
  }
@@ -5255,7 +5255,7 @@ var NavigationBarItemComponent = React38.forwardRef(
5255
5255
  }
5256
5256
  );
5257
5257
  NavigationBarItemComponent.displayName = "NavigationBarItem";
5258
- var NavigationBarItem = React38.memo(NavigationBarItemComponent);
5258
+ var NavigationBarItem = React39.memo(NavigationBarItemComponent);
5259
5259
  var navContainerVariants = cva(
5260
5260
  "flex items-center justify-center select-none transition-transform duration-300 z-50",
5261
5261
  {
@@ -5281,7 +5281,7 @@ var navContainerVariants = cva(
5281
5281
  }
5282
5282
  }
5283
5283
  );
5284
- var NavigationBarComponent = React38.forwardRef(
5284
+ var NavigationBarComponent = React39.forwardRef(
5285
5285
  ({
5286
5286
  variant = "flexible",
5287
5287
  itemLayout,
@@ -5298,18 +5298,18 @@ var NavigationBarComponent = React38.forwardRef(
5298
5298
  className,
5299
5299
  style
5300
5300
  }, ref) => {
5301
- const [isVisible, setIsVisible] = React38.useState(true);
5302
- const lastScrollY = React38.useRef(
5301
+ const [isVisible, setIsVisible] = React39.useState(true);
5302
+ const lastScrollY = React39.useRef(
5303
5303
  typeof window !== "undefined" ? window.scrollY : 0
5304
5304
  );
5305
5305
  const isSquare = isSquareShape(shape);
5306
5306
  const effectiveShapeSize = shapeSize != null ? shapeSize : isSquare ? 56 : 32;
5307
- const computedMinHeight = React38.useMemo(() => {
5307
+ const computedMinHeight = React39.useMemo(() => {
5308
5308
  const baseHeight = variant === "baseline" ? 80 : 64;
5309
5309
  const requiredHeight = itemLayout === "horizontal" || labelVisibility === "unlabeled" ? effectiveShapeSize + 16 : effectiveShapeSize + 32;
5310
5310
  return Math.max(baseHeight, requiredHeight);
5311
5311
  }, [variant, itemLayout, labelVisibility, effectiveShapeSize]);
5312
- React38.useEffect(() => {
5312
+ React39.useEffect(() => {
5313
5313
  if (typeof window === "undefined" || !hideOnScroll) {
5314
5314
  setIsVisible(true);
5315
5315
  return;
@@ -5393,8 +5393,8 @@ var NavigationBarComponent = React38.forwardRef(
5393
5393
  }
5394
5394
  );
5395
5395
  NavigationBarComponent.displayName = "NavigationBar";
5396
- var NavigationBar = React38.memo(NavigationBarComponent);
5397
- var NavigationRailContext = React38.createContext({
5396
+ var NavigationBar = React39.memo(NavigationBarComponent);
5397
+ var NavigationRailContext = React39.createContext({
5398
5398
  variant: "collapsed",
5399
5399
  labelVisibility: "labeled",
5400
5400
  activeIndicatorWidth: "hug"
@@ -5430,9 +5430,9 @@ var railContainerVariants = cva(
5430
5430
  }
5431
5431
  );
5432
5432
  function cloneIconWithFill2(icon, selected) {
5433
- if (!React38.isValidElement(icon)) return icon;
5433
+ if (!React39.isValidElement(icon)) return icon;
5434
5434
  if (icon.type === Icon) {
5435
- return React38.cloneElement(
5435
+ return React39.cloneElement(
5436
5436
  icon,
5437
5437
  { fill: selected ? 1 : 0, animateFill: true }
5438
5438
  );
@@ -5461,7 +5461,7 @@ function ActivePill2({
5461
5461
  width = 56,
5462
5462
  height = 32
5463
5463
  }) {
5464
- const { activeIndicatorTransition } = React38.useContext(NavigationRailContext);
5464
+ const { activeIndicatorTransition } = React39.useContext(NavigationRailContext);
5465
5465
  const shapeStyle = getNavigationShapeStyle(shape, width, height);
5466
5466
  return /* @__PURE__ */ jsx(
5467
5467
  m.div,
@@ -5536,7 +5536,7 @@ function IconContainer2({ selected, badge, children }) {
5536
5536
  }
5537
5537
  );
5538
5538
  }
5539
- var NavigationRailItemComponent = React38.forwardRef(
5539
+ var NavigationRailItemComponent = React39.forwardRef(
5540
5540
  ({
5541
5541
  selected,
5542
5542
  icon,
@@ -5559,7 +5559,7 @@ var NavigationRailItemComponent = React38.forwardRef(
5559
5559
  shape: contextShape,
5560
5560
  shapeSize: contextShapeSize,
5561
5561
  activeIndicatorWidth: contextActiveIndicatorWidth
5562
- } = React38.useContext(NavigationRailContext);
5562
+ } = React39.useContext(NavigationRailContext);
5563
5563
  const activeShape = (_a = shapeProp != null ? shapeProp : contextShape) != null ? _a : "pill";
5564
5564
  const isSquare = isSquareShape(activeShape);
5565
5565
  const resolvedShapeSize = (_b = shapeSizeProp != null ? shapeSizeProp : contextShapeSize) != null ? _b : 56;
@@ -5569,12 +5569,12 @@ var NavigationRailItemComponent = React38.forwardRef(
5569
5569
  const enableLayout = !isModal;
5570
5570
  const isExpandedPill = isExpanded && !isSquare;
5571
5571
  const expandedPillWidthClass = activeIndicatorWidth === "fill" ? "w-full" : "w-fit";
5572
- const activePillId = `rail-pill-${React38.useId()}`;
5572
+ const activePillId = `rail-pill-${React39.useId()}`;
5573
5573
  const { ripples, onPointerDown, removeRipple } = useRippleState({
5574
5574
  disabled
5575
5575
  });
5576
5576
  const showLabel = isExpanded || labelVisibility === "labeled" || labelVisibility === "auto" && selected;
5577
- const handleClick = React38.useCallback(
5577
+ const handleClick = React39.useCallback(
5578
5578
  (e) => {
5579
5579
  if (disabled) {
5580
5580
  e.preventDefault();
@@ -5596,7 +5596,7 @@ var NavigationRailItemComponent = React38.forwardRef(
5596
5596
  const iconPillWidth = isSquare ? resolvedShapeSize : 56;
5597
5597
  const iconPillHeight = isSquare ? resolvedShapeSize : 32;
5598
5598
  if (asChild && children) {
5599
- const child = React38.Children.only(children);
5599
+ const child = React39.Children.only(children);
5600
5600
  const innerContent = /* @__PURE__ */ jsxs(Fragment, { children: [
5601
5601
  /* @__PURE__ */ jsxs(
5602
5602
  m.div,
@@ -5714,7 +5714,7 @@ var NavigationRailItemComponent = React38.forwardRef(
5714
5714
  onPointerDown,
5715
5715
  className: itemClassName,
5716
5716
  tabIndex: -1,
5717
- children: React38.cloneElement(child, { children: innerContent })
5717
+ children: React39.cloneElement(child, { children: innerContent })
5718
5718
  }
5719
5719
  ) });
5720
5720
  }
@@ -5842,9 +5842,9 @@ var NavigationRailItemComponent = React38.forwardRef(
5842
5842
  }
5843
5843
  );
5844
5844
  NavigationRailItemComponent.displayName = "NavigationRailItem";
5845
- var NavigationRailItem = React38.memo(NavigationRailItemComponent);
5845
+ var NavigationRailItem = React39.memo(NavigationRailItemComponent);
5846
5846
  function useRoving(navRef) {
5847
- React38.useEffect(() => {
5847
+ React39.useEffect(() => {
5848
5848
  if (!navRef.current) return;
5849
5849
  const items = getMenuItems(navRef.current);
5850
5850
  const selected = items.find(
@@ -5854,7 +5854,7 @@ function useRoving(navRef) {
5854
5854
  const firstFocusable = selected != null ? selected : items[0];
5855
5855
  if (firstFocusable) firstFocusable.tabIndex = 0;
5856
5856
  }, [navRef]);
5857
- return React38.useCallback(
5857
+ return React39.useCallback(
5858
5858
  (e) => {
5859
5859
  if (!navRef.current) return;
5860
5860
  const items = getMenuItems(navRef.current);
@@ -5882,7 +5882,7 @@ function useRoving(navRef) {
5882
5882
  [navRef]
5883
5883
  );
5884
5884
  }
5885
- var NavigationRailComponent = React38.forwardRef(
5885
+ var NavigationRailComponent = React39.forwardRef(
5886
5886
  ({
5887
5887
  variant = "collapsed",
5888
5888
  labelVisibility = "labeled",
@@ -5906,9 +5906,9 @@ var NavigationRailComponent = React38.forwardRef(
5906
5906
  const isXr = variant === "xr";
5907
5907
  const isSpatial = isXr && fabPlacement === "spatialized";
5908
5908
  const applyAnimation = !isXr || !isSpatial;
5909
- const navRef = React38.useRef(null);
5909
+ const navRef = React39.useRef(null);
5910
5910
  const handleKeyDown = useRoving(navRef);
5911
- const setRefs = React38.useCallback(
5911
+ const setRefs = React39.useCallback(
5912
5912
  (node) => {
5913
5913
  navRef.current = node;
5914
5914
  if (typeof ref === "function") ref(node);
@@ -6001,7 +6001,7 @@ var NavigationRailComponent = React38.forwardRef(
6001
6001
  children: fab
6002
6002
  }
6003
6003
  ),
6004
- React38.cloneElement(
6004
+ React39.cloneElement(
6005
6005
  navElement,
6006
6006
  {
6007
6007
  className: cn(navBaseClasses, "pointer-events-auto")
@@ -6046,7 +6046,7 @@ var NavigationRailComponent = React38.forwardRef(
6046
6046
  }
6047
6047
  );
6048
6048
  NavigationRailComponent.displayName = "NavigationRail";
6049
- var NavigationRail = React38.memo(NavigationRailComponent);
6049
+ var NavigationRail = React39.memo(NavigationRailComponent);
6050
6050
  function useSearchKeyboard({
6051
6051
  active,
6052
6052
  onActiveChange,
@@ -6055,14 +6055,14 @@ function useSearchKeyboard({
6055
6055
  itemCount,
6056
6056
  onSelectSuggestion
6057
6057
  }) {
6058
- const [activeIndex, setActiveIndex] = React38.useState(-1);
6059
- const resetKeyRef = React38.useRef(`${active}:${query}`);
6058
+ const [activeIndex, setActiveIndex] = React39.useState(-1);
6059
+ const resetKeyRef = React39.useRef(`${active}:${query}`);
6060
6060
  const currentKey = `${active}:${query}`;
6061
6061
  if (resetKeyRef.current !== currentKey) {
6062
6062
  resetKeyRef.current = currentKey;
6063
6063
  setActiveIndex(-1);
6064
6064
  }
6065
- const handleKeyDown = React38.useCallback(
6065
+ const handleKeyDown = React39.useCallback(
6066
6066
  (e) => {
6067
6067
  if (!active) return;
6068
6068
  switch (e.key) {
@@ -6102,11 +6102,39 @@ function useSearchKeyboard({
6102
6102
  query
6103
6103
  ]
6104
6104
  );
6105
- const resetActiveIndex = React38.useCallback(() => {
6105
+ const resetActiveIndex = React39.useCallback(() => {
6106
6106
  setActiveIndex(-1);
6107
6107
  }, []);
6108
6108
  return { activeIndex, handleKeyDown, resetActiveIndex };
6109
6109
  }
6110
+ var StateLayer = React39.forwardRef(
6111
+ (_a, ref) => {
6112
+ var _b = _a, { className, hovered, focused, pressed } = _b, props = __objRest(_b, ["className", "hovered", "focused", "pressed"]);
6113
+ let opacity = 0;
6114
+ if (pressed) {
6115
+ opacity = 0.12;
6116
+ } else if (focused) {
6117
+ opacity = 0.1;
6118
+ } else if (hovered) {
6119
+ opacity = 0.08;
6120
+ }
6121
+ return /* @__PURE__ */ jsx(LazyMotion, { features: domMax, strict: true, children: /* @__PURE__ */ jsx(
6122
+ m.div,
6123
+ __spreadValues({
6124
+ ref,
6125
+ className: cn(
6126
+ "absolute inset-0 bg-current pointer-events-none rounded-[inherit]",
6127
+ className
6128
+ ),
6129
+ initial: false,
6130
+ animate: { opacity },
6131
+ transition: { duration: 0.2 },
6132
+ "aria-hidden": "true"
6133
+ }, props)
6134
+ ) });
6135
+ }
6136
+ );
6137
+ StateLayer.displayName = "StateLayer";
6110
6138
 
6111
6139
  // src/ui/search/search.tokens.ts
6112
6140
  var SearchTokens = {
@@ -6145,7 +6173,12 @@ var SEARCH_COLORS = {
6145
6173
  /** SearchViewTokens.DividerColor → outline */
6146
6174
  divider: "var(--md-sys-color-outline)",
6147
6175
  /** Focus indicator → secondary */
6148
- focusIndicator: "var(--md-sys-color-secondary)"
6176
+ focusIndicator: "var(--md-sys-color-secondary)",
6177
+ /** State layer overlay for interactive hover/press */
6178
+ stateLayer: "var(--md-sys-color-on-surface)"
6179
+ };
6180
+ var SEARCH_ELEVATION = {
6181
+ level3: "elevation-3"
6149
6182
  };
6150
6183
  var SEARCH_TYPOGRAPHY = {
6151
6184
  /** BodyLarge — used for input text and placeholder. */
@@ -6170,10 +6203,10 @@ function AnimatedPlaceholder({
6170
6203
  className
6171
6204
  }) {
6172
6205
  const shouldReduceMotion = useReducedMotion();
6173
- const containerRef = React38.useRef(null);
6174
- const spanRef = React38.useRef(null);
6175
- const [xOffset, setXOffset] = React38.useState(0);
6176
- const recalculate = React38.useCallback(() => {
6206
+ const containerRef = React39.useRef(null);
6207
+ const spanRef = React39.useRef(null);
6208
+ const [xOffset, setXOffset] = React39.useState(0);
6209
+ const recalculate = React39.useCallback(() => {
6177
6210
  const container = containerRef.current;
6178
6211
  const span = spanRef.current;
6179
6212
  if (!container || !span || textAlign === "left") {
@@ -6188,10 +6221,10 @@ function AnimatedPlaceholder({
6188
6221
  setXOffset(Math.max(0, containerWidth - textWidth));
6189
6222
  }
6190
6223
  }, [textAlign]);
6191
- React38.useLayoutEffect(() => {
6224
+ React39.useLayoutEffect(() => {
6192
6225
  recalculate();
6193
6226
  }, [recalculate]);
6194
- React38.useEffect(() => {
6227
+ React39.useEffect(() => {
6195
6228
  const container = containerRef.current;
6196
6229
  if (!container) return;
6197
6230
  const observer = new ResizeObserver(recalculate);
@@ -6250,6 +6283,7 @@ function SearchBar({
6250
6283
  onActiveChange,
6251
6284
  leadingIcon,
6252
6285
  trailingIcon,
6286
+ avatar,
6253
6287
  placeholder = "Search",
6254
6288
  textAlign = "left",
6255
6289
  className,
@@ -6260,10 +6294,13 @@ function SearchBar({
6260
6294
  activeIndex
6261
6295
  }) {
6262
6296
  const shouldReduceMotion = useReducedMotion();
6263
- const inputRef = React38.useRef(null);
6264
- const prevActiveRef = React38.useRef(active);
6265
- const isRestoringFocusRef = React38.useRef(false);
6266
- React38.useEffect(() => {
6297
+ const inputRef = React39.useRef(null);
6298
+ const prevActiveRef = React39.useRef(active);
6299
+ const isRestoringFocusRef = React39.useRef(false);
6300
+ const [isHovered, setIsHovered] = React39.useState(false);
6301
+ const [isPressed, setIsPressed] = React39.useState(false);
6302
+ const [isFocused, setIsFocused] = React39.useState(false);
6303
+ React39.useEffect(() => {
6267
6304
  var _a;
6268
6305
  let rafId;
6269
6306
  if (prevActiveRef.current === true && active === false) {
@@ -6279,10 +6316,14 @@ function SearchBar({
6279
6316
  };
6280
6317
  }, [active]);
6281
6318
  const handleFocus = () => {
6319
+ setIsFocused(true);
6282
6320
  if (!active && !isRestoringFocusRef.current) {
6283
6321
  onActiveChange(true);
6284
6322
  }
6285
6323
  };
6324
+ const handleBlur = () => {
6325
+ setIsFocused(false);
6326
+ };
6286
6327
  const handleFormSubmit = (e) => {
6287
6328
  e.preventDefault();
6288
6329
  onSearch(query);
@@ -6301,18 +6342,39 @@ function SearchBar({
6301
6342
  layout: !shouldReduceMotion,
6302
6343
  layoutId: shouldReduceMotion ? void 0 : searchId,
6303
6344
  transition: shouldReduceMotion ? void 0 : SEARCH_BAR_EXPAND_SPRING,
6304
- className: cn("relative", className),
6345
+ className: cn(
6346
+ "relative group select-none",
6347
+ SEARCH_ELEVATION.level3,
6348
+ className
6349
+ ),
6305
6350
  style: { height: SearchTokens.heights.bar },
6306
6351
  initial: shouldReduceMotion ? false : { opacity: 0, scale: 0.95 },
6307
6352
  animate: { opacity: 1, scale: 1 },
6308
6353
  exit: shouldReduceMotion ? {} : { opacity: 0, scale: 0.95, transition: SEARCH_BAR_EXIT_SPRING },
6354
+ onPointerEnter: () => setIsHovered(true),
6355
+ onPointerLeave: () => {
6356
+ setIsHovered(false);
6357
+ setIsPressed(false);
6358
+ },
6359
+ onPointerDown: () => setIsPressed(true),
6360
+ onPointerUp: () => setIsPressed(false),
6361
+ onPointerCancel: () => setIsPressed(false),
6309
6362
  children: [
6310
6363
  /* @__PURE__ */ jsx(
6311
6364
  "div",
6312
6365
  {
6313
- className: "absolute inset-0 rounded-full",
6366
+ className: "absolute inset-0 rounded-full overflow-hidden",
6314
6367
  style: { backgroundColor: SEARCH_COLORS.container },
6315
- "aria-hidden": "true"
6368
+ "aria-hidden": "true",
6369
+ children: /* @__PURE__ */ jsx(
6370
+ StateLayer,
6371
+ {
6372
+ hovered: isHovered,
6373
+ focused: isFocused,
6374
+ pressed: isPressed,
6375
+ style: { color: SEARCH_COLORS.stateLayer }
6376
+ }
6377
+ )
6316
6378
  }
6317
6379
  ),
6318
6380
  /* @__PURE__ */ jsx(
@@ -6358,21 +6420,36 @@ function SearchBar({
6358
6420
  ),
6359
6421
  style: { color: SEARCH_COLORS.inputText },
6360
6422
  onFocus: handleFocus,
6423
+ onBlur: handleBlur,
6361
6424
  onChange: (e) => onQueryChange(e.target.value),
6362
6425
  onKeyDown
6363
6426
  }
6364
6427
  )
6365
6428
  }
6366
6429
  ),
6367
- trailingIcon && /* @__PURE__ */ jsx(
6368
- "span",
6369
- {
6370
- className: "flex shrink-0 items-center justify-center",
6371
- style: { color: SEARCH_COLORS.trailingIcon },
6372
- "aria-hidden": "true",
6373
- children: trailingIcon
6374
- }
6375
- )
6430
+ (trailingIcon || avatar) && /* @__PURE__ */ jsxs("div", { className: "flex shrink-0 items-center gap-2", children: [
6431
+ trailingIcon && /* @__PURE__ */ jsx(
6432
+ "span",
6433
+ {
6434
+ className: "flex shrink-0 items-center justify-center",
6435
+ style: { color: SEARCH_COLORS.trailingIcon },
6436
+ "aria-hidden": "true",
6437
+ children: trailingIcon
6438
+ }
6439
+ ),
6440
+ avatar && /* @__PURE__ */ jsx(
6441
+ "span",
6442
+ {
6443
+ className: "flex shrink-0 items-center justify-center rounded-full overflow-hidden",
6444
+ style: {
6445
+ width: SearchTokens.avatarSize,
6446
+ height: SearchTokens.avatarSize
6447
+ },
6448
+ "aria-hidden": "true",
6449
+ children: avatar
6450
+ }
6451
+ )
6452
+ ] })
6376
6453
  ] })
6377
6454
  }
6378
6455
  )
@@ -6382,7 +6459,7 @@ function SearchBar({
6382
6459
  ) })
6383
6460
  );
6384
6461
  }
6385
- var SearchContext = React38.createContext(null);
6462
+ var SearchContext = React39.createContext(null);
6386
6463
  function SearchProvider({
6387
6464
  children,
6388
6465
  value
@@ -6390,7 +6467,7 @@ function SearchProvider({
6390
6467
  return /* @__PURE__ */ jsx(SearchContext.Provider, { value, children });
6391
6468
  }
6392
6469
  function useSearch() {
6393
- const context = React38.useContext(SearchContext);
6470
+ const context = React39.useContext(SearchContext);
6394
6471
  if (!context) {
6395
6472
  return { listboxId: "", activeIndex: -1 };
6396
6473
  }
@@ -6417,7 +6494,7 @@ function useClickOutside(handler, enabled = true) {
6417
6494
  return ref;
6418
6495
  }
6419
6496
  function useSearchViewFocus(inputRef, active) {
6420
- React38.useEffect(() => {
6497
+ React39.useEffect(() => {
6421
6498
  if (!active) return;
6422
6499
  let raf2;
6423
6500
  const raf1 = requestAnimationFrame(() => {
@@ -6477,11 +6554,11 @@ var ROTATE_KEY_SPLINES = [
6477
6554
  var ROTATE_VALUES = "0 24 24; 154 24 24; 309 24 24; 463 24 24; 617 24 24; 771 24 24; 926 24 24; 1080 24 24";
6478
6555
  var DETERMINATE_CIRCLE = "M24 7 C34.49 7 41 13.51 41 24 C41 34.49 34.49 41 24 41 C13.51 41 7 34.49 7 24 C7 13.51 13.51 7 24 7 Z";
6479
6556
  var DETERMINATE_SOFT_BURST = "M20.9 10.4 21.4 9.5 21.9 8.7 22.5 7.8 23.2 7.2 24.2 7 25.1 7.4 25.7 8.1 26.2 9 26.8 9.8 27.3 10.6 28.1 11.2 29 11.3 30 11 30.9 10.6 31.8 10.3 32.8 9.9 33.7 10 34.5 10.6 34.9 11.5 34.8 12.5 34.8 13.5 34.7 14.5 34.7 15.5 35.2 16.3 36 16.8 37 17.1 37.9 17.3 38.9 17.5 39.8 17.9 40.4 18.7 40.5 19.7 40 20.5 39.4 21.3 38.7 22 38.1 22.8 37.6 23.7 37.7 24.6 38.3 25.5 38.9 26.2 39.6 27 40.2 27.7 40.5 28.7 40.3 29.6 39.5 30.3 38.6 30.6 37.6 30.8 36.7 31 35.7 31.3 35 31.9 34.6 32.8 34.7 33.8 34.8 34.8 34.9 35.8 34.8 36.8 34.3 37.6 33.4 38.1 32.4 38 31.5 37.6 30.6 37.2 29.7 36.9 28.7 36.6 27.8 36.9 27.1 37.6 26.6 38.5 26.1 39.3 25.5 40.2 24.8 40.8 23.8 41 22.9 40.6 22.3 39.9 21.8 39 21.2 38.2 20.7 37.4 19.9 36.8 19 36.7 18 37 17.1 37.4 16.2 37.7 15.2 38.1 14.3 38 13.5 37.4 13.1 36.5 13.2 35.5 13.2 34.5 13.3 33.5 13.3 32.5 12.8 31.7 12 31.2 11 31 10.1 30.7 9.1 30.5 8.2 30.1 7.6 29.3 7.5 28.3 8 27.5 8.7 26.7 9.3 26 9.9 25.2 10.4 24.3 10.3 23.4 9.7 22.5 9.1 21.8 8.4 21 7.8 20.3 7.5 19.3 7.7 18.4 8.5 17.7 9.4 17.4 10.4 17.2 11.3 17 12.3 16.7 13 16.1 13.4 15.2 13.3 14.2 13.2 13.2 13.1 12.2 13.2 11.2 13.7 10.4 14.6 9.9 15.6 10 16.5 10.4 17.4 10.8 18.3 11.1 19.3 11.4 20.2 11.1Z";
6480
- var IndeterminateSvg = React38.memo(function IndeterminateSvg2({
6557
+ var IndeterminateSvg = React39.memo(function IndeterminateSvg2({
6481
6558
  size
6482
6559
  }) {
6483
- const [ready, setReady] = React38.useState(false);
6484
- React38.useEffect(() => {
6560
+ const [ready, setReady] = React39.useState(false);
6561
+ React39.useEffect(() => {
6485
6562
  const raf = requestAnimationFrame(() => setReady(true));
6486
6563
  return () => cancelAnimationFrame(raf);
6487
6564
  }, []);
@@ -6526,7 +6603,7 @@ var IndeterminateSvg = React38.memo(function IndeterminateSvg2({
6526
6603
  }
6527
6604
  );
6528
6605
  });
6529
- var DeterminateSvg = React38.memo(function DeterminateSvg2({
6606
+ var DeterminateSvg = React39.memo(function DeterminateSvg2({
6530
6607
  size,
6531
6608
  progress
6532
6609
  }) {
@@ -6551,7 +6628,7 @@ var DeterminateSvg = React38.memo(function DeterminateSvg2({
6551
6628
  }
6552
6629
  );
6553
6630
  });
6554
- var LoadingIndicator = React38.forwardRef(
6631
+ var LoadingIndicator = React39.forwardRef(
6555
6632
  (_a, ref) => {
6556
6633
  var _b = _a, {
6557
6634
  variant = "uncontained",
@@ -6686,7 +6763,7 @@ var ADDITIONAL_ROTATION_EASE_DURATION = 500;
6686
6763
  var DEFAULT_MIN_PROGRESS = 0.1;
6687
6764
  var DEFAULT_MAX_PROGRESS = 0.8;
6688
6765
  var PROGRESS_CYCLE_DURATION = 1500;
6689
- var CircularProgress = React38.forwardRef(
6766
+ var CircularProgress = React39.forwardRef(
6690
6767
  (_a, ref) => {
6691
6768
  var _b = _a, {
6692
6769
  value,
@@ -6740,19 +6817,19 @@ var CircularProgress = React38.forwardRef(
6740
6817
  const shouldShowDeterminateTrack = showTrack === "auto" ? true : showTrack;
6741
6818
  const BASELINE_SIZE = 48;
6742
6819
  const scaleFactor = size / BASELINE_SIZE;
6743
- const effectiveAmplitude = React38.useMemo(
6820
+ const effectiveAmplitude = React39.useMemo(
6744
6821
  () => amplitude != null ? amplitude : 1.6 * scaleFactor,
6745
6822
  [amplitude, scaleFactor]
6746
6823
  );
6747
- const effectiveWavelength = React38.useMemo(
6824
+ const effectiveWavelength = React39.useMemo(
6748
6825
  () => wavelength != null ? wavelength : 15 * scaleFactor,
6749
6826
  [wavelength, scaleFactor]
6750
6827
  );
6751
- const resolvedAmplitudeRange = React38.useMemo(
6828
+ const resolvedAmplitudeRange = React39.useMemo(
6752
6829
  () => amplitudeRange != null ? amplitudeRange : [0, effectiveAmplitude],
6753
6830
  [amplitudeRange, effectiveAmplitude]
6754
6831
  );
6755
- const wavyActivePath = React38.useMemo(
6832
+ const wavyActivePath = React39.useMemo(
6756
6833
  () => isWavy ? generateWavyCircularPath(
6757
6834
  center,
6758
6835
  radius,
@@ -6761,8 +6838,8 @@ var CircularProgress = React38.forwardRef(
6761
6838
  ) : null,
6762
6839
  [isWavy, center, radius, effectiveAmplitude, effectiveWavelength]
6763
6840
  );
6764
- const circumference = React38.useMemo(() => 2 * Math.PI * radius, [radius]);
6765
- const gapForTrack = React38.useMemo(
6841
+ const circumference = React39.useMemo(() => 2 * Math.PI * radius, [radius]);
6842
+ const gapForTrack = React39.useMemo(
6766
6843
  () => (gapSize + trackHeight) / circumference,
6767
6844
  [gapSize, trackHeight, circumference]
6768
6845
  );
@@ -6770,17 +6847,17 @@ var CircularProgress = React38.forwardRef(
6770
6847
  const trackOffset = isDeterminate ? activeAngularFraction + gapForTrack : 0;
6771
6848
  const trackLength = isDeterminate ? Math.max(1e-3, 1 - activeAngularFraction - 2 * gapForTrack) : 1;
6772
6849
  const ActiveCircleElem = m.circle;
6773
- const indeterminateSvgRef = React38.useRef(null);
6774
- const indeterminateTrackRef = React38.useRef(null);
6775
- const indeterminateActiveRef = React38.useRef(null);
6776
- const indeterminateWavyTrackPathRef = React38.useRef(null);
6777
- const indeterminateWavyActivePathRef = React38.useRef(null);
6778
- const determinateWavyActivePathRef = React38.useRef(null);
6779
- const determinateWavyTrackPathRef = React38.useRef(null);
6780
- const cachedPathLengthRef = React38.useRef(0);
6850
+ const indeterminateSvgRef = React39.useRef(null);
6851
+ const indeterminateTrackRef = React39.useRef(null);
6852
+ const indeterminateActiveRef = React39.useRef(null);
6853
+ const indeterminateWavyTrackPathRef = React39.useRef(null);
6854
+ const indeterminateWavyActivePathRef = React39.useRef(null);
6855
+ const determinateWavyActivePathRef = React39.useRef(null);
6856
+ const determinateWavyTrackPathRef = React39.useRef(null);
6857
+ const cachedPathLengthRef = React39.useRef(0);
6781
6858
  const fractionMV = useMotionValue(isDeterminate ? clampedValue / 100 : 0);
6782
6859
  const amplitudeMV = useMotionValue(isWavy ? effectiveAmplitude : 0);
6783
- React38.useEffect(() => {
6860
+ React39.useEffect(() => {
6784
6861
  if (isDeterminate) {
6785
6862
  animate(fractionMV, clampedValue / 100, {
6786
6863
  duration: 0.4,
@@ -6788,7 +6865,7 @@ var CircularProgress = React38.forwardRef(
6788
6865
  });
6789
6866
  }
6790
6867
  }, [clampedValue, isDeterminate, fractionMV]);
6791
- React38.useEffect(() => {
6868
+ React39.useEffect(() => {
6792
6869
  if (!isDeterminate || !isWavy) return;
6793
6870
  const fraction = clampedValue / 100;
6794
6871
  let targetAmp = effectiveAmplitude;
@@ -6808,7 +6885,7 @@ var CircularProgress = React38.forwardRef(
6808
6885
  amplitudeMV,
6809
6886
  determinateAnimation
6810
6887
  ]);
6811
- React38.useLayoutEffect(() => {
6888
+ React39.useLayoutEffect(() => {
6812
6889
  if (!isWavy || !wavyActivePath) {
6813
6890
  cachedPathLengthRef.current = circumference;
6814
6891
  return;
@@ -7185,9 +7262,9 @@ var CircularProgress = React38.forwardRef(
7185
7262
  );
7186
7263
  CircularProgress.displayName = "CircularProgress";
7187
7264
  function useContainerWidth() {
7188
- const [width, setWidth] = React38.useState(0);
7189
- const observerRef = React38.useRef(null);
7190
- const ref = React38.useCallback((node) => {
7265
+ const [width, setWidth] = React39.useState(0);
7266
+ const observerRef = React39.useRef(null);
7267
+ const ref = React39.useCallback((node) => {
7191
7268
  if (observerRef.current) {
7192
7269
  observerRef.current.disconnect();
7193
7270
  observerRef.current = null;
@@ -7201,7 +7278,7 @@ function useContainerWidth() {
7201
7278
  observerRef.current = obs;
7202
7279
  }
7203
7280
  }, []);
7204
- React38.useEffect(() => {
7281
+ React39.useEffect(() => {
7205
7282
  return () => {
7206
7283
  if (observerRef.current) {
7207
7284
  observerRef.current.disconnect();
@@ -7211,7 +7288,7 @@ function useContainerWidth() {
7211
7288
  return [ref, width];
7212
7289
  }
7213
7290
  function useMergedRef(...refs) {
7214
- return React38.useCallback(
7291
+ return React39.useCallback(
7215
7292
  (node) => {
7216
7293
  for (const ref of refs) {
7217
7294
  if (typeof ref === "function") {
@@ -7225,7 +7302,7 @@ function useMergedRef(...refs) {
7225
7302
  [refs]
7226
7303
  );
7227
7304
  }
7228
- var FlatLinearTrack = React38.memo(function FlatLinearTrack2({
7305
+ var FlatLinearTrack = React39.memo(function FlatLinearTrack2({
7229
7306
  trackHeight,
7230
7307
  activeColor,
7231
7308
  trackColor,
@@ -7301,7 +7378,7 @@ var FlatLinearTrack = React38.memo(function FlatLinearTrack2({
7301
7378
  }
7302
7379
  );
7303
7380
  });
7304
- var WavyLinearTrack = React38.memo(function WavyLinearTrack2({
7381
+ var WavyLinearTrack = React39.memo(function WavyLinearTrack2({
7305
7382
  trackHeight,
7306
7383
  svgHeight,
7307
7384
  amplitude,
@@ -7320,13 +7397,13 @@ var WavyLinearTrack = React38.memo(function WavyLinearTrack2({
7320
7397
  }) {
7321
7398
  const isDeterminate = typeof value === "number";
7322
7399
  const clampedValue = isDeterminate ? Math.max(0, Math.min(100, value)) : 100;
7323
- const titleId = React38.useId();
7400
+ const titleId = React39.useId();
7324
7401
  const [containerRef, width] = useContainerWidth();
7325
- const activePathRef = React38.useRef(null);
7326
- const trackPathRef = React38.useRef(null);
7402
+ const activePathRef = React39.useRef(null);
7403
+ const trackPathRef = React39.useRef(null);
7327
7404
  const amplitudeMV = useMotionValue(amplitude);
7328
7405
  const fractionMV = useMotionValue(isDeterminate ? clampedValue / 100 : 1);
7329
- React38.useEffect(() => {
7406
+ React39.useEffect(() => {
7330
7407
  if (isDeterminate) {
7331
7408
  const fraction = clampedValue / 100;
7332
7409
  let targetAmp = amplitude;
@@ -7514,7 +7591,7 @@ var WavyLinearTrack = React38.memo(function WavyLinearTrack2({
7514
7591
  }
7515
7592
  );
7516
7593
  });
7517
- var LinearProgress = React38.forwardRef(
7594
+ var LinearProgress = React39.forwardRef(
7518
7595
  (_a, ref) => {
7519
7596
  var _b = _a, {
7520
7597
  value,
@@ -7555,10 +7632,10 @@ var LinearProgress = React38.forwardRef(
7555
7632
  ]);
7556
7633
  const isDeterminate = value !== void 0;
7557
7634
  const clampedValue = isDeterminate ? Math.min(100, Math.max(0, value)) : 0;
7558
- const containerRef = React38.useRef(null);
7635
+ const containerRef = React39.useRef(null);
7559
7636
  const mergedRef = useMergedRef(ref, containerRef);
7560
- const [isRtl, setIsRtl] = React38.useState(false);
7561
- React38.useEffect(() => {
7637
+ const [isRtl, setIsRtl] = React39.useState(false);
7638
+ React39.useEffect(() => {
7562
7639
  if (containerRef.current) {
7563
7640
  const dir = getComputedStyle(containerRef.current).direction;
7564
7641
  setIsRtl(dir === "rtl");
@@ -7566,16 +7643,16 @@ var LinearProgress = React38.forwardRef(
7566
7643
  }, []);
7567
7644
  const resolvedTrackShape = trackShape != null ? trackShape : shape;
7568
7645
  const isWavy = shape === "wavy" || resolvedTrackShape === "wavy";
7569
- const effectiveAmplitude = React38.useMemo(() => amplitude != null ? amplitude : 3, [amplitude]);
7570
- const svgHeight = React38.useMemo(
7646
+ const effectiveAmplitude = React39.useMemo(() => amplitude != null ? amplitude : 3, [amplitude]);
7647
+ const svgHeight = React39.useMemo(
7571
7648
  () => isWavy ? trackHeight + effectiveAmplitude * 2 : trackHeight,
7572
7649
  [isWavy, trackHeight, effectiveAmplitude]
7573
7650
  );
7574
- const shouldShowStop = React38.useMemo(
7651
+ const shouldShowStop = React39.useMemo(
7575
7652
  () => isDeterminate && resolvedTrackShape === "flat" && showStopIndicator !== false,
7576
7653
  [isDeterminate, resolvedTrackShape, showStopIndicator]
7577
7654
  );
7578
- const stopSize = React38.useMemo(
7655
+ const stopSize = React39.useMemo(
7579
7656
  () => Math.max(2, trackHeight > 4 ? 4 : trackHeight / 2),
7580
7657
  [trackHeight]
7581
7658
  );
@@ -7650,7 +7727,7 @@ var LinearProgress = React38.forwardRef(
7650
7727
  }
7651
7728
  );
7652
7729
  LinearProgress.displayName = "LinearProgress";
7653
- var ProgressIndicator = React38.forwardRef((props, ref) => {
7730
+ var ProgressIndicator = React39.forwardRef((props, ref) => {
7654
7731
  if (props.variant === "circular") {
7655
7732
  return /* @__PURE__ */ jsx(CircularProgress, __spreadValues({ ref }, props));
7656
7733
  }
@@ -7782,7 +7859,7 @@ function resolveDisabledBgClass(colorStyle) {
7782
7859
  }
7783
7860
  return "disabled:text-m3-on-surface/[0.38]";
7784
7861
  }
7785
- var IconButtonComponent = React38.forwardRef(
7862
+ var IconButtonComponent = React39.forwardRef(
7786
7863
  (_a, ref) => {
7787
7864
  var _b = _a, {
7788
7865
  className,
@@ -7824,18 +7901,18 @@ var IconButtonComponent = React38.forwardRef(
7824
7901
  var _a2, _b2, _c, _d, _e;
7825
7902
  const isToggle = variant === "toggle";
7826
7903
  const isSelected = isToggle && !!selected;
7827
- const resolvedColorClass = React38.useMemo(
7904
+ const resolvedColorClass = React39.useMemo(
7828
7905
  () => isSelected ? colorStyles[colorStyle].selected : colorStyles[colorStyle].default,
7829
7906
  [isSelected, colorStyle]
7830
7907
  );
7831
- const outlineWidthClass = React38.useMemo(
7908
+ const outlineWidthClass = React39.useMemo(
7832
7909
  () => {
7833
7910
  var _a3;
7834
7911
  return colorStyle === "outlined" && !isSelected ? (_a3 = SIZE_OUTLINE_WIDTH[size]) != null ? _a3 : "border" : "";
7835
7912
  },
7836
7913
  [colorStyle, isSelected, size]
7837
7914
  );
7838
- const disabledBgClass = React38.useMemo(
7915
+ const disabledBgClass = React39.useMemo(
7839
7916
  () => resolveDisabledBgClass(colorStyle),
7840
7917
  [colorStyle]
7841
7918
  );
@@ -7858,7 +7935,7 @@ var IconButtonComponent = React38.forwardRef(
7858
7935
  const { ripples, onPointerDown, removeRipple } = useRippleState({
7859
7936
  disabled: loading
7860
7937
  });
7861
- const handleClick = React38.useCallback(
7938
+ const handleClick = React39.useCallback(
7862
7939
  (e) => {
7863
7940
  if (loading) {
7864
7941
  e.preventDefault();
@@ -7868,7 +7945,7 @@ var IconButtonComponent = React38.forwardRef(
7868
7945
  },
7869
7946
  [loading, onClick]
7870
7947
  );
7871
- const handleKeyDown = React38.useCallback(
7948
+ const handleKeyDown = React39.useCallback(
7872
7949
  (e) => {
7873
7950
  if (loading) return;
7874
7951
  if ((e.key === "Enter" || e.key === " ") && onClick) {
@@ -7924,7 +8001,7 @@ var IconButtonComponent = React38.forwardRef(
7924
8001
  width: isCustomSize ? `${iconSize}px` : void 0,
7925
8002
  height: isCustomSize ? `${iconSize}px` : void 0
7926
8003
  },
7927
- children: isSelected && selectedIcon ? selectedIcon : asChild ? React38.Children.only(children).props.children : children
8004
+ children: isSelected && selectedIcon ? selectedIcon : asChild ? React39.Children.only(children).props.children : children
7928
8005
  }),
7929
8006
  isSelected && selectedIcon ? "selected-content" : "content"
7930
8007
  ) })
@@ -7941,7 +8018,7 @@ var IconButtonComponent = React38.forwardRef(
7941
8018
  className
7942
8019
  );
7943
8020
  if (asChild) {
7944
- const child = React38.Children.only(children);
8021
+ const child = React39.Children.only(children);
7945
8022
  return /* @__PURE__ */ jsx(LazyMotion, { features: domMax, strict: true, children: /* @__PURE__ */ jsx(
7946
8023
  Slot,
7947
8024
  __spreadProps(__spreadValues({
@@ -7958,7 +8035,7 @@ var IconButtonComponent = React38.forwardRef(
7958
8035
  }),
7959
8036
  className: containerClassName
7960
8037
  }, restProps), {
7961
- children: React38.cloneElement(child, { children: innerContent })
8038
+ children: React39.cloneElement(child, { children: innerContent })
7962
8039
  })
7963
8040
  ) });
7964
8041
  }
@@ -7986,44 +8063,81 @@ var IconButtonComponent = React38.forwardRef(
7986
8063
  }
7987
8064
  );
7988
8065
  IconButtonComponent.displayName = "IconButton";
7989
- var IconButton = React38.memo(IconButtonComponent);
8066
+ var IconButton = React39.memo(IconButtonComponent);
7990
8067
  function TrailingAction({
7991
8068
  query,
7992
8069
  trailingIcon,
8070
+ avatar,
7993
8071
  onClear
7994
8072
  }) {
7995
- if (query) {
7996
- return /* @__PURE__ */ jsx(
7997
- IconButton,
8073
+ const shouldReduceMotion = useReducedMotion();
8074
+ return /* @__PURE__ */ jsxs("div", { className: "flex shrink-0 items-center gap-2", children: [
8075
+ /* @__PURE__ */ jsx(AnimatePresence, { mode: "wait", initial: false, children: query ? /* @__PURE__ */ jsx(
8076
+ m.div,
7998
8077
  {
7999
- size: "sm",
8000
- style: { color: SEARCH_COLORS.trailingIcon },
8001
- "aria-label": "Clear search",
8002
- onClick: onClear,
8078
+ initial: shouldReduceMotion ? false : { opacity: 0, scale: 0.8 },
8079
+ animate: { opacity: 1, scale: 1 },
8080
+ exit: shouldReduceMotion ? {} : { opacity: 0, scale: 0.8 },
8081
+ transition: { duration: 0.15 },
8082
+ className: "flex items-center justify-center",
8003
8083
  children: /* @__PURE__ */ jsx(
8004
- "span",
8084
+ IconButton,
8005
8085
  {
8006
- className: "material-symbols-rounded select-none leading-none",
8007
- style: { fontSize: 20 },
8008
- "aria-hidden": "true",
8009
- children: "close"
8086
+ size: "sm",
8087
+ style: { color: SEARCH_COLORS.trailingIcon },
8088
+ "aria-label": "Clear search",
8089
+ onClick: onClear,
8090
+ children: /* @__PURE__ */ jsx(
8091
+ "span",
8092
+ {
8093
+ className: "material-symbols-rounded select-none leading-none",
8094
+ style: { fontSize: 20 },
8095
+ "aria-hidden": "true",
8096
+ children: "close"
8097
+ }
8098
+ )
8010
8099
  }
8011
8100
  )
8012
- }
8013
- );
8014
- }
8015
- if (trailingIcon) {
8016
- return /* @__PURE__ */ jsx(
8017
- "span",
8101
+ },
8102
+ "clear-action"
8103
+ ) : trailingIcon && /* @__PURE__ */ jsx(
8104
+ m.span,
8018
8105
  {
8106
+ initial: shouldReduceMotion ? false : { opacity: 0, scale: 0.8 },
8107
+ animate: { opacity: 1, scale: 1 },
8108
+ exit: shouldReduceMotion ? {} : { opacity: 0, scale: 0.8 },
8109
+ transition: { duration: 0.15 },
8019
8110
  className: "flex shrink-0 items-center justify-center",
8020
8111
  style: { color: SEARCH_COLORS.trailingIcon },
8021
8112
  "aria-hidden": "true",
8022
8113
  children: trailingIcon
8114
+ },
8115
+ "trailing-icon"
8116
+ ) }),
8117
+ avatar && /* @__PURE__ */ jsx(
8118
+ "span",
8119
+ {
8120
+ className: "flex shrink-0 items-center justify-center rounded-full overflow-hidden",
8121
+ style: {
8122
+ width: SearchTokens.avatarSize,
8123
+ height: SearchTokens.avatarSize
8124
+ },
8125
+ "aria-hidden": "true",
8126
+ children: avatar
8023
8127
  }
8024
- );
8025
- }
8026
- return null;
8128
+ )
8129
+ ] });
8130
+ }
8131
+ function DefaultSearchIcon2() {
8132
+ return /* @__PURE__ */ jsx(
8133
+ "span",
8134
+ {
8135
+ className: "material-symbols-rounded select-none leading-none",
8136
+ style: { fontSize: SearchTokens.iconSize },
8137
+ "aria-hidden": "true",
8138
+ children: "search"
8139
+ }
8140
+ );
8027
8141
  }
8028
8142
  function SearchViewDocked({
8029
8143
  query,
@@ -8033,6 +8147,7 @@ function SearchViewDocked({
8033
8147
  onActiveChange,
8034
8148
  leadingIcon,
8035
8149
  trailingIcon,
8150
+ avatar,
8036
8151
  placeholder = "Search",
8037
8152
  textAlign = "left",
8038
8153
  styleType = "contained",
@@ -8046,7 +8161,7 @@ function SearchViewDocked({
8046
8161
  activeIndex
8047
8162
  }) {
8048
8163
  const shouldReduceMotion = useReducedMotion();
8049
- const inputRef = React38.useRef(null);
8164
+ const inputRef = React39.useRef(null);
8050
8165
  useSearchViewFocus(inputRef, active);
8051
8166
  const dropdownRef = useClickOutside(() => {
8052
8167
  onActiveChange(false);
@@ -8065,10 +8180,12 @@ function SearchViewDocked({
8065
8180
  m.div,
8066
8181
  {
8067
8182
  ref: dropdownRef,
8183
+ layout: !shouldReduceMotion,
8068
8184
  layoutId: shouldReduceMotion ? void 0 : searchId,
8069
8185
  className: cn(
8070
8186
  // DockedContainerShape = CornerExtraLarge = 28dp radius
8071
8187
  "rounded-[28px] overflow-hidden",
8188
+ SEARCH_ELEVATION.level3,
8072
8189
  viewClassName
8073
8190
  ),
8074
8191
  style: { backgroundColor: SEARCH_COLORS.container },
@@ -8090,7 +8207,7 @@ function SearchViewDocked({
8090
8207
  className: "flex shrink-0 items-center justify-center",
8091
8208
  style: { color: SEARCH_COLORS.leadingIcon },
8092
8209
  "aria-hidden": "true",
8093
- children: leadingIcon
8210
+ children: leadingIcon != null ? leadingIcon : /* @__PURE__ */ jsx(DefaultSearchIcon2, {})
8094
8211
  }
8095
8212
  ),
8096
8213
  /* @__PURE__ */ jsx(
@@ -8131,6 +8248,7 @@ function SearchViewDocked({
8131
8248
  {
8132
8249
  query,
8133
8250
  trailingIcon,
8251
+ avatar,
8134
8252
  onClear: () => onQueryChange("")
8135
8253
  }
8136
8254
  )
@@ -8151,7 +8269,7 @@ function SearchViewDocked({
8151
8269
  id: listboxId,
8152
8270
  role: "listbox",
8153
8271
  "aria-label": `${ariaLabel} results`,
8154
- className: "min-h-30",
8272
+ className: "min-h-[120px]",
8155
8273
  children
8156
8274
  }
8157
8275
  )
@@ -8180,6 +8298,7 @@ function SearchViewFullScreen({
8180
8298
  onActiveChange,
8181
8299
  leadingIcon,
8182
8300
  trailingIcon,
8301
+ avatar,
8183
8302
  placeholder = "Search",
8184
8303
  textAlign = "left",
8185
8304
  styleType = "contained",
@@ -8192,10 +8311,10 @@ function SearchViewFullScreen({
8192
8311
  activeIndex
8193
8312
  }) {
8194
8313
  const shouldReduceMotion = useReducedMotion();
8195
- const inputRef = React38.useRef(null);
8314
+ const inputRef = React39.useRef(null);
8196
8315
  useSearchViewFocus(inputRef, active);
8197
- const [mounted, setMounted] = React38.useState(false);
8198
- React38.useEffect(() => {
8316
+ const [mounted, setMounted] = React39.useState(false);
8317
+ React39.useEffect(() => {
8199
8318
  setMounted(true);
8200
8319
  }, []);
8201
8320
  const handleFormSubmit = (e) => {
@@ -8294,6 +8413,7 @@ function SearchViewFullScreen({
8294
8413
  {
8295
8414
  query,
8296
8415
  trailingIcon,
8416
+ avatar,
8297
8417
  onClear: () => onQueryChange("")
8298
8418
  }
8299
8419
  )
@@ -8345,6 +8465,7 @@ function SearchComponent({
8345
8465
  hasGap = false,
8346
8466
  leadingIcon,
8347
8467
  trailingIcon,
8468
+ avatar,
8348
8469
  placeholder = "Search",
8349
8470
  textAlign = "left",
8350
8471
  children,
@@ -8353,10 +8474,10 @@ function SearchComponent({
8353
8474
  className,
8354
8475
  viewClassName
8355
8476
  }) {
8356
- const generatedId = React38.useId();
8477
+ const generatedId = React39.useId();
8357
8478
  const searchId = id != null ? id : generatedId;
8358
8479
  const listboxId = `${searchId}-listbox`;
8359
- const itemCount = React38.Children.count(children);
8480
+ const itemCount = React39.Children.count(children);
8360
8481
  const { activeIndex, handleKeyDown } = useSearchKeyboard({
8361
8482
  active,
8362
8483
  onActiveChange,
@@ -8372,6 +8493,7 @@ function SearchComponent({
8372
8493
  onActiveChange,
8373
8494
  leadingIcon,
8374
8495
  trailingIcon,
8496
+ avatar,
8375
8497
  placeholder,
8376
8498
  textAlign,
8377
8499
  "aria-label": ariaLabel,
@@ -8415,9 +8537,9 @@ function formatBadgeLabel(children, max) {
8415
8537
  return "";
8416
8538
  }
8417
8539
  function detectBadgeHasContent(badge) {
8418
- return React38.isValidElement(badge) && badge.props.children != null;
8540
+ return React39.isValidElement(badge) && badge.props.children != null;
8419
8541
  }
8420
- var BadgeImpl = React38.forwardRef(
8542
+ var BadgeImpl = React39.forwardRef(
8421
8543
  (_a, ref) => {
8422
8544
  var _b = _a, {
8423
8545
  children,
@@ -8471,7 +8593,7 @@ var BadgeImpl = React38.forwardRef(
8471
8593
  }
8472
8594
  );
8473
8595
  BadgeImpl.displayName = "Badge";
8474
- React38.memo(BadgeImpl);
8596
+ React39.memo(BadgeImpl);
8475
8597
  function BadgedBox({
8476
8598
  badge,
8477
8599
  children,
@@ -8492,9 +8614,9 @@ function BadgedBox({
8492
8614
  )
8493
8615
  ] });
8494
8616
  }
8495
- var TabsContext = React38.createContext(null);
8617
+ var TabsContext = React39.createContext(null);
8496
8618
  function useTabsContext() {
8497
- const ctx = React38.useContext(TabsContext);
8619
+ const ctx = React39.useContext(TabsContext);
8498
8620
  if (!ctx) {
8499
8621
  throw new Error(
8500
8622
  "[MD3 Tabs] Component must be used within a <Tabs> root. Ensure <TabsList>, <Tab>, and <TabsContent> are descendants of <Tabs>."
@@ -8502,7 +8624,7 @@ function useTabsContext() {
8502
8624
  }
8503
8625
  return ctx;
8504
8626
  }
8505
- var TabsComponent = React38.forwardRef(
8627
+ var TabsComponent = React39.forwardRef(
8506
8628
  ({
8507
8629
  value: controlledValue,
8508
8630
  defaultValue = "",
@@ -8511,35 +8633,35 @@ var TabsComponent = React38.forwardRef(
8511
8633
  children,
8512
8634
  className
8513
8635
  }, ref) => {
8514
- const [internalValue, setInternalValue] = React38.useState(defaultValue);
8636
+ const [internalValue, setInternalValue] = React39.useState(defaultValue);
8515
8637
  const isControlled = controlledValue !== void 0;
8516
8638
  const value = isControlled ? controlledValue : internalValue;
8517
- const handleValueChange = React38.useCallback(
8639
+ const handleValueChange = React39.useCallback(
8518
8640
  (newValue) => {
8519
8641
  if (!isControlled) setInternalValue(newValue);
8520
8642
  onValueChange == null ? void 0 : onValueChange(newValue);
8521
8643
  },
8522
8644
  [isControlled, onValueChange]
8523
8645
  );
8524
- const [focusedValue, setFocusedValue] = React38.useState(value);
8525
- React38.useEffect(() => {
8646
+ const [focusedValue, setFocusedValue] = React39.useState(value);
8647
+ React39.useEffect(() => {
8526
8648
  setFocusedValue(value);
8527
8649
  }, [value]);
8528
- const [tabValues, setTabValues] = React38.useState([]);
8529
- const registerTab = React38.useCallback((tabValue) => {
8650
+ const [tabValues, setTabValues] = React39.useState([]);
8651
+ const registerTab = React39.useCallback((tabValue) => {
8530
8652
  setTabValues((prev) => {
8531
8653
  if (prev.includes(tabValue)) return prev;
8532
8654
  return [...prev, tabValue];
8533
8655
  });
8534
8656
  }, []);
8535
- const unregisterTab = React38.useCallback((tabValue) => {
8657
+ const unregisterTab = React39.useCallback((tabValue) => {
8536
8658
  setTabValues((prev) => prev.filter((v) => v !== tabValue));
8537
8659
  }, []);
8538
- const hasAutoSelected = React38.useRef(false);
8539
- const [disabledValues, setDisabledValues] = React38.useState(
8660
+ const hasAutoSelected = React39.useRef(false);
8661
+ const [disabledValues, setDisabledValues] = React39.useState(
8540
8662
  /* @__PURE__ */ new Set()
8541
8663
  );
8542
- const markTabDisabled = React38.useCallback(
8664
+ const markTabDisabled = React39.useCallback(
8543
8665
  (tabValue, disabled) => {
8544
8666
  setDisabledValues((prev) => {
8545
8667
  const next = new Set(prev);
@@ -8553,7 +8675,7 @@ var TabsComponent = React38.forwardRef(
8553
8675
  },
8554
8676
  []
8555
8677
  );
8556
- React38.useEffect(() => {
8678
+ React39.useEffect(() => {
8557
8679
  if (isControlled || hasAutoSelected.current || tabValues.length === 0) {
8558
8680
  return;
8559
8681
  }
@@ -8568,9 +8690,9 @@ var TabsComponent = React38.forwardRef(
8568
8690
  setFocusedValue(firstEnabled);
8569
8691
  }
8570
8692
  }, [tabValues, disabledValues, isControlled, value]);
8571
- const id = React38.useId();
8693
+ const id = React39.useId();
8572
8694
  const layoutGroupId = `tabs-${id}`;
8573
- const contextValue = React38.useMemo(
8695
+ const contextValue = React39.useMemo(
8574
8696
  () => ({
8575
8697
  value,
8576
8698
  onValueChange: handleValueChange,
@@ -8601,12 +8723,12 @@ var TabsComponent = React38.forwardRef(
8601
8723
  }
8602
8724
  );
8603
8725
  TabsComponent.displayName = "Tabs";
8604
- var Tabs = React38.memo(TabsComponent);
8605
- var TabsListContext = React38.createContext(
8726
+ var Tabs = React39.memo(TabsComponent);
8727
+ var TabsListContext = React39.createContext(
8606
8728
  null
8607
8729
  );
8608
8730
  function useTabsListContext() {
8609
- const ctx = React38.useContext(TabsListContext);
8731
+ const ctx = React39.useContext(TabsListContext);
8610
8732
  return ctx != null ? ctx : { variant: "primary", scrollable: false };
8611
8733
  }
8612
8734
 
@@ -8690,7 +8812,7 @@ var TABS_CONTENT_TRANSITION = {
8690
8812
  ease: "easeInOut"
8691
8813
  };
8692
8814
  var INDICATOR_MIN_WIDTH = 24;
8693
- var TabComponent = React38.forwardRef(
8815
+ var TabComponent = React39.forwardRef(
8694
8816
  ({
8695
8817
  value,
8696
8818
  icon,
@@ -8720,9 +8842,9 @@ var TabComponent = React38.forwardRef(
8720
8842
  const isFocused = focusedValue === value;
8721
8843
  const hasIcon = icon != null;
8722
8844
  const isStackedIcon = hasIcon && !inlineIcon;
8723
- const buttonRef = React38.useRef(null);
8724
- const isFirstMount = React38.useRef(true);
8725
- const mergedRef = React38.useCallback(
8845
+ const buttonRef = React39.useRef(null);
8846
+ const isFirstMount = React39.useRef(true);
8847
+ const mergedRef = React39.useCallback(
8726
8848
  (node) => {
8727
8849
  buttonRef.current = node;
8728
8850
  if (typeof ref === "function") ref(node);
@@ -8730,15 +8852,15 @@ var TabComponent = React38.forwardRef(
8730
8852
  },
8731
8853
  [ref]
8732
8854
  );
8733
- React38.useEffect(() => {
8855
+ React39.useEffect(() => {
8734
8856
  registerTab(value);
8735
8857
  return () => unregisterTab(value);
8736
8858
  }, [value, registerTab, unregisterTab]);
8737
- React38.useEffect(() => {
8859
+ React39.useEffect(() => {
8738
8860
  markTabDisabled(value, disabled);
8739
8861
  return () => markTabDisabled(value, false);
8740
8862
  }, [value, disabled, markTabDisabled]);
8741
- const handleKeyDown = React38.useCallback(
8863
+ const handleKeyDown = React39.useCallback(
8742
8864
  (e) => {
8743
8865
  const isRtl = buttonRef.current ? getComputedStyle(buttonRef.current).direction === "rtl" : false;
8744
8866
  const enabledValues = tabValues.filter((v) => !disabledValues.has(v));
@@ -8792,7 +8914,7 @@ var TabComponent = React38.forwardRef(
8792
8914
  autoActivate
8793
8915
  ]
8794
8916
  );
8795
- React38.useEffect(() => {
8917
+ React39.useEffect(() => {
8796
8918
  if (isFirstMount.current) {
8797
8919
  isFirstMount.current = false;
8798
8920
  return;
@@ -8801,7 +8923,7 @@ var TabComponent = React38.forwardRef(
8801
8923
  buttonRef.current.focus({ preventScroll: true });
8802
8924
  }
8803
8925
  }, [isFocused]);
8804
- React38.useEffect(() => {
8926
+ React39.useEffect(() => {
8805
8927
  if (!isActive || !scrollable || !buttonRef.current) return;
8806
8928
  const btn = buttonRef.current;
8807
8929
  let container = btn.parentElement;
@@ -8938,8 +9060,8 @@ var TabComponent = React38.forwardRef(
8938
9060
  }
8939
9061
  );
8940
9062
  TabComponent.displayName = "Tab";
8941
- var Tab = React38.memo(TabComponent);
8942
- var TabsContentComponent = React38.forwardRef(
9063
+ var Tab = React39.memo(TabComponent);
9064
+ var TabsContentComponent = React39.forwardRef(
8943
9065
  ({ value, className, children }, ref) => {
8944
9066
  var _a;
8945
9067
  const { value: selectedValue, layoutGroupId } = useTabsContext();
@@ -8973,8 +9095,8 @@ var TabsContentComponent = React38.forwardRef(
8973
9095
  }
8974
9096
  );
8975
9097
  TabsContentComponent.displayName = "TabsContent";
8976
- var TabsContent = React38.memo(TabsContentComponent);
8977
- var TabsListComponent = React38.forwardRef(
9098
+ var TabsContent = React39.memo(TabsContentComponent);
9099
+ var TabsListComponent = React39.forwardRef(
8978
9100
  ({
8979
9101
  variant,
8980
9102
  scrollable = false,
@@ -8985,12 +9107,12 @@ var TabsListComponent = React38.forwardRef(
8985
9107
  }, ref) => {
8986
9108
  const { layoutGroupId, value, setFocusedValue } = useTabsContext();
8987
9109
  const listLayoutId = `${layoutGroupId}-list`;
8988
- const listContextValue = React38.useMemo(
9110
+ const listContextValue = React39.useMemo(
8989
9111
  () => ({ variant, scrollable }),
8990
9112
  [variant, scrollable]
8991
9113
  );
8992
9114
  const bgColor = backgroundColor != null ? backgroundColor : "var(--md-sys-color-surface)";
8993
- const handleBlur = React38.useCallback(
9115
+ const handleBlur = React39.useCallback(
8994
9116
  (e) => {
8995
9117
  const listEl = e.currentTarget;
8996
9118
  if (listEl.contains(e.relatedTarget)) return;
@@ -9039,7 +9161,7 @@ var TabsListComponent = React38.forwardRef(
9039
9161
  }
9040
9162
  );
9041
9163
  TabsListComponent.displayName = "TabsList";
9042
- var TabsList = React38.memo(TabsListComponent);
9164
+ var TabsList = React39.memo(TabsListComponent);
9043
9165
 
9044
9166
  // src/ui/toolbar/toolbar-colors.ts
9045
9167
  var standardFloatingToolbarColors = {
@@ -9095,13 +9217,13 @@ function getToolbarColors(variant = "standard", customColors) {
9095
9217
  return standardFloatingToolbarColors;
9096
9218
  }
9097
9219
  }
9098
- var ToolbarContext = React38.createContext(
9220
+ var ToolbarContext = React39.createContext(
9099
9221
  null
9100
9222
  );
9101
9223
  function useToolbarContext() {
9102
- return React38.useContext(ToolbarContext);
9224
+ return React39.useContext(ToolbarContext);
9103
9225
  }
9104
- var BottomDockedToolbar = React38.forwardRef(
9226
+ var BottomDockedToolbar = React39.forwardRef(
9105
9227
  (_a, ref) => {
9106
9228
  var _b = _a, {
9107
9229
  variant = "standard",
@@ -9134,8 +9256,8 @@ var BottomDockedToolbar = React38.forwardRef(
9134
9256
  const { scrollY } = useScroll(
9135
9257
  scrollContainerRef ? { container: scrollContainerRef } : void 0
9136
9258
  );
9137
- const [isHidden, setIsHidden] = React38.useState(false);
9138
- const lastScrollY = React38.useRef(0);
9259
+ const [isHidden, setIsHidden] = React39.useState(false);
9260
+ const lastScrollY = React39.useRef(0);
9139
9261
  useMotionValueEvent(scrollY, "change", (latest) => {
9140
9262
  if (!hideOnScroll) return;
9141
9263
  const diff = latest - lastScrollY.current;
@@ -9294,15 +9416,15 @@ function buildSlotVariants(xHidden, yHidden, isHorizontal) {
9294
9416
  };
9295
9417
  }
9296
9418
  function applyItemClassName(nodes, itemClassName) {
9297
- return React38.Children.map(nodes, (child) => {
9298
- if (!React38.isValidElement(child)) return child;
9419
+ return React39.Children.map(nodes, (child) => {
9420
+ if (!React39.isValidElement(child)) return child;
9299
9421
  const element = child;
9300
- return React38.cloneElement(element, {
9422
+ return React39.cloneElement(element, {
9301
9423
  className: cn(element.props.className, itemClassName)
9302
9424
  });
9303
9425
  });
9304
9426
  }
9305
- var FloatingToolbarBase = React38.forwardRef(
9427
+ var FloatingToolbarBase = React39.forwardRef(
9306
9428
  (_a, ref) => {
9307
9429
  var _b = _a, {
9308
9430
  expanded,
@@ -9474,11 +9596,11 @@ var FloatingToolbarBase = React38.forwardRef(
9474
9596
  }
9475
9597
  );
9476
9598
  FloatingToolbarBase.displayName = "FloatingToolbarBase";
9477
- var HorizontalFloatingToolbar = React38.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarBase, __spreadValues({ ref, orientation: "horizontal" }, props)));
9599
+ var HorizontalFloatingToolbar = React39.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarBase, __spreadValues({ ref, orientation: "horizontal" }, props)));
9478
9600
  HorizontalFloatingToolbar.displayName = "HorizontalFloatingToolbar";
9479
- var VerticalFloatingToolbar = React38.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarBase, __spreadValues({ ref, orientation: "vertical" }, props)));
9601
+ var VerticalFloatingToolbar = React39.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarBase, __spreadValues({ ref, orientation: "vertical" }, props)));
9480
9602
  VerticalFloatingToolbar.displayName = "VerticalFloatingToolbar";
9481
- var FloatingToolbarWithFabBase = React38.forwardRef(
9603
+ var FloatingToolbarWithFabBase = React39.forwardRef(
9482
9604
  (_a, ref) => {
9483
9605
  var _b = _a, {
9484
9606
  expanded,
@@ -9606,9 +9728,9 @@ var FloatingToolbarWithFabBase = React38.forwardRef(
9606
9728
  }
9607
9729
  );
9608
9730
  FloatingToolbarWithFabBase.displayName = "FloatingToolbarWithFabBase";
9609
- var HorizontalFloatingToolbarWithFab = React38.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarWithFabBase, __spreadValues({ ref, orientation: "horizontal" }, props)));
9731
+ var HorizontalFloatingToolbarWithFab = React39.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarWithFabBase, __spreadValues({ ref, orientation: "horizontal" }, props)));
9610
9732
  HorizontalFloatingToolbarWithFab.displayName = "HorizontalFloatingToolbarWithFab";
9611
- var VerticalFloatingToolbarWithFab = React38.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarWithFabBase, __spreadValues({ ref, orientation: "vertical" }, props)));
9733
+ var VerticalFloatingToolbarWithFab = React39.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarWithFabBase, __spreadValues({ ref, orientation: "vertical" }, props)));
9612
9734
  VerticalFloatingToolbarWithFab.displayName = "VerticalFloatingToolbarWithFab";
9613
9735
  var ToolbarDivider = ({
9614
9736
  orientation: propsOrientation,
@@ -9644,7 +9766,7 @@ var VARIANT_TO_COLOR_STYLE = {
9644
9766
  tonal: "tonal",
9645
9767
  filled: "filled"
9646
9768
  };
9647
- var ToolbarIconButton = React38.forwardRef(
9769
+ var ToolbarIconButton = React39.forwardRef(
9648
9770
  (_a, ref) => {
9649
9771
  var _b = _a, {
9650
9772
  emphasis = "standard",
@@ -9816,7 +9938,7 @@ var MOTION_PROP_KEYS = [
9816
9938
  "layoutId",
9817
9939
  "onLayoutAnimationComplete"
9818
9940
  ];
9819
- var ToolbarToggleButton = React38.forwardRef(
9941
+ var ToolbarToggleButton = React39.forwardRef(
9820
9942
  (_a, ref) => {
9821
9943
  var _b = _a, {
9822
9944
  emphasis = "standard",
@@ -9850,7 +9972,7 @@ var ToolbarToggleButton = React38.forwardRef(
9850
9972
  "onPointerLeave"
9851
9973
  ]);
9852
9974
  const context = useToolbarContext();
9853
- const [isPressed, setIsPressed] = React38.useState(false);
9975
+ const [isPressed, setIsPressed] = React39.useState(false);
9854
9976
  const {
9855
9977
  ripples,
9856
9978
  onPointerDown: handleRipplePointerDown,
@@ -9858,7 +9980,7 @@ var ToolbarToggleButton = React38.forwardRef(
9858
9980
  } = useRippleState({
9859
9981
  disabled: Boolean(disabled) || !ripple
9860
9982
  });
9861
- const handlePointerDown = React38.useCallback(
9983
+ const handlePointerDown = React39.useCallback(
9862
9984
  (e) => {
9863
9985
  setIsPressed(true);
9864
9986
  if (!disabled && ripple) {
@@ -9868,14 +9990,14 @@ var ToolbarToggleButton = React38.forwardRef(
9868
9990
  },
9869
9991
  [disabled, ripple, handleRipplePointerDown, onPointerDownProp]
9870
9992
  );
9871
- const handlePointerUp = React38.useCallback(
9993
+ const handlePointerUp = React39.useCallback(
9872
9994
  (e) => {
9873
9995
  setIsPressed(false);
9874
9996
  onPointerUpProp == null ? void 0 : onPointerUpProp(e);
9875
9997
  },
9876
9998
  [onPointerUpProp]
9877
9999
  );
9878
- const handlePointerLeave = React38.useCallback(
10000
+ const handlePointerLeave = React39.useCallback(
9879
10001
  (e) => {
9880
10002
  setIsPressed(false);
9881
10003
  onPointerLeaveProp == null ? void 0 : onPointerLeaveProp(e);
@@ -9894,14 +10016,14 @@ var ToolbarToggleButton = React38.forwardRef(
9894
10016
  context == null ? void 0 : context.itemClassName,
9895
10017
  className
9896
10018
  );
9897
- const animateConfig = React38.useMemo(
10019
+ const animateConfig = React39.useMemo(
9898
10020
  () => ({
9899
10021
  scaleX: pressExpand && isPressed ? 1 + pressExpandRatio : 1,
9900
10022
  borderRadius: isPressed ? ToolbarToggleButtonRadiusTokens.pressedRadius : ToolbarToggleButtonRadiusTokens.pillRadius
9901
10023
  }),
9902
10024
  [pressExpand, pressExpandRatio, isPressed]
9903
10025
  );
9904
- const transitionConfig = React38.useMemo(
10026
+ const transitionConfig = React39.useMemo(
9905
10027
  () => ({
9906
10028
  scaleX: FAST_SPATIAL_SPRING,
9907
10029
  borderRadius: BUTTON_RADIUS_SPRING
@@ -9923,7 +10045,7 @@ var ToolbarToggleButton = React38.forwardRef(
9923
10045
  children && (typeof children === "string" || typeof children === "number" ? /* @__PURE__ */ jsx("span", { children }) : children)
9924
10046
  ] });
9925
10047
  if (asChild) {
9926
- const child = React38.Children.only(children);
10048
+ const child = React39.Children.only(children);
9927
10049
  const childContent = child.props.children;
9928
10050
  const innerChildContent = /* @__PURE__ */ jsxs(Fragment, { children: [
9929
10051
  ripple && /* @__PURE__ */ jsx(
@@ -9962,7 +10084,7 @@ var ToolbarToggleButton = React38.forwardRef(
9962
10084
  onPointerUp: handlePointerUp,
9963
10085
  onPointerLeave: handlePointerLeave
9964
10086
  }, strippedProps), {
9965
- children: React38.cloneElement(child, { children: innerChildContent })
10087
+ children: React39.cloneElement(child, { children: innerChildContent })
9966
10088
  })
9967
10089
  ) });
9968
10090
  }
@@ -9999,6 +10121,6 @@ var ToolbarToggleButton = React38.forwardRef(
9999
10121
  );
10000
10122
  ToolbarToggleButton.displayName = "ToolbarToggleButton";
10001
10123
 
10002
- export { APP_BAR_BOTTOM_SPRING, APP_BAR_COLORS, APP_BAR_COLOR_TRANSITION, APP_BAR_ENTER_ALWAYS_SPRING, APP_BAR_TITLE_FADE, AppBarColumn, AppBarOverflowIndicator, AppBarRow, AppBarTokens, BottomAppBar, BottomDockedToolbar, CHECK_ICON_VARIANTS, ContextMenu, ContextMenuContent, ContextMenuTrigger, DIVIDER_COLOR, DIVIDER_PADDING, DockedToolbar, FAST_EFFECTS_TRANSITION, FAST_SPATIAL_SPRING, FadingBlurMask, GROUP_SHAPES, HorizontalFloatingToolbar, HorizontalFloatingToolbarWithFab, ITEM_SHAPE_CLASSES, LargeFlexibleAppBar, MENU_CHECK_ICON_SIZE, MENU_CONTAINER_VARIANTS, MENU_GROUP_GAP, MENU_ICON_SIZE, MENU_ITEM_MIN_HEIGHT, MENU_MAX_WIDTH, MENU_MIN_WIDTH, MediumFlexibleAppBar, Menu, MenuContent, MenuDivider, MenuGroup, MenuItem, MenuProvider, MenuTrigger, NavigationBar, NavigationBarComponent, NavigationBarItem, NavigationRail, NavigationRailItem, SEARCH_BAR_EXIT_SPRING, SEARCH_BAR_EXPAND_SPRING, SEARCH_COLORS, SEARCH_DOCKED_REVEAL_SPRING, SEARCH_FULLSCREEN_SPRING, SEARCH_TYPOGRAPHY, SEARCH_VIEW_SPRING, STANDARD_COLORS, SUBMENU_CONTAINER_VARIANTS, Search, SearchAppBar, SearchBar, SearchTokens, SearchView, SearchViewContainer, SearchViewDocked, SearchViewFullScreen, SmallAppBar, SubMenu, Tab, Tabs, TabsColors, TabsContent, TabsList, TabsTokens, ToolbarDivider, ToolbarDividerTokens, ToolbarIconButton, ToolbarIconButtonTokens, ToolbarToggleButton, ToolbarToggleButtonTokens, VIBRANT_COLORS, VerticalFloatingToolbar, VerticalFloatingToolbarWithFab, VerticalMenu, VerticalMenuContent, VerticalMenuDivider, VerticalMenuGroup, appBarTypography, getNavigationShapeStyle, getToolbarColors, isSquareShape, standardFloatingToolbarColors, surfaceContainerHighFloatingToolbarColors, surfaceContainerHighestFloatingToolbarColors, tertiaryContainerFloatingToolbarColors, useAppBarScroll, useFloatingToolbarScrollBehavior, useMenuContext, useSearch, useSearchKeyboard, vibrantFloatingToolbarColors, xrFloatingToolbarColors };
10124
+ export { APP_BAR_BOTTOM_SPRING, APP_BAR_COLORS, APP_BAR_COLOR_TRANSITION, APP_BAR_ENTER_ALWAYS_SPRING, APP_BAR_TITLE_FADE, AppBarColumn, AppBarOverflowIndicator, AppBarRow, AppBarTokens, BottomAppBar, BottomDockedToolbar, CHECK_ICON_VARIANTS, ContextMenu, ContextMenuContent, ContextMenuTrigger, DIVIDER_COLOR, DIVIDER_PADDING, DockedToolbar, FAST_EFFECTS_TRANSITION, FAST_SPATIAL_SPRING, FadingBlurMask, GROUP_SHAPES, HorizontalFloatingToolbar, HorizontalFloatingToolbarWithFab, ITEM_SHAPE_CLASSES, LargeFlexibleAppBar, MENU_CHECK_ICON_SIZE, MENU_CONTAINER_VARIANTS, MENU_GROUP_GAP, MENU_ICON_SIZE, MENU_ITEM_MIN_HEIGHT, MENU_MAX_WIDTH, MENU_MIN_WIDTH, MediumFlexibleAppBar, Menu, MenuContent, MenuDivider, MenuGroup, MenuItem, MenuProvider, MenuTrigger, NavigationBar, NavigationBarComponent, NavigationBarItem, NavigationRail, NavigationRailItem, SEARCH_BAR_EXIT_SPRING, SEARCH_BAR_EXPAND_SPRING, SEARCH_COLORS, SEARCH_DOCKED_REVEAL_SPRING, SEARCH_ELEVATION, SEARCH_FULLSCREEN_SPRING, SEARCH_TYPOGRAPHY, SEARCH_VIEW_SPRING, STANDARD_COLORS, SUBMENU_CONTAINER_VARIANTS, Search, SearchAppBar, SearchBar, SearchTokens, SearchView, SearchViewContainer, SearchViewDocked, SearchViewFullScreen, SmallAppBar, SubMenu, Tab, Tabs, TabsColors, TabsContent, TabsList, TabsTokens, ToolbarDivider, ToolbarDividerTokens, ToolbarIconButton, ToolbarIconButtonTokens, ToolbarToggleButton, ToolbarToggleButtonTokens, VIBRANT_COLORS, VerticalFloatingToolbar, VerticalFloatingToolbarWithFab, VerticalMenu, VerticalMenuContent, VerticalMenuDivider, VerticalMenuGroup, appBarTypography, getNavigationShapeStyle, getToolbarColors, isSquareShape, standardFloatingToolbarColors, surfaceContainerHighFloatingToolbarColors, surfaceContainerHighestFloatingToolbarColors, tertiaryContainerFloatingToolbarColors, useAppBarScroll, useFloatingToolbarScrollBehavior, useMenuContext, useSearch, useSearchKeyboard, vibrantFloatingToolbarColors, xrFloatingToolbarColors };
10003
10125
  //# sourceMappingURL=navigation.mjs.map
10004
10126
  //# sourceMappingURL=navigation.mjs.map