@form-create/vant-designer
Version:
基于Vant的移动端低代码可视化表单设计器,可以通过拖拽的方式快速创建表单,提高开发者对表单的开发效率。
47 lines (44 loc) • 971 B
JavaScript
import {localeProps} from '../../utils';
const label = '面板';
const name = 'vanCollapseItem';
export default {
icon: 'icon-cell',
label,
name,
drag: true,
dragBtn: false,
inside: true,
mask: false,
rule({t}) {
return {
type: name,
props: {
title: t('com.vanCollapseItem.name')
},
style: {},
children: []
};
},
props(_, {t}) {
return localeProps(t, name + '.props', [
{
type: 'switch',
field: 'disabled',
}, {
type: 'input',
field: 'name',
}, {
type: 'input',
field: 'title',
},
{
type: 'input',
field: 'value',
},
{
type: 'input',
field: 'label',
}
]);
}
};