From 66850c8e9b909c8339903f14196f45884a67f4cd Mon Sep 17 00:00:00 2001 From: Sigve Kvalsvik Date: Fri, 29 Sep 2017 12:09:11 +0200 Subject: [PATCH 01/82] Implement table view and Portfolio content --- app/assets/locales/locale-en.json | 6 +- .../stylesheets/components/_account.scss | 72 ++++ app/components/Account/AccountLeftPanel.jsx | 2 +- app/components/Account/AccountOverview.jsx | 314 +++++++++++------- app/components/Icon/Icon.jsx | 3 +- app/components/Icon/deposit.svg | 5 + app/components/Icon/dollar.svg | 5 + app/components/Icon/settle.svg | 7 + app/components/Icon/trade.svg | 5 + app/components/Icon/transfer.svg | 8 + app/components/Icon/withdraw.svg | 5 + app/components/Utility/AssetName.jsx | 2 +- app/components/Utility/BalanceComponent.jsx | 20 +- .../Utility/EquivalentValueComponent.jsx | 7 +- app/components/Utility/Tabs.jsx | 27 +- app/components/Utility/TotalBalanceValue.jsx | 8 +- 16 files changed, 355 insertions(+), 141 deletions(-) create mode 100644 app/components/Icon/deposit.svg create mode 100644 app/components/Icon/dollar.svg create mode 100644 app/components/Icon/settle.svg create mode 100644 app/components/Icon/trade.svg create mode 100644 app/components/Icon/transfer.svg create mode 100644 app/components/Icon/withdraw.svg diff --git a/app/assets/locales/locale-en.json b/app/assets/locales/locale-en.json index 0e1c2a9a43..d19ebf2597 100644 --- a/app/assets/locales/locale-en.json +++ b/app/assets/locales/locale-en.json @@ -364,7 +364,11 @@ "propose_from": "Propose From", "settle": "Settle", "no_orders": "No open orders", - "asset_details": "Asset details" + "asset_details": "Asset details", + "portfolio": "Portfolio", + "activity": "Activity", + "eq_value_header": "Value (%(asset)s)", + "qty": "Qty" }, "pagination": { "newer": "Newer", diff --git a/app/assets/stylesheets/components/_account.scss b/app/assets/stylesheets/components/_account.scss index cfda717b25..b5818297c3 100755 --- a/app/assets/stylesheets/components/_account.scss +++ b/app/assets/stylesheets/components/_account.scss @@ -107,3 +107,75 @@ a.action-button > span { text-transform: lowercase; } + +ul.account-overview { + li { + > a { + font-size: 1rem; + color: grey; + background-color: #1A242F; + &:hover { + background-color: #1A242F; + color: white; + } + > span.tab-title { + } + + > span.tab-subtext { + font-size: 85%; + color: #7ED321; + } + } + &.is-active > a { + color: white; + background-color: #1A242F; + > span.tab-title { + } + } + &.total-value { + > a { + cursor: default; + background-color: #27384B; + > span.tab-title { + font-size: 95%; + } + &:hover > span.tab-title { + color: grey; + } + } + } + } +} + +table.table.dashboard-table { + > thead > tr > th { + background-color: #1A242F; + color: white; + font-weight: 600; + text-align: center; + } + > tbody > tr { + > td { + font-size: 0.9rem; + background-color: #27384B; + color: white; + border: 1px solid #323131; + text-align: center; + } + &.total-value { + td { + padding: 8px 5px; + background-color: #1A242F; + } + td:first-of-type { + text-align: left; + text-transform: uppercase; + font-weight: 600; + } + td:nth-child(3) { + color: #7ED321; + font-weight: 600; + } + } + } +} diff --git a/app/components/Account/AccountLeftPanel.jsx b/app/components/Account/AccountLeftPanel.jsx index c29aaf7c8a..f570904f17 100644 --- a/app/components/Account/AccountLeftPanel.jsx +++ b/app/components/Account/AccountLeftPanel.jsx @@ -91,7 +91,7 @@ class AccountLeftPanel extends React.Component {