svelte 3.59.0 → 3.59.2

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.
@@ -1,2098 +0,0 @@
1
- 'use strict';
2
-
3
- function noop() { }
4
- const identity = x => x;
5
- function assign(tar, src) {
6
- // @ts-ignore
7
- for (const k in src)
8
- tar[k] = src[k];
9
- return tar;
10
- }
11
- // Adapted from https://github.com/then/is-promise/blob/master/index.js
12
- // Distributed under MIT License https://github.com/then/is-promise/blob/master/LICENSE
13
- function is_promise(value) {
14
- return !!value && (typeof value === 'object' || typeof value === 'function') && typeof value.then === 'function';
15
- }
16
- function add_location(element, file, line, column, char) {
17
- element.__svelte_meta = {
18
- loc: { file, line, column, char }
19
- };
20
- }
21
- function run(fn) {
22
- return fn();
23
- }
24
- function blank_object() {
25
- return Object.create(null);
26
- }
27
- function run_all(fns) {
28
- fns.forEach(run);
29
- }
30
- function is_function(thing) {
31
- return typeof thing === 'function';
32
- }
33
- function safe_not_equal(a, b) {
34
- return a != a ? b == b : a !== b || ((a && typeof a === 'object') || typeof a === 'function');
35
- }
36
- let src_url_equal_anchor;
37
- function src_url_equal(element_src, url) {
38
- if (!src_url_equal_anchor) {
39
- src_url_equal_anchor = document.createElement('a');
40
- }
41
- src_url_equal_anchor.href = url;
42
- return element_src === src_url_equal_anchor.href;
43
- }
44
- function not_equal(a, b) {
45
- return a != a ? b == b : a !== b;
46
- }
47
- function is_empty(obj) {
48
- return Object.keys(obj).length === 0;
49
- }
50
- function validate_store(store, name) {
51
- if (store != null && typeof store.subscribe !== 'function') {
52
- throw new Error(`'${name}' is not a store with a 'subscribe' method`);
53
- }
54
- }
55
- function subscribe(store, ...callbacks) {
56
- if (store == null) {
57
- return noop;
58
- }
59
- const unsub = store.subscribe(...callbacks);
60
- return unsub.unsubscribe ? () => unsub.unsubscribe() : unsub;
61
- }
62
- function get_store_value(store) {
63
- let value;
64
- subscribe(store, _ => value = _)();
65
- return value;
66
- }
67
- function component_subscribe(component, store, callback) {
68
- component.$$.on_destroy.push(subscribe(store, callback));
69
- }
70
- function create_slot(definition, ctx, $$scope, fn) {
71
- if (definition) {
72
- const slot_ctx = get_slot_context(definition, ctx, $$scope, fn);
73
- return definition[0](slot_ctx);
74
- }
75
- }
76
- function get_slot_context(definition, ctx, $$scope, fn) {
77
- return definition[1] && fn
78
- ? assign($$scope.ctx.slice(), definition[1](fn(ctx)))
79
- : $$scope.ctx;
80
- }
81
- function get_slot_changes(definition, $$scope, dirty, fn) {
82
- if (definition[2] && fn) {
83
- const lets = definition[2](fn(dirty));
84
- if ($$scope.dirty === undefined) {
85
- return lets;
86
- }
87
- if (typeof lets === 'object') {
88
- const merged = [];
89
- const len = Math.max($$scope.dirty.length, lets.length);
90
- for (let i = 0; i < len; i += 1) {
91
- merged[i] = $$scope.dirty[i] | lets[i];
92
- }
93
- return merged;
94
- }
95
- return $$scope.dirty | lets;
96
- }
97
- return $$scope.dirty;
98
- }
99
- function update_slot_base(slot, slot_definition, ctx, $$scope, slot_changes, get_slot_context_fn) {
100
- if (slot_changes) {
101
- const slot_context = get_slot_context(slot_definition, ctx, $$scope, get_slot_context_fn);
102
- slot.p(slot_context, slot_changes);
103
- }
104
- }
105
- function update_slot(slot, slot_definition, ctx, $$scope, dirty, get_slot_changes_fn, get_slot_context_fn) {
106
- const slot_changes = get_slot_changes(slot_definition, $$scope, dirty, get_slot_changes_fn);
107
- update_slot_base(slot, slot_definition, ctx, $$scope, slot_changes, get_slot_context_fn);
108
- }
109
- function get_all_dirty_from_scope($$scope) {
110
- if ($$scope.ctx.length > 32) {
111
- const dirty = [];
112
- const length = $$scope.ctx.length / 32;
113
- for (let i = 0; i < length; i++) {
114
- dirty[i] = -1;
115
- }
116
- return dirty;
117
- }
118
- return -1;
119
- }
120
- function exclude_internal_props(props) {
121
- const result = {};
122
- for (const k in props)
123
- if (k[0] !== '$')
124
- result[k] = props[k];
125
- return result;
126
- }
127
- function compute_rest_props(props, keys) {
128
- const rest = {};
129
- keys = new Set(keys);
130
- for (const k in props)
131
- if (!keys.has(k) && k[0] !== '$')
132
- rest[k] = props[k];
133
- return rest;
134
- }
135
- function compute_slots(slots) {
136
- const result = {};
137
- for (const key in slots) {
138
- result[key] = true;
139
- }
140
- return result;
141
- }
142
- function once(fn) {
143
- let ran = false;
144
- return function (...args) {
145
- if (ran)
146
- return;
147
- ran = true;
148
- fn.call(this, ...args);
149
- };
150
- }
151
- function null_to_empty(value) {
152
- return value == null ? '' : value;
153
- }
154
- function set_store_value(store, ret, value) {
155
- store.set(value);
156
- return ret;
157
- }
158
- const has_prop = (obj, prop) => Object.prototype.hasOwnProperty.call(obj, prop);
159
- function action_destroyer(action_result) {
160
- return action_result && is_function(action_result.destroy) ? action_result.destroy : noop;
161
- }
162
- function split_css_unit(value) {
163
- const split = typeof value === 'string' && value.match(/^\s*(-?[\d.]+)([^\s]*)\s*$/);
164
- return split ? [parseFloat(split[1]), split[2] || 'px'] : [value, 'px'];
165
- }
166
- const contenteditable_truthy_values = ['', true, 1, 'true', 'contenteditable'];
167
-
168
- const is_client = typeof window !== 'undefined';
169
- exports.now = is_client
170
- ? () => window.performance.now()
171
- : () => Date.now();
172
- exports.raf = is_client ? cb => requestAnimationFrame(cb) : noop;
173
- // used internally for testing
174
- function set_now(fn) {
175
- exports.now = fn;
176
- }
177
- function set_raf(fn) {
178
- exports.raf = fn;
179
- }
180
-
181
- const tasks = new Set();
182
- function run_tasks(now) {
183
- tasks.forEach(task => {
184
- if (!task.c(now)) {
185
- tasks.delete(task);
186
- task.f();
187
- }
188
- });
189
- if (tasks.size !== 0)
190
- exports.raf(run_tasks);
191
- }
192
- /**
193
- * For testing purposes only!
194
- */
195
- function clear_loops() {
196
- tasks.clear();
197
- }
198
- /**
199
- * Creates a new task that runs on each raf frame
200
- * until it returns a falsy value or is aborted
201
- */
202
- function loop(callback) {
203
- let task;
204
- if (tasks.size === 0)
205
- exports.raf(run_tasks);
206
- return {
207
- promise: new Promise(fulfill => {
208
- tasks.add(task = { c: callback, f: fulfill });
209
- }),
210
- abort() {
211
- tasks.delete(task);
212
- }
213
- };
214
- }
215
-
216
- const globals = (typeof window !== 'undefined'
217
- ? window
218
- : typeof globalThis !== 'undefined'
219
- ? globalThis
220
- : global);
221
-
222
- /**
223
- * Resize observer singleton.
224
- * One listener per element only!
225
- * https://groups.google.com/a/chromium.org/g/blink-dev/c/z6ienONUb5A/m/F5-VcUZtBAAJ
226
- */
227
- class ResizeObserverSingleton {
228
- constructor(options) {
229
- this.options = options;
230
- this._listeners = 'WeakMap' in globals ? new WeakMap() : undefined;
231
- }
232
- observe(element, listener) {
233
- this._listeners.set(element, listener);
234
- this._getObserver().observe(element, this.options);
235
- return () => {
236
- this._listeners.delete(element);
237
- this._observer.unobserve(element); // this line can probably be removed
238
- };
239
- }
240
- _getObserver() {
241
- var _a;
242
- return (_a = this._observer) !== null && _a !== void 0 ? _a : (this._observer = new ResizeObserver((entries) => {
243
- var _a;
244
- for (const entry of entries) {
245
- ResizeObserverSingleton.entries.set(entry.target, entry);
246
- (_a = this._listeners.get(entry.target)) === null || _a === void 0 ? void 0 : _a(entry);
247
- }
248
- }));
249
- }
250
- }
251
- // Needs to be written like this to pass the tree-shake-test
252
- ResizeObserverSingleton.entries = 'WeakMap' in globals ? new WeakMap() : undefined;
253
-
254
- // Track which nodes are claimed during hydration. Unclaimed nodes can then be removed from the DOM
255
- // at the end of hydration without touching the remaining nodes.
256
- let is_hydrating = false;
257
- function start_hydrating() {
258
- is_hydrating = true;
259
- }
260
- function end_hydrating() {
261
- is_hydrating = false;
262
- }
263
- function upper_bound(low, high, key, value) {
264
- // Return first index of value larger than input value in the range [low, high)
265
- while (low < high) {
266
- const mid = low + ((high - low) >> 1);
267
- if (key(mid) <= value) {
268
- low = mid + 1;
269
- }
270
- else {
271
- high = mid;
272
- }
273
- }
274
- return low;
275
- }
276
- function init_hydrate(target) {
277
- if (target.hydrate_init)
278
- return;
279
- target.hydrate_init = true;
280
- // We know that all children have claim_order values since the unclaimed have been detached if target is not <head>
281
- let children = target.childNodes;
282
- // If target is <head>, there may be children without claim_order
283
- if (target.nodeName === 'HEAD') {
284
- const myChildren = [];
285
- for (let i = 0; i < children.length; i++) {
286
- const node = children[i];
287
- if (node.claim_order !== undefined) {
288
- myChildren.push(node);
289
- }
290
- }
291
- children = myChildren;
292
- }
293
- /*
294
- * Reorder claimed children optimally.
295
- * We can reorder claimed children optimally by finding the longest subsequence of
296
- * nodes that are already claimed in order and only moving the rest. The longest
297
- * subsequence of nodes that are claimed in order can be found by
298
- * computing the longest increasing subsequence of .claim_order values.
299
- *
300
- * This algorithm is optimal in generating the least amount of reorder operations
301
- * possible.
302
- *
303
- * Proof:
304
- * We know that, given a set of reordering operations, the nodes that do not move
305
- * always form an increasing subsequence, since they do not move among each other
306
- * meaning that they must be already ordered among each other. Thus, the maximal
307
- * set of nodes that do not move form a longest increasing subsequence.
308
- */
309
- // Compute longest increasing subsequence
310
- // m: subsequence length j => index k of smallest value that ends an increasing subsequence of length j
311
- const m = new Int32Array(children.length + 1);
312
- // Predecessor indices + 1
313
- const p = new Int32Array(children.length);
314
- m[0] = -1;
315
- let longest = 0;
316
- for (let i = 0; i < children.length; i++) {
317
- const current = children[i].claim_order;
318
- // Find the largest subsequence length such that it ends in a value less than our current value
319
- // upper_bound returns first greater value, so we subtract one
320
- // with fast path for when we are on the current longest subsequence
321
- const seqLen = ((longest > 0 && children[m[longest]].claim_order <= current) ? longest + 1 : upper_bound(1, longest, idx => children[m[idx]].claim_order, current)) - 1;
322
- p[i] = m[seqLen] + 1;
323
- const newLen = seqLen + 1;
324
- // We can guarantee that current is the smallest value. Otherwise, we would have generated a longer sequence.
325
- m[newLen] = i;
326
- longest = Math.max(newLen, longest);
327
- }
328
- // The longest increasing subsequence of nodes (initially reversed)
329
- const lis = [];
330
- // The rest of the nodes, nodes that will be moved
331
- const toMove = [];
332
- let last = children.length - 1;
333
- for (let cur = m[longest] + 1; cur != 0; cur = p[cur - 1]) {
334
- lis.push(children[cur - 1]);
335
- for (; last >= cur; last--) {
336
- toMove.push(children[last]);
337
- }
338
- last--;
339
- }
340
- for (; last >= 0; last--) {
341
- toMove.push(children[last]);
342
- }
343
- lis.reverse();
344
- // We sort the nodes being moved to guarantee that their insertion order matches the claim order
345
- toMove.sort((a, b) => a.claim_order - b.claim_order);
346
- // Finally, we move the nodes
347
- for (let i = 0, j = 0; i < toMove.length; i++) {
348
- while (j < lis.length && toMove[i].claim_order >= lis[j].claim_order) {
349
- j++;
350
- }
351
- const anchor = j < lis.length ? lis[j] : null;
352
- target.insertBefore(toMove[i], anchor);
353
- }
354
- }
355
- function append(target, node) {
356
- target.appendChild(node);
357
- }
358
- function append_styles(target, style_sheet_id, styles) {
359
- const append_styles_to = get_root_for_style(target);
360
- if (!append_styles_to.getElementById(style_sheet_id)) {
361
- const style = element('style');
362
- style.id = style_sheet_id;
363
- style.textContent = styles;
364
- append_stylesheet(append_styles_to, style);
365
- }
366
- }
367
- function get_root_for_style(node) {
368
- if (!node)
369
- return document;
370
- const root = node.getRootNode ? node.getRootNode() : node.ownerDocument;
371
- if (root && root.host) {
372
- return root;
373
- }
374
- return node.ownerDocument;
375
- }
376
- function append_empty_stylesheet(node) {
377
- const style_element = element('style');
378
- append_stylesheet(get_root_for_style(node), style_element);
379
- return style_element.sheet;
380
- }
381
- function append_stylesheet(node, style) {
382
- append(node.head || node, style);
383
- return style.sheet;
384
- }
385
- function append_hydration(target, node) {
386
- if (is_hydrating) {
387
- init_hydrate(target);
388
- if ((target.actual_end_child === undefined) || ((target.actual_end_child !== null) && (target.actual_end_child.parentNode !== target))) {
389
- target.actual_end_child = target.firstChild;
390
- }
391
- // Skip nodes of undefined ordering
392
- while ((target.actual_end_child !== null) && (target.actual_end_child.claim_order === undefined)) {
393
- target.actual_end_child = target.actual_end_child.nextSibling;
394
- }
395
- if (node !== target.actual_end_child) {
396
- // We only insert if the ordering of this node should be modified or the parent node is not target
397
- if (node.claim_order !== undefined || node.parentNode !== target) {
398
- target.insertBefore(node, target.actual_end_child);
399
- }
400
- }
401
- else {
402
- target.actual_end_child = node.nextSibling;
403
- }
404
- }
405
- else if (node.parentNode !== target || node.nextSibling !== null) {
406
- target.appendChild(node);
407
- }
408
- }
409
- function insert(target, node, anchor) {
410
- target.insertBefore(node, anchor || null);
411
- }
412
- function insert_hydration(target, node, anchor) {
413
- if (is_hydrating && !anchor) {
414
- append_hydration(target, node);
415
- }
416
- else if (node.parentNode !== target || node.nextSibling != anchor) {
417
- target.insertBefore(node, anchor || null);
418
- }
419
- }
420
- function detach(node) {
421
- if (node.parentNode) {
422
- node.parentNode.removeChild(node);
423
- }
424
- }
425
- function destroy_each(iterations, detaching) {
426
- for (let i = 0; i < iterations.length; i += 1) {
427
- if (iterations[i])
428
- iterations[i].d(detaching);
429
- }
430
- }
431
- function element(name) {
432
- return document.createElement(name);
433
- }
434
- function element_is(name, is) {
435
- return document.createElement(name, { is });
436
- }
437
- function object_without_properties(obj, exclude) {
438
- const target = {};
439
- for (const k in obj) {
440
- if (has_prop(obj, k)
441
- // @ts-ignore
442
- && exclude.indexOf(k) === -1) {
443
- // @ts-ignore
444
- target[k] = obj[k];
445
- }
446
- }
447
- return target;
448
- }
449
- function svg_element(name) {
450
- return document.createElementNS('http://www.w3.org/2000/svg', name);
451
- }
452
- function text(data) {
453
- return document.createTextNode(data);
454
- }
455
- function space() {
456
- return text(' ');
457
- }
458
- function empty() {
459
- return text('');
460
- }
461
- function comment(content) {
462
- return document.createComment(content);
463
- }
464
- function listen(node, event, handler, options) {
465
- node.addEventListener(event, handler, options);
466
- return () => node.removeEventListener(event, handler, options);
467
- }
468
- function prevent_default(fn) {
469
- return function (event) {
470
- event.preventDefault();
471
- // @ts-ignore
472
- return fn.call(this, event);
473
- };
474
- }
475
- function stop_propagation(fn) {
476
- return function (event) {
477
- event.stopPropagation();
478
- // @ts-ignore
479
- return fn.call(this, event);
480
- };
481
- }
482
- function stop_immediate_propagation(fn) {
483
- return function (event) {
484
- event.stopImmediatePropagation();
485
- // @ts-ignore
486
- return fn.call(this, event);
487
- };
488
- }
489
- function self(fn) {
490
- return function (event) {
491
- // @ts-ignore
492
- if (event.target === this)
493
- fn.call(this, event);
494
- };
495
- }
496
- function trusted(fn) {
497
- return function (event) {
498
- // @ts-ignore
499
- if (event.isTrusted)
500
- fn.call(this, event);
501
- };
502
- }
503
- function attr(node, attribute, value) {
504
- if (value == null)
505
- node.removeAttribute(attribute);
506
- else if (node.getAttribute(attribute) !== value)
507
- node.setAttribute(attribute, value);
508
- }
509
- /**
510
- * List of attributes that should always be set through the attr method,
511
- * because updating them through the property setter doesn't work reliably.
512
- * In the example of `width`/`height`, the problem is that the setter only
513
- * accepts numeric values, but the attribute can also be set to a string like `50%`.
514
- * If this list becomes too big, rethink this approach.
515
- */
516
- const always_set_through_set_attribute = ['width', 'height'];
517
- function set_attributes(node, attributes) {
518
- // @ts-ignore
519
- const descriptors = Object.getOwnPropertyDescriptors(node.__proto__);
520
- for (const key in attributes) {
521
- if (attributes[key] == null) {
522
- node.removeAttribute(key);
523
- }
524
- else if (key === 'style') {
525
- node.style.cssText = attributes[key];
526
- }
527
- else if (key === '__value') {
528
- node.value = node[key] = attributes[key];
529
- }
530
- else if (descriptors[key] && descriptors[key].set && always_set_through_set_attribute.indexOf(key) === -1) {
531
- node[key] = attributes[key];
532
- }
533
- else {
534
- attr(node, key, attributes[key]);
535
- }
536
- }
537
- }
538
- function set_svg_attributes(node, attributes) {
539
- for (const key in attributes) {
540
- attr(node, key, attributes[key]);
541
- }
542
- }
543
- function set_custom_element_data_map(node, data_map) {
544
- Object.keys(data_map).forEach((key) => {
545
- set_custom_element_data(node, key, data_map[key]);
546
- });
547
- }
548
- function set_custom_element_data(node, prop, value) {
549
- if (prop in node) {
550
- node[prop] = typeof node[prop] === 'boolean' && value === '' ? true : value;
551
- }
552
- else {
553
- attr(node, prop, value);
554
- }
555
- }
556
- function set_dynamic_element_data(tag) {
557
- return (/-/.test(tag)) ? set_custom_element_data_map : set_attributes;
558
- }
559
- function xlink_attr(node, attribute, value) {
560
- node.setAttributeNS('http://www.w3.org/1999/xlink', attribute, value);
561
- }
562
- function get_svelte_dataset(node) {
563
- return node.dataset.svelteH;
564
- }
565
- function get_binding_group_value(group, __value, checked) {
566
- const value = new Set();
567
- for (let i = 0; i < group.length; i += 1) {
568
- if (group[i].checked)
569
- value.add(group[i].__value);
570
- }
571
- if (!checked) {
572
- value.delete(__value);
573
- }
574
- return Array.from(value);
575
- }
576
- function init_binding_group(group) {
577
- let _inputs;
578
- return {
579
- /* push */ p(...inputs) {
580
- _inputs = inputs;
581
- _inputs.forEach(input => group.push(input));
582
- },
583
- /* remove */ r() {
584
- _inputs.forEach(input => group.splice(group.indexOf(input), 1));
585
- }
586
- };
587
- }
588
- function init_binding_group_dynamic(group, indexes) {
589
- let _group = get_binding_group(group);
590
- let _inputs;
591
- function get_binding_group(group) {
592
- for (let i = 0; i < indexes.length; i++) {
593
- group = group[indexes[i]] = group[indexes[i]] || [];
594
- }
595
- return group;
596
- }
597
- function push() {
598
- _inputs.forEach(input => _group.push(input));
599
- }
600
- function remove() {
601
- _inputs.forEach(input => _group.splice(_group.indexOf(input), 1));
602
- }
603
- return {
604
- /* update */ u(new_indexes) {
605
- indexes = new_indexes;
606
- const new_group = get_binding_group(group);
607
- if (new_group !== _group) {
608
- remove();
609
- _group = new_group;
610
- push();
611
- }
612
- },
613
- /* push */ p(...inputs) {
614
- _inputs = inputs;
615
- push();
616
- },
617
- /* remove */ r: remove
618
- };
619
- }
620
- function to_number(value) {
621
- return value === '' ? null : +value;
622
- }
623
- function time_ranges_to_array(ranges) {
624
- const array = [];
625
- for (let i = 0; i < ranges.length; i += 1) {
626
- array.push({ start: ranges.start(i), end: ranges.end(i) });
627
- }
628
- return array;
629
- }
630
- function children(element) {
631
- return Array.from(element.childNodes);
632
- }
633
- function init_claim_info(nodes) {
634
- if (nodes.claim_info === undefined) {
635
- nodes.claim_info = { last_index: 0, total_claimed: 0 };
636
- }
637
- }
638
- function claim_node(nodes, predicate, processNode, createNode, dontUpdateLastIndex = false) {
639
- // Try to find nodes in an order such that we lengthen the longest increasing subsequence
640
- init_claim_info(nodes);
641
- const resultNode = (() => {
642
- // We first try to find an element after the previous one
643
- for (let i = nodes.claim_info.last_index; i < nodes.length; i++) {
644
- const node = nodes[i];
645
- if (predicate(node)) {
646
- const replacement = processNode(node);
647
- if (replacement === undefined) {
648
- nodes.splice(i, 1);
649
- }
650
- else {
651
- nodes[i] = replacement;
652
- }
653
- if (!dontUpdateLastIndex) {
654
- nodes.claim_info.last_index = i;
655
- }
656
- return node;
657
- }
658
- }
659
- // Otherwise, we try to find one before
660
- // We iterate in reverse so that we don't go too far back
661
- for (let i = nodes.claim_info.last_index - 1; i >= 0; i--) {
662
- const node = nodes[i];
663
- if (predicate(node)) {
664
- const replacement = processNode(node);
665
- if (replacement === undefined) {
666
- nodes.splice(i, 1);
667
- }
668
- else {
669
- nodes[i] = replacement;
670
- }
671
- if (!dontUpdateLastIndex) {
672
- nodes.claim_info.last_index = i;
673
- }
674
- else if (replacement === undefined) {
675
- // Since we spliced before the last_index, we decrease it
676
- nodes.claim_info.last_index--;
677
- }
678
- return node;
679
- }
680
- }
681
- // If we can't find any matching node, we create a new one
682
- return createNode();
683
- })();
684
- resultNode.claim_order = nodes.claim_info.total_claimed;
685
- nodes.claim_info.total_claimed += 1;
686
- return resultNode;
687
- }
688
- function claim_element_base(nodes, name, attributes, create_element) {
689
- return claim_node(nodes, (node) => node.nodeName === name, (node) => {
690
- const remove = [];
691
- for (let j = 0; j < node.attributes.length; j++) {
692
- const attribute = node.attributes[j];
693
- if (!attributes[attribute.name]) {
694
- remove.push(attribute.name);
695
- }
696
- }
697
- remove.forEach(v => node.removeAttribute(v));
698
- return undefined;
699
- }, () => create_element(name));
700
- }
701
- function claim_element(nodes, name, attributes) {
702
- return claim_element_base(nodes, name, attributes, element);
703
- }
704
- function claim_svg_element(nodes, name, attributes) {
705
- return claim_element_base(nodes, name, attributes, svg_element);
706
- }
707
- function claim_text(nodes, data) {
708
- return claim_node(nodes, (node) => node.nodeType === 3, (node) => {
709
- const dataStr = '' + data;
710
- if (node.data.startsWith(dataStr)) {
711
- if (node.data.length !== dataStr.length) {
712
- return node.splitText(dataStr.length);
713
- }
714
- }
715
- else {
716
- node.data = dataStr;
717
- }
718
- }, () => text(data), true // Text nodes should not update last index since it is likely not worth it to eliminate an increasing subsequence of actual elements
719
- );
720
- }
721
- function claim_space(nodes) {
722
- return claim_text(nodes, ' ');
723
- }
724
- function claim_comment(nodes, data) {
725
- return claim_node(nodes, (node) => node.nodeType === 8, (node) => {
726
- node.data = '' + data;
727
- return undefined;
728
- }, () => comment(data), true);
729
- }
730
- function find_comment(nodes, text, start) {
731
- for (let i = start; i < nodes.length; i += 1) {
732
- const node = nodes[i];
733
- if (node.nodeType === 8 /* comment node */ && node.textContent.trim() === text) {
734
- return i;
735
- }
736
- }
737
- return nodes.length;
738
- }
739
- function claim_html_tag(nodes, is_svg) {
740
- // find html opening tag
741
- const start_index = find_comment(nodes, 'HTML_TAG_START', 0);
742
- const end_index = find_comment(nodes, 'HTML_TAG_END', start_index);
743
- if (start_index === end_index) {
744
- return new HtmlTagHydration(undefined, is_svg);
745
- }
746
- init_claim_info(nodes);
747
- const html_tag_nodes = nodes.splice(start_index, end_index - start_index + 1);
748
- detach(html_tag_nodes[0]);
749
- detach(html_tag_nodes[html_tag_nodes.length - 1]);
750
- const claimed_nodes = html_tag_nodes.slice(1, html_tag_nodes.length - 1);
751
- for (const n of claimed_nodes) {
752
- n.claim_order = nodes.claim_info.total_claimed;
753
- nodes.claim_info.total_claimed += 1;
754
- }
755
- return new HtmlTagHydration(claimed_nodes, is_svg);
756
- }
757
- function set_data(text, data) {
758
- data = '' + data;
759
- if (text.data === data)
760
- return;
761
- text.data = data;
762
- }
763
- function set_data_contenteditable(text, data) {
764
- data = '' + data;
765
- if (text.wholeText === data)
766
- return;
767
- text.data = data;
768
- }
769
- function set_data_maybe_contenteditable(text, data, attr_value) {
770
- if (~contenteditable_truthy_values.indexOf(attr_value)) {
771
- set_data_contenteditable(text, data);
772
- }
773
- else {
774
- set_data(text, data);
775
- }
776
- }
777
- function set_input_value(input, value) {
778
- input.value = value == null ? '' : value;
779
- }
780
- function set_input_type(input, type) {
781
- try {
782
- input.type = type;
783
- }
784
- catch (e) {
785
- // do nothing
786
- }
787
- }
788
- function set_style(node, key, value, important) {
789
- if (value === null) {
790
- node.style.removeProperty(key);
791
- }
792
- else {
793
- node.style.setProperty(key, value, important ? 'important' : '');
794
- }
795
- }
796
- function select_option(select, value, mounting) {
797
- for (let i = 0; i < select.options.length; i += 1) {
798
- const option = select.options[i];
799
- if (option.__value === value) {
800
- option.selected = true;
801
- return;
802
- }
803
- }
804
- if (!mounting || value !== undefined) {
805
- select.selectedIndex = -1; // no option should be selected
806
- }
807
- }
808
- function select_options(select, value) {
809
- for (let i = 0; i < select.options.length; i += 1) {
810
- const option = select.options[i];
811
- option.selected = ~value.indexOf(option.__value);
812
- }
813
- }
814
- function select_value(select) {
815
- const selected_option = select.querySelector(':checked');
816
- return selected_option && selected_option.__value;
817
- }
818
- function select_multiple_value(select) {
819
- return [].map.call(select.querySelectorAll(':checked'), option => option.__value);
820
- }
821
- // unfortunately this can't be a constant as that wouldn't be tree-shakeable
822
- // so we cache the result instead
823
- let crossorigin;
824
- function is_crossorigin() {
825
- if (crossorigin === undefined) {
826
- crossorigin = false;
827
- try {
828
- if (typeof window !== 'undefined' && window.parent) {
829
- void window.parent.document;
830
- }
831
- }
832
- catch (error) {
833
- crossorigin = true;
834
- }
835
- }
836
- return crossorigin;
837
- }
838
- function add_iframe_resize_listener(node, fn) {
839
- const computed_style = getComputedStyle(node);
840
- if (computed_style.position === 'static') {
841
- node.style.position = 'relative';
842
- }
843
- const iframe = element('iframe');
844
- iframe.setAttribute('style', 'display: block; position: absolute; top: 0; left: 0; width: 100%; height: 100%; ' +
845
- 'overflow: hidden; border: 0; opacity: 0; pointer-events: none; z-index: -1;');
846
- iframe.setAttribute('aria-hidden', 'true');
847
- iframe.tabIndex = -1;
848
- const crossorigin = is_crossorigin();
849
- let unsubscribe;
850
- if (crossorigin) {
851
- iframe.src = "data:text/html,<script>onresize=function(){parent.postMessage(0,'*')}</script>";
852
- unsubscribe = listen(window, 'message', (event) => {
853
- if (event.source === iframe.contentWindow)
854
- fn();
855
- });
856
- }
857
- else {
858
- iframe.src = 'about:blank';
859
- iframe.onload = () => {
860
- unsubscribe = listen(iframe.contentWindow, 'resize', fn);
861
- // make sure an initial resize event is fired _after_ the iframe is loaded (which is asynchronous)
862
- // see https://github.com/sveltejs/svelte/issues/4233
863
- fn();
864
- };
865
- }
866
- append(node, iframe);
867
- return () => {
868
- if (crossorigin) {
869
- unsubscribe();
870
- }
871
- else if (unsubscribe && iframe.contentWindow) {
872
- unsubscribe();
873
- }
874
- detach(iframe);
875
- };
876
- }
877
- const resize_observer_content_box = /* @__PURE__ */ new ResizeObserverSingleton({ box: 'content-box' });
878
- const resize_observer_border_box = /* @__PURE__ */ new ResizeObserverSingleton({ box: 'border-box' });
879
- const resize_observer_device_pixel_content_box = /* @__PURE__ */ new ResizeObserverSingleton({ box: 'device-pixel-content-box' });
880
- function toggle_class(element, name, toggle) {
881
- element.classList[toggle ? 'add' : 'remove'](name);
882
- }
883
- function custom_event(type, detail, { bubbles = false, cancelable = false } = {}) {
884
- const e = document.createEvent('CustomEvent');
885
- e.initCustomEvent(type, bubbles, cancelable, detail);
886
- return e;
887
- }
888
- function query_selector_all(selector, parent = document.body) {
889
- return Array.from(parent.querySelectorAll(selector));
890
- }
891
- function head_selector(nodeId, head) {
892
- const result = [];
893
- let started = 0;
894
- for (const node of head.childNodes) {
895
- if (node.nodeType === 8 /* comment node */) {
896
- const comment = node.textContent.trim();
897
- if (comment === `HEAD_${nodeId}_END`) {
898
- started -= 1;
899
- result.push(node);
900
- }
901
- else if (comment === `HEAD_${nodeId}_START`) {
902
- started += 1;
903
- result.push(node);
904
- }
905
- }
906
- else if (started > 0) {
907
- result.push(node);
908
- }
909
- }
910
- return result;
911
- }
912
- class HtmlTag {
913
- constructor(is_svg = false) {
914
- this.is_svg = false;
915
- this.is_svg = is_svg;
916
- this.e = this.n = null;
917
- }
918
- c(html) {
919
- this.h(html);
920
- }
921
- m(html, target, anchor = null) {
922
- if (!this.e) {
923
- if (this.is_svg)
924
- this.e = svg_element(target.nodeName);
925
- /** #7364 target for <template> may be provided as #document-fragment(11) */
926
- else
927
- this.e = element((target.nodeType === 11 ? 'TEMPLATE' : target.nodeName));
928
- this.t = target.tagName !== 'TEMPLATE' ? target : target.content;
929
- this.c(html);
930
- }
931
- this.i(anchor);
932
- }
933
- h(html) {
934
- this.e.innerHTML = html;
935
- this.n = Array.from(this.e.nodeName === 'TEMPLATE' ? this.e.content.childNodes : this.e.childNodes);
936
- }
937
- i(anchor) {
938
- for (let i = 0; i < this.n.length; i += 1) {
939
- insert(this.t, this.n[i], anchor);
940
- }
941
- }
942
- p(html) {
943
- this.d();
944
- this.h(html);
945
- this.i(this.a);
946
- }
947
- d() {
948
- this.n.forEach(detach);
949
- }
950
- }
951
- class HtmlTagHydration extends HtmlTag {
952
- constructor(claimed_nodes, is_svg = false) {
953
- super(is_svg);
954
- this.e = this.n = null;
955
- this.l = claimed_nodes;
956
- }
957
- c(html) {
958
- if (this.l) {
959
- this.n = this.l;
960
- }
961
- else {
962
- super.c(html);
963
- }
964
- }
965
- i(anchor) {
966
- for (let i = 0; i < this.n.length; i += 1) {
967
- insert_hydration(this.t, this.n[i], anchor);
968
- }
969
- }
970
- }
971
- function attribute_to_object(attributes) {
972
- const result = {};
973
- for (const attribute of attributes) {
974
- result[attribute.name] = attribute.value;
975
- }
976
- return result;
977
- }
978
- function get_custom_elements_slots(element) {
979
- const result = {};
980
- element.childNodes.forEach((node) => {
981
- result[node.slot || 'default'] = true;
982
- });
983
- return result;
984
- }
985
- function construct_svelte_component(component, props) {
986
- return new component(props);
987
- }
988
-
989
- // we need to store the information for multiple documents because a Svelte application could also contain iframes
990
- // https://github.com/sveltejs/svelte/issues/3624
991
- const managed_styles = new Map();
992
- let active = 0;
993
- // https://github.com/darkskyapp/string-hash/blob/master/index.js
994
- function hash(str) {
995
- let hash = 5381;
996
- let i = str.length;
997
- while (i--)
998
- hash = ((hash << 5) - hash) ^ str.charCodeAt(i);
999
- return hash >>> 0;
1000
- }
1001
- function create_style_information(doc, node) {
1002
- const info = { stylesheet: append_empty_stylesheet(node), rules: {} };
1003
- managed_styles.set(doc, info);
1004
- return info;
1005
- }
1006
- function create_rule(node, a, b, duration, delay, ease, fn, uid = 0) {
1007
- const step = 16.666 / duration;
1008
- let keyframes = '{\n';
1009
- for (let p = 0; p <= 1; p += step) {
1010
- const t = a + (b - a) * ease(p);
1011
- keyframes += p * 100 + `%{${fn(t, 1 - t)}}\n`;
1012
- }
1013
- const rule = keyframes + `100% {${fn(b, 1 - b)}}\n}`;
1014
- const name = `__svelte_${hash(rule)}_${uid}`;
1015
- const doc = get_root_for_style(node);
1016
- const { stylesheet, rules } = managed_styles.get(doc) || create_style_information(doc, node);
1017
- if (!rules[name]) {
1018
- rules[name] = true;
1019
- stylesheet.insertRule(`@keyframes ${name} ${rule}`, stylesheet.cssRules.length);
1020
- }
1021
- const animation = node.style.animation || '';
1022
- node.style.animation = `${animation ? `${animation}, ` : ''}${name} ${duration}ms linear ${delay}ms 1 both`;
1023
- active += 1;
1024
- return name;
1025
- }
1026
- function delete_rule(node, name) {
1027
- const previous = (node.style.animation || '').split(', ');
1028
- const next = previous.filter(name
1029
- ? anim => anim.indexOf(name) < 0 // remove specific animation
1030
- : anim => anim.indexOf('__svelte') === -1 // remove all Svelte animations
1031
- );
1032
- const deleted = previous.length - next.length;
1033
- if (deleted) {
1034
- node.style.animation = next.join(', ');
1035
- active -= deleted;
1036
- if (!active)
1037
- clear_rules();
1038
- }
1039
- }
1040
- function clear_rules() {
1041
- exports.raf(() => {
1042
- if (active)
1043
- return;
1044
- managed_styles.forEach(info => {
1045
- const { ownerNode } = info.stylesheet;
1046
- // there is no ownerNode if it runs on jsdom.
1047
- if (ownerNode)
1048
- detach(ownerNode);
1049
- });
1050
- managed_styles.clear();
1051
- });
1052
- }
1053
-
1054
- exports.current_component = void 0;
1055
- function set_current_component(component) {
1056
- exports.current_component = component;
1057
- }
1058
- function get_current_component() {
1059
- if (!exports.current_component)
1060
- throw new Error('Function called outside component initialization');
1061
- return exports.current_component;
1062
- }
1063
- /**
1064
- * Schedules a callback to run immediately before the component is updated after any state change.
1065
- *
1066
- * The first time the callback runs will be before the initial `onMount`
1067
- *
1068
- * https://svelte.dev/docs#run-time-svelte-beforeupdate
1069
- */
1070
- function beforeUpdate(fn) {
1071
- get_current_component().$$.before_update.push(fn);
1072
- }
1073
- /**
1074
- * The `onMount` function schedules a callback to run as soon as the component has been mounted to the DOM.
1075
- * It must be called during the component's initialisation (but doesn't need to live *inside* the component;
1076
- * it can be called from an external module).
1077
- *
1078
- * If a function is returned _synchronously_ from `onMount`, it will be called when the component is unmounted.
1079
- *
1080
- * `onMount` does not run inside a [server-side component](/docs#run-time-server-side-component-api).
1081
- *
1082
- * https://svelte.dev/docs#run-time-svelte-onmount
1083
- */
1084
- function onMount(fn) {
1085
- get_current_component().$$.on_mount.push(fn);
1086
- }
1087
- /**
1088
- * Schedules a callback to run immediately after the component has been updated.
1089
- *
1090
- * The first time the callback runs will be after the initial `onMount`
1091
- */
1092
- function afterUpdate(fn) {
1093
- get_current_component().$$.after_update.push(fn);
1094
- }
1095
- /**
1096
- * Schedules a callback to run immediately before the component is unmounted.
1097
- *
1098
- * Out of `onMount`, `beforeUpdate`, `afterUpdate` and `onDestroy`, this is the
1099
- * only one that runs inside a server-side component.
1100
- *
1101
- * https://svelte.dev/docs#run-time-svelte-ondestroy
1102
- */
1103
- function onDestroy(fn) {
1104
- get_current_component().$$.on_destroy.push(fn);
1105
- }
1106
- /**
1107
- * Creates an event dispatcher that can be used to dispatch [component events](/docs#template-syntax-component-directives-on-eventname).
1108
- * Event dispatchers are functions that can take two arguments: `name` and `detail`.
1109
- *
1110
- * Component events created with `createEventDispatcher` create a
1111
- * [CustomEvent](https://developer.mozilla.org/en-US/docs/Web/API/CustomEvent).
1112
- * These events do not [bubble](https://developer.mozilla.org/en-US/docs/Learn/JavaScript/Building_blocks/Events#Event_bubbling_and_capture).
1113
- * The `detail` argument corresponds to the [CustomEvent.detail](https://developer.mozilla.org/en-US/docs/Web/API/CustomEvent/detail)
1114
- * property and can contain any type of data.
1115
- *
1116
- * The event dispatcher can be typed to narrow the allowed event names and the type of the `detail` argument:
1117
- * ```ts
1118
- * const dispatch = createEventDispatcher<{
1119
- * loaded: never; // does not take a detail argument
1120
- * change: string; // takes a detail argument of type string, which is required
1121
- * optional: number | null; // takes an optional detail argument of type number
1122
- * }>();
1123
- * ```
1124
- *
1125
- * https://svelte.dev/docs#run-time-svelte-createeventdispatcher
1126
- */
1127
- function createEventDispatcher() {
1128
- const component = get_current_component();
1129
- return ((type, detail, { cancelable = false } = {}) => {
1130
- const callbacks = component.$$.callbacks[type];
1131
- if (callbacks) {
1132
- // TODO are there situations where events could be dispatched
1133
- // in a server (non-DOM) environment?
1134
- const event = custom_event(type, detail, { cancelable });
1135
- callbacks.slice().forEach(fn => {
1136
- fn.call(component, event);
1137
- });
1138
- return !event.defaultPrevented;
1139
- }
1140
- return true;
1141
- });
1142
- }
1143
- /**
1144
- * Associates an arbitrary `context` object with the current component and the specified `key`
1145
- * and returns that object. The context is then available to children of the component
1146
- * (including slotted content) with `getContext`.
1147
- *
1148
- * Like lifecycle functions, this must be called during component initialisation.
1149
- *
1150
- * https://svelte.dev/docs#run-time-svelte-setcontext
1151
- */
1152
- function setContext(key, context) {
1153
- get_current_component().$$.context.set(key, context);
1154
- return context;
1155
- }
1156
- /**
1157
- * Retrieves the context that belongs to the closest parent component with the specified `key`.
1158
- * Must be called during component initialisation.
1159
- *
1160
- * https://svelte.dev/docs#run-time-svelte-getcontext
1161
- */
1162
- function getContext(key) {
1163
- return get_current_component().$$.context.get(key);
1164
- }
1165
- /**
1166
- * Retrieves the whole context map that belongs to the closest parent component.
1167
- * Must be called during component initialisation. Useful, for example, if you
1168
- * programmatically create a component and want to pass the existing context to it.
1169
- *
1170
- * https://svelte.dev/docs#run-time-svelte-getallcontexts
1171
- */
1172
- function getAllContexts() {
1173
- return get_current_component().$$.context;
1174
- }
1175
- /**
1176
- * Checks whether a given `key` has been set in the context of a parent component.
1177
- * Must be called during component initialisation.
1178
- *
1179
- * https://svelte.dev/docs#run-time-svelte-hascontext
1180
- */
1181
- function hasContext(key) {
1182
- return get_current_component().$$.context.has(key);
1183
- }
1184
- // TODO figure out if we still want to support
1185
- // shorthand events, or if we want to implement
1186
- // a real bubbling mechanism
1187
- function bubble(component, event) {
1188
- const callbacks = component.$$.callbacks[event.type];
1189
- if (callbacks) {
1190
- // @ts-ignore
1191
- callbacks.slice().forEach(fn => fn.call(this, event));
1192
- }
1193
- }
1194
-
1195
- const dirty_components = [];
1196
- const intros = { enabled: false };
1197
- const binding_callbacks = [];
1198
- let render_callbacks = [];
1199
- const flush_callbacks = [];
1200
- const resolved_promise = /* @__PURE__ */ Promise.resolve();
1201
- let update_scheduled = false;
1202
- function schedule_update() {
1203
- if (!update_scheduled) {
1204
- update_scheduled = true;
1205
- resolved_promise.then(flush);
1206
- }
1207
- }
1208
- function tick() {
1209
- schedule_update();
1210
- return resolved_promise;
1211
- }
1212
- function add_render_callback(fn) {
1213
- render_callbacks.push(fn);
1214
- }
1215
- function add_flush_callback(fn) {
1216
- flush_callbacks.push(fn);
1217
- }
1218
- // flush() calls callbacks in this order:
1219
- // 1. All beforeUpdate callbacks, in order: parents before children
1220
- // 2. All bind:this callbacks, in reverse order: children before parents.
1221
- // 3. All afterUpdate callbacks, in order: parents before children. EXCEPT
1222
- // for afterUpdates called during the initial onMount, which are called in
1223
- // reverse order: children before parents.
1224
- // Since callbacks might update component values, which could trigger another
1225
- // call to flush(), the following steps guard against this:
1226
- // 1. During beforeUpdate, any updated components will be added to the
1227
- // dirty_components array and will cause a reentrant call to flush(). Because
1228
- // the flush index is kept outside the function, the reentrant call will pick
1229
- // up where the earlier call left off and go through all dirty components. The
1230
- // current_component value is saved and restored so that the reentrant call will
1231
- // not interfere with the "parent" flush() call.
1232
- // 2. bind:this callbacks cannot trigger new flush() calls.
1233
- // 3. During afterUpdate, any updated components will NOT have their afterUpdate
1234
- // callback called a second time; the seen_callbacks set, outside the flush()
1235
- // function, guarantees this behavior.
1236
- const seen_callbacks = new Set();
1237
- let flushidx = 0; // Do *not* move this inside the flush() function
1238
- function flush() {
1239
- // Do not reenter flush while dirty components are updated, as this can
1240
- // result in an infinite loop. Instead, let the inner flush handle it.
1241
- // Reentrancy is ok afterwards for bindings etc.
1242
- if (flushidx !== 0) {
1243
- return;
1244
- }
1245
- const saved_component = exports.current_component;
1246
- do {
1247
- // first, call beforeUpdate functions
1248
- // and update components
1249
- try {
1250
- while (flushidx < dirty_components.length) {
1251
- const component = dirty_components[flushidx];
1252
- flushidx++;
1253
- set_current_component(component);
1254
- update(component.$$);
1255
- }
1256
- }
1257
- catch (e) {
1258
- // reset dirty state to not end up in a deadlocked state and then rethrow
1259
- dirty_components.length = 0;
1260
- flushidx = 0;
1261
- throw e;
1262
- }
1263
- set_current_component(null);
1264
- dirty_components.length = 0;
1265
- flushidx = 0;
1266
- while (binding_callbacks.length)
1267
- binding_callbacks.pop()();
1268
- // then, once components are updated, call
1269
- // afterUpdate functions. This may cause
1270
- // subsequent updates...
1271
- for (let i = 0; i < render_callbacks.length; i += 1) {
1272
- const callback = render_callbacks[i];
1273
- if (!seen_callbacks.has(callback)) {
1274
- // ...so guard against infinite loops
1275
- seen_callbacks.add(callback);
1276
- callback();
1277
- }
1278
- }
1279
- render_callbacks.length = 0;
1280
- } while (dirty_components.length);
1281
- while (flush_callbacks.length) {
1282
- flush_callbacks.pop()();
1283
- }
1284
- update_scheduled = false;
1285
- seen_callbacks.clear();
1286
- set_current_component(saved_component);
1287
- }
1288
- function update($$) {
1289
- if ($$.fragment !== null) {
1290
- $$.update();
1291
- run_all($$.before_update);
1292
- const dirty = $$.dirty;
1293
- $$.dirty = [-1];
1294
- $$.fragment && $$.fragment.p($$.ctx, dirty);
1295
- $$.after_update.forEach(add_render_callback);
1296
- }
1297
- }
1298
- /**
1299
- * Useful for example to execute remaining `afterUpdate` callbacks before executing `destroy`.
1300
- */
1301
- function flush_render_callbacks(fns) {
1302
- const filtered = [];
1303
- const targets = [];
1304
- render_callbacks.forEach((c) => fns.indexOf(c) === -1 ? filtered.push(c) : targets.push(c));
1305
- targets.forEach((c) => c());
1306
- render_callbacks = filtered;
1307
- }
1308
-
1309
- let promise;
1310
- function wait() {
1311
- if (!promise) {
1312
- promise = Promise.resolve();
1313
- promise.then(() => {
1314
- promise = null;
1315
- });
1316
- }
1317
- return promise;
1318
- }
1319
- function dispatch(node, direction, kind) {
1320
- node.dispatchEvent(custom_event(`${direction ? 'intro' : 'outro'}${kind}`));
1321
- }
1322
- const outroing = new Set();
1323
- let outros;
1324
- function group_outros() {
1325
- outros = {
1326
- r: 0,
1327
- c: [],
1328
- p: outros // parent group
1329
- };
1330
- }
1331
- function check_outros() {
1332
- if (!outros.r) {
1333
- run_all(outros.c);
1334
- }
1335
- outros = outros.p;
1336
- }
1337
- function transition_in(block, local) {
1338
- if (block && block.i) {
1339
- outroing.delete(block);
1340
- block.i(local);
1341
- }
1342
- }
1343
- function transition_out(block, local, detach, callback) {
1344
- if (block && block.o) {
1345
- if (outroing.has(block))
1346
- return;
1347
- outroing.add(block);
1348
- outros.c.push(() => {
1349
- outroing.delete(block);
1350
- if (callback) {
1351
- if (detach)
1352
- block.d(1);
1353
- callback();
1354
- }
1355
- });
1356
- block.o(local);
1357
- }
1358
- else if (callback) {
1359
- callback();
1360
- }
1361
- }
1362
- const null_transition = { duration: 0 };
1363
- function create_in_transition(node, fn, params) {
1364
- const options = { direction: 'in' };
1365
- let config = fn(node, params, options);
1366
- let running = false;
1367
- let animation_name;
1368
- let task;
1369
- let uid = 0;
1370
- function cleanup() {
1371
- if (animation_name)
1372
- delete_rule(node, animation_name);
1373
- }
1374
- function go() {
1375
- const { delay = 0, duration = 300, easing = identity, tick = noop, css } = config || null_transition;
1376
- if (css)
1377
- animation_name = create_rule(node, 0, 1, duration, delay, easing, css, uid++);
1378
- tick(0, 1);
1379
- const start_time = exports.now() + delay;
1380
- const end_time = start_time + duration;
1381
- if (task)
1382
- task.abort();
1383
- running = true;
1384
- add_render_callback(() => dispatch(node, true, 'start'));
1385
- task = loop(now => {
1386
- if (running) {
1387
- if (now >= end_time) {
1388
- tick(1, 0);
1389
- dispatch(node, true, 'end');
1390
- cleanup();
1391
- return running = false;
1392
- }
1393
- if (now >= start_time) {
1394
- const t = easing((now - start_time) / duration);
1395
- tick(t, 1 - t);
1396
- }
1397
- }
1398
- return running;
1399
- });
1400
- }
1401
- let started = false;
1402
- return {
1403
- start() {
1404
- if (started)
1405
- return;
1406
- started = true;
1407
- delete_rule(node);
1408
- if (is_function(config)) {
1409
- config = config(options);
1410
- wait().then(go);
1411
- }
1412
- else {
1413
- go();
1414
- }
1415
- },
1416
- invalidate() {
1417
- started = false;
1418
- },
1419
- end() {
1420
- if (running) {
1421
- cleanup();
1422
- running = false;
1423
- }
1424
- }
1425
- };
1426
- }
1427
- function create_out_transition(node, fn, params) {
1428
- const options = { direction: 'out' };
1429
- let config = fn(node, params, options);
1430
- let running = true;
1431
- let animation_name;
1432
- const group = outros;
1433
- group.r += 1;
1434
- function go() {
1435
- const { delay = 0, duration = 300, easing = identity, tick = noop, css } = config || null_transition;
1436
- if (css)
1437
- animation_name = create_rule(node, 1, 0, duration, delay, easing, css);
1438
- const start_time = exports.now() + delay;
1439
- const end_time = start_time + duration;
1440
- add_render_callback(() => dispatch(node, false, 'start'));
1441
- loop(now => {
1442
- if (running) {
1443
- if (now >= end_time) {
1444
- tick(0, 1);
1445
- dispatch(node, false, 'end');
1446
- if (!--group.r) {
1447
- // this will result in `end()` being called,
1448
- // so we don't need to clean up here
1449
- run_all(group.c);
1450
- }
1451
- return false;
1452
- }
1453
- if (now >= start_time) {
1454
- const t = easing((now - start_time) / duration);
1455
- tick(1 - t, t);
1456
- }
1457
- }
1458
- return running;
1459
- });
1460
- }
1461
- if (is_function(config)) {
1462
- wait().then(() => {
1463
- // @ts-ignore
1464
- config = config(options);
1465
- go();
1466
- });
1467
- }
1468
- else {
1469
- go();
1470
- }
1471
- return {
1472
- end(reset) {
1473
- if (reset && config.tick) {
1474
- config.tick(1, 0);
1475
- }
1476
- if (running) {
1477
- if (animation_name)
1478
- delete_rule(node, animation_name);
1479
- running = false;
1480
- }
1481
- }
1482
- };
1483
- }
1484
- function create_bidirectional_transition(node, fn, params, intro) {
1485
- const options = { direction: 'both' };
1486
- let config = fn(node, params, options);
1487
- let t = intro ? 0 : 1;
1488
- let running_program = null;
1489
- let pending_program = null;
1490
- let animation_name = null;
1491
- function clear_animation() {
1492
- if (animation_name)
1493
- delete_rule(node, animation_name);
1494
- }
1495
- function init(program, duration) {
1496
- const d = (program.b - t);
1497
- duration *= Math.abs(d);
1498
- return {
1499
- a: t,
1500
- b: program.b,
1501
- d,
1502
- duration,
1503
- start: program.start,
1504
- end: program.start + duration,
1505
- group: program.group
1506
- };
1507
- }
1508
- function go(b) {
1509
- const { delay = 0, duration = 300, easing = identity, tick = noop, css } = config || null_transition;
1510
- const program = {
1511
- start: exports.now() + delay,
1512
- b
1513
- };
1514
- if (!b) {
1515
- // @ts-ignore todo: improve typings
1516
- program.group = outros;
1517
- outros.r += 1;
1518
- }
1519
- if (running_program || pending_program) {
1520
- pending_program = program;
1521
- }
1522
- else {
1523
- // if this is an intro, and there's a delay, we need to do
1524
- // an initial tick and/or apply CSS animation immediately
1525
- if (css) {
1526
- clear_animation();
1527
- animation_name = create_rule(node, t, b, duration, delay, easing, css);
1528
- }
1529
- if (b)
1530
- tick(0, 1);
1531
- running_program = init(program, duration);
1532
- add_render_callback(() => dispatch(node, b, 'start'));
1533
- loop(now => {
1534
- if (pending_program && now > pending_program.start) {
1535
- running_program = init(pending_program, duration);
1536
- pending_program = null;
1537
- dispatch(node, running_program.b, 'start');
1538
- if (css) {
1539
- clear_animation();
1540
- animation_name = create_rule(node, t, running_program.b, running_program.duration, 0, easing, config.css);
1541
- }
1542
- }
1543
- if (running_program) {
1544
- if (now >= running_program.end) {
1545
- tick(t = running_program.b, 1 - t);
1546
- dispatch(node, running_program.b, 'end');
1547
- if (!pending_program) {
1548
- // we're done
1549
- if (running_program.b) {
1550
- // intro — we can tidy up immediately
1551
- clear_animation();
1552
- }
1553
- else {
1554
- // outro — needs to be coordinated
1555
- if (!--running_program.group.r)
1556
- run_all(running_program.group.c);
1557
- }
1558
- }
1559
- running_program = null;
1560
- }
1561
- else if (now >= running_program.start) {
1562
- const p = now - running_program.start;
1563
- t = running_program.a + running_program.d * easing(p / running_program.duration);
1564
- tick(t, 1 - t);
1565
- }
1566
- }
1567
- return !!(running_program || pending_program);
1568
- });
1569
- }
1570
- }
1571
- return {
1572
- run(b) {
1573
- if (is_function(config)) {
1574
- wait().then(() => {
1575
- const opts = { direction: b ? 'in' : 'out' };
1576
- // @ts-ignore
1577
- config = config(opts);
1578
- go(b);
1579
- });
1580
- }
1581
- else {
1582
- go(b);
1583
- }
1584
- },
1585
- end() {
1586
- clear_animation();
1587
- running_program = pending_program = null;
1588
- }
1589
- };
1590
- }
1591
-
1592
- function bind(component, name, callback) {
1593
- const index = component.$$.props[name];
1594
- if (index !== undefined) {
1595
- component.$$.bound[index] = callback;
1596
- callback(component.$$.ctx[index]);
1597
- }
1598
- }
1599
- function create_component(block) {
1600
- block && block.c();
1601
- }
1602
- function claim_component(block, parent_nodes) {
1603
- block && block.l(parent_nodes);
1604
- }
1605
- function mount_component(component, target, anchor) {
1606
- const { fragment, after_update } = component.$$;
1607
- fragment && fragment.m(target, anchor);
1608
- // onMount happens before the initial afterUpdate
1609
- add_render_callback(() => {
1610
- const new_on_destroy = component.$$.on_mount.map(run).filter(is_function);
1611
- // if the component was destroyed immediately
1612
- // it will update the `$$.on_destroy` reference to `null`.
1613
- // the destructured on_destroy may still reference to the old array
1614
- if (component.$$.on_destroy) {
1615
- component.$$.on_destroy.push(...new_on_destroy);
1616
- }
1617
- else {
1618
- // Edge case - component was destroyed immediately,
1619
- // most likely as a result of a binding initialising
1620
- run_all(new_on_destroy);
1621
- }
1622
- component.$$.on_mount = [];
1623
- });
1624
- after_update.forEach(add_render_callback);
1625
- }
1626
- function destroy_component(component, detaching) {
1627
- const $$ = component.$$;
1628
- if ($$.fragment !== null) {
1629
- flush_render_callbacks($$.after_update);
1630
- run_all($$.on_destroy);
1631
- $$.fragment && $$.fragment.d(detaching);
1632
- // TODO null out other refs, including component.$$ (but need to
1633
- // preserve final state?)
1634
- $$.on_destroy = $$.fragment = null;
1635
- $$.ctx = [];
1636
- }
1637
- }
1638
- function make_dirty(component, i) {
1639
- if (component.$$.dirty[0] === -1) {
1640
- dirty_components.push(component);
1641
- schedule_update();
1642
- component.$$.dirty.fill(0);
1643
- }
1644
- component.$$.dirty[(i / 31) | 0] |= (1 << (i % 31));
1645
- }
1646
- function init(component, options, instance, create_fragment, not_equal, props, append_styles, dirty = [-1]) {
1647
- const parent_component = exports.current_component;
1648
- set_current_component(component);
1649
- const $$ = component.$$ = {
1650
- fragment: null,
1651
- ctx: [],
1652
- // state
1653
- props,
1654
- update: noop,
1655
- not_equal,
1656
- bound: blank_object(),
1657
- // lifecycle
1658
- on_mount: [],
1659
- on_destroy: [],
1660
- on_disconnect: [],
1661
- before_update: [],
1662
- after_update: [],
1663
- context: new Map(options.context || (parent_component ? parent_component.$$.context : [])),
1664
- // everything else
1665
- callbacks: blank_object(),
1666
- dirty,
1667
- skip_bound: false,
1668
- root: options.target || parent_component.$$.root
1669
- };
1670
- append_styles && append_styles($$.root);
1671
- let ready = false;
1672
- $$.ctx = instance
1673
- ? instance(component, options.props || {}, (i, ret, ...rest) => {
1674
- const value = rest.length ? rest[0] : ret;
1675
- if ($$.ctx && not_equal($$.ctx[i], $$.ctx[i] = value)) {
1676
- if (!$$.skip_bound && $$.bound[i])
1677
- $$.bound[i](value);
1678
- if (ready)
1679
- make_dirty(component, i);
1680
- }
1681
- return ret;
1682
- })
1683
- : [];
1684
- $$.update();
1685
- ready = true;
1686
- run_all($$.before_update);
1687
- // `false` as a special case of no DOM component
1688
- $$.fragment = create_fragment ? create_fragment($$.ctx) : false;
1689
- if (options.target) {
1690
- if (options.hydrate) {
1691
- start_hydrating();
1692
- const nodes = children(options.target);
1693
- // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
1694
- $$.fragment && $$.fragment.l(nodes);
1695
- nodes.forEach(detach);
1696
- }
1697
- else {
1698
- // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
1699
- $$.fragment && $$.fragment.c();
1700
- }
1701
- if (options.intro)
1702
- transition_in(component.$$.fragment);
1703
- mount_component(component, options.target, options.anchor);
1704
- end_hydrating();
1705
- flush();
1706
- }
1707
- set_current_component(parent_component);
1708
- }
1709
- exports.SvelteElement = void 0;
1710
- if (typeof HTMLElement === 'function') {
1711
- exports.SvelteElement = class extends HTMLElement {
1712
- constructor($$componentCtor, $$slots, use_shadow_dom) {
1713
- super();
1714
- this.$$componentCtor = $$componentCtor;
1715
- this.$$slots = $$slots;
1716
- this.$$connected = false;
1717
- this.$$data = {};
1718
- this.$$reflecting = false;
1719
- this.$$props_definition = {};
1720
- this.$$listeners = {};
1721
- this.$$listener_unsubscribe_fns = new Map();
1722
- if (use_shadow_dom) {
1723
- this.attachShadow({ mode: 'open' });
1724
- }
1725
- }
1726
- addEventListener(type, listener, options) {
1727
- // We can't determine upfront if the event is a custom event or not, so we have to
1728
- // listen to both. If someone uses a custom event with the same name as a regular
1729
- // browser event, this fires twice - we can't avoid that.
1730
- this.$$listeners[type] = this.$$listeners[type] || [];
1731
- this.$$listeners[type].push(listener);
1732
- if (this.$$component) {
1733
- const unsub = this.$$component.$on(type, listener);
1734
- this.$$listener_unsubscribe_fns.set(listener, unsub);
1735
- }
1736
- super.addEventListener(type, listener, options);
1737
- }
1738
- removeEventListener(type, listener, options) {
1739
- super.removeEventListener(type, listener, options);
1740
- if (this.$$component) {
1741
- const unsub = this.$$listener_unsubscribe_fns.get(listener);
1742
- if (unsub) {
1743
- unsub();
1744
- this.$$listener_unsubscribe_fns.delete(listener);
1745
- }
1746
- }
1747
- }
1748
- async connectedCallback() {
1749
- this.$$connected = true;
1750
- if (!this.$$component) {
1751
- // We wait one tick to let possible child slot elements be created/mounted
1752
- await Promise.resolve();
1753
- if (!this.$$connected) {
1754
- return;
1755
- }
1756
- function create_slot(name) {
1757
- return () => {
1758
- let node;
1759
- const obj = {
1760
- c: function create() {
1761
- node = document.createElement('slot');
1762
- if (name !== 'default') {
1763
- node.setAttribute('name', name);
1764
- }
1765
- },
1766
- m: function mount(target, anchor) {
1767
- insert(target, node, anchor);
1768
- },
1769
- d: function destroy(detaching) {
1770
- if (detaching) {
1771
- detach(node);
1772
- }
1773
- }
1774
- };
1775
- return obj;
1776
- };
1777
- }
1778
- const $$slots = {};
1779
- const existing_slots = get_custom_elements_slots(this);
1780
- for (const name of this.$$slots) {
1781
- if (name in existing_slots) {
1782
- $$slots[name] = [create_slot(name)];
1783
- }
1784
- }
1785
- for (const attribute of this.attributes) {
1786
- // this.$$data takes precedence over this.attributes
1787
- const name = this.$$get_prop_name(attribute.name);
1788
- if (!(name in this.$$data)) {
1789
- this.$$data[name] = get_custom_element_value(name, attribute.value, this.$$props_definition, 'toProp');
1790
- }
1791
- }
1792
- this.$$component = new this.$$componentCtor({
1793
- target: this.shadowRoot || this,
1794
- props: Object.assign(Object.assign({}, this.$$data), { $$slots, $$scope: {
1795
- ctx: []
1796
- } })
1797
- });
1798
- for (const type in this.$$listeners) {
1799
- for (const listener of this.$$listeners[type]) {
1800
- const unsub = this.$$component.$on(type, listener);
1801
- this.$$listener_unsubscribe_fns.set(listener, unsub);
1802
- }
1803
- }
1804
- this.$$listeners = {};
1805
- }
1806
- }
1807
- // We don't need this when working within Svelte code, but for compatibility of people using this outside of Svelte
1808
- // and setting attributes through setAttribute etc, this is helpful
1809
- attributeChangedCallback(attr, _oldValue, newValue) {
1810
- if (this.$$reflecting)
1811
- return;
1812
- attr = this.$$get_prop_name(attr);
1813
- this.$$data[attr] = get_custom_element_value(attr, newValue, this.$$props_definition, 'toProp');
1814
- this.$$component.$set({ [attr]: this.$$data[attr] });
1815
- }
1816
- disconnectedCallback() {
1817
- this.$$connected = false;
1818
- // In a microtask, because this could be a move within the DOM
1819
- Promise.resolve().then(() => {
1820
- if (!this.$$connected) {
1821
- this.$$component.$destroy();
1822
- this.$$component = undefined;
1823
- }
1824
- });
1825
- }
1826
- $$get_prop_name(attribute_name) {
1827
- return Object.keys(this.$$props_definition).find(key => this.$$props_definition[key].attribute === attribute_name ||
1828
- (!this.$$props_definition[key].attribute && key.toLowerCase() === attribute_name)) || attribute_name;
1829
- }
1830
- };
1831
- }
1832
- function get_custom_element_value(prop, value, props_definition, transform) {
1833
- var _a;
1834
- const type = (_a = props_definition[prop]) === null || _a === void 0 ? void 0 : _a.type;
1835
- value = type === 'Boolean' && typeof value !== 'boolean' ? value != null : value;
1836
- if (!transform || !props_definition[prop]) {
1837
- return value;
1838
- }
1839
- else if (transform === 'toAttribute') {
1840
- switch (type) {
1841
- case 'Object':
1842
- case 'Array':
1843
- return value == null ? null : JSON.stringify(value);
1844
- case 'Boolean':
1845
- return value ? '' : null;
1846
- case 'Number':
1847
- return value == null ? null : value;
1848
- default:
1849
- return value;
1850
- }
1851
- }
1852
- else {
1853
- switch (type) {
1854
- case 'Object':
1855
- case 'Array':
1856
- return value && JSON.parse(value);
1857
- case 'Boolean':
1858
- return value; // conversion already handled above
1859
- case 'Number':
1860
- return value != null ? +value : value;
1861
- default:
1862
- return value;
1863
- }
1864
- }
1865
- }
1866
- /**
1867
- * @internal
1868
- *
1869
- * Turn a Svelte component into a custom element.
1870
- * @param Component A Svelte component constructor
1871
- * @param props_definition The props to observe
1872
- * @param slots The slots to create
1873
- * @param accessors Other accessors besides the ones for props the component has
1874
- * @param use_shadow_dom Whether to use shadow DOM
1875
- * @returns A custom element class
1876
- */
1877
- function create_custom_element(Component, props_definition, slots, accessors, use_shadow_dom) {
1878
- const Class = class extends exports.SvelteElement {
1879
- constructor() {
1880
- super(Component, slots, use_shadow_dom);
1881
- this.$$props_definition = props_definition;
1882
- }
1883
- static get observedAttributes() {
1884
- return Object.keys(props_definition).map(key => (props_definition[key].attribute || key).toLowerCase());
1885
- }
1886
- };
1887
- Object.keys(props_definition).forEach((prop) => {
1888
- Object.defineProperty(Class.prototype, prop, {
1889
- get() {
1890
- return this.$$component && prop in this.$$component
1891
- ? this.$$component[prop]
1892
- : this.$$data[prop];
1893
- },
1894
- set(value) {
1895
- var _a;
1896
- value = get_custom_element_value(prop, value, props_definition);
1897
- this.$$data[prop] = value;
1898
- (_a = this.$$component) === null || _a === void 0 ? void 0 : _a.$set({ [prop]: value });
1899
- if (props_definition[prop].reflect) {
1900
- this.$$reflecting = true;
1901
- const attribute_value = get_custom_element_value(prop, value, props_definition, 'toAttribute');
1902
- if (attribute_value == null) {
1903
- this.removeAttribute(prop);
1904
- }
1905
- else {
1906
- this.setAttribute(props_definition[prop].attribute || prop, attribute_value);
1907
- }
1908
- this.$$reflecting = false;
1909
- }
1910
- }
1911
- });
1912
- });
1913
- accessors.forEach(accessor => {
1914
- Object.defineProperty(Class.prototype, accessor, {
1915
- get() {
1916
- var _a;
1917
- return (_a = this.$$component) === null || _a === void 0 ? void 0 : _a[accessor];
1918
- }
1919
- });
1920
- });
1921
- Component.element = Class;
1922
- return Class;
1923
- }
1924
- /**
1925
- * Base class for Svelte components. Used when dev=false.
1926
- */
1927
- class SvelteComponent {
1928
- $destroy() {
1929
- destroy_component(this, 1);
1930
- this.$destroy = noop;
1931
- }
1932
- $on(type, callback) {
1933
- if (!is_function(callback)) {
1934
- return noop;
1935
- }
1936
- const callbacks = (this.$$.callbacks[type] || (this.$$.callbacks[type] = []));
1937
- callbacks.push(callback);
1938
- return () => {
1939
- const index = callbacks.indexOf(callback);
1940
- if (index !== -1)
1941
- callbacks.splice(index, 1);
1942
- };
1943
- }
1944
- $set($$props) {
1945
- if (this.$$set && !is_empty($$props)) {
1946
- this.$$.skip_bound = true;
1947
- this.$$set($$props);
1948
- this.$$.skip_bound = false;
1949
- }
1950
- }
1951
- }
1952
-
1953
- exports.HtmlTag = HtmlTag;
1954
- exports.HtmlTagHydration = HtmlTagHydration;
1955
- exports.ResizeObserverSingleton = ResizeObserverSingleton;
1956
- exports.SvelteComponent = SvelteComponent;
1957
- exports.action_destroyer = action_destroyer;
1958
- exports.add_flush_callback = add_flush_callback;
1959
- exports.add_iframe_resize_listener = add_iframe_resize_listener;
1960
- exports.add_location = add_location;
1961
- exports.add_render_callback = add_render_callback;
1962
- exports.afterUpdate = afterUpdate;
1963
- exports.append = append;
1964
- exports.append_empty_stylesheet = append_empty_stylesheet;
1965
- exports.append_hydration = append_hydration;
1966
- exports.append_styles = append_styles;
1967
- exports.assign = assign;
1968
- exports.attr = attr;
1969
- exports.attribute_to_object = attribute_to_object;
1970
- exports.beforeUpdate = beforeUpdate;
1971
- exports.bind = bind;
1972
- exports.binding_callbacks = binding_callbacks;
1973
- exports.blank_object = blank_object;
1974
- exports.bubble = bubble;
1975
- exports.check_outros = check_outros;
1976
- exports.children = children;
1977
- exports.claim_comment = claim_comment;
1978
- exports.claim_component = claim_component;
1979
- exports.claim_element = claim_element;
1980
- exports.claim_html_tag = claim_html_tag;
1981
- exports.claim_space = claim_space;
1982
- exports.claim_svg_element = claim_svg_element;
1983
- exports.claim_text = claim_text;
1984
- exports.clear_loops = clear_loops;
1985
- exports.comment = comment;
1986
- exports.component_subscribe = component_subscribe;
1987
- exports.compute_rest_props = compute_rest_props;
1988
- exports.compute_slots = compute_slots;
1989
- exports.construct_svelte_component = construct_svelte_component;
1990
- exports.contenteditable_truthy_values = contenteditable_truthy_values;
1991
- exports.createEventDispatcher = createEventDispatcher;
1992
- exports.create_bidirectional_transition = create_bidirectional_transition;
1993
- exports.create_component = create_component;
1994
- exports.create_custom_element = create_custom_element;
1995
- exports.create_in_transition = create_in_transition;
1996
- exports.create_out_transition = create_out_transition;
1997
- exports.create_rule = create_rule;
1998
- exports.create_slot = create_slot;
1999
- exports.custom_event = custom_event;
2000
- exports.delete_rule = delete_rule;
2001
- exports.destroy_component = destroy_component;
2002
- exports.destroy_each = destroy_each;
2003
- exports.detach = detach;
2004
- exports.dirty_components = dirty_components;
2005
- exports.element = element;
2006
- exports.element_is = element_is;
2007
- exports.empty = empty;
2008
- exports.end_hydrating = end_hydrating;
2009
- exports.exclude_internal_props = exclude_internal_props;
2010
- exports.flush = flush;
2011
- exports.flush_render_callbacks = flush_render_callbacks;
2012
- exports.getAllContexts = getAllContexts;
2013
- exports.getContext = getContext;
2014
- exports.get_all_dirty_from_scope = get_all_dirty_from_scope;
2015
- exports.get_binding_group_value = get_binding_group_value;
2016
- exports.get_current_component = get_current_component;
2017
- exports.get_custom_elements_slots = get_custom_elements_slots;
2018
- exports.get_root_for_style = get_root_for_style;
2019
- exports.get_slot_changes = get_slot_changes;
2020
- exports.get_store_value = get_store_value;
2021
- exports.get_svelte_dataset = get_svelte_dataset;
2022
- exports.globals = globals;
2023
- exports.group_outros = group_outros;
2024
- exports.hasContext = hasContext;
2025
- exports.has_prop = has_prop;
2026
- exports.head_selector = head_selector;
2027
- exports.identity = identity;
2028
- exports.init = init;
2029
- exports.init_binding_group = init_binding_group;
2030
- exports.init_binding_group_dynamic = init_binding_group_dynamic;
2031
- exports.insert = insert;
2032
- exports.insert_hydration = insert_hydration;
2033
- exports.intros = intros;
2034
- exports.is_client = is_client;
2035
- exports.is_crossorigin = is_crossorigin;
2036
- exports.is_empty = is_empty;
2037
- exports.is_function = is_function;
2038
- exports.is_promise = is_promise;
2039
- exports.listen = listen;
2040
- exports.loop = loop;
2041
- exports.mount_component = mount_component;
2042
- exports.noop = noop;
2043
- exports.not_equal = not_equal;
2044
- exports.null_to_empty = null_to_empty;
2045
- exports.object_without_properties = object_without_properties;
2046
- exports.onDestroy = onDestroy;
2047
- exports.onMount = onMount;
2048
- exports.once = once;
2049
- exports.prevent_default = prevent_default;
2050
- exports.query_selector_all = query_selector_all;
2051
- exports.resize_observer_border_box = resize_observer_border_box;
2052
- exports.resize_observer_content_box = resize_observer_content_box;
2053
- exports.resize_observer_device_pixel_content_box = resize_observer_device_pixel_content_box;
2054
- exports.run = run;
2055
- exports.run_all = run_all;
2056
- exports.safe_not_equal = safe_not_equal;
2057
- exports.schedule_update = schedule_update;
2058
- exports.select_multiple_value = select_multiple_value;
2059
- exports.select_option = select_option;
2060
- exports.select_options = select_options;
2061
- exports.select_value = select_value;
2062
- exports.self = self;
2063
- exports.setContext = setContext;
2064
- exports.set_attributes = set_attributes;
2065
- exports.set_current_component = set_current_component;
2066
- exports.set_custom_element_data = set_custom_element_data;
2067
- exports.set_custom_element_data_map = set_custom_element_data_map;
2068
- exports.set_data = set_data;
2069
- exports.set_data_contenteditable = set_data_contenteditable;
2070
- exports.set_data_maybe_contenteditable = set_data_maybe_contenteditable;
2071
- exports.set_dynamic_element_data = set_dynamic_element_data;
2072
- exports.set_input_type = set_input_type;
2073
- exports.set_input_value = set_input_value;
2074
- exports.set_now = set_now;
2075
- exports.set_raf = set_raf;
2076
- exports.set_store_value = set_store_value;
2077
- exports.set_style = set_style;
2078
- exports.set_svg_attributes = set_svg_attributes;
2079
- exports.space = space;
2080
- exports.split_css_unit = split_css_unit;
2081
- exports.src_url_equal = src_url_equal;
2082
- exports.start_hydrating = start_hydrating;
2083
- exports.stop_immediate_propagation = stop_immediate_propagation;
2084
- exports.stop_propagation = stop_propagation;
2085
- exports.subscribe = subscribe;
2086
- exports.svg_element = svg_element;
2087
- exports.text = text;
2088
- exports.tick = tick;
2089
- exports.time_ranges_to_array = time_ranges_to_array;
2090
- exports.to_number = to_number;
2091
- exports.toggle_class = toggle_class;
2092
- exports.transition_in = transition_in;
2093
- exports.transition_out = transition_out;
2094
- exports.trusted = trusted;
2095
- exports.update_slot = update_slot;
2096
- exports.update_slot_base = update_slot_base;
2097
- exports.validate_store = validate_store;
2098
- exports.xlink_attr = xlink_attr;