|
@@ -2,15 +2,15 @@ import { defineComponent, toRefs, PropType, ref, Transition, onMounted } from 'v
|
|
import { Button, Grid, GridItem, Popup } from 'vant'
|
|
import { Button, Grid, GridItem, Popup } from 'vant'
|
|
import qs from 'query-string'
|
|
import qs from 'query-string'
|
|
import { MusicSheelDetail, ShaeetStatusType } from '../../colexiu/index.d'
|
|
import { MusicSheelDetail, ShaeetStatusType } from '../../colexiu/index.d'
|
|
-import BackIcon from '../../colexiu/header/icons/back.svg'
|
|
|
|
|
|
+import BackIcon from '../../colexiu/buttons/icons/icon-back.svg'
|
|
import { heardLevel } from '/src/constant/formats'
|
|
import { heardLevel } from '/src/constant/formats'
|
|
import Note from '/src/pages/report/note'
|
|
import Note from '/src/pages/report/note'
|
|
import PlayerPopup from '/src/pages/report/player'
|
|
import PlayerPopup from '/src/pages/report/player'
|
|
import styles from './index.module.less'
|
|
import styles from './index.module.less'
|
|
import state from '/src/pages/state'
|
|
import state from '/src/pages/state'
|
|
import AgainIcon from '../again.svg'
|
|
import AgainIcon from '../again.svg'
|
|
-import ExplainIcon from '../explain.svg'
|
|
|
|
-import ReplayIcon from '../replay.svg'
|
|
|
|
|
|
+import ExplainIcon from '../icon-explain.png'
|
|
|
|
+import ReplayIcon from '../icon-replay.png'
|
|
import CloseIcon from './close.png'
|
|
import CloseIcon from './close.png'
|
|
import detailStyles from './index.module.less'
|
|
import detailStyles from './index.module.less'
|
|
import { postMessage } from '/src/helpers/native-message'
|
|
import { postMessage } from '/src/helpers/native-message'
|
|
@@ -40,6 +40,7 @@ export default defineComponent({
|
|
},
|
|
},
|
|
emits: ['activeChange'],
|
|
emits: ['activeChange'],
|
|
setup(props, { emit, expose }) {
|
|
setup(props, { emit, expose }) {
|
|
|
|
+ const { detail, record } = toRefs(props)
|
|
const back = () => {
|
|
const back = () => {
|
|
postMessage({
|
|
postMessage({
|
|
api: 'back',
|
|
api: 'back',
|
|
@@ -87,30 +88,29 @@ export default defineComponent({
|
|
})
|
|
})
|
|
|
|
|
|
return () => {
|
|
return () => {
|
|
- const { detail, record } = toRefs(props)
|
|
|
|
return (
|
|
return (
|
|
<header class={[styles.header, styles.className]}>
|
|
<header class={[styles.header, styles.className]}>
|
|
<div class={styles.info}>
|
|
<div class={styles.info}>
|
|
- {search.source !== 'web' ? (
|
|
|
|
|
|
+ <div class={styles.leftButton}>
|
|
<Button onClick={back} class={styles.back}>
|
|
<Button onClick={back} class={styles.back}>
|
|
<img src={BackIcon} alt="back" />
|
|
<img src={BackIcon} alt="back" />
|
|
</Button>
|
|
</Button>
|
|
- ) : null}
|
|
|
|
- <div class={[styles.maininfo, 'van-ellipsis']}></div>
|
|
|
|
|
|
+ <span class={styles.musicName}>{record?.value?.sysMusicScoreName}</span>
|
|
|
|
+ </div>
|
|
{record.value && record.value?.heardLevel ? (
|
|
{record.value && record.value?.heardLevel ? (
|
|
<Grid class={styles.center} columnNum={5}>
|
|
<Grid class={styles.center} columnNum={5}>
|
|
<GridItem
|
|
<GridItem
|
|
class="van-hairline--right"
|
|
class="van-hairline--right"
|
|
vSlots={{
|
|
vSlots={{
|
|
- text: () => <span>难度</span>,
|
|
|
|
icon: () => <span>{(heardLevel as any)[record.value?.heardLevel]}</span>,
|
|
icon: () => <span>{(heardLevel as any)[record.value?.heardLevel]}</span>,
|
|
|
|
+ text: () => <span>难度</span>,
|
|
}}
|
|
}}
|
|
/>
|
|
/>
|
|
<GridItem
|
|
<GridItem
|
|
class="van-hairline--right"
|
|
class="van-hairline--right"
|
|
vSlots={{
|
|
vSlots={{
|
|
- text: () => <span>评测分数</span>,
|
|
|
|
icon: () => <span>{record.value?.score}分</span>,
|
|
icon: () => <span>{record.value?.score}分</span>,
|
|
|
|
+ text: () => <span>评测分数</span>,
|
|
}}
|
|
}}
|
|
/>
|
|
/>
|
|
<GridItem
|
|
<GridItem
|
|
@@ -120,8 +120,8 @@ export default defineComponent({
|
|
emit('activeChange', 'pitch')
|
|
emit('activeChange', 'pitch')
|
|
}}
|
|
}}
|
|
vSlots={{
|
|
vSlots={{
|
|
|
|
+ icon: () => <span style={{ color: 'var(--van-primary-color)' }}>{record.value?.intonation}分</span>,
|
|
text: () => <span class={['switch', { active: active.value === 'pitch' }]}>音准</span>,
|
|
text: () => <span class={['switch', { active: active.value === 'pitch' }]}>音准</span>,
|
|
- icon: () => <span style={{ color: '#2DC7AA' }}>{record.value?.intonation}分</span>,
|
|
|
|
}}
|
|
}}
|
|
/>
|
|
/>
|
|
<GridItem
|
|
<GridItem
|
|
@@ -131,8 +131,8 @@ export default defineComponent({
|
|
emit('activeChange', 'rhythm')
|
|
emit('activeChange', 'rhythm')
|
|
}}
|
|
}}
|
|
vSlots={{
|
|
vSlots={{
|
|
|
|
+ icon: () => <span style={{ color: 'var(--van-primary-color)' }}>{record.value?.cadence}分</span>,
|
|
text: () => <span class={['switch', { active: active.value === 'rhythm' }]}>节奏</span>,
|
|
text: () => <span class={['switch', { active: active.value === 'rhythm' }]}>节奏</span>,
|
|
- icon: () => <span style={{ color: '#FF4E19' }}>{record.value?.cadence}分</span>,
|
|
|
|
}}
|
|
}}
|
|
/>
|
|
/>
|
|
<GridItem
|
|
<GridItem
|
|
@@ -141,8 +141,8 @@ export default defineComponent({
|
|
emit('activeChange', 'completion')
|
|
emit('activeChange', 'completion')
|
|
}}
|
|
}}
|
|
vSlots={{
|
|
vSlots={{
|
|
- text: () => <span class={['switch', { active: active.value === 'completion' }]}>时值</span>,
|
|
|
|
- icon: () => <span style={{ color: '#FFC459' }}>{record.value?.integrity}分</span>,
|
|
|
|
|
|
+ icon: () => <span style={{ color: '#4EA1FF' }}>{record.value?.integrity}分</span>,
|
|
|
|
+ text: () => <span class={['switch', { active: active.value === 'completion' }]}>完成度</span>,
|
|
}}
|
|
}}
|
|
/>
|
|
/>
|
|
</Grid>
|
|
</Grid>
|
|
@@ -152,8 +152,8 @@ export default defineComponent({
|
|
<PlayerPopup {...record.value} btnClass={detailStyles.btn} popupClass={detailStyles.popup}>
|
|
<PlayerPopup {...record.value} btnClass={detailStyles.btn} popupClass={detailStyles.popup}>
|
|
<GridItem
|
|
<GridItem
|
|
vSlots={{
|
|
vSlots={{
|
|
- text: () => <span>回放</span>,
|
|
|
|
icon: () => <img src={ReplayIcon} />,
|
|
icon: () => <img src={ReplayIcon} />,
|
|
|
|
+ text: () => <span>回放</span>,
|
|
}}
|
|
}}
|
|
/>
|
|
/>
|
|
</PlayerPopup>
|
|
</PlayerPopup>
|
|
@@ -161,16 +161,16 @@ export default defineComponent({
|
|
<GridItem
|
|
<GridItem
|
|
onClick={() => (visible.value = true)}
|
|
onClick={() => (visible.value = true)}
|
|
vSlots={{
|
|
vSlots={{
|
|
- text: () => <span>释义</span>,
|
|
|
|
icon: () => <img src={ExplainIcon} />,
|
|
icon: () => <img src={ExplainIcon} />,
|
|
|
|
+ text: () => <span>释义</span>,
|
|
}}
|
|
}}
|
|
/>
|
|
/>
|
|
{search.source !== 'web' ? (
|
|
{search.source !== 'web' ? (
|
|
<GridItem
|
|
<GridItem
|
|
onClick={again}
|
|
onClick={again}
|
|
vSlots={{
|
|
vSlots={{
|
|
- text: () => <span>再来一遍</span>,
|
|
|
|
icon: () => <img src={AgainIcon} />,
|
|
icon: () => <img src={AgainIcon} />,
|
|
|
|
+ text: () => <span>再来一遍</span>,
|
|
}}
|
|
}}
|
|
/>
|
|
/>
|
|
) : null}
|
|
) : null}
|