@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
|
@@ -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;
|
|
@@ -40,8 +40,8 @@ export declare class EditorPluginInjectionAPI implements PluginInjectionAPIDefin
|
|
|
40
40
|
private plugins;
|
|
41
41
|
constructor({ getEditorState, getEditorView }: PluginInjectionAPIProps);
|
|
42
42
|
api<T extends NextEditorPlugin<any, any>>(): import("../types/next-editor-plugin").PublicPluginAPI<[
|
|
43
|
-
NextEditorPlugin<T extends import("
|
|
44
|
-
..."dependencies" extends keyof (T extends NextEditorPlugin<any, infer
|
|
43
|
+
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>,
|
|
44
|
+
..."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> : [
|
|
45
45
|
] : [
|
|
46
46
|
]
|
|
47
47
|
]>;
|
|
@@ -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>;
|
package/doc-utils/package.json
CHANGED
package/emoji/package.json
CHANGED
package/extensions/package.json
CHANGED
package/guideline/package.json
CHANGED
package/hooks/package.json
CHANGED
package/icons/package.json
CHANGED
package/in-product/package.json
CHANGED
package/indentation/package.json
CHANGED
package/insert/package.json
CHANGED
package/keymaps/package.json
CHANGED
package/link/package.json
CHANGED
package/lists/package.json
CHANGED
package/mark/package.json
CHANGED
package/media/package.json
CHANGED
package/mention/package.json
CHANGED
package/messages/package.json
CHANGED
package/monitoring/package.json
CHANGED
package/node-width/package.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-common",
|
|
3
|
-
"version": "78.17.
|
|
3
|
+
"version": "78.17.2",
|
|
4
4
|
"description": "A package that contains common classes and components for editor and renderer",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -105,7 +105,7 @@
|
|
|
105
105
|
"@atlaskit/codemod-utils": "^4.2.0",
|
|
106
106
|
"@atlaskit/custom-steps": "^0.0.15",
|
|
107
107
|
"@atlaskit/editor-json-transformer": "^8.10.0",
|
|
108
|
-
"@atlaskit/editor-palette": "1.5.
|
|
108
|
+
"@atlaskit/editor-palette": "1.5.3",
|
|
109
109
|
"@atlaskit/editor-prosemirror": "3.0.0",
|
|
110
110
|
"@atlaskit/editor-shared-styles": "^2.9.0",
|
|
111
111
|
"@atlaskit/editor-tables": "^2.5.0",
|
|
@@ -122,7 +122,7 @@
|
|
|
122
122
|
"@atlaskit/media-file-preview": "^0.5.0",
|
|
123
123
|
"@atlaskit/media-picker": "^66.3.0",
|
|
124
124
|
"@atlaskit/media-ui": "^25.4.0",
|
|
125
|
-
"@atlaskit/media-viewer": "48.4.
|
|
125
|
+
"@atlaskit/media-viewer": "48.4.2",
|
|
126
126
|
"@atlaskit/mention": "^23.0.0",
|
|
127
127
|
"@atlaskit/menu": "^2.1.0",
|
|
128
128
|
"@atlaskit/platform-feature-flags": "^0.2.0",
|
|
@@ -192,7 +192,7 @@
|
|
|
192
192
|
"react": "^16.8.0",
|
|
193
193
|
"react-test-renderer": "^16.8.0",
|
|
194
194
|
"sinon": "^2.2.0",
|
|
195
|
-
"typescript": "~4.
|
|
195
|
+
"typescript": "~5.4.2"
|
|
196
196
|
},
|
|
197
197
|
"techstack": {
|
|
198
198
|
"@atlassian/frontend": {
|
|
@@ -247,4 +247,4 @@
|
|
|
247
247
|
"type": "boolean"
|
|
248
248
|
}
|
|
249
249
|
}
|
|
250
|
-
}
|
|
250
|
+
}
|
package/panel/package.json
CHANGED
package/paste/package.json
CHANGED
package/preset/package.json
CHANGED
package/resizer/package.json
CHANGED