布局组件

文档版本:1.2.0

组件名:BhtLayout

描述

布局编辑组件,用于维护页面画布、组件拖拽、定位和保存。

效果

暂无缩略图。

示例

<bht-layout></bht-layout>

代码

<bht-layout :ref="item.id" :item="item"></bht-layout>

<BhtLayout :ref="item.id" :item="item"></BhtLayout>

参数

该组件未声明外部 props。

组件配置项

暂无配置项。

画布配置

布局编辑器内部维护 BhtCanvasConfig,用于控制画布设备、尺寸和样式。

key名称类型默认值说明
canvasDevice布局设备selectpcpc、tablet、mobile
canvasMode画布模式selectfluidfluid、fixed
canvasComponentSizing组件尺寸策略selectresponsiveresponsive、fixed
canvasAlign画布对齐selectcenterleft、center、right
canvasPcWidthPC 宽度string100vw例如 100vw、1440px
canvasPcHeightPC 高度string100vh例如 100vh、900px
canvasTabletWidth平板宽度string768px例如 768px
canvasTabletHeight平板高度string1024px例如 1024px
canvasMobileWidth手机宽度string390px例如 390px
canvasMobileHeight手机高度string844px例如 844px
canvasFixedComponentWidth固定组件宽度string320px组件尺寸为固定时的默认宽度
canvasFixedComponentAlign固定组件对齐selectcenterleft、center、right
canvasStageBackgroundColor工作区背景色color#f3f6fb请选择工作区背景色
canvasBackgroundColor画布背景色color#ffffff请选择画布背景色
canvasBorderColor画布边框色color#d7dee8请选择画布边框色
canvasBorderWidth画布边框宽度string0例如 0、1px
canvasBorderStyle画布边框样式selectsolidsolid、dashed、none
canvasBorderRadius画布圆角string0例如 0、12px
canvasPadding画布内边距string0例如 0、24px
canvasStagePadding工作区内边距string0例如 0、32px
canvasMinHeight画布最小高度string720px兼容旧配置,例如 720px、100vh
canvasBoxShadow画布阴影stringnone例如 none、0 24px 54px rgba(...)
canvasOverflow画布溢出selectvisiblevisible、hidden、auto
canvasCustomStyle自定义样式string-例如 background-image: linear-gradient(...);

引入

import { BhtLayout } from '@behappyto/cms-ui-vue3'