Skip to content

Commit

Permalink
error form story
Browse files Browse the repository at this point in the history
  • Loading branch information
sgendre committed Oct 11, 2023
1 parent e219468 commit 4592ee9
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
4 changes: 3 additions & 1 deletion packages/forms/stories/SchemaState.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,9 @@ const errorsProps = errorsSchema.uiSchema.reduce(
...acc,
[current.key.split('.').join(',')]: 'There is an error',
}),
{},
{
tabConfiguration: 'There is an error',
},
);

export const Errors: Story = {
Expand Down
12 changes: 10 additions & 2 deletions packages/forms/stories/UIFormStoriesSchemas/errors.schema.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,14 @@ export const errorsSchema = {
title: 'Comment',
required: ['fieldname'],
properties: {
tabConfiguration: {
type: 'object',
properties: {
fieldname: {
type: 'string',
},
},
},
fieldname: {
type: 'string',
},
Expand Down Expand Up @@ -100,7 +108,7 @@ export const errorsSchema = {
widget: 'tabs',
items: [
{
key: 'tab-settings-tab-main',
key: 'tabConfiguration',
title: 'Configuration',
widget: 'fieldset',
items: [
Expand All @@ -111,7 +119,7 @@ export const errorsSchema = {
],
},
{
key: 'tab-info',
key: 'tabInfo',
title: 'Info',
widget: 'fieldset',
items: [
Expand Down

0 comments on commit 4592ee9

Please sign in to comment.