-
Notifications
You must be signed in to change notification settings - Fork 6
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#4320] Make it possible to let the back…
…end drive the content of the confirmation page more Added example with simulated backend data for the cosign confirmation page.
- Loading branch information
1 parent
14bbe90
commit 65681e0
Showing
4 changed files
with
87 additions
and
8 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
62 changes: 62 additions & 0 deletions
62
src/components/PostCompletionViews/ConfirmationViewCosign.stories.js
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,62 @@ | ||
import {withRouter} from 'storybook-addon-remix-react-router'; | ||
|
||
import {buildForm} from 'api-mocks'; | ||
import {AnalyticsToolsDecorator, withForm, withSubmissionPollInfo} from 'story-utils/decorators'; | ||
|
||
import {ConfirmationViewDisplay} from './ConfirmationView'; | ||
|
||
export default { | ||
title: 'Views / Cosign / Submission completed', | ||
component: ConfirmationViewDisplay, | ||
decorators: [withForm, AnalyticsToolsDecorator, withSubmissionPollInfo, withRouter], | ||
args: { | ||
publicReference: 'OF-1234', | ||
reportDownloadUrl: '/dummy', | ||
confirmationPageTitle: 'Request incomplete', | ||
confirmationPageContent: ` | ||
<p>Your request is not yet complete.</p> | ||
<h2>Cosigning required</h2> | ||
<p> | ||
We've sent an email with a cosign request to | ||
<a href="mailto:[email protected]">[email protected]</a>. Once the submission has | ||
been cosigned we will start processing your request. | ||
</p> | ||
<p> | ||
If you need to contact us about this submission, you can use the reference | ||
<strong>OF-1234</strong>. | ||
</p> | ||
`, | ||
mainWebsiteUrl: 'https://example.com', | ||
paymentUrl: '', | ||
}, | ||
argTypes: { | ||
paymentUrl: {control: false}, | ||
}, | ||
parameters: { | ||
formContext: { | ||
form: buildForm({ | ||
cosignLoginOptions: [ | ||
{ | ||
identifier: 'digid', | ||
label: 'DigiD', | ||
url: 'http://localhost:8000/auth/digid/?next=http://localhost:8000/cosign&code=123', | ||
logo: { | ||
title: 'DigiD simulatie', | ||
imageSrc: './digid.png', | ||
href: 'https://www.digid.nl/', | ||
appearance: 'dark', | ||
}, | ||
isForGemachtigde: false, | ||
}, | ||
], | ||
}), | ||
}, | ||
reactRouter: { | ||
location: {state: {}}, | ||
}, | ||
}, | ||
}; | ||
|
||
export const Default = { | ||
name: 'Submission completed', | ||
}; |
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