-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtemp_editor.txt
More file actions
66 lines (60 loc) · 3.25 KB
/
temp_editor.txt
File metadata and controls
66 lines (60 loc) · 3.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
<template>
<div class="editor2d-page">
<t-layout>
<t-header>
<Header/>
</t-header>
<t-layout>
<t-aside>
<Graphics/>
</t-aside>
<t-layout>
<t-content>
<editor-view/>
</t-content>
</t-layout>
<t-aside style="width: auto">
<Props/>
</t-aside>
</t-layout>
</t-layout>
</div>
</template>
<script lang="ts">
import Props from './props/Props.vue';
import Header from './header/Header.vue';
import Graphics from './graphics/Graphics.vue';
import EditorView from './editor-view/EditorView.vue';
import {defineComponent, onBeforeMount} from "vue";
import {Editor2DProps} from "./editor2d-type";
import {ExtendGraphic} from "./core/editor2d-graphics.ts";
import {globalEditor2DConfig} from "./core/editor2d-global-data";
export default defineComponent({
name: 'GenerateForm',
components: {Props, Header, Graphics, EditorView},
props: Editor2DProps,
setup(props) {
const init = (props: any) => {
if (!props.displayMenuTitle) {
globalEditor2DConfig.displayMenuTitle = props.displayMenuTitle;
}
if (!props.displayMenuIcon) {
globalEditor2DConfig.displayMenuIcon = props.displayMenuIcon;
}
if (props.disabledTips) {
globalEditor2DConfig.disabledTips = props.disabledTips;
}
new ExtendGraphic().init(props.options);
}
onBeforeMount(() => {
init(props);
})
}
})
</script>
<style scoped lang="less">
.editor2d-page {
height: 100vh;
overflow: hidden;
}
</style>