@noemaru1011/ui 1.0.2 → 1.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/llms-full.txt CHANGED
@@ -1,507 +1,509 @@
1
- # my-ui-catalog — Full AI Context
2
-
3
- ## 1. Overview
4
-
5
- `@noemaru1011/ui` is a reusable UI component library built with React and TypeScript.
6
-
7
- It provides components for application interfaces, layout composition, common interactions, and low-level UI primitives.
8
-
9
- Repository:
10
-
11
- - https://github.com/noemaru1011/my-ui-catalog
12
-
13
- Storybook:
14
-
15
- - https://noemaru1011.github.io/my-ui-catalog/
16
-
17
- npm package:
18
-
19
- - `@noemaru1011/ui`
20
-
21
- ## 2. Technology Stack
22
-
23
- The project uses the following technologies:
24
-
25
- - React 19
26
- - TypeScript
27
- - Vite
28
- - Tailwind CSS 4
29
- - Base UI
30
- - class-variance-authority
31
- - i18next
32
- - react-i18next
33
- - Storybook
34
-
35
- Use the package's published peer dependency requirements as the source of truth for compatibility.
36
-
37
- ## 3. Installation
38
-
39
- ```bash
40
- npm install @noemaru1011/ui
41
- ```
42
-
43
- Import the stylesheet in the application entry point:
44
-
45
- ```tsx
46
- import '@noemaru1011/ui/style.css';
47
- ```
48
-
49
- The stylesheet provides the library's Tailwind CSS output, theme variables, and component styles.
50
-
51
- ## 4. Public API
52
-
53
- The package entry point is `src/index.ts`.
54
-
55
- ### 4.1 Elements
56
-
57
- The Elements collection provides higher-level, reusable interface components.
58
-
59
- ```tsx
60
- import {
61
- Accordion,
62
- Blockquote,
63
- Checkbox,
64
- Combobox,
65
- ComboboxMultiple,
66
- DatePicker,
67
- DateRange,
68
- DescriptionList,
69
- Disclosure,
70
- FileUpload,
71
- FileUploadButton,
72
- HamburgerMenu,
73
- Heading,
74
- Image,
75
- Input,
76
- PasswordInput,
77
- Link,
78
- List,
79
- Loading,
80
- Radio,
81
- LanguageSelect,
82
- Select,
83
- Switch,
84
- ThemeSwitch,
85
- Text,
86
- Textarea,
87
- } from '@noemaru1011/ui';
88
- ```
89
-
90
- Available components:
91
-
92
- - Accordion
93
- - Blockquote
94
- - Checkbox
95
- - Combobox
96
- - ComboboxMultiple
97
- - DatePicker
98
- - DateRange
99
- - DescriptionList
100
- - Disclosure
101
- - FileUpload
102
- - FileUploadButton
103
- - HamburgerMenu
104
- - Heading
105
- - Image
106
- - Input
107
- - PasswordInput
108
- - Link
109
- - List
110
- - Loading
111
- - Radio
112
- - LanguageSelect
113
- - Select
114
- - Switch
115
- - ThemeSwitch
116
- - Text
117
- - Textarea
118
-
119
- ### 4.2 Layouts
120
-
121
- The Layouts collection provides components for composing page and application structures.
122
-
123
- ```tsx
124
- import {
125
- AppLayout,
126
- Center,
127
- Cluster,
128
- Container,
129
- Forbidden,
130
- InternalServerError,
131
- NotFound,
132
- Grid,
133
- Stack,
134
- } from '@noemaru1011/ui';
135
- ```
136
-
137
- Available components:
138
-
139
- - AppLayout
140
- - Center
141
- - Cluster
142
- - Container
143
- - Forbidden
144
- - InternalServerError
145
- - NotFound
146
- - Grid
147
- - Stack
148
-
149
- ### 4.3 UI Components
150
-
151
- The package also exports commonly used UI components directly.
152
-
153
- ```tsx
154
- import {
155
- Alert,
156
- AlertDialog,
157
- Badge,
158
- Breadcrumb,
159
- Button,
160
- Card,
161
- Carousel,
162
- Dialog,
163
- Drawer,
164
- Field,
165
- InputGroup,
166
- Label,
167
- Pagination,
168
- Popover,
169
- RadioGroup,
170
- Separator,
171
- Spinner,
172
- Table,
173
- Tabs,
174
- Toast,
175
- Tooltip,
176
- } from '@noemaru1011/ui';
177
- ```
178
-
179
- Available components:
180
-
181
- - Alert
182
- - AlertDialog
183
- - Badge
184
- - Breadcrumb
185
- - Button
186
- - Card
187
- - Carousel
188
- - Dialog
189
- - Drawer
190
- - Field
191
- - InputGroup
192
- - Label
193
- - Pagination
194
- - Popover
195
- - RadioGroup
196
- - Separator
197
- - Spinner
198
- - Table
199
- - Tabs
200
- - Toast
201
- - Tooltip
202
-
203
- ### 4.4 Primitive Components
204
-
205
- Low-level UI primitives are available through the `primitives` namespace.
206
-
207
- ```tsx
208
- import { primitives } from '@noemaru1011/ui';
209
- ```
210
-
211
- The namespace exposes the components exported from `src/components/ui`.
212
-
213
- These include:
214
-
215
- - accordion
216
- - alert
217
- - alert-dialog
218
- - badge
219
- - breadcrumb
220
- - button
221
- - calendar
222
- - card
223
- - carousel
224
- - checkbox
225
- - combobox
226
- - dialog
227
- - drawer
228
- - field
229
- - input-group
230
- - input
231
- - label
232
- - pagination
233
- - popover
234
- - radio-group
235
- - select
236
- - separator
237
- - spinner
238
- - switch
239
- - table
240
- - tabs
241
- - textarea
242
- - toast
243
- - tooltip
244
-
245
- Use the higher-level Elements and Layouts exports when they satisfy the use case. Use primitives when lower-level control is needed.
246
-
247
- ### 4.5 Other Exports
248
-
249
- The package entry point also exports:
250
-
251
- - Theme Provider
252
- - i18n configuration
253
- - data-table-features
254
- - utility functions
255
-
256
- Refer to `src/index.ts` and the corresponding source files for exact export names and signatures.
257
-
258
- ## 5. Button
259
-
260
- The Button component is based on Base UI and uses class-variance-authority for variant and size styling.
261
-
262
- ### Variants
263
-
264
- - `default`
265
- - `outline`
266
- - `secondary`
267
- - `ghost`
268
- - `destructive`
269
- - `link`
270
-
271
- ### Sizes
272
-
273
- - `default`
274
- - `xs`
275
- - `sm`
276
- - `lg`
277
- - `icon`
278
- - `icon-xs`
279
- - `icon-sm`
280
- - `icon-lg`
281
-
282
- ### Loading State
283
-
284
- The Button supports a `loading` property.
285
-
286
- When loading is enabled:
287
-
288
- - The button is disabled.
289
- - `aria-busy` is set.
290
- - A Spinner is displayed.
291
-
292
- Example:
293
-
294
- ```tsx
295
- import { Button } from '@noemaru1011/ui';
296
-
297
- export function SaveButton() {
298
- return (
299
- <Button loading>
300
- Saving...
301
- </Button>
302
- );
303
- }
304
- ```
305
-
306
- The exact TypeScript interface should be checked in the published type definitions.
307
-
308
- ## 6. Styling and Theme
309
-
310
- The library stylesheet is defined in:
311
-
312
- - `src/index.css`
313
-
314
- The project uses Tailwind CSS 4 and semantic CSS variables.
315
-
316
- ### Theme
317
-
318
- The stylesheet defines:
319
-
320
- - Light theme variables on `:root`
321
- - Dark theme variables on `.dark`
322
-
323
- The library supports semantic design tokens for colors and UI styling.
324
-
325
- Use the provided theme variables rather than hardcoding colors when extending the design system.
326
-
327
- ### Typography
328
-
329
- The stylesheet includes Noto Sans JP Variable as a Japanese font resource.
330
-
331
- ### Border Radius
332
-
333
- The base radius is:
334
-
335
- ```css
336
- --radius: 0.625rem;
337
- ```
338
-
339
- This corresponds to 10px when the root font size is 16px.
340
-
341
- The design system generally uses the standard radius scale. Documented exceptions include:
342
-
343
- - `rounded-full`
344
- - `rounded-none`
345
- - `rounded-[inherit]`
346
- - `rounded-[2px]`
347
-
348
- ### Z-index
349
-
350
- The stylesheet defines semantic z-index utility classes:
351
-
352
- - `z-base`
353
- - `z-local`
354
- - `z-sticky`
355
- - `z-popover`
356
- - `z-overlay`
357
- - `z-modal`
358
- - `z-toast`
359
- - `z-tooltip`
360
-
361
- Prefer these semantic layers when implementing overlays, dialogs, popovers, notifications, and tooltips.
362
-
363
- ## 7. Internationalization (i18n)
364
-
365
- The i18n configuration is defined in:
366
-
367
- - `src/i18n/index.ts`
368
-
369
- The library uses:
370
-
371
- - i18next
372
- - i18next-browser-languagedetector
373
- - react-i18next
374
-
375
- Configuration:
376
-
377
- - Default language: Japanese (`ja`)
378
- - Fallback language: Japanese (`ja`)
379
- - Default namespace: `common`
380
- - Namespaces:
381
- - `common`
382
- - `error`
383
- - `example`
384
-
385
- Language detection:
386
-
387
- - localStorage
388
- - Browser navigator
389
-
390
- Detected language settings are cached in localStorage.
391
-
392
- Refer to the i18n source and exported API for the exact initialization and integration procedure.
393
-
394
- ## 8. Basic Usage
395
-
396
- ```tsx
397
- import '@noemaru1011/ui/style.css';
398
-
399
- import {
400
- Button,
401
- Card,
402
- Heading,
403
- Stack,
404
- Text,
405
- } from '@noemaru1011/ui';
406
-
407
- export function SamplePage() {
408
- return (
409
- <Stack>
410
- <Card>
411
- <Heading>Welcome</Heading>
412
- <Text>This is a sample page.</Text>
413
- <Button>Continue</Button>
414
- </Card>
415
- </Stack>
416
- );
417
- }
418
- ```
419
-
420
- This example illustrates the import pattern. Check the published type definitions for the exact props supported by each component.
421
-
422
- ## 9. Build and Source Structure
423
-
424
- The library build configuration is:
425
-
426
- - `vite.lib.config.ts`
427
-
428
- The build entry point is:
429
-
430
- - `src/index.ts`
431
-
432
- The build output directory is:
433
-
434
- - `dist`
435
-
436
- The library build also generates TypeScript declaration files.
437
-
438
- Important source locations:
439
-
440
- | Path | Purpose |
441
- |---|---|
442
- | `src/index.ts` | Public package entry point |
443
- | `src/components/elements/` | Higher-level reusable components |
444
- | `src/components/layouts/` | Layout components |
445
- | `src/components/ui/` | Low-level UI primitives |
446
- | `src/components/providers/theme-provider/` | Theme provider |
447
- | `src/i18n/` | Internationalization |
448
- | `src/index.css` | Global styles and design tokens |
449
- | `src/stories/` | Storybook documentation and examples |
450
- | `.storybook/` | Storybook configuration |
451
-
452
- ## 10. Storybook
453
-
454
- Storybook is used to document and demonstrate components.
455
-
456
- Public Storybook:
457
-
458
- https://noemaru1011.github.io/my-ui-catalog/
459
-
460
- The project configures Storybook to load MDX and component stories from `src`.
461
-
462
- Use Storybook to inspect component appearance and examples. For exact TypeScript APIs, use the source code or published declaration files.
463
-
464
- ## 11. Guidelines for AI Agents
465
-
466
- When generating code using this library, follow these rules:
467
-
468
- 1. Import components from `@noemaru1011/ui` unless there is a clear reason to use another entry point.
469
- 2. Import `@noemaru1011/ui/style.css` in the application.
470
- 3. Prefer Elements and Layouts for common application UI.
471
- 4. Use `primitives` for low-level UI composition.
472
- 5. Do not invent component names, props, variants, or event handlers.
473
- 6. Verify exact component interfaces against the published TypeScript declaration files.
474
- 7. Do not assume every primitive has the same API as its higher-level counterpart.
475
- 8. Reuse the library's theme tokens and semantic styles.
476
- 9. Prefer the existing i18n configuration for translated text.
477
- 10. Use Storybook as a visual reference, not as a replacement for TypeScript API definitions.
478
-
479
- ## 12. Source of Truth
480
-
481
- When information conflicts, use this priority order:
482
-
483
- 1. Published TypeScript declaration files
484
- 2. Current source code
485
- 3. Package metadata
486
- 4. Storybook examples
487
- 5. README and other documentation
488
- 6. This AI context document
489
-
490
- This document is intended to help AI systems understand the package structure and usage. It is not a replacement for the actual API definitions.
491
-
492
- ## 13. Maintenance
493
-
494
- When the library changes, update this document alongside the relevant source changes.
495
-
496
- In particular, review:
497
-
498
- - Public exports
499
- - Component names
500
- - Component props and types
501
- - Dependencies and peer dependencies
502
- - Styling and theme tokens
503
- - i18n configuration
504
- - Installation instructions
505
- - Storybook examples
506
-
1
+ # my-ui-catalog — Full AI Context
2
+
3
+ ## 1. Overview
4
+
5
+ `@noemaru1011/ui` is a reusable UI component library built with React and TypeScript.
6
+
7
+ It provides components for application interfaces, layout composition, common interactions, and low-level UI primitives.
8
+
9
+ Repository:
10
+
11
+ - https://github.com/noemaru1011/my-ui-catalog
12
+
13
+ Storybook:
14
+
15
+ - https://noemaru1011.github.io/my-ui-catalog/
16
+
17
+ npm package:
18
+
19
+ - `@noemaru1011/ui`
20
+
21
+ ## 2. Technology Stack
22
+
23
+ The project uses the following technologies:
24
+
25
+ - React 19
26
+ - TypeScript
27
+ - Vite
28
+ - Tailwind CSS 4
29
+ - Base UI
30
+ - class-variance-authority
31
+ - i18next
32
+ - react-i18next
33
+ - Storybook
34
+
35
+ Use the package's published peer dependency requirements as the source of truth for compatibility.
36
+
37
+ ## 3. Installation
38
+
39
+ ```bash
40
+ npm install @noemaru1011/ui
41
+ ```
42
+
43
+ Import the stylesheet in the application entry point:
44
+
45
+ ```tsx
46
+ import '@noemaru1011/ui/style.css';
47
+ ```
48
+
49
+ The stylesheet provides the library's Tailwind CSS output, theme variables, and component styles.
50
+
51
+ ## 4. Public API
52
+
53
+ The package entry point is `src/index.ts`.
54
+
55
+ ### 4.1 Elements
56
+
57
+ The Elements collection provides higher-level, reusable interface components.
58
+
59
+ ```tsx
60
+ import {
61
+ Accordion,
62
+ Blockquote,
63
+ Checkbox,
64
+ Combobox,
65
+ ComboboxMultiple,
66
+ DatePicker,
67
+ DateRange,
68
+ DescriptionList,
69
+ Disclosure,
70
+ FileUpload,
71
+ FileUploadButton,
72
+ HamburgerMenu,
73
+ Heading,
74
+ Image,
75
+ Input,
76
+ PasswordInput,
77
+ Link,
78
+ List,
79
+ Loading,
80
+ Radio,
81
+ LanguageSelect,
82
+ Select,
83
+ Switch,
84
+ ThemeSwitch,
85
+ Text,
86
+ Textarea,
87
+ } from '@noemaru1011/ui';
88
+ ```
89
+
90
+ Available components:
91
+
92
+ - Accordion
93
+ - Blockquote
94
+ - Checkbox
95
+ - Combobox
96
+ - ComboboxMultiple
97
+ - DatePicker
98
+ - DateRange
99
+ - DescriptionList
100
+ - Disclosure
101
+ - FileUpload
102
+ - FileUploadButton
103
+ - HamburgerMenu
104
+ - Heading
105
+ - Image
106
+ - Input
107
+ - PasswordInput
108
+ - Link
109
+ - List
110
+ - Loading
111
+ - Radio
112
+ - LanguageSelect
113
+ - Select
114
+ - Switch
115
+ - ThemeSwitch
116
+ - Text
117
+ - Textarea
118
+
119
+ ### 4.2 Layouts
120
+
121
+ The Layouts collection provides components for composing page and application structures.
122
+
123
+ ```tsx
124
+ import {
125
+ AppLayout,
126
+ Center,
127
+ Cluster,
128
+ Container,
129
+ Forbidden,
130
+ InternalServerError,
131
+ NotFound,
132
+ Grid,
133
+ Reel,
134
+ Stack,
135
+ } from '@noemaru1011/ui';
136
+ ```
137
+
138
+ Available components:
139
+
140
+ - AppLayout
141
+ - Center
142
+ - Cluster
143
+ - Container
144
+ - Forbidden
145
+ - InternalServerError
146
+ - NotFound
147
+ - Grid
148
+ - Reel
149
+ - Stack
150
+
151
+ ### 4.3 UI Components
152
+
153
+ The package also exports commonly used UI components directly.
154
+
155
+ ```tsx
156
+ import {
157
+ Alert,
158
+ AlertDialog,
159
+ Badge,
160
+ Breadcrumb,
161
+ Button,
162
+ Card,
163
+ Carousel,
164
+ Dialog,
165
+ Drawer,
166
+ Field,
167
+ InputGroup,
168
+ Label,
169
+ Pagination,
170
+ Popover,
171
+ RadioGroup,
172
+ Separator,
173
+ Spinner,
174
+ Table,
175
+ Tabs,
176
+ Toast,
177
+ Tooltip,
178
+ } from '@noemaru1011/ui';
179
+ ```
180
+
181
+ Available components:
182
+
183
+ - Alert
184
+ - AlertDialog
185
+ - Badge
186
+ - Breadcrumb
187
+ - Button
188
+ - Card
189
+ - Carousel
190
+ - Dialog
191
+ - Drawer
192
+ - Field
193
+ - InputGroup
194
+ - Label
195
+ - Pagination
196
+ - Popover
197
+ - RadioGroup
198
+ - Separator
199
+ - Spinner
200
+ - Table
201
+ - Tabs
202
+ - Toast
203
+ - Tooltip
204
+
205
+ ### 4.4 Primitive Components
206
+
207
+ Low-level UI primitives are available through the `primitives` namespace.
208
+
209
+ ```tsx
210
+ import { primitives } from '@noemaru1011/ui';
211
+ ```
212
+
213
+ The namespace exposes the components exported from `src/components/ui`.
214
+
215
+ These include:
216
+
217
+ - accordion
218
+ - alert
219
+ - alert-dialog
220
+ - badge
221
+ - breadcrumb
222
+ - button
223
+ - calendar
224
+ - card
225
+ - carousel
226
+ - checkbox
227
+ - combobox
228
+ - dialog
229
+ - drawer
230
+ - field
231
+ - input-group
232
+ - input
233
+ - label
234
+ - pagination
235
+ - popover
236
+ - radio-group
237
+ - select
238
+ - separator
239
+ - spinner
240
+ - switch
241
+ - table
242
+ - tabs
243
+ - textarea
244
+ - toast
245
+ - tooltip
246
+
247
+ Use the higher-level Elements and Layouts exports when they satisfy the use case. Use primitives when lower-level control is needed.
248
+
249
+ ### 4.5 Other Exports
250
+
251
+ The package entry point also exports:
252
+
253
+ - Theme Provider
254
+ - i18n configuration
255
+ - data-table-features
256
+ - utility functions
257
+
258
+ Refer to `src/index.ts` and the corresponding source files for exact export names and signatures.
259
+
260
+ ## 5. Button
261
+
262
+ The Button component is based on Base UI and uses class-variance-authority for variant and size styling.
263
+
264
+ ### Variants
265
+
266
+ - `default`
267
+ - `outline`
268
+ - `secondary`
269
+ - `ghost`
270
+ - `destructive`
271
+ - `link`
272
+
273
+ ### Sizes
274
+
275
+ - `default`
276
+ - `xs`
277
+ - `sm`
278
+ - `lg`
279
+ - `icon`
280
+ - `icon-xs`
281
+ - `icon-sm`
282
+ - `icon-lg`
283
+
284
+ ### Loading State
285
+
286
+ The Button supports a `loading` property.
287
+
288
+ When loading is enabled:
289
+
290
+ - The button is disabled.
291
+ - `aria-busy` is set.
292
+ - A Spinner is displayed.
293
+
294
+ Example:
295
+
296
+ ```tsx
297
+ import { Button } from '@noemaru1011/ui';
298
+
299
+ export function SaveButton() {
300
+ return (
301
+ <Button loading>
302
+ Saving...
303
+ </Button>
304
+ );
305
+ }
306
+ ```
307
+
308
+ The exact TypeScript interface should be checked in the published type definitions.
309
+
310
+ ## 6. Styling and Theme
311
+
312
+ The library stylesheet is defined in:
313
+
314
+ - `src/index.css`
315
+
316
+ The project uses Tailwind CSS 4 and semantic CSS variables.
317
+
318
+ ### Theme
319
+
320
+ The stylesheet defines:
321
+
322
+ - Light theme variables on `:root`
323
+ - Dark theme variables on `.dark`
324
+
325
+ The library supports semantic design tokens for colors and UI styling.
326
+
327
+ Use the provided theme variables rather than hardcoding colors when extending the design system.
328
+
329
+ ### Typography
330
+
331
+ The stylesheet includes Noto Sans JP Variable as a Japanese font resource.
332
+
333
+ ### Border Radius
334
+
335
+ The base radius is:
336
+
337
+ ```css
338
+ --radius: 0.625rem;
339
+ ```
340
+
341
+ This corresponds to 10px when the root font size is 16px.
342
+
343
+ The design system generally uses the standard radius scale. Documented exceptions include:
344
+
345
+ - `rounded-full`
346
+ - `rounded-none`
347
+ - `rounded-[inherit]`
348
+ - `rounded-[2px]`
349
+
350
+ ### Z-index
351
+
352
+ The stylesheet defines semantic z-index utility classes:
353
+
354
+ - `z-base`
355
+ - `z-local`
356
+ - `z-sticky`
357
+ - `z-popover`
358
+ - `z-overlay`
359
+ - `z-modal`
360
+ - `z-toast`
361
+ - `z-tooltip`
362
+
363
+ Prefer these semantic layers when implementing overlays, dialogs, popovers, notifications, and tooltips.
364
+
365
+ ## 7. Internationalization (i18n)
366
+
367
+ The i18n configuration is defined in:
368
+
369
+ - `src/i18n/index.ts`
370
+
371
+ The library uses:
372
+
373
+ - i18next
374
+ - i18next-browser-languagedetector
375
+ - react-i18next
376
+
377
+ Configuration:
378
+
379
+ - Default language: Japanese (`ja`)
380
+ - Fallback language: Japanese (`ja`)
381
+ - Default namespace: `common`
382
+ - Namespaces:
383
+ - `common`
384
+ - `error`
385
+ - `example`
386
+
387
+ Language detection:
388
+
389
+ - localStorage
390
+ - Browser navigator
391
+
392
+ Detected language settings are cached in localStorage.
393
+
394
+ Refer to the i18n source and exported API for the exact initialization and integration procedure.
395
+
396
+ ## 8. Basic Usage
397
+
398
+ ```tsx
399
+ import '@noemaru1011/ui/style.css';
400
+
401
+ import {
402
+ Button,
403
+ Card,
404
+ Heading,
405
+ Stack,
406
+ Text,
407
+ } from '@noemaru1011/ui';
408
+
409
+ export function SamplePage() {
410
+ return (
411
+ <Stack>
412
+ <Card>
413
+ <Heading>Welcome</Heading>
414
+ <Text>This is a sample page.</Text>
415
+ <Button>Continue</Button>
416
+ </Card>
417
+ </Stack>
418
+ );
419
+ }
420
+ ```
421
+
422
+ This example illustrates the import pattern. Check the published type definitions for the exact props supported by each component.
423
+
424
+ ## 9. Build and Source Structure
425
+
426
+ The library build configuration is:
427
+
428
+ - `vite.lib.config.ts`
429
+
430
+ The build entry point is:
431
+
432
+ - `src/index.ts`
433
+
434
+ The build output directory is:
435
+
436
+ - `dist`
437
+
438
+ The library build also generates TypeScript declaration files.
439
+
440
+ Important source locations:
441
+
442
+ | Path | Purpose |
443
+ |---|---|
444
+ | `src/index.ts` | Public package entry point |
445
+ | `src/components/elements/` | Higher-level reusable components |
446
+ | `src/components/layouts/` | Layout components |
447
+ | `src/components/ui/` | Low-level UI primitives |
448
+ | `src/components/providers/theme-provider/` | Theme provider |
449
+ | `src/i18n/` | Internationalization |
450
+ | `src/index.css` | Global styles and design tokens |
451
+ | `src/stories/` | Storybook documentation and examples |
452
+ | `.storybook/` | Storybook configuration |
453
+
454
+ ## 10. Storybook
455
+
456
+ Storybook is used to document and demonstrate components.
457
+
458
+ Public Storybook:
459
+
460
+ https://noemaru1011.github.io/my-ui-catalog/
461
+
462
+ The project configures Storybook to load MDX and component stories from `src`.
463
+
464
+ Use Storybook to inspect component appearance and examples. For exact TypeScript APIs, use the source code or published declaration files.
465
+
466
+ ## 11. Guidelines for AI Agents
467
+
468
+ When generating code using this library, follow these rules:
469
+
470
+ 1. Import components from `@noemaru1011/ui` unless there is a clear reason to use another entry point.
471
+ 2. Import `@noemaru1011/ui/style.css` in the application.
472
+ 3. Prefer Elements and Layouts for common application UI.
473
+ 4. Use `primitives` for low-level UI composition.
474
+ 5. Do not invent component names, props, variants, or event handlers.
475
+ 6. Verify exact component interfaces against the published TypeScript declaration files.
476
+ 7. Do not assume every primitive has the same API as its higher-level counterpart.
477
+ 8. Reuse the library's theme tokens and semantic styles.
478
+ 9. Prefer the existing i18n configuration for translated text.
479
+ 10. Use Storybook as a visual reference, not as a replacement for TypeScript API definitions.
480
+
481
+ ## 12. Source of Truth
482
+
483
+ When information conflicts, use this priority order:
484
+
485
+ 1. Published TypeScript declaration files
486
+ 2. Current source code
487
+ 3. Package metadata
488
+ 4. Storybook examples
489
+ 5. README and other documentation
490
+ 6. This AI context document
491
+
492
+ This document is intended to help AI systems understand the package structure and usage. It is not a replacement for the actual API definitions.
493
+
494
+ ## 13. Maintenance
495
+
496
+ When the library changes, update this document alongside the relevant source changes.
497
+
498
+ In particular, review:
499
+
500
+ - Public exports
501
+ - Component names
502
+ - Component props and types
503
+ - Dependencies and peer dependencies
504
+ - Styling and theme tokens
505
+ - i18n configuration
506
+ - Installation instructions
507
+ - Storybook examples
508
+
507
509
  Keep `llms.txt` concise and use `llms-full.txt` for detailed documentation.