@sincpro/web-ui 2.4.0 → 2.5.0
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/README.md +24 -3
- package/dist/components/activity/Activity.d.ts +20 -1
- package/dist/components/activity/Activity.js +44 -7
- package/dist/components/activity/index.d.ts +1 -1
- package/dist/components/board/Board.d.ts +74 -2
- package/dist/components/board/Board.js +65 -2
- package/dist/components/board/index.d.ts +1 -1
- package/dist/components/board/index.js +1 -1
- package/dist/components/canvas/canvas.css +6 -1
- package/dist/components/form/Form.js +11 -0
- package/dist/components/form/FormIndex.d.ts +11 -0
- package/dist/components/form/FormIndex.js +96 -0
- package/dist/components/form/Sheet.js +5 -0
- package/dist/components/listing/ChartExplorer.js +10 -5
- package/dist/components/record/DirtyActions.d.ts +10 -1
- package/dist/components/record/DirtyActions.js +77 -6
- package/dist/components/record/RecordHeader.js +17 -11
- package/dist/foundations/calendar.d.ts +12 -0
- package/dist/foundations/calendar.js +50 -0
- package/dist/foundations/chart.d.ts +10 -1
- package/dist/foundations/chart.js +17 -1
- package/dist/foundations/copy.d.ts +20 -0
- package/dist/foundations/copy.es.js +9 -0
- package/dist/foundations/copy.js +9 -0
- package/dist/foundations/form.d.ts +6 -0
- package/dist/foundations/form.js +7 -0
- package/dist/foundations/index.d.ts +2 -2
- package/dist/foundations/index.js +2 -2
- package/dist/foundations/pivot.d.ts +6 -0
- package/dist/foundations/pivot.js +1 -0
- package/dist/primitives/chart/BarList.d.ts +30 -0
- package/dist/primitives/chart/BarList.js +27 -0
- package/dist/primitives/chart/Chart.d.ts +13 -0
- package/dist/primitives/chart/Chart.js +71 -19
- package/dist/primitives/chart/Sparkline.d.ts +30 -0
- package/dist/primitives/chart/Sparkline.js +53 -0
- package/dist/primitives/chart/index.d.ts +2 -0
- package/dist/primitives/chart/index.js +2 -0
- package/dist/primitives/field/Field.d.ts +6 -2
- package/dist/primitives/field/Field.js +35 -6
- package/dist/primitives/value/Metric.d.ts +7 -0
- package/dist/primitives/value/Metric.js +5 -2
- package/dist/tokens.css +53 -2
- package/package.json +1 -1
package/dist/tokens.css
CHANGED
|
@@ -342,6 +342,20 @@
|
|
|
342
342
|
--text-display: 1.75rem;
|
|
343
343
|
--text-display--line-height: 1.2;
|
|
344
344
|
|
|
345
|
+
/* Two steps for FIGURES, not for text. A number a board leads with is read before anything
|
|
346
|
+
else on the page, and at 19 px (`title`) it read as one more label — the board's headline
|
|
347
|
+
figures sat in chips the size of a tag. They are not titles either: a title is read, a
|
|
348
|
+
figure is compared, so they get their own steps, set tighter (a figure at display size
|
|
349
|
+
with text tracking looks loose: its digits drift apart).
|
|
350
|
+
figure — the value of a board's stat tile
|
|
351
|
+
hero — the ONE figure a board leads with (≥ 48 px), at most one per view */
|
|
352
|
+
--text-figure: 1.875rem;
|
|
353
|
+
--text-figure--line-height: 1.1;
|
|
354
|
+
--text-figure--letter-spacing: -0.02em;
|
|
355
|
+
--text-hero: 3rem;
|
|
356
|
+
--text-hero--line-height: 1;
|
|
357
|
+
--text-hero--letter-spacing: -0.03em;
|
|
358
|
+
|
|
345
359
|
/* ---------------------------------------------------------------- *
|
|
346
360
|
* THE RADIUS SCALE — «it is very square», and that was true.
|
|
347
361
|
*
|
|
@@ -533,6 +547,10 @@
|
|
|
533
547
|
to «Referencia del cli…», and a truncated label is a question. */
|
|
534
548
|
--container-label: 10rem;
|
|
535
549
|
|
|
550
|
+
/* The index of a «settings» form's sections (`FormIndex`), at the sheet's left: wide enough
|
|
551
|
+
for «Contacto y guía pública», narrow enough that the cards keep the page. */
|
|
552
|
+
--container-form-index: 12rem;
|
|
553
|
+
|
|
536
554
|
/* The tag column of a list row. It is what the column ASKS FOR, and it
|
|
537
555
|
belongs to the system: with a width of its own every tag starts where its
|
|
538
556
|
own ends and twelve rows give twelve indents. Asking for the same 8 rem,
|
|
@@ -596,6 +614,11 @@
|
|
|
596
614
|
its figure and label, so the tiles below do not move down when the numbers arrive. */
|
|
597
615
|
--size-metric: 3.75rem;
|
|
598
616
|
|
|
617
|
+
/* A stat tile's sparkline: the shape of the last periods under the figure, not a chart —
|
|
618
|
+
no axis, no grid. Tall enough to see a turn, short enough that the figure stays the
|
|
619
|
+
subject. */
|
|
620
|
+
--size-sparkline: 2.5rem;
|
|
621
|
+
|
|
599
622
|
/* The width of the peek drawer. It is a system decision and not a component
|
|
600
623
|
one: 30rem is what fits of a record without leaving the list behind it
|
|
601
624
|
—which has to stay clickable— reduced to a useless strip. */
|
|
@@ -783,11 +806,18 @@
|
|
|
783
806
|
--radius-ui-dialog: var(--ui-dialog-radius, var(--radius-panel));
|
|
784
807
|
--color-ui-dialog: var(--ui-dialog-bg, var(--color-surface));
|
|
785
808
|
|
|
786
|
-
/* A box of content: a block, a card of a list, a
|
|
809
|
+
/* A box of content: a block, a card of a list, a metric. */
|
|
787
810
|
--radius-ui-card: var(--ui-card-radius, var(--radius-box));
|
|
788
811
|
--color-ui-card: var(--ui-card-bg, var(--color-surface));
|
|
789
812
|
--color-ui-card-border: var(--ui-card-border, var(--color-line));
|
|
790
813
|
|
|
814
|
+
/* A board's tile and stat tile: a PANEL of a page, not a box inside one — the panel's
|
|
815
|
+
radius, like a window. Its colours fall back to the card's, so an application that
|
|
816
|
+
re-skinned its cards re-skins its boards too, and can still tell them apart. */
|
|
817
|
+
--radius-ui-tile: var(--ui-tile-radius, var(--radius-panel));
|
|
818
|
+
--color-ui-tile: var(--ui-tile-bg, var(--ui-card-bg, var(--color-surface)));
|
|
819
|
+
--color-ui-tile-border: var(--ui-tile-border, var(--ui-card-border, var(--color-line)));
|
|
820
|
+
|
|
791
821
|
/* A capsule: a tag, a chip of the search bar. */
|
|
792
822
|
--radius-ui-tag: var(--ui-tag-radius, var(--radius-pill));
|
|
793
823
|
|
|
@@ -1137,7 +1167,9 @@
|
|
|
1137
1167
|
--sc-accent: var(--color-primary);
|
|
1138
1168
|
--sc-danger: var(--color-danger);
|
|
1139
1169
|
--sc-on-danger: var(--color-surface);
|
|
1140
|
-
|
|
1170
|
+
/* `--color-scrim` is opaque — a veil is a share of it. Unmixed, ⌘K's palette (`.sc-scrim`)
|
|
1171
|
+
opened over a solid page (#43); both veils dim the page the way `Dialog` does. */
|
|
1172
|
+
--sc-scrim: color-mix(in srgb, var(--color-scrim) 40%, transparent);
|
|
1141
1173
|
--sc-modal-scrim: color-mix(in srgb, var(--color-scrim) 40%, transparent);
|
|
1142
1174
|
--sc-shadow: var(--shadow-window);
|
|
1143
1175
|
--sc-radius: var(--radius-panel);
|
|
@@ -1538,6 +1570,25 @@
|
|
|
1538
1570
|
}
|
|
1539
1571
|
}
|
|
1540
1572
|
|
|
1573
|
+
/* A field of the «settings» form style (`FormStyleProvider`): what it asks — the label and its
|
|
1574
|
+
help written out — on the left, two parts in five; the control on the right, three. The
|
|
1575
|
+
label column grows with the row because it holds a sentence, not one word. Below
|
|
1576
|
+
`--container-handheld` of the section it sits in, the row is one column: the help over a
|
|
1577
|
+
control squeezed beside it was two half-read things. */
|
|
1578
|
+
@utility grid-setting {
|
|
1579
|
+
grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
|
|
1580
|
+
& > [data-under-control] {
|
|
1581
|
+
grid-column-start: 2;
|
|
1582
|
+
}
|
|
1583
|
+
/* 40rem IS `--container-handheld`: a container query cannot read a custom property. */
|
|
1584
|
+
@container (width < 40rem) {
|
|
1585
|
+
grid-template-columns: minmax(0, 1fr);
|
|
1586
|
+
& > [data-under-control] {
|
|
1587
|
+
grid-column-start: auto;
|
|
1588
|
+
}
|
|
1589
|
+
}
|
|
1590
|
+
}
|
|
1591
|
+
|
|
1541
1592
|
/* ==================================================================== *
|
|
1542
1593
|
* TOUCH — the same controls, sized for a finger.
|
|
1543
1594
|
*
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sincpro/web-ui",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.5.0",
|
|
4
4
|
"description": "An enterprise web design system for business software — ERPs, back offices, management tools — in React and Tailwind: tokens, primitives, components and the two views every management screen is made of.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|