@atlaskit/editor-plugin-media 14.3.0 → 14.3.2
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 +13 -0
- package/dist/cjs/nodeviews/mediaSingleNext.js +2 -10
- package/dist/cjs/ui/CaptionPlaceholder/index.js +6 -42
- package/dist/es2019/nodeviews/mediaSingleNext.js +3 -11
- package/dist/es2019/ui/CaptionPlaceholder/index.js +0 -43
- package/dist/esm/nodeviews/mediaSingleNext.js +3 -11
- package/dist/esm/ui/CaptionPlaceholder/index.js +1 -39
- package/dist/types/ui/CaptionPlaceholder/index.d.ts +0 -1
- package/package.json +4 -7
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-media
|
|
2
2
|
|
|
3
|
+
## 14.3.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
9
|
+
## 14.3.1
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [`4fa93c380fa24`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/4fa93c380fa24) -
|
|
14
|
+
Clean up platform editor typography UGC feature gate
|
|
15
|
+
|
|
3
16
|
## 14.3.0
|
|
4
17
|
|
|
5
18
|
### Minor Changes
|
|
@@ -21,7 +21,6 @@ var _ui = require("@atlaskit/editor-common/ui");
|
|
|
21
21
|
var _state = require("@atlaskit/editor-prosemirror/state");
|
|
22
22
|
var _utils = require("@atlaskit/editor-prosemirror/utils");
|
|
23
23
|
var _mediaClient = require("@atlaskit/media-client");
|
|
24
|
-
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
25
24
|
var _captions = require("../pm-plugins/commands/captions");
|
|
26
25
|
var _mediaCommon = require("../pm-plugins/utils/media-common");
|
|
27
26
|
var _CaptionPlaceholder = require("../ui/CaptionPlaceholder");
|
|
@@ -503,18 +502,11 @@ var MediaSingleNodeNext = exports.MediaSingleNodeNext = function MediaSingleNode
|
|
|
503
502
|
}));
|
|
504
503
|
}), (0, _react2.jsx)(_reactNodeView.NodeViewContentHole, {
|
|
505
504
|
ref: forwardRef
|
|
506
|
-
}), shouldShowPlaceholder && (
|
|
507
|
-
// platform_editor_typography_ugc clean up
|
|
508
|
-
// remove typecasting
|
|
509
|
-
, {
|
|
505
|
+
}), shouldShowPlaceholder && (0, _react2.jsx)(_CaptionPlaceholder.CaptionPlaceholderButton, {
|
|
510
506
|
ref: captionPlaceHolderRef,
|
|
511
507
|
onClick: clickPlaceholder,
|
|
512
508
|
placeholderMessage: mediaOptions.allowImagePreview ? _media.captionMessages.placeholderWithDoubleClickPrompt : _media.captionMessages.placeholder
|
|
513
|
-
})
|
|
514
|
-
ref: captionPlaceHolderRef,
|
|
515
|
-
onClick: clickPlaceholder,
|
|
516
|
-
placeholderMessage: mediaOptions.allowImagePreview ? _media.captionMessages.placeholderWithDoubleClickPrompt : _media.captionMessages.placeholder
|
|
517
|
-
})));
|
|
509
|
+
}));
|
|
518
510
|
if (widthType !== 'pixel') {
|
|
519
511
|
return (0, _react2.jsx)(_react.Fragment, null, canResize ? mediaOptions.allowPixelResizing ? (0, _react2.jsx)(_ResizableMediaSingleNext.default, {
|
|
520
512
|
view: view,
|
|
@@ -1,32 +1,27 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
3
|
var _typeof = require("@babel/runtime/helpers/typeof");
|
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
|
6
5
|
value: true
|
|
7
6
|
});
|
|
8
|
-
exports.CaptionPlaceholderButton =
|
|
9
|
-
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
|
|
7
|
+
exports.CaptionPlaceholderButton = void 0;
|
|
10
8
|
var _react = _interopRequireWildcard(require("react"));
|
|
11
9
|
var _react2 = require("@emotion/react");
|
|
12
10
|
var _reactIntl = require("react-intl");
|
|
13
11
|
var _media = require("@atlaskit/editor-common/media");
|
|
14
12
|
var _mediaSingle = require("@atlaskit/editor-common/media-single");
|
|
15
13
|
var _primitives = require("@atlaskit/primitives");
|
|
16
|
-
var
|
|
14
|
+
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); }
|
|
17
15
|
/* eslint-disable @atlaskit/design-system/use-primitives-text */
|
|
18
|
-
// This had to be disabled to add an id and styles to a component that could not be replaced with Text
|
|
19
|
-
// This was added in a experiment cleanup and should be removed if possible
|
|
20
|
-
// Be sure to use primitives in this file as needed
|
|
21
16
|
/**
|
|
22
17
|
* @jsxRuntime classic
|
|
23
18
|
* @jsx jsx
|
|
24
19
|
*/
|
|
20
|
+
|
|
25
21
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
22
|
+
|
|
26
23
|
// eslint-disable-next-line @atlaskit/design-system/no-emotion-primitives -- to be migrated to @atlaskit/primitives/compiled – go/akcss
|
|
27
|
-
|
|
28
|
-
// eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
|
|
29
|
-
var placeholder = (0, _react2.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n\tcolor: ", ";\n\twidth: 100%;\n\ttext-align: center;\n\tmargin-top: ", " !important;\n\tdisplay: block;\n"])), "var(--ds-text-subtlest, #6B6E76)", "var(--ds-space-100, 8px)");
|
|
24
|
+
|
|
30
25
|
var placeholderText = (0, _react2.css)({
|
|
31
26
|
color: "var(--ds-text-subtlest, #6B6E76)"
|
|
32
27
|
});
|
|
@@ -34,40 +29,9 @@ var placeholderButton = (0, _primitives.xcss)({
|
|
|
34
29
|
width: '100%',
|
|
35
30
|
marginTop: 'space.100'
|
|
36
31
|
});
|
|
37
|
-
|
|
38
|
-
// Remove this component
|
|
39
|
-
var CaptionPlaceholder = exports.CaptionPlaceholder = /*#__PURE__*/_react.default.forwardRef(function (_ref, ref) {
|
|
32
|
+
var CaptionPlaceholderButton = exports.CaptionPlaceholderButton = /*#__PURE__*/_react.default.forwardRef(function (_ref, ref) {
|
|
40
33
|
var onClick = _ref.onClick,
|
|
41
34
|
placeholderMessage = _ref.placeholderMessage;
|
|
42
|
-
var handlePointerDown = (0, _react.useCallback)(function (e) {
|
|
43
|
-
e.preventDefault();
|
|
44
|
-
onClick();
|
|
45
|
-
}, [onClick]);
|
|
46
|
-
var computedPlaceholderMessage = placeholderMessage ? placeholderMessage : _media.captionMessages.placeholder;
|
|
47
|
-
|
|
48
|
-
// This issue is a temporary fix for users being able to edit captions on edge browsers. This will be removed
|
|
49
|
-
// replaced with CaptionPlaceholderButton in the near future and this code can be removed.
|
|
50
|
-
return (
|
|
51
|
-
// eslint-disable-next-line @atlaskit/design-system/use-primitives-text
|
|
52
|
-
(0, _react2.jsx)("span", {
|
|
53
|
-
ref: ref,
|
|
54
|
-
css: placeholder,
|
|
55
|
-
onPointerDown: handlePointerDown
|
|
56
|
-
// This id is just used for setting styles at the moment, if it's needed for anything more specific
|
|
57
|
-
// It may need to be generated to avoid overlap
|
|
58
|
-
,
|
|
59
|
-
id: _mediaSingle.CAPTION_PLACEHOLDER_ID,
|
|
60
|
-
"data-id": _mediaSingle.CAPTION_PLACEHOLDER_ID,
|
|
61
|
-
"data-testid": "caption-placeholder"
|
|
62
|
-
}, (0, _react2.jsx)(_reactIntl.FormattedMessage
|
|
63
|
-
// Ignored via go/ees005
|
|
64
|
-
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
65
|
-
, computedPlaceholderMessage))
|
|
66
|
-
);
|
|
67
|
-
});
|
|
68
|
-
var CaptionPlaceholderButton = exports.CaptionPlaceholderButton = /*#__PURE__*/_react.default.forwardRef(function (_ref2, ref) {
|
|
69
|
-
var onClick = _ref2.onClick,
|
|
70
|
-
placeholderMessage = _ref2.placeholderMessage;
|
|
71
35
|
var handleMouseDown = (0, _react.useCallback)(function (e) {
|
|
72
36
|
// In firefox, button is focused when mouse down, which make editor lose focus
|
|
73
37
|
// Hence we want to disabled it so that user can type in caption directly after click
|
|
@@ -16,10 +16,9 @@ import { MediaSingle } from '@atlaskit/editor-common/ui';
|
|
|
16
16
|
import { NodeSelection } from '@atlaskit/editor-prosemirror/state';
|
|
17
17
|
import { findParentNodeOfTypeClosestToPos } from '@atlaskit/editor-prosemirror/utils';
|
|
18
18
|
import { getAttrsFromUrl } from '@atlaskit/media-client';
|
|
19
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
20
19
|
import { insertAndSelectCaptionFromMediaSinglePos } from '../pm-plugins/commands/captions';
|
|
21
20
|
import { isMediaBlobUrlFromAttrs } from '../pm-plugins/utils/media-common';
|
|
22
|
-
import {
|
|
21
|
+
import { CaptionPlaceholderButton } from '../ui/CaptionPlaceholder';
|
|
23
22
|
import { CommentBadgeWrapper } from '../ui/CommentBadge';
|
|
24
23
|
import ResizableMediaSingle from '../ui/ResizableMediaSingle';
|
|
25
24
|
import ResizableMediaSingleNext from '../ui/ResizableMediaSingle/ResizableMediaSingleNext';
|
|
@@ -462,18 +461,11 @@ export const MediaSingleNodeNext = mediaSingleNodeNextProps => {
|
|
|
462
461
|
isDrafting: isCurrentNodeDrafting
|
|
463
462
|
}))), jsx(NodeViewContentHole, {
|
|
464
463
|
ref: forwardRef
|
|
465
|
-
}), shouldShowPlaceholder &&
|
|
466
|
-
// platform_editor_typography_ugc clean up
|
|
467
|
-
// remove typecasting
|
|
468
|
-
, {
|
|
464
|
+
}), shouldShowPlaceholder && jsx(CaptionPlaceholderButton, {
|
|
469
465
|
ref: captionPlaceHolderRef,
|
|
470
466
|
onClick: clickPlaceholder,
|
|
471
467
|
placeholderMessage: mediaOptions.allowImagePreview ? captionMessages.placeholderWithDoubleClickPrompt : captionMessages.placeholder
|
|
472
|
-
})
|
|
473
|
-
ref: captionPlaceHolderRef,
|
|
474
|
-
onClick: clickPlaceholder,
|
|
475
|
-
placeholderMessage: mediaOptions.allowImagePreview ? captionMessages.placeholderWithDoubleClickPrompt : captionMessages.placeholder
|
|
476
|
-
})));
|
|
468
|
+
}));
|
|
477
469
|
if (widthType !== 'pixel') {
|
|
478
470
|
return jsx(Fragment, null, canResize ? mediaOptions.allowPixelResizing ? jsx(ResizableMediaSingleNext, {
|
|
479
471
|
view: view,
|
|
@@ -1,7 +1,4 @@
|
|
|
1
1
|
/* eslint-disable @atlaskit/design-system/use-primitives-text */
|
|
2
|
-
// This had to be disabled to add an id and styles to a component that could not be replaced with Text
|
|
3
|
-
// This was added in a experiment cleanup and should be removed if possible
|
|
4
|
-
// Be sure to use primitives in this file as needed
|
|
5
2
|
/**
|
|
6
3
|
* @jsxRuntime classic
|
|
7
4
|
* @jsx jsx
|
|
@@ -15,14 +12,6 @@ import { captionMessages as messages } from '@atlaskit/editor-common/media';
|
|
|
15
12
|
import { CAPTION_PLACEHOLDER_ID } from '@atlaskit/editor-common/media-single';
|
|
16
13
|
// eslint-disable-next-line @atlaskit/design-system/no-emotion-primitives -- to be migrated to @atlaskit/primitives/compiled – go/akcss
|
|
17
14
|
import { Pressable, xcss } from '@atlaskit/primitives';
|
|
18
|
-
// eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
|
|
19
|
-
const placeholder = css`
|
|
20
|
-
color: ${"var(--ds-text-subtlest, #6B6E76)"};
|
|
21
|
-
width: 100%;
|
|
22
|
-
text-align: center;
|
|
23
|
-
margin-top: ${"var(--ds-space-100, 8px)"} !important;
|
|
24
|
-
display: block;
|
|
25
|
-
`;
|
|
26
15
|
const placeholderText = css({
|
|
27
16
|
color: "var(--ds-text-subtlest, #6B6E76)"
|
|
28
17
|
});
|
|
@@ -30,38 +19,6 @@ const placeholderButton = xcss({
|
|
|
30
19
|
width: '100%',
|
|
31
20
|
marginTop: 'space.100'
|
|
32
21
|
});
|
|
33
|
-
// platform_editor_typography_ugc clean up
|
|
34
|
-
// Remove this component
|
|
35
|
-
export const CaptionPlaceholder = /*#__PURE__*/React.forwardRef(({
|
|
36
|
-
onClick,
|
|
37
|
-
placeholderMessage
|
|
38
|
-
}, ref) => {
|
|
39
|
-
const handlePointerDown = useCallback(e => {
|
|
40
|
-
e.preventDefault();
|
|
41
|
-
onClick();
|
|
42
|
-
}, [onClick]);
|
|
43
|
-
const computedPlaceholderMessage = placeholderMessage ? placeholderMessage : messages.placeholder;
|
|
44
|
-
|
|
45
|
-
// This issue is a temporary fix for users being able to edit captions on edge browsers. This will be removed
|
|
46
|
-
// replaced with CaptionPlaceholderButton in the near future and this code can be removed.
|
|
47
|
-
return (
|
|
48
|
-
// eslint-disable-next-line @atlaskit/design-system/use-primitives-text
|
|
49
|
-
jsx("span", {
|
|
50
|
-
ref: ref,
|
|
51
|
-
css: placeholder,
|
|
52
|
-
onPointerDown: handlePointerDown
|
|
53
|
-
// This id is just used for setting styles at the moment, if it's needed for anything more specific
|
|
54
|
-
// It may need to be generated to avoid overlap
|
|
55
|
-
,
|
|
56
|
-
id: CAPTION_PLACEHOLDER_ID,
|
|
57
|
-
"data-id": CAPTION_PLACEHOLDER_ID,
|
|
58
|
-
"data-testid": "caption-placeholder"
|
|
59
|
-
}, jsx(FormattedMessage
|
|
60
|
-
// Ignored via go/ees005
|
|
61
|
-
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
62
|
-
, computedPlaceholderMessage))
|
|
63
|
-
);
|
|
64
|
-
});
|
|
65
22
|
export const CaptionPlaceholderButton = /*#__PURE__*/React.forwardRef(({
|
|
66
23
|
onClick,
|
|
67
24
|
placeholderMessage
|
|
@@ -22,10 +22,9 @@ import { MediaSingle } from '@atlaskit/editor-common/ui';
|
|
|
22
22
|
import { NodeSelection } from '@atlaskit/editor-prosemirror/state';
|
|
23
23
|
import { findParentNodeOfTypeClosestToPos } from '@atlaskit/editor-prosemirror/utils';
|
|
24
24
|
import { getAttrsFromUrl } from '@atlaskit/media-client';
|
|
25
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
26
25
|
import { insertAndSelectCaptionFromMediaSinglePos } from '../pm-plugins/commands/captions';
|
|
27
26
|
import { isMediaBlobUrlFromAttrs } from '../pm-plugins/utils/media-common';
|
|
28
|
-
import {
|
|
27
|
+
import { CaptionPlaceholderButton } from '../ui/CaptionPlaceholder';
|
|
29
28
|
import { CommentBadgeWrapper } from '../ui/CommentBadge';
|
|
30
29
|
import ResizableMediaSingle from '../ui/ResizableMediaSingle';
|
|
31
30
|
import ResizableMediaSingleNext from '../ui/ResizableMediaSingle/ResizableMediaSingleNext';
|
|
@@ -497,18 +496,11 @@ export var MediaSingleNodeNext = function MediaSingleNodeNext(mediaSingleNodeNex
|
|
|
497
496
|
}));
|
|
498
497
|
}), jsx(NodeViewContentHole, {
|
|
499
498
|
ref: forwardRef
|
|
500
|
-
}), shouldShowPlaceholder &&
|
|
501
|
-
// platform_editor_typography_ugc clean up
|
|
502
|
-
// remove typecasting
|
|
503
|
-
, {
|
|
499
|
+
}), shouldShowPlaceholder && jsx(CaptionPlaceholderButton, {
|
|
504
500
|
ref: captionPlaceHolderRef,
|
|
505
501
|
onClick: clickPlaceholder,
|
|
506
502
|
placeholderMessage: mediaOptions.allowImagePreview ? captionMessages.placeholderWithDoubleClickPrompt : captionMessages.placeholder
|
|
507
|
-
})
|
|
508
|
-
ref: captionPlaceHolderRef,
|
|
509
|
-
onClick: clickPlaceholder,
|
|
510
|
-
placeholderMessage: mediaOptions.allowImagePreview ? captionMessages.placeholderWithDoubleClickPrompt : captionMessages.placeholder
|
|
511
|
-
})));
|
|
503
|
+
}));
|
|
512
504
|
if (widthType !== 'pixel') {
|
|
513
505
|
return jsx(Fragment, null, canResize ? mediaOptions.allowPixelResizing ? jsx(ResizableMediaSingleNext, {
|
|
514
506
|
view: view,
|
|
@@ -1,9 +1,4 @@
|
|
|
1
|
-
import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
|
|
2
|
-
var _templateObject;
|
|
3
1
|
/* eslint-disable @atlaskit/design-system/use-primitives-text */
|
|
4
|
-
// This had to be disabled to add an id and styles to a component that could not be replaced with Text
|
|
5
|
-
// This was added in a experiment cleanup and should be removed if possible
|
|
6
|
-
// Be sure to use primitives in this file as needed
|
|
7
2
|
/**
|
|
8
3
|
* @jsxRuntime classic
|
|
9
4
|
* @jsx jsx
|
|
@@ -17,8 +12,6 @@ import { captionMessages as messages } from '@atlaskit/editor-common/media';
|
|
|
17
12
|
import { CAPTION_PLACEHOLDER_ID } from '@atlaskit/editor-common/media-single';
|
|
18
13
|
// eslint-disable-next-line @atlaskit/design-system/no-emotion-primitives -- to be migrated to @atlaskit/primitives/compiled – go/akcss
|
|
19
14
|
import { Pressable, xcss } from '@atlaskit/primitives';
|
|
20
|
-
// eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
|
|
21
|
-
var placeholder = css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n\tcolor: ", ";\n\twidth: 100%;\n\ttext-align: center;\n\tmargin-top: ", " !important;\n\tdisplay: block;\n"])), "var(--ds-text-subtlest, #6B6E76)", "var(--ds-space-100, 8px)");
|
|
22
15
|
var placeholderText = css({
|
|
23
16
|
color: "var(--ds-text-subtlest, #6B6E76)"
|
|
24
17
|
});
|
|
@@ -26,40 +19,9 @@ var placeholderButton = xcss({
|
|
|
26
19
|
width: '100%',
|
|
27
20
|
marginTop: 'space.100'
|
|
28
21
|
});
|
|
29
|
-
|
|
30
|
-
// Remove this component
|
|
31
|
-
export var CaptionPlaceholder = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
22
|
+
export var CaptionPlaceholderButton = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
32
23
|
var onClick = _ref.onClick,
|
|
33
24
|
placeholderMessage = _ref.placeholderMessage;
|
|
34
|
-
var handlePointerDown = useCallback(function (e) {
|
|
35
|
-
e.preventDefault();
|
|
36
|
-
onClick();
|
|
37
|
-
}, [onClick]);
|
|
38
|
-
var computedPlaceholderMessage = placeholderMessage ? placeholderMessage : messages.placeholder;
|
|
39
|
-
|
|
40
|
-
// This issue is a temporary fix for users being able to edit captions on edge browsers. This will be removed
|
|
41
|
-
// replaced with CaptionPlaceholderButton in the near future and this code can be removed.
|
|
42
|
-
return (
|
|
43
|
-
// eslint-disable-next-line @atlaskit/design-system/use-primitives-text
|
|
44
|
-
jsx("span", {
|
|
45
|
-
ref: ref,
|
|
46
|
-
css: placeholder,
|
|
47
|
-
onPointerDown: handlePointerDown
|
|
48
|
-
// This id is just used for setting styles at the moment, if it's needed for anything more specific
|
|
49
|
-
// It may need to be generated to avoid overlap
|
|
50
|
-
,
|
|
51
|
-
id: CAPTION_PLACEHOLDER_ID,
|
|
52
|
-
"data-id": CAPTION_PLACEHOLDER_ID,
|
|
53
|
-
"data-testid": "caption-placeholder"
|
|
54
|
-
}, jsx(FormattedMessage
|
|
55
|
-
// Ignored via go/ees005
|
|
56
|
-
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
57
|
-
, computedPlaceholderMessage))
|
|
58
|
-
);
|
|
59
|
-
});
|
|
60
|
-
export var CaptionPlaceholderButton = /*#__PURE__*/React.forwardRef(function (_ref2, ref) {
|
|
61
|
-
var onClick = _ref2.onClick,
|
|
62
|
-
placeholderMessage = _ref2.placeholderMessage;
|
|
63
25
|
var handleMouseDown = useCallback(function (e) {
|
|
64
26
|
// In firefox, button is focused when mouse down, which make editor lose focus
|
|
65
27
|
// Hence we want to disabled it so that user can type in caption directly after click
|
|
@@ -11,6 +11,5 @@ type CaptionPlaceholderProps = {
|
|
|
11
11
|
id: string;
|
|
12
12
|
};
|
|
13
13
|
};
|
|
14
|
-
export declare const CaptionPlaceholder: React.ForwardRefExoticComponent<CaptionPlaceholderProps & React.RefAttributes<HTMLSpanElement>>;
|
|
15
14
|
export declare const CaptionPlaceholderButton: React.ForwardRefExoticComponent<CaptionPlaceholderProps & React.RefAttributes<HTMLButtonElement>>;
|
|
16
15
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-media",
|
|
3
|
-
"version": "14.3.
|
|
3
|
+
"version": "14.3.2",
|
|
4
4
|
"description": "Media plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -44,9 +44,9 @@
|
|
|
44
44
|
"@atlaskit/editor-shared-styles": "^4.0.0",
|
|
45
45
|
"@atlaskit/editor-tables": "^3.0.0",
|
|
46
46
|
"@atlaskit/form": "^16.1.0",
|
|
47
|
-
"@atlaskit/icon": "^
|
|
47
|
+
"@atlaskit/icon": "^37.0.0",
|
|
48
48
|
"@atlaskit/icon-lab": "^7.3.0",
|
|
49
|
-
"@atlaskit/media-card": "^81.
|
|
49
|
+
"@atlaskit/media-card": "^81.4.0",
|
|
50
50
|
"@atlaskit/media-client": "^37.2.0",
|
|
51
51
|
"@atlaskit/media-client-react": "^6.1.0",
|
|
52
52
|
"@atlaskit/media-common": "^14.3.0",
|
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
"uuid": "^3.1.0"
|
|
70
70
|
},
|
|
71
71
|
"peerDependencies": {
|
|
72
|
-
"@atlaskit/editor-common": "^116.
|
|
72
|
+
"@atlaskit/editor-common": "^116.25.0",
|
|
73
73
|
"@atlaskit/media-core": "^38.0.0",
|
|
74
74
|
"react": "^18.2.0",
|
|
75
75
|
"react-dom": "^18.2.0",
|
|
@@ -118,9 +118,6 @@
|
|
|
118
118
|
"platform_media_cross_client_copy_with_auth": {
|
|
119
119
|
"type": "boolean"
|
|
120
120
|
},
|
|
121
|
-
"platform_editor_typography_ugc": {
|
|
122
|
-
"type": "boolean"
|
|
123
|
-
},
|
|
124
121
|
"platform_editor_introduce_insert_media_command": {
|
|
125
122
|
"type": "boolean"
|
|
126
123
|
},
|