@atlaskit/editor-plugin-text-color 2.0.0 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @atlaskit/editor-plugin-text-color
2
2
 
3
+ ## 2.0.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [#120533](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/120533)
8
+ [`f1bec731e278f`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/f1bec731e278f) -
9
+ Adds a `sideEffects` field to ensure this package does not have Compiled styles tree-shaken in the
10
+ future to avoid an accidental regression.
11
+
12
+ This is related to
13
+ https://community.developer.atlassian.com/t/rfc-73-migrating-our-components-to-compiled-css-in-js/85953
14
+
3
15
  ## 2.0.0
4
16
 
5
17
  ### Major Changes
@@ -26,6 +26,7 @@ var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
26
26
  var _textStyle = _interopRequireDefault(require("@atlaskit/icon/core/text-style"));
27
27
  var _chevronDown = _interopRequireDefault(require("@atlaskit/icon/utility/migration/chevron-down"));
28
28
  var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
29
+ var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
29
30
  var _changeColor = require("../../pm-plugins/commands/change-color");
30
31
  var _inputType = require("../../pm-plugins/utils/inputType");
31
32
  var _types = require("../../types");
@@ -200,7 +201,7 @@ var ToolbarTextColor = exports.ToolbarTextColor = /*#__PURE__*/function (_React$
200
201
  },
201
202
  trigger: (0, _react2.jsx)(_uiMenu.ToolbarButton, {
202
203
  buttonId: _uiMenu.TOOLBAR_BUTTON.TEXT_COLOR,
203
- spacing: isReducedSpacing ? reducedSpacing : 'default',
204
+ spacing: !isReducedSpacing || (0, _experiments.editorExperiment)('platform_editor_controls', 'variant1') ? 'default' : reducedSpacing,
204
205
  disabled: disabled || pluginState.disabled,
205
206
  selected: isOpen,
206
207
  "aria-label": labelTextColor,
@@ -6,7 +6,7 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
6
6
  import React from 'react';
7
7
 
8
8
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
9
- import { jsx, css } from '@emotion/react';
9
+ import { css, jsx } from '@emotion/react';
10
10
  import { injectIntl } from 'react-intl-next';
11
11
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE } from '@atlaskit/editor-common/analytics';
12
12
  import { DynamicStrokeIconDecoration, SteppedRainbowIconDecoration } from '@atlaskit/editor-common/icons';
@@ -19,6 +19,7 @@ import { akEditorMenuZIndex } from '@atlaskit/editor-shared-styles';
19
19
  import TextStyleIcon from '@atlaskit/icon/core/text-style';
20
20
  import ChevronDownIcon from '@atlaskit/icon/utility/migration/chevron-down';
21
21
  import { fg } from '@atlaskit/platform-feature-flags';
22
+ import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
22
23
  import { changeColor as changeColorWithAnalytics } from '../../pm-plugins/commands/change-color';
23
24
  import { getInputMethod } from '../../pm-plugins/utils/inputType';
24
25
  import { ToolbarType } from '../../types';
@@ -182,7 +183,7 @@ export class ToolbarTextColor extends React.Component {
182
183
  },
183
184
  trigger: jsx(ToolbarButton, {
184
185
  buttonId: TOOLBAR_BUTTON.TEXT_COLOR,
185
- spacing: isReducedSpacing ? reducedSpacing : 'default',
186
+ spacing: !isReducedSpacing || editorExperiment('platform_editor_controls', 'variant1') ? 'default' : reducedSpacing,
186
187
  disabled: disabled || pluginState.disabled,
187
188
  selected: isOpen,
188
189
  "aria-label": labelTextColor,
@@ -16,7 +16,7 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
16
16
  import React from 'react';
17
17
 
18
18
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
19
- import { jsx, css } from '@emotion/react';
19
+ import { css, jsx } from '@emotion/react';
20
20
  import { injectIntl } from 'react-intl-next';
21
21
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE } from '@atlaskit/editor-common/analytics';
22
22
  import { DynamicStrokeIconDecoration, SteppedRainbowIconDecoration } from '@atlaskit/editor-common/icons';
@@ -29,6 +29,7 @@ import { akEditorMenuZIndex } from '@atlaskit/editor-shared-styles';
29
29
  import TextStyleIcon from '@atlaskit/icon/core/text-style';
30
30
  import ChevronDownIcon from '@atlaskit/icon/utility/migration/chevron-down';
31
31
  import { fg } from '@atlaskit/platform-feature-flags';
32
+ import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
32
33
  import { changeColor as changeColorWithAnalytics } from '../../pm-plugins/commands/change-color';
33
34
  import { getInputMethod } from '../../pm-plugins/utils/inputType';
34
35
  import { ToolbarType } from '../../types';
@@ -196,7 +197,7 @@ export var ToolbarTextColor = /*#__PURE__*/function (_React$Component) {
196
197
  },
197
198
  trigger: jsx(ToolbarButton, {
198
199
  buttonId: TOOLBAR_BUTTON.TEXT_COLOR,
199
- spacing: isReducedSpacing ? reducedSpacing : 'default',
200
+ spacing: !isReducedSpacing || editorExperiment('platform_editor_controls', 'variant1') ? 'default' : reducedSpacing,
200
201
  disabled: disabled || pluginState.disabled,
201
202
  selected: isOpen,
202
203
  "aria-label": labelTextColor,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-text-color",
3
- "version": "2.0.0",
3
+ "version": "2.0.1",
4
4
  "description": "Text color plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -25,26 +25,28 @@
25
25
  ]
26
26
  }
27
27
  },
28
- "sideEffects": false,
28
+ "sideEffects": [
29
+ "*.compiled.css"
30
+ ],
29
31
  "atlaskit:src": "src/index.ts",
30
32
  "af:exports": {
31
33
  ".": "./src/index.ts"
32
34
  },
33
35
  "dependencies": {
34
36
  "@atlaskit/adf-schema": "^47.2.1",
35
- "@atlaskit/editor-common": "^100.0.0",
37
+ "@atlaskit/editor-common": "^100.4.0",
36
38
  "@atlaskit/editor-palette": "2.0.0",
37
39
  "@atlaskit/editor-plugin-analytics": "^2.0.0",
38
40
  "@atlaskit/editor-plugin-primary-toolbar": "^3.0.0",
39
41
  "@atlaskit/editor-plugin-selection-toolbar": "^2.0.0",
40
42
  "@atlaskit/editor-prosemirror": "7.0.0",
41
- "@atlaskit/editor-shared-styles": "^3.3.0",
43
+ "@atlaskit/editor-shared-styles": "^3.4.0",
42
44
  "@atlaskit/editor-tables": "^2.9.0",
43
- "@atlaskit/icon": "^24.0.0",
45
+ "@atlaskit/icon": "^24.1.0",
44
46
  "@atlaskit/platform-feature-flags": "^1.1.0",
45
47
  "@atlaskit/theme": "^17.0.0",
46
- "@atlaskit/tmp-editor-statsig": "^3.0.0",
47
- "@atlaskit/tokens": "^4.0.0",
48
+ "@atlaskit/tmp-editor-statsig": "^3.3.0",
49
+ "@atlaskit/tokens": "^4.2.0",
48
50
  "@babel/runtime": "^7.0.0",
49
51
  "@emotion/react": "^11.7.1"
50
52
  },