|
@@ -182,6 +182,7 @@ export const createMeasure = (): IMeasure => {
|
|
|
/** 生成小节 */
|
|
|
export const renderMeasures = (abc: IAbc) => {
|
|
|
// console.log("🚀 ~ abc:", abc)
|
|
|
+ let wrap = 1;
|
|
|
let text = `X:1\n`;
|
|
|
|
|
|
abc.title && (text += abc.title + "\n");
|
|
@@ -232,6 +233,10 @@ export const renderMeasures = (abc: IAbc) => {
|
|
|
}
|
|
|
let _i = i + 1;
|
|
|
text += `"<${_i}"${ measure.barline}`;
|
|
|
+ if (wrap % 4 === 0) {
|
|
|
+ text += "\n";
|
|
|
+ }
|
|
|
+ wrap++;
|
|
|
}
|
|
|
// console.log(text)
|
|
|
return text;
|