@atlaskit/eslint-plugin-ui-styling-standard 1.0.1 → 1.0.2
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/README.md +17 -17
- package/dist/cjs/rules/convert-props-syntax/index.js +3 -3
- package/dist/cjs/rules/no-container-queries/index.js +3 -1
- package/dist/cjs/rules/no-dynamic-styles/index.js +1 -1
- package/dist/cjs/rules/no-exported-styles/index.js +4 -2
- package/dist/cjs/rules/no-imported-style-values/index.js +2 -1
- package/dist/cjs/rules/no-unsafe-values/index.js +4 -2
- package/dist/es2019/rules/convert-props-syntax/index.js +3 -3
- package/dist/es2019/rules/no-container-queries/index.js +3 -1
- package/dist/es2019/rules/no-dynamic-styles/index.js +2 -0
- package/dist/es2019/rules/no-exported-styles/index.js +4 -2
- package/dist/es2019/rules/no-imported-style-values/index.js +4 -0
- package/dist/es2019/rules/no-unsafe-values/index.js +4 -2
- package/dist/esm/rules/convert-props-syntax/index.js +3 -3
- package/dist/esm/rules/no-container-queries/index.js +3 -1
- package/dist/esm/rules/no-dynamic-styles/index.js +2 -0
- package/dist/esm/rules/no-exported-styles/index.js +4 -2
- package/dist/esm/rules/no-imported-style-values/index.js +4 -0
- package/dist/esm/rules/no-unsafe-values/index.js +4 -2
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -42,23 +42,23 @@ module.exports = {
|
|
|
42
42
|
|
|
43
43
|
| Rule | Description | Recommended | Fixable | Suggestions |
|
|
44
44
|
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ----------- | ------- | ----------- |
|
|
45
|
-
| <a href="./src/rules/atlaskit-theme/README.md">atlaskit-theme</a>
|
|
46
|
-
| <a href="./src/rules/convert-props-syntax/README.md">convert-props-syntax</a>
|
|
47
|
-
| <a href="./src/rules/enforce-style-prop/README.md">enforce-style-prop</a>
|
|
48
|
-
| <a href="./src/rules/local-cx-xcss/README.md">local-cx-xcss</a>
|
|
49
|
-
| <a href="./src/rules/no-array-arguments/README.md">no-array-arguments</a>
|
|
50
|
-
| <a href="./src/rules/no-classname-prop/README.md">no-classname-prop</a>
|
|
51
|
-
| <a href="./src/rules/no-container-queries/README.md">no-container-queries</a>
|
|
52
|
-
| <a href="./src/rules/no-dynamic-styles/README.md">no-dynamic-styles</a>
|
|
53
|
-
| <a href="./src/rules/no-exported-styles/README.md">no-exported-styles</a>
|
|
54
|
-
| <a href="./src/rules/no-global-styles/README.md">no-global-styles</a>
|
|
55
|
-
| <a href="./src/rules/no-important-styles/README.md">no-important-styles</a>
|
|
56
|
-
| <a href="./src/rules/no-imported-style-values/README.md">no-imported-style-values</a>
|
|
57
|
-
| <a href="./src/rules/no-nested-selectors/README.md">no-nested-selectors</a>
|
|
58
|
-
| <a href="./src/rules/no-styled/README.md">no-styled</a>
|
|
59
|
-
| <a href="./src/rules/no-unsafe-selectors/README.md">no-unsafe-selectors</a>
|
|
60
|
-
| <a href="./src/rules/no-unsafe-values/README.md">no-unsafe-values</a>
|
|
61
|
-
| <a href="./src/rules/use-compiled/README.md">use-compiled</a>
|
|
45
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/atlaskit-theme/README.md">atlaskit-theme</a> | Ban certain usages of `@atlaskit/theme` that `@compiled/react` does not understand | Yes | | |
|
|
46
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/convert-props-syntax/README.md">convert-props-syntax</a> | Convert props syntax that is unsupported by styled-components@<4 or @emotion/styled to props syntax that is supported. This is useful when used in conjunction with `no-styled-tagged-template-expression`, as output from the latter may use props syntax unsupported by those libraries. | Yes | Yes | |
|
|
47
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/enforce-style-prop/README.md">enforce-style-prop</a> | Disallows usage of static styles in the `style` attribute in components | Yes | | |
|
|
48
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/local-cx-xcss/README.md">local-cx-xcss</a> | Ensures the cx() function, which is part of the XCSS API, is only used within the xcss prop. This aids tracking what styles are applied to a jsx element. | Yes | | |
|
|
49
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/no-array-arguments/README.md">no-array-arguments</a> | Prevents usage of array arguments to style declaration functions | Yes | Yes | |
|
|
50
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/no-classname-prop/README.md">no-classname-prop</a> | Disallows usage of the `className` prop in JSX | Yes | | |
|
|
51
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/no-container-queries/README.md">no-container-queries</a> | Prevents usage of @container query within css styling | Yes | | |
|
|
52
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/no-dynamic-styles/README.md">no-dynamic-styles</a> | Disallows use of dynamic styles in CSS-in-JS calls | Yes | | |
|
|
53
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/no-exported-styles/README.md">no-exported-styles</a> | Disallows exports of css, keyframes, styled and xcss | Yes | | |
|
|
54
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/no-global-styles/README.md">no-global-styles</a> | Prevents global styles through CSS-in-JS or CSS module imports | Yes | | |
|
|
55
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/no-important-styles/README.md">no-important-styles</a> | Disallows important style declarations | Yes | | |
|
|
56
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/no-imported-style-values/README.md">no-imported-style-values</a> | Disallows imports of style values | Yes | | |
|
|
57
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/no-nested-selectors/README.md">no-nested-selectors</a> | Prevents usage of nested selectors within css styling | Yes | | |
|
|
58
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/no-styled/README.md">no-styled</a> | Disallows usage of the `styled` imports | Yes | | |
|
|
59
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/no-unsafe-selectors/README.md">no-unsafe-selectors</a> | Disallows use of nested styles in `css` functions. | Yes | Yes | Yes |
|
|
60
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/no-unsafe-values/README.md">no-unsafe-values</a> | Disallows styles that are difficult/impossible to statically anaylze. | Yes | | |
|
|
61
|
+
| <a href="./packages/design-system/eslint-plugin-ui-styling-standard/src/rules/use-compiled/README.md">use-compiled</a> | Ensures usage of `@compiled/react` instead of other CSS-in-JS libraries | Yes | Yes | |
|
|
62
62
|
| <a href="https://atlassian.design/components/eslint-plugin-ui-styling-standard/consistent-css-prop-usage/usage">@atlaskit/design-system/consistent-css-prop-usage</a> | Ensures consistency with `css` and `xcss` prop usages | Yes | Yes | |
|
|
63
63
|
| <a href="https://atlassian.design/components/eslint-plugin-ui-styling-standard/no-css-tagged-template-expression/usage">@atlaskit/design-system/no-css-tagged-template-expression</a> | Disallows any `css` tagged template expressions that originate from Emotion, Styled Components or Compiled | Yes | Yes | |
|
|
64
64
|
| <a href="https://atlassian.design/components/eslint-plugin-ui-styling-standard/no-keyframes-tagged-template-expression/usage">@atlaskit/design-system/no-keyframes-tagged-template-expression</a> | Disallows any `keyframe` tagged template expressions that originate from Emotion, Styled Components or Compiled | Yes | Yes | |
|
|
@@ -5,11 +5,11 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
7
|
exports.rule = exports.default = void 0;
|
|
8
|
+
var _eslintCodemodUtils = require("eslint-codemod-utils");
|
|
8
9
|
var _eslintScope = require("eslint-scope");
|
|
9
|
-
var _createRule = require("../utils/create-rule");
|
|
10
|
-
var _isSupportedImport = require("@atlaskit/eslint-utils/is-supported-import");
|
|
11
10
|
var _estraverse = _interopRequireDefault(require("estraverse"));
|
|
12
|
-
var
|
|
11
|
+
var _isSupportedImport = require("@atlaskit/eslint-utils/is-supported-import");
|
|
12
|
+
var _createRule = require("../utils/create-rule");
|
|
13
13
|
function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t.return || t.return(); } finally { if (u) throw o; } } }; }
|
|
14
14
|
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
15
15
|
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
@@ -6,8 +6,10 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports.rule = exports.default = void 0;
|
|
8
8
|
var _estraverse = _interopRequireDefault(require("estraverse"));
|
|
9
|
-
var _createRule = require("../utils/create-rule");
|
|
10
9
|
var _isSupportedImport = require("@atlaskit/eslint-utils/is-supported-import");
|
|
10
|
+
var _createRule = require("../utils/create-rule");
|
|
11
|
+
/* eslint-disable @atlassian/tangerine/import/entry-points */
|
|
12
|
+
|
|
11
13
|
var schema = [{
|
|
12
14
|
type: 'object',
|
|
13
15
|
properties: {
|
|
@@ -10,7 +10,7 @@ var _isSupportedImport = require("@atlaskit/eslint-utils/is-supported-import");
|
|
|
10
10
|
var _createRule = require("../utils/create-rule");
|
|
11
11
|
function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t.return || t.return(); } finally { if (u) throw o; } } }; }
|
|
12
12
|
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
13
|
-
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
13
|
+
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; } // eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
14
14
|
var schema = [{
|
|
15
15
|
type: 'object',
|
|
16
16
|
properties: {
|
|
@@ -4,9 +4,11 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.rule = exports.default = void 0;
|
|
7
|
-
var _createRule = require("../utils/create-rule");
|
|
8
|
-
var _isSupportedImport = require("@atlaskit/eslint-utils/is-supported-import");
|
|
9
7
|
var _createNoExportedRule = require("@atlaskit/eslint-utils/create-no-exported-rule");
|
|
8
|
+
var _isSupportedImport = require("@atlaskit/eslint-utils/is-supported-import");
|
|
9
|
+
var _createRule = require("../utils/create-rule");
|
|
10
|
+
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
11
|
+
|
|
10
12
|
var schema = [{
|
|
11
13
|
type: 'object',
|
|
12
14
|
properties: {
|
|
@@ -13,7 +13,8 @@ var _isSupportedImport = require("@atlaskit/eslint-utils/is-supported-import");
|
|
|
13
13
|
var _createRule = require("../utils/create-rule");
|
|
14
14
|
function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t.return || t.return(); } finally { if (u) throw o; } } }; }
|
|
15
15
|
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
16
|
-
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
16
|
+
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; } // eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
17
|
+
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
17
18
|
var schema = [{
|
|
18
19
|
type: 'object',
|
|
19
20
|
properties: {
|
|
@@ -4,10 +4,12 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.rule = exports.default = void 0;
|
|
7
|
-
var _createRule = require("../utils/create-rule");
|
|
8
7
|
var _isSupportedImport = require("@atlaskit/eslint-utils/is-supported-import");
|
|
9
|
-
var
|
|
8
|
+
var _createRule = require("../utils/create-rule");
|
|
10
9
|
var _messages = require("./messages");
|
|
10
|
+
var _utils = require("./utils");
|
|
11
|
+
/* eslint-disable @atlassian/tangerine/import/entry-points */
|
|
12
|
+
|
|
11
13
|
var schema = [{
|
|
12
14
|
type: 'object',
|
|
13
15
|
additionalProperties: false,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
+
import { isNodeOfType } from 'eslint-codemod-utils';
|
|
1
2
|
import { analyze } from 'eslint-scope';
|
|
2
|
-
import { createLintRule } from '../utils/create-rule';
|
|
3
|
-
import { isStyledComponents, isEmotion } from '@atlaskit/eslint-utils/is-supported-import';
|
|
4
3
|
import ESTraverse from 'estraverse';
|
|
5
|
-
import {
|
|
4
|
+
import { isEmotion, isStyledComponents } from '@atlaskit/eslint-utils/is-supported-import';
|
|
5
|
+
import { createLintRule } from '../utils/create-rule';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Represents some information about single line that contains some props, e.g.
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
/* eslint-disable @atlassian/tangerine/import/entry-points */
|
|
2
|
+
|
|
1
3
|
import estraverse from 'estraverse';
|
|
4
|
+
import { getImportSources, isCss, isCssMap, isKeyframes, isStyled, isXcss } from '@atlaskit/eslint-utils/is-supported-import';
|
|
2
5
|
import { createLintRule } from '../utils/create-rule';
|
|
3
|
-
import { isCss, getImportSources, isStyled, isKeyframes, isCssMap, isXcss } from '@atlaskit/eslint-utils/is-supported-import';
|
|
4
6
|
const schema = [{
|
|
5
7
|
type: 'object',
|
|
6
8
|
properties: {
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
2
|
+
|
|
3
3
|
import { createNoExportedRule } from '@atlaskit/eslint-utils/create-no-exported-rule';
|
|
4
|
+
import { isCss, isCssMap, isKeyframes, isStyled, isXcss } from '@atlaskit/eslint-utils/is-supported-import';
|
|
5
|
+
import { createLintRule } from '../utils/create-rule';
|
|
4
6
|
const schema = [{
|
|
5
7
|
type: 'object',
|
|
6
8
|
properties: {
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
2
|
+
|
|
3
|
+
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
4
|
+
|
|
1
5
|
import esquery from 'esquery';
|
|
2
6
|
import estraverse from 'estraverse';
|
|
3
7
|
import { getAllowedDynamicKeys, getAllowedFunctionCalls, isAllowListedVariable } from '@atlaskit/eslint-utils/allowed-function-calls';
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
+
/* eslint-disable @atlassian/tangerine/import/entry-points */
|
|
2
|
+
|
|
3
|
+
import { getImportSources, isCss, isCssMap, isKeyframes, isStyled, isXcss } from '@atlaskit/eslint-utils/is-supported-import';
|
|
1
4
|
import { createLintRule } from '../utils/create-rule';
|
|
2
|
-
import { isCss, getImportSources, isStyled, isKeyframes, isCssMap, isXcss } from '@atlaskit/eslint-utils/is-supported-import';
|
|
3
|
-
import { Linter } from './utils';
|
|
4
5
|
import { messages } from './messages';
|
|
6
|
+
import { Linter } from './utils';
|
|
5
7
|
const schema = [{
|
|
6
8
|
type: 'object',
|
|
7
9
|
additionalProperties: false,
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t.return || t.return(); } finally { if (u) throw o; } } }; }
|
|
2
2
|
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
3
3
|
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
4
|
+
import { isNodeOfType } from 'eslint-codemod-utils';
|
|
4
5
|
import { analyze } from 'eslint-scope';
|
|
5
|
-
import { createLintRule } from '../utils/create-rule';
|
|
6
|
-
import { isStyledComponents, isEmotion } from '@atlaskit/eslint-utils/is-supported-import';
|
|
7
6
|
import ESTraverse from 'estraverse';
|
|
8
|
-
import {
|
|
7
|
+
import { isEmotion, isStyledComponents } from '@atlaskit/eslint-utils/is-supported-import';
|
|
8
|
+
import { createLintRule } from '../utils/create-rule';
|
|
9
9
|
|
|
10
10
|
/**
|
|
11
11
|
* Represents some information about single line that contains some props, e.g.
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
/* eslint-disable @atlassian/tangerine/import/entry-points */
|
|
2
|
+
|
|
1
3
|
import estraverse from 'estraverse';
|
|
4
|
+
import { getImportSources, isCss, isCssMap, isKeyframes, isStyled, isXcss } from '@atlaskit/eslint-utils/is-supported-import';
|
|
2
5
|
import { createLintRule } from '../utils/create-rule';
|
|
3
|
-
import { isCss, getImportSources, isStyled, isKeyframes, isCssMap, isXcss } from '@atlaskit/eslint-utils/is-supported-import';
|
|
4
6
|
var schema = [{
|
|
5
7
|
type: 'object',
|
|
6
8
|
properties: {
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t.return || t.return(); } finally { if (u) throw o; } } }; }
|
|
2
2
|
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
3
3
|
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
4
|
+
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
5
|
+
|
|
4
6
|
import esquery from 'esquery';
|
|
5
7
|
import { getImportSources, hasStyleObjectArguments } from '@atlaskit/eslint-utils/is-supported-import';
|
|
6
8
|
import { createLintRule } from '../utils/create-rule';
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
2
|
+
|
|
3
3
|
import { createNoExportedRule } from '@atlaskit/eslint-utils/create-no-exported-rule';
|
|
4
|
+
import { isCss, isCssMap, isKeyframes, isStyled, isXcss } from '@atlaskit/eslint-utils/is-supported-import';
|
|
5
|
+
import { createLintRule } from '../utils/create-rule';
|
|
4
6
|
var schema = [{
|
|
5
7
|
type: 'object',
|
|
6
8
|
properties: {
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t.return || t.return(); } finally { if (u) throw o; } } }; }
|
|
2
2
|
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
3
3
|
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
4
|
+
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
5
|
+
|
|
6
|
+
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
7
|
+
|
|
4
8
|
import esquery from 'esquery';
|
|
5
9
|
import estraverse from 'estraverse';
|
|
6
10
|
import { getAllowedDynamicKeys, getAllowedFunctionCalls, isAllowListedVariable } from '@atlaskit/eslint-utils/allowed-function-calls';
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
+
/* eslint-disable @atlassian/tangerine/import/entry-points */
|
|
2
|
+
|
|
3
|
+
import { getImportSources, isCss, isCssMap, isKeyframes, isStyled, isXcss } from '@atlaskit/eslint-utils/is-supported-import';
|
|
1
4
|
import { createLintRule } from '../utils/create-rule';
|
|
2
|
-
import { isCss, getImportSources, isStyled, isKeyframes, isCssMap, isXcss } from '@atlaskit/eslint-utils/is-supported-import';
|
|
3
|
-
import { Linter } from './utils';
|
|
4
5
|
import { messages } from './messages';
|
|
6
|
+
import { Linter } from './utils';
|
|
5
7
|
var schema = [{
|
|
6
8
|
type: 'object',
|
|
7
9
|
additionalProperties: false,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/eslint-plugin-ui-styling-standard",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"author": "Atlassian Pty Ltd",
|
|
5
5
|
"description": "The eslint plugin to enforce and educate on Atlassian's UI Styling Standard",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
"./package.json": "./package.json"
|
|
41
41
|
},
|
|
42
42
|
"dependencies": {
|
|
43
|
-
"@atlaskit/eslint-plugin-design-system": "^
|
|
43
|
+
"@atlaskit/eslint-plugin-design-system": "^11.0.0",
|
|
44
44
|
"@atlaskit/eslint-utils": "^1.7.0",
|
|
45
45
|
"@babel/runtime": "^7.0.0",
|
|
46
46
|
"@typescript-eslint/utils": "^5.48.1",
|