@rolemodel/optics 2.1.2 → 2.1.3

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 (40) hide show
  1. package/.yarn/install-state.gz +0 -0
  2. package/.yarn/releases/yarn-4.8.1.cjs +935 -0
  3. package/.yarnrc.yml +1 -1
  4. package/dist/css/components/accordion.css +66 -0
  5. package/dist/css/components/alert.css +171 -0
  6. package/dist/css/components/avatar.css +95 -0
  7. package/dist/css/components/badge.css +73 -0
  8. package/dist/css/components/breadcrumbs.css +37 -0
  9. package/dist/css/components/button.css +273 -0
  10. package/dist/css/components/button_group.css +47 -0
  11. package/dist/css/components/card.css +62 -0
  12. package/dist/css/components/confirm-dialog.css +80 -0
  13. package/dist/css/components/divider.css +55 -0
  14. package/dist/css/components/form.css +360 -0
  15. package/dist/css/components/icon.css +121 -0
  16. package/dist/css/components/index.css +24 -0
  17. package/dist/css/components/modal.css +149 -0
  18. package/dist/css/components/navbar.css +60 -0
  19. package/dist/css/components/pagination.css +24 -0
  20. package/dist/css/components/side_panel.css +90 -0
  21. package/dist/css/components/sidebar.css +138 -0
  22. package/dist/css/components/spinner.css +52 -0
  23. package/dist/css/components/switch.css +107 -0
  24. package/dist/css/components/tab.css +76 -0
  25. package/dist/css/components/table.css +133 -0
  26. package/dist/css/components/tag.css +168 -0
  27. package/dist/css/components/text_pair.css +55 -0
  28. package/dist/css/components/tooltip.css +134 -0
  29. package/dist/css/core/base.css +95 -0
  30. package/dist/css/core/fonts/icon_fonts.css +8 -0
  31. package/dist/css/core/fonts/index.css +8 -0
  32. package/dist/css/core/fonts/text_fonts.css +16 -0
  33. package/dist/css/core/layout.css +43 -0
  34. package/dist/css/core/tokens/base_tokens.css +338 -0
  35. package/dist/css/core/tokens/index.css +2 -0
  36. package/dist/css/core/tokens/scale_color_tokens.css +1498 -0
  37. package/dist/css/core/utilities.css +429 -0
  38. package/dist/package.json +3 -3
  39. package/package.json +3 -3
  40. package/.yarn/releases/yarn-4.2.2.cjs +0 -894
@@ -0,0 +1,338 @@
1
+ :root {
2
+ /* Color HSLs
3
+ A theme comprised of a primary, neutral, warning, danger, info, and notice colors.
4
+ */
5
+
6
+ /* Basic Colors */
7
+
8
+ /**
9
+ * @tokens Basic Colors
10
+ * @presenter Color
11
+ */
12
+ --op-color-white: hsl(0deg 100% 100%);
13
+ --op-color-black: hsl(0deg 0% 0%);
14
+
15
+ /**
16
+ * @tokens Primary Colors
17
+ * @presenter Color
18
+ */
19
+ --op-color-primary-h: 216;
20
+ --op-color-primary-s: 58%;
21
+ --op-color-primary-l: 48%;
22
+
23
+ /**
24
+ * @tokens Neutral Colors
25
+ * @presenter Color
26
+ */
27
+ --op-color-neutral-h: var(--op-color-primary-h);
28
+ --op-color-neutral-s: 4%;
29
+ --op-color-neutral-l: var(--op-color-primary-l);
30
+
31
+ /**
32
+ * @tokens Alerts Warning Colors
33
+ * @presenter Color
34
+ */
35
+ --op-color-alerts-warning-h: 47;
36
+ --op-color-alerts-warning-s: 100%;
37
+ --op-color-alerts-warning-l: 61%;
38
+
39
+ /**
40
+ * @tokens Alerts Danger Colors
41
+ * @presenter Color
42
+ */
43
+ --op-color-alerts-danger-h: 0;
44
+ --op-color-alerts-danger-s: 99%;
45
+ --op-color-alerts-danger-l: 76%;
46
+
47
+ /**
48
+ * @tokens Alerts Info Colors
49
+ * @presenter Color
50
+ */
51
+ --op-color-alerts-info-h: 216;
52
+ --op-color-alerts-info-s: 58%;
53
+ --op-color-alerts-info-l: 48%;
54
+
55
+ /**
56
+ * @tokens Alerts Notice Colors
57
+ * @presenter Color
58
+ */
59
+ --op-color-alerts-notice-h: 130;
60
+ --op-color-alerts-notice-s: 61%;
61
+ --op-color-alerts-notice-l: 64%;
62
+
63
+ /**
64
+ * @tokens Opacities
65
+ * @presenter Opacity
66
+ */
67
+ --op-opacity-none: 0;
68
+ --op-opacity-overlay: 0.2;
69
+ --op-opacity-disabled: 0.4;
70
+ --op-opacity-half: 0.5;
71
+ --op-opacity-full: 1;
72
+
73
+ /*
74
+ Breakpoints
75
+ CSS does not support using variables within @media or @container queries. Environment variables are drafted but likely to not be implemented soon.
76
+ https://drafts.csswg.org/css-env-1/
77
+ https://bholmes.dev/blog/alternative-to-css-variable-media-queries/
78
+
79
+ Here is a list of breakpoints used throughout Optics:
80
+ */
81
+
82
+ /**
83
+ * @tokens Breakpoints
84
+ * @presenter Spacing
85
+ */
86
+ --op-breakpoint-x-small: 512px; /* vertical phone */
87
+ --op-breakpoint-small: 768px; /* vertical ipad */
88
+ --op-breakpoint-medium: 1024px; /* landscape ipad */
89
+ --op-breakpoint-large: 1280px; /* small laptop */
90
+ --op-breakpoint-x-large: 1440px; /* medium laptop */
91
+
92
+ /* Border */
93
+
94
+ /**
95
+ * @tokens Border Radius
96
+ * @presenter BorderRadius
97
+ */
98
+ --op-radius-small: 2px;
99
+ --op-radius-medium: 4px;
100
+ --op-radius-large: 8px;
101
+ --op-radius-x-large: 12px;
102
+ --op-radius-2x-large: 16px;
103
+ --op-radius-circle: 50%;
104
+ --op-radius-pill: 9999px;
105
+
106
+ /**
107
+ * @tokens Border Width
108
+ * @presenter Spacing
109
+ */
110
+ --op-border-width: 1px;
111
+ --op-border-width-large: 2px;
112
+ --op-border-width-x-large: 4px;
113
+
114
+ /**
115
+ * @tokens Border Color
116
+ * @presenter Color
117
+ */
118
+ --op-color-border: var(--op-color-neutral-plus-five);
119
+
120
+ /* E.G. box-shadow: var(--op-border-top) var(--op-color-border); */
121
+
122
+ /**
123
+ * @tokens Border Shadow
124
+ * @presenter Shadow
125
+ */
126
+ --op-border-none: 0 0 0 0;
127
+ --op-border-all: 0 0 0 var(--op-border-width);
128
+ --op-border-top: 0 calc(-1 * var(--op-border-width)) 0 0;
129
+ --op-border-right: var(--op-border-width) 0 0 0;
130
+ --op-border-bottom: 0 var(--op-border-width) 0 0;
131
+ --op-border-left: calc(-1 * var(--op-border-width)) 0 0 0;
132
+ --op-border-y: var(--op-border-top) var(--op-color-border), var(--op-border-bottom) var(--op-color-border);
133
+ --op-border-x: var(--op-border-left) var(--op-color-border), var(--op-border-right) var(--op-color-border);
134
+
135
+ /* Font */
136
+
137
+ /**
138
+ * @tokens Font Scale
139
+ * @presenter FontSize
140
+ */
141
+ --op-font-scale-unit: 1rem; /* 10px; */
142
+ --op-font-2x-small: calc(var(--op-font-scale-unit) * 1); /* 10px */
143
+ --op-font-x-small: calc(var(--op-font-scale-unit) * 1.2); /* 12px */
144
+ --op-font-small: calc(var(--op-font-scale-unit) * 1.4); /* 14px */
145
+ --op-font-medium: calc(var(--op-font-scale-unit) * 1.6); /* 16px */
146
+ --op-font-large: calc(var(--op-font-scale-unit) * 1.8); /* 18px */
147
+ --op-font-x-large: calc(var(--op-font-scale-unit) * 2); /* 20px */
148
+ --op-font-2x-large: calc(var(--op-font-scale-unit) * 2.4); /* 24px */
149
+ --op-font-3x-large: calc(var(--op-font-scale-unit) * 2.8); /* 28px */
150
+ --op-font-4x-large: calc(var(--op-font-scale-unit) * 3.2); /* 32px */
151
+ --op-font-5x-large: calc(var(--op-font-scale-unit) * 3.6); /* 36px */
152
+ --op-font-6x-large: calc(var(--op-font-scale-unit) * 4.8); /* 48px */
153
+
154
+ /**
155
+ * @tokens Font Weight
156
+ * @presenter FontWeight
157
+ */
158
+ --op-font-weight-thin: 100;
159
+ --op-font-weight-extra-light: 200;
160
+ --op-font-weight-light: 300;
161
+ --op-font-weight-normal: 400;
162
+ --op-font-weight-medium: 500;
163
+ --op-font-weight-semi-bold: 600;
164
+ --op-font-weight-bold: 700;
165
+ --op-font-weight-extra-bold: 800;
166
+ --op-font-weight-black: 900;
167
+
168
+ /**
169
+ * @tokens Font Family
170
+ * @presenter FontFamily
171
+ */
172
+ --op-font-family: 'Noto Sans', sans-serif;
173
+ --op-font-family-alt: 'Noto Serif', serif;
174
+
175
+ /* Text */
176
+
177
+ /**
178
+ * @tokens Line Height
179
+ * @presenter LineHeight
180
+ */
181
+ --op-line-height-none: 0;
182
+ --op-line-height-densest: 1;
183
+ --op-line-height-denser: 1.15;
184
+ --op-line-height-dense: 1.3;
185
+ --op-line-height-base: 1.5;
186
+ --op-line-height-loose: 1.6;
187
+ --op-line-height-looser: 1.7;
188
+ --op-line-height-loosest: 1.8;
189
+
190
+ /**
191
+ * @tokens Letter Spacing
192
+ * @presenter LetterSpacing
193
+ */
194
+ --op-letter-spacing-navigation: 0.01rem;
195
+ --op-letter-spacing-label: 0.04rem;
196
+
197
+ /* Transitions and Animations */
198
+
199
+ /**
200
+ * @tokens Transition
201
+ */
202
+ --op-transition-accordion: rotate 120ms ease-in;
203
+ --op-transition-accordion-content: height 300ms ease, content-visibility 300ms ease allow-discrete;
204
+ --op-transition-input: all 120ms ease-in;
205
+ --op-transition-sidebar: all 200ms ease-in-out;
206
+ --op-transition-modal: all 300ms ease-in;
207
+ --op-transition-panel: right 400ms ease-in;
208
+ --op-transition-tooltip: all 300ms ease-in 300ms;
209
+
210
+ /**
211
+ * @tokens Animation
212
+ * @presenter Animation
213
+ */
214
+ --op-animation-flash: rm-slide-in-out-flash 5s normal forwards;
215
+
216
+ /* Encoded Images */
217
+
218
+ /**
219
+ * @tokens Encoded Images
220
+ */
221
+ --op-encoded-images-dropdown-arrow-width: calc(
222
+ 1.2 * var(--op-space-scale-unit)
223
+ ); /* 12px No way to string interpolate */
224
+
225
+ --op-encoded-images-dropdown-arrow: url('data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTIiIGhlaWdodD0iOSIgdmlld0JveD0iMCAwIDEyIDkiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGQ9Ik02IDguMzc1MDFMMCAyLjM3NTAxTDEuNCAwLjk3NTAwNkw2IDUuNTc1MDFMMTAuNiAwLjk3NTAwNkwxMiAyLjM3NTAxTDYgOC4zNzUwMVoiIGZpbGw9IiMwQTBBMEIiLz4KPC9zdmc+Cg==');
226
+
227
+ /* Spacing */
228
+
229
+ /**
230
+ * @tokens Size Scale
231
+ * @presenter Spacing
232
+ */
233
+ --op-size-unit: 0.4rem; /* 4px */
234
+
235
+ /**
236
+ * @tokens Space Scale
237
+ * @presenter Spacing
238
+ */
239
+ --op-space-scale-unit: 1rem; /* 10px; */
240
+ --op-space-3x-small: calc(var(--op-space-scale-unit) * 0.2); /* 2px */
241
+ --op-space-2x-small: calc(var(--op-space-scale-unit) * 0.4); /* 4px */
242
+ --op-space-x-small: calc(var(--op-space-scale-unit) * 0.8); /* 8px */
243
+ --op-space-small: calc(var(--op-space-scale-unit) * 1.2); /* 12px */
244
+ --op-space-medium: calc(var(--op-space-scale-unit) * 1.6); /* 16px */
245
+ --op-space-large: calc(var(--op-space-scale-unit) * 2); /* 20px */
246
+ --op-space-x-large: calc(var(--op-space-scale-unit) * 2.4); /* 24px */
247
+ --op-space-2x-large: calc(var(--op-space-scale-unit) * 2.8); /* 28px */
248
+ --op-space-3x-large: calc(var(--op-space-scale-unit) * 4); /* 40px */
249
+ --op-space-4x-large: calc(var(--op-space-scale-unit) * 8); /* 80px */
250
+
251
+ /* Shadows */
252
+
253
+ /**
254
+ * @tokens Shadows
255
+ * @presenter Shadow
256
+ */
257
+ --op-shadow-x-small: 0 1px 2px hsl(0deg 0% 0% / 3%), 0 1px 3px hsl(0deg 0% 0% / 15%);
258
+ --op-shadow-small: 0 1px 2px hsl(0deg 0% 0% / 3%), 0 2px 6px hsl(0deg 0% 0% / 15%);
259
+ --op-shadow-medium: 0 4px 8px hsl(0deg 0% 0% / 15%), 0 1px 3px hsl(0deg 0% 0% / 3%);
260
+ --op-shadow-large: 0 6px 10px hsl(0deg 0% 0% / 15%), 0 2px 3px hsl(0deg 0% 0% / 3%);
261
+ --op-shadow-x-large: 0 8px 12px hsl(0deg 0% 0% / 15%), 0 4px 4px hsl(0deg 0% 0% / 3%);
262
+
263
+ /* Z Index */
264
+
265
+ /**
266
+ * @tokens Z-Index
267
+ */
268
+ --op-z-index-header: 500;
269
+ --op-z-index-footer: 500;
270
+ --op-z-index-sidebar: 700;
271
+ --op-z-index-dialog: 800;
272
+ --op-z-index-dialog-backdrop: 801;
273
+ --op-z-index-dialog-content: 802;
274
+ --op-z-index-dropdown: 900;
275
+ --op-z-index-alert-group: 950;
276
+ --op-z-index-tooltip: 1000;
277
+
278
+ /* Inputs */
279
+
280
+ /*
281
+ This should follow multiples of 4
282
+ https: //uxdesign.cc/baseline-grids-design-systems-ae23b5af8cec See example 8
283
+ */
284
+
285
+ /**
286
+ * @tokens Input Heights
287
+ * @presenter Spacing
288
+ */
289
+ --op-input-height-small: 2.8rem; /* 28px */
290
+ --op-input-height-medium: 3.6rem; /* 36px */
291
+ --op-input-height-large: 4rem; /* 40px */
292
+ --op-input-height-x-large: 8.4rem; /* 84px */
293
+
294
+ /**
295
+ * @tokens Input Focus
296
+ * @presenter Shadow
297
+ */
298
+ --op-input-inner-focus: inset 0 0 0 var(--op-border-width-large);
299
+ --op-input-outer-focus: 0 0 0 var(--op-border-width-x-large);
300
+ --op-input-focus-primary: var(--op-input-inner-focus) var(--op-color-primary-plus-two),
301
+ var(--op-input-outer-focus) var(--op-color-primary-plus-five);
302
+ --op-input-focus-neutral: var(--op-input-inner-focus) var(--op-color-neutral-plus-two),
303
+ var(--op-input-outer-focus) var(--op-color-neutral-plus-five);
304
+ --op-input-focus-danger: var(--op-input-inner-focus) var(--op-color-alerts-danger-plus-two),
305
+ var(--op-input-outer-focus) var(--op-color-alerts-danger-plus-five);
306
+ --op-input-focus-warning: var(--op-input-inner-focus) var(--op-color-alerts-warning-plus-two),
307
+ var(--op-input-outer-focus) var(--op-color-alerts-warning-plus-five);
308
+ --op-input-focus-info: var(--op-input-inner-focus) var(--op-color-alerts-info-plus-two),
309
+ var(--op-input-outer-focus) var(--op-color-alerts-info-plus-five);
310
+ --op-input-focus-notice: var(--op-input-inner-focus) var(--op-color-alerts-notice-plus-two),
311
+ var(--op-input-outer-focus) var(--op-color-alerts-notice-plus-five);
312
+ }
313
+
314
+ /* Animations */
315
+ @keyframes rm-slide-in-out-flash {
316
+ /*
317
+ If an duration of 5s is set:
318
+ Start off the Screen
319
+ */
320
+ 0% {
321
+ right: -100%;
322
+ }
323
+
324
+ /* Animate onto the screen for 0.5s */
325
+ 10% {
326
+ right: var(--op-space-large);
327
+ }
328
+
329
+ /* Stay on the screen for 3s */
330
+ 70% {
331
+ right: var(--op-space-large);
332
+ }
333
+
334
+ /* Animate off the screen for 1.5s */
335
+ 100% {
336
+ right: -100%;
337
+ }
338
+ }
@@ -0,0 +1,2 @@
1
+ @import 'base_tokens';
2
+ @import 'scale_color_tokens';