1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00

Storybook housekeeping 🧹 (#14331)

* Removing argTypes that are related to static props and don't have anything to do with the component. Also some general house keeping

* updates
This commit is contained in:
George Marshall 2022-04-07 08:14:22 -07:00 committed by GitHub
parent e0e466490e
commit 9ce966ba1d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 7 additions and 70 deletions

View File

@ -5,27 +5,6 @@ export default {
title: 'Components/App/AppHeader',
id: __filename,
argTypes: {
history: {
control: 'object',
},
networkDropdownOpen: {
control: 'boolean',
},
showNetworkDropdown: {
action: 'showNetworkDropdown',
},
hideNetworkDropdown: {
action: 'hideNetworkDropdown',
},
toggleAccountMenu: {
action: 'toggleAccountMenu',
},
selectedAddress: {
control: 'text',
},
isUnlocked: {
control: 'boolean',
},
hideNetworkIndicator: {
control: 'boolean',
},
@ -35,9 +14,6 @@ export default {
disableNetworkIndicator: {
control: 'boolean',
},
isAccountMenuOpen: {
control: 'boolean',
},
onClick: {
action: 'onClick',
},

View File

@ -6,30 +6,14 @@ export default {
id: __filename,
component: ConfirmRemoveAccount,
argTypes: {
hideModal: {
action: 'hideModal',
},
removeAccount: {
action: 'removeAccount',
},
identity: {
control: 'object',
},
chainId: {
control: 'text',
},
rpcPrefs: {
control: 'object',
},
},
args: {
identity: {
control: 'object',
},
chainId: 'chainId',
rpcPrefs: {
control: 'object',
},
},
};

View File

@ -4,34 +4,8 @@ import ExportPrivateKeyModal from '.';
export default {
title: 'Components/App/Modals/ExportPrivateKeyModal',
id: __filename,
argTypes: {
exportAccount: {
action: 'exportAccount',
},
selectedIdentity: {
control: 'object',
},
warning: {
control: 'node',
},
showAccountDetailModal: {
action: 'showAccountDetailModal',
},
hideModal: {
action: 'hideModal',
},
hideWarning: {
action: 'hideWarning',
},
clearAccountDetails: {
action: 'clearAccountDetails',
},
previousModalState: {
control: 'text',
},
},
};
export const DefaultStory = (args) => <ExportPrivateKeyModal {...args} />;
export const DefaultStory = () => <ExportPrivateKeyModal />;
DefaultStory.storyName = 'Default';

View File

@ -47,6 +47,9 @@ export default {
fiatNumberOfDecimals: {
control: 'number',
},
showFiat: {
control: 'boolean',
},
},
args: {
type: ETH,

View File

@ -2,7 +2,7 @@ import React from 'react';
import RevealSeedPhrase from '.';
export default {
title: 'Components/Pages/FirstTimeFlow/RevealSeedPhrase',
title: 'Pages/FirstTimeFlow/RevealSeedPhrase',
id: __filename,
};

View File

@ -2,7 +2,7 @@ import React from 'react';
import PermissionsRedirect from '.';
export default {
title: 'Components/Pages/PermissionsConnect/Redirect/PermissionsRedirect',
title: 'Pages/PermissionsConnect/Redirect/PermissionsRedirect',
id: __filename,
argTypes: {
subjectMetadata: {

View File

@ -2,7 +2,7 @@ import React from 'react';
import SmartTransactionStatus from './smart-transaction-status';
export default {
title: 'SmartTransactionStatus',
title: 'Pages/Swaps/SmartTransactionStatus',
};
export const SmartTransactionStatusComponent = () => {