@atlaskit/eslint-plugin-design-system 10.2.1 → 10.3.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/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # @atlaskit/eslint-plugin-design-system
2
2
 
3
+ ## 10.3.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#102286](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/102286)
8
+ [`8c56c1feba06`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/8c56c1feba06) -
9
+ Adds support for `role="button"` in `no-html-anchor` rule
10
+
3
11
  ## 10.2.1
4
12
 
5
13
  ### Patch Changes
@@ -21,6 +21,12 @@ This rule marks code as violations when it finds native HTML anchor elements.
21
21
  ^ Using a native HTML `<a>`
22
22
  Hello, World!
23
23
  </a>
24
+
25
+ <div role="link" tabIndex="0" data-href="https://www.atlassian.com">
26
+ ^^^^^^^^^^^ Using `role="link"` to create links
27
+ Hello, World!
28
+ </div>
29
+
24
30
  ```
25
31
 
26
32
  ### Correct
@@ -11,6 +11,12 @@ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return
11
11
  function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
12
12
  var supportedElements = [{
13
13
  name: 'a'
14
+ }, {
15
+ name: '*',
16
+ attributes: [{
17
+ name: 'role',
18
+ values: ['link']
19
+ }]
14
20
  }];
15
21
 
16
22
  /**
@@ -2,6 +2,12 @@ import { isNodeOfType } from 'eslint-codemod-utils';
2
2
  import * as ast from '../../../ast-nodes';
3
3
  const supportedElements = [{
4
4
  name: 'a'
5
+ }, {
6
+ name: '*',
7
+ attributes: [{
8
+ name: 'role',
9
+ values: ['link']
10
+ }]
5
11
  }];
6
12
 
7
13
  /**
@@ -2,6 +2,12 @@ import { isNodeOfType } from 'eslint-codemod-utils';
2
2
  import * as ast from '../../../ast-nodes';
3
3
  var supportedElements = [{
4
4
  name: 'a'
5
+ }, {
6
+ name: '*',
7
+ attributes: [{
8
+ name: 'role',
9
+ values: ['link']
10
+ }]
5
11
  }];
6
12
 
7
13
  /**
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": "10.2.1",
4
+ "version": "10.3.0",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
7
7
  "publishConfig": {