@zenuml/core 2.0.21 → 2.0.23
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/cy/defect-406-alt-under-creation.html +2 -1
- package/cy/smoke-creation.html +2 -1
- package/cy/smoke-fragment-issue.html +2 -1
- package/cy/smoke-fragment.html +2 -1
- package/cy/smoke-interaction.html +2 -1
- package/cy/smoke-return.html +2 -1
- package/cy/smoke.html +2 -1
- package/dist/zenuml-core.mjs +7 -7
- package/dist/zenuml-core.umd.js +1 -1
- package/package.json +1 -1
package/cy/smoke-creation.html
CHANGED
package/cy/smoke-fragment.html
CHANGED
package/cy/smoke-return.html
CHANGED
package/cy/smoke.html
CHANGED
package/dist/zenuml-core.mjs
CHANGED
|
@@ -26097,16 +26097,16 @@ const Zy = {
|
|
|
26097
26097
|
e || (e = document.createElement("style"), e.id = t, document.head.append(e)), e.textContent = n;
|
|
26098
26098
|
},
|
|
26099
26099
|
setRemoteCss(n) {
|
|
26100
|
-
|
|
26101
|
-
|
|
26102
|
-
|
|
26100
|
+
const t = new URL(n).hostname;
|
|
26101
|
+
if (t === "https://github.com" || t === "https://githubusercontent.com") {
|
|
26102
|
+
fetch(n.replace("github.com", "raw.githubusercontent.com").replace("blob/", "")).then((s) => s.text()).then((s) => {
|
|
26103
|
+
this.setStyle(s);
|
|
26103
26104
|
});
|
|
26104
26105
|
return;
|
|
26105
26106
|
}
|
|
26106
|
-
|
|
26107
|
-
|
|
26108
|
-
|
|
26109
|
-
e || (e = document.createElement("link"), e.id = t, e.rel = "stylesheet", document.head.append(e)), e.href = n;
|
|
26107
|
+
const e = "zenuml-remote-css";
|
|
26108
|
+
let r = document.getElementById(e);
|
|
26109
|
+
r || (r = document.createElement("link"), r.id = e, r.rel = "stylesheet", document.head.append(r)), r.href = n;
|
|
26110
26110
|
}
|
|
26111
26111
|
},
|
|
26112
26112
|
components: {
|
package/dist/zenuml-core.umd.js
CHANGED
|
@@ -502,7 +502,7 @@ A.method() {
|
|
|
502
502
|
A.method() {
|
|
503
503
|
@return A->B: message
|
|
504
504
|
}`)])])])])},function(){var n=this,t=n.$createElement,e=n._self._c||t;return e("p",{staticClass:"text-sm text-gray-500"},[n._v(" Use "),e("span",{staticClass:"rounded inline-block bg-gray-50 text-gray-600"},[e("code",{staticClass:"text-xs"},[n._v("@Actor TheParticipant")])]),n._v(" to define the type of the participant. ")])}];const TL={name:"TipsDialog",components:{IconList:EL},computed:{standardTypes(){return["Actor","Boundary","Control","Database","Entity"]},awsServices(){return["CloudWatch","CloudFront","Cognito","DynamoDB","EBS","EC2","ECS","EFS","ElastiCache","ElasticBeantalk","ElasticFileSystem","Glacier","IAM","Kinesis","Lambda","LightSail","RDS","Redshift","S3","SNS","SQS","Sagemaker","VPC"]},azureServices(){return["AzureActiveDirectory","AzureBackup","AzureCDN","AzureDataFactory","AzureDevOps","AzureFunction","AzureSQL","CosmosDB","LogicApps","VirtualMachine"]},googleServices(){return["BigTable","BigQuery","CloudCDN","CloudDNS","CloudInterconnect","CloudLoadBalancing","CloudSQL","CloudStorage","DataLab","DataProc","GoogleIAM","GoogleSecurity","GoogleVPC","PubSub","SecurityScanner","StackDriver","VisionAPI"]}},methods:{closeTipsDialog(){var n;this.$store.state.showTips=!1;try{(n=this.$gtag)==null||n.event("close",{event_category:"help",event_label:"tips dialog"})}catch(t){console.error(t)}}}},mh={};var AL=tt(TL,bL,wL,!1,SL,null,null,null);function SL(n){for(let t in mh)this[t]=mh[t]}const RL=function(){return AL.exports}();var kL=function(){var n=this,t=n.$createElement,e=n._self._c||t;return e("div",{staticClass:"point text-skin-message-arrow",class:{fill:n.fill,"no-fill":!n.fill,"right-to-left":n.rtl}},[n.rtl?n._e():e("svg",{staticClass:"arrow stroke-2",attrs:{height:"10",width:"10"}},[e("polyline",{staticClass:"right head fill-current stroke-current",attrs:{points:"0,0 10,5 0,10"}})]),n.rtl?e("svg",{staticClass:"arrow stroke-2",attrs:{height:"10",width:"10"}},[e("polyline",{staticClass:"left head fill-current stroke-current",attrs:{points:"10,0 0,5 10,10"}})]):n._e()])},OL=[];const gw="",NL={name:"point",props:["fill","rtl"]},_h={};var IL=tt(NL,kL,OL,!1,PL,"340f62e6",null,null);function PL(n){for(let t in _h)this[t]=_h[t]}const ML=function(){return IL.exports}();var $L=function(){var n=this,t=n.$createElement,e=n._self._c||t;return e("div",{staticClass:"message border-skin-message-arrow border-b-2 flex items-end",class:{"flex-row-reverse":n.rtl,return:n.type==="return","right-to-left":n.rtl,"text-left":n.isAsync,"text-center":!n.isAsync},style:{"border-bottom-style":n.borderStyle}},[e("div",{staticClass:"name flex-grow text-sm truncate hover:whitespace-normal hover:text-skin-message-hover hover:bg-skin-message-hover",staticStyle:{"padding-left":"5px",float:"left"},style:{color:n.color}},[n._v(" "+n._s(n.content)+" ")]),e("point",{staticClass:"flex-shrink-0 transform translate-y-1/2 -my-px",attrs:{fill:n.fill,rtl:n.rtl}})],1)},DL=[];const FL={name:"message",props:["content","rtl","type","color"],computed:{isAsync:function(){return this.type==="async"},borderStyle(){switch(this.type){case"sync":case"async":return"solid";case"creation":case"return":return"dashed"}return""},fill(){switch(this.type){case"sync":case"async":return!0;case"creation":case"return":return!1}return!1}},components:{Point:ML}},Lh={};var BL=tt(FL,$L,DL,!1,UL,null,null,null);function UL(n){for(let t in Lh)this[t]=Lh[t]}const zr=function(){return BL.exports}();var HL=function(){var n=this,t=n.$createElement,e=n._self._c||t;return e("div",{staticClass:"invisible"},[e("message",{attrs:{content:n.text,rtl:"false",type:"sync"}})],1)},GL=[];const jL={name:"WidthProvider",components:{Message:zr},data:function(){return{text:"abcd"}},methods:{width:function(n,t){return console.log(n,t),this.text=n,this.$el.clientWidth}},mounted(){this.$store.state.widthProvider=this}},vh={};var VL=tt(jL,HL,GL,!1,zL,null,null,null);function zL(n){for(let t in vh)this[t]=vh[t]}const ZL=function(){return VL.exports}();function qL(n,t){if(n.match(/^[a-z]+:\/\//i))return n;if(n.match(/^\/\//))return window.location.protocol+n;if(n.match(/^[a-z]+:/i))return n;const e=document.implementation.createHTMLDocument(),r=e.createElement("base"),s=e.createElement("a");return e.head.appendChild(r),e.body.appendChild(s),t&&(r.href=t),s.href=n,s.href}const WL=(()=>{let n=0;const t=()=>`0000${(Math.random()*36**4<<0).toString(36)}`.slice(-4);return()=>(n+=1,`u${t()}${n}`)})();function Xe(n){const t=[];for(let e=0,r=n.length;e<r;e++)t.push(n[e]);return t}function yi(n,t){const r=(n.ownerDocument.defaultView||window).getComputedStyle(n).getPropertyValue(t);return r?parseFloat(r.replace("px","")):0}function KL(n){const t=yi(n,"border-left-width"),e=yi(n,"border-right-width");return n.clientWidth+t+e}function YL(n){const t=yi(n,"border-top-width"),e=yi(n,"border-bottom-width");return n.clientHeight+t+e}function yh(n,t={}){const e=t.width||KL(n),r=t.height||YL(n);return{width:e,height:r}}function XL(){let n,t;try{t=process}catch{}const e=t&&t.env?t.env.devicePixelRatio:null;return e&&(n=parseInt(e,10),Number.isNaN(n)&&(n=1)),n||window.devicePixelRatio||1}const re=16384;function QL(n){(n.width>re||n.height>re)&&(n.width>re&&n.height>re?n.width>n.height?(n.height*=re/n.width,n.width=re):(n.width*=re/n.height,n.height=re):n.width>re?(n.height*=re/n.width,n.width=re):(n.width*=re/n.height,n.height=re))}function JL(n,t={}){return n.toBlob?new Promise(e=>{n.toBlob(e,t.type?t.type:"image/png",t.quality?t.quality:1)}):new Promise(e=>{const r=window.atob(n.toDataURL(t.type?t.type:void 0,t.quality?t.quality:void 0).split(",")[1]),s=r.length,i=new Uint8Array(s);for(let o=0;o<s;o+=1)i[o]=r.charCodeAt(o);e(new Blob([i],{type:t.type?t.type:"image/png"}))})}function Ci(n){return new Promise((t,e)=>{const r=new Image;r.decode=()=>t(r),r.onload=()=>t(r),r.onerror=e,r.crossOrigin="anonymous",r.decoding="async",r.src=n})}async function tv(n){return Promise.resolve().then(()=>new XMLSerializer().serializeToString(n)).then(encodeURIComponent).then(t=>`data:image/svg+xml;charset=utf-8,${t}`)}async function ev(n,t,e){const r="http://www.w3.org/2000/svg",s=document.createElementNS(r,"svg"),i=document.createElementNS(r,"foreignObject");return s.setAttribute("width",`${t}`),s.setAttribute("height",`${e}`),s.setAttribute("viewBox",`0 0 ${t} ${e}`),i.setAttribute("width","100%"),i.setAttribute("height","100%"),i.setAttribute("x","0"),i.setAttribute("y","0"),i.setAttribute("externalResourcesRequired","true"),s.appendChild(i),i.appendChild(n),tv(s)}function nv(n){const t=n.getPropertyValue("content");return`${n.cssText} content: '${t.replace(/'|"/g,"")}';`}function rv(n){return Xe(n).map(t=>{const e=n.getPropertyValue(t),r=n.getPropertyPriority(t);return`${t}: ${e}${r?" !important":""};`}).join(" ")}function sv(n,t,e){const r=`.${n}:${t}`,s=e.cssText?nv(e):rv(e);return document.createTextNode(`${r}{${s}}`)}function Ch(n,t,e){const r=window.getComputedStyle(n,e),s=r.getPropertyValue("content");if(s===""||s==="none")return;const i=WL();try{t.className=`${t.className} ${i}`}catch{return}const o=document.createElement("style");o.appendChild(sv(i,e,r)),t.appendChild(o)}function iv(n,t){Ch(n,t,":before"),Ch(n,t,":after")}const Eh="application/font-woff",bh="image/jpeg",ov={woff:Eh,woff2:Eh,ttf:"application/font-truetype",eot:"application/vnd.ms-fontobject",png:"image/png",jpg:bh,jpeg:bh,gif:"image/gif",tiff:"image/tiff",svg:"image/svg+xml",webp:"image/webp"};function av(n){const t=/\.([^./]*?)$/g.exec(n);return t?t[1]:""}function g1(n){const t=av(n).toLowerCase();return ov[t]||""}function lv(n){return n.split(/,/)[1]}function x1(n){return n.search(/^(data:)/)!==-1}function wh(n,t){return`data:${t};base64,${n}`}async function Th(n,t,e){const r=await fetch(n,t);if(r.status===404)throw new Error(`Resource "${r.url}" not found`);const s=await r.blob();return new Promise((i,o)=>{const a=new FileReader;a.onerror=o,a.onloadend=()=>{try{i(e({res:r,result:a.result}))}catch(l){o(l)}},a.readAsDataURL(s)})}const m1={};function cv(n,t,e){let r=n.replace(/\?.*/,"");return e&&(r=n),/ttf|otf|eot|woff2?/i.test(r)&&(r=r.replace(/.*\//,"")),t?`[${t}]${r}`:r}async function _1(n,t,e){const r=cv(n,t,e.includeQueryParams);if(m1[r]!=null)return m1[r];e.cacheBust&&(n+=(/\?/.test(n)?"&":"?")+new Date().getTime());let s;try{const i=await Th(n,e.fetchRequestInit,({res:o,result:a})=>(t||(t=o.headers.get("Content-Type")||""),lv(a)));s=wh(i,t)}catch(i){s=e.imagePlaceholder||"";let o=`Failed to fetch resource: ${n}`;i&&(o=typeof i=="string"?i:i.message),o&&console.warn(o)}return m1[r]=s,s}async function uv(n){const t=n.toDataURL();return t==="data:,"?n.cloneNode(!1):Ci(t)}async function hv(n,t){if(n.currentSrc){const i=document.createElement("canvas"),o=i.getContext("2d");i.width=n.clientWidth,i.height=n.clientHeight,o==null||o.drawImage(n,0,0,i.width,i.height);const a=i.toDataURL();return Ci(a)}const e=n.poster,r=g1(e),s=await _1(e,r,t);return Ci(s)}async function fv(n){var t;try{if(!((t=n==null?void 0:n.contentDocument)===null||t===void 0)&&t.body)return await Ei(n.contentDocument.body,{},!0)}catch{}return n.cloneNode(!1)}async function dv(n,t){return n instanceof HTMLCanvasElement?uv(n):n instanceof HTMLVideoElement?hv(n,t):n instanceof HTMLIFrameElement?fv(n):n.cloneNode(!1)}const pv=n=>n.tagName!=null&&n.tagName.toUpperCase()==="SLOT";async function gv(n,t,e){var r;const s=pv(n)&&n.assignedNodes?Xe(n.assignedNodes()):Xe(((r=n.shadowRoot)!==null&&r!==void 0?r:n).childNodes);return s.length===0||n instanceof HTMLVideoElement||await s.reduce((i,o)=>i.then(()=>Ei(o,e)).then(a=>{a&&t.appendChild(a)}),Promise.resolve()),t}function xv(n,t){const e=t.style;if(!e)return;const r=window.getComputedStyle(n);r.cssText?(e.cssText=r.cssText,e.transformOrigin=r.transformOrigin):Xe(r).forEach(s=>{let i=r.getPropertyValue(s);s==="font-size"&&i.endsWith("px")&&(i=`${Math.floor(parseFloat(i.substring(0,i.length-2)))-.1}px`),e.setProperty(s,i,r.getPropertyPriority(s))})}function mv(n,t){n instanceof HTMLTextAreaElement&&(t.innerHTML=n.value),n instanceof HTMLInputElement&&t.setAttribute("value",n.value)}function _v(n,t){if(n instanceof HTMLSelectElement){const e=t,r=Array.from(e.children).find(s=>n.value===s.getAttribute("value"));r&&r.setAttribute("selected","")}}function Lv(n,t){return t instanceof Element&&(xv(n,t),iv(n,t),mv(n,t),_v(n,t)),t}async function vv(n,t){const e=n.querySelectorAll?n.querySelectorAll("use"):[];if(e.length===0)return n;const r={};for(let i=0;i<e.length;i++){const a=e[i].getAttribute("xlink:href");if(a){const l=n.querySelector(a),c=document.querySelector(a);!l&&c&&!r[a]&&(r[a]=await Ei(c,t,!0))}}const s=Object.values(r);if(s.length){const i="http://www.w3.org/1999/xhtml",o=document.createElementNS(i,"svg");o.setAttribute("xmlns",i),o.style.position="absolute",o.style.width="0",o.style.height="0",o.style.overflow="hidden",o.style.display="none";const a=document.createElementNS(i,"defs");o.appendChild(a);for(let l=0;l<s.length;l++)a.appendChild(s[l]);n.appendChild(o)}return n}async function Ei(n,t,e){return!e&&t.filter&&!t.filter(n)?null:Promise.resolve(n).then(r=>dv(r,t)).then(r=>gv(n,r,t)).then(r=>Lv(n,r)).then(r=>vv(r,t))}const Ah=/url\((['"]?)([^'"]+?)\1\)/g,yv=/url\([^)]+\)\s*format\((["']?)([^"']+)\1\)/g,Cv=/src:\s*(?:url\([^)]+\)\s*format\([^)]+\)[,;]\s*)+/g;function Ev(n){const t=n.replace(/([.*+?^${}()|\[\]\/\\])/g,"\\$1");return new RegExp(`(url\\(['"]?)(${t})(['"]?\\))`,"g")}function bv(n){const t=[];return n.replace(Ah,(e,r,s)=>(t.push(s),e)),t.filter(e=>!x1(e))}async function wv(n,t,e,r,s){try{const i=e?qL(t,e):t,o=g1(t);let a;if(s){const l=await s(i);a=wh(l,o)}else a=await _1(i,o,r);return n.replace(Ev(t),`$1${a}$3`)}catch{}return n}function Tv(n,{preferredFontFormat:t}){return t?n.replace(Cv,e=>{for(;;){const[r,,s]=yv.exec(e)||[];if(!s)return"";if(s===t)return`src: ${r};`}}):n}function Sh(n){return n.search(Ah)!==-1}async function Rh(n,t,e){if(!Sh(n))return n;const r=Tv(n,e);return bv(r).reduce((i,o)=>i.then(a=>wv(a,o,t,e)),Promise.resolve(r))}async function Av(n,t){var e;const r=(e=n.style)===null||e===void 0?void 0:e.getPropertyValue("background");if(r){const s=await Rh(r,null,t);n.style.setProperty("background",s,n.style.getPropertyPriority("background"))}}async function Sv(n,t){if(!(n instanceof HTMLImageElement&&!x1(n.src))&&!(n instanceof SVGImageElement&&!x1(n.href.baseVal)))return;const e=n instanceof HTMLImageElement?n.src:n.href.baseVal,r=await _1(e,g1(e),t);await new Promise((s,i)=>{n.onload=s,n.onerror=i;const o=n;o.decode&&(o.decode=s),n instanceof HTMLImageElement?(n.srcset="",n.src=r):n.href.baseVal=r})}async function Rv(n,t){const r=Xe(n.childNodes).map(s=>kh(s,t));await Promise.all(r).then(()=>n)}async function kh(n,t){n instanceof Element&&(await Av(n,t),await Sv(n,t),await Rv(n,t))}function kv(n,t){const{style:e}=n;t.backgroundColor&&(e.backgroundColor=t.backgroundColor),t.width&&(e.width=`${t.width}px`),t.height&&(e.height=`${t.height}px`);const r=t.style;return r!=null&&Object.keys(r).forEach(s=>{e[s]=r[s]}),n}const Oh={};async function Nh(n){let t=Oh[n];if(t!=null)return t;const r=await(await fetch(n)).text();return t={url:n,cssText:r},Oh[n]=t,t}async function Ih(n,t){let e=n.cssText;const r=/url\(["']?([^"')]+)["']?\)/g,i=(e.match(/url\([^)]+\)/g)||[]).map(async o=>{let a=o.replace(r,"$1");return a.startsWith("https://")||(a=new URL(a,n.url).href),Th(a,t.fetchRequestInit,({result:l})=>(e=e.replace(o,`url(${l})`),[o,l]))});return Promise.all(i).then(()=>e)}function Ph(n){if(n==null)return[];const t=[],e=/(\/\*[\s\S]*?\*\/)/gi;let r=n.replace(e,"");const s=new RegExp("((@.*?keyframes [\\s\\S]*?){([\\s\\S]*?}\\s*?)})","gi");for(;;){const l=s.exec(r);if(l===null)break;t.push(l[0])}r=r.replace(s,"");const i=/@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi,o="((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})",a=new RegExp(o,"gi");for(;;){let l=i.exec(r);if(l===null){if(l=a.exec(r),l===null)break;i.lastIndex=a.lastIndex}else a.lastIndex=i.lastIndex;t.push(l[0])}return t}async function Ov(n,t){const e=[],r=[];return n.forEach(s=>{if("cssRules"in s)try{Xe(s.cssRules||[]).forEach((i,o)=>{if(i.type===CSSRule.IMPORT_RULE){let a=o+1;const l=i.href,c=Nh(l).then(u=>Ih(u,t)).then(u=>Ph(u).forEach(f=>{try{s.insertRule(f,f.startsWith("@import")?a+=1:s.cssRules.length)}catch(d){console.error("Error inserting rule from remote css",{rule:f,error:d})}})).catch(u=>{console.error("Error loading remote css",u.toString())});r.push(c)}})}catch(i){const o=n.find(a=>a.href==null)||document.styleSheets[0];s.href!=null&&r.push(Nh(s.href).then(a=>Ih(a,t)).then(a=>Ph(a).forEach(l=>{o.insertRule(l,s.cssRules.length)})).catch(a=>{console.error("Error loading remote stylesheet",a.toString())})),console.error("Error inlining remote css file",i.toString())}}),Promise.all(r).then(()=>(n.forEach(s=>{if("cssRules"in s)try{Xe(s.cssRules||[]).forEach(i=>{e.push(i)})}catch(i){console.error(`Error while reading CSS rules from ${s.href}`,i.toString())}}),e))}function Nv(n){return n.filter(t=>t.type===CSSRule.FONT_FACE_RULE).filter(t=>Sh(t.style.getPropertyValue("src")))}async function Iv(n,t){if(n.ownerDocument==null)throw new Error("Provided element is not within a Document");const e=Xe(n.ownerDocument.styleSheets),r=await Ov(e,t);return Nv(r)}async function Pv(n,t){const e=await Iv(n,t);return(await Promise.all(e.map(s=>{const i=s.parentStyleSheet?s.parentStyleSheet.href:null;return Rh(s.cssText,i,t)}))).join(`
|
|
505
|
-
`)}async function Mv(n,t){const e=t.fontEmbedCSS!=null?t.fontEmbedCSS:t.skipFonts?null:await Pv(n,t);if(e){const r=document.createElement("style"),s=document.createTextNode(e);r.appendChild(s),n.firstChild?n.insertBefore(r,n.firstChild):n.appendChild(r)}}async function Mh(n,t={}){const{width:e,height:r}=yh(n,t),s=await Ei(n,t,!0);return await Mv(s,t),await kh(s,t),kv(s,t),await ev(s,e,r)}async function L1(n,t={}){const{width:e,height:r}=yh(n,t),s=await Mh(n,t),i=await Ci(s),o=document.createElement("canvas"),a=o.getContext("2d"),l=t.pixelRatio||XL(),c=t.canvasWidth||e,u=t.canvasHeight||r;return o.width=c*l,o.height=u*l,t.skipAutoScale||QL(o),o.style.width=`${c}`,o.style.height=`${u}`,t.backgroundColor&&(a.fillStyle=t.backgroundColor,a.fillRect(0,0,o.width,o.height)),a.drawImage(i,0,0,o.width,o.height),o}async function $v(n,t={}){return(await L1(n,t)).toDataURL()}async function Dv(n,t={}){return(await L1(n,t)).toDataURL("image/jpeg",t.quality||1)}async function Fv(n,t={}){const e=await L1(n,t);return await JL(e)}var Bv=function(){var n=this,t=n.$createElement,e=n._self._c||t;return e("div",{directives:[{name:"show",rawName:"v-show",value:n.debug,expression:"debug"}]},[e("div",{staticClass:"flex flex-nowrap m-2 text-sm"},[e("div",{staticClass:"ml-4 text-xs inline-flex items-center font-bold leading-sm px-3 py-1 bg-green-200 text-green-700 rounded-sm"},[e("svg",{staticClass:"h-4 w-4",attrs:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}},[e("line",{attrs:{x1:"6",y1:"3",x2:"6",y2:"15"}}),e("circle",{attrs:{cx:"18",cy:"6",r:"3"}}),e("circle",{attrs:{cx:"6",cy:"18",r:"3"}}),e("path",{attrs:{d:"M18 9a9 9 0 0 1-9 9"}})]),e("span",{staticClass:"inline-block px-2"},[n._v(n._s(n.gitBranch)+":"+n._s(n.commitHash))])])])])},Uv=[];const Hv="process.env.VUE_APP_GIT_HASH",Gv="process.env.VUE_APP_GIT_BRANCH",jv={name:"Debug",data(){return{commitHash:Hv,gitBranch:Gv}},computed:{debug(){return!!localStorage.zenumlDebug}}},$h={};var Vv=tt(jv,Bv,Uv,!1,zv,null,null,null);function zv(n){for(let t in $h)this[t]=$h[t]}const Zv=function(){return Vv.exports}();var qv=function(){var n=this,t=n.$createElement,e=n._self._c||t;return e("div",{ref:"export",staticClass:"zenuml p-1 bg-skin-canvas",class:n.theme,staticStyle:{display:"inline-block"}},[e("debug"),e("div",{staticClass:"frame text-skin-frame bg-skin-frame border-skin-frame relative m-1 origin-top-left whitespace-nowrap border rounded",style:{transform:`scale(${n.scale})`}},[e("div",{ref:"content"},[e("div",{staticClass:"header text-skin-title bg-skin-title border-skin-frame border-b p-1 flex justify-between rounded-t"},[e("div",{staticClass:"left hide-export"},[n._t("default")],2),e("div",{staticClass:"right flex-grow flex justify-between"},[e("diagram-title",{attrs:{context:n.title}}),e("privacy",{staticClass:"hide-export flex items-center"})],1)]),e("div",[n.showTips?e("div",{staticClass:"fixed z-40 inset-0 overflow-y-auto",attrs:{"aria-labelledby":"modal-title",role:"dialog","aria-modal":"true"}},[e("TipsDialog")],1):n._e()]),e("seq-diagram")],1),e("div",{staticClass:"footer p-1 flex justify-between"},[e("button",{staticClass:"bottom-1 left-1 hide-export",on:{click:function(r){return n.showTipsDialog()}}},[e("svg",{staticClass:"filter grayscale",staticStyle:{width:"1em",height:"1em","vertical-align":"middle",fill:"currentColor",overflow:"hidden"},attrs:{viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg"}},[e("path",{attrs:{d:"M514 912c-219.9 0-398.8-178.9-398.8-398.9 0-219.9 178.9-398.8 398.8-398.8s398.9 178.9 398.9 398.8c-0.1 220-179 398.9-398.9 398.9z m0-701.5c-166.9 0-302.7 135.8-302.7 302.7S347.1 815.9 514 815.9s302.7-135.8 302.7-302.7S680.9 210.5 514 210.5z",fill:"#BDD2EF"}}),e("path",{attrs:{d:"M431.1 502.4c-0.1 0.3 0.3 0.4 0.4 0.2 6.9-11.7 56.5-89.1 23.4 167.3-17.4 134.7 122.9 153.6 142.3-7.9 0.1-1-1.3-1.4-1.7-0.4-11.9 37.2-49.6 104.9-4.7-155.2 18.6-107.2-127.6-146-159.7-4z",fill:"#2867CE"}}),e("path",{attrs:{d:"M541.3 328m-68 0a68 68 0 1 0 136 0 68 68 0 1 0-136 0Z",fill:"#2867CE"}})])]),e("div",{staticClass:"zoom-controls bg-skin-base text-skin-control flex justify-between w-28 hide-export",style:{transform:`scale(${1/n.scale})`}},[e("button",{staticClass:"zoom-in px-1",on:{click:function(r){return n.zoomIn()}}},[n._v("+")]),e("label",[n._v(n._s(Number(n.scale*100).toFixed(0))+" %")]),e("button",{staticClass:"zoom-out px-1",on:{click:function(r){return n.zoomOut()}}},[n._v("-")])]),e("width-provider"),e("a",{staticClass:"brand text-skin-link absolute bottom-1 right-1 text-xs",attrs:{target:"_blank",href:"https://zenuml.com"}},[n._v("ZenUML.com")])],1)])],1)},Wv=[];const Kv={name:"DiagramFrame",computed:{...Cr(["showTips","scale","theme"]),...Dt(["rootContext"]),title(){var n;return this.rootContext||console.error("`rootContext` is empty. Please make sure `store` is properly configured."),(n=this.rootContext)==null?void 0:n.title()}},methods:{...Er(["setScale"]),showTipsDialog(){var n;this.$store.state.showTips=!0;try{(n=this.$gtag)==null||n.event("view",{event_category:"help",event_label:"tips dialog"})}catch(t){console.error(t)}},toPng(){return $v(this.$refs.export,{backgroundColor:"white",filter:n=>{var t;return!((t=n==null?void 0:n.classList)!=null&&t.contains("hide-export"))}})},toSvg(){return Mh(this.$refs.export,{backgroundColor:"white",filter:n=>{var t;return!((t=n==null?void 0:n.classList)!=null&&t.contains("hide-export"))}})},toBlob(){return Fv(this.$refs.export,{backgroundColor:"white",filter:n=>{var t;return!((t=n==null?void 0:n.classList)!=null&&t.contains("hide-export"))}})},toJpeg(){return Dv(this.$refs.export,{backgroundColor:"white",filter:n=>{var t;return!((t=n==null?void 0:n.classList)!=null&&t.contains("hide-export"))}})},zoomIn(){this.setScale(this.scale+.1)},zoomOut(){this.setScale(this.scale-.1)},setTheme(n){this.theme=n},setStyle(n){const t="zenuml-style";let e=document.getElementById(t);e||(e=document.createElement("style"),e.id=t,document.head.append(e)),e.textContent=n},setRemoteCss(n){if(n.includes("https://github.com")||n.includes("https://githubusercontent.com")){fetch(n.replace("github.com","raw.githubusercontent.com").replace("blob/","")).then(r=>r.text()).then(r=>{this.setStyle(r)});return}console.log("setRemoteCss",n);const t="zenuml-remote-css";let e=document.getElementById(t);e||(e=document.createElement("link"),e.id=t,e.rel="stylesheet",document.head.append(e)),e.href=n}},components:{Debug:Zv,WidthProvider:ZL,TipsDialog:RL,DiagramTitle:L_,SeqDiagram:p1,Privacy:d_}},Dh={};var Yv=tt(Kv,qv,Wv,!1,Xv,null,null,null);function Xv(n){for(let t in Dh)this[t]=Dh[t]}const Fh=function(){return Yv.exports}(),xw="",mw="",_w="",Lw="",vw="",yw="",Cw="";function Bh(){return{baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}let Yn=Bh();function Qv(n){Yn=n}const Jv=/[&<>"']/,ty=/[&<>"']/g,ey=/[<>"']|&(?!#?\w+;)/,ny=/[<>"']|&(?!#?\w+;)/g,ry={"&":"&","<":"<",">":">",'"':""","'":"'"},Uh=n=>ry[n];function Tt(n,t){if(t){if(Jv.test(n))return n.replace(ty,Uh)}else if(ey.test(n))return n.replace(ny,Uh);return n}const sy=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function Hh(n){return n.replace(sy,(t,e)=>(e=e.toLowerCase(),e==="colon"?":":e.charAt(0)==="#"?e.charAt(1)==="x"?String.fromCharCode(parseInt(e.substring(2),16)):String.fromCharCode(+e.substring(1)):""))}const iy=/(^|[^\[])\^/g;function it(n,t){n=n.source||n,t=t||"";const e={replace:(r,s)=>(s=s.source||s,s=s.replace(iy,"$1"),n=n.replace(r,s),e),getRegex:()=>new RegExp(n,t)};return e}const oy=/[^\w:]/g,ay=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function Gh(n,t,e){if(n){let r;try{r=decodeURIComponent(Hh(e)).replace(oy,"").toLowerCase()}catch{return null}if(r.indexOf("javascript:")===0||r.indexOf("vbscript:")===0||r.indexOf("data:")===0)return null}t&&!ay.test(e)&&(e=hy(t,e));try{e=encodeURI(e).replace(/%25/g,"%")}catch{return null}return e}const bi={},ly=/^[^:]+:\/*[^/]*$/,cy=/^([^:]+:)[\s\S]*$/,uy=/^([^:]+:\/*[^/]*)[\s\S]*$/;function hy(n,t){bi[" "+n]||(ly.test(n)?bi[" "+n]=n+"/":bi[" "+n]=Ti(n,"/",!0)),n=bi[" "+n];const e=n.indexOf(":")===-1;return t.substring(0,2)==="//"?e?t:n.replace(cy,"$1")+t:t.charAt(0)==="/"?e?t:n.replace(uy,"$1")+t:n+t}const wi={exec:function(){}};function pe(n){let t=1,e,r;for(;t<arguments.length;t++){e=arguments[t];for(r in e)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r])}return n}function jh(n,t){const e=n.replace(/\|/g,(i,o,a)=>{let l=!1,c=o;for(;--c>=0&&a[c]==="\\";)l=!l;return l?"|":" |"}),r=e.split(/ \|/);let s=0;if(r[0].trim()||r.shift(),r[r.length-1].trim()||r.pop(),r.length>t)r.splice(t);else for(;r.length<t;)r.push("");for(;s<r.length;s++)r[s]=r[s].trim().replace(/\\\|/g,"|");return r}function Ti(n,t,e){const r=n.length;if(r===0)return"";let s=0;for(;s<r;){const i=n.charAt(r-s-1);if(i===t&&!e)s++;else if(i!==t&&e)s++;else break}return n.substr(0,r-s)}function fy(n,t){if(n.indexOf(t[1])===-1)return-1;const e=n.length;let r=0,s=0;for(;s<e;s++)if(n[s]==="\\")s++;else if(n[s]===t[0])r++;else if(n[s]===t[1]&&(r--,r<0))return s;return-1}function Vh(n){n&&n.sanitize&&!n.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")}function zh(n,t){if(t<1)return"";let e="";for(;t>1;)t&1&&(e+=n),t>>=1,n+=n;return e+n}function Zh(n,t,e,r){const s=t.href,i=t.title?Tt(t.title):null,o=n[1].replace(/\\([\[\]])/g,"$1");if(n[0].charAt(0)!=="!"){r.state.inLink=!0;const a={type:"link",raw:e,href:s,title:i,text:o,tokens:r.inlineTokens(o,[])};return r.state.inLink=!1,a}else return{type:"image",raw:e,href:s,title:i,text:Tt(o)}}function dy(n,t){const e=n.match(/^(\s+)(?:```)/);if(e===null)return t;const r=e[1];return t.split(`
|
|
505
|
+
`)}async function Mv(n,t){const e=t.fontEmbedCSS!=null?t.fontEmbedCSS:t.skipFonts?null:await Pv(n,t);if(e){const r=document.createElement("style"),s=document.createTextNode(e);r.appendChild(s),n.firstChild?n.insertBefore(r,n.firstChild):n.appendChild(r)}}async function Mh(n,t={}){const{width:e,height:r}=yh(n,t),s=await Ei(n,t,!0);return await Mv(s,t),await kh(s,t),kv(s,t),await ev(s,e,r)}async function L1(n,t={}){const{width:e,height:r}=yh(n,t),s=await Mh(n,t),i=await Ci(s),o=document.createElement("canvas"),a=o.getContext("2d"),l=t.pixelRatio||XL(),c=t.canvasWidth||e,u=t.canvasHeight||r;return o.width=c*l,o.height=u*l,t.skipAutoScale||QL(o),o.style.width=`${c}`,o.style.height=`${u}`,t.backgroundColor&&(a.fillStyle=t.backgroundColor,a.fillRect(0,0,o.width,o.height)),a.drawImage(i,0,0,o.width,o.height),o}async function $v(n,t={}){return(await L1(n,t)).toDataURL()}async function Dv(n,t={}){return(await L1(n,t)).toDataURL("image/jpeg",t.quality||1)}async function Fv(n,t={}){const e=await L1(n,t);return await JL(e)}var Bv=function(){var n=this,t=n.$createElement,e=n._self._c||t;return e("div",{directives:[{name:"show",rawName:"v-show",value:n.debug,expression:"debug"}]},[e("div",{staticClass:"flex flex-nowrap m-2 text-sm"},[e("div",{staticClass:"ml-4 text-xs inline-flex items-center font-bold leading-sm px-3 py-1 bg-green-200 text-green-700 rounded-sm"},[e("svg",{staticClass:"h-4 w-4",attrs:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}},[e("line",{attrs:{x1:"6",y1:"3",x2:"6",y2:"15"}}),e("circle",{attrs:{cx:"18",cy:"6",r:"3"}}),e("circle",{attrs:{cx:"6",cy:"18",r:"3"}}),e("path",{attrs:{d:"M18 9a9 9 0 0 1-9 9"}})]),e("span",{staticClass:"inline-block px-2"},[n._v(n._s(n.gitBranch)+":"+n._s(n.commitHash))])])])])},Uv=[];const Hv="process.env.VUE_APP_GIT_HASH",Gv="process.env.VUE_APP_GIT_BRANCH",jv={name:"Debug",data(){return{commitHash:Hv,gitBranch:Gv}},computed:{debug(){return!!localStorage.zenumlDebug}}},$h={};var Vv=tt(jv,Bv,Uv,!1,zv,null,null,null);function zv(n){for(let t in $h)this[t]=$h[t]}const Zv=function(){return Vv.exports}();var qv=function(){var n=this,t=n.$createElement,e=n._self._c||t;return e("div",{ref:"export",staticClass:"zenuml p-1 bg-skin-canvas",class:n.theme,staticStyle:{display:"inline-block"}},[e("debug"),e("div",{staticClass:"frame text-skin-frame bg-skin-frame border-skin-frame relative m-1 origin-top-left whitespace-nowrap border rounded",style:{transform:`scale(${n.scale})`}},[e("div",{ref:"content"},[e("div",{staticClass:"header text-skin-title bg-skin-title border-skin-frame border-b p-1 flex justify-between rounded-t"},[e("div",{staticClass:"left hide-export"},[n._t("default")],2),e("div",{staticClass:"right flex-grow flex justify-between"},[e("diagram-title",{attrs:{context:n.title}}),e("privacy",{staticClass:"hide-export flex items-center"})],1)]),e("div",[n.showTips?e("div",{staticClass:"fixed z-40 inset-0 overflow-y-auto",attrs:{"aria-labelledby":"modal-title",role:"dialog","aria-modal":"true"}},[e("TipsDialog")],1):n._e()]),e("seq-diagram")],1),e("div",{staticClass:"footer p-1 flex justify-between"},[e("button",{staticClass:"bottom-1 left-1 hide-export",on:{click:function(r){return n.showTipsDialog()}}},[e("svg",{staticClass:"filter grayscale",staticStyle:{width:"1em",height:"1em","vertical-align":"middle",fill:"currentColor",overflow:"hidden"},attrs:{viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg"}},[e("path",{attrs:{d:"M514 912c-219.9 0-398.8-178.9-398.8-398.9 0-219.9 178.9-398.8 398.8-398.8s398.9 178.9 398.9 398.8c-0.1 220-179 398.9-398.9 398.9z m0-701.5c-166.9 0-302.7 135.8-302.7 302.7S347.1 815.9 514 815.9s302.7-135.8 302.7-302.7S680.9 210.5 514 210.5z",fill:"#BDD2EF"}}),e("path",{attrs:{d:"M431.1 502.4c-0.1 0.3 0.3 0.4 0.4 0.2 6.9-11.7 56.5-89.1 23.4 167.3-17.4 134.7 122.9 153.6 142.3-7.9 0.1-1-1.3-1.4-1.7-0.4-11.9 37.2-49.6 104.9-4.7-155.2 18.6-107.2-127.6-146-159.7-4z",fill:"#2867CE"}}),e("path",{attrs:{d:"M541.3 328m-68 0a68 68 0 1 0 136 0 68 68 0 1 0-136 0Z",fill:"#2867CE"}})])]),e("div",{staticClass:"zoom-controls bg-skin-base text-skin-control flex justify-between w-28 hide-export",style:{transform:`scale(${1/n.scale})`}},[e("button",{staticClass:"zoom-in px-1",on:{click:function(r){return n.zoomIn()}}},[n._v("+")]),e("label",[n._v(n._s(Number(n.scale*100).toFixed(0))+" %")]),e("button",{staticClass:"zoom-out px-1",on:{click:function(r){return n.zoomOut()}}},[n._v("-")])]),e("width-provider"),e("a",{staticClass:"brand text-skin-link absolute bottom-1 right-1 text-xs",attrs:{target:"_blank",href:"https://zenuml.com"}},[n._v("ZenUML.com")])],1)])],1)},Wv=[];const Kv={name:"DiagramFrame",computed:{...Cr(["showTips","scale","theme"]),...Dt(["rootContext"]),title(){var n;return this.rootContext||console.error("`rootContext` is empty. Please make sure `store` is properly configured."),(n=this.rootContext)==null?void 0:n.title()}},methods:{...Er(["setScale"]),showTipsDialog(){var n;this.$store.state.showTips=!0;try{(n=this.$gtag)==null||n.event("view",{event_category:"help",event_label:"tips dialog"})}catch(t){console.error(t)}},toPng(){return $v(this.$refs.export,{backgroundColor:"white",filter:n=>{var t;return!((t=n==null?void 0:n.classList)!=null&&t.contains("hide-export"))}})},toSvg(){return Mh(this.$refs.export,{backgroundColor:"white",filter:n=>{var t;return!((t=n==null?void 0:n.classList)!=null&&t.contains("hide-export"))}})},toBlob(){return Fv(this.$refs.export,{backgroundColor:"white",filter:n=>{var t;return!((t=n==null?void 0:n.classList)!=null&&t.contains("hide-export"))}})},toJpeg(){return Dv(this.$refs.export,{backgroundColor:"white",filter:n=>{var t;return!((t=n==null?void 0:n.classList)!=null&&t.contains("hide-export"))}})},zoomIn(){this.setScale(this.scale+.1)},zoomOut(){this.setScale(this.scale-.1)},setTheme(n){this.theme=n},setStyle(n){const t="zenuml-style";let e=document.getElementById(t);e||(e=document.createElement("style"),e.id=t,document.head.append(e)),e.textContent=n},setRemoteCss(n){const t=new URL(n).hostname;if(t==="https://github.com"||t==="https://githubusercontent.com"){fetch(n.replace("github.com","raw.githubusercontent.com").replace("blob/","")).then(s=>s.text()).then(s=>{this.setStyle(s)});return}const e="zenuml-remote-css";let r=document.getElementById(e);r||(r=document.createElement("link"),r.id=e,r.rel="stylesheet",document.head.append(r)),r.href=n}},components:{Debug:Zv,WidthProvider:ZL,TipsDialog:RL,DiagramTitle:L_,SeqDiagram:p1,Privacy:d_}},Dh={};var Yv=tt(Kv,qv,Wv,!1,Xv,null,null,null);function Xv(n){for(let t in Dh)this[t]=Dh[t]}const Fh=function(){return Yv.exports}(),xw="",mw="",_w="",Lw="",vw="",yw="",Cw="";function Bh(){return{baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}let Yn=Bh();function Qv(n){Yn=n}const Jv=/[&<>"']/,ty=/[&<>"']/g,ey=/[<>"']|&(?!#?\w+;)/,ny=/[<>"']|&(?!#?\w+;)/g,ry={"&":"&","<":"<",">":">",'"':""","'":"'"},Uh=n=>ry[n];function Tt(n,t){if(t){if(Jv.test(n))return n.replace(ty,Uh)}else if(ey.test(n))return n.replace(ny,Uh);return n}const sy=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function Hh(n){return n.replace(sy,(t,e)=>(e=e.toLowerCase(),e==="colon"?":":e.charAt(0)==="#"?e.charAt(1)==="x"?String.fromCharCode(parseInt(e.substring(2),16)):String.fromCharCode(+e.substring(1)):""))}const iy=/(^|[^\[])\^/g;function it(n,t){n=n.source||n,t=t||"";const e={replace:(r,s)=>(s=s.source||s,s=s.replace(iy,"$1"),n=n.replace(r,s),e),getRegex:()=>new RegExp(n,t)};return e}const oy=/[^\w:]/g,ay=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function Gh(n,t,e){if(n){let r;try{r=decodeURIComponent(Hh(e)).replace(oy,"").toLowerCase()}catch{return null}if(r.indexOf("javascript:")===0||r.indexOf("vbscript:")===0||r.indexOf("data:")===0)return null}t&&!ay.test(e)&&(e=hy(t,e));try{e=encodeURI(e).replace(/%25/g,"%")}catch{return null}return e}const bi={},ly=/^[^:]+:\/*[^/]*$/,cy=/^([^:]+:)[\s\S]*$/,uy=/^([^:]+:\/*[^/]*)[\s\S]*$/;function hy(n,t){bi[" "+n]||(ly.test(n)?bi[" "+n]=n+"/":bi[" "+n]=Ti(n,"/",!0)),n=bi[" "+n];const e=n.indexOf(":")===-1;return t.substring(0,2)==="//"?e?t:n.replace(cy,"$1")+t:t.charAt(0)==="/"?e?t:n.replace(uy,"$1")+t:n+t}const wi={exec:function(){}};function pe(n){let t=1,e,r;for(;t<arguments.length;t++){e=arguments[t];for(r in e)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r])}return n}function jh(n,t){const e=n.replace(/\|/g,(i,o,a)=>{let l=!1,c=o;for(;--c>=0&&a[c]==="\\";)l=!l;return l?"|":" |"}),r=e.split(/ \|/);let s=0;if(r[0].trim()||r.shift(),r[r.length-1].trim()||r.pop(),r.length>t)r.splice(t);else for(;r.length<t;)r.push("");for(;s<r.length;s++)r[s]=r[s].trim().replace(/\\\|/g,"|");return r}function Ti(n,t,e){const r=n.length;if(r===0)return"";let s=0;for(;s<r;){const i=n.charAt(r-s-1);if(i===t&&!e)s++;else if(i!==t&&e)s++;else break}return n.substr(0,r-s)}function fy(n,t){if(n.indexOf(t[1])===-1)return-1;const e=n.length;let r=0,s=0;for(;s<e;s++)if(n[s]==="\\")s++;else if(n[s]===t[0])r++;else if(n[s]===t[1]&&(r--,r<0))return s;return-1}function Vh(n){n&&n.sanitize&&!n.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")}function zh(n,t){if(t<1)return"";let e="";for(;t>1;)t&1&&(e+=n),t>>=1,n+=n;return e+n}function Zh(n,t,e,r){const s=t.href,i=t.title?Tt(t.title):null,o=n[1].replace(/\\([\[\]])/g,"$1");if(n[0].charAt(0)!=="!"){r.state.inLink=!0;const a={type:"link",raw:e,href:s,title:i,text:o,tokens:r.inlineTokens(o,[])};return r.state.inLink=!1,a}else return{type:"image",raw:e,href:s,title:i,text:Tt(o)}}function dy(n,t){const e=n.match(/^(\s+)(?:```)/);if(e===null)return t;const r=e[1];return t.split(`
|
|
506
506
|
`).map(s=>{const i=s.match(/^\s+/);if(i===null)return s;const[o]=i;return o.length>=r.length?s.slice(r.length):s}).join(`
|
|
507
507
|
`)}class v1{constructor(t){this.options=t||Yn}space(t){const e=this.rules.block.newline.exec(t);if(e&&e[0].length>0)return{type:"space",raw:e[0]}}code(t){const e=this.rules.block.code.exec(t);if(e){const r=e[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?r:Ti(r,`
|
|
508
508
|
`)}}}fences(t){const e=this.rules.block.fences.exec(t);if(e){const r=e[0],s=dy(r,e[3]||"");return{type:"code",raw:r,lang:e[2]?e[2].trim():e[2],text:s}}}heading(t){const e=this.rules.block.heading.exec(t);if(e){let r=e[2].trim();if(/#$/.test(r)){const i=Ti(r,"#");(this.options.pedantic||!i||/ $/.test(i))&&(r=i.trim())}const s={type:"heading",raw:e[0],depth:e[1].length,text:r,tokens:[]};return this.lexer.inline(s.text,s.tokens),s}}hr(t){const e=this.rules.block.hr.exec(t);if(e)return{type:"hr",raw:e[0]}}blockquote(t){const e=this.rules.block.blockquote.exec(t);if(e){const r=e[0].replace(/^ *> ?/gm,"");return{type:"blockquote",raw:e[0],tokens:this.lexer.blockTokens(r,[]),text:r}}}list(t){let e=this.rules.block.list.exec(t);if(e){let r,s,i,o,a,l,c,u,f,d,p,w,I=e[1].trim();const q=I.length>1,$={type:"list",raw:"",ordered:q,start:q?+I.slice(0,-1):"",loose:!1,items:[]};I=q?`\\d{1,9}\\${I.slice(-1)}`:`\\${I}`,this.options.pedantic&&(I=q?I:"[*+-]");const j=new RegExp(`^( {0,3}${I})((?: [^\\n]*)?(?:\\n|$))`);for(;t&&(w=!1,!(!(e=j.exec(t))||this.rules.block.hr.test(t)));){if(r=e[0],t=t.substring(r.length),u=e[2].split(`
|