mirror of
https://github.com/trezor/trezor-wallet
synced 2025-02-11 15:42:42 +00:00
allow styles override in Content component
This commit is contained in:
parent
19cdb097f9
commit
7d7d6e44bf
@ -18,6 +18,7 @@ import FirmwareUnsupported from './components/FirmwareUnsupported';
|
||||
import l10nMessages from './index.messages';
|
||||
|
||||
type Props = {
|
||||
className?: string,
|
||||
children?: React.Node,
|
||||
isLoading?: boolean,
|
||||
loader?: $ElementType<$ElementType<State, 'selectedAccount'>, 'loader'>,
|
||||
@ -76,8 +77,8 @@ const getExceptionPage = exceptionPage => {
|
||||
}
|
||||
};
|
||||
|
||||
const Content = ({ children, isLoading = false, loader, exceptionPage }: Props) => (
|
||||
<Wrapper>
|
||||
const Content = ({ className, children, isLoading = false, loader, exceptionPage }: Props) => (
|
||||
<Wrapper className={className}>
|
||||
{!isLoading && children}
|
||||
{isLoading && exceptionPage && getExceptionPage(exceptionPage)}
|
||||
{isLoading && loader && (
|
||||
@ -98,6 +99,7 @@ const Content = ({ children, isLoading = false, loader, exceptionPage }: Props)
|
||||
|
||||
Content.propTypes = {
|
||||
children: PropTypes.oneOfType([PropTypes.element, PropTypes.array]),
|
||||
className: PropTypes.string,
|
||||
isLoading: PropTypes.bool,
|
||||
loader: PropTypes.object,
|
||||
exceptionPage: PropTypes.object,
|
||||
|
Loading…
Reference in New Issue
Block a user