File tree Expand file tree Collapse file tree 5 files changed +14648
-9
lines changed Expand file tree Collapse file tree 5 files changed +14648
-9
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " @owliehq/editor" ,
3
- "version" : " 1.0 .0" ,
3
+ "version" : " 1.1 .0" ,
4
4
"description" : " A modern WYSIWYG rich-text editor built on top of tiptap and Quasar for Vue.js" ,
5
5
"productName" : " Owlie Quasar Tiptap editor" ,
6
6
"scripts" : {
Original file line number Diff line number Diff line change @@ -98,7 +98,7 @@ import {
98
98
OKatexInline ,
99
99
OFormatClear ,
100
100
OPrint ,
101
- OImage ,
101
+ // OImage,
102
102
OEmbed ,
103
103
RecommendedExtensions ,
104
104
OwlieImageDrag
@@ -180,6 +180,12 @@ export default {
180
180
default : function () {
181
181
return {}
182
182
}
183
+ },
184
+ uploadCallback: {
185
+ type: Function ,
186
+ default : function () {
187
+ return ' '
188
+ }
183
189
}
184
190
},
185
191
components: {
@@ -280,15 +286,14 @@ export default {
280
286
extension = new DynamicClass (' OLink' )
281
287
break
282
288
case ' OwlieImageDrag' :
283
- const uploadFunction = () => {
284
- return ' http://placehold.it/900x350'
285
- }
289
+ console .log (this .uploadCallback )
286
290
287
- extension = new OwlieImageDrag ({ uploadFunction })
291
+ extension = new OwlieImageDrag ({ uploadFunction: this . uploadCallback })
288
292
default :
289
293
try {
290
294
extension = new DynamicClass (extension)
291
295
} catch (e) {
296
+ // console.log(extention)
292
297
console .error (e .message )
293
298
}
294
299
break
Original file line number Diff line number Diff line change @@ -121,8 +121,6 @@ export default class ImageDrag extends Node {
121
121
/ i m a g e / i. test ( file . type )
122
122
)
123
123
124
- console . log ( 'images' , images )
125
-
126
124
if ( images . length === 0 ) {
127
125
return
128
126
}
Original file line number Diff line number Diff line change @@ -21,6 +21,9 @@ export default {
21
21
editable: true ,
22
22
showToolbar: true ,
23
23
showBubble: true ,
24
+ async uploadCallback () {
25
+ return ' http://placehold.it/900x350'
26
+ },
24
27
extensions: [
25
28
// TipTap
26
29
' Bold' ,
@@ -146,7 +149,7 @@ export default {
146
149
onUpdate ({ state, getJSON, getHTML }) {
147
150
this .json = getJSON ()
148
151
this .html = getHTML ()
149
- console .log (' html' , this .html )
152
+ // console.log('html', this.html)
150
153
151
154
// console.log('json', JSON.stringify(this.json))
152
155
}
You can’t perform that action at this time.
0 commit comments