We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8bc06d5 commit 5a4ac16Copy full SHA for 5a4ac16
src/components/Code.vue
@@ -4,9 +4,10 @@
4
<CodeEditor v-if="codeDialogVisible" style="max-height: 65vh;" ref="codeEditor" :initCode="outputCode"
5
mode="text/html"></CodeEditor>
6
<div style="color: #666; font-size: 12px; text-align:center; margin: 5px;">使用代码前请确认相应的组件库已集成至项目</div>
7
- <div style="text-aligin:center;">
+ <div style="text-align:center;">
8
<el-row>
9
<el-col :span="12">
10
+ 输出形式:
11
<el-radio-group v-model="outputMode">
12
<el-radio label="vue">Vue</el-radio>
13
<el-radio label="html">单页Html</el-radio>
@@ -79,7 +80,12 @@ export default {
79
80
let blob = new Blob([this.outputCode], {
81
type: "text/plain;charset=utf-8",
82
});
- saveAs(blob, "VueComponent.vue");
83
+
84
+ if (this.isVueMode) {
85
+ saveAs(blob, "VueComponent.vue");
86
+ } else {
87
+ saveAs(blob, "vcc.html");
88
+ }
89
},
90
91
0 commit comments