@hellboy/ds 0.1.2

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 (137) hide show
  1. package/README.md +111 -0
  2. package/dist/index.css +3699 -0
  3. package/dist/index.css.map +1 -0
  4. package/dist/index.d.mts +1087 -0
  5. package/dist/index.d.ts +1087 -0
  6. package/dist/index.js +3391 -0
  7. package/dist/index.js.map +1 -0
  8. package/dist/index.mjs +3287 -0
  9. package/dist/index.mjs.map +1 -0
  10. package/dist/theme.css +55 -0
  11. package/hellboy-ds-0.1.2.tgz +0 -0
  12. package/package.json +42 -0
  13. package/src/components/badge/Badge.tsx +29 -0
  14. package/src/components/badge/index.ts +1 -0
  15. package/src/components/banner/Banner.tsx +48 -0
  16. package/src/components/banner/banner.css +44 -0
  17. package/src/components/banner/index.ts +1 -0
  18. package/src/components/button/button.tsx +127 -0
  19. package/src/components/button/index.ts +1 -0
  20. package/src/components/card/card.tsx +57 -0
  21. package/src/components/card/index.ts +1 -0
  22. package/src/components/checkbox/Checkbox.tsx +98 -0
  23. package/src/components/checkbox/index.ts +1 -0
  24. package/src/components/code-block/code-block.tsx +44 -0
  25. package/src/components/code-block/index.ts +1 -0
  26. package/src/components/color-control/color-control.tsx +322 -0
  27. package/src/components/color-control/index.ts +1 -0
  28. package/src/components/drag-handle/DragHandle.tsx +78 -0
  29. package/src/components/drag-handle/index.ts +1 -0
  30. package/src/components/drawer/drawer.tsx +82 -0
  31. package/src/components/drawer/index.ts +1 -0
  32. package/src/components/floating-bar/floating-bar.tsx +52 -0
  33. package/src/components/floating-bar/index.ts +2 -0
  34. package/src/components/footer/footer.tsx +28 -0
  35. package/src/components/footer/index.ts +1 -0
  36. package/src/components/grid/Grid.tsx +53 -0
  37. package/src/components/grid/index.ts +1 -0
  38. package/src/components/header/header.tsx +57 -0
  39. package/src/components/header/index.ts +1 -0
  40. package/src/components/icons/icons.tsx +44 -0
  41. package/src/components/icons/index.ts +1 -0
  42. package/src/components/index.ts +29 -0
  43. package/src/components/input/DatePicker.tsx +133 -0
  44. package/src/components/input/Input.tsx +220 -0
  45. package/src/components/input/InputDate.tsx +10 -0
  46. package/src/components/input/InputDateTime.tsx +10 -0
  47. package/src/components/input/InputEmail.tsx +10 -0
  48. package/src/components/input/InputField.tsx +137 -0
  49. package/src/components/input/InputNumber.tsx +10 -0
  50. package/src/components/input/InputPassword.tsx +10 -0
  51. package/src/components/input/InputSearch.tsx +10 -0
  52. package/src/components/input/InputTel.tsx +10 -0
  53. package/src/components/input/InputText.tsx +10 -0
  54. package/src/components/input/InputTime.tsx +10 -0
  55. package/src/components/input/InputUrl.tsx +10 -0
  56. package/src/components/input/TimePicker.tsx +151 -0
  57. package/src/components/input/index.ts +11 -0
  58. package/src/components/layout/Layout.tsx +244 -0
  59. package/src/components/layout/index.ts +1 -0
  60. package/src/components/list/List.tsx +159 -0
  61. package/src/components/list/index.ts +1 -0
  62. package/src/components/navbar/MenuCategory.tsx +20 -0
  63. package/src/components/navbar/MenuGroup.tsx +288 -0
  64. package/src/components/navbar/MenuItem.tsx +65 -0
  65. package/src/components/navbar/Navbar.tsx +23 -0
  66. package/src/components/navbar/index.ts +4 -0
  67. package/src/components/page/index.ts +1 -0
  68. package/src/components/page/page.tsx +46 -0
  69. package/src/components/page-index/PageIndex.tsx +275 -0
  70. package/src/components/page-index/index.ts +1 -0
  71. package/src/components/popover/index.ts +1 -0
  72. package/src/components/popover/popover.tsx +199 -0
  73. package/src/components/radio/Radio.tsx +176 -0
  74. package/src/components/radio/index.ts +1 -0
  75. package/src/components/section/index.ts +1 -0
  76. package/src/components/section/section.tsx +66 -0
  77. package/src/components/select/Select.tsx +212 -0
  78. package/src/components/select/index.ts +1 -0
  79. package/src/components/slider/Slider.tsx +267 -0
  80. package/src/components/slider/index.ts +1 -0
  81. package/src/components/switch/index.ts +1 -0
  82. package/src/components/switch/switch.tsx +99 -0
  83. package/src/components/table/Table.tsx +147 -0
  84. package/src/components/table/index.ts +1 -0
  85. package/src/components/theme-control/index.ts +1 -0
  86. package/src/components/theme-control/theme-control.tsx +78 -0
  87. package/src/components/tooltip/index.ts +1 -0
  88. package/src/components/tooltip/tooltip.tsx +207 -0
  89. package/src/contexts/NavbarTooltipContext.tsx +48 -0
  90. package/src/contexts/index.ts +1 -0
  91. package/src/foundations/motion.md +136 -0
  92. package/src/index.ts +40 -0
  93. package/src/style/_shared/field.css +69 -0
  94. package/src/style/components/badge/badge.css +74 -0
  95. package/src/style/components/button/button.css +244 -0
  96. package/src/style/components/card/card.css +69 -0
  97. package/src/style/components/checkbox.css +142 -0
  98. package/src/style/components/code-block/code-block.css +34 -0
  99. package/src/style/components/color-control/color-control.css +126 -0
  100. package/src/style/components/drag-handle/drag-handle.css +68 -0
  101. package/src/style/components/drawer/drawer.css +210 -0
  102. package/src/style/components/floating-bar/floating-bar.css +39 -0
  103. package/src/style/components/footer/footer.css +108 -0
  104. package/src/style/components/grid/grid.css +33 -0
  105. package/src/style/components/header/header.css +44 -0
  106. package/src/style/components/icons/icons.css +44 -0
  107. package/src/style/components/input/input.css +393 -0
  108. package/src/style/components/layout/layout.css +205 -0
  109. package/src/style/components/list/list.css +140 -0
  110. package/src/style/components/navbar/navbar.css +342 -0
  111. package/src/style/components/page/page.css +46 -0
  112. package/src/style/components/page-index/page-index.css +158 -0
  113. package/src/style/components/popover/popover.css +44 -0
  114. package/src/style/components/radio.css +178 -0
  115. package/src/style/components/section/section.css +67 -0
  116. package/src/style/components/select/select.css +143 -0
  117. package/src/style/components/slider/slider.css +159 -0
  118. package/src/style/components/switch/switch.css +267 -0
  119. package/src/style/components/table/table.css +108 -0
  120. package/src/style/components/theme-control/theme-control.css +35 -0
  121. package/src/style/components/tooltip/tooltip.css +52 -0
  122. package/src/style/foundations/global.css +316 -0
  123. package/src/style/foundations/motion.css +164 -0
  124. package/src/style/foundations/spacing.css +51 -0
  125. package/src/style/foundations/typography.css +39 -0
  126. package/src/style/foundations/z-index.css +81 -0
  127. package/src/style/modes/dark.css +146 -0
  128. package/src/style/modes/light.css +147 -0
  129. package/src/style/semantic.css +52 -0
  130. package/src/style/styles.css +51 -0
  131. package/src/style/themes/theme.json +37 -0
  132. package/src/utils/README.md +305 -0
  133. package/src/utils/USER_PREFERENCES.md +558 -0
  134. package/src/utils/theme.ts +127 -0
  135. package/src/utils/user-preferences.ts +577 -0
  136. package/tsconfig.json +25 -0
  137. package/tsup.config.ts +52 -0
@@ -0,0 +1,69 @@
1
+ /**
2
+ * Field Base Styles
3
+ * Shared styles for form field inputs (Input, Select, etc)
4
+ * Provides consistent styling for outline, focus, hover, error states
5
+ */
6
+
7
+ /* Base field styling */
8
+ .field {
9
+ width: 100%;
10
+ font-family: inherit;
11
+ font-size: var(--font-size-base);
12
+ line-height: 1.5;
13
+ color: var(--color-foreground-1);
14
+ background-color: var(--color-bg-1);
15
+ border: none;
16
+ outline: 2px solid var(--color-bg-3);
17
+ outline-offset: -2px;
18
+ border-radius: var(--radius-base);
19
+ padding: var(--spacing-2) var(--spacing-3);
20
+ transition: outline-color var(--transition-base), box-shadow var(--transition-base);
21
+ cursor: pointer;
22
+ }
23
+
24
+ /* Size variants */
25
+ .field--sm {
26
+ font-size: var(--font-size-sm);
27
+ padding: var(--spacing-1) var(--spacing-2);
28
+ }
29
+
30
+ .field--lg {
31
+ font-size: var(--font-size-lg);
32
+ padding: var(--spacing-3) var(--spacing-4);
33
+ }
34
+
35
+ /* Focus state - uses action colors */
36
+ .field:focus,
37
+ .field:focus-visible {
38
+ outline-color: var(--color-action-primary);
39
+ box-shadow: 0 0 0 3px hsla(var(--accent-hue), var(--accent-saturation), var(--accent-lightness), 0.1);
40
+ }
41
+
42
+ /* Hover state */
43
+ .field:hover:not(:disabled):not(.field--error) {
44
+ outline-color: var(--color-action-primary-hover);
45
+ }
46
+
47
+ /* Error state */
48
+ .field--error {
49
+ outline-color: hsla(var(--error-hue), var(--error-saturation), 50%, 1);
50
+ }
51
+
52
+ .field--error:focus,
53
+ .field--error:focus-visible {
54
+ outline-color: hsla(var(--error-hue), var(--error-saturation), 50%, 1);
55
+ box-shadow: 0 0 0 3px hsla(var(--error-hue), var(--error-saturation), var(--error-lightness), 0.1);
56
+ }
57
+
58
+ /* Disabled state */
59
+ .field:disabled,
60
+ .field--disabled {
61
+ cursor: not-allowed;
62
+ opacity: 0.6;
63
+ background-color: var(--color-bg-2);
64
+ }
65
+
66
+ /* Open state (for selectable fields) */
67
+ .field--open {
68
+ outline-color: var(--color-action-primary);
69
+ }
@@ -0,0 +1,74 @@
1
+ /**
2
+ * Badge Component Styles
3
+ * Small, contextual information display with variants and sizes
4
+ */
5
+
6
+ .badge {
7
+ display: inline-flex;
8
+ align-items: center;
9
+ justify-content: center;
10
+ font-weight: var(--font-weight-semibold);
11
+ border-radius: 999px;
12
+ white-space: nowrap;
13
+ transition: all var(--transition-base, 0.2s ease);
14
+ }
15
+
16
+ /* Size variants */
17
+ .badge--sm {
18
+ padding: var(--spacing-1) var(--spacing-2);
19
+ font-size: var(--font-size-xs);
20
+ min-height: 20px;
21
+ }
22
+
23
+ .badge--md {
24
+ padding: var(--spacing-1) var(--spacing-3);
25
+ font-size: var(--font-size-sm);
26
+ min-height: 24px;
27
+ }
28
+
29
+ .badge--lg {
30
+ padding: var(--spacing-2) var(--spacing-4);
31
+ font-size: var(--font-size-base);
32
+ min-height: 32px;
33
+ }
34
+
35
+ /* Color variants */
36
+ .badge--primary {
37
+ background-color: var(--color-primary);
38
+ color: var(--color-on-primary);
39
+ }
40
+
41
+ .badge--secondary {
42
+ background-color: var(--color-secondary);
43
+ color: var(--color-on-secondary);
44
+ }
45
+
46
+ .badge--tertiary {
47
+ background-color: var(--color-tertiary);
48
+ color: var(--color-on-tertiary);
49
+ }
50
+
51
+ .badge--accent {
52
+ background-color: var(--color-accent);
53
+ color: var(--color-on-accent);
54
+ }
55
+
56
+ .badge--success {
57
+ background-color: hsla(var(--success-hue), var(--success-saturation), var(--success-lightness), 1);
58
+ color: hsla(var(--success-hue), 0%, 100%, 1);
59
+ }
60
+
61
+ .badge--warning {
62
+ background-color: hsla(var(--warning-hue), var(--warning-saturation), var(--warning-lightness), 1);
63
+ color: hsla(var(--warning-hue), 0%, 100%, 1);
64
+ }
65
+
66
+ .badge--error {
67
+ background-color: hsla(var(--error-hue), var(--error-saturation), var(--error-lightness), 1);
68
+ color: hsla(var(--error-hue), 0%, 100%, 1);
69
+ }
70
+
71
+ .badge--info {
72
+ background-color: hsla(var(--info-hue), var(--info-saturation), var(--info-lightness), 1);
73
+ color: hsla(var(--info-hue), 0%, 100%, 1);
74
+ }
@@ -0,0 +1,244 @@
1
+ /**
2
+ * Button Component Styles
3
+ * Classes: btn, btn--{variant}, btn--{size}
4
+ *
5
+ * Uses semantic action color tokens:
6
+ * - var(--color-action-primary): primary CTA button color
7
+ * - var(--color-action-primary-hover): hover state
8
+ * - var(--color-action-primary-active): active/pressed state
9
+ * - var(--color-action-primary-disabled): disabled state
10
+ *
11
+ * Supports both pointer (hover) and touch (:active) interfaces
12
+ */
13
+
14
+ .btn {
15
+ position: relative;
16
+ display: inline-flex;
17
+ align-items: center;
18
+ justify-content: center;
19
+ gap: var(--spacing-2);
20
+ white-space: nowrap;
21
+ text-decoration: none;
22
+ user-select: none;
23
+ border-radius: var(--radius-base);
24
+ border: 1px solid transparent;
25
+ font-weight: var(--font-weight-semibold);
26
+ line-height: var(--line-height-normal);
27
+ letter-spacing: var(--letter-spacing-normal);
28
+ transition: var(--motion-transition-hover-in), transform var(--motion-duration-fast) var(--motion-easing-linear);
29
+ cursor: pointer;
30
+ }
31
+
32
+ .btn:not(:hover):not(:active) {
33
+ transition: var(--motion-transition-hover-out), transform var(--motion-duration-fast) var(--motion-easing-accelerate);
34
+ }
35
+
36
+ /* Sizes */
37
+ .btn--xs {
38
+ padding: var(--spacing-1);
39
+ font-size: var(--font-size-xs);
40
+ }
41
+
42
+ .btn--sm {
43
+ padding: var(--spacing-2) var(--spacing-3);
44
+ font-size: var(--font-size-sm);
45
+ min-height: 32px;
46
+ }
47
+
48
+ .btn--md {
49
+ padding: var(--spacing-2) var(--spacing-4);
50
+ font-size: var(--font-size-base);
51
+ min-height: 40px;
52
+ }
53
+
54
+ .btn--lg {
55
+ padding: var(--spacing-3) var(--spacing-6);
56
+ font-size: var(--font-size-lg);
57
+ min-height: 48px;
58
+ }
59
+
60
+ /* Icon only variant */
61
+ .btn--icon-only {
62
+ padding: var(--spacing-2);
63
+ width: auto;
64
+ aspect-ratio: 1;
65
+ }
66
+
67
+ .btn--icon-only.btn--xs {
68
+ padding: var(--spacing-1);
69
+ min-width: 24px;
70
+ min-height: 24px;
71
+ }
72
+
73
+ .btn--icon-only.btn--sm {
74
+ padding: var(--spacing-1);
75
+ min-width: 32px;
76
+ min-height: 32px;
77
+ }
78
+
79
+ .btn--icon-only.btn--md {
80
+ padding: var(--spacing-2);
81
+ min-width: 40px;
82
+ min-height: 40px;
83
+ }
84
+
85
+ .btn--icon-only.btn--lg {
86
+ padding: var(--spacing-3);
87
+ min-width: 48px;
88
+ min-height: 48px;
89
+ }
90
+
91
+ /* ===== PRIMARY VARIANT ===== */
92
+ .btn--primary {
93
+ background-color: var(--color-action-primary);
94
+ outline: 0px solid var(--color-action-primary);
95
+ box-shadow: 0 0 0 0 var(--color-action-primary);
96
+ color: var(--color-on-action-primary);
97
+ }
98
+
99
+ /* Pointer hover */
100
+ .btn--primary:hover:not(:disabled) {
101
+ background-color: var(--color-action-primary-hover);
102
+ box-shadow: 0 0 0 2px var(--color-action-primary-hover);
103
+ outline: 2px solid var(--color-action-primary-hover);
104
+ }
105
+
106
+ /* Keyboard/Touch active */
107
+ .btn--primary:active:not(:disabled) {
108
+ background-color: var(--color-action-primary-active);
109
+ transform: scale(0.98);
110
+ }
111
+
112
+ /* Focus indicator (keyboard navigation) */
113
+ .btn--primary:focus-visible:not(:disabled) {
114
+ outline: 2px solid var(--color-action-primary);
115
+ outline-offset: 2px;
116
+ }
117
+
118
+ /* ===== SECONDARY VARIANT ===== */
119
+ .btn--secondary {
120
+ background-color: var(--color-action-secondary);
121
+ color: var(--color-on-action-secondary);
122
+ }
123
+
124
+ .btn--secondary:hover:not(:disabled) {
125
+ background-color: var(--color-action-secondary-hover);
126
+ }
127
+
128
+ .btn--secondary:active:not(:disabled) {
129
+ background-color: var(--color-action-secondary-active);
130
+ transform: scale(0.98);
131
+ }
132
+
133
+ .btn--secondary:focus-visible:not(:disabled) {
134
+ outline: 2px solid var(--color-action-secondary);
135
+ outline-offset: 2px;
136
+ }
137
+
138
+ /* ===== TERTIARY VARIANT (Outline) ===== */
139
+ .btn--tertiary {
140
+ background-color: transparent;
141
+ color: var(--color-foreground-2);
142
+ border-color: var(--color-action-tertiary);
143
+ border-width: 2px;
144
+ }
145
+
146
+ .btn--tertiary:hover:not(:disabled) {
147
+ background-color: hsla(var(--accent-hue), var(--accent-saturation), var(--accent-lightness-hover), 0.2);
148
+ border-color: var(--color-action-primary-hover);
149
+ color: var(--color-foreground-2);
150
+ }
151
+
152
+ .btn--tertiary:active:not(:disabled) {
153
+ background-color: hsla(var(--accent-hue), var(--accent-saturation), var(--accent-lightness-active), 0.2);
154
+ border-color: var(--color-action-primary-active);
155
+ color: var(--color-action-primary-active);
156
+ transform: scale(0.98);
157
+ }
158
+
159
+ .btn--tertiary:focus-visible:not(:disabled) {
160
+ outline: 2px solid var(--color-action-primary);
161
+ outline-offset: 2px;
162
+ }
163
+
164
+ /* ===== GHOST VARIANT (Transparent Outline) ===== */
165
+ .btn--ghost {
166
+ background-color: transparent;
167
+ color: var(--color-foreground-2);
168
+ border-color: transparent;
169
+ border-width: 2px;
170
+ }
171
+
172
+ .btn--ghost:hover:not(:disabled) {
173
+ background-color: transparent;
174
+ border-color: var(--color-action-primary-hover);
175
+ color: var(--color-foreground-2);
176
+ }
177
+
178
+ .btn--ghost:active:not(:disabled) {
179
+ background-color: hsla(var(--accent-hue), var(--accent-saturation), var(--accent-lightness-active), 0.2);
180
+ border-color: var(--color-action-primary-active);
181
+ color: var(--color-action-primary-active);
182
+ transform: scale(0.98);
183
+ }
184
+
185
+ .btn--ghost:focus-visible:not(:disabled) {
186
+ outline: 2px solid var(--color-action-primary);
187
+ outline-offset: 2px;
188
+ }
189
+
190
+ /* ===== DISABLED STATE (All Variants) ===== */
191
+ .btn:disabled {
192
+ background-color: var(--color-primary-disabled);
193
+ color: var(--color-foreground-2);
194
+ cursor: not-allowed;
195
+ border-color: var(--color-primary-disabled);
196
+ }
197
+
198
+ /* ===== UTILITY CLASSES ===== */
199
+ .btn--full-width {
200
+ width: 100%;
201
+ }
202
+
203
+ /* Touch device support: no hover on touchscreen */
204
+ @media (hover: none) and (pointer: coarse) {
205
+ .btn--primary:active:not(:disabled) {
206
+ background-color: var(--color-primary-active);
207
+ }
208
+
209
+ .btn--secondary:active:not(:disabled) {
210
+ background-color: var(--color-secondary-active);
211
+ }
212
+
213
+ .btn--tertiary:active:not(:disabled) {
214
+ background-color: hsla(var(--primary-hue), var(--primary-saturation), var(--primary-lightness-active), 0.2);
215
+ }
216
+
217
+ .btn--ghost:active:not(:disabled) {
218
+ background-color: hsla(var(--primary-hue), var(--primary-saturation), var(--primary-lightness-active), 0.2);
219
+ }
220
+ }
221
+
222
+ .btn__spinner {
223
+ display: inline-block;
224
+ width: 16px;
225
+ height: 16px;
226
+ border-radius: 50%;
227
+ border: 2px solid currentColor;
228
+ border-top-color: transparent;
229
+ animation: btn-spin 0.6s linear infinite;
230
+ }
231
+
232
+ .btn__icon {
233
+ flex-shrink: 0;
234
+ }
235
+
236
+ .btn__icon-placeholder {
237
+ flex-shrink: 0;
238
+ }
239
+
240
+ @keyframes btn-spin {
241
+ to {
242
+ transform: rotate(360deg);
243
+ }
244
+ }
@@ -0,0 +1,69 @@
1
+ /**
2
+ * Card Component Styles
3
+ * Flexible card component for content containers
4
+ *
5
+ * Supports light/dark modes via data-theme or prefers-color-scheme fallback
6
+ * Interactive cards have hover and active states with smooth transitions
7
+ */
8
+
9
+ .card {
10
+ /* Base card styles */
11
+ background-color: var(--color-bg-1);
12
+ border-radius: 8px;
13
+ padding: var(--spacing-4);
14
+ border: none;
15
+ transition: box-shadow var(--transition-base), transform var(--transition-base), background-color var(--transition-base);
16
+ overflow: visible;
17
+ }
18
+
19
+ .card--default {
20
+ /* Default variant - subtle border */
21
+ border: 1px solid var(--color-foreground-2);
22
+ border-color: rgba(0, 0, 0, 0.1);
23
+ }
24
+
25
+ .card--elevated {
26
+ /* Elevated variant - shadow */
27
+ box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
28
+ }
29
+
30
+ .card--outlined {
31
+ /* Outlined variant - stronger border */
32
+ border: 2px solid var(--color-foreground-2);
33
+ border-color: rgba(0, 0, 0, 0.15);
34
+ }
35
+
36
+ /* ===== INTERACTIVE CARD STYLES ===== */
37
+ .card--interactive {
38
+ /* Interactive styles */
39
+ cursor: pointer;
40
+ user-select: none;
41
+ background-color: var(--color-bg-2);
42
+ }
43
+
44
+ /* Pointer hover */
45
+ .card--interactive:hover {
46
+ background-color: hsla(0, 0%, var(--lightness-bg-2), 0.8);
47
+ transform: translateY(-2px);
48
+ box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
49
+ }
50
+
51
+ /* Active / Pressed */
52
+ .card--interactive:active {
53
+ background-color: hsla(0, 0%, var(--lightness-bg-2), 0.9);
54
+ transform: translateY(0);
55
+ }
56
+
57
+ /* Focus indicator (keyboard navigation) */
58
+ .card--interactive:focus-visible {
59
+ outline: 2px solid var(--color-action-primary);
60
+ outline-offset: 2px;
61
+ }
62
+
63
+ /* Touch device support: respond to :active without :hover */
64
+ @media (hover: none) and (pointer: coarse) {
65
+ .card--interactive:active {
66
+ background-color: hsla(0, 0%, var(--lightness-bg-2), 0.8);
67
+ transform: translateY(-1px);
68
+ }
69
+ }
@@ -0,0 +1,142 @@
1
+ /* Checkbox Component Styles */
2
+
3
+ .checkbox {
4
+ display: inline-flex;
5
+ flex-direction: column;
6
+ gap: var(--spacing-1);
7
+ }
8
+
9
+ .checkbox__container {
10
+ display: inline-flex;
11
+ align-items: center;
12
+ gap: var(--spacing-2);
13
+ cursor: pointer;
14
+ user-select: none;
15
+ }
16
+
17
+ .checkbox__input {
18
+ position: absolute;
19
+ opacity: 0;
20
+ width: 0;
21
+ height: 0;
22
+ pointer-events: none;
23
+ }
24
+
25
+ .checkbox__box {
26
+ position: relative;
27
+ display: inline-flex;
28
+ align-items: center;
29
+ justify-content: center;
30
+ flex-shrink: 0;
31
+ border: 2px solid var(--color-foreground-2);
32
+ border-radius: 4px;
33
+ background-color: var(--color-bg-1);
34
+ transition: all 0.2s ease;
35
+ }
36
+
37
+ .checkbox__icon {
38
+ color: var(--color-on-primary);
39
+ transition: opacity 0.2s ease;
40
+ }
41
+
42
+ .checkbox__label {
43
+ font-size: var(--font-size-md);
44
+ color: var(--color-foreground-1);
45
+ line-height: 1.5;
46
+ }
47
+
48
+ /* Size variants */
49
+ .checkbox--sm .checkbox__box {
50
+ width: 16px;
51
+ height: 16px;
52
+ }
53
+
54
+ .checkbox--sm .checkbox__label {
55
+ font-size: var(--font-size-sm);
56
+ }
57
+
58
+ .checkbox--md .checkbox__box {
59
+ width: 20px;
60
+ height: 20px;
61
+ }
62
+
63
+ .checkbox--lg .checkbox__box {
64
+ width: 24px;
65
+ height: 24px;
66
+ }
67
+
68
+ .checkbox--lg .checkbox__label {
69
+ font-size: var(--font-size-lg);
70
+ }
71
+
72
+ /* Checked state */
73
+ .checkbox__input[aria-checked="true"] + .checkbox__box,
74
+ .checkbox__input:checked + .checkbox__box {
75
+ background-color: var(--color-primary);
76
+ border-color: var(--color-primary);
77
+ }
78
+
79
+ /* Indeterminate state */
80
+ .checkbox__input[aria-checked="mixed"] + .checkbox__box {
81
+ background-color: var(--color-primary);
82
+ border-color: var(--color-primary);
83
+ }
84
+
85
+ /* Focus state */
86
+ .checkbox__input:focus-visible + .checkbox__box {
87
+ outline: 2px solid var(--color-primary);
88
+ outline-offset: 2px;
89
+ }
90
+
91
+ /* Hover state */
92
+ .checkbox__container:hover .checkbox__box {
93
+ border-color: var(--color-primary);
94
+ }
95
+
96
+ .checkbox__container:hover .checkbox__input[aria-checked="true"] + .checkbox__box,
97
+ .checkbox__container:hover .checkbox__input:checked + .checkbox__box,
98
+ .checkbox__container:hover .checkbox__input[aria-checked="mixed"] + .checkbox__box {
99
+ background-color: HSLA(
100
+ var(--primary-hue),
101
+ var(--primary-saturation),
102
+ calc(var(--primary-lightness) - 5%),
103
+ 1
104
+ );
105
+ }
106
+
107
+ /* Disabled state */
108
+ .checkbox--disabled .checkbox__container {
109
+ cursor: not-allowed;
110
+ opacity: 0.5;
111
+ }
112
+
113
+ .checkbox--disabled .checkbox__box {
114
+ background-color: var(--color-bg-2);
115
+ border-color: var(--color-foreground-3);
116
+ }
117
+
118
+ /* Error state */
119
+ .checkbox--error .checkbox__box {
120
+ border-color: hsla(var(--error-hue), var(--error-saturation), 50%, 1);
121
+ }
122
+
123
+ .checkbox--error .checkbox__input:focus-visible + .checkbox__box {
124
+ outline-color: hsla(var(--error-hue), var(--error-saturation), 50%, 1);
125
+ }
126
+
127
+ /* Feedback text */
128
+ .checkbox__feedback {
129
+ padding-left: calc(var(--spacing-2) + 20px);
130
+ }
131
+
132
+ .checkbox__error-text {
133
+ font-size: var(--font-size-sm);
134
+ color: hsla(var(--error-hue), var(--error-saturation), var(--error-lightness), 1);
135
+ display: block;
136
+ }
137
+
138
+ .checkbox__helper-text {
139
+ font-size: var(--font-size-sm);
140
+ color: var(--color-foreground-2);
141
+ display: block;
142
+ }
@@ -0,0 +1,34 @@
1
+ /* CodeBlock Component Styles */
2
+
3
+ .code-block {
4
+ background-color: var(--color-bg-2);
5
+ border: 1px solid var(--color-foreground-2);
6
+ border-color: rgba(0, 0, 0, 0.1);
7
+ border-radius: var(--radius-base);
8
+ padding: var(--spacing-4);
9
+ margin: var(--spacing-4) 0;
10
+ font-family: var(--font-family-mono);
11
+ font-size: var(--font-size-sm);
12
+ overflow-x: auto;
13
+ transition: background-color var(--transition-base, 0.2s ease);
14
+ }
15
+
16
+ .code-block code {
17
+ background: none;
18
+ padding: 0;
19
+ border-radius: 0;
20
+ color: var(--color-foreground-1);
21
+ }
22
+
23
+ /* Inline variant - just the code text without background or margins */
24
+ .code-block--inline {
25
+ background: none;
26
+ border: none;
27
+ border-radius: 0;
28
+ padding: 0;
29
+ margin: 0;
30
+ font-family: var(--font-family-mono);
31
+ font-size: inherit;
32
+ color: var(--color-primary);
33
+ display: inline;
34
+ }