@atlaskit/eslint-plugin-design-system 4.12.3 → 4.12.4
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/CHANGELOG.md +6 -0
- package/dist/cjs/rules/ensure-design-token-usage-spacing/index.js +9 -2
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/rules/ensure-design-token-usage-spacing/index.js +9 -2
- package/dist/es2019/version.json +1 -1
- package/dist/esm/rules/ensure-design-token-usage-spacing/index.js +9 -2
- package/dist/esm/version.json +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @atlaskit/eslint-plugin-design-system
|
|
2
2
|
|
|
3
|
+
## 4.12.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`bc989043572`](https://bitbucket.org/atlassian/atlassian-frontend/commits/bc989043572) - Internal changes to apply spacing tokens. This should be a no-op change.
|
|
8
|
+
|
|
3
9
|
## 4.12.3
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
|
@@ -102,11 +102,16 @@ var rule = {
|
|
|
102
102
|
var fontSizeValue = (0, _utils.getValue)( // @ts-ignore
|
|
103
103
|
(0, _eslintCodemodUtils.isNodeOfType)(fontSizeNode, 'Property') && fontSizeNode.value, context);
|
|
104
104
|
var fontSize = Array.isArray(fontSizeValue) ? fontSizeValue[0] : fontSizeValue;
|
|
105
|
-
|
|
105
|
+
|
|
106
|
+
function findObjectStyles(node) {
|
|
106
107
|
if (!(0, _eslintCodemodUtils.isNodeOfType)(node, 'Property')) {
|
|
107
108
|
return;
|
|
108
109
|
}
|
|
109
110
|
|
|
111
|
+
if ((0, _eslintCodemodUtils.isNodeOfType)(node.value, 'ObjectExpression')) {
|
|
112
|
+
return node.value.properties.forEach(findObjectStyles);
|
|
113
|
+
}
|
|
114
|
+
|
|
110
115
|
if (!(0, _eslintCodemodUtils.isNodeOfType)(node.key, 'Identifier')) {
|
|
111
116
|
return;
|
|
112
117
|
}
|
|
@@ -213,7 +218,9 @@ var rule = {
|
|
|
213
218
|
} : undefined
|
|
214
219
|
});
|
|
215
220
|
});
|
|
216
|
-
}
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
parentNode.properties.forEach(findObjectStyles);
|
|
217
224
|
},
|
|
218
225
|
// CSSTemplateLiteral and StyledTemplateLiteral
|
|
219
226
|
// const cssTemplateLiteral = css`color: red; padding: 12px`;
|
package/dist/cjs/version.json
CHANGED
|
@@ -72,11 +72,16 @@ const rule = {
|
|
|
72
72
|
const fontSizeValue = getValue( // @ts-ignore
|
|
73
73
|
isNodeOfType(fontSizeNode, 'Property') && fontSizeNode.value, context);
|
|
74
74
|
const fontSize = Array.isArray(fontSizeValue) ? fontSizeValue[0] : fontSizeValue;
|
|
75
|
-
|
|
75
|
+
|
|
76
|
+
function findObjectStyles(node) {
|
|
76
77
|
if (!isNodeOfType(node, 'Property')) {
|
|
77
78
|
return;
|
|
78
79
|
}
|
|
79
80
|
|
|
81
|
+
if (isNodeOfType(node.value, 'ObjectExpression')) {
|
|
82
|
+
return node.value.properties.forEach(findObjectStyles);
|
|
83
|
+
}
|
|
84
|
+
|
|
80
85
|
if (!isNodeOfType(node.key, 'Identifier')) {
|
|
81
86
|
return;
|
|
82
87
|
}
|
|
@@ -179,7 +184,9 @@ const rule = {
|
|
|
179
184
|
} : undefined
|
|
180
185
|
});
|
|
181
186
|
});
|
|
182
|
-
}
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
parentNode.properties.forEach(findObjectStyles);
|
|
183
190
|
},
|
|
184
191
|
// CSSTemplateLiteral and StyledTemplateLiteral
|
|
185
192
|
// const cssTemplateLiteral = css`color: red; padding: 12px`;
|
package/dist/es2019/version.json
CHANGED
|
@@ -88,11 +88,16 @@ var rule = {
|
|
|
88
88
|
var fontSizeValue = getValue( // @ts-ignore
|
|
89
89
|
isNodeOfType(fontSizeNode, 'Property') && fontSizeNode.value, context);
|
|
90
90
|
var fontSize = Array.isArray(fontSizeValue) ? fontSizeValue[0] : fontSizeValue;
|
|
91
|
-
|
|
91
|
+
|
|
92
|
+
function findObjectStyles(node) {
|
|
92
93
|
if (!isNodeOfType(node, 'Property')) {
|
|
93
94
|
return;
|
|
94
95
|
}
|
|
95
96
|
|
|
97
|
+
if (isNodeOfType(node.value, 'ObjectExpression')) {
|
|
98
|
+
return node.value.properties.forEach(findObjectStyles);
|
|
99
|
+
}
|
|
100
|
+
|
|
96
101
|
if (!isNodeOfType(node.key, 'Identifier')) {
|
|
97
102
|
return;
|
|
98
103
|
}
|
|
@@ -199,7 +204,9 @@ var rule = {
|
|
|
199
204
|
} : undefined
|
|
200
205
|
});
|
|
201
206
|
});
|
|
202
|
-
}
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
parentNode.properties.forEach(findObjectStyles);
|
|
203
210
|
},
|
|
204
211
|
// CSSTemplateLiteral and StyledTemplateLiteral
|
|
205
212
|
// const cssTemplateLiteral = css`color: red; padding: 12px`;
|
package/dist/esm/version.json
CHANGED
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/eslint-plugin-design-system",
|
|
3
3
|
"description": "The essential plugin for use with the Atlassian Design System.",
|
|
4
|
-
"version": "4.12.
|
|
4
|
+
"version": "4.12.4",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"registry": "https://registry.npmjs.org/"
|