@atlaskit/status 1.4.9 → 1.4.10

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 (31) hide show
  1. package/CHANGELOG.md +291 -126
  2. package/afm-cc/tsconfig.json +3 -0
  3. package/afm-jira/tsconfig.json +40 -0
  4. package/dist/cjs/components/Status.js +6 -2
  5. package/dist/cjs/components/StatusPicker.js +9 -5
  6. package/dist/cjs/components/analytics.js +1 -1
  7. package/dist/cjs/components/internal/color-palette.js +12 -7
  8. package/dist/cjs/components/internal/color.js +20 -7
  9. package/dist/es2019/components/Status.js +6 -1
  10. package/dist/es2019/components/StatusPicker.js +9 -3
  11. package/dist/es2019/components/analytics.js +1 -1
  12. package/dist/es2019/components/internal/color-palette.js +16 -12
  13. package/dist/es2019/components/internal/color.js +29 -27
  14. package/dist/esm/components/Status.js +6 -1
  15. package/dist/esm/components/StatusPicker.js +9 -3
  16. package/dist/esm/components/analytics.js +1 -1
  17. package/dist/esm/components/internal/color-palette.js +12 -7
  18. package/dist/esm/components/internal/color.js +21 -8
  19. package/dist/types/components/Status.d.ts +1 -1
  20. package/dist/types/components/StatusPicker.d.ts +2 -2
  21. package/dist/types/components/analytics.d.ts +1 -1
  22. package/dist/types/components/internal/color-palette.d.ts +2 -2
  23. package/dist/types/components/internal/color.d.ts +1 -1
  24. package/dist/types-ts4.5/components/Status.d.ts +1 -1
  25. package/dist/types-ts4.5/components/StatusPicker.d.ts +2 -2
  26. package/dist/types-ts4.5/components/analytics.d.ts +1 -1
  27. package/dist/types-ts4.5/components/internal/color-palette.d.ts +2 -2
  28. package/dist/types-ts4.5/components/internal/color.d.ts +1 -1
  29. package/docs/0-intro.tsx +15 -21
  30. package/package.json +79 -80
  31. package/report.api.md +35 -36
@@ -27,6 +27,9 @@
27
27
  {
28
28
  "path": "../../../design-system/lozenge/afm-cc/tsconfig.json"
29
29
  },
30
+ {
31
+ "path": "../../../design-system/primitives/afm-cc/tsconfig.json"
32
+ },
30
33
  {
31
34
  "path": "../../../design-system/textfield/afm-cc/tsconfig.json"
32
35
  },
@@ -0,0 +1,40 @@
1
+ {
2
+ "extends": "../../../../tsconfig.products.json",
3
+ "compilerOptions": {
4
+ "declaration": true,
5
+ "target": "es5",
6
+ "outDir": "../../../../../tsDist/@atlaskit__status/app",
7
+ "composite": true,
8
+ "rootDir": "../",
9
+ "baseUrl": "../"
10
+ },
11
+ "include": [
12
+ "../src/**/*.ts",
13
+ "../src/**/*.tsx"
14
+ ],
15
+ "exclude": [
16
+ "../src/**/__tests__/*",
17
+ "../src/**/*.test.*",
18
+ "../src/**/test.*"
19
+ ],
20
+ "references": [
21
+ {
22
+ "path": "../../../analytics/analytics-next/afm-jira/tsconfig.json"
23
+ },
24
+ {
25
+ "path": "../../../design-system/icon/afm-jira/tsconfig.json"
26
+ },
27
+ {
28
+ "path": "../../../design-system/lozenge/afm-jira/tsconfig.json"
29
+ },
30
+ {
31
+ "path": "../../../design-system/textfield/afm-jira/tsconfig.json"
32
+ },
33
+ {
34
+ "path": "../../../design-system/theme/afm-jira/tsconfig.json"
35
+ },
36
+ {
37
+ "path": "../../../design-system/tokens/afm-jira/tsconfig.json"
38
+ }
39
+ ]
40
+ }
@@ -19,7 +19,7 @@ var _analyticsNext = require("@atlaskit/analytics-next");
19
19
  var _analytics = require("./analytics");
20
20
  var _constants = require("./constants");
21
21
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
22
- function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /** @jsx jsx */
22
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /** @jsx jsx */ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
23
23
  // Disabling linting for nextline since these values are used as text reference, but not used as part of the CSS
24
24
  // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage, @atlaskit/design-system/ensure-design-token-usage/preview
25
25
 
@@ -44,7 +44,9 @@ var MAX_WIDTH = 200;
44
44
  * See DSP-7701 for additional context.
45
45
  */
46
46
  var inlineBlockStyles = (0, _react2.css)({
47
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
47
48
  '& > *': {
49
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-important-styles -- Ignored via go/DSP-18766
48
50
  display: 'inline-block !important',
49
51
  lineHeight: '16px',
50
52
  verticalAlign: 'middle'
@@ -97,7 +99,9 @@ var StatusInternal = /*#__PURE__*/function (_PureComponent) {
97
99
  var appearance = colorToLozengeAppearanceMap[color] || DEFAULT_APPEARANCE;
98
100
  // Note: ommitted data-local-id attribute to avoid copying/pasting the same localId
99
101
  return (0, _react2.jsx)("span", {
100
- css: isAndroidChromium ? inlineBlockStyles : undefined,
102
+ css: isAndroidChromium ? inlineBlockStyles : undefined
103
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
104
+ ,
101
105
  className: "status-lozenge-span",
102
106
  onClick: onClick,
103
107
  onMouseEnter: this.handleMouseEnter,
@@ -13,20 +13,24 @@ var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits
13
13
  var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));
14
14
  var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));
15
15
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
16
- var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
17
16
  var _textfield = _interopRequireDefault(require("@atlaskit/textfield"));
18
17
  var _react = _interopRequireWildcard(require("react"));
19
18
  var _reactIntlNext = require("react-intl-next");
20
19
  var _react2 = require("@emotion/react");
21
20
  var _colorPalette = _interopRequireDefault(require("./internal/color-palette"));
22
21
  var _i18n = require("./i18n");
23
- var _templateObject;
24
- /** @jsx jsx */
22
+ var _colors = require("@atlaskit/theme/colors");
25
23
  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); }
26
24
  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; }
27
25
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
28
- function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
29
- var fieldTextWrapperStyles = (0, _react2.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n margin: 0 ", ";\n"])), "var(--ds-space-100, 8px)");
26
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /** @jsx jsx */ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
27
+ var fieldTextWrapperStyles = (0, _react2.css)({
28
+ margin: "0 ".concat("var(--ds-space-100, 8px)"),
29
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
30
+ '& [data-ds--text-field--container]': {
31
+ borderColor: "var(--ds-border-bold, ".concat(_colors.N80A, ")")
32
+ }
33
+ });
30
34
  var Picker = /*#__PURE__*/function (_PureComponent) {
31
35
  (0, _inherits2.default)(Picker, _PureComponent);
32
36
  var _super = _createSuper(Picker);
@@ -10,7 +10,7 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
10
10
  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; }
11
11
  var ELEMENTS_CHANNEL = exports.ELEMENTS_CHANNEL = 'fabric-elements';
12
12
  var packageName = "@atlaskit/status";
13
- var packageVersion = "1.4.9";
13
+ var packageVersion = "1.4.10";
14
14
  var createStatusAnalyticsAndFire = exports.createStatusAnalyticsAndFire = function createStatusAnalyticsAndFire(createAnalyticsEvent) {
15
15
  return function (payload) {
16
16
  var statusPayload = _objectSpread(_objectSpread({}, payload), {}, {
@@ -14,10 +14,13 @@ var _react2 = require("@emotion/react");
14
14
  var _color = _interopRequireDefault(require("./color"));
15
15
  var _templateObject;
16
16
  /** @jsx jsx */
17
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
17
18
  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); }
18
19
  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; }
19
20
  var palette = [['neutral', "var(--ds-background-neutral, ".concat(colors.N40, ")"), "var(--ds-border-bold, ".concat(colors.N400, ")"), "var(--ds-icon, ".concat(colors.N400, ")")], ['purple', "var(--ds-background-discovery, ".concat(colors.P50, ")"), "var(--ds-border-discovery, ".concat(colors.P400, ")"), "var(--ds-icon-discovery, ".concat(colors.P400, ")")], ['blue', "var(--ds-background-information, ".concat(colors.B50, ")"), "var(--ds-border-information, ".concat(colors.B400, ")"), "var(--ds-icon-information, ".concat(colors.B400, ")")], ['red', "var(--ds-background-danger, ".concat(colors.R50, ")"), "var(--ds-border-danger, ".concat(colors.R400, ")"), "var(--ds-icon-danger, ".concat(colors.R400, ")")], ['yellow', "var(--ds-background-warning, ".concat(colors.Y50, ")"), "var(--ds-border-warning, ".concat(colors.Y400, ")"), "var(--ds-icon-warning, ".concat(colors.Y400, ")")], ['green', "var(--ds-background-success, ".concat(colors.G50, ")"), "var(--ds-border-success, ".concat(colors.G400, ")"), "var(--ds-icon-success, ".concat(colors.G400, ")")]];
20
- var colorPaletteWrapperStyles = (0, _react2.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n padding-left: 0px;\n margin: ", " ", " 0\n ", ";\n /* Firefox bug fix: https://product-fabric.atlassian.net/browse/ED-1789 */\n display: flex;\n flex-wrap: wrap;\n"])), "var(--ds-space-100, 8px)", "var(--ds-space-100, 8px)", "var(--ds-space-100, 8px)");
21
+
22
+ // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/design-system/no-css-tagged-template-expression -- Ignored via go/DSP-18766
23
+ var colorPaletteWrapperStyles = (0, _react2.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n\tpadding-left: 0px;\n\tmargin: ", " ", " 0 ", ";\n\t/* Firefox bug fix: https://product-fabric.atlassian.net/browse/ED-1789 */\n\tdisplay: flex;\n\tflex-wrap: wrap;\n"])), "var(--ds-space-100, 8px)", "var(--ds-space-100, 8px)", "var(--ds-space-100, 8px)");
21
24
  var VK_LEFT = 37; //ArrowLeft
22
25
  var VK_RIGHT = 39; //ArrowRight
23
26
  var VK_UP = 38; //ArrowUp
@@ -70,14 +73,16 @@ var _default = exports.default = function _default(_ref) {
70
73
  }, [currentFocusedColor, setCurrentFocusedColor, colorRefs]);
71
74
  return (
72
75
  /**
73
- We need to disable below eslint rule becuase of role "radiogroup". This role was added
74
- in https://a11y-internal.atlassian.net/browse/AK-832 to fix accessibility issue.
75
- When we migrated to emotion from styled component, we started getting this error.
76
- Task added in https://product-fabric.atlassian.net/wiki/spaces/E/pages/3182068181/Potential+improvements#Moderate-changes.
77
- */
76
+ We need to disable below eslint rule becuase of role "radiogroup". This role was added
77
+ in https://a11y-internal.atlassian.net/browse/AK-832 to fix accessibility issue.
78
+ When we migrated to emotion from styled component, we started getting this error.
79
+ Task added in https://product-fabric.atlassian.net/wiki/spaces/E/pages/3182068181/Potential+improvements#Moderate-changes.
80
+ */
78
81
  // eslint-disable-next-line jsx-a11y/interactive-supports-focus
79
82
  (0, _react2.jsx)("ul", {
80
- css: colorPaletteWrapperStyles,
83
+ css: colorPaletteWrapperStyles
84
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
85
+ ,
81
86
  className: className,
82
87
  style: {
83
88
  maxWidth: cols * 32
@@ -16,23 +16,36 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
16
16
  var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
17
17
  var _done = _interopRequireDefault(require("@atlaskit/icon/glyph/editor/done"));
18
18
  var _colors = require("@atlaskit/theme/colors");
19
+ var _primitives = require("@atlaskit/primitives");
19
20
  var _react = _interopRequireWildcard(require("react"));
20
21
  var _reactIntlNext = require("react-intl-next");
21
22
  var _react2 = require("@emotion/react");
22
23
  var _constants = require("../constants");
23
24
  var _i18n = require("../i18n");
24
- var _templateObject, _templateObject2;
25
+ var _templateObject;
25
26
  /** @jsx jsx */
27
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
26
28
  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); }
27
29
  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; }
28
30
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
29
31
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
30
- var buttonStyles = (0, _react2.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n height: 24px;\n width: 24px;\n background: ", ";\n padding: 0;\n border-radius: 4px;\n border: 1px solid ", ";\n cursor: pointer;\n display: block;\n box-sizing: border-box;\n overflow: hidden;\n"])), "var(--ds-background-neutral, ".concat(_colors.N900, ")"), "var(--ds-border, ".concat(_colors.N0, ")"));
32
+ var buttonStyles = (0, _primitives.xcss)({
33
+ height: '24px',
34
+ width: '24px',
35
+ background: 'color.background.neutral',
36
+ padding: 'space.0',
37
+ borderRadius: 'border.radius',
38
+ borderWidth: 'border.width',
39
+ borderStyle: 'solid',
40
+ borderColor: 'color.border',
41
+ display: 'block',
42
+ overflow: 'hidden'
43
+ });
31
44
 
32
45
  // We have tried with changing border and padding from 1px to token near version 2px,
33
46
  // the pop - up is being expanded to two lines.
34
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview
35
- var buttonWrapperStyles = (0, _react2.css)(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n border: 1px solid transparent;\n margin: 0 ", ";\n font-size: 0;\n display: flex;\n align-items: center;\n padding: 1px;\n border-radius: ", ";\n &:hover {\n border: 1px solid ", ";\n }\n"])), "var(--ds-space-025, 2px)", "var(--ds-space-075, 6px)", "var(--ds-border, ".concat(_colors.N50, ")"));
47
+ // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview, @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/design-system/no-css-tagged-template-expression -- Ignored via go/DSP-18766
48
+ var buttonWrapperStyles = (0, _react2.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n\tborder: 1px solid transparent;\n\tmargin: 0 ", ";\n\tfont-size: 0;\n\tdisplay: flex;\n\talign-items: center;\n\tpadding: 1px;\n\tborder-radius: ", ";\n\t&:hover {\n\t\tborder: 1px solid ", ";\n\t}\n"])), "var(--ds-space-025, 2px)", "var(--ds-space-075, 6px)", "var(--ds-border, ".concat(_colors.N50, ")"));
36
49
  var Color = exports.default = /*#__PURE__*/function (_PureComponent) {
37
50
  (0, _inherits2.default)(Color, _PureComponent);
38
51
  var _super = _createSuper(Color);
@@ -82,14 +95,13 @@ var Color = exports.default = /*#__PURE__*/function (_PureComponent) {
82
95
  return (0, _react2.jsx)("li", {
83
96
  css: buttonWrapperStyles
84
97
  }, (0, _react2.jsx)(_reactIntlNext.FormattedMessage, _i18n.messages["".concat(value, "Color")], function (labels) {
85
- return (0, _react2.jsx)("button", {
86
- css: buttonStyles,
98
+ return (0, _react2.jsx)(_primitives.Pressable, {
99
+ xcss: buttonStyles,
87
100
  onClick: _this2.onClick,
88
101
  onMouseEnter: _this2.onMouseEnter,
89
102
  onMouseLeave: _this2.onMouseLeave,
90
103
  onMouseDown: _this2.onMouseDown,
91
104
  tabIndex: tabIndex,
92
- className: "".concat(isSelected ? 'selected' : ''),
93
105
  title: labels[0]
94
106
  // button element does not support aria-selected.
95
107
  // For button selected (to be precise pressed) or not
@@ -99,6 +111,7 @@ var Color = exports.default = /*#__PURE__*/function (_PureComponent) {
99
111
  "aria-pressed": isSelected,
100
112
  style: {
101
113
  backgroundColor: backgroundColor || 'transparent',
114
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
102
115
  borderColor: borderColor
103
116
  },
104
117
  ref: setRef
@@ -1,6 +1,7 @@
1
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
2
  /** @jsx jsx */
3
3
  import { PureComponent } from 'react';
4
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
4
5
  import { css, jsx } from '@emotion/react';
5
6
  import Lozenge from '@atlaskit/lozenge';
6
7
  import { withAnalyticsEvents } from '@atlaskit/analytics-next';
@@ -31,7 +32,9 @@ const MAX_WIDTH = 200;
31
32
  * See DSP-7701 for additional context.
32
33
  */
33
34
  const inlineBlockStyles = css({
35
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
34
36
  '& > *': {
37
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-important-styles -- Ignored via go/DSP-18766
35
38
  display: 'inline-block !important',
36
39
  lineHeight: '16px',
37
40
  verticalAlign: 'middle'
@@ -75,7 +78,9 @@ class StatusInternal extends PureComponent {
75
78
  const appearance = colorToLozengeAppearanceMap[color] || DEFAULT_APPEARANCE;
76
79
  // Note: ommitted data-local-id attribute to avoid copying/pasting the same localId
77
80
  return jsx("span", {
78
- css: isAndroidChromium ? inlineBlockStyles : undefined,
81
+ css: isAndroidChromium ? inlineBlockStyles : undefined
82
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
83
+ ,
79
84
  className: "status-lozenge-span",
80
85
  onClick: onClick,
81
86
  onMouseEnter: this.handleMouseEnter,
@@ -3,12 +3,18 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
3
3
  import TextField from '@atlaskit/textfield';
4
4
  import React, { PureComponent } from 'react';
5
5
  import { injectIntl } from 'react-intl-next';
6
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
6
7
  import { css, jsx } from '@emotion/react';
7
8
  import ColorPalette from './internal/color-palette';
8
9
  import { messages } from './i18n';
9
- const fieldTextWrapperStyles = css`
10
- margin: 0 ${"var(--ds-space-100, 8px)"};
11
- `;
10
+ import { N80A } from '@atlaskit/theme/colors';
11
+ const fieldTextWrapperStyles = css({
12
+ margin: `0 ${"var(--ds-space-100, 8px)"}`,
13
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
14
+ '& [data-ds--text-field--container]': {
15
+ borderColor: `var(--ds-border-bold, ${N80A})`
16
+ }
17
+ });
12
18
  class Picker extends PureComponent {
13
19
  constructor(...args) {
14
20
  super(...args);
@@ -1,6 +1,6 @@
1
1
  export const ELEMENTS_CHANNEL = 'fabric-elements';
2
2
  const packageName = "@atlaskit/status";
3
- const packageVersion = "1.4.9";
3
+ const packageVersion = "1.4.10";
4
4
  export const createStatusAnalyticsAndFire = createAnalyticsEvent => payload => {
5
5
  const statusPayload = {
6
6
  ...payload,
@@ -1,16 +1,18 @@
1
1
  /** @jsx jsx */
2
2
  import * as colors from '@atlaskit/theme/colors';
3
3
  import React, { useEffect, useRef, useCallback, useState } from 'react';
4
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
4
5
  import { css, jsx } from '@emotion/react';
5
6
  import Color from './color';
6
7
  const palette = [['neutral', `var(--ds-background-neutral, ${colors.N40})`, `var(--ds-border-bold, ${colors.N400})`, `var(--ds-icon, ${colors.N400})`], ['purple', `var(--ds-background-discovery, ${colors.P50})`, `var(--ds-border-discovery, ${colors.P400})`, `var(--ds-icon-discovery, ${colors.P400})`], ['blue', `var(--ds-background-information, ${colors.B50})`, `var(--ds-border-information, ${colors.B400})`, `var(--ds-icon-information, ${colors.B400})`], ['red', `var(--ds-background-danger, ${colors.R50})`, `var(--ds-border-danger, ${colors.R400})`, `var(--ds-icon-danger, ${colors.R400})`], ['yellow', `var(--ds-background-warning, ${colors.Y50})`, `var(--ds-border-warning, ${colors.Y400})`, `var(--ds-icon-warning, ${colors.Y400})`], ['green', `var(--ds-background-success, ${colors.G50})`, `var(--ds-border-success, ${colors.G400})`, `var(--ds-icon-success, ${colors.G400})`]];
8
+
9
+ // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/design-system/no-css-tagged-template-expression -- Ignored via go/DSP-18766
7
10
  const colorPaletteWrapperStyles = css`
8
- padding-left: 0px;
9
- margin: ${"var(--ds-space-100, 8px)"} ${"var(--ds-space-100, 8px)"} 0
10
- ${"var(--ds-space-100, 8px)"};
11
- /* Firefox bug fix: https://product-fabric.atlassian.net/browse/ED-1789 */
12
- display: flex;
13
- flex-wrap: wrap;
11
+ padding-left: 0px;
12
+ margin: ${"var(--ds-space-100, 8px)"} ${"var(--ds-space-100, 8px)"} 0 ${"var(--ds-space-100, 8px)"};
13
+ /* Firefox bug fix: https://product-fabric.atlassian.net/browse/ED-1789 */
14
+ display: flex;
15
+ flex-wrap: wrap;
14
16
  `;
15
17
  const VK_LEFT = 37; //ArrowLeft
16
18
  const VK_RIGHT = 39; //ArrowRight
@@ -57,14 +59,16 @@ export default (({
57
59
  }, [currentFocusedColor, setCurrentFocusedColor, colorRefs]);
58
60
  return (
59
61
  /**
60
- We need to disable below eslint rule becuase of role "radiogroup". This role was added
61
- in https://a11y-internal.atlassian.net/browse/AK-832 to fix accessibility issue.
62
- When we migrated to emotion from styled component, we started getting this error.
63
- Task added in https://product-fabric.atlassian.net/wiki/spaces/E/pages/3182068181/Potential+improvements#Moderate-changes.
64
- */
62
+ We need to disable below eslint rule becuase of role "radiogroup". This role was added
63
+ in https://a11y-internal.atlassian.net/browse/AK-832 to fix accessibility issue.
64
+ When we migrated to emotion from styled component, we started getting this error.
65
+ Task added in https://product-fabric.atlassian.net/wiki/spaces/E/pages/3182068181/Potential+improvements#Moderate-changes.
66
+ */
65
67
  // eslint-disable-next-line jsx-a11y/interactive-supports-focus
66
68
  jsx("ul", {
67
- css: colorPaletteWrapperStyles,
69
+ css: colorPaletteWrapperStyles
70
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
71
+ ,
68
72
  className: className,
69
73
  style: {
70
74
  maxWidth: cols * 32
@@ -1,39 +1,41 @@
1
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
2
  /** @jsx jsx */
3
3
  import EditorDoneIcon from '@atlaskit/icon/glyph/editor/done';
4
- import { N900, N0, N50 } from '@atlaskit/theme/colors';
4
+ import { N50 } from '@atlaskit/theme/colors';
5
+ import { Pressable, xcss } from '@atlaskit/primitives';
5
6
  import React, { PureComponent } from 'react';
6
7
  import { FormattedMessage } from 'react-intl-next';
8
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
7
9
  import { css, jsx } from '@emotion/react';
8
10
  import { ANALYTICS_HOVER_DELAY } from '../constants';
9
11
  import { messages } from '../i18n';
10
- const buttonStyles = css`
11
- height: 24px;
12
- width: 24px;
13
- background: ${`var(--ds-background-neutral, ${N900})`};
14
- padding: 0;
15
- border-radius: 4px;
16
- border: 1px solid ${`var(--ds-border, ${N0})`};
17
- cursor: pointer;
18
- display: block;
19
- box-sizing: border-box;
20
- overflow: hidden;
21
- `;
12
+ const buttonStyles = xcss({
13
+ height: '24px',
14
+ width: '24px',
15
+ background: 'color.background.neutral',
16
+ padding: 'space.0',
17
+ borderRadius: 'border.radius',
18
+ borderWidth: 'border.width',
19
+ borderStyle: 'solid',
20
+ borderColor: 'color.border',
21
+ display: 'block',
22
+ overflow: 'hidden'
23
+ });
22
24
 
23
25
  // We have tried with changing border and padding from 1px to token near version 2px,
24
26
  // the pop - up is being expanded to two lines.
25
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview
27
+ // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview, @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/design-system/no-css-tagged-template-expression -- Ignored via go/DSP-18766
26
28
  const buttonWrapperStyles = css`
27
- border: 1px solid transparent;
28
- margin: 0 ${"var(--ds-space-025, 2px)"};
29
- font-size: 0;
30
- display: flex;
31
- align-items: center;
32
- padding: 1px;
33
- border-radius: ${"var(--ds-space-075, 6px)"};
34
- &:hover {
35
- border: 1px solid ${`var(--ds-border, ${N50})`};
36
- }
29
+ border: 1px solid transparent;
30
+ margin: 0 ${"var(--ds-space-025, 2px)"};
31
+ font-size: 0;
32
+ display: flex;
33
+ align-items: center;
34
+ padding: 1px;
35
+ border-radius: ${"var(--ds-space-075, 6px)"};
36
+ &:hover {
37
+ border: 1px solid ${`var(--ds-border, ${N50})`};
38
+ }
37
39
  `;
38
40
  export default class Color extends PureComponent {
39
41
  constructor(...args) {
@@ -76,14 +78,13 @@ export default class Color extends PureComponent {
76
78
  } = this.props;
77
79
  return jsx("li", {
78
80
  css: buttonWrapperStyles
79
- }, jsx(FormattedMessage, messages[`${value}Color`], labels => jsx("button", {
80
- css: buttonStyles,
81
+ }, jsx(FormattedMessage, messages[`${value}Color`], labels => jsx(Pressable, {
82
+ xcss: buttonStyles,
81
83
  onClick: this.onClick,
82
84
  onMouseEnter: this.onMouseEnter,
83
85
  onMouseLeave: this.onMouseLeave,
84
86
  onMouseDown: this.onMouseDown,
85
87
  tabIndex: tabIndex,
86
- className: `${isSelected ? 'selected' : ''}`,
87
88
  title: labels[0]
88
89
  // button element does not support aria-selected.
89
90
  // For button selected (to be precise pressed) or not
@@ -93,6 +94,7 @@ export default class Color extends PureComponent {
93
94
  "aria-pressed": isSelected,
94
95
  style: {
95
96
  backgroundColor: backgroundColor || 'transparent',
97
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
96
98
  borderColor
97
99
  },
98
100
  ref: setRef
@@ -9,6 +9,7 @@ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflec
9
9
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
10
10
  /** @jsx jsx */
11
11
  import { PureComponent } from 'react';
12
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
12
13
  import { css, jsx } from '@emotion/react';
13
14
  import Lozenge from '@atlaskit/lozenge';
14
15
  import { withAnalyticsEvents } from '@atlaskit/analytics-next';
@@ -39,7 +40,9 @@ var MAX_WIDTH = 200;
39
40
  * See DSP-7701 for additional context.
40
41
  */
41
42
  var inlineBlockStyles = css({
43
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
42
44
  '& > *': {
45
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-important-styles -- Ignored via go/DSP-18766
43
46
  display: 'inline-block !important',
44
47
  lineHeight: '16px',
45
48
  verticalAlign: 'middle'
@@ -92,7 +95,9 @@ var StatusInternal = /*#__PURE__*/function (_PureComponent) {
92
95
  var appearance = colorToLozengeAppearanceMap[color] || DEFAULT_APPEARANCE;
93
96
  // Note: ommitted data-local-id attribute to avoid copying/pasting the same localId
94
97
  return jsx("span", {
95
- css: isAndroidChromium ? inlineBlockStyles : undefined,
98
+ css: isAndroidChromium ? inlineBlockStyles : undefined
99
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
100
+ ,
96
101
  className: "status-lozenge-span",
97
102
  onClick: onClick,
98
103
  onMouseEnter: this.handleMouseEnter,
@@ -5,18 +5,24 @@ import _inherits from "@babel/runtime/helpers/inherits";
5
5
  import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
6
6
  import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
7
7
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
8
- import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
9
- var _templateObject;
10
8
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
11
9
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
12
10
  /** @jsx jsx */
13
11
  import TextField from '@atlaskit/textfield';
14
12
  import React, { PureComponent } from 'react';
15
13
  import { injectIntl } from 'react-intl-next';
14
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
16
15
  import { css, jsx } from '@emotion/react';
17
16
  import ColorPalette from './internal/color-palette';
18
17
  import { messages } from './i18n';
19
- var fieldTextWrapperStyles = css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n margin: 0 ", ";\n"])), "var(--ds-space-100, 8px)");
18
+ import { N80A } from '@atlaskit/theme/colors';
19
+ var fieldTextWrapperStyles = css({
20
+ margin: "0 ".concat("var(--ds-space-100, 8px)"),
21
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
22
+ '& [data-ds--text-field--container]': {
23
+ borderColor: "var(--ds-border-bold, ".concat(N80A, ")")
24
+ }
25
+ });
20
26
  var Picker = /*#__PURE__*/function (_PureComponent) {
21
27
  _inherits(Picker, _PureComponent);
22
28
  var _super = _createSuper(Picker);
@@ -3,7 +3,7 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
3
3
  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) { _defineProperty(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; }
4
4
  export var ELEMENTS_CHANNEL = 'fabric-elements';
5
5
  var packageName = "@atlaskit/status";
6
- var packageVersion = "1.4.9";
6
+ var packageVersion = "1.4.10";
7
7
  export var createStatusAnalyticsAndFire = function createStatusAnalyticsAndFire(createAnalyticsEvent) {
8
8
  return function (payload) {
9
9
  var statusPayload = _objectSpread(_objectSpread({}, payload), {}, {
@@ -4,10 +4,13 @@ var _templateObject;
4
4
  /** @jsx jsx */
5
5
  import * as colors from '@atlaskit/theme/colors';
6
6
  import React, { useEffect, useRef, useCallback, useState } from 'react';
7
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
7
8
  import { css, jsx } from '@emotion/react';
8
9
  import Color from './color';
9
10
  var palette = [['neutral', "var(--ds-background-neutral, ".concat(colors.N40, ")"), "var(--ds-border-bold, ".concat(colors.N400, ")"), "var(--ds-icon, ".concat(colors.N400, ")")], ['purple', "var(--ds-background-discovery, ".concat(colors.P50, ")"), "var(--ds-border-discovery, ".concat(colors.P400, ")"), "var(--ds-icon-discovery, ".concat(colors.P400, ")")], ['blue', "var(--ds-background-information, ".concat(colors.B50, ")"), "var(--ds-border-information, ".concat(colors.B400, ")"), "var(--ds-icon-information, ".concat(colors.B400, ")")], ['red', "var(--ds-background-danger, ".concat(colors.R50, ")"), "var(--ds-border-danger, ".concat(colors.R400, ")"), "var(--ds-icon-danger, ".concat(colors.R400, ")")], ['yellow', "var(--ds-background-warning, ".concat(colors.Y50, ")"), "var(--ds-border-warning, ".concat(colors.Y400, ")"), "var(--ds-icon-warning, ".concat(colors.Y400, ")")], ['green', "var(--ds-background-success, ".concat(colors.G50, ")"), "var(--ds-border-success, ".concat(colors.G400, ")"), "var(--ds-icon-success, ".concat(colors.G400, ")")]];
10
- var colorPaletteWrapperStyles = css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n padding-left: 0px;\n margin: ", " ", " 0\n ", ";\n /* Firefox bug fix: https://product-fabric.atlassian.net/browse/ED-1789 */\n display: flex;\n flex-wrap: wrap;\n"])), "var(--ds-space-100, 8px)", "var(--ds-space-100, 8px)", "var(--ds-space-100, 8px)");
11
+
12
+ // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/design-system/no-css-tagged-template-expression -- Ignored via go/DSP-18766
13
+ var colorPaletteWrapperStyles = css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n\tpadding-left: 0px;\n\tmargin: ", " ", " 0 ", ";\n\t/* Firefox bug fix: https://product-fabric.atlassian.net/browse/ED-1789 */\n\tdisplay: flex;\n\tflex-wrap: wrap;\n"])), "var(--ds-space-100, 8px)", "var(--ds-space-100, 8px)", "var(--ds-space-100, 8px)");
11
14
  var VK_LEFT = 37; //ArrowLeft
12
15
  var VK_RIGHT = 39; //ArrowRight
13
16
  var VK_UP = 38; //ArrowUp
@@ -60,14 +63,16 @@ export default (function (_ref) {
60
63
  }, [currentFocusedColor, setCurrentFocusedColor, colorRefs]);
61
64
  return (
62
65
  /**
63
- We need to disable below eslint rule becuase of role "radiogroup". This role was added
64
- in https://a11y-internal.atlassian.net/browse/AK-832 to fix accessibility issue.
65
- When we migrated to emotion from styled component, we started getting this error.
66
- Task added in https://product-fabric.atlassian.net/wiki/spaces/E/pages/3182068181/Potential+improvements#Moderate-changes.
67
- */
66
+ We need to disable below eslint rule becuase of role "radiogroup". This role was added
67
+ in https://a11y-internal.atlassian.net/browse/AK-832 to fix accessibility issue.
68
+ When we migrated to emotion from styled component, we started getting this error.
69
+ Task added in https://product-fabric.atlassian.net/wiki/spaces/E/pages/3182068181/Potential+improvements#Moderate-changes.
70
+ */
68
71
  // eslint-disable-next-line jsx-a11y/interactive-supports-focus
69
72
  jsx("ul", {
70
- css: colorPaletteWrapperStyles,
73
+ css: colorPaletteWrapperStyles
74
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
75
+ ,
71
76
  className: className,
72
77
  style: {
73
78
  maxWidth: cols * 32
@@ -6,23 +6,36 @@ import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstruct
6
6
  import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
7
7
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
8
8
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
9
- var _templateObject, _templateObject2;
9
+ var _templateObject;
10
10
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
11
11
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
12
12
  /** @jsx jsx */
13
13
  import EditorDoneIcon from '@atlaskit/icon/glyph/editor/done';
14
- import { N900, N0, N50 } from '@atlaskit/theme/colors';
14
+ import { N50 } from '@atlaskit/theme/colors';
15
+ import { Pressable, xcss } from '@atlaskit/primitives';
15
16
  import React, { PureComponent } from 'react';
16
17
  import { FormattedMessage } from 'react-intl-next';
18
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
17
19
  import { css, jsx } from '@emotion/react';
18
20
  import { ANALYTICS_HOVER_DELAY } from '../constants';
19
21
  import { messages } from '../i18n';
20
- var buttonStyles = css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n height: 24px;\n width: 24px;\n background: ", ";\n padding: 0;\n border-radius: 4px;\n border: 1px solid ", ";\n cursor: pointer;\n display: block;\n box-sizing: border-box;\n overflow: hidden;\n"])), "var(--ds-background-neutral, ".concat(N900, ")"), "var(--ds-border, ".concat(N0, ")"));
22
+ var buttonStyles = xcss({
23
+ height: '24px',
24
+ width: '24px',
25
+ background: 'color.background.neutral',
26
+ padding: 'space.0',
27
+ borderRadius: 'border.radius',
28
+ borderWidth: 'border.width',
29
+ borderStyle: 'solid',
30
+ borderColor: 'color.border',
31
+ display: 'block',
32
+ overflow: 'hidden'
33
+ });
21
34
 
22
35
  // We have tried with changing border and padding from 1px to token near version 2px,
23
36
  // the pop - up is being expanded to two lines.
24
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview
25
- var buttonWrapperStyles = css(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n border: 1px solid transparent;\n margin: 0 ", ";\n font-size: 0;\n display: flex;\n align-items: center;\n padding: 1px;\n border-radius: ", ";\n &:hover {\n border: 1px solid ", ";\n }\n"])), "var(--ds-space-025, 2px)", "var(--ds-space-075, 6px)", "var(--ds-border, ".concat(N50, ")"));
37
+ // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview, @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/design-system/no-css-tagged-template-expression -- Ignored via go/DSP-18766
38
+ var buttonWrapperStyles = css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n\tborder: 1px solid transparent;\n\tmargin: 0 ", ";\n\tfont-size: 0;\n\tdisplay: flex;\n\talign-items: center;\n\tpadding: 1px;\n\tborder-radius: ", ";\n\t&:hover {\n\t\tborder: 1px solid ", ";\n\t}\n"])), "var(--ds-space-025, 2px)", "var(--ds-space-075, 6px)", "var(--ds-border, ".concat(N50, ")"));
26
39
  var Color = /*#__PURE__*/function (_PureComponent) {
27
40
  _inherits(Color, _PureComponent);
28
41
  var _super = _createSuper(Color);
@@ -72,14 +85,13 @@ var Color = /*#__PURE__*/function (_PureComponent) {
72
85
  return jsx("li", {
73
86
  css: buttonWrapperStyles
74
87
  }, jsx(FormattedMessage, messages["".concat(value, "Color")], function (labels) {
75
- return jsx("button", {
76
- css: buttonStyles,
88
+ return jsx(Pressable, {
89
+ xcss: buttonStyles,
77
90
  onClick: _this2.onClick,
78
91
  onMouseEnter: _this2.onMouseEnter,
79
92
  onMouseLeave: _this2.onMouseLeave,
80
93
  onMouseDown: _this2.onMouseDown,
81
94
  tabIndex: tabIndex,
82
- className: "".concat(isSelected ? 'selected' : ''),
83
95
  title: labels[0]
84
96
  // button element does not support aria-selected.
85
97
  // For button selected (to be precise pressed) or not
@@ -89,6 +101,7 @@ var Color = /*#__PURE__*/function (_PureComponent) {
89
101
  "aria-pressed": isSelected,
90
102
  style: {
91
103
  backgroundColor: backgroundColor || 'transparent',
104
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
92
105
  borderColor: borderColor
93
106
  },
94
107
  ref: setRef