You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
549 B
26 lines
549 B
1 year ago
|
<template>
|
||
|
<w-dialog ref="dialogRef" :title="$t('re.dictionary.sampleJson.dialog.title')" width="600px" :can-maximize="false">
|
||
|
<w-code-mirror v-model="sourceCodeRef" lang="json" :rows="15"></w-code-mirror>
|
||
|
</w-dialog>
|
||
|
</template>
|
||
|
<script setup lang="ts">
|
||
|
import { ref } from 'vue';
|
||
|
|
||
|
const dialogRef = ref();
|
||
|
const sourceCodeRef = ref();
|
||
|
|
||
|
const open = (sourceCode: string) => {
|
||
|
sourceCodeRef.value = sourceCode;
|
||
|
dialogRef.value.show();
|
||
|
};
|
||
|
|
||
|
const close = () => {
|
||
|
dialogRef.value.hide();
|
||
|
};
|
||
|
|
||
|
defineExpose({
|
||
|
open,
|
||
|
close,
|
||
|
});
|
||
|
</script>
|