@atlaskit/editor-core 188.1.0 → 188.2.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 +10 -0
- package/dist/cjs/labs/next/presets/universal.js +2 -1
- package/dist/cjs/plugins/index.js +0 -7
- package/dist/cjs/ui/WithHelpTrigger/index.js +3 -7
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/labs/next/presets/universal.js +2 -1
- package/dist/es2019/plugins/index.js +0 -1
- package/dist/es2019/ui/WithHelpTrigger/index.js +2 -7
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/labs/next/presets/universal.js +2 -1
- package/dist/esm/plugins/index.js +0 -1
- package/dist/esm/ui/WithHelpTrigger/index.js +2 -7
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/plugins/index.d.ts +0 -1
- package/dist/types/ui/WithHelpTrigger/index.d.ts +0 -4
- package/dist/types-ts4.5/plugins/index.d.ts +0 -1
- package/dist/types-ts4.5/ui/WithHelpTrigger/index.d.ts +0 -4
- package/package.json +5 -5
- package/report.api.md +1 -1
- package/tmp/api-report-tmp.d.ts +1 -1
- package/dist/cjs/plugins/help-dialog/commands.js +0 -19
- package/dist/cjs/plugins/help-dialog/index.js +0 -138
- package/dist/cjs/plugins/help-dialog/plugin-key.js +0 -8
- package/dist/cjs/plugins/help-dialog/ui/HelpDialogLoader.js +0 -24
- package/dist/cjs/plugins/help-dialog/ui/index.js +0 -563
- package/dist/cjs/plugins/help-dialog/ui/styles.js +0 -50
- package/dist/es2019/plugins/help-dialog/commands.js +0 -13
- package/dist/es2019/plugins/help-dialog/index.js +0 -125
- package/dist/es2019/plugins/help-dialog/plugin-key.js +0 -2
- package/dist/es2019/plugins/help-dialog/ui/HelpDialogLoader.js +0 -6
- package/dist/es2019/plugins/help-dialog/ui/index.js +0 -441
- package/dist/es2019/plugins/help-dialog/ui/styles.js +0 -110
- package/dist/esm/plugins/help-dialog/commands.js +0 -13
- package/dist/esm/plugins/help-dialog/index.js +0 -130
- package/dist/esm/plugins/help-dialog/plugin-key.js +0 -2
- package/dist/esm/plugins/help-dialog/ui/HelpDialogLoader.js +0 -12
- package/dist/esm/plugins/help-dialog/ui/index.js +0 -552
- package/dist/esm/plugins/help-dialog/ui/styles.js +0 -40
- package/dist/types/plugins/help-dialog/commands.d.ts +0 -3
- package/dist/types/plugins/help-dialog/index.d.ts +0 -5
- package/dist/types/plugins/help-dialog/plugin-key.d.ts +0 -2
- package/dist/types/plugins/help-dialog/ui/HelpDialogLoader.d.ts +0 -4
- package/dist/types/plugins/help-dialog/ui/index.d.ts +0 -27
- package/dist/types/plugins/help-dialog/ui/styles.d.ts +0 -33
- package/dist/types-ts4.5/plugins/help-dialog/commands.d.ts +0 -3
- package/dist/types-ts4.5/plugins/help-dialog/index.d.ts +0 -5
- package/dist/types-ts4.5/plugins/help-dialog/plugin-key.d.ts +0 -2
- package/dist/types-ts4.5/plugins/help-dialog/ui/HelpDialogLoader.d.ts +0 -4
- package/dist/types-ts4.5/plugins/help-dialog/ui/index.d.ts +0 -27
- package/dist/types-ts4.5/plugins/help-dialog/ui/styles.d.ts +0 -33
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
# @atlaskit/editor-core
|
|
2
2
|
|
|
3
|
+
## 188.2.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#41049](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/41049) [`56e271b5da6`](https://bitbucket.org/atlassian/atlassian-frontend/commits/56e271b5da6) - Extract help-dialog-plugin from editor-core
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- Updated dependencies
|
|
12
|
+
|
|
3
13
|
## 188.1.0
|
|
4
14
|
|
|
5
15
|
### Minor Changes
|
|
@@ -9,6 +9,7 @@ var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/typeof"));
|
|
|
9
9
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
10
10
|
var _api = require("../../../selection-api/api");
|
|
11
11
|
var _plugins = require("../../../plugins");
|
|
12
|
+
var _editorPluginHelpDialog = require("@atlaskit/editor-plugin-help-dialog");
|
|
12
13
|
var _editorPluginRule = require("@atlaskit/editor-plugin-rule");
|
|
13
14
|
var _editorPluginEmoji = require("@atlaskit/editor-plugin-emoji");
|
|
14
15
|
var _editorPluginList = require("@atlaskit/editor-plugin-list");
|
|
@@ -181,7 +182,7 @@ function createUniversalPreset(appearance, props, featureFlags, prevAppearance,
|
|
|
181
182
|
return builder.add([plugin, props.feedbackInfo]);
|
|
182
183
|
}
|
|
183
184
|
return builder;
|
|
184
|
-
}).maybeAdd(
|
|
185
|
+
}).maybeAdd(_editorPluginHelpDialog.helpDialogPlugin, function (plugin, builder) {
|
|
185
186
|
if (props.allowHelpDialog) {
|
|
186
187
|
return builder.add([plugin, !!props.legacyImageUploadProvider]);
|
|
187
188
|
}
|
|
@@ -143,12 +143,6 @@ Object.defineProperty(exports, "fragmentMarkPlugin", {
|
|
|
143
143
|
return _fragment.default;
|
|
144
144
|
}
|
|
145
145
|
});
|
|
146
|
-
Object.defineProperty(exports, "helpDialogPlugin", {
|
|
147
|
-
enumerable: true,
|
|
148
|
-
get: function get() {
|
|
149
|
-
return _helpDialog.default;
|
|
150
|
-
}
|
|
151
|
-
});
|
|
152
146
|
Object.defineProperty(exports, "historyPlugin", {
|
|
153
147
|
enumerable: true,
|
|
154
148
|
get: function get() {
|
|
@@ -312,7 +306,6 @@ var _collabEdit = _interopRequireDefault(require("./collab-edit"));
|
|
|
312
306
|
var _date = _interopRequireDefault(require("./date"));
|
|
313
307
|
var _extension = _interopRequireDefault(require("./extension"));
|
|
314
308
|
var _fakeTextCursor = _interopRequireDefault(require("./fake-text-cursor"));
|
|
315
|
-
var _helpDialog = _interopRequireDefault(require("./help-dialog"));
|
|
316
309
|
var _insertBlock = _interopRequireDefault(require("./insert-block"));
|
|
317
310
|
var _jiraIssue = _interopRequireDefault(require("./jira-issue"));
|
|
318
311
|
var _layout = _interopRequireDefault(require("./layout"));
|
|
@@ -17,13 +17,9 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
|
17
17
|
var _analytics = require("../../plugins/analytics");
|
|
18
18
|
var _eventDispatcher = require("../../event-dispatcher");
|
|
19
19
|
var _consts = require("../../plugins/analytics/consts");
|
|
20
|
-
var
|
|
20
|
+
var _editorPluginHelpDialog = require("@atlaskit/editor-plugin-help-dialog");
|
|
21
21
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
22
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
23
|
-
/**
|
|
24
|
-
* @deprecated
|
|
25
|
-
* Use WithHelpTrigger from @atlaskit/editor-plugin-help-dialog which uses pluginInjectionApi
|
|
26
|
-
*/
|
|
22
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
27
23
|
var WithHelpTrigger = exports.default = /*#__PURE__*/function (_React$Component) {
|
|
28
24
|
(0, _inherits2.default)(WithHelpTrigger, _React$Component);
|
|
29
25
|
var _super = _createSuper(WithHelpTrigger);
|
|
@@ -50,7 +46,7 @@ var WithHelpTrigger = exports.default = /*#__PURE__*/function (_React$Component)
|
|
|
50
46
|
});
|
|
51
47
|
var editorView = editorActions._privateGetEditorView();
|
|
52
48
|
if (editorView) {
|
|
53
|
-
(0,
|
|
49
|
+
(0, _editorPluginHelpDialog.deprecatedOpenHelpCommand)(editorView.state.tr, editorView.dispatch);
|
|
54
50
|
}
|
|
55
51
|
});
|
|
56
52
|
return _this;
|
|
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.version = exports.nextMajorVersion = exports.name = void 0;
|
|
7
7
|
var name = exports.name = "@atlaskit/editor-core";
|
|
8
|
-
var version = exports.version = "188.
|
|
8
|
+
var version = exports.version = "188.2.0";
|
|
9
9
|
var nextMajorVersion = exports.nextMajorVersion = function nextMajorVersion() {
|
|
10
10
|
return [Number(version.split('.')[0]) + 1, 0, 0].join('.');
|
|
11
11
|
};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { createEditorSelectionAPI } from '../../../selection-api/api';
|
|
2
|
-
import { breakoutPlugin, collabEditPlugin, dataConsumerMarkPlugin, datePlugin, extensionPlugin, fragmentMarkPlugin,
|
|
2
|
+
import { breakoutPlugin, collabEditPlugin, dataConsumerMarkPlugin, datePlugin, extensionPlugin, fragmentMarkPlugin, insertBlockPlugin, jiraIssuePlugin, layoutPlugin, toolbarListsIndentationPlugin, macroPlugin, maxContentSizePlugin, mediaPlugin, mentionsPlugin, panelPlugin, placeholderTextPlugin, saveOnEnterPlugin, tasksAndDecisionsPlugin, textColorPlugin, statusPlugin, alignmentPlugin, indentationPlugin, customAutoformatPlugin, feedbackDialogPlugin, historyPlugin, expandPlugin, isExpandInsertionEnabled, scrollIntoViewPlugin, mobileDimensionsPlugin, findReplacePlugin, mobileSelectionPlugin, annotationPlugin, captionPlugin, avatarGroupPlugin, viewUpdateSubscriptionPlugin, beforePrimaryToolbarPlugin, codeBidiWarningPlugin, borderPlugin } from '../../../plugins';
|
|
3
|
+
import { helpDialogPlugin } from '@atlaskit/editor-plugin-help-dialog';
|
|
3
4
|
import { rulePlugin } from '@atlaskit/editor-plugin-rule';
|
|
4
5
|
import { emojiPlugin } from '@atlaskit/editor-plugin-emoji';
|
|
5
6
|
import { listPlugin } from '@atlaskit/editor-plugin-list';
|
|
@@ -5,7 +5,6 @@ export { default as collabEditPlugin } from './collab-edit';
|
|
|
5
5
|
export { default as datePlugin } from './date';
|
|
6
6
|
export { default as extensionPlugin } from './extension';
|
|
7
7
|
export { default as fakeTextCursorPlugin } from './fake-text-cursor';
|
|
8
|
-
export { default as helpDialogPlugin } from './help-dialog';
|
|
9
8
|
export { default as insertBlockPlugin } from './insert-block';
|
|
10
9
|
export { default as jiraIssuePlugin } from './jira-issue';
|
|
11
10
|
export { default as layoutPlugin } from './layout';
|
|
@@ -4,12 +4,7 @@ import PropTypes from 'prop-types';
|
|
|
4
4
|
import { ACTION, ACTION_SUBJECT, INPUT_METHOD, EVENT_TYPE, ACTION_SUBJECT_ID } from '../../plugins/analytics';
|
|
5
5
|
import { createDispatch } from '../../event-dispatcher';
|
|
6
6
|
import { analyticsEventKey } from '../../plugins/analytics/consts';
|
|
7
|
-
|
|
8
|
-
import { openHelpCommand } from '../../plugins/help-dialog/commands';
|
|
9
|
-
/**
|
|
10
|
-
* @deprecated
|
|
11
|
-
* Use WithHelpTrigger from @atlaskit/editor-plugin-help-dialog which uses pluginInjectionApi
|
|
12
|
-
*/
|
|
7
|
+
import { deprecatedOpenHelpCommand } from '@atlaskit/editor-plugin-help-dialog';
|
|
13
8
|
export default class WithHelpTrigger extends React.Component {
|
|
14
9
|
constructor(...args) {
|
|
15
10
|
super(...args);
|
|
@@ -31,7 +26,7 @@ export default class WithHelpTrigger extends React.Component {
|
|
|
31
26
|
});
|
|
32
27
|
const editorView = editorActions._privateGetEditorView();
|
|
33
28
|
if (editorView) {
|
|
34
|
-
|
|
29
|
+
deprecatedOpenHelpCommand(editorView.state.tr, editorView.dispatch);
|
|
35
30
|
}
|
|
36
31
|
});
|
|
37
32
|
}
|
|
@@ -3,7 +3,8 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
3
3
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
4
4
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
5
5
|
import { createEditorSelectionAPI } from '../../../selection-api/api';
|
|
6
|
-
import { breakoutPlugin, collabEditPlugin, dataConsumerMarkPlugin, datePlugin, extensionPlugin, fragmentMarkPlugin,
|
|
6
|
+
import { breakoutPlugin, collabEditPlugin, dataConsumerMarkPlugin, datePlugin, extensionPlugin, fragmentMarkPlugin, insertBlockPlugin, jiraIssuePlugin, layoutPlugin, toolbarListsIndentationPlugin, macroPlugin, maxContentSizePlugin, mediaPlugin, mentionsPlugin, panelPlugin, placeholderTextPlugin, saveOnEnterPlugin, tasksAndDecisionsPlugin, textColorPlugin, statusPlugin, alignmentPlugin, indentationPlugin, customAutoformatPlugin, feedbackDialogPlugin, historyPlugin, expandPlugin, isExpandInsertionEnabled, scrollIntoViewPlugin, mobileDimensionsPlugin, findReplacePlugin, mobileSelectionPlugin, annotationPlugin, captionPlugin, avatarGroupPlugin, viewUpdateSubscriptionPlugin, beforePrimaryToolbarPlugin, codeBidiWarningPlugin, borderPlugin } from '../../../plugins';
|
|
7
|
+
import { helpDialogPlugin } from '@atlaskit/editor-plugin-help-dialog';
|
|
7
8
|
import { rulePlugin } from '@atlaskit/editor-plugin-rule';
|
|
8
9
|
import { emojiPlugin } from '@atlaskit/editor-plugin-emoji';
|
|
9
10
|
import { listPlugin } from '@atlaskit/editor-plugin-list';
|
|
@@ -5,7 +5,6 @@ export { default as collabEditPlugin } from './collab-edit';
|
|
|
5
5
|
export { default as datePlugin } from './date';
|
|
6
6
|
export { default as extensionPlugin } from './extension';
|
|
7
7
|
export { default as fakeTextCursorPlugin } from './fake-text-cursor';
|
|
8
|
-
export { default as helpDialogPlugin } from './help-dialog';
|
|
9
8
|
export { default as insertBlockPlugin } from './insert-block';
|
|
10
9
|
export { default as jiraIssuePlugin } from './jira-issue';
|
|
11
10
|
export { default as layoutPlugin } from './layout';
|
|
@@ -12,12 +12,7 @@ import PropTypes from 'prop-types';
|
|
|
12
12
|
import { ACTION, ACTION_SUBJECT, INPUT_METHOD, EVENT_TYPE, ACTION_SUBJECT_ID } from '../../plugins/analytics';
|
|
13
13
|
import { createDispatch } from '../../event-dispatcher';
|
|
14
14
|
import { analyticsEventKey } from '../../plugins/analytics/consts';
|
|
15
|
-
|
|
16
|
-
import { openHelpCommand } from '../../plugins/help-dialog/commands';
|
|
17
|
-
/**
|
|
18
|
-
* @deprecated
|
|
19
|
-
* Use WithHelpTrigger from @atlaskit/editor-plugin-help-dialog which uses pluginInjectionApi
|
|
20
|
-
*/
|
|
15
|
+
import { deprecatedOpenHelpCommand } from '@atlaskit/editor-plugin-help-dialog';
|
|
21
16
|
var WithHelpTrigger = /*#__PURE__*/function (_React$Component) {
|
|
22
17
|
_inherits(WithHelpTrigger, _React$Component);
|
|
23
18
|
var _super = _createSuper(WithHelpTrigger);
|
|
@@ -44,7 +39,7 @@ var WithHelpTrigger = /*#__PURE__*/function (_React$Component) {
|
|
|
44
39
|
});
|
|
45
40
|
var editorView = editorActions._privateGetEditorView();
|
|
46
41
|
if (editorView) {
|
|
47
|
-
|
|
42
|
+
deprecatedOpenHelpCommand(editorView.state.tr, editorView.dispatch);
|
|
48
43
|
}
|
|
49
44
|
});
|
|
50
45
|
return _this;
|
|
@@ -5,7 +5,6 @@ export { default as collabEditPlugin } from './collab-edit';
|
|
|
5
5
|
export { default as datePlugin } from './date';
|
|
6
6
|
export { default as extensionPlugin } from './extension';
|
|
7
7
|
export { default as fakeTextCursorPlugin } from './fake-text-cursor';
|
|
8
|
-
export { default as helpDialogPlugin } from './help-dialog';
|
|
9
8
|
export { default as insertBlockPlugin } from './insert-block';
|
|
10
9
|
export { default as jiraIssuePlugin } from './jira-issue';
|
|
11
10
|
export { default as layoutPlugin } from './layout';
|
|
@@ -3,10 +3,6 @@ import PropTypes from 'prop-types';
|
|
|
3
3
|
interface WithHelpTriggerProps {
|
|
4
4
|
render: (openHelp: () => void) => React.ReactNode;
|
|
5
5
|
}
|
|
6
|
-
/**
|
|
7
|
-
* @deprecated
|
|
8
|
-
* Use WithHelpTrigger from @atlaskit/editor-plugin-help-dialog which uses pluginInjectionApi
|
|
9
|
-
*/
|
|
10
6
|
export default class WithHelpTrigger extends React.Component<WithHelpTriggerProps, any> {
|
|
11
7
|
static contextTypes: {
|
|
12
8
|
editorActions: PropTypes.Validator<object>;
|
|
@@ -5,7 +5,6 @@ export { default as collabEditPlugin } from './collab-edit';
|
|
|
5
5
|
export { default as datePlugin } from './date';
|
|
6
6
|
export { default as extensionPlugin } from './extension';
|
|
7
7
|
export { default as fakeTextCursorPlugin } from './fake-text-cursor';
|
|
8
|
-
export { default as helpDialogPlugin } from './help-dialog';
|
|
9
8
|
export { default as insertBlockPlugin } from './insert-block';
|
|
10
9
|
export { default as jiraIssuePlugin } from './jira-issue';
|
|
11
10
|
export { default as layoutPlugin } from './layout';
|
|
@@ -3,10 +3,6 @@ import PropTypes from 'prop-types';
|
|
|
3
3
|
interface WithHelpTriggerProps {
|
|
4
4
|
render: (openHelp: () => void) => React.ReactNode;
|
|
5
5
|
}
|
|
6
|
-
/**
|
|
7
|
-
* @deprecated
|
|
8
|
-
* Use WithHelpTrigger from @atlaskit/editor-plugin-help-dialog which uses pluginInjectionApi
|
|
9
|
-
*/
|
|
10
6
|
export default class WithHelpTrigger extends React.Component<WithHelpTriggerProps, any> {
|
|
11
7
|
static contextTypes: {
|
|
12
8
|
editorActions: PropTypes.Validator<object>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-core",
|
|
3
|
-
"version": "188.
|
|
3
|
+
"version": "188.2.0",
|
|
4
4
|
"description": "A package contains Atlassian editor core functionality",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"@atlaskit/code": "^14.6.0",
|
|
56
56
|
"@atlaskit/date": "^0.10.0",
|
|
57
57
|
"@atlaskit/datetime-picker": "^12.10.0",
|
|
58
|
-
"@atlaskit/editor-common": "^76.
|
|
58
|
+
"@atlaskit/editor-common": "^76.3.0",
|
|
59
59
|
"@atlaskit/editor-json-transformer": "^8.10.0",
|
|
60
60
|
"@atlaskit/editor-markdown-transformer": "^5.2.5",
|
|
61
61
|
"@atlaskit/editor-palette": "1.5.1",
|
|
@@ -76,7 +76,7 @@
|
|
|
76
76
|
"@atlaskit/editor-plugin-focus": "^0.2.0",
|
|
77
77
|
"@atlaskit/editor-plugin-grid": "^0.3.0",
|
|
78
78
|
"@atlaskit/editor-plugin-guideline": "^0.5.0",
|
|
79
|
-
"@atlaskit/editor-plugin-help-dialog": "^0.
|
|
79
|
+
"@atlaskit/editor-plugin-help-dialog": "^0.2.0",
|
|
80
80
|
"@atlaskit/editor-plugin-hyperlink": "^0.5.0",
|
|
81
81
|
"@atlaskit/editor-plugin-image-upload": "^0.2.0",
|
|
82
82
|
"@atlaskit/editor-plugin-list": "^1.3.0",
|
|
@@ -107,7 +107,6 @@
|
|
|
107
107
|
"@atlaskit/media-viewer": "^48.1.0",
|
|
108
108
|
"@atlaskit/mention": "^22.1.0",
|
|
109
109
|
"@atlaskit/menu": "^1.11.0",
|
|
110
|
-
"@atlaskit/modal-dialog": "^12.7.0",
|
|
111
110
|
"@atlaskit/platform-feature-flags": "^0.2.0",
|
|
112
111
|
"@atlaskit/prosemirror-collab": "^0.2.0",
|
|
113
112
|
"@atlaskit/prosemirror-input-rules": "^2.4.0",
|
|
@@ -156,7 +155,7 @@
|
|
|
156
155
|
"@af/integration-testing": "*",
|
|
157
156
|
"@af/visual-regression": "*",
|
|
158
157
|
"@atlaskit/code": "^14.6.0",
|
|
159
|
-
"@atlaskit/collab-provider": "9.
|
|
158
|
+
"@atlaskit/collab-provider": "9.14.0",
|
|
160
159
|
"@atlaskit/dropdown-menu": "^11.14.0",
|
|
161
160
|
"@atlaskit/editor-extension-dropbox": "^0.4.0",
|
|
162
161
|
"@atlaskit/editor-plugin-table": "^4.0.0",
|
|
@@ -170,6 +169,7 @@
|
|
|
170
169
|
"@atlaskit/media-integration-test-helpers": "^3.0.0",
|
|
171
170
|
"@atlaskit/media-test-helpers": "^33.0.0",
|
|
172
171
|
"@atlaskit/menu": "^1.11.0",
|
|
172
|
+
"@atlaskit/modal-dialog": "^12.7.0",
|
|
173
173
|
"@atlaskit/platform-feature-flags": "^0.2.0",
|
|
174
174
|
"@atlaskit/renderer": "^108.15.0",
|
|
175
175
|
"@atlaskit/section-message": "^6.4.0",
|
package/report.api.md
CHANGED
|
@@ -836,7 +836,7 @@ interface WithEditorActionsProps {
|
|
|
836
836
|
render(actions: EditorActions): React_2.ReactElement<any> | null;
|
|
837
837
|
}
|
|
838
838
|
|
|
839
|
-
// @public
|
|
839
|
+
// @public (undocumented)
|
|
840
840
|
export class WithHelpTrigger extends React_2.Component<
|
|
841
841
|
WithHelpTriggerProps,
|
|
842
842
|
any
|
package/tmp/api-report-tmp.d.ts
CHANGED
|
@@ -768,7 +768,7 @@ interface WithEditorActionsProps {
|
|
|
768
768
|
render(actions: EditorActions): React_2.ReactElement<any> | null;
|
|
769
769
|
}
|
|
770
770
|
|
|
771
|
-
// @public
|
|
771
|
+
// @public (undocumented)
|
|
772
772
|
export class WithHelpTrigger extends React_2.Component<WithHelpTriggerProps, any> {
|
|
773
773
|
// (undocumented)
|
|
774
774
|
static contextTypes: {
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.openHelpCommand = exports.closeHelpCommand = void 0;
|
|
7
|
-
var _pluginKey = require("./plugin-key");
|
|
8
|
-
var openHelpCommand = exports.openHelpCommand = function openHelpCommand(tr, dispatch) {
|
|
9
|
-
tr = tr.setMeta(_pluginKey.pluginKey, true);
|
|
10
|
-
if (dispatch) {
|
|
11
|
-
dispatch(tr);
|
|
12
|
-
return true;
|
|
13
|
-
}
|
|
14
|
-
return false;
|
|
15
|
-
};
|
|
16
|
-
var closeHelpCommand = exports.closeHelpCommand = function closeHelpCommand(tr, dispatch) {
|
|
17
|
-
tr = tr.setMeta(_pluginKey.pluginKey, false);
|
|
18
|
-
dispatch(tr);
|
|
19
|
-
};
|
|
@@ -1,138 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
Object.defineProperty(exports, "__esModule", {
|
|
5
|
-
value: true
|
|
6
|
-
});
|
|
7
|
-
exports.createPlugin = createPlugin;
|
|
8
|
-
exports.default = void 0;
|
|
9
|
-
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
10
|
-
var _react = _interopRequireDefault(require("react"));
|
|
11
|
-
var _keymap = require("@atlaskit/editor-prosemirror/keymap");
|
|
12
|
-
var _safePlugin = require("@atlaskit/editor-common/safe-plugin");
|
|
13
|
-
var _keymaps = require("@atlaskit/editor-common/keymaps");
|
|
14
|
-
var _HelpDialogLoader = require("./ui/HelpDialogLoader");
|
|
15
|
-
var _analytics = require("@atlaskit/editor-common/analytics");
|
|
16
|
-
var _questionCircle = _interopRequireDefault(require("@atlaskit/icon/glyph/question-circle"));
|
|
17
|
-
var _messages = require("@atlaskit/editor-common/messages");
|
|
18
|
-
var _commands = require("./commands");
|
|
19
|
-
var _pluginKey = require("./plugin-key");
|
|
20
|
-
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
21
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
22
|
-
function createPlugin(dispatch, imageEnabled) {
|
|
23
|
-
return new _safePlugin.SafePlugin({
|
|
24
|
-
key: _pluginKey.pluginKey,
|
|
25
|
-
state: {
|
|
26
|
-
init: function init() {
|
|
27
|
-
return {
|
|
28
|
-
isVisible: false,
|
|
29
|
-
imageEnabled: imageEnabled
|
|
30
|
-
};
|
|
31
|
-
},
|
|
32
|
-
apply: function apply(tr, _value, state) {
|
|
33
|
-
var isVisible = tr.getMeta(_pluginKey.pluginKey);
|
|
34
|
-
var currentState = _pluginKey.pluginKey.getState(state);
|
|
35
|
-
if (isVisible !== undefined && isVisible !== currentState.isVisible) {
|
|
36
|
-
var newState = _objectSpread(_objectSpread({}, currentState), {}, {
|
|
37
|
-
isVisible: isVisible
|
|
38
|
-
});
|
|
39
|
-
dispatch(_pluginKey.pluginKey, newState);
|
|
40
|
-
return newState;
|
|
41
|
-
}
|
|
42
|
-
return currentState;
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
});
|
|
46
|
-
}
|
|
47
|
-
var helpDialog = function helpDialog(_ref) {
|
|
48
|
-
var _ref$config = _ref.config,
|
|
49
|
-
imageUploadProviderExists = _ref$config === void 0 ? false : _ref$config,
|
|
50
|
-
api = _ref.api;
|
|
51
|
-
return {
|
|
52
|
-
name: 'helpDialog',
|
|
53
|
-
pmPlugins: function pmPlugins() {
|
|
54
|
-
return [{
|
|
55
|
-
name: 'helpDialog',
|
|
56
|
-
plugin: function plugin(_ref2) {
|
|
57
|
-
var dispatch = _ref2.dispatch;
|
|
58
|
-
return createPlugin(dispatch, imageUploadProviderExists);
|
|
59
|
-
}
|
|
60
|
-
}, {
|
|
61
|
-
name: 'helpDialogKeymap',
|
|
62
|
-
plugin: function plugin() {
|
|
63
|
-
var _api$analytics;
|
|
64
|
-
return keymapPlugin(api === null || api === void 0 || (_api$analytics = api.analytics) === null || _api$analytics === void 0 ? void 0 : _api$analytics.actions);
|
|
65
|
-
}
|
|
66
|
-
}];
|
|
67
|
-
},
|
|
68
|
-
pluginsOptions: {
|
|
69
|
-
quickInsert: function quickInsert(_ref3) {
|
|
70
|
-
var formatMessage = _ref3.formatMessage;
|
|
71
|
-
return [{
|
|
72
|
-
id: 'helpdialog',
|
|
73
|
-
title: formatMessage(_messages.toolbarInsertBlockMessages.help),
|
|
74
|
-
description: formatMessage(_messages.toolbarInsertBlockMessages.helpDescription),
|
|
75
|
-
keywords: ['?'],
|
|
76
|
-
priority: 4000,
|
|
77
|
-
keyshortcut: (0, _keymaps.tooltip)(_keymaps.openHelp),
|
|
78
|
-
icon: function icon() {
|
|
79
|
-
return /*#__PURE__*/_react.default.createElement(_questionCircle.default, {
|
|
80
|
-
label: ""
|
|
81
|
-
});
|
|
82
|
-
},
|
|
83
|
-
action: function action(insert) {
|
|
84
|
-
var _api$analytics2;
|
|
85
|
-
var tr = insert('');
|
|
86
|
-
(0, _commands.openHelpCommand)(tr);
|
|
87
|
-
api === null || api === void 0 || (_api$analytics2 = api.analytics) === null || _api$analytics2 === void 0 || _api$analytics2.actions.attachAnalyticsEvent({
|
|
88
|
-
action: _analytics.ACTION.HELP_OPENED,
|
|
89
|
-
actionSubject: _analytics.ACTION_SUBJECT.HELP,
|
|
90
|
-
actionSubjectId: _analytics.ACTION_SUBJECT_ID.HELP_QUICK_INSERT,
|
|
91
|
-
attributes: {
|
|
92
|
-
inputMethod: _analytics.INPUT_METHOD.QUICK_INSERT
|
|
93
|
-
},
|
|
94
|
-
eventType: _analytics.EVENT_TYPE.UI
|
|
95
|
-
})(tr);
|
|
96
|
-
return tr;
|
|
97
|
-
}
|
|
98
|
-
}];
|
|
99
|
-
}
|
|
100
|
-
},
|
|
101
|
-
contentComponent: function contentComponent(_ref4) {
|
|
102
|
-
var editorView = _ref4.editorView;
|
|
103
|
-
return /*#__PURE__*/_react.default.createElement(_HelpDialogLoader.HelpDialogLoader, {
|
|
104
|
-
pluginInjectionApi: api,
|
|
105
|
-
editorView: editorView,
|
|
106
|
-
quickInsertEnabled: !!(api !== null && api !== void 0 && api.quickInsert)
|
|
107
|
-
});
|
|
108
|
-
},
|
|
109
|
-
getSharedState: function getSharedState(editorState) {
|
|
110
|
-
if (!editorState) {
|
|
111
|
-
return null;
|
|
112
|
-
}
|
|
113
|
-
return _pluginKey.pluginKey.getState(editorState) || null;
|
|
114
|
-
}
|
|
115
|
-
};
|
|
116
|
-
};
|
|
117
|
-
var keymapPlugin = function keymapPlugin(editorAnalyticsAPI) {
|
|
118
|
-
var list = {};
|
|
119
|
-
(0, _keymaps.bindKeymapWithCommand)(_keymaps.openHelp.common, function (state, dispatch) {
|
|
120
|
-
var tr = state.tr;
|
|
121
|
-
var isVisible = tr.getMeta(_pluginKey.pluginKey);
|
|
122
|
-
if (!isVisible) {
|
|
123
|
-
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 || editorAnalyticsAPI.attachAnalyticsEvent({
|
|
124
|
-
action: _analytics.ACTION.CLICKED,
|
|
125
|
-
actionSubject: _analytics.ACTION_SUBJECT.BUTTON,
|
|
126
|
-
actionSubjectId: _analytics.ACTION_SUBJECT_ID.BUTTON_HELP,
|
|
127
|
-
attributes: {
|
|
128
|
-
inputMethod: _analytics.INPUT_METHOD.SHORTCUT
|
|
129
|
-
},
|
|
130
|
-
eventType: _analytics.EVENT_TYPE.UI
|
|
131
|
-
})(tr);
|
|
132
|
-
(0, _commands.openHelpCommand)(tr, dispatch);
|
|
133
|
-
}
|
|
134
|
-
return true;
|
|
135
|
-
}, list);
|
|
136
|
-
return (0, _keymap.keymap)(list);
|
|
137
|
-
};
|
|
138
|
-
var _default = exports.default = helpDialog;
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
Object.defineProperty(exports, "__esModule", {
|
|
5
|
-
value: true
|
|
6
|
-
});
|
|
7
|
-
exports.HelpDialogLoader = void 0;
|
|
8
|
-
var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/typeof"));
|
|
9
|
-
var _reactLoadable = _interopRequireDefault(require("react-loadable"));
|
|
10
|
-
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
11
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || (0, _typeof2.default)(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
12
|
-
var HelpDialogLoader = exports.HelpDialogLoader = (0, _reactLoadable.default)({
|
|
13
|
-
loader: function loader() {
|
|
14
|
-
return Promise.resolve().then(function () {
|
|
15
|
-
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_editor-core-helpdialog" */
|
|
16
|
-
'./index'));
|
|
17
|
-
}).then(function (mod) {
|
|
18
|
-
return mod.default;
|
|
19
|
-
});
|
|
20
|
-
},
|
|
21
|
-
loading: function loading() {
|
|
22
|
-
return null;
|
|
23
|
-
}
|
|
24
|
-
});
|