@atlaskit/editor-plugin-breakout 3.1.9 → 3.1.10
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 +8 -0
- package/dist/types/breakoutPluginType.d.ts +2 -2
- package/dist/types/pm-plugins/pragmatic-resizer.d.ts +4 -4
- package/dist/types/pm-plugins/resizer-callbacks.d.ts +5 -5
- package/dist/types/pm-plugins/utils/analytics.d.ts +1 -1
- package/dist/types/pm-plugins/utils/single-player-expand.d.ts +2 -2
- package/dist/types/ui/GuidelineLabel.d.ts +1 -1
- package/dist/types/ui/LayoutButton.d.ts +6 -6
- package/dist/types-ts4.5/breakoutPluginType.d.ts +2 -2
- package/dist/types-ts4.5/pm-plugins/pragmatic-resizer.d.ts +4 -4
- package/dist/types-ts4.5/pm-plugins/resizer-callbacks.d.ts +5 -5
- package/dist/types-ts4.5/pm-plugins/utils/analytics.d.ts +1 -1
- package/dist/types-ts4.5/pm-plugins/utils/single-player-expand.d.ts +2 -2
- package/dist/types-ts4.5/ui/GuidelineLabel.d.ts +1 -1
- package/dist/types-ts4.5/ui/LayoutButton.d.ts +6 -6
- package/package.json +3 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-breakout
|
|
2
2
|
|
|
3
|
+
## 3.1.10
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`265c1bf0cefa4`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/265c1bf0cefa4) -
|
|
8
|
+
Sorted type and interface props to improve Atlaskit docs
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
|
|
3
11
|
## 3.1.9
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
@@ -10,8 +10,8 @@ import type { WidthPlugin } from '@atlaskit/editor-plugin-width';
|
|
|
10
10
|
import type { ContentNodeWithPos } from '@atlaskit/editor-prosemirror/utils';
|
|
11
11
|
import type { ActiveGuidelineKey } from './pm-plugins/resizing-plugin';
|
|
12
12
|
export interface BreakoutPluginState {
|
|
13
|
-
breakoutNode: ContentNodeWithPos | undefined;
|
|
14
13
|
activeGuidelineKey: ActiveGuidelineKey | undefined;
|
|
14
|
+
breakoutNode: ContentNodeWithPos | undefined;
|
|
15
15
|
}
|
|
16
16
|
export interface BreakoutPluginOptions {
|
|
17
17
|
allowBreakoutButton?: boolean;
|
|
@@ -28,7 +28,7 @@ export type BreakoutPluginDependencies = [
|
|
|
28
28
|
OptionalPlugin<AnalyticsPlugin>
|
|
29
29
|
];
|
|
30
30
|
export type BreakoutPlugin = NextEditorPlugin<'breakout', {
|
|
31
|
-
pluginConfiguration: BreakoutPluginOptions | undefined;
|
|
32
31
|
dependencies: BreakoutPluginDependencies;
|
|
32
|
+
pluginConfiguration: BreakoutPluginOptions | undefined;
|
|
33
33
|
sharedState: Partial<BreakoutPluginState>;
|
|
34
34
|
}>;
|
|
@@ -3,12 +3,12 @@ import { type PortalProviderAPI } from '@atlaskit/editor-common/portal';
|
|
|
3
3
|
import type { BaseEventPayload, ElementDragType } from '@atlaskit/pragmatic-drag-and-drop/types';
|
|
4
4
|
export declare const resizeHandleMessage: Record<string, MessageDescriptor>;
|
|
5
5
|
export declare const createPragmaticResizer: ({ target, onDragStart, onDrag, onDrop, intl, nodeViewPortalProviderAPI, }: {
|
|
6
|
-
target: HTMLElement;
|
|
7
|
-
onDragStart: (args: BaseEventPayload<ElementDragType>) => void;
|
|
8
|
-
onDrag: (args: BaseEventPayload<ElementDragType>) => void;
|
|
9
|
-
onDrop: (args: BaseEventPayload<ElementDragType>) => void;
|
|
10
6
|
intl: IntlShape;
|
|
11
7
|
nodeViewPortalProviderAPI: PortalProviderAPI;
|
|
8
|
+
onDrag: (args: BaseEventPayload<ElementDragType>) => void;
|
|
9
|
+
onDragStart: (args: BaseEventPayload<ElementDragType>) => void;
|
|
10
|
+
onDrop: (args: BaseEventPayload<ElementDragType>) => void;
|
|
11
|
+
target: HTMLElement;
|
|
12
12
|
}) => {
|
|
13
13
|
rightHandle: HTMLDivElement;
|
|
14
14
|
leftHandle: HTMLDivElement;
|
|
@@ -5,19 +5,19 @@ import type { ElementDragPayload } from '@atlaskit/pragmatic-drag-and-drop/eleme
|
|
|
5
5
|
import type { BaseEventPayload, DragLocationHistory, ElementDragType } from '@atlaskit/pragmatic-drag-and-drop/types';
|
|
6
6
|
import type { BreakoutPlugin } from '../breakoutPluginType';
|
|
7
7
|
export declare function getProposedWidth({ initialWidth, location, api, source, }: {
|
|
8
|
+
api: ExtractInjectionAPI<BreakoutPlugin> | undefined;
|
|
8
9
|
initialWidth: number;
|
|
9
10
|
location: DragLocationHistory;
|
|
10
|
-
api: ExtractInjectionAPI<BreakoutPlugin> | undefined;
|
|
11
11
|
source: ElementDragPayload;
|
|
12
12
|
}): number;
|
|
13
13
|
export declare function createResizerCallbacks({ dom, contentDOM, view, mark, api, }: {
|
|
14
|
-
|
|
14
|
+
api: ExtractInjectionAPI<BreakoutPlugin> | undefined;
|
|
15
15
|
contentDOM: HTMLElement;
|
|
16
|
-
|
|
16
|
+
dom: HTMLElement;
|
|
17
17
|
mark: Mark;
|
|
18
|
-
|
|
18
|
+
view: EditorView;
|
|
19
19
|
}): {
|
|
20
|
-
onDragStart: () => void;
|
|
21
20
|
onDrag: (args: BaseEventPayload<ElementDragType>) => void;
|
|
21
|
+
onDragStart: () => void;
|
|
22
22
|
onDrop: (args: BaseEventPayload<ElementDragType>) => void;
|
|
23
23
|
};
|
|
@@ -6,7 +6,7 @@ export declare const generateResizeFrameRatePayloads: (props: {
|
|
|
6
6
|
originalNode: PMNode;
|
|
7
7
|
}) => BreakoutEventPayload[];
|
|
8
8
|
export declare const generateResizedEventPayload: ({ node, prevWidth, newWidth, }: {
|
|
9
|
+
newWidth: number;
|
|
9
10
|
node: PMNode;
|
|
10
11
|
prevWidth: number;
|
|
11
|
-
newWidth: number;
|
|
12
12
|
}) => BreakoutEventPayload;
|
|
@@ -2,10 +2,10 @@ import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
|
2
2
|
import type { Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
3
3
|
import type { ContentNodeWithPos } from '@atlaskit/editor-prosemirror/utils';
|
|
4
4
|
interface UpdateExpandedStateNew {
|
|
5
|
-
|
|
5
|
+
isLivePage?: boolean;
|
|
6
6
|
node: PMNode;
|
|
7
7
|
pos: number;
|
|
8
|
-
|
|
8
|
+
tr: Transaction;
|
|
9
9
|
}
|
|
10
10
|
export declare const updateExpandedStateNew: ({ tr, node, pos, isLivePage }: UpdateExpandedStateNew) => void;
|
|
11
11
|
export declare const updateExpandedState: (tr: Transaction, node: ContentNodeWithPos, isLivePage?: boolean) => void;
|
|
@@ -4,9 +4,9 @@ import { type EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
|
4
4
|
import type { BreakoutPlugin } from '../breakoutPluginType';
|
|
5
5
|
type GuidelineLabelProps = {
|
|
6
6
|
api: ExtractInjectionAPI<BreakoutPlugin> | undefined;
|
|
7
|
+
boundariesElement?: HTMLElement;
|
|
7
8
|
editorView: EditorView;
|
|
8
9
|
mountPoint?: HTMLElement;
|
|
9
|
-
boundariesElement?: HTMLElement;
|
|
10
10
|
scrollableElement?: HTMLElement;
|
|
11
11
|
};
|
|
12
12
|
export declare const GuidelineLabel: ({ api, editorView, mountPoint, boundariesElement, scrollableElement, }: GuidelineLabelProps) => React.JSX.Element | null;
|
|
@@ -4,16 +4,16 @@ import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
|
4
4
|
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
5
5
|
import type { BreakoutPlugin } from '../breakoutPluginType';
|
|
6
6
|
export interface Props {
|
|
7
|
+
api: ExtractInjectionAPI<BreakoutPlugin> | undefined;
|
|
8
|
+
boundariesElement?: HTMLElement;
|
|
9
|
+
breakoutMode: BreakoutMode | undefined;
|
|
7
10
|
editorView: EditorView;
|
|
11
|
+
handleClick?: Function;
|
|
12
|
+
isBreakoutNodePresent: boolean;
|
|
13
|
+
isLivePage?: boolean;
|
|
8
14
|
mountPoint?: HTMLElement;
|
|
9
15
|
node: PMNode | null;
|
|
10
|
-
boundariesElement?: HTMLElement;
|
|
11
16
|
scrollableElement?: HTMLElement;
|
|
12
|
-
handleClick?: Function;
|
|
13
|
-
isLivePage?: boolean;
|
|
14
|
-
isBreakoutNodePresent: boolean;
|
|
15
|
-
breakoutMode: BreakoutMode | undefined;
|
|
16
|
-
api: ExtractInjectionAPI<BreakoutPlugin> | undefined;
|
|
17
17
|
}
|
|
18
18
|
declare const _default: import("react").FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps>> & {
|
|
19
19
|
WrappedComponent: import("react").ComponentType<Props & WrappedComponentProps>;
|
|
@@ -10,8 +10,8 @@ import type { WidthPlugin } from '@atlaskit/editor-plugin-width';
|
|
|
10
10
|
import type { ContentNodeWithPos } from '@atlaskit/editor-prosemirror/utils';
|
|
11
11
|
import type { ActiveGuidelineKey } from './pm-plugins/resizing-plugin';
|
|
12
12
|
export interface BreakoutPluginState {
|
|
13
|
-
breakoutNode: ContentNodeWithPos | undefined;
|
|
14
13
|
activeGuidelineKey: ActiveGuidelineKey | undefined;
|
|
14
|
+
breakoutNode: ContentNodeWithPos | undefined;
|
|
15
15
|
}
|
|
16
16
|
export interface BreakoutPluginOptions {
|
|
17
17
|
allowBreakoutButton?: boolean;
|
|
@@ -28,7 +28,7 @@ export type BreakoutPluginDependencies = [
|
|
|
28
28
|
OptionalPlugin<AnalyticsPlugin>
|
|
29
29
|
];
|
|
30
30
|
export type BreakoutPlugin = NextEditorPlugin<'breakout', {
|
|
31
|
-
pluginConfiguration: BreakoutPluginOptions | undefined;
|
|
32
31
|
dependencies: BreakoutPluginDependencies;
|
|
32
|
+
pluginConfiguration: BreakoutPluginOptions | undefined;
|
|
33
33
|
sharedState: Partial<BreakoutPluginState>;
|
|
34
34
|
}>;
|
|
@@ -3,12 +3,12 @@ import { type PortalProviderAPI } from '@atlaskit/editor-common/portal';
|
|
|
3
3
|
import type { BaseEventPayload, ElementDragType } from '@atlaskit/pragmatic-drag-and-drop/types';
|
|
4
4
|
export declare const resizeHandleMessage: Record<string, MessageDescriptor>;
|
|
5
5
|
export declare const createPragmaticResizer: ({ target, onDragStart, onDrag, onDrop, intl, nodeViewPortalProviderAPI, }: {
|
|
6
|
-
target: HTMLElement;
|
|
7
|
-
onDragStart: (args: BaseEventPayload<ElementDragType>) => void;
|
|
8
|
-
onDrag: (args: BaseEventPayload<ElementDragType>) => void;
|
|
9
|
-
onDrop: (args: BaseEventPayload<ElementDragType>) => void;
|
|
10
6
|
intl: IntlShape;
|
|
11
7
|
nodeViewPortalProviderAPI: PortalProviderAPI;
|
|
8
|
+
onDrag: (args: BaseEventPayload<ElementDragType>) => void;
|
|
9
|
+
onDragStart: (args: BaseEventPayload<ElementDragType>) => void;
|
|
10
|
+
onDrop: (args: BaseEventPayload<ElementDragType>) => void;
|
|
11
|
+
target: HTMLElement;
|
|
12
12
|
}) => {
|
|
13
13
|
rightHandle: HTMLDivElement;
|
|
14
14
|
leftHandle: HTMLDivElement;
|
|
@@ -5,19 +5,19 @@ import type { ElementDragPayload } from '@atlaskit/pragmatic-drag-and-drop/eleme
|
|
|
5
5
|
import type { BaseEventPayload, DragLocationHistory, ElementDragType } from '@atlaskit/pragmatic-drag-and-drop/types';
|
|
6
6
|
import type { BreakoutPlugin } from '../breakoutPluginType';
|
|
7
7
|
export declare function getProposedWidth({ initialWidth, location, api, source, }: {
|
|
8
|
+
api: ExtractInjectionAPI<BreakoutPlugin> | undefined;
|
|
8
9
|
initialWidth: number;
|
|
9
10
|
location: DragLocationHistory;
|
|
10
|
-
api: ExtractInjectionAPI<BreakoutPlugin> | undefined;
|
|
11
11
|
source: ElementDragPayload;
|
|
12
12
|
}): number;
|
|
13
13
|
export declare function createResizerCallbacks({ dom, contentDOM, view, mark, api, }: {
|
|
14
|
-
|
|
14
|
+
api: ExtractInjectionAPI<BreakoutPlugin> | undefined;
|
|
15
15
|
contentDOM: HTMLElement;
|
|
16
|
-
|
|
16
|
+
dom: HTMLElement;
|
|
17
17
|
mark: Mark;
|
|
18
|
-
|
|
18
|
+
view: EditorView;
|
|
19
19
|
}): {
|
|
20
|
-
onDragStart: () => void;
|
|
21
20
|
onDrag: (args: BaseEventPayload<ElementDragType>) => void;
|
|
21
|
+
onDragStart: () => void;
|
|
22
22
|
onDrop: (args: BaseEventPayload<ElementDragType>) => void;
|
|
23
23
|
};
|
|
@@ -6,7 +6,7 @@ export declare const generateResizeFrameRatePayloads: (props: {
|
|
|
6
6
|
originalNode: PMNode;
|
|
7
7
|
}) => BreakoutEventPayload[];
|
|
8
8
|
export declare const generateResizedEventPayload: ({ node, prevWidth, newWidth, }: {
|
|
9
|
+
newWidth: number;
|
|
9
10
|
node: PMNode;
|
|
10
11
|
prevWidth: number;
|
|
11
|
-
newWidth: number;
|
|
12
12
|
}) => BreakoutEventPayload;
|
|
@@ -2,10 +2,10 @@ import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
|
2
2
|
import type { Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
3
3
|
import type { ContentNodeWithPos } from '@atlaskit/editor-prosemirror/utils';
|
|
4
4
|
interface UpdateExpandedStateNew {
|
|
5
|
-
|
|
5
|
+
isLivePage?: boolean;
|
|
6
6
|
node: PMNode;
|
|
7
7
|
pos: number;
|
|
8
|
-
|
|
8
|
+
tr: Transaction;
|
|
9
9
|
}
|
|
10
10
|
export declare const updateExpandedStateNew: ({ tr, node, pos, isLivePage }: UpdateExpandedStateNew) => void;
|
|
11
11
|
export declare const updateExpandedState: (tr: Transaction, node: ContentNodeWithPos, isLivePage?: boolean) => void;
|
|
@@ -4,9 +4,9 @@ import { type EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
|
4
4
|
import type { BreakoutPlugin } from '../breakoutPluginType';
|
|
5
5
|
type GuidelineLabelProps = {
|
|
6
6
|
api: ExtractInjectionAPI<BreakoutPlugin> | undefined;
|
|
7
|
+
boundariesElement?: HTMLElement;
|
|
7
8
|
editorView: EditorView;
|
|
8
9
|
mountPoint?: HTMLElement;
|
|
9
|
-
boundariesElement?: HTMLElement;
|
|
10
10
|
scrollableElement?: HTMLElement;
|
|
11
11
|
};
|
|
12
12
|
export declare const GuidelineLabel: ({ api, editorView, mountPoint, boundariesElement, scrollableElement, }: GuidelineLabelProps) => React.JSX.Element | null;
|
|
@@ -4,16 +4,16 @@ import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
|
4
4
|
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
5
5
|
import type { BreakoutPlugin } from '../breakoutPluginType';
|
|
6
6
|
export interface Props {
|
|
7
|
+
api: ExtractInjectionAPI<BreakoutPlugin> | undefined;
|
|
8
|
+
boundariesElement?: HTMLElement;
|
|
9
|
+
breakoutMode: BreakoutMode | undefined;
|
|
7
10
|
editorView: EditorView;
|
|
11
|
+
handleClick?: Function;
|
|
12
|
+
isBreakoutNodePresent: boolean;
|
|
13
|
+
isLivePage?: boolean;
|
|
8
14
|
mountPoint?: HTMLElement;
|
|
9
15
|
node: PMNode | null;
|
|
10
|
-
boundariesElement?: HTMLElement;
|
|
11
16
|
scrollableElement?: HTMLElement;
|
|
12
|
-
handleClick?: Function;
|
|
13
|
-
isLivePage?: boolean;
|
|
14
|
-
isBreakoutNodePresent: boolean;
|
|
15
|
-
breakoutMode: BreakoutMode | undefined;
|
|
16
|
-
api: ExtractInjectionAPI<BreakoutPlugin> | undefined;
|
|
17
17
|
}
|
|
18
18
|
declare const _default: import("react").FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps>> & {
|
|
19
19
|
WrappedComponent: import("react").ComponentType<Props & WrappedComponentProps>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-breakout",
|
|
3
|
-
"version": "3.1.
|
|
3
|
+
"version": "3.1.10",
|
|
4
4
|
"description": "Breakout plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
47
47
|
"@atlaskit/pragmatic-drag-and-drop": "^1.7.0",
|
|
48
48
|
"@atlaskit/theme": "^19.0.0",
|
|
49
|
-
"@atlaskit/tmp-editor-statsig": "^11.
|
|
49
|
+
"@atlaskit/tmp-editor-statsig": "^11.5.0",
|
|
50
50
|
"@atlaskit/tokens": "^6.0.0",
|
|
51
51
|
"@atlaskit/tooltip": "^20.4.0",
|
|
52
52
|
"@babel/runtime": "^7.0.0",
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
"uuid": "^3.1.0"
|
|
57
57
|
},
|
|
58
58
|
"peerDependencies": {
|
|
59
|
-
"@atlaskit/editor-common": "^107.
|
|
59
|
+
"@atlaskit/editor-common": "^107.28.0",
|
|
60
60
|
"react": "^18.2.0",
|
|
61
61
|
"react-dom": "^18.2.0",
|
|
62
62
|
"react-intl-next": "npm:react-intl@^5.18.1"
|
|
@@ -68,7 +68,6 @@
|
|
|
68
68
|
"@atlaskit/editor-plugin-composition": "^2.0.0",
|
|
69
69
|
"@atlaskit/editor-plugin-decorations": "^3.0.0",
|
|
70
70
|
"@atlaskit/ssr": "workspace:^",
|
|
71
|
-
"@atlaskit/visual-regression": "workspace:^",
|
|
72
71
|
"@testing-library/react": "^13.4.0",
|
|
73
72
|
"wait-for-expect": "^1.2.0"
|
|
74
73
|
},
|