2021-12-07 00:08:13 +01:00
|
|
|
import { createBrowserHistory } from 'history';
|
2021-08-31 01:02:23 +02:00
|
|
|
import React from 'react';
|
2021-12-07 00:08:13 +01:00
|
|
|
import README from './README.mdx';
|
2021-08-31 01:02:23 +02:00
|
|
|
import UnlockPage from './unlock-page.component';
|
|
|
|
|
|
|
|
export default {
|
2021-12-01 20:27:57 +01:00
|
|
|
title: 'Pages/UnlockPage',
|
2021-09-15 20:55:48 +02:00
|
|
|
id: __filename,
|
2021-12-07 00:08:13 +01:00
|
|
|
component: UnlockPage,
|
|
|
|
parameters: {
|
|
|
|
docs: {
|
|
|
|
page: README,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
argTypes: {
|
|
|
|
history: { control: 'object' },
|
|
|
|
isUnlocked: { control: 'boolean' },
|
|
|
|
onRestore: { action: 'onRestore' },
|
|
|
|
onSubmit: { action: 'onSubmit' },
|
|
|
|
forceUpdateMetamaskState: { action: 'forceUpdateMetamaskState' },
|
|
|
|
showOptInModal: { action: 'showOptInModal' },
|
|
|
|
},
|
2021-08-31 01:02:23 +02:00
|
|
|
};
|
|
|
|
|
2021-12-07 00:08:13 +01:00
|
|
|
export const DefaultStory = (args) => {
|
|
|
|
const history = createBrowserHistory();
|
|
|
|
return <UnlockPage {...args} history={history} />;
|
|
|
|
};
|
|
|
|
|
|
|
|
DefaultStory.storyName = 'Default';
|
|
|
|
|
|
|
|
DefaultStory.args = {
|
|
|
|
forceUpdateMetamaskState: () => ({
|
|
|
|
participateInMetaMetrics: true,
|
|
|
|
}),
|
2021-08-31 01:02:23 +02:00
|
|
|
};
|
2021-12-01 20:27:57 +01:00
|
|
|
|
|
|
|
DefaultStory.storyName = 'Default';
|