Skip to content

Commit

Permalink
Merge branch 'develop' into feature/news-0922
Browse files Browse the repository at this point in the history
  • Loading branch information
Luphia authored Sep 23, 2023
2 parents df23859 + b0c562f commit 96196fc
Show file tree
Hide file tree
Showing 35 changed files with 509 additions and 272 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+49.3",
"version": "0.8.0+49.5",
"private": true,
"scripts": {
"dev": "next dev",
Expand Down
Binary file added public/elements/isunone_banner_bg_mobile.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
128 changes: 128 additions & 0 deletions public/elements/isunone_banner_bg_mobile.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
31 changes: 15 additions & 16 deletions src/components/app_download_container/app_download_container.tsx
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
import Image from 'next/image';
import React from 'react';
import {useTranslation} from 'next-i18next';
import Link from 'next/link';

type TranslateFunction = (s: string) => string;

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

// const containerDescription = `container mx-auto flex items-center md:flex-row flex-col`;
const desktopVersionBreakpoint = 'hidden lg:flex';
const mobileVersionBreakpoint = 'flex lg:hidden';

return (
<>
{/* Desktop */}
{/* Info: Desktop (20230922 - Shirley) */}
<div className={`${desktopVersionBreakpoint}`}>
<section className={`bg-black py-24`}>
<h1 className="flex shrink-0 items-center justify-center py-20 px-2 text-lg font-bold text-white sm:text-2xl md:px-20 md:text-3xl lg:text-4xl xl:text-6xl">
<section className={`bg-black`}>
<h1 className="flex shrink-0 items-center justify-center pb-20 px-2 text-lg font-bold text-white sm:text-2xl md:px-20 md:text-3xl lg:text-4xl xl:text-6xl">
{t('HOME_PAGE.APP_DOWLOAD_CONTAINER_TITLE')}&nbsp;
<span className="text-cyan-400">
{t('HOME_PAGE.APP_DOWLOAD_CONTAINER_TITLE_HIGHLIGHT')}
Expand All @@ -25,7 +25,7 @@ const AppDowloadContainer = () => {
{t('HOME_PAGE.APP_DOWLOAD_CONTAINER_TITLE_2')}
</h1>

<div className="mx-auto flex flex-wrap items-center space-y-2 pb-24 md:flex-row">
<div className="mx-auto flex flex-wrap items-center space-y-2 md:flex-row">
<div className="mx-auto mb-10 max-w-md md:mb-0 md:w-1/2 lg:max-w-sm 2xl:ml-1/8">
<div className="flex justify-center">
<Image
Expand All @@ -38,23 +38,23 @@ const AppDowloadContainer = () => {
</div>

<div className="mx-auto mt-10 flex shrink-0 flex-wrap items-center justify-center sm:space-x-4 md:ml-auto md:mr-0">
<button type="button" className="hover:opacity-80">
<Link target="_blank" href="/coming-soon" className="hover:opacity-80">
<Image
src="/elements/[email protected]"
width={120}
height={40}
alt="app-store"
/>
</button>
</Link>

<button type="button" className="hover:opacity-80">
<Link target="_blank" href="/coming-soon" className="hover:opacity-80">
<Image
src={'/elements/[email protected]'}
width={155}
height={40}
alt="google play"
/>
</button>
</Link>
</div>
</div>
<div className="mx-auto flex w-full flex-col flex-wrap items-center justify-center pt-20 pl-1/10 md:w-3/5 lg:pl-0 lg:pt-0">
Expand All @@ -70,7 +70,7 @@ const AppDowloadContainer = () => {
</section>
</div>

{/* Mobile */}
{/* Info: Mobile (20230922 - Shirley) */}
<div className={`${mobileVersionBreakpoint}`}>
<section className={`bg-black`}>
<div className="flex shrink-0 flex-col items-center justify-center space-y-2 px-2 pt-0 pb-10 text-2xl font-bold text-white sm:space-y-5 sm:text-3xl md:px-20 md:pb-20 md:text-4xl">
Expand All @@ -83,7 +83,7 @@ const AppDowloadContainer = () => {
<div>{t('HOME_PAGE.APP_DOWLOAD_CONTAINER_TITLE_2')}</div>
</div>

<div className="mx-auto flex flex-wrap items-center space-y-2 pb-24 md:flex-row">
<div className="mx-auto flex flex-wrap items-center space-y-2 md:flex-row">
<div className="mx-auto flex w-4/5 flex-col flex-wrap items-center justify-center py-5 pl-1/10 md:w-4/5">
<Image
className="flex justify-center rounded object-contain"
Expand All @@ -95,7 +95,6 @@ const AppDowloadContainer = () => {
</div>

<div className="mx-auto mb-10 max-w-md md:mb-0 md:w-1/2 lg:max-w-sm 2xl:ml-1/8">
{/* QR Code Size Automatic Toggle */}
<div className="hidden justify-center md:flex">
<Image
className="rounded object-cover object-center"
Expand All @@ -117,23 +116,23 @@ const AppDowloadContainer = () => {
</div>

<div className="mx-auto mt-5 flex shrink-0 flex-wrap items-center justify-center space-x-3 sm:mt-10 sm:space-x-4 md:ml-auto md:mr-0">
<button type="button" className="hover:opacity-80">
<Link target="_blank" href="/coming-soon" className="hover:opacity-80">
<Image
src="/elements/[email protected]"
width={134}
height={40}
alt="app-store"
/>
</button>
</Link>

<button type="button" className="hover:opacity-80">
<Link target="_blank" href="/coming-soon" className="hover:opacity-80">
<Image
src={'/elements/[email protected]'}
width={135}
height={40}
alt="google play"
/>
</button>
</Link>
</div>
</div>
</div>
Expand Down
54 changes: 32 additions & 22 deletions src/components/audit_report/audit_report.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,24 +3,32 @@ import Link from 'next/link';
import {BiLinkAlt} from 'react-icons/bi';
import {TranslateFunction} from '../../interfaces/tidebit_defi_background/locale';
import {useTranslation} from 'next-i18next';
import {BAIFA_LINK} from '../../constants/config';
import {useEffect, useState} from 'react';
import useStateRef from 'react-usestateref';
import useCheckLink from '../../lib/hooks/use_check_link';

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

const {i18n} = useTranslation('common');

const baifaLink = useCheckLink(BAIFA_LINK, BAIFA_LINK);

return (
<section>
<div className="mb-5 items-center text-2xl font-medium text-white lg:mb-10 lg:text-3xl xl:text-4xl">
<div className="mb-5 items-center font-medium text-white lg:mb-10 text-2xl xs:text-3xl sm:text-4xl">
<div className="flex items-center justify-center">
<span className="my-auto h-px w-1/11 rounded bg-white/50 xs:inline-block xs:w-1/10 lg:w-3/10 xl:mx-2"></span>
<h1 className="mx-5 text-center">
<h1 className="mx-3 text-center">
<span className="text-tidebitTheme">{t('HOME_PAGE.SMART')} </span>{' '}
{t('HOME_PAGE.AUDITING_REPORTS')}
</h1>
<span className="my-auto h-px w-1/11 rounded bg-white/50 xs:inline-block xs:w-1/10 lg:w-3/10 xl:mx-2"></span>
</div>
</div>

<div className="mx-20">
<div className="lg:mx-20">
<div className="mb-5 flex w-full justify-center text-lightGray lg:mb-10">
{t('HOME_PAGE.LAST_UPDATED')}{' '}
<span className="text-lightWhite">&nbsp;August 04, 2023</span>
Expand All @@ -32,8 +40,8 @@ const AuditReport = () => {

<div className="flex w-full justify-around">
<div className="mx-0 grid grid-cols-2 items-center justify-center gap-x-5 gap-y-5 lg:mx-0 lg:flex lg:w-full lg:flex-row lg:items-center lg:justify-center lg:space-x-12 lg:space-y-0">
<div className="flex h-100px w-100px 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">
<Link
<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={t('HOME_PAGE.COMPREHENSIVE_INCOME_STATEMENT_LINK')}
download
Expand All @@ -47,14 +55,14 @@ const AuditReport = () => {
height={80}
alt="Income Statement"
/>
<p className=" text-center text-xs lg:text-lg">
<p className=" text-center text-xs sm:text-base lg:text-lg">
{t('HOME_PAGE.COMPREHENSIVE_INCOME_STATEMENT')}
</p>
</Link>
</a>
</div>

<div className="flex h-100px w-100px 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">
<Link
<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={t('HOME_PAGE.BALANCE_SHEET_LINK')}
download
Expand All @@ -68,12 +76,12 @@ const AuditReport = () => {
height={80}
alt="Balance Sheet"
/>
<p className="text-xs lg:text-lg">{t('HOME_PAGE.BALANCE_SHEET')}</p>
</Link>
<p className="text-xs sm:text-base lg:text-lg">{t('HOME_PAGE.BALANCE_SHEET')}</p>
</a>
</div>

<div className="flex h-100px w-100px 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">
<Link
<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={t('HOME_PAGE.CASH_FLOW_STATEMENT_LINK')}
download
Expand All @@ -88,15 +96,15 @@ const AuditReport = () => {
alt="Cash Flow Statement"
/>
<div className="flex flex-col items-center justify-center w-full">
<p className="text-xxs xs:text-xs lg:text-lg text-center">
<p className="text-xs xs:text-xs sm:text-base lg:text-lg text-center">
{t('HOME_PAGE.CASH_FLOW_STATEMENT')}
</p>
</div>
</Link>
</a>
</div>

<div className="flex h-100px w-100px 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">
<Link
<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={t('HOME_PAGE.RED_FLAG_ANALYSIS_LINK')}
download
Expand All @@ -110,18 +118,20 @@ const AuditReport = () => {
height={80}
alt="Red Flag Analysis"
/>
<p className="text-xs lg:text-lg">{t('HOME_PAGE.RED_FLAG_ANALYSIS')}</p>
</Link>
<p className="text-xs sm:text-base lg:text-lg">
{t('HOME_PAGE.RED_FLAG_ANALYSIS')}
</p>
</a>
</div>
</div>
</div>

<div className="flex w-full justify-center space-x-3 pt-10">
<div className="flex w-full justify-center space-x-3 pt-10 lg:flex-row flex-col items-center lg:space-y-0 space-y-2">
<p className=""> {t('HOME_PAGE.POWERED_BY')}</p>
<a
href={`https://baifa.io`}
href={baifaLink}
target="_blank"
className={`flex w-100px items-center justify-center space-x-2 whitespace-nowrap rounded-full bg-lightGray3 px-3 py-1 text-sm font-bold text-lightWhite transition-colors duration-300 hover:bg-lightGray1 hover:text-black`}
className={`flex w-105px items-center justify-center space-x-2 whitespace-nowrap rounded-full bg-lightGray3 px-3 py-1 text-sm font-bold text-lightWhite transition-colors duration-300 hover:bg-lightGray1 hover:text-black`}
>
<p className="">BAIFA</p>

Expand Down
69 changes: 66 additions & 3 deletions src/components/banner/banner.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,23 +3,27 @@ import React from 'react';
import {useTranslation} from 'next-i18next';
import {useGlobal} from '../../contexts/global_context';
import {LayoutAssertion} from '../../constants/layout_assertion';
import useCheckLink from '../../lib/hooks/use_check_link';
import {I_SUN_ONE_LINK} from '../../constants/config';

type TranslateFunction = (s: string) => string;

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

const {layoutAssertion} = useGlobal();
const iSunOneIconSize = layoutAssertion === LayoutAssertion.MOBILE ? 35 : 50;
const shrink = 0.7;

const iSunOneLink = useCheckLink(I_SUN_ONE_LINK, I_SUN_ONE_LINK);

return (
<>
<div className="">
<section className="w-full">
<div
className="w-screen flex flex-col items-start pt-5 xl:pt-20 lg:pt-10 pl-1/4 md:pl-2/5 xl:pl-1/2 bg-center bg-no-repeat bg-cover"
className="hidden w-screen lg:flex flex-col items-start pt-5 xl:pt-20 lg:pt-10 pl-1/4 md:pl-2/5 xl:pl-1/2 bg-iSunOneBg bg-center bg-no-repeat bg-cover"
style={{
backgroundImage: 'url(/elements/[email protected])',
height: `${layoutAssertion === LayoutAssertion.MOBILE ? '200px' : '356px'}`,
}}
>
Expand All @@ -33,7 +37,7 @@ const Banner = () => {
<div className="pt-5 lg:pt-12 group">
<a
className="flex text-center items-center tracking-wider"
href="https://www.isun1.com/"
href={iSunOneLink}
target="_blank"
>
<Image
Expand Down Expand Up @@ -76,6 +80,65 @@ const Banner = () => {
</a>
</div>
</div>

<div className="relative h-120vh md:h-200vh w-screen flex items-center justify-center lg:hidden bg-center bg-no-repeat bg-iSunOneBgMobile bg-contain">
<div className="flex flex-col mb-250px xs:mb-2/3 sm:mb-2/3 items-center w-full z-20">
<p className="text-white text-2xl xs:text-3xl sm:text-4xl font-bold tracking-normal">
{t('HOME_PAGE.ISUNONE_PROMOTION_TITLE_1')}{' '}
<span className="text-lightGreen6">USDT</span>
<span className="mx-2">&</span>
<span className="text-lightBlue mr-2">USDC</span>
{t('HOME_PAGE.ISUNONE_PROMOTION_TITLE_2')}
</p>
<div className="pt-5 sm:pt-12 group">
<a
className="flex text-center items-center tracking-wider"
href={iSunOneLink}
target="_blank"
>
<Image
src={`/elements/isunone_logo.svg`}
width={iSunOneIconSize}
height={iSunOneIconSize}
alt="isunone logo"
/>
<p className="ml-3 mr-2 text-white text-base xs:text-2xl sm:text-3xl font-bold group-hover:text-lightYellow3 transition-all duration-300">
{t('HOME_PAGE.ISUNONE_PROMOTION_DESCRIPTION')}
</p>
<div className="">
<div className="">
<svg
xmlns="http://www.w3.org/2000/svg"
width={iSunOneIconSize * shrink}
height={iSunOneIconSize * shrink}
fill="none"
viewBox="0 0 30 31"
className="transition-transform duration-300 group-hover:translate-x-2"
>
<g clipPath="url(#clip0_9_1330)">
<g>
<path
className="fill-current text-white group-hover:text-yellow-400 transition-colors duration-300"
d="M25.896 16.357a1.875 1.875 0 000-2.65l-7.07-7.074a1.875 1.875 0 10-2.652 2.652l3.87 3.872H5.625a1.875 1.875 0 100 3.75h14.419l-3.87 3.87a1.875 1.875 0 002.652 2.652l7.07-7.072z"
></path>
</g>
</g>
<defs>
<clipPath id="clip0_9_1330">
<path
fill="#fff"
d="M0 0H30V30H0z"
transform="rotate(90 14.984 15.016)"
></path>
</clipPath>
</defs>
</svg>
</div>
</div>
</a>
</div>
</div>
</div>
</section>
</div>
</>
Expand Down
4 changes: 2 additions & 2 deletions src/components/crypto_category/crypto_category.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ const CryptoCategory = ({...otherProps}) => {
return (
<div className="container mx-auto flex shrink-0 flex-wrap justify-center space-y-1">
<div className="mb-10 flex w-full flex-col text-center xl:mb-20">
<div className="mb-0 items-center text-2xl font-medium text-white xs:text-3xl sm:text-4xl">
<div className="mb-0 items-center font-medium text-white text-2xl xs:text-3xl sm:text-4xl">
<div className="flex items-center justify-center">
<span className="my-auto h-px w-1/11 rounded bg-white/50 xs:inline-block xs:w-1/10 lg:w-3/10 xl:mx-2"></span>
<h1 className="mx-1 text-center xl:w-410px">
Expand All @@ -82,7 +82,7 @@ const CryptoCategory = ({...otherProps}) => {
</div>
</div>
<div className="flex w-full items-center justify-center">
<div className="mb-5 grid grid-cols-2 space-y-4 space-x-4 lg:grid-cols-5">
<div className="grid grid-cols-2 space-y-4 space-x-4 lg:grid-cols-5">
{renderCryptoCard}
</div>
</div>
Expand Down
4 changes: 2 additions & 2 deletions src/components/cta/cta.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,10 @@ const Cta = () => {
</span>{' '}
{t('HOME_PAGE.CTA_REST_TITLE')}
</div>
<div className="mx-5 mt-4 max-w-md text-sm font-normal leading-7 tracking-0.02rem text-white md:text-xl">
<div className="mx-5 mt-4 w-278px text-sm font-normal leading-7 tracking-0.02rem text-white md:text-xl">
{t('HOME_PAGE.CTA_DESCRIPTION')}
</div>
<div className="flex flex-col items-center space-y-4 pt-4">
<div className="flex flex-col items-center space-y-4 pt-10">
<a
href={t('HOME_PAGE.WHITEPAPER_LINK')}
className={`flex items-center justify-center space-x-2 whitespace-nowrap rounded-full bg-lightGray3 px-3 py-1 text-sm text-lightWhite transition-colors duration-300 hover:bg-lightGray1 hover:text-black`}
Expand Down
Loading

0 comments on commit 96196fc

Please sign in to comment.