@tiptap/vue-2 2.0.0-beta.21 → 2.0.0-beta.210

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.
@@ -1,6 +1,10 @@
1
- import Vue from 'vue'
1
+ import Vue, { Component } from 'vue'
2
2
 
3
- export const NodeViewContent = Vue.extend({
3
+ export interface NodeViewContentInterface extends Vue {
4
+ as: string,
5
+ }
6
+
7
+ export const NodeViewContent: Component = {
4
8
  props: {
5
9
  as: {
6
10
  type: String,
@@ -8,16 +12,14 @@ export const NodeViewContent = Vue.extend({
8
12
  },
9
13
  },
10
14
 
11
- render(createElement) {
12
- return createElement(
13
- this.as, {
14
- style: {
15
- whiteSpace: 'pre-wrap',
16
- },
17
- attrs: {
18
- 'data-node-view-content': '',
19
- },
15
+ render(this: NodeViewContentInterface, createElement) {
16
+ return createElement(this.as, {
17
+ style: {
18
+ whiteSpace: 'pre-wrap',
19
+ },
20
+ attrs: {
21
+ 'data-node-view-content': '',
20
22
  },
21
- )
23
+ })
22
24
  },
23
- })
25
+ }
@@ -1,6 +1,14 @@
1
- import Vue from 'vue'
1
+ import Vue, { Component } from 'vue'
2
2
 
3
- export const NodeViewWrapper = Vue.extend({
3
+ export interface NodeViewWrapperInterface extends Vue {
4
+ as: string,
5
+ decorationClasses: {
6
+ value: string,
7
+ },
8
+ onDragStart: Function,
9
+ }
10
+
11
+ export const NodeViewWrapper: Component = {
4
12
  props: {
5
13
  as: {
6
14
  type: String,
@@ -10,10 +18,10 @@ export const NodeViewWrapper = Vue.extend({
10
18
 
11
19
  inject: ['onDragStart', 'decorationClasses'],
12
20
 
13
- render(createElement) {
21
+ render(this: NodeViewWrapperInterface, createElement) {
14
22
  return createElement(
15
- this.as, {
16
- // @ts-ignore
23
+ this.as,
24
+ {
17
25
  class: this.decorationClasses.value,
18
26
  style: {
19
27
  whiteSpace: 'normal',
@@ -22,11 +30,10 @@ export const NodeViewWrapper = Vue.extend({
22
30
  'data-node-view-wrapper': '',
23
31
  },
24
32
  on: {
25
- // @ts-ignore
26
33
  dragstart: this.onDragStart,
27
34
  },
28
35
  },
29
36
  this.$slots.default,
30
37
  )
31
38
  },
32
- })
39
+ }
@@ -2,53 +2,65 @@ import {
2
2
  NodeView,
3
3
  NodeViewProps,
4
4
  NodeViewRenderer,
5
+ NodeViewRendererOptions,
5
6
  NodeViewRendererProps,
6
7
  } from '@tiptap/core'
7
- import { Decoration, NodeView as ProseMirrorNodeView } from 'prosemirror-view'
8
- import { Node as ProseMirrorNode } from 'prosemirror-model'
8
+ import { Node as ProseMirrorNode } from '@tiptap/pm/model'
9
+ import { Decoration, NodeView as ProseMirrorNodeView } from '@tiptap/pm/view'
9
10
  import Vue from 'vue'
10
- import { VueConstructor, PropType } from 'vue/types/umd'
11
+ import { PropType, VueConstructor } from 'vue/types/umd'
12
+
11
13
  import { Editor } from './Editor'
12
14
  import { VueRenderer } from './VueRenderer'
13
15
 
14
16
  export const nodeViewProps = {
15
17
  editor: {
16
18
  type: Object as PropType<NodeViewProps['editor']>,
17
- required: true,
19
+ required: true as const,
18
20
  },
19
21
  node: {
20
22
  type: Object as PropType<NodeViewProps['node']>,
21
- required: true,
23
+ required: true as const,
22
24
  },
23
25
  decorations: {
24
26
  type: Object as PropType<NodeViewProps['decorations']>,
25
- required: true,
27
+ required: true as const,
26
28
  },
27
29
  selected: {
28
30
  type: Boolean as PropType<NodeViewProps['selected']>,
29
- required: true,
31
+ required: true as const,
30
32
  },
31
33
  extension: {
32
34
  type: Object as PropType<NodeViewProps['extension']>,
33
- required: true,
35
+ required: true as const,
34
36
  },
35
37
  getPos: {
36
38
  type: Function as PropType<NodeViewProps['getPos']>,
37
- required: true,
39
+ required: true as const,
38
40
  },
39
41
  updateAttributes: {
40
42
  type: Function as PropType<NodeViewProps['updateAttributes']>,
41
- required: true,
43
+ required: true as const,
44
+ },
45
+ deleteNode: {
46
+ type: Function as PropType<NodeViewProps['deleteNode']>,
47
+ required: true as const,
42
48
  },
43
49
  }
44
50
 
45
- interface VueNodeViewRendererOptions {
46
- stopEvent: ((event: Event) => boolean) | null,
47
- update: ((node: ProseMirrorNode, decorations: Decoration[]) => boolean) | null,
51
+ export interface VueNodeViewRendererOptions extends NodeViewRendererOptions {
52
+ update:
53
+ | ((props: {
54
+ oldNode: ProseMirrorNode
55
+ oldDecorations: Decoration[]
56
+ newNode: ProseMirrorNode
57
+ newDecorations: Decoration[]
58
+ updateProps: () => void
59
+ }) => boolean)
60
+ | null
48
61
  }
49
62
 
50
- class VueNodeView extends NodeView<(Vue | VueConstructor), Editor> {
51
-
63
+ class VueNodeView extends NodeView<Vue | VueConstructor, Editor, VueNodeViewRendererOptions> {
52
64
  renderer!: VueRenderer
53
65
 
54
66
  decorationClasses!: {
@@ -64,6 +76,7 @@ class VueNodeView extends NodeView<(Vue | VueConstructor), Editor> {
64
76
  extension: this.extension,
65
77
  getPos: () => this.getPos(),
66
78
  updateAttributes: (attributes = {}) => this.updateAttributes(attributes),
79
+ deleteNode: () => this.deleteNode(),
67
80
  }
68
81
 
69
82
  const onDragStart = this.onDragStart.bind(this)
@@ -72,17 +85,18 @@ class VueNodeView extends NodeView<(Vue | VueConstructor), Editor> {
72
85
  value: this.getDecorationClasses(),
73
86
  })
74
87
 
75
- const Component = Vue
76
- .extend(this.component)
77
- .extend({
78
- props: Object.keys(props),
79
- provide: () => {
80
- return {
81
- onDragStart,
82
- decorationClasses: this.decorationClasses,
83
- }
84
- },
85
- })
88
+ // @ts-ignore
89
+ const vue = this.editor.contentComponent?.$options._base ?? Vue // eslint-disable-line
90
+
91
+ const Component = vue.extend(this.component).extend({
92
+ props: Object.keys(props),
93
+ provide: () => {
94
+ return {
95
+ onDragStart,
96
+ decorationClasses: this.decorationClasses,
97
+ }
98
+ },
99
+ })
86
100
 
87
101
  this.renderer = new VueRenderer(Component, {
88
102
  parent: this.editor.contentComponent,
@@ -95,7 +109,7 @@ class VueNodeView extends NodeView<(Vue | VueConstructor), Editor> {
95
109
  throw Error('Please use the NodeViewWrapper component for your node view.')
96
110
  }
97
111
 
98
- return this.renderer.element
112
+ return this.renderer.element as HTMLElement
99
113
  }
100
114
 
101
115
  get contentDOM() {
@@ -105,12 +119,29 @@ class VueNodeView extends NodeView<(Vue | VueConstructor), Editor> {
105
119
 
106
120
  const contentElement = this.dom.querySelector('[data-node-view-content]')
107
121
 
108
- return contentElement || this.dom
122
+ return (contentElement || this.dom) as HTMLElement | null
109
123
  }
110
124
 
111
125
  update(node: ProseMirrorNode, decorations: Decoration[]) {
126
+ const updateProps = (props?: Record<string, any>) => {
127
+ this.decorationClasses.value = this.getDecorationClasses()
128
+ this.renderer.updateProps(props)
129
+ }
130
+
112
131
  if (typeof this.options.update === 'function') {
113
- return this.options.update(node, decorations)
132
+ const oldNode = this.node
133
+ const oldDecorations = this.decorations
134
+
135
+ this.node = node
136
+ this.decorations = decorations
137
+
138
+ return this.options.update({
139
+ oldNode,
140
+ oldDecorations,
141
+ newNode: node,
142
+ newDecorations: decorations,
143
+ updateProps: () => updateProps({ node, decorations }),
144
+ })
114
145
  }
115
146
 
116
147
  if (node.type !== this.node.type) {
@@ -123,8 +154,8 @@ class VueNodeView extends NodeView<(Vue | VueConstructor), Editor> {
123
154
 
124
155
  this.node = node
125
156
  this.decorations = decorations
126
- this.decorationClasses.value = this.getDecorationClasses()
127
- this.renderer.updateProps({ node, decorations })
157
+
158
+ updateProps({ node, decorations })
128
159
 
129
160
  return true
130
161
  }
@@ -142,20 +173,24 @@ class VueNodeView extends NodeView<(Vue | VueConstructor), Editor> {
142
173
  }
143
174
 
144
175
  getDecorationClasses() {
145
- return this.decorations
146
- // @ts-ignore
147
- .map(item => item.type.attrs.class)
148
- .flat()
149
- .join(' ')
176
+ return (
177
+ this.decorations
178
+ // @ts-ignore
179
+ .map(item => item.type.attrs.class)
180
+ .flat()
181
+ .join(' ')
182
+ )
150
183
  }
151
184
 
152
185
  destroy() {
153
186
  this.renderer.destroy()
154
187
  }
155
-
156
188
  }
157
189
 
158
- export function VueNodeViewRenderer(component: Vue | VueConstructor, options?: Partial<VueNodeViewRendererOptions>): NodeViewRenderer {
190
+ export function VueNodeViewRenderer(
191
+ component: Vue | VueConstructor,
192
+ options?: Partial<VueNodeViewRendererOptions>,
193
+ ): NodeViewRenderer {
159
194
  return (props: NodeViewRendererProps) => {
160
195
  // try to get the parent component
161
196
  // this is important for vue devtools to show the component hierarchy correctly
@@ -164,6 +199,6 @@ export function VueNodeViewRenderer(component: Vue | VueConstructor, options?: P
164
199
  return {}
165
200
  }
166
201
 
167
- return new VueNodeView(component, props, options) as ProseMirrorNodeView
202
+ return new VueNodeView(component, props, options) as unknown as ProseMirrorNodeView
168
203
  }
169
204
  }
@@ -5,7 +5,7 @@ export class VueRenderer {
5
5
  ref!: Vue
6
6
 
7
7
  constructor(component: Vue | VueConstructor, props: any) {
8
- const Component = Vue.extend(component)
8
+ const Component = (typeof component === 'function') ? component : Vue.extend(component)
9
9
 
10
10
  this.ref = new Component(props).$mount()
11
11
  }
@@ -20,8 +20,11 @@ export class VueRenderer {
20
20
  }
21
21
 
22
22
  // prevents `Avoid mutating a prop directly` error message
23
- const originalSilent = Vue.config.silent
24
- Vue.config.silent = true
23
+ // Fix: `VueNodeViewRenderer` change vue Constructor `config.silent` not working
24
+ const currentVueConstructor = this.ref.$props.editor?.contentComponent?.$options._base ?? Vue // eslint-disable-line
25
+ const originalSilent = currentVueConstructor.config.silent
26
+
27
+ currentVueConstructor.config.silent = true
25
28
 
26
29
  Object
27
30
  .entries(props)
@@ -29,7 +32,7 @@ export class VueRenderer {
29
32
  this.ref.$props[key] = value
30
33
  })
31
34
 
32
- Vue.config.silent = originalSilent
35
+ currentVueConstructor.config.silent = originalSilent
33
36
  }
34
37
 
35
38
  destroy(): void {
package/src/index.ts CHANGED
@@ -1,9 +1,9 @@
1
- export * from '@tiptap/core'
2
1
  export * from './BubbleMenu'
3
2
  export { Editor } from './Editor'
4
3
  export * from './EditorContent'
5
4
  export * from './FloatingMenu'
6
- export * from './VueRenderer'
7
- export * from './VueNodeViewRenderer'
8
- export * from './NodeViewWrapper'
9
5
  export * from './NodeViewContent'
6
+ export * from './NodeViewWrapper'
7
+ export * from './VueNodeViewRenderer'
8
+ export * from './VueRenderer'
9
+ export * from '@tiptap/core'
package/CHANGELOG.md DELETED
@@ -1,180 +0,0 @@
1
- # Change Log
2
-
3
- All notable changes to this project will be documented in this file.
4
- See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
-
6
- # [2.0.0-beta.21](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.20...@tiptap/vue-2@2.0.0-beta.21) (2021-04-23)
7
-
8
- **Note:** Version bump only for package @tiptap/vue-2
9
-
10
-
11
-
12
-
13
-
14
- # [2.0.0-beta.20](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.19...@tiptap/vue-2@2.0.0-beta.20) (2021-04-22)
15
-
16
- **Note:** Version bump only for package @tiptap/vue-2
17
-
18
-
19
-
20
-
21
-
22
- # [2.0.0-beta.19](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.18...@tiptap/vue-2@2.0.0-beta.19) (2021-04-21)
23
-
24
- **Note:** Version bump only for package @tiptap/vue-2
25
-
26
-
27
-
28
-
29
-
30
- # [2.0.0-beta.18](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.17...@tiptap/vue-2@2.0.0-beta.18) (2021-04-16)
31
-
32
-
33
- ### Features
34
-
35
- * add tippyOptions prop ([9a56f66](https://github.com/ueberdosis/tiptap/commit/9a56f666a118ca7c59a6f1f67f40e6490e20d3b8))
36
- * remove keepInBounds ([d7282f1](https://github.com/ueberdosis/tiptap/commit/d7282f168bc6cfae4e1630d14bb8462bc135b254))
37
-
38
-
39
-
40
-
41
-
42
- # [2.0.0-beta.17](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.16...@tiptap/vue-2@2.0.0-beta.17) (2021-04-15)
43
-
44
- **Note:** Version bump only for package @tiptap/vue-2
45
-
46
-
47
-
48
-
49
-
50
- # [2.0.0-beta.16](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.15...@tiptap/vue-2@2.0.0-beta.16) (2021-04-08)
51
-
52
- **Note:** Version bump only for package @tiptap/vue-2
53
-
54
-
55
-
56
-
57
-
58
- # [2.0.0-beta.15](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.14...@tiptap/vue-2@2.0.0-beta.15) (2021-04-08)
59
-
60
- **Note:** Version bump only for package @tiptap/vue-2
61
-
62
-
63
-
64
-
65
-
66
- # [2.0.0-beta.14](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.13...@tiptap/vue-2@2.0.0-beta.14) (2021-04-03)
67
-
68
- **Note:** Version bump only for package @tiptap/vue-2
69
-
70
-
71
-
72
-
73
-
74
- # [2.0.0-beta.13](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.12...@tiptap/vue-2@2.0.0-beta.13) (2021-04-01)
75
-
76
- **Note:** Version bump only for package @tiptap/vue-2
77
-
78
-
79
-
80
-
81
-
82
- # [2.0.0-beta.12](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.11...@tiptap/vue-2@2.0.0-beta.12) (2021-04-01)
83
-
84
- **Note:** Version bump only for package @tiptap/vue-2
85
-
86
-
87
-
88
-
89
-
90
- # [2.0.0-beta.11](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.10...@tiptap/vue-2@2.0.0-beta.11) (2021-04-01)
91
-
92
- **Note:** Version bump only for package @tiptap/vue-2
93
-
94
-
95
-
96
-
97
-
98
- # [2.0.0-beta.10](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.9...@tiptap/vue-2@2.0.0-beta.10) (2021-04-01)
99
-
100
- **Note:** Version bump only for package @tiptap/vue-2
101
-
102
-
103
-
104
-
105
-
106
- # [2.0.0-beta.9](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.8...@tiptap/vue-2@2.0.0-beta.9) (2021-03-31)
107
-
108
- **Note:** Version bump only for package @tiptap/vue-2
109
-
110
-
111
-
112
-
113
-
114
- # [2.0.0-beta.8](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.7...@tiptap/vue-2@2.0.0-beta.8) (2021-03-31)
115
-
116
- **Note:** Version bump only for package @tiptap/vue-2
117
-
118
-
119
-
120
-
121
-
122
- # [2.0.0-beta.7](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.6...@tiptap/vue-2@2.0.0-beta.7) (2021-03-31)
123
-
124
- **Note:** Version bump only for package @tiptap/vue-2
125
-
126
-
127
-
128
-
129
-
130
- # [2.0.0-beta.6](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.5...@tiptap/vue-2@2.0.0-beta.6) (2021-03-28)
131
-
132
- **Note:** Version bump only for package @tiptap/vue-2
133
-
134
-
135
-
136
-
137
-
138
- # [2.0.0-beta.5](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.4...@tiptap/vue-2@2.0.0-beta.5) (2021-03-24)
139
-
140
- **Note:** Version bump only for package @tiptap/vue-2
141
-
142
-
143
-
144
-
145
-
146
- # [2.0.0-beta.4](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.3...@tiptap/vue-2@2.0.0-beta.4) (2021-03-18)
147
-
148
- **Note:** Version bump only for package @tiptap/vue-2
149
-
150
-
151
-
152
-
153
-
154
- # [2.0.0-beta.3](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.2...@tiptap/vue-2@2.0.0-beta.3) (2021-03-17)
155
-
156
- **Note:** Version bump only for package @tiptap/vue-2
157
-
158
-
159
-
160
-
161
-
162
- # [2.0.0-beta.2](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-beta.1...@tiptap/vue-2@2.0.0-beta.2) (2021-03-16)
163
-
164
- **Note:** Version bump only for package @tiptap/vue-2
165
-
166
-
167
-
168
-
169
-
170
- # [2.0.0-beta.1](https://github.com/ueberdosis/tiptap/compare/@tiptap/vue-2@2.0.0-alpha.1...@tiptap/vue-2@2.0.0-beta.1) (2021-03-05)
171
-
172
- **Note:** Version bump only for package @tiptap/vue-2
173
-
174
-
175
-
176
-
177
-
178
- # 2.0.0-alpha.1 (2021-02-28)
179
-
180
- **Note:** Version bump only for package @tiptap/vue-2
package/LICENSE.md DELETED
@@ -1,21 +0,0 @@
1
- MIT License
2
-
3
- Copyright (c) 2020, überdosis GbR
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
@@ -1,5 +0,0 @@
1
- import Vue from 'vue';
2
- export declare const BubbleMenu: import("vue/types/vue").ExtendedVue<Vue, unknown, unknown, unknown, {
3
- editor: import("@tiptap/core").Editor;
4
- tippyOptions: {} | undefined;
5
- }>;
@@ -1,5 +0,0 @@
1
- import { Editor as CoreEditor } from '@tiptap/core';
2
- import Vue from 'vue';
3
- export declare class Editor extends CoreEditor {
4
- contentComponent: Vue | null;
5
- }
@@ -1,5 +0,0 @@
1
- import Vue from 'vue';
2
- import { Editor } from './Editor';
3
- export declare const EditorContent: import("vue/types/vue").ExtendedVue<Vue, unknown, unknown, unknown, {
4
- editor: Editor;
5
- }>;
@@ -1,5 +0,0 @@
1
- import Vue from 'vue';
2
- export declare const FloatingMenu: import("vue/types/vue").ExtendedVue<Vue, unknown, unknown, unknown, {
3
- editor: import("@tiptap/core").Editor;
4
- tippyOptions: {} | undefined;
5
- }>;
@@ -1,4 +0,0 @@
1
- import Vue from 'vue';
2
- export declare const NodeViewContent: import("vue/types/vue").ExtendedVue<Vue, unknown, unknown, unknown, {
3
- as: string;
4
- }>;
@@ -1,4 +0,0 @@
1
- import Vue from 'vue';
2
- export declare const NodeViewWrapper: import("vue/types/vue").ExtendedVue<Vue, unknown, unknown, unknown, {
3
- as: string;
4
- }>;
@@ -1,43 +0,0 @@
1
- import { NodeViewRenderer } from '@tiptap/core';
2
- import { Decoration } from 'prosemirror-view';
3
- import { Node as ProseMirrorNode } from 'prosemirror-model';
4
- import Vue from 'vue';
5
- import { VueConstructor, PropType } from 'vue/types/umd';
6
- export declare const nodeViewProps: {
7
- editor: {
8
- type: PropType<import("@tiptap/core").Editor>;
9
- required: boolean;
10
- };
11
- node: {
12
- type: PropType<ProseMirrorNode<any>>;
13
- required: boolean;
14
- };
15
- decorations: {
16
- type: PropType<Decoration<{
17
- [key: string]: any;
18
- }>[]>;
19
- required: boolean;
20
- };
21
- selected: {
22
- type: PropType<boolean>;
23
- required: boolean;
24
- };
25
- extension: {
26
- type: PropType<import("@tiptap/core").Node<any>>;
27
- required: boolean;
28
- };
29
- getPos: {
30
- type: PropType<() => number>;
31
- required: boolean;
32
- };
33
- updateAttributes: {
34
- type: PropType<(attributes: Record<string, any>) => void>;
35
- required: boolean;
36
- };
37
- };
38
- interface VueNodeViewRendererOptions {
39
- stopEvent: ((event: Event) => boolean) | null;
40
- update: ((node: ProseMirrorNode, decorations: Decoration[]) => boolean) | null;
41
- }
42
- export declare function VueNodeViewRenderer(component: Vue | VueConstructor, options?: Partial<VueNodeViewRendererOptions>): NodeViewRenderer;
43
- export {};
@@ -1,9 +0,0 @@
1
- import Vue from 'vue';
2
- import { VueConstructor } from 'vue/types/umd';
3
- export declare class VueRenderer {
4
- ref: Vue;
5
- constructor(component: Vue | VueConstructor, props: any);
6
- get element(): Element;
7
- updateProps(props?: Record<string, any>): void;
8
- destroy(): void;
9
- }
@@ -1,9 +0,0 @@
1
- export * from '@tiptap/core';
2
- export * from './BubbleMenu';
3
- export { Editor } from './Editor';
4
- export * from './EditorContent';
5
- export * from './FloatingMenu';
6
- export * from './VueRenderer';
7
- export * from './VueNodeViewRenderer';
8
- export * from './NodeViewWrapper';
9
- export * from './NodeViewContent';