formatting q-editor's url link input when wrapped in q-field
-
I wanted to add some validations so wrapped
q-editor
inq-field
but that messes up link input box as well. Any advise how I can fix this?<q-field label="Description" v-model="qeditor" outlined stack-label :rules="[val => !!val || 'Description is required']"> <template v-slot:control> <q-editor flat v-model="qeditor" :toolbar="[ ['bold', 'italic', 'strike', 'underline', 'subscript', 'superscript'], ['hr', 'link'], ['removeFormat' ], ['undo', 'redo'] ]" ></q-editor> </template> </q-field>
Output:
-
This happens because qinput and qselect is already wrapped in a qfield internally. As you see in the warning https://quasar.dev/vue-components/field#Introduction
-
Thanks. I did not wrap either qinput or qselect in qfield. I believe qeditor is internally using qinput for URL which I am not sure how to fix!
-
Any help on how to fix this?
-
I have updated to Quasar version 1.1.4 and the above code is now giving error as soon as I hit the link button.
"[Vue warn]: Error in nextTick: 'TypeError: Cannot read property 'selectNodeContents' of undefined' found in ---> <QEditor> <QField> <Root>" TypeError: Cannot read property 'selectNodeContents' of undefined at VueComponent.<anonymous> (editor-caret.js:223) at Array.<anonymous> (vue.runtime.esm.js:1980) at flushCallbacks (vue.runtime.esm.js:1906)
-
Added issue on Github as a bug!
https://github.com/quasarframework/quasar/issues/5134