@atlaskit/editor-plugin-text-color 1.18.2 → 1.20.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,29 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-text-color
|
|
2
2
|
|
|
3
|
+
## 1.20.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#116949](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/116949)
|
|
8
|
+
[`9154f7b89e3d2`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/9154f7b89e3d2) -
|
|
9
|
+
[ux] ED-26674 Hiding contextual toolbar menu items when the menu is docked to top
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- Updated dependencies
|
|
14
|
+
|
|
15
|
+
## 1.19.0
|
|
16
|
+
|
|
17
|
+
### Minor Changes
|
|
18
|
+
|
|
19
|
+
- [#116013](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/116013)
|
|
20
|
+
[`18e022766bfd3`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/18e022766bfd3) -
|
|
21
|
+
[ux] ED-26464 Hiding primary toolbar and docking contextual toolbar items to top
|
|
22
|
+
|
|
23
|
+
### Patch Changes
|
|
24
|
+
|
|
25
|
+
- Updated dependencies
|
|
26
|
+
|
|
3
27
|
## 1.18.2
|
|
4
28
|
|
|
5
29
|
### Patch Changes
|
|
@@ -30,6 +30,15 @@ var textColorPlugin = exports.textColorPlugin = function textColorPlugin(_ref) {
|
|
|
30
30
|
isToolbarReducedSpacing = _ref2.isToolbarReducedSpacing,
|
|
31
31
|
dispatchAnalyticsEvent = _ref2.dispatchAnalyticsEvent,
|
|
32
32
|
disabled = _ref2.disabled;
|
|
33
|
+
if ((0, _experiments.editorExperiment)('platform_editor_controls', 'variant1', {
|
|
34
|
+
exposure: true
|
|
35
|
+
})) {
|
|
36
|
+
return /*#__PURE__*/_react.default.createElement(_FloatingToolbarComponent.FloatingToolbarComponent, {
|
|
37
|
+
editorView: editorView,
|
|
38
|
+
dispatchAnalyticsEvent: dispatchAnalyticsEvent,
|
|
39
|
+
api: api
|
|
40
|
+
});
|
|
41
|
+
}
|
|
33
42
|
return /*#__PURE__*/_react.default.createElement(_PrimaryToolbarComponent.PrimaryToolbarComponent, {
|
|
34
43
|
isReducedSpacing: isToolbarReducedSpacing,
|
|
35
44
|
editorView: editorView,
|
|
@@ -76,6 +85,12 @@ var textColorPlugin = exports.textColorPlugin = function textColorPlugin(_ref) {
|
|
|
76
85
|
},
|
|
77
86
|
pluginsOptions: {
|
|
78
87
|
selectionToolbar: function selectionToolbar() {
|
|
88
|
+
var _api$selectionToolbar;
|
|
89
|
+
if ((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) === 'top' && (0, _experiments.editorExperiment)('platform_editor_controls', 'variant1', {
|
|
90
|
+
exposure: true
|
|
91
|
+
})) {
|
|
92
|
+
return undefined;
|
|
93
|
+
}
|
|
79
94
|
if ((0, _experiments.editorExperiment)('contextual_formatting_toolbar', true, {
|
|
80
95
|
exposure: true
|
|
81
96
|
}) || (0, _experiments.editorExperiment)('platform_editor_contextual_formatting_toolbar_v2', 'variant1', {
|
|
@@ -25,6 +25,15 @@ export const textColorPlugin = ({
|
|
|
25
25
|
dispatchAnalyticsEvent,
|
|
26
26
|
disabled
|
|
27
27
|
}) => {
|
|
28
|
+
if (editorExperiment('platform_editor_controls', 'variant1', {
|
|
29
|
+
exposure: true
|
|
30
|
+
})) {
|
|
31
|
+
return /*#__PURE__*/React.createElement(FloatingToolbarComponent, {
|
|
32
|
+
editorView: editorView,
|
|
33
|
+
dispatchAnalyticsEvent: dispatchAnalyticsEvent,
|
|
34
|
+
api: api
|
|
35
|
+
});
|
|
36
|
+
}
|
|
28
37
|
return /*#__PURE__*/React.createElement(PrimaryToolbarComponent, {
|
|
29
38
|
isReducedSpacing: isToolbarReducedSpacing,
|
|
30
39
|
editorView: editorView,
|
|
@@ -70,6 +79,12 @@ export const textColorPlugin = ({
|
|
|
70
79
|
},
|
|
71
80
|
pluginsOptions: {
|
|
72
81
|
selectionToolbar: () => {
|
|
82
|
+
var _api$selectionToolbar, _api$selectionToolbar2, _api$selectionToolbar3;
|
|
83
|
+
if ((api === null || api === void 0 ? void 0 : (_api$selectionToolbar = api.selectionToolbar) === null || _api$selectionToolbar === void 0 ? void 0 : (_api$selectionToolbar2 = _api$selectionToolbar.sharedState) === null || _api$selectionToolbar2 === void 0 ? void 0 : (_api$selectionToolbar3 = _api$selectionToolbar2.currentState()) === null || _api$selectionToolbar3 === void 0 ? void 0 : _api$selectionToolbar3.toolbarDocking) === 'top' && editorExperiment('platform_editor_controls', 'variant1', {
|
|
84
|
+
exposure: true
|
|
85
|
+
})) {
|
|
86
|
+
return undefined;
|
|
87
|
+
}
|
|
73
88
|
if (editorExperiment('contextual_formatting_toolbar', true, {
|
|
74
89
|
exposure: true
|
|
75
90
|
}) || editorExperiment('platform_editor_contextual_formatting_toolbar_v2', 'variant1', {
|
|
@@ -23,6 +23,15 @@ export var textColorPlugin = function textColorPlugin(_ref) {
|
|
|
23
23
|
isToolbarReducedSpacing = _ref2.isToolbarReducedSpacing,
|
|
24
24
|
dispatchAnalyticsEvent = _ref2.dispatchAnalyticsEvent,
|
|
25
25
|
disabled = _ref2.disabled;
|
|
26
|
+
if (editorExperiment('platform_editor_controls', 'variant1', {
|
|
27
|
+
exposure: true
|
|
28
|
+
})) {
|
|
29
|
+
return /*#__PURE__*/React.createElement(FloatingToolbarComponent, {
|
|
30
|
+
editorView: editorView,
|
|
31
|
+
dispatchAnalyticsEvent: dispatchAnalyticsEvent,
|
|
32
|
+
api: api
|
|
33
|
+
});
|
|
34
|
+
}
|
|
26
35
|
return /*#__PURE__*/React.createElement(PrimaryToolbarComponent, {
|
|
27
36
|
isReducedSpacing: isToolbarReducedSpacing,
|
|
28
37
|
editorView: editorView,
|
|
@@ -69,6 +78,12 @@ export var textColorPlugin = function textColorPlugin(_ref) {
|
|
|
69
78
|
},
|
|
70
79
|
pluginsOptions: {
|
|
71
80
|
selectionToolbar: function selectionToolbar() {
|
|
81
|
+
var _api$selectionToolbar;
|
|
82
|
+
if ((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) === 'top' && editorExperiment('platform_editor_controls', 'variant1', {
|
|
83
|
+
exposure: true
|
|
84
|
+
})) {
|
|
85
|
+
return undefined;
|
|
86
|
+
}
|
|
72
87
|
if (editorExperiment('contextual_formatting_toolbar', true, {
|
|
73
88
|
exposure: true
|
|
74
89
|
}) || editorExperiment('platform_editor_contextual_formatting_toolbar_v2', 'variant1', {
|
|
@@ -1,10 +1,15 @@
|
|
|
1
1
|
import type { Command, NextEditorPlugin, OptionalPlugin } from '@atlaskit/editor-common/types';
|
|
2
2
|
import type { AnalyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
3
|
import type { PrimaryToolbarPlugin } from '@atlaskit/editor-plugin-primary-toolbar';
|
|
4
|
+
import type { SelectionToolbarPlugin } from '@atlaskit/editor-plugin-selection-toolbar';
|
|
4
5
|
import type { TextColorPluginConfig, TextColorPluginState } from './pm-plugins/main';
|
|
5
6
|
import type { TextColorInputMethod } from './types';
|
|
6
7
|
type Config = TextColorPluginConfig | boolean;
|
|
7
|
-
export type Dependencies = [
|
|
8
|
+
export type Dependencies = [
|
|
9
|
+
OptionalPlugin<AnalyticsPlugin>,
|
|
10
|
+
OptionalPlugin<PrimaryToolbarPlugin>,
|
|
11
|
+
OptionalPlugin<SelectionToolbarPlugin>
|
|
12
|
+
];
|
|
8
13
|
export type TextColorPlugin = NextEditorPlugin<'textColor', {
|
|
9
14
|
pluginConfiguration: Config | undefined;
|
|
10
15
|
dependencies: Dependencies;
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import type { Command, NextEditorPlugin, OptionalPlugin } from '@atlaskit/editor-common/types';
|
|
2
2
|
import type { AnalyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
3
3
|
import type { PrimaryToolbarPlugin } from '@atlaskit/editor-plugin-primary-toolbar';
|
|
4
|
+
import type { SelectionToolbarPlugin } from '@atlaskit/editor-plugin-selection-toolbar';
|
|
4
5
|
import type { TextColorPluginConfig, TextColorPluginState } from './pm-plugins/main';
|
|
5
6
|
import type { TextColorInputMethod } from './types';
|
|
6
7
|
type Config = TextColorPluginConfig | boolean;
|
|
7
8
|
export type Dependencies = [
|
|
8
9
|
OptionalPlugin<AnalyticsPlugin>,
|
|
9
|
-
OptionalPlugin<PrimaryToolbarPlugin
|
|
10
|
+
OptionalPlugin<PrimaryToolbarPlugin>,
|
|
11
|
+
OptionalPlugin<SelectionToolbarPlugin>
|
|
10
12
|
];
|
|
11
13
|
export type TextColorPlugin = NextEditorPlugin<'textColor', {
|
|
12
14
|
pluginConfiguration: Config | undefined;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-text-color",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.20.0",
|
|
4
4
|
"description": "Text color plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -32,17 +32,18 @@
|
|
|
32
32
|
},
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"@atlaskit/adf-schema": "^47.2.1",
|
|
35
|
-
"@atlaskit/editor-common": "^99.
|
|
35
|
+
"@atlaskit/editor-common": "^99.18.0",
|
|
36
36
|
"@atlaskit/editor-palette": "1.7.0",
|
|
37
37
|
"@atlaskit/editor-plugin-analytics": "^1.12.0",
|
|
38
|
-
"@atlaskit/editor-plugin-primary-toolbar": "^2.
|
|
38
|
+
"@atlaskit/editor-plugin-primary-toolbar": "^2.3.0",
|
|
39
|
+
"@atlaskit/editor-plugin-selection-toolbar": "^1.9.0",
|
|
39
40
|
"@atlaskit/editor-prosemirror": "7.0.0",
|
|
40
41
|
"@atlaskit/editor-shared-styles": "^3.3.0",
|
|
41
42
|
"@atlaskit/editor-tables": "^2.9.0",
|
|
42
|
-
"@atlaskit/icon": "^23.
|
|
43
|
+
"@atlaskit/icon": "^23.11.0",
|
|
43
44
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
44
45
|
"@atlaskit/theme": "^16.0.0",
|
|
45
|
-
"@atlaskit/tmp-editor-statsig": "^2.
|
|
46
|
+
"@atlaskit/tmp-editor-statsig": "^2.47.0",
|
|
46
47
|
"@atlaskit/tokens": "^3.3.0",
|
|
47
48
|
"@babel/runtime": "^7.0.0",
|
|
48
49
|
"@emotion/react": "^11.7.1"
|