@accelint/design-toolkit 0.0.1 → 0.0.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.
- package/dist/components/accordion/index.d.ts +44 -0
- package/dist/components/accordion/index.js +2 -0
- package/dist/components/accordion/index.js.map +1 -0
- package/dist/components/avatar/index.d.ts +7 -0
- package/dist/components/avatar/index.js +1 -1
- package/dist/components/avatar/index.js.map +1 -1
- package/dist/components/badge/index.d.ts +3 -1
- package/dist/components/badge/index.js +1 -1
- package/dist/components/badge/index.js.map +1 -1
- package/dist/components/button/index.d.ts +8 -1
- package/dist/components/button/index.js +1 -1
- package/dist/components/button/index.js.map +1 -1
- package/dist/components/checkbox/index.d.ts +19 -0
- package/dist/components/checkbox/index.js +2 -0
- package/dist/components/checkbox/index.js.map +1 -0
- package/dist/components/chip/index.d.ts +57 -0
- package/dist/components/chip/index.js +2 -0
- package/dist/components/chip/index.js.map +1 -0
- package/dist/components/classification-badge/index.d.ts +3 -3
- package/dist/components/classification-badge/index.js +1 -1
- package/dist/components/classification-badge/index.js.map +1 -1
- package/dist/components/classification-banner/index.d.ts +2 -1
- package/dist/components/classification-banner/index.js +2 -2
- package/dist/components/classification-banner/index.js.map +1 -1
- package/dist/components/floating-button/index.js +1 -1
- package/dist/components/floating-button/index.js.map +1 -1
- package/dist/components/icon/index.d.ts +19 -0
- package/dist/components/icon/index.js +2 -0
- package/dist/components/icon/index.js.map +1 -0
- package/dist/components/icon-button/index.d.ts +1 -1
- package/dist/components/icon-button/index.js +1 -1
- package/dist/components/icon-button/index.js.map +1 -1
- package/dist/components/label/index.d.ts +14 -0
- package/dist/components/label/index.js +2 -0
- package/dist/components/label/index.js.map +1 -0
- package/dist/components/radio/index.d.ts +16 -0
- package/dist/components/radio/index.js +2 -0
- package/dist/components/radio/index.js.map +1 -0
- package/dist/components/switch/index.d.ts +14 -0
- package/dist/components/switch/index.js +2 -0
- package/dist/components/switch/index.js.map +1 -0
- package/dist/components/text-area/index.d.ts +25 -0
- package/dist/components/text-area/index.js +2 -0
- package/dist/components/text-area/index.js.map +1 -0
- package/dist/components/text-field/index.d.ts +23 -0
- package/dist/components/text-field/index.js +2 -0
- package/dist/components/text-field/index.js.map +1 -0
- package/dist/components/toggle-icon-button/index.js +1 -1
- package/dist/components/toggle-icon-button/index.js.map +1 -1
- package/dist/components/tooltip/index.js +1 -1
- package/dist/components/tooltip/index.js.map +1 -1
- package/dist/icons/catalog.d.ts +34 -0
- package/dist/icons/catalog.js +2 -0
- package/dist/icons/catalog.js.map +1 -0
- package/dist/index.css +28 -22
- package/dist/index.d.ts +12 -76
- package/dist/index.js +1 -1
- package/dist/lib/react.d.ts +23 -1
- package/dist/lib/react.js +1 -1
- package/dist/lib/react.js.map +1 -1
- package/dist/metafile-esm.json +1 -1
- package/dist/styles.css +657 -81
- package/package.json +79 -15
- package/dist/icons/add-fill.d.ts +0 -7
- package/dist/icons/add-fill.js +0 -3
- package/dist/icons/add-fill.js.map +0 -1
- package/dist/icons/add-to-list.d.ts +0 -7
- package/dist/icons/add-to-list.js +0 -3
- package/dist/icons/add-to-list.js.map +0 -1
- package/dist/icons/add.d.ts +0 -7
- package/dist/icons/add.js +0 -3
- package/dist/icons/add.js.map +0 -1
- package/dist/icons/arrange-table.d.ts +0 -7
- package/dist/icons/arrange-table.js +0 -3
- package/dist/icons/arrange-table.js.map +0 -1
- package/dist/icons/attach-file.d.ts +0 -7
- package/dist/icons/attach-file.js +0 -3
- package/dist/icons/attach-file.js.map +0 -1
- package/dist/icons/cancel-fill.d.ts +0 -7
- package/dist/icons/cancel-fill.js +0 -3
- package/dist/icons/cancel-fill.js.map +0 -1
- package/dist/icons/cancel.d.ts +0 -7
- package/dist/icons/cancel.js +0 -3
- package/dist/icons/cancel.js.map +0 -1
- package/dist/icons/center-on.d.ts +0 -7
- package/dist/icons/center-on.js +0 -3
- package/dist/icons/center-on.js.map +0 -1
- package/dist/icons/check.d.ts +0 -7
- package/dist/icons/check.js +0 -3
- package/dist/icons/check.js.map +0 -1
- package/dist/icons/collapse-all.d.ts +0 -7
- package/dist/icons/collapse-all.js +0 -3
- package/dist/icons/collapse-all.js.map +0 -1
- package/dist/icons/collapse-window.d.ts +0 -7
- package/dist/icons/collapse-window.js +0 -3
- package/dist/icons/collapse-window.js.map +0 -1
- package/dist/icons/condense.d.ts +0 -7
- package/dist/icons/condense.js +0 -3
- package/dist/icons/condense.js.map +0 -1
- package/dist/icons/copy-to-clipboard.d.ts +0 -7
- package/dist/icons/copy-to-clipboard.js +0 -3
- package/dist/icons/copy-to-clipboard.js.map +0 -1
- package/dist/icons/create-coa.d.ts +0 -7
- package/dist/icons/create-coa.js +0 -3
- package/dist/icons/create-coa.js.map +0 -1
- package/dist/icons/delete.d.ts +0 -7
- package/dist/icons/delete.js +0 -3
- package/dist/icons/delete.js.map +0 -1
- package/dist/icons/drag-horz.d.ts +0 -7
- package/dist/icons/drag-horz.js +0 -3
- package/dist/icons/drag-horz.js.map +0 -1
- package/dist/icons/drag-vert.d.ts +0 -7
- package/dist/icons/drag-vert.js +0 -3
- package/dist/icons/drag-vert.js.map +0 -1
- package/dist/icons/duplicate.d.ts +0 -7
- package/dist/icons/duplicate.js +0 -3
- package/dist/icons/duplicate.js.map +0 -1
- package/dist/icons/edit.d.ts +0 -7
- package/dist/icons/edit.js +0 -3
- package/dist/icons/edit.js.map +0 -1
- package/dist/icons/expand-all.d.ts +0 -7
- package/dist/icons/expand-all.js +0 -3
- package/dist/icons/expand-all.js.map +0 -1
- package/dist/icons/expand-left.d.ts +0 -7
- package/dist/icons/expand-left.js +0 -3
- package/dist/icons/expand-left.js.map +0 -1
- package/dist/icons/expand-right.d.ts +0 -7
- package/dist/icons/expand-right.js +0 -3
- package/dist/icons/expand-right.js.map +0 -1
- package/dist/icons/expand-window.d.ts +0 -7
- package/dist/icons/expand-window.js +0 -3
- package/dist/icons/expand-window.js.map +0 -1
- package/dist/icons/expand.d.ts +0 -7
- package/dist/icons/expand.js +0 -3
- package/dist/icons/expand.js.map +0 -1
- package/dist/icons/explore-data.d.ts +0 -7
- package/dist/icons/explore-data.js +0 -3
- package/dist/icons/explore-data.js.map +0 -1
- package/dist/icons/filter.d.ts +0 -7
- package/dist/icons/filter.js +0 -3
- package/dist/icons/filter.js.map +0 -1
- package/dist/icons/flag.d.ts +0 -7
- package/dist/icons/flag.js +0 -3
- package/dist/icons/flag.js.map +0 -1
- package/dist/icons/focus.d.ts +0 -7
- package/dist/icons/focus.js +0 -3
- package/dist/icons/focus.js.map +0 -1
- package/dist/icons/global-share.d.ts +0 -7
- package/dist/icons/global-share.js +0 -3
- package/dist/icons/global-share.js.map +0 -1
- package/dist/icons/group.d.ts +0 -7
- package/dist/icons/group.js +0 -3
- package/dist/icons/group.js.map +0 -1
- package/dist/icons/hide.d.ts +0 -7
- package/dist/icons/hide.js +0 -3
- package/dist/icons/hide.js.map +0 -1
- package/dist/icons/import.d.ts +0 -7
- package/dist/icons/import.js +0 -3
- package/dist/icons/import.js.map +0 -1
- package/dist/icons/index.d.ts +0 -75
- package/dist/icons/index.js +0 -2
- package/dist/icons/index.js.map +0 -1
- package/dist/icons/insert-chart.d.ts +0 -7
- package/dist/icons/insert-chart.js +0 -3
- package/dist/icons/insert-chart.js.map +0 -1
- package/dist/icons/jump-to.d.ts +0 -7
- package/dist/icons/jump-to.js +0 -3
- package/dist/icons/jump-to.js.map +0 -1
- package/dist/icons/lasso.d.ts +0 -7
- package/dist/icons/lasso.js +0 -3
- package/dist/icons/lasso.js.map +0 -1
- package/dist/icons/link.d.ts +0 -7
- package/dist/icons/link.js +0 -3
- package/dist/icons/link.js.map +0 -1
- package/dist/icons/lock-fill.d.ts +0 -7
- package/dist/icons/lock-fill.js +0 -3
- package/dist/icons/lock-fill.js.map +0 -1
- package/dist/icons/lock-outline.d.ts +0 -7
- package/dist/icons/lock-outline.js +0 -3
- package/dist/icons/lock-outline.js.map +0 -1
- package/dist/icons/login.d.ts +0 -7
- package/dist/icons/login.js +0 -3
- package/dist/icons/login.js.map +0 -1
- package/dist/icons/logout.d.ts +0 -7
- package/dist/icons/logout.js +0 -3
- package/dist/icons/logout.js.map +0 -1
- package/dist/icons/loop.d.ts +0 -7
- package/dist/icons/loop.js +0 -3
- package/dist/icons/loop.js.map +0 -1
- package/dist/icons/move.d.ts +0 -7
- package/dist/icons/move.js +0 -3
- package/dist/icons/move.js.map +0 -1
- package/dist/icons/mute.d.ts +0 -7
- package/dist/icons/mute.js +0 -3
- package/dist/icons/mute.js.map +0 -1
- package/dist/icons/open-container.d.ts +0 -7
- package/dist/icons/open-container.js +0 -3
- package/dist/icons/open-container.js.map +0 -1
- package/dist/icons/paste-from-clipboard.d.ts +0 -7
- package/dist/icons/paste-from-clipboard.js +0 -3
- package/dist/icons/paste-from-clipboard.js.map +0 -1
- package/dist/icons/pause.d.ts +0 -7
- package/dist/icons/pause.js +0 -3
- package/dist/icons/pause.js.map +0 -1
- package/dist/icons/person.d.ts +0 -7
- package/dist/icons/person.js +0 -3
- package/dist/icons/person.js.map +0 -1
- package/dist/icons/pin.d.ts +0 -7
- package/dist/icons/pin.js +0 -3
- package/dist/icons/pin.js.map +0 -1
- package/dist/icons/placeholder.d.ts +0 -7
- package/dist/icons/placeholder.js +0 -3
- package/dist/icons/placeholder.js.map +0 -1
- package/dist/icons/play.d.ts +0 -7
- package/dist/icons/play.js +0 -3
- package/dist/icons/play.js.map +0 -1
- package/dist/icons/playback.d.ts +0 -7
- package/dist/icons/playback.js +0 -3
- package/dist/icons/playback.js.map +0 -1
- package/dist/icons/polygon-lasso.d.ts +0 -7
- package/dist/icons/polygon-lasso.js +0 -3
- package/dist/icons/polygon-lasso.js.map +0 -1
- package/dist/icons/pop-back-in.d.ts +0 -7
- package/dist/icons/pop-back-in.js +0 -3
- package/dist/icons/pop-back-in.js.map +0 -1
- package/dist/icons/pop-out.d.ts +0 -7
- package/dist/icons/pop-out.js +0 -3
- package/dist/icons/pop-out.js.map +0 -1
- package/dist/icons/record.d.ts +0 -7
- package/dist/icons/record.js +0 -3
- package/dist/icons/record.js.map +0 -1
- package/dist/icons/rectangle-select.d.ts +0 -7
- package/dist/icons/rectangle-select.js +0 -3
- package/dist/icons/rectangle-select.js.map +0 -1
- package/dist/icons/remove-fill.d.ts +0 -7
- package/dist/icons/remove-fill.js +0 -3
- package/dist/icons/remove-fill.js.map +0 -1
- package/dist/icons/remove-from-list.d.ts +0 -7
- package/dist/icons/remove-from-list.js +0 -3
- package/dist/icons/remove-from-list.js.map +0 -1
- package/dist/icons/remove.d.ts +0 -7
- package/dist/icons/remove.js +0 -3
- package/dist/icons/remove.js.map +0 -1
- package/dist/icons/reverse.d.ts +0 -7
- package/dist/icons/reverse.js +0 -3
- package/dist/icons/reverse.js.map +0 -1
- package/dist/icons/screenshot.d.ts +0 -7
- package/dist/icons/screenshot.js +0 -3
- package/dist/icons/screenshot.js.map +0 -1
- package/dist/icons/search.d.ts +0 -7
- package/dist/icons/search.js +0 -3
- package/dist/icons/search.js.map +0 -1
- package/dist/icons/share.d.ts +0 -7
- package/dist/icons/share.js +0 -3
- package/dist/icons/share.js.map +0 -1
- package/dist/icons/show.d.ts +0 -7
- package/dist/icons/show.js +0 -3
- package/dist/icons/show.js.map +0 -1
- package/dist/icons/stack-cards.d.ts +0 -7
- package/dist/icons/stack-cards.js +0 -3
- package/dist/icons/stack-cards.js.map +0 -1
- package/dist/icons/stack.d.ts +0 -7
- package/dist/icons/stack.js +0 -3
- package/dist/icons/stack.js.map +0 -1
- package/dist/icons/tether.d.ts +0 -7
- package/dist/icons/tether.js +0 -3
- package/dist/icons/tether.js.map +0 -1
- package/dist/icons/track-changes.d.ts +0 -7
- package/dist/icons/track-changes.js +0 -3
- package/dist/icons/track-changes.js.map +0 -1
- package/dist/icons/types.d.ts +0 -6
- package/dist/icons/types.js +0 -2
- package/dist/icons/types.js.map +0 -1
- package/dist/icons/undo.d.ts +0 -7
- package/dist/icons/undo.js +0 -3
- package/dist/icons/undo.js.map +0 -1
- package/dist/icons/zoom-in.d.ts +0 -7
- package/dist/icons/zoom-in.js +0 -3
- package/dist/icons/zoom-in.js.map +0 -1
- package/dist/icons/zoom-out.d.ts +0 -7
- package/dist/icons/zoom-out.js +0 -3
- package/dist/icons/zoom-out.js.map +0 -1
- package/dist/icons/zoom-to.d.ts +0 -7
- package/dist/icons/zoom-to.js +0 -3
- package/dist/icons/zoom-to.js.map +0 -1
package/dist/index.css
CHANGED
@@ -94,7 +94,7 @@
|
|
94
94
|
--classification-confidential: #0033a0;
|
95
95
|
--classification-secret: #c8102e;
|
96
96
|
--classification-top-secret: #ff8c00;
|
97
|
-
--classification-
|
97
|
+
--classification-ts-sci: #fce83a;
|
98
98
|
|
99
99
|
--header-xxl-size: 32px;
|
100
100
|
--header-xxl-height: 40px;
|
@@ -182,8 +182,8 @@
|
|
182
182
|
|
183
183
|
--color-default-light: var(--neutral-01, #ffffff);
|
184
184
|
--color-default-dark: var(--neutral-03, #898989);
|
185
|
-
--color-inverse-dark: var(--neutral-
|
186
|
-
--color-inverse-light: var(--neutral-
|
185
|
+
--color-inverse-dark: var(--neutral-07,#383838);
|
186
|
+
--color-inverse-light: var(--neutral-09, #222222);
|
187
187
|
--color-disabled: var(--neutral-05, #565656);
|
188
188
|
--color-highlight: var(--highlight-primary-03, #28f5be);
|
189
189
|
--color-info: var(--neutral-04, #686868);
|
@@ -198,7 +198,7 @@
|
|
198
198
|
--color-classification-confidential: var(--classification-confidential, #0033a0);
|
199
199
|
--color-classification-secret: var(--classification-secret, #c8102e);
|
200
200
|
--color-classification-top-secret: var(--classification-top-secret, #ff8c00);
|
201
|
-
--color-classification-
|
201
|
+
--color-classification-ts-sci: var(--classification-ts-sci, #fce83a);
|
202
202
|
|
203
203
|
/** Radius **/
|
204
204
|
--radius-none: 0px;
|
@@ -232,102 +232,107 @@
|
|
232
232
|
@utility text-header-xxl {
|
233
233
|
font-size: var(--header-xxl-size);
|
234
234
|
font-weight: 500;
|
235
|
-
line-height: var(--header-xxl-height);
|
236
235
|
letter-spacing: 0px;
|
236
|
+
line-height: var(--header-xxl-height);
|
237
237
|
}
|
238
238
|
|
239
239
|
@utility text-header-xl {
|
240
240
|
font-size: var(--header-xl-size);
|
241
241
|
font-weight: 500;
|
242
|
-
line-height: var(--header-xl-height);
|
243
242
|
letter-spacing: 0.18px;
|
243
|
+
line-height: var(--header-xl-height);
|
244
244
|
}
|
245
245
|
|
246
246
|
@utility text-header-l {
|
247
247
|
font-size: var(--header-l-size);
|
248
248
|
font-weight: 500;
|
249
|
-
line-height: var(--header-l-height);
|
250
249
|
letter-spacing: 0.18px;
|
250
|
+
line-height: var(--header-l-height);
|
251
251
|
}
|
252
252
|
|
253
253
|
@utility text-header-m {
|
254
254
|
font-size: var(--header-m-size);
|
255
255
|
font-weight: 500;
|
256
|
-
line-height: var(--header-m-height);
|
257
256
|
letter-spacing: 0.25px;
|
257
|
+
line-height: var(--header-m-height);
|
258
258
|
}
|
259
259
|
|
260
260
|
@utility text-header-s {
|
261
261
|
font-size: var(--header-s-size);
|
262
262
|
font-weight: 500;
|
263
|
-
line-height: var(--header-s-height);
|
264
263
|
letter-spacing: 0.4px;
|
264
|
+
line-height: var(--header-s-height);
|
265
265
|
}
|
266
266
|
|
267
267
|
@utility text-header-xs {
|
268
268
|
font-size: var(--header-xs-size);
|
269
269
|
font-weight: 500;
|
270
|
-
line-height: var(--header-xs-height);
|
271
270
|
letter-spacing: 0.25px;
|
271
|
+
line-height: var(--header-xs-height);
|
272
272
|
}
|
273
273
|
|
274
274
|
|
275
275
|
@utility text-body-l {
|
276
276
|
font-size: var(--body-l-size);
|
277
|
-
|
277
|
+
font-weight: 400;
|
278
278
|
letter-spacing: 0.5px;
|
279
|
+
line-height: var(--body-l-height);
|
279
280
|
}
|
280
281
|
|
281
282
|
@utility text-body-m {
|
282
283
|
font-size: var(--body-m-size);
|
283
|
-
|
284
|
+
font-weight: 400;
|
284
285
|
letter-spacing: 0.25px;
|
286
|
+
line-height: var(--body-m-height);
|
285
287
|
}
|
286
288
|
|
287
289
|
@utility text-body-s {
|
288
290
|
font-size: var(--body-s-size);
|
289
|
-
|
291
|
+
font-weight: 400;
|
290
292
|
letter-spacing: 0.4px;
|
293
|
+
line-height: var(--body-s-height);
|
291
294
|
}
|
292
295
|
|
293
296
|
@utility text-body-xs {
|
294
297
|
font-size: var(--body-xs-size);
|
295
|
-
|
298
|
+
font-weight: 400;
|
296
299
|
letter-spacing: 0.5px;
|
300
|
+
line-height: var(--body-xs-height);
|
297
301
|
}
|
298
302
|
|
299
303
|
@utility text-body-xxs {
|
300
304
|
font-size: var(--body-xxs-size);
|
301
|
-
|
305
|
+
font-weight: 400;
|
302
306
|
letter-spacing: 0.25px;
|
307
|
+
line-height: var(--body-xxs-height);
|
303
308
|
}
|
304
309
|
|
305
310
|
@utility text-button-l {
|
306
311
|
font-size: var(--button-l-size);
|
307
312
|
font-weight: bold;
|
308
|
-
line-height: var(--button-l-height);
|
309
313
|
letter-spacing: 0.5px;
|
314
|
+
line-height: var(--button-l-height);
|
310
315
|
}
|
311
316
|
|
312
317
|
@utility text-button-m {
|
313
318
|
font-size: var(--button-m-size);
|
314
319
|
font-weight: bold;
|
315
|
-
line-height: var(--button-m-height);
|
316
320
|
letter-spacing: 0.25px;
|
321
|
+
line-height: var(--button-m-height);
|
317
322
|
}
|
318
323
|
|
319
324
|
@utility text-button-s {
|
320
325
|
font-size: var(--button-s-size);
|
321
326
|
font-weight: bold;
|
322
|
-
line-height: var(--button-s-height);
|
323
327
|
letter-spacing: 0.4px;
|
328
|
+
line-height: var(--button-s-height);
|
324
329
|
}
|
325
330
|
|
326
331
|
@utility text-button-xs {
|
327
332
|
font-size: var(--button-xs-size);
|
328
333
|
font-weight: bold;
|
329
|
-
line-height: var(--button-xs-height);
|
330
334
|
letter-spacing: 0.5px;
|
335
|
+
line-height: var(--button-xs-height);
|
331
336
|
}
|
332
337
|
|
333
338
|
@utility w-content {
|
@@ -338,6 +343,10 @@
|
|
338
343
|
height: fit-content;
|
339
344
|
}
|
340
345
|
|
346
|
+
@utility w-* {
|
347
|
+
width: --value([ *]);
|
348
|
+
}
|
349
|
+
|
341
350
|
@utility icon-* {
|
342
351
|
--icon-color: --value([ *]);
|
343
352
|
--icon-color: --value(--color- *);
|
@@ -354,6 +363,3 @@
|
|
354
363
|
--icon-color: --value([ *]);
|
355
364
|
--icon-color: --value(--color- *);
|
356
365
|
}
|
357
|
-
|
358
|
-
@custom-variant pressed (&:where([data-pressed] *));
|
359
|
-
@custom-variant ai-hovered (&:where([data-hovered] *));
|
package/dist/index.d.ts
CHANGED
@@ -1,93 +1,29 @@
|
|
1
|
+
export { Accordion, AccordionGroupProps, AccordionHeaderProps, AccordionPanelProps, AccordionProps } from './components/accordion/index.js';
|
1
2
|
export { Avatar, AvatarProps } from './components/avatar/index.js';
|
2
3
|
export { Badge, BadgeProps } from './components/badge/index.js';
|
3
4
|
export { Box, BoxProps } from './components/box/index.js';
|
4
5
|
export { Button, ButtonProps } from './components/button/index.js';
|
6
|
+
export { Checkbox, CheckboxGroupProps, CheckboxProps } from './components/checkbox/index.js';
|
7
|
+
export { Chip, ChipListProps, ChipProps, DeletableChip, SelectableChip } from './components/chip/index.js';
|
5
8
|
export { ClassificationBadge, ClassificationBadgeProps } from './components/classification-badge/index.js';
|
6
9
|
export { ClassificationBanner, ClassificationBannerProps } from './components/classification-banner/index.js';
|
7
10
|
export { FloatingButton, FloatingButtonProps } from './components/floating-button/index.js';
|
11
|
+
export { Icon, IconProps } from './components/icon/index.js';
|
8
12
|
export { IconButton, IconButtonProps } from './components/icon-button/index.js';
|
13
|
+
export { Label } from './components/label/index.js';
|
14
|
+
export { Radio, RadioGroupProps, RadioProps } from './components/radio/index.js';
|
15
|
+
export { Switch, SwitchProps } from './components/switch/index.js';
|
16
|
+
export { TextArea, TextAreaProps } from './components/text-area/index.js';
|
17
|
+
export { TextField, TextFieldProps } from './components/text-field/index.js';
|
9
18
|
export { ToggleIconButton, ToggleIconButtonProps } from './components/toggle-icon-button/index.js';
|
10
19
|
export { Tooltip, TooltipBody, TooltipBodyProps, TooltipProps, TooltipTrigger, TooltipTriggerProps } from './components/tooltip/index.js';
|
11
|
-
export {
|
12
|
-
export { AddToList } from './icons/add-to-list.js';
|
13
|
-
export { Add } from './icons/add.js';
|
14
|
-
export { ArrangeTable } from './icons/arrange-table.js';
|
15
|
-
export { AttachFile } from './icons/attach-file.js';
|
16
|
-
export { CancelFill } from './icons/cancel-fill.js';
|
17
|
-
export { Cancel } from './icons/cancel.js';
|
18
|
-
export { CenterOn } from './icons/center-on.js';
|
19
|
-
export { Check } from './icons/check.js';
|
20
|
-
export { CollapseAll } from './icons/collapse-all.js';
|
21
|
-
export { CollapseWindow } from './icons/collapse-window.js';
|
22
|
-
export { Condense } from './icons/condense.js';
|
23
|
-
export { CopyToClipboard } from './icons/copy-to-clipboard.js';
|
24
|
-
export { CreateCOA } from './icons/create-coa.js';
|
25
|
-
export { Delete } from './icons/delete.js';
|
26
|
-
export { DragHorz } from './icons/drag-horz.js';
|
27
|
-
export { DragVert } from './icons/drag-vert.js';
|
28
|
-
export { Duplicate } from './icons/duplicate.js';
|
29
|
-
export { Edit } from './icons/edit.js';
|
30
|
-
export { ExpandAll } from './icons/expand-all.js';
|
31
|
-
export { ExpandLeft } from './icons/expand-left.js';
|
32
|
-
export { ExpandRight } from './icons/expand-right.js';
|
33
|
-
export { ExpandWindow } from './icons/expand-window.js';
|
34
|
-
export { Expand } from './icons/expand.js';
|
35
|
-
export { ExploreData } from './icons/explore-data.js';
|
36
|
-
export { Filter } from './icons/filter.js';
|
37
|
-
export { Flag } from './icons/flag.js';
|
38
|
-
export { Focus } from './icons/focus.js';
|
39
|
-
export { GlobalShare } from './icons/global-share.js';
|
40
|
-
export { Group } from './icons/group.js';
|
41
|
-
export { Hide } from './icons/hide.js';
|
42
|
-
export { Import } from './icons/import.js';
|
43
|
-
export { InsertChart } from './icons/insert-chart.js';
|
44
|
-
export { JumpTo } from './icons/jump-to.js';
|
45
|
-
export { Lasso } from './icons/lasso.js';
|
46
|
-
export { Link } from './icons/link.js';
|
47
|
-
export { LockFill } from './icons/lock-fill.js';
|
48
|
-
export { LockOutline } from './icons/lock-outline.js';
|
49
|
-
export { Login } from './icons/login.js';
|
50
|
-
export { Logout } from './icons/logout.js';
|
51
|
-
export { Loop } from './icons/loop.js';
|
52
|
-
export { Move } from './icons/move.js';
|
53
|
-
export { Mute } from './icons/mute.js';
|
54
|
-
export { OpenContainer } from './icons/open-container.js';
|
55
|
-
export { PasteFromClipboard } from './icons/paste-from-clipboard.js';
|
56
|
-
export { Pause } from './icons/pause.js';
|
57
|
-
export { Person } from './icons/person.js';
|
58
|
-
export { Pin } from './icons/pin.js';
|
59
|
-
export { Placeholder } from './icons/placeholder.js';
|
60
|
-
export { Play } from './icons/play.js';
|
61
|
-
export { Playback } from './icons/playback.js';
|
62
|
-
export { PolygonLasso } from './icons/polygon-lasso.js';
|
63
|
-
export { PopBackIn } from './icons/pop-back-in.js';
|
64
|
-
export { PopOut } from './icons/pop-out.js';
|
65
|
-
export { Record } from './icons/record.js';
|
66
|
-
export { RectangleSelect } from './icons/rectangle-select.js';
|
67
|
-
export { RemoveFill } from './icons/remove-fill.js';
|
68
|
-
export { RemoveFromList } from './icons/remove-from-list.js';
|
69
|
-
export { Remove } from './icons/remove.js';
|
70
|
-
export { Reverse } from './icons/reverse.js';
|
71
|
-
export { Screenshot } from './icons/screenshot.js';
|
72
|
-
export { Search } from './icons/search.js';
|
73
|
-
export { Share } from './icons/share.js';
|
74
|
-
export { Show } from './icons/show.js';
|
75
|
-
export { StackCards } from './icons/stack-cards.js';
|
76
|
-
export { Stack } from './icons/stack.js';
|
77
|
-
export { Tether } from './icons/tether.js';
|
78
|
-
export { TrackChanges } from './icons/track-changes.js';
|
79
|
-
export { IconProps } from './icons/types.js';
|
80
|
-
export { Undo } from './icons/undo.js';
|
81
|
-
export { ZoomIn } from './icons/zoom-in.js';
|
82
|
-
export { ZoomOut } from './icons/zoom-out.js';
|
83
|
-
export { ZoomTo } from './icons/zoom-to.js';
|
84
|
-
export { containsExactChildren } from './lib/react.js';
|
20
|
+
export { containsExactChildren, expectsIconWrapper } from './lib/react.js';
|
85
21
|
export { cn, twMerge } from './lib/utils.js';
|
86
22
|
import 'react/jsx-runtime';
|
87
23
|
import 'cva/types';
|
88
|
-
import '@radix-ui/react-avatar';
|
89
|
-
import 'cva';
|
90
24
|
import 'react';
|
91
25
|
import 'react-aria-components';
|
26
|
+
import 'cva';
|
27
|
+
import '@radix-ui/react-avatar';
|
92
28
|
import 'tailwind-merge';
|
93
29
|
import 'clsx';
|
package/dist/index.js
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
export{
|
1
|
+
export{Accordion}from'./components/accordion/index.js';export{Avatar}from'./components/avatar/index.js';export{Badge}from'./components/badge/index.js';export{Box}from'./components/box/index.js';export{Button}from'./components/button/index.js';export{Checkbox}from'./components/checkbox/index.js';export{Chip,DeletableChip,SelectableChip}from'./components/chip/index.js';export{ClassificationBadge}from'./components/classification-badge/index.js';export{ClassificationBanner}from'./components/classification-banner/index.js';export{FloatingButton}from'./components/floating-button/index.js';export{Icon}from'./components/icon/index.js';export{IconButton}from'./components/icon-button/index.js';export{Label}from'./components/label/index.js';export{Radio}from'./components/radio/index.js';export{Switch}from'./components/switch/index.js';export{TextArea}from'./components/text-area/index.js';export{TextField}from'./components/text-field/index.js';export{ToggleIconButton}from'./components/toggle-icon-button/index.js';export{Tooltip,TooltipBody,TooltipTrigger}from'./components/tooltip/index.js';export{containsExactChildren,expectsIconWrapper}from'./lib/react.js';export{cn,twMerge}from'./lib/utils.js';//# sourceMappingURL=index.js.map
|
2
2
|
//# sourceMappingURL=index.js.map
|
package/dist/lib/react.d.ts
CHANGED
@@ -6,5 +6,27 @@ type ContainsExactChildrenProps = {
|
|
6
6
|
restrictions: Record<string, number>;
|
7
7
|
};
|
8
8
|
declare function containsExactChildren({ children, componentName, restrictions, }: ContainsExactChildrenProps): void;
|
9
|
+
/**
|
10
|
+
* I look for svgIcons exported from the @accelint/icons library
|
11
|
+
* and ensure that they are wrapped in an Icon component in order
|
12
|
+
* to get the classes and styles they need in context.
|
13
|
+
*
|
14
|
+
* Using isValidElement means we will filter out strings, boolean, etc
|
15
|
+
* that are valid nodes but not elements.
|
16
|
+
*
|
17
|
+
* @example
|
18
|
+
* expectsIconWrapper({
|
19
|
+
* children,
|
20
|
+
* componentName: Button.displayName,
|
21
|
+
* });
|
22
|
+
*
|
23
|
+
*
|
24
|
+
* @param children the children of the calling component
|
25
|
+
* @param componentName the displayName of the calling component
|
26
|
+
*/
|
27
|
+
declare function expectsIconWrapper({ children, componentName }: {
|
28
|
+
children: any;
|
29
|
+
componentName: any;
|
30
|
+
}): void;
|
9
31
|
|
10
|
-
export { containsExactChildren };
|
32
|
+
export { containsExactChildren, expectsIconWrapper };
|
package/dist/lib/react.js
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
import {Children,isValidElement}from'react';function
|
1
|
+
import {Children,isValidElement}from'react';function h({children:i,componentName:t,restrictions:o}){let n=Children.toArray(i);if(!n.every(isValidElement))throw new Error(`<${t}> received invalid children.`);let p=n.reduce((e,r)=>({...e,[r.type.displayName]:e[r.type.displayName]-1}),o),s=Object.entries(p).filter(([,e])=>e!==0);if(s.length!==0){let e=s.map(([r,d])=>`${d} of <${r}>`).join(", ");throw new Error(`<${t}> is missing the following: ${e}`)}}function m({children:i,componentName:t}){Children.toArray(i).map(n=>{if(isValidElement(n)&&n.type.name?.startsWith("Svg"))throw new Error(`${t} is using an icon without the required Icon wrapper`)});}export{h as containsExactChildren,m as expectsIconWrapper};//# sourceMappingURL=react.js.map
|
2
2
|
//# sourceMappingURL=react.js.map
|
package/dist/lib/react.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../../src/lib/react.ts"],"names":["containsExactChildren","children","componentName","restrictions","childrenComponents","Children","isValidElement","restrictionResults","acc","child","missingComponents","value","restrictionString","key"],"mappings":"4CAqBO,SAASA,CAAAA,CAAsB,CACpC,QAAA,CAAAC,CACA,CAAA,aAAA,CAAAC,
|
1
|
+
{"version":3,"sources":["../../src/lib/react.ts"],"names":["containsExactChildren","children","componentName","restrictions","childrenComponents","Children","isValidElement","restrictionResults","acc","child","missingComponents","value","restrictionString","key","expectsIconWrapper"],"mappings":"4CAqBO,SAASA,CAAAA,CAAsB,CACpC,QAAA,CAAAC,CACA,CAAA,aAAA,CAAAC,CACA,CAAA,YAAA,CAAAC,CACF,CAA+B,CAAA,CAC7B,IAAMC,CAAAA,CAAqBC,QAAS,CAAA,OAAA,CAAQJ,CAAQ,CAAA,CAEpD,GAAI,CAACG,CAAAA,CAAmB,KAAME,CAAAA,cAAc,CAC1C,CAAA,MAAM,IAAI,KAAA,CAAM,IAAIJ,CAAa,CAAA,4BAAA,CAA8B,CAGjE,CAAA,IAAMK,CAAqBH,CAAAA,CAAAA,CAAmB,MAC5C,CAAA,CAACI,EAAKC,CAAW,IAAA,CAEf,GAAGD,CAAAA,CACH,CAACC,CAAAA,CAAM,IAAK,CAAA,WAAW,EAAGD,CAAIC,CAAAA,CAAAA,CAAM,IAAK,CAAA,WAAW,CAAI,CAAA,CAC1D,CACAN,CAAAA,CAAAA,CACF,EAEMO,CAAoB,CAAA,MAAA,CAAO,OAAQH,CAAAA,CAAkB,CAAE,CAAA,MAAA,CAC3D,CAAC,EAAGI,CAAK,CAAA,GAAMA,CAAU,GAAA,CAC3B,CAEA,CAAA,GAAID,CAAkB,CAAA,MAAA,GAAW,EAAG,CAClC,IAAME,CAAoBF,CAAAA,CAAAA,CACvB,GAAI,CAAA,CAAC,CAACG,CAAAA,CAAKF,CAAK,CAAM,GAAA,CAAA,EAAGA,CAAK,CAAA,KAAA,EAAQE,CAAG,CAAA,CAAA,CAAG,CAC5C,CAAA,IAAA,CAAK,IAAI,CAEZ,CAAA,MAAM,IAAI,KAAA,CACR,CAAIX,CAAAA,EAAAA,CAAa,CAA+BU,4BAAAA,EAAAA,CAAiB,EACnE,CACF,CACF,CAoBO,SAASE,CAAmB,CAAA,CAAE,QAAAb,CAAAA,CAAAA,CAAU,cAAAC,CAAc,CAAA,CAAG,CACnCG,QAAAA,CAAS,OAAQJ,CAAAA,CAAQ,CAEjC,CAAA,GAAA,CAAKQ,GAAU,CAChC,GAAIH,cAAeG,CAAAA,CAAK,CAElBA,EAAAA,CAAAA,CAAM,IAAK,CAAA,IAAA,EAAM,WAAW,KAAK,CAAA,CACnC,MAAM,IAAI,MACR,CAAGP,EAAAA,CAAa,CAClB,mDAAA,CAAA,CAGN,CAAC,EACH","file":"react.js","sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n// @ts-nocheck\nimport { Children, type ReactNode, isValidElement } from 'react';\n\ntype ContainsExactChildrenProps = {\n componentName: string;\n children: ReactNode | ReactNode[];\n restrictions: Record<string, number>;\n};\n\nexport function containsExactChildren({\n children,\n componentName,\n restrictions,\n}: ContainsExactChildrenProps) {\n const childrenComponents = Children.toArray(children);\n\n if (!childrenComponents.every(isValidElement)) {\n throw new Error(`<${componentName}> received invalid children.`);\n }\n\n const restrictionResults = childrenComponents.reduce(\n (acc, child) => ({\n // biome-ignore lint/performance/noAccumulatingSpread: this is fine.\n ...acc,\n [child.type.displayName]: acc[child.type.displayName] - 1,\n }),\n restrictions,\n );\n\n const missingComponents = Object.entries(restrictionResults).filter(\n ([, value]) => value !== 0,\n );\n\n if (missingComponents.length !== 0) {\n const restrictionString = missingComponents\n .map(([key, value]) => `${value} of <${key}>`)\n .join(', ');\n\n throw new Error(\n `<${componentName}> is missing the following: ${restrictionString}`,\n );\n }\n}\n\n/**\n * I look for svgIcons exported from the @accelint/icons library\n * and ensure that they are wrapped in an Icon component in order\n * to get the classes and styles they need in context.\n *\n * Using isValidElement means we will filter out strings, boolean, etc\n * that are valid nodes but not elements.\n *\n * @example\n * expectsIconWrapper({\n * children,\n * componentName: Button.displayName,\n * });\n *\n *\n * @param children the children of the calling component\n * @param componentName the displayName of the calling component\n */\nexport function expectsIconWrapper({ children, componentName }) {\n const childrenComponents = Children.toArray(children);\n\n childrenComponents.map((child) => {\n if (isValidElement(child)) {\n // icons should never be a direct child of the parent\n if (child.type.name?.startsWith('Svg')) {\n throw new Error(\n `${componentName} is using an icon without the required Icon wrapper`,\n );\n }\n }\n });\n}\n"]}
|