@skewedaspect/sleekspace-ui 0.2.0-beta.1

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 (266) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +111 -0
  3. package/dist/sleekspace-ui.css +12844 -0
  4. package/dist/sleekspace-ui.es.js +19021 -0
  5. package/dist/sleekspace-ui.umd.js +19040 -0
  6. package/docs/components/accordion.md +92 -0
  7. package/docs/components/alert.md +72 -0
  8. package/docs/components/avatar.md +69 -0
  9. package/docs/components/breadcrumbs.md +65 -0
  10. package/docs/components/button/_meta.yaml +12 -0
  11. package/docs/components/button/accessibility.md +16 -0
  12. package/docs/components/button/custom-colors.md +18 -0
  13. package/docs/components/button/icons.md +31 -0
  14. package/docs/components/button/intro.md +8 -0
  15. package/docs/components/button/kinds.md +25 -0
  16. package/docs/components/button/sizes.md +14 -0
  17. package/docs/components/button/states.md +12 -0
  18. package/docs/components/button/usage.md +23 -0
  19. package/docs/components/button/variants.md +14 -0
  20. package/docs/components/button.md +110 -0
  21. package/docs/components/card.md +87 -0
  22. package/docs/components/checkbox.md +77 -0
  23. package/docs/components/collapsible.md +71 -0
  24. package/docs/components/divider.md +62 -0
  25. package/docs/components/dropdown.md +88 -0
  26. package/docs/components/field.md +80 -0
  27. package/docs/components/group.md +41 -0
  28. package/docs/components/input.md +84 -0
  29. package/docs/components/listbox.md +82 -0
  30. package/docs/components/modal.md +101 -0
  31. package/docs/components/navbar.md +64 -0
  32. package/docs/components/number-input.md +78 -0
  33. package/docs/components/page.md +77 -0
  34. package/docs/components/pagination.md +88 -0
  35. package/docs/components/panel.md +74 -0
  36. package/docs/components/popover.md +93 -0
  37. package/docs/components/progress.md +76 -0
  38. package/docs/components/radio.md +86 -0
  39. package/docs/components/sidebar.md +74 -0
  40. package/docs/components/skeleton.md +76 -0
  41. package/docs/components/slider.md +94 -0
  42. package/docs/components/spinner.md +59 -0
  43. package/docs/components/switch.md +97 -0
  44. package/docs/components/table.md +91 -0
  45. package/docs/components/tabs.md +108 -0
  46. package/docs/components/tag.md +75 -0
  47. package/docs/components/tags-input.md +88 -0
  48. package/docs/components/textarea.md +80 -0
  49. package/docs/components/theme.md +65 -0
  50. package/docs/components/toast.md +95 -0
  51. package/docs/components/tooltip.md +90 -0
  52. package/docs/guides/custom-colors.md +84 -0
  53. package/docs/guides/design-tokens.md +105 -0
  54. package/docs/guides/getting-started.md +144 -0
  55. package/docs/guides/installation.md +62 -0
  56. package/docs/guides/theming.md +101 -0
  57. package/package.json +76 -0
  58. package/src/components/Accordion/SkAccordion.vue +133 -0
  59. package/src/components/Accordion/SkAccordionItem.vue +131 -0
  60. package/src/components/Accordion/index.ts +3 -0
  61. package/src/components/Accordion/types.ts +9 -0
  62. package/src/components/Alert/SkAlert.vue +137 -0
  63. package/src/components/Alert/types.ts +10 -0
  64. package/src/components/Avatar/SkAvatar.vue +141 -0
  65. package/src/components/Avatar/index.ts +8 -0
  66. package/src/components/Avatar/types.ts +31 -0
  67. package/src/components/Breadcrumbs/SkBreadcrumbItem.vue +76 -0
  68. package/src/components/Breadcrumbs/SkBreadcrumbSeparator.vue +38 -0
  69. package/src/components/Breadcrumbs/SkBreadcrumbs.vue +93 -0
  70. package/src/components/Breadcrumbs/index.ts +10 -0
  71. package/src/components/Breadcrumbs/types.ts +36 -0
  72. package/src/components/Button/SkButton.vue +148 -0
  73. package/src/components/Button/types.ts +21 -0
  74. package/src/components/Card/SkCard.vue +144 -0
  75. package/src/components/Card/types.ts +12 -0
  76. package/src/components/Checkbox/SkCheckbox.vue +136 -0
  77. package/src/components/Checkbox/index.ts +8 -0
  78. package/src/components/Checkbox/types.ts +10 -0
  79. package/src/components/Collapsible/SkCollapsible.vue +159 -0
  80. package/src/components/Collapsible/index.ts +2 -0
  81. package/src/components/Collapsible/types.ts +8 -0
  82. package/src/components/Divider/SkDivider.vue +63 -0
  83. package/src/components/Divider/types.ts +15 -0
  84. package/src/components/Dropdown/SkDropdown.vue +150 -0
  85. package/src/components/Dropdown/SkDropdownMenuItem.vue +58 -0
  86. package/src/components/Dropdown/SkDropdownMenuSeparator.vue +26 -0
  87. package/src/components/Dropdown/SkDropdownSubmenu.vue +107 -0
  88. package/src/components/Dropdown/index.ts +11 -0
  89. package/src/components/Dropdown/types.ts +11 -0
  90. package/src/components/Field/SkField.vue +152 -0
  91. package/src/components/Field/index.ts +8 -0
  92. package/src/components/Field/types.ts +7 -0
  93. package/src/components/Group/SkGroup.vue +52 -0
  94. package/src/components/Group/types.ts +10 -0
  95. package/src/components/Input/SkInput.vue +117 -0
  96. package/src/components/Input/index.ts +8 -0
  97. package/src/components/Input/types.ts +11 -0
  98. package/src/components/Listbox/SkListbox.vue +164 -0
  99. package/src/components/Listbox/SkListboxItem.vue +68 -0
  100. package/src/components/Listbox/SkListboxSeparator.vue +26 -0
  101. package/src/components/Listbox/index.ts +10 -0
  102. package/src/components/Listbox/types.ts +10 -0
  103. package/src/components/Modal/SkModal.vue +231 -0
  104. package/src/components/Modal/index.ts +8 -0
  105. package/src/components/Modal/types.ts +12 -0
  106. package/src/components/NavBar/SkNavBar.vue +83 -0
  107. package/src/components/NavBar/index.ts +8 -0
  108. package/src/components/NavBar/types.ts +15 -0
  109. package/src/components/NumberInput/SkNumberInput.vue +168 -0
  110. package/src/components/NumberInput/index.ts +8 -0
  111. package/src/components/NumberInput/types.ts +10 -0
  112. package/src/components/Page/SkPage.vue +94 -0
  113. package/src/components/Page/index.ts +8 -0
  114. package/src/components/Page/types.ts +21 -0
  115. package/src/components/Pagination/SkPagination.vue +185 -0
  116. package/src/components/Pagination/SkPaginationItem.vue +107 -0
  117. package/src/components/Pagination/index.ts +9 -0
  118. package/src/components/Pagination/types.ts +40 -0
  119. package/src/components/Panel/SkPanel.vue +96 -0
  120. package/src/components/Panel/types.ts +15 -0
  121. package/src/components/Popover/SkPopover.vue +185 -0
  122. package/src/components/Popover/index.ts +8 -0
  123. package/src/components/Popover/types.ts +11 -0
  124. package/src/components/Progress/SkProgress.vue +144 -0
  125. package/src/components/Progress/index.ts +8 -0
  126. package/src/components/Progress/types.ts +34 -0
  127. package/src/components/Radio/SkRadio.vue +110 -0
  128. package/src/components/Radio/SkRadioGroup.vue +92 -0
  129. package/src/components/Radio/index.ts +9 -0
  130. package/src/components/Radio/types.ts +11 -0
  131. package/src/components/Sidebar/README.md +405 -0
  132. package/src/components/Sidebar/SkSidebar.vue +88 -0
  133. package/src/components/Sidebar/SkSidebarItem.vue +58 -0
  134. package/src/components/Sidebar/SkSidebarSection.vue +40 -0
  135. package/src/components/Sidebar/types.ts +3 -0
  136. package/src/components/Skeleton/SkSkeleton.vue +171 -0
  137. package/src/components/Skeleton/index.ts +8 -0
  138. package/src/components/Skeleton/types.ts +31 -0
  139. package/src/components/Slider/SkSlider.vue +165 -0
  140. package/src/components/Slider/index.ts +8 -0
  141. package/src/components/Slider/types.ts +44 -0
  142. package/src/components/Spinner/SkSpinner.vue +105 -0
  143. package/src/components/Spinner/index.ts +8 -0
  144. package/src/components/Spinner/types.ts +28 -0
  145. package/src/components/Switch/SkSwitch.vue +215 -0
  146. package/src/components/Switch/index.ts +8 -0
  147. package/src/components/Switch/types.ts +12 -0
  148. package/src/components/Table/SkTable.vue +109 -0
  149. package/src/components/Table/index.ts +2 -0
  150. package/src/components/Table/types.ts +15 -0
  151. package/src/components/Tabs/README.md +331 -0
  152. package/src/components/Tabs/SkTab.vue +84 -0
  153. package/src/components/Tabs/SkTabList.vue +62 -0
  154. package/src/components/Tabs/SkTabPanel.vue +47 -0
  155. package/src/components/Tabs/SkTabPanels.vue +23 -0
  156. package/src/components/Tabs/SkTabs.vue +124 -0
  157. package/src/components/Tabs/types.ts +21 -0
  158. package/src/components/Tag/SkTag.vue +129 -0
  159. package/src/components/Tag/types.ts +15 -0
  160. package/src/components/TagsInput/SkTagsInput.vue +184 -0
  161. package/src/components/TagsInput/index.ts +8 -0
  162. package/src/components/TagsInput/types.ts +10 -0
  163. package/src/components/Textarea/SkTextarea.vue +117 -0
  164. package/src/components/Textarea/index.ts +8 -0
  165. package/src/components/Textarea/types.ts +10 -0
  166. package/src/components/Theme/SkTheme.vue +47 -0
  167. package/src/components/Theme/types.ts +17 -0
  168. package/src/components/Theme/useTheme.ts +131 -0
  169. package/src/components/Toast/SkToast.vue +156 -0
  170. package/src/components/Toast/SkToastProvider.vue +180 -0
  171. package/src/components/Toast/index.ts +15 -0
  172. package/src/components/Toast/types.ts +63 -0
  173. package/src/components/Toast/useToast.ts +78 -0
  174. package/src/components/Tooltip/SkTooltip.vue +162 -0
  175. package/src/components/Tooltip/SkTooltipProvider.vue +114 -0
  176. package/src/components/Tooltip/index.ts +9 -0
  177. package/src/components/Tooltip/types.ts +13 -0
  178. package/src/composables/useCustomColors.test.ts +505 -0
  179. package/src/composables/useCustomColors.ts +124 -0
  180. package/src/composables/usePortalContext.test.ts +402 -0
  181. package/src/composables/usePortalContext.ts +95 -0
  182. package/src/global.d.ts +76 -0
  183. package/src/index.ts +259 -0
  184. package/src/styles/_scrollbar.scss +100 -0
  185. package/src/styles/base/_fonts.scss +105 -0
  186. package/src/styles/base/_global.scss +47 -0
  187. package/src/styles/base/_index.scss +24 -0
  188. package/src/styles/base/_reset.scss +11 -0
  189. package/src/styles/base/_typography.scss +178 -0
  190. package/src/styles/components/_accordion.scss +250 -0
  191. package/src/styles/components/_alert.scss +239 -0
  192. package/src/styles/components/_avatar.scss +133 -0
  193. package/src/styles/components/_breadcrumbs.scss +137 -0
  194. package/src/styles/components/_button.scss +731 -0
  195. package/src/styles/components/_card.scss +141 -0
  196. package/src/styles/components/_checkbox.scss +232 -0
  197. package/src/styles/components/_collapsible.scss +158 -0
  198. package/src/styles/components/_divider.scss +121 -0
  199. package/src/styles/components/_field.scss +87 -0
  200. package/src/styles/components/_group.scss +138 -0
  201. package/src/styles/components/_index.scss +46 -0
  202. package/src/styles/components/_input.scss +205 -0
  203. package/src/styles/components/_listbox.scss +453 -0
  204. package/src/styles/components/_menu.scss +216 -0
  205. package/src/styles/components/_modal.scss +329 -0
  206. package/src/styles/components/_navbar.scss +258 -0
  207. package/src/styles/components/_number-input.scss +352 -0
  208. package/src/styles/components/_page.scss +98 -0
  209. package/src/styles/components/_pagination.scss +411 -0
  210. package/src/styles/components/_panel.scss +281 -0
  211. package/src/styles/components/_popover.scss +258 -0
  212. package/src/styles/components/_progress.scss +280 -0
  213. package/src/styles/components/_radio.scss +255 -0
  214. package/src/styles/components/_sidebar.scss +92 -0
  215. package/src/styles/components/_skeleton.scss +138 -0
  216. package/src/styles/components/_slider.scss +262 -0
  217. package/src/styles/components/_spinner.scss +331 -0
  218. package/src/styles/components/_switch.scss +370 -0
  219. package/src/styles/components/_table.scss +405 -0
  220. package/src/styles/components/_tabs.scss +486 -0
  221. package/src/styles/components/_tag.scss +425 -0
  222. package/src/styles/components/_tags-input.scss +279 -0
  223. package/src/styles/components/_textarea.scss +208 -0
  224. package/src/styles/components/_toast.scss +331 -0
  225. package/src/styles/components/_tooltip.scss +206 -0
  226. package/src/styles/fonts/Titillium_Web/OFL.txt +93 -0
  227. package/src/styles/fonts/Titillium_Web/TitilliumWeb-Black.ttf +0 -0
  228. package/src/styles/fonts/Titillium_Web/TitilliumWeb-Bold.ttf +0 -0
  229. package/src/styles/fonts/Titillium_Web/TitilliumWeb-BoldItalic.ttf +0 -0
  230. package/src/styles/fonts/Titillium_Web/TitilliumWeb-ExtraLight.ttf +0 -0
  231. package/src/styles/fonts/Titillium_Web/TitilliumWeb-ExtraLightItalic.ttf +0 -0
  232. package/src/styles/fonts/Titillium_Web/TitilliumWeb-Italic.ttf +0 -0
  233. package/src/styles/fonts/Titillium_Web/TitilliumWeb-Light.ttf +0 -0
  234. package/src/styles/fonts/Titillium_Web/TitilliumWeb-LightItalic.ttf +0 -0
  235. package/src/styles/fonts/Titillium_Web/TitilliumWeb-Regular.ttf +0 -0
  236. package/src/styles/fonts/Titillium_Web/TitilliumWeb-SemiBold.ttf +0 -0
  237. package/src/styles/fonts/Titillium_Web/TitilliumWeb-SemiBoldItalic.ttf +0 -0
  238. package/src/styles/index.scss +17 -0
  239. package/src/styles/mixins/_cut-border.scss +254 -0
  240. package/src/styles/mixins/_index.scss +7 -0
  241. package/src/styles/theme/_variables.scss +42 -0
  242. package/src/styles/themes/README.md +127 -0
  243. package/src/styles/themes/_colorful.scss +58 -0
  244. package/src/styles/themes/_greyscale.scss +58 -0
  245. package/src/styles/themes/index.scss +9 -0
  246. package/src/styles/tokens/README.md +268 -0
  247. package/src/styles/tokens/_foundation-borders.scss +26 -0
  248. package/src/styles/tokens/_foundation-colors.scss +169 -0
  249. package/src/styles/tokens/_foundation-glow.scss +36 -0
  250. package/src/styles/tokens/_foundation-radius.scss +53 -0
  251. package/src/styles/tokens/_foundation-scrollbar.scss +31 -0
  252. package/src/styles/tokens/_foundation-shadows.scss +37 -0
  253. package/src/styles/tokens/_foundation-space.scss +36 -0
  254. package/src/styles/tokens/_foundation-transitions.scss +37 -0
  255. package/src/styles/tokens/_foundation-typography.scss +58 -0
  256. package/src/styles/tokens/_semantic-color-kinds.scss +112 -0
  257. package/src/styles/tokens/_semantic-colors.scss +10 -0
  258. package/src/styles/tokens/_semantic-interactive.scss +29 -0
  259. package/src/styles/tokens/_semantic-scrollbar.scss +48 -0
  260. package/src/styles/tokens/_semantic-surfaces.scss +36 -0
  261. package/src/styles/tokens/index.scss +38 -0
  262. package/src/styles/tokens.scss +268 -0
  263. package/src/styles/utilities/_index.scss +9 -0
  264. package/src/styles/utilities/_typography.scss +121 -0
  265. package/src/types.ts +50 -0
  266. package/web-types.json +3524 -0
@@ -0,0 +1,127 @@
1
+ # SleekSpace UI Themes
2
+
3
+ This directory contains all theme definitions for the design system. Each theme maps foundation color primitives to semantic color roles (kinds).
4
+
5
+ ## Current Themes
6
+
7
+ - **Greyscale** (`_greyscale.scss`) - Default theme with gray neutral, blue primary, orange accent
8
+ - **Colorful** (`_colorful.scss`) - Vibrant theme with blue neutral, orange primary, blue accent
9
+
10
+ ## Adding a New Theme
11
+
12
+ To create a new theme:
13
+
14
+ 1. **Create a new theme file** in this directory: `_mytheme.scss`
15
+
16
+ 2. **Define the theme** using the `[data-scheme="mytheme"]` selector:
17
+
18
+ ```scss
19
+ /**
20
+ * My Theme
21
+ *
22
+ * Description of your theme's color personality.
23
+ */
24
+
25
+ [data-scheme="mytheme"]
26
+ {
27
+ /* Neutral Kind - Used for default UI elements */
28
+ --sk-neutral-base: var(--sk-color-gray-50);
29
+ --sk-neutral-hover: color-mix(in oklch, var(--sk-neutral-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
30
+ --sk-neutral-active: color-mix(in oklch, var(--sk-neutral-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
31
+ --sk-neutral-text: oklch(1 0 0);
32
+ --sk-neutral-text-contrast: var(--sk-color-gray-95);
33
+
34
+ /* Primary Kind - Main brand color for primary actions */
35
+ --sk-primary-base: var(--sk-color-blue-50);
36
+ --sk-primary-hover: color-mix(in oklch, var(--sk-primary-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
37
+ --sk-primary-active: color-mix(in oklch, var(--sk-primary-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
38
+ --sk-primary-text: oklch(1 0 0);
39
+ --sk-primary-text-contrast: var(--sk-color-gray-95);
40
+
41
+ /* Accent Kind - Secondary emphasis */
42
+ --sk-accent-base: var(--sk-color-orange-50);
43
+ --sk-accent-hover: color-mix(in oklch, var(--sk-accent-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
44
+ --sk-accent-active: color-mix(in oklch, var(--sk-accent-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
45
+ --sk-accent-text: oklch(1 0 0);
46
+ --sk-accent-text-contrast: var(--sk-color-gray-95);
47
+
48
+ /* Success Kind - Success states and positive actions */
49
+ --sk-success-base: var(--sk-color-green-50);
50
+ --sk-success-hover: color-mix(in oklch, var(--sk-success-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
51
+ --sk-success-active: color-mix(in oklch, var(--sk-success-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
52
+ --sk-success-text: oklch(1 0 0);
53
+ --sk-success-text-contrast: var(--sk-color-gray-95);
54
+
55
+ /* Warning Kind - Warning states and caution */
56
+ --sk-warning-base: var(--sk-color-yellow-50);
57
+ --sk-warning-hover: color-mix(in oklch, var(--sk-warning-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
58
+ --sk-warning-active: color-mix(in oklch, var(--sk-warning-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
59
+ --sk-warning-text: oklch(1 0 0);
60
+ --sk-warning-text-contrast: var(--sk-color-gray-95);
61
+
62
+ /* Danger Kind - Error states and destructive actions */
63
+ --sk-danger-base: var(--sk-color-red-50);
64
+ --sk-danger-hover: color-mix(in oklch, var(--sk-danger-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
65
+ --sk-danger-active: color-mix(in oklch, var(--sk-danger-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
66
+ --sk-danger-text: oklch(1 0 0);
67
+ --sk-danger-text-contrast: var(--sk-color-gray-95);
68
+
69
+ /* Info Kind - Informational content */
70
+ --sk-info-base: var(--sk-color-cyan-50);
71
+ --sk-info-hover: color-mix(in oklch, var(--sk-info-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
72
+ --sk-info-active: color-mix(in oklch, var(--sk-info-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
73
+ --sk-info-text: oklch(1 0 0);
74
+ --sk-info-text-contrast: var(--sk-color-gray-95);
75
+ }
76
+ ```
77
+
78
+ 3. **Import your theme** in `index.scss`:
79
+
80
+ ```scss
81
+ @forward 'greyscale';
82
+ @forward 'colorful';
83
+ @forward 'mytheme'; // Add your theme
84
+ ```
85
+
86
+ 4. **Add the TypeScript type** in `src/components/Theme/types.ts`:
87
+
88
+ ```typescript
89
+ export type SkThemeName = 'greyscale' | 'colorful' | 'mytheme';
90
+ ```
91
+
92
+ 5. **Use your theme**:
93
+
94
+ ```vue
95
+ <SkTheme theme="mytheme">
96
+ <YourApp />
97
+ </SkTheme>
98
+ ```
99
+
100
+ ## Available Foundation Colors
101
+
102
+ Each color family has 11 shades (05, 10, 20, 30, 40, 50, 60, 70, 80, 90, 95):
103
+
104
+ - `--sk-color-gray-XX` - Gray scale
105
+ - `--sk-color-blue-XX` - Neon Blue
106
+ - `--sk-color-red-XX` - Red
107
+ - `--sk-color-orange-XX` - Neon Orange
108
+ - `--sk-color-yellow-XX` - Yellow
109
+ - `--sk-color-green-XX` - Neon Green
110
+ - `--sk-color-mint-XX` - Neon Mint
111
+ - `--sk-color-cyan-XX` - Light Blue/Cyan
112
+ - `--sk-color-purple-XX` - Neon Purple
113
+ - `--sk-color-pink-XX` - Neon Pink
114
+
115
+ Shade `50` is typically the most vibrant/saturated version of each color.
116
+
117
+ ## Token Structure
118
+
119
+ Each kind requires 5 tokens:
120
+
121
+ - **`-base`**: The main color (maps to a foundation color)
122
+ - **`-hover`**: Hover state (derived via `color-mix()`)
123
+ - **`-active`**: Active/pressed state (derived via `color-mix()`)
124
+ - **`-text`**: Text color on colored backgrounds (usually white)
125
+ - **`-text-contrast`**: Alternative text color for special cases
126
+
127
+ The hover/active states use `color-mix()` to automatically lighten the base color, ensuring consistency across all themes.
@@ -0,0 +1,58 @@
1
+ /**
2
+ * Colorful Theme
3
+ *
4
+ * Vibrant theme with blue neutral colors and orange primary.
5
+ * This swaps the primary/neutral colors from greyscale for a bolder look.
6
+ */
7
+
8
+ [data-scheme="colorful"]
9
+ {
10
+ /* Neutral Kind */
11
+ --sk-neutral-base: var(--sk-color-blue-70);
12
+ --sk-neutral-hover: color-mix(in oklch, var(--sk-neutral-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
13
+ --sk-neutral-active: color-mix(in oklch, var(--sk-neutral-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
14
+ --sk-neutral-text: oklch(1 0 0);
15
+ --sk-neutral-text-contrast: var(--sk-color-gray-95);
16
+
17
+ /* Primary Kind */
18
+ --sk-primary-base: var(--sk-color-orange-50);
19
+ --sk-primary-hover: color-mix(in oklch, var(--sk-primary-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
20
+ --sk-primary-active: color-mix(in oklch, var(--sk-primary-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
21
+ --sk-primary-text: oklch(1 0 0);
22
+ --sk-primary-text-contrast: var(--sk-color-gray-95);
23
+
24
+ /* Accent Kind */
25
+ --sk-accent-base: var(--sk-color-blue-50);
26
+ --sk-accent-hover: color-mix(in oklch, var(--sk-accent-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
27
+ --sk-accent-active: color-mix(in oklch, var(--sk-accent-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
28
+ --sk-accent-text: oklch(1 0 0);
29
+ --sk-accent-text-contrast: var(--sk-color-gray-95);
30
+
31
+ /* Success Kind */
32
+ --sk-success-base: var(--sk-color-green-50);
33
+ --sk-success-hover: color-mix(in oklch, var(--sk-success-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
34
+ --sk-success-active: color-mix(in oklch, var(--sk-success-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
35
+ --sk-success-text: oklch(1 0 0);
36
+ --sk-success-text-contrast: var(--sk-color-gray-95);
37
+
38
+ /* Warning Kind */
39
+ --sk-warning-base: var(--sk-color-yellow-50);
40
+ --sk-warning-hover: color-mix(in oklch, var(--sk-warning-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
41
+ --sk-warning-active: color-mix(in oklch, var(--sk-warning-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
42
+ --sk-warning-text: oklch(1 0 0);
43
+ --sk-warning-text-contrast: var(--sk-color-gray-95);
44
+
45
+ /* Danger Kind */
46
+ --sk-danger-base: var(--sk-color-red-50);
47
+ --sk-danger-hover: color-mix(in oklch, var(--sk-danger-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
48
+ --sk-danger-active: color-mix(in oklch, var(--sk-danger-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
49
+ --sk-danger-text: oklch(1 0 0);
50
+ --sk-danger-text-contrast: var(--sk-color-gray-95);
51
+
52
+ /* Info Kind */
53
+ --sk-info-base: var(--sk-color-cyan-50);
54
+ --sk-info-hover: color-mix(in oklch, var(--sk-info-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
55
+ --sk-info-active: color-mix(in oklch, var(--sk-info-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
56
+ --sk-info-text: oklch(1 0 0);
57
+ --sk-info-text-contrast: var(--sk-color-gray-95);
58
+ }
@@ -0,0 +1,58 @@
1
+ /**
2
+ * Greyscale Theme
3
+ *
4
+ * Reference theme with gray neutral colors and blue primary.
5
+ * This is the default, more subdued theme.
6
+ */
7
+
8
+ [data-scheme="greyscale"]
9
+ {
10
+ /* Neutral Kind */
11
+ --sk-neutral-base: var(--sk-color-gray-50);
12
+ --sk-neutral-hover: color-mix(in oklch, var(--sk-neutral-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
13
+ --sk-neutral-active: color-mix(in oklch, var(--sk-neutral-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
14
+ --sk-neutral-text: oklch(1 0 0);
15
+ --sk-neutral-text-contrast: var(--sk-color-gray-95);
16
+
17
+ /* Primary Kind */
18
+ --sk-primary-base: var(--sk-color-blue-50);
19
+ --sk-primary-hover: color-mix(in oklch, var(--sk-primary-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
20
+ --sk-primary-active: color-mix(in oklch, var(--sk-primary-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
21
+ --sk-primary-text: oklch(1 0 0);
22
+ --sk-primary-text-contrast: var(--sk-color-gray-95);
23
+
24
+ /* Accent Kind */
25
+ --sk-accent-base: var(--sk-color-orange-50);
26
+ --sk-accent-hover: color-mix(in oklch, var(--sk-accent-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
27
+ --sk-accent-active: color-mix(in oklch, var(--sk-accent-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
28
+ --sk-accent-text: oklch(1 0 0);
29
+ --sk-accent-text-contrast: var(--sk-color-gray-95);
30
+
31
+ /* Success Kind */
32
+ --sk-success-base: var(--sk-color-green-50);
33
+ --sk-success-hover: color-mix(in oklch, var(--sk-success-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
34
+ --sk-success-active: color-mix(in oklch, var(--sk-success-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
35
+ --sk-success-text: oklch(1 0 0);
36
+ --sk-success-text-contrast: var(--sk-color-gray-95);
37
+
38
+ /* Warning Kind */
39
+ --sk-warning-base: var(--sk-color-yellow-50);
40
+ --sk-warning-hover: color-mix(in oklch, var(--sk-warning-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
41
+ --sk-warning-active: color-mix(in oklch, var(--sk-warning-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
42
+ --sk-warning-text: oklch(1 0 0);
43
+ --sk-warning-text-contrast: var(--sk-color-gray-95);
44
+
45
+ /* Danger Kind */
46
+ --sk-danger-base: var(--sk-color-red-50);
47
+ --sk-danger-hover: color-mix(in oklch, var(--sk-danger-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
48
+ --sk-danger-active: color-mix(in oklch, var(--sk-danger-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
49
+ --sk-danger-text: oklch(1 0 0);
50
+ --sk-danger-text-contrast: var(--sk-color-gray-95);
51
+
52
+ /* Info Kind */
53
+ --sk-info-base: var(--sk-color-cyan-50);
54
+ --sk-info-hover: color-mix(in oklch, var(--sk-info-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate));
55
+ --sk-info-active: color-mix(in oklch, var(--sk-info-base), var(--sk-color-gray-10) var(--sk-mix-amount-strong));
56
+ --sk-info-text: oklch(1 0 0);
57
+ --sk-info-text-contrast: var(--sk-color-gray-95);
58
+ }
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Themes Index
3
+ *
4
+ * All theme definitions for the SleekSpace UI design system.
5
+ * Each theme defines semantic color mappings for the 7 kinds.
6
+ */
7
+
8
+ @forward 'greyscale';
9
+ @forward 'colorful';
@@ -0,0 +1,268 @@
1
+ # SleekSpace Design Tokens
2
+
3
+ This directory contains all design tokens for the SleekSpace UI component library, organized in a three-tier hierarchy.
4
+
5
+ ## Token Hierarchy
6
+
7
+ ```
8
+ Foundation Tokens (global primitives)
9
+
10
+ Semantic Tokens (contextual meanings)
11
+
12
+ Component Tokens (component-specific)
13
+ ```
14
+
15
+ ### Foundation Tokens
16
+
17
+ Foundation tokens are the lowest-level design primitives. These are global values that all other tokens derive from:
18
+
19
+ - **Colors** (`_foundation-colors.scss`): Color primitives (10 hues × 11 shades), opacity scale, color mixing percentages
20
+ - **Space** (`_foundation-space.scss`): Spacing scale from 3xs to 4xl with global scale multiplier
21
+ - **Radius** (`_foundation-radius.scss`): Border radius scale and radius factors for calculations
22
+ - **Borders** (`_foundation-borders.scss`): Border widths and styles
23
+ - **Shadows** (`_foundation-shadows.scss`): Elevation shadows for creating depth
24
+ - **Glow** (`_foundation-glow.scss`): Glow effects for neon aesthetic (SleekSpace-specific)
25
+ - **Transitions** (`_foundation-transitions.scss`): Animation timing and easing functions
26
+ - **Typography** (`_foundation-typography.scss`): Font families, sizes, weights, line heights
27
+
28
+ ### Semantic Tokens
29
+
30
+ Semantic tokens provide contextual meaning by referencing foundation tokens:
31
+
32
+ - **Colors** (`_semantic-colors.scss`): Kind-based colors (neutral, primary, secondary, success, warning, danger, info) with base/hover/active/text variants for each scheme (greyscale, colorful)
33
+ - **Surfaces** (`_semantic-surfaces.scss`): Background and text colors for surfaces
34
+ - **Interactive** (`_semantic-interactive.scss`): Focus rings and selection states
35
+
36
+ ### Component Tokens
37
+
38
+ Component-specific tokens are defined inline within component stylesheets. Only create component tokens when:
39
+ 1. The value doesn't fit existing foundation/semantic tokens
40
+ 2. The behavior is unique to that component
41
+ 3. Independent control is needed
42
+
43
+ ## Naming Convention
44
+
45
+ All tokens follow the pattern: `--sk-{category}-{subcategory}-{variant/size}`
46
+
47
+ Examples:
48
+ - `--sk-color-blue-50`
49
+ - `--sk-space-md`
50
+ - `--sk-radius-lg`
51
+ - `--sk-transition-fast`
52
+ - `--sk-primary-base`
53
+ - `--sk-primary-hover`
54
+
55
+ ## Adding New Components
56
+
57
+ When creating a new component, follow these guidelines:
58
+
59
+ ### 1. Use Semantic Tokens for Colors
60
+
61
+ **Do this:**
62
+ ```scss
63
+ .sk-new-component {
64
+ background-color: var(--sk-primary-base);
65
+ color: var(--sk-primary-text);
66
+
67
+ &:hover {
68
+ background-color: var(--sk-primary-hover);
69
+ }
70
+ }
71
+ ```
72
+
73
+ **Not this:**
74
+ ```scss
75
+ .sk-new-component {
76
+ background-color: var(--sk-color-blue-50); // ❌ Don't use color primitives directly
77
+ color: white; // ❌ Don't use hard-coded values
78
+ }
79
+ ```
80
+
81
+ ### 2. Use Foundation Tokens for Spacing/Radius/Borders
82
+
83
+ **Do this:**
84
+ ```scss
85
+ .sk-new-component {
86
+ padding: var(--sk-space-md);
87
+ gap: var(--sk-space-sm);
88
+ border-radius: var(--sk-radius-md);
89
+ border-width: var(--sk-border-width-thin);
90
+ }
91
+ ```
92
+
93
+ **Not this:**
94
+ ```scss
95
+ .sk-new-component {
96
+ padding: 16px; // ❌ Don't use hard-coded values
97
+ gap: 12px; // ❌ Use tokens instead
98
+ border-radius: 8px; // ❌ Use tokens instead
99
+ }
100
+ ```
101
+
102
+ ### 3. Use Transition Tokens
103
+
104
+ **Do this:**
105
+ ```scss
106
+ .sk-new-component {
107
+ transition: var(--sk-transition-fast);
108
+ // Or more specific:
109
+ transition:
110
+ color var(--sk-transition-duration-fast) var(--sk-transition-easing-ease-out),
111
+ background-color var(--sk-transition-duration-fast) var(--sk-transition-easing-ease-out);
112
+ }
113
+ ```
114
+
115
+ ### 4. Use Opacity Tokens
116
+
117
+ **Do this:**
118
+ ```scss
119
+ .sk-new-component {
120
+ background-color: oklch(from var(--sk-primary-base) l c h / var(--sk-opacity-moderate));
121
+ }
122
+ ```
123
+
124
+ **Not this:**
125
+ ```scss
126
+ .sk-new-component {
127
+ background-color: oklch(from var(--sk-primary-base) l c h / 0.2); // ❌ Use tokens
128
+ }
129
+ ```
130
+
131
+ ### 5. Use Glow Tokens for Neon Effects
132
+
133
+ **Do this:**
134
+ ```scss
135
+ .sk-new-component {
136
+ &.variant-neon:hover {
137
+ box-shadow:
138
+ 0 0 var(--sk-glow-blur-md) var(--sk-glow-spread-sm)
139
+ color-mix(
140
+ in oklch,
141
+ var(--sk-primary-base),
142
+ transparent calc(100% - (var(--sk-glow-intensity-moderate) * 100%))
143
+ );
144
+ }
145
+ }
146
+ ```
147
+
148
+ ## Common Patterns
149
+
150
+ ### Kind-Based Component Styling
151
+
152
+ Use SCSS mixins to generate styles for each kind:
153
+
154
+ ```scss
155
+ @mixin component-kind($kind) {
156
+ &.sk-#{$kind} {
157
+ --component-color-base: var(--sk-#{$kind}-base);
158
+ --component-text: var(--sk-#{$kind}-text);
159
+
160
+ background-color: var(--component-color-base);
161
+ color: var(--component-text);
162
+
163
+ &:hover {
164
+ background-color: var(--sk-#{$kind}-hover);
165
+ }
166
+ }
167
+ }
168
+
169
+ .sk-new-component {
170
+ @each $kind in $kinds {
171
+ @include component-kind($kind);
172
+ }
173
+ }
174
+ ```
175
+
176
+ ### Size-Based Component Styling
177
+
178
+ ```scss
179
+ .sk-new-component {
180
+ height: 40px; // base size
181
+ padding: var(--sk-space-md);
182
+
183
+ &.sk-sm {
184
+ height: 32px;
185
+ padding: var(--sk-space-sm);
186
+ }
187
+
188
+ &.sk-lg {
189
+ height: 48px;
190
+ padding: var(--sk-space-lg);
191
+ }
192
+ }
193
+ ```
194
+
195
+ ### Color Derivation with color-mix()
196
+
197
+ ```scss
198
+ // Darken a color
199
+ color-mix(in oklch, var(--sk-primary-base), var(--sk-color-gray-10) var(--sk-mix-amount-moderate))
200
+
201
+ // Lighten a color
202
+ color-mix(in oklch, var(--sk-primary-base), var(--sk-color-gray-95) var(--sk-mix-amount-light))
203
+
204
+ // Add transparency
205
+ oklch(from var(--sk-primary-base) l c h / var(--sk-opacity-moderate))
206
+ ```
207
+
208
+ ## Global Customization
209
+
210
+ Users can customize the entire system using scale multipliers:
211
+
212
+ ```css
213
+ :root {
214
+ --sk-space-scale: 1.2; /* 20% larger spacing */
215
+ --sk-radius-scale: 1.5; /* 50% rounder corners */
216
+ --sk-font-size-scale: 0.9; /* 10% smaller text */
217
+ }
218
+ ```
219
+
220
+ ## Compatibility Layer
221
+
222
+ The `_compat-layer.scss` file provides backwards compatibility for old token names. This allows existing components to continue working while we migrate to the new naming conventions.
223
+
224
+ **TODO**: Remove `_compat-layer.scss` once all components are migrated to new token names.
225
+
226
+ ## Token Files
227
+
228
+ | File | Purpose | Token Count |
229
+ |------|---------|-------------|
230
+ | `_foundation-colors.scss` | Color primitives, opacity, mixing | ~123 |
231
+ | `_foundation-space.scss` | Spacing scale | 11 |
232
+ | `_foundation-radius.scss` | Border radius scale + factors | 13 |
233
+ | `_foundation-borders.scss` | Border widths + styles | 7 |
234
+ | `_foundation-shadows.scss` | Elevation shadows | 7 |
235
+ | `_foundation-glow.scss` | Glow effects | 9 |
236
+ | `_foundation-transitions.scss` | Animation timing | 11 |
237
+ | `_foundation-typography.scss` | Fonts and sizes | 22 |
238
+ | `_semantic-colors.scss` | Kind-based colors (2 schemes) | 70 |
239
+ | `_semantic-surfaces.scss` | Surface + text colors | 7 |
240
+ | `_semantic-interactive.scss` | Focus + selection | 6 |
241
+ | **Total** | | **~286** |
242
+
243
+ ## Color Schemes
244
+
245
+ The system supports multiple color schemes via `data-scheme` attribute:
246
+
247
+ - `greyscale` - Gray neutral with blue primary (reference theme)
248
+ - `colorful` - Blue neutral with orange primary
249
+
250
+ To add a new scheme, update `_semantic-colors.scss`:
251
+
252
+ ```scss
253
+ [data-scheme="my-new-scheme"] {
254
+ --sk-neutral-base: var(--sk-color-gray-50);
255
+ --sk-primary-base: var(--sk-color-purple-50);
256
+ // ... define all semantic color tokens
257
+ }
258
+ ```
259
+
260
+ ## Resources
261
+
262
+ - **Full Proposal**: See `/DESIGN_TOKENS_PROPOSAL.md` for complete design rationale and implementation plan
263
+ - **Web Awesome Inspiration**: https://webawesome.com/docs/tokens/
264
+ - **OKLCH Color Space**: https://oklch.com/
265
+
266
+ ## Questions?
267
+
268
+ If you have questions about the token system or need guidance on using tokens in your components, refer to the full proposal document or ask the team.
@@ -0,0 +1,26 @@
1
+ /**
2
+ * Foundation Tokens - Borders
3
+ *
4
+ * Border widths and styles for component outlines.
5
+ */
6
+
7
+ :root
8
+ {
9
+ /* ===================================================================
10
+ * Border Widths
11
+ * =================================================================== */
12
+
13
+ --sk-border-width-none: 0;
14
+ --sk-border-width-thin: 1px;
15
+ --sk-border-width-normal: 2px;
16
+ --sk-border-width-thick: 4px;
17
+ --sk-border-width-heavy: 6px;
18
+
19
+ /* ===================================================================
20
+ * Border Styles
21
+ * =================================================================== */
22
+
23
+ --sk-border-style-solid: solid;
24
+ --sk-border-style-dashed: dashed;
25
+ --sk-border-style-none: none;
26
+ }