@alilc/lowcode-setter-behavior
交互 setter
Last updated 3 years ago by mark-ck .
MIT · Original npm · Tarball · package.json
$ npm install @alilc/lowcode-setter-behavior 
SYNC missed versions from official npm registry.

Behavior Setter

@alilc/lowcode-setter-behavior

API

参数名 说明 必填 类型 默认值 备注
field 引擎传入属性 true SettingTarget - -
onChange 引擎传入属性,setter 值变化需要调用 onChange 告知引擎 true (value: any) => void - -
actions 待配置的事件列表 true string[] ['onActionClick', 'onClick']
type link or modal or both false string -
value 引擎传入属性,当前值 true any -
url 当前搭建平台获取页面列表的 api false string
responseFormatter 当前搭建平台获取页面列表 api 的返回值处理函数,要将返回值处理成 [{ label: string, value: any }] false (response: any) => ([{ label: string, value: any }]) -
extraBehaviorActions 自定义交互 false BehaviorAction

Interfaces

export interface BehaviorAction<Value = Record<string, any>, Options = Record<string, any>> {
  /** 行为key */
  name: string;
  /** 行为名字,显示在RadioGroup选项 */
  title: string;
  /** 选项渲染 */
  render?: (props: BehaviorActionProps<Value, Options>) => React.ReactNode;
  /** 值序列化为低代码协议的值 */
  toActionValue: (value: Value) => any;
}

Current Tags

  • 1.0.0                                ...           latest (3 years ago)

1 Versions

  • 1.0.0                                ...           3 years ago
Downloads
Total 0
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (3)

© 2010 - cnpmjs.org x YWFE | Home | YWFE