@atlaskit/editor-common 78.17.0 → 78.17.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/analytics/package.json +1 -1
- package/annotation/package.json +1 -1
- package/card/package.json +1 -1
- package/clipboard/package.json +1 -1
- package/collab/package.json +1 -1
- package/commands/package.json +1 -1
- package/constants/package.json +1 -1
- package/copy-button/package.json +1 -1
- package/core-utils/package.json +1 -1
- package/dist/cjs/extensibility/Extension/Extension/index.js +17 -12
- package/dist/cjs/extensibility/MultiBodiedExtension/index.js +16 -12
- package/dist/cjs/hooks/useSharedPluginState.js +3 -0
- package/dist/cjs/monitoring/error.js +1 -1
- package/dist/cjs/ui/DropList/index.js +1 -1
- package/dist/es2019/extensibility/Extension/Extension/index.js +16 -11
- package/dist/es2019/extensibility/MultiBodiedExtension/index.js +15 -11
- package/dist/es2019/hooks/useSharedPluginState.js +5 -0
- package/dist/es2019/monitoring/error.js +1 -1
- package/dist/es2019/ui/DropList/index.js +1 -1
- package/dist/esm/extensibility/Extension/Extension/index.js +17 -12
- package/dist/esm/extensibility/MultiBodiedExtension/index.js +16 -12
- package/dist/esm/hooks/useSharedPluginState.js +3 -0
- package/dist/esm/monitoring/error.js +1 -1
- package/dist/esm/ui/DropList/index.js +1 -1
- package/dist/types/analytics/types/enums.d.ts +2 -2
- package/dist/types/annotation/index.d.ts +2 -0
- package/dist/types/commands/index.d.ts +3 -3
- package/dist/types/element-browser/components/ElementSearch.d.ts +1 -1
- package/dist/types/floating-toolbar/index.d.ts +1 -1
- package/dist/types/link/LinkSearch/LinkSearchListItem.d.ts +2 -2
- package/dist/types/preset/plugin-injection-api.d.ts +1 -1
- package/dist/types/provider-helpers/promise-helpers.d.ts +2 -2
- package/dist/types/styles/shared/resizer.d.ts +3 -3
- package/dist/types/ui/Caption/index.d.ts +2 -2
- package/dist/types/ui/UnsupportedBlock/index.d.ts +2 -2
- package/dist/types/ui/UnsupportedInline/index.d.ts +2 -2
- package/dist/types/ui-color/ColorPalette/index.d.ts +2 -2
- package/dist/types/utils/compare-props.d.ts +2 -2
- package/dist/types/utils/imageLoader.d.ts +1 -1
- package/dist/types-ts4.5/analytics/types/enums.d.ts +2 -2
- package/dist/types-ts4.5/annotation/index.d.ts +2 -0
- package/dist/types-ts4.5/commands/index.d.ts +3 -3
- package/dist/types-ts4.5/element-browser/components/ElementSearch.d.ts +1 -1
- package/dist/types-ts4.5/floating-toolbar/index.d.ts +1 -1
- package/dist/types-ts4.5/link/LinkSearch/LinkSearchListItem.d.ts +2 -2
- package/dist/types-ts4.5/preset/plugin-injection-api.d.ts +2 -2
- package/dist/types-ts4.5/provider-helpers/promise-helpers.d.ts +2 -2
- package/dist/types-ts4.5/styles/shared/resizer.d.ts +3 -3
- package/dist/types-ts4.5/ui/Caption/index.d.ts +2 -2
- package/dist/types-ts4.5/ui/UnsupportedBlock/index.d.ts +2 -2
- package/dist/types-ts4.5/ui/UnsupportedInline/index.d.ts +2 -2
- package/dist/types-ts4.5/ui-color/ColorPalette/index.d.ts +2 -2
- package/dist/types-ts4.5/utils/compare-props.d.ts +2 -2
- package/dist/types-ts4.5/utils/imageLoader.d.ts +1 -1
- package/doc-utils/package.json +1 -1
- package/editor-analytics/package.json +1 -1
- package/element-browser/package.json +1 -1
- package/emoji/package.json +1 -1
- package/error-boundary/package.json +1 -1
- package/event-dispatcher/package.json +1 -1
- package/extensibility/package.json +1 -1
- package/extensions/package.json +1 -1
- package/floating-toolbar/package.json +1 -1
- package/guideline/package.json +1 -1
- package/hooks/package.json +1 -1
- package/icons/package.json +1 -1
- package/in-product/package.json +1 -1
- package/indentation/package.json +1 -1
- package/insert/package.json +1 -1
- package/keymaps/package.json +1 -1
- package/legacy-rank-plugins/package.json +1 -1
- package/link/package.json +1 -1
- package/lists/package.json +1 -1
- package/mark/package.json +1 -1
- package/media/package.json +1 -1
- package/media-inline/package.json +1 -1
- package/media-single/package.json +1 -1
- package/mention/package.json +1 -1
- package/messages/package.json +1 -1
- package/monitoring/package.json +1 -1
- package/node-width/package.json +1 -1
- package/normalize-feature-flags/package.json +1 -1
- package/package.json +5 -5
- package/panel/package.json +1 -1
- package/paste/package.json +1 -1
- package/portal-provider/package.json +1 -1
- package/preset/package.json +1 -1
- package/provider-factory/package.json +1 -1
- package/provider-helpers/package.json +1 -1
- package/quick-insert/package.json +1 -1
- package/react-node-view/package.json +1 -1
- package/resizer/package.json +1 -1
- package/safe-plugin/package.json +1 -1
- package/selection/package.json +1 -1
- package/selection-based-node-view/package.json +1 -1
- package/styles/package.json +1 -1
- package/transforms/package.json +1 -1
- package/type-ahead/package.json +1 -1
- package/types/package.json +1 -1
- package/ufo/package.json +1 -1
- package/ui/package.json +1 -1
- package/ui-color/package.json +1 -1
- package/ui-menu/package.json +1 -1
- package/ui-react/package.json +1 -1
- package/utils/package.json +1 -1
- package/validator/package.json +1 -1
- package/with-plugin-state/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# @atlaskit/editor-common
|
|
2
2
|
|
|
3
|
+
## 78.17.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#83116](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/83116) [`8d4e99057fe0`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/8d4e99057fe0) - Upgrade Typescript from `4.9.5` to `5.4.2`
|
|
8
|
+
- Updated dependencies
|
|
9
|
+
|
|
10
|
+
## 78.17.1
|
|
11
|
+
|
|
12
|
+
### Patch Changes
|
|
13
|
+
|
|
14
|
+
- Updated dependencies
|
|
15
|
+
|
|
3
16
|
## 78.17.0
|
|
4
17
|
|
|
5
18
|
### Minor Changes
|
package/analytics/package.json
CHANGED
package/annotation/package.json
CHANGED
package/card/package.json
CHANGED
package/clipboard/package.json
CHANGED
package/collab/package.json
CHANGED
package/commands/package.json
CHANGED
package/constants/package.json
CHANGED
package/copy-button/package.json
CHANGED
package/core-utils/package.json
CHANGED
|
@@ -165,19 +165,24 @@ var widthPluginKey = {
|
|
|
165
165
|
}
|
|
166
166
|
};
|
|
167
167
|
var ExtensionDeprecated = function ExtensionDeprecated(props) {
|
|
168
|
-
return (
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
168
|
+
return (
|
|
169
|
+
// @ts-ignore - 'WithPluginState' cannot be used as a JSX component.
|
|
170
|
+
// This error was introduced after upgrading to TypeScript 5
|
|
171
|
+
(0, _react2.jsx)(_withPluginState.WithPluginState, {
|
|
172
|
+
editorView: props.view,
|
|
173
|
+
plugins: {
|
|
174
|
+
widthState: widthPluginKey
|
|
175
|
+
},
|
|
176
|
+
render: function render(_ref) {
|
|
177
|
+
var widthState = _ref.widthState;
|
|
178
|
+
return (0, _react2.jsx)(ExtensionWithPluginState, (0, _extends2.default)({
|
|
179
|
+
widthState: widthState
|
|
180
|
+
}, props));
|
|
181
|
+
}
|
|
182
|
+
})
|
|
183
|
+
);
|
|
180
184
|
};
|
|
185
|
+
|
|
181
186
|
/**
|
|
182
187
|
* End workaround
|
|
183
188
|
*/
|
|
@@ -197,18 +197,22 @@ var widthPluginKey = {
|
|
|
197
197
|
}
|
|
198
198
|
};
|
|
199
199
|
var MultiBodiedExtensionDeprecated = function MultiBodiedExtensionDeprecated(props) {
|
|
200
|
-
return (
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
200
|
+
return (
|
|
201
|
+
// @ts-ignore - 'WithPluginState' cannot be used as a JSX component.
|
|
202
|
+
// This error was introduced after upgrading to TypeScript 5
|
|
203
|
+
(0, _react2.jsx)(_withPluginState.WithPluginState, {
|
|
204
|
+
editorView: props.editorView,
|
|
205
|
+
plugins: {
|
|
206
|
+
widthState: widthPluginKey
|
|
207
|
+
},
|
|
208
|
+
render: function render(_ref2) {
|
|
209
|
+
var widthState = _ref2.widthState;
|
|
210
|
+
return (0, _react2.jsx)(MultiBodiedExtensionWithWidth, (0, _extends2.default)({
|
|
211
|
+
widthState: widthState
|
|
212
|
+
}, props));
|
|
213
|
+
}
|
|
214
|
+
})
|
|
215
|
+
);
|
|
212
216
|
};
|
|
213
217
|
/**
|
|
214
218
|
* End workaround
|
|
@@ -109,6 +109,9 @@ function useSharedPluginState(injectionApi, plugins) {
|
|
|
109
109
|
return _objectSpread(_objectSpread({}, acc), {}, (0, _defineProperty2.default)({}, "".concat(pluginName, "State"), injectionApi === null || injectionApi === void 0 ? void 0 : injectionApi[pluginName]));
|
|
110
110
|
}, {});
|
|
111
111
|
}, [injectionApi, pluginNames]);
|
|
112
|
+
|
|
113
|
+
// @ts-expect-error - Type '`${K}State`' is not assignable to type '`${K}State`'. Two different types with this name exist, but they are unrelated.
|
|
114
|
+
// This error was introduced after upgrading to TypeScript 5
|
|
112
115
|
return useSharedPluginStateInternal(namedExternalPlugins);
|
|
113
116
|
}
|
|
114
117
|
function useSharedPluginStateInternal(externalPlugins) {
|
|
@@ -16,7 +16,7 @@ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return
|
|
|
16
16
|
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 && Object.prototype.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; }
|
|
17
17
|
var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
|
|
18
18
|
var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
|
|
19
|
-
var packageVersion = "78.17.
|
|
19
|
+
var packageVersion = "78.17.2";
|
|
20
20
|
var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
|
|
21
21
|
// Remove URL as it has UGC
|
|
22
22
|
// TODO: Sanitise the URL instead of just removing it
|
|
@@ -22,7 +22,7 @@ var _templateObject, _templateObject2, _templateObject3;
|
|
|
22
22
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
23
23
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /** @jsx jsx */
|
|
24
24
|
var packageName = "@atlaskit/editor-common";
|
|
25
|
-
var packageVersion = "78.17.
|
|
25
|
+
var packageVersion = "78.17.2";
|
|
26
26
|
var halfFocusRing = 1;
|
|
27
27
|
var dropOffset = '0, 8';
|
|
28
28
|
var DropList = /*#__PURE__*/function (_Component) {
|
|
@@ -162,18 +162,23 @@ const widthPluginKey = {
|
|
|
162
162
|
}
|
|
163
163
|
};
|
|
164
164
|
const ExtensionDeprecated = props => {
|
|
165
|
-
return
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
165
|
+
return (
|
|
166
|
+
// @ts-ignore - 'WithPluginState' cannot be used as a JSX component.
|
|
167
|
+
// This error was introduced after upgrading to TypeScript 5
|
|
168
|
+
jsx(WithPluginState, {
|
|
169
|
+
editorView: props.view,
|
|
170
|
+
plugins: {
|
|
171
|
+
widthState: widthPluginKey
|
|
172
|
+
},
|
|
173
|
+
render: ({
|
|
174
|
+
widthState
|
|
175
|
+
}) => jsx(ExtensionWithPluginState, _extends({
|
|
176
|
+
widthState: widthState
|
|
177
|
+
}, props))
|
|
178
|
+
})
|
|
179
|
+
);
|
|
176
180
|
};
|
|
181
|
+
|
|
177
182
|
/**
|
|
178
183
|
* End workaround
|
|
179
184
|
*/
|
|
@@ -188,17 +188,21 @@ const widthPluginKey = {
|
|
|
188
188
|
}
|
|
189
189
|
};
|
|
190
190
|
const MultiBodiedExtensionDeprecated = props => {
|
|
191
|
-
return
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
191
|
+
return (
|
|
192
|
+
// @ts-ignore - 'WithPluginState' cannot be used as a JSX component.
|
|
193
|
+
// This error was introduced after upgrading to TypeScript 5
|
|
194
|
+
jsx(WithPluginState, {
|
|
195
|
+
editorView: props.editorView,
|
|
196
|
+
plugins: {
|
|
197
|
+
widthState: widthPluginKey
|
|
198
|
+
},
|
|
199
|
+
render: ({
|
|
200
|
+
widthState
|
|
201
|
+
}) => jsx(MultiBodiedExtensionWithWidth, _extends({
|
|
202
|
+
widthState: widthState
|
|
203
|
+
}, props))
|
|
204
|
+
})
|
|
205
|
+
);
|
|
202
206
|
};
|
|
203
207
|
/**
|
|
204
208
|
* End workaround
|
|
@@ -91,8 +91,13 @@ export function useSharedPluginState(injectionApi, plugins) {
|
|
|
91
91
|
// Create a memoized object containing the named plugins
|
|
92
92
|
const namedExternalPlugins = useMemo(() => pluginNames.reduce((acc, pluginName) => ({
|
|
93
93
|
...acc,
|
|
94
|
+
// @ts-expect-error - Implicit conversion of a 'symbol' to a 'string' will fail at runtime. Consider wrapping this expression in 'String(...)'
|
|
95
|
+
// This error was introduced after upgrading to TypeScript 5
|
|
94
96
|
[`${pluginName}State`]: injectionApi === null || injectionApi === void 0 ? void 0 : injectionApi[pluginName]
|
|
95
97
|
}), {}), [injectionApi, pluginNames]);
|
|
98
|
+
|
|
99
|
+
// @ts-expect-error - Type '`${K}State`' is not assignable to type '`${K}State`'. Two different types with this name exist, but they are unrelated.
|
|
100
|
+
// This error was introduced after upgrading to TypeScript 5
|
|
96
101
|
return useSharedPluginStateInternal(namedExternalPlugins);
|
|
97
102
|
}
|
|
98
103
|
function useSharedPluginStateInternal(externalPlugins) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
const SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
|
|
2
2
|
const packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
|
|
3
|
-
const packageVersion = "78.17.
|
|
3
|
+
const packageVersion = "78.17.2";
|
|
4
4
|
const sanitiseSentryEvents = (data, _hint) => {
|
|
5
5
|
// Remove URL as it has UGC
|
|
6
6
|
// TODO: Sanitise the URL instead of just removing it
|
|
@@ -7,7 +7,7 @@ import { createAndFireEvent, withAnalyticsContext, withAnalyticsEvents } from '@
|
|
|
7
7
|
import { N0, N50A, N60A, N900 } from '@atlaskit/theme/colors';
|
|
8
8
|
import Layer from '../Layer';
|
|
9
9
|
const packageName = "@atlaskit/editor-common";
|
|
10
|
-
const packageVersion = "78.17.
|
|
10
|
+
const packageVersion = "78.17.2";
|
|
11
11
|
const halfFocusRing = 1;
|
|
12
12
|
const dropOffset = '0, 8';
|
|
13
13
|
class DropList extends Component {
|
|
@@ -156,19 +156,24 @@ var widthPluginKey = {
|
|
|
156
156
|
}
|
|
157
157
|
};
|
|
158
158
|
var ExtensionDeprecated = function ExtensionDeprecated(props) {
|
|
159
|
-
return
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
159
|
+
return (
|
|
160
|
+
// @ts-ignore - 'WithPluginState' cannot be used as a JSX component.
|
|
161
|
+
// This error was introduced after upgrading to TypeScript 5
|
|
162
|
+
jsx(WithPluginState, {
|
|
163
|
+
editorView: props.view,
|
|
164
|
+
plugins: {
|
|
165
|
+
widthState: widthPluginKey
|
|
166
|
+
},
|
|
167
|
+
render: function render(_ref) {
|
|
168
|
+
var widthState = _ref.widthState;
|
|
169
|
+
return jsx(ExtensionWithPluginState, _extends({
|
|
170
|
+
widthState: widthState
|
|
171
|
+
}, props));
|
|
172
|
+
}
|
|
173
|
+
})
|
|
174
|
+
);
|
|
171
175
|
};
|
|
176
|
+
|
|
172
177
|
/**
|
|
173
178
|
* End workaround
|
|
174
179
|
*/
|
|
@@ -188,18 +188,22 @@ var widthPluginKey = {
|
|
|
188
188
|
}
|
|
189
189
|
};
|
|
190
190
|
var MultiBodiedExtensionDeprecated = function MultiBodiedExtensionDeprecated(props) {
|
|
191
|
-
return
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
191
|
+
return (
|
|
192
|
+
// @ts-ignore - 'WithPluginState' cannot be used as a JSX component.
|
|
193
|
+
// This error was introduced after upgrading to TypeScript 5
|
|
194
|
+
jsx(WithPluginState, {
|
|
195
|
+
editorView: props.editorView,
|
|
196
|
+
plugins: {
|
|
197
|
+
widthState: widthPluginKey
|
|
198
|
+
},
|
|
199
|
+
render: function render(_ref2) {
|
|
200
|
+
var widthState = _ref2.widthState;
|
|
201
|
+
return jsx(MultiBodiedExtensionWithWidth, _extends({
|
|
202
|
+
widthState: widthState
|
|
203
|
+
}, props));
|
|
204
|
+
}
|
|
205
|
+
})
|
|
206
|
+
);
|
|
203
207
|
};
|
|
204
208
|
/**
|
|
205
209
|
* End workaround
|
|
@@ -102,6 +102,9 @@ export function useSharedPluginState(injectionApi, plugins) {
|
|
|
102
102
|
return _objectSpread(_objectSpread({}, acc), {}, _defineProperty({}, "".concat(pluginName, "State"), injectionApi === null || injectionApi === void 0 ? void 0 : injectionApi[pluginName]));
|
|
103
103
|
}, {});
|
|
104
104
|
}, [injectionApi, pluginNames]);
|
|
105
|
+
|
|
106
|
+
// @ts-expect-error - Type '`${K}State`' is not assignable to type '`${K}State`'. Two different types with this name exist, but they are unrelated.
|
|
107
|
+
// This error was introduced after upgrading to TypeScript 5
|
|
105
108
|
return useSharedPluginStateInternal(namedExternalPlugins);
|
|
106
109
|
}
|
|
107
110
|
function useSharedPluginStateInternal(externalPlugins) {
|
|
@@ -6,7 +6,7 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
|
|
|
6
6
|
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; }
|
|
7
7
|
var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
|
|
8
8
|
var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
|
|
9
|
-
var packageVersion = "78.17.
|
|
9
|
+
var packageVersion = "78.17.2";
|
|
10
10
|
var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
|
|
11
11
|
// Remove URL as it has UGC
|
|
12
12
|
// TODO: Sanitise the URL instead of just removing it
|
|
@@ -17,7 +17,7 @@ import { createAndFireEvent, withAnalyticsContext, withAnalyticsEvents } from '@
|
|
|
17
17
|
import { N0, N50A, N60A, N900 } from '@atlaskit/theme/colors';
|
|
18
18
|
import Layer from '../Layer';
|
|
19
19
|
var packageName = "@atlaskit/editor-common";
|
|
20
|
-
var packageVersion = "78.17.
|
|
20
|
+
var packageVersion = "78.17.2";
|
|
21
21
|
var halfFocusRing = 1;
|
|
22
22
|
var dropOffset = '0, 8';
|
|
23
23
|
var DropList = /*#__PURE__*/function (_Component) {
|
|
@@ -174,8 +174,8 @@ export declare enum INPUT_METHOD {
|
|
|
174
174
|
}
|
|
175
175
|
export declare enum TRIGGER_METHOD {
|
|
176
176
|
BUTTON = "button",
|
|
177
|
-
KEYBOARD = "keyboard",
|
|
178
|
-
SHORTCUT = "shortcut",
|
|
177
|
+
KEYBOARD = "keyboard",// single key, e.g. Esc, Enter
|
|
178
|
+
SHORTCUT = "shortcut",// combination of keys, e.g. Mod + F
|
|
179
179
|
TOOLBAR = "toolbar"
|
|
180
180
|
}
|
|
181
181
|
export declare enum ACTION_SUBJECT {
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
+
/// <reference path="../../../../../../typings/events.d.ts" />
|
|
1
2
|
/// <reference types="node" />
|
|
3
|
+
/// <reference types="node/events" />
|
|
2
4
|
import { EventEmitter } from 'events';
|
|
3
5
|
export type UpdateEvent = 'create' | 'delete' | 'resolve' | 'unresolve' | 'setselectedannotation';
|
|
4
6
|
export type VisibilityEvent = 'setvisibility';
|
|
@@ -6,8 +6,8 @@ type AlignmentState = 'start' | 'end' | 'center';
|
|
|
6
6
|
export declare function addParagraphAtEnd(tr: Transaction): void;
|
|
7
7
|
export declare function createParagraphAtEnd(): Command;
|
|
8
8
|
export declare const changeImageAlignment: (align?: AlignmentState) => Command;
|
|
9
|
-
export declare const createToggleBlockMarkOnRange: <T extends {} = object>(markType: MarkType, getAttrs: (prevAttrs?: T
|
|
10
|
-
export declare const createToggleInlineMarkOnRange: <T extends {} = object>(markType: MarkType, getAttrs: (prevAttrs?: T
|
|
9
|
+
export declare const createToggleBlockMarkOnRange: <T extends {} = object>(markType: MarkType, getAttrs: (prevAttrs?: T, node?: PMNode) => T | undefined | false, allowedBlocks?: NodeType[] | ((schema: Schema, node: PMNode, parent: PMNode | null) => boolean) | undefined) => (from: number, to: number, tr: Transaction, state: EditorState) => boolean;
|
|
10
|
+
export declare const createToggleInlineMarkOnRange: <T extends {} = object>(markType: MarkType, getAttrs: (prevAttrs?: T, node?: PMNode) => T | undefined | false) => (from: number, to: number, tr: Transaction, state: EditorState) => boolean;
|
|
11
11
|
/**
|
|
12
12
|
* Toggles block mark based on the return type of `getAttrs`.
|
|
13
13
|
* This is similar to ProseMirror's `getAttrs` from `AttributeSpec`
|
|
@@ -15,7 +15,7 @@ export declare const createToggleInlineMarkOnRange: <T extends {} = object>(mark
|
|
|
15
15
|
* return `undefined for no-op.
|
|
16
16
|
* return an `object` to update the mark.
|
|
17
17
|
*/
|
|
18
|
-
export declare const toggleBlockMark: <T extends {} = object>(markType: MarkType, getAttrs: (prevAttrs?: T
|
|
18
|
+
export declare const toggleBlockMark: <T extends {} = object>(markType: MarkType, getAttrs: (prevAttrs?: T, node?: PMNode) => T | undefined | false, allowedBlocks?: NodeType[] | ((schema: Schema, node: PMNode, parent: PMNode | null) => boolean) | undefined) => Command;
|
|
19
19
|
export declare const clearEditorContent: Command;
|
|
20
20
|
export declare function findCutBefore($pos: ResolvedPos): ResolvedPos | null;
|
|
21
21
|
/**
|
|
@@ -13,7 +13,7 @@ interface Props {
|
|
|
13
13
|
items: QuickInsertItem[];
|
|
14
14
|
selectedItemIndex?: number;
|
|
15
15
|
}
|
|
16
|
-
declare const MemoizedElementSearchWithAnalytics: React.MemoExoticComponent<React.ForwardRefExoticComponent<Omit<Props & WrappedComponentProps
|
|
16
|
+
declare const MemoizedElementSearchWithAnalytics: React.MemoExoticComponent<React.ForwardRefExoticComponent<Omit<Props & WrappedComponentProps, "intl"> & {
|
|
17
17
|
forwardedRef?: React.Ref<any> | undefined;
|
|
18
18
|
} & {
|
|
19
19
|
children?: React.ReactNode;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { FloatingToolbarItem } from '../types';
|
|
2
2
|
export type Item = FloatingToolbarItem<Function>;
|
|
3
3
|
export declare const shallowEqual: (objA?: Object, objB?: Object) => boolean;
|
|
4
|
-
export declare const compareArrays: <T extends any[]>(left: T
|
|
4
|
+
export declare const compareArrays: <T extends any[]>(left: Array<T>, right: Array<T>, compareFn?: (left: T, right: T) => boolean) => boolean;
|
|
5
5
|
export declare const isSameItem: (leftItem: Item, rightItem: Item) => boolean;
|
|
6
6
|
export declare const areSameItems: (leftArr?: Array<Item>, rightArr?: Array<Item>) => boolean;
|
|
7
7
|
export { default as messages } from './messages';
|
|
@@ -16,7 +16,7 @@ export interface Props {
|
|
|
16
16
|
id?: string;
|
|
17
17
|
role?: string;
|
|
18
18
|
}
|
|
19
|
-
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps
|
|
20
|
-
WrappedComponent: React.ComponentType<Props & WrappedComponentProps
|
|
19
|
+
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps>> & {
|
|
20
|
+
WrappedComponent: React.ComponentType<Props & WrappedComponentProps>;
|
|
21
21
|
};
|
|
22
22
|
export default _default;
|
|
@@ -39,7 +39,7 @@ export declare class EditorPluginInjectionAPI implements PluginInjectionAPIDefin
|
|
|
39
39
|
private commandsAPI;
|
|
40
40
|
private plugins;
|
|
41
41
|
constructor({ getEditorState, getEditorView }: PluginInjectionAPIProps);
|
|
42
|
-
api<T extends NextEditorPlugin<any, any>>(): import("../types/next-editor-plugin").PublicPluginAPI<[NextEditorPlugin<T extends import("
|
|
42
|
+
api<T extends NextEditorPlugin<any, any>>(): import("../types/next-editor-plugin").PublicPluginAPI<[NextEditorPlugin<T extends import("./core-plugin").CorePlugin<infer Name extends string, any, any> ? Name : never, T extends NextEditorPlugin<any, infer Metadata extends import("../types/next-editor-plugin").NextEditorPluginMetadata> ? Metadata : never>, ..."dependencies" extends keyof (T extends NextEditorPlugin<any, infer Metadata extends import("../types/next-editor-plugin").NextEditorPluginMetadata> ? Metadata : never) ? (T extends NextEditorPlugin<any, infer Metadata extends import("../types/next-editor-plugin").NextEditorPluginMetadata> ? Metadata : never)["dependencies"] extends (import("./core-plugin").CorePlugin<any, any, any> | import("../types/next-editor-plugin").OptionalPlugin<import("./core-plugin").CorePlugin<any, any, any>>)[] ? Exclude<(T extends NextEditorPlugin<any, infer Metadata extends import("../types/next-editor-plugin").NextEditorPluginMetadata> ? Metadata : never)["dependencies"], undefined> : [] : []]>;
|
|
43
43
|
onEditorViewUpdated: ({ newEditorState, oldEditorState, }: EditorStateDiff) => void;
|
|
44
44
|
onEditorPluginInitialized: (plugin: NextEditorPluginInitializedType) => void;
|
|
45
45
|
private addPlugin;
|
|
@@ -17,7 +17,7 @@ type RejectedResult = {
|
|
|
17
17
|
* which can replace this implementation once it makes to the browsers.
|
|
18
18
|
* @param promises
|
|
19
19
|
*/
|
|
20
|
-
export declare const waitForAllPromises: <T>(promises: Promise<T>[]) => Promise<(
|
|
20
|
+
export declare const waitForAllPromises: <T>(promises: Promise<T>[]) => Promise<(FulfiledResult<T> | RejectedResult)[]>;
|
|
21
21
|
/**
|
|
22
22
|
* Will resolve on the first fulfilled promise and disregard the remaining ones. Similar to `Promise.race` but won't
|
|
23
23
|
* care about rejected promises.
|
|
@@ -28,5 +28,5 @@ export declare const waitForFirstFulfilledPromise: <T>(promises: Promise<T>[]) =
|
|
|
28
28
|
* Find all fullfilled promises and return their values
|
|
29
29
|
* @param results
|
|
30
30
|
*/
|
|
31
|
-
export declare const getOnlyFulfilled: <T>(results: (
|
|
31
|
+
export declare const getOnlyFulfilled: <T>(results: (FulfiledResult<T> | RejectedResult)[]) => T[];
|
|
32
32
|
export {};
|
|
@@ -2,9 +2,9 @@ export declare const resizerItemClassName = "resizer-item";
|
|
|
2
2
|
export declare const resizerHoverZoneClassName = "resizer-hover-zone";
|
|
3
3
|
export declare const resizerExtendedZone = "resizer-is-extended";
|
|
4
4
|
export declare const resizerHandleClassName = "resizer-handle";
|
|
5
|
-
export declare const resizerHandleTrackClassName
|
|
6
|
-
export declare const resizerHandleThumbClassName
|
|
7
|
-
export declare const resizerDangerClassName
|
|
5
|
+
export declare const resizerHandleTrackClassName = "resizer-handle-track";
|
|
6
|
+
export declare const resizerHandleThumbClassName = "resizer-handle-thumb";
|
|
7
|
+
export declare const resizerDangerClassName = "resizer-handle-danger";
|
|
8
8
|
export declare const handleWrapperClass = "resizer-handle-wrapper";
|
|
9
9
|
export declare const resizerHandleZIndex = 1;
|
|
10
10
|
export declare const resizerStyles: import("@emotion/react").SerializedStyles;
|
|
@@ -13,7 +13,7 @@ type Props = {
|
|
|
13
13
|
export declare class CaptionComponent extends React.Component<Props & WrappedComponentProps> {
|
|
14
14
|
render(): jsx.JSX.Element;
|
|
15
15
|
}
|
|
16
|
-
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps
|
|
17
|
-
WrappedComponent: React.ComponentType<Props & WrappedComponentProps
|
|
16
|
+
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps>> & {
|
|
17
|
+
WrappedComponent: React.ComponentType<Props & WrappedComponentProps>;
|
|
18
18
|
};
|
|
19
19
|
export default _default;
|
|
@@ -8,7 +8,7 @@ export interface Props {
|
|
|
8
8
|
children?: React.ReactNode;
|
|
9
9
|
dispatchAnalyticsEvent?: (payload: UnsupportedContentTooltipPayload) => void;
|
|
10
10
|
}
|
|
11
|
-
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps
|
|
12
|
-
WrappedComponent: React.ComponentType<Props & WrappedComponentProps
|
|
11
|
+
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps>> & {
|
|
12
|
+
WrappedComponent: React.ComponentType<Props & WrappedComponentProps>;
|
|
13
13
|
};
|
|
14
14
|
export default _default;
|
|
@@ -8,7 +8,7 @@ export interface Props {
|
|
|
8
8
|
children?: React.ReactNode;
|
|
9
9
|
dispatchAnalyticsEvent?: (payload: UnsupportedContentTooltipPayload) => void;
|
|
10
10
|
}
|
|
11
|
-
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps
|
|
12
|
-
WrappedComponent: React.ComponentType<Props & WrappedComponentProps
|
|
11
|
+
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps>> & {
|
|
12
|
+
WrappedComponent: React.ComponentType<Props & WrappedComponentProps>;
|
|
13
13
|
};
|
|
14
14
|
export default _default;
|
|
@@ -32,7 +32,7 @@ interface Props {
|
|
|
32
32
|
paletteColorTooltipMessages?: PaletteTooltipMessages;
|
|
33
33
|
};
|
|
34
34
|
}
|
|
35
|
-
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps
|
|
36
|
-
WrappedComponent: React.ComponentType<Props & WrappedComponentProps
|
|
35
|
+
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps>> & {
|
|
36
|
+
WrappedComponent: React.ComponentType<Props & WrappedComponentProps>;
|
|
37
37
|
};
|
|
38
38
|
export default _default;
|
|
@@ -17,7 +17,7 @@ export type ShallowPropsDifference<T> = {
|
|
|
17
17
|
added: Array<keyof T>;
|
|
18
18
|
changed: Array<keyof T>;
|
|
19
19
|
};
|
|
20
|
-
export declare const getKeys: <T>(obj: T) =>
|
|
20
|
+
export declare const getKeys: <T>(obj: T) => Array<keyof T>;
|
|
21
21
|
export declare const getKeysAddedRemovedCommon: <T>(object1: T, object2: T) => {
|
|
22
22
|
added: (keyof T & keyof (T & {}))[];
|
|
23
23
|
common: (keyof T & keyof (T & {}))[];
|
|
@@ -27,6 +27,6 @@ export declare const serializeValue: <T>(value: T[keyof T]) => string | (T[keyof
|
|
|
27
27
|
type: string;
|
|
28
28
|
keys: string[];
|
|
29
29
|
} | undefined;
|
|
30
|
-
export declare const getPropsDifference: <T>(object1: T, object2: T, curDepth?: number, maxDepth?: number, keysToIgnore?:
|
|
30
|
+
export declare const getPropsDifference: <T>(object1: T, object2: T, curDepth?: number, maxDepth?: number, keysToIgnore?: Array<keyof T>) => PropsDifference<T>;
|
|
31
31
|
export declare const getShallowPropsDifference: <T>(object1: T, object2: T) => ShallowPropsDifference<T>;
|
|
32
32
|
export {};
|
|
@@ -11,4 +11,4 @@ export interface ImageLoaderState {
|
|
|
11
11
|
imageStatus: ImageStatus;
|
|
12
12
|
}
|
|
13
13
|
export type ImageStatus = 'complete' | 'loading' | 'error';
|
|
14
|
-
export declare const withImageLoader: <P extends {}>(Wrapped:
|
|
14
|
+
export declare const withImageLoader: <P extends {}>(Wrapped: ComponentType<React.PropsWithChildren<P & ImageLoaderProps>>) => React.ComponentClass<P & ImageLoaderProps>;
|