Merge pull request #33 from webzard-io/example

refactor: use expression widget to show data
This commit is contained in:
tanbowensg 2022-02-23 15:50:28 +08:00 committed by Bowen Tan
parent f58cd197c9
commit ee47da58fd
4 changed files with 14 additions and 9 deletions

View File

@ -5,7 +5,8 @@ import { Category } from '../../constants/category'
export const CascaderValueSchema = Type.Array(Type.Union([Type.String(), Type.Array(Type.String())]), {
title:'Default Value',
category: Category.Data
category: Category.Data,
widget:'expression'
})
export const CascaderPropsSchema = {
@ -13,7 +14,8 @@ export const CascaderPropsSchema = {
title:'Options',
weight: 10,
description: `An array of arrays`,
category: Category.Data
category: Category.Data,
widget:'expression'
}),
expandTrigger: StringUnion(['click', 'hover'],{
title:'Expand Trigger',

View File

@ -7,12 +7,13 @@ export const MentionsPropsSchema = {
options: Type.Array(Type.String(), {
title:'Options',
weight: 3,
category:Category.Data
category:Category.Data,
widget:'expression'
}),
defaultValue: Type.String({
title:'Default Value',
weight: 2,
category:Category.Data
category:Category.Data,
}),
prefix: Type.String({
title:'Prefix',

View File

@ -42,7 +42,7 @@ export const ColumnSchema = Type.Object({
export const TablePropsSchema = Type.Object({
data: Type.Array(Type.Any(), {
title: 'Data',
widget: 'CodeEditor',
widget: 'expression',
category: 'Data',
weight: 0
}),

View File

@ -12,11 +12,13 @@ export const TreeSelectPropsSchema = {
children: Type.Array(Type.Any())
}), {
title: 'Options',
category: Category.Data
category: Category.Data,
widget: 'expression'
}),
defaultValue: Type.Array(Type.String(), {
title: 'Default Value',
category: Category.Data
category: Category.Data,
widget: 'expression'
}),
multiple: Type.Boolean({
title: 'Multiple',
@ -29,7 +31,7 @@ export const TreeSelectPropsSchema = {
placeholder: Type.String({
title: 'Placeholder',
category: Category.Basic,
weight:10
weight: 10
}),
size: StringUnion(['mini', 'small', 'default', 'large'], {
title: 'Size',
@ -38,7 +40,7 @@ export const TreeSelectPropsSchema = {
disabled: Type.Boolean({
title: 'Disabled',
category: Category.Basic,
weight:9
weight: 9
}),
showSearch: Type.Boolean({
title: 'Show Search',