dothtml 4.8.4 → 5.0.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 (80) hide show
  1. package/{jest.config.js → jest.config.ts} +19 -16
  2. package/lib/arg-callback-obj.d.ts +29 -0
  3. package/lib/built-in-components/nav-link.d.ts +8 -0
  4. package/lib/built-in-components/router.d.ts +57 -0
  5. package/lib/component.d.ts +73 -0
  6. package/lib/dot-component-legacy.d.ts +0 -0
  7. package/lib/dot-document.d.ts +0 -0
  8. package/lib/dot-util.d.ts +13 -0
  9. package/lib/dot.d.ts +5 -0
  10. package/lib/dothtml.d.ts +21 -0
  11. package/lib/dothtml.js +2 -0
  12. package/lib/dothtml.js.LICENSE.txt +1 -0
  13. package/lib/err.d.ts +2 -0
  14. package/lib/event-bus.d.ts +10 -0
  15. package/lib/i-dot.d.ts +674 -0
  16. package/lib/i-dotcss.d.ts +821 -0
  17. package/lib/node-polyfill.d.ts +2 -0
  18. package/lib/observable-array.d.ts +49 -0
  19. package/lib/style-builder.d.ts +3 -0
  20. package/package.json +11 -5
  21. package/readme.md +3 -2
  22. package/src/{arg-callback-obj.js → arg-callback-obj.ts} +18 -6
  23. package/src/built-in-components/nav-link.ts +21 -0
  24. package/src/built-in-components/router.ts +315 -0
  25. package/src/component.ts +369 -0
  26. package/src/dot-component-legacy.ts +79 -0
  27. package/src/dot-document.ts +0 -0
  28. package/src/dot-util.ts +33 -0
  29. package/src/dot.ts +1147 -0
  30. package/src/dothtml.ts +33 -0
  31. package/src/err.ts +22 -0
  32. package/src/event-bus.ts +39 -0
  33. package/src/i-dot.ts +787 -0
  34. package/src/i-dotcss.ts +911 -0
  35. package/src/node-polyfill.ts +11 -0
  36. package/src/{observable-array.js → observable-array.ts} +10 -5
  37. package/src/{style-builder.js → style-builder.ts} +219 -183
  38. package/tsconfig.json +99 -0
  39. package/unittests/advanced-bindings.test.ts +421 -0
  40. package/unittests/{array-evaluation.test.js → array-evaluation.test.ts} +1 -1
  41. package/unittests/{basic-functionality.test.js → basic-functionality.test.ts} +14 -10
  42. package/unittests/class-binding.test.ts +227 -0
  43. package/unittests/component-decorator.-.ts +14 -0
  44. package/unittests/components-data.test.ts +153 -0
  45. package/unittests/components.test.ts +257 -0
  46. package/unittests/computed.test.ts +35 -0
  47. package/unittests/{core.js → core.ts} +5 -2
  48. package/unittests/element-and-attribute-coverage.test.ts +472 -0
  49. package/unittests/hooks.test.ts +67 -0
  50. package/unittests/immutable-if.test.ts +19 -0
  51. package/unittests/input-bindings.test.ts +166 -0
  52. package/unittests/integration.test.ts +5 -0
  53. package/unittests/{iterations.test.js → iterations.test.ts} +5 -5
  54. package/unittests/logic.test.ts +18 -0
  55. package/unittests/refs.test.ts +36 -0
  56. package/unittests/routing.-.ts +56 -0
  57. package/unittests/{scopes.test.js → scopes.test.ts} +5 -5
  58. package/unittests/special-tags.test.ts +39 -0
  59. package/unittests/styles.test.ts +9 -0
  60. package/unittests/{testpage.js → testpage.ts} +2 -0
  61. package/unittests/{wait.test.js → wait.test.ts} +8 -5
  62. package/webpack.config.js +13 -1
  63. package/lib/dothtml.min.js +0 -1
  64. package/src/component.js +0 -305
  65. package/src/err.js +0 -20
  66. package/src/event-bus.js +0 -40
  67. package/src/index.js +0 -1453
  68. package/src/util.js +0 -13
  69. package/unittests/advanced-bindings.test.js +0 -386
  70. package/unittests/class-binding.test.js +0 -53
  71. package/unittests/components-data.test.js +0 -97
  72. package/unittests/components.test.js +0 -151
  73. package/unittests/computed.test.js +0 -36
  74. package/unittests/hooks.test.js +0 -57
  75. package/unittests/immutable-if.test.js +0 -15
  76. package/unittests/input-bindings.test.js +0 -155
  77. package/unittests/integration.test.js +0 -6
  78. package/unittests/logic.test.js +0 -18
  79. package/unittests/routing.-.js +0 -56
  80. package/unittests/special-tags.test.js +0 -32
@@ -62,10 +62,13 @@ module.exports = {
62
62
  // globalTeardown: undefined,
63
63
 
64
64
  // A set of global variables that need to be available in all test environments
65
- // globals: {
66
- // window: {},
67
- // document: {createElement:function(){}}
68
- // },
65
+ "globals": {
66
+ "ts-jest":{
67
+ "tsconfig":{
68
+ "rootDir":"."
69
+ }
70
+ }
71
+ },
69
72
 
70
73
  // The maximum amount of workers used to run your tests. Can be specified as % or a number. E.g. maxWorkers: 10% will use 10% of your CPU amount + 1 as the maximum worker number. maxWorkers: 2 will use a maximum of 2 workers.
71
74
  // maxWorkers: "50%",
@@ -76,14 +79,14 @@ module.exports = {
76
79
  // ],
77
80
 
78
81
  // An array of file extensions your modules use
79
- // moduleFileExtensions: [
80
- // "js",
81
- // "jsx",
82
- // "ts",
83
- // "tsx",
84
- // "json",
85
- // "node"
86
- // ],
82
+ moduleFileExtensions: [
83
+ "ts",
84
+ "js",
85
+ // "jsx",
86
+ // "tsx",
87
+ // "json",
88
+ // "node"
89
+ ],
87
90
 
88
91
  // A map from regular expressions to module names or to arrays of module names that allow to stub out resources with a single module
89
92
  // moduleNameMapper: {},
@@ -98,7 +101,7 @@ module.exports = {
98
101
  // notifyMode: "failure-change",
99
102
 
100
103
  // A preset that is used as a base for Jest's configuration
101
- // preset: "",
104
+ preset: "ts-jest",
102
105
 
103
106
  // Run tests from one or more projects
104
107
  // projects: undefined,
@@ -122,9 +125,9 @@ module.exports = {
122
125
  // rootDir: undefined,
123
126
 
124
127
  // A list of paths to directories that Jest should use to search for files in
125
- // roots: [
126
- // "<rootDir>"
127
- // ],
128
+ roots: [
129
+ "<rootDir>"
130
+ ],
128
131
 
129
132
  // Allows you to use a custom runner instead of Jest's default test runner
130
133
  // runner: "jest-runner",
@@ -0,0 +1,29 @@
1
+ import { IDotDocument } from "./i-dot";
2
+ export declare abstract class ArgCallback {
3
+ el: Element;
4
+ f: (content?: any, index?: number) => string;
5
+ constructor(element: Element, value: (content?: any, index?: number) => string);
6
+ abstract updateContent(dot: IDotDocument, propVal?: any): any;
7
+ }
8
+ export declare class AttrArgCallback extends ArgCallback {
9
+ attr: string;
10
+ constructor(element: Element, attributeName: string, value: (content?: any) => string);
11
+ updateContent(dot: any): void;
12
+ }
13
+ export declare class ContentArgCallback extends ArgCallback {
14
+ constructor(element: Element, content: () => string);
15
+ updateContent(dot: any, propVal: string): void;
16
+ }
17
+ export declare class ArrayArgCallback extends ArgCallback {
18
+ dotTarget: IDotDocument;
19
+ constructor(dotTarget: any, content: any);
20
+ updateContent(): void;
21
+ }
22
+ export declare class ConditionalArgCallback extends ArgCallback {
23
+ startNode: Node;
24
+ endNode: Node;
25
+ condition: () => boolean | boolean;
26
+ lastValue: boolean;
27
+ constructor(startNode: any, endNode: any, content: any, condition: any);
28
+ updateContent(dot: any): void;
29
+ }
@@ -0,0 +1,8 @@
1
+ import Component from "../component";
2
+ import { DotContent } from "../i-dot";
3
+ export declare class NavLink extends Component {
4
+ content: DotContent;
5
+ hRef: string;
6
+ constructor(content: DotContent, href: string);
7
+ builder(): import("../i-dot").IDotA;
8
+ }
@@ -0,0 +1,57 @@
1
+ import Component from "../component";
2
+ interface RouterParams {
3
+ autoNavigate: boolean;
4
+ onNavigateInit: Function;
5
+ onError: Function;
6
+ onResponse: Function;
7
+ onComplete: Function;
8
+ routes: Array<{
9
+ path: string;
10
+ }>;
11
+ }
12
+ export default class DotRouter extends Component {
13
+ static allRouters: {
14
+ [key: string]: DotRouter;
15
+ };
16
+ static routerId: number;
17
+ static mayRedirect: boolean;
18
+ static _get(url: any, success: any, fail: any): void;
19
+ static routerEventSet: boolean;
20
+ static setupPopupFunction(): void;
21
+ id: number;
22
+ outlet: Element;
23
+ navId: number;
24
+ currentRoute: string;
25
+ currentParams: RouterParams;
26
+ params: RouterParams;
27
+ routesAndSegments: Array<{
28
+ path: string;
29
+ segments: string[];
30
+ }>;
31
+ constructor(params: RouterParams);
32
+ /**
33
+ * TODO: convert to interface.
34
+ * @param {Object} params - Parameters.
35
+ * @param {Array.<{path: string, title: string, component: Object}>} params.routes - Array of routes.
36
+ * @param {boolean} params.autoNavigate - Router will automatically navigate when outlet is created.
37
+ * @param {Function} params.onNavigateInit - Occurs before any request is sent, and before the router outlet is emptied.
38
+ * @param {Function} params.onError - Occurs in the event of an HTTP error.
39
+ * @param {Function} params.onResponse - Occurs after a successful HTTP response, but before rendering.
40
+ * @param {Function} params.onComplete - Occurs after an uncancelled route completes without an error.
41
+ */
42
+ builder(): import("../i-dot").IDotElementDocument<import("../i-dot").IDotGenericElement>;
43
+ registered(): void;
44
+ ready(): void;
45
+ deleting(): void;
46
+ navigate(path: string, noHistory?: boolean, force?: boolean): {
47
+ cancel: () => void;
48
+ element: Element;
49
+ httpResponse: any;
50
+ isNew: boolean;
51
+ params: any;
52
+ path: string;
53
+ title: any;
54
+ wasCancelled: boolean;
55
+ };
56
+ }
57
+ export {};
@@ -0,0 +1,73 @@
1
+ import { IDotElement } from "./i-dot";
2
+ import IDotCss from "./i-dotcss";
3
+ declare abstract class Component {
4
+ static initializeComponent<T extends Component>(obj: T): void;
5
+ static build<T extends Component>(obj: T): Element;
6
+ static initializeEventHandlers(obj: any): void;
7
+ static createProp(activePropContainer: Function, name: string): void;
8
+ static configureDependency(cc: Component, name: string): void;
9
+ static updateProp(obj: Component, name: string): void;
10
+ constructor(...args: Array<any>);
11
+ /**
12
+ * A function returning DOThtml (required).
13
+ */
14
+ abstract builder(...args: Array<any>): IDotElement;
15
+ /**
16
+ *
17
+ */
18
+ props: {
19
+ [key: string]: any;
20
+ };
21
+ /**
22
+ * A series of events that can be raised from inside the component.
23
+ */
24
+ events: {
25
+ [key: string]: (...params: Array<any>) => void;
26
+ };
27
+ /**
28
+ * An optional function that gets called before the component is created, scoped to the new component object.
29
+ */
30
+ created(...args: Array<any>): void;
31
+ /**
32
+ * An optional function called after the element has been added. One parameter will be provided containing the added element.
33
+ */
34
+ ready(): void;
35
+ /**
36
+ * An optional function called before the component is deleted.
37
+ */
38
+ deleting(): void;
39
+ /**
40
+ * An optional function called after the component is deleted.
41
+ */
42
+ deleted(): void;
43
+ /**
44
+ * An optional function called after the component is built.
45
+ */
46
+ built(): void;
47
+ on(event: string, handler: Function): void;
48
+ off(event: string, handler: Function): void;
49
+ private __$el;
50
+ private __built;
51
+ private __stylesSet;
52
+ private __eventsInitialized;
53
+ private __propContainer;
54
+ private __args;
55
+ /**
56
+ * The main element of this component - automatically set after the builder is called.
57
+ */
58
+ get $el(): HTMLElement;
59
+ $refs: {
60
+ [key: string]: Element;
61
+ };
62
+ /**
63
+ * Name of the component (optional). If provided, dot and the VDBO will be extended.
64
+ */
65
+ name: string;
66
+ /**
67
+ * An optional function that is called after builder that stylizes the component using a scoped style builder.
68
+ */
69
+ style?(styleBuilder: IDotCss): void;
70
+ $styleBuilder?: Function;
71
+ $updateStyles(): void;
72
+ }
73
+ export default Component;
File without changes
File without changes
@@ -0,0 +1,13 @@
1
+ import type Component from "./component";
2
+ export declare function eachK(obj: any, cb: any): void;
3
+ export declare function isF(v: any): any;
4
+ export declare const sT: typeof setTimeout;
5
+ export declare function str(s: number, v?: number): string;
6
+ declare class _ClassPrefix {
7
+ private current;
8
+ reset(): void;
9
+ get next(): number;
10
+ }
11
+ export declare const ClassPrefix: _ClassPrefix;
12
+ export declare const GlobalComponentStack: Array<Component>;
13
+ export {};
package/lib/dot.d.ts ADDED
@@ -0,0 +1,5 @@
1
+ import { IDotCore } from "./i-dot";
2
+ declare const dot: IDotCore;
3
+ export declare const SELECTOR_MODE = 1;
4
+ export declare const ATTRIBUTE_MODE = 2;
5
+ export default dot;
@@ -0,0 +1,21 @@
1
+ import dot from "./dot";
2
+ /*! DOThtml (c) Joshua Sideris | dothtml.org/license */
3
+ /**
4
+ * Changes:
5
+ * - Converted to typescript.
6
+ * - Removed if, IF, elseif, ELSEIF, else, and ELSE functions, replacing them with when, otherwiseWhen, and otherwise. Improves compatibility for IE 8.
7
+ * - Also took some shortcuts that may not have polyfill with older browsers. Will get back to adding reverse compatibility in a future update.
8
+ * - Created several type interfaces.
9
+ * - Changed the names to HTML tags and attributes to pascal case.
10
+ * - Removed most E and A suffixes from tag and attribute names.
11
+ * - Removed special selection behavior for overlapping HTML names. Instead, all conflicts were renamed.
12
+ * - Added attribute-element associations.
13
+ * - Added `as` function for casting (mostly useful when adding attributes via the dot selector).
14
+ * - Started the long process of adding comment documentation for custom built-in functions.
15
+ * - Re-imagined components from the ground up. Components are now classes that inherit from `Component`. Plays very nicely with TS and ES6.
16
+ * - Added interfaces for new methods that can be invoked on various elements. For instance, play, pause, and stop on audio and video elements.
17
+ * - Updated scopeClass method to put the optional parameter last.
18
+ */
19
+ export default dot;
20
+ export { IDotElement } from "./i-dot";
21
+ export { default as IDotCss } from "./i-dotcss";
package/lib/dothtml.js ADDED
@@ -0,0 +1,2 @@
1
+ /*! For license information please see dothtml.js.LICENSE.txt */
2
+ (()=>{"use strict";var e={555:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ConditionalArgCallback=t.ArrayArgCallback=t.ContentArgCallback=t.AttrArgCallback=t.ArgCallback=void 0;class n{constructor(e,t){this.el=e,this.f=t}}t.ArgCallback=n,t.AttrArgCallback=class extends n{constructor(e,t,n){super(e,n),this.attr=t}updateContent(e){this.el.setAttribute(this.attr,this.f())}},t.ContentArgCallback=class extends n{constructor(e,t){super(e,t)}updateContent(e,t){e(this.el).empty().h(this.f(t))}},t.ArrayArgCallback=class extends n{constructor(e,t){super(null,t),this.dotTarget=e}updateContent(){}},t.ConditionalArgCallback=class extends n{constructor(e,t,n,r){super(null,n),this.startNode=e,this.endNode=t,this.condition=r,this.lastValue=void 0}updateContent(e){if(this.lastValue!=!!this.condition())if(this.lastValue=!this.lastValue,this.lastValue)e._appendOrCreateDocument(this.f,this.endNode.parentNode,this.endNode);else do{var t=this.startNode.nextSibling;t&&t!=this.endNode&&t.parentNode.removeChild(t)}while(this.startNode.nextSibling&&this.startNode.nextSibling!=this.endNode)}}},999:function(e,t,n){var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const a=r(n(969)),i=r(n(150)),o=n(669),s=r(n(177)),l=n(555);class u{constructor(...e){this.__built=!1,this.__stylesSet=!1,this.__eventsInitialized=!1,this.$refs={},this.__args=e}static initializeComponent(e){e.constructor.__dotComponentInitialized||(e.constructor.__dotComponentInitialized=!0,e.constructor.__dotClassNumb=o.ClassPrefix.next,e.constructor.__activePropContainer=function(e){this.__component=e},(0,o.eachK)(e.props,((t,n)=>{u.createProp(e.constructor.__activePropContainer,t)})))}static build(e){u.initializeComponent(e),o.GlobalComponentStack.push(e),e.created&&e.created(...e.__args),e.__built&&(0,s.default)("CB"),e.__built=!0,e.__propContainer={activePropConstructor:e.constructor.__activePropContainer,rawProps:e.props||{},activeProps:new e.constructor.__activePropContainer(e),propDependencies:{},bindings:{}},e.props=e.__propContainer.activeProps,(0,o.eachK)(e.__propContainer.rawProps,((t,n)=>{e.__propContainer.bindings[t]=[],e.props[t]=n})),u.initializeEventHandlers(e);let t=e.builder(...e.__args).getLast();return(!t||t.parentNode.childNodes.length>1)&&(0,s.default)("C#",e.name||e.constructor.name||"(unnamed obj)"),e.__$el=e.$el||t,e.$el.__dothtml_component=e,e.style&&(e.$styleBuilder=function(){i.default.css.scopeToEl(e.$el),e.__stylesSet||(i.default.css.cacheScopedStaticStyles(e.$el),e.__stylesSet=!0),i.default.css.clearDynamicStyles(e.$el),e.style(i.default.css),i.default.css.unscope()},e.$updateStyles()),e.built&&e.built(),e.ready&&(0,o.sT)((()=>{o.GlobalComponentStack.push(e),e.ready(),o.GlobalComponentStack.pop()}),0),o.GlobalComponentStack.pop(),e.$el}static initializeEventHandlers(e){e.__eventsInitialized||(e.__eventsInitialized=!0,(0,o.eachK)(e.events,((t,n)=>{e.events[t]=function(){for(let n of e.events[t].__handlers)n.apply(this,arguments)},e.events[t].__handlers=[]})))}static createProp(e,t){Object.defineProperty(e.prototype,t,{configurable:!1,enumerable:!1,get:function(){i.default.__lastProp=t,i.default.__lastIndex=null,i.default.__lastComponent=this.__component;let e=this.__component.__propContainer.rawProps[t];return u.configureDependency(this.__component,t),e},set:function(e){let n=e;e instanceof Array&&(n=new a.default(e),n.addEventListener("read",(e=>{i.default.__lastIndex=e.index}))),this.__component.__propContainer.rawProps[t]=n;for(let e of this.__component.__propContainer.bindings[t])(0,i.default)(e.element).as(i.default.input).setVal(n);return u.updateProp(this.__component,t),n}})}static configureDependency(e,t){var n=i.default.__currentArgCallback[i.default.__currentArgCallback.length-1];if(n){let i=e.__propContainer.rawProps[t];i instanceof a.default&&(i.addEventListener("itemadded",(function(r){n instanceof l.ArrayArgCallback?n.dotTarget._appendOrCreateDocument(n.f(r.item,r.index),void 0,r.index):n&&u.updateProp(e,t)})),i.addEventListener("itemset",(function(r){if(n instanceof l.ArrayArgCallback){var a=n.dotTarget.__document,i=a.childNodes[r.index];a.removeChild(i),n.dotTarget._appendOrCreateDocument(n.f(r.item,r.index),void 0,r.index)}else n&&u.updateProp(e,t)})),i.addEventListener("itemremoved",(function(r){n instanceof l.ArrayArgCallback?n.dotTarget.__document.removeChild(n.dotTarget.__document.childNodes[r.index]):n&&u.updateProp(e,t)})));var r=e.__propContainer.propDependencies[t];r||(r=e.__propContainer.propDependencies[t]=[]),r.push(n)}}static updateProp(e,t){let n=e.__propContainer.propDependencies[t],r=e.__propContainer.rawProps[t],a=!1;for(let e=0;e<(n||[]).length;e++){let t=n[e];t.updateContent(i.default,r),t instanceof l.AttrArgCallback&&"class"==t.attr&&(a=!0)}a&&e.$updateStyles()}created(...e){}ready(){}deleting(){}deleted(){}built(){}on(e,t){u.initializeEventHandlers(this);let n=this.events&&this.events[e];n||(0,s.default)("UE",e);let r=n.__handlers;-1==r.indexOf(t)&&r.push(t)}off(e,t){let n=this.events&&this.events[e];n||(0,s.default)("UE",e);let r=n.__handlers,a=r.indexOf(t);a>-1&&r.splice(a,1)}get $el(){return this.__$el}$updateStyles(){this.$styleBuilder&&this.$styleBuilder()}}t.default=u},669:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.GlobalComponentStack=t.ClassPrefix=t.str=t.sT=t.isF=t.eachK=void 0,t.eachK=function(e,t){if(e)for(var n=Object.keys(e),r=0;r<n.length;r++)t(n[r],e[n[r]])},t.isF=function(e){return e&&e.constructor&&e.call&&e.apply},t.sT=setTimeout,t.str=function(e,t){return(e||"").toString(t)},t.ClassPrefix=new class{constructor(){this.current=65536}reset(){this.current=65536}get next(){return this.current++}},t.GlobalComponentStack=[]},150:function(e,t,n){var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.ATTRIBUTE_MODE=t.SELECTOR_MODE=void 0;const a=r(n(351)),i=r(n(139)),o=r(n(177)),s=n(669),l=r(n(999)),u=n(555),c=r(n(969)),d=function(e){var n=e?"string"==typeof e?document.querySelectorAll(e):e instanceof Element||e instanceof Node?[e]:e instanceof NodeList||e instanceof Array&&e[0]&&(e[0]instanceof Element||e[0]instanceof Node)?e:[]:[],r=new v;return n.length>0&&(r.__document=n[0]),d.__selectionMode=t.SELECTOR_MODE,r},h="DOTHTML-DEFER";var p=0;function f(e,t){k[e]=d[e]=t}function g(e){var t=null,n=e.__dothtml_component;n&&(n.deleting&&n.deleting(),n.__$el=null,t=n.deleted),e.parentNode&&e.parentNode.removeChild(e),t&&t.apply(n)}function m(e,t,n,r){e.addEventListener?e.addEventListener(t,n,r||!1):e.attachEvent("on"+t,n)}function _(e){f(e,(function(t){return this.el(e,t)}))}function b(e,t){k[t||e]=function(t){return this.attr(e,t)}}t.SELECTOR_MODE=1,t.ATTRIBUTE_MODE=2;var y,v=function(e,n){this.__document=e,this.__lastNode=e?e.lastChild:null,this.__if=null,this.__pendingCalls=[],this.__anonAttrFuncs={},this.__classPrefix=n||0,this.__classedElements=[],this.__selectionMode=t.SELECTOR_MODE},k=v.prototype,w=["a","aside","abbr","address","area","article","audio","b","bdi","bdo","blockQuote","body","br","button","canvas","caption","cite","code","col","colGroup","content","data","dataList","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldSet","figCaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hr","i","iFrame","img","input","ins","kbd","keyGen","label","legend","li","main","map","mark","menu","menuItem","meter","nav","object","ol","optGroup","option","output","p","param","pre","progress","q","rp","rt","ruby","s","samp","section","select","small","source","span","strong","svg","sub","summary","sup","table","tBody","td","textArea","tFoot","th","tHead","time","tr","track","u","ul","var","video","wbr"],x=["accept","accessKey","action","align","aLink","alt","archive","autoComplete","autoFocus","autoPlay","autoSave","axis","background","bgColor","border","buffered","cellPadding","cellSpacing","challenge","char","charOff","checked","classId","clear","codeBase","codeType","color","cols","colSpan","compact","contentEditable","contextMenu","controls","coords","dateTime","declare","default","dir","dirName","disabled","download","draggable","dropZone","encType","face","font","fontFace","fontFaceFormat","fontFaceName","fontFaceSrc","fontFaceUri","fontSpecification","for","foreignObject","formAction","frame","frameBorder","headers","height","hidden","high","hRef","hRefLang","hSpace","icon","id","images","isMap","itemProp","keyType","kind","lang","list","longDesc","loop","low","manifest","marginHeight","marginWidth","max","maxLength","media","metadata","method","min","missingGlyph","multiple","muted","name","noHRef","noResize","noShade","noValidate","nowrap","open","optimum","pattern","ping","placeholder","poster","preload","prompt","radioGroup","readOnly","rel","required","rev","reversed","rows","rowSpan","rules","sandbox","scope","scrolling","seamless","selected","shape","size","sizes","spellCheck","src","srcDoc","srcLang","srcSet","standby","start","step","style","tabIndex","target","title","type","useMap","vAlign","value","valueType","width","wrap"],C=[["quoteCite","cite"],["objectData","data"],["whichForm","form"],["trackLabel","label"],["colSpan","span"],["tableSummary","summary"],["optionLabel","label"],["acceptCharset","accept-charset"]],S=["onAbort","onBlur","onChange","onInput","onCanPlay","onCantPlayThrough","onClick","onCopy","onContextMenu","onCueChange","onCut","onDblClick","onDrag","onDragEnd","onDragEnter","onDragLeave","onDragOver","onDragStart","onDrop","onDurationChange","onEmptied","onEnded","onError","onFocus","onHashChange","onInvalid","onKeyDown","onKeyPress","onKeyUp","onLoad","onLoadedData","onLoadedMetadata","onLoadStart","onMouseDown","onMouseEnter","onMouseMove","onMouseOut","onMouseOver","onMouseUp","onMouseWheel","onOffline","onOnline","onPageHide","onPagePaste","onPageShow","onPause","onPlay","onPlaying","onPopState","onProgress","onRateChange","onReset","onResize","onScroll","onSearch","onSeeked","onSeeking","onSelect","onStalled","onStorage","onSubmit","onSuspend","onTimeUpdate","onToggle","onUnload","onVolumeChange","onWaiting","onWheel"];for(y in w)_(w[y]);for(y in x)b(x[y]);for(y in C)b(C[y][1],C[y][0]);for(y in S)b(S[y]);f("as",(function(e){return this})),f("_getNewDocument",(function(){return document.createElement("DOTHTML-DOCUMENT")})),f("_getAnInstance",(function(){if(this.__document||this.__pendingCalls.length>0)return this;var e=new v(null,this.__classPrefix);return e.__if=this.__if,e})),f("_getLastChildOrNull",(function(){return this.__document&&this.__document.lastChild?this.__document.lastChild:null})),f("getLast",(function(){return this._getLastChildOrNull()})),f("getCurrent",(function(){let e;switch(d.__selectionMode){case t.SELECTOR_MODE:e=this.__document;break;case t.ATTRIBUTE_MODE:e=this.getLast()||this.__document}return e})),k.toString=function(){return this.__document?this.__document.innerHTML:""},k.ref=function(e){let t=this.getLast(),n=s.GlobalComponentStack.length;return t&&n>0&&(s.GlobalComponentStack[n-1].$refs[e]=t),this},f("_evalContent",(function(e,t){if(null==e||null==e)return null;if("string"==typeof e||"number"==typeof e||"boolean"==typeof e){let t=new v(this._getNewDocument(),this.__classPrefix);return t.__document.innerHTML=e,t.__document.childNodes}if(e instanceof Node)return e;if("[object Array]"===Object.prototype.toString.call(e)){let t=new v(this._getNewDocument(),this.__classPrefix);for(let n=0;n<e.length;n++)t._appendOrCreateDocument(e[n]);if(t.__document)return t.__document.childNodes}else{if((0,s.isF)(e))return this._evalContent(e(),t);if(e instanceof l.default)return this._evalContent(l.default.build(e));if(e instanceof v){for(let n=0;n<e.__pendingCalls.length;n++)t.push(e.__pendingCalls[n]);let n=this.__classPrefix;for(let t in e.__classedElements){let r=e.__classedElements[t];n?r.className="dot-"+(0,s.str)(n,16)+"-"+r.className:this.__classedElements.push(r)}if(e.__document)return e.__document.childNodes}}return null})),f("_appendOrCreateDocument",(function(e,t,n){var r=this;if(t&&n&&isNaN(n)&&n.parentNode!=t)throw"beforeNode is not in parentEl.";t=t||(n&&isNaN(n)?n.parentNode:null)||r.__document||r._getNewDocument(),isNaN(n)||(n=t.childNodes[n]);var a=r.__document===t?r:new v(t,r.__classPrefix);a.__if=r.__if;var i,o=[],l=(0,s.isF)(e);l&&d.__currentArgCallback.push(new u.ContentArgCallback(t,e));try{i=a._evalContent(e,o)}finally{l&&d.__currentArgCallback.pop()}for(var c=0;c<o.length;c++){var h=o[c],p=(n?n.previousSibling||t:null)||t.lastChild||t;p&&"DOCUMENT"!=p.tagName?"attr"==h.type?(0,s.isF)(h.params[0])?m(p,h.name,h.params[0],h.arg3):p.setAttribute(h.name,h.params[0]):"wait"==h.type&&h.callback():a.__pendingCalls.push(h)}if(null!=i)if(i instanceof NodeList)for(;i.length>0;)n?t.insertBefore(i[0],n):t.appendChild(i[0]);else n?t.insertBefore(i,n):t.appendChild(i);return a})),f("el",(function(e,n){var r=this,a=document.createElement(e),i=r.__document||r._getNewDocument();i.appendChild(a),n&&r._appendOrCreateDocument(n,a);var o=r.__document===i?r:new v(i,r.__classPrefix);if(n&&n instanceof v)for(var s in n.__classedElements)o.__classedElements.push(n.__classedElements[s]);return d.__selectionMode=t.ATTRIBUTE_MODE,o})),f("h",(function(e){var t=this,n=t._getNewDocument();new v(n,t.__classPrefix)._appendOrCreateDocument(e);for(var r=t.__document||t._getNewDocument();n.childNodes.length>0;)r.appendChild(n.childNodes[0]);return t.__document===r?t:new v(r,t.__classPrefix)})),f("t",(function(e){var t=document.createTextNode(e),n=this.__document||this._getNewDocument();return n.appendChild(t),new v(n,this.__classPrefix)})),f("attr",(function(e,t,n){var r=this;if((0,s.isF)(t)&&(0==e.indexOf("on")&&-1!=S.indexOf(e)?e=e.substring(2).toLowerCase():(d.__anonAttrFuncs[p]=t,t="dot.__anonAttrFuncs["+p+++"](arguments[0]);")),!r.__document){var a=r._getAnInstance();return a.__pendingCalls.push({type:"attr",name:e,params:[t],arg3:n}),a}var i=r.__document.childNodes,o=i[i.length-1];if(o&&o.setAttribute)if((0,s.isF)(t))m(o,e,t,n);else{if("object"==typeof t&&!(t instanceof d.css._Builder)){var l=t,c=function(){var e="";return(0,s.eachK)(l,(function(t,n){(n=(0,s.isF)(n)?n():n)&&(e+=" "+t)})),e.substring(1)};d.__currentArgCallback.push(new u.AttrArgCallback(o,e,c)),t=c(),d.__currentArgCallback.pop()}var h=o.getAttribute(e);h?h+=" ":h="",o.setAttribute(e,h+(void 0===t?e:t))}return r})),f("_appendSetElement",(function(e,t){var n=this;if(!e)return(0,o.default)("A",e),n;var r=document.getElementById(e);if(!r)return(0,o.default)("F",e),n;if(n.__document)for(t||(r.innerHTML="");n.__document.childNodes.length>0;)r.appendChild(n.__document.childNodes[0]);return n})),f("iterate",(function(e,t){for(var n=this,r=0;r<e;r++){let e=null;(0,s.isF)(t)&&(e=t(r)),n=n._appendOrCreateDocument(e)}return n})),f("each",(function(e,t,n){var r=this;if((0,s.isF)(e)){if(!n)return r.defer((function(n){n.each(e,t,!0)}));var a=e;d.__currentArgCallback.push(new u.ArrayArgCallback(r,t));try{e=a()}finally{d.__currentArgCallback.pop()}}if(e instanceof Array||e instanceof c.default)for(var i=0;i<e.length;i++)r=r._appendOrCreateDocument(t(e[i],i));else{var o=Object.keys(e);for(i=0;i<o.length;i++){var l=o[i];r=r._appendOrCreateDocument(t(e[l],l))}}return r})),k.customData=function(e,t){return this.attr("data-"+e,t)},k.class=function(e){var t=this.__classPrefix;if(t){var n="dot-"+(0,s.str)(t,16)+"-";if("string"==typeof e)e=n+e;else if("object"==typeof e){var r={};(0,s.eachK)(e,(function(e,t){r[n+e]=t})),e=r}}else{var a=this.getLast();a&&this.__classedElements.push(a)}return this.attr("class",e)},k.play=function(){let e=this.getCurrent();return e.play&&e.play(),this},k.pause=function(e){let t=this.getCurrent();return t.pause&&t.pause(),e&&(t.currentTime=0),this},k.stop=function(){return this.pause(!0)},k.setVal=function(e){let t=this.getCurrent();return t?(Array.isArray&&Array.isArray(e)||!Array.isArray&&e.join?e=e.join(""):null==e&&(e=""),"checkbox"==t.type||"radio"==t.type?t.checked=!!e:"OPTION"==t.tagName?t.selected=!!e:t.value=e,this):this},k.getVal=function(){var e=this.__lastNode||this.__document;if(e&&1===e.nodeType)return"checkbox"==e.type||"radio"==e.type?!!e.checked:"OPTION"==e.tagName?!!e.selected:e.value},f("when",(function(e,t,n){var r=this._getAnInstance();if((0,s.isF)(e)){n||(n=r.__conditionalArray=[e]);var a=n.length-1;r=function(e,t,n,r){var a=document.createTextNode(""),i=document.createTextNode(""),o=new u.ConditionalArgCallback(a,i,r,t);d.__currentArgCallback.push(o);var s=t();e=e._appendOrCreateDocument(a);for(var l=0;l<n.length;l++)n[l]();return o.lastValue=s,s&&(e=e._appendOrCreateDocument(r)),e=e._appendOrCreateDocument(i),d.__currentArgCallback.pop(),e}(r,(function(){for(var t=0;t<a;t++)if(n[t]())return!1;return!!e()}),n,t)}else e?(r=r._appendOrCreateDocument((0,s.isF)(t)?t():t)).__if=!0:r.__if=!1;return r})),f("otherwiseWhen",(function(e,t){if((0,s.isF)(e)){var n=this.__conditionalArray;return n||(0,o.default)("MC"),n.push(e),this.when(e,t,n)}return this.__if?this:this.when(e,t)})),f("otherwise",(function(e){var t=this.__conditionalArray;if(t){var n=function(){return!0};return t.push(n),this.when(n,e,t)}return this.__if?this:(this.__if=null,this._getAnInstance()._appendOrCreateDocument(e))})),f("script",(function(e){var t=this.getLast();return(0,s.sT)((function(){e(t)}),0),this})),f("wait",(function(e,t){var n=this.el(h),r=n.__document.lastChild;return(0,s.sT)((()=>{n._appendOrCreateDocument(t,null,r),r.parentElement.removeChild(r)}),e),n})),f("defer",(function(e){(0,s.isF)(e)||(0,o.default)("XF","defer");var t=this.el(h),n=t.__document.lastChild;return(0,s.sT)((()=>{e(d(n.parentElement)),n.parentElement.removeChild(n)}),0),t})),f("empty",(function(){if(this.__document){for(var e=[this.__document],t=!0,n=[];e.length>0;){var r=e.shift();if(r.childNodes.length>0)for(var a=0;a<r.childNodes.length;a++)e.push(r.childNodes[a]);!t&&n.push(r),t=!1}for(;n.length>0;)g(n.pop())}return this})),f("remove",(function(){this.empty(),g(this.__document)})),f("scopeClass",(function(e,t){null==e&&(e=s.ClassPrefix.next);var n=this;n.__classPrefix=e;var r=n.h(t);return n.__classPrefix=0,r})),k.bindTo=function(e){let t=d.__lastProp,n=d.__lastIndex,r=d.__lastComponent,a=this.getLast(),i=r.props[t];null!=n&&null!=n&&(i=i[n]);let o=this.setVal(i);return m(a,"change",(function(e){r.props[t]=d(a).as(d.input).getVal()})),r.__propContainer.bindings[t].push({element:a}),o},d.resetScopeClass=function(){return s.ClassPrefix.reset(),this},d.css=i.default,d.bus=a.default,d.__currentArgCallback=[],d.__document=null,d.__if=null,d.__pendingCalls=[],d.__anonAttrFuncs={},t.default=d},220:function(e,t,n){var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const a=r(n(150)),i=r(n(999));a.default.version="5.0.0",a.default.Component=i.default,t.default=a.default},177:(e,t)=>{var n;Object.defineProperty(t,"__esModule",{value:!0}),n=function(e,...t){throw{A:`Can't append "${(t=t||[])[0]}".`,CB:"Unable to build the same component twice. Ensure each component is only used once.",CU:"Invalid usage: a component should at least have a name and a builder function.","C#":`Component "${t[0]}" must return exactly one child node.`,F:`Element "${t[0]}" not found.`,MC:"Can't mix static conditions with dynamic conditional rendering.",R:"Router must be passed a JSON object that contains an 'routes' array containing objects with a 'path', 'title', and 'component'.",S:"SVG is not supported by DOThtml.",UE:`Unknown event name "${t[0]}".`,XS:"Expected a string.",XF:`Expected a function in "${t[0]}".`}[e]||"Unknown error."},t.default=n},351:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0});const r=n(669),a=new class{constructor(){this._callbacks={},this._checkAddEvent=function(e){var t=this._callbacks[e];return t||(this._callbacks[e]=t=[]),t}}on(e,t){this._checkAddEvent(e).push(t)}off(e,t){for(var n=this._checkAddEvent(e),r=n.length-1;n>=0;r--)n[r]==t&&n.splice(r,1)}emit(e,...t){var n=this._checkAddEvent(e);(0,r.eachK)(n,(function(e,n){n(...t)}))}flush(e){this._checkAddEvent(e).length=0}};t.default=a},969:(e,t)=>{function n(e){var t=this,n=[],r={itemadded:[],itemremoved:[],itemset:[],read:[]};function a(e){e in t||Object.defineProperty(t,e,{configurable:!0,enumerable:!0,get:function(){return i({type:"read",index:e,item:n[e]}),n[e]},set:function(t){n[e]!=t&&(n[e]=t,i({type:"itemset",index:e,item:t}))}})}function i(e){r[e.type].forEach((function(n){n.call(t,e)}))}Object.defineProperty(t,"addEventListener",{configurable:!1,enumerable:!1,writable:!1,value:function(e,t){if(!((e=(""+e).toLowerCase())in r))throw new Error("Invalid event name.");if("function"!=typeof t)throw new Error("Invalid handler.");r[e].push(t)}}),Object.defineProperty(t,"removeEventListener",{configurable:!1,enumerable:!1,writable:!1,value:function(e,t){if(!((e=(""+e).toLowerCase())in r))throw new Error("Invalid event name.");if("function"!=typeof t)throw new Error("Invalid handler.");for(var n=r[e],a=n.length;--a>=0;)n[a]===t&&n.splice(a,1)}}),Object.defineProperty(t,"push",{configurable:!1,enumerable:!1,writable:!1,value:function(){for(var e,t=0,r=arguments.length;t<r;t++)e=n.length,n.push(arguments[t]),a(e),i({type:"itemadded",index:e,item:arguments[t]});return n.length}}),Object.defineProperty(t,"pop",{configurable:!1,enumerable:!1,writable:!1,value:function(){if(n.length>-1){var e=n.length-1,r=n.pop();return delete t[e],i({type:"itemremoved",index:e,item:r}),r}}}),Object.defineProperty(t,"unshift",{configurable:!1,enumerable:!1,writable:!1,value:function(){for(var e=0,t=arguments.length;e<t;e++)n.splice(e,0,arguments[e]),a(n.length-1),i({type:"itemadded",index:e,item:arguments[e]});return n.length}}),Object.defineProperty(t,"shift",{configurable:!1,enumerable:!1,writable:!1,value:function(){if(n.length>-1){var e=n.shift();return delete t[n.length],i({type:"itemremoved",index:0,item:e}),e}}}),Object.defineProperty(t,"splice",{configurable:!1,enumerable:!1,writable:!1,value:function(e,r){var o,s=[];e=null==e?0:e<0?n.length+e:e,r=null==r?n.length-e:r>0?r:0;for(var l=[];r--;)o=n.splice(e,1)[0],s.push(o),delete t[n.length],l.push({type:"itemremoved",index:e+s.length-1,item:o});for(var u=l.length-1;u>=0;u--)i(l[u]);u=2;for(var c=arguments.length;u<c;u++)n.splice(e,0,arguments[u]),a(n.length-1),i({type:"itemadded",index:e,item:arguments[u]}),e++;return s}}),Object.defineProperty(t,"length",{configurable:!1,enumerable:!1,get:function(){return n.length},set:function(e){var r=Number(e),a=n.length;if(!(r%1==0&&r>=0))throw new RangeError("Invalid array length");return r<a?t.splice(r):r>a&&t.push.apply(t,new Array(r-a)),n.length=r,e}}),Object.getOwnPropertyNames(Array.prototype).forEach((function(e){e in t||Object.defineProperty(t,e,{configurable:!1,enumerable:!1,writable:!1,value:Array.prototype[e]})})),e instanceof Array&&t.push.apply(t,e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=n,n.prototype.length=0},139:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0});const n="data-dot-static-styles",r=function(e){var t=null;if(e){if("string"==typeof e)if(e.length>2&&e.indexOf("{}")==e.length-2)e=e.substring(0,e.length-2),t=[document.createElement("style")],document.head.appendChild(t[0]),t[0].innerHTML=e+"{}";else{var n=i[0];t=n&&n.parentNode&&n.querySelectorAll?o(e,n):document.querySelectorAll(e)}(e instanceof NodeList||e instanceof Array)&&(t=e),e instanceof Node&&(t=[e])}return a._lastBuilder=new s(t),a._lastBuilder},a=r;r.version="0.16.0",a._fxInterval=1e3/60,a._lastBuilder=null,a._floatRegex=new RegExp("[-+]?[0-9]*\\.?[0-9]+(?:[eE][-+]?[0-9]+)?","g");var i=[];function o(e,t){for(var n=Array.from(t.querySelectorAll(e)),r=0;r<n.length;r++){var a=n[r];if(a.__dothtml_component){n.splice(r,1),r--;for(var i=a.querySelectorAll(e),o=0;o<i.length;o++){let e=i[o];n.splice(n.indexOf(e,r+1),1)}}}var s=Array.from(t.parentNode.querySelectorAll(e)),l=s.indexOf(t);return-1!=l&&n.unshift(s[l]),n}function s(e){this.currentCss="",this.target=e}a._Builder=s;var l=s.prototype;function u(){this.type=null,this.jsFriendlyProp=null}l.toString=r.prototype.toString=function(){return this.currentCss},l.hide=function(){if(this.target){var e=arguments[0]||{},t=e,n=e,a={};if(a.duration=n.duration||(isNaN(t)?0:t)||0,a.complete=n.complete||("function"==typeof arguments[1]?arguments[1]:"function"==typeof arguments[2]?arguments[2]:function(){}),a.hideStyle=n.hideStyle||"normal",a.animationStyle=n.animationStyle||("string"==typeof arguments[1]?arguments[1]:"ease"),a.duration>0)for(var i=0,o=0,s=this.target.length,l=0;l<this.target.length;l++){var u=this.target[l].style.width,c=this.target[l].style.height,d=this.target[l].style.opacity;""===d&&(d=1);var h=this.target[l].style.overflow;"fade"!=a.hideStyle&&(this.target[l].style.overflow="hidden",o+=2,function(e,t,n,l,u){r(t).width.animate(0,a.duration,a.animationStyle,(function(){r(t).display("none").width(n).overflow(u),++i>=o*s&&a.complete(e)})),r(t).height.animate(0,a.duration,a.animationStyle,(function(){r(t).display("none").height(l),++i>=o*s&&a.complete(e)}))}(this,this.target[l],u,c,h)),"shrink"!=a.hideStyle&&(o++,function(e,t,n){r(t).opacity.animate(0,a.duration,a.animationStyle,(function(){r(t).display("none").opacity(n),++i>=o*s&&a.complete(e)}))}(this,this.target[l],d))}else r(this.target).display("none"),a.complete(this)}return this},l.show=function(){if(this.target){var e=arguments[0]||{},t=e,n=e,a={};if(a.duration=n.duration||(isNaN(t)?0:t)||0,a.display=n.display||"block",a.opacity=n.opacity,a.width=n.width||null,a.height=n.height||null,a.complete=n.complete||("function"==typeof arguments[1]?arguments[1]:"function"==typeof arguments[2]?arguments[2]:function(){}),a.showStyle=n.showStyle||"normal",a.animationStyle=n.animationStyle||("string"==typeof arguments[1]?arguments[1]:"ease"),!(a.duration>0))return r(this.target).display(a.display);for(var i=0,o=this.target.length,s=0,l=0;l<this.target.length;l++){var u=a.opacity;if(void 0===a.opacity&&(u=parseFloat(this.target[l].style.opacity)||1),"fade"!=a.showStyle){s+=2;var c=a.width||this.target[l].style.width,d=a.height||this.target[l].style.height;r(this.target[l]).width(0),r(this.target[l]).height(0),r(this.target[l]).width.animate(c,a.duration,a.animationStyle,(function(){++i>=o*s&&a.complete()})),r(this.target[l]).height.animate(d,a.duration,a.animationStyle,(function(){++i>=o*s&&a.complete()}))}r(this.target[l]).opacity(0),r(this.target[l]).display(a.display),"grow"!=a.showStyle&&(s++,r(this.target[l]).opacity.animate(u,a.duration,a.animationStyle,(function(){++i==o*s&&a.complete()})))}}return this},l.fadeOut=function(e,t){return this.hide({duration:isNaN(e)?400:Number(e),hideStyle:"fade",complete:t})},l.fadeIn=function(e,t){return this.show({duration:isNaN(e)?400:Number(e),showStyle:"fade",complete:t})},a._Url=function(e){if(this.type="url",this.url=null,!e||0==e.length||1==e.length&&""==e[0]||"none"==e[0]||"initial"==e[0]||"inherit"==e[0])this.url=null;else{this.url=[];for(var t=0;t<e.length;t++)if(0===e[t].toLowerCase().indexOf("url")){var n=e[t].substring(e[t].indexOf("("),e[t].lastIndexOf(")")).trim();(n.indexOf('"')&&n.lastIndexOf('"')==n.length-1||n.indexOf("'")&&n.lastIndexOf("'")==n.length-1)&&(n=n.substring(1,n.length-1)),this.url.push(n)}else this.url.push(e[t])}},a._Url.prototype.toString=function(){if(this.url){for(var e=[],t=0;t<this.url.length;t++)e.push('url("'+this.url[t]+'")');return e.join(", ")}return"none"},a._Color=function(e){if(this.type="color",this.r=0,this.g=0,this.b=0,this.a=1,1==e.length)if(""==(e=e[0])||"none"==e||"initial"==e||"inherit"==e);else if(isNaN(e))if("#"==e[0]){var t=e.split("#")[1];3==t.length?(this.r=Number("0x"+t[0]+t[0]),this.g=Number("0x"+t[1]+t[1]),this.b=Number("0x"+t[2]+t[2])):6==t.length&&(this.r=Number("0x"+t[0]+t[1]),this.g=Number("0x"+t[2]+t[3]),this.b=Number("0x"+t[4]+t[5]))}else if(0===e.toLowerCase().indexOf("rgb")){var n=e.split("(")[1];3!=(n=(n=n.split(")")[0]).split(",")).length&&4!=n.length||(this.r=Number(n[0]),this.g=Number(n[1]),this.b=Number(n[2]),this.a=Number(n[3]||1))}else{var r=0,a=0,i=0;switch(e.toLowerCase()){case"aliceblue":r=240,a=248,i=255;break;case"antiquewhite":r=250,a=235,i=215;break;case"aqua":r=0,a=255,i=255;break;case"aquamarine":r=127,a=255,i=212;break;case"azure":r=240,a=255,i=255;break;case"beige":r=245,a=245,i=220;break;case"bisque":r=255,a=228,i=196;break;case"black":r=0,a=0,i=0;break;case"blanchedalmond":r=255,a=235,i=205;break;case"blue":r=0,a=0,i=255;break;case"blueviolet":r=138,a=43,i=226;break;case"brown":r=165,a=42,i=42;break;case"burlywood":r=222,a=184,i=135;break;case"cadetblue":r=95,a=158,i=160;break;case"chartreuse":r=127,a=255,i=0;break;case"chocolate":r=210,a=105,i=30;break;case"coral":r=255,a=127,i=80;break;case"cornflowerblue":r=100,a=149,i=237;break;case"cornsilk":r=255,a=248,i=220;break;case"crimson":r=220,a=20,i=60;break;case"cyan":r=0,a=255,i=255;break;case"darkblue":r=0,a=0,i=139;break;case"darkcyan":r=0,a=139,i=139;break;case"darkgoldenrod":r=184,a=134,i=11;break;case"darkgray":case"darkgrey":r=169,a=169,i=169;break;case"darkgreen":r=0,a=100,i=0;break;case"darkkhaki":r=189,a=183,i=107;break;case"darkmagenta":r=139,a=0,i=139;break;case"darkolivegreen":r=85,a=107,i=47;break;case"darkorange":r=255,a=140,i=0;break;case"darkorchid":r=153,a=50,i=204;break;case"darkred":r=139,a=0,i=0;break;case"darksalmon":r=233,a=150,i=122;break;case"darkseagreen":r=143,a=188,i=143;break;case"darkslateblue":r=72,a=61,i=139;break;case"darkslategray":case"darkslategrey":r=47,a=79,i=79;break;case"darkturquoise":r=0,a=206,i=209;break;case"darkviolet":r=148,a=0,i=211;break;case"deeppink":r=255,a=20,i=147;break;case"deepskyblue":r=0,a=191,i=255;break;case"dimgray":case"dimgrey":r=105,a=105,i=105;break;case"dodgerblue":r=30,a=144,i=255;break;case"firebrick":r=178,a=34,i=34;break;case"floralwhite":r=255,a=250,i=240;break;case"forestgreen":r=34,a=139,i=34;break;case"fuchsia":r=255,a=0,i=255;break;case"gainsboro":r=220,a=220,i=220;break;case"ghostwhite":r=248,a=248,i=255;break;case"gold":r=255,a=215,i=0;break;case"goldenrod":r=218,a=165,i=32;break;case"gray":case"grey":r=128,a=128,i=128;break;case"green":r=0,a=128,i=0;break;case"greenyellow":r=173,a=255,i=47;break;case"honeydew":r=240,a=255,i=240;break;case"hotpink":r=255,a=105,i=180;break;case"indianred":r=205,a=92,i=92;break;case"indigo":r=75,a=0,i=130;break;case"ivory":r=255,a=255,i=240;break;case"khaki":r=240,a=230,i=140;break;case"lavender":r=230,a=230,i=250;break;case"lavenderblush":r=255,a=240,i=245;break;case"lawngreen":r=124,a=252,i=0;break;case"lemonchiffon":r=255,a=250,i=205;break;case"lightblue":r=173,a=216,i=230;break;case"lightcoral":r=240,a=128,i=128;break;case"lightcyan":r=224,a=255,i=255;break;case"lightgoldenrodyellow":r=250,a=250,i=210;break;case"lightgray":case"lightgrey":r=211,a=211,i=211;break;case"lightgreen":r=144,a=238,i=144;break;case"lightpink":r=255,a=182,i=193;break;case"lightsalmon":r=255,a=160,i=122;break;case"lightseagreen":r=32,a=178,i=170;break;case"lightskyblue":r=135,a=206,i=250;break;case"lightslategray":case"lightslategrey":r=119,a=136,i=153;break;case"lightsteelblue":r=176,a=196,i=222;break;case"lightyellow":r=255,a=255,i=224;break;case"lime":r=0,a=255,i=0;break;case"limegreen":r=50,a=205,i=50;break;case"linen":r=250,a=240,i=230;break;case"magenta":r=255,a=0,i=255;break;case"maroon":r=128,a=0,i=0;break;case"mediumaquamarine":r=102,a=205,i=170;break;case"mediumblue":r=0,a=0,i=205;break;case"mediumorchid":r=186,a=85,i=211;break;case"mediumpurple":r=147,a=112,i=219;break;case"mediumseagreen":r=60,a=179,i=113;break;case"mediumslateblue":r=123,a=104,i=238;break;case"mediumspringgreen":r=0,a=250,i=154;break;case"mediumturquoise":r=72,a=209,i=204;break;case"mediumvioletred":r=199,a=21,i=133;break;case"midnightblue":r=25,a=25,i=112;break;case"mintcream":r=245,a=255,i=250;break;case"mistyrose":r=255,a=228,i=225;break;case"moccasin":r=255,a=228,i=181;break;case"navajowhite":r=255,a=222,i=173;break;case"navy":r=0,a=0,i=128;break;case"oldlace":r=253,a=245,i=230;break;case"olive":r=128,a=128,i=0;break;case"olivedrab":r=107,a=142,i=35;break;case"orange":r=255,a=165,i=0;break;case"orangered":r=255,a=69,i=0;break;case"orchid":r=218,a=112,i=214;break;case"palegoldenrod":r=238,a=232,i=170;break;case"palegreen":r=152,a=251,i=152;break;case"paleturquoise":r=175,a=238,i=238;break;case"palevioletred":r=219,a=112,i=147;break;case"papayawhip":r=255,a=239,i=213;break;case"peachpuff":r=255,a=218,i=185;break;case"peru":r=205,a=133,i=63;break;case"pink":r=255,a=192,i=203;break;case"plum":r=221,a=160,i=221;break;case"powderblue":r=176,a=224,i=230;break;case"purple":r=128,a=0,i=128;break;case"rebeccapurple":r=102,a=51,i=153;break;case"red":r=255,a=0,i=0;break;case"rosybrown":r=188,a=143,i=143;break;case"royalblue":r=65,a=105,i=225;break;case"saddlebrown":r=139,a=69,i=19;break;case"salmon":r=250,a=128,i=114;break;case"sandybrown":r=244,a=164,i=96;break;case"seagreen":r=46,a=139,i=87;break;case"seashell":r=255,a=245,i=238;break;case"sienna":r=160,a=82,i=45;break;case"silver":r=192,a=192,i=192;break;case"skyblue":r=135,a=206,i=235;break;case"slateblue":r=106,a=90,i=205;break;case"slategray":case"slategrey":r=112,a=128,i=144;break;case"snow":r=255,a=250,i=250;break;case"springgreen":r=0,a=255,i=127;break;case"steelblue":r=70,a=130,i=180;break;case"tan":r=210,a=180,i=140;break;case"teal":r=0,a=128,i=128;break;case"thistle":r=216,a=191,i=216;break;case"tomato":r=255,a=99,i=71;break;case"turquoise":r=64,a=224,i=208;break;case"violet":r=238,a=130,i=238;break;case"wheat":r=245,a=222,i=179;break;case"white":r=255,a=255,i=255;break;case"whitesmoke":r=245,a=245,i=245;break;case"yellow":r=255,a=255,i=0;break;case"yellowgreen":r=154,a=205,i=50}this.r=r,this.g=a,this.b=i}else this.b=255&e,e>>=8,this.g=255&e,e>>=8,this.r=255&e;else 3!=e.length&&4!=e.length||(this.r=e[0],this.g=e[1],this.b=e[2],4==e.length&&(this.a=e[3]))},a._Color.prototype.toString=function(){var e=Math.round,t=Math.max,n=Math.min;return 1==this.a?"rgb("+n(255,t(0,e(this.r)))+", "+n(255,t(0,e(this.g)))+", "+n(255,t(0,e(this.b)))+")":"rgba("+n(255,t(0,e(this.r)))+", "+n(255,t(0,e(this.g)))+", "+n(255,t(0,e(this.b)))+", "+n(1,t(0,this.a))+")"},a._Length=function(e){e=e||"0px",isNaN(e)||(e=Math.round(e)+"px"),this.type="length",this.length=Number(e.match(a._floatRegex)[0]),this.units=e.split(a._floatRegex)[1]||"px"},a._Length.prototype.toString=function(){return this.length+this.units},a._Angle=function(e){e=e||"0deg",isNaN(e)||(e=Math.round(e)+"px"),this.type="angle",this.angle=Number(e.match(a._floatRegex)[0]),this.units=e.split(a._floatRegex)[1]||"deg"},a._Angle.prototype.toString=function(){return this.angle+this.units},a._Transform=function(e){if(this.type="transformation",this.transformations=[],""!=e&&"none"!=e&&"initial"!=e&&"inherit"!=e&&-1!=(""+e).indexOf("(")){var t=e.split(/\)\s*/);t.pop();for(var n=0;n<t.length;n++)t[n]+=")";Math.cos,Math.sin,Math.tan;for(var r=0;r<t.length;r++){var a=t[r].trim().split(/[\(\)]/),i=a[0],o=a[1].split(/\s*,\s*/);this[i]&&this[i].apply(this,o)}}},a._Transform.prototype.toString=function(){for(var e="",t=0;t<this.transformations.length;t++){var n=this.transformations[t];e+=n.transformation+"(";for(var r=0;r<n.args.length;r++)e+=n.args[r]+",";e=e.substring(0,e.length-1),e+=") "}return e.trim()},a._Transform.prototype._updateValue=function(e,t){this.transformations.push({transformation:e,args:t})},a._Transform.prototype.matrix3d=function(...e){var t=e;if(16!=t.length)throw"matrix3d requires 16 parameters.";return this.finalMatrix=r.matrixMultiply3D(t,this.finalMatrix),this._updateValue("matrix3d",t),this},a._Transform.prototype.matrix=function(...e){var t=e;if(6==t.length)this._updateValue("matrix",t);else{if(16!=t.length)throw"matrix requires 6 parameters.";this.matrix3d.apply(this,t)}return this},a._Transform.prototype.translate=function(){var e=arguments;if(1==e.length){var t=r.lengthToPx(e[0]);this._updateValue("translate",[new a._Length(t+"px")])}else if(2==e.length){t=r.lengthToPx(e[0]);var n=r.lengthToPx(e[1]);this._updateValue("translate",[new a._Length(t+"px"),new a._Length(n+"px")])}else{if(3!=e.length)throw"translate requires 1 or 2 parameters.";this.translate3d.apply(this,e)}return this},a._Transform.prototype.translate3d=function(){var e=arguments;if(3!=e.length)throw"translate3d requires 3 parameters.";var t=r.lengthToPx(e[0]),n=r.lengthToPx(e[1]),i=r.lengthToPx(e[2]);return this._updateValue("translate3d",[new a._Length(t+"px"),new a._Length(n+"px"),new a._Length(i+"px")]),this},a._Transform.prototype.translateX=function(){var e=arguments;if(1!=e.length)throw"translateX requires 1 parameter.";return this.translate(e[0],0),this},a._Transform.prototype.translateY=function(){var e=arguments;if(1!=e.length)throw"translateY requires 1 parameter.";return this.translate(0,e[0]),this},a._Transform.prototype.translateZ=function(){var e=arguments;if(1!=e.length)throw"translateZ requires 1 parameter.";return this.translate3d(0,0,e[0]),this},a._Transform.prototype.scale=function(){var e=arguments;if(2==e.length)this._updateValue("scale",e);else{if(3!=e.length)throw"scale requires 2 parameters.";this.scale3d.apply(this,e)}return this},a._Transform.prototype.scale3d=function(){var e=arguments;if(3!=e.length)throw"scale3d requires 3 parameters.";return this._updateValue("scale3d",e),this},a._Transform.prototype.scaleX=function(){var e=arguments;if(1!=e.length)throw"scaleX requires 1 parameter.";return this.scale(e[0],1),this},a._Transform.prototype.scaleY=function(){var e=arguments;if(1!=e.length)throw"scaleY requires 1 parameter.";return this.scale(1,e[0]),this},a._Transform.prototype.scaleZ=function(){var e=arguments;if(1!=e.length)throw"scaleZ requires 1 parameter.";return this.scale3d(1,1,e[0]),this},a._Transform.prototype.rotate=function(){var e=arguments;if(1!=e.length)throw"scaleZ requires 1 parameter.";var t=r.angleToDeg(e[0]);return this._updateValue("rotate",[new a._Angle(t+"deg")]),this},a._Transform.prototype.rotate3d=function(){var e=arguments;if(4!=e.length)throw"rotate3d requires 4 parameters.";var t=e[0],n=e[1],i=e[2],o=r.angleToDeg(e[3]);return this._updateValue("rotate3d",[t,n,i,new a._Angle(o+"deg")]),this},a._Transform.prototype.rotateX=function(){var e=arguments;if(1!=e.length)throw"rotateX requires 1 parameter.";var t=r.angleToDeg(e[0]);return this._updateValue("rotateX",[new a._Angle(t+"deg")]),this},a._Transform.prototype.rotateY=function(){var e=arguments;if(1!=e.length)throw"rotateY requires 1 parameter.";var t=r.angleToDeg(e[0]);return this._updateValue("rotateY",[new a._Angle(t+"deg")]),this},a._Transform.prototype.rotateZ=function(){return this.rotate.apply(this,arguments),this},a._Transform.prototype.skew=function(){var e=arguments;if(1==e.length){var t=r.angleToDeg(e[0]);this._updateValue("skew",[new a._Angle(t+"deg")])}else{if(2!=e.length)throw"skew requires 1 or 2 parameters.";t=r.angleToDeg(e[0]);var n=r.angleToDeg(e[1]);this._updateValue("skew",[new a._Angle(t+"deg"),new a._Angle(n+"deg")])}return this},a._Transform.prototype.skewX=function(){var e=arguments;if(1!=e.length)throw"skewX requires 1 parameter.";return this.skew.apply(this,e),this},a._Transform.prototype.skewY=function(){var e=arguments;if(1!=e.length)throw"skewY requires 1 parameter.";return this.skew.apply(this,[0,e[0]]),this},a._Transform.prototype.perspective=function(){var e=arguments;if(1!=e.length)throw"perspective requires 1 parameter.";var t=r.lengthToPx(e[0]);return this._updateValue("perspective",[new a._Length(t+"px")]),this},a._Complex=function(e){this.type="complex",this.parts=(" "+e+" ").split(a._floatRegex),this.numbers=e.match(a._floatRegex)},a._Complex.prototype.toString=function(){for(var e=this.parts[0],t=0;t<this.numbers.length;t++)e+=this.numbers[t]+this.parts[t+1];return e},a._Number=function(e){this.type="number",this.value=Number(e)},a._Number.prototype.toString=function(){return this.value},a._Unknown=function(e){this.type="unknown",this.value=e},a._Unknown.prototype.toString=function(){return this.value},u.prototype.toString=function(){if(a._lastBuilder.target){var e=null;if(a._lastBuilder.target.length>1){e=[];for(var t=0;t<a._lastBuilder.target.length;t++)e.push(a._lastBuilder.target[t].style[this.jsFriendlyProp])}else e=a._lastBuilder.target[0].style[this.jsFriendlyProp];return e}return null},u.prototype.val=function(){if(a._lastBuilder.target){var e=null;if(a._lastBuilder.target.length>1){e=null;for(var t=0;t<a._lastBuilder.target.length;t++)a._lastBuilder.target[0].style[this.jsFriendlyProp]?e.push(a._convertStyleIntoDotCssObject(a._lastBuilder.target[t].style[this.jsFriendlyProp],this.type)):e.push(null)}else e=a._lastBuilder.target[0].style[this.jsFriendlyProp]?a._convertStyleIntoDotCssObject(a._lastBuilder.target[0].style[this.jsFriendlyProp],this.type):null;return e}return null},u.prototype.animate=function(e,t,n,i){if(t=isNaN(t)?400:t||0,a._lastBuilder&&a._lastBuilder.target){!i&&n&&n.call&&n.apply&&(i=n,n=void 0);for(var o=0;o<a._lastBuilder.target.length;o++){var s,l=a._lastBuilder.target[o],u=null,c=null;if(c=a._convertStyleIntoDotCssObject(e,this.type),"transformation"==this.type&&(u=a._convertStyleIntoDotCssObject(l.style[this.jsFriendlyProp],this.type)),u||(u=a._convertStyleIntoDotCssObject(a._computedStyleOrActualStyle(l,this.jsFriendlyProp),this.type)),s=c.toString(),"length"==this.type){if(u.units!=c.units)if(0==u.length)u.units=c.units,u.length=0;else if(0==c.length)c.units=u.units,c.length=0;else{var d=r.lengthToPx(u.toString(),this.jsFriendlyProp,l),h=r.lengthToPx(c.toString(),this.jsFriendlyProp,l);u.length=d,u.units="px",c.length=h,c.units="px"}}else if("color"==this.type);else if("transformation"==this.type){for(var p="",f="",g=u.transformations.length-1,m=c.transformations.length-1;g>=0||m>=0;){var _="",b=null,y=null;if(g>=0&&m>=0&&u.transformations[g].transformation==c.transformations[m].transformation){var v=u.transformations[g],k=c.transformations[m];_=v.transformation,b=v.args,y=k.args,g--,m--}else if(g>=m){if(_=(v=u.transformations[g]).transformation,b=v.args,"matrix"==_)y=[1,0,0,1,0,0];else if("matrix3d"==_)y=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];else{var w=-1==_.indexOf("scale")?0:1;y=[];for(var x=0;x<b.length;x++)y.push(isNaN(b[x])?isNaN(b[x].angle)?isNaN(b[x].length)?0:new a._Length(0):new a._Angle(0):w)}g--}else{if(_=(k=c.transformations[m]).transformation,y=k.args,"matrix"==_)b=[1,0,0,1,0,0];else if("matrix3d"==_)b=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];else for(w=-1==_.indexOf("scale")?0:1,b=[],x=0;x<y.length;x++)b.push(isNaN(y[x])?isNaN(y[x].angle)?isNaN(y[x].length)?0:new a._Length(0):new a._Angle(0):w);m--}if(p=") "+p,f=") "+f,-1!=_.indexOf("rotate")){var C=b[b.length-1].angle,S=y[y.length-1].angle,N=r.angleSubtract(S,C);b[b.length-1].angle=S-N}for(x=b.length-1;x>=0;x--)p=","+b[o]+p,f=","+y[o]+f;p=_+"("+p.substring(1),f=_+"("+f.substring(1)}u=a._convertStyleIntoDotCssObject(p,"transformation"),c=a._convertStyleIntoDotCssObject(f,"transformation")}else if("number"==u.type&&"number"==c.type);else{if("complex"!=u.type||"complex"!=c.type){console.warn("Couldn't animate "+this.jsFriendlyProp+". Not a recognizable length, color, or number.");continue}if(!a._compareComplexDataTypes(u,c)){console.warn("Couldn't animate "+this.jsFriendlyProp+". Value mismatch.");continue}}a._animate(l,this.jsFriendlyProp,u.type||this.type,u,c,s,a._fxInterval,t,n||"ease",i)}}return a._lastBuilder},u.prototype.apply=Function.apply,u.prototype.call=Function.call,a._animate=function(e,t,n,i,o,s,l,u,c,d,h){if(!h||e.style[t]==h)if(u-l>0){switch(n){case"color":var p=Math.round(a._numberStep(i.r,o.r,l,u,c)),f=Math.round(a._numberStep(i.g,o.g,l,u,c)),g=Math.round(a._numberStep(i.b,o.b,l,u,c)),m=r.formatNumberValue(a._numberStep(i.a,o.a,l,u,c));r(e)[t](p,f,g,m);break;case"length":r(e)[t](r.formatNumberValue(a._numberStep(i.length,o.length,l,u,c),i.units)+i.units);break;case"transformation":for(var _="",b=0;b<i.transformations.length;b++){var y=i.transformations[b],v=o.transformations[b];_+=y.transformation+"(";for(var k=0;k<y.args.length;k++){var w=y.args[k],x=v.args[k],C=isNaN(w)?w.length||w.angle||w.value||0:w,S=isNaN(x)?x.length||x.angle||x.value||0:x,N=isNaN(w)?w.units:"";_+=r.formatNumberValue(a._numberStep(C,S,l,u,c),N)+N+","}_=_.substring(0,_.length-1),_+=") "}r(e)[t](_);break;default:switch(i.type){case"number":r(e)[t](r.formatNumberValue(a._numberStep(i.value,o.value,l,u,c)));break;case"complex":var T="";for(b=0;b<i.numbers.length;b++)T+=i.parts[b],T+=r.formatNumberValue(a._numberStep(i.numbers[b],o.numbers[b],l,u,c));T+=i.parts[i.parts.length-1],r(e)[t](T);break;default:console.warn("Unexpected data type for animation.")}}var O=window.performance&&window.performance.now?window.performance.now():null,A=e.style[t],P=function(r){var h=O?window.performance.now()-O:a._fxInterval;a._animate(e,t,n,i,o,s,l+h,u,c,d,A)};window.requestAnimationFrame?window.requestAnimationFrame(P):window.setTimeout(P,a._fxInterval)}else r(e)[t](s),d&&d()},a._numberStep=function(e,t,n,r,a){switch(e=Number(e),t=Number(t),a){case"geometric":case"exponential":case"ease":return e+.5*(1-Math.cos(Math.PI*(n/r)))*(t-e);case"linear":default:return e+n/r*(t-e)}},r.formatNumberValue=function(e,t){switch(t){case"px":return Math.round(e);default:return Math.round(100*e)/100}};var c={color:"color|background-Color|border-Bottom-Color|border-Color|border-Left-Color|border-Right-Color|border-Top-Color|text-Decoration-Color|outline-Color|column-Rule-Color",length:"background-Size|border-Bottom-Left-Radius|border-Bottom-Right-Radius|border-Bottom-Width|border-Image-Width|border-Left-Width|border-Radius|border-Right-Width|border-Top-Left-Radius|border-Top-Right-Radius|border-Top-Width|border-Width|bottom|height|left|margin|margin-Bottom|margin-Left|margin-Right|margin-Top|max-Height|max-Width|min-Height|min-Width|padding|padding-Bottom|padding-Left|padding-Right|padding-Top|right|top|width|line-Height|font-Size",url:"background-Image|border-Image|list-Style-Image|content|image-Orientation",transformation:"transformation",misc:"opacity|background|background-Attachment|background-Blend-Mode|background-Position|background-Repeat|background-Clip|background-Origin|border|border-Bottom|border-Bottom-Style|border-Image-Outset|border-Image-Repeat|border-Image-Slice|border-Image-Source|border-Left|border-Left-Style|border-Right|border-Right-Style|border-Style|border-Top|border-Top-Style|box-Decoration-Break|box-Shadow|clear|clip|display|float|overflow|box|overflow-X|overflow-Y|position|visibility|vertical-Align|z-Index|align-Content|align-Items|align-Self|flex|flex-Basis|flex-Direction|flex-Flow|flex-Grow|flex-Shrink|flex-Wrap|grid|grid-Area|grid-Auto-Columns|grid-auto-Rows|grid-Column|grid-Column-End|grid-Column-Gap|grid-Column-Start|grid-Gap|grid-Row|grid-Row-End|grid-Row-Gap|grid-Row-Start|grid-Template|grid-Template-Areas|grid-Template-Columns|grid-Template-Rows|justify-Content|order|hanging-Punctuation|hyphens|letter-Spacing|line-Break|overflow-Wrap|tab-Size|text-Align|text-Align-Last|text-Combine-Upright|text-Indent|text-Justify|text-Transform|white-Space|word-Break|word-Spacing|word-Wrap|text-Decoration|text-Decoration-Line|text-Decoration-Style|text-Shadow|text-Underline-Position|font|font-Family|font-Feature-Settings|font-Kerning|font-Language-Override|font-Size-Adjust|font-Stretch|font-Style|font-Synthesis|font-Variant|font-Variant-Alternates|font-Variant-Caps|font-Variant-East-Asian|font-Variant-Ligatures|font-Variant-Numeric|font-Variant-Position|font-Weight|direction|text-Orientation|text-Combine-Upright|unicode-Bidi|user-Select|writing-Mode|border-Collapse|border-Spacing|caption-Side|empty-Cells|table-Layout|counter-Increment|counter-Reset|list-Style|list-Style-Position|list-Style-Type|animation|animation-Delay|animation-Direction|animation-Duration|animation-Fill-Mode|animation-Iteration-Count|animation-Name|animation-Play-State|animation-Timing-Function|backface-Visibility|perspective2d|perspective-Origin|transform-Origin|transform-Style|transition|transition-Property|transition-Duration|transition-Timing-Function|transition-Delay|box-Sizing|cursor|ime-Mode|nav-Down|nav-Index|nav-Left|nav-Right|nav-Up|outline|outline-Offset|outline-Style|outline-Width|resize|text-Overflow|break-After|break-Before|break-Inside|column-Count|column-Fill|column-Gap|column-Rule|column-Rule-Style|column-Rule-Width|column-Span|column-Width|columns|widows|orphans|page-Break-After|page-Break-Before|page-Break-Inside|marks|quotes|filter|image-Rendering|image-Resolution|object-Fit|object-Position|mask|mask-Type|mark|mark-After|mark-Before|phonemes|rest|rest-After|rest-Before|voice-Balance|voice-Duration|voice-Pitch|voice-Pitch-Range|voice-Rate|voice-Stress|voice-Volume|marquee-Direction|marquee-Play-Count|marquee-Speed|marquee-Style|pointer-Events"},d=[{unit:"Em"},{unit:"Ex"},{unit:"Ch"},{unit:"Rem"},{unit:"Vw"},{unit:"Vh"},{unit:"Vmin"},{unit:"Vmax"},{unit:"%",jsName:"P"},{unit:"Cm"},{unit:"Mm"},{unit:"In"},{unit:"Px"},{unit:"Pt"},{unit:"Pc"}];for(var h in r.matrixMultiply3D=function(e,t){if(16!=e.length||16!=t.length)throw"3D matrices must be arrays of 16 length.";for(var n=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],r=0;r<4;r++)for(var a=0;a<4;a++)for(var i=0;i<4;i++)n[r+4*a]+=Number(e[r+4*i])*Number(t[i+4*a]);return n},r.angleToDeg=function(e){if(!isNaN(e))return Number(e);if(-1!=(e=e.trim()).indexOf("deg"))return r.formatNumberValue(Number(e.split("deg")[0]));if(-1!=e.indexOf("grad"))return r.formatNumberValue(.9*Number(e.split("grad")[0]));if(-1!=e.indexOf("rad"))return r.formatNumberValue(180*Number(e.split("rad")[0])/Math.PI);if(-1!=e.indexOf("turn"))return r.formatNumberValue(360*Number(e.split("turn")[0]));throw e+" does not have valid units for an angle."},r.lengthToPx=function(e,t,n){var i=Math.round,o=Number;if(!isNaN(e))return i(o(e));if((e=e.trim()).split,-1!=e.indexOf("px"))return i(o(e.split("px")[0]));if(-1!=e.indexOf("in"))return i(96*o(e.split("in")[0]));if(-1!=e.indexOf("pt"))return i(96*o(e.split("pt")[0])/72);if(-1!=e.indexOf("pc"))return i(16*o(e.split("pc")[0]));if(-1!=e.indexOf("cm"))return i(96*o(e.split("cm")[0])/2.54);if(-1!=e.indexOf("mm"))return i(96*o(e.split("mm")[0])/25.4);if(-1!=e.indexOf("q"))return i(96*o(e.split("q")[0])/101.6);if(-1!=e.indexOf("vw"))return i(.01*o(e.split("vw")[0])*Math.max(document.documentElement.clientWidth,window.innerWidth||0));if(-1!=e.indexOf("vh"))return i(.01*o(e.split("vh")[0])*Math.max(document.documentElement.clientHeight,window.innerHeight||0));if(-1!=e.indexOf("vmin"))return Math.min(r.lengthToPx(i(o(e.split("vmin")[0]+"vw"))),i(o(e.split("vmin")[0]+"vx")));if(-1!=e.indexOf("vmax"))return Math.max(r.lengthToPx(i(o(e.split("vmin")[0]+"vw"))),i(o(e.split("vmin")[0]+"vx")));if(-1!=e.indexOf("rem"))return i(o(e.split("rem")[0])*r.lengthToPx(a._computedStyleOrActualStyle(document.body,"fontSize")));if(t&&n){if(-1!=e.indexOf("em"))return i(o(e.split("em")[0])*r.lengthToPx(a._computedStyleOrActualStyle(n,"fontSize")));var s=null;switch(t){case"maxHeight":case"minHeight":case"top":case"bottom":case"height":if(!n.parentNode)throw"Cannot convert "+e+" "+t+" to px for an element that has no parent.";s=r.lengthToPx(a._computedStyleOrActualStyle(n.parentNode,"height"));break;case"maxHidth":case"minWidth":case"right":case"left":case"width":case"margin":case"marginTop":case"marginBottom":case"marginLeft":case"marginRight":case"padding":case"paddingTop":case"paddingBottom":case"paddingLeft":case"paddingRight":if(s=r.lengthToPx(a._computedStyleOrActualStyle(n.parentNode,"width")),!n.parentNode)throw"Cannot convert "+e+" "+t+" to px for an element that has no parent.";break;case"lineHeight":s=r.lengthToPx(a._computedStyleOrActualStyle(n,"fontSize"));break;case"fontSize":s=r.lengthToPx(a._computedStyleOrActualStyle(n,"height"));break;default:throw"Unable to convert the value "+e+" to px for "+t+"."}if(isNaN(s))throw"Convert the value "+e+" to px for "+t+" because the value it is relative to is not a number.";if(-1!=e.indexOf("%"))return i(.01*o(e.split("%")[0])*s);throw"The units of "+e+" are not recognized by dotcss."}throw e+" does not have valid units for an absolute length."},a._convertStyleIntoDotCssObject=function(e,t){return e instanceof Array||(e=[e]),"color"==t?new a._Color(e):"url"==t?new a._Url(e):"length"!=t||isNaN(e[0])&&(-1!=e[0].indexOf(" ")||e[0].replace(a._floatRegex,"")==e[0])?"transformation"==t?new a._Transform(e[0].toString()):""===e[0]||isNaN(e[0])&&(""+e[0]).replace(a._floatRegex,"")==e[0]?new a._Unknown(e[0]):isNaN(e[0])?new a._Complex(e[0]):new a._Number(e[0]):new a._Length(e[0])},a._compareComplexDataTypes=function(e,t){if("complex"!=e.type||"complex"!=t.type)return!1;if(e.numbers.length!=t.numbers.length)return!1;if(e.parts.length!=t.parts.length)return!1;for(var n=0;n<e.parts.length;n++)if(e.parts[n]!=t.parts[n])return!1;return!0},a._addPropFunctionToDotCssObject=function(e){r[e]=function(){var t=new s;return t[e].apply(t,arguments)}},a._makeFunction=function(e,t,n){if(l[t]=function(){if(0==arguments.length)return this;for(var r=[],i=0;i<arguments.length;i++)r.push(arguments[i]);var o=a._convertStyleIntoDotCssObject(r,n).toString(),s=e+":"+o+";";if(this.currentCss+=s,this.target)for(var l=0;l<this.target.length;l++){var u=this.target[l];"STYLE"==u.tagName?u.innerHTML=u.innerHTML.substring(0,u.innerHTML.length-1)+e+":"+o+";}":u.style[t]=o}return this},a._addPropFunctionToDotCssObject(t),"length"==n)for(var r=0;r<d.length;r++){var i=d[r];!function(e){l[t+(e.jsName||e.unit)]=function(){for(var n=0;n<arguments.length;n++)arguments[n]=arguments[n]+e.unit.toLowerCase();return l[t].apply(this,arguments)}}(i),a._addPropFunctionToDotCssObject(t+(i.jsName||i.unit))}for(var o in l[t].type=n,l[t].jsFriendlyProp=t,u.prototype)void 0===l[t][o]&&(l[t][o]=u.prototype[o])},a._makeTransformFunction=function(e){r[e]=function(){var t=new a._Transform;return t[e].apply(t,arguments)}},a._computedStyleOrActualStyle=function(e,t){return window.getComputedStyle(e)[t]||e.style[t]},a._modDeg=function(e){return e<0&&(e=360- -e%360),e%360},r.angleSubtract=function(e,t){e<0?e=360- -e%360:e%=360,t<0?t=360- -t%360:t%=360;var n=Math.abs(t-e)%360;return(n>180?360-n:n)*(e-t>=0&&e-t<=180||e-t<=-180&&e-t>=-360?1:-1)},r.url=function(e){return"url('"+e+"')"},r.rgb=function(e,t,n){return"rgb("+e+", "+t+", "+n+")"},r.rgba=function(e,t,n,r){return"rgba("+e+", "+t+", "+n+", "+r+")"},r.buildTransform=function(){return new a._Transform},r.cacheScopedStaticStyles=function(e){let t=o("*",e);for(let e of t)e.hasAttribute("style")&&e.setAttribute(n,e.getAttribute("style"))},r.clearDynamicStyles=function(e){let t=o("*",e);for(let e of t)e.removeAttribute("style"),e.hasAttribute(n)&&e.setAttribute("style",e.getAttribute(n))},r.scopeToEl=function(e){return i.unshift(e),this},r.unscope=function(){return i.shift(),this},c){let e=c[h].split("|");for(var p in e)a._makeFunction(e[p].toLowerCase(),e[p].replace(new RegExp("-","g"),""),h)}for(let e=0;e<d.length;e++)a._makeTransformFunction(d[e]);t.default=r}},t={},n=function n(r){var a=t[r];if(void 0!==a)return a.exports;var i=t[r]={exports:{}};return e[r].call(i.exports,i,i.exports,n),i.exports}(220);module.exports=n})();
@@ -0,0 +1 @@
1
+ /*! DOThtml (c) Joshua Sideris | dothtml.org/license */
package/lib/err.d.ts ADDED
@@ -0,0 +1,2 @@
1
+ declare var ERR: (c: string, ...p: Array<string>) => never;
2
+ export default ERR;
@@ -0,0 +1,10 @@
1
+ declare class _EventBus {
2
+ private _callbacks;
3
+ _checkAddEvent: (event: any) => any;
4
+ on(event: any, callback: any): void;
5
+ off(event: any, callback: any): void;
6
+ emit(event: any, ...args: any[]): void;
7
+ flush(event: any): void;
8
+ }
9
+ declare const EventBus: _EventBus;
10
+ export default EventBus;