Jelajahi Sumber

Merge branch 'feature-tianyong' into gym-test

TIANYONG 6 bulan lalu
induk
melakukan
6c335949c9

+ 1 - 1
src/page-instrument/header-top/index.module.less

@@ -267,7 +267,7 @@
             display: flex;
             align-items: center;
             justify-content: center;
-            background: #FFC121;
+            background: #FE9825;
             border-radius: 120px 120px 120px 1px;
             border: 1px solid #FFFFFF;
 

+ 2 - 2
src/page-instrument/header-top/settting/index.tsx

@@ -85,7 +85,7 @@ export default defineComponent({
                                     <Switch v-model={state.setting.repeatAutoPlay}></Switch>
                                 </div>
                         }                        
-                        {
+                        {/* {
                             state.isSingleLine && state.modeType === "practise" && !state.isCombineRender && !state.isPercussion && 
                                 <div class={styles.cellBox}>
                                 <div class={styles.tit}>旋律线</div>
@@ -96,7 +96,7 @@ export default defineComponent({
                                         }}                                        
                                     ></Switch>
                                 </div>   
-                        }
+                        } */}
                         <div class={styles.cellBox} style={{border:"none"}}>
                                 <div class={styles.tit}>指针模式</div>
                                 <div class={styles.radioBox}>

+ 4 - 4
src/page-instrument/view-detail/smoothAnimation/index.ts

@@ -83,7 +83,7 @@ export function initSmoothAnimation() {
    const batePos2 = createSmoothCurvePoints(batePos1, _numberOfSegments)
    smoothAnimationState.pointsPos = batePos2
    // 初始化旋律线
-   initCanvasSmooth()
+   //initCanvasSmooth() 暂时关闭旋律线
    // 谱面的平均速度(因为可能有反复的情况所以实际距离要加上反复的距离)
    const canvasDomPath = batePos.reduce((path, item, index, arr) => {
       if (index !== 0) {
@@ -138,7 +138,7 @@ export function destroySmoothAnimation() {
    smoothAnimationState.isShow.value = false
    window.removeEventListener("resize", calcClientWidth)
    // 销毁组件 防止内存泄漏
-   smoothAnimationState.smoothBotDom && render(null, smoothAnimationState.smoothBotDom)
+   //smoothAnimationState.smoothBotDom && render(null, smoothAnimationState.smoothBotDom) //关闭旋律线
    smoothAnimationState.smoothAnimationBoxDom?.remove()
    Object.assign(smoothAnimationState, {
       canvasDom: null,
@@ -356,7 +356,7 @@ export function moveTranslateXNum(translateXNum: number) {
  */
 function smoothAnimationMove(pos: { x: number; y: number }, progresspointsPos: pointsPosType) {
    smoothAnimationState.smoothBotDom && (smoothAnimationState.smoothBotDom.style.transform = `translate(${pos.x}px, ${pos.y}px)`)
-   smoothAnimationState.canvasCtx && drawSmoothCurveProgress(smoothAnimationState.canvasCtx, progresspointsPos, "#36CFB3")
+   //smoothAnimationState.canvasCtx && drawSmoothCurveProgress(smoothAnimationState.canvasCtx, progresspointsPos, "#36CFB3") 暂时关闭旋律线
 }
 
 /**
@@ -403,7 +403,7 @@ function createSmoothAnimation() {
    smoothBotDom.className = "smoothBot"
    smoothAnimationState.smoothBotDom = smoothBotDom
    // 添加小鸟
-   render(h(Bird), smoothBotDom)
+   //render(h(Bird), smoothBotDom) //关闭旋律线
    smoothAnimationConDom.appendChild(smoothCanvasDom)
    smoothAnimationConDom.appendChild(smoothBotDom)
    smoothAnimationBoxDom.appendChild(smoothAnimationConDom)

+ 1 - 1
src/state.ts

@@ -580,7 +580,7 @@ const state = reactive({
   /** 切换谱面后,作业选段是否需要刷新 */
   workSectionNeedReset: false,
   /** 旋律线开关 */
-  melodyLine: true,
+  melodyLine: false,
   /** 是否是C调,切换到唱名时,只有C调所有的谱面类型都可以播放唱名文件;其它调的只有首调可以播放唱名,因为唱名是按照C调制作的,没有其它调的唱名文件 */
   isCTone: false,
   evxmlAddPartName: false, // 妙极客的部分曲子没有part-name,需要自行添加的part-name

+ 10 - 0
src/view/plugins/toggleMusicSheet/choosePartName/index.module.less

@@ -58,6 +58,16 @@
         &.sheetCon{
           flex-grow: 1;
           overflow: hidden;
+          position: relative;
+          /* 解决iphonex 不能滚动 */
+          .boxCon{
+            position: absolute;
+            left: 0;
+            top: 0;
+            bottom: 0;
+            right: 0;
+            overflow: hidden;
+          }
           .con{
             width: 100%;
             height: calc(100% - 4px);

+ 8 - 6
src/view/plugins/toggleMusicSheet/choosePartName/index.tsx

@@ -80,12 +80,14 @@ export default defineComponent({
               <div class={styles.tips}>(最多可选4个)</div>
             </div>
             <div class={[styles.content, styles.sheetCon]}>
-              <div class={styles.con}>
-                {
-                  props.partListNames.map((item: any)=>{
-                    return <div class={[styles.selBtn,selValues.value.includes(item.value) && styles.active]} onClick={()=>{hanldeSelSheet(item.value)}}>{item.text}</div>
-                  })
-                }
+              <div class={styles.boxCon}>
+                <div class={styles.con}>
+                  {
+                    props.partListNames.map((item: any)=>{
+                      return <div class={[styles.selBtn,selValues.value.includes(item.value) && styles.active]} onClick={()=>{hanldeSelSheet(item.value)}}>{item.text}</div>
+                    })
+                  }
+                </div>
               </div>
             </div>
           </div>