Skip to content

Commit

Permalink
feat: 调整layout导入
Browse files Browse the repository at this point in the history
  • Loading branch information
lichunn committed Jun 12, 2024
1 parent 2c6491c commit cd677f3
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 22 deletions.
13 changes: 0 additions & 13 deletions packages/layout/src/DesignCanvas.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,22 +9,13 @@
@remove="removeNode"
@selected="nodeSelected"
></component>
<!-- <canvas-container
:controller="controller"
:materials-panel="materialsPanel"
:canvas-src="canvasUrl"
@remove="removeNode"
@selected="nodeSelected"
></canvas-container> -->
</div>
<component :is="canvas.component.CanvasFooter" :data="footData" @click="selectFooterNode"></component>
<!-- <footer-bar :data="footData" @click="selectFooterNode"></footer-bar> -->
</div>
</template>

<script>
import { ref, watch, computed, onUnmounted } from 'vue'
// import { CanvasContainer, CanvasFooter } from '@opentiny/tiny-engine-canvas'
import {
useProperties,
useCanvas,
Expand Down Expand Up @@ -52,10 +43,6 @@ const componentType = {
}
export default {
components: {
// CanvasContainer,
// FooterBar: CanvasFooter////
},
props: {
canvas: {
type: Object
Expand Down
2 changes: 0 additions & 2 deletions packages/layout/src/DesignPlugins.vue
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@
import { reactive, ref, watch } from 'vue'
import { Popover, Tooltip } from '@opentiny/vue'
import { useLayout, usePage } from '@opentiny/tiny-engine-controller'
// import { getMergeRegistry } from '@opentiny/tiny-engine-entry'
import { PublicIcon } from '@opentiny/tiny-engine-common'
export default {
Expand All @@ -116,7 +115,6 @@ export default {
},
emits: ['click', 'node-click'],
setup(props, { emit }) {
// const plugins = getMergeRegistry('plugins')
const components = {}
const iconComponents = {}
const pluginRef = ref(null)
Expand Down
10 changes: 6 additions & 4 deletions packages/layout/src/DesignSettings.vue
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,25 @@
import { computed, ref } from 'vue'
import { Tabs, TabItem } from '@opentiny/vue'
import { useLayout } from '@opentiny/tiny-engine-controller'
import { getMergeRegistry } from '@opentiny/tiny-engine-entry'
export default {
components: {
TinyTabs: Tabs,
TinyTabItem: TabItem
},
props: {
settings: {
type: Array,
default: () => []
}
},
setup() {
const { layoutState } = useLayout()
const settings = getMergeRegistry('settings')
const activating = computed(() => layoutState.settings.activating)
const showMask = ref(true)
return {
showMask,
settings,
activating,
layoutState
}
Expand Down
11 changes: 8 additions & 3 deletions packages/layout/src/DesignToolbars.vue
Original file line number Diff line number Diff line change
Expand Up @@ -19,21 +19,26 @@
import { reactive, nextTick } from 'vue'
import { useLayout } from '@opentiny/tiny-engine-controller'
import { ProgressBar } from '@opentiny/tiny-engine-common'
import { getMergeRegistry } from '@opentiny/tiny-engine-entry'
export default {
components: {
ProgressBar
},
setup() {
props: {
toolbars: {
type: Array,
default: () => []
}
},
setup(props) {
const leftBar = []
const rightBar = []
const centerBar = []
const state = reactive({
showDeployBlock: false
})
getMergeRegistry('toolbars').forEach((item) => {
props.toolbars.forEach((item) => {
if (item.align === 'right') {
rightBar.push(item)
} else if (item.align === 'center') {
Expand Down

0 comments on commit cd677f3

Please sign in to comment.