@gtivr4/a1-design-system-react 0.9.0 → 0.11.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/package.json +1 -1
- package/src/color-scheme.css +4 -0
- package/src/components/checkbox-group/checkbox-group.css +1 -1
- package/src/components/choice-group/choice-group.css +2 -2
- package/src/components/data-table/data-table.css +11 -0
- package/src/components/definition-list/DefinitionList.jsx +7 -4
- package/src/components/definition-list/definition-list.css +4 -3
- package/src/components/field/field.css +1 -1
- package/src/components/fieldset/fieldset.css +1 -1
- package/src/components/inline-editable/inline-editable.css +1 -1
- package/src/components/radio-group/radio-group.css +1 -1
- package/src/components/switch/switch.css +1 -1
- package/src/themes.css +1 -0
- package/src/tokens.css +1 -0
package/package.json
CHANGED
package/src/color-scheme.css
CHANGED
|
@@ -44,6 +44,7 @@ body {
|
|
|
44
44
|
color-scheme: dark;
|
|
45
45
|
--semantic-color-surface-page: var(--base-color-neutral-900);
|
|
46
46
|
--semantic-color-surface-card: var(--base-color-neutral-800);
|
|
47
|
+
--semantic-color-surface-field: var(--base-color-neutral-700);
|
|
47
48
|
--semantic-color-surface-panel: var(--base-color-neutral-800);
|
|
48
49
|
--semantic-color-surface-raised: var(--base-color-neutral-700);
|
|
49
50
|
--semantic-color-text-default: var(--base-color-neutral-50);
|
|
@@ -277,6 +278,7 @@ html.a1-theme-dark {
|
|
|
277
278
|
color-scheme: dark;
|
|
278
279
|
--semantic-color-surface-page: var(--base-color-neutral-900);
|
|
279
280
|
--semantic-color-surface-card: var(--base-color-neutral-800);
|
|
281
|
+
--semantic-color-surface-field: var(--base-color-neutral-700);
|
|
280
282
|
--semantic-color-surface-panel: var(--base-color-neutral-800);
|
|
281
283
|
--semantic-color-surface-raised: var(--base-color-neutral-700);
|
|
282
284
|
--semantic-color-text-default: var(--base-color-neutral-50);
|
|
@@ -353,6 +355,7 @@ html.a1-theme-dark .a1-theme-light {
|
|
|
353
355
|
color-scheme: light;
|
|
354
356
|
--semantic-color-surface-page: var(--base-color-neutral-0);
|
|
355
357
|
--semantic-color-surface-card: var(--base-color-neutral-0);
|
|
358
|
+
--semantic-color-surface-field: var(--base-color-neutral-0);
|
|
356
359
|
--semantic-color-surface-panel: var(--base-color-neutral-50);
|
|
357
360
|
--semantic-color-surface-raised: var(--base-color-neutral-100);
|
|
358
361
|
--semantic-color-text-default: var(--base-color-neutral-900);
|
|
@@ -517,6 +520,7 @@ html.a1-theme-light {
|
|
|
517
520
|
html.a1-theme-light .a1-inverse {
|
|
518
521
|
color-scheme: dark;
|
|
519
522
|
--semantic-color-surface-page: var(--base-color-neutral-900);
|
|
523
|
+
--semantic-color-surface-field: var(--base-color-neutral-700);
|
|
520
524
|
--semantic-color-surface-panel: var(--base-color-neutral-800);
|
|
521
525
|
--semantic-color-surface-raised: var(--base-color-neutral-700);
|
|
522
526
|
--semantic-color-text-default: var(--base-color-neutral-50);
|
|
@@ -177,7 +177,7 @@
|
|
|
177
177
|
margin-top: var(--a1-cb-input-nudge);
|
|
178
178
|
border: var(--component-field-border-width) solid var(--semantic-color-border-strong);
|
|
179
179
|
border-radius: var(--a1-cb-radius);
|
|
180
|
-
background-color: var(--semantic-color-surface-
|
|
180
|
+
background-color: var(--semantic-color-surface-field);
|
|
181
181
|
cursor: pointer;
|
|
182
182
|
transition:
|
|
183
183
|
border-color var(--semantic-motion-duration-fast),
|
|
@@ -161,7 +161,7 @@
|
|
|
161
161
|
padding-inline-start: calc(var(--a1-cg-padding) + var(--a1-cg-indicator-size) + var(--base-spacing-8));
|
|
162
162
|
border: var(--component-choice-group-border-width) solid var(--semantic-color-border-subtle);
|
|
163
163
|
border-radius: var(--component-choice-group-border-radius);
|
|
164
|
-
background-color: var(--semantic-color-surface-
|
|
164
|
+
background-color: var(--semantic-color-surface-field);
|
|
165
165
|
cursor: pointer;
|
|
166
166
|
transition:
|
|
167
167
|
border-color var(--semantic-motion-duration-fast) var(--semantic-motion-easing-standard),
|
|
@@ -271,7 +271,7 @@
|
|
|
271
271
|
width: var(--a1-cg-indicator-size);
|
|
272
272
|
height: var(--a1-cg-indicator-size);
|
|
273
273
|
border: 1.5px solid var(--semantic-color-border-default);
|
|
274
|
-
background-color: var(--semantic-color-surface-
|
|
274
|
+
background-color: var(--semantic-color-surface-field);
|
|
275
275
|
background-repeat: no-repeat;
|
|
276
276
|
background-position: center;
|
|
277
277
|
transition:
|
|
@@ -433,4 +433,15 @@
|
|
|
433
433
|
flex-direction: column;
|
|
434
434
|
align-items: flex-start;
|
|
435
435
|
}
|
|
436
|
+
|
|
437
|
+
/* Notice rows span the full card width — suppress the column-label ::before
|
|
438
|
+
and reset td to block so the content fills edge-to-edge. */
|
|
439
|
+
.a1-data-table__notice-row td {
|
|
440
|
+
display: block;
|
|
441
|
+
padding: 0;
|
|
442
|
+
}
|
|
443
|
+
|
|
444
|
+
.a1-data-table__notice-row td::before {
|
|
445
|
+
display: none;
|
|
446
|
+
}
|
|
436
447
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Children, isValidElement, useEffect, useMemo, useRef, useState } from "react";
|
|
2
|
+
import { Button } from "../button/Button.jsx";
|
|
2
3
|
import { Heading } from "../heading/Heading.jsx";
|
|
3
|
-
import { IconButton } from "../icon-button/IconButton.jsx";
|
|
4
4
|
import "./definition-list.css";
|
|
5
5
|
|
|
6
6
|
const directions = ["row", "column"];
|
|
@@ -86,13 +86,16 @@ function DefinitionCopyButton({ text, label = "Copy value", copiedLabel = "Copie
|
|
|
86
86
|
}
|
|
87
87
|
|
|
88
88
|
return (
|
|
89
|
-
<
|
|
89
|
+
<Button
|
|
90
90
|
className="a1-definition-list__copy"
|
|
91
91
|
icon={copied ? "check" : "content_copy"}
|
|
92
|
-
label={copied ? copiedLabel : label}
|
|
93
92
|
onClick={handleCopy}
|
|
93
|
+
size="sm"
|
|
94
|
+
type="button"
|
|
94
95
|
variant="tertiary"
|
|
95
|
-
|
|
96
|
+
>
|
|
97
|
+
{copied ? copiedLabel : label}
|
|
98
|
+
</Button>
|
|
96
99
|
);
|
|
97
100
|
}
|
|
98
101
|
|
|
@@ -52,7 +52,8 @@
|
|
|
52
52
|
}
|
|
53
53
|
|
|
54
54
|
.a1-definition-list__copy {
|
|
55
|
-
|
|
55
|
+
flex: 0 0 auto;
|
|
56
|
+
margin-block-start: calc((1lh - var(--component-button-small-height)) / 2);
|
|
56
57
|
}
|
|
57
58
|
|
|
58
59
|
.a1-definition-list--column {
|
|
@@ -99,10 +100,10 @@
|
|
|
99
100
|
}
|
|
100
101
|
|
|
101
102
|
.a1-definition-list__value-content {
|
|
102
|
-
flex:
|
|
103
|
+
flex: 0 1 auto;
|
|
103
104
|
}
|
|
104
105
|
|
|
105
|
-
@container (max-width:
|
|
106
|
+
@container (max-width: 240px) {
|
|
106
107
|
.a1-definition-list--row .a1-definition-list__item {
|
|
107
108
|
display: flex;
|
|
108
109
|
flex-direction: column;
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
--a1-field-accent-compensation: var(--component-field-accent-compensation);
|
|
17
17
|
|
|
18
18
|
/* interaction — hover/active/readonly values come from :root in color-scheme.css */
|
|
19
|
-
--a1-field-background: var(--semantic-color-surface-
|
|
19
|
+
--a1-field-background: var(--semantic-color-surface-field);
|
|
20
20
|
--a1-field-border-color: var(--semantic-color-border-strong);
|
|
21
21
|
--a1-field-focus-ring-color: var(--component-field-focus-ring-color);
|
|
22
22
|
--a1-field-focus-ring-width: var(--component-field-focus-ring-width);
|
|
@@ -51,7 +51,7 @@
|
|
|
51
51
|
/* ─── Surface variant ────────────────────────────────────────────────────── */
|
|
52
52
|
|
|
53
53
|
.a1-fieldset--surface {
|
|
54
|
-
background: var(--semantic-color-surface-
|
|
54
|
+
background: var(--semantic-color-surface-card);
|
|
55
55
|
border: var(--component-card-border-width) solid var(--semantic-color-border-subtle);
|
|
56
56
|
border-radius: var(--component-card-border-radius);
|
|
57
57
|
box-shadow: var(--component-card-shadow);
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
display: block;
|
|
30
30
|
width: 100%;
|
|
31
31
|
min-height: 2em;
|
|
32
|
-
background: var(--semantic-color-surface-
|
|
32
|
+
background: var(--semantic-color-surface-field);
|
|
33
33
|
border: 1px solid var(--semantic-color-border-strong);
|
|
34
34
|
border-radius: var(--base-border-radius-sm);
|
|
35
35
|
padding: var(--base-spacing-4) var(--base-spacing-8);
|
|
@@ -174,7 +174,7 @@
|
|
|
174
174
|
margin-top: var(--a1-rb-input-nudge);
|
|
175
175
|
border: var(--component-field-border-width) solid var(--semantic-color-border-strong);
|
|
176
176
|
border-radius: 50%;
|
|
177
|
-
background-color: var(--semantic-color-surface-
|
|
177
|
+
background-color: var(--semantic-color-surface-field);
|
|
178
178
|
cursor: pointer;
|
|
179
179
|
transition:
|
|
180
180
|
border-color var(--semantic-motion-duration-fast),
|
|
@@ -150,7 +150,7 @@
|
|
|
150
150
|
height: var(--a1-sw-track-height);
|
|
151
151
|
border-radius: var(--a1-sw-track-height);
|
|
152
152
|
border: var(--component-field-border-width) solid var(--semantic-color-border-strong);
|
|
153
|
-
background-color: var(--semantic-color-surface-
|
|
153
|
+
background-color: var(--semantic-color-surface-field);
|
|
154
154
|
cursor: pointer;
|
|
155
155
|
transition:
|
|
156
156
|
background-color var(--semantic-motion-duration-normal) var(--semantic-motion-easing-standard),
|
package/src/themes.css
CHANGED
|
@@ -365,6 +365,7 @@ html.a1-theme-fresh {
|
|
|
365
365
|
--semantic-color-text-accent: var(--base-color-accent-600);
|
|
366
366
|
--semantic-color-surface-page: #D7FFF8;
|
|
367
367
|
--semantic-color-surface-card: var(--base-color-neutral-0);
|
|
368
|
+
--semantic-color-surface-field: var(--base-color-neutral-0);
|
|
368
369
|
--semantic-color-surface-panel: var(--base-color-neutral-0);
|
|
369
370
|
--semantic-color-surface-raised: var(--base-color-neutral-50);
|
|
370
371
|
--semantic-color-border-subtle: var(--base-color-neutral-200);
|
package/src/tokens.css
CHANGED
|
@@ -183,6 +183,7 @@
|
|
|
183
183
|
--semantic-color-text-accent: #7c3aed;
|
|
184
184
|
--semantic-color-surface-page: #ffffff;
|
|
185
185
|
--semantic-color-surface-card: #ffffff;
|
|
186
|
+
--semantic-color-surface-field: #ffffff;
|
|
186
187
|
--semantic-color-surface-panel: #f0f6fe;
|
|
187
188
|
--semantic-color-surface-raised: #e1e8f3;
|
|
188
189
|
--semantic-color-surface-inverse: #060b14;
|