@atlaskit/editor-plugin-extension 1.15.0 → 1.15.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 +24 -0
- package/dist/cjs/toolbar.js +16 -6
- package/dist/cjs/ui/ConfigPanel/Fields/Select.js +8 -1
- package/dist/es2019/toolbar.js +17 -7
- package/dist/es2019/ui/ConfigPanel/Fields/Select.js +3 -0
- package/dist/esm/toolbar.js +17 -7
- package/dist/esm/ui/ConfigPanel/Fields/Select.js +8 -1
- package/package.json +8 -8
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,29 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-extension
|
|
2
2
|
|
|
3
|
+
## 1.15.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#153024](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/153024)
|
|
8
|
+
[`f2ca7201459b1`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/f2ca7201459b1) -
|
|
9
|
+
Fix issue where the label for id did not target the input
|
|
10
|
+
- [#153024](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/153024)
|
|
11
|
+
[`f2ca7201459b1`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/f2ca7201459b1) -
|
|
12
|
+
Fix tests where id targeting need to be updated
|
|
13
|
+
- Updated dependencies
|
|
14
|
+
|
|
15
|
+
## 1.15.1
|
|
16
|
+
|
|
17
|
+
### Patch Changes
|
|
18
|
+
|
|
19
|
+
- [#152399](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/152399)
|
|
20
|
+
[`fbd7217f0cb51`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/fbd7217f0cb51) -
|
|
21
|
+
[ux] ED-25092: Migrated table toolbar icons
|
|
22
|
+
- [#152510](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/152510)
|
|
23
|
+
[`dcf9edde7ac7b`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/dcf9edde7ac7b) -
|
|
24
|
+
bump adf-schema to 42.0.1
|
|
25
|
+
- Updated dependencies
|
|
26
|
+
|
|
3
27
|
## 1.15.0
|
|
4
28
|
|
|
5
29
|
### Minor Changes
|
package/dist/cjs/toolbar.js
CHANGED
|
@@ -11,7 +11,12 @@ var _messages = _interopRequireDefault(require("@atlaskit/editor-common/messages
|
|
|
11
11
|
var _styles = require("@atlaskit/editor-common/styles");
|
|
12
12
|
var _utils = require("@atlaskit/editor-common/utils");
|
|
13
13
|
var _utils2 = require("@atlaskit/editor-prosemirror/utils");
|
|
14
|
-
var
|
|
14
|
+
var _contentWidthNarrow = _interopRequireDefault(require("@atlaskit/icon/core/content-width-narrow"));
|
|
15
|
+
var _contentWidthWide = _interopRequireDefault(require("@atlaskit/icon/core/content-width-wide"));
|
|
16
|
+
var _delete = _interopRequireDefault(require("@atlaskit/icon/core/delete"));
|
|
17
|
+
var _edit = _interopRequireDefault(require("@atlaskit/icon/core/edit"));
|
|
18
|
+
var _expandHorizontal = _interopRequireDefault(require("@atlaskit/icon/core/expand-horizontal"));
|
|
19
|
+
var _edit2 = _interopRequireDefault(require("@atlaskit/icon/glyph/editor/edit"));
|
|
15
20
|
var _mediaCenter = _interopRequireDefault(require("@atlaskit/icon/glyph/editor/media-center"));
|
|
16
21
|
var _mediaFullWidth = _interopRequireDefault(require("@atlaskit/icon/glyph/editor/media-full-width"));
|
|
17
22
|
var _mediaWide = _interopRequireDefault(require("@atlaskit/icon/glyph/editor/media-wide"));
|
|
@@ -34,7 +39,7 @@ var isLayoutSupported = function isLayoutSupported(state, selectedExtNode) {
|
|
|
34
39
|
if (!selectedExtNode) {
|
|
35
40
|
return false;
|
|
36
41
|
}
|
|
37
|
-
var isMultiBodiedExtension = (0, _platformFeatureFlags.
|
|
42
|
+
var isMultiBodiedExtension = (0, _platformFeatureFlags.fg)('platform.editor.multi-bodied-extension_0rygg') && selectedExtNode.node.type === multiBodiedExtension;
|
|
38
43
|
var isNonEmbeddedBodiedExtension = selectedExtNode.node.type === bodiedExtension && !(0, _utils2.hasParentNodeOfType)([multiBodiedExtension].filter(Boolean))(selection);
|
|
39
44
|
var isNonEmbeddedExtension = selectedExtNode.node.type === extension && !(0, _utils2.hasParentNodeOfType)([bodiedExtension, table, expand, multiBodiedExtension].filter(Boolean))(selection);
|
|
40
45
|
|
|
@@ -50,21 +55,24 @@ var breakoutOptions = function breakoutOptions(state, formatMessage, extensionSt
|
|
|
50
55
|
var layout = nodeWithPos.node.attrs.layout;
|
|
51
56
|
return [{
|
|
52
57
|
type: 'button',
|
|
53
|
-
icon:
|
|
58
|
+
icon: _contentWidthNarrow.default,
|
|
59
|
+
iconFallback: _mediaCenter.default,
|
|
54
60
|
onClick: (0, _commands.updateExtensionLayout)('default', editorAnalyticsAPI),
|
|
55
61
|
selected: layout === 'default',
|
|
56
62
|
title: formatMessage(_messages.default.layoutFixedWidth),
|
|
57
63
|
tabIndex: null
|
|
58
64
|
}, {
|
|
59
65
|
type: 'button',
|
|
60
|
-
icon:
|
|
66
|
+
icon: _contentWidthWide.default,
|
|
67
|
+
iconFallback: _mediaWide.default,
|
|
61
68
|
onClick: (0, _commands.updateExtensionLayout)('wide', editorAnalyticsAPI),
|
|
62
69
|
selected: layout === 'wide',
|
|
63
70
|
title: formatMessage(_messages.default.layoutWide),
|
|
64
71
|
tabIndex: null
|
|
65
72
|
}, {
|
|
66
73
|
type: 'button',
|
|
67
|
-
icon:
|
|
74
|
+
icon: _expandHorizontal.default,
|
|
75
|
+
iconFallback: _mediaFullWidth.default,
|
|
68
76
|
onClick: (0, _commands.updateExtensionLayout)('full-width', editorAnalyticsAPI),
|
|
69
77
|
selected: layout === 'full-width',
|
|
70
78
|
title: formatMessage(_messages.default.layoutFullWidth),
|
|
@@ -81,6 +89,7 @@ var editButton = function editButton(formatMessage, extensionState, applyChangeT
|
|
|
81
89
|
id: 'editor.extension.edit',
|
|
82
90
|
type: 'button',
|
|
83
91
|
icon: _edit.default,
|
|
92
|
+
iconFallback: _edit2.default,
|
|
84
93
|
testId: 'extension-toolbar-edit-button',
|
|
85
94
|
// Taking the latest `updateExtension` from plugin state to avoid race condition @see ED-8501
|
|
86
95
|
onClick: function onClick(state, dispatch, view) {
|
|
@@ -179,7 +188,8 @@ var getToolbarConfig = exports.getToolbarConfig = function getToolbarConfig(_ref
|
|
|
179
188
|
}, {
|
|
180
189
|
id: 'editor.extension.delete',
|
|
181
190
|
type: 'button',
|
|
182
|
-
icon:
|
|
191
|
+
icon: _delete.default,
|
|
192
|
+
iconFallback: _remove.default,
|
|
183
193
|
appearance: 'danger',
|
|
184
194
|
onClick: (0, _commands.removeExtension)(editorAnalyticsAPI),
|
|
185
195
|
onMouseEnter: hoverDecoration === null || hoverDecoration === void 0 ? void 0 : hoverDecoration(nodeType, true),
|
|
@@ -7,6 +7,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
});
|
|
8
8
|
exports.default = SelectField;
|
|
9
9
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
10
|
+
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
10
11
|
var _react = _interopRequireWildcard(require("react"));
|
|
11
12
|
var _form = require("@atlaskit/form");
|
|
12
13
|
var _select = _interopRequireDefault(require("@atlaskit/select"));
|
|
@@ -15,6 +16,8 @@ var _utils = require("../utils");
|
|
|
15
16
|
var _SelectItem = require("./SelectItem");
|
|
16
17
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
17
18
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
19
|
+
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; }
|
|
20
|
+
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; }
|
|
18
21
|
function SelectField(_ref) {
|
|
19
22
|
var name = _ref.name,
|
|
20
23
|
field = _ref.field,
|
|
@@ -37,7 +40,11 @@ function SelectField(_ref) {
|
|
|
37
40
|
}, function (_ref2) {
|
|
38
41
|
var fieldProps = _ref2.fieldProps,
|
|
39
42
|
error = _ref2.error;
|
|
40
|
-
return /*#__PURE__*/_react.default.createElement(_react.Fragment, null, /*#__PURE__*/_react.default.createElement(_select.default, (0, _extends2.default)({}, fieldProps, {
|
|
43
|
+
return /*#__PURE__*/_react.default.createElement(_react.Fragment, null, /*#__PURE__*/_react.default.createElement(_select.default, (0, _extends2.default)({}, _objectSpread(_objectSpread({}, fieldProps), {}, {
|
|
44
|
+
// Pass `id` as `inputId` so that the input gets the correct id, and make sure there are no duplicate ids
|
|
45
|
+
inputId: fieldProps.id,
|
|
46
|
+
id: undefined
|
|
47
|
+
}), {
|
|
41
48
|
onChange: function onChange(value) {
|
|
42
49
|
fieldProps.onChange(value);
|
|
43
50
|
onFieldChange(name, true);
|
package/dist/es2019/toolbar.js
CHANGED
|
@@ -3,12 +3,17 @@ import commonMessages from '@atlaskit/editor-common/messages';
|
|
|
3
3
|
import { BODIED_EXT_MBE_MARGIN_TOP } from '@atlaskit/editor-common/styles';
|
|
4
4
|
import { getChildrenInfo, getNodeName, isReferencedSource } from '@atlaskit/editor-common/utils';
|
|
5
5
|
import { findParentNodeOfType, hasParentNodeOfType } from '@atlaskit/editor-prosemirror/utils';
|
|
6
|
-
import
|
|
6
|
+
import ContentWidthNarrowIcon from '@atlaskit/icon/core/content-width-narrow';
|
|
7
|
+
import ContentWidthWideIcon from '@atlaskit/icon/core/content-width-wide';
|
|
8
|
+
import DeleteIcon from '@atlaskit/icon/core/delete';
|
|
9
|
+
import EditIcon from '@atlaskit/icon/core/edit';
|
|
10
|
+
import ExpandHorizontalIcon from '@atlaskit/icon/core/expand-horizontal';
|
|
11
|
+
import LegacyEditIcon from '@atlaskit/icon/glyph/editor/edit';
|
|
7
12
|
import CenterIcon from '@atlaskit/icon/glyph/editor/media-center';
|
|
8
13
|
import FullWidthIcon from '@atlaskit/icon/glyph/editor/media-full-width';
|
|
9
14
|
import WideIcon from '@atlaskit/icon/glyph/editor/media-wide';
|
|
10
15
|
import RemoveIcon from '@atlaskit/icon/glyph/editor/remove';
|
|
11
|
-
import {
|
|
16
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
12
17
|
import { editExtension } from './actions';
|
|
13
18
|
import { removeDescendantNodes, removeExtension, updateExtensionLayout } from './commands';
|
|
14
19
|
import { pluginKey as macroPluginKey } from './pm-plugins/macro/plugin-key';
|
|
@@ -31,7 +36,7 @@ const isLayoutSupported = (state, selectedExtNode) => {
|
|
|
31
36
|
if (!selectedExtNode) {
|
|
32
37
|
return false;
|
|
33
38
|
}
|
|
34
|
-
const isMultiBodiedExtension =
|
|
39
|
+
const isMultiBodiedExtension = fg('platform.editor.multi-bodied-extension_0rygg') && selectedExtNode.node.type === multiBodiedExtension;
|
|
35
40
|
const isNonEmbeddedBodiedExtension = selectedExtNode.node.type === bodiedExtension && !hasParentNodeOfType([multiBodiedExtension].filter(Boolean))(selection);
|
|
36
41
|
const isNonEmbeddedExtension = selectedExtNode.node.type === extension && !hasParentNodeOfType([bodiedExtension, table, expand, multiBodiedExtension].filter(Boolean))(selection);
|
|
37
42
|
|
|
@@ -49,21 +54,24 @@ const breakoutOptions = (state, formatMessage, extensionState, breakoutEnabled,
|
|
|
49
54
|
} = nodeWithPos.node.attrs;
|
|
50
55
|
return [{
|
|
51
56
|
type: 'button',
|
|
52
|
-
icon:
|
|
57
|
+
icon: ContentWidthNarrowIcon,
|
|
58
|
+
iconFallback: CenterIcon,
|
|
53
59
|
onClick: updateExtensionLayout('default', editorAnalyticsAPI),
|
|
54
60
|
selected: layout === 'default',
|
|
55
61
|
title: formatMessage(commonMessages.layoutFixedWidth),
|
|
56
62
|
tabIndex: null
|
|
57
63
|
}, {
|
|
58
64
|
type: 'button',
|
|
59
|
-
icon:
|
|
65
|
+
icon: ContentWidthWideIcon,
|
|
66
|
+
iconFallback: WideIcon,
|
|
60
67
|
onClick: updateExtensionLayout('wide', editorAnalyticsAPI),
|
|
61
68
|
selected: layout === 'wide',
|
|
62
69
|
title: formatMessage(commonMessages.layoutWide),
|
|
63
70
|
tabIndex: null
|
|
64
71
|
}, {
|
|
65
72
|
type: 'button',
|
|
66
|
-
icon:
|
|
73
|
+
icon: ExpandHorizontalIcon,
|
|
74
|
+
iconFallback: FullWidthIcon,
|
|
67
75
|
onClick: updateExtensionLayout('full-width', editorAnalyticsAPI),
|
|
68
76
|
selected: layout === 'full-width',
|
|
69
77
|
title: formatMessage(commonMessages.layoutFullWidth),
|
|
@@ -80,6 +88,7 @@ const editButton = (formatMessage, extensionState, applyChangeToContextPanel, ed
|
|
|
80
88
|
id: 'editor.extension.edit',
|
|
81
89
|
type: 'button',
|
|
82
90
|
icon: EditIcon,
|
|
91
|
+
iconFallback: LegacyEditIcon,
|
|
83
92
|
testId: 'extension-toolbar-edit-button',
|
|
84
93
|
// Taking the latest `updateExtension` from plugin state to avoid race condition @see ED-8501
|
|
85
94
|
onClick: (state, dispatch, view) => {
|
|
@@ -176,7 +185,8 @@ export const getToolbarConfig = ({
|
|
|
176
185
|
}, {
|
|
177
186
|
id: 'editor.extension.delete',
|
|
178
187
|
type: 'button',
|
|
179
|
-
icon:
|
|
188
|
+
icon: DeleteIcon,
|
|
189
|
+
iconFallback: RemoveIcon,
|
|
180
190
|
appearance: 'danger',
|
|
181
191
|
onClick: removeExtension(editorAnalyticsAPI),
|
|
182
192
|
onMouseEnter: hoverDecoration === null || hoverDecoration === void 0 ? void 0 : hoverDecoration(nodeType, true),
|
|
@@ -29,6 +29,9 @@ export default function SelectField({
|
|
|
29
29
|
fieldProps,
|
|
30
30
|
error
|
|
31
31
|
}) => /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement(Select, _extends({}, fieldProps, {
|
|
32
|
+
// Pass `id` as `inputId` so that the input gets the correct id, and make sure there are no duplicate ids
|
|
33
|
+
inputId: fieldProps.id,
|
|
34
|
+
id: undefined,
|
|
32
35
|
onChange: value => {
|
|
33
36
|
fieldProps.onChange(value);
|
|
34
37
|
onFieldChange(name, true);
|
package/dist/esm/toolbar.js
CHANGED
|
@@ -4,12 +4,17 @@ import commonMessages from '@atlaskit/editor-common/messages';
|
|
|
4
4
|
import { BODIED_EXT_MBE_MARGIN_TOP } from '@atlaskit/editor-common/styles';
|
|
5
5
|
import { getChildrenInfo as _getChildrenInfo, getNodeName, isReferencedSource } from '@atlaskit/editor-common/utils';
|
|
6
6
|
import { findParentNodeOfType, hasParentNodeOfType } from '@atlaskit/editor-prosemirror/utils';
|
|
7
|
-
import
|
|
7
|
+
import ContentWidthNarrowIcon from '@atlaskit/icon/core/content-width-narrow';
|
|
8
|
+
import ContentWidthWideIcon from '@atlaskit/icon/core/content-width-wide';
|
|
9
|
+
import DeleteIcon from '@atlaskit/icon/core/delete';
|
|
10
|
+
import EditIcon from '@atlaskit/icon/core/edit';
|
|
11
|
+
import ExpandHorizontalIcon from '@atlaskit/icon/core/expand-horizontal';
|
|
12
|
+
import LegacyEditIcon from '@atlaskit/icon/glyph/editor/edit';
|
|
8
13
|
import CenterIcon from '@atlaskit/icon/glyph/editor/media-center';
|
|
9
14
|
import FullWidthIcon from '@atlaskit/icon/glyph/editor/media-full-width';
|
|
10
15
|
import WideIcon from '@atlaskit/icon/glyph/editor/media-wide';
|
|
11
16
|
import RemoveIcon from '@atlaskit/icon/glyph/editor/remove';
|
|
12
|
-
import {
|
|
17
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
13
18
|
import { editExtension } from './actions';
|
|
14
19
|
import { removeDescendantNodes, removeExtension, updateExtensionLayout } from './commands';
|
|
15
20
|
import { pluginKey as macroPluginKey } from './pm-plugins/macro/plugin-key';
|
|
@@ -27,7 +32,7 @@ var isLayoutSupported = function isLayoutSupported(state, selectedExtNode) {
|
|
|
27
32
|
if (!selectedExtNode) {
|
|
28
33
|
return false;
|
|
29
34
|
}
|
|
30
|
-
var isMultiBodiedExtension =
|
|
35
|
+
var isMultiBodiedExtension = fg('platform.editor.multi-bodied-extension_0rygg') && selectedExtNode.node.type === multiBodiedExtension;
|
|
31
36
|
var isNonEmbeddedBodiedExtension = selectedExtNode.node.type === bodiedExtension && !hasParentNodeOfType([multiBodiedExtension].filter(Boolean))(selection);
|
|
32
37
|
var isNonEmbeddedExtension = selectedExtNode.node.type === extension && !hasParentNodeOfType([bodiedExtension, table, expand, multiBodiedExtension].filter(Boolean))(selection);
|
|
33
38
|
|
|
@@ -43,21 +48,24 @@ var breakoutOptions = function breakoutOptions(state, formatMessage, extensionSt
|
|
|
43
48
|
var layout = nodeWithPos.node.attrs.layout;
|
|
44
49
|
return [{
|
|
45
50
|
type: 'button',
|
|
46
|
-
icon:
|
|
51
|
+
icon: ContentWidthNarrowIcon,
|
|
52
|
+
iconFallback: CenterIcon,
|
|
47
53
|
onClick: updateExtensionLayout('default', editorAnalyticsAPI),
|
|
48
54
|
selected: layout === 'default',
|
|
49
55
|
title: formatMessage(commonMessages.layoutFixedWidth),
|
|
50
56
|
tabIndex: null
|
|
51
57
|
}, {
|
|
52
58
|
type: 'button',
|
|
53
|
-
icon:
|
|
59
|
+
icon: ContentWidthWideIcon,
|
|
60
|
+
iconFallback: WideIcon,
|
|
54
61
|
onClick: updateExtensionLayout('wide', editorAnalyticsAPI),
|
|
55
62
|
selected: layout === 'wide',
|
|
56
63
|
title: formatMessage(commonMessages.layoutWide),
|
|
57
64
|
tabIndex: null
|
|
58
65
|
}, {
|
|
59
66
|
type: 'button',
|
|
60
|
-
icon:
|
|
67
|
+
icon: ExpandHorizontalIcon,
|
|
68
|
+
iconFallback: FullWidthIcon,
|
|
61
69
|
onClick: updateExtensionLayout('full-width', editorAnalyticsAPI),
|
|
62
70
|
selected: layout === 'full-width',
|
|
63
71
|
title: formatMessage(commonMessages.layoutFullWidth),
|
|
@@ -74,6 +82,7 @@ var editButton = function editButton(formatMessage, extensionState, applyChangeT
|
|
|
74
82
|
id: 'editor.extension.edit',
|
|
75
83
|
type: 'button',
|
|
76
84
|
icon: EditIcon,
|
|
85
|
+
iconFallback: LegacyEditIcon,
|
|
77
86
|
testId: 'extension-toolbar-edit-button',
|
|
78
87
|
// Taking the latest `updateExtension` from plugin state to avoid race condition @see ED-8501
|
|
79
88
|
onClick: function onClick(state, dispatch, view) {
|
|
@@ -172,7 +181,8 @@ export var getToolbarConfig = function getToolbarConfig(_ref) {
|
|
|
172
181
|
}, {
|
|
173
182
|
id: 'editor.extension.delete',
|
|
174
183
|
type: 'button',
|
|
175
|
-
icon:
|
|
184
|
+
icon: DeleteIcon,
|
|
185
|
+
iconFallback: RemoveIcon,
|
|
176
186
|
appearance: 'danger',
|
|
177
187
|
onClick: removeExtension(editorAnalyticsAPI),
|
|
178
188
|
onMouseEnter: hoverDecoration === null || hoverDecoration === void 0 ? void 0 : hoverDecoration(nodeType, true),
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
+
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
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
|
+
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; }
|
|
2
5
|
import React, { Fragment } from 'react';
|
|
3
6
|
import { Field } from '@atlaskit/form';
|
|
4
7
|
import Select from '@atlaskit/select';
|
|
@@ -27,7 +30,11 @@ export default function SelectField(_ref) {
|
|
|
27
30
|
}, function (_ref2) {
|
|
28
31
|
var fieldProps = _ref2.fieldProps,
|
|
29
32
|
error = _ref2.error;
|
|
30
|
-
return /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement(Select, _extends({}, fieldProps, {
|
|
33
|
+
return /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement(Select, _extends({}, _objectSpread(_objectSpread({}, fieldProps), {}, {
|
|
34
|
+
// Pass `id` as `inputId` so that the input gets the correct id, and make sure there are no duplicate ids
|
|
35
|
+
inputId: fieldProps.id,
|
|
36
|
+
id: undefined
|
|
37
|
+
}), {
|
|
31
38
|
onChange: function onChange(value) {
|
|
32
39
|
fieldProps.onChange(value);
|
|
33
40
|
onFieldChange(name, true);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-extension",
|
|
3
|
-
"version": "1.15.
|
|
3
|
+
"version": "1.15.2",
|
|
4
4
|
"description": "editor-plugin-extension plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -23,16 +23,16 @@
|
|
|
23
23
|
".": "./src/index.ts"
|
|
24
24
|
},
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@atlaskit/adf-schema": "^
|
|
26
|
+
"@atlaskit/adf-schema": "^42.0.2",
|
|
27
27
|
"@atlaskit/adf-utils": "^19.9.0",
|
|
28
28
|
"@atlaskit/analytics-next": "^10.1.0",
|
|
29
29
|
"@atlaskit/avatar": "^21.15.0",
|
|
30
30
|
"@atlaskit/button": "^20.2.0",
|
|
31
31
|
"@atlaskit/checkbox": "^14.0.0",
|
|
32
|
-
"@atlaskit/datetime-picker": "^15.
|
|
33
|
-
"@atlaskit/editor-common": "^93.
|
|
34
|
-
"@atlaskit/editor-json-transformer": "^8.
|
|
35
|
-
"@atlaskit/editor-plugin-analytics": "^1.
|
|
32
|
+
"@atlaskit/datetime-picker": "^15.4.0",
|
|
33
|
+
"@atlaskit/editor-common": "^93.6.0",
|
|
34
|
+
"@atlaskit/editor-json-transformer": "^8.20.0",
|
|
35
|
+
"@atlaskit/editor-plugin-analytics": "^1.10.0",
|
|
36
36
|
"@atlaskit/editor-plugin-context-identifier": "^1.3.0",
|
|
37
37
|
"@atlaskit/editor-plugin-context-panel": "^1.3.0",
|
|
38
38
|
"@atlaskit/editor-plugin-decorations": "^1.3.0",
|
|
@@ -55,8 +55,8 @@
|
|
|
55
55
|
"@atlaskit/tabs": "^16.5.0",
|
|
56
56
|
"@atlaskit/textarea": "^5.6.0",
|
|
57
57
|
"@atlaskit/textfield": "^6.5.0",
|
|
58
|
-
"@atlaskit/theme": "^13.
|
|
59
|
-
"@atlaskit/tmp-editor-statsig": "^2.
|
|
58
|
+
"@atlaskit/theme": "^13.1.0",
|
|
59
|
+
"@atlaskit/tmp-editor-statsig": "^2.6.0",
|
|
60
60
|
"@atlaskit/toggle": "^13.4.0",
|
|
61
61
|
"@atlaskit/tokens": "^2.0.0",
|
|
62
62
|
"@atlaskit/tooltip": "^18.8.0",
|