@atlaskit/eslint-plugin-design-system 12.2.0 → 13.0.1

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,35 @@
1
1
  # @atlaskit/eslint-plugin-design-system
2
2
 
3
+ ## 13.0.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [#119942](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/119942)
8
+ [`d5163d608020e`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/d5163d608020e) -
9
+ "Modify the no-unsafe-design-token-usage rule to exclude the getTokenValue function when used in
10
+ 'none' mode for fallbackUsage. This adjustment is necessary because the getTokenValue function is
11
+ not covered by the build-time @atlaskit/tokens/babel-plugin by design. As a result, using this
12
+ function without a fallback can be unsafe, as it defaults to a blank value if applied on a webpage
13
+ where the ADS theme is not enabled."
14
+
15
+ ## 13.0.0
16
+
17
+ ### Major Changes
18
+
19
+ - [#117363](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/117363)
20
+ [`10a0f7f6c2027`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/10a0f7f6c2027) -
21
+ This package's `peerDependencies` have been adjusted for `react` and/or `react-dom` to reflect the
22
+ status of only supporting React 18 going forward. No explicit breaking change to React support has
23
+ been made in this release, but this is to signify going forward, breaking changes for React 16 or
24
+ React 17 may come via non-major semver releases.
25
+
26
+ Please refer this community post for more details:
27
+ https://community.developer.atlassian.com/t/rfc-78-dropping-support-for-react-16-and-rendering-in-a-react-18-concurrent-root-in-jira-and-confluence/87026
28
+
29
+ ### Patch Changes
30
+
31
+ - Updated dependencies
32
+
3
33
  ## 12.2.0
4
34
 
5
35
  ### Minor Changes
@@ -109,6 +109,12 @@ var rule = (0, _createRule.createLintRule)({
109
109
  if (!(0, _eslintCodemodUtils.isNodeOfType)(node, 'CallExpression')) {
110
110
  return;
111
111
  }
112
+ var isGetTokenValueCall = (0, _eslintCodemodUtils.isNodeOfType)(node.callee, 'Identifier') && node.callee.name === 'getTokenValue';
113
+
114
+ // Skip processing if it's a `getTokenValue` call and config.fallbackUsage is `none`
115
+ if (isGetTokenValueCall && config.fallbackUsage === 'none') {
116
+ return;
117
+ }
112
118
  if (node.arguments.length < 2 && config.fallbackUsage === 'forced') {
113
119
  var fix;
114
120
  if (node.arguments[0].type === 'Literal') {
@@ -121,6 +121,12 @@ token('color.background.blanket');
121
121
  if (!isNodeOfType(node, 'CallExpression')) {
122
122
  return;
123
123
  }
124
+ const isGetTokenValueCall = isNodeOfType(node.callee, 'Identifier') && node.callee.name === 'getTokenValue';
125
+
126
+ // Skip processing if it's a `getTokenValue` call and config.fallbackUsage is `none`
127
+ if (isGetTokenValueCall && config.fallbackUsage === 'none') {
128
+ return;
129
+ }
124
130
  if (node.arguments.length < 2 && config.fallbackUsage === 'forced') {
125
131
  let fix;
126
132
  if (node.arguments[0].type === 'Literal') {
@@ -104,6 +104,12 @@ var rule = createLintRule({
104
104
  if (!isNodeOfType(node, 'CallExpression')) {
105
105
  return;
106
106
  }
107
+ var isGetTokenValueCall = isNodeOfType(node.callee, 'Identifier') && node.callee.name === 'getTokenValue';
108
+
109
+ // Skip processing if it's a `getTokenValue` call and config.fallbackUsage is `none`
110
+ if (isGetTokenValueCall && config.fallbackUsage === 'none') {
111
+ return;
112
+ }
107
113
  if (node.arguments.length < 2 && config.fallbackUsage === 'forced') {
108
114
  var fix;
109
115
  if (node.arguments[0].type === 'Literal') {
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": "12.2.0",
4
+ "version": "13.0.1",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
7
7
  "publishConfig": {
@@ -40,12 +40,12 @@
40
40
  "./package.json": "./package.json"
41
41
  },
42
42
  "peerDependencies": {
43
- "react": "^16.8.0 || ^17.0.0 || ^18.0.0"
43
+ "react": "^18.2.0"
44
44
  },
45
45
  "dependencies": {
46
- "@atlaskit/eslint-utils": "^1.10.0",
47
- "@atlaskit/icon": "^23.8.0",
48
- "@atlaskit/icon-lab": "^2.5.0",
46
+ "@atlaskit/eslint-utils": "^2.0.0",
47
+ "@atlaskit/icon": "^24.1.0",
48
+ "@atlaskit/icon-lab": "^3.2.0",
49
49
  "@atlaskit/tokens": "*",
50
50
  "@babel/runtime": "^7.0.0",
51
51
  "@typescript-eslint/utils": "^7.1.0",
@@ -58,8 +58,8 @@
58
58
  },
59
59
  "devDependencies": {
60
60
  "@af/formatting": "*",
61
- "@atlaskit/ds-lib": "^3.5.0",
62
- "@atlaskit/theme": "^15.0.0",
61
+ "@atlaskit/ds-lib": "^4.0.0",
62
+ "@atlaskit/theme": "^17.0.0",
63
63
  "@atlassian/codegen": "*",
64
64
  "@atlassian/eslint-utils": "^0.5.0",
65
65
  "@atlassian/ts-loader": "*",