@bug-on/m3-expressive 1.2.3 → 1.2.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/README.md +128 -41
  3. package/dist/buttons.d.mts +1 -1
  4. package/dist/buttons.d.ts +1 -1
  5. package/dist/buttons.js +33 -14
  6. package/dist/buttons.js.map +1 -1
  7. package/dist/buttons.mjs +33 -14
  8. package/dist/buttons.mjs.map +1 -1
  9. package/dist/forms.d.mts +2 -2
  10. package/dist/forms.d.ts +2 -2
  11. package/dist/index.d.mts +79 -7
  12. package/dist/index.d.ts +79 -7
  13. package/dist/index.js +6071 -5547
  14. package/dist/index.js.map +1 -1
  15. package/dist/index.mjs +5964 -5441
  16. package/dist/index.mjs.map +1 -1
  17. package/dist/layout.js +10 -7
  18. package/dist/layout.js.map +1 -1
  19. package/dist/layout.mjs +10 -7
  20. package/dist/layout.mjs.map +1 -1
  21. package/dist/md3-expressive-shapes-CPcfl_Hf.d.mts +498 -0
  22. package/dist/md3-expressive-shapes-CPcfl_Hf.d.ts +498 -0
  23. package/dist/navigation.d.mts +93 -20
  24. package/dist/navigation.d.ts +93 -20
  25. package/dist/navigation.js +2824 -561
  26. package/dist/navigation.js.map +1 -1
  27. package/dist/navigation.mjs +2815 -554
  28. package/dist/navigation.mjs.map +1 -1
  29. package/dist/overlays.d.mts +2 -2
  30. package/dist/overlays.d.ts +2 -2
  31. package/dist/shapes.d.mts +3 -498
  32. package/dist/shapes.d.ts +3 -498
  33. package/dist/{side-sheet-modal-Bd5Qqvp9.d.ts → side-sheet-modal-DdEZR6Vl.d.ts} +1 -1
  34. package/dist/{side-sheet-modal-64FGhDxL.d.mts → side-sheet-modal-Dgjt739k.d.mts} +1 -1
  35. package/dist/{split-button-trailing-uncheckable-C-qQlyZx.d.ts → split-button-trailing-uncheckable--BhNTEJw.d.ts} +10 -5
  36. package/dist/{split-button-trailing-uncheckable-DHJqNeq_.d.mts → split-button-trailing-uncheckable-DPJL3bO6.d.mts} +10 -5
  37. package/dist/{text-field-T4Rg-9Bw.d.mts → text-field-DWC7qOvp.d.mts} +128 -128
  38. package/dist/{text-field-T4Rg-9Bw.d.ts → text-field-DWC7qOvp.d.ts} +128 -128
  39. package/package.json +3 -3
@@ -1,5 +1,5 @@
1
1
  "use client";
2
- import * as React36 from 'react';
2
+ import * as React37 from 'react';
3
3
  import { useRef, useEffect, useState } from 'react';
4
4
  import { clsx } from 'clsx';
5
5
  import { twMerge } from 'tailwind-merge';
@@ -305,9 +305,10 @@ var SUBMENU_CONTAINER_VARIANTS = {
305
305
  transition: FAST_EFFECTS_TRANSITION
306
306
  }
307
307
  };
308
- var MenuContext = React36.createContext({
308
+ var MenuContext = React37.createContext({
309
309
  variant: "baseline",
310
310
  colorVariant: "standard",
311
+ density: 0,
311
312
  menuPrimitive: "dropdown",
312
313
  open: false,
313
314
  onOpenChange: () => {
@@ -316,29 +317,46 @@ var MenuContext = React36.createContext({
316
317
  function MenuProvider({
317
318
  variant = "baseline",
318
319
  colorVariant = "standard",
320
+ density = 0,
319
321
  menuPrimitive = "dropdown",
320
322
  open,
321
323
  onOpenChange,
322
324
  children
323
325
  }) {
324
- const value = React36.useMemo(
325
- () => ({ variant, colorVariant, menuPrimitive, open, onOpenChange }),
326
- [variant, colorVariant, menuPrimitive, open, onOpenChange]
326
+ const value = React37.useMemo(
327
+ () => ({
328
+ variant,
329
+ colorVariant,
330
+ density,
331
+ menuPrimitive,
332
+ open,
333
+ onOpenChange
334
+ }),
335
+ [variant, colorVariant, density, menuPrimitive, open, onOpenChange]
327
336
  );
328
337
  return /* @__PURE__ */ jsx(MenuContext.Provider, { value, children });
329
338
  }
330
339
  function useMenuContext() {
331
- const ctx = React36.useContext(MenuContext);
332
- return React36.useMemo(
333
- () => __spreadProps(__spreadValues({}, ctx), {
334
- isStatic: ctx.menuPrimitive === "static",
335
- menuVariant: ctx.variant
340
+ const ctx = React37.useContext(MenuContext);
341
+ return React37.useMemo(
342
+ () => Object.assign(ctx, {
343
+ get isStatic() {
344
+ return ctx.menuPrimitive === "static";
345
+ },
346
+ get menuVariant() {
347
+ return ctx.variant;
348
+ }
336
349
  }),
337
350
  [ctx]
338
351
  );
339
352
  }
340
353
  var MENU_BASELINE_ITEM_HORIZONTAL_PADDING = "px-3";
341
354
  var MENU_ITEM_MIN_HEIGHT = "min-h-11";
355
+ var DENSITY_MIN_HEIGHT = {
356
+ 0: "min-h-12",
357
+ "-2": "min-h-10",
358
+ "-4": "min-h-8"
359
+ };
342
360
  var MENU_MIN_WIDTH = "min-w-28";
343
361
  var MENU_MAX_WIDTH = "max-w-70";
344
362
  var MENU_GROUP_GAP = "gap-0.5";
@@ -371,7 +389,7 @@ var ITEM_SHAPE_CLASSES = {
371
389
  leading: "rounded-t-[12px] rounded-b-[4px]",
372
390
  middle: "rounded-[4px]",
373
391
  trailing: "rounded-t-[4px] rounded-b-[12px]",
374
- standalone: "rounded-[4px]",
392
+ standalone: "rounded-[12px]",
375
393
  selected: "rounded-[12px]"
376
394
  };
377
395
  var STANDARD_COLORS = {
@@ -388,9 +406,9 @@ var STANDARD_COLORS = {
388
406
  /** Trailing icon color (StandardMenuTokens.ItemTrailingIconColor) */
389
407
  trailingIconColor: "text-m3-on-surface-variant",
390
408
  /** Hover state layer (OnSurface @ 8% opacity) */
391
- hoverLayer: "hover:bg-m3-on-surface/8",
409
+ hoverLayer: "hover:bg-m3-on-surface/8 data-[highlighted]:bg-m3-on-surface/8",
392
410
  /** Focus state layer (OnSurface @ 12% opacity) */
393
- focusLayer: "focus:bg-m3-on-surface/12",
411
+ focusLayer: "focus:bg-m3-on-surface/12 data-[highlighted]:bg-m3-on-surface/8",
394
412
  /** Selected item background (StandardMenuTokens.ItemSelectedContainerColor) */
395
413
  selectedBg: "bg-m3-tertiary-container",
396
414
  /** Selected item text (StandardMenuTokens.ItemSelectedLabelTextColor) */
@@ -406,8 +424,8 @@ var BASELINE_COLORS = {
406
424
  iconColor: "text-m3-on-surface-variant",
407
425
  supportingTextColor: "text-m3-on-surface-variant",
408
426
  trailingIconColor: "text-m3-on-surface-variant",
409
- hoverLayer: "hover:bg-m3-on-surface/8",
410
- focusLayer: "focus:bg-m3-on-surface/12",
427
+ hoverLayer: "hover:bg-m3-on-surface/8 data-[highlighted]:bg-m3-on-surface/8",
428
+ focusLayer: "focus:bg-m3-on-surface/12 data-[highlighted]:bg-m3-on-surface/8",
411
429
  selectedBg: "bg-m3-secondary-container",
412
430
  selectedText: "text-m3-on-secondary-container",
413
431
  selectedIcon: "text-m3-on-secondary-container"};
@@ -425,9 +443,9 @@ var VIBRANT_COLORS = {
425
443
  /** Trailing icon color (VibrantMenuTokens.ItemTrailingIconColor) */
426
444
  trailingIconColor: "text-m3-on-tertiary-container",
427
445
  /** Hover state layer (OnTertiaryContainer @ 8% opacity) */
428
- hoverLayer: "hover:bg-m3-on-tertiary-container/8",
446
+ hoverLayer: "hover:bg-m3-on-tertiary-container/8 data-[highlighted]:bg-m3-on-tertiary-container/8",
429
447
  /** Focus state layer (OnTertiaryContainer @ 12% opacity) */
430
- focusLayer: "focus:bg-m3-on-tertiary-container/12",
448
+ focusLayer: "focus:bg-m3-on-tertiary-container/12 data-[highlighted]:bg-m3-on-tertiary-container/8",
431
449
  /** Selected item background (VibrantMenuTokens.ItemSelectedContainerColor = Tertiary) */
432
450
  selectedBg: "bg-m3-tertiary",
433
451
  /** Selected item text (VibrantMenuTokens.ItemSelectedLabelTextColor = OnTertiary) */
@@ -439,12 +457,29 @@ var VIBRANT_COLORS = {
439
457
  };
440
458
  var DIVIDER_PADDING = "mx-3 my-0.5";
441
459
  var DIVIDER_COLOR = "bg-m3-outline-variant";
460
+ function flattenChildren(nodes) {
461
+ return React37.Children.toArray(nodes).reduce(
462
+ (acc, child) => {
463
+ if (!React37.isValidElement(child)) return acc;
464
+ if (child.type === React37.Fragment) {
465
+ return acc.concat(
466
+ flattenChildren(
467
+ child.props.children
468
+ )
469
+ );
470
+ }
471
+ acc.push(child);
472
+ return acc;
473
+ },
474
+ []
475
+ );
476
+ }
442
477
  function ContextMenu({
443
478
  children,
444
479
  variant = "baseline",
445
480
  colorVariant = "standard"
446
481
  }) {
447
- const [open, setOpen] = React36.useState(false);
482
+ const [open, setOpen] = React37.useState(false);
448
483
  return /* @__PURE__ */ jsx(
449
484
  MenuProvider,
450
485
  {
@@ -458,12 +493,12 @@ function ContextMenu({
458
493
  );
459
494
  }
460
495
  ContextMenu.displayName = "ContextMenu";
461
- var ContextMenuTrigger = React36.forwardRef((_a, ref) => {
496
+ var ContextMenuTrigger = React37.forwardRef((_a, ref) => {
462
497
  var _b = _a, { children, asChild = true } = _b, props = __objRest(_b, ["children", "asChild"]);
463
498
  return /* @__PURE__ */ jsx(RxContextMenu.Trigger, __spreadProps(__spreadValues({ ref, asChild }, props), { children }));
464
499
  });
465
500
  ContextMenuTrigger.displayName = "ContextMenuTrigger";
466
- var ContextMenuContent = React36.forwardRef(
501
+ var ContextMenuContent = React37.forwardRef(
467
502
  (_a, ref) => {
468
503
  var _b = _a, {
469
504
  children,
@@ -486,71 +521,51 @@ var ContextMenuContent = React36.forwardRef(
486
521
  const colorVariant = propColorVariant != null ? propColorVariant : contextColorVariant;
487
522
  const colors = variant === "baseline" ? BASELINE_COLORS : colorVariant === "vibrant" ? VIBRANT_COLORS : STANDARD_COLORS;
488
523
  const isExpressiveGap = variant === "expressive" && separatorStyle === "gap";
489
- const containerClassName = variant === "expressive" ? cn(
490
- "z-50 flex flex-col w-full",
491
- MENU_MIN_WIDTH,
492
- MENU_MAX_WIDTH,
493
- isExpressiveGap ? MENU_GROUP_GAP : "",
494
- isExpressiveGap ? "bg-transparent" : colors.containerBg,
495
- isExpressiveGap ? "" : "rounded-2xl",
496
- isExpressiveGap ? "" : "elevation-2",
497
- hasOverflow || isExpressiveGap ? "overflow-visible" : "overflow-hidden",
498
- "outline-none",
499
- className
500
- ) : cn(
501
- "z-50 flex flex-col",
502
- MENU_MIN_WIDTH,
503
- MENU_MAX_WIDTH,
504
- MENU_POPUP_PADDING_Y,
505
- MENU_GROUP_GAP,
506
- colors.containerBg,
507
- MENU_CONTAINER_SHAPE,
508
- "elevation-2",
509
- hasOverflow ? "overflow-visible" : "overflow-hidden",
510
- "outline-none",
511
- className
524
+ const containerClassName = React37.useMemo(
525
+ () => variant === "expressive" ? cn(
526
+ "z-50 flex flex-col w-full",
527
+ MENU_MIN_WIDTH,
528
+ MENU_MAX_WIDTH,
529
+ isExpressiveGap ? MENU_GROUP_GAP : "",
530
+ isExpressiveGap ? "bg-transparent" : colors.containerBg,
531
+ isExpressiveGap ? "" : "rounded-2xl",
532
+ isExpressiveGap ? "" : "elevation-2",
533
+ hasOverflow || isExpressiveGap ? "overflow-visible" : "overflow-hidden",
534
+ "outline-none",
535
+ className
536
+ ) : cn(
537
+ "z-50 flex flex-col",
538
+ MENU_MIN_WIDTH,
539
+ MENU_MAX_WIDTH,
540
+ MENU_POPUP_PADDING_Y,
541
+ MENU_GROUP_GAP,
542
+ colors.containerBg,
543
+ MENU_CONTAINER_SHAPE,
544
+ "elevation-2",
545
+ hasOverflow ? "overflow-visible" : "overflow-hidden",
546
+ "outline-none",
547
+ className
548
+ ),
549
+ [variant, isExpressiveGap, hasOverflow, className, colors.containerBg]
512
550
  );
513
- const flattenChildren = (nodes) => {
514
- return React36.Children.toArray(nodes).reduce(
515
- (acc, child) => {
516
- if (React36.isValidElement(child)) {
517
- if (child.type === React36.Fragment) {
518
- return acc.concat(
519
- flattenChildren(
520
- child.props.children
521
- )
522
- );
523
- }
524
- acc.push(child);
525
- }
526
- return acc;
527
- },
528
- []
529
- );
530
- };
531
- let renderedChildren = children;
532
- if (variant === "expressive") {
551
+ const renderedChildren = React37.useMemo(() => {
552
+ if (variant !== "expressive") return children;
533
553
  const validChildren = flattenChildren(children);
534
554
  const groupCount = validChildren.length;
535
- const enhancedChildren = validChildren.map(
536
- (child, i) => React36.cloneElement(
555
+ const enhanced = validChildren.map(
556
+ (child, i) => React37.cloneElement(
537
557
  child,
538
- {
539
- index: i,
540
- count: groupCount,
541
- isGapVariant: isExpressiveGap
542
- }
558
+ { index: i, count: groupCount, isGapVariant: isExpressiveGap }
543
559
  )
544
560
  );
545
- renderedChildren = separatorStyle === "divider" ? enhancedChildren.reduce((acc, child, i) => {
561
+ if (separatorStyle !== "divider") return enhanced;
562
+ return enhanced.reduce((acc, child, i) => {
546
563
  if (i > 0) {
547
564
  acc.push(
548
565
  /* @__PURE__ */ jsx(
549
566
  "hr",
550
567
  {
551
- className: cn(
552
- "mx-3 my-0.5 h-px border-0 bg-m3-outline-variant"
553
- )
568
+ className: cn("mx-3 my-0.5 h-px border-0 bg-m3-outline-variant")
554
569
  },
555
570
  `divider-${child.key || i}`
556
571
  )
@@ -558,8 +573,8 @@ var ContextMenuContent = React36.forwardRef(
558
573
  }
559
574
  acc.push(child);
560
575
  return acc;
561
- }, []) : enhancedChildren;
562
- }
576
+ }, []);
577
+ }, [children, variant, isExpressiveGap, separatorStyle]);
563
578
  return /* @__PURE__ */ jsx(AnimatePresence, { children: open && /* @__PURE__ */ jsx(RxContextMenu.Portal, { forceMount: true, children: /* @__PURE__ */ jsx(RxContextMenu.Content, __spreadProps(__spreadValues({ ref, asChild: true, forceMount: true }, props), { children: /* @__PURE__ */ jsx(
564
579
  m.div,
565
580
  {
@@ -583,6 +598,7 @@ function Menu(_a) {
583
598
  variant,
584
599
  menuVariant,
585
600
  colorVariant = "standard",
601
+ density = 0,
586
602
  open: controlledOpen,
587
603
  onOpenChange: controlledOnOpenChange,
588
604
  defaultOpen
@@ -591,18 +607,19 @@ function Menu(_a) {
591
607
  "variant",
592
608
  "menuVariant",
593
609
  "colorVariant",
610
+ "density",
594
611
  "open",
595
612
  "onOpenChange",
596
613
  "defaultOpen"
597
614
  ]);
598
615
  var _a2;
599
616
  const resolvedVariant = (_a2 = variant != null ? variant : menuVariant) != null ? _a2 : "baseline";
600
- const [internalOpen, setInternalOpen] = React36.useState(
617
+ const [internalOpen, setInternalOpen] = React37.useState(
601
618
  () => defaultOpen != null ? defaultOpen : false
602
619
  );
603
620
  const isControlled = controlledOpen !== void 0;
604
621
  const open = isControlled ? controlledOpen : internalOpen;
605
- const handleOpenChange = React36.useCallback(
622
+ const handleOpenChange = React37.useCallback(
606
623
  (next) => {
607
624
  if (!isControlled) setInternalOpen(next);
608
625
  controlledOnOpenChange == null ? void 0 : controlledOnOpenChange(next);
@@ -614,6 +631,7 @@ function Menu(_a) {
614
631
  {
615
632
  variant: resolvedVariant,
616
633
  colorVariant,
634
+ density,
617
635
  open,
618
636
  onOpenChange: handleOpenChange,
619
637
  children: /* @__PURE__ */ jsx(
@@ -629,12 +647,12 @@ function Menu(_a) {
629
647
  );
630
648
  }
631
649
  Menu.displayName = "Menu";
632
- var MenuTrigger = React36.forwardRef((_a, ref) => {
650
+ var MenuTrigger = React37.forwardRef((_a, ref) => {
633
651
  var _b = _a, { children, asChild = true } = _b, props = __objRest(_b, ["children", "asChild"]);
634
652
  return /* @__PURE__ */ jsx(DropdownMenu.Trigger, __spreadProps(__spreadValues({ ref, asChild }, props), { children }));
635
653
  });
636
654
  MenuTrigger.displayName = "MenuTrigger";
637
- var MenuContent = React36.forwardRef(
655
+ var MenuContent = React37.forwardRef(
638
656
  (_a, ref) => {
639
657
  var _b = _a, {
640
658
  children,
@@ -644,6 +662,7 @@ var MenuContent = React36.forwardRef(
644
662
  hasOverflow = false,
645
663
  colorVariant: propColorVariant,
646
664
  separatorStyle = "gap",
665
+ matchTriggerWidth = false,
647
666
  className
648
667
  } = _b, props = __objRest(_b, [
649
668
  "children",
@@ -653,6 +672,7 @@ var MenuContent = React36.forwardRef(
653
672
  "hasOverflow",
654
673
  "colorVariant",
655
674
  "separatorStyle",
675
+ "matchTriggerWidth",
656
676
  "className"
657
677
  ]);
658
678
  const {
@@ -663,68 +683,66 @@ var MenuContent = React36.forwardRef(
663
683
  const colorVariant = propColorVariant != null ? propColorVariant : contextColorVariant;
664
684
  const colors = variant === "baseline" ? BASELINE_COLORS : colorVariant === "vibrant" ? VIBRANT_COLORS : STANDARD_COLORS;
665
685
  const isExpressiveGap = variant === "expressive" && separatorStyle === "gap";
666
- const containerClassName = variant === "expressive" ? cn(
667
- "z-50 flex flex-col",
668
- MENU_MIN_WIDTH,
669
- MENU_MAX_WIDTH,
670
- isExpressiveGap ? MENU_GROUP_GAP : "",
671
- isExpressiveGap ? "bg-transparent" : colors.containerBg,
672
- isExpressiveGap ? "" : "rounded-2xl",
673
- isExpressiveGap ? "" : "elevation-2",
674
- hasOverflow || isExpressiveGap ? "overflow-visible" : "overflow-hidden",
675
- "outline-none",
676
- className
677
- ) : cn(
678
- "z-50 flex flex-col",
679
- MENU_MIN_WIDTH,
680
- MENU_MAX_WIDTH,
681
- MENU_POPUP_PADDING_Y,
682
- MENU_GROUP_GAP,
683
- colors.containerBg,
684
- MENU_CONTAINER_SHAPE,
685
- "elevation-2",
686
- hasOverflow ? "overflow-visible" : "overflow-hidden",
687
- "outline-none",
688
- className
689
- );
690
- const flattenChildren = (nodes) => {
691
- return React36.Children.toArray(nodes).reduce(
692
- (acc, child) => {
693
- if (React36.isValidElement(child)) {
694
- if (child.type === React36.Fragment) {
695
- return acc.concat(
696
- flattenChildren(
697
- child.props.children
698
- )
699
- );
700
- }
701
- acc.push(child);
702
- }
703
- return acc;
704
- },
705
- []
686
+ const containerClassName = React37.useMemo(() => {
687
+ const widthClass = matchTriggerWidth ? "w-[var(--radix-dropdown-menu-trigger-width)]" : cn(MENU_MIN_WIDTH, MENU_MAX_WIDTH);
688
+ return variant === "expressive" ? cn(
689
+ "z-50 flex flex-col",
690
+ widthClass,
691
+ isExpressiveGap ? MENU_GROUP_GAP : "",
692
+ isExpressiveGap ? "bg-transparent" : colors.containerBg,
693
+ isExpressiveGap ? "" : "p-1",
694
+ isExpressiveGap ? "" : "rounded-2xl",
695
+ isExpressiveGap ? "" : "elevation-2",
696
+ hasOverflow || isExpressiveGap ? "overflow-visible" : "overflow-hidden",
697
+ "outline-none",
698
+ className
699
+ ) : cn(
700
+ "z-50 flex flex-col",
701
+ widthClass,
702
+ MENU_POPUP_PADDING_Y,
703
+ MENU_GROUP_GAP,
704
+ colors.containerBg,
705
+ MENU_CONTAINER_SHAPE,
706
+ "elevation-2",
707
+ hasOverflow ? "overflow-visible" : "overflow-hidden",
708
+ "outline-none",
709
+ className
706
710
  );
707
- };
708
- let renderedChildren = children;
709
- if (variant === "expressive") {
711
+ }, [
712
+ variant,
713
+ isExpressiveGap,
714
+ hasOverflow,
715
+ matchTriggerWidth,
716
+ className,
717
+ colors.containerBg
718
+ ]);
719
+ const renderedChildren = React37.useMemo(() => {
720
+ if (variant !== "expressive") return children;
710
721
  const validChildren = flattenChildren(children);
711
722
  const groupCount = validChildren.length;
712
- const enhancedChildren = validChildren.map(
713
- (child, i) => React36.cloneElement(child, {
714
- index: i,
715
- count: groupCount,
716
- isGapVariant: isExpressiveGap
717
- })
718
- );
719
- renderedChildren = separatorStyle === "divider" ? enhancedChildren.reduce((acc, child, i) => {
723
+ const enhanced = validChildren.map((child, i) => {
724
+ var _a2;
725
+ if (typeof child.type === "string") return child;
726
+ const defaultItemPosition = groupCount === 1 ? "standalone" : i === 0 ? "leading" : i === groupCount - 1 ? "trailing" : "middle";
727
+ const itemPosition = (_a2 = child.props.itemPosition) != null ? _a2 : defaultItemPosition;
728
+ return React37.cloneElement(
729
+ child,
730
+ {
731
+ index: i,
732
+ count: groupCount,
733
+ itemPosition,
734
+ isGapVariant: isExpressiveGap
735
+ }
736
+ );
737
+ });
738
+ if (separatorStyle !== "divider") return enhanced;
739
+ return enhanced.reduce((acc, child, i) => {
720
740
  if (i > 0) {
721
741
  acc.push(
722
742
  /* @__PURE__ */ jsx(
723
743
  "hr",
724
744
  {
725
- className: cn(
726
- "mx-3 my-0.5 h-px border-0 bg-m3-outline-variant"
727
- )
745
+ className: cn("mx-3 my-0.5 h-px border-0 bg-m3-outline-variant")
728
746
  },
729
747
  `divider-${child.key || i}`
730
748
  )
@@ -732,8 +750,8 @@ var MenuContent = React36.forwardRef(
732
750
  }
733
751
  acc.push(child);
734
752
  return acc;
735
- }, []) : enhancedChildren;
736
- }
753
+ }, []);
754
+ }, [children, variant, isExpressiveGap, separatorStyle]);
737
755
  return /* @__PURE__ */ jsx(AnimatePresence, { children: open && /* @__PURE__ */ jsx(DropdownMenu.Portal, { forceMount: true, children: /* @__PURE__ */ jsx(
738
756
  DropdownMenu.Content,
739
757
  __spreadProps(__spreadValues({
@@ -765,9 +783,9 @@ var MenuContent = React36.forwardRef(
765
783
  }
766
784
  );
767
785
  MenuContent.displayName = "MenuContent";
768
- var MenuDivider = React36.forwardRef(
786
+ var MenuDivider = React37.forwardRef(
769
787
  (_a, ref) => {
770
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
788
+ var _b = _a, { className, isGapVariant: _isGapVariant } = _b, props = __objRest(_b, ["className", "isGapVariant"]);
771
789
  const { menuVariant } = useMenuContext();
772
790
  return /* @__PURE__ */ jsx(DropdownMenu.Separator, { asChild: true, children: /* @__PURE__ */ jsx(
773
791
  "hr",
@@ -796,7 +814,7 @@ function getGroupPosition(index, count) {
796
814
  function getGroupActiveShape(position) {
797
815
  return GROUP_SHAPES[`${position}Active`];
798
816
  }
799
- var MenuGroup = React36.forwardRef(
817
+ var MenuGroup = React37.forwardRef(
800
818
  (_a, ref) => {
801
819
  var _b = _a, {
802
820
  children,
@@ -817,46 +835,25 @@ var MenuGroup = React36.forwardRef(
817
835
  "itemPosition",
818
836
  "className"
819
837
  ]);
820
- const {
821
- menuVariant,
822
- colorVariant: contextColorVariant,
823
- isStatic
824
- } = useMenuContext();
838
+ const { menuVariant, colorVariant: contextColorVariant } = useMenuContext();
825
839
  const colorVariant = propColorVariant != null ? propColorVariant : contextColorVariant;
826
840
  const colors = menuVariant === "baseline" ? BASELINE_COLORS : colorVariant === "vibrant" ? VIBRANT_COLORS : STANDARD_COLORS;
827
841
  const position = getGroupPosition(index, count);
828
- const activeShape = getGroupActiveShape(position);
829
- const [isHovered, setIsHovered] = React36.useState(false);
830
- const currentShape = isStatic || isHovered ? activeShape : GROUP_SHAPES.inactive;
831
- const handlePointerEnter = React36.useCallback(() => setIsHovered(true), []);
832
- const handlePointerLeave = React36.useCallback(() => setIsHovered(false), []);
833
- const flattenChildren = (children2) => {
834
- return React36.Children.toArray(children2).reduce(
835
- (acc, child) => {
836
- if (React36.isValidElement(child)) {
837
- if (child.type === React36.Fragment) {
838
- return acc.concat(
839
- flattenChildren(
840
- child.props.children
841
- )
842
- );
843
- }
844
- acc.push(child);
845
- }
846
- return acc;
847
- },
848
- []
849
- );
850
- };
851
- const validChildren = flattenChildren(children);
852
- const itemCount = validChildren.length;
853
- const enhancedChildren = validChildren.map((child, i) => {
854
- const itemPosition2 = itemCount === 1 ? "standalone" : i === 0 ? "leading" : i === itemCount - 1 ? "trailing" : "middle";
855
- return React36.cloneElement(child, {
856
- itemPosition: itemPosition2,
857
- colorVariant
842
+ const currentShape = getGroupActiveShape(position);
843
+ const enhancedChildren = React37.useMemo(() => {
844
+ const valid = flattenChildren(children);
845
+ const itemCount = valid.length;
846
+ return valid.map((child, i) => {
847
+ var _a2;
848
+ if (typeof child.type === "string") return child;
849
+ const defaultItemPosition = itemCount === 1 ? "standalone" : i === 0 ? "leading" : i === itemCount - 1 ? "trailing" : "middle";
850
+ const itemPosition2 = (_a2 = child.props.itemPosition) != null ? _a2 : defaultItemPosition;
851
+ return React37.cloneElement(child, {
852
+ itemPosition: itemPosition2,
853
+ colorVariant
854
+ });
858
855
  });
859
- });
856
+ }, [children, colorVariant]);
860
857
  return /* @__PURE__ */ jsxs(
861
858
  m.div,
862
859
  __spreadProps(__spreadValues({
@@ -868,10 +865,8 @@ var MenuGroup = React36.forwardRef(
868
865
  // In baseline variant, MenuGroup is transparent so it shouldn't clip.
869
866
  // In expressive variant, it needs overflow-hidden to clip hover states to its morphing shape.
870
867
  menuVariant === "baseline" ? "" : "overflow-hidden",
871
- // Vertical padding: 2dp for gap variant (to match Figma), 4dp for baseline
872
- isGapVariant ? "py-0.5" : MENU_GROUP_PADDING_Y,
873
- // Horizontal padding: 4dp for expressive menus (both static and popup), 0 for baseline
874
- menuVariant === "expressive" ? "px-1" : "",
868
+ // Padding: uniform 4dp (p-1) for expressive menus (matches 12px inner item corners inside 16px outer corners)
869
+ menuVariant === "expressive" ? "p-1" : MENU_GROUP_PADDING_Y,
875
870
  // Gap variant has floating segments, so each group manages its own shadow
876
871
  isGapVariant ? "elevation-2" : "",
877
872
  // Background based on color variant (transparent for baseline to avoid double-layering)
@@ -879,9 +874,7 @@ var MenuGroup = React36.forwardRef(
879
874
  className
880
875
  ),
881
876
  animate: { borderRadius: currentShape },
882
- transition: FAST_SPATIAL_SPRING,
883
- onPointerEnter: handlePointerEnter,
884
- onPointerLeave: handlePointerLeave
877
+ transition: FAST_SPATIAL_SPRING
885
878
  }, rest), {
886
879
  children: [
887
880
  label && /* @__PURE__ */ jsx(
@@ -918,7 +911,7 @@ var VARIANT_FONT = {
918
911
  rounded: "'Material Symbols Rounded'",
919
912
  sharp: "'Material Symbols Sharp'"
920
913
  };
921
- var IconComponent = React36.forwardRef(
914
+ var IconComponent = React37.forwardRef(
922
915
  (_a, ref) => {
923
916
  var _b = _a, {
924
917
  name,
@@ -984,14 +977,14 @@ var IconComponent = React36.forwardRef(
984
977
  }
985
978
  );
986
979
  IconComponent.displayName = "Icon";
987
- var Icon = React36.memo(IconComponent);
980
+ var Icon = React37.memo(IconComponent);
988
981
  function getItemShapeClass(position, selected, isStatic = false, menuVariant = "expressive") {
989
982
  if (menuVariant === "baseline") return BASELINE_ITEM_SHAPE;
990
983
  if (selected) return ITEM_SHAPE_CLASSES.selected;
991
984
  if (isStatic && position === "standalone") return "rounded-[12px]";
992
985
  return ITEM_SHAPE_CLASSES[position];
993
986
  }
994
- var MenuItem = React36.forwardRef(
987
+ var MenuItem = React37.forwardRef(
995
988
  (_a, ref) => {
996
989
  var _b = _a, {
997
990
  children,
@@ -1004,11 +997,13 @@ var MenuItem = React36.forwardRef(
1004
997
  disabled = false,
1005
998
  itemPosition = "standalone",
1006
999
  colorVariant: propColorVariant,
1000
+ density: propDensity,
1007
1001
  keepOpen = false,
1008
1002
  className,
1009
1003
  isSubTrigger,
1010
1004
  value,
1011
- role
1005
+ role,
1006
+ isGapVariant: _isGapVariant
1012
1007
  } = _b, rest = __objRest(_b, [
1013
1008
  "children",
1014
1009
  "onClick",
@@ -1020,18 +1015,24 @@ var MenuItem = React36.forwardRef(
1020
1015
  "disabled",
1021
1016
  "itemPosition",
1022
1017
  "colorVariant",
1018
+ "density",
1023
1019
  "keepOpen",
1024
1020
  "className",
1025
1021
  "isSubTrigger",
1026
1022
  "value",
1027
- "role"
1023
+ "role",
1024
+ "isGapVariant"
1028
1025
  ]);
1026
+ var _a2;
1029
1027
  const {
1030
1028
  menuVariant,
1031
1029
  colorVariant: contextColorVariant,
1030
+ density: contextDensity,
1032
1031
  menuPrimitive
1033
1032
  } = useMenuContext();
1034
1033
  const colorVariant = propColorVariant != null ? propColorVariant : contextColorVariant;
1034
+ const density = (_a2 = propDensity != null ? propDensity : contextDensity) != null ? _a2 : 0;
1035
+ const minHeightClass = DENSITY_MIN_HEIGHT[density];
1035
1036
  const colors = menuVariant === "baseline" ? BASELINE_COLORS : colorVariant === "vibrant" ? VIBRANT_COLORS : STANDARD_COLORS;
1036
1037
  const isStaticMenu = menuPrimitive === "static";
1037
1038
  const shapeClass = getItemShapeClass(
@@ -1073,12 +1074,11 @@ var MenuItem = React36.forwardRef(
1073
1074
  className: cn(
1074
1075
  // Layout
1075
1076
  "relative flex w-full cursor-pointer select-none items-center outline-none",
1076
- // Sizing: min-h 48dp, min-w 112dp, max-w 280dp
1077
- "min-h-12 min-w-28 max-w-70",
1077
+ // Sizing: min-h based on density (48dp, 40dp, 32dp), min-w 112dp
1078
+ minHeightClass,
1079
+ "min-w-28",
1078
1080
  // Horizontal padding
1079
1081
  menuVariant === "baseline" ? MENU_BASELINE_ITEM_HORIZONTAL_PADDING : "px-4",
1080
- // Spacing between items
1081
- isStaticMenu ? "my-0.5" : "",
1082
1082
  // Shape morphing (position-based + selected override)
1083
1083
  shapeClass,
1084
1084
  // Animate border-radius AND background-color together (FastEffects: 150ms)
@@ -1090,7 +1090,7 @@ var MenuItem = React36.forwardRef(
1090
1090
  !selected && colors.focusLayer,
1091
1091
  // Focus visible ring (WCAG 2.4.11 — visible focus indicator)
1092
1092
  // Uses ring-inset so the ring doesn't overflow the item bounds.
1093
- "focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-m3-primary",
1093
+ "focus:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-m3-secondary data-highlighted:ring-0",
1094
1094
  // Disabled
1095
1095
  disabled && "pointer-events-none opacity-[0.38]",
1096
1096
  className
@@ -1193,31 +1193,31 @@ function SubMenu({
1193
1193
  }) {
1194
1194
  const { colorVariant: contextColorVariant, menuPrimitive } = useMenuContext();
1195
1195
  const colorVariant = propColorVariant != null ? propColorVariant : contextColorVariant;
1196
- const [open, setOpen] = React36.useState(false);
1197
- const openTimerRef = React36.useRef(null);
1198
- const closeTimerRef = React36.useRef(
1196
+ const [open, setOpen] = React37.useState(false);
1197
+ const openTimerRef = React37.useRef(null);
1198
+ const closeTimerRef = React37.useRef(
1199
1199
  null
1200
1200
  );
1201
- const clearTimers = React36.useCallback(() => {
1201
+ const clearTimers = React37.useCallback(() => {
1202
1202
  if (openTimerRef.current) clearTimeout(openTimerRef.current);
1203
1203
  if (closeTimerRef.current) clearTimeout(closeTimerRef.current);
1204
1204
  }, []);
1205
- const handleTriggerPointerEnter = React36.useCallback(() => {
1205
+ const handleTriggerPointerEnter = React37.useCallback(() => {
1206
1206
  clearTimers();
1207
1207
  openTimerRef.current = setTimeout(() => setOpen(true), hoverOpenDelay);
1208
1208
  }, [hoverOpenDelay, clearTimers]);
1209
- const handleTriggerPointerLeave = React36.useCallback(() => {
1209
+ const handleTriggerPointerLeave = React37.useCallback(() => {
1210
1210
  clearTimers();
1211
1211
  closeTimerRef.current = setTimeout(() => setOpen(false), hoverCloseDelay);
1212
1212
  }, [hoverCloseDelay, clearTimers]);
1213
- const handleContentPointerEnter = React36.useCallback(() => {
1213
+ const handleContentPointerEnter = React37.useCallback(() => {
1214
1214
  clearTimers();
1215
1215
  }, [clearTimers]);
1216
- const handleContentPointerLeave = React36.useCallback(() => {
1216
+ const handleContentPointerLeave = React37.useCallback(() => {
1217
1217
  clearTimers();
1218
1218
  closeTimerRef.current = setTimeout(() => setOpen(false), hoverCloseDelay);
1219
1219
  }, [hoverCloseDelay, clearTimers]);
1220
- React36.useEffect(() => () => clearTimers(), [clearTimers]);
1220
+ React37.useEffect(() => () => clearTimers(), [clearTimers]);
1221
1221
  const Sub3 = menuPrimitive === "context" ? RxContextMenu.Sub : DropdownMenu.Sub;
1222
1222
  const SubTrigger3 = menuPrimitive === "context" ? RxContextMenu.SubTrigger : DropdownMenu.SubTrigger;
1223
1223
  const SubContent3 = menuPrimitive === "context" ? RxContextMenu.SubContent : DropdownMenu.SubContent;
@@ -1229,7 +1229,7 @@ function SubMenu({
1229
1229
  className: "w-full outline-none",
1230
1230
  onPointerEnter: handleTriggerPointerEnter,
1231
1231
  onPointerLeave: handleTriggerPointerLeave,
1232
- children: React36.isValidElement(trigger) ? React36.cloneElement(trigger, {
1232
+ children: React37.isValidElement(trigger) ? React37.cloneElement(trigger, {
1233
1233
  isSubTrigger: true,
1234
1234
  // Auto-add chevron if missing
1235
1235
  trailingIcon: trigger.props.trailingIcon || /* @__PURE__ */ jsx(Icon, { name: "chevron_right", size: 20 })
@@ -1306,7 +1306,7 @@ function SubMenuContent({
1306
1306
  );
1307
1307
  }
1308
1308
  SubMenuContent.displayName = "SubMenuContent";
1309
- var VerticalMenuDivider = React36.forwardRef((_a, ref) => {
1309
+ var VerticalMenuDivider = React37.forwardRef((_a, ref) => {
1310
1310
  var _b = _a, { className, index, count, isGapVariant } = _b, props = __objRest(_b, ["className", "index", "count", "isGapVariant"]);
1311
1311
  return /* @__PURE__ */ jsx(
1312
1312
  "hr",
@@ -1326,7 +1326,7 @@ var VerticalMenuDivider = React36.forwardRef((_a, ref) => {
1326
1326
  });
1327
1327
  VerticalMenuDivider.displayName = "VerticalMenuDivider";
1328
1328
  var VerticalMenuGroup = MenuGroup;
1329
- var VerticalMenuContent = React36.forwardRef(
1329
+ var VerticalMenuContent = React37.forwardRef(
1330
1330
  (_a, ref) => {
1331
1331
  var _b = _a, {
1332
1332
  children,
@@ -1342,46 +1342,39 @@ var VerticalMenuContent = React36.forwardRef(
1342
1342
  const { colorVariant: contextColorVariant } = useMenuContext();
1343
1343
  const colorVariant = propColorVariant != null ? propColorVariant : contextColorVariant;
1344
1344
  const colors = colorVariant === "vibrant" ? VIBRANT_COLORS : STANDARD_COLORS;
1345
- const flattenChildren = (children2) => {
1346
- return React36.Children.toArray(children2).reduce(
1347
- (acc, child) => {
1348
- if (React36.isValidElement(child)) {
1349
- if (child.type === React36.Fragment) {
1350
- return acc.concat(
1351
- flattenChildren(
1352
- child.props.children
1353
- )
1354
- );
1355
- }
1356
- acc.push(child);
1345
+ const renderedChildren = React37.useMemo(() => {
1346
+ const valid = flattenChildren(children);
1347
+ const groupCount = valid.length;
1348
+ const enhanced = valid.map((child, i) => {
1349
+ var _a2;
1350
+ if (typeof child.type === "string") return child;
1351
+ const defaultItemPosition = groupCount === 1 ? "standalone" : i === 0 ? "leading" : i === groupCount - 1 ? "trailing" : "middle";
1352
+ const itemPosition = (_a2 = child.props.itemPosition) != null ? _a2 : defaultItemPosition;
1353
+ return React37.cloneElement(
1354
+ child,
1355
+ {
1356
+ index: i,
1357
+ count: groupCount,
1358
+ itemPosition,
1359
+ isGapVariant: separatorStyle === "gap"
1357
1360
  }
1358
- return acc;
1359
- },
1360
- []
1361
- );
1362
- };
1363
- const validChildren = flattenChildren(children);
1364
- const groupCount = validChildren.length;
1365
- const enhancedChildren = validChildren.map(
1366
- (child, i) => React36.cloneElement(child, {
1367
- index: i,
1368
- count: groupCount,
1369
- isGapVariant: separatorStyle === "gap"
1370
- })
1371
- );
1372
- const renderedChildren = separatorStyle === "divider" ? enhancedChildren.reduce((acc, child, i) => {
1373
- if (i > 0) {
1374
- acc.push(
1375
- /* @__PURE__ */ jsx(
1376
- VerticalMenuDivider,
1377
- {},
1378
- `divider-${child.key || i}`
1379
- )
1380
1361
  );
1381
- }
1382
- acc.push(child);
1383
- return acc;
1384
- }, []) : enhancedChildren;
1362
+ });
1363
+ if (separatorStyle !== "divider") return enhanced;
1364
+ return enhanced.reduce((acc, child, i) => {
1365
+ if (i > 0) {
1366
+ acc.push(
1367
+ /* @__PURE__ */ jsx(
1368
+ VerticalMenuDivider,
1369
+ {},
1370
+ `divider-${child.key || i}`
1371
+ )
1372
+ );
1373
+ }
1374
+ acc.push(child);
1375
+ return acc;
1376
+ }, []);
1377
+ }, [children, separatorStyle]);
1385
1378
  return /* @__PURE__ */ jsx(
1386
1379
  "div",
1387
1380
  __spreadProps(__spreadValues({
@@ -1400,13 +1393,13 @@ var VerticalMenuContent = React36.forwardRef(
1400
1393
  }
1401
1394
  );
1402
1395
  VerticalMenuContent.displayName = "VerticalMenuContent";
1403
- var VerticalMenu = React36.forwardRef((_a, ref) => {
1396
+ var VerticalMenu = React37.forwardRef((_a, ref) => {
1404
1397
  var _b = _a, { children, colorVariant = "standard", className } = _b, props = __objRest(_b, ["children", "colorVariant", "className"]);
1405
- const noop = React36.useCallback(() => {
1398
+ const noop = React37.useCallback(() => {
1406
1399
  }, []);
1407
1400
  const colors = colorVariant === "vibrant" ? VIBRANT_COLORS : STANDARD_COLORS;
1408
- const containerRef = React36.useRef(null);
1409
- const mergedRef = React36.useCallback(
1401
+ const containerRef = React37.useRef(null);
1402
+ const mergedRef = React37.useCallback(
1410
1403
  (node) => {
1411
1404
  containerRef.current = node;
1412
1405
  if (typeof ref === "function") ref(node);
@@ -1415,7 +1408,7 @@ var VerticalMenu = React36.forwardRef((_a, ref) => {
1415
1408
  },
1416
1409
  [ref]
1417
1410
  );
1418
- const handleKeyDown = React36.useCallback(
1411
+ const handleKeyDown = React37.useCallback(
1419
1412
  (e) => {
1420
1413
  var _a2;
1421
1414
  if (!containerRef.current) return;
@@ -1498,7 +1491,7 @@ var VerticalMenu = React36.forwardRef((_a, ref) => {
1498
1491
  });
1499
1492
  VerticalMenu.displayName = "VerticalMenu";
1500
1493
  function detectSeparatorStyle(children) {
1501
- const child = React36.Children.toArray(children).find(React36.isValidElement);
1494
+ const child = React37.Children.toArray(children).find(React37.isValidElement);
1502
1495
  if (child) {
1503
1496
  const style = child.props.separatorStyle;
1504
1497
  if (style) return style;
@@ -1579,11 +1572,11 @@ function AppBarColumn({
1579
1572
  maxItemCount,
1580
1573
  className
1581
1574
  }) {
1582
- const containerRef = React36.useRef(null);
1583
- const [visibleCount, setVisibleCount] = React36.useState(
1575
+ const containerRef = React37.useRef(null);
1576
+ const [visibleCount, setVisibleCount] = React37.useState(
1584
1577
  maxItemCount != null ? maxItemCount : items.length
1585
1578
  );
1586
- React36.useEffect(() => {
1579
+ React37.useEffect(() => {
1587
1580
  if (maxItemCount !== void 0) {
1588
1581
  setVisibleCount(Math.min(maxItemCount, items.length));
1589
1582
  return;
@@ -1631,11 +1624,11 @@ function AppBarColumn({
1631
1624
  );
1632
1625
  }
1633
1626
  function AppBarRow({ items, maxItemCount, className }) {
1634
- const containerRef = React36.useRef(null);
1635
- const [visibleCount, setVisibleCount] = React36.useState(
1627
+ const containerRef = React37.useRef(null);
1628
+ const [visibleCount, setVisibleCount] = React37.useState(
1636
1629
  maxItemCount != null ? maxItemCount : items.length
1637
1630
  );
1638
- React36.useEffect(() => {
1631
+ React37.useEffect(() => {
1639
1632
  if (maxItemCount !== void 0) {
1640
1633
  setVisibleCount(Math.min(maxItemCount, items.length));
1641
1634
  return;
@@ -1689,12 +1682,12 @@ function useAppBarScroll({
1689
1682
  collapsedHeight = 64,
1690
1683
  expandedHeight = 112
1691
1684
  } = {}) {
1692
- const [isScrolled, setIsScrolled] = React36.useState(false);
1693
- const [collapsedFraction, setCollapsedFraction] = React36.useState(0);
1694
- const [isHidden, setIsHidden] = React36.useState(false);
1695
- const prevScrollYRef = React36.useRef(0);
1685
+ const [isScrolled, setIsScrolled] = React37.useState(false);
1686
+ const [collapsedFraction, setCollapsedFraction] = React37.useState(0);
1687
+ const [isHidden, setIsHidden] = React37.useState(false);
1688
+ const prevScrollYRef = React37.useRef(0);
1696
1689
  const hideThreshold = 64;
1697
- React36.useEffect(() => {
1690
+ React37.useEffect(() => {
1698
1691
  var _a;
1699
1692
  const scrollDistance = expandedHeight - collapsedHeight;
1700
1693
  const getScrollY = () => {
@@ -1815,7 +1808,7 @@ function useFlexibleAppBar({
1815
1808
  expandedHeight
1816
1809
  });
1817
1810
  const scrollProgress = useMotionValue(0);
1818
- React36.useEffect(() => {
1811
+ React37.useEffect(() => {
1819
1812
  scrollProgress.set(
1820
1813
  shouldReduceMotion ? collapsedFraction > 0.5 ? 1 : 0 : collapsedFraction
1821
1814
  );
@@ -2156,7 +2149,7 @@ function SearchAppBar({
2156
2149
  }) {
2157
2150
  var _a, _b;
2158
2151
  const shouldReduceMotion = useReducedMotion();
2159
- const [isSearchOpen, setIsSearchOpen] = React36.useState(false);
2152
+ const [isSearchOpen, setIsSearchOpen] = React37.useState(false);
2160
2153
  const { isScrolled } = useAppBarScroll({
2161
2154
  scrollElement,
2162
2155
  behavior: scrollBehavior === "exitUntilCollapsed" ? "pinned" : scrollBehavior
@@ -2270,8 +2263,8 @@ function SearchView({
2270
2263
  className
2271
2264
  }) {
2272
2265
  const shouldReduceMotion = useReducedMotion();
2273
- const inputRef = React36.useRef(null);
2274
- React36.useEffect(() => {
2266
+ const inputRef = React37.useRef(null);
2267
+ React37.useEffect(() => {
2275
2268
  const timer = window.setTimeout(() => {
2276
2269
  var _a;
2277
2270
  (_a = inputRef.current) == null ? void 0 : _a.focus();
@@ -2527,7 +2520,7 @@ function SmallAppBar({
2527
2520
  "small-app-bar"
2528
2521
  ) });
2529
2522
  }
2530
- var RippleItem = React36.memo(function RippleItem2({
2523
+ var RippleItem = React37.memo(function RippleItem2({
2531
2524
  ripple,
2532
2525
  onDone
2533
2526
  }) {
@@ -2571,8 +2564,8 @@ function Ripple({
2571
2564
  }
2572
2565
  function useRippleState(options = {}) {
2573
2566
  const { disabled = false } = options;
2574
- const [ripples, setRipples] = React36.useState([]);
2575
- const onPointerDown = React36.useCallback(
2567
+ const [ripples, setRipples] = React37.useState([]);
2568
+ const onPointerDown = React37.useCallback(
2576
2569
  (e) => {
2577
2570
  if (disabled) return;
2578
2571
  const rect = e.currentTarget.getBoundingClientRect();
@@ -2589,7 +2582,7 @@ function useRippleState(options = {}) {
2589
2582
  },
2590
2583
  [disabled]
2591
2584
  );
2592
- const removeRipple = React36.useCallback((id) => {
2585
+ const removeRipple = React37.useCallback((id) => {
2593
2586
  setRipples((prev) => prev.filter((r) => r.id !== id));
2594
2587
  }, []);
2595
2588
  return { ripples, onPointerDown, removeRipple };
@@ -2603,27 +2596,1950 @@ function TouchTarget() {
2603
2596
  }
2604
2597
  );
2605
2598
  }
2606
- var NavigationBarContext = React36.createContext({ variant: "flexible" });
2599
+
2600
+ // src/shapes/core/features.ts
2601
+ function cornerFeature(cubics, convex2) {
2602
+ return { type: "corner", cubics, convex: convex2 };
2603
+ }
2604
+ function edgeFeature(cubics) {
2605
+ return { type: "edge", cubics };
2606
+ }
2607
+ function transformFeature(feature, fn) {
2608
+ const cubics = feature.cubics.map((c) => c.transformed(fn));
2609
+ if (feature.type === "corner") {
2610
+ return cornerFeature(cubics, feature.convex);
2611
+ }
2612
+ return edgeFeature(cubics);
2613
+ }
2614
+
2615
+ // src/shapes/math/corner-rounding.ts
2616
+ var UNROUNDED = Object.freeze({
2617
+ radius: 0,
2618
+ smoothing: 0
2619
+ });
2620
+
2621
+ // src/shapes/utils/utils.ts
2622
+ var DISTANCE_EPSILON = 1e-4;
2623
+ var FLOAT_PI = Math.PI;
2624
+ function distance(dx, dy) {
2625
+ return Math.sqrt(dx * dx + dy * dy);
2626
+ }
2627
+ function distanceSquared(dx, dy) {
2628
+ return dx * dx + dy * dy;
2629
+ }
2630
+ function radialToCartesian(radius, angle) {
2631
+ return [radius * Math.cos(angle), radius * Math.sin(angle)];
2632
+ }
2633
+ function interpolate(start, stop, fraction) {
2634
+ return start + (stop - start) * fraction;
2635
+ }
2636
+ function square(value) {
2637
+ return value * value;
2638
+ }
2639
+ function convex(prevX, prevY, currX, currY, nextX, nextY) {
2640
+ const v1x = currX - prevX;
2641
+ const v1y = currY - prevY;
2642
+ const v2x = nextX - currX;
2643
+ const v2y = nextY - currY;
2644
+ return v1x * v2y - v1y * v2x > 0;
2645
+ }
2646
+
2647
+ // src/shapes/math/point.ts
2648
+ function point(x, y) {
2649
+ return { x, y };
2650
+ }
2651
+
2652
+ // src/shapes/math/cubic.ts
2653
+ var Cubic = class _Cubic {
2654
+ constructor(points) {
2655
+ if (points.length !== 8)
2656
+ throw new Error("Cubic points array must have exactly 8 elements");
2657
+ this.points = points;
2658
+ }
2659
+ /** First anchor point X */
2660
+ get anchor0X() {
2661
+ return this.points[0];
2662
+ }
2663
+ /** First anchor point Y */
2664
+ get anchor0Y() {
2665
+ return this.points[1];
2666
+ }
2667
+ /** First control point X */
2668
+ get control0X() {
2669
+ return this.points[2];
2670
+ }
2671
+ /** First control point Y */
2672
+ get control0Y() {
2673
+ return this.points[3];
2674
+ }
2675
+ /** Second control point X */
2676
+ get control1X() {
2677
+ return this.points[4];
2678
+ }
2679
+ /** Second control point Y */
2680
+ get control1Y() {
2681
+ return this.points[5];
2682
+ }
2683
+ /** Second anchor point X */
2684
+ get anchor1X() {
2685
+ return this.points[6];
2686
+ }
2687
+ /** Second anchor point Y */
2688
+ get anchor1Y() {
2689
+ return this.points[7];
2690
+ }
2691
+ /**
2692
+ * Returns a point on the curve at parameter t (0=start, 1=end).
2693
+ * Uses the standard cubic Bézier formula.
2694
+ * @param t - Parameter in [0, 1]
2695
+ */
2696
+ pointOnCurve(t) {
2697
+ const u = 1 - t;
2698
+ return point(
2699
+ this.anchor0X * (u * u * u) + this.control0X * (3 * t * u * u) + this.control1X * (3 * t * t * u) + this.anchor1X * (t * t * t),
2700
+ this.anchor0Y * (u * u * u) + this.control0Y * (3 * t * u * u) + this.control1Y * (3 * t * t * u) + this.anchor1Y * (t * t * t)
2701
+ );
2702
+ }
2703
+ /**
2704
+ * Returns true if this curve has (near) zero length.
2705
+ */
2706
+ zeroLength() {
2707
+ return Math.abs(this.anchor0X - this.anchor1X) < DISTANCE_EPSILON && Math.abs(this.anchor0Y - this.anchor1Y) < DISTANCE_EPSILON;
2708
+ }
2709
+ /**
2710
+ * Splits this cubic at parameter t, returning two cubics.
2711
+ * Uses De Casteljau's algorithm.
2712
+ * @param t - Split parameter in [0, 1]
2713
+ * @returns [left, right] pair
2714
+ */
2715
+ split(t) {
2716
+ const u = 1 - t;
2717
+ const mid = this.pointOnCurve(t);
2718
+ const left = new _Cubic([
2719
+ this.anchor0X,
2720
+ this.anchor0Y,
2721
+ this.anchor0X * u + this.control0X * t,
2722
+ this.anchor0Y * u + this.control0Y * t,
2723
+ this.anchor0X * (u * u) + this.control0X * (2 * u * t) + this.control1X * (t * t),
2724
+ this.anchor0Y * (u * u) + this.control0Y * (2 * u * t) + this.control1Y * (t * t),
2725
+ mid.x,
2726
+ mid.y
2727
+ ]);
2728
+ const right = new _Cubic([
2729
+ mid.x,
2730
+ mid.y,
2731
+ this.control0X * (u * u) + this.control1X * (2 * u * t) + this.anchor1X * (t * t),
2732
+ this.control0Y * (u * u) + this.control1Y * (2 * u * t) + this.anchor1Y * (t * t),
2733
+ this.control1X * u + this.anchor1X * t,
2734
+ this.control1Y * u + this.anchor1Y * t,
2735
+ this.anchor1X,
2736
+ this.anchor1Y
2737
+ ]);
2738
+ return [left, right];
2739
+ }
2740
+ /**
2741
+ * Returns a reversed copy of this cubic (anchor0 ↔ anchor1, controls swapped).
2742
+ */
2743
+ reverse() {
2744
+ return new _Cubic([
2745
+ this.anchor1X,
2746
+ this.anchor1Y,
2747
+ this.control1X,
2748
+ this.control1Y,
2749
+ this.control0X,
2750
+ this.control0Y,
2751
+ this.anchor0X,
2752
+ this.anchor0Y
2753
+ ]);
2754
+ }
2755
+ /**
2756
+ * Calculates the axis-aligned bounding box.
2757
+ * @param approximate - If true, uses control point hull (faster). Default: false.
2758
+ * @returns [minX, minY, maxX, maxY]
2759
+ */
2760
+ calculateBounds(approximate = false) {
2761
+ if (this.zeroLength()) {
2762
+ return [this.anchor0X, this.anchor0Y, this.anchor0X, this.anchor0Y];
2763
+ }
2764
+ let minX = Math.min(this.anchor0X, this.anchor1X);
2765
+ let minY = Math.min(this.anchor0Y, this.anchor1Y);
2766
+ let maxX = Math.max(this.anchor0X, this.anchor1X);
2767
+ let maxY = Math.max(this.anchor0Y, this.anchor1Y);
2768
+ if (approximate) {
2769
+ minX = Math.min(minX, this.control0X, this.control1X);
2770
+ minY = Math.min(minY, this.control0Y, this.control1Y);
2771
+ maxX = Math.max(maxX, this.control0X, this.control1X);
2772
+ maxY = Math.max(maxY, this.control0Y, this.control1Y);
2773
+ return [minX, minY, maxX, maxY];
2774
+ }
2775
+ const xa = -this.anchor0X + 3 * this.control0X - 3 * this.control1X + this.anchor1X;
2776
+ const xb = 2 * this.anchor0X - 4 * this.control0X + 2 * this.control1X;
2777
+ const xc = -this.anchor0X + this.control0X;
2778
+ const expandX = (t) => {
2779
+ if (t >= 0 && t <= 1) {
2780
+ const v = this.pointOnCurve(t).x;
2781
+ if (v < minX) minX = v;
2782
+ if (v > maxX) maxX = v;
2783
+ }
2784
+ };
2785
+ if (Math.abs(xa) < DISTANCE_EPSILON) {
2786
+ if (xb !== 0) expandX(2 * xc / (-2 * xb));
2787
+ } else {
2788
+ const xs = xb * xb - 4 * xa * xc;
2789
+ if (xs >= 0) {
2790
+ expandX((-xb + Math.sqrt(xs)) / (2 * xa));
2791
+ expandX((-xb - Math.sqrt(xs)) / (2 * xa));
2792
+ }
2793
+ }
2794
+ const ya = -this.anchor0Y + 3 * this.control0Y - 3 * this.control1Y + this.anchor1Y;
2795
+ const yb = 2 * this.anchor0Y - 4 * this.control0Y + 2 * this.control1Y;
2796
+ const yc = -this.anchor0Y + this.control0Y;
2797
+ const expandY = (t) => {
2798
+ if (t >= 0 && t <= 1) {
2799
+ const v = this.pointOnCurve(t).y;
2800
+ if (v < minY) minY = v;
2801
+ if (v > maxY) maxY = v;
2802
+ }
2803
+ };
2804
+ if (Math.abs(ya) < DISTANCE_EPSILON) {
2805
+ if (yb !== 0) expandY(2 * yc / (-2 * yb));
2806
+ } else {
2807
+ const ys = yb * yb - 4 * ya * yc;
2808
+ if (ys >= 0) {
2809
+ expandY((-yb + Math.sqrt(ys)) / (2 * ya));
2810
+ expandY((-yb - Math.sqrt(ys)) / (2 * ya));
2811
+ }
2812
+ }
2813
+ return [minX, minY, maxX, maxY];
2814
+ }
2815
+ /**
2816
+ * Interpolates between this cubic and another at fraction t.
2817
+ * @param other - Target cubic
2818
+ * @param t - Fraction [0, 1]
2819
+ */
2820
+ interpolateTo(other, t) {
2821
+ return new _Cubic(
2822
+ this.points.map((v, i) => interpolate(v, other.points[i], t))
2823
+ );
2824
+ }
2825
+ /**
2826
+ * Applies a PointTransformer to all anchor and control points.
2827
+ * @param fn - The transform function
2828
+ */
2829
+ transformed(fn) {
2830
+ const p = this.points.slice();
2831
+ for (let i = 0; i < 8; i += 2) {
2832
+ const [tx, ty] = fn(p[i], p[i + 1]);
2833
+ p[i] = tx;
2834
+ p[i + 1] = ty;
2835
+ }
2836
+ return new _Cubic(p);
2837
+ }
2838
+ toString() {
2839
+ return `Cubic(a0=(${this.anchor0X},${this.anchor0Y}) c0=(${this.control0X},${this.control0Y}) c1=(${this.control1X},${this.control1Y}) a1=(${this.anchor1X},${this.anchor1Y}))`;
2840
+ }
2841
+ // ─── Static factories ─────────────────────────────────────────────────────
2842
+ /**
2843
+ * Creates a cubic representing a straight line.
2844
+ * Control points lie at 1/3 and 2/3 of the line.
2845
+ * @param x0 - Start anchor X
2846
+ * @param y0 - Start anchor Y
2847
+ * @param x1 - End anchor X
2848
+ * @param y1 - End anchor Y
2849
+ */
2850
+ static straightLine(x0, y0, x1, y1) {
2851
+ return new _Cubic([
2852
+ x0,
2853
+ y0,
2854
+ interpolate(x0, x1, 1 / 3),
2855
+ interpolate(y0, y1, 1 / 3),
2856
+ interpolate(x0, x1, 2 / 3),
2857
+ interpolate(y0, y1, 2 / 3),
2858
+ x1,
2859
+ y1
2860
+ ]);
2861
+ }
2862
+ /**
2863
+ * Creates a cubic approximating a circular arc.
2864
+ * p0 and p1 must be equidistant from the center.
2865
+ * For arcs > 180°, use multiple cubics.
2866
+ *
2867
+ * @param centerX - Arc center X
2868
+ * @param centerY - Arc center Y
2869
+ * @param x0 - Start point X (on circle)
2870
+ * @param y0 - Start point Y (on circle)
2871
+ * @param x1 - End point X (on circle)
2872
+ * @param y1 - End point Y (on circle)
2873
+ */
2874
+ static circularArc(centerX, centerY, x0, y0, x1, y1) {
2875
+ const p0dx = x0 - centerX;
2876
+ const p0dy = y0 - centerY;
2877
+ const p1dx = x1 - centerX;
2878
+ const p1dy = y1 - centerY;
2879
+ const d0 = Math.sqrt(p0dx * p0dx + p0dy * p0dy);
2880
+ const d1 = Math.sqrt(p1dx * p1dx + p1dy * p1dy);
2881
+ if (d0 < DISTANCE_EPSILON || d1 < DISTANCE_EPSILON) {
2882
+ return _Cubic.straightLine(x0, y0, x1, y1);
2883
+ }
2884
+ const nx0 = p0dx / d0, ny0 = p0dy / d0;
2885
+ const nx1 = p1dx / d1, ny1 = p1dy / d1;
2886
+ const rx0 = -ny0, ry0 = nx0;
2887
+ const rx1 = -ny1, ry1 = nx1;
2888
+ const cosa = nx0 * nx1 + ny0 * ny1;
2889
+ if (cosa > 0.999) return _Cubic.straightLine(x0, y0, x1, y1);
2890
+ const clockwise = rx0 * p1dx + ry0 * p1dy >= 0;
2891
+ const k = d0 * (4 / 3) * (Math.sqrt(2 * (1 - cosa)) - Math.sqrt(1 - square(cosa))) / (1 - cosa) * (clockwise ? 1 : -1);
2892
+ return new _Cubic([
2893
+ x0,
2894
+ y0,
2895
+ x0 + rx0 * k,
2896
+ y0 + ry0 * k,
2897
+ x1 - rx1 * k,
2898
+ y1 - ry1 * k,
2899
+ x1,
2900
+ y1
2901
+ ]);
2902
+ }
2903
+ /**
2904
+ * Creates a zero-length cubic at the given point.
2905
+ * @param x - X coordinate
2906
+ * @param y - Y coordinate
2907
+ */
2908
+ static empty(x, y) {
2909
+ return new _Cubic([x, y, x, y, x, y, x, y]);
2910
+ }
2911
+ };
2912
+
2913
+ // src/shapes/core/rounded-polygon.ts
2914
+ var RoundedCorner = class {
2915
+ constructor(p0, p1, p2, rounding = UNROUNDED) {
2916
+ this.p0 = p0;
2917
+ this.p1 = p1;
2918
+ this.p2 = p2;
2919
+ this.rounding = rounding;
2920
+ this.center = point(0, 0);
2921
+ const v01x = p0.x - p1.x, v01y = p0.y - p1.y;
2922
+ const v21x = p2.x - p1.x, v21y = p2.y - p1.y;
2923
+ const d01 = distance(v01x, v01y);
2924
+ const d21 = distance(v21x, v21y);
2925
+ if (d01 > 0 && d21 > 0) {
2926
+ this.d1 = point(v01x / d01, v01y / d01);
2927
+ this.d2 = point(v21x / d21, v21y / d21);
2928
+ this.cornerRadius = rounding.radius;
2929
+ this.smoothing = rounding.smoothing;
2930
+ const cosA = this.d1.x * this.d2.x + this.d1.y * this.d2.y;
2931
+ this.sinAngle = Math.sqrt(Math.max(0, 1 - square(cosA)));
2932
+ this.expectedRoundCut = this.sinAngle > 1e-3 ? this.cornerRadius * (cosA + 1) / this.sinAngle : 0;
2933
+ } else {
2934
+ this.d1 = point(0, 0);
2935
+ this.d2 = point(0, 0);
2936
+ this.cornerRadius = 0;
2937
+ this.smoothing = 0;
2938
+ this.sinAngle = 0;
2939
+ this.expectedRoundCut = 0;
2940
+ }
2941
+ }
2942
+ get expectedCut() {
2943
+ return (1 + this.smoothing) * this.expectedRoundCut;
2944
+ }
2945
+ getCubics(allowedCut0, allowedCut1 = allowedCut0) {
2946
+ const allowedCut = Math.min(allowedCut0, allowedCut1);
2947
+ if (this.expectedRoundCut < DISTANCE_EPSILON || allowedCut < DISTANCE_EPSILON || this.cornerRadius < DISTANCE_EPSILON) {
2948
+ this.center = this.p1;
2949
+ return [Cubic.straightLine(this.p1.x, this.p1.y, this.p1.x, this.p1.y)];
2950
+ }
2951
+ const actualRoundCut = Math.min(allowedCut, this.expectedRoundCut);
2952
+ const actualSmoothing0 = this.calcSmoothingValue(allowedCut0);
2953
+ const actualSmoothing1 = this.calcSmoothingValue(allowedCut1);
2954
+ const actualR = this.cornerRadius * actualRoundCut / this.expectedRoundCut;
2955
+ const centerDist = Math.sqrt(square(actualR) + square(actualRoundCut));
2956
+ const midDirX = (this.d1.x + this.d2.x) / 2;
2957
+ const midDirY = (this.d1.y + this.d2.y) / 2;
2958
+ const midDist = distance(midDirX, midDirY);
2959
+ this.center = point(
2960
+ this.p1.x + midDirX / midDist * centerDist,
2961
+ this.p1.y + midDirY / midDist * centerDist
2962
+ );
2963
+ const ci0 = point(
2964
+ this.p1.x + this.d1.x * actualRoundCut,
2965
+ this.p1.y + this.d1.y * actualRoundCut
2966
+ );
2967
+ const ci2 = point(
2968
+ this.p1.x + this.d2.x * actualRoundCut,
2969
+ this.p1.y + this.d2.y * actualRoundCut
2970
+ );
2971
+ const flanking0 = this.computeFlankingCurve(
2972
+ actualRoundCut,
2973
+ actualSmoothing0,
2974
+ this.p1,
2975
+ this.p0,
2976
+ ci0,
2977
+ ci2,
2978
+ this.center,
2979
+ actualR
2980
+ );
2981
+ const flanking2 = this.computeFlankingCurve(
2982
+ actualRoundCut,
2983
+ actualSmoothing1,
2984
+ this.p1,
2985
+ this.p2,
2986
+ ci2,
2987
+ ci0,
2988
+ this.center,
2989
+ actualR
2990
+ ).reverse();
2991
+ return [
2992
+ flanking0,
2993
+ Cubic.circularArc(
2994
+ this.center.x,
2995
+ this.center.y,
2996
+ flanking0.anchor1X,
2997
+ flanking0.anchor1Y,
2998
+ flanking2.anchor0X,
2999
+ flanking2.anchor0Y
3000
+ ),
3001
+ flanking2
3002
+ ];
3003
+ }
3004
+ calcSmoothingValue(allowedCut) {
3005
+ if (allowedCut > this.expectedCut) return this.smoothing;
3006
+ if (allowedCut > this.expectedRoundCut) {
3007
+ return this.smoothing * (allowedCut - this.expectedRoundCut) / (this.expectedCut - this.expectedRoundCut);
3008
+ }
3009
+ return 0;
3010
+ }
3011
+ computeFlankingCurve(actualRoundCut, actualSmoothing, corner, sideStart, circleIntersect, otherIntersect, circleCenter, actualR) {
3012
+ var _a;
3013
+ const sdx = sideStart.x - corner.x, sdy = sideStart.y - corner.y;
3014
+ const sd = distance(sdx, sdy);
3015
+ const sideDir = point(sdx / sd, sdy / sd);
3016
+ const curveStart = point(
3017
+ corner.x + sideDir.x * actualRoundCut * (1 + actualSmoothing),
3018
+ corner.y + sideDir.y * actualRoundCut * (1 + actualSmoothing)
3019
+ );
3020
+ const px = interpolate(
3021
+ circleIntersect.x,
3022
+ (circleIntersect.x + otherIntersect.x) / 2,
3023
+ actualSmoothing
3024
+ );
3025
+ const py = interpolate(
3026
+ circleIntersect.y,
3027
+ (circleIntersect.y + otherIntersect.y) / 2,
3028
+ actualSmoothing
3029
+ );
3030
+ const ptoCx = px - circleCenter.x, ptoCy = py - circleCenter.y;
3031
+ const ptoCd = distance(ptoCx, ptoCy);
3032
+ const curveEnd = point(
3033
+ circleCenter.x + ptoCx / ptoCd * actualR,
3034
+ circleCenter.y + ptoCy / ptoCd * actualR
3035
+ );
3036
+ const tangentX = -(curveEnd.y - circleCenter.y);
3037
+ const tangentY = curveEnd.x - circleCenter.x;
3038
+ const anchorEnd = (_a = lineIntersection(
3039
+ sideStart,
3040
+ sideDir,
3041
+ curveEnd,
3042
+ point(tangentX, tangentY)
3043
+ )) != null ? _a : circleIntersect;
3044
+ const anchorStart = point(
3045
+ (curveStart.x + anchorEnd.x * 2) / 3,
3046
+ (curveStart.y + anchorEnd.y * 2) / 3
3047
+ );
3048
+ return new Cubic([
3049
+ curveStart.x,
3050
+ curveStart.y,
3051
+ anchorStart.x,
3052
+ anchorStart.y,
3053
+ anchorEnd.x,
3054
+ anchorEnd.y,
3055
+ curveEnd.x,
3056
+ curveEnd.y
3057
+ ]);
3058
+ }
3059
+ };
3060
+ function lineIntersection(p0, d0, p1, d1) {
3061
+ const rd1x = -d1.y, rd1y = d1.x;
3062
+ const den = d0.x * rd1x + d0.y * rd1y;
3063
+ if (Math.abs(den) < DISTANCE_EPSILON) return null;
3064
+ const num = (p1.x - p0.x) * rd1x + (p1.y - p0.y) * rd1y;
3065
+ if (Math.abs(den) < DISTANCE_EPSILON * Math.abs(num)) return null;
3066
+ const k = num / den;
3067
+ return point(p0.x + d0.x * k, p0.y + d0.y * k);
3068
+ }
3069
+ function calculateCenter(vertices) {
3070
+ let cx = 0, cy = 0;
3071
+ for (let i = 0; i < vertices.length; i += 2) {
3072
+ cx += vertices[i];
3073
+ cy += vertices[i + 1];
3074
+ }
3075
+ const n = vertices.length / 2;
3076
+ return point(cx / n, cy / n);
3077
+ }
3078
+ function verticesFromNumVerts(numVertices, radius, cx, cy) {
3079
+ const result = [];
3080
+ for (let i = 0; i < numVertices; i++) {
3081
+ const angle = FLOAT_PI / numVertices * 2 * i;
3082
+ const [rx, ry] = radialToCartesian(radius, angle);
3083
+ result.push(cx + rx, cy + ry);
3084
+ }
3085
+ return result;
3086
+ }
3087
+ var RoundedPolygon = class _RoundedPolygon {
3088
+ /** @internal Use static factory methods instead */
3089
+ constructor(features, center) {
3090
+ this.features = features;
3091
+ this.center = center;
3092
+ this.cubics = buildCubicsList(features);
3093
+ validateContiguity(this.cubics);
3094
+ }
3095
+ get centerX() {
3096
+ return this.center.x;
3097
+ }
3098
+ get centerY() {
3099
+ return this.center.y;
3100
+ }
3101
+ // ─── Static factories ────────────────────────────────────────────────
3102
+ /**
3103
+ * Creates a polygon from a vertex count (regular polygon).
3104
+ * @param numVertices - Number of vertices (≥ 3)
3105
+ * @param radius - Circumradius (default: 1)
3106
+ * @param centerX - Center X (default: 0)
3107
+ * @param centerY - Center Y (default: 0)
3108
+ * @param rounding - Corner rounding for all vertices
3109
+ * @param perVertexRounding - Per-vertex rounding overrides
3110
+ */
3111
+ static fromNumVertices(numVertices, radius = 1, centerX = 0, centerY = 0, rounding = UNROUNDED, perVertexRounding) {
3112
+ if (numVertices < 3)
3113
+ throw new Error("Polygon must have at least 3 vertices");
3114
+ const vertices = verticesFromNumVerts(
3115
+ numVertices,
3116
+ radius,
3117
+ centerX,
3118
+ centerY
3119
+ );
3120
+ return _RoundedPolygon.fromVertices(
3121
+ vertices,
3122
+ rounding,
3123
+ perVertexRounding,
3124
+ centerX,
3125
+ centerY
3126
+ );
3127
+ }
3128
+ /**
3129
+ * Creates a polygon from a flat vertex array [x0, y0, x1, y1, ...].
3130
+ * @param vertices - Flat array of x,y pairs (length must be even and ≥ 6)
3131
+ * @param rounding - Corner rounding for all vertices
3132
+ * @param perVertexRounding - Per-vertex rounding overrides
3133
+ * @param centerX - Center X (auto-calculated if not provided)
3134
+ * @param centerY - Center Y (auto-calculated if not provided)
3135
+ */
3136
+ static fromVertices(vertices, rounding = UNROUNDED, perVertexRounding, centerX, centerY) {
3137
+ if (vertices.length < 6)
3138
+ throw new Error("Polygon must have at least 3 vertices");
3139
+ if (vertices.length % 2 !== 0)
3140
+ throw new Error("Vertices array must have even length");
3141
+ if (perVertexRounding && perVertexRounding.length * 2 !== vertices.length) {
3142
+ throw new Error("perVertexRounding must match vertex count");
3143
+ }
3144
+ const n = vertices.length / 2;
3145
+ const roundedCorners = [];
3146
+ for (let i = 0; i < n; i++) {
3147
+ const vtxRounding = perVertexRounding ? perVertexRounding[i] : rounding;
3148
+ const prevIdx = (i + n - 1) % n * 2;
3149
+ const nextIdx = (i + 1) % n * 2;
3150
+ roundedCorners.push(
3151
+ new RoundedCorner(
3152
+ point(vertices[prevIdx], vertices[prevIdx + 1]),
3153
+ point(vertices[i * 2], vertices[i * 2 + 1]),
3154
+ point(vertices[nextIdx], vertices[nextIdx + 1]),
3155
+ vtxRounding
3156
+ )
3157
+ );
3158
+ }
3159
+ const cutAdjusts = [];
3160
+ for (let ix = 0; ix < n; ix++) {
3161
+ const expectedRoundCut = roundedCorners[ix].expectedRoundCut + roundedCorners[(ix + 1) % n].expectedRoundCut;
3162
+ const expectedCut = roundedCorners[ix].expectedCut + roundedCorners[(ix + 1) % n].expectedCut;
3163
+ const vx = vertices[ix * 2], vy = vertices[ix * 2 + 1];
3164
+ const nx = vertices[(ix + 1) % n * 2], ny = vertices[(ix + 1) % n * 2 + 1];
3165
+ const sideSize = distance(vx - nx, vy - ny);
3166
+ if (expectedRoundCut > sideSize) {
3167
+ cutAdjusts.push([sideSize / expectedRoundCut, 0]);
3168
+ } else if (expectedCut > sideSize) {
3169
+ cutAdjusts.push([
3170
+ 1,
3171
+ (sideSize - expectedRoundCut) / (expectedCut - expectedRoundCut)
3172
+ ]);
3173
+ } else {
3174
+ cutAdjusts.push([1, 1]);
3175
+ }
3176
+ }
3177
+ const corners = [];
3178
+ for (let i = 0; i < n; i++) {
3179
+ const allowedCuts = [];
3180
+ for (const delta of [0, 1]) {
3181
+ const [roundCutRatio, cutRatio] = cutAdjusts[(i + n - 1 + delta) % n];
3182
+ allowedCuts.push(
3183
+ roundedCorners[i].expectedRoundCut * roundCutRatio + (roundedCorners[i].expectedCut - roundedCorners[i].expectedRoundCut) * cutRatio
3184
+ );
3185
+ }
3186
+ corners.push(roundedCorners[i].getCubics(allowedCuts[0], allowedCuts[1]));
3187
+ }
3188
+ const tempFeatures = [];
3189
+ for (let i = 0; i < n; i++) {
3190
+ const prevIdx = (i + n - 1) % n;
3191
+ const nextIdx = (i + 1) % n;
3192
+ const currV = point(vertices[i * 2], vertices[i * 2 + 1]);
3193
+ const prevV = point(vertices[prevIdx * 2], vertices[prevIdx * 2 + 1]);
3194
+ const nextV = point(vertices[nextIdx * 2], vertices[nextIdx * 2 + 1]);
3195
+ const isConvex = convex(
3196
+ prevV.x,
3197
+ prevV.y,
3198
+ currV.x,
3199
+ currV.y,
3200
+ nextV.x,
3201
+ nextV.y
3202
+ );
3203
+ tempFeatures.push(cornerFeature(corners[i], isConvex));
3204
+ const lastCornerA1 = corners[i][corners[i].length - 1];
3205
+ const nextCornerA0 = corners[(i + 1) % n][0];
3206
+ tempFeatures.push(
3207
+ edgeFeature([
3208
+ Cubic.straightLine(
3209
+ lastCornerA1.anchor1X,
3210
+ lastCornerA1.anchor1Y,
3211
+ nextCornerA0.anchor0X,
3212
+ nextCornerA0.anchor0Y
3213
+ )
3214
+ ])
3215
+ );
3216
+ }
3217
+ const cx = centerX != null ? centerX : calculateCenter(vertices).x;
3218
+ const cy = centerY != null ? centerY : calculateCenter(vertices).y;
3219
+ return new _RoundedPolygon(tempFeatures, point(cx, cy));
3220
+ }
3221
+ /**
3222
+ * Creates a polygon from a pre-built Feature list.
3223
+ * @param features - Feature list (≥ 2 features)
3224
+ * @param centerX - Center X (auto-calculated if NaN)
3225
+ * @param centerY - Center Y (auto-calculated if NaN)
3226
+ */
3227
+ static fromFeatures(features, centerX = Number.NaN, centerY = Number.NaN) {
3228
+ if (features.length < 2)
3229
+ throw new Error("Polygon must have at least 2 features");
3230
+ const allVertices = [];
3231
+ for (const f of features) {
3232
+ for (const c of f.cubics) {
3233
+ allVertices.push(c.anchor0X, c.anchor0Y);
3234
+ }
3235
+ }
3236
+ const cx = Number.isNaN(centerX) ? calculateCenter(allVertices).x : centerX;
3237
+ const cy = Number.isNaN(centerY) ? calculateCenter(allVertices).y : centerY;
3238
+ return new _RoundedPolygon(features, point(cx, cy));
3239
+ }
3240
+ // ─── Instance methods ────────────────────────────────────────────────
3241
+ /**
3242
+ * Returns a new RoundedPolygon with all points transformed.
3243
+ * @param fn - Transform function: (x, y) => [x', y']
3244
+ */
3245
+ transformed(fn) {
3246
+ const [cx, cy] = fn(this.center.x, this.center.y);
3247
+ return new _RoundedPolygon(
3248
+ this.features.map((f) => transformFeature(f, fn)),
3249
+ point(cx, cy)
3250
+ );
3251
+ }
3252
+ /**
3253
+ * Returns a normalized copy: scaled and centered to fit in [0,1] × [0,1].
3254
+ * Maintains aspect ratio by using the larger dimension.
3255
+ */
3256
+ normalized() {
3257
+ const [minX, minY, maxX, maxY] = this.calculateBounds(false);
3258
+ const width = maxX - minX;
3259
+ const height = maxY - minY;
3260
+ const side = Math.max(width, height);
3261
+ const offsetX = (side - width) / 2 - minX;
3262
+ const offsetY = (side - height) / 2 - minY;
3263
+ return this.transformed((x, y) => [
3264
+ (x + offsetX) / side,
3265
+ (y + offsetY) / side
3266
+ ]);
3267
+ }
3268
+ /**
3269
+ * Calculates the axis-aligned bounding box.
3270
+ * @param approximate - If true, uses control point hull (faster). Default: true.
3271
+ * @returns [minX, minY, maxX, maxY]
3272
+ */
3273
+ calculateBounds(approximate = true) {
3274
+ let minX = Number.MAX_VALUE, minY = Number.MAX_VALUE;
3275
+ let maxX = -Number.MAX_VALUE, maxY = -Number.MAX_VALUE;
3276
+ for (const c of this.cubics) {
3277
+ const [cx0, cy0, cx1, cy1] = c.calculateBounds(approximate);
3278
+ if (cx0 < minX) minX = cx0;
3279
+ if (cy0 < minY) minY = cy0;
3280
+ if (cx1 > maxX) maxX = cx1;
3281
+ if (cy1 > maxY) maxY = cy1;
3282
+ }
3283
+ return [minX, minY, maxX, maxY];
3284
+ }
3285
+ /**
3286
+ * Calculates the maximum bounding square (useful for shapes that rotate).
3287
+ * @returns [minX, minY, maxX, maxY] of the max-bounds square
3288
+ */
3289
+ calculateMaxBounds() {
3290
+ let maxDistSq = 0;
3291
+ for (const c of this.cubics) {
3292
+ const ad = distanceSquared(
3293
+ c.anchor0X - this.centerX,
3294
+ c.anchor0Y - this.centerY
3295
+ );
3296
+ const mid = c.pointOnCurve(0.5);
3297
+ const md = distanceSquared(mid.x - this.centerX, mid.y - this.centerY);
3298
+ const m31 = Math.max(ad, md);
3299
+ if (m31 > maxDistSq) maxDistSq = m31;
3300
+ }
3301
+ const d = Math.sqrt(maxDistSq);
3302
+ return [
3303
+ this.centerX - d,
3304
+ this.centerY - d,
3305
+ this.centerX + d,
3306
+ this.centerY + d
3307
+ ];
3308
+ }
3309
+ };
3310
+ function buildCubicsList(features) {
3311
+ const result = [];
3312
+ let firstCubic = null;
3313
+ let lastCubic = null;
3314
+ let firstFeatureSplitStart = null;
3315
+ let firstFeatureSplitEnd = null;
3316
+ if (features.length > 0 && features[0].cubics.length === 3) {
3317
+ const center = features[0].cubics[1];
3318
+ const [start, end] = center.split(0.5);
3319
+ firstFeatureSplitStart = [features[0].cubics[0], start];
3320
+ firstFeatureSplitEnd = [end, features[0].cubics[2]];
3321
+ }
3322
+ for (let i = 0; i <= features.length; i++) {
3323
+ let featureCubics;
3324
+ if (i === 0 && firstFeatureSplitEnd) {
3325
+ featureCubics = firstFeatureSplitEnd;
3326
+ } else if (i === features.length) {
3327
+ if (firstFeatureSplitStart) featureCubics = firstFeatureSplitStart;
3328
+ else break;
3329
+ } else {
3330
+ featureCubics = features[i].cubics;
3331
+ }
3332
+ for (const cubic of featureCubics) {
3333
+ if (!cubic.zeroLength()) {
3334
+ if (lastCubic) result.push(lastCubic);
3335
+ lastCubic = cubic;
3336
+ if (!firstCubic) firstCubic = cubic;
3337
+ } else if (lastCubic) {
3338
+ const p = lastCubic.points.slice();
3339
+ p[6] = cubic.anchor1X;
3340
+ p[7] = cubic.anchor1Y;
3341
+ lastCubic = new Cubic(p);
3342
+ }
3343
+ }
3344
+ }
3345
+ if (lastCubic && firstCubic) {
3346
+ result.push(
3347
+ new Cubic([
3348
+ lastCubic.anchor0X,
3349
+ lastCubic.anchor0Y,
3350
+ lastCubic.control0X,
3351
+ lastCubic.control0Y,
3352
+ lastCubic.control1X,
3353
+ lastCubic.control1Y,
3354
+ firstCubic.anchor0X,
3355
+ firstCubic.anchor0Y
3356
+ ])
3357
+ );
3358
+ } else {
3359
+ result.push(Cubic.empty(0, 0));
3360
+ }
3361
+ return result;
3362
+ }
3363
+ function validateContiguity(cubics) {
3364
+ let prev = cubics[cubics.length - 1];
3365
+ for (const cubic of cubics) {
3366
+ if (Math.abs(cubic.anchor0X - prev.anchor1X) > DISTANCE_EPSILON || Math.abs(cubic.anchor0Y - prev.anchor1Y) > DISTANCE_EPSILON) {
3367
+ throw new Error(
3368
+ `RoundedPolygon must be contiguous: gap between (${cubic.anchor0X},${cubic.anchor0Y}) and (${prev.anchor1X},${prev.anchor1Y})`
3369
+ );
3370
+ }
3371
+ prev = cubic;
3372
+ }
3373
+ }
3374
+
3375
+ // src/shapes/catalog/md3-expressive-shapes.ts
3376
+ function createShape(pts) {
3377
+ const cubics = pts.map((p) => new Cubic(p));
3378
+ return RoundedPolygon.fromFeatures(
3379
+ cubics.map((c) => cornerFeature([c], false))
3380
+ );
3381
+ }
3382
+ var archShape = createShape([
3383
+ [1, 0.83461, 1, 0.8547, 1, 0.86477, 0.99898, 0.87322],
3384
+ [0.99898, 0.87322, 0.99115, 0.93918, 0.93918, 0.99115, 0.87322, 0.99898],
3385
+ [0.87322, 0.99898, 0.86477, 1, 0.8547, 1, 0.83461, 1],
3386
+ [0.83461, 1, 0.61154, 1, 0.38847, 1, 0.1654, 1],
3387
+ [0.1654, 1, 0.14529, 1, 0.13524, 1, 0.12679, 0.99898],
3388
+ [0.12679, 0.99898, 0.06084, 0.99115, 884e-5, 0.93918, 1e-3, 0.87322],
3389
+ [1e-3, 0.87322, 0, 0.86477, 0, 0.8547, 0, 0.83461],
3390
+ [0, 0.83461, 0, 0.72307, 0, 0.61154, 0, 0.5],
3391
+ [0, 0.5, 0, 0.22385, 0.22386, 0, 0.5, 0],
3392
+ [0.5, 0, 0.77615, 0, 1, 0.22385, 1, 0.5],
3393
+ [1, 0.5, 1, 0.61154, 1, 0.72307, 1, 0.83461]
3394
+ ]);
3395
+ var arrowShape = createShape([
3396
+ [0.8594, 0.44684, 0.81504, 0.37855, 0.77068, 0.31016, 0.72632, 0.24187],
3397
+ [0.72632, 0.24187, 0.69754, 0.19753, 0.66825, 0.1526, 0.62934, 0.11738],
3398
+ [0.62934, 0.11738, 0.59043, 0.08209, 0.54003, 0.05716, 0.48834, 0.06041],
3399
+ [0.48834, 0.06041, 0.44296, 0.06333, 0.4009, 0.08773, 0.36769, 0.11959],
3400
+ [0.36769, 0.11959, 0.33449, 0.15146, 0.30869, 0.1907, 0.28332, 0.22956],
3401
+ [0.28332, 0.22956, 0.21469, 0.33456, 0.14598, 0.43956, 0.07736, 0.54462],
3402
+ [0.07736, 0.54462, 0.04474, 0.5945, 0.01128, 0.64655, 226e-5, 0.70598],
3403
+ [226e-5, 0.70598, -864e-5, 0.77779, 0.02074, 0.85092, 0.07284, 0.89867],
3404
+ [0.07284, 0.89867, 0.12733, 0.94861, 0.21563, 0.94456, 0.28196, 0.93089],
3405
+ [0.28196, 0.93089, 0.35467, 0.91586, 0.42576, 0.8876, 0.49992, 0.88769],
3406
+ [0.49992, 0.88769, 0.56344, 0.88769, 0.62483, 0.90858, 0.68664, 0.92377],
3407
+ [0.68664, 0.92377, 0.74837, 0.93886, 0.8147, 0.94817, 0.8743, 0.9257],
3408
+ [0.8743, 0.9257, 0.94829, 0.89788, 1.00142, 0.81877, 0.99997, 0.73757],
3409
+ [0.99997, 0.73757, 0.99861, 0.66348, 0.95714, 0.59731, 0.91721, 0.53567],
3410
+ [0.91721, 0.53567, 0.89797, 0.50608, 0.87873, 0.47643, 0.85948, 0.44684],
3411
+ [0.85948, 0.44684, 0.85946, 0.44684, 0.85943, 0.44684, 0.8594, 0.44684]
3412
+ ]);
3413
+ var boomShape = createShape([
3414
+ [0.49006, 0.03176, 0.49241, 0.01294, 0.49359, 354e-5, 0.49537, 185e-5],
3415
+ [0.49537, 185e-5, 0.49796, -62e-5, 0.50203, -62e-5, 0.50462, 185e-5],
3416
+ [0.50462, 185e-5, 0.50641, 354e-5, 0.50759, 0.01294, 0.50994, 0.03176],
3417
+ [0.50994, 0.03176, 0.51992, 0.11153, 0.5299, 0.1913, 0.53987, 0.27107],
3418
+ [0.53987, 0.27107, 0.54082, 0.27866, 0.5413, 0.28244, 0.54266, 0.28403],
3419
+ [0.54266, 0.28403, 0.54464, 0.28628, 0.54787, 0.287, 0.5506, 0.28572],
3420
+ [0.5506, 0.28572, 0.55248, 0.28485, 0.55445, 0.28157, 0.55839, 0.275],
3421
+ [0.55839, 0.275, 0.59978, 0.20621, 0.64116, 0.13742, 0.68254, 0.06863],
3422
+ [0.68254, 0.06863, 0.69231, 0.05241, 0.69719, 0.04429, 0.6995, 0.04348],
3423
+ [0.6995, 0.04348, 0.70287, 0.04232, 0.70657, 0.04398, 0.70795, 0.04729],
3424
+ [0.70795, 0.04729, 0.70891, 0.04954, 0.70617, 0.05863, 0.70071, 0.07679],
3425
+ [0.70071, 0.07679, 0.67756, 0.15373, 0.6544, 0.23068, 0.63124, 0.30763],
3426
+ [0.63124, 0.30763, 0.62904, 0.31497, 0.62794, 0.31863, 0.62855, 0.3206],
3427
+ [0.62855, 0.3206, 0.62942, 0.32348, 0.6321, 0.32544, 0.63512, 0.32541],
3428
+ [0.63512, 0.32541, 0.63719, 0.32538, 0.64031, 0.32319, 0.64656, 0.31882],
3429
+ [0.64656, 0.31882, 0.7122, 0.2729, 0.77783, 0.22698, 0.84347, 0.18107],
3430
+ [0.84347, 0.18107, 0.85895, 0.17022, 0.86669, 0.16482, 0.86913, 0.16501],
3431
+ [0.86913, 0.16501, 0.87269, 0.16533, 0.87539, 0.16834, 0.87532, 0.17191],
3432
+ [0.87532, 0.17191, 0.87528, 0.17438, 0.86911, 0.18157, 0.85678, 0.19591],
3433
+ [0.85678, 0.19591, 0.80449, 0.25674, 0.75221, 0.31758, 0.69992, 0.37841],
3434
+ [0.69992, 0.37841, 0.69494, 0.38419, 0.69246, 0.3871, 0.69221, 0.38916],
3435
+ [0.69221, 0.38916, 0.69185, 0.39216, 0.6935, 0.39503, 0.69627, 0.39622],
3436
+ [0.69627, 0.39622, 0.69817, 0.39706, 0.70191, 0.39631, 0.70939, 0.39488],
3437
+ [0.70939, 0.39488, 0.78793, 0.37977, 0.86646, 0.36467, 0.945, 0.34957],
3438
+ [0.945, 0.34957, 0.96353, 0.346, 0.9728, 0.34422, 0.97494, 0.34541],
3439
+ [0.97494, 0.34541, 0.97806, 0.34713, 0.97931, 0.351, 0.9778, 0.35425],
3440
+ [0.9778, 0.35425, 0.97676, 0.35647, 0.96822, 0.3605, 0.95115, 0.36856],
3441
+ [0.95115, 0.36856, 0.87878, 0.40276, 0.80641, 0.43696, 0.73403, 0.47116],
3442
+ [0.73403, 0.47116, 0.72714, 0.47441, 0.7237, 0.47603, 0.72263, 0.47781],
3443
+ [0.72263, 0.47781, 0.72109, 0.48041, 0.72144, 0.48372, 0.72348, 0.48594],
3444
+ [0.72348, 0.48594, 0.72489, 0.48747, 0.7286, 0.48834, 0.73601, 0.49006],
3445
+ [0.73601, 0.49006, 0.81387, 0.50839, 0.89173, 0.52671, 0.96959, 0.54503],
3446
+ [0.96959, 0.54503, 0.98796, 0.54934, 0.99715, 0.5515, 0.99862, 0.55347],
3447
+ [0.99862, 0.55347, 1.00077, 0.55631, 1.00035, 0.56037, 0.99766, 0.56272],
3448
+ [0.99766, 0.56272, 0.9958, 0.56431, 0.98638, 0.56453, 0.96751, 0.56491],
3449
+ [0.96751, 0.56491, 0.88757, 0.56654, 0.80762, 0.56818, 0.72767, 0.56981],
3450
+ [0.72767, 0.56981, 0.72006, 0.56997, 0.71626, 0.57006, 0.71456, 0.57125],
3451
+ [0.71456, 0.57125, 0.7121, 0.573, 0.71108, 0.57617, 0.71206, 0.57903],
3452
+ [0.71206, 0.57903, 0.71272, 0.581, 0.71576, 0.58331, 0.72182, 0.58794],
3453
+ [0.72182, 0.58794, 0.78555, 0.6365, 0.84927, 0.68506, 0.91299, 0.73362],
3454
+ [0.91299, 0.73362, 0.92802, 0.74509, 0.93554, 0.75084, 0.93609, 0.75322],
3455
+ [0.93609, 0.75322, 0.93691, 0.7567, 0.93489, 0.76022, 0.93147, 0.76128],
3456
+ [0.93147, 0.76128, 0.92912, 0.762, 0.92043, 0.75831, 0.90304, 0.75097],
3457
+ [0.90304, 0.75097, 0.82934, 0.71977, 0.75565, 0.68857, 0.68195, 0.65737],
3458
+ [0.68195, 0.65737, 0.67493, 0.6544, 0.67142, 0.6529, 0.66939, 0.65331],
3459
+ [0.66939, 0.65331, 0.66644, 0.65391, 0.66423, 0.65637, 0.66396, 0.65937],
3460
+ [0.66396, 0.65937, 0.66378, 0.66144, 0.66561, 0.66481, 0.66928, 0.6715],
3461
+ [0.66928, 0.6715, 0.70784, 0.74193, 0.74641, 0.81237, 0.78497, 0.88281],
3462
+ [0.78497, 0.88281, 0.79407, 0.8994, 0.79862, 0.90771, 0.79815, 0.91015],
3463
+ [0.79815, 0.91015, 0.79748, 0.91366, 0.79421, 0.91604, 0.79067, 0.91562],
3464
+ [0.79067, 0.91562, 0.78824, 0.91531, 0.78179, 0.9084, 0.76888, 0.89456],
3465
+ [0.76888, 0.89456, 0.71418, 0.83591, 0.65947, 0.77727, 0.60477, 0.71862],
3466
+ [0.60477, 0.71862, 0.59956, 0.71306, 0.59695, 0.71025, 0.59494, 0.70981],
3467
+ [0.59494, 0.70981, 0.592, 0.70912, 0.58897, 0.71048, 0.58752, 0.71312],
3468
+ [0.58752, 0.71312, 0.58651, 0.71493, 0.58683, 0.71875, 0.58747, 0.72637],
3469
+ [0.58747, 0.72637, 0.59421, 0.80649, 0.60094, 0.8866, 0.60768, 0.96671],
3470
+ [0.60768, 0.96671, 0.60927, 0.98562, 0.61006, 0.99506, 0.60866, 0.99709],
3471
+ [0.60866, 0.99709, 0.60663, 1.00002, 0.60267, 1.00087, 0.59962, 0.99902],
3472
+ [0.59962, 0.99902, 0.59752, 0.99774, 0.59442, 0.98877, 0.58823, 0.97087],
3473
+ [0.58823, 0.97087, 0.56197, 0.89493, 0.53572, 0.819, 0.50946, 0.74306],
3474
+ [0.50946, 0.74306, 0.50696, 0.73581, 0.50571, 0.73222, 0.50406, 0.73097],
3475
+ [0.50406, 0.73097, 0.50165, 0.72916, 0.49834, 0.72916, 0.49594, 0.73097],
3476
+ [0.49594, 0.73097, 0.49428, 0.73222, 0.49303, 0.73581, 0.49053, 0.74306],
3477
+ [0.49053, 0.74306, 0.46428, 0.819, 0.43803, 0.89493, 0.41177, 0.97087],
3478
+ [0.41177, 0.97087, 0.40558, 0.98877, 0.40248, 0.99774, 0.40038, 0.99902],
3479
+ [0.40038, 0.99902, 0.39733, 1.00087, 0.39338, 1.00002, 0.39134, 0.99709],
3480
+ [0.39134, 0.99709, 0.38994, 0.99506, 0.39073, 0.98562, 0.39232, 0.96671],
3481
+ [0.39232, 0.96671, 0.39906, 0.8866, 0.40579, 0.80649, 0.41253, 0.72637],
3482
+ [0.41253, 0.72637, 0.41317, 0.71875, 0.41349, 0.71493, 0.41248, 0.71312],
3483
+ [0.41248, 0.71312, 0.41104, 0.71048, 0.408, 0.70912, 0.40507, 0.70981],
3484
+ [0.40507, 0.70981, 0.40305, 0.71025, 0.40044, 0.71306, 0.39523, 0.71862],
3485
+ [0.39523, 0.71862, 0.34053, 0.77727, 0.28582, 0.83591, 0.23112, 0.89456],
3486
+ [0.23112, 0.89456, 0.21821, 0.9084, 0.21176, 0.91531, 0.20933, 0.91562],
3487
+ [0.20933, 0.91562, 0.20578, 0.91604, 0.20252, 0.91366, 0.20184, 0.91015],
3488
+ [0.20184, 0.91015, 0.20138, 0.90771, 0.20593, 0.8994, 0.21503, 0.88281],
3489
+ [0.21503, 0.88281, 0.25359, 0.81237, 0.29215, 0.74193, 0.33072, 0.6715],
3490
+ [0.33072, 0.6715, 0.33439, 0.66481, 0.33622, 0.66144, 0.33604, 0.65937],
3491
+ [0.33604, 0.65937, 0.33577, 0.65637, 0.33356, 0.65391, 0.3306, 0.65331],
3492
+ [0.3306, 0.65331, 0.32857, 0.6529, 0.32506, 0.6544, 0.31805, 0.65737],
3493
+ [0.31805, 0.65737, 0.24435, 0.68857, 0.17065, 0.71977, 0.09695, 0.75097],
3494
+ [0.09695, 0.75097, 0.07957, 0.75831, 0.07087, 0.762, 0.06853, 0.76128],
3495
+ [0.06853, 0.76128, 0.06511, 0.76022, 0.06309, 0.7567, 0.06391, 0.75322],
3496
+ [0.06391, 0.75322, 0.06446, 0.75084, 0.07198, 0.74509, 0.08701, 0.73362],
3497
+ [0.08701, 0.73362, 0.15073, 0.68506, 0.21445, 0.6365, 0.27817, 0.58794],
3498
+ [0.27817, 0.58794, 0.28424, 0.58331, 0.28727, 0.581, 0.28794, 0.57903],
3499
+ [0.28794, 0.57903, 0.28892, 0.57617, 0.2879, 0.573, 0.28543, 0.57125],
3500
+ [0.28543, 0.57125, 0.28374, 0.57006, 0.27993, 0.56997, 0.27232, 0.56981],
3501
+ [0.27232, 0.56981, 0.19238, 0.56818, 0.11243, 0.56654, 0.03248, 0.56491],
3502
+ [0.03248, 0.56491, 0.01362, 0.56453, 419e-5, 0.56431, 234e-5, 0.56272],
3503
+ [234e-5, 0.56272, -35e-5, 0.56036, -77e-5, 0.55633, 138e-5, 0.55347],
3504
+ [138e-5, 0.55347, 285e-5, 0.5515, 0.01204, 0.54934, 0.03041, 0.54503],
3505
+ [0.03041, 0.54503, 0.10827, 0.52671, 0.18613, 0.50839, 0.26399, 0.49006],
3506
+ [0.26399, 0.49006, 0.2714, 0.48834, 0.27511, 0.48747, 0.27652, 0.48594],
3507
+ [0.27652, 0.48594, 0.27856, 0.48372, 0.27891, 0.48041, 0.27736, 0.47781],
3508
+ [0.27736, 0.47781, 0.2763, 0.47603, 0.27286, 0.47441, 0.26597, 0.47116],
3509
+ [0.26597, 0.47116, 0.19359, 0.43696, 0.12122, 0.40276, 0.04885, 0.36856],
3510
+ [0.04885, 0.36856, 0.03177, 0.3605, 0.02324, 0.35647, 0.0222, 0.35425],
3511
+ [0.0222, 0.35425, 0.02068, 0.35101, 0.02193, 0.34715, 0.02506, 0.34541],
3512
+ [0.02506, 0.34541, 0.0272, 0.34422, 0.03647, 0.346, 0.055, 0.34957],
3513
+ [0.055, 0.34957, 0.13353, 0.36467, 0.21207, 0.37977, 0.29061, 0.39488],
3514
+ [0.29061, 0.39488, 0.29809, 0.39631, 0.30183, 0.39706, 0.30373, 0.39622],
3515
+ [0.30373, 0.39622, 0.3065, 0.39502, 0.30815, 0.39215, 0.30779, 0.38916],
3516
+ [0.30779, 0.38916, 0.30755, 0.3871, 0.30506, 0.38419, 0.30008, 0.37841],
3517
+ [0.30008, 0.37841, 0.24779, 0.31758, 0.19551, 0.25674, 0.14322, 0.19591],
3518
+ [0.14322, 0.19591, 0.13089, 0.18157, 0.12472, 0.17438, 0.12468, 0.17191],
3519
+ [0.12468, 0.17191, 0.12461, 0.16834, 0.12731, 0.16533, 0.13086, 0.16501],
3520
+ [0.13086, 0.16501, 0.1333, 0.16482, 0.14104, 0.17022, 0.15653, 0.18107],
3521
+ [0.15653, 0.18107, 0.22217, 0.22698, 0.2878, 0.2729, 0.35344, 0.31882],
3522
+ [0.35344, 0.31882, 0.35969, 0.32319, 0.36281, 0.32538, 0.36488, 0.32541],
3523
+ [0.36488, 0.32541, 0.3679, 0.32544, 0.37058, 0.32348, 0.37145, 0.3206],
3524
+ [0.37145, 0.3206, 0.37206, 0.31863, 0.37096, 0.31497, 0.36875, 0.30763],
3525
+ [0.36875, 0.30763, 0.3456, 0.23068, 0.32244, 0.15373, 0.29929, 0.07679],
3526
+ [0.29929, 0.07679, 0.29382, 0.05863, 0.29109, 0.04954, 0.29205, 0.04729],
3527
+ [0.29205, 0.04729, 0.29342, 0.04399, 0.29711, 0.04232, 0.3005, 0.04348],
3528
+ [0.3005, 0.04348, 0.30281, 0.04429, 0.30769, 0.05241, 0.31745, 0.06863],
3529
+ [0.31745, 0.06863, 0.35884, 0.13742, 0.40022, 0.20621, 0.44161, 0.275],
3530
+ [0.44161, 0.275, 0.44555, 0.28157, 0.44752, 0.28485, 0.4494, 0.28572],
3531
+ [0.4494, 0.28572, 0.45212, 0.287, 0.45536, 0.28628, 0.45734, 0.28403],
3532
+ [0.45734, 0.28403, 0.4587, 0.28244, 0.45917, 0.27866, 0.46012, 0.27107],
3533
+ [0.46012, 0.27107, 0.4701, 0.1913, 0.48008, 0.11153, 0.49006, 0.03176]
3534
+ ]);
3535
+ var bunShape = createShape([
3536
+ [0.01546, 0.25425, 0.01545, 0.18682, 0.04224, 0.12214, 0.08992, 0.07446],
3537
+ [0.08992, 0.07446, 0.1376, 0.02678, 0.20228, -1e-5, 0.26971, 0],
3538
+ [0.26971, 0, 0.42313, 0, 0.57654, 0, 0.72996, 0],
3539
+ [0.72996, 0, 0.85665, -17e-5, 0.96413, 0.09297, 0.98198, 0.2184],
3540
+ [0.98198, 0.2184, 0.99983, 0.34383, 0.92261, 0.46325, 0.8009, 0.49844],
3541
+ [0.8009, 0.49844, 0.8002, 0.49863, 0.79972, 0.49927, 0.79974, 0.5],
3542
+ [0.79974, 0.5, 0.79974, 0.50072, 0.80021, 0.50134, 0.8009, 0.50156],
3543
+ [0.8009, 0.50156, 0.92232, 0.537, 0.99924, 0.65629, 0.98142, 0.78152],
3544
+ [0.98142, 0.78152, 0.96359, 0.90675, 0.85645, 0.99984, 0.72996, 1],
3545
+ [0.72996, 1, 0.57654, 1, 0.42313, 1, 0.26971, 1],
3546
+ [0.26971, 1, 0.20228, 1.00001, 0.1376, 0.97322, 0.08992, 0.92554],
3547
+ [0.08992, 0.92554, 0.04224, 0.87786, 0.01545, 0.81318, 0.01546, 0.74575],
3548
+ [0.01546, 0.74575, 0.01548, 0.63344, 0.08915, 0.53444, 0.19671, 0.50216],
3549
+ [0.19671, 0.50216, 0.19766, 0.50187, 0.19832, 0.501, 0.19832, 0.5],
3550
+ [0.19832, 0.5, 0.19832, 0.49901, 0.19766, 0.49813, 0.19671, 0.49784],
3551
+ [0.19671, 0.49784, 0.08915, 0.46556, 0.01548, 0.36656, 0.01546, 0.25425]
3552
+ ]);
3553
+ var burstShape = createShape([
3554
+ [0.49184, 797e-5, 0.49416, 384e-5, 0.49528, 181e-5, 0.49669, 94e-5],
3555
+ [0.49669, 94e-5, 0.49872, -31e-5, 0.50128, -31e-5, 0.50331, 94e-5],
3556
+ [0.50331, 94e-5, 0.50472, 181e-5, 0.50584, 384e-5, 0.50816, 797e-5],
3557
+ [0.50816, 797e-5, 0.53447, 0.055, 0.56078, 0.10203, 0.58709, 0.14906],
3558
+ [0.58709, 0.14906, 0.5885, 0.15159, 0.58922, 0.15287, 0.59019, 0.15362],
3559
+ [0.59019, 0.15362, 0.59156, 0.15475, 0.59334, 0.15522, 0.59509, 0.15494],
3560
+ [0.59509, 0.15494, 0.59631, 0.15475, 0.59756, 0.15403, 0.60003, 0.15253],
3561
+ [0.60003, 0.15253, 0.64634, 0.12496, 0.69266, 0.09739, 0.73897, 0.06981],
3562
+ [0.73897, 0.06981, 0.743, 0.06741, 0.74503, 0.06619, 0.74666, 0.06616],
3563
+ [0.74666, 0.06616, 0.74906, 0.06606, 0.75125, 0.06734, 0.75241, 0.06944],
3564
+ [0.75241, 0.06944, 0.75319, 0.07091, 0.75316, 0.07325, 0.75309, 0.07797],
3565
+ [0.75309, 0.07797, 0.75236, 0.13185, 0.75164, 0.18574, 0.75091, 0.23962],
3566
+ [0.75091, 0.23962, 0.75084, 0.24253, 0.75084, 0.24397, 0.75128, 0.24512],
3567
+ [0.75128, 0.24512, 0.75191, 0.24678, 0.75322, 0.24809, 0.75488, 0.24872],
3568
+ [0.75488, 0.24872, 0.75603, 0.24916, 0.75747, 0.24916, 0.76038, 0.24909],
3569
+ [0.76038, 0.24909, 0.81426, 0.24836, 0.86815, 0.24764, 0.92203, 0.24691],
3570
+ [0.92203, 0.24691, 0.92675, 0.24684, 0.92909, 0.24681, 0.93056, 0.24759],
3571
+ [0.93056, 0.24759, 0.93266, 0.24875, 0.93394, 0.25094, 0.93384, 0.25334],
3572
+ [0.93384, 0.25334, 0.93381, 0.25497, 0.93259, 0.257, 0.93019, 0.26103],
3573
+ [0.93019, 0.26103, 0.90261, 0.30734, 0.87504, 0.35366, 0.84747, 0.39997],
3574
+ [0.84747, 0.39997, 0.84597, 0.40244, 0.84525, 0.40369, 0.84506, 0.40491],
3575
+ [0.84506, 0.40491, 0.84478, 0.40666, 0.84525, 0.40844, 0.84638, 0.40981],
3576
+ [0.84638, 0.40981, 0.84713, 0.41078, 0.84841, 0.4115, 0.85094, 0.41291],
3577
+ [0.85094, 0.41291, 0.89797, 0.43922, 0.945, 0.46553, 0.99203, 0.49184],
3578
+ [0.99203, 0.49184, 0.99616, 0.49416, 0.99819, 0.49528, 0.99906, 0.49669],
3579
+ [0.99906, 0.49669, 1.00031, 0.49872, 1.00031, 0.50128, 0.99906, 0.50331],
3580
+ [0.99906, 0.50331, 0.99819, 0.50472, 0.99616, 0.50584, 0.99203, 0.50816],
3581
+ [0.99203, 0.50816, 0.945, 0.53447, 0.89797, 0.56078, 0.85094, 0.58709],
3582
+ [0.85094, 0.58709, 0.84841, 0.5885, 0.84713, 0.58922, 0.84638, 0.59019],
3583
+ [0.84638, 0.59019, 0.84525, 0.59156, 0.84478, 0.59334, 0.84506, 0.59509],
3584
+ [0.84506, 0.59509, 0.84525, 0.59631, 0.84597, 0.59756, 0.84747, 0.60003],
3585
+ [0.84747, 0.60003, 0.87504, 0.64634, 0.90261, 0.69266, 0.93019, 0.73897],
3586
+ [0.93019, 0.73897, 0.93259, 0.743, 0.93381, 0.74503, 0.93384, 0.74666],
3587
+ [0.93384, 0.74666, 0.93394, 0.74906, 0.93266, 0.75125, 0.93056, 0.75241],
3588
+ [0.93056, 0.75241, 0.92909, 0.75319, 0.92675, 0.75316, 0.92203, 0.75309],
3589
+ [0.92203, 0.75309, 0.86815, 0.75236, 0.81426, 0.75164, 0.76038, 0.75091],
3590
+ [0.76038, 0.75091, 0.75747, 0.75084, 0.75603, 0.75084, 0.75488, 0.75128],
3591
+ [0.75488, 0.75128, 0.75322, 0.75191, 0.75191, 0.75322, 0.75128, 0.75488],
3592
+ [0.75128, 0.75488, 0.75084, 0.75603, 0.75084, 0.75747, 0.75091, 0.76038],
3593
+ [0.75091, 0.76038, 0.75164, 0.81426, 0.75236, 0.86815, 0.75309, 0.92203],
3594
+ [0.75309, 0.92203, 0.75316, 0.92675, 0.75319, 0.92909, 0.75241, 0.93056],
3595
+ [0.75241, 0.93056, 0.75125, 0.93266, 0.74906, 0.93394, 0.74666, 0.93384],
3596
+ [0.74666, 0.93384, 0.74503, 0.93381, 0.743, 0.93259, 0.73897, 0.93019],
3597
+ [0.73897, 0.93019, 0.69266, 0.90261, 0.64634, 0.87504, 0.60003, 0.84747],
3598
+ [0.60003, 0.84747, 0.59756, 0.84597, 0.59631, 0.84525, 0.59509, 0.84506],
3599
+ [0.59509, 0.84506, 0.59334, 0.84478, 0.59156, 0.84525, 0.59019, 0.84638],
3600
+ [0.59019, 0.84638, 0.58922, 0.84713, 0.5885, 0.84841, 0.58709, 0.85094],
3601
+ [0.58709, 0.85094, 0.56078, 0.89797, 0.53447, 0.945, 0.50816, 0.99203],
3602
+ [0.50816, 0.99203, 0.50584, 0.99616, 0.50472, 0.99819, 0.50331, 0.99906],
3603
+ [0.50331, 0.99906, 0.50128, 1.00031, 0.49872, 1.00031, 0.49669, 0.99906],
3604
+ [0.49669, 0.99906, 0.49528, 0.99819, 0.49416, 0.99616, 0.49184, 0.99203],
3605
+ [0.49184, 0.99203, 0.46553, 0.945, 0.43922, 0.89797, 0.41291, 0.85094],
3606
+ [0.41291, 0.85094, 0.4115, 0.84841, 0.41078, 0.84713, 0.40981, 0.84638],
3607
+ [0.40981, 0.84638, 0.40844, 0.84525, 0.40666, 0.84478, 0.40491, 0.84506],
3608
+ [0.40491, 0.84506, 0.40369, 0.84525, 0.40244, 0.84597, 0.39997, 0.84747],
3609
+ [0.39997, 0.84747, 0.35366, 0.87504, 0.30734, 0.90261, 0.26103, 0.93019],
3610
+ [0.26103, 0.93019, 0.257, 0.93259, 0.25497, 0.93381, 0.25334, 0.93384],
3611
+ [0.25334, 0.93384, 0.25094, 0.93394, 0.24875, 0.93266, 0.24759, 0.93056],
3612
+ [0.24759, 0.93056, 0.24681, 0.92909, 0.24684, 0.92675, 0.24691, 0.92203],
3613
+ [0.24691, 0.92203, 0.24764, 0.86815, 0.24836, 0.81426, 0.24909, 0.76038],
3614
+ [0.24909, 0.76038, 0.24916, 0.75747, 0.24916, 0.75603, 0.24872, 0.75488],
3615
+ [0.24872, 0.75488, 0.24809, 0.75322, 0.24678, 0.75191, 0.24513, 0.75128],
3616
+ [0.24513, 0.75128, 0.24397, 0.75084, 0.24253, 0.75084, 0.23963, 0.75091],
3617
+ [0.23963, 0.75091, 0.18574, 0.75164, 0.13185, 0.75236, 0.07797, 0.75309],
3618
+ [0.07797, 0.75309, 0.07325, 0.75316, 0.07091, 0.75319, 0.06944, 0.75241],
3619
+ [0.06944, 0.75241, 0.06734, 0.75127, 0.06607, 0.74904, 0.06616, 0.74666],
3620
+ [0.06616, 0.74666, 0.06619, 0.74503, 0.06741, 0.743, 0.06981, 0.73897],
3621
+ [0.06981, 0.73897, 0.09739, 0.69266, 0.12496, 0.64634, 0.15253, 0.60003],
3622
+ [0.15253, 0.60003, 0.15403, 0.59756, 0.15475, 0.59631, 0.15494, 0.59509],
3623
+ [0.15494, 0.59509, 0.15522, 0.59334, 0.15475, 0.59156, 0.15363, 0.59019],
3624
+ [0.15363, 0.59019, 0.15288, 0.58922, 0.15159, 0.5885, 0.14906, 0.58709],
3625
+ [0.14906, 0.58709, 0.10203, 0.56078, 0.055, 0.53447, 797e-5, 0.50816],
3626
+ [797e-5, 0.50816, 384e-5, 0.50584, 181e-5, 0.50472, 94e-5, 0.50331],
3627
+ [94e-5, 0.50331, -31e-5, 0.50128, -31e-5, 0.49872, 94e-5, 0.49669],
3628
+ [94e-5, 0.49669, 181e-5, 0.49528, 384e-5, 0.49416, 797e-5, 0.49184],
3629
+ [797e-5, 0.49184, 0.055, 0.46553, 0.10203, 0.43922, 0.14906, 0.41291],
3630
+ [0.14906, 0.41291, 0.15159, 0.4115, 0.15287, 0.41078, 0.15362, 0.40981],
3631
+ [0.15362, 0.40981, 0.15475, 0.40844, 0.15522, 0.40666, 0.15494, 0.40491],
3632
+ [0.15494, 0.40491, 0.15475, 0.40369, 0.15403, 0.40244, 0.15253, 0.39997],
3633
+ [0.15253, 0.39997, 0.12496, 0.35366, 0.09739, 0.30734, 0.06981, 0.26103],
3634
+ [0.06981, 0.26103, 0.06741, 0.257, 0.06619, 0.25497, 0.06616, 0.25334],
3635
+ [0.06616, 0.25334, 0.06606, 0.25094, 0.06734, 0.24875, 0.06944, 0.24759],
3636
+ [0.06944, 0.24759, 0.07091, 0.24681, 0.07325, 0.24684, 0.07797, 0.24691],
3637
+ [0.07797, 0.24691, 0.13185, 0.24764, 0.18574, 0.24836, 0.23963, 0.24909],
3638
+ [0.23963, 0.24909, 0.24253, 0.24916, 0.24397, 0.24916, 0.24513, 0.24872],
3639
+ [0.24513, 0.24872, 0.24678, 0.24809, 0.24809, 0.24678, 0.24872, 0.24512],
3640
+ [0.24872, 0.24512, 0.24916, 0.24397, 0.24916, 0.24253, 0.24909, 0.23962],
3641
+ [0.24909, 0.23962, 0.24836, 0.18574, 0.24764, 0.13185, 0.24691, 0.07797],
3642
+ [0.24691, 0.07797, 0.24684, 0.07325, 0.24681, 0.07091, 0.24759, 0.06944],
3643
+ [0.24759, 0.06944, 0.24875, 0.06734, 0.25094, 0.06606, 0.25334, 0.06616],
3644
+ [0.25334, 0.06616, 0.25497, 0.06619, 0.257, 0.06741, 0.26103, 0.06981],
3645
+ [0.26103, 0.06981, 0.30734, 0.09739, 0.35366, 0.12496, 0.39997, 0.15253],
3646
+ [0.39997, 0.15253, 0.40244, 0.15403, 0.40369, 0.15475, 0.40491, 0.15494],
3647
+ [0.40491, 0.15494, 0.40666, 0.15522, 0.40844, 0.15475, 0.40981, 0.15362],
3648
+ [0.40981, 0.15362, 0.41078, 0.15287, 0.4115, 0.15159, 0.41291, 0.14906],
3649
+ [0.41291, 0.14906, 0.43922, 0.10203, 0.46553, 0.055, 0.49184, 797e-5]
3650
+ ]);
3651
+ var circleShape = createShape([
3652
+ [1, 0.5, 1, 0.77614, 0.77614, 1, 0.5, 1],
3653
+ [0.5, 1, 0.22386, 1, 0, 0.77614, 0, 0.5],
3654
+ [0, 0.5, 0, 0.22386, 0.22386, 0, 0.5, 0],
3655
+ [0.5, 0, 0.77614, 0, 1, 0.22386, 1, 0.5]
3656
+ ]);
3657
+ var clamshellShape = createShape([
3658
+ [0.95752, 0.36588, 0.97848, 0.4081, 0.98896, 0.42921, 0.99426, 0.45126],
3659
+ [0.99426, 0.45126, 1.00191, 0.4833, 1.00191, 0.5167, 0.99426, 0.54874],
3660
+ [0.99426, 0.54874, 0.98896, 0.57079, 0.97848, 0.5919, 0.95752, 0.63412],
3661
+ [0.95752, 0.63412, 0.93623, 0.677, 0.91494, 0.71987, 0.89365, 0.76275],
3662
+ [0.89365, 0.76275, 0.87268, 0.80497, 0.8622, 0.82608, 0.84842, 0.84244],
3663
+ [0.84842, 0.84244, 0.8285, 0.86609, 0.80339, 0.88295, 0.77581, 0.89118],
3664
+ [0.77581, 0.89118, 0.75673, 0.89688, 0.73577, 0.89688, 0.69384, 0.89688],
3665
+ [0.69384, 0.89688, 0.56461, 0.89688, 0.43539, 0.89688, 0.30616, 0.89688],
3666
+ [0.30616, 0.89688, 0.26423, 0.89688, 0.24327, 0.89688, 0.22419, 0.89118],
3667
+ [0.22419, 0.89118, 0.19661, 0.88295, 0.1715, 0.86609, 0.15158, 0.84244],
3668
+ [0.15158, 0.84244, 0.1378, 0.82608, 0.12732, 0.80497, 0.10635, 0.76275],
3669
+ [0.10635, 0.76275, 0.08506, 0.71987, 0.06377, 0.677, 0.04248, 0.63412],
3670
+ [0.04248, 0.63412, 0.02152, 0.5919, 0.01104, 0.57079, 574e-5, 0.54874],
3671
+ [574e-5, 0.54874, -191e-5, 0.5167, -191e-5, 0.4833, 574e-5, 0.45126],
3672
+ [574e-5, 0.45126, 0.01104, 0.42921, 0.02152, 0.4081, 0.04248, 0.36588],
3673
+ [0.04248, 0.36588, 0.06377, 0.323, 0.08506, 0.28013, 0.10635, 0.23725],
3674
+ [0.10635, 0.23725, 0.12732, 0.19503, 0.1378, 0.17392, 0.15158, 0.15756],
3675
+ [0.15158, 0.15756, 0.1715, 0.13391, 0.19661, 0.11705, 0.22419, 0.10882],
3676
+ [0.22419, 0.10882, 0.24327, 0.10312, 0.26423, 0.10312, 0.30616, 0.10312],
3677
+ [0.30616, 0.10312, 0.43539, 0.10312, 0.56461, 0.10312, 0.69384, 0.10312],
3678
+ [0.69384, 0.10312, 0.73577, 0.10312, 0.75673, 0.10312, 0.77581, 0.10882],
3679
+ [0.77581, 0.10882, 0.80339, 0.11705, 0.8285, 0.13391, 0.84842, 0.15756],
3680
+ [0.84842, 0.15756, 0.8622, 0.17392, 0.87268, 0.19503, 0.89365, 0.23725],
3681
+ [0.89365, 0.23725, 0.91494, 0.28013, 0.93623, 0.323, 0.95752, 0.36588]
3682
+ ]);
3683
+ var diamondShape = createShape([
3684
+ [0.67951, 0.864, 0.62689, 0.93286, 0.60059, 0.96728, 0.57021, 0.98296],
3685
+ [0.57021, 0.98296, 0.52616, 1.00568, 0.47384, 1.00568, 0.42979, 0.98296],
3686
+ [0.42979, 0.98296, 0.39941, 0.96728, 0.37311, 0.93286, 0.32049, 0.864],
3687
+ [0.32049, 0.864, 0.26225, 0.78778, 0.20401, 0.71156, 0.14577, 0.63534],
3688
+ [0.14577, 0.63534, 0.11377, 0.59346, 0.09777, 0.57252, 0.08984, 0.5501],
3689
+ [0.08984, 0.5501, 0.07838, 0.51768, 0.07838, 0.48232, 0.08984, 0.4499],
3690
+ [0.08984, 0.4499, 0.09777, 0.42748, 0.11377, 0.40654, 0.14577, 0.36466],
3691
+ [0.14577, 0.36466, 0.20401, 0.28844, 0.26225, 0.21222, 0.32049, 0.136],
3692
+ [0.32049, 0.136, 0.37311, 0.06714, 0.39941, 0.03271, 0.42979, 0.01704],
3693
+ [0.42979, 0.01704, 0.47384, -568e-5, 0.52616, -568e-5, 0.57021, 0.01704],
3694
+ [0.57021, 0.01704, 0.60059, 0.03272, 0.62689, 0.06714, 0.67951, 0.136],
3695
+ [0.67951, 0.136, 0.73775, 0.21222, 0.79599, 0.28844, 0.85423, 0.36466],
3696
+ [0.85423, 0.36466, 0.88623, 0.40654, 0.90223, 0.42748, 0.91016, 0.4499],
3697
+ [0.91016, 0.4499, 0.92162, 0.48232, 0.92162, 0.51768, 0.91016, 0.5501],
3698
+ [0.91016, 0.5501, 0.90223, 0.57252, 0.88623, 0.59346, 0.85423, 0.63534],
3699
+ [0.85423, 0.63534, 0.79599, 0.71156, 0.73775, 0.78778, 0.67951, 0.864]
3700
+ ]);
3701
+ var fanShape = createShape([
3702
+ [0, 0.15789, 0, 0.15232, 0, 0.14954, 7e-5, 0.14718],
3703
+ [7e-5, 0.14718, 256e-5, 0.06699, 0.06699, 256e-5, 0.14718, 8e-5],
3704
+ [0.14718, 8e-5, 0.14954, 0, 0.15232, 0, 0.1579, 0],
3705
+ [0.1579, 0, 0.18761, 0, 0.20246, 0, 0.21503, 39e-5],
3706
+ [0.21503, 39e-5, 0.64271, 0.01366, 0.98632, 0.35728, 0.99961, 0.78497],
3707
+ [0.99961, 0.78497, 1, 0.79753, 1, 0.81239, 1, 0.8421],
3708
+ [1, 0.8421, 1, 0.84767, 1, 0.85046, 0.99993, 0.85282],
3709
+ [0.99993, 0.85282, 0.99743, 0.93301, 0.933, 0.99744, 0.85282, 0.99993],
3710
+ [0.85282, 0.99993, 0.85046, 1, 0.84768, 1, 0.84211, 1],
3711
+ [0.84211, 1, 0.63634, 1, 0.43057, 1, 0.2248, 1],
3712
+ [0.2248, 1, 0.15688, 1, 0.12292, 1, 0.09598, 0.98933],
3713
+ [0.09598, 0.98933, 0.05698, 0.97389, 0.02611, 0.94301, 0.01067, 0.90402],
3714
+ [0.01067, 0.90402, 0, 0.87708, 0, 0.84312, 0, 0.7752],
3715
+ [0, 0.7752, 0, 0.56943, 0, 0.36366, 0, 0.15789]
3716
+ ]);
3717
+ var flowerShape = createShape([
3718
+ [0.85353, 0.14645, 0.81641, 0.10934, 0.73184, 0.12769, 0.62984, 0.1865],
3719
+ [0.62984, 0.1865, 0.59928, 0.07277, 0.55247, 0, 0.5, 0],
3720
+ [0.5, 0, 0.4475, 0, 0.40069, 0.07276, 0.37016, 0.18649],
3721
+ [0.37016, 0.18649, 0.26813, 0.12768, 0.18359, 0.10934, 0.14647, 0.14644],
3722
+ [0.14647, 0.14644, 0.10938, 0.18355, 0.12772, 0.26811, 0.18653, 0.37014],
3723
+ [0.18653, 0.37014, 0.07278, 0.40069, 0, 0.44751, 0, 0.5],
3724
+ [0, 0.5, 0, 0.55248, 0.07275, 0.59929, 0.1865, 0.62984],
3725
+ [0.1865, 0.62984, 0.12766, 0.73188, 0.10931, 0.81644, 0.14641, 0.85355],
3726
+ [0.14641, 0.85355, 0.18353, 0.89067, 0.26809, 0.87231, 0.37012, 0.81347],
3727
+ [0.37012, 0.81347, 0.40069, 0.92722, 0.4475, 1, 0.5, 1],
3728
+ [0.5, 1, 0.55247, 1, 0.59928, 0.92722, 0.62984, 0.81346],
3729
+ [0.62984, 0.81346, 0.73191, 0.8723, 0.81647, 0.89066, 0.85359, 0.85355],
3730
+ [0.85359, 0.85355, 0.89069, 0.81644, 0.87234, 0.73188, 0.8135, 0.62984],
3731
+ [0.8135, 0.62984, 0.92725, 0.59929, 1, 0.55248, 1, 0.5],
3732
+ [1, 0.5, 1, 0.44751, 0.92722, 0.40069, 0.81344, 0.37014],
3733
+ [0.81344, 0.37014, 0.87228, 0.26811, 0.89063, 0.18356, 0.85353, 0.14645]
3734
+ ]);
3735
+ var gemShape = createShape([
3736
+ [0.31244, 0.08536, 0.37064, 0.04306, 0.39978, 0.02191, 0.4308, 0.0114],
3737
+ [0.4308, 0.0114, 0.47568, -38e-4, 0.52432, -38e-4, 0.5692, 0.0114],
3738
+ [0.5692, 0.0114, 0.60022, 0.02191, 0.62936, 0.04306, 0.68756, 0.08536],
3739
+ [0.68756, 0.08536, 0.73121, 0.11706, 0.77485, 0.14876, 0.81849, 0.18046],
3740
+ [0.81849, 0.18046, 0.85308, 0.20558, 0.87038, 0.21814, 0.88446, 0.23321],
3741
+ [0.88446, 0.23321, 0.90483, 0.25499, 0.92046, 0.28077, 0.93035, 0.30891],
3742
+ [0.93035, 0.30891, 0.93721, 0.32838, 0.94032, 0.34951, 0.9466, 0.39178],
3743
+ [0.9466, 0.39178, 0.95468, 0.44627, 0.96276, 0.50076, 0.97083, 0.55524],
3744
+ [0.97083, 0.55524, 0.98183, 0.6294, 0.98734, 0.66648, 0.9818, 0.69989],
3745
+ [0.9818, 0.69989, 0.97375, 0.74823, 0.9495, 0.79239, 0.91301, 0.8251],
3746
+ [0.91301, 0.8251, 0.88779, 0.84771, 0.85353, 0.86296, 0.78503, 0.89347],
3747
+ [0.78503, 0.89347, 0.73331, 0.91651, 0.68159, 0.93954, 0.62987, 0.96258],
3748
+ [0.62987, 0.96258, 0.58853, 0.98099, 0.56785, 0.99019, 0.54663, 0.9949],
3749
+ [0.54663, 0.9949, 0.51592, 1.0017, 0.48408, 1.0017, 0.45337, 0.9949],
3750
+ [0.45337, 0.9949, 0.43215, 0.99019, 0.41147, 0.98099, 0.37013, 0.96258],
3751
+ [0.37013, 0.96258, 0.31841, 0.93954, 0.26669, 0.91651, 0.21497, 0.89347],
3752
+ [0.21497, 0.89347, 0.14647, 0.86296, 0.11221, 0.84771, 0.08699, 0.8251],
3753
+ [0.08699, 0.8251, 0.0505, 0.79239, 0.02625, 0.74823, 0.0182, 0.69989],
3754
+ [0.0182, 0.69989, 0.01266, 0.66648, 0.01817, 0.6294, 0.02917, 0.55524],
3755
+ [0.02917, 0.55524, 0.03724, 0.50076, 0.04532, 0.44627, 0.0534, 0.39178],
3756
+ [0.0534, 0.39178, 0.05968, 0.34951, 0.06279, 0.32838, 0.06965, 0.30891],
3757
+ [0.06965, 0.30891, 0.07954, 0.28077, 0.09517, 0.25499, 0.11554, 0.23321],
3758
+ [0.11554, 0.23321, 0.12962, 0.21814, 0.14692, 0.20558, 0.18151, 0.18046],
3759
+ [0.18151, 0.18046, 0.22515, 0.14876, 0.26879, 0.11706, 0.31244, 0.08536]
3760
+ ]);
3761
+ var ghostishShape = createShape([
3762
+ [0, 0.47619, 0, 0.2132, 0.22386, 0, 0.5, 0],
3763
+ [0.5, 0, 0.77614, 0, 1, 0.2132, 1, 0.47619],
3764
+ [1, 0.47619, 1, 0.5873, 1, 0.69841, 1, 0.80952],
3765
+ [1, 0.80952, 1, 0.91472, 0.91046, 1, 0.8, 1],
3766
+ [0.8, 1, 0.76726, 1, 0.73636, 0.99251, 0.70908, 0.97923],
3767
+ [0.70908, 0.97923, 0.69518, 0.97246, 0.68131, 0.96504, 0.66738, 0.95759],
3768
+ [0.66738, 0.95759, 0.61838, 0.93137, 0.56864, 0.90476, 0.51423, 0.90476],
3769
+ [0.51423, 0.90476, 0.50474, 0.90476, 0.49526, 0.90476, 0.48577, 0.90476],
3770
+ [0.48577, 0.90476, 0.43136, 0.90476, 0.38163, 0.93137, 0.33262, 0.95759],
3771
+ [0.33262, 0.95759, 0.31869, 0.96504, 0.30482, 0.97246, 0.29092, 0.97923],
3772
+ [0.29092, 0.97923, 0.26364, 0.99251, 0.23274, 1, 0.2, 1],
3773
+ [0.2, 1, 0.08954, 1, 0, 0.91472, 0, 0.80952],
3774
+ [0, 0.80952, 0, 0.69841, 0, 0.5873, 0, 0.47619]
3775
+ ]);
3776
+ var heartShape = createShape([
3777
+ [0.78469, 0.05353, 0.717, 0.05353, 0.6566, 0.08531, 0.61713, 0.135],
3778
+ [0.61713, 0.135, 0.57809, 0.17803, 0.53904, 0.22106, 0.5, 0.26409],
3779
+ [0.5, 0.26409, 0.5, 0.26396, 0.5, 0.26382, 0.5, 0.26369],
3780
+ [0.5, 0.26369, 0.46096, 0.22065, 0.42191, 0.1776, 0.38287, 0.13456],
3781
+ [0.38287, 0.13456, 0.3434, 0.08491, 0.283, 0.05312, 0.21531, 0.05312],
3782
+ [0.21531, 0.05312, 0.0964, 0.05312, 0, 0.15116, 0, 0.27206],
3783
+ [0, 0.27206, 0, 0.37831, 0.08867, 0.45772, 0.15287, 0.534],
3784
+ [0.15287, 0.534, 0.21684, 0.61003, 0.2808, 0.686, 0.34476, 0.762],
3785
+ [0.34476, 0.762, 0.39262, 0.81887, 0.44049, 0.87575, 0.48835, 0.93263],
3786
+ [0.48835, 0.93263, 0.49224, 0.93722, 0.49611, 0.94184, 0.5, 0.94647],
3787
+ [0.5, 0.94647, 0.5, 0.9466, 0.5, 0.94674, 0.5, 0.94688],
3788
+ [0.5, 0.94688, 0.50389, 0.94225, 0.50776, 0.93766, 0.51165, 0.93303],
3789
+ [0.51165, 0.93303, 0.55951, 0.87616, 0.60737, 0.81931, 0.65524, 0.76244],
3790
+ [0.65524, 0.76244, 0.7192, 0.68644, 0.78317, 0.61044, 0.84713, 0.53444],
3791
+ [0.84713, 0.53444, 0.91133, 0.45816, 1, 0.37875, 1, 0.27247],
3792
+ [1, 0.27247, 1, 0.15156, 0.9036, 0.05353, 0.78469, 0.05353]
3793
+ ]);
3794
+ var clover4LeafShape = createShape([
3795
+ [0.07095, 0.5, 0.02669, 0.44709, 0, 0.37882, 0, 0.30426],
3796
+ [0, 0.30426, 0, 0.13622, 0.13551, 0, 0.3027, 0],
3797
+ [0.3027, 0, 0.37834, 0, 0.44753, 0.02791, 0.50057, 0.07402],
3798
+ [0.50057, 0.07402, 0.55351, 0.02791, 0.62253, 0, 0.69801, 0],
3799
+ [0.69801, 0, 0.8648, 0, 1, 0.13622, 1, 0.30426],
3800
+ [1, 0.30426, 1, 0.37882, 0.97338, 0.44709, 0.92922, 0.5],
3801
+ [0.92922, 0.5, 0.97338, 0.55291, 1, 0.62118, 1, 0.69574],
3802
+ [1, 0.69574, 1, 0.86378, 0.8648, 1, 0.69801, 1],
3803
+ [0.69801, 1, 0.62253, 1, 0.55351, 0.97209, 0.50057, 0.92598],
3804
+ [0.50057, 0.92598, 0.44753, 0.97209, 0.37834, 1, 0.3027, 1],
3805
+ [0.3027, 1, 0.13551, 1, 0, 0.86378, 0, 0.69574],
3806
+ [0, 0.69574, 0, 0.62118, 0.02669, 0.55291, 0.07095, 0.5]
3807
+ ]);
3808
+ var clover8LeafShape = createShape([
3809
+ [0.96431, 0.5, 1.0451, 0.6505, 0.98406, 0.78678, 0.82834, 0.82831],
3810
+ [0.82834, 0.82831, 0.78678, 0.98406, 0.6505, 1.04506, 0.5, 0.96431],
3811
+ [0.5, 0.96431, 0.34947, 1.0451, 0.21319, 0.98406, 0.17166, 0.82834],
3812
+ [0.17166, 0.82834, 0.01594, 0.78678, -0.0451, 0.6505, 0.03569, 0.5],
3813
+ [0.03569, 0.5, -0.0451, 0.34947, 0.01594, 0.21319, 0.17166, 0.17166],
3814
+ [0.17166, 0.17166, 0.21319, 0.01594, 0.34947, -0.0451, 0.5, 0.03569],
3815
+ [0.5, 0.03569, 0.6505, -0.0451, 0.78678, 0.01594, 0.82831, 0.17166],
3816
+ [0.82831, 0.17166, 0.98406, 0.21319, 1.04506, 0.34947, 0.96431, 0.5]
3817
+ ]);
3818
+ var ovalShape = createShape([
3819
+ [0.77103, 0.77103, 0.53902, 1.00303, 0.22959, 1.06979, 0.07991, 0.9201],
3820
+ [0.07991, 0.9201, -0.06978, 0.7704, -304e-5, 0.46097, 0.22897, 0.22897],
3821
+ [0.22897, 0.22897, 0.46098, -303e-5, 0.77041, -0.06979, 0.92009, 0.0799],
3822
+ [0.92009, 0.0799, 1.06978, 0.2296, 1.00304, 0.53903, 0.77103, 0.77103]
3823
+ ]);
3824
+ var pentagonShape = createShape([
3825
+ [0.3426, 0.07617, 0.39138, 0.03842, 0.41575, 0.01954, 0.44181, 0.01017],
3826
+ [0.44181, 0.01017, 0.47942, -336e-5, 0.52058, -336e-5, 0.55819, 0.01017],
3827
+ [0.55819, 0.01017, 0.58425, 0.01954, 0.60862, 0.03842, 0.6574, 0.07617],
3828
+ [0.6574, 0.07617, 0.69296, 0.1037, 0.72853, 0.13123, 0.76409, 0.15876],
3829
+ [0.76409, 0.15876, 0.79963, 0.18455, 0.83517, 0.21034, 0.87071, 0.23613],
3830
+ [0.87071, 0.23613, 0.9213, 0.27285, 0.94662, 0.29123, 0.96352, 0.31429],
3831
+ [0.96352, 0.31429, 0.98796, 0.34769, 1.00083, 0.38872, 0.99996, 0.43069],
3832
+ [0.99996, 0.43069, 0.99933, 0.45972, 0.9893, 0.49006, 0.96918, 0.55072],
3833
+ [0.96918, 0.55072, 0.95522, 0.59283, 0.94126, 0.63495, 0.9273, 0.67706],
3834
+ [0.9273, 0.67706, 0.91443, 0.72021, 0.90155, 0.76335, 0.88868, 0.8065],
3835
+ [0.88868, 0.8065, 0.87052, 0.86724, 0.86146, 0.89762, 0.84562, 0.92124],
3836
+ [0.84562, 0.92124, 0.82268, 0.95543, 0.78934, 0.98055, 0.75099, 0.99259],
3837
+ [0.75099, 0.99259, 0.7245, 1.00093, 0.69393, 1.00043, 0.63281, 0.99946],
3838
+ [0.63281, 0.99946, 0.58854, 0.99876, 0.54427, 0.99806, 0.5, 0.99737],
3839
+ [0.5, 0.99737, 0.45573, 0.99806, 0.41146, 0.99876, 0.36719, 0.99946],
3840
+ [0.36719, 0.99946, 0.30607, 1.00043, 0.2755, 1.00093, 0.24901, 0.99259],
3841
+ [0.24901, 0.99259, 0.21066, 0.98055, 0.17732, 0.95543, 0.15438, 0.92124],
3842
+ [0.15438, 0.92124, 0.13854, 0.89762, 0.12948, 0.86724, 0.11132, 0.8065],
3843
+ [0.11132, 0.8065, 0.09845, 0.76335, 0.08557, 0.72021, 0.0727, 0.67706],
3844
+ [0.0727, 0.67706, 0.05874, 0.63495, 0.04478, 0.59283, 0.03082, 0.55072],
3845
+ [0.03082, 0.55072, 0.0107, 0.49006, 67e-5, 0.45972, 4e-5, 0.43069],
3846
+ [4e-5, 0.43069, -83e-5, 0.38872, 0.01204, 0.34769, 0.03648, 0.31429],
3847
+ [0.03648, 0.31429, 0.05338, 0.29123, 0.0787, 0.27285, 0.12929, 0.23613],
3848
+ [0.12929, 0.23613, 0.16483, 0.21034, 0.20037, 0.18455, 0.23591, 0.15876],
3849
+ [0.23591, 0.15876, 0.27147, 0.13123, 0.30704, 0.1037, 0.3426, 0.07617]
3850
+ ]);
3851
+ var pillShape = createShape([
3852
+ [0.2662, 0.1259, 0.43407, -0.04197, 0.70623, -0.04197, 0.8741, 0.1259],
3853
+ [0.8741, 0.1259, 1.04197, 0.29377, 1.04197, 0.56593, 0.8741, 0.7338],
3854
+ [0.8741, 0.7338, 0.82733, 0.78057, 0.78057, 0.82733, 0.7338, 0.8741],
3855
+ [0.7338, 0.8741, 0.56593, 1.04197, 0.29377, 1.04197, 0.1259, 0.8741],
3856
+ [0.1259, 0.8741, -0.04197, 0.70623, -0.04197, 0.43407, 0.1259, 0.2662],
3857
+ [0.1259, 0.2662, 0.17267, 0.21943, 0.21943, 0.17267, 0.2662, 0.1259]
3858
+ ]);
3859
+ var pixelCircleShape = createShape([
3860
+ [0.70372, 0, 0.56791, 0, 0.43209, 0, 0.29628, 0],
3861
+ [0.29628, 0, 0.29628, 0.0216, 0.29628, 0.04321, 0.29628, 0.06481],
3862
+ [0.29628, 0.06481, 0.24999, 0.06481, 0.2037, 0.06481, 0.15741, 0.06481],
3863
+ [0.15741, 0.06481, 0.15741, 0.09259, 0.15741, 0.12037, 0.15741, 0.14816],
3864
+ [0.15741, 0.14816, 0.12963, 0.14816, 0.10185, 0.14816, 0.07408, 0.14816],
3865
+ [0.07408, 0.14816, 0.07408, 0.19753, 0.07408, 0.24691, 0.07408, 0.29628],
3866
+ [0.07408, 0.29628, 0.04938, 0.29628, 0.02469, 0.29628, 0, 0.29628],
3867
+ [0, 0.29628, 0, 0.43209, 0, 0.56791, 0, 0.70372],
3868
+ [0, 0.70372, 0.02469, 0.70372, 0.04938, 0.70372, 0.07408, 0.70372],
3869
+ [0.07408, 0.70372, 0.07408, 0.75309, 0.07408, 0.80247, 0.07408, 0.85184],
3870
+ [0.07408, 0.85184, 0.10185, 0.85184, 0.12963, 0.85184, 0.15741, 0.85184],
3871
+ [0.15741, 0.85184, 0.15741, 0.87962, 0.15741, 0.90741, 0.15741, 0.93519],
3872
+ [0.15741, 0.93519, 0.2037, 0.93519, 0.24999, 0.93519, 0.29628, 0.93519],
3873
+ [0.29628, 0.93519, 0.29628, 0.95679, 0.29628, 0.9784, 0.29628, 1],
3874
+ [0.29628, 1, 0.43209, 1, 0.56791, 1, 0.70372, 1],
3875
+ [0.70372, 1, 0.70372, 0.9784, 0.70372, 0.95679, 0.70372, 0.93519],
3876
+ [0.70372, 0.93519, 0.75001, 0.93519, 0.7963, 0.93519, 0.84259, 0.93519],
3877
+ [0.84259, 0.93519, 0.84259, 0.90741, 0.84259, 0.87962, 0.84259, 0.85184],
3878
+ [0.84259, 0.85184, 0.87037, 0.85184, 0.89816, 0.85184, 0.92594, 0.85184],
3879
+ [0.92594, 0.85184, 0.92594, 0.80247, 0.92594, 0.75309, 0.92594, 0.70372],
3880
+ [0.92594, 0.70372, 0.95062, 0.70372, 0.97531, 0.70372, 1, 0.70372],
3881
+ [1, 0.70372, 1, 0.56791, 1, 0.43209, 1, 0.29628],
3882
+ [1, 0.29628, 0.97531, 0.29628, 0.95062, 0.29628, 0.92594, 0.29628],
3883
+ [0.92594, 0.29628, 0.92594, 0.24691, 0.92594, 0.19753, 0.92594, 0.14816],
3884
+ [0.92594, 0.14816, 0.89816, 0.14816, 0.87037, 0.14816, 0.84259, 0.14816],
3885
+ [0.84259, 0.14816, 0.84259, 0.12038, 0.84259, 0.09259, 0.84259, 0.06481],
3886
+ [0.84259, 0.06481, 0.7963, 0.06481, 0.75001, 0.06481, 0.70372, 0.06481],
3887
+ [0.70372, 0.06481, 0.70372, 0.04321, 0.70372, 0.0216, 0.70372, 0]
3888
+ ]);
3889
+ var pixelTriangleShape = createShape([
3890
+ [0.28637, 0, 0.22842, 0, 0.17046, 0, 0.1125, 0],
3891
+ [0.1125, 0, 0.1125, 0.33333, 0.1125, 0.66667, 0.1125, 1],
3892
+ [0.1125, 1, 0.17046, 1, 0.22842, 1, 0.28637, 1],
3893
+ [0.28637, 1, 0.28637, 0.97101, 0.28637, 0.94203, 0.28637, 0.91304],
3894
+ [0.28637, 0.91304, 0.33108, 0.91304, 0.37579, 0.91304, 0.4205, 0.91304],
3895
+ [0.4205, 0.91304, 0.4205, 0.88551, 0.4205, 0.85797, 0.4205, 0.83043],
3896
+ [0.4205, 0.83043, 0.46688, 0.83043, 0.51325, 0.83043, 0.55963, 0.83043],
3897
+ [0.55963, 0.83043, 0.55963, 0.79855, 0.55963, 0.76667, 0.55963, 0.73478],
3898
+ [0.55963, 0.73478, 0.59771, 0.73478, 0.63579, 0.73478, 0.67388, 0.73478],
3899
+ [0.67388, 0.73478, 0.67388, 0.70869, 0.67388, 0.68261, 0.67388, 0.65652],
3900
+ [0.67388, 0.65652, 0.71197, 0.65652, 0.75006, 0.65652, 0.78816, 0.65652],
3901
+ [0.78816, 0.65652, 0.78816, 0.62464, 0.78816, 0.59275, 0.78816, 0.56087],
3902
+ [0.78816, 0.56087, 0.82127, 0.56087, 0.85439, 0.56087, 0.8875, 0.56087],
3903
+ [0.8875, 0.56087, 0.8875, 0.52029, 0.8875, 0.47971, 0.8875, 0.43913],
3904
+ [0.8875, 0.43913, 0.85439, 0.43913, 0.82127, 0.43913, 0.78816, 0.43913],
3905
+ [0.78816, 0.43913, 0.78816, 0.40725, 0.78816, 0.37536, 0.78816, 0.34347],
3906
+ [0.78816, 0.34347, 0.75006, 0.34347, 0.71197, 0.34347, 0.67388, 0.34347],
3907
+ [0.67388, 0.34347, 0.67388, 0.31739, 0.67388, 0.2913, 0.67388, 0.26522],
3908
+ [0.67388, 0.26522, 0.63579, 0.26522, 0.59771, 0.26522, 0.55963, 0.26522],
3909
+ [0.55963, 0.26522, 0.55963, 0.23333, 0.55963, 0.20145, 0.55963, 0.16957],
3910
+ [0.55963, 0.16957, 0.51325, 0.16957, 0.46688, 0.16957, 0.4205, 0.16957],
3911
+ [0.4205, 0.16957, 0.4205, 0.14203, 0.4205, 0.11449, 0.4205, 0.08696],
3912
+ [0.4205, 0.08696, 0.37579, 0.08696, 0.33108, 0.08696, 0.28637, 0.08696],
3913
+ [0.28637, 0.08696, 0.28637, 0.05797, 0.28637, 0.02899, 0.28637, 0]
3914
+ ]);
3915
+ var puffyDiamondShape = createShape([
3916
+ [0.77937, 0.78048, 0.81712, 0.7427, 0.8299, 0.6894, 0.81768, 0.64111],
3917
+ [0.81768, 0.64111, 0.86599, 0.65339, 0.91937, 0.64063, 0.95718, 0.60282],
3918
+ [0.95718, 0.60282, 1.01427, 0.54574, 1.01427, 0.45319, 0.95718, 0.39611],
3919
+ [0.95718, 0.39611, 0.91959, 0.35852, 0.86662, 0.34569, 0.81856, 0.3576],
3920
+ [0.81856, 0.3576, 0.82928, 0.31027, 0.81621, 0.25865, 0.77937, 0.2218],
3921
+ [0.77937, 0.2218, 0.7415, 0.18394, 0.68803, 0.17119, 0.63969, 0.18355],
3922
+ [0.63969, 0.18355, 0.6525, 0.13492, 0.63984, 0.08095, 0.60169, 0.04282],
3923
+ [0.60169, 0.04282, 0.54462, -0.01426, 0.45206, -0.01426, 0.395, 0.04282],
3924
+ [0.395, 0.04282, 0.3571, 0.08073, 0.34435, 0.13427, 0.35678, 0.18269],
3925
+ [0.35678, 0.18269, 0.30938, 0.17184, 0.2576, 0.18487, 0.22069, 0.2218],
3926
+ [0.22069, 0.2218, 0.18385, 0.25865, 0.17079, 0.31028, 0.1815, 0.35761],
3927
+ [0.1815, 0.35761, 0.13341, 0.34568, 0.08041, 0.35851, 0.04282, 0.39611],
3928
+ [0.04282, 0.39611, -0.01427, 0.45319, -0.01427, 0.54574, 0.04282, 0.60282],
3929
+ [0.04282, 0.60282, 0.08063, 0.64064, 0.13404, 0.6534, 0.18235, 0.6411],
3930
+ [0.18235, 0.6411, 0.17013, 0.68939, 0.18291, 0.7427, 0.22069, 0.78048],
3931
+ [0.22069, 0.78048, 0.25744, 0.81725, 0.30894, 0.83033, 0.35619, 0.81973],
3932
+ [0.35619, 0.81973, 0.34478, 0.8675, 0.35772, 0.9199, 0.395, 0.95718],
3933
+ [0.395, 0.95718, 0.45206, 1.01426, 0.54462, 1.01426, 0.60169, 0.95718],
3934
+ [0.60169, 0.95718, 0.63919, 0.91968, 0.65206, 0.86688, 0.64028, 0.81888],
3935
+ [0.64028, 0.81888, 0.6885, 0.83098, 0.74165, 0.81817, 0.77937, 0.78048]
3936
+ ]);
3937
+ var puffyShape = createShape([
3938
+ [0.99994, 0.49408, 0.99912, 0.42679, 0.94916, 0.37292, 0.88825, 0.37382],
3939
+ [0.88825, 0.37382, 0.88491, 0.37382, 0.88159, 0.3741, 0.87831, 0.37449],
3940
+ [0.87831, 0.37449, 0.88087, 0.37218, 0.88337, 0.36982, 0.88575, 0.36722],
3941
+ [0.88575, 0.36722, 0.92937, 0.32028, 0.93028, 0.24307, 0.88784, 0.19483],
3942
+ [0.88784, 0.19483, 0.88534, 0.19201, 0.88287, 0.18919, 0.88031, 0.18648],
3943
+ [0.88031, 0.18648, 0.83669, 0.13954, 0.76694, 0.14055, 0.72444, 0.1888],
3944
+ [0.72444, 0.1888, 0.72209, 0.19144, 0.71997, 0.19421, 0.71787, 0.19703],
3945
+ [0.71787, 0.19703, 0.71822, 0.19342, 0.71844, 0.18975, 0.7185, 0.18603],
3946
+ [0.7185, 0.18603, 0.71934, 0.11874, 0.67066, 0.06346, 0.60981, 0.0625],
3947
+ [0.60981, 0.0625, 0.60682, 0.0625, 0.60383, 0.0625, 0.60084, 0.0625],
3948
+ [0.60084, 0.0625, 0.55575, 0.0625, 0.51706, 0.09248, 0.5, 0.13537],
3949
+ [0.5, 0.13537, 0.48294, 0.09248, 0.44422, 0.0625, 0.39916, 0.0625],
3950
+ [0.39916, 0.0625, 0.39617, 0.0625, 0.39318, 0.0625, 0.39019, 0.0625],
3951
+ [0.39019, 0.0625, 0.32934, 0.0634, 0.28066, 0.11869, 0.28147, 0.18603],
3952
+ [0.28147, 0.18603, 0.28147, 0.18975, 0.28172, 0.19342, 0.28206, 0.19703],
3953
+ [0.28206, 0.19703, 0.28, 0.19418, 0.27781, 0.19144, 0.2755, 0.1888],
3954
+ [0.2755, 0.1888, 0.23306, 0.14055, 0.16325, 0.13954, 0.11962, 0.18648],
3955
+ [0.11962, 0.18648, 0.11709, 0.18925, 0.11453, 0.19201, 0.11209, 0.19483],
3956
+ [0.11209, 0.19483, 0.06966, 0.24307, 0.07056, 0.32022, 0.11419, 0.36722],
3957
+ [0.11419, 0.36722, 0.11659, 0.36982, 0.11906, 0.37218, 0.12162, 0.37449],
3958
+ [0.12162, 0.37449, 0.11833, 0.37409, 0.11501, 0.37387, 0.11169, 0.37382],
3959
+ [0.11169, 0.37382, 0.05084, 0.37292, 87e-5, 0.42679, 0, 0.49408],
3960
+ [0, 0.49408, 0, 0.49803, 0, 0.50197, 0, 0.50592],
3961
+ [0, 0.50592, 81e-5, 0.57321, 0.05081, 0.62708, 0.11169, 0.62618],
3962
+ [0.11169, 0.62618, 0.11506, 0.62618, 0.11837, 0.6259, 0.12162, 0.62551],
3963
+ [0.12162, 0.62551, 0.11906, 0.62782, 0.11659, 0.63018, 0.11419, 0.63278],
3964
+ [0.11419, 0.63278, 0.07056, 0.67972, 0.06966, 0.75693, 0.11209, 0.80518],
3965
+ [0.11209, 0.80518, 0.11459, 0.80799, 0.11709, 0.81081, 0.11962, 0.81352],
3966
+ [0.11962, 0.81352, 0.16325, 0.86046, 0.233, 0.85945, 0.2755, 0.8112],
3967
+ [0.2755, 0.8112, 0.27784, 0.80856, 0.28, 0.80579, 0.28206, 0.80297],
3968
+ [0.28206, 0.80298, 0.28171, 0.80663, 0.28151, 0.8103, 0.28147, 0.81397],
3969
+ [0.28147, 0.81397, 0.28066, 0.88126, 0.32931, 0.9366, 0.39019, 0.9375],
3970
+ [0.39019, 0.9375, 0.39318, 0.9375, 0.39617, 0.9375, 0.39916, 0.9375],
3971
+ [0.39916, 0.9375, 0.44425, 0.9375, 0.48294, 0.90752, 0.5, 0.86463],
3972
+ [0.5, 0.86463, 0.51706, 0.90752, 0.55578, 0.9375, 0.60084, 0.9375],
3973
+ [0.60084, 0.9375, 0.60383, 0.9375, 0.60682, 0.9375, 0.60981, 0.9375],
3974
+ [0.60981, 0.9375, 0.67066, 0.9366, 0.71934, 0.88131, 0.71853, 0.81397],
3975
+ [0.71853, 0.81397, 0.71853, 0.81025, 0.71828, 0.80658, 0.71794, 0.80297],
3976
+ [0.71794, 0.80297, 0.72, 0.80579, 0.72216, 0.80856, 0.7245, 0.8112],
3977
+ [0.7245, 0.8112, 0.76694, 0.85945, 0.83675, 0.86046, 0.88037, 0.81352],
3978
+ [0.88037, 0.81352, 0.88291, 0.81075, 0.88547, 0.80799, 0.88791, 0.80518],
3979
+ [0.88791, 0.80518, 0.93034, 0.75693, 0.92944, 0.67978, 0.88581, 0.63278],
3980
+ [0.88581, 0.63278, 0.88341, 0.63018, 0.88094, 0.62782, 0.87838, 0.62551],
3981
+ [0.87838, 0.62551, 0.88167, 0.62591, 0.88499, 0.62613, 0.88831, 0.62618],
3982
+ [0.88831, 0.62618, 0.94916, 0.62708, 0.99919, 0.57327, 1, 0.50592],
3983
+ [1, 0.50592, 1, 0.50197, 1, 0.49803, 1, 0.49408],
3984
+ [1, 0.49408, 0.99998, 0.49408, 0.99996, 0.49408, 0.99994, 0.49408]
3985
+ ]);
3986
+ var semiCircleShape = createShape([
3987
+ [1, 0.70913, 1, 0.76622, 0.95372, 0.8125, 0.89663, 0.8125],
3988
+ [0.89663, 0.8125, 0.63221, 0.8125, 0.36779, 0.8125, 0.10337, 0.8125],
3989
+ [0.10337, 0.8125, 0.04628, 0.8125, 0, 0.76622, 0, 0.70913],
3990
+ [0, 0.70913, 0, 0.70192, 0, 0.69471, 0, 0.6875],
3991
+ [0, 0.6875, 0, 0.41134, 0.22386, 0.1875, 0.5, 0.1875],
3992
+ [0.5, 0.1875, 0.77614, 0.1875, 1, 0.41134, 1, 0.6875],
3993
+ [1, 0.6875, 1, 0.69471, 1, 0.70192, 1, 0.70913]
3994
+ ]);
3995
+ var cookie12SidedShape = createShape([
3996
+ [0.42719, 0.03077, 0.42887, 0.02912, 0.42972, 0.02827, 0.43044, 0.02759],
3997
+ [0.43044, 0.02759, 0.46953, -92e-4, 0.53047, -92e-4, 0.56956, 0.02759],
3998
+ [0.56956, 0.02759, 0.57028, 0.02827, 0.57113, 0.02912, 0.57281, 0.03077],
3999
+ [0.57281, 0.03077, 0.57384, 0.03174, 0.57434, 0.03224, 0.57481, 0.03271],
4000
+ [0.57481, 0.03271, 0.59982, 0.05657, 0.63526, 0.06606, 0.66885, 0.0579],
4001
+ [0.66885, 0.0579, 0.6695, 0.05774, 0.67019, 0.05756, 0.67157, 0.05721],
4002
+ [0.67157, 0.05721, 0.67385, 0.05662, 0.675, 0.05634, 0.67597, 0.05609],
4003
+ [0.67597, 0.05609, 0.72819, 0.04377, 0.781, 0.07424, 0.79644, 0.12565],
4004
+ [0.79644, 0.12565, 0.79672, 0.12662, 0.79704, 0.12774, 0.79769, 0.13003],
4005
+ [0.79769, 0.13003, 0.79807, 0.1314, 0.79825, 0.13209, 0.79844, 0.13274],
4006
+ [0.79844, 0.13274, 0.80817, 0.1659, 0.8341, 0.19183, 0.86726, 0.20156],
4007
+ [0.86726, 0.20156, 0.86791, 0.20175, 0.8686, 0.20193, 0.86997, 0.20231],
4008
+ [0.86997, 0.20231, 0.87226, 0.20296, 0.87338, 0.20328, 0.87435, 0.20356],
4009
+ [0.87435, 0.20356, 0.92576, 0.219, 0.95623, 0.27181, 0.94391, 0.32403],
4010
+ [0.94391, 0.32403, 0.94366, 0.325, 0.94338, 0.32615, 0.94279, 0.32843],
4011
+ [0.94279, 0.32843, 0.94244, 0.32981, 0.94226, 0.3305, 0.9421, 0.33115],
4012
+ [0.9421, 0.33115, 0.93394, 0.36474, 0.94343, 0.40018, 0.96729, 0.42519],
4013
+ [0.96729, 0.42519, 0.96776, 0.42566, 0.96826, 0.42616, 0.96923, 0.42719],
4014
+ [0.96923, 0.42719, 0.97088, 0.42887, 0.97173, 0.42972, 0.97241, 0.43044],
4015
+ [0.97241, 0.43044, 1.0092, 0.46953, 1.0092, 0.53047, 0.97241, 0.56956],
4016
+ [0.97241, 0.56956, 0.97173, 0.57028, 0.97088, 0.57113, 0.96923, 0.57281],
4017
+ [0.96923, 0.57281, 0.96826, 0.57384, 0.96776, 0.57434, 0.96729, 0.57481],
4018
+ [0.96729, 0.57481, 0.94343, 0.59982, 0.93394, 0.63526, 0.9421, 0.66885],
4019
+ [0.9421, 0.66885, 0.94226, 0.6695, 0.94244, 0.67019, 0.94279, 0.67157],
4020
+ [0.94279, 0.67157, 0.94338, 0.67385, 0.94366, 0.675, 0.94391, 0.67597],
4021
+ [0.94391, 0.67597, 0.95623, 0.72819, 0.92576, 0.781, 0.87435, 0.79644],
4022
+ [0.87435, 0.79644, 0.87338, 0.79672, 0.87226, 0.79704, 0.86997, 0.79769],
4023
+ [0.86997, 0.79769, 0.8686, 0.79807, 0.86791, 0.79825, 0.86726, 0.79844],
4024
+ [0.86726, 0.79844, 0.8341, 0.80817, 0.80817, 0.8341, 0.79844, 0.86726],
4025
+ [0.79844, 0.86726, 0.79825, 0.86791, 0.79807, 0.8686, 0.79769, 0.86997],
4026
+ [0.79769, 0.86997, 0.79704, 0.87226, 0.79672, 0.87338, 0.79644, 0.87435],
4027
+ [0.79644, 0.87435, 0.781, 0.92576, 0.72819, 0.95623, 0.67597, 0.94391],
4028
+ [0.67597, 0.94391, 0.675, 0.94366, 0.67385, 0.94338, 0.67157, 0.94279],
4029
+ [0.67157, 0.94279, 0.67019, 0.94244, 0.6695, 0.94226, 0.66885, 0.9421],
4030
+ [0.66885, 0.9421, 0.63526, 0.93394, 0.59982, 0.94343, 0.57481, 0.96729],
4031
+ [0.57481, 0.96729, 0.57434, 0.96776, 0.57384, 0.96826, 0.57281, 0.96923],
4032
+ [0.57281, 0.96923, 0.57113, 0.97088, 0.57028, 0.97173, 0.56956, 0.97241],
4033
+ [0.56956, 0.97241, 0.53047, 1.0092, 0.46953, 1.0092, 0.43044, 0.97241],
4034
+ [0.43044, 0.97241, 0.42972, 0.97173, 0.42887, 0.97088, 0.42719, 0.96923],
4035
+ [0.42719, 0.96923, 0.42616, 0.96826, 0.42566, 0.96776, 0.42519, 0.96729],
4036
+ [0.42519, 0.96729, 0.40018, 0.94343, 0.36474, 0.93394, 0.33115, 0.9421],
4037
+ [0.33115, 0.9421, 0.3305, 0.94226, 0.32981, 0.94244, 0.32843, 0.94279],
4038
+ [0.32843, 0.94279, 0.32615, 0.94338, 0.325, 0.94366, 0.32403, 0.94391],
4039
+ [0.32403, 0.94391, 0.27181, 0.95623, 0.219, 0.92576, 0.20356, 0.87435],
4040
+ [0.20356, 0.87435, 0.20328, 0.87338, 0.20296, 0.87226, 0.20231, 0.86997],
4041
+ [0.20231, 0.86997, 0.20193, 0.8686, 0.20175, 0.86791, 0.20156, 0.86726],
4042
+ [0.20156, 0.86726, 0.19183, 0.8341, 0.1659, 0.80817, 0.13274, 0.79844],
4043
+ [0.13274, 0.79844, 0.13209, 0.79825, 0.1314, 0.79807, 0.13003, 0.79769],
4044
+ [0.13003, 0.79769, 0.12774, 0.79704, 0.12662, 0.79672, 0.12565, 0.79644],
4045
+ [0.12565, 0.79644, 0.07424, 0.781, 0.04377, 0.72819, 0.05609, 0.67597],
4046
+ [0.05609, 0.67597, 0.05634, 0.675, 0.05662, 0.67385, 0.05721, 0.67157],
4047
+ [0.05721, 0.67157, 0.05756, 0.67019, 0.05774, 0.6695, 0.0579, 0.66885],
4048
+ [0.0579, 0.66885, 0.06606, 0.63526, 0.05657, 0.59982, 0.03271, 0.57481],
4049
+ [0.03271, 0.57481, 0.03224, 0.57434, 0.03174, 0.57384, 0.03077, 0.57281],
4050
+ [0.03077, 0.57281, 0.02912, 0.57113, 0.02827, 0.57028, 0.02759, 0.56956],
4051
+ [0.02759, 0.56956, -92e-4, 0.53047, -92e-4, 0.46953, 0.02759, 0.43044],
4052
+ [0.02759, 0.43044, 0.02827, 0.42972, 0.02912, 0.42887, 0.03077, 0.42719],
4053
+ [0.03077, 0.42719, 0.03174, 0.42616, 0.03224, 0.42566, 0.03271, 0.42519],
4054
+ [0.03271, 0.42519, 0.05657, 0.40018, 0.06606, 0.36474, 0.0579, 0.33115],
4055
+ [0.0579, 0.33115, 0.05774, 0.3305, 0.05756, 0.32981, 0.05721, 0.32843],
4056
+ [0.05721, 0.32843, 0.05662, 0.32615, 0.05634, 0.325, 0.05609, 0.32403],
4057
+ [0.05609, 0.32403, 0.04377, 0.27181, 0.07424, 0.219, 0.12565, 0.20356],
4058
+ [0.12565, 0.20356, 0.12662, 0.20328, 0.12774, 0.20296, 0.13003, 0.20231],
4059
+ [0.13003, 0.20231, 0.1314, 0.20193, 0.13209, 0.20175, 0.13274, 0.20156],
4060
+ [0.13274, 0.20156, 0.1659, 0.19183, 0.19183, 0.1659, 0.20156, 0.13274],
4061
+ [0.20156, 0.13274, 0.20175, 0.13209, 0.20193, 0.1314, 0.20231, 0.13003],
4062
+ [0.20231, 0.13003, 0.20296, 0.12774, 0.20328, 0.12662, 0.20356, 0.12565],
4063
+ [0.20356, 0.12565, 0.219, 0.07424, 0.27181, 0.04377, 0.32403, 0.05609],
4064
+ [0.32403, 0.05609, 0.325, 0.05634, 0.32615, 0.05662, 0.32843, 0.05721],
4065
+ [0.32843, 0.05721, 0.32981, 0.05756, 0.3305, 0.05774, 0.33115, 0.0579],
4066
+ [0.33115, 0.0579, 0.36474, 0.06606, 0.40018, 0.05657, 0.42519, 0.03271],
4067
+ [0.42519, 0.03271, 0.42566, 0.03224, 0.42616, 0.03174, 0.42719, 0.03077]
4068
+ ]);
4069
+ var cookie4SidedShape = createShape([
4070
+ [0.63833, 0.02217, 0.85312, -0.07111, 1.07112, 0.14689, 0.97783, 0.36168],
4071
+ [0.97783, 0.36168, 0.97269, 0.37351, 0.96755, 0.38534, 0.9624, 0.39718],
4072
+ [0.9624, 0.39718, 0.93394, 0.46277, 0.93394, 0.53723, 0.9624, 0.60282],
4073
+ [0.9624, 0.60282, 0.96755, 0.61466, 0.97269, 0.62649, 0.97783, 0.63832],
4074
+ [0.97783, 0.63832, 1.07112, 0.85311, 0.85312, 1.07111, 0.63833, 0.97783],
4075
+ [0.63833, 0.97783, 0.6265, 0.97268, 0.61466, 0.96754, 0.60283, 0.9624],
4076
+ [0.60283, 0.9624, 0.53724, 0.93393, 0.46278, 0.93393, 0.39718, 0.9624],
4077
+ [0.39718, 0.9624, 0.38535, 0.96754, 0.37352, 0.97268, 0.36168, 0.97783],
4078
+ [0.36168, 0.97783, 0.14689, 1.07111, -0.07112, 0.85311, 0.02217, 0.63832],
4079
+ [0.02217, 0.63832, 0.02731, 0.62649, 0.03245, 0.61466, 0.03759, 0.60282],
4080
+ [0.03759, 0.60282, 0.06608, 0.53723, 0.06608, 0.46277, 0.03759, 0.39718],
4081
+ [0.03759, 0.39718, 0.03245, 0.38534, 0.02731, 0.37351, 0.02217, 0.36168],
4082
+ [0.02217, 0.36168, -0.07112, 0.14689, 0.14689, -0.07111, 0.36168, 0.02217],
4083
+ [0.36168, 0.02217, 0.37352, 0.02732, 0.38535, 0.03246, 0.39718, 0.0376],
4084
+ [0.39718, 0.0376, 0.46278, 0.06607, 0.53724, 0.06607, 0.60283, 0.0376],
4085
+ [0.60283, 0.0376, 0.61466, 0.03246, 0.6265, 0.02732, 0.63833, 0.02217]
4086
+ ]);
4087
+ var cookie6SidedShape = createShape([
4088
+ [0.32337, 0.07142, 0.42176, -0.02381, 0.57824, -0.02381, 0.67663, 0.07142],
4089
+ [0.67663, 0.07142, 0.70677, 0.10055, 0.74365, 0.12178, 0.78399, 0.13319],
4090
+ [0.78399, 0.13319, 0.91589, 0.17053, 0.99413, 0.30566, 0.96061, 0.4382],
4091
+ [0.96061, 0.4382, 0.95036, 0.47876, 0.95036, 0.52124, 0.96061, 0.5618],
4092
+ [0.96061, 0.5618, 0.99413, 0.69434, 0.91589, 0.82947, 0.78399, 0.86681],
4093
+ [0.78399, 0.86681, 0.74365, 0.87822, 0.70677, 0.89945, 0.67663, 0.92858],
4094
+ [0.67663, 0.92858, 0.57824, 1.02381, 0.42176, 1.02381, 0.32337, 0.92858],
4095
+ [0.32337, 0.92858, 0.29323, 0.89945, 0.25635, 0.87822, 0.21601, 0.86681],
4096
+ [0.21601, 0.86681, 0.08411, 0.82947, 587e-5, 0.69434, 0.03939, 0.5618],
4097
+ [0.03939, 0.5618, 0.04964, 0.52124, 0.04964, 0.47876, 0.03939, 0.4382],
4098
+ [0.03939, 0.4382, 587e-5, 0.30566, 0.08411, 0.17053, 0.21601, 0.13319],
4099
+ [0.21601, 0.13319, 0.25635, 0.12178, 0.29323, 0.10055, 0.32337, 0.07142]
4100
+ ]);
4101
+ var cookie7SidedShape = createShape([
4102
+ [0.35209, 0.06806, 0.36326, 0.05824, 0.36884, 0.05334, 0.37397, 0.04937],
4103
+ [0.37397, 0.04937, 0.4482, -813e-5, 0.5518, -813e-5, 0.62603, 0.04937],
4104
+ [0.62603, 0.04937, 0.63116, 0.05334, 0.63674, 0.05824, 0.64791, 0.06806],
4105
+ [0.64791, 0.06806, 0.65164, 0.07137, 0.65351, 0.07299, 0.65539, 0.07459],
4106
+ [0.65539, 0.07459, 0.68167, 0.09662, 0.71303, 0.11176, 0.74663, 0.11862],
4107
+ [0.74663, 0.11862, 0.74903, 0.11912, 0.75147, 0.11956, 0.75637, 0.12043],
4108
+ [0.75637, 0.12043, 0.771, 0.12306, 0.77831, 0.12434, 0.78461, 0.1259],
4109
+ [0.78461, 0.1259, 0.87573, 0.14821, 0.94032, 0.2294, 0.94176, 0.3234],
4110
+ [0.94176, 0.3234, 0.94186, 0.3299, 0.94151, 0.33734, 0.9408, 0.35221],
4111
+ [0.9408, 0.35221, 0.94057, 0.35721, 0.94045, 0.35968, 0.94039, 0.36215],
4112
+ [0.94039, 0.36215, 0.93958, 0.39649, 0.94732, 0.43049, 0.96293, 0.46109],
4113
+ [0.96293, 0.46109, 0.96404, 0.46328, 0.96523, 0.46546, 0.96759, 0.46987],
4114
+ [0.96759, 0.46987, 0.97467, 0.48296, 0.97821, 0.4895, 0.98093, 0.4954],
4115
+ [0.98093, 0.4954, 1.02032, 0.58071, 0.99727, 0.68196, 0.92484, 0.74168],
4116
+ [0.92484, 0.74168, 0.91984, 0.74584, 0.91381, 0.75018, 0.90177, 0.7589],
4117
+ [0.90177, 0.7589, 0.89774, 0.76184, 0.89572, 0.76328, 0.89377, 0.76478],
4118
+ [0.89377, 0.76478, 0.86646, 0.78557, 0.84476, 0.81284, 0.83064, 0.84412],
4119
+ [0.83064, 0.84412, 0.82963, 0.84637, 0.82865, 0.84865, 0.82671, 0.85325],
4120
+ [0.82671, 0.85325, 0.82091, 0.86696, 0.818, 0.87381, 0.8151, 0.87962],
4121
+ [0.8151, 0.87962, 0.7731, 0.96368, 0.67977, 1.00875, 0.58801, 0.98925],
4122
+ [0.58801, 0.98925, 0.58166, 0.98787, 0.57451, 0.98587, 0.56019, 0.98187],
4123
+ [0.56019, 0.98187, 0.5554, 0.98056, 0.55301, 0.97987, 0.55063, 0.97928],
4124
+ [0.55063, 0.97928, 0.51741, 0.97084, 0.48259, 0.97084, 0.44937, 0.97928],
4125
+ [0.44937, 0.97928, 0.44699, 0.97987, 0.4446, 0.98056, 0.43981, 0.98187],
4126
+ [0.43981, 0.98187, 0.42549, 0.98587, 0.41834, 0.98787, 0.41199, 0.98925],
4127
+ [0.41199, 0.98925, 0.32023, 1.00875, 0.2269, 0.96368, 0.1849, 0.87962],
4128
+ [0.1849, 0.87962, 0.18199, 0.87381, 0.17909, 0.86696, 0.17329, 0.85325],
4129
+ [0.17329, 0.85325, 0.17135, 0.84865, 0.17037, 0.84637, 0.16936, 0.84412],
4130
+ [0.16936, 0.84412, 0.15523, 0.81284, 0.13353, 0.78557, 0.10623, 0.76478],
4131
+ [0.10623, 0.76478, 0.10428, 0.76328, 0.10226, 0.76184, 0.09823, 0.7589],
4132
+ [0.09823, 0.7589, 0.08619, 0.75018, 0.08017, 0.74584, 0.07516, 0.74168],
4133
+ [0.07516, 0.74168, 273e-5, 0.68196, -0.02032, 0.58071, 0.01907, 0.4954],
4134
+ [0.01907, 0.4954, 0.02179, 0.4895, 0.02533, 0.48296, 0.03241, 0.46987],
4135
+ [0.03241, 0.46987, 0.03477, 0.46546, 0.03596, 0.46328, 0.03707, 0.46109],
4136
+ [0.03707, 0.46109, 0.05268, 0.43049, 0.06042, 0.39649, 0.05961, 0.36215],
4137
+ [0.05961, 0.36215, 0.05955, 0.35968, 0.05943, 0.35721, 0.0592, 0.35221],
4138
+ [0.0592, 0.35221, 0.05849, 0.33734, 0.05813, 0.3299, 0.05824, 0.3234],
4139
+ [0.05824, 0.3234, 0.05968, 0.2294, 0.12427, 0.14821, 0.21539, 0.1259],
4140
+ [0.21539, 0.1259, 0.22169, 0.12434, 0.229, 0.12306, 0.24363, 0.12043],
4141
+ [0.24363, 0.12043, 0.24853, 0.11956, 0.25097, 0.11912, 0.25337, 0.11862],
4142
+ [0.25337, 0.11862, 0.28697, 0.11176, 0.31833, 0.09662, 0.34461, 0.07459],
4143
+ [0.34461, 0.07459, 0.34649, 0.07299, 0.34836, 0.07137, 0.35209, 0.06806]
4144
+ ]);
4145
+ var cookie9SidedShape = createShape([
4146
+ [0.39144, 0.04182, 0.39684, 0.03735, 0.39953, 0.03513, 0.402, 0.03326],
4147
+ [0.402, 0.03326, 0.45981, -0.01109, 0.54019, -0.01109, 0.598, 0.03326],
4148
+ [0.598, 0.03326, 0.60047, 0.03513, 0.60316, 0.03735, 0.60856, 0.04182],
4149
+ [0.60856, 0.04182, 0.61097, 0.04379, 0.61216, 0.04479, 0.61334, 0.04576],
4150
+ [0.61334, 0.04576, 0.64056, 0.06743, 0.67404, 0.07974, 0.70881, 0.08085],
4151
+ [0.70881, 0.08085, 0.71031, 0.08088, 0.71187, 0.08091, 0.71497, 0.08094],
4152
+ [0.71497, 0.08094, 0.72194, 0.08104, 0.72544, 0.08107, 0.7285, 0.08123],
4153
+ [0.7285, 0.08123, 0.80112, 0.08494, 0.86243, 0.13694, 0.87865, 0.20854],
4154
+ [0.87865, 0.20854, 0.87934, 0.21157, 0.88, 0.21504, 0.88131, 0.22194],
4155
+ [0.88131, 0.22194, 0.88187, 0.22504, 0.88215, 0.22657, 0.88247, 0.22807],
4156
+ [0.88247, 0.22807, 0.88956, 0.26244, 0.90737, 0.29357, 0.93325, 0.31694],
4157
+ [0.93325, 0.31694, 0.9344, 0.31797, 0.93556, 0.319, 0.93793, 0.32104],
4158
+ [0.93793, 0.32104, 0.94321, 0.32563, 0.94584, 0.32794, 0.94809, 0.33007],
4159
+ [0.94809, 0.33007, 1.00137, 0.38004, 1.01528, 0.45972, 0.98215, 0.5251],
4160
+ [0.98215, 0.5251, 0.98075, 0.52788, 0.97903, 0.53094, 0.97562, 0.53707],
4161
+ [0.97562, 0.53707, 0.97409, 0.53982, 0.97334, 0.54119, 0.97262, 0.54253],
4162
+ [0.97262, 0.54253, 0.9562, 0.57351, 0.95003, 0.60889, 0.955, 0.6436],
4163
+ [0.955, 0.6436, 0.95521, 0.64513, 0.95546, 0.64666, 0.95596, 0.64975],
4164
+ [0.95596, 0.64975, 0.95709, 0.65672, 0.95765, 0.66019, 0.95803, 0.66328],
4165
+ [0.95803, 0.66328, 0.96703, 0.73616, 0.927, 0.80622, 0.86003, 0.83478],
4166
+ [0.86003, 0.83478, 0.85718, 0.836, 0.8539, 0.83725, 0.8474, 0.83975],
4167
+ [0.8474, 0.83975, 0.8445, 0.84084, 0.84303, 0.84141, 0.84162, 0.84197],
4168
+ [0.84162, 0.84197, 0.80937, 0.855, 0.78212, 0.87812, 0.76381, 0.90794],
4169
+ [0.76381, 0.90794, 0.76303, 0.90925, 0.76225, 0.91059, 0.76065, 0.91328],
4170
+ [0.76065, 0.91328, 0.75709, 0.91934, 0.75531, 0.92237, 0.75362, 0.925],
4171
+ [0.75362, 0.925, 0.71415, 0.98665, 0.63894, 1.01434, 0.56944, 0.99272],
4172
+ [0.56944, 0.99272, 0.5665, 0.99181, 0.56319, 0.99065, 0.55662, 0.98831],
4173
+ [0.55662, 0.98831, 0.55369, 0.98728, 0.55222, 0.98675, 0.55078, 0.98628],
4174
+ [0.55078, 0.98628, 0.51782, 0.97531, 0.48218, 0.97531, 0.44922, 0.98628],
4175
+ [0.44922, 0.98628, 0.44778, 0.98675, 0.44631, 0.98728, 0.44338, 0.98831],
4176
+ [0.44338, 0.98831, 0.43681, 0.99065, 0.4335, 0.99181, 0.43056, 0.99272],
4177
+ [0.43056, 0.99272, 0.36106, 1.01434, 0.28585, 0.98665, 0.24638, 0.925],
4178
+ [0.24638, 0.925, 0.24469, 0.92237, 0.24291, 0.91934, 0.23935, 0.91328],
4179
+ [0.23935, 0.91328, 0.23775, 0.91059, 0.23697, 0.90925, 0.23619, 0.90794],
4180
+ [0.23619, 0.90794, 0.21788, 0.87812, 0.19063, 0.855, 0.15838, 0.84197],
4181
+ [0.15838, 0.84197, 0.15697, 0.84141, 0.1555, 0.84084, 0.1526, 0.83975],
4182
+ [0.1526, 0.83975, 0.1461, 0.83725, 0.14282, 0.836, 0.13997, 0.83478],
4183
+ [0.13997, 0.83478, 0.073, 0.80622, 0.03297, 0.73616, 0.04197, 0.66328],
4184
+ [0.04197, 0.66328, 0.04235, 0.66019, 0.04291, 0.65672, 0.04404, 0.64975],
4185
+ [0.04404, 0.64975, 0.04454, 0.64666, 0.04479, 0.64513, 0.045, 0.6436],
4186
+ [0.045, 0.6436, 0.04997, 0.60889, 0.0438, 0.57351, 0.02738, 0.54253],
4187
+ [0.02738, 0.54253, 0.02666, 0.54119, 0.02591, 0.53982, 0.02438, 0.53707],
4188
+ [0.02438, 0.53707, 0.02097, 0.53094, 0.01925, 0.52788, 0.01785, 0.5251],
4189
+ [0.01785, 0.5251, -0.01528, 0.45972, -137e-5, 0.38004, 0.05191, 0.33007],
4190
+ [0.05191, 0.33007, 0.05416, 0.32794, 0.05679, 0.32563, 0.06207, 0.32104],
4191
+ [0.06207, 0.32104, 0.06444, 0.319, 0.0656, 0.31797, 0.06675, 0.31694],
4192
+ [0.06675, 0.31694, 0.0927, 0.29347, 0.11049, 0.26234, 0.11753, 0.22807],
4193
+ [0.11753, 0.22807, 0.11785, 0.22657, 0.11813, 0.22504, 0.11869, 0.22194],
4194
+ [0.11869, 0.22194, 0.12, 0.21504, 0.12066, 0.21157, 0.12135, 0.20854],
4195
+ [0.12135, 0.20854, 0.13757, 0.13694, 0.19888, 0.08494, 0.2715, 0.08123],
4196
+ [0.2715, 0.08123, 0.27456, 0.08107, 0.27806, 0.08104, 0.28503, 0.08094],
4197
+ [0.28503, 0.08094, 0.28813, 0.08091, 0.28969, 0.08088, 0.29119, 0.08085],
4198
+ [0.29119, 0.08085, 0.32596, 0.07974, 0.35944, 0.06743, 0.38666, 0.04576],
4199
+ [0.38666, 0.04576, 0.38784, 0.04479, 0.38903, 0.04379, 0.39144, 0.04182]
4200
+ ]);
4201
+ var slantedShape = createShape([
4202
+ [0.04911, 0.28294, 0.05715, 0.20613, 0.06118, 0.16772, 0.07595, 0.13743],
4203
+ [0.07595, 0.13743, 0.09732, 0.09358, 0.13462, 0.05972, 0.18009, 0.04288],
4204
+ [0.18009, 0.04288, 0.21151, 0.03125, 0.24979, 0.03125, 0.32635, 0.03125],
4205
+ [0.32635, 0.03125, 0.45521, 0.03125, 0.58407, 0.03125, 0.71293, 0.03125],
4206
+ [0.71293, 0.03125, 0.80551, 0.03125, 0.85181, 0.03125, 0.88715, 0.04642],
4207
+ [0.88715, 0.04642, 0.93832, 0.06838, 0.97725, 0.11203, 0.99352, 0.16569],
4208
+ [0.99352, 0.16569, 1.00476, 0.20272, 0.9999, 0.24916, 0.99017, 0.34206],
4209
+ [0.99017, 0.34206, 0.97708, 0.46706, 0.96398, 0.59206, 0.95089, 0.71706],
4210
+ [0.95089, 0.71706, 0.94285, 0.79387, 0.93883, 0.83228, 0.92405, 0.86256],
4211
+ [0.92405, 0.86256, 0.90268, 0.90641, 0.86538, 0.94028, 0.81991, 0.95712],
4212
+ [0.81991, 0.95712, 0.78849, 0.96875, 0.75021, 0.96875, 0.67365, 0.96875],
4213
+ [0.67365, 0.96875, 0.54479, 0.96875, 0.41593, 0.96875, 0.28707, 0.96875],
4214
+ [0.28707, 0.96875, 0.19449, 0.96875, 0.14819, 0.96875, 0.11285, 0.95359],
4215
+ [0.11285, 0.95359, 0.06169, 0.93162, 0.02275, 0.88797, 648e-5, 0.83431],
4216
+ [648e-5, 0.83431, -476e-5, 0.79728, 1e-4, 0.75084, 983e-5, 0.65794],
4217
+ [983e-5, 0.65794, 0.02292, 0.53294, 0.03602, 0.40794, 0.04911, 0.28294]
4218
+ ]);
4219
+ var softBoomShape = createShape([
4220
+ [0.54668, 0.26546, 0.61712, -0.08849, 0.38296, -0.08849, 0.45337, 0.26546],
4221
+ [0.45337, 0.26546, 0.38296, -0.08849, 0.16664, 11e-4, 0.36715, 0.30118],
4222
+ [0.36715, 0.30118, 0.16664, 11e-4, 11e-4, 0.16665, 0.30118, 0.36715],
4223
+ [0.30118, 0.36715, 11e-4, 0.16665, -0.08849, 0.38296, 0.26546, 0.45334],
4224
+ [0.26546, 0.45334, -0.08849, 0.38293, -0.08849, 0.61706, 0.26546, 0.54665],
4225
+ [0.26546, 0.54665, -0.08849, 0.61706, 114e-5, 0.83334, 0.30118, 0.63284],
4226
+ [0.30118, 0.63284, 114e-5, 0.83334, 0.16668, 0.9989, 0.36715, 0.69881],
4227
+ [0.36715, 0.69881, 0.16664, 0.99884, 0.38296, 1.08843, 0.45334, 0.73452],
4228
+ [0.45334, 0.73452, 0.38293, 1.08849, 0.61706, 1.08849, 0.54665, 0.73452],
4229
+ [0.54665, 0.73452, 0.61706, 1.08849, 0.83334, 0.99884, 0.63284, 0.69881],
4230
+ [0.63284, 0.69881, 0.83334, 0.99884, 0.9989, 0.83331, 0.69881, 0.63284],
4231
+ [0.69881, 0.63284, 0.99884, 0.83334, 1.08843, 0.61702, 0.73452, 0.54665],
4232
+ [0.73452, 0.54665, 1.08849, 0.61706, 1.08849, 0.38293, 0.73452, 0.45334],
4233
+ [0.73452, 0.45334, 1.08849, 0.38293, 0.99884, 0.16665, 0.69881, 0.36715],
4234
+ [0.69881, 0.36715, 0.99884, 0.16665, 0.83331, 11e-4, 0.63284, 0.30118],
4235
+ [0.63284, 0.30118, 0.83334, 114e-5, 0.61702, -0.08845, 0.54665, 0.26546],
4236
+ [0.54665, 0.26546, 0.54666, 0.26546, 0.54667, 0.26546, 0.54668, 0.26546]
4237
+ ]);
4238
+ var softBurstShape = createShape([
4239
+ [0.45359, 0.0247, 0.47494, -823e-5, 0.52506, -823e-5, 0.54641, 0.0247],
4240
+ [0.54641, 0.0247, 0.56348, 0.05101, 0.58055, 0.07733, 0.59763, 0.10364],
4241
+ [0.59763, 0.10364, 0.61166, 0.12529, 0.64, 0.1341, 0.66466, 0.12447],
4242
+ [0.66466, 0.12447, 0.69464, 0.11278, 0.72462, 0.10108, 0.7546, 0.08939],
4243
+ [0.7546, 0.08939, 0.79213, 0.07475, 0.83266, 0.10291, 0.82972, 0.14156],
4244
+ [0.82972, 0.14156, 0.82736, 0.17245, 0.82499, 0.20334, 0.82263, 0.23422],
4245
+ [0.82263, 0.23422, 0.82066, 0.25963, 0.83816, 0.28266, 0.86403, 0.28875],
4246
+ [0.86403, 0.28875, 0.89548, 0.29614, 0.92693, 0.30352, 0.95838, 0.31091],
4247
+ [0.95838, 0.31091, 0.99772, 0.32016, 1.01322, 0.36572, 0.98707, 0.39535],
4248
+ [0.98707, 0.39535, 0.96617, 0.41899, 0.94527, 0.44264, 0.92438, 0.46629],
4249
+ [0.92438, 0.46629, 0.90719, 0.48575, 0.90719, 0.51425, 0.92438, 0.53372],
4250
+ [0.92438, 0.53372, 0.94527, 0.55737, 0.96617, 0.58102, 0.98707, 0.60466],
4251
+ [0.98707, 0.60466, 1.01322, 0.63429, 0.99772, 0.67985, 0.95838, 0.6891],
4252
+ [0.95838, 0.6891, 0.92693, 0.69648, 0.89548, 0.70387, 0.86403, 0.71126],
4253
+ [0.86403, 0.71126, 0.83816, 0.71735, 0.82066, 0.74038, 0.82263, 0.76579],
4254
+ [0.82263, 0.76579, 0.82499, 0.79667, 0.82736, 0.82756, 0.82972, 0.85844],
4255
+ [0.82972, 0.85844, 0.83266, 0.8971, 0.79213, 0.92526, 0.7546, 0.91063],
4256
+ [0.7546, 0.91063, 0.72462, 0.89893, 0.69464, 0.88724, 0.66466, 0.87554],
4257
+ [0.66466, 0.87554, 0.64, 0.86591, 0.61166, 0.87473, 0.59763, 0.89638],
4258
+ [0.59763, 0.89638, 0.58055, 0.92269, 0.56348, 0.94901, 0.54641, 0.97532],
4259
+ [0.54641, 0.97532, 0.52506, 1.00823, 0.47494, 1.00823, 0.45359, 0.97532],
4260
+ [0.45359, 0.97532, 0.43652, 0.94901, 0.41945, 0.92269, 0.40237, 0.89638],
4261
+ [0.40237, 0.89638, 0.38834, 0.87473, 0.36, 0.86591, 0.33534, 0.87554],
4262
+ [0.33534, 0.87554, 0.30536, 0.88724, 0.27538, 0.89893, 0.2454, 0.91063],
4263
+ [0.2454, 0.91063, 0.20787, 0.92526, 0.16734, 0.8971, 0.17028, 0.85844],
4264
+ [0.17028, 0.85844, 0.17264, 0.82756, 0.17501, 0.79667, 0.17737, 0.76579],
4265
+ [0.17737, 0.76579, 0.17934, 0.74038, 0.16184, 0.71735, 0.13597, 0.71126],
4266
+ [0.13597, 0.71126, 0.10452, 0.70387, 0.07307, 0.69648, 0.04162, 0.6891],
4267
+ [0.04162, 0.6891, 228e-5, 0.67985, -0.01322, 0.63429, 0.01293, 0.60466],
4268
+ [0.01293, 0.60466, 0.03383, 0.58102, 0.05473, 0.55737, 0.07562, 0.53372],
4269
+ [0.07562, 0.53372, 0.09281, 0.51425, 0.09281, 0.48575, 0.07562, 0.46629],
4270
+ [0.07562, 0.46629, 0.05473, 0.44264, 0.03383, 0.41899, 0.01293, 0.39535],
4271
+ [0.01293, 0.39535, -0.01322, 0.36572, 228e-5, 0.32016, 0.04162, 0.31091],
4272
+ [0.04162, 0.31091, 0.07307, 0.30352, 0.10452, 0.29614, 0.13597, 0.28875],
4273
+ [0.13597, 0.28875, 0.16184, 0.28266, 0.17934, 0.25963, 0.17737, 0.23422],
4274
+ [0.17737, 0.23422, 0.17501, 0.20334, 0.17264, 0.17245, 0.17028, 0.14156],
4275
+ [0.17028, 0.14156, 0.16734, 0.10291, 0.20787, 0.07475, 0.2454, 0.08939],
4276
+ [0.2454, 0.08939, 0.27538, 0.10108, 0.30536, 0.11278, 0.33534, 0.12447],
4277
+ [0.33534, 0.12447, 0.36, 0.1341, 0.38834, 0.12529, 0.40237, 0.10364],
4278
+ [0.40237, 0.10364, 0.41945, 0.07733, 0.43652, 0.05101, 0.45359, 0.0247]
4279
+ ]);
4280
+ var squareShape = createShape([
4281
+ [1, 0.5375, 1, 0.67725, 1, 0.74712, 0.97806, 0.80253],
4282
+ [0.97806, 0.80253, 0.94628, 0.88278, 0.88278, 0.94628, 0.80253, 0.97806],
4283
+ [0.80253, 0.97806, 0.74713, 1, 0.67725, 1, 0.5375, 1],
4284
+ [0.5375, 1, 0.5125, 1, 0.4875, 1, 0.4625, 1],
4285
+ [0.4625, 1, 0.32275, 1, 0.25288, 1, 0.19747, 0.97806],
4286
+ [0.19747, 0.97806, 0.11722, 0.94628, 0.05372, 0.88278, 0.02194, 0.80253],
4287
+ [0.02194, 0.80253, 0, 0.74713, 0, 0.67725, 0, 0.5375],
4288
+ [0, 0.5375, 0, 0.5125, 0, 0.4875, 0, 0.4625],
4289
+ [0, 0.4625, 0, 0.32275, 0, 0.25288, 0.02194, 0.19747],
4290
+ [0.02194, 0.19747, 0.0537, 0.11723, 0.11723, 0.05371, 0.19747, 0.02194],
4291
+ [0.19747, 0.02194, 0.25288, 0, 0.32275, 0, 0.4625, 0],
4292
+ [0.4625, 0, 0.4875, 0, 0.5125, 0, 0.5375, 0],
4293
+ [0.5375, 0, 0.67725, 0, 0.74712, 0, 0.80253, 0.02194],
4294
+ [0.80253, 0.02194, 0.88277, 0.05371, 0.9463, 0.11723, 0.97806, 0.19747],
4295
+ [0.97806, 0.19747, 1, 0.25288, 1, 0.32275, 1, 0.4625],
4296
+ [1, 0.4625, 1, 0.4875, 1, 0.5125, 1, 0.5375]
4297
+ ]);
4298
+ var sunnyShape = createShape([
4299
+ [0.77016, 0.1213, 0.80126, 0.12342, 0.81681, 0.12448, 0.82938, 0.12995],
4300
+ [0.82938, 0.12995, 0.84756, 0.13791, 0.86208, 0.15244, 0.87004, 0.17062],
4301
+ [0.87004, 0.17062, 0.87554, 0.18318, 0.8766, 0.19874, 0.87871, 0.22983],
4302
+ [0.87871, 0.22983, 0.88031, 0.25348, 0.88192, 0.27714, 0.88353, 0.3008],
4303
+ [0.88353, 0.3008, 0.88439, 0.31338, 0.88481, 0.31968, 0.88618, 0.32568],
4304
+ [0.88618, 0.32568, 0.88816, 0.33436, 0.89159, 0.34264, 0.89633, 0.35018],
4305
+ [0.89633, 0.35018, 0.89961, 0.35541, 0.90376, 0.36015, 0.91204, 0.36965],
4306
+ [0.91204, 0.36965, 0.92764, 0.38751, 0.94323, 0.40537, 0.95882, 0.42324],
4307
+ [0.95882, 0.42324, 0.97932, 0.44674, 0.98957, 0.45847, 0.99457, 0.47124],
4308
+ [0.99457, 0.47124, 1.0018, 0.48973, 1.0018, 0.51027, 0.99457, 0.52876],
4309
+ [0.99457, 0.52876, 0.98957, 0.54153, 0.97932, 0.55326, 0.95882, 0.57676],
4310
+ [0.95882, 0.57676, 0.94323, 0.59463, 0.92764, 0.61249, 0.91204, 0.63035],
4311
+ [0.91204, 0.63035, 0.90376, 0.63985, 0.89961, 0.64459, 0.89633, 0.64982],
4312
+ [0.89633, 0.64982, 0.89159, 0.65736, 0.88816, 0.66564, 0.88618, 0.67432],
4313
+ [0.88618, 0.67432, 0.88481, 0.68032, 0.88439, 0.68662, 0.88353, 0.6992],
4314
+ [0.88353, 0.6992, 0.88192, 0.72286, 0.88031, 0.74652, 0.87871, 0.77017],
4315
+ [0.87871, 0.77017, 0.8766, 0.80126, 0.87554, 0.81682, 0.87004, 0.82938],
4316
+ [0.87004, 0.82938, 0.86208, 0.84756, 0.84756, 0.86209, 0.82938, 0.87005],
4317
+ [0.82938, 0.87005, 0.81681, 0.87552, 0.80126, 0.87658, 0.77016, 0.8787],
4318
+ [0.77016, 0.8787, 0.7465, 0.88031, 0.72285, 0.88192, 0.69919, 0.88352],
4319
+ [0.69919, 0.88352, 0.68661, 0.88438, 0.68032, 0.88482, 0.67431, 0.88617],
4320
+ [0.67431, 0.88617, 0.66563, 0.88815, 0.65735, 0.89158, 0.64981, 0.89632],
4321
+ [0.64981, 0.89632, 0.6446, 0.89961, 0.63985, 0.90376, 0.63035, 0.91205],
4322
+ [0.63035, 0.91205, 0.61248, 0.92764, 0.59462, 0.94323, 0.57675, 0.95882],
4323
+ [0.57675, 0.95882, 0.55327, 0.97932, 0.54153, 0.98955, 0.52875, 0.99455],
4324
+ [0.52875, 0.99455, 0.51027, 1.00182, 0.48973, 1.00182, 0.47125, 0.99455],
4325
+ [0.47125, 0.99455, 0.45847, 0.98955, 0.44673, 0.97932, 0.42325, 0.95882],
4326
+ [0.42325, 0.95882, 0.40538, 0.94323, 0.38752, 0.92764, 0.36965, 0.91205],
4327
+ [0.36965, 0.91205, 0.36015, 0.90376, 0.3554, 0.89961, 0.35019, 0.89632],
4328
+ [0.35019, 0.89632, 0.34265, 0.89158, 0.33437, 0.88815, 0.32569, 0.88617],
4329
+ [0.32569, 0.88617, 0.31968, 0.88482, 0.31339, 0.88438, 0.30081, 0.88352],
4330
+ [0.30081, 0.88352, 0.27715, 0.88192, 0.2535, 0.88031, 0.22984, 0.8787],
4331
+ [0.22984, 0.8787, 0.19874, 0.87658, 0.18319, 0.87552, 0.17062, 0.87005],
4332
+ [0.17062, 0.87005, 0.15244, 0.86209, 0.13792, 0.84756, 0.12996, 0.82938],
4333
+ [0.12996, 0.82938, 0.12446, 0.81682, 0.1234, 0.80126, 0.12129, 0.77017],
4334
+ [0.12129, 0.77017, 0.11968, 0.74652, 0.11807, 0.72286, 0.11647, 0.6992],
4335
+ [0.11647, 0.6992, 0.11561, 0.68662, 0.11519, 0.68032, 0.11382, 0.67432],
4336
+ [0.11382, 0.67432, 0.11185, 0.66564, 0.10841, 0.65736, 0.10367, 0.64982],
4337
+ [0.10367, 0.64982, 0.10039, 0.64459, 0.09624, 0.63985, 0.08796, 0.63035],
4338
+ [0.08796, 0.63035, 0.07236, 0.61249, 0.05677, 0.59463, 0.04118, 0.57676],
4339
+ [0.04118, 0.57676, 0.02068, 0.55326, 0.01043, 0.54153, 543e-5, 0.52876],
4340
+ [543e-5, 0.52876, -18e-4, 0.51027, -18e-4, 0.48973, 543e-5, 0.47124],
4341
+ [543e-5, 0.47124, 0.01043, 0.45847, 0.02068, 0.44674, 0.04118, 0.42324],
4342
+ [0.04118, 0.42324, 0.05677, 0.40537, 0.07236, 0.38751, 0.08796, 0.36965],
4343
+ [0.08796, 0.36965, 0.09624, 0.36015, 0.10039, 0.35541, 0.10367, 0.35018],
4344
+ [0.10367, 0.35018, 0.10841, 0.34264, 0.11184, 0.33436, 0.11382, 0.32568],
4345
+ [0.11382, 0.32568, 0.11519, 0.31968, 0.11561, 0.31338, 0.11647, 0.3008],
4346
+ [0.11647, 0.3008, 0.11808, 0.27714, 0.11969, 0.25348, 0.12129, 0.22983],
4347
+ [0.12129, 0.22983, 0.1234, 0.19874, 0.12446, 0.18318, 0.12996, 0.17062],
4348
+ [0.12996, 0.17062, 0.13792, 0.15244, 0.15244, 0.13791, 0.17062, 0.12995],
4349
+ [0.17062, 0.12995, 0.18319, 0.12448, 0.19874, 0.12342, 0.22984, 0.1213],
4350
+ [0.22984, 0.1213, 0.2535, 0.11969, 0.27716, 0.11808, 0.30081, 0.11648],
4351
+ [0.30081, 0.11648, 0.31339, 0.11562, 0.31968, 0.11518, 0.32569, 0.11383],
4352
+ [0.32569, 0.11383, 0.33437, 0.11185, 0.34266, 0.10842, 0.35019, 0.10368],
4353
+ [0.35019, 0.10368, 0.3554, 0.10039, 0.36015, 0.09624, 0.36965, 0.08795],
4354
+ [0.36965, 0.08795, 0.38752, 0.07236, 0.40538, 0.05677, 0.42325, 0.04118],
4355
+ [0.42325, 0.04118, 0.44673, 0.02068, 0.45847, 0.01045, 0.47125, 545e-5],
4356
+ [0.47125, 545e-5, 0.48973, -182e-5, 0.51027, -182e-5, 0.52875, 545e-5],
4357
+ [0.52875, 545e-5, 0.54153, 0.01045, 0.55327, 0.02068, 0.57675, 0.04118],
4358
+ [0.57675, 0.04118, 0.59462, 0.05677, 0.61248, 0.07236, 0.63035, 0.08795],
4359
+ [0.63035, 0.08795, 0.63985, 0.09624, 0.6446, 0.10039, 0.64981, 0.10368],
4360
+ [0.64981, 0.10368, 0.65735, 0.10842, 0.66563, 0.11185, 0.67431, 0.11383],
4361
+ [0.67431, 0.11383, 0.68032, 0.11518, 0.68661, 0.11562, 0.69919, 0.11648],
4362
+ [0.69919, 0.11648, 0.72285, 0.11808, 0.7465, 0.11969, 0.77016, 0.1213]
4363
+ ]);
4364
+ var triangleShape = createShape([
4365
+ [0.33058, 0.2095, 0.37847, 0.12601, 0.40242, 0.08427, 0.43146, 0.06665],
4366
+ [0.43146, 0.06665, 0.47358, 0.04108, 0.52643, 0.04108, 0.56854, 0.06665],
4367
+ [0.56854, 0.06665, 0.59758, 0.08427, 0.62153, 0.12601, 0.66943, 0.2095],
4368
+ [0.66943, 0.2095, 0.75568, 0.35983, 0.84194, 0.51017, 0.92819, 0.66051],
4369
+ [0.92819, 0.66051, 0.97563, 0.7432, 0.99935, 0.78452, 0.99998, 0.81829],
4370
+ [0.99998, 0.81829, 1.00088, 0.86728, 0.97451, 0.91273, 0.93153, 0.93626],
4371
+ [0.93153, 0.93626, 0.90188, 0.95253, 0.85417, 0.95253, 0.75877, 0.95253],
4372
+ [0.75877, 0.95253, 0.58626, 0.95253, 0.41375, 0.95253, 0.24124, 0.95253],
4373
+ [0.24124, 0.95253, 0.14583, 0.95253, 0.09812, 0.95253, 0.06847, 0.93626],
4374
+ [0.06847, 0.93626, 0.02548, 0.91274, -89e-5, 0.86729, 2e-5, 0.81829],
4375
+ [2e-5, 0.81829, 65e-5, 0.78452, 0.02437, 0.7432, 0.07181, 0.66051],
4376
+ [0.07181, 0.66051, 0.15807, 0.51017, 0.24432, 0.35983, 0.33058, 0.2095]
4377
+ ]);
4378
+ var verySunnyShape = createShape([
4379
+ [0.42725, 0.04123, 0.46018, -0.01374, 0.53981, -0.01374, 0.57275, 0.04123],
4380
+ [0.57275, 0.04123, 0.58508, 0.06182, 0.59741, 0.08241, 0.60974, 0.10301],
4381
+ [0.60974, 0.10301, 0.62896, 0.13504, 0.66687, 0.15076, 0.70309, 0.14166],
4382
+ [0.70309, 0.14166, 0.72638, 0.13583, 0.74967, 0.13, 0.77296, 0.12416],
4383
+ [0.77296, 0.12416, 0.83512, 0.1086, 0.8914, 0.16488, 0.87583, 0.22704],
4384
+ [0.87583, 0.22704, 0.87, 0.25033, 0.86417, 0.27362, 0.85833, 0.29691],
4385
+ [0.85833, 0.29691, 0.84924, 0.33313, 0.86496, 0.37103, 0.89699, 0.39025],
4386
+ [0.89699, 0.39025, 0.91758, 0.40258, 0.93818, 0.41492, 0.95877, 0.42725],
4387
+ [0.95877, 0.42725, 1.01374, 0.46019, 1.01374, 0.53981, 0.95877, 0.57275],
4388
+ [0.95877, 0.57275, 0.93818, 0.58508, 0.91758, 0.59742, 0.89699, 0.60975],
4389
+ [0.89699, 0.60975, 0.86496, 0.62897, 0.84924, 0.66687, 0.85833, 0.70309],
4390
+ [0.85833, 0.70309, 0.86417, 0.72638, 0.87, 0.74967, 0.87583, 0.77296],
4391
+ [0.87583, 0.77296, 0.8914, 0.83512, 0.83512, 0.8914, 0.77296, 0.87584],
4392
+ [0.77296, 0.87584, 0.74967, 0.87, 0.72638, 0.86417, 0.70309, 0.85834],
4393
+ [0.70309, 0.85834, 0.66687, 0.84924, 0.62896, 0.86496, 0.60974, 0.89699],
4394
+ [0.60974, 0.89699, 0.59741, 0.91759, 0.58508, 0.93818, 0.57275, 0.95877],
4395
+ [0.57275, 0.95877, 0.53981, 1.01374, 0.46018, 1.01374, 0.42725, 0.95877],
4396
+ [0.42725, 0.95877, 0.41491, 0.93818, 0.40258, 0.91759, 0.39025, 0.89699],
4397
+ [0.39025, 0.89699, 0.37103, 0.86496, 0.33312, 0.84924, 0.29691, 0.85834],
4398
+ [0.29691, 0.85834, 0.27361, 0.86417, 0.25031, 0.87, 0.22702, 0.87584],
4399
+ [0.22702, 0.87584, 0.16489, 0.8914, 0.10859, 0.83512, 0.12416, 0.77296],
4400
+ [0.12416, 0.77296, 0.12999, 0.74967, 0.13583, 0.72638, 0.14167, 0.70309],
4401
+ [0.14167, 0.70309, 0.15075, 0.66687, 0.13505, 0.62897, 0.103, 0.60975],
4402
+ [0.103, 0.60975, 0.08241, 0.59742, 0.06181, 0.58508, 0.04121, 0.57275],
4403
+ [0.04121, 0.57275, -0.01373, 0.53981, -0.01373, 0.46019, 0.04121, 0.42725],
4404
+ [0.04121, 0.42725, 0.06181, 0.41492, 0.08241, 0.40258, 0.103, 0.39025],
4405
+ [0.103, 0.39025, 0.13505, 0.37103, 0.15075, 0.33313, 0.14167, 0.29691],
4406
+ [0.14167, 0.29691, 0.13583, 0.27362, 0.12999, 0.25033, 0.12416, 0.22704],
4407
+ [0.12416, 0.22704, 0.10859, 0.16488, 0.16489, 0.1086, 0.22702, 0.12416],
4408
+ [0.22702, 0.12416, 0.25031, 0.13, 0.27361, 0.13583, 0.29691, 0.14166],
4409
+ [0.29691, 0.14166, 0.33312, 0.15076, 0.37103, 0.13504, 0.39025, 0.10301],
4410
+ [0.39025, 0.10301, 0.40258, 0.08241, 0.41491, 0.06182, 0.42725, 0.04123]
4411
+ ]);
4412
+ function reversePolygon(polygon) {
4413
+ const reversedFeatures = polygon.features.map((f) => {
4414
+ const reversedCubics = f.cubics.map((c) => c.reverse()).reverse();
4415
+ if (f.type === "corner") {
4416
+ return cornerFeature(reversedCubics, f.convex);
4417
+ } else {
4418
+ return edgeFeature(reversedCubics);
4419
+ }
4420
+ }).reverse();
4421
+ return RoundedPolygon.fromFeatures(
4422
+ reversedFeatures,
4423
+ polygon.centerX,
4424
+ polygon.centerY
4425
+ );
4426
+ }
4427
+ function rotate180(polygon) {
4428
+ return polygon.transformed((x, y) => [1 - x, 1 - y]);
4429
+ }
4430
+ function flipV(polygon) {
4431
+ const flipped = polygon.transformed((x, y) => [x, 1 - y]);
4432
+ return reversePolygon(flipped);
4433
+ }
4434
+ var MD3Shapes = {
4435
+ arch: flipV(archShape),
4436
+ arrow: flipV(arrowShape),
4437
+ boom: boomShape,
4438
+ bun: bunShape,
4439
+ burst: burstShape,
4440
+ circle: circleShape,
4441
+ clamshell: clamshellShape,
4442
+ diamond: diamondShape,
4443
+ fan: rotate180(fanShape),
4444
+ flower: flowerShape,
4445
+ gem: flipV(gemShape),
4446
+ ghostish: flipV(ghostishShape),
4447
+ heart: flipV(heartShape),
4448
+ clover4Leaf: clover4LeafShape,
4449
+ clover8Leaf: clover8LeafShape,
4450
+ oval: flipV(ovalShape),
4451
+ pentagon: flipV(pentagonShape),
4452
+ pill: flipV(pillShape),
4453
+ pixelCircle: pixelCircleShape,
4454
+ pixelTriangle: pixelTriangleShape,
4455
+ puffyDiamond: puffyDiamondShape,
4456
+ puffy: puffyShape,
4457
+ semiCircle: flipV(semiCircleShape),
4458
+ cookie12Sided: cookie12SidedShape,
4459
+ cookie4Sided: cookie4SidedShape,
4460
+ cookie6Sided: cookie6SidedShape,
4461
+ cookie7Sided: cookie7SidedShape,
4462
+ cookie9Sided: cookie9SidedShape,
4463
+ slanted: flipV(slantedShape),
4464
+ softBoom: softBoomShape,
4465
+ softBurst: softBurstShape,
4466
+ square: squareShape,
4467
+ sunny: sunnyShape,
4468
+ triangle: flipV(triangleShape),
4469
+ verySunny: verySunnyShape
4470
+ };
4471
+
4472
+ // src/shapes/render/shape-rendering.ts
4473
+ function toSvgPath(cubics, width = 1, height = 1) {
4474
+ if (cubics.length === 0) return "";
4475
+ const paddingX = width * 0.015;
4476
+ const paddingY = height * 0.015;
4477
+ const sx = width - 2 * paddingX;
4478
+ const sy = height - 2 * paddingY;
4479
+ const flipY = (y) => paddingY + sy * (1 - y);
4480
+ const parts = [
4481
+ `M ${fmt(paddingX + cubics[0].anchor0X * sx)} ${fmt(flipY(cubics[0].anchor0Y))}`
4482
+ ];
4483
+ for (const c of cubics) {
4484
+ parts.push(
4485
+ `C ${fmt(paddingX + c.control0X * sx)} ${fmt(flipY(c.control0Y))},${fmt(paddingX + c.control1X * sx)} ${fmt(flipY(c.control1Y))},${fmt(paddingX + c.anchor1X * sx)} ${fmt(flipY(c.anchor1Y))}`
4486
+ );
4487
+ }
4488
+ parts.push("Z");
4489
+ return parts.join(" ");
4490
+ }
4491
+ function toClipPath(polygon, width, height) {
4492
+ const pathData = toSvgPath(polygon.cubics, width, height);
4493
+ return `path('${pathData}')`;
4494
+ }
4495
+ function fmt(v) {
4496
+ return Number(v.toFixed(4)).toString();
4497
+ }
4498
+
4499
+ // src/ui/navigation/navigation-shape-utils.ts
4500
+ function getNavigationShapeStyle(shape, width = 56, height = 56) {
4501
+ if (!shape || shape === "pill" || shape === "circle") {
4502
+ return void 0;
4503
+ }
4504
+ const polygon = MD3Shapes[shape];
4505
+ if (!polygon) {
4506
+ return void 0;
4507
+ }
4508
+ return {
4509
+ clipPath: toClipPath(polygon, width, height)
4510
+ };
4511
+ }
4512
+ function isSquareShape(shape) {
4513
+ return Boolean(shape && shape !== "pill");
4514
+ }
4515
+ var NavigationBarContext = React37.createContext({ variant: "flexible" });
2607
4516
  function cloneIconWithFill(icon, selected) {
2608
- if (!React36.isValidElement(icon)) return icon;
4517
+ if (!React37.isValidElement(icon)) return icon;
2609
4518
  if (icon.type === Icon) {
2610
- return React36.cloneElement(
4519
+ return React37.cloneElement(
2611
4520
  icon,
2612
4521
  { fill: selected ? 1 : 0, animateFill: true }
2613
4522
  );
2614
4523
  }
2615
4524
  return icon;
2616
4525
  }
2617
- function ActivePill() {
2618
- const { activeIndicatorTransition } = React36.useContext(NavigationBarContext);
4526
+ function ActivePill({
4527
+ shape = "pill",
4528
+ width = 56,
4529
+ height = 32
4530
+ }) {
4531
+ const { activeIndicatorTransition } = React37.useContext(NavigationBarContext);
4532
+ const shapeStyle = getNavigationShapeStyle(shape, width, height);
2619
4533
  return /* @__PURE__ */ jsx(
2620
4534
  m.div,
2621
4535
  {
2622
- className: "absolute inset-0 bg-m3-secondary-container pointer-events-none",
2623
- style: {
2624
- borderRadius: 9999,
4536
+ className: cn(
4537
+ "bg-m3-secondary-container pointer-events-none",
4538
+ shapeStyle ? "absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 rounded-none" : shape === "circle" ? "absolute inset-0 rounded-full" : "absolute inset-0 rounded-full"
4539
+ ),
4540
+ style: __spreadValues(__spreadValues({
2625
4541
  zIndex: 0
2626
- },
4542
+ }, shapeStyle ? { width, height } : {}), shapeStyle),
2627
4543
  initial: { opacity: 0, scale: 0.5 },
2628
4544
  animate: { opacity: 1, scale: 1 },
2629
4545
  exit: { opacity: 0, scale: 0.5 },
@@ -2631,11 +4547,42 @@ function ActivePill() {
2631
4547
  }
2632
4548
  );
2633
4549
  }
2634
- function HoverStateLayer() {
2635
- return /* @__PURE__ */ jsx("div", { className: "absolute inset-0 rounded-full bg-m3-on-surface opacity-0 group-hover:opacity-[0.08] group-focus-visible:opacity-[0.10] active:opacity-[0.10] transition-opacity duration-200 pointer-events-none z-0" });
4550
+ function HoverStateLayer({
4551
+ shape = "pill",
4552
+ width = 56,
4553
+ height = 32
4554
+ }) {
4555
+ const shapeStyle = getNavigationShapeStyle(shape, width, height);
4556
+ return /* @__PURE__ */ jsx(
4557
+ "div",
4558
+ {
4559
+ className: cn(
4560
+ "bg-m3-on-surface opacity-0 group-hover:opacity-[0.08] group-focus-visible:opacity-[0.10] active:opacity-[0.10] transition-opacity duration-200 pointer-events-none z-0",
4561
+ shapeStyle ? "absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 rounded-none" : shape === "circle" ? "absolute inset-0 rounded-full" : "absolute inset-0 rounded-[16px]"
4562
+ ),
4563
+ style: __spreadValues(__spreadValues({}, shapeStyle ? { width, height } : {}), shapeStyle)
4564
+ }
4565
+ );
2636
4566
  }
2637
- function RippleLayer({ ripples, onRippleDone }) {
2638
- return /* @__PURE__ */ jsx("div", { className: "absolute inset-0 rounded-full overflow-hidden pointer-events-none z-0", children: /* @__PURE__ */ jsx(Ripple, { ripples, onRippleDone }) });
4567
+ function RippleLayer({
4568
+ ripples,
4569
+ onRippleDone,
4570
+ shape = "pill",
4571
+ width = 56,
4572
+ height = 32
4573
+ }) {
4574
+ const shapeStyle = getNavigationShapeStyle(shape, width, height);
4575
+ return /* @__PURE__ */ jsx(
4576
+ "div",
4577
+ {
4578
+ className: cn(
4579
+ "overflow-hidden pointer-events-none z-0",
4580
+ shapeStyle ? "absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 rounded-none" : shape === "circle" ? "absolute inset-0 rounded-full" : "absolute inset-0 rounded-[16px]"
4581
+ ),
4582
+ style: __spreadValues(__spreadValues({}, shapeStyle ? { width, height } : {}), shapeStyle),
4583
+ children: /* @__PURE__ */ jsx(Ripple, { ripples, onRippleDone })
4584
+ }
4585
+ );
2639
4586
  }
2640
4587
  function IconContainer({ selected, badge, children }) {
2641
4588
  return /* @__PURE__ */ jsxs(
@@ -2653,7 +4600,7 @@ function IconContainer({ selected, badge, children }) {
2653
4600
  }
2654
4601
  );
2655
4602
  }
2656
- var NavigationBarItemComponent = React36.forwardRef(
4603
+ var NavigationBarItemComponent = React37.forwardRef(
2657
4604
  ({
2658
4605
  selected,
2659
4606
  icon,
@@ -2661,23 +4608,37 @@ var NavigationBarItemComponent = React36.forwardRef(
2661
4608
  onClick,
2662
4609
  disabled = false,
2663
4610
  badge,
4611
+ shape: shapeProp,
4612
+ shapeSize: shapeSizeProp,
4613
+ hideLabel = false,
2664
4614
  className,
2665
4615
  "aria-label": ariaLabelProp,
2666
4616
  asChild = false,
2667
4617
  children
2668
4618
  }, ref) => {
2669
- var _a;
4619
+ var _a, _b, _c;
2670
4620
  const {
2671
4621
  variant,
2672
4622
  itemLayout,
4623
+ shape: contextShape,
4624
+ labelVisibility: contextLabelVisibility,
4625
+ shapeSize: contextShapeSize,
2673
4626
  itemClassName: contextItemClassName
2674
- } = React36.useContext(NavigationBarContext);
4627
+ } = React37.useContext(NavigationBarContext);
4628
+ const activeShape = (_a = shapeProp != null ? shapeProp : contextShape) != null ? _a : "pill";
4629
+ const isSquare = isSquareShape(activeShape);
4630
+ const resolvedShapeSize = (_b = shapeSizeProp != null ? shapeSizeProp : contextShapeSize) != null ? _b : 56;
2675
4631
  const isForcedHorizontal = itemLayout === "horizontal";
2676
4632
  const isResponsiveHorizontal = (variant === "flexible" || variant === "xr") && itemLayout === void 0;
4633
+ const shouldShowLabel = !hideLabel && (() => {
4634
+ if (contextLabelVisibility === "unlabeled") return false;
4635
+ if (contextLabelVisibility === "auto") return selected;
4636
+ return true;
4637
+ })();
2677
4638
  const { ripples, onPointerDown, removeRipple } = useRippleState({
2678
4639
  disabled
2679
4640
  });
2680
- const handleClick = React36.useCallback(
4641
+ const handleClick = React37.useCallback(
2681
4642
  (e) => {
2682
4643
  if (disabled) {
2683
4644
  e.preventDefault();
@@ -2701,8 +4662,10 @@ var NavigationBarItemComponent = React36.forwardRef(
2701
4662
  contextItemClassName,
2702
4663
  className
2703
4664
  );
4665
+ const iconPillWidth = isSquare ? resolvedShapeSize : 56;
4666
+ const iconPillHeight = isSquare ? resolvedShapeSize : 32;
2704
4667
  if (asChild && children) {
2705
- const child = React36.Children.only(children);
4668
+ const child = React37.Children.only(children);
2706
4669
  const innerContent = /* @__PURE__ */ jsxs(Fragment, { children: [
2707
4670
  /* @__PURE__ */ jsxs(
2708
4671
  "div",
@@ -2710,10 +4673,12 @@ var NavigationBarItemComponent = React36.forwardRef(
2710
4673
  className: cn(
2711
4674
  "relative flex items-center justify-center flex-col gap-y-1 w-full px-1 py-1.5",
2712
4675
  isResponsiveHorizontal && "min-[600px]:flex-row min-[600px]:gap-y-0 min-[600px]:gap-x-1.5 min-[600px]:h-10 min-[600px]:px-4 min-[600px]:py-0 min-[600px]:rounded-full min-[600px]:w-auto",
2713
- isForcedHorizontal && "flex-row gap-y-0 gap-x-1.5 h-10 px-4 py-0 rounded-full w-auto"
4676
+ isForcedHorizontal && "flex-row gap-y-0 gap-x-1.5 h-10 px-4 py-0 rounded-full w-auto",
4677
+ // When label is hidden and not horizontal, remove bottom gap
4678
+ !shouldShowLabel && !isForcedHorizontal && "gap-y-0"
2714
4679
  ),
2715
4680
  children: [
2716
- /* @__PURE__ */ jsxs(
4681
+ !isSquare && /* @__PURE__ */ jsxs(
2717
4682
  "div",
2718
4683
  {
2719
4684
  className: cn(
@@ -2722,9 +4687,18 @@ var NavigationBarItemComponent = React36.forwardRef(
2722
4687
  isForcedHorizontal && "block!"
2723
4688
  ),
2724
4689
  children: [
2725
- /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(ActivePill, {}) }),
2726
- /* @__PURE__ */ jsx(HoverStateLayer, {}),
2727
- /* @__PURE__ */ jsx(RippleLayer, { ripples, onRippleDone: removeRipple })
4690
+ /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(ActivePill, { shape: activeShape, width: 56, height: 40 }) }),
4691
+ /* @__PURE__ */ jsx(HoverStateLayer, { shape: activeShape, width: 56, height: 40 }),
4692
+ /* @__PURE__ */ jsx(
4693
+ RippleLayer,
4694
+ {
4695
+ ripples,
4696
+ onRippleDone: removeRipple,
4697
+ shape: activeShape,
4698
+ width: 56,
4699
+ height: 40
4700
+ }
4701
+ )
2728
4702
  ]
2729
4703
  }
2730
4704
  ),
@@ -2733,23 +4707,47 @@ var NavigationBarItemComponent = React36.forwardRef(
2733
4707
  {
2734
4708
  className: cn(
2735
4709
  "relative flex items-center justify-center shrink-0 z-10",
2736
- "h-8 w-16 mx-auto rounded-full",
2737
- isResponsiveHorizontal && "min-[600px]:size-6 min-[600px]:w-auto min-[600px]:h-auto",
2738
- isForcedHorizontal && "size-6 w-auto h-auto"
4710
+ isSquare ? "mx-auto" : "h-8 w-14 mx-auto rounded-[16px]",
4711
+ !isSquare && isResponsiveHorizontal && "min-[600px]:size-6 min-[600px]:w-auto min-[600px]:h-auto",
4712
+ !isSquare && isForcedHorizontal && "size-6 w-auto h-auto"
2739
4713
  ),
4714
+ style: isSquare ? { width: resolvedShapeSize, height: resolvedShapeSize } : void 0,
2740
4715
  children: [
2741
4716
  /* @__PURE__ */ jsxs(
2742
4717
  "div",
2743
4718
  {
2744
4719
  className: cn(
2745
4720
  "absolute inset-0 z-0",
2746
- isResponsiveHorizontal && "min-[600px]:hidden",
2747
- isForcedHorizontal && "hidden"
4721
+ !isSquare && isResponsiveHorizontal && "min-[600px]:hidden",
4722
+ !isSquare && isForcedHorizontal && "hidden"
2748
4723
  ),
2749
4724
  children: [
2750
- /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(ActivePill, {}) }),
2751
- /* @__PURE__ */ jsx(HoverStateLayer, {}),
2752
- /* @__PURE__ */ jsx(RippleLayer, { ripples, onRippleDone: removeRipple })
4725
+ /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(
4726
+ ActivePill,
4727
+ {
4728
+ shape: activeShape,
4729
+ width: iconPillWidth,
4730
+ height: iconPillHeight
4731
+ }
4732
+ ) }),
4733
+ /* @__PURE__ */ jsx(
4734
+ HoverStateLayer,
4735
+ {
4736
+ shape: activeShape,
4737
+ width: iconPillWidth,
4738
+ height: iconPillHeight
4739
+ }
4740
+ ),
4741
+ /* @__PURE__ */ jsx(
4742
+ RippleLayer,
4743
+ {
4744
+ ripples,
4745
+ onRippleDone: removeRipple,
4746
+ shape: activeShape,
4747
+ width: iconPillWidth,
4748
+ height: iconPillHeight
4749
+ }
4750
+ )
2753
4751
  ]
2754
4752
  }
2755
4753
  ),
@@ -2757,15 +4755,19 @@ var NavigationBarItemComponent = React36.forwardRef(
2757
4755
  ]
2758
4756
  }
2759
4757
  ),
2760
- /* @__PURE__ */ jsx(AnimatePresence, { mode: "popLayout", children: /* @__PURE__ */ jsx(
2761
- "span",
4758
+ label && /* @__PURE__ */ jsx(AnimatePresence, { mode: "popLayout", initial: false, children: shouldShowLabel && /* @__PURE__ */ jsx(
4759
+ m.span,
2762
4760
  {
4761
+ initial: { opacity: 0, height: 0, scale: 0.85, y: -2 },
4762
+ animate: { opacity: 1, height: "auto", scale: 1, y: 0 },
4763
+ exit: { opacity: 0, height: 0, scale: 0.85, y: -2 },
4764
+ transition: SPRING_TRANSITION_EXPRESSIVE,
2763
4765
  className: cn(
2764
- "z-10 transition-all duration-200 truncate px-1",
2765
- selected ? "text-m3-on-surface" : "text-m3-on-surface-variant",
2766
- "font-medium text-[12px] leading-4 tracking-[0.5px]"
4766
+ "z-10 transition-colors duration-200 truncate px-1 inline-block overflow-hidden",
4767
+ selected ? "text-m3-on-surface font-medium" : "text-m3-on-surface-variant font-medium",
4768
+ "text-[12px] leading-4 tracking-[0.5px]"
2767
4769
  ),
2768
- children: (_a = child.props.children) != null ? _a : label
4770
+ children: (_c = child.props.children) != null ? _c : label
2769
4771
  },
2770
4772
  "nav-label"
2771
4773
  ) })
@@ -2781,11 +4783,14 @@ var NavigationBarItemComponent = React36.forwardRef(
2781
4783
  role: "menuitem",
2782
4784
  "aria-current": selected ? "page" : void 0,
2783
4785
  "aria-disabled": disabled ? true : void 0,
2784
- "aria-label": ariaLabelProp || (typeof label === "string" ? label : void 0),
4786
+ "aria-label": (
4787
+ // Always provide aria-label even when label is visually hidden
4788
+ ariaLabelProp || (typeof label === "string" ? label : void 0)
4789
+ ),
2785
4790
  onClick: handleClick,
2786
4791
  onPointerDown,
2787
4792
  className: itemClassName,
2788
- children: React36.cloneElement(child, { children: innerContent })
4793
+ children: React37.cloneElement(child, { children: innerContent })
2789
4794
  }
2790
4795
  );
2791
4796
  }
@@ -2797,7 +4802,10 @@ var NavigationBarItemComponent = React36.forwardRef(
2797
4802
  role: "menuitem",
2798
4803
  "aria-current": selected ? "page" : void 0,
2799
4804
  "aria-disabled": disabled ? true : void 0,
2800
- "aria-label": ariaLabelProp || (typeof label === "string" ? label : void 0),
4805
+ "aria-label": (
4806
+ // Always provide aria-label even when label is visually hidden
4807
+ ariaLabelProp || (typeof label === "string" ? label : void 0)
4808
+ ),
2801
4809
  onClick: handleClick,
2802
4810
  onPointerDown,
2803
4811
  className: itemClassName,
@@ -2808,10 +4816,12 @@ var NavigationBarItemComponent = React36.forwardRef(
2808
4816
  className: cn(
2809
4817
  "relative flex items-center justify-center flex-col gap-y-1 w-full px-1 py-1.5",
2810
4818
  isResponsiveHorizontal && "min-[600px]:flex-row min-[600px]:gap-y-0 min-[600px]:gap-x-1.5 min-[600px]:h-10 min-[600px]:px-4 min-[600px]:py-0 min-[600px]:rounded-full min-[600px]:w-auto",
2811
- isForcedHorizontal && "flex-row gap-y-0 gap-x-1.5 h-10 px-4 py-0 rounded-full w-auto"
4819
+ isForcedHorizontal && "flex-row gap-y-0 gap-x-1.5 h-10 px-4 py-0 rounded-full w-auto",
4820
+ // When label is hidden and not horizontal, remove bottom gap
4821
+ !shouldShowLabel && !isForcedHorizontal && "gap-y-0"
2812
4822
  ),
2813
4823
  children: [
2814
- /* @__PURE__ */ jsxs(
4824
+ !isSquare && /* @__PURE__ */ jsxs(
2815
4825
  "div",
2816
4826
  {
2817
4827
  className: cn(
@@ -2820,9 +4830,18 @@ var NavigationBarItemComponent = React36.forwardRef(
2820
4830
  isForcedHorizontal && "block!"
2821
4831
  ),
2822
4832
  children: [
2823
- /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(ActivePill, {}) }),
2824
- /* @__PURE__ */ jsx(HoverStateLayer, {}),
2825
- /* @__PURE__ */ jsx(RippleLayer, { ripples, onRippleDone: removeRipple })
4833
+ /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(ActivePill, { shape: activeShape, width: 56, height: 40 }) }),
4834
+ /* @__PURE__ */ jsx(HoverStateLayer, { shape: activeShape, width: 56, height: 40 }),
4835
+ /* @__PURE__ */ jsx(
4836
+ RippleLayer,
4837
+ {
4838
+ ripples,
4839
+ onRippleDone: removeRipple,
4840
+ shape: activeShape,
4841
+ width: 56,
4842
+ height: 40
4843
+ }
4844
+ )
2826
4845
  ]
2827
4846
  }
2828
4847
  ),
@@ -2831,23 +4850,47 @@ var NavigationBarItemComponent = React36.forwardRef(
2831
4850
  {
2832
4851
  className: cn(
2833
4852
  "relative flex items-center justify-center shrink-0 z-10",
2834
- "h-8 w-16 mx-auto rounded-full",
2835
- isResponsiveHorizontal && "min-[600px]:size-6 min-[600px]:w-auto min-[600px]:h-auto",
2836
- isForcedHorizontal && "size-6 w-auto h-auto"
4853
+ isSquare ? "mx-auto" : "h-8 w-14 mx-auto rounded-[16px]",
4854
+ !isSquare && isResponsiveHorizontal && "min-[600px]:size-6 min-[600px]:w-auto min-[600px]:h-auto",
4855
+ !isSquare && isForcedHorizontal && "size-6 w-auto h-auto"
2837
4856
  ),
4857
+ style: isSquare ? { width: resolvedShapeSize, height: resolvedShapeSize } : void 0,
2838
4858
  children: [
2839
4859
  /* @__PURE__ */ jsxs(
2840
4860
  "div",
2841
4861
  {
2842
4862
  className: cn(
2843
4863
  "absolute inset-0 z-0",
2844
- isResponsiveHorizontal && "min-[600px]:hidden",
2845
- isForcedHorizontal && "hidden"
4864
+ !isSquare && isResponsiveHorizontal && "min-[600px]:hidden",
4865
+ !isSquare && isForcedHorizontal && "hidden"
2846
4866
  ),
2847
4867
  children: [
2848
- /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(ActivePill, {}) }),
2849
- /* @__PURE__ */ jsx(HoverStateLayer, {}),
2850
- /* @__PURE__ */ jsx(RippleLayer, { ripples, onRippleDone: removeRipple })
4868
+ /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(
4869
+ ActivePill,
4870
+ {
4871
+ shape: activeShape,
4872
+ width: iconPillWidth,
4873
+ height: iconPillHeight
4874
+ }
4875
+ ) }),
4876
+ /* @__PURE__ */ jsx(
4877
+ HoverStateLayer,
4878
+ {
4879
+ shape: activeShape,
4880
+ width: iconPillWidth,
4881
+ height: iconPillHeight
4882
+ }
4883
+ ),
4884
+ /* @__PURE__ */ jsx(
4885
+ RippleLayer,
4886
+ {
4887
+ ripples,
4888
+ onRippleDone: removeRipple,
4889
+ shape: activeShape,
4890
+ width: iconPillWidth,
4891
+ height: iconPillHeight
4892
+ }
4893
+ )
2851
4894
  ]
2852
4895
  }
2853
4896
  ),
@@ -2855,13 +4898,17 @@ var NavigationBarItemComponent = React36.forwardRef(
2855
4898
  ]
2856
4899
  }
2857
4900
  ),
2858
- /* @__PURE__ */ jsx(AnimatePresence, { mode: "popLayout", children: /* @__PURE__ */ jsx(
2859
- "span",
4901
+ label && /* @__PURE__ */ jsx(AnimatePresence, { mode: "popLayout", initial: false, children: shouldShowLabel && /* @__PURE__ */ jsx(
4902
+ m.span,
2860
4903
  {
4904
+ initial: { opacity: 0, height: 0, scale: 0.85, y: -2 },
4905
+ animate: { opacity: 1, height: "auto", scale: 1, y: 0 },
4906
+ exit: { opacity: 0, height: 0, scale: 0.85, y: -2 },
4907
+ transition: SPRING_TRANSITION_EXPRESSIVE,
2861
4908
  className: cn(
2862
- "z-10 transition-all duration-200 truncate px-1",
2863
- selected ? "text-m3-on-surface" : "text-m3-on-surface-variant",
2864
- "font-medium text-[12px] leading-4 tracking-[0.5px]"
4909
+ "z-10 transition-colors duration-200 truncate px-1 inline-block overflow-hidden",
4910
+ selected ? "text-m3-on-surface font-medium" : "text-m3-on-surface-variant font-medium",
4911
+ "text-[12px] leading-4 tracking-[0.5px]"
2865
4912
  ),
2866
4913
  children: label
2867
4914
  },
@@ -2877,15 +4924,15 @@ var NavigationBarItemComponent = React36.forwardRef(
2877
4924
  }
2878
4925
  );
2879
4926
  NavigationBarItemComponent.displayName = "NavigationBarItem";
2880
- var NavigationBarItem = React36.memo(NavigationBarItemComponent);
4927
+ var NavigationBarItem = React37.memo(NavigationBarItemComponent);
2881
4928
  var navContainerVariants = cva(
2882
4929
  "flex items-center justify-center select-none transition-transform duration-300 z-50",
2883
4930
  {
2884
4931
  variants: {
2885
4932
  variant: {
2886
- flexible: "bottom-0 left-0 right-0 w-full h-16 pb-safe",
2887
- baseline: "bottom-0 left-0 right-0 w-full h-20 pb-safe",
2888
- xr: "bottom-6 left-1/2 -translate-x-1/2 w-auto max-w-[calc(100%-2rem)] min-[600px]:max-w-fit h-20 min-[600px]:h-16 rounded-[48px] px-2"
4933
+ flexible: "bottom-0 left-0 right-0 w-full min-h-16 py-1 pb-safe",
4934
+ baseline: "bottom-0 left-0 right-0 w-full min-h-20 py-1 pb-safe",
4935
+ xr: "bottom-6 left-1/2 -translate-x-1/2 w-auto max-w-[calc(100%-2rem)] min-[600px]:max-w-fit min-h-20 min-[600px]:min-h-16 rounded-[48px] px-2 py-1"
2889
4936
  },
2890
4937
  position: {
2891
4938
  fixed: "fixed",
@@ -2903,10 +4950,13 @@ var navContainerVariants = cva(
2903
4950
  }
2904
4951
  }
2905
4952
  );
2906
- var NavigationBarComponent = React36.forwardRef(
4953
+ var NavigationBarComponent = React37.forwardRef(
2907
4954
  ({
2908
4955
  variant = "flexible",
2909
4956
  itemLayout,
4957
+ shape,
4958
+ labelVisibility,
4959
+ shapeSize,
2910
4960
  hideOnScroll = false,
2911
4961
  elevated = false,
2912
4962
  fixed = true,
@@ -2917,11 +4967,18 @@ var NavigationBarComponent = React36.forwardRef(
2917
4967
  className,
2918
4968
  style
2919
4969
  }, ref) => {
2920
- const [isVisible, setIsVisible] = React36.useState(true);
2921
- const lastScrollY = React36.useRef(
4970
+ const [isVisible, setIsVisible] = React37.useState(true);
4971
+ const lastScrollY = React37.useRef(
2922
4972
  typeof window !== "undefined" ? window.scrollY : 0
2923
4973
  );
2924
- React36.useEffect(() => {
4974
+ const isSquare = isSquareShape(shape);
4975
+ const effectiveShapeSize = shapeSize != null ? shapeSize : isSquare ? 56 : 32;
4976
+ const computedMinHeight = React37.useMemo(() => {
4977
+ const baseHeight = variant === "baseline" ? 80 : 64;
4978
+ const requiredHeight = itemLayout === "horizontal" || labelVisibility === "unlabeled" ? effectiveShapeSize + 16 : effectiveShapeSize + 32;
4979
+ return Math.max(baseHeight, requiredHeight);
4980
+ }, [variant, itemLayout, labelVisibility, effectiveShapeSize]);
4981
+ React37.useEffect(() => {
2925
4982
  if (typeof window === "undefined" || !hideOnScroll) {
2926
4983
  setIsVisible(true);
2927
4984
  return;
@@ -2967,6 +5024,9 @@ var NavigationBarComponent = React36.forwardRef(
2967
5024
  value: {
2968
5025
  variant,
2969
5026
  itemLayout,
5027
+ shape,
5028
+ labelVisibility,
5029
+ shapeSize,
2970
5030
  activeIndicatorTransition,
2971
5031
  itemClassName
2972
5032
  },
@@ -2977,7 +5037,7 @@ var NavigationBarComponent = React36.forwardRef(
2977
5037
  role: "navigation",
2978
5038
  "aria-label": "Main navigation",
2979
5039
  className: navBaseClasses,
2980
- style,
5040
+ style: __spreadValues({ minHeight: computedMinHeight }, style),
2981
5041
  initial: false,
2982
5042
  animate: {
2983
5043
  y: isVisible ? "0%" : variant === "xr" ? "calc(100% + 40px)" : "100%"
@@ -2989,8 +5049,8 @@ var NavigationBarComponent = React36.forwardRef(
2989
5049
  role: "menubar",
2990
5050
  "aria-orientation": "horizontal",
2991
5051
  className: cn(
2992
- "flex w-full h-full mx-auto",
2993
- variant === "xr" ? "gap-0 min-[600px]:gap-1.5 items-center justify-center px-1" : "max-w-7xl gap-1.5"
5052
+ "flex w-full h-full mx-auto items-center justify-center",
5053
+ variant === "xr" ? "gap-0 min-[600px]:gap-1.5 px-1" : "max-w-7xl gap-1.5"
2994
5054
  ),
2995
5055
  children
2996
5056
  }
@@ -3002,8 +5062,12 @@ var NavigationBarComponent = React36.forwardRef(
3002
5062
  }
3003
5063
  );
3004
5064
  NavigationBarComponent.displayName = "NavigationBar";
3005
- var NavigationBar = React36.memo(NavigationBarComponent);
3006
- var NavigationRailContext = React36.createContext({ variant: "collapsed", labelVisibility: "labeled" });
5065
+ var NavigationBar = React37.memo(NavigationBarComponent);
5066
+ var NavigationRailContext = React37.createContext({
5067
+ variant: "collapsed",
5068
+ labelVisibility: "labeled",
5069
+ activeIndicatorWidth: "hug"
5070
+ });
3007
5071
  var MD3_MODAL_TRANSITION = {
3008
5072
  type: "tween",
3009
5073
  ease: [0.05, 0.7, 0.1, 1],
@@ -3014,9 +5078,9 @@ var railContainerVariants = cva(
3014
5078
  {
3015
5079
  variants: {
3016
5080
  variant: {
3017
- collapsed: "items-center h-full pt-11 pb-4 shadow-none bg-m3-surface rounded-none",
3018
- expanded: "items-start h-full pt-11 pb-4 shadow-none bg-m3-surface rounded-none",
3019
- modal: "bg-m3-surface shadow-lg rounded-r-[var(--m3-shape-corner-large)] h-full pt-11 pb-4",
5081
+ collapsed: "items-center h-full pt-11 pb-14 shadow-none bg-m3-surface rounded-none",
5082
+ expanded: "items-start h-full pt-11 pb-14 shadow-none bg-m3-surface rounded-none",
5083
+ modal: "bg-m3-surface shadow-lg rounded-r-[var(--m3-shape-corner-large)] h-full pt-11 pb-14",
3020
5084
  xr: "h-fit py-5 rounded-[48px] shadow-xl bg-m3-surface border border-white/5"
3021
5085
  },
3022
5086
  narrow: {
@@ -3035,9 +5099,9 @@ var railContainerVariants = cva(
3035
5099
  }
3036
5100
  );
3037
5101
  function cloneIconWithFill2(icon, selected) {
3038
- if (!React36.isValidElement(icon)) return icon;
5102
+ if (!React37.isValidElement(icon)) return icon;
3039
5103
  if (icon.type === Icon) {
3040
- return React36.cloneElement(
5104
+ return React37.cloneElement(
3041
5105
  icon,
3042
5106
  { fill: selected ? 1 : 0, animateFill: true }
3043
5107
  );
@@ -3059,14 +5123,28 @@ function setFocusedItem(items, index) {
3059
5123
  target.focus();
3060
5124
  }
3061
5125
  }
3062
- function ActivePill2({ layoutId, disableInitial = false }) {
3063
- const { activeIndicatorTransition } = React36.useContext(NavigationRailContext);
5126
+ function ActivePill2({
5127
+ layoutId,
5128
+ disableInitial = false,
5129
+ shape = "pill",
5130
+ width = 56,
5131
+ height = 32
5132
+ }) {
5133
+ const { activeIndicatorTransition } = React37.useContext(NavigationRailContext);
5134
+ const shapeStyle = getNavigationShapeStyle(shape, width, height);
3064
5135
  return /* @__PURE__ */ jsx(
3065
5136
  m.div,
3066
5137
  {
3067
5138
  layoutId,
3068
- className: "absolute inset-0 bg-m3-secondary-container pointer-events-none",
3069
- style: { borderRadius: 9999, zIndex: 0, originX: 0.5, originY: 0.5 },
5139
+ className: cn(
5140
+ "bg-m3-secondary-container pointer-events-none",
5141
+ shapeStyle ? "absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 rounded-none" : "absolute inset-0 rounded-full"
5142
+ ),
5143
+ style: __spreadValues(__spreadValues({
5144
+ zIndex: 0,
5145
+ originX: 0.5,
5146
+ originY: 0.5
5147
+ }, shapeStyle ? { width, height } : {}), shapeStyle),
3070
5148
  initial: disableInitial ? false : { opacity: 0, scale: 0.5 },
3071
5149
  animate: { opacity: 1, scale: 1 },
3072
5150
  exit: { opacity: 0, scale: 0.5, transition: { duration: 0.15 } },
@@ -3074,11 +5152,42 @@ function ActivePill2({ layoutId, disableInitial = false }) {
3074
5152
  }
3075
5153
  );
3076
5154
  }
3077
- function HoverStateLayer2() {
3078
- return /* @__PURE__ */ jsx("div", { className: "absolute inset-0 rounded-full bg-m3-on-surface opacity-0 group-hover:opacity-[0.08] transition-opacity duration-200 pointer-events-none z-0" });
5155
+ function HoverStateLayer2({
5156
+ shape = "pill",
5157
+ width = 56,
5158
+ height = 32
5159
+ }) {
5160
+ const shapeStyle = getNavigationShapeStyle(shape, width, height);
5161
+ return /* @__PURE__ */ jsx(
5162
+ "div",
5163
+ {
5164
+ className: cn(
5165
+ "bg-m3-on-surface opacity-0 group-hover:opacity-[0.08] transition-opacity duration-200 pointer-events-none z-0",
5166
+ shapeStyle ? "absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 rounded-none" : "absolute inset-0 rounded-full"
5167
+ ),
5168
+ style: __spreadValues(__spreadValues({}, shapeStyle ? { width, height } : {}), shapeStyle)
5169
+ }
5170
+ );
3079
5171
  }
3080
- function RippleLayer2({ ripples, onRippleDone }) {
3081
- return /* @__PURE__ */ jsx("div", { className: "absolute inset-0 rounded-full overflow-hidden pointer-events-none z-0", children: /* @__PURE__ */ jsx(Ripple, { ripples, onRippleDone }) });
5172
+ function RippleLayer2({
5173
+ ripples,
5174
+ onRippleDone,
5175
+ shape = "pill",
5176
+ width = 56,
5177
+ height = 32
5178
+ }) {
5179
+ const shapeStyle = getNavigationShapeStyle(shape, width, height);
5180
+ return /* @__PURE__ */ jsx(
5181
+ "div",
5182
+ {
5183
+ className: cn(
5184
+ "overflow-hidden pointer-events-none z-0",
5185
+ shapeStyle ? "absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 rounded-none" : "absolute inset-0 rounded-full"
5186
+ ),
5187
+ style: __spreadValues(__spreadValues({}, shapeStyle ? { width, height } : {}), shapeStyle),
5188
+ children: /* @__PURE__ */ jsx(Ripple, { ripples, onRippleDone })
5189
+ }
5190
+ );
3082
5191
  }
3083
5192
  function IconContainer2({ selected, badge, children }) {
3084
5193
  return /* @__PURE__ */ jsxs(
@@ -3096,7 +5205,7 @@ function IconContainer2({ selected, badge, children }) {
3096
5205
  }
3097
5206
  );
3098
5207
  }
3099
- var NavigationRailItemComponent = React36.forwardRef(
5208
+ var NavigationRailItemComponent = React37.forwardRef(
3100
5209
  ({
3101
5210
  selected,
3102
5211
  icon,
@@ -3104,24 +5213,37 @@ var NavigationRailItemComponent = React36.forwardRef(
3104
5213
  onClick,
3105
5214
  disabled = false,
3106
5215
  badge,
5216
+ shape: shapeProp,
5217
+ shapeSize: shapeSizeProp,
5218
+ activeIndicatorWidth: activeIndicatorWidthProp,
3107
5219
  className,
3108
5220
  "aria-label": ariaLabelProp,
3109
5221
  asChild = false,
3110
5222
  children
3111
5223
  }, ref) => {
3112
- var _a;
3113
- const { variant, labelVisibility } = React36.useContext(
3114
- NavigationRailContext
3115
- );
5224
+ var _a, _b, _c, _d;
5225
+ const {
5226
+ variant,
5227
+ labelVisibility,
5228
+ shape: contextShape,
5229
+ shapeSize: contextShapeSize,
5230
+ activeIndicatorWidth: contextActiveIndicatorWidth
5231
+ } = React37.useContext(NavigationRailContext);
5232
+ const activeShape = (_a = shapeProp != null ? shapeProp : contextShape) != null ? _a : "pill";
5233
+ const isSquare = isSquareShape(activeShape);
5234
+ const resolvedShapeSize = (_b = shapeSizeProp != null ? shapeSizeProp : contextShapeSize) != null ? _b : 56;
5235
+ const activeIndicatorWidth = (_c = activeIndicatorWidthProp != null ? activeIndicatorWidthProp : contextActiveIndicatorWidth) != null ? _c : "hug";
3116
5236
  const isExpanded = variant === "expanded" || variant === "modal";
3117
5237
  const isModal = variant === "modal";
3118
5238
  const enableLayout = !isModal;
3119
- const activePillId = `rail-pill-${React36.useId()}`;
5239
+ const isExpandedPill = isExpanded && !isSquare;
5240
+ const expandedPillWidthClass = activeIndicatorWidth === "fill" ? "w-full" : "w-fit";
5241
+ const activePillId = `rail-pill-${React37.useId()}`;
3120
5242
  const { ripples, onPointerDown, removeRipple } = useRippleState({
3121
5243
  disabled
3122
5244
  });
3123
5245
  const showLabel = isExpanded || labelVisibility === "labeled" || labelVisibility === "auto" && selected;
3124
- const handleClick = React36.useCallback(
5246
+ const handleClick = React37.useCallback(
3125
5247
  (e) => {
3126
5248
  if (disabled) {
3127
5249
  e.preventDefault();
@@ -3140,8 +5262,10 @@ var NavigationRailItemComponent = React36.forwardRef(
3140
5262
  isExpanded ? "w-full flex-row items-center px-3 h-14" : "w-full flex-col justify-center h-14",
3141
5263
  className
3142
5264
  );
5265
+ const iconPillWidth = isSquare ? resolvedShapeSize : 56;
5266
+ const iconPillHeight = isSquare ? resolvedShapeSize : 32;
3143
5267
  if (asChild && children) {
3144
- const child = React36.Children.only(children);
5268
+ const child = React37.Children.only(children);
3145
5269
  const innerContent = /* @__PURE__ */ jsxs(Fragment, { children: [
3146
5270
  /* @__PURE__ */ jsxs(
3147
5271
  m.div,
@@ -3149,31 +5273,71 @@ var NavigationRailItemComponent = React36.forwardRef(
3149
5273
  layout: enableLayout,
3150
5274
  className: cn(
3151
5275
  "relative flex z-10",
3152
- isExpanded ? "flex-row items-center w-fit h-14 px-4 gap-x-3 rounded-full" : "flex-col items-center justify-center w-full gap-y-1 rounded-full"
5276
+ isExpanded ? cn(
5277
+ "flex-row items-center h-14 px-4 gap-x-3 rounded-full",
5278
+ expandedPillWidthClass
5279
+ ) : "flex-col items-center justify-center w-full gap-y-1 rounded-full"
3153
5280
  ),
3154
5281
  children: [
3155
- isExpanded && /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(
3156
- ActivePill2,
3157
- {
3158
- layoutId: activePillId,
3159
- disableInitial: isModal
3160
- }
3161
- ) }),
3162
- isExpanded && /* @__PURE__ */ jsx(HoverStateLayer2, {}),
3163
- isExpanded && /* @__PURE__ */ jsx(RippleLayer2, { ripples, onRippleDone: removeRipple }),
5282
+ isExpandedPill && /* @__PURE__ */ jsxs(Fragment, { children: [
5283
+ /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(
5284
+ ActivePill2,
5285
+ {
5286
+ layoutId: activePillId,
5287
+ disableInitial: isModal,
5288
+ shape: activeShape
5289
+ }
5290
+ ) }),
5291
+ /* @__PURE__ */ jsx(HoverStateLayer2, { shape: activeShape }),
5292
+ /* @__PURE__ */ jsx(
5293
+ RippleLayer2,
5294
+ {
5295
+ ripples,
5296
+ onRippleDone: removeRipple,
5297
+ shape: activeShape
5298
+ }
5299
+ )
5300
+ ] }),
3164
5301
  /* @__PURE__ */ jsxs(
3165
5302
  m.div,
3166
5303
  {
3167
5304
  layout: enableLayout,
3168
5305
  className: cn(
3169
5306
  "relative flex items-center justify-center shrink-0 z-10",
3170
- isExpanded ? "size-6" : "h-8 w-14 mx-auto"
5307
+ isSquare ? "mx-auto" : isExpandedPill ? "size-6" : "h-8 w-14 mx-auto rounded-full"
3171
5308
  ),
3172
- style: { borderRadius: 9999 },
5309
+ style: isSquare ? { width: resolvedShapeSize, height: resolvedShapeSize } : void 0,
3173
5310
  children: [
3174
- !isExpanded && /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(ActivePill2, { layoutId: activePillId }) }),
3175
- !isExpanded && /* @__PURE__ */ jsx(HoverStateLayer2, {}),
3176
- !isExpanded && /* @__PURE__ */ jsx(RippleLayer2, { ripples, onRippleDone: removeRipple }),
5311
+ !isExpandedPill && /* @__PURE__ */ jsxs(Fragment, { children: [
5312
+ /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(
5313
+ ActivePill2,
5314
+ {
5315
+ layoutId: activePillId,
5316
+ disableInitial: isModal,
5317
+ shape: activeShape,
5318
+ width: iconPillWidth,
5319
+ height: iconPillHeight
5320
+ }
5321
+ ) }),
5322
+ /* @__PURE__ */ jsx(
5323
+ HoverStateLayer2,
5324
+ {
5325
+ shape: activeShape,
5326
+ width: iconPillWidth,
5327
+ height: iconPillHeight
5328
+ }
5329
+ ),
5330
+ /* @__PURE__ */ jsx(
5331
+ RippleLayer2,
5332
+ {
5333
+ ripples,
5334
+ onRippleDone: removeRipple,
5335
+ shape: activeShape,
5336
+ width: iconPillWidth,
5337
+ height: iconPillHeight
5338
+ }
5339
+ )
5340
+ ] }),
3177
5341
  /* @__PURE__ */ jsx(
3178
5342
  m.div,
3179
5343
  {
@@ -3195,10 +5359,10 @@ var NavigationRailItemComponent = React36.forwardRef(
3195
5359
  transition: SPRING_TRANSITION,
3196
5360
  className: cn(
3197
5361
  "z-10 transition-colors duration-200 whitespace-nowrap",
3198
- selected ? "text-m3-on-surface" : "text-m3-on-surface-variant",
3199
- isExpanded ? "text-sm font-medium tracking-wide text-left" : "text-xs font-medium tracking-wide"
5362
+ selected ? isExpandedPill ? "text-m3-on-secondary-container font-medium" : "text-m3-on-surface font-medium" : "text-m3-on-surface-variant font-medium",
5363
+ isExpanded ? "text-sm tracking-wide text-left" : "text-xs tracking-wide"
3200
5364
  ),
3201
- children: (_a = child.props.children) != null ? _a : label
5365
+ children: (_d = child.props.children) != null ? _d : label
3202
5366
  },
3203
5367
  "rail-label"
3204
5368
  ) })
@@ -3219,7 +5383,7 @@ var NavigationRailItemComponent = React36.forwardRef(
3219
5383
  onPointerDown,
3220
5384
  className: itemClassName,
3221
5385
  tabIndex: -1,
3222
- children: React36.cloneElement(child, { children: innerContent })
5386
+ children: React37.cloneElement(child, { children: innerContent })
3223
5387
  }
3224
5388
  ) });
3225
5389
  }
@@ -3244,31 +5408,71 @@ var NavigationRailItemComponent = React36.forwardRef(
3244
5408
  layout: enableLayout,
3245
5409
  className: cn(
3246
5410
  "relative flex z-10",
3247
- isExpanded ? "flex-row items-center w-fit h-14 px-4 gap-x-3 rounded-full" : "flex-col items-center justify-center w-full gap-y-1 rounded-full"
5411
+ isExpanded ? cn(
5412
+ "flex-row items-center h-14 px-4 gap-x-3 rounded-full",
5413
+ expandedPillWidthClass
5414
+ ) : "flex-col items-center justify-center w-full gap-y-1 rounded-full"
3248
5415
  ),
3249
5416
  children: [
3250
- isExpanded && /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(
3251
- ActivePill2,
3252
- {
3253
- layoutId: activePillId,
3254
- disableInitial: isModal
3255
- }
3256
- ) }),
3257
- isExpanded && /* @__PURE__ */ jsx(HoverStateLayer2, {}),
3258
- isExpanded && /* @__PURE__ */ jsx(RippleLayer2, { ripples, onRippleDone: removeRipple }),
5417
+ isExpandedPill && /* @__PURE__ */ jsxs(Fragment, { children: [
5418
+ /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(
5419
+ ActivePill2,
5420
+ {
5421
+ layoutId: activePillId,
5422
+ disableInitial: isModal,
5423
+ shape: activeShape
5424
+ }
5425
+ ) }),
5426
+ /* @__PURE__ */ jsx(HoverStateLayer2, { shape: activeShape }),
5427
+ /* @__PURE__ */ jsx(
5428
+ RippleLayer2,
5429
+ {
5430
+ ripples,
5431
+ onRippleDone: removeRipple,
5432
+ shape: activeShape
5433
+ }
5434
+ )
5435
+ ] }),
3259
5436
  /* @__PURE__ */ jsxs(
3260
5437
  m.div,
3261
5438
  {
3262
5439
  layout: enableLayout,
3263
5440
  className: cn(
3264
5441
  "relative flex items-center justify-center shrink-0 z-10",
3265
- isExpanded ? "size-6" : "h-8 w-14 mx-auto"
5442
+ isSquare ? "mx-auto" : isExpandedPill ? "size-6" : "h-8 w-14 mx-auto rounded-full"
3266
5443
  ),
3267
- style: { borderRadius: 9999 },
5444
+ style: isSquare ? { width: resolvedShapeSize, height: resolvedShapeSize } : void 0,
3268
5445
  children: [
3269
- !isExpanded && /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(ActivePill2, { layoutId: activePillId }) }),
3270
- !isExpanded && /* @__PURE__ */ jsx(HoverStateLayer2, {}),
3271
- !isExpanded && /* @__PURE__ */ jsx(RippleLayer2, { ripples, onRippleDone: removeRipple }),
5446
+ !isExpandedPill && /* @__PURE__ */ jsxs(Fragment, { children: [
5447
+ /* @__PURE__ */ jsx(AnimatePresence, { initial: false, children: selected && /* @__PURE__ */ jsx(
5448
+ ActivePill2,
5449
+ {
5450
+ layoutId: activePillId,
5451
+ disableInitial: isModal,
5452
+ shape: activeShape,
5453
+ width: iconPillWidth,
5454
+ height: iconPillHeight
5455
+ }
5456
+ ) }),
5457
+ /* @__PURE__ */ jsx(
5458
+ HoverStateLayer2,
5459
+ {
5460
+ shape: activeShape,
5461
+ width: iconPillWidth,
5462
+ height: iconPillHeight
5463
+ }
5464
+ ),
5465
+ /* @__PURE__ */ jsx(
5466
+ RippleLayer2,
5467
+ {
5468
+ ripples,
5469
+ onRippleDone: removeRipple,
5470
+ shape: activeShape,
5471
+ width: iconPillWidth,
5472
+ height: iconPillHeight
5473
+ }
5474
+ )
5475
+ ] }),
3272
5476
  /* @__PURE__ */ jsx(
3273
5477
  m.div,
3274
5478
  {
@@ -3290,8 +5494,8 @@ var NavigationRailItemComponent = React36.forwardRef(
3290
5494
  transition: SPRING_TRANSITION,
3291
5495
  className: cn(
3292
5496
  "z-10 transition-colors duration-200 whitespace-nowrap",
3293
- selected ? "text-m3-on-surface" : "text-m3-on-surface-variant",
3294
- isExpanded ? "text-sm font-medium tracking-wide text-left" : "text-xs font-medium tracking-wide"
5497
+ selected ? isExpandedPill ? "text-m3-on-secondary-container font-medium" : "text-m3-on-surface font-medium" : "text-m3-on-surface-variant font-medium",
5498
+ isExpanded ? "text-sm tracking-wide text-left" : "text-xs tracking-wide"
3295
5499
  ),
3296
5500
  children: label
3297
5501
  },
@@ -3307,9 +5511,9 @@ var NavigationRailItemComponent = React36.forwardRef(
3307
5511
  }
3308
5512
  );
3309
5513
  NavigationRailItemComponent.displayName = "NavigationRailItem";
3310
- var NavigationRailItem = React36.memo(NavigationRailItemComponent);
5514
+ var NavigationRailItem = React37.memo(NavigationRailItemComponent);
3311
5515
  function useRoving(navRef) {
3312
- React36.useEffect(() => {
5516
+ React37.useEffect(() => {
3313
5517
  if (!navRef.current) return;
3314
5518
  const items = getMenuItems(navRef.current);
3315
5519
  const selected = items.find(
@@ -3319,7 +5523,7 @@ function useRoving(navRef) {
3319
5523
  const firstFocusable = selected != null ? selected : items[0];
3320
5524
  if (firstFocusable) firstFocusable.tabIndex = 0;
3321
5525
  }, [navRef]);
3322
- return React36.useCallback(
5526
+ return React37.useCallback(
3323
5527
  (e) => {
3324
5528
  if (!navRef.current) return;
3325
5529
  const items = getMenuItems(navRef.current);
@@ -3347,10 +5551,13 @@ function useRoving(navRef) {
3347
5551
  [navRef]
3348
5552
  );
3349
5553
  }
3350
- var NavigationRailComponent = React36.forwardRef(
5554
+ var NavigationRailComponent = React37.forwardRef(
3351
5555
  ({
3352
5556
  variant = "collapsed",
3353
5557
  labelVisibility = "labeled",
5558
+ shape,
5559
+ shapeSize,
5560
+ activeIndicatorWidth = "hug",
3354
5561
  header,
3355
5562
  fab,
3356
5563
  fabPlacement = "contained",
@@ -3364,12 +5571,13 @@ var NavigationRailComponent = React36.forwardRef(
3364
5571
  style
3365
5572
  }, ref) => {
3366
5573
  const isModal = variant === "modal";
5574
+ const isExpanded = variant === "expanded" || variant === "modal";
3367
5575
  const isXr = variant === "xr";
3368
5576
  const isSpatial = isXr && fabPlacement === "spatialized";
3369
5577
  const applyAnimation = !isXr || !isSpatial;
3370
- const navRef = React36.useRef(null);
5578
+ const navRef = React37.useRef(null);
3371
5579
  const handleKeyDown = useRoving(navRef);
3372
- const setRefs = React36.useCallback(
5580
+ const setRefs = React37.useCallback(
3373
5581
  (node) => {
3374
5582
  navRef.current = node;
3375
5583
  if (typeof ref === "function") ref(node);
@@ -3405,10 +5613,12 @@ var NavigationRailComponent = React36.forwardRef(
3405
5613
  transition: isModal ? MD3_MODAL_TRANSITION : SPRING_TRANSITION,
3406
5614
  children: [
3407
5615
  (header || fab && !isSpatial) && /* @__PURE__ */ jsxs(
3408
- "div",
5616
+ m.div,
3409
5617
  {
5618
+ layout: true,
3410
5619
  className: cn(
3411
- "flex w-full flex-col items-center justify-start shrink-0 empty:hidden",
5620
+ "flex w-full flex-col justify-start shrink-0 empty:hidden",
5621
+ isExpanded ? "items-start px-3" : "items-center",
3412
5622
  navHeaderSpacing
3413
5623
  ),
3414
5624
  children: [
@@ -3460,7 +5670,7 @@ var NavigationRailComponent = React36.forwardRef(
3460
5670
  children: fab
3461
5671
  }
3462
5672
  ),
3463
- React36.cloneElement(
5673
+ React37.cloneElement(
3464
5674
  navElement,
3465
5675
  {
3466
5676
  className: cn(navBaseClasses, "pointer-events-auto")
@@ -3474,6 +5684,9 @@ var NavigationRailComponent = React36.forwardRef(
3474
5684
  const contextValue = {
3475
5685
  variant,
3476
5686
  labelVisibility,
5687
+ shape,
5688
+ shapeSize,
5689
+ activeIndicatorWidth,
3477
5690
  activeIndicatorTransition
3478
5691
  };
3479
5692
  if (isModal) {
@@ -3502,7 +5715,7 @@ var NavigationRailComponent = React36.forwardRef(
3502
5715
  }
3503
5716
  );
3504
5717
  NavigationRailComponent.displayName = "NavigationRail";
3505
- var NavigationRail = React36.memo(NavigationRailComponent);
5718
+ var NavigationRail = React37.memo(NavigationRailComponent);
3506
5719
  function useSearchKeyboard({
3507
5720
  active,
3508
5721
  onActiveChange,
@@ -3511,14 +5724,14 @@ function useSearchKeyboard({
3511
5724
  itemCount,
3512
5725
  onSelectSuggestion
3513
5726
  }) {
3514
- const [activeIndex, setActiveIndex] = React36.useState(-1);
3515
- const resetKeyRef = React36.useRef(`${active}:${query}`);
5727
+ const [activeIndex, setActiveIndex] = React37.useState(-1);
5728
+ const resetKeyRef = React37.useRef(`${active}:${query}`);
3516
5729
  const currentKey = `${active}:${query}`;
3517
5730
  if (resetKeyRef.current !== currentKey) {
3518
5731
  resetKeyRef.current = currentKey;
3519
5732
  setActiveIndex(-1);
3520
5733
  }
3521
- const handleKeyDown = React36.useCallback(
5734
+ const handleKeyDown = React37.useCallback(
3522
5735
  (e) => {
3523
5736
  if (!active) return;
3524
5737
  switch (e.key) {
@@ -3558,7 +5771,7 @@ function useSearchKeyboard({
3558
5771
  query
3559
5772
  ]
3560
5773
  );
3561
- const resetActiveIndex = React36.useCallback(() => {
5774
+ const resetActiveIndex = React37.useCallback(() => {
3562
5775
  setActiveIndex(-1);
3563
5776
  }, []);
3564
5777
  return { activeIndex, handleKeyDown, resetActiveIndex };
@@ -3626,10 +5839,10 @@ function AnimatedPlaceholder({
3626
5839
  className
3627
5840
  }) {
3628
5841
  const shouldReduceMotion = useReducedMotion();
3629
- const containerRef = React36.useRef(null);
3630
- const spanRef = React36.useRef(null);
3631
- const [xOffset, setXOffset] = React36.useState(0);
3632
- const recalculate = React36.useCallback(() => {
5842
+ const containerRef = React37.useRef(null);
5843
+ const spanRef = React37.useRef(null);
5844
+ const [xOffset, setXOffset] = React37.useState(0);
5845
+ const recalculate = React37.useCallback(() => {
3633
5846
  const container = containerRef.current;
3634
5847
  const span = spanRef.current;
3635
5848
  if (!container || !span || textAlign === "left") {
@@ -3644,10 +5857,10 @@ function AnimatedPlaceholder({
3644
5857
  setXOffset(Math.max(0, containerWidth - textWidth));
3645
5858
  }
3646
5859
  }, [textAlign]);
3647
- React36.useLayoutEffect(() => {
5860
+ React37.useLayoutEffect(() => {
3648
5861
  recalculate();
3649
5862
  }, [recalculate]);
3650
- React36.useEffect(() => {
5863
+ React37.useEffect(() => {
3651
5864
  const container = containerRef.current;
3652
5865
  if (!container) return;
3653
5866
  const observer = new ResizeObserver(recalculate);
@@ -3716,10 +5929,10 @@ function SearchBar({
3716
5929
  activeIndex
3717
5930
  }) {
3718
5931
  const shouldReduceMotion = useReducedMotion();
3719
- const inputRef = React36.useRef(null);
3720
- const prevActiveRef = React36.useRef(active);
3721
- const isRestoringFocusRef = React36.useRef(false);
3722
- React36.useEffect(() => {
5932
+ const inputRef = React37.useRef(null);
5933
+ const prevActiveRef = React37.useRef(active);
5934
+ const isRestoringFocusRef = React37.useRef(false);
5935
+ React37.useEffect(() => {
3723
5936
  var _a;
3724
5937
  let rafId;
3725
5938
  if (prevActiveRef.current === true && active === false) {
@@ -3838,7 +6051,7 @@ function SearchBar({
3838
6051
  ) })
3839
6052
  );
3840
6053
  }
3841
- var SearchContext = React36.createContext(null);
6054
+ var SearchContext = React37.createContext(null);
3842
6055
  function SearchProvider({
3843
6056
  children,
3844
6057
  value
@@ -3846,7 +6059,7 @@ function SearchProvider({
3846
6059
  return /* @__PURE__ */ jsx(SearchContext.Provider, { value, children });
3847
6060
  }
3848
6061
  function useSearch() {
3849
- const context = React36.useContext(SearchContext);
6062
+ const context = React37.useContext(SearchContext);
3850
6063
  if (!context) {
3851
6064
  return { listboxId: "", activeIndex: -1 };
3852
6065
  }
@@ -3873,7 +6086,7 @@ function useClickOutside(handler, enabled = true) {
3873
6086
  return ref;
3874
6087
  }
3875
6088
  function useSearchViewFocus(inputRef, active) {
3876
- React36.useEffect(() => {
6089
+ React37.useEffect(() => {
3877
6090
  if (!active) return;
3878
6091
  let raf2;
3879
6092
  const raf1 = requestAnimationFrame(() => {
@@ -3933,11 +6146,11 @@ var ROTATE_KEY_SPLINES = [
3933
6146
  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";
3934
6147
  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";
3935
6148
  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";
3936
- var IndeterminateSvg = React36.memo(function IndeterminateSvg2({
6149
+ var IndeterminateSvg = React37.memo(function IndeterminateSvg2({
3937
6150
  size
3938
6151
  }) {
3939
- const [ready, setReady] = React36.useState(false);
3940
- React36.useEffect(() => {
6152
+ const [ready, setReady] = React37.useState(false);
6153
+ React37.useEffect(() => {
3941
6154
  const raf = requestAnimationFrame(() => setReady(true));
3942
6155
  return () => cancelAnimationFrame(raf);
3943
6156
  }, []);
@@ -3982,7 +6195,7 @@ var IndeterminateSvg = React36.memo(function IndeterminateSvg2({
3982
6195
  }
3983
6196
  );
3984
6197
  });
3985
- var DeterminateSvg = React36.memo(function DeterminateSvg2({
6198
+ var DeterminateSvg = React37.memo(function DeterminateSvg2({
3986
6199
  size,
3987
6200
  progress
3988
6201
  }) {
@@ -4007,7 +6220,7 @@ var DeterminateSvg = React36.memo(function DeterminateSvg2({
4007
6220
  }
4008
6221
  );
4009
6222
  });
4010
- var LoadingIndicator = React36.forwardRef(
6223
+ var LoadingIndicator = React37.forwardRef(
4011
6224
  (_a, ref) => {
4012
6225
  var _b = _a, {
4013
6226
  variant = "uncontained",
@@ -4122,7 +6335,7 @@ function getSinePath(startX, endX, phase, wl, amp) {
4122
6335
  d += ` L ${endX.toFixed(2)} ${yEnd.toFixed(2)}`;
4123
6336
  return d;
4124
6337
  }
4125
- var CircularProgress = React36.forwardRef(
6338
+ var CircularProgress = React37.forwardRef(
4126
6339
  (_a, ref) => {
4127
6340
  var _b = _a, {
4128
6341
  value,
@@ -4160,15 +6373,15 @@ var CircularProgress = React36.forwardRef(
4160
6373
  const isWavy = shape === "wavy";
4161
6374
  const BASELINE_SIZE = 48;
4162
6375
  const scaleFactor = size / BASELINE_SIZE;
4163
- const effectiveAmplitude = React36.useMemo(
6376
+ const effectiveAmplitude = React37.useMemo(
4164
6377
  () => amplitude != null ? amplitude : 1.6 * scaleFactor,
4165
6378
  [amplitude, scaleFactor]
4166
6379
  );
4167
- const effectiveWavelength = React36.useMemo(
6380
+ const effectiveWavelength = React37.useMemo(
4168
6381
  () => wavelength != null ? wavelength : 15 * scaleFactor,
4169
6382
  [wavelength, scaleFactor]
4170
6383
  );
4171
- const wavyActivePath = React36.useMemo(
6384
+ const wavyActivePath = React37.useMemo(
4172
6385
  () => isWavy ? generateWavyCircularPath(
4173
6386
  center,
4174
6387
  radius,
@@ -4177,8 +6390,8 @@ var CircularProgress = React36.forwardRef(
4177
6390
  ) : null,
4178
6391
  [isWavy, center, radius, effectiveAmplitude, effectiveWavelength]
4179
6392
  );
4180
- const circumference = React36.useMemo(() => 2 * Math.PI * radius, [radius]);
4181
- const gapForTrack = React36.useMemo(
6393
+ const circumference = React37.useMemo(() => 2 * Math.PI * radius, [radius]);
6394
+ const gapForTrack = React37.useMemo(
4182
6395
  () => (gapSize + trackHeight) / circumference,
4183
6396
  [gapSize, trackHeight, circumference]
4184
6397
  );
@@ -4367,9 +6580,9 @@ var CircularProgress = React36.forwardRef(
4367
6580
  );
4368
6581
  CircularProgress.displayName = "CircularProgress";
4369
6582
  function useContainerWidth() {
4370
- const [width, setWidth] = React36.useState(0);
4371
- const observerRef = React36.useRef(null);
4372
- const ref = React36.useCallback((node) => {
6583
+ const [width, setWidth] = React37.useState(0);
6584
+ const observerRef = React37.useRef(null);
6585
+ const ref = React37.useCallback((node) => {
4373
6586
  if (observerRef.current) {
4374
6587
  observerRef.current.disconnect();
4375
6588
  observerRef.current = null;
@@ -4383,7 +6596,7 @@ function useContainerWidth() {
4383
6596
  observerRef.current = obs;
4384
6597
  }
4385
6598
  }, []);
4386
- React36.useEffect(() => {
6599
+ React37.useEffect(() => {
4387
6600
  return () => {
4388
6601
  if (observerRef.current) {
4389
6602
  observerRef.current.disconnect();
@@ -4393,7 +6606,7 @@ function useContainerWidth() {
4393
6606
  return [ref, width];
4394
6607
  }
4395
6608
  function useMergedRef(...refs) {
4396
- return React36.useCallback(
6609
+ return React37.useCallback(
4397
6610
  (node) => {
4398
6611
  for (const ref of refs) {
4399
6612
  if (typeof ref === "function") {
@@ -4407,7 +6620,7 @@ function useMergedRef(...refs) {
4407
6620
  [refs]
4408
6621
  );
4409
6622
  }
4410
- var FlatLinearTrack = React36.memo(function FlatLinearTrack2({
6623
+ var FlatLinearTrack = React37.memo(function FlatLinearTrack2({
4411
6624
  trackHeight,
4412
6625
  activeColor,
4413
6626
  trackColor,
@@ -4483,7 +6696,7 @@ var FlatLinearTrack = React36.memo(function FlatLinearTrack2({
4483
6696
  }
4484
6697
  );
4485
6698
  });
4486
- var WavyLinearTrack = React36.memo(function WavyLinearTrack2({
6699
+ var WavyLinearTrack = React37.memo(function WavyLinearTrack2({
4487
6700
  trackHeight,
4488
6701
  svgHeight,
4489
6702
  amplitude,
@@ -4502,13 +6715,13 @@ var WavyLinearTrack = React36.memo(function WavyLinearTrack2({
4502
6715
  }) {
4503
6716
  const isDeterminate = typeof value === "number";
4504
6717
  const clampedValue = isDeterminate ? Math.max(0, Math.min(100, value)) : 100;
4505
- const titleId = React36.useId();
6718
+ const titleId = React37.useId();
4506
6719
  const [containerRef, width] = useContainerWidth();
4507
- const activePathRef = React36.useRef(null);
4508
- const trackPathRef = React36.useRef(null);
6720
+ const activePathRef = React37.useRef(null);
6721
+ const trackPathRef = React37.useRef(null);
4509
6722
  const amplitudeMV = useMotionValue(amplitude);
4510
6723
  const fractionMV = useMotionValue(isDeterminate ? clampedValue / 100 : 1);
4511
- React36.useEffect(() => {
6724
+ React37.useEffect(() => {
4512
6725
  if (isDeterminate) {
4513
6726
  const fraction = clampedValue / 100;
4514
6727
  let targetAmp = amplitude;
@@ -4679,7 +6892,7 @@ var WavyLinearTrack = React36.memo(function WavyLinearTrack2({
4679
6892
  }
4680
6893
  );
4681
6894
  });
4682
- var LinearProgress = React36.forwardRef(
6895
+ var LinearProgress = React37.forwardRef(
4683
6896
  (_a, ref) => {
4684
6897
  var _b = _a, {
4685
6898
  value,
@@ -4720,10 +6933,10 @@ var LinearProgress = React36.forwardRef(
4720
6933
  ]);
4721
6934
  const isDeterminate = value !== void 0;
4722
6935
  const clampedValue = isDeterminate ? Math.min(100, Math.max(0, value)) : 0;
4723
- const containerRef = React36.useRef(null);
6936
+ const containerRef = React37.useRef(null);
4724
6937
  const mergedRef = useMergedRef(ref, containerRef);
4725
- const [isRtl, setIsRtl] = React36.useState(false);
4726
- React36.useEffect(() => {
6938
+ const [isRtl, setIsRtl] = React37.useState(false);
6939
+ React37.useEffect(() => {
4727
6940
  if (containerRef.current) {
4728
6941
  const dir = getComputedStyle(containerRef.current).direction;
4729
6942
  setIsRtl(dir === "rtl");
@@ -4731,16 +6944,16 @@ var LinearProgress = React36.forwardRef(
4731
6944
  }, []);
4732
6945
  const isWavy = shape === "wavy";
4733
6946
  const resolvedTrackShape = trackShape != null ? trackShape : shape;
4734
- const effectiveAmplitude = React36.useMemo(() => amplitude != null ? amplitude : 3, [amplitude]);
4735
- const svgHeight = React36.useMemo(
6947
+ const effectiveAmplitude = React37.useMemo(() => amplitude != null ? amplitude : 3, [amplitude]);
6948
+ const svgHeight = React37.useMemo(
4736
6949
  () => isWavy ? trackHeight + effectiveAmplitude * 2 : trackHeight,
4737
6950
  [isWavy, trackHeight, effectiveAmplitude]
4738
6951
  );
4739
- const shouldShowStop = React36.useMemo(
6952
+ const shouldShowStop = React37.useMemo(
4740
6953
  () => isDeterminate && resolvedTrackShape === "flat" && (showStopIndicator === true || showStopIndicator === "auto" && isDeterminate),
4741
6954
  [isDeterminate, resolvedTrackShape, showStopIndicator]
4742
6955
  );
4743
- const stopSize = React36.useMemo(
6956
+ const stopSize = React37.useMemo(
4744
6957
  () => Math.max(2, trackHeight > 4 ? 4 : trackHeight / 2),
4745
6958
  [trackHeight]
4746
6959
  );
@@ -4813,7 +7026,7 @@ var LinearProgress = React36.forwardRef(
4813
7026
  }
4814
7027
  );
4815
7028
  LinearProgress.displayName = "LinearProgress";
4816
- var ProgressIndicator = React36.forwardRef((props, ref) => {
7029
+ var ProgressIndicator = React37.forwardRef((props, ref) => {
4817
7030
  if (props.variant === "circular") {
4818
7031
  return /* @__PURE__ */ jsx(CircularProgress, __spreadValues({ ref }, props));
4819
7032
  }
@@ -4945,7 +7158,7 @@ function resolveDisabledBgClass(colorStyle) {
4945
7158
  }
4946
7159
  return "disabled:text-m3-on-surface/[0.38]";
4947
7160
  }
4948
- var IconButtonComponent = React36.forwardRef(
7161
+ var IconButtonComponent = React37.forwardRef(
4949
7162
  (_a, ref) => {
4950
7163
  var _b = _a, {
4951
7164
  className,
@@ -4987,18 +7200,18 @@ var IconButtonComponent = React36.forwardRef(
4987
7200
  var _a2, _b2, _c, _d, _e;
4988
7201
  const isToggle = variant === "toggle";
4989
7202
  const isSelected = isToggle && !!selected;
4990
- const resolvedColorClass = React36.useMemo(
7203
+ const resolvedColorClass = React37.useMemo(
4991
7204
  () => isSelected ? colorStyles[colorStyle].selected : colorStyles[colorStyle].default,
4992
7205
  [isSelected, colorStyle]
4993
7206
  );
4994
- const outlineWidthClass = React36.useMemo(
7207
+ const outlineWidthClass = React37.useMemo(
4995
7208
  () => {
4996
7209
  var _a3;
4997
7210
  return colorStyle === "outlined" && !isSelected ? (_a3 = SIZE_OUTLINE_WIDTH[size]) != null ? _a3 : "border" : "";
4998
7211
  },
4999
7212
  [colorStyle, isSelected, size]
5000
7213
  );
5001
- const disabledBgClass = React36.useMemo(
7214
+ const disabledBgClass = React37.useMemo(
5002
7215
  () => resolveDisabledBgClass(colorStyle),
5003
7216
  [colorStyle]
5004
7217
  );
@@ -5021,7 +7234,7 @@ var IconButtonComponent = React36.forwardRef(
5021
7234
  const { ripples, onPointerDown, removeRipple } = useRippleState({
5022
7235
  disabled: loading
5023
7236
  });
5024
- const handleClick = React36.useCallback(
7237
+ const handleClick = React37.useCallback(
5025
7238
  (e) => {
5026
7239
  if (loading) {
5027
7240
  e.preventDefault();
@@ -5031,7 +7244,7 @@ var IconButtonComponent = React36.forwardRef(
5031
7244
  },
5032
7245
  [loading, onClick]
5033
7246
  );
5034
- const handleKeyDown = React36.useCallback(
7247
+ const handleKeyDown = React37.useCallback(
5035
7248
  (e) => {
5036
7249
  if (loading) return;
5037
7250
  if ((e.key === "Enter" || e.key === " ") && onClick) {
@@ -5087,7 +7300,7 @@ var IconButtonComponent = React36.forwardRef(
5087
7300
  width: isCustomSize ? `${iconSize}px` : void 0,
5088
7301
  height: isCustomSize ? `${iconSize}px` : void 0
5089
7302
  },
5090
- children: isSelected && selectedIcon ? selectedIcon : asChild ? React36.Children.only(children).props.children : children
7303
+ children: isSelected && selectedIcon ? selectedIcon : asChild ? React37.Children.only(children).props.children : children
5091
7304
  }),
5092
7305
  isSelected && selectedIcon ? "selected-content" : "content"
5093
7306
  ) })
@@ -5104,7 +7317,7 @@ var IconButtonComponent = React36.forwardRef(
5104
7317
  className
5105
7318
  );
5106
7319
  if (asChild) {
5107
- const child = React36.Children.only(children);
7320
+ const child = React37.Children.only(children);
5108
7321
  return /* @__PURE__ */ jsx(LazyMotion, { features: domMax, strict: true, children: /* @__PURE__ */ jsx(
5109
7322
  Slot,
5110
7323
  __spreadProps(__spreadValues({
@@ -5121,7 +7334,7 @@ var IconButtonComponent = React36.forwardRef(
5121
7334
  }),
5122
7335
  className: containerClassName
5123
7336
  }, restProps), {
5124
- children: React36.cloneElement(child, { children: innerContent })
7337
+ children: React37.cloneElement(child, { children: innerContent })
5125
7338
  })
5126
7339
  ) });
5127
7340
  }
@@ -5149,7 +7362,7 @@ var IconButtonComponent = React36.forwardRef(
5149
7362
  }
5150
7363
  );
5151
7364
  IconButtonComponent.displayName = "IconButton";
5152
- var IconButton = React36.memo(IconButtonComponent);
7365
+ var IconButton = React37.memo(IconButtonComponent);
5153
7366
  function TrailingAction({
5154
7367
  query,
5155
7368
  trailingIcon,
@@ -5209,7 +7422,7 @@ function SearchViewDocked({
5209
7422
  activeIndex
5210
7423
  }) {
5211
7424
  const shouldReduceMotion = useReducedMotion();
5212
- const inputRef = React36.useRef(null);
7425
+ const inputRef = React37.useRef(null);
5213
7426
  useSearchViewFocus(inputRef, active);
5214
7427
  const dropdownRef = useClickOutside(() => {
5215
7428
  onActiveChange(false);
@@ -5355,10 +7568,10 @@ function SearchViewFullScreen({
5355
7568
  activeIndex
5356
7569
  }) {
5357
7570
  const shouldReduceMotion = useReducedMotion();
5358
- const inputRef = React36.useRef(null);
7571
+ const inputRef = React37.useRef(null);
5359
7572
  useSearchViewFocus(inputRef, active);
5360
- const [mounted, setMounted] = React36.useState(false);
5361
- React36.useEffect(() => {
7573
+ const [mounted, setMounted] = React37.useState(false);
7574
+ React37.useEffect(() => {
5362
7575
  setMounted(true);
5363
7576
  }, []);
5364
7577
  const handleFormSubmit = (e) => {
@@ -5516,10 +7729,10 @@ function SearchComponent({
5516
7729
  className,
5517
7730
  viewClassName
5518
7731
  }) {
5519
- const generatedId = React36.useId();
7732
+ const generatedId = React37.useId();
5520
7733
  const searchId = id != null ? id : generatedId;
5521
7734
  const listboxId = `${searchId}-listbox`;
5522
- const itemCount = React36.Children.count(children);
7735
+ const itemCount = React37.Children.count(children);
5523
7736
  const { activeIndex, handleKeyDown } = useSearchKeyboard({
5524
7737
  active,
5525
7738
  onActiveChange,
@@ -5578,9 +7791,9 @@ function formatBadgeLabel(children, max) {
5578
7791
  return "";
5579
7792
  }
5580
7793
  function detectBadgeHasContent(badge) {
5581
- return React36.isValidElement(badge) && badge.props.children != null;
7794
+ return React37.isValidElement(badge) && badge.props.children != null;
5582
7795
  }
5583
- var BadgeImpl = React36.forwardRef(
7796
+ var BadgeImpl = React37.forwardRef(
5584
7797
  (_a, ref) => {
5585
7798
  var _b = _a, {
5586
7799
  children,
@@ -5634,7 +7847,7 @@ var BadgeImpl = React36.forwardRef(
5634
7847
  }
5635
7848
  );
5636
7849
  BadgeImpl.displayName = "Badge";
5637
- React36.memo(BadgeImpl);
7850
+ React37.memo(BadgeImpl);
5638
7851
  function BadgedBox({
5639
7852
  badge,
5640
7853
  children,
@@ -5655,9 +7868,9 @@ function BadgedBox({
5655
7868
  )
5656
7869
  ] });
5657
7870
  }
5658
- var TabsContext = React36.createContext(null);
7871
+ var TabsContext = React37.createContext(null);
5659
7872
  function useTabsContext() {
5660
- const ctx = React36.useContext(TabsContext);
7873
+ const ctx = React37.useContext(TabsContext);
5661
7874
  if (!ctx) {
5662
7875
  throw new Error(
5663
7876
  "[MD3 Tabs] Component must be used within a <Tabs> root. Ensure <TabsList>, <Tab>, and <TabsContent> are descendants of <Tabs>."
@@ -5665,7 +7878,7 @@ function useTabsContext() {
5665
7878
  }
5666
7879
  return ctx;
5667
7880
  }
5668
- var TabsComponent = React36.forwardRef(
7881
+ var TabsComponent = React37.forwardRef(
5669
7882
  ({
5670
7883
  value: controlledValue,
5671
7884
  defaultValue = "",
@@ -5674,35 +7887,35 @@ var TabsComponent = React36.forwardRef(
5674
7887
  children,
5675
7888
  className
5676
7889
  }, ref) => {
5677
- const [internalValue, setInternalValue] = React36.useState(defaultValue);
7890
+ const [internalValue, setInternalValue] = React37.useState(defaultValue);
5678
7891
  const isControlled = controlledValue !== void 0;
5679
7892
  const value = isControlled ? controlledValue : internalValue;
5680
- const handleValueChange = React36.useCallback(
7893
+ const handleValueChange = React37.useCallback(
5681
7894
  (newValue) => {
5682
7895
  if (!isControlled) setInternalValue(newValue);
5683
7896
  onValueChange == null ? void 0 : onValueChange(newValue);
5684
7897
  },
5685
7898
  [isControlled, onValueChange]
5686
7899
  );
5687
- const [focusedValue, setFocusedValue] = React36.useState(value);
5688
- React36.useEffect(() => {
7900
+ const [focusedValue, setFocusedValue] = React37.useState(value);
7901
+ React37.useEffect(() => {
5689
7902
  setFocusedValue(value);
5690
7903
  }, [value]);
5691
- const [tabValues, setTabValues] = React36.useState([]);
5692
- const registerTab = React36.useCallback((tabValue) => {
7904
+ const [tabValues, setTabValues] = React37.useState([]);
7905
+ const registerTab = React37.useCallback((tabValue) => {
5693
7906
  setTabValues((prev) => {
5694
7907
  if (prev.includes(tabValue)) return prev;
5695
7908
  return [...prev, tabValue];
5696
7909
  });
5697
7910
  }, []);
5698
- const unregisterTab = React36.useCallback((tabValue) => {
7911
+ const unregisterTab = React37.useCallback((tabValue) => {
5699
7912
  setTabValues((prev) => prev.filter((v) => v !== tabValue));
5700
7913
  }, []);
5701
- const hasAutoSelected = React36.useRef(false);
5702
- const [disabledValues, setDisabledValues] = React36.useState(
7914
+ const hasAutoSelected = React37.useRef(false);
7915
+ const [disabledValues, setDisabledValues] = React37.useState(
5703
7916
  /* @__PURE__ */ new Set()
5704
7917
  );
5705
- const markTabDisabled = React36.useCallback(
7918
+ const markTabDisabled = React37.useCallback(
5706
7919
  (tabValue, disabled) => {
5707
7920
  setDisabledValues((prev) => {
5708
7921
  const next = new Set(prev);
@@ -5716,7 +7929,7 @@ var TabsComponent = React36.forwardRef(
5716
7929
  },
5717
7930
  []
5718
7931
  );
5719
- React36.useEffect(() => {
7932
+ React37.useEffect(() => {
5720
7933
  if (isControlled || hasAutoSelected.current || tabValues.length === 0) {
5721
7934
  return;
5722
7935
  }
@@ -5731,9 +7944,9 @@ var TabsComponent = React36.forwardRef(
5731
7944
  setFocusedValue(firstEnabled);
5732
7945
  }
5733
7946
  }, [tabValues, disabledValues, isControlled, value]);
5734
- const id = React36.useId();
7947
+ const id = React37.useId();
5735
7948
  const layoutGroupId = `tabs-${id}`;
5736
- const contextValue = React36.useMemo(
7949
+ const contextValue = React37.useMemo(
5737
7950
  () => ({
5738
7951
  value,
5739
7952
  onValueChange: handleValueChange,
@@ -5764,12 +7977,12 @@ var TabsComponent = React36.forwardRef(
5764
7977
  }
5765
7978
  );
5766
7979
  TabsComponent.displayName = "Tabs";
5767
- var Tabs = React36.memo(TabsComponent);
5768
- var TabsListContext = React36.createContext(
7980
+ var Tabs = React37.memo(TabsComponent);
7981
+ var TabsListContext = React37.createContext(
5769
7982
  null
5770
7983
  );
5771
7984
  function useTabsListContext() {
5772
- const ctx = React36.useContext(TabsListContext);
7985
+ const ctx = React37.useContext(TabsListContext);
5773
7986
  return ctx != null ? ctx : { variant: "primary", scrollable: false };
5774
7987
  }
5775
7988
 
@@ -5853,7 +8066,7 @@ var TABS_CONTENT_TRANSITION = {
5853
8066
  ease: "easeInOut"
5854
8067
  };
5855
8068
  var INDICATOR_MIN_WIDTH = 24;
5856
- var TabComponent = React36.forwardRef(
8069
+ var TabComponent = React37.forwardRef(
5857
8070
  ({
5858
8071
  value,
5859
8072
  icon,
@@ -5883,9 +8096,9 @@ var TabComponent = React36.forwardRef(
5883
8096
  const isFocused = focusedValue === value;
5884
8097
  const hasIcon = icon != null;
5885
8098
  const isStackedIcon = hasIcon && !inlineIcon;
5886
- const buttonRef = React36.useRef(null);
5887
- const isFirstMount = React36.useRef(true);
5888
- const mergedRef = React36.useCallback(
8099
+ const buttonRef = React37.useRef(null);
8100
+ const isFirstMount = React37.useRef(true);
8101
+ const mergedRef = React37.useCallback(
5889
8102
  (node) => {
5890
8103
  buttonRef.current = node;
5891
8104
  if (typeof ref === "function") ref(node);
@@ -5893,15 +8106,15 @@ var TabComponent = React36.forwardRef(
5893
8106
  },
5894
8107
  [ref]
5895
8108
  );
5896
- React36.useEffect(() => {
8109
+ React37.useEffect(() => {
5897
8110
  registerTab(value);
5898
8111
  return () => unregisterTab(value);
5899
8112
  }, [value, registerTab, unregisterTab]);
5900
- React36.useEffect(() => {
8113
+ React37.useEffect(() => {
5901
8114
  markTabDisabled(value, disabled);
5902
8115
  return () => markTabDisabled(value, false);
5903
8116
  }, [value, disabled, markTabDisabled]);
5904
- const handleKeyDown = React36.useCallback(
8117
+ const handleKeyDown = React37.useCallback(
5905
8118
  (e) => {
5906
8119
  const isRtl = buttonRef.current ? getComputedStyle(buttonRef.current).direction === "rtl" : false;
5907
8120
  const enabledValues = tabValues.filter((v) => !disabledValues.has(v));
@@ -5955,7 +8168,7 @@ var TabComponent = React36.forwardRef(
5955
8168
  autoActivate
5956
8169
  ]
5957
8170
  );
5958
- React36.useEffect(() => {
8171
+ React37.useEffect(() => {
5959
8172
  if (isFirstMount.current) {
5960
8173
  isFirstMount.current = false;
5961
8174
  return;
@@ -5964,7 +8177,7 @@ var TabComponent = React36.forwardRef(
5964
8177
  buttonRef.current.focus({ preventScroll: true });
5965
8178
  }
5966
8179
  }, [isFocused]);
5967
- React36.useEffect(() => {
8180
+ React37.useEffect(() => {
5968
8181
  if (!isActive || !scrollable || !buttonRef.current) return;
5969
8182
  const btn = buttonRef.current;
5970
8183
  let container = btn.parentElement;
@@ -6101,8 +8314,8 @@ var TabComponent = React36.forwardRef(
6101
8314
  }
6102
8315
  );
6103
8316
  TabComponent.displayName = "Tab";
6104
- var Tab = React36.memo(TabComponent);
6105
- var TabsContentComponent = React36.forwardRef(
8317
+ var Tab = React37.memo(TabComponent);
8318
+ var TabsContentComponent = React37.forwardRef(
6106
8319
  ({ value, className, children }, ref) => {
6107
8320
  var _a;
6108
8321
  const { value: selectedValue, layoutGroupId } = useTabsContext();
@@ -6136,8 +8349,8 @@ var TabsContentComponent = React36.forwardRef(
6136
8349
  }
6137
8350
  );
6138
8351
  TabsContentComponent.displayName = "TabsContent";
6139
- var TabsContent = React36.memo(TabsContentComponent);
6140
- var TabsListComponent = React36.forwardRef(
8352
+ var TabsContent = React37.memo(TabsContentComponent);
8353
+ var TabsListComponent = React37.forwardRef(
6141
8354
  ({
6142
8355
  variant,
6143
8356
  scrollable = false,
@@ -6148,12 +8361,12 @@ var TabsListComponent = React36.forwardRef(
6148
8361
  }, ref) => {
6149
8362
  const { layoutGroupId, value, setFocusedValue } = useTabsContext();
6150
8363
  const listLayoutId = `${layoutGroupId}-list`;
6151
- const listContextValue = React36.useMemo(
8364
+ const listContextValue = React37.useMemo(
6152
8365
  () => ({ variant, scrollable }),
6153
8366
  [variant, scrollable]
6154
8367
  );
6155
8368
  const bgColor = backgroundColor != null ? backgroundColor : "var(--md-sys-color-surface)";
6156
- const handleBlur = React36.useCallback(
8369
+ const handleBlur = React37.useCallback(
6157
8370
  (e) => {
6158
8371
  const listEl = e.currentTarget;
6159
8372
  if (listEl.contains(e.relatedTarget)) return;
@@ -6202,7 +8415,7 @@ var TabsListComponent = React36.forwardRef(
6202
8415
  }
6203
8416
  );
6204
8417
  TabsListComponent.displayName = "TabsList";
6205
- var TabsList = React36.memo(TabsListComponent);
8418
+ var TabsList = React37.memo(TabsListComponent);
6206
8419
 
6207
8420
  // src/ui/toolbar/toolbar-colors.ts
6208
8421
  var standardFloatingToolbarColors = {
@@ -6258,13 +8471,13 @@ function getToolbarColors(variant = "standard", customColors) {
6258
8471
  return standardFloatingToolbarColors;
6259
8472
  }
6260
8473
  }
6261
- var ToolbarContext = React36.createContext(
8474
+ var ToolbarContext = React37.createContext(
6262
8475
  null
6263
8476
  );
6264
8477
  function useToolbarContext() {
6265
- return React36.useContext(ToolbarContext);
8478
+ return React37.useContext(ToolbarContext);
6266
8479
  }
6267
- var BottomDockedToolbar = React36.forwardRef(
8480
+ var BottomDockedToolbar = React37.forwardRef(
6268
8481
  (_a, ref) => {
6269
8482
  var _b = _a, {
6270
8483
  variant = "standard",
@@ -6297,8 +8510,8 @@ var BottomDockedToolbar = React36.forwardRef(
6297
8510
  const { scrollY } = useScroll(
6298
8511
  scrollContainerRef ? { container: scrollContainerRef } : void 0
6299
8512
  );
6300
- const [isHidden, setIsHidden] = React36.useState(false);
6301
- const lastScrollY = React36.useRef(0);
8513
+ const [isHidden, setIsHidden] = React37.useState(false);
8514
+ const lastScrollY = React37.useRef(0);
6302
8515
  useMotionValueEvent(scrollY, "change", (latest) => {
6303
8516
  if (!hideOnScroll) return;
6304
8517
  const diff = latest - lastScrollY.current;
@@ -6408,6 +8621,10 @@ var ToolbarToggleButtonTokens = {
6408
8621
  PaddingX: 16,
6409
8622
  Gap: 8
6410
8623
  };
8624
+ var ToolbarToggleButtonRadiusTokens = {
8625
+ pillRadius: 24,
8626
+ pressedRadius: 12
8627
+ };
6411
8628
  var ALIGNMENT_CLASS = {
6412
8629
  start: "justify-start",
6413
8630
  center: "justify-center",
@@ -6453,15 +8670,15 @@ function buildSlotVariants(xHidden, yHidden, isHorizontal) {
6453
8670
  };
6454
8671
  }
6455
8672
  function applyItemClassName(nodes, itemClassName) {
6456
- return React36.Children.map(nodes, (child) => {
6457
- if (!React36.isValidElement(child)) return child;
8673
+ return React37.Children.map(nodes, (child) => {
8674
+ if (!React37.isValidElement(child)) return child;
6458
8675
  const element = child;
6459
- return React36.cloneElement(element, {
8676
+ return React37.cloneElement(element, {
6460
8677
  className: cn(element.props.className, itemClassName)
6461
8678
  });
6462
8679
  });
6463
8680
  }
6464
- var FloatingToolbarBase = React36.forwardRef(
8681
+ var FloatingToolbarBase = React37.forwardRef(
6465
8682
  (_a, ref) => {
6466
8683
  var _b = _a, {
6467
8684
  expanded,
@@ -6633,11 +8850,11 @@ var FloatingToolbarBase = React36.forwardRef(
6633
8850
  }
6634
8851
  );
6635
8852
  FloatingToolbarBase.displayName = "FloatingToolbarBase";
6636
- var HorizontalFloatingToolbar = React36.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarBase, __spreadValues({ ref, orientation: "horizontal" }, props)));
8853
+ var HorizontalFloatingToolbar = React37.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarBase, __spreadValues({ ref, orientation: "horizontal" }, props)));
6637
8854
  HorizontalFloatingToolbar.displayName = "HorizontalFloatingToolbar";
6638
- var VerticalFloatingToolbar = React36.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarBase, __spreadValues({ ref, orientation: "vertical" }, props)));
8855
+ var VerticalFloatingToolbar = React37.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarBase, __spreadValues({ ref, orientation: "vertical" }, props)));
6639
8856
  VerticalFloatingToolbar.displayName = "VerticalFloatingToolbar";
6640
- var FloatingToolbarWithFabBase = React36.forwardRef(
8857
+ var FloatingToolbarWithFabBase = React37.forwardRef(
6641
8858
  (_a, ref) => {
6642
8859
  var _b = _a, {
6643
8860
  expanded,
@@ -6765,9 +8982,9 @@ var FloatingToolbarWithFabBase = React36.forwardRef(
6765
8982
  }
6766
8983
  );
6767
8984
  FloatingToolbarWithFabBase.displayName = "FloatingToolbarWithFabBase";
6768
- var HorizontalFloatingToolbarWithFab = React36.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarWithFabBase, __spreadValues({ ref, orientation: "horizontal" }, props)));
8985
+ var HorizontalFloatingToolbarWithFab = React37.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarWithFabBase, __spreadValues({ ref, orientation: "horizontal" }, props)));
6769
8986
  HorizontalFloatingToolbarWithFab.displayName = "HorizontalFloatingToolbarWithFab";
6770
- var VerticalFloatingToolbarWithFab = React36.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarWithFabBase, __spreadValues({ ref, orientation: "vertical" }, props)));
8987
+ var VerticalFloatingToolbarWithFab = React37.forwardRef((props, ref) => /* @__PURE__ */ jsx(FloatingToolbarWithFabBase, __spreadValues({ ref, orientation: "vertical" }, props)));
6771
8988
  VerticalFloatingToolbarWithFab.displayName = "VerticalFloatingToolbarWithFab";
6772
8989
  var ToolbarDivider = ({
6773
8990
  orientation: propsOrientation,
@@ -6803,7 +9020,7 @@ var VARIANT_TO_COLOR_STYLE = {
6803
9020
  tonal: "tonal",
6804
9021
  filled: "filled"
6805
9022
  };
6806
- var ToolbarIconButton = React36.forwardRef(
9023
+ var ToolbarIconButton = React37.forwardRef(
6807
9024
  (_a, ref) => {
6808
9025
  var _b = _a, {
6809
9026
  emphasis = "standard",
@@ -6924,6 +9141,34 @@ function useFloatingToolbarScrollBehavior(options = {}) {
6924
9141
  exitDirection
6925
9142
  };
6926
9143
  }
9144
+ var BUTTON_RADIUS_SPRING = FAST_EFFECTS_SPRING;
9145
+ ({
9146
+ xs: {
9147
+ // 1dp
9148
+ squareShapeRadius: cornerRadius.medium,
9149
+ // 12dp
9150
+ pressedShapeRadius: cornerRadius.small},
9151
+ sm: {
9152
+ // 1dp
9153
+ squareShapeRadius: cornerRadius.medium,
9154
+ // 12dp
9155
+ pressedShapeRadius: cornerRadius.small},
9156
+ md: {
9157
+ // 1dp
9158
+ squareShapeRadius: cornerRadius.large,
9159
+ // 16dp
9160
+ pressedShapeRadius: cornerRadius.medium},
9161
+ lg: {
9162
+ // 2dp
9163
+ squareShapeRadius: cornerRadius.extraLarge,
9164
+ // 28dp
9165
+ pressedShapeRadius: cornerRadius.large},
9166
+ xl: {
9167
+ // 3dp
9168
+ squareShapeRadius: cornerRadius.extraLarge,
9169
+ // 28dp
9170
+ pressedShapeRadius: cornerRadius.large}
9171
+ });
6927
9172
  var MOTION_PROP_KEYS = [
6928
9173
  "animate",
6929
9174
  "exit",
@@ -6947,36 +9192,41 @@ var MOTION_PROP_KEYS = [
6947
9192
  "layoutId",
6948
9193
  "onLayoutAnimationComplete"
6949
9194
  ];
6950
- var ToolbarToggleButton = React36.forwardRef(
9195
+ var ToolbarToggleButton = React37.forwardRef(
6951
9196
  (_a, ref) => {
6952
9197
  var _b = _a, {
6953
9198
  emphasis = "standard",
6954
9199
  selected = false,
6955
9200
  icon,
6956
9201
  children,
6957
- pressScale = 0.95,
6958
- pressBounceOffset = 6,
9202
+ pressExpand = true,
9203
+ pressExpandRatio = 0.06,
6959
9204
  ripple = true,
6960
9205
  asChild = false,
6961
9206
  className,
6962
9207
  type = "button",
6963
9208
  disabled,
6964
- onPointerDown: onPointerDownProp
9209
+ onPointerDown: onPointerDownProp,
9210
+ onPointerUp: onPointerUpProp,
9211
+ onPointerLeave: onPointerLeaveProp
6965
9212
  } = _b, props = __objRest(_b, [
6966
9213
  "emphasis",
6967
9214
  "selected",
6968
9215
  "icon",
6969
9216
  "children",
6970
- "pressScale",
6971
- "pressBounceOffset",
9217
+ "pressExpand",
9218
+ "pressExpandRatio",
6972
9219
  "ripple",
6973
9220
  "asChild",
6974
9221
  "className",
6975
9222
  "type",
6976
9223
  "disabled",
6977
- "onPointerDown"
9224
+ "onPointerDown",
9225
+ "onPointerUp",
9226
+ "onPointerLeave"
6978
9227
  ]);
6979
9228
  const context = useToolbarContext();
9229
+ const [isPressed, setIsPressed] = React37.useState(false);
6980
9230
  const {
6981
9231
  ripples,
6982
9232
  onPointerDown: handleRipplePointerDown,
@@ -6984,8 +9234,9 @@ var ToolbarToggleButton = React36.forwardRef(
6984
9234
  } = useRippleState({
6985
9235
  disabled: Boolean(disabled) || !ripple
6986
9236
  });
6987
- const handlePointerDown = React36.useCallback(
9237
+ const handlePointerDown = React37.useCallback(
6988
9238
  (e) => {
9239
+ setIsPressed(true);
6989
9240
  if (!disabled && ripple) {
6990
9241
  handleRipplePointerDown(e);
6991
9242
  }
@@ -6993,7 +9244,21 @@ var ToolbarToggleButton = React36.forwardRef(
6993
9244
  },
6994
9245
  [disabled, ripple, handleRipplePointerDown, onPointerDownProp]
6995
9246
  );
6996
- const baseClasses = "relative overflow-hidden inline-flex items-center justify-center min-w-[95px] h-[48px] px-4 rounded-full text-sm font-medium transition-colors select-none focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-current/40 disabled:pointer-events-none disabled:opacity-38";
9247
+ const handlePointerUp = React37.useCallback(
9248
+ (e) => {
9249
+ setIsPressed(false);
9250
+ onPointerUpProp == null ? void 0 : onPointerUpProp(e);
9251
+ },
9252
+ [onPointerUpProp]
9253
+ );
9254
+ const handlePointerLeave = React37.useCallback(
9255
+ (e) => {
9256
+ setIsPressed(false);
9257
+ onPointerLeaveProp == null ? void 0 : onPointerLeaveProp(e);
9258
+ },
9259
+ [onPointerLeaveProp]
9260
+ );
9261
+ const baseClasses = "relative overflow-hidden inline-flex items-center justify-center min-w-[95px] h-[48px] px-4 text-sm font-medium select-none focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-current/40 disabled:pointer-events-none disabled:opacity-38";
6997
9262
  const variantClasses = {
6998
9263
  standard: selected ? "bg-current/16 text-current hover:bg-current/20 active:bg-current/24" : "bg-transparent text-current hover:bg-current/8 active:bg-current/12",
6999
9264
  tonal: selected ? "bg-m3-secondary-container text-m3-on-secondary-container hover:shadow-sm" : "bg-m3-surface-container-high text-m3-on-surface hover:bg-m3-surface-container-highest",
@@ -7005,27 +9270,17 @@ var ToolbarToggleButton = React36.forwardRef(
7005
9270
  context == null ? void 0 : context.itemClassName,
7006
9271
  className
7007
9272
  );
7008
- const whileTapConfig = React36.useMemo(
9273
+ const animateConfig = React37.useMemo(
7009
9274
  () => ({
7010
- scale: pressScale,
7011
- x: pressBounceOffset ? [
7012
- 0,
7013
- -pressBounceOffset,
7014
- pressBounceOffset,
7015
- -pressBounceOffset / 2,
7016
- pressBounceOffset / 2,
7017
- 0
7018
- ] : 0
9275
+ scaleX: pressExpand && isPressed ? 1 + pressExpandRatio : 1,
9276
+ borderRadius: isPressed ? ToolbarToggleButtonRadiusTokens.pressedRadius : ToolbarToggleButtonRadiusTokens.pillRadius
7019
9277
  }),
7020
- [pressScale, pressBounceOffset]
9278
+ [pressExpand, pressExpandRatio, isPressed]
7021
9279
  );
7022
- const transitionConfig = React36.useMemo(
7023
- () => __spreadProps(__spreadValues({}, TOOLBAR_SPRING_TRANSITION), {
7024
- scale: TOOLBAR_SPRING_TRANSITION,
7025
- x: {
7026
- duration: 0.35,
7027
- ease: "easeInOut"
7028
- }
9280
+ const transitionConfig = React37.useMemo(
9281
+ () => ({
9282
+ scaleX: FAST_SPATIAL_SPRING,
9283
+ borderRadius: BUTTON_RADIUS_SPRING
7029
9284
  }),
7030
9285
  []
7031
9286
  );
@@ -7044,7 +9299,7 @@ var ToolbarToggleButton = React36.forwardRef(
7044
9299
  children && (typeof children === "string" || typeof children === "number" ? /* @__PURE__ */ jsx("span", { children }) : children)
7045
9300
  ] });
7046
9301
  if (asChild) {
7047
- const child = React36.Children.only(children);
9302
+ const child = React37.Children.only(children);
7048
9303
  const childContent = child.props.children;
7049
9304
  const innerChildContent = /* @__PURE__ */ jsxs(Fragment, { children: [
7050
9305
  ripple && /* @__PURE__ */ jsx(
@@ -7079,9 +9334,11 @@ var ToolbarToggleButton = React36.forwardRef(
7079
9334
  ref,
7080
9335
  "aria-pressed": selected,
7081
9336
  className: combinedClassName,
7082
- onPointerDown: handlePointerDown
9337
+ onPointerDown: handlePointerDown,
9338
+ onPointerUp: handlePointerUp,
9339
+ onPointerLeave: handlePointerLeave
7083
9340
  }, strippedProps), {
7084
- children: React36.cloneElement(child, { children: innerChildContent })
9341
+ children: React37.cloneElement(child, { children: innerChildContent })
7085
9342
  })
7086
9343
  ) });
7087
9344
  }
@@ -7092,9 +9349,13 @@ var ToolbarToggleButton = React36.forwardRef(
7092
9349
  type,
7093
9350
  "aria-pressed": selected,
7094
9351
  disabled,
7095
- whileTap: whileTapConfig,
9352
+ animate: animateConfig,
7096
9353
  transition: transitionConfig,
9354
+ initial: false,
9355
+ style: { transformOrigin: "center" },
7097
9356
  onPointerDown: handlePointerDown,
9357
+ onPointerUp: handlePointerUp,
9358
+ onPointerLeave: handlePointerLeave,
7098
9359
  className: combinedClassName
7099
9360
  }, props), {
7100
9361
  children: [
@@ -7114,6 +9375,6 @@ var ToolbarToggleButton = React36.forwardRef(
7114
9375
  );
7115
9376
  ToolbarToggleButton.displayName = "ToolbarToggleButton";
7116
9377
 
7117
- 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, 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, getToolbarColors, standardFloatingToolbarColors, surfaceContainerHighFloatingToolbarColors, surfaceContainerHighestFloatingToolbarColors, tertiaryContainerFloatingToolbarColors, useAppBarScroll, useFloatingToolbarScrollBehavior, useMenuContext, useSearch, useSearchKeyboard, vibrantFloatingToolbarColors, xrFloatingToolbarColors };
9378
+ 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, 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 };
7118
9379
  //# sourceMappingURL=navigation.mjs.map
7119
9380
  //# sourceMappingURL=navigation.mjs.map