Group
创建 Group。用于将元素进行打组,自身没有样式,可以不断嵌套。
实际宽高随子元素变化,不能设置,可以通过 bounds 获取实际宽高信息。
用法
App.vue
Import Map
xxxxxxxxxx
33
<script setup lang="ts">
import { LeaferApp } from 'leafer-vue'
const size = {
width: 50,
height: 50,
}
</script>
<template>
<LeaferApp :width="672" :height="340" type="draw">
<Leafer>
<Group>
<Polygon
:x="10" :y="18"
v-bind="size"
fill="#82DBC5"
/>
<Rect
:x="70" :y="10"
v-bind="size"
fill="#4F4F4F"
/>
<Ellipse
:x="130" :y="10"
v-bind="size"
Show Error
属性
详情查看Group |🌿 Leafer UI。
事件请查看事件处理 |🌿 Leafer Vue