soltana-ui 0.1.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 (104) hide show
  1. package/README.md +158 -0
  2. package/dist/config/index.d.ts +3 -0
  3. package/dist/config/index.js +7 -0
  4. package/dist/config/register.d.ts +27 -0
  5. package/dist/config/stylesheet.d.ts +13 -0
  6. package/dist/config/types.d.ts +177 -0
  7. package/dist/config/types.js +7 -0
  8. package/dist/config/validation.d.ts +29 -0
  9. package/dist/config/validation.js +59 -0
  10. package/dist/enhancers/accordion.d.ts +19 -0
  11. package/dist/enhancers/carousel.d.ts +21 -0
  12. package/dist/enhancers/collapsible.d.ts +14 -0
  13. package/dist/enhancers/color-picker.d.ts +20 -0
  14. package/dist/enhancers/combobox.d.ts +17 -0
  15. package/dist/enhancers/context-menu.d.ts +19 -0
  16. package/dist/enhancers/date-picker.d.ts +8 -0
  17. package/dist/enhancers/drawer.d.ts +11 -0
  18. package/dist/enhancers/dropdown.d.ts +17 -0
  19. package/dist/enhancers/hover-card.d.ts +15 -0
  20. package/dist/enhancers/index.d.ts +42 -0
  21. package/dist/enhancers/modal.d.ts +16 -0
  22. package/dist/enhancers/scroll-area.d.ts +14 -0
  23. package/dist/enhancers/tabs.d.ts +26 -0
  24. package/dist/enhancers/test-helpers.d.ts +20 -0
  25. package/dist/enhancers/test-utils.d.ts +10 -0
  26. package/dist/enhancers/toast.d.ts +24 -0
  27. package/dist/enhancers/tooltip.d.ts +15 -0
  28. package/dist/enhancers/tree.d.ts +24 -0
  29. package/dist/enhancers/utils/click-away.d.ts +7 -0
  30. package/dist/enhancers/utils/create-overlay-enhancer.d.ts +14 -0
  31. package/dist/enhancers/utils/focus-trap.d.ts +9 -0
  32. package/dist/enhancers/utils/generate-id.d.ts +6 -0
  33. package/dist/enhancers/utils/keyboard-nav.d.ts +21 -0
  34. package/dist/enhancers/utils/position.d.ts +30 -0
  35. package/dist/fonts/index.d.ts +20 -0
  36. package/dist/index.d.ts +9 -0
  37. package/dist/init.d.ts +16 -0
  38. package/dist/plugins/index.d.ts +2 -0
  39. package/dist/plugins/index.js +1 -0
  40. package/dist/plugins/postcss-soltana-treeshake.d.ts +10 -0
  41. package/dist/plugins/postcss-soltana-treeshake.js +149 -0
  42. package/dist/plugins/types.d.ts +9 -0
  43. package/dist/plugins/types.js +4 -0
  44. package/dist/soltana-ui.css +1 -0
  45. package/dist/soltana-ui.js +1702 -0
  46. package/dist/soltana-ui.umd.cjs +1 -0
  47. package/package.json +90 -0
  48. package/src/styles/_variables.scss +348 -0
  49. package/src/styles/base/_accessibility.scss +146 -0
  50. package/src/styles/base/_index.scss +12 -0
  51. package/src/styles/base/_register.scss +84 -0
  52. package/src/styles/base/_relief-system.scss +53 -0
  53. package/src/styles/base/_scrollbar.scss +40 -0
  54. package/src/styles/base/_transitions.scss +75 -0
  55. package/src/styles/base/_typography.scss +442 -0
  56. package/src/styles/components/_alert-dialogs.scss +75 -0
  57. package/src/styles/components/_badges.scss +215 -0
  58. package/src/styles/components/_buttons.scss +293 -0
  59. package/src/styles/components/_callouts.scss +99 -0
  60. package/src/styles/components/_cards.scss +97 -0
  61. package/src/styles/components/_carousels.scss +108 -0
  62. package/src/styles/components/_closes.scss +63 -0
  63. package/src/styles/components/_code.scss +75 -0
  64. package/src/styles/components/_collapsibles.scss +61 -0
  65. package/src/styles/components/_color-pickers.scss +211 -0
  66. package/src/styles/components/_comboboxes.scss +88 -0
  67. package/src/styles/components/_context-menus.scss +82 -0
  68. package/src/styles/components/_date-pickers.scss +165 -0
  69. package/src/styles/components/_feedback.scss +354 -0
  70. package/src/styles/components/_figures.scss +52 -0
  71. package/src/styles/components/_heros.scss +83 -0
  72. package/src/styles/components/_hover-cards.scss +55 -0
  73. package/src/styles/components/_images.scss +71 -0
  74. package/src/styles/components/_index.scss +41 -0
  75. package/src/styles/components/_indicators.scss +403 -0
  76. package/src/styles/components/_inputs.scss +409 -0
  77. package/src/styles/components/_layouts.scss +139 -0
  78. package/src/styles/components/_lists.scss +135 -0
  79. package/src/styles/components/_menus.scss +195 -0
  80. package/src/styles/components/_navigation.scss +325 -0
  81. package/src/styles/components/_overlays.scss +233 -0
  82. package/src/styles/components/_scroll-areas.scss +53 -0
  83. package/src/styles/components/_segmented-controls.scss +75 -0
  84. package/src/styles/components/_tables.scss +137 -0
  85. package/src/styles/components/_toasts.scss +111 -0
  86. package/src/styles/components/_toggles.scss +57 -0
  87. package/src/styles/components/_trees.scss +123 -0
  88. package/src/styles/decorative/_classical.scss +196 -0
  89. package/src/styles/decorative/_index.scss +7 -0
  90. package/src/styles/finishes/_index.scss +55 -0
  91. package/src/styles/index.scss +30 -0
  92. package/src/styles/reliefs/_index.scss +66 -0
  93. package/src/styles/reliefs/_neumorphic-tables.scss +92 -0
  94. package/src/styles/themes/_dark.scss +130 -0
  95. package/src/styles/themes/_index.scss +3 -0
  96. package/src/styles/themes/_light.scss +122 -0
  97. package/src/styles/themes/_sepia.scss +121 -0
  98. package/src/styles/utilities/_index.scss +13 -0
  99. package/src/styles/utilities/_layout.scss +100 -0
  100. package/src/styles/utilities/_mixins.scss +410 -0
  101. package/src/styles/utilities/_responsive.scss +46 -0
  102. package/src/styles/utilities/_sizing.scss +62 -0
  103. package/src/styles/utilities/_spacing.scss +12 -0
  104. package/src/styles/utilities/_visual.scss +436 -0
@@ -0,0 +1,410 @@
1
+ // ---------------------------------------------------------------------------
2
+ // Utility Generation Mixins
3
+ // ---------------------------------------------------------------------------
4
+ // Shared loop bodies for spacing, gap, grid, layout, and sizing utilities.
5
+ // Consumed by base partials (non-responsive) and _responsive.scss (prefixed).
6
+ // ---------------------------------------------------------------------------
7
+
8
+ @use '../variables' as *;
9
+
10
+ @mixin generate-gap($prefix: '') {
11
+ @each $step in $gap-steps {
12
+ .#{$prefix}gap-#{$step} {
13
+ gap: calc(#{$step} * 0.25rem);
14
+ }
15
+ .#{$prefix}gap-x-#{$step} {
16
+ column-gap: calc(#{$step} * 0.25rem);
17
+ }
18
+ .#{$prefix}gap-y-#{$step} {
19
+ row-gap: calc(#{$step} * 0.25rem);
20
+ }
21
+ }
22
+ }
23
+
24
+ @mixin generate-padding($prefix: '', $directions: true) {
25
+ @each $step in $space-keys {
26
+ $val: calc(#{$step} * 0.25rem);
27
+
28
+ .#{$prefix}p-#{$step} {
29
+ padding: $val;
30
+ }
31
+ .#{$prefix}px-#{$step} {
32
+ padding-left: $val;
33
+ padding-right: $val;
34
+ }
35
+ .#{$prefix}py-#{$step} {
36
+ padding-top: $val;
37
+ padding-bottom: $val;
38
+ }
39
+ @if $directions {
40
+ .#{$prefix}pt-#{$step} {
41
+ padding-top: $val;
42
+ }
43
+ .#{$prefix}pr-#{$step} {
44
+ padding-right: $val;
45
+ }
46
+ .#{$prefix}pb-#{$step} {
47
+ padding-bottom: $val;
48
+ }
49
+ .#{$prefix}pl-#{$step} {
50
+ padding-left: $val;
51
+ }
52
+ }
53
+ }
54
+ }
55
+
56
+ @mixin generate-margin($prefix: '', $directions: true) {
57
+ @each $step in $space-keys {
58
+ $val: calc(#{$step} * 0.25rem);
59
+
60
+ .#{$prefix}m-#{$step} {
61
+ margin: $val;
62
+ }
63
+ .#{$prefix}mx-#{$step} {
64
+ margin-left: $val;
65
+ margin-right: $val;
66
+ }
67
+ .#{$prefix}my-#{$step} {
68
+ margin-top: $val;
69
+ margin-bottom: $val;
70
+ }
71
+ @if $directions {
72
+ .#{$prefix}mt-#{$step} {
73
+ margin-top: $val;
74
+ }
75
+ .#{$prefix}mr-#{$step} {
76
+ margin-right: $val;
77
+ }
78
+ .#{$prefix}mb-#{$step} {
79
+ margin-bottom: $val;
80
+ }
81
+ .#{$prefix}ml-#{$step} {
82
+ margin-left: $val;
83
+ }
84
+ }
85
+ }
86
+ }
87
+
88
+ @mixin generate-auto-margins($prefix: '') {
89
+ .#{$prefix}mx-auto {
90
+ margin-left: auto;
91
+ margin-right: auto;
92
+ }
93
+
94
+ .#{$prefix}ml-auto {
95
+ margin-left: auto;
96
+ }
97
+
98
+ .#{$prefix}mr-auto {
99
+ margin-right: auto;
100
+ }
101
+ }
102
+
103
+ @mixin generate-grid($prefix: '') {
104
+ @for $i from 1 through 12 {
105
+ .#{$prefix}grid-cols-#{$i} {
106
+ grid-template-columns: repeat(#{$i}, minmax(0, 1fr));
107
+ }
108
+ .#{$prefix}col-span-#{$i} {
109
+ grid-column: span #{$i} / span #{$i};
110
+ }
111
+ }
112
+
113
+ .#{$prefix}col-span-full {
114
+ grid-column: 1 / -1;
115
+ }
116
+
117
+ @for $i from 1 through 6 {
118
+ .#{$prefix}grid-rows-#{$i} {
119
+ grid-template-rows: repeat(#{$i}, minmax(0, 1fr));
120
+ }
121
+ .#{$prefix}row-span-#{$i} {
122
+ grid-row: span #{$i} / span #{$i};
123
+ }
124
+ }
125
+ }
126
+
127
+ // ============================================================================
128
+ // DISPLAY
129
+ // ============================================================================
130
+
131
+ @mixin generate-display($prefix: '') {
132
+ .#{$prefix}block {
133
+ display: block;
134
+ }
135
+ .#{$prefix}inline-block {
136
+ display: inline-block;
137
+ }
138
+ .#{$prefix}inline {
139
+ display: inline;
140
+ }
141
+ .#{$prefix}flex {
142
+ display: flex;
143
+ }
144
+ .#{$prefix}inline-flex {
145
+ display: inline-flex;
146
+ }
147
+ .#{$prefix}grid {
148
+ display: grid;
149
+ }
150
+ .#{$prefix}inline-grid {
151
+ display: inline-grid;
152
+ }
153
+ .#{$prefix}hidden {
154
+ display: none;
155
+ }
156
+ .#{$prefix}contents {
157
+ display: contents;
158
+ }
159
+ }
160
+
161
+ // ============================================================================
162
+ // FLEX DIRECTION
163
+ // ============================================================================
164
+
165
+ @mixin generate-flex-direction($prefix: '') {
166
+ .#{$prefix}flex-row {
167
+ flex-direction: row;
168
+ }
169
+ .#{$prefix}flex-col {
170
+ flex-direction: column;
171
+ }
172
+ .#{$prefix}flex-row-reverse {
173
+ flex-direction: row-reverse;
174
+ }
175
+ .#{$prefix}flex-col-reverse {
176
+ flex-direction: column-reverse;
177
+ }
178
+ }
179
+
180
+ // ============================================================================
181
+ // FLEX WRAP
182
+ // ============================================================================
183
+
184
+ @mixin generate-flex-wrap($prefix: '') {
185
+ .#{$prefix}flex-wrap {
186
+ flex-wrap: wrap;
187
+ }
188
+ .#{$prefix}flex-nowrap {
189
+ flex-wrap: nowrap;
190
+ }
191
+ }
192
+
193
+ // ============================================================================
194
+ // FLEX SIZING
195
+ // ============================================================================
196
+
197
+ @mixin generate-flex-sizing($prefix: '') {
198
+ .#{$prefix}flex-1 {
199
+ flex: 1 1 0%;
200
+ }
201
+ .#{$prefix}flex-auto {
202
+ flex: 1 1 auto;
203
+ }
204
+ .#{$prefix}flex-initial {
205
+ flex: 0 1 auto;
206
+ }
207
+ .#{$prefix}flex-none {
208
+ flex: none;
209
+ }
210
+ .#{$prefix}grow {
211
+ flex-grow: 1;
212
+ }
213
+ .#{$prefix}grow-0 {
214
+ flex-grow: 0;
215
+ }
216
+ .#{$prefix}shrink {
217
+ flex-shrink: 1;
218
+ }
219
+ .#{$prefix}shrink-0 {
220
+ flex-shrink: 0;
221
+ }
222
+ }
223
+
224
+ // ============================================================================
225
+ // ALIGNMENT
226
+ // ============================================================================
227
+
228
+ @mixin generate-alignment($prefix: '') {
229
+ .#{$prefix}items-start {
230
+ align-items: flex-start;
231
+ }
232
+ .#{$prefix}items-center {
233
+ align-items: center;
234
+ }
235
+ .#{$prefix}items-end {
236
+ align-items: flex-end;
237
+ }
238
+ .#{$prefix}items-baseline {
239
+ align-items: baseline;
240
+ }
241
+ .#{$prefix}items-stretch {
242
+ align-items: stretch;
243
+ }
244
+ .#{$prefix}justify-start {
245
+ justify-content: flex-start;
246
+ }
247
+ .#{$prefix}justify-center {
248
+ justify-content: center;
249
+ }
250
+ .#{$prefix}justify-end {
251
+ justify-content: flex-end;
252
+ }
253
+ .#{$prefix}justify-between {
254
+ justify-content: space-between;
255
+ }
256
+ .#{$prefix}justify-around {
257
+ justify-content: space-around;
258
+ }
259
+ .#{$prefix}justify-evenly {
260
+ justify-content: space-evenly;
261
+ }
262
+ .#{$prefix}self-auto {
263
+ align-self: auto;
264
+ }
265
+ .#{$prefix}self-start {
266
+ align-self: flex-start;
267
+ }
268
+ .#{$prefix}self-center {
269
+ align-self: center;
270
+ }
271
+ .#{$prefix}self-end {
272
+ align-self: flex-end;
273
+ }
274
+ .#{$prefix}self-stretch {
275
+ align-self: stretch;
276
+ }
277
+ }
278
+
279
+ // ============================================================================
280
+ // POSITION
281
+ // ============================================================================
282
+
283
+ @mixin generate-position($prefix: '') {
284
+ .#{$prefix}relative {
285
+ position: relative;
286
+ }
287
+ .#{$prefix}absolute {
288
+ position: absolute;
289
+ }
290
+ .#{$prefix}fixed {
291
+ position: fixed;
292
+ }
293
+ .#{$prefix}sticky {
294
+ position: sticky;
295
+ }
296
+ .#{$prefix}static {
297
+ position: static;
298
+ }
299
+ .#{$prefix}inset-0 {
300
+ inset: 0;
301
+ }
302
+ .#{$prefix}top-0 {
303
+ top: 0;
304
+ }
305
+ .#{$prefix}right-0 {
306
+ right: 0;
307
+ }
308
+ .#{$prefix}bottom-0 {
309
+ bottom: 0;
310
+ }
311
+ .#{$prefix}left-0 {
312
+ left: 0;
313
+ }
314
+ }
315
+
316
+ // ============================================================================
317
+ // OVERFLOW
318
+ // ============================================================================
319
+
320
+ @mixin generate-overflow($prefix: '') {
321
+ @each $val in $overflow-values {
322
+ .#{$prefix}overflow-#{$val} {
323
+ overflow: $val;
324
+ }
325
+ .#{$prefix}overflow-x-#{$val} {
326
+ overflow-x: $val;
327
+ }
328
+ .#{$prefix}overflow-y-#{$val} {
329
+ overflow-y: $val;
330
+ }
331
+ }
332
+ }
333
+
334
+ // ============================================================================
335
+ // TEXT ALIGN
336
+ // ============================================================================
337
+
338
+ @mixin generate-text-align($prefix: '') {
339
+ .#{$prefix}text-left {
340
+ text-align: left;
341
+ }
342
+ .#{$prefix}text-center {
343
+ text-align: center;
344
+ }
345
+ .#{$prefix}text-right {
346
+ text-align: right;
347
+ }
348
+ .#{$prefix}text-justify {
349
+ text-align: justify;
350
+ }
351
+ }
352
+
353
+ // ============================================================================
354
+ // VISIBILITY
355
+ // ============================================================================
356
+
357
+ @mixin generate-visibility($prefix: '') {
358
+ .#{$prefix}visible {
359
+ visibility: visible;
360
+ }
361
+ .#{$prefix}invisible {
362
+ visibility: hidden;
363
+ }
364
+ }
365
+
366
+ // ============================================================================
367
+ // ORDER
368
+ // ============================================================================
369
+
370
+ @mixin generate-order($prefix: '') {
371
+ .#{$prefix}order-first {
372
+ order: -9999;
373
+ }
374
+ .#{$prefix}order-last {
375
+ order: 9999;
376
+ }
377
+ .#{$prefix}order-none {
378
+ order: 0;
379
+ }
380
+ }
381
+
382
+ // ============================================================================
383
+ // WIDTH FRACTIONS
384
+ // ============================================================================
385
+
386
+ @mixin generate-width-fractions($prefix: '', $include-auto: false) {
387
+ @if $include-auto {
388
+ .#{$prefix}w-auto {
389
+ width: auto;
390
+ }
391
+ }
392
+
393
+ @each $name, $val in $size-fractions {
394
+ .#{$prefix}w-#{$name} {
395
+ width: $val;
396
+ }
397
+ }
398
+ }
399
+
400
+ // ============================================================================
401
+ // MAX WIDTHS
402
+ // ============================================================================
403
+
404
+ @mixin generate-max-widths($prefix: '') {
405
+ @each $name, $val in $max-widths {
406
+ .#{$prefix}max-w-#{$name} {
407
+ max-width: $val;
408
+ }
409
+ }
410
+ }
@@ -0,0 +1,46 @@
1
+ // ---------------------------------------------------------------------------
2
+ // Responsive Utilities
3
+ // ---------------------------------------------------------------------------
4
+ // Breakpoint-prefixed layout utilities. Visual/tier classes are excluded —
5
+ // responsive concerns are limited to the layout sphere.
6
+ // ---------------------------------------------------------------------------
7
+
8
+ @use 'sass:list';
9
+ @use 'sass:string';
10
+ @use '../variables' as *;
11
+ @use 'mixins' as gen;
12
+
13
+ // Escape leading digits for valid CSS class names (e.g. 2xl → \32 xl)
14
+ @function escape-bp($name) {
15
+ $str: '#{$name}';
16
+ $first: string.slice($str, 1, 1);
17
+ $digits: ('0', '1', '2', '3', '4', '5', '6', '7', '8', '9');
18
+ @if list.index($digits, $first) {
19
+ @return '\\3' + $first + ' ' + string.slice($str, 2);
20
+ }
21
+ @return $str;
22
+ }
23
+
24
+ @each $bp-name, $bp-value in $breakpoints {
25
+ $bp: escape-bp($bp-name);
26
+
27
+ @media (min-width: #{$bp-value}) {
28
+ @include gen.generate-display('#{$bp}\\:');
29
+ @include gen.generate-flex-direction('#{$bp}\\:');
30
+ @include gen.generate-flex-wrap('#{$bp}\\:');
31
+ @include gen.generate-flex-sizing('#{$bp}\\:');
32
+ @include gen.generate-alignment('#{$bp}\\:');
33
+ @include gen.generate-grid('#{$bp}\\:');
34
+ @include gen.generate-position('#{$bp}\\:');
35
+ @include gen.generate-overflow('#{$bp}\\:');
36
+ @include gen.generate-gap('#{$bp}\\:');
37
+ @include gen.generate-padding('#{$bp}\\:', $directions: false);
38
+ @include gen.generate-margin('#{$bp}\\:', $directions: false);
39
+ @include gen.generate-auto-margins('#{$bp}\\:');
40
+ @include gen.generate-width-fractions('#{$bp}\\:', $include-auto: true);
41
+ @include gen.generate-max-widths('#{$bp}\\:');
42
+ @include gen.generate-text-align('#{$bp}\\:');
43
+ @include gen.generate-visibility('#{$bp}\\:');
44
+ @include gen.generate-order('#{$bp}\\:');
45
+ }
46
+ }
@@ -0,0 +1,62 @@
1
+ // ---------------------------------------------------------------------------
2
+ // Sizing Utilities
3
+ // ---------------------------------------------------------------------------
4
+ // Width, height, min/max sizing utilities.
5
+ // ---------------------------------------------------------------------------
6
+
7
+ @use '../variables' as *;
8
+ @use 'mixins' as gen;
9
+
10
+ // ============================================================================
11
+ // FRACTIONAL & KEYWORD SIZES
12
+ // ============================================================================
13
+
14
+ @include gen.generate-width-fractions;
15
+
16
+ @each $name, $val in $size-fractions {
17
+ @if $name != 'screen' {
18
+ .h-#{$name} {
19
+ height: $val;
20
+ }
21
+ }
22
+ }
23
+
24
+ .h-screen {
25
+ height: 100vh;
26
+ }
27
+
28
+ // ============================================================================
29
+ // MIN HEIGHT
30
+ // ============================================================================
31
+
32
+ .min-h-0 {
33
+ min-height: 0;
34
+ }
35
+
36
+ .min-h-full {
37
+ min-height: 100%;
38
+ }
39
+
40
+ .min-h-screen {
41
+ min-height: 100vh;
42
+ }
43
+
44
+ // ============================================================================
45
+ // MAX WIDTH
46
+ // ============================================================================
47
+
48
+ @include gen.generate-max-widths;
49
+
50
+ // ============================================================================
51
+ // FIXED SIZES (full spacing scale)
52
+ // ============================================================================
53
+
54
+ @each $key, $val in $spacing-steps {
55
+ .w-#{$key} {
56
+ width: $val;
57
+ }
58
+
59
+ .h-#{$key} {
60
+ height: $val;
61
+ }
62
+ }
@@ -0,0 +1,12 @@
1
+ // ---------------------------------------------------------------------------
2
+ // Spacing Utilities
3
+ // ---------------------------------------------------------------------------
4
+ // Margin, padding, and gap utilities.
5
+ // ---------------------------------------------------------------------------
6
+
7
+ @use 'mixins' as *;
8
+
9
+ @include generate-gap;
10
+ @include generate-padding;
11
+ @include generate-margin;
12
+ @include generate-auto-margins;