apprun 3.33.9 → 3.35.0

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.
Files changed (71) hide show
  1. package/.clinerules +1 -0
  2. package/LICENSE +1 -1
  3. package/README.md +1 -1
  4. package/WHATSNEW.md +106 -0
  5. package/apprun.d.ts +7 -1
  6. package/dist/apprun-dev-tools.js +1 -1
  7. package/dist/apprun-dev-tools.js.map +1 -1
  8. package/dist/apprun-html.esm.js +21 -4
  9. package/dist/apprun-html.esm.js.map +1 -1
  10. package/dist/apprun-html.js +1 -1
  11. package/dist/apprun-html.js.LICENSE.txt +6 -0
  12. package/dist/apprun-html.js.map +1 -1
  13. package/dist/apprun-play-html.esm.js +21 -4
  14. package/dist/apprun-play-html.esm.js.map +1 -1
  15. package/dist/apprun-play.js +1 -1
  16. package/dist/apprun-play.js.map +1 -1
  17. package/dist/apprun.esm.js +1 -1
  18. package/dist/apprun.esm.js.map +1 -1
  19. package/dist/apprun.js +1 -1
  20. package/dist/apprun.js.map +1 -1
  21. package/esm/app.js +38 -10
  22. package/esm/app.js.map +1 -1
  23. package/esm/apprun-code.js.map +1 -1
  24. package/esm/apprun-dev-tools-tests.js.map +1 -1
  25. package/esm/apprun-dev-tools.js.map +1 -1
  26. package/esm/apprun-html.js.map +1 -1
  27. package/esm/apprun-play.js.map +1 -1
  28. package/esm/apprun.js +65 -9
  29. package/esm/apprun.js.map +1 -1
  30. package/esm/component.js +59 -1
  31. package/esm/component.js.map +1 -1
  32. package/esm/decorator.js +33 -0
  33. package/esm/decorator.js.map +1 -1
  34. package/esm/directive.js +31 -0
  35. package/esm/directive.js.map +1 -1
  36. package/esm/router.js +27 -0
  37. package/esm/router.js.map +1 -1
  38. package/esm/types.js +28 -0
  39. package/esm/types.js.map +1 -1
  40. package/esm/vdom-lit-html.js +19 -17
  41. package/esm/vdom-lit-html.js.map +1 -1
  42. package/esm/vdom-my.js.map +1 -1
  43. package/esm/vdom-patch.js.map +1 -1
  44. package/esm/vdom-to-html.js.map +1 -1
  45. package/esm/vdom.js +24 -0
  46. package/esm/vdom.js.map +1 -1
  47. package/esm/web-component.js +32 -0
  48. package/esm/web-component.js.map +1 -1
  49. package/index.html +3 -2
  50. package/jest.config.js +63 -0
  51. package/jest.setup.js +47 -0
  52. package/jsx-runtime.js +1 -1
  53. package/jsx-runtime.js.map +1 -1
  54. package/package.json +16 -43
  55. package/react.js +0 -15
  56. package/rollup.config.js +27 -10
  57. package/src/app.ts +64 -30
  58. package/src/apprun.ts +94 -13
  59. package/src/component.ts +57 -1
  60. package/src/decorator.ts +34 -1
  61. package/src/directive.ts +33 -1
  62. package/src/global.d.ts +22 -0
  63. package/src/router.ts +28 -2
  64. package/src/types/apprun.d.ts +56 -0
  65. package/src/types.ts +30 -1
  66. package/src/vdom-lit-html.ts +21 -19
  67. package/src/vdom.ts +25 -2
  68. package/src/web-component.ts +33 -0
  69. package/tsconfig.jest.json +27 -3
  70. package/tsconfig.json +3 -3
  71. package/webpack.config.cjs +9 -2
package/.clinerules ADDED
@@ -0,0 +1 @@
1
+ Update or create the file’s top comment block to briefly describe the file’s purpose, structure, and usage, matching its original style. Focus on clarity and maintainability for YOU to understand in the future.
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  The MIT License (MIT)
2
2
 
3
- Copyright (c) 2022 Yiyi Sun
3
+ Copyright (c) 2015-2025 Yiyi Sun
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
package/README.md CHANGED
@@ -142,7 +142,7 @@ AppRun is an MIT-licensed open-source project. Please consider [supporting the p
142
142
 
143
143
  MIT
144
144
 
145
- Copyright (c) 2015-2024 Yiyi Sun
145
+ Copyright (c) 2015-2025 Yiyi Sun
146
146
 
147
147
 
148
148
  [travis-image]: https://travis-ci.org/yysun/apprun.svg?branch=master
package/WHATSNEW.md CHANGED
@@ -1,5 +1,111 @@
1
1
  ## What's New
2
2
 
3
+ > July 12, 2025, V3.35.0
4
+
5
+ ### Support auto use router for pretty links
6
+
7
+ AppRun now supports pretty links.
8
+
9
+ ```html
10
+ <a href="/about">About</a>
11
+ ```
12
+
13
+ You can subscribe components to events like `'/about'`.
14
+
15
+ ```js
16
+ // Routing (component event)
17
+ class Home extends Component {
18
+ view = () => <div>Home</div>;
19
+ update = {'/, /home': state => state };
20
+ }
21
+
22
+ class Contact extends Component {
23
+ view = () => <div>Contact</div>;
24
+ update = {'/contact': state => state };
25
+ }
26
+
27
+ class About extends Component {
28
+ view = () => <div>About</div>;
29
+ update = {'/about': state => state };
30
+ }
31
+
32
+ const App = () => <>
33
+ <div id="menus">
34
+ <a href="/home">Home</a>{' | '}
35
+ <a href="/contact">Contact</a>{' | '}
36
+ <a href="/about">About</a></div>
37
+ <div id="pages"></div>
38
+ </>
39
+
40
+ app.render(document.body, <App />);
41
+ [About, Contact, Home].map(C => new C().start('pages'));
42
+ ```
43
+ <apprun-code></apprun-code>
44
+
45
+
46
+
47
+ AppRun will catch the `'/about'` route as event and render the component that is subscribed to it.
48
+
49
+ If you have components subscribe to '#', or '#/', Apprun will fallback to the hash-based routing.
50
+
51
+ > July 6, 2025, V3.33.10
52
+
53
+ ### Support async generator for event handlers
54
+
55
+ You can now use async generator functions for event handlers. The async generator function can return multiple values. AppRun will render each value in the order they are generated.
56
+
57
+ ```js
58
+ const state = {};
59
+ const view = state => html`
60
+ <div><button @click=${run(getComic)}>fetch ...</button></div>
61
+ ${state.loading && html`<div>loading ... </div>`}
62
+ ${state.comic && html`<img src=${state.comic.img} />`}
63
+ `;
64
+ async function* getComic() { // async generator function returns loading flag and then the comic object
65
+ yield { loading: true };
66
+ const response = await fetch('https://my-xkcd-api.glitch.me');
67
+ const comic = await response.json();
68
+ yield { comic };
69
+ }
70
+
71
+ app.start(document.body, state, view);
72
+ ```
73
+ <apprun-code></apprun-code>
74
+
75
+
76
+ ### use lit-html V3 for apprun-html.js
77
+
78
+ The `apprun-html.js` now uses `lit-html` V3 for rendering the view. The `apprun-html.js` is a standalone version of AppRun that uses `lit-html` for rendering the view without JSX.
79
+
80
+ ```html
81
+ <html lang="en">
82
+ <head>
83
+ <meta charset="utf-8">
84
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
85
+ <title>Counter</title>
86
+ </head>
87
+ <body>
88
+ <script src="https://unpkg.com/dist/apprun-html"></script>
89
+ <script>
90
+ const add = (state, delta) => state + delta;
91
+ const view = state => {
92
+ return html`<div>
93
+ <h1>${state}</h1>
94
+ <button @click=${run(add, -1)}>-1</button>
95
+ <button @click=${run(add, +1)}>+1</button>
96
+ </div>`;
97
+ };
98
+ app.start(document.body, 0, view);
99
+ </script>
100
+ </body>
101
+
102
+ </html>
103
+ ```
104
+ <apprun-code></apprun-code>
105
+
106
+
107
+
108
+
3
109
  > Aug 12, 2024, V3.33.4
4
110
 
5
111
  ### Add app.use_render and app.use_react function
package/apprun.d.ts CHANGED
@@ -59,6 +59,7 @@ declare module 'apprun' {
59
59
  safeHTML(html: string): any[];
60
60
  use_render(render, mode?: 0 | 1);
61
61
  use_react(React, ReactDOM);
62
+ version: string;
62
63
  }
63
64
 
64
65
  export class Component<T = any, E = any> {
@@ -92,11 +93,16 @@ declare module 'apprun' {
92
93
  export const ROUTER_EVENT: string;
93
94
  export const ROUTER_404_EVENT: string;
94
95
  export const safeHTML;
95
- export function Fragment (props, ...children): [];
96
+ export function Fragment(props, ...children): [];
96
97
  }
97
98
 
98
99
  declare namespace JSX {
99
100
  interface IntrinsicElements {
100
101
  [elemName: string]: any;
101
102
  }
103
+ }
104
+
105
+ declare module 'apprun/react' {
106
+ import { Component } from 'apprun';
107
+ export default function toReact(componentClass: Component): Function;
102
108
  }
@@ -1,3 +1,3 @@
1
1
  /*! For license information please see apprun-dev-tools.js.LICENSE.txt */
2
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.apprun=t():e.apprun=t()}(this,(()=>(()=>{"use strict";var e={859:(e,t,n)=>{n.d(t,{A:()=>r});let i;const o="object"==typeof self&&self.self===self&&self||"object"==typeof n.g&&n.g.global===n.g&&n.g;o.app&&o._AppRunVersions?i=o.app:(i=new class{constructor(){this._events={}}on(e,t,n={}){this._events[e]=this._events[e]||[],this._events[e].push({fn:t,options:n})}off(e,t){const n=this._events[e]||[];this._events[e]=n.filter((e=>e.fn!==t))}find(e){return this._events[e]}run(e,...t){const n=this.getSubscribers(e,this._events);return console.assert(n&&n.length>0,"No subscriber for event: "+e),n.forEach((n=>{const{fn:i,options:o}=n;return o.delay?this.delay(e,i,t,o):Object.keys(o).length>0?i.apply(this,[...t,o]):i.apply(this,t),!n.options.once})),n.length}once(e,t,n={}){this.on(e,t,Object.assign(Object.assign({},n),{once:!0}))}delay(e,t,n,i){i._t&&clearTimeout(i._t),i._t=setTimeout((()=>{clearTimeout(i._t),Object.keys(i).length>0?t.apply(this,[...n,i]):t.apply(this,n)}),i.delay)}runAsync(e,...t){const n=this.getSubscribers(e,this._events);console.assert(n&&n.length>0,"No subscriber for event: "+e);const i=n.map((e=>{const{fn:n,options:i}=e;return Object.keys(i).length>0?n.apply(this,[...t,i]):n.apply(this,t)}));return Promise.all(i)}query(e,...t){return this.runAsync(e,...t)}getSubscribers(e,t){const n=t[e]||[];return t[e]=n.filter((e=>!e.options.once)),Object.keys(t).filter((t=>t.endsWith("*")&&e.startsWith(t.replace("*","")))).sort(((e,t)=>t.length-e.length)).forEach((i=>n.push(...t[i].map((t=>Object.assign(Object.assign({},t),{options:Object.assign(Object.assign({},t.options),{event:e})})))))),n}},o.app=i,o._AppRunVersions="AppRun-3");const r=i}},t={};function n(i){var o=t[i];if(void 0!==o)return o.exports;var r=t[i]={exports:{}};return e[i](r,r.exports,n),r.exports}n.d=(e,t)=>{for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var i=n(859);function o(e){return e.map((e=>a(e))).join("")}function r(e){for(var t in e)null==e[t]?delete e[t]:"object"==typeof e[t]&&r(e[t])}function a(e){if(!e)return"";if(e._$litType$)return e.toString();if(r(e),Array.isArray(e))return o(e);if("string"==typeof e)return e.startsWith("_html:")?e.substring(6):e;if(e.tag){const t=e.props?function(e){return Object.keys(e).map((t=>{return` ${"className"===t?"class":t}="${n=e[t],"object"==typeof n?Object.keys(n).map((e=>`${e}:${n[e]}`)).join(";"):n.toString()}"`;var n})).join("")}(e.props):"",n=e.children?o(e.children):"";return`<${e.tag}${t}>${n}</${e.tag}>`}return"object"==typeof e?JSON.stringify(e):void 0}const l=a;let s;function c(e){s=window.open("",e),s.document.write(`<html>\n <title>AppRun Analyzer | ${document.location.href}</title>\n <style>\n body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI" }\n </style>\n <body><pre>`)}function u(e){s.document.write(e+"\n")}function p(){s.document.write("</pre>\n </body>\n </html>"),s.document.close()}app.debug=!0;const f=e=>{u(`import ${e.constructor.name} from '../src/${e.constructor.name}'`),u(`describe('${e.constructor.name}', ()=>{`),e._actions.forEach((t=>{"."!==t.name&&(u(` it ('should handle event: ${t.name}', (done)=>{`),u(` const component = new ${e.constructor.name}().mount();`),u(` component.run('${t.name}');`),u(" setTimeout(() => {"),u(" //expect(?).toHaveBeenCalled();"),u(" //expect(component.state).toBe(?);"),u(" done();"),u(" })"))})),u("});")};let d=!1,h=[];app.on("debug",(e=>{d&&e.vdom&&(h.push(e),console.log(`* ${h.length} state(s) recorded.`))}));function g(e){return null==e}var m={isNothing:g,isObject:function(e){return"object"==typeof e&&null!==e},toArray:function(e){return Array.isArray(e)?e:g(e)?[]:[e]},repeat:function(e,t){var n,i="";for(n=0;n<t;n+=1)i+=e;return i},isNegativeZero:function(e){return 0===e&&Number.NEGATIVE_INFINITY===1/e},extend:function(e,t){var n,i,o,r;if(t)for(n=0,i=(r=Object.keys(t)).length;n<i;n+=1)e[o=r[n]]=t[o];return e}};function y(e,t){var n="",i=e.reason||"(unknown reason)";return e.mark?(e.mark.name&&(n+='in "'+e.mark.name+'" '),n+="("+(e.mark.line+1)+":"+(e.mark.column+1)+")",!t&&e.mark.snippet&&(n+="\n\n"+e.mark.snippet),i+" "+n):i}function b(e,t){Error.call(this),this.name="YAMLException",this.reason=e,this.mark=t,this.message=y(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack||""}b.prototype=Object.create(Error.prototype),b.prototype.constructor=b,b.prototype.toString=function(e){return this.name+": "+y(this,e)};var v=b;function A(e,t,n,i,o){var r="",a="",l=Math.floor(o/2)-1;return i-t>l&&(t=i-l+(r=" ... ").length),n-i>l&&(n=i+l-(a=" ...").length),{str:r+e.slice(t,n).replace(/\t/g,"→")+a,pos:i-t+r.length}}function w(e,t){return m.repeat(" ",t-e.length)+e}var k=function(e,t){if(t=Object.create(t||null),!e.buffer)return null;t.maxLength||(t.maxLength=79),"number"!=typeof t.indent&&(t.indent=1),"number"!=typeof t.linesBefore&&(t.linesBefore=3),"number"!=typeof t.linesAfter&&(t.linesAfter=2);for(var n,i=/\r?\n|\r|\0/g,o=[0],r=[],a=-1;n=i.exec(e.buffer);)r.push(n.index),o.push(n.index+n[0].length),e.position<=n.index&&a<0&&(a=o.length-2);a<0&&(a=o.length-1);var l,s,c="",u=Math.min(e.line+t.linesAfter,r.length).toString().length,p=t.maxLength-(t.indent+u+3);for(l=1;l<=t.linesBefore&&!(a-l<0);l++)s=A(e.buffer,o[a-l],r[a-l],e.position-(o[a]-o[a-l]),p),c=m.repeat(" ",t.indent)+w((e.line-l+1).toString(),u)+" | "+s.str+"\n"+c;for(s=A(e.buffer,o[a],r[a],e.position,p),c+=m.repeat(" ",t.indent)+w((e.line+1).toString(),u)+" | "+s.str+"\n",c+=m.repeat("-",t.indent+u+3+s.pos)+"^\n",l=1;l<=t.linesAfter&&!(a+l>=r.length);l++)s=A(e.buffer,o[a+l],r[a+l],e.position-(o[a]-o[a+l]),p),c+=m.repeat(" ",t.indent)+w((e.line+l+1).toString(),u)+" | "+s.str+"\n";return c.replace(/\n$/,"")},x=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],C=["scalar","sequence","mapping"],O=function(e,t){if(t=t||{},Object.keys(t).forEach((function(t){if(-1===x.indexOf(t))throw new v('Unknown option "'+t+'" is met in definition of "'+e+'" YAML type.')})),this.options=t,this.tag=e,this.kind=t.kind||null,this.resolve=t.resolve||function(){return!0},this.construct=t.construct||function(e){return e},this.instanceOf=t.instanceOf||null,this.predicate=t.predicate||null,this.represent=t.represent||null,this.representName=t.representName||null,this.defaultStyle=t.defaultStyle||null,this.multi=t.multi||!1,this.styleAliases=function(e){var t={};return null!==e&&Object.keys(e).forEach((function(n){e[n].forEach((function(e){t[String(e)]=n}))})),t}(t.styleAliases||null),-1===C.indexOf(this.kind))throw new v('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')};function j(e,t){var n=[];return e[t].forEach((function(e){var t=n.length;n.forEach((function(n,i){n.tag===e.tag&&n.kind===e.kind&&n.multi===e.multi&&(t=i)})),n[t]=e})),n}function S(e){return this.extend(e)}S.prototype.extend=function(e){var t=[],n=[];if(e instanceof O)n.push(e);else if(Array.isArray(e))n=n.concat(e);else{if(!e||!Array.isArray(e.implicit)&&!Array.isArray(e.explicit))throw new v("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");e.implicit&&(t=t.concat(e.implicit)),e.explicit&&(n=n.concat(e.explicit))}t.forEach((function(e){if(!(e instanceof O))throw new v("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(e.loadKind&&"scalar"!==e.loadKind)throw new v("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(e.multi)throw new v("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")})),n.forEach((function(e){if(!(e instanceof O))throw new v("Specified list of YAML types (or a single Type object) contains a non-Type object.")}));var i=Object.create(S.prototype);return i.implicit=(this.implicit||[]).concat(t),i.explicit=(this.explicit||[]).concat(n),i.compiledImplicit=j(i,"implicit"),i.compiledExplicit=j(i,"explicit"),i.compiledTypeMap=function(){var e,t,n={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function i(e){e.multi?(n.multi[e.kind].push(e),n.multi.fallback.push(e)):n[e.kind][e.tag]=n.fallback[e.tag]=e}for(e=0,t=arguments.length;e<t;e+=1)arguments[e].forEach(i);return n}(i.compiledImplicit,i.compiledExplicit),i};var I=S,_=new O("tag:yaml.org,2002:str",{kind:"scalar",construct:function(e){return null!==e?e:""}}),T=new O("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(e){return null!==e?e:[]}}),E=new O("tag:yaml.org,2002:map",{kind:"mapping",construct:function(e){return null!==e?e:{}}}),N=new I({explicit:[_,T,E]}),L=new O("tag:yaml.org,2002:null",{kind:"scalar",resolve:function(e){if(null===e)return!0;var t=e.length;return 1===t&&"~"===e||4===t&&("null"===e||"Null"===e||"NULL"===e)},construct:function(){return null},predicate:function(e){return null===e},represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"}),F=new O("tag:yaml.org,2002:bool",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t=e.length;return 4===t&&("true"===e||"True"===e||"TRUE"===e)||5===t&&("false"===e||"False"===e||"FALSE"===e)},construct:function(e){return"true"===e||"True"===e||"TRUE"===e},predicate:function(e){return"[object Boolean]"===Object.prototype.toString.call(e)},represent:{lowercase:function(e){return e?"true":"false"},uppercase:function(e){return e?"TRUE":"FALSE"},camelcase:function(e){return e?"True":"False"}},defaultStyle:"lowercase"});function M(e){return 48<=e&&e<=55}function $(e){return 48<=e&&e<=57}var D=new O("tag:yaml.org,2002:int",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t,n,i=e.length,o=0,r=!1;if(!i)return!1;if("-"!==(t=e[o])&&"+"!==t||(t=e[++o]),"0"===t){if(o+1===i)return!0;if("b"===(t=e[++o])){for(o++;o<i;o++)if("_"!==(t=e[o])){if("0"!==t&&"1"!==t)return!1;r=!0}return r&&"_"!==t}if("x"===t){for(o++;o<i;o++)if("_"!==(t=e[o])){if(!(48<=(n=e.charCodeAt(o))&&n<=57||65<=n&&n<=70||97<=n&&n<=102))return!1;r=!0}return r&&"_"!==t}if("o"===t){for(o++;o<i;o++)if("_"!==(t=e[o])){if(!M(e.charCodeAt(o)))return!1;r=!0}return r&&"_"!==t}}if("_"===t)return!1;for(;o<i;o++)if("_"!==(t=e[o])){if(!$(e.charCodeAt(o)))return!1;r=!0}return!(!r||"_"===t)},construct:function(e){var t,n=e,i=1;if(-1!==n.indexOf("_")&&(n=n.replace(/_/g,"")),"-"!==(t=n[0])&&"+"!==t||("-"===t&&(i=-1),t=(n=n.slice(1))[0]),"0"===n)return 0;if("0"===t){if("b"===n[1])return i*parseInt(n.slice(2),2);if("x"===n[1])return i*parseInt(n.slice(2),16);if("o"===n[1])return i*parseInt(n.slice(2),8)}return i*parseInt(n,10)},predicate:function(e){return"[object Number]"===Object.prototype.toString.call(e)&&e%1==0&&!m.isNegativeZero(e)},represent:{binary:function(e){return e>=0?"0b"+e.toString(2):"-0b"+e.toString(2).slice(1)},octal:function(e){return e>=0?"0o"+e.toString(8):"-0o"+e.toString(8).slice(1)},decimal:function(e){return e.toString(10)},hexadecimal:function(e){return e>=0?"0x"+e.toString(16).toUpperCase():"-0x"+e.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),R=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"),U=/^[-+]?[0-9]+e/,q=new O("tag:yaml.org,2002:float",{kind:"scalar",resolve:function(e){return null!==e&&!(!R.test(e)||"_"===e[e.length-1])},construct:function(e){var t,n;return n="-"===(t=e.replace(/_/g,"").toLowerCase())[0]?-1:1,"+-".indexOf(t[0])>=0&&(t=t.slice(1)),".inf"===t?1===n?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:".nan"===t?NaN:n*parseFloat(t,10)},predicate:function(e){return"[object Number]"===Object.prototype.toString.call(e)&&(e%1!=0||m.isNegativeZero(e))},represent:function(e,t){var n;if(isNaN(e))switch(t){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(t){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(t){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(m.isNegativeZero(e))return"-0.0";return n=e.toString(10),U.test(n)?n.replace("e",".e"):n},defaultStyle:"lowercase"}),Y=N.extend({implicit:[L,F,D,q]}),B=Y,P=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),V=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$"),W=new O("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:function(e){return null!==e&&(null!==P.exec(e)||null!==V.exec(e))},construct:function(e){var t,n,i,o,r,a,l,s,c=0,u=null;if(null===(t=P.exec(e))&&(t=V.exec(e)),null===t)throw new Error("Date resolve error");if(n=+t[1],i=+t[2]-1,o=+t[3],!t[4])return new Date(Date.UTC(n,i,o));if(r=+t[4],a=+t[5],l=+t[6],t[7]){for(c=t[7].slice(0,3);c.length<3;)c+="0";c=+c}return t[9]&&(u=6e4*(60*+t[10]+ +(t[11]||0)),"-"===t[9]&&(u=-u)),s=new Date(Date.UTC(n,i,o,r,a,l,c)),u&&s.setTime(s.getTime()-u),s},instanceOf:Date,represent:function(e){return e.toISOString()}}),G=new O("tag:yaml.org,2002:merge",{kind:"scalar",resolve:function(e){return"<<"===e||null===e}}),K="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r",H=new O("tag:yaml.org,2002:binary",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t,n,i=0,o=e.length,r=K;for(n=0;n<o;n++)if(!((t=r.indexOf(e.charAt(n)))>64)){if(t<0)return!1;i+=6}return i%8==0},construct:function(e){var t,n,i=e.replace(/[\r\n=]/g,""),o=i.length,r=K,a=0,l=[];for(t=0;t<o;t++)t%4==0&&t&&(l.push(a>>16&255),l.push(a>>8&255),l.push(255&a)),a=a<<6|r.indexOf(i.charAt(t));return 0==(n=o%4*6)?(l.push(a>>16&255),l.push(a>>8&255),l.push(255&a)):18===n?(l.push(a>>10&255),l.push(a>>2&255)):12===n&&l.push(a>>4&255),new Uint8Array(l)},predicate:function(e){return"[object Uint8Array]"===Object.prototype.toString.call(e)},represent:function(e){var t,n,i="",o=0,r=e.length,a=K;for(t=0;t<r;t++)t%3==0&&t&&(i+=a[o>>18&63],i+=a[o>>12&63],i+=a[o>>6&63],i+=a[63&o]),o=(o<<8)+e[t];return 0==(n=r%3)?(i+=a[o>>18&63],i+=a[o>>12&63],i+=a[o>>6&63],i+=a[63&o]):2===n?(i+=a[o>>10&63],i+=a[o>>4&63],i+=a[o<<2&63],i+=a[64]):1===n&&(i+=a[o>>2&63],i+=a[o<<4&63],i+=a[64],i+=a[64]),i}}),J=Object.prototype.hasOwnProperty,Z=Object.prototype.toString,z=new O("tag:yaml.org,2002:omap",{kind:"sequence",resolve:function(e){if(null===e)return!0;var t,n,i,o,r,a=[],l=e;for(t=0,n=l.length;t<n;t+=1){if(i=l[t],r=!1,"[object Object]"!==Z.call(i))return!1;for(o in i)if(J.call(i,o)){if(r)return!1;r=!0}if(!r)return!1;if(-1!==a.indexOf(o))return!1;a.push(o)}return!0},construct:function(e){return null!==e?e:[]}}),X=Object.prototype.toString,Q=new O("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:function(e){if(null===e)return!0;var t,n,i,o,r,a=e;for(r=new Array(a.length),t=0,n=a.length;t<n;t+=1){if(i=a[t],"[object Object]"!==X.call(i))return!1;if(1!==(o=Object.keys(i)).length)return!1;r[t]=[o[0],i[o[0]]]}return!0},construct:function(e){if(null===e)return[];var t,n,i,o,r,a=e;for(r=new Array(a.length),t=0,n=a.length;t<n;t+=1)i=a[t],o=Object.keys(i),r[t]=[o[0],i[o[0]]];return r}}),ee=Object.prototype.hasOwnProperty,te=new O("tag:yaml.org,2002:set",{kind:"mapping",resolve:function(e){if(null===e)return!0;var t,n=e;for(t in n)if(ee.call(n,t)&&null!==n[t])return!1;return!0},construct:function(e){return null!==e?e:{}}}),ne=B.extend({implicit:[W,G],explicit:[H,z,Q,te]}),ie=Object.prototype.hasOwnProperty,oe=1,re=2,ae=3,le=4,se=1,ce=2,ue=3,pe=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,fe=/[\x85\u2028\u2029]/,de=/[,\[\]\{\}]/,he=/^(?:!|!!|![a-z\-]+!)$/i,ge=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function me(e){return Object.prototype.toString.call(e)}function ye(e){return 10===e||13===e}function be(e){return 9===e||32===e}function ve(e){return 9===e||32===e||10===e||13===e}function Ae(e){return 44===e||91===e||93===e||123===e||125===e}function we(e){var t;return 48<=e&&e<=57?e-48:97<=(t=32|e)&&t<=102?t-97+10:-1}function ke(e){return 48===e?"\0":97===e?"":98===e?"\b":116===e||9===e?"\t":110===e?"\n":118===e?"\v":102===e?"\f":114===e?"\r":101===e?"":32===e?" ":34===e?'"':47===e?"/":92===e?"\\":78===e?"…":95===e?" ":76===e?"\u2028":80===e?"\u2029":""}function xe(e){return e<=65535?String.fromCharCode(e):String.fromCharCode(55296+(e-65536>>10),56320+(e-65536&1023))}for(var Ce=new Array(256),Oe=new Array(256),je=0;je<256;je++)Ce[je]=ke(je)?1:0,Oe[je]=ke(je);function Se(e,t){this.input=e,this.filename=t.filename||null,this.schema=t.schema||ne,this.onWarning=t.onWarning||null,this.legacy=t.legacy||!1,this.json=t.json||!1,this.listener=t.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function Ie(e,t){var n={name:e.filename,buffer:e.input.slice(0,-1),position:e.position,line:e.line,column:e.position-e.lineStart};return n.snippet=k(n),new v(t,n)}function _e(e,t){throw Ie(e,t)}function Te(e,t){e.onWarning&&e.onWarning.call(null,Ie(e,t))}var Ee={YAML:function(e,t,n){var i,o,r;null!==e.version&&_e(e,"duplication of %YAML directive"),1!==n.length&&_e(e,"YAML directive accepts exactly one argument"),null===(i=/^([0-9]+)\.([0-9]+)$/.exec(n[0]))&&_e(e,"ill-formed argument of the YAML directive"),o=parseInt(i[1],10),r=parseInt(i[2],10),1!==o&&_e(e,"unacceptable YAML version of the document"),e.version=n[0],e.checkLineBreaks=r<2,1!==r&&2!==r&&Te(e,"unsupported YAML version of the document")},TAG:function(e,t,n){var i,o;2!==n.length&&_e(e,"TAG directive accepts exactly two arguments"),i=n[0],o=n[1],he.test(i)||_e(e,"ill-formed tag handle (first argument) of the TAG directive"),ie.call(e.tagMap,i)&&_e(e,'there is a previously declared suffix for "'+i+'" tag handle'),ge.test(o)||_e(e,"ill-formed tag prefix (second argument) of the TAG directive");try{o=decodeURIComponent(o)}catch(t){_e(e,"tag prefix is malformed: "+o)}e.tagMap[i]=o}};function Ne(e,t,n,i){var o,r,a,l;if(t<n){if(l=e.input.slice(t,n),i)for(o=0,r=l.length;o<r;o+=1)9===(a=l.charCodeAt(o))||32<=a&&a<=1114111||_e(e,"expected valid JSON character");else pe.test(l)&&_e(e,"the stream contains non-printable characters");e.result+=l}}function Le(e,t,n,i){var o,r,a,l;for(m.isObject(n)||_e(e,"cannot merge mappings; the provided source object is unacceptable"),a=0,l=(o=Object.keys(n)).length;a<l;a+=1)r=o[a],ie.call(t,r)||(t[r]=n[r],i[r]=!0)}function Fe(e,t,n,i,o,r,a,l,s){var c,u;if(Array.isArray(o))for(c=0,u=(o=Array.prototype.slice.call(o)).length;c<u;c+=1)Array.isArray(o[c])&&_e(e,"nested arrays are not supported inside keys"),"object"==typeof o&&"[object Object]"===me(o[c])&&(o[c]="[object Object]");if("object"==typeof o&&"[object Object]"===me(o)&&(o="[object Object]"),o=String(o),null===t&&(t={}),"tag:yaml.org,2002:merge"===i)if(Array.isArray(r))for(c=0,u=r.length;c<u;c+=1)Le(e,t,r[c],n);else Le(e,t,r,n);else e.json||ie.call(n,o)||!ie.call(t,o)||(e.line=a||e.line,e.lineStart=l||e.lineStart,e.position=s||e.position,_e(e,"duplicated mapping key")),"__proto__"===o?Object.defineProperty(t,o,{configurable:!0,enumerable:!0,writable:!0,value:r}):t[o]=r,delete n[o];return t}function Me(e){var t;10===(t=e.input.charCodeAt(e.position))?e.position++:13===t?(e.position++,10===e.input.charCodeAt(e.position)&&e.position++):_e(e,"a line break is expected"),e.line+=1,e.lineStart=e.position,e.firstTabInLine=-1}function $e(e,t,n){for(var i=0,o=e.input.charCodeAt(e.position);0!==o;){for(;be(o);)9===o&&-1===e.firstTabInLine&&(e.firstTabInLine=e.position),o=e.input.charCodeAt(++e.position);if(t&&35===o)do{o=e.input.charCodeAt(++e.position)}while(10!==o&&13!==o&&0!==o);if(!ye(o))break;for(Me(e),o=e.input.charCodeAt(e.position),i++,e.lineIndent=0;32===o;)e.lineIndent++,o=e.input.charCodeAt(++e.position)}return-1!==n&&0!==i&&e.lineIndent<n&&Te(e,"deficient indentation"),i}function De(e){var t,n=e.position;return!(45!==(t=e.input.charCodeAt(n))&&46!==t||t!==e.input.charCodeAt(n+1)||t!==e.input.charCodeAt(n+2)||(n+=3,0!==(t=e.input.charCodeAt(n))&&!ve(t)))}function Re(e,t){1===t?e.result+=" ":t>1&&(e.result+=m.repeat("\n",t-1))}function Ue(e,t){var n,i,o=e.tag,r=e.anchor,a=[],l=!1;if(-1!==e.firstTabInLine)return!1;for(null!==e.anchor&&(e.anchorMap[e.anchor]=a),i=e.input.charCodeAt(e.position);0!==i&&(-1!==e.firstTabInLine&&(e.position=e.firstTabInLine,_e(e,"tab characters must not be used in indentation")),45===i)&&ve(e.input.charCodeAt(e.position+1));)if(l=!0,e.position++,$e(e,!0,-1)&&e.lineIndent<=t)a.push(null),i=e.input.charCodeAt(e.position);else if(n=e.line,Be(e,t,ae,!1,!0),a.push(e.result),$e(e,!0,-1),i=e.input.charCodeAt(e.position),(e.line===n||e.lineIndent>t)&&0!==i)_e(e,"bad indentation of a sequence entry");else if(e.lineIndent<t)break;return!!l&&(e.tag=o,e.anchor=r,e.kind="sequence",e.result=a,!0)}function qe(e){var t,n,i,o,r=!1,a=!1;if(33!==(o=e.input.charCodeAt(e.position)))return!1;if(null!==e.tag&&_e(e,"duplication of a tag property"),60===(o=e.input.charCodeAt(++e.position))?(r=!0,o=e.input.charCodeAt(++e.position)):33===o?(a=!0,n="!!",o=e.input.charCodeAt(++e.position)):n="!",t=e.position,r){do{o=e.input.charCodeAt(++e.position)}while(0!==o&&62!==o);e.position<e.length?(i=e.input.slice(t,e.position),o=e.input.charCodeAt(++e.position)):_e(e,"unexpected end of the stream within a verbatim tag")}else{for(;0!==o&&!ve(o);)33===o&&(a?_e(e,"tag suffix cannot contain exclamation marks"):(n=e.input.slice(t-1,e.position+1),he.test(n)||_e(e,"named tag handle cannot contain such characters"),a=!0,t=e.position+1)),o=e.input.charCodeAt(++e.position);i=e.input.slice(t,e.position),de.test(i)&&_e(e,"tag suffix cannot contain flow indicator characters")}i&&!ge.test(i)&&_e(e,"tag name cannot contain such characters: "+i);try{i=decodeURIComponent(i)}catch(t){_e(e,"tag name is malformed: "+i)}return r?e.tag=i:ie.call(e.tagMap,n)?e.tag=e.tagMap[n]+i:"!"===n?e.tag="!"+i:"!!"===n?e.tag="tag:yaml.org,2002:"+i:_e(e,'undeclared tag handle "'+n+'"'),!0}function Ye(e){var t,n;if(38!==(n=e.input.charCodeAt(e.position)))return!1;for(null!==e.anchor&&_e(e,"duplication of an anchor property"),n=e.input.charCodeAt(++e.position),t=e.position;0!==n&&!ve(n)&&!Ae(n);)n=e.input.charCodeAt(++e.position);return e.position===t&&_e(e,"name of an anchor node must contain at least one character"),e.anchor=e.input.slice(t,e.position),!0}function Be(e,t,n,i,o){var r,a,l,s,c,u,p,f,d,h=1,g=!1,y=!1;if(null!==e.listener&&e.listener("open",e),e.tag=null,e.anchor=null,e.kind=null,e.result=null,r=a=l=le===n||ae===n,i&&$e(e,!0,-1)&&(g=!0,e.lineIndent>t?h=1:e.lineIndent===t?h=0:e.lineIndent<t&&(h=-1)),1===h)for(;qe(e)||Ye(e);)$e(e,!0,-1)?(g=!0,l=r,e.lineIndent>t?h=1:e.lineIndent===t?h=0:e.lineIndent<t&&(h=-1)):l=!1;if(l&&(l=g||o),1!==h&&le!==n||(f=oe===n||re===n?t:t+1,d=e.position-e.lineStart,1===h?l&&(Ue(e,d)||function(e,t,n){var i,o,r,a,l,s,c,u=e.tag,p=e.anchor,f={},d=Object.create(null),h=null,g=null,m=null,y=!1,b=!1;if(-1!==e.firstTabInLine)return!1;for(null!==e.anchor&&(e.anchorMap[e.anchor]=f),c=e.input.charCodeAt(e.position);0!==c;){if(y||-1===e.firstTabInLine||(e.position=e.firstTabInLine,_e(e,"tab characters must not be used in indentation")),i=e.input.charCodeAt(e.position+1),r=e.line,63!==c&&58!==c||!ve(i)){if(a=e.line,l=e.lineStart,s=e.position,!Be(e,n,re,!1,!0))break;if(e.line===r){for(c=e.input.charCodeAt(e.position);be(c);)c=e.input.charCodeAt(++e.position);if(58===c)ve(c=e.input.charCodeAt(++e.position))||_e(e,"a whitespace character is expected after the key-value separator within a block mapping"),y&&(Fe(e,f,d,h,g,null,a,l,s),h=g=m=null),b=!0,y=!1,o=!1,h=e.tag,g=e.result;else{if(!b)return e.tag=u,e.anchor=p,!0;_e(e,"can not read an implicit mapping pair; a colon is missed")}}else{if(!b)return e.tag=u,e.anchor=p,!0;_e(e,"can not read a block mapping entry; a multiline key may not be an implicit key")}}else 63===c?(y&&(Fe(e,f,d,h,g,null,a,l,s),h=g=m=null),b=!0,y=!0,o=!0):y?(y=!1,o=!0):_e(e,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),e.position+=1,c=i;if((e.line===r||e.lineIndent>t)&&(y&&(a=e.line,l=e.lineStart,s=e.position),Be(e,t,le,!0,o)&&(y?g=e.result:m=e.result),y||(Fe(e,f,d,h,g,m,a,l,s),h=g=m=null),$e(e,!0,-1),c=e.input.charCodeAt(e.position)),(e.line===r||e.lineIndent>t)&&0!==c)_e(e,"bad indentation of a mapping entry");else if(e.lineIndent<t)break}return y&&Fe(e,f,d,h,g,null,a,l,s),b&&(e.tag=u,e.anchor=p,e.kind="mapping",e.result=f),b}(e,d,f))||function(e,t){var n,i,o,r,a,l,s,c,u,p,f,d,h=!0,g=e.tag,m=e.anchor,y=Object.create(null);if(91===(d=e.input.charCodeAt(e.position)))a=93,c=!1,r=[];else{if(123!==d)return!1;a=125,c=!0,r={}}for(null!==e.anchor&&(e.anchorMap[e.anchor]=r),d=e.input.charCodeAt(++e.position);0!==d;){if($e(e,!0,t),(d=e.input.charCodeAt(e.position))===a)return e.position++,e.tag=g,e.anchor=m,e.kind=c?"mapping":"sequence",e.result=r,!0;h?44===d&&_e(e,"expected the node content, but found ','"):_e(e,"missed comma between flow collection entries"),f=null,l=s=!1,63===d&&ve(e.input.charCodeAt(e.position+1))&&(l=s=!0,e.position++,$e(e,!0,t)),n=e.line,i=e.lineStart,o=e.position,Be(e,t,oe,!1,!0),p=e.tag,u=e.result,$e(e,!0,t),d=e.input.charCodeAt(e.position),!s&&e.line!==n||58!==d||(l=!0,d=e.input.charCodeAt(++e.position),$e(e,!0,t),Be(e,t,oe,!1,!0),f=e.result),c?Fe(e,r,y,p,u,f,n,i,o):l?r.push(Fe(e,null,y,p,u,f,n,i,o)):r.push(u),$e(e,!0,t),44===(d=e.input.charCodeAt(e.position))?(h=!0,d=e.input.charCodeAt(++e.position)):h=!1}_e(e,"unexpected end of the stream within a flow collection")}(e,f)?y=!0:(a&&function(e,t){var n,i,o,r,a,l=se,s=!1,c=!1,u=t,p=0,f=!1;if(124===(r=e.input.charCodeAt(e.position)))i=!1;else{if(62!==r)return!1;i=!0}for(e.kind="scalar",e.result="";0!==r;)if(43===(r=e.input.charCodeAt(++e.position))||45===r)se===l?l=43===r?ue:ce:_e(e,"repeat of a chomping mode identifier");else{if(!((o=48<=(a=r)&&a<=57?a-48:-1)>=0))break;0===o?_e(e,"bad explicit indentation width of a block scalar; it cannot be less than one"):c?_e(e,"repeat of an indentation width identifier"):(u=t+o-1,c=!0)}if(be(r)){do{r=e.input.charCodeAt(++e.position)}while(be(r));if(35===r)do{r=e.input.charCodeAt(++e.position)}while(!ye(r)&&0!==r)}for(;0!==r;){for(Me(e),e.lineIndent=0,r=e.input.charCodeAt(e.position);(!c||e.lineIndent<u)&&32===r;)e.lineIndent++,r=e.input.charCodeAt(++e.position);if(!c&&e.lineIndent>u&&(u=e.lineIndent),ye(r))p++;else{if(e.lineIndent<u){l===ue?e.result+=m.repeat("\n",s?1+p:p):l===se&&s&&(e.result+="\n");break}for(i?be(r)?(f=!0,e.result+=m.repeat("\n",s?1+p:p)):f?(f=!1,e.result+=m.repeat("\n",p+1)):0===p?s&&(e.result+=" "):e.result+=m.repeat("\n",p):e.result+=m.repeat("\n",s?1+p:p),s=!0,c=!0,p=0,n=e.position;!ye(r)&&0!==r;)r=e.input.charCodeAt(++e.position);Ne(e,n,e.position,!1)}}return!0}(e,f)||function(e,t){var n,i,o;if(39!==(n=e.input.charCodeAt(e.position)))return!1;for(e.kind="scalar",e.result="",e.position++,i=o=e.position;0!==(n=e.input.charCodeAt(e.position));)if(39===n){if(Ne(e,i,e.position,!0),39!==(n=e.input.charCodeAt(++e.position)))return!0;i=e.position,e.position++,o=e.position}else ye(n)?(Ne(e,i,o,!0),Re(e,$e(e,!1,t)),i=o=e.position):e.position===e.lineStart&&De(e)?_e(e,"unexpected end of the document within a single quoted scalar"):(e.position++,o=e.position);_e(e,"unexpected end of the stream within a single quoted scalar")}(e,f)||function(e,t){var n,i,o,r,a,l,s;if(34!==(l=e.input.charCodeAt(e.position)))return!1;for(e.kind="scalar",e.result="",e.position++,n=i=e.position;0!==(l=e.input.charCodeAt(e.position));){if(34===l)return Ne(e,n,e.position,!0),e.position++,!0;if(92===l){if(Ne(e,n,e.position,!0),ye(l=e.input.charCodeAt(++e.position)))$e(e,!1,t);else if(l<256&&Ce[l])e.result+=Oe[l],e.position++;else if((a=120===(s=l)?2:117===s?4:85===s?8:0)>0){for(o=a,r=0;o>0;o--)(a=we(l=e.input.charCodeAt(++e.position)))>=0?r=(r<<4)+a:_e(e,"expected hexadecimal character");e.result+=xe(r),e.position++}else _e(e,"unknown escape sequence");n=i=e.position}else ye(l)?(Ne(e,n,i,!0),Re(e,$e(e,!1,t)),n=i=e.position):e.position===e.lineStart&&De(e)?_e(e,"unexpected end of the document within a double quoted scalar"):(e.position++,i=e.position)}_e(e,"unexpected end of the stream within a double quoted scalar")}(e,f)?y=!0:function(e){var t,n,i;if(42!==(i=e.input.charCodeAt(e.position)))return!1;for(i=e.input.charCodeAt(++e.position),t=e.position;0!==i&&!ve(i)&&!Ae(i);)i=e.input.charCodeAt(++e.position);return e.position===t&&_e(e,"name of an alias node must contain at least one character"),n=e.input.slice(t,e.position),ie.call(e.anchorMap,n)||_e(e,'unidentified alias "'+n+'"'),e.result=e.anchorMap[n],$e(e,!0,-1),!0}(e)?(y=!0,null===e.tag&&null===e.anchor||_e(e,"alias node should not have any properties")):function(e,t,n){var i,o,r,a,l,s,c,u,p=e.kind,f=e.result;if(ve(u=e.input.charCodeAt(e.position))||Ae(u)||35===u||38===u||42===u||33===u||124===u||62===u||39===u||34===u||37===u||64===u||96===u)return!1;if((63===u||45===u)&&(ve(i=e.input.charCodeAt(e.position+1))||n&&Ae(i)))return!1;for(e.kind="scalar",e.result="",o=r=e.position,a=!1;0!==u;){if(58===u){if(ve(i=e.input.charCodeAt(e.position+1))||n&&Ae(i))break}else if(35===u){if(ve(e.input.charCodeAt(e.position-1)))break}else{if(e.position===e.lineStart&&De(e)||n&&Ae(u))break;if(ye(u)){if(l=e.line,s=e.lineStart,c=e.lineIndent,$e(e,!1,-1),e.lineIndent>=t){a=!0,u=e.input.charCodeAt(e.position);continue}e.position=r,e.line=l,e.lineStart=s,e.lineIndent=c;break}}a&&(Ne(e,o,r,!1),Re(e,e.line-l),o=r=e.position,a=!1),be(u)||(r=e.position+1),u=e.input.charCodeAt(++e.position)}return Ne(e,o,r,!1),!!e.result||(e.kind=p,e.result=f,!1)}(e,f,oe===n)&&(y=!0,null===e.tag&&(e.tag="?")),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):0===h&&(y=l&&Ue(e,d))),null===e.tag)null!==e.anchor&&(e.anchorMap[e.anchor]=e.result);else if("?"===e.tag){for(null!==e.result&&"scalar"!==e.kind&&_e(e,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+e.kind+'"'),s=0,c=e.implicitTypes.length;s<c;s+=1)if((p=e.implicitTypes[s]).resolve(e.result)){e.result=p.construct(e.result),e.tag=p.tag,null!==e.anchor&&(e.anchorMap[e.anchor]=e.result);break}}else if("!"!==e.tag){if(ie.call(e.typeMap[e.kind||"fallback"],e.tag))p=e.typeMap[e.kind||"fallback"][e.tag];else for(p=null,s=0,c=(u=e.typeMap.multi[e.kind||"fallback"]).length;s<c;s+=1)if(e.tag.slice(0,u[s].tag.length)===u[s].tag){p=u[s];break}p||_e(e,"unknown tag !<"+e.tag+">"),null!==e.result&&p.kind!==e.kind&&_e(e,"unacceptable node kind for !<"+e.tag+'> tag; it should be "'+p.kind+'", not "'+e.kind+'"'),p.resolve(e.result,e.tag)?(e.result=p.construct(e.result,e.tag),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):_e(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")}return null!==e.listener&&e.listener("close",e),null!==e.tag||null!==e.anchor||y}function Pe(e){var t,n,i,o,r=e.position,a=!1;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap=Object.create(null),e.anchorMap=Object.create(null);0!==(o=e.input.charCodeAt(e.position))&&($e(e,!0,-1),o=e.input.charCodeAt(e.position),!(e.lineIndent>0||37!==o));){for(a=!0,o=e.input.charCodeAt(++e.position),t=e.position;0!==o&&!ve(o);)o=e.input.charCodeAt(++e.position);for(i=[],(n=e.input.slice(t,e.position)).length<1&&_e(e,"directive name must not be less than one character in length");0!==o;){for(;be(o);)o=e.input.charCodeAt(++e.position);if(35===o){do{o=e.input.charCodeAt(++e.position)}while(0!==o&&!ye(o));break}if(ye(o))break;for(t=e.position;0!==o&&!ve(o);)o=e.input.charCodeAt(++e.position);i.push(e.input.slice(t,e.position))}0!==o&&Me(e),ie.call(Ee,n)?Ee[n](e,n,i):Te(e,'unknown document directive "'+n+'"')}$e(e,!0,-1),0===e.lineIndent&&45===e.input.charCodeAt(e.position)&&45===e.input.charCodeAt(e.position+1)&&45===e.input.charCodeAt(e.position+2)?(e.position+=3,$e(e,!0,-1)):a&&_e(e,"directives end mark is expected"),Be(e,e.lineIndent-1,le,!1,!0),$e(e,!0,-1),e.checkLineBreaks&&fe.test(e.input.slice(r,e.position))&&Te(e,"non-ASCII line breaks are interpreted as content"),e.documents.push(e.result),e.position===e.lineStart&&De(e)?46===e.input.charCodeAt(e.position)&&(e.position+=3,$e(e,!0,-1)):e.position<e.length-1&&_e(e,"end of the stream or a document separator is expected")}function Ve(e,t){t=t||{},0!==(e=String(e)).length&&(10!==e.charCodeAt(e.length-1)&&13!==e.charCodeAt(e.length-1)&&(e+="\n"),65279===e.charCodeAt(0)&&(e=e.slice(1)));var n=new Se(e,t),i=e.indexOf("\0");for(-1!==i&&(n.position=i,_e(n,"null byte is not allowed in input")),n.input+="\0";32===n.input.charCodeAt(n.position);)n.lineIndent+=1,n.position+=1;for(;n.position<n.length-1;)Pe(n);return n.documents}var We={loadAll:function(e,t,n){null!==t&&"object"==typeof t&&void 0===n&&(n=t,t=null);var i=Ve(e,n);if("function"!=typeof t)return i;for(var o=0,r=i.length;o<r;o+=1)t(i[o])},load:function(e,t){var n=Ve(e,t);if(0!==n.length){if(1===n.length)return n[0];throw new v("expected a single document in the stream, but found more")}}},Ge=Object.prototype.toString,Ke=Object.prototype.hasOwnProperty,He=65279,Je=9,Ze=10,ze=13,Xe=32,Qe=33,et=34,tt=35,nt=37,it=38,ot=39,rt=42,at=44,lt=45,st=58,ct=61,ut=62,pt=63,ft=64,dt=91,ht=93,gt=96,mt=123,yt=124,bt=125,vt={0:"\\0",7:"\\a",8:"\\b",9:"\\t",10:"\\n",11:"\\v",12:"\\f",13:"\\r",27:"\\e",34:'\\"',92:"\\\\",133:"\\N",160:"\\_",8232:"\\L",8233:"\\P"},At=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],wt=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function kt(e){var t,n,i;if(t=e.toString(16).toUpperCase(),e<=255)n="x",i=2;else if(e<=65535)n="u",i=4;else{if(!(e<=4294967295))throw new v("code point within a string may not be greater than 0xFFFFFFFF");n="U",i=8}return"\\"+n+m.repeat("0",i-t.length)+t}var xt=2;function Ct(e){this.schema=e.schema||ne,this.indent=Math.max(1,e.indent||2),this.noArrayIndent=e.noArrayIndent||!1,this.skipInvalid=e.skipInvalid||!1,this.flowLevel=m.isNothing(e.flowLevel)?-1:e.flowLevel,this.styleMap=function(e,t){var n,i,o,r,a,l,s;if(null===t)return{};for(n={},o=0,r=(i=Object.keys(t)).length;o<r;o+=1)a=i[o],l=String(t[a]),"!!"===a.slice(0,2)&&(a="tag:yaml.org,2002:"+a.slice(2)),(s=e.compiledTypeMap.fallback[a])&&Ke.call(s.styleAliases,l)&&(l=s.styleAliases[l]),n[a]=l;return n}(this.schema,e.styles||null),this.sortKeys=e.sortKeys||!1,this.lineWidth=e.lineWidth||80,this.noRefs=e.noRefs||!1,this.noCompatMode=e.noCompatMode||!1,this.condenseFlow=e.condenseFlow||!1,this.quotingType='"'===e.quotingType?xt:1,this.forceQuotes=e.forceQuotes||!1,this.replacer="function"==typeof e.replacer?e.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function Ot(e,t){for(var n,i=m.repeat(" ",t),o=0,r=-1,a="",l=e.length;o<l;)-1===(r=e.indexOf("\n",o))?(n=e.slice(o),o=l):(n=e.slice(o,r+1),o=r+1),n.length&&"\n"!==n&&(a+=i),a+=n;return a}function jt(e,t){return"\n"+m.repeat(" ",e.indent*t)}function St(e){return e===Xe||e===Je}function It(e){return 32<=e&&e<=126||161<=e&&e<=55295&&8232!==e&&8233!==e||57344<=e&&e<=65533&&e!==He||65536<=e&&e<=1114111}function _t(e){return It(e)&&e!==He&&e!==ze&&e!==Ze}function Tt(e,t,n){var i=_t(e),o=i&&!St(e);return(n?i:i&&e!==at&&e!==dt&&e!==ht&&e!==mt&&e!==bt)&&e!==tt&&!(t===st&&!o)||_t(t)&&!St(t)&&e===tt||t===st&&o}function Et(e,t){var n,i=e.charCodeAt(t);return i>=55296&&i<=56319&&t+1<e.length&&(n=e.charCodeAt(t+1))>=56320&&n<=57343?1024*(i-55296)+n-56320+65536:i}function Nt(e){return/^\n* /.test(e)}var Lt=1,Ft=2,Mt=3,$t=4,Dt=5;function Rt(e,t,n,i,o){e.dump=function(){if(0===t.length)return e.quotingType===xt?'""':"''";if(!e.noCompatMode&&(-1!==At.indexOf(t)||wt.test(t)))return e.quotingType===xt?'"'+t+'"':"'"+t+"'";var r=e.indent*Math.max(1,n),a=-1===e.lineWidth?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-r),l=i||e.flowLevel>-1&&n>=e.flowLevel;switch(function(e,t,n,i,o,r,a,l){var s,c,u=0,p=null,f=!1,d=!1,h=-1!==i,g=-1,m=It(c=Et(e,0))&&c!==He&&!St(c)&&c!==lt&&c!==pt&&c!==st&&c!==at&&c!==dt&&c!==ht&&c!==mt&&c!==bt&&c!==tt&&c!==it&&c!==rt&&c!==Qe&&c!==yt&&c!==ct&&c!==ut&&c!==ot&&c!==et&&c!==nt&&c!==ft&&c!==gt&&function(e){return!St(e)&&e!==st}(Et(e,e.length-1));if(t||a)for(s=0;s<e.length;u>=65536?s+=2:s++){if(!It(u=Et(e,s)))return Dt;m=m&&Tt(u,p,l),p=u}else{for(s=0;s<e.length;u>=65536?s+=2:s++){if((u=Et(e,s))===Ze)f=!0,h&&(d=d||s-g-1>i&&" "!==e[g+1],g=s);else if(!It(u))return Dt;m=m&&Tt(u,p,l),p=u}d=d||h&&s-g-1>i&&" "!==e[g+1]}return f||d?n>9&&Nt(e)?Dt:a?r===xt?Dt:Ft:d?$t:Mt:!m||a||o(e)?r===xt?Dt:Ft:Lt}(t,l,e.indent,a,(function(t){return function(e,t){var n,i;for(n=0,i=e.implicitTypes.length;n<i;n+=1)if(e.implicitTypes[n].resolve(t))return!0;return!1}(e,t)}),e.quotingType,e.forceQuotes&&!i,o)){case Lt:return t;case Ft:return"'"+t.replace(/'/g,"''")+"'";case Mt:return"|"+Ut(t,e.indent)+qt(Ot(t,r));case $t:return">"+Ut(t,e.indent)+qt(Ot(function(e,t){for(var n,i,o,r=/(\n+)([^\n]*)/g,a=(o=-1!==(o=e.indexOf("\n"))?o:e.length,r.lastIndex=o,Yt(e.slice(0,o),t)),l="\n"===e[0]||" "===e[0];i=r.exec(e);){var s=i[1],c=i[2];n=" "===c[0],a+=s+(l||n||""===c?"":"\n")+Yt(c,t),l=n}return a}(t,a),r));case Dt:return'"'+function(e){for(var t,n="",i=0,o=0;o<e.length;i>=65536?o+=2:o++)i=Et(e,o),!(t=vt[i])&&It(i)?(n+=e[o],i>=65536&&(n+=e[o+1])):n+=t||kt(i);return n}(t)+'"';default:throw new v("impossible error: invalid scalar style")}}()}function Ut(e,t){var n=Nt(e)?String(t):"",i="\n"===e[e.length-1];return n+(!i||"\n"!==e[e.length-2]&&"\n"!==e?i?"":"-":"+")+"\n"}function qt(e){return"\n"===e[e.length-1]?e.slice(0,-1):e}function Yt(e,t){if(""===e||" "===e[0])return e;for(var n,i,o=/ [^ ]/g,r=0,a=0,l=0,s="";n=o.exec(e);)(l=n.index)-r>t&&(i=a>r?a:l,s+="\n"+e.slice(r,i),r=i+1),a=l;return s+="\n",e.length-r>t&&a>r?s+=e.slice(r,a)+"\n"+e.slice(a+1):s+=e.slice(r),s.slice(1)}function Bt(e,t,n,i){var o,r,a,l="",s=e.tag;for(o=0,r=n.length;o<r;o+=1)a=n[o],e.replacer&&(a=e.replacer.call(n,String(o),a)),(Vt(e,t+1,a,!0,!0,!1,!0)||void 0===a&&Vt(e,t+1,null,!0,!0,!1,!0))&&(i&&""===l||(l+=jt(e,t)),e.dump&&Ze===e.dump.charCodeAt(0)?l+="-":l+="- ",l+=e.dump);e.tag=s,e.dump=l||"[]"}function Pt(e,t,n){var i,o,r,a,l,s;for(r=0,a=(o=n?e.explicitTypes:e.implicitTypes).length;r<a;r+=1)if(((l=o[r]).instanceOf||l.predicate)&&(!l.instanceOf||"object"==typeof t&&t instanceof l.instanceOf)&&(!l.predicate||l.predicate(t))){if(n?l.multi&&l.representName?e.tag=l.representName(t):e.tag=l.tag:e.tag="?",l.represent){if(s=e.styleMap[l.tag]||l.defaultStyle,"[object Function]"===Ge.call(l.represent))i=l.represent(t,s);else{if(!Ke.call(l.represent,s))throw new v("!<"+l.tag+'> tag resolver accepts not "'+s+'" style');i=l.represent[s](t,s)}e.dump=i}return!0}return!1}function Vt(e,t,n,i,o,r,a){e.tag=null,e.dump=n,Pt(e,n,!1)||Pt(e,n,!0);var l,s=Ge.call(e.dump),c=i;i&&(i=e.flowLevel<0||e.flowLevel>t);var u,p,f="[object Object]"===s||"[object Array]"===s;if(f&&(p=-1!==(u=e.duplicates.indexOf(n))),(null!==e.tag&&"?"!==e.tag||p||2!==e.indent&&t>0)&&(o=!1),p&&e.usedDuplicates[u])e.dump="*ref_"+u;else{if(f&&p&&!e.usedDuplicates[u]&&(e.usedDuplicates[u]=!0),"[object Object]"===s)i&&0!==Object.keys(e.dump).length?(function(e,t,n,i){var o,r,a,l,s,c,u="",p=e.tag,f=Object.keys(n);if(!0===e.sortKeys)f.sort();else if("function"==typeof e.sortKeys)f.sort(e.sortKeys);else if(e.sortKeys)throw new v("sortKeys must be a boolean or a function");for(o=0,r=f.length;o<r;o+=1)c="",i&&""===u||(c+=jt(e,t)),l=n[a=f[o]],e.replacer&&(l=e.replacer.call(n,a,l)),Vt(e,t+1,a,!0,!0,!0)&&((s=null!==e.tag&&"?"!==e.tag||e.dump&&e.dump.length>1024)&&(e.dump&&Ze===e.dump.charCodeAt(0)?c+="?":c+="? "),c+=e.dump,s&&(c+=jt(e,t)),Vt(e,t+1,l,!0,s)&&(e.dump&&Ze===e.dump.charCodeAt(0)?c+=":":c+=": ",u+=c+=e.dump));e.tag=p,e.dump=u||"{}"}(e,t,e.dump,o),p&&(e.dump="&ref_"+u+e.dump)):(function(e,t,n){var i,o,r,a,l,s="",c=e.tag,u=Object.keys(n);for(i=0,o=u.length;i<o;i+=1)l="",""!==s&&(l+=", "),e.condenseFlow&&(l+='"'),a=n[r=u[i]],e.replacer&&(a=e.replacer.call(n,r,a)),Vt(e,t,r,!1,!1)&&(e.dump.length>1024&&(l+="? "),l+=e.dump+(e.condenseFlow?'"':"")+":"+(e.condenseFlow?"":" "),Vt(e,t,a,!1,!1)&&(s+=l+=e.dump));e.tag=c,e.dump="{"+s+"}"}(e,t,e.dump),p&&(e.dump="&ref_"+u+" "+e.dump));else if("[object Array]"===s)i&&0!==e.dump.length?(e.noArrayIndent&&!a&&t>0?Bt(e,t-1,e.dump,o):Bt(e,t,e.dump,o),p&&(e.dump="&ref_"+u+e.dump)):(function(e,t,n){var i,o,r,a="",l=e.tag;for(i=0,o=n.length;i<o;i+=1)r=n[i],e.replacer&&(r=e.replacer.call(n,String(i),r)),(Vt(e,t,r,!1,!1)||void 0===r&&Vt(e,t,null,!1,!1))&&(""!==a&&(a+=","+(e.condenseFlow?"":" ")),a+=e.dump);e.tag=l,e.dump="["+a+"]"}(e,t,e.dump),p&&(e.dump="&ref_"+u+" "+e.dump));else{if("[object String]"!==s){if("[object Undefined]"===s)return!1;if(e.skipInvalid)return!1;throw new v("unacceptable kind of an object to dump "+s)}"?"!==e.tag&&Rt(e,e.dump,t,r,c)}null!==e.tag&&"?"!==e.tag&&(l=encodeURI("!"===e.tag[0]?e.tag.slice(1):e.tag).replace(/!/g,"%21"),l="!"===e.tag[0]?"!"+l:"tag:yaml.org,2002:"===l.slice(0,18)?"!!"+l.slice(18):"!<"+l+">",e.dump=l+" "+e.dump)}return!0}function Wt(e,t){var n,i,o=[],r=[];for(Gt(e,o,r),n=0,i=r.length;n<i;n+=1)t.duplicates.push(o[r[n]]);t.usedDuplicates=new Array(i)}function Gt(e,t,n){var i,o,r;if(null!==e&&"object"==typeof e)if(-1!==(o=t.indexOf(e)))-1===n.indexOf(o)&&n.push(o);else if(t.push(e),Array.isArray(e))for(o=0,r=e.length;o<r;o+=1)Gt(e[o],t,n);else for(o=0,r=(i=Object.keys(e)).length;o<r;o+=1)Gt(e[i[o]],t,n)}function Kt(e,t){return function(){throw new Error("Function yaml."+e+" is removed in js-yaml 4. Use yaml."+t+" instead, which is now safe by default.")}}const Ht={Type:O,Schema:I,FAILSAFE_SCHEMA:N,JSON_SCHEMA:Y,CORE_SCHEMA:B,DEFAULT_SCHEMA:ne,load:We.load,loadAll:We.loadAll,dump:function(e,t){var n=new Ct(t=t||{});n.noRefs||Wt(e,n);var i=e;return n.replacer&&(i=n.replacer.call({"":i},"",i)),Vt(n,0,i,!0,!0)?n.dump+"\n":""},YAMLException:v,types:{binary:H,float:q,map:E,null:L,pairs:Q,set:te,timestamp:W,bool:F,int:D,merge:G,omap:z,seq:T,str:_},safeLoad:Kt("safeLoad","load"),safeLoadAll:Kt("safeLoadAll","loadAll"),safeDump:Kt("safeDump","dump")};var Jt;function Zt(e,t){return"function"==typeof t?t.toString():["",null].includes(t)||"object"==typeof t&&(0===t.length||0===Object.keys(t).length)?void 0:t}function zt(e){const t={get(e,t,n){const i=Reflect.get(e,t,n);return"object"==typeof i&&null!==i?Array.isArray(i)?i.map((e=>zt(e))):zt(i):`{${t}}`}};return Array.isArray(e)?e.map((e=>zt(e))):new Proxy(e,t)}function Xt(e){let t;if("object"==typeof e.state){const n=zt(e.state);t=e.view(n)}else t=e.view(e.state);return t}function Qt(e){const t=window.open("","_apprun_debug","toolbar=0");t.document.write(`<html>\n <title>AppRun Analyzer | ${document.location.href}</title>\n <style>\n body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI" }\n li { margin-left: 80px; }\n </style>\n <body>\n <div id="main">${e}</div>\n <\/script>\n </body>\n </html>`),t.document.close()}i.A.debug=!0,window["_apprun-help"]=["",()=>{Object.keys(window).forEach((e=>{e.startsWith("_apprun-")&&("_apprun-help"===e?console.log("AppRun Commands:"):console.log(`* ${e.substring(8)}: ${window[e][0]}`))}))}];const en=()=>{const e={components:{}};i.A.run("get-components",e);const{components:t}=e;return t};let tn=Number(null===(Jt=null===window||void 0===window?void 0:window.localStorage)||void 0===Jt?void 0:Jt.getItem("__apprun_debugging__"))||0;if(i.A.on("debug",(e=>{1&tn&&e.event&&console.log(e),2&tn&&e.vdom&&console.log(e)})),window["_apprun-components"]=["components [print]",e=>{(e=>{const t=en(),n=[];if(t instanceof Map)for(let[e,i]of t){const t="string"==typeof e?document.getElementById(e)||document.querySelector(e):e;n.push({element:t,comps:i})}else Object.keys(t).forEach((e=>{const i="string"==typeof e?document.getElementById(e)||document.querySelector(e):e;n.push({element:i,comps:t[e]})}));if(e){const e=(e=>{const t=({components:e})=>i.A.h("ul",null,e.map((e=>{const t=Xt(e),n=e._actions.map((e=>e.name)),o={state:e.state,view:t,actions:n,update:e.update};return i.A.h("li",null,i.A.h("div",null,e.constructor.name),i.A.h("div",null,i.A.h("pre",null,(r=Ht.dump(o,{replacer:Zt}))?r.toString().replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;"):r)),i.A.h("br",null));var r})));return i.A.h("ul",null,e.map((({element:e,comps:n})=>i.A.h("li",null,i.A.h("div",null,(e=>i.A.h("div",null,e.tagName.toLowerCase(),e.id?"#"+e.id:""," ",e.className&&e.className.split(" ").map((e=>"."+e)).join()))(e)),i.A.h(t,{components:n})))))})(n);Qt(l(e))}else n.forEach((({element:e,comps:t})=>console.log(e,t)))})("print"===e)}],window["_apprun-events"]=["events [print]",e=>{(e=>{const t=i.A._events,n={},o=en(),r=e=>e._actions.forEach((t=>{n[t.name]=n[t.name]||[],n[t.name].push(e)}));if(o instanceof Map)for(let[e,t]of o)t.forEach(r);else Object.keys(o).forEach((e=>o[e].forEach(r)));const a=[];if(Object.keys(n).forEach((e=>{a.push({event:e,components:n[e],global:!!t[e]})})),a.sort(((e,t)=>e.event>t.event?1:-1)).map((e=>e.event)),e){const e=(e=>{const t=({components:e})=>i.A.h("ul",null,e.map((e=>i.A.h("li",null,i.A.h("div",null,e.constructor.name))))),n=({events:e,global:n})=>i.A.h("ul",null,e&&e.filter((e=>e.global===n&&"."!==e.event)).map((({event:e,components:n})=>i.A.h("li",null,i.A.h("div",null,e),i.A.h(t,{components:n})))));return i.A.h("div",null,i.A.h("div",null,"GLOBAL EVENTS"),i.A.h(n,{events:e,global:!0}),i.A.h("div",null,"LOCAL EVENTS"),i.A.h(n,{events:e,global:!1}))})(a);Qt(l(e))}else console.log("=== GLOBAL EVENTS ==="),a.filter((e=>e.global&&"."!==e.event)).forEach((({event:e,components:t})=>console.log({event:e},t))),console.log("=== LOCAL EVENTS ==="),a.filter((e=>!e.global&&"."!==e.event)).forEach((({event:e,components:t})=>console.log({event:e},t)))})("print"===e)}],window["_apprun-log"]=["log [event|view] on|off",(e,t)=>{var n;"on"===e?tn=3:"off"===e?tn=0:"event"===e?"on"===t?tn|=1:"off"===t&&(tn&=-2):"view"===e&&("on"===t?tn|=2:"off"===t&&(tn&=-3)),console.log(`* log ${e} ${t||""}`),null===(n=null===window||void 0===window?void 0:window.localStorage)||void 0===n||n.setItem("__apprun_debugging__",`${tn}`)}],window["_apprun-create-event-tests"]=["create-event-tests",()=>(()=>{const e={components:{}};app.run("get-components",e);const{components:t}=e;if(c(""),t instanceof Map)for(let[e,n]of t)n.forEach(f);else Object.keys(t).forEach((e=>{t[e].forEach(f)}));p()})()],window["_apprun-create-state-tests"]=["create-state-tests <start|stop>",e=>{var t;"start"===(t=e)?(h=[],d=!0,console.log("* State logging started.")):"stop"===t?(0!==h.length?(c(""),h.forEach(((e,t)=>{u(` it ('view snapshot: #${t+1}', ()=>{`),u(` const component = new ${e.component.constructor.name}()`),u(` const state = ${JSON.stringify(e.state,void 0,2)};`),u(" const vdom = component['view'](state);"),u(" expect(JSON.stringify(vdom)).toMatchSnapshot();"),u(" })")})),p()):console.log("* No state recorded."),d=!1,h=[],console.log("* State logging stopped.")):console.log("create-state-tests <start|stop>")}],window._apprun=e=>{const[t,...n]=e[0].split(" ").filter((e=>!!e)),i=window[`_apprun-${t}`];i?i[1](...n):window["_apprun-help"][1]()},console.info('AppRun DevTools 2.27: type "_apprun `help`" to list all available commands.'),window.__REDUX_DEVTOOLS_EXTENSION__){let e=!1;const t=window.__REDUX_DEVTOOLS_EXTENSION__.connect();if(t){const n=location.hash||"#";t.send(n,"");const o=[{component:null,state:""}];console.info("Connected to the Redux DevTools"),t.subscribe((t=>{if("START"===t.type)e=!0;else if("STOP"===t.type)e=!1;else if("DISPATCH"===t.type){const e=t.payload.index;if(0===e)i.A.run(n);else{const{component:t,state:n}=o[e];null==t||t.setState(n)}}}));const r=(e,n,i)=>{null!=i&&(o.push({component:e,state:i}),t.send(n,i))};i.A.on("debug",(t=>{if(e&&t.event){const e=t.newState,n={type:t.event,payload:t.p},i=t.component;e instanceof Promise?e.then((e=>r(i,n,e))):r(i,n,e)}}))}}return{}})()));
2
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.apprun=t():e.apprun=t()}(this,(()=>(()=>{"use strict";var e={859:(e,t,n)=>{n.d(t,{A:()=>r});let i;const o="undefined"!=typeof window?window:void 0!==n.g?n.g:"undefined"!=typeof self?self:{};o.app&&o._AppRunVersions?i=o.app:(i=new class{constructor(){this._events={}}on(e,t,n={}){this._events[e]=this._events[e]||[],this._events[e].push({fn:t,options:n})}off(e,t){const n=this._events[e]||[];this._events[e]=n.filter((e=>e.fn!==t))}find(e){return this._events[e]}run(e,...t){const n=this.getSubscribers(e,this._events);return console.assert(n&&n.length>0,"No subscriber for event: "+e),n.forEach((n=>{const{fn:i,options:o}=n;return o.delay?this.delay(e,i,t,o):Object.keys(o).length>0?i.apply(this,[...t,o]):i.apply(this,t),!n.options.once})),n.length}once(e,t,n={}){this.on(e,t,Object.assign(Object.assign({},n),{once:!0}))}delay(e,t,n,i){i._t&&clearTimeout(i._t),i._t=setTimeout((()=>{clearTimeout(i._t),Object.keys(i).length>0?t.apply(this,[...n,i]):t.apply(this,n)}),i.delay)}runAsync(e,...t){const n=this.getSubscribers(e,this._events);console.assert(n&&n.length>0,"No subscriber for event: "+e);const i=n.map((e=>{const{fn:n,options:i}=e;return Object.keys(i).length>0?n.apply(this,[...t,i]):n.apply(this,t)}));return Promise.all(i)}query(e,...t){return this.runAsync(e,...t)}getSubscribers(e,t){const n=t[e]||[];return t[e]=n.filter((e=>!e.options.once)),Object.keys(t).filter((t=>t.endsWith("*")&&e.startsWith(t.replace("*","")))).sort(((e,t)=>t.length-e.length)).forEach((i=>n.push(...t[i].map((t=>Object.assign(Object.assign({},t),{options:Object.assign(Object.assign({},t.options),{event:e})})))))),n}},o.app=i,o._AppRunVersions="AppRun-3.3.11");const r=i}},t={};function n(i){var o=t[i];if(void 0!==o)return o.exports;var r=t[i]={exports:{}};return e[i](r,r.exports,n),r.exports}n.d=(e,t)=>{for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var i=n(859);function o(e){return e.map((e=>a(e))).join("")}function r(e){for(var t in e)null==e[t]?delete e[t]:"object"==typeof e[t]&&r(e[t])}function a(e){if(!e)return"";if(e._$litType$)return e.toString();if(r(e),Array.isArray(e))return o(e);if("string"==typeof e)return e.startsWith("_html:")?e.substring(6):e;if(e.tag){const t=e.props?function(e){return Object.keys(e).map((t=>{return` ${"className"===t?"class":t}="${n=e[t],"object"==typeof n?Object.keys(n).map((e=>`${e}:${n[e]}`)).join(";"):n.toString()}"`;var n})).join("")}(e.props):"",n=e.children?o(e.children):"";return`<${e.tag}${t}>${n}</${e.tag}>`}return"object"==typeof e?JSON.stringify(e):void 0}const l=a;let s;function c(e){s=window.open("",e),s.document.write(`<html>\n <title>AppRun Analyzer | ${document.location.href}</title>\n <style>\n body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI" }\n </style>\n <body><pre>`)}function u(e){s.document.write(e+"\n")}function p(){s.document.write("</pre>\n </body>\n </html>"),s.document.close()}app.debug=!0;const f=e=>{u(`import ${e.constructor.name} from '../src/${e.constructor.name}'`),u(`describe('${e.constructor.name}', ()=>{`),e._actions.forEach((t=>{"."!==t.name&&(u(` it ('should handle event: ${t.name}', (done)=>{`),u(` const component = new ${e.constructor.name}().mount();`),u(` component.run('${t.name}');`),u(" setTimeout(() => {"),u(" //expect(?).toHaveBeenCalled();"),u(" //expect(component.state).toBe(?);"),u(" done();"),u(" })"))})),u("});")};let d=!1,h=[];app.on("debug",(e=>{d&&e.vdom&&(h.push(e),console.log(`* ${h.length} state(s) recorded.`))}));function g(e){return null==e}var m={isNothing:g,isObject:function(e){return"object"==typeof e&&null!==e},toArray:function(e){return Array.isArray(e)?e:g(e)?[]:[e]},repeat:function(e,t){var n,i="";for(n=0;n<t;n+=1)i+=e;return i},isNegativeZero:function(e){return 0===e&&Number.NEGATIVE_INFINITY===1/e},extend:function(e,t){var n,i,o,r;if(t)for(n=0,i=(r=Object.keys(t)).length;n<i;n+=1)e[o=r[n]]=t[o];return e}};function y(e,t){var n="",i=e.reason||"(unknown reason)";return e.mark?(e.mark.name&&(n+='in "'+e.mark.name+'" '),n+="("+(e.mark.line+1)+":"+(e.mark.column+1)+")",!t&&e.mark.snippet&&(n+="\n\n"+e.mark.snippet),i+" "+n):i}function b(e,t){Error.call(this),this.name="YAMLException",this.reason=e,this.mark=t,this.message=y(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack||""}b.prototype=Object.create(Error.prototype),b.prototype.constructor=b,b.prototype.toString=function(e){return this.name+": "+y(this,e)};var v=b;function A(e,t,n,i,o){var r="",a="",l=Math.floor(o/2)-1;return i-t>l&&(t=i-l+(r=" ... ").length),n-i>l&&(n=i+l-(a=" ...").length),{str:r+e.slice(t,n).replace(/\t/g,"→")+a,pos:i-t+r.length}}function w(e,t){return m.repeat(" ",t-e.length)+e}var k=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],x=["scalar","sequence","mapping"],C=function(e,t){if(t=t||{},Object.keys(t).forEach((function(t){if(-1===k.indexOf(t))throw new v('Unknown option "'+t+'" is met in definition of "'+e+'" YAML type.')})),this.options=t,this.tag=e,this.kind=t.kind||null,this.resolve=t.resolve||function(){return!0},this.construct=t.construct||function(e){return e},this.instanceOf=t.instanceOf||null,this.predicate=t.predicate||null,this.represent=t.represent||null,this.representName=t.representName||null,this.defaultStyle=t.defaultStyle||null,this.multi=t.multi||!1,this.styleAliases=function(e){var t={};return null!==e&&Object.keys(e).forEach((function(n){e[n].forEach((function(e){t[String(e)]=n}))})),t}(t.styleAliases||null),-1===x.indexOf(this.kind))throw new v('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')};function O(e,t){var n=[];return e[t].forEach((function(e){var t=n.length;n.forEach((function(n,i){n.tag===e.tag&&n.kind===e.kind&&n.multi===e.multi&&(t=i)})),n[t]=e})),n}function S(e){return this.extend(e)}S.prototype.extend=function(e){var t=[],n=[];if(e instanceof C)n.push(e);else if(Array.isArray(e))n=n.concat(e);else{if(!e||!Array.isArray(e.implicit)&&!Array.isArray(e.explicit))throw new v("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");e.implicit&&(t=t.concat(e.implicit)),e.explicit&&(n=n.concat(e.explicit))}t.forEach((function(e){if(!(e instanceof C))throw new v("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(e.loadKind&&"scalar"!==e.loadKind)throw new v("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(e.multi)throw new v("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")})),n.forEach((function(e){if(!(e instanceof C))throw new v("Specified list of YAML types (or a single Type object) contains a non-Type object.")}));var i=Object.create(S.prototype);return i.implicit=(this.implicit||[]).concat(t),i.explicit=(this.explicit||[]).concat(n),i.compiledImplicit=O(i,"implicit"),i.compiledExplicit=O(i,"explicit"),i.compiledTypeMap=function(){var e,t,n={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function i(e){e.multi?(n.multi[e.kind].push(e),n.multi.fallback.push(e)):n[e.kind][e.tag]=n.fallback[e.tag]=e}for(e=0,t=arguments.length;e<t;e+=1)arguments[e].forEach(i);return n}(i.compiledImplicit,i.compiledExplicit),i};var j=S,I=new C("tag:yaml.org,2002:str",{kind:"scalar",construct:function(e){return null!==e?e:""}}),_=new C("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(e){return null!==e?e:[]}}),T=new C("tag:yaml.org,2002:map",{kind:"mapping",construct:function(e){return null!==e?e:{}}}),E=new j({explicit:[I,_,T]}),N=new C("tag:yaml.org,2002:null",{kind:"scalar",resolve:function(e){if(null===e)return!0;var t=e.length;return 1===t&&"~"===e||4===t&&("null"===e||"Null"===e||"NULL"===e)},construct:function(){return null},predicate:function(e){return null===e},represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"}),L=new C("tag:yaml.org,2002:bool",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t=e.length;return 4===t&&("true"===e||"True"===e||"TRUE"===e)||5===t&&("false"===e||"False"===e||"FALSE"===e)},construct:function(e){return"true"===e||"True"===e||"TRUE"===e},predicate:function(e){return"[object Boolean]"===Object.prototype.toString.call(e)},represent:{lowercase:function(e){return e?"true":"false"},uppercase:function(e){return e?"TRUE":"FALSE"},camelcase:function(e){return e?"True":"False"}},defaultStyle:"lowercase"});function F(e){return 48<=e&&e<=55}function M(e){return 48<=e&&e<=57}var $=new C("tag:yaml.org,2002:int",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t,n,i=e.length,o=0,r=!1;if(!i)return!1;if("-"!==(t=e[o])&&"+"!==t||(t=e[++o]),"0"===t){if(o+1===i)return!0;if("b"===(t=e[++o])){for(o++;o<i;o++)if("_"!==(t=e[o])){if("0"!==t&&"1"!==t)return!1;r=!0}return r&&"_"!==t}if("x"===t){for(o++;o<i;o++)if("_"!==(t=e[o])){if(!(48<=(n=e.charCodeAt(o))&&n<=57||65<=n&&n<=70||97<=n&&n<=102))return!1;r=!0}return r&&"_"!==t}if("o"===t){for(o++;o<i;o++)if("_"!==(t=e[o])){if(!F(e.charCodeAt(o)))return!1;r=!0}return r&&"_"!==t}}if("_"===t)return!1;for(;o<i;o++)if("_"!==(t=e[o])){if(!M(e.charCodeAt(o)))return!1;r=!0}return!(!r||"_"===t)},construct:function(e){var t,n=e,i=1;if(-1!==n.indexOf("_")&&(n=n.replace(/_/g,"")),"-"!==(t=n[0])&&"+"!==t||("-"===t&&(i=-1),t=(n=n.slice(1))[0]),"0"===n)return 0;if("0"===t){if("b"===n[1])return i*parseInt(n.slice(2),2);if("x"===n[1])return i*parseInt(n.slice(2),16);if("o"===n[1])return i*parseInt(n.slice(2),8)}return i*parseInt(n,10)},predicate:function(e){return"[object Number]"===Object.prototype.toString.call(e)&&e%1==0&&!m.isNegativeZero(e)},represent:{binary:function(e){return e>=0?"0b"+e.toString(2):"-0b"+e.toString(2).slice(1)},octal:function(e){return e>=0?"0o"+e.toString(8):"-0o"+e.toString(8).slice(1)},decimal:function(e){return e.toString(10)},hexadecimal:function(e){return e>=0?"0x"+e.toString(16).toUpperCase():"-0x"+e.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),D=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"),R=/^[-+]?[0-9]+e/,U=new C("tag:yaml.org,2002:float",{kind:"scalar",resolve:function(e){return null!==e&&!(!D.test(e)||"_"===e[e.length-1])},construct:function(e){var t,n;return n="-"===(t=e.replace(/_/g,"").toLowerCase())[0]?-1:1,"+-".indexOf(t[0])>=0&&(t=t.slice(1)),".inf"===t?1===n?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:".nan"===t?NaN:n*parseFloat(t,10)},predicate:function(e){return"[object Number]"===Object.prototype.toString.call(e)&&(e%1!=0||m.isNegativeZero(e))},represent:function(e,t){var n;if(isNaN(e))switch(t){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(t){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(t){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(m.isNegativeZero(e))return"-0.0";return n=e.toString(10),R.test(n)?n.replace("e",".e"):n},defaultStyle:"lowercase"}),q=E.extend({implicit:[N,L,$,U]}),Y=q,B=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),P=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$"),V=new C("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:function(e){return null!==e&&(null!==B.exec(e)||null!==P.exec(e))},construct:function(e){var t,n,i,o,r,a,l,s,c=0,u=null;if(null===(t=B.exec(e))&&(t=P.exec(e)),null===t)throw new Error("Date resolve error");if(n=+t[1],i=+t[2]-1,o=+t[3],!t[4])return new Date(Date.UTC(n,i,o));if(r=+t[4],a=+t[5],l=+t[6],t[7]){for(c=t[7].slice(0,3);c.length<3;)c+="0";c=+c}return t[9]&&(u=6e4*(60*+t[10]+ +(t[11]||0)),"-"===t[9]&&(u=-u)),s=new Date(Date.UTC(n,i,o,r,a,l,c)),u&&s.setTime(s.getTime()-u),s},instanceOf:Date,represent:function(e){return e.toISOString()}}),W=new C("tag:yaml.org,2002:merge",{kind:"scalar",resolve:function(e){return"<<"===e||null===e}}),G="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r",K=new C("tag:yaml.org,2002:binary",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t,n,i=0,o=e.length,r=G;for(n=0;n<o;n++)if(!((t=r.indexOf(e.charAt(n)))>64)){if(t<0)return!1;i+=6}return i%8==0},construct:function(e){var t,n,i=e.replace(/[\r\n=]/g,""),o=i.length,r=G,a=0,l=[];for(t=0;t<o;t++)t%4==0&&t&&(l.push(a>>16&255),l.push(a>>8&255),l.push(255&a)),a=a<<6|r.indexOf(i.charAt(t));return 0==(n=o%4*6)?(l.push(a>>16&255),l.push(a>>8&255),l.push(255&a)):18===n?(l.push(a>>10&255),l.push(a>>2&255)):12===n&&l.push(a>>4&255),new Uint8Array(l)},predicate:function(e){return"[object Uint8Array]"===Object.prototype.toString.call(e)},represent:function(e){var t,n,i="",o=0,r=e.length,a=G;for(t=0;t<r;t++)t%3==0&&t&&(i+=a[o>>18&63],i+=a[o>>12&63],i+=a[o>>6&63],i+=a[63&o]),o=(o<<8)+e[t];return 0==(n=r%3)?(i+=a[o>>18&63],i+=a[o>>12&63],i+=a[o>>6&63],i+=a[63&o]):2===n?(i+=a[o>>10&63],i+=a[o>>4&63],i+=a[o<<2&63],i+=a[64]):1===n&&(i+=a[o>>2&63],i+=a[o<<4&63],i+=a[64],i+=a[64]),i}}),H=Object.prototype.hasOwnProperty,J=Object.prototype.toString,Z=new C("tag:yaml.org,2002:omap",{kind:"sequence",resolve:function(e){if(null===e)return!0;var t,n,i,o,r,a=[],l=e;for(t=0,n=l.length;t<n;t+=1){if(i=l[t],r=!1,"[object Object]"!==J.call(i))return!1;for(o in i)if(H.call(i,o)){if(r)return!1;r=!0}if(!r)return!1;if(-1!==a.indexOf(o))return!1;a.push(o)}return!0},construct:function(e){return null!==e?e:[]}}),z=Object.prototype.toString,X=new C("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:function(e){if(null===e)return!0;var t,n,i,o,r,a=e;for(r=new Array(a.length),t=0,n=a.length;t<n;t+=1){if(i=a[t],"[object Object]"!==z.call(i))return!1;if(1!==(o=Object.keys(i)).length)return!1;r[t]=[o[0],i[o[0]]]}return!0},construct:function(e){if(null===e)return[];var t,n,i,o,r,a=e;for(r=new Array(a.length),t=0,n=a.length;t<n;t+=1)i=a[t],o=Object.keys(i),r[t]=[o[0],i[o[0]]];return r}}),Q=Object.prototype.hasOwnProperty,ee=new C("tag:yaml.org,2002:set",{kind:"mapping",resolve:function(e){if(null===e)return!0;var t,n=e;for(t in n)if(Q.call(n,t)&&null!==n[t])return!1;return!0},construct:function(e){return null!==e?e:{}}}),te=Y.extend({implicit:[V,W],explicit:[K,Z,X,ee]}),ne=Object.prototype.hasOwnProperty,ie=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,oe=/[\x85\u2028\u2029]/,re=/[,\[\]\{\}]/,ae=/^(?:!|!!|![a-z\-]+!)$/i,le=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function se(e){return Object.prototype.toString.call(e)}function ce(e){return 10===e||13===e}function ue(e){return 9===e||32===e}function pe(e){return 9===e||32===e||10===e||13===e}function fe(e){return 44===e||91===e||93===e||123===e||125===e}function de(e){var t;return 48<=e&&e<=57?e-48:97<=(t=32|e)&&t<=102?t-97+10:-1}function he(e){return 48===e?"\0":97===e?"":98===e?"\b":116===e||9===e?"\t":110===e?"\n":118===e?"\v":102===e?"\f":114===e?"\r":101===e?"":32===e?" ":34===e?'"':47===e?"/":92===e?"\\":78===e?"…":95===e?" ":76===e?"\u2028":80===e?"\u2029":""}function ge(e){return e<=65535?String.fromCharCode(e):String.fromCharCode(55296+(e-65536>>10),56320+(e-65536&1023))}for(var me=new Array(256),ye=new Array(256),be=0;be<256;be++)me[be]=he(be)?1:0,ye[be]=he(be);function ve(e,t){this.input=e,this.filename=t.filename||null,this.schema=t.schema||te,this.onWarning=t.onWarning||null,this.legacy=t.legacy||!1,this.json=t.json||!1,this.listener=t.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function Ae(e,t){var n={name:e.filename,buffer:e.input.slice(0,-1),position:e.position,line:e.line,column:e.position-e.lineStart};return n.snippet=function(e,t){if(t=Object.create(t||null),!e.buffer)return null;t.maxLength||(t.maxLength=79),"number"!=typeof t.indent&&(t.indent=1),"number"!=typeof t.linesBefore&&(t.linesBefore=3),"number"!=typeof t.linesAfter&&(t.linesAfter=2);for(var n,i=/\r?\n|\r|\0/g,o=[0],r=[],a=-1;n=i.exec(e.buffer);)r.push(n.index),o.push(n.index+n[0].length),e.position<=n.index&&a<0&&(a=o.length-2);a<0&&(a=o.length-1);var l,s,c="",u=Math.min(e.line+t.linesAfter,r.length).toString().length,p=t.maxLength-(t.indent+u+3);for(l=1;l<=t.linesBefore&&!(a-l<0);l++)s=A(e.buffer,o[a-l],r[a-l],e.position-(o[a]-o[a-l]),p),c=m.repeat(" ",t.indent)+w((e.line-l+1).toString(),u)+" | "+s.str+"\n"+c;for(s=A(e.buffer,o[a],r[a],e.position,p),c+=m.repeat(" ",t.indent)+w((e.line+1).toString(),u)+" | "+s.str+"\n",c+=m.repeat("-",t.indent+u+3+s.pos)+"^\n",l=1;l<=t.linesAfter&&!(a+l>=r.length);l++)s=A(e.buffer,o[a+l],r[a+l],e.position-(o[a]-o[a+l]),p),c+=m.repeat(" ",t.indent)+w((e.line+l+1).toString(),u)+" | "+s.str+"\n";return c.replace(/\n$/,"")}(n),new v(t,n)}function we(e,t){throw Ae(e,t)}function ke(e,t){e.onWarning&&e.onWarning.call(null,Ae(e,t))}var xe={YAML:function(e,t,n){var i,o,r;null!==e.version&&we(e,"duplication of %YAML directive"),1!==n.length&&we(e,"YAML directive accepts exactly one argument"),null===(i=/^([0-9]+)\.([0-9]+)$/.exec(n[0]))&&we(e,"ill-formed argument of the YAML directive"),o=parseInt(i[1],10),r=parseInt(i[2],10),1!==o&&we(e,"unacceptable YAML version of the document"),e.version=n[0],e.checkLineBreaks=r<2,1!==r&&2!==r&&ke(e,"unsupported YAML version of the document")},TAG:function(e,t,n){var i,o;2!==n.length&&we(e,"TAG directive accepts exactly two arguments"),i=n[0],o=n[1],ae.test(i)||we(e,"ill-formed tag handle (first argument) of the TAG directive"),ne.call(e.tagMap,i)&&we(e,'there is a previously declared suffix for "'+i+'" tag handle'),le.test(o)||we(e,"ill-formed tag prefix (second argument) of the TAG directive");try{o=decodeURIComponent(o)}catch(t){we(e,"tag prefix is malformed: "+o)}e.tagMap[i]=o}};function Ce(e,t,n,i){var o,r,a,l;if(t<n){if(l=e.input.slice(t,n),i)for(o=0,r=l.length;o<r;o+=1)9===(a=l.charCodeAt(o))||32<=a&&a<=1114111||we(e,"expected valid JSON character");else ie.test(l)&&we(e,"the stream contains non-printable characters");e.result+=l}}function Oe(e,t,n,i){var o,r,a,l;for(m.isObject(n)||we(e,"cannot merge mappings; the provided source object is unacceptable"),a=0,l=(o=Object.keys(n)).length;a<l;a+=1)r=o[a],ne.call(t,r)||(t[r]=n[r],i[r]=!0)}function Se(e,t,n,i,o,r,a,l,s){var c,u;if(Array.isArray(o))for(c=0,u=(o=Array.prototype.slice.call(o)).length;c<u;c+=1)Array.isArray(o[c])&&we(e,"nested arrays are not supported inside keys"),"object"==typeof o&&"[object Object]"===se(o[c])&&(o[c]="[object Object]");if("object"==typeof o&&"[object Object]"===se(o)&&(o="[object Object]"),o=String(o),null===t&&(t={}),"tag:yaml.org,2002:merge"===i)if(Array.isArray(r))for(c=0,u=r.length;c<u;c+=1)Oe(e,t,r[c],n);else Oe(e,t,r,n);else e.json||ne.call(n,o)||!ne.call(t,o)||(e.line=a||e.line,e.lineStart=l||e.lineStart,e.position=s||e.position,we(e,"duplicated mapping key")),"__proto__"===o?Object.defineProperty(t,o,{configurable:!0,enumerable:!0,writable:!0,value:r}):t[o]=r,delete n[o];return t}function je(e){var t;10===(t=e.input.charCodeAt(e.position))?e.position++:13===t?(e.position++,10===e.input.charCodeAt(e.position)&&e.position++):we(e,"a line break is expected"),e.line+=1,e.lineStart=e.position,e.firstTabInLine=-1}function Ie(e,t,n){for(var i=0,o=e.input.charCodeAt(e.position);0!==o;){for(;ue(o);)9===o&&-1===e.firstTabInLine&&(e.firstTabInLine=e.position),o=e.input.charCodeAt(++e.position);if(t&&35===o)do{o=e.input.charCodeAt(++e.position)}while(10!==o&&13!==o&&0!==o);if(!ce(o))break;for(je(e),o=e.input.charCodeAt(e.position),i++,e.lineIndent=0;32===o;)e.lineIndent++,o=e.input.charCodeAt(++e.position)}return-1!==n&&0!==i&&e.lineIndent<n&&ke(e,"deficient indentation"),i}function _e(e){var t,n=e.position;return!(45!==(t=e.input.charCodeAt(n))&&46!==t||t!==e.input.charCodeAt(n+1)||t!==e.input.charCodeAt(n+2)||(n+=3,0!==(t=e.input.charCodeAt(n))&&!pe(t)))}function Te(e,t){1===t?e.result+=" ":t>1&&(e.result+=m.repeat("\n",t-1))}function Ee(e,t){var n,i,o=e.tag,r=e.anchor,a=[],l=!1;if(-1!==e.firstTabInLine)return!1;for(null!==e.anchor&&(e.anchorMap[e.anchor]=a),i=e.input.charCodeAt(e.position);0!==i&&(-1!==e.firstTabInLine&&(e.position=e.firstTabInLine,we(e,"tab characters must not be used in indentation")),45===i)&&pe(e.input.charCodeAt(e.position+1));)if(l=!0,e.position++,Ie(e,!0,-1)&&e.lineIndent<=t)a.push(null),i=e.input.charCodeAt(e.position);else if(n=e.line,Fe(e,t,3,!1,!0),a.push(e.result),Ie(e,!0,-1),i=e.input.charCodeAt(e.position),(e.line===n||e.lineIndent>t)&&0!==i)we(e,"bad indentation of a sequence entry");else if(e.lineIndent<t)break;return!!l&&(e.tag=o,e.anchor=r,e.kind="sequence",e.result=a,!0)}function Ne(e){var t,n,i,o,r=!1,a=!1;if(33!==(o=e.input.charCodeAt(e.position)))return!1;if(null!==e.tag&&we(e,"duplication of a tag property"),60===(o=e.input.charCodeAt(++e.position))?(r=!0,o=e.input.charCodeAt(++e.position)):33===o?(a=!0,n="!!",o=e.input.charCodeAt(++e.position)):n="!",t=e.position,r){do{o=e.input.charCodeAt(++e.position)}while(0!==o&&62!==o);e.position<e.length?(i=e.input.slice(t,e.position),o=e.input.charCodeAt(++e.position)):we(e,"unexpected end of the stream within a verbatim tag")}else{for(;0!==o&&!pe(o);)33===o&&(a?we(e,"tag suffix cannot contain exclamation marks"):(n=e.input.slice(t-1,e.position+1),ae.test(n)||we(e,"named tag handle cannot contain such characters"),a=!0,t=e.position+1)),o=e.input.charCodeAt(++e.position);i=e.input.slice(t,e.position),re.test(i)&&we(e,"tag suffix cannot contain flow indicator characters")}i&&!le.test(i)&&we(e,"tag name cannot contain such characters: "+i);try{i=decodeURIComponent(i)}catch(t){we(e,"tag name is malformed: "+i)}return r?e.tag=i:ne.call(e.tagMap,n)?e.tag=e.tagMap[n]+i:"!"===n?e.tag="!"+i:"!!"===n?e.tag="tag:yaml.org,2002:"+i:we(e,'undeclared tag handle "'+n+'"'),!0}function Le(e){var t,n;if(38!==(n=e.input.charCodeAt(e.position)))return!1;for(null!==e.anchor&&we(e,"duplication of an anchor property"),n=e.input.charCodeAt(++e.position),t=e.position;0!==n&&!pe(n)&&!fe(n);)n=e.input.charCodeAt(++e.position);return e.position===t&&we(e,"name of an anchor node must contain at least one character"),e.anchor=e.input.slice(t,e.position),!0}function Fe(e,t,n,i,o){var r,a,l,s,c,u,p,f,d,h=1,g=!1,y=!1;if(null!==e.listener&&e.listener("open",e),e.tag=null,e.anchor=null,e.kind=null,e.result=null,r=a=l=4===n||3===n,i&&Ie(e,!0,-1)&&(g=!0,e.lineIndent>t?h=1:e.lineIndent===t?h=0:e.lineIndent<t&&(h=-1)),1===h)for(;Ne(e)||Le(e);)Ie(e,!0,-1)?(g=!0,l=r,e.lineIndent>t?h=1:e.lineIndent===t?h=0:e.lineIndent<t&&(h=-1)):l=!1;if(l&&(l=g||o),1!==h&&4!==n||(f=1===n||2===n?t:t+1,d=e.position-e.lineStart,1===h?l&&(Ee(e,d)||function(e,t,n){var i,o,r,a,l,s,c,u=e.tag,p=e.anchor,f={},d=Object.create(null),h=null,g=null,m=null,y=!1,b=!1;if(-1!==e.firstTabInLine)return!1;for(null!==e.anchor&&(e.anchorMap[e.anchor]=f),c=e.input.charCodeAt(e.position);0!==c;){if(y||-1===e.firstTabInLine||(e.position=e.firstTabInLine,we(e,"tab characters must not be used in indentation")),i=e.input.charCodeAt(e.position+1),r=e.line,63!==c&&58!==c||!pe(i)){if(a=e.line,l=e.lineStart,s=e.position,!Fe(e,n,2,!1,!0))break;if(e.line===r){for(c=e.input.charCodeAt(e.position);ue(c);)c=e.input.charCodeAt(++e.position);if(58===c)pe(c=e.input.charCodeAt(++e.position))||we(e,"a whitespace character is expected after the key-value separator within a block mapping"),y&&(Se(e,f,d,h,g,null,a,l,s),h=g=m=null),b=!0,y=!1,o=!1,h=e.tag,g=e.result;else{if(!b)return e.tag=u,e.anchor=p,!0;we(e,"can not read an implicit mapping pair; a colon is missed")}}else{if(!b)return e.tag=u,e.anchor=p,!0;we(e,"can not read a block mapping entry; a multiline key may not be an implicit key")}}else 63===c?(y&&(Se(e,f,d,h,g,null,a,l,s),h=g=m=null),b=!0,y=!0,o=!0):y?(y=!1,o=!0):we(e,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),e.position+=1,c=i;if((e.line===r||e.lineIndent>t)&&(y&&(a=e.line,l=e.lineStart,s=e.position),Fe(e,t,4,!0,o)&&(y?g=e.result:m=e.result),y||(Se(e,f,d,h,g,m,a,l,s),h=g=m=null),Ie(e,!0,-1),c=e.input.charCodeAt(e.position)),(e.line===r||e.lineIndent>t)&&0!==c)we(e,"bad indentation of a mapping entry");else if(e.lineIndent<t)break}return y&&Se(e,f,d,h,g,null,a,l,s),b&&(e.tag=u,e.anchor=p,e.kind="mapping",e.result=f),b}(e,d,f))||function(e,t){var n,i,o,r,a,l,s,c,u,p,f,d,h=!0,g=e.tag,m=e.anchor,y=Object.create(null);if(91===(d=e.input.charCodeAt(e.position)))a=93,c=!1,r=[];else{if(123!==d)return!1;a=125,c=!0,r={}}for(null!==e.anchor&&(e.anchorMap[e.anchor]=r),d=e.input.charCodeAt(++e.position);0!==d;){if(Ie(e,!0,t),(d=e.input.charCodeAt(e.position))===a)return e.position++,e.tag=g,e.anchor=m,e.kind=c?"mapping":"sequence",e.result=r,!0;h?44===d&&we(e,"expected the node content, but found ','"):we(e,"missed comma between flow collection entries"),f=null,l=s=!1,63===d&&pe(e.input.charCodeAt(e.position+1))&&(l=s=!0,e.position++,Ie(e,!0,t)),n=e.line,i=e.lineStart,o=e.position,Fe(e,t,1,!1,!0),p=e.tag,u=e.result,Ie(e,!0,t),d=e.input.charCodeAt(e.position),!s&&e.line!==n||58!==d||(l=!0,d=e.input.charCodeAt(++e.position),Ie(e,!0,t),Fe(e,t,1,!1,!0),f=e.result),c?Se(e,r,y,p,u,f,n,i,o):l?r.push(Se(e,null,y,p,u,f,n,i,o)):r.push(u),Ie(e,!0,t),44===(d=e.input.charCodeAt(e.position))?(h=!0,d=e.input.charCodeAt(++e.position)):h=!1}we(e,"unexpected end of the stream within a flow collection")}(e,f)?y=!0:(a&&function(e,t){var n,i,o,r,a,l=1,s=!1,c=!1,u=t,p=0,f=!1;if(124===(r=e.input.charCodeAt(e.position)))i=!1;else{if(62!==r)return!1;i=!0}for(e.kind="scalar",e.result="";0!==r;)if(43===(r=e.input.charCodeAt(++e.position))||45===r)1===l?l=43===r?3:2:we(e,"repeat of a chomping mode identifier");else{if(!((o=48<=(a=r)&&a<=57?a-48:-1)>=0))break;0===o?we(e,"bad explicit indentation width of a block scalar; it cannot be less than one"):c?we(e,"repeat of an indentation width identifier"):(u=t+o-1,c=!0)}if(ue(r)){do{r=e.input.charCodeAt(++e.position)}while(ue(r));if(35===r)do{r=e.input.charCodeAt(++e.position)}while(!ce(r)&&0!==r)}for(;0!==r;){for(je(e),e.lineIndent=0,r=e.input.charCodeAt(e.position);(!c||e.lineIndent<u)&&32===r;)e.lineIndent++,r=e.input.charCodeAt(++e.position);if(!c&&e.lineIndent>u&&(u=e.lineIndent),ce(r))p++;else{if(e.lineIndent<u){3===l?e.result+=m.repeat("\n",s?1+p:p):1===l&&s&&(e.result+="\n");break}for(i?ue(r)?(f=!0,e.result+=m.repeat("\n",s?1+p:p)):f?(f=!1,e.result+=m.repeat("\n",p+1)):0===p?s&&(e.result+=" "):e.result+=m.repeat("\n",p):e.result+=m.repeat("\n",s?1+p:p),s=!0,c=!0,p=0,n=e.position;!ce(r)&&0!==r;)r=e.input.charCodeAt(++e.position);Ce(e,n,e.position,!1)}}return!0}(e,f)||function(e,t){var n,i,o;if(39!==(n=e.input.charCodeAt(e.position)))return!1;for(e.kind="scalar",e.result="",e.position++,i=o=e.position;0!==(n=e.input.charCodeAt(e.position));)if(39===n){if(Ce(e,i,e.position,!0),39!==(n=e.input.charCodeAt(++e.position)))return!0;i=e.position,e.position++,o=e.position}else ce(n)?(Ce(e,i,o,!0),Te(e,Ie(e,!1,t)),i=o=e.position):e.position===e.lineStart&&_e(e)?we(e,"unexpected end of the document within a single quoted scalar"):(e.position++,o=e.position);we(e,"unexpected end of the stream within a single quoted scalar")}(e,f)||function(e,t){var n,i,o,r,a,l,s;if(34!==(l=e.input.charCodeAt(e.position)))return!1;for(e.kind="scalar",e.result="",e.position++,n=i=e.position;0!==(l=e.input.charCodeAt(e.position));){if(34===l)return Ce(e,n,e.position,!0),e.position++,!0;if(92===l){if(Ce(e,n,e.position,!0),ce(l=e.input.charCodeAt(++e.position)))Ie(e,!1,t);else if(l<256&&me[l])e.result+=ye[l],e.position++;else if((a=120===(s=l)?2:117===s?4:85===s?8:0)>0){for(o=a,r=0;o>0;o--)(a=de(l=e.input.charCodeAt(++e.position)))>=0?r=(r<<4)+a:we(e,"expected hexadecimal character");e.result+=ge(r),e.position++}else we(e,"unknown escape sequence");n=i=e.position}else ce(l)?(Ce(e,n,i,!0),Te(e,Ie(e,!1,t)),n=i=e.position):e.position===e.lineStart&&_e(e)?we(e,"unexpected end of the document within a double quoted scalar"):(e.position++,i=e.position)}we(e,"unexpected end of the stream within a double quoted scalar")}(e,f)?y=!0:function(e){var t,n,i;if(42!==(i=e.input.charCodeAt(e.position)))return!1;for(i=e.input.charCodeAt(++e.position),t=e.position;0!==i&&!pe(i)&&!fe(i);)i=e.input.charCodeAt(++e.position);return e.position===t&&we(e,"name of an alias node must contain at least one character"),n=e.input.slice(t,e.position),ne.call(e.anchorMap,n)||we(e,'unidentified alias "'+n+'"'),e.result=e.anchorMap[n],Ie(e,!0,-1),!0}(e)?(y=!0,null===e.tag&&null===e.anchor||we(e,"alias node should not have any properties")):function(e,t,n){var i,o,r,a,l,s,c,u,p=e.kind,f=e.result;if(pe(u=e.input.charCodeAt(e.position))||fe(u)||35===u||38===u||42===u||33===u||124===u||62===u||39===u||34===u||37===u||64===u||96===u)return!1;if((63===u||45===u)&&(pe(i=e.input.charCodeAt(e.position+1))||n&&fe(i)))return!1;for(e.kind="scalar",e.result="",o=r=e.position,a=!1;0!==u;){if(58===u){if(pe(i=e.input.charCodeAt(e.position+1))||n&&fe(i))break}else if(35===u){if(pe(e.input.charCodeAt(e.position-1)))break}else{if(e.position===e.lineStart&&_e(e)||n&&fe(u))break;if(ce(u)){if(l=e.line,s=e.lineStart,c=e.lineIndent,Ie(e,!1,-1),e.lineIndent>=t){a=!0,u=e.input.charCodeAt(e.position);continue}e.position=r,e.line=l,e.lineStart=s,e.lineIndent=c;break}}a&&(Ce(e,o,r,!1),Te(e,e.line-l),o=r=e.position,a=!1),ue(u)||(r=e.position+1),u=e.input.charCodeAt(++e.position)}return Ce(e,o,r,!1),!!e.result||(e.kind=p,e.result=f,!1)}(e,f,1===n)&&(y=!0,null===e.tag&&(e.tag="?")),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):0===h&&(y=l&&Ee(e,d))),null===e.tag)null!==e.anchor&&(e.anchorMap[e.anchor]=e.result);else if("?"===e.tag){for(null!==e.result&&"scalar"!==e.kind&&we(e,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+e.kind+'"'),s=0,c=e.implicitTypes.length;s<c;s+=1)if((p=e.implicitTypes[s]).resolve(e.result)){e.result=p.construct(e.result),e.tag=p.tag,null!==e.anchor&&(e.anchorMap[e.anchor]=e.result);break}}else if("!"!==e.tag){if(ne.call(e.typeMap[e.kind||"fallback"],e.tag))p=e.typeMap[e.kind||"fallback"][e.tag];else for(p=null,s=0,c=(u=e.typeMap.multi[e.kind||"fallback"]).length;s<c;s+=1)if(e.tag.slice(0,u[s].tag.length)===u[s].tag){p=u[s];break}p||we(e,"unknown tag !<"+e.tag+">"),null!==e.result&&p.kind!==e.kind&&we(e,"unacceptable node kind for !<"+e.tag+'> tag; it should be "'+p.kind+'", not "'+e.kind+'"'),p.resolve(e.result,e.tag)?(e.result=p.construct(e.result,e.tag),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):we(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")}return null!==e.listener&&e.listener("close",e),null!==e.tag||null!==e.anchor||y}function Me(e){var t,n,i,o,r=e.position,a=!1;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap=Object.create(null),e.anchorMap=Object.create(null);0!==(o=e.input.charCodeAt(e.position))&&(Ie(e,!0,-1),o=e.input.charCodeAt(e.position),!(e.lineIndent>0||37!==o));){for(a=!0,o=e.input.charCodeAt(++e.position),t=e.position;0!==o&&!pe(o);)o=e.input.charCodeAt(++e.position);for(i=[],(n=e.input.slice(t,e.position)).length<1&&we(e,"directive name must not be less than one character in length");0!==o;){for(;ue(o);)o=e.input.charCodeAt(++e.position);if(35===o){do{o=e.input.charCodeAt(++e.position)}while(0!==o&&!ce(o));break}if(ce(o))break;for(t=e.position;0!==o&&!pe(o);)o=e.input.charCodeAt(++e.position);i.push(e.input.slice(t,e.position))}0!==o&&je(e),ne.call(xe,n)?xe[n](e,n,i):ke(e,'unknown document directive "'+n+'"')}Ie(e,!0,-1),0===e.lineIndent&&45===e.input.charCodeAt(e.position)&&45===e.input.charCodeAt(e.position+1)&&45===e.input.charCodeAt(e.position+2)?(e.position+=3,Ie(e,!0,-1)):a&&we(e,"directives end mark is expected"),Fe(e,e.lineIndent-1,4,!1,!0),Ie(e,!0,-1),e.checkLineBreaks&&oe.test(e.input.slice(r,e.position))&&ke(e,"non-ASCII line breaks are interpreted as content"),e.documents.push(e.result),e.position===e.lineStart&&_e(e)?46===e.input.charCodeAt(e.position)&&(e.position+=3,Ie(e,!0,-1)):e.position<e.length-1&&we(e,"end of the stream or a document separator is expected")}function $e(e,t){t=t||{},0!==(e=String(e)).length&&(10!==e.charCodeAt(e.length-1)&&13!==e.charCodeAt(e.length-1)&&(e+="\n"),65279===e.charCodeAt(0)&&(e=e.slice(1)));var n=new ve(e,t),i=e.indexOf("\0");for(-1!==i&&(n.position=i,we(n,"null byte is not allowed in input")),n.input+="\0";32===n.input.charCodeAt(n.position);)n.lineIndent+=1,n.position+=1;for(;n.position<n.length-1;)Me(n);return n.documents}var De={loadAll:function(e,t,n){null!==t&&"object"==typeof t&&void 0===n&&(n=t,t=null);var i=$e(e,n);if("function"!=typeof t)return i;for(var o=0,r=i.length;o<r;o+=1)t(i[o])},load:function(e,t){var n=$e(e,t);if(0!==n.length){if(1===n.length)return n[0];throw new v("expected a single document in the stream, but found more")}}},Re=Object.prototype.toString,Ue=Object.prototype.hasOwnProperty,qe=65279,Ye={0:"\\0",7:"\\a",8:"\\b",9:"\\t",10:"\\n",11:"\\v",12:"\\f",13:"\\r",27:"\\e",34:'\\"',92:"\\\\",133:"\\N",160:"\\_",8232:"\\L",8233:"\\P"},Be=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],Pe=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function Ve(e){var t,n,i;if(t=e.toString(16).toUpperCase(),e<=255)n="x",i=2;else if(e<=65535)n="u",i=4;else{if(!(e<=4294967295))throw new v("code point within a string may not be greater than 0xFFFFFFFF");n="U",i=8}return"\\"+n+m.repeat("0",i-t.length)+t}function We(e){this.schema=e.schema||te,this.indent=Math.max(1,e.indent||2),this.noArrayIndent=e.noArrayIndent||!1,this.skipInvalid=e.skipInvalid||!1,this.flowLevel=m.isNothing(e.flowLevel)?-1:e.flowLevel,this.styleMap=function(e,t){var n,i,o,r,a,l,s;if(null===t)return{};for(n={},o=0,r=(i=Object.keys(t)).length;o<r;o+=1)a=i[o],l=String(t[a]),"!!"===a.slice(0,2)&&(a="tag:yaml.org,2002:"+a.slice(2)),(s=e.compiledTypeMap.fallback[a])&&Ue.call(s.styleAliases,l)&&(l=s.styleAliases[l]),n[a]=l;return n}(this.schema,e.styles||null),this.sortKeys=e.sortKeys||!1,this.lineWidth=e.lineWidth||80,this.noRefs=e.noRefs||!1,this.noCompatMode=e.noCompatMode||!1,this.condenseFlow=e.condenseFlow||!1,this.quotingType='"'===e.quotingType?2:1,this.forceQuotes=e.forceQuotes||!1,this.replacer="function"==typeof e.replacer?e.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function Ge(e,t){for(var n,i=m.repeat(" ",t),o=0,r=-1,a="",l=e.length;o<l;)-1===(r=e.indexOf("\n",o))?(n=e.slice(o),o=l):(n=e.slice(o,r+1),o=r+1),n.length&&"\n"!==n&&(a+=i),a+=n;return a}function Ke(e,t){return"\n"+m.repeat(" ",e.indent*t)}function He(e){return 32===e||9===e}function Je(e){return 32<=e&&e<=126||161<=e&&e<=55295&&8232!==e&&8233!==e||57344<=e&&e<=65533&&e!==qe||65536<=e&&e<=1114111}function Ze(e){return Je(e)&&e!==qe&&13!==e&&10!==e}function ze(e,t,n){var i=Ze(e),o=i&&!He(e);return(n?i:i&&44!==e&&91!==e&&93!==e&&123!==e&&125!==e)&&35!==e&&!(58===t&&!o)||Ze(t)&&!He(t)&&35===e||58===t&&o}function Xe(e,t){var n,i=e.charCodeAt(t);return i>=55296&&i<=56319&&t+1<e.length&&(n=e.charCodeAt(t+1))>=56320&&n<=57343?1024*(i-55296)+n-56320+65536:i}function Qe(e){return/^\n* /.test(e)}function et(e,t,n,i,o){e.dump=function(){if(0===t.length)return 2===e.quotingType?'""':"''";if(!e.noCompatMode&&(-1!==Be.indexOf(t)||Pe.test(t)))return 2===e.quotingType?'"'+t+'"':"'"+t+"'";var r=e.indent*Math.max(1,n),a=-1===e.lineWidth?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-r),l=i||e.flowLevel>-1&&n>=e.flowLevel;switch(function(e,t,n,i,o,r,a,l){var s,c,u=0,p=null,f=!1,d=!1,h=-1!==i,g=-1,m=Je(c=Xe(e,0))&&c!==qe&&!He(c)&&45!==c&&63!==c&&58!==c&&44!==c&&91!==c&&93!==c&&123!==c&&125!==c&&35!==c&&38!==c&&42!==c&&33!==c&&124!==c&&61!==c&&62!==c&&39!==c&&34!==c&&37!==c&&64!==c&&96!==c&&function(e){return!He(e)&&58!==e}(Xe(e,e.length-1));if(t||a)for(s=0;s<e.length;u>=65536?s+=2:s++){if(!Je(u=Xe(e,s)))return 5;m=m&&ze(u,p,l),p=u}else{for(s=0;s<e.length;u>=65536?s+=2:s++){if(10===(u=Xe(e,s)))f=!0,h&&(d=d||s-g-1>i&&" "!==e[g+1],g=s);else if(!Je(u))return 5;m=m&&ze(u,p,l),p=u}d=d||h&&s-g-1>i&&" "!==e[g+1]}return f||d?n>9&&Qe(e)?5:a?2===r?5:2:d?4:3:!m||a||o(e)?2===r?5:2:1}(t,l,e.indent,a,(function(t){return function(e,t){var n,i;for(n=0,i=e.implicitTypes.length;n<i;n+=1)if(e.implicitTypes[n].resolve(t))return!0;return!1}(e,t)}),e.quotingType,e.forceQuotes&&!i,o)){case 1:return t;case 2:return"'"+t.replace(/'/g,"''")+"'";case 3:return"|"+tt(t,e.indent)+nt(Ge(t,r));case 4:return">"+tt(t,e.indent)+nt(Ge(function(e,t){for(var n,i,o,r=/(\n+)([^\n]*)/g,a=(o=-1!==(o=e.indexOf("\n"))?o:e.length,r.lastIndex=o,it(e.slice(0,o),t)),l="\n"===e[0]||" "===e[0];i=r.exec(e);){var s=i[1],c=i[2];n=" "===c[0],a+=s+(l||n||""===c?"":"\n")+it(c,t),l=n}return a}(t,a),r));case 5:return'"'+function(e){for(var t,n="",i=0,o=0;o<e.length;i>=65536?o+=2:o++)i=Xe(e,o),!(t=Ye[i])&&Je(i)?(n+=e[o],i>=65536&&(n+=e[o+1])):n+=t||Ve(i);return n}(t)+'"';default:throw new v("impossible error: invalid scalar style")}}()}function tt(e,t){var n=Qe(e)?String(t):"",i="\n"===e[e.length-1];return n+(!i||"\n"!==e[e.length-2]&&"\n"!==e?i?"":"-":"+")+"\n"}function nt(e){return"\n"===e[e.length-1]?e.slice(0,-1):e}function it(e,t){if(""===e||" "===e[0])return e;for(var n,i,o=/ [^ ]/g,r=0,a=0,l=0,s="";n=o.exec(e);)(l=n.index)-r>t&&(i=a>r?a:l,s+="\n"+e.slice(r,i),r=i+1),a=l;return s+="\n",e.length-r>t&&a>r?s+=e.slice(r,a)+"\n"+e.slice(a+1):s+=e.slice(r),s.slice(1)}function ot(e,t,n,i){var o,r,a,l="",s=e.tag;for(o=0,r=n.length;o<r;o+=1)a=n[o],e.replacer&&(a=e.replacer.call(n,String(o),a)),(at(e,t+1,a,!0,!0,!1,!0)||void 0===a&&at(e,t+1,null,!0,!0,!1,!0))&&(i&&""===l||(l+=Ke(e,t)),e.dump&&10===e.dump.charCodeAt(0)?l+="-":l+="- ",l+=e.dump);e.tag=s,e.dump=l||"[]"}function rt(e,t,n){var i,o,r,a,l,s;for(r=0,a=(o=n?e.explicitTypes:e.implicitTypes).length;r<a;r+=1)if(((l=o[r]).instanceOf||l.predicate)&&(!l.instanceOf||"object"==typeof t&&t instanceof l.instanceOf)&&(!l.predicate||l.predicate(t))){if(n?l.multi&&l.representName?e.tag=l.representName(t):e.tag=l.tag:e.tag="?",l.represent){if(s=e.styleMap[l.tag]||l.defaultStyle,"[object Function]"===Re.call(l.represent))i=l.represent(t,s);else{if(!Ue.call(l.represent,s))throw new v("!<"+l.tag+'> tag resolver accepts not "'+s+'" style');i=l.represent[s](t,s)}e.dump=i}return!0}return!1}function at(e,t,n,i,o,r,a){e.tag=null,e.dump=n,rt(e,n,!1)||rt(e,n,!0);var l,s=Re.call(e.dump),c=i;i&&(i=e.flowLevel<0||e.flowLevel>t);var u,p,f="[object Object]"===s||"[object Array]"===s;if(f&&(p=-1!==(u=e.duplicates.indexOf(n))),(null!==e.tag&&"?"!==e.tag||p||2!==e.indent&&t>0)&&(o=!1),p&&e.usedDuplicates[u])e.dump="*ref_"+u;else{if(f&&p&&!e.usedDuplicates[u]&&(e.usedDuplicates[u]=!0),"[object Object]"===s)i&&0!==Object.keys(e.dump).length?(function(e,t,n,i){var o,r,a,l,s,c,u="",p=e.tag,f=Object.keys(n);if(!0===e.sortKeys)f.sort();else if("function"==typeof e.sortKeys)f.sort(e.sortKeys);else if(e.sortKeys)throw new v("sortKeys must be a boolean or a function");for(o=0,r=f.length;o<r;o+=1)c="",i&&""===u||(c+=Ke(e,t)),l=n[a=f[o]],e.replacer&&(l=e.replacer.call(n,a,l)),at(e,t+1,a,!0,!0,!0)&&((s=null!==e.tag&&"?"!==e.tag||e.dump&&e.dump.length>1024)&&(e.dump&&10===e.dump.charCodeAt(0)?c+="?":c+="? "),c+=e.dump,s&&(c+=Ke(e,t)),at(e,t+1,l,!0,s)&&(e.dump&&10===e.dump.charCodeAt(0)?c+=":":c+=": ",u+=c+=e.dump));e.tag=p,e.dump=u||"{}"}(e,t,e.dump,o),p&&(e.dump="&ref_"+u+e.dump)):(function(e,t,n){var i,o,r,a,l,s="",c=e.tag,u=Object.keys(n);for(i=0,o=u.length;i<o;i+=1)l="",""!==s&&(l+=", "),e.condenseFlow&&(l+='"'),a=n[r=u[i]],e.replacer&&(a=e.replacer.call(n,r,a)),at(e,t,r,!1,!1)&&(e.dump.length>1024&&(l+="? "),l+=e.dump+(e.condenseFlow?'"':"")+":"+(e.condenseFlow?"":" "),at(e,t,a,!1,!1)&&(s+=l+=e.dump));e.tag=c,e.dump="{"+s+"}"}(e,t,e.dump),p&&(e.dump="&ref_"+u+" "+e.dump));else if("[object Array]"===s)i&&0!==e.dump.length?(e.noArrayIndent&&!a&&t>0?ot(e,t-1,e.dump,o):ot(e,t,e.dump,o),p&&(e.dump="&ref_"+u+e.dump)):(function(e,t,n){var i,o,r,a="",l=e.tag;for(i=0,o=n.length;i<o;i+=1)r=n[i],e.replacer&&(r=e.replacer.call(n,String(i),r)),(at(e,t,r,!1,!1)||void 0===r&&at(e,t,null,!1,!1))&&(""!==a&&(a+=","+(e.condenseFlow?"":" ")),a+=e.dump);e.tag=l,e.dump="["+a+"]"}(e,t,e.dump),p&&(e.dump="&ref_"+u+" "+e.dump));else{if("[object String]"!==s){if("[object Undefined]"===s)return!1;if(e.skipInvalid)return!1;throw new v("unacceptable kind of an object to dump "+s)}"?"!==e.tag&&et(e,e.dump,t,r,c)}null!==e.tag&&"?"!==e.tag&&(l=encodeURI("!"===e.tag[0]?e.tag.slice(1):e.tag).replace(/!/g,"%21"),l="!"===e.tag[0]?"!"+l:"tag:yaml.org,2002:"===l.slice(0,18)?"!!"+l.slice(18):"!<"+l+">",e.dump=l+" "+e.dump)}return!0}function lt(e,t){var n,i,o=[],r=[];for(st(e,o,r),n=0,i=r.length;n<i;n+=1)t.duplicates.push(o[r[n]]);t.usedDuplicates=new Array(i)}function st(e,t,n){var i,o,r;if(null!==e&&"object"==typeof e)if(-1!==(o=t.indexOf(e)))-1===n.indexOf(o)&&n.push(o);else if(t.push(e),Array.isArray(e))for(o=0,r=e.length;o<r;o+=1)st(e[o],t,n);else for(o=0,r=(i=Object.keys(e)).length;o<r;o+=1)st(e[i[o]],t,n)}function ct(e,t){return function(){throw new Error("Function yaml."+e+" is removed in js-yaml 4. Use yaml."+t+" instead, which is now safe by default.")}}const ut={Type:C,Schema:j,FAILSAFE_SCHEMA:E,JSON_SCHEMA:q,CORE_SCHEMA:Y,DEFAULT_SCHEMA:te,load:De.load,loadAll:De.loadAll,dump:function(e,t){var n=new We(t=t||{});n.noRefs||lt(e,n);var i=e;return n.replacer&&(i=n.replacer.call({"":i},"",i)),at(n,0,i,!0,!0)?n.dump+"\n":""},YAMLException:v,types:{binary:K,float:U,map:T,null:N,pairs:X,set:ee,timestamp:V,bool:L,int:$,merge:W,omap:Z,seq:_,str:I},safeLoad:ct("safeLoad","load"),safeLoadAll:ct("safeLoadAll","loadAll"),safeDump:ct("safeDump","dump")};var pt;function ft(e,t){return"function"==typeof t?t.toString():["",null].includes(t)||"object"==typeof t&&(0===t.length||0===Object.keys(t).length)?void 0:t}function dt(e){const t={get(e,t,n){const i=Reflect.get(e,t,n);return"object"==typeof i&&null!==i?Array.isArray(i)?i.map((e=>dt(e))):dt(i):`{${t}}`}};return Array.isArray(e)?e.map((e=>dt(e))):new Proxy(e,t)}function ht(e){let t;if("object"==typeof e.state){const n=dt(e.state);t=e.view(n)}else t=e.view(e.state);return t}function gt(e){const t=window.open("","_apprun_debug","toolbar=0");t.document.write(`<html>\n <title>AppRun Analyzer | ${document.location.href}</title>\n <style>\n body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI" }\n li { margin-left: 80px; }\n </style>\n <body>\n <div id="main">${e}</div>\n <\/script>\n </body>\n </html>`),t.document.close()}i.A.debug=!0,window["_apprun-help"]=["",()=>{Object.keys(window).forEach((e=>{e.startsWith("_apprun-")&&("_apprun-help"===e?console.log("AppRun Commands:"):console.log(`* ${e.substring(8)}: ${window[e][0]}`))}))}];const mt=()=>{const e={components:{}};i.A.run("get-components",e);const{components:t}=e;return t};let yt=Number(null===(pt=null===window||void 0===window?void 0:window.localStorage)||void 0===pt?void 0:pt.getItem("__apprun_debugging__"))||0;if(i.A.on("debug",(e=>{1&yt&&e.event&&console.log(e),2&yt&&e.vdom&&console.log(e)})),window["_apprun-components"]=["components [print]",e=>{(e=>{const t=mt(),n=[];if(t instanceof Map)for(let[e,i]of t){const t="string"==typeof e?document.getElementById(e)||document.querySelector(e):e;n.push({element:t,comps:i})}else Object.keys(t).forEach((e=>{const i="string"==typeof e?document.getElementById(e)||document.querySelector(e):e;n.push({element:i,comps:t[e]})}));if(e){const e=(e=>{const t=({components:e})=>i.A.h("ul",null,e.map((e=>{const t=ht(e),n=e._actions.map((e=>e.name)),o={state:e.state,view:t,actions:n,update:e.update};return i.A.h("li",null,i.A.h("div",null,e.constructor.name),i.A.h("div",null,i.A.h("pre",null,(r=ut.dump(o,{replacer:ft}))?r.toString().replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;"):r)),i.A.h("br",null));var r})));return i.A.h("ul",null,e.map((({element:e,comps:n})=>i.A.h("li",null,i.A.h("div",null,(e=>i.A.h("div",null,e.tagName.toLowerCase(),e.id?"#"+e.id:""," ",e.className&&e.className.split(" ").map((e=>"."+e)).join()))(e)),i.A.h(t,{components:n})))))})(n);gt(l(e))}else n.forEach((({element:e,comps:t})=>console.log(e,t)))})("print"===e)}],window["_apprun-events"]=["events [print]",e=>{(e=>{const t=i.A._events,n={},o=mt(),r=e=>e._actions.forEach((t=>{n[t.name]=n[t.name]||[],n[t.name].push(e)}));if(o instanceof Map)for(let[e,t]of o)t.forEach(r);else Object.keys(o).forEach((e=>o[e].forEach(r)));const a=[];if(Object.keys(n).forEach((e=>{a.push({event:e,components:n[e],global:!!t[e]})})),a.sort(((e,t)=>e.event>t.event?1:-1)).map((e=>e.event)),e){const e=(e=>{const t=({components:e})=>i.A.h("ul",null,e.map((e=>i.A.h("li",null,i.A.h("div",null,e.constructor.name))))),n=({events:e,global:n})=>i.A.h("ul",null,e&&e.filter((e=>e.global===n&&"."!==e.event)).map((({event:e,components:n})=>i.A.h("li",null,i.A.h("div",null,e),i.A.h(t,{components:n})))));return i.A.h("div",null,i.A.h("div",null,"GLOBAL EVENTS"),i.A.h(n,{events:e,global:!0}),i.A.h("div",null,"LOCAL EVENTS"),i.A.h(n,{events:e,global:!1}))})(a);gt(l(e))}else console.log("=== GLOBAL EVENTS ==="),a.filter((e=>e.global&&"."!==e.event)).forEach((({event:e,components:t})=>console.log({event:e},t))),console.log("=== LOCAL EVENTS ==="),a.filter((e=>!e.global&&"."!==e.event)).forEach((({event:e,components:t})=>console.log({event:e},t)))})("print"===e)}],window["_apprun-log"]=["log [event|view] on|off",(e,t)=>{var n;"on"===e?yt=3:"off"===e?yt=0:"event"===e?"on"===t?yt|=1:"off"===t&&(yt&=-2):"view"===e&&("on"===t?yt|=2:"off"===t&&(yt&=-3)),console.log(`* log ${e} ${t||""}`),null===(n=null===window||void 0===window?void 0:window.localStorage)||void 0===n||n.setItem("__apprun_debugging__",`${yt}`)}],window["_apprun-create-event-tests"]=["create-event-tests",()=>(()=>{const e={components:{}};app.run("get-components",e);const{components:t}=e;if(c(""),t instanceof Map)for(let[e,n]of t)n.forEach(f);else Object.keys(t).forEach((e=>{t[e].forEach(f)}));p()})()],window["_apprun-create-state-tests"]=["create-state-tests <start|stop>",e=>{var t;"start"===(t=e)?(h=[],d=!0,console.log("* State logging started.")):"stop"===t?(0!==h.length?(c(""),h.forEach(((e,t)=>{u(` it ('view snapshot: #${t+1}', ()=>{`),u(` const component = new ${e.component.constructor.name}()`),u(` const state = ${JSON.stringify(e.state,void 0,2)};`),u(" const vdom = component['view'](state);"),u(" expect(JSON.stringify(vdom)).toMatchSnapshot();"),u(" })")})),p()):console.log("* No state recorded."),d=!1,h=[],console.log("* State logging stopped.")):console.log("create-state-tests <start|stop>")}],window._apprun=e=>{const[t,...n]=e[0].split(" ").filter((e=>!!e)),i=window[`_apprun-${t}`];i?i[1](...n):window["_apprun-help"][1]()},console.info('AppRun DevTools 2.27: type "_apprun `help`" to list all available commands.'),window.__REDUX_DEVTOOLS_EXTENSION__){let e=!1;const t=window.__REDUX_DEVTOOLS_EXTENSION__.connect();if(t){const n=location.hash||"#";t.send(n,"");const o=[{component:null,state:""}];console.info("Connected to the Redux DevTools"),t.subscribe((t=>{if("START"===t.type)e=!0;else if("STOP"===t.type)e=!1;else if("DISPATCH"===t.type){const e=t.payload.index;if(0===e)i.A.run(n);else{const{component:t,state:n}=o[e];null==t||t.setState(n)}}}));const r=(e,n,i)=>{null!=i&&(o.push({component:e,state:i}),t.send(n,i))};i.A.on("debug",(t=>{if(e&&t.event){const e=t.newState,n={type:t.event,payload:t.p},i=t.component;e instanceof Promise?e.then((e=>r(i,n,e))):r(i,n,e)}}))}}return{}})()));
3
3
  //# sourceMappingURL=apprun-dev-tools.js.map