ionbase-ui 0.70.0 → 0.75.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/dist/components/Chart.d.ts +95 -0
- package/dist/components/Chart.d.ts.map +1 -0
- package/dist/components/Chart.js +60 -0
- package/dist/components/Chart.js.map +1 -0
- package/dist/components/SettingRow.d.ts +54 -0
- package/dist/components/SettingRow.d.ts.map +1 -0
- package/dist/components/SettingRow.js +60 -0
- package/dist/components/SettingRow.js.map +1 -0
- package/dist/components/StatTile.d.ts +65 -0
- package/dist/components/StatTile.d.ts.map +1 -0
- package/dist/components/StatTile.js +54 -0
- package/dist/components/StatTile.js.map +1 -0
- package/dist/components/agent-run.d.ts +147 -0
- package/dist/components/agent-run.d.ts.map +1 -0
- package/dist/components/agent-run.js +250 -0
- package/dist/components/agent-run.js.map +1 -0
- package/dist/components/index.d.ts +10 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.js +16 -0
- package/dist/components/index.js.map +1 -1
- package/dist/components/use-agent-run.d.ts +65 -0
- package/dist/components/use-agent-run.d.ts.map +1 -0
- package/dist/components/use-agent-run.js +127 -0
- package/dist/components/use-agent-run.js.map +1 -0
- package/dist/figma-descriptions.json +88 -63
- package/dist/figma-map.json +236 -2
- package/dist/meta/ChartLegend.json +125 -0
- package/dist/meta/ChartTooltip.json +126 -0
- package/dist/meta/SettingRow.json +102 -0
- package/dist/meta/StatGroup.json +65 -0
- package/dist/meta/StatTile.json +163 -0
- package/dist/meta/components.json +595 -1
- package/dist/meta/contrast.json +613 -1
- package/dist/meta/index.json +64 -1
- package/dist/meta/patterns/AgentRun.json +14 -0
- package/dist/meta/patterns/HumanApproval.json +4 -0
- package/dist/meta/patterns/SettingsPanel.json +2 -1
- package/dist/meta/patterns/index.json +4 -1
- package/dist/styles/chart.css +275 -0
- package/dist/styles/index.css +3 -0
- package/dist/styles/setting-row.css +58 -0
- package/dist/styles/stat-tile.css +66 -0
- package/dist/styles/tokens/base.css +36 -8
- package/dist/styles/tokens/theme-dark.css +12 -0
- package/dist/tokens/index.d.ts +193 -40
- package/dist/tokens/index.d.ts.map +1 -1
- package/dist/tokens/index.js +157 -32
- package/dist/tokens/index.js.map +1 -1
- package/eslint-plugin/meta-data.js +9 -0
- package/eslint-plugin/rules/needs-accessible-name.js +14 -1
- package/llms.txt +19 -2
- package/package.json +1 -1
package/dist/meta/index.json
CHANGED
|
@@ -1,10 +1,23 @@
|
|
|
1
1
|
{
|
|
2
2
|
"package": "ionbase-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.75.0",
|
|
4
4
|
"usage": "Pick a component here, then read dist/meta/<Name>.json for its full contract.",
|
|
5
5
|
"hooks": [
|
|
6
|
+
"useAgentRun",
|
|
6
7
|
"useToast"
|
|
7
8
|
],
|
|
9
|
+
"helpers": [
|
|
10
|
+
"agentRunFrom",
|
|
11
|
+
"agentRunHasEnded",
|
|
12
|
+
"agentRunLog",
|
|
13
|
+
"agentRunReducer",
|
|
14
|
+
"chartAxisProps",
|
|
15
|
+
"chartGridProps",
|
|
16
|
+
"chartSeriesClass",
|
|
17
|
+
"chartTooltipProps",
|
|
18
|
+
"initialAgentRunState",
|
|
19
|
+
"replayAgentRun"
|
|
20
|
+
],
|
|
8
21
|
"components": {
|
|
9
22
|
"Accordion": {
|
|
10
23
|
"summary": "Sections that collapse, with the document's heading structure intact. Holds the open set and the heading level.",
|
|
@@ -235,6 +248,25 @@
|
|
|
235
248
|
"detail": "dist/meta/Button.json",
|
|
236
249
|
"hasIntent": true
|
|
237
250
|
},
|
|
251
|
+
"ChartLegend": {
|
|
252
|
+
"summary": "Which colour is which series, for a chart drawn with visx. The swatch reads the same token as the series.",
|
|
253
|
+
"status": "stable",
|
|
254
|
+
"variants": {
|
|
255
|
+
"shape": [
|
|
256
|
+
"square",
|
|
257
|
+
"line"
|
|
258
|
+
]
|
|
259
|
+
},
|
|
260
|
+
"detail": "dist/meta/ChartLegend.json",
|
|
261
|
+
"hasIntent": true
|
|
262
|
+
},
|
|
263
|
+
"ChartTooltip": {
|
|
264
|
+
"summary": "The panel showing the values under the pointer on a visx chart. visx positions it; this draws it.",
|
|
265
|
+
"status": "stable",
|
|
266
|
+
"variants": {},
|
|
267
|
+
"detail": "dist/meta/ChartTooltip.json",
|
|
268
|
+
"hasIntent": true
|
|
269
|
+
},
|
|
238
270
|
"Checkbox": {
|
|
239
271
|
"summary": "A native checkbox with the system's styling, supporting an indeterminate state.",
|
|
240
272
|
"status": "stable",
|
|
@@ -705,6 +737,13 @@
|
|
|
705
737
|
"detail": "dist/meta/Select.json",
|
|
706
738
|
"hasIntent": true
|
|
707
739
|
},
|
|
740
|
+
"SettingRow": {
|
|
741
|
+
"summary": "One setting: its name and description on the left, the control on the right — and the control named and described by them automatically.",
|
|
742
|
+
"status": "stable",
|
|
743
|
+
"variants": {},
|
|
744
|
+
"detail": "dist/meta/SettingRow.json",
|
|
745
|
+
"hasIntent": true
|
|
746
|
+
},
|
|
708
747
|
"Sidebar": {
|
|
709
748
|
"summary": "An application's navigation as a column: pinned header and footer that take any component, a scrolling body of titled, collapsible sections, and nested items that expand.",
|
|
710
749
|
"status": "stable",
|
|
@@ -752,6 +791,30 @@
|
|
|
752
791
|
"detail": "dist/meta/Spinner.json",
|
|
753
792
|
"hasIntent": true
|
|
754
793
|
},
|
|
794
|
+
"StatGroup": {
|
|
795
|
+
"summary": "A row of StatTiles, as a description list. Wraps on its own — no breakpoints in the caller's code.",
|
|
796
|
+
"status": "stable",
|
|
797
|
+
"variants": {},
|
|
798
|
+
"detail": "dist/meta/StatGroup.json",
|
|
799
|
+
"hasIntent": true
|
|
800
|
+
},
|
|
801
|
+
"StatTile": {
|
|
802
|
+
"summary": "One headline figure and how it moved against a comparison period. Good and bad come from `goodWhen`, never from the sign alone.",
|
|
803
|
+
"status": "stable",
|
|
804
|
+
"variants": {
|
|
805
|
+
"changeUnit": [
|
|
806
|
+
"points",
|
|
807
|
+
"percent"
|
|
808
|
+
],
|
|
809
|
+
"goodWhen": [
|
|
810
|
+
"neutral",
|
|
811
|
+
"up",
|
|
812
|
+
"down"
|
|
813
|
+
]
|
|
814
|
+
},
|
|
815
|
+
"detail": "dist/meta/StatTile.json",
|
|
816
|
+
"hasIntent": true
|
|
817
|
+
},
|
|
755
818
|
"Stepper": {
|
|
756
819
|
"summary": "Where the user is in a task that has an order. An ordered list of steps, each stating its position and status in text.",
|
|
757
820
|
"status": "stable",
|
|
@@ -16,6 +16,20 @@
|
|
|
16
16
|
"Alert",
|
|
17
17
|
"Badge"
|
|
18
18
|
],
|
|
19
|
+
"drivenBy": {
|
|
20
|
+
"hook": "useAgentRun",
|
|
21
|
+
"note": "It turns the events a run reports into the props on AgentActivityStep (`status`), StreamingText (`outputProps`), AgentStop (`stopProps`) and ApprovalGate (`approvalProps`), and applies this pattern's states on the way: one active step, a stop keeps what was done and skips the rest, a failure marks the step that was running. It owns state, not markup or copy — which steps to show is `log`, and every sentence is yours. Feed it with `dispatch` from a live run or `replay(recording)` from a stored one; `agentRunFrom(events)` rebuilds a finished run without playing it.",
|
|
22
|
+
"events": [
|
|
23
|
+
"`run-started` — optionally with `steps: [{ id, label }]`, the plan, so steps the run never reaches can be named as not done",
|
|
24
|
+
"`step-started` { id, label? } — closes whichever step was active; exactly one is active at a time",
|
|
25
|
+
"`step-done` / `step-skipped` { id }",
|
|
26
|
+
"`step-failed` { id, error? }",
|
|
27
|
+
"`approval-requested` { id } — the step becomes the ApprovalGate; the run is `awaiting`",
|
|
28
|
+
"`approval-resolved` { id, decision: approved | rejected | expired, resolution? } — `expired` ends the run without acting",
|
|
29
|
+
"`output` { text } — appended; `output-done` ends streaming",
|
|
30
|
+
"`run-finished`, `run-failed` { error? }, `run-stopped` { resolution? } — the three ends a producer sends; after any end, later events are ignored"
|
|
31
|
+
]
|
|
32
|
+
},
|
|
19
33
|
"structure": [
|
|
20
34
|
"A header row carrying the task name and the AgentStop control. The stop is the first thing on screen and it stays there for the whole run.",
|
|
21
35
|
"An AgentActivity list of AgentActivityStep, one per step, in the order they happened. Exactly one step is `active` at a time.",
|
|
@@ -13,6 +13,10 @@
|
|
|
13
13
|
"AgentStop",
|
|
14
14
|
"Alert"
|
|
15
15
|
],
|
|
16
|
+
"drivenBy": {
|
|
17
|
+
"hook": "useAgentRun",
|
|
18
|
+
"note": "`approvalProps` carries the gate's `status`, `isSubmitting` and `resolution`, and `onApprove`/`onReject` when `onDecision` is given. A decision that throws stays pending with `state.approval.error` set — show it, because a decision the server never received must not look made. A stop or an expiry while pending resolves the gate as `expired`, never as approved."
|
|
19
|
+
},
|
|
16
20
|
"structure": [
|
|
17
21
|
"The gate appears in place, where the run reached it — inside the step log, not in a dialog that covers it.",
|
|
18
22
|
"The AgentActivityStep that is waiting stays `active`; the ApprovalGate is its `detail`.",
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
"the settings are grouped and the groups are worth naming"
|
|
7
7
|
],
|
|
8
8
|
"composes": [
|
|
9
|
+
"SettingRow",
|
|
9
10
|
"Toggle",
|
|
10
11
|
"Checkbox",
|
|
11
12
|
"RadioGroup",
|
|
@@ -21,7 +22,7 @@
|
|
|
21
22
|
],
|
|
22
23
|
"structure": [
|
|
23
24
|
"Named groups, separated by Divider, each with a heading.",
|
|
24
|
-
"One
|
|
25
|
+
"One SettingRow per setting: label and description on the left, control on the right, wired together by the row.",
|
|
25
26
|
"For save-on-submit panels, a save bar that appears only when something is dirty, with save and discard.",
|
|
26
27
|
"Tabs for panels large enough that a single scroll is unreasonable — but never with unsaved changes hidden behind an inactive tab."
|
|
27
28
|
],
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"package": "ionbase-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.75.0",
|
|
4
4
|
"usage": "A pattern is a documented composition of components, not a component. Read one here, then read the contracts of what it composes.",
|
|
5
5
|
"patterns": {
|
|
6
6
|
"AgentRun": {
|
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
"Alert",
|
|
16
16
|
"Badge"
|
|
17
17
|
],
|
|
18
|
+
"drivenBy": "useAgentRun",
|
|
18
19
|
"states": [
|
|
19
20
|
"loading",
|
|
20
21
|
"empty",
|
|
@@ -113,6 +114,7 @@
|
|
|
113
114
|
"AgentStop",
|
|
114
115
|
"Alert"
|
|
115
116
|
],
|
|
117
|
+
"drivenBy": "useAgentRun",
|
|
116
118
|
"states": [
|
|
117
119
|
"loading",
|
|
118
120
|
"empty",
|
|
@@ -147,6 +149,7 @@
|
|
|
147
149
|
"SettingsPanel": {
|
|
148
150
|
"summary": "Grouped settings that either apply immediately or are saved together — never both in one panel.",
|
|
149
151
|
"composes": [
|
|
152
|
+
"SettingRow",
|
|
150
153
|
"Toggle",
|
|
151
154
|
"Checkbox",
|
|
152
155
|
"RadioGroup",
|
|
@@ -0,0 +1,275 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Chart — styling for charts drawn with visx
|
|
3
|
+
*
|
|
4
|
+
* IonBase does not draw charts. visx does: it owns scales, shapes, axes and
|
|
5
|
+
* layout, and this file owns what they look like. Every rule is a class the
|
|
6
|
+
* product puts on a visx element — `chartAxisProps` and `chartGridProps` carry
|
|
7
|
+
* the axis and grid ones — so a chart themes with the page like everything
|
|
8
|
+
* else.
|
|
9
|
+
*
|
|
10
|
+
* CSS, NOT PROPS
|
|
11
|
+
*
|
|
12
|
+
* visx writes colour as SVG presentation attributes: `stroke="#222"` on an
|
|
13
|
+
* axis, `fill="#222"` and `font-family="Arial"` on a tick label, `#eaf0f6` on a
|
|
14
|
+
* grid line. A presentation attribute loses to any CSS declaration, so a class
|
|
15
|
+
* overrides all of them without a prop — and a CSS `var()` resolves in every
|
|
16
|
+
* browser, where a var() written into an attribute does not reliably.
|
|
17
|
+
*
|
|
18
|
+
* SERIES COLOUR IS ONE CUSTOM PROPERTY
|
|
19
|
+
*
|
|
20
|
+
* `.ion-chart-series-<n>` sets `--ion-chart-series` to `--chart-<n>`, and the
|
|
21
|
+
* line, area, bar, point and swatch rules read it. So a series is coloured in
|
|
22
|
+
* one place and its line, its points and its legend swatch cannot disagree —
|
|
23
|
+
* a legend that does not match its line is a chart that lies.
|
|
24
|
+
*/
|
|
25
|
+
|
|
26
|
+
.ion-chart {
|
|
27
|
+
display: grid;
|
|
28
|
+
gap: var(--spacing-12);
|
|
29
|
+
margin: 0;
|
|
30
|
+
min-width: 0;
|
|
31
|
+
font-family: var(--font-family-sans);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.ion-chart__caption {
|
|
35
|
+
color: var(--text-secondary);
|
|
36
|
+
font-size: var(--type-body-sm);
|
|
37
|
+
line-height: var(--type-body-sm-line-height);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
/* ---------------------------------------------------------------- axes */
|
|
41
|
+
|
|
42
|
+
/* Tabular figures, so tick values line up down a vertical axis. */
|
|
43
|
+
.ion-chart__tick {
|
|
44
|
+
fill: var(--text-tertiary);
|
|
45
|
+
font-family: var(--font-family-sans);
|
|
46
|
+
font-size: var(--type-caption);
|
|
47
|
+
font-variant-numeric: tabular-nums;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.ion-chart__axis-label {
|
|
51
|
+
fill: var(--text-secondary);
|
|
52
|
+
font-family: var(--font-family-sans);
|
|
53
|
+
font-size: var(--type-caption);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.ion-chart__axis-line,
|
|
57
|
+
.ion-chart__axis-tick line {
|
|
58
|
+
stroke: var(--border-default);
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
/* ---------------------------------------------------- gridlines, markers */
|
|
62
|
+
|
|
63
|
+
/* visx puts the class on the group; the lines inside inherit nothing. */
|
|
64
|
+
.ion-chart__grid line {
|
|
65
|
+
stroke: var(--border-subtle);
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
/* A target, a threshold, an average — a line the data is read against. */
|
|
69
|
+
.ion-chart__reference {
|
|
70
|
+
stroke: var(--border-stronger);
|
|
71
|
+
stroke-dasharray: 4 4;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.ion-chart__reference-label {
|
|
75
|
+
fill: var(--text-secondary);
|
|
76
|
+
font-family: var(--font-family-sans);
|
|
77
|
+
font-size: var(--type-caption);
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
/* The vertical rule under the pointer while a tooltip is open. */
|
|
81
|
+
.ion-chart__crosshair {
|
|
82
|
+
stroke: var(--border-strong);
|
|
83
|
+
pointer-events: none;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
/* -------------------------------------------------------------- series */
|
|
87
|
+
|
|
88
|
+
.ion-chart-series-1 {
|
|
89
|
+
--ion-chart-series: var(--chart-1);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.ion-chart-series-2 {
|
|
93
|
+
--ion-chart-series: var(--chart-2);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.ion-chart-series-3 {
|
|
97
|
+
--ion-chart-series: var(--chart-3);
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.ion-chart-series-4 {
|
|
101
|
+
--ion-chart-series: var(--chart-4);
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.ion-chart-series-5 {
|
|
105
|
+
--ion-chart-series: var(--chart-5);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.ion-chart-series-6 {
|
|
109
|
+
--ion-chart-series: var(--chart-6);
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
.ion-chart-series-7 {
|
|
113
|
+
--ion-chart-series: var(--chart-7);
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.ion-chart-series-8 {
|
|
117
|
+
--ion-chart-series: var(--chart-8);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
.ion-chart__line {
|
|
121
|
+
fill: none;
|
|
122
|
+
stroke: var(--ion-chart-series, var(--chart-1));
|
|
123
|
+
stroke-width: 2;
|
|
124
|
+
stroke-linejoin: round;
|
|
125
|
+
stroke-linecap: round;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
/*
|
|
129
|
+
* An area is the series at low opacity. The one place opacity is right: the
|
|
130
|
+
* fill sits behind its own full-strength line, which carries the 3:1 — the
|
|
131
|
+
* wash only says "this much".
|
|
132
|
+
*/
|
|
133
|
+
.ion-chart__area {
|
|
134
|
+
fill: var(--ion-chart-series, var(--chart-1));
|
|
135
|
+
fill-opacity: 0.16;
|
|
136
|
+
stroke: none;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
.ion-chart__bar {
|
|
140
|
+
fill: var(--ion-chart-series, var(--chart-1));
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
/* A hollow point, ringed in the series and filled with the ground. */
|
|
144
|
+
.ion-chart__point {
|
|
145
|
+
fill: var(--surface-default);
|
|
146
|
+
stroke: var(--ion-chart-series, var(--chart-1));
|
|
147
|
+
stroke-width: 2;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.ion-chart__point--active {
|
|
151
|
+
fill: var(--ion-chart-series, var(--chart-1));
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
/* ------------------------------------------------------------- heatmap */
|
|
155
|
+
|
|
156
|
+
.ion-chart__heat--0 {
|
|
157
|
+
fill: var(--surface-sunken);
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.ion-chart__heat--1 {
|
|
161
|
+
fill: var(--chart-sequential-1);
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
.ion-chart__heat--2 {
|
|
165
|
+
fill: var(--chart-sequential-2);
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
.ion-chart__heat--3 {
|
|
169
|
+
fill: var(--chart-sequential-3);
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
.ion-chart__heat--4 {
|
|
173
|
+
fill: var(--chart-sequential-4);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.ion-chart__heat--5 {
|
|
177
|
+
fill: var(--chart-sequential-5);
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
/* -------------------------------------------------------------- swatch */
|
|
181
|
+
|
|
182
|
+
/* A series key: a square for bars and areas, a short rule for lines. */
|
|
183
|
+
.ion-chart-swatch {
|
|
184
|
+
display: inline-block;
|
|
185
|
+
flex-shrink: 0;
|
|
186
|
+
width: 0.625rem;
|
|
187
|
+
height: 0.625rem;
|
|
188
|
+
border-radius: var(--radius-2xs);
|
|
189
|
+
background-color: var(--ion-chart-series, var(--chart-1));
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
.ion-chart-swatch--line {
|
|
193
|
+
height: 0.1875rem;
|
|
194
|
+
width: 0.875rem;
|
|
195
|
+
border-radius: var(--radius-full);
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
/* -------------------------------------------------------------- legend */
|
|
199
|
+
|
|
200
|
+
.ion-chart-legend {
|
|
201
|
+
display: flex;
|
|
202
|
+
flex-wrap: wrap;
|
|
203
|
+
gap: var(--spacing-4) var(--spacing-16);
|
|
204
|
+
margin: 0;
|
|
205
|
+
padding: 0;
|
|
206
|
+
list-style: none;
|
|
207
|
+
font-family: var(--font-family-sans);
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
.ion-chart-legend__item {
|
|
211
|
+
display: inline-flex;
|
|
212
|
+
align-items: center;
|
|
213
|
+
gap: var(--spacing-6);
|
|
214
|
+
color: var(--text-secondary);
|
|
215
|
+
font-size: var(--type-body-sm);
|
|
216
|
+
line-height: var(--type-body-sm-line-height);
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
/* ------------------------------------------------------------- tooltip */
|
|
220
|
+
|
|
221
|
+
/*
|
|
222
|
+
* The panel Popover and Toast use: raised, a subtle rim and the lg shadow, so
|
|
223
|
+
* a tooltip over a chart reads as the same family as every other floating
|
|
224
|
+
* surface. Pass visx's Tooltip `unstyled` and `applyPositionStyle` — this
|
|
225
|
+
* component is the box, visx only places it.
|
|
226
|
+
*/
|
|
227
|
+
.ion-chart-tooltip {
|
|
228
|
+
display: grid;
|
|
229
|
+
gap: var(--spacing-6);
|
|
230
|
+
min-width: 8rem;
|
|
231
|
+
max-width: 16rem;
|
|
232
|
+
padding: var(--spacing-8) var(--spacing-12);
|
|
233
|
+
border: var(--border-width-default) solid var(--border-subtle);
|
|
234
|
+
border-radius: var(--radius-md);
|
|
235
|
+
background-color: var(--surface-raised);
|
|
236
|
+
box-shadow: var(--ion-shadow-shadow-lg);
|
|
237
|
+
color: var(--text-default);
|
|
238
|
+
font-family: var(--font-family-sans);
|
|
239
|
+
font-size: var(--type-caption);
|
|
240
|
+
line-height: var(--type-caption-line-height);
|
|
241
|
+
pointer-events: none;
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
.ion-chart-tooltip__title {
|
|
245
|
+
color: var(--text-default);
|
|
246
|
+
font-weight: var(--font-weight-semibold);
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
.ion-chart-tooltip__rows {
|
|
250
|
+
display: grid;
|
|
251
|
+
gap: var(--spacing-4);
|
|
252
|
+
margin: 0;
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
.ion-chart-tooltip__row {
|
|
256
|
+
display: flex;
|
|
257
|
+
align-items: center;
|
|
258
|
+
justify-content: space-between;
|
|
259
|
+
gap: var(--spacing-12);
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
.ion-chart-tooltip__label {
|
|
263
|
+
display: inline-flex;
|
|
264
|
+
align-items: center;
|
|
265
|
+
gap: var(--spacing-6);
|
|
266
|
+
margin: 0;
|
|
267
|
+
color: var(--text-secondary);
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
.ion-chart-tooltip__value {
|
|
271
|
+
margin: 0;
|
|
272
|
+
color: var(--text-default);
|
|
273
|
+
font-weight: var(--font-weight-medium);
|
|
274
|
+
font-variant-numeric: tabular-nums;
|
|
275
|
+
}
|
package/dist/styles/index.css
CHANGED
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* SettingRow
|
|
3
|
+
*
|
|
4
|
+
* Promoted from the demo app's settings screen: the name and description on the
|
|
5
|
+
* left in `text/default` and `text/secondary`, the control on the right, 16px
|
|
6
|
+
* apart. The label is the Body/Default Semibold rung, the description a step
|
|
7
|
+
* down on body-sm.
|
|
8
|
+
*
|
|
9
|
+
* IT STACKS BY ITS OWN WIDTH
|
|
10
|
+
*
|
|
11
|
+
* The demo stacked the row below a 767px VIEWPORT, which is the wrong question:
|
|
12
|
+
* a settings row in a 360px drawer on a desktop is just as cramped as one on a
|
|
13
|
+
* phone. The row is a size container and the inner flex reads it, so it stacks
|
|
14
|
+
* wherever it is narrow. Container queries apply to descendants only, which is
|
|
15
|
+
* why there is an `__inner` at all.
|
|
16
|
+
*/
|
|
17
|
+
.ion-setting-row {
|
|
18
|
+
container-type: inline-size;
|
|
19
|
+
font-family: var(--font-family-sans);
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.ion-setting-row__inner {
|
|
23
|
+
display: flex;
|
|
24
|
+
align-items: center;
|
|
25
|
+
justify-content: space-between;
|
|
26
|
+
gap: var(--spacing-16);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.ion-setting-row__text {
|
|
30
|
+
display: grid;
|
|
31
|
+
gap: var(--spacing-2);
|
|
32
|
+
min-width: 0;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.ion-setting-row__label {
|
|
36
|
+
color: var(--text-default);
|
|
37
|
+
font-size: var(--type-body);
|
|
38
|
+
line-height: var(--type-body-line-height);
|
|
39
|
+
font-weight: var(--font-weight-semibold);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.ion-setting-row__description {
|
|
43
|
+
color: var(--text-secondary);
|
|
44
|
+
font-size: var(--type-body-sm);
|
|
45
|
+
line-height: var(--type-body-sm-line-height);
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.ion-setting-row__control {
|
|
49
|
+
flex-shrink: 0;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
@container (width < 30rem) {
|
|
53
|
+
.ion-setting-row__inner {
|
|
54
|
+
flex-direction: column;
|
|
55
|
+
align-items: flex-start;
|
|
56
|
+
gap: var(--spacing-8);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* StatTile, StatGroup
|
|
3
|
+
*
|
|
4
|
+
* Promoted from the demo app's Overview KPI row, where the measurements were
|
|
5
|
+
* settled against a real dashboard rather than invented here: a card on
|
|
6
|
+
* `surface/default` with a `border/subtle` rule and the `lg` radius, the label
|
|
7
|
+
* a rung down in `text/secondary`, the figure on the h4 rung, and the change as
|
|
8
|
+
* a small Badge beside a caption.
|
|
9
|
+
*
|
|
10
|
+
* THE GRID NEEDS NO BREAKPOINT
|
|
11
|
+
*
|
|
12
|
+
* `auto-fit` with a minimum tile width wraps on its own: four tiles in a row on
|
|
13
|
+
* a desktop, two on a phone. The minimum is `min(100%, 10rem)` so a single tile
|
|
14
|
+
* in a container narrower than 10rem shrinks instead of overflowing it.
|
|
15
|
+
*/
|
|
16
|
+
.ion-stat-group {
|
|
17
|
+
display: grid;
|
|
18
|
+
grid-template-columns: repeat(auto-fit, minmax(min(100%, 10rem), 1fr));
|
|
19
|
+
gap: var(--spacing-12);
|
|
20
|
+
margin: 0;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.ion-stat-tile {
|
|
24
|
+
display: grid;
|
|
25
|
+
align-content: start;
|
|
26
|
+
gap: var(--spacing-8);
|
|
27
|
+
padding: var(--spacing-16);
|
|
28
|
+
border: var(--border-width-default) solid var(--border-subtle);
|
|
29
|
+
border-radius: var(--radius-lg);
|
|
30
|
+
background-color: var(--surface-default);
|
|
31
|
+
font-family: var(--font-family-sans);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.ion-stat-tile__label {
|
|
35
|
+
color: var(--text-secondary);
|
|
36
|
+
font-size: var(--type-body-sm);
|
|
37
|
+
line-height: var(--type-body-sm-line-height);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.ion-stat-tile__body {
|
|
41
|
+
display: grid;
|
|
42
|
+
gap: var(--spacing-6);
|
|
43
|
+
margin: 0;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
/* Tabular figures, so a row of tiles lines its digits up as values change. */
|
|
47
|
+
.ion-stat-tile__value {
|
|
48
|
+
color: var(--text-default);
|
|
49
|
+
font-size: var(--type-h4);
|
|
50
|
+
line-height: var(--type-h4-line-height);
|
|
51
|
+
font-weight: var(--font-weight-semibold);
|
|
52
|
+
font-variant-numeric: tabular-nums;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.ion-stat-tile__change {
|
|
56
|
+
display: inline-flex;
|
|
57
|
+
flex-wrap: wrap;
|
|
58
|
+
align-items: center;
|
|
59
|
+
gap: var(--spacing-6);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.ion-stat-tile__comparison {
|
|
63
|
+
color: var(--text-tertiary);
|
|
64
|
+
font-size: var(--type-caption);
|
|
65
|
+
line-height: var(--type-caption-line-height);
|
|
66
|
+
}
|
|
@@ -214,14 +214,6 @@
|
|
|
214
214
|
--information-700: #4715b2;
|
|
215
215
|
--information-800: #350e8b;
|
|
216
216
|
--information-900: #260769;
|
|
217
|
-
--chart-1: #286ef0;
|
|
218
|
-
--chart-2: #14994e;
|
|
219
|
-
--chart-3: #4f3cc8;
|
|
220
|
-
--chart-4: #ea5600;
|
|
221
|
-
--chart-5: #df2679;
|
|
222
|
-
--chart-6: #a97a14;
|
|
223
|
-
--chart-7: #eb3737;
|
|
224
|
-
--chart-8: #6b7280;
|
|
225
217
|
--base-white: #ffffff;
|
|
226
218
|
--base-black: #000000;
|
|
227
219
|
--alpha-black-05: rgba(0, 0, 0, 0.05);
|
|
@@ -256,6 +248,8 @@
|
|
|
256
248
|
--palette-1-50: #f6f8f9;
|
|
257
249
|
--palette-1-200: #e5e7eb;
|
|
258
250
|
--palette-1-300: #dde0e4;
|
|
251
|
+
--palette-1-400: #9ca3b0;
|
|
252
|
+
--palette-1-500: #6b7280;
|
|
259
253
|
--palette-1-600: #4b5563;
|
|
260
254
|
--palette-1-700: #384252;
|
|
261
255
|
--palette-1-800: #1d2735;
|
|
@@ -263,6 +257,8 @@
|
|
|
263
257
|
--palette-2-50: #ebf7ff;
|
|
264
258
|
--palette-2-200: #c7e4fa;
|
|
265
259
|
--palette-2-300: #9fd5f9;
|
|
260
|
+
--palette-2-400: #609cf0;
|
|
261
|
+
--palette-2-500: #286ef0;
|
|
266
262
|
--palette-2-600: #1c62e3;
|
|
267
263
|
--palette-2-700: #1541b2;
|
|
268
264
|
--palette-2-800: #0e2d8b;
|
|
@@ -270,6 +266,8 @@
|
|
|
270
266
|
--palette-3-50: #f6f1f8;
|
|
271
267
|
--palette-3-200: #dfd4fc;
|
|
272
268
|
--palette-3-300: #adadf5;
|
|
269
|
+
--palette-3-400: #9a8ff4;
|
|
270
|
+
--palette-3-500: #786cdd;
|
|
273
271
|
--palette-3-600: #4f3cc8;
|
|
274
272
|
--palette-3-700: #4715b2;
|
|
275
273
|
--palette-3-800: #350e8b;
|
|
@@ -277,6 +275,8 @@
|
|
|
277
275
|
--palette-4-50: #fdf2f8;
|
|
278
276
|
--palette-4-200: #fbd0e8;
|
|
279
277
|
--palette-4-300: #f9a9d5;
|
|
278
|
+
--palette-4-400: #f773b7;
|
|
279
|
+
--palette-4-500: #df2679;
|
|
280
280
|
--palette-4-600: #c3135c;
|
|
281
281
|
--palette-4-700: #a0134b;
|
|
282
282
|
--palette-4-800: #881141;
|
|
@@ -284,6 +284,8 @@
|
|
|
284
284
|
--palette-5-50: #fff6ea;
|
|
285
285
|
--palette-5-200: #fedbb4;
|
|
286
286
|
--palette-5-300: #fdc17c;
|
|
287
|
+
--palette-5-400: #ef8539;
|
|
288
|
+
--palette-5-500: #ea5600;
|
|
287
289
|
--palette-5-600: #af3e0e;
|
|
288
290
|
--palette-5-700: #8e2f07;
|
|
289
291
|
--palette-5-800: #671f07;
|
|
@@ -291,6 +293,8 @@
|
|
|
291
293
|
--palette-6-50: #f8fefc;
|
|
292
294
|
--palette-6-200: #c6ebdc;
|
|
293
295
|
--palette-6-300: #82d8b4;
|
|
296
|
+
--palette-6-400: #39b378;
|
|
297
|
+
--palette-6-500: #14994e;
|
|
294
298
|
--palette-6-600: #0d7d38;
|
|
295
299
|
--palette-6-700: #076426;
|
|
296
300
|
--palette-6-800: #054d1a;
|
|
@@ -298,10 +302,21 @@
|
|
|
298
302
|
--palette-7-50: #fef1f1;
|
|
299
303
|
--palette-7-200: #fed2d2;
|
|
300
304
|
--palette-7-300: #ffadad;
|
|
305
|
+
--palette-7-400: #f56b6b;
|
|
306
|
+
--palette-7-500: #eb3737;
|
|
301
307
|
--palette-7-600: #c61616;
|
|
302
308
|
--palette-7-700: #ad1515;
|
|
303
309
|
--palette-7-800: #850e0e;
|
|
304
310
|
--palette-7-900: #650a0a;
|
|
311
|
+
--palette-8-50: #fefce7;
|
|
312
|
+
--palette-8-200: #faef9e;
|
|
313
|
+
--palette-8-300: #f0dc7a;
|
|
314
|
+
--palette-8-400: #eac534;
|
|
315
|
+
--palette-8-500: #c89809;
|
|
316
|
+
--palette-8-600: #a97a14;
|
|
317
|
+
--palette-8-700: #91700d;
|
|
318
|
+
--palette-8-800: #795a0c;
|
|
319
|
+
--palette-8-900: #6f4815;
|
|
305
320
|
--text-default: #131923;
|
|
306
321
|
--text-secondary: #384252;
|
|
307
322
|
--text-tertiary: #4b5563;
|
|
@@ -435,6 +450,19 @@
|
|
|
435
450
|
--ring-focus: #286ef0;
|
|
436
451
|
--ring-error: #eb3737;
|
|
437
452
|
--ring-offset: #ffffff;
|
|
453
|
+
--chart-1: #286ef0;
|
|
454
|
+
--chart-2: #14994e;
|
|
455
|
+
--chart-3: #4f3cc8;
|
|
456
|
+
--chart-4: #ea5600;
|
|
457
|
+
--chart-5: #df2679;
|
|
458
|
+
--chart-6: #a97a14;
|
|
459
|
+
--chart-7: #eb3737;
|
|
460
|
+
--chart-8: #6b7280;
|
|
461
|
+
--chart-sequential-1: #9fd5f9;
|
|
462
|
+
--chart-sequential-2: #609cf0;
|
|
463
|
+
--chart-sequential-3: #286ef0;
|
|
464
|
+
--chart-sequential-4: #1541b2;
|
|
465
|
+
--chart-sequential-5: #071e69;
|
|
438
466
|
--grid-margin: 80px;
|
|
439
467
|
--grid-gutter: 24px;
|
|
440
468
|
--grid-columns: 12;
|