-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🚚 [open-formulieren/open-forms#4546] Move RichText component to 'base…
… building blocks' While it initially was only relevant for the content component, we will make use of this same component in the display component for the soft required validation errors. The component translations wrapper around it remains component-type specific since we can leverage the type-safety when checking validation error keys, at the cost of a little bit of code duplication.
- Loading branch information
1 parent
bd1afb0
commit acc635e
Showing
6 changed files
with
48 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
import {Meta, StoryObj} from '@storybook/react'; | ||
|
||
import {withFormik} from '@/sb-decorators'; | ||
|
||
import RichText from './rich-text'; | ||
|
||
export default { | ||
title: 'Formio/Builder/RichText', | ||
component: RichText, | ||
decorators: [withFormik], | ||
args: { | ||
name: 'richText', | ||
required: false, | ||
supportsBackendTemplating: false, | ||
}, | ||
parameters: { | ||
controls: {hideNoControlsWarning: true}, | ||
modal: {noModal: true}, | ||
formik: {initialValues: {richText: ''}}, | ||
}, | ||
} satisfies Meta<typeof RichText>; | ||
|
||
type Story = StoryObj<typeof RichText>; | ||
|
||
export const Default: Story = {}; | ||
|
||
export const WithBackendTemplatingSupport: Story = { | ||
args: { | ||
supportsBackendTemplating: true, | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters