@atlaskit/primitives 18.0.0 → 18.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.
Files changed (70) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/codemods/hypermod.config.tsx +5 -1
  3. package/constellation/anchor/usage.mdx +40 -38
  4. package/constellation/pressable/usage.mdx +23 -22
  5. package/dist/cjs/compiled/components/anchor.js +2 -4
  6. package/dist/cjs/compiled/components/box.js +1 -3
  7. package/dist/cjs/compiled/components/focusable.js +1 -3
  8. package/dist/cjs/compiled/components/pressable.js +2 -4
  9. package/dist/cjs/components/anchor.js +3 -5
  10. package/dist/cjs/components/bleed.js +1 -1
  11. package/dist/cjs/components/box.js +1 -3
  12. package/dist/cjs/components/pressable.js +1 -2
  13. package/dist/cjs/responsive/hide.js +1 -1
  14. package/dist/es2019/compiled/components/anchor.js +2 -4
  15. package/dist/es2019/compiled/components/box.js +1 -3
  16. package/dist/es2019/compiled/components/focusable.js +1 -3
  17. package/dist/es2019/compiled/components/pressable.js +2 -4
  18. package/dist/es2019/components/anchor.js +3 -5
  19. package/dist/es2019/components/bleed.js +1 -1
  20. package/dist/es2019/components/box.js +1 -3
  21. package/dist/es2019/components/pressable.js +1 -2
  22. package/dist/es2019/responsive/hide.js +1 -1
  23. package/dist/esm/compiled/components/anchor.js +2 -4
  24. package/dist/esm/compiled/components/box.js +1 -3
  25. package/dist/esm/compiled/components/focusable.js +1 -3
  26. package/dist/esm/compiled/components/pressable.js +2 -4
  27. package/dist/esm/components/anchor.js +3 -5
  28. package/dist/esm/components/bleed.js +1 -1
  29. package/dist/esm/components/box.js +1 -3
  30. package/dist/esm/components/pressable.js +1 -2
  31. package/dist/esm/responsive/hide.js +1 -1
  32. package/dist/types/compiled/components/flex.d.ts +2 -2
  33. package/dist/types/compiled/components/grid.d.ts +2 -2
  34. package/dist/types/compiled/components/inline.d.ts +2 -2
  35. package/dist/types/compiled/components/stack.d.ts +2 -2
  36. package/dist/types/compiled/index.d.ts +1 -1
  37. package/dist/types/components/flex.d.ts +19 -18
  38. package/dist/types/components/grid.d.ts +30 -29
  39. package/dist/types/components/inline.d.ts +1 -1
  40. package/dist/types/components/stack.d.ts +2 -2
  41. package/dist/types/components/text.d.ts +4 -3
  42. package/dist/types/responsive/build-media-query-css.d.ts +3 -3
  43. package/dist/types/responsive/media-helper.d.ts +17 -17
  44. package/dist/types/utils/has-text-ancestor-context.d.ts +2 -1
  45. package/dist/types/utils/surface-provider.d.ts +2 -1
  46. package/dist/types-ts4.5/compiled/components/flex.d.ts +2 -2
  47. package/dist/types-ts4.5/compiled/components/grid.d.ts +2 -2
  48. package/dist/types-ts4.5/compiled/components/inline.d.ts +2 -2
  49. package/dist/types-ts4.5/compiled/components/stack.d.ts +2 -2
  50. package/dist/types-ts4.5/compiled/index.d.ts +1 -1
  51. package/dist/types-ts4.5/components/flex.d.ts +19 -18
  52. package/dist/types-ts4.5/components/grid.d.ts +30 -29
  53. package/dist/types-ts4.5/components/inline.d.ts +1 -1
  54. package/dist/types-ts4.5/components/stack.d.ts +2 -2
  55. package/dist/types-ts4.5/components/text.d.ts +4 -3
  56. package/dist/types-ts4.5/responsive/build-media-query-css.d.ts +3 -3
  57. package/dist/types-ts4.5/responsive/media-helper.d.ts +17 -17
  58. package/dist/types-ts4.5/utils/has-text-ancestor-context.d.ts +2 -1
  59. package/dist/types-ts4.5/utils/surface-provider.d.ts +2 -1
  60. package/package.json +7 -7
  61. package/scripts/codegen-styles.tsx +6 -9
  62. package/scripts/color-codegen-template.tsx +3 -1
  63. package/scripts/elevation-codegen-template.tsx +3 -1
  64. package/scripts/inverse-color-map-template.tsx +1 -1
  65. package/scripts/misc-codegen-template.tsx +3 -1
  66. package/scripts/shape-codegen-template.tsx +3 -1
  67. package/scripts/spacing-codegen-template.tsx +1 -1
  68. package/scripts/text-codegen-template.tsx +1 -1
  69. package/scripts/typography-codegen-template.tsx +1 -1
  70. package/scripts/utils.tsx +17 -10
package/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # @atlaskit/primitives
2
2
 
3
+ ## 18.0.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [`5db9e3f21a52f`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/5db9e3f21a52f) -
8
+ Internal refactoring
9
+ - Updated dependencies
10
+
3
11
  ## 18.0.0
4
12
 
5
13
  ### Major Changes
@@ -1,6 +1,10 @@
1
1
  import compiledForkStage1 from './compiled-fork-stage1/transform';
2
2
 
3
- const config = {
3
+ const config: {
4
+ presets: {
5
+ 'compiled-fork-stage1': typeof compiledForkStage1;
6
+ };
7
+ } = {
4
8
  presets: {
5
9
  'compiled-fork-stage1': compiledForkStage1,
6
10
  },
@@ -39,48 +39,50 @@ Anchors are underlined by default. This helps differentiate links from regular t
39
39
  accessibility requirement. Using color alone to differentiate links isn't accessible, especially if
40
40
  links are surrounded by other text.
41
41
 
42
- <DoDont
43
- type="do"
44
- image={{
45
- url: anchor1Do,
46
- alt: 'A link surrounded by regular text. The link provides color and an underline to differentiate the link from regular text.',
47
- }}
48
- >
49
- Use both underlines and color for links surrounded by regular text.
50
- </DoDont>
51
-
52
- <DoDont
53
- type="dont"
54
- image={{
55
- url: anchor1Dont,
56
- alt: "A link surrounded by regular text. The link provides only color but no underline to differentiate the link from regular text, however it's insufficient.",
57
- }}
58
- >
59
- Only use color to differentiate links from regular text.
60
- </DoDont>
42
+ <DoDontGrid>
43
+ <DoDont
44
+ type="do"
45
+ image={{
46
+ url: anchor1Do,
47
+ alt: 'A link surrounded by regular text. The link provides color and an underline to differentiate the link from regular text.',
48
+ }}
49
+ >
50
+ Use both underlines and color for links surrounded by regular text.
51
+ </DoDont>
52
+ <DoDont
53
+ type="dont"
54
+ image={{
55
+ url: anchor1Dont,
56
+ alt: "A link surrounded by regular text. The link provides only color but no underline to differentiate the link from regular text, however it's insufficient.",
57
+ }}
58
+ >
59
+ Only use color to differentiate links from regular text.
60
+ </DoDont>
61
+ </DoDontGrid>
61
62
 
62
63
  Only remove underlines and omit other style affordances such as color if the context surrounding the
63
64
  link makes it clear that it's interactive, such as in navigation or a card layout.
64
65
 
65
- <DoDont
66
- type="do"
67
- image={{
68
- url: anchor2Do,
69
- alt: 'Links in a navigation section. The links use a subtle text color and no underline, which is appropriate because the surrounding context makes it clear that they are links.',
70
- }}
71
- >
72
- Omit underlines and color when surrounding context makes it clear it's a link.
73
- </DoDont>
74
-
75
- <DoDont
76
- type="dont"
77
- image={{
78
- url: anchor2Dont,
79
- alt: 'Links in a navigation section. The links use a bright text color and underline, which is not required because the surrounding context makes it clear that they are links.',
80
- }}
81
- >
82
- Use underlines and color when surrounding context already makes it clear it's a link.
83
- </DoDont>
66
+ <DoDontGrid>
67
+ <DoDont
68
+ type="do"
69
+ image={{
70
+ url: anchor2Do,
71
+ alt: 'Links in a navigation section. The links use a subtle text color and no underline, which is appropriate because the surrounding context makes it clear that they are links.',
72
+ }}
73
+ >
74
+ Omit underlines and color when surrounding context makes it clear it's a link.
75
+ </DoDont>
76
+ <DoDont
77
+ type="dont"
78
+ image={{
79
+ url: anchor2Dont,
80
+ alt: 'Links in a navigation section. The links use a bright text color and underline, which is not required because the surrounding context makes it clear that they are links.',
81
+ }}
82
+ >
83
+ Use underlines and color when surrounding context already makes it clear it's a link.
84
+ </DoDont>
85
+ </DoDontGrid>
84
86
 
85
87
  Also, don't underline text that isn't a link. This makes the text look clickable because it looks a
86
88
  link.
@@ -32,28 +32,29 @@ Only use pressable when existing components such as [buttons](/components/button
32
32
  Using [existing components](/components) with safe customizations is usually faster and keeps
33
33
  Atlassian UI more visually consistent as things change.
34
34
 
35
- <DoDont
36
- type="do"
37
- image={{
38
- url: pressablePrimaryDo,
39
- alt: 'A set of custom buttons built with pressable that are not possible using existing design system components',
40
- }}
41
- >
42
- Use pressable to create buttons when there isn't an existing design system component to achieve
43
- your use case.
44
- </DoDont>
45
-
46
- <DoDont
47
- type="dont"
48
- image={{
49
- url: pressablePrimaryDont,
50
- alt: 'A custom button build with Pressable that looks similar to Button, an existing design system component',
51
- }}
52
- >
53
- Don't use pressable to redesign elements that already exists in the Atlassian design system, such
54
- as <a href="/components/button/examples">buttons</a>. This can cause visual and behavioral
55
- inconsistency in apps.
56
- </DoDont>
35
+ <DoDontGrid>
36
+ <DoDont
37
+ type="do"
38
+ image={{
39
+ url: pressablePrimaryDo,
40
+ alt: 'A set of custom buttons built with pressable that are not possible using existing design system components',
41
+ }}
42
+ >
43
+ Use pressable to create buttons when there isn't an existing design system component to achieve
44
+ your use case.
45
+ </DoDont>
46
+ <DoDont
47
+ type="dont"
48
+ image={{
49
+ url: pressablePrimaryDont,
50
+ alt: 'A custom button build with Pressable that looks similar to Button, an existing design system component',
51
+ }}
52
+ >
53
+ Don't use pressable to redesign elements that already exists in the Atlassian design system,
54
+ such as <a href="/components/button/examples">buttons</a>. This can cause visual and behavioral
55
+ inconsistency in apps.
56
+ </DoDont>
57
+ </DoDontGrid>
57
58
 
58
59
  ## Accessibility
59
60
 
@@ -70,7 +70,7 @@ var AnchorNoRef = function AnchorNoRef(_ref, ref) {
70
70
  action: 'clicked',
71
71
  componentName: componentName || 'Anchor',
72
72
  packageName: "@atlaskit/primitives",
73
- packageVersion: "17.1.1",
73
+ packageVersion: "0.0.0-development",
74
74
  analyticsData: analyticsContext,
75
75
  actionSubject: 'link'
76
76
  });
@@ -98,9 +98,7 @@ var AnchorNoRef = function AnchorNoRef(_ref, ref) {
98
98
  // @ts-expect-error we don't allow `a` on Focusable for makers as they should use Anchor instead
99
99
  , (0, _extends2.default)({
100
100
  as: Component,
101
- className: xcss
102
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- TODO: Properly type this and allow pass-through if we can determine the type
103
- ,
101
+ className: xcss,
104
102
  style: style,
105
103
  ref: ref
106
104
  // eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
@@ -336,9 +336,7 @@ var Box = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
336
336
  // @ts-ignore -- not using expect since it causes issues with help-center local consumption - className doesn't exist in the prop definition but we want to ensure it cannot be applied even if types are bypassed
337
337
  var _spreadClass = htmlAttributes.className,
338
338
  safeHtmlAttributes = (0, _objectWithoutProperties2.default)(htmlAttributes, _excluded2);
339
- var node = /*#__PURE__*/React.createElement(Component
340
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
341
- , (0, _extends2.default)({
339
+ var node = /*#__PURE__*/React.createElement(Component, (0, _extends2.default)({
342
340
  style: style
343
341
  // @ts-ignore -- Expression produces a union type that is too complex to represent. We may be able to narrow the type here but unsure.
344
342
  ,
@@ -40,9 +40,7 @@ var Focusable = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
40
40
  return /*#__PURE__*/React.createElement(Component, (0, _extends2.default)({}, safeHtmlAttributes, {
41
41
  // @ts-ignore Expression produces a union type that is too complex to represent. We may be able to narrow the type here but unsure.
42
42
  ref: ref,
43
- className: (0, _runtime.ax)(["_ymio1r31 _ypr0glyw _zcxs1o36 _mizu194a _1ah3dkaa _ra3xnqa1 _128mdkaa _1cvmnqa1 _4davt94y", isInset && "_1ah31gjf _2mwq1gjf", xcss])
44
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop
45
- ,
43
+ className: (0, _runtime.ax)(["_ymio1r31 _ypr0glyw _zcxs1o36 _mizu194a _1ah3dkaa _ra3xnqa1 _128mdkaa _1cvmnqa1 _4davt94y", isInset && "_1ah31gjf _2mwq1gjf", xcss]),
46
44
  style: style,
47
45
  "data-testid": testId
48
46
  }), children);
@@ -61,7 +61,7 @@ var Pressable = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
61
61
  action: 'clicked',
62
62
  componentName: componentName || 'Pressable',
63
63
  packageName: "@atlaskit/primitives",
64
- packageVersion: "17.1.1",
64
+ packageVersion: "0.0.0-development",
65
65
  analyticsData: analyticsContext,
66
66
  actionSubject: 'button'
67
67
  });
@@ -78,9 +78,7 @@ var Pressable = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
78
78
  // Adding a tabIndex of 0 to the button will allow it to be focused on click.
79
79
  // This is a known issue in Safari that is meant to be "intended", see https://bugs.webkit.org/show_bug.cgi?id=22261
80
80
  ,
81
- tabIndex: tabIndex !== null && tabIndex !== void 0 ? tabIndex : (0, _deviceCheck.isSafari)() && !isDisabled ? 0 : undefined
82
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- TODO: Properly type this and allow pass-through if we can determine the type
83
- ,
81
+ tabIndex: tabIndex !== null && tabIndex !== void 0 ? tabIndex : (0, _deviceCheck.isSafari)() && !isDisabled ? 0 : undefined,
84
82
  style: style
85
83
  }, safeHtmlAttributes, {
86
84
  type: type,
@@ -26,7 +26,7 @@ var _excluded = ["href", "children", "backgroundColor", "newWindowLabel", "paddi
26
26
  * @jsxRuntime classic
27
27
  * @jsx jsx
28
28
  */
29
- // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
29
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
30
30
  // TODO: duplicates FocusRing styles from `@atlaskit/focus-ring`.
31
31
  var focusRingStyles = (0, _react2.css)({
32
32
  '&:focus, &:focus-visible': {
@@ -105,7 +105,7 @@ var AnchorNoRef = function AnchorNoRef(_ref, ref) {
105
105
  action: 'clicked',
106
106
  componentName: componentName || 'Anchor',
107
107
  packageName: "@atlaskit/primitives",
108
- packageVersion: "17.1.1",
108
+ packageVersion: "0.0.0-development",
109
109
  analyticsData: analyticsContext,
110
110
  actionSubject: 'link'
111
111
  });
@@ -130,9 +130,7 @@ var AnchorNoRef = function AnchorNoRef(_ref, ref) {
130
130
  var hrefObjectUsedWithoutRouterLink = RouterLink === undefined && (0, _typeof2.default)(href) === 'object';
131
131
  (0, _tinyInvariant.default)(!hrefObjectUsedWithoutRouterLink, "@atlaskit/primitives: Anchor primitive cannot pass an object to 'href' unless a router link is configured in the AppProvider");
132
132
  var Component = isRouterLink ? RouterLink : 'a';
133
- return (0, _react2.jsx)(Component
134
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
135
- , (0, _extends2.default)({
133
+ return (0, _react2.jsx)(Component, (0, _extends2.default)({
136
134
  style: style,
137
135
  ref: ref
138
136
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
@@ -14,7 +14,7 @@ var _xcss = require("../xcss/xcss");
14
14
  * @jsx jsx
15
15
  */
16
16
 
17
- // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
17
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports, @atlaskit/ui-styling-standard/use-compiled
18
18
 
19
19
  var baseStyles = (0, _react2.css)({
20
20
  boxSizing: 'border-box'
@@ -57,9 +57,7 @@ var Box = exports.Box = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref)
57
57
  var resolvedStyles = (0, _xcss.parseXcss)(xcss);
58
58
  var node =
59
59
  // @ts-expect-error Expression produces a union type that is too complex to represent. I think this is unavoidable
60
- (0, _react2.jsx)(Component
61
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
62
- , (0, _extends2.default)({
60
+ (0, _react2.jsx)(Component, (0, _extends2.default)({
63
61
  style: style
64
62
  // @ts-ignore Expression produces a union type that is too complex to represent. We may be able to narrow the type here but unsure.
65
63
  ,
@@ -97,7 +97,7 @@ var Pressable = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
97
97
  action: 'clicked',
98
98
  componentName: componentName || 'Pressable',
99
99
  packageName: "@atlaskit/primitives",
100
- packageVersion: "17.1.1",
100
+ packageVersion: "0.0.0-development",
101
101
  analyticsData: analyticsContext,
102
102
  actionSubject: 'button'
103
103
  });
@@ -108,7 +108,6 @@ var Pressable = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
108
108
  safeHtmlAttributes = (0, _objectWithoutProperties2.default)(htmlAttributes, _excluded2);
109
109
  var resolvedStyles = (0, _xcss.parseXcss)(xcss);
110
110
  return (0, _react2.jsx)("button", (0, _extends2.default)({
111
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
112
111
  style: style,
113
112
  ref: ref
114
113
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
@@ -14,7 +14,7 @@ var _buildMediaQueryCss = require("./build-media-query-css");
14
14
  * @jsx jsx
15
15
  */
16
16
 
17
- // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
17
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
18
18
 
19
19
  var hideAboveQueries = (0, _buildMediaQueryCss.UNSAFE_buildAboveMediaQueryCSS)({
20
20
  display: 'none'
@@ -56,7 +56,7 @@ const AnchorNoRef = ({
56
56
  action: 'clicked',
57
57
  componentName: componentName || 'Anchor',
58
58
  packageName: "@atlaskit/primitives",
59
- packageVersion: "17.1.1",
59
+ packageVersion: "0.0.0-development",
60
60
  analyticsData: analyticsContext,
61
61
  actionSubject: 'link'
62
62
  });
@@ -86,9 +86,7 @@ const AnchorNoRef = ({
86
86
  // @ts-expect-error we don't allow `a` on Focusable for makers as they should use Anchor instead
87
87
  , _extends({
88
88
  as: Component,
89
- className: xcss
90
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- TODO: Properly type this and allow pass-through if we can determine the type
91
- ,
89
+ className: xcss,
92
90
  style: style,
93
91
  ref: ref
94
92
  // eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
@@ -321,9 +321,7 @@ const Box = /*#__PURE__*/forwardRef(({
321
321
  className: _spreadClass,
322
322
  ...safeHtmlAttributes
323
323
  } = htmlAttributes;
324
- const node = /*#__PURE__*/React.createElement(Component
325
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
326
- , _extends({
324
+ const node = /*#__PURE__*/React.createElement(Component, _extends({
327
325
  style: style
328
326
  // @ts-ignore -- Expression produces a union type that is too complex to represent. We may be able to narrow the type here but unsure.
329
327
  ,
@@ -30,9 +30,7 @@ const Focusable = /*#__PURE__*/forwardRef(({
30
30
  return /*#__PURE__*/React.createElement(Component, _extends({}, safeHtmlAttributes, {
31
31
  // @ts-ignore Expression produces a union type that is too complex to represent. We may be able to narrow the type here but unsure.
32
32
  ref: ref,
33
- className: ax(["_ymio1r31 _ypr0glyw _zcxs1o36 _mizu194a _1ah3dkaa _ra3xnqa1 _128mdkaa _1cvmnqa1 _4davt94y", isInset && "_1ah31gjf _2mwq1gjf", xcss])
34
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop
35
- ,
33
+ className: ax(["_ymio1r31 _ypr0glyw _zcxs1o36 _mizu194a _1ah3dkaa _ra3xnqa1 _128mdkaa _1cvmnqa1 _4davt94y", isInset && "_1ah31gjf _2mwq1gjf", xcss]),
36
34
  style: style,
37
35
  "data-testid": testId
38
36
  }), children);
@@ -48,7 +48,7 @@ const Pressable = /*#__PURE__*/forwardRef(({
48
48
  action: 'clicked',
49
49
  componentName: componentName || 'Pressable',
50
50
  packageName: "@atlaskit/primitives",
51
- packageVersion: "17.1.1",
51
+ packageVersion: "0.0.0-development",
52
52
  analyticsData: analyticsContext,
53
53
  actionSubject: 'button'
54
54
  });
@@ -67,9 +67,7 @@ const Pressable = /*#__PURE__*/forwardRef(({
67
67
  // Adding a tabIndex of 0 to the button will allow it to be focused on click.
68
68
  // This is a known issue in Safari that is meant to be "intended", see https://bugs.webkit.org/show_bug.cgi?id=22261
69
69
  ,
70
- tabIndex: tabIndex !== null && tabIndex !== void 0 ? tabIndex : isSafari() && !isDisabled ? 0 : undefined
71
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- TODO: Properly type this and allow pass-through if we can determine the type
72
- ,
70
+ tabIndex: tabIndex !== null && tabIndex !== void 0 ? tabIndex : isSafari() && !isDisabled ? 0 : undefined,
73
71
  style: style
74
72
  }, safeHtmlAttributes, {
75
73
  type: type,
@@ -5,7 +5,7 @@ import _extends from "@babel/runtime/helpers/extends";
5
5
  */
6
6
  import { forwardRef, useCallback, useContext } from 'react';
7
7
 
8
- // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
8
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
9
9
  import { css, jsx } from '@emotion/react';
10
10
  import invariant from 'tiny-invariant';
11
11
  import { usePlatformLeafEventHandler } from '@atlaskit/analytics-next';
@@ -94,7 +94,7 @@ const AnchorNoRef = ({
94
94
  action: 'clicked',
95
95
  componentName: componentName || 'Anchor',
96
96
  packageName: "@atlaskit/primitives",
97
- packageVersion: "17.1.1",
97
+ packageVersion: "0.0.0-development",
98
98
  analyticsData: analyticsContext,
99
99
  actionSubject: 'link'
100
100
  });
@@ -121,9 +121,7 @@ const AnchorNoRef = ({
121
121
  const hrefObjectUsedWithoutRouterLink = RouterLink === undefined && typeof href === 'object';
122
122
  invariant(!hrefObjectUsedWithoutRouterLink, `@atlaskit/primitives: Anchor primitive cannot pass an object to 'href' unless a router link is configured in the AppProvider`);
123
123
  const Component = isRouterLink ? RouterLink : 'a';
124
- return jsx(Component
125
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
126
- , _extends({
124
+ return jsx(Component, _extends({
127
125
  style: style,
128
126
  ref: ref
129
127
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
@@ -4,7 +4,7 @@
4
4
  */
5
5
  import React from 'react';
6
6
 
7
- // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
7
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports, @atlaskit/ui-styling-standard/use-compiled
8
8
  import { css, jsx } from '@emotion/react';
9
9
  import { parseXcss } from '../xcss/xcss';
10
10
  const baseStyles = css({
@@ -51,9 +51,7 @@ export const Box = /*#__PURE__*/forwardRef(({
51
51
  const resolvedStyles = parseXcss(xcss);
52
52
  const node =
53
53
  // @ts-expect-error Expression produces a union type that is too complex to represent. I think this is unavoidable
54
- jsx(Component
55
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
56
- , _extends({
54
+ jsx(Component, _extends({
57
55
  style: style
58
56
  // @ts-ignore Expression produces a union type that is too complex to represent. We may be able to narrow the type here but unsure.
59
57
  ,
@@ -86,7 +86,7 @@ const Pressable = /*#__PURE__*/forwardRef(({
86
86
  action: 'clicked',
87
87
  componentName: componentName || 'Pressable',
88
88
  packageName: "@atlaskit/primitives",
89
- packageVersion: "17.1.1",
89
+ packageVersion: "0.0.0-development",
90
90
  analyticsData: analyticsContext,
91
91
  actionSubject: 'button'
92
92
  });
@@ -99,7 +99,6 @@ const Pressable = /*#__PURE__*/forwardRef(({
99
99
  } = htmlAttributes;
100
100
  const resolvedStyles = parseXcss(xcss);
101
101
  return jsx("button", _extends({
102
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
103
102
  style: style,
104
103
  ref: ref
105
104
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
@@ -3,7 +3,7 @@
3
3
  * @jsx jsx
4
4
  */
5
5
 
6
- // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
6
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
7
7
  import { jsx } from '@emotion/react';
8
8
  import { parseXcss } from '../xcss/xcss';
9
9
  import { UNSAFE_buildAboveMediaQueryCSS, UNSAFE_buildBelowMediaQueryCSS } from './build-media-query-css';
@@ -61,7 +61,7 @@ var AnchorNoRef = function AnchorNoRef(_ref, ref) {
61
61
  action: 'clicked',
62
62
  componentName: componentName || 'Anchor',
63
63
  packageName: "@atlaskit/primitives",
64
- packageVersion: "17.1.1",
64
+ packageVersion: "0.0.0-development",
65
65
  analyticsData: analyticsContext,
66
66
  actionSubject: 'link'
67
67
  });
@@ -89,9 +89,7 @@ var AnchorNoRef = function AnchorNoRef(_ref, ref) {
89
89
  // @ts-expect-error we don't allow `a` on Focusable for makers as they should use Anchor instead
90
90
  , _extends({
91
91
  as: Component,
92
- className: xcss
93
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- TODO: Properly type this and allow pass-through if we can determine the type
94
- ,
92
+ className: xcss,
95
93
  style: style,
96
94
  ref: ref
97
95
  // eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
@@ -328,9 +328,7 @@ var Box = /*#__PURE__*/forwardRef(function (_ref, ref) {
328
328
  // @ts-ignore -- not using expect since it causes issues with help-center local consumption - className doesn't exist in the prop definition but we want to ensure it cannot be applied even if types are bypassed
329
329
  var _spreadClass = htmlAttributes.className,
330
330
  safeHtmlAttributes = _objectWithoutProperties(htmlAttributes, _excluded2);
331
- var node = /*#__PURE__*/React.createElement(Component
332
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
333
- , _extends({
331
+ var node = /*#__PURE__*/React.createElement(Component, _extends({
334
332
  style: style
335
333
  // @ts-ignore -- Expression produces a union type that is too complex to represent. We may be able to narrow the type here but unsure.
336
334
  ,
@@ -31,9 +31,7 @@ var Focusable = /*#__PURE__*/forwardRef(function (_ref, ref) {
31
31
  return /*#__PURE__*/React.createElement(Component, _extends({}, safeHtmlAttributes, {
32
32
  // @ts-ignore Expression produces a union type that is too complex to represent. We may be able to narrow the type here but unsure.
33
33
  ref: ref,
34
- className: ax(["_ymio1r31 _ypr0glyw _zcxs1o36 _mizu194a _1ah3dkaa _ra3xnqa1 _128mdkaa _1cvmnqa1 _4davt94y", isInset && "_1ah31gjf _2mwq1gjf", xcss])
35
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop
36
- ,
34
+ className: ax(["_ymio1r31 _ypr0glyw _zcxs1o36 _mizu194a _1ah3dkaa _ra3xnqa1 _128mdkaa _1cvmnqa1 _4davt94y", isInset && "_1ah31gjf _2mwq1gjf", xcss]),
37
35
  style: style,
38
36
  "data-testid": testId
39
37
  }), children);
@@ -52,7 +52,7 @@ var Pressable = /*#__PURE__*/forwardRef(function (_ref, ref) {
52
52
  action: 'clicked',
53
53
  componentName: componentName || 'Pressable',
54
54
  packageName: "@atlaskit/primitives",
55
- packageVersion: "17.1.1",
55
+ packageVersion: "0.0.0-development",
56
56
  analyticsData: analyticsContext,
57
57
  actionSubject: 'button'
58
58
  });
@@ -69,9 +69,7 @@ var Pressable = /*#__PURE__*/forwardRef(function (_ref, ref) {
69
69
  // Adding a tabIndex of 0 to the button will allow it to be focused on click.
70
70
  // This is a known issue in Safari that is meant to be "intended", see https://bugs.webkit.org/show_bug.cgi?id=22261
71
71
  ,
72
- tabIndex: tabIndex !== null && tabIndex !== void 0 ? tabIndex : isSafari() && !isDisabled ? 0 : undefined
73
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- TODO: Properly type this and allow pass-through if we can determine the type
74
- ,
72
+ tabIndex: tabIndex !== null && tabIndex !== void 0 ? tabIndex : isSafari() && !isDisabled ? 0 : undefined,
75
73
  style: style
76
74
  }, safeHtmlAttributes, {
77
75
  type: type,
@@ -10,7 +10,7 @@ var _excluded = ["href", "children", "backgroundColor", "newWindowLabel", "paddi
10
10
  */
11
11
  import { forwardRef, useCallback, useContext } from 'react';
12
12
 
13
- // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
13
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
14
14
  import { css, jsx } from '@emotion/react';
15
15
  import invariant from 'tiny-invariant';
16
16
  import { usePlatformLeafEventHandler } from '@atlaskit/analytics-next';
@@ -99,7 +99,7 @@ var AnchorNoRef = function AnchorNoRef(_ref, ref) {
99
99
  action: 'clicked',
100
100
  componentName: componentName || 'Anchor',
101
101
  packageName: "@atlaskit/primitives",
102
- packageVersion: "17.1.1",
102
+ packageVersion: "0.0.0-development",
103
103
  analyticsData: analyticsContext,
104
104
  actionSubject: 'link'
105
105
  });
@@ -124,9 +124,7 @@ var AnchorNoRef = function AnchorNoRef(_ref, ref) {
124
124
  var hrefObjectUsedWithoutRouterLink = RouterLink === undefined && _typeof(href) === 'object';
125
125
  invariant(!hrefObjectUsedWithoutRouterLink, "@atlaskit/primitives: Anchor primitive cannot pass an object to 'href' unless a router link is configured in the AppProvider");
126
126
  var Component = isRouterLink ? RouterLink : 'a';
127
- return jsx(Component
128
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
129
- , _extends({
127
+ return jsx(Component, _extends({
130
128
  style: style,
131
129
  ref: ref
132
130
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
@@ -5,7 +5,7 @@ import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
5
5
  */
6
6
  import React from 'react';
7
7
 
8
- // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
8
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports, @atlaskit/ui-styling-standard/use-compiled
9
9
  import { css, jsx } from '@emotion/react';
10
10
  import { parseXcss } from '../xcss/xcss';
11
11
  var baseStyles = css({
@@ -52,9 +52,7 @@ export var Box = /*#__PURE__*/forwardRef(function (_ref, ref) {
52
52
  var resolvedStyles = parseXcss(xcss);
53
53
  var node =
54
54
  // @ts-expect-error Expression produces a union type that is too complex to represent. I think this is unavoidable
55
- jsx(Component
56
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
57
- , _extends({
55
+ jsx(Component, _extends({
58
56
  style: style
59
57
  // @ts-ignore Expression produces a union type that is too complex to represent. We may be able to narrow the type here but unsure.
60
58
  ,
@@ -91,7 +91,7 @@ var Pressable = /*#__PURE__*/forwardRef(function (_ref, ref) {
91
91
  action: 'clicked',
92
92
  componentName: componentName || 'Pressable',
93
93
  packageName: "@atlaskit/primitives",
94
- packageVersion: "17.1.1",
94
+ packageVersion: "0.0.0-development",
95
95
  analyticsData: analyticsContext,
96
96
  actionSubject: 'button'
97
97
  });
@@ -102,7 +102,6 @@ var Pressable = /*#__PURE__*/forwardRef(function (_ref, ref) {
102
102
  safeHtmlAttributes = _objectWithoutProperties(htmlAttributes, _excluded2);
103
103
  var resolvedStyles = parseXcss(xcss);
104
104
  return jsx("button", _extends({
105
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
106
105
  style: style,
107
106
  ref: ref
108
107
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
@@ -4,7 +4,7 @@ import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
4
4
  * @jsx jsx
5
5
  */
6
6
 
7
- // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
7
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
8
8
  import { jsx } from '@emotion/react';
9
9
  import { parseXcss } from '../xcss/xcss';
10
10
  import { UNSAFE_buildAboveMediaQueryCSS, UNSAFE_buildBelowMediaQueryCSS } from './build-media-query-css';
@@ -2,7 +2,7 @@
2
2
  * @jsxRuntime classic
3
3
  * @jsx jsx
4
4
  */
5
- import { type AriaAttributes, type ElementType, type ReactNode } from 'react';
5
+ import { type AriaAttributes, type ElementType, type ForwardRefExoticComponent, type MemoExoticComponent, type ReactNode, type RefAttributes } from 'react';
6
6
  import type { AlignItems, BasePrimitiveProps, Direction, GapToken, JustifyContent, Wrap } from './types';
7
7
  export type FlexProps<T extends ElementType = 'div'> = {
8
8
  /**
@@ -67,5 +67,5 @@ export type FlexProps<T extends ElementType = 'div'> = {
67
67
  * )
68
68
  * ```
69
69
  */
70
- declare const Flex: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<Omit<FlexProps<ElementType>, "ref"> & import("react").RefAttributes<any>>>;
70
+ declare const Flex: MemoExoticComponent<ForwardRefExoticComponent<Omit<FlexProps<ElementType>, 'ref'> & RefAttributes<any>>>;
71
71
  export default Flex;