We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 63ce98e commit 0ef80b5Copy full SHA for 0ef80b5
src/ui.js
@@ -47,7 +47,7 @@ function FormField(props) {
47
if (props.schema.handler)
48
inputProps.handler = props.schema.handler;
49
50
- let type = props.schema.type;
+ let type = normalizeKeyword(props.schema.type);
51
let choices = getKeyword(props.schema, 'choices', 'enum');
52
53
if (choices) {
src/util.js
@@ -157,6 +157,9 @@ export function debounce(func, wait) {
157
export function normalizeKeyword(kw) {
158
/* Converts custom supported keywords to standard JSON schema keywords */
159
160
+ if (Array.isArray(kw))
161
+ kw = kw[0];
162
+
163
switch (kw) {
164
case 'list': return 'array';
165
case 'dict': return 'object';
0 commit comments