|
@@ -14,24 +14,24 @@ export default defineComponent({
|
|
|
const autoProduct = (val: any) => {
|
|
|
if (search.modeType === 'json') return
|
|
|
console.log(musicData.rended, '渲染是否结束')
|
|
|
- // if (!musicData.svg){
|
|
|
- // musicData.svg = document.getElementById('osmdSvgPage1')?.outerHTML || '';
|
|
|
- // }
|
|
|
- // if (!musicData.svg) {
|
|
|
- // return
|
|
|
- // }
|
|
|
- // if (SettingState.sett.type === 'staff') {
|
|
|
- // if (!detailState.activeDetail?.musicSvg) {
|
|
|
- // handleSave(false)
|
|
|
- // }
|
|
|
- // } else {
|
|
|
- // if (
|
|
|
- // (SettingState.sett.keySignature && !detailState.activeDetail?.musicFirstSvg) ||
|
|
|
- // (!SettingState.sett.keySignature && !detailState.activeDetail?.musicJianSvg)
|
|
|
- // ) {
|
|
|
- // handleSave(false)
|
|
|
- // }
|
|
|
- // }
|
|
|
+ if (!musicData.svg){
|
|
|
+ musicData.svg = document.getElementById('osmdSvgPage1')?.outerHTML || '';
|
|
|
+ }
|
|
|
+ if (!musicData.svg) {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (SettingState.sett.type === 'staff') {
|
|
|
+ if (!detailState.activeDetail?.musicSvg) {
|
|
|
+ handleSave(false)
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ if (
|
|
|
+ (SettingState.sett.keySignature && !detailState.activeDetail?.musicFirstSvg) ||
|
|
|
+ (!SettingState.sett.keySignature && !detailState.activeDetail?.musicJianSvg)
|
|
|
+ ) {
|
|
|
+ handleSave(false)
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
expose({
|
|
|
autoProduct,
|