Skip to content

Commit

Permalink
Merge pull request #1322 from CAFECA-IO/fix/ui-bugs
Browse files Browse the repository at this point in the history
Fix/UI bugs
  • Loading branch information
Luphia authored Oct 11, 2023
2 parents a7f33ec + 4fe3154 commit 39a4b38
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 25 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "src",
"version": "0.8.0+55.2",
"version": "0.8.0+56.1",
"private": true,
"scripts": {
"dev": "next dev",
Expand Down
12 changes: 3 additions & 9 deletions src/components/audit_report/audit_report.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,7 @@ const AuditReport = () => {
<div className="flex h-130px w-130px sm:h-150px sm:w-150px items-center justify-center rounded-xl border-1px border-transparent bg-darkGray4 transition-all duration-150 hover:cursor-pointer hover:border-tidebitTheme xs:h-130px xs:w-130px lg:h-200px lg:w-200px">
<a
// TODO: Report updated from context (20230619 - Shirley)
href={`${BAIFA_LINK}/reports/${baifaProjectId}/${t(
'HOME_PAGE.COMPREHENSIVE_INCOME_STATEMENT_LINK'
)}`}
href={`${t('HOME_PAGE.COMPREHENSIVE_INCOME_STATEMENT_LINK')}`}
target="_blank"
className="flex flex-col items-center justify-center space-y-5"
>
Expand All @@ -70,9 +68,7 @@ const AuditReport = () => {
<div className="flex h-130px w-130px sm:h-150px sm:w-150px items-center justify-center rounded-xl border-1px border-transparent bg-darkGray4 transition-all duration-150 hover:cursor-pointer hover:border-tidebitTheme xs:h-130px xs:w-130px lg:h-200px lg:w-200px">
<a
// TODO: Report updated from context (20230619 - Shirley)
href={`${BAIFA_LINK}/reports/${baifaProjectId}/${t(
'HOME_PAGE.BALANCE_SHEET_LINK'
)}`}
href={`${t('HOME_PAGE.BALANCE_SHEET_LINK')}`}
target="_blank"
className="flex flex-col items-center justify-center space-y-5"
>
Expand All @@ -90,9 +86,7 @@ const AuditReport = () => {
<div className="flex h-130px w-130px sm:h-150px sm:w-150px items-center justify-center rounded-xl border-1px border-transparent bg-darkGray4 transition-all duration-150 hover:cursor-pointer hover:border-tidebitTheme xs:h-130px xs:w-130px lg:h-200px lg:w-200px">
<a
// TODO: Report updated from context (20230619 - Shirley)
href={`${BAIFA_LINK}/reports/${baifaProjectId}/${t(
'HOME_PAGE.CASH_FLOW_STATEMENT_LINK'
)}`}
href={`${t('HOME_PAGE.CASH_FLOW_STATEMENT_LINK')}`}
target="_blank"
className="flex flex-col items-center justify-center space-y-5"
>
Expand Down
14 changes: 8 additions & 6 deletions src/components/reserve_ratio/reserve_ratio.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,15 @@ import {FiDownload} from 'react-icons/fi';
import {useGlobal} from '../../contexts/global_context';
import {ToastTypeAndText} from '../../constants/toast_type';
import {numberFormatted} from '../../lib/common';
import useCheckLink from '../../lib/hooks/use_check_link';

const ReserveRatio = () => {
const {t}: {t: TranslateFunction} = useTranslation('common');

const {websiteReserve} = useContext(MarketContext);
const {BTC, ETH, USDT} = websiteReserve;

const baifaLink = useCheckLink(BAIFA_LINK, BAIFA_LINK);
const baifaProjectId = process.env.BAIFA_PROJECT_ID;

// TODO: 用 isNumber 檢驗,資料傳給卡片之前都整理成 string (20230914 - Shirley)
Expand Down Expand Up @@ -81,7 +83,7 @@ const ReserveRatio = () => {
color="text-lightGreen2"
ratio={usdtReserveRatio}
icon="/asset_icon/usdt.svg"
link="/"
link={`${baifaLink}/reports/${baifaProjectId}/plugin`}
userHoldings={usdtUserHolding}
walletAssets={usdtReserve}
/>
Expand All @@ -90,7 +92,7 @@ const ReserveRatio = () => {
color="text-bluePurple"
ratio={ethReserveRatio}
icon="/asset_icon/eth.svg"
link="/"
link={`${baifaLink}/reports/${baifaProjectId}/plugin`}
userHoldings={ethUserHolding}
walletAssets={ethReserve}
/>
Expand All @@ -99,7 +101,7 @@ const ReserveRatio = () => {
color="text-lightOrange"
ratio={btcReserveRatio}
icon="/asset_icon/btc.svg"
link="/"
link={`${baifaLink}/reports/${baifaProjectId}/plugin`}
userHoldings={btcUserHolding}
walletAssets={btcReserve}
/>
Expand All @@ -114,7 +116,7 @@ const ReserveRatio = () => {
color="text-lightGreen2"
ratio={usdtReserveRatio}
icon="/asset_icon/usdt.svg"
link="/"
link={`${baifaLink}/reports/${baifaProjectId}/plugin`}
userHoldings={usdtUserHolding}
walletAssets={usdtReserve}
/>
Expand All @@ -123,7 +125,7 @@ const ReserveRatio = () => {
color="text-bluePurple"
ratio={ethReserveRatio}
icon="/asset_icon/eth.svg"
link="/"
link={`${baifaLink}/reports/${baifaProjectId}/plugin`}
userHoldings={ethUserHolding}
walletAssets={ethReserve}
/>
Expand All @@ -132,7 +134,7 @@ const ReserveRatio = () => {
color="text-lightOrange"
ratio={btcReserveRatio}
icon="/asset_icon/btc.svg"
link="/"
link={`${baifaLink}/reports/${baifaProjectId}/plugin`}
userHoldings={btcUserHolding}
walletAssets={btcReserve}
/>
Expand Down
6 changes: 3 additions & 3 deletions src/locales/cn/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,9 @@
"APP_DOWLOAD_CONTAINER_TITLE_2": "进行交易。",
"DOWNLOAD_REPORT": "下载报告",
"REPORTS_LINK": "/balance",
"COMPREHENSIVE_INCOME_STATEMENT_LINK": "/comprehensive-income",
"BALANCE_SHEET_LINK": "/balance",
"CASH_FLOW_STATEMENT_LINK": "/cash-flow",
"COMPREHENSIVE_INCOME_STATEMENT_LINK": "https://baifa.io/reports/TBDJH4gK8Lp0Z/comprehensive-income",
"BALANCE_SHEET_LINK": "https://baifa.io/reports/TBDJH4gK8Lp0Z/balance",
"CASH_FLOW_STATEMENT_LINK": "https://baifa.io/reports/TBDJH4gK8Lp0Z/cash-flow",
"RED_FLAG_ANALYSIS_LINK": "/reports/red_flag_analysis.pdf",
"SMART": "人工智能",
"AUDITING_REPORTS": "监管报告",
Expand Down
6 changes: 3 additions & 3 deletions src/locales/en/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,9 @@
"APP_DOWLOAD_CONTAINER_TITLE_2": "anywhere, anytime",
"DOWNLOAD_REPORT": "Download Report",
"REPORTS_LINK": "/balance",
"COMPREHENSIVE_INCOME_STATEMENT_LINK": "/comprehensive-income",
"BALANCE_SHEET_LINK": "/balance",
"CASH_FLOW_STATEMENT_LINK": "/cash-flow",
"COMPREHENSIVE_INCOME_STATEMENT_LINK": "https://baifa.io/reports/TBDJH4gK8Lp0Z/comprehensive-income",
"BALANCE_SHEET_LINK": "https://baifa.io/reports/TBDJH4gK8Lp0Z/balance",
"CASH_FLOW_STATEMENT_LINK": "https://baifa.io/reports/TBDJH4gK8Lp0Z/cash-flow",
"RED_FLAG_ANALYSIS_LINK": "/reports/red_flag_analysis.pdf",
"SMART": "AI",
"AUDITING_REPORTS": "Supervision Reports",
Expand Down
6 changes: 3 additions & 3 deletions src/locales/tw/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,9 @@
"APP_DOWLOAD_CONTAINER_TITLE_2": "進行交易。",
"DOWNLOAD_REPORT": "下載報告",
"REPORTS_LINK": "/balance",
"COMPREHENSIVE_INCOME_STATEMENT_LINK": "/comprehensive-income",
"BALANCE_SHEET_LINK": "/balance",
"CASH_FLOW_STATEMENT_LINK": "/cash-flow",
"COMPREHENSIVE_INCOME_STATEMENT_LINK": "https://baifa.io/reports/TBDJH4gK8Lp0Z/comprehensive-income",
"BALANCE_SHEET_LINK": "https://baifa.io/reports/TBDJH4gK8Lp0Z/balance",
"CASH_FLOW_STATEMENT_LINK": "https://baifa.io/reports/TBDJH4gK8Lp0Z/cash-flow",
"RED_FLAG_ANALYSIS_LINK": "/reports/red_flag_analysis.pdf",
"SMART": "人工智慧",
"AUDITING_REPORTS": "監管報告",
Expand Down

0 comments on commit 39a4b38

Please sign in to comment.