Skip to content

Commit 593200d

Browse files
committed
Revert changes in demo
1 parent 556bfeb commit 593200d

File tree

1 file changed

+25
-3
lines changed
  • packages/react-form-renderer/demo

1 file changed

+25
-3
lines changed

packages/react-form-renderer/demo/index.js

Lines changed: 25 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,13 +59,35 @@ const conditionLogicDemo = {
5959
title: 'Testing Conditions',
6060
description: 'Write X in both',
6161
fields: [
62+
{
63+
name: 'text_box_1',
64+
label: 'Text Box 1',
65+
title: 'Text Box',
66+
component: 'text-field',
67+
clearOnUnmount: true,
68+
condition: {
69+
sequence: [
70+
{ when: 'a', is: 'x', then: { visible: true, set: { password: 'defaultPassword' } }, else: { set: { password: 'no password' } } },
71+
{ when: 'b', is: 'x', then: { visible: true, set: { text_box_1: 'defaultText' } } }
72+
]
73+
}
74+
},
6275
{
6376
name: 'a',
6477
label: 'a',
6578
title: 'a',
66-
initialValue: '1',
67-
dataType: 'number',
68-
type: 'number',
79+
component: 'text-field'
80+
},
81+
{
82+
name: 'b',
83+
label: 'b',
84+
title: 'b',
85+
component: 'text-field'
86+
},
87+
{
88+
name: 'password',
89+
label: 'password',
90+
title: 'password',
6991
component: 'text-field'
7092
}
7193
]

0 commit comments

Comments
 (0)