|
@@ -176,7 +176,7 @@ export default defineComponent({
|
|
|
// console.log("🚀 ~ resultData:", resultData);
|
|
|
// @ts-ignore
|
|
|
// resultData.musicalNotesPlayStats?.notesData.forEach((item) => item.rhythmicAssessment.result = 'EARLY')
|
|
|
- console.log('结果11')
|
|
|
+ console.log('结果11',resultData)
|
|
|
detailData.musicalNotesPlayStats = resultData.musicalNotesPlayStats?.notesData || [];
|
|
|
detailData.userMeasureScore = resultData.userMeasureScore || {};
|
|
|
|
|
@@ -276,7 +276,11 @@ export default defineComponent({
|
|
|
const stemEl = document.getElementById("vf-" + active.id + "-stem");
|
|
|
let errType = scoreData.itemType === "cadence" ? note.rhythmicAssessment.result : note.pitchAssessment.result;
|
|
|
// console.log(1111222,errType)
|
|
|
- const isNeedCopyElement = scoreData.itemType === "integrity" ? false : ["HIGH", "LOW", "EARLY", "LATE"].includes(errType);
|
|
|
+ /**
|
|
|
+ * 新版小酷AI不需要在当前的音符复制出来一个音符,所以注释掉isNeedCopyElement和copySvg
|
|
|
+ */
|
|
|
+ // const isNeedCopyElement = scoreData.itemType === "integrity" ? false : ["HIGH", "LOW", "EARLY", "LATE"].includes(errType);
|
|
|
+ const isNeedCopyElement = false;
|
|
|
if (scoreData.itemType === "integrity") {
|
|
|
errType = errType = note.pitchAssessment.result === "HIGH" || note.pitchAssessment.result === "LOW" || note.pitchAssessment.result === "WRONG" ? "RIGHT" : errType;
|
|
|
}
|
|
@@ -299,14 +303,14 @@ export default defineComponent({
|
|
|
if (scoreData.musicType === "staff") {
|
|
|
stemEl?.classList.add(colorsClass.RIGHT);
|
|
|
svgEl?.classList.add(colorsClass.RIGHT);
|
|
|
- copySvg = svgEl.querySelector(".vf-notehead")!.cloneNode(true) as SVGSVGElement;
|
|
|
+ // copySvg = svgEl.querySelector(".vf-notehead")!.cloneNode(true) as SVGSVGElement;
|
|
|
} else {
|
|
|
//copySvg = svgEl.querySelector('.vf-numbered-note-head')!.cloneNode(true) as SVGSVGElement
|
|
|
|
|
|
if (isNeedCopyElement) {
|
|
|
svgEl?.classList.add(styles.inaccuracy);
|
|
|
const targetId = errType === "HIGH" ? "topSvg" : errType === "LOW" ? "bottomSvg" : errType === "EARLY" ? "leftSvg" : errType === "LATE" ? "rightSvg" : "";
|
|
|
- copySvg = document.getElementById(targetId)!.cloneNode(true) as SVGSVGElement;
|
|
|
+ // copySvg = document.getElementById(targetId)!.cloneNode(true) as SVGSVGElement;
|
|
|
const { width, height } = svgEl.getBoundingClientRect() || {};
|
|
|
// @ts-ignore
|
|
|
let { x, y } = svgEl?.getBBox() || {};
|
|
@@ -326,18 +330,15 @@ export default defineComponent({
|
|
|
// svgEl.prepend(rect);
|
|
|
}
|
|
|
if (scoreData.musicType === "staff") {
|
|
|
- copySvg.style.transform = getOffsetPosition(errType);
|
|
|
- //svgEl.style.opacity = '.7'
|
|
|
+ // copySvg.style.transform = getOffsetPosition(errType);
|
|
|
if (stemEl) {
|
|
|
- //stemEl.style.opacity = '.7'
|
|
|
+ //
|
|
|
}
|
|
|
}
|
|
|
- copySvg.id = "vf-" + active.id + "-copy";
|
|
|
- copySvg?.classList.add(colorsClass[errType]);
|
|
|
- // stemEl?.classList.add(colorsClass.RIGHT)
|
|
|
+ // copySvg.id = "vf-" + active.id + "-copy";
|
|
|
+ // copySvg?.classList.add(colorsClass[errType]);
|
|
|
// @ts-ignore
|
|
|
- state.osmd?.container.querySelector("svg")!.insertAdjacentElement("afterbegin", copySvg);
|
|
|
- // svgEl?.parentElement?.appendChild(copySvg)
|
|
|
+ // state.osmd?.container.querySelector("svg")!.insertAdjacentElement("afterbegin", copySvg);
|
|
|
}
|
|
|
}, 300);
|
|
|
}
|