winduum 2.0.0-next.1 → 2.0.0-next.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 (219) hide show
  1. package/package.json +12 -12
  2. package/plugin/index.js +10 -10
  3. package/plugin/utilities/dot.js +2 -2
  4. package/src/base/breakpoints.css +10 -10
  5. package/src/base/keyframes.css +3 -3
  6. package/src/components/badge/bordered.css +5 -15
  7. package/src/components/badge/circle.css +4 -4
  8. package/src/components/badge/default.css +34 -18
  9. package/src/components/badge/index.css +1 -1
  10. package/src/components/badge/lg.css +2 -2
  11. package/src/components/badge/muted.css +3 -3
  12. package/src/components/badge/props/default.css +9 -0
  13. package/src/components/badge/readme.md +12 -12
  14. package/src/components/badge/sm.css +3 -3
  15. package/src/components/badge/square.css +3 -3
  16. package/src/components/breadcrumb/default.css +7 -7
  17. package/src/components/breadcrumb/index.css +1 -1
  18. package/src/components/breadcrumb/props/default.css +5 -0
  19. package/src/components/breadcrumb/readme.md +1 -1
  20. package/src/components/button/bordered.css +18 -18
  21. package/src/components/button/circle.css +5 -5
  22. package/src/components/button/default.css +29 -29
  23. package/src/components/button/fill.css +5 -5
  24. package/src/components/button/ghosted.css +13 -13
  25. package/src/components/button/interactive.css +32 -32
  26. package/src/components/button/lg.css +3 -3
  27. package/src/components/button/muted.css +13 -13
  28. package/src/components/button/props/default.css +9 -9
  29. package/src/components/button/props/interactive.css +7 -7
  30. package/src/components/button/raised.css +5 -5
  31. package/src/components/button/readme.md +2 -2
  32. package/src/components/button/sm.css +3 -3
  33. package/src/components/button/square.css +4 -4
  34. package/src/components/card/default.css +4 -6
  35. package/src/components/card/index.css +1 -1
  36. package/src/components/card/props/default.css +6 -0
  37. package/src/components/card/readme.md +1 -1
  38. package/src/components/carousel/content.css +2 -2
  39. package/src/components/carousel/default.css +1 -1
  40. package/src/components/check/default.css +34 -41
  41. package/src/components/check/index.css +1 -2
  42. package/src/components/check/interactive.css +31 -25
  43. package/src/components/check/invalid.css +7 -6
  44. package/src/components/check/props/default.css +13 -0
  45. package/src/components/check/readme.md +8 -9
  46. package/src/components/color/default.css +13 -25
  47. package/src/components/color/index.css +1 -2
  48. package/src/components/color/interactive.css +18 -12
  49. package/src/components/color/props/default.css +7 -0
  50. package/src/components/color/readme.md +7 -8
  51. package/src/components/compare/default.css +17 -18
  52. package/src/components/compare/index.js +2 -2
  53. package/src/components/control/color.css +8 -8
  54. package/src/components/control/default.css +36 -39
  55. package/src/components/control/file.css +14 -12
  56. package/src/components/control/floating-interactive.css +5 -5
  57. package/src/components/control/floating.css +7 -7
  58. package/src/components/control/icon.css +8 -8
  59. package/src/components/control/index.css +5 -6
  60. package/src/components/control/interactive.css +9 -9
  61. package/src/components/control/invalid.css +7 -7
  62. package/src/components/control/props/color.css +5 -0
  63. package/src/components/control/props/default.css +16 -0
  64. package/src/components/control/props/floating.css +4 -0
  65. package/src/components/control/props/icon.css +4 -0
  66. package/src/components/control/props/select.css +4 -0
  67. package/src/components/control/readme.md +19 -20
  68. package/src/components/control/select-multiple.css +2 -2
  69. package/src/components/control/select.css +8 -8
  70. package/src/components/dialog/content.css +6 -6
  71. package/src/components/dialog/default.css +11 -8
  72. package/src/components/dialog/index.css +2 -2
  73. package/src/components/dialog/index.js +3 -3
  74. package/src/components/dialog/props/content.css +5 -0
  75. package/src/components/dialog/props/default.css +6 -0
  76. package/src/components/dialog/readme.md +2 -2
  77. package/src/components/drawer/content.css +4 -4
  78. package/src/components/drawer/default.css +8 -5
  79. package/src/components/drawer/index.css +2 -2
  80. package/src/components/drawer/index.js +3 -3
  81. package/src/components/drawer/props/content.css +7 -0
  82. package/src/components/drawer/props/default.css +3 -0
  83. package/src/components/drawer/readme.md +2 -2
  84. package/src/components/field/default.css +6 -6
  85. package/src/components/form/index.js +5 -5
  86. package/src/components/group/default.css +11 -11
  87. package/src/components/group/readme.md +6 -6
  88. package/src/components/group/vertical.css +2 -2
  89. package/src/components/heading/default.css +6 -6
  90. package/src/components/heading/index.css +1 -1
  91. package/src/components/heading/lg.css +2 -2
  92. package/src/components/heading/props/default.css +6 -0
  93. package/src/components/heading/readme.md +8 -8
  94. package/src/components/heading/sm.css +2 -2
  95. package/src/components/image/avatar.css +1 -1
  96. package/src/components/image/default.css +1 -1
  97. package/src/components/image/readme.md +6 -6
  98. package/src/components/index.css +0 -2
  99. package/src/components/info/default.css +6 -6
  100. package/src/components/info/index.css +1 -1
  101. package/src/components/info/props/default.css +4 -0
  102. package/src/components/info/readme.md +6 -6
  103. package/src/components/label/default.css +6 -6
  104. package/src/components/label/index.css +1 -1
  105. package/src/components/label/props/default.css +4 -0
  106. package/src/components/label/readme.md +6 -6
  107. package/src/components/link/default.css +6 -6
  108. package/src/components/link/index.css +1 -2
  109. package/src/components/link/interactive.css +3 -10
  110. package/src/components/link/props/default.css +4 -0
  111. package/src/components/link/readme.md +7 -7
  112. package/src/components/notice/default.css +16 -20
  113. package/src/components/notice/index.css +1 -1
  114. package/src/components/notice/props/default.css +8 -0
  115. package/src/components/notice/readme.md +6 -6
  116. package/src/components/pagination/default.css +2 -2
  117. package/src/components/popover/content.css +14 -15
  118. package/src/components/popover/default.css +1 -1
  119. package/src/components/popover/index.css +1 -1
  120. package/src/components/popover/props/content.css +8 -0
  121. package/src/components/popover/readme.md +1 -1
  122. package/src/components/progress/default.css +15 -16
  123. package/src/components/progress/index.css +1 -1
  124. package/src/components/progress/lg.css +2 -2
  125. package/src/components/progress/meter.css +7 -7
  126. package/src/components/progress/props/default.css +6 -0
  127. package/src/components/progress/readme.md +9 -9
  128. package/src/components/progress/sm.css +2 -2
  129. package/src/components/range/default.css +47 -49
  130. package/src/components/range/index.css +1 -1
  131. package/src/components/range/index.js +2 -2
  132. package/src/components/range/multi.css +6 -6
  133. package/src/components/range/props/default.css +9 -0
  134. package/src/components/range/readme.md +8 -8
  135. package/src/components/range/vertical.css +3 -3
  136. package/src/components/rating/default.css +11 -11
  137. package/src/components/rating/index.css +1 -1
  138. package/src/components/rating/invalid.css +3 -3
  139. package/src/components/rating/props/default.css +8 -0
  140. package/src/components/rating/readme.md +7 -7
  141. package/src/components/switch/default.css +23 -26
  142. package/src/components/switch/index.css +1 -1
  143. package/src/components/switch/interactive.css +13 -9
  144. package/src/components/switch/invalid.css +4 -4
  145. package/src/components/switch/props/default.css +17 -0
  146. package/src/components/switch/readme.md +8 -8
  147. package/src/components/table/default.css +11 -11
  148. package/src/components/table/index.css +1 -2
  149. package/src/components/table/interactive.css +14 -14
  150. package/src/components/table/props/default.css +8 -0
  151. package/src/components/table/readme.md +1 -2
  152. package/src/components/tabs/default.css +6 -6
  153. package/src/components/text/default.css +102 -72
  154. package/src/components/text/index.css +1 -1
  155. package/src/components/text/props/default.css +9 -0
  156. package/src/components/text/readme.md +6 -6
  157. package/src/components/title/default.css +6 -6
  158. package/src/components/title/index.css +1 -1
  159. package/src/components/title/lg.css +2 -2
  160. package/src/components/title/props/default.css +5 -0
  161. package/src/components/title/readme.md +8 -8
  162. package/src/components/title/sm.css +2 -2
  163. package/src/components/toast/content.css +16 -15
  164. package/src/components/toast/default.css +8 -8
  165. package/src/components/toast/index.css +2 -2
  166. package/src/components/toast/props/content.css +7 -0
  167. package/src/components/toast/props/default.css +4 -0
  168. package/src/components/toast/readme.md +2 -2
  169. package/src/components/toaster/default.css +4 -4
  170. package/src/components/toaster/index.css +1 -1
  171. package/src/components/toaster/index.js +8 -8
  172. package/src/components/toaster/props/default.css +4 -0
  173. package/src/components/toaster/readme.md +1 -1
  174. package/src/components/tooltip/default.css +15 -15
  175. package/src/components/tooltip/index.css +1 -1
  176. package/src/components/tooltip/props/default.css +12 -0
  177. package/src/components/tooltip/readme.md +2 -2
  178. package/src/utilities/divider.css +13 -3
  179. package/src/utilities/ripple/index.css +9 -4
  180. package/src/utilities/skeleton/default.css +8 -1
  181. package/src/utilities/skeleton/props/default.css +3 -3
  182. package/src/utilities/swap/default.css +3 -3
  183. package/src/components/badge/default-props.css +0 -8
  184. package/src/components/breadcrumb/default-props.css +0 -5
  185. package/src/components/card/default-props.css +0 -4
  186. package/src/components/check/default-props.css +0 -13
  187. package/src/components/check/interactive-props.css +0 -3
  188. package/src/components/color/default-props.css +0 -11
  189. package/src/components/color/interactive-props.css +0 -3
  190. package/src/components/control/color-props.css +0 -5
  191. package/src/components/control/default-props.css +0 -16
  192. package/src/components/control/floating-props.css +0 -4
  193. package/src/components/control/icon-props.css +0 -4
  194. package/src/components/control/interactive-props.css +0 -3
  195. package/src/components/control/select-props.css +0 -4
  196. package/src/components/dialog/content-props.css +0 -5
  197. package/src/components/dialog/default-props.css +0 -6
  198. package/src/components/drawer/content-props.css +0 -6
  199. package/src/components/drawer/default-props.css +0 -3
  200. package/src/components/heading/default-props.css +0 -6
  201. package/src/components/info/default-props.css +0 -4
  202. package/src/components/label/default-props.css +0 -4
  203. package/src/components/link/default-props.css +0 -4
  204. package/src/components/link/interactive-props.css +0 -5
  205. package/src/components/notice/default-props.css +0 -8
  206. package/src/components/popover/content-props.css +0 -8
  207. package/src/components/progress/default-props.css +0 -4
  208. package/src/components/range/default-props.css +0 -10
  209. package/src/components/rating/default-props.css +0 -5
  210. package/src/components/switch/default-props.css +0 -17
  211. package/src/components/switch/interactive-props.css +0 -3
  212. package/src/components/table/default-props.css +0 -8
  213. package/src/components/table/interactive-props.css +0 -4
  214. package/src/components/text/default-props.css +0 -9
  215. package/src/components/title/default-props.css +0 -5
  216. package/src/components/toast/content-props.css +0 -7
  217. package/src/components/toast/default-props.css +0 -4
  218. package/src/components/toaster/default-props.css +0 -4
  219. package/src/components/tooltip/default-props.css +0 -12
@@ -1,4 +1,4 @@
1
- .button:is(.lg) {
2
- --button-height: 3rem;
3
- --button-padding-inline: 1.75rem;
1
+ .x-button:is(.lg) {
2
+ --x-button-height: 3rem;
3
+ --x-button-padding-inline: 1.75rem;
4
4
  }
@@ -1,14 +1,14 @@
1
- .button:is(.muted) {
2
- --button-disabled-background-color-opacity: 5%;
3
- --button-disabled-background-color-mix: transparent;
4
- --button-disabled-color: var(--color-accent);
5
- --button-active-background-color-opacity: 30%;
6
- --button-active-background-color-mix: transparent;
7
- --button-active-color: var(--color-accent);
8
- --button-hover-background-color-opacity: 20%;
9
- --button-hover-background-color-mix: transparent;
10
- --button-hover-color: var(--color-accent);
11
- --button-focus-outline-offset: -2px;
12
- --button-color: var(--color-accent);
13
- --button-background-color-opacity: 10%;
1
+ .x-button:is(.muted) {
2
+ --x-button-disabled-background-color-opacity: 5%;
3
+ --x-button-disabled-background-color-mix: transparent;
4
+ --x-button-disabled-color: var(--color-accent);
5
+ --x-button-active-background-color-opacity: 30%;
6
+ --x-button-active-background-color-mix: transparent;
7
+ --x-button-active-color: var(--color-accent);
8
+ --x-button-hover-background-color-opacity: 20%;
9
+ --x-button-hover-background-color-mix: transparent;
10
+ --x-button-hover-color: var(--color-accent);
11
+ --x-button-focus-outline-offset: -2px;
12
+ --x-button-color: var(--color-accent);
13
+ --x-button-background-color-opacity: 10%;
14
14
  }
@@ -1,11 +1,11 @@
1
1
  :root, :host {
2
- --button-outline-width: 2px;
3
- --button-border-width: 0px;
4
- --button-border-radius: var(--radius);
5
- --button-font-size: var(--font-size-sm);
6
- --button-font-weight: var(--font-weight-medium);
7
- --button-gap: var(--spacing-sm);
8
- --button-height: 2.25rem;
9
- --button-padding-block: 0.375rem;
10
- --button-padding-inline: 0.75rem;
2
+ --x-button-outline-width: 2px;
3
+ --x-button-border-width: 0px;
4
+ --x-button-border-radius: var(--radius);
5
+ --x-button-font-size: var(--font-size-sm);
6
+ --x-button-font-weight: var(--font-weight-medium);
7
+ --x-button-gap: var(--spacing-sm);
8
+ --x-button-height: 2.25rem;
9
+ --x-button-padding-block: 0.375rem;
10
+ --x-button-padding-inline: 0.75rem;
11
11
  }
@@ -1,9 +1,9 @@
1
1
  :root, :host {
2
- --button-hover-background-color-mix: var(--color-dark);
3
- --button-hover-background-color-opacity: 80%;
4
- --button-focus-outline-offset: 2px;
5
- --button-focus-outline-color-opacity: 50%;
6
- --button-active-background-color-mix: var(--color-dark);
7
- --button-active-background-color-opacity: 90%;
8
- --button-disabled-background-color-opacity: 75%;
2
+ --x-button-hover-background-color-mix: var(--color-dark);
3
+ --x-button-hover-background-color-opacity: 80%;
4
+ --x-button-focus-outline-offset: 2px;
5
+ --x-button-focus-outline-color-opacity: 50%;
6
+ --x-button-active-background-color-mix: var(--color-dark);
7
+ --x-button-active-background-color-opacity: 90%;
8
+ --x-button-disabled-background-color-opacity: 75%;
9
9
  }
@@ -1,6 +1,6 @@
1
- .button:is(.raised) {
2
- --button-border-width: 1px;
3
- --button-border-color-opacity: 75%;
4
- --button-border-color: var(--button-background-color);
5
- --button-border-color-mix: var(--button-color);
1
+ .x-button:is(.raised) {
2
+ --x-button-border-width: 1px;
3
+ --x-button-border-color-opacity: 75%;
4
+ --x-button-border-color: var(--x-button-background-color);
5
+ --x-button-border-color-mix: var(--x-button-color);
6
6
  }
@@ -14,10 +14,10 @@ Include CSS either globally or to your component _([you can't use TailwindCSS la
14
14
  or modular (you can use your own props or CSS)
15
15
 
16
16
  ```css
17
- @import "winduum/src/button/default.css" layer(components);
18
17
  @import "winduum/src/button/props/default.css" layer(components);
19
- @import "winduum/src/button/interactive.css" layer(components);
20
18
  @import "winduum/src/button/props/interactive.css" layer(components);
19
+ @import "winduum/src/button/default.css" layer(components);
20
+ @import "winduum/src/button/interactive.css" layer(components);
21
21
  @import "winduum/src/button/sm.css" layer(components);
22
22
  @import "winduum/src/button/lg.css" layer(components);
23
23
  @import "winduum/src/button/bordered.css" layer(components);
@@ -1,4 +1,4 @@
1
- .button:is(.sm) {
2
- --button-height: 2rem;
3
- --button-padding-inline: 1rem;
1
+ .x-button:is(.sm) {
2
+ --x-button-height: 2rem;
3
+ --x-button-padding-inline: 1rem;
4
4
  }
@@ -1,5 +1,5 @@
1
- .button:is(.square) {
2
- --button-padding-block: 0;
3
- --button-padding-inline: 0;
4
- --button-width: var(--button-height);
1
+ .x-button:is(.square) {
2
+ --x-button-padding-block: 0;
3
+ --x-button-padding-inline: 0;
4
+ --x-button-width: var(--x-button-height);
5
5
  }
@@ -1,9 +1,7 @@
1
- .card {
2
- --card-p: var(--card-py) var(--card-px);
3
-
4
- background-color: var(--color-body-primary);
5
- border-radius: var(--radius-2xl);
6
- padding: var(--card-p);
1
+ .x-card {
2
+ background-color: var(--x-card-background-color);
3
+ border-radius: var(--x-card-border-radius);
4
+ padding: var(--x-card-padding-block) var(--x-card-padding-inline);
7
5
  display: flex;
8
6
  flex-direction: column;
9
7
  }
@@ -1,2 +1,2 @@
1
+ @import "props/default.css";
1
2
  @import "default.css";
2
- @import "default-props.css";
@@ -0,0 +1,6 @@
1
+ :root, :host {
2
+ --x-card-background-color: var(--color-body-primary);
3
+ --x-card-border-radius: var(--radius-2xl);
4
+ --x-card-padding-block: var(--spacing-2xl);
5
+ --x-card-padding-inline: var(--spacing-3xl);
6
+ }
@@ -14,8 +14,8 @@ Include CSS either globally or to your component _([you can't use TailwindCSS la
14
14
  or modular (you can use your own props or CSS)
15
15
 
16
16
  ```css
17
+ @import "winduum/src/components/card/props/default.css" layer(components);
17
18
  @import "winduum/src/components/card/default.css" layer(components);
18
- @import "winduum/src/components/card/default-props.css" layer(components);
19
19
  ```
20
20
 
21
21
  ### Local imports
@@ -1,10 +1,9 @@
1
- .carousel-content {
1
+ .x-carousel-content {
2
2
  display: flex;
3
3
  overflow: auto;
4
4
  user-select: none;
5
5
  scrollbar-width: none;
6
6
  -webkit-overflow-scrolling: touch;
7
- overscroll-behavior-x: none;
8
7
  position: relative;
9
8
  scroll-behavior: smooth;
10
9
  scroll-snap-type: x mandatory;
@@ -22,6 +21,7 @@
22
21
  }
23
22
  }
24
23
 
24
+ /* TODO grabbing */
25
25
  &:is(.grabbing) {
26
26
  &, & * {
27
27
  cursor: grabbing;
@@ -1,3 +1,3 @@
1
- .carousel {
1
+ .x-carousel {
2
2
  inline-size: 100%;
3
3
  }
@@ -1,64 +1,57 @@
1
- .check {
2
- --check-outline-color: var(--color-accent);
3
- --check-icon-color: var(--color-accent-foreground);
1
+ .x-check {
2
+ --x-check-outline-color: var(--color-accent);
3
+ --x-check-icon-color: var(--color-accent-foreground);
4
4
 
5
- font-weight: var(--check-font-weight);
6
- font-size: var(--check-font-size);
7
- line-height: var(--check-line-height);
8
- letter-spacing: var(--check-letter-spacing);
9
- gap: var(--check-gap);
5
+ font-weight: var(--x-check-font-weight);
6
+ font-size: var(--x-check-font-size);
7
+ line-height: var(--x-check-line-height);
8
+ letter-spacing: var(--x-check-letter-spacing);
9
+ gap: var(--x-check-gap);
10
10
  display: inline-flex;
11
11
  text-wrap: pretty;
12
12
 
13
13
  &:has([type="radio"]) {
14
- --check-icon: var(--mask-radio);
15
- --check-border-radius: 50%;
16
- }
17
-
18
- :where(a) {
19
- color: var(--color-accent);
20
- text-decoration: underline;
14
+ --x-check-icon: var(--mask-radio);
15
+ --x-check-border-radius: 50%;
21
16
  }
22
17
 
23
18
  :where(input) {
24
- --tw-border-opacity: 0.2;
25
- --tw-border-mix: transparent;
26
- --tw-outline-opacity: 0;
27
- --tw-outline-mix: transparent;
28
- --tw-bg-opacity: 0;
29
- --tw-bg-mix: transparent;
30
-
31
- width: var(--check-size);
32
- height: var(--check-size);
33
- border-radius: var(--check-border-radius);
34
- background-color: color-mix(in var(--default-color-space), var(--check-bg) calc(var(--tw-bg-opacity) * 100%), var(--tw-bg-mix));
19
+ inline-size: var(--x-check-size);
20
+ block-size: var(--x-check-size);
21
+ border-radius: var(--x-check-border-radius);
22
+ background-color:
23
+ color-mix(
24
+ in var(--x-check-background-color-space, srgb),
25
+ var(--x-check-background-color) var(--x-check-background-color-opacity, 0%),
26
+ var(--x-check-background-color-mix, transparent)
27
+ );
35
28
  border:
36
- var(--check-border-width) solid
29
+ var(--x-check-border-width) solid
37
30
  color-mix(
38
- in var(--default-color-space),
39
- var(--check-border-color) calc(var(--tw-border-opacity) * 100%),
40
- var(--tw-border-mix)
31
+ in var(--x-check-border-color-space, srgb),
32
+ var(--x-check-border-color) var(--x-check-border-color-opacity, 20%),
33
+ var(--x-check-border-color-mix, transparent)
41
34
  );
42
35
  outline:
43
- var(--check-outline-width) solid
36
+ var(--x-check-outline-width) solid
44
37
  color-mix(
45
- in var(--default-color-space),
46
- var(--check-outline-color) calc(var(--tw-outline-opacity) * 100%),
47
- var(--tw-outline-mix)
38
+ in var(--x-check-outline-color-space, srgb),
39
+ var(--x-check-outline-color) var(--x-check-outline-color-opacity, 0%),
40
+ var(--x-check-outline-color-mix, transparent)
48
41
  );
49
- outline-offset: var(--check-outline-offset);
42
+ outline-offset: var(--x-check-outline-offset);
50
43
  display: flex;
51
44
  flex-shrink: 0;
52
45
 
53
46
  &::before {
54
- width: var(--check-icon-size);
55
- height: var(--check-icon-size);
56
- color: var(--check-icon-color);
57
- mask: var(--check-icon);
47
+ width: var(--x-check-icon-size);
48
+ height: var(--x-check-icon-size);
49
+ color: var(--x-check-icon-color);
50
+ mask: var(--x-check-icon);
58
51
  transition: inherit;
59
52
  content: "";
60
53
  background-color: currentColor;
61
- opacity: 0;
54
+ opacity: 0%;
62
55
  transform: scale(0);
63
56
  will-change: transform;
64
57
  margin: auto;
@@ -66,7 +59,7 @@
66
59
 
67
60
  &:where(:required) {
68
61
  + *::after {
69
- color: var(--color-error);
62
+ color: var(--x-check-required-color, var(--color-error));
70
63
  content: " *";
71
64
  }
72
65
  }
@@ -1,5 +1,4 @@
1
- @import "default-props.css";
1
+ @import "props/default.css";
2
2
  @import "default.css";
3
- @import "interactive-props.css";
4
3
  @import "interactive.css";
5
4
  @import "invalid.css";
@@ -1,48 +1,54 @@
1
- .check {
2
- --check-hover-border-color: var(--color-accent);
3
- --check-hover-bg: var(--color-accent);
4
- --check-checked-bg: var(--color-accent);
5
- --check-focus-border-color: var(--color-accent);
1
+ .x-check {
2
+ --x-check-hover-border-color: var(--color-accent);
3
+ --x-check-hover-background-color: var(--color-accent);
4
+ --x-check-checked-background-color: var(--color-accent);
5
+ --x-check-focus-border-color: var(--color-accent);
6
6
 
7
7
  :where(input) {
8
8
  transition-property: var(--default-transition-property);
9
9
  transition-timing-function: var(--transition-timing-function-in-out);
10
10
  transition-duration: var(--default-transition-duration);
11
11
 
12
- &:enabled {
13
- &:is(:hover, :focus-visible) {
14
- --check-border-color: var(--check-hover-border-color);
15
- --check-bg: var(--check-hover-bg);
16
- --tw-border-opacity: var(--check-hover-border-opacity, 0.75);
17
- --tw-bg-opacity: var(--check-hover-bg-opacity, 0.1);
18
- }
12
+ &:where(:hover, :focus-visible) {
13
+ --x-check-background-color: var(--x-check-hover-background-color);
14
+ --x-check-background-color-opacity: var(--x-check-hover-background-color-opacity, 10%);
15
+ --x-check-border-color: var(--x-check-hover-border-color);
16
+ --x-check-border-color-opacity: var(--x-check-hover-border-color-opacity, 75%);
17
+ }
19
18
 
20
- &:focus {
21
- --check-border-color: var(--check-focus-border-color);
22
- --check-outline-offset: var(--check-focus-outline-offset);
23
- --tw-border-opacity: var(--check-focus-border-opacity, 0.75);
24
- --tw-outline-opacity: var(--check-focus-outline-opacity, 0.2);
25
- }
19
+ &:focus {
20
+ --x-check-border-color: var(--x-check-focus-border-color);
21
+ --x-check-border-color-opacity: var(--x-check-focus-border-color-opacity, 75%);
22
+ --x-check-outline-color-opacity: var(--x-check-focus-outline-opacity, 20%);
23
+ --x-check-outline-offset: var(--x-check-focus-outline-offset);
26
24
  }
27
25
 
28
26
  &:disabled {
29
- --tw-bg-opacity: var(--check-disabled-bg-opacity, 0.15);
27
+ --x-check-background-color: var(--x-check-disabled-background-color, currentColor);
28
+ --x-check-background-color-mix: var(--x-check-disabled-background-color-mix, transparent);
29
+ --x-check-background-color-opacity: var(--x-check-disabled-background-color-opacity, 5%);
30
+ --x-check-border-color: var(--x-check-disabled-border-color, currentColor);
31
+ --x-check-border-color-mix: var(--x-check-disabled-border-color-mix, transparent);
32
+ --x-check-border-color-opacity: var(--x-check-disabled-border-color-opacity, 15%);
30
33
 
31
34
  cursor: not-allowed;
32
- opacity: var(--check-disabled-opacity);
33
35
  }
34
36
 
35
37
  &:where([type="checkbox"]):indeterminate {
36
- --check-icon: var(--mask-indeterminate);
38
+ --x-check-icon: var(--mask-indeterminate);
37
39
  }
38
40
 
39
41
  &:is(:checked, [type="checkbox"]:indeterminate) {
40
- --check-bg: var(--check-checked-bg);
41
- --tw-bg-opacity: 1;
42
- --tw-border-opacity: 0;
42
+ --x-check-background-color: var(--x-check-checked-background-color);
43
+ --x-check-background-color-opacity: 100%;
44
+ --x-check-border-color-opacity: 0%;
45
+
46
+ &:disabled {
47
+ opacity: var(--x-check-checked-disabled-opacity, 75%);
48
+ }
43
49
 
44
50
  &::before {
45
- opacity: 1;
51
+ opacity: 100%;
46
52
  transform: scale(1);
47
53
  }
48
54
  }
@@ -1,8 +1,9 @@
1
- .check {
2
- &.invalid, .validated & :where(input):invalid {
3
- --check-border-color: var(--color-error);
4
- --check-outline-color: var(--color-error);
5
- --check-bg: var(--color-error);
6
- --tw-border-opacity: 1;
1
+ .x-check {
2
+ &.invalid, :user-invalid, .validated & :invalid {
3
+ --x-check-border-color: var(--x-check-invalid-border-color, var(--color-error));
4
+ --x-check-outline-color: var(--x-check-invalid-outline-color, var(--color-error));
5
+ --x-check-background-color: var(--x-check-invalid-background-color, var(--color-error));
6
+ --x-check-background-color-opacity: var(--x-check-invalid-background-color-opacity, 15%);
7
+ --x-check-border-color-opacity: var(--x-check-invalid-border-color-opacity, 100%);
7
8
  }
8
9
  }
@@ -0,0 +1,13 @@
1
+ :root, :host {
2
+ --x-check-size: 1.25rem;
3
+ --x-check-icon-size: 1.125rem;
4
+ --x-check-icon: var(--mask-check);
5
+ --x-check-gap: var(--spacing-md);
6
+ --x-check-font-size: var(--font-size-sm);
7
+ --x-check-line-height: calc(1em + 0.25rem);
8
+ --x-check-border-radius: var(--radius-md);
9
+ --x-check-border-width: 1px;
10
+ --x-check-background-color: currentColor;
11
+ --x-check-border-color: currentColor;
12
+ --x-check-outline-width: 2px;
13
+ }
@@ -1,4 +1,4 @@
1
- # [Check](https://winduum.dev/docs/ui/check.html)
1
+ # [Check](https://winduum.dev/docs/components/check.html)
2
2
 
3
3
  ## Installation
4
4
  ```shell
@@ -8,17 +8,16 @@ Learn more how to set up Winduum [here](https://winduum.dev/docs/).
8
8
  Include CSS either globally or to your component _([you can't use TailwindCSS layers in per-component CSS](https://tailwindcss.com/docs/adding-custom-styles#layers-and-per-component-css))_
9
9
 
10
10
  ```css
11
- @import "winduum/src/ui/check/index.css" layer(components);
11
+ @import "winduum/src/components/check/index.css" layer(components);
12
12
  ```
13
13
 
14
14
  or modular (you can use your own props or CSS)
15
15
 
16
16
  ```css
17
- @import "winduum/src/ui/check/default-props.css" layer(components);
18
- @import "winduum/src/ui/check/default.css" layer(components);
19
- @import "winduum/src/ui/check/interactive-props.css" layer(components);
20
- @import "winduum/src/ui/check/interactive.css" layer(components);
21
- @import "winduum/src/ui/check/invalid.css" layer(components);
17
+ @import "winduum/src/components/check/props/default.css" layer(components);
18
+ @import "winduum/src/components/check/default.css" layer(components);
19
+ @import "winduum/src/components/check/interactive.css" layer(components);
20
+ @import "winduum/src/components/check/invalid.css" layer(components);
22
21
  ```
23
22
 
24
23
  ### Local imports
@@ -26,8 +25,8 @@ By default, imports are directly from `npm` so you can leverage updates.
26
25
  You can also copy and paste the code from this directory to your project and remap the imports to local.
27
26
 
28
27
  ```css
29
- @import "@/components/ui/check/assets/index.css" layer(components);
28
+ @import "@/components/check/assets/index.css" layer(components);
30
29
  ```
31
30
 
32
31
  ### Docs
33
- Visit [docs](https://winduum.dev/docs/ui/check.html) to learn more about usage examples.
32
+ Visit [docs](https://winduum.dev/docs/components/check.html) to learn more about usage examples.
@@ -1,31 +1,20 @@
1
- .color {
1
+ .x-color {
2
+ --x-color-outline-color: var(--color-accent);
3
+
2
4
  display: inline-flex;
3
5
 
4
6
  :where(input) {
5
- --tw-border-opacity: 0.1;
6
- --tw-border-mix: transparent;
7
- --tw-outline-opacity: 0;
8
- --tw-outline-mix: transparent;
9
-
10
- width: var(--color-size);
11
- height: var(--color-size);
12
- padding: var(--color-p);
13
- border-radius: var(--color-border-radius);
14
- border:
15
- var(--color-border-width) solid
16
- color-mix(
17
- in var(--default-color-space),
18
- var(--color-border-color) calc(var(--tw-border-opacity) * 100%),
19
- var(--tw-border-mix)
20
- );
7
+ inline-size: var(--x-color-size);
8
+ block-size: var(--x-color-size);
9
+ border-radius: var(--x-color-border-radius);
21
10
  outline:
22
- var(--color-outline-width) solid
11
+ var(--x-color-outline-width, 1px) solid
23
12
  color-mix(
24
- in var(--default-color-space),
25
- var(--color-outline-color) calc(var(--tw-outline-opacity) * 100%),
26
- var(--tw-outline-mix)
13
+ in var(--x-color-outline-color-space, srgb),
14
+ var(--x-color-outline-color) var(--x-color-outline-color-opacity, 0%),
15
+ var(--x-color-outline-color-mix, transparent)
27
16
  );
28
- outline-offset: var(--check-outline-offset);
17
+ outline-offset: var(--x-color-outline-offset);
29
18
  display: inline-grid;
30
19
 
31
20
  &::before, &::after {
@@ -36,12 +25,11 @@
36
25
  }
37
26
 
38
27
  &::before {
39
- background-color: var(--color-primary);
40
- border-color: inherit;
28
+ background-color: var(--x-color-primary);
41
29
  }
42
30
 
43
31
  &::after {
44
- background-color: var(--color-secondary);
32
+ background-color: var(--x-color-secondary);
45
33
  clip-path: polygon(100% 0, 100% 100%, 0 100%);
46
34
  }
47
35
  }
@@ -1,4 +1,3 @@
1
- @import "default-props.css";
1
+ @import "props/default.css";
2
2
  @import "default.css";
3
- @import "interactive-props.css";
4
3
  @import "interactive.css";
@@ -1,30 +1,36 @@
1
- .color {
1
+ .x-color {
2
2
  :where(input) {
3
3
  transition-property: var(--default-transition-property);
4
4
  transition-timing-function: var(--transition-timing-function-in-out);
5
5
  transition-duration: var(--default-transition-duration);
6
6
 
7
- &:where(:disabled) {
7
+ &:disabled {
8
8
  cursor: not-allowed;
9
9
 
10
10
  &::before, &::after {
11
- opacity: var(--color-disabled-opacity);
11
+ opacity: var(--x-color-disabled-opacity, 50%);
12
12
  }
13
13
  }
14
14
 
15
- &:where(:enabled) {
16
- &:is(:hover) {
17
- --tw-border-opacity: 0.3;
15
+ &:enabled {
16
+ &:hover {
17
+ --x-color-outline-color-opacity: var(--x-color-hover-outline-color-opacity);
18
+ --x-color-outline-offset: var(--x-color-hover-outline-offset);
18
19
  }
19
20
 
20
- &:is(:focus-visible) {
21
- --tw-border-opacity: 1;
22
- --tw-outline-opacity: 0.2;
21
+ &:focus-visible {
22
+ --x-color-outline-color-opacity: var(--x-color-focus-outline-color-opacity, 50%);
23
+ --x-color-outline-offset: var(--x-color-focus-outline-offset, 3px);
23
24
  }
24
- }
25
25
 
26
- &:is(:checked) {
27
- --tw-border-opacity: 1;
26
+ &:checked {
27
+ --x-color-outline-color-opacity: var(--x-color-checked-outline-color-opacity, 100%);
28
+ --x-color-outline-offset: var(--x-color-focus-outline-offset, 3px);
29
+
30
+ &:focus-visible {
31
+ outline-style: dashed;
32
+ }
33
+ }
28
34
  }
29
35
  }
30
36
  }
@@ -0,0 +1,7 @@
1
+ :root, :host {
2
+ --x-color-primary: currentColor;
3
+ --x-color-secondary: transparent;
4
+ --x-color-size: 1.5rem;
5
+ --x-color-border-radius: var(--radius-full);
6
+ --x-color-outline-width: 1px;
7
+ }
@@ -1,4 +1,4 @@
1
- # [Color](https://winduum.dev/docs/ui/color.html)
1
+ # [Color](https://winduum.dev/docs/components/color.html)
2
2
 
3
3
  ## Installation
4
4
  ```shell
@@ -8,16 +8,15 @@ Learn more how to set up Winduum [here](https://winduum.dev/docs/).
8
8
  Include CSS either globally or to your component _([you can't use TailwindCSS layers in per-component CSS](https://tailwindcss.com/docs/adding-custom-styles#layers-and-per-component-css))_
9
9
 
10
10
  ```css
11
- @import "winduum/src/ui/color/index.css" layer(components);
11
+ @import "winduum/src/components/color/index.css" layer(components);
12
12
  ```
13
13
 
14
14
  or modular (you can use your own props or CSS)
15
15
 
16
16
  ```css
17
- @import "winduum/src/ui/color/default-props.css" layer(components);
18
- @import "winduum/src/ui/color/default.css" layer(components);
19
- @import "winduum/src/ui/color/interactive-props.css" layer(components);
20
- @import "winduum/src/ui/color/interactive.css" layer(components);
17
+ @import "winduum/src/components/color/props/default.css" layer(components);
18
+ @import "winduum/src/components/color/default.css" layer(components);
19
+ @import "winduum/src/components/color/interactive.css" layer(components);
21
20
 
22
21
  ```
23
22
 
@@ -26,8 +25,8 @@ By default, imports are directly from `npm` so you can leverage updates.
26
25
  You can also copy and paste the code from this directory to your project and remap the imports to local.
27
26
 
28
27
  ```css
29
- @import "@/components/ui/color/assets/index.css" layer(components);
28
+ @import "@/components/color/assets/index.css" layer(components);
30
29
  ```
31
30
 
32
31
  ### Docs
33
- Visit [docs](https://winduum.dev/docs/ui/color.html) to learn more about usage examples.
32
+ Visit [docs](https://winduum.dev/docs/components/color.html) to learn more about usage examples.