@usevyre/ai-context 1.2.2 → 1.4.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.
Files changed (38) hide show
  1. package/dist/anti-patterns.json +393 -1
  2. package/dist/cheat-sheets/box.md +52 -0
  3. package/dist/cheat-sheets/button.md +2 -0
  4. package/dist/cheat-sheets/card.md +2 -0
  5. package/dist/cheat-sheets/carousel.md +50 -0
  6. package/dist/cheat-sheets/carouselslide.md +22 -0
  7. package/dist/cheat-sheets/emptystate.md +48 -0
  8. package/dist/cheat-sheets/form.md +50 -0
  9. package/dist/cheat-sheets/formfield.md +22 -0
  10. package/dist/cheat-sheets/grid.md +50 -0
  11. package/dist/cheat-sheets/griditem.md +24 -0
  12. package/dist/cheat-sheets/index.md +22 -0
  13. package/dist/cheat-sheets/input.md +2 -0
  14. package/dist/cheat-sheets/numberinput.md +41 -0
  15. package/dist/cheat-sheets/otpinput.md +51 -0
  16. package/dist/cheat-sheets/stack.md +55 -0
  17. package/dist/cheat-sheets/stat.md +41 -0
  18. package/dist/cheat-sheets/statgroup.md +23 -0
  19. package/dist/cheat-sheets/step.md +8 -0
  20. package/dist/cheat-sheets/steppanel.md +8 -0
  21. package/dist/cheat-sheets/stepper.md +59 -0
  22. package/dist/cheat-sheets/steppernav.md +8 -0
  23. package/dist/cheat-sheets/timeline.md +40 -0
  24. package/dist/cheat-sheets/timelineitem.md +28 -0
  25. package/dist/cheat-sheets/togglegroup.md +55 -0
  26. package/dist/cheat-sheets/toggleitem.md +29 -0
  27. package/dist/cheat-sheets/tree.md +48 -0
  28. package/dist/claude-context.md +770 -1
  29. package/dist/copilot-instructions.md +770 -1
  30. package/dist/cursor-rules.md +269 -1
  31. package/dist/full-context.md +769 -0
  32. package/dist/index.js +10427 -4763
  33. package/dist/schema.json +1680 -3
  34. package/dist/tokens.json +1 -1
  35. package/dist/tokens.md +1 -1
  36. package/dist/version-info.json +320 -91
  37. package/dist/windsurf-rules.md +770 -1
  38. package/package.json +1 -1
@@ -1,5 +1,5 @@
1
1
  # useVyre Rules for Windsurf
2
- # Version: 1.2.0
2
+ # Version: 1.16.0
3
3
 
4
4
  # useVyre Design System — AI Context
5
5
  # Version: 0.2.0
@@ -342,6 +342,7 @@ import { Button } from "@usevyre/react"
342
342
  - ❌ `color="..."` → Use variant prop instead
343
343
  - ❌ `icon={...}` → Use leftIcon={...} or rightIcon={...}
344
344
  - ❌ `size="icon" without aria-label` → Add aria-label describing the action
345
+ - ❌ `padding / margin / marginTop (any spacing prop) on a useVyre component` → Space BETWEEN components with <Stack gap> / <Grid gap>; space AROUND a block with <Box padding/margin> wrapping it
345
346
 
346
347
  ---
347
348
 
@@ -427,6 +428,7 @@ import { Card, CardHeader, CardBody, CardFooter } from "@usevyre/react"
427
428
 
428
429
  **Common mistakes:**
429
430
  - ❌ `variant="primary"` → Use variant="elevated" | "outlined" | "ghost" | "accent"
431
+ - ❌ `padding / margin / marginTop (any spacing prop) on a useVyre component` → Space BETWEEN components with <Stack gap> / <Grid gap>; space AROUND a block with <Box padding/margin> wrapping it
430
432
 
431
433
  ---
432
434
 
@@ -638,6 +640,7 @@ import { Input } from "@usevyre/react"
638
640
  - ❌ `size="icon"` → Use size="sm" | "md" | "lg"
639
641
  - ❌ `type="search" for search UI` → Import Command from @usevyre/react for search palettes
640
642
  - ❌ `Vue: binding Input/Textarea value without v-model` → Use v-model on <Input>/<Textarea> in Vue; in React use value + onChange
643
+ - ❌ `padding / margin / marginTop (any spacing prop) on a useVyre component` → Space BETWEEN components with <Stack gap> / <Grid gap>; space AROUND a block with <Box padding/margin> wrapping it
641
644
 
642
645
  ---
643
646
 
@@ -1380,6 +1383,716 @@ const messages = [
1380
1383
 
1381
1384
  ---
1382
1385
 
1386
+ ### Stack
1387
+
1388
+ Full one-dimensional flex layout primitive. USE INSTEAD OF <div style={{display:'flex'}}>. Covers the whole CSS flexbox surface (direction incl. reverse, wrap, align/justify/alignContent/alignSelf, grow/shrink/basis, per-axis gap) with token-locked spacing. Renders a plain <div> (or `as`).
1389
+
1390
+ ```tsx
1391
+ import { Stack } from "@usevyre/react"
1392
+
1393
+ // Props:
1394
+ // direction = "row" | "column" | "row-reverse" | "column-reverse" (default: row)
1395
+ // inline = boolean (default: false)
1396
+ // gap = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl" (default: md)
1397
+ // rowGap = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1398
+ // columnGap = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1399
+ // align = "start" | "center" | "end" | "stretch" | "baseline" (default: stretch)
1400
+ // justify = "start" | "center" | "end" | "between" | "around" | "evenly" (default: start)
1401
+ // alignContent = "start" | "center" | "end" | "stretch" | "between" | "around" | "evenly"
1402
+ // alignSelf = "auto" | "start" | "center" | "end" | "stretch" | "baseline"
1403
+ // wrap = "nowrap" | "wrap" | "wrap-reverse" (default: nowrap)
1404
+ // grow = number
1405
+ // shrink = number
1406
+ // basis = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl" | "auto" | "content" | "0"
1407
+ // width = "auto" | "full" | "fit" | "screen" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1408
+ // height = "auto" | "full" | "fit" | "screen" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1409
+ // as = string (default: div)
1410
+
1411
+ // Examples:
1412
+ <Stack direction="row" gap="md" align="center" justify="between">
1413
+ <Avatar src={user.avatar} />
1414
+ <Text>{user.name}</Text>
1415
+ <Button>Edit</Button>
1416
+ </Stack>
1417
+ <Stack wrap="wrap" rowGap="lg" columnGap="md">
1418
+ {tags.map((t) => <Tag key={t}>{t}</Tag>)}
1419
+ </Stack>
1420
+ ```
1421
+
1422
+ **Common mistakes:**
1423
+ - ❌ `<div style={{ display: 'flex', gap: 12 }}>` → Use <Stack gap="md"> — gap is a token
1424
+ - ❌ `gap={12} or gap="12px"` → Use gap="none|xs|sm|md|lg|xl|2xl"
1425
+ - ❌ `direction="vertical" / "horizontal"` → Use direction="row" or "column" (also row-reverse / column-reverse)
1426
+ - ❌ `style={{ width: "100%" }} / style={{ height: 320 }}` → Use the width / height prop: width="full", width="md", height="screen", etc.
1427
+
1428
+ ---
1429
+
1430
+ ### Grid
1431
+
1432
+ Two-dimensional CSS grid primitive. Explicit column/row counts (or auto-fit), auto-flow control, token gap. Pair with GridItem for cell spanning/placement. Renders a plain <div> (or `as`).
1433
+
1434
+ ```tsx
1435
+ import { Grid, GridItem } from "@usevyre/react"
1436
+
1437
+ // Props:
1438
+ // columns = number | "auto-fit" (default: 1)
1439
+ // rows = number | "auto"
1440
+ // flow = "row" | "column" | "dense" | "row-dense" | "column-dense"
1441
+ // gap = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl" (default: md)
1442
+ // rowGap = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1443
+ // columnGap = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1444
+ // align = "start" | "center" | "end" | "stretch" (default: stretch)
1445
+ // justify = "start" | "center" | "end" | "stretch"
1446
+ // width = "auto" | "full" | "fit" | "screen" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1447
+ // height = "auto" | "full" | "fit" | "screen" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1448
+ // as = string (default: div)
1449
+
1450
+ // Examples:
1451
+ <Grid columns={3} gap="lg">
1452
+ <GridItem colSpan={2}><Card>Wide</Card></GridItem>
1453
+ <Card>Two</Card>
1454
+ <Card>Three</Card>
1455
+ </Grid>
1456
+ <Grid columns="auto-fit" gap="md">
1457
+ {items.map((i) => <Card key={i.id}>{i.title}</Card>)}
1458
+ </Grid>
1459
+ ```
1460
+
1461
+ **Common mistakes:**
1462
+ - ❌ `<div style={{ display:'grid', gridTemplateColumns:'1fr 1fr 1fr' }}>` → Use <Grid columns={3} gap="md">
1463
+ - ❌ `columns="3" (string)` → Use columns={3} or columns="auto-fit"
1464
+ - ❌ `Nested div with inline grid-column for spanning` → Wrap the cell in <GridItem colSpan={2}>
1465
+ - ❌ `style={{ width: "100%" }} / style={{ height: 320 }}` → Use the width / height prop: width="full", width="md", height="screen", etc.
1466
+
1467
+ ---
1468
+
1469
+ ### GridItem
1470
+
1471
+ Child placement inside <Grid>. Sets column/row span and start lines. Renders a plain <div> (or `as`).
1472
+
1473
+ ```tsx
1474
+ import { GridItem } from "@usevyre/react"
1475
+
1476
+ // Props:
1477
+ // colSpan = number
1478
+ // rowSpan = number
1479
+ // colStart = number
1480
+ // rowStart = number
1481
+ // as = string (default: div)
1482
+
1483
+ // Examples:
1484
+ <Grid columns={4} gap="md">
1485
+ <GridItem colSpan={2}>Featured</GridItem>
1486
+ <div>a</div>
1487
+ <div>b</div>
1488
+ </Grid>
1489
+ ```
1490
+
1491
+ **Common mistakes:**
1492
+ - ❌ `GridItem outside a Grid` → Place <GridItem> directly inside <Grid>
1493
+
1494
+ ---
1495
+
1496
+ ### Box
1497
+
1498
+ Spacing-only container plus a controlled escape hatch. Token padding/margin with shorthand, per-axis (X/Y) and per-side (Top/Right/Bottom/Left) overrides. The `style` prop is an explicit anti-pattern escape hatch. Renders a plain <div> (or `as`).
1499
+
1500
+ ```tsx
1501
+ import { Box } from "@usevyre/react"
1502
+
1503
+ // Props:
1504
+ // padding = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1505
+ // paddingX = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1506
+ // paddingY = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1507
+ // paddingTop = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1508
+ // paddingRight = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1509
+ // paddingBottom = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1510
+ // paddingLeft = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1511
+ // margin = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1512
+ // marginX = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1513
+ // marginY = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1514
+ // marginTop = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1515
+ // marginRight = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1516
+ // marginBottom = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1517
+ // marginLeft = "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1518
+ // width = "auto" | "full" | "fit" | "screen" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1519
+ // height = "auto" | "full" | "fit" | "screen" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl"
1520
+ // as = string (default: div)
1521
+ // style = React.CSSProperties
1522
+
1523
+ // Examples:
1524
+ <Box as="section" paddingX="lg" paddingY="md">
1525
+ <Heading>Settings</Heading>
1526
+ </Box>
1527
+ <Box marginTop="xl"><Separator /></Box>
1528
+ ```
1529
+
1530
+ **Common mistakes:**
1531
+ - ❌ `<Box style={{ padding: 16 }}>` → Use <Box padding="md"> (or paddingX/paddingTop/...)
1532
+ - ❌ `Using Box for flex/grid layout` → Use <Stack> or <Grid>
1533
+ - ❌ `style={{ width: "100%" }} / style={{ height: 320 }}` → Use the width / height prop: width="full", width="md", height="screen", etc.
1534
+
1535
+ ---
1536
+
1537
+ ### Form
1538
+
1539
+ Controlled, data-driven form. Zero dependencies. Validation runs on submit and (after the first submit) on blur. Errors map into the wrapped Field automatically (state=error + hint=message). Compose with FormField, which wires name/value/onChange/onBlur into a single control child.
1540
+
1541
+ ```tsx
1542
+ import { Form, FormField } from "@usevyre/react"
1543
+
1544
+ // Props:
1545
+ // values = Record<string, any>
1546
+ // defaultValues = Record<string, any>
1547
+ // onChange = function
1548
+ // onSubmit = function
1549
+ // onInvalid = function
1550
+
1551
+ // Examples:
1552
+ const [values, setValues] = useState({ email: "", password: "" });
1553
+
1554
+ <Form values={values} onChange={setValues} onSubmit={(v) => signIn(v)}>
1555
+ <FormField name="email" label="Email" rules={{ required: true, email: true }}>
1556
+ <Input type="email" />
1557
+ </FormField>
1558
+ <FormField name="password" label="Password" rules={{ required: true, minLength: 8 }}>
1559
+ <Input type="password" />
1560
+ </FormField>
1561
+ <Button type="submit" variant="primary">Sign in</Button>
1562
+ </Form>
1563
+ <FormField
1564
+ name="confirm"
1565
+ label="Confirm password"
1566
+ rules={{
1567
+ required: true,
1568
+ validate: (v, all) => v === all.password ? null : "Passwords do not match",
1569
+ }}
1570
+ >
1571
+ <Input type="password" />
1572
+ </FormField>
1573
+ ```
1574
+
1575
+ **Common mistakes:**
1576
+ - ❌ `Manually tracking each field's error state with useState` → Wrap controls in <FormField name rules> and let Form manage errors
1577
+ - ❌ `Adding a validation library (zod/yup) just for basic rules` → Use rules={{ required, minLength, pattern, email, validate }}
1578
+ - ❌ `<FormField> with multiple control children` → Use one control per FormField (Input/Textarea/Select/etc.)
1579
+ - ❌ `<FormField> outside a <Form>` → Always nest FormField inside <Form>
1580
+
1581
+ ---
1582
+
1583
+ ### FormField
1584
+
1585
+ A single labelled, validated field inside <Form>. Injects name/value/onChange/onBlur into its one control child and wraps it in <Field> (label + error state + hint).
1586
+
1587
+ ```tsx
1588
+ import { FormField } from "@usevyre/react"
1589
+
1590
+ // Props:
1591
+ // name = string
1592
+ // label = string
1593
+ // hint = string
1594
+ // rules = object
1595
+
1596
+ // Examples:
1597
+ <FormField name="bio" label="Bio" hint="Max 200 characters" rules={{ maxLength: 200 }}>
1598
+ <Textarea />
1599
+ </FormField>
1600
+ ```
1601
+
1602
+ **Common mistakes:**
1603
+ - ❌ `Putting onChange/value manually on the control inside FormField` → Let FormField wire the control; only pass static props (type, placeholder)
1604
+
1605
+ ---
1606
+
1607
+ ### NumberInput
1608
+
1609
+ Controlled numeric input with −/+ stepper buttons. onChange emits a NUMBER (or null when empty) — NOT an event. Drops straight into <FormField> (Form handles the non-event value). Clamps to min/max on blur; keyboard ArrowUp/Down ±step, Shift+Arrow ±step×10.
1610
+
1611
+ ```tsx
1612
+ import { NumberInput } from "@usevyre/react"
1613
+
1614
+ // Props:
1615
+ // value = number | null
1616
+ // defaultValue = number | null (default: null)
1617
+ // onChange = function
1618
+ // min = number
1619
+ // max = number
1620
+ // step = number (default: 1)
1621
+ // precision = number
1622
+ // size = "sm" | "md" | "lg" (default: md)
1623
+ // disabled = boolean (default: false)
1624
+ // readOnly = boolean (default: false)
1625
+
1626
+ // Examples:
1627
+ const [qty, setQty] = useState<number | null>(1);
1628
+
1629
+ <NumberInput value={qty} onChange={setQty} min={1} max={99} />
1630
+ <FormField name="age" label="Age" rules={{ required: true, min: 18 }}>
1631
+ <NumberInput min={0} max={120} />
1632
+ </FormField>
1633
+ ```
1634
+
1635
+ **Common mistakes:**
1636
+ - ❌ `onChange={(e) => set(e.target.value)}` → onChange={(value) => set(value)} — value is number | null
1637
+ - ❌ `Using <Input type="number"> for numeric fields` → Use <NumberInput value onChange min max step />
1638
+ - ❌ `Parsing the value with Number() in form state` → Store the value directly; it is already number | null
1639
+
1640
+ ---
1641
+
1642
+ ### ToggleGroup
1643
+
1644
+ Segmented control. CONTROLLED — the group owns the value. onChange emits the VALUE (not an event). type=single → value:string|null; type=multiple → value:string[]. Provide options[] for simple lists or <ToggleItem value> children for custom content. Distinct from Switch (boolean), ButtonGroup (layout only), RadioGroup (form radios, single only).
1645
+
1646
+ ```tsx
1647
+ import { ToggleGroup, ToggleItem } from "@usevyre/react"
1648
+
1649
+ // Props:
1650
+ // type = "single" | "multiple" (default: single)
1651
+ // value = string | null | string[]
1652
+ // onChange = function
1653
+ // options = array
1654
+ // size = "sm" | "md" | "lg" (default: md)
1655
+ // orientation = "horizontal" | "vertical" (default: horizontal)
1656
+ // disabled = boolean (default: false)
1657
+
1658
+ // Examples:
1659
+ const [view, setView] = useState<string | null>("grid");
1660
+
1661
+ <ToggleGroup
1662
+ value={view}
1663
+ onChange={setView}
1664
+ options={[
1665
+ { value: "grid", label: "Grid" },
1666
+ { value: "list", label: "List" },
1667
+ ]}
1668
+ />
1669
+ const [fmt, setFmt] = useState<string[]>(["bold"]);
1670
+
1671
+ <ToggleGroup type="multiple" value={fmt} onChange={setFmt}>
1672
+ <ToggleItem value="bold">B</ToggleItem>
1673
+ <ToggleItem value="italic">I</ToggleItem>
1674
+ <ToggleItem value="underline">U</ToggleItem>
1675
+ </ToggleGroup>
1676
+ ```
1677
+
1678
+ **Common mistakes:**
1679
+ - ❌ `onChange={(e) => set(e.target.value)}` → onChange={(value) => set(value)} — string|null (single) or string[] (multiple)
1680
+ - ❌ `Using ToggleGroup for a single on/off setting` → Use <Switch> for on/off; ToggleGroup is for choosing among options
1681
+ - ❌ `type="multiple" with a string value` → value={['a','b']} and onChange receives string[]
1682
+ - ❌ `<ToggleItem> outside <ToggleGroup>` → Always nest ToggleItem inside ToggleGroup (or use options)
1683
+
1684
+ ---
1685
+
1686
+ ### ToggleItem
1687
+
1688
+ A single toggle button inside <ToggleGroup>. Reads selection state from the group via context.
1689
+
1690
+ ```tsx
1691
+ import { ToggleItem } from "@usevyre/react"
1692
+
1693
+ // Props:
1694
+ // value = string
1695
+ // icon = ReactNode
1696
+ // disabled = boolean (default: false)
1697
+
1698
+ // Examples:
1699
+ <ToggleGroup value={v} onChange={setV}>
1700
+ <ToggleItem value="left">Left</ToggleItem>
1701
+ <ToggleItem value="center">Center</ToggleItem>
1702
+ </ToggleGroup>
1703
+ ```
1704
+
1705
+ **Common mistakes:**
1706
+ - ❌ `Tracking selected state on ToggleItem yourself` → Only set value; the group controls selected state
1707
+
1708
+ ---
1709
+
1710
+ ### Stepper
1711
+
1712
+ Multi-step flow indicator + controller (onboarding/checkout/wizard). CONTROLLED by a 0-based index. Compose StepperNav (with Step indicators) and StepPanel (content shown when its index == active). Step/StepPanel take an explicit 0-based `index`. Not Tabs — Stepper is an ORDERED linear flow with completed/current/upcoming states.
1713
+
1714
+ ```tsx
1715
+ import { Stepper, StepperNav, Step, StepPanel } from "@usevyre/react"
1716
+
1717
+ // Props:
1718
+ // value = number
1719
+ // defaultValue = number (default: 0)
1720
+ // onChange = function
1721
+ // orientation = "horizontal" | "vertical" (default: horizontal)
1722
+ // clickable = boolean (default: false)
1723
+
1724
+ // Examples:
1725
+ const [step, setStep] = useState(0);
1726
+
1727
+ <Stepper value={step} onChange={setStep}>
1728
+ <StepperNav>
1729
+ <Step index={0} label="Account" />
1730
+ <Step index={1} label="Profile" />
1731
+ <Step index={2} label="Done" />
1732
+ </StepperNav>
1733
+ <StepPanel index={0}><AccountForm /></StepPanel>
1734
+ <StepPanel index={1}><ProfileForm /></StepPanel>
1735
+ <StepPanel index={2}><Summary /></StepPanel>
1736
+ <Stack direction="row" gap="sm" justify="between">
1737
+ <Button onClick={() => setStep((s) => s - 1)} disabled={step === 0}>Back</Button>
1738
+ <Button variant="primary" onClick={() => setStep((s) => s + 1)}>Next</Button>
1739
+ </Stack>
1740
+ </Stepper>
1741
+ <Stepper orientation="vertical" defaultValue={1}>
1742
+ <StepperNav>
1743
+ <Step index={0} label="Cart" description="2 items" />
1744
+ <Step index={1} label="Shipping" description="Enter address" />
1745
+ <Step index={2} label="Payment" />
1746
+ </StepperNav>
1747
+ </Stepper>
1748
+ ```
1749
+
1750
+ **Common mistakes:**
1751
+ - ❌ `Using Tabs for a wizard / checkout flow` → Use <Stepper> with StepperNav + Step + StepPanel
1752
+ - ❌ `onChange={(e) => set(e.target.value)}` → onChange={(index) => setStep(index)}
1753
+ - ❌ `Manually toggling which panel is visible` → Give each StepPanel an index; Stepper shows the active one
1754
+ - ❌ `<Step> or <StepPanel> outside <Stepper>` → Nest Step inside StepperNav, StepPanel inside Stepper
1755
+
1756
+ ---
1757
+
1758
+ ### StepperNav
1759
+
1760
+ Container for Step indicators inside <Stepper>. Lays them out per the Stepper's orientation.
1761
+
1762
+ ```tsx
1763
+ import { Stepper, StepperNav, Step, StepPanel } from "@usevyre/react"
1764
+
1765
+ ```
1766
+
1767
+ ---
1768
+
1769
+ ### Step
1770
+
1771
+ One step indicator inside <StepperNav>. State (completed/current/upcoming) derives from the Stepper's active index automatically.
1772
+
1773
+ ```tsx
1774
+ import { Stepper, StepperNav, Step, StepPanel } from "@usevyre/react"
1775
+
1776
+ // Props:
1777
+ // index = number
1778
+ // label = ReactNode
1779
+ // description = ReactNode
1780
+ // icon = ReactNode
1781
+
1782
+ ```
1783
+
1784
+ ---
1785
+
1786
+ ### StepPanel
1787
+
1788
+ Content for one step. Renders its children only when its index equals the Stepper's active step.
1789
+
1790
+ ```tsx
1791
+ import { Stepper, StepperNav, Step, StepPanel } from "@usevyre/react"
1792
+
1793
+ // Props:
1794
+ // index = number
1795
+
1796
+ ```
1797
+
1798
+ ---
1799
+
1800
+ ### EmptyState
1801
+
1802
+ Presentational placeholder for empty lists, tables, and search results. No state. title/description/variant/size are props; the optional call-to-action goes in children (React) or the default slot (Vue). variant picks a preset icon (default=box, search=magnifier, error=warning); pass `icon` (or #icon slot) to override.
1803
+
1804
+ ```tsx
1805
+ import { EmptyState } from "@usevyre/react"
1806
+
1807
+ // Props:
1808
+ // title = string
1809
+ // description = string
1810
+ // variant = "default" | "search" | "error" (default: default)
1811
+ // icon = ReactNode
1812
+ // size = "sm" | "md" | "lg" (default: md)
1813
+ // children = ReactNode
1814
+
1815
+ // Examples:
1816
+ <EmptyState
1817
+ variant="search"
1818
+ title="No results"
1819
+ description="Try a different search term."
1820
+ >
1821
+ <Button variant="secondary" onClick={reset}>Clear filters</Button>
1822
+ </EmptyState>
1823
+ <EmptyState
1824
+ size="lg"
1825
+ title="No projects yet"
1826
+ description="Create your first project to get started."
1827
+ >
1828
+ <Button variant="primary">New project</Button>
1829
+ </EmptyState>
1830
+ ```
1831
+
1832
+ **Common mistakes:**
1833
+ - ❌ `Building an empty placeholder with a bare <div> + centered text` → Use <EmptyState title description variant>
1834
+ - ❌ `action / cta prop` → Put the Button as children of EmptyState
1835
+ - ❌ `Using EmptyState for a loading state` → Use <Skeleton> while loading; EmptyState when the result set is empty
1836
+
1837
+ ---
1838
+
1839
+ ### Stat
1840
+
1841
+ Presentational dashboard KPI. No state. The arrow DIRECTION follows the sign of `delta` (the actual change: -0.4% → down arrow). The arrow/delta COLOR is set explicitly by `trend` (up=success, down=danger, neutral=muted) — so 'churn -0.4%, trend=up' shows a green DOWN arrow. Wrap several in StatGroup for an evenly-split row with dividers.
1842
+
1843
+ ```tsx
1844
+ import { Stat, StatGroup } from "@usevyre/react"
1845
+
1846
+ // Props:
1847
+ // label = string
1848
+ // value = string | number
1849
+ // delta = string | number
1850
+ // trend = "up" | "down" | "neutral" (default: neutral)
1851
+ // deltaLabel = string
1852
+ // icon = ReactNode
1853
+ // size = "sm" | "md" | "lg" (default: md)
1854
+
1855
+ // Examples:
1856
+ <StatGroup>
1857
+ <Stat label="Revenue" value="$48.2k" delta="+12%" trend="up" deltaLabel="vs last month" />
1858
+ <Stat label="Churn" value="2.1%" delta="-0.4%" trend="up" deltaLabel="lower is better" />
1859
+ <Stat label="Orders" value="1,204" delta="0%" trend="neutral" />
1860
+ </StatGroup>
1861
+ <Stat label="Active users" value="12,840" delta="+3.2%" trend="up"
1862
+ icon={<UsersIcon />} size="lg" />
1863
+ ```
1864
+
1865
+ **Common mistakes:**
1866
+ - ❌ `Assuming trend flips the arrow direction` → delta="-0.4%" always shows a down arrow; trend="up" just colors it green
1867
+ - ❌ `Building a KPI card with Card + manual layout` → Use <Stat label value delta trend />
1868
+ - ❌ `Laying out a KPI row with custom flex + dividers` → Wrap the Stats in <StatGroup>
1869
+
1870
+ ---
1871
+
1872
+ ### StatGroup
1873
+
1874
+ Evenly-split row of <Stat> with subtle dividers between items. Each Stat flexes to equal width.
1875
+
1876
+ ```tsx
1877
+ import { Stat, StatGroup } from "@usevyre/react"
1878
+
1879
+ // Examples:
1880
+ <StatGroup>
1881
+ <Stat label="MRR" value="$9.6k" delta="+5%" trend="up" />
1882
+ <Stat label="Refunds" value="32" delta="+8" trend="down" />
1883
+ </StatGroup>
1884
+ ```
1885
+
1886
+ **Common mistakes:**
1887
+ - ❌ `Putting non-Stat children in StatGroup` → Only place <Stat> elements inside StatGroup
1888
+
1889
+ ---
1890
+
1891
+ ### Timeline
1892
+
1893
+ Vertical activity feed for audit logs and history. Presentational — a status dot per item plus a connector line. Pass `items` for plain logs, or TimelineItem children for rich per-item content. Timeline does NOT reorder; pass items in the order you want shown.
1894
+
1895
+ ```tsx
1896
+ import { Timeline, TimelineItem } from "@usevyre/react"
1897
+
1898
+ // Props:
1899
+ // items = array
1900
+ // children = ReactNode
1901
+
1902
+ // Examples:
1903
+ <Timeline
1904
+ items={[
1905
+ { title: "Deployed v2.1", time: "2m ago", status: "success" },
1906
+ { title: "Build started", time: "5m ago", status: "info" },
1907
+ { title: "Push to main", time: "6m ago" },
1908
+ ]}
1909
+ />
1910
+ <Timeline>
1911
+ <TimelineItem title="Invoice paid" time="Apr 2" status="success">
1912
+ <Text size="sm">$1,200 — <a href="#">view receipt</a></Text>
1913
+ </TimelineItem>
1914
+ <TimelineItem title="Invoice sent" time="Mar 28" status="info" />
1915
+ </Timeline>
1916
+ ```
1917
+
1918
+ **Common mistakes:**
1919
+ - ❌ `Building an activity log with a <ul> + manual dots/lines` → Use <Timeline items={[...]} /> or TimelineItem children
1920
+ - ❌ `Using Stepper for a history/audit feed` → Use <Timeline> for logs/history; Stepper for wizards
1921
+ - ❌ `Expecting Timeline to sort by time` → Sort the array yourself (newest- or oldest-first)
1922
+
1923
+ ---
1924
+
1925
+ ### TimelineItem
1926
+
1927
+ One entry in a <Timeline>. Renders a status-colored dot (or a custom icon), a title, an optional time, and optional rich content.
1928
+
1929
+ ```tsx
1930
+ import { Timeline, TimelineItem } from "@usevyre/react"
1931
+
1932
+ // Props:
1933
+ // title = ReactNode
1934
+ // time = ReactNode
1935
+ // status = "default" | "success" | "warning" | "danger" | "info" (default: default)
1936
+ // icon = ReactNode
1937
+ // children = ReactNode
1938
+
1939
+ // Examples:
1940
+ <TimelineItem title="Comment added" time="1h ago" status="default">
1941
+ <Text size="sm">“Looks good to me 👍”</Text>
1942
+ </TimelineItem>
1943
+ ```
1944
+
1945
+ **Common mistakes:**
1946
+ - ❌ `<TimelineItem> outside <Timeline>` → Always nest TimelineItem inside Timeline
1947
+
1948
+ ---
1949
+
1950
+ ### Tree
1951
+
1952
+ Hierarchical tree view for file explorers and nested navigation. DATA-DRIVEN and CONTROLLED — pass a nested `data` array; the Tree renders recursively. Single selection. A node WITH children is a folder (click toggles expand); a leaf fires onSelect. Keyboard: ArrowUp/Down move, ArrowRight/Left expand/collapse, Enter/Space select.
1953
+
1954
+ ```tsx
1955
+ import { Tree } from "@usevyre/react"
1956
+
1957
+ // Props:
1958
+ // data = TreeNode[]
1959
+ // expandedIds = string[]
1960
+ // defaultExpandedIds = string[] (default: [])
1961
+ // onExpandedChange = function
1962
+ // selectedId = string | null
1963
+ // defaultSelectedId = string | null (default: null)
1964
+ // onSelect = function
1965
+
1966
+ // Examples:
1967
+ const [sel, setSel] = useState<string | null>("src/a.ts");
1968
+
1969
+ <Tree
1970
+ data={[
1971
+ { id: "src", label: "src", children: [
1972
+ { id: "src/a.ts", label: "a.ts" },
1973
+ { id: "src/b", label: "b", children: [
1974
+ { id: "src/b/c.ts", label: "c.ts" },
1975
+ ]},
1976
+ ]},
1977
+ { id: "README.md", label: "README.md" },
1978
+ ]}
1979
+ selectedId={sel}
1980
+ onSelect={setSel}
1981
+ defaultExpandedIds={["src"]}
1982
+ />
1983
+ const [open, setOpen] = useState<string[]>(["root"]);
1984
+
1985
+ <Tree data={tree} expandedIds={open} onExpandedChange={setOpen} />
1986
+ ```
1987
+
1988
+ **Common mistakes:**
1989
+ - ❌ `Rendering a nested <ul> tree by hand with manual expand state` → Pass a nested `data` array to <Tree> and control expandedIds/selectedId
1990
+ - ❌ `onSelect={(e) => ...}` → onSelect={(id) => setSelected(id)}
1991
+ - ❌ `Mutating the data array to expand/collapse` → Track expandedIds in state (or use defaultExpandedIds)
1992
+ - ❌ `Using DropdownMenu submenus for a file tree` → Use <Tree> for file explorers / nested nav
1993
+
1994
+ ---
1995
+
1996
+ ### OTPInput
1997
+
1998
+ Segmented one-time-code input for verification / 2FA. CONTROLLED. onChange emits the STRING value (not an event), and onComplete fires once when every slot is filled. Paste-aware (pasting a full code fills all slots), auto-advance on input, backspace moves to the previous slot, arrow keys navigate. Drops straight into <FormField>.
1999
+
2000
+ ```tsx
2001
+ import { OTPInput } from "@usevyre/react"
2002
+
2003
+ // Props:
2004
+ // value = string
2005
+ // defaultValue = string (default: "")
2006
+ // onChange = function
2007
+ // onComplete = function
2008
+ // length = number (default: 6)
2009
+ // type = "numeric" | "alphanumeric" (default: numeric)
2010
+ // mask = boolean (default: false)
2011
+ // size = "sm" | "md" | "lg" (default: md)
2012
+ // disabled = boolean (default: false)
2013
+ // autoFocus = boolean (default: false)
2014
+
2015
+ // Examples:
2016
+ const [code, setCode] = useState("");
2017
+
2018
+ <OTPInput
2019
+ value={code}
2020
+ onChange={setCode}
2021
+ onComplete={(c) => verify(c)}
2022
+ autoFocus
2023
+ />
2024
+ <FormField name="otp" label="Verification code"
2025
+ rules={{ required: true, minLength: 6 }}>
2026
+ <OTPInput length={6} />
2027
+ </FormField>
2028
+ ```
2029
+
2030
+ **Common mistakes:**
2031
+ - ❌ `onChange={(e) => set(e.target.value)}` → onChange={(value) => setCode(value)}
2032
+ - ❌ `Six separate <Input> boxes wired by hand` → Use <OTPInput length={6} value onChange />
2033
+ - ❌ `Reading completion by comparing length yourself` → Use onComplete={(code) => verify(code)}
2034
+ - ❌ `type="password" to hide digits` → Use mask (type stays numeric/alphanumeric)
2035
+
2036
+ ---
2037
+
2038
+ ### Carousel
2039
+
2040
+ Accessible content slider for galleries, onboarding, and testimonials. CONTROLLED by a 0-based slide index. Compose CarouselSlide children (slide order = index). Snap scrolling, clickable dot indicators, prev/next arrows, ArrowLeft/Right keyboard, optional loop and autoPlay (autoplay pauses on hover/focus). onChange emits the index (not an event).
2041
+
2042
+ ```tsx
2043
+ import { Carousel, CarouselSlide } from "@usevyre/react"
2044
+
2045
+ // Props:
2046
+ // value = number
2047
+ // defaultValue = number (default: 0)
2048
+ // onChange = function
2049
+ // loop = boolean (default: false)
2050
+ // autoPlay = boolean (default: false)
2051
+ // interval = number (default: 5000)
2052
+ // showArrows = boolean (default: true)
2053
+ // showIndicators = boolean (default: true)
2054
+
2055
+ // Examples:
2056
+ const [i, setI] = useState(0);
2057
+
2058
+ <Carousel value={i} onChange={setI} loop>
2059
+ <CarouselSlide><img src="/a.jpg" alt="A" /></CarouselSlide>
2060
+ <CarouselSlide><img src="/b.jpg" alt="B" /></CarouselSlide>
2061
+ <CarouselSlide><img src="/c.jpg" alt="C" /></CarouselSlide>
2062
+ </Carousel>
2063
+ <Carousel autoPlay interval={4000} showArrows={false}>
2064
+ <CarouselSlide><Welcome /></CarouselSlide>
2065
+ <CarouselSlide><Features /></CarouselSlide>
2066
+ <CarouselSlide><GetStarted /></CarouselSlide>
2067
+ </Carousel>
2068
+ ```
2069
+
2070
+ **Common mistakes:**
2071
+ - ❌ `onChange={(e) => set(e.target.value)}` → onChange={(index) => setIndex(index)}
2072
+ - ❌ `Putting raw elements directly in Carousel` → Wrap each slide in <CarouselSlide>
2073
+ - ❌ `Building a slider with manual scroll + dot state` → Use <Carousel> with CarouselSlide children
2074
+ - ❌ `autoPlay without considering reduced motion / pausing` → Carousel already pauses on hover/focus; keep interval reasonable or omit autoPlay
2075
+
2076
+ ---
2077
+
2078
+ ### CarouselSlide
2079
+
2080
+ One slide inside <Carousel>. Holds arbitrary content (image, Card, testimonial). Slide order determines its index.
2081
+
2082
+ ```tsx
2083
+ import { Carousel, CarouselSlide } from "@usevyre/react"
2084
+
2085
+ // Examples:
2086
+ <CarouselSlide>
2087
+ <Card><CardBody>“Best tool ever.” — Ada</CardBody></Card>
2088
+ </CarouselSlide>
2089
+ ```
2090
+
2091
+ **Common mistakes:**
2092
+ - ❌ `<CarouselSlide> outside <Carousel>` → Always nest CarouselSlide inside Carousel
2093
+
2094
+ ---
2095
+
1383
2096
  ### DateRangePicker
1384
2097
 
1385
2098
  Start/end date range picker. Built on Calendar (mode=range) with a friendlier { from, to } object API, a two-month side-by-side view, and preset shortcuts. Use this for report/filter date ranges; use DatePicker for a single date.
@@ -1433,11 +2146,13 @@ If you generate these, you are hallucinating.
1433
2146
  - ❌ `<Button color="...">` → Use variant prop instead
1434
2147
  - ❌ `<Button icon={...}>` → Use leftIcon={...} or rightIcon={...}
1435
2148
  - ❌ `<Button size="icon" without aria-label>` → Add aria-label describing the action
2149
+ - ❌ `<Button padding / margin / marginTop (any spacing prop) on a useVyre component>` → Space BETWEEN components with <Stack gap> / <Grid gap>; space AROUND a block with <Box padding/margin> wrapping it
1436
2150
  - ❌ `<Calendar Calendar for an input field that opens a popover>` → Use <DatePicker /> (single date) or <DateRangePicker /> (range)
1437
2151
  - ❌ `<Calendar value as tuple for mode="single">` → Pass value matching mode; use mode="range" for [start,end]
1438
2152
  - ❌ `<DatePicker DatePicker mode="range" for { from, to } object>` → Use <DateRangePicker /> for the { from, to } object API + presets + dual month
1439
2153
  - ❌ `<DatePicker DatePicker without value/onChange>` → Provide value and onChange (e.g. from useState)
1440
2154
  - ❌ `<Card variant="primary">` → Use variant="elevated" | "outlined" | "ghost" | "accent"
2155
+ - ❌ `<Card padding / margin / marginTop (any spacing prop) on a useVyre component>` → Space BETWEEN components with <Stack gap> / <Grid gap>; space AROUND a block with <Box padding/margin> wrapping it
1441
2156
  - ❌ `<Checkbox size="lg">` → Use size="md"
1442
2157
  - ❌ `<RadioGroup <Radio> used outside a <RadioGroup>>` → Always wrap <Radio> in <RadioGroup>
1443
2158
  - ❌ `<RadioGroup RadioGroup without value/onChange (React) or v-model (Vue)>` → Bind value + onChange (React) or v-model (Vue); or defaultValue for uncontrolled in React
@@ -1452,6 +2167,7 @@ If you generate these, you are hallucinating.
1452
2167
  - ❌ `<Input size="icon">` → Use size="sm" | "md" | "lg"
1453
2168
  - ❌ `<Input type="search" for search UI>` → Import Command from @usevyre/react for search palettes
1454
2169
  - ❌ `<Input Vue: binding Input/Textarea value without v-model>` → Use v-model on <Input>/<Textarea> in Vue; in React use value + onChange
2170
+ - ❌ `<Input padding / margin / marginTop (any spacing prop) on a useVyre component>` → Space BETWEEN components with <Stack gap> / <Grid gap>; space AROUND a block with <Box padding/margin> wrapping it
1455
2171
  - ❌ `<Modal size="xl">` → Use size="lg" or size="full"
1456
2172
  - ❌ `<Popover placement="top-center">` → Use placement="top" for centered placement
1457
2173
  - ❌ `<Progress value > 100>` → Normalize your value to 0–100 range before passing
@@ -1488,6 +2204,59 @@ If you generate these, you are hallucinating.
1488
2204
  - ❌ `<Conversation Expecting Conversation to store/append messages>` → Append to your own state in onSend (or @send) and pass it back via value
1489
2205
  - ❌ `<Conversation composer without onSend (React) / @send (Vue)>` → Provide onSend / @send to append the message to value
1490
2206
  - ❌ `<Conversation Treating onSend as (text) only when using allowAttachments>` → Handle onSend(text, files) — map files to message attachments and append
2207
+ - ❌ `<Stack <div style={{ display: 'flex', gap: 12 }}>>` → Use <Stack gap="md"> — gap is a token
2208
+ - ❌ `<Stack gap={12} or gap="12px">` → Use gap="none|xs|sm|md|lg|xl|2xl"
2209
+ - ❌ `<Stack direction="vertical" / "horizontal">` → Use direction="row" or "column" (also row-reverse / column-reverse)
2210
+ - ❌ `<Stack style={{ width: "100%" }} / style={{ height: 320 }}>` → Use the width / height prop: width="full", width="md", height="screen", etc.
2211
+ - ❌ `<Grid <div style={{ display:'grid', gridTemplateColumns:'1fr 1fr 1fr' }}>>` → Use <Grid columns={3} gap="md">
2212
+ - ❌ `<Grid columns="3" (string)>` → Use columns={3} or columns="auto-fit"
2213
+ - ❌ `<Grid Nested div with inline grid-column for spanning>` → Wrap the cell in <GridItem colSpan={2}>
2214
+ - ❌ `<Grid style={{ width: "100%" }} / style={{ height: 320 }}>` → Use the width / height prop: width="full", width="md", height="screen", etc.
2215
+ - ❌ `<GridItem GridItem outside a Grid>` → Place <GridItem> directly inside <Grid>
2216
+ - ❌ `<Box <Box style={{ padding: 16 }}>>` → Use <Box padding="md"> (or paddingX/paddingTop/...)
2217
+ - ❌ `<Box Using Box for flex/grid layout>` → Use <Stack> or <Grid>
2218
+ - ❌ `<Box style={{ width: "100%" }} / style={{ height: 320 }}>` → Use the width / height prop: width="full", width="md", height="screen", etc.
2219
+ - ❌ `<Form Manually tracking each field's error state with useState>` → Wrap controls in <FormField name rules> and let Form manage errors
2220
+ - ❌ `<Form Adding a validation library (zod/yup) just for basic rules>` → Use rules={{ required, minLength, pattern, email, validate }}
2221
+ - ❌ `<Form <FormField> with multiple control children>` → Use one control per FormField (Input/Textarea/Select/etc.)
2222
+ - ❌ `<Form <FormField> outside a <Form>>` → Always nest FormField inside <Form>
2223
+ - ❌ `<FormField Putting onChange/value manually on the control inside FormField>` → Let FormField wire the control; only pass static props (type, placeholder)
2224
+ - ❌ `<NumberInput onChange={(e) => set(e.target.value)}>` → onChange={(value) => set(value)} — value is number | null
2225
+ - ❌ `<NumberInput Using <Input type="number"> for numeric fields>` → Use <NumberInput value onChange min max step />
2226
+ - ❌ `<NumberInput Parsing the value with Number() in form state>` → Store the value directly; it is already number | null
2227
+ - ❌ `<ToggleGroup onChange={(e) => set(e.target.value)}>` → onChange={(value) => set(value)} — string|null (single) or string[] (multiple)
2228
+ - ❌ `<ToggleGroup Using ToggleGroup for a single on/off setting>` → Use <Switch> for on/off; ToggleGroup is for choosing among options
2229
+ - ❌ `<ToggleGroup type="multiple" with a string value>` → value={['a','b']} and onChange receives string[]
2230
+ - ❌ `<ToggleGroup <ToggleItem> outside <ToggleGroup>>` → Always nest ToggleItem inside ToggleGroup (or use options)
2231
+ - ❌ `<ToggleItem Tracking selected state on ToggleItem yourself>` → Only set value; the group controls selected state
2232
+ - ❌ `<Stepper Using Tabs for a wizard / checkout flow>` → Use <Stepper> with StepperNav + Step + StepPanel
2233
+ - ❌ `<Stepper onChange={(e) => set(e.target.value)}>` → onChange={(index) => setStep(index)}
2234
+ - ❌ `<Stepper Manually toggling which panel is visible>` → Give each StepPanel an index; Stepper shows the active one
2235
+ - ❌ `<Stepper <Step> or <StepPanel> outside <Stepper>>` → Nest Step inside StepperNav, StepPanel inside Stepper
2236
+ - ❌ `<EmptyState Building an empty placeholder with a bare <div> + centered text>` → Use <EmptyState title description variant>
2237
+ - ❌ `<EmptyState action / cta prop>` → Put the Button as children of EmptyState
2238
+ - ❌ `<EmptyState Using EmptyState for a loading state>` → Use <Skeleton> while loading; EmptyState when the result set is empty
2239
+ - ❌ `<Stat Assuming trend flips the arrow direction>` → delta="-0.4%" always shows a down arrow; trend="up" just colors it green
2240
+ - ❌ `<Stat Building a KPI card with Card + manual layout>` → Use <Stat label value delta trend />
2241
+ - ❌ `<Stat Laying out a KPI row with custom flex + dividers>` → Wrap the Stats in <StatGroup>
2242
+ - ❌ `<StatGroup Putting non-Stat children in StatGroup>` → Only place <Stat> elements inside StatGroup
2243
+ - ❌ `<Timeline Building an activity log with a <ul> + manual dots/lines>` → Use <Timeline items={[...]} /> or TimelineItem children
2244
+ - ❌ `<Timeline Using Stepper for a history/audit feed>` → Use <Timeline> for logs/history; Stepper for wizards
2245
+ - ❌ `<Timeline Expecting Timeline to sort by time>` → Sort the array yourself (newest- or oldest-first)
2246
+ - ❌ `<TimelineItem <TimelineItem> outside <Timeline>>` → Always nest TimelineItem inside Timeline
2247
+ - ❌ `<Tree Rendering a nested <ul> tree by hand with manual expand state>` → Pass a nested `data` array to <Tree> and control expandedIds/selectedId
2248
+ - ❌ `<Tree onSelect={(e) => ...}>` → onSelect={(id) => setSelected(id)}
2249
+ - ❌ `<Tree Mutating the data array to expand/collapse>` → Track expandedIds in state (or use defaultExpandedIds)
2250
+ - ❌ `<Tree Using DropdownMenu submenus for a file tree>` → Use <Tree> for file explorers / nested nav
2251
+ - ❌ `<OTPInput onChange={(e) => set(e.target.value)}>` → onChange={(value) => setCode(value)}
2252
+ - ❌ `<OTPInput Six separate <Input> boxes wired by hand>` → Use <OTPInput length={6} value onChange />
2253
+ - ❌ `<OTPInput Reading completion by comparing length yourself>` → Use onComplete={(code) => verify(code)}
2254
+ - ❌ `<OTPInput type="password" to hide digits>` → Use mask (type stays numeric/alphanumeric)
2255
+ - ❌ `<Carousel onChange={(e) => set(e.target.value)}>` → onChange={(index) => setIndex(index)}
2256
+ - ❌ `<Carousel Putting raw elements directly in Carousel>` → Wrap each slide in <CarouselSlide>
2257
+ - ❌ `<Carousel Building a slider with manual scroll + dot state>` → Use <Carousel> with CarouselSlide children
2258
+ - ❌ `<Carousel autoPlay without considering reduced motion / pausing>` → Carousel already pauses on hover/focus; keep interval reasonable or omit autoPlay
2259
+ - ❌ `<CarouselSlide <CarouselSlide> outside <Carousel>>` → Always nest CarouselSlide inside Carousel
1491
2260
  - ❌ `<DateRangePicker value={[from, to]}>` → Use value={{ from, to }} and read range.from / range.to
1492
2261
  - ❌ `<DateRangePicker DateRangePicker for a single date>` → Use <DatePicker /> for a single date
1493
2262
  - ❌ `<DateRangePicker presets="true" (string)>` → Use the bare prop: presets (or presets={true})