Skip to content

Commit

Permalink
feat: default use zh-CN(temporarily)
Browse files Browse the repository at this point in the history
  • Loading branch information
YongZL committed Jun 26, 2024
1 parent fb24f2f commit 751f1b6
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 7 deletions.
6 changes: 3 additions & 3 deletions src/components/common/DivText.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ const DivText: FC<TextType> = ({ textArray = [] }) => {
{textArray.length &&
textArray.map((item, key) => {
return (
<div key={`text_${key}`} className="break-all ">
<span className=" font-bold leading-7 text-[#000000] mo:text-[15px]">{item.text}</span>
<span className=" font-normal text-[#666666] text-[15px] mo:text-[15px]">{item.value}</span>
<div key={`text_${key}`} className="break-all text-[15px] ">
<span className=" font-bold leading-7 text-[#000000] ">{item.text}</span>
<span className=" font-normal text-[#666666]">{item.value}</span>
</div>
);
})}
Expand Down
2 changes: 1 addition & 1 deletion src/components/common/header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ export function Header(p: HTMLAttributes<HTMLDivElement>) {
</WrapLink>

<div className="flex items-center gap-5">
<SelectLang postLocalesData={() => LngList} reload={false} />
{/* <SelectLang postLocalesData={() => LngList} reload={false} /> */}

{!isMobile && <MenuAction key="menu" />}
</div>
Expand Down
10 changes: 7 additions & 3 deletions src/components/routes/home.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ import {
import { useT } from '@/lib/hooks/useT';
import { scrollToAnchor } from '@/lib/utils';
import classNames from 'classnames';
import { Fragment, useState } from 'react';
import { Fragment, useEffect, useState } from 'react';
import { WrapLink } from '../ant/Link';
import { Btn } from '../common/button';
import { useNavigate } from '@umijs/max';
import { setLocale, useNavigate } from '@umijs/max';

function Card() {
const { user } = useUser();
Expand Down Expand Up @@ -276,7 +276,7 @@ function CardTabs() {
<div
className={`flex text-lg mo:text-base flex-shrink-0 max-w-[75rem] mo:max-w-auto mo:px-0 pt-10 pb-5 px-5 flex-col w-full mo:flex-col mo:mt-11 mo:mb-0`}
>
<ul className="flex justify-between w-full pb-8 gap-5 mo:flex-col mo:pb-0">
<ul className="flex justify-between w-full gap-5 pb-8 mo:flex-col mo:pb-0">
{tabsList.map((v, i) => {
return (
<li key={`tabsList${i}`} className={classNames('w-0 flex-1 flex mo:w-full mo:flex-col')}>
Expand Down Expand Up @@ -331,6 +331,10 @@ function CardTabs() {

export function Home() {
const { user } = useUser();

useEffect(() => {
setLocale('zh-CN');
}, []);
return (
<HomeHeaderLayout>
<div className={`flex flex-col flex-shrink-0 mo:items-center mo:h-[37.25rem] w-full `}>
Expand Down

0 comments on commit 751f1b6

Please sign in to comment.