@atlaskit/editor-plugin-text-color 16.0.7 → 16.0.8

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,11 @@
1
1
  # @atlaskit/editor-plugin-text-color
2
2
 
3
+ ## 16.0.8
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
3
9
  ## 16.0.7
4
10
 
5
11
  ### Patch Changes
@@ -8,7 +8,7 @@ exports.textColorPlugin = void 0;
8
8
  var _react = _interopRequireDefault(require("react"));
9
9
  var _adfSchema = require("@atlaskit/adf-schema");
10
10
  var _fg = require("@atlaskit/platform-feature-flags/fg");
11
- var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
11
+ var _editorExperiment = require("@atlaskit/tmp-editor-statsig/editor-experiment");
12
12
  var _changeColor2 = require("./editor-commands/change-color");
13
13
  var _palette = require("./editor-commands/palette");
14
14
  var _changeColor3 = require("./pm-plugins/commands/change-color");
@@ -118,7 +118,7 @@ var textColorPlugin = exports.textColorPlugin = function textColorPlugin(_ref) {
118
118
  selectionToolbar: function selectionToolbar() {
119
119
  var _api$userPreferences, _api$selectionToolbar;
120
120
  var toolbarDocking = (0, _fg.fg)('platform_editor_use_preferences_plugin') ? api === null || api === void 0 || (_api$userPreferences = api.userPreferences) === null || _api$userPreferences === void 0 || (_api$userPreferences = _api$userPreferences.sharedState) === null || _api$userPreferences === void 0 || (_api$userPreferences = _api$userPreferences.currentState()) === null || _api$userPreferences === void 0 ? void 0 : _api$userPreferences.preferences.toolbarDockingPosition : api === null || api === void 0 || (_api$selectionToolbar = api.selectionToolbar) === null || _api$selectionToolbar === void 0 || (_api$selectionToolbar = _api$selectionToolbar.sharedState) === null || _api$selectionToolbar === void 0 || (_api$selectionToolbar = _api$selectionToolbar.currentState()) === null || _api$selectionToolbar === void 0 ? void 0 : _api$selectionToolbar.toolbarDocking;
121
- if (toolbarDocking === 'none' && (0, _experiments.editorExperiment)('platform_editor_controls', 'variant1', {
121
+ if (toolbarDocking === 'none' && (0, _editorExperiment.editorExperiment)('platform_editor_controls', 'variant1', {
122
122
  exposure: true
123
123
  })) {
124
124
  var toolbarCustom = {
@@ -15,7 +15,7 @@ var _useSharedPluginStateSelector = require("@atlaskit/editor-common/use-shared-
15
15
  var _editorPalette = require("@atlaskit/editor-palette");
16
16
  var _editorToolbar = require("@atlaskit/editor-toolbar");
17
17
  var _isExperimentEnabled = require("@atlaskit/platform-feature-experiments/is-experiment-enabled");
18
- var _conditionalHooksFactory = require("@atlaskit/platform-feature-flags-react/conditional-hooks-factory");
18
+ var _conditionalHooksFactory = require("@atlaskit/platform-feature-flags-react/conditional-hooks-factory/conditional-hooks-factory");
19
19
  var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
20
20
  function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
21
21
  var getIconColor = function getIconColor(textColor, defaultColor, highlightColor) {
@@ -26,7 +26,7 @@ var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
26
26
  var _chevronDown = _interopRequireDefault(require("@atlaskit/icon/core/chevron-down"));
27
27
  var _textStyle = _interopRequireDefault(require("@atlaskit/icon/core/text-style"));
28
28
  var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
29
- var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
29
+ var _editorExperiment = require("@atlaskit/tmp-editor-statsig/editor-experiment");
30
30
  var _changeColor = require("../../pm-plugins/commands/change-color");
31
31
  var _inputType = require("../../pm-plugins/utils/inputType");
32
32
  var _types = require("../../types");
@@ -194,7 +194,7 @@ var ToolbarTextColor = exports.ToolbarTextColor = /*#__PURE__*/function (_React$
194
194
  },
195
195
  trigger: (0, _react2.jsx)(_uiMenu.ToolbarButton, {
196
196
  buttonId: _uiMenu.TOOLBAR_BUTTON.TEXT_COLOR,
197
- spacing: !isReducedSpacing || (0, _experiments.editorExperiment)('platform_editor_controls', 'variant1') ? 'default' : reducedSpacing,
197
+ spacing: !isReducedSpacing || (0, _editorExperiment.editorExperiment)('platform_editor_controls', 'variant1') ? 'default' : reducedSpacing,
198
198
  disabled: disabled || pluginState.disabled,
199
199
  selected: isOpen,
200
200
  "aria-label": labelTextColor,
@@ -279,6 +279,6 @@ var ToolbarTextColor = exports.ToolbarTextColor = /*#__PURE__*/function (_React$
279
279
  }
280
280
  }
281
281
  }]);
282
- }(_react.default.Component); // eslint-disable-next-line @typescript-eslint/ban-types
282
+ }(_react.default.Component); // eslint-disable-next-line @typescript-eslint/no-restricted-types
283
283
  var _default_1 = (0, _reactIntl.injectIntl)(ToolbarTextColor);
284
284
  var _default = exports.default = _default_1;
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import { textColor } from '@atlaskit/adf-schema';
3
3
  import { fg } from '@atlaskit/platform-feature-flags/fg';
4
- import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
4
+ import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
5
5
  import { changeColor as changeColorCommand } from './editor-commands/change-color';
6
6
  import { setPalette } from './editor-commands/palette';
7
7
  import { changeColor } from './pm-plugins/commands/change-color';
@@ -8,7 +8,7 @@ import { useSharedPluginStateSelector } from '@atlaskit/editor-common/use-shared
8
8
  import { hexToEditorTextPaletteColor, hexToEditorTextBackgroundPaletteColor } from '@atlaskit/editor-palette';
9
9
  import { TextColorIcon, ToolbarColorSwatch, ToolbarDropdownMenu, ToolbarDropdownMenuProvider, ToolbarTooltip, useToolbarUI } from '@atlaskit/editor-toolbar';
10
10
  import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
11
- import { conditionalHooksFactory } from '@atlaskit/platform-feature-flags-react/conditional-hooks-factory';
11
+ import { conditionalHooksFactory } from '@atlaskit/platform-feature-flags-react/conditional-hooks-factory/conditional-hooks-factory';
12
12
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
13
13
  const getIconColor = (textColor, defaultColor, highlightColor) => {
14
14
  if (expValEquals('platform_editor_lovability_text_bg_color', 'isEnabled', true)) {
@@ -19,7 +19,7 @@ import { akEditorMenuZIndex } from '@atlaskit/editor-shared-styles';
19
19
  import ChevronDownIcon from '@atlaskit/icon/core/chevron-down';
20
20
  import TextStyleIcon from '@atlaskit/icon/core/text-style';
21
21
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
22
- import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
22
+ import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
23
23
  import { changeColor as changeColorWithAnalytics } from '../../pm-plugins/commands/change-color';
24
24
  import { getInputMethod } from '../../pm-plugins/utils/inputType';
25
25
  import { ToolbarType } from '../../types';
@@ -258,6 +258,6 @@ export class ToolbarTextColor extends React.Component {
258
258
  }
259
259
  }
260
260
 
261
- // eslint-disable-next-line @typescript-eslint/ban-types
261
+ // eslint-disable-next-line @typescript-eslint/no-restricted-types
262
262
  const _default_1 = injectIntl(ToolbarTextColor);
263
263
  export default _default_1;
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import { textColor } from '@atlaskit/adf-schema';
3
3
  import { fg } from '@atlaskit/platform-feature-flags/fg';
4
- import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
4
+ import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
5
5
  import { changeColor as changeColorCommand } from './editor-commands/change-color';
6
6
  import { setPalette as _setPalette } from './editor-commands/palette';
7
7
  import { changeColor as _changeColor } from './pm-plugins/commands/change-color';
@@ -8,7 +8,7 @@ import { useSharedPluginStateSelector } from '@atlaskit/editor-common/use-shared
8
8
  import { hexToEditorTextPaletteColor, hexToEditorTextBackgroundPaletteColor } from '@atlaskit/editor-palette';
9
9
  import { TextColorIcon, ToolbarColorSwatch, ToolbarDropdownMenu, ToolbarDropdownMenuProvider, ToolbarTooltip, useToolbarUI } from '@atlaskit/editor-toolbar';
10
10
  import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
11
- import { conditionalHooksFactory } from '@atlaskit/platform-feature-flags-react/conditional-hooks-factory';
11
+ import { conditionalHooksFactory } from '@atlaskit/platform-feature-flags-react/conditional-hooks-factory/conditional-hooks-factory';
12
12
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
13
13
  var getIconColor = function getIconColor(textColor, defaultColor, highlightColor) {
14
14
  if (expValEquals('platform_editor_lovability_text_bg_color', 'isEnabled', true)) {
@@ -29,7 +29,7 @@ import { akEditorMenuZIndex } from '@atlaskit/editor-shared-styles';
29
29
  import ChevronDownIcon from '@atlaskit/icon/core/chevron-down';
30
30
  import TextStyleIcon from '@atlaskit/icon/core/text-style';
31
31
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
32
- import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
32
+ import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
33
33
  import { changeColor as changeColorWithAnalytics } from '../../pm-plugins/commands/change-color';
34
34
  import { getInputMethod } from '../../pm-plugins/utils/inputType';
35
35
  import { ToolbarType } from '../../types';
@@ -277,6 +277,6 @@ export var ToolbarTextColor = /*#__PURE__*/function (_React$Component) {
277
277
  }]);
278
278
  }(React.Component);
279
279
 
280
- // eslint-disable-next-line @typescript-eslint/ban-types
280
+ // eslint-disable-next-line @typescript-eslint/no-restricted-types
281
281
  var _default_1 = injectIntl(ToolbarTextColor);
282
282
  export default _default_1;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-text-color",
3
- "version": "16.0.7",
3
+ "version": "16.0.8",
4
4
  "description": "Text color plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -42,7 +42,7 @@
42
42
  "@atlaskit/platform-feature-flags": "^2.1.0",
43
43
  "@atlaskit/platform-feature-flags-react": "^1.2.0",
44
44
  "@atlaskit/primitives": "^22.4.0",
45
- "@atlaskit/tmp-editor-statsig": "^167.0.0",
45
+ "@atlaskit/tmp-editor-statsig": "^168.0.0",
46
46
  "@atlaskit/tokens": "^16.9.0",
47
47
  "@babel/runtime": "^7.0.0",
48
48
  "@emotion/react": "^11.7.1"