deploy: 57bb0fa248
This commit is contained in:
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
let e;const r={},t=function(t,n){if(!n||0===n.length)return t();if(void 0===e){const r=document.createElement("link").relList;e=r&&r.supports&&r.supports("modulepreload")?"modulepreload":"preload"}return Promise.all(n.map((t=>{if((t=`/mermaid-live-editor/_app/${t}`)in r)return;r[t]=!0;const n=t.endsWith(".css"),o=n?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${t}"]${o}`))return;const s=document.createElement("link");return s.rel=n?"stylesheet":e,n||(s.as="script",s.crossOrigin=""),s.href=t,document.head.appendChild(s),n?new Promise(((e,r)=>{s.addEventListener("load",e),s.addEventListener("error",r)})):void 0}))).then((()=>t()))};export{t as _};
|
||||
@@ -0,0 +1 @@
|
||||
let t;function a(a){t=a}export{a as i,t as r};
|
||||
@@ -0,0 +1 @@
|
||||
var e=Object.defineProperty,a=Object.defineProperties,t=Object.getOwnPropertyDescriptors,r=Object.getOwnPropertySymbols,s=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable,i=(a,t,r)=>t in a?e(a,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):a[t]=r,n=(e,a)=>{for(var t in a||(a={}))s.call(a,t)&&i(e,t,a[t]);if(r)for(var t of r(a))o.call(a,t)&&i(e,t,a[t]);return e},c=(e,r)=>a(e,t(r));import{a4 as l,a5 as d,C as p,a6 as u,$ as m,a8 as f,ac as y,S as g,i as h,s as b,e as v,c as O,a as S,d as E,b as w,P as D,f as T,H as L,I as j,J as _,z as x,aa as C,ab as P,L as I}from"./vendor-134b46ff.js";import{_ as J}from"./preload-helper-78524df4.js";let A;let N;const k=l(p({code:"graph TD\n A[Christmas] --\x3e|Get money| B(Go shopping)\n B --\x3e C{Let me think}\n C --\x3e|One| D[Laptop]\n C --\x3e|Two| E[iPhone]\n C --\x3e|Three| F[fa:fa-car Car]\n ",mermaid:JSON.stringify({theme:"default"},null,2),updateEditor:!1,autoSync:!0,updateDiagram:!0}),d(),"codeStore"),V=u([k],(([e],a)=>{a(m(JSON.stringify(e),!0))})),$=e=>{k.update((a=>n(n({},a),e)))};let R=!1;const z=(e,a,t=!1)=>{var r;r=e,A&&(clearTimeout(N),N=setTimeout((function(){const e=r.replace(/^\s*%%.*\n/g,"\n").trimStart().split(" ")[0];console.debug("ga:","send","event","render",e),A.track("render",{graphType:e})}),5e3));if((e.match(/\n/g)||"").length+1>50&&!R&&f(k).autoSync){const e=confirm("Long diagram deteced. Turn off Auto Sync? Click the sync logo to manually sync.");R=!0,e&&$({autoSync:!1})}k.update((r=>c(n({},r),{code:e,updateEditor:a,updateDiagram:t})))},B=(e,a)=>{k.update((t=>c(n({},t),{mermaid:e,updateEditor:a})))},G=()=>JSON.stringify(f(k)),H=p(void 0);function F(e){let a,t;return{c(){a=v("div"),t=v("div"),this.h()},l(e){a=O(e,"DIV",{id:!0,class:!0});var r=S(a);t=O(r,"DIV",{id:!0,class:!0}),S(t).forEach(E),r.forEach(E),this.h()},h(){w(t,"id","container"),w(t,"class","flex-1 overflow-auto"),w(a,"id","view"),w(a,"class","p-2 svelte-5ndy2s"),D(a,"error",e[1]),D(a,"outOfSync",e[2])},m(r,s){T(r,a,s),L(a,t),e[3](t)},p(e,[t]){2&t&&D(a,"error",e[1]),4&t&&D(a,"outOfSync",e[2])},i:j,o:j,d(t){t&&E(a),e[3](null)}}}function M(e,a,t){let r;_(e,k,(e=>t(7,r=e)));let s,o="",i="",n=!1,c=!1,l=!0;return x((()=>{k.subscribe((e=>{try{if(s&&e&&(e.updateDiagram||e.autoSync)){if(e.autoSync||C(k,r.updateDiagram=!1,r),t(2,c=!1),l=!0,o===e.code&&i===e.mermaid)return;o=e.code,i=e.mermaid;const a=s.parentElement.parentElement.parentElement.scrollTop;delete s.dataset.processed,P.exports.initialize(Object.assign({},JSON.parse(e.mermaid))),P.exports.render("graph-div",o,(e=>{t(0,s.innerHTML=e,s)})),t(0,s.parentElement.parentElement.parentElement.scrollTop=a,s),t(1,n=!1)}else l?l=!1:t(2,c=!0)}catch(a){console.log("view fail",a),t(1,n=!0)}})),H.subscribe((e=>{void 0===e?t(1,n=!1):(t(1,n=!0),console.log("Error: ",e))}))})),[s,n,c,function(e){I[e?"unshift":"push"]((()=>{s=e,t(0,s)}))}]}class U extends g{constructor(e){super(),h(this,e,M,F,b,{})}}const q=()=>{(e=>{let a;try{const t=y(e);console.log(`Tring to load state: ${t}`),a=JSON.parse(t);const r="string"==typeof a.mermaid?JSON.parse(a.mermaid):a.mermaid;r.securityLevel&&"strict"!==r.securityLevel&&confirm(`Removing "securityLevel":"${r.securityLevel}" from the config for safety.\nClick Cancel if you trust the source of this Diagram.`)&&delete r.securityLevel,a.mermaid=JSON.stringify(r,null,2)}catch(t){e&&console.error("Init error",t),a=f(k),console.log(a)}$(c(n({},a),{updateEditor:!0}))})(window.location.hash.slice(1))},K=()=>{$({updateDiagram:!0})},Q=async()=>{q(),K(),V.subscribe((e=>{history.replaceState(void 0,void 0,`#${e}`)})),await(async()=>{if(!A)try{const{Analytics:e}=await J((()=>import("./analytics.browser.es-de8d1c22.js")),[]),a=await J((()=>import("./analytics-plugin-ga.browser.es-1cdb0512.js")),[]);A=e({app:"mermaid-live-editor",plugins:[a.init({trackingId:"UA-153180559-1"})]})}catch{console.info("Analytics blocked ;)")}})(),null==A||A.page()};export{U as V,A as a,V as b,k as c,B as d,H as e,G as g,Q as i,K as s,z as u};
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
import{S as r,i as s,s as a,e as t,t as e,c as n,a as o,g as c,d as u,f,H as l,h as p,k as m,l as d,n as i,I as h}from"./chunks/vendor-134b46ff.js";function E(r){let s,a,m=r[1].frame+"";return{c(){s=t("pre"),a=e(m)},l(r){s=n(r,"PRE",{});var t=o(s);a=c(t,m),t.forEach(u)},m(r,t){f(r,s,t),l(s,a)},p(r,s){2&s&&m!==(m=r[1].frame+"")&&p(a,m)},d(r){r&&u(s)}}}function k(r){let s,a,m=r[1].stack+"";return{c(){s=t("pre"),a=e(m)},l(r){s=n(r,"PRE",{});var t=o(s);a=c(t,m),t.forEach(u)},m(r,t){f(r,s,t),l(s,a)},p(r,s){2&s&&m!==(m=r[1].stack+"")&&p(a,m)},d(r){r&&u(s)}}}function v(r){let s,a,v,g,x,P,R,H,N=r[1].message+"",$=r[1].frame&&E(r),b=r[1].stack&&k(r);return{c(){s=t("h1"),a=e(r[0]),v=m(),g=t("pre"),x=e(N),P=m(),$&&$.c(),R=m(),b&&b.c(),H=d()},l(t){s=n(t,"H1",{});var e=o(s);a=c(e,r[0]),e.forEach(u),v=i(t),g=n(t,"PRE",{});var f=o(g);x=c(f,N),f.forEach(u),P=i(t),$&&$.l(t),R=i(t),b&&b.l(t),H=d()},m(r,t){f(r,s,t),l(s,a),f(r,v,t),f(r,g,t),l(g,x),f(r,P,t),$&&$.m(r,t),f(r,R,t),b&&b.m(r,t),f(r,H,t)},p(r,[s]){1&s&&p(a,r[0]),2&s&&N!==(N=r[1].message+"")&&p(x,N),r[1].frame?$?$.p(r,s):($=E(r),$.c(),$.m(R.parentNode,R)):$&&($.d(1),$=null),r[1].stack?b?b.p(r,s):(b=k(r),b.c(),b.m(H.parentNode,H)):b&&(b.d(1),b=null)},i:h,o:h,d(r){r&&u(s),r&&u(v),r&&u(g),r&&u(P),$&&$.d(r),r&&u(R),b&&b.d(r),r&&u(H)}}}function g({error:r,status:s}){return{props:{error:r,status:s}}}function x(r,s,a){let{status:t}=s,{error:e}=s;return r.$$set=r=>{"status"in r&&a(0,t=r.status),"error"in r&&a(1,e=r.error)},[t,e]}export default class extends r{constructor(r){super(),s(this,r,x,v,a,{status:0,error:1})}}export{g as load};
|
||||
@@ -0,0 +1 @@
|
||||
import{S as s,i as e,s as r,D as o,e as a,c,a as t,d as n,b as i,f as l,E as u,F as f,G as h,v as p,r as $,z as d}from"../chunks/vendor-134b46ff.js";import{b as v}from"../chunks/paths-45dac81d.js";function g(s){let e,r;const d=s[1].default,v=o(d,s,s[0],null);return{c(){e=a("main"),v&&v.c(),this.h()},l(s){e=c(s,"MAIN",{class:!0});var r=t(e);v&&v.l(r),r.forEach(n),this.h()},h(){i(e,"class","h-screen")},m(s,o){l(s,e,o),v&&v.m(e,null),r=!0},p(s,[e]){v&&v.p&&(!r||1&e)&&u(v,d,s,s[0],r?h(d,s[0],e,null):f(s[0]),null)},i(s){r||(p(v,s),r=!0)},o(s){$(v,s),r=!1},d(s){s&&n(e),v&&v.d(s)}}}function m(s,e,r){let{$$slots:o={},$$scope:a}=e;return d((()=>{"serviceWorker"in navigator&&navigator.serviceWorker.register(`${v}/service-worker.js`,{scope:`${v}/`}).then((function(s){console.log("Registration successful, scope is:",s.scope)})).catch((function(s){console.log("Service worker registration failed, error:",s)}))})),s.$$set=s=>{"$$scope"in s&&r(0,a=s.$$scope)},[a,o]}export default class extends s{constructor(s){super(),e(this,s,m,g,r,{})}}
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
import{S as t,i as n,s as o,z as s}from"../chunks/vendor-134b46ff.js";import{r as e}from"../chunks/singletons-12a22614.js";import{b as i}from"../chunks/paths-45dac81d.js";const a=async function(t,n){return e.goto(t,n,[])};function c(t){var n=this&&this.__awaiter||function(t,n,o,s){return new(o||(o=Promise))((function(e,i){function a(t){try{r(s.next(t))}catch(n){i(n)}}function c(t){try{r(s.throw(t))}catch(n){i(n)}}function r(t){var n;t.done?e(t.value):(n=t.value,n instanceof o?n:new o((function(t){t(n)}))).then(a,c)}r((s=s.apply(t,n||[])).next())}))};return s((()=>n(void 0,void 0,void 0,(function*(){const t=window.location.hash.split("/");let n="edit";t.length>2&&(n=`${t[1]}#${t[2]}`),yield a(`${i}/${n}`,{replaceState:!0})})))),[]}export default class extends t{constructor(t){super(),n(this,t,c,null,o,{})}}
|
||||
@@ -0,0 +1 @@
|
||||
import{S as s,i as r,s as a,j as t,m as e,o as n,I as o,v as f,r as c,w as m,z as u}from"../chunks/vendor-134b46ff.js";import{V as i,i as p}from"../chunks/util-5805f6cc.js";import"../chunks/preload-helper-78524df4.js";function $(s){let r,a;return r=new i({}),{c(){t(r.$$.fragment)},l(s){e(r.$$.fragment,s)},m(s,t){n(r,s,t),a=!0},p:o,i(s){a||(f(r.$$.fragment,s),a=!0)},o(s){c(r.$$.fragment,s),a=!1},d(s){m(r,s)}}}function l(s){return u(p),[]}export default class extends s{constructor(s){super(),r(this,s,l,$,a,{})}}
|
||||
File diff suppressed because one or more lines are too long
+5
-10
@@ -19,11 +19,6 @@
|
||||
rel="stylesheet"
|
||||
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.2/css/all.min.css"
|
||||
/>
|
||||
<script
|
||||
src="https://cdn.jsdelivr.net/npm/mermaid@8.11.0/dist/mermaid.min.js"
|
||||
integrity="sha256-sVAx+v/Q7v0Q2xm5vN7h5ccSna6gaLREhG9sF8pKT6I="
|
||||
crossorigin="anonymous"
|
||||
></script>
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="https://cdnjs.cloudflare.com/ajax/libs/monaco-editor/0.25.2/min/vs/editor/editor.main.min.css"
|
||||
@@ -55,15 +50,15 @@
|
||||
|
||||
|
||||
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/start-f7808a56.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/vendor-9af57fc6.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/preload-helper-9f12a5fd.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/singletons-bb9012b7.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/start-83e63352.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/vendor-134b46ff.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/preload-helper-78524df4.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/singletons-12a22614.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/paths-45dac81d.js">
|
||||
<link rel="stylesheet" href="/mermaid-live-editor/_app/assets/start-0826e215.css">
|
||||
|
||||
<script type="module">
|
||||
import { start } from "/mermaid-live-editor/_app/start-f7808a56.js";
|
||||
import { start } from "/mermaid-live-editor/_app/start-83e63352.js";
|
||||
start({
|
||||
target: document.querySelector("#svelte"),
|
||||
paths: {"base":"/mermaid-live-editor","assets":"/mermaid-live-editor"},
|
||||
|
||||
+5
-10
@@ -19,11 +19,6 @@
|
||||
rel="stylesheet"
|
||||
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.2/css/all.min.css"
|
||||
/>
|
||||
<script
|
||||
src="https://cdn.jsdelivr.net/npm/mermaid@8.11.0/dist/mermaid.min.js"
|
||||
integrity="sha256-sVAx+v/Q7v0Q2xm5vN7h5ccSna6gaLREhG9sF8pKT6I="
|
||||
crossorigin="anonymous"
|
||||
></script>
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="https://cdnjs.cloudflare.com/ajax/libs/monaco-editor/0.25.2/min/vs/editor/editor.main.min.css"
|
||||
@@ -55,15 +50,15 @@
|
||||
|
||||
|
||||
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/start-f7808a56.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/vendor-9af57fc6.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/preload-helper-9f12a5fd.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/singletons-bb9012b7.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/start-83e63352.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/vendor-134b46ff.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/preload-helper-78524df4.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/singletons-12a22614.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/paths-45dac81d.js">
|
||||
<link rel="stylesheet" href="/mermaid-live-editor/_app/assets/start-0826e215.css">
|
||||
|
||||
<script type="module">
|
||||
import { start } from "/mermaid-live-editor/_app/start-f7808a56.js";
|
||||
import { start } from "/mermaid-live-editor/_app/start-83e63352.js";
|
||||
start({
|
||||
target: document.querySelector("#svelte"),
|
||||
paths: {"base":"/mermaid-live-editor","assets":"/mermaid-live-editor"},
|
||||
|
||||
+5
-10
@@ -19,11 +19,6 @@
|
||||
rel="stylesheet"
|
||||
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.2/css/all.min.css"
|
||||
/>
|
||||
<script
|
||||
src="https://cdn.jsdelivr.net/npm/mermaid@8.11.0/dist/mermaid.min.js"
|
||||
integrity="sha256-sVAx+v/Q7v0Q2xm5vN7h5ccSna6gaLREhG9sF8pKT6I="
|
||||
crossorigin="anonymous"
|
||||
></script>
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="https://cdnjs.cloudflare.com/ajax/libs/monaco-editor/0.25.2/min/vs/editor/editor.main.min.css"
|
||||
@@ -55,15 +50,15 @@
|
||||
|
||||
|
||||
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/start-f7808a56.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/vendor-9af57fc6.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/preload-helper-9f12a5fd.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/singletons-bb9012b7.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/start-83e63352.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/vendor-134b46ff.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/preload-helper-78524df4.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/singletons-12a22614.js">
|
||||
<link rel="modulepreload" href="/mermaid-live-editor/_app/chunks/paths-45dac81d.js">
|
||||
<link rel="stylesheet" href="/mermaid-live-editor/_app/assets/start-0826e215.css">
|
||||
|
||||
<script type="module">
|
||||
import { start } from "/mermaid-live-editor/_app/start-f7808a56.js";
|
||||
import { start } from "/mermaid-live-editor/_app/start-83e63352.js";
|
||||
start({
|
||||
target: document.querySelector("#svelte"),
|
||||
paths: {"base":"/mermaid-live-editor","assets":"/mermaid-live-editor"},
|
||||
|
||||
Reference in New Issue
Block a user