Merge pull request #1973 from burakcakirel/readonly-html-editor
Add readonly attribute for text editor
This commit is contained in:
commit
db099d64eb
@ -37,6 +37,10 @@ export default {
|
|||||||
type: String,
|
type: String,
|
||||||
default: 'snow'
|
default: 'snow'
|
||||||
},
|
},
|
||||||
|
readonly: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false
|
||||||
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
data () {
|
data () {
|
||||||
@ -58,7 +62,8 @@ export default {
|
|||||||
theme: theme,
|
theme: theme,
|
||||||
modules: {
|
modules: {
|
||||||
toolbar: `#${this.toolbarId}`
|
toolbar: `#${this.toolbarId}`
|
||||||
}
|
},
|
||||||
|
readOnly: this.readonly
|
||||||
});
|
});
|
||||||
|
|
||||||
if (this.editorValue.length > 0) {
|
if (this.editorValue.length > 0) {
|
||||||
|
@ -31,6 +31,10 @@
|
|||||||
@if (isset($attributes['disabled']))
|
@if (isset($attributes['disabled']))
|
||||||
:disabled="{{ $attributes['disabled'] }}"
|
:disabled="{{ $attributes['disabled'] }}"
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
|
@if (isset($attributes['readonly']))
|
||||||
|
:readonly="{{ $attributes['readonly'] }}"
|
||||||
|
@endif
|
||||||
></akaunting-html-editor>
|
></akaunting-html-editor>
|
||||||
|
|
||||||
<div class="invalid-feedback d-block"
|
<div class="invalid-feedback d-block"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user