Skip to content

Commit ecbfe5e

Browse files
Fix references to typo 'ui:option', which should be 'ui:options' (#107)
Fix references to typo 'ui:option', which should be 'ui:options' Co-authored-by: raymond-lam <[email protected]>
1 parent 00cfb22 commit ecbfe5e

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/formBuilder/types.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ export type Parameters = {
5353
definitionData: { [string]: any },
5454
definitionUi: { [string]: any },
5555
category: string,
56-
'ui:option': { [string]: any },
56+
'ui:options': { [string]: any },
5757
};
5858

5959
type DataType =

src/formBuilder/utils.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ const supportedUiParameters = new Set([
148148
'ui:widget',
149149
'ui:autofocus',
150150
'ui:autocomplete',
151-
'ui:option',
151+
'ui:options',
152152
'ui:field',
153153
'items',
154154
'definitions',
@@ -289,12 +289,12 @@ function checkObjectForUnsupportedFeatures(
289289
);
290290

291291
// check unsupported ui option
292-
if (uiProp === 'ui:option')
293-
Object.keys(uischema[parameter]['ui:option']).forEach(
292+
if (uiProp === 'ui:options')
293+
Object.keys(uischema[parameter]['ui:options']).forEach(
294294
(uiOption) => {
295295
if (!supportedOptions.has(uiOption))
296296
unsupportedFeatures.push(
297-
`UI Property: ui:option.${uiOption} for ${parameter}`,
297+
`UI Property: ui:options.${uiOption} for ${parameter}`,
298298
);
299299
},
300300
);

0 commit comments

Comments
 (0)