shaogen1995 пре 1 месец
родитељ
комит
1a671f2605

BIN
public/myData/base.ts


BIN
public/myData/home.mp4


Разлика између датотеке није приказан због своје велике величине
+ 18 - 18
public/myData/myDataEN.js


BIN
src/assets/img/closeWithTxt2En.png


BIN
src/assets/img/closeWithTxtEn.png


+ 16 - 0
src/components/Zclose/index.module.scss

@@ -0,0 +1,16 @@
+.Zclose {
+  width: 80px;
+  height: 40px;
+  position: absolute;
+  z-index: 3;
+  top: 6%;
+  right: 4%;
+  cursor: pointer;
+
+  :global {
+    .ZcloseImg {
+      height: 100%;
+      object-fit: contain;
+    }
+  }
+}

+ 29 - 0
src/components/Zclose/index.tsx

@@ -0,0 +1,29 @@
+import React from 'react'
+import styles from './index.module.scss'
+import { useSelector } from 'react-redux'
+import { RootState } from '@/store'
+
+type Props = {
+  imgSrc?: string
+  clickFu: () => void
+}
+
+function Zclose({ imgSrc, clickFu }: Props) {
+  const { myLangue } = useSelector((state: RootState) => state.A0Layout)
+
+  return (
+    <div className={styles.Zclose} onClick={clickFu}>
+      <img
+        className='ZcloseImg'
+        src={require(`@/assets/img/closeWithTxt${imgSrc ? imgSrc : ''}${
+          myLangue === 'EN' ? 'En' : ''
+        }.png`)}
+        alt=''
+      />
+    </div>
+  )
+}
+
+const MemoZclose = React.memo(Zclose)
+
+export default MemoZclose

+ 21 - 18
src/pages/A2yblm/components/Detail/index.module.scss

@@ -2,6 +2,7 @@
   width: 100%;
   height: 100%;
   position: relative;
+
   :global {
     .selectContainner {
       position: absolute;
@@ -23,7 +24,8 @@
         transform: translate(-50%, -50%);
         width: 4px;
         height: 84%;
-        & > img {
+
+        &>img {
           width: 100%;
           height: 100%;
           object-fit: contain;
@@ -38,21 +40,24 @@
         align-items: center;
         justify-content: space-between;
         gap: 10px;
+
         .topL {
           width: 100px;
           height: fit-content;
           display: flex;
           flex-direction: column;
           gap: 10px;
+
           .item {
             width: 100px;
             height: 27px;
-            font-size: 14px;
+            font-size: 18px;
             line-height: 15px;
             text-align: right;
             color: rgba(255, 233, 182, 1);
             cursor: pointer;
             position: relative;
+
             .selectedBg {
               width: 120px;
               height: 100%;
@@ -60,35 +65,41 @@
               top: -30%;
               left: 31%;
               z-index: -1;
-              & > img {
+
+              &>img {
                 width: 100%;
                 height: 100%;
                 object-fit: contain;
               }
             }
           }
+
           .active {
             color: rgb(255, 252, 246);
             text-shadow: 3px 0px 10px rgba(255, 255, 255, 1);
           }
         }
+
         .topR {
           width: 40px;
           height: 100%;
           display: flex;
           align-items: center;
+
           .split {
             width: 2px;
             height: 100%;
           }
+
           .txt {
             width: 40px;
-            font-size: 15px;
+            font-size: 18px;
             writing-mode: vertical-rl;
             text-orientation: upright;
             text-align: right;
             color: rgba(255, 233, 182, 1);
           }
+
           .txtActive {
             color: rgba(255, 252, 246, 0.8);
           }
@@ -98,20 +109,12 @@
   }
 }
 
-// ---------移动端
-.detailMo {
+// ---------英文版
+.detailEn {
   :global {
-    .selectContainner {
-      & > div {
-        & > div {
-          .txt {
-            font-size: 18px !important;
-          }
-          .item {
-            font-size: 18px !important;
-          }
-        }
-      }
+    .topL .item {
+      height: auto !important;
+      font-size: 16px !important;
     }
   }
-}
+}

+ 65 - 34
src/pages/A2yblm/components/Detail/index.tsx

@@ -1,18 +1,17 @@
-import React from "react";
-import styles from "./index.module.scss";
-import { isPc } from "@/utils/http";
-import { callIframeFu } from "@/utils/history";
+import React from 'react'
+import styles from './index.module.scss'
+import { callIframeFu } from '@/utils/history'
 import classNames from 'classnames'
-import { useSelector } from "react-redux";
-import { RootState } from "@/store";
+import { useSelector } from 'react-redux'
+import { RootState } from '@/store'
 
 type DetailProps = {
-  currentTagIndex: number,
-  setCurrentTagIndex: (index: number) => void,
+  currentTagIndex: number
+  setCurrentTagIndex: (index: number) => void
   setIsShowTag: (isShow: boolean) => void
 }
 function Detail({ currentTagIndex, setCurrentTagIndex, setIsShowTag }: DetailProps) {
-  const {myData} = useSelector((state: RootState) => state.A0Layout)
+  const { myData, myLangue } = useSelector((state: RootState) => state.A0Layout)
 
   const handleHot = (index: number) => {
     setCurrentTagIndex(index)
@@ -21,7 +20,7 @@ function Detail({ currentTagIndex, setCurrentTagIndex, setIsShowTag }: DetailPro
 
   setTimeout(() => {
     handleHot(currentTagIndex)
-  }, 20);
+  }, 20)
 
   window.showTag = () => {
     setIsShowTag(true)
@@ -31,43 +30,75 @@ function Detail({ currentTagIndex, setCurrentTagIndex, setIsShowTag }: DetailPro
   }
 
   return (
-    <div className={classNames(styles.detail, isPc ? '' : styles.detailMo)}>
-      <div className="selectContainner">
-        <div className="detail_line">
-          <img src={require(`@/assets/img/A2_line_${currentTagIndex >= myData.detail_modal.top.length ? 'beice.png' : 'beiyang.png'}`)} alt="" />
+    <div className={classNames(styles.detail, myLangue === 'ZH' ? '' : styles.detailEn)}>
+      <div className='selectContainner'>
+        <div className='detail_line'>
+          <img
+            src={require(`@/assets/img/A2_line_${
+              currentTagIndex >= myData.detail_modal.top.length ? 'beice.png' : 'beiyang.png'
+            }`)}
+            alt=''
+          />
         </div>
-        <div className="detail_top">
-          <div className="topL">
+        <div className='detail_top'>
+          <div className='topL'>
             {myData.detail_modal.top.map((item, index) => (
-              <div className={`item ${currentTagIndex === index ? 'active' : ''}`} onClick={() => handleHot(index)} key={index}>
+              <div
+                className={`item ${currentTagIndex === index ? 'active' : ''}`}
+                onClick={() => handleHot(index)}
+                key={index}
+              >
                 {item.title}
-                {currentTagIndex === index && <div className="selectedBg"><img src={require('@/assets/img/hotSelected_bg.png')} alt="" /></div>}
+                {currentTagIndex === index && (
+                  <div className='selectedBg'>
+                    <img src={require('@/assets/img/hotSelected_bg.png')} alt='' />
+                  </div>
+                )}
               </div>
             ))}
           </div>
-          <div className="topR">
-            <div className="split"></div>
-            <div className="txt">碑阳</div>
+          <div className='topR'>
+            <div className='split'></div>
+            <div className='txt'>{myLangue==='EN'?'front':'碑阳'}</div>
           </div>
         </div>
-        <div className="detail_bottom"> <div className="topL">
-          {myData.detail_modal.bottom.map((item, index) => (
-            <div className={`item ${currentTagIndex === index + myData.detail_modal.top.length ? 'active' : ''}`} onClick={() => handleHot(index + myData.detail_modal.top.length)} key={index}>
-              {item.title}
-              {currentTagIndex === index + myData.detail_modal.top.length && <div className="selectedBg"><img src={require('@/assets/img/hotSelected_bg.png')} alt="" /></div>}
+        <div className='detail_bottom'>
+          {' '}
+          <div className='topL'>
+            {myData.detail_modal.bottom.map((item, index) => (
+              <div
+                className={`item ${
+                  currentTagIndex === index + myData.detail_modal.top.length ? 'active' : ''
+                }`}
+                onClick={() => handleHot(index + myData.detail_modal.top.length)}
+                key={index}
+              >
+                {item.title}
+                {currentTagIndex === index + myData.detail_modal.top.length && (
+                  <div className='selectedBg'>
+                    <img src={require('@/assets/img/hotSelected_bg.png')} alt='' />
+                  </div>
+                )}
+              </div>
+            ))}
+          </div>
+          <div className='topR'>
+            <div className='split'></div>
+            <div
+              className={`txt ${
+                currentTagIndex >= myData.detail_modal.top.length ? 'txtActive' : ''
+              }`}
+            >
+              
+              {myLangue==='EN'?'side':'碑侧'}
             </div>
-          ))}
+          </div>
         </div>
-          <div className="topR">
-            <div className="split"></div>
-            <div className={`txt ${currentTagIndex >= myData.detail_modal.top.length ? 'txtActive' : ''}`}>碑侧</div>
-          </div></div>
       </div>
-
     </div>
   )
 }
 
-const MemoDetail = React.memo(Detail);
+const MemoDetail = React.memo(Detail)
 
-export default MemoDetail;
+export default MemoDetail

+ 4 - 3
src/pages/A2yblm/components/ModalTxt/data.ts

@@ -1,5 +1,6 @@
 export const modalTxtTab = [
-  { key: 1, name: '造碑人与碑主', sonTxt: '壹' },
-  { key: 2, name: '程哲生平与家族世系', sonTxt: '贰' },
-  { key: 3, name: '颂文', sonTxt: '叄' }
+  { key: 1,nameEn:'Stele Creators and Commemorated Subjects', name: '造碑人与碑主', sonTxt: '壹' },
+  { key: 2,nameEn:'Cheng Zhe’s Life and Family Lineage', name: '程哲生平与家族世系', sonTxt: '贰' },
+  { key: 3,nameEn:'eulogium', name: '颂文', sonTxt: '叄' }
 ]
+

+ 73 - 111
src/pages/A2yblm/components/ModalTxt/index.module.scss

@@ -5,7 +5,7 @@
   z-index: 1;
   top: 50%;
   left: 50%;
-  transform: translate(-8%, -50%);
+  transform: translate(-4%, -50%);
   display: flex;
   align-items: center;
   justify-content: flex-end;
@@ -19,30 +19,30 @@
       gap: 10px;
 
       .topBar {
-        padding-left: 20px;
-        width: 90%;
+        padding-left: 0;
+        padding-right: 0;
+        justify-content: left;
+        width: 72%;
         height: 70px;
         display: flex;
         align-items: center;
-        justify-content: space-around;
-        padding-right: 60px;
         position: relative;
         gap: 10px;
         margin-top: 10px;
 
         .beie {
-          width: 100px;
-          height: 50px;
+          top: 11px;
+          left: -97px;
+          height: 60px;
+          width: 120px;
           font-size: 10px;
           line-height: 50px;
           color: #fff;
           position: absolute;
           align-self: flex-start;
-          top: 35px;
-          left: -109px;
 
-          & > img {
-            width: 100px;
+          &>img {
+            width: 100%;
             object-fit: contain;
           }
 
@@ -54,6 +54,8 @@
             left: 50%;
             transform: translate(-65%, -50%);
             cursor: pointer;
+            margin-left: 6px;
+            font-size: 18px;
           }
         }
 
@@ -62,15 +64,15 @@
         .tab2 {
           width: fit-content;
           min-width: 70px;
-          height: 50px;
+          height: 60px;
           display: flex;
           align-items: center;
           flex-direction: column;
           cursor: pointer;
           position: relative;
 
-          & > img {
-            height: 45px;
+          &>img {
+            height: 50px;
             object-fit: contain;
           }
 
@@ -92,16 +94,37 @@
             font-size: 10px;
             line-height: 15px;
             text-align: center;
-            font-weight: lighter;
             color: rgba(255, 255, 255, 1);
-            width: 200%;
+            width: 100%;
             font-weight: 700;
+            font-size: 14px;
           }
         }
 
         .tab:nth-child(3) {
           width: 100px;
         }
+
+        .tab0 {
+          width: 84px;
+        }
+
+        .tab1 {
+          width: 140px;
+          padding-left: 10px;
+
+          .tabNub {
+            transform: translate(-27%, -50%) !important;
+          }
+        }
+
+        .tab2 {
+          width: 60px;
+
+          .tabNub {
+            transform: translate(-50%, -50%) !important;
+          }
+        }
       }
 
       .intro {
@@ -149,7 +172,8 @@
             color: rgba(94, 52, 34, 1); // 原始颜色
             overflow: auto;
             padding-bottom: 10px;
-            -webkit-overflow-scrolling: touch; /* 启用原生平滑滚动 */
+            -webkit-overflow-scrolling: touch;
+            /* 启用原生平滑滚动 */
             overflow-scrolling: touch;
             overscroll-behavior-y: none;
 
@@ -157,6 +181,7 @@
               width: 100%;
               height: 17px;
             }
+
             .t2 {
               width: 100%;
               height: 370px;
@@ -179,11 +204,11 @@
               color: rgba(0, 0, 0, 0.25);
             }
 
-            &:has(> a:hover) > a:not(:hover) {
+            &:has(> a:hover)>a:not(:hover) {
               color: rgba(0, 0, 0, 0.25);
             }
 
-            & > a {
+            &>a {
               color: rgba(94, 52, 34, 1);
               position: relative;
 
@@ -222,21 +247,22 @@
         color: rgba(94, 52, 34, 1);
 
         .title {
-          font-size: 13px;
+          font-size: 20px;
           line-height: 20px;
           font-weight: bold;
         }
 
         .text {
           width: 400px;
-          line-height: 15px;
-          font-size: 9px;
+          line-height: 24px;
+          font-size: 16px;
           text-align: justify;
           letter-spacing: 2px;
           color: #504e40;
 
-          // & > p {
-          // }
+          &>p {
+            padding-bottom: 10px;
+          }
         }
       }
     }
@@ -244,112 +270,48 @@
 }
 
 // -----------移动端
-.modalTxtMo {
-  transform: translate(-4%, -50%);
+.modalTxtEn {
 
   :global {
     .modalTxtContainner {
       .topBar {
-        padding-left: 0;
-        padding-right: 0;
-        justify-content: left;
-        width: 72%;
-        .beie {
-          top: 11px;
-          left: -97px;
-          height: 60px;
-          width: 120px;
-
-          & > img {
-            width: 100%;
-          }
-
-          .txt {
-            margin-left: 6px;
-            font-size: 18px;
-          }
+        .beie .txt {
+          width: auto;
+          font-size: 16px;
         }
 
-        .tab1,
-        .tab2,
         .tab0 {
-          height: 60px;
-
-          img {
-            height: 50px;
-          }
+          width: 100px;
+        }
 
+        .tab0,
+        .tab1,
+        .tab2 {
           .txt {
-            width: 100%;
-            font-size: 14px;
+            font-size: 12px !important;
           }
         }
-        .tab0 {
-          width: 84px;
-        }
-        .tab1 {
-          width: 140px;
-          padding-left: 10px;
-          .tabNub {
-            transform: translate(-27%, -50%) !important;
-          }
-        }
-        .tab2 {
-          width: 60px;
-          .tabNub {
-            transform: translate(-50%, -50%) !important;
-          }
+
+        .txtAc {
+          width: 300px !important;
+          max-width: 9999px;
+          position: absolute;
+          bottom: -5px;
+          left: 50%;
+          transform: translateX(-50%);
         }
       }
 
       .content {
-        .title {
-          font-size: 20px;
-        }
+        position: relative;
+        top: 20px;
 
         .text {
-          line-height: 20px;
-          font-size: 16px;
-          line-height: 24px;
-          & > p {
-            padding-bottom: 10px;
-          }
+          text-align: start;
+          letter-spacing: 0;
         }
       }
 
-      .intro {
-        font-size: 15px;
-        line-height: 21px;
-
-        font-weight: 400;
-        color: #504e40;
-      }
-
-      .detailTxt {
-        .title {
-          font-size: 16px !important;
-          line-height: 0px !important;
-        }
-
-        .txt {
-          font-size: 16px !important;
-          line-height: 22px !important;
-          letter-spacing: 2px;
-
-          a::after {
-            bottom: -2px !important;
-            height: 2px !important;
-          }
-
-          &:has(> a:hover) {
-            color: rgba(94, 52, 34, 1) !important;
-          }
-
-          &:has(> a:hover) > a:not(:hover) {
-            color: rgba(94, 52, 34, 1) !important;
-          }
-        }
-      }
     }
   }
-}
+}

+ 12 - 12
src/pages/A2yblm/components/ModalTxt/index.tsx

@@ -1,7 +1,6 @@
 /* eslint-disable jsx-a11y/anchor-is-valid */
 import React, { useState, useEffect, useRef, useCallback } from 'react'
 import styles from './index.module.scss'
-import { isPc } from '@/utils/http'
 import { Tooltip } from 'antd'
 import { callIframeFu, isMobiileFu } from '@/utils/history'
 import classNames from 'classnames'
@@ -18,7 +17,7 @@ type Props = {
 }
 
 function ModalTxt({ setIsShowTabBar, setIsShowMzmTitle, setBottomTxt }: Props, ref: any) {
-  const { myData } = useSelector((state: RootState) => state.A0Layout)
+  const { myData,myLangue } = useSelector((state: RootState) => state.A0Layout)
 
   const [selectedTab, setSelectedTab] = useState(0)
   const selectedTabRef = useRef(0)
@@ -337,13 +336,14 @@ function ModalTxt({ setIsShowTabBar, setIsShowMzmTitle, setBottomTxt }: Props, r
   }
 ,[setBottomTxt, setIsShowMzmTitle])
   return (
-    <div className={classNames(styles.modalTxt, isPc ? '' : styles.modalTxtMo)} id='modalTxt'>
+    <div className={classNames(styles.modalTxt, myLangue==='ZH' ? '' : styles.modalTxtEn)} id='modalTxt'>
       <div className='modalTxtContainner'>
         <div className='topBar'>
           <div className='beie' hidden={selectedTab !== 0}>
             <img src={require('@/assets/img/beie.png')} alt='' />
             <div className='txt' onClick={handleBeie}>
-              碑额
+              {myLangue==='EN'?'forehead':'碑额'}
+              
             </div>
           </div>
 
@@ -363,10 +363,10 @@ function ModalTxt({ setIsShowTabBar, setIsShowMzmTitle, setBottomTxt }: Props, r
                 {item.sonTxt}
               </div>
               <div
-                className='txt'
+                className={classNames('txt',selectedTab === item.key ? 'txtAc' : '')}
                 style={{ opacity: selectedTab === item.key || selectedTab === 0 ? '1' : '0' }}
               >
-                {item.name}
+                {myLangue==='EN'?item.nameEn: item.name}
               </div>
             </div>
           ))}
@@ -408,13 +408,13 @@ function ModalTxt({ setIsShowTabBar, setIsShowMzmTitle, setBottomTxt }: Props, r
 
         {selectedTab === 0 && (
           <div className='content'>
-            <div className='title myFont'>碑文概述</div>
+            <div className='title myFont'>{myLangue==='EN'?'Overview of the Inscription':'碑文概述'}</div>
             <div className='text'>
-             程哲碑碑文,
-            <br /> 31行楷书,满行45字,
-            <br /> 字径约2厘米,带方界格,总计1404字;
-            <br /> 未刻正式碑名。 <br />
-            通篇颂德程氏家族的历史功绩。
+             {myLangue==='EN'?'The inscription on the Cheng Zhe Stele consists of 31 lines of regular script,':'程哲碑碑文,'}
+            <br />{myLangue==='EN'?'with 45 characters per line at maximum. ':'31行楷书,满行45字,'}
+            <br /> {myLangue==='EN'?' The characters are approximately 2 cm in size, set within square grids, totaling 1,404 characters.':'字径约2厘米,带方界格,总计1404字;'}
+            <br /> {myLangue==='EN'?'No formal title of the stele is engraved. ':'未刻正式碑名。 '}<br />
+            {myLangue==='EN'?'The entire text praises the historical achievements of the Cheng family.':'通篇颂德程氏家族的历史功绩。'}
             </div>
           </div>
         )}

+ 14 - 0
src/pages/A2yblm/index.module.scss

@@ -316,6 +316,7 @@
 
     .A2_tabBar {
       top: 48%;
+
       .tab {
         word-break: break-all;
         padding: 0 6px;
@@ -323,5 +324,18 @@
         height: 70px;
       }
     }
+
+    .tagInfo {
+      .top {
+        .title {
+          width: auto;
+          max-width: 100%;
+        }
+      }
+      .content>div{
+        letter-spacing: 0;
+        text-align: start;
+      }
+    }
   }
 }

+ 29 - 90
src/pages/A5wenwu/index.module.scss

@@ -4,28 +4,14 @@
   position: relative;
 
   :global {
-    .back {
-      width: 60px;
-      height: 30px;
-      position: absolute;
-      z-index: 1;
-      top: 3%;
-      left: 4%;
-      cursor: pointer;
-
-      & > img {
-        height: 100%;
-        object-fit: contain;
-      }
-    }
 
     .gesture {
-      width: 120px;
+      width: 140px;
       height: 70px;
       position: absolute;
       z-index: 1;
       top: 50%;
-      left: 50%;
+      left: 46%;
       transform: translate(120%, -50%);
       display: flex;
       align-items: center;
@@ -33,12 +19,12 @@
       flex-direction: column;
 
       &.state1 {
-        & > img {
+        &>img {
           animation: gestureState1 2s linear;
         }
       }
 
-      & > img {
+      &>img {
         transform: translateX(0);
         width: 100%;
         object-fit: contain;
@@ -49,7 +35,7 @@
         height: 17px;
         text-align: center;
         line-height: 15px;
-        font-size: 8px;
+        font-size: 16px;
         font-weight: lighter;
         color: #fff;
       }
@@ -63,7 +49,7 @@
       flex-direction: column;
       position: absolute;
       z-index: 1;
-      top: 50%;
+      top: 46%;
       left: 5%;
       gap: 20px;
       transform: translateY(-50%);
@@ -73,11 +59,12 @@
         align-items: center;
         justify-content: center;
         flex-direction: column;
-        width: 40px;
-        height: 55px;
+        width: 60px;
+        height: 60px;
+        margin: 7px 0;
         cursor: pointer;
 
-        & > img {
+        &>img {
           width: 100%;
           object-fit: contain;
         }
@@ -88,9 +75,10 @@
           text-align: center;
           line-height: 15px;
           letter-spacing: 1px;
-          font-size: 10px;
           font-weight: 500;
           color: #fbebbd;
+          margin-top: 4px;
+          font-size: 14px;
         }
       }
     }
@@ -103,7 +91,7 @@
       flex-direction: column;
       position: absolute;
       z-index: 1;
-      top: 50%;
+      top: 46%;
       right: 5%;
       transform: translateY(-50%);
 
@@ -112,11 +100,12 @@
         align-items: center;
         justify-content: center;
         flex-direction: column;
-        width: 25px;
-        height: 55px;
         cursor: pointer;
+        width: 45px;
+        height: 65px;
+        margin: 8px 0;
 
-        & > img {
+        &>img {
           width: 100%;
           object-fit: contain;
         }
@@ -127,7 +116,7 @@
           text-align: center;
           line-height: 15px;
           letter-spacing: 1px;
-          font-size: 10px;
+          font-size: 14px;
           font-weight: 500;
           color: #fbebbd;
         }
@@ -148,21 +137,9 @@
   display: flex;
   align-items: center;
   justify-content: center;
+
   :global {
-    .close {
-      width: 80px;
-      height: 40px;
-      position: absolute;
-      z-index: 3;
-      top: 6%;
-      right: 4%;
-      cursor: pointer;
 
-      & > img {
-        height: 100%;
-        object-fit: contain;
-      }
-    }
     .TContainner {
       position: relative;
       width: 100%;
@@ -170,6 +147,7 @@
       display: flex;
       align-items: center;
       justify-content: center;
+
       .TLeft {
         position: absolute;
         left: 2%;
@@ -180,6 +158,7 @@
         align-items: center;
         justify-content: center;
         gap: 40px;
+
         .Tbtn1,
         .Tbtn2 {
           transition: all 0.3s ease-in-out;
@@ -194,6 +173,7 @@
           background-size: 100% 100%;
           color: rgba(255, 233, 182, 1);
         }
+
         .TActive {
           color: rgba(124, 75, 54, 1);
           background: url('../../assets/img/btn_tabAc.png') no-repeat;
@@ -204,55 +184,14 @@
   }
 }
 
-// ---------移动端
-.A5wenwuMo {
+// ---------英文版
+.A5wenwuEn {
   :global {
-    .back {
-      width: 80px;
-      height: 40px;
-
-      img {
-        object-fit: fill !important;
-      }
-    }
-
-    .A5_tabBar {
-      top: 46%;
-
-      .tab {
-        width: 60px;
-        height: 60px;
-        margin: 7px 0;
-
-        .txt {
-          margin-top: 4px;
-          font-size: 14px;
-        }
-      }
-    }
-
-    .gesture {
-      left: 46%;
-      width: 140px;
-      height: 120px;
-
-      .txt {
-        font-size: 16px;
-      }
+    .A5_tabBar .tab .txt{
+      width: auto;
     }
-
-    .A5_tabBarR {
-      top: 46%;
-
-      .tab {
-        width: 45px;
-        height: 65px;
-        margin: 8px 0;
-
-        .txt {
-          font-size: 14px;
-        }
-      }
+    .A5_tabBarR .tab .txt{
+      width: auto;
     }
   }
-}
+}

+ 78 - 36
src/pages/A5wenwu/index.tsx

@@ -2,9 +2,14 @@ import React, { useEffect, useState } from 'react'
 import styles from './index.module.scss'
 import { callIframeFu } from '@/utils/history'
 import classNames from 'classnames'
-import { isPc } from '@/utils/http'
+import { useSelector } from 'react-redux'
+import { RootState } from '@/store'
+import Zback from '@/components/Zback'
+import Zclose from '@/components/Zclose'
 
 function A5wenwu() {
+  const { myLangue } = useSelector((state: RootState) => state.A0Layout)
+
   const [currentTab, setCurrentTab] = useState('tab0')
   const [isShowGesture, setIsShowGesture] = useState(true)
   const [isShowTapianModal, setIsShowTapianModal] = useState(false)
@@ -25,7 +30,6 @@ function A5wenwu() {
     }, 500)
   }, [])
 
-
   useEffect(() => {
     if (currentTab !== 'tab1') callIframeFu('hideSize', undefined)
   }, [currentTab])
@@ -75,15 +79,15 @@ function A5wenwu() {
   }
 
   return (
-    <div className={classNames(styles.A5wenwu, isPc ? '' : styles.A5wenwuMo)}>
-      <div className='back' onClick={gotoBack}>
-        <img src={require('@/assets/img/btn_back.png')} alt='' />
-      </div>
+    <div className={classNames(styles.A5wenwu, myLangue === 'ZH' ? '' : styles.A5wenwuEn)}>
+      <Zback clickFu={() => gotoBack()} />
 
       {isShowGesture && (
-        <div className={classNames('gesture', gestureState1)} >
+        <div className={classNames('gesture', gestureState1)}>
           <img src={require('@/assets/img/A5_gesture.png')} alt='' />
-          <div className='txt'>单指滑动进行旋转</div>
+          <div className='txt'>
+            {myLangue === 'EN' ? 'Rotate by swiping with a single finger' : '单指滑动进行旋转'}
+          </div>
         </div>
       )}
 
@@ -94,21 +98,21 @@ function A5wenwu() {
             src={require(`@/assets/img/A5_size${currentTab === 'tab1' ? 'Ac' : ''}.png`)}
             alt=''
           />
-          <div className='txt'>尺寸</div>
+          <div className='txt'>{myLangue === 'EN' ? 'size' : '尺寸'}</div>
         </div>
         <div className={`tab`} onClick={handleTapian}>
           <img
             src={require(`@/assets/img/A5_tapian${currentTab === 'tab2' ? 'Ac' : ''}.png`)}
             alt=''
           />
-          <div className='txt'>拓片</div>
+          <div className='txt'>{myLangue === 'EN' ? 'rubbings' : '拓片'}</div>
         </div>
         <div className={`tab`} onClick={handleLine}>
           <img
             src={require(`@/assets/img/A5_line${currentTab === 'tab3' ? 'Ac' : ''}.png`)}
             alt=''
           />
-          <div className='txt'>线图</div>
+          <div className='txt'>{myLangue === 'EN' ? 'graph' : '线图'}</div>
         </div>
       </div>
 
@@ -116,50 +120,88 @@ function A5wenwu() {
       <div className='A5_tabBarR'>
         <div className={`tab`} onClick={() => handleZoomIn(0.1)}>
           <img src={require(`@/assets/img/A5_zoomin.png`)} alt='' />
-          <div className='txt'>放大</div>
+          <div className='txt'>{myLangue === 'EN' ? 'zoomIn' : '放大'}</div>
         </div>
         <div className={`tab`} onClick={() => handleZoomOut(0.1)}>
           <img src={require(`@/assets/img/A5_zoomout.png`)} alt='' />
-          <div className='txt'>缩小</div>
+          <div className='txt'>{myLangue === 'EN' ? 'zoomOut' : '缩小'}</div>
         </div>
         <div className={`tab`} onClick={handleReset}>
           <img src={require(`@/assets/img/A5_reset.png`)} alt='' />
-          <div className='txt'>重置</div>
+          <div className='txt'>{myLangue === 'EN' ? 'reset' : '重置'}</div>
         </div>
       </div>
 
       {/* 拓片弹窗 */}
-      <div className={classNames(styles.tapianModal)} style={{ display: isShowTapianModal ? 'flex' : 'none' }}>
-        <div className='close' onClick={() => { handleTabClick('tab2'); setIsShowTapianModal(false) }}>
-          <img src={require('@/assets/img/closeWithTxt.png')} alt='' />
-        </div>
-        <div className="TContainner">
-          <div className="TLeft">
-            <div className={`Tbtn1 ${tapianType === '碑面' ? 'TActive' : ''}`} onClick={() => setTapianType('碑面')}>碑面</div>
-            <div className={`Tbtn2 ${tapianType === '碑文' ? 'TActive' : ''}`} onClick={() => setTapianType('碑文')}>碑文</div>
+      <div
+        className={classNames(styles.tapianModal)}
+        style={{ display: isShowTapianModal ? 'flex' : 'none' }}
+      >
+        <Zclose
+          clickFu={() => {
+            handleTabClick('tab2')
+            setIsShowTapianModal(false)
+          }}
+        />
+
+        <div className='TContainner'>
+          <div className='TLeft'>
+            <div
+              className={`Tbtn1 ${tapianType === '碑面' ? 'TActive' : ''}`}
+              onClick={() => setTapianType('碑面')}
+            >
+               {myLangue === 'EN' ? 'face' : '碑面'}
+            </div>
+            <div
+              className={`Tbtn2 ${tapianType === '碑文' ? 'TActive' : ''}`}
+              onClick={() => setTapianType('碑文')}
+            >
+              {myLangue === 'EN' ? 'text' : '碑文'}
+            </div>
           </div>
-          <div className="TRight">
-            <img src={require(`@/assets/img/A5_tapian${tapianType === '碑面' ? '1' : '2'}.png`)} alt="" />
+          <div className='TRight'>
+            <img
+              src={require(`@/assets/img/A5_tapian${tapianType === '碑面' ? '1' : '2'}.png`)}
+              alt=''
+            />
           </div>
         </div>
-
       </div>
 
       {/* 线图弹窗 */}
-      <div className={classNames(styles.lineModal)} style={{ display: isShowLineModal ? 'flex' : 'none' }}>
-        <div className='close' onClick={() => { handleTabClick('tab3'); setIsShowLineModal(false) }}>
-          <img src={require('@/assets/img/closeWithTxt.png')} alt='' />
-        </div>
-        <div className="TContainner">
-          <div className="TLeft">
-            <div className={`Tbtn1 ${lineType === '碑面' ? 'TActive' : ''}`} onClick={() => setLineType('碑面')}>碑面</div>
-            <div className={`Tbtn2 ${lineType === '碑文' ? 'TActive' : ''}`} onClick={() => setLineType('碑文')}>碑文</div>
+      <div
+        className={classNames(styles.lineModal)}
+        style={{ display: isShowLineModal ? 'flex' : 'none' }}
+      >
+        <Zclose
+          clickFu={() => {
+            handleTabClick('tab3')
+            setIsShowLineModal(false)
+          }}
+        />
+
+        <div className='TContainner'>
+          <div className='TLeft'>
+            <div
+              className={`Tbtn1 ${lineType === '碑面' ? 'TActive' : ''}`}
+              onClick={() => setLineType('碑面')}
+            >
+              {myLangue === 'EN' ? 'face' : '碑面'}
+            </div>
+            <div
+              className={`Tbtn2 ${lineType === '碑文' ? 'TActive' : ''}`}
+              onClick={() => setLineType('碑文')}
+            >
+              {myLangue === 'EN' ? 'text' : '碑文'}
+            </div>
           </div>
-          <div className="TRight">
-            <img src={require(`@/assets/img/A5_xiantu${lineType === '碑面' ? '1' : '2'}.png`)} alt="" />
+          <div className='TRight'>
+            <img
+              src={require(`@/assets/img/A5_xiantu${lineType === '碑面' ? '1' : '2'}.png`)}
+              alt=''
+            />
           </div>
         </div>
-
       </div>
     </div>
   )