jssm 5.123.0 → 5.124.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -6
- package/dist/cdn/viz.js +104 -97
- package/dist/cli/fsl-render.cjs +1 -1
- package/dist/cli/fsl.cjs +1 -1
- package/dist/deno/README.md +6 -6
- package/dist/deno/jssm.js +1 -1
- package/dist/deno/jssm_viz.d.ts +37 -33
- package/dist/jssm.es5.cjs +1 -1
- package/dist/jssm.es5.iife.js +1 -1
- package/dist/jssm.es6.mjs +1 -1
- package/dist/jssm_viz.cjs +1 -1
- package/dist/jssm_viz.iife.cjs +1 -1
- package/dist/jssm_viz.mjs +1 -1
- package/jssm_viz.es5.d.cts +37 -33
- package/jssm_viz.es6.d.ts +37 -33
- package/package.json +1 -1
package/dist/cdn/viz.js
CHANGED
|
@@ -16,7 +16,7 @@ const t$2=globalThis,e$4=t$2.ShadowRoot&&(void 0===t$2.ShadyCSS||t$2.ShadyCSS.na
|
|
|
16
16
|
* Copyright 2017 Google LLC
|
|
17
17
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
18
18
|
*/
|
|
19
|
-
const t$1=globalThis,i$2=t=>t,s$1=t$1.trustedTypes,e$2=s$1?s$1.createPolicy("lit-html",{createHTML:t=>t}):void 0,h="$lit$",o$3=`lit$${Math.random().toFixed(9).slice(2)}$`,n$1="?"+o$3,r$2=`<${n$1}>`,l=document,c=()=>l.createComment(""),a=t=>null===t||"object"!=typeof t&&"function"!=typeof t,u=Array.isArray,d=t=>u(t)||"function"==typeof t?.[Symbol.iterator],f="[ \t\n\f\r]",v=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,_=/-->/g,m=/>/g,p=RegExp(`>|${f}(?:([^\\s"'>=/]+)(${f}*=${f}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),g=/'/g,$=/"/g,y=/^(?:script|style|textarea|title)$/i,x=t=>(i,...s)=>({_$litType$:t,strings:i,values:s}),b=x(1),E=Symbol.for("lit-noChange"),A=Symbol.for("lit-nothing"),C=new WeakMap,P=l.createTreeWalker(l,129);function V(t,i){if(!u(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==e$2?e$2.createHTML(i):i}const N=(t,i)=>{const s=t.length-1,e=[];let n,l=2===i?"<svg>":3===i?"<math>":"",c=v;for(let i=0;i<s;i++){const s=t[i];let a,u,d=-1,f=0;for(;f<s.length&&(c.lastIndex=f,u=c.exec(s),null!==u);)f=c.lastIndex,c===v?"!--"===u[1]?c=_:void 0!==u[1]?c=m:void 0!==u[2]?(y.test(u[2])&&(n=RegExp("</"+u[2],"g")),c=p):void 0!==u[3]&&(c=p):c===p?">"===u[0]?(c=n??v,d=-1):void 0===u[1]?d=-2:(d=c.lastIndex-u[2].length,a=u[1],c=void 0===u[3]?p:'"'===u[3]?$:g):c===$||c===g?c=p:c===_||c===m?c=v:(c=p,n=void 0);const x=c===p&&t[i+1].startsWith("/>")?" ":"";l+=c===v?s+r$2:d>=0?(e.push(a),s.slice(0,d)+h+s.slice(d)+o$3+x):s+o$3+(-2===d?i:x);}return [V(t,l+(t[s]||"<?>")+(2===i?"</svg>":3===i?"</math>":"")),e]};class S{constructor({strings:t,_$litType$:i},e){let r;this.parts=[];let l=0,a=0;const u=t.length-1,d=this.parts,[f,v]=N(t,i);if(this.el=S.createElement(f,e),P.currentNode=this.el.content,2===i||3===i){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes);}for(;null!==(r=P.nextNode())&&d.length<u;){if(1===r.nodeType){if(r.hasAttributes())for(const t of r.getAttributeNames())if(t.endsWith(h)){const i=v[a++],s=r.getAttribute(t).split(o$3),e=/([.?@])?(.*)/.exec(i);d.push({type:1,index:l,name:e[2],strings:s,ctor:"."===e[1]?I:"?"===e[1]?L:"@"===e[1]?z:H}),r.removeAttribute(t);}else t.startsWith(o$3)&&(d.push({type:6,index:l}),r.removeAttribute(t));if(y.test(r.tagName)){const t=r.textContent.split(o$3),i=t.length-1;if(i>0){r.textContent=s$1?s$1.emptyScript:"";for(let s=0;s<i;s++)r.append(t[s],c()),P.nextNode(),d.push({type:2,index:++l});r.append(t[i],c());}}}else if(8===r.nodeType)if(r.data===n$1)d.push({type:2,index:l});else {let t=-1;for(;-1!==(t=r.data.indexOf(o$3,t+1));)d.push({type:7,index:l}),t+=o$3.length-1;}l++;}}static createElement(t,i){const s=l.createElement("template");return s.innerHTML=t,s}}function M(t,i,s=t,e){if(i===E)return i;let h=void 0!==e?s._$Co?.[e]:s._$Cl;const o=a(i)?void 0:i._$litDirective$;return h?.constructor!==o&&(h?._$AO?.(false),void 0===o?h=void 0:(h=new o(t),h._$AT(t,s,e)),void 0!==e?(s._$Co??=[])[e]=h:s._$Cl=h),void 0!==h&&(i=M(t,h._$AS(t,i.values),h,e)),i}class R{constructor(t,i){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=i;}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:i},parts:s}=this._$AD,e=(t?.creationScope??l).importNode(i,true);P.currentNode=e;let h=P.nextNode(),o=0,n=0,r=s[0];for(;void 0!==r;){if(o===r.index){let i;2===r.type?i=new k(h,h.nextSibling,this,t):1===r.type?i=new r.ctor(h,r.name,r.strings,this,t):6===r.type&&(i=new Z(h,this,t)),this._$AV.push(i),r=s[++n];}o!==r?.index&&(h=P.nextNode(),o++);}return P.currentNode=l,e}p(t){let i=0;for(const s of this._$AV) void 0!==s&&(void 0!==s.strings?(s._$AI(t,s,i),i+=s.strings.length-2):s._$AI(t[i])),i++;}}class k{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,i,s,e){this.type=2,this._$AH=A,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=s,this.options=e,this._$Cv=e?.isConnected??true;}get parentNode(){let t=this._$AA.parentNode;const i=this._$AM;return void 0!==i&&11===t?.nodeType&&(t=i.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,i=this){t=M(this,t,i),a(t)?t===A||null==t||""===t?(this._$AH!==A&&this._$AR(),this._$AH=A):t!==this._$AH&&t!==E&&this._(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):d(t)?this.k(t):this._(t);}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t));}_(t){this._$AH!==A&&a(this._$AH)?this._$AA.nextSibling.data=t:this.T(l.createTextNode(t)),this._$AH=t;}$(t){const{values:i,_$litType$:s}=t,e="number"==typeof s?this._$AC(t):(void 0===s.el&&(s.el=S.createElement(V(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===e)this._$AH.p(i);else {const t=new R(e,this),s=t.u(this.options);t.p(i),this.T(s),this._$AH=t;}}_$AC(t){let i=C.get(t.strings);return void 0===i&&C.set(t.strings,i=new S(t)),i}k(t){u(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let s,e=0;for(const h of t)e===i.length?i.push(s=new k(this.O(c()),this.O(c()),this,this.options)):s=i[e],s._$AI(h),e++;e<i.length&&(this._$AR(s&&s._$AB.nextSibling,e),i.length=e);}_$AR(t=this._$AA.nextSibling,s){for(this._$AP?.(false,true,s);t!==this._$AB;){const s=i$2(t).nextSibling;i$2(t).remove(),t=s;}}setConnected(t){ void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t));}}class H{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,i,s,e,h){this.type=1,this._$AH=A,this._$AN=void 0,this.element=t,this.name=i,this._$AM=e,this.options=h,s.length>2||""!==s[0]||""!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=A;}_$AI(t,i=this,s,e){const h=this.strings;let o=false;if(void 0===h)t=M(this,t,i,0),o=!a(t)||t!==this._$AH&&t!==E,o&&(this._$AH=t);else {const e=t;let n,r;for(t=h[0],n=0;n<h.length-1;n++)r=M(this,e[s+n],i,n),r===E&&(r=this._$AH[n]),o||=!a(r)||r!==this._$AH[n],r===A?t=A:t!==A&&(t+=(r??"")+h[n+1]),this._$AH[n]=r;}o&&!e&&this.j(t);}j(t){t===A?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"");}}class I extends H{constructor(){super(...arguments),this.type=3;}j(t){this.element[this.name]=t===A?void 0:t;}}class L extends H{constructor(){super(...arguments),this.type=4;}j(t){this.element.toggleAttribute(this.name,!!t&&t!==A);}}class z extends H{constructor(t,i,s,e,h){super(t,i,s,e,h),this.type=5;}_$AI(t,i=this){if((t=M(this,t,i,0)??A)===E)return;const s=this._$AH,e=t===A&&s!==A||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,h=t!==A&&(s===A||e);e&&this.element.removeEventListener(this.name,this,s),h&&this.element.addEventListener(this.name,this,t),this._$AH=t;}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t);}}class Z{constructor(t,i,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=i,this.options=s;}get _$AU(){return this._$AM._$AU}_$AI(t){M(this,t);}}const B=t$1.litHtmlPolyfillSupport;B?.(S,k),(t$1.litHtmlVersions??=[]).push("3.3.
|
|
19
|
+
const t$1=globalThis,i$2=t=>t,s$1=t$1.trustedTypes,e$2=s$1?s$1.createPolicy("lit-html",{createHTML:t=>t}):void 0,h="$lit$",o$3=`lit$${Math.random().toFixed(9).slice(2)}$`,n$1="?"+o$3,r$2=`<${n$1}>`,l=document,c=()=>l.createComment(""),a=t=>null===t||"object"!=typeof t&&"function"!=typeof t,u=Array.isArray,d=t=>u(t)||"function"==typeof t?.[Symbol.iterator],f="[ \t\n\f\r]",v=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,_=/-->/g,m=/>/g,p=RegExp(`>|${f}(?:([^\\s"'>=/]+)(${f}*=${f}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),g=/'/g,$=/"/g,y=/^(?:script|style|textarea|title)$/i,x=t=>(i,...s)=>({_$litType$:t,strings:i,values:s}),b=x(1),E=Symbol.for("lit-noChange"),A=Symbol.for("lit-nothing"),C=new WeakMap,P=l.createTreeWalker(l,129);function V(t,i){if(!u(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==e$2?e$2.createHTML(i):i}const N=(t,i)=>{const s=t.length-1,e=[];let n,l=2===i?"<svg>":3===i?"<math>":"",c=v;for(let i=0;i<s;i++){const s=t[i];let a,u,d=-1,f=0;for(;f<s.length&&(c.lastIndex=f,u=c.exec(s),null!==u);)f=c.lastIndex,c===v?"!--"===u[1]?c=_:void 0!==u[1]?c=m:void 0!==u[2]?(y.test(u[2])&&(n=RegExp("</"+u[2],"g")),c=p):void 0!==u[3]&&(c=p):c===p?">"===u[0]?(c=n??v,d=-1):void 0===u[1]?d=-2:(d=c.lastIndex-u[2].length,a=u[1],c=void 0===u[3]?p:'"'===u[3]?$:g):c===$||c===g?c=p:c===_||c===m?c=v:(c=p,n=void 0);const x=c===p&&t[i+1].startsWith("/>")?" ":"";l+=c===v?s+r$2:d>=0?(e.push(a),s.slice(0,d)+h+s.slice(d)+o$3+x):s+o$3+(-2===d?i:x);}return [V(t,l+(t[s]||"<?>")+(2===i?"</svg>":3===i?"</math>":"")),e]};class S{constructor({strings:t,_$litType$:i},e){let r;this.parts=[];let l=0,a=0;const u=t.length-1,d=this.parts,[f,v]=N(t,i);if(this.el=S.createElement(f,e),P.currentNode=this.el.content,2===i||3===i){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes);}for(;null!==(r=P.nextNode())&&d.length<u;){if(1===r.nodeType){if(r.hasAttributes())for(const t of r.getAttributeNames())if(t.endsWith(h)){const i=v[a++],s=r.getAttribute(t).split(o$3),e=/([.?@])?(.*)/.exec(i);d.push({type:1,index:l,name:e[2],strings:s,ctor:"."===e[1]?I:"?"===e[1]?L:"@"===e[1]?z:H}),r.removeAttribute(t);}else t.startsWith(o$3)&&(d.push({type:6,index:l}),r.removeAttribute(t));if(y.test(r.tagName)){const t=r.textContent.split(o$3),i=t.length-1;if(i>0){r.textContent=s$1?s$1.emptyScript:"";for(let s=0;s<i;s++)r.append(t[s],c()),P.nextNode(),d.push({type:2,index:++l});r.append(t[i],c());}}}else if(8===r.nodeType)if(r.data===n$1)d.push({type:2,index:l});else {let t=-1;for(;-1!==(t=r.data.indexOf(o$3,t+1));)d.push({type:7,index:l}),t+=o$3.length-1;}l++;}}static createElement(t,i){const s=l.createElement("template");return s.innerHTML=t,s}}function M(t,i,s=t,e){if(i===E)return i;let h=void 0!==e?s._$Co?.[e]:s._$Cl;const o=a(i)?void 0:i._$litDirective$;return h?.constructor!==o&&(h?._$AO?.(false),void 0===o?h=void 0:(h=new o(t),h._$AT(t,s,e)),void 0!==e?(s._$Co??=[])[e]=h:s._$Cl=h),void 0!==h&&(i=M(t,h._$AS(t,i.values),h,e)),i}class R{constructor(t,i){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=i;}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:i},parts:s}=this._$AD,e=(t?.creationScope??l).importNode(i,true);P.currentNode=e;let h=P.nextNode(),o=0,n=0,r=s[0];for(;void 0!==r;){if(o===r.index){let i;2===r.type?i=new k(h,h.nextSibling,this,t):1===r.type?i=new r.ctor(h,r.name,r.strings,this,t):6===r.type&&(i=new Z(h,this,t)),this._$AV.push(i),r=s[++n];}o!==r?.index&&(h=P.nextNode(),o++);}return P.currentNode=l,e}p(t){let i=0;for(const s of this._$AV) void 0!==s&&(void 0!==s.strings?(s._$AI(t,s,i),i+=s.strings.length-2):s._$AI(t[i])),i++;}}class k{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,i,s,e){this.type=2,this._$AH=A,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=s,this.options=e,this._$Cv=e?.isConnected??true;}get parentNode(){let t=this._$AA.parentNode;const i=this._$AM;return void 0!==i&&11===t?.nodeType&&(t=i.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,i=this){t=M(this,t,i),a(t)?t===A||null==t||""===t?(this._$AH!==A&&this._$AR(),this._$AH=A):t!==this._$AH&&t!==E&&this._(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):d(t)?this.k(t):this._(t);}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t));}_(t){this._$AH!==A&&a(this._$AH)?this._$AA.nextSibling.data=t:this.T(l.createTextNode(t)),this._$AH=t;}$(t){const{values:i,_$litType$:s}=t,e="number"==typeof s?this._$AC(t):(void 0===s.el&&(s.el=S.createElement(V(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===e)this._$AH.p(i);else {const t=new R(e,this),s=t.u(this.options);t.p(i),this.T(s),this._$AH=t;}}_$AC(t){let i=C.get(t.strings);return void 0===i&&C.set(t.strings,i=new S(t)),i}k(t){u(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let s,e=0;for(const h of t)e===i.length?i.push(s=new k(this.O(c()),this.O(c()),this,this.options)):s=i[e],s._$AI(h),e++;e<i.length&&(this._$AR(s&&s._$AB.nextSibling,e),i.length=e);}_$AR(t=this._$AA.nextSibling,s){for(this._$AP?.(false,true,s);t!==this._$AB;){const s=i$2(t).nextSibling;i$2(t).remove(),t=s;}}setConnected(t){ void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t));}}class H{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,i,s,e,h){this.type=1,this._$AH=A,this._$AN=void 0,this.element=t,this.name=i,this._$AM=e,this.options=h,s.length>2||""!==s[0]||""!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=A;}_$AI(t,i=this,s,e){const h=this.strings;let o=false;if(void 0===h)t=M(this,t,i,0),o=!a(t)||t!==this._$AH&&t!==E,o&&(this._$AH=t);else {const e=t;let n,r;for(t=h[0],n=0;n<h.length-1;n++)r=M(this,e[s+n],i,n),r===E&&(r=this._$AH[n]),o||=!a(r)||r!==this._$AH[n],r===A?t=A:t!==A&&(t+=(r??"")+h[n+1]),this._$AH[n]=r;}o&&!e&&this.j(t);}j(t){t===A?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"");}}class I extends H{constructor(){super(...arguments),this.type=3;}j(t){this.element[this.name]=t===A?void 0:t;}}class L extends H{constructor(){super(...arguments),this.type=4;}j(t){this.element.toggleAttribute(this.name,!!t&&t!==A);}}class z extends H{constructor(t,i,s,e,h){super(t,i,s,e,h),this.type=5;}_$AI(t,i=this){if((t=M(this,t,i,0)??A)===E)return;const s=this._$AH,e=t===A&&s!==A||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,h=t!==A&&(s===A||e);e&&this.element.removeEventListener(this.name,this,s),h&&this.element.addEventListener(this.name,this,t),this._$AH=t;}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t);}}class Z{constructor(t,i,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=i,this.options=s;}get _$AU(){return this._$AM._$AU}_$AI(t){M(this,t);}}const B=t$1.litHtmlPolyfillSupport;B?.(S,k),(t$1.litHtmlVersions??=[]).push("3.3.2");const D=(t,i,s)=>{const e=s?.renderBefore??i;let h=e._$litPart$;if(void 0===h){const t=s?.renderBefore??null;e._$litPart$=h=new k(i.insertBefore(c(),t),t,void 0,s??{});}return h._$AI(t),h};
|
|
20
20
|
|
|
21
21
|
/**
|
|
22
22
|
* @license
|
|
@@ -348,8 +348,8 @@ peg$SyntaxError.buildMessage = function (expected, found) {
|
|
|
348
348
|
};
|
|
349
349
|
function peg$parse(input, options) {
|
|
350
350
|
options = options !== void 0 ? options : {};
|
|
351
|
-
var peg$FAILED = {}, peg$startRuleFunctions = { Document: peg$parseDocument }, peg$startRuleFunction = peg$parseDocument, peg$c0 = function (e) { return e; }, peg$c1 = "
|
|
352
|
-
themes.push(th); return themes; }, peg$c16 = function (th) { return [th]; }, peg$c17 = "box3d", peg$c18 = peg$literalExpectation("box3d", false), peg$c19 = "polygon", peg$c20 = peg$literalExpectation("polygon", false), peg$c21 = "ellipse", peg$c22 = peg$literalExpectation("ellipse", false), peg$c23 = "oval", peg$c24 = peg$literalExpectation("oval", false), peg$c25 = "circle", peg$c26 = peg$literalExpectation("circle", false), peg$c27 = "point", peg$c28 = peg$literalExpectation("point", false), peg$c29 = "egg", peg$c30 = peg$literalExpectation("egg", false), peg$c31 = "triangle", peg$c32 = peg$literalExpectation("triangle", false), peg$c33 = "plaintext", peg$c34 = peg$literalExpectation("plaintext", false), peg$c35 = "
|
|
351
|
+
var peg$FAILED = {}, peg$startRuleFunctions = { Document: peg$parseDocument }, peg$startRuleFunction = peg$parseDocument, peg$c0 = function (e) { return e; }, peg$c1 = "default", peg$c2 = peg$literalExpectation("default", false), peg$c3 = "ocean", peg$c4 = peg$literalExpectation("ocean", false), peg$c5 = "modern", peg$c6 = peg$literalExpectation("modern", false), peg$c7 = "plain", peg$c8 = peg$literalExpectation("plain", false), peg$c9 = "bold", peg$c10 = peg$literalExpectation("bold", false), peg$c11 = "[", peg$c12 = peg$literalExpectation("[", false), peg$c13 = "]", peg$c14 = peg$literalExpectation("]", false), peg$c15 = function (ths, th) { const themes = ths.map(t => t[0]); if (th)
|
|
352
|
+
themes.push(th); return themes; }, peg$c16 = function (th) { return [th]; }, peg$c17 = "box3d", peg$c18 = peg$literalExpectation("box3d", false), peg$c19 = "polygon", peg$c20 = peg$literalExpectation("polygon", false), peg$c21 = "ellipse", peg$c22 = peg$literalExpectation("ellipse", false), peg$c23 = "oval", peg$c24 = peg$literalExpectation("oval", false), peg$c25 = "circle", peg$c26 = peg$literalExpectation("circle", false), peg$c27 = "point", peg$c28 = peg$literalExpectation("point", false), peg$c29 = "egg", peg$c30 = peg$literalExpectation("egg", false), peg$c31 = "triangle", peg$c32 = peg$literalExpectation("triangle", false), peg$c33 = "plaintext", peg$c34 = peg$literalExpectation("plaintext", false), peg$c35 = "diamond", peg$c36 = peg$literalExpectation("diamond", false), peg$c37 = "trapezium", peg$c38 = peg$literalExpectation("trapezium", false), peg$c39 = "parallelogram", peg$c40 = peg$literalExpectation("parallelogram", false), peg$c41 = "house", peg$c42 = peg$literalExpectation("house", false), peg$c43 = "pentagon", peg$c44 = peg$literalExpectation("pentagon", false), peg$c45 = "hexagon", peg$c46 = peg$literalExpectation("hexagon", false), peg$c47 = "septagon", peg$c48 = peg$literalExpectation("septagon", false), peg$c49 = "octagon", peg$c50 = peg$literalExpectation("octagon", false), peg$c51 = "doublecircle", peg$c52 = peg$literalExpectation("doublecircle", false), peg$c53 = "doubleoctagon", peg$c54 = peg$literalExpectation("doubleoctagon", false), peg$c55 = "tripleoctagon", peg$c56 = peg$literalExpectation("tripleoctagon", false), peg$c57 = "invtriangle", peg$c58 = peg$literalExpectation("invtriangle", false), peg$c59 = "invtrapezium", peg$c60 = peg$literalExpectation("invtrapezium", false), peg$c61 = "invhouse", peg$c62 = peg$literalExpectation("invhouse", false), peg$c63 = "Mdiamond", peg$c64 = peg$literalExpectation("Mdiamond", false), peg$c65 = "Msquare", peg$c66 = peg$literalExpectation("Msquare", false), peg$c67 = "Mcircle", peg$c68 = peg$literalExpectation("Mcircle", false), peg$c69 = "rectangle", peg$c70 = peg$literalExpectation("rectangle", false), peg$c71 = "rect", peg$c72 = peg$literalExpectation("rect", false), peg$c73 = "square", peg$c74 = peg$literalExpectation("square", false), peg$c75 = "star", peg$c76 = peg$literalExpectation("star", false), peg$c77 = "none", peg$c78 = peg$literalExpectation("none", false), peg$c79 = "underline", peg$c80 = peg$literalExpectation("underline", false), peg$c81 = "cylinder", peg$c82 = peg$literalExpectation("cylinder", false), peg$c83 = "note", peg$c84 = peg$literalExpectation("note", false), peg$c85 = "tab", peg$c86 = peg$literalExpectation("tab", false), peg$c87 = "folder", peg$c88 = peg$literalExpectation("folder", false), peg$c89 = "box", peg$c90 = peg$literalExpectation("box", false), peg$c91 = "component", peg$c92 = peg$literalExpectation("component", false), peg$c93 = "promoter", peg$c94 = peg$literalExpectation("promoter", false), peg$c95 = "cds", peg$c96 = peg$literalExpectation("cds", false), peg$c97 = "terminator", peg$c98 = peg$literalExpectation("terminator", false), peg$c99 = "utr", peg$c100 = peg$literalExpectation("utr", false), peg$c101 = "primersite", peg$c102 = peg$literalExpectation("primersite", false), peg$c103 = "restrictionsite", peg$c104 = peg$literalExpectation("restrictionsite", false), peg$c105 = "fivepoverhang", peg$c106 = peg$literalExpectation("fivepoverhang", false), peg$c107 = "threepoverhang", peg$c108 = peg$literalExpectation("threepoverhang", false), peg$c109 = "noverhang", peg$c110 = peg$literalExpectation("noverhang", false), peg$c111 = "assembly", peg$c112 = peg$literalExpectation("assembly", false), peg$c113 = "signature", peg$c114 = peg$literalExpectation("signature", false), peg$c115 = "insulator", peg$c116 = peg$literalExpectation("insulator", false), peg$c117 = "ribosite", peg$c118 = peg$literalExpectation("ribosite", false), peg$c119 = "rnastab", peg$c120 = peg$literalExpectation("rnastab", false), peg$c121 = "proteasesite", peg$c122 = peg$literalExpectation("proteasesite", false), peg$c123 = "proteinstab", peg$c124 = peg$literalExpectation("proteinstab", false), peg$c125 = "rpromoter", peg$c126 = peg$literalExpectation("rpromoter", false), peg$c127 = "rarrow", peg$c128 = peg$literalExpectation("rarrow", false), peg$c129 = "larrow", peg$c130 = peg$literalExpectation("larrow", false), peg$c131 = "lpromoter", peg$c132 = peg$literalExpectation("lpromoter", false), peg$c133 = "record", peg$c134 = peg$literalExpectation("record", false), peg$c135 = peg$otherExpectation("forward light arrow ->"), peg$c136 = "->", peg$c137 = peg$literalExpectation("->", false), peg$c138 = "\u2192", peg$c139 = peg$literalExpectation("\u2192", false), peg$c140 = function () { return "->"; }, peg$c141 = peg$otherExpectation("two way light arrow <->"), peg$c142 = "<->", peg$c143 = peg$literalExpectation("<->", false), peg$c144 = "\u2194", peg$c145 = peg$literalExpectation("\u2194", false), peg$c146 = function () { return "<->"; }, peg$c147 = peg$otherExpectation("back light arrow <-"), peg$c148 = "<-", peg$c149 = peg$literalExpectation("<-", false), peg$c150 = "\u2190", peg$c151 = peg$literalExpectation("\u2190", false), peg$c152 = function () { return "<-"; }, peg$c153 = peg$otherExpectation("forward fat arrow =>"), peg$c154 = "=>", peg$c155 = peg$literalExpectation("=>", false), peg$c156 = "\u21D2", peg$c157 = peg$literalExpectation("\u21D2", false), peg$c158 = function () { return "=>"; }, peg$c159 = peg$otherExpectation("two way fat arrow <=>"), peg$c160 = "<=>", peg$c161 = peg$literalExpectation("<=>", false), peg$c162 = "\u21D4", peg$c163 = peg$literalExpectation("\u21D4", false), peg$c164 = function () { return "<=>"; }, peg$c165 = peg$otherExpectation("back fat arrow <="), peg$c166 = "<=", peg$c167 = peg$literalExpectation("<=", false), peg$c168 = "\u21D0", peg$c169 = peg$literalExpectation("\u21D0", false), peg$c170 = function () { return "<="; }, peg$c171 = peg$otherExpectation("forward tilde arrow ~>"), peg$c172 = "~>", peg$c173 = peg$literalExpectation("~>", false), peg$c174 = "\u219B", peg$c175 = peg$literalExpectation("\u219B", false), peg$c176 = function () { return "~>"; }, peg$c177 = peg$otherExpectation("two way tilde arrow <~>"), peg$c178 = "<~>", peg$c179 = peg$literalExpectation("<~>", false), peg$c180 = "\u21AE", peg$c181 = peg$literalExpectation("\u21AE", false), peg$c182 = function () { return "<~>"; }, peg$c183 = peg$otherExpectation("back tilde arrow <~"), peg$c184 = "<~", peg$c185 = peg$literalExpectation("<~", false), peg$c186 = "\u219A", peg$c187 = peg$literalExpectation("\u219A", false), peg$c188 = function () { return "<~"; }, peg$c189 = peg$otherExpectation("light fat arrow <-=>"), peg$c190 = "<-=>", peg$c191 = peg$literalExpectation("<-=>", false), peg$c192 = "\u2190\u21D2", peg$c193 = peg$literalExpectation("\u2190\u21D2", false), peg$c194 = function () { return "<-=>"; }, peg$c195 = peg$otherExpectation("light tilde arrow <-~>"), peg$c196 = "<-~>", peg$c197 = peg$literalExpectation("<-~>", false), peg$c198 = "\u2190\u219B", peg$c199 = peg$literalExpectation("\u2190\u219B", false), peg$c200 = function () { return "<-~>"; }, peg$c201 = peg$otherExpectation("fat light arrow <=->"), peg$c202 = "<=->", peg$c203 = peg$literalExpectation("<=->", false), peg$c204 = "\u21D0\u2192", peg$c205 = peg$literalExpectation("\u21D0\u2192", false), peg$c206 = function () { return "<=->"; }, peg$c207 = peg$otherExpectation("fat tilde arrow <=~>"), peg$c208 = "<=~>", peg$c209 = peg$literalExpectation("<=~>", false), peg$c210 = "\u21D0\u219B", peg$c211 = peg$literalExpectation("\u21D0\u219B", false), peg$c212 = function () { return "<=~>"; }, peg$c213 = peg$otherExpectation("tilde light arrow <~->"), peg$c214 = "<~->", peg$c215 = peg$literalExpectation("<~->", false), peg$c216 = "\u219A\u2192", peg$c217 = peg$literalExpectation("\u219A\u2192", false), peg$c218 = function () { return "<~->"; }, peg$c219 = peg$otherExpectation("tilde fat arrow <~=>"), peg$c220 = "<~=>", peg$c221 = peg$literalExpectation("<~=>", false), peg$c222 = "\u219A\u21D2", peg$c223 = peg$literalExpectation("\u219A\u21D2", false), peg$c224 = function () { return "<~=>"; }, peg$c225 = peg$otherExpectation("light arrow"), peg$c226 = peg$otherExpectation("fat arrow"), peg$c227 = peg$otherExpectation("tilde arrow"), peg$c228 = peg$otherExpectation("mixed arrow"), peg$c229 = peg$otherExpectation("arrow"), peg$c230 = "true", peg$c231 = peg$literalExpectation("true", false), peg$c232 = function () { return true; }, peg$c233 = "false", peg$c234 = peg$literalExpectation("false", false), peg$c235 = function () { return false; }, peg$c236 = "regular", peg$c237 = peg$literalExpectation("regular", false), peg$c238 = "rounded", peg$c239 = peg$literalExpectation("rounded", false), peg$c240 = "lined", peg$c241 = peg$literalExpectation("lined", false), peg$c242 = "solid", peg$c243 = peg$literalExpectation("solid", false), peg$c244 = "dotted", peg$c245 = peg$literalExpectation("dotted", false), peg$c246 = "dashed", peg$c247 = peg$literalExpectation("dashed", false), peg$c248 = "\"", peg$c249 = peg$literalExpectation("\"", false), peg$c250 = "\\", peg$c251 = peg$literalExpectation("\\", false), peg$c252 = "/", peg$c253 = peg$literalExpectation("/", false), peg$c254 = "b", peg$c255 = peg$literalExpectation("b", false), peg$c256 = function () { return "\b"; }, peg$c257 = "f", peg$c258 = peg$literalExpectation("f", false), peg$c259 = function () { return "\f"; }, peg$c260 = "n", peg$c261 = peg$literalExpectation("n", false), peg$c262 = function () { return "\n"; }, peg$c263 = "r", peg$c264 = peg$literalExpectation("r", false), peg$c265 = function () { return "\r"; }, peg$c266 = "t", peg$c267 = peg$literalExpectation("t", false), peg$c268 = function () { return "\t"; }, peg$c269 = "v", peg$c270 = peg$literalExpectation("v", false), peg$c271 = function () { return "\v"; }, peg$c272 = "u", peg$c273 = peg$literalExpectation("u", false), peg$c274 = function (digits) {
|
|
353
353
|
return String.fromCharCode(parseInt(digits, 16));
|
|
354
354
|
}, peg$c275 = function (Sequence) { return Sequence; }, peg$c276 = "null", peg$c277 = peg$literalExpectation("null", false), peg$c278 = function () { return null; }, peg$c279 = "undefined", peg$c280 = peg$literalExpectation("undefined", false), peg$c281 = function () { return undefined; }, peg$c282 = /^[\0-!#-[\]-\uFFFF]/, peg$c283 = peg$classExpectation([["\0", "!"], ["#", "["], ["]", "\uFFFF"]], false, false), peg$c284 = "'", peg$c285 = peg$literalExpectation("'", false), peg$c286 = /^[ -&(-[\]-\uFFFF]/, peg$c287 = peg$classExpectation([[" ", "&"], ["(", "["], ["]", "\uFFFF"]], false, false), peg$c288 = peg$otherExpectation("action label"), peg$c289 = function (chars) { return chars.join(""); }, peg$c290 = /^[\n\r\u2028\u2029]/, peg$c291 = peg$classExpectation(["\n", "\r", "\u2028", "\u2029"], false, false), peg$c292 = "*/", peg$c293 = peg$literalExpectation("*/", false), peg$c294 = peg$anyExpectation(), peg$c295 = peg$otherExpectation("block comment"), peg$c296 = "/*", peg$c297 = peg$literalExpectation("/*", false), peg$c298 = peg$otherExpectation("line comment"), peg$c299 = "//", peg$c300 = peg$literalExpectation("//", false), peg$c301 = peg$otherExpectation("whitespace"), peg$c302 = /^[ \t\r\n\x0B]/, peg$c303 = peg$classExpectation([" ", "\t", "\r", "\n", "\x0B"], false, false), peg$c304 = peg$otherExpectation("string"), peg$c305 = /^[0-9a-zA-Z._!$\^*!?,\x80-\uFFFF]/, peg$c306 = peg$classExpectation([["0", "9"], ["a", "z"], ["A", "Z"], ".", "_", "!", "$", "^", "*", "!", "?", ",", ["\x80", "\uFFFF"]], false, false), peg$c307 = /^[0-9a-zA-Z.+_\^()*&$#@!?,\x80-\uFFFF]/, peg$c308 = peg$classExpectation([["0", "9"], ["a", "z"], ["A", "Z"], ".", "+", "_", "^", "(", ")", "*", "&", "$", "#", "@", "!", "?", ",", ["\x80", "\uFFFF"]], false, false), peg$c309 = peg$otherExpectation("atom"), peg$c310 = function (firstletter, text) {
|
|
355
355
|
return firstletter + ((text || []).join(''));
|
|
@@ -586,9 +586,9 @@ function peg$parse(input, options) {
|
|
|
586
586
|
}
|
|
587
587
|
function peg$parseTheme() {
|
|
588
588
|
var s0;
|
|
589
|
-
if (input.substr(peg$currPos,
|
|
589
|
+
if (input.substr(peg$currPos, 7) === peg$c1) {
|
|
590
590
|
s0 = peg$c1;
|
|
591
|
-
peg$currPos +=
|
|
591
|
+
peg$currPos += 7;
|
|
592
592
|
}
|
|
593
593
|
else {
|
|
594
594
|
s0 = peg$FAILED;
|
|
@@ -597,9 +597,9 @@ function peg$parse(input, options) {
|
|
|
597
597
|
}
|
|
598
598
|
}
|
|
599
599
|
if (s0 === peg$FAILED) {
|
|
600
|
-
if (input.substr(peg$currPos,
|
|
600
|
+
if (input.substr(peg$currPos, 5) === peg$c3) {
|
|
601
601
|
s0 = peg$c3;
|
|
602
|
-
peg$currPos +=
|
|
602
|
+
peg$currPos += 5;
|
|
603
603
|
}
|
|
604
604
|
else {
|
|
605
605
|
s0 = peg$FAILED;
|
|
@@ -860,256 +860,256 @@ function peg$parse(input, options) {
|
|
|
860
860
|
}
|
|
861
861
|
}
|
|
862
862
|
if (s0 === peg$FAILED) {
|
|
863
|
-
if (input.substr(peg$currPos, 5) === peg$
|
|
864
|
-
s0 = peg$
|
|
863
|
+
if (input.substr(peg$currPos, 5) === peg$c7) {
|
|
864
|
+
s0 = peg$c7;
|
|
865
865
|
peg$currPos += 5;
|
|
866
866
|
}
|
|
867
867
|
else {
|
|
868
868
|
s0 = peg$FAILED;
|
|
869
869
|
if (peg$silentFails === 0) {
|
|
870
|
-
peg$fail(peg$
|
|
870
|
+
peg$fail(peg$c8);
|
|
871
871
|
}
|
|
872
872
|
}
|
|
873
873
|
if (s0 === peg$FAILED) {
|
|
874
|
-
if (input.substr(peg$currPos, 7) === peg$
|
|
875
|
-
s0 = peg$
|
|
874
|
+
if (input.substr(peg$currPos, 7) === peg$c35) {
|
|
875
|
+
s0 = peg$c35;
|
|
876
876
|
peg$currPos += 7;
|
|
877
877
|
}
|
|
878
878
|
else {
|
|
879
879
|
s0 = peg$FAILED;
|
|
880
880
|
if (peg$silentFails === 0) {
|
|
881
|
-
peg$fail(peg$
|
|
881
|
+
peg$fail(peg$c36);
|
|
882
882
|
}
|
|
883
883
|
}
|
|
884
884
|
if (s0 === peg$FAILED) {
|
|
885
|
-
if (input.substr(peg$currPos, 9) === peg$
|
|
886
|
-
s0 = peg$
|
|
885
|
+
if (input.substr(peg$currPos, 9) === peg$c37) {
|
|
886
|
+
s0 = peg$c37;
|
|
887
887
|
peg$currPos += 9;
|
|
888
888
|
}
|
|
889
889
|
else {
|
|
890
890
|
s0 = peg$FAILED;
|
|
891
891
|
if (peg$silentFails === 0) {
|
|
892
|
-
peg$fail(peg$
|
|
892
|
+
peg$fail(peg$c38);
|
|
893
893
|
}
|
|
894
894
|
}
|
|
895
895
|
if (s0 === peg$FAILED) {
|
|
896
|
-
if (input.substr(peg$currPos, 13) === peg$
|
|
897
|
-
s0 = peg$
|
|
896
|
+
if (input.substr(peg$currPos, 13) === peg$c39) {
|
|
897
|
+
s0 = peg$c39;
|
|
898
898
|
peg$currPos += 13;
|
|
899
899
|
}
|
|
900
900
|
else {
|
|
901
901
|
s0 = peg$FAILED;
|
|
902
902
|
if (peg$silentFails === 0) {
|
|
903
|
-
peg$fail(peg$
|
|
903
|
+
peg$fail(peg$c40);
|
|
904
904
|
}
|
|
905
905
|
}
|
|
906
906
|
if (s0 === peg$FAILED) {
|
|
907
|
-
if (input.substr(peg$currPos, 5) === peg$
|
|
908
|
-
s0 = peg$
|
|
907
|
+
if (input.substr(peg$currPos, 5) === peg$c41) {
|
|
908
|
+
s0 = peg$c41;
|
|
909
909
|
peg$currPos += 5;
|
|
910
910
|
}
|
|
911
911
|
else {
|
|
912
912
|
s0 = peg$FAILED;
|
|
913
913
|
if (peg$silentFails === 0) {
|
|
914
|
-
peg$fail(peg$
|
|
914
|
+
peg$fail(peg$c42);
|
|
915
915
|
}
|
|
916
916
|
}
|
|
917
917
|
if (s0 === peg$FAILED) {
|
|
918
|
-
if (input.substr(peg$currPos, 8) === peg$
|
|
919
|
-
s0 = peg$
|
|
918
|
+
if (input.substr(peg$currPos, 8) === peg$c43) {
|
|
919
|
+
s0 = peg$c43;
|
|
920
920
|
peg$currPos += 8;
|
|
921
921
|
}
|
|
922
922
|
else {
|
|
923
923
|
s0 = peg$FAILED;
|
|
924
924
|
if (peg$silentFails === 0) {
|
|
925
|
-
peg$fail(peg$
|
|
925
|
+
peg$fail(peg$c44);
|
|
926
926
|
}
|
|
927
927
|
}
|
|
928
928
|
if (s0 === peg$FAILED) {
|
|
929
|
-
if (input.substr(peg$currPos, 7) === peg$
|
|
930
|
-
s0 = peg$
|
|
929
|
+
if (input.substr(peg$currPos, 7) === peg$c45) {
|
|
930
|
+
s0 = peg$c45;
|
|
931
931
|
peg$currPos += 7;
|
|
932
932
|
}
|
|
933
933
|
else {
|
|
934
934
|
s0 = peg$FAILED;
|
|
935
935
|
if (peg$silentFails === 0) {
|
|
936
|
-
peg$fail(peg$
|
|
936
|
+
peg$fail(peg$c46);
|
|
937
937
|
}
|
|
938
938
|
}
|
|
939
939
|
if (s0 === peg$FAILED) {
|
|
940
|
-
if (input.substr(peg$currPos, 8) === peg$
|
|
941
|
-
s0 = peg$
|
|
940
|
+
if (input.substr(peg$currPos, 8) === peg$c47) {
|
|
941
|
+
s0 = peg$c47;
|
|
942
942
|
peg$currPos += 8;
|
|
943
943
|
}
|
|
944
944
|
else {
|
|
945
945
|
s0 = peg$FAILED;
|
|
946
946
|
if (peg$silentFails === 0) {
|
|
947
|
-
peg$fail(peg$
|
|
947
|
+
peg$fail(peg$c48);
|
|
948
948
|
}
|
|
949
949
|
}
|
|
950
950
|
if (s0 === peg$FAILED) {
|
|
951
|
-
if (input.substr(peg$currPos, 7) === peg$
|
|
952
|
-
s0 = peg$
|
|
951
|
+
if (input.substr(peg$currPos, 7) === peg$c49) {
|
|
952
|
+
s0 = peg$c49;
|
|
953
953
|
peg$currPos += 7;
|
|
954
954
|
}
|
|
955
955
|
else {
|
|
956
956
|
s0 = peg$FAILED;
|
|
957
957
|
if (peg$silentFails === 0) {
|
|
958
|
-
peg$fail(peg$
|
|
958
|
+
peg$fail(peg$c50);
|
|
959
959
|
}
|
|
960
960
|
}
|
|
961
961
|
if (s0 === peg$FAILED) {
|
|
962
|
-
if (input.substr(peg$currPos, 12) === peg$
|
|
963
|
-
s0 = peg$
|
|
962
|
+
if (input.substr(peg$currPos, 12) === peg$c51) {
|
|
963
|
+
s0 = peg$c51;
|
|
964
964
|
peg$currPos += 12;
|
|
965
965
|
}
|
|
966
966
|
else {
|
|
967
967
|
s0 = peg$FAILED;
|
|
968
968
|
if (peg$silentFails === 0) {
|
|
969
|
-
peg$fail(peg$
|
|
969
|
+
peg$fail(peg$c52);
|
|
970
970
|
}
|
|
971
971
|
}
|
|
972
972
|
if (s0 === peg$FAILED) {
|
|
973
|
-
if (input.substr(peg$currPos, 13) === peg$
|
|
974
|
-
s0 = peg$
|
|
973
|
+
if (input.substr(peg$currPos, 13) === peg$c53) {
|
|
974
|
+
s0 = peg$c53;
|
|
975
975
|
peg$currPos += 13;
|
|
976
976
|
}
|
|
977
977
|
else {
|
|
978
978
|
s0 = peg$FAILED;
|
|
979
979
|
if (peg$silentFails === 0) {
|
|
980
|
-
peg$fail(peg$
|
|
980
|
+
peg$fail(peg$c54);
|
|
981
981
|
}
|
|
982
982
|
}
|
|
983
983
|
if (s0 === peg$FAILED) {
|
|
984
|
-
if (input.substr(peg$currPos, 13) === peg$
|
|
985
|
-
s0 = peg$
|
|
984
|
+
if (input.substr(peg$currPos, 13) === peg$c55) {
|
|
985
|
+
s0 = peg$c55;
|
|
986
986
|
peg$currPos += 13;
|
|
987
987
|
}
|
|
988
988
|
else {
|
|
989
989
|
s0 = peg$FAILED;
|
|
990
990
|
if (peg$silentFails === 0) {
|
|
991
|
-
peg$fail(peg$
|
|
991
|
+
peg$fail(peg$c56);
|
|
992
992
|
}
|
|
993
993
|
}
|
|
994
994
|
if (s0 === peg$FAILED) {
|
|
995
|
-
if (input.substr(peg$currPos, 11) === peg$
|
|
996
|
-
s0 = peg$
|
|
995
|
+
if (input.substr(peg$currPos, 11) === peg$c57) {
|
|
996
|
+
s0 = peg$c57;
|
|
997
997
|
peg$currPos += 11;
|
|
998
998
|
}
|
|
999
999
|
else {
|
|
1000
1000
|
s0 = peg$FAILED;
|
|
1001
1001
|
if (peg$silentFails === 0) {
|
|
1002
|
-
peg$fail(peg$
|
|
1002
|
+
peg$fail(peg$c58);
|
|
1003
1003
|
}
|
|
1004
1004
|
}
|
|
1005
1005
|
if (s0 === peg$FAILED) {
|
|
1006
|
-
if (input.substr(peg$currPos, 12) === peg$
|
|
1007
|
-
s0 = peg$
|
|
1006
|
+
if (input.substr(peg$currPos, 12) === peg$c59) {
|
|
1007
|
+
s0 = peg$c59;
|
|
1008
1008
|
peg$currPos += 12;
|
|
1009
1009
|
}
|
|
1010
1010
|
else {
|
|
1011
1011
|
s0 = peg$FAILED;
|
|
1012
1012
|
if (peg$silentFails === 0) {
|
|
1013
|
-
peg$fail(peg$
|
|
1013
|
+
peg$fail(peg$c60);
|
|
1014
1014
|
}
|
|
1015
1015
|
}
|
|
1016
1016
|
if (s0 === peg$FAILED) {
|
|
1017
|
-
if (input.substr(peg$currPos, 8) === peg$
|
|
1018
|
-
s0 = peg$
|
|
1017
|
+
if (input.substr(peg$currPos, 8) === peg$c61) {
|
|
1018
|
+
s0 = peg$c61;
|
|
1019
1019
|
peg$currPos += 8;
|
|
1020
1020
|
}
|
|
1021
1021
|
else {
|
|
1022
1022
|
s0 = peg$FAILED;
|
|
1023
1023
|
if (peg$silentFails === 0) {
|
|
1024
|
-
peg$fail(peg$
|
|
1024
|
+
peg$fail(peg$c62);
|
|
1025
1025
|
}
|
|
1026
1026
|
}
|
|
1027
1027
|
if (s0 === peg$FAILED) {
|
|
1028
|
-
if (input.substr(peg$currPos, 8) === peg$
|
|
1029
|
-
s0 = peg$
|
|
1028
|
+
if (input.substr(peg$currPos, 8) === peg$c63) {
|
|
1029
|
+
s0 = peg$c63;
|
|
1030
1030
|
peg$currPos += 8;
|
|
1031
1031
|
}
|
|
1032
1032
|
else {
|
|
1033
1033
|
s0 = peg$FAILED;
|
|
1034
1034
|
if (peg$silentFails === 0) {
|
|
1035
|
-
peg$fail(peg$
|
|
1035
|
+
peg$fail(peg$c64);
|
|
1036
1036
|
}
|
|
1037
1037
|
}
|
|
1038
1038
|
if (s0 === peg$FAILED) {
|
|
1039
|
-
if (input.substr(peg$currPos, 7) === peg$
|
|
1040
|
-
s0 = peg$
|
|
1039
|
+
if (input.substr(peg$currPos, 7) === peg$c65) {
|
|
1040
|
+
s0 = peg$c65;
|
|
1041
1041
|
peg$currPos += 7;
|
|
1042
1042
|
}
|
|
1043
1043
|
else {
|
|
1044
1044
|
s0 = peg$FAILED;
|
|
1045
1045
|
if (peg$silentFails === 0) {
|
|
1046
|
-
peg$fail(peg$
|
|
1046
|
+
peg$fail(peg$c66);
|
|
1047
1047
|
}
|
|
1048
1048
|
}
|
|
1049
1049
|
if (s0 === peg$FAILED) {
|
|
1050
|
-
if (input.substr(peg$currPos, 7) === peg$
|
|
1051
|
-
s0 = peg$
|
|
1050
|
+
if (input.substr(peg$currPos, 7) === peg$c67) {
|
|
1051
|
+
s0 = peg$c67;
|
|
1052
1052
|
peg$currPos += 7;
|
|
1053
1053
|
}
|
|
1054
1054
|
else {
|
|
1055
1055
|
s0 = peg$FAILED;
|
|
1056
1056
|
if (peg$silentFails === 0) {
|
|
1057
|
-
peg$fail(peg$
|
|
1057
|
+
peg$fail(peg$c68);
|
|
1058
1058
|
}
|
|
1059
1059
|
}
|
|
1060
1060
|
if (s0 === peg$FAILED) {
|
|
1061
|
-
if (input.substr(peg$currPos, 9) === peg$
|
|
1062
|
-
s0 = peg$
|
|
1061
|
+
if (input.substr(peg$currPos, 9) === peg$c69) {
|
|
1062
|
+
s0 = peg$c69;
|
|
1063
1063
|
peg$currPos += 9;
|
|
1064
1064
|
}
|
|
1065
1065
|
else {
|
|
1066
1066
|
s0 = peg$FAILED;
|
|
1067
1067
|
if (peg$silentFails === 0) {
|
|
1068
|
-
peg$fail(peg$
|
|
1068
|
+
peg$fail(peg$c70);
|
|
1069
1069
|
}
|
|
1070
1070
|
}
|
|
1071
1071
|
if (s0 === peg$FAILED) {
|
|
1072
|
-
if (input.substr(peg$currPos, 4) === peg$
|
|
1073
|
-
s0 = peg$
|
|
1072
|
+
if (input.substr(peg$currPos, 4) === peg$c71) {
|
|
1073
|
+
s0 = peg$c71;
|
|
1074
1074
|
peg$currPos += 4;
|
|
1075
1075
|
}
|
|
1076
1076
|
else {
|
|
1077
1077
|
s0 = peg$FAILED;
|
|
1078
1078
|
if (peg$silentFails === 0) {
|
|
1079
|
-
peg$fail(peg$
|
|
1079
|
+
peg$fail(peg$c72);
|
|
1080
1080
|
}
|
|
1081
1081
|
}
|
|
1082
1082
|
if (s0 === peg$FAILED) {
|
|
1083
|
-
if (input.substr(peg$currPos, 6) === peg$
|
|
1084
|
-
s0 = peg$
|
|
1083
|
+
if (input.substr(peg$currPos, 6) === peg$c73) {
|
|
1084
|
+
s0 = peg$c73;
|
|
1085
1085
|
peg$currPos += 6;
|
|
1086
1086
|
}
|
|
1087
1087
|
else {
|
|
1088
1088
|
s0 = peg$FAILED;
|
|
1089
1089
|
if (peg$silentFails === 0) {
|
|
1090
|
-
peg$fail(peg$
|
|
1090
|
+
peg$fail(peg$c74);
|
|
1091
1091
|
}
|
|
1092
1092
|
}
|
|
1093
1093
|
if (s0 === peg$FAILED) {
|
|
1094
|
-
if (input.substr(peg$currPos, 4) === peg$
|
|
1095
|
-
s0 = peg$
|
|
1094
|
+
if (input.substr(peg$currPos, 4) === peg$c75) {
|
|
1095
|
+
s0 = peg$c75;
|
|
1096
1096
|
peg$currPos += 4;
|
|
1097
1097
|
}
|
|
1098
1098
|
else {
|
|
1099
1099
|
s0 = peg$FAILED;
|
|
1100
1100
|
if (peg$silentFails === 0) {
|
|
1101
|
-
peg$fail(peg$
|
|
1101
|
+
peg$fail(peg$c76);
|
|
1102
1102
|
}
|
|
1103
1103
|
}
|
|
1104
1104
|
if (s0 === peg$FAILED) {
|
|
1105
|
-
if (input.substr(peg$currPos, 4) === peg$
|
|
1106
|
-
s0 = peg$
|
|
1105
|
+
if (input.substr(peg$currPos, 4) === peg$c77) {
|
|
1106
|
+
s0 = peg$c77;
|
|
1107
1107
|
peg$currPos += 4;
|
|
1108
1108
|
}
|
|
1109
1109
|
else {
|
|
1110
1110
|
s0 = peg$FAILED;
|
|
1111
1111
|
if (peg$silentFails === 0) {
|
|
1112
|
-
peg$fail(peg$
|
|
1112
|
+
peg$fail(peg$c78);
|
|
1113
1113
|
}
|
|
1114
1114
|
}
|
|
1115
1115
|
if (s0 === peg$FAILED) {
|
|
@@ -18388,14 +18388,14 @@ function peg$parse(input, options) {
|
|
|
18388
18388
|
if (s4 !== peg$FAILED) {
|
|
18389
18389
|
s5 = peg$parseWS();
|
|
18390
18390
|
if (s5 !== peg$FAILED) {
|
|
18391
|
-
if (input.substr(peg$currPos, 7) === peg$
|
|
18392
|
-
s6 = peg$
|
|
18391
|
+
if (input.substr(peg$currPos, 7) === peg$c1) {
|
|
18392
|
+
s6 = peg$c1;
|
|
18393
18393
|
peg$currPos += 7;
|
|
18394
18394
|
}
|
|
18395
18395
|
else {
|
|
18396
18396
|
s6 = peg$FAILED;
|
|
18397
18397
|
if (peg$silentFails === 0) {
|
|
18398
|
-
peg$fail(peg$
|
|
18398
|
+
peg$fail(peg$c2);
|
|
18399
18399
|
}
|
|
18400
18400
|
}
|
|
18401
18401
|
if (s6 !== peg$FAILED) {
|
|
@@ -18633,14 +18633,14 @@ function peg$parse(input, options) {
|
|
|
18633
18633
|
if (s4 !== peg$FAILED) {
|
|
18634
18634
|
s5 = peg$parseWS();
|
|
18635
18635
|
if (s5 !== peg$FAILED) {
|
|
18636
|
-
if (input.substr(peg$currPos, 7) === peg$
|
|
18637
|
-
s6 = peg$
|
|
18636
|
+
if (input.substr(peg$currPos, 7) === peg$c1) {
|
|
18637
|
+
s6 = peg$c1;
|
|
18638
18638
|
peg$currPos += 7;
|
|
18639
18639
|
}
|
|
18640
18640
|
else {
|
|
18641
18641
|
s6 = peg$FAILED;
|
|
18642
18642
|
if (peg$silentFails === 0) {
|
|
18643
|
-
peg$fail(peg$
|
|
18643
|
+
peg$fail(peg$c2);
|
|
18644
18644
|
}
|
|
18645
18645
|
}
|
|
18646
18646
|
if (s6 !== peg$FAILED) {
|
|
@@ -21041,7 +21041,7 @@ var constants = /*#__PURE__*/Object.freeze({
|
|
|
21041
21041
|
* Useful for runtime diagnostics and for embedding in serialized machine
|
|
21042
21042
|
* snapshots so that deserializers can detect version-skew.
|
|
21043
21043
|
*/
|
|
21044
|
-
const version = "5.
|
|
21044
|
+
const version = "5.124.1";
|
|
21045
21045
|
|
|
21046
21046
|
// whargarbl lots of these return arrays could/should be sets
|
|
21047
21047
|
const { state_name_chars, state_name_first_chars, action_label_chars } = constants;
|
|
@@ -24504,15 +24504,21 @@ function default_fillcolor_for(kind) {
|
|
|
24504
24504
|
* honoured uniformly. A single `style_for` call per state — downstream
|
|
24505
24505
|
* helpers operate on the cached result rather than re-querying.
|
|
24506
24506
|
*
|
|
24507
|
+
* When `hide_state_labels` is true, the `label=` attribute is omitted from
|
|
24508
|
+
* every state's node line; Graphviz then renders the node box without any
|
|
24509
|
+
* text inside. Useful for diagrams where the state shape carries meaning
|
|
24510
|
+
* on its own (e.g. a tutorial graphic, an icon-only diagram, or a
|
|
24511
|
+
* presentation slide).
|
|
24512
|
+
*
|
|
24507
24513
|
* @internal
|
|
24508
24514
|
*/
|
|
24509
|
-
function states_to_nodes_string(u_jssm, l_states, state_index, state_kinds) {
|
|
24515
|
+
function states_to_nodes_string(u_jssm, l_states, state_index, state_kinds, hide_state_labels = false) {
|
|
24510
24516
|
return l_states.map((s) => {
|
|
24511
24517
|
var _a;
|
|
24512
24518
|
const style = u_jssm.style_for(s);
|
|
24513
24519
|
const fillcolor = style.backgroundColor || default_fillcolor_for((_a = state_kinds.get(s)) !== null && _a !== void 0 ? _a : 'base');
|
|
24514
24520
|
const features = [
|
|
24515
|
-
['label', u_jssm.display_text(s)],
|
|
24521
|
+
['label', hide_state_labels ? '' : u_jssm.display_text(s)],
|
|
24516
24522
|
['shape', style.shape || ''],
|
|
24517
24523
|
['color', style.borderColor || ''],
|
|
24518
24524
|
['style', compose_style_string(style)],
|
|
@@ -24686,21 +24692,23 @@ function arranges_for(u_jssm, state_index) {
|
|
|
24686
24692
|
* const dot = machine_to_dot(sm`a -> b;`);
|
|
24687
24693
|
* // 'digraph G { ... }'
|
|
24688
24694
|
*
|
|
24695
|
+
* // suppress state-name labels (boxes only, no text inside)
|
|
24696
|
+
* const dot2 = machine_to_dot(sm`a -> b;`, { hide_state_labels: true });
|
|
24697
|
+
*
|
|
24689
24698
|
* const dot_with_footer = machine_to_dot(sm`a -> b;`, { footer: 'labelloc="b"; label="caption";' });
|
|
24690
24699
|
* // 'digraph G { ... labelloc="b"; label="caption"; }'
|
|
24691
24700
|
* ```
|
|
24692
24701
|
*
|
|
24693
24702
|
* @param u_jssm The machine to render.
|
|
24694
|
-
* @param opts Optional
|
|
24695
|
-
* @param opts.footer Optional verbatim dot source inserted just before the closing `}`.
|
|
24703
|
+
* @param opts Optional render flags. See {@link VizRenderOpts}.
|
|
24696
24704
|
* @returns A complete graphviz dot source string.
|
|
24697
24705
|
*/
|
|
24698
|
-
function machine_to_dot(u_jssm, opts) {
|
|
24706
|
+
function machine_to_dot(u_jssm, opts = {}) {
|
|
24699
24707
|
var _a;
|
|
24700
24708
|
const l_states = u_jssm.states();
|
|
24701
24709
|
const state_index = new Map(l_states.map((s, i) => [s, i]));
|
|
24702
24710
|
const state_kinds = classify_states(u_jssm, l_states);
|
|
24703
|
-
const nodes = states_to_nodes_string(u_jssm, l_states, state_index, state_kinds);
|
|
24711
|
+
const nodes = states_to_nodes_string(u_jssm, l_states, state_index, state_kinds, opts.hide_state_labels === true);
|
|
24704
24712
|
const edges = states_to_edges_string(u_jssm, l_states, state_index, state_kinds);
|
|
24705
24713
|
const arranges = arranges_for(u_jssm, state_index);
|
|
24706
24714
|
const rank_dir = flow_direction_to_rankdir(u_jssm.flow() || 'down');
|
|
@@ -24715,16 +24723,18 @@ function machine_to_dot(u_jssm, opts) {
|
|
|
24715
24723
|
* import { fsl_to_dot } from 'jssm/viz';
|
|
24716
24724
|
* const dot = fsl_to_dot('a -> b;');
|
|
24717
24725
|
*
|
|
24726
|
+
* // suppress state-name labels
|
|
24727
|
+
* const dot2 = fsl_to_dot('a -> b;', { hide_state_labels: true });
|
|
24728
|
+
*
|
|
24718
24729
|
* const dot_with_footer = fsl_to_dot('a -> b;', { footer: 'label="caption";' });
|
|
24719
24730
|
* // 'digraph G { ... label="caption"; }'
|
|
24720
24731
|
* ```
|
|
24721
24732
|
*
|
|
24722
24733
|
* @param fsl The FSL source.
|
|
24723
|
-
* @param opts Optional
|
|
24724
|
-
* @param opts.footer Optional verbatim dot source inserted just before the closing `}`.
|
|
24734
|
+
* @param opts Optional render flags. See {@link VizRenderOpts}.
|
|
24725
24735
|
* @returns A complete graphviz dot source string.
|
|
24726
24736
|
*/
|
|
24727
|
-
function fsl_to_dot(fsl, opts) {
|
|
24737
|
+
function fsl_to_dot(fsl, opts = {}) {
|
|
24728
24738
|
return machine_to_dot(sm `${fsl}`, opts);
|
|
24729
24739
|
}
|
|
24730
24740
|
/**
|
|
@@ -24757,13 +24767,10 @@ async function dot_to_svg(dot, options) {
|
|
|
24757
24767
|
* ```
|
|
24758
24768
|
*
|
|
24759
24769
|
* @param fsl The FSL source.
|
|
24760
|
-
* @param opts Optional
|
|
24761
|
-
* @param opts.footer Optional verbatim dot source inserted just before the closing `}` of the intermediate dot source.
|
|
24762
|
-
* @param opts.engine Graphviz layout engine to use (e.g. `'dot'`, `'neato'`, `'circo'`).
|
|
24763
|
-
* Unrecognized engine names cause `@viz-js/viz` to throw at render time.
|
|
24770
|
+
* @param opts Optional render flags. See {@link VizRenderOpts}.
|
|
24764
24771
|
* @returns A promise resolving to an SVG XML string.
|
|
24765
24772
|
*/
|
|
24766
|
-
async function fsl_to_svg_string(fsl, opts) {
|
|
24773
|
+
async function fsl_to_svg_string(fsl, opts = {}) {
|
|
24767
24774
|
return dot_to_svg(fsl_to_dot(fsl, opts), opts);
|
|
24768
24775
|
}
|
|
24769
24776
|
|