copious-mail 0.0.0-stage → 0.9.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (182) hide show
  1. package/LICENSE +504 -0
  2. package/README.md +143 -2
  3. package/bin/index.js +345 -0
  4. package/client/copiousLogo.svg +123 -0
  5. package/client/hosted.html +5259 -0
  6. package/client/mail_styles.css +40 -0
  7. package/client/mikado.bundle.debug.js +1406 -0
  8. package/client/mikado.bundle.min.js +68 -0
  9. package/client/mikado.bundle.module.debug.js +1401 -0
  10. package/client/mikado.bundle.module.min.js +67 -0
  11. package/client/mikado.bundle.profiler.debug.js +1490 -0
  12. package/client/mikado.es5.debug.js +1995 -0
  13. package/client/mikado.es5.min.js +85 -0
  14. package/client/mikado.light.debug.js +535 -0
  15. package/client/mikado.light.min.js +29 -0
  16. package/client/mikado.light.module.debug.js +530 -0
  17. package/data/user_list.db +14 -0
  18. package/index.html +7242 -0
  19. package/index.js +5 -0
  20. package/jsconfig.json +32 -0
  21. package/lib/mail_repo_bridge_ops.js +1177 -0
  22. package/lib/utils.js +70 -0
  23. package/lib/websocket_con.js +249 -0
  24. package/mail_bridge.conf +10 -0
  25. package/package.json +41 -5
  26. package/svelte-src/App.svelte +2513 -0
  27. package/svelte-src/ContactGrid.svelte +98 -0
  28. package/svelte-src/FloatWindow.svelte +181 -0
  29. package/svelte-src/MessageDisplay.svelte +230 -0
  30. package/svelte-src/MessageEditor.svelte +664 -0
  31. package/svelte-src/MessageListEditor.svelte +133 -0
  32. package/svelte-src/Thing.svelte +190 -0
  33. package/svelte-src/ThingFull.svelte +117 -0
  34. package/svelte-src/ipfs_profile_proxy.js +923 -0
  35. package/svelte-src/main.js +10 -0
  36. package/svelte-src/search_box.js +69 -0
  37. package/svelte-src/utilities.js +180 -0
  38. package/test/c +28 -0
  39. package/test/copiousLogo.svg +123 -0
  40. package/test/index.html +4408 -0
  41. package/test/index.js +244 -0
  42. package/test/mail_styles.css +40 -0
  43. package/test/mikado.bundle.debug.js +1406 -0
  44. package/test/mikado.bundle.min.js +68 -0
  45. package/test/mikado.bundle.module.debug.js +1401 -0
  46. package/test/mikado.bundle.module.min.js +67 -0
  47. package/test/mikado.bundle.profiler.debug.js +1490 -0
  48. package/test/mikado.es5.debug.js +1995 -0
  49. package/test/mikado.es5.min.js +85 -0
  50. package/test/mikado.light.debug.js +535 -0
  51. package/test/mikado.light.min.js +29 -0
  52. package/test/mikado.light.module.debug.js +530 -0
  53. package/test/tpl/partial/attachment_edit.es5.js +1 -0
  54. package/test/tpl/partial/attachment_edit.html +5 -0
  55. package/test/tpl/partial/attachment_edit.js +1 -0
  56. package/test/tpl/partial/attachment_view.es5.js +1 -0
  57. package/test/tpl/partial/attachment_view.html +1 -0
  58. package/test/tpl/partial/attachment_view.js +1 -0
  59. package/test/tpl/partial/contact_list.es5.js +1 -0
  60. package/test/tpl/partial/contact_list.html +9 -0
  61. package/test/tpl/partial/contact_list.js +1 -0
  62. package/test/tpl/partial/draft_list.es5.js +1 -0
  63. package/test/tpl/partial/draft_list.html +8 -0
  64. package/test/tpl/partial/draft_list.js +1 -0
  65. package/test/tpl/partial/inbox_list.es5.js +1 -0
  66. package/test/tpl/partial/inbox_list.html +7 -0
  67. package/test/tpl/partial/inbox_list.js +1 -0
  68. package/test/tpl/partial/notify_list.es5.js +1 -0
  69. package/test/tpl/partial/notify_list.html +8 -0
  70. package/test/tpl/partial/notify_list.js +1 -0
  71. package/test/tpl/partial/sent_list.es5.js +1 -0
  72. package/test/tpl/partial/sent_list.html +7 -0
  73. package/test/tpl/partial/sent_list.js +1 -0
  74. package/test/tpl/partial/spam_list.es5.js +1 -0
  75. package/test/tpl/partial/spam_list.html +8 -0
  76. package/test/tpl/partial/spam_list.js +1 -0
  77. package/test/tpl/partial/trash_list.es5.js +1 -0
  78. package/test/tpl/partial/trash_list.html +7 -0
  79. package/test/tpl/partial/trash_list.js +1 -0
  80. package/test/tpl/partial/user.es5.js +1 -0
  81. package/test/tpl/partial/user.html +18 -0
  82. package/test/tpl/partial/user.js +1 -0
  83. package/tools/jsdoc.conf +47 -0
  84. package/tools/templates/docdash/publish.js +843 -0
  85. package/tools/templates/docdash/static/fonts/Montserrat/Montserrat-Bold.eot +0 -0
  86. package/tools/templates/docdash/static/fonts/Montserrat/Montserrat-Bold.ttf +0 -0
  87. package/tools/templates/docdash/static/fonts/Montserrat/Montserrat-Bold.woff +0 -0
  88. package/tools/templates/docdash/static/fonts/Montserrat/Montserrat-Bold.woff2 +0 -0
  89. package/tools/templates/docdash/static/fonts/Montserrat/Montserrat-Regular.eot +0 -0
  90. package/tools/templates/docdash/static/fonts/Montserrat/Montserrat-Regular.ttf +0 -0
  91. package/tools/templates/docdash/static/fonts/Montserrat/Montserrat-Regular.woff +0 -0
  92. package/tools/templates/docdash/static/fonts/Montserrat/Montserrat-Regular.woff2 +0 -0
  93. package/tools/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-light-webfont.eot +0 -0
  94. package/tools/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-light-webfont.svg +978 -0
  95. package/tools/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-light-webfont.ttf +0 -0
  96. package/tools/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-light-webfont.woff +0 -0
  97. package/tools/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-light-webfont.woff2 +0 -0
  98. package/tools/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-regular-webfont.eot +0 -0
  99. package/tools/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-regular-webfont.svg +1049 -0
  100. package/tools/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-regular-webfont.ttf +0 -0
  101. package/tools/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-regular-webfont.woff +0 -0
  102. package/tools/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-regular-webfont.woff2 +0 -0
  103. package/tools/templates/docdash/static/scripts/collapse.js +67 -0
  104. package/tools/templates/docdash/static/scripts/commonNav.js +28 -0
  105. package/tools/templates/docdash/static/scripts/linenumber.js +25 -0
  106. package/tools/templates/docdash/static/scripts/nav.js +12 -0
  107. package/tools/templates/docdash/static/scripts/polyfill.js +4 -0
  108. package/tools/templates/docdash/static/scripts/prettify/Apache-License-2.0.txt +202 -0
  109. package/tools/templates/docdash/static/scripts/prettify/lang-css.js +2 -0
  110. package/tools/templates/docdash/static/scripts/prettify/prettify.js +28 -0
  111. package/tools/templates/docdash/static/scripts/search.js +99 -0
  112. package/tools/templates/docdash/static/styles/jsdoc.css +803 -0
  113. package/tools/templates/docdash/static/styles/prettify.css +80 -0
  114. package/tools/templates/docdash/tmpl/augments.tmpl +10 -0
  115. package/tools/templates/docdash/tmpl/container.tmpl +203 -0
  116. package/tools/templates/docdash/tmpl/details.tmpl +152 -0
  117. package/tools/templates/docdash/tmpl/example.tmpl +2 -0
  118. package/tools/templates/docdash/tmpl/examples.tmpl +13 -0
  119. package/tools/templates/docdash/tmpl/exceptions.tmpl +32 -0
  120. package/tools/templates/docdash/tmpl/layout.tmpl +102 -0
  121. package/tools/templates/docdash/tmpl/mainpage.tmpl +15 -0
  122. package/tools/templates/docdash/tmpl/members.tmpl +38 -0
  123. package/tools/templates/docdash/tmpl/method.tmpl +132 -0
  124. package/tools/templates/docdash/tmpl/modifies.tmpl +14 -0
  125. package/tools/templates/docdash/tmpl/namespace.tmpl +133 -0
  126. package/tools/templates/docdash/tmpl/params.tmpl +132 -0
  127. package/tools/templates/docdash/tmpl/properties.tmpl +107 -0
  128. package/tools/templates/docdash/tmpl/returns.tmpl +19 -0
  129. package/tools/templates/docdash/tmpl/source.tmpl +8 -0
  130. package/tools/templates/docdash/tmpl/tutorial.tmpl +19 -0
  131. package/tools/templates/docdash/tmpl/type.tmpl +26 -0
  132. package/tools/templates/templates/docdash/publish.js +843 -0
  133. package/tools/templates/templates/docdash/static/fonts/Montserrat/Montserrat-Bold.eot +0 -0
  134. package/tools/templates/templates/docdash/static/fonts/Montserrat/Montserrat-Bold.ttf +0 -0
  135. package/tools/templates/templates/docdash/static/fonts/Montserrat/Montserrat-Bold.woff +0 -0
  136. package/tools/templates/templates/docdash/static/fonts/Montserrat/Montserrat-Bold.woff2 +0 -0
  137. package/tools/templates/templates/docdash/static/fonts/Montserrat/Montserrat-Regular.eot +0 -0
  138. package/tools/templates/templates/docdash/static/fonts/Montserrat/Montserrat-Regular.ttf +0 -0
  139. package/tools/templates/templates/docdash/static/fonts/Montserrat/Montserrat-Regular.woff +0 -0
  140. package/tools/templates/templates/docdash/static/fonts/Montserrat/Montserrat-Regular.woff2 +0 -0
  141. package/tools/templates/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-light-webfont.eot +0 -0
  142. package/tools/templates/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-light-webfont.svg +978 -0
  143. package/tools/templates/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-light-webfont.ttf +0 -0
  144. package/tools/templates/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-light-webfont.woff +0 -0
  145. package/tools/templates/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-light-webfont.woff2 +0 -0
  146. package/tools/templates/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-regular-webfont.eot +0 -0
  147. package/tools/templates/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-regular-webfont.svg +1049 -0
  148. package/tools/templates/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-regular-webfont.ttf +0 -0
  149. package/tools/templates/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-regular-webfont.woff +0 -0
  150. package/tools/templates/templates/docdash/static/fonts/Source-Sans-Pro/sourcesanspro-regular-webfont.woff2 +0 -0
  151. package/tools/templates/templates/docdash/static/scripts/collapse.js +67 -0
  152. package/tools/templates/templates/docdash/static/scripts/commonNav.js +28 -0
  153. package/tools/templates/templates/docdash/static/scripts/linenumber.js +25 -0
  154. package/tools/templates/templates/docdash/static/scripts/nav.js +12 -0
  155. package/tools/templates/templates/docdash/static/scripts/polyfill.js +4 -0
  156. package/tools/templates/templates/docdash/static/scripts/prettify/Apache-License-2.0.txt +202 -0
  157. package/tools/templates/templates/docdash/static/scripts/prettify/lang-css.js +2 -0
  158. package/tools/templates/templates/docdash/static/scripts/prettify/prettify.js +28 -0
  159. package/tools/templates/templates/docdash/static/scripts/search.js +99 -0
  160. package/tools/templates/templates/docdash/static/styles/jsdoc.css +803 -0
  161. package/tools/templates/templates/docdash/static/styles/prettify.css +80 -0
  162. package/tools/templates/templates/docdash/tmpl/augments.tmpl +10 -0
  163. package/tools/templates/templates/docdash/tmpl/container.tmpl +203 -0
  164. package/tools/templates/templates/docdash/tmpl/details.tmpl +152 -0
  165. package/tools/templates/templates/docdash/tmpl/example.tmpl +2 -0
  166. package/tools/templates/templates/docdash/tmpl/examples.tmpl +13 -0
  167. package/tools/templates/templates/docdash/tmpl/exceptions.tmpl +32 -0
  168. package/tools/templates/templates/docdash/tmpl/layout.tmpl +102 -0
  169. package/tools/templates/templates/docdash/tmpl/mainpage.tmpl +15 -0
  170. package/tools/templates/templates/docdash/tmpl/members.tmpl +38 -0
  171. package/tools/templates/templates/docdash/tmpl/method.tmpl +132 -0
  172. package/tools/templates/templates/docdash/tmpl/modifies.tmpl +14 -0
  173. package/tools/templates/templates/docdash/tmpl/namespace.tmpl +133 -0
  174. package/tools/templates/templates/docdash/tmpl/params.tmpl +132 -0
  175. package/tools/templates/templates/docdash/tmpl/properties.tmpl +107 -0
  176. package/tools/templates/templates/docdash/tmpl/returns.tmpl +19 -0
  177. package/tools/templates/templates/docdash/tmpl/source.tmpl +8 -0
  178. package/tools/templates/templates/docdash/tmpl/tutorial.tmpl +19 -0
  179. package/tools/templates/templates/docdash/tmpl/type.tmpl +26 -0
  180. package/tpl/partial/user.es5.js +1 -0
  181. package/tpl/partial/user.html +10 -0
  182. package/tpl/partial/user.js +1 -0
@@ -0,0 +1,535 @@
1
+ /**!
2
+ * Mikado.js v0.8.400 (Light/Debug)
3
+ * Copyright 2019-2024 Nextapps GmbH
4
+ * Author: Thomas Wilkerling
5
+ * Licence: Apache-2.0
6
+ * https://github.com/nextapps-de/mikado
7
+ */
8
+ (function(){'use strict';
9
+ var n;
10
+ function p(a, b, c) {
11
+ let d;
12
+ c && (d = a._mkc) && (a._mkc = null);
13
+ const h = b.length, k = [], e = {};
14
+ for (let l = 0, q, m, r, v, w = null; l < h; l++) {
15
+ q = b[l];
16
+ if (m = q.v) {
17
+ if (v = r = e[m], !v) {
18
+ a: {
19
+ var f = a, g = m;
20
+ for (let u = 0, A = g.length, y = ""; u < A; u++) {
21
+ const t = g[u];
22
+ y += t;
23
+ if (e[y]) {
24
+ f = e[y];
25
+ } else {
26
+ if (">" === t) {
27
+ f = f.firstChild;
28
+ } else {
29
+ if ("|" === t) {
30
+ r = [f.firstChild, f];
31
+ break a;
32
+ }
33
+ if ("@" === t) {
34
+ r = [f.style, f];
35
+ break a;
36
+ }
37
+ f = f.nextSibling;
38
+ }
39
+ e[y] = f;
40
+ }
41
+ }
42
+ r = [f];
43
+ }
44
+ v = r[0];
45
+ r = r[1] || v;
46
+ }
47
+ } else {
48
+ v = r = a;
49
+ }
50
+ c && (w = d ? d[l] : {}, r._mkc = w);
51
+ k[l] = new x(w, v, "");
52
+ }
53
+ return a._mkp = k;
54
+ }
55
+ function z(a, b, c, d, h, k) {
56
+ const e = h || (b.tag ? b.svg ? document.createElementNS("http://www.w3.org/2000/svg", b.tag) : document.createElement(b.tag) : document.createTextNode(b.text));
57
+ let f, g;
58
+ if (g = b.class) {
59
+ "object" === typeof g ? c.push(new x(f = {_c:""}, e, d)) : h || (e.className = g);
60
+ }
61
+ if (g = b.attr) {
62
+ for (const l in g) {
63
+ let q = g[l];
64
+ "object" === typeof q ? (f || c.push(new x(f = {}, e, d)), f["_a" + l] = !1) : h || e.setAttribute(l, q);
65
+ }
66
+ }
67
+ if (g = b.style) {
68
+ "object" === typeof g ? (c.push(new x(f || (f = {}), e.style, d + "@")), f._s = "") : h || (e.style.cssText = g);
69
+ }
70
+ if (g = b.text) {
71
+ "object" === typeof g ? (a = e, g = g[0], b.tag ? (d += "|", a = !h && e.firstChild, a || (a = document.createTextNode(g), e.appendChild(a))) : f = {}, (f || (f = {}))._t = g, c.push(new x(f, a, d))) : h || (b.tag ? e.textContent = g : e.nodeValue = g);
72
+ } else if (g = b.child) {
73
+ if (h && (h = h.firstChild, !h)) {
74
+ return console.warn("Hydration failed of template '" + a.name + "' because the existing DOM structure was incompatible. Falls back to factory construction instead."), null;
75
+ }
76
+ g.constructor !== Array && (g = [g]);
77
+ for (let l = 0, q, m = g.length; l < m; l++) {
78
+ if (q = g[l], d = l ? d + "+" : d + ">", b = z(a, q, c, d, h, 1), h) {
79
+ if (l < m - 1 && (h = h.nextSibling, !h)) {
80
+ return console.warn("Hydration failed of template '" + a.name + "' because the existing DOM structure was incompatible. Falls back to factory construction instead."), null;
81
+ }
82
+ } else {
83
+ e.appendChild(b);
84
+ }
85
+ }
86
+ } else if (g = b.html) {
87
+ "object" === typeof g ? (f || c.push(new x(f = {}, e, d)), f._h = "") : h || (e.innerHTML = g);
88
+ } else if (g = b.inc) {
89
+ f || c.push(new x(null, e, d));
90
+ let l;
91
+ if ("string" === typeof g) {
92
+ l = C[g];
93
+ if (!l) {
94
+ throw Error("The partial template '" + g + "' which is included by the root template '" + a.name + "' was not registered. When using named includes make sure you register all your includes by Mikado.register(tpl) before instantiating the Mikado view instance.");
95
+ }
96
+ if (!(l instanceof D)) {
97
+ d = l[0];
98
+ if (b = l[1]) {
99
+ b.async = !1, h && (b.root = h, b.hydrate = !0);
100
+ }
101
+ C[g] = l = new D(d, b);
102
+ }
103
+ } else if (1 !== g) {
104
+ d = a.inc.length;
105
+ if (!a.tpl.fn.length) {
106
+ throw Error("The template '" + a.name + "|" + d + "' has conflicts. It should provide a handler entry, but wasn't found.");
107
+ }
108
+ l = new D({name:a.name + "|" + d, tpl:g, key:g.key, cache:g.cache, fn:a.tpl.fn}, {recycle:a.recycle, cache:a.cache, pool:!!a.pool, state:a.state, mount:e, hydrate:!!h});
109
+ }
110
+ 1 !== g && a.inc.push(l);
111
+ }
112
+ f && (e._mkc = f);
113
+ k || (e._mkp = c);
114
+ return e;
115
+ }
116
+ const E = {checked:1, selected:1, hidden:1};
117
+ function x(a, b, c) {
118
+ this.c = a;
119
+ this.n = b;
120
+ this.v = c;
121
+ }
122
+ n = x.prototype;
123
+ n._a = function(a, b, c, d, h) {
124
+ if (this.c) {
125
+ if (d) {
126
+ if (h || 0 === h) {
127
+ d = d[h] || (d[h] = {});
128
+ }
129
+ d["_a" + a] = b;
130
+ }
131
+ if (this.c["_a" + a] === b) {
132
+ return;
133
+ }
134
+ this.c["_a" + a] = b;
135
+ }
136
+ !E[a] || c && "selected" === a ? !1 === b ? this.n.removeAttribute(a) : this.n.setAttribute(a, b) : this.n[a] = b;
137
+ };
138
+ n._t = function(a, b, c) {
139
+ if (this.c) {
140
+ if (b) {
141
+ if (c || 0 === c) {
142
+ b = b[c] || (b[c] = {});
143
+ }
144
+ b._t = a;
145
+ }
146
+ if (this.c._t === a) {
147
+ return;
148
+ }
149
+ this.c._t = a;
150
+ }
151
+ this.n.nodeValue = a;
152
+ };
153
+ n._c = function(a, b, c) {
154
+ if (this.c) {
155
+ if (b) {
156
+ if (c || 0 === c) {
157
+ b = b[c] || (b[c] = {});
158
+ }
159
+ b._c = a;
160
+ }
161
+ if (this.c._c === a) {
162
+ return;
163
+ }
164
+ this.c._c = a;
165
+ }
166
+ this.n.className = a;
167
+ };
168
+ n._s = function(a, b, c) {
169
+ if (this.c) {
170
+ if (b) {
171
+ if (c || 0 === c) {
172
+ b = b[c] || (b[c] = {});
173
+ }
174
+ b._s = a;
175
+ }
176
+ if (this.c._s === a) {
177
+ return;
178
+ }
179
+ this.c._s = a;
180
+ }
181
+ this.n.cssText = a;
182
+ };
183
+ n._h = function(a, b, c) {
184
+ if (this.c) {
185
+ if (b) {
186
+ if (c || 0 === c) {
187
+ b = b[c] || (b[c] = {});
188
+ }
189
+ b._h = a;
190
+ }
191
+ if (this.c._h === a) {
192
+ return;
193
+ }
194
+ this.c._h = a;
195
+ }
196
+ this.n.innerHTML = a;
197
+ };
198
+ const C = Object.create(null);
199
+ function D(a, b = {}) {
200
+ if (!(this instanceof D)) {
201
+ return new D(a, b);
202
+ }
203
+ if ("string" === typeof a) {
204
+ var c = C[a];
205
+ if (!c) {
206
+ throw Error("The template '" + a + "' is not registered.");
207
+ }
208
+ if (c instanceof D) {
209
+ return c;
210
+ }
211
+ a = c[0];
212
+ b || (b = c[1]);
213
+ }
214
+ if (!a) {
215
+ throw Error("Initialization Error: Template is not defined.");
216
+ }
217
+ if (!a.tpl) {
218
+ throw Error("Initialization Error: Template isn't supported.");
219
+ }
220
+ this.g = [];
221
+ this.length = 0;
222
+ this.root = b.root || b.mount || null;
223
+ this.recycle = !!b.recycle;
224
+ this.state = b.state || {};
225
+ this.shadow = b.shadow || !1;
226
+ this.key = a.key || "";
227
+ this.j = {};
228
+ c = a.fn;
229
+ a.m || c && (a.m = c.slice());
230
+ this.apply = c && c.pop();
231
+ this.tpl = a;
232
+ this.name = a.name;
233
+ this.inc = [];
234
+ this.pool = (c = this.recycle || !!this.key) && b.pool ? 1 : 0;
235
+ this.l = [];
236
+ this.h = new Map();
237
+ this.cache = c && (a.cache || !!b.cache);
238
+ this.root ? this.mount(this.root, b.hydrate) : this.i = null;
239
+ }
240
+ n = D.prototype;
241
+ n.mount = function(a, b) {
242
+ if (!a) {
243
+ throw Error("No target was passed to .mount()");
244
+ }
245
+ this.shadow && (a = a.shadowRoot || a.attachShadow({mode:"open"}));
246
+ const c = a._mki;
247
+ var d = this.root !== a;
248
+ if (c === this) {
249
+ if (!d) {
250
+ return this;
251
+ }
252
+ this.g = a._mkd;
253
+ this.length = this.g.length;
254
+ } else if (c) {
255
+ c.clear(), a._mkd = this.g = [], this.length = 0, a.firstChild && (a.textContent = "");
256
+ } else {
257
+ if (b) {
258
+ var h = a.children;
259
+ const k = h.length, e = Array(k);
260
+ for (let f = 0; f < k; f++) {
261
+ e[f] = h[f];
262
+ }
263
+ this.g = e;
264
+ this.length = this.g.length;
265
+ } else {
266
+ this.g = [], this.length = 0, a.firstChild && (a.textContent = "");
267
+ }
268
+ a._mkd = this.g;
269
+ }
270
+ if (this.key) {
271
+ if (d && this.root && (this.root._mkl = this.j), c === this) {
272
+ this.j = a._mkl;
273
+ } else {
274
+ d = {};
275
+ if (!c && b && this.length) {
276
+ for (let k = 0, e, f; k < this.length; k++) {
277
+ e = this.g[k], (f = e.getAttribute("key")) || console.warn("The template '" + this.name + "' runs in keyed mode, but the hydrated component don't have the attribute 'key' exported."), e._mkk = f, d[f] = e;
278
+ }
279
+ }
280
+ a._mkl = this.j = d;
281
+ }
282
+ }
283
+ a._mki = this;
284
+ this.root = a;
285
+ this.i || (b && this.length && (this.i = this.g[0].cloneNode(!0), z(this, this.tpl.tpl, [], "", this.i) && F(this)), this.tpl && (this.i = z(this, this.tpl.tpl, [], ""), F(this)));
286
+ return this;
287
+ };
288
+ function F(a) {
289
+ a.tpl.m && (a.tpl.fn = a.tpl.m, a.tpl.m = null);
290
+ a.tpl = null;
291
+ }
292
+ n.render = function(a, b) {
293
+ if (!this.root) {
294
+ throw Error("Template was not mounted or root was not found.");
295
+ }
296
+ if (this.root._mki !== this) {
297
+ throw Error("Another template is already assigned to this root. Please use '.mount(root_element)' before calling '.render()' to switch the context of a template.");
298
+ }
299
+ var c = this.length;
300
+ if (!a && !this.apply) {
301
+ return this.g[0] || this.add(), this;
302
+ }
303
+ if (Array.isArray(a)) {
304
+ var d = a.length;
305
+ if (!d) {
306
+ return this.remove(0, c);
307
+ }
308
+ } else {
309
+ a = [a], d = 1;
310
+ }
311
+ var h = this.key;
312
+ !c || h || this.recycle || (this.remove(0, c), c = 0);
313
+ var k = c < d ? c : d, e = 0;
314
+ if (e < k) {
315
+ for (let l, q; e < k; e++) {
316
+ l = this.g[e];
317
+ q = a[e];
318
+ if (h && l._mkk !== q[h]) {
319
+ c = this.g;
320
+ d = this.j;
321
+ h = this.key;
322
+ k = a.length;
323
+ let m = c.length, r = m > k ? m : k, v = 0;
324
+ for (e || (e = 0); e < r; e++) {
325
+ var f = void 0;
326
+ if (e < k) {
327
+ const w = a[e];
328
+ var g = e >= m;
329
+ let u, A, y;
330
+ if (!g && (u = c[e], A = w[h], y = u._mkk, y === A)) {
331
+ this.update(u, w, b, e);
332
+ continue;
333
+ }
334
+ if (g || !d[A]) {
335
+ g || !this.pool ? (m++, r = m > k ? m : k, this.add(w, b, e)) : this.replace(u, w, b, e);
336
+ continue;
337
+ }
338
+ let t, B;
339
+ for (g = e + 1; g < r; g++) {
340
+ if (!t && g < m && c[g]._mkk === A && (t = g + 1), !B && g < k && a[g][h] === y && (B = g + 1), t && B) {
341
+ t >= B + v ? (f = c[t - 1], this.root.insertBefore(f, u), this.update(f, w, b, e), t === B ? (1 < g - e && this.root.insertBefore(u, c[t]), c[e] = c[g], (c[g] = u) || console.error("reconcile.error 1")) : (t - 1 === e && console.error("reconcile.error 2"), G(c, t - 1, e), v++)) : (f = B - 1 + v, this.root.insertBefore(u, c[f] || null), (f > m ? m : f) - 1 === e && console.error("reconcile.error 3"), G(c, e, (f > m ? m : f) - 1), v--, e--);
342
+ f = 1;
343
+ break;
344
+ }
345
+ }
346
+ }
347
+ f || (this.remove(e), m--, r = m > k ? m : k, e--);
348
+ }
349
+ return this;
350
+ }
351
+ this.update(l, q, b, e);
352
+ }
353
+ }
354
+ if (e < d) {
355
+ for (; e < d; e++) {
356
+ this.add(a[e], b);
357
+ }
358
+ } else {
359
+ d < c && this.remove(d, c - d);
360
+ }
361
+ return this;
362
+ };
363
+ n.replace = function(a, b, c, d) {
364
+ "undefined" === typeof d && ("number" === typeof a ? (d = 0 > a ? this.length + a : a, a = this.g[d]) : d = this.index(a));
365
+ var h;
366
+ if (this.key) {
367
+ var k = b[this.key];
368
+ if (h = this.j[k]) {
369
+ if (h !== a) {
370
+ k = this.index(h);
371
+ const e = k < d ? h : a, f = k < d ? a : h;
372
+ let g = this.g[k < d ? k + 1 : d + 1];
373
+ this.g[d] = h;
374
+ this.g[k] = a;
375
+ g !== f ? this.root.insertBefore(e, f) : g = e;
376
+ this.root.insertBefore(f, g);
377
+ }
378
+ } else {
379
+ this.pool && (h = this.h.get(k)) && (this.h.delete(k), H(this, a), this.g[d] = h, a.replaceWith(h));
380
+ }
381
+ } else {
382
+ this.recycle && (h = a);
383
+ }
384
+ h ? this.apply && this.apply(b, c || this.state, d, h._mkp || p(h, this.i._mkp, this.cache)) : (b = this.create(b, c, d, 1), (this.key || this.pool) && H(this, a), this.g[d] = b, a.replaceWith(b));
385
+ return this;
386
+ };
387
+ n.update = function(a, b, c, d) {
388
+ if (!this.apply) {
389
+ return "number" !== typeof d && console.warn("The template '" + this.name + "' is a static template and should not be updated. Alternatively you can use .replace() to switch contents."), this;
390
+ }
391
+ "undefined" === typeof d && ("number" === typeof a ? (d = 0 > a ? this.length + a - 1 : a, a = this.g[d]) : d = this.index(a));
392
+ this.apply(b, c || this.state, d, a._mkp || p(a, this.i._mkp, this.cache));
393
+ return this;
394
+ };
395
+ n.create = function(a, b, c, d) {
396
+ const h = this.key, k = h && a[h];
397
+ let e;
398
+ var f;
399
+ let g, l;
400
+ this.pool && (h ? (f = this.h) && (e = f.get(k)) && (f.delete(k), l = 1) : (f = this.l) && f.length && (e = f.pop()));
401
+ e || (e = g = this.i, g || (this.i = e = g = z(this, this.tpl.tpl, [], ""), F(this)));
402
+ let q;
403
+ this.apply && (f = e._mkp || p(e, this.i._mkp, !!g || this.cache), q = g && this.cache && Array(f.length), this.apply(a, b || this.state, c, f, !!g, q));
404
+ g && (e = g.cloneNode(!0), q && !0 !== q && (e._mkc = q));
405
+ h && (l || (e._mkk = k), d && (this.j[k] = e));
406
+ return e;
407
+ };
408
+ n.add = function(a, b, c) {
409
+ let d;
410
+ "number" === typeof b ? (c = 0 > b ? this.length + b : b, b = null, d = c < this.length) : "number" === typeof c ? (0 > c && (c += this.length), d = c < this.length) : c = this.length;
411
+ a = this.create(a, b, c, 1);
412
+ d ? (this.root.insertBefore(a, this.g[c]), G(this.g, this.length - 1, c, a), this.length++) : (this.root.appendChild(a), this.g[this.length++] = a);
413
+ this.key && this.pool && this.pool < this.length && (this.pool = this.length);
414
+ return this;
415
+ };
416
+ function G(a, b, c, d) {
417
+ const h = d || a[b];
418
+ d && b++;
419
+ if (b < c) {
420
+ for (; b < c; b++) {
421
+ a[b] = a[b + 1];
422
+ }
423
+ } else {
424
+ for (; b > c; b--) {
425
+ a[b] = a[b - 1];
426
+ }
427
+ }
428
+ a[c] = h;
429
+ }
430
+ n.append = function(a, b, c) {
431
+ let d;
432
+ "number" === typeof b ? (c = 0 > b ? this.length + b : b, b = null, d = 1) : "number" === typeof c && (0 > c && (c += this.length), d = 1);
433
+ const h = a.length;
434
+ for (let k = 0; k < h; k++) {
435
+ this.add(a[k], b, d ? c++ : null);
436
+ }
437
+ return this;
438
+ };
439
+ n.clear = function() {
440
+ this.length && this.remove(0, this.length);
441
+ return this;
442
+ };
443
+ n.remove = function(a, b) {
444
+ let c = this.length;
445
+ c && a && ("number" !== typeof a ? a = this.index(a) : 0 > a && (a = c + a));
446
+ if (!c || a >= c) {
447
+ return this;
448
+ }
449
+ b ? 0 > b && (a -= b + 1, 0 > a && (a = 0), b *= -1) : b = 1;
450
+ let d;
451
+ !a && b >= c ? (d = this.g, b = d.length, this.root.textContent = "", this.root._mkd = this.g = [], c = 0) : (d = this.g.splice(a, b), c -= b);
452
+ const h = this.pool && !this.key, k = this.key || this.pool;
453
+ (a = this.key && this.pool) && b >= a && (this.h = new Map(), a = 0);
454
+ for (let e = 0, f; e < b; e++) {
455
+ f = d[h ? b - e - 1 : e], c && f.remove(), k && H(this, f, 1);
456
+ }
457
+ if (a && 0 < (a = this.h.size - a)) {
458
+ for (b = this.h.keys(); a--;) {
459
+ this.h.delete(b.next().value);
460
+ }
461
+ }
462
+ this.length = c;
463
+ return this;
464
+ };
465
+ n.index = function(a) {
466
+ return a ? this.g.indexOf(a) : -1;
467
+ };
468
+ n.node = function(a) {
469
+ return this.g[a];
470
+ };
471
+ function H(a, b, c) {
472
+ let d;
473
+ a.key && (d = b._mkk, a.j[d] = null);
474
+ a.pool && (d ? (a.h.set(d, b), !c && a.h.size > a.pool && a.h.delete(a.h.keys().next().value)) : a.l[a.l.length] = b);
475
+ }
476
+ n.flush = function() {
477
+ this.l = [];
478
+ this.h = new Map();
479
+ return this;
480
+ };
481
+ n.destroy = function() {
482
+ for (let a = 0, b; a < this.inc.length; a++) {
483
+ b = this.inc[a], C[b.name] || b.destroy();
484
+ }
485
+ this.key && (this.root && (this.root._mkl = null), this.j = null);
486
+ this.root && (this.root._mkd = this.root._mki = null);
487
+ this.h = this.l = this.g = this.root = this.tpl = this.apply = this.inc = this.state = this.i = null;
488
+ };
489
+ D.once = function(a, b, c, d) {
490
+ if (!a) {
491
+ throw Error("Root element is not defined.");
492
+ }
493
+ if (!b) {
494
+ throw Error("Template is not defined.");
495
+ }
496
+ if (c || b.fn) {
497
+ b = new D(b);
498
+ if (c && Array.isArray(c)) {
499
+ for (let h = 0; h < c.length; h++) {
500
+ a.append(b.create(c[h], d, h));
501
+ }
502
+ } else {
503
+ a.append(b.create(c, d));
504
+ }
505
+ b.destroy();
506
+ } else {
507
+ c = z({}, b.tpl, [], "", null, 1), a.append(c);
508
+ }
509
+ return D;
510
+ };
511
+ D.register = function(a, b) {
512
+ let c, d;
513
+ if ("string" === typeof a) {
514
+ if (c = d = a, a = C[c], a instanceof D || (a = a[0]), !a) {
515
+ throw Error("The template '" + c + "' was not found.");
516
+ }
517
+ } else {
518
+ c = a.name;
519
+ }
520
+ C[c] && (d ? console.info("The template '" + c + "' was replaced by a new definition.") : console.warn("The template '" + c + "' was already registered and is getting overwritten. When this isn't your intention, then please check your template names about uniqueness and collision!"));
521
+ C[c] = [a, b];
522
+ return D;
523
+ };
524
+ D.unregister = function(a) {
525
+ "object" === typeof a && (a = a.name);
526
+ const b = C[a];
527
+ b && (b instanceof D && b.destroy(), C[a] = null);
528
+ return D;
529
+ };
530
+ const I = window;
531
+ let J;
532
+ (J = I.define) && J.amd ? J([], function() {
533
+ return D;
534
+ }) : "object" === typeof I.exports ? I.exports = D : I.Mikado = D;
535
+ }).call(this);
@@ -0,0 +1,29 @@
1
+ /**!
2
+ * Mikado.js v0.8.400 (Light)
3
+ * Copyright 2019-2024 Nextapps GmbH
4
+ * Author: Thomas Wilkerling
5
+ * Licence: Apache-2.0
6
+ * https://github.com/nextapps-de/mikado
7
+ */
8
+ (function(){'use strict';var m;function p(a,b,c){let d;c&&(d=a._mkc)&&(a._mkc=null);const g=b.length,k=[],e={};for(let l=0,q,n,r,v,w=null;l<g;l++){q=b[l];if(n=q.v){if(v=r=e[n],!v){a:{var h=a,f=n;for(let u=0,A=f.length,x="";u<A;u++){const t=f[u];x+=t;if(e[x])h=e[x];else{if(">"===t)h=h.firstChild;else{if("|"===t){r=[h.firstChild,h];break a}if("@"===t){r=[h.style,h];break a}h=h.nextSibling}e[x]=h}}r=[h]}v=r[0];r=r[1]||v}}else v=r=a;c&&(w=d?d[l]:{},r._mkc=w);k[l]=new y(w,v,"")}return a._mkp=k}
9
+ function z(a,b,c,d,g,k){const e=g||(b.tag?b.svg?document.createElementNS("http://www.w3.org/2000/svg",b.tag):document.createElement(b.tag):document.createTextNode(b.text));let h,f;if(f=b.class)"object"===typeof f?c.push(new y(h={_c:""},e,d)):g||(e.className=f);if(f=b.attr)for(const l in f){let q=f[l];"object"===typeof q?(h||c.push(new y(h={},e,d)),h["_a"+l]=!1):g||e.setAttribute(l,q)}if(f=b.style)"object"===typeof f?(c.push(new y(h||(h={}),e.style,d+"@")),h._s=""):g||(e.style.cssText=f);if(f=b.text)"object"===
10
+ typeof f?(a=e,f=f[0],b.tag?(d+="|",a=!g&&e.firstChild,a||(a=document.createTextNode(f),e.appendChild(a))):h={},(h||(h={}))._t=f,c.push(new y(h,a,d))):g||(b.tag?e.textContent=f:e.nodeValue=f);else if(f=b.child){if(g&&(g=g.firstChild,!g))return null;f.constructor!==Array&&(f=[f]);for(let l=0,q,n=f.length;l<n;l++)if(q=f[l],d=l?d+"+":d+">",b=z(a,q,c,d,g,1),g){if(l<n-1&&(g=g.nextSibling,!g))return null}else e.appendChild(b)}else if(f=b.html)"object"===typeof f?(h||c.push(new y(h={},e,d)),h._h=""):g||(e.innerHTML=
11
+ f);else if(f=b.inc){h||c.push(new y(null,e,d));let l;if("string"===typeof f){if(l=C[f],!(l instanceof D)){d=l[0];if(b=l[1])b.async=!1,g&&(b.root=g,b.hydrate=!0);C[f]=l=new D(d,b)}}else 1!==f&&(l=new D({name:a.name+"|"+a.inc.length,tpl:f,key:f.key,cache:f.cache,fn:a.tpl.fn},{recycle:a.recycle,cache:a.cache,pool:!!a.pool,state:a.state,mount:e,hydrate:!!g}));1!==f&&a.inc.push(l)}h&&(e._mkc=h);k||(e._mkp=c);return e}const E={checked:1,selected:1,hidden:1};
12
+ function y(a,b,c){this.c=a;this.n=b;this.v=c}m=y.prototype;m._a=function(a,b,c,d,g){if(this.c){if(d){if(g||0===g)d=d[g]||(d[g]={});d["_a"+a]=b}if(this.c["_a"+a]===b)return;this.c["_a"+a]=b}!E[a]||c&&"selected"===a?!1===b?this.n.removeAttribute(a):this.n.setAttribute(a,b):this.n[a]=b};m._t=function(a,b,c){if(this.c){if(b){if(c||0===c)b=b[c]||(b[c]={});b._t=a}if(this.c._t===a)return;this.c._t=a}this.n.nodeValue=a};
13
+ m._c=function(a,b,c){if(this.c){if(b){if(c||0===c)b=b[c]||(b[c]={});b._c=a}if(this.c._c===a)return;this.c._c=a}this.n.className=a};m._s=function(a,b,c){if(this.c){if(b){if(c||0===c)b=b[c]||(b[c]={});b._s=a}if(this.c._s===a)return;this.c._s=a}this.n.cssText=a};m._h=function(a,b,c){if(this.c){if(b){if(c||0===c)b=b[c]||(b[c]={});b._h=a}if(this.c._h===a)return;this.c._h=a}this.n.innerHTML=a};const C=Object.create(null);
14
+ function D(a,b={}){if(!(this instanceof D))return new D(a,b);if("string"===typeof a){var c=C[a];if(c instanceof D)return c;a=c[0];b||(b=c[1])}this.g=[];this.length=0;this.root=b.root||b.mount||null;this.recycle=!!b.recycle;this.state=b.state||{};this.shadow=b.shadow||!1;this.key=a.key||"";this.j={};c=a.fn;a.m||c&&(a.m=c.slice());this.apply=c&&c.pop();this.tpl=a;this.name=a.name;this.inc=[];this.pool=(c=this.recycle||!!this.key)&&b.pool?1:0;this.l=[];this.h=new Map;this.cache=c&&(a.cache||!!b.cache);
15
+ this.root?this.mount(this.root,b.hydrate):this.i=null}m=D.prototype;
16
+ m.mount=function(a,b){this.shadow&&(a=a.shadowRoot||a.attachShadow({mode:"open"}));const c=a._mki;var d=this.root!==a;if(c===this){if(!d)return this;this.g=a._mkd;this.length=this.g.length}else if(c)c.clear(),a._mkd=this.g=[],this.length=0,a.firstChild&&(a.textContent="");else{if(b){var g=a.children;const k=g.length,e=Array(k);for(let h=0;h<k;h++)e[h]=g[h];this.g=e;this.length=this.g.length}else this.g=[],this.length=0,a.firstChild&&(a.textContent="");a._mkd=this.g}if(this.key)if(d&&this.root&&(this.root._mkl=
17
+ this.j),c===this)this.j=a._mkl;else{d={};if(!c&&b&&this.length)for(let k=0,e,h;k<this.length;k++)e=this.g[k],h=e.getAttribute("key"),e._mkk=h,d[h]=e;a._mkl=this.j=d}a._mki=this;this.root=a;this.i||(b&&this.length&&(this.i=this.g[0].cloneNode(!0),z(this,this.tpl.tpl,[],"",this.i)&&F(this)),this.tpl&&(this.i=z(this,this.tpl.tpl,[],""),F(this)));return this};function F(a){a.tpl.m&&(a.tpl.fn=a.tpl.m,a.tpl.m=null);a.tpl=null}
18
+ m.render=function(a,b){var c=this.length;if(!a&&!this.apply)return this.g[0]||this.add(),this;if(Array.isArray(a)){var d=a.length;if(!d)return this.remove(0,c)}else a=[a],d=1;var g=this.key;!c||g||this.recycle||(this.remove(0,c),c=0);var k=c<d?c:d,e=0;if(e<k)for(let l,q;e<k;e++){l=this.g[e];q=a[e];if(g&&l._mkk!==q[g]){c=this.g;d=this.j;g=this.key;k=a.length;let n=c.length,r=n>k?n:k,v=0;for(e||(e=0);e<r;e++){var h=void 0;if(e<k){const w=a[e];var f=e>=n;let u,A,x;if(!f&&(u=c[e],A=w[g],x=u._mkk,x===
19
+ A)){this.update(u,w,b,e);continue}if(f||!d[A]){f||!this.pool?(n++,r=n>k?n:k,this.add(w,b,e)):this.replace(u,w,b,e);continue}let t,B;for(f=e+1;f<r;f++)if(!t&&f<n&&c[f]._mkk===A&&(t=f+1),!B&&f<k&&a[f][g]===x&&(B=f+1),t&&B){t>=B+v?(h=c[t-1],this.root.insertBefore(h,u),this.update(h,w,b,e),t===B?(1<f-e&&this.root.insertBefore(u,c[t]),c[e]=c[f],c[f]=u):(G(c,t-1,e),v++)):(h=B-1+v,this.root.insertBefore(u,c[h]||null),G(c,e,(h>n?n:h)-1),v--,e--);h=1;break}}h||(this.remove(e),n--,r=n>k?n:k,e--)}return this}this.update(l,
20
+ q,b,e)}if(e<d)for(;e<d;e++)this.add(a[e],b);else d<c&&this.remove(d,c-d);return this};
21
+ m.replace=function(a,b,c,d){"undefined"===typeof d&&("number"===typeof a?(d=0>a?this.length+a:a,a=this.g[d]):d=this.index(a));var g;if(this.key){var k=b[this.key];if(g=this.j[k]){if(g!==a){k=this.index(g);const e=k<d?g:a,h=k<d?a:g;let f=this.g[k<d?k+1:d+1];this.g[d]=g;this.g[k]=a;f!==h?this.root.insertBefore(e,h):f=e;this.root.insertBefore(h,f)}}else this.pool&&(g=this.h.get(k))&&(this.h.delete(k),H(this,a),this.g[d]=g,a.replaceWith(g))}else this.recycle&&(g=a);g?this.apply&&this.apply(b,c||this.state,
22
+ d,g._mkp||p(g,this.i._mkp,this.cache)):(b=this.create(b,c,d,1),(this.key||this.pool)&&H(this,a),this.g[d]=b,a.replaceWith(b));return this};m.update=function(a,b,c,d){if(!this.apply)return this;"undefined"===typeof d&&("number"===typeof a?(d=0>a?this.length+a-1:a,a=this.g[d]):d=this.index(a));this.apply(b,c||this.state,d,a._mkp||p(a,this.i._mkp,this.cache));return this};
23
+ m.create=function(a,b,c,d){const g=this.key,k=g&&a[g];let e;var h;let f,l;this.pool&&(g?(h=this.h)&&(e=h.get(k))&&(h.delete(k),l=1):(h=this.l)&&h.length&&(e=h.pop()));e||(e=f=this.i,f||(this.i=e=f=z(this,this.tpl.tpl,[],""),F(this)));let q;this.apply&&(h=e._mkp||p(e,this.i._mkp,!!f||this.cache),q=f&&this.cache&&Array(h.length),this.apply(a,b||this.state,c,h,!!f,q));f&&(e=f.cloneNode(!0),q&&!0!==q&&(e._mkc=q));g&&(l||(e._mkk=k),d&&(this.j[k]=e));return e};
24
+ m.add=function(a,b,c){let d;"number"===typeof b?(c=0>b?this.length+b:b,b=null,d=c<this.length):"number"===typeof c?(0>c&&(c+=this.length),d=c<this.length):c=this.length;a=this.create(a,b,c,1);d?(this.root.insertBefore(a,this.g[c]),G(this.g,this.length-1,c,a),this.length++):(this.root.appendChild(a),this.g[this.length++]=a);this.key&&this.pool&&this.pool<this.length&&(this.pool=this.length);return this};
25
+ function G(a,b,c,d){const g=d||a[b];d&&b++;if(b<c)for(;b<c;b++)a[b]=a[b+1];else for(;b>c;b--)a[b]=a[b-1];a[c]=g}m.append=function(a,b,c){let d;"number"===typeof b?(c=0>b?this.length+b:b,b=null,d=1):"number"===typeof c&&(0>c&&(c+=this.length),d=1);const g=a.length;for(let k=0;k<g;k++)this.add(a[k],b,d?c++:null);return this};m.clear=function(){this.length&&this.remove(0,this.length);return this};
26
+ m.remove=function(a,b){let c=this.length;c&&a&&("number"!==typeof a?a=this.index(a):0>a&&(a=c+a));if(!c||a>=c)return this;b?0>b&&(a-=b+1,0>a&&(a=0),b*=-1):b=1;let d;!a&&b>=c?(d=this.g,b=d.length,this.root.textContent="",this.root._mkd=this.g=[],c=0):(d=this.g.splice(a,b),c-=b);const g=this.pool&&!this.key,k=this.key||this.pool;(a=this.key&&this.pool)&&b>=a&&(this.h=new Map,a=0);for(let e=0,h;e<b;e++)h=d[g?b-e-1:e],c&&h.remove(),k&&H(this,h,1);if(a&&0<(a=this.h.size-a))for(b=this.h.keys();a--;)this.h.delete(b.next().value);
27
+ this.length=c;return this};m.index=function(a){return a?this.g.indexOf(a):-1};m.node=function(a){return this.g[a]};function H(a,b,c){let d;a.key&&(d=b._mkk,a.j[d]=null);a.pool&&(d?(a.h.set(d,b),!c&&a.h.size>a.pool&&a.h.delete(a.h.keys().next().value)):a.l[a.l.length]=b)}m.flush=function(){this.l=[];this.h=new Map;return this};
28
+ m.destroy=function(){for(let a=0,b;a<this.inc.length;a++)b=this.inc[a],C[b.name]||b.destroy();this.key&&(this.root&&(this.root._mkl=null),this.j=null);this.root&&(this.root._mkd=this.root._mki=null);this.h=this.l=this.g=this.root=this.tpl=this.apply=this.inc=this.state=this.i=null};D.once=function(a,b,c,d){if(c||b.fn){b=new D(b);if(c&&Array.isArray(c))for(let g=0;g<c.length;g++)a.append(b.create(c[g],d,g));else a.append(b.create(c,d));b.destroy()}else c=z({},b.tpl,[],"",null,1),a.append(c);return D};D.register=function(a,b){let c;"string"===typeof a?(c=a,a=C[c],a instanceof D||(a=a[0])):c=a.name;C[c]=[a,b];return D};D.unregister=function(a){"object"===typeof a&&(a=a.name);const b=C[a];b&&(b instanceof D&&b.destroy(),C[a]=null);return D};const I=window;let J;
29
+ (J=I.define)&&J.amd?J([],function(){return D}):"object"===typeof I.exports?I.exports=D:I.Mikado=D;}).call(this);