@tinybigui/react 0.4.2 → 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1411,53 +1411,48 @@ declare function useOptionalButtonGroup(): ButtonGroupContextValue | null;
1411
1411
  declare function getConnectedRadiusClasses(ctx: ButtonGroupContextValue, value?: string): readonly string[];
1412
1412
 
1413
1413
  /**
1414
- * Material Design 3 IconButton Variants (CVA)
1415
- *
1416
- * Type-safe variant management for IconButton component.
1417
- * Uses Tailwind CSS classes mapped to MD3 design tokens.
1418
- *
1419
- * Key differences from Button:
1420
- * - Circular shape (not pill-shaped)
1421
- * - Fixed square dimensions
1422
- * - No text content support
1423
- * - 'standard' variant instead of 'elevated'
1414
+ * IconButton variant types (MD3 specification)
1424
1415
  */
1425
- declare const iconButtonVariants: (props?: ({
1426
- variant?: "filled" | "outlined" | "tonal" | "standard" | null | undefined;
1427
- color?: "primary" | "secondary" | "tertiary" | "error" | null | undefined;
1428
- size?: "small" | "large" | "medium" | null | undefined;
1429
- selected?: boolean | null | undefined;
1430
- isDisabled?: boolean | null | undefined;
1431
- } & class_variance_authority_types.ClassProp) | undefined) => string;
1416
+ type IconButtonVariant = "standard" | "filled" | "tonal" | "outlined";
1432
1417
  /**
1433
- * Extract variant prop types from CVA
1418
+ * Color scheme (MD3 color roles)
1434
1419
  */
1435
- type IconButtonVariants = VariantProps<typeof iconButtonVariants>;
1436
-
1420
+ type IconButtonColor = "primary" | "secondary" | "tertiary" | "error";
1437
1421
  /**
1438
- * IconButton variant types (MD3 specification)
1422
+ * Icon button sizes M3 Expressive 5-tier system.
1423
+ *
1424
+ * Container heights (dp → px):
1425
+ * - xsmall: 32dp
1426
+ * - small: 40dp
1427
+ * - medium: 56dp (default)
1428
+ * - large: 96dp
1429
+ * - xlarge: 136dp
1439
1430
  */
1440
- type IconButtonVariant = "standard" | "filled" | "tonal" | "outlined";
1431
+ type IconButtonSize = "xsmall" | "small" | "medium" | "large" | "xlarge";
1441
1432
  /**
1442
- * Color scheme
1433
+ * Width variant — adjusts container width relative to height.
1434
+ * - narrow: narrower than height
1435
+ * - default: same width as height (square container)
1436
+ * - wide: wider than height
1443
1437
  */
1444
- type IconButtonColor = "primary" | "secondary" | "tertiary" | "error";
1438
+ type IconButtonWidth = "narrow" | "default" | "wide";
1445
1439
  /**
1446
- * IconButton sizes (square dimensions)
1440
+ * Shape variant controls corner rounding.
1441
+ * - round: fully circular (rounded-full)
1442
+ * - square: size-tiered corner radius (MD3 shape scale)
1447
1443
  */
1448
- type IconButtonSize = "small" | "medium" | "large";
1444
+ type IconButtonShape = "round" | "square";
1449
1445
  /**
1450
- * Material Design 3 IconButton Component Props
1446
+ * Material Design 3 Expressive IconButton Component Props
1451
1447
  *
1452
- * Icon-only button component with 4 variants and mandatory accessibility.
1453
- *
1454
- * **Key Features:**
1448
+ * Icon-only button component following the M3 Expressive spec with:
1449
+ * - 5 sizes: xsmall, small, medium (default), large, xlarge
1450
+ * - 3 width options: narrow, default, wide
1451
+ * - 2 shapes: round (circular), square (corner-radius scale)
1452
+ * - Press shape-morph: corners tighten on press when `shape="round"`
1453
+ * - Toggle support: `selected` + `selectedIcon`
1455
1454
  * - 4 variants: standard, filled, tonal, outlined
1456
- * - Icon only (no text content)
1457
- * - Circular shape (MD3 specification)
1458
1455
  * - Mandatory `aria-label` for accessibility
1459
- * - Toggle support with `selected` prop
1460
- * - 48×48px minimum touch target
1461
1456
  *
1462
1457
  * @example
1463
1458
  * ```tsx
@@ -1471,13 +1466,19 @@ type IconButtonSize = "small" | "medium" | "large";
1471
1466
  * <IconHeart />
1472
1467
  * </IconButton>
1473
1468
  *
1474
- * // Toggle button
1469
+ * // Toggle button with selectedIcon
1475
1470
  * <IconButton
1476
1471
  * aria-label={isFavorite ? "Remove from favorites" : "Add to favorites"}
1477
1472
  * selected={isFavorite}
1478
1473
  * onPress={() => setIsFavorite(!isFavorite)}
1474
+ * selectedIcon={<IconStarFilled />}
1479
1475
  * >
1480
- * {isFavorite ? <IconStarFilled /> : <IconStarOutline />}
1476
+ * <IconStarOutline />
1477
+ * </IconButton>
1478
+ *
1479
+ * // Large square shape
1480
+ * <IconButton aria-label="Settings" size="large" shape="square">
1481
+ * <IconSettings />
1481
1482
  * </IconButton>
1482
1483
  *
1483
1484
  * // Disabled
@@ -1498,21 +1499,48 @@ interface IconButtonProps extends AriaButtonProps {
1498
1499
  */
1499
1500
  color?: IconButtonColor;
1500
1501
  /**
1501
- * Size variant
1502
+ * Size tier (M3 Expressive 5-tier system)
1502
1503
  * @default 'medium'
1503
1504
  */
1504
1505
  size?: IconButtonSize;
1505
1506
  /**
1506
- * Icon content (React node). Recommended size:
1507
- * - small: 20×20px
1508
- * - medium: 24×24px
1509
- * - large: 28×28px
1507
+ * Container width relative to height.
1508
+ * - `narrow`: slimmer than the container height
1509
+ * - `default`: square container (width = height)
1510
+ * - `wide`: wider than the container height
1511
+ *
1512
+ * @default 'default'
1513
+ */
1514
+ width?: IconButtonWidth;
1515
+ /**
1516
+ * Corner shape.
1517
+ * - `round`: fully circular (pill-shaped)
1518
+ * - `square`: size-tiered corner radius from the MD3 shape scale
1519
+ *
1520
+ * Applies a press shape-morph (corners tighten on press, spring back on release).
1521
+ *
1522
+ * @default 'round'
1523
+ */
1524
+ shape?: IconButtonShape;
1525
+ /**
1526
+ * Icon content. Recommended icon sizes per container size:
1527
+ * - xsmall: 20×20px
1528
+ * - small / medium: 24×24px
1529
+ * - large: 32×32px
1530
+ * - xlarge: 40×40px
1510
1531
  */
1511
1532
  children: React__default.ReactNode;
1512
1533
  /**
1513
- * Toggle state (for toggle buttons)
1514
- * When true, button shows selected state
1515
- * @default false
1534
+ * Icon to display when `selected` is `true`.
1535
+ * When provided with a `selected` prop the button becomes a toggle button.
1536
+ * If omitted, `children` is shown in both states.
1537
+ */
1538
+ selectedIcon?: React__default.ReactNode;
1539
+ /**
1540
+ * Toggle state.
1541
+ * When defined (even as `false`) the button behaves as a toggle button and
1542
+ * `aria-pressed` is set.
1543
+ * @default undefined
1516
1544
  */
1517
1545
  selected?: boolean;
1518
1546
  /**
@@ -1531,8 +1559,8 @@ interface IconButtonProps extends AriaButtonProps {
1531
1559
  */
1532
1560
  value?: string;
1533
1561
  /**
1534
- * HTML title attribute for tooltip
1535
- * Recommended for better UX on desktop
1562
+ * HTML title attribute for tooltip.
1563
+ * Recommended for better UX on desktop.
1536
1564
  */
1537
1565
  title?: string;
1538
1566
  /**
@@ -1540,8 +1568,8 @@ interface IconButtonProps extends AriaButtonProps {
1540
1568
  */
1541
1569
  onMouseDown?: (e: React__default.MouseEvent<HTMLButtonElement>) => void;
1542
1570
  /**
1543
- * REQUIRED: Accessible label for screen readers
1544
- * Since IconButton has no visible text, this is mandatory
1571
+ * REQUIRED: Accessible label for screen readers.
1572
+ * Since IconButton has no visible text, this is mandatory.
1545
1573
  *
1546
1574
  * @example
1547
1575
  * aria-label="Delete item"
@@ -1552,19 +1580,27 @@ interface IconButtonProps extends AriaButtonProps {
1552
1580
  }
1553
1581
 
1554
1582
  /**
1555
- * Material Design 3 IconButton Component
1583
+ * Material Design 3 Expressive — IconButton Component (Layer 3: Styled)
1556
1584
  *
1557
- * Icon-only button component following MD3 specifications.
1558
- * Supports 4 variants, toggle mode, and enforces accessibility.
1585
+ * Built on React Aria for world-class accessibility. Implements the
1586
+ * Variants-vs-States architecture: all interaction/selection states are
1587
+ * expressed as data-* attributes (emitted by IconButtonHeadless) and consumed
1588
+ * by each slot via group-data-[x]/icon-button Tailwind selectors — no state
1589
+ * variants in CVA.
1559
1590
  *
1560
- * **Key Features:**
1561
- * - 4 variants: standard, filled, tonal, outlined
1562
- * - Circular shape (MD3 specification)
1563
- * - Mandatory `aria-label` for accessibility
1564
- * - Toggle support with `selected` prop
1565
- * - Ripple effect on interaction
1566
- * - 48×48px minimum touch target
1567
- * - ButtonGroup-aware: applies connected corner radii and min-width when inside a group
1591
+ * Features:
1592
+ * - M3 Expressive 5-tier sizes: xsmall, small, medium, large, xlarge
1593
+ * - 3 width options: narrow, default, wide
1594
+ * - 2 shapes: round (circular), square (MD3 corner scale)
1595
+ * - Press shape-morph (round shape springs into square corner on press)
1596
+ * - 4 variants: standard, filled, tonal, outlined
1597
+ * - 4 color roles: primary, secondary, tertiary, error
1598
+ * - Toggle support (selected + selectedIcon)
1599
+ * - ✅ MD3-correct state layer: per-variant color, opacity-8/10/10
1600
+ * - ✅ MD3-correct disabled: content opacity-38 + container on-surface/12
1601
+ * - ✅ Ripple effect on press
1602
+ * - ✅ ButtonGroup-aware: connected corner radii + min-width
1603
+ * - ✅ Mandatory aria-label for accessibility
1568
1604
  *
1569
1605
  * @example
1570
1606
  * ```tsx
@@ -1573,226 +1609,343 @@ interface IconButtonProps extends AriaButtonProps {
1573
1609
  * <IconDelete />
1574
1610
  * </IconButton>
1575
1611
  *
1576
- * // Filled with color
1577
- * <IconButton aria-label="Favorite" variant="filled" color="error">
1612
+ * // Filled with color, large
1613
+ * <IconButton aria-label="Favorite" variant="filled" color="error" size="large">
1578
1614
  * <IconHeart />
1579
1615
  * </IconButton>
1580
1616
  *
1581
- * // Toggle button
1617
+ * // Toggle button with selectedIcon
1582
1618
  * <IconButton
1583
1619
  * aria-label={selected ? "Remove favorite" : "Add favorite"}
1584
1620
  * selected={selected}
1585
1621
  * onPress={() => setSelected(!selected)}
1622
+ * selectedIcon={<IconStarFilled />}
1586
1623
  * >
1587
- * {selected ? <IconStarFilled /> : <IconStarOutline />}
1624
+ * <IconStarOutline />
1588
1625
  * </IconButton>
1589
1626
  *
1590
- * // Inside a connected ButtonGroup (corner radii applied automatically)
1591
- * <ButtonGroup variant="connected" selectionMode="multi" aria-label="Quick settings">
1592
- * <IconButton aria-label="Bluetooth"><BluetoothIcon /></IconButton>
1593
- * <IconButton aria-label="Wi-Fi"><WifiIcon /></IconButton>
1594
- * </ButtonGroup>
1627
+ * // Square shape, wide width
1628
+ * <IconButton aria-label="Menu" shape="square" width="wide" size="medium">
1629
+ * <IconMenu />
1630
+ * </IconButton>
1595
1631
  * ```
1596
1632
  */
1597
- declare const IconButton: React__default.ForwardRefExoticComponent<IconButtonProps & Omit<IconButtonVariants, "isDisabled" | "selected"> & React__default.RefAttributes<HTMLButtonElement>>;
1633
+ declare const IconButton: React__default.ForwardRefExoticComponent<IconButtonProps & React__default.RefAttributes<HTMLButtonElement>>;
1598
1634
 
1599
1635
  /**
1600
1636
  * Headless IconButton Component (Layer 2)
1601
1637
  *
1602
1638
  * Unstyled icon button primitive using React Aria for accessibility.
1603
- * Provides behavior only - bring your own styles.
1639
+ * Provides behavior AND emits MD3-compliant data-* interaction attributes
1640
+ * so the styled Layer 3 can drive all visual states through CSS alone.
1641
+ *
1642
+ * Emitted data attributes (via getInteractionDataAttributes):
1643
+ * - `data-hovered` — pointer is over the button
1644
+ * - `data-focus-visible` — keyboard/programmatic focus is visible
1645
+ * - `data-pressed` — button is being pressed
1646
+ * - `data-selected` — toggle button is in the ON state
1647
+ * - `data-disabled` — button is non-interactive
1648
+ *
1649
+ * Content flags (set explicitly):
1650
+ * - `data-toggle` — button is a toggle (selected prop is defined)
1604
1651
  *
1605
1652
  * Features:
1606
1653
  * - Full keyboard navigation (Enter, Space)
1607
- * - Screen reader support
1654
+ * - Screen reader support (aria-pressed for toggle buttons)
1608
1655
  * - Touch/pointer event handling
1609
1656
  * - Focus management
1657
+ * - Hover detection (useHover — pointer-only, not keyboard)
1610
1658
  * - Disabled state handling
1611
- * - Toggle button support (aria-pressed)
1612
1659
  *
1613
1660
  * @example
1614
1661
  * ```tsx
1615
- * // Use for custom styling
1616
- * <IconButtonHeadless className="custom-icon-button-class" aria-label="Delete">
1662
+ * // Advanced custom styling
1663
+ * <IconButtonHeadless
1664
+ * aria-label="Delete"
1665
+ * className="group/icon-button my-custom-classes"
1666
+ * isSelected={false}
1667
+ * isToggle={false}
1668
+ * isDisabled={false}
1669
+ * >
1617
1670
  * <IconDelete />
1618
1671
  * </IconButtonHeadless>
1619
1672
  * ```
1620
1673
  */
1621
1674
  interface IconButtonHeadlessProps extends AriaButtonProps {
1622
- /**
1623
- * Additional CSS classes
1624
- */
1675
+ /** Additional CSS classes */
1625
1676
  className?: string;
1626
- /**
1627
- * Icon content (React node)
1628
- */
1677
+ /** Icon content */
1629
1678
  children: React.ReactNode;
1630
- /**
1631
- * Tab index for keyboard navigation
1632
- * @default 0
1633
- */
1679
+ /** Tab index for keyboard navigation @default 0 */
1634
1680
  tabIndex?: number;
1635
- /**
1636
- * Mouse down handler (for ripple effect)
1637
- */
1681
+ /** Mouse down handler (for ripple effect) */
1638
1682
  onMouseDown?: (e: React.MouseEvent<HTMLButtonElement>) => void;
1639
- /**
1640
- * Button type attribute
1641
- * @default 'button'
1642
- */
1683
+ /** Button type attribute @default 'button' */
1643
1684
  type?: "button" | "submit" | "reset";
1644
1685
  /**
1645
- * Toggle state (for toggle buttons)
1646
- * Sets aria-pressed attribute
1686
+ * Toggle selected state.
1687
+ * When defined, sets aria-pressed and emits data-selected / data-toggle.
1647
1688
  */
1648
- selected?: boolean;
1689
+ isSelected?: boolean;
1649
1690
  /**
1650
- * REQUIRED: Accessible label for screen readers
1691
+ * Whether this button behaves as a toggle (i.e. selected prop was passed).
1692
+ * Drives `data-toggle` attribute; determines whether aria-pressed is set.
1651
1693
  */
1694
+ isToggle?: boolean;
1695
+ /** Whether the button is disabled */
1696
+ isDisabled?: boolean;
1697
+ /** REQUIRED: Accessible label for screen readers */
1652
1698
  "aria-label": string;
1653
- /**
1654
- * HTML title attribute for tooltip
1655
- */
1699
+ /** HTML title attribute for tooltip */
1656
1700
  title?: string;
1657
1701
  }
1658
1702
  declare const IconButtonHeadless: React$1.ForwardRefExoticComponent<IconButtonHeadlessProps & React$1.RefAttributes<HTMLButtonElement>>;
1659
1703
 
1660
1704
  /**
1661
- * Material Design 3 FAB Variants (CVA)
1705
+ * Material Design 3 FAB Variants — Slot-based architecture
1662
1706
  *
1663
- * Type-safe variant management for FAB component.
1664
- * Uses Tailwind CSS classes mapped to MD3 design tokens.
1707
+ * Architecture: Variants vs States
1708
+ * - CVA holds design-time structure only (no disabled/loading state variants).
1709
+ * - All interaction states are driven by data-* attributes on the root via
1710
+ * group-data-[x]/fab Tailwind selectors in each slot's base classes.
1711
+ * - Content flags (data-with-icon, data-loading) are set explicitly by the component.
1712
+ * - Self-targeting data-[x]: selectors handle root-level disabled styling.
1665
1713
  *
1666
- * Key differences from Button/IconButton:
1667
- * - NOT fully rounded (uses specific corner radius: 12px/16px/28px)
1668
- * - Always has elevation (shadow-elevation-3)
1669
- * - Larger sizes (40px/56px/96px)
1670
- * - Extended variant with variable width
1714
+ * Slot responsibilities:
1715
+ * fabVariants — root <button>; shape per size, color per variant,
1716
+ * elevation (base 3 hover 4 → focus/pressed 3),
1717
+ * self data-[disabled] styling, group/fab scope.
1718
+ * fabStateLayerVariants absolute inset overlay, opacity 0/8%/10%/10%,
1719
+ * color = icon/on-color per MD3 spec.
1720
+ * fabFocusRingVariants — keyboard focus outline ring (inset-[-3px]).
1721
+ * MUST NOT sit inside overflow-hidden.
1722
+ * fabIconVariants — icon wrapper; size per FAB size variant.
1723
+ * fabLabelVariants — extended FAB text label slot.
1724
+ *
1725
+ * MD3 Expressive size scale:
1726
+ * fab → 56dp container, 16dp corner, 24dp icon (default)
1727
+ * medium → 80dp container, 20dp corner, 28dp icon (M3 Expressive)
1728
+ * large → 96dp container, 28dp corner, 36dp icon
1729
+ * extended → 56dp height, 16dp corner, 24dp icon (+ text label)
1730
+ * small → 40dp container, 12dp corner, 24dp icon (@deprecated)
1731
+ *
1732
+ * MD3 Expressive color roles:
1733
+ * primary-container → bg-primary-container / text-on-primary-container (default)
1734
+ * secondary-container → bg-secondary-container / text-on-secondary-container
1735
+ * tertiary-container → bg-tertiary-container / text-on-tertiary-container
1736
+ * primary → bg-primary / text-on-primary (solid, M3 Expressive)
1737
+ * secondary → bg-secondary / text-on-secondary (solid, M3 Expressive)
1738
+ * tertiary → bg-tertiary / text-on-tertiary (solid, M3 Expressive)
1739
+ * surface → bg-surface-container-high / text-primary (@deprecated)
1740
+ *
1741
+ * Elevation per state (MD3 spec):
1742
+ * base → elevation-3
1743
+ * hovered → elevation-4 (shadow-elevation-4)
1744
+ * focused → elevation-3 (doubled selector wins over hover)
1745
+ * pressed → elevation-3 (doubled selector wins over hover)
1746
+ * disabled → no shadow
1747
+ *
1748
+ * State-layer opacities (MD3):
1749
+ * hover → 8% (opacity-8)
1750
+ * focus → 10% (opacity-10)
1751
+ * pressed→ 10% (opacity-10, doubled selector wins over hover's 8%)
1752
+ *
1753
+ * Important — overflow-hidden is NOT on the root button.
1754
+ * The focus ring span has `inset-[-3px]` to extend outside the button boundary,
1755
+ * which requires the root to not clip overflow. Overflow clipping is delegated
1756
+ * to the state layer and ripple container (overflow-hidden + rounded-[inherit]).
1671
1757
  */
1672
1758
  declare const fabVariants: (props?: ({
1673
- size?: "small" | "large" | "medium" | "extended" | null | undefined;
1674
- color?: "primary" | "secondary" | "tertiary" | "surface" | null | undefined;
1675
- isDisabled?: boolean | null | undefined;
1759
+ size?: "small" | "large" | "medium" | "fab" | "extended" | null | undefined;
1760
+ color?: "primary" | "primary-container" | "secondary" | "secondary-container" | "tertiary" | "tertiary-container" | "surface" | null | undefined;
1676
1761
  } & class_variance_authority_types.ClassProp) | undefined) => string;
1677
- /**
1678
- * Extract variant prop types from CVA
1679
- */
1680
1762
  type FABVariants = VariantProps<typeof fabVariants>;
1681
1763
 
1682
1764
  /**
1683
- * FAB size types
1765
+ * FAB size types — MD3 Expressive scale.
1766
+ *
1767
+ * | Value | Height | Icon | Corner | Notes |
1768
+ * |------------|--------|-------|--------|------------------------------|
1769
+ * | `fab` | 56dp | 24dp | 16dp | Default. Regular FAB. |
1770
+ * | `medium` | 80dp | 28dp | 20dp | Medium FAB (M3 Expressive). |
1771
+ * | `large` | 96dp | 36dp | 28dp | Large FAB. |
1772
+ * | `extended` | 56dp | 24dp | 16dp | Extended FAB with text label.|
1773
+ * | `small` | 40dp | 24dp | 12dp | @deprecated — Use `fab`. |
1774
+ *
1775
+ * @default 'fab'
1684
1776
  */
1685
- type FABSize = "small" | "medium" | "large" | "extended";
1777
+ type FABSize = "fab" | "medium" | "large" | "extended" | "small";
1686
1778
  /**
1687
- * FAB color scheme
1779
+ * FAB color styles — MD3 Expressive color roles.
1780
+ *
1781
+ * **Container styles (default set):**
1782
+ * - `primary-container` — bg-primary-container / text-on-primary-container (default)
1783
+ * - `secondary-container` — bg-secondary-container / text-on-secondary-container
1784
+ * - `tertiary-container` — bg-tertiary-container / text-on-tertiary-container
1785
+ *
1786
+ * **Solid styles (M3 Expressive):**
1787
+ * - `primary` — bg-primary / text-on-primary
1788
+ * - `secondary` — bg-secondary / text-on-secondary
1789
+ * - `tertiary` — bg-tertiary / text-on-tertiary
1790
+ *
1791
+ * **Deprecated:**
1792
+ * - `surface` — @deprecated Use `primary-container`. Maps to surface-container-high.
1793
+ *
1794
+ * @default 'primary-container'
1688
1795
  */
1689
- type FABColor = "primary" | "secondary" | "tertiary" | "surface";
1796
+ type FABColor = "primary-container" | "secondary-container" | "tertiary-container" | "primary" | "secondary" | "tertiary" | "surface";
1690
1797
  /**
1691
1798
  * Material Design 3 FAB (Floating Action Button) Component Props
1692
1799
  *
1693
- * High-emphasis button for primary screen action.
1694
- * Supports 4 sizes: small (40px), medium (56px), large (96px), extended (variable width with text)
1695
- *
1696
- * ⚠️ IMPORTANT:
1697
- * - Only ONE FAB per screen
1698
- * - aria-label is REQUIRED (even for extended FAB with text)
1699
- * - Use for primary constructive actions only (create, add, compose)
1700
- * - NOT for destructive (delete), navigation (back), or secondary actions
1800
+ * High-emphasis button for the primary screen action.
1801
+ * Implements the MD3 Expressive FAB spec with a slot-based architecture
1802
+ * matching Button and Switch for consistent interaction state handling.
1701
1803
  *
1702
1804
  * @example
1703
1805
  * ```tsx
1704
- * // Standard FAB (medium)
1705
- * <FAB aria-label="Create new item" icon={<IconAdd />} />
1806
+ * // Default FAB (56dp)
1807
+ * <FAB aria-label="Create" icon={<IconAdd />} />
1706
1808
  *
1707
- * // Small FAB
1708
- * <FAB aria-label="Add photo" icon={<IconCamera />} size="small" />
1809
+ * // Medium FAB (80dp, M3 Expressive)
1810
+ * <FAB aria-label="Create" icon={<IconAdd />} size="medium" />
1709
1811
  *
1710
- * // Large FAB
1812
+ * // Large FAB (96dp)
1711
1813
  * <FAB aria-label="Compose" icon={<IconEdit />} size="large" />
1712
1814
  *
1713
- * // Extended FAB (with text)
1714
- * <FAB aria-label="Create new document" icon={<IconAdd />} size="extended">
1815
+ * // Extended FAB (with text label)
1816
+ * <FAB aria-label="Create document" icon={<IconAdd />} size="extended">
1715
1817
  * Create
1716
1818
  * </FAB>
1717
1819
  *
1820
+ * // Solid primary color (M3 Expressive)
1821
+ * <FAB aria-label="Add" icon={<IconAdd />} color="primary" />
1822
+ *
1718
1823
  * // Loading state
1719
1824
  * <FAB aria-label="Creating" icon={<IconAdd />} loading />
1720
- *
1721
- * // Secondary color
1722
- * <FAB aria-label="Edit" icon={<IconEdit />} color="secondary" />
1723
1825
  * ```
1724
1826
  */
1725
1827
  interface FABProps extends AriaButtonProps {
1726
1828
  /**
1727
- * FAB size variant
1728
- * - small: 40×40px (24px icon)
1729
- * - medium: 56×56px (24px icon) - default
1730
- * - large: 96×96px (36px icon)
1731
- * - extended: Variable width with text (24px icon)
1732
- * @default 'medium'
1829
+ * FAB size variant.
1830
+ *
1831
+ * - `fab` (56dp) Default. Standard FAB.
1832
+ * - `medium` (80dp) — Medium FAB. M3 Expressive. Previously 56dp; now remapped.
1833
+ * - `large` (96dp) Large FAB.
1834
+ * - `extended` (56dp height) — Extended FAB with icon and text label.
1835
+ * - `small` (40dp) — @deprecated. Use `fab` instead.
1836
+ *
1837
+ * @default 'fab'
1733
1838
  */
1734
1839
  size?: FABSize;
1735
1840
  /**
1736
- * Color scheme
1737
- * @default 'primary'
1841
+ * Color style for the FAB.
1842
+ *
1843
+ * - `primary-container` — Default. bg-primary-container / text-on-primary-container.
1844
+ * - `secondary-container` — bg-secondary-container / text-on-secondary-container.
1845
+ * - `tertiary-container` — bg-tertiary-container / text-on-tertiary-container.
1846
+ * - `primary` — Solid. bg-primary / text-on-primary (M3 Expressive).
1847
+ * - `secondary` — Solid. bg-secondary / text-on-secondary (M3 Expressive).
1848
+ * - `tertiary` — Solid. bg-tertiary / text-on-tertiary (M3 Expressive).
1849
+ * - `surface` — @deprecated. Use `primary-container`.
1850
+ *
1851
+ * @default 'primary-container'
1738
1852
  */
1739
1853
  color?: FABColor;
1740
1854
  /**
1741
1855
  * Icon content (required).
1742
- * Recommended sizes:
1743
- * - small/medium/extended: 24x24px
1744
- * - large: 36x36px
1856
+ * Recommended icon sizes per variant:
1857
+ * - `fab` / `extended` / `small`: 24×24px
1858
+ * - `medium`: 28×28px
1859
+ * - `large`: 36×36px
1745
1860
  */
1746
1861
  icon: React__default.ReactNode;
1747
1862
  /**
1748
- * Text label (required for extended FAB, ignored for other sizes)
1863
+ * Text label only rendered for `size="extended"`.
1749
1864
  */
1750
1865
  children?: React__default.ReactNode;
1751
1866
  /**
1752
- * Mandatory accessible label for the FAB.
1753
- * This is crucial for screen readers as FAB is icon-based.
1754
- * Even extended FAB with text requires aria-label.
1867
+ * Mandatory accessible label for all FAB sizes.
1868
+ * Required even for extended FABs that have visible text.
1755
1869
  */
1756
1870
  "aria-label": string;
1757
1871
  /**
1758
- * Loading state - shows spinner, disables interaction
1872
+ * Shows a loading spinner and disables interaction.
1759
1873
  * @default false
1760
1874
  */
1761
1875
  loading?: boolean;
1762
1876
  /**
1763
- * Disable ripple effect
1877
+ * Disables the MD3 ripple press-feedback animation.
1764
1878
  * @default false
1765
1879
  */
1766
1880
  disableRipple?: boolean;
1767
1881
  /**
1768
- * Additional CSS classes (Tailwind)
1769
- * Can be used for positioning (e.g., "fixed bottom-4 right-4")
1882
+ * Additional Tailwind classes — commonly used for positioning
1883
+ * (e.g. `className="fixed bottom-4 right-4"`).
1770
1884
  */
1771
1885
  className?: string;
1772
1886
  /**
1773
- * HTML title attribute for tooltip
1887
+ * HTML title attribute for tooltip.
1774
1888
  */
1775
1889
  title?: string;
1776
1890
  /**
1777
- * Mouse down handler (for ripple effect and custom handling)
1891
+ * Mouse down handler (merged with the internal ripple handler).
1778
1892
  */
1779
1893
  onMouseDown?: (e: React__default.MouseEvent<HTMLButtonElement>) => void;
1894
+ /**
1895
+ * Tab index for keyboard navigation.
1896
+ * @default 0
1897
+ */
1898
+ tabIndex?: number | undefined;
1899
+ /**
1900
+ * Button type attribute.
1901
+ * @default 'button'
1902
+ */
1903
+ type?: "button" | "submit" | "reset";
1780
1904
  }
1781
1905
 
1782
1906
  /**
1783
- * Material Design 3 FAB (Floating Action Button) Component
1907
+ * Material Design 3 FAB (Floating Action Button) — M3 Expressive
1908
+ *
1909
+ * High-emphasis button for the primary screen action.
1910
+ * Implements the Variants-vs-States architecture: all interaction states are
1911
+ * expressed as data-* attributes on the root and consumed by each slot via
1912
+ * group-data-[x]/fab Tailwind selectors — no state variants in CVA.
1913
+ *
1914
+ * Features:
1915
+ * - ✅ MD3 Expressive size scale: fab (56dp), medium (80dp), large (96dp), extended, small (dep)
1916
+ * - ✅ Container + solid color styles (primary-container, primary, secondary*, tertiary*)
1917
+ * - ✅ Elevation 3 base → 4 hover → 3 focus/pressed per MD3 spec
1918
+ * - ✅ State-layer color = icon/on-color per MD3 spec
1919
+ * - ✅ Correct state-layer opacities: hover 8% / focus 10% / pressed 10%
1920
+ * - ✅ Dedicated focus ring slot (inset-[-3px], keyboard-only)
1921
+ * - ✅ Loading state with spinner
1922
+ * - ✅ Ripple effect (Material Design)
1923
+ * - ✅ Full keyboard accessibility via React Aria
1784
1924
  *
1785
- * High-emphasis button for primary screen action.
1786
- * Supports 4 sizes: small, medium, large, extended
1787
- * Implementation uses Tailwind CSS classes mapped to MD3 tokens.
1925
+ * @example
1926
+ * ```tsx
1927
+ * // Default FAB (56dp, primary-container)
1928
+ * <FAB aria-label="Create" icon={<IconAdd />} />
1929
+ *
1930
+ * // Medium FAB (80dp, M3 Expressive)
1931
+ * <FAB aria-label="Create" icon={<IconAdd />} size="medium" />
1932
+ *
1933
+ * // Solid primary color (M3 Expressive)
1934
+ * <FAB aria-label="Add" icon={<IconAdd />} color="primary" />
1935
+ *
1936
+ * // Extended FAB with text
1937
+ * <FAB aria-label="Create document" icon={<IconAdd />} size="extended">
1938
+ * Create
1939
+ * </FAB>
1940
+ * ```
1788
1941
  */
1789
- declare const FAB: React__default.ForwardRefExoticComponent<FABProps & Omit<FABVariants, "isDisabled"> & React__default.RefAttributes<HTMLButtonElement>>;
1942
+ declare const FAB: React__default.ForwardRefExoticComponent<FABProps & Omit<FABVariants, never> & React__default.RefAttributes<HTMLButtonElement>>;
1790
1943
 
1791
1944
  /**
1792
1945
  * Headless FAB Component (Layer 2)
1793
1946
  *
1794
1947
  * Unstyled FAB primitive using React Aria for accessibility.
1795
- * Provides behavior only - bring your own styles.
1948
+ * Provides behavior only bring your own styles.
1796
1949
  *
1797
1950
  * Features:
1798
1951
  * - Full keyboard navigation (Enter, Space)
@@ -1800,45 +1953,35 @@ declare const FAB: React__default.ForwardRefExoticComponent<FABProps & Omit<FABV
1800
1953
  * - Touch/pointer event handling
1801
1954
  * - Focus management
1802
1955
  * - Disabled state handling
1956
+ * - Press lifecycle callbacks (onPressStart/onPressEnd) for pressed state tracking
1803
1957
  *
1804
1958
  * @example
1805
1959
  * ```tsx
1806
- * // Use for custom styling
1807
- * <FABHeadless className="custom-fab-class" aria-label="Add">
1960
+ * <FABHeadless aria-label="Add" className="custom-fab">
1808
1961
  * <IconAdd />
1809
1962
  * </FABHeadless>
1810
1963
  * ```
1811
1964
  */
1812
1965
  interface FABHeadlessProps extends AriaButtonProps {
1813
- /**
1814
- * Additional CSS classes
1815
- */
1966
+ /** Additional CSS classes */
1816
1967
  className?: string;
1817
- /**
1818
- * FAB content (icon and optional text)
1819
- */
1968
+ /** FAB content (icon and optional text) */
1820
1969
  children: React.ReactNode;
1821
1970
  /**
1822
- * Tab index for keyboard navigation
1971
+ * Tab index for keyboard navigation.
1823
1972
  * @default 0
1824
1973
  */
1825
1974
  tabIndex?: number;
1826
- /**
1827
- * Mouse down handler (for ripple effect)
1828
- */
1975
+ /** Mouse down handler (for ripple effect) */
1829
1976
  onMouseDown?: (e: React.MouseEvent<HTMLButtonElement>) => void;
1830
1977
  /**
1831
- * Button type attribute
1978
+ * Button type attribute.
1832
1979
  * @default 'button'
1833
1980
  */
1834
1981
  type?: "button" | "submit" | "reset";
1835
- /**
1836
- * REQUIRED: Accessible label for screen readers
1837
- */
1982
+ /** REQUIRED: Accessible label for screen readers */
1838
1983
  "aria-label": string;
1839
- /**
1840
- * HTML title attribute for tooltip
1841
- */
1984
+ /** HTML title attribute for tooltip */
1842
1985
  title?: string;
1843
1986
  }
1844
1987
  declare const FABHeadless: React$1.ForwardRefExoticComponent<FABHeadlessProps & React$1.RefAttributes<HTMLButtonElement>>;
@@ -10627,7 +10770,7 @@ type DatePickerContainerVariants = VariantProps<typeof datePickerContainerVarian
10627
10770
  * MD3 spec: 48x48dp circle, various states and types.
10628
10771
  */
10629
10772
  declare const calendarCellVariants: (props?: ({
10630
- cellType?: "disabled" | "selected" | "default" | "today" | "selected-range-middle" | "outside-month" | null | undefined;
10773
+ cellType?: "disabled" | "default" | "selected" | "today" | "selected-range-middle" | "outside-month" | null | undefined;
10631
10774
  state?: "focused" | "enabled" | "hovered" | "pressed" | null | undefined;
10632
10775
  } & class_variance_authority_types.ClassProp) | undefined) => string;
10633
10776
  type CalendarCellVariants = VariantProps<typeof calendarCellVariants>;