@atlaskit/editor-core 187.6.1 → 187.7.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 +17 -0
- package/dist/cjs/plugins/expand/commands.js +2 -1
- package/dist/cjs/plugins/expand/index.js +1 -1
- package/dist/cjs/plugins/media/pm-plugins/main.js +14 -1
- package/dist/cjs/ui/Appearance/FullPage/MainToolbar.js +1 -1
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/plugins/expand/commands.js +2 -1
- package/dist/es2019/plugins/expand/index.js +1 -1
- package/dist/es2019/plugins/media/pm-plugins/main.js +10 -0
- package/dist/es2019/plugins/media/ui/ResizableMediaSingle/index.js +1 -2
- package/dist/es2019/ui/Appearance/FullPage/MainToolbar.js +2 -2
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/es2019/version.json +1 -1
- package/dist/esm/plugins/expand/commands.js +2 -1
- package/dist/esm/plugins/expand/index.js +1 -1
- package/dist/esm/plugins/media/pm-plugins/main.js +12 -0
- package/dist/esm/plugins/media/ui/ResizableMediaSingle/index.js +1 -2
- package/dist/esm/ui/Appearance/FullPage/MainToolbar.js +2 -2
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/esm/version.json +1 -1
- package/dist/types/plugins/media/pm-plugins/main.d.ts +3 -0
- package/dist/types/plugins/media/pm-plugins/types.d.ts +13 -11
- package/dist/types/plugins/media/toolbar/index.d.ts +5 -5
- package/dist/types/plugins/media/ui/ResizableMediaSingle/index.d.ts +3 -3
- package/dist/types-ts4.5/plugins/media/pm-plugins/main.d.ts +3 -0
- package/dist/types-ts4.5/plugins/media/pm-plugins/types.d.ts +13 -11
- package/dist/types-ts4.5/plugins/media/toolbar/index.d.ts +5 -5
- package/dist/types-ts4.5/plugins/media/ui/ResizableMediaSingle/index.d.ts +3 -3
- package/package.json +6 -6
- package/report.api.md +6 -2
- package/tmp/api-report-tmp.d.ts +6 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,22 @@
|
|
|
1
1
|
# @atlaskit/editor-core
|
|
2
2
|
|
|
3
|
+
## 187.7.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [`e83596269e5`](https://bitbucket.org/atlassian/atlassian-frontend/commits/e83596269e5) - Add isResizing support into media plugin
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- Updated dependencies
|
|
12
|
+
|
|
13
|
+
## 187.6.10
|
|
14
|
+
|
|
15
|
+
### Patch Changes
|
|
16
|
+
|
|
17
|
+
- [`fa2209eee80`](https://bitbucket.org/atlassian/atlassian-frontend/commits/fa2209eee80) - [ux] Fixes z-index full page editor main toolbar
|
|
18
|
+
- [`9b64591559a`](https://bitbucket.org/atlassian/atlassian-frontend/commits/9b64591559a) - [ux] ED-19163 Expand should only wrap selected text if added inline
|
|
19
|
+
|
|
3
20
|
## 187.6.1
|
|
4
21
|
|
|
5
22
|
### Patch Changes
|
|
@@ -13,6 +13,7 @@ var _gapCursorSelection = require("../selection/gap-cursor-selection");
|
|
|
13
13
|
var _utils2 = require("./utils");
|
|
14
14
|
var _pluginFactory = require("./pm-plugins/plugin-factory");
|
|
15
15
|
var _blockType = require("../block-type/commands/block-type");
|
|
16
|
+
var _prosemirrorUtils = require("prosemirror-utils");
|
|
16
17
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
17
18
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
18
19
|
var setExpandRef = function setExpandRef(ref) {
|
|
@@ -123,7 +124,7 @@ var insertExpand = function insertExpand(state, dispatch) {
|
|
|
123
124
|
if (!expandNode) {
|
|
124
125
|
return false;
|
|
125
126
|
}
|
|
126
|
-
var tr = (0, _blockType.createWrapSelectionTransaction)({
|
|
127
|
+
var tr = state.selection.empty ? (0, _prosemirrorUtils.safeInsert)(expandNode)(state.tr).scrollIntoView() : (0, _blockType.createWrapSelectionTransaction)({
|
|
127
128
|
state: state,
|
|
128
129
|
type: expandNode.type
|
|
129
130
|
});
|
|
@@ -74,7 +74,7 @@ var expandPlugin = function expandPlugin() {
|
|
|
74
74
|
if (!node) {
|
|
75
75
|
return false;
|
|
76
76
|
}
|
|
77
|
-
var tr = (0, _blockType.createWrapSelectionTransaction)({
|
|
77
|
+
var tr = state.selection.empty ? insert(node) : (0, _blockType.createWrapSelectionTransaction)({
|
|
78
78
|
state: state,
|
|
79
79
|
type: node.type
|
|
80
80
|
});
|
|
@@ -5,7 +5,7 @@ var _typeof = require("@babel/runtime/helpers/typeof");
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports.getMediaPluginState = exports.createPlugin = exports.MediaPluginStateImplementation = exports.MEDIA_CONTENT_WRAP_CLASS_NAME = void 0;
|
|
8
|
+
exports.getMediaPluginState = exports.createPlugin = exports.MediaPluginStateImplementation = exports.MEDIA_PLUGIN_IS_RESIZING_KEY = exports.MEDIA_CONTENT_WRAP_CLASS_NAME = void 0;
|
|
9
9
|
Object.defineProperty(exports, "stateKey", {
|
|
10
10
|
enumerable: true,
|
|
11
11
|
get: function get() {
|
|
@@ -50,6 +50,8 @@ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (O
|
|
|
50
50
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
51
51
|
var MEDIA_CONTENT_WRAP_CLASS_NAME = 'media-content-wrap';
|
|
52
52
|
exports.MEDIA_CONTENT_WRAP_CLASS_NAME = MEDIA_CONTENT_WRAP_CLASS_NAME;
|
|
53
|
+
var MEDIA_PLUGIN_IS_RESIZING_KEY = 'mediaSinglePlugin.isResizing';
|
|
54
|
+
exports.MEDIA_PLUGIN_IS_RESIZING_KEY = MEDIA_PLUGIN_IS_RESIZING_KEY;
|
|
53
55
|
var createDropPlaceholder = function createDropPlaceholder(intl, allowDropLine) {
|
|
54
56
|
var dropPlaceholder = document.createElement('div');
|
|
55
57
|
var createElement = _react.default.createElement;
|
|
@@ -81,6 +83,7 @@ var MediaPluginStateImplementation = /*#__PURE__*/function () {
|
|
|
81
83
|
(0, _defineProperty2.default)(this, "isFullscreen", false);
|
|
82
84
|
(0, _defineProperty2.default)(this, "layout", 'center');
|
|
83
85
|
(0, _defineProperty2.default)(this, "mediaNodes", []);
|
|
86
|
+
(0, _defineProperty2.default)(this, "isResizing", false);
|
|
84
87
|
(0, _defineProperty2.default)(this, "destroyed", false);
|
|
85
88
|
(0, _defineProperty2.default)(this, "removeOnCloseListener", function () {});
|
|
86
89
|
(0, _defineProperty2.default)(this, "onPopupToggleCallback", function () {});
|
|
@@ -491,6 +494,11 @@ var MediaPluginStateImplementation = /*#__PURE__*/function () {
|
|
|
491
494
|
this.errorReporter = options.errorReporter || new _utils.ErrorReporter();
|
|
492
495
|
}
|
|
493
496
|
(0, _createClass2.default)(MediaPluginStateImplementation, [{
|
|
497
|
+
key: "setIsResizing",
|
|
498
|
+
value: function setIsResizing(isResizing) {
|
|
499
|
+
this.isResizing = isResizing;
|
|
500
|
+
}
|
|
501
|
+
}, {
|
|
494
502
|
key: "updateElement",
|
|
495
503
|
value: function updateElement() {
|
|
496
504
|
var newElement;
|
|
@@ -632,6 +640,11 @@ var createPlugin = function createPlugin(_schema, options, reactContext, getIntl
|
|
|
632
640
|
return new MediaPluginStateImplementation(state, options, mediaOptions, newInsertionBehaviour, dispatch, pluginInjectionApi);
|
|
633
641
|
},
|
|
634
642
|
apply: function apply(tr, pluginState) {
|
|
643
|
+
var isResizing = tr.getMeta(MEDIA_PLUGIN_IS_RESIZING_KEY);
|
|
644
|
+
if (isResizing !== undefined) {
|
|
645
|
+
pluginState.setIsResizing(isResizing);
|
|
646
|
+
}
|
|
647
|
+
|
|
635
648
|
// remap editing media single position if we're in collab
|
|
636
649
|
if (typeof pluginState.editingMediaSinglePos === 'number') {
|
|
637
650
|
pluginState.editingMediaSinglePos = tr.mapping.map(pluginState.editingMediaSinglePos);
|
|
@@ -17,7 +17,7 @@ var toolbarLineHeight = 56;
|
|
|
17
17
|
// box-shadow is overriden by the mainToolbar
|
|
18
18
|
var mainToolbarWithKeyline = (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n box-shadow: 0 ", "px 0 0\n ", ";\n"])), _editorSharedStyles.akEditorToolbarKeylineHeight, "var(--ds-border, ".concat(_colors.N30, ")"));
|
|
19
19
|
var mainToolbarTwoLineStyle = (0, _react.css)(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n @media (max-width: ", "px) {\n flex-wrap: wrap;\n height: calc(", "px * 2);\n }\n"])), MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT, toolbarLineHeight);
|
|
20
|
-
var mainToolbar = (0, _react.css)(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n position: relative;\n align-items: center;\n box-shadow: none;\n transition: box-shadow 200ms ", ";\n z-index: ", ";\n display: flex;\n height: ", "px;\n flex-shrink: 0;\n // TODO: https://product-fabric.atlassian.net/browse/DSP-4456\n background-color: ", ";\n\n & object {\n height: 0 !important;\n }\n\n @media (max-width: ", "px) {\n display: grid;\n height: calc(", "px * 2);\n }\n"])), _editorSharedStyles.akEditorSwoopCubicBezier, _editorSharedStyles.
|
|
20
|
+
var mainToolbar = (0, _react.css)(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n position: relative;\n align-items: center;\n box-shadow: none;\n transition: box-shadow 200ms ", ";\n z-index: ", ";\n display: flex;\n height: ", "px;\n flex-shrink: 0;\n // TODO: https://product-fabric.atlassian.net/browse/DSP-4456\n background-color: ", ";\n\n & object {\n height: 0 !important;\n }\n\n @media (max-width: ", "px) {\n display: grid;\n height: calc(", "px * 2);\n }\n"])), _editorSharedStyles.akEditorSwoopCubicBezier, _editorSharedStyles.akEditorFloatingDialogZIndex, toolbarLineHeight, "var(--ds-surface, white)", _editorSharedStyles.akEditorMobileMaxWidth, toolbarLineHeight);
|
|
21
21
|
var mainToolbarStyle = function mainToolbarStyle(showKeyline, twoLineEditorToolbar) {
|
|
22
22
|
return [mainToolbar, showKeyline && mainToolbarWithKeyline, twoLineEditorToolbar && mainToolbarTwoLineStyle];
|
|
23
23
|
};
|
|
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.version = exports.nextMajorVersion = exports.name = void 0;
|
|
7
7
|
var name = "@atlaskit/editor-core";
|
|
8
8
|
exports.name = name;
|
|
9
|
-
var version = "187.
|
|
9
|
+
var version = "187.7.0";
|
|
10
10
|
exports.version = version;
|
|
11
11
|
var nextMajorVersion = function nextMajorVersion() {
|
|
12
12
|
return [Number(version.split('.')[0]) + 1, 0, 0].join('.');
|
package/dist/cjs/version.json
CHANGED
|
@@ -5,6 +5,7 @@ import { GapCursorSelection, Side } from '../selection/gap-cursor-selection';
|
|
|
5
5
|
import { findExpand } from './utils';
|
|
6
6
|
import { createCommand } from './pm-plugins/plugin-factory';
|
|
7
7
|
import { createWrapSelectionTransaction } from '../block-type/commands/block-type';
|
|
8
|
+
import { safeInsert } from 'prosemirror-utils';
|
|
8
9
|
export const setExpandRef = ref => createCommand({
|
|
9
10
|
type: 'SET_EXPAND_REF',
|
|
10
11
|
data: {
|
|
@@ -102,7 +103,7 @@ export const insertExpand = (state, dispatch) => {
|
|
|
102
103
|
if (!expandNode) {
|
|
103
104
|
return false;
|
|
104
105
|
}
|
|
105
|
-
const tr = createWrapSelectionTransaction({
|
|
106
|
+
const tr = state.selection.empty ? safeInsert(expandNode)(state.tr).scrollIntoView() : createWrapSelectionTransaction({
|
|
106
107
|
state,
|
|
107
108
|
type: expandNode.type
|
|
108
109
|
});
|
|
@@ -26,6 +26,7 @@ import { MediaTaskManager } from './mediaTaskManager';
|
|
|
26
26
|
import { CellSelection } from '@atlaskit/editor-tables/cell-selection';
|
|
27
27
|
export { stateKey } from './plugin-key';
|
|
28
28
|
export const MEDIA_CONTENT_WRAP_CLASS_NAME = 'media-content-wrap';
|
|
29
|
+
export const MEDIA_PLUGIN_IS_RESIZING_KEY = 'mediaSinglePlugin.isResizing';
|
|
29
30
|
const createDropPlaceholder = (intl, allowDropLine) => {
|
|
30
31
|
const dropPlaceholder = document.createElement('div');
|
|
31
32
|
const createElement = React.createElement;
|
|
@@ -54,6 +55,7 @@ export class MediaPluginStateImplementation {
|
|
|
54
55
|
_defineProperty(this, "isFullscreen", false);
|
|
55
56
|
_defineProperty(this, "layout", 'center');
|
|
56
57
|
_defineProperty(this, "mediaNodes", []);
|
|
58
|
+
_defineProperty(this, "isResizing", false);
|
|
57
59
|
_defineProperty(this, "destroyed", false);
|
|
58
60
|
_defineProperty(this, "removeOnCloseListener", () => {});
|
|
59
61
|
_defineProperty(this, "onPopupToggleCallback", () => {});
|
|
@@ -419,6 +421,9 @@ export class MediaPluginStateImplementation {
|
|
|
419
421
|
options.providerFactory.subscribe('contextIdentifierProvider', this.onContextIdentifierProvider);
|
|
420
422
|
this.errorReporter = options.errorReporter || new ErrorReporter();
|
|
421
423
|
}
|
|
424
|
+
setIsResizing(isResizing) {
|
|
425
|
+
this.isResizing = isResizing;
|
|
426
|
+
}
|
|
422
427
|
updateElement() {
|
|
423
428
|
let newElement;
|
|
424
429
|
const selectedContainer = this.selectedMediaContainerNode();
|
|
@@ -520,6 +525,11 @@ export const createPlugin = (_schema, options, reactContext, getIntl, dispatch,
|
|
|
520
525
|
return new MediaPluginStateImplementation(state, options, mediaOptions, newInsertionBehaviour, dispatch, pluginInjectionApi);
|
|
521
526
|
},
|
|
522
527
|
apply(tr, pluginState) {
|
|
528
|
+
const isResizing = tr.getMeta(MEDIA_PLUGIN_IS_RESIZING_KEY);
|
|
529
|
+
if (isResizing !== undefined) {
|
|
530
|
+
pluginState.setIsResizing(isResizing);
|
|
531
|
+
}
|
|
532
|
+
|
|
523
533
|
// remap editing media single position if we're in collab
|
|
524
534
|
if (typeof pluginState.editingMediaSinglePos === 'number') {
|
|
525
535
|
pluginState.editingMediaSinglePos = tr.mapping.map(pluginState.editingMediaSinglePos);
|
|
@@ -5,10 +5,9 @@ import React from 'react';
|
|
|
5
5
|
import { jsx } from '@emotion/react';
|
|
6
6
|
import { findParentNodeOfTypeClosestToPos, hasParentNodeOfType } from 'prosemirror-utils';
|
|
7
7
|
import { getMediaClient } from '@atlaskit/media-client';
|
|
8
|
-
import { calcPctFromPx, calcColumnsFromPx, wrappedLayouts } from '@atlaskit/editor-common/ui';
|
|
8
|
+
import { calcPctFromPx, calcColumnsFromPx, wrappedLayouts, Resizer, calcMediaPxWidth, snapTo, handleSides, imageAlignmentMap } from '@atlaskit/editor-common/ui';
|
|
9
9
|
import { akEditorWideLayoutWidth } from '@atlaskit/editor-shared-styles';
|
|
10
10
|
import { wrapperStyle } from './styled';
|
|
11
|
-
import { Resizer, calcMediaPxWidth, snapTo, handleSides, imageAlignmentMap } from '@atlaskit/editor-common/ui';
|
|
12
11
|
import { calculateSnapPoints } from '@atlaskit/editor-common/utils';
|
|
13
12
|
export default class ResizableMediaSingle extends React.Component {
|
|
14
13
|
constructor(...args) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { css } from '@emotion/react';
|
|
2
2
|
import { N30 } from '@atlaskit/theme/colors';
|
|
3
|
-
import {
|
|
3
|
+
import { akEditorFloatingDialogZIndex, akEditorSwoopCubicBezier, akEditorToolbarKeylineHeight, akEditorMobileMaxWidth } from '@atlaskit/editor-shared-styles';
|
|
4
4
|
export const MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT = 868;
|
|
5
5
|
const toolbarLineHeight = 56;
|
|
6
6
|
|
|
@@ -20,7 +20,7 @@ const mainToolbar = css`
|
|
|
20
20
|
align-items: center;
|
|
21
21
|
box-shadow: none;
|
|
22
22
|
transition: box-shadow 200ms ${akEditorSwoopCubicBezier};
|
|
23
|
-
z-index: ${
|
|
23
|
+
z-index: ${akEditorFloatingDialogZIndex};
|
|
24
24
|
display: flex;
|
|
25
25
|
height: ${toolbarLineHeight}px;
|
|
26
26
|
flex-shrink: 0;
|
package/dist/es2019/version.json
CHANGED
|
@@ -8,6 +8,7 @@ import { GapCursorSelection, Side } from '../selection/gap-cursor-selection';
|
|
|
8
8
|
import { findExpand } from './utils';
|
|
9
9
|
import { createCommand } from './pm-plugins/plugin-factory';
|
|
10
10
|
import { createWrapSelectionTransaction } from '../block-type/commands/block-type';
|
|
11
|
+
import { safeInsert } from 'prosemirror-utils';
|
|
11
12
|
export var setExpandRef = function setExpandRef(ref) {
|
|
12
13
|
return createCommand({
|
|
13
14
|
type: 'SET_EXPAND_REF',
|
|
@@ -110,7 +111,7 @@ export var insertExpand = function insertExpand(state, dispatch) {
|
|
|
110
111
|
if (!expandNode) {
|
|
111
112
|
return false;
|
|
112
113
|
}
|
|
113
|
-
var tr = createWrapSelectionTransaction({
|
|
114
|
+
var tr = state.selection.empty ? safeInsert(expandNode)(state.tr).scrollIntoView() : createWrapSelectionTransaction({
|
|
114
115
|
state: state,
|
|
115
116
|
type: expandNode.type
|
|
116
117
|
});
|
|
@@ -35,6 +35,7 @@ import { MediaTaskManager } from './mediaTaskManager';
|
|
|
35
35
|
import { CellSelection } from '@atlaskit/editor-tables/cell-selection';
|
|
36
36
|
export { stateKey } from './plugin-key';
|
|
37
37
|
export var MEDIA_CONTENT_WRAP_CLASS_NAME = 'media-content-wrap';
|
|
38
|
+
export var MEDIA_PLUGIN_IS_RESIZING_KEY = 'mediaSinglePlugin.isResizing';
|
|
38
39
|
var createDropPlaceholder = function createDropPlaceholder(intl, allowDropLine) {
|
|
39
40
|
var dropPlaceholder = document.createElement('div');
|
|
40
41
|
var createElement = React.createElement;
|
|
@@ -66,6 +67,7 @@ export var MediaPluginStateImplementation = /*#__PURE__*/function () {
|
|
|
66
67
|
_defineProperty(this, "isFullscreen", false);
|
|
67
68
|
_defineProperty(this, "layout", 'center');
|
|
68
69
|
_defineProperty(this, "mediaNodes", []);
|
|
70
|
+
_defineProperty(this, "isResizing", false);
|
|
69
71
|
_defineProperty(this, "destroyed", false);
|
|
70
72
|
_defineProperty(this, "removeOnCloseListener", function () {});
|
|
71
73
|
_defineProperty(this, "onPopupToggleCallback", function () {});
|
|
@@ -476,6 +478,11 @@ export var MediaPluginStateImplementation = /*#__PURE__*/function () {
|
|
|
476
478
|
this.errorReporter = options.errorReporter || new ErrorReporter();
|
|
477
479
|
}
|
|
478
480
|
_createClass(MediaPluginStateImplementation, [{
|
|
481
|
+
key: "setIsResizing",
|
|
482
|
+
value: function setIsResizing(isResizing) {
|
|
483
|
+
this.isResizing = isResizing;
|
|
484
|
+
}
|
|
485
|
+
}, {
|
|
479
486
|
key: "updateElement",
|
|
480
487
|
value: function updateElement() {
|
|
481
488
|
var newElement;
|
|
@@ -615,6 +622,11 @@ export var createPlugin = function createPlugin(_schema, options, reactContext,
|
|
|
615
622
|
return new MediaPluginStateImplementation(state, options, mediaOptions, newInsertionBehaviour, dispatch, pluginInjectionApi);
|
|
616
623
|
},
|
|
617
624
|
apply: function apply(tr, pluginState) {
|
|
625
|
+
var isResizing = tr.getMeta(MEDIA_PLUGIN_IS_RESIZING_KEY);
|
|
626
|
+
if (isResizing !== undefined) {
|
|
627
|
+
pluginState.setIsResizing(isResizing);
|
|
628
|
+
}
|
|
629
|
+
|
|
618
630
|
// remap editing media single position if we're in collab
|
|
619
631
|
if (typeof pluginState.editingMediaSinglePos === 'number') {
|
|
620
632
|
pluginState.editingMediaSinglePos = tr.mapping.map(pluginState.editingMediaSinglePos);
|
|
@@ -15,10 +15,9 @@ import React from 'react';
|
|
|
15
15
|
import { jsx } from '@emotion/react';
|
|
16
16
|
import { findParentNodeOfTypeClosestToPos, hasParentNodeOfType } from 'prosemirror-utils';
|
|
17
17
|
import { getMediaClient } from '@atlaskit/media-client';
|
|
18
|
-
import { calcPctFromPx, calcColumnsFromPx, wrappedLayouts } from '@atlaskit/editor-common/ui';
|
|
18
|
+
import { calcPctFromPx, calcColumnsFromPx, wrappedLayouts, Resizer, calcMediaPxWidth, snapTo, handleSides, imageAlignmentMap } from '@atlaskit/editor-common/ui';
|
|
19
19
|
import { akEditorWideLayoutWidth } from '@atlaskit/editor-shared-styles';
|
|
20
20
|
import { wrapperStyle } from './styled';
|
|
21
|
-
import { Resizer, calcMediaPxWidth, snapTo, handleSides, imageAlignmentMap } from '@atlaskit/editor-common/ui';
|
|
22
21
|
import { calculateSnapPoints } from '@atlaskit/editor-common/utils';
|
|
23
22
|
var ResizableMediaSingle = /*#__PURE__*/function (_React$Component) {
|
|
24
23
|
_inherits(ResizableMediaSingle, _React$Component);
|
|
@@ -2,14 +2,14 @@ import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral
|
|
|
2
2
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10;
|
|
3
3
|
import { css } from '@emotion/react';
|
|
4
4
|
import { N30 } from '@atlaskit/theme/colors';
|
|
5
|
-
import {
|
|
5
|
+
import { akEditorFloatingDialogZIndex, akEditorSwoopCubicBezier, akEditorToolbarKeylineHeight, akEditorMobileMaxWidth } from '@atlaskit/editor-shared-styles';
|
|
6
6
|
export var MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT = 868;
|
|
7
7
|
var toolbarLineHeight = 56;
|
|
8
8
|
|
|
9
9
|
// box-shadow is overriden by the mainToolbar
|
|
10
10
|
var mainToolbarWithKeyline = css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n box-shadow: 0 ", "px 0 0\n ", ";\n"])), akEditorToolbarKeylineHeight, "var(--ds-border, ".concat(N30, ")"));
|
|
11
11
|
var mainToolbarTwoLineStyle = css(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n @media (max-width: ", "px) {\n flex-wrap: wrap;\n height: calc(", "px * 2);\n }\n"])), MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT, toolbarLineHeight);
|
|
12
|
-
var mainToolbar = css(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n position: relative;\n align-items: center;\n box-shadow: none;\n transition: box-shadow 200ms ", ";\n z-index: ", ";\n display: flex;\n height: ", "px;\n flex-shrink: 0;\n // TODO: https://product-fabric.atlassian.net/browse/DSP-4456\n background-color: ", ";\n\n & object {\n height: 0 !important;\n }\n\n @media (max-width: ", "px) {\n display: grid;\n height: calc(", "px * 2);\n }\n"])), akEditorSwoopCubicBezier,
|
|
12
|
+
var mainToolbar = css(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n position: relative;\n align-items: center;\n box-shadow: none;\n transition: box-shadow 200ms ", ";\n z-index: ", ";\n display: flex;\n height: ", "px;\n flex-shrink: 0;\n // TODO: https://product-fabric.atlassian.net/browse/DSP-4456\n background-color: ", ";\n\n & object {\n height: 0 !important;\n }\n\n @media (max-width: ", "px) {\n display: grid;\n height: calc(", "px * 2);\n }\n"])), akEditorSwoopCubicBezier, akEditorFloatingDialogZIndex, toolbarLineHeight, "var(--ds-surface, white)", akEditorMobileMaxWidth, toolbarLineHeight);
|
|
13
13
|
export var mainToolbarStyle = function mainToolbarStyle(showKeyline, twoLineEditorToolbar) {
|
|
14
14
|
return [mainToolbar, showKeyline && mainToolbarWithKeyline, twoLineEditorToolbar && mainToolbarTwoLineStyle];
|
|
15
15
|
};
|
package/dist/esm/version.json
CHANGED
|
@@ -19,6 +19,7 @@ import type mediaPlugin from '../index';
|
|
|
19
19
|
export type { MediaState, MediaProvider, MediaStateStatus };
|
|
20
20
|
export { stateKey } from './plugin-key';
|
|
21
21
|
export declare const MEDIA_CONTENT_WRAP_CLASS_NAME = "media-content-wrap";
|
|
22
|
+
export declare const MEDIA_PLUGIN_IS_RESIZING_KEY = "mediaSinglePlugin.isResizing";
|
|
22
23
|
export declare class MediaPluginStateImplementation implements MediaPluginState {
|
|
23
24
|
allowsUploads: boolean;
|
|
24
25
|
mediaClientConfig?: MediaClientConfig;
|
|
@@ -34,6 +35,7 @@ export declare class MediaPluginStateImplementation implements MediaPluginState
|
|
|
34
35
|
options: MediaPluginOptions;
|
|
35
36
|
mediaProvider?: MediaProvider;
|
|
36
37
|
newInsertionBehaviour?: boolean;
|
|
38
|
+
isResizing: boolean;
|
|
37
39
|
private view;
|
|
38
40
|
private destroyed;
|
|
39
41
|
private contextIdentifierProvider?;
|
|
@@ -55,6 +57,7 @@ export declare class MediaPluginStateImplementation implements MediaPluginState
|
|
|
55
57
|
onContextIdentifierProvider: (_name: string, provider?: Promise<ContextIdentifierProvider>) => Promise<void>;
|
|
56
58
|
setMediaProvider: (mediaProvider?: Promise<MediaProvider>) => Promise<void>;
|
|
57
59
|
getMediaOptions: () => MediaPluginOptions;
|
|
60
|
+
setIsResizing(isResizing: boolean): void;
|
|
58
61
|
updateElement(): void;
|
|
59
62
|
private isMediaSchemaNode;
|
|
60
63
|
private getDomElement;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { Node as PMNode } from 'prosemirror-model';
|
|
2
|
-
import { MediaClientConfig } from '@atlaskit/media-core';
|
|
3
|
-
import { RichMediaLayout as MediaSingleLayout } from '@atlaskit/adf-schema';
|
|
4
|
-
import type { ContextIdentifierProvider } from '@atlaskit/editor-common/provider-factory';
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import PickerFacade
|
|
10
|
-
import { Dispatch } from '../../../event-dispatcher';
|
|
11
|
-
import { ProsemirrorGetPosHandler } from '../../../nodeviews/types';
|
|
1
|
+
import type { Node as PMNode } from 'prosemirror-model';
|
|
2
|
+
import type { MediaClientConfig } from '@atlaskit/media-core';
|
|
3
|
+
import type { RichMediaLayout as MediaSingleLayout } from '@atlaskit/adf-schema';
|
|
4
|
+
import type { ContextIdentifierProvider, MediaProvider } from '@atlaskit/editor-common/provider-factory';
|
|
5
|
+
import type { MediaOptions, MediaState } from '../types';
|
|
6
|
+
import type { MediaPluginOptions } from '../media-plugin-options';
|
|
7
|
+
import type { EditorView } from 'prosemirror-view';
|
|
8
|
+
import type { MediaStateEventSubscriber } from '../picker-facade';
|
|
9
|
+
import type PickerFacade from '../picker-facade';
|
|
10
|
+
import type { Dispatch } from '../../../event-dispatcher';
|
|
11
|
+
import type { ProsemirrorGetPosHandler } from '../../../nodeviews/types';
|
|
12
12
|
export interface MediaNodeWithPosHandler {
|
|
13
13
|
node: PMNode;
|
|
14
14
|
getPos: ProsemirrorGetPosHandler;
|
|
@@ -32,6 +32,7 @@ export interface MediaPluginState {
|
|
|
32
32
|
editingMediaSinglePos?: number;
|
|
33
33
|
showEditingDialog?: boolean;
|
|
34
34
|
mediaOptions?: MediaOptions;
|
|
35
|
+
isResizing: boolean;
|
|
35
36
|
dispatch?: Dispatch;
|
|
36
37
|
onContextIdentifierProvider: (_name: string, provider?: Promise<ContextIdentifierProvider>) => Promise<void>;
|
|
37
38
|
setMediaProvider: (mediaProvider?: Promise<MediaProvider>) => Promise<void>;
|
|
@@ -54,6 +55,7 @@ export interface MediaPluginState {
|
|
|
54
55
|
selectedMediaContainerNode: () => PMNode | undefined;
|
|
55
56
|
handleDrag: (dragState: 'enter' | 'leave') => void;
|
|
56
57
|
updateElement(): void;
|
|
58
|
+
setIsResizing(isResizing: boolean): void;
|
|
57
59
|
setView(view: EditorView): void;
|
|
58
60
|
destroy(): void;
|
|
59
61
|
updateAndDispatch(props: Partial<Pick<this, 'allowsUploads' | 'allUploadsFinished' | 'isFullscreen'>>): void;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { EditorState } from 'prosemirror-state';
|
|
2
|
-
import { IntlShape } from 'react-intl-next';
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
1
|
+
import type { EditorState } from 'prosemirror-state';
|
|
2
|
+
import type { IntlShape } from 'react-intl-next';
|
|
3
|
+
import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
|
|
4
|
+
import type { FloatingToolbarConfig } from '../../../plugins/floating-toolbar/types';
|
|
5
|
+
import type { MediaFloatingToolbarOptions } from '../types';
|
|
5
6
|
import type mediaPlugin from '../index';
|
|
6
|
-
import { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
|
|
7
7
|
export declare const floatingToolbar: (state: EditorState, intl: IntlShape, options: MediaFloatingToolbarOptions | undefined, pluginInjectionApi: ExtractInjectionAPI<typeof mediaPlugin> | undefined) => FloatingToolbarConfig | undefined;
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
/** @jsx jsx */
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { jsx } from '@emotion/react';
|
|
5
|
-
import { RichMediaLayout as MediaSingleLayout } from '@atlaskit/adf-schema';
|
|
6
|
-
import { MediaClientConfig } from '@atlaskit/media-core';
|
|
7
|
-
import { Props } from './types';
|
|
5
|
+
import type { RichMediaLayout as MediaSingleLayout } from '@atlaskit/adf-schema';
|
|
6
|
+
import type { MediaClientConfig } from '@atlaskit/media-core';
|
|
7
|
+
import type { Props } from './types';
|
|
8
8
|
type State = {
|
|
9
9
|
offsetLeft: number;
|
|
10
10
|
isVideoFile: boolean;
|
|
@@ -19,6 +19,7 @@ import type mediaPlugin from '../index';
|
|
|
19
19
|
export type { MediaState, MediaProvider, MediaStateStatus };
|
|
20
20
|
export { stateKey } from './plugin-key';
|
|
21
21
|
export declare const MEDIA_CONTENT_WRAP_CLASS_NAME = "media-content-wrap";
|
|
22
|
+
export declare const MEDIA_PLUGIN_IS_RESIZING_KEY = "mediaSinglePlugin.isResizing";
|
|
22
23
|
export declare class MediaPluginStateImplementation implements MediaPluginState {
|
|
23
24
|
allowsUploads: boolean;
|
|
24
25
|
mediaClientConfig?: MediaClientConfig;
|
|
@@ -34,6 +35,7 @@ export declare class MediaPluginStateImplementation implements MediaPluginState
|
|
|
34
35
|
options: MediaPluginOptions;
|
|
35
36
|
mediaProvider?: MediaProvider;
|
|
36
37
|
newInsertionBehaviour?: boolean;
|
|
38
|
+
isResizing: boolean;
|
|
37
39
|
private view;
|
|
38
40
|
private destroyed;
|
|
39
41
|
private contextIdentifierProvider?;
|
|
@@ -55,6 +57,7 @@ export declare class MediaPluginStateImplementation implements MediaPluginState
|
|
|
55
57
|
onContextIdentifierProvider: (_name: string, provider?: Promise<ContextIdentifierProvider>) => Promise<void>;
|
|
56
58
|
setMediaProvider: (mediaProvider?: Promise<MediaProvider>) => Promise<void>;
|
|
57
59
|
getMediaOptions: () => MediaPluginOptions;
|
|
60
|
+
setIsResizing(isResizing: boolean): void;
|
|
58
61
|
updateElement(): void;
|
|
59
62
|
private isMediaSchemaNode;
|
|
60
63
|
private getDomElement;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { Node as PMNode } from 'prosemirror-model';
|
|
2
|
-
import { MediaClientConfig } from '@atlaskit/media-core';
|
|
3
|
-
import { RichMediaLayout as MediaSingleLayout } from '@atlaskit/adf-schema';
|
|
4
|
-
import type { ContextIdentifierProvider } from '@atlaskit/editor-common/provider-factory';
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import PickerFacade
|
|
10
|
-
import { Dispatch } from '../../../event-dispatcher';
|
|
11
|
-
import { ProsemirrorGetPosHandler } from '../../../nodeviews/types';
|
|
1
|
+
import type { Node as PMNode } from 'prosemirror-model';
|
|
2
|
+
import type { MediaClientConfig } from '@atlaskit/media-core';
|
|
3
|
+
import type { RichMediaLayout as MediaSingleLayout } from '@atlaskit/adf-schema';
|
|
4
|
+
import type { ContextIdentifierProvider, MediaProvider } from '@atlaskit/editor-common/provider-factory';
|
|
5
|
+
import type { MediaOptions, MediaState } from '../types';
|
|
6
|
+
import type { MediaPluginOptions } from '../media-plugin-options';
|
|
7
|
+
import type { EditorView } from 'prosemirror-view';
|
|
8
|
+
import type { MediaStateEventSubscriber } from '../picker-facade';
|
|
9
|
+
import type PickerFacade from '../picker-facade';
|
|
10
|
+
import type { Dispatch } from '../../../event-dispatcher';
|
|
11
|
+
import type { ProsemirrorGetPosHandler } from '../../../nodeviews/types';
|
|
12
12
|
export interface MediaNodeWithPosHandler {
|
|
13
13
|
node: PMNode;
|
|
14
14
|
getPos: ProsemirrorGetPosHandler;
|
|
@@ -32,6 +32,7 @@ export interface MediaPluginState {
|
|
|
32
32
|
editingMediaSinglePos?: number;
|
|
33
33
|
showEditingDialog?: boolean;
|
|
34
34
|
mediaOptions?: MediaOptions;
|
|
35
|
+
isResizing: boolean;
|
|
35
36
|
dispatch?: Dispatch;
|
|
36
37
|
onContextIdentifierProvider: (_name: string, provider?: Promise<ContextIdentifierProvider>) => Promise<void>;
|
|
37
38
|
setMediaProvider: (mediaProvider?: Promise<MediaProvider>) => Promise<void>;
|
|
@@ -54,6 +55,7 @@ export interface MediaPluginState {
|
|
|
54
55
|
selectedMediaContainerNode: () => PMNode | undefined;
|
|
55
56
|
handleDrag: (dragState: 'enter' | 'leave') => void;
|
|
56
57
|
updateElement(): void;
|
|
58
|
+
setIsResizing(isResizing: boolean): void;
|
|
57
59
|
setView(view: EditorView): void;
|
|
58
60
|
destroy(): void;
|
|
59
61
|
updateAndDispatch(props: Partial<Pick<this, 'allowsUploads' | 'allUploadsFinished' | 'isFullscreen'>>): void;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { EditorState } from 'prosemirror-state';
|
|
2
|
-
import { IntlShape } from 'react-intl-next';
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
1
|
+
import type { EditorState } from 'prosemirror-state';
|
|
2
|
+
import type { IntlShape } from 'react-intl-next';
|
|
3
|
+
import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
|
|
4
|
+
import type { FloatingToolbarConfig } from '../../../plugins/floating-toolbar/types';
|
|
5
|
+
import type { MediaFloatingToolbarOptions } from '../types';
|
|
5
6
|
import type mediaPlugin from '../index';
|
|
6
|
-
import { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
|
|
7
7
|
export declare const floatingToolbar: (state: EditorState, intl: IntlShape, options: MediaFloatingToolbarOptions | undefined, pluginInjectionApi: ExtractInjectionAPI<typeof mediaPlugin> | undefined) => FloatingToolbarConfig | undefined;
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
/** @jsx jsx */
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { jsx } from '@emotion/react';
|
|
5
|
-
import { RichMediaLayout as MediaSingleLayout } from '@atlaskit/adf-schema';
|
|
6
|
-
import { MediaClientConfig } from '@atlaskit/media-core';
|
|
7
|
-
import { Props } from './types';
|
|
5
|
+
import type { RichMediaLayout as MediaSingleLayout } from '@atlaskit/adf-schema';
|
|
6
|
+
import type { MediaClientConfig } from '@atlaskit/media-core';
|
|
7
|
+
import type { Props } from './types';
|
|
8
8
|
type State = {
|
|
9
9
|
offsetLeft: number;
|
|
10
10
|
isVideoFile: boolean;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-core",
|
|
3
|
-
"version": "187.
|
|
3
|
+
"version": "187.7.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.7.0",
|
|
58
|
-
"@atlaskit/editor-common": "^74.
|
|
58
|
+
"@atlaskit/editor-common": "^74.29.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",
|
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
"@atlaskit/editor-plugin-grid": "^0.1.0",
|
|
70
70
|
"@atlaskit/editor-plugin-guideline": "^0.3.4",
|
|
71
71
|
"@atlaskit/editor-plugin-hyperlink": "^0.2.0",
|
|
72
|
-
"@atlaskit/editor-plugin-table": "^2.
|
|
72
|
+
"@atlaskit/editor-plugin-table": "^2.6.0",
|
|
73
73
|
"@atlaskit/editor-plugin-width": "^0.1.0",
|
|
74
74
|
"@atlaskit/editor-shared-styles": "^2.5.0",
|
|
75
75
|
"@atlaskit/editor-tables": "^2.3.0",
|
|
@@ -95,7 +95,7 @@
|
|
|
95
95
|
"@atlaskit/radio": "^5.6.0",
|
|
96
96
|
"@atlaskit/section-message": "^6.4.0",
|
|
97
97
|
"@atlaskit/select": "^16.5.0",
|
|
98
|
-
"@atlaskit/smart-card": "^26.
|
|
98
|
+
"@atlaskit/smart-card": "^26.12.0",
|
|
99
99
|
"@atlaskit/smart-user-picker": "^6.1.0",
|
|
100
100
|
"@atlaskit/spinner": "^15.5.0",
|
|
101
101
|
"@atlaskit/status": "^1.3.0",
|
|
@@ -149,14 +149,14 @@
|
|
|
149
149
|
"@atlaskit/collab-provider": "9.7.3",
|
|
150
150
|
"@atlaskit/dropdown-menu": "^11.11.0",
|
|
151
151
|
"@atlaskit/editor-extension-dropbox": "^0.4.0",
|
|
152
|
-
"@atlaskit/editor-plugin-table": "^2.
|
|
152
|
+
"@atlaskit/editor-plugin-table": "^2.6.0",
|
|
153
153
|
"@atlaskit/editor-test-helpers": "^18.10.0",
|
|
154
154
|
"@atlaskit/flag": "^15.2.0",
|
|
155
155
|
"@atlaskit/icon-object": "^6.3.0",
|
|
156
156
|
"@atlaskit/inline-dialog": "^13.6.0",
|
|
157
157
|
"@atlaskit/link-analytics": "^8.2.0",
|
|
158
158
|
"@atlaskit/link-provider": "^1.6.0",
|
|
159
|
-
"@atlaskit/link-test-helpers": "^
|
|
159
|
+
"@atlaskit/link-test-helpers": "^6.0.0",
|
|
160
160
|
"@atlaskit/media-core": "^34.1.0",
|
|
161
161
|
"@atlaskit/media-integration-test-helpers": "^3.0.0",
|
|
162
162
|
"@atlaskit/media-test-helpers": "^33.0.0",
|
package/report.api.md
CHANGED
|
@@ -104,7 +104,7 @@ import { MediaClientConfig } from '@atlaskit/media-core';
|
|
|
104
104
|
import { MediaFeatureFlags } from '@atlaskit/media-common';
|
|
105
105
|
import { MediaFeatureFlags as MediaFeatureFlags_2 } from '@atlaskit/media-common/mediaFeatureFlags';
|
|
106
106
|
import { MediaFile } from '@atlaskit/media-picker/types';
|
|
107
|
-
import { MediaProvider as MediaProvider_2 } from '@atlaskit/editor-common/provider-factory';
|
|
107
|
+
import type { MediaProvider as MediaProvider_2 } from '@atlaskit/editor-common/provider-factory';
|
|
108
108
|
import type { MentionDescription } from '@atlaskit/mention';
|
|
109
109
|
import { MentionProvider } from '@atlaskit/mention/resource';
|
|
110
110
|
import type { MentionProvider as MentionProvider_2 } from '@atlaskit/mention';
|
|
@@ -142,7 +142,7 @@ import type { ReactHookFactory } from '@atlaskit/editor-common/types';
|
|
|
142
142
|
import type { RefObject } from 'react';
|
|
143
143
|
import { ReplaceRawValue } from '@atlaskit/editor-common/types';
|
|
144
144
|
import type { ResolvedEditorState } from '@atlaskit/collab-provider';
|
|
145
|
-
import { RichMediaLayout } from '@atlaskit/adf-schema';
|
|
145
|
+
import type { RichMediaLayout } from '@atlaskit/adf-schema';
|
|
146
146
|
import type { Schema } from 'prosemirror-model';
|
|
147
147
|
import type { SearchProvider } from '@atlaskit/editor-common/provider-factory';
|
|
148
148
|
import { SelectItemMode } from '@atlaskit/editor-common/type-ahead';
|
|
@@ -1496,6 +1496,8 @@ interface MediaPluginState {
|
|
|
1496
1496
|
// (undocumented)
|
|
1497
1497
|
isFullscreen: boolean;
|
|
1498
1498
|
// (undocumented)
|
|
1499
|
+
isResizing: boolean;
|
|
1500
|
+
// (undocumented)
|
|
1499
1501
|
layout: RichMediaLayout;
|
|
1500
1502
|
// (undocumented)
|
|
1501
1503
|
mediaClientConfig?: MediaClientConfig;
|
|
@@ -1527,6 +1529,8 @@ interface MediaPluginState {
|
|
|
1527
1529
|
// (undocumented)
|
|
1528
1530
|
setBrowseFn: (browseFn: () => void) => void;
|
|
1529
1531
|
// (undocumented)
|
|
1532
|
+
setIsResizing(isResizing: boolean): void;
|
|
1533
|
+
// (undocumented)
|
|
1530
1534
|
setMediaProvider: (mediaProvider?: Promise<MediaProvider_2>) => Promise<void>;
|
|
1531
1535
|
// (undocumented)
|
|
1532
1536
|
setView(view: EditorView): void;
|
package/tmp/api-report-tmp.d.ts
CHANGED
|
@@ -93,7 +93,7 @@ import { MediaClientConfig } from '@atlaskit/media-core';
|
|
|
93
93
|
import { MediaFeatureFlags } from '@atlaskit/media-common';
|
|
94
94
|
import { MediaFeatureFlags as MediaFeatureFlags_2 } from '@atlaskit/media-common/mediaFeatureFlags';
|
|
95
95
|
import { MediaFile } from '@atlaskit/media-picker/types';
|
|
96
|
-
import { MediaProvider as MediaProvider_2 } from '@atlaskit/editor-common/provider-factory';
|
|
96
|
+
import type { MediaProvider as MediaProvider_2 } from '@atlaskit/editor-common/provider-factory';
|
|
97
97
|
import type { MentionDescription } from '@atlaskit/mention';
|
|
98
98
|
import { MentionProvider } from '@atlaskit/mention/resource';
|
|
99
99
|
import type { MentionProvider as MentionProvider_2 } from '@atlaskit/mention';
|
|
@@ -131,7 +131,7 @@ import type { ReactHookFactory } from '@atlaskit/editor-common/types';
|
|
|
131
131
|
import type { RefObject } from 'react';
|
|
132
132
|
import { ReplaceRawValue } from '@atlaskit/editor-common/types';
|
|
133
133
|
import type { ResolvedEditorState } from '@atlaskit/collab-provider';
|
|
134
|
-
import { RichMediaLayout } from '@atlaskit/adf-schema';
|
|
134
|
+
import type { RichMediaLayout } from '@atlaskit/adf-schema';
|
|
135
135
|
import type { Schema } from 'prosemirror-model';
|
|
136
136
|
import type { SearchProvider } from '@atlaskit/editor-common/provider-factory';
|
|
137
137
|
import { SelectItemMode } from '@atlaskit/editor-common/type-ahead';
|
|
@@ -1347,6 +1347,8 @@ interface MediaPluginState {
|
|
|
1347
1347
|
// (undocumented)
|
|
1348
1348
|
isFullscreen: boolean;
|
|
1349
1349
|
// (undocumented)
|
|
1350
|
+
isResizing: boolean;
|
|
1351
|
+
// (undocumented)
|
|
1350
1352
|
layout: RichMediaLayout;
|
|
1351
1353
|
// (undocumented)
|
|
1352
1354
|
mediaClientConfig?: MediaClientConfig;
|
|
@@ -1375,6 +1377,8 @@ interface MediaPluginState {
|
|
|
1375
1377
|
// (undocumented)
|
|
1376
1378
|
setBrowseFn: (browseFn: () => void) => void;
|
|
1377
1379
|
// (undocumented)
|
|
1380
|
+
setIsResizing(isResizing: boolean): void;
|
|
1381
|
+
// (undocumented)
|
|
1378
1382
|
setMediaProvider: (mediaProvider?: Promise<MediaProvider_2>) => Promise<void>;
|
|
1379
1383
|
// (undocumented)
|
|
1380
1384
|
setView(view: EditorView): void;
|