@atlaskit/editor-plugin-media 3.0.14 → 3.1.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 +18 -0
- package/dist/cjs/nodeviews/toDOM-fixes/mediaSingle.js +5 -2
- package/dist/cjs/pm-plugins/alt-text/ui/AltTextEdit.js +3 -2
- package/dist/cjs/ui/ImageBorder/index.js +5 -4
- package/dist/cjs/ui/MediaLinkingToolbar.js +3 -2
- package/dist/cjs/ui/toolbar/index.js +1 -1
- package/dist/es2019/nodeviews/toDOM-fixes/mediaSingle.js +5 -1
- package/dist/es2019/pm-plugins/alt-text/ui/AltTextEdit.js +3 -2
- package/dist/es2019/ui/ImageBorder/index.js +3 -2
- package/dist/es2019/ui/MediaLinkingToolbar.js +3 -2
- package/dist/es2019/ui/toolbar/index.js +1 -1
- package/dist/esm/nodeviews/toDOM-fixes/mediaSingle.js +5 -2
- package/dist/esm/pm-plugins/alt-text/ui/AltTextEdit.js +3 -2
- package/dist/esm/ui/ImageBorder/index.js +3 -2
- package/dist/esm/ui/MediaLinkingToolbar.js +3 -2
- package/dist/esm/ui/toolbar/index.js +1 -1
- package/dist/types/nodeviews/mediaNodeView/index.d.ts +1 -1
- package/dist/types/ui/toolbar/utils.d.ts +1 -1
- package/dist/types-ts4.5/nodeviews/mediaNodeView/index.d.ts +1 -1
- package/dist/types-ts4.5/ui/toolbar/utils.d.ts +1 -1
- package/package.json +6 -9
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-media
|
|
2
2
|
|
|
3
|
+
## 3.1.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#170742](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/170742)
|
|
8
|
+
[`9c026e8d50959`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/9c026e8d50959) -
|
|
9
|
+
Add data-media-vc-wrapper attribute to Editor MediaCardWrapper component
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- Updated dependencies
|
|
14
|
+
|
|
15
|
+
## 3.0.15
|
|
16
|
+
|
|
17
|
+
### Patch Changes
|
|
18
|
+
|
|
19
|
+
- Updated dependencies
|
|
20
|
+
|
|
3
21
|
## 3.0.14
|
|
4
22
|
|
|
5
23
|
### Patch Changes
|
|
@@ -9,6 +9,7 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
|
|
|
9
9
|
var _adfSchema = require("@atlaskit/adf-schema");
|
|
10
10
|
var _lazyNodeView = require("@atlaskit/editor-common/lazy-node-view");
|
|
11
11
|
var _colors = require("@atlaskit/theme/colors");
|
|
12
|
+
var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
|
|
12
13
|
var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
|
|
13
14
|
var _toDOMAttrs = require("./toDOMAttrs");
|
|
14
15
|
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; }
|
|
@@ -190,7 +191,7 @@ var getToDom = exports.getToDom = function getToDom(allowPixelResizing) {
|
|
|
190
191
|
childMediaWidth: childMediaWidth,
|
|
191
192
|
mediaSingleDimensionWidth: mediaSingleAttrs === null || mediaSingleAttrs === void 0 ? void 0 : mediaSingleAttrs.width
|
|
192
193
|
});
|
|
193
|
-
return ['div', {
|
|
194
|
+
return ['div', _objectSpread({
|
|
194
195
|
class: 'mediaSingleView-content-wrap',
|
|
195
196
|
layout: layout,
|
|
196
197
|
style: (0, _lazyNodeView.convertToInlineCss)({
|
|
@@ -205,7 +206,9 @@ var getToDom = exports.getToDom = function getToDom(allowPixelResizing) {
|
|
|
205
206
|
marginLeft: isMediaWrapped ? layout === 'wrap-left' ? 'auto' : HALF_GUTTER_SIZE : 0,
|
|
206
207
|
width: contentWrapperWidth
|
|
207
208
|
})
|
|
208
|
-
},
|
|
209
|
+
}, (0, _expValEquals.expValEquals)('platform_editor_media_card_vc_wrapper_attribute', 'isEnabled', true) ? {
|
|
210
|
+
'data-media-vc-wrapper': 'true'
|
|
211
|
+
} : {}), content];
|
|
209
212
|
};
|
|
210
213
|
};
|
|
211
214
|
|
|
@@ -20,8 +20,8 @@ var _keymaps = require("@atlaskit/editor-common/keymaps");
|
|
|
20
20
|
var _media = require("@atlaskit/editor-common/media");
|
|
21
21
|
var _ui = require("@atlaskit/editor-common/ui");
|
|
22
22
|
var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
|
|
23
|
+
var _chevronLeftChevronLeftLarge = _interopRequireDefault(require("@atlaskit/icon/core/migration/chevron-left--chevron-left-large"));
|
|
23
24
|
var _crossCircle = _interopRequireDefault(require("@atlaskit/icon/core/migration/cross-circle"));
|
|
24
|
-
var _chevronLeftChevronLeftLarge = _interopRequireDefault(require("@atlaskit/icon/utility/migration/chevron-left--chevron-left-large"));
|
|
25
25
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
26
26
|
var _colors = require("@atlaskit/theme/colors");
|
|
27
27
|
var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
|
|
@@ -208,7 +208,8 @@ var AltTextEditComponent = exports.AltTextEditComponent = /*#__PURE__*/function
|
|
|
208
208
|
}, (0, _react2.jsx)(_ui.FloatingToolbarButton, {
|
|
209
209
|
title: formatMessage(_media.altTextMessages.back),
|
|
210
210
|
icon: (0, _react2.jsx)(_chevronLeftChevronLeftLarge.default, {
|
|
211
|
-
label: formatMessage(_media.altTextMessages.back)
|
|
211
|
+
label: formatMessage(_media.altTextMessages.back),
|
|
212
|
+
size: "small"
|
|
212
213
|
}),
|
|
213
214
|
tooltipContent: backButtonMessageComponent,
|
|
214
215
|
onClick: this.closeMediaAltTextMenu
|
|
@@ -16,11 +16,11 @@ var _uiColor = require("@atlaskit/editor-common/ui-color");
|
|
|
16
16
|
var _uiMenu = require("@atlaskit/editor-common/ui-menu");
|
|
17
17
|
var _editorPalette = require("@atlaskit/editor-palette");
|
|
18
18
|
var _border = _interopRequireDefault(require("@atlaskit/icon/core/border"));
|
|
19
|
+
var _chevronDown = _interopRequireDefault(require("@atlaskit/icon/core/chevron-down"));
|
|
19
20
|
var _strokeWeightLarge = _interopRequireDefault(require("@atlaskit/icon/core/stroke-weight-large"));
|
|
20
21
|
var _strokeWeightMedium = _interopRequireDefault(require("@atlaskit/icon/core/stroke-weight-medium"));
|
|
21
22
|
var _strokeWeightSmall = _interopRequireDefault(require("@atlaskit/icon/core/stroke-weight-small"));
|
|
22
|
-
var
|
|
23
|
-
var _chevronDown2 = _interopRequireDefault(require("@atlaskit/icon/utility/chevron-down"));
|
|
23
|
+
var _chevronDown2 = _interopRequireDefault(require("@atlaskit/icon/glyph/chevron-down"));
|
|
24
24
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
25
25
|
var _compiled = require("@atlaskit/primitives/compiled");
|
|
26
26
|
var _tooltip = _interopRequireDefault(require("@atlaskit/tooltip"));
|
|
@@ -330,11 +330,12 @@ var ImageBorder = function ImageBorder(_ref) {
|
|
|
330
330
|
"aria-label": formatMessage(_media.imageBorderMessages.borderOptions),
|
|
331
331
|
title: formatMessage(_media.imageBorderMessages.borderOptions),
|
|
332
332
|
spacing: "compact",
|
|
333
|
-
iconBefore: (0, _react2.jsx)(
|
|
333
|
+
iconBefore: (0, _react2.jsx)(_chevronDown.default, {
|
|
334
334
|
color: "currentColor",
|
|
335
335
|
spacing: "spacious",
|
|
336
336
|
label: "",
|
|
337
|
-
LEGACY_fallbackIcon:
|
|
337
|
+
LEGACY_fallbackIcon: _chevronDown2.default,
|
|
338
|
+
size: "small"
|
|
338
339
|
}),
|
|
339
340
|
onClick: function onClick() {
|
|
340
341
|
setIsOpen(!isOpen);
|
|
@@ -20,8 +20,8 @@ var _media = require("@atlaskit/editor-common/media");
|
|
|
20
20
|
var _messages = require("@atlaskit/editor-common/messages");
|
|
21
21
|
var _ui = require("@atlaskit/editor-common/ui");
|
|
22
22
|
var _utils = require("@atlaskit/editor-common/utils");
|
|
23
|
+
var _chevronLeftChevronLeftLarge = _interopRequireDefault(require("@atlaskit/icon/core/migration/chevron-left--chevron-left-large"));
|
|
23
24
|
var _linkBrokenEditorUnlink = _interopRequireDefault(require("@atlaskit/icon/core/migration/link-broken--editor-unlink"));
|
|
24
|
-
var _chevronLeftChevronLeftLarge = _interopRequireDefault(require("@atlaskit/icon/utility/migration/chevron-left--chevron-left-large"));
|
|
25
25
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
26
26
|
var _colors = require("@atlaskit/theme/colors");
|
|
27
27
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
@@ -125,7 +125,8 @@ var LinkAddToolbar = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
125
125
|
}, (0, _react2.jsx)(_ui.FloatingToolbarButton, {
|
|
126
126
|
title: formatLinkAddressText,
|
|
127
127
|
icon: (0, _react2.jsx)(_chevronLeftChevronLeftLarge.default, {
|
|
128
|
-
label: formatLinkAddressText
|
|
128
|
+
label: formatLinkAddressText,
|
|
129
|
+
size: "small"
|
|
129
130
|
}),
|
|
130
131
|
onClick: function onClick() {
|
|
131
132
|
return _this.handleOnBack({
|
|
@@ -770,7 +770,7 @@ var floatingToolbar = exports.floatingToolbar = function floatingToolbar(state,
|
|
|
770
770
|
nodeType: nodeType,
|
|
771
771
|
getDomRef: function getDomRef() {
|
|
772
772
|
var _mediaPluginState$ele;
|
|
773
|
-
var element = isSelectedNodeMediaSingle
|
|
773
|
+
var element = isSelectedNodeMediaSingle ? ((_mediaPluginState$ele = mediaPluginState.element) === null || _mediaPluginState$ele === void 0 ? void 0 : _mediaPluginState$ele.querySelector(".".concat(_styles.MediaSingleNodeSelector))) || mediaPluginState.element : mediaPluginState.element;
|
|
774
774
|
return element;
|
|
775
775
|
}
|
|
776
776
|
};
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { mediaSingleSpec } from '@atlaskit/adf-schema';
|
|
2
2
|
import { convertToInlineCss } from '@atlaskit/editor-common/lazy-node-view';
|
|
3
3
|
import { N20, N50 } from '@atlaskit/theme/colors';
|
|
4
|
+
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
4
5
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
5
6
|
import { getAttrsFromNodeMediaSingle } from './toDOMAttrs';
|
|
6
7
|
const WRAPPED_LAYOUTS = ['wrap-left', 'wrap-right'];
|
|
@@ -199,7 +200,10 @@ export const getToDom = allowPixelResizing => node => {
|
|
|
199
200
|
marginRight: isMediaWrapped ? layout === 'wrap-right' ? 'auto' : HALF_GUTTER_SIZE : 0,
|
|
200
201
|
marginLeft: isMediaWrapped ? layout === 'wrap-left' ? 'auto' : HALF_GUTTER_SIZE : 0,
|
|
201
202
|
width: contentWrapperWidth
|
|
202
|
-
})
|
|
203
|
+
}),
|
|
204
|
+
...(expValEquals('platform_editor_media_card_vc_wrapper_attribute', 'isEnabled', true) ? {
|
|
205
|
+
'data-media-vc-wrapper': 'true'
|
|
206
|
+
} : {})
|
|
203
207
|
}, content];
|
|
204
208
|
};
|
|
205
209
|
|
|
@@ -15,8 +15,8 @@ import { escape, ToolTipContent } from '@atlaskit/editor-common/keymaps';
|
|
|
15
15
|
import { altTextMessages as messages } from '@atlaskit/editor-common/media';
|
|
16
16
|
import { RECENT_SEARCH_WIDTH_IN_PX as CONTAINER_WIDTH_IN_PX, FloatingToolbarButton as Button, ErrorMessage, PanelTextInput } from '@atlaskit/editor-common/ui';
|
|
17
17
|
import { relativeFontSizeToBase16 } from '@atlaskit/editor-shared-styles';
|
|
18
|
+
import ChevronLeftLargeIcon from '@atlaskit/icon/core/migration/chevron-left--chevron-left-large';
|
|
18
19
|
import CrossCircleIcon from '@atlaskit/icon/core/migration/cross-circle';
|
|
19
|
-
import ChevronLeftLargeIcon from '@atlaskit/icon/utility/migration/chevron-left--chevron-left-large';
|
|
20
20
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
21
21
|
import { N200, N30, N80, R400 } from '@atlaskit/theme/colors';
|
|
22
22
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
@@ -197,7 +197,8 @@ export class AltTextEditComponent extends React.Component {
|
|
|
197
197
|
}, jsx(Button, {
|
|
198
198
|
title: formatMessage(messages.back),
|
|
199
199
|
icon: jsx(ChevronLeftLargeIcon, {
|
|
200
|
-
label: formatMessage(messages.back)
|
|
200
|
+
label: formatMessage(messages.back),
|
|
201
|
+
size: "small"
|
|
201
202
|
}),
|
|
202
203
|
tooltipContent: backButtonMessageComponent,
|
|
203
204
|
onClick: this.closeMediaAltTextMenu
|
|
@@ -14,11 +14,11 @@ import { borderColorPalette, borderPaletteTooltipMessages, ColorPalette } from '
|
|
|
14
14
|
import { ArrowKeyNavigationProvider, ArrowKeyNavigationType, DropdownMenu, ToolbarButton } from '@atlaskit/editor-common/ui-menu';
|
|
15
15
|
import { hexToEditorBorderPaletteColor } from '@atlaskit/editor-palette';
|
|
16
16
|
import BorderIcon from '@atlaskit/icon/core/border';
|
|
17
|
+
import ChevronDownIcon from '@atlaskit/icon/core/chevron-down';
|
|
17
18
|
import StrokeWeightLargeIcon from '@atlaskit/icon/core/stroke-weight-large';
|
|
18
19
|
import StrokeWeightMediumIcon from '@atlaskit/icon/core/stroke-weight-medium';
|
|
19
20
|
import StrokeWeightSmallIcon from '@atlaskit/icon/core/stroke-weight-small';
|
|
20
21
|
import ExpandIcon from '@atlaskit/icon/glyph/chevron-down';
|
|
21
|
-
import ChevronDownIcon from '@atlaskit/icon/utility/chevron-down';
|
|
22
22
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
23
23
|
import { Text } from '@atlaskit/primitives/compiled';
|
|
24
24
|
import Tooltip from '@atlaskit/tooltip';
|
|
@@ -307,7 +307,8 @@ const ImageBorder = ({
|
|
|
307
307
|
color: "currentColor",
|
|
308
308
|
spacing: "spacious",
|
|
309
309
|
label: "",
|
|
310
|
-
LEGACY_fallbackIcon: ExpandIcon
|
|
310
|
+
LEGACY_fallbackIcon: ExpandIcon,
|
|
311
|
+
size: "small"
|
|
311
312
|
}),
|
|
312
313
|
onClick: () => {
|
|
313
314
|
setIsOpen(!isOpen);
|
|
@@ -15,8 +15,8 @@ import { FloatingToolbarButton as Button, ErrorMessage, FloatingToolbarSeparator
|
|
|
15
15
|
// Common Translations will live here
|
|
16
16
|
PanelTextInput } from '@atlaskit/editor-common/ui';
|
|
17
17
|
import { normalizeUrl } from '@atlaskit/editor-common/utils';
|
|
18
|
+
import ChevronLeftLargeIcon from '@atlaskit/icon/core/migration/chevron-left--chevron-left-large';
|
|
18
19
|
import EditorUnlinkIcon from '@atlaskit/icon/core/migration/link-broken--editor-unlink';
|
|
19
|
-
import ChevronLeftLargeIcon from '@atlaskit/icon/utility/migration/chevron-left--chevron-left-large';
|
|
20
20
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
21
21
|
import { R400 } from '@atlaskit/theme/colors';
|
|
22
22
|
const validationWrapper = css({
|
|
@@ -120,7 +120,8 @@ class LinkAddToolbar extends React.PureComponent {
|
|
|
120
120
|
}, jsx(Button, {
|
|
121
121
|
title: formatLinkAddressText,
|
|
122
122
|
icon: jsx(ChevronLeftLargeIcon, {
|
|
123
|
-
label: formatLinkAddressText
|
|
123
|
+
label: formatLinkAddressText,
|
|
124
|
+
size: "small"
|
|
124
125
|
}),
|
|
125
126
|
onClick: () => this.handleOnBack({
|
|
126
127
|
url: value,
|
|
@@ -768,7 +768,7 @@ export const floatingToolbar = (state, intl, options = {}, pluginInjectionApi) =
|
|
|
768
768
|
nodeType,
|
|
769
769
|
getDomRef: () => {
|
|
770
770
|
var _mediaPluginState$ele;
|
|
771
|
-
const element = isSelectedNodeMediaSingle
|
|
771
|
+
const element = isSelectedNodeMediaSingle ? ((_mediaPluginState$ele = mediaPluginState.element) === null || _mediaPluginState$ele === void 0 ? void 0 : _mediaPluginState$ele.querySelector(`.${MediaSingleNodeSelector}`)) || mediaPluginState.element : mediaPluginState.element;
|
|
772
772
|
return element;
|
|
773
773
|
}
|
|
774
774
|
};
|
|
@@ -4,6 +4,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
4
4
|
import { mediaSingleSpec } from '@atlaskit/adf-schema';
|
|
5
5
|
import { convertToInlineCss } from '@atlaskit/editor-common/lazy-node-view';
|
|
6
6
|
import { N20, N50 } from '@atlaskit/theme/colors';
|
|
7
|
+
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
7
8
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
8
9
|
import { getAttrsFromNodeMediaSingle } from './toDOMAttrs';
|
|
9
10
|
var WRAPPED_LAYOUTS = ['wrap-left', 'wrap-right'];
|
|
@@ -183,7 +184,7 @@ export var getToDom = function getToDom(allowPixelResizing) {
|
|
|
183
184
|
childMediaWidth: childMediaWidth,
|
|
184
185
|
mediaSingleDimensionWidth: mediaSingleAttrs === null || mediaSingleAttrs === void 0 ? void 0 : mediaSingleAttrs.width
|
|
185
186
|
});
|
|
186
|
-
return ['div', {
|
|
187
|
+
return ['div', _objectSpread({
|
|
187
188
|
class: 'mediaSingleView-content-wrap',
|
|
188
189
|
layout: layout,
|
|
189
190
|
style: convertToInlineCss({
|
|
@@ -198,7 +199,9 @@ export var getToDom = function getToDom(allowPixelResizing) {
|
|
|
198
199
|
marginLeft: isMediaWrapped ? layout === 'wrap-left' ? 'auto' : HALF_GUTTER_SIZE : 0,
|
|
199
200
|
width: contentWrapperWidth
|
|
200
201
|
})
|
|
201
|
-
},
|
|
202
|
+
}, expValEquals('platform_editor_media_card_vc_wrapper_attribute', 'isEnabled', true) ? {
|
|
203
|
+
'data-media-vc-wrapper': 'true'
|
|
204
|
+
} : {}), content];
|
|
202
205
|
};
|
|
203
206
|
};
|
|
204
207
|
|
|
@@ -22,8 +22,8 @@ import { escape, ToolTipContent } from '@atlaskit/editor-common/keymaps';
|
|
|
22
22
|
import { altTextMessages as messages } from '@atlaskit/editor-common/media';
|
|
23
23
|
import { RECENT_SEARCH_WIDTH_IN_PX as CONTAINER_WIDTH_IN_PX, FloatingToolbarButton as Button, ErrorMessage, PanelTextInput } from '@atlaskit/editor-common/ui';
|
|
24
24
|
import { relativeFontSizeToBase16 } from '@atlaskit/editor-shared-styles';
|
|
25
|
+
import ChevronLeftLargeIcon from '@atlaskit/icon/core/migration/chevron-left--chevron-left-large';
|
|
25
26
|
import CrossCircleIcon from '@atlaskit/icon/core/migration/cross-circle';
|
|
26
|
-
import ChevronLeftLargeIcon from '@atlaskit/icon/utility/migration/chevron-left--chevron-left-large';
|
|
27
27
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
28
28
|
import { N200, N30, N80, R400 } from '@atlaskit/theme/colors';
|
|
29
29
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
@@ -205,7 +205,8 @@ export var AltTextEditComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
205
205
|
}, jsx(Button, {
|
|
206
206
|
title: formatMessage(messages.back),
|
|
207
207
|
icon: jsx(ChevronLeftLargeIcon, {
|
|
208
|
-
label: formatMessage(messages.back)
|
|
208
|
+
label: formatMessage(messages.back),
|
|
209
|
+
size: "small"
|
|
209
210
|
}),
|
|
210
211
|
tooltipContent: backButtonMessageComponent,
|
|
211
212
|
onClick: this.closeMediaAltTextMenu
|
|
@@ -15,11 +15,11 @@ import { borderColorPalette, borderPaletteTooltipMessages, ColorPalette } from '
|
|
|
15
15
|
import { ArrowKeyNavigationProvider, ArrowKeyNavigationType, DropdownMenu, ToolbarButton } from '@atlaskit/editor-common/ui-menu';
|
|
16
16
|
import { hexToEditorBorderPaletteColor } from '@atlaskit/editor-palette';
|
|
17
17
|
import BorderIcon from '@atlaskit/icon/core/border';
|
|
18
|
+
import ChevronDownIcon from '@atlaskit/icon/core/chevron-down';
|
|
18
19
|
import StrokeWeightLargeIcon from '@atlaskit/icon/core/stroke-weight-large';
|
|
19
20
|
import StrokeWeightMediumIcon from '@atlaskit/icon/core/stroke-weight-medium';
|
|
20
21
|
import StrokeWeightSmallIcon from '@atlaskit/icon/core/stroke-weight-small';
|
|
21
22
|
import ExpandIcon from '@atlaskit/icon/glyph/chevron-down';
|
|
22
|
-
import ChevronDownIcon from '@atlaskit/icon/utility/chevron-down';
|
|
23
23
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
24
24
|
import { Text } from '@atlaskit/primitives/compiled';
|
|
25
25
|
import Tooltip from '@atlaskit/tooltip';
|
|
@@ -326,7 +326,8 @@ var ImageBorder = function ImageBorder(_ref) {
|
|
|
326
326
|
color: "currentColor",
|
|
327
327
|
spacing: "spacious",
|
|
328
328
|
label: "",
|
|
329
|
-
LEGACY_fallbackIcon: ExpandIcon
|
|
329
|
+
LEGACY_fallbackIcon: ExpandIcon,
|
|
330
|
+
size: "small"
|
|
330
331
|
}),
|
|
331
332
|
onClick: function onClick() {
|
|
332
333
|
setIsOpen(!isOpen);
|
|
@@ -22,8 +22,8 @@ import { FloatingToolbarButton as Button, ErrorMessage, FloatingToolbarSeparator
|
|
|
22
22
|
// Common Translations will live here
|
|
23
23
|
PanelTextInput } from '@atlaskit/editor-common/ui';
|
|
24
24
|
import { normalizeUrl } from '@atlaskit/editor-common/utils';
|
|
25
|
+
import ChevronLeftLargeIcon from '@atlaskit/icon/core/migration/chevron-left--chevron-left-large';
|
|
25
26
|
import EditorUnlinkIcon from '@atlaskit/icon/core/migration/link-broken--editor-unlink';
|
|
26
|
-
import ChevronLeftLargeIcon from '@atlaskit/icon/utility/migration/chevron-left--chevron-left-large';
|
|
27
27
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
28
28
|
import { R400 } from '@atlaskit/theme/colors';
|
|
29
29
|
var validationWrapper = css({
|
|
@@ -121,7 +121,8 @@ var LinkAddToolbar = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
121
121
|
}, jsx(Button, {
|
|
122
122
|
title: formatLinkAddressText,
|
|
123
123
|
icon: jsx(ChevronLeftLargeIcon, {
|
|
124
|
-
label: formatLinkAddressText
|
|
124
|
+
label: formatLinkAddressText,
|
|
125
|
+
size: "small"
|
|
125
126
|
}),
|
|
126
127
|
onClick: function onClick() {
|
|
127
128
|
return _this.handleOnBack({
|
|
@@ -761,7 +761,7 @@ export var floatingToolbar = function floatingToolbar(state, intl) {
|
|
|
761
761
|
nodeType: nodeType,
|
|
762
762
|
getDomRef: function getDomRef() {
|
|
763
763
|
var _mediaPluginState$ele;
|
|
764
|
-
var element = isSelectedNodeMediaSingle
|
|
764
|
+
var element = isSelectedNodeMediaSingle ? ((_mediaPluginState$ele = mediaPluginState.element) === null || _mediaPluginState$ele === void 0 ? void 0 : _mediaPluginState$ele.querySelector(".".concat(MediaSingleNodeSelector))) || mediaPluginState.element : mediaPluginState.element;
|
|
765
765
|
return element;
|
|
766
766
|
}
|
|
767
767
|
};
|
|
@@ -5,7 +5,7 @@ import { type PortalProviderAPI } from '@atlaskit/editor-common/portal';
|
|
|
5
5
|
import type { ContextIdentifierProvider, MediaProvider, ProviderFactory, Providers } from '@atlaskit/editor-common/provider-factory';
|
|
6
6
|
import { SelectionBasedNodeView } from '@atlaskit/editor-common/selection-based-node-view';
|
|
7
7
|
import type { ExtractInjectionAPI, EditorContainerWidth as WidthPluginState } from '@atlaskit/editor-common/types';
|
|
8
|
-
import { SharedInteractionState } from '@atlaskit/editor-plugin-interaction';
|
|
8
|
+
import type { SharedInteractionState } from '@atlaskit/editor-plugin-interaction';
|
|
9
9
|
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
10
10
|
import type { Decoration, EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
11
11
|
import type { MediaNextEditorPluginType } from '../../mediaPluginType';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IntlShape } from 'react-intl-next';
|
|
1
|
+
import type { IntlShape } from 'react-intl-next';
|
|
2
2
|
import type { ExternalMediaAttributes, MediaADFAttrs, RichMediaLayout } from '@atlaskit/adf-schema';
|
|
3
3
|
import type { LayoutIcon } from '@atlaskit/editor-common/card';
|
|
4
4
|
import type { Command, FloatingToolbarItem, FloatingToolbarDropdown, ExtractInjectionAPI } from '@atlaskit/editor-common/types';
|
|
@@ -5,7 +5,7 @@ import { type PortalProviderAPI } from '@atlaskit/editor-common/portal';
|
|
|
5
5
|
import type { ContextIdentifierProvider, MediaProvider, ProviderFactory, Providers } from '@atlaskit/editor-common/provider-factory';
|
|
6
6
|
import { SelectionBasedNodeView } from '@atlaskit/editor-common/selection-based-node-view';
|
|
7
7
|
import type { ExtractInjectionAPI, EditorContainerWidth as WidthPluginState } from '@atlaskit/editor-common/types';
|
|
8
|
-
import { SharedInteractionState } from '@atlaskit/editor-plugin-interaction';
|
|
8
|
+
import type { SharedInteractionState } from '@atlaskit/editor-plugin-interaction';
|
|
9
9
|
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
10
10
|
import type { Decoration, EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
11
11
|
import type { MediaNextEditorPluginType } from '../../mediaPluginType';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IntlShape } from 'react-intl-next';
|
|
1
|
+
import type { IntlShape } from 'react-intl-next';
|
|
2
2
|
import type { ExternalMediaAttributes, MediaADFAttrs, RichMediaLayout } from '@atlaskit/adf-schema';
|
|
3
3
|
import type { LayoutIcon } from '@atlaskit/editor-common/card';
|
|
4
4
|
import type { Command, FloatingToolbarItem, FloatingToolbarDropdown, ExtractInjectionAPI } from '@atlaskit/editor-common/types';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-media",
|
|
3
|
-
"version": "3.0
|
|
3
|
+
"version": "3.1.0",
|
|
4
4
|
"description": "Media plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"@atlaskit/analytics-namespaced-context": "^7.0.0",
|
|
39
39
|
"@atlaskit/analytics-next": "^11.1.0",
|
|
40
40
|
"@atlaskit/button": "^23.2.0",
|
|
41
|
-
"@atlaskit/editor-common": "^106.
|
|
41
|
+
"@atlaskit/editor-common": "^106.9.0",
|
|
42
42
|
"@atlaskit/editor-palette": "^2.1.0",
|
|
43
43
|
"@atlaskit/editor-plugin-analytics": "^2.3.0",
|
|
44
44
|
"@atlaskit/editor-plugin-annotation": "^2.9.0",
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
"@atlaskit/editor-plugin-decorations": "^2.0.0",
|
|
47
47
|
"@atlaskit/editor-plugin-editor-disabled": "^2.0.0",
|
|
48
48
|
"@atlaskit/editor-plugin-editor-viewmode": "^4.0.0",
|
|
49
|
-
"@atlaskit/editor-plugin-floating-toolbar": "^4.
|
|
49
|
+
"@atlaskit/editor-plugin-floating-toolbar": "^4.2.0",
|
|
50
50
|
"@atlaskit/editor-plugin-focus": "^1.5.0",
|
|
51
51
|
"@atlaskit/editor-plugin-grid": "^2.0.0",
|
|
52
52
|
"@atlaskit/editor-plugin-guideline": "^2.0.0",
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
"@atlaskit/form": "^12.0.0",
|
|
60
60
|
"@atlaskit/icon": "^26.4.0",
|
|
61
61
|
"@atlaskit/media-card": "^79.3.0",
|
|
62
|
-
"@atlaskit/media-client": "^33.
|
|
62
|
+
"@atlaskit/media-client": "^33.4.0",
|
|
63
63
|
"@atlaskit/media-client-react": "^4.1.0",
|
|
64
64
|
"@atlaskit/media-common": "^12.1.0",
|
|
65
65
|
"@atlaskit/media-filmstrip": "^50.1.0",
|
|
@@ -70,8 +70,8 @@
|
|
|
70
70
|
"@atlaskit/primitives": "^14.8.0",
|
|
71
71
|
"@atlaskit/textfield": "^8.0.0",
|
|
72
72
|
"@atlaskit/theme": "^18.0.0",
|
|
73
|
-
"@atlaskit/tmp-editor-statsig": "^
|
|
74
|
-
"@atlaskit/tokens": "^5.
|
|
73
|
+
"@atlaskit/tmp-editor-statsig": "^7.1.0",
|
|
74
|
+
"@atlaskit/tokens": "^5.2.0",
|
|
75
75
|
"@atlaskit/tooltip": "^20.3.0",
|
|
76
76
|
"@babel/runtime": "^7.0.0",
|
|
77
77
|
"@emotion/react": "^11.7.1",
|
|
@@ -172,9 +172,6 @@
|
|
|
172
172
|
"platform_editor_remove_media_inline_feature_flag": {
|
|
173
173
|
"type": "boolean"
|
|
174
174
|
},
|
|
175
|
-
"platform_editor_media_single_toolbar_target": {
|
|
176
|
-
"type": "boolean"
|
|
177
|
-
},
|
|
178
175
|
"platform_editor_controls_patch_6": {
|
|
179
176
|
"type": "boolean"
|
|
180
177
|
},
|