@atlaskit/editor-plugin-code-block-advanced 3.2.1 → 3.2.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 +8 -0
- package/dist/types/codeBlockAdvancedPluginType.d.ts +1 -1
- package/dist/types/nodeviews/codeBlockAdvanced.d.ts +1 -1
- package/dist/types/nodeviews/codemirrorSync/syncCMWithPM.d.ts +2 -2
- package/dist/types/nodeviews/extensions/keymap/backspace.d.ts +2 -2
- package/dist/types/nodeviews/extensions/keymap/index.d.ts +3 -3
- package/dist/types/nodeviews/extensions/keymap/maybeEscape.d.ts +4 -4
- package/dist/types/nodeviews/lazyCodeBlockAdvanced.d.ts +1 -1
- package/dist/types/pm-plugins/main.d.ts +1 -1
- package/dist/types-ts4.5/codeBlockAdvancedPluginType.d.ts +1 -1
- package/dist/types-ts4.5/nodeviews/codeBlockAdvanced.d.ts +1 -1
- package/dist/types-ts4.5/nodeviews/codemirrorSync/syncCMWithPM.d.ts +2 -2
- package/dist/types-ts4.5/nodeviews/extensions/keymap/backspace.d.ts +2 -2
- package/dist/types-ts4.5/nodeviews/extensions/keymap/index.d.ts +3 -3
- package/dist/types-ts4.5/nodeviews/extensions/keymap/maybeEscape.d.ts +4 -4
- package/dist/types-ts4.5/nodeviews/lazyCodeBlockAdvanced.d.ts +1 -1
- package/dist/types-ts4.5/pm-plugins/main.d.ts +1 -1
- package/package.json +4 -4
- package/src/codeBlockAdvancedPluginType.ts +1 -1
- package/src/nodeviews/codeBlockAdvanced.ts +1 -1
- package/src/nodeviews/codemirrorSync/syncCMWithPM.ts +2 -2
- package/src/nodeviews/extensions/keymap/backspace.ts +2 -2
- package/src/nodeviews/extensions/keymap/index.ts +3 -3
- package/src/nodeviews/extensions/keymap/maybeEscape.ts +5 -5
- package/src/nodeviews/extensions/prosemirrorDecorations.ts +2 -2
- package/src/nodeviews/lazyCodeBlockAdvanced.ts +1 -1
- package/src/pm-plugins/main.ts +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-code-block-advanced
|
|
2
2
|
|
|
3
|
+
## 3.2.2
|
|
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.2.1
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
@@ -16,6 +16,6 @@ export type CodeBlockAdvancedPlugin = NextEditorPlugin<'codeBlockAdvanced', {
|
|
|
16
16
|
pluginConfiguration: CodeBlockAdvancedPluginOptions | undefined;
|
|
17
17
|
}>;
|
|
18
18
|
export type CodeBlockAdvancedPluginOptions = {
|
|
19
|
-
extensions?: Extension[];
|
|
20
19
|
allowCodeFolding?: boolean;
|
|
20
|
+
extensions?: Extension[];
|
|
21
21
|
};
|
|
@@ -6,10 +6,10 @@ import { type Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
|
6
6
|
import type { Decoration, DecorationSource, EditorView, NodeView } from '@atlaskit/editor-prosemirror/view';
|
|
7
7
|
import type { CodeBlockAdvancedPlugin } from '../codeBlockAdvancedPluginType';
|
|
8
8
|
export interface ConfigProps {
|
|
9
|
+
allowCodeFolding: boolean;
|
|
9
10
|
api: ExtractInjectionAPI<CodeBlockAdvancedPlugin> | undefined;
|
|
10
11
|
extensions: Extension[];
|
|
11
12
|
getIntl: () => IntlShape;
|
|
12
|
-
allowCodeFolding: boolean;
|
|
13
13
|
}
|
|
14
14
|
declare class CodeBlockAdvancedNodeView implements NodeView {
|
|
15
15
|
dom: Node;
|
|
@@ -3,10 +3,10 @@ import type { getPosHandlerNode } from '@atlaskit/editor-common/types';
|
|
|
3
3
|
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
4
4
|
import { type EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
5
5
|
interface BackspaceProps {
|
|
6
|
-
view: EditorView;
|
|
7
6
|
cm: CodeMirror;
|
|
8
|
-
getPos: getPosHandlerNode;
|
|
9
7
|
getNode: () => PMNode;
|
|
8
|
+
getPos: getPosHandlerNode;
|
|
9
|
+
view: EditorView;
|
|
10
10
|
}
|
|
11
11
|
export declare const backspaceKeymap: ({ cm, view, getPos, getNode }: BackspaceProps) => boolean;
|
|
12
12
|
export {};
|
|
@@ -4,12 +4,12 @@ import type { getPosHandlerNode } from '@atlaskit/editor-common/types';
|
|
|
4
4
|
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
5
5
|
import { type EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
6
6
|
interface KeymapProps {
|
|
7
|
-
|
|
7
|
+
customFindReplace: boolean;
|
|
8
8
|
getNode: () => PMNode;
|
|
9
9
|
getPos: getPosHandlerNode;
|
|
10
|
-
selectCodeBlockNode: (relativeSelectionPos: RelativeSelectionPos | undefined) => void;
|
|
11
10
|
onMaybeNodeSelection: () => void;
|
|
12
|
-
|
|
11
|
+
selectCodeBlockNode: (relativeSelectionPos: RelativeSelectionPos | undefined) => void;
|
|
12
|
+
view: EditorView;
|
|
13
13
|
}
|
|
14
14
|
export declare const keymapExtension: ({ view, getNode, getPos, selectCodeBlockNode, onMaybeNodeSelection, customFindReplace, }: KeymapProps) => Extension;
|
|
15
15
|
export {};
|
|
@@ -4,14 +4,14 @@ import type { getPosHandlerNode } from '@atlaskit/editor-common/types';
|
|
|
4
4
|
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
5
5
|
import { type EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
6
6
|
interface MaybeEscapeProps {
|
|
7
|
-
unit: 'line' | 'char';
|
|
8
|
-
dir: -1 | 1;
|
|
9
|
-
view: EditorView;
|
|
10
7
|
cm: CodeMirror;
|
|
11
|
-
|
|
8
|
+
dir: -1 | 1;
|
|
12
9
|
getNode: () => PMNode;
|
|
10
|
+
getPos: getPosHandlerNode;
|
|
13
11
|
onMaybeNodeSelection: () => void;
|
|
14
12
|
selectCodeBlockNode: (relativeSelectionPos: RelativeSelectionPos | undefined) => void;
|
|
13
|
+
unit: 'line' | 'char';
|
|
14
|
+
view: EditorView;
|
|
15
15
|
}
|
|
16
16
|
export declare const maybeEscapeKeymap: ({ unit, dir, view, cm, getPos, getNode, onMaybeNodeSelection, selectCodeBlockNode, }: MaybeEscapeProps) => boolean;
|
|
17
17
|
export {};
|
|
@@ -3,10 +3,10 @@ import type { IntlShape } from 'react-intl-next';
|
|
|
3
3
|
import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
|
|
4
4
|
import type { CodeBlockAdvancedPlugin } from '../codeBlockAdvancedPluginType';
|
|
5
5
|
interface Props {
|
|
6
|
+
allowCodeFolding: boolean;
|
|
6
7
|
api: ExtractInjectionAPI<CodeBlockAdvancedPlugin> | undefined;
|
|
7
8
|
extensions: Extension[];
|
|
8
9
|
getIntl: () => IntlShape;
|
|
9
|
-
allowCodeFolding: boolean;
|
|
10
10
|
}
|
|
11
11
|
export declare const lazyCodeBlockView: (props: Props) => import("@atlaskit/editor-common/lazy-node-view").NodeViewConstructor;
|
|
12
12
|
export {};
|
|
@@ -4,10 +4,10 @@ import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
|
4
4
|
import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
|
|
5
5
|
import type { CodeBlockAdvancedPlugin } from '../codeBlockAdvancedPluginType';
|
|
6
6
|
interface Props {
|
|
7
|
+
allowCodeFolding: boolean;
|
|
7
8
|
api: ExtractInjectionAPI<CodeBlockAdvancedPlugin> | undefined;
|
|
8
9
|
extensions: Extension[];
|
|
9
10
|
getIntl: () => IntlShape;
|
|
10
|
-
allowCodeFolding: boolean;
|
|
11
11
|
}
|
|
12
12
|
export declare const createPlugin: (props: Props) => SafePlugin<any>;
|
|
13
13
|
export {};
|
|
@@ -16,6 +16,6 @@ export type CodeBlockAdvancedPlugin = NextEditorPlugin<'codeBlockAdvanced', {
|
|
|
16
16
|
pluginConfiguration: CodeBlockAdvancedPluginOptions | undefined;
|
|
17
17
|
}>;
|
|
18
18
|
export type CodeBlockAdvancedPluginOptions = {
|
|
19
|
-
extensions?: Extension[];
|
|
20
19
|
allowCodeFolding?: boolean;
|
|
20
|
+
extensions?: Extension[];
|
|
21
21
|
};
|
|
@@ -6,10 +6,10 @@ import { type Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
|
6
6
|
import type { Decoration, DecorationSource, EditorView, NodeView } from '@atlaskit/editor-prosemirror/view';
|
|
7
7
|
import type { CodeBlockAdvancedPlugin } from '../codeBlockAdvancedPluginType';
|
|
8
8
|
export interface ConfigProps {
|
|
9
|
+
allowCodeFolding: boolean;
|
|
9
10
|
api: ExtractInjectionAPI<CodeBlockAdvancedPlugin> | undefined;
|
|
10
11
|
extensions: Extension[];
|
|
11
12
|
getIntl: () => IntlShape;
|
|
12
|
-
allowCodeFolding: boolean;
|
|
13
13
|
}
|
|
14
14
|
declare class CodeBlockAdvancedNodeView implements NodeView {
|
|
15
15
|
dom: Node;
|
|
@@ -3,10 +3,10 @@ import type { getPosHandlerNode } from '@atlaskit/editor-common/types';
|
|
|
3
3
|
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
4
4
|
import { type EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
5
5
|
interface BackspaceProps {
|
|
6
|
-
view: EditorView;
|
|
7
6
|
cm: CodeMirror;
|
|
8
|
-
getPos: getPosHandlerNode;
|
|
9
7
|
getNode: () => PMNode;
|
|
8
|
+
getPos: getPosHandlerNode;
|
|
9
|
+
view: EditorView;
|
|
10
10
|
}
|
|
11
11
|
export declare const backspaceKeymap: ({ cm, view, getPos, getNode }: BackspaceProps) => boolean;
|
|
12
12
|
export {};
|
|
@@ -4,12 +4,12 @@ import type { getPosHandlerNode } from '@atlaskit/editor-common/types';
|
|
|
4
4
|
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
5
5
|
import { type EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
6
6
|
interface KeymapProps {
|
|
7
|
-
|
|
7
|
+
customFindReplace: boolean;
|
|
8
8
|
getNode: () => PMNode;
|
|
9
9
|
getPos: getPosHandlerNode;
|
|
10
|
-
selectCodeBlockNode: (relativeSelectionPos: RelativeSelectionPos | undefined) => void;
|
|
11
10
|
onMaybeNodeSelection: () => void;
|
|
12
|
-
|
|
11
|
+
selectCodeBlockNode: (relativeSelectionPos: RelativeSelectionPos | undefined) => void;
|
|
12
|
+
view: EditorView;
|
|
13
13
|
}
|
|
14
14
|
export declare const keymapExtension: ({ view, getNode, getPos, selectCodeBlockNode, onMaybeNodeSelection, customFindReplace, }: KeymapProps) => Extension;
|
|
15
15
|
export {};
|
|
@@ -4,14 +4,14 @@ import type { getPosHandlerNode } from '@atlaskit/editor-common/types';
|
|
|
4
4
|
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
5
5
|
import { type EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
6
6
|
interface MaybeEscapeProps {
|
|
7
|
-
unit: 'line' | 'char';
|
|
8
|
-
dir: -1 | 1;
|
|
9
|
-
view: EditorView;
|
|
10
7
|
cm: CodeMirror;
|
|
11
|
-
|
|
8
|
+
dir: -1 | 1;
|
|
12
9
|
getNode: () => PMNode;
|
|
10
|
+
getPos: getPosHandlerNode;
|
|
13
11
|
onMaybeNodeSelection: () => void;
|
|
14
12
|
selectCodeBlockNode: (relativeSelectionPos: RelativeSelectionPos | undefined) => void;
|
|
13
|
+
unit: 'line' | 'char';
|
|
14
|
+
view: EditorView;
|
|
15
15
|
}
|
|
16
16
|
export declare const maybeEscapeKeymap: ({ unit, dir, view, cm, getPos, getNode, onMaybeNodeSelection, selectCodeBlockNode, }: MaybeEscapeProps) => boolean;
|
|
17
17
|
export {};
|
|
@@ -3,10 +3,10 @@ import type { IntlShape } from 'react-intl-next';
|
|
|
3
3
|
import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
|
|
4
4
|
import type { CodeBlockAdvancedPlugin } from '../codeBlockAdvancedPluginType';
|
|
5
5
|
interface Props {
|
|
6
|
+
allowCodeFolding: boolean;
|
|
6
7
|
api: ExtractInjectionAPI<CodeBlockAdvancedPlugin> | undefined;
|
|
7
8
|
extensions: Extension[];
|
|
8
9
|
getIntl: () => IntlShape;
|
|
9
|
-
allowCodeFolding: boolean;
|
|
10
10
|
}
|
|
11
11
|
export declare const lazyCodeBlockView: (props: Props) => import("@atlaskit/editor-common/lazy-node-view").NodeViewConstructor;
|
|
12
12
|
export {};
|
|
@@ -4,10 +4,10 @@ import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
|
4
4
|
import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
|
|
5
5
|
import type { CodeBlockAdvancedPlugin } from '../codeBlockAdvancedPluginType';
|
|
6
6
|
interface Props {
|
|
7
|
+
allowCodeFolding: boolean;
|
|
7
8
|
api: ExtractInjectionAPI<CodeBlockAdvancedPlugin> | undefined;
|
|
8
9
|
extensions: Extension[];
|
|
9
10
|
getIntl: () => IntlShape;
|
|
10
|
-
allowCodeFolding: boolean;
|
|
11
11
|
}
|
|
12
12
|
export declare const createPlugin: (props: Props) => SafePlugin<any>;
|
|
13
13
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-code-block-advanced",
|
|
3
|
-
"version": "3.2.
|
|
3
|
+
"version": "3.2.2",
|
|
4
4
|
"description": "CodeBlockAdvanced plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -35,11 +35,11 @@
|
|
|
35
35
|
"@atlaskit/editor-plugin-code-block": "^5.0.0",
|
|
36
36
|
"@atlaskit/editor-plugin-editor-disabled": "^3.0.0",
|
|
37
37
|
"@atlaskit/editor-plugin-find-replace": "^3.2.0",
|
|
38
|
-
"@atlaskit/editor-plugin-selection": "^3.
|
|
38
|
+
"@atlaskit/editor-plugin-selection": "^3.2.0",
|
|
39
39
|
"@atlaskit/editor-plugin-selection-marker": "^3.0.0",
|
|
40
40
|
"@atlaskit/editor-prosemirror": "7.0.0",
|
|
41
41
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
42
|
-
"@atlaskit/tmp-editor-statsig": "^11.
|
|
42
|
+
"@atlaskit/tmp-editor-statsig": "^11.5.0",
|
|
43
43
|
"@atlaskit/tokens": "^6.0.0",
|
|
44
44
|
"@babel/runtime": "^7.0.0",
|
|
45
45
|
"@codemirror/autocomplete": "6.18.4",
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"codemirror-lang-elixir": "4.0.0"
|
|
56
56
|
},
|
|
57
57
|
"peerDependencies": {
|
|
58
|
-
"@atlaskit/editor-common": "^107.
|
|
58
|
+
"@atlaskit/editor-common": "^107.28.0",
|
|
59
59
|
"react": "^18.2.0"
|
|
60
60
|
},
|
|
61
61
|
"devDependencies": {
|
|
@@ -46,10 +46,10 @@ import { tripleClickSelectAllExtension } from './extensions/tripleClickExtension
|
|
|
46
46
|
import { LanguageLoader } from './languages/loader';
|
|
47
47
|
|
|
48
48
|
export interface ConfigProps {
|
|
49
|
+
allowCodeFolding: boolean;
|
|
49
50
|
api: ExtractInjectionAPI<CodeBlockAdvancedPlugin> | undefined;
|
|
50
51
|
extensions: Extension[];
|
|
51
52
|
getIntl: () => IntlShape;
|
|
52
|
-
allowCodeFolding: boolean;
|
|
53
53
|
}
|
|
54
54
|
|
|
55
55
|
// Based on: https://prosemirror.net/examples/codemirror/
|
|
@@ -4,9 +4,9 @@ import { TextSelection } from '@atlaskit/editor-prosemirror/state';
|
|
|
4
4
|
import { type EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
5
5
|
|
|
6
6
|
interface Props {
|
|
7
|
-
view: EditorView;
|
|
8
|
-
update: ViewUpdate;
|
|
9
7
|
offset: number;
|
|
8
|
+
update: ViewUpdate;
|
|
9
|
+
view: EditorView;
|
|
10
10
|
}
|
|
11
11
|
|
|
12
12
|
/**
|
|
@@ -6,10 +6,10 @@ import { TextSelection } from '@atlaskit/editor-prosemirror/state';
|
|
|
6
6
|
import { type EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
7
7
|
|
|
8
8
|
interface BackspaceProps {
|
|
9
|
-
view: EditorView;
|
|
10
9
|
cm: CodeMirror;
|
|
11
|
-
getPos: getPosHandlerNode;
|
|
12
10
|
getNode: () => PMNode;
|
|
11
|
+
getPos: getPosHandlerNode;
|
|
12
|
+
view: EditorView;
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
export const backspaceKeymap = ({ cm, view, getPos, getNode }: BackspaceProps) => {
|
|
@@ -16,12 +16,12 @@ import { backspaceKeymap } from './backspace';
|
|
|
16
16
|
import { maybeEscapeKeymap } from './maybeEscape';
|
|
17
17
|
|
|
18
18
|
interface KeymapProps {
|
|
19
|
-
|
|
19
|
+
customFindReplace: boolean;
|
|
20
20
|
getNode: () => PMNode;
|
|
21
21
|
getPos: getPosHandlerNode;
|
|
22
|
-
selectCodeBlockNode: (relativeSelectionPos: RelativeSelectionPos | undefined) => void;
|
|
23
22
|
onMaybeNodeSelection: () => void;
|
|
24
|
-
|
|
23
|
+
selectCodeBlockNode: (relativeSelectionPos: RelativeSelectionPos | undefined) => void;
|
|
24
|
+
view: EditorView;
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
export const keymapExtension = ({
|
|
@@ -7,14 +7,14 @@ import { Selection } from '@atlaskit/editor-prosemirror/state';
|
|
|
7
7
|
import { type EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
8
8
|
|
|
9
9
|
interface MaybeEscapeProps {
|
|
10
|
-
unit: 'line' | 'char';
|
|
11
|
-
dir: -1 | 1;
|
|
12
|
-
view: EditorView;
|
|
13
10
|
cm: CodeMirror;
|
|
14
|
-
|
|
11
|
+
dir: -1 | 1;
|
|
15
12
|
getNode: () => PMNode;
|
|
13
|
+
getPos: getPosHandlerNode;
|
|
16
14
|
onMaybeNodeSelection: () => void;
|
|
17
15
|
selectCodeBlockNode: (relativeSelectionPos: RelativeSelectionPos | undefined) => void;
|
|
16
|
+
unit: 'line' | 'char';
|
|
17
|
+
view: EditorView;
|
|
18
18
|
}
|
|
19
19
|
|
|
20
20
|
export const maybeEscapeKeymap = ({
|
|
@@ -32,7 +32,7 @@ export const maybeEscapeKeymap = ({
|
|
|
32
32
|
}
|
|
33
33
|
const node = getNode();
|
|
34
34
|
const { state } = cm;
|
|
35
|
-
let main: {
|
|
35
|
+
let main: { empty: boolean; from: number; head: number; to: number; } = state.selection.main;
|
|
36
36
|
if (!main.empty) {
|
|
37
37
|
return false;
|
|
38
38
|
}
|
|
@@ -30,12 +30,12 @@ type WidgetConstructor = ((view: EditorView, getPos: () => number | undefined) =
|
|
|
30
30
|
// See: https://github.com/ProseMirror/prosemirror-view/blob/master/src/decoration.ts
|
|
31
31
|
interface ExtendedProseMirrorDecoration extends Decoration {
|
|
32
32
|
inline: boolean;
|
|
33
|
-
widget: boolean;
|
|
34
33
|
type: {
|
|
35
34
|
attrs?: Record<string, string>;
|
|
36
|
-
toDOM?: WidgetConstructor;
|
|
37
35
|
side?: number;
|
|
36
|
+
toDOM?: WidgetConstructor;
|
|
38
37
|
};
|
|
38
|
+
widget: boolean;
|
|
39
39
|
}
|
|
40
40
|
|
|
41
41
|
// This type is not exposed publically by ProseMirror but we need it to map to CodeMirror
|
|
@@ -9,10 +9,10 @@ import type { EditorView, DecorationSource, Decoration } from '@atlaskit/editor-
|
|
|
9
9
|
import type { CodeBlockAdvancedPlugin } from '../codeBlockAdvancedPluginType';
|
|
10
10
|
|
|
11
11
|
interface Props {
|
|
12
|
+
allowCodeFolding: boolean;
|
|
12
13
|
api: ExtractInjectionAPI<CodeBlockAdvancedPlugin> | undefined;
|
|
13
14
|
extensions: Extension[];
|
|
14
15
|
getIntl: () => IntlShape;
|
|
15
|
-
allowCodeFolding: boolean;
|
|
16
16
|
}
|
|
17
17
|
|
|
18
18
|
export const lazyCodeBlockView = (props: Props) => {
|
package/src/pm-plugins/main.ts
CHANGED
|
@@ -11,10 +11,10 @@ import { lazyCodeBlockView } from '../nodeviews/lazyCodeBlockAdvanced';
|
|
|
11
11
|
import { shiftArrowDownWorkaround, shiftArrowUpWorkaround } from './shiftArrowKeyWorkaround';
|
|
12
12
|
|
|
13
13
|
interface Props {
|
|
14
|
+
allowCodeFolding: boolean;
|
|
14
15
|
api: ExtractInjectionAPI<CodeBlockAdvancedPlugin> | undefined;
|
|
15
16
|
extensions: Extension[];
|
|
16
17
|
getIntl: () => IntlShape;
|
|
17
|
-
allowCodeFolding: boolean;
|
|
18
18
|
}
|
|
19
19
|
|
|
20
20
|
export const createPlugin = (props: Props) => {
|