@atlaskit/inline-edit 13.4.0 → 13.5.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.
Files changed (37) hide show
  1. package/CHANGELOG.md +1053 -1040
  2. package/README.md +2 -1
  3. package/__perf__/default.tsx +10 -10
  4. package/__perf__/inline-edit.tsx +31 -36
  5. package/__perf__/inline-text-field.tsx +9 -9
  6. package/codemods/12.0.0-lite-mode.ts +4 -4
  7. package/codemods/__tests__/12.0.0-lite-mode.tsx +21 -21
  8. package/codemods/__tests__/add-comments-when-validate-found.ts +14 -14
  9. package/codemods/__tests__/lift-InlineEditStateless-to-default.ts +35 -35
  10. package/codemods/__tests__/lift-InlineEditableTextField-to-its-entry-point.tsx +21 -21
  11. package/codemods/__tests__/spread-errorMessage-out-of-fieldProps.tsx +28 -28
  12. package/codemods/migrates/add-comments-when-validate-found.ts +13 -23
  13. package/codemods/migrates/lift-InlineEditStateless-to-default.ts +43 -57
  14. package/codemods/migrates/lift-InlineEditableTextField-to-its-entry-point.ts +29 -42
  15. package/codemods/migrates/spread-errorMessage-out-of-fieldProps.ts +45 -63
  16. package/codemods/migrates/utils.ts +62 -70
  17. package/dist/cjs/inline-edit.js +4 -2
  18. package/dist/cjs/inline-editable-textfield.js +8 -1
  19. package/dist/cjs/internal/buttons.js +10 -3
  20. package/dist/cjs/internal/read-view.js +6 -0
  21. package/dist/es2019/inline-edit.js +6 -1
  22. package/dist/es2019/inline-editable-textfield.js +9 -1
  23. package/dist/es2019/internal/buttons.js +9 -3
  24. package/dist/es2019/internal/read-view.js +6 -0
  25. package/dist/esm/inline-edit.js +6 -1
  26. package/dist/esm/inline-editable-textfield.js +9 -1
  27. package/dist/esm/internal/buttons.js +9 -3
  28. package/dist/esm/internal/read-view.js +6 -0
  29. package/dist/types/internal/buttons.d.ts +3 -0
  30. package/dist/types/internal/read-view.d.ts +3 -0
  31. package/dist/types/types.d.ts +2 -2
  32. package/dist/types-ts4.5/internal/buttons.d.ts +3 -0
  33. package/dist/types-ts4.5/internal/read-view.d.ts +3 -0
  34. package/dist/types-ts4.5/types.d.ts +2 -2
  35. package/extract-react-types/inline-editable-textfield-props.tsx +2 -4
  36. package/package.json +109 -111
  37. package/report.api.md +32 -37
@@ -1,10 +1,6 @@
1
1
  import type { ASTPath, default as core, ImportDeclaration } from 'jscodeshift';
2
2
 
3
- import {
4
- addCommentToStartOfFile,
5
- getDefaultSpecifierName,
6
- hasJSXAttributesByName,
7
- } from './utils';
3
+ import { addCommentToStartOfFile, getDefaultSpecifierName, hasJSXAttributesByName } from './utils';
8
4
 
9
5
  const commentMessage = `We could not automatically convert this code to the new API.
10
6
 
@@ -31,24 +27,18 @@ const MyEditView = (
31
27
  `;
32
28
 
33
29
  const addCommentsWhenValidateFound = (j: core.JSCodeshift, source: any) => {
34
- const defaultSpecifier = getDefaultSpecifierName(
35
- j,
36
- source,
37
- '@atlaskit/inline-edit',
38
- );
39
-
40
- if (!defaultSpecifier) {
41
- return;
42
- }
43
-
44
- source
45
- .findJSXElements(defaultSpecifier)
46
- .forEach((element: ASTPath<ImportDeclaration>) => {
47
- const isValidateDefined = hasJSXAttributesByName(j, element, 'validate');
48
- if (isValidateDefined) {
49
- addCommentToStartOfFile({ j, base: source, message: commentMessage });
50
- }
51
- });
30
+ const defaultSpecifier = getDefaultSpecifierName(j, source, '@atlaskit/inline-edit');
31
+
32
+ if (!defaultSpecifier) {
33
+ return;
34
+ }
35
+
36
+ source.findJSXElements(defaultSpecifier).forEach((element: ASTPath<ImportDeclaration>) => {
37
+ const isValidateDefined = hasJSXAttributesByName(j, element, 'validate');
38
+ if (isValidateDefined) {
39
+ addCommentToStartOfFile({ j, base: source, message: commentMessage });
40
+ }
41
+ });
52
42
  };
53
43
 
54
44
  export default addCommentsWhenValidateFound;
@@ -1,9 +1,9 @@
1
1
  import type {
2
- ASTPath,
3
- default as core,
4
- ImportDeclaration,
5
- ImportDefaultSpecifier,
6
- ImportSpecifier,
2
+ ASTPath,
3
+ default as core,
4
+ ImportDeclaration,
5
+ ImportDefaultSpecifier,
6
+ ImportSpecifier,
7
7
  } from 'jscodeshift';
8
8
 
9
9
  import { addCommentToStartOfFile } from './utils';
@@ -14,58 +14,44 @@ This file uses \`InlineEdit\` and \`InlineEditStateless\` at the same time. We'v
14
14
  `;
15
15
 
16
16
  const elevateComponentToDefault =
17
- (pkg: string, toPkg: string, innerElementName: string) =>
18
- (j: core.JSCodeshift, root: any) => {
19
- const importDeclarations = root
20
- .find(j.ImportDeclaration)
21
- .filter(
22
- (path: ASTPath<ImportDeclaration>) => path.node.source.value === pkg,
23
- );
24
-
25
- const defaultSpecifier = importDeclarations
26
- .find(j.ImportDefaultSpecifier)
27
- .nodes();
28
- const otherSpecifier = importDeclarations.find(j.ImportSpecifier).nodes();
29
-
30
- const isImportingStateless =
31
- otherSpecifier.filter(
32
- (s: ImportSpecifier) =>
33
- s.imported && s.imported.name === innerElementName,
34
- ).length > 0;
35
-
36
- if (defaultSpecifier.length > 0 && isImportingStateless) {
37
- addCommentToStartOfFile({ j, base: root, message: commentMessage });
38
- return;
39
- }
40
-
41
- const newDefaultSpecifier = defaultSpecifier.map(
42
- (s: ImportDefaultSpecifier) => {
43
- return j.importDeclaration(
44
- [j.importDefaultSpecifier(s.local)],
45
- j.literal(pkg),
46
- );
47
- },
48
- );
49
-
50
- const newOtherSpecifiers = otherSpecifier.map((s: ImportSpecifier) => {
51
- if (s.imported.name === innerElementName) {
52
- return j.importDeclaration(
53
- [j.importDefaultSpecifier(s.local)],
54
- j.literal(toPkg),
55
- );
56
- } else {
57
- return j.importDeclaration([s], j.literal(pkg));
58
- }
59
- });
60
-
61
- importDeclarations.forEach((path: ASTPath<ImportDeclaration>) => {
62
- j(path).replaceWith(newDefaultSpecifier);
63
- j(path).insertBefore(newOtherSpecifiers);
64
- });
65
- };
17
+ (pkg: string, toPkg: string, innerElementName: string) => (j: core.JSCodeshift, root: any) => {
18
+ const importDeclarations = root
19
+ .find(j.ImportDeclaration)
20
+ .filter((path: ASTPath<ImportDeclaration>) => path.node.source.value === pkg);
21
+
22
+ const defaultSpecifier = importDeclarations.find(j.ImportDefaultSpecifier).nodes();
23
+ const otherSpecifier = importDeclarations.find(j.ImportSpecifier).nodes();
24
+
25
+ const isImportingStateless =
26
+ otherSpecifier.filter(
27
+ (s: ImportSpecifier) => s.imported && s.imported.name === innerElementName,
28
+ ).length > 0;
29
+
30
+ if (defaultSpecifier.length > 0 && isImportingStateless) {
31
+ addCommentToStartOfFile({ j, base: root, message: commentMessage });
32
+ return;
33
+ }
34
+
35
+ const newDefaultSpecifier = defaultSpecifier.map((s: ImportDefaultSpecifier) => {
36
+ return j.importDeclaration([j.importDefaultSpecifier(s.local)], j.literal(pkg));
37
+ });
38
+
39
+ const newOtherSpecifiers = otherSpecifier.map((s: ImportSpecifier) => {
40
+ if (s.imported.name === innerElementName) {
41
+ return j.importDeclaration([j.importDefaultSpecifier(s.local)], j.literal(toPkg));
42
+ } else {
43
+ return j.importDeclaration([s], j.literal(pkg));
44
+ }
45
+ });
46
+
47
+ importDeclarations.forEach((path: ASTPath<ImportDeclaration>) => {
48
+ j(path).replaceWith(newDefaultSpecifier);
49
+ j(path).insertBefore(newOtherSpecifiers);
50
+ });
51
+ };
66
52
 
67
53
  export default elevateComponentToDefault(
68
- '@atlaskit/inline-edit',
69
- '@atlaskit/inline-edit',
70
- 'InlineEditStateless',
54
+ '@atlaskit/inline-edit',
55
+ '@atlaskit/inline-edit',
56
+ 'InlineEditStateless',
71
57
  );
@@ -1,53 +1,40 @@
1
1
  import type {
2
- ASTPath,
3
- default as core,
4
- ImportDeclaration,
5
- ImportDefaultSpecifier,
6
- ImportSpecifier,
2
+ ASTPath,
3
+ default as core,
4
+ ImportDeclaration,
5
+ ImportDefaultSpecifier,
6
+ ImportSpecifier,
7
7
  } from 'jscodeshift';
8
8
 
9
9
  const elevateComponentToNewEntryPoint =
10
- (pkg: string, toPkg: string, innerElementName: string) =>
11
- (j: core.JSCodeshift, root: any) => {
12
- const importDeclarations = root
13
- .find(j.ImportDeclaration)
14
- .filter(
15
- (path: ASTPath<ImportDeclaration>) => path.node.source.value === pkg,
16
- );
10
+ (pkg: string, toPkg: string, innerElementName: string) => (j: core.JSCodeshift, root: any) => {
11
+ const importDeclarations = root
12
+ .find(j.ImportDeclaration)
13
+ .filter((path: ASTPath<ImportDeclaration>) => path.node.source.value === pkg);
17
14
 
18
- const defaultSpecifier = importDeclarations
19
- .find(j.ImportDefaultSpecifier)
20
- .nodes();
21
- const otherSpecifier = importDeclarations.find(j.ImportSpecifier).nodes();
15
+ const defaultSpecifier = importDeclarations.find(j.ImportDefaultSpecifier).nodes();
16
+ const otherSpecifier = importDeclarations.find(j.ImportSpecifier).nodes();
22
17
 
23
- const newDefaultSpecifier = defaultSpecifier.map(
24
- (s: ImportDefaultSpecifier) => {
25
- return j.importDeclaration(
26
- [j.importDefaultSpecifier(s.local)],
27
- j.literal(pkg),
28
- );
29
- },
30
- );
18
+ const newDefaultSpecifier = defaultSpecifier.map((s: ImportDefaultSpecifier) => {
19
+ return j.importDeclaration([j.importDefaultSpecifier(s.local)], j.literal(pkg));
20
+ });
31
21
 
32
- const newOtherSpecifiers = otherSpecifier.map((s: ImportSpecifier) => {
33
- if (s.imported.name === innerElementName) {
34
- return j.importDeclaration(
35
- [j.importDefaultSpecifier(s.local)],
36
- j.literal(toPkg),
37
- );
38
- } else {
39
- return j.importDeclaration([s], j.literal(pkg));
40
- }
41
- });
22
+ const newOtherSpecifiers = otherSpecifier.map((s: ImportSpecifier) => {
23
+ if (s.imported.name === innerElementName) {
24
+ return j.importDeclaration([j.importDefaultSpecifier(s.local)], j.literal(toPkg));
25
+ } else {
26
+ return j.importDeclaration([s], j.literal(pkg));
27
+ }
28
+ });
42
29
 
43
- importDeclarations.forEach((path: ASTPath<ImportDeclaration>) => {
44
- j(path).replaceWith(newDefaultSpecifier);
45
- j(path).insertBefore(newOtherSpecifiers);
46
- });
47
- };
30
+ importDeclarations.forEach((path: ASTPath<ImportDeclaration>) => {
31
+ j(path).replaceWith(newDefaultSpecifier);
32
+ j(path).insertBefore(newOtherSpecifiers);
33
+ });
34
+ };
48
35
 
49
36
  export default elevateComponentToNewEntryPoint(
50
- '@atlaskit/inline-edit',
51
- '@atlaskit/inline-edit/inline-editable-textfield',
52
- 'InlineEditableTextfield',
37
+ '@atlaskit/inline-edit',
38
+ '@atlaskit/inline-edit/inline-editable-textfield',
39
+ 'InlineEditableTextfield',
53
40
  );
@@ -1,74 +1,56 @@
1
1
  import { type NodePath } from 'ast-types/lib/node-path';
2
2
  import type { ASTPath, default as core, ImportDeclaration } from 'jscodeshift';
3
3
 
4
- import {
5
- getDefaultSpecifierName,
6
- getJSXAttributesByName,
7
- hasJSXAttributesByName,
8
- } from './utils';
4
+ import { getDefaultSpecifierName, getJSXAttributesByName, hasJSXAttributesByName } from './utils';
9
5
 
10
6
  const isConvertable = (arrowFunction: NodePath | null) => {
11
- return (
12
- arrowFunction &&
13
- arrowFunction.value.params.length === 1 &&
14
- arrowFunction.value.params[0].type === 'Identifier'
15
- );
7
+ return (
8
+ arrowFunction &&
9
+ arrowFunction.value.params.length === 1 &&
10
+ arrowFunction.value.params[0].type === 'Identifier'
11
+ );
16
12
  };
17
13
 
18
14
  const spreadErrorMessage = (j: core.JSCodeshift, source: any) => {
19
- const defaultSpecifier = getDefaultSpecifierName(
20
- j,
21
- source,
22
- '@atlaskit/inline-edit',
23
- );
24
-
25
- if (!defaultSpecifier) {
26
- return;
27
- }
28
-
29
- const createObjectProperty = (name: string) => {
30
- const obj = j.objectProperty(j.identifier(name), j.identifier(name));
31
- obj.shorthand = true;
32
- obj.loc = null;
33
-
34
- return obj;
35
- };
36
-
37
- source
38
- .findJSXElements(defaultSpecifier)
39
- .forEach((element: ASTPath<ImportDeclaration>) => {
40
- getJSXAttributesByName(j, element, 'editView').forEach((editView) => {
41
- const collection = j(editView)
42
- .find(j.JSXExpressionContainer)
43
- .find(j.ArrowFunctionExpression);
44
-
45
- const isValidateDefined = hasJSXAttributesByName(
46
- j,
47
- element,
48
- 'validate',
49
- );
50
- const arrowFunction = collection.length > 0 ? collection.get() : null;
51
-
52
- if (isValidateDefined && isConvertable(arrowFunction)) {
53
- const name = arrowFunction.value.params[0].name;
54
- const replacement = j.jsxExpressionContainer(
55
- j.arrowFunctionExpression(
56
- [
57
- j.objectPattern([
58
- createObjectProperty('errorMessage'),
59
- j.restProperty(j.identifier(name)),
60
- ]),
61
- ],
62
- arrowFunction.value.body,
63
- ),
64
- );
65
-
66
- j(editView).replaceWith(
67
- j.jsxAttribute(j.jsxIdentifier('editView'), replacement),
68
- );
69
- }
70
- });
71
- });
15
+ const defaultSpecifier = getDefaultSpecifierName(j, source, '@atlaskit/inline-edit');
16
+
17
+ if (!defaultSpecifier) {
18
+ return;
19
+ }
20
+
21
+ const createObjectProperty = (name: string) => {
22
+ const obj = j.objectProperty(j.identifier(name), j.identifier(name));
23
+ obj.shorthand = true;
24
+ obj.loc = null;
25
+
26
+ return obj;
27
+ };
28
+
29
+ source.findJSXElements(defaultSpecifier).forEach((element: ASTPath<ImportDeclaration>) => {
30
+ getJSXAttributesByName(j, element, 'editView').forEach((editView) => {
31
+ const collection = j(editView).find(j.JSXExpressionContainer).find(j.ArrowFunctionExpression);
32
+
33
+ const isValidateDefined = hasJSXAttributesByName(j, element, 'validate');
34
+ const arrowFunction = collection.length > 0 ? collection.get() : null;
35
+
36
+ if (isValidateDefined && isConvertable(arrowFunction)) {
37
+ const name = arrowFunction.value.params[0].name;
38
+ const replacement = j.jsxExpressionContainer(
39
+ j.arrowFunctionExpression(
40
+ [
41
+ j.objectPattern([
42
+ createObjectProperty('errorMessage'),
43
+ j.restProperty(j.identifier(name)),
44
+ ]),
45
+ ],
46
+ arrowFunction.value.body,
47
+ ),
48
+ );
49
+
50
+ j(editView).replaceWith(j.jsxAttribute(j.jsxIdentifier('editView'), replacement));
51
+ }
52
+ });
53
+ });
72
54
  };
73
55
 
74
56
  export default spreadErrorMessage;
@@ -1,102 +1,94 @@
1
1
  import type {
2
- ASTPath,
3
- default as core,
4
- ImportDeclaration,
5
- JSXAttribute,
6
- Program,
2
+ ASTPath,
3
+ default as core,
4
+ ImportDeclaration,
5
+ JSXAttribute,
6
+ Program,
7
7
  } from 'jscodeshift';
8
8
  import { type Collection } from 'jscodeshift/src/Collection';
9
9
 
10
10
  function addCommentBefore({
11
- j,
12
- target,
13
- message,
11
+ j,
12
+ target,
13
+ message,
14
14
  }: {
15
- j: core.JSCodeshift;
16
- target:
17
- | Collection<Node>
18
- | Collection<Program>
19
- | Collection<ImportDeclaration>;
20
- message: string;
15
+ j: core.JSCodeshift;
16
+ target: Collection<Node> | Collection<Program> | Collection<ImportDeclaration>;
17
+ message: string;
21
18
  }) {
22
- const content: string = ` TODO: (from codemod) ${message} `;
23
- target.forEach((path: ASTPath<any>) => {
24
- path.value.comments = path.value.comments || [];
19
+ const content: string = ` TODO: (from codemod) ${message} `;
20
+ target.forEach((path: ASTPath<any>) => {
21
+ path.value.comments = path.value.comments || [];
25
22
 
26
- const exists = path.value.comments.find(
27
- (comment: ASTPath<any>) => comment.value === content,
28
- );
23
+ const exists = path.value.comments.find((comment: ASTPath<any>) => comment.value === content);
29
24
 
30
- // avoiding duplicates of the same comment
31
- if (exists) {
32
- return;
33
- }
25
+ // avoiding duplicates of the same comment
26
+ if (exists) {
27
+ return;
28
+ }
34
29
 
35
- path.value.comments.push(j.commentBlock(content));
36
- });
30
+ path.value.comments.push(j.commentBlock(content));
31
+ });
37
32
  }
38
33
 
39
34
  function addCommentToStartOfFile({
40
- j,
41
- base,
42
- message,
35
+ j,
36
+ base,
37
+ message,
43
38
  }: {
44
- j: core.JSCodeshift;
45
- base: Collection<Node>;
46
- message: string;
39
+ j: core.JSCodeshift;
40
+ base: Collection<Node>;
41
+ message: string;
47
42
  }) {
48
- addCommentBefore({
49
- j,
50
- target: base.find(j.Program),
51
- message,
52
- });
43
+ addCommentBefore({
44
+ j,
45
+ target: base.find(j.Program),
46
+ message,
47
+ });
53
48
  }
54
49
 
55
50
  function getJSXAttributesByName(
56
- j: core.JSCodeshift,
57
- element: ASTPath<any>,
58
- attributeName: string,
51
+ j: core.JSCodeshift,
52
+ element: ASTPath<any>,
53
+ attributeName: string,
59
54
  ): Collection<JSXAttribute> {
60
- return j(element)
61
- .find(j.JSXOpeningElement)
62
- .find(j.JSXAttribute)
63
- .filter((attribute) => {
64
- const matches = j(attribute)
65
- .find(j.JSXIdentifier)
66
- .filter((identifier) => identifier.value.name === attributeName);
67
- return Boolean(matches.length);
68
- });
55
+ return j(element)
56
+ .find(j.JSXOpeningElement)
57
+ .find(j.JSXAttribute)
58
+ .filter((attribute) => {
59
+ const matches = j(attribute)
60
+ .find(j.JSXIdentifier)
61
+ .filter((identifier) => identifier.value.name === attributeName);
62
+ return Boolean(matches.length);
63
+ });
69
64
  }
70
65
 
71
66
  const getDefaultSpecifierName = (
72
- j: core.JSCodeshift,
73
- base: Collection<any>,
74
- packageName: string,
67
+ j: core.JSCodeshift,
68
+ base: Collection<any>,
69
+ packageName: string,
75
70
  ) => {
76
- const specifiers = base
77
- .find(j.ImportDeclaration)
78
- .filter(
79
- (path: ASTPath<ImportDeclaration>) =>
80
- path.node.source.value === packageName,
81
- )
82
- .find(j.ImportDefaultSpecifier);
71
+ const specifiers = base
72
+ .find(j.ImportDeclaration)
73
+ .filter((path: ASTPath<ImportDeclaration>) => path.node.source.value === packageName)
74
+ .find(j.ImportDefaultSpecifier);
83
75
 
84
- if (!specifiers.length) {
85
- return null;
86
- }
76
+ if (!specifiers.length) {
77
+ return null;
78
+ }
87
79
 
88
- return specifiers.nodes()[0]!.local!.name;
80
+ return specifiers.nodes()[0]!.local!.name;
89
81
  };
90
82
 
91
83
  const hasJSXAttributesByName = (
92
- j: core.JSCodeshift,
93
- element: ASTPath<any>,
94
- attributeName: string,
84
+ j: core.JSCodeshift,
85
+ element: ASTPath<any>,
86
+ attributeName: string,
95
87
  ) => getJSXAttributesByName(j, element, attributeName).length > 0;
96
88
 
97
89
  export {
98
- getDefaultSpecifierName,
99
- getJSXAttributesByName,
100
- hasJSXAttributesByName,
101
- addCommentToStartOfFile,
90
+ getDefaultSpecifierName,
91
+ getJSXAttributesByName,
92
+ hasJSXAttributesByName,
93
+ addCommentToStartOfFile,
102
94
  };
@@ -21,7 +21,9 @@ var _readView = _interopRequireDefault(require("./internal/read-view"));
21
21
  function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
22
22
  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; }
23
23
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
24
- function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } /** @jsx jsx */
24
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } /**
25
+ * @jsxRuntime classic
26
+ */ /** @jsx jsx */ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
25
27
  var fieldStyles = (0, _react2.css)({
26
28
  maxWidth: '100%',
27
29
  position: 'relative'
@@ -29,7 +31,7 @@ var fieldStyles = (0, _react2.css)({
29
31
  var analyticsAttributes = {
30
32
  componentName: 'inlineEdit',
31
33
  packageName: "@atlaskit/inline-edit",
32
- packageVersion: "13.4.0"
34
+ packageVersion: "13.5.0"
33
35
  };
34
36
  var noop = function noop() {};
35
37
  var InnerInlineEdit = function InnerInlineEdit(props) {
@@ -16,17 +16,24 @@ var _colors = require("@atlaskit/theme/colors");
16
16
  var _inlineEdit = _interopRequireDefault(require("./inline-edit"));
17
17
  var _constants = require("./internal/constants");
18
18
  var _excluded = ["errorMessage", "isInvalid"];
19
+ /**
20
+ * @jsxRuntime classic
21
+ */
19
22
  /** @jsx jsx */
23
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
20
24
  var errorIconContainerStyles = (0, _react2.css)({
21
- paddingRight: "var(--ds-space-075, 6px)",
25
+ paddingInlineEnd: "var(--ds-space-075, 6px)",
22
26
  lineHeight: '100%'
23
27
  });
24
28
  var readViewForTextFieldStyles = (0, _react2.css)({
25
29
  display: 'flex',
26
30
  maxWidth: '100%',
31
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
27
32
  minHeight: "".concat(8 * 2.5 / _constants.fontSize, "em"),
28
33
  padding: "var(--ds-space-100, 8px)".concat(" ", "var(--ds-space-075, 6px)"),
34
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
29
35
  fontSize: _constants.fontSize,
36
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
30
37
  lineHeight: 8 * 2.5 / _constants.fontSize,
31
38
  wordBreak: 'break-word'
32
39
  });
@@ -11,8 +11,13 @@ var _check = _interopRequireDefault(require("@atlaskit/icon/glyph/check"));
11
11
  var _cross = _interopRequireDefault(require("@atlaskit/icon/glyph/cross"));
12
12
  var _colors = require("@atlaskit/theme/colors");
13
13
  var _constants = require("./constants");
14
+ /**
15
+ * @jsxRuntime classic
16
+ */
14
17
  /** @jsx jsx */
15
18
 
19
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
20
+
16
21
  var buttonsContainerStyles = (0, _react.css)({
17
22
  display: 'flex',
18
23
  marginBlockStart: "var(--ds-space-075, 6px)",
@@ -29,21 +34,23 @@ var buttonWrapperBaseStyles = (0, _react.css)({
29
34
  zIndex: 200,
30
35
  backgroundColor: "var(--ds-surface-overlay, ".concat(_colors.N0, ")"),
31
36
  borderRadius: "var(--ds-border-radius, 3px)",
37
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
32
38
  fontSize: _constants.fontSize,
39
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors -- Ignored via go/DSP-18766
33
40
  '&:last-child': {
34
41
  marginInlineStart: "var(--ds-space-050, 4px)"
35
42
  },
36
43
  boxShadow: "var(--ds-shadow-overlay, ".concat("0 4px 8px -2px ".concat(_colors.N50A, ", 0 0 1px ").concat(_colors.N60A), ")"),
37
44
  // These buttons are floating, so they need an override to overlay interaction states
38
- // eslint-disable-next-line @atlaskit/design-system/no-nested-styles
45
+ // eslint-disable-next-line @atlaskit/design-system/no-nested-styles, @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
39
46
  '& > button': {
40
47
  backgroundColor: "var(--ds-surface-overlay, ".concat(_colors.N20A, ")")
41
48
  },
42
- // eslint-disable-next-line @atlaskit/design-system/no-nested-styles
49
+ // eslint-disable-next-line @atlaskit/design-system/no-nested-styles, @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
43
50
  '& > button:hover': {
44
51
  backgroundColor: "var(--ds-surface-overlay-hovered, ".concat(_colors.N30A, ")")
45
52
  },
46
- // eslint-disable-next-line @atlaskit/design-system/no-nested-styles
53
+ // eslint-disable-next-line @atlaskit/design-system/no-nested-styles, @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
47
54
  '& > button:active': {
48
55
  backgroundColor: "var(--ds-surface-overlay-pressed, rgba(179, 212, 255, 0.6))",
49
56
  color: "var(--ds-text, ".concat(_colors.B400, ")")
@@ -14,8 +14,13 @@ var _visuallyHidden = _interopRequireDefault(require("@atlaskit/visually-hidden"
14
14
  var _constants = require("./constants");
15
15
  function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
16
16
  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; }
17
+ /**
18
+ * @jsxRuntime classic
19
+ */
17
20
  /** @jsx jsx */
18
21
 
22
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
23
+
19
24
  var readViewContainerStyles = (0, _react2.css)({
20
25
  lineHeight: 1
21
26
  });
@@ -45,6 +50,7 @@ var readViewWrapperStyles = (0, _react2.css)({
45
50
  width: 'auto',
46
51
  maxWidth: '100%',
47
52
  border: '2px solid transparent',
53
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
48
54
  borderRadius: _constants.borderRadius,
49
55
  transition: 'background 0.2s',
50
56
  '&:hover': {