@atlaskit/editor-plugin-synced-block 4.3.7 → 4.3.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 +8 -0
- package/dist/cjs/nodeviews/syncedBlock.js +2 -1
- package/dist/cjs/syncedBlockPlugin.js +2 -2
- package/dist/es2019/nodeviews/syncedBlock.js +4 -1
- package/dist/es2019/syncedBlockPlugin.js +2 -2
- package/dist/es2019/ui/OverflowMenuSection.js +3 -3
- package/dist/esm/nodeviews/syncedBlock.js +2 -1
- package/dist/esm/syncedBlockPlugin.js +2 -2
- package/dist/esm/ui/OverflowMenuSection.js +3 -3
- package/dist/types/ui/OverflowMenuSection.d.ts +1 -1
- package/dist/types-ts4.5/ui/OverflowMenuSection.d.ts +1 -1
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-synced-block
|
|
2
2
|
|
|
3
|
+
## 4.3.8
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`0cc1855e9071d`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/0cc1855e9071d) -
|
|
8
|
+
EDITOR-1921 add analytics for sync block provider failures
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
|
|
3
11
|
## 4.3.7
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
@@ -65,7 +65,8 @@ var SyncBlock = /*#__PURE__*/function (_ReactNodeView) {
|
|
|
65
65
|
return (0, _editorSyncedBlockProvider.useFetchSyncBlockTitle)(syncBlockStore, _this2.node);
|
|
66
66
|
},
|
|
67
67
|
useFetchSyncBlockData: function useFetchSyncBlockData() {
|
|
68
|
-
|
|
68
|
+
var _this2$api;
|
|
69
|
+
return (0, _editorSyncedBlockProvider.useFetchSyncBlockData)(syncBlockStore, resourceId, localId, (_this2$api = _this2.api) === null || _this2$api === void 0 || (_this2$api = _this2$api.analytics) === null || _this2$api === void 0 || (_this2$api = _this2$api.actions) === null || _this2$api === void 0 ? void 0 : _this2$api.fireAnalyticsEvent);
|
|
69
70
|
}
|
|
70
71
|
});
|
|
71
72
|
}
|
|
@@ -21,10 +21,10 @@ var _floatingToolbar = require("./ui/floating-toolbar");
|
|
|
21
21
|
var _SyncBlockRefresher = require("./ui/SyncBlockRefresher");
|
|
22
22
|
var _toolbarComponents = require("./ui/toolbar-components");
|
|
23
23
|
var syncedBlockPlugin = exports.syncedBlockPlugin = function syncedBlockPlugin(_ref) {
|
|
24
|
-
var _api$blockMenu, _api$toolbar;
|
|
24
|
+
var _api$analytics, _api$blockMenu, _api$toolbar;
|
|
25
25
|
var config = _ref.config,
|
|
26
26
|
api = _ref.api;
|
|
27
|
-
var syncBlockStore = new _editorSyncedBlockProvider.SyncBlockStoreManager(config === null || config === void 0 ? void 0 : config.syncBlockDataProvider);
|
|
27
|
+
var syncBlockStore = new _editorSyncedBlockProvider.SyncBlockStoreManager(config === null || config === void 0 ? void 0 : config.syncBlockDataProvider, api === null || api === void 0 || (_api$analytics = api.analytics) === null || _api$analytics === void 0 || (_api$analytics = _api$analytics.actions) === null || _api$analytics === void 0 ? void 0 : _api$analytics.fireAnalyticsEvent);
|
|
28
28
|
api === null || api === void 0 || (_api$blockMenu = api.blockMenu) === null || _api$blockMenu === void 0 || _api$blockMenu.actions.registerBlockMenuComponents((0, _blockMenuComponents.getBlockMenuComponents)(api));
|
|
29
29
|
api === null || api === void 0 || (_api$toolbar = api.toolbar) === null || _api$toolbar === void 0 || _api$toolbar.actions.registerComponents((0, _toolbarComponents.getToolbarComponents)(api));
|
|
30
30
|
return {
|
|
@@ -36,7 +36,10 @@ class SyncBlock extends ReactNodeView {
|
|
|
36
36
|
localId: this.node.attrs.localId,
|
|
37
37
|
syncedBlockRenderer: (_this$options2 = this.options) === null || _this$options2 === void 0 ? void 0 : _this$options2.syncedBlockRenderer,
|
|
38
38
|
useFetchSyncBlockTitle: () => useFetchSyncBlockTitle(syncBlockStore, this.node),
|
|
39
|
-
useFetchSyncBlockData: () =>
|
|
39
|
+
useFetchSyncBlockData: () => {
|
|
40
|
+
var _this$api2, _this$api2$analytics, _this$api2$analytics$;
|
|
41
|
+
return useFetchSyncBlockData(syncBlockStore, resourceId, localId, (_this$api2 = this.api) === null || _this$api2 === void 0 ? void 0 : (_this$api2$analytics = _this$api2.analytics) === null || _this$api2$analytics === void 0 ? void 0 : (_this$api2$analytics$ = _this$api2$analytics.actions) === null || _this$api2$analytics$ === void 0 ? void 0 : _this$api2$analytics$.fireAnalyticsEvent);
|
|
42
|
+
}
|
|
40
43
|
});
|
|
41
44
|
}
|
|
42
45
|
destroy() {
|
|
@@ -17,8 +17,8 @@ export const syncedBlockPlugin = ({
|
|
|
17
17
|
config,
|
|
18
18
|
api
|
|
19
19
|
}) => {
|
|
20
|
-
var _api$blockMenu, _api$toolbar;
|
|
21
|
-
const syncBlockStore = new SyncBlockStoreManager(config === null || config === void 0 ? void 0 : config.syncBlockDataProvider);
|
|
20
|
+
var _api$analytics, _api$analytics$action, _api$blockMenu, _api$toolbar;
|
|
21
|
+
const syncBlockStore = new SyncBlockStoreManager(config === null || config === void 0 ? void 0 : config.syncBlockDataProvider, api === null || api === void 0 ? void 0 : (_api$analytics = api.analytics) === null || _api$analytics === void 0 ? void 0 : (_api$analytics$action = _api$analytics.actions) === null || _api$analytics$action === void 0 ? void 0 : _api$analytics$action.fireAnalyticsEvent);
|
|
22
22
|
api === null || api === void 0 ? void 0 : (_api$blockMenu = api.blockMenu) === null || _api$blockMenu === void 0 ? void 0 : _api$blockMenu.actions.registerBlockMenuComponents(getBlockMenuComponents(api));
|
|
23
23
|
api === null || api === void 0 ? void 0 : (_api$toolbar = api.toolbar) === null || _api$toolbar === void 0 ? void 0 : _api$toolbar.actions.registerComponents(getToolbarComponents(api));
|
|
24
24
|
return {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { useEditorToolbar } from
|
|
3
|
-
import { ToolbarDropdownItemSection } from
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { useEditorToolbar } from '@atlaskit/editor-common/toolbar';
|
|
3
|
+
import { ToolbarDropdownItemSection } from '@atlaskit/editor-toolbar';
|
|
4
4
|
export const OverflowMenuSection = ({
|
|
5
5
|
children
|
|
6
6
|
}) => {
|
|
@@ -58,7 +58,8 @@ var SyncBlock = /*#__PURE__*/function (_ReactNodeView) {
|
|
|
58
58
|
return _useFetchSyncBlockTitle(syncBlockStore, _this2.node);
|
|
59
59
|
},
|
|
60
60
|
useFetchSyncBlockData: function useFetchSyncBlockData() {
|
|
61
|
-
|
|
61
|
+
var _this2$api;
|
|
62
|
+
return _useFetchSyncBlockData(syncBlockStore, resourceId, localId, (_this2$api = _this2.api) === null || _this2$api === void 0 || (_this2$api = _this2$api.analytics) === null || _this2$api === void 0 || (_this2$api = _this2$api.actions) === null || _this2$api === void 0 ? void 0 : _this2$api.fireAnalyticsEvent);
|
|
62
63
|
}
|
|
63
64
|
});
|
|
64
65
|
}
|
|
@@ -14,10 +14,10 @@ import { getToolbarConfig } from './ui/floating-toolbar';
|
|
|
14
14
|
import { SyncBlockRefresher } from './ui/SyncBlockRefresher';
|
|
15
15
|
import { getToolbarComponents } from './ui/toolbar-components';
|
|
16
16
|
export var syncedBlockPlugin = function syncedBlockPlugin(_ref) {
|
|
17
|
-
var _api$blockMenu, _api$toolbar;
|
|
17
|
+
var _api$analytics, _api$blockMenu, _api$toolbar;
|
|
18
18
|
var config = _ref.config,
|
|
19
19
|
api = _ref.api;
|
|
20
|
-
var syncBlockStore = new SyncBlockStoreManager(config === null || config === void 0 ? void 0 : config.syncBlockDataProvider);
|
|
20
|
+
var syncBlockStore = new SyncBlockStoreManager(config === null || config === void 0 ? void 0 : config.syncBlockDataProvider, api === null || api === void 0 || (_api$analytics = api.analytics) === null || _api$analytics === void 0 || (_api$analytics = _api$analytics.actions) === null || _api$analytics === void 0 ? void 0 : _api$analytics.fireAnalyticsEvent);
|
|
21
21
|
api === null || api === void 0 || (_api$blockMenu = api.blockMenu) === null || _api$blockMenu === void 0 || _api$blockMenu.actions.registerBlockMenuComponents(getBlockMenuComponents(api));
|
|
22
22
|
api === null || api === void 0 || (_api$toolbar = api.toolbar) === null || _api$toolbar === void 0 || _api$toolbar.actions.registerComponents(getToolbarComponents(api));
|
|
23
23
|
return {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { useEditorToolbar } from
|
|
3
|
-
import { ToolbarDropdownItemSection } from
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { useEditorToolbar } from '@atlaskit/editor-common/toolbar';
|
|
3
|
+
import { ToolbarDropdownItemSection } from '@atlaskit/editor-toolbar';
|
|
4
4
|
export var OverflowMenuSection = function OverflowMenuSection(_ref) {
|
|
5
5
|
var children = _ref.children;
|
|
6
6
|
var _useEditorToolbar = useEditorToolbar(),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-synced-block",
|
|
3
|
-
"version": "4.3.
|
|
3
|
+
"version": "4.3.8",
|
|
4
4
|
"description": "SyncedBlock plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"@atlaskit/editor-plugin-selection": "^6.1.0",
|
|
40
40
|
"@atlaskit/editor-prosemirror": "7.0.0",
|
|
41
41
|
"@atlaskit/editor-shared-styles": "^3.10.0",
|
|
42
|
-
"@atlaskit/editor-synced-block-provider": "^2.
|
|
42
|
+
"@atlaskit/editor-synced-block-provider": "^2.11.0",
|
|
43
43
|
"@atlaskit/editor-tables": "^2.9.0",
|
|
44
44
|
"@atlaskit/editor-toolbar": "^0.17.0",
|
|
45
45
|
"@atlaskit/flag": "^17.5.0",
|