File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed
src/routes/sandbox/version Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change 141141 args_schema_parallel: newSchema
142142 };
143143 }
144+
145+ function loadExample () {
146+ const oldSchemaExample = {
147+ title: ' Test' ,
148+ type: ' object' ,
149+ properties: { foo: { title: ' foo' , type: ' string' } },
150+ required: [' foo' ]
151+ };
152+ const newSchemaExample = deepCopy (oldSchemaExample);
153+ newSchemaExample .properties .bar = { title: ' bar' , type: ' string' };
154+ newSchemaExample .required .push (' bar' );
155+ oldJsonSchemaString = JSON .stringify (oldSchemaExample, null , 2 );
156+ oldJsonDataString = JSON .stringify ({ foo: ' something' }, null , 2 );
157+ newJsonSchemaString = JSON .stringify (newSchemaExample, null , 2 );
158+ forceRedrawOld ();
159+ handleNewJsonSchemaStringChanged ();
160+ }
144161< / script>
145162
146163< h1 class = " fw-light" > Sandbox page for task version update< / h1>
152169 < div class = " col-lg-6 mt-3" >
153170 < div class = " row" >
154171 < div class = " col" >
172+ < button class = " btn btn-outline-primary float-end" on: click= {loadExample}>
173+ Load example
174+ < / button>
155175 < div class = " form-check form-switch" >
156176 < input
157177 class = " form-check-input"
You can’t perform that action at this time.
0 commit comments