@atlaskit/editor-plugin-card 4.5.7 → 4.5.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 +6 -0
- package/dist/cjs/pm-plugins/main.js +1 -8
- package/dist/cjs/ui/toolbar.js +3 -3
- package/dist/es2019/pm-plugins/main.js +0 -1
- package/dist/es2019/ui/toolbar.js +1 -1
- package/dist/esm/pm-plugins/main.js +0 -1
- package/dist/esm/ui/toolbar.js +1 -1
- package/dist/types/pm-plugins/main.d.ts +0 -1
- package/dist/types-ts4.5/pm-plugins/main.d.ts +0 -1
- package/package.json +4 -4
- package/dist/cjs/ui/analytics/index.js +0 -19
- package/dist/es2019/ui/analytics/index.js +0 -2
- package/dist/esm/ui/analytics/index.js +0 -2
- package/dist/types/ui/analytics/index.d.ts +0 -2
- package/dist/types-ts4.5/ui/analytics/index.d.ts +0 -2
package/CHANGELOG.md
CHANGED
|
@@ -4,14 +4,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
4
4
|
Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
|
-
exports.createPlugin = exports.ALLOW_EVENTS_CLASSNAME = void 0;
|
|
8
|
-
Object.defineProperty(exports, "pluginKey", {
|
|
9
|
-
enumerable: true,
|
|
10
|
-
get: function get() {
|
|
11
|
-
return _pluginKey.pluginKey;
|
|
12
|
-
}
|
|
13
|
-
});
|
|
14
|
-
exports.stopEvent = void 0;
|
|
7
|
+
exports.stopEvent = exports.createPlugin = exports.ALLOW_EVENTS_CLASSNAME = void 0;
|
|
15
8
|
var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
|
|
16
9
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
17
10
|
var _rafSchd = _interopRequireDefault(require("raf-schd"));
|
package/dist/cjs/ui/toolbar.js
CHANGED
|
@@ -30,7 +30,7 @@ var _unlink = _interopRequireDefault(require("@atlaskit/icon/glyph/editor/unlink
|
|
|
30
30
|
var _shortcut = _interopRequireDefault(require("@atlaskit/icon/glyph/shortcut"));
|
|
31
31
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
32
32
|
var _doc = require("../pm-plugins/doc");
|
|
33
|
-
var
|
|
33
|
+
var _pluginKey = require("../pm-plugins/plugin-key");
|
|
34
34
|
var _utils3 = require("../pm-plugins/utils");
|
|
35
35
|
var _DatasourceAppearanceButton = require("./DatasourceAppearanceButton");
|
|
36
36
|
var _EditLinkToolbar = require("./EditLinkToolbar");
|
|
@@ -113,7 +113,7 @@ var floatingToolbar = exports.floatingToolbar = function floatingToolbar(cardOpt
|
|
|
113
113
|
blockCard = _state$schema$nodes.blockCard,
|
|
114
114
|
embedCard = _state$schema$nodes.embedCard;
|
|
115
115
|
var nodeType = [inlineCard, blockCard, embedCard];
|
|
116
|
-
var pluginState =
|
|
116
|
+
var pluginState = _pluginKey.pluginKey.getState(state);
|
|
117
117
|
if (!(state.selection instanceof _state.NodeSelection)) {
|
|
118
118
|
return;
|
|
119
119
|
}
|
|
@@ -211,7 +211,7 @@ var generateToolbarItems = function generateToolbarItems(state, intl, providerFa
|
|
|
211
211
|
var _ref2 = (_pluginInjectionApi$d = pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$d2 = pluginInjectionApi.decorations) === null || _pluginInjectionApi$d2 === void 0 ? void 0 : _pluginInjectionApi$d2.actions) !== null && _pluginInjectionApi$d !== void 0 ? _pluginInjectionApi$d : {},
|
|
212
212
|
hoverDecoration = _ref2.hoverDecoration;
|
|
213
213
|
var isDatasource = (0, _utils3.isDatasourceNode)(node);
|
|
214
|
-
var pluginState =
|
|
214
|
+
var pluginState = _pluginKey.pluginKey.getState(state);
|
|
215
215
|
var annotationApiState = pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$a2 = pluginInjectionApi.annotation) === null || _pluginInjectionApi$a2 === void 0 ? void 0 : _pluginInjectionApi$a2.sharedState.currentState();
|
|
216
216
|
var activeCommentMark = node.marks.find(function (mark) {
|
|
217
217
|
return mark.type.name === 'annotation' && (annotationApiState === null || annotationApiState === void 0 ? void 0 : annotationApiState.annotations[mark.attrs.id]) === false;
|
|
@@ -19,7 +19,6 @@ import reducer from './reducers';
|
|
|
19
19
|
import { handleProvider, resolveWithProvider } from './util/resolve';
|
|
20
20
|
import { getNewRequests, getPluginState, getPluginStateWithUpdatedPos } from './util/state';
|
|
21
21
|
import { isBlockSupportedAtPosition, isEmbedSupportedAtPosition } from './utils';
|
|
22
|
-
export { pluginKey } from './plugin-key';
|
|
23
22
|
const LOCAL_STORAGE_DISCOVERY_KEY_SMART_LINK = 'smart-link-upgrade-pulse';
|
|
24
23
|
export const ALLOW_EVENTS_CLASSNAME = 'card-plugin-element-allow-events';
|
|
25
24
|
export const stopEvent = event => {
|
|
@@ -20,7 +20,7 @@ import UnlinkIcon from '@atlaskit/icon/glyph/editor/unlink';
|
|
|
20
20
|
import OpenIcon from '@atlaskit/icon/glyph/shortcut';
|
|
21
21
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
22
22
|
import { changeSelectedCardToText } from '../pm-plugins/doc';
|
|
23
|
-
import { pluginKey } from '../pm-plugins/
|
|
23
|
+
import { pluginKey } from '../pm-plugins/plugin-key';
|
|
24
24
|
import { appearanceForNodeType, displayInfoForCard, findCardInfo, isDatasourceNode, titleUrlPairFromNode } from '../pm-plugins/utils';
|
|
25
25
|
import { DatasourceAppearanceButton } from './DatasourceAppearanceButton';
|
|
26
26
|
import { buildEditLinkToolbar, editLinkToolbarConfig, getEditLinkCallback } from './EditLinkToolbar';
|
|
@@ -23,7 +23,6 @@ import reducer from './reducers';
|
|
|
23
23
|
import { handleProvider, resolveWithProvider } from './util/resolve';
|
|
24
24
|
import { getNewRequests, getPluginState, getPluginStateWithUpdatedPos } from './util/state';
|
|
25
25
|
import { isBlockSupportedAtPosition, isEmbedSupportedAtPosition } from './utils';
|
|
26
|
-
export { pluginKey } from './plugin-key';
|
|
27
26
|
var LOCAL_STORAGE_DISCOVERY_KEY_SMART_LINK = 'smart-link-upgrade-pulse';
|
|
28
27
|
export var ALLOW_EVENTS_CLASSNAME = 'card-plugin-element-allow-events';
|
|
29
28
|
export var stopEvent = function stopEvent(event) {
|
package/dist/esm/ui/toolbar.js
CHANGED
|
@@ -24,7 +24,7 @@ import UnlinkIcon from '@atlaskit/icon/glyph/editor/unlink';
|
|
|
24
24
|
import OpenIcon from '@atlaskit/icon/glyph/shortcut';
|
|
25
25
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
26
26
|
import { changeSelectedCardToText } from '../pm-plugins/doc';
|
|
27
|
-
import { pluginKey } from '../pm-plugins/
|
|
27
|
+
import { pluginKey } from '../pm-plugins/plugin-key';
|
|
28
28
|
import { appearanceForNodeType, displayInfoForCard, findCardInfo, isDatasourceNode, titleUrlPairFromNode } from '../pm-plugins/utils';
|
|
29
29
|
import { DatasourceAppearanceButton } from './DatasourceAppearanceButton';
|
|
30
30
|
import { buildEditLinkToolbar, editLinkToolbarConfig, getEditLinkCallback } from './EditLinkToolbar';
|
|
@@ -2,7 +2,6 @@ import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
|
2
2
|
import type { ExtractInjectionAPI, PMPluginFactoryParams } from '@atlaskit/editor-common/types';
|
|
3
3
|
import type { cardPlugin } from '../index';
|
|
4
4
|
import type { CardPluginOptions, CardPluginState } from '../types';
|
|
5
|
-
export { pluginKey } from './plugin-key';
|
|
6
5
|
export declare const ALLOW_EVENTS_CLASSNAME = "card-plugin-element-allow-events";
|
|
7
6
|
export declare const stopEvent: (event: Event) => boolean;
|
|
8
7
|
export declare const createPlugin: (options: CardPluginOptions, pluginInjectionApi: ExtractInjectionAPI<typeof cardPlugin> | undefined) => (pmPluginFactoryParams: PMPluginFactoryParams) => SafePlugin<CardPluginState>;
|
|
@@ -2,7 +2,6 @@ import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
|
2
2
|
import type { ExtractInjectionAPI, PMPluginFactoryParams } from '@atlaskit/editor-common/types';
|
|
3
3
|
import type { cardPlugin } from '../index';
|
|
4
4
|
import type { CardPluginOptions, CardPluginState } from '../types';
|
|
5
|
-
export { pluginKey } from './plugin-key';
|
|
6
5
|
export declare const ALLOW_EVENTS_CLASSNAME = "card-plugin-element-allow-events";
|
|
7
6
|
export declare const stopEvent: (event: Event) => boolean;
|
|
8
7
|
export declare const createPlugin: (options: CardPluginOptions, pluginInjectionApi: ExtractInjectionAPI<typeof cardPlugin> | undefined) => (pmPluginFactoryParams: PMPluginFactoryParams) => SafePlugin<CardPluginState>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-card",
|
|
3
|
-
"version": "4.5.
|
|
3
|
+
"version": "4.5.8",
|
|
4
4
|
"description": "Card plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"@atlaskit/adf-schema": "^46.1.0",
|
|
35
35
|
"@atlaskit/analytics-next": "^10.2.0",
|
|
36
36
|
"@atlaskit/custom-steps": "^0.9.0",
|
|
37
|
-
"@atlaskit/editor-common": "^
|
|
37
|
+
"@atlaskit/editor-common": "^97.0.0",
|
|
38
38
|
"@atlaskit/editor-plugin-analytics": "^1.10.0",
|
|
39
39
|
"@atlaskit/editor-plugin-decorations": "^1.3.0",
|
|
40
40
|
"@atlaskit/editor-plugin-editor-disabled": "^1.3.0",
|
|
@@ -55,9 +55,9 @@
|
|
|
55
55
|
"@atlaskit/menu": "2.13.7",
|
|
56
56
|
"@atlaskit/platform-feature-flags": "^0.3.0",
|
|
57
57
|
"@atlaskit/primitives": "^13.3.0",
|
|
58
|
-
"@atlaskit/smart-card": "^32.
|
|
58
|
+
"@atlaskit/smart-card": "^32.8.0",
|
|
59
59
|
"@atlaskit/theme": "^14.0.0",
|
|
60
|
-
"@atlaskit/tmp-editor-statsig": "^2.
|
|
60
|
+
"@atlaskit/tmp-editor-statsig": "^2.29.0",
|
|
61
61
|
"@atlaskit/tokens": "^2.5.0",
|
|
62
62
|
"@babel/runtime": "^7.0.0",
|
|
63
63
|
"@emotion/react": "^11.7.1",
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
Object.defineProperty(exports, "createEventsQueue", {
|
|
7
|
-
enumerable: true,
|
|
8
|
-
get: function get() {
|
|
9
|
-
return _createEventsQueue.createEventsQueue;
|
|
10
|
-
}
|
|
11
|
-
});
|
|
12
|
-
Object.defineProperty(exports, "eventsFromTransaction", {
|
|
13
|
-
enumerable: true,
|
|
14
|
-
get: function get() {
|
|
15
|
-
return _eventsFromTr.eventsFromTransaction;
|
|
16
|
-
}
|
|
17
|
-
});
|
|
18
|
-
var _createEventsQueue = require("./create-events-queue");
|
|
19
|
-
var _eventsFromTr = require("./events-from-tr");
|