Skip to content

编组

关键方法

group ( custom: IGroup | IGroupInputData): IGroup

将选中的元素进行编组,支持传入一个自定义的 Group 实例 或 json 对象。

新的 group 将增加如下属性:

ts
group.editable = true
group.hitChildren = false

ungroup ( ): UI[]

将选中的元素进行解组。

注意 Box / Frame 元素不支持解组,防止产生问题,如需编组/解组,请使用 Group 元素代替

开关组

openGroup ( IGroup )

打开组, 模拟双击打开组的功能。

closeGroup ( IGroup )

关闭组。

归属

Editor 元素

Released under the MIT License.