@sarunyu/system-one 4.9.36 → 4.9.39

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/AGENTS.md CHANGED
@@ -29,6 +29,10 @@ in this package.** This file is the short version: the rules you must follow.
29
29
  - Custom numbered pagination, banner slide dots, or carousel progress bars → use `<Pagination>` / `<PaginationBanner>` / `<PaginationCarousel>`.
30
30
  - Custom tooltips, `title` attributes, or hand-rolled hover popovers → use `<Tooltip>`.
31
31
  - Custom floating panels triggered by click, hand-rolled popovers with `useState` + absolute positioning → use `<Popover>`.
32
+ - Custom range inputs / sliders → use `<Slider>`. Never `<input type="range">` with utility classes.
33
+ - Custom progress bars or circular progress rings → use `<LinearProgress>` / `<CircleProgress>`. Never `<progress>` or hand-rolled SVG rings.
34
+ - Custom file upload dropzones or upload file rows → use `<UploadArea>` / `<UploadItem>`.
35
+ - Custom vertical list rows (settings menus, nav lists, data rows with icons) → use `<List>` + `<ListItem>`. Never hand-roll `<ul>` / `<li>` or `<div>` rows for this pattern.
32
36
 
33
37
  2. **Use token-backed Tailwind classes for color.** Never emit hard-coded colors:
34
38
  - Hex (`#3b82f6`), arbitrary (`bg-[#...]`), and palette utilities
@@ -90,6 +94,24 @@ in this package.** This file is the short version: the rules you must follow.
90
94
  share one `const body = …` between the two branches. See the `LoginSheet`
91
95
  recipe in `llms.txt`.
92
96
 
97
+ 8. **`<BottomSheet>` MUST use the lazy-mount pattern.** Vaul mounts its portal
98
+ immediately when `<BottomSheet>` enters the React tree — even with
99
+ `open={false}`. Always guard with an `everOpened` flag so the component
100
+ never mounts until the user first opens it.
101
+ ```tsx
102
+ // button-triggered
103
+ const [everOpened, setEverOpened] = useState(false);
104
+ const [open, setOpen] = useState(false);
105
+ <Button onClick={() => { setEverOpened(true); setOpen(true); }}>Open</Button>
106
+ {everOpened && <BottomSheet open={open} onOpenChange={setOpen}>…</BottomSheet>}
107
+
108
+ // prop-driven (receiving open from parent)
109
+ const [everOpened, setEverOpened] = useState(false);
110
+ useEffect(() => { if (open) setEverOpened(true); }, [open]);
111
+ if (!everOpened) return null;
112
+ return <BottomSheet open={open} onOpenChange={…}>…</BottomSheet>;
113
+ ```
114
+
93
115
  ## Setup check
94
116
 
95
117
  Required one-liner in the app entry (App Router: `app/layout.tsx`,
package/DESIGN.md CHANGED
@@ -249,9 +249,9 @@ Use sparingly. Corporate UIs prefer border separation over heavy elevation.
249
249
 
250
250
  ## Component library
251
251
 
252
- This design system ships 30 pre-built components. **Always use them — never recreate with raw HTML.**
252
+ This design system ships 35 pre-built components. **Always use them — never recreate with raw HTML.**
253
253
 
254
- Key components: `Button`, `Input`, `TextArea`, `SearchInput`, `Dropdown`, `DropdownMultiple`, `Checkbox`, `Radio`, `Toggle`, `DateInput`, `TimeInput`, `Avatar`, `AvatarStack`, `Breadcrumb`, `Pagination`, `PaginationBanner`, `PaginationCarousel`, `Tag`, `StatusTag`, `Chip`, `TabGroup`, `Card`, `Table` + `TableRow` + `TableHeaderCell` + `TableCell`, `Modal`, `BottomSheet`, `Alert`, `Toast`, `ToastStack`, `Notification`, `Badge`, `Tooltip`, `Popover`.
254
+ Key components: `Button`, `Input`, `TextArea`, `SearchInput`, `Dropdown`, `DropdownMultiple`, `Checkbox`, `Radio`, `Toggle`, `DateInput`, `TimeInput`, `Avatar`, `AvatarStack`, `Breadcrumb`, `Pagination`, `PaginationBanner`, `PaginationCarousel`, `Tag`, `StatusTag`, `Chip`, `TabGroup`, `Card`, `Table` + `TableRow` + `TableHeaderCell` + `TableCell`, `Modal`, `BottomSheet`, `Alert`, `Toast`, `ToastStack`, `Notification`, `Badge`, `Tooltip`, `Popover`, `Slider`, `LinearProgress`, `CircleProgress`, `UploadArea`, `UploadItem`, `List` + `ListItem`.
255
255
 
256
256
  For props, variants, and usage rules → read `AGENTS.md` and `llms.txt` in this package.
257
257