mirror of
https://github.com/vbenjs/gf-vben-admin.git
synced 2025-02-03 03:32:59 +08:00
fix(CodeEditor): add readonly prop (#572)
This commit is contained in:
parent
2f8b2183ec
commit
9cd293c283
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="h-full">
|
<div class="h-full">
|
||||||
<CodeMirrorEditor :value="getValue" @change="handleValueChange" :mode="mode" />
|
<CodeMirrorEditor :value="getValue" @change="handleValueChange" :mode="mode" :readonly="readonly" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
@ -24,6 +24,10 @@
|
|||||||
type: String,
|
type: String,
|
||||||
default: MODE.JSON,
|
default: MODE.JSON,
|
||||||
},
|
},
|
||||||
|
readonly: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
emits: ['change'],
|
emits: ['change'],
|
||||||
setup(props, { emit }) {
|
setup(props, { emit }) {
|
||||||
|
Loading…
Reference in New Issue
Block a user