File tree Expand file tree Collapse file tree 1 file changed +3
-34
lines changed
packages/carbon-component-mapper/demo Expand file tree Collapse file tree 1 file changed +3
-34
lines changed Original file line number Diff line number Diff line change 1
1
import React from 'react' ;
2
2
import ReactDOM from 'react-dom' ;
3
3
import FormRenderer from '@data-driven-forms/react-form-renderer' ;
4
- // import { arraySchemaDDF } from './demo-schemas/widget-schema';
4
+ import { arraySchemaDDF } from './demo-schemas/widget-schema' ;
5
5
import { componentMapper , FormTemplate } from '../src' ;
6
6
import { wizardSchema } from './demo-schemas/wizard-schema' ;
7
7
import sandboxSchema from './demo-schemas/sandbox' ;
@@ -10,7 +10,7 @@ import demoSchema from '@data-driven-forms/common/src/demoschema';
10
10
import { Button } from 'carbon-components-react' ;
11
11
12
12
const fieldArrayState = {
13
- schema : demoSchema ,
13
+ schema : arraySchemaDDF ,
14
14
additionalOptions : {
15
15
initialValues : {
16
16
number : [ 1 , 2 , 3 , 4 ] ,
@@ -45,38 +45,7 @@ class App extends React.Component {
45
45
componentMapper = { componentMapper }
46
46
FormTemplate = { ( props ) => < FormTemplate { ...props } showFormControls = { this . state . additionalOptions . showFormControls } /> }
47
47
onCancel = { console . log }
48
- //schema={this.state.schema}
49
- schema = { {
50
- fields : [
51
- {
52
- component : 'dual-list-select' ,
53
- name : 'dual-list' ,
54
- label : 'select animal' ,
55
- options : [
56
- {
57
- value : 'cats' ,
58
- label : 'cats'
59
- } ,
60
- {
61
- value : 'cats_1' ,
62
- label : 'cats_1'
63
- } ,
64
- {
65
- value : 'cats_2' ,
66
- label : 'cats_2'
67
- } ,
68
- {
69
- value : 'zebras' ,
70
- label : 'zebras'
71
- } ,
72
- {
73
- value : 'pigeons' ,
74
- label : 'pigeons'
75
- }
76
- ]
77
- }
78
- ]
79
- } }
48
+ schema = { this . state . schema }
80
49
{ ...this . state . additionalOptions }
81
50
/>
82
51
</ div >
You can’t perform that action at this time.
0 commit comments