@adobe/design-data-spec 4.8.0 → 4.9.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/conformance/README.md +32 -9
- package/conformance/invalid/SPEC-051/dataset.json +9 -3
- package/conformance/invalid/SPEC-052/dataset.json +14 -4
- package/conformance/invalid/SPEC-053/dataset.json +16 -4
- package/conformance/invalid/SPEC-054/dataset.json +18 -5
- package/conformance/invalid/SPEC-055/dataset.json +9 -3
- package/conformance/invalid/SPEC-057/dataset.json +5 -2
- package/conformance/invalid/SPEC-058/dataset.json +8 -3
- package/conformance/invalid/SPEC-059/dataset.json +28 -0
- package/conformance/invalid/SPEC-059/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-060/dataset.json +44 -0
- package/conformance/invalid/SPEC-060/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-061/dataset.json +63 -0
- package/conformance/invalid/SPEC-061/expected-errors.json +15 -0
- package/conformance/invalid/SPEC-062/dataset.json +50 -0
- package/conformance/invalid/SPEC-062/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-063/dataset.json +57 -0
- package/conformance/invalid/SPEC-063/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-064/dataset.json +53 -0
- package/conformance/invalid/SPEC-064/expected-errors.json +15 -0
- package/conformance/invalid/SPEC-065/dataset.json +78 -0
- package/conformance/invalid/SPEC-065/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-066/dataset.json +37 -0
- package/conformance/invalid/SPEC-066/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-067/dataset.json +60 -0
- package/conformance/invalid/SPEC-067/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-068/dataset.json +37 -0
- package/conformance/invalid/SPEC-068/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-069/dataset.json +63 -0
- package/conformance/invalid/SPEC-069/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-070/dataset.json +71 -0
- package/conformance/invalid/SPEC-070/expected-errors.json +15 -0
- package/conformance/invalid/SPEC-071/dataset.json +77 -0
- package/conformance/invalid/SPEC-071/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-072/dataset.json +52 -0
- package/conformance/invalid/SPEC-072/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-073/dataset.json +59 -0
- package/conformance/invalid/SPEC-073/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-074/dataset.json +36 -0
- package/conformance/invalid/SPEC-074/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-075/dataset.json +53 -0
- package/conformance/invalid/SPEC-075/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-076/dataset.json +62 -0
- package/conformance/invalid/SPEC-076/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-076/manifest.json +6 -0
- package/conformance/invalid/SPEC-079/dataset.json +62 -0
- package/conformance/invalid/SPEC-079/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-079/manifest.json +58 -0
- package/conformance/invalid/SPEC-080/dataset.json +62 -0
- package/conformance/invalid/SPEC-080/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-080/manifest.json +32 -0
- package/conformance/invalid/SPEC-081/dataset.json +62 -0
- package/conformance/invalid/SPEC-081/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-081/manifest.json +7 -0
- package/conformance/invalid/SPEC-082/dataset.json +62 -0
- package/conformance/invalid/SPEC-082/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-082/manifest.json +14 -0
- package/conformance/invalid/SPEC-083/dataset.json +47 -0
- package/conformance/invalid/SPEC-083/expected-errors.json +10 -0
- package/conformance/invalid/SPEC-084/dataset.json +16 -0
- package/conformance/invalid/SPEC-084/expected-errors.json +10 -0
- package/conformance/valid/SPEC-025/dataset.json +1 -1
- package/conformance/valid/SPEC-049/dataset.json +1 -1
- package/conformance/valid/SPEC-051/dataset.json +40 -9
- package/conformance/valid/SPEC-064/dataset.json +64 -0
- package/conformance/valid/SPEC-064/expected-errors.json +4 -0
- package/conformance/valid/SPEC-065/dataset.json +89 -0
- package/conformance/valid/SPEC-065/expected-errors.json +4 -0
- package/conformance/valid/SPEC-079/dataset.json +62 -0
- package/conformance/valid/SPEC-079/manifest.json +58 -0
- package/package.json +1 -1
- package/rules/rules.yaml +373 -0
- package/schemas/anatomy-part.schema.json +11 -0
- package/schemas/component-changelog.schema.json +306 -0
- package/schemas/component-spec-sheet.schema.json +215 -0
- package/schemas/component-visual.schema.json +287 -0
- package/schemas/component.schema.json +80 -0
- package/schemas/manifest.schema.json +5 -0
- package/schemas/relationship.schema.json +8 -6
- package/spec/anatomy-format.md +97 -10
- package/spec/artifact-moves.md +157 -0
- package/spec/component-changelog.md +49 -0
- package/spec/component-format.md +4 -0
- package/spec/component-visuals.md +210 -0
- package/spec/index.md +5 -0
- package/spec/manifest.md +46 -29
- package/spec/option-constraints.md +87 -0
- package/spec/relationship-format.md +14 -11
|
@@ -5,16 +5,23 @@
|
|
|
5
5
|
"component": "button",
|
|
6
6
|
"part": "label",
|
|
7
7
|
"property": "background-color",
|
|
8
|
-
"options": {
|
|
8
|
+
"options": {
|
|
9
|
+
"style": "fill",
|
|
10
|
+
"state": ["hover"]
|
|
11
|
+
}
|
|
9
12
|
},
|
|
10
13
|
"value": "#ff0000",
|
|
11
14
|
"uuid": "33333333-3333-3333-3333-333333333333",
|
|
12
15
|
"legacyKey": "button-label-background-color-fill-hover"
|
|
13
16
|
},
|
|
14
17
|
{
|
|
15
|
-
"scope": {
|
|
18
|
+
"scope": {
|
|
19
|
+
"component": "button",
|
|
20
|
+
"property": "border-color"
|
|
21
|
+
},
|
|
16
22
|
"context": "informative border color",
|
|
17
|
-
"$ref": "33333333-3333-3333-3333-333333333333"
|
|
23
|
+
"$ref": "33333333-3333-3333-3333-333333333333",
|
|
24
|
+
"uuid": "4e242f61-d33d-53e0-b6ae-c21ed87ab4d0"
|
|
18
25
|
}
|
|
19
26
|
],
|
|
20
27
|
"components": [
|
|
@@ -22,20 +29,44 @@
|
|
|
22
29
|
"$id": "https://opensource.adobe.com/spectrum-design-data/schemas/v0/components/button.json",
|
|
23
30
|
"name": "button",
|
|
24
31
|
"displayName": "Button",
|
|
25
|
-
"meta": {
|
|
32
|
+
"meta": {
|
|
33
|
+
"category": "actions"
|
|
34
|
+
},
|
|
26
35
|
"anatomy": [
|
|
27
|
-
{
|
|
28
|
-
|
|
36
|
+
{
|
|
37
|
+
"name": "icon",
|
|
38
|
+
"description": "Leading icon."
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"name": "label",
|
|
42
|
+
"description": "Button text.",
|
|
43
|
+
"required": true
|
|
44
|
+
}
|
|
29
45
|
],
|
|
30
46
|
"options": {
|
|
31
47
|
"style": {
|
|
32
48
|
"type": "enum",
|
|
33
|
-
"values": [
|
|
49
|
+
"values": [
|
|
50
|
+
{
|
|
51
|
+
"value": "fill"
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"value": "outline"
|
|
55
|
+
}
|
|
56
|
+
]
|
|
34
57
|
}
|
|
35
58
|
},
|
|
36
59
|
"states": [
|
|
37
|
-
{
|
|
38
|
-
|
|
60
|
+
{
|
|
61
|
+
"name": "hover",
|
|
62
|
+
"trigger": "interaction",
|
|
63
|
+
"precedence": 50
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
"name": "disabled",
|
|
67
|
+
"trigger": "prop",
|
|
68
|
+
"precedence": 100
|
|
69
|
+
}
|
|
39
70
|
]
|
|
40
71
|
}
|
|
41
72
|
]
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
{
|
|
2
|
+
"components": [
|
|
3
|
+
{
|
|
4
|
+
"$id": "https://opensource.adobe.com/spectrum-design-data/schemas/v0/components/button.json",
|
|
5
|
+
"name": "button",
|
|
6
|
+
"displayName": "Button",
|
|
7
|
+
"meta": {
|
|
8
|
+
"category": "actions"
|
|
9
|
+
},
|
|
10
|
+
"options": {
|
|
11
|
+
"variant": {
|
|
12
|
+
"type": "string",
|
|
13
|
+
"values": [
|
|
14
|
+
{
|
|
15
|
+
"value": "primary"
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
"value": "accent"
|
|
19
|
+
}
|
|
20
|
+
]
|
|
21
|
+
},
|
|
22
|
+
"style": {
|
|
23
|
+
"type": "string",
|
|
24
|
+
"values": [
|
|
25
|
+
{
|
|
26
|
+
"value": "fill"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"value": "outline"
|
|
30
|
+
}
|
|
31
|
+
]
|
|
32
|
+
},
|
|
33
|
+
"isLabelHidden": {
|
|
34
|
+
"type": "boolean"
|
|
35
|
+
},
|
|
36
|
+
"icon": {
|
|
37
|
+
"type": "string"
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
"constraints": [
|
|
41
|
+
{
|
|
42
|
+
"when": {
|
|
43
|
+
"style": "outline"
|
|
44
|
+
},
|
|
45
|
+
"require": {
|
|
46
|
+
"variant": ["primary"]
|
|
47
|
+
},
|
|
48
|
+
"severity": "error"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"when": {
|
|
52
|
+
"isLabelHidden": true
|
|
53
|
+
},
|
|
54
|
+
"require": {
|
|
55
|
+
"icon": {
|
|
56
|
+
"present": true
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
"severity": "error"
|
|
60
|
+
}
|
|
61
|
+
]
|
|
62
|
+
}
|
|
63
|
+
]
|
|
64
|
+
}
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
{
|
|
2
|
+
"components": [
|
|
3
|
+
{
|
|
4
|
+
"$id": "https://opensource.adobe.com/spectrum-design-data/schemas/v0/components/button.json",
|
|
5
|
+
"name": "button",
|
|
6
|
+
"displayName": "Button",
|
|
7
|
+
"meta": {
|
|
8
|
+
"category": "actions"
|
|
9
|
+
},
|
|
10
|
+
"options": {
|
|
11
|
+
"variant": {
|
|
12
|
+
"type": "string",
|
|
13
|
+
"values": [
|
|
14
|
+
{
|
|
15
|
+
"value": "primary"
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
"value": "accent"
|
|
19
|
+
}
|
|
20
|
+
]
|
|
21
|
+
},
|
|
22
|
+
"style": {
|
|
23
|
+
"type": "string",
|
|
24
|
+
"values": [
|
|
25
|
+
{
|
|
26
|
+
"value": "fill"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"value": "outline"
|
|
30
|
+
}
|
|
31
|
+
]
|
|
32
|
+
},
|
|
33
|
+
"isLabelHidden": {
|
|
34
|
+
"type": "boolean"
|
|
35
|
+
},
|
|
36
|
+
"icon": {
|
|
37
|
+
"type": "string"
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
"constraints": [
|
|
41
|
+
{
|
|
42
|
+
"when": {
|
|
43
|
+
"style": "outline"
|
|
44
|
+
},
|
|
45
|
+
"require": {
|
|
46
|
+
"variant": ["primary"]
|
|
47
|
+
},
|
|
48
|
+
"severity": "error"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"when": {
|
|
52
|
+
"isLabelHidden": true
|
|
53
|
+
},
|
|
54
|
+
"require": {
|
|
55
|
+
"icon": {
|
|
56
|
+
"present": true
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
"severity": "error"
|
|
60
|
+
}
|
|
61
|
+
]
|
|
62
|
+
}
|
|
63
|
+
],
|
|
64
|
+
"relationships": [
|
|
65
|
+
{
|
|
66
|
+
"scope": {
|
|
67
|
+
"component": "button",
|
|
68
|
+
"property": "background-color",
|
|
69
|
+
"options": {
|
|
70
|
+
"variant": "accent"
|
|
71
|
+
}
|
|
72
|
+
},
|
|
73
|
+
"value": "#ff0000",
|
|
74
|
+
"uuid": "180823cc-5404-54c9-97e8-a5c0a401cb09"
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
"scope": {
|
|
78
|
+
"component": "button",
|
|
79
|
+
"property": "background-color",
|
|
80
|
+
"options": {
|
|
81
|
+
"style": "outline",
|
|
82
|
+
"variant": "primary"
|
|
83
|
+
}
|
|
84
|
+
},
|
|
85
|
+
"value": "#ff0000",
|
|
86
|
+
"uuid": "f92bfa48-5e24-5603-8553-fa3c35efd784"
|
|
87
|
+
}
|
|
88
|
+
]
|
|
89
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
{
|
|
2
|
+
"tokens": [
|
|
3
|
+
{
|
|
4
|
+
"name": {
|
|
5
|
+
"property": "component-height-100"
|
|
6
|
+
},
|
|
7
|
+
"uuid": "76000000-0000-4000-8000-000000000001",
|
|
8
|
+
"value": "32px"
|
|
9
|
+
}
|
|
10
|
+
],
|
|
11
|
+
"components": [
|
|
12
|
+
{
|
|
13
|
+
"$id": "https://opensource.adobe.com/spectrum-design-data/schemas/v0/components/button.json",
|
|
14
|
+
"name": "button",
|
|
15
|
+
"displayName": "Button",
|
|
16
|
+
"meta": {
|
|
17
|
+
"category": "actions",
|
|
18
|
+
"documentationUrl": "https://spectrum.adobe.com/page/button/"
|
|
19
|
+
},
|
|
20
|
+
"anatomy": [
|
|
21
|
+
{
|
|
22
|
+
"name": "container",
|
|
23
|
+
"description": "Background.",
|
|
24
|
+
"required": true
|
|
25
|
+
}
|
|
26
|
+
],
|
|
27
|
+
"options": {
|
|
28
|
+
"size": {
|
|
29
|
+
"type": "string",
|
|
30
|
+
"default": "m",
|
|
31
|
+
"values": [
|
|
32
|
+
{
|
|
33
|
+
"value": "m"
|
|
34
|
+
}
|
|
35
|
+
]
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
],
|
|
40
|
+
"relationships": [],
|
|
41
|
+
"visuals": [
|
|
42
|
+
{
|
|
43
|
+
"component": "button",
|
|
44
|
+
"root": "container",
|
|
45
|
+
"sizeScale": {
|
|
46
|
+
"m": 100
|
|
47
|
+
},
|
|
48
|
+
"parts": {
|
|
49
|
+
"container": {
|
|
50
|
+
"kind": "box",
|
|
51
|
+
"props": {
|
|
52
|
+
"height": {
|
|
53
|
+
"token": {
|
|
54
|
+
"property": "component-height-100"
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
]
|
|
62
|
+
}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
{
|
|
2
|
+
"specVersion": "1.0.0-draft",
|
|
3
|
+
"platform": "fixture-resolves",
|
|
4
|
+
"foundationVersion": "3.7.0",
|
|
5
|
+
"extensions": {
|
|
6
|
+
"components": [
|
|
7
|
+
{
|
|
8
|
+
"name": "button-fixture",
|
|
9
|
+
"displayName": "Button fixture",
|
|
10
|
+
"meta": {
|
|
11
|
+
"category": "actions"
|
|
12
|
+
},
|
|
13
|
+
"anatomy": [
|
|
14
|
+
{
|
|
15
|
+
"name": "container",
|
|
16
|
+
"description": "Background.",
|
|
17
|
+
"required": true
|
|
18
|
+
}
|
|
19
|
+
],
|
|
20
|
+
"options": {
|
|
21
|
+
"size": {
|
|
22
|
+
"type": "string",
|
|
23
|
+
"default": "m",
|
|
24
|
+
"values": [
|
|
25
|
+
{
|
|
26
|
+
"value": "m"
|
|
27
|
+
}
|
|
28
|
+
]
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
],
|
|
33
|
+
"visuals": [
|
|
34
|
+
{
|
|
35
|
+
"file": "extensions/visuals/button-fixture.json",
|
|
36
|
+
"recipe": {
|
|
37
|
+
"component": "button-fixture",
|
|
38
|
+
"root": "container",
|
|
39
|
+
"sizeScale": {
|
|
40
|
+
"m": 100
|
|
41
|
+
},
|
|
42
|
+
"parts": {
|
|
43
|
+
"container": {
|
|
44
|
+
"kind": "box",
|
|
45
|
+
"props": {
|
|
46
|
+
"height": {
|
|
47
|
+
"token": {
|
|
48
|
+
"property": "component-height-100"
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
]
|
|
57
|
+
}
|
|
58
|
+
}
|
package/package.json
CHANGED