From 38af0469470a3e0c421dd4a9ac2c82f42edf4061 Mon Sep 17 00:00:00 2001 From: infojunkie Date: Fri, 12 Jan 2024 22:30:32 -0800 Subject: [PATCH] Add build --- lib/ireal-musicxml.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ireal-musicxml.js b/lib/ireal-musicxml.js index fd179d4..b936485 100644 --- a/lib/ireal-musicxml.js +++ b/lib/ireal-musicxml.js @@ -1,2 +1,2 @@ /*! For license information please see ireal-musicxml.js.LICENSE.txt */ -!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.iReal2MusicXML=e():t.iReal2MusicXML=e()}(this,(()=>(()=>{var t={272:(t,e,r)=>{"use strict";var n=r(723),o=[],i=[],a=n.makeRequestCallFromTimer((function(){if(i.length)throw i.shift()}));function u(t){var e;(e=o.length?o.pop():new s).task=t,n(e)}function s(){this.task=null}t.exports=u,s.prototype.call=function(){try{this.task.call()}catch(t){u.onerror?u.onerror(t):(i.push(t),a())}finally{this.task=null,o[o.length]=this}}},723:(t,e,r)=>{"use strict";function n(t){i.length||o(),i[i.length]=t}t.exports=n;var o,i=[],a=0;function u(){for(;a1024){for(var e=0,r=i.length-a;e{var t={8552:(t,e,r)=>{var n=r(852)(r(5639),"DataView");t.exports=n},1989:(t,e,r)=>{var n=r(1789),o=r(401),i=r(7667),a=r(1327),u=r(1866);function s(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e{var n=r(7040),o=r(4125),i=r(2117),a=r(7518),u=r(4705);function s(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e{var n=r(852)(r(5639),"Map");t.exports=n},3369:(t,e,r)=>{var n=r(4785),o=r(1285),i=r(6e3),a=r(9916),u=r(5265);function s(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e{var n=r(852)(r(5639),"Promise");t.exports=n},8525:(t,e,r)=>{var n=r(852)(r(5639),"Set");t.exports=n},8668:(t,e,r)=>{var n=r(3369),o=r(619),i=r(2385);function a(t){var e=-1,r=null==t?0:t.length;for(this.__data__=new n;++e{var n=r(8407),o=r(7465),i=r(3779),a=r(7599),u=r(4758),s=r(4309);function c(t){var e=this.__data__=new n(t);this.size=e.size}c.prototype.clear=o,c.prototype.delete=i,c.prototype.get=a,c.prototype.has=u,c.prototype.set=s,t.exports=c},2705:(t,e,r)=>{var n=r(5639).Symbol;t.exports=n},1149:(t,e,r)=>{var n=r(5639).Uint8Array;t.exports=n},577:(t,e,r)=>{var n=r(852)(r(5639),"WeakMap");t.exports=n},6874:t=>{t.exports=function(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}},7412:t=>{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length;++r{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length,o=0,i=[];++r{var n=r(2118);t.exports=function(t,e){return!(null==t||!t.length)&&n(t,e,0)>-1}},1196:t=>{t.exports=function(t,e,r){for(var n=-1,o=null==t?0:t.length;++n{var n=r(2545),o=r(5694),i=r(1469),a=r(4144),u=r(5776),s=r(6719),c=Object.prototype.hasOwnProperty;t.exports=function(t,e){var r=i(t),l=!r&&o(t),f=!r&&!l&&a(t),p=!r&&!l&&!f&&s(t),h=r||l||f||p,d=h?n(t.length,String):[],v=d.length;for(var b in t)!e&&!c.call(t,b)||h&&("length"==b||f&&("offset"==b||"parent"==b)||p&&("buffer"==b||"byteLength"==b||"byteOffset"==b)||u(b,v))||d.push(b);return d}},9932:t=>{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length,o=Array(n);++r{t.exports=function(t,e){for(var r=-1,n=e.length,o=t.length;++r{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length;++r{var n=r(9465),o=r(7813),i=Object.prototype.hasOwnProperty;t.exports=function(t,e,r){var a=t[e];i.call(t,e)&&o(a,r)&&(void 0!==r||e in t)||n(t,e,r)}},8470:(t,e,r)=>{var n=r(7813);t.exports=function(t,e){for(var r=t.length;r--;)if(n(t[r][0],e))return r;return-1}},4037:(t,e,r)=>{var n=r(8363),o=r(3674);t.exports=function(t,e){return t&&n(e,o(e),t)}},3886:(t,e,r)=>{var n=r(8363),o=r(1704);t.exports=function(t,e){return t&&n(e,o(e),t)}},9465:(t,e,r)=>{var n=r(8777);t.exports=function(t,e,r){"__proto__"==e&&n?n(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}},5990:(t,e,r)=>{var n=r(6384),o=r(7412),i=r(4865),a=r(4037),u=r(3886),s=r(4626),c=r(278),l=r(8805),f=r(1911),p=r(8234),h=r(6904),d=r(4160),v=r(3824),b=r(9148),m=r(8517),y=r(1469),g=r(4144),_=r(6688),j=r(3218),w=r(2928),x=r(3674),O=r(1704),S="[object Arguments]",A="[object Function]",E="[object Object]",k={};k[S]=k["[object Array]"]=k["[object ArrayBuffer]"]=k["[object DataView]"]=k["[object Boolean]"]=k["[object Date]"]=k["[object Float32Array]"]=k["[object Float64Array]"]=k["[object Int8Array]"]=k["[object Int16Array]"]=k["[object Int32Array]"]=k["[object Map]"]=k["[object Number]"]=k[E]=k["[object RegExp]"]=k["[object Set]"]=k["[object String]"]=k["[object Symbol]"]=k["[object Uint8Array]"]=k["[object Uint8ClampedArray]"]=k["[object Uint16Array]"]=k["[object Uint32Array]"]=!0,k["[object Error]"]=k[A]=k["[object WeakMap]"]=!1,t.exports=function t(e,r,D,C,P,z){var F,T=1&r,M=2&r,L=4&r;if(D&&(F=P?D(e,C,P,z):D(e)),void 0!==F)return F;if(!j(e))return e;var I=y(e);if(I){if(F=v(e),!T)return c(e,F)}else{var N=d(e),R=N==A||"[object GeneratorFunction]"==N;if(g(e))return s(e,T);if(N==E||N==S||R&&!P){if(F=M||R?{}:m(e),!T)return M?f(e,u(F,e)):l(e,a(F,e))}else{if(!k[N])return P?e:{};F=b(e,N,T)}}z||(z=new n);var q=z.get(e);if(q)return q;z.set(e,F),w(e)?e.forEach((function(n){F.add(t(n,r,D,n,e,z))})):_(e)&&e.forEach((function(n,o){F.set(o,t(n,r,D,o,e,z))}));var G=I?void 0:(L?M?h:p:M?O:x)(e);return o(G||e,(function(n,o){G&&(n=e[o=n]),i(F,o,t(n,r,D,o,e,z))})),F}},3118:(t,e,r)=>{var n=r(3218),o=Object.create,i=function(){function t(){}return function(e){if(!n(e))return{};if(o)return o(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}}();t.exports=i},731:(t,e,r)=>{var n=r(8668),o=r(7443),i=r(1196),a=r(9932),u=r(1717),s=r(4757);t.exports=function(t,e,r,c){var l=-1,f=o,p=!0,h=t.length,d=[],v=e.length;if(!h)return d;r&&(e=a(e,u(r))),c?(f=i,p=!1):e.length>=200&&(f=s,p=!1,e=new n(e));t:for(;++l{t.exports=function(t,e,r,n){for(var o=t.length,i=r+(n?1:-1);n?i--:++i{var n=r(2488),o=r(7285);t.exports=function t(e,r,i,a,u){var s=-1,c=e.length;for(i||(i=o),u||(u=[]);++s0&&i(l)?r>1?t(l,r-1,i,a,u):n(u,l):a||(u[u.length]=l)}return u}},8483:(t,e,r)=>{var n=r(5063)();t.exports=n},7816:(t,e,r)=>{var n=r(8483),o=r(3674);t.exports=function(t,e){return t&&n(t,e,o)}},7786:(t,e,r)=>{var n=r(1811),o=r(327);t.exports=function(t,e){for(var r=0,i=(e=n(e,t)).length;null!=t&&r{var n=r(2488),o=r(1469);t.exports=function(t,e,r){var i=e(t);return o(t)?i:n(i,r(t))}},4239:(t,e,r)=>{var n=r(2705),o=r(9607),i=r(2333),a=n?n.toStringTag:void 0;t.exports=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":a&&a in Object(t)?o(t):i(t)}},13:t=>{t.exports=function(t,e){return null!=t&&e in Object(t)}},2118:(t,e,r)=>{var n=r(1848),o=r(2722),i=r(2351);t.exports=function(t,e,r){return e==e?i(t,e,r):n(t,o,r)}},8975:(t,e,r)=>{var n=r(7816);t.exports=function(t,e,r,o){return n(t,(function(t,n,i){e(o,r(t),n,i)})),o}},9454:(t,e,r)=>{var n=r(4239),o=r(7005);t.exports=function(t){return o(t)&&"[object Arguments]"==n(t)}},939:(t,e,r)=>{var n=r(2492),o=r(7005);t.exports=function t(e,r,i,a,u){return e===r||(null==e||null==r||!o(e)&&!o(r)?e!=e&&r!=r:n(e,r,i,a,t,u))}},2492:(t,e,r)=>{var n=r(6384),o=r(7114),i=r(8351),a=r(6096),u=r(4160),s=r(1469),c=r(4144),l=r(6719),f="[object Arguments]",p="[object Array]",h="[object Object]",d=Object.prototype.hasOwnProperty;t.exports=function(t,e,r,v,b,m){var y=s(t),g=s(e),_=y?p:u(t),j=g?p:u(e),w=(_=_==f?h:_)==h,x=(j=j==f?h:j)==h,O=_==j;if(O&&c(t)){if(!c(e))return!1;y=!0,w=!1}if(O&&!w)return m||(m=new n),y||l(t)?o(t,e,r,v,b,m):i(t,e,_,r,v,b,m);if(!(1&r)){var S=w&&d.call(t,"__wrapped__"),A=x&&d.call(e,"__wrapped__");if(S||A){var E=S?t.value():t,k=A?e.value():e;return m||(m=new n),b(E,k,r,v,m)}}return!!O&&(m||(m=new n),a(t,e,r,v,b,m))}},5588:(t,e,r)=>{var n=r(4160),o=r(7005);t.exports=function(t){return o(t)&&"[object Map]"==n(t)}},2958:(t,e,r)=>{var n=r(6384),o=r(939);t.exports=function(t,e,r,i){var a=r.length,u=a,s=!i;if(null==t)return!u;for(t=Object(t);a--;){var c=r[a];if(s&&c[2]?c[1]!==t[c[0]]:!(c[0]in t))return!1}for(;++a{t.exports=function(t){return t!=t}},8458:(t,e,r)=>{var n=r(3560),o=r(5346),i=r(3218),a=r(346),u=/^\[object .+?Constructor\]$/,s=Function.prototype,c=Object.prototype,l=s.toString,f=c.hasOwnProperty,p=RegExp("^"+l.call(f).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");t.exports=function(t){return!(!i(t)||o(t))&&(n(t)?p:u).test(a(t))}},9221:(t,e,r)=>{var n=r(4160),o=r(7005);t.exports=function(t){return o(t)&&"[object Set]"==n(t)}},8749:(t,e,r)=>{var n=r(4239),o=r(1780),i=r(7005),a={};a["[object Float32Array]"]=a["[object Float64Array]"]=a["[object Int8Array]"]=a["[object Int16Array]"]=a["[object Int32Array]"]=a["[object Uint8Array]"]=a["[object Uint8ClampedArray]"]=a["[object Uint16Array]"]=a["[object Uint32Array]"]=!0,a["[object Arguments]"]=a["[object Array]"]=a["[object ArrayBuffer]"]=a["[object Boolean]"]=a["[object DataView]"]=a["[object Date]"]=a["[object Error]"]=a["[object Function]"]=a["[object Map]"]=a["[object Number]"]=a["[object Object]"]=a["[object RegExp]"]=a["[object Set]"]=a["[object String]"]=a["[object WeakMap]"]=!1,t.exports=function(t){return i(t)&&o(t.length)&&!!a[n(t)]}},7206:(t,e,r)=>{var n=r(1573),o=r(6432),i=r(6557),a=r(1469),u=r(9601);t.exports=function(t){return"function"==typeof t?t:null==t?i:"object"==typeof t?a(t)?o(t[0],t[1]):n(t):u(t)}},280:(t,e,r)=>{var n=r(5726),o=r(6916),i=Object.prototype.hasOwnProperty;t.exports=function(t){if(!n(t))return o(t);var e=[];for(var r in Object(t))i.call(t,r)&&"constructor"!=r&&e.push(r);return e}},313:(t,e,r)=>{var n=r(3218),o=r(5726),i=r(3498),a=Object.prototype.hasOwnProperty;t.exports=function(t){if(!n(t))return i(t);var e=o(t),r=[];for(var u in t)("constructor"!=u||!e&&a.call(t,u))&&r.push(u);return r}},1573:(t,e,r)=>{var n=r(2958),o=r(1499),i=r(2634);t.exports=function(t){var e=o(t);return 1==e.length&&e[0][2]?i(e[0][0],e[0][1]):function(r){return r===t||n(r,t,e)}}},6432:(t,e,r)=>{var n=r(939),o=r(7361),i=r(9095),a=r(5403),u=r(9162),s=r(2634),c=r(327);t.exports=function(t,e){return a(t)&&u(e)?s(c(t),e):function(r){var a=o(r,t);return void 0===a&&a===e?i(r,t):n(e,a,3)}}},371:t=>{t.exports=function(t){return function(e){return null==e?void 0:e[t]}}},9152:(t,e,r)=>{var n=r(7786);t.exports=function(t){return function(e){return n(e,t)}}},5976:(t,e,r)=>{var n=r(6557),o=r(5357),i=r(61);t.exports=function(t,e){return i(o(t,e,n),t+"")}},6560:(t,e,r)=>{var n=r(5703),o=r(8777),i=r(6557),a=o?function(t,e){return o(t,"toString",{configurable:!0,enumerable:!1,value:n(e),writable:!0})}:i;t.exports=a},2545:t=>{t.exports=function(t,e){for(var r=-1,n=Array(t);++r{var n=r(2705),o=r(9932),i=r(1469),a=r(3448),u=n?n.prototype:void 0,s=u?u.toString:void 0;t.exports=function t(e){if("string"==typeof e)return e;if(i(e))return o(e,t)+"";if(a(e))return s?s.call(e):"";var r=e+"";return"0"==r&&1/e==-1/0?"-0":r}},7561:(t,e,r)=>{var n=r(7990),o=/^\s+/;t.exports=function(t){return t?t.slice(0,n(t)+1).replace(o,""):t}},1717:t=>{t.exports=function(t){return function(e){return t(e)}}},5652:(t,e,r)=>{var n=r(8668),o=r(7443),i=r(1196),a=r(4757),u=r(3593),s=r(1814);t.exports=function(t,e,r){var c=-1,l=o,f=t.length,p=!0,h=[],d=h;if(r)p=!1,l=i;else if(f>=200){var v=e?null:u(t);if(v)return s(v);p=!1,l=a,d=new n}else d=e?[]:h;t:for(;++c{t.exports=function(t,e){return t.has(e)}},1811:(t,e,r)=>{var n=r(1469),o=r(5403),i=r(5514),a=r(9833);t.exports=function(t,e){return n(t)?t:o(t,e)?[t]:i(a(t))}},4318:(t,e,r)=>{var n=r(1149);t.exports=function(t){var e=new t.constructor(t.byteLength);return new n(e).set(new n(t)),e}},4626:(t,e,r)=>{t=r.nmd(t);var n=r(5639),o=e&&!e.nodeType&&e,i=o&&t&&!t.nodeType&&t,a=i&&i.exports===o?n.Buffer:void 0,u=a?a.allocUnsafe:void 0;t.exports=function(t,e){if(e)return t.slice();var r=t.length,n=u?u(r):new t.constructor(r);return t.copy(n),n}},7157:(t,e,r)=>{var n=r(4318);t.exports=function(t,e){var r=e?n(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}},3147:t=>{var e=/\w*$/;t.exports=function(t){var r=new t.constructor(t.source,e.exec(t));return r.lastIndex=t.lastIndex,r}},419:(t,e,r)=>{var n=r(2705),o=n?n.prototype:void 0,i=o?o.valueOf:void 0;t.exports=function(t){return i?Object(i.call(t)):{}}},7133:(t,e,r)=>{var n=r(4318);t.exports=function(t,e){var r=e?n(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}},278:t=>{t.exports=function(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r{var n=r(4865),o=r(9465);t.exports=function(t,e,r,i){var a=!r;r||(r={});for(var u=-1,s=e.length;++u{var n=r(8363),o=r(9551);t.exports=function(t,e){return n(t,o(t),e)}},1911:(t,e,r)=>{var n=r(8363),o=r(1442);t.exports=function(t,e){return n(t,o(t),e)}},4429:(t,e,r)=>{var n=r(5639)["__core-js_shared__"];t.exports=n},5063:t=>{t.exports=function(t){return function(e,r,n){for(var o=-1,i=Object(e),a=n(e),u=a.length;u--;){var s=a[t?u:++o];if(!1===r(i[s],s,i))break}return e}}},7740:(t,e,r)=>{var n=r(7206),o=r(8612),i=r(3674);t.exports=function(t){return function(e,r,a){var u=Object(e);if(!o(e)){var s=n(r,3);e=i(e),r=function(t){return s(u[t],t,u)}}var c=t(e,r,a);return c>-1?u[s?e[c]:c]:void 0}}},7779:(t,e,r)=>{var n=r(8975);t.exports=function(t,e){return function(r,o){return n(r,t,e(o),{})}}},3593:(t,e,r)=>{var n=r(8525),o=r(308),i=r(1814),a=n&&1/i(new n([,-0]))[1]==1/0?function(t){return new n(t)}:o;t.exports=a},8777:(t,e,r)=>{var n=r(852),o=function(){try{var t=n(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();t.exports=o},7114:(t,e,r)=>{var n=r(8668),o=r(2908),i=r(4757);t.exports=function(t,e,r,a,u,s){var c=1&r,l=t.length,f=e.length;if(l!=f&&!(c&&f>l))return!1;var p=s.get(t),h=s.get(e);if(p&&h)return p==e&&h==t;var d=-1,v=!0,b=2&r?new n:void 0;for(s.set(t,e),s.set(e,t);++d{var n=r(2705),o=r(1149),i=r(7813),a=r(7114),u=r(8776),s=r(1814),c=n?n.prototype:void 0,l=c?c.valueOf:void 0;t.exports=function(t,e,r,n,c,f,p){switch(r){case"[object DataView]":if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case"[object ArrayBuffer]":return!(t.byteLength!=e.byteLength||!f(new o(t),new o(e)));case"[object Boolean]":case"[object Date]":case"[object Number]":return i(+t,+e);case"[object Error]":return t.name==e.name&&t.message==e.message;case"[object RegExp]":case"[object String]":return t==e+"";case"[object Map]":var h=u;case"[object Set]":var d=1&n;if(h||(h=s),t.size!=e.size&&!d)return!1;var v=p.get(t);if(v)return v==e;n|=2,p.set(t,e);var b=a(h(t),h(e),n,c,f,p);return p.delete(t),b;case"[object Symbol]":if(l)return l.call(t)==l.call(e)}return!1}},6096:(t,e,r)=>{var n=r(8234),o=Object.prototype.hasOwnProperty;t.exports=function(t,e,r,i,a,u){var s=1&r,c=n(t),l=c.length;if(l!=n(e).length&&!s)return!1;for(var f=l;f--;){var p=c[f];if(!(s?p in e:o.call(e,p)))return!1}var h=u.get(t),d=u.get(e);if(h&&d)return h==e&&d==t;var v=!0;u.set(t,e),u.set(e,t);for(var b=s;++f{var n="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g;t.exports=n},8234:(t,e,r)=>{var n=r(8866),o=r(9551),i=r(3674);t.exports=function(t){return n(t,i,o)}},6904:(t,e,r)=>{var n=r(8866),o=r(1442),i=r(1704);t.exports=function(t){return n(t,i,o)}},5050:(t,e,r)=>{var n=r(7019);t.exports=function(t,e){var r=t.__data__;return n(e)?r["string"==typeof e?"string":"hash"]:r.map}},1499:(t,e,r)=>{var n=r(9162),o=r(3674);t.exports=function(t){for(var e=o(t),r=e.length;r--;){var i=e[r],a=t[i];e[r]=[i,a,n(a)]}return e}},852:(t,e,r)=>{var n=r(8458),o=r(7801);t.exports=function(t,e){var r=o(t,e);return n(r)?r:void 0}},5924:(t,e,r)=>{var n=r(5569)(Object.getPrototypeOf,Object);t.exports=n},9607:(t,e,r)=>{var n=r(2705),o=Object.prototype,i=o.hasOwnProperty,a=o.toString,u=n?n.toStringTag:void 0;t.exports=function(t){var e=i.call(t,u),r=t[u];try{t[u]=void 0;var n=!0}catch(t){}var o=a.call(t);return n&&(e?t[u]=r:delete t[u]),o}},9551:(t,e,r)=>{var n=r(4963),o=r(479),i=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols,u=a?function(t){return null==t?[]:(t=Object(t),n(a(t),(function(e){return i.call(t,e)})))}:o;t.exports=u},1442:(t,e,r)=>{var n=r(2488),o=r(5924),i=r(9551),a=r(479),u=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)n(e,i(t)),t=o(t);return e}:a;t.exports=u},4160:(t,e,r)=>{var n=r(8552),o=r(7071),i=r(3818),a=r(8525),u=r(577),s=r(4239),c=r(346),l="[object Map]",f="[object Promise]",p="[object Set]",h="[object WeakMap]",d="[object DataView]",v=c(n),b=c(o),m=c(i),y=c(a),g=c(u),_=s;(n&&_(new n(new ArrayBuffer(1)))!=d||o&&_(new o)!=l||i&&_(i.resolve())!=f||a&&_(new a)!=p||u&&_(new u)!=h)&&(_=function(t){var e=s(t),r="[object Object]"==e?t.constructor:void 0,n=r?c(r):"";if(n)switch(n){case v:return d;case b:return l;case m:return f;case y:return p;case g:return h}return e}),t.exports=_},7801:t=>{t.exports=function(t,e){return null==t?void 0:t[e]}},222:(t,e,r)=>{var n=r(1811),o=r(5694),i=r(1469),a=r(5776),u=r(1780),s=r(327);t.exports=function(t,e,r){for(var c=-1,l=(e=n(e,t)).length,f=!1;++c{var n=r(4536);t.exports=function(){this.__data__=n?n(null):{},this.size=0}},401:t=>{t.exports=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}},7667:(t,e,r)=>{var n=r(4536),o=Object.prototype.hasOwnProperty;t.exports=function(t){var e=this.__data__;if(n){var r=e[t];return"__lodash_hash_undefined__"===r?void 0:r}return o.call(e,t)?e[t]:void 0}},1327:(t,e,r)=>{var n=r(4536),o=Object.prototype.hasOwnProperty;t.exports=function(t){var e=this.__data__;return n?void 0!==e[t]:o.call(e,t)}},1866:(t,e,r)=>{var n=r(4536);t.exports=function(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=n&&void 0===e?"__lodash_hash_undefined__":e,this}},3824:t=>{var e=Object.prototype.hasOwnProperty;t.exports=function(t){var r=t.length,n=new t.constructor(r);return r&&"string"==typeof t[0]&&e.call(t,"index")&&(n.index=t.index,n.input=t.input),n}},9148:(t,e,r)=>{var n=r(4318),o=r(7157),i=r(3147),a=r(419),u=r(7133);t.exports=function(t,e,r){var s=t.constructor;switch(e){case"[object ArrayBuffer]":return n(t);case"[object Boolean]":case"[object Date]":return new s(+t);case"[object DataView]":return o(t,r);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return u(t,r);case"[object Map]":case"[object Set]":return new s;case"[object Number]":case"[object String]":return new s(t);case"[object RegExp]":return i(t);case"[object Symbol]":return a(t)}}},8517:(t,e,r)=>{var n=r(3118),o=r(5924),i=r(5726);t.exports=function(t){return"function"!=typeof t.constructor||i(t)?{}:n(o(t))}},7285:(t,e,r)=>{var n=r(2705),o=r(5694),i=r(1469),a=n?n.isConcatSpreadable:void 0;t.exports=function(t){return i(t)||o(t)||!!(a&&t&&t[a])}},5776:t=>{var e=/^(?:0|[1-9]\d*)$/;t.exports=function(t,r){var n=typeof t;return!!(r=null==r?9007199254740991:r)&&("number"==n||"symbol"!=n&&e.test(t))&&t>-1&&t%1==0&&t{var n=r(1469),o=r(3448),i=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;t.exports=function(t,e){if(n(t))return!1;var r=typeof t;return!("number"!=r&&"symbol"!=r&&"boolean"!=r&&null!=t&&!o(t))||a.test(t)||!i.test(t)||null!=e&&t in Object(e)}},7019:t=>{t.exports=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t}},5346:(t,e,r)=>{var n,o=r(4429),i=(n=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"";t.exports=function(t){return!!i&&i in t}},5726:t=>{var e=Object.prototype;t.exports=function(t){var r=t&&t.constructor;return t===("function"==typeof r&&r.prototype||e)}},9162:(t,e,r)=>{var n=r(3218);t.exports=function(t){return t==t&&!n(t)}},7040:t=>{t.exports=function(){this.__data__=[],this.size=0}},4125:(t,e,r)=>{var n=r(8470),o=Array.prototype.splice;t.exports=function(t){var e=this.__data__,r=n(e,t);return!(r<0||(r==e.length-1?e.pop():o.call(e,r,1),--this.size,0))}},2117:(t,e,r)=>{var n=r(8470);t.exports=function(t){var e=this.__data__,r=n(e,t);return r<0?void 0:e[r][1]}},7518:(t,e,r)=>{var n=r(8470);t.exports=function(t){return n(this.__data__,t)>-1}},4705:(t,e,r)=>{var n=r(8470);t.exports=function(t,e){var r=this.__data__,o=n(r,t);return o<0?(++this.size,r.push([t,e])):r[o][1]=e,this}},4785:(t,e,r)=>{var n=r(1989),o=r(8407),i=r(7071);t.exports=function(){this.size=0,this.__data__={hash:new n,map:new(i||o),string:new n}}},1285:(t,e,r)=>{var n=r(5050);t.exports=function(t){var e=n(this,t).delete(t);return this.size-=e?1:0,e}},6e3:(t,e,r)=>{var n=r(5050);t.exports=function(t){return n(this,t).get(t)}},9916:(t,e,r)=>{var n=r(5050);t.exports=function(t){return n(this,t).has(t)}},5265:(t,e,r)=>{var n=r(5050);t.exports=function(t,e){var r=n(this,t),o=r.size;return r.set(t,e),this.size+=r.size==o?0:1,this}},8776:t=>{t.exports=function(t){var e=-1,r=Array(t.size);return t.forEach((function(t,n){r[++e]=[n,t]})),r}},2634:t=>{t.exports=function(t,e){return function(r){return null!=r&&r[t]===e&&(void 0!==e||t in Object(r))}}},4523:(t,e,r)=>{var n=r(8306);t.exports=function(t){var e=n(t,(function(t){return 500===r.size&&r.clear(),t})),r=e.cache;return e}},4536:(t,e,r)=>{var n=r(852)(Object,"create");t.exports=n},6916:(t,e,r)=>{var n=r(5569)(Object.keys,Object);t.exports=n},3498:t=>{t.exports=function(t){var e=[];if(null!=t)for(var r in Object(t))e.push(r);return e}},1167:(t,e,r)=>{t=r.nmd(t);var n=r(1957),o=e&&!e.nodeType&&e,i=o&&t&&!t.nodeType&&t,a=i&&i.exports===o&&n.process,u=function(){try{return i&&i.require&&i.require("util").types||a&&a.binding&&a.binding("util")}catch(t){}}();t.exports=u},2333:t=>{var e=Object.prototype.toString;t.exports=function(t){return e.call(t)}},5569:t=>{t.exports=function(t,e){return function(r){return t(e(r))}}},5357:(t,e,r)=>{var n=r(6874),o=Math.max;t.exports=function(t,e,r){return e=o(void 0===e?t.length-1:e,0),function(){for(var i=arguments,a=-1,u=o(i.length-e,0),s=Array(u);++a{var n=r(1957),o="object"==typeof self&&self&&self.Object===Object&&self,i=n||o||Function("return this")();t.exports=i},619:t=>{t.exports=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this}},2385:t=>{t.exports=function(t){return this.__data__.has(t)}},1814:t=>{t.exports=function(t){var e=-1,r=Array(t.size);return t.forEach((function(t){r[++e]=t})),r}},61:(t,e,r)=>{var n=r(6560),o=r(1275)(n);t.exports=o},1275:t=>{var e=Date.now;t.exports=function(t){var r=0,n=0;return function(){var o=e(),i=16-(o-n);if(n=o,i>0){if(++r>=800)return arguments[0]}else r=0;return t.apply(void 0,arguments)}}},7465:(t,e,r)=>{var n=r(8407);t.exports=function(){this.__data__=new n,this.size=0}},3779:t=>{t.exports=function(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}},7599:t=>{t.exports=function(t){return this.__data__.get(t)}},4758:t=>{t.exports=function(t){return this.__data__.has(t)}},4309:(t,e,r)=>{var n=r(8407),o=r(7071),i=r(3369);t.exports=function(t,e){var r=this.__data__;if(r instanceof n){var a=r.__data__;if(!o||a.length<199)return a.push([t,e]),this.size=++r.size,this;r=this.__data__=new i(a)}return r.set(t,e),this.size=r.size,this}},2351:t=>{t.exports=function(t,e,r){for(var n=r-1,o=t.length;++n{var n=r(4523),o=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,i=/\\(\\)?/g,a=n((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(o,(function(t,r,n,o){e.push(n?o.replace(i,"$1"):r||t)})),e}));t.exports=a},327:(t,e,r)=>{var n=r(3448);t.exports=function(t){if("string"==typeof t||n(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}},346:t=>{var e=Function.prototype.toString;t.exports=function(t){if(null!=t){try{return e.call(t)}catch(t){}try{return t+""}catch(t){}}return""}},7990:t=>{var e=/\s/;t.exports=function(t){for(var r=t.length;r--&&e.test(t.charAt(r)););return r}},6678:(t,e,r)=>{var n=r(5990);t.exports=function(t){return n(t,4)}},361:(t,e,r)=>{var n=r(5990);t.exports=function(t){return n(t,5)}},5703:t=>{t.exports=function(t){return function(){return t}}},1966:(t,e,r)=>{var n=r(731),o=r(1078),i=r(5976),a=r(9246),u=i((function(t,e){return a(t)?n(t,o(e,1,a,!0)):[]}));t.exports=u},7813:t=>{t.exports=function(t,e){return t===e||t!=t&&e!=e}},3311:(t,e,r)=>{var n=r(7740)(r(998));t.exports=n},998:(t,e,r)=>{var n=r(1848),o=r(7206),i=r(554),a=Math.max;t.exports=function(t,e,r){var u=null==t?0:t.length;if(!u)return-1;var s=null==r?0:i(r);return s<0&&(s=a(u+s,0)),n(t,o(e,3),s)}},7361:(t,e,r)=>{var n=r(7786);t.exports=function(t,e,r){var o=null==t?void 0:n(t,e);return void 0===o?r:o}},9095:(t,e,r)=>{var n=r(13),o=r(222);t.exports=function(t,e){return null!=t&&o(t,e,n)}},6557:t=>{t.exports=function(t){return t}},3137:(t,e,r)=>{var n=r(5703),o=r(7779),i=r(6557),a=Object.prototype.toString,u=o((function(t,e,r){null!=e&&"function"!=typeof e.toString&&(e=a.call(e)),t[e]=r}),n(i));t.exports=u},5694:(t,e,r)=>{var n=r(9454),o=r(7005),i=Object.prototype,a=i.hasOwnProperty,u=i.propertyIsEnumerable,s=n(function(){return arguments}())?n:function(t){return o(t)&&a.call(t,"callee")&&!u.call(t,"callee")};t.exports=s},1469:t=>{var e=Array.isArray;t.exports=e},8612:(t,e,r)=>{var n=r(3560),o=r(1780);t.exports=function(t){return null!=t&&o(t.length)&&!n(t)}},9246:(t,e,r)=>{var n=r(8612),o=r(7005);t.exports=function(t){return o(t)&&n(t)}},4144:(t,e,r)=>{t=r.nmd(t);var n=r(5639),o=r(5062),i=e&&!e.nodeType&&e,a=i&&t&&!t.nodeType&&t,u=a&&a.exports===i?n.Buffer:void 0,s=(u?u.isBuffer:void 0)||o;t.exports=s},8446:(t,e,r)=>{var n=r(939);t.exports=function(t,e){return n(t,e)}},3560:(t,e,r)=>{var n=r(4239),o=r(3218);t.exports=function(t){if(!o(t))return!1;var e=n(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}},1780:t=>{t.exports=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}},6688:(t,e,r)=>{var n=r(5588),o=r(1717),i=r(1167),a=i&&i.isMap,u=a?o(a):n;t.exports=u},3218:t=>{t.exports=function(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}},7005:t=>{t.exports=function(t){return null!=t&&"object"==typeof t}},2928:(t,e,r)=>{var n=r(9221),o=r(1717),i=r(1167),a=i&&i.isSet,u=a?o(a):n;t.exports=u},3448:(t,e,r)=>{var n=r(4239),o=r(7005);t.exports=function(t){return"symbol"==typeof t||o(t)&&"[object Symbol]"==n(t)}},6719:(t,e,r)=>{var n=r(8749),o=r(1717),i=r(1167),a=i&&i.isTypedArray,u=a?o(a):n;t.exports=u},3674:(t,e,r)=>{var n=r(4636),o=r(280),i=r(8612);t.exports=function(t){return i(t)?n(t):o(t)}},1704:(t,e,r)=>{var n=r(4636),o=r(313),i=r(8612);t.exports=function(t){return i(t)?n(t,!0):o(t)}},8306:(t,e,r)=>{var n=r(3369);function o(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var r=function(){var n=arguments,o=e?e.apply(this,n):n[0],i=r.cache;if(i.has(o))return i.get(o);var a=t.apply(this,n);return r.cache=i.set(o,a)||i,a};return r.cache=new(o.Cache||n),r}o.Cache=n,t.exports=o},308:t=>{t.exports=function(){}},9601:(t,e,r)=>{var n=r(371),o=r(9152),i=r(5403),a=r(327);t.exports=function(t){return i(t)?n(a(t)):o(t)}},479:t=>{t.exports=function(){return[]}},5062:t=>{t.exports=function(){return!1}},8601:(t,e,r)=>{var n=r(4841);t.exports=function(t){return t?Infinity===(t=n(t))||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}},554:(t,e,r)=>{var n=r(8601);t.exports=function(t){var e=n(t),r=e%1;return e==e?r?e-r:e:0}},4841:(t,e,r)=>{var n=r(7561),o=r(3218),i=r(3448),a=/^[-+]0x[0-9a-f]+$/i,u=/^0b[01]+$/i,s=/^0o[0-7]+$/i,c=parseInt;t.exports=function(t){if("number"==typeof t)return t;if(i(t))return NaN;if(o(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=o(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=n(t);var r=u.test(t);return r||s.test(t)?c(t.slice(2),r?2:8):a.test(t)?NaN:+t}},9833:(t,e,r)=>{var n=r(531);t.exports=function(t){return null==t?"":n(t)}},4908:(t,e,r)=>{var n=r(5652);t.exports=function(t){return t&&t.length?n(t):[]}},2569:(t,e,r)=>{var n=r(731),o=r(5976),i=r(9246),a=o((function(t,e){return i(t)?n(t,e):[]}));t.exports=a}},e={};function r(n){var o=e[n];if(void 0!==o)return o.exports;var i=e[n]={id:n,loaded:!1,exports:{}};return t[n](i,i.exports,r),i.loaded=!0,i.exports}r.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return r.d(e,{a:e}),e},r.d=(t,e)=>{for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.nmd=t=>(t.paths=[],t.children||(t.children=[]),t);var n={};return(()=>{"use strict";function t(t,e){return t.reduce((function(t,e){return t?e(t):null}),e)}r.r(n),r.d(n,{chordParserFactory:()=>ke,chordRendererFactory:()=>nr});var e=r(361),o=r.n(e);const i=function(t){if(!Array.isArray(t))throw new TypeError("customFilters should be given as an array");if(t.some((function(t){return"function"!=typeof t})))throw new TypeError("The given filter is not a function");return!0};function a(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function u(t){for(var e=1;et.length)&&(e=t.length);for(var r=0,n=new Array(e);r0&&void 0!==arguments[0]?arguments[0]:{};return{input:{symbol:arguments.length>1?arguments[1]:void 0},normalized:{},formatted:{},parserConfiguration:o()(t)}}function Pt(t){return function(t){if(Array.isArray(t))return zt(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return zt(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?zt(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function zt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);rt.length)&&(e=t.length);for(var r=0,n=new Array(e);rt.length)&&(e=t.length);for(var r=0,n=new Array(e);r0)throw new J(t,a);return n}(e)),e.input.modifiers=r,e.normalized.intervals=function(t,e){return t.includes(ve.power)?["1","5"]:t.includes(ve.bass)?["1"]:$t()(["1"].concat(me(function(t){var e=[];return t.includes(ve.omit3)?[]:(it(t,[ve.sus,ve.sus2])||(we(t)?t.includes(ve.eleventh)||e.push("3"):e.push("b3")),t.includes(ve.add3)&&e.push("3"),e)}(t)),me(function(t){var e=[];return it(t,[ve.sus,ve.add4])&&e.push("4"),e}(t)),me(function(t,e){var r=[];return t.includes(ve.omit5)?[]:((it(t,[ve.dim,ve.halfDim,ve.fifthFlat])||je(t,e,"b5"))&&r.push("b5"),(it(t,[ve.aug,ve.fifthSharp])||je(t,e,"#5"))&&r.push("#5"),r.length||t.includes(ve.thirteenthFlat)||r.push("5"),r)}(t,e)),me(function(t){var e=[];return it(t,[ve.addb6])&&e.push("b6"),!it(t,[ve.add6,ve.add69])||xe(t)||it(t,[ve.halfDim])||e.push("6"),e}(t)),me(function(t){var e=[];return it(t,[ve.alt])&&e.push("b7"),it(t,[ve.seventh,ve.halfDim])?t.includes(ve.dim)?e.push("bb7"):t.includes(ve.halfDim)?e.push("b7"):e.push(_e(t)):it(t,[ve.ninth,ve.eleventh,ve.thirteenth])&&e.push(_e(t)),t.includes(ve.add7)&&e.push("7"),e}(t)),me(function(t,e){var r=[];return it(t,[ve.add69,ve.ninth,ve.eleventh,ve.thirteenth])&&ut(t,[ve.ninthFlat,ve.ninthSharp])&&r.push("9"),it(t,[ve.sus2,ve.add9])&&r.push("9"),(it(t,[ve.ninthFlat])||je(t,e,"b9"))&&r.push("b9"),(it(t,[ve.ninthSharp])||je(t,e,"#9"))&&r.push("#9"),r}(t,e)),me(function(t,e){var r=[];return(it(t,[ve.thirteenth])&&!we(t)||it(t,[ve.eleventh,ve.add11]))&&r.push("11"),(it(t,[ve.eleventhSharp])||je(t,e,"#11"))&&r.push("#11"),r}(t,e)),me(function(t,e){var r=[];return(it(t,[ve.add13,ve.thirteenth])||it(t,[ve.add6,ve.add69])&&xe(t)||it(t,[ve.add6,ve.add69])&&it(t,[ve.halfDim]))&&r.push("13"),(it(t,[ve.thirteenthFlat])||je(t,e,"b13"))&&r.push("b13"),r}(t,e)))).sort((function(t,e){return be[t]-be[e]}))}(r,t),e.normalized.semitones=e.normalized.intervals.map((function(t){return be[t]})).sort((function(t,e){return t-e})),e.normalized.intents=function(t){return{major:we(t),eleventh:t.includes(ve.eleventh),alt:t.includes(ve.alt)}}(r),e}function _e(t){return t.includes(ve.ma)?"7":"b7"}function je(t,e,r){return t.includes(ve.alt)&&e.includes(r)}function we(t){return ut(t,[ve.mi,ve.dim,ve.dim7,ve.halfDim])}function xe(t){return it(t,[ve.seventh,ve.ninth,ve.eleventh,ve.thirteenth])}function Oe(t){return t.replace(/[.\-*+?^${}()|[\]\\]/g,"\\$&")}function Se(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r0&&void 0!==arguments[0]?arguments[0]:{},r=["b5","#5","b9","#9","#11","b13"],n=["english","german","latin"],a=e.notationSystems,u=void 0===a?o()(n):a,s=e.altIntervals,c=void 0===s?o()(r):s,l=e.customFilters,f=void 0===l?[]:l;return function(t,e){Ae("altIntervals",t,e,!0)}(c,r),function(t,e){Ae("notationSystems",t,e)}(u,n),i(f),function(r){var n,i=[];if(!("string"==typeof(n=r)&&n.length>0)){var a=new K;i.push(Ee(a))}var s,l,p,h,d,v=o()(L).filter((function(t){return u.includes(t.name)}));if(!i.length)for(;v.length&&!s;){p=v.shift(),l=[Ct.bind(null,e),oe.bind(null,p.notes),St,ge.bind(null,c),lt,Nt,Jt,jt,ft,It].concat(function(t){if(Array.isArray(t))return Se(t)}(d=f)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(d)||function(t,e){if(t){if("string"==typeof t)return Se(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Se(t,e):void 0}}(d)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}());try{(s=t(l,r))?s.input.notationSystem=p.name:i.push((h=p.name,Ee(new Z,h)))}catch(a){i.push(Ee(a,p.name))}}return s||{error:i}}};function De(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Ce(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:"none",r=arguments.length>1?arguments[1]:void 0;if("none"===e)return r;var n=Be()(r.normalized.intervals,{max:["4","b5","#5","6","bb7","b7","7","b9","9","#9","11","#11","b13","13"],core:["4","b9","9","#9","11","#11","b13","13"]}[e]);return ut(n,["b3","3"])&&n.push(r.normalized.intents.major?"3":"b3"),ut(n,["b5","5","#5"])&&n.push("5"),r.normalized.intervals=n,r.normalized.semitones=n.map((function(t){return be[t]})),r.normalized.intents.eleventh=!1,r.normalized.intents.alt=!1,"max"===e&&delete r.normalized.bassNote,t([Jt,jt,It],r)}var $e=r(3137),We=["C","C#","D","D#","E","F","F#","G","G#","A","A#","B"],Xe={"C#":"Db","D#":"Eb","F#":"Gb","G#":"Ab","A#":"Bb"},Ve=r.n($e)()(Xe);function Ke(t,e,r){var n=r.normalized,o=n.rootNote,i=n.bassNote,a=Ye(o);if(r.normalized.rootNote=Ze(a,t,e),r.formatted.rootNote=r.normalized.rootNote,i){var u=Ye(i);r.normalized.bassNote=Ze(u,t,e),r.formatted.bassNote=r.normalized.bassNote}return It(r)}function Ze(t,e,r){var n=We.indexOf(t)+e,o=Math.floor(n/12),i=We[n-12*o];return r&&Xe[i]||i}function Ye(t){return Ve[t]||t}var He={german:{Ab:"As",A:"A","A#":"Ais",Bb:"Hes",B:"H",C:"C","C#":"Cis",Db:"Des",D:"D","D#":"Dis",Eb:"Es",E:"E",F:"F","F#":"Fis",Gb:"Ges",G:"G","G#":"Gis"},latin:{Ab:"Lab",A:"La","A#":"La#",Bb:"Sib",B:"Si",C:"Do","C#":"Do#",Db:"Reb",D:"Re","D#":"Re#",Eb:"Mib",E:"Mi",F:"Fa","F#":"Fa#",Gb:"Solb",G:"Sol","G#":"Sol#"}},Je=Object.keys(He);function Qe(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"english",e=arguments.length>1?arguments[1]:void 0,r="auto"===t?e.input.notationSystem:t;return"english"===r?e:Je.includes(r)?(e.formatted.rootNote=He[r][e.formatted.rootNote],e.formatted.bassNote&&(e.formatted.bassNote=He[r][e.formatted.bassNote]),e):null}function tr(t){return t&&t.formatted&&t.formatted.symbol?t.formatted.symbol:null}function er(t){return er="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},er(t)}function rr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r0&&void 0!==arguments[0]?arguments[0]:{},r=e.useShortNamings,n=void 0!==r&&r,a=e.simplify,u=void 0===a?"none":a,s=e.transposeValue,c=void 0===s?0:s,l=e.harmonizeAccidentals,f=void 0!==l&&l,p=e.useFlats,h=void 0!==p&&p,d=e.printer,v=void 0===d?"text":d,b=e.notationSystem,m=void 0===b?"english":b,y=e.customFilters,g=void 0===y?[]:y;i(g);var _,j=[];return["max","core"].includes(u)&&j.push(Ue.bind(null,u)),(f||0!==c)&&j.push(Ke.bind(null,c,h)),n&&j.push(qe),j.push.apply(j,[Qe.bind(null,m),ft].concat(function(t){if(Array.isArray(t))return rr(t)}(_=g)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(_)||function(t,e){if(t){if("string"==typeof t)return rr(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?rr(t,e):void 0}}(_)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())),function(e){if(!function(t){return t&&"object"===er(t)&&!t.error&&t.input}(e))return null;var r=t(j,o()(e));return"raw"===v?function(t){delete t.parserConfiguration.notationSystems;var e=o()(t),r=tr(t),n=ke(t.parserConfiguration)(r);return e.input=n.input,e}(r):tr(r)}}})(),n})()},t.exports=e()},529:t=>{var e=-1,r=1,n=0;function o(t,v,b,m,y){if(t===v)return t?[[n,t]]:[];if(null!=b){var _=function(t,e,r){var n="number"==typeof r?{index:r,length:0}:r.oldRange,o="number"==typeof r?null:r.newRange,i=t.length,a=e.length;if(0===n.length&&(null===o||0===o.length)){var u=n.index,s=t.slice(0,u),c=t.slice(u),l=o?o.index:null,f=u+a-i;if((null===l||l===f)&&!(f<0||f>a)){var p=e.slice(0,f);if((v=e.slice(f))===c){var h=Math.min(u,f);if((m=s.slice(0,h))===(_=p.slice(0,h)))return g(m,s.slice(h),p.slice(h),c)}}if(null===l||l===u){var d=u,v=(p=e.slice(0,d),e.slice(d));if(p===s){var b=Math.min(i-d,a-d);if((y=c.slice(c.length-b))===(j=v.slice(v.length-b)))return g(s,c.slice(0,c.length-b),v.slice(0,v.length-b),y)}}}if(n.length>0&&o&&0===o.length){var m=t.slice(0,n.index),y=t.slice(n.index+n.length);if(!(a<(h=m.length)+(b=y.length))){var _=e.slice(0,h),j=e.slice(a-b);if(m===_&&y===j)return g(m,t.slice(h,i-b),e.slice(h,a-b),y)}}return null}(t,v,b);if(_)return _}var j=a(t,v),w=t.substring(0,j);j=s(t=t.substring(j),v=v.substring(j));var x=t.substring(t.length-j),O=function(t,u){var c;if(!t)return[[r,u]];if(!u)return[[e,t]];var l=t.length>u.length?t:u,f=t.length>u.length?u:t,p=l.indexOf(f);if(-1!==p)return c=[[r,l.substring(0,p)],[n,f],[r,l.substring(p+f.length)]],t.length>u.length&&(c[0][0]=c[2][0]=e),c;if(1===f.length)return[[e,t],[r,u]];var h=function(t,e){var r=t.length>e.length?t:e,n=t.length>e.length?e:t;if(r.length<4||2*n.length=t.length?[n,o,i,u,f]:null}var i,u,c,l,f,p=o(r,n,Math.ceil(r.length/4)),h=o(r,n,Math.ceil(r.length/2));return p||h?(i=h?p&&p[4].length>h[4].length?p:h:p,t.length>e.length?(u=i[0],c=i[1],l=i[2],f=i[3]):(l=i[0],f=i[1],u=i[2],c=i[3]),[u,c,l,f,i[4]]):null}(t,u);if(h){var d=h[0],v=h[1],b=h[2],m=h[3],y=h[4],g=o(d,b),_=o(v,m);return g.concat([[n,y]],_)}return function(t,n){for(var o=t.length,a=n.length,u=Math.ceil((o+a)/2),s=u,c=2*u,l=new Array(c),f=new Array(c),p=0;po)b+=2;else if(w>a)v+=2;else if(d&&(S=s+h-_)>=0&&S=(O=o-f[S]))return i(t,n,E,w)}for(var x=-g+m;x<=g-y;x+=2){for(var O,S=s+x,A=(O=x===-g||x!==g&&f[S-1]o)y+=2;else if(A>a)m+=2;else if(!d){var E;if((j=s+h-x)>=0&&j=(O=o-O))return i(t,n,E,w)}}}return[[e,t],[r,n]]}(t,u)}(t=t.substring(0,t.length-j),v=v.substring(0,v.length-j));return w&&O.unshift([n,w]),x&&O.push([n,x]),d(O,y),m&&function(t){for(var o=!1,i=[],a=0,v=null,b=0,m=0,y=0,g=0,_=0;b0?i[a-1]:-1,m=0,y=0,g=0,_=0,v=null,o=!0)),b++;for(o&&d(t),function(t){function e(t,e){if(!t||!e)return 6;var r=t.charAt(t.length-1),n=e.charAt(0),o=r.match(c),i=n.match(c),a=o&&r.match(l),u=i&&n.match(l),s=a&&r.match(f),d=u&&n.match(f),v=s&&t.match(p),b=d&&e.match(h);return v||b?5:s||d?4:o&&!a&&u?3:a||u?2:o||i?1:0}for(var r=1;r=y&&(y=g,v=o,b=i,m=a)}t[r-1][1]!=v&&(v?t[r-1][1]=v:(t.splice(r-1,1),r--),t[r][1]=b,m?t[r+1][1]=m:(t.splice(r+1,1),r--))}r++}}(t),b=1;b=O?(x>=j.length/2||x>=w.length/2)&&(t.splice(b,0,[n,w.substring(0,x)]),t[b-1][1]=j.substring(0,j.length-x),t[b+1][1]=w.substring(x),b++):(O>=j.length/2||O>=w.length/2)&&(t.splice(b,0,[n,j.substring(0,O)]),t[b-1][0]=r,t[b-1][1]=w.substring(0,w.length-O),t[b+1][0]=e,t[b+1][1]=j.substring(O),b++),b++}b++}}(O),O}function i(t,e,r,n){var i=t.substring(0,r),a=e.substring(0,n),u=t.substring(r),s=e.substring(n),c=o(i,a),l=o(u,s);return c.concat(l)}function a(t,e){if(!t||!e||t.charAt(0)!==e.charAt(0))return 0;for(var r=0,n=Math.min(t.length,e.length),o=n,i=0;rn?t=t.substring(r-n):r=0&&y(t[h][1])){var v=t[h][1].slice(-1);if(t[h][1]=t[h][1].slice(0,-1),f=v+f,p=v+p,!t[h][1]){t.splice(h,1),u--;var b=h-1;t[b]&&t[b][0]===r&&(l++,p=t[b][1]+p,b--),t[b]&&t[b][0]===e&&(c++,f=t[b][1]+f,b--),h=b}}m(t[u][1])&&(v=t[u][1].charAt(0),t[u][1]=t[u][1].slice(1),f+=v,p+=v)}if(u0||p.length>0){f.length>0&&p.length>0&&(0!==(i=a(p,f))&&(h>=0?t[h][1]+=p.substring(0,i):(t.splice(0,0,[n,p.substring(0,i)]),u++),p=p.substring(i),f=f.substring(i)),0!==(i=s(p,f))&&(t[u][1]=p.substring(p.length-i)+t[u][1],p=p.substring(0,p.length-i),f=f.substring(0,f.length-i)));var g=l+c;0===f.length&&0===p.length?(t.splice(u-g,g),u-=g):0===f.length?(t.splice(u-g,g,[r,p]),u=u-g+1):0===p.length?(t.splice(u-g,g,[e,f]),u=u-g+1):(t.splice(u-g,g,[e,f],[r,p]),u=u-g+2)}0!==u&&t[u-1][0]===n?(t[u-1][1]+=t[u][1],t.splice(u,1)):u++,l=0,c=0,f="",p=""}""===t[t.length-1][1]&&t.pop();var _=!1;for(u=1;u=55296&&t<=56319}function b(t){return t>=56320&&t<=57343}function m(t){return b(t.charCodeAt(0))}function y(t){return v(t.charCodeAt(t.length-1))}function g(t,o,i,a){return y(t)||m(a)?null:function(t){for(var e=[],r=0;r0&&e.push(t[r]);return e}([[n,t],[e,o],[r,i],[n,a]])}function _(t,e,r,n){return o(t,e,r,n,!0)}_.INSERT=r,_.DELETE=e,_.EQUAL=n,t.exports=_},308:function(t,e){var r,n;"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self&&self,r=function(t){"use strict";function e(t){return function(t){if(Array.isArray(t))return r(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return r(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function r(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if("string"!=typeof t)return t;var r=new RegExp("(".concat(Object.keys(e).join("|"),")(?!(\\w|#)*;)"),"g");return String(t).replace(r,(function(t,r){return e[r]||""}))},d=function(){var t=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1?arguments[1]:void 0;return Array.isArray(t)?t.map((function(t){var r=Object.keys(t)[0],n=t[r],o=e?h(n,e):n,i=!0===o?"":'="'.concat(o,'"');return"".concat(r).concat(i)})):Object.keys(t).map((function(r){var n=e?h(t[r],e):t[r],o=!0===t[r]?"":'="'.concat(n,'"');return"".concat(r).concat(o)}))}(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},arguments.length>1?arguments[1]:void 0);if(0===t.length)return"";var e=t.join(" ");return" ".concat(e)},v=["string","number",u],b=function(t){return v.includes(p(t))},m=([].concat(v,[s,c]),function(t){return!t.match("<")}),y={"<":"<",">":">","&":"&"},g=function t(){var r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=n.depth,s=void 0===i?0:i,c=n.indent,v=n._isFirstItem,g=n._isOutputStart,_=void 0===g||g,j=n.header,w=n.attributesFilter,x=void 0===w?{}:w,O=n.filter,S=void 0===O?{}:O,A="boolean"!=typeof x||x?o(o(o({},y),{'"':"""}),x):{},E="boolean"!=typeof S||S?o(o({},y),S):{},k=function(){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"").repeat(t)}(c,s),D=p(r),C=function(t){var e=t.header,r=(t.indent,t.isOutputStart);return e&&r?a(e)===u?'':e:""}({header:j,indent:c,depth:s,isOutputStart:_}),P=_&&!C&&v&&0===s,z="";switch(D){case"special-object":var F=r._name,T=r._content;if(null===T){z=F;break}if(Array.isArray(T)&&T.every(b))return T.map((function(e){return t({_name:F,_content:e},o(o({},n),{},{depth:s,_isOutputStart:!1}))})).join("");if(F.match(f))break;var M=t(T,o(o({},n),{},{depth:s+1,_isOutputStart:P})),L=p(M),I=m(M),N="".concat(c&&!P?"\n":"").concat(k);if("_comment"===F){z+="".concat(N,"\x3c!-- ").concat(T," --\x3e");break}var R="undefined"===L||""===M,q=a(r._selfCloseTag)===u?R&&r._selfCloseTag:R,G=q?"/":"",B=d(r._attrs,A),U="<".concat(F).concat(B).concat(G,">"),$=c&&!I?"\n".concat(k):"",W=q?"":"".concat(M).concat($,"");z+="".concat(N).concat(U).concat(W);break;case"object":var X=Object.keys(r);z=X.map((function(i,a){var u=o(o({},n),{},{_isFirstItem:0===a,_isLastItem:a+1===X.length,_isOutputStart:P}),s={_name:i};if("object"===p(r[i])&&(l.forEach((function(t){var e=r[i][t];void 0!==e&&(s[t]=e,delete r[i][t])})),void 0!==r[i]._content&&Object.keys(r[i]).length>1)){var c=Object.assign({},r[i]);delete c._content,s._content=[].concat(e(function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object.keys(t).map((function(e){return{_name:e,_content:t[e]}}))}(c)),[r[i]._content])}return void 0===s._content&&(s._content=r[i]),t(s,u,i)}),n).join("");break;case"function":var V=r(n);z=t(V,n);break;case"array":z=r.map((function(e,i){var a=o(o({},n),{},{_isFirstItem:0===i,_isLastItem:i+1===r.length,_isOutputStart:P});return t(e,a)})).join("");break;default:z=h(r,E)}return"".concat(C).concat(z)};t.toXML=g;var _={toXML:g};t.default=_},void 0===(n=r.apply(e,[e]))||(t.exports=n)},259:(t,e,r)=>{"use strict";t.exports=r(159)},434:(t,e,r)=>{"use strict";var n=r(723);function o(){}var i=null,a={};function u(t){if("object"!=typeof this)throw new TypeError("Promises must be constructed via new");if("function"!=typeof t)throw new TypeError("Promise constructor's argument is not a function");this._x=0,this._y=0,this._z=null,this._A=null,t!==o&&h(t,this)}function s(t,e){for(;3===t._y;)t=t._z;if(u._B&&u._B(t),0===t._y)return 0===t._x?(t._x=1,void(t._A=e)):1===t._x?(t._x=2,void(t._A=[t._A,e])):void t._A.push(e);!function(t,e){n((function(){var r=1===t._y?e.onFulfilled:e.onRejected;if(null!==r){var n=function(t,e){try{return t(e)}catch(t){return i=t,a}}(r,t._z);n===a?l(e.promise,i):c(e.promise,n)}else 1===t._y?c(e.promise,t._z):l(e.promise,t._z)}))}(t,e)}function c(t,e){if(e===t)return l(t,new TypeError("A promise cannot be resolved with itself."));if(e&&("object"==typeof e||"function"==typeof e)){var r=function(t){try{return t.then}catch(t){return i=t,a}}(e);if(r===a)return l(t,i);if(r===t.then&&e instanceof u)return t._y=3,t._z=e,void f(t);if("function"==typeof r)return void h(r.bind(e),t)}t._y=1,t._z=e,f(t)}function l(t,e){t._y=2,t._z=e,u._C&&u._C(t,e),f(t)}function f(t){if(1===t._x&&(s(t,t._A),t._A=null),2===t._x){for(var e=0;e{"use strict";var n=r(434);t.exports=n,n.prototype.done=function(t,e){(arguments.length?this.then.apply(this,arguments):this).then(null,(function(t){setTimeout((function(){throw t}),0)}))}},803:(t,e,r)=>{"use strict";var n=r(434);t.exports=n;var o=l(!0),i=l(!1),a=l(null),u=l(void 0),s=l(0),c=l("");function l(t){var e=new n(n._D);return e._y=1,e._z=t,e}n.resolve=function(t){if(t instanceof n)return t;if(null===t)return a;if(void 0===t)return u;if(!0===t)return o;if(!1===t)return i;if(0===t)return s;if(""===t)return c;if("object"==typeof t||"function"==typeof t)try{var e=t.then;if("function"==typeof e)return new n(e.bind(t))}catch(t){return new n((function(e,r){r(t)}))}return l(t)};var f=function(t){return"function"==typeof Array.from?(f=Array.from,Array.from(t)):(f=function(t){return Array.prototype.slice.call(t)},Array.prototype.slice.call(t))};function p(t){return{status:"fulfilled",value:t}}function h(t){return{status:"rejected",reason:t}}function d(t){if(t&&("object"==typeof t||"function"==typeof t)){if(t instanceof n&&t.then===n.prototype.then)return t.then(p,h);var e=t.then;if("function"==typeof e)return new n(e.bind(t)).then(p,h)}return p(t)}function v(t){if("function"==typeof AggregateError)return new AggregateError(t,"All promises were rejected");var e=new Error("All promises were rejected");return e.name="AggregateError",e.errors=t,e}n.all=function(t){var e=f(t);return new n((function(t,r){if(0===e.length)return t([]);var o=e.length;function i(a,u){if(u&&("object"==typeof u||"function"==typeof u)){if(u instanceof n&&u.then===n.prototype.then){for(;3===u._y;)u=u._z;return 1===u._y?i(a,u._z):(2===u._y&&r(u._z),void u.then((function(t){i(a,t)}),r))}var s=u.then;if("function"==typeof s)return void new n(s.bind(u)).then((function(t){i(a,t)}),r)}e[a]=u,0==--o&&t(e)}for(var a=0;a{"use strict";var n=r(434);t.exports=n,n.prototype.finally=function(t){return this.then((function(e){return n.resolve(t()).then((function(){return e}))}),(function(e){return n.resolve(t()).then((function(){throw e}))}))}},159:(t,e,r)=>{"use strict";t.exports=r(434),r(445),r(29),r(803),r(490),r(690)},490:(t,e,r)=>{"use strict";var n=r(434),o=r(272);t.exports=n,n.denodeify=function(t,e){return"number"==typeof e&&e!==1/0?function(t,e){for(var r=[],o=0;o "+e+") {","args = new Array(arguments.length + 1);","for (var i = 0; i < arguments.length; i++) {","args[i] = arguments[i];","}","}","return new Promise(function (rs, rj) {","var cb = "+i+";","var res;","switch (argLength) {",r.concat(["extra"]).map((function(t,e){return"case "+e+":res = fn.call("+["self"].concat(r.slice(0,e)).concat("cb").join(",")+");break;"})).join(""),"default:","args[argLength] = cb;","res = fn.apply(self, args);","}","if (res &&",'(typeof res === "object" || typeof res === "function") &&','typeof res.then === "function"',") {rs(res);}","});","};"].join("");return Function(["Promise","fn"],a)(n,t)}(t)};var i="function (err, res) {if (err) { rj(err); } else { rs(res); }}";n.nodeify=function(t){return function(){var e=Array.prototype.slice.call(arguments),r="function"==typeof e[e.length-1]?e.pop():null,i=this;try{return t.apply(this,arguments).nodeify(r,i)}catch(t){if(null==r)return new n((function(e,r){r(t)}));o((function(){r.call(i,t)}))}}},n.prototype.nodeify=function(t,e){if("function"!=typeof t)return this;this.then((function(r){o((function(){t.call(e,null,r)}))}),(function(r){o((function(){t.call(e,r)}))}))}},690:(t,e,r)=>{"use strict";var n=r(434);t.exports=n,n.enableSynchronous=function(){n.prototype.isPending=function(){return 0==this.getState()},n.prototype.isFulfilled=function(){return 1==this.getState()},n.prototype.isRejected=function(){return 2==this.getState()},n.prototype.getValue=function(){if(3===this._y)return this._z.getValue();if(!this.isFulfilled())throw new Error("Cannot get a value of an unfulfilled promise.");return this._z},n.prototype.getReason=function(){if(3===this._y)return this._z.getReason();if(!this.isRejected())throw new Error("Cannot get a rejection reason of a non-rejected promise.");return this._z},n.prototype.getState=function(){return 3===this._y?this._z.getState():-1===this._y||-2===this._y?0:this._y}},n.disableSynchronous=function(){n.prototype.isPending=void 0,n.prototype.isFulfilled=void 0,n.prototype.isRejected=void 0,n.prototype.getValue=void 0,n.prototype.getReason=void 0,n.prototype.getState=void 0}},666:t=>{var e=function(t){"use strict";var e,r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",u=i.asyncIterator||"@@asyncIterator",s=i.toStringTag||"@@toStringTag";function c(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{c({},"")}catch(t){c=function(t,e,r){return t[e]=r}}function l(t,e,r,n){var i=e&&e.prototype instanceof m?e:m,a=Object.create(i.prototype),u=new C(n||[]);return o(a,"_invoke",{value:A(t,r,u)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=l;var p="suspendedStart",h="suspendedYield",d="executing",v="completed",b={};function m(){}function y(){}function g(){}var _={};c(_,a,(function(){return this}));var j=Object.getPrototypeOf,w=j&&j(j(P([])));w&&w!==r&&n.call(w,a)&&(_=w);var x=g.prototype=m.prototype=Object.create(_);function O(t){["next","throw","return"].forEach((function(e){c(t,e,(function(t){return this._invoke(e,t)}))}))}function S(t,e){function r(o,i,a,u){var s=f(t[o],t,i);if("throw"!==s.type){var c=s.arg,l=c.value;return l&&"object"==typeof l&&n.call(l,"__await")?e.resolve(l.__await).then((function(t){r("next",t,a,u)}),(function(t){r("throw",t,a,u)})):e.resolve(l).then((function(t){c.value=t,a(c)}),(function(t){return r("throw",t,a,u)}))}u(s.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function A(t,e,r){var n=p;return function(o,i){if(n===d)throw new Error("Generator is already running");if(n===v){if("throw"===o)throw i;return z()}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var u=E(a,r);if(u){if(u===b)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(n===p)throw n=v,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n=d;var s=f(t,e,r);if("normal"===s.type){if(n=r.done?v:h,s.arg===b)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n=v,r.method="throw",r.arg=s.arg)}}}function E(t,r){var n=r.method,o=t.iterator[n];if(o===e)return r.delegate=null,"throw"===n&&t.iterator.return&&(r.method="return",r.arg=e,E(t,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),b;var i=f(o,t.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,b;var a=i.arg;return a?a.done?(r[t.resultName]=a.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,b):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,b)}function k(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function D(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function C(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(k,this),this.reset(!0)}function P(t){if(t){var r=t[a];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,i=function r(){for(;++o=0;--i){var a=this.tryEntries[i],u=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var s=n.call(a,"catchLoc"),c=n.call(a,"finallyLoc");if(s&&c){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),D(r),b}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;D(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:P(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),b}},t}(t.exports);try{regeneratorRuntime=e}catch(t){"object"==typeof globalThis?globalThis.regeneratorRuntime=e:Function("r","regeneratorRuntime = r")(e)}}},e={};function r(n){var o=e[n];if(void 0!==o)return o.exports;var i=e[n]={exports:{}};return t[n].call(i.exports,i,i.exports,r),i.exports}r.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return r.d(e,{a:e}),e},r.d=(t,e)=>{for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var n={};return(()=>{"use strict";r.r(n),r.d(n,{Cell:()=>h,Chord:()=>d,LogLevel:()=>D,MusicXML:()=>C,Playlist:()=>p,Song:()=>v,convert:()=>M,convertSync:()=>T});var t=r(259),e=r.n(t),o=r(529),i=r.n(o);function a(t){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a(t)}function u(t,e,r){return(e=l(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function s(t,e){for(var r=0;r1&&(this.name=n.pop()),this.songs=n.map((function(t){try{return new v(t,"irealbook"===r[1])}catch(r){var e=t.split("="),n=v.parseTitle(e[0].trim());return console.error("[ireal-musicxml] [".concat(n,"] ").concat(r.toString())),null}})).filter((function(t){return null!==t})).reduce((function(t,e){if(t.length>0){var r=i()(t[t.length-1].title,e.title);if(0===r[0][0]&&r.every((function(t){return 0===t[0]||t[1].match(/^\d+$/)})))return t[t.length-1].cells=t[t.length-1].cells.concat(e.cells),t}return t.push(e),t}),[])})),h=c((function t(){f(this,t),this.annots=[],this.comments=[],this.bars="",this.spacer=0,this.chord=null})),d=c((function t(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;f(this,t),this.note=e,this.modifiers=r,this.over=n,this.alternate=o})),v=function(){function t(e){var r=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(f(this,t),this.cells=[],this.musicXml="",!e)return this.title="",this.composer="",this.style="",this.key="",this.transpose=0,this.groove="",this.bpm=0,void(this.repeats=0);var n=e.split("=");if(r)this.title=t.parseTitle(n[0].trim()),this.composer=t.parseComposer(n[1].trim()),this.style=n[2].trim(),this.key=n[3],this.cells=this.parse(n[5]);else{this.title=t.parseTitle(n[0].trim()),this.composer=t.parseComposer(n[1].trim()),this.style=n[3].trim(),this.key=n[4],this.transpose=+n[5]||0,this.groove=n[7],this.bpm=+n[8],this.repeats=+n[9]||3;var o=n[6].split("1r34LbKcu7");this.cells=this.parse(function(t){for(var e,r="";t.length>51;)e=t.substring(0,50),t=t.substring(50),r+=b(e);return(r+=t).replace(/Kcl/g,"| x").replace(/LZ/g," |").replace(/XyQ/g," ")}(o[1]))}}return c(t,[{key:"parse",value:function(e){for(var r=e.trim(),n=[];r;){for(var o=!1,i=0;i/,v.chordRegex,v.chordRegex2]);var m=r(308),y=r(13);function g(t){return g="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},g(t)}function _(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function j(t){for(var e=1;et.length)&&(e=t.length);for(var r=0,n=new Array(e);r\n\n ').trim(),indent:" "})}},{key:"convertSong",value:function(){return{_name:"score-partwise",_attrs:{version:"4.0"},_content:[{work:{"work-title":this.song.title}},{identification:[{_name:"creator",_attrs:{type:"composer"},_content:this.song.composer},{encoding:[{software:"@infojunkie/ireal-musicxml ".concat("1.11.0")},{"encoding-date":t.convertDate(new Date)},{_name:"supports",_attrs:{element:"accidental",type:"no"}},{_name:"supports",_attrs:{element:"transpose",type:"no"}},{_name:"supports",_attrs:{attribute:"new-page",element:"print",type:"yes",value:"yes"}},{_name:"supports",_attrs:{attribute:"new-system",element:"print",type:"yes",value:"yes"}}]}]},{defaults:{scaling:{millimeters:7,tenths:40}}},{"part-list":{_name:"score-part",_attrs:{id:"P1"},_content:{_name:"part-name",_attrs:{"print-object":"no"},_content:"Lead sheet"}}},{_name:"part",_attrs:{id:"P1"},_content:this.convertMeasures()}]}}},{key:"convertMeasures",value:function(){var e=this,r=this.song.cells.reduce((function(r,n,o){if((n.bars.match(/\(|\{|\[/)||!e.measure&&(n.chord||n.annots.length||n.comments.length))&&(e.measure&&(e._log(D.Warn,"Starting a new measure over existing measure. Closing current measure first."),e.measure.barlines.push(e.convertBarline("","right")),e.adjustChordsDuration(e.measure)&&r.push(e.measure)),e.measure=new t.Measure(r.length+1),r.length||(e.measure.attributes.push({divisions:e.options.divisions},{clef:[{sign:"G"},{line:2}]},{"measure-style":[{_name:"slash",_attrs:{type:"start","use-stems":"rhythmic"===e.options.notation?"yes":"no"}}]},e.convertKey()),e.song.bpm&&e.measure.body._content.push(e.convertTempo(e.song.bpm)),e.measure.body._content.push(e.convertStyleAndGroove(e.song.style,e.song.groove))),e.measure.barlines.push(e.convertBarline(n.bars,"left")),e.barRepeat&&(e.measure.chords=w(r[r.length-e.barRepeat-1].chords))),!e.measure)return(n.chord||n.annots.length||n.comments.length||n.bars&&")"!==n.bars)&&e._log(D.Warn,"Found non-empty orphan cell ".concat(JSON.stringify(n)),r[r.length-1]),r;if(o>0&&o%16==0&&e.measure.body._content.splice(0,0,{_name:"print",_attrs:{"new-system":"yes"}}),n.chord)switch(n.chord.note){case"x":e.barRepeat=1,e.measure.chords=w(r[r.length-e.barRepeat].chords);break;case"r":e.barRepeat=2,e.measure.chords=w(r[r.length-e.barRepeat].chords);break;case"p":if(e.measure.chords.length){e.measure.chords[e.measure.chords.length-1].spaces++;break}case"W":var i=e.measure;i.chords.length||(i=r.slice().reverse().find((function(t){return t.chords.length})))||e._log(D.Error,"Cannot find any measure with chords prior to ".concat(JSON.stringify(n.chord)));var a=i.chords[i.chords.length-1].ireal;a.over=n.chord.over,a.alternate=n.chord.alternate,e.measure.chords.push(e.convertChord(a));break;case" ":e._log(D.Warn,"Unhandled empty/alternate chord ".concat(JSON.stringify(n.chord)));break;default:e.measure.chords.push(e.convertChord(n.chord))}else e.barRepeat||e.measure.chords.length&&e.measure.chords[e.measure.chords.length-1].spaces++;return n.annots.forEach((function(t){switch(t[0]){case"*":var n=t.slice(1);e.measure.body._content.push(e.convertSection(n));break;case"T":var o=t.slice(1);e.measure.attributes.push(e.convertTime(o));break;case"S":e.measure.body._content.push(e.convertSegno());break;case"N":var i=parseInt(t.slice(1));if(e.measure.barlines[0]._content.push(e.convertEnding(i,"start")),i>1){r[r.length-1].barlines[1]._content.push(e.convertEnding(i-1,"stop"));var a=r.slice().reverse().find((function(t){return t.barEnding===i-1}));a||e._log(D.Error,"Cannot find ending ".concat(i-1," in right barline of any measure"));var u=a.barlines[1]._content.findIndex((function(t){return"ending"===t._name}));-1===u&&e._log(D.Error,"Cannot find ending ".concat(i-1," in right barline"),a),delete a.barlines[1]._content[u]}e.measure.barEnding=i;break;case"Q":e.measure.body._content.push(e.convertToCoda()),e.codas.push(e.measure);break;case"l":case"s":break;case"f":e.measure.chords[e.measure.chords.length-1].fermata=!0;break;case"U":e.measure.body._content.push(e.convertFine("END"));break;default:e._log(D.Warn,'Unhandled annotation "'.concat(t,'"'))}})),n.comments.map((function(t){return t.trim()})).forEach((function(r){var n=e._map(t.mapRepeats,r);n?e.measure.body._content.push(n.call(e,r)):e.measure.body._content.push(e.convertComment(r))})),n.bars.match(/\)|\}|\]|Z/)&&e.measure.chords.length&&(e.measure.barlines.push(e.convertBarline(n.bars,"right")),e.measure.barEnding&&e.measure.barlines[1]._content.push(e.convertEnding(e.measure.barEnding,"discontinue")),e.adjustChordsDuration(e.measure)&&r.push(e.measure),e.measure=null,e.barRepeat&&e.barRepeat--),r}),[]);if(this.codas.length){var n=this.codas[this.codas.length-1],o=n.body._content.findIndex((function(t){return"direction"===t._name&&Array.isArray(t._content)&&t._content.some((function(t){return"sound"===t._name&&Object.keys(t._attrs).includes("tocoda")}))}));-1===o&&this._log(D.Warn,"Cannot find sound direction",n),n.body._content[o]=this.convertCoda()}return r.map((function(t){return t.assemble()}))}},{key:"convertRepeatNx",value:function(t){var e;null!==(e=t.match(/(\d+)x/))&&(this.repeats=e[1])}},{key:"convertFine",value:function(t){return{_name:"direction",_attrs:{placement:"below"},_content:[{"direction-type":{words:t}},{_name:"sound",_attrs:{fine:"yes"}}]}}},{key:"convertDaCapo",value:function(t){return{_name:"direction",_attrs:{placement:"below"},_content:[{"direction-type":{words:t}},{_name:"sound",_attrs:{dacapo:"yes"}}]}}},{key:"convertDalSegno",value:function(t){return{_name:"direction",_attrs:{placement:"below"},_content:[{"direction-type":{words:t}},{_name:"sound",_attrs:{dalsegno:"yes"}}]}}},{key:"convertComment",value:function(t){var e="*"===t[0]?t.slice(3):t;return{_name:"direction",_attrs:{placement:"*"===t[0]?"above":"below"},_content:{"direction-type":{words:e}}}}},{key:"convertEnding",value:function(t,e){return{_name:"ending",_attrs:{number:t,type:e},_content:"".concat(t,".")}}},{key:"convertBarline",value:function(t,e){var r="left"===e?"none":"regular",n=null;return t.match(/\[|\]/)?r="light-light":t.match(/Z/)?r="light-heavy":t.match(/\{|\}/)&&(r="left"===e?"heavy-light":"light-heavy",n="left"===e?"forward":"backward"),"forward"===n&&(this.repeats=2),{_name:"barline",_attrs:{location:e},_content:[{"bar-style":r},j({},n&&{_name:"repeat",_attrs:j({direction:n},"backward"===n&&{times:this.repeats})})]}}},{key:"convertSection",value:function(t){return"i"===t&&(t="Intro"),{_name:"direction",_attrs:{placement:"above"},_content:{"direction-type":{rehearsal:t}}}}},{key:"convertSegno",value:function(){return{_name:"direction",_attrs:{placement:"above"},_content:[{"direction-type":{_name:"segno"}},{_name:"sound",_attrs:{segno:"segno"}}]}}},{key:"convertCoda",value:function(){return{_name:"direction",_attrs:{placement:"above"},_content:[{"direction-type":{_name:"coda"}},{_name:"sound",_attrs:{coda:"coda"}}]}}},{key:"convertToCoda",value:function(){return{_name:"direction",_attrs:{placement:"above"},_content:[{"direction-type":{words:"To Coda"}},{_name:"sound",_attrs:{tocoda:"coda"}}]}}},{key:"convertTempo",value:function(t){return{_name:"direction",_attrs:{placement:"above"},_content:[{"direction-type":[{_name:"metronome",_attrs:{parentheses:"no"},_content:[{"beat-unit":this.calculateChordDuration(1)[0].type},{"per-minute":t}]}]},{_name:"sound",_attrs:{tempo:t}}]}}},{key:"convertTime",value:function(t){var e=parseInt(t[0]),r=parseInt(t[1]);return"12"===t&&(e=12,r=8),this.time={beats:e,beatType:r},{time:[{beats:e},{"beat-type":r}]}}},{key:"adjustChordsDuration",value:function(t){var e=this;if(t.chords.length>this.time.beats)return this._log(D.Error,"Too many chords (".concat(t.chords.length," out of ").concat(this.time.beats,")"),t),!0;var r=t.chords.reduce((function(t,e){return t+1+e.spaces}),0);if(!r)return this._log(D.Warn,"No chord found. Skipping current measure.",t),!1;if(r>this.time.beats)for(var n=0;r>this.time.beats;)t.chords[n].spaces>0&&(t.chords[n].spaces--,r--),n=(n+1)%t.chords.length;else for(var o=0;r1?n>0?"stop":"start":null)})),t})),!0}},{key:"calculateChordDuration",value:function(t){var e=this,r={1:[{t:"eighth",d:0,b:1}],2:[{t:"quarter",d:0,b:2}],3:[{t:"quarter",d:1,b:3}],4:[{t:"half",d:0,b:4}],5:[{t:"quarter",d:1,b:3},{t:"quarter",d:0,b:2}],6:[{t:"half",d:1,b:6}],7:[{t:"half",d:2,b:7}],8:[{t:"whole",d:0,b:8}],9:[{t:"half",d:1,b:6},{t:"quarter",d:1,b:3}],10:[{t:"half",d:1,b:6},{t:"half",d:0,b:4}],11:[{t:"half",d:2,b:7},{t:"half",d:0,b:4}],12:[{t:"whole",d:1,b:12}],13:[{t:"half",d:2,b:7},{t:"half",d:1,b:6}],14:[{t:"whole",d:2,b:14}],15:[{t:"whole",d:0,b:8},{t:"half",d:2,b:7}]};if("slash"===this.options.notation){var n=8/this.time.beatType;return Array(t).fill(this._map(r,n,[],"Unexpected beat count 1 for time signature ".concat(this.time.beats,"/").concat(this.time.beatType)).map((function(t){return{duration:t.b*e.options.divisions/2,type:t.t,dots:t.d}}))[0])}var o=8*t/this.time.beatType;return this._map(r,o,[],"Unexpected beat count ".concat(t," for time signature ").concat(this.time.beats,"/").concat(this.time.beatType)).map((function(t){return{duration:t.b*e.options.divisions/2,type:t.t,dots:t.d}}))}},{key:"convertChordNote",value:function(e){var r=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,o={_name:"pitch",_content:[{step:this.options.step},{alter:this._map(t.mapFifthsToAlters,this.fifths,[],"Unhandled fifths count=".concat(this.fifths)).includes(this.options.step)?this.fifths>0?1:-1:0},{octave:this.options.octave}]},i=[];return r&&i.push({_name:"fermata"}),n&&i.push({_name:"tied",_attrs:{type:n}}),t.reorderSequence(this.measure,[o,{_name:"cue"},{notehead:this.options.notehead},{duration:e.duration},{voice:1},{_name:"type",_attrs:{size:"full"},_content:e.type},j({},i.length&&{notations:t.reorderSequence(this.measure,i,t.sequenceNotations)})].concat(Array(e.dots).fill({_name:"dot"})),t.sequenceNote)}},{key:"convertChordDegree",value:function(t,e,r){return{_name:"degree",_attrs:{"print-object":"no"},_content:[{"degree-value":t},{"degree-alter":r},{"degree-type":e}]}}},{key:"convertChordSymbol",value:function(e){var r=this,n=this.renderChord(this.parseChord("".concat(e.note).concat(e.modifiers)));if(!n)return this._log(D.Warn,'Unrecognized chord "'.concat(e.note).concat(e.modifiers,'"')),{rootStep:null,rootAlter:null,chordKind:null,chordDegrees:[],chordText:null};var o=n.input.rootNote[0],i=this._map(t.mapAlter,n.input.rootNote[1]||null,null,'Unrecognized accidental in chord "'.concat(n.input.rootNote,'"')),a=n.formatted.descriptor+n.formatted.chordChanges.join(""),u=this._map({major:"major",major6:"major-sixth",major7:"major-seventh",dominant7:"dominant",minor:"minor",minor6:"minor-sixth",minor7:"minor-seventh",minorMajor7:"major-minor",augmented:"augmented",diminished:"diminished",diminished7:"diminished-seventh",power:"power"},n.normalized.quality,"",'Unrecognized chord quality "'.concat(n.normalized.quality,'"'));if(n.normalized.extensions.length){var s=Math.max.apply(Math,w(n.normalized.extensions.map((function(t){return parseInt(t)})))).toString();"dominant-11th"===(u=u.split("-")[0]+this._map({9:"-ninth",11:"-11th",13:"-13th"},s,"","Unhandled extension ".concat(s)))&&(n.normalized.isSuspended=!1)}[{intervals:["1","4","5"],kind:"suspended-fourth",strict:!0},{intervals:["1","5","9"],kind:"suspended-second",strict:!0},{intervals:["1","b3","b5","b7"],kind:"half-diminished",strict:!0},{intervals:["1","3","#5","b7"],kind:"augmented-seventh",strict:!1}].some((function(t){if((!t.strict||n.normalized.intervals.length===t.intervals.length)&&t.intervals.every((function(t,e){return t===n.normalized.intervals[e]})))return u=t.kind,t.intervals.forEach((function(t){n.normalized.alterations=n.normalized.alterations.filter((function(e){return e===t})),n.normalized.adds=n.normalized.adds.filter((function(e){return e===t})),n.normalized.omits=n.normalized.omits.filter((function(e){return e===t}))})),n.normalized.intervals.forEach((function(e){t.intervals.includes(e)||n.normalized.adds.push(e)})),!0}));var c=[];return n.normalized.isSuspended&&!u.includes("suspended")&&(n.normalized.adds.push("4"),n.normalized.adds.includes("3")||n.normalized.omits.push("3")),n.normalized.alterations.forEach((function(e){var o=e.slice(1);c.push(r.convertChordDegree(o,"5"===o||n.normalized.extensions.includes(o)?"alter":"add",r._map(t.mapAlter,e[0],0,'Unrecognized alter symbol in "'.concat(e,'"'))))})),n.normalized.adds.forEach((function(e){var n=Object.keys(t.mapAlter).includes(e[0])?e[0]:null,o=n?e.slice(1):e;c.push(r.convertChordDegree(o,"add",r._map(t.mapAlter,n,0,'Unrecognized alter symbol in "'.concat(e,'"'))))})),n.normalized.omits.forEach((function(e){var n=Object.keys(t.mapAlter).includes(e[0])?e[0]:null,o=n?e.slice(1):e;c.push(r.convertChordDegree(o,"subtract",r._map(t.mapAlter,n,0,'Unrecognized alter symbol in "'.concat(e,'"'))))})),{rootStep:o,rootAlter:i,chordKind:u,chordDegrees:c,chordText:a}}},{key:"convertChord",value:function(e){var r=this,n=null;if("n"===e.note)n=[{root:[{_name:"root-step",_attrs:{text:""},_content:this.options.step}]},{_name:"kind",_attrs:{text:"N.C."},_content:"none"}];else{var o=this.convertChordSymbol(e),i=o.rootStep,a=o.rootAlter,u=o.chordKind,s=o.chordDegrees,c=o.chordText,l=e.over?[{"bass-step":e.over.note[0]},j({},e.over.note[1]&&{"bass-alter":this._map(t.mapAlter,e.over.note[1],null,'Unrecognized accidental in bass note "'.concat(e.over.note,'"'))})]:null;n=[{root:[{"root-step":i},j({},a&&{"root-alter":a})]},{_name:"kind",_attrs:{text:c,"use-symbols":"no"},_content:u},j({},l&&{bass:l})].concat(s)}return e.alternate&&this._log(D.Warn,"Unhandled alternate chord ".concat(JSON.stringify(e.alternate))),new t.Chord(n,this.calculateChordDuration(1).map((function(t){return r.convertChordNote(t)})),e)}},{key:"convertKey",value:function(){return this.fifths=this._map({C:0,G:1,D:2,A:3,E:4,B:5,"F#":6,"C#":7,F:-1,Bb:-2,Eb:-3,Ab:-4,Db:-5,Gb:-6,Cb:-7,"A-":0,"E-":1,"B-":2,"F#-":3,"C#-":4,"G#-":5,"D#-":6,"A#-":7,"D-":-1,"G-":-2,"C-":-3,"F-":-4,"Bb-":-5,"Eb-":-6,"Ab-":-7},this.song.key,0,'Unrecognized key signature "'.concat(this.song.key,'"')),{key:[{fifths:this.fifths},{mode:"-"===this.song.key.slice(-1)?"minor":"major"}]}}},{key:"convertStyleAndGroove",value:function(t,e){return{_name:"direction",_attrs:{placement:"above"},_content:[{"direction-type":[{words:t}]},{sound:[{play:[{_name:"other-play",_attrs:{type:"groove"},_content:e||t}]}]}]}}},{key:"_log",value:function(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.measure;if(!(t4&&void 0!==arguments[4]?arguments[4]:D.Warn,i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:this.measure;return e?e in t?t[e]:(n&&this._log(o,n,i),r||null):r}}],[{key:"convert",value:function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return new t(e,Object.assign({},this.defaultOptions,r)).convert()}},{key:"convertDate",value:function(t){return new Date(t.getTime()-6e4*t.getTimezoneOffset()).toISOString().split("T")[0]}},{key:"reorderSequence",value:function(t,e,r){var n=this;return e.filter((function(t){return Object.keys(t).length})).sort((function(e,o){var i=Object.keys(e)[0];"_name"===i&&(i=e[i]);var a=Object.keys(o)[0];"_name"===a&&(a=o[a]);var u=r.indexOf(i),s=r.indexOf(a);return-1===u&&n._log(D.Warn,'Unrecognized element "'.concat(i,'"'),t),-1===s&&n._log(D.Warn,'Unrecognized element "'.concat(a,'"'),t),u-s}))}}]),t}();function P(t){return P="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},P(t)}function z(){z=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",u=o.toStringTag||"@@toStringTag";function s(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,r){return t[e]=r}}function c(t,e,r,o){var i=e&&e.prototype instanceof p?e:p,a=Object.create(i.prototype),u=new S(o||[]);return n(a,"_invoke",{value:j(t,r,u)}),a}function l(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=c;var f={};function p(){}function h(){}function d(){}var v={};s(v,i,(function(){return this}));var b=Object.getPrototypeOf,m=b&&b(b(A([])));m&&m!==e&&r.call(m,i)&&(v=m);var y=d.prototype=p.prototype=Object.create(v);function g(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function _(t,e){function o(n,i,a,u){var s=l(t[n],t,i);if("throw"!==s.type){var c=s.arg,f=c.value;return f&&"object"==P(f)&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,u)}),(function(t){o("throw",t,a,u)})):e.resolve(f).then((function(t){c.value=t,a(c)}),(function(t){return o("throw",t,a,u)}))}u(s.arg)}var i;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){o(t,r,e,n)}))}return i=i?i.then(n,n):n()}})}function j(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return{value:void 0,done:!0}}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var u=w(a,r);if(u){if(u===f)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var s=l(t,e,r);if("normal"===s.type){if(n=r.done?"completed":"suspendedYield",s.arg===f)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n="completed",r.method="throw",r.arg=s.arg)}}}function w(t,e){var r=e.method,n=t.iterator[r];if(void 0===n)return e.delegate=null,"throw"===r&&t.iterator.return&&(e.method="return",e.arg=void 0,w(t,e),"throw"===e.method)||"return"!==r&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+r+"' method")),f;var o=l(n,t.iterator,e.arg);if("throw"===o.type)return e.method="throw",e.arg=o.arg,e.delegate=null,f;var i=o.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function x(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function O(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function S(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(x,this),this.reset(!0)}function A(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function e(){for(;++n=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var u=r.call(i,"catchLoc"),s=r.call(i,"finallyLoc");if(u&&s){if(this.prev=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),O(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;O(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:A(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function F(t,e,r,n,o,i,a){try{var u=t[i](a),s=u.value}catch(t){return void r(t)}u.done?e(s):Promise.resolve(s).then(n,o)}function T(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=new p(t);return r.songs.forEach((function(t){t.musicXml=C.convert(t,e)})),r}function M(t){return L.apply(this,arguments)}function L(){var t;return t=z().mark((function t(r){var n,o=arguments;return z().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=o.length>1&&void 0!==o[1]?o[1]:{},t.abrupt("return",new(e())((function(t){return t(T(r,n))})));case 2:case"end":return t.stop()}}),t)})),L=function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){F(i,n,o,a,u,"next",t)}function u(t){F(i,n,o,a,u,"throw",t)}a(void 0)}))},L.apply(this,arguments)}E(C,"defaultOptions",{divisions:768,notation:"rhythmic",step:"B",octave:4,notehead:"slash",logLevel:D.Warn}),E(C,"sequenceAttributes",["divisions","key","time","staves","part-symbol","instruments","clef","staff-details","transpose","directive","measure-style"]),E(C,"sequenceNote",["cue","pitch","rest","unpitched","duration","tie","voice","type","dot","accidental","time-modification","stem","notehead","notehead-text","staff","beam","notations","lyric","play"]),E(C,"sequenceNotations",["accidental-mark","arpeggiate","articulations","dynamics","fermata","glissando","non-arpeggiate","ornaments","other-notation","slide","slur","technical","tied","tuplet"]),E(C,"sequenceBarline",["bar-style","footnote","level","wavy-line","segno","coda","fermata","ending","repeat"]),E(C,"mapAlter",{"#":1,b:-1}),E(C,"mapFifthsToAlters",{0:[],1:["F"],2:["F","C"],3:["F","C","G"],4:["F","C","G","D"],5:["F","C","G","D","A"],6:["F","C","G","D","A","E"],7:["F","C","G","D","A","E","B"],"-1":["B"],"-2":["B","E"],"-3":["B","E","A"],"-4":["B","E","A","D"],"-5":["B","E","A","D","G"],"-6":["B","E","A","D","G","C"],"-7":["B","E","A","D","G","C","F"]}),E(C,"mapRepeats",{"D.C. al Coda":C.prototype.convertDaCapo,"D.C. al Fine":C.prototype.convertDaCapo,"D.C. al 1st End.":C.prototype.convertDaCapo,"D.C. al 2nd End.":C.prototype.convertDaCapo,"D.C. al 3rd End.":C.prototype.convertDaCapo,"D.S. al Coda":C.prototype.convertDalSegno,"D.S. al Fine":C.prototype.convertDalSegno,"D.S. al 1st End.":C.prototype.convertDalSegno,"D.S. al 2nd End.":C.prototype.convertDalSegno,"D.S. al 3rd End.":C.prototype.convertDalSegno,Fine:C.prototype.convertFine,"3x":C.prototype.convertRepeatNx,"4x":C.prototype.convertRepeatNx,"5x":C.prototype.convertRepeatNx,"6x":C.prototype.convertRepeatNx,"7x":C.prototype.convertRepeatNx,"8x":C.prototype.convertRepeatNx}),E(C,"Measure",function(){function t(e){A(this,t),this.body={_name:"measure",_attrs:{number:e},_content:[]},this.attributes=[],this.chords=[],this.barlines=[],this.barEnding=0}return S(t,[{key:"number",value:function(){return this.body._attrs.number}},{key:"assemble",value:function(){var t=this;return this.attributes.length&&this.body._content.push({attributes:C.reorderSequence(this,this.attributes,C.sequenceAttributes)}),this.chords.forEach((function(e){var r;(r=t.body._content).push.apply(r,[{harmony:e.harmony}].concat(w(e.notes.map((function(t){return{note:t}})))))})),this.barlines[0]._content=C.reorderSequence(this,this.barlines[0]._content,C.sequenceBarline),this.body._content.splice(1,0,this.barlines[0]),this.barlines[1]._content=C.reorderSequence(this,this.barlines[1]._content,C.sequenceBarline),this.body._content.push(this.barlines[1]),this.body}}]),t}()),E(C,"Chord",function(){return S((function t(e,r,n){A(this,t),this.harmony=e,this.notes=r,this.ireal=n,this.spaces=0,this.fermata=!1}))}()),r(666)})(),n})())); \ No newline at end of file +!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.iReal2MusicXML=e():t.iReal2MusicXML=e()}(this,(()=>(()=>{var t={272:(t,e,r)=>{"use strict";var n=r(723),o=[],i=[],a=n.makeRequestCallFromTimer((function(){if(i.length)throw i.shift()}));function u(t){var e;(e=o.length?o.pop():new s).task=t,n(e)}function s(){this.task=null}t.exports=u,s.prototype.call=function(){try{this.task.call()}catch(t){u.onerror?u.onerror(t):(i.push(t),a())}finally{this.task=null,o[o.length]=this}}},723:(t,e,r)=>{"use strict";function n(t){i.length||o(),i[i.length]=t}t.exports=n;var o,i=[],a=0;function u(){for(;a1024){for(var e=0,r=i.length-a;e{var t={8552:(t,e,r)=>{var n=r(852)(r(5639),"DataView");t.exports=n},1989:(t,e,r)=>{var n=r(1789),o=r(401),i=r(7667),a=r(1327),u=r(1866);function s(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e{var n=r(7040),o=r(4125),i=r(2117),a=r(7518),u=r(4705);function s(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e{var n=r(852)(r(5639),"Map");t.exports=n},3369:(t,e,r)=>{var n=r(4785),o=r(1285),i=r(6e3),a=r(9916),u=r(5265);function s(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e{var n=r(852)(r(5639),"Promise");t.exports=n},8525:(t,e,r)=>{var n=r(852)(r(5639),"Set");t.exports=n},8668:(t,e,r)=>{var n=r(3369),o=r(619),i=r(2385);function a(t){var e=-1,r=null==t?0:t.length;for(this.__data__=new n;++e{var n=r(8407),o=r(7465),i=r(3779),a=r(7599),u=r(4758),s=r(4309);function c(t){var e=this.__data__=new n(t);this.size=e.size}c.prototype.clear=o,c.prototype.delete=i,c.prototype.get=a,c.prototype.has=u,c.prototype.set=s,t.exports=c},2705:(t,e,r)=>{var n=r(5639).Symbol;t.exports=n},1149:(t,e,r)=>{var n=r(5639).Uint8Array;t.exports=n},577:(t,e,r)=>{var n=r(852)(r(5639),"WeakMap");t.exports=n},6874:t=>{t.exports=function(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}},7412:t=>{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length;++r{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length,o=0,i=[];++r{var n=r(2118);t.exports=function(t,e){return!(null==t||!t.length)&&n(t,e,0)>-1}},1196:t=>{t.exports=function(t,e,r){for(var n=-1,o=null==t?0:t.length;++n{var n=r(2545),o=r(5694),i=r(1469),a=r(4144),u=r(5776),s=r(6719),c=Object.prototype.hasOwnProperty;t.exports=function(t,e){var r=i(t),l=!r&&o(t),f=!r&&!l&&a(t),h=!r&&!l&&!f&&s(t),p=r||l||f||h,d=p?n(t.length,String):[],v=d.length;for(var b in t)!e&&!c.call(t,b)||p&&("length"==b||f&&("offset"==b||"parent"==b)||h&&("buffer"==b||"byteLength"==b||"byteOffset"==b)||u(b,v))||d.push(b);return d}},9932:t=>{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length,o=Array(n);++r{t.exports=function(t,e){for(var r=-1,n=e.length,o=t.length;++r{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length;++r{var n=r(9465),o=r(7813),i=Object.prototype.hasOwnProperty;t.exports=function(t,e,r){var a=t[e];i.call(t,e)&&o(a,r)&&(void 0!==r||e in t)||n(t,e,r)}},8470:(t,e,r)=>{var n=r(7813);t.exports=function(t,e){for(var r=t.length;r--;)if(n(t[r][0],e))return r;return-1}},4037:(t,e,r)=>{var n=r(8363),o=r(3674);t.exports=function(t,e){return t&&n(e,o(e),t)}},3886:(t,e,r)=>{var n=r(8363),o=r(1704);t.exports=function(t,e){return t&&n(e,o(e),t)}},9465:(t,e,r)=>{var n=r(8777);t.exports=function(t,e,r){"__proto__"==e&&n?n(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}},5990:(t,e,r)=>{var n=r(6384),o=r(7412),i=r(4865),a=r(4037),u=r(3886),s=r(4626),c=r(278),l=r(8805),f=r(1911),h=r(8234),p=r(6904),d=r(4160),v=r(3824),b=r(9148),m=r(8517),y=r(1469),g=r(4144),_=r(6688),j=r(3218),w=r(2928),x=r(3674),O=r(1704),S="[object Arguments]",A="[object Function]",E="[object Object]",k={};k[S]=k["[object Array]"]=k["[object ArrayBuffer]"]=k["[object DataView]"]=k["[object Boolean]"]=k["[object Date]"]=k["[object Float32Array]"]=k["[object Float64Array]"]=k["[object Int8Array]"]=k["[object Int16Array]"]=k["[object Int32Array]"]=k["[object Map]"]=k["[object Number]"]=k[E]=k["[object RegExp]"]=k["[object Set]"]=k["[object String]"]=k["[object Symbol]"]=k["[object Uint8Array]"]=k["[object Uint8ClampedArray]"]=k["[object Uint16Array]"]=k["[object Uint32Array]"]=!0,k["[object Error]"]=k[A]=k["[object WeakMap]"]=!1,t.exports=function t(e,r,D,C,P,z){var F,T=1&r,M=2&r,L=4&r;if(D&&(F=P?D(e,C,P,z):D(e)),void 0!==F)return F;if(!j(e))return e;var I=y(e);if(I){if(F=v(e),!T)return c(e,F)}else{var N=d(e),R=N==A||"[object GeneratorFunction]"==N;if(g(e))return s(e,T);if(N==E||N==S||R&&!P){if(F=M||R?{}:m(e),!T)return M?f(e,u(F,e)):l(e,a(F,e))}else{if(!k[N])return P?e:{};F=b(e,N,T)}}z||(z=new n);var q=z.get(e);if(q)return q;z.set(e,F),w(e)?e.forEach((function(n){F.add(t(n,r,D,n,e,z))})):_(e)&&e.forEach((function(n,o){F.set(o,t(n,r,D,o,e,z))}));var G=I?void 0:(L?M?p:h:M?O:x)(e);return o(G||e,(function(n,o){G&&(n=e[o=n]),i(F,o,t(n,r,D,o,e,z))})),F}},3118:(t,e,r)=>{var n=r(3218),o=Object.create,i=function(){function t(){}return function(e){if(!n(e))return{};if(o)return o(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}}();t.exports=i},731:(t,e,r)=>{var n=r(8668),o=r(7443),i=r(1196),a=r(9932),u=r(1717),s=r(4757);t.exports=function(t,e,r,c){var l=-1,f=o,h=!0,p=t.length,d=[],v=e.length;if(!p)return d;r&&(e=a(e,u(r))),c?(f=i,h=!1):e.length>=200&&(f=s,h=!1,e=new n(e));t:for(;++l{t.exports=function(t,e,r,n){for(var o=t.length,i=r+(n?1:-1);n?i--:++i{var n=r(2488),o=r(7285);t.exports=function t(e,r,i,a,u){var s=-1,c=e.length;for(i||(i=o),u||(u=[]);++s0&&i(l)?r>1?t(l,r-1,i,a,u):n(u,l):a||(u[u.length]=l)}return u}},8483:(t,e,r)=>{var n=r(5063)();t.exports=n},7816:(t,e,r)=>{var n=r(8483),o=r(3674);t.exports=function(t,e){return t&&n(t,e,o)}},7786:(t,e,r)=>{var n=r(1811),o=r(327);t.exports=function(t,e){for(var r=0,i=(e=n(e,t)).length;null!=t&&r{var n=r(2488),o=r(1469);t.exports=function(t,e,r){var i=e(t);return o(t)?i:n(i,r(t))}},4239:(t,e,r)=>{var n=r(2705),o=r(9607),i=r(2333),a=n?n.toStringTag:void 0;t.exports=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":a&&a in Object(t)?o(t):i(t)}},13:t=>{t.exports=function(t,e){return null!=t&&e in Object(t)}},2118:(t,e,r)=>{var n=r(1848),o=r(2722),i=r(2351);t.exports=function(t,e,r){return e==e?i(t,e,r):n(t,o,r)}},8975:(t,e,r)=>{var n=r(7816);t.exports=function(t,e,r,o){return n(t,(function(t,n,i){e(o,r(t),n,i)})),o}},9454:(t,e,r)=>{var n=r(4239),o=r(7005);t.exports=function(t){return o(t)&&"[object Arguments]"==n(t)}},939:(t,e,r)=>{var n=r(2492),o=r(7005);t.exports=function t(e,r,i,a,u){return e===r||(null==e||null==r||!o(e)&&!o(r)?e!=e&&r!=r:n(e,r,i,a,t,u))}},2492:(t,e,r)=>{var n=r(6384),o=r(7114),i=r(8351),a=r(6096),u=r(4160),s=r(1469),c=r(4144),l=r(6719),f="[object Arguments]",h="[object Array]",p="[object Object]",d=Object.prototype.hasOwnProperty;t.exports=function(t,e,r,v,b,m){var y=s(t),g=s(e),_=y?h:u(t),j=g?h:u(e),w=(_=_==f?p:_)==p,x=(j=j==f?p:j)==p,O=_==j;if(O&&c(t)){if(!c(e))return!1;y=!0,w=!1}if(O&&!w)return m||(m=new n),y||l(t)?o(t,e,r,v,b,m):i(t,e,_,r,v,b,m);if(!(1&r)){var S=w&&d.call(t,"__wrapped__"),A=x&&d.call(e,"__wrapped__");if(S||A){var E=S?t.value():t,k=A?e.value():e;return m||(m=new n),b(E,k,r,v,m)}}return!!O&&(m||(m=new n),a(t,e,r,v,b,m))}},5588:(t,e,r)=>{var n=r(4160),o=r(7005);t.exports=function(t){return o(t)&&"[object Map]"==n(t)}},2958:(t,e,r)=>{var n=r(6384),o=r(939);t.exports=function(t,e,r,i){var a=r.length,u=a,s=!i;if(null==t)return!u;for(t=Object(t);a--;){var c=r[a];if(s&&c[2]?c[1]!==t[c[0]]:!(c[0]in t))return!1}for(;++a{t.exports=function(t){return t!=t}},8458:(t,e,r)=>{var n=r(3560),o=r(5346),i=r(3218),a=r(346),u=/^\[object .+?Constructor\]$/,s=Function.prototype,c=Object.prototype,l=s.toString,f=c.hasOwnProperty,h=RegExp("^"+l.call(f).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");t.exports=function(t){return!(!i(t)||o(t))&&(n(t)?h:u).test(a(t))}},9221:(t,e,r)=>{var n=r(4160),o=r(7005);t.exports=function(t){return o(t)&&"[object Set]"==n(t)}},8749:(t,e,r)=>{var n=r(4239),o=r(1780),i=r(7005),a={};a["[object Float32Array]"]=a["[object Float64Array]"]=a["[object Int8Array]"]=a["[object Int16Array]"]=a["[object Int32Array]"]=a["[object Uint8Array]"]=a["[object Uint8ClampedArray]"]=a["[object Uint16Array]"]=a["[object Uint32Array]"]=!0,a["[object Arguments]"]=a["[object Array]"]=a["[object ArrayBuffer]"]=a["[object Boolean]"]=a["[object DataView]"]=a["[object Date]"]=a["[object Error]"]=a["[object Function]"]=a["[object Map]"]=a["[object Number]"]=a["[object Object]"]=a["[object RegExp]"]=a["[object Set]"]=a["[object String]"]=a["[object WeakMap]"]=!1,t.exports=function(t){return i(t)&&o(t.length)&&!!a[n(t)]}},7206:(t,e,r)=>{var n=r(1573),o=r(6432),i=r(6557),a=r(1469),u=r(9601);t.exports=function(t){return"function"==typeof t?t:null==t?i:"object"==typeof t?a(t)?o(t[0],t[1]):n(t):u(t)}},280:(t,e,r)=>{var n=r(5726),o=r(6916),i=Object.prototype.hasOwnProperty;t.exports=function(t){if(!n(t))return o(t);var e=[];for(var r in Object(t))i.call(t,r)&&"constructor"!=r&&e.push(r);return e}},313:(t,e,r)=>{var n=r(3218),o=r(5726),i=r(3498),a=Object.prototype.hasOwnProperty;t.exports=function(t){if(!n(t))return i(t);var e=o(t),r=[];for(var u in t)("constructor"!=u||!e&&a.call(t,u))&&r.push(u);return r}},1573:(t,e,r)=>{var n=r(2958),o=r(1499),i=r(2634);t.exports=function(t){var e=o(t);return 1==e.length&&e[0][2]?i(e[0][0],e[0][1]):function(r){return r===t||n(r,t,e)}}},6432:(t,e,r)=>{var n=r(939),o=r(7361),i=r(9095),a=r(5403),u=r(9162),s=r(2634),c=r(327);t.exports=function(t,e){return a(t)&&u(e)?s(c(t),e):function(r){var a=o(r,t);return void 0===a&&a===e?i(r,t):n(e,a,3)}}},371:t=>{t.exports=function(t){return function(e){return null==e?void 0:e[t]}}},9152:(t,e,r)=>{var n=r(7786);t.exports=function(t){return function(e){return n(e,t)}}},5976:(t,e,r)=>{var n=r(6557),o=r(5357),i=r(61);t.exports=function(t,e){return i(o(t,e,n),t+"")}},6560:(t,e,r)=>{var n=r(5703),o=r(8777),i=r(6557),a=o?function(t,e){return o(t,"toString",{configurable:!0,enumerable:!1,value:n(e),writable:!0})}:i;t.exports=a},2545:t=>{t.exports=function(t,e){for(var r=-1,n=Array(t);++r{var n=r(2705),o=r(9932),i=r(1469),a=r(3448),u=n?n.prototype:void 0,s=u?u.toString:void 0;t.exports=function t(e){if("string"==typeof e)return e;if(i(e))return o(e,t)+"";if(a(e))return s?s.call(e):"";var r=e+"";return"0"==r&&1/e==-1/0?"-0":r}},7561:(t,e,r)=>{var n=r(7990),o=/^\s+/;t.exports=function(t){return t?t.slice(0,n(t)+1).replace(o,""):t}},1717:t=>{t.exports=function(t){return function(e){return t(e)}}},5652:(t,e,r)=>{var n=r(8668),o=r(7443),i=r(1196),a=r(4757),u=r(3593),s=r(1814);t.exports=function(t,e,r){var c=-1,l=o,f=t.length,h=!0,p=[],d=p;if(r)h=!1,l=i;else if(f>=200){var v=e?null:u(t);if(v)return s(v);h=!1,l=a,d=new n}else d=e?[]:p;t:for(;++c{t.exports=function(t,e){return t.has(e)}},1811:(t,e,r)=>{var n=r(1469),o=r(5403),i=r(5514),a=r(9833);t.exports=function(t,e){return n(t)?t:o(t,e)?[t]:i(a(t))}},4318:(t,e,r)=>{var n=r(1149);t.exports=function(t){var e=new t.constructor(t.byteLength);return new n(e).set(new n(t)),e}},4626:(t,e,r)=>{t=r.nmd(t);var n=r(5639),o=e&&!e.nodeType&&e,i=o&&t&&!t.nodeType&&t,a=i&&i.exports===o?n.Buffer:void 0,u=a?a.allocUnsafe:void 0;t.exports=function(t,e){if(e)return t.slice();var r=t.length,n=u?u(r):new t.constructor(r);return t.copy(n),n}},7157:(t,e,r)=>{var n=r(4318);t.exports=function(t,e){var r=e?n(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}},3147:t=>{var e=/\w*$/;t.exports=function(t){var r=new t.constructor(t.source,e.exec(t));return r.lastIndex=t.lastIndex,r}},419:(t,e,r)=>{var n=r(2705),o=n?n.prototype:void 0,i=o?o.valueOf:void 0;t.exports=function(t){return i?Object(i.call(t)):{}}},7133:(t,e,r)=>{var n=r(4318);t.exports=function(t,e){var r=e?n(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}},278:t=>{t.exports=function(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r{var n=r(4865),o=r(9465);t.exports=function(t,e,r,i){var a=!r;r||(r={});for(var u=-1,s=e.length;++u{var n=r(8363),o=r(9551);t.exports=function(t,e){return n(t,o(t),e)}},1911:(t,e,r)=>{var n=r(8363),o=r(1442);t.exports=function(t,e){return n(t,o(t),e)}},4429:(t,e,r)=>{var n=r(5639)["__core-js_shared__"];t.exports=n},5063:t=>{t.exports=function(t){return function(e,r,n){for(var o=-1,i=Object(e),a=n(e),u=a.length;u--;){var s=a[t?u:++o];if(!1===r(i[s],s,i))break}return e}}},7740:(t,e,r)=>{var n=r(7206),o=r(8612),i=r(3674);t.exports=function(t){return function(e,r,a){var u=Object(e);if(!o(e)){var s=n(r,3);e=i(e),r=function(t){return s(u[t],t,u)}}var c=t(e,r,a);return c>-1?u[s?e[c]:c]:void 0}}},7779:(t,e,r)=>{var n=r(8975);t.exports=function(t,e){return function(r,o){return n(r,t,e(o),{})}}},3593:(t,e,r)=>{var n=r(8525),o=r(308),i=r(1814),a=n&&1/i(new n([,-0]))[1]==1/0?function(t){return new n(t)}:o;t.exports=a},8777:(t,e,r)=>{var n=r(852),o=function(){try{var t=n(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();t.exports=o},7114:(t,e,r)=>{var n=r(8668),o=r(2908),i=r(4757);t.exports=function(t,e,r,a,u,s){var c=1&r,l=t.length,f=e.length;if(l!=f&&!(c&&f>l))return!1;var h=s.get(t),p=s.get(e);if(h&&p)return h==e&&p==t;var d=-1,v=!0,b=2&r?new n:void 0;for(s.set(t,e),s.set(e,t);++d{var n=r(2705),o=r(1149),i=r(7813),a=r(7114),u=r(8776),s=r(1814),c=n?n.prototype:void 0,l=c?c.valueOf:void 0;t.exports=function(t,e,r,n,c,f,h){switch(r){case"[object DataView]":if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case"[object ArrayBuffer]":return!(t.byteLength!=e.byteLength||!f(new o(t),new o(e)));case"[object Boolean]":case"[object Date]":case"[object Number]":return i(+t,+e);case"[object Error]":return t.name==e.name&&t.message==e.message;case"[object RegExp]":case"[object String]":return t==e+"";case"[object Map]":var p=u;case"[object Set]":var d=1&n;if(p||(p=s),t.size!=e.size&&!d)return!1;var v=h.get(t);if(v)return v==e;n|=2,h.set(t,e);var b=a(p(t),p(e),n,c,f,h);return h.delete(t),b;case"[object Symbol]":if(l)return l.call(t)==l.call(e)}return!1}},6096:(t,e,r)=>{var n=r(8234),o=Object.prototype.hasOwnProperty;t.exports=function(t,e,r,i,a,u){var s=1&r,c=n(t),l=c.length;if(l!=n(e).length&&!s)return!1;for(var f=l;f--;){var h=c[f];if(!(s?h in e:o.call(e,h)))return!1}var p=u.get(t),d=u.get(e);if(p&&d)return p==e&&d==t;var v=!0;u.set(t,e),u.set(e,t);for(var b=s;++f{var n="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g;t.exports=n},8234:(t,e,r)=>{var n=r(8866),o=r(9551),i=r(3674);t.exports=function(t){return n(t,i,o)}},6904:(t,e,r)=>{var n=r(8866),o=r(1442),i=r(1704);t.exports=function(t){return n(t,i,o)}},5050:(t,e,r)=>{var n=r(7019);t.exports=function(t,e){var r=t.__data__;return n(e)?r["string"==typeof e?"string":"hash"]:r.map}},1499:(t,e,r)=>{var n=r(9162),o=r(3674);t.exports=function(t){for(var e=o(t),r=e.length;r--;){var i=e[r],a=t[i];e[r]=[i,a,n(a)]}return e}},852:(t,e,r)=>{var n=r(8458),o=r(7801);t.exports=function(t,e){var r=o(t,e);return n(r)?r:void 0}},5924:(t,e,r)=>{var n=r(5569)(Object.getPrototypeOf,Object);t.exports=n},9607:(t,e,r)=>{var n=r(2705),o=Object.prototype,i=o.hasOwnProperty,a=o.toString,u=n?n.toStringTag:void 0;t.exports=function(t){var e=i.call(t,u),r=t[u];try{t[u]=void 0;var n=!0}catch(t){}var o=a.call(t);return n&&(e?t[u]=r:delete t[u]),o}},9551:(t,e,r)=>{var n=r(4963),o=r(479),i=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols,u=a?function(t){return null==t?[]:(t=Object(t),n(a(t),(function(e){return i.call(t,e)})))}:o;t.exports=u},1442:(t,e,r)=>{var n=r(2488),o=r(5924),i=r(9551),a=r(479),u=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)n(e,i(t)),t=o(t);return e}:a;t.exports=u},4160:(t,e,r)=>{var n=r(8552),o=r(7071),i=r(3818),a=r(8525),u=r(577),s=r(4239),c=r(346),l="[object Map]",f="[object Promise]",h="[object Set]",p="[object WeakMap]",d="[object DataView]",v=c(n),b=c(o),m=c(i),y=c(a),g=c(u),_=s;(n&&_(new n(new ArrayBuffer(1)))!=d||o&&_(new o)!=l||i&&_(i.resolve())!=f||a&&_(new a)!=h||u&&_(new u)!=p)&&(_=function(t){var e=s(t),r="[object Object]"==e?t.constructor:void 0,n=r?c(r):"";if(n)switch(n){case v:return d;case b:return l;case m:return f;case y:return h;case g:return p}return e}),t.exports=_},7801:t=>{t.exports=function(t,e){return null==t?void 0:t[e]}},222:(t,e,r)=>{var n=r(1811),o=r(5694),i=r(1469),a=r(5776),u=r(1780),s=r(327);t.exports=function(t,e,r){for(var c=-1,l=(e=n(e,t)).length,f=!1;++c{var n=r(4536);t.exports=function(){this.__data__=n?n(null):{},this.size=0}},401:t=>{t.exports=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}},7667:(t,e,r)=>{var n=r(4536),o=Object.prototype.hasOwnProperty;t.exports=function(t){var e=this.__data__;if(n){var r=e[t];return"__lodash_hash_undefined__"===r?void 0:r}return o.call(e,t)?e[t]:void 0}},1327:(t,e,r)=>{var n=r(4536),o=Object.prototype.hasOwnProperty;t.exports=function(t){var e=this.__data__;return n?void 0!==e[t]:o.call(e,t)}},1866:(t,e,r)=>{var n=r(4536);t.exports=function(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=n&&void 0===e?"__lodash_hash_undefined__":e,this}},3824:t=>{var e=Object.prototype.hasOwnProperty;t.exports=function(t){var r=t.length,n=new t.constructor(r);return r&&"string"==typeof t[0]&&e.call(t,"index")&&(n.index=t.index,n.input=t.input),n}},9148:(t,e,r)=>{var n=r(4318),o=r(7157),i=r(3147),a=r(419),u=r(7133);t.exports=function(t,e,r){var s=t.constructor;switch(e){case"[object ArrayBuffer]":return n(t);case"[object Boolean]":case"[object Date]":return new s(+t);case"[object DataView]":return o(t,r);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return u(t,r);case"[object Map]":case"[object Set]":return new s;case"[object Number]":case"[object String]":return new s(t);case"[object RegExp]":return i(t);case"[object Symbol]":return a(t)}}},8517:(t,e,r)=>{var n=r(3118),o=r(5924),i=r(5726);t.exports=function(t){return"function"!=typeof t.constructor||i(t)?{}:n(o(t))}},7285:(t,e,r)=>{var n=r(2705),o=r(5694),i=r(1469),a=n?n.isConcatSpreadable:void 0;t.exports=function(t){return i(t)||o(t)||!!(a&&t&&t[a])}},5776:t=>{var e=/^(?:0|[1-9]\d*)$/;t.exports=function(t,r){var n=typeof t;return!!(r=null==r?9007199254740991:r)&&("number"==n||"symbol"!=n&&e.test(t))&&t>-1&&t%1==0&&t{var n=r(1469),o=r(3448),i=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;t.exports=function(t,e){if(n(t))return!1;var r=typeof t;return!("number"!=r&&"symbol"!=r&&"boolean"!=r&&null!=t&&!o(t))||a.test(t)||!i.test(t)||null!=e&&t in Object(e)}},7019:t=>{t.exports=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t}},5346:(t,e,r)=>{var n,o=r(4429),i=(n=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"";t.exports=function(t){return!!i&&i in t}},5726:t=>{var e=Object.prototype;t.exports=function(t){var r=t&&t.constructor;return t===("function"==typeof r&&r.prototype||e)}},9162:(t,e,r)=>{var n=r(3218);t.exports=function(t){return t==t&&!n(t)}},7040:t=>{t.exports=function(){this.__data__=[],this.size=0}},4125:(t,e,r)=>{var n=r(8470),o=Array.prototype.splice;t.exports=function(t){var e=this.__data__,r=n(e,t);return!(r<0||(r==e.length-1?e.pop():o.call(e,r,1),--this.size,0))}},2117:(t,e,r)=>{var n=r(8470);t.exports=function(t){var e=this.__data__,r=n(e,t);return r<0?void 0:e[r][1]}},7518:(t,e,r)=>{var n=r(8470);t.exports=function(t){return n(this.__data__,t)>-1}},4705:(t,e,r)=>{var n=r(8470);t.exports=function(t,e){var r=this.__data__,o=n(r,t);return o<0?(++this.size,r.push([t,e])):r[o][1]=e,this}},4785:(t,e,r)=>{var n=r(1989),o=r(8407),i=r(7071);t.exports=function(){this.size=0,this.__data__={hash:new n,map:new(i||o),string:new n}}},1285:(t,e,r)=>{var n=r(5050);t.exports=function(t){var e=n(this,t).delete(t);return this.size-=e?1:0,e}},6e3:(t,e,r)=>{var n=r(5050);t.exports=function(t){return n(this,t).get(t)}},9916:(t,e,r)=>{var n=r(5050);t.exports=function(t){return n(this,t).has(t)}},5265:(t,e,r)=>{var n=r(5050);t.exports=function(t,e){var r=n(this,t),o=r.size;return r.set(t,e),this.size+=r.size==o?0:1,this}},8776:t=>{t.exports=function(t){var e=-1,r=Array(t.size);return t.forEach((function(t,n){r[++e]=[n,t]})),r}},2634:t=>{t.exports=function(t,e){return function(r){return null!=r&&r[t]===e&&(void 0!==e||t in Object(r))}}},4523:(t,e,r)=>{var n=r(8306);t.exports=function(t){var e=n(t,(function(t){return 500===r.size&&r.clear(),t})),r=e.cache;return e}},4536:(t,e,r)=>{var n=r(852)(Object,"create");t.exports=n},6916:(t,e,r)=>{var n=r(5569)(Object.keys,Object);t.exports=n},3498:t=>{t.exports=function(t){var e=[];if(null!=t)for(var r in Object(t))e.push(r);return e}},1167:(t,e,r)=>{t=r.nmd(t);var n=r(1957),o=e&&!e.nodeType&&e,i=o&&t&&!t.nodeType&&t,a=i&&i.exports===o&&n.process,u=function(){try{return i&&i.require&&i.require("util").types||a&&a.binding&&a.binding("util")}catch(t){}}();t.exports=u},2333:t=>{var e=Object.prototype.toString;t.exports=function(t){return e.call(t)}},5569:t=>{t.exports=function(t,e){return function(r){return t(e(r))}}},5357:(t,e,r)=>{var n=r(6874),o=Math.max;t.exports=function(t,e,r){return e=o(void 0===e?t.length-1:e,0),function(){for(var i=arguments,a=-1,u=o(i.length-e,0),s=Array(u);++a{var n=r(1957),o="object"==typeof self&&self&&self.Object===Object&&self,i=n||o||Function("return this")();t.exports=i},619:t=>{t.exports=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this}},2385:t=>{t.exports=function(t){return this.__data__.has(t)}},1814:t=>{t.exports=function(t){var e=-1,r=Array(t.size);return t.forEach((function(t){r[++e]=t})),r}},61:(t,e,r)=>{var n=r(6560),o=r(1275)(n);t.exports=o},1275:t=>{var e=Date.now;t.exports=function(t){var r=0,n=0;return function(){var o=e(),i=16-(o-n);if(n=o,i>0){if(++r>=800)return arguments[0]}else r=0;return t.apply(void 0,arguments)}}},7465:(t,e,r)=>{var n=r(8407);t.exports=function(){this.__data__=new n,this.size=0}},3779:t=>{t.exports=function(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}},7599:t=>{t.exports=function(t){return this.__data__.get(t)}},4758:t=>{t.exports=function(t){return this.__data__.has(t)}},4309:(t,e,r)=>{var n=r(8407),o=r(7071),i=r(3369);t.exports=function(t,e){var r=this.__data__;if(r instanceof n){var a=r.__data__;if(!o||a.length<199)return a.push([t,e]),this.size=++r.size,this;r=this.__data__=new i(a)}return r.set(t,e),this.size=r.size,this}},2351:t=>{t.exports=function(t,e,r){for(var n=r-1,o=t.length;++n{var n=r(4523),o=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,i=/\\(\\)?/g,a=n((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(o,(function(t,r,n,o){e.push(n?o.replace(i,"$1"):r||t)})),e}));t.exports=a},327:(t,e,r)=>{var n=r(3448);t.exports=function(t){if("string"==typeof t||n(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}},346:t=>{var e=Function.prototype.toString;t.exports=function(t){if(null!=t){try{return e.call(t)}catch(t){}try{return t+""}catch(t){}}return""}},7990:t=>{var e=/\s/;t.exports=function(t){for(var r=t.length;r--&&e.test(t.charAt(r)););return r}},6678:(t,e,r)=>{var n=r(5990);t.exports=function(t){return n(t,4)}},361:(t,e,r)=>{var n=r(5990);t.exports=function(t){return n(t,5)}},5703:t=>{t.exports=function(t){return function(){return t}}},1966:(t,e,r)=>{var n=r(731),o=r(1078),i=r(5976),a=r(9246),u=i((function(t,e){return a(t)?n(t,o(e,1,a,!0)):[]}));t.exports=u},7813:t=>{t.exports=function(t,e){return t===e||t!=t&&e!=e}},3311:(t,e,r)=>{var n=r(7740)(r(998));t.exports=n},998:(t,e,r)=>{var n=r(1848),o=r(7206),i=r(554),a=Math.max;t.exports=function(t,e,r){var u=null==t?0:t.length;if(!u)return-1;var s=null==r?0:i(r);return s<0&&(s=a(u+s,0)),n(t,o(e,3),s)}},7361:(t,e,r)=>{var n=r(7786);t.exports=function(t,e,r){var o=null==t?void 0:n(t,e);return void 0===o?r:o}},9095:(t,e,r)=>{var n=r(13),o=r(222);t.exports=function(t,e){return null!=t&&o(t,e,n)}},6557:t=>{t.exports=function(t){return t}},3137:(t,e,r)=>{var n=r(5703),o=r(7779),i=r(6557),a=Object.prototype.toString,u=o((function(t,e,r){null!=e&&"function"!=typeof e.toString&&(e=a.call(e)),t[e]=r}),n(i));t.exports=u},5694:(t,e,r)=>{var n=r(9454),o=r(7005),i=Object.prototype,a=i.hasOwnProperty,u=i.propertyIsEnumerable,s=n(function(){return arguments}())?n:function(t){return o(t)&&a.call(t,"callee")&&!u.call(t,"callee")};t.exports=s},1469:t=>{var e=Array.isArray;t.exports=e},8612:(t,e,r)=>{var n=r(3560),o=r(1780);t.exports=function(t){return null!=t&&o(t.length)&&!n(t)}},9246:(t,e,r)=>{var n=r(8612),o=r(7005);t.exports=function(t){return o(t)&&n(t)}},4144:(t,e,r)=>{t=r.nmd(t);var n=r(5639),o=r(5062),i=e&&!e.nodeType&&e,a=i&&t&&!t.nodeType&&t,u=a&&a.exports===i?n.Buffer:void 0,s=(u?u.isBuffer:void 0)||o;t.exports=s},8446:(t,e,r)=>{var n=r(939);t.exports=function(t,e){return n(t,e)}},3560:(t,e,r)=>{var n=r(4239),o=r(3218);t.exports=function(t){if(!o(t))return!1;var e=n(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}},1780:t=>{t.exports=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}},6688:(t,e,r)=>{var n=r(5588),o=r(1717),i=r(1167),a=i&&i.isMap,u=a?o(a):n;t.exports=u},3218:t=>{t.exports=function(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}},7005:t=>{t.exports=function(t){return null!=t&&"object"==typeof t}},2928:(t,e,r)=>{var n=r(9221),o=r(1717),i=r(1167),a=i&&i.isSet,u=a?o(a):n;t.exports=u},3448:(t,e,r)=>{var n=r(4239),o=r(7005);t.exports=function(t){return"symbol"==typeof t||o(t)&&"[object Symbol]"==n(t)}},6719:(t,e,r)=>{var n=r(8749),o=r(1717),i=r(1167),a=i&&i.isTypedArray,u=a?o(a):n;t.exports=u},3674:(t,e,r)=>{var n=r(4636),o=r(280),i=r(8612);t.exports=function(t){return i(t)?n(t):o(t)}},1704:(t,e,r)=>{var n=r(4636),o=r(313),i=r(8612);t.exports=function(t){return i(t)?n(t,!0):o(t)}},8306:(t,e,r)=>{var n=r(3369);function o(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var r=function(){var n=arguments,o=e?e.apply(this,n):n[0],i=r.cache;if(i.has(o))return i.get(o);var a=t.apply(this,n);return r.cache=i.set(o,a)||i,a};return r.cache=new(o.Cache||n),r}o.Cache=n,t.exports=o},308:t=>{t.exports=function(){}},9601:(t,e,r)=>{var n=r(371),o=r(9152),i=r(5403),a=r(327);t.exports=function(t){return i(t)?n(a(t)):o(t)}},479:t=>{t.exports=function(){return[]}},5062:t=>{t.exports=function(){return!1}},8601:(t,e,r)=>{var n=r(4841);t.exports=function(t){return t?Infinity===(t=n(t))||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}},554:(t,e,r)=>{var n=r(8601);t.exports=function(t){var e=n(t),r=e%1;return e==e?r?e-r:e:0}},4841:(t,e,r)=>{var n=r(7561),o=r(3218),i=r(3448),a=/^[-+]0x[0-9a-f]+$/i,u=/^0b[01]+$/i,s=/^0o[0-7]+$/i,c=parseInt;t.exports=function(t){if("number"==typeof t)return t;if(i(t))return NaN;if(o(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=o(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=n(t);var r=u.test(t);return r||s.test(t)?c(t.slice(2),r?2:8):a.test(t)?NaN:+t}},9833:(t,e,r)=>{var n=r(531);t.exports=function(t){return null==t?"":n(t)}},4908:(t,e,r)=>{var n=r(5652);t.exports=function(t){return t&&t.length?n(t):[]}},2569:(t,e,r)=>{var n=r(731),o=r(5976),i=r(9246),a=o((function(t,e){return i(t)?n(t,e):[]}));t.exports=a}},e={};function r(n){var o=e[n];if(void 0!==o)return o.exports;var i=e[n]={id:n,loaded:!1,exports:{}};return t[n](i,i.exports,r),i.loaded=!0,i.exports}r.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return r.d(e,{a:e}),e},r.d=(t,e)=>{for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.nmd=t=>(t.paths=[],t.children||(t.children=[]),t);var n={};return(()=>{"use strict";function t(t,e){return t.reduce((function(t,e){return t?e(t):null}),e)}r.r(n),r.d(n,{chordParserFactory:()=>ke,chordRendererFactory:()=>nr});var e=r(361),o=r.n(e);const i=function(t){if(!Array.isArray(t))throw new TypeError("customFilters should be given as an array");if(t.some((function(t){return"function"!=typeof t})))throw new TypeError("The given filter is not a function");return!0};function a(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function u(t){for(var e=1;et.length)&&(e=t.length);for(var r=0,n=new Array(e);r0&&void 0!==arguments[0]?arguments[0]:{};return{input:{symbol:arguments.length>1?arguments[1]:void 0},normalized:{},formatted:{},parserConfiguration:o()(t)}}function Pt(t){return function(t){if(Array.isArray(t))return zt(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return zt(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?zt(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function zt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);rt.length)&&(e=t.length);for(var r=0,n=new Array(e);rt.length)&&(e=t.length);for(var r=0,n=new Array(e);r0)throw new J(t,a);return n}(e)),e.input.modifiers=r,e.normalized.intervals=function(t,e){return t.includes(ve.power)?["1","5"]:t.includes(ve.bass)?["1"]:$t()(["1"].concat(me(function(t){var e=[];return t.includes(ve.omit3)?[]:(it(t,[ve.sus,ve.sus2])||(we(t)?t.includes(ve.eleventh)||e.push("3"):e.push("b3")),t.includes(ve.add3)&&e.push("3"),e)}(t)),me(function(t){var e=[];return it(t,[ve.sus,ve.add4])&&e.push("4"),e}(t)),me(function(t,e){var r=[];return t.includes(ve.omit5)?[]:((it(t,[ve.dim,ve.halfDim,ve.fifthFlat])||je(t,e,"b5"))&&r.push("b5"),(it(t,[ve.aug,ve.fifthSharp])||je(t,e,"#5"))&&r.push("#5"),r.length||t.includes(ve.thirteenthFlat)||r.push("5"),r)}(t,e)),me(function(t){var e=[];return it(t,[ve.addb6])&&e.push("b6"),!it(t,[ve.add6,ve.add69])||xe(t)||it(t,[ve.halfDim])||e.push("6"),e}(t)),me(function(t){var e=[];return it(t,[ve.alt])&&e.push("b7"),it(t,[ve.seventh,ve.halfDim])?t.includes(ve.dim)?e.push("bb7"):t.includes(ve.halfDim)?e.push("b7"):e.push(_e(t)):it(t,[ve.ninth,ve.eleventh,ve.thirteenth])&&e.push(_e(t)),t.includes(ve.add7)&&e.push("7"),e}(t)),me(function(t,e){var r=[];return it(t,[ve.add69,ve.ninth,ve.eleventh,ve.thirteenth])&&ut(t,[ve.ninthFlat,ve.ninthSharp])&&r.push("9"),it(t,[ve.sus2,ve.add9])&&r.push("9"),(it(t,[ve.ninthFlat])||je(t,e,"b9"))&&r.push("b9"),(it(t,[ve.ninthSharp])||je(t,e,"#9"))&&r.push("#9"),r}(t,e)),me(function(t,e){var r=[];return(it(t,[ve.thirteenth])&&!we(t)||it(t,[ve.eleventh,ve.add11]))&&r.push("11"),(it(t,[ve.eleventhSharp])||je(t,e,"#11"))&&r.push("#11"),r}(t,e)),me(function(t,e){var r=[];return(it(t,[ve.add13,ve.thirteenth])||it(t,[ve.add6,ve.add69])&&xe(t)||it(t,[ve.add6,ve.add69])&&it(t,[ve.halfDim]))&&r.push("13"),(it(t,[ve.thirteenthFlat])||je(t,e,"b13"))&&r.push("b13"),r}(t,e)))).sort((function(t,e){return be[t]-be[e]}))}(r,t),e.normalized.semitones=e.normalized.intervals.map((function(t){return be[t]})).sort((function(t,e){return t-e})),e.normalized.intents=function(t){return{major:we(t),eleventh:t.includes(ve.eleventh),alt:t.includes(ve.alt)}}(r),e}function _e(t){return t.includes(ve.ma)?"7":"b7"}function je(t,e,r){return t.includes(ve.alt)&&e.includes(r)}function we(t){return ut(t,[ve.mi,ve.dim,ve.dim7,ve.halfDim])}function xe(t){return it(t,[ve.seventh,ve.ninth,ve.eleventh,ve.thirteenth])}function Oe(t){return t.replace(/[.\-*+?^${}()|[\]\\]/g,"\\$&")}function Se(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r0&&void 0!==arguments[0]?arguments[0]:{},r=["b5","#5","b9","#9","#11","b13"],n=["english","german","latin"],a=e.notationSystems,u=void 0===a?o()(n):a,s=e.altIntervals,c=void 0===s?o()(r):s,l=e.customFilters,f=void 0===l?[]:l;return function(t,e){Ae("altIntervals",t,e,!0)}(c,r),function(t,e){Ae("notationSystems",t,e)}(u,n),i(f),function(r){var n,i=[];if(!("string"==typeof(n=r)&&n.length>0)){var a=new K;i.push(Ee(a))}var s,l,h,p,d,v=o()(L).filter((function(t){return u.includes(t.name)}));if(!i.length)for(;v.length&&!s;){h=v.shift(),l=[Ct.bind(null,e),oe.bind(null,h.notes),St,ge.bind(null,c),lt,Nt,Jt,jt,ft,It].concat(function(t){if(Array.isArray(t))return Se(t)}(d=f)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(d)||function(t,e){if(t){if("string"==typeof t)return Se(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Se(t,e):void 0}}(d)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}());try{(s=t(l,r))?s.input.notationSystem=h.name:i.push((p=h.name,Ee(new Z,p)))}catch(a){i.push(Ee(a,h.name))}}return s||{error:i}}};function De(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Ce(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:"none",r=arguments.length>1?arguments[1]:void 0;if("none"===e)return r;var n=Be()(r.normalized.intervals,{max:["4","b5","#5","6","bb7","b7","7","b9","9","#9","11","#11","b13","13"],core:["4","b9","9","#9","11","#11","b13","13"]}[e]);return ut(n,["b3","3"])&&n.push(r.normalized.intents.major?"3":"b3"),ut(n,["b5","5","#5"])&&n.push("5"),r.normalized.intervals=n,r.normalized.semitones=n.map((function(t){return be[t]})),r.normalized.intents.eleventh=!1,r.normalized.intents.alt=!1,"max"===e&&delete r.normalized.bassNote,t([Jt,jt,It],r)}var $e=r(3137),We=["C","C#","D","D#","E","F","F#","G","G#","A","A#","B"],Xe={"C#":"Db","D#":"Eb","F#":"Gb","G#":"Ab","A#":"Bb"},Ve=r.n($e)()(Xe);function Ke(t,e,r){var n=r.normalized,o=n.rootNote,i=n.bassNote,a=Ye(o);if(r.normalized.rootNote=Ze(a,t,e),r.formatted.rootNote=r.normalized.rootNote,i){var u=Ye(i);r.normalized.bassNote=Ze(u,t,e),r.formatted.bassNote=r.normalized.bassNote}return It(r)}function Ze(t,e,r){var n=We.indexOf(t)+e,o=Math.floor(n/12),i=We[n-12*o];return r&&Xe[i]||i}function Ye(t){return Ve[t]||t}var He={german:{Ab:"As",A:"A","A#":"Ais",Bb:"Hes",B:"H",C:"C","C#":"Cis",Db:"Des",D:"D","D#":"Dis",Eb:"Es",E:"E",F:"F","F#":"Fis",Gb:"Ges",G:"G","G#":"Gis"},latin:{Ab:"Lab",A:"La","A#":"La#",Bb:"Sib",B:"Si",C:"Do","C#":"Do#",Db:"Reb",D:"Re","D#":"Re#",Eb:"Mib",E:"Mi",F:"Fa","F#":"Fa#",Gb:"Solb",G:"Sol","G#":"Sol#"}},Je=Object.keys(He);function Qe(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"english",e=arguments.length>1?arguments[1]:void 0,r="auto"===t?e.input.notationSystem:t;return"english"===r?e:Je.includes(r)?(e.formatted.rootNote=He[r][e.formatted.rootNote],e.formatted.bassNote&&(e.formatted.bassNote=He[r][e.formatted.bassNote]),e):null}function tr(t){return t&&t.formatted&&t.formatted.symbol?t.formatted.symbol:null}function er(t){return er="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},er(t)}function rr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r0&&void 0!==arguments[0]?arguments[0]:{},r=e.useShortNamings,n=void 0!==r&&r,a=e.simplify,u=void 0===a?"none":a,s=e.transposeValue,c=void 0===s?0:s,l=e.harmonizeAccidentals,f=void 0!==l&&l,h=e.useFlats,p=void 0!==h&&h,d=e.printer,v=void 0===d?"text":d,b=e.notationSystem,m=void 0===b?"english":b,y=e.customFilters,g=void 0===y?[]:y;i(g);var _,j=[];return["max","core"].includes(u)&&j.push(Ue.bind(null,u)),(f||0!==c)&&j.push(Ke.bind(null,c,p)),n&&j.push(qe),j.push.apply(j,[Qe.bind(null,m),ft].concat(function(t){if(Array.isArray(t))return rr(t)}(_=g)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(_)||function(t,e){if(t){if("string"==typeof t)return rr(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?rr(t,e):void 0}}(_)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())),function(e){if(!function(t){return t&&"object"===er(t)&&!t.error&&t.input}(e))return null;var r=t(j,o()(e));return"raw"===v?function(t){delete t.parserConfiguration.notationSystems;var e=o()(t),r=tr(t),n=ke(t.parserConfiguration)(r);return e.input=n.input,e}(r):tr(r)}}})(),n})()},t.exports=e()},529:t=>{var e=-1,r=1,n=0;function o(t,v,b,m,y){if(t===v)return t?[[n,t]]:[];if(null!=b){var _=function(t,e,r){var n="number"==typeof r?{index:r,length:0}:r.oldRange,o="number"==typeof r?null:r.newRange,i=t.length,a=e.length;if(0===n.length&&(null===o||0===o.length)){var u=n.index,s=t.slice(0,u),c=t.slice(u),l=o?o.index:null,f=u+a-i;if((null===l||l===f)&&!(f<0||f>a)){var h=e.slice(0,f);if((v=e.slice(f))===c){var p=Math.min(u,f);if((m=s.slice(0,p))===(_=h.slice(0,p)))return g(m,s.slice(p),h.slice(p),c)}}if(null===l||l===u){var d=u,v=(h=e.slice(0,d),e.slice(d));if(h===s){var b=Math.min(i-d,a-d);if((y=c.slice(c.length-b))===(j=v.slice(v.length-b)))return g(s,c.slice(0,c.length-b),v.slice(0,v.length-b),y)}}}if(n.length>0&&o&&0===o.length){var m=t.slice(0,n.index),y=t.slice(n.index+n.length);if(!(a<(p=m.length)+(b=y.length))){var _=e.slice(0,p),j=e.slice(a-b);if(m===_&&y===j)return g(m,t.slice(p,i-b),e.slice(p,a-b),y)}}return null}(t,v,b);if(_)return _}var j=a(t,v),w=t.substring(0,j);j=s(t=t.substring(j),v=v.substring(j));var x=t.substring(t.length-j),O=function(t,u){var c;if(!t)return[[r,u]];if(!u)return[[e,t]];var l=t.length>u.length?t:u,f=t.length>u.length?u:t,h=l.indexOf(f);if(-1!==h)return c=[[r,l.substring(0,h)],[n,f],[r,l.substring(h+f.length)]],t.length>u.length&&(c[0][0]=c[2][0]=e),c;if(1===f.length)return[[e,t],[r,u]];var p=function(t,e){var r=t.length>e.length?t:e,n=t.length>e.length?e:t;if(r.length<4||2*n.length=t.length?[n,o,i,u,f]:null}var i,u,c,l,f,h=o(r,n,Math.ceil(r.length/4)),p=o(r,n,Math.ceil(r.length/2));return h||p?(i=p?h&&h[4].length>p[4].length?h:p:h,t.length>e.length?(u=i[0],c=i[1],l=i[2],f=i[3]):(l=i[0],f=i[1],u=i[2],c=i[3]),[u,c,l,f,i[4]]):null}(t,u);if(p){var d=p[0],v=p[1],b=p[2],m=p[3],y=p[4],g=o(d,b),_=o(v,m);return g.concat([[n,y]],_)}return function(t,n){for(var o=t.length,a=n.length,u=Math.ceil((o+a)/2),s=u,c=2*u,l=new Array(c),f=new Array(c),h=0;ho)b+=2;else if(w>a)v+=2;else if(d&&(S=s+p-_)>=0&&S=(O=o-f[S]))return i(t,n,E,w)}for(var x=-g+m;x<=g-y;x+=2){for(var O,S=s+x,A=(O=x===-g||x!==g&&f[S-1]o)y+=2;else if(A>a)m+=2;else if(!d){var E;if((j=s+p-x)>=0&&j=(O=o-O))return i(t,n,E,w)}}}return[[e,t],[r,n]]}(t,u)}(t=t.substring(0,t.length-j),v=v.substring(0,v.length-j));return w&&O.unshift([n,w]),x&&O.push([n,x]),d(O,y),m&&function(t){for(var o=!1,i=[],a=0,v=null,b=0,m=0,y=0,g=0,_=0;b0?i[a-1]:-1,m=0,y=0,g=0,_=0,v=null,o=!0)),b++;for(o&&d(t),function(t){function e(t,e){if(!t||!e)return 6;var r=t.charAt(t.length-1),n=e.charAt(0),o=r.match(c),i=n.match(c),a=o&&r.match(l),u=i&&n.match(l),s=a&&r.match(f),d=u&&n.match(f),v=s&&t.match(h),b=d&&e.match(p);return v||b?5:s||d?4:o&&!a&&u?3:a||u?2:o||i?1:0}for(var r=1;r=y&&(y=g,v=o,b=i,m=a)}t[r-1][1]!=v&&(v?t[r-1][1]=v:(t.splice(r-1,1),r--),t[r][1]=b,m?t[r+1][1]=m:(t.splice(r+1,1),r--))}r++}}(t),b=1;b=O?(x>=j.length/2||x>=w.length/2)&&(t.splice(b,0,[n,w.substring(0,x)]),t[b-1][1]=j.substring(0,j.length-x),t[b+1][1]=w.substring(x),b++):(O>=j.length/2||O>=w.length/2)&&(t.splice(b,0,[n,j.substring(0,O)]),t[b-1][0]=r,t[b-1][1]=w.substring(0,w.length-O),t[b+1][0]=e,t[b+1][1]=j.substring(O),b++),b++}b++}}(O),O}function i(t,e,r,n){var i=t.substring(0,r),a=e.substring(0,n),u=t.substring(r),s=e.substring(n),c=o(i,a),l=o(u,s);return c.concat(l)}function a(t,e){if(!t||!e||t.charAt(0)!==e.charAt(0))return 0;for(var r=0,n=Math.min(t.length,e.length),o=n,i=0;rn?t=t.substring(r-n):r=0&&y(t[p][1])){var v=t[p][1].slice(-1);if(t[p][1]=t[p][1].slice(0,-1),f=v+f,h=v+h,!t[p][1]){t.splice(p,1),u--;var b=p-1;t[b]&&t[b][0]===r&&(l++,h=t[b][1]+h,b--),t[b]&&t[b][0]===e&&(c++,f=t[b][1]+f,b--),p=b}}m(t[u][1])&&(v=t[u][1].charAt(0),t[u][1]=t[u][1].slice(1),f+=v,h+=v)}if(u0||h.length>0){f.length>0&&h.length>0&&(0!==(i=a(h,f))&&(p>=0?t[p][1]+=h.substring(0,i):(t.splice(0,0,[n,h.substring(0,i)]),u++),h=h.substring(i),f=f.substring(i)),0!==(i=s(h,f))&&(t[u][1]=h.substring(h.length-i)+t[u][1],h=h.substring(0,h.length-i),f=f.substring(0,f.length-i)));var g=l+c;0===f.length&&0===h.length?(t.splice(u-g,g),u-=g):0===f.length?(t.splice(u-g,g,[r,h]),u=u-g+1):0===h.length?(t.splice(u-g,g,[e,f]),u=u-g+1):(t.splice(u-g,g,[e,f],[r,h]),u=u-g+2)}0!==u&&t[u-1][0]===n?(t[u-1][1]+=t[u][1],t.splice(u,1)):u++,l=0,c=0,f="",h=""}""===t[t.length-1][1]&&t.pop();var _=!1;for(u=1;u=55296&&t<=56319}function b(t){return t>=56320&&t<=57343}function m(t){return b(t.charCodeAt(0))}function y(t){return v(t.charCodeAt(t.length-1))}function g(t,o,i,a){return y(t)||m(a)?null:function(t){for(var e=[],r=0;r0&&e.push(t[r]);return e}([[n,t],[e,o],[r,i],[n,a]])}function _(t,e,r,n){return o(t,e,r,n,!0)}_.INSERT=r,_.DELETE=e,_.EQUAL=n,t.exports=_},308:function(t,e){var r,n;"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self&&self,r=function(t){"use strict";function e(t){return function(t){if(Array.isArray(t))return r(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return r(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function r(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r0&&void 0!==arguments[0]?arguments[0]:"",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if("string"!=typeof t)return t;var r=new RegExp("(".concat(Object.keys(e).join("|"),")(?!(\\w|#)*;)"),"g");return String(t).replace(r,(function(t,r){return e[r]||""}))},d=function(){var t=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1?arguments[1]:void 0;return Array.isArray(t)?t.map((function(t){var r=Object.keys(t)[0],n=t[r],o=e?p(n,e):n,i=!0===o?"":'="'.concat(o,'"');return"".concat(r).concat(i)})):Object.keys(t).map((function(r){var n=e?p(t[r],e):t[r],o=!0===t[r]?"":'="'.concat(n,'"');return"".concat(r).concat(o)}))}(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},arguments.length>1?arguments[1]:void 0);if(0===t.length)return"";var e=t.join(" ");return" ".concat(e)},v=["string","number",u],b=function(t){return v.includes(h(t))},m=([].concat(v,[s,c]),function(t){return!t.match("<")}),y={"<":"<",">":">","&":"&"},g=function t(){var r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=n.depth,s=void 0===i?0:i,c=n.indent,v=n._isFirstItem,g=n._isOutputStart,_=void 0===g||g,j=n.header,w=n.attributesFilter,x=void 0===w?{}:w,O=n.filter,S=void 0===O?{}:O,A="boolean"!=typeof x||x?o(o(o({},y),{'"':"""}),x):{},E="boolean"!=typeof S||S?o(o({},y),S):{},k=function(){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"").repeat(t)}(c,s),D=h(r),C=function(t){var e=t.header,r=(t.indent,t.isOutputStart);return e&&r?a(e)===u?'':e:""}({header:j,indent:c,depth:s,isOutputStart:_}),P=_&&!C&&v&&0===s,z="";switch(D){case"special-object":var F=r._name,T=r._content;if(null===T){z=F;break}if(Array.isArray(T)&&T.every(b))return T.map((function(e){return t({_name:F,_content:e},o(o({},n),{},{depth:s,_isOutputStart:!1}))})).join("");if(F.match(f))break;var M=t(T,o(o({},n),{},{depth:s+1,_isOutputStart:P})),L=h(M),I=m(M),N="".concat(c&&!P?"\n":"").concat(k);if("_comment"===F){z+="".concat(N,"\x3c!-- ").concat(T," --\x3e");break}var R="undefined"===L||""===M,q=a(r._selfCloseTag)===u?R&&r._selfCloseTag:R,G=q?"/":"",B=d(r._attrs,A),U="<".concat(F).concat(B).concat(G,">"),$=c&&!I?"\n".concat(k):"",W=q?"":"".concat(M).concat($,"");z+="".concat(N).concat(U).concat(W);break;case"object":var X=Object.keys(r);z=X.map((function(i,a){var u=o(o({},n),{},{_isFirstItem:0===a,_isLastItem:a+1===X.length,_isOutputStart:P}),s={_name:i};if("object"===h(r[i])&&(l.forEach((function(t){var e=r[i][t];void 0!==e&&(s[t]=e,delete r[i][t])})),void 0!==r[i]._content&&Object.keys(r[i]).length>1)){var c=Object.assign({},r[i]);delete c._content,s._content=[].concat(e(function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object.keys(t).map((function(e){return{_name:e,_content:t[e]}}))}(c)),[r[i]._content])}return void 0===s._content&&(s._content=r[i]),t(s,u,i)}),n).join("");break;case"function":var V=r(n);z=t(V,n);break;case"array":z=r.map((function(e,i){var a=o(o({},n),{},{_isFirstItem:0===i,_isLastItem:i+1===r.length,_isOutputStart:P});return t(e,a)})).join("");break;default:z=p(r,E)}return"".concat(C).concat(z)};t.toXML=g;var _={toXML:g};t.default=_},void 0===(n=r.apply(e,[e]))||(t.exports=n)},259:(t,e,r)=>{"use strict";t.exports=r(159)},434:(t,e,r)=>{"use strict";var n=r(723);function o(){}var i=null,a={};function u(t){if("object"!=typeof this)throw new TypeError("Promises must be constructed via new");if("function"!=typeof t)throw new TypeError("Promise constructor's argument is not a function");this._x=0,this._y=0,this._z=null,this._A=null,t!==o&&p(t,this)}function s(t,e){for(;3===t._y;)t=t._z;if(u._B&&u._B(t),0===t._y)return 0===t._x?(t._x=1,void(t._A=e)):1===t._x?(t._x=2,void(t._A=[t._A,e])):void t._A.push(e);!function(t,e){n((function(){var r=1===t._y?e.onFulfilled:e.onRejected;if(null!==r){var n=function(t,e){try{return t(e)}catch(t){return i=t,a}}(r,t._z);n===a?l(e.promise,i):c(e.promise,n)}else 1===t._y?c(e.promise,t._z):l(e.promise,t._z)}))}(t,e)}function c(t,e){if(e===t)return l(t,new TypeError("A promise cannot be resolved with itself."));if(e&&("object"==typeof e||"function"==typeof e)){var r=function(t){try{return t.then}catch(t){return i=t,a}}(e);if(r===a)return l(t,i);if(r===t.then&&e instanceof u)return t._y=3,t._z=e,void f(t);if("function"==typeof r)return void p(r.bind(e),t)}t._y=1,t._z=e,f(t)}function l(t,e){t._y=2,t._z=e,u._C&&u._C(t,e),f(t)}function f(t){if(1===t._x&&(s(t,t._A),t._A=null),2===t._x){for(var e=0;e{"use strict";var n=r(434);t.exports=n,n.prototype.done=function(t,e){(arguments.length?this.then.apply(this,arguments):this).then(null,(function(t){setTimeout((function(){throw t}),0)}))}},803:(t,e,r)=>{"use strict";var n=r(434);t.exports=n;var o=l(!0),i=l(!1),a=l(null),u=l(void 0),s=l(0),c=l("");function l(t){var e=new n(n._D);return e._y=1,e._z=t,e}n.resolve=function(t){if(t instanceof n)return t;if(null===t)return a;if(void 0===t)return u;if(!0===t)return o;if(!1===t)return i;if(0===t)return s;if(""===t)return c;if("object"==typeof t||"function"==typeof t)try{var e=t.then;if("function"==typeof e)return new n(e.bind(t))}catch(t){return new n((function(e,r){r(t)}))}return l(t)};var f=function(t){return"function"==typeof Array.from?(f=Array.from,Array.from(t)):(f=function(t){return Array.prototype.slice.call(t)},Array.prototype.slice.call(t))};function h(t){return{status:"fulfilled",value:t}}function p(t){return{status:"rejected",reason:t}}function d(t){if(t&&("object"==typeof t||"function"==typeof t)){if(t instanceof n&&t.then===n.prototype.then)return t.then(h,p);var e=t.then;if("function"==typeof e)return new n(e.bind(t)).then(h,p)}return h(t)}function v(t){if("function"==typeof AggregateError)return new AggregateError(t,"All promises were rejected");var e=new Error("All promises were rejected");return e.name="AggregateError",e.errors=t,e}n.all=function(t){var e=f(t);return new n((function(t,r){if(0===e.length)return t([]);var o=e.length;function i(a,u){if(u&&("object"==typeof u||"function"==typeof u)){if(u instanceof n&&u.then===n.prototype.then){for(;3===u._y;)u=u._z;return 1===u._y?i(a,u._z):(2===u._y&&r(u._z),void u.then((function(t){i(a,t)}),r))}var s=u.then;if("function"==typeof s)return void new n(s.bind(u)).then((function(t){i(a,t)}),r)}e[a]=u,0==--o&&t(e)}for(var a=0;a{"use strict";var n=r(434);t.exports=n,n.prototype.finally=function(t){return this.then((function(e){return n.resolve(t()).then((function(){return e}))}),(function(e){return n.resolve(t()).then((function(){throw e}))}))}},159:(t,e,r)=>{"use strict";t.exports=r(434),r(445),r(29),r(803),r(490),r(690)},490:(t,e,r)=>{"use strict";var n=r(434),o=r(272);t.exports=n,n.denodeify=function(t,e){return"number"==typeof e&&e!==1/0?function(t,e){for(var r=[],o=0;o "+e+") {","args = new Array(arguments.length + 1);","for (var i = 0; i < arguments.length; i++) {","args[i] = arguments[i];","}","}","return new Promise(function (rs, rj) {","var cb = "+i+";","var res;","switch (argLength) {",r.concat(["extra"]).map((function(t,e){return"case "+e+":res = fn.call("+["self"].concat(r.slice(0,e)).concat("cb").join(",")+");break;"})).join(""),"default:","args[argLength] = cb;","res = fn.apply(self, args);","}","if (res &&",'(typeof res === "object" || typeof res === "function") &&','typeof res.then === "function"',") {rs(res);}","});","};"].join("");return Function(["Promise","fn"],a)(n,t)}(t)};var i="function (err, res) {if (err) { rj(err); } else { rs(res); }}";n.nodeify=function(t){return function(){var e=Array.prototype.slice.call(arguments),r="function"==typeof e[e.length-1]?e.pop():null,i=this;try{return t.apply(this,arguments).nodeify(r,i)}catch(t){if(null==r)return new n((function(e,r){r(t)}));o((function(){r.call(i,t)}))}}},n.prototype.nodeify=function(t,e){if("function"!=typeof t)return this;this.then((function(r){o((function(){t.call(e,null,r)}))}),(function(r){o((function(){t.call(e,r)}))}))}},690:(t,e,r)=>{"use strict";var n=r(434);t.exports=n,n.enableSynchronous=function(){n.prototype.isPending=function(){return 0==this.getState()},n.prototype.isFulfilled=function(){return 1==this.getState()},n.prototype.isRejected=function(){return 2==this.getState()},n.prototype.getValue=function(){if(3===this._y)return this._z.getValue();if(!this.isFulfilled())throw new Error("Cannot get a value of an unfulfilled promise.");return this._z},n.prototype.getReason=function(){if(3===this._y)return this._z.getReason();if(!this.isRejected())throw new Error("Cannot get a rejection reason of a non-rejected promise.");return this._z},n.prototype.getState=function(){return 3===this._y?this._z.getState():-1===this._y||-2===this._y?0:this._y}},n.disableSynchronous=function(){n.prototype.isPending=void 0,n.prototype.isFulfilled=void 0,n.prototype.isRejected=void 0,n.prototype.getValue=void 0,n.prototype.getReason=void 0,n.prototype.getState=void 0}},666:t=>{var e=function(t){"use strict";var e,r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",u=i.asyncIterator||"@@asyncIterator",s=i.toStringTag||"@@toStringTag";function c(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{c({},"")}catch(t){c=function(t,e,r){return t[e]=r}}function l(t,e,r,n){var i=e&&e.prototype instanceof m?e:m,a=Object.create(i.prototype),u=new C(n||[]);return o(a,"_invoke",{value:A(t,r,u)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=l;var h="suspendedStart",p="suspendedYield",d="executing",v="completed",b={};function m(){}function y(){}function g(){}var _={};c(_,a,(function(){return this}));var j=Object.getPrototypeOf,w=j&&j(j(P([])));w&&w!==r&&n.call(w,a)&&(_=w);var x=g.prototype=m.prototype=Object.create(_);function O(t){["next","throw","return"].forEach((function(e){c(t,e,(function(t){return this._invoke(e,t)}))}))}function S(t,e){function r(o,i,a,u){var s=f(t[o],t,i);if("throw"!==s.type){var c=s.arg,l=c.value;return l&&"object"==typeof l&&n.call(l,"__await")?e.resolve(l.__await).then((function(t){r("next",t,a,u)}),(function(t){r("throw",t,a,u)})):e.resolve(l).then((function(t){c.value=t,a(c)}),(function(t){return r("throw",t,a,u)}))}u(s.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function A(t,e,r){var n=h;return function(o,i){if(n===d)throw new Error("Generator is already running");if(n===v){if("throw"===o)throw i;return z()}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var u=E(a,r);if(u){if(u===b)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(n===h)throw n=v,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n=d;var s=f(t,e,r);if("normal"===s.type){if(n=r.done?v:p,s.arg===b)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n=v,r.method="throw",r.arg=s.arg)}}}function E(t,r){var n=r.method,o=t.iterator[n];if(o===e)return r.delegate=null,"throw"===n&&t.iterator.return&&(r.method="return",r.arg=e,E(t,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),b;var i=f(o,t.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,b;var a=i.arg;return a?a.done?(r[t.resultName]=a.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,b):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,b)}function k(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function D(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function C(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(k,this),this.reset(!0)}function P(t){if(t){var r=t[a];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,i=function r(){for(;++o=0;--i){var a=this.tryEntries[i],u=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var s=n.call(a,"catchLoc"),c=n.call(a,"finallyLoc");if(s&&c){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),D(r),b}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;D(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:P(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),b}},t}(t.exports);try{regeneratorRuntime=e}catch(t){"object"==typeof globalThis?globalThis.regeneratorRuntime=e:Function("r","regeneratorRuntime = r")(e)}}},e={};function r(n){var o=e[n];if(void 0!==o)return o.exports;var i=e[n]={exports:{}};return t[n].call(i.exports,i,i.exports,r),i.exports}r.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return r.d(e,{a:e}),e},r.d=(t,e)=>{for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var n={};return(()=>{"use strict";r.r(n),r.d(n,{Cell:()=>d,Chord:()=>v,LogLevel:()=>P,MusicXML:()=>z,Playlist:()=>p,Song:()=>b,convert:()=>I,convertSync:()=>L});var t,e=r(259),o=r.n(e),i=r(529),a=r.n(i);function u(t){return u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},u(t)}function s(t,e,r){return(e=f(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function c(t,e){for(var r=0;r1&&(this.name=n.pop()),this.songs=n.map((function(t){try{return new b(t,"irealbook"===r[1])}catch(r){var e=t.split("="),n=b.parseTitle(e[0].trim());return console.error("[ireal-musicxml] [".concat(n,"] ").concat(r.toString())),null}})).filter((function(t){return null!==t})).reduce((function(t,e){if(t.length>0){var r=a()(t[t.length-1].title,e.title);if(0===r[0][0]&&r.every((function(t){return 0===t[0]||t[1].match(/^\d+$/)})))return t[t.length-1].cells=t[t.length-1].cells.concat(e.cells),t}return t.push(e),t}),[])})),d=l((function t(){h(this,t),this.annots=[],this.comments=[],this.bars="",this.spacer=0,this.chord=null})),v=l((function t(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;h(this,t),this.note=e,this.modifiers=r,this.over=n,this.alternate=o})),b=function(){function t(e){var r=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(h(this,t),this.cells=[],this.musicXml="",!e)return this.title="",this.composer="",this.style="",this.key="",this.transpose=0,this.groove="",this.bpm=0,void(this.repeats=0);var n=e.split("=");if(r)this.title=t.parseTitle(n[0].trim()),this.composer=t.parseComposer(n[1].trim()),this.style=n[2].trim(),this.key=n[3],this.cells=this.parse(n[5]);else{this.title=t.parseTitle(n[0].trim()),this.composer=t.parseComposer(n[1].trim()),this.style=n[3].trim(),this.key=n[4],this.transpose=+n[5]||0,this.groove=n[7],this.bpm=+n[8],this.repeats=+n[9]||3;var o=n[6].split("1r34LbKcu7");this.cells=this.parse(function(t){for(var e,r="";t.length>51;)e=t.substring(0,50),t=t.substring(50),r+=m(e);return(r+=t).replace(/Kcl/g,"| x").replace(/LZ/g," |").replace(/XyQ/g," ")}(o[1]))}}return l(t,[{key:"parse",value:function(e){for(var r=e.trim(),n=[];r;){for(var o=!1,i=0;i/,t.chordRegex,t.chordRegex2]);var y=r(308),g=r(13);var _;function j(t){return j="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},j(t)}function w(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function x(t){for(var e=1;et.length)&&(e=t.length);for(var r=0,n=new Array(e);r\n\n ').trim(),indent:" "})}},{key:"convertSong",value:function(){return{_name:"score-partwise",_attrs:{version:"4.0"},_content:[{work:{"work-title":this.song.title}},{identification:[{_name:"creator",_attrs:{type:"composer"},_content:this.song.composer},{encoding:[{software:"@infojunkie/ireal-musicxml ".concat("1.12.0")},{"encoding-date":t.convertDate(new Date)},{_name:"supports",_attrs:{element:"accidental",type:"no"}},{_name:"supports",_attrs:{element:"transpose",type:"no"}},{_name:"supports",_attrs:{attribute:"new-page",element:"print",type:"yes",value:"yes"}},{_name:"supports",_attrs:{attribute:"new-system",element:"print",type:"yes",value:"yes"}}]}]},{defaults:{scaling:{millimeters:7,tenths:40}}},{"part-list":{_name:"score-part",_attrs:{id:"P1"},_content:{_name:"part-name",_attrs:{"print-object":"no"},_content:"Lead sheet"}}},{_name:"part",_attrs:{id:"P1"},_content:this.convertMeasures()}]}}},{key:"convertMeasures",value:function(){var e=this,r=this.song.cells.reduce((function(r,n,o){if((n.bars.match(/\(|\{|\[/)||!e.measure&&(n.chord||n.annots.length||n.comments.length))&&(e.measure&&(e._log(P.Warn,"Starting a new measure over existing measure. Closing current measure first."),e.measure.barlines.push(e.convertBarline("","right")),e.adjustChordsDuration(e.measure)&&r.push(e.measure)),e.measure=new t.Measure(r.length+1),r.length||(e.measure.attributes.push({divisions:e.options.divisions},{clef:[{sign:"G"},{line:2}]},{"measure-style":[{_name:"slash",_attrs:{type:"start","use-stems":"rhythmic"===e.options.notation?"yes":"no"}}]},e.convertKey()),e.song.bpm&&e.measure.body._content.push(e.convertTempo(e.song.bpm)),e.measure.body._content.push(e.convertStyleAndGroove(e.song.style,e.song.groove))),e.measure.barlines.push(e.convertBarline(n.bars,"left")),e.barRepeat&&(e.measure.chords=O(r[r.length-e.barRepeat-1].chords))),!e.measure)return(n.chord||n.annots.length||n.comments.length||n.bars&&")"!==n.bars)&&e._log(P.Warn,"Found non-empty orphan cell ".concat(JSON.stringify(n)),r[r.length-1]),r;if(o>0&&o%16==0&&e.measure.body._content.splice(0,0,{_name:"print",_attrs:{"new-system":"yes"}}),n.chord)switch(n.chord.note){case"x":e.barRepeat=1,e.measure.chords=O(r[r.length-e.barRepeat].chords);break;case"r":e.barRepeat=2,e.measure.chords=O(r[r.length-e.barRepeat].chords);break;case"p":if(e.measure.chords.length){e.measure.chords[e.measure.chords.length-1].spaces++;break}case"W":var i=e.measure;i.chords.length||(i=r.slice().reverse().find((function(t){return t.chords.length})))||e._log(P.Error,"Cannot find any measure with chords prior to ".concat(JSON.stringify(n.chord)));var a=i.chords[i.chords.length-1].ireal;a.over=n.chord.over,a.alternate=n.chord.alternate,e.measure.chords.push(e.convertChord(a));break;case" ":e._log(P.Warn,"Unhandled empty/alternate chord ".concat(JSON.stringify(n.chord)));break;default:e.measure.chords.push(e.convertChord(n.chord))}else e.barRepeat||e.measure.chords.length&&e.measure.chords[e.measure.chords.length-1].spaces++;return n.annots.forEach((function(t){switch(t[0]){case"*":var n=t.slice(1);e.measure.body._content.push(e.convertSection(n));break;case"T":var o=t.slice(1);e.measure.attributes.push(e.convertTime(o));break;case"S":e.measure.body._content.push(e.convertSegno());break;case"N":var i=parseInt(t.slice(1));if(e.measure.barlines[0]._content.push(e.convertEnding(i,"start")),i>1){r[r.length-1].barlines[1]._content.push(e.convertEnding(i-1,"stop"));var a=r.slice().reverse().find((function(t){return t.barEnding===i-1}));a||e._log(P.Error,"Cannot find ending ".concat(i-1," in right barline of any measure"));var u=a.barlines[1]._content.findIndex((function(t){return"ending"===t._name}));-1===u&&e._log(P.Error,"Cannot find ending ".concat(i-1," in right barline"),a),delete a.barlines[1]._content[u]}e.measure.barEnding=i;break;case"Q":e.measure.body._content.push(e.convertToCoda()),e.codas.push(e.measure);break;case"l":case"s":break;case"f":e.measure.chords[e.measure.chords.length-1].fermata=!0;break;case"U":e.measure.body._content.push(e.convertFine("END"));break;default:e._log(P.Warn,'Unhandled annotation "'.concat(t,'"'))}})),n.comments.map((function(t){return t.trim()})).forEach((function(r){var n=e._map(t.mapRepeats,r);n?e.measure.body._content.push(n.call(e,r)):e.measure.body._content.push(e.convertComment(r))})),n.bars.match(/\)|\}|\]|Z/)&&e.measure.chords.length&&(e.measure.barlines.push(e.convertBarline(n.bars,"right")),e.measure.barEnding&&e.measure.barlines[1]._content.push(e.convertEnding(e.measure.barEnding,"discontinue")),e.adjustChordsDuration(e.measure)&&r.push(e.measure),e.measure=null,e.barRepeat&&e.barRepeat--),r}),[]);if(this.codas.length){var n=this.codas[this.codas.length-1],o=n.body._content.findIndex((function(t){return"direction"===t._name&&Array.isArray(t._content)&&t._content.some((function(t){return"sound"===t._name&&Object.keys(t._attrs).includes("tocoda")}))}));-1===o&&this._log(P.Warn,"Cannot find sound direction",n),n.body._content[o]=this.convertCoda()}return r.map((function(t){return t.assemble()}))}},{key:"convertRepeatNx",value:function(t){var e;null!==(e=t.match(/(\d+)x/))&&(this.repeats=e[1])}},{key:"convertFine",value:function(t){return{_name:"direction",_attrs:{placement:"below"},_content:[{"direction-type":{words:t}},{_name:"sound",_attrs:{fine:"yes"}}]}}},{key:"convertDaCapo",value:function(t){return{_name:"direction",_attrs:{placement:"below"},_content:[{"direction-type":{words:t}},{_name:"sound",_attrs:{dacapo:"yes"}}]}}},{key:"convertDalSegno",value:function(t){return{_name:"direction",_attrs:{placement:"below"},_content:[{"direction-type":{words:t}},{_name:"sound",_attrs:{dalsegno:"yes"}}]}}},{key:"convertComment",value:function(t){var e="*"===t[0]?t.slice(3):t;return{_name:"direction",_attrs:{placement:"*"===t[0]?"above":"below"},_content:{"direction-type":{words:e}}}}},{key:"convertEnding",value:function(t,e){return{_name:"ending",_attrs:{number:t,type:e},_content:"".concat(t,".")}}},{key:"convertBarline",value:function(t,e){var r="left"===e?"none":"regular",n=null;return t.match(/\[|\]/)?r="light-light":t.match(/Z/)?r="light-heavy":t.match(/\{|\}/)&&(r="left"===e?"heavy-light":"light-heavy",n="left"===e?"forward":"backward"),"forward"===n&&(this.repeats=2),{_name:"barline",_attrs:{location:e},_content:[{"bar-style":r},x({},n&&{_name:"repeat",_attrs:x({direction:n},"backward"===n&&{times:this.repeats})})]}}},{key:"convertSection",value:function(t){return"i"===t&&(t="Intro"),{_name:"direction",_attrs:{placement:"above"},_content:{"direction-type":{rehearsal:t}}}}},{key:"convertSegno",value:function(){return{_name:"direction",_attrs:{placement:"above"},_content:[{"direction-type":{_name:"segno"}},{_name:"sound",_attrs:{segno:"segno"}}]}}},{key:"convertCoda",value:function(){return{_name:"direction",_attrs:{placement:"above"},_content:[{"direction-type":{_name:"coda"}},{_name:"sound",_attrs:{coda:"coda"}}]}}},{key:"convertToCoda",value:function(){return{_name:"direction",_attrs:{placement:"above"},_content:[{"direction-type":{words:"To Coda"}},{_name:"sound",_attrs:{tocoda:"coda"}}]}}},{key:"convertTempo",value:function(t){return{_name:"direction",_attrs:{placement:"above"},_content:[{"direction-type":[{_name:"metronome",_attrs:{parentheses:"no"},_content:[{"beat-unit":this.calculateChordDuration(1)[0].type},{"per-minute":t}]}]},{_name:"sound",_attrs:{tempo:t}}]}}},{key:"convertTime",value:function(t){var e=parseInt(t[0]),r=parseInt(t[1]);return"12"===t&&(e=12,r=8),this.time={beats:e,beatType:r},{time:[{beats:e},{"beat-type":r}]}}},{key:"adjustChordsDuration",value:function(t){var e=this;if(t.chords.length>this.time.beats)return this._log(P.Error,"Too many chords (".concat(t.chords.length," out of ").concat(this.time.beats,")"),t),!0;var r=t.chords.reduce((function(t,e){return t+1+e.spaces}),0);if(!r)return this._log(P.Warn,"No chord found. Skipping current measure.",t),!1;if(r>this.time.beats)for(var n=0;r>this.time.beats;)t.chords[n].spaces>0&&(t.chords[n].spaces--,r--),n=(n+1)%t.chords.length;else for(var o=0;r1?n>0?"stop":"start":null)})),t})),!0}},{key:"calculateChordDuration",value:function(t){var e=this,r={1:[{t:"eighth",d:0,b:1}],2:[{t:"quarter",d:0,b:2}],3:[{t:"quarter",d:1,b:3}],4:[{t:"half",d:0,b:4}],5:[{t:"quarter",d:1,b:3},{t:"quarter",d:0,b:2}],6:[{t:"half",d:1,b:6}],7:[{t:"half",d:2,b:7}],8:[{t:"whole",d:0,b:8}],9:[{t:"half",d:1,b:6},{t:"quarter",d:1,b:3}],10:[{t:"half",d:1,b:6},{t:"half",d:0,b:4}],11:[{t:"half",d:2,b:7},{t:"half",d:0,b:4}],12:[{t:"whole",d:1,b:12}],13:[{t:"half",d:2,b:7},{t:"half",d:1,b:6}],14:[{t:"whole",d:2,b:14}],15:[{t:"whole",d:0,b:8},{t:"half",d:2,b:7}]};if("slash"===this.options.notation){var n=8/this.time.beatType;return Array(t).fill(this._map(r,n,[],"Unexpected beat count 1 for time signature ".concat(this.time.beats,"/").concat(this.time.beatType)).map((function(t){return{duration:t.b*e.options.divisions/2,type:t.t,dots:t.d}}))[0])}var o=8*t/this.time.beatType;return this._map(r,o,[],"Unexpected beat count ".concat(t," for time signature ").concat(this.time.beats,"/").concat(this.time.beatType)).map((function(t){return{duration:t.b*e.options.divisions/2,type:t.t,dots:t.d}}))}},{key:"convertChordNote",value:function(e){var r=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,o={_name:"pitch",_content:[{step:this.options.step},{alter:this._map(t.mapFifthsToAlters,this.fifths,[],"Unhandled fifths count=".concat(this.fifths)).includes(this.options.step)?this.fifths>0?1:-1:0},{octave:this.options.octave}]},i=[];return r&&i.push({_name:"fermata"}),n&&i.push({_name:"tied",_attrs:{type:n}}),t.reorderSequence(this.measure,[o,{_name:"cue"},{notehead:this.options.notehead},{duration:e.duration},{voice:1},{_name:"type",_attrs:{size:"full"},_content:e.type},x({},i.length&&{notations:t.reorderSequence(this.measure,i,t.sequenceNotations)})].concat(Array(e.dots).fill({_name:"dot"})),t.sequenceNote)}},{key:"convertChordDegree",value:function(t,e,r){return{_name:"degree",_attrs:{"print-object":"no"},_content:[{"degree-value":t},{"degree-alter":r},{"degree-type":e}]}}},{key:"convertChordSymbol",value:function(e){var r=this,n=this.renderChord(this.parseChord("".concat(e.note).concat(e.modifiers)));if(!n)return this._log(P.Warn,'Unrecognized chord "'.concat(e.note).concat(e.modifiers,'"')),{rootStep:null,rootAlter:null,chordKind:null,chordDegrees:[],chordText:null};var o=n.input.rootNote[0],i=this._map(t.mapAlter,n.input.rootNote[1]||null,null,'Unrecognized accidental in chord "'.concat(n.input.rootNote,'"')),a=n.formatted.descriptor+n.formatted.chordChanges.join(""),u=this._map({major:"major",major6:"major-sixth",major7:"major-seventh",dominant7:"dominant",minor:"minor",minor6:"minor-sixth",minor7:"minor-seventh",minorMajor7:"major-minor",augmented:"augmented",diminished:"diminished",diminished7:"diminished-seventh",power:"power"},n.normalized.quality,"",'Unrecognized chord quality "'.concat(n.normalized.quality,'"'));if(n.normalized.extensions.length){var s=Math.max.apply(Math,O(n.normalized.extensions.map((function(t){return parseInt(t)})))).toString();"dominant-11th"===(u=u.split("-")[0]+this._map({9:"-ninth",11:"-11th",13:"-13th"},s,"","Unhandled extension ".concat(s)))&&(n.normalized.isSuspended=!1)}[{intervals:["1","4","5"],kind:"suspended-fourth",strict:!0},{intervals:["1","5","9"],kind:"suspended-second",strict:!0},{intervals:["1","b3","b5","b7"],kind:"half-diminished",strict:!0},{intervals:["1","3","#5","b7"],kind:"augmented-seventh",strict:!1}].some((function(t){if((!t.strict||n.normalized.intervals.length===t.intervals.length)&&t.intervals.every((function(t,e){return t===n.normalized.intervals[e]})))return u=t.kind,t.intervals.forEach((function(t){n.normalized.alterations=n.normalized.alterations.filter((function(e){return e===t})),n.normalized.adds=n.normalized.adds.filter((function(e){return e===t})),n.normalized.omits=n.normalized.omits.filter((function(e){return e===t}))})),n.normalized.intervals.forEach((function(e){t.intervals.includes(e)||n.normalized.adds.push(e)})),!0}));var c=[];return n.normalized.isSuspended&&!u.includes("suspended")&&(n.normalized.adds.push("4"),n.normalized.adds.includes("3")||n.normalized.omits.push("3")),n.normalized.alterations.forEach((function(e){var o=e.slice(1);c.push(r.convertChordDegree(o,"5"===o||n.normalized.extensions.includes(o)?"alter":"add",r._map(t.mapAlter,e[0],0,'Unrecognized alter symbol in "'.concat(e,'"'))))})),n.normalized.adds.forEach((function(e){var n=Object.keys(t.mapAlter).includes(e[0])?e[0]:null,o=n?e.slice(1):e;c.push(r.convertChordDegree(o,"add",r._map(t.mapAlter,n,0,'Unrecognized alter symbol in "'.concat(e,'"'))))})),n.normalized.omits.forEach((function(e){var n=Object.keys(t.mapAlter).includes(e[0])?e[0]:null,o=n?e.slice(1):e;c.push(r.convertChordDegree(o,"subtract",r._map(t.mapAlter,n,0,'Unrecognized alter symbol in "'.concat(e,'"'))))})),{rootStep:o,rootAlter:i,chordKind:u,chordDegrees:c,chordText:a}}},{key:"convertChord",value:function(e){var r=this,n=null;if("n"===e.note)n=[{root:[{_name:"root-step",_attrs:{text:""},_content:this.options.step}]},{_name:"kind",_attrs:{text:"N.C."},_content:"none"}];else{var o=this.convertChordSymbol(e),i=o.rootStep,a=o.rootAlter,u=o.chordKind,s=o.chordDegrees,c=o.chordText,l=e.over?[{"bass-step":e.over.note[0]},x({},e.over.note[1]&&{"bass-alter":this._map(t.mapAlter,e.over.note[1],null,'Unrecognized accidental in bass note "'.concat(e.over.note,'"'))})]:null;n=[{root:[{"root-step":i},x({},a&&{"root-alter":a})]},{_name:"kind",_attrs:{text:c,"use-symbols":"no"},_content:u},x({},l&&{bass:l})].concat(s)}return e.alternate&&this._log(P.Warn,"Unhandled alternate chord ".concat(JSON.stringify(e.alternate))),new t.Chord(n,this.calculateChordDuration(1).map((function(t){return r.convertChordNote(t)})),e)}},{key:"convertKey",value:function(){return this.fifths=this._map({C:0,G:1,D:2,A:3,E:4,B:5,"F#":6,"C#":7,F:-1,Bb:-2,Eb:-3,Ab:-4,Db:-5,Gb:-6,Cb:-7,"A-":0,"E-":1,"B-":2,"F#-":3,"C#-":4,"G#-":5,"D#-":6,"A#-":7,"D-":-1,"G-":-2,"C-":-3,"F-":-4,"Bb-":-5,"Eb-":-6,"Ab-":-7},this.song.key,0,'Unrecognized key signature "'.concat(this.song.key,'"')),{key:[{fifths:this.fifths},{mode:"-"===this.song.key.slice(-1)?"minor":"major"}]}}},{key:"convertStyleAndGroove",value:function(t,e){return{_name:"direction",_attrs:{placement:"above"},_content:[{"direction-type":[{words:t}]},{sound:[{play:[{_name:"other-play",_attrs:{type:"groove"},_content:e||t}]}]}]}}},{key:"_log",value:function(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.measure;if(!(t4&&void 0!==arguments[4]?arguments[4]:P.Warn,i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:this.measure;return e?e in t?t[e]:(n&&this._log(o,n,i),r||null):r}}],[{key:"convert",value:function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return new t(e,Object.assign({},this.defaultOptions,r)).convert()}},{key:"convertDate",value:function(t){return new Date(t.getTime()-6e4*t.getTimezoneOffset()).toISOString().split("T")[0]}},{key:"reorderSequence",value:function(t,e,r){var n=this;return e.filter((function(t){return Object.keys(t).length})).sort((function(e,o){var i=Object.keys(e)[0];"_name"===i&&(i=e[i]);var a=Object.keys(o)[0];"_name"===a&&(a=o[a]);var u=r.indexOf(i),s=r.indexOf(a);return-1===u&&n._log(P.Warn,'Unrecognized element "'.concat(i,'"'),t),-1===s&&n._log(P.Warn,'Unrecognized element "'.concat(a,'"'),t),u-s}))}}]),t}();function F(t){return F="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},F(t)}function T(){T=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",u=i.asyncIterator||"@@asyncIterator",s=i.toStringTag||"@@toStringTag";function c(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{c({},"")}catch(t){c=function(t,e,r){return t[e]=r}}function l(t,e,r,n){var i=e&&e.prototype instanceof m?e:m,a=Object.create(i.prototype),u=new C(n||[]);return o(a,"_invoke",{value:A(t,r,u)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=l;var h="suspendedStart",p="suspendedYield",d="executing",v="completed",b={};function m(){}function y(){}function g(){}var _={};c(_,a,(function(){return this}));var j=Object.getPrototypeOf,w=j&&j(j(P([])));w&&w!==r&&n.call(w,a)&&(_=w);var x=g.prototype=m.prototype=Object.create(_);function O(t){["next","throw","return"].forEach((function(e){c(t,e,(function(t){return this._invoke(e,t)}))}))}function S(t,e){function r(o,i,a,u){var s=f(t[o],t,i);if("throw"!==s.type){var c=s.arg,l=c.value;return l&&"object"==F(l)&&n.call(l,"__await")?e.resolve(l.__await).then((function(t){r("next",t,a,u)}),(function(t){r("throw",t,a,u)})):e.resolve(l).then((function(t){c.value=t,a(c)}),(function(t){return r("throw",t,a,u)}))}u(s.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function A(e,r,n){var o=h;return function(i,a){if(o===d)throw new Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var u=n.delegate;if(u){var s=E(u,n);if(s){if(s===b)continue;return s}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var c=f(e,r,n);if("normal"===c.type){if(o=n.done?v:p,c.arg===b)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(o=v,n.method="throw",n.arg=c.arg)}}}function E(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,E(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),b;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,b;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,b):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,b)}function k(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function D(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function C(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(k,this),this.reset(!0)}function P(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o=0;--i){var a=this.tryEntries[i],u=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var s=n.call(a,"catchLoc"),c=n.call(a,"finallyLoc");if(s&&c){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),D(r),b}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;D(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:P(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),b}},e}function M(t,e,r,n,o,i,a){try{var u=t[i](a),s=u.value}catch(t){return void r(t)}u.done?e(s):Promise.resolve(s).then(n,o)}function L(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=new p(t);return r.songs.forEach((function(t){t.musicXml=z.convert(t,e)})),r}function I(t){return N.apply(this,arguments)}function N(){var t;return t=T().mark((function t(e){var r,n=arguments;return T().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=n.length>1&&void 0!==n[1]?n[1]:{},t.abrupt("return",new(o())((function(t){return t(L(e,r))})));case 2:case"end":return t.stop()}}),t)})),N=function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){M(i,n,o,a,u,"next",t)}function u(t){M(i,n,o,a,u,"throw",t)}a(void 0)}))},N.apply(this,arguments)}_=z,D(z,"defaultOptions",{divisions:768,notation:"rhythmic",step:"B",octave:4,notehead:"slash",logLevel:P.Warn}),D(z,"sequenceAttributes",["divisions","key","time","staves","part-symbol","instruments","clef","staff-details","transpose","directive","measure-style"]),D(z,"sequenceNote",["cue","pitch","rest","unpitched","duration","tie","voice","type","dot","accidental","time-modification","stem","notehead","notehead-text","staff","beam","notations","lyric","play"]),D(z,"sequenceNotations",["accidental-mark","arpeggiate","articulations","dynamics","fermata","glissando","non-arpeggiate","ornaments","other-notation","slide","slur","technical","tied","tuplet"]),D(z,"sequenceBarline",["bar-style","footnote","level","wavy-line","segno","coda","fermata","ending","repeat"]),D(z,"mapAlter",{"#":1,b:-1}),D(z,"mapFifthsToAlters",{0:[],1:["F"],2:["F","C"],3:["F","C","G"],4:["F","C","G","D"],5:["F","C","G","D","A"],6:["F","C","G","D","A","E"],7:["F","C","G","D","A","E","B"],"-1":["B"],"-2":["B","E"],"-3":["B","E","A"],"-4":["B","E","A","D"],"-5":["B","E","A","D","G"],"-6":["B","E","A","D","G","C"],"-7":["B","E","A","D","G","C","F"]}),D(z,"mapRepeats",{"D.C. al Coda":_.prototype.convertDaCapo,"D.C. al Fine":_.prototype.convertDaCapo,"D.C. al 1st End.":_.prototype.convertDaCapo,"D.C. al 2nd End.":_.prototype.convertDaCapo,"D.C. al 3rd End.":_.prototype.convertDaCapo,"D.S. al Coda":_.prototype.convertDalSegno,"D.S. al Fine":_.prototype.convertDalSegno,"D.S. al 1st End.":_.prototype.convertDalSegno,"D.S. al 2nd End.":_.prototype.convertDalSegno,"D.S. al 3rd End.":_.prototype.convertDalSegno,Fine:_.prototype.convertFine,"3x":_.prototype.convertRepeatNx,"4x":_.prototype.convertRepeatNx,"5x":_.prototype.convertRepeatNx,"6x":_.prototype.convertRepeatNx,"7x":_.prototype.convertRepeatNx,"8x":_.prototype.convertRepeatNx}),D(z,"Measure",function(){function t(e){k(this,t),this.body={_name:"measure",_attrs:{number:e},_content:[]},this.attributes=[],this.chords=[],this.barlines=[],this.barEnding=0}return E(t,[{key:"number",value:function(){return this.body._attrs.number}},{key:"assemble",value:function(){var t=this;return this.attributes.length&&this.body._content.push({attributes:_.reorderSequence(this,this.attributes,_.sequenceAttributes)}),this.chords.forEach((function(e){var r;(r=t.body._content).push.apply(r,[{harmony:e.harmony}].concat(O(e.notes.map((function(t){return{note:t}})))))})),this.barlines[0]._content=_.reorderSequence(this,this.barlines[0]._content,_.sequenceBarline),this.body._content.splice(1,0,this.barlines[0]),this.barlines[1]._content=_.reorderSequence(this,this.barlines[1]._content,_.sequenceBarline),this.body._content.push(this.barlines[1]),this.body}}]),t}()),D(z,"Chord",function(){return E((function t(e,r,n){k(this,t),this.harmony=e,this.notes=r,this.ireal=n,this.spaces=0,this.fermata=!1}))}()),r(666)})(),n})())); \ No newline at end of file