@atelier-ui/react 0.1.9 → 0.1.11

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 (35) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/package.json +1 -1
  3. package/src/lib/accordion/llm-accordion.css +120 -0
  4. package/src/lib/alert/llm-alert.css +80 -0
  5. package/src/lib/avatar/llm-avatar.css +106 -0
  6. package/src/lib/badge/llm-badge.css +60 -0
  7. package/src/lib/breadcrumbs/llm-breadcrumbs.css +62 -0
  8. package/src/lib/button/llm-button.css +139 -0
  9. package/src/lib/card/llm-card.css +70 -0
  10. package/src/lib/chat/llm-chat.css +446 -0
  11. package/src/lib/checkbox/llm-checkbox.css +123 -0
  12. package/src/lib/code-block/llm-code-block.css +112 -0
  13. package/src/lib/combobox/llm-combobox.css +169 -0
  14. package/src/lib/dialog/llm-dialog.css +174 -0
  15. package/src/lib/drawer/llm-drawer.css +228 -0
  16. package/src/lib/icon/llm-icon.css +29 -0
  17. package/src/lib/input/llm-input.css +94 -0
  18. package/src/lib/menu/llm-menu.css +85 -0
  19. package/src/lib/pagination/llm-pagination.css +80 -0
  20. package/src/lib/progress/llm-progress.css +69 -0
  21. package/src/lib/radio/llm-radio.css +78 -0
  22. package/src/lib/radio-group/llm-radio-group.css +31 -0
  23. package/src/lib/select/llm-select.css +83 -0
  24. package/src/lib/skeleton/llm-skeleton.css +51 -0
  25. package/src/lib/spec.d.ts +2 -2
  26. package/src/lib/spec.d.ts.map +1 -1
  27. package/src/lib/spec.js.map +1 -1
  28. package/src/lib/stepper/llm-stepper.css +171 -0
  29. package/src/lib/table/llm-table.css +200 -0
  30. package/src/lib/tabs/llm-tabs.css +120 -0
  31. package/src/lib/textarea/llm-textarea.css +100 -0
  32. package/src/lib/toast/llm-toast.css +137 -0
  33. package/src/lib/toggle/llm-toggle.css +118 -0
  34. package/src/lib/tooltip/llm-tooltip.css +80 -0
  35. package/styles/tokens.css +346 -0
@@ -0,0 +1,171 @@
1
+ .llm-stepper {
2
+ display: block;
3
+ font-family: var(--ui-font-family);
4
+ }
5
+
6
+ /* ─── Header ─── */
7
+ .stepper-header {
8
+ display: flex;
9
+ align-items: center;
10
+ }
11
+
12
+ /* ─── Step item ─── */
13
+ .step-item {
14
+ display: flex;
15
+ flex-direction: column;
16
+ align-items: center;
17
+ min-width: 0;
18
+ }
19
+
20
+ /* ─── Connector ─── */
21
+ .step-connector {
22
+ flex: 1;
23
+ height: 2px;
24
+ background: var(--ui-color-border);
25
+ border-radius: var(--ui-radius-full);
26
+ transition: background var(--ui-transition-normal) var(--ui-ease-out);
27
+ min-width: var(--ui-spacing-4);
28
+ }
29
+
30
+ .step-connector.is-active {
31
+ background: var(--ui-color-primary);
32
+ }
33
+
34
+ /* ─── Step circle button ─── */
35
+ .step-circle {
36
+ all: unset;
37
+ box-sizing: border-box;
38
+ display: inline-flex;
39
+ align-items: center;
40
+ justify-content: center;
41
+ width: 36px;
42
+ height: 36px;
43
+ border-radius: 50%;
44
+ border: 2px solid var(--ui-color-border);
45
+ background: var(--ui-color-surface);
46
+ color: var(--ui-color-text-muted);
47
+ font-size: var(--ui-font-size-sm);
48
+ font-weight: var(--ui-font-weight-semibold);
49
+ cursor: pointer;
50
+ transition: var(--ui-transition-normal) var(--ui-ease-out);
51
+ transition-property: border-color, background-color, color, box-shadow;
52
+ user-select: none;
53
+ flex-shrink: 0;
54
+ }
55
+
56
+ .step-circle:focus-visible {
57
+ outline: none;
58
+ box-shadow: var(--ui-focus-ring);
59
+ }
60
+
61
+ .step-circle:disabled {
62
+ cursor: not-allowed;
63
+ }
64
+
65
+ /* ─── Step text ─── */
66
+ .step-text {
67
+ display: flex;
68
+ flex-direction: column;
69
+ align-items: center;
70
+ margin-top: var(--ui-spacing-2);
71
+ text-align: center;
72
+ }
73
+
74
+ .step-label {
75
+ font-size: var(--ui-font-size-sm);
76
+ font-weight: var(--ui-font-weight-medium);
77
+ color: var(--ui-color-text-muted);
78
+ white-space: nowrap;
79
+ }
80
+
81
+ .step-description {
82
+ font-size: var(--ui-font-size-xs);
83
+ color: var(--ui-color-text-muted);
84
+ margin-top: 2px;
85
+ }
86
+
87
+ .step-optional {
88
+ font-size: var(--ui-font-size-xs);
89
+ color: var(--ui-color-text-muted);
90
+ font-style: italic;
91
+ margin-top: 2px;
92
+ }
93
+
94
+ /* ─── Content ─── */
95
+ .stepper-content {
96
+ margin-top: var(--ui-spacing-6);
97
+ }
98
+
99
+ .stepper-content [role="tabpanel"][hidden] {
100
+ display: none;
101
+ }
102
+
103
+ /* ─── Active state ─── */
104
+ .step-item.is-active .step-circle {
105
+ border-color: var(--ui-color-primary);
106
+ color: var(--ui-color-primary);
107
+ }
108
+
109
+ .step-item.is-active .step-label {
110
+ color: var(--ui-color-text);
111
+ font-weight: var(--ui-font-weight-semibold);
112
+ }
113
+
114
+ /* ─── Completed state ─── */
115
+ .step-item.is-completed .step-circle {
116
+ border-color: var(--ui-color-primary);
117
+ background: var(--ui-color-primary);
118
+ color: var(--ui-color-text-on-primary);
119
+ }
120
+
121
+ .step-item.is-completed .step-label {
122
+ color: var(--ui-color-text);
123
+ }
124
+
125
+ /* ─── Error state ─── */
126
+ .step-item.is-error .step-circle {
127
+ border-color: var(--ui-color-danger);
128
+ background: var(--ui-color-danger);
129
+ color: var(--ui-color-text-on-danger, #ffffff);
130
+ }
131
+
132
+ .step-item.is-error .step-label {
133
+ color: var(--ui-color-danger);
134
+ }
135
+
136
+ /* ─── Disabled state ─── */
137
+ .step-item.is-disabled .step-circle {
138
+ opacity: var(--ui-opacity-disabled);
139
+ cursor: not-allowed;
140
+ }
141
+
142
+ .step-item.is-disabled .step-label {
143
+ opacity: var(--ui-opacity-disabled);
144
+ }
145
+
146
+ /* ─── Vertical orientation ─── */
147
+ .llm-stepper.orientation-vertical .stepper-header {
148
+ flex-direction: column;
149
+ align-items: stretch;
150
+ }
151
+
152
+ .llm-stepper.orientation-vertical .step-item {
153
+ flex-direction: row;
154
+ align-items: flex-start;
155
+ gap: var(--ui-spacing-3);
156
+ }
157
+
158
+ .llm-stepper.orientation-vertical .step-text {
159
+ align-items: flex-start;
160
+ text-align: left;
161
+ margin-top: 0;
162
+ padding-top: var(--ui-spacing-1);
163
+ }
164
+
165
+ .llm-stepper.orientation-vertical .step-connector {
166
+ flex: none;
167
+ width: 2px;
168
+ height: var(--ui-spacing-6);
169
+ margin-left: 17px;
170
+ min-width: 0;
171
+ }
@@ -0,0 +1,200 @@
1
+ /* ============================================================
2
+ llm-table.css — Styles for the React table component
3
+ ============================================================ */
4
+
5
+ /* ---------------------------------------------------------------------------
6
+ Table host container
7
+ --------------------------------------------------------------------------- */
8
+ .llm-table {
9
+ display: block;
10
+ font-family: var(--ui-font-family);
11
+ color: var(--ui-color-text);
12
+ }
13
+
14
+ .llm-table-wrapper {
15
+ width: 100%;
16
+ overflow-x: auto;
17
+ }
18
+
19
+ .llm-table table {
20
+ width: 100%;
21
+ border-collapse: collapse;
22
+ }
23
+
24
+ /* ---------------------------------------------------------------------------
25
+ Header cells
26
+ --------------------------------------------------------------------------- */
27
+ .llm-table thead th {
28
+ font-size: var(--ui-font-size-xs);
29
+ font-weight: var(--ui-font-weight-semibold);
30
+ color: var(--ui-color-text-muted);
31
+ letter-spacing: var(--ui-letter-spacing-wide);
32
+ text-transform: uppercase;
33
+ border-bottom: 2px solid var(--ui-color-border);
34
+ background-color: var(--ui-color-surface);
35
+ padding: var(--ui-spacing-3) var(--ui-spacing-4);
36
+ text-align: start;
37
+ white-space: nowrap;
38
+ }
39
+
40
+ /* ---------------------------------------------------------------------------
41
+ Body cells
42
+ --------------------------------------------------------------------------- */
43
+ .llm-table tbody td {
44
+ border-bottom: 1px solid var(--ui-color-border);
45
+ padding: var(--ui-spacing-3) var(--ui-spacing-4);
46
+ vertical-align: middle;
47
+ background-color: var(--ui-color-surface);
48
+ transition: background-color var(--ui-transition-fast);
49
+ }
50
+
51
+ /* ---------------------------------------------------------------------------
52
+ Size variants
53
+ --------------------------------------------------------------------------- */
54
+ .llm-table.size-sm thead th,
55
+ .llm-table.size-sm tbody td {
56
+ padding: var(--ui-spacing-2) var(--ui-spacing-3);
57
+ font-size: var(--ui-font-size-xs);
58
+ }
59
+
60
+ .llm-table.size-md thead th,
61
+ .llm-table.size-md tbody td {
62
+ padding: var(--ui-spacing-3) var(--ui-spacing-4);
63
+ font-size: var(--ui-font-size-sm);
64
+ }
65
+
66
+ .llm-table.size-lg thead th,
67
+ .llm-table.size-lg tbody td {
68
+ padding: var(--ui-spacing-4) var(--ui-spacing-6);
69
+ font-size: var(--ui-font-size-md);
70
+ }
71
+
72
+ /* ---------------------------------------------------------------------------
73
+ Table variants
74
+ --------------------------------------------------------------------------- */
75
+
76
+ /* Striped: alternate even row background */
77
+ .llm-table.variant-striped tbody tr:nth-child(even) td {
78
+ background-color: var(--ui-color-surface-sunken);
79
+ }
80
+
81
+ /* Bordered: all cell borders */
82
+ .llm-table.variant-bordered thead th,
83
+ .llm-table.variant-bordered tbody td {
84
+ border: 1px solid var(--ui-color-border);
85
+ }
86
+
87
+ /* ---------------------------------------------------------------------------
88
+ Alignment
89
+ --------------------------------------------------------------------------- */
90
+ th.align-start,
91
+ td.align-start {
92
+ text-align: start;
93
+ }
94
+
95
+ th.align-center,
96
+ td.align-center {
97
+ text-align: center;
98
+ }
99
+
100
+ th.align-end,
101
+ td.align-end {
102
+ text-align: end;
103
+ }
104
+
105
+ /* ---------------------------------------------------------------------------
106
+ Row hover and selection
107
+ --------------------------------------------------------------------------- */
108
+ .llm-table tbody tr:hover td {
109
+ background-color: var(--ui-color-surface-sunken);
110
+ }
111
+
112
+ .llm-table tbody tr.is-selected td {
113
+ background-color: var(--ui-color-primary-light);
114
+ }
115
+
116
+ /* Keep selected color on hover */
117
+ .llm-table tbody tr.is-selected:hover td {
118
+ background-color: var(--ui-color-primary-light);
119
+ }
120
+
121
+ /* Selection checkbox cell — fixed narrow width */
122
+ .llm-tr-select-cell {
123
+ width: 2.75rem;
124
+ text-align: center;
125
+ }
126
+
127
+ /* Strip default checkbox layout to center it in the cell */
128
+ .llm-tr-select-cell .llm-checkbox label {
129
+ justify-content: center;
130
+ }
131
+
132
+ /* ---------------------------------------------------------------------------
133
+ Sticky header
134
+ z-index:1 is intentional — above sibling rows but below dropdowns (z-index:100)
135
+ --------------------------------------------------------------------------- */
136
+ .llm-table.is-sticky-header thead th {
137
+ position: sticky;
138
+ top: 0;
139
+ z-index: 1;
140
+ box-shadow: 0 1px 0 0 var(--ui-color-border);
141
+ }
142
+
143
+ /* ---------------------------------------------------------------------------
144
+ Sort button
145
+ --------------------------------------------------------------------------- */
146
+ .llm-th-sort-btn {
147
+ all: unset;
148
+ box-sizing: border-box;
149
+ display: inline-flex;
150
+ align-items: center;
151
+ gap: var(--ui-spacing-2);
152
+ cursor: pointer;
153
+ font: inherit;
154
+ color: inherit;
155
+ font-weight: inherit;
156
+ width: 100%;
157
+ }
158
+
159
+ .llm-th-sort-btn:focus-visible {
160
+ outline: none;
161
+ box-shadow: var(--ui-focus-ring);
162
+ border-radius: var(--ui-radius-sm);
163
+ }
164
+
165
+ .llm-th-sort-icon {
166
+ flex-shrink: 0;
167
+ }
168
+
169
+ .llm-th-sort-asc-arrow,
170
+ .llm-th-sort-desc-arrow {
171
+ opacity: 0.25;
172
+ transition: opacity var(--ui-transition-fast);
173
+ }
174
+
175
+ th.is-sorted .llm-th-sort-icon {
176
+ color: var(--ui-color-primary);
177
+ }
178
+
179
+ th.sort-asc .llm-th-sort-asc-arrow {
180
+ opacity: 1;
181
+ }
182
+
183
+ th.sort-desc .llm-th-sort-desc-arrow {
184
+ opacity: 1;
185
+ }
186
+
187
+ /* ---------------------------------------------------------------------------
188
+ Empty state
189
+ --------------------------------------------------------------------------- */
190
+ .llm-tbody-empty-cell {
191
+ text-align: center;
192
+ padding: var(--ui-spacing-12) var(--ui-spacing-4) !important;
193
+ color: var(--ui-color-text-muted);
194
+ font-size: var(--ui-font-size-md);
195
+ background-color: var(--ui-color-surface) !important;
196
+ }
197
+
198
+ /* ---------------------------------------------------------------------------
199
+ Dark mode — inherited via --ui-* token overrides in tokens.css
200
+ --------------------------------------------------------------------------- */
@@ -0,0 +1,120 @@
1
+ .llm-tab-group {
2
+ display: block;
3
+ font-family: var(--ui-font-family);
4
+ color: var(--ui-color-text);
5
+ }
6
+
7
+ /* ─── Tab list ─── */
8
+ .llm-tab-group .tablist {
9
+ display: flex;
10
+ gap: var(--ui-spacing-2);
11
+ border-bottom: 1px solid var(--ui-color-border);
12
+ overflow-x: auto;
13
+ scrollbar-width: none;
14
+ }
15
+
16
+ .llm-tab-group .tablist::-webkit-scrollbar {
17
+ display: none;
18
+ }
19
+
20
+ /* ─── Tab button ─── */
21
+ .llm-tab-group .tablist button {
22
+ all: unset;
23
+ box-sizing: border-box;
24
+ position: relative;
25
+ display: inline-flex;
26
+ align-items: center;
27
+ min-height: 2.5rem;
28
+ padding: var(--ui-spacing-3) var(--ui-spacing-4);
29
+ font-size: var(--ui-font-size-sm);
30
+ font-weight: var(--ui-font-weight-medium);
31
+ color: var(--ui-color-text-muted);
32
+ cursor: pointer;
33
+ transition: var(--ui-transition-fast);
34
+ transition-property: color, background-color;
35
+ border-radius: var(--ui-radius-md) var(--ui-radius-md) 0 0;
36
+ white-space: nowrap;
37
+ user-select: none;
38
+ }
39
+
40
+ /* Active indicator (underline) — 3px for modern weight */
41
+ .llm-tab-group .tablist button::after {
42
+ content: '';
43
+ position: absolute;
44
+ bottom: -1px;
45
+ left: var(--ui-spacing-2);
46
+ right: var(--ui-spacing-2);
47
+ height: 3px;
48
+ background: transparent;
49
+ border-radius: var(--ui-radius-full) var(--ui-radius-full) 0 0;
50
+ transition: background var(--ui-transition-fast);
51
+ }
52
+
53
+ .llm-tab-group .tablist button.is-active {
54
+ color: var(--ui-color-primary);
55
+ }
56
+
57
+ .llm-tab-group .tablist button.is-active::after {
58
+ background: var(--ui-color-primary);
59
+ }
60
+
61
+ /* Hover */
62
+ .llm-tab-group .tablist button:hover:not(.is-disabled):not(.is-active) {
63
+ color: var(--ui-color-text);
64
+ background: var(--ui-color-surface-sunken);
65
+ }
66
+
67
+ /* Focus */
68
+ .llm-tab-group .tablist button:focus-visible {
69
+ outline: none;
70
+ box-shadow: var(--ui-focus-ring);
71
+ border-radius: var(--ui-radius-md);
72
+ }
73
+
74
+ /* Disabled */
75
+ .llm-tab-group .tablist button.is-disabled {
76
+ opacity: var(--ui-opacity-disabled);
77
+ cursor: not-allowed;
78
+ }
79
+
80
+ /* ─── Tab panel ─── */
81
+ .llm-tab-group [role="tabpanel"] {
82
+ padding: var(--ui-spacing-5) 0;
83
+ }
84
+
85
+ .llm-tab-group [role="tabpanel"]:focus-visible {
86
+ outline: none;
87
+ box-shadow: var(--ui-focus-ring);
88
+ border-radius: var(--ui-radius-md);
89
+ }
90
+
91
+ /* ─── Pills variant ─── */
92
+ .llm-tab-group.variant-pills .tablist {
93
+ border-bottom: none;
94
+ gap: var(--ui-spacing-2);
95
+ padding: var(--ui-spacing-1);
96
+ background: var(--ui-color-surface-sunken);
97
+ border-radius: var(--ui-radius-lg);
98
+ }
99
+
100
+ .llm-tab-group.variant-pills .tablist button {
101
+ border-radius: var(--ui-radius-md);
102
+ min-height: 2rem;
103
+ padding: var(--ui-spacing-2) var(--ui-spacing-4);
104
+ font-size: var(--ui-font-size-sm);
105
+ }
106
+
107
+ .llm-tab-group.variant-pills .tablist button::after {
108
+ display: none;
109
+ }
110
+
111
+ .llm-tab-group.variant-pills .tablist button.is-active {
112
+ background: var(--ui-color-surface);
113
+ color: var(--ui-color-text);
114
+ box-shadow: var(--ui-shadow-sm);
115
+ }
116
+
117
+ .llm-tab-group.variant-pills .tablist button:hover:not(.is-disabled):not(.is-active) {
118
+ background: transparent;
119
+ color: var(--ui-color-text);
120
+ }
@@ -0,0 +1,100 @@
1
+ .llm-textarea {
2
+ display: block;
3
+ font-family: var(--ui-font-family);
4
+ font-size: var(--ui-font-size-md);
5
+ }
6
+
7
+ .llm-textarea textarea {
8
+ display: block;
9
+ width: 100%;
10
+ padding: 0.625rem var(--ui-spacing-4);
11
+ font-size: inherit;
12
+ font-family: inherit;
13
+ line-height: var(--ui-line-height-normal);
14
+ color: var(--ui-color-text);
15
+ background-color: var(--ui-color-input-bg);
16
+ border: 1px solid var(--ui-color-input-border);
17
+ border-radius: var(--ui-radius-md);
18
+ transition: border-color var(--ui-transition-fast),
19
+ box-shadow var(--ui-transition-fast),
20
+ background-color var(--ui-transition-fast);
21
+ outline: none;
22
+ box-sizing: border-box;
23
+ resize: vertical;
24
+ min-height: 5rem;
25
+ }
26
+
27
+ .llm-textarea textarea::placeholder {
28
+ color: var(--ui-color-placeholder);
29
+ }
30
+
31
+ .llm-textarea textarea:hover:not(:disabled):not(:read-only) {
32
+ border-color: var(--ui-color-input-border-hover);
33
+ }
34
+
35
+ .llm-textarea textarea:focus {
36
+ border-color: var(--ui-color-input-border-focus);
37
+ background-color: var(--ui-color-input-bg-focus);
38
+ box-shadow: var(--ui-focus-ring);
39
+ }
40
+
41
+ .llm-textarea .textarea-field {
42
+ position: relative;
43
+ }
44
+
45
+ /* Invalid state */
46
+ .llm-textarea.is-invalid textarea {
47
+ border-color: var(--ui-color-input-border-invalid);
48
+ padding-right: 2.25rem;
49
+ }
50
+
51
+ .llm-textarea.is-invalid textarea:focus {
52
+ border-color: var(--ui-color-input-border-invalid);
53
+ box-shadow: 0 0 0 2px var(--ui-color-surface), 0 0 0 4px var(--ui-color-danger);
54
+ }
55
+
56
+ /* Non-color invalid indicator (WCAG 1.4.1) */
57
+ .llm-textarea.is-invalid .textarea-field::before {
58
+ content: '✕';
59
+ position: absolute;
60
+ top: 0.75rem;
61
+ right: 0.875rem;
62
+ color: var(--ui-color-danger);
63
+ font-weight: 700;
64
+ line-height: 1;
65
+ pointer-events: none;
66
+ }
67
+
68
+ /* Disabled state */
69
+ .llm-textarea.is-disabled {
70
+ opacity: var(--ui-opacity-disabled);
71
+ cursor: not-allowed;
72
+ }
73
+
74
+ .llm-textarea.is-disabled textarea {
75
+ cursor: not-allowed;
76
+ }
77
+
78
+ /* Readonly state */
79
+ .llm-textarea.is-readonly textarea {
80
+ background-color: var(--ui-color-surface-sunken);
81
+ cursor: default;
82
+ }
83
+
84
+ /* Auto-resize: hide manual resize handle when autoResize is active */
85
+ .llm-textarea.is-auto-resize textarea {
86
+ resize: none;
87
+ overflow: hidden;
88
+ }
89
+
90
+ /* Error messages */
91
+ .llm-textarea .errors {
92
+ margin-top: var(--ui-spacing-2);
93
+ }
94
+
95
+ .llm-textarea .error-message {
96
+ margin: 0;
97
+ font-size: var(--ui-font-size-sm);
98
+ color: var(--ui-color-error-text);
99
+ line-height: var(--ui-line-height-normal);
100
+ }