@nextlyhq/ui 0.0.2-alpha.73 → 0.0.2-alpha.74
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/index.cjs +997 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +192 -1
- package/dist/index.d.ts +192 -1
- package/dist/index.mjs +995 -10
- package/dist/index.mjs.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/styles.scoped.css +1 -1
- package/dist/theme.css +117 -82
- package/package.json +4 -4
package/dist/theme.css
CHANGED
|
@@ -279,29 +279,8 @@
|
|
|
279
279
|
* Perfect Fourth Scale (1.333 ratio) - WCAG 2.2 AA Compliant
|
|
280
280
|
* ============================================ */
|
|
281
281
|
|
|
282
|
-
/* Font
|
|
283
|
-
|
|
284
|
-
/* Type Scale - Base Size: 16px (1rem) */
|
|
285
|
-
--text-xs: 0.75rem;
|
|
286
|
-
/* 12px */
|
|
287
|
-
--text-sm: 0.875rem;
|
|
288
|
-
/* 14px */
|
|
289
|
-
--text-base: 1rem;
|
|
290
|
-
/* 16px - body text (WCAG minimum) */
|
|
291
|
-
--text-lg: 1.125rem;
|
|
292
|
-
/* 18px */
|
|
293
|
-
--text-xl: 1.25rem;
|
|
294
|
-
/* 20px */
|
|
295
|
-
--text-2xl: 1.5rem;
|
|
296
|
-
/* 24px */
|
|
297
|
-
--text-3xl: 1.875rem;
|
|
298
|
-
/* 30px */
|
|
299
|
-
--text-4xl: 2.25rem;
|
|
300
|
-
/* 36px */
|
|
301
|
-
--text-5xl: 3rem;
|
|
302
|
-
/* 48px */
|
|
303
|
-
--text-6xl: 3.75rem;
|
|
304
|
-
/* 60px */
|
|
282
|
+
/* Font families, the type scale and the spacing scale live in the
|
|
283
|
+
* non-inline @theme blocks below. */
|
|
305
284
|
|
|
306
285
|
/* Line Heights (Leading) */
|
|
307
286
|
--leading-none: 1;
|
|
@@ -331,57 +310,6 @@
|
|
|
331
310
|
--tracking-widest: 0.1em;
|
|
332
311
|
/* +1.6px at 16px */
|
|
333
312
|
|
|
334
|
-
/* ============================================
|
|
335
|
-
* SPACING & LAYOUT (Tailwind v4.1)
|
|
336
|
-
* 8px Grid System - Industry Standard
|
|
337
|
-
* ============================================ */
|
|
338
|
-
|
|
339
|
-
/* Spacing Scale (8px base unit) */
|
|
340
|
-
--space-0: 0rem;
|
|
341
|
-
/* 0px */
|
|
342
|
-
--space-px: 0.0625rem;
|
|
343
|
-
/* 1px - for fine borders */
|
|
344
|
-
--space-0-5: 0.125rem;
|
|
345
|
-
/* 2px */
|
|
346
|
-
--space-1: 0.25rem;
|
|
347
|
-
/* 4px - icon padding, tiny gaps */
|
|
348
|
-
--space-1-5: 0.375rem;
|
|
349
|
-
/* 6px */
|
|
350
|
-
--space-2: 0.5rem;
|
|
351
|
-
/* 8px - tight spacing, inline elements */
|
|
352
|
-
--space-2-5: 0.625rem;
|
|
353
|
-
/* 10px */
|
|
354
|
-
--space-3: 0.75rem;
|
|
355
|
-
/* 12px - between related elements */
|
|
356
|
-
--space-3-5: 0.875rem;
|
|
357
|
-
/* 14px */
|
|
358
|
-
--space-4: 1rem;
|
|
359
|
-
/* 16px - standard element spacing */
|
|
360
|
-
--space-5: 1.25rem;
|
|
361
|
-
/* 20px */
|
|
362
|
-
--space-6: 1.5rem;
|
|
363
|
-
/* 24px - between form fields */
|
|
364
|
-
--space-7: 1.75rem;
|
|
365
|
-
/* 28px */
|
|
366
|
-
--space-8: 2rem;
|
|
367
|
-
/* 32px - between sections */
|
|
368
|
-
--space-9: 2.25rem;
|
|
369
|
-
/* 36px */
|
|
370
|
-
--space-10: 2.5rem;
|
|
371
|
-
/* 40px */
|
|
372
|
-
--space-11: 2.75rem;
|
|
373
|
-
/* 44px - minimum touch target */
|
|
374
|
-
--space-12: 3rem;
|
|
375
|
-
/* 48px - between major sections */
|
|
376
|
-
--space-14: 3.5rem;
|
|
377
|
-
/* 56px */
|
|
378
|
-
--space-16: 4rem;
|
|
379
|
-
/* 64px - page margins */
|
|
380
|
-
--space-20: 5rem;
|
|
381
|
-
/* 80px */
|
|
382
|
-
--space-24: 6rem;
|
|
383
|
-
/* 96px - large section breaks */
|
|
384
|
-
|
|
385
313
|
/* ============================================
|
|
386
314
|
* BORDER RADIUS (Tailwind v4.1)
|
|
387
315
|
*
|
|
@@ -562,20 +490,119 @@
|
|
|
562
490
|
}
|
|
563
491
|
|
|
564
492
|
/* ============================================
|
|
565
|
-
*
|
|
566
|
-
*
|
|
567
|
-
*
|
|
493
|
+
* TYPE SCALE & SPACING SCALE (Tailwind v4.1)
|
|
494
|
+
*
|
|
495
|
+
* Deliberately a STATIC, non-inline `@theme`: every token here is emitted as a
|
|
496
|
+
* real custom property on `:root` whether or not a Tailwind utility uses it.
|
|
497
|
+
* Stylesheets that are not compiled against this theme read these through
|
|
498
|
+
* `var()` -- the page-builder editor's (`@nextlyhq/builder/styles.css`, pulled
|
|
499
|
+
* in by `@nextlyhq/plugin-page-builder/styles/editor.css`) does, for
|
|
500
|
+
* `--text-xs`, `--text-sm`, `--text-lg` and `--space-*` -- and a `var()` in
|
|
501
|
+
* such a sheet makes Tailwind emit nothing. Under `@theme inline` a token is
|
|
502
|
+
* emitted only where CSS Tailwind compiles reads it with `var()`, and a plain
|
|
503
|
+
* `@theme` drops the ones no utility uses, so either way the admin's build
|
|
504
|
+
* left these out and the editor's text fell back to the browser's 16px and its
|
|
505
|
+
* spacing to nothing. `static` keeps them all.
|
|
506
|
+
*
|
|
507
|
+
* Non-inline also makes the `text-*` utilities read `var(--text-*)` rather
|
|
508
|
+
* than a copied value, so they follow a token redeclared on a scope, as the
|
|
509
|
+
* font utilities above do. `--space-*` is not a Tailwind namespace (spacing
|
|
510
|
+
* utilities use `--spacing`), so it adds no utilities; it exists for `var()`.
|
|
511
|
+
* `packages/admin/src/styles/__tests__/editor-token-emission.test.ts` holds
|
|
512
|
+
* the admin's built stylesheet to emitting every token the editor reads.
|
|
513
|
+
* ============================================ */
|
|
514
|
+
@theme static {
|
|
515
|
+
/* Type Scale - Base Size: 16px (1rem) */
|
|
516
|
+
--text-xs: 0.75rem;
|
|
517
|
+
/* 12px */
|
|
518
|
+
--text-sm: 0.875rem;
|
|
519
|
+
/* 14px */
|
|
520
|
+
--text-base: 1rem;
|
|
521
|
+
/* 16px - body text (WCAG minimum) */
|
|
522
|
+
--text-lg: 1.125rem;
|
|
523
|
+
/* 18px */
|
|
524
|
+
--text-xl: 1.25rem;
|
|
525
|
+
/* 20px */
|
|
526
|
+
--text-2xl: 1.5rem;
|
|
527
|
+
/* 24px */
|
|
528
|
+
--text-3xl: 1.875rem;
|
|
529
|
+
/* 30px */
|
|
530
|
+
--text-4xl: 2.25rem;
|
|
531
|
+
/* 36px */
|
|
532
|
+
--text-5xl: 3rem;
|
|
533
|
+
/* 48px */
|
|
534
|
+
--text-6xl: 3.75rem;
|
|
535
|
+
/* 60px */
|
|
536
|
+
|
|
537
|
+
/* Spacing Scale (8px base unit) */
|
|
538
|
+
--space-0: 0rem;
|
|
539
|
+
/* 0px */
|
|
540
|
+
--space-px: 0.0625rem;
|
|
541
|
+
/* 1px - for fine borders */
|
|
542
|
+
--space-0-5: 0.125rem;
|
|
543
|
+
/* 2px */
|
|
544
|
+
--space-1: 0.25rem;
|
|
545
|
+
/* 4px - icon padding, tiny gaps */
|
|
546
|
+
--space-1-5: 0.375rem;
|
|
547
|
+
/* 6px */
|
|
548
|
+
--space-2: 0.5rem;
|
|
549
|
+
/* 8px - tight spacing, inline elements */
|
|
550
|
+
--space-2-5: 0.625rem;
|
|
551
|
+
/* 10px */
|
|
552
|
+
--space-3: 0.75rem;
|
|
553
|
+
/* 12px - between related elements */
|
|
554
|
+
--space-3-5: 0.875rem;
|
|
555
|
+
/* 14px */
|
|
556
|
+
--space-4: 1rem;
|
|
557
|
+
/* 16px - standard element spacing */
|
|
558
|
+
--space-5: 1.25rem;
|
|
559
|
+
/* 20px */
|
|
560
|
+
--space-6: 1.5rem;
|
|
561
|
+
/* 24px - between form fields */
|
|
562
|
+
--space-7: 1.75rem;
|
|
563
|
+
/* 28px */
|
|
564
|
+
--space-8: 2rem;
|
|
565
|
+
/* 32px - between sections */
|
|
566
|
+
--space-9: 2.25rem;
|
|
567
|
+
/* 36px */
|
|
568
|
+
--space-10: 2.5rem;
|
|
569
|
+
/* 40px */
|
|
570
|
+
--space-11: 2.75rem;
|
|
571
|
+
/* 44px - minimum touch target */
|
|
572
|
+
--space-12: 3rem;
|
|
573
|
+
/* 48px - between major sections */
|
|
574
|
+
--space-14: 3.5rem;
|
|
575
|
+
/* 56px */
|
|
576
|
+
--space-16: 4rem;
|
|
577
|
+
/* 64px - page margins */
|
|
578
|
+
--space-20: 5rem;
|
|
579
|
+
/* 80px */
|
|
580
|
+
--space-24: 6rem;
|
|
581
|
+
/* 96px - large section breaks */
|
|
582
|
+
}
|
|
583
|
+
|
|
584
|
+
/* ============================================
|
|
585
|
+
* LARGER HEADING SIZES
|
|
586
|
+
*
|
|
587
|
+
* Tailwind lifts an `@theme` out of an enclosing `@media`: these declarations
|
|
588
|
+
* are not limited to wide screens. They replace the `--text-2xl` to
|
|
589
|
+
* `--text-5xl` values of the type scale above at EVERY width, and the built
|
|
590
|
+
* stylesheet declares only these. Because that scale is non-inline, the
|
|
591
|
+
* `text-2xl` to `text-5xl` utilities read `var(--text-*)` and so render at
|
|
592
|
+
* these sizes. The block is `static` like the scale: a token's options come
|
|
593
|
+
* from its last declaration, and without it the sizes no utility uses would
|
|
594
|
+
* be dropped from the build again.
|
|
568
595
|
* ============================================ */
|
|
569
596
|
@media (min-width: 768px) {
|
|
570
|
-
@theme {
|
|
597
|
+
@theme static {
|
|
571
598
|
--text-2xl: 1.75rem;
|
|
572
|
-
/* 28px
|
|
599
|
+
/* 28px (the scale above says 24px) */
|
|
573
600
|
--text-3xl: 2.25rem;
|
|
574
|
-
/* 36px
|
|
601
|
+
/* 36px (the scale above says 30px) */
|
|
575
602
|
--text-4xl: 3rem;
|
|
576
|
-
/* 48px
|
|
603
|
+
/* 48px (the scale above says 36px) */
|
|
577
604
|
--text-5xl: 4rem;
|
|
578
|
-
/* 64px
|
|
605
|
+
/* 64px (the scale above says 48px) */
|
|
579
606
|
}
|
|
580
607
|
}
|
|
581
608
|
|
|
@@ -777,6 +804,11 @@
|
|
|
777
804
|
* from the library's green, which read at 4.26:1 on it, to about 5.2:1. */
|
|
778
805
|
--nx-toast-success-bg: oklch(0.9788 0.0221 160.24);
|
|
779
806
|
--nx-toast-success-text: oklch(0.5048 0.1506 146.87);
|
|
807
|
+
/* A warning toast's surface and text, the same way: the library's own pale
|
|
808
|
+
* amber surface, and its amber text, which read at 3.07:1 on it, darkened
|
|
809
|
+
* to about 5.1:1. */
|
|
810
|
+
--nx-toast-warning-bg: oklch(0.9904 0.0167 96.37);
|
|
811
|
+
--nx-toast-warning-text: oklch(0.54 0.13 60);
|
|
780
812
|
|
|
781
813
|
/* Darkened from amber-500 so it reads as text on white at WCAG 4.5:1 (was
|
|
782
814
|
* 2.15:1); its light shades still tint badge/alert surfaces. */
|
|
@@ -1072,6 +1104,9 @@
|
|
|
1072
1104
|
/* The toast library's own dark success surface and text, kept: about 12.3:1. */
|
|
1073
1105
|
--nx-toast-success-bg: oklch(0.2107 0.0498 157.43);
|
|
1074
1106
|
--nx-toast-success-text: oklch(0.8635 0.1699 157.75);
|
|
1107
|
+
/* The toast library's own dark warning surface and text, kept: about 11.2:1. */
|
|
1108
|
+
--nx-toast-warning-bg: oklch(0.2277 0.0509 113.29);
|
|
1109
|
+
--nx-toast-warning-text: oklch(0.8642 0.1416 92.19);
|
|
1075
1110
|
--nx-warning: oklch(0.7686 0.1646 70.11);
|
|
1076
1111
|
/* amber-500 */
|
|
1077
1112
|
--nx-warning-foreground: oklch(0.2079 0.0399 265.73);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nextlyhq/ui",
|
|
3
|
-
"version": "0.0.2-alpha.
|
|
3
|
+
"version": "0.0.2-alpha.74",
|
|
4
4
|
"description": "Nextly UI — Reusable React component library for Nextly plugins and custom admin UIs",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"keywords": [
|
|
@@ -87,9 +87,9 @@
|
|
|
87
87
|
"react-dom": "^19.3.0"
|
|
88
88
|
},
|
|
89
89
|
"devDependencies": {
|
|
90
|
-
"@nextlyhq/admin-css": "0.0.2-alpha.
|
|
91
|
-
"@nextlyhq/module-specifiers": "0.0.2-alpha.
|
|
92
|
-
"@nextlyhq/tsconfig": "0.0.2-alpha.
|
|
90
|
+
"@nextlyhq/admin-css": "0.0.2-alpha.74",
|
|
91
|
+
"@nextlyhq/module-specifiers": "0.0.2-alpha.74",
|
|
92
|
+
"@nextlyhq/tsconfig": "0.0.2-alpha.74",
|
|
93
93
|
"@tailwindcss/cli": "^4.3.2",
|
|
94
94
|
"@testing-library/react": "^16.3.0",
|
|
95
95
|
"@types/culori": "^4.0.1",
|