@atlaskit/editor-plugin-synced-block 8.4.10 → 8.4.11
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 +9 -0
- package/dist/cjs/ui/CreateSyncedBlockButton.js +1 -2
- package/dist/cjs/ui/CreateSyncedBlockDropdownItem.js +2 -4
- package/dist/cjs/ui/floating-toolbar.js +1 -5
- package/dist/cjs/ui/quick-insert.js +1 -1
- package/dist/es2019/ui/CreateSyncedBlockButton.js +1 -2
- package/dist/es2019/ui/CreateSyncedBlockDropdownItem.js +2 -4
- package/dist/es2019/ui/floating-toolbar.js +1 -5
- package/dist/es2019/ui/quick-insert.js +1 -1
- package/dist/esm/ui/CreateSyncedBlockButton.js +1 -2
- package/dist/esm/ui/CreateSyncedBlockDropdownItem.js +2 -4
- package/dist/esm/ui/floating-toolbar.js +1 -5
- package/dist/esm/ui/quick-insert.js +1 -1
- package/package.json +1 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-synced-block
|
|
2
2
|
|
|
3
|
+
## 8.4.11
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`3b124b51740be`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/3b124b51740be) -
|
|
8
|
+
Remove fully rolled out feature gates platform_synced_block_patch_12 and
|
|
9
|
+
platform_synced_blocks_dogfooding
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
3
12
|
## 8.4.10
|
|
4
13
|
|
|
5
14
|
### Patch Changes
|
|
@@ -13,7 +13,6 @@ var _messages = require("@atlaskit/editor-common/messages");
|
|
|
13
13
|
var _editorPluginConnectivity = require("@atlaskit/editor-plugin-connectivity");
|
|
14
14
|
var _editorToolbar = require("@atlaskit/editor-toolbar");
|
|
15
15
|
var _blockSynced = _interopRequireDefault(require("@atlaskit/icon-lab/core/block-synced"));
|
|
16
|
-
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
17
16
|
var _utils = require("../pm-plugins/utils/utils");
|
|
18
17
|
var _types = require("../types");
|
|
19
18
|
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); }
|
|
@@ -45,7 +44,7 @@ var CreateSyncedBlockButton = exports.CreateSyncedBlockButton = function CreateS
|
|
|
45
44
|
});
|
|
46
45
|
api === null || api === void 0 || (_api$core2 = api.core) === null || _api$core2 === void 0 || _api$core2.actions.focus();
|
|
47
46
|
}, [api]);
|
|
48
|
-
var message = intl.formatMessage(
|
|
47
|
+
var message = intl.formatMessage(_messages.syncBlockMessages.syncBlockLabel);
|
|
49
48
|
return /*#__PURE__*/_react.default.createElement(_editorToolbar.ToolbarTooltip, {
|
|
50
49
|
content: message
|
|
51
50
|
}, /*#__PURE__*/_react.default.createElement(_editorToolbar.ToolbarButton, {
|
|
@@ -65,8 +65,7 @@ var CreateSyncedBlockDropdownItem = function CreateSyncedBlockDropdownItem(_ref2
|
|
|
65
65
|
onClick: onClick,
|
|
66
66
|
isDisabled: isOffline,
|
|
67
67
|
testId: _types.SYNCED_BLOCK_BUTTON_TEST_ID.blockMenuCreate,
|
|
68
|
-
|
|
69
|
-
elemAfterText: (0, _platformFeatureFlags.fg)('platform_synced_block_patch_12') ? lozenge : undefined
|
|
68
|
+
elemAfterText: lozenge
|
|
70
69
|
}, formatMessage(_messages.blockMenuMessages.syncBlock));
|
|
71
70
|
};
|
|
72
71
|
var CopySyncedBlockDropdownItem = function CopySyncedBlockDropdownItem(_ref3) {
|
|
@@ -97,8 +96,7 @@ var CopySyncedBlockDropdownItem = function CopySyncedBlockDropdownItem(_ref3) {
|
|
|
97
96
|
}),
|
|
98
97
|
onClick: onClick,
|
|
99
98
|
isDisabled: (0, _editorPluginConnectivity.isOfflineMode)(mode),
|
|
100
|
-
|
|
101
|
-
elemAfterText: (0, _platformFeatureFlags.fg)('platform_synced_block_patch_12') ? lozenge : undefined
|
|
99
|
+
elemAfterText: lozenge
|
|
102
100
|
}, formatMessage(_messages.blockMenuMessages.copySyncedBlock));
|
|
103
101
|
};
|
|
104
102
|
var CreateOrCopySyncedBlockDropdownItem = exports.CreateOrCopySyncedBlockDropdownItem = function CreateOrCopySyncedBlockDropdownItem(_ref4) {
|
|
@@ -18,7 +18,6 @@ var _copy = _interopRequireDefault(require("@atlaskit/icon/core/copy"));
|
|
|
18
18
|
var _delete = _interopRequireDefault(require("@atlaskit/icon/core/delete"));
|
|
19
19
|
var _edit = _interopRequireDefault(require("@atlaskit/icon/core/edit"));
|
|
20
20
|
var _linkBroken = _interopRequireDefault(require("@atlaskit/icon/core/link-broken"));
|
|
21
|
-
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
22
21
|
var _editorCommands = require("../editor-commands");
|
|
23
22
|
var _utils2 = require("../pm-plugins/utils/utils");
|
|
24
23
|
var _types = require("../types");
|
|
@@ -133,10 +132,7 @@ var getToolbarConfig = exports.getToolbarConfig = function getToolbarConfig(stat
|
|
|
133
132
|
|
|
134
133
|
// testId is required to show focus on trigger button on ESC key press
|
|
135
134
|
// see hideOnEsc in platform/packages/editor/editor-plugin-floating-toolbar/src/ui/Dropdown.tsx
|
|
136
|
-
var testId =
|
|
137
|
-
if ((0, _platformFeatureFlags.fg)('platform_synced_block_patch_12')) {
|
|
138
|
-
testId = isBodiedSyncBlock ? _types.SYNCED_BLOCK_BUTTON_TEST_ID.syncedBlockToolbarSourceOverflowTrigger : _types.SYNCED_BLOCK_BUTTON_TEST_ID.syncedBlockToolbarReferenceOverflowTrigger;
|
|
139
|
-
}
|
|
135
|
+
var testId = isBodiedSyncBlock ? _types.SYNCED_BLOCK_BUTTON_TEST_ID.syncedBlockToolbarSourceOverflowTrigger : _types.SYNCED_BLOCK_BUTTON_TEST_ID.syncedBlockToolbarReferenceOverflowTrigger;
|
|
140
136
|
var overflowMenuConfig = [{
|
|
141
137
|
type: 'overflow-dropdown',
|
|
142
138
|
testId: testId,
|
|
@@ -24,7 +24,7 @@ var getQuickInsertConfig = exports.getQuickInsertConfig = function getQuickInser
|
|
|
24
24
|
if (!(config !== null && config !== void 0 && config.enableSourceCreation)) {
|
|
25
25
|
return [];
|
|
26
26
|
}
|
|
27
|
-
var syncBlockTitle =
|
|
27
|
+
var syncBlockTitle = _messages.blockTypeMessages.syncBlock;
|
|
28
28
|
return [{
|
|
29
29
|
id: 'syncBlock',
|
|
30
30
|
title: formatMessage(syncBlockTitle),
|
|
@@ -5,7 +5,6 @@ import { syncBlockMessages } from '@atlaskit/editor-common/messages';
|
|
|
5
5
|
import { isOfflineMode } from '@atlaskit/editor-plugin-connectivity';
|
|
6
6
|
import { ToolbarButton, ToolbarTooltip } from '@atlaskit/editor-toolbar';
|
|
7
7
|
import BlockSyncedIcon from '@atlaskit/icon-lab/core/block-synced';
|
|
8
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
9
8
|
import { canBeConvertedToSyncBlock } from '../pm-plugins/utils/utils';
|
|
10
9
|
import { SYNCED_BLOCK_BUTTON_TEST_ID } from '../types';
|
|
11
10
|
export const CreateSyncedBlockButton = ({
|
|
@@ -37,7 +36,7 @@ export const CreateSyncedBlockButton = ({
|
|
|
37
36
|
}));
|
|
38
37
|
api === null || api === void 0 ? void 0 : (_api$core2 = api.core) === null || _api$core2 === void 0 ? void 0 : _api$core2.actions.focus();
|
|
39
38
|
}, [api]);
|
|
40
|
-
const message = intl.formatMessage(
|
|
39
|
+
const message = intl.formatMessage(syncBlockMessages.syncBlockLabel);
|
|
41
40
|
return /*#__PURE__*/React.createElement(ToolbarTooltip, {
|
|
42
41
|
content: message
|
|
43
42
|
}, /*#__PURE__*/React.createElement(ToolbarButton, {
|
|
@@ -56,8 +56,7 @@ const CreateSyncedBlockDropdownItem = ({
|
|
|
56
56
|
onClick: onClick,
|
|
57
57
|
isDisabled: isOffline,
|
|
58
58
|
testId: SYNCED_BLOCK_BUTTON_TEST_ID.blockMenuCreate,
|
|
59
|
-
|
|
60
|
-
elemAfterText: fg('platform_synced_block_patch_12') ? lozenge : undefined
|
|
59
|
+
elemAfterText: lozenge
|
|
61
60
|
}, formatMessage(blockMenuMessages.syncBlock));
|
|
62
61
|
};
|
|
63
62
|
const CopySyncedBlockDropdownItem = ({
|
|
@@ -91,8 +90,7 @@ const CopySyncedBlockDropdownItem = ({
|
|
|
91
90
|
}),
|
|
92
91
|
onClick: onClick,
|
|
93
92
|
isDisabled: isOfflineMode(mode),
|
|
94
|
-
|
|
95
|
-
elemAfterText: fg('platform_synced_block_patch_12') ? lozenge : undefined
|
|
93
|
+
elemAfterText: lozenge
|
|
96
94
|
}, formatMessage(blockMenuMessages.copySyncedBlock));
|
|
97
95
|
};
|
|
98
96
|
export const CreateOrCopySyncedBlockDropdownItem = ({
|
|
@@ -9,7 +9,6 @@ import CopyIcon from '@atlaskit/icon/core/copy';
|
|
|
9
9
|
import DeleteIcon from '@atlaskit/icon/core/delete';
|
|
10
10
|
import EditIcon from '@atlaskit/icon/core/edit';
|
|
11
11
|
import LinkBrokenIcon from '@atlaskit/icon/core/link-broken';
|
|
12
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
13
12
|
import { copySyncedBlockReferenceToClipboard, editSyncedBlockSource, removeSyncedBlock, unsync } from '../editor-commands';
|
|
14
13
|
import { findSyncBlockOrBodiedSyncBlock, isBodiedSyncBlockNode } from '../pm-plugins/utils/utils';
|
|
15
14
|
import { SYNCED_BLOCK_BUTTON_TEST_ID } from '../types';
|
|
@@ -129,10 +128,7 @@ export const getToolbarConfig = (state, intl, api, syncBlockStore) => {
|
|
|
129
128
|
|
|
130
129
|
// testId is required to show focus on trigger button on ESC key press
|
|
131
130
|
// see hideOnEsc in platform/packages/editor/editor-plugin-floating-toolbar/src/ui/Dropdown.tsx
|
|
132
|
-
|
|
133
|
-
if (fg('platform_synced_block_patch_12')) {
|
|
134
|
-
testId = isBodiedSyncBlock ? SYNCED_BLOCK_BUTTON_TEST_ID.syncedBlockToolbarSourceOverflowTrigger : SYNCED_BLOCK_BUTTON_TEST_ID.syncedBlockToolbarReferenceOverflowTrigger;
|
|
135
|
-
}
|
|
131
|
+
const testId = isBodiedSyncBlock ? SYNCED_BLOCK_BUTTON_TEST_ID.syncedBlockToolbarSourceOverflowTrigger : SYNCED_BLOCK_BUTTON_TEST_ID.syncedBlockToolbarReferenceOverflowTrigger;
|
|
136
132
|
const overflowMenuConfig = [{
|
|
137
133
|
type: 'overflow-dropdown',
|
|
138
134
|
testId,
|
|
@@ -16,7 +16,7 @@ export const getQuickInsertConfig = (config, api, syncBlockStore) => {
|
|
|
16
16
|
if (!(config !== null && config !== void 0 && config.enableSourceCreation)) {
|
|
17
17
|
return [];
|
|
18
18
|
}
|
|
19
|
-
const syncBlockTitle =
|
|
19
|
+
const syncBlockTitle = blockTypeMessages.syncBlock;
|
|
20
20
|
return [{
|
|
21
21
|
id: 'syncBlock',
|
|
22
22
|
title: formatMessage(syncBlockTitle),
|
|
@@ -5,7 +5,6 @@ import { syncBlockMessages } from '@atlaskit/editor-common/messages';
|
|
|
5
5
|
import { isOfflineMode } from '@atlaskit/editor-plugin-connectivity';
|
|
6
6
|
import { ToolbarButton, ToolbarTooltip } from '@atlaskit/editor-toolbar';
|
|
7
7
|
import BlockSyncedIcon from '@atlaskit/icon-lab/core/block-synced';
|
|
8
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
9
8
|
import { canBeConvertedToSyncBlock } from '../pm-plugins/utils/utils';
|
|
10
9
|
import { SYNCED_BLOCK_BUTTON_TEST_ID } from '../types';
|
|
11
10
|
export var CreateSyncedBlockButton = function CreateSyncedBlockButton(_ref) {
|
|
@@ -36,7 +35,7 @@ export var CreateSyncedBlockButton = function CreateSyncedBlockButton(_ref) {
|
|
|
36
35
|
});
|
|
37
36
|
api === null || api === void 0 || (_api$core2 = api.core) === null || _api$core2 === void 0 || _api$core2.actions.focus();
|
|
38
37
|
}, [api]);
|
|
39
|
-
var message = intl.formatMessage(
|
|
38
|
+
var message = intl.formatMessage(syncBlockMessages.syncBlockLabel);
|
|
40
39
|
return /*#__PURE__*/React.createElement(ToolbarTooltip, {
|
|
41
40
|
content: message
|
|
42
41
|
}, /*#__PURE__*/React.createElement(ToolbarButton, {
|
|
@@ -56,8 +56,7 @@ var CreateSyncedBlockDropdownItem = function CreateSyncedBlockDropdownItem(_ref2
|
|
|
56
56
|
onClick: onClick,
|
|
57
57
|
isDisabled: isOffline,
|
|
58
58
|
testId: SYNCED_BLOCK_BUTTON_TEST_ID.blockMenuCreate,
|
|
59
|
-
|
|
60
|
-
elemAfterText: fg('platform_synced_block_patch_12') ? lozenge : undefined
|
|
59
|
+
elemAfterText: lozenge
|
|
61
60
|
}, formatMessage(blockMenuMessages.syncBlock));
|
|
62
61
|
};
|
|
63
62
|
var CopySyncedBlockDropdownItem = function CopySyncedBlockDropdownItem(_ref3) {
|
|
@@ -88,8 +87,7 @@ var CopySyncedBlockDropdownItem = function CopySyncedBlockDropdownItem(_ref3) {
|
|
|
88
87
|
}),
|
|
89
88
|
onClick: onClick,
|
|
90
89
|
isDisabled: isOfflineMode(mode),
|
|
91
|
-
|
|
92
|
-
elemAfterText: fg('platform_synced_block_patch_12') ? lozenge : undefined
|
|
90
|
+
elemAfterText: lozenge
|
|
93
91
|
}, formatMessage(blockMenuMessages.copySyncedBlock));
|
|
94
92
|
};
|
|
95
93
|
export var CreateOrCopySyncedBlockDropdownItem = function CreateOrCopySyncedBlockDropdownItem(_ref4) {
|
|
@@ -12,7 +12,6 @@ import CopyIcon from '@atlaskit/icon/core/copy';
|
|
|
12
12
|
import DeleteIcon from '@atlaskit/icon/core/delete';
|
|
13
13
|
import EditIcon from '@atlaskit/icon/core/edit';
|
|
14
14
|
import LinkBrokenIcon from '@atlaskit/icon/core/link-broken';
|
|
15
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
16
15
|
import { copySyncedBlockReferenceToClipboard, editSyncedBlockSource, removeSyncedBlock, unsync } from '../editor-commands';
|
|
17
16
|
import { findSyncBlockOrBodiedSyncBlock, isBodiedSyncBlockNode } from '../pm-plugins/utils/utils';
|
|
18
17
|
import { SYNCED_BLOCK_BUTTON_TEST_ID } from '../types';
|
|
@@ -124,10 +123,7 @@ export var getToolbarConfig = function getToolbarConfig(state, intl, api, syncBl
|
|
|
124
123
|
|
|
125
124
|
// testId is required to show focus on trigger button on ESC key press
|
|
126
125
|
// see hideOnEsc in platform/packages/editor/editor-plugin-floating-toolbar/src/ui/Dropdown.tsx
|
|
127
|
-
var testId =
|
|
128
|
-
if (fg('platform_synced_block_patch_12')) {
|
|
129
|
-
testId = isBodiedSyncBlock ? SYNCED_BLOCK_BUTTON_TEST_ID.syncedBlockToolbarSourceOverflowTrigger : SYNCED_BLOCK_BUTTON_TEST_ID.syncedBlockToolbarReferenceOverflowTrigger;
|
|
130
|
-
}
|
|
126
|
+
var testId = isBodiedSyncBlock ? SYNCED_BLOCK_BUTTON_TEST_ID.syncedBlockToolbarSourceOverflowTrigger : SYNCED_BLOCK_BUTTON_TEST_ID.syncedBlockToolbarReferenceOverflowTrigger;
|
|
131
127
|
var overflowMenuConfig = [{
|
|
132
128
|
type: 'overflow-dropdown',
|
|
133
129
|
testId: testId,
|
|
@@ -15,7 +15,7 @@ export var getQuickInsertConfig = function getQuickInsertConfig(config, api, syn
|
|
|
15
15
|
if (!(config !== null && config !== void 0 && config.enableSourceCreation)) {
|
|
16
16
|
return [];
|
|
17
17
|
}
|
|
18
|
-
var syncBlockTitle =
|
|
18
|
+
var syncBlockTitle = blockTypeMessages.syncBlock;
|
|
19
19
|
return [{
|
|
20
20
|
id: 'syncBlock',
|
|
21
21
|
title: formatMessage(syncBlockTitle),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-synced-block",
|
|
3
|
-
"version": "8.4.
|
|
3
|
+
"version": "8.4.11",
|
|
4
4
|
"description": "SyncedBlock plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -113,9 +113,6 @@
|
|
|
113
113
|
"confluence_fronend_labels_categorization_migration": {
|
|
114
114
|
"type": "boolean"
|
|
115
115
|
},
|
|
116
|
-
"platform_synced_block_patch_12": {
|
|
117
|
-
"type": "boolean"
|
|
118
|
-
},
|
|
119
116
|
"platform_synced_block_patch_13": {
|
|
120
117
|
"type": "boolean"
|
|
121
118
|
}
|