aboutsummaryrefslogtreecommitdiffstats
path: root/packages
diff options
context:
space:
mode:
authorBrandon Millman <brandon.millman@gmail.com>2018-06-22 04:50:58 +0800
committerfragosti <francesco.agosti93@gmail.com>2018-06-22 08:40:33 +0800
commit3df58827119b2dd70a1a41ceccd304b6055500b8 (patch)
treec9d91982cc5cda9905304d95378bbf442bc8a587 /packages
parentb6765b849cec691418bd0ccb38c584a146d97b19 (diff)
downloaddexon-0x-contracts-3df58827119b2dd70a1a41ceccd304b6055500b8.tar.gz
dexon-0x-contracts-3df58827119b2dd70a1a41ceccd304b6055500b8.tar.zst
dexon-0x-contracts-3df58827119b2dd70a1a41ceccd304b6055500b8.zip
Remove Background component
Diffstat (limited to 'packages')
-rw-r--r--packages/website/ts/components/portal/portal.tsx4
-rw-r--r--packages/website/ts/components/relayer_index/relayer_index.tsx39
-rw-r--r--packages/website/ts/components/ui/background.tsx24
-rw-r--r--packages/website/ts/components/ui/container.tsx1
-rw-r--r--packages/website/ts/style/z_index.ts1
5 files changed, 12 insertions, 57 deletions
diff --git a/packages/website/ts/components/portal/portal.tsx b/packages/website/ts/components/portal/portal.tsx
index c82bfbe6a..ec46fd4cd 100644
--- a/packages/website/ts/components/portal/portal.tsx
+++ b/packages/website/ts/components/portal/portal.tsx
@@ -22,7 +22,6 @@ import { RelayerIndex } from 'ts/components/relayer_index/relayer_index';
import { TokenBalances } from 'ts/components/token_balances';
import { TopBar, TopBarDisplayType } from 'ts/components/top_bar/top_bar';
import { TradeHistory } from 'ts/components/trade_history/trade_history';
-import { Background } from 'ts/components/ui/background';
import { Container } from 'ts/components/ui/container';
import { FlashMessage } from 'ts/components/ui/flash_message';
import { Island } from 'ts/components/ui/island';
@@ -228,7 +227,6 @@ export class Portal extends React.Component<PortalProps, PortalState> {
: TokenVisibility.TRACKED;
return (
<div>
- <Background />
<DocumentTitle title="0x Portal DApp" />
<TopBar
userAddress={this.props.userAddress}
@@ -245,7 +243,7 @@ export class Portal extends React.Component<PortalProps, PortalState> {
style={{ backgroundColor: colors.lightestGrey, position: 'fixed' }}
maxWidth={LARGE_LAYOUT_MAX_WIDTH}
/>
- <Container marginTop={TOP_BAR_HEIGHT}>
+ <Container marginTop={TOP_BAR_HEIGHT} minHeight="110vh" backgroundColor={colors.lightestGrey}>
<Switch>
<Route path={`${WebsitePaths.Portal}/:route`} render={this._renderOtherRoutes.bind(this)} />
<Route
diff --git a/packages/website/ts/components/relayer_index/relayer_index.tsx b/packages/website/ts/components/relayer_index/relayer_index.tsx
index d565eb608..5a6dc1ae9 100644
--- a/packages/website/ts/components/relayer_index/relayer_index.tsx
+++ b/packages/website/ts/components/relayer_index/relayer_index.tsx
@@ -1,4 +1,3 @@
-import { Styles } from '@0xproject/react-shared';
import * as _ from 'lodash';
import CircularProgress from 'material-ui/CircularProgress';
import { GridList } from 'material-ui/GridList';
@@ -20,22 +19,6 @@ interface RelayerIndexState {
error?: Error;
}
-const styles: Styles = {
- root: {
- width: '100%',
- },
- item: {
- backgroundColor: colors.white,
- borderBottomRightRadius: 10,
- borderBottomLeftRadius: 10,
- borderTopRightRadius: 10,
- borderTopLeftRadius: 10,
- boxShadow: `0px 4px 6px ${colors.walletBoxShadow}`,
- overflow: 'hidden',
- padding: 4,
- },
-};
-
const CELL_HEIGHT = 290;
const NUMBER_OF_COLUMNS_LARGE = 3;
const NUMBER_OF_COLUMNS_MEDIUM = 2;
@@ -76,18 +59,16 @@ export class RelayerIndex extends React.Component<RelayerIndexProps, RelayerInde
} else {
const numberOfColumns = this._numberOfColumnsForScreenWidth(this.props.screenWidth);
return (
- <div style={styles.root}>
- <GridList
- cellHeight={CELL_HEIGHT}
- cols={numberOfColumns}
- padding={GRID_PADDING}
- style={styles.gridList}
- >
- {this.state.relayerInfos.map((relayerInfo: WebsiteBackendRelayerInfo, index) => (
- <RelayerGridTile key={index} relayerInfo={relayerInfo} networkId={this.props.networkId} />
- ))}
- </GridList>
- </div>
+ <GridList
+ cellHeight={CELL_HEIGHT}
+ cols={numberOfColumns}
+ padding={GRID_PADDING}
+ style={{ marginTop: -10, marginBottom: 0 }}
+ >
+ {this.state.relayerInfos.map((relayerInfo: WebsiteBackendRelayerInfo, index) => (
+ <RelayerGridTile key={index} relayerInfo={relayerInfo} networkId={this.props.networkId} />
+ ))}
+ </GridList>
);
}
}
diff --git a/packages/website/ts/components/ui/background.tsx b/packages/website/ts/components/ui/background.tsx
deleted file mode 100644
index 808792a41..000000000
--- a/packages/website/ts/components/ui/background.tsx
+++ /dev/null
@@ -1,24 +0,0 @@
-import { colors } from '@0xproject/react-shared';
-import * as React from 'react';
-import { styled } from 'ts/style/theme';
-import { zIndex } from 'ts/style/z_index';
-
-export interface BackgroundProps {
- color?: string;
-}
-
-const PlainBackground: React.StatelessComponent<BackgroundProps> = props => <div {...props} />;
-
-export const Background = styled(PlainBackground)`
- background-color: ${props => props.color};
- height: 100vh;
- width: 100vw;
- position: fixed;
- z-index: ${zIndex.background};
-`;
-
-Background.defaultProps = {
- color: colors.lightestGrey,
-};
-
-Background.displayName = 'Background';
diff --git a/packages/website/ts/components/ui/container.tsx b/packages/website/ts/components/ui/container.tsx
index 90aec0e7c..a747ef01f 100644
--- a/packages/website/ts/components/ui/container.tsx
+++ b/packages/website/ts/components/ui/container.tsx
@@ -15,6 +15,7 @@ export interface ContainerProps {
borderRadius?: StringOrNum;
maxWidth?: StringOrNum;
width?: StringOrNum;
+ minHeight?: StringOrNum;
isHidden?: boolean;
className?: string;
position?: 'absolute' | 'fixed' | 'relative' | 'unset';
diff --git a/packages/website/ts/style/z_index.ts b/packages/website/ts/style/z_index.ts
index 6e3aebaa1..0411cdd91 100644
--- a/packages/website/ts/style/z_index.ts
+++ b/packages/website/ts/style/z_index.ts
@@ -1,5 +1,4 @@
export const zIndex = {
- background: -1,
topBar: 1100,
overlay: 1105,
aboveOverlay: 1106,