jsonforms - 组件
这个库是用 无。 。 。 .
运行单元测试
运行 nx test jsonforms-components 通过 欢乐。 。 。 .
文件夹等级
- src
- lib
- Additional
- Cells
- common
- Components
- Controls
- Context
- ErrorHandling
- layouts
- util
嵌入中的 ADSP 应用程序中的窗体服务 UI 组件
要使用 ADSP 表格服务 UI 组件在 JSON 表格中添加到您的应用程序中 。 您必须加入以下 JSX 标记并输入到您的反应组件中作为例子 .
import { JsonForms } from '@jsonforms/react';
import {
GoARenderers,
} from '@abgov/jsonforms-components';
<JsonForms
schema={yourJSONDataSchema}
uischema={yourJSONUISchema}
data={data}
validationMode="ValidateAndShow"
renderers={GoARenderers}
onChange={onChange}
/>
高级秘书处 窗体服务 UI 组件 UI schema
UI 司马 在JSON表格中定义了生成的形式的一般布局. @abgov/jsonforms-组件 lib 集成 GoA UI 组件 通过扩展UI Schema中的"选项"属性来构成组件。 以GOAInput UI Schema为例: https://govalta.github.io/adsp-monorepo/tourics/form-service/building-forms.html 互联网档案馆的存檔,存档日期2014-12-22
{
"type": "Control",
"scope": "#/properties/name",
"options": {
"GoAInput": {
"name": "Name",
"label": "Name",
"testId": ""
...
}
}
}
"GOAInput"的存在表明我们将使用GOAInput来提供输入. “ GOAInput” 中的属性将作为组件属性传递给 GOAInput .
有关控制、布局、阶梯的更多信息和使用情况,请参见ADSP表格服务指南,该指南提供了更多信息 深度资料 关于用法.
请参看 骗局 它包含用于当前从ADSP Form服务UI组件中可以获得的不同类型的控件、阶梯、布局等的图例,可用于您的应用程序的UI计划.