PageSourceSearch

https://milanairports.com/libraries/dorag-build2/app.module-HB53SYD5.js

js milanairports.com collected 2026-09-24 09:38:08 UTC 3,460,660 bytes, 83,000 lines download raw bytes

1import {
2  APP_ID,
3  ApplicationRef,
4  Attribute,
5  BrowserModule,
6  ChangeDetectionStrategy,
7  ChangeDetectorRef,
8  CommonModule,
9  Component,
10  ContentChild,
11  ContentChildren,
12  DOCUMENT,
13  DatePipe,
14  DecimalPipe,
15  Directive,
16  DomSanitizer,
17  ElementRef,
18  EnvironmentInjector,
19  EventEmitter,
20  Host,
21  HostBinding,
22  HostListener,
23  HttpClient,
24  HttpClientJsonpModule,
25  HttpHeaders,
26  Inject,
27  Injectable,
28  InjectionToken,
29  Injector,
30  Input,
31  NgClass,
32  NgForOf,
33  NgIf,
34  NgModule,
35  NgTemplateOutlet,
36  NgZone,
37  Optional,
38  Output,
39  Pipe,
40  Renderer2,
41  RuntimeError,
42  Self,
43  SkipSelf,
44  Subject,
45  TemplateRef,
46  Version,
47  ViewChild,
48  ViewContainerRef,
49  ViewEncapsulation,
50  __async,
51  __commonJS,
52  __decorate,
53  __metadata,
54  __spreadProps,
55  __spreadValues,
56  __toESM,
57  afterNextRender,
58  animationFrameScheduler,
59  asapScheduler,
60  auditTime,
61  booleanAttribute,
62  catchError,
63  computed,
64  concat,
65  concatMap,
66  createComponent,
67  debounceTime,
68  defer,
69  effect,
70  filter,
71  firstValueFrom,
72  forkJoin,
73  formatDate,
74  formatNumber,
75  forwardRef,
76  from,
77  fromEvent,
78  getDOM,
79  inject,
80  input,
81  isObservable,
82  isPromise,
83  isSubscribable,
84  makeEnvironmentProviders,
85  map,
86  merge,
87  numberAttribute,
88  of,
89  provideHttpClient,
90  registerLocaleData,
91  setClassMetadata,
92  shareReplay,
93  signal,
94  startWith,
95  switchMap,
96  take,
97  takeUntil,
98  tap,
99  timer,
100  untracked,
101  ɵsetClassDebugInfo,
102  ɵɵInheritDefinitionFeature,
103  ɵɵNgOnChangesFeature,
104  ɵɵProvidersFeature,
105  ɵɵadvance,
106  ɵɵattribute,
107  ɵɵclassMap,
108  ɵɵclassProp,
109  ɵɵcomponentInstance,
110  ɵɵconditional,
111  ɵɵcontentQuery,
112  ɵɵdefineComponent,
113  ɵɵdefineDirective,
114  ɵɵdefineInjectable,
115  ɵɵdefineInjector,
116  ɵɵdefineNgModule,
117  ɵɵdefinePipe,
118  ɵɵdirectiveInject,
119  ɵɵelement,
120  ɵɵelementContainer,
121  ɵɵelementContainerEnd,
122  ɵɵelementContainerStart,
123  ɵɵelementEnd,
124  ɵɵelementStart,
125  ɵɵgetCurrentView,
126  ɵɵgetInheritedFactory,
127  ɵɵhostProperty,
128  ɵɵinject,
129  ɵɵinjectAttribute,
130  ɵɵlistener,
131  ɵɵloadQuery,
132  ɵɵnextContext,
133  ɵɵpipe,
134  ɵɵpipeBind1,
135  ɵɵpipeBind2,
136  ɵɵprojection,
137  ɵɵprojectionDef,
138  ɵɵproperty,
139  ɵɵpropertyInterpolate,
140  ɵɵpureFunction1,
141  ɵɵpureFunction2,
142  ɵɵpureFunction3,
143  ɵɵpureFunction4,
144  ɵɵqueryRefresh,
145  ɵɵreference,
146  ɵɵrepeater,
147  ɵɵrepeaterCreate,
148  ɵɵresetView,
149  ɵɵresolveDocument,
150  ɵɵresolveWindow,
151  ɵɵrestoreView,
152  ɵɵsanitizeHtml,
153  ɵɵsanitizeResourceUrl,
154  ɵɵsanitizeUrl,
155  ɵɵstyleProp,
156  ɵɵtemplate,
157  ɵɵtemplateRefExtractor,
158  ɵɵtext,
159  ɵɵtextInterpolate,
160  ɵɵtextInterpolate1,
161  ɵɵtextInterpolate2,
162  ɵɵtwoWayBindingSet,
163  ɵɵtwoWayListener,
164  ɵɵtwoWayProperty,
165  ɵɵviewQuery
166} from "./chunk-6SQWLHQI.js";
167
vendor: 39,035 bytes, lines 168-1200
168// node_modules/reflect-metadata/Reflect.js
169var require_Reflect = __commonJS({
170  "node_modules/reflect-metadata/Reflect.js"() {
171    "use strict";
172    var Reflect2;
173    (function(Reflect3) {
174      (function(factory) {
175        var root = typeof globalThis === "object" ? globalThis : typeof global === "object" ? global : typeof self === "object" ? self : typeof this === "object" ? this : sloppyModeThis();
176        var exporter = makeExporter(Reflect3);
177        if (typeof root.Reflect !== "undefined") {
178          exporter = makeExporter(root.Reflect, exporter);
179        }
180        factory(exporter, root);
181        if (typeof root.Reflect === "undefined") {
182          root.Reflect = Reflect3;
183        }
184        function makeExporter(target, previous) {
185          return function(key, value) {
186            Object.defineProperty(target, key, {
187              configurable: true,
188              writable: true,
189              value
190            });
191            if (previous) previous(key, value);
192          };
193        }
194        function functionThis() {
195          try {
196            return Function("return this;")();
197          } catch (_2) {
198          }
199        }
200        function indirectEvalThis() {
201          try {
202            return (void 0, eval)("(function() { return this; })()");
203          } catch (_2) {
204          }
205        }
206        function sloppyModeThis() {
207          return functionThis() || indirectEvalThis();
208        }
209      })(function(exporter, root) {
210        var hasOwn = Object.prototype.hasOwnProperty;
211        var supportsSymbol = typeof Symbol === "function";
212        var toPrimitiveSymbol = supportsSymbol && typeof Symbol.toPrimitive !== "undefined" ? Symbol.toPrimitive : "@@toPrimitive";
213        var iteratorSymbol = supportsSymbol && typeof Symbol.iterator !== "undefined" ? Symbol.iterator : "@@iterator";
214        var supportsCreate = typeof Object.create === "function";
215        var supportsProto = {
216          __proto__: []
217        } instanceof Array;
218        var downLevel = !supportsCreate && !supportsProto;
219        var HashMap = {
220          // create an object in dictionary mode (a.k.a. "slow" mode in v8)
221          create: supportsCreate ? function() {
222            return MakeDictionary(/* @__PURE__ */ Object.create(null));
223          } : supportsProto ? function() {
224            return MakeDictionary({
225              __proto__: null
226            });
227          } : function() {
228            return MakeDictionary({});
229          },
230          has: downLevel ? function(map2, key) {
231            return hasOwn.call(map2, key);
232          } : function(map2, key) {
233            return key in map2;
234          },
235          get: downLevel ? function(map2, key) {
236            return hasOwn.call(map2, key) ? map2[key] : void 0;
237          } : function(map2, key) {
238            return map2[key];
239          }
240        };
241        var functionPrototype = Object.getPrototypeOf(Function);
242        var _Map = typeof Map === "function" && typeof Map.prototype.entries === "function" ? Map : CreateMapPolyfill();
243        var _Set = typeof Set === "function" && typeof Set.prototype.entries === "function" ? Set : CreateSetPolyfill();
244        var _WeakMap = typeof WeakMap === "function" ? WeakMap : CreateWeakMapPolyfill();
245        var registrySymbol = supportsSymbol ? Symbol.for("@reflect-metadata:registry") : void 0;
246        var metadataRegistry = GetOrCreateMetadataRegistry();
247        var metadataProvider = CreateMetadataProvider(metadataRegistry);
248        function decorate(decorators, target, propertyKey, attributes) {
249          if (!IsUndefined(propertyKey)) {
250            if (!IsArray(decorators)) throw new TypeError();
251            if (!IsObject(target)) throw new TypeError();
252            if (!IsObject(attributes) && !IsUndefined(attributes) && !IsNull(attributes)) throw new TypeError();
253            if (IsNull(attributes)) attributes = void 0;
254            propertyKey = ToPropertyKey(propertyKey);
255            return DecorateProperty(decorators, target, propertyKey, attributes);
256          } else {
257            if (!IsArray(decorators)) throw new TypeError();
258            if (!IsConstructor(target)) throw new TypeError();
259            return DecorateConstructor(decorators, target);
260          }
261        }
262        exporter("decorate", decorate);
263        function metadata(metadataKey, metadataValue) {
264          function decorator(target, propertyKey) {
265            if (!IsObject(target)) throw new TypeError();
266            if (!IsUndefined(propertyKey) && !IsPropertyKey(propertyKey)) throw new TypeError();
267            OrdinaryDefineOwnMetadata(metadataKey, metadataValue, target, propertyKey);
268          }
269          return decorator;
270        }
271        exporter("metadata", metadata);
272        function defineMetadata(metadataKey, metadataValue, target, propertyKey) {
273          if (!IsObject(target)) throw new TypeError();
274          if (!IsUndefined(propertyKey)) propertyKey = ToPropertyKey(propertyKey);
275          return OrdinaryDefineOwnMetadata(metadataKey, metadataValue, target, propertyKey);
276        }
277        exporter("defineMetadata", defineMetadata);
278        function hasMetadata(metadataKey, target, propertyKey) {
279          if (!IsObject(target)) throw new TypeError();
280          if (!IsUndefined(propertyKey)) propertyKey = ToPropertyKey(propertyKey);
281          return OrdinaryHasMetadata(metadataKey, target, propertyKey);
282        }
283        exporter("hasMetadata", hasMetadata);
284        function hasOwnMetadata(metadataKey, target, propertyKey) {
285          if (!IsObject(target)) throw new TypeError();
286          if (!IsUndefined(propertyKey)) propertyKey = ToPropertyKey(propertyKey);
287          return OrdinaryHasOwnMetadata(metadataKey, target, propertyKey);
288        }
289        exporter("hasOwnMetadata", hasOwnMetadata);
290        function getMetadata(metadataKey, target, propertyKey) {
291          if (!IsObject(target)) throw new TypeError();
292          if (!IsUndefined(propertyKey)) propertyKey = ToPropertyKey(propertyKey);
293          return OrdinaryGetMetadata(metadataKey, target, propertyKey);
294        }
295        exporter("getMetadata", getMetadata);
296        function getOwnMetadata(metadataKey, target, propertyKey) {
297          if (!IsObject(target)) throw new TypeError();
298          if (!IsUndefined(propertyKey)) propertyKey = ToPropertyKey(propertyKey);
299          return OrdinaryGetOwnMetadata(metadataKey, target, propertyKey);
300        }
301        exporter("getOwnMetadata", getOwnMetadata);
302        function getMetadataKeys(target, propertyKey) {
303          if (!IsObject(target)) throw new TypeError();
304          if (!IsUndefined(propertyKey)) propertyKey = ToPropertyKey(propertyKey);
305          return OrdinaryMetadataKeys(target, propertyKey);
306        }
307        exporter("getMetadataKeys", getMetadataKeys);
308        function getOwnMetadataKeys(target, propertyKey) {
309          if (!IsObject(target)) throw new TypeError();
310          if (!IsUndefined(propertyKey)) propertyKey = ToPropertyKey(propertyKey);
311          return OrdinaryOwnMetadataKeys(target, propertyKey);
312        }
313        exporter("getOwnMetadataKeys", getOwnMetadataKeys);
314        function deleteMetadata(metadataKey, target, propertyKey) {
315          if (!IsObject(target)) throw new TypeError();
316          if (!IsUndefined(propertyKey)) propertyKey = ToPropertyKey(propertyKey);
317          if (!IsObject(target)) throw new TypeError();
318          if (!IsUndefined(propertyKey)) propertyKey = ToPropertyKey(propertyKey);
319          var provider = GetMetadataProvider(
320            target,
321            propertyKey,
322            /*Create*/
323            false
324          );
325          if (IsUndefined(provider)) return false;
326          return provider.OrdinaryDeleteMetadata(metadataKey, target, propertyKey);
327        }
328        exporter("deleteMetadata", deleteMetadata);
329        function DecorateConstructor(decorators, target) {
330          for (var i = decorators.length - 1; i >= 0; --i) {
331            var decorator = decorators[i];
332            var decorated = decorator(target);
333            if (!IsUndefined(decorated) && !IsNull(decorated)) {
334              if (!IsConstructor(decorated)) throw new TypeError();
335              target = decorated;
336            }
337          }
338          return target;
339        }
340        function DecorateProperty(decorators, target, propertyKey, descriptor) {
341          for (var i = decorators.length - 1; i >= 0; --i) {
342            var decorator = decorators[i];
343            var decorated = decorator(target, propertyKey, descriptor);
344            if (!IsUndefined(decorated) && !IsNull(decorated)) {
345              if (!IsObject(decorated)) throw new TypeError();
346              descriptor = decorated;
347            }
348          }
349          return descriptor;
350        }
351        function OrdinaryHasMetadata(MetadataKey, O, P) {
352          var hasOwn2 = OrdinaryHasOwnMetadata(MetadataKey, O, P);
353          if (hasOwn2) return true;
354          var parent = OrdinaryGetPrototypeOf(O);
355          if (!IsNull(parent)) return OrdinaryHasMetadata(MetadataKey, parent, P);
356          return false;
357        }
358        function OrdinaryHasOwnMetadata(MetadataKey, O, P) {
359          var provider = GetMetadataProvider(
360            O,
361            P,
362            /*Create*/
363            false
364          );
365          if (IsUndefined(provider)) return false;
366          return ToBoolean(provider.OrdinaryHasOwnMetadata(MetadataKey, O, P));
367        }
368        function OrdinaryGetMetadata(MetadataKey, O, P) {
369          var hasOwn2 = OrdinaryHasOwnMetadata(MetadataKey, O, P);
370          if (hasOwn2) return OrdinaryGetOwnMetadata(MetadataKey, O, P);
371          var parent = OrdinaryGetPrototypeOf(O);
372          if (!IsNull(parent)) return OrdinaryGetMetadata(MetadataKey, parent, P);
373          return void 0;
374        }
375        function OrdinaryGetOwnMetadata(MetadataKey, O, P) {
376          var provider = GetMetadataProvider(
377            O,
378            P,
379            /*Create*/
380            false
381          );
382          if (IsUndefined(provider)) return;
383          return provider.OrdinaryGetOwnMetadata(MetadataKey, O, P);
384        }
385        function OrdinaryDefineOwnMetadata(MetadataKey, MetadataValue, O, P) {
386          var provider = GetMetadataProvider(
387            O,
388            P,
389            /*Create*/
390            true
391          );
392          provider.OrdinaryDefineOwnMetadata(MetadataKey, MetadataValue, O, P);
393        }
394        function OrdinaryMetadataKeys(O, P) {
395          var ownKeys = OrdinaryOwnMetadataKeys(O, P);
396          var parent = OrdinaryGetPrototypeOf(O);
397          if (parent === null) return ownKeys;
398          var parentKeys = OrdinaryMetadataKeys(parent, P);
399          if (parentKeys.length <= 0) return ownKeys;
400          if (ownKeys.length <= 0) return parentKeys;
401          var set = new _Set();
402          var keys = [];
403          for (var _i = 0, ownKeys_1 = ownKeys; _i < ownKeys_1.length; _i++) {
404            var key = ownKeys_1[_i];
405            var hasKey = set.has(key);
406            if (!hasKey) {
407              set.add(key);
408              keys.push(key);
409            }
410          }
411          for (var _a = 0, parentKeys_1 = parentKeys; _a < parentKeys_1.length; _a++) {
412            var key = parentKeys_1[_a];
413            var hasKey = set.has(key);
414            if (!hasKey) {
415              set.add(key);
416              keys.push(key);
417            }
418          }
419          return keys;
420        }
421        function OrdinaryOwnMetadataKeys(O, P) {
422          var provider = GetMetadataProvider(
423            O,
424            P,
425            /*create*/
426            false
427          );
428          if (!provider) {
429            return [];
430          }
431          return provider.OrdinaryOwnMetadataKeys(O, P);
432        }
433        function Type(x) {
434          if (x === null) return 1;
435          switch (typeof x) {
436            case "undefined":
437              return 0;
438            case "boolean":
439              return 2;
440            case "string":
441              return 3;
442            case "symbol":
443              return 4;
444            case "number":
445              return 5;
446            case "object":
447              return x === null ? 1 : 6;
448            default:
449              return 6;
450          }
451        }
452        function IsUndefined(x) {
453          return x === void 0;
454        }
455        function IsNull(x) {
456          return x === null;
457        }
458        function IsSymbol(x) {
459          return typeof x === "symbol";
460        }
461        function IsObject(x) {
462          return typeof x === "object" ? x !== null : typeof x === "function";
463        }
464        function ToPrimitive(input2, PreferredType) {
465          switch (Type(input2)) {
466            case 0:
467              return input2;
468            case 1:
469              return input2;
470            case 2:
471              return input2;
472            case 3:
473              return input2;
474            case 4:
475              return input2;
476            case 5:
477              return input2;
478          }
479          var hint = PreferredType === 3 ? "string" : PreferredType === 5 ? "number" : "default";
480          var exoticToPrim = GetMethod(input2, toPrimitiveSymbol);
481          if (exoticToPrim !== void 0) {
482            var result = exoticToPrim.call(input2, hint);
483            if (IsObject(result)) throw new TypeError();
484            return result;
485          }
486          return OrdinaryToPrimitive(input2, hint === "default" ? "number" : hint);
487        }
488        function OrdinaryToPrimitive(O, hint) {
489          if (hint === "string") {
490            var toString_1 = O.toString;
491            if (IsCallable(toString_1)) {
492              var result = toString_1.call(O);
493              if (!IsObject(result)) return result;
494            }
495            var valueOf = O.valueOf;
496            if (IsCallable(valueOf)) {
497              var result = valueOf.call(O);
498              if (!IsObject(result)) return result;
499            }
500          } else {
501            var valueOf = O.valueOf;
502            if (IsCallable(valueOf)) {
503              var result = valueOf.call(O);
504              if (!IsObject(result)) return result;
505            }
506            var toString_2 = O.toString;
507            if (IsCallable(toString_2)) {
508              var result = toString_2.call(O);
509              if (!IsObject(result)) return result;
510            }
511          }
512          throw new TypeError();
513        }
514        function ToBoolean(argument) {
515          return !!argument;
516        }
517        function ToString(argument) {
518          return "" + argument;
519        }
520        function ToPropertyKey(argument) {
521          var key = ToPrimitive(
522            argument,
523            3
524            /* String */
525          );
526          if (IsSymbol(key)) return key;
527          return ToString(key);
528        }
529        function IsArray(argument) {
530          return Array.isArray ? Array.isArray(argument) : argument instanceof Object ? argument instanceof Array : Object.prototype.toString.call(argument) === "[object Array]";
531        }
532        function IsCallable(argument) {
533          return typeof argument === "function";
534        }
535        function IsConstructor(argument) {
536          return typeof argument === "function";
537        }
538        function IsPropertyKey(argument) {
539          switch (Type(argument)) {
540            case 3:
541              return true;
542            case 4:
543              return true;
544            default:
545              return false;
546          }
547        }
548        function SameValueZero(x, y) {
549          return x === y || x !== x && y !== y;
550        }
551        function GetMethod(V, P) {
552          var func = V[P];
553          if (func === void 0 || func === null) return void 0;
554          if (!IsCallable(func)) throw new TypeError();
555          return func;
556        }
557        function GetIterator(obj) {
558          var method = GetMethod(obj, iteratorSymbol);
559          if (!IsCallable(method)) throw new TypeError();
560          var iterator = method.call(obj);
561          if (!IsObject(iterator)) throw new TypeError();
562          return iterator;
563        }
564        function IteratorValue(iterResult) {
565          return iterResult.value;
566        }
567        function IteratorStep(iterator) {
568          var result = iterator.next();
569          return result.done ? false : result;
570        }
571        function IteratorClose(iterator) {
572          var f = iterator["return"];
573          if (f) f.call(iterator);
574        }
575        function OrdinaryGetPrototypeOf(O) {
576          var proto = Object.getPrototypeOf(O);
577          if (typeof O !== "function" || O === functionPrototype) return proto;
578          if (proto !== functionPrototype) return proto;
579          var prototype = O.prototype;
580          var prototypeProto = prototype && Object.getPrototypeOf(prototype);
581          if (prototypeProto == null || prototypeProto === Object.prototype) return proto;
582          var constructor = prototypeProto.constructor;
583          if (typeof constructor !== "function") return proto;
584          if (constructor === O) return proto;
585          return constructor;
586        }
587        function CreateMetadataRegistry() {
588          var fallback;
589          if (!IsUndefined(registrySymbol) && typeof root.Reflect !== "undefined" && !(registrySymbol in root.Reflect) && typeof root.Reflect.defineMetadata === "function") {
590            fallback = CreateFallbackProvider(root.Reflect);
591          }
592          var first;
593          var second;
594          var rest;
595          var targetProviderMap = new _WeakMap();
596          var registry = {
597            registerProvider,
598            getProvider,
599            setProvider
600          };
601          return registry;
602          function registerProvider(provider) {
603            if (!Object.isExtensible(registry)) {
604              throw new Error("Cannot add provider to a frozen registry.");
605            }
606            switch (true) {
607              case fallback === provider:
608                break;
609              case IsUndefined(first):
610                first = provider;
611                break;
612              case first === provider:
613                break;
614              case IsUndefined(second):
615                second = provider;
616                break;
617              case second === provider:
618                break;
619              default:
620                if (rest === void 0) rest = new _Set();
621                rest.add(provider);
622                break;
623            }
624          }
625          function getProviderNoCache(O, P) {
626            if (!IsUndefined(first)) {
627              if (first.isProviderFor(O, P)) return first;
628              if (!IsUndefined(second)) {
629                if (second.isProviderFor(O, P)) return first;
630                if (!IsUndefined(rest)) {
631                  var iterator = GetIterator(rest);
632                  while (true) {
633                    var next = IteratorStep(iterator);
634                    if (!next) {
635                      return void 0;
636                    }
637                    var provider = IteratorValue(next);
638                    if (provider.isProviderFor(O, P)) {
639                      IteratorClose(iterator);
640                      return provider;
641                    }
642                  }
643                }
644              }
645            }
646            if (!IsUndefined(fallback) && fallback.isProviderFor(O, P)) {
647              return fallback;
648            }
649            return void 0;
650          }
651          function getProvider(O, P) {
652            var providerMap = targetProviderMap.get(O);
653            var provider;
654            if (!IsUndefined(providerMap)) {
655              provider = providerMap.get(P);
656            }
657            if (!IsUndefined(provider)) {
658              return provider;
659            }
660            provider = getProviderNoCache(O, P);
661            if (!IsUndefined(provider)) {
662              if (IsUndefined(providerMap)) {
663                providerMap = new _Map();
664                targetProviderMap.set(O, providerMap);
665              }
666              providerMap.set(P, provider);
667            }
668            return provider;
669          }
670          function hasProvider(provider) {
671            if (IsUndefined(provider)) throw new TypeError();
672            return first === provider || second === provider || !IsUndefined(rest) && rest.has(provider);
673          }
674          function setProvider(O, P, provider) {
675            if (!hasProvider(provider)) {
676              throw new Error("Metadata provider not registered.");
677            }
678            var existingProvider = getProvider(O, P);
679            if (existingProvider !== provider) {
680              if (!IsUndefined(existingProvider)) {
681                return false;
682              }
683              var providerMap = targetProviderMap.get(O);
684              if (IsUndefined(providerMap)) {
685                providerMap = new _Map();
686                targetProviderMap.set(O, providerMap);
687              }
688              providerMap.set(P, provider);
689            }
690            return true;
691          }
692        }
693        function GetOrCreateMetadataRegistry() {
694          var metadataRegistry2;
695          if (!IsUndefined(registrySymbol) && IsObject(root.Reflect) && Object.isExtensible(root.Reflect)) {
696            metadataRegistry2 = root.Reflect[registrySymbol];
697          }
698          if (IsUndefined(metadataRegistry2)) {
699            metadataRegistry2 = CreateMetadataRegistry();
700          }
701          if (!IsUndefined(registrySymbol) && IsObject(root.Reflect) && Object.isExtensible(root.Reflect)) {
702            Object.defineProperty(root.Reflect, registrySymbol, {
703              enumerable: false,
704              configurable: false,
705              writable: false,
706              value: metadataRegistry2
707            });
708          }
709          return metadataRegistry2;
710        }
711        function CreateMetadataProvider(registry) {
712          var metadata2 = new _WeakMap();
713          var provider = {
714            isProviderFor: function(O, P) {
715              var targetMetadata = metadata2.get(O);
716              if (IsUndefined(targetMetadata)) return false;
717              return targetMetadata.has(P);
718            },
719            OrdinaryDefineOwnMetadata: OrdinaryDefineOwnMetadata2,
720            OrdinaryHasOwnMetadata: OrdinaryHasOwnMetadata2,
721            OrdinaryGetOwnMetadata: OrdinaryGetOwnMetadata2,
722            OrdinaryOwnMetadataKeys: OrdinaryOwnMetadataKeys2,
723            OrdinaryDeleteMetadata
724          };
725          metadataRegistry.registerProvider(provider);
726          return provider;
727          function GetOrCreateMetadataMap(O, P, Create) {
728            var targetMetadata = metadata2.get(O);
729            var createdTargetMetadata = false;
730            if (IsUndefined(targetMetadata)) {
731              if (!Create) return void 0;
732              targetMetadata = new _Map();
733              metadata2.set(O, targetMetadata);
734              createdTargetMetadata = true;
735            }
736            var metadataMap = targetMetadata.get(P);
737            if (IsUndefined(metadataMap)) {
738              if (!Create) return void 0;
739              metadataMap = new _Map();
740              targetMetadata.set(P, metadataMap);
741              if (!registry.setProvider(O, P, provider)) {
742                targetMetadata.delete(P);
743                if (createdTargetMetadata) {
744                  metadata2.delete(O);
745                }
746                throw new Error("Wrong provider for target.");
747              }
748            }
749            return metadataMap;
750          }
751          function OrdinaryHasOwnMetadata2(MetadataKey, O, P) {
752            var metadataMap = GetOrCreateMetadataMap(
753              O,
754              P,
755              /*Create*/
756              false
757            );
758            if (IsUndefined(metadataMap)) return false;
759            return ToBoolean(metadataMap.has(MetadataKey));
760          }
761          function OrdinaryGetOwnMetadata2(MetadataKey, O, P) {
762            var metadataMap = GetOrCreateMetadataMap(
763              O,
764              P,
765              /*Create*/
766              false
767            );
768            if (IsUndefined(metadataMap)) return void 0;
769            return metadataMap.get(MetadataKey);
770          }
771          function OrdinaryDefineOwnMetadata2(MetadataKey, MetadataValue, O, P) {
772            var metadataMap = GetOrCreateMetadataMap(
773              O,
774              P,
775              /*Create*/
776              true
777            );
778            metadataMap.set(MetadataKey, MetadataValue);
779          }
780          function OrdinaryOwnMetadataKeys2(O, P) {
781            var keys = [];
782            var metadataMap = GetOrCreateMetadataMap(
783              O,
784              P,
785              /*Create*/
786              false
787            );
788            if (IsUndefined(metadataMap)) return keys;
789            var keysObj = metadataMap.keys();
790            var iterator = GetIterator(keysObj);
791            var k = 0;
792            while (true) {
793              var next = IteratorStep(iterator);
794              if (!next) {
795                keys.length = k;
796                return keys;
797              }
798              var nextValue = IteratorValue(next);
799              try {
800                keys[k] = nextValue;
801              } catch (e) {
802                try {
803                  IteratorClose(iterator);
804                } finally {
805                  throw e;
806                }
807              }
808              k++;
809            }
810          }
811          function OrdinaryDeleteMetadata(MetadataKey, O, P) {
812            var metadataMap = GetOrCreateMetadataMap(
813              O,
814              P,
815              /*Create*/
816              false
817            );
818            if (IsUndefined(metadataMap)) return false;
819            if (!metadataMap.delete(MetadataKey)) return false;
820            if (metadataMap.size === 0) {
821              var targetMetadata = metadata2.get(O);
822              if (!IsUndefined(targetMetadata)) {
823                targetMetadata.delete(P);
824                if (targetMetadata.size === 0) {
825                  metadata2.delete(targetMetadata);
826                }
827              }
828            }
829            return true;
830          }
831        }
832        function CreateFallbackProvider(reflect) {
833          var defineMetadata2 = reflect.defineMetadata, hasOwnMetadata2 = reflect.hasOwnMetadata, getOwnMetadata2 = reflect.getOwnMetadata, getOwnMetadataKeys2 = reflect.getOwnMetadataKeys, deleteMetadata2 = reflect.deleteMetadata;
834          var metadataOwner = new _WeakMap();
835          var provider = {
836            isProviderFor: function(O, P) {
837              var metadataPropertySet = metadataOwner.get(O);
838              if (!IsUndefined(metadataPropertySet) && metadataPropertySet.has(P)) {
839                return true;
840              }
841              if (getOwnMetadataKeys2(O, P).length) {
842                if (IsUndefined(metadataPropertySet)) {
843                  metadataPropertySet = new _Set();
844                  metadataOwner.set(O, metadataPropertySet);
845                }
846                metadataPropertySet.add(P);
847                return true;
848              }
849              return false;
850            },
851            OrdinaryDefineOwnMetadata: defineMetadata2,
852            OrdinaryHasOwnMetadata: hasOwnMetadata2,
853            OrdinaryGetOwnMetadata: getOwnMetadata2,
854            OrdinaryOwnMetadataKeys: getOwnMetadataKeys2,
855            OrdinaryDeleteMetadata: deleteMetadata2
856          };
857          return provider;
858        }
859        function GetMetadataProvider(O, P, Create) {
860          var registeredProvider = metadataRegistry.getProvider(O, P);
861          if (!IsUndefined(registeredProvider)) {
862            return registeredProvider;
863          }
864          if (Create) {
865            if (metadataRegistry.setProvider(O, P, metadataProvider)) {
866              return metadataProvider;
867            }
868            throw new Error("Illegal state.");
869          }
870          return void 0;
871        }
872        function CreateMapPolyfill() {
873          var cacheSentinel = {};
874          var arraySentinel = [];
875          var MapIterator = (
876            /** @class */
877            function() {
878              function MapIterator2(keys, values, selector) {
879                this._index = 0;
880                this._keys = keys;
881                this._values = values;
882                this._selector = selector;
883              }
884              MapIterator2.prototype["@@iterator"] = function() {
885                return this;
886              };
887              MapIterator2.prototype[iteratorSymbol] = function() {
888                return this;
889              };
890              MapIterator2.prototype.next = function() {
891                var index = this._index;
892                if (index >= 0 && index < this._keys.length) {
893                  var result = this._selector(this._keys[index], this._values[index]);
894                  if (index + 1 >= this._keys.length) {
895                    this._index = -1;
896                    this._keys = arraySentinel;
897                    this._values = arraySentinel;
898                  } else {
899                    this._index++;
900                  }
901                  return {
902                    value: result,
903                    done: false
904                  };
905                }
906                return {
907                  value: void 0,
908                  done: true
909                };
910              };
911              MapIterator2.prototype.throw = function(error) {
912                if (this._index >= 0) {
913                  this._index = -1;
914                  this._keys = arraySentinel;
915                  this._values = arraySentinel;
916                }
917                throw error;
918              };
919              MapIterator2.prototype.return = function(value) {
920                if (this._index >= 0) {
921                  this._index = -1;
922                  this._keys = arraySentinel;
923                  this._values = arraySentinel;
924                }
925                return {
926                  value,
927                  done: true
928                };
929              };
930              return MapIterator2;
931            }()
932          );
933          var Map2 = (
934            /** @class */
935            function() {
936              function Map3() {
937                this._keys = [];
938                this._values = [];
939                this._cacheKey = cacheSentinel;
940                this._cacheIndex = -2;
941              }
942              Object.defineProperty(Map3.prototype, "size", {
943                get: function() {
944                  return this._keys.length;
945                },
946                enumerable: true,
947                configurable: true
948              });
949              Map3.prototype.has = function(key) {
950                return this._find(
951                  key,
952                  /*insert*/
953                  false
954                ) >= 0;
955              };
956              Map3.prototype.get = function(key) {
957                var index = this._find(
958                  key,
959                  /*insert*/
960                  false
961                );
962                return index >= 0 ? this._values[index] : void 0;
963              };
964              Map3.prototype.set = function(key, value) {
965                var index = this._find(
966                  key,
967                  /*insert*/
968                  true
969                );
970                this._values[index] = value;
971                return this;
972              };
973              Map3.prototype.delete = function(key) {
974                var index = this._find(
975                  key,
976                  /*insert*/
977                  false
978                );
979                if (index >= 0) {
980                  var size = this._keys.length;
981                  for (var i = index + 1; i < size; i++) {
982                    this._keys[i - 1] = this._keys[i];
983                    this._values[i - 1] = this._values[i];
984                  }
985                  this._keys.length--;
986                  this._values.length--;
987                  if (SameValueZero(key, this._cacheKey)) {
988                    this._cacheKey = cacheSentinel;
989                    this._cacheIndex = -2;
990                  }
991                  return true;
992                }
993                return false;
994              };
995              Map3.prototype.clear = function() {
996                this._keys.length = 0;
997                this._values.length = 0;
998                this._cacheKey = cacheSentinel;
999                this._cacheIndex = -2;
1000              };
1001              Map3.prototype.keys = function() {
1002                return new MapIterator(this._keys, this._values, getKey);
1003              };
1004              Map3.prototype.values = function() {
1005                return new MapIterator(this._keys, this._values, getValue2);
1006              };
1007              Map3.prototype.entries = function() {
1008                return new MapIterator(this._keys, this._values, getEntry);
1009              };
1010              Map3.prototype["@@iterator"] = function() {
1011                return this.entries();
1012              };
1013              Map3.prototype[iteratorSymbol] = function() {
1014                return this.entries();
1015              };
1016              Map3.prototype._find = function(key, insert) {
1017                if (!SameValueZero(this._cacheKey, key)) {
1018                  this._cacheIndex = -1;
1019                  for (var i = 0; i < this._keys.length; i++) {
1020                    if (SameValueZero(this._keys[i], key)) {
1021                      this._cacheIndex = i;
1022                      break;
1023                    }
1024                  }
1025                }
1026                if (this._cacheIndex < 0 && insert) {
1027                  this._cacheIndex = this._keys.length;
1028                  this._keys.push(key);
1029                  this._values.push(void 0);
1030                }
1031                return this._cacheIndex;
1032              };
1033              return Map3;
1034            }()
1035          );
1036          return Map2;
1037          function getKey(key, _2) {
1038            return key;
1039          }
1040          function getValue2(_2, value) {
1041            return value;
1042          }
1043          function getEntry(key, value) {
1044            return [key, value];
1045          }
1046        }
1047        function CreateSetPolyfill() {
1048          var Set2 = (
1049            /** @class */
1050            function() {
1051              function Set3() {
1052                this._map = new _Map();
1053              }
1054              Object.defineProperty(Set3.prototype, "size", {
1055                get: function() {
1056                  return this._map.size;
1057                },
1058                enumerable: true,
1059                configurable: true
1060              });
1061              Set3.prototype.has = function(value) {
1062                return this._map.has(value);
1063              };
1064              Set3.prototype.add = function(value) {
1065                return this._map.set(value, value), this;
1066              };
1067              Set3.prototype.delete = function(value) {
1068                return this._map.delete(value);
1069              };
1070              Set3.prototype.clear = function() {
1071                this._map.clear();
1072              };
1073              Set3.prototype.keys = function() {
1074                return this._map.keys();
1075              };
1076              Set3.prototype.values = function() {
1077                return this._map.keys();
1078              };
1079              Set3.prototype.entries = function() {
1080                return this._map.entries();
1081              };
1082              Set3.prototype["@@iterator"] = function() {
1083                return this.keys();
1084              };
1085              Set3.prototype[iteratorSymbol] = function() {
1086                return this.keys();
1087              };
1088              return Set3;
1089            }()
1090          );
1091          return Set2;
1092        }
1093        function CreateWeakMapPolyfill() {
1094          var UUID_SIZE = 16;
1095          var keys = HashMap.create();
1096          var rootKey = CreateUniqueKey();
1097          return (
1098            /** @class */
1099            function() {
1100              function WeakMap2() {
1101                this._key = CreateUniqueKey();
1102              }
1103              WeakMap2.prototype.has = function(target) {
1104                var table = GetOrCreateWeakMapTable(
1105                  target,
1106                  /*create*/
1107                  false
1108                );
1109                return table !== void 0 ? HashMap.has(table, this._key) : false;
1110              };
1111              WeakMap2.prototype.get = function(target) {
1112                var table = GetOrCreateWeakMapTable(
1113                  target,
1114                  /*create*/
1115                  false
1116                );
1117                return table !== void 0 ? HashMap.get(table, this._key) : void 0;
1118              };
1119              WeakMap2.prototype.set = function(target, value) {
1120                var table = GetOrCreateWeakMapTable(
1121                  target,
1122                  /*create*/
1123                  true
1124                );
1125                table[this._key] = value;
1126                return this;
1127              };
1128              WeakMap2.prototype.delete = function(target) {
1129                var table = GetOrCreateWeakMapTable(
1130                  target,
1131                  /*create*/
1132                  false
1133                );
1134                return table !== void 0 ? delete table[this._key] : false;
1135              };
1136              WeakMap2.prototype.clear = function() {
1137                this._key = CreateUniqueKey();
1138              };
1139              return WeakMap2;
1140            }()
1141          );
1142          function CreateUniqueKey() {
1143            var key;
1144            do
1145              key = "@@WeakMap@@" + CreateUUID();
1146            while (HashMap.has(keys, key));
1147            keys[key] = true;
1148            return key;
1149          }
1150          function GetOrCreateWeakMapTable(target, create) {
1151            if (!hasOwn.call(target, rootKey)) {
1152              if (!create) return void 0;
1153              Object.defineProperty(target, rootKey, {
1154                value: HashMap.create()
1155              });
1156            }
1157            return target[rootKey];
1158          }
1159          function FillRandomBytes(buffer, size) {
1160            for (var i = 0; i < size; ++i) buffer[i] = Math.random() * 255 | 0;
1161            return buffer;
1162          }
1163          function GenRandomBytes(size) {
1164            if (typeof Uint8Array === "function") {
1165              var array = new Uint8Array(size);
1166              if (typeof crypto !== "undefined") {
1167                crypto.getRandomValues(array);
1168              } else if (typeof msCrypto !== "undefined") {
1169                msCrypto.getRandomValues(array);
1170              } else {
1171                FillRandomBytes(array, size);
1172              }
1173              return array;
1174            }
1175            return FillRandomBytes(new Array(size), size);
1176          }
1177          function CreateUUID() {
1178            var data = GenRandomBytes(UUID_SIZE);
1179            data[6] = data[6] & 79 | 64;
1180            data[8] = data[8] & 191 | 128;
1181            var result = "";
1182            for (var offset = 0; offset < UUID_SIZE; ++offset) {
1183              var byte = data[offset];
1184              if (offset === 4 || offset === 6 || offset === 8) result += "-";
1185              if (byte < 16) result += "0";
1186              result += byte.toString(16).toLowerCase();
1187            }
1188            return result;
1189          }
1190        }
1191        function MakeDictionary(obj) {
1192          obj.__ = void 0;
1193          delete obj.__;
1194          return obj;
1195        }
1196      });
1197    })(Reflect2 || (Reflect2 = {}));
1198  }
1199});
1200
vendor: 223,620 bytes, lines 1201-6601
1201// node_modules/lodash/lodash.js
1202var require_lodash = __commonJS({
1203  "node_modules/lodash/lodash.js"(exports, module) {
1204    "use strict";
1205    (function() {
1206      var undefined2;
1207      var VERSION2 = "4.17.21";
1208      var LARGE_ARRAY_SIZE = 200;
1209      var CORE_ERROR_TEXT = "Unsupported core-js use. Try https://npms.io/search?q=ponyfill.", FUNC_ERROR_TEXT = "Expected a function", INVALID_TEMPL_VAR_ERROR_TEXT = "Invalid `variable` option passed into `_.template`";
1210      var HASH_UNDEFINED = "__lodash_hash_undefined__";
1211      var MAX_MEMOIZE_SIZE = 500;
1212      var PLACEHOLDER = "__lodash_placeholder__";
1213      var CLONE_DEEP_FLAG = 1, CLONE_FLAT_FLAG = 2, CLONE_SYMBOLS_FLAG = 4;
1214      var COMPARE_PARTIAL_FLAG = 1, COMPARE_UNORDERED_FLAG = 2;
1215      var WRAP_BIND_FLAG = 1, WRAP_BIND_KEY_FLAG = 2, WRAP_CURRY_BOUND_FLAG = 4, WRAP_CURRY_FLAG = 8, WRAP_CURRY_RIGHT_FLAG = 16, WRAP_PARTIAL_FLAG = 32, WRAP_PARTIAL_RIGHT_FLAG = 64, WRAP_ARY_FLAG = 128, WRAP_REARG_FLAG = 256, WRAP_FLIP_FLAG = 512;
1216      var DEFAULT_TRUNC_LENGTH = 30, DEFAULT_TRUNC_OMISSION = "...";
1217      var HOT_COUNT = 800, HOT_SPAN = 16;
1218      var LAZY_FILTER_FLAG = 1, LAZY_MAP_FLAG = 2, LAZY_WHILE_FLAG = 3;
1219      var INFINITY = 1 / 0, MAX_SAFE_INTEGER = 9007199254740991, MAX_INTEGER = 17976931348623157e292, NAN = 0 / 0;
1220      var MAX_ARRAY_LENGTH = 4294967295, MAX_ARRAY_INDEX = MAX_ARRAY_LENGTH - 1, HALF_MAX_ARRAY_LENGTH = MAX_ARRAY_LENGTH >>> 1;
1221      var wrapFlags = [["ary", WRAP_ARY_FLAG], ["bind", WRAP_BIND_FLAG], ["bindKey", WRAP_BIND_KEY_FLAG], ["curry", WRAP_CURRY_FLAG], ["curryRight", WRAP_CURRY_RIGHT_FLAG], ["flip", WRAP_FLIP_FLAG], ["partial", WRAP_PARTIAL_FLAG], ["partialRight", WRAP_PARTIAL_RIGHT_FLAG], ["rearg", WRAP_REARG_FLAG]];
1222      var argsTag = "[object Arguments]", arrayTag = "[object Array]", asyncTag = "[object AsyncFunction]", boolTag = "[object Boolean]", dateTag = "[object Date]", domExcTag = "[object DOMException]", errorTag = "[object Error]", funcTag = "[object Function]", genTag = "[object GeneratorFunction]", mapTag = "[object Map]", numberTag = "[object Number]", nullTag = "[object Null]", objectTag = "[object Object]", promiseTag = "[object Promise]", proxyTag = "[object Proxy]", regexpTag = "[object RegExp]", setTag = "[object Set]", stringTag = "[object String]", symbolTag = "[object Symbol]", undefinedTag = "[object Undefined]", weakMapTag = "[object WeakMap]", weakSetTag = "[object WeakSet]";
1223      var arrayBufferTag = "[object ArrayBuffer]", dataViewTag = "[object DataView]", float32Tag = "[object Float32Array]", float64Tag = "[object Float64Array]", int8Tag = "[object Int8Array]", int16Tag = "[object Int16Array]", int32Tag = "[object Int32Array]", uint8Tag = "[object Uint8Array]", uint8ClampedTag = "[object Uint8ClampedArray]", uint16Tag = "[object Uint16Array]", uint32Tag = "[object Uint32Array]";
1224      var reEmptyStringLeading = /\b__p \+= '';/g, reEmptyStringMiddle = /\b(__p \+=) '' \+/g, reEmptyStringTrailing = /(__e\(.*?\)|\b__t\)) \+\n'';/g;
1225      var reEscapedHtml = /&(?:amp|lt|gt|quot|#39);/g, reUnescapedHtml = /[&<>"']/g, reHasEscapedHtml = RegExp(reEscapedHtml.source), reHasUnescapedHtml = RegExp(reUnescapedHtml.source);
1226      var reEscape = /<%-([\s\S]+?)%>/g, reEvaluate = /<%([\s\S]+?)%>/g, reInterpolate = /<%=([\s\S]+?)%>/g;
1227      var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, reIsPlainProp = /^\w*$/, rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g;
1228      var reRegExpChar = /[\\^$.*+?()[\]{}|]/g, reHasRegExpChar = RegExp(reRegExpChar.source);
1229      var reTrimStart = /^\s+/;
1230      var reWhitespace = /\s/;
1231      var reWrapComment = /\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/, reWrapDetails = /\{\n\/\* \[wrapped with (.+)\] \*/, reSplitDetails = /,? & /;
1232      var reAsciiWord = /[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;
1233      var reForbiddenIdentifierChars = /[()=,{}\[\]\/\s]/;
1234      var reEscapeChar = /\\(\\)?/g;
1235      var reEsTemplate = /\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g;
1236      var reFlags = /\w*$/;
1237      var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;
1238      var reIsBinary = /^0b[01]+$/i;
1239      var reIsHostCtor = /^\[object .+?Constructor\]$/;
1240      var reIsOctal = /^0o[0-7]+$/i;
1241      var reIsUint = /^(?:0|[1-9]\d*)$/;
1242      var reLatin = /[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g;
1243      var reNoMatch = /($^)/;
1244      var reUnescapedString = /['\n\r\u2028\u2029\\]/g;
1245      var rsAstralRange = "\\ud800-\\udfff", rsComboMarksRange = "\\u0300-\\u036f", reComboHalfMarksRange = "\\ufe20-\\ufe2f", rsComboSymbolsRange = "\\u20d0-\\u20ff", rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange, rsDingbatRange = "\\u2700-\\u27bf", rsLowerRange = "a-z\\xdf-\\xf6\\xf8-\\xff", rsMathOpRange = "\\xac\\xb1\\xd7\\xf7", rsNonCharRange = "\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf", rsPunctuationRange = "\\u2000-\\u206f", rsSpaceRange = " \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000", rsUpperRange = "A-Z\\xc0-\\xd6\\xd8-\\xde", rsVarRange = "\\ufe0e\\ufe0f", rsBreakRange = rsMathOpRange + rsNonCharRange + rsPunctuationRange + rsSpaceRange;
1246      var rsApos = "['\u2019]", rsAstral = "[" + rsAstralRange + "]", rsBreak = "[" + rsBreakRange + "]", rsCombo = "[" + rsComboRange + "]", rsDigits = "\\d+", rsDingbat = "[" + rsDingbatRange + "]", rsLower = "[" + rsLowerRange + "]", rsMisc = "[^" + rsAstralRange + rsBreakRange + rsDigits + rsDingbatRange + rsLowerRange + rsUpperRange + "]", rsFitz = "\\ud83c[\\udffb-\\udfff]", rsModifier = "(?:" + rsCombo + "|" + rsFitz + ")", rsNonAstral = "[^" + rsAstralRange + "]", rsRegional = "(?:\\ud83c[\\udde6-\\uddff]){2}", rsSurrPair = "[\\ud800-\\udbff][\\udc00-\\udfff]", rsUpper = "[" + rsUpperRange + "]", rsZWJ = "\\u200d";
1247      var rsMiscLower = "(?:" + rsLower + "|" + rsMisc + ")", rsMiscUpper = "(?:" + rsUpper + "|" + rsMisc + ")", rsOptContrLower = "(?:" + rsApos + "(?:d|ll|m|re|s|t|ve))?", rsOptContrUpper = "(?:" + rsApos + "(?:D|LL|M|RE|S|T|VE))?", reOptMod = rsModifier + "?", rsOptVar = "[" + rsVarRange + "]?", rsOptJoin = "(?:" + rsZWJ + "(?:" + [rsNonAstral, rsRegional, rsSurrPair].join("|") + ")" + rsOptVar + reOptMod + ")*", rsOrdLower = "\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])", rsOrdUpper = "\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])", rsSeq = rsOptVar + reOptMod + rsOptJoin, rsEmoji = "(?:" + [rsDingbat, rsRegional, rsSurrPair].join("|") + ")" + rsSeq, rsSymbol = "(?:" + [rsNonAstral + rsCombo + "?", rsCombo, rsRegional, rsSurrPair, rsAstral].join("|") + ")";
1248      var reApos = RegExp(rsApos, "g");
1249      var reComboMark = RegExp(rsCombo, "g");
1250      var reUnicode = RegExp(rsFitz + "(?=" + rsFitz + ")|" + rsSymbol + rsSeq, "g");
1251      var reUnicodeWord = RegExp([rsUpper + "?" + rsLower + "+" + rsOptContrLower + "(?=" + [rsBreak, rsUpper, "$"].join("|") + ")", rsMiscUpper + "+" + rsOptContrUpper + "(?=" + [rsBreak, rsUpper + rsMiscLower, "$"].join("|") + ")", rsUpper + "?" + rsMiscLower + "+" + rsOptContrLower, rsUpper + "+" + rsOptContrUpper, rsOrdUpper, rsOrdLower, rsDigits, rsEmoji].join("|"), "g");
1252      var reHasUnicode = RegExp("[" + rsZWJ + rsAstralRange + rsComboRange + rsVarRange + "]");
1253      var reHasUnicodeWord = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;
1254      var contextProps = ["Array", "Buffer", "DataView", "Date", "Error", "Float32Array", "Float64Array", "Function", "Int8Array", "Int16Array", "Int32Array", "Map", "Math", "Object", "Promise", "RegExp", "Set", "String", "Symbol", "TypeError", "Uint8Array", "Uint8ClampedArray", "Uint16Array", "Uint32Array", "WeakMap", "_", "clearTimeout", "isFinite", "parseInt", "setTimeout"];
1255      var templateCounter = -1;
1256      var typedArrayTags = {};
1257      typedArrayTags[float32Tag] = typedArrayTags[float64Tag] = typedArrayTags[int8Tag] = typedArrayTags[int16Tag] = typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] = typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] = typedArrayTags[uint32Tag] = true;
1258      typedArrayTags[argsTag] = typedArrayTags[arrayTag] = typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] = typedArrayTags[dataViewTag] = typedArrayTags[dateTag] = typedArrayTags[errorTag] = typedArrayTags[funcTag] = typedArrayTags[mapTag] = typedArrayTags[numberTag] = typedArrayTags[objectTag] = typedArrayTags[regexpTag] = typedArrayTags[setTag] = typedArrayTags[stringTag] = typedArrayTags[weakMapTag] = false;
1259      var cloneableTags = {};
1260      cloneableTags[argsTag] = cloneableTags[arrayTag] = cloneableTags[arrayBufferTag] = cloneableTags[dataViewTag] = cloneableTags[boolTag] = cloneableTags[dateTag] = cloneableTags[float32Tag] = cloneableTags[float64Tag] = cloneableTags[int8Tag] = cloneableTags[int16Tag] = cloneableTags[int32Tag] = cloneableTags[mapTag] = cloneableTags[numberTag] = cloneableTags[objectTag] = cloneableTags[regexpTag] = cloneableTags[setTag] = cloneableTags[stringTag] = cloneableTags[symbolTag] = cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] = cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true;
1261      cloneableTags[errorTag] = cloneableTags[funcTag] = cloneableTags[weakMapTag] = false;
1262      var deburredLetters = {
1263        // Latin-1 Supplement block.
1264        "\xC0": "A",
1265        "\xC1": "A",
1266        "\xC2": "A",
1267        "\xC3": "A",
1268        "\xC4": "A",
1269        "\xC5": "A",
1270        "\xE0": "a",
1271        "\xE1": "a",
1272        "\xE2": "a",
1273        "\xE3": "a",
1274        "\xE4": "a",
1275        "\xE5": "a",
1276        "\xC7": "C",
1277        "\xE7": "c",
1278        "\xD0": "D",
1279        "\xF0": "d",
1280        "\xC8": "E",
1281        "\xC9": "E",
1282        "\xCA": "E",
1283        "\xCB": "E",
1284        "\xE8": "e",
1285        "\xE9": "e",
1286        "\xEA": "e",
1287        "\xEB": "e",
1288        "\xCC": "I",
1289        "\xCD": "I",
1290        "\xCE": "I",
1291        "\xCF": "I",
1292        "\xEC": "i",
1293        "\xED": "i",
1294        "\xEE": "i",
1295        "\xEF": "i",
1296        "\xD1": "N",
1297        "\xF1": "n",
1298        "\xD2": "O",
1299        "\xD3": "O",
1300        "\xD4": "O",
1301        "\xD5": "O",
1302        "\xD6": "O",
1303        "\xD8": "O",
1304        "\xF2": "o",
1305        "\xF3": "o",
1306        "\xF4": "o",
1307        "\xF5": "o",
1308        "\xF6": "o",
1309        "\xF8": "o",
1310        "\xD9": "U",
1311        "\xDA": "U",
1312        "\xDB": "U",
1313        "\xDC": "U",
1314        "\xF9": "u",
1315        "\xFA": "u",
1316        "\xFB": "u",
1317        "\xFC": "u",
1318        "\xDD": "Y",
1319        "\xFD": "y",
1320        "\xFF": "y",
1321        "\xC6": "Ae",
1322        "\xE6": "ae",
1323        "\xDE": "Th",
1324        "\xFE": "th",
1325        "\xDF": "ss",
1326        // Latin Extended-A block.
1327        "\u0100": "A",
1328        "\u0102": "A",
1329        "\u0104": "A",
1330        "\u0101": "a",
1331        "\u0103": "a",
1332        "\u0105": "a",
1333        "\u0106": "C",
1334        "\u0108": "C",
1335        "\u010A": "C",
1336        "\u010C": "C",
1337        "\u0107": "c",
1338        "\u0109": "c",
1339        "\u010B": "c",
1340        "\u010D": "c",
1341        "\u010E": "D",
1342        "\u0110": "D",
1343        "\u010F": "d",
1344        "\u0111": "d",
1345        "\u0112": "E",
1346        "\u0114": "E",
1347        "\u0116": "E",
1348        "\u0118": "E",
1349        "\u011A": "E",
1350        "\u0113": "e",
1351        "\u0115": "e",
1352        "\u0117": "e",
1353        "\u0119": "e",
1354        "\u011B": "e",
1355        "\u011C": "G",
1356        "\u011E": "G",
1357        "\u0120": "G",
1358        "\u0122": "G",
1359        "\u011D": "g",
1360        "\u011F": "g",
1361        "\u0121": "g",
1362        "\u0123": "g",
1363        "\u0124": "H",
1364        "\u0126": "H",
1365        "\u0125": "h",
1366        "\u0127": "h",
1367        "\u0128": "I",
1368        "\u012A": "I",
1369        "\u012C": "I",
1370        "\u012E": "I",
1371        "\u0130": "I",
1372        "\u0129": "i",
1373        "\u012B": "i",
1374        "\u012D": "i",
1375        "\u012F": "i",
1376        "\u0131": "i",
1377        "\u0134": "J",
1378        "\u0135": "j",
1379        "\u0136": "K",
1380        "\u0137": "k",
1381        "\u0138": "k",
1382        "\u0139": "L",
1383        "\u013B": "L",
1384        "\u013D": "L",
1385        "\u013F": "L",
1386        "\u0141": "L",
1387        "\u013A": "l",
1388        "\u013C": "l",
1389        "\u013E": "l",
1390        "\u0140": "l",
1391        "\u0142": "l",
1392        "\u0143": "N",
1393        "\u0145": "N",
1394        "\u0147": "N",
1395        "\u014A": "N",
1396        "\u0144": "n",
1397        "\u0146": "n",
1398        "\u0148": "n",
1399        "\u014B": "n",
1400        "\u014C": "O",
1401        "\u014E": "O",
1402        "\u0150": "O",
1403        "\u014D": "o",
1404        "\u014F": "o",
1405        "\u0151": "o",
1406        "\u0154": "R",
1407        "\u0156": "R",
1408        "\u0158": "R",
1409        "\u0155": "r",
1410        "\u0157": "r",
1411        "\u0159": "r",
1412        "\u015A": "S",
1413        "\u015C": "S",
1414        "\u015E": "S",
1415        "\u0160": "S",
1416        "\u015B": "s",
1417        "\u015D": "s",
1418        "\u015F": "s",
1419        "\u0161": "s",
1420        "\u0162": "T",
1421        "\u0164": "T",
1422        "\u0166": "T",
1423        "\u0163": "t",
1424        "\u0165": "t",
1425        "\u0167": "t",
1426        "\u0168": "U",
1427        "\u016A": "U",
1428        "\u016C": "U",
1429        "\u016E": "U",
1430        "\u0170": "U",
1431        "\u0172": "U",
1432        "\u0169": "u",
1433        "\u016B": "u",
1434        "\u016D": "u",
1435        "\u016F": "u",
1436        "\u0171": "u",
1437        "\u0173": "u",
1438        "\u0174": "W",
1439        "\u0175": "w",
1440        "\u0176": "Y",
1441        "\u0177": "y",
1442        "\u0178": "Y",
1443        "\u0179": "Z",
1444        "\u017B": "Z",
1445        "\u017D": "Z",
1446        "\u017A": "z",
1447        "\u017C": "z",
1448        "\u017E": "z",
1449        "\u0132": "IJ",
1450        "\u0133": "ij",
1451        "\u0152": "Oe",
1452        "\u0153": "oe",
1453        "\u0149": "'n",
1454        "\u017F": "s"
1455      };
1456      var htmlEscapes2 = {
1457        "&": "&amp;",
1458        "<": "&lt;",
1459        ">": "&gt;",
1460        '"': "&quot;",
1461        "'": "&#39;"
1462      };
1463      var htmlUnescapes = {
1464        "&amp;": "&",
1465        "&lt;": "<",
1466        "&gt;": ">",
1467        "&quot;": '"',
1468        "&#39;": "'"
1469      };
1470      var stringEscapes = {
1471        "\\": "\\",
1472        "'": "'",
1473        "\n": "n",
1474        "\r": "r",
1475        "\u2028": "u2028",
1476        "\u2029": "u2029"
1477      };
1478      var freeParseFloat = parseFloat, freeParseInt = parseInt;
1479      var freeGlobal = typeof global == "object" && global && global.Object === Object && global;
1480      var freeSelf = typeof self == "object" && self && self.Object === Object && self;
1481      var root = freeGlobal || freeSelf || Function("return this")();
1482      var freeExports = typeof exports == "object" && exports && !exports.nodeType && exports;
1483      var freeModule = freeExports && typeof module == "object" && module && !module.nodeType && module;
1484      var moduleExports = freeModule && freeModule.exports === freeExports;
1485      var freeProcess = moduleExports && freeGlobal.process;
1486      var nodeUtil = function() {
1487        try {
1488          var types = freeModule && freeModule.require && freeModule.require("util").types;
1489          if (types) {
1490            return types;
1491          }
1492          return freeProcess && freeProcess.binding && freeProcess.binding("util");
1493        } catch (e) {
1494        }
1495      }();
1496      var nodeIsArrayBuffer = nodeUtil && nodeUtil.isArrayBuffer, nodeIsDate = nodeUtil && nodeUtil.isDate, nodeIsMap = nodeUtil && nodeUtil.isMap, nodeIsRegExp = nodeUtil && nodeUtil.isRegExp, nodeIsSet = nodeUtil && nodeUtil.isSet, nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;
1497      function apply(func, thisArg, args) {
1498        switch (args.length) {
1499          case 0:
1500            return func.call(thisArg);
1501          case 1:
1502            return func.call(thisArg, args[0]);
1503          case 2:
1504            return func.call(thisArg, args[0], args[1]);
1505          case 3:
1506            return func.call(thisArg, args[0], args[1], args[2]);
1507        }
1508        return func.apply(thisArg, args);
1509      }
1510      function arrayAggregator(array, setter, iteratee, accumulator) {
1511        var index = -1, length = array == null ? 0 : array.length;
1512        while (++index < length) {
1513          var value = array[index];
1514          setter(accumulator, value, iteratee(value), array);
1515        }
1516        return accumulator;
1517      }
1518      function arrayEach(array, iteratee) {
1519        var index = -1, length = array == null ? 0 : array.length;
1520        while (++index < length) {
1521          if (iteratee(array[index], index, array) === false) {
1522            break;
1523          }
1524        }
1525        return array;
1526      }
1527      function arrayEachRight(array, iteratee) {
1528        var length = array == null ? 0 : array.length;
1529        while (length--) {
1530          if (iteratee(array[length], length, array) === false) {
1531            break;
1532          }
1533        }
1534        return array;
1535      }
1536      function arrayEvery(array, predicate) {
1537        var index = -1, length = array == null ? 0 : array.length;
1538        while (++index < length) {
1539          if (!predicate(array[index], index, array)) {
1540            return false;
1541          }
1542        }
1543        return true;
1544      }
1545      function arrayFilter(array, predicate) {
1546        var index = -1, length = array == null ? 0 : array.length, resIndex = 0, result = [];
1547        while (++index < length) {
1548          var value = array[index];
1549          if (predicate(value, index, array)) {
1550            result[resIndex++] = value;
1551          }
1552        }
1553        return result;
1554      }
1555      function arrayIncludes(array, value) {
1556        var length = array == null ? 0 : array.length;
1557        return !!length && baseIndexOf(array, value, 0) > -1;
1558      }
1559      function arrayIncludesWith(array, value, comparator) {
1560        var index = -1, length = array == null ? 0 : array.length;
1561        while (++index < length) {
1562          if (comparator(value, array[index])) {
1563            return true;
1564          }
1565        }
1566        return false;
1567      }
1568      function arrayMap(array, iteratee) {
1569        var index = -1, length = array == null ? 0 : array.length, result = Array(length);
1570        while (++index < length) {
1571          result[index] = iteratee(array[index], index, array);
1572        }
1573        return result;
1574      }
1575      function arrayPush(array, values) {
1576        var index = -1, length = values.length, offset = array.length;
1577        while (++index < length) {
1578          array[offset + index] = values[index];
1579        }
1580        return array;
1581      }
1582      function arrayReduce(array, iteratee, accumulator, initAccum) {
1583        var index = -1, length = array == null ? 0 : array.length;
1584        if (initAccum && length) {
1585          accumulator = array[++index];
1586        }
1587        while (++index < length) {
1588          accumulator = iteratee(accumulator, array[index], index, array);
1589        }
1590        return accumulator;
1591      }
1592      function arrayReduceRight(array, iteratee, accumulator, initAccum) {
1593        var length = array == null ? 0 : array.length;
1594        if (initAccum && length) {
1595          accumulator = array[--length];
1596        }
1597        while (length--) {
1598          accumulator = iteratee(accumulator, array[length], length, array);
1599        }
1600        return accumulator;
1601      }
1602      function arraySome(array, predicate) {
1603        var index = -1, length = array == null ? 0 : array.length;
1604        while (++index < length) {
1605          if (predicate(array[index], index, array)) {
1606            return true;
1607          }
1608        }
1609        return false;
1610      }
1611      var asciiSize = baseProperty("length");
1612      function asciiToArray(string) {
1613        return string.split("");
1614      }
1615      function asciiWords(string) {
1616        return string.match(reAsciiWord) || [];
1617      }
1618      function baseFindKey(collection, predicate, eachFunc) {
1619        var result;
1620        eachFunc(collection, function(value, key, collection2) {
1621          if (predicate(value, key, collection2)) {
1622            result = key;
1623            return false;
1624          }
1625        });
1626        return result;
1627      }
1628      function baseFindIndex(array, predicate, fromIndex, fromRight) {
1629        var length = array.length, index = fromIndex + (fromRight ? 1 : -1);
1630        while (fromRight ? index-- : ++index < length) {
1631          if (predicate(array[index], index, array)) {
1632            return index;
1633          }
1634        }
1635        return -1;
1636      }
1637      function baseIndexOf(array, value, fromIndex) {
1638        return value === value ? strictIndexOf(array, value, fromIndex) : baseFindIndex(array, baseIsNaN, fromIndex);
1639      }
1640      function baseIndexOfWith(array, value, fromIndex, comparator) {
1641        var index = fromIndex - 1, length = array.length;
1642        while (++index < length) {
1643          if (comparator(array[index], value)) {
1644            return index;
1645          }
1646        }
1647        return -1;
1648      }
1649      function baseIsNaN(value) {
1650        return value !== value;
1651      }
1652      function baseMean(array, iteratee) {
1653        var length = array == null ? 0 : array.length;
1654        return length ? baseSum(array, iteratee) / length : NAN;
1655      }
1656      function baseProperty(key) {
1657        return function(object) {
1658          return object == null ? undefined2 : object[key];
1659        };
1660      }
1661      function basePropertyOf(object) {
1662        return function(key) {
1663          return object == null ? undefined2 : object[key];
1664        };
1665      }
1666      function baseReduce(collection, iteratee, accumulator, initAccum, eachFunc) {
1667        eachFunc(collection, function(value, index, collection2) {
1668          accumulator = initAccum ? (initAccum = false, value) : iteratee(accumulator, value, index, collection2);
1669        });
1670        return accumulator;
1671      }
1672      function baseSortBy(array, comparer) {
1673        var length = array.length;
1674        array.sort(comparer);
1675        while (length--) {
1676          array[length] = array[length].value;
1677        }
1678        return array;
1679      }
1680      function baseSum(array, iteratee) {
1681        var result, index = -1, length = array.length;
1682        while (++index < length) {
1683          var current = iteratee(array[index]);
1684          if (current !== undefined2) {
1685            result = result === undefined2 ? current : result + current;
1686          }
1687        }
1688        return result;
1689      }
1690      function baseTimes(n, iteratee) {
1691        var index = -1, result = Array(n);
1692        while (++index < n) {
1693          result[index] = iteratee(index);
1694        }
1695        return result;
1696      }
1697      function baseToPairs(object, props) {
1698        return arrayMap(props, function(key) {
1699          return [key, object[key]];
1700        });
1701      }
1702      function baseTrim(string) {
1703        return string ? string.slice(0, trimmedEndIndex(string) + 1).replace(reTrimStart, "") : string;
1704      }
1705      function baseUnary(func) {
1706        return function(value) {
1707          return func(value);
1708        };
1709      }
1710      function baseValues(object, props) {
1711        return arrayMap(props, function(key) {
1712          return object[key];
1713        });
1714      }
1715      function cacheHas(cache, key) {
1716        return cache.has(key);
1717      }
1718      function charsStartIndex(strSymbols, chrSymbols) {
1719        var index = -1, length = strSymbols.length;
1720        while (++index < length && baseIndexOf(chrSymbols, strSymbols[index], 0) > -1) {
1721        }
1722        return index;
1723      }
1724      function charsEndIndex(strSymbols, chrSymbols) {
1725        var index = strSymbols.length;
1726        while (index-- && baseIndexOf(chrSymbols, strSymbols[index], 0) > -1) {
1727        }
1728        return index;
1729      }
1730      function countHolders(array, placeholder) {
1731        var length = array.length, result = 0;
1732        while (length--) {
1733          if (array[length] === placeholder) {
1734            ++result;
1735          }
1736        }
1737        return result;
1738      }
1739      var deburrLetter = basePropertyOf(deburredLetters);
1740      var escapeHtmlChar = basePropertyOf(htmlEscapes2);
1741      function escapeStringChar(chr) {
1742        return "\\" + stringEscapes[chr];
1743      }
1744      function getValue2(object, key) {
1745        return object == null ? undefined2 : object[key];
1746      }
1747      function hasUnicode(string) {
1748        return reHasUnicode.test(string);
1749      }
1750      function hasUnicodeWord(string) {
1751        return reHasUnicodeWord.test(string);
1752      }
1753      function iteratorToArray(iterator) {
1754        var data, result = [];
1755        while (!(data = iterator.next()).done) {
1756          result.push(data.value);
1757        }
1758        return result;
1759      }
1760      function mapToArray(map2) {
1761        var index = -1, result = Array(map2.size);
1762        map2.forEach(function(value, key) {
1763          result[++index] = [key, value];
1764        });
1765        return result;
1766      }
1767      function overArg(func, transform) {
1768        return function(arg) {
1769          return func(transform(arg));
1770        };
1771      }
1772      function replaceHolders(array, placeholder) {
1773        var index = -1, length = array.length, resIndex = 0, result = [];
1774        while (++index < length) {
1775          var value = array[index];
1776          if (value === placeholder || value === PLACEHOLDER) {
1777            array[index] = PLACEHOLDER;
1778            result[resIndex++] = index;
1779          }
1780        }
1781        return result;
1782      }
1783      function setToArray(set) {
1784        var index = -1, result = Array(set.size);
1785        set.forEach(function(value) {
1786          result[++index] = value;
1787        });
1788        return result;
1789      }
1790      function setToPairs(set) {
1791        var index = -1, result = Array(set.size);
1792        set.forEach(function(value) {
1793          result[++index] = [value, value];
1794        });
1795        return result;
1796      }
1797      function strictIndexOf(array, value, fromIndex) {
1798        var index = fromIndex - 1, length = array.length;
1799        while (++index < length) {
1800          if (array[index] === value) {
1801            return index;
1802          }
1803        }
1804        return -1;
1805      }
1806      function strictLastIndexOf(array, value, fromIndex) {
1807        var index = fromIndex + 1;
1808        while (index--) {
1809          if (array[index] === value) {
1810            return index;
1811          }
1812        }
1813        return index;
1814      }
1815      function stringSize(string) {
1816        return hasUnicode(string) ? unicodeSize(string) : asciiSize(string);
1817      }
1818      function stringToArray(string) {
1819        return hasUnicode(string) ? unicodeToArray(string) : asciiToArray(string);
1820      }
1821      function trimmedEndIndex(string) {
1822        var index = string.length;
1823        while (index-- && reWhitespace.test(string.charAt(index))) {
1824        }
1825        return index;
1826      }
1827      var unescapeHtmlChar = basePropertyOf(htmlUnescapes);
1828      function unicodeSize(string) {
1829        var result = reUnicode.lastIndex = 0;
1830        while (reUnicode.test(string)) {
1831          ++result;
1832        }
1833        return result;
1834      }
1835      function unicodeToArray(string) {
1836        return string.match(reUnicode) || [];
1837      }
1838      function unicodeWords(string) {
1839        return string.match(reUnicodeWord) || [];
1840      }
1841      var runInContext = function runInContext2(context) {
1842        context = context == null ? root : _2.defaults(root.Object(), context, _2.pick(root, contextProps));
1843        var Array2 = context.Array, Date2 = context.Date, Error2 = context.Error, Function2 = context.Function, Math2 = context.Math, Object2 = context.Object, RegExp2 = context.RegExp, String2 = context.String, TypeError2 = context.TypeError;
1844        var arrayProto = Array2.prototype, funcProto = Function2.prototype, objectProto = Object2.prototype;
1845        var coreJsData = context["__core-js_shared__"];
1846        var funcToString = funcProto.toString;
1847        var hasOwnProperty = objectProto.hasOwnProperty;
1848        var idCounter = 0;
1849        var maskSrcKey = function() {
1850          var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || "");
1851          return uid ? "Symbol(src)_1." + uid : "";
1852        }();
1853        var nativeObjectToString = objectProto.toString;
1854        var objectCtorString = funcToString.call(Object2);
1855        var oldDash = root._;
1856        var reIsNative = RegExp2("^" + funcToString.call(hasOwnProperty).replace(reRegExpChar, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$");
1857        var Buffer = moduleExports ? context.Buffer : undefined2, Symbol2 = context.Symbol, Uint8Array2 = context.Uint8Array, allocUnsafe = Buffer ? Buffer.allocUnsafe : undefined2, getPrototype = overArg(Object2.getPrototypeOf, Object2), objectCreate = Object2.create, propertyIsEnumerable = objectProto.propertyIsEnumerable, splice = arrayProto.splice, spreadableSymbol = Symbol2 ? Symbol2.isConcatSpreadable : undefined2, symIterator = Symbol2 ? Symbol2.iterator : undefined2, symToStringTag = Symbol2 ? Symbol2.toStringTag : undefined2;
1858        var defineProperty = function() {
1859          try {
1860            var func = getNative(Object2, "defineProperty");
1861            func({}, "", {});
1862            return func;
1863          } catch (e) {
1864          }
1865        }();
1866        var ctxClearTimeout = context.clearTimeout !== root.clearTimeout && context.clearTimeout, ctxNow = Date2 && Date2.now !== root.Date.now && Date2.now, ctxSetTimeout = context.setTimeout !== root.setTimeout && context.setTimeout;
1867        var nativeCeil = Math2.ceil, nativeFloor = Math2.floor, nativeGetSymbols = Object2.getOwnPropertySymbols, nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined2, nativeIsFinite = context.isFinite, nativeJoin = arrayProto.join, nativeKeys = overArg(Object2.keys, Object2), nativeMax = Math2.max, nativeMin = Math2.min, nativeNow = Date2.now, nativeParseInt = context.parseInt, nativeRandom = Math2.random, nativeReverse = arrayProto.reverse;
1868        var DataView2 = getNative(context, "DataView"), Map2 = getNative(context, "Map"), Promise2 = getNative(context, "Promise"), Set2 = getNative(context, "Set"), WeakMap2 = getNative(context, "WeakMap"), nativeCreate = getNative(Object2, "create");
1869        var metaMap = WeakMap2 && new WeakMap2();
1870        var realNames = {};
1871        var dataViewCtorString = toSource(DataView2), mapCtorString = toSource(Map2), promiseCtorString = toSource(Promise2), setCtorString = toSource(Set2), weakMapCtorString = toSource(WeakMap2);
1872        var symbolProto = Symbol2 ? Symbol2.prototype : undefined2, symbolValueOf = symbolProto ? symbolProto.valueOf : undefined2, symbolToString = symbolProto ? symbolProto.toString : undefined2;
1873        function lodash(value) {
1874          if (isObjectLike(value) && !isArray2(value) && !(value instanceof LazyWrapper)) {
1875            if (value instanceof LodashWrapper) {
1876              return value;
1877            }
1878            if (hasOwnProperty.call(value, "__wrapped__")) {
1879              return wrapperClone(value);
1880            }
1881          }
1882          return new LodashWrapper(value);
1883        }
1884        var baseCreate = /* @__PURE__ */ function() {
1885          function object() {
1886          }
1887          return function(proto) {
1888            if (!isObject7(proto)) {
1889              return {};
1890            }
1891            if (objectCreate) {
1892              return objectCreate(proto);
1893            }
1894            object.prototype = proto;
1895            var result2 = new object();
1896            object.prototype = undefined2;
1897            return result2;
1898          };
1899        }();
1900        function baseLodash() {
1901        }
1902        function LodashWrapper(value, chainAll) {
1903          this.__wrapped__ = value;
1904          this.__actions__ = [];
1905          this.__chain__ = !!chainAll;
1906          this.__index__ = 0;
1907          this.__values__ = undefined2;
1908        }
1909        lodash.templateSettings = {
1910          /**
1911           * Used to detect `data` property values to be HTML-escaped.
1912           *
1913           * @memberOf _.templateSettings
1914           * @type {RegExp}
1915           */
1916          "escape": reEscape,
1917          /**
1918           * Used to detect code to be evaluated.
1919           *
1920           * @memberOf _.templateSettings
1921           * @type {RegExp}
1922           */
1923          "evaluate": reEvaluate,
1924          /**
1925           * Used to detect `data` property values to inject.
1926           *
1927           * @memberOf _.templateSettings
1928           * @type {RegExp}
1929           */
1930          "interpolate": reInterpolate,
1931          /**
1932           * Used to reference the data object in the template text.
1933           *
1934           * @memberOf _.templateSettings
1935           * @type {string}
1936           */
1937          "variable": "",
1938          /**
1939           * Used to import variables into the compiled template.
1940           *
1941           * @memberOf _.templateSettings
1942           * @type {Object}
1943           */
1944          "imports": {
1945            /**
1946             * A reference to the `lodash` function.
1947             *
1948             * @memberOf _.templateSettings.imports
1949             * @type {Function}
1950             */
1951            "_": lodash
1952          }
1953        };
1954        lodash.prototype = baseLodash.prototype;
1955        lodash.prototype.constructor = lodash;
1956        LodashWrapper.prototype = baseCreate(baseLodash.prototype);
1957        LodashWrapper.prototype.constructor = LodashWrapper;
1958        function LazyWrapper(value) {
1959          this.__wrapped__ = value;
1960          this.__actions__ = [];
1961          this.__dir__ = 1;
1962          this.__filtered__ = false;
1963          this.__iteratees__ = [];
1964          this.__takeCount__ = MAX_ARRAY_LENGTH;
1965          this.__views__ = [];
1966        }
1967        function lazyClone() {
1968          var result2 = new LazyWrapper(this.__wrapped__);
1969          result2.__actions__ = copyArray(this.__actions__);
1970          result2.__dir__ = this.__dir__;
1971          result2.__filtered__ = this.__filtered__;
1972          result2.__iteratees__ = copyArray(this.__iteratees__);
1973          result2.__takeCount__ = this.__takeCount__;
1974          result2.__views__ = copyArray(this.__views__);
1975          return result2;
1976        }
1977        function lazyReverse() {
1978          if (this.__filtered__) {
1979            var result2 = new LazyWrapper(this);
1980            result2.__dir__ = -1;
1981            result2.__filtered__ = true;
1982          } else {
1983            result2 = this.clone();
1984            result2.__dir__ *= -1;
1985          }
1986          return result2;
1987        }
1988        function lazyValue() {
1989          var array = this.__wrapped__.value(), dir = this.__dir__, isArr = isArray2(array), isRight = dir < 0, arrLength = isArr ? array.length : 0, view = getView(0, arrLength, this.__views__), start = view.start, end = view.end, length = end - start, index = isRight ? end : start - 1, iteratees = this.__iteratees__, iterLength = iteratees.length, resIndex = 0, takeCount = nativeMin(length, this.__takeCount__);
1990          if (!isArr || !isRight && arrLength == length && takeCount == length) {
1991            return baseWrapperValue(array, this.__actions__);
1992          }
1993          var result2 = [];
1994          outer: while (length-- && resIndex < takeCount) {
1995            index += dir;
1996            var iterIndex = -1, value = array[index];
1997            while (++iterIndex < iterLength) {
1998              var data = iteratees[iterIndex], iteratee2 = data.iteratee, type = data.type, computed2 = iteratee2(value);
1999              if (type == LAZY_MAP_FLAG) {
2000                value = computed2;
2001              } else if (!computed2) {
2002                if (type == LAZY_FILTER_FLAG) {
2003                  continue outer;
2004                } else {
2005                  break outer;
2006                }
2007              }
2008            }
2009            result2[resIndex++] = value;
2010          }
2011          return result2;
2012        }
2013        LazyWrapper.prototype = baseCreate(baseLodash.prototype);
2014        LazyWrapper.prototype.constructor = LazyWrapper;
2015        function Hash(entries) {
2016          var index = -1, length = entries == null ? 0 : entries.length;
2017          this.clear();
2018          while (++index < length) {
2019            var entry = entries[index];
2020            this.set(entry[0], entry[1]);
2021          }
2022        }
2023        function hashClear() {
2024          this.__data__ = nativeCreate ? nativeCreate(null) : {};
2025          this.size = 0;
2026        }
2027        function hashDelete(key) {
2028          var result2 = this.has(key) && delete this.__data__[key];
2029          this.size -= result2 ? 1 : 0;
2030          return result2;
2031        }
2032        function hashGet(key) {
2033          var data = this.__data__;
2034          if (nativeCreate) {
2035            var result2 = data[key];
2036            return result2 === HASH_UNDEFINED ? undefined2 : result2;
2037          }
2038          return hasOwnProperty.call(data, key) ? data[key] : undefined2;
2039        }
2040        function hashHas(key) {
2041          var data = this.__data__;
2042          return nativeCreate ? data[key] !== undefined2 : hasOwnProperty.call(data, key);
2043        }
2044        function hashSet(key, value) {
2045          var data = this.__data__;
2046          this.size += this.has(key) ? 0 : 1;
2047          data[key] = nativeCreate && value === undefined2 ? HASH_UNDEFINED : value;
2048          return this;
2049        }
2050        Hash.prototype.clear = hashClear;
2051        Hash.prototype["delete"] = hashDelete;
2052        Hash.prototype.get = hashGet;
2053        Hash.prototype.has = hashHas;
2054        Hash.prototype.set = hashSet;
2055        function ListCache(entries) {
2056          var index = -1, length = entries == null ? 0 : entries.length;
2057          this.clear();
2058          while (++index < length) {
2059            var entry = entries[index];
2060            this.set(entry[0], entry[1]);
2061          }
2062        }
2063        function listCacheClear() {
2064          this.__data__ = [];
2065          this.size = 0;
2066        }
2067        function listCacheDelete(key) {
2068          var data = this.__data__, index = assocIndexOf(data, key);
2069          if (index < 0) {
2070            return false;
2071          }
2072          var lastIndex = data.length - 1;
2073          if (index == lastIndex) {
2074            data.pop();
2075          } else {
2076            splice.call(data, index, 1);
2077          }
2078          --this.size;
2079          return true;
2080        }
2081        function listCacheGet(key) {
2082          var data = this.__data__, index = assocIndexOf(data, key);
2083          return index < 0 ? undefined2 : data[index][1];
2084        }
2085        function listCacheHas(key) {
2086          return assocIndexOf(this.__data__, key) > -1;
2087        }
2088        function listCacheSet(key, value) {
2089          var data = this.__data__, index = assocIndexOf(data, key);
2090          if (index < 0) {
2091            ++this.size;
2092            data.push([key, value]);
2093          } else {
2094            data[index][1] = value;
2095          }
2096          return this;
2097        }
2098        ListCache.prototype.clear = listCacheClear;
2099        ListCache.prototype["delete"] = listCacheDelete;
2100        ListCache.prototype.get = listCacheGet;
2101        ListCache.prototype.has = listCacheHas;
2102        ListCache.prototype.set = listCacheSet;
2103        function MapCache(entries) {
2104          var index = -1, length = entries == null ? 0 : entries.length;
2105          this.clear();
2106          while (++index < length) {
2107            var entry = entries[index];
2108            this.set(entry[0], entry[1]);
2109          }
2110        }
2111        function mapCacheClear() {
2112          this.size = 0;
2113          this.__data__ = {
2114            "hash": new Hash(),
2115            "map": new (Map2 || ListCache)(),
2116            "string": new Hash()
2117          };
2118        }
2119        function mapCacheDelete(key) {
2120          var result2 = getMapData(this, key)["delete"](key);
2121          this.size -= result2 ? 1 : 0;
2122          return result2;
2123        }
2124        function mapCacheGet(key) {
2125          return getMapData(this, key).get(key);
2126        }
2127        function mapCacheHas(key) {
2128          return getMapData(this, key).has(key);
2129        }
2130        function mapCacheSet(key, value) {
2131          var data = getMapData(this, key), size2 = data.size;
2132          data.set(key, value);
2133          this.size += data.size == size2 ? 0 : 1;
2134          return this;
2135        }
2136        MapCache.prototype.clear = mapCacheClear;
2137        MapCache.prototype["delete"] = mapCacheDelete;
2138        MapCache.prototype.get = mapCacheGet;
2139        MapCache.prototype.has = mapCacheHas;
2140        MapCache.prototype.set = mapCacheSet;
2141        function SetCache(values2) {
2142          var index = -1, length = values2 == null ? 0 : values2.length;
2143          this.__data__ = new MapCache();
2144          while (++index < length) {
2145            this.add(values2[index]);
2146          }
2147        }
2148        function setCacheAdd(value) {
2149          this.__data__.set(value, HASH_UNDEFINED);
2150          return this;
2151        }
2152        function setCacheHas(value) {
2153          return this.__data__.has(value);
2154        }
2155        SetCache.prototype.add = SetCache.prototype.push = setCacheAdd;
2156        SetCache.prototype.has = setCacheHas;
2157        function Stack(entries) {
2158          var data = this.__data__ = new ListCache(entries);
2159          this.size = data.size;
2160        }
2161        function stackClear() {
2162          this.__data__ = new ListCache();
2163          this.size = 0;
2164        }
2165        function stackDelete(key) {
2166          var data = this.__data__, result2 = data["delete"](key);
2167          this.size = data.size;
2168          return result2;
2169        }
2170        function stackGet(key) {
2171          return this.__data__.get(key);
2172        }
2173        function stackHas(key) {
2174          return this.__data__.has(key);
2175        }
2176        function stackSet(key, value) {
2177          var data = this.__data__;
2178          if (data instanceof ListCache) {
2179            var pairs = data.__data__;
2180            if (!Map2 || pairs.length < LARGE_ARRAY_SIZE - 1) {
2181              pairs.push([key, value]);
2182              this.size = ++data.size;
2183              return this;
2184            }
2185            data = this.__data__ = new MapCache(pairs);
2186          }
2187          data.set(key, value);
2188          this.size = data.size;
2189          return this;
2190        }
2191        Stack.prototype.clear = stackClear;
2192        Stack.prototype["delete"] = stackDelete;
2193        Stack.prototype.get = stackGet;
2194        Stack.prototype.has = stackHas;
2195        Stack.prototype.set = stackSet;
2196        function arrayLikeKeys(value, inherited) {
2197          var isArr = isArray2(value), isArg = !isArr && isArguments(value), isBuff = !isArr && !isArg && isBuffer(value), isType = !isArr && !isArg && !isBuff && isTypedArray(value), skipIndexes = isArr || isArg || isBuff || isType, result2 = skipIndexes ? baseTimes(value.length, String2) : [], length = result2.length;
2198          for (var key in value) {
2199            if ((inherited || hasOwnProperty.call(value, key)) && !(skipIndexes && // Safari 9 has enumerable `arguments.length` in strict mode.
2200            (key == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
2201            isBuff && (key == "offset" || key == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
2202            isType && (key == "buffer" || key == "byteLength" || key == "byteOffset") || // Skip index properties.
2203            isIndex(key, length)))) {
2204              result2.push(key);
2205            }
2206          }
2207          return result2;
2208        }
2209        function arraySample(array) {
2210          var length = array.length;
2211          return length ? array[baseRandom(0, length - 1)] : undefined2;
2212        }
2213        function arraySampleSize(array, n) {
2214          return shuffleSelf(copyArray(array), baseClamp(n, 0, array.length));
2215        }
2216        function arrayShuffle(array) {
2217          return shuffleSelf(copyArray(array));
2218        }
2219        function assignMergeValue(object, key, value) {
2220          if (value !== undefined2 && !eq(object[key], value) || value === undefined2 && !(key in object)) {
2221            baseAssignValue(object, key, value);
2222          }
2223        }
2224        function assignValue(object, key, value) {
2225          var objValue = object[key];
2226          if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) || value === undefined2 && !(key in object)) {
2227            baseAssignValue(object, key, value);
2228          }
2229        }
2230        function assocIndexOf(array, key) {
2231          var length = array.length;
2232          while (length--) {
2233            if (eq(array[length][0], key)) {
2234              return length;
2235            }
2236          }
2237          return -1;
2238        }
2239        function baseAggregator(collection, setter, iteratee2, accumulator) {
2240          baseEach(collection, function(value, key, collection2) {
2241            setter(accumulator, value, iteratee2(value), collection2);
2242          });
2243          return accumulator;
2244        }
2245        function baseAssign(object, source) {
2246          return object && copyObject(source, keys(source), object);
2247        }
2248        function baseAssignIn(object, source) {
2249          return object && copyObject(source, keysIn(source), object);
2250        }
2251        function baseAssignValue(object, key, value) {
2252          if (key == "__proto__" && defineProperty) {
2253            defineProperty(object, key, {
2254              "configurable": true,
2255              "enumerable": true,
2256              "value": value,
2257              "writable": true
2258            });
2259          } else {
2260            object[key] = value;
2261          }
2262        }
2263        function baseAt(object, paths) {
2264          var index = -1, length = paths.length, result2 = Array2(length), skip = object == null;
2265          while (++index < length) {
2266            result2[index] = skip ? undefined2 : get(object, paths[index]);
2267          }
2268          return result2;
2269        }
2270        function baseClamp(number, lower, upper) {
2271          if (number === number) {
2272            if (upper !== undefined2) {
2273              number = number <= upper ? number : upper;
2274            }
2275            if (lower !== undefined2) {
2276              number = number >= lower ? number : lower;
2277            }
2278          }
2279          return number;
2280        }
2281        function baseClone(value, bitmask, customizer, key, object, stack) {
2282          var result2, isDeep = bitmask & CLONE_DEEP_FLAG, isFlat = bitmask & CLONE_FLAT_FLAG, isFull = bitmask & CLONE_SYMBOLS_FLAG;
2283          if (customizer) {
2284            result2 = object ? customizer(value, key, object, stack) : customizer(value);
2285          }
2286          if (result2 !== undefined2) {
2287            return result2;
2288          }
2289          if (!isObject7(value)) {
2290            return value;
2291          }
2292          var isArr = isArray2(value);
2293          if (isArr) {
2294            result2 = initCloneArray(value);
2295            if (!isDeep) {
2296              return copyArray(value, result2);
2297            }
2298          } else {
2299            var tag2 = getTag(value), isFunc = tag2 == funcTag || tag2 == genTag;
2300            if (isBuffer(value)) {
2301              return cloneBuffer(value, isDeep);
2302            }
2303            if (tag2 == objectTag || tag2 == argsTag || isFunc && !object) {
2304              result2 = isFlat || isFunc ? {} : initCloneObject(value);
2305              if (!isDeep) {
2306                return isFlat ? copySymbolsIn(value, baseAssignIn(result2, value)) : copySymbols(value, baseAssign(result2, value));
2307              }
2308            } else {
2309              if (!cloneableTags[tag2]) {
2310                return object ? value : {};
2311              }
2312              result2 = initCloneByTag(value, tag2, isDeep);
2313            }
2314          }
2315          stack || (stack = new Stack());
2316          var stacked = stack.get(value);
2317          if (stacked) {
2318            return stacked;
2319          }
2320          stack.set(value, result2);
2321          if (isSet(value)) {
2322            value.forEach(function(subValue) {
2323              result2.add(baseClone(subValue, bitmask, customizer, subValue, value, stack));
2324            });
2325          } else if (isMap(value)) {
2326            value.forEach(function(subValue, key2) {
2327              result2.set(key2, baseClone(subValue, bitmask, customizer, key2, value, stack));
2328            });
2329          }
2330          var keysFunc = isFull ? isFlat ? getAllKeysIn : getAllKeys : isFlat ? keysIn : keys;
2331          var props = isArr ? undefined2 : keysFunc(value);
2332          arrayEach(props || value, function(subValue, key2) {
2333            if (props) {
2334              key2 = subValue;
2335              subValue = value[key2];
2336            }
2337            assignValue(result2, key2, baseClone(subValue, bitmask, customizer, key2, value, stack));
2338          });
2339          return result2;
2340        }
2341        function baseConforms(source) {
2342          var props = keys(source);
2343          return function(object) {
2344            return baseConformsTo(object, source, props);
2345          };
2346        }
2347        function baseConformsTo(object, source, props) {
2348          var length = props.length;
2349          if (object == null) {
2350            return !length;
2351          }
2352          object = Object2(object);
2353          while (length--) {
2354            var key = props[length], predicate = source[key], value = object[key];
2355            if (value === undefined2 && !(key in object) || !predicate(value)) {
2356              return false;
2357            }
2358          }
2359          return true;
2360        }
2361        function baseDelay(func, wait, args) {
2362          if (typeof func != "function") {
2363            throw new TypeError2(FUNC_ERROR_TEXT);
2364          }
2365          return setTimeout2(function() {
2366            func.apply(undefined2, args);
2367          }, wait);
2368        }
2369        function baseDifference(array, values2, iteratee2, comparator) {
2370          var index = -1, includes2 = arrayIncludes, isCommon = true, length = array.length, result2 = [], valuesLength = values2.length;
2371          if (!length) {
2372            return result2;
2373          }
2374          if (iteratee2) {
2375            values2 = arrayMap(values2, baseUnary(iteratee2));
2376          }
2377          if (comparator) {
2378            includes2 = arrayIncludesWith;
2379            isCommon = false;
2380          } else if (values2.length >= LARGE_ARRAY_SIZE) {
2381            includes2 = cacheHas;
2382            isCommon = false;
2383            values2 = new SetCache(values2);
2384          }
2385          outer: while (++index < length) {
2386            var value = array[index], computed2 = iteratee2 == null ? value : iteratee2(value);
2387            value = comparator || value !== 0 ? value : 0;
2388            if (isCommon && computed2 === computed2) {
2389              var valuesIndex = valuesLength;
2390              while (valuesIndex--) {
2391                if (values2[valuesIndex] === computed2) {
2392                  continue outer;
2393                }
2394              }
2395              result2.push(value);
2396            } else if (!includes2(values2, computed2, comparator)) {
2397              result2.push(value);
2398            }
2399          }
2400          return result2;
2401        }
2402        var baseEach = createBaseEach(baseForOwn);
2403        var baseEachRight = createBaseEach(baseForOwnRight, true);
2404        function baseEvery(collection, predicate) {
2405          var result2 = true;
2406          baseEach(collection, function(value, index, collection2) {
2407            result2 = !!predicate(value, index, collection2);
2408            return result2;
2409          });
2410          return result2;
2411        }
2412        function baseExtremum(array, iteratee2, comparator) {
2413          var index = -1, length = array.length;
2414          while (++index < length) {
2415            var value = array[index], current = iteratee2(value);
2416            if (current != null && (computed2 === undefined2 ? current === current && !isSymbol(current) : comparator(current, computed2))) {
2417              var computed2 = current, result2 = value;
2418            }
2419          }
2420          return result2;
2421        }
2422        function baseFill(array, value, start, end) {
2423          var length = array.length;
2424          start = toInteger2(start);
2425          if (start < 0) {
2426            start = -start > length ? 0 : length + start;
2427          }
2428          end = end === undefined2 || end > length ? length : toInteger2(end);
2429          if (end < 0) {
2430            end += length;
2431          }
2432          end = start > end ? 0 : toLength(end);
2433          while (start < end) {
2434            array[start++] = value;
2435          }
2436          return array;
2437        }
2438        function baseFilter(collection, predicate) {
2439          var result2 = [];
2440          baseEach(collection, function(value, index, collection2) {
2441            if (predicate(value, index, collection2)) {
2442              result2.push(value);
2443            }
2444          });
2445          return result2;
2446        }
2447        function baseFlatten(array, depth, predicate, isStrict, result2) {
2448          var index = -1, length = array.length;
2449          predicate || (predicate = isFlattenable);
2450          result2 || (result2 = []);
2451          while (++index < length) {
2452            var value = array[index];
2453            if (depth > 0 && predicate(value)) {
2454              if (depth > 1) {
2455                baseFlatten(value, depth - 1, predicate, isStrict, result2);
2456              } else {
2457                arrayPush(result2, value);
2458              }
2459            } else if (!isStrict) {
2460              result2[result2.length] = value;
2461            }
2462          }
2463          return result2;
2464        }
2465        var baseFor = createBaseFor();
2466        var baseForRight = createBaseFor(true);
2467        function baseForOwn(object, iteratee2) {
2468          return object && baseFor(object, iteratee2, keys);
2469        }
2470        function baseForOwnRight(object, iteratee2) {
2471          return object && baseForRight(object, iteratee2, keys);
2472        }
2473        function baseFunctions(object, props) {
2474          return arrayFilter(props, function(key) {
2475            return isFunction3(object[key]);
2476          });
2477        }
2478        function baseGet(object, path2) {
2479          path2 = castPath(path2, object);
2480          var index = 0, length = path2.length;
2481          while (object != null && index < length) {
2482            object = object[toKey(path2[index++])];
2483          }
2484          return index && index == length ? object : undefined2;
2485        }
2486        function baseGetAllKeys(object, keysFunc, symbolsFunc) {
2487          var result2 = keysFunc(object);
2488          return isArray2(object) ? result2 : arrayPush(result2, symbolsFunc(object));
2489        }
2490        function baseGetTag(value) {
2491          if (value == null) {
2492            return value === undefined2 ? undefinedTag : nullTag;
2493          }
2494          return symToStringTag && symToStringTag in Object2(value) ? getRawTag(value) : objectToString(value);
2495        }
2496        function baseGt(value, other2) {
2497          return value > other2;
2498        }
2499        function baseHas(object, key) {
2500          return object != null && hasOwnProperty.call(object, key);
2501        }
2502        function baseHasIn(object, key) {
2503          return object != null && key in Object2(object);
2504        }
2505        function baseInRange(number, start, end) {
2506          return number >= nativeMin(start, end) && number < nativeMax(start, end);
2507        }
2508        function baseIntersection(arrays, iteratee2, comparator) {
2509          var includes2 = comparator ? arrayIncludesWith : arrayIncludes, length = arrays[0].length, othLength = arrays.length, othIndex = othLength, caches = Array2(othLength), maxLength = Infinity, result2 = [];
2510          while (othIndex--) {
2511            var array = arrays[othIndex];
2512            if (othIndex && iteratee2) {
2513              array = arrayMap(array, baseUnary(iteratee2));
2514            }
2515            maxLength = nativeMin(array.length, maxLength);
2516            caches[othIndex] = !comparator && (iteratee2 || length >= 120 && array.length >= 120) ? new SetCache(othIndex && array) : undefined2;
2517          }
2518          array = arrays[0];
2519          var index = -1, seen = caches[0];
2520          outer: while (++index < length && result2.length < maxLength) {
2521            var value = array[index], computed2 = iteratee2 ? iteratee2(value) : value;
2522            value = comparator || value !== 0 ? value : 0;
2523            if (!(seen ? cacheHas(seen, computed2) : includes2(result2, computed2, comparator))) {
2524              othIndex = othLength;
2525              while (--othIndex) {
2526                var cache = caches[othIndex];
2527                if (!(cache ? cacheHas(cache, computed2) : includes2(arrays[othIndex], computed2, comparator))) {
2528                  continue outer;
2529                }
2530              }
2531              if (seen) {
2532                seen.push(computed2);
2533              }
2534              result2.push(value);
2535            }
2536          }
2537          return result2;
2538        }
2539        function baseInverter(object, setter, iteratee2, accumulator) {
2540          baseForOwn(object, function(value, key, object2) {
2541            setter(accumulator, iteratee2(value), key, object2);
2542          });
2543          return accumulator;
2544        }
2545        function baseInvoke(object, path2, args) {
2546          path2 = castPath(path2, object);
2547          object = parent(object, path2);
2548          var func = object == null ? object : object[toKey(last(path2))];
2549          return func == null ? undefined2 : apply(func, object, args);
2550        }
2551        function baseIsArguments(value) {
2552          return isObjectLike(value) && baseGetTag(value) == argsTag;
2553        }
2554        function baseIsArrayBuffer(value) {
2555          return isObjectLike(value) && baseGetTag(value) == arrayBufferTag;
2556        }
2557        function baseIsDate(value) {
2558          return isObjectLike(value) && baseGetTag(value) == dateTag;
2559        }
2560        function baseIsEqual(value, other2, bitmask, customizer, stack) {
2561          if (value === other2) {
2562            return true;
2563          }
2564          if (value == null || other2 == null || !isObjectLike(value) && !isObjectLike(other2)) {
2565            return value !== value && other2 !== other2;
2566          }
2567          return baseIsEqualDeep(value, other2, bitmask, customizer, baseIsEqual, stack);
2568        }
2569        function baseIsEqualDeep(object, other2, bitmask, customizer, equalFunc, stack) {
2570          var objIsArr = isArray2(object), othIsArr = isArray2(other2), objTag = objIsArr ? arrayTag : getTag(object), othTag = othIsArr ? arrayTag : getTag(other2);
2571          objTag = objTag == argsTag ? objectTag : objTag;
2572          othTag = othTag == argsTag ? objectTag : othTag;
2573          var objIsObj = objTag == objectTag, othIsObj = othTag == objectTag, isSameTag = objTag == othTag;
2574          if (isSameTag && isBuffer(object)) {
2575            if (!isBuffer(other2)) {
2576              return false;
2577            }
2578            objIsArr = true;
2579            objIsObj = false;
2580          }
2581          if (isSameTag && !objIsObj) {
2582            stack || (stack = new Stack());
2583            return objIsArr || isTypedArray(object) ? equalArrays(object, other2, bitmask, customizer, equalFunc, stack) : equalByTag(object, other2, objTag, bitmask, customizer, equalFunc, stack);
2584          }
2585          if (!(bitmask & COMPARE_PARTIAL_FLAG)) {
2586            var objIsWrapped = objIsObj && hasOwnProperty.call(object, "__wrapped__"), othIsWrapped = othIsObj && hasOwnProperty.call(other2, "__wrapped__");
2587            if (objIsWrapped || othIsWrapped) {
2588              var objUnwrapped = objIsWrapped ? object.value() : object, othUnwrapped = othIsWrapped ? other2.value() : other2;
2589              stack || (stack = new Stack());
2590              return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);
2591            }
2592          }
2593          if (!isSameTag) {
2594            return false;
2595          }
2596          stack || (stack = new Stack());
2597          return equalObjects(object, other2, bitmask, customizer, equalFunc, stack);
2598        }
2599        function baseIsMap(value) {
2600          return isObjectLike(value) && getTag(value) == mapTag;
2601        }
2602        function baseIsMatch(object, source, matchData, customizer) {
2603          var index = matchData.length, length = index, noCustomizer = !customizer;
2604          if (object == null) {
2605            return !length;
2606          }
2607          object = Object2(object);
2608          while (index--) {
2609            var data = matchData[index];
2610            if (noCustomizer && data[2] ? data[1] !== object[data[0]] : !(data[0] in object)) {
2611              return false;
2612            }
2613          }
2614          while (++index < length) {
2615            data = matchData[index];
2616            var key = data[0], objValue = object[key], srcValue = data[1];
2617            if (noCustomizer && data[2]) {
2618              if (objValue === undefined2 && !(key in object)) {
2619                return false;
2620              }
2621            } else {
2622              var stack = new Stack();
2623              if (customizer) {
2624                var result2 = customizer(objValue, srcValue, key, object, source, stack);
2625              }
2626              if (!(result2 === undefined2 ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack) : result2)) {
2627                return false;
2628              }
2629            }
2630          }
2631          return true;
2632        }
2633        function baseIsNative(value) {
2634          if (!isObject7(value) || isMasked(value)) {
2635            return false;
2636          }
2637          var pattern = isFunction3(value) ? reIsNative : reIsHostCtor;
2638          return pattern.test(toSource(value));
2639        }
2640        function baseIsRegExp(value) {
2641          return isObjectLike(value) && baseGetTag(value) == regexpTag;
2642        }
2643        function baseIsSet(value) {
2644          return isObjectLike(value) && getTag(value) == setTag;
2645        }
2646        function baseIsTypedArray(value) {
2647          return isObjectLike(value) && isLength(value.length) && !!typedArrayTags[baseGetTag(value)];
2648        }
2649        function baseIteratee(value) {
2650          if (typeof value == "function") {
2651            return value;
2652          }
2653          if (value == null) {
2654            return identity2;
2655          }
2656          if (typeof value == "object") {
2657            return isArray2(value) ? baseMatchesProperty(value[0], value[1]) : baseMatches(value);
2658          }
2659          return property(value);
2660        }
2661        function baseKeys(object) {
2662          if (!isPrototype(object)) {
2663            return nativeKeys(object);
2664          }
2665          var result2 = [];
2666          for (var key in Object2(object)) {
2667            if (hasOwnProperty.call(object, key) && key != "constructor") {
2668              result2.push(key);
2669            }
2670          }
2671          return result2;
2672        }
2673        function baseKeysIn(object) {
2674          if (!isObject7(object)) {
2675            return nativeKeysIn(object);
2676          }
2677          var isProto = isPrototype(object), result2 = [];
2678          for (var key in object) {
2679            if (!(key == "constructor" && (isProto || !hasOwnProperty.call(object, key)))) {
2680              result2.push(key);
2681            }
2682          }
2683          return result2;
2684        }
2685        function baseLt(value, other2) {
2686          return value < other2;
2687        }
2688        function baseMap(collection, iteratee2) {
2689          var index = -1, result2 = isArrayLike(collection) ? Array2(collection.length) : [];
2690          baseEach(collection, function(value, key, collection2) {
2691            result2[++index] = iteratee2(value, key, collection2);
2692          });
2693          return result2;
2694        }
2695        function baseMatches(source) {
2696          var matchData = getMatchData(source);
2697          if (matchData.length == 1 && matchData[0][2]) {
2698            return matchesStrictComparable(matchData[0][0], matchData[0][1]);
2699          }
2700          return function(object) {
2701            return object === source || baseIsMatch(object, source, matchData);
2702          };
2703        }
2704        function baseMatchesProperty(path2, srcValue) {
2705          if (isKey(path2) && isStrictComparable(srcValue)) {
2706            return matchesStrictComparable(toKey(path2), srcValue);
2707          }
2708          return function(object) {
2709            var objValue = get(object, path2);
2710            return objValue === undefined2 && objValue === srcValue ? hasIn(object, path2) : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);
2711          };
2712        }
2713        function baseMerge(object, source, srcIndex, customizer, stack) {
2714          if (object === source) {
2715            return;
2716          }
2717          baseFor(source, function(srcValue, key) {
2718            stack || (stack = new Stack());
2719            if (isObject7(srcValue)) {
2720              baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack);
2721            } else {
2722              var newValue = customizer ? customizer(safeGet(object, key), srcValue, key + "", object, source, stack) : undefined2;
2723              if (newValue === undefined2) {
2724                newValue = srcValue;
2725              }
2726              assignMergeValue(object, key, newValue);
2727            }
2728          }, keysIn);
2729        }
2730        function baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) {
2731          var objValue = safeGet(object, key), srcValue = safeGet(source, key), stacked = stack.get(srcValue);
2732          if (stacked) {
2733            assignMergeValue(object, key, stacked);
2734            return;
2735          }
2736          var newValue = customizer ? customizer(objValue, srcValue, key + "", object, source, stack) : undefined2;
2737          var isCommon = newValue === undefined2;
2738          if (isCommon) {
2739            var isArr = isArray2(srcValue), isBuff = !isArr && isBuffer(srcValue), isTyped = !isArr && !isBuff && isTypedArray(srcValue);
2740            newValue = srcValue;
2741            if (isArr || isBuff || isTyped) {
2742              if (isArray2(objValue)) {
2743                newValue = objValue;
2744              } else if (isArrayLikeObject(objValue)) {
2745                newValue = copyArray(objValue);
2746              } else if (isBuff) {
2747                isCommon = false;
2748                newValue = cloneBuffer(srcValue, true);
2749              } else if (isTyped) {
2750                isCommon = false;
2751                newValue = cloneTypedArray(srcValue, true);
2752              } else {
2753                newValue = [];
2754              }
2755            } else if (isPlainObject(srcValue) || isArguments(srcValue)) {
2756              newValue = objValue;
2757              if (isArguments(objValue)) {
2758                newValue = toPlainObject(objValue);
2759              } else if (!isObject7(objValue) || isFunction3(objValue)) {
2760                newValue = initCloneObject(srcValue);
2761              }
2762            } else {
2763              isCommon = false;
2764            }
2765          }
2766          if (isCommon) {
2767            stack.set(srcValue, newValue);
2768            mergeFunc(newValue, srcValue, srcIndex, customizer, stack);
2769            stack["delete"](srcValue);
2770          }
2771          assignMergeValue(object, key, newValue);
2772        }
2773        function baseNth(array, n) {
2774          var length = array.length;
2775          if (!length) {
2776            return;
2777          }
2778          n += n < 0 ? length : 0;
2779          return isIndex(n, length) ? array[n] : undefined2;
2780        }
2781        function baseOrderBy(collection, iteratees, orders) {
2782          if (iteratees.length) {
2783            iteratees = arrayMap(iteratees, function(iteratee2) {
2784              if (isArray2(iteratee2)) {
2785                return function(value) {
2786                  return baseGet(value, iteratee2.length === 1 ? iteratee2[0] : iteratee2);
2787                };
2788              }
2789              return iteratee2;
2790            });
2791          } else {
2792            iteratees = [identity2];
2793          }
2794          var index = -1;
2795          iteratees = arrayMap(iteratees, baseUnary(getIteratee()));
2796          var result2 = baseMap(collection, function(value, key, collection2) {
2797            var criteria = arrayMap(iteratees, function(iteratee2) {
2798              return iteratee2(value);
2799            });
2800            return {
2801              "criteria": criteria,
2802              "index": ++index,
2803              "value": value
2804            };
2805          });
2806          return baseSortBy(result2, function(object, other2) {
2807            return compareMultiple(object, other2, orders);
2808          });
2809        }
2810        function basePick(object, paths) {
2811          return basePickBy(object, paths, function(value, path2) {
2812            return hasIn(object, path2);
2813          });
2814        }
2815        function basePickBy(object, paths, predicate) {
2816          var index = -1, length = paths.length, result2 = {};
2817          while (++index < length) {
2818            var path2 = paths[index], value = baseGet(object, path2);
2819            if (predicate(value, path2)) {
2820              baseSet(result2, castPath(path2, object), value);
2821            }
2822          }
2823          return result2;
2824        }
2825        function basePropertyDeep(path2) {
2826          return function(object) {
2827            return baseGet(object, path2);
2828          };
2829        }
2830        function basePullAll(array, values2, iteratee2, comparator) {
2831          var indexOf2 = comparator ? baseIndexOfWith : baseIndexOf, index = -1, length = values2.length, seen = array;
2832          if (array === values2) {
2833            values2 = copyArray(values2);
2834          }
2835          if (iteratee2) {
2836            seen = arrayMap(array, baseUnary(iteratee2));
2837          }
2838          while (++index < length) {
2839            var fromIndex = 0, value = values2[index], computed2 = iteratee2 ? iteratee2(value) : value;
2840            while ((fromIndex = indexOf2(seen, computed2, fromIndex, comparator)) > -1) {
2841              if (seen !== array) {
2842                splice.call(seen, fromIndex, 1);
2843              }
2844              splice.call(array, fromIndex, 1);
2845            }
2846          }
2847          return array;
2848        }
2849        function basePullAt(array, indexes) {
2850          var length = array ? indexes.length : 0, lastIndex = length - 1;
2851          while (length--) {
2852            var index = indexes[length];
2853            if (length == lastIndex || index !== previous) {
2854              var previous = index;
2855              if (isIndex(index)) {
2856                splice.call(array, index, 1);
2857              } else {
2858                baseUnset(array, index);
2859              }
2860            }
2861          }
2862          return array;
2863        }
2864        function baseRandom(lower, upper) {
2865          return lower + nativeFloor(nativeRandom() * (upper - lower + 1));
2866        }
2867        function baseRange(start, end, step, fromRight) {
2868          var index = -1, length = nativeMax(nativeCeil((end - start) / (step || 1)), 0), result2 = Array2(length);
2869          while (length--) {
2870            result2[fromRight ? length : ++index] = start;
2871            start += step;
2872          }
2873          return result2;
2874        }
2875        function baseRepeat(string, n) {
2876          var result2 = "";
2877          if (!string || n < 1 || n > MAX_SAFE_INTEGER) {
2878            return result2;
2879          }
2880          do {
2881            if (n % 2) {
2882              result2 += string;
2883            }
2884            n = nativeFloor(n / 2);
2885            if (n) {
2886              string += string;
2887            }
2888          } while (n);
2889          return result2;
2890        }
2891        function baseRest(func, start) {
2892          return setToString(overRest(func, start, identity2), func + "");
2893        }
2894        function baseSample(collection) {
2895          return arraySample(values(collection));
2896        }
2897        function baseSampleSize(collection, n) {
2898          var array = values(collection);
2899          return shuffleSelf(array, baseClamp(n, 0, array.length));
2900        }
2901        function baseSet(object, path2, value, customizer) {
2902          if (!isObject7(object)) {
2903            return object;
2904          }
2905          path2 = castPath(path2, object);
2906          var index = -1, length = path2.length, lastIndex = length - 1, nested = object;
2907          while (nested != null && ++index < length) {
2908            var key = toKey(path2[index]), newValue = value;
2909            if (key === "__proto__" || key === "constructor" || key === "prototype") {
2910              return object;
2911            }
2912            if (index != lastIndex) {
2913              var objValue = nested[key];
2914              newValue = customizer ? customizer(objValue, key, nested) : undefined2;
2915              if (newValue === undefined2) {
2916                newValue = isObject7(objValue) ? objValue : isIndex(path2[index + 1]) ? [] : {};
2917              }
2918            }
2919            assignValue(nested, key, newValue);
2920            nested = nested[key];
2921          }
2922          return object;
2923        }
2924        var baseSetData = !metaMap ? identity2 : function(func, data) {
2925          metaMap.set(func, data);
2926          return func;
2927        };
2928        var baseSetToString = !defineProperty ? identity2 : function(func, string) {
2929          return defineProperty(func, "toString", {
2930            "configurable": true,
2931            "enumerable": false,
2932            "value": constant(string),
2933            "writable": true
2934          });
2935        };
2936        function baseShuffle(collection) {
2937          return shuffleSelf(values(collection));
2938        }
2939        function baseSlice(array, start, end) {
2940          var index = -1, length = array.length;
2941          if (start < 0) {
2942            start = -start > length ? 0 : length + start;
2943          }
2944          end = end > length ? length : end;
2945          if (end < 0) {
2946            end += length;
2947          }
2948          length = start > end ? 0 : end - start >>> 0;
2949          start >>>= 0;
2950          var result2 = Array2(length);
2951          while (++index < length) {
2952            result2[index] = array[index + start];
2953          }
2954          return result2;
2955        }
2956        function baseSome(collection, predicate) {
2957          var result2;
2958          baseEach(collection, function(value, index, collection2) {
2959            result2 = predicate(value, index, collection2);
2960            return !result2;
2961          });
2962          return !!result2;
2963        }
2964        function baseSortedIndex(array, value, retHighest) {
2965          var low = 0, high = array == null ? low : array.length;
2966          if (typeof value == "number" && value === value && high <= HALF_MAX_ARRAY_LENGTH) {
2967            while (low < high) {
2968              var mid = low + high >>> 1, computed2 = array[mid];
2969              if (computed2 !== null && !isSymbol(computed2) && (retHighest ? computed2 <= value : computed2 < value)) {
2970                low = mid + 1;
2971              } else {
2972                high = mid;
2973              }
2974            }
2975            return high;
2976          }
2977          return baseSortedIndexBy(array, value, identity2, retHighest);
2978        }
2979        function baseSortedIndexBy(array, value, iteratee2, retHighest) {
2980          var low = 0, high = array == null ? 0 : array.length;
2981          if (high === 0) {
2982            return 0;
2983          }
2984          value = iteratee2(value);
2985          var valIsNaN = value !== value, valIsNull = value === null, valIsSymbol = isSymbol(value), valIsUndefined = value === undefined2;
2986          while (low < high) {
2987            var mid = nativeFloor((low + high) / 2), computed2 = iteratee2(array[mid]), othIsDefined = computed2 !== undefined2, othIsNull = computed2 === null, othIsReflexive = computed2 === computed2, othIsSymbol = isSymbol(computed2);
2988            if (valIsNaN) {
2989              var setLow = retHighest || othIsReflexive;
2990            } else if (valIsUndefined) {
2991              setLow = othIsReflexive && (retHighest || othIsDefined);
2992            } else if (valIsNull) {
2993              setLow = othIsReflexive && othIsDefined && (retHighest || !othIsNull);
2994            } else if (valIsSymbol) {
2995              setLow = othIsReflexive && othIsDefined && !othIsNull && (retHighest || !othIsSymbol);
2996            } else if (othIsNull || othIsSymbol) {
2997              setLow = false;
2998            } else {
2999              setLow = retHighest ? computed2 <= value : computed2 < value;
3000            }
3001            if (setLow) {
3002              low = mid + 1;
3003            } else {
3004              high = mid;
3005            }
3006          }
3007          return nativeMin(high, MAX_ARRAY_INDEX);
3008        }
3009        function baseSortedUniq(array, iteratee2) {
3010          var index = -1, length = array.length, resIndex = 0, result2 = [];
3011          while (++index < length) {
3012            var value = array[index], computed2 = iteratee2 ? iteratee2(value) : value;
3013            if (!index || !eq(computed2, seen)) {
3014              var seen = computed2;
3015              result2[resIndex++] = value === 0 ? 0 : value;
3016            }
3017          }
3018          return result2;
3019        }
3020        function baseToNumber(value) {
3021          if (typeof value == "number") {
3022            return value;
3023          }
3024          if (isSymbol(value)) {
3025            return NAN;
3026          }
3027          return +value;
3028        }
3029        function baseToString(value) {
3030          if (typeof value == "string") {
3031            return value;
3032          }
3033          if (isArray2(value)) {
3034            return arrayMap(value, baseToString) + "";
3035          }
3036          if (isSymbol(value)) {
3037            return symbolToString ? symbolToString.call(value) : "";
3038          }
3039          var result2 = value + "";
3040          return result2 == "0" && 1 / value == -INFINITY ? "-0" : result2;
3041        }
3042        function baseUniq(array, iteratee2, comparator) {
3043          var index = -1, includes2 = arrayIncludes, length = array.length, isCommon = true, result2 = [], seen = result2;
3044          if (comparator) {
3045            isCommon = false;
3046            includes2 = arrayIncludesWith;
3047          } else if (length >= LARGE_ARRAY_SIZE) {
3048            var set2 = iteratee2 ? null : createSet(array);
3049            if (set2) {
3050              return setToArray(set2);
3051            }
3052            isCommon = false;
3053            includes2 = cacheHas;
3054            seen = new SetCache();
3055          } else {
3056            seen = iteratee2 ? [] : result2;
3057          }
3058          outer: while (++index < length) {
3059            var value = array[index], computed2 = iteratee2 ? iteratee2(value) : value;
3060            value = comparator || value !== 0 ? value : 0;
3061            if (isCommon && computed2 === computed2) {
3062              var seenIndex = seen.length;
3063              while (seenIndex--) {
3064                if (seen[seenIndex] === computed2) {
3065                  continue outer;
3066                }
3067              }
3068              if (iteratee2) {
3069                seen.push(computed2);
3070              }
3071              result2.push(value);
3072            } else if (!includes2(seen, computed2, comparator)) {
3073              if (seen !== result2) {
3074                seen.push(computed2);
3075              }
3076              result2.push(value);
3077            }
3078          }
3079          return result2;
3080        }
3081        function baseUnset(object, path2) {
3082          path2 = castPath(path2, object);
3083          object = parent(object, path2);
3084          return object == null || delete object[toKey(last(path2))];
3085        }
3086        function baseUpdate(object, path2, updater, customizer) {
3087          return baseSet(object, path2, updater(baseGet(object, path2)), customizer);
3088        }
3089        function baseWhile(array, predicate, isDrop, fromRight) {
3090          var length = array.length, index = fromRight ? length : -1;
3091          while ((fromRight ? index-- : ++index < length) && predicate(array[index], index, array)) {
3092          }
3093          return isDrop ? baseSlice(array, fromRight ? 0 : index, fromRight ? index + 1 : length) : baseSlice(array, fromRight ? index + 1 : 0, fromRight ? length : index);
3094        }
3095        function baseWrapperValue(value, actions) {
3096          var result2 = value;
3097          if (result2 instanceof LazyWrapper) {
3098            result2 = result2.value();
3099          }
3100          return arrayReduce(actions, function(result3, action) {
3101            return action.func.apply(action.thisArg, arrayPush([result3], action.args));
3102          }, result2);
3103        }
3104        function baseXor(arrays, iteratee2, comparator) {
3105          var length = arrays.length;
3106          if (length < 2) {
3107            return length ? baseUniq(arrays[0]) : [];
3108          }
3109          var index = -1, result2 = Array2(length);
3110          while (++index < length) {
3111            var array = arrays[index], othIndex = -1;
3112            while (++othIndex < length) {
3113              if (othIndex != index) {
3114                result2[index] = baseDifference(result2[index] || array, arrays[othIndex], iteratee2, comparator);
3115              }
3116            }
3117          }
3118          return baseUniq(baseFlatten(result2, 1), iteratee2, comparator);
3119        }
3120        function baseZipObject(props, values2, assignFunc) {
3121          var index = -1, length = props.length, valsLength = values2.length, result2 = {};
3122          while (++index < length) {
3123            var value = index < valsLength ? values2[index] : undefined2;
3124            assignFunc(result2, props[index], value);
3125          }
3126          return result2;
3127        }
3128        function castArrayLikeObject(value) {
3129          return isArrayLikeObject(value) ? value : [];
3130        }
3131        function castFunction(value) {
3132          return typeof value == "function" ? value : identity2;
3133        }
3134        function castPath(value, object) {
3135          if (isArray2(value)) {
3136            return value;
3137          }
3138          return isKey(value, object) ? [value] : stringToPath(toString(value));
3139        }
3140        var castRest = baseRest;
3141        function castSlice(array, start, end) {
3142          var length = array.length;
3143          end = end === undefined2 ? length : end;
3144          return !start && end >= length ? array : baseSlice(array, start, end);
3145        }
3146        var clearTimeout2 = ctxClearTimeout || function(id) {
3147          return root.clearTimeout(id);
3148        };
3149        function cloneBuffer(buffer, isDeep) {
3150          if (isDeep) {
3151            return buffer.slice();
3152          }
3153          var length = buffer.length, result2 = allocUnsafe ? allocUnsafe(length) : new buffer.constructor(length);
3154          buffer.copy(result2);
3155          return result2;
3156        }
3157        function cloneArrayBuffer(arrayBuffer) {
3158          var result2 = new arrayBuffer.constructor(arrayBuffer.byteLength);
3159          new Uint8Array2(result2).set(new Uint8Array2(arrayBuffer));
3160          return result2;
3161        }
3162        function cloneDataView(dataView, isDeep) {
3163          var buffer = isDeep ? cloneArrayBuffer(dataView.buffer) : dataView.buffer;
3164          return new dataView.constructor(buffer, dataView.byteOffset, dataView.byteLength);
3165        }
3166        function cloneRegExp(regexp) {
3167          var result2 = new regexp.constructor(regexp.source, reFlags.exec(regexp));
3168          result2.lastIndex = regexp.lastIndex;
3169          return result2;
3170        }
3171        function cloneSymbol(symbol) {
3172          return symbolValueOf ? Object2(symbolValueOf.call(symbol)) : {};
3173        }
3174        function cloneTypedArray(typedArray, isDeep) {
3175          var buffer = isDeep ? cloneArrayBuffer(typedArray.buffer) : typedArray.buffer;
3176          return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);
3177        }
3178        function compareAscending(value, other2) {
3179          if (value !== other2) {
3180            var valIsDefined = value !== undefined2, valIsNull = value === null, valIsReflexive = value === value, valIsSymbol = isSymbol(value);
3181            var othIsDefined = other2 !== undefined2, othIsNull = other2 === null, othIsReflexive = other2 === other2, othIsSymbol = isSymbol(other2);
3182            if (!othIsNull && !othIsSymbol && !valIsSymbol && value > other2 || valIsSymbol && othIsDefined && othIsReflexive && !othIsNull && !othIsSymbol || valIsNull && othIsDefined && othIsReflexive || !valIsDefined && othIsReflexive || !valIsReflexive) {
3183              return 1;
3184            }
3185            if (!valIsNull && !valIsSymbol && !othIsSymbol && value < other2 || othIsSymbol && valIsDefined && valIsReflexive && !valIsNull && !valIsSymbol || othIsNull && valIsDefined && valIsReflexive || !othIsDefined && valIsReflexive || !othIsReflexive) {
3186              return -1;
3187            }
3188          }
3189          return 0;
3190        }
3191        function compareMultiple(object, other2, orders) {
3192          var index = -1, objCriteria = object.criteria, othCriteria = other2.criteria, length = objCriteria.length, ordersLength = orders.length;
3193          while (++index < length) {
3194            var result2 = compareAscending(objCriteria[index], othCriteria[index]);
3195            if (result2) {
3196              if (index >= ordersLength) {
3197                return result2;
3198              }
3199              var order = orders[index];
3200              return result2 * (order == "desc" ? -1 : 1);
3201            }
3202          }
3203          return object.index - other2.index;
3204        }
3205        function composeArgs(args, partials, holders, isCurried) {
3206          var argsIndex = -1, argsLength = args.length, holdersLength = holders.length, leftIndex = -1, leftLength = partials.length, rangeLength = nativeMax(argsLength - holdersLength, 0), result2 = Array2(leftLength + rangeLength), isUncurried = !isCurried;
3207          while (++leftIndex < leftLength) {
3208            result2[leftIndex] = partials[leftIndex];
3209          }
3210          while (++argsIndex < holdersLength) {
3211            if (isUncurried || argsIndex < argsLength) {
3212              result2[holders[argsIndex]] = args[argsIndex];
3213            }
3214          }
3215          while (rangeLength--) {
3216            result2[leftIndex++] = args[argsIndex++];
3217          }
3218          return result2;
3219        }
3220        function composeArgsRight(args, partials, holders, isCurried) {
3221          var argsIndex = -1, argsLength = args.length, holdersIndex = -1, holdersLength = holders.length, rightIndex = -1, rightLength = partials.length, rangeLength = nativeMax(argsLength - holdersLength, 0), result2 = Array2(rangeLength + rightLength), isUncurried = !isCurried;
3222          while (++argsIndex < rangeLength) {
3223            result2[argsIndex] = args[argsIndex];
3224          }
3225          var offset = argsIndex;
3226          while (++rightIndex < rightLength) {
3227            result2[offset + rightIndex] = partials[rightIndex];
3228          }
3229          while (++holdersIndex < holdersLength) {
3230            if (isUncurried || argsIndex < argsLength) {
3231              result2[offset + holders[holdersIndex]] = args[argsIndex++];
3232            }
3233          }
3234          return result2;
3235        }
3236        function copyArray(source, array) {
3237          var index = -1, length = source.length;
3238          array || (array = Array2(length));
3239          while (++index < length) {
3240            array[index] = source[index];
3241          }
3242          return array;
3243        }
3244        function copyObject(source, props, object, customizer) {
3245          var isNew = !object;
3246          object || (object = {});
3247          var index = -1, length = props.length;
3248          while (++index < length) {
3249            var key = props[index];
3250            var newValue = customizer ? customizer(object[key], source[key], key, object, source) : undefined2;
3251            if (newValue === undefined2) {
3252              newValue = source[key];
3253            }
3254            if (isNew) {
3255              baseAssignValue(object, key, newValue);
3256            } else {
3257              assignValue(object, key, newValue);
3258            }
3259          }
3260          return object;
3261        }
3262        function copySymbols(source, object) {
3263          return copyObject(source, getSymbols(source), object);
3264        }
3265        function copySymbolsIn(source, object) {
3266          return copyObject(source, getSymbolsIn(source), object);
3267        }
3268        function createAggregator(setter, initializer) {
3269          return function(collection, iteratee2) {
3270            var func = isArray2(collection) ? arrayAggregator : baseAggregator, accumulator = initializer ? initializer() : {};
3271            return func(collection, setter, getIteratee(iteratee2, 2), accumulator);
3272          };
3273        }
3274        function createAssigner(assigner) {
3275          return baseRest(function(object, sources) {
3276            var index = -1, length = sources.length, customizer = length > 1 ? sources[length - 1] : undefined2, guard = length > 2 ? sources[2] : undefined2;
3277            customizer = assigner.length > 3 && typeof customizer == "function" ? (length--, customizer) : undefined2;
3278            if (guard && isIterateeCall(sources[0], sources[1], guard)) {
3279              customizer = length < 3 ? undefined2 : customizer;
3280              length = 1;
3281            }
3282            object = Object2(object);
3283            while (++index < length) {
3284              var source = sources[index];
3285              if (source) {
3286                assigner(object, source, index, customizer);
3287              }
3288            }
3289            return object;
3290          });
3291        }
3292        function createBaseEach(eachFunc, fromRight) {
3293          return function(collection, iteratee2) {
3294            if (collection == null) {
3295              return collection;
3296            }
3297            if (!isArrayLike(collection)) {
3298              return eachFunc(collection, iteratee2);
3299            }
3300            var length = collection.length, index = fromRight ? length : -1, iterable = Object2(collection);
3301            while (fromRight ? index-- : ++index < length) {
3302              if (iteratee2(iterable[index], index, iterable) === false) {
3303                break;
3304              }
3305            }
3306            return collection;
3307          };
3308        }
3309        function createBaseFor(fromRight) {
3310          return function(object, iteratee2, keysFunc) {
3311            var index = -1, iterable = Object2(object), props = keysFunc(object), length = props.length;
3312            while (length--) {
3313              var key = props[fromRight ? length : ++index];
3314              if (iteratee2(iterable[key], key, iterable) === false) {
3315                break;
3316              }
3317            }
3318            return object;
3319          };
3320        }
3321        function createBind(func, bitmask, thisArg) {
3322          var isBind = bitmask & WRAP_BIND_FLAG, Ctor = createCtor(func);
3323          function wrapper() {
3324            var fn = this && this !== root && this instanceof wrapper ? Ctor : func;
3325            return fn.apply(isBind ? thisArg : this, arguments);
3326          }
3327          return wrapper;
3328        }
3329        function createCaseFirst(methodName) {
3330          return function(string) {
3331            string = toString(string);
3332            var strSymbols = hasUnicode(string) ? stringToArray(string) : undefined2;
3333            var chr = strSymbols ? strSymbols[0] : string.charAt(0);
3334            var trailing = strSymbols ? castSlice(strSymbols, 1).join("") : string.slice(1);
3335            return chr[methodName]() + trailing;
3336          };
3337        }
3338        function createCompounder(callback) {
3339          return function(string) {
3340            return arrayReduce(words(deburr(string).replace(reApos, "")), callback, "");
3341          };
3342        }
3343        function createCtor(Ctor) {
3344          return function() {
3345            var args = arguments;
3346            switch (args.length) {
3347              case 0:
3348                return new Ctor();
3349              case 1:
3350                return new Ctor(args[0]);
3351              case 2:
3352                return new Ctor(args[0], args[1]);
3353              case 3:
3354                return new Ctor(args[0], args[1], args[2]);
3355              case 4:
3356                return new Ctor(args[0], args[1], args[2], args[3]);
3357              case 5:
3358                return new Ctor(args[0], args[1], args[2], args[3], args[4]);
3359              case 6:
3360                return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5]);
3361              case 7:
3362                return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5], args[6]);
3363            }
3364            var thisBinding = baseCreate(Ctor.prototype), result2 = Ctor.apply(thisBinding, args);
3365            return isObject7(result2) ? result2 : thisBinding;
3366          };
3367        }
3368        function createCurry(func, bitmask, arity) {
3369          var Ctor = createCtor(func);
3370          function wrapper() {
3371            var length = arguments.length, args = Array2(length), index = length, placeholder = getHolder(wrapper);
3372            while (index--) {
3373              args[index] = arguments[index];
3374            }
3375            var holders = length < 3 && args[0] !== placeholder && args[length - 1] !== placeholder ? [] : replaceHolders(args, placeholder);
3376            length -= holders.length;
3377            if (length < arity) {
3378              return createRecurry(func, bitmask, createHybrid, wrapper.placeholder, undefined2, args, holders, undefined2, undefined2, arity - length);
3379            }
3380            var fn = this && this !== root && this instanceof wrapper ? Ctor : func;
3381            return apply(fn, this, args);
3382          }
3383          return wrapper;
3384        }
3385        function createFind(findIndexFunc) {
3386          return function(collection, predicate, fromIndex) {
3387            var iterable = Object2(collection);
3388            if (!isArrayLike(collection)) {
3389              var iteratee2 = getIteratee(predicate, 3);
3390              collection = keys(collection);
3391              predicate = function(key) {
3392                return iteratee2(iterable[key], key, iterable);
3393              };
3394            }
3395            var index = findIndexFunc(collection, predicate, fromIndex);
3396            return index > -1 ? iterable[iteratee2 ? collection[index] : index] : undefined2;
3397          };
3398        }
3399        function createFlow(fromRight) {
3400          return flatRest(function(funcs) {
3401            var length = funcs.length, index = length, prereq = LodashWrapper.prototype.thru;
3402            if (fromRight) {
3403              funcs.reverse();
3404            }
3405            while (index--) {
3406              var func = funcs[index];
3407              if (typeof func != "function") {
3408                throw new TypeError2(FUNC_ERROR_TEXT);
3409              }
3410              if (prereq && !wrapper && getFuncName(func) == "wrapper") {
3411                var wrapper = new LodashWrapper([], true);
3412              }
3413            }
3414            index = wrapper ? index : length;
3415            while (++index < length) {
3416              func = funcs[index];
3417              var funcName = getFuncName(func), data = funcName == "wrapper" ? getData(func) : undefined2;
3418              if (data && isLaziable(data[0]) && data[1] == (WRAP_ARY_FLAG | WRAP_CURRY_FLAG | WRAP_PARTIAL_FLAG | WRAP_REARG_FLAG) && !data[4].length && data[9] == 1) {
3419                wrapper = wrapper[getFuncName(data[0])].apply(wrapper, data[3]);
3420              } else {
3421                wrapper = func.length == 1 && isLaziable(func) ? wrapper[funcName]() : wrapper.thru(func);
3422              }
3423            }
3424            return function() {
3425              var args = arguments, value = args[0];
3426              if (wrapper && args.length == 1 && isArray2(value)) {
3427                return wrapper.plant(value).value();
3428              }
3429              var index2 = 0, result2 = length ? funcs[index2].apply(this, args) : value;
3430              while (++index2 < length) {
3431                result2 = funcs[index2].call(this, result2);
3432              }
3433              return result2;
3434            };
3435          });
3436        }
3437        function createHybrid(func, bitmask, thisArg, partials, holders, partialsRight, holdersRight, argPos, ary2, arity) {
3438          var isAry = bitmask & WRAP_ARY_FLAG, isBind = bitmask & WRAP_BIND_FLAG, isBindKey = bitmask & WRAP_BIND_KEY_FLAG, isCurried = bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG), isFlip = bitmask & WRAP_FLIP_FLAG, Ctor = isBindKey ? undefined2 : createCtor(func);
3439          function wrapper() {
3440            var length = arguments.length, args = Array2(length), index = length;
3441            while (index--) {
3442              args[index] = arguments[index];
3443            }
3444            if (isCurried) {
3445              var placeholder = getHolder(wrapper), holdersCount = countHolders(args, placeholder);
3446            }
3447            if (partials) {
3448              args = composeArgs(args, partials, holders, isCurried);
3449            }
3450            if (partialsRight) {
3451              args = composeArgsRight(args, partialsRight, holdersRight, isCurried);
3452            }
3453            length -= holdersCount;
3454            if (isCurried && length < arity) {
3455              var newHolders = replaceHolders(args, placeholder);
3456              return createRecurry(func, bitmask, createHybrid, wrapper.placeholder, thisArg, args, newHolders, argPos, ary2, arity - length);
3457            }
3458            var thisBinding = isBind ? thisArg : this, fn = isBindKey ? thisBinding[func] : func;
3459            length = args.length;
3460            if (argPos) {
3461              args = reorder(args, argPos);
3462            } else if (isFlip && length > 1) {
3463              args.reverse();
3464            }
3465            if (isAry && ary2 < length) {
3466              args.length = ary2;
3467            }
3468            if (this && this !== root && this instanceof wrapper) {
3469              fn = Ctor || createCtor(fn);
3470            }
3471            return fn.apply(thisBinding, args);
3472          }
3473          return wrapper;
3474        }
3475        function createInverter(setter, toIteratee) {
3476          return function(object, iteratee2) {
3477            return baseInverter(object, setter, toIteratee(iteratee2), {});
3478          };
3479        }
3480        function createMathOperation(operator, defaultValue) {
3481          return function(value, other2) {
3482            var result2;
3483            if (value === undefined2 && other2 === undefined2) {
3484              return defaultValue;
3485            }
3486            if (value !== undefined2) {
3487              result2 = value;
3488            }
3489            if (other2 !== undefined2) {
3490              if (result2 === undefined2) {
3491                return other2;
3492              }
3493              if (typeof value == "string" || typeof other2 == "string") {
3494                value = baseToString(value);
3495                other2 = baseToString(other2);
3496              } else {
3497                value = baseToNumber(value);
3498                other2 = baseToNumber(other2);
3499              }
3500              result2 = operator(value, other2);
3501            }
3502            return result2;
3503          };
3504        }
3505        function createOver(arrayFunc) {
3506          return flatRest(function(iteratees) {
3507            iteratees = arrayMap(iteratees, baseUnary(getIteratee()));
3508            return baseRest(function(args) {
3509              var thisArg = this;
3510              return arrayFunc(iteratees, function(iteratee2) {
3511                return apply(iteratee2, thisArg, args);
3512              });
3513            });
3514          });
3515        }
3516        function createPadding(length, chars) {
3517          chars = chars === undefined2 ? " " : baseToString(chars);
3518          var charsLength = chars.length;
3519          if (charsLength < 2) {
3520            return charsLength ? baseRepeat(chars, length) : chars;
3521          }
3522          var result2 = baseRepeat(chars, nativeCeil(length / stringSize(chars)));
3523          return hasUnicode(chars) ? castSlice(stringToArray(result2), 0, length).join("") : result2.slice(0, length);
3524        }
3525        function createPartial(func, bitmask, thisArg, partials) {
3526          var isBind = bitmask & WRAP_BIND_FLAG, Ctor = createCtor(func);
3527          function wrapper() {
3528            var argsIndex = -1, argsLength = arguments.length, leftIndex = -1, leftLength = partials.length, args = Array2(leftLength + argsLength), fn = this && this !== root && this instanceof wrapper ? Ctor : func;
3529            while (++leftIndex < leftLength) {
3530              args[leftIndex] = partials[leftIndex];
3531            }
3532            while (argsLength--) {
3533              args[leftIndex++] = arguments[++argsIndex];
3534            }
3535            return apply(fn, isBind ? thisArg : this, args);
3536          }
3537          return wrapper;
3538        }
3539        function createRange(fromRight) {
3540          return function(start, end, step) {
3541            if (step && typeof step != "number" && isIterateeCall(start, end, step)) {
3542              end = step = undefined2;
3543            }
3544            start = toFinite(start);
3545            if (end === undefined2) {
3546              end = start;
3547              start = 0;
3548            } else {
3549              end = toFinite(end);
3550            }
3551            step = step === undefined2 ? start < end ? 1 : -1 : toFinite(step);
3552            return baseRange(start, end, step, fromRight);
3553          };
3554        }
3555        function createRelationalOperation(operator) {
3556          return function(value, other2) {
3557            if (!(typeof value == "string" && typeof other2 == "string")) {
3558              value = toNumber(value);
3559              other2 = toNumber(other2);
3560            }
3561            return operator(value, other2);
3562          };
3563        }
3564        function createRecurry(func, bitmask, wrapFunc, placeholder, thisArg, partials, holders, argPos, ary2, arity) {
3565          var isCurry = bitmask & WRAP_CURRY_FLAG, newHolders = isCurry ? holders : undefined2, newHoldersRight = isCurry ? undefined2 : holders, newPartials = isCurry ? partials : undefined2, newPartialsRight = isCurry ? undefined2 : partials;
3566          bitmask |= isCurry ? WRAP_PARTIAL_FLAG : WRAP_PARTIAL_RIGHT_FLAG;
3567          bitmask &= ~(isCurry ? WRAP_PARTIAL_RIGHT_FLAG : WRAP_PARTIAL_FLAG);
3568          if (!(bitmask & WRAP_CURRY_BOUND_FLAG)) {
3569            bitmask &= ~(WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG);
3570          }
3571          var newData = [func, bitmask, thisArg, newPartials, newHolders, newPartialsRight, newHoldersRight, argPos, ary2, arity];
3572          var result2 = wrapFunc.apply(undefined2, newData);
3573          if (isLaziable(func)) {
3574            setData(result2, newData);
3575          }
3576          result2.placeholder = placeholder;
3577          return setWrapToString(result2, func, bitmask);
3578        }
3579        function createRound(methodName) {
3580          var func = Math2[methodName];
3581          return function(number, precision) {
3582            number = toNumber(number);
3583            precision = precision == null ? 0 : nativeMin(toInteger2(precision), 292);
3584            if (precision && nativeIsFinite(number)) {
3585              var pair = (toString(number) + "e").split("e"), value = func(pair[0] + "e" + (+pair[1] + precision));
3586              pair = (toString(value) + "e").split("e");
3587              return +(pair[0] + "e" + (+pair[1] - precision));
3588            }
3589            return func(number);
3590          };
3591        }
3592        var createSet = !(Set2 && 1 / setToArray(new Set2([, -0]))[1] == INFINITY) ? noop : function(values2) {
3593          return new Set2(values2);
3594        };
3595        function createToPairs(keysFunc) {
3596          return function(object) {
3597            var tag2 = getTag(object);
3598            if (tag2 == mapTag) {
3599              return mapToArray(object);
3600            }
3601            if (tag2 == setTag) {
3602              return setToPairs(object);
3603            }
3604            return baseToPairs(object, keysFunc(object));
3605          };
3606        }
3607        function createWrap(func, bitmask, thisArg, partials, holders, argPos, ary2, arity) {
3608          var isBindKey = bitmask & WRAP_BIND_KEY_FLAG;
3609          if (!isBindKey && typeof func != "function") {
3610            throw new TypeError2(FUNC_ERROR_TEXT);
3611          }
3612          var length = partials ? partials.length : 0;
3613          if (!length) {
3614            bitmask &= ~(WRAP_PARTIAL_FLAG | WRAP_PARTIAL_RIGHT_FLAG);
3615            partials = holders = undefined2;
3616          }
3617          ary2 = ary2 === undefined2 ? ary2 : nativeMax(toInteger2(ary2), 0);
3618          arity = arity === undefined2 ? arity : toInteger2(arity);
3619          length -= holders ? holders.length : 0;
3620          if (bitmask & WRAP_PARTIAL_RIGHT_FLAG) {
3621            var partialsRight = partials, holdersRight = holders;
3622            partials = holders = undefined2;
3623          }
3624          var data = isBindKey ? undefined2 : getData(func);
3625          var newData = [func, bitmask, thisArg, partials, holders, partialsRight, holdersRight, argPos, ary2, arity];
3626          if (data) {
3627            mergeData(newData, data);
3628          }
3629          func = newData[0];
3630          bitmask = newData[1];
3631          thisArg = newData[2];
3632          partials = newData[3];
3633          holders = newData[4];
3634          arity = newData[9] = newData[9] === undefined2 ? isBindKey ? 0 : func.length : nativeMax(newData[9] - length, 0);
3635          if (!arity && bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG)) {
3636            bitmask &= ~(WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG);
3637          }
3638          if (!bitmask || bitmask == WRAP_BIND_FLAG) {
3639            var result2 = createBind(func, bitmask, thisArg);
3640          } else if (bitmask == WRAP_CURRY_FLAG || bitmask == WRAP_CURRY_RIGHT_FLAG) {
3641            result2 = createCurry(func, bitmask, arity);
3642          } else if ((bitmask == WRAP_PARTIAL_FLAG || bitmask == (WRAP_BIND_FLAG | WRAP_PARTIAL_FLAG)) && !holders.length) {
3643            result2 = createPartial(func, bitmask, thisArg, partials);
3644          } else {
3645            result2 = createHybrid.apply(undefined2, newData);
3646          }
3647          var setter = data ? baseSetData : setData;
3648          return setWrapToString(setter(result2, newData), func, bitmask);
3649        }
3650        function customDefaultsAssignIn(objValue, srcValue, key, object) {
3651          if (objValue === undefined2 || eq(objValue, objectProto[key]) && !hasOwnProperty.call(object, key)) {
3652            return srcValue;
3653          }
3654          return objValue;
3655        }
3656        function customDefaultsMerge(objValue, srcValue, key, object, source, stack) {
3657          if (isObject7(objValue) && isObject7(srcValue)) {
3658            stack.set(srcValue, objValue);
3659            baseMerge(objValue, srcValue, undefined2, customDefaultsMerge, stack);
3660            stack["delete"](srcValue);
3661          }
3662          return objValue;
3663        }
3664        function customOmitClone(value) {
3665          return isPlainObject(value) ? undefined2 : value;
3666        }
3667        function equalArrays(array, other2, bitmask, customizer, equalFunc, stack) {
3668          var isPartial = bitmask & COMPARE_PARTIAL_FLAG, arrLength = array.length, othLength = other2.length;
3669          if (arrLength != othLength && !(isPartial && othLength > arrLength)) {
3670            return false;
3671          }
3672          var arrStacked = stack.get(array);
3673          var othStacked = stack.get(other2);
3674          if (arrStacked && othStacked) {
3675            return arrStacked == other2 && othStacked == array;
3676          }
3677          var index = -1, result2 = true, seen = bitmask & COMPARE_UNORDERED_FLAG ? new SetCache() : undefined2;
3678          stack.set(array, other2);
3679          stack.set(other2, array);
3680          while (++index < arrLength) {
3681            var arrValue = array[index], othValue = other2[index];
3682            if (customizer) {
3683              var compared = isPartial ? customizer(othValue, arrValue, index, other2, array, stack) : customizer(arrValue, othValue, index, array, other2, stack);
3684            }
3685            if (compared !== undefined2) {
3686              if (compared) {
3687                continue;
3688              }
3689              result2 = false;
3690              break;
3691            }
3692            if (seen) {
3693              if (!arraySome(other2, function(othValue2, othIndex) {
3694                if (!cacheHas(seen, othIndex) && (arrValue === othValue2 || equalFunc(arrValue, othValue2, bitmask, customizer, stack))) {
3695                  return seen.push(othIndex);
3696                }
3697              })) {
3698                result2 = false;
3699                break;
3700              }
3701            } else if (!(arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {
3702              result2 = false;
3703              break;
3704            }
3705          }
3706          stack["delete"](array);
3707          stack["delete"](other2);
3708          return result2;
3709        }
3710        function equalByTag(object, other2, tag2, bitmask, customizer, equalFunc, stack) {
3711          switch (tag2) {
3712            case dataViewTag:
3713              if (object.byteLength != other2.byteLength || object.byteOffset != other2.byteOffset) {
3714                return false;
3715              }
3716              object = object.buffer;
3717              other2 = other2.buffer;
3718            case arrayBufferTag:
3719              if (object.byteLength != other2.byteLength || !equalFunc(new Uint8Array2(object), new Uint8Array2(other2))) {
3720                return false;
3721              }
3722              return true;
3723            case boolTag:
3724            case dateTag:
3725            case numberTag:
3726              return eq(+object, +other2);
3727            case errorTag:
3728              return object.name == other2.name && object.message == other2.message;
3729            case regexpTag:
3730            case stringTag:
3731              return object == other2 + "";
3732            case mapTag:
3733              var convert = mapToArray;
3734            case setTag:
3735              var isPartial = bitmask & COMPARE_PARTIAL_FLAG;
3736              convert || (convert = setToArray);
3737              if (object.size != other2.size && !isPartial) {
3738                return false;
3739              }
3740              var stacked = stack.get(object);
3741              if (stacked) {
3742                return stacked == other2;
3743              }
3744              bitmask |= COMPARE_UNORDERED_FLAG;
3745              stack.set(object, other2);
3746              var result2 = equalArrays(convert(object), convert(other2), bitmask, customizer, equalFunc, stack);
3747              stack["delete"](object);
3748              return result2;
3749            case symbolTag:
3750              if (symbolValueOf) {
3751                return symbolValueOf.call(object) == symbolValueOf.call(other2);
3752              }
3753          }
3754          return false;
3755        }
3756        function equalObjects(object, other2, bitmask, customizer, equalFunc, stack) {
3757          var isPartial = bitmask & COMPARE_PARTIAL_FLAG, objProps = getAllKeys(object), objLength = objProps.length, othProps = getAllKeys(other2), othLength = othProps.length;
3758          if (objLength != othLength && !isPartial) {
3759            return false;
3760          }
3761          var index = objLength;
3762          while (index--) {
3763            var key = objProps[index];
3764            if (!(isPartial ? key in other2 : hasOwnProperty.call(other2, key))) {
3765              return false;
3766            }
3767          }
3768          var objStacked = stack.get(object);
3769          var othStacked = stack.get(other2);
3770          if (objStacked && othStacked) {
3771            return objStacked == other2 && othStacked == object;
3772          }
3773          var result2 = true;
3774          stack.set(object, other2);
3775          stack.set(other2, object);
3776          var skipCtor = isPartial;
3777          while (++index < objLength) {
3778            key = objProps[index];
3779            var objValue = object[key], othValue = other2[key];
3780            if (customizer) {
3781              var compared = isPartial ? customizer(othValue, objValue, key, other2, object, stack) : customizer(objValue, othValue, key, object, other2, stack);
3782            }
3783            if (!(compared === undefined2 ? objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack) : compared)) {
3784              result2 = false;
3785              break;
3786            }
3787            skipCtor || (skipCtor = key == "constructor");
3788          }
3789          if (result2 && !skipCtor) {
3790            var objCtor = object.constructor, othCtor = other2.constructor;
3791            if (objCtor != othCtor && "constructor" in object && "constructor" in other2 && !(typeof objCtor == "function" && objCtor instanceof objCtor && typeof othCtor == "function" && othCtor instanceof othCtor)) {
3792              result2 = false;
3793            }
3794          }
3795          stack["delete"](object);
3796          stack["delete"](other2);
3797          return result2;
3798        }
3799        function flatRest(func) {
3800          return setToString(overRest(func, undefined2, flatten), func + "");
3801        }
3802        function getAllKeys(object) {
3803          return baseGetAllKeys(object, keys, getSymbols);
3804        }
3805        function getAllKeysIn(object) {
3806          return baseGetAllKeys(object, keysIn, getSymbolsIn);
3807        }
3808        var getData = !metaMap ? noop : function(func) {
3809          return metaMap.get(func);
3810        };
3811        function getFuncName(func) {
3812          var result2 = func.name + "", array = realNames[result2], length = hasOwnProperty.call(realNames, result2) ? array.length : 0;
3813          while (length--) {
3814            var data = array[length], otherFunc = data.func;
3815            if (otherFunc == null || otherFunc == func) {
3816              return data.name;
3817            }
3818          }
3819          return result2;
3820        }
3821        function getHolder(func) {
3822          var object = hasOwnProperty.call(lodash, "placeholder") ? lodash : func;
3823          return object.placeholder;
3824        }
3825        function getIteratee() {
3826          var result2 = lodash.iteratee || iteratee;
3827          result2 = result2 === iteratee ? baseIteratee : result2;
3828          return arguments.length ? result2(arguments[0], arguments[1]) : result2;
3829        }
3830        function getMapData(map3, key) {
3831          var data = map3.__data__;
3832          return isKeyable(key) ? data[typeof key == "string" ? "string" : "hash"] : data.map;
3833        }
3834        function getMatchData(object) {
3835          var result2 = keys(object), length = result2.length;
3836          while (length--) {
3837            var key = result2[length], value = object[key];
3838            result2[length] = [key, value, isStrictComparable(value)];
3839          }
3840          return result2;
3841        }
3842        function getNative(object, key) {
3843          var value = getValue2(object, key);
3844          return baseIsNative(value) ? value : undefined2;
3845        }
3846        function getRawTag(value) {
3847          var isOwn = hasOwnProperty.call(value, symToStringTag), tag2 = value[symToStringTag];
3848          try {
3849            value[symToStringTag] = undefined2;
3850            var unmasked = true;
3851          } catch (e) {
3852          }
3853          var result2 = nativeObjectToString.call(value);
3854          if (unmasked) {
3855            if (isOwn) {
3856              value[symToStringTag] = tag2;
3857            } else {
3858              delete value[symToStringTag];
3859            }
3860          }
3861          return result2;
3862        }
3863        var getSymbols = !nativeGetSymbols ? stubArray : function(object) {
3864          if (object == null) {
3865            return [];
3866          }
3867          object = Object2(object);
3868          return arrayFilter(nativeGetSymbols(object), function(symbol) {
3869            return propertyIsEnumerable.call(object, symbol);
3870          });
3871        };
3872        var getSymbolsIn = !nativeGetSymbols ? stubArray : function(object) {
3873          var result2 = [];
3874          while (object) {
3875            arrayPush(result2, getSymbols(object));
3876            object = getPrototype(object);
3877          }
3878          return result2;
3879        };
3880        var getTag = baseGetTag;
3881        if (DataView2 && getTag(new DataView2(new ArrayBuffer(1))) != dataViewTag || Map2 && getTag(new Map2()) != mapTag || Promise2 && getTag(Promise2.resolve()) != promiseTag || Set2 && getTag(new Set2()) != setTag || WeakMap2 && getTag(new WeakMap2()) != weakMapTag) {
3882          getTag = function(value) {
3883            var result2 = baseGetTag(value), Ctor = result2 == objectTag ? value.constructor : undefined2, ctorString = Ctor ? toSource(Ctor) : "";
3884            if (ctorString) {
3885              switch (ctorString) {
3886                case dataViewCtorString:
3887                  return dataViewTag;
3888                case mapCtorString:
3889                  return mapTag;
3890                case promiseCtorString:
3891                  return promiseTag;
3892                case setCtorString:
3893                  return setTag;
3894                case weakMapCtorString:
3895                  return weakMapTag;
3896              }
3897            }
3898            return result2;
3899          };
3900        }
3901        function getView(start, end, transforms) {
3902          var index = -1, length = transforms.length;
3903          while (++index < length) {
3904            var data = transforms[index], size2 = data.size;
3905            switch (data.type) {
3906              case "drop":
3907                start += size2;
3908                break;
3909              case "dropRight":
3910                end -= size2;
3911                break;
3912              case "take":
3913                end = nativeMin(end, start + size2);
3914                break;
3915              case "takeRight":
3916                start = nativeMax(start, end - size2);
3917                break;
3918            }
3919          }
3920          return {
3921            "start": start,
3922            "end": end
3923          };
3924        }
3925        function getWrapDetails(source) {
3926          var match = source.match(reWrapDetails);
3927          return match ? match[1].split(reSplitDetails) : [];
3928        }
3929        function hasPath(object, path2, hasFunc) {
3930          path2 = castPath(path2, object);
3931          var index = -1, length = path2.length, result2 = false;
3932          while (++index < length) {
3933            var key = toKey(path2[index]);
3934            if (!(result2 = object != null && hasFunc(object, key))) {
3935              break;
3936            }
3937            object = object[key];
3938          }
3939          if (result2 || ++index != length) {
3940            return result2;
3941          }
3942          length = object == null ? 0 : object.length;
3943          return !!length && isLength(length) && isIndex(key, length) && (isArray2(object) || isArguments(object));
3944        }
3945        function initCloneArray(array) {
3946          var length = array.length, result2 = new array.constructor(length);
3947          if (length && typeof array[0] == "string" && hasOwnProperty.call(array, "index")) {
3948            result2.index = array.index;
3949            result2.input = array.input;
3950          }
3951          return result2;
3952        }
3953        function initCloneObject(object) {
3954          return typeof object.constructor == "function" && !isPrototype(object) ? baseCreate(getPrototype(object)) : {};
3955        }
3956        function initCloneByTag(object, tag2, isDeep) {
3957          var Ctor = object.constructor;
3958          switch (tag2) {
3959            case arrayBufferTag:
3960              return cloneArrayBuffer(object);
3961            case boolTag:
3962            case dateTag:
3963              return new Ctor(+object);
3964            case dataViewTag:
3965              return cloneDataView(object, isDeep);
3966            case float32Tag:
3967            case float64Tag:
3968            case int8Tag:
3969            case int16Tag:
3970            case int32Tag:
3971            case uint8Tag:
3972            case uint8ClampedTag:
3973            case uint16Tag:
3974            case uint32Tag:
3975              return cloneTypedArray(object, isDeep);
3976            case mapTag:
3977              return new Ctor();
3978            case numberTag:
3979            case stringTag:
3980              return new Ctor(object);
3981            case regexpTag:
3982              return cloneRegExp(object);
3983            case setTag:
3984              return new Ctor();
3985            case symbolTag:
3986              return cloneSymbol(object);
3987          }
3988        }
3989        function insertWrapDetails(source, details) {
3990          var length = details.length;
3991          if (!length) {
3992            return source;
3993          }
3994          var lastIndex = length - 1;
3995          details[lastIndex] = (length > 1 ? "& " : "") + details[lastIndex];
3996          details = details.join(length > 2 ? ", " : " ");
3997          return source.replace(reWrapComment, "{\n/* [wrapped with " + details + "] */\n");
3998        }
3999        function isFlattenable(value) {
4000          return isArray2(value) || isArguments(value) || !!(spreadableSymbol && value && value[spreadableSymbol]);
4001        }
4002        function isIndex(value, length) {
4003          var type = typeof value;
4004          length = length == null ? MAX_SAFE_INTEGER : length;
4005          return !!length && (type == "number" || type != "symbol" && reIsUint.test(value)) && value > -1 && value % 1 == 0 && value < length;
4006        }
4007        function isIterateeCall(value, index, object) {
4008          if (!isObject7(object)) {
4009            return false;
4010          }
4011          var type = typeof index;
4012          if (type == "number" ? isArrayLike(object) && isIndex(index, object.length) : type == "string" && index in object) {
4013            return eq(object[index], value);
4014          }
4015          return false;
4016        }
4017        function isKey(value, object) {
4018          if (isArray2(value)) {
4019            return false;
4020          }
4021          var type = typeof value;
4022          if (type == "number" || type == "symbol" || type == "boolean" || value == null || isSymbol(value)) {
4023            return true;
4024          }
4025          return reIsPlainProp.test(value) || !reIsDeepProp.test(value) || object != null && value in Object2(object);
4026        }
4027        function isKeyable(value) {
4028          var type = typeof value;
4029          return type == "string" || type == "number" || type == "symbol" || type == "boolean" ? value !== "__proto__" : value === null;
4030        }
4031        function isLaziable(func) {
4032          var funcName = getFuncName(func), other2 = lodash[funcName];
4033          if (typeof other2 != "function" || !(funcName in LazyWrapper.prototype)) {
4034            return false;
4035          }
4036          if (func === other2) {
4037            return true;
4038          }
4039          var data = getData(other2);
4040          return !!data && func === data[0];
4041        }
4042        function isMasked(func) {
4043          return !!maskSrcKey && maskSrcKey in func;
4044        }
4045        var isMaskable = coreJsData ? isFunction3 : stubFalse;
4046        function isPrototype(value) {
4047          var Ctor = value && value.constructor, proto = typeof Ctor == "function" && Ctor.prototype || objectProto;
4048          return value === proto;
4049        }
4050        function isStrictComparable(value) {
4051          return value === value && !isObject7(value);
4052        }
4053        function matchesStrictComparable(key, srcValue) {
4054          return function(object) {
4055            if (object == null) {
4056              return false;
4057            }
4058            return object[key] === srcValue && (srcValue !== undefined2 || key in Object2(object));
4059          };
4060        }
4061        function memoizeCapped(func) {
4062          var result2 = memoize(func, function(key) {
4063            if (cache.size === MAX_MEMOIZE_SIZE) {
4064              cache.clear();
4065            }
4066            return key;
4067          });
4068          var cache = result2.cache;
4069          return result2;
4070        }
4071        function mergeData(data, source) {
4072          var bitmask = data[1], srcBitmask = source[1], newBitmask = bitmask | srcBitmask, isCommon = newBitmask < (WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG | WRAP_ARY_FLAG);
4073          var isCombo = srcBitmask == WRAP_ARY_FLAG && bitmask == WRAP_CURRY_FLAG || srcBitmask == WRAP_ARY_FLAG && bitmask == WRAP_REARG_FLAG && data[7].length <= source[8] || srcBitmask == (WRAP_ARY_FLAG | WRAP_REARG_FLAG) && source[7].length <= source[8] && bitmask == WRAP_CURRY_FLAG;
4074          if (!(isCommon || isCombo)) {
4075            return data;
4076          }
4077          if (srcBitmask & WRAP_BIND_FLAG) {
4078            data[2] = source[2];
4079            newBitmask |= bitmask & WRAP_BIND_FLAG ? 0 : WRAP_CURRY_BOUND_FLAG;
4080          }
4081          var value = source[3];
4082          if (value) {
4083            var partials = data[3];
4084            data[3] = partials ? composeArgs(partials, value, source[4]) : value;
4085            data[4] = partials ? replaceHolders(data[3], PLACEHOLDER) : source[4];
4086          }
4087          value = source[5];
4088          if (value) {
4089            partials = data[5];
4090            data[5] = partials ? composeArgsRight(partials, value, source[6]) : value;
4091            data[6] = partials ? replaceHolders(data[5], PLACEHOLDER) : source[6];
4092          }
4093          value = source[7];
4094          if (value) {
4095            data[7] = value;
4096          }
4097          if (srcBitmask & WRAP_ARY_FLAG) {
4098            data[8] = data[8] == null ? source[8] : nativeMin(data[8], source[8]);
4099          }
4100          if (data[9] == null) {
4101            data[9] = source[9];
4102          }
4103          data[0] = source[0];
4104          data[1] = newBitmask;
4105          return data;
4106        }
4107        function nativeKeysIn(object) {
4108          var result2 = [];
4109          if (object != null) {
4110            for (var key in Object2(object)) {
4111              result2.push(key);
4112            }
4113          }
4114          return result2;
4115        }
4116        function objectToString(value) {
4117          return nativeObjectToString.call(value);
4118        }
4119        function overRest(func, start, transform2) {
4120          start = nativeMax(start === undefined2 ? func.length - 1 : start, 0);
4121          return function() {
4122            var args = arguments, index = -1, length = nativeMax(args.length - start, 0), array = Array2(length);
4123            while (++index < length) {
4124              array[index] = args[start + index];
4125            }
4126            index = -1;
4127            var otherArgs = Array2(start + 1);
4128            while (++index < start) {
4129              otherArgs[index] = args[index];
4130            }
4131            otherArgs[start] = transform2(array);
4132            return apply(func, this, otherArgs);
4133          };
4134        }
4135        function parent(object, path2) {
4136          return path2.length < 2 ? object : baseGet(object, baseSlice(path2, 0, -1));
4137        }
4138        function reorder(array, indexes) {
4139          var arrLength = array.length, length = nativeMin(indexes.length, arrLength), oldArray = copyArray(array);
4140          while (length--) {
4141            var index = indexes[length];
4142            array[length] = isIndex(index, arrLength) ? oldArray[index] : undefined2;
4143          }
4144          return array;
4145        }
4146        function safeGet(object, key) {
4147          if (key === "constructor" && typeof object[key] === "function") {
4148            return;
4149          }
4150          if (key == "__proto__") {
4151            return;
4152          }
4153          return object[key];
4154        }
4155        var setData = shortOut(baseSetData);
4156        var setTimeout2 = ctxSetTimeout || function(func, wait) {
4157          return root.setTimeout(func, wait);
4158        };
4159        var setToString = shortOut(baseSetToString);
4160        function setWrapToString(wrapper, reference, bitmask) {
4161          var source = reference + "";
4162          return setToString(wrapper, insertWrapDetails(source, updateWrapDetails(getWrapDetails(source), bitmask)));
4163        }
4164        function shortOut(func) {
4165          var count = 0, lastCalled = 0;
4166          return function() {
4167            var stamp = nativeNow(), remaining = HOT_SPAN - (stamp - lastCalled);
4168            lastCalled = stamp;
4169            if (remaining > 0) {
4170              if (++count >= HOT_COUNT) {
4171                return arguments[0];
4172              }
4173            } else {
4174              count = 0;
4175            }
4176            return func.apply(undefined2, arguments);
4177          };
4178        }
4179        function shuffleSelf(array, size2) {
4180          var index = -1, length = array.length, lastIndex = length - 1;
4181          size2 = size2 === undefined2 ? length : size2;
4182          while (++index < size2) {
4183            var rand = baseRandom(index, lastIndex), value = array[rand];
4184            array[rand] = array[index];
4185            array[index] = value;
4186          }
4187          array.length = size2;
4188          return array;
4189        }
4190        var stringToPath = memoizeCapped(function(string) {
4191          var result2 = [];
4192          if (string.charCodeAt(0) === 46) {
4193            result2.push("");
4194          }
4195          string.replace(rePropName, function(match, number, quote, subString) {
4196            result2.push(quote ? subString.replace(reEscapeChar, "$1") : number || match);
4197          });
4198          return result2;
4199        });
4200        function toKey(value) {
4201          if (typeof value == "string" || isSymbol(value)) {
4202            return value;
4203          }
4204          var result2 = value + "";
4205          return result2 == "0" && 1 / value == -INFINITY ? "-0" : result2;
4206        }
4207        function toSource(func) {
4208          if (func != null) {
4209            try {
4210              return funcToString.call(func);
4211            } catch (e) {
4212            }
4213            try {
4214              return func + "";
4215            } catch (e) {
4216            }
4217          }
4218          return "";
4219        }
4220        function updateWrapDetails(details, bitmask) {
4221          arrayEach(wrapFlags, function(pair) {
4222            var value = "_." + pair[0];
4223            if (bitmask & pair[1] && !arrayIncludes(details, value)) {
4224              details.push(value);
4225            }
4226          });
4227          return details.sort();
4228        }
4229        function wrapperClone(wrapper) {
4230          if (wrapper instanceof LazyWrapper) {
4231            return wrapper.clone();
4232          }
4233          var result2 = new LodashWrapper(wrapper.__wrapped__, wrapper.__chain__);
4234          result2.__actions__ = copyArray(wrapper.__actions__);
4235          result2.__index__ = wrapper.__index__;
4236          result2.__values__ = wrapper.__values__;
4237          return result2;
4238        }
4239        function chunk(array, size2, guard) {
4240          if (guard ? isIterateeCall(array, size2, guard) : size2 === undefined2) {
4241            size2 = 1;
4242          } else {
4243            size2 = nativeMax(toInteger2(size2), 0);
4244          }
4245          var length = array == null ? 0 : array.length;
4246          if (!length || size2 < 1) {
4247            return [];
4248          }
4249          var index = 0, resIndex = 0, result2 = Array2(nativeCeil(length / size2));
4250          while (index < length) {
4251            result2[resIndex++] = baseSlice(array, index, index += size2);
4252          }
4253          return result2;
4254        }
4255        function compact(array) {
4256          var index = -1, length = array == null ? 0 : array.length, resIndex = 0, result2 = [];
4257          while (++index < length) {
4258            var value = array[index];
4259            if (value) {
4260              result2[resIndex++] = value;
4261            }
4262          }
4263          return result2;
4264        }
4265        function concat2() {
4266          var length = arguments.length;
4267          if (!length) {
4268            return [];
4269          }
4270          var args = Array2(length - 1), array = arguments[0], index = length;
4271          while (index--) {
4272            args[index - 1] = arguments[index];
4273          }
4274          return arrayPush(isArray2(array) ? copyArray(array) : [array], baseFlatten(args, 1));
4275        }
4276        var difference = baseRest(function(array, values2) {
4277          return isArrayLikeObject(array) ? baseDifference(array, baseFlatten(values2, 1, isArrayLikeObject, true)) : [];
4278        });
4279        var differenceBy = baseRest(function(array, values2) {
4280          var iteratee2 = last(values2);
4281          if (isArrayLikeObject(iteratee2)) {
4282            iteratee2 = undefined2;
4283          }
4284          return isArrayLikeObject(array) ? baseDifference(array, baseFlatten(values2, 1, isArrayLikeObject, true), getIteratee(iteratee2, 2)) : [];
4285        });
4286        var differenceWith = baseRest(function(array, values2) {
4287          var comparator = last(values2);
4288          if (isArrayLikeObject(comparator)) {
4289            comparator = undefined2;
4290          }
4291          return isArrayLikeObject(array) ? baseDifference(array, baseFlatten(values2, 1, isArrayLikeObject, true), undefined2, comparator) : [];
4292        });
4293        function drop(array, n, guard) {
4294          var length = array == null ? 0 : array.length;
4295          if (!length) {
4296            return [];
4297          }
4298          n = guard || n === undefined2 ? 1 : toInteger2(n);
4299          return baseSlice(array, n < 0 ? 0 : n, length);
4300        }
4301        function dropRight(array, n, guard) {
4302          var length = array == null ? 0 : array.length;
4303          if (!length) {
4304            return [];
4305          }
4306          n = guard || n === undefined2 ? 1 : toInteger2(n);
4307          n = length - n;
4308          return baseSlice(array, 0, n < 0 ? 0 : n);
4309        }
4310        function dropRightWhile(array, predicate) {
4311          return array && array.length ? baseWhile(array, getIteratee(predicate, 3), true, true) : [];
4312        }
4313        function dropWhile(array, predicate) {
4314          return array && array.length ? baseWhile(array, getIteratee(predicate, 3), true) : [];
4315        }
4316        function fill(array, value, start, end) {
4317          var length = array == null ? 0 : array.length;
4318          if (!length) {
4319            return [];
4320          }
4321          if (start && typeof start != "number" && isIterateeCall(array, value, start)) {
4322            start = 0;
4323            end = length;
4324          }
4325          return baseFill(array, value, start, end);
4326        }
4327        function findIndex(array, predicate, fromIndex) {
4328          var length = array == null ? 0 : array.length;
4329          if (!length) {
4330            return -1;
4331          }
4332          var index = fromIndex == null ? 0 : toInteger2(fromIndex);
4333          if (index < 0) {
4334            index = nativeMax(length + index, 0);
4335          }
4336          return baseFindIndex(array, getIteratee(predicate, 3), index);
4337        }
4338        function findLastIndex(array, predicate, fromIndex) {
4339          var length = array == null ? 0 : array.length;
4340          if (!length) {
4341            return -1;
4342          }
4343          var index = length - 1;
4344          if (fromIndex !== undefined2) {
4345            index = toInteger2(fromIndex);
4346            index = fromIndex < 0 ? nativeMax(length + index, 0) : nativeMin(index, length - 1);
4347          }
4348          return baseFindIndex(array, getIteratee(predicate, 3), index, true);
4349        }
4350        function flatten(array) {
4351          var length = array == null ? 0 : array.length;
4352          return length ? baseFlatten(array, 1) : [];
4353        }
4354        function flattenDeep(array) {
4355          var length = array == null ? 0 : array.length;
4356          return length ? baseFlatten(array, INFINITY) : [];
4357        }
4358        function flattenDepth(array, depth) {
4359          var length = array == null ? 0 : array.length;
4360          if (!length) {
4361            return [];
4362          }
4363          depth = depth === undefined2 ? 1 : toInteger2(depth);
4364          return baseFlatten(array, depth);
4365        }
4366        function fromPairs(pairs) {
4367          var index = -1, length = pairs == null ? 0 : pairs.length, result2 = {};
4368          while (++index < length) {
4369            var pair = pairs[index];
4370            result2[pair[0]] = pair[1];
4371          }
4372          return result2;
4373        }
4374        function head(array) {
4375          return array && array.length ? array[0] : undefined2;
4376        }
4377        function indexOf(array, value, fromIndex) {
4378          var length = array == null ? 0 : array.length;
4379          if (!length) {
4380            return -1;
4381          }
4382          var index = fromIndex == null ? 0 : toInteger2(fromIndex);
4383          if (index < 0) {
4384            index = nativeMax(length + index, 0);
4385          }
4386          return baseIndexOf(array, value, index);
4387        }
4388        function initial(array) {
4389          var length = array == null ? 0 : array.length;
4390          return length ? baseSlice(array, 0, -1) : [];
4391        }
4392        var intersection = baseRest(function(arrays) {
4393          var mapped = arrayMap(arrays, castArrayLikeObject);
4394          return mapped.length && mapped[0] === arrays[0] ? baseIntersection(mapped) : [];
4395        });
4396        var intersectionBy = baseRest(function(arrays) {
4397          var iteratee2 = last(arrays), mapped = arrayMap(arrays, castArrayLikeObject);
4398          if (iteratee2 === last(mapped)) {
4399            iteratee2 = undefined2;
4400          } else {
4401            mapped.pop();
4402          }
4403          return mapped.length && mapped[0] === arrays[0] ? baseIntersection(mapped, getIteratee(iteratee2, 2)) : [];
4404        });
4405        var intersectionWith = baseRest(function(arrays) {
4406          var comparator = last(arrays), mapped = arrayMap(arrays, castArrayLikeObject);
4407          comparator = typeof comparator == "function" ? comparator : undefined2;
4408          if (comparator) {
4409            mapped.pop();
4410          }
4411          return mapped.length && mapped[0] === arrays[0] ? baseIntersection(mapped, undefined2, comparator) : [];
4412        });
4413        function join(array, separator) {
4414          return array == null ? "" : nativeJoin.call(array, separator);
4415        }
4416        function last(array) {
4417          var length = array == null ? 0 : array.length;
4418          return length ? array[length - 1] : undefined2;
4419        }
4420        function lastIndexOf(array, value, fromIndex) {
4421          var length = array == null ? 0 : array.length;
4422          if (!length) {
4423            return -1;
4424          }
4425          var index = length;
4426          if (fromIndex !== undefined2) {
4427            index = toInteger2(fromIndex);
4428            index = index < 0 ? nativeMax(length + index, 0) : nativeMin(index, length - 1);
4429          }
4430          return value === value ? strictLastIndexOf(array, value, index) : baseFindIndex(array, baseIsNaN, index, true);
4431        }
4432        function nth(array, n) {
4433          return array && array.length ? baseNth(array, toInteger2(n)) : undefined2;
4434        }
4435        var pull = baseRest(pullAll);
4436        function pullAll(array, values2) {
4437          return array && array.length && values2 && values2.length ? basePullAll(array, values2) : array;
4438        }
4439        function pullAllBy(array, values2, iteratee2) {
4440          return array && array.length && values2 && values2.length ? basePullAll(array, values2, getIteratee(iteratee2, 2)) : array;
4441        }
4442        function pullAllWith(array, values2, comparator) {
4443          return array && array.length && values2 && values2.length ? basePullAll(array, values2, undefined2, comparator) : array;
4444        }
4445        var pullAt = flatRest(function(array, indexes) {
4446          var length = array == null ? 0 : array.length, result2 = baseAt(array, indexes);
4447          basePullAt(array, arrayMap(indexes, function(index) {
4448            return isIndex(index, length) ? +index : index;
4449          }).sort(compareAscending));
4450          return result2;
4451        });
4452        function remove(array, predicate) {
4453          var result2 = [];
4454          if (!(array && array.length)) {
4455            return result2;
4456          }
4457          var index = -1, indexes = [], length = array.length;
4458          predicate = getIteratee(predicate, 3);
4459          while (++index < length) {
4460            var value = array[index];
4461            if (predicate(value, index, array)) {
4462              result2.push(value);
4463              indexes.push(index);
4464            }
4465          }
4466          basePullAt(array, indexes);
4467          return result2;
4468        }
4469        function reverse(array) {
4470          return array == null ? array : nativeReverse.call(array);
4471        }
4472        function slice(array, start, end) {
4473          var length = array == null ? 0 : array.length;
4474          if (!length) {
4475            return [];
4476          }
4477          if (end && typeof end != "number" && isIterateeCall(array, start, end)) {
4478            start = 0;
4479            end = length;
4480          } else {
4481            start = start == null ? 0 : toInteger2(start);
4482            end = end === undefined2 ? length : toInteger2(end);
4483          }
4484          return baseSlice(array, start, end);
4485        }
4486        function sortedIndex(array, value) {
4487          return baseSortedIndex(array, value);
4488        }
4489        function sortedIndexBy(array, value, iteratee2) {
4490          return baseSortedIndexBy(array, value, getIteratee(iteratee2, 2));
4491        }
4492        function sortedIndexOf(array, value) {
4493          var length = array == null ? 0 : array.length;
4494          if (length) {
4495            var index = baseSortedIndex(array, value);
4496            if (index < length && eq(array[index], value)) {
4497              return index;
4498            }
4499          }
4500          return -1;
4501        }
4502        function sortedLastIndex(array, value) {
4503          return baseSortedIndex(array, value, true);
4504        }
4505        function sortedLastIndexBy(array, value, iteratee2) {
4506          return baseSortedIndexBy(array, value, getIteratee(iteratee2, 2), true);
4507        }
4508        function sortedLastIndexOf(array, value) {
4509          var length = array == null ? 0 : array.length;
4510          if (length) {
4511            var index = baseSortedIndex(array, value, true) - 1;
4512            if (eq(array[index], value)) {
4513              return index;
4514            }
4515          }
4516          return -1;
4517        }
4518        function sortedUniq(array) {
4519          return array && array.length ? baseSortedUniq(array) : [];
4520        }
4521        function sortedUniqBy(array, iteratee2) {
4522          return array && array.length ? baseSortedUniq(array, getIteratee(iteratee2, 2)) : [];
4523        }
4524        function tail(array) {
4525          var length = array == null ? 0 : array.length;
4526          return length ? baseSlice(array, 1, length) : [];
4527        }
4528        function take2(array, n, guard) {
4529          if (!(array && array.length)) {
4530            return [];
4531          }
4532          n = guard || n === undefined2 ? 1 : toInteger2(n);
4533          return baseSlice(array, 0, n < 0 ? 0 : n);
4534        }
4535        function takeRight(array, n, guard) {
4536          var length = array == null ? 0 : array.length;
4537          if (!length) {
4538            return [];
4539          }
4540          n = guard || n === undefined2 ? 1 : toInteger2(n);
4541          n = length - n;
4542          return baseSlice(array, n < 0 ? 0 : n, length);
4543        }
4544        function takeRightWhile(array, predicate) {
4545          return array && array.length ? baseWhile(array, getIteratee(predicate, 3), false, true) : [];
4546        }
4547        function takeWhile(array, predicate) {
4548          return array && array.length ? baseWhile(array, getIteratee(predicate, 3)) : [];
4549        }
4550        var union = baseRest(function(arrays) {
4551          return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true));
4552        });
4553        var unionBy = baseRest(function(arrays) {
4554          var iteratee2 = last(arrays);
4555          if (isArrayLikeObject(iteratee2)) {
4556            iteratee2 = undefined2;
4557          }
4558          return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true), getIteratee(iteratee2, 2));
4559        });
4560        var unionWith = baseRest(function(arrays) {
4561          var comparator = last(arrays);
4562          comparator = typeof comparator == "function" ? comparator : undefined2;
4563          return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true), undefined2, comparator);
4564        });
4565        function uniq(array) {
4566          return array && array.length ? baseUniq(array) : [];
4567        }
4568        function uniqBy(array, iteratee2) {
4569          return array && array.length ? baseUniq(array, getIteratee(iteratee2, 2)) : [];
4570        }
4571        function uniqWith(array, comparator) {
4572          comparator = typeof comparator == "function" ? comparator : undefined2;
4573          return array && array.length ? baseUniq(array, undefined2, comparator) : [];
4574        }
4575        function unzip(array) {
4576          if (!(array && array.length)) {
4577            return [];
4578          }
4579          var length = 0;
4580          array = arrayFilter(array, function(group) {
4581            if (isArrayLikeObject(group)) {
4582              length = nativeMax(group.length, length);
4583              return true;
4584            }
4585          });
4586          return baseTimes(length, function(index) {
4587            return arrayMap(array, baseProperty(index));
4588          });
4589        }
4590        function unzipWith(array, iteratee2) {
4591          if (!(array && array.length)) {
4592            return [];
4593          }
4594          var result2 = unzip(array);
4595          if (iteratee2 == null) {
4596            return result2;
4597          }
4598          return arrayMap(result2, function(group) {
4599            return apply(iteratee2, undefined2, group);
4600          });
4601        }
4602        var without = baseRest(function(array, values2) {
4603          return isArrayLikeObject(array) ? baseDifference(array, values2) : [];
4604        });
4605        var xor = baseRest(function(arrays) {
4606          return baseXor(arrayFilter(arrays, isArrayLikeObject));
4607        });
4608        var xorBy = baseRest(function(arrays) {
4609          var iteratee2 = last(arrays);
4610          if (isArrayLikeObject(iteratee2)) {
4611            iteratee2 = undefined2;
4612          }
4613          return baseXor(arrayFilter(arrays, isArrayLikeObject), getIteratee(iteratee2, 2));
4614        });
4615        var xorWith = baseRest(function(arrays) {
4616          var comparator = last(arrays);
4617          comparator = typeof comparator == "function" ? comparator : undefined2;
4618          return baseXor(arrayFilter(arrays, isArrayLikeObject), undefined2, comparator);
4619        });
4620        var zip = baseRest(unzip);
4621        function zipObject(props, values2) {
4622          return baseZipObject(props || [], values2 || [], assignValue);
4623        }
4624        function zipObjectDeep(props, values2) {
4625          return baseZipObject(props || [], values2 || [], baseSet);
4626        }
4627        var zipWith = baseRest(function(arrays) {
4628          var length = arrays.length, iteratee2 = length > 1 ? arrays[length - 1] : undefined2;
4629          iteratee2 = typeof iteratee2 == "function" ? (arrays.pop(), iteratee2) : undefined2;
4630          return unzipWith(arrays, iteratee2);
4631        });
4632        function chain(value) {
4633          var result2 = lodash(value);
4634          result2.__chain__ = true;
4635          return result2;
4636        }
4637        function tap2(value, interceptor) {
4638          interceptor(value);
4639          return value;
4640        }
4641        function thru(value, interceptor) {
4642          return interceptor(value);
4643        }
4644        var wrapperAt = flatRest(function(paths) {
4645          var length = paths.length, start = length ? paths[0] : 0, value = this.__wrapped__, interceptor = function(object) {
4646            return baseAt(object, paths);
4647          };
4648          if (length > 1 || this.__actions__.length || !(value instanceof LazyWrapper) || !isIndex(start)) {
4649            return this.thru(interceptor);
4650          }
4651          value = value.slice(start, +start + (length ? 1 : 0));
4652          value.__actions__.push({
4653            "func": thru,
4654            "args": [interceptor],
4655            "thisArg": undefined2
4656          });
4657          return new LodashWrapper(value, this.__chain__).thru(function(array) {
4658            if (length && !array.length) {
4659              array.push(undefined2);
4660            }
4661            return array;
4662          });
4663        });
4664        function wrapperChain() {
4665          return chain(this);
4666        }
4667        function wrapperCommit() {
4668          return new LodashWrapper(this.value(), this.__chain__);
4669        }
4670        function wrapperNext() {
4671          if (this.__values__ === undefined2) {
4672            this.__values__ = toArray(this.value());
4673          }
4674          var done = this.__index__ >= this.__values__.length, value = done ? undefined2 : this.__values__[this.__index__++];
4675          return {
4676            "done": done,
4677            "value": value
4678          };
4679        }
4680        function wrapperToIterator() {
4681          return this;
4682        }
4683        function wrapperPlant(value) {
4684          var result2, parent2 = this;
4685          while (parent2 instanceof baseLodash) {
4686            var clone2 = wrapperClone(parent2);
4687            clone2.__index__ = 0;
4688            clone2.__values__ = undefined2;
4689            if (result2) {
4690              previous.__wrapped__ = clone2;
4691            } else {
4692              result2 = clone2;
4693            }
4694            var previous = clone2;
4695            parent2 = parent2.__wrapped__;
4696          }
4697          previous.__wrapped__ = value;
4698          return result2;
4699        }
4700        function wrapperReverse() {
4701          var value = this.__wrapped__;
4702          if (value instanceof LazyWrapper) {
4703            var wrapped = value;
4704            if (this.__actions__.length) {
4705              wrapped = new LazyWrapper(this);
4706            }
4707            wrapped = wrapped.reverse();
4708            wrapped.__actions__.push({
4709              "func": thru,
4710              "args": [reverse],
4711              "thisArg": undefined2
4712            });
4713            return new LodashWrapper(wrapped, this.__chain__);
4714          }
4715          return this.thru(reverse);
4716        }
4717        function wrapperValue() {
4718          return baseWrapperValue(this.__wrapped__, this.__actions__);
4719        }
4720        var countBy = createAggregator(function(result2, value, key) {
4721          if (hasOwnProperty.call(result2, key)) {
4722            ++result2[key];
4723          } else {
4724            baseAssignValue(result2, key, 1);
4725          }
4726        });
4727        function every(collection, predicate, guard) {
4728          var func = isArray2(collection) ? arrayEvery : baseEvery;
4729          if (guard && isIterateeCall(collection, predicate, guard)) {
4730            predicate = undefined2;
4731          }
4732          return func(collection, getIteratee(predicate, 3));
4733        }
4734        function filter2(collection, predicate) {
4735          var func = isArray2(collection) ? arrayFilter : baseFilter;
4736          return func(collection, getIteratee(predicate, 3));
4737        }
4738        var find = createFind(findIndex);
4739        var findLast = createFind(findLastIndex);
4740        function flatMap(collection, iteratee2) {
4741          return baseFlatten(map2(collection, iteratee2), 1);
4742        }
4743        function flatMapDeep(collection, iteratee2) {
4744          return baseFlatten(map2(collection, iteratee2), INFINITY);
4745        }
4746        function flatMapDepth(collection, iteratee2, depth) {
4747          depth = depth === undefined2 ? 1 : toInteger2(depth);
4748          return baseFlatten(map2(collection, iteratee2), depth);
4749        }
4750        function forEach(collection, iteratee2) {
4751          var func = isArray2(collection) ? arrayEach : baseEach;
4752          return func(collection, getIteratee(iteratee2, 3));
4753        }
4754        function forEachRight(collection, iteratee2) {
4755          var func = isArray2(collection) ? arrayEachRight : baseEachRight;
4756          return func(collection, getIteratee(iteratee2, 3));
4757        }
4758        var groupBy = createAggregator(function(result2, value, key) {
4759          if (hasOwnProperty.call(result2, key)) {
4760            result2[key].push(value);
4761          } else {
4762            baseAssignValue(result2, key, [value]);
4763          }
4764        });
4765        function includes(collection, value, fromIndex, guard) {
4766          collection = isArrayLike(collection) ? collection : values(collection);
4767          fromIndex = fromIndex && !guard ? toInteger2(fromIndex) : 0;
4768          var length = collection.length;
4769          if (fromIndex < 0) {
4770            fromIndex = nativeMax(length + fromIndex, 0);
4771          }
4772          return isString2(collection) ? fromIndex <= length && collection.indexOf(value, fromIndex) > -1 : !!length && baseIndexOf(collection, value, fromIndex) > -1;
4773        }
4774        var invokeMap = baseRest(function(collection, path2, args) {
4775          var index = -1, isFunc = typeof path2 == "function", result2 = isArrayLike(collection) ? Array2(collection.length) : [];
4776          baseEach(collection, function(value) {
4777            result2[++index] = isFunc ? apply(path2, value, args) : baseInvoke(value, path2, args);
4778          });
4779          return result2;
4780        });
4781        var keyBy = createAggregator(function(result2, value, key) {
4782          baseAssignValue(result2, key, value);
4783        });
4784        function map2(collection, iteratee2) {
4785          var func = isArray2(collection) ? arrayMap : baseMap;
4786          return func(collection, getIteratee(iteratee2, 3));
4787        }
4788        function orderBy(collection, iteratees, orders, guard) {
4789          if (collection == null) {
4790            return [];
4791          }
4792          if (!isArray2(iteratees)) {
4793            iteratees = iteratees == null ? [] : [iteratees];
4794          }
4795          orders = guard ? undefined2 : orders;
4796          if (!isArray2(orders)) {
4797            orders = orders == null ? [] : [orders];
4798          }
4799          return baseOrderBy(collection, iteratees, orders);
4800        }
4801        var partition = createAggregator(function(result2, value, key) {
4802          result2[key ? 0 : 1].push(value);
4803        }, function() {
4804          return [[], []];
4805        });
4806        function reduce(collection, iteratee2, accumulator) {
4807          var func = isArray2(collection) ? arrayReduce : baseReduce, initAccum = arguments.length < 3;
4808          return func(collection, getIteratee(iteratee2, 4), accumulator, initAccum, baseEach);
4809        }
4810        function reduceRight(collection, iteratee2, accumulator) {
4811          var func = isArray2(collection) ? arrayReduceRight : baseReduce, initAccum = arguments.length < 3;
4812          return func(collection, getIteratee(iteratee2, 4), accumulator, initAccum, baseEachRight);
4813        }
4814        function reject(collection, predicate) {
4815          var func = isArray2(collection) ? arrayFilter : baseFilter;
4816          return func(collection, negate(getIteratee(predicate, 3)));
4817        }
4818        function sample(collection) {
4819          var func = isArray2(collection) ? arraySample : baseSample;
4820          return func(collection);
4821        }
4822        function sampleSize(collection, n, guard) {
4823          if (guard ? isIterateeCall(collection, n, guard) : n === undefined2) {
4824            n = 1;
4825          } else {
4826            n = toInteger2(n);
4827          }
4828          var func = isArray2(collection) ? arraySampleSize : baseSampleSize;
4829          return func(collection, n);
4830        }
4831        function shuffle(collection) {
4832          var func = isArray2(collection) ? arrayShuffle : baseShuffle;
4833          return func(collection);
4834        }
4835        function size(collection) {
4836          if (collection == null) {
4837            return 0;
4838          }
4839          if (isArrayLike(collection)) {
4840            return isString2(collection) ? stringSize(collection) : collection.length;
4841          }
4842          var tag2 = getTag(collection);
4843          if (tag2 == mapTag || tag2 == setTag) {
4844            return collection.size;
4845          }
4846          return baseKeys(collection).length;
4847        }
4848        function some(collection, predicate, guard) {
4849          var func = isArray2(collection) ? arraySome : baseSome;
4850          if (guard && isIterateeCall(collection, predicate, guard)) {
4851            predicate = undefined2;
4852          }
4853          return func(collection, getIteratee(predicate, 3));
4854        }
4855        var sortBy = baseRest(function(collection, iteratees) {
4856          if (collection == null) {
4857            return [];
4858          }
4859          var length = iteratees.length;
4860          if (length > 1 && isIterateeCall(collection, iteratees[0], iteratees[1])) {
4861            iteratees = [];
4862          } else if (length > 2 && isIterateeCall(iteratees[0], iteratees[1], iteratees[2])) {
4863            iteratees = [iteratees[0]];
4864          }
4865          return baseOrderBy(collection, baseFlatten(iteratees, 1), []);
4866        });
4867        var now2 = ctxNow || function() {
4868          return root.Date.now();
4869        };
4870        function after(n, func) {
4871          if (typeof func != "function") {
4872            throw new TypeError2(FUNC_ERROR_TEXT);
4873          }
4874          n = toInteger2(n);
4875          return function() {
4876            if (--n < 1) {
4877              return func.apply(this, arguments);
4878            }
4879          };
4880        }
4881        function ary(func, n, guard) {
4882          n = guard ? undefined2 : n;
4883          n = func && n == null ? func.length : n;
4884          return createWrap(func, WRAP_ARY_FLAG, undefined2, undefined2, undefined2, undefined2, n);
4885        }
4886        function before(n, func) {
4887          var result2;
4888          if (typeof func != "function") {
4889            throw new TypeError2(FUNC_ERROR_TEXT);
4890          }
4891          n = toInteger2(n);
4892          return function() {
4893            if (--n > 0) {
4894              result2 = func.apply(this, arguments);
4895            }
4896            if (n <= 1) {
4897              func = undefined2;
4898            }
4899            return result2;
4900          };
4901        }
4902        var bind = baseRest(function(func, thisArg, partials) {
4903          var bitmask = WRAP_BIND_FLAG;
4904          if (partials.length) {
4905            var holders = replaceHolders(partials, getHolder(bind));
4906            bitmask |= WRAP_PARTIAL_FLAG;
4907          }
4908          return createWrap(func, bitmask, thisArg, partials, holders);
4909        });
4910        var bindKey = baseRest(function(object, key, partials) {
4911          var bitmask = WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG;
4912          if (partials.length) {
4913            var holders = replaceHolders(partials, getHolder(bindKey));
4914            bitmask |= WRAP_PARTIAL_FLAG;
4915          }
4916          return createWrap(key, bitmask, object, partials, holders);
4917        });
4918        function curry(func, arity, guard) {
4919          arity = guard ? undefined2 : arity;
4920          var result2 = createWrap(func, WRAP_CURRY_FLAG, undefined2, undefined2, undefined2, undefined2, undefined2, arity);
4921          result2.placeholder = curry.placeholder;
4922          return result2;
4923        }
4924        function curryRight(func, arity, guard) {
4925          arity = guard ? undefined2 : arity;
4926          var result2 = createWrap(func, WRAP_CURRY_RIGHT_FLAG, undefined2, undefined2, undefined2, undefined2, undefined2, arity);
4927          result2.placeholder = curryRight.placeholder;
4928          return result2;
4929        }
4930        function debounce(func, wait, options2) {
4931          var lastArgs, lastThis, maxWait, result2, timerId, lastCallTime, lastInvokeTime = 0, leading = false, maxing = false, trailing = true;
4932          if (typeof func != "function") {
4933            throw new TypeError2(FUNC_ERROR_TEXT);
4934          }
4935          wait = toNumber(wait) || 0;
4936          if (isObject7(options2)) {
4937            leading = !!options2.leading;
4938            maxing = "maxWait" in options2;
4939            maxWait = maxing ? nativeMax(toNumber(options2.maxWait) || 0, wait) : maxWait;
4940            trailing = "trailing" in options2 ? !!options2.trailing : trailing;
4941          }
4942          function invokeFunc(time) {
4943            var args = lastArgs, thisArg = lastThis;
4944            lastArgs = lastThis = undefined2;
4945            lastInvokeTime = time;
4946            result2 = func.apply(thisArg, args);
4947            return result2;
4948          }
4949          function leadingEdge(time) {
4950            lastInvokeTime = time;
4951            timerId = setTimeout2(timerExpired, wait);
4952            return leading ? invokeFunc(time) : result2;
4953          }
4954          function remainingWait(time) {
4955            var timeSinceLastCall = time - lastCallTime, timeSinceLastInvoke = time - lastInvokeTime, timeWaiting = wait - timeSinceLastCall;
4956            return maxing ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke) : timeWaiting;
4957          }
4958          function shouldInvoke(time) {
4959            var timeSinceLastCall = time - lastCallTime, timeSinceLastInvoke = time - lastInvokeTime;
4960            return lastCallTime === undefined2 || timeSinceLastCall >= wait || timeSinceLastCall < 0 || maxing && timeSinceLastInvoke >= maxWait;
4961          }
4962          function timerExpired() {
4963            var time = now2();
4964            if (shouldInvoke(time)) {
4965              return trailingEdge(time);
4966            }
4967            timerId = setTimeout2(timerExpired, remainingWait(time));
4968          }
4969          function trailingEdge(time) {
4970            timerId = undefined2;
4971            if (trailing && lastArgs) {
4972              return invokeFunc(time);
4973            }
4974            lastArgs = lastThis = undefined2;
4975            return result2;
4976          }
4977          function cancel() {
4978            if (timerId !== undefined2) {
4979              clearTimeout2(timerId);
4980            }
4981            lastInvokeTime = 0;
4982            lastArgs = lastCallTime = lastThis = timerId = undefined2;
4983          }
4984          function flush() {
4985            return timerId === undefined2 ? result2 : trailingEdge(now2());
4986          }
4987          function debounced() {
4988            var time = now2(), isInvoking = shouldInvoke(time);
4989            lastArgs = arguments;
4990            lastThis = this;
4991            lastCallTime = time;
4992            if (isInvoking) {
4993              if (timerId === undefined2) {
4994                return leadingEdge(lastCallTime);
4995              }
4996              if (maxing) {
4997                clearTimeout2(timerId);
4998                timerId = setTimeout2(timerExpired, wait);
4999                return invokeFunc(lastCallTime);
5000              }
5001            }
5002            if (timerId === undefined2) {
5003              timerId = setTimeout2(timerExpired, wait);
5004            }
5005            return result2;
5006          }
5007          debounced.cancel = cancel;
5008          debounced.flush = flush;
5009          return debounced;
5010        }
5011        var defer2 = baseRest(function(func, args) {
5012          return baseDelay(func, 1, args);
5013        });
5014        var delay = baseRest(function(func, wait, args) {
5015          return baseDelay(func, toNumber(wait) || 0, args);
5016        });
5017        function flip(func) {
5018          return createWrap(func, WRAP_FLIP_FLAG);
5019        }
5020        function memoize(func, resolver) {
5021          if (typeof func != "function" || resolver != null && typeof resolver != "function") {
5022            throw new TypeError2(FUNC_ERROR_TEXT);
5023          }
5024          var memoized = function() {
5025            var args = arguments, key = resolver ? resolver.apply(this, args) : args[0], cache = memoized.cache;
5026            if (cache.has(key)) {
5027              return cache.get(key);
5028            }
5029            var result2 = func.apply(this, args);
5030            memoized.cache = cache.set(key, result2) || cache;
5031            return result2;
5032          };
5033          memoized.cache = new (memoize.Cache || MapCache)();
5034          return memoized;
5035        }
5036        memoize.Cache = MapCache;
5037        function negate(predicate) {
5038          if (typeof predicate != "function") {
5039            throw new TypeError2(FUNC_ERROR_TEXT);
5040          }
5041          return function() {
5042            var args = arguments;
5043            switch (args.length) {
5044              case 0:
5045                return !predicate.call(this);
5046              case 1:
5047                return !predicate.call(this, args[0]);
5048              case 2:
5049                return !predicate.call(this, args[0], args[1]);
5050              case 3:
5051                return !predicate.call(this, args[0], args[1], args[2]);
5052            }
5053            return !predicate.apply(this, args);
5054          };
5055        }
5056        function once(func) {
5057          return before(2, func);
5058        }
5059        var overArgs = castRest(function(func, transforms) {
5060          transforms = transforms.length == 1 && isArray2(transforms[0]) ? arrayMap(transforms[0], baseUnary(getIteratee())) : arrayMap(baseFlatten(transforms, 1), baseUnary(getIteratee()));
5061          var funcsLength = transforms.length;
5062          return baseRest(function(args) {
5063            var index = -1, length = nativeMin(args.length, funcsLength);
5064            while (++index < length) {
5065              args[index] = transforms[index].call(this, args[index]);
5066            }
5067            return apply(func, this, args);
5068          });
5069        });
5070        var partial = baseRest(function(func, partials) {
5071          var holders = replaceHolders(partials, getHolder(partial));
5072          return createWrap(func, WRAP_PARTIAL_FLAG, undefined2, partials, holders);
5073        });
5074        var partialRight = baseRest(function(func, partials) {
5075          var holders = replaceHolders(partials, getHolder(partialRight));
5076          return createWrap(func, WRAP_PARTIAL_RIGHT_FLAG, undefined2, partials, holders);
5077        });
5078        var rearg = flatRest(function(func, indexes) {
5079          return createWrap(func, WRAP_REARG_FLAG, undefined2, undefined2, undefined2, indexes);
5080        });
5081        function rest(func, start) {
5082          if (typeof func != "function") {
5083            throw new TypeError2(FUNC_ERROR_TEXT);
5084          }
5085          start = start === undefined2 ? start : toInteger2(start);
5086          return baseRest(func, start);
5087        }
5088        function spread(func, start) {
5089          if (typeof func != "function") {
5090            throw new TypeError2(FUNC_ERROR_TEXT);
5091          }
5092          start = start == null ? 0 : nativeMax(toInteger2(start), 0);
5093          return baseRest(function(args) {
5094            var array = args[start], otherArgs = castSlice(args, 0, start);
5095            if (array) {
5096              arrayPush(otherArgs, array);
5097            }
5098            return apply(func, this, otherArgs);
5099          });
5100        }
5101        function throttle(func, wait, options2) {
5102          var leading = true, trailing = true;
5103          if (typeof func != "function") {
5104            throw new TypeError2(FUNC_ERROR_TEXT);
5105          }
5106          if (isObject7(options2)) {
5107            leading = "leading" in options2 ? !!options2.leading : leading;
5108            trailing = "trailing" in options2 ? !!options2.trailing : trailing;
5109          }
5110          return debounce(func, wait, {
5111            "leading": leading,
5112            "maxWait": wait,
5113            "trailing": trailing
5114          });
5115        }
5116        function unary(func) {
5117          return ary(func, 1);
5118        }
5119        function wrap(value, wrapper) {
5120          return partial(castFunction(wrapper), value);
5121        }
5122        function castArray() {
5123          if (!arguments.length) {
5124            return [];
5125          }
5126          var value = arguments[0];
5127          return isArray2(value) ? value : [value];
5128        }
5129        function clone(value) {
5130          return baseClone(value, CLONE_SYMBOLS_FLAG);
5131        }
5132        function cloneWith(value, customizer) {
5133          customizer = typeof customizer == "function" ? customizer : undefined2;
5134          return baseClone(value, CLONE_SYMBOLS_FLAG, customizer);
5135        }
5136        function cloneDeep2(value) {
5137          return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG);
5138        }
5139        function cloneDeepWith(value, customizer) {
5140          customizer = typeof customizer == "function" ? customizer : undefined2;
5141          return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG, customizer);
5142        }
5143        function conformsTo(object, source) {
5144          return source == null || baseConformsTo(object, source, keys(source));
5145        }
5146        function eq(value, other2) {
5147          return value === other2 || value !== value && other2 !== other2;
5148        }
5149        var gt = createRelationalOperation(baseGt);
5150        var gte = createRelationalOperation(function(value, other2) {
5151          return value >= other2;
5152        });
5153        var isArguments = baseIsArguments(/* @__PURE__ */ function() {
5154          return arguments;
5155        }()) ? baseIsArguments : function(value) {
5156          return isObjectLike(value) && hasOwnProperty.call(value, "callee") && !propertyIsEnumerable.call(value, "callee");
5157        };
5158        var isArray2 = Array2.isArray;
5159        var isArrayBuffer = nodeIsArrayBuffer ? baseUnary(nodeIsArrayBuffer) : baseIsArrayBuffer;
5160        function isArrayLike(value) {
5161          return value != null && isLength(value.length) && !isFunction3(value);
5162        }
5163        function isArrayLikeObject(value) {
5164          return isObjectLike(value) && isArrayLike(value);
5165        }
5166        function isBoolean(value) {
5167          return value === true || value === false || isObjectLike(value) && baseGetTag(value) == boolTag;
5168        }
5169        var isBuffer = nativeIsBuffer || stubFalse;
5170        var isDate = nodeIsDate ? baseUnary(nodeIsDate) : baseIsDate;
5171        function isElement(value) {
5172          return isObjectLike(value) && value.nodeType === 1 && !isPlainObject(value);
5173        }
5174        function isEmpty(value) {
5175          if (value == null) {
5176            return true;
5177          }
5178          if (isArrayLike(value) && (isArray2(value) || typeof value == "string" || typeof value.splice == "function" || isBuffer(value) || isTypedArray(value) || isArguments(value))) {
5179            return !value.length;
5180          }
5181          var tag2 = getTag(value);
5182          if (tag2 == mapTag || tag2 == setTag) {
5183            return !value.size;
5184          }
5185          if (isPrototype(value)) {
5186            return !baseKeys(value).length;
5187          }
5188          for (var key in value) {
5189            if (hasOwnProperty.call(value, key)) {
5190              return false;
5191            }
5192          }
5193          return true;
5194        }
5195        function isEqual(value, other2) {
5196          return baseIsEqual(value, other2);
5197        }
5198        function isEqualWith(value, other2, customizer) {
5199          customizer = typeof customizer == "function" ? customizer : undefined2;
5200          var result2 = customizer ? customizer(value, other2) : undefined2;
5201          return result2 === undefined2 ? baseIsEqual(value, other2, undefined2, customizer) : !!result2;
5202        }
5203        function isError(value) {
5204          if (!isObjectLike(value)) {
5205            return false;
5206          }
5207          var tag2 = baseGetTag(value);
5208          return tag2 == errorTag || tag2 == domExcTag || typeof value.message == "string" && typeof value.name == "string" && !isPlainObject(value);
5209        }
5210        function isFinite(value) {
5211          return typeof value == "number" && nativeIsFinite(value);
5212        }
5213        function isFunction3(value) {
5214          if (!isObject7(value)) {
5215            return false;
5216          }
5217          var tag2 = baseGetTag(value);
5218          return tag2 == funcTag || tag2 == genTag || tag2 == asyncTag || tag2 == proxyTag;
5219        }
5220        function isInteger(value) {
5221          return typeof value == "number" && value == toInteger2(value);
5222        }
5223        function isLength(value) {
5224          return typeof value == "number" && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
5225        }
5226        function isObject7(value) {
5227          var type = typeof value;
5228          return value != null && (type == "object" || type == "function");
5229        }
5230        function isObjectLike(value) {
5231          return value != null && typeof value == "object";
5232        }
5233        var isMap = nodeIsMap ? baseUnary(nodeIsMap) : baseIsMap;
5234        function isMatch(object, source) {
5235          return object === source || baseIsMatch(object, source, getMatchData(source));
5236        }
5237        function isMatchWith(object, source, customizer) {
5238          customizer = typeof customizer == "function" ? customizer : undefined2;
5239          return baseIsMatch(object, source, getMatchData(source), customizer);
5240        }
5241        function isNaN2(value) {
5242          return isNumber(value) && value != +value;
5243        }
5244        function isNative(value) {
5245          if (isMaskable(value)) {
5246            throw new Error2(CORE_ERROR_TEXT);
5247          }
5248          return baseIsNative(value);
5249        }
5250        function isNull(value) {
5251          return value === null;
5252        }
5253        function isNil(value) {
5254          return value == null;
5255        }
5256        function isNumber(value) {
5257          return typeof value == "number" || isObjectLike(value) && baseGetTag(value) == numberTag;
5258        }
5259        function isPlainObject(value) {
5260          if (!isObjectLike(value) || baseGetTag(value) != objectTag) {
5261            return false;
5262          }
5263          var proto = getPrototype(value);
5264          if (proto === null) {
5265            return true;
5266          }
5267          var Ctor = hasOwnProperty.call(proto, "constructor") && proto.constructor;
5268          return typeof Ctor == "function" && Ctor instanceof Ctor && funcToString.call(Ctor) == objectCtorString;
5269        }
5270        var isRegExp = nodeIsRegExp ? baseUnary(nodeIsRegExp) : baseIsRegExp;
5271        function isSafeInteger(value) {
5272          return isInteger(value) && value >= -MAX_SAFE_INTEGER && value <= MAX_SAFE_INTEGER;
5273        }
5274        var isSet = nodeIsSet ? baseUnary(nodeIsSet) : baseIsSet;
5275        function isString2(value) {
5276          return typeof value == "string" || !isArray2(value) && isObjectLike(value) && baseGetTag(value) == stringTag;
5277        }
5278        function isSymbol(value) {
5279          return typeof value == "symbol" || isObjectLike(value) && baseGetTag(value) == symbolTag;
5280        }
5281        var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;
5282        function isUndefined(value) {
5283          return value === undefined2;
5284        }
5285        function isWeakMap(value) {
5286          return isObjectLike(value) && getTag(value) == weakMapTag;
5287        }
5288        function isWeakSet(value) {
5289          return isObjectLike(value) && baseGetTag(value) == weakSetTag;
5290        }
5291        var lt = createRelationalOperation(baseLt);
5292        var lte = createRelationalOperation(function(value, other2) {
5293          return value <= other2;
5294        });
5295        function toArray(value) {
5296          if (!value) {
5297            return [];
5298          }
5299          if (isArrayLike(value)) {
5300            return isString2(value) ? stringToArray(value) : copyArray(value);
5301          }
5302          if (symIterator && value[symIterator]) {
5303            return iteratorToArray(value[symIterator]());
5304          }
5305          var tag2 = getTag(value), func = tag2 == mapTag ? mapToArray : tag2 == setTag ? setToArray : values;
5306          return func(value);
5307        }
5308        function toFinite(value) {
5309          if (!value) {
5310            return value === 0 ? value : 0;
5311          }
5312          value = toNumber(value);
5313          if (value === INFINITY || value === -INFINITY) {
5314            var sign = value < 0 ? -1 : 1;
5315            return sign * MAX_INTEGER;
5316          }
5317          return value === value ? value : 0;
5318        }
5319        function toInteger2(value) {
5320          var result2 = toFinite(value), remainder = result2 % 1;
5321          return result2 === result2 ? remainder ? result2 - remainder : result2 : 0;
5322        }
5323        function toLength(value) {
5324          return value ? baseClamp(toInteger2(value), 0, MAX_ARRAY_LENGTH) : 0;
5325        }
5326        function toNumber(value) {
5327          if (typeof value == "number") {
5328            return value;
5329          }
5330          if (isSymbol(value)) {
5331            return NAN;
5332          }
5333          if (isObject7(value)) {
5334            var other2 = typeof value.valueOf == "function" ? value.valueOf() : value;
5335            value = isObject7(other2) ? other2 + "" : other2;
5336          }
5337          if (typeof value != "string") {
5338            return value === 0 ? value : +value;
5339          }
5340          value = baseTrim(value);
5341          var isBinary = reIsBinary.test(value);
5342          return isBinary || reIsOctal.test(value) ? freeParseInt(value.slice(2), isBinary ? 2 : 8) : reIsBadHex.test(value) ? NAN : +value;
5343        }
5344        function toPlainObject(value) {
5345          return copyObject(value, keysIn(value));
5346        }
5347        function toSafeInteger(value) {
5348          return value ? baseClamp(toInteger2(value), -MAX_SAFE_INTEGER, MAX_SAFE_INTEGER) : value === 0 ? value : 0;
5349        }
5350        function toString(value) {
5351          return value == null ? "" : baseToString(value);
5352        }
5353        var assign = createAssigner(function(object, source) {
5354          if (isPrototype(source) || isArrayLike(source)) {
5355            copyObject(source, keys(source), object);
5356            return;
5357          }
5358          for (var key in source) {
5359            if (hasOwnProperty.call(source, key)) {
5360              assignValue(object, key, source[key]);
5361            }
5362          }
5363        });
5364        var assignIn = createAssigner(function(object, source) {
5365          copyObject(source, keysIn(source), object);
5366        });
5367        var assignInWith = createAssigner(function(object, source, srcIndex, customizer) {
5368          copyObject(source, keysIn(source), object, customizer);
5369        });
5370        var assignWith = createAssigner(function(object, source, srcIndex, customizer) {
5371          copyObject(source, keys(source), object, customizer);
5372        });
5373        var at = flatRest(baseAt);
5374        function create(prototype, properties) {
5375          var result2 = baseCreate(prototype);
5376          return properties == null ? result2 : baseAssign(result2, properties);
5377        }
5378        var defaults2 = baseRest(function(object, sources) {
5379          object = Object2(object);
5380          var index = -1;
5381          var length = sources.length;
5382          var guard = length > 2 ? sources[2] : undefined2;
5383          if (guard && isIterateeCall(sources[0], sources[1], guard)) {
5384            length = 1;
5385          }
5386          while (++index < length) {
5387            var source = sources[index];
5388            var props = keysIn(source);
5389            var propsIndex = -1;
5390            var propsLength = props.length;
5391            while (++propsIndex < propsLength) {
5392              var key = props[propsIndex];
5393              var value = object[key];
5394              if (value === undefined2 || eq(value, objectProto[key]) && !hasOwnProperty.call(object, key)) {
5395                object[key] = source[key];
5396              }
5397            }
5398          }
5399          return object;
5400        });
5401        var defaultsDeep = baseRest(function(args) {
5402          args.push(undefined2, customDefaultsMerge);
5403          return apply(mergeWith, undefined2, args);
5404        });
5405        function findKey(object, predicate) {
5406          return baseFindKey(object, getIteratee(predicate, 3), baseForOwn);
5407        }
5408        function findLastKey(object, predicate) {
5409          return baseFindKey(object, getIteratee(predicate, 3), baseForOwnRight);
5410        }
5411        function forIn(object, iteratee2) {
5412          return object == null ? object : baseFor(object, getIteratee(iteratee2, 3), keysIn);
5413        }
5414        function forInRight(object, iteratee2) {
5415          return object == null ? object : baseForRight(object, getIteratee(iteratee2, 3), keysIn);
5416        }
5417        function forOwn(object, iteratee2) {
5418          return object && baseForOwn(object, getIteratee(iteratee2, 3));
5419        }
5420        function forOwnRight(object, iteratee2) {
5421          return object && baseForOwnRight(object, getIteratee(iteratee2, 3));
5422        }
5423        function functions2(object) {
5424          return object == null ? [] : baseFunctions(object, keys(object));
5425        }
5426        function functionsIn(object) {
5427          return object == null ? [] : baseFunctions(object, keysIn(object));
5428        }
5429        function get(object, path2, defaultValue) {
5430          var result2 = object == null ? undefined2 : baseGet(object, path2);
5431          return result2 === undefined2 ? defaultValue : result2;
5432        }
5433        function has(object, path2) {
5434          return object != null && hasPath(object, path2, baseHas);
5435        }
5436        function hasIn(object, path2) {
5437          return object != null && hasPath(object, path2, baseHasIn);
5438        }
5439        var invert = createInverter(function(result2, value, key) {
5440          if (value != null && typeof value.toString != "function") {
5441            value = nativeObjectToString.call(value);
5442          }
5443          result2[value] = key;
5444        }, constant(identity2));
5445        var invertBy = createInverter(function(result2, value, key) {
5446          if (value != null && typeof value.toString != "function") {
5447            value = nativeObjectToString.call(value);
5448          }
5449          if (hasOwnProperty.call(result2, value)) {
5450            result2[value].push(key);
5451          } else {
5452            result2[value] = [key];
5453          }
5454        }, getIteratee);
5455        var invoke = baseRest(baseInvoke);
5456        function keys(object) {
5457          return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);
5458        }
5459        function keysIn(object) {
5460          return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object);
5461        }
5462        function mapKeys(object, iteratee2) {
5463          var result2 = {};
5464          iteratee2 = getIteratee(iteratee2, 3);
5465          baseForOwn(object, function(value, key, object2) {
5466            baseAssignValue(result2, iteratee2(value, key, object2), value);
5467          });
5468          return result2;
5469        }
5470        function mapValues(object, iteratee2) {
5471          var result2 = {};
5472          iteratee2 = getIteratee(iteratee2, 3);
5473          baseForOwn(object, function(value, key, object2) {
5474            baseAssignValue(result2, key, iteratee2(value, key, object2));
5475          });
5476          return result2;
5477        }
5478        var merge3 = createAssigner(function(object, source, srcIndex) {
5479          baseMerge(object, source, srcIndex);
5480        });
5481        var mergeWith = createAssigner(function(object, source, srcIndex, customizer) {
5482          baseMerge(object, source, srcIndex, customizer);
5483        });
5484        var omit = flatRest(function(object, paths) {
5485          var result2 = {};
5486          if (object == null) {
5487            return result2;
5488          }
5489          var isDeep = false;
5490          paths = arrayMap(paths, function(path2) {
5491            path2 = castPath(path2, object);
5492            isDeep || (isDeep = path2.length > 1);
5493            return path2;
5494          });
5495          copyObject(object, getAllKeysIn(object), result2);
5496          if (isDeep) {
5497            result2 = baseClone(result2, CLONE_DEEP_FLAG | CLONE_FLAT_FLAG | CLONE_SYMBOLS_FLAG, customOmitClone);
5498          }
5499          var length = paths.length;
5500          while (length--) {
5501            baseUnset(result2, paths[length]);
5502          }
5503          return result2;
5504        });
5505        function omitBy(object, predicate) {
5506          return pickBy(object, negate(getIteratee(predicate)));
5507        }
5508        var pick = flatRest(function(object, paths) {
5509          return object == null ? {} : basePick(object, paths);
5510        });
5511        function pickBy(object, predicate) {
5512          if (object == null) {
5513            return {};
5514          }
5515          var props = arrayMap(getAllKeysIn(object), function(prop) {
5516            return [prop];
5517          });
5518          predicate = getIteratee(predicate);
5519          return basePickBy(object, props, function(value, path2) {
5520            return predicate(value, path2[0]);
5521          });
5522        }
5523        function result(object, path2, defaultValue) {
5524          path2 = castPath(path2, object);
5525          var index = -1, length = path2.length;
5526          if (!length) {
5527            length = 1;
5528            object = undefined2;
5529          }
5530          while (++index < length) {
5531            var value = object == null ? undefined2 : object[toKey(path2[index])];
5532            if (value === undefined2) {
5533              index = length;
5534              value = defaultValue;
5535            }
5536            object = isFunction3(value) ? value.call(object) : value;
5537          }
5538          return object;
5539        }
5540        function set(object, path2, value) {
5541          return object == null ? object : baseSet(object, path2, value);
5542        }
5543        function setWith(object, path2, value, customizer) {
5544          customizer = typeof customizer == "function" ? customizer : undefined2;
5545          return object == null ? object : baseSet(object, path2, value, customizer);
5546        }
5547        var toPairs = createToPairs(keys);
5548        var toPairsIn = createToPairs(keysIn);
5549        function transform(object, iteratee2, accumulator) {
5550          var isArr = isArray2(object), isArrLike = isArr || isBuffer(object) || isTypedArray(object);
5551          iteratee2 = getIteratee(iteratee2, 4);
5552          if (accumulator == null) {
5553            var Ctor = object && object.constructor;
5554            if (isArrLike) {
5555              accumulator = isArr ? new Ctor() : [];
5556            } else if (isObject7(object)) {
5557              accumulator = isFunction3(Ctor) ? baseCreate(getPrototype(object)) : {};
5558            } else {
5559              accumulator = {};
5560            }
5561          }
5562          (isArrLike ? arrayEach : baseForOwn)(object, function(value, index, object2) {
5563            return iteratee2(accumulator, value, index, object2);
5564          });
5565          return accumulator;
5566        }
5567        function unset(object, path2) {
5568          return object == null ? true : baseUnset(object, path2);
5569        }
5570        function update2(object, path2, updater) {
5571          return object == null ? object : baseUpdate(object, path2, castFunction(updater));
5572        }
5573        function updateWith(object, path2, updater, customizer) {
5574          customizer = typeof customizer == "function" ? customizer : undefined2;
5575          return object == null ? object : baseUpdate(object, path2, castFunction(updater), customizer);
5576        }
5577        function values(object) {
5578          return object == null ? [] : baseValues(object, keys(object));
5579        }
5580        function valuesIn(object) {
5581          return object == null ? [] : baseValues(object, keysIn(object));
5582        }
5583        function clamp(number, lower, upper) {
5584          if (upper === undefined2) {
5585            upper = lower;
5586            lower = undefined2;
5587          }
5588          if (upper !== undefined2) {
5589            upper = toNumber(upper);
5590            upper = upper === upper ? upper : 0;
5591          }
5592          if (lower !== undefined2) {
5593            lower = toNumber(lower);
5594            lower = lower === lower ? lower : 0;
5595          }
5596          return baseClamp(toNumber(number), lower, upper);
5597        }
5598        function inRange(number, start, end) {
5599          start = toFinite(start);
5600          if (end === undefined2) {
5601            end = start;
5602            start = 0;
5603          } else {
5604            end = toFinite(end);
5605          }
5606          number = toNumber(number);
5607          return baseInRange(number, start, end);
5608        }
5609        function random(lower, upper, floating) {
5610          if (floating && typeof floating != "boolean" && isIterateeCall(lower, upper, floating)) {
5611            upper = floating = undefined2;
5612          }
5613          if (floating === undefined2) {
5614            if (typeof upper == "boolean") {
5615              floating = upper;
5616              upper = undefined2;
5617            } else if (typeof lower == "boolean") {
5618              floating = lower;
5619              lower = undefined2;
5620            }
5621          }
5622          if (lower === undefined2 && upper === undefined2) {
5623            lower = 0;
5624            upper = 1;
5625          } else {
5626            lower = toFinite(lower);
5627            if (upper === undefined2) {
5628              upper = lower;
5629              lower = 0;
5630            } else {
5631              upper = toFinite(upper);
5632            }
5633          }
5634          if (lower > upper) {
5635            var temp = lower;
5636            lower = upper;
5637            upper = temp;
5638          }
5639          if (floating || lower % 1 || upper % 1) {
5640            var rand = nativeRandom();
5641            return nativeMin(lower + rand * (upper - lower + freeParseFloat("1e-" + ((rand + "").length - 1))), upper);
5642          }
5643          return baseRandom(lower, upper);
5644        }
5645        var camelCase = createCompounder(function(result2, word, index) {
5646          word = word.toLowerCase();
5647          return result2 + (index ? capitalize(word) : word);
5648        });
5649        function capitalize(string) {
5650          return upperFirst(toString(string).toLowerCase());
5651        }
5652        function deburr(string) {
5653          string = toString(string);
5654          return string && string.replace(reLatin, deburrLetter).replace(reComboMark, "");
5655        }
5656        function endsWith(string, target, position) {
5657          string = toString(string);
5658          target = baseToString(target);
5659          var length = string.length;
5660          position = position === undefined2 ? length : baseClamp(toInteger2(position), 0, length);
5661          var end = position;
5662          position -= target.length;
5663          return position >= 0 && string.slice(position, end) == target;
5664        }
5665        function escape3(string) {
5666          string = toString(string);
5667          return string && reHasUnescapedHtml.test(string) ? string.replace(reUnescapedHtml, escapeHtmlChar) : string;
5668        }
5669        function escapeRegExp(string) {
5670          string = toString(string);
5671          return string && reHasRegExpChar.test(string) ? string.replace(reRegExpChar, "\\$&") : string;
5672        }
5673        var kebabCase = createCompounder(function(result2, word, index) {
5674          return result2 + (index ? "-" : "") + word.toLowerCase();
5675        });
5676        var lowerCase = createCompounder(function(result2, word, index) {
5677          return result2 + (index ? " " : "") + word.toLowerCase();
5678        });
5679        var lowerFirst = createCaseFirst("toLowerCase");
5680        function pad2(string, length, chars) {
5681          string = toString(string);
5682          length = toInteger2(length);
5683          var strLength = length ? stringSize(string) : 0;
5684          if (!length || strLength >= length) {
5685            return string;
5686          }
5687          var mid = (length - strLength) / 2;
5688          return createPadding(nativeFloor(mid), chars) + string + createPadding(nativeCeil(mid), chars);
5689        }
5690        function padEnd(string, length, chars) {
5691          string = toString(string);
5692          length = toInteger2(length);
5693          var strLength = length ? stringSize(string) : 0;
5694          return length && strLength < length ? string + createPadding(length - strLength, chars) : string;
5695        }
5696        function padStart(string, length, chars) {
5697          string = toString(string);
5698          length = toInteger2(length);
5699          var strLength = length ? stringSize(string) : 0;
5700          return length && strLength < length ? createPadding(length - strLength, chars) + string : string;
5701        }
5702        function parseInt2(string, radix, guard) {
5703          if (guard || radix == null) {
5704            radix = 0;
5705          } else if (radix) {
5706            radix = +radix;
5707          }
5708          return nativeParseInt(toString(string).replace(reTrimStart, ""), radix || 0);
5709        }
5710        function repeat(string, n, guard) {
5711          if (guard ? isIterateeCall(string, n, guard) : n === undefined2) {
5712            n = 1;
5713          } else {
5714            n = toInteger2(n);
5715          }
5716          return baseRepeat(toString(string), n);
5717        }
5718        function replace() {
5719          var args = arguments, string = toString(args[0]);
5720          return args.length < 3 ? string : string.replace(args[1], args[2]);
5721        }
5722        var snakeCase = createCompounder(function(result2, word, index) {
5723          return result2 + (index ? "_" : "") + word.toLowerCase();
5724        });
5725        function split(string, separator, limit) {
5726          if (limit && typeof limit != "number" && isIterateeCall(string, separator, limit)) {
5727            separator = limit = undefined2;
5728          }
5729          limit = limit === undefined2 ? MAX_ARRAY_LENGTH : limit >>> 0;
5730          if (!limit) {
5731            return [];
5732          }
5733          string = toString(string);
5734          if (string && (typeof separator == "string" || separator != null && !isRegExp(separator))) {
5735            separator = baseToString(separator);
5736            if (!separator && hasUnicode(string)) {
5737              return castSlice(stringToArray(string), 0, limit);
5738            }
5739          }
5740          return string.split(separator, limit);
5741        }
5742        var startCase = createCompounder(function(result2, word, index) {
5743          return result2 + (index ? " " : "") + upperFirst(word);
5744        });
5745        function startsWith(string, target, position) {
5746          string = toString(string);
5747          position = position == null ? 0 : baseClamp(toInteger2(position), 0, string.length);
5748          target = baseToString(target);
5749          return string.slice(position, position + target.length) == target;
5750        }
5751        function template(string, options2, guard) {
5752          var settings = lodash.templateSettings;
5753          if (guard && isIterateeCall(string, options2, guard)) {
5754            options2 = undefined2;
5755          }
5756          string = toString(string);
5757          options2 = assignInWith({}, options2, settings, customDefaultsAssignIn);
5758          var imports = assignInWith({}, options2.imports, settings.imports, customDefaultsAssignIn), importsKeys = keys(imports), importsValues = baseValues(imports, importsKeys);
5759          var isEscaping, isEvaluating, index = 0, interpolate = options2.interpolate || reNoMatch, source = "__p += '";
5760          var reDelimiters = RegExp2((options2.escape || reNoMatch).source + "|" + interpolate.source + "|" + (interpolate === reInterpolate ? reEsTemplate : reNoMatch).source + "|" + (options2.evaluate || reNoMatch).source + "|$", "g");
5761          var sourceURL = "//# sourceURL=" + (hasOwnProperty.call(options2, "sourceURL") ? (options2.sourceURL + "").replace(/\s/g, " ") : "lodash.templateSources[" + ++templateCounter + "]") + "\n";
5762          string.replace(reDelimiters, function(match, escapeValue, interpolateValue, esTemplateValue, evaluateValue, offset) {
5763            interpolateValue || (interpolateValue = esTemplateValue);
5764            source += string.slice(index, offset).replace(reUnescapedString, escapeStringChar);
5765            if (escapeValue) {
5766              isEscaping = true;
5767              source += "' +\n__e(" + escapeValue + ") +\n'";
5768            }
5769            if (evaluateValue) {
5770              isEvaluating = true;
5771              source += "';\n" + evaluateValue + ";\n__p += '";
5772            }
5773            if (interpolateValue) {
5774              source += "' +\n((__t = (" + interpolateValue + ")) == null ? '' : __t) +\n'";
5775            }
5776            index = offset + match.length;
5777            return match;
5778          });
5779          source += "';\n";
5780          var variable = hasOwnProperty.call(options2, "variable") && options2.variable;
5781          if (!variable) {
5782            source = "with (obj) {\n" + source + "\n}\n";
5783          } else if (reForbiddenIdentifierChars.test(variable)) {
5784            throw new Error2(INVALID_TEMPL_VAR_ERROR_TEXT);
5785          }
5786          source = (isEvaluating ? source.replace(reEmptyStringLeading, "") : source).replace(reEmptyStringMiddle, "$1").replace(reEmptyStringTrailing, "$1;");
5787          source = "function(" + (variable || "obj") + ") {\n" + (variable ? "" : "obj || (obj = {});\n") + "var __t, __p = ''" + (isEscaping ? ", __e = _.escape" : "") + (isEvaluating ? ", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n" : ";\n") + source + "return __p\n}";
5788          var result2 = attempt(function() {
5789            return Function2(importsKeys, sourceURL + "return " + source).apply(undefined2, importsValues);
5790          });
5791          result2.source = source;
5792          if (isError(result2)) {
5793            throw result2;
5794          }
5795          return result2;
5796        }
5797        function toLower(value) {
5798          return toString(value).toLowerCase();
5799        }
5800        function toUpper(value) {
5801          return toString(value).toUpperCase();
5802        }
5803        function trim(string, chars, guard) {
5804          string = toString(string);
5805          if (string && (guard || chars === undefined2)) {
5806            return baseTrim(string);
5807          }
5808          if (!string || !(chars = baseToString(chars))) {
5809            return string;
5810          }
5811          var strSymbols = stringToArray(string), chrSymbols = stringToArray(chars), start = charsStartIndex(strSymbols, chrSymbols), end = charsEndIndex(strSymbols, chrSymbols) + 1;
5812          return castSlice(strSymbols, start, end).join("");
5813        }
5814        function trimEnd(string, chars, guard) {
5815          string = toString(string);
5816          if (string && (guard || chars === undefined2)) {
5817            return string.slice(0, trimmedEndIndex(string) + 1);
5818          }
5819          if (!string || !(chars = baseToString(chars))) {
5820            return string;
5821          }
5822          var strSymbols = stringToArray(string), end = charsEndIndex(strSymbols, stringToArray(chars)) + 1;
5823          return castSlice(strSymbols, 0, end).join("");
5824        }
5825        function trimStart(string, chars, guard) {
5826          string = toString(string);
5827          if (string && (guard || chars === undefined2)) {
5828            return string.replace(reTrimStart, "");
5829          }
5830          if (!string || !(chars = baseToString(chars))) {
5831            return string;
5832          }
5833          var strSymbols = stringToArray(string), start = charsStartIndex(strSymbols, stringToArray(chars));
5834          return castSlice(strSymbols, start).join("");
5835        }
5836        function truncate(string, options2) {
5837          var length = DEFAULT_TRUNC_LENGTH, omission = DEFAULT_TRUNC_OMISSION;
5838          if (isObject7(options2)) {
5839            var separator = "separator" in options2 ? options2.separator : separator;
5840            length = "length" in options2 ? toInteger2(options2.length) : length;
5841            omission = "omission" in options2 ? baseToString(options2.omission) : omission;
5842          }
5843          string = toString(string);
5844          var strLength = string.length;
5845          if (hasUnicode(string)) {
5846            var strSymbols = stringToArray(string);
5847            strLength = strSymbols.length;
5848          }
5849          if (length >= strLength) {
5850            return string;
5851          }
5852          var end = length - stringSize(omission);
5853          if (end < 1) {
5854            return omission;
5855          }
5856          var result2 = strSymbols ? castSlice(strSymbols, 0, end).join("") : string.slice(0, end);
5857          if (separator === undefined2) {
5858            return result2 + omission;
5859          }
5860          if (strSymbols) {
5861            end += result2.length - end;
5862          }
5863          if (isRegExp(separator)) {
5864            if (string.slice(end).search(separator)) {
5865              var match, substring = result2;
5866              if (!separator.global) {
5867                separator = RegExp2(separator.source, toString(reFlags.exec(separator)) + "g");
5868              }
5869              separator.lastIndex = 0;
5870              while (match = separator.exec(substring)) {
5871                var newEnd = match.index;
5872              }
5873              result2 = result2.slice(0, newEnd === undefined2 ? end : newEnd);
5874            }
5875          } else if (string.indexOf(baseToString(separator), end) != end) {
5876            var index = result2.lastIndexOf(separator);
5877            if (index > -1) {
5878              result2 = result2.slice(0, index);
5879            }
5880          }
5881          return result2 + omission;
5882        }
5883        function unescape(string) {
5884          string = toString(string);
5885          return string && reHasEscapedHtml.test(string) ? string.replace(reEscapedHtml, unescapeHtmlChar) : string;
5886        }
5887        var upperCase = createCompounder(function(result2, word, index) {
5888          return result2 + (index ? " " : "") + word.toUpperCase();
5889        });
5890        var upperFirst = createCaseFirst("toUpperCase");
5891        function words(string, pattern, guard) {
5892          string = toString(string);
5893          pattern = guard ? undefined2 : pattern;
5894          if (pattern === undefined2) {
5895            return hasUnicodeWord(string) ? unicodeWords(string) : asciiWords(string);
5896          }
5897          return string.match(pattern) || [];
5898        }
5899        var attempt = baseRest(function(func, args) {
5900          try {
5901            return apply(func, undefined2, args);
5902          } catch (e) {
5903            return isError(e) ? e : new Error2(e);
5904          }
5905        });
5906        var bindAll = flatRest(function(object, methodNames) {
5907          arrayEach(methodNames, function(key) {
5908            key = toKey(key);
5909            baseAssignValue(object, key, bind(object[key], object));
5910          });
5911          return object;
5912        });
5913        function cond(pairs) {
5914          var length = pairs == null ? 0 : pairs.length, toIteratee = getIteratee();
5915          pairs = !length ? [] : arrayMap(pairs, function(pair) {
5916            if (typeof pair[1] != "function") {
5917              throw new TypeError2(FUNC_ERROR_TEXT);
5918            }
5919            return [toIteratee(pair[0]), pair[1]];
5920          });
5921          return baseRest(function(args) {
5922            var index = -1;
5923            while (++index < length) {
5924              var pair = pairs[index];
5925              if (apply(pair[0], this, args)) {
5926                return apply(pair[1], this, args);
5927              }
5928            }
5929          });
5930        }
5931        function conforms(source) {
5932          return baseConforms(baseClone(source, CLONE_DEEP_FLAG));
5933        }
5934        function constant(value) {
5935          return function() {
5936            return value;
5937          };
5938        }
5939        function defaultTo(value, defaultValue) {
5940          return value == null || value !== value ? defaultValue : value;
5941        }
5942        var flow = createFlow();
5943        var flowRight = createFlow(true);
5944        function identity2(value) {
5945          return value;
5946        }
5947        function iteratee(func) {
5948          return baseIteratee(typeof func == "function" ? func : baseClone(func, CLONE_DEEP_FLAG));
5949        }
5950        function matches(source) {
5951          return baseMatches(baseClone(source, CLONE_DEEP_FLAG));
5952        }
5953        function matchesProperty(path2, srcValue) {
5954          return baseMatchesProperty(path2, baseClone(srcValue, CLONE_DEEP_FLAG));
5955        }
5956        var method = baseRest(function(path2, args) {
5957          return function(object) {
5958            return baseInvoke(object, path2, args);
5959          };
5960        });
5961        var methodOf = baseRest(function(object, args) {
5962          return function(path2) {
5963            return baseInvoke(object, path2, args);
5964          };
5965        });
5966        function mixin(object, source, options2) {
5967          var props = keys(source), methodNames = baseFunctions(source, props);
5968          if (options2 == null && !(isObject7(source) && (methodNames.length || !props.length))) {
5969            options2 = source;
5970            source = object;
5971            object = this;
5972            methodNames = baseFunctions(source, keys(source));
5973          }
5974          var chain2 = !(isObject7(options2) && "chain" in options2) || !!options2.chain, isFunc = isFunction3(object);
5975          arrayEach(methodNames, function(methodName) {
5976            var func = source[methodName];
5977            object[methodName] = func;
5978            if (isFunc) {
5979              object.prototype[methodName] = function() {
5980                var chainAll = this.__chain__;
5981                if (chain2 || chainAll) {
5982                  var result2 = object(this.__wrapped__), actions = result2.__actions__ = copyArray(this.__actions__);
5983                  actions.push({
5984                    "func": func,
5985                    "args": arguments,
5986                    "thisArg": object
5987                  });
5988                  result2.__chain__ = chainAll;
5989                  return result2;
5990                }
5991                return func.apply(object, arrayPush([this.value()], arguments));
5992              };
5993            }
5994          });
5995          return object;
5996        }
5997        function noConflict() {
5998          if (root._ === this) {
5999            root._ = oldDash;
6000          }
6001          return this;
6002        }
6003        function noop() {
6004        }
6005        function nthArg(n) {
6006          n = toInteger2(n);
6007          return baseRest(function(args) {
6008            return baseNth(args, n);
6009          });
6010        }
6011        var over = createOver(arrayMap);
6012        var overEvery = createOver(arrayEvery);
6013        var overSome = createOver(arraySome);
6014        function property(path2) {
6015          return isKey(path2) ? baseProperty(toKey(path2)) : basePropertyDeep(path2);
6016        }
6017        function propertyOf(object) {
6018          return function(path2) {
6019            return object == null ? undefined2 : baseGet(object, path2);
6020          };
6021        }
6022        var range = createRange();
6023        var rangeRight = createRange(true);
6024        function stubArray() {
6025          return [];
6026        }
6027        function stubFalse() {
6028          return false;
6029        }
6030        function stubObject() {
6031          return {};
6032        }
6033        function stubString() {
6034          return "";
6035        }
6036        function stubTrue() {
6037          return true;
6038        }
6039        function times(n, iteratee2) {
6040          n = toInteger2(n);
6041          if (n < 1 || n > MAX_SAFE_INTEGER) {
6042            return [];
6043          }
6044          var index = MAX_ARRAY_LENGTH, length = nativeMin(n, MAX_ARRAY_LENGTH);
6045          iteratee2 = getIteratee(iteratee2);
6046          n -= MAX_ARRAY_LENGTH;
6047          var result2 = baseTimes(length, iteratee2);
6048          while (++index < n) {
6049            iteratee2(index);
6050          }
6051          return result2;
6052        }
6053        function toPath(value) {
6054          if (isArray2(value)) {
6055            return arrayMap(value, toKey);
6056          }
6057          return isSymbol(value) ? [value] : copyArray(stringToPath(toString(value)));
6058        }
6059        function uniqueId(prefix) {
6060          var id = ++idCounter;
6061          return toString(prefix) + id;
6062        }
6063        var add = createMathOperation(function(augend, addend) {
6064          return augend + addend;
6065        }, 0);
6066        var ceil = createRound("ceil");
6067        var divide = createMathOperation(function(dividend, divisor) {
6068          return dividend / divisor;
6069        }, 1);
6070        var floor = createRound("floor");
6071        function max(array) {
6072          return array && array.length ? baseExtremum(array, identity2, baseGt) : undefined2;
6073        }
6074        function maxBy(array, iteratee2) {
6075          return array && array.length ? baseExtremum(array, getIteratee(iteratee2, 2), baseGt) : undefined2;
6076        }
6077        function mean(array) {
6078          return baseMean(array, identity2);
6079        }
6080        function meanBy(array, iteratee2) {
6081          return baseMean(array, getIteratee(iteratee2, 2));
6082        }
6083        function min(array) {
6084          return array && array.length ? baseExtremum(array, identity2, baseLt) : undefined2;
6085        }
6086        function minBy(array, iteratee2) {
6087          return array && array.length ? baseExtremum(array, getIteratee(iteratee2, 2), baseLt) : undefined2;
6088        }
6089        var multiply = createMathOperation(function(multiplier, multiplicand) {
6090          return multiplier * multiplicand;
6091        }, 1);
6092        var round = createRound("round");
6093        var subtract = createMathOperation(function(minuend, subtrahend) {
6094          return minuend - subtrahend;
6095        }, 0);
6096        function sum(array) {
6097          return array && array.length ? baseSum(array, identity2) : 0;
6098        }
6099        function sumBy(array, iteratee2) {
6100          return array && array.length ? baseSum(array, getIteratee(iteratee2, 2)) : 0;
6101        }
6102        lodash.after = after;
6103        lodash.ary = ary;
6104        lodash.assign = assign;
6105        lodash.assignIn = assignIn;
6106        lodash.assignInWith = assignInWith;
6107        lodash.assignWith = assignWith;
6108        lodash.at = at;
6109        lodash.before = before;
6110        lodash.bind = bind;
6111        lodash.bindAll = bindAll;
6112        lodash.bindKey = bindKey;
6113        lodash.castArray = castArray;
6114        lodash.chain = chain;
6115        lodash.chunk = chunk;
6116        lodash.compact = compact;
6117        lodash.concat = concat2;
6118        lodash.cond = cond;
6119        lodash.conforms = conforms;
6120        lodash.constant = constant;
6121        lodash.countBy = countBy;
6122        lodash.create = create;
6123        lodash.curry = curry;
6124        lodash.curryRight = curryRight;
6125        lodash.debounce = debounce;
6126        lodash.defaults = defaults2;
6127        lodash.defaultsDeep = defaultsDeep;
6128        lodash.defer = defer2;
6129        lodash.delay = delay;
6130        lodash.difference = difference;
6131        lodash.differenceBy = differenceBy;
6132        lodash.differenceWith = differenceWith;
6133        lodash.drop = drop;
6134        lodash.dropRight = dropRight;
6135        lodash.dropRightWhile = dropRightWhile;
6136        lodash.dropWhile = dropWhile;
6137        lodash.fill = fill;
6138        lodash.filter = filter2;
6139        lodash.flatMap = flatMap;
6140        lodash.flatMapDeep = flatMapDeep;
6141        lodash.flatMapDepth = flatMapDepth;
6142        lodash.flatten = flatten;
6143        lodash.flattenDeep = flattenDeep;
6144        lodash.flattenDepth = flattenDepth;
6145        lodash.flip = flip;
6146        lodash.flow = flow;
6147        lodash.flowRight = flowRight;
6148        lodash.fromPairs = fromPairs;
6149        lodash.functions = functions2;
6150        lodash.functionsIn = functionsIn;
6151        lodash.groupBy = groupBy;
6152        lodash.initial = initial;
6153        lodash.intersection = intersection;
6154        lodash.intersectionBy = intersectionBy;
6155        lodash.intersectionWith = intersectionWith;
6156        lodash.invert = invert;
6157        lodash.invertBy = invertBy;
6158        lodash.invokeMap = invokeMap;
6159        lodash.iteratee = iteratee;
6160        lodash.keyBy = keyBy;
6161        lodash.keys = keys;
6162        lodash.keysIn = keysIn;
6163        lodash.map = map2;
6164        lodash.mapKeys = mapKeys;
6165        lodash.mapValues = mapValues;
6166        lodash.matches = matches;
6167        lodash.matchesProperty = matchesProperty;
6168        lodash.memoize = memoize;
6169        lodash.merge = merge3;
6170        lodash.mergeWith = mergeWith;
6171        lodash.method = method;
6172        lodash.methodOf = methodOf;
6173        lodash.mixin = mixin;
6174        lodash.negate = negate;
6175        lodash.nthArg = nthArg;
6176        lodash.omit = omit;
6177        lodash.omitBy = omitBy;
6178        lodash.once = once;
6179        lodash.orderBy = orderBy;
6180        lodash.over = over;
6181        lodash.overArgs = overArgs;
6182        lodash.overEvery = overEvery;
6183        lodash.overSome = overSome;
6184        lodash.partial = partial;
6185        lodash.partialRight = partialRight;
6186        lodash.partition = partition;
6187        lodash.pick = pick;
6188        lodash.pickBy = pickBy;
6189        lodash.property = property;
6190        lodash.propertyOf = propertyOf;
6191        lodash.pull = pull;
6192        lodash.pullAll = pullAll;
6193        lodash.pullAllBy = pullAllBy;
6194        lodash.pullAllWith = pullAllWith;
6195        lodash.pullAt = pullAt;
6196        lodash.range = range;
6197        lodash.rangeRight = rangeRight;
6198        lodash.rearg = rearg;
6199        lodash.reject = reject;
6200        lodash.remove = remove;
6201        lodash.rest = rest;
6202        lodash.reverse = reverse;
6203        lodash.sampleSize = sampleSize;
6204        lodash.set = set;
6205        lodash.setWith = setWith;
6206        lodash.shuffle = shuffle;
6207        lodash.slice = slice;
6208        lodash.sortBy = sortBy;
6209        lodash.sortedUniq = sortedUniq;
6210        lodash.sortedUniqBy = sortedUniqBy;
6211        lodash.split = split;
6212        lodash.spread = spread;
6213        lodash.tail = tail;
6214        lodash.take = take2;
6215        lodash.takeRight = takeRight;
6216        lodash.takeRightWhile = takeRightWhile;
6217        lodash.takeWhile = takeWhile;
6218        lodash.tap = tap2;
6219        lodash.throttle = throttle;
6220        lodash.thru = thru;
6221        lodash.toArray = toArray;
6222        lodash.toPairs = toPairs;
6223        lodash.toPairsIn = toPairsIn;
6224        lodash.toPath = toPath;
6225        lodash.toPlainObject = toPlainObject;
6226        lodash.transform = transform;
6227        lodash.unary = unary;
6228        lodash.union = union;
6229        lodash.unionBy = unionBy;
6230        lodash.unionWith = unionWith;
6231        lodash.uniq = uniq;
6232        lodash.uniqBy = uniqBy;
6233        lodash.uniqWith = uniqWith;
6234        lodash.unset = unset;
6235        lodash.unzip = unzip;
6236        lodash.unzipWith = unzipWith;
6237        lodash.update = update2;
6238        lodash.updateWith = updateWith;
6239        lodash.values = values;
6240        lodash.valuesIn = valuesIn;
6241        lodash.without = without;
6242        lodash.words = words;
6243        lodash.wrap = wrap;
6244        lodash.xor = xor;
6245        lodash.xorBy = xorBy;
6246        lodash.xorWith = xorWith;
6247        lodash.zip = zip;
6248        lodash.zipObject = zipObject;
6249        lodash.zipObjectDeep = zipObjectDeep;
6250        lodash.zipWith = zipWith;
6251        lodash.entries = toPairs;
6252        lodash.entriesIn = toPairsIn;
6253        lodash.extend = assignIn;
6254        lodash.extendWith = assignInWith;
6255        mixin(lodash, lodash);
6256        lodash.add = add;
6257        lodash.attempt = attempt;
6258        lodash.camelCase = camelCase;
6259        lodash.capitalize = capitalize;
6260        lodash.ceil = ceil;
6261        lodash.clamp = clamp;
6262        lodash.clone = clone;
6263        lodash.cloneDeep = cloneDeep2;
6264        lodash.cloneDeepWith = cloneDeepWith;
6265        lodash.cloneWith = cloneWith;
6266        lodash.conformsTo = conformsTo;
6267        lodash.deburr = deburr;
6268        lodash.defaultTo = defaultTo;
6269        lodash.divide = divide;
6270        lodash.endsWith = endsWith;
6271        lodash.eq = eq;
6272        lodash.escape = escape3;
6273        lodash.escapeRegExp = escapeRegExp;
6274        lodash.every = every;
6275        lodash.find = find;
6276        lodash.findIndex = findIndex;
6277        lodash.findKey = findKey;
6278        lodash.findLast = findLast;
6279        lodash.findLastIndex = findLastIndex;
6280        lodash.findLastKey = findLastKey;
6281        lodash.floor = floor;
6282        lodash.forEach = forEach;
6283        lodash.forEachRight = forEachRight;
6284        lodash.forIn = forIn;
6285        lodash.forInRight = forInRight;
6286        lodash.forOwn = forOwn;
6287        lodash.forOwnRight = forOwnRight;
6288        lodash.get = get;
6289        lodash.gt = gt;
6290        lodash.gte = gte;
6291        lodash.has = has;
6292        lodash.hasIn = hasIn;
6293        lodash.head = head;
6294        lodash.identity = identity2;
6295        lodash.includes = includes;
6296        lodash.indexOf = indexOf;
6297        lodash.inRange = inRange;
6298        lodash.invoke = invoke;
6299        lodash.isArguments = isArguments;
6300        lodash.isArray = isArray2;
6301        lodash.isArrayBuffer = isArrayBuffer;
6302        lodash.isArrayLike = isArrayLike;
6303        lodash.isArrayLikeObject = isArrayLikeObject;
6304        lodash.isBoolean = isBoolean;
6305        lodash.isBuffer = isBuffer;
6306        lodash.isDate = isDate;
6307        lodash.isElement = isElement;
6308        lodash.isEmpty = isEmpty;
6309        lodash.isEqual = isEqual;
6310        lodash.isEqualWith = isEqualWith;
6311        lodash.isError = isError;
6312        lodash.isFinite = isFinite;
6313        lodash.isFunction = isFunction3;
6314        lodash.isInteger = isInteger;
6315        lodash.isLength = isLength;
6316        lodash.isMap = isMap;
6317        lodash.isMatch = isMatch;
6318        lodash.isMatchWith = isMatchWith;
6319        lodash.isNaN = isNaN2;
6320        lodash.isNative = isNative;
6321        lodash.isNil = isNil;
6322        lodash.isNull = isNull;
6323        lodash.isNumber = isNumber;
6324        lodash.isObject = isObject7;
6325        lodash.isObjectLike = isObjectLike;
6326        lodash.isPlainObject = isPlainObject;
6327        lodash.isRegExp = isRegExp;
6328        lodash.isSafeInteger = isSafeInteger;
6329        lodash.isSet = isSet;
6330        lodash.isString = isString2;
6331        lodash.isSymbol = isSymbol;
6332        lodash.isTypedArray = isTypedArray;
6333        lodash.isUndefined = isUndefined;
6334        lodash.isWeakMap = isWeakMap;
6335        lodash.isWeakSet = isWeakSet;
6336        lodash.join = join;
6337        lodash.kebabCase = kebabCase;
6338        lodash.last = last;
6339        lodash.lastIndexOf = lastIndexOf;
6340        lodash.lowerCase = lowerCase;
6341        lodash.lowerFirst = lowerFirst;
6342        lodash.lt = lt;
6343        lodash.lte = lte;
6344        lodash.max = max;
6345        lodash.maxBy = maxBy;
6346        lodash.mean = mean;
6347        lodash.meanBy = meanBy;
6348        lodash.min = min;
6349        lodash.minBy = minBy;
6350        lodash.stubArray = stubArray;
6351        lodash.stubFalse = stubFalse;
6352        lodash.stubObject = stubObject;
6353        lodash.stubString = stubString;
6354        lodash.stubTrue = stubTrue;
6355        lodash.multiply = multiply;
6356        lodash.nth = nth;
6357        lodash.noConflict = noConflict;
6358        lodash.noop = noop;
6359        lodash.now = now2;
6360        lodash.pad = pad2;
6361        lodash.padEnd = padEnd;
6362        lodash.padStart = padStart;
6363        lodash.parseInt = parseInt2;
6364        lodash.random = random;
6365        lodash.reduce = reduce;
6366        lodash.reduceRight = reduceRight;
6367        lodash.repeat = repeat;
6368        lodash.replace = replace;
6369        lodash.result = result;
6370        lodash.round = round;
6371        lodash.runInContext = runInContext2;
6372        lodash.sample = sample;
6373        lodash.size = size;
6374        lodash.snakeCase = snakeCase;
6375        lodash.some = some;
6376        lodash.sortedIndex = sortedIndex;
6377        lodash.sortedIndexBy = sortedIndexBy;
6378        lodash.sortedIndexOf = sortedIndexOf;
6379        lodash.sortedLastIndex = sortedLastIndex;
6380        lodash.sortedLastIndexBy = sortedLastIndexBy;
6381        lodash.sortedLastIndexOf = sortedLastIndexOf;
6382        lodash.startCase = startCase;
6383        lodash.startsWith = startsWith;
6384        lodash.subtract = subtract;
6385        lodash.sum = sum;
6386        lodash.sumBy = sumBy;
6387        lodash.template = template;
6388        lodash.times = times;
6389        lodash.toFinite = toFinite;
6390        lodash.toInteger = toInteger2;
6391        lodash.toLength = toLength;
6392        lodash.toLower = toLower;
6393        lodash.toNumber = toNumber;
6394        lodash.toSafeInteger = toSafeInteger;
6395        lodash.toString = toString;
6396        lodash.toUpper = toUpper;
6397        lodash.trim = trim;
6398        lodash.trimEnd = trimEnd;
6399        lodash.trimStart = trimStart;
6400        lodash.truncate = truncate;
6401        lodash.unescape = unescape;
6402        lodash.uniqueId = uniqueId;
6403        lodash.upperCase = upperCase;
6404        lodash.upperFirst = upperFirst;
6405        lodash.each = forEach;
6406        lodash.eachRight = forEachRight;
6407        lodash.first = head;
6408        mixin(lodash, function() {
6409          var source = {};
6410          baseForOwn(lodash, function(func, methodName) {
6411            if (!hasOwnProperty.call(lodash.prototype, methodName)) {
6412              source[methodName] = func;
6413            }
6414          });
6415          return source;
6416        }(), {
6417          "chain": false
6418        });
6419        lodash.VERSION = VERSION2;
6420        arrayEach(["bind", "bindKey", "curry", "curryRight", "partial", "partialRight"], function(methodName) {
6421          lodash[methodName].placeholder = lodash;
6422        });
6423        arrayEach(["drop", "take"], function(methodName, index) {
6424          LazyWrapper.prototype[methodName] = function(n) {
6425            n = n === undefined2 ? 1 : nativeMax(toInteger2(n), 0);
6426            var result2 = this.__filtered__ && !index ? new LazyWrapper(this) : this.clone();
6427            if (result2.__filtered__) {
6428              result2.__takeCount__ = nativeMin(n, result2.__takeCount__);
6429            } else {
6430              result2.__views__.push({
6431                "size": nativeMin(n, MAX_ARRAY_LENGTH),
6432                "type": methodName + (result2.__dir__ < 0 ? "Right" : "")
6433              });
6434            }
6435            return result2;
6436          };
6437          LazyWrapper.prototype[methodName + "Right"] = function(n) {
6438            return this.reverse()[methodName](n).reverse();
6439          };
6440        });
6441        arrayEach(["filter", "map", "takeWhile"], function(methodName, index) {
6442          var type = index + 1, isFilter = type == LAZY_FILTER_FLAG || type == LAZY_WHILE_FLAG;
6443          LazyWrapper.prototype[methodName] = function(iteratee2) {
6444            var result2 = this.clone();
6445            result2.__iteratees__.push({
6446              "iteratee": getIteratee(iteratee2, 3),
6447              "type": type
6448            });
6449            result2.__filtered__ = result2.__filtered__ || isFilter;
6450            return result2;
6451          };
6452        });
6453        arrayEach(["head", "last"], function(methodName, index) {
6454          var takeName = "take" + (index ? "Right" : "");
6455          LazyWrapper.prototype[methodName] = function() {
6456            return this[takeName](1).value()[0];
6457          };
6458        });
6459        arrayEach(["initial", "tail"], function(methodName, index) {
6460          var dropName = "drop" + (index ? "" : "Right");
6461          LazyWrapper.prototype[methodName] = function() {
6462            return this.__filtered__ ? new LazyWrapper(this) : this[dropName](1);
6463          };
6464        });
6465        LazyWrapper.prototype.compact = function() {
6466          return this.filter(identity2);
6467        };
6468        LazyWrapper.prototype.find = function(predicate) {
6469          return this.filter(predicate).head();
6470        };
6471        LazyWrapper.prototype.findLast = function(predicate) {
6472          return this.reverse().find(predicate);
6473        };
6474        LazyWrapper.prototype.invokeMap = baseRest(function(path2, args) {
6475          if (typeof path2 == "function") {
6476            return new LazyWrapper(this);
6477          }
6478          return this.map(function(value) {
6479            return baseInvoke(value, path2, args);
6480          });
6481        });
6482        LazyWrapper.prototype.reject = function(predicate) {
6483          return this.filter(negate(getIteratee(predicate)));
6484        };
6485        LazyWrapper.prototype.slice = function(start, end) {
6486          start = toInteger2(start);
6487          var result2 = this;
6488          if (result2.__filtered__ && (start > 0 || end < 0)) {
6489            return new LazyWrapper(result2);
6490          }
6491          if (start < 0) {
6492            result2 = result2.takeRight(-start);
6493          } else if (start) {
6494            result2 = result2.drop(start);
6495          }
6496          if (end !== undefined2) {
6497            end = toInteger2(end);
6498            result2 = end < 0 ? result2.dropRight(-end) : result2.take(end - start);
6499          }
6500          return result2;
6501        };
6502        LazyWrapper.prototype.takeRightWhile = function(predicate) {
6503          return this.reverse().takeWhile(predicate).reverse();
6504        };
6505        LazyWrapper.prototype.toArray = function() {
6506          return this.take(MAX_ARRAY_LENGTH);
6507        };
6508        baseForOwn(LazyWrapper.prototype, function(func, methodName) {
6509          var checkIteratee = /^(?:filter|find|map|reject)|While$/.test(methodName), isTaker = /^(?:head|last)$/.test(methodName), lodashFunc = lodash[isTaker ? "take" + (methodName == "last" ? "Right" : "") : methodName], retUnwrapped = isTaker || /^find/.test(methodName);
6510          if (!lodashFunc) {
6511            return;
6512          }
6513          lodash.prototype[methodName] = function() {
6514            var value = this.__wrapped__, args = isTaker ? [1] : arguments, isLazy = value instanceof LazyWrapper, iteratee2 = args[0], useLazy = isLazy || isArray2(value);
6515            var interceptor = function(value2) {
6516              var result3 = lodashFunc.apply(lodash, arrayPush([value2], args));
6517              return isTaker && chainAll ? result3[0] : result3;
6518            };
6519            if (useLazy && checkIteratee && typeof iteratee2 == "function" && iteratee2.length != 1) {
6520              isLazy = useLazy = false;
6521            }
6522            var chainAll = this.__chain__, isHybrid = !!this.__actions__.length, isUnwrapped = retUnwrapped && !chainAll, onlyLazy = isLazy && !isHybrid;
6523            if (!retUnwrapped && useLazy) {
6524              value = onlyLazy ? value : new LazyWrapper(this);
6525              var result2 = func.apply(value, args);
6526              result2.__actions__.push({
6527                "func": thru,
6528                "args": [interceptor],
6529                "thisArg": undefined2
6530              });
6531              return new LodashWrapper(result2, chainAll);
6532            }
6533            if (isUnwrapped && onlyLazy) {
6534              return func.apply(this, args);
6535            }
6536            result2 = this.thru(interceptor);
6537            return isUnwrapped ? isTaker ? result2.value()[0] : result2.value() : result2;
6538          };
6539        });
6540        arrayEach(["pop", "push", "shift", "sort", "splice", "unshift"], function(methodName) {
6541          var func = arrayProto[methodName], chainName = /^(?:push|sort|unshift)$/.test(methodName) ? "tap" : "thru", retUnwrapped = /^(?:pop|shift)$/.test(methodName);
6542          lodash.prototype[methodName] = function() {
6543            var args = arguments;
6544            if (retUnwrapped && !this.__chain__) {
6545              var value = this.value();
6546              return func.apply(isArray2(value) ? value : [], args);
6547            }
6548            return this[chainName](function(value2) {
6549              return func.apply(isArray2(value2) ? value2 : [], args);
6550            });
6551          };
6552        });
6553        baseForOwn(LazyWrapper.prototype, function(func, methodName) {
6554          var lodashFunc = lodash[methodName];
6555          if (lodashFunc) {
6556            var key = lodashFunc.name + "";
6557            if (!hasOwnProperty.call(realNames, key)) {
6558              realNames[key] = [];
6559            }
6560            realNames[key].push({
6561              "name": methodName,
6562              "func": lodashFunc
6563            });
6564          }
6565        });
6566        realNames[createHybrid(undefined2, WRAP_BIND_KEY_FLAG).name] = [{
6567          "name": "wrapper",
6568          "func": undefined2
6569        }];
6570        LazyWrapper.prototype.clone = lazyClone;
6571        LazyWrapper.prototype.reverse = lazyReverse;
6572        LazyWrapper.prototype.value = lazyValue;
6573        lodash.prototype.at = wrapperAt;
6574        lodash.prototype.chain = wrapperChain;
6575        lodash.prototype.commit = wrapperCommit;
6576        lodash.prototype.next = wrapperNext;
6577        lodash.prototype.plant = wrapperPlant;
6578        lodash.prototype.reverse = wrapperReverse;
6579        lodash.prototype.toJSON = lodash.prototype.valueOf = lodash.prototype.value = wrapperValue;
6580        lodash.prototype.first = lodash.prototype.head;
6581        if (symIterator) {
6582          lodash.prototype[symIterator] = wrapperToIterator;
6583        }
6584        return lodash;
6585      };
6586      var _2 = runInContext();
6587      if (typeof define == "function" && typeof define.amd == "object" && define.amd) {
6588        root._ = _2;
6589        define(function() {
6590          return _2;
6591        });
6592      } else if (freeModule) {
6593        (freeModule.exports = _2)._ = _2;
6594        freeExports._ = _2;
6595      } else {
6596        root._ = _2;
6597      }
6598    }).call(exports);
6599  }
6600});
6601
vendor: 466,618 bytes, lines 6602-15388
6602// node_modules/highcharts/highcharts.js
6603var require_highcharts = __commonJS({
6604  "node_modules/highcharts/highcharts.js"(exports, module) {
6605    "use strict";
6606    !/**
6607    * Highcharts JS v11.4.8 (2024-08-29)
6608    *
6609    * (c) 2009-2024 Torstein Honsi
6610    *
6611    * License: www.highcharts.com/license
6612    */
6613    function(t, e) {
6614      "object" == typeof module && module.exports ? (e.default = e, module.exports = t && t.document ? e(t) : e) : "function" == typeof define && define.amd ? define("highcharts/highcharts", function() {
6615        return e(t);
6616      }) : (t.Highcharts && t.Highcharts.error(16, true), t.Highcharts = e(t));
6617    }("undefined" != typeof window ? window : exports, function(t) {
6618      "use strict";
6619      var e = {};
6620      function i(e2, i2, s, r) {
6621        !e2.hasOwnProperty(i2) && (e2[i2] = r.apply(null, s), t && "function" == typeof CustomEvent && t.dispatchEvent(new CustomEvent("HighchartsModuleLoaded", {
6622          detail: {
6623            path: i2,
6624            module: e2[i2]
6625          }
6626        })));
6627      }
6628      return i(e, "Core/Globals.js", [], function() {
6629        var e2, i2;
6630        return (i2 = e2 || (e2 = {})).SVG_NS = "http://www.w3.org/2000/svg", i2.product = "Highcharts", i2.version = "11.4.8", i2.win = void 0 !== t ? t : {}, i2.doc = i2.win.document, i2.svg = i2.doc && i2.doc.createElementNS && !!i2.doc.createElementNS(i2.SVG_NS, "svg").createSVGRect, i2.userAgent = i2.win.navigator && i2.win.navigator.userAgent || "", i2.isChrome = i2.win.chrome, i2.isFirefox = -1 !== i2.userAgent.indexOf("Firefox"), i2.isMS = /(edge|msie|trident)/i.test(i2.userAgent) && !i2.win.opera, i2.isSafari = !i2.isChrome && -1 !== i2.userAgent.indexOf("Safari"), i2.isTouchDevice = /(Mobile|Android|Windows Phone)/.test(i2.userAgent), i2.isWebKit = -1 !== i2.userAgent.indexOf("AppleWebKit"), i2.deg2rad = 2 * Math.PI / 360, i2.hasBidiBug = i2.isFirefox && 4 > parseInt(i2.userAgent.split("Firefox/")[1], 10), i2.marginNames = ["plotTop", "marginRight", "marginBottom", "plotLeft"], i2.noop = function() {
6631        }, i2.supportsPassiveEvents = function() {
6632          let t2 = false;
6633          if (!i2.isMS) {
6634            let e3 = Object.defineProperty({}, "passive", {
6635              get: function() {
6636                t2 = true;
6637              }
6638            });
6639            i2.win.addEventListener && i2.win.removeEventListener && (i2.win.addEventListener("testPassive", i2.noop, e3), i2.win.removeEventListener("testPassive", i2.noop, e3));
6640          }
6641          return t2;
6642        }(), i2.charts = [], i2.composed = [], i2.dateFormats = {}, i2.seriesTypes = {}, i2.symbolSizes = {}, i2.chartCount = 0, e2;
6643      }), i(e, "Core/Utilities.js", [e["Core/Globals.js"]], function(t2) {
6644        let e2;
6645        let {
6646          charts: i2,
6647          doc: s,
6648          win: r
6649        } = t2;
6650        function o(e3, i3, s2, n2) {
6651          let a2 = i3 ? "Highcharts error" : "Highcharts warning";
6652          32 === e3 && (e3 = `${a2}: Deprecated member`);
6653          let h2 = p(e3), l2 = h2 ? `${a2} #${e3}: www.highcharts.com/errors/${e3}/` : e3.toString();
6654          if (void 0 !== n2) {
6655            let t3 = "";
6656            h2 && (l2 += "?"), C(n2, function(e4, i4) {
6657              t3 += `
6658 - ${i4}: ${e4}`, h2 && (l2 += encodeURI(i4) + "=" + encodeURI(e4));
6659            }), l2 += t3;
6660          }
6661          M(t2, "displayError", {
6662            chart: s2,
6663            code: e3,
6664            message: l2,
6665            params: n2
6666          }, function() {
6667            if (i3) throw Error(l2);
6668            r.console && -1 === o.messages.indexOf(l2) && console.warn(l2);
6669          }), o.messages.push(l2);
6670        }
6671        function n(t3, e3) {
6672          return parseInt(t3, e3 || 10);
6673        }
6674        function a(t3) {
6675          return "string" == typeof t3;
6676        }
6677        function h(t3) {
6678          let e3 = Object.prototype.toString.call(t3);
6679          return "[object Array]" === e3 || "[object Array Iterator]" === e3;
6680        }
6681        function l(t3, e3) {
6682          return !!t3 && "object" == typeof t3 && (!e3 || !h(t3));
6683        }
6684        function d(t3) {
6685          return l(t3) && "number" == typeof t3.nodeType;
6686        }
6687        function c(t3) {
6688          let e3 = t3 && t3.constructor;
6689          return !!(l(t3, true) && !d(t3) && e3 && e3.name && "Object" !== e3.name);
6690        }
6691        function p(t3) {
6692          return "number" == typeof t3 && !isNaN(t3) && t3 < 1 / 0 && t3 > -1 / 0;
6693        }
6694        function u11(t3) {
6695          return null != t3;
6696        }
6697        function g(t3, e3, i3) {
6698          let s2;
6699          let r2 = a(e3) && !u11(i3), o2 = (e4, i4) => {
6700            u11(e4) ? t3.setAttribute(i4, e4) : r2 ? (s2 = t3.getAttribute(i4)) || "class" !== i4 || (s2 = t3.getAttribute(i4 + "Name")) : t3.removeAttribute(i4);
6701          };
6702          return a(e3) ? o2(i3, e3) : C(e3, o2), s2;
6703        }
6704        function f(t3) {
6705          return h(t3) ? t3 : [t3];
6706        }
6707        function m(t3, e3) {
6708          let i3;
6709          for (i3 in t3 || (t3 = {}), e3) t3[i3] = e3[i3];
6710          return t3;
6711        }
6712        function x() {
6713          let t3 = arguments, e3 = t3.length;
6714          for (let i3 = 0; i3 < e3; i3++) {
6715            let e4 = t3[i3];
6716            if (null != e4) return e4;
6717          }
6718        }
6719        function y(t3, e3) {
6720          m(t3.style, e3);
6721        }
6722        function b(t3) {
6723          return Math.pow(10, Math.floor(Math.log(t3) / Math.LN10));
6724        }
6725        function v(t3, e3) {
6726          return t3 > 1e14 ? t3 : parseFloat(t3.toPrecision(e3 || 14));
6727        }
6728        (o || (o = {})).messages = [], Math.easeInOutSine = function(t3) {
6729          return -0.5 * (Math.cos(Math.PI * t3) - 1);
6730        };
6731        let S2 = Array.prototype.find ? function(t3, e3) {
6732          return t3.find(e3);
6733        } : function(t3, e3) {
6734          let i3;
6735          let s2 = t3.length;
6736          for (i3 = 0; i3 < s2; i3++) if (e3(t3[i3], i3)) return t3[i3];
6737        };
6738        function C(t3, e3, i3) {
6739          for (let s2 in t3) Object.hasOwnProperty.call(t3, s2) && e3.call(i3 || t3[s2], t3[s2], s2, t3);
6740        }
6741        function k(t3, e3, i3) {
6742          function s2(e4, i4) {
6743            let s3 = t3.removeEventListener;
6744            s3 && s3.call(t3, e4, i4, false);
6745          }
6746          function r2(i4) {
6747            let r3, o3;
6748            t3.nodeName && (e3 ? (r3 = {})[e3] = true : r3 = i4, C(r3, function(t4, e4) {
6749              if (i4[e4]) for (o3 = i4[e4].length; o3--; ) s2(e4, i4[e4][o3].fn);
6750            }));
6751          }
6752          let o2 = "function" == typeof t3 && t3.prototype || t3;
6753          if (Object.hasOwnProperty.call(o2, "hcEvents")) {
6754            let t4 = o2.hcEvents;
6755            if (e3) {
6756              let o3 = t4[e3] || [];
6757              i3 ? (t4[e3] = o3.filter(function(t5) {
6758                return i3 !== t5.fn;
6759              }), s2(e3, i3)) : (r2(t4), t4[e3] = []);
6760            } else r2(t4), delete o2.hcEvents;
6761          }
6762        }
6763        function M(e3, i3, r2, o2) {
6764          if (r2 = r2 || {}, s.createEvent && (e3.dispatchEvent || e3.fireEvent && e3 !== t2)) {
6765            let t3 = s.createEvent("Events");
6766            t3.initEvent(i3, true, true), r2 = m(t3, r2), e3.dispatchEvent ? e3.dispatchEvent(r2) : e3.fireEvent(i3, r2);
6767          } else if (e3.hcEvents) {
6768            r2.target || m(r2, {
6769              preventDefault: function() {
6770                r2.defaultPrevented = true;
6771              },
6772              target: e3,
6773              type: i3
6774            });
6775            let t3 = [], s2 = e3, o3 = false;
6776            for (; s2.hcEvents; ) Object.hasOwnProperty.call(s2, "hcEvents") && s2.hcEvents[i3] && (t3.length && (o3 = true), t3.unshift.apply(t3, s2.hcEvents[i3])), s2 = Object.getPrototypeOf(s2);
6777            o3 && t3.sort((t4, e4) => t4.order - e4.order), t3.forEach((t4) => {
6778              false === t4.fn.call(e3, r2) && r2.preventDefault();
6779            });
6780          }
6781          o2 && !r2.defaultPrevented && o2.call(e3, r2);
6782        }
6783        C({
6784          map: "map",
6785          each: "forEach",
6786          grep: "filter",
6787          reduce: "reduce",
6788          some: "some"
6789        }, function(e3, i3) {
6790          t2[i3] = function(t3) {
6791            return o(32, false, void 0, {
6792              [`Highcharts.${i3}`]: `use Array.${e3}`
6793            }), Array.prototype[e3].apply(t3, [].slice.call(arguments, 1));
6794          };
6795        });
6796        let w = function() {
6797          let t3 = Math.random().toString(36).substring(2, 9) + "-", i3 = 0;
6798          return function() {
6799            return "highcharts-" + (e2 ? "" : t3) + i3++;
6800          };
6801        }();
6802        return r.jQuery && (r.jQuery.fn.highcharts = function() {
6803          let e3 = [].slice.call(arguments);
6804          if (this[0]) return e3[0] ? (new t2[a(e3[0]) ? e3.shift() : "Chart"](this[0], e3[0], e3[1]), this) : i2[g(this[0], "data-highcharts-chart")];
6805        }), {
6806          addEvent: function(e3, i3, s2, r2 = {}) {
6807            let o2 = "function" == typeof e3 && e3.prototype || e3;
6808            Object.hasOwnProperty.call(o2, "hcEvents") || (o2.hcEvents = {});
6809            let n2 = o2.hcEvents;
6810            t2.Point && e3 instanceof t2.Point && e3.series && e3.series.chart && (e3.series.chart.runTrackerClick = true);
6811            let a2 = e3.addEventListener;
6812            a2 && a2.call(e3, i3, s2, !!t2.supportsPassiveEvents && {
6813              passive: void 0 === r2.passive ? -1 !== i3.indexOf("touch") : r2.passive,
6814              capture: false
6815            }), n2[i3] || (n2[i3] = []);
6816            let h2 = {
6817              fn: s2,
6818              order: "number" == typeof r2.order ? r2.order : 1 / 0
6819            };
6820            return n2[i3].push(h2), n2[i3].sort((t3, e4) => t3.order - e4.order), function() {
6821              k(e3, i3, s2);
6822            };
6823          },
6824          arrayMax: function(t3) {
6825            let e3 = t3.length, i3 = t3[0];
6826            for (; e3--; ) t3[e3] > i3 && (i3 = t3[e3]);
6827            return i3;
6828          },
6829          arrayMin: function(t3) {
6830            let e3 = t3.length, i3 = t3[0];
6831            for (; e3--; ) t3[e3] < i3 && (i3 = t3[e3]);
6832            return i3;
6833          },
6834          attr: g,
6835          clamp: function(t3, e3, i3) {
6836            return t3 > e3 ? t3 < i3 ? t3 : i3 : e3;
6837          },
6838          clearTimeout: function(t3) {
6839            u11(t3) && clearTimeout(t3);
6840          },
6841          correctFloat: v,
6842          createElement: function(t3, e3, i3, r2, o2) {
6843            let n2 = s.createElement(t3);
6844            return e3 && m(n2, e3), o2 && y(n2, {
6845              padding: "0",
6846              border: "none",
6847              margin: "0"
6848            }), i3 && y(n2, i3), r2 && r2.appendChild(n2), n2;
6849          },
6850          crisp: (t3, e3 = 0, i3) => {
6851            let s2 = e3 % 2 / 2, r2 = i3 ? -1 : 1;
6852            return (Math.round(t3 * r2 - s2) + s2) * r2;
6853          },
6854          css: y,
6855          defined: u11,
6856          destroyObjectProperties: function(t3, e3, i3) {
6857            C(t3, function(s2, r2) {
6858              s2 !== e3 && s2?.destroy && s2.destroy(), (s2?.destroy || !i3) && delete t3[r2];
6859            });
6860          },
6861          diffObjects: function(t3, e3, i3, s2) {
6862            let r2 = {};
6863            return function t4(e4, r3, o2, n2) {
6864              let a2 = i3 ? r3 : e4;
6865              C(e4, function(i4, d2) {
6866                if (!n2 && s2 && s2.indexOf(d2) > -1 && r3[d2]) {
6867                  i4 = f(i4), o2[d2] = [];
6868                  for (let e5 = 0; e5 < Math.max(i4.length, r3[d2].length); e5++) r3[d2][e5] && (void 0 === i4[e5] ? o2[d2][e5] = r3[d2][e5] : (o2[d2][e5] = {}, t4(i4[e5], r3[d2][e5], o2[d2][e5], n2 + 1)));
6869                } else l(i4, true) && !i4.nodeType ? (o2[d2] = h(i4) ? [] : {}, t4(i4, r3[d2] || {}, o2[d2], n2 + 1), 0 !== Object.keys(o2[d2]).length || "colorAxis" === d2 && 0 === n2 || delete o2[d2]) : (e4[d2] !== r3[d2] || d2 in e4 && !(d2 in r3)) && "__proto__" !== d2 && "constructor" !== d2 && (o2[d2] = a2[d2]);
6870              });
6871            }(t3, e3, r2, 0), r2;
6872          },
6873          discardElement: function(t3) {
6874            t3 && t3.parentElement && t3.parentElement.removeChild(t3);
6875          },
6876          erase: function(t3, e3) {
6877            let i3 = t3.length;
6878            for (; i3--; ) if (t3[i3] === e3) {
6879              t3.splice(i3, 1);
6880              break;
6881            }
6882          },
6883          error: o,
6884          extend: m,
6885          extendClass: function(t3, e3) {
6886            let i3 = function() {
6887            };
6888            return i3.prototype = new t3(), m(i3.prototype, e3), i3;
6889          },
6890          find: S2,
6891          fireEvent: M,
6892          getClosestDistance: function(t3, e3) {
6893            let i3, s2, r2, o2;
6894            let n2 = !e3;
6895            return t3.forEach((t4) => {
6896              if (t4.length > 1) for (o2 = s2 = t4.length - 1; o2 > 0; o2--) (r2 = t4[o2] - t4[o2 - 1]) < 0 && !n2 ? (e3?.(), e3 = void 0) : r2 && (void 0 === i3 || r2 < i3) && (i3 = r2);
6897            }), i3;
6898          },
6899          getMagnitude: b,
6900          getNestedProperty: function(t3, e3) {
6901            let i3 = t3.split(".");
6902            for (; i3.length && u11(e3); ) {
6903              let t4 = i3.shift();
6904              if (void 0 === t4 || "__proto__" === t4) return;
6905              if ("this" === t4) {
6906                let t5;
6907                return l(e3) && (t5 = e3["@this"]), t5 ?? e3;
6908              }
6909              let s2 = e3[t4];
6910              if (!u11(s2) || "function" == typeof s2 || "number" == typeof s2.nodeType || s2 === r) return;
6911              e3 = s2;
6912            }
6913            return e3;
6914          },
6915          getStyle: function t3(e3, i3, s2) {
6916            let o2;
6917            if ("width" === i3) {
6918              let i4 = Math.min(e3.offsetWidth, e3.scrollWidth), s3 = e3.getBoundingClientRect && e3.getBoundingClientRect().width;
6919              return s3 < i4 && s3 >= i4 - 1 && (i4 = Math.floor(s3)), Math.max(0, i4 - (t3(e3, "padding-left", true) || 0) - (t3(e3, "padding-right", true) || 0));
6920            }
6921            if ("height" === i3) return Math.max(0, Math.min(e3.offsetHeight, e3.scrollHeight) - (t3(e3, "padding-top", true) || 0) - (t3(e3, "padding-bottom", true) || 0));
6922            let a2 = r.getComputedStyle(e3, void 0);
6923            return a2 && (o2 = a2.getPropertyValue(i3), x(s2, "opacity" !== i3) && (o2 = n(o2))), o2;
6924          },
6925          inArray: function(t3, e3, i3) {
6926            return o(32, false, void 0, {
6927              "Highcharts.inArray": "use Array.indexOf"
6928            }), e3.indexOf(t3, i3);
6929          },
6930          insertItem: function(t3, e3) {
6931            let i3;
6932            let s2 = t3.options.index, r2 = e3.length;
6933            for (i3 = t3.options.isInternal ? r2 : 0; i3 < r2 + 1; i3++) if (!e3[i3] || p(s2) && s2 < x(e3[i3].options.index, e3[i3]._i) || e3[i3].options.isInternal) {
6934              e3.splice(i3, 0, t3);
6935              break;
6936            }
6937            return i3;
6938          },
6939          isArray: h,
6940          isClass: c,
6941          isDOMElement: d,
6942          isFunction: function(t3) {
6943            return "function" == typeof t3;
6944          },
6945          isNumber: p,
6946          isObject: l,
6947          isString: a,
6948          keys: function(t3) {
6949            return o(32, false, void 0, {
6950              "Highcharts.keys": "use Object.keys"
6951            }), Object.keys(t3);
6952          },
6953          merge: function() {
6954            let t3, e3 = arguments, i3 = {}, s2 = function(t4, e4) {
6955              return "object" != typeof t4 && (t4 = {}), C(e4, function(i4, r3) {
6956                "__proto__" !== r3 && "constructor" !== r3 && (!l(i4, true) || c(i4) || d(i4) ? t4[r3] = e4[r3] : t4[r3] = s2(t4[r3] || {}, i4));
6957              }), t4;
6958            };
6959            true === e3[0] && (i3 = e3[1], e3 = Array.prototype.slice.call(e3, 2));
6960            let r2 = e3.length;
6961            for (t3 = 0; t3 < r2; t3++) i3 = s2(i3, e3[t3]);
6962            return i3;
6963          },
6964          normalizeTickInterval: function(t3, e3, i3, s2, r2) {
6965            let o2, n2 = t3;
6966            i3 = x(i3, b(t3));
6967            let a2 = t3 / i3;
6968            for (!e3 && (e3 = r2 ? [1, 1.2, 1.5, 2, 2.5, 3, 4, 5, 6, 8, 10] : [1, 2, 2.5, 5, 10], false === s2 && (1 === i3 ? e3 = e3.filter(function(t4) {
6969              return t4 % 1 == 0;
6970            }) : i3 <= 0.1 && (e3 = [1 / i3]))), o2 = 0; o2 < e3.length && (n2 = e3[o2], (!r2 || !(n2 * i3 >= t3)) && (r2 || !(a2 <= (e3[o2] + (e3[o2 + 1] || e3[o2])) / 2))); o2++) ;
6971            return v(n2 * i3, -Math.round(Math.log(1e-3) / Math.LN10));
6972          },
6973          objectEach: C,
6974          offset: function(t3) {
6975            let e3 = s.documentElement, i3 = t3.parentElement || t3.parentNode ? t3.getBoundingClientRect() : {
6976              top: 0,
6977              left: 0,
6978              width: 0,
6979              height: 0
6980            };
6981            return {
6982              top: i3.top + (r.pageYOffset || e3.scrollTop) - (e3.clientTop || 0),
6983              left: i3.left + (r.pageXOffset || e3.scrollLeft) - (e3.clientLeft || 0),
6984              width: i3.width,
6985              height: i3.height
6986            };
6987          },
6988          pad: function(t3, e3, i3) {
6989            return Array((e3 || 2) + 1 - String(t3).replace("-", "").length).join(i3 || "0") + t3;
6990          },
6991          pick: x,
6992          pInt: n,
6993          pushUnique: function(t3, e3) {
6994            return 0 > t3.indexOf(e3) && !!t3.push(e3);
6995          },
6996          relativeLength: function(t3, e3, i3) {
6997            return /%$/.test(t3) ? e3 * parseFloat(t3) / 100 + (i3 || 0) : parseFloat(t3);
6998          },
6999          removeEvent: k,
7000          replaceNested: function(t3, ...e3) {
7001            let i3, s2;
7002            do
7003              for (s2 of (i3 = t3, e3)) t3 = t3.replace(s2[0], s2[1]);
7004            while (t3 !== i3);
7005            return t3;
7006          },
7007          splat: f,
7008          stableSort: function(t3, e3) {
7009            let i3, s2;
7010            let r2 = t3.length;
7011            for (s2 = 0; s2 < r2; s2++) t3[s2].safeI = s2;
7012            for (t3.sort(function(t4, s3) {
7013              return 0 === (i3 = e3(t4, s3)) ? t4.safeI - s3.safeI : i3;
7014            }), s2 = 0; s2 < r2; s2++) delete t3[s2].safeI;
7015          },
7016          syncTimeout: function(t3, e3, i3) {
7017            return e3 > 0 ? setTimeout(t3, e3, i3) : (t3.call(0, i3), -1);
7018          },
7019          timeUnits: {
7020            millisecond: 1,
7021            second: 1e3,
7022            minute: 6e4,
7023            hour: 36e5,
7024            day: 864e5,
7025            week: 6048e5,
7026            month: 24192e5,
7027            year: 314496e5
7028          },
7029          uniqueKey: w,
7030          useSerialIds: function(t3) {
7031            return e2 = x(t3, e2);
7032          },
7033          wrap: function(t3, e3, i3) {
7034            let s2 = t3[e3];
7035            t3[e3] = function() {
7036              let t4 = arguments, e4 = this;
7037              return i3.apply(this, [function() {
7038                return s2.apply(e4, arguments.length ? arguments : t4);
7039              }].concat([].slice.call(arguments)));
7040            };
7041          }
7042        };
7043      }), i(e, "Core/Chart/ChartDefaults.js", [], function() {
7044        return {
7045          alignThresholds: false,
7046          panning: {
7047            enabled: false,
7048            type: "x"
7049          },
7050          styledMode: false,
7051          borderRadius: 0,
7052          colorCount: 10,
7053          allowMutatingData: true,
7054          ignoreHiddenSeries: true,
7055          spacing: [10, 10, 15, 10],
7056          resetZoomButton: {
7057            theme: {},
7058            position: {}
7059          },
7060          reflow: true,
7061          type: "line",
7062          zooming: {
7063            singleTouch: false,
7064            resetButton: {
7065              theme: {
7066                zIndex: 6
7067              },
7068              position: {
7069                align: "right",
7070                x: -10,
7071                y: 10
7072              }
7073            }
7074          },
7075          width: null,
7076          height: null,
7077          borderColor: "#334eff",
7078          backgroundColor: "#ffffff",
7079          plotBorderColor: "#cccccc"
7080        };
7081      }), i(e, "Core/Color/Palettes.js", [], function() {
7082        return {
7083          colors: ["#2caffe", "#544fc5", "#00e272", "#fe6a35", "#6b8abc", "#d568fb", "#2ee0ca", "#fa4b42", "#feb56a", "#91e8e1"]
7084        };
7085      }), i(e, "Core/Time.js", [e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2) {
7086        let {
7087          win: i2
7088        } = t2, {
7089          defined: s,
7090          error: r,
7091          extend: o,
7092          isNumber: n,
7093          isObject: a,
7094          merge: h,
7095          objectEach: l,
7096          pad: d,
7097          pick: c,
7098          splat: p,
7099          timeUnits: u11
7100        } = e2, g = t2.isSafari && i2.Intl && i2.Intl.DateTimeFormat.prototype.formatRange, f = t2.isSafari && i2.Intl && !i2.Intl.DateTimeFormat.prototype.formatRange;
7101        class m {
7102          constructor(t3) {
7103            this.options = {}, this.useUTC = false, this.variableTimezone = false, this.Date = i2.Date, this.getTimezoneOffset = this.timezoneOffsetFunction(), this.update(t3);
7104          }
7105          get(t3, e3) {
7106            if (this.variableTimezone || this.timezoneOffset) {
7107              let i3 = e3.getTime(), s2 = i3 - this.getTimezoneOffset(e3);
7108              e3.setTime(s2);
7109              let r2 = e3["getUTC" + t3]();
7110              return e3.setTime(i3), r2;
7111            }
7112            return this.useUTC ? e3["getUTC" + t3]() : e3["get" + t3]();
7113          }
7114          set(t3, e3, i3) {
7115            if (this.variableTimezone || this.timezoneOffset) {
7116              if ("Milliseconds" === t3 || "Seconds" === t3 || "Minutes" === t3 && this.getTimezoneOffset(e3) % 36e5 == 0) return e3["setUTC" + t3](i3);
7117              let s2 = this.getTimezoneOffset(e3), r2 = e3.getTime() - s2;
7118              e3.setTime(r2), e3["setUTC" + t3](i3);
7119              let o2 = this.getTimezoneOffset(e3);
7120              return r2 = e3.getTime() + o2, e3.setTime(r2);
7121            }
7122            return this.useUTC || g && "FullYear" === t3 ? e3["setUTC" + t3](i3) : e3["set" + t3](i3);
7123          }
7124          update(t3 = {}) {
7125            let e3 = c(t3.useUTC, true);
7126            this.options = t3 = h(true, this.options, t3), this.Date = t3.Date || i2.Date || Date, this.useUTC = e3, this.timezoneOffset = e3 && t3.timezoneOffset || void 0, this.getTimezoneOffset = this.timezoneOffsetFunction(), this.variableTimezone = e3 && !!(t3.getTimezoneOffset || t3.timezone);
7127          }
7128          makeTime(t3, e3, i3, s2, r2, o2) {
7129            let n2, a2, h2;
7130            return this.useUTC ? (n2 = this.Date.UTC.apply(0, arguments), a2 = this.getTimezoneOffset(n2), n2 += a2, a2 !== (h2 = this.getTimezoneOffset(n2)) ? n2 += h2 - a2 : a2 - 36e5 !== this.getTimezoneOffset(n2 - 36e5) || f || (n2 -= 36e5)) : n2 = new this.Date(t3, e3, c(i3, 1), c(s2, 0), c(r2, 0), c(o2, 0)).getTime(), n2;
7131          }
7132          timezoneOffsetFunction() {
7133            let t3 = this, e3 = this.options, i3 = e3.getTimezoneOffset;
7134            return this.useUTC ? e3.timezone ? (t4) => {
7135              try {
7136                let i4 = `shortOffset,${e3.timezone || ""}`, [s2, r2, o2, a2, h2 = 0] = (m.formatCache[i4] = m.formatCache[i4] || Intl.DateTimeFormat("en", {
7137                  timeZone: e3.timezone,
7138                  timeZoneName: "shortOffset"
7139                })).format(t4).split(/(GMT|:)/).map(Number), l2 = -(36e5 * (o2 + h2 / 60));
7140                if (n(l2)) return l2;
7141              } catch (t5) {
7142                r(34);
7143              }
7144              return 0;
7145            } : this.useUTC && i3 ? (t4) => 6e4 * i3(t4.valueOf()) : () => 6e4 * (t3.timezoneOffset || 0) : (t4) => 6e4 * new Date(t4.toString()).getTimezoneOffset();
7146          }
7147          dateFormat(e3, i3, r2) {
7148            if (!s(i3) || isNaN(i3)) return t2.defaultOptions.lang && t2.defaultOptions.lang.invalidDate || "";
7149            e3 = c(e3, "%Y-%m-%d %H:%M:%S");
7150            let n2 = this, a2 = new this.Date(i3), h2 = this.get("Hours", a2), p2 = this.get("Day", a2), u12 = this.get("Date", a2), g2 = this.get("Month", a2), f2 = this.get("FullYear", a2), m2 = t2.defaultOptions.lang, x = m2 && m2.weekdays, y = m2 && m2.shortWeekdays;
7151            return l(o({
7152              a: y ? y[p2] : x[p2].substr(0, 3),
7153              A: x[p2],
7154              d: d(u12),
7155              e: d(u12, 2, " "),
7156              w: p2,
7157              b: m2.shortMonths[g2],
7158              B: m2.months[g2],
7159              m: d(g2 + 1),
7160              o: g2 + 1,
7161              y: f2.toString().substr(2, 2),
7162              Y: f2,
7163              H: d(h2),
7164              k: h2,
7165              I: d(h2 % 12 || 12),
7166              l: h2 % 12 || 12,
7167              M: d(this.get("Minutes", a2)),
7168              p: h2 < 12 ? "AM" : "PM",
7169              P: h2 < 12 ? "am" : "pm",
7170              S: d(this.get("Seconds", a2)),
7171              L: d(Math.floor(i3 % 1e3), 3)
7172            }, t2.dateFormats), function(t3, s2) {
7173              for (; -1 !== e3.indexOf("%" + s2); ) e3 = e3.replace("%" + s2, "function" == typeof t3 ? t3.call(n2, i3) : t3);
7174            }), r2 ? e3.substr(0, 1).toUpperCase() + e3.substr(1) : e3;
7175          }
7176          resolveDTLFormat(t3) {
7177            return a(t3, true) ? t3 : {
7178              main: (t3 = p(t3))[0],
7179              from: t3[1],
7180              to: t3[2]
7181            };
7182          }
7183          getTimeTicks(t3, e3, i3, r2) {
7184            let n2, a2, h2, l2;
7185            let d2 = this, p2 = d2.Date, g2 = [], f2 = {}, m2 = new p2(e3), x = t3.unitRange, y = t3.count || 1;
7186            if (r2 = c(r2, 1), s(e3)) {
7187              d2.set("Milliseconds", m2, x >= u11.second ? 0 : y * Math.floor(d2.get("Milliseconds", m2) / y)), x >= u11.second && d2.set("Seconds", m2, x >= u11.minute ? 0 : y * Math.floor(d2.get("Seconds", m2) / y)), x >= u11.minute && d2.set("Minutes", m2, x >= u11.hour ? 0 : y * Math.floor(d2.get("Minutes", m2) / y)), x >= u11.hour && d2.set("Hours", m2, x >= u11.day ? 0 : y * Math.floor(d2.get("Hours", m2) / y)), x >= u11.day && d2.set("Date", m2, x >= u11.month ? 1 : Math.max(1, y * Math.floor(d2.get("Date", m2) / y))), x >= u11.month && (d2.set("Month", m2, x >= u11.year ? 0 : y * Math.floor(d2.get("Month", m2) / y)), a2 = d2.get("FullYear", m2)), x >= u11.year && (a2 -= a2 % y, d2.set("FullYear", m2, a2)), x === u11.week && (l2 = d2.get("Day", m2), d2.set("Date", m2, d2.get("Date", m2) - l2 + r2 + (l2 < r2 ? -7 : 0))), a2 = d2.get("FullYear", m2);
7188              let t4 = d2.get("Month", m2), o2 = d2.get("Date", m2), c2 = d2.get("Hours", m2);
7189              e3 = m2.getTime(), (d2.variableTimezone || !d2.useUTC) && s(i3) && (h2 = i3 - e3 > 4 * u11.month || d2.getTimezoneOffset(e3) !== d2.getTimezoneOffset(i3));
7190              let p3 = m2.getTime();
7191              for (n2 = 1; p3 < i3; ) g2.push(p3), x === u11.year ? p3 = d2.makeTime(a2 + n2 * y, 0) : x === u11.month ? p3 = d2.makeTime(a2, t4 + n2 * y) : h2 && (x === u11.day || x === u11.week) ? p3 = d2.makeTime(a2, t4, o2 + n2 * y * (x === u11.day ? 1 : 7)) : h2 && x === u11.hour && y > 1 ? p3 = d2.makeTime(a2, t4, o2, c2 + n2 * y) : p3 += x * y, n2++;
7192              g2.push(p3), x <= u11.hour && g2.length < 1e4 && g2.forEach(function(t5) {
7193                t5 % 18e5 == 0 && "000000000" === d2.dateFormat("%H%M%S%L", t5) && (f2[t5] = "day");
7194              });
7195            }
7196            return g2.info = o(t3, {
7197              higherRanks: f2,
7198              totalRange: x * y
7199            }), g2;
7200          }
7201          getDateFormat(t3, e3, i3, s2) {
7202            let r2 = this.dateFormat("%m-%d %H:%M:%S.%L", e3), o2 = "01-01 00:00:00.000", n2 = {
7203              millisecond: 15,
7204              second: 12,
7205              minute: 9,
7206              hour: 6,
7207              day: 3
7208            }, a2 = "millisecond", h2 = a2;
7209            for (a2 in u11) {
7210              if (t3 === u11.week && +this.dateFormat("%w", e3) === i3 && r2.substr(6) === o2.substr(6)) {
7211                a2 = "week";
7212                break;
7213              }
7214              if (u11[a2] > t3) {
7215                a2 = h2;
7216                break;
7217              }
7218              if (n2[a2] && r2.substr(n2[a2]) !== o2.substr(n2[a2])) break;
7219              "week" !== a2 && (h2 = a2);
7220            }
7221            return this.resolveDTLFormat(s2[a2]).main;
7222          }
7223        }
7224        return m.formatCache = {}, m;
7225      }), i(e, "Core/Defaults.js", [e["Core/Chart/ChartDefaults.js"], e["Core/Globals.js"], e["Core/Color/Palettes.js"], e["Core/Time.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, r) {
7226        let {
7227          isTouchDevice: o
7228        } = e2, {
7229          fireEvent: n,
7230          merge: a
7231        } = r, h = {
7232          colors: i2.colors,
7233          symbols: ["circle", "diamond", "square", "triangle", "triangle-down"],
7234          lang: {
7235            loading: "Loading...",
7236            months: ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"],
7237            shortMonths: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"],
7238            weekdays: ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"],
7239            decimalPoint: ".",
7240            numericSymbols: ["k", "M", "G", "T", "P", "E"],
7241            resetZoom: "Reset zoom",
7242            resetZoomTitle: "Reset zoom level 1:1",
7243            thousandsSep: " "
7244          },
7245          global: {
7246            buttonTheme: {
7247              fill: "#f7f7f7",
7248              padding: 8,
7249              r: 2,
7250              stroke: "#cccccc",
7251              "stroke-width": 1,
7252              style: {
7253                color: "#333333",
7254                cursor: "pointer",
7255                fontSize: "0.8em",
7256                fontWeight: "normal"
7257              },
7258              states: {
7259                hover: {
7260                  fill: "#e6e6e6"
7261                },
7262                select: {
7263                  fill: "#e6e9ff",
7264                  style: {
7265                    color: "#000000",
7266                    fontWeight: "bold"
7267                  }
7268                },
7269                disabled: {
7270                  style: {
7271                    color: "#cccccc"
7272                  }
7273                }
7274              }
7275            }
7276          },
7277          time: {
7278            Date: void 0,
7279            getTimezoneOffset: void 0,
7280            timezone: void 0,
7281            timezoneOffset: 0,
7282            useUTC: true
7283          },
7284          chart: t2,
7285          title: {
7286            style: {
7287              color: "#333333",
7288              fontWeight: "bold"
7289            },
7290            text: "Chart title",
7291            align: "center",
7292            margin: 15,
7293            widthAdjust: -44
7294          },
7295          subtitle: {
7296            style: {
7297              color: "#666666",
7298              fontSize: "0.8em"
7299            },
7300            text: "",
7301            align: "center",
7302            widthAdjust: -44
7303          },
7304          caption: {
7305            margin: 15,
7306            style: {
7307              color: "#666666",
7308              fontSize: "0.8em"
7309            },
7310            text: "",
7311            align: "left",
7312            verticalAlign: "bottom"
7313          },
7314          plotOptions: {},
7315          legend: {
7316            enabled: true,
7317            align: "center",
7318            alignColumns: true,
7319            className: "highcharts-no-tooltip",
7320            events: {},
7321            layout: "horizontal",
7322            itemMarginBottom: 2,
7323            itemMarginTop: 2,
7324            labelFormatter: function() {
7325              return this.name;
7326            },
7327            borderColor: "#999999",
7328            borderRadius: 0,
7329            navigation: {
7330              style: {
7331                fontSize: "0.8em"
7332              },
7333              activeColor: "#0022ff",
7334              inactiveColor: "#cccccc"
7335            },
7336            itemStyle: {
7337              color: "#333333",
7338              cursor: "pointer",
7339              fontSize: "0.8em",
7340              textDecoration: "none",
7341              textOverflow: "ellipsis"
7342            },
7343            itemHoverStyle: {
7344              color: "#000000"
7345            },
7346            itemHiddenStyle: {
7347              color: "#666666",
7348              textDecoration: "line-through"
7349            },
7350            shadow: false,
7351            itemCheckboxStyle: {
7352              position: "absolute",
7353              width: "13px",
7354              height: "13px"
7355            },
7356            squareSymbol: true,
7357            symbolPadding: 5,
7358            verticalAlign: "bottom",
7359            x: 0,
7360            y: 0,
7361            title: {
7362              style: {
7363                fontSize: "0.8em",
7364                fontWeight: "bold"
7365              }
7366            }
7367          },
7368          loading: {
7369            labelStyle: {
7370              fontWeight: "bold",
7371              position: "relative",
7372              top: "45%"
7373            },
7374            style: {
7375              position: "absolute",
7376              backgroundColor: "#ffffff",
7377              opacity: 0.5,
7378              textAlign: "center"
7379            }
7380          },
7381          tooltip: {
7382            enabled: true,
7383            animation: {
7384              duration: 300,
7385              easing: (t3) => Math.sqrt(1 - Math.pow(t3 - 1, 2))
7386            },
7387            borderRadius: 3,
7388            dateTimeLabelFormats: {
7389              millisecond: "%A, %e %b, %H:%M:%S.%L",
7390              second: "%A, %e %b, %H:%M:%S",
7391              minute: "%A, %e %b, %H:%M",
7392              hour: "%A, %e %b, %H:%M",
7393              day: "%A, %e %b %Y",
7394              week: "Week from %A, %e %b %Y",
7395              month: "%B %Y",
7396              year: "%Y"
7397            },
7398            footerFormat: "",
7399            headerShape: "callout",
7400            hideDelay: 500,
7401            padding: 8,
7402            shape: "callout",
7403            shared: false,
7404            snap: o ? 25 : 10,
7405            headerFormat: '<span style="font-size: 0.8em">{point.key}</span><br/>',
7406            pointFormat: '<span style="color:{point.color}">\u25CF</span> {series.name}: <b>{point.y}</b><br/>',
7407            backgroundColor: "#ffffff",
7408            borderWidth: void 0,
7409            shadow: true,
7410            stickOnContact: false,
7411            style: {
7412              color: "#333333",
7413              cursor: "default",
7414              fontSize: "0.8em"
7415            },
7416            useHTML: false
7417          },
7418          credits: {
7419            enabled: true,
7420            href: "https://www.highcharts.com?credits",
7421            position: {
7422              align: "right",
7423              x: -10,
7424              verticalAlign: "bottom",
7425              y: -5
7426            },
7427            style: {
7428              cursor: "pointer",
7429              color: "#999999",
7430              fontSize: "0.6em"
7431            },
7432            text: "Highcharts.com"
7433          }
7434        };
7435        h.chart.styledMode = false;
7436        let l = new s(h.time);
7437        return {
7438          defaultOptions: h,
7439          defaultTime: l,
7440          getOptions: function() {
7441            return h;
7442          },
7443          setOptions: function(t3) {
7444            return n(e2, "setOptions", {
7445              options: t3
7446            }), a(true, h, t3), (t3.time || t3.global) && (e2.time ? e2.time.update(a(h.global, h.time, t3.global, t3.time)) : e2.time = l), h;
7447          }
7448        };
7449      }), i(e, "Core/Color/Color.js", [e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2) {
7450        let {
7451          isNumber: i2,
7452          merge: s,
7453          pInt: r
7454        } = e2;
7455        class o {
7456          static parse(t3) {
7457            return t3 ? new o(t3) : o.None;
7458          }
7459          constructor(e3) {
7460            let i3, s2, r2, n;
7461            this.rgba = [NaN, NaN, NaN, NaN], this.input = e3;
7462            let a = t2.Color;
7463            if (a && a !== o) return new a(e3);
7464            if ("object" == typeof e3 && void 0 !== e3.stops) this.stops = e3.stops.map((t3) => new o(t3[1]));
7465            else if ("string" == typeof e3) {
7466              if (this.input = e3 = o.names[e3.toLowerCase()] || e3, "#" === e3.charAt(0)) {
7467                let t3 = e3.length, i4 = parseInt(e3.substr(1), 16);
7468                7 === t3 ? s2 = [(16711680 & i4) >> 16, (65280 & i4) >> 8, 255 & i4, 1] : 4 === t3 && (s2 = [(3840 & i4) >> 4 | (3840 & i4) >> 8, (240 & i4) >> 4 | 240 & i4, (15 & i4) << 4 | 15 & i4, 1]);
7469              }
7470              if (!s2) for (r2 = o.parsers.length; r2-- && !s2; ) (i3 = (n = o.parsers[r2]).regex.exec(e3)) && (s2 = n.parse(i3));
7471            }
7472            s2 && (this.rgba = s2);
7473          }
7474          get(t3) {
7475            let e3 = this.input, r2 = this.rgba;
7476            if ("object" == typeof e3 && void 0 !== this.stops) {
7477              let i3 = s(e3);
7478              return i3.stops = [].slice.call(i3.stops), this.stops.forEach((e4, s2) => {
7479                i3.stops[s2] = [i3.stops[s2][0], e4.get(t3)];
7480              }), i3;
7481            }
7482            return r2 && i2(r2[0]) ? "rgb" !== t3 && (t3 || 1 !== r2[3]) ? "a" === t3 ? `${r2[3]}` : "rgba(" + r2.join(",") + ")" : "rgb(" + r2[0] + "," + r2[1] + "," + r2[2] + ")" : e3;
7483          }
7484          brighten(t3) {
7485            let e3 = this.rgba;
7486            if (this.stops) this.stops.forEach(function(e4) {
7487              e4.brighten(t3);
7488            });
7489            else if (i2(t3) && 0 !== t3) for (let i3 = 0; i3 < 3; i3++) e3[i3] += r(255 * t3), e3[i3] < 0 && (e3[i3] = 0), e3[i3] > 255 && (e3[i3] = 255);
7490            return this;
7491          }
7492          setOpacity(t3) {
7493            return this.rgba[3] = t3, this;
7494          }
7495          tweenTo(t3, e3) {
7496            let s2 = this.rgba, r2 = t3.rgba;
7497            if (!i2(s2[0]) || !i2(r2[0])) return t3.input || "none";
7498            let o2 = 1 !== r2[3] || 1 !== s2[3];
7499            return (o2 ? "rgba(" : "rgb(") + Math.round(r2[0] + (s2[0] - r2[0]) * (1 - e3)) + "," + Math.round(r2[1] + (s2[1] - r2[1]) * (1 - e3)) + "," + Math.round(r2[2] + (s2[2] - r2[2]) * (1 - e3)) + (o2 ? "," + (r2[3] + (s2[3] - r2[3]) * (1 - e3)) : "") + ")";
7500          }
7501        }
7502        return o.names = {
7503          white: "#ffffff",
7504          black: "#000000"
7505        }, o.parsers = [{
7506          regex: /rgba\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d?(?:\.\d+)?)\s*\)/,
7507          parse: function(t3) {
7508            return [r(t3[1]), r(t3[2]), r(t3[3]), parseFloat(t3[4], 10)];
7509          }
7510        }, {
7511          regex: /rgb\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)/,
7512          parse: function(t3) {
7513            return [r(t3[1]), r(t3[2]), r(t3[3]), 1];
7514          }
7515        }], o.None = new o(""), o;
7516      }), i(e, "Core/Animation/Fx.js", [e["Core/Color/Color.js"], e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
7517        let {
7518          parse: s
7519        } = t2, {
7520          win: r
7521        } = e2, {
7522          isNumber: o,
7523          objectEach: n
7524        } = i2;
7525        class a {
7526          constructor(t3, e3, i3) {
7527            this.pos = NaN, this.options = e3, this.elem = t3, this.prop = i3;
7528          }
7529          dSetter() {
7530            let t3 = this.paths, e3 = t3 && t3[0], i3 = t3 && t3[1], s2 = this.now || 0, r2 = [];
7531            if (1 !== s2 && e3 && i3) {
7532              if (e3.length === i3.length && s2 < 1) for (let t4 = 0; t4 < i3.length; t4++) {
7533                let n2 = e3[t4], a2 = i3[t4], h = [];
7534                for (let t5 = 0; t5 < a2.length; t5++) {
7535                  let e4 = n2[t5], i4 = a2[t5];
7536                  o(e4) && o(i4) && !("A" === a2[0] && (4 === t5 || 5 === t5)) ? h[t5] = e4 + s2 * (i4 - e4) : h[t5] = i4;
7537                }
7538                r2.push(h);
7539              }
7540              else r2 = i3;
7541            } else r2 = this.toD || [];
7542            this.elem.attr("d", r2, void 0, true);
7543          }
7544          update() {
7545            let t3 = this.elem, e3 = this.prop, i3 = this.now, s2 = this.options.step;
7546            this[e3 + "Setter"] ? this[e3 + "Setter"]() : t3.attr ? t3.element && t3.attr(e3, i3, null, true) : t3.style[e3] = i3 + this.unit, s2 && s2.call(t3, i3, this);
7547          }
7548          run(t3, e3, i3) {
7549            let s2 = this, o2 = s2.options, n2 = function(t4) {
7550              return !n2.stopped && s2.step(t4);
7551            }, h = r.requestAnimationFrame || function(t4) {
7552              setTimeout(t4, 13);
7553            }, l = function() {
7554              for (let t4 = 0; t4 < a.timers.length; t4++) a.timers[t4]() || a.timers.splice(t4--, 1);
7555              a.timers.length && h(l);
7556            };
7557            t3 !== e3 || this.elem["forceAnimate:" + this.prop] ? (this.startTime = +/* @__PURE__ */ new Date(), this.start = t3, this.end = e3, this.unit = i3, this.now = this.start, this.pos = 0, n2.elem = this.elem, n2.prop = this.prop, n2() && 1 === a.timers.push(n2) && h(l)) : (delete o2.curAnim[this.prop], o2.complete && 0 === Object.keys(o2.curAnim).length && o2.complete.call(this.elem));
7558          }
7559          step(t3) {
7560            let e3, i3;
7561            let s2 = +/* @__PURE__ */ new Date(), r2 = this.options, o2 = this.elem, a2 = r2.complete, h = r2.duration, l = r2.curAnim;
7562            return o2.attr && !o2.element ? e3 = false : t3 || s2 >= h + this.startTime ? (this.now = this.end, this.pos = 1, this.update(), l[this.prop] = true, i3 = true, n(l, function(t4) {
7563              true !== t4 && (i3 = false);
7564            }), i3 && a2 && a2.call(o2), e3 = false) : (this.pos = r2.easing((s2 - this.startTime) / h), this.now = this.start + (this.end - this.start) * this.pos, this.update(), e3 = true), e3;
7565          }
7566          initPath(t3, e3, i3) {
7567            let s2 = t3.startX, r2 = t3.endX, n2 = i3.slice(), a2 = t3.isArea, h = a2 ? 2 : 1, l = e3 && i3.length > e3.length && i3.hasStackedCliffs, d, c, p, u11, g = e3 && e3.slice();
7568            if (!g || l) return [n2, n2];
7569            function f(t4, e4) {
7570              for (; t4.length < c; ) {
7571                let i4 = t4[0], s3 = e4[c - t4.length];
7572                if (s3 && "M" === i4[0] && ("C" === s3[0] ? t4[0] = ["C", i4[1], i4[2], i4[1], i4[2], i4[1], i4[2]] : t4[0] = ["L", i4[1], i4[2]]), t4.unshift(i4), a2) {
7573                  let e5 = t4.pop();
7574                  t4.push(t4[t4.length - 1], e5);
7575                }
7576              }
7577            }
7578            function m(t4) {
7579              for (; t4.length < c; ) {
7580                let e4 = t4[Math.floor(t4.length / h) - 1].slice();
7581                if ("C" === e4[0] && (e4[1] = e4[5], e4[2] = e4[6]), a2) {
7582                  let i4 = t4[Math.floor(t4.length / h)].slice();
7583                  t4.splice(t4.length / 2, 0, e4, i4);
7584                } else t4.push(e4);
7585              }
7586            }
7587            if (s2 && r2 && r2.length) {
7588              for (p = 0; p < s2.length; p++) {
7589                if (s2[p] === r2[0]) {
7590                  d = p;
7591                  break;
7592                }
7593                if (s2[0] === r2[r2.length - s2.length + p]) {
7594                  d = p, u11 = true;
7595                  break;
7596                }
7597                if (s2[s2.length - 1] === r2[r2.length - s2.length + p]) {
7598                  d = s2.length - p;
7599                  break;
7600                }
7601              }
7602              void 0 === d && (g = []);
7603            }
7604            return g.length && o(d) && (c = n2.length + d * h, u11 ? (f(g, n2), m(n2)) : (f(n2, g), m(g))), [g, n2];
7605          }
7606          fillSetter() {
7607            a.prototype.strokeSetter.apply(this, arguments);
7608          }
7609          strokeSetter() {
7610            this.elem.attr(this.prop, s(this.start).tweenTo(s(this.end), this.pos), void 0, true);
7611          }
7612        }
7613        return a.timers = [], a;
7614      }), i(e, "Core/Animation/AnimationUtilities.js", [e["Core/Animation/Fx.js"], e["Core/Utilities.js"]], function(t2, e2) {
7615        let {
7616          defined: i2,
7617          getStyle: s,
7618          isArray: r,
7619          isNumber: o,
7620          isObject: n,
7621          merge: a,
7622          objectEach: h,
7623          pick: l
7624        } = e2;
7625        function d(t3) {
7626          return n(t3) ? a({
7627            duration: 500,
7628            defer: 0
7629          }, t3) : {
7630            duration: t3 ? 500 : 0,
7631            defer: 0
7632          };
7633        }
7634        function c(e3, i3) {
7635          let s2 = t2.timers.length;
7636          for (; s2--; ) t2.timers[s2].elem !== e3 || i3 && i3 !== t2.timers[s2].prop || (t2.timers[s2].stopped = true);
7637        }
7638        return {
7639          animate: function(e3, i3, l2) {
7640            let d2, p = "", u11, g, f;
7641            n(l2) || (f = arguments, l2 = {
7642              duration: f[2],
7643              easing: f[3],
7644              complete: f[4]
7645            }), o(l2.duration) || (l2.duration = 400), l2.easing = "function" == typeof l2.easing ? l2.easing : Math[l2.easing] || Math.easeInOutSine, l2.curAnim = a(i3), h(i3, function(o2, n2) {
7646              c(e3, n2), g = new t2(e3, l2, n2), u11 = void 0, "d" === n2 && r(i3.d) ? (g.paths = g.initPath(e3, e3.pathArray, i3.d), g.toD = i3.d, d2 = 0, u11 = 1) : e3.attr ? d2 = e3.attr(n2) : (d2 = parseFloat(s(e3, n2)) || 0, "opacity" !== n2 && (p = "px")), u11 || (u11 = o2), "string" == typeof u11 && u11.match("px") && (u11 = u11.replace(/px/g, "")), g.run(d2, u11, p);
7647            });
7648          },
7649          animObject: d,
7650          getDeferredAnimation: function(t3, e3, s2) {
7651            let r2 = d(e3), o2 = s2 ? [s2] : t3.series, a2 = 0, h2 = 0;
7652            return o2.forEach((t4) => {
7653              let s3 = d(t4.options.animation);
7654              a2 = n(e3) && i2(e3.defer) ? r2.defer : Math.max(a2, s3.duration + s3.defer), h2 = Math.min(r2.duration, s3.duration);
7655            }), t3.renderer.forExport && (a2 = 0), {
7656              defer: Math.max(0, a2 - h2),
7657              duration: Math.min(a2, h2)
7658            };
7659          },
7660          setAnimation: function(t3, e3) {
7661            e3.renderer.globalAnimation = l(t3, e3.options.chart.animation, true);
7662          },
7663          stop: c
7664        };
7665      }), i(e, "Core/Renderer/HTML/AST.js", [e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2) {
7666        let {
7667          SVG_NS: i2,
7668          win: s
7669        } = t2, {
7670          attr: r,
7671          createElement: o,
7672          css: n,
7673          error: a,
7674          isFunction: h,
7675          isString: l,
7676          objectEach: d,
7677          splat: c
7678        } = e2, {
7679          trustedTypes: p
7680        } = s, u11 = p && h(p.createPolicy) && p.createPolicy("highcharts", {
7681          createHTML: (t3) => t3
7682        }), g = u11 ? u11.createHTML("") : "", f = function() {
7683          try {
7684            return !!new DOMParser().parseFromString(g, "text/html");
7685          } catch (t3) {
7686            return false;
7687          }
7688        }();
7689        class m {
7690          static filterUserAttributes(t3) {
7691            return d(t3, (e3, i3) => {
7692              let s2 = true;
7693              -1 === m.allowedAttributes.indexOf(i3) && (s2 = false), -1 !== ["background", "dynsrc", "href", "lowsrc", "src"].indexOf(i3) && (s2 = l(e3) && m.allowedReferences.some((t4) => 0 === e3.indexOf(t4))), s2 || (a(33, false, void 0, {
7694                "Invalid attribute in config": `${i3}`
7695              }), delete t3[i3]), l(e3) && t3[i3] && (t3[i3] = e3.replace(/</g, "&lt;"));
7696            }), t3;
7697          }
7698          static parseStyle(t3) {
7699            return t3.split(";").reduce((t4, e3) => {
7700              let i3 = e3.split(":").map((t5) => t5.trim()), s2 = i3.shift();
7701              return s2 && i3.length && (t4[s2.replace(/-([a-z])/g, (t5) => t5[1].toUpperCase())] = i3.join(":")), t4;
7702            }, {});
7703          }
7704          static setElementHTML(t3, e3) {
7705            t3.innerHTML = m.emptyHTML, e3 && new m(e3).addToDOM(t3);
7706          }
7707          constructor(t3) {
7708            this.nodes = "string" == typeof t3 ? this.parseMarkup(t3) : t3;
7709          }
7710          addToDOM(e3) {
7711            return function e4(s2, o2) {
7712              let h2;
7713              return c(s2).forEach(function(s3) {
7714                let l2;
7715                let c2 = s3.tagName, p2 = s3.textContent ? t2.doc.createTextNode(s3.textContent) : void 0, u12 = m.bypassHTMLFiltering;
7716                if (c2) {
7717                  if ("#text" === c2) l2 = p2;
7718                  else if (-1 !== m.allowedTags.indexOf(c2) || u12) {
7719                    let a2 = "svg" === c2 ? i2 : o2.namespaceURI || i2, h3 = t2.doc.createElementNS(a2, c2), g2 = s3.attributes || {};
7720                    d(s3, function(t3, e5) {
7721                      "tagName" !== e5 && "attributes" !== e5 && "children" !== e5 && "style" !== e5 && "textContent" !== e5 && (g2[e5] = t3);
7722                    }), r(h3, u12 ? g2 : m.filterUserAttributes(g2)), s3.style && n(h3, s3.style), p2 && h3.appendChild(p2), e4(s3.children || [], h3), l2 = h3;
7723                  } else a(33, false, void 0, {
7724                    "Invalid tagName in config": c2
7725                  });
7726                }
7727                l2 && o2.appendChild(l2), h2 = l2;
7728              }), h2;
7729            }(this.nodes, e3);
7730          }
7731          parseMarkup(t3) {
7732            let e3;
7733            let i3 = [];
7734            if (t3 = t3.trim().replace(/ style=(["'])/g, " data-style=$1"), f) e3 = new DOMParser().parseFromString(u11 ? u11.createHTML(t3) : t3, "text/html");
7735            else {
7736              let i4 = o("div");
7737              i4.innerHTML = t3, e3 = {
7738                body: i4
7739              };
7740            }
7741            let s2 = (t4, e4) => {
7742              let i4 = t4.nodeName.toLowerCase(), r2 = {
7743                tagName: i4
7744              };
7745              "#text" === i4 && (r2.textContent = t4.textContent || "");
7746              let o2 = t4.attributes;
7747              if (o2) {
7748                let t5 = {};
7749                [].forEach.call(o2, (e5) => {
7750                  "data-style" === e5.name ? r2.style = m.parseStyle(e5.value) : t5[e5.name] = e5.value;
7751                }), r2.attributes = t5;
7752              }
7753              if (t4.childNodes.length) {
7754                let e5 = [];
7755                [].forEach.call(t4.childNodes, (t5) => {
7756                  s2(t5, e5);
7757                }), e5.length && (r2.children = e5);
7758              }
7759              e4.push(r2);
7760            };
7761            return [].forEach.call(e3.body.childNodes, (t4) => s2(t4, i3)), i3;
7762          }
7763        }
7764        return m.allowedAttributes = ["alt", "aria-controls", "aria-describedby", "aria-expanded", "aria-haspopup", "aria-hidden", "aria-label", "aria-labelledby", "aria-live", "aria-pressed", "aria-readonly", "aria-roledescription", "aria-selected", "class", "clip-path", "color", "colspan", "cx", "cy", "d", "dx", "dy", "disabled", "fill", "filterUnits", "flood-color", "flood-opacity", "height", "href", "id", "in", "in2", "markerHeight", "markerWidth", "offset", "opacity", "operator", "orient", "padding", "paddingLeft", "paddingRight", "patternUnits", "r", "radius", "refX", "refY", "role", "scope", "slope", "src", "startOffset", "stdDeviation", "stroke", "stroke-linecap", "stroke-width", "style", "tableValues", "result", "rowspan", "summary", "target", "tabindex", "text-align", "text-anchor", "textAnchor", "textLength", "title", "type", "valign", "width", "x", "x1", "x2", "xlink:href", "y", "y1", "y2", "zIndex"], m.allowedReferences = ["https://", "http://", "mailto:", "/", "../", "./", "#"], m.allowedTags = ["a", "abbr", "b", "br", "button", "caption", "circle", "clipPath", "code", "dd", "defs", "div", "dl", "dt", "em", "feComponentTransfer", "feComposite", "feDropShadow", "feFlood", "feFuncA", "feFuncB", "feFuncG", "feFuncR", "feGaussianBlur", "feMorphology", "feOffset", "feMerge", "feMergeNode", "filter", "h1", "h2", "h3", "h4", "h5", "h6", "hr", "i", "img", "li", "linearGradient", "marker", "ol", "p", "path", "pattern", "pre", "rect", "small", "span", "stop", "strong", "style", "sub", "sup", "svg", "table", "text", "textPath", "thead", "title", "tbody", "tspan", "td", "th", "tr", "u", "ul", "#text"], m.emptyHTML = g, m.bypassHTMLFiltering = false, m;
7765      }), i(e, "Core/Templating.js", [e["Core/Defaults.js"], e["Core/Utilities.js"]], function(t2, e2) {
7766        let {
7767          defaultOptions: i2,
7768          defaultTime: s
7769        } = t2, {
7770          extend: r,
7771          getNestedProperty: o,
7772          isArray: n,
7773          isNumber: a,
7774          isObject: h,
7775          pick: l,
7776          pInt: d
7777        } = e2, c = {
7778          add: (t3, e3) => t3 + e3,
7779          divide: (t3, e3) => 0 !== e3 ? t3 / e3 : "",
7780          eq: (t3, e3) => t3 == e3,
7781          each: function(t3) {
7782            let e3 = arguments[arguments.length - 1];
7783            return !!n(t3) && t3.map((i3, s2) => p(e3.body, r(h(i3) ? i3 : {
7784              "@this": i3
7785            }, {
7786              "@index": s2,
7787              "@first": 0 === s2,
7788              "@last": s2 === t3.length - 1
7789            }))).join("");
7790          },
7791          ge: (t3, e3) => t3 >= e3,
7792          gt: (t3, e3) => t3 > e3,
7793          if: (t3) => !!t3,
7794          le: (t3, e3) => t3 <= e3,
7795          lt: (t3, e3) => t3 < e3,
7796          multiply: (t3, e3) => t3 * e3,
7797          ne: (t3, e3) => t3 != e3,
7798          subtract: (t3, e3) => t3 - e3,
7799          unless: (t3) => !t3
7800        };
7801        function p(t3 = "", e3, r2) {
7802          let n2 = /\{([\w\:\.\,;\-\/<>%@"'’= #\(\)]+)\}/g, a2 = /\(([\w\:\.\,;\-\/<>%@"'= ]+)\)/g, h2 = [], d2 = /f$/, g = /\.(\d)/, f = i2.lang, m = r2 && r2.time || s, x = r2 && r2.numberFormatter || u11, y = (t4 = "") => {
7803            let i3;
7804            return "true" === t4 || "false" !== t4 && ((i3 = Number(t4)).toString() === t4 ? i3 : o(t4, e3));
7805          }, b, v, S2 = 0, C;
7806          for (; null !== (b = n2.exec(t3)); ) {
7807            let i3 = a2.exec(b[1]);
7808            i3 && (b = i3, C = true), v && v.isBlock || (v = {
7809              ctx: e3,
7810              expression: b[1],
7811              find: b[0],
7812              isBlock: "#" === b[1].charAt(0),
7813              start: b.index,
7814              startInner: b.index + b[0].length,
7815              length: b[0].length
7816            });
7817            let s2 = b[1].split(" ")[0].replace("#", "");
7818            c[s2] && (v.isBlock && s2 === v.fn && S2++, v.fn || (v.fn = s2));
7819            let r3 = "else" === b[1];
7820            if (v.isBlock && v.fn && (b[1] === `/${v.fn}` || r3)) {
7821              if (S2) !r3 && S2--;
7822              else {
7823                let e4 = v.startInner, i4 = t3.substr(e4, b.index - e4);
7824                void 0 === v.body ? (v.body = i4, v.startInner = b.index + b[0].length) : v.elseBody = i4, v.find += i4 + b[0], r3 || (h2.push(v), v = void 0);
7825              }
7826            } else v.isBlock || h2.push(v);
7827            if (i3 && !v?.isBlock) break;
7828          }
7829          return h2.forEach((i3) => {
7830            let s2, o2;
7831            let {
7832              body: n3,
7833              elseBody: a3,
7834              expression: h3,
7835              fn: u12
7836            } = i3;
7837            if (u12) {
7838              let t4 = [i3], l2 = h3.split(" ");
7839              for (o2 = c[u12].length; o2--; ) t4.unshift(y(l2[o2 + 1]));
7840              s2 = c[u12].apply(e3, t4), i3.isBlock && "boolean" == typeof s2 && (s2 = p(s2 ? n3 : a3, e3, r2));
7841            } else {
7842              let t4 = h3.split(":");
7843              if (s2 = y(t4.shift() || ""), t4.length && "number" == typeof s2) {
7844                let e4 = t4.join(":");
7845                if (d2.test(e4)) {
7846                  let t5 = parseInt((e4.match(g) || ["", "-1"])[1], 10);
7847                  null !== s2 && (s2 = x(s2, t5, f.decimalPoint, e4.indexOf(",") > -1 ? f.thousandsSep : ""));
7848                } else s2 = m.dateFormat(e4, s2);
7849              }
7850            }
7851            t3 = t3.replace(i3.find, l(s2, ""));
7852          }), C ? p(t3, e3, r2) : t3;
7853        }
7854        function u11(t3, e3, s2, r2) {
7855          let o2, n2;
7856          t3 = +t3 || 0, e3 = +e3;
7857          let h2 = i2.lang, c2 = (t3.toString().split(".")[1] || "").split("e")[0].length, p2 = t3.toString().split("e"), u12 = e3;
7858          -1 === e3 ? e3 = Math.min(c2, 20) : a(e3) ? e3 && p2[1] && p2[1] < 0 && ((n2 = e3 + +p2[1]) >= 0 ? (p2[0] = (+p2[0]).toExponential(n2).split("e")[0], e3 = n2) : (p2[0] = p2[0].split(".")[0] || 0, t3 = e3 < 20 ? (p2[0] * Math.pow(10, p2[1])).toFixed(e3) : 0, p2[1] = 0)) : e3 = 2;
7859          let g = (Math.abs(p2[1] ? p2[0] : t3) + Math.pow(10, -Math.max(e3, c2) - 1)).toFixed(e3), f = String(d(g)), m = f.length > 3 ? f.length % 3 : 0;
7860          return s2 = l(s2, h2.decimalPoint), r2 = l(r2, h2.thousandsSep), o2 = (t3 < 0 ? "-" : "") + (m ? f.substr(0, m) + r2 : ""), 0 > +p2[1] && !u12 ? o2 = "0" : o2 += f.substr(m).replace(/(\d{3})(?=\d)/g, "$1" + r2), e3 ? o2 += s2 + g.slice(-e3) : 0 == +o2 && (o2 = "0"), p2[1] && 0 != +o2 && (o2 += "e" + p2[1]), o2;
7861        }
7862        return {
7863          dateFormat: function(t3, e3, i3) {
7864            return s.dateFormat(t3, e3, i3);
7865          },
7866          format: p,
7867          helpers: c,
7868          numberFormat: u11
7869        };
7870      }), i(e, "Core/Renderer/RendererRegistry.js", [e["Core/Globals.js"]], function(t2) {
7871        var e2, i2;
7872        let s;
7873        return (i2 = e2 || (e2 = {})).rendererTypes = {}, i2.getRendererType = function(t3 = s) {
7874          return i2.rendererTypes[t3] || i2.rendererTypes[s];
7875        }, i2.registerRendererType = function(e3, r, o) {
7876          i2.rendererTypes[e3] = r, (!s || o) && (s = e3, t2.Renderer = r);
7877        }, e2;
7878      }), i(e, "Core/Renderer/RendererUtilities.js", [e["Core/Utilities.js"]], function(t2) {
7879        var e2;
7880        let {
7881          clamp: i2,
7882          pick: s,
7883          pushUnique: r,
7884          stableSort: o
7885        } = t2;
7886        return (e2 || (e2 = {})).distribute = function t3(e3, n, a) {
7887          let h = e3, l = h.reducedLen || n, d = (t4, e4) => t4.target - e4.target, c = [], p = e3.length, u11 = [], g = c.push, f, m, x, y = true, b, v, S2 = 0, C;
7888          for (f = p; f--; ) S2 += e3[f].size;
7889          if (S2 > l) {
7890            for (o(e3, (t4, e4) => (e4.rank || 0) - (t4.rank || 0)), x = (C = e3[0].rank === e3[e3.length - 1].rank) ? p / 2 : -1, m = C ? x : p - 1; x && S2 > l; ) b = e3[f = Math.floor(m)], r(u11, f) && (S2 -= b.size), m += x, C && m >= e3.length && (x /= 2, m = x);
7891            u11.sort((t4, e4) => e4 - t4).forEach((t4) => g.apply(c, e3.splice(t4, 1)));
7892          }
7893          for (o(e3, d), e3 = e3.map((t4) => ({
7894            size: t4.size,
7895            targets: [t4.target],
7896            align: s(t4.align, 0.5)
7897          })); y; ) {
7898            for (f = e3.length; f--; ) b = e3[f], v = (Math.min.apply(0, b.targets) + Math.max.apply(0, b.targets)) / 2, b.pos = i2(v - b.size * b.align, 0, n - b.size);
7899            for (f = e3.length, y = false; f--; ) f > 0 && e3[f - 1].pos + e3[f - 1].size > e3[f].pos && (e3[f - 1].size += e3[f].size, e3[f - 1].targets = e3[f - 1].targets.concat(e3[f].targets), e3[f - 1].align = 0.5, e3[f - 1].pos + e3[f - 1].size > n && (e3[f - 1].pos = n - e3[f - 1].size), e3.splice(f, 1), y = true);
7900          }
7901          return g.apply(h, c), f = 0, e3.some((e4) => {
7902            let i3 = 0;
7903            return (e4.targets || []).some(() => (h[f].pos = e4.pos + i3, void 0 !== a && Math.abs(h[f].pos - h[f].target) > a) ? (h.slice(0, f + 1).forEach((t4) => delete t4.pos), h.reducedLen = (h.reducedLen || n) - 0.1 * n, h.reducedLen > 0.1 * n && t3(h, n, a), true) : (i3 += h[f].size, f++, false));
7904          }), o(h, d), h;
7905        }, e2;
7906      }), i(e, "Core/Renderer/SVG/SVGElement.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Color/Color.js"], e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
7907        let {
7908          animate: r,
7909          animObject: o,
7910          stop: n
7911        } = t2, {
7912          deg2rad: a,
7913          doc: h,
7914          svg: l,
7915          SVG_NS: d,
7916          win: c
7917        } = i2, {
7918          addEvent: p,
7919          attr: u11,
7920          createElement: g,
7921          crisp: f,
7922          css: m,
7923          defined: x,
7924          erase: y,
7925          extend: b,
7926          fireEvent: v,
7927          isArray: S2,
7928          isFunction: C,
7929          isObject: k,
7930          isString: M,
7931          merge: w,
7932          objectEach: T2,
7933          pick: A,
7934          pInt: P,
7935          pushUnique: L,
7936          replaceNested: O,
7937          syncTimeout: D2,
7938          uniqueKey: E
7939        } = s;
7940        class I {
7941          _defaultGetter(t3) {
7942            let e3 = A(this[t3 + "Value"], this[t3], this.element ? this.element.getAttribute(t3) : null, 0);
7943            return /^-?[\d\.]+$/.test(e3) && (e3 = parseFloat(e3)), e3;
7944          }
7945          _defaultSetter(t3, e3, i3) {
7946            i3.setAttribute(e3, t3);
7947          }
7948          add(t3) {
7949            let e3;
7950            let i3 = this.renderer, s2 = this.element;
7951            return t3 && (this.parentGroup = t3), void 0 !== this.textStr && "text" === this.element.nodeName && i3.buildText(this), this.added = true, (!t3 || t3.handleZ || this.zIndex) && (e3 = this.zIndexSetter()), e3 || (t3 ? t3.element : i3.box).appendChild(s2), this.onAdd && this.onAdd(), this;
7952          }
7953          addClass(t3, e3) {
7954            let i3 = e3 ? "" : this.attr("class") || "";
7955            return (t3 = (t3 || "").split(/ /g).reduce(function(t4, e4) {
7956              return -1 === i3.indexOf(e4) && t4.push(e4), t4;
7957            }, i3 ? [i3] : []).join(" ")) !== i3 && this.attr("class", t3), this;
7958          }
7959          afterSetters() {
7960            this.doTransform && (this.updateTransform(), this.doTransform = false);
7961          }
7962          align(t3, e3, i3, s2 = true) {
7963            let r2, o2, n2, a2;
7964            let h2 = {}, l2 = this.renderer, d2 = l2.alignedObjects, c2 = !!t3;
7965            t3 ? (this.alignOptions = t3, this.alignByTranslate = e3, this.alignTo = i3) : (t3 = this.alignOptions || {}, e3 = this.alignByTranslate, i3 = this.alignTo);
7966            let p2 = !i3 || M(i3) ? i3 || "renderer" : void 0;
7967            p2 && (c2 && L(d2, this), i3 = void 0);
7968            let u12 = A(i3, l2[p2], l2), g2 = t3.align, f2 = t3.verticalAlign;
7969            return r2 = (u12.x || 0) + (t3.x || 0), o2 = (u12.y || 0) + (t3.y || 0), "right" === g2 ? n2 = 1 : "center" === g2 && (n2 = 2), n2 && (r2 += ((u12.width || 0) - (t3.width || 0)) / n2), h2[e3 ? "translateX" : "x"] = Math.round(r2), "bottom" === f2 ? a2 = 1 : "middle" === f2 && (a2 = 2), a2 && (o2 += ((u12.height || 0) - (t3.height || 0)) / a2), h2[e3 ? "translateY" : "y"] = Math.round(o2), s2 && (this[this.placed ? "animate" : "attr"](h2), this.placed = true), this.alignAttr = h2, this;
7970          }
7971          alignSetter(t3) {
7972            let e3 = {
7973              left: "start",
7974              center: "middle",
7975              right: "end"
7976            };
7977            e3[t3] && (this.alignValue = t3, this.element.setAttribute("text-anchor", e3[t3]));
7978          }
7979          animate(t3, e3, i3) {
7980            let s2 = o(A(e3, this.renderer.globalAnimation, true)), n2 = s2.defer;
7981            return h.hidden && (s2.duration = 0), 0 !== s2.duration ? (i3 && (s2.complete = i3), D2(() => {
7982              this.element && r(this, t3, s2);
7983            }, n2)) : (this.attr(t3, void 0, i3 || s2.complete), T2(t3, function(t4, e4) {
7984              s2.step && s2.step.call(this, t4, {
7985                prop: e4,
7986                pos: 1,
7987                elem: this
7988              });
7989            }, this)), this;
7990          }
7991          applyTextOutline(t3) {
7992            let e3 = this.element;
7993            -1 !== t3.indexOf("contrast") && (t3 = t3.replace(/contrast/g, this.renderer.getContrast(e3.style.fill)));
7994            let s2 = t3.split(" "), r2 = s2[s2.length - 1], o2 = s2[0];
7995            if (o2 && "none" !== o2 && i2.svg) {
7996              this.fakeTS = true, o2 = o2.replace(/(^[\d\.]+)(.*?)$/g, function(t5, e4, i4) {
7997                return 2 * Number(e4) + i4;
7998              }), this.removeTextOutline();
7999              let t4 = h.createElementNS(d, "tspan");
8000              u11(t4, {
8001                class: "highcharts-text-outline",
8002                fill: r2,
8003                stroke: r2,
8004                "stroke-width": o2,
8005                "stroke-linejoin": "round"
8006              });
8007              let i3 = e3.querySelector("textPath") || e3;
8008              [].forEach.call(i3.childNodes, (e4) => {
8009                let i4 = e4.cloneNode(true);
8010                i4.removeAttribute && ["fill", "stroke", "stroke-width", "stroke"].forEach((t5) => i4.removeAttribute(t5)), t4.appendChild(i4);
8011              });
8012              let s3 = 0;
8013              [].forEach.call(i3.querySelectorAll("text tspan"), (t5) => {
8014                s3 += Number(t5.getAttribute("dy"));
8015              });
8016              let n2 = h.createElementNS(d, "tspan");
8017              n2.textContent = "\u200B", u11(n2, {
8018                x: Number(e3.getAttribute("x")),
8019                dy: -s3
8020              }), t4.appendChild(n2), i3.insertBefore(t4, i3.firstChild);
8021            }
8022          }
8023          attr(t3, e3, i3, s2) {
8024            let {
8025              element: r2
8026            } = this, o2 = I.symbolCustomAttribs, a2, h2, l2 = this, d2;
8027            return "string" == typeof t3 && void 0 !== e3 && (a2 = t3, (t3 = {})[a2] = e3), "string" == typeof t3 ? l2 = (this[t3 + "Getter"] || this._defaultGetter).call(this, t3, r2) : (T2(t3, function(e4, i4) {
8028              d2 = false, s2 || n(this, i4), this.symbolName && -1 !== o2.indexOf(i4) && (h2 || (this.symbolAttr(t3), h2 = true), d2 = true), this.rotation && ("x" === i4 || "y" === i4) && (this.doTransform = true), d2 || (this[i4 + "Setter"] || this._defaultSetter).call(this, e4, i4, r2);
8029            }, this), this.afterSetters()), i3 && i3.call(this), l2;
8030          }
8031          clip(t3) {
8032            if (t3 && !t3.clipPath) {
8033              let e3 = E() + "-", i3 = this.renderer.createElement("clipPath").attr({
8034                id: e3
8035              }).add(this.renderer.defs);
8036              b(t3, {
8037                clipPath: i3,
8038                id: e3,
8039                count: 0
8040              }), t3.add(i3);
8041            }
8042            return this.attr("clip-path", t3 ? `url(${this.renderer.url}#${t3.id})` : "none");
8043          }
8044          crisp(t3, e3) {
8045            e3 = Math.round(e3 || t3.strokeWidth || 0);
8046            let i3 = t3.x || this.x || 0, s2 = t3.y || this.y || 0, r2 = (t3.width || this.width || 0) + i3, o2 = (t3.height || this.height || 0) + s2, n2 = f(i3, e3), a2 = f(s2, e3);
8047            return b(t3, {
8048              x: n2,
8049              y: a2,
8050              width: f(r2, e3) - n2,
8051              height: f(o2, e3) - a2
8052            }), x(t3.strokeWidth) && (t3.strokeWidth = e3), t3;
8053          }
8054          complexColor(t3, i3, s2) {
8055            let r2 = this.renderer, o2, n2, a2, h2, l2, d2, c2, p2, u12, g2, f2 = [], m2;
8056            v(this.renderer, "complexColor", {
8057              args: arguments
8058            }, function() {
8059              if (t3.radialGradient ? n2 = "radialGradient" : t3.linearGradient && (n2 = "linearGradient"), n2) {
8060                if (a2 = t3[n2], l2 = r2.gradients, d2 = t3.stops, u12 = s2.radialReference, S2(a2) && (t3[n2] = a2 = {
8061                  x1: a2[0],
8062                  y1: a2[1],
8063                  x2: a2[2],
8064                  y2: a2[3],
8065                  gradientUnits: "userSpaceOnUse"
8066                }), "radialGradient" === n2 && u12 && !x(a2.gradientUnits) && (h2 = a2, a2 = w(a2, r2.getRadialAttr(u12, h2), {
8067                  gradientUnits: "userSpaceOnUse"
8068                })), T2(a2, function(t4, e3) {
8069                  "id" !== e3 && f2.push(e3, t4);
8070                }), T2(d2, function(t4) {
8071                  f2.push(t4);
8072                }), l2[f2 = f2.join(",")]) g2 = l2[f2].attr("id");
8073                else {
8074                  a2.id = g2 = E();
8075                  let t4 = l2[f2] = r2.createElement(n2).attr(a2).add(r2.defs);
8076                  t4.radAttr = h2, t4.stops = [], d2.forEach(function(i4) {
8077                    0 === i4[1].indexOf("rgba") ? (c2 = (o2 = e2.parse(i4[1])).get("rgb"), p2 = o2.get("a")) : (c2 = i4[1], p2 = 1);
8078                    let s3 = r2.createElement("stop").attr({
8079                      offset: i4[0],
8080                      "stop-color": c2,
8081                      "stop-opacity": p2
8082                    }).add(t4);
8083                    t4.stops.push(s3);
8084                  });
8085                }
8086                m2 = "url(" + r2.url + "#" + g2 + ")", s2.setAttribute(i3, m2), s2.gradient = f2, t3.toString = function() {
8087                  return m2;
8088                };
8089              }
8090            });
8091          }
8092          css(t3) {
8093            let e3 = this.styles, i3 = {}, s2 = this.element, r2, o2 = !e3;
8094            if (e3 && T2(t3, function(t4, s3) {
8095              e3 && e3[s3] !== t4 && (i3[s3] = t4, o2 = true);
8096            }), o2) {
8097              e3 && (t3 = b(e3, i3)), null === t3.width || "auto" === t3.width ? delete this.textWidth : "text" === s2.nodeName.toLowerCase() && t3.width && (r2 = this.textWidth = P(t3.width)), b(this.styles, t3), r2 && !l && this.renderer.forExport && delete t3.width;
8098              let o3 = w(t3);
8099              s2.namespaceURI === this.SVG_NS && (["textOutline", "textOverflow", "width"].forEach((t4) => o3 && delete o3[t4]), o3.color && (o3.fill = o3.color)), m(s2, o3);
8100            }
8101            return this.added && ("text" === this.element.nodeName && this.renderer.buildText(this), t3.textOutline && this.applyTextOutline(t3.textOutline)), this;
8102          }
8103          dashstyleSetter(t3) {
8104            let e3, i3 = this["stroke-width"];
8105            if ("inherit" === i3 && (i3 = 1), t3 = t3 && t3.toLowerCase()) {
8106              let s2 = t3.replace("shortdashdotdot", "3,1,1,1,1,1,").replace("shortdashdot", "3,1,1,1").replace("shortdot", "1,1,").replace("shortdash", "3,1,").replace("longdash", "8,3,").replace(/dot/g, "1,3,").replace("dash", "4,3,").replace(/,$/, "").split(",");
8107              for (e3 = s2.length; e3--; ) s2[e3] = "" + P(s2[e3]) * A(i3, NaN);
8108              t3 = s2.join(",").replace(/NaN/g, "none"), this.element.setAttribute("stroke-dasharray", t3);
8109            }
8110          }
8111          destroy() {
8112            let t3 = this, e3 = t3.element || {}, i3 = t3.renderer, s2 = e3.ownerSVGElement, r2 = "SPAN" === e3.nodeName && t3.parentGroup || void 0, o2, a2;
8113            if (e3.onclick = e3.onmouseout = e3.onmouseover = e3.onmousemove = e3.point = null, n(t3), t3.clipPath && s2) {
8114              let e4 = t3.clipPath;
8115              [].forEach.call(s2.querySelectorAll("[clip-path],[CLIP-PATH]"), function(t4) {
8116                t4.getAttribute("clip-path").indexOf(e4.element.id) > -1 && t4.removeAttribute("clip-path");
8117              }), t3.clipPath = e4.destroy();
8118            }
8119            if (t3.connector = t3.connector?.destroy(), t3.stops) {
8120              for (a2 = 0; a2 < t3.stops.length; a2++) t3.stops[a2].destroy();
8121              t3.stops.length = 0, t3.stops = void 0;
8122            }
8123            for (t3.safeRemoveChild(e3); r2 && r2.div && 0 === r2.div.childNodes.length; ) o2 = r2.parentGroup, t3.safeRemoveChild(r2.div), delete r2.div, r2 = o2;
8124            t3.alignOptions && y(i3.alignedObjects, t3), T2(t3, function(e4, i4) {
8125              t3[i4] && t3[i4].parentGroup === t3 && t3[i4].destroy && t3[i4].destroy(), delete t3[i4];
8126            });
8127          }
8128          dSetter(t3, e3, i3) {
8129            S2(t3) && ("string" == typeof t3[0] && (t3 = this.renderer.pathToSegments(t3)), this.pathArray = t3, t3 = t3.reduce((t4, e4, i4) => e4 && e4.join ? (i4 ? t4 + " " : "") + e4.join(" ") : (e4 || "").toString(), "")), /(NaN| {2}|^$)/.test(t3) && (t3 = "M 0 0"), this[e3] !== t3 && (i3.setAttribute(e3, t3), this[e3] = t3);
8130          }
8131          fillSetter(t3, e3, i3) {
8132            "string" == typeof t3 ? i3.setAttribute(e3, t3) : t3 && this.complexColor(t3, e3, i3);
8133          }
8134          hrefSetter(t3, e3, i3) {
8135            i3.setAttributeNS("http://www.w3.org/1999/xlink", e3, t3);
8136          }
8137          getBBox(t3, e3) {
8138            let i3, s2, r2, o2;
8139            let {
8140              alignValue: n2,
8141              element: a2,
8142              renderer: h2,
8143              styles: l2,
8144              textStr: d2
8145            } = this, {
8146              cache: c2,
8147              cacheKeys: p2
8148            } = h2, u12 = a2.namespaceURI === this.SVG_NS, g2 = A(e3, this.rotation, 0), f2 = h2.styledMode ? a2 && I.prototype.getStyle.call(a2, "font-size") : l2.fontSize;
8149            if (x(d2) && (-1 === (o2 = d2.toString()).indexOf("<") && (o2 = o2.replace(/\d/g, "0")), o2 += ["", h2.rootFontSize, f2, g2, this.textWidth, n2, l2.textOverflow, l2.fontWeight].join(",")), o2 && !t3 && (i3 = c2[o2]), !i3 || i3.polygon) {
8150              if (u12 || h2.forExport) {
8151                try {
8152                  r2 = this.fakeTS && function(t5) {
8153                    let e4 = a2.querySelector(".highcharts-text-outline");
8154                    e4 && m(e4, {
8155                      display: t5
8156                    });
8157                  }, C(r2) && r2("none"), i3 = a2.getBBox ? b({}, a2.getBBox()) : {
8158                    width: a2.offsetWidth,
8159                    height: a2.offsetHeight,
8160                    x: 0,
8161                    y: 0
8162                  }, C(r2) && r2("");
8163                } catch (t5) {
8164                }
8165                (!i3 || i3.width < 0) && (i3 = {
8166                  x: 0,
8167                  y: 0,
8168                  width: 0,
8169                  height: 0
8170                });
8171              } else i3 = this.htmlGetBBox();
8172              s2 = i3.height, u12 && (i3.height = s2 = {
8173                "11px,17": 14,
8174                "13px,20": 16
8175              }[`${f2 || ""},${Math.round(s2)}`] || s2), g2 && (i3 = this.getRotatedBox(i3, g2));
8176              let t4 = {
8177                bBox: i3
8178              };
8179              v(this, "afterGetBBox", t4), i3 = t4.bBox;
8180            }
8181            if (o2 && ("" === d2 || i3.height > 0)) {
8182              for (; p2.length > 250; ) delete c2[p2.shift()];
8183              c2[o2] || p2.push(o2), c2[o2] = i3;
8184            }
8185            return i3;
8186          }
8187          getRotatedBox(t3, e3) {
8188            let {
8189              x: i3,
8190              y: s2,
8191              width: r2,
8192              height: o2
8193            } = t3, {
8194              alignValue: n2,
8195              translateY: h2,
8196              rotationOriginX: l2 = 0,
8197              rotationOriginY: d2 = 0
8198            } = this, c2 = {
8199              right: 1,
8200              center: 0.5
8201            }[n2 || 0] || 0, p2 = Number(this.element.getAttribute("y") || 0) - (h2 ? 0 : s2), u12 = e3 * a, g2 = (e3 - 90) * a, f2 = Math.cos(u12), m2 = Math.sin(u12), x2 = r2 * f2, y2 = r2 * m2, b2 = Math.cos(g2), v2 = Math.sin(g2), [[S3, C2], [k2, M2]] = [l2, d2].map((t4) => [t4 - t4 * f2, t4 * m2]), w2 = i3 + c2 * (r2 - x2) + S3 + M2 + p2 * b2, T3 = w2 + x2, A2 = T3 - o2 * b2, P2 = A2 - x2, L2 = s2 + p2 - c2 * y2 - C2 + k2 + p2 * v2, O2 = L2 + y2, D3 = O2 - o2 * v2, E2 = D3 - y2, I2 = Math.min(w2, T3, A2, P2), j = Math.min(L2, O2, D3, E2), B = Math.max(w2, T3, A2, P2) - I2, R = Math.max(L2, O2, D3, E2) - j;
8202            return {
8203              x: I2,
8204              y: j,
8205              width: B,
8206              height: R,
8207              polygon: [[w2, L2], [T3, O2], [A2, D3], [P2, E2]]
8208            };
8209          }
8210          getStyle(t3) {
8211            return c.getComputedStyle(this.element || this, "").getPropertyValue(t3);
8212          }
8213          hasClass(t3) {
8214            return -1 !== ("" + this.attr("class")).split(" ").indexOf(t3);
8215          }
8216          hide() {
8217            return this.attr({
8218              visibility: "hidden"
8219            });
8220          }
8221          htmlGetBBox() {
8222            return {
8223              height: 0,
8224              width: 0,
8225              x: 0,
8226              y: 0
8227            };
8228          }
8229          constructor(t3, e3) {
8230            this.onEvents = {}, this.opacity = 1, this.SVG_NS = d, this.element = "span" === e3 || "body" === e3 ? g(e3) : h.createElementNS(this.SVG_NS, e3), this.renderer = t3, this.styles = {}, v(this, "afterInit");
8231          }
8232          on(t3, e3) {
8233            let {
8234              onEvents: i3
8235            } = this;
8236            return i3[t3] && i3[t3](), i3[t3] = p(this.element, t3, e3), this;
8237          }
8238          opacitySetter(t3, e3, i3) {
8239            let s2 = Number(Number(t3).toFixed(3));
8240            this.opacity = s2, i3.setAttribute(e3, s2);
8241          }
8242          reAlign() {
8243            this.alignOptions?.width && "left" !== this.alignOptions.align && (this.alignOptions.width = this.getBBox().width, this.placed = false, this.align());
8244          }
8245          removeClass(t3) {
8246            return this.attr("class", ("" + this.attr("class")).replace(M(t3) ? RegExp(`(^| )${t3}( |$)`) : t3, " ").replace(/ +/g, " ").trim());
8247          }
8248          removeTextOutline() {
8249            let t3 = this.element.querySelector("tspan.highcharts-text-outline");
8250            t3 && this.safeRemoveChild(t3);
8251          }
8252          safeRemoveChild(t3) {
8253            let e3 = t3.parentNode;
8254            e3 && e3.removeChild(t3);
8255          }
8256          setRadialReference(t3) {
8257            let e3 = this.element.gradient && this.renderer.gradients[this.element.gradient];
8258            return this.element.radialReference = t3, e3 && e3.radAttr && e3.animate(this.renderer.getRadialAttr(t3, e3.radAttr)), this;
8259          }
8260          shadow(t3) {
8261            let {
8262              renderer: e3
8263            } = this, i3 = w(this.parentGroup?.rotation === 90 ? {
8264              offsetX: -1,
8265              offsetY: -1
8266            } : {}, k(t3) ? t3 : {}), s2 = e3.shadowDefinition(i3);
8267            return this.attr({
8268              filter: t3 ? `url(${e3.url}#${s2})` : "none"
8269            });
8270          }
8271          show(t3 = true) {
8272            return this.attr({
8273              visibility: t3 ? "inherit" : "visible"
8274            });
8275          }
8276          "stroke-widthSetter"(t3, e3, i3) {
8277            this[e3] = t3, i3.setAttribute(e3, t3);
8278          }
8279          strokeWidth() {
8280            if (!this.renderer.styledMode) return this["stroke-width"] || 0;
8281            let t3 = this.getStyle("stroke-width"), e3 = 0, i3;
8282            return /px$/.test(t3) ? e3 = P(t3) : "" !== t3 && (u11(i3 = h.createElementNS(d, "rect"), {
8283              width: t3,
8284              "stroke-width": 0
8285            }), this.element.parentNode.appendChild(i3), e3 = i3.getBBox().width, i3.parentNode.removeChild(i3)), e3;
8286          }
8287          symbolAttr(t3) {
8288            let e3 = this;
8289            I.symbolCustomAttribs.forEach(function(i3) {
8290              e3[i3] = A(t3[i3], e3[i3]);
8291            }), e3.attr({
8292              d: e3.renderer.symbols[e3.symbolName](e3.x, e3.y, e3.width, e3.height, e3)
8293            });
8294          }
8295          textSetter(t3) {
8296            t3 !== this.textStr && (delete this.textPxLength, this.textStr = t3, this.added && this.renderer.buildText(this), this.reAlign());
8297          }
8298          titleSetter(t3) {
8299            let e3 = this.element, i3 = e3.getElementsByTagName("title")[0] || h.createElementNS(this.SVG_NS, "title");
8300            e3.insertBefore ? e3.insertBefore(i3, e3.firstChild) : e3.appendChild(i3), i3.textContent = O(A(t3, ""), [/<[^>]*>/g, ""]).replace(/&lt;/g, "<").replace(/&gt;/g, ">");
8301          }
8302          toFront() {
8303            let t3 = this.element;
8304            return t3.parentNode.appendChild(t3), this;
8305          }
8306          translate(t3, e3) {
8307            return this.attr({
8308              translateX: t3,
8309              translateY: e3
8310            });
8311          }
8312          updateTransform(t3 = "transform") {
8313            let {
8314              element: e3,
8315              matrix: i3,
8316              rotation: s2 = 0,
8317              rotationOriginX: r2,
8318              rotationOriginY: o2,
8319              scaleX: n2,
8320              scaleY: a2,
8321              translateX: h2 = 0,
8322              translateY: l2 = 0
8323            } = this, d2 = ["translate(" + h2 + "," + l2 + ")"];
8324            x(i3) && d2.push("matrix(" + i3.join(",") + ")"), s2 && (d2.push("rotate(" + s2 + " " + A(r2, e3.getAttribute("x"), 0) + " " + A(o2, e3.getAttribute("y") || 0) + ")"), this.text?.element.tagName === "SPAN" && this.text.attr({
8325              rotation: s2,
8326              rotationOriginX: (r2 || 0) - this.padding,
8327              rotationOriginY: (o2 || 0) - this.padding
8328            })), (x(n2) || x(a2)) && d2.push("scale(" + A(n2, 1) + " " + A(a2, 1) + ")"), d2.length && !(this.text || this).textPath && e3.setAttribute(t3, d2.join(" "));
8329          }
8330          visibilitySetter(t3, e3, i3) {
8331            "inherit" === t3 ? i3.removeAttribute(e3) : this[e3] !== t3 && i3.setAttribute(e3, t3), this[e3] = t3;
8332          }
8333          xGetter(t3) {
8334            return "circle" === this.element.nodeName && ("x" === t3 ? t3 = "cx" : "y" === t3 && (t3 = "cy")), this._defaultGetter(t3);
8335          }
8336          zIndexSetter(t3, e3) {
8337            let i3 = this.renderer, s2 = this.parentGroup, r2 = (s2 || i3).element || i3.box, o2 = this.element, n2 = r2 === i3.box, a2, h2, l2, d2 = false, c2, p2 = this.added, u12;
8338            if (x(t3) ? (o2.setAttribute("data-z-index", t3), t3 = +t3, this[e3] === t3 && (p2 = false)) : x(this[e3]) && o2.removeAttribute("data-z-index"), this[e3] = t3, p2) {
8339              for ((t3 = this.zIndex) && s2 && (s2.handleZ = true), u12 = (a2 = r2.childNodes).length - 1; u12 >= 0 && !d2; u12--) c2 = !x(l2 = (h2 = a2[u12]).getAttribute("data-z-index")), h2 !== o2 && (t3 < 0 && c2 && !n2 && !u12 ? (r2.insertBefore(o2, a2[u12]), d2 = true) : (P(l2) <= t3 || c2 && (!x(t3) || t3 >= 0)) && (r2.insertBefore(o2, a2[u12 + 1]), d2 = true));
8340              d2 || (r2.insertBefore(o2, a2[n2 ? 3 : 0]), d2 = true);
8341            }
8342            return d2;
8343          }
8344        }
8345        return I.symbolCustomAttribs = ["anchorX", "anchorY", "clockwise", "end", "height", "innerR", "r", "start", "width", "x", "y"], I.prototype.strokeSetter = I.prototype.fillSetter, I.prototype.yGetter = I.prototype.xGetter, I.prototype.matrixSetter = I.prototype.rotationOriginXSetter = I.prototype.rotationOriginYSetter = I.prototype.rotationSetter = I.prototype.scaleXSetter = I.prototype.scaleYSetter = I.prototype.translateXSetter = I.prototype.translateYSetter = I.prototype.verticalAlignSetter = function(t3, e3) {
8346          this[e3] = t3, this.doTransform = true;
8347        }, I;
8348      }), i(e, "Core/Renderer/SVG/SVGLabel.js", [e["Core/Renderer/SVG/SVGElement.js"], e["Core/Utilities.js"]], function(t2, e2) {
8349        let {
8350          defined: i2,
8351          extend: s,
8352          isNumber: r,
8353          merge: o,
8354          pick: n,
8355          removeEvent: a
8356        } = e2;
8357        class h extends t2 {
8358          constructor(t3, e3, i3, s2, r2, o2, n2, a2, l, d) {
8359            let c;
8360            super(t3, "g"), this.paddingLeftSetter = this.paddingSetter, this.paddingRightSetter = this.paddingSetter, this.doUpdate = false, this.textStr = e3, this.x = i3, this.y = s2, this.anchorX = o2, this.anchorY = n2, this.baseline = l, this.className = d, this.addClass("button" === d ? "highcharts-no-tooltip" : "highcharts-label"), d && this.addClass("highcharts-" + d), this.text = t3.text(void 0, 0, 0, a2).attr({
8361              zIndex: 1
8362            }), "string" == typeof r2 && ((c = /^url\((.*?)\)$/.test(r2)) || this.renderer.symbols[r2]) && (this.symbolKey = r2), this.bBox = h.emptyBBox, this.padding = 3, this.baselineOffset = 0, this.needsBox = t3.styledMode || c, this.deferredAttr = {}, this.alignFactor = 0;
8363          }
8364          alignSetter(t3) {
8365            let e3 = {
8366              left: 0,
8367              center: 0.5,
8368              right: 1
8369            }[t3];
8370            e3 !== this.alignFactor && (this.alignFactor = e3, this.bBox && r(this.xSetting) && this.attr({
8371              x: this.xSetting
8372            }));
8373          }
8374          anchorXSetter(t3, e3) {
8375            this.anchorX = t3, this.boxAttr(e3, Math.round(t3) - this.getCrispAdjust() - this.xSetting);
8376          }
8377          anchorYSetter(t3, e3) {
8378            this.anchorY = t3, this.boxAttr(e3, t3 - this.ySetting);
8379          }
8380          boxAttr(t3, e3) {
8381            this.box ? this.box.attr(t3, e3) : this.deferredAttr[t3] = e3;
8382          }
8383          css(e3) {
8384            if (e3) {
8385              let t3 = {};
8386              e3 = o(e3), h.textProps.forEach((i3) => {
8387                void 0 !== e3[i3] && (t3[i3] = e3[i3], delete e3[i3]);
8388              }), this.text.css(t3), "fontSize" in t3 || "fontWeight" in t3 ? this.updateTextPadding() : ("width" in t3 || "textOverflow" in t3) && this.updateBoxSize();
8389            }
8390            return t2.prototype.css.call(this, e3);
8391          }
8392          destroy() {
8393            a(this.element, "mouseenter"), a(this.element, "mouseleave"), this.text && this.text.destroy(), this.box && (this.box = this.box.destroy()), t2.prototype.destroy.call(this);
8394          }
8395          fillSetter(t3, e3) {
8396            t3 && (this.needsBox = true), this.fill = t3, this.boxAttr(e3, t3);
8397          }
8398          getBBox(t3, e3) {
8399            this.textStr && 0 === this.bBox.width && 0 === this.bBox.height && this.updateBoxSize();
8400            let {
8401              padding: i3,
8402              height: s2 = 0,
8403              translateX: r2 = 0,
8404              translateY: o2 = 0,
8405              width: a2 = 0
8406            } = this, h2 = n(this.paddingLeft, i3), l = e3 ?? (this.rotation || 0), d = {
8407              width: a2,
8408              height: s2,
8409              x: r2 + this.bBox.x - h2,
8410              y: o2 + this.bBox.y - i3 + this.baselineOffset
8411            };
8412            return l && (d = this.getRotatedBox(d, l)), d;
8413          }
8414          getCrispAdjust() {
8415            return (this.renderer.styledMode && this.box ? this.box.strokeWidth() : this["stroke-width"] ? parseInt(this["stroke-width"], 10) : 0) % 2 / 2;
8416          }
8417          heightSetter(t3) {
8418            this.heightSetting = t3, this.doUpdate = true;
8419          }
8420          afterSetters() {
8421            super.afterSetters(), this.doUpdate && (this.updateBoxSize(), this.doUpdate = false);
8422          }
8423          onAdd() {
8424            this.text.add(this), this.attr({
8425              text: n(this.textStr, ""),
8426              x: this.x || 0,
8427              y: this.y || 0
8428            }), this.box && i2(this.anchorX) && this.attr({
8429              anchorX: this.anchorX,
8430              anchorY: this.anchorY
8431            });
8432          }
8433          paddingSetter(t3, e3) {
8434            r(t3) ? t3 !== this[e3] && (this[e3] = t3, this.updateTextPadding()) : this[e3] = void 0;
8435          }
8436          rSetter(t3, e3) {
8437            this.boxAttr(e3, t3);
8438          }
8439          strokeSetter(t3, e3) {
8440            this.stroke = t3, this.boxAttr(e3, t3);
8441          }
8442          "stroke-widthSetter"(t3, e3) {
8443            t3 && (this.needsBox = true), this["stroke-width"] = t3, this.boxAttr(e3, t3);
8444          }
8445          "text-alignSetter"(t3) {
8446            this.textAlign = t3;
8447          }
8448          textSetter(t3) {
8449            void 0 !== t3 && this.text.attr({
8450              text: t3
8451            }), this.updateTextPadding(), this.reAlign();
8452          }
8453          updateBoxSize() {
8454            let t3;
8455            let e3 = this.text, o2 = {}, n2 = this.padding, a2 = this.bBox = (!r(this.widthSetting) || !r(this.heightSetting) || this.textAlign) && i2(e3.textStr) ? e3.getBBox(void 0, 0) : h.emptyBBox;
8456            this.width = this.getPaddedWidth(), this.height = (this.heightSetting || a2.height || 0) + 2 * n2;
8457            let l = this.renderer.fontMetrics(e3);
8458            if (this.baselineOffset = n2 + Math.min((this.text.firstLineMetrics || l).b, a2.height || 1 / 0), this.heightSetting && (this.baselineOffset += (this.heightSetting - l.h) / 2), this.needsBox && !e3.textPath) {
8459              if (!this.box) {
8460                let t4 = this.box = this.symbolKey ? this.renderer.symbol(this.symbolKey) : this.renderer.rect();
8461                t4.addClass(("button" === this.className ? "" : "highcharts-label-box") + (this.className ? " highcharts-" + this.className + "-box" : "")), t4.add(this);
8462              }
8463              t3 = this.getCrispAdjust(), o2.x = t3, o2.y = (this.baseline ? -this.baselineOffset : 0) + t3, o2.width = Math.round(this.width), o2.height = Math.round(this.height), this.box.attr(s(o2, this.deferredAttr)), this.deferredAttr = {};
8464            }
8465          }
8466          updateTextPadding() {
8467            let t3 = this.text;
8468            if (!t3.textPath) {
8469              this.updateBoxSize();
8470              let e3 = this.baseline ? 0 : this.baselineOffset, s2 = n(this.paddingLeft, this.padding);
8471              i2(this.widthSetting) && this.bBox && ("center" === this.textAlign || "right" === this.textAlign) && (s2 += {
8472                center: 0.5,
8473                right: 1
8474              }[this.textAlign] * (this.widthSetting - this.bBox.width)), (s2 !== t3.x || e3 !== t3.y) && (t3.attr("x", s2), t3.hasBoxWidthChanged && (this.bBox = t3.getBBox(true)), void 0 !== e3 && t3.attr("y", e3)), t3.x = s2, t3.y = e3;
8475            }
8476          }
8477          widthSetter(t3) {
8478            this.widthSetting = r(t3) ? t3 : void 0, this.doUpdate = true;
8479          }
8480          getPaddedWidth() {
8481            let t3 = this.padding, e3 = n(this.paddingLeft, t3), i3 = n(this.paddingRight, t3);
8482            return (this.widthSetting || this.bBox.width || 0) + e3 + i3;
8483          }
8484          xSetter(t3) {
8485            this.x = t3, this.alignFactor && (t3 -= this.alignFactor * this.getPaddedWidth(), this["forceAnimate:x"] = true), this.xSetting = Math.round(t3), this.attr("translateX", this.xSetting);
8486          }
8487          ySetter(t3) {
8488            this.ySetting = this.y = Math.round(t3), this.attr("translateY", this.ySetting);
8489          }
8490        }
8491        return h.emptyBBox = {
8492          width: 0,
8493          height: 0,
8494          x: 0,
8495          y: 0
8496        }, h.textProps = ["color", "direction", "fontFamily", "fontSize", "fontStyle", "fontWeight", "lineHeight", "textAlign", "textDecoration", "textOutline", "textOverflow", "whiteSpace", "width"], h;
8497      }), i(e, "Core/Renderer/SVG/Symbols.js", [e["Core/Utilities.js"]], function(t2) {
8498        let {
8499          defined: e2,
8500          isNumber: i2,
8501          pick: s
8502        } = t2;
8503        function r(t3, i3, r2, o2, n2) {
8504          let a = [];
8505          if (n2) {
8506            let h = n2.start || 0, l = s(n2.r, r2), d = s(n2.r, o2 || r2), c = 2e-4 / (n2.borderRadius ? 1 : Math.max(l, 1)), p = Math.abs((n2.end || 0) - h - 2 * Math.PI) < c, u11 = (n2.end || 0) - (p ? c : 0), g = n2.innerR, f = s(n2.open, p), m = Math.cos(h), x = Math.sin(h), y = Math.cos(u11), b = Math.sin(u11), v = s(n2.longArc, u11 - h - Math.PI < c ? 0 : 1), S2 = ["A", l, d, 0, v, s(n2.clockwise, 1), t3 + l * y, i3 + d * b];
8507            S2.params = {
8508              start: h,
8509              end: u11,
8510              cx: t3,
8511              cy: i3
8512            }, a.push(["M", t3 + l * m, i3 + d * x], S2), e2(g) && ((S2 = ["A", g, g, 0, v, e2(n2.clockwise) ? 1 - n2.clockwise : 0, t3 + g * m, i3 + g * x]).params = {
8513              start: u11,
8514              end: h,
8515              cx: t3,
8516              cy: i3
8517            }, a.push(f ? ["M", t3 + g * y, i3 + g * b] : ["L", t3 + g * y, i3 + g * b], S2)), f || a.push(["Z"]);
8518          }
8519          return a;
8520        }
8521        function o(t3, e3, i3, s2, r2) {
8522          return r2 && r2.r ? n(t3, e3, i3, s2, r2) : [["M", t3, e3], ["L", t3 + i3, e3], ["L", t3 + i3, e3 + s2], ["L", t3, e3 + s2], ["Z"]];
8523        }
8524        function n(t3, e3, i3, s2, r2) {
8525          let o2 = r2?.r || 0;
8526          return [["M", t3 + o2, e3], ["L", t3 + i3 - o2, e3], ["A", o2, o2, 0, 0, 1, t3 + i3, e3 + o2], ["L", t3 + i3, e3 + s2 - o2], ["A", o2, o2, 0, 0, 1, t3 + i3 - o2, e3 + s2], ["L", t3 + o2, e3 + s2], ["A", o2, o2, 0, 0, 1, t3, e3 + s2 - o2], ["L", t3, e3 + o2], ["A", o2, o2, 0, 0, 1, t3 + o2, e3], ["Z"]];
8527        }
8528        return {
8529          arc: r,
8530          callout: function(t3, e3, s2, r2, o2) {
8531            let a = Math.min(o2 && o2.r || 0, s2, r2), h = a + 6, l = o2 && o2.anchorX, d = o2 && o2.anchorY || 0, c = n(t3, e3, s2, r2, {
8532              r: a
8533            });
8534            if (!i2(l) || l < s2 && l > 0 && d < r2 && d > 0) return c;
8535            if (t3 + l > s2 - h) {
8536              if (d > e3 + h && d < e3 + r2 - h) c.splice(3, 1, ["L", t3 + s2, d - 6], ["L", t3 + s2 + 6, d], ["L", t3 + s2, d + 6], ["L", t3 + s2, e3 + r2 - a]);
8537              else if (l < s2) {
8538                let i3 = d < e3 + h, o3 = i3 ? e3 : e3 + r2;
8539                c.splice(i3 ? 2 : 5, 0, ["L", l, d], ["L", t3 + s2 - a, o3]);
8540              } else c.splice(3, 1, ["L", t3 + s2, r2 / 2], ["L", l, d], ["L", t3 + s2, r2 / 2], ["L", t3 + s2, e3 + r2 - a]);
8541            } else if (t3 + l < h) {
8542              if (d > e3 + h && d < e3 + r2 - h) c.splice(7, 1, ["L", t3, d + 6], ["L", t3 - 6, d], ["L", t3, d - 6], ["L", t3, e3 + a]);
8543              else if (l > 0) {
8544                let i3 = d < e3 + h, s3 = i3 ? e3 : e3 + r2;
8545                c.splice(i3 ? 1 : 6, 0, ["L", l, d], ["L", t3 + a, s3]);
8546              } else c.splice(7, 1, ["L", t3, r2 / 2], ["L", l, d], ["L", t3, r2 / 2], ["L", t3, e3 + a]);
8547            } else d > r2 && l < s2 - h ? c.splice(5, 1, ["L", l + 6, e3 + r2], ["L", l, e3 + r2 + 6], ["L", l - 6, e3 + r2], ["L", t3 + a, e3 + r2]) : d < 0 && l > h && c.splice(1, 1, ["L", l - 6, e3], ["L", l, e3 - 6], ["L", l + 6, e3], ["L", s2 - a, e3]);
8548            return c;
8549          },
8550          circle: function(t3, e3, i3, s2) {
8551            return r(t3 + i3 / 2, e3 + s2 / 2, i3 / 2, s2 / 2, {
8552              start: 0.5 * Math.PI,
8553              end: 2.5 * Math.PI,
8554              open: false
8555            });
8556          },
8557          diamond: function(t3, e3, i3, s2) {
8558            return [["M", t3 + i3 / 2, e3], ["L", t3 + i3, e3 + s2 / 2], ["L", t3 + i3 / 2, e3 + s2], ["L", t3, e3 + s2 / 2], ["Z"]];
8559          },
8560          rect: o,
8561          roundedRect: n,
8562          square: o,
8563          triangle: function(t3, e3, i3, s2) {
8564            return [["M", t3 + i3 / 2, e3], ["L", t3 + i3, e3 + s2], ["L", t3, e3 + s2], ["Z"]];
8565          },
8566          "triangle-down": function(t3, e3, i3, s2) {
8567            return [["M", t3, e3], ["L", t3 + i3, e3], ["L", t3 + i3 / 2, e3 + s2], ["Z"]];
8568          }
8569        };
8570      }), i(e, "Core/Renderer/SVG/TextBuilder.js", [e["Core/Renderer/HTML/AST.js"], e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
8571        let {
8572          doc: s,
8573          SVG_NS: r,
8574          win: o
8575        } = e2, {
8576          attr: n,
8577          extend: a,
8578          fireEvent: h,
8579          isString: l,
8580          objectEach: d,
8581          pick: c
8582        } = i2;
8583        return class {
8584          constructor(t3) {
8585            let e3 = t3.styles;
8586            this.renderer = t3.renderer, this.svgElement = t3, this.width = t3.textWidth, this.textLineHeight = e3 && e3.lineHeight, this.textOutline = e3 && e3.textOutline, this.ellipsis = !!(e3 && "ellipsis" === e3.textOverflow), this.noWrap = !!(e3 && "nowrap" === e3.whiteSpace);
8587          }
8588          buildSVG() {
8589            let e3 = this.svgElement, i3 = e3.element, r2 = e3.renderer, o2 = c(e3.textStr, "").toString(), n2 = -1 !== o2.indexOf("<"), a2 = i3.childNodes, h2 = !e3.added && r2.box, d2 = [o2, this.ellipsis, this.noWrap, this.textLineHeight, this.textOutline, e3.getStyle("font-size"), this.width].join(",");
8590            if (d2 !== e3.textCache) {
8591              e3.textCache = d2, delete e3.actualWidth;
8592              for (let t3 = a2.length; t3--; ) i3.removeChild(a2[t3]);
8593              if (n2 || this.ellipsis || this.width || e3.textPath || -1 !== o2.indexOf(" ") && (!this.noWrap || /<br.*?>/g.test(o2))) {
8594                if ("" !== o2) {
8595                  h2 && h2.appendChild(i3);
8596                  let s2 = new t2(o2);
8597                  this.modifyTree(s2.nodes), s2.addToDOM(i3), this.modifyDOM(), this.ellipsis && -1 !== (i3.textContent || "").indexOf("\u2026") && e3.attr("title", this.unescapeEntities(e3.textStr || "", ["&lt;", "&gt;"])), h2 && h2.removeChild(i3);
8598                }
8599              } else i3.appendChild(s.createTextNode(this.unescapeEntities(o2)));
8600              l(this.textOutline) && e3.applyTextOutline && e3.applyTextOutline(this.textOutline);
8601            }
8602          }
8603          modifyDOM() {
8604            let t3;
8605            let e3 = this.svgElement, i3 = n(e3.element, "x");
8606            for (e3.firstLineMetrics = void 0; t3 = e3.element.firstChild; ) if (/^[\s\u200B]*$/.test(t3.textContent || " ")) e3.element.removeChild(t3);
8607            else break;
8608            [].forEach.call(e3.element.querySelectorAll("tspan.highcharts-br"), (t4, s2) => {
8609              t4.nextSibling && t4.previousSibling && (0 === s2 && 1 === t4.previousSibling.nodeType && (e3.firstLineMetrics = e3.renderer.fontMetrics(t4.previousSibling)), n(t4, {
8610                dy: this.getLineHeight(t4.nextSibling),
8611                x: i3
8612              }));
8613            });
8614            let a2 = this.width || 0;
8615            if (!a2) return;
8616            let h2 = (t4, o2) => {
8617              let h3 = t4.textContent || "", l3 = h3.replace(/([^\^])-/g, "$1- ").split(" "), d2 = !this.noWrap && (l3.length > 1 || e3.element.childNodes.length > 1), c2 = this.getLineHeight(o2), p = 0, u11 = e3.actualWidth;
8618              if (this.ellipsis) h3 && this.truncate(t4, h3, void 0, 0, Math.max(0, a2 - 0.8 * c2), (t5, e4) => t5.substring(0, e4) + "\u2026");
8619              else if (d2) {
8620                let h4 = [], d3 = [];
8621                for (; o2.firstChild && o2.firstChild !== t4; ) d3.push(o2.firstChild), o2.removeChild(o2.firstChild);
8622                for (; l3.length; ) l3.length && !this.noWrap && p > 0 && (h4.push(t4.textContent || ""), t4.textContent = l3.join(" ").replace(/- /g, "-")), this.truncate(t4, void 0, l3, 0 === p && u11 || 0, a2, (t5, e4) => l3.slice(0, e4).join(" ").replace(/- /g, "-")), u11 = e3.actualWidth, p++;
8623                d3.forEach((e4) => {
8624                  o2.insertBefore(e4, t4);
8625                }), h4.forEach((e4) => {
8626                  o2.insertBefore(s.createTextNode(e4), t4);
8627                  let a3 = s.createElementNS(r, "tspan");
8628                  a3.textContent = "\u200B", n(a3, {
8629                    dy: c2,
8630                    x: i3
8631                  }), o2.insertBefore(a3, t4);
8632                });
8633              }
8634            }, l2 = (t4) => {
8635              [].slice.call(t4.childNodes).forEach((i4) => {
8636                i4.nodeType === o.Node.TEXT_NODE ? h2(i4, t4) : (-1 !== i4.className.baseVal.indexOf("highcharts-br") && (e3.actualWidth = 0), l2(i4));
8637              });
8638            };
8639            l2(e3.element);
8640          }
8641          getLineHeight(t3) {
8642            let e3 = t3.nodeType === o.Node.TEXT_NODE ? t3.parentElement : t3;
8643            return this.textLineHeight ? parseInt(this.textLineHeight.toString(), 10) : this.renderer.fontMetrics(e3 || this.svgElement.element).h;
8644          }
8645          modifyTree(t3) {
8646            let e3 = (i3, s2) => {
8647              let {
8648                attributes: r2 = {},
8649                children: o2,
8650                style: n2 = {},
8651                tagName: h2
8652              } = i3, l2 = this.renderer.styledMode;
8653              if ("b" === h2 || "strong" === h2 ? l2 ? r2.class = "highcharts-strong" : n2.fontWeight = "bold" : ("i" === h2 || "em" === h2) && (l2 ? r2.class = "highcharts-emphasized" : n2.fontStyle = "italic"), n2 && n2.color && (n2.fill = n2.color), "br" === h2) {
8654                r2.class = "highcharts-br", i3.textContent = "\u200B";
8655                let e4 = t3[s2 + 1];
8656                e4 && e4.textContent && (e4.textContent = e4.textContent.replace(/^ +/gm, ""));
8657              } else "a" === h2 && o2 && o2.some((t4) => "#text" === t4.tagName) && (i3.children = [{
8658                children: o2,
8659                tagName: "tspan"
8660              }]);
8661              "#text" !== h2 && "a" !== h2 && (i3.tagName = "tspan"), a(i3, {
8662                attributes: r2,
8663                style: n2
8664              }), o2 && o2.filter((t4) => "#text" !== t4.tagName).forEach(e3);
8665            };
8666            t3.forEach(e3), h(this.svgElement, "afterModifyTree", {
8667              nodes: t3
8668            });
8669          }
8670          truncate(t3, e3, i3, s2, r2, o2) {
8671            let n2, a2;
8672            let h2 = this.svgElement, {
8673              rotation: l2
8674            } = h2, d2 = [], c2 = i3 ? 1 : 0, p = (e3 || i3 || "").length, u11 = p, g = function(e4, r3) {
8675              let o3 = r3 || e4, n3 = t3.parentNode;
8676              if (n3 && void 0 === d2[o3] && n3.getSubStringLength) try {
8677                d2[o3] = s2 + n3.getSubStringLength(0, i3 ? o3 + 1 : o3);
8678              } catch (t4) {
8679              }
8680              return d2[o3];
8681            };
8682            if (h2.rotation = 0, s2 + (a2 = g(t3.textContent.length)) > r2) {
8683              for (; c2 <= p; ) u11 = Math.ceil((c2 + p) / 2), i3 && (n2 = o2(i3, u11)), a2 = g(u11, n2 && n2.length - 1), c2 === p ? c2 = p + 1 : a2 > r2 ? p = u11 - 1 : c2 = u11;
8684              0 === p ? t3.textContent = "" : e3 && p === e3.length - 1 || (t3.textContent = n2 || o2(e3 || i3, u11));
8685            }
8686            i3 && i3.splice(0, u11), h2.actualWidth = a2, h2.rotation = l2;
8687          }
8688          unescapeEntities(t3, e3) {
8689            return d(this.renderer.escapes, function(i3, s2) {
8690              e3 && -1 !== e3.indexOf(i3) || (t3 = t3.toString().replace(RegExp(i3, "g"), s2));
8691            }), t3;
8692          }
8693        };
8694      }), i(e, "Core/Renderer/SVG/SVGRenderer.js", [e["Core/Renderer/HTML/AST.js"], e["Core/Defaults.js"], e["Core/Color/Color.js"], e["Core/Globals.js"], e["Core/Renderer/RendererRegistry.js"], e["Core/Renderer/SVG/SVGElement.js"], e["Core/Renderer/SVG/SVGLabel.js"], e["Core/Renderer/SVG/Symbols.js"], e["Core/Renderer/SVG/TextBuilder.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, r, o, n, a, h, l) {
8695        let d;
8696        let {
8697          defaultOptions: c
8698        } = e2, {
8699          charts: p,
8700          deg2rad: u11,
8701          doc: g,
8702          isFirefox: f,
8703          isMS: m,
8704          isWebKit: x,
8705          noop: y,
8706          SVG_NS: b,
8707          symbolSizes: v,
8708          win: S2
8709        } = s, {
8710          addEvent: C,
8711          attr: k,
8712          createElement: M,
8713          crisp: w,
8714          css: T2,
8715          defined: A,
8716          destroyObjectProperties: P,
8717          extend: L,
8718          isArray: O,
8719          isNumber: D2,
8720          isObject: E,
8721          isString: I,
8722          merge: j,
8723          pick: B,
8724          pInt: R,
8725          replaceNested: z,
8726          uniqueKey: N
8727        } = l;
8728        class W {
8729          constructor(t3, e3, i3, s2, r2, o2, n2) {
8730            let a2, h2;
8731            let l2 = this.createElement("svg").attr({
8732              version: "1.1",
8733              class: "highcharts-root"
8734            }), d2 = l2.element;
8735            n2 || l2.css(this.getStyle(s2 || {})), t3.appendChild(d2), k(t3, "dir", "ltr"), -1 === t3.innerHTML.indexOf("xmlns") && k(d2, "xmlns", this.SVG_NS), this.box = d2, this.boxWrapper = l2, this.alignedObjects = [], this.url = this.getReferenceURL(), this.createElement("desc").add().element.appendChild(g.createTextNode("Created with Highcharts 11.4.8")), this.defs = this.createElement("defs").add(), this.allowHTML = o2, this.forExport = r2, this.styledMode = n2, this.gradients = {}, this.cache = {}, this.cacheKeys = [], this.imgCount = 0, this.rootFontSize = l2.getStyle("font-size"), this.setSize(e3, i3, false), f && t3.getBoundingClientRect && ((a2 = function() {
8736              T2(t3, {
8737                left: 0,
8738                top: 0
8739              }), h2 = t3.getBoundingClientRect(), T2(t3, {
8740                left: Math.ceil(h2.left) - h2.left + "px",
8741                top: Math.ceil(h2.top) - h2.top + "px"
8742              });
8743            })(), this.unSubPixelFix = C(S2, "resize", a2));
8744          }
8745          definition(e3) {
8746            return new t2([e3]).addToDOM(this.defs.element);
8747          }
8748          getReferenceURL() {
8749            if ((f || x) && g.getElementsByTagName("base").length) {
8750              if (!A(d)) {
8751                let e3 = N(), i3 = new t2([{
8752                  tagName: "svg",
8753                  attributes: {
8754                    width: 8,
8755                    height: 8
8756                  },
8757                  children: [{
8758                    tagName: "defs",
8759                    children: [{
8760                      tagName: "clipPath",
8761                      attributes: {
8762                        id: e3
8763                      },
8764                      children: [{
8765                        tagName: "rect",
8766                        attributes: {
8767                          width: 4,
8768                          height: 4
8769                        }
8770                      }]
8771                    }]
8772                  }, {
8773                    tagName: "rect",
8774                    attributes: {
8775                      id: "hitme",
8776                      width: 8,
8777                      height: 8,
8778                      "clip-path": `url(#${e3})`,
8779                      fill: "rgba(0,0,0,0.001)"
8780                    }
8781                  }]
8782                }]).addToDOM(g.body);
8783                T2(i3, {
8784                  position: "fixed",
8785                  top: 0,
8786                  left: 0,
8787                  zIndex: 9e5
8788                });
8789                let s2 = g.elementFromPoint(6, 6);
8790                d = "hitme" === (s2 && s2.id), g.body.removeChild(i3);
8791              }
8792              if (d) return z(S2.location.href.split("#")[0], [/<[^>]*>/g, ""], [/([\('\)])/g, "\\$1"], [/ /g, "%20"]);
8793            }
8794            return "";
8795          }
8796          getStyle(t3) {
8797            return this.style = L({
8798              fontFamily: "Helvetica, Arial, sans-serif",
8799              fontSize: "1rem"
8800            }, t3), this.style;
8801          }
8802          setStyle(t3) {
8803            this.boxWrapper.css(this.getStyle(t3));
8804          }
8805          isHidden() {
8806            return !this.boxWrapper.getBBox().width;
8807          }
8808          destroy() {
8809            let t3 = this.defs;
8810            return this.box = null, this.boxWrapper = this.boxWrapper.destroy(), P(this.gradients || {}), this.gradients = null, this.defs = t3.destroy(), this.unSubPixelFix && this.unSubPixelFix(), this.alignedObjects = null, null;
8811          }
8812          createElement(t3) {
8813            return new this.Element(this, t3);
8814          }
8815          getRadialAttr(t3, e3) {
8816            return {
8817              cx: t3[0] - t3[2] / 2 + (e3.cx || 0) * t3[2],
8818              cy: t3[1] - t3[2] / 2 + (e3.cy || 0) * t3[2],
8819              r: (e3.r || 0) * t3[2]
8820            };
8821          }
8822          shadowDefinition(t3) {
8823            let e3 = [`highcharts-drop-shadow-${this.chartIndex}`, ...Object.keys(t3).map((e4) => `${e4}-${t3[e4]}`)].join("-").toLowerCase().replace(/[^a-z\d\-]/g, ""), i3 = j({
8824              color: "#000000",
8825              offsetX: 1,
8826              offsetY: 1,
8827              opacity: 0.15,
8828              width: 5
8829            }, t3);
8830            return this.defs.element.querySelector(`#${e3}`) || this.definition({
8831              tagName: "filter",
8832              attributes: {
8833                id: e3,
8834                filterUnits: i3.filterUnits
8835              },
8836              children: this.getShadowFilterContent(i3)
8837            }), e3;
8838          }
8839          getShadowFilterContent(t3) {
8840            return [{
8841              tagName: "feDropShadow",
8842              attributes: {
8843                dx: t3.offsetX,
8844                dy: t3.offsetY,
8845                "flood-color": t3.color,
8846                "flood-opacity": Math.min(5 * t3.opacity, 1),
8847                stdDeviation: t3.width / 2
8848              }
8849            }];
8850          }
8851          buildText(t3) {
8852            new h(t3).buildSVG();
8853          }
8854          getContrast(t3) {
8855            let e3 = i2.parse(t3).rgba.map((t4) => {
8856              let e4 = t4 / 255;
8857              return e4 <= 0.03928 ? e4 / 12.92 : Math.pow((e4 + 0.055) / 1.055, 2.4);
8858            }), s2 = 0.2126 * e3[0] + 0.7152 * e3[1] + 0.0722 * e3[2];
8859            return 1.05 / (s2 + 0.05) > (s2 + 0.05) / 0.05 ? "#FFFFFF" : "#000000";
8860          }
8861          button(e3, i3, s2, r2, o2 = {}, n2, a2, h2, l2, d2) {
8862            let p2 = this.label(e3, i3, s2, l2, void 0, void 0, d2, void 0, "button"), u12 = this.styledMode, g2 = arguments, f2 = 0;
8863            o2 = j(c.global.buttonTheme, o2), u12 && (delete o2.fill, delete o2.stroke, delete o2["stroke-width"]);
8864            let x2 = o2.states || {}, y2 = o2.style || {};
8865            delete o2.states, delete o2.style;
8866            let b2 = [t2.filterUserAttributes(o2)], v2 = [y2];
8867            return u12 || ["hover", "select", "disabled"].forEach((e4, i4) => {
8868              b2.push(j(b2[0], t2.filterUserAttributes(g2[i4 + 5] || x2[e4] || {}))), v2.push(b2[i4 + 1].style), delete b2[i4 + 1].style;
8869            }), C(p2.element, m ? "mouseover" : "mouseenter", function() {
8870              3 !== f2 && p2.setState(1);
8871            }), C(p2.element, m ? "mouseout" : "mouseleave", function() {
8872              3 !== f2 && p2.setState(f2);
8873            }), p2.setState = (t3 = 0) => {
8874              if (1 !== t3 && (p2.state = f2 = t3), p2.removeClass(/highcharts-button-(normal|hover|pressed|disabled)/).addClass("highcharts-button-" + ["normal", "hover", "pressed", "disabled"][t3]), !u12) {
8875                p2.attr(b2[t3]);
8876                let e4 = v2[t3];
8877                E(e4) && p2.css(e4);
8878              }
8879            }, p2.attr(b2[0]), !u12 && (p2.css(L({
8880              cursor: "default"
8881            }, y2)), d2 && p2.text.css({
8882              pointerEvents: "none"
8883            })), p2.on("touchstart", (t3) => t3.stopPropagation()).on("click", function(t3) {
8884              3 !== f2 && r2.call(p2, t3);
8885            });
8886          }
8887          crispLine(t3, e3) {
8888            let [i3, s2] = t3;
8889            return A(i3[1]) && i3[1] === s2[1] && (i3[1] = s2[1] = w(i3[1], e3)), A(i3[2]) && i3[2] === s2[2] && (i3[2] = s2[2] = w(i3[2], e3)), t3;
8890          }
8891          path(t3) {
8892            let e3 = this.styledMode ? {} : {
8893              fill: "none"
8894            };
8895            return O(t3) ? e3.d = t3 : E(t3) && L(e3, t3), this.createElement("path").attr(e3);
8896          }
8897          circle(t3, e3, i3) {
8898            let s2 = E(t3) ? t3 : void 0 === t3 ? {} : {
8899              x: t3,
8900              y: e3,
8901              r: i3
8902            }, r2 = this.createElement("circle");
8903            return r2.xSetter = r2.ySetter = function(t4, e4, i4) {
8904              i4.setAttribute("c" + e4, t4);
8905            }, r2.attr(s2);
8906          }
8907          arc(t3, e3, i3, s2, r2, o2) {
8908            let n2;
8909            E(t3) ? (e3 = (n2 = t3).y, i3 = n2.r, s2 = n2.innerR, r2 = n2.start, o2 = n2.end, t3 = n2.x) : n2 = {
8910              innerR: s2,
8911              start: r2,
8912              end: o2
8913            };
8914            let a2 = this.symbol("arc", t3, e3, i3, i3, n2);
8915            return a2.r = i3, a2;
8916          }
8917          rect(t3, e3, i3, s2, r2, o2) {
8918            let n2 = E(t3) ? t3 : void 0 === t3 ? {} : {
8919              x: t3,
8920              y: e3,
8921              r: r2,
8922              width: Math.max(i3 || 0, 0),
8923              height: Math.max(s2 || 0, 0)
8924            }, a2 = this.createElement("rect");
8925            return this.styledMode || (void 0 !== o2 && (n2["stroke-width"] = o2, L(n2, a2.crisp(n2))), n2.fill = "none"), a2.rSetter = function(t4, e4, i4) {
8926              a2.r = t4, k(i4, {
8927                rx: t4,
8928                ry: t4
8929              });
8930            }, a2.rGetter = function() {
8931              return a2.r || 0;
8932            }, a2.attr(n2);
8933          }
8934          roundedRect(t3) {
8935            return this.symbol("roundedRect").attr(t3);
8936          }
8937          setSize(t3, e3, i3) {
8938            this.width = t3, this.height = e3, this.boxWrapper.animate({
8939              width: t3,
8940              height: e3
8941            }, {
8942              step: function() {
8943                this.attr({
8944                  viewBox: "0 0 " + this.attr("width") + " " + this.attr("height")
8945                });
8946              },
8947              duration: B(i3, true) ? void 0 : 0
8948            }), this.alignElements();
8949          }
8950          g(t3) {
8951            let e3 = this.createElement("g");
8952            return t3 ? e3.attr({
8953              class: "highcharts-" + t3
8954            }) : e3;
8955          }
8956          image(t3, e3, i3, s2, r2, o2) {
8957            let n2 = {
8958              preserveAspectRatio: "none"
8959            };
8960            D2(e3) && (n2.x = e3), D2(i3) && (n2.y = i3), D2(s2) && (n2.width = s2), D2(r2) && (n2.height = r2);
8961            let a2 = this.createElement("image").attr(n2), h2 = function(e4) {
8962              a2.attr({
8963                href: t3
8964              }), o2.call(a2, e4);
8965            };
8966            if (o2) {
8967              a2.attr({
8968                href: "data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw=="
8969              });
8970              let e4 = new S2.Image();
8971              C(e4, "load", h2), e4.src = t3, e4.complete && h2({});
8972            } else a2.attr({
8973              href: t3
8974            });
8975            return a2;
8976          }
8977          symbol(t3, e3, i3, s2, r2, o2) {
8978            let n2, a2, h2, l2;
8979            let d2 = this, c2 = /^url\((.*?)\)$/, u12 = c2.test(t3), f2 = !u12 && (this.symbols[t3] ? t3 : "circle"), m2 = f2 && this.symbols[f2];
8980            if (m2) "number" == typeof e3 && (a2 = m2.call(this.symbols, e3 || 0, i3 || 0, s2 || 0, r2 || 0, o2)), n2 = this.path(a2), d2.styledMode || n2.attr("fill", "none"), L(n2, {
8981              symbolName: f2 || void 0,
8982              x: e3,
8983              y: i3,
8984              width: s2,
8985              height: r2
8986            }), o2 && L(n2, o2);
8987            else if (u12) {
8988              h2 = t3.match(c2)[1];
8989              let s3 = n2 = this.image(h2);
8990              s3.imgwidth = B(o2 && o2.width, v[h2] && v[h2].width), s3.imgheight = B(o2 && o2.height, v[h2] && v[h2].height), l2 = (t4) => t4.attr({
8991                width: t4.width,
8992                height: t4.height
8993              }), ["width", "height"].forEach((t4) => {
8994                s3[`${t4}Setter`] = function(t5, e4) {
8995                  this[e4] = t5;
8996                  let {
8997                    alignByTranslate: i4,
8998                    element: s4,
8999                    width: r3,
9000                    height: n3,
9001                    imgwidth: a3,
9002                    imgheight: h3
9003                  } = this, l3 = "width" === e4 ? a3 : h3, d3 = 1;
9004                  o2 && "within" === o2.backgroundSize && r3 && n3 && a3 && h3 ? (d3 = Math.min(r3 / a3, n3 / h3), k(s4, {
9005                    width: Math.round(a3 * d3),
9006                    height: Math.round(h3 * d3)
9007                  })) : s4 && l3 && s4.setAttribute(e4, l3), !i4 && a3 && h3 && this.translate(((r3 || 0) - a3 * d3) / 2, ((n3 || 0) - h3 * d3) / 2);
9008                };
9009              }), A(e3) && s3.attr({
9010                x: e3,
9011                y: i3
9012              }), s3.isImg = true, s3.symbolUrl = t3, A(s3.imgwidth) && A(s3.imgheight) ? l2(s3) : (s3.attr({
9013                width: 0,
9014                height: 0
9015              }), M("img", {
9016                onload: function() {
9017                  let t4 = p[d2.chartIndex];
9018                  0 === this.width && (T2(this, {
9019                    position: "absolute",
9020                    top: "-999em"
9021                  }), g.body.appendChild(this)), v[h2] = {
9022                    width: this.width,
9023                    height: this.height
9024                  }, s3.imgwidth = this.width, s3.imgheight = this.height, s3.element && l2(s3), this.parentNode && this.parentNode.removeChild(this), d2.imgCount--, d2.imgCount || !t4 || t4.hasLoaded || t4.onload();
9025                },
9026                src: h2
9027              }), this.imgCount++);
9028            }
9029            return n2;
9030          }
9031          clipRect(t3, e3, i3, s2) {
9032            return this.rect(t3, e3, i3, s2, 0);
9033          }
9034          text(t3, e3, i3, s2) {
9035            let r2 = {};
9036            if (s2 && (this.allowHTML || !this.forExport)) return this.html(t3, e3, i3);
9037            r2.x = Math.round(e3 || 0), i3 && (r2.y = Math.round(i3)), A(t3) && (r2.text = t3);
9038            let o2 = this.createElement("text").attr(r2);
9039            return s2 && (!this.forExport || this.allowHTML) || (o2.xSetter = function(t4, e4, i4) {
9040              let s3 = i4.getElementsByTagName("tspan"), r3 = i4.getAttribute(e4);
9041              for (let i5 = 0, o3; i5 < s3.length; i5++) (o3 = s3[i5]).getAttribute(e4) === r3 && o3.setAttribute(e4, t4);
9042              i4.setAttribute(e4, t4);
9043            }), o2;
9044          }
9045          fontMetrics(t3) {
9046            let e3 = R(o.prototype.getStyle.call(t3, "font-size") || 0), i3 = e3 < 24 ? e3 + 3 : Math.round(1.2 * e3), s2 = Math.round(0.8 * i3);
9047            return {
9048              h: i3,
9049              b: s2,
9050              f: e3
9051            };
9052          }
9053          rotCorr(t3, e3, i3) {
9054            let s2 = t3;
9055            return e3 && i3 && (s2 = Math.max(s2 * Math.cos(e3 * u11), 4)), {
9056              x: -t3 / 3 * Math.sin(e3 * u11),
9057              y: s2
9058            };
9059          }
9060          pathToSegments(t3) {
9061            let e3 = [], i3 = [], s2 = {
9062              A: 8,
9063              C: 7,
9064              H: 2,
9065              L: 3,
9066              M: 3,
9067              Q: 5,
9068              S: 5,
9069              T: 3,
9070              V: 2
9071            };
9072            for (let r2 = 0; r2 < t3.length; r2++) I(i3[0]) && D2(t3[r2]) && i3.length === s2[i3[0].toUpperCase()] && t3.splice(r2, 0, i3[0].replace("M", "L").replace("m", "l")), "string" == typeof t3[r2] && (i3.length && e3.push(i3.slice(0)), i3.length = 0), i3.push(t3[r2]);
9073            return e3.push(i3.slice(0)), e3;
9074          }
9075          label(t3, e3, i3, s2, r2, o2, a2, h2, l2) {
9076            return new n(this, t3, e3, i3, s2, r2, o2, a2, h2, l2);
9077          }
9078          alignElements() {
9079            this.alignedObjects.forEach((t3) => t3.align());
9080          }
9081        }
9082        return L(W.prototype, {
9083          Element: o,
9084          SVG_NS: b,
9085          escapes: {
9086            "&": "&amp;",
9087            "<": "&lt;",
9088            ">": "&gt;",
9089            "'": "&#39;",
9090            '"': "&quot;"
9091          },
9092          symbols: a,
9093          draw: y
9094        }), r.registerRendererType("svg", W, true), W;
9095      }), i(e, "Core/Renderer/HTML/HTMLElement.js", [e["Core/Renderer/HTML/AST.js"], e["Core/Globals.js"], e["Core/Renderer/SVG/SVGElement.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
9096        let {
9097          composed: r
9098        } = e2, {
9099          attr: o,
9100          css: n,
9101          createElement: a,
9102          defined: h,
9103          extend: l,
9104          pInt: d,
9105          pushUnique: c
9106        } = s;
9107        function p(t3, e3, s2) {
9108          let r2 = this.div?.style || s2.style;
9109          i2.prototype[`${e3}Setter`].call(this, t3, e3, s2), r2 && (r2[e3] = t3);
9110        }
9111        let u11 = (t3, e3) => {
9112          if (!t3.div) {
9113            let s2 = o(t3.element, "class"), r2 = t3.css, n2 = a("div", s2 ? {
9114              className: s2
9115            } : void 0, __spreadProps(__spreadValues({
9116              position: "absolute",
9117              left: `${t3.translateX || 0}px`,
9118              top: `${t3.translateY || 0}px`
9119            }, t3.styles), {
9120              display: t3.display,
9121              opacity: t3.opacity,
9122              visibility: t3.visibility
9123            }), t3.parentGroup?.div || e3);
9124            t3.classSetter = (t4, e4, i3) => {
9125              i3.setAttribute("class", t4), n2.className = t4;
9126            }, t3.translateXSetter = t3.translateYSetter = (e4, i3) => {
9127              t3[i3] = e4, n2.style["translateX" === i3 ? "left" : "top"] = `${e4}px`, t3.doTransform = true;
9128            }, t3.opacitySetter = t3.visibilitySetter = p, t3.css = (e4) => (r2.call(t3, e4), e4.cursor && (n2.style.cursor = e4.cursor), e4.pointerEvents && (n2.style.pointerEvents = e4.pointerEvents), t3), t3.on = function() {
9129              return i2.prototype.on.apply({
9130                element: n2,
9131                onEvents: t3.onEvents
9132              }, arguments), t3;
9133            }, t3.div = n2;
9134          }
9135          return t3.div;
9136        };
9137        class g extends i2 {
9138          static compose(t3) {
9139            c(r, this.compose) && (t3.prototype.html = function(t4, e3, i3) {
9140              return new g(this, "span").attr({
9141                text: t4,
9142                x: Math.round(e3),
9143                y: Math.round(i3)
9144              });
9145            });
9146          }
9147          constructor(t3, e3) {
9148            super(t3, e3), this.css(__spreadValues({
9149              position: "absolute"
9150            }, t3.styledMode ? {} : {
9151              fontFamily: t3.style.fontFamily,
9152              fontSize: t3.style.fontSize
9153            })), this.element.style.whiteSpace = "nowrap";
9154          }
9155          getSpanCorrection(t3, e3, i3) {
9156            this.xCorr = -t3 * i3, this.yCorr = -e3;
9157          }
9158          css(t3) {
9159            let e3;
9160            let {
9161              element: i3
9162            } = this, s2 = "SPAN" === i3.tagName && t3 && "width" in t3, r2 = s2 && t3.width;
9163            return s2 && (delete t3.width, this.textWidth = d(r2) || void 0, e3 = true), t3?.textOverflow === "ellipsis" && (t3.whiteSpace = "nowrap", t3.overflow = "hidden"), l(this.styles, t3), n(i3, t3), e3 && this.updateTransform(), this;
9164          }
9165          htmlGetBBox() {
9166            let {
9167              element: t3
9168            } = this;
9169            return {
9170              x: t3.offsetLeft,
9171              y: t3.offsetTop,
9172              width: t3.offsetWidth,
9173              height: t3.offsetHeight
9174            };
9175          }
9176          updateTransform() {
9177            if (!this.added) {
9178              this.alignOnAdd = true;
9179              return;
9180            }
9181            let {
9182              element: t3,
9183              renderer: e3,
9184              rotation: i3,
9185              rotationOriginX: s2,
9186              rotationOriginY: r2,
9187              styles: o2,
9188              textAlign: a2 = "left",
9189              textWidth: l2,
9190              translateX: d2 = 0,
9191              translateY: c2 = 0,
9192              x: p2 = 0,
9193              y: u12 = 0
9194            } = this, g2 = {
9195              left: 0,
9196              center: 0.5,
9197              right: 1
9198            }[a2], f2 = o2.whiteSpace;
9199            if (n(t3, {
9200              marginLeft: `${d2}px`,
9201              marginTop: `${c2}px`
9202            }), "SPAN" === t3.tagName) {
9203              let o3 = [i3, a2, t3.innerHTML, l2, this.textAlign].join(","), d3 = -(this.parentGroup?.padding * 1) || 0, c3, m = false;
9204              if (l2 !== this.oldTextWidth) {
9205                let e4 = this.textPxLength ? this.textPxLength : (n(t3, {
9206                  width: "",
9207                  whiteSpace: f2 || "nowrap"
9208                }), t3.offsetWidth), s3 = l2 || 0;
9209                (s3 > this.oldTextWidth || e4 > s3) && (/[ \-]/.test(t3.textContent || t3.innerText) || "ellipsis" === t3.style.textOverflow) && (n(t3, {
9210                  width: e4 > s3 || i3 ? l2 + "px" : "auto",
9211                  display: "block",
9212                  whiteSpace: f2 || "normal"
9213                }), this.oldTextWidth = l2, m = true);
9214              }
9215              this.hasBoxWidthChanged = m, o3 !== this.cTT && (c3 = e3.fontMetrics(t3).b, h(i3) && (i3 !== (this.oldRotation || 0) || a2 !== this.oldAlign) && this.setSpanRotation(i3, d3, d3), this.getSpanCorrection(!h(i3) && this.textPxLength || t3.offsetWidth, c3, g2));
9216              let {
9217                xCorr: x = 0,
9218                yCorr: y = 0
9219              } = this, b = (s2 ?? p2) - x - p2 - d3, v = (r2 ?? u12) - y - u12 - d3;
9220              n(t3, {
9221                left: `${p2 + x}px`,
9222                top: `${u12 + y}px`,
9223                transformOrigin: `${b}px ${v}px`
9224              }), this.cTT = o3, this.oldRotation = i3, this.oldAlign = a2;
9225            }
9226          }
9227          setSpanRotation(t3, e3, i3) {
9228            n(this.element, {
9229              transform: `rotate(${t3}deg)`,
9230              transformOrigin: `${e3}% ${i3}px`
9231            });
9232          }
9233          add(t3) {
9234            let e3;
9235            let i3 = this.renderer.box.parentNode, s2 = [];
9236            if (this.parentGroup = t3, t3 && !(e3 = t3.div)) {
9237              let r2 = t3;
9238              for (; r2; ) s2.push(r2), r2 = r2.parentGroup;
9239              for (let t4 of s2.reverse()) e3 = u11(t4, i3);
9240            }
9241            return (e3 || i3).appendChild(this.element), this.added = true, this.alignOnAdd && this.updateTransform(), this;
9242          }
9243          textSetter(e3) {
9244            e3 !== this.textStr && (delete this.bBox, delete this.oldTextWidth, t2.setElementHTML(this.element, e3 ?? ""), this.textStr = e3, this.doTransform = true);
9245          }
9246          alignSetter(t3) {
9247            this.alignValue = this.textAlign = t3, this.doTransform = true;
9248          }
9249          xSetter(t3, e3) {
9250            this[e3] = t3, this.doTransform = true;
9251          }
9252        }
9253        let f = g.prototype;
9254        return f.visibilitySetter = f.opacitySetter = p, f.ySetter = f.rotationSetter = f.rotationOriginXSetter = f.rotationOriginYSetter = f.xSetter, g;
9255      }), i(e, "Core/Axis/AxisDefaults.js", [], function() {
9256        var t2, e2;
9257        return (e2 = t2 || (t2 = {})).xAxis = {
9258          alignTicks: true,
9259          allowDecimals: void 0,
9260          panningEnabled: true,
9261          zIndex: 2,
9262          zoomEnabled: true,
9263          dateTimeLabelFormats: {
9264            millisecond: {
9265              main: "%H:%M:%S.%L",
9266              range: false
9267            },
9268            second: {
9269              main: "%H:%M:%S",
9270              range: false
9271            },
9272            minute: {
9273              main: "%H:%M",
9274              range: false
9275            },
9276            hour: {
9277              main: "%H:%M",
9278              range: false
9279            },
9280            day: {
9281              main: "%e %b"
9282            },
9283            week: {
9284              main: "%e %b"
9285            },
9286            month: {
9287              main: "%b '%y"
9288            },
9289            year: {
9290              main: "%Y"
9291            }
9292          },
9293          endOnTick: false,
9294          gridLineDashStyle: "Solid",
9295          gridZIndex: 1,
9296          labels: {
9297            autoRotationLimit: 80,
9298            distance: 15,
9299            enabled: true,
9300            indentation: 10,
9301            overflow: "justify",
9302            reserveSpace: void 0,
9303            rotation: void 0,
9304            staggerLines: 0,
9305            step: 0,
9306            useHTML: false,
9307            zIndex: 7,
9308            style: {
9309              color: "#333333",
9310              cursor: "default",
9311              fontSize: "0.8em"
9312            }
9313          },
9314          maxPadding: 0.01,
9315          minorGridLineDashStyle: "Solid",
9316          minorTickLength: 2,
9317          minorTickPosition: "outside",
9318          minorTicksPerMajor: 5,
9319          minPadding: 0.01,
9320          offset: void 0,
9321          reversed: void 0,
9322          reversedStacks: false,
9323          showEmpty: true,
9324          showFirstLabel: true,
9325          showLastLabel: true,
9326          startOfWeek: 1,
9327          startOnTick: false,
9328          tickLength: 10,
9329          tickPixelInterval: 100,
9330          tickmarkPlacement: "between",
9331          tickPosition: "outside",
9332          title: {
9333            align: "middle",
9334            useHTML: false,
9335            x: 0,
9336            y: 0,
9337            style: {
9338              color: "#666666",
9339              fontSize: "0.8em"
9340            }
9341          },
9342          visible: true,
9343          minorGridLineColor: "#f2f2f2",
9344          minorGridLineWidth: 1,
9345          minorTickColor: "#999999",
9346          lineColor: "#333333",
9347          lineWidth: 1,
9348          gridLineColor: "#e6e6e6",
9349          gridLineWidth: void 0,
9350          tickColor: "#333333"
9351        }, e2.yAxis = {
9352          reversedStacks: true,
9353          endOnTick: true,
9354          maxPadding: 0.05,
9355          minPadding: 0.05,
9356          tickPixelInterval: 72,
9357          showLastLabel: true,
9358          labels: {
9359            x: void 0
9360          },
9361          startOnTick: true,
9362          title: {
9363            text: "Values"
9364          },
9365          stackLabels: {
9366            animation: {},
9367            allowOverlap: false,
9368            enabled: false,
9369            crop: true,
9370            overflow: "justify",
9371            formatter: function() {
9372              let {
9373                numberFormatter: t3
9374              } = this.axis.chart;
9375              return t3(this.total || 0, -1);
9376            },
9377            style: {
9378              color: "#000000",
9379              fontSize: "0.7em",
9380              fontWeight: "bold",
9381              textOutline: "1px contrast"
9382            }
9383          },
9384          gridLineWidth: 1,
9385          lineWidth: 0
9386        }, t2;
9387      }), i(e, "Core/Foundation.js", [e["Core/Utilities.js"]], function(t2) {
9388        var e2;
9389        let {
9390          addEvent: i2,
9391          isFunction: s,
9392          objectEach: r,
9393          removeEvent: o
9394        } = t2;
9395        return (e2 || (e2 = {})).registerEventOptions = function(t3, e3) {
9396          t3.eventOptions = t3.eventOptions || {}, r(e3.events, function(e4, r2) {
9397            t3.eventOptions[r2] !== e4 && (t3.eventOptions[r2] && (o(t3, r2, t3.eventOptions[r2]), delete t3.eventOptions[r2]), s(e4) && (t3.eventOptions[r2] = e4, i2(t3, r2, e4, {
9398              order: 0
9399            })));
9400          });
9401        }, e2;
9402      }), i(e, "Core/Axis/Tick.js", [e["Core/Templating.js"], e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
9403        let {
9404          deg2rad: s
9405        } = e2, {
9406          clamp: r,
9407          correctFloat: o,
9408          defined: n,
9409          destroyObjectProperties: a,
9410          extend: h,
9411          fireEvent: l,
9412          isNumber: d,
9413          merge: c,
9414          objectEach: p,
9415          pick: u11
9416        } = i2;
9417        return class {
9418          constructor(t3, e3, i3, s2, r2) {
9419            this.isNew = true, this.isNewLabel = true, this.axis = t3, this.pos = e3, this.type = i3 || "", this.parameters = r2 || {}, this.tickmarkOffset = this.parameters.tickmarkOffset, this.options = this.parameters.options, l(this, "init"), i3 || s2 || this.addLabel();
9420          }
9421          addLabel() {
9422            let e3 = this, i3 = e3.axis, s2 = i3.options, r2 = i3.chart, a2 = i3.categories, c2 = i3.logarithmic, p2 = i3.names, g = e3.pos, f = u11(e3.options && e3.options.labels, s2.labels), m = i3.tickPositions, x = g === m[0], y = g === m[m.length - 1], b = (!f.step || 1 === f.step) && 1 === i3.tickInterval, v = m.info, S2 = e3.label, C, k, M, w = this.parameters.category || (a2 ? u11(a2[g], p2[g], g) : g);
9423            c2 && d(w) && (w = o(c2.lin2log(w))), i3.dateTime && (v ? C = (k = r2.time.resolveDTLFormat(s2.dateTimeLabelFormats[!s2.grid && v.higherRanks[g] || v.unitName])).main : d(w) && (C = i3.dateTime.getXDateFormat(w, s2.dateTimeLabelFormats || {}))), e3.isFirst = x, e3.isLast = y;
9424            let T2 = {
9425              axis: i3,
9426              chart: r2,
9427              dateTimeLabelFormat: C,
9428              isFirst: x,
9429              isLast: y,
9430              pos: g,
9431              tick: e3,
9432              tickPositionInfo: v,
9433              value: w
9434            };
9435            l(this, "labelFormat", T2);
9436            let A = (e4) => f.formatter ? f.formatter.call(e4, e4) : f.format ? (e4.text = i3.defaultLabelFormatter.call(e4), t2.format(f.format, e4, r2)) : i3.defaultLabelFormatter.call(e4), P = A.call(T2, T2), L = k && k.list;
9437            L ? e3.shortenLabel = function() {
9438              for (M = 0; M < L.length; M++) if (h(T2, {
9439                dateTimeLabelFormat: L[M]
9440              }), S2.attr({
9441                text: A.call(T2, T2)
9442              }), S2.getBBox().width < i3.getSlotWidth(e3) - 2 * (f.padding || 0)) return;
9443              S2.attr({
9444                text: ""
9445              });
9446            } : e3.shortenLabel = void 0, b && i3._addedPlotLB && e3.moveLabel(P, f), n(S2) || e3.movedLabel ? S2 && S2.textStr !== P && !b && (!S2.textWidth || f.style.width || S2.styles.width || S2.css({
9447              width: null
9448            }), S2.attr({
9449              text: P
9450            }), S2.textPxLength = S2.getBBox().width) : (e3.label = S2 = e3.createLabel(P, f), e3.rotation = 0);
9451          }
9452          createLabel(t3, e3, i3) {
9453            let s2 = this.axis, r2 = s2.chart, o2 = n(t3) && e3.enabled ? r2.renderer.text(t3, i3?.x, i3?.y, e3.useHTML).add(s2.labelGroup) : void 0;
9454            return o2 && (r2.styledMode || o2.css(c(e3.style)), o2.textPxLength = o2.getBBox().width), o2;
9455          }
9456          destroy() {
9457            a(this, this.axis);
9458          }
9459          getPosition(t3, e3, i3, s2) {
9460            let n2 = this.axis, a2 = n2.chart, h2 = s2 && a2.oldChartHeight || a2.chartHeight, d2 = {
9461              x: t3 ? o(n2.translate(e3 + i3, void 0, void 0, s2) + n2.transB) : n2.left + n2.offset + (n2.opposite ? (s2 && a2.oldChartWidth || a2.chartWidth) - n2.right - n2.left : 0),
9462              y: t3 ? h2 - n2.bottom + n2.offset - (n2.opposite ? n2.height : 0) : o(h2 - n2.translate(e3 + i3, void 0, void 0, s2) - n2.transB)
9463            };
9464            return d2.y = r(d2.y, -1e9, 1e9), l(this, "afterGetPosition", {
9465              pos: d2
9466            }), d2;
9467          }
9468          getLabelPosition(t3, e3, i3, r2, o2, a2, h2, d2) {
9469            let c2, p2;
9470            let g = this.axis, f = g.transA, m = g.isLinked && g.linkedParent ? g.linkedParent.reversed : g.reversed, x = g.staggerLines, y = g.tickRotCorr || {
9471              x: 0,
9472              y: 0
9473            }, b = r2 || g.reserveSpaceDefault ? 0 : -g.labelOffset * ("center" === g.labelAlign ? 0.5 : 1), v = o2.distance, S2 = {};
9474            return c2 = 0 === g.side ? i3.rotation ? -v : -i3.getBBox().height : 2 === g.side ? y.y + v : Math.cos(i3.rotation * s) * (y.y - i3.getBBox(false, 0).height / 2), n(o2.y) && (c2 = 0 === g.side && g.horiz ? o2.y + c2 : o2.y), t3 = t3 + u11(o2.x, [0, 1, 0, -1][g.side] * v) + b + y.x - (a2 && r2 ? a2 * f * (m ? -1 : 1) : 0), e3 = e3 + c2 - (a2 && !r2 ? a2 * f * (m ? 1 : -1) : 0), x && (p2 = h2 / (d2 || 1) % x, g.opposite && (p2 = x - p2 - 1), e3 += p2 * (g.labelOffset / x)), S2.x = t3, S2.y = Math.round(e3), l(this, "afterGetLabelPosition", {
9475              pos: S2,
9476              tickmarkOffset: a2,
9477              index: h2
9478            }), S2;
9479          }
9480          getLabelSize() {
9481            return this.label ? this.label.getBBox()[this.axis.horiz ? "height" : "width"] : 0;
9482          }
9483          getMarkPath(t3, e3, i3, s2, r2 = false, o2) {
9484            return o2.crispLine([["M", t3, e3], ["L", t3 + (r2 ? 0 : -i3), e3 + (r2 ? i3 : 0)]], s2);
9485          }
9486          handleOverflow(t3) {
9487            let e3 = this.axis, i3 = e3.options.labels, r2 = t3.x, o2 = e3.chart.chartWidth, n2 = e3.chart.spacing, a2 = u11(e3.labelLeft, Math.min(e3.pos, n2[3])), h2 = u11(e3.labelRight, Math.max(e3.isRadial ? 0 : e3.pos + e3.len, o2 - n2[1])), l2 = this.label, d2 = this.rotation, c2 = {
9488              left: 0,
9489              center: 0.5,
9490              right: 1
9491            }[e3.labelAlign || l2.attr("align")], p2 = l2.getBBox().width, g = e3.getSlotWidth(this), f = {}, m = g, x = 1, y, b, v;
9492            d2 || "justify" !== i3.overflow ? d2 < 0 && r2 - c2 * p2 < a2 ? v = Math.round(r2 / Math.cos(d2 * s) - a2) : d2 > 0 && r2 + c2 * p2 > h2 && (v = Math.round((o2 - r2) / Math.cos(d2 * s))) : (y = r2 - c2 * p2, b = r2 + (1 - c2) * p2, y < a2 ? m = t3.x + m * (1 - c2) - a2 : b > h2 && (m = h2 - t3.x + m * c2, x = -1), (m = Math.min(g, m)) < g && "center" === e3.labelAlign && (t3.x += x * (g - m - c2 * (g - Math.min(p2, m)))), (p2 > m || e3.autoRotation && (l2.styles || {}).width) && (v = m)), v && (this.shortenLabel ? this.shortenLabel() : (f.width = Math.floor(v) + "px", (i3.style || {}).textOverflow || (f.textOverflow = "ellipsis"), l2.css(f)));
9493          }
9494          moveLabel(t3, e3) {
9495            let i3 = this, s2 = i3.label, r2 = i3.axis, o2 = false, n2;
9496            s2 && s2.textStr === t3 ? (i3.movedLabel = s2, o2 = true, delete i3.label) : p(r2.ticks, function(e4) {
9497              o2 || e4.isNew || e4 === i3 || !e4.label || e4.label.textStr !== t3 || (i3.movedLabel = e4.label, o2 = true, e4.labelPos = i3.movedLabel.xy, delete e4.label);
9498            }), !o2 && (i3.labelPos || s2) && (n2 = i3.labelPos || s2.xy, i3.movedLabel = i3.createLabel(t3, e3, n2), i3.movedLabel && i3.movedLabel.attr({
9499              opacity: 0
9500            }));
9501          }
9502          render(t3, e3, i3) {
9503            let s2 = this.axis, r2 = s2.horiz, n2 = this.pos, a2 = u11(this.tickmarkOffset, s2.tickmarkOffset), h2 = this.getPosition(r2, n2, a2, e3), d2 = h2.x, c2 = h2.y, p2 = s2.pos, g = p2 + s2.len, f = r2 ? d2 : c2;
9504            !s2.chart.polar && this.isNew && (o(f) < p2 || f > g) && (i3 = 0);
9505            let m = u11(i3, this.label && this.label.newOpacity, 1);
9506            i3 = u11(i3, 1), this.isActive = true, this.renderGridLine(e3, i3), this.renderMark(h2, i3), this.renderLabel(h2, e3, m, t3), this.isNew = false, l(this, "afterRender");
9507          }
9508          renderGridLine(t3, e3) {
9509            let i3 = this.axis, s2 = i3.options, r2 = {}, o2 = this.pos, n2 = this.type, a2 = u11(this.tickmarkOffset, i3.tickmarkOffset), h2 = i3.chart.renderer, l2 = this.gridLine, d2, c2 = s2.gridLineWidth, p2 = s2.gridLineColor, g = s2.gridLineDashStyle;
9510            "minor" === this.type && (c2 = s2.minorGridLineWidth, p2 = s2.minorGridLineColor, g = s2.minorGridLineDashStyle), l2 || (i3.chart.styledMode || (r2.stroke = p2, r2["stroke-width"] = c2 || 0, r2.dashstyle = g), n2 || (r2.zIndex = 1), t3 && (e3 = 0), this.gridLine = l2 = h2.path().attr(r2).addClass("highcharts-" + (n2 ? n2 + "-" : "") + "grid-line").add(i3.gridGroup)), l2 && (d2 = i3.getPlotLinePath({
9511              value: o2 + a2,
9512              lineWidth: l2.strokeWidth(),
9513              force: "pass",
9514              old: t3,
9515              acrossPanes: false
9516            })) && l2[t3 || this.isNew ? "attr" : "animate"]({
9517              d: d2,
9518              opacity: e3
9519            });
9520          }
9521          renderMark(t3, e3) {
9522            let i3 = this.axis, s2 = i3.options, r2 = i3.chart.renderer, o2 = this.type, n2 = i3.tickSize(o2 ? o2 + "Tick" : "tick"), a2 = t3.x, h2 = t3.y, l2 = u11(s2["minor" !== o2 ? "tickWidth" : "minorTickWidth"], !o2 && i3.isXAxis ? 1 : 0), d2 = s2["minor" !== o2 ? "tickColor" : "minorTickColor"], c2 = this.mark, p2 = !c2;
9523            n2 && (i3.opposite && (n2[0] = -n2[0]), c2 || (this.mark = c2 = r2.path().addClass("highcharts-" + (o2 ? o2 + "-" : "") + "tick").add(i3.axisGroup), i3.chart.styledMode || c2.attr({
9524              stroke: d2,
9525              "stroke-width": l2
9526            })), c2[p2 ? "attr" : "animate"]({
9527              d: this.getMarkPath(a2, h2, n2[0], c2.strokeWidth(), i3.horiz, r2),
9528              opacity: e3
9529            }));
9530          }
9531          renderLabel(t3, e3, i3, s2) {
9532            let r2 = this.axis, o2 = r2.horiz, n2 = r2.options, a2 = this.label, h2 = n2.labels, l2 = h2.step, c2 = u11(this.tickmarkOffset, r2.tickmarkOffset), p2 = t3.x, g = t3.y, f = true;
9533            a2 && d(p2) && (a2.xy = t3 = this.getLabelPosition(p2, g, a2, o2, h2, c2, s2, l2), (!this.isFirst || this.isLast || n2.showFirstLabel) && (!this.isLast || this.isFirst || n2.showLastLabel) ? !o2 || h2.step || h2.rotation || e3 || 0 === i3 || this.handleOverflow(t3) : f = false, l2 && s2 % l2 && (f = false), f && d(t3.y) ? (t3.opacity = i3, a2[this.isNewLabel ? "attr" : "animate"](t3).show(true), this.isNewLabel = false) : (a2.hide(), this.isNewLabel = true));
9534          }
9535          replaceMovedLabel() {
9536            let t3 = this.label, e3 = this.axis;
9537            t3 && !this.isNew && (t3.animate({
9538              opacity: 0
9539            }, void 0, t3.destroy), delete this.label), e3.isDirty = true, this.label = this.movedLabel, delete this.movedLabel;
9540          }
9541        };
9542      }), i(e, "Core/Axis/Axis.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Axis/AxisDefaults.js"], e["Core/Color/Color.js"], e["Core/Defaults.js"], e["Core/Foundation.js"], e["Core/Globals.js"], e["Core/Axis/Tick.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, r, o, n, a) {
9543        let {
9544          animObject: h
9545        } = t2, {
9546          xAxis: l,
9547          yAxis: d
9548        } = e2, {
9549          defaultOptions: c
9550        } = s, {
9551          registerEventOptions: p
9552        } = r, {
9553          deg2rad: u11
9554        } = o, {
9555          arrayMax: g,
9556          arrayMin: f,
9557          clamp: m,
9558          correctFloat: x,
9559          defined: y,
9560          destroyObjectProperties: b,
9561          erase: v,
9562          error: S2,
9563          extend: C,
9564          fireEvent: k,
9565          getClosestDistance: M,
9566          insertItem: w,
9567          isArray: T2,
9568          isNumber: A,
9569          isString: P,
9570          merge: L,
9571          normalizeTickInterval: O,
9572          objectEach: D2,
9573          pick: E,
9574          relativeLength: I,
9575          removeEvent: j,
9576          splat: B,
9577          syncTimeout: R
9578        } = a, z = (t3, e3) => O(e3, void 0, void 0, E(t3.options.allowDecimals, e3 < 0.5 || void 0 !== t3.tickAmount), !!t3.tickAmount);
9579        C(c, {
9580          xAxis: l,
9581          yAxis: L(l, d)
9582        });
9583        class N {
9584          constructor(t3, e3, i3) {
9585            this.init(t3, e3, i3);
9586          }
9587          init(t3, e3, i3 = this.coll) {
9588            let s2 = "xAxis" === i3, r2 = this.isZAxis || (t3.inverted ? !s2 : s2);
9589            this.chart = t3, this.horiz = r2, this.isXAxis = s2, this.coll = i3, k(this, "init", {
9590              userOptions: e3
9591            }), this.opposite = E(e3.opposite, this.opposite), this.side = E(e3.side, this.side, r2 ? this.opposite ? 0 : 2 : this.opposite ? 1 : 3), this.setOptions(e3);
9592            let o2 = this.options, n2 = o2.labels;
9593            this.type ?? (this.type = o2.type || "linear"), this.uniqueNames ?? (this.uniqueNames = o2.uniqueNames ?? true), k(this, "afterSetType"), this.userOptions = e3, this.minPixelPadding = 0, this.reversed = E(o2.reversed, this.reversed), this.visible = o2.visible, this.zoomEnabled = o2.zoomEnabled, this.hasNames = "category" === this.type || true === o2.categories, this.categories = T2(o2.categories) && o2.categories || (this.hasNames ? [] : void 0), this.names || (this.names = [], this.names.keys = {}), this.plotLinesAndBandsGroups = {}, this.positiveValuesOnly = !!this.logarithmic, this.isLinked = y(o2.linkedTo), this.ticks = {}, this.labelEdge = [], this.minorTicks = {}, this.plotLinesAndBands = [], this.alternateBands = {}, this.len ?? (this.len = 0), this.minRange = this.userMinRange = o2.minRange || o2.maxZoom, this.range = o2.range, this.offset = o2.offset || 0, this.max = void 0, this.min = void 0;
9594            let a2 = E(o2.crosshair, B(t3.options.tooltip.crosshairs)[s2 ? 0 : 1]);
9595            this.crosshair = true === a2 ? {} : a2, -1 === t3.axes.indexOf(this) && (s2 ? t3.axes.splice(t3.xAxis.length, 0, this) : t3.axes.push(this), w(this, t3[this.coll])), t3.orderItems(this.coll), this.series = this.series || [], t3.inverted && !this.isZAxis && s2 && !y(this.reversed) && (this.reversed = true), this.labelRotation = A(n2.rotation) ? n2.rotation : void 0, p(this, o2), k(this, "afterInit");
9596          }
9597          setOptions(t3) {
9598            let e3 = this.horiz ? {
9599              labels: {
9600                autoRotation: [-45],
9601                padding: 4
9602              },
9603              margin: 15
9604            } : {
9605              labels: {
9606                padding: 1
9607              },
9608              title: {
9609                rotation: 90 * this.side
9610              }
9611            };
9612            this.options = L(e3, c[this.coll], t3), k(this, "afterSetOptions", {
9613              userOptions: t3
9614            });
9615          }
9616          defaultLabelFormatter() {
9617            let t3 = this.axis, {
9618              numberFormatter: e3
9619            } = this.chart, i3 = A(this.value) ? this.value : NaN, s2 = t3.chart.time, r2 = t3.categories, o2 = this.dateTimeLabelFormat, n2 = c.lang, a2 = n2.numericSymbols, h2 = n2.numericSymbolMagnitude || 1e3, l2 = t3.logarithmic ? Math.abs(i3) : t3.tickInterval, d2 = a2 && a2.length, p2, u12;
9620            if (r2) u12 = `${this.value}`;
9621            else if (o2) u12 = s2.dateFormat(o2, i3);
9622            else if (d2 && a2 && l2 >= 1e3) for (; d2-- && void 0 === u12; ) l2 >= (p2 = Math.pow(h2, d2 + 1)) && 10 * i3 % p2 == 0 && null !== a2[d2] && 0 !== i3 && (u12 = e3(i3 / p2, -1) + a2[d2]);
9623            return void 0 === u12 && (u12 = Math.abs(i3) >= 1e4 ? e3(i3, -1) : e3(i3, -1, void 0, "")), u12;
9624          }
9625          getSeriesExtremes() {
9626            let t3;
9627            let e3 = this;
9628            k(this, "getSeriesExtremes", null, function() {
9629              e3.hasVisibleSeries = false, e3.dataMin = e3.dataMax = e3.threshold = void 0, e3.softThreshold = !e3.isXAxis, e3.series.forEach((i3) => {
9630                if (i3.reserveSpace()) {
9631                  let s2 = i3.options, r2, o2 = s2.threshold, n2, a2;
9632                  if (e3.hasVisibleSeries = true, e3.positiveValuesOnly && 0 >= (o2 || 0) && (o2 = void 0), e3.isXAxis) (r2 = i3.xData) && r2.length && (r2 = e3.logarithmic ? r2.filter((t4) => t4 > 0) : r2, n2 = (t3 = i3.getXExtremes(r2)).min, a2 = t3.max, A(n2) || n2 instanceof Date || (r2 = r2.filter(A), n2 = (t3 = i3.getXExtremes(r2)).min, a2 = t3.max), r2.length && (e3.dataMin = Math.min(E(e3.dataMin, n2), n2), e3.dataMax = Math.max(E(e3.dataMax, a2), a2)));
9633                  else {
9634                    let t4 = i3.applyExtremes();
9635                    A(t4.dataMin) && (n2 = t4.dataMin, e3.dataMin = Math.min(E(e3.dataMin, n2), n2)), A(t4.dataMax) && (a2 = t4.dataMax, e3.dataMax = Math.max(E(e3.dataMax, a2), a2)), y(o2) && (e3.threshold = o2), (!s2.softThreshold || e3.positiveValuesOnly) && (e3.softThreshold = false);
9636                  }
9637                }
9638              });
9639            }), k(this, "afterGetSeriesExtremes");
9640          }
9641          translate(t3, e3, i3, s2, r2, o2) {
9642            let n2 = this.linkedParent || this, a2 = s2 && n2.old ? n2.old.min : n2.min;
9643            if (!A(a2)) return NaN;
9644            let h2 = n2.minPixelPadding, l2 = (n2.isOrdinal || n2.brokenAxis?.hasBreaks || n2.logarithmic && r2) && n2.lin2val, d2 = 1, c2 = 0, p2 = s2 && n2.old ? n2.old.transA : n2.transA, u12 = 0;
9645            return p2 || (p2 = n2.transA), i3 && (d2 *= -1, c2 = n2.len), n2.reversed && (d2 *= -1, c2 -= d2 * (n2.sector || n2.len)), e3 ? (u12 = (t3 = t3 * d2 + c2 - h2) / p2 + a2, l2 && (u12 = n2.lin2val(u12))) : (l2 && (t3 = n2.val2lin(t3)), u12 = d2 * (t3 - a2) * p2 + c2 + d2 * h2 + (A(o2) ? p2 * o2 : 0), n2.isRadial || (u12 = x(u12))), u12;
9646          }
9647          toPixels(t3, e3) {
9648            return this.translate(t3, false, !this.horiz, void 0, true) + (e3 ? 0 : this.pos);
9649          }
9650          toValue(t3, e3) {
9651            return this.translate(t3 - (e3 ? 0 : this.pos), true, !this.horiz, void 0, true);
9652          }
9653          getPlotLinePath(t3) {
9654            let e3 = this, i3 = e3.chart, s2 = e3.left, r2 = e3.top, o2 = t3.old, n2 = t3.value, a2 = t3.lineWidth, h2 = o2 && i3.oldChartHeight || i3.chartHeight, l2 = o2 && i3.oldChartWidth || i3.chartWidth, d2 = e3.transB, c2 = t3.translatedValue, p2 = t3.force, u12, g2, f2, x2, y2;
9655            function b2(t4, e4, i4) {
9656              return "pass" !== p2 && (t4 < e4 || t4 > i4) && (p2 ? t4 = m(t4, e4, i4) : y2 = true), t4;
9657            }
9658            let v2 = {
9659              value: n2,
9660              lineWidth: a2,
9661              old: o2,
9662              force: p2,
9663              acrossPanes: t3.acrossPanes,
9664              translatedValue: c2
9665            };
9666            return k(this, "getPlotLinePath", v2, function(t4) {
9667              u12 = f2 = (c2 = m(c2 = E(c2, e3.translate(n2, void 0, void 0, o2)), -1e9, 1e9)) + d2, g2 = x2 = h2 - c2 - d2, A(c2) ? e3.horiz ? (g2 = r2, x2 = h2 - e3.bottom + (e3.options.isInternal ? 0 : i3.scrollablePixelsY || 0), u12 = f2 = b2(u12, s2, s2 + e3.width)) : (u12 = s2, f2 = l2 - e3.right + (i3.scrollablePixelsX || 0), g2 = x2 = b2(g2, r2, r2 + e3.height)) : (y2 = true, p2 = false), t4.path = y2 && !p2 ? void 0 : i3.renderer.crispLine([["M", u12, g2], ["L", f2, x2]], a2 || 1);
9668            }), v2.path;
9669          }
9670          getLinearTickPositions(t3, e3, i3) {
9671            let s2, r2, o2;
9672            let n2 = x(Math.floor(e3 / t3) * t3), a2 = x(Math.ceil(i3 / t3) * t3), h2 = [];
9673            if (x(n2 + t3) === n2 && (o2 = 20), this.single) return [e3];
9674            for (s2 = n2; s2 <= a2 && (h2.push(s2), (s2 = x(s2 + t3, o2)) !== r2); ) r2 = s2;
9675            return h2;
9676          }
9677          getMinorTickInterval() {
9678            let {
9679              minorTicks: t3,
9680              minorTickInterval: e3
9681            } = this.options;
9682            return true === t3 ? E(e3, "auto") : false !== t3 ? e3 : void 0;
9683          }
9684          getMinorTickPositions() {
9685            let t3 = this.options, e3 = this.tickPositions, i3 = this.minorTickInterval, s2 = this.pointRangePadding || 0, r2 = (this.min || 0) - s2, o2 = (this.max || 0) + s2, n2 = o2 - r2, a2 = [], h2;
9686            if (n2 && n2 / i3 < this.len / 3) {
9687              let s3 = this.logarithmic;
9688              if (s3) this.paddedTicks.forEach(function(t4, e4, r3) {
9689                e4 && a2.push.apply(a2, s3.getLogTickPositions(i3, r3[e4 - 1], r3[e4], true));
9690              });
9691              else if (this.dateTime && "auto" === this.getMinorTickInterval()) a2 = a2.concat(this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(i3), r2, o2, t3.startOfWeek));
9692              else for (h2 = r2 + (e3[0] - r2) % i3; h2 <= o2 && h2 !== a2[0]; h2 += i3) a2.push(h2);
9693            }
9694            return 0 !== a2.length && this.trimTicks(a2), a2;
9695          }
9696          adjustForMinRange() {
9697            let t3 = this.options, e3 = this.logarithmic, {
9698              max: i3,
9699              min: s2,
9700              minRange: r2
9701            } = this, o2, n2, a2, h2;
9702            this.isXAxis && void 0 === r2 && !e3 && (r2 = y(t3.min) || y(t3.max) || y(t3.floor) || y(t3.ceiling) ? null : Math.min(5 * (M(this.series.map((t4) => (t4.xIncrement ? t4.xData?.slice(0, 2) : t4.xData) || [])) || 0), this.dataMax - this.dataMin)), A(i3) && A(s2) && A(r2) && i3 - s2 < r2 && (n2 = this.dataMax - this.dataMin >= r2, o2 = (r2 - i3 + s2) / 2, a2 = [s2 - o2, E(t3.min, s2 - o2)], n2 && (a2[2] = e3 ? e3.log2lin(this.dataMin) : this.dataMin), h2 = [(s2 = g(a2)) + r2, E(t3.max, s2 + r2)], n2 && (h2[2] = e3 ? e3.log2lin(this.dataMax) : this.dataMax), (i3 = f(h2)) - s2 < r2 && (a2[0] = i3 - r2, a2[1] = E(t3.min, i3 - r2), s2 = g(a2))), this.minRange = r2, this.min = s2, this.max = i3;
9703          }
9704          getClosest() {
9705            let t3, e3;
9706            if (this.categories) e3 = 1;
9707            else {
9708              let i3 = [];
9709              this.series.forEach(function(t4) {
9710                let s2 = t4.closestPointRange;
9711                t4.xData?.length === 1 ? i3.push(t4.xData[0]) : !t4.noSharedTooltip && y(s2) && t4.reserveSpace() && (e3 = y(e3) ? Math.min(e3, s2) : s2);
9712              }), i3.length && (i3.sort((t4, e4) => t4 - e4), t3 = M([i3]));
9713            }
9714            return t3 && e3 ? Math.min(t3, e3) : t3 || e3;
9715          }
9716          nameToX(t3) {
9717            let e3 = T2(this.options.categories), i3 = e3 ? this.categories : this.names, s2 = t3.options.x, r2;
9718            return t3.series.requireSorting = false, y(s2) || (s2 = this.uniqueNames && i3 ? e3 ? i3.indexOf(t3.name) : E(i3.keys[t3.name], -1) : t3.series.autoIncrement()), -1 === s2 ? !e3 && i3 && (r2 = i3.length) : r2 = s2, void 0 !== r2 ? (this.names[r2] = t3.name, this.names.keys[t3.name] = r2) : t3.x && (r2 = t3.x), r2;
9719          }
9720          updateNames() {
9721            let t3 = this, e3 = this.names;
9722            e3.length > 0 && (Object.keys(e3.keys).forEach(function(t4) {
9723              delete e3.keys[t4];
9724            }), e3.length = 0, this.minRange = this.userMinRange, (this.series || []).forEach((e4) => {
9725              e4.xIncrement = null, (!e4.points || e4.isDirtyData) && (t3.max = Math.max(t3.max, e4.xData.length - 1), e4.processData(), e4.generatePoints()), e4.data.forEach(function(i3, s2) {
9726                let r2;
9727                i3?.options && void 0 !== i3.name && void 0 !== (r2 = t3.nameToX(i3)) && r2 !== i3.x && (i3.x = r2, e4.xData[s2] = r2);
9728              });
9729            }));
9730          }
9731          setAxisTranslation() {
9732            let t3 = this, e3 = t3.max - t3.min, i3 = t3.linkedParent, s2 = !!t3.categories, r2 = t3.isXAxis, o2 = t3.axisPointRange || 0, n2, a2 = 0, h2 = 0, l2, d2 = t3.transA;
9733            (r2 || s2 || o2) && (n2 = t3.getClosest(), i3 ? (a2 = i3.minPointOffset, h2 = i3.pointRangePadding) : t3.series.forEach(function(e4) {
9734              let i4 = s2 ? 1 : r2 ? E(e4.options.pointRange, n2, 0) : t3.axisPointRange || 0, l3 = e4.options.pointPlacement;
9735              if (o2 = Math.max(o2, i4), !t3.single || s2) {
9736                let t4 = e4.is("xrange") ? !r2 : r2;
9737                a2 = Math.max(a2, t4 && P(l3) ? 0 : i4 / 2), h2 = Math.max(h2, t4 && "on" === l3 ? 0 : i4);
9738              }
9739            }), l2 = t3.ordinal && t3.ordinal.slope && n2 ? t3.ordinal.slope / n2 : 1, t3.minPointOffset = a2 *= l2, t3.pointRangePadding = h2 *= l2, t3.pointRange = Math.min(o2, t3.single && s2 ? 1 : e3), r2 && n2 && (t3.closestPointRange = n2)), t3.translationSlope = t3.transA = d2 = t3.staticScale || t3.len / (e3 + h2 || 1), t3.transB = t3.horiz ? t3.left : t3.bottom, t3.minPixelPadding = d2 * a2, k(this, "afterSetAxisTranslation");
9740          }
9741          minFromRange() {
9742            let {
9743              max: t3,
9744              min: e3
9745            } = this;
9746            return A(t3) && A(e3) && t3 - e3 || void 0;
9747          }
9748          setTickInterval(t3) {
9749            let {
9750              categories: e3,
9751              chart: i3,
9752              dataMax: s2,
9753              dataMin: r2,
9754              dateTime: o2,
9755              isXAxis: n2,
9756              logarithmic: a2,
9757              options: h2,
9758              softThreshold: l2
9759            } = this, d2 = A(this.threshold) ? this.threshold : void 0, c2 = this.minRange || 0, {
9760              ceiling: p2,
9761              floor: u12,
9762              linkedTo: g2,
9763              softMax: f2,
9764              softMin: m2
9765            } = h2, b2 = A(g2) && i3[this.coll]?.[g2], v2 = h2.tickPixelInterval, C2 = h2.maxPadding, M2 = h2.minPadding, w2 = 0, T3, P2 = A(h2.tickInterval) && h2.tickInterval >= 0 ? h2.tickInterval : void 0, L2, O2, D3, I2;
9766            if (o2 || e3 || b2 || this.getTickAmount(), D3 = E(this.userMin, h2.min), I2 = E(this.userMax, h2.max), b2 ? (this.linkedParent = b2, T3 = b2.getExtremes(), this.min = E(T3.min, T3.dataMin), this.max = E(T3.max, T3.dataMax), this.type !== b2.type && S2(11, true, i3)) : (l2 && y(d2) && A(s2) && A(r2) && (r2 >= d2 ? (L2 = d2, M2 = 0) : s2 <= d2 && (O2 = d2, C2 = 0)), this.min = E(D3, L2, r2), this.max = E(I2, O2, s2)), A(this.max) && A(this.min) && (a2 && (this.positiveValuesOnly && !t3 && 0 >= Math.min(this.min, E(r2, this.min)) && S2(10, true, i3), this.min = x(a2.log2lin(this.min), 16), this.max = x(a2.log2lin(this.max), 16)), this.range && A(r2) && (this.userMin = this.min = D3 = Math.max(r2, this.minFromRange() || 0), this.userMax = I2 = this.max, this.range = void 0)), k(this, "foundExtremes"), this.adjustForMinRange(), A(this.min) && A(this.max)) {
9767              if (!A(this.userMin) && A(m2) && m2 < this.min && (this.min = D3 = m2), !A(this.userMax) && A(f2) && f2 > this.max && (this.max = I2 = f2), e3 || this.axisPointRange || this.stacking?.usePercentage || b2 || !(w2 = this.max - this.min) || (!y(D3) && M2 && (this.min -= w2 * M2), y(I2) || !C2 || (this.max += w2 * C2)), !A(this.userMin) && A(u12) && (this.min = Math.max(this.min, u12)), !A(this.userMax) && A(p2) && (this.max = Math.min(this.max, p2)), l2 && A(r2) && A(s2)) {
9768                let t4 = d2 || 0;
9769                !y(D3) && this.min < t4 && r2 >= t4 ? this.min = h2.minRange ? Math.min(t4, this.max - c2) : t4 : !y(I2) && this.max > t4 && s2 <= t4 && (this.max = h2.minRange ? Math.max(t4, this.min + c2) : t4);
9770              }
9771              !i3.polar && this.min > this.max && (y(h2.min) ? this.max = this.min : y(h2.max) && (this.min = this.max)), w2 = this.max - this.min;
9772            }
9773            if (this.min !== this.max && A(this.min) && A(this.max) ? b2 && !P2 && v2 === b2.options.tickPixelInterval ? this.tickInterval = P2 = b2.tickInterval : this.tickInterval = E(P2, this.tickAmount ? w2 / Math.max(this.tickAmount - 1, 1) : void 0, e3 ? 1 : w2 * v2 / Math.max(this.len, v2)) : this.tickInterval = 1, n2 && !t3) {
9774              let t4 = this.min !== this.old?.min || this.max !== this.old?.max;
9775              this.series.forEach(function(e4) {
9776                e4.forceCrop = e4.forceCropping?.(), e4.processData(t4);
9777              }), k(this, "postProcessData", {
9778                hasExtremesChanged: t4
9779              });
9780            }
9781            this.setAxisTranslation(), k(this, "initialAxisTranslation"), this.pointRange && !P2 && (this.tickInterval = Math.max(this.pointRange, this.tickInterval));
9782            let j2 = E(h2.minTickInterval, o2 && !this.series.some((t4) => t4.noSharedTooltip) ? this.closestPointRange : 0);
9783            !P2 && this.tickInterval < j2 && (this.tickInterval = j2), o2 || a2 || P2 || (this.tickInterval = z(this, this.tickInterval)), this.tickAmount || (this.tickInterval = this.unsquish()), this.setTickPositions();
9784          }
9785          setTickPositions() {
9786            let t3 = this.options, e3 = t3.tickPositions, i3 = t3.tickPositioner, s2 = this.getMinorTickInterval(), r2 = !this.isPanning, o2 = r2 && t3.startOnTick, n2 = r2 && t3.endOnTick, a2 = [], h2;
9787            if (this.tickmarkOffset = this.categories && "between" === t3.tickmarkPlacement && 1 === this.tickInterval ? 0.5 : 0, this.single = this.min === this.max && y(this.min) && !this.tickAmount && (this.min % 1 == 0 || false !== t3.allowDecimals), e3) a2 = e3.slice();
9788            else if (A(this.min) && A(this.max)) {
9789              if (!this.ordinal?.positions && (this.max - this.min) / this.tickInterval > Math.max(2 * this.len, 200)) a2 = [this.min, this.max], S2(19, false, this.chart);
9790              else if (this.dateTime) a2 = this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(this.tickInterval, t3.units), this.min, this.max, t3.startOfWeek, this.ordinal?.positions, this.closestPointRange, true);
9791              else if (this.logarithmic) a2 = this.logarithmic.getLogTickPositions(this.tickInterval, this.min, this.max);
9792              else {
9793                let t4 = this.tickInterval, e4 = t4;
9794                for (; e4 <= 2 * t4; ) if (a2 = this.getLinearTickPositions(this.tickInterval, this.min, this.max), this.tickAmount && a2.length > this.tickAmount) this.tickInterval = z(this, e4 *= 1.1);
9795                else break;
9796              }
9797              a2.length > this.len && (a2 = [a2[0], a2[a2.length - 1]])[0] === a2[1] && (a2.length = 1), i3 && (this.tickPositions = a2, (h2 = i3.apply(this, [this.min, this.max])) && (a2 = h2));
9798            }
9799            this.tickPositions = a2, this.minorTickInterval = "auto" === s2 && this.tickInterval ? this.tickInterval / t3.minorTicksPerMajor : s2, this.paddedTicks = a2.slice(0), this.trimTicks(a2, o2, n2), !this.isLinked && A(this.min) && A(this.max) && (this.single && a2.length < 2 && !this.categories && !this.series.some((t4) => t4.is("heatmap") && "between" === t4.options.pointPlacement) && (this.min -= 0.5, this.max += 0.5), e3 || h2 || this.adjustTickAmount()), k(this, "afterSetTickPositions");
9800          }
9801          trimTicks(t3, e3, i3) {
9802            let s2 = t3[0], r2 = t3[t3.length - 1], o2 = !this.isOrdinal && this.minPointOffset || 0;
9803            if (k(this, "trimTicks"), !this.isLinked) {
9804              if (e3 && s2 !== -1 / 0) this.min = s2;
9805              else for (; this.min - o2 > t3[0]; ) t3.shift();
9806              if (i3) this.max = r2;
9807              else for (; this.max + o2 < t3[t3.length - 1]; ) t3.pop();
9808              0 === t3.length && y(s2) && !this.options.tickPositions && t3.push((r2 + s2) / 2);
9809            }
9810          }
9811          alignToOthers() {
9812            let t3;
9813            let e3 = this, i3 = e3.chart, s2 = [this], r2 = e3.options, o2 = i3.options.chart, n2 = "yAxis" === this.coll && o2.alignThresholds, a2 = [];
9814            if (e3.thresholdAlignment = void 0, (false !== o2.alignTicks && r2.alignTicks || n2) && false !== r2.startOnTick && false !== r2.endOnTick && !e3.logarithmic) {
9815              let r3 = (t4) => {
9816                let {
9817                  horiz: e4,
9818                  options: i4
9819                } = t4;
9820                return [e4 ? i4.left : i4.top, i4.width, i4.height, i4.pane].join(",");
9821              }, o3 = r3(this);
9822              i3[this.coll].forEach(function(i4) {
9823                let {
9824                  series: n3
9825                } = i4;
9826                n3.length && n3.some((t4) => t4.visible) && i4 !== e3 && r3(i4) === o3 && (t3 = true, s2.push(i4));
9827              });
9828            }
9829            if (t3 && n2) {
9830              s2.forEach((t5) => {
9831                let i4 = t5.getThresholdAlignment(e3);
9832                A(i4) && a2.push(i4);
9833              });
9834              let t4 = a2.length > 1 ? a2.reduce((t5, e4) => t5 += e4, 0) / a2.length : void 0;
9835              s2.forEach((e4) => {
9836                e4.thresholdAlignment = t4;
9837              });
9838            }
9839            return t3;
9840          }
9841          getThresholdAlignment(t3) {
9842            if ((!A(this.dataMin) || this !== t3 && this.series.some((t4) => t4.isDirty || t4.isDirtyData)) && this.getSeriesExtremes(), A(this.threshold)) {
9843              let t4 = m((this.threshold - (this.dataMin || 0)) / ((this.dataMax || 0) - (this.dataMin || 0)), 0, 1);
9844              return this.options.reversed && (t4 = 1 - t4), t4;
9845            }
9846          }
9847          getTickAmount() {
9848            let t3 = this.options, e3 = t3.tickPixelInterval, i3 = t3.tickAmount;
9849            y(t3.tickInterval) || i3 || !(this.len < e3) || this.isRadial || this.logarithmic || !t3.startOnTick || !t3.endOnTick || (i3 = 2), !i3 && this.alignToOthers() && (i3 = Math.ceil(this.len / e3) + 1), i3 < 4 && (this.finalTickAmt = i3, i3 = 5), this.tickAmount = i3;
9850          }
9851          adjustTickAmount() {
9852            let t3 = this, {
9853              finalTickAmt: e3,
9854              max: i3,
9855              min: s2,
9856              options: r2,
9857              tickPositions: o2,
9858              tickAmount: n2,
9859              thresholdAlignment: a2
9860            } = t3, h2 = o2?.length, l2 = E(t3.threshold, t3.softThreshold ? 0 : null), d2, c2, p2 = t3.tickInterval, u12, g2 = () => o2.push(x(o2[o2.length - 1] + p2)), f2 = () => o2.unshift(x(o2[0] - p2));
9861            if (A(a2) && (u12 = a2 < 0.5 ? Math.ceil(a2 * (n2 - 1)) : Math.floor(a2 * (n2 - 1)), r2.reversed && (u12 = n2 - 1 - u12)), t3.hasData() && A(s2) && A(i3)) {
9862              let a3 = () => {
9863                t3.transA *= (h2 - 1) / (n2 - 1), t3.min = r2.startOnTick ? o2[0] : Math.min(s2, o2[0]), t3.max = r2.endOnTick ? o2[o2.length - 1] : Math.max(i3, o2[o2.length - 1]);
9864              };
9865              if (A(u12) && A(t3.threshold)) {
9866                for (; o2[u12] !== l2 || o2.length !== n2 || o2[0] > s2 || o2[o2.length - 1] < i3; ) {
9867                  for (o2.length = 0, o2.push(t3.threshold); o2.length < n2; ) void 0 === o2[u12] || o2[u12] > t3.threshold ? f2() : g2();
9868                  if (p2 > 8 * t3.tickInterval) break;
9869                  p2 *= 2;
9870                }
9871                a3();
9872              } else if (h2 < n2) {
9873                for (; o2.length < n2; ) o2.length % 2 || s2 === l2 ? g2() : f2();
9874                a3();
9875              }
9876              if (y(e3)) {
9877                for (c2 = d2 = o2.length; c2--; ) (3 === e3 && c2 % 2 == 1 || e3 <= 2 && c2 > 0 && c2 < d2 - 1) && o2.splice(c2, 1);
9878                t3.finalTickAmt = void 0;
9879              }
9880            }
9881          }
9882          setScale() {
9883            let {
9884              coll: t3,
9885              stacking: e3
9886            } = this, i3 = false, s2 = false;
9887            this.series.forEach((t4) => {
9888              i3 = i3 || t4.isDirtyData || t4.isDirty, s2 = s2 || t4.xAxis && t4.xAxis.isDirty || false;
9889            }), this.setAxisSize();
9890            let r2 = this.len !== (this.old && this.old.len);
9891            r2 || i3 || s2 || this.isLinked || this.forceRedraw || this.userMin !== (this.old && this.old.userMin) || this.userMax !== (this.old && this.old.userMax) || this.alignToOthers() ? (e3 && "yAxis" === t3 && e3.buildStacks(), this.forceRedraw = false, this.userMinRange || (this.minRange = void 0), this.getSeriesExtremes(), this.setTickInterval(), e3 && "xAxis" === t3 && e3.buildStacks(), this.isDirty || (this.isDirty = r2 || this.min !== this.old?.min || this.max !== this.old?.max)) : e3 && e3.cleanStacks(), i3 && delete this.allExtremes, k(this, "afterSetScale");
9892          }
9893          setExtremes(t3, e3, i3 = true, s2, r2) {
9894            this.series.forEach((t4) => {
9895              delete t4.kdTree;
9896            }), k(this, "setExtremes", r2 = C(r2, {
9897              min: t3,
9898              max: e3
9899            }), (t4) => {
9900              this.userMin = t4.min, this.userMax = t4.max, this.eventArgs = t4, i3 && this.chart.redraw(s2);
9901            });
9902          }
9903          setAxisSize() {
9904            let t3 = this.chart, e3 = this.options, i3 = e3.offsets || [0, 0, 0, 0], s2 = this.horiz, r2 = this.width = Math.round(I(E(e3.width, t3.plotWidth - i3[3] + i3[1]), t3.plotWidth)), o2 = this.height = Math.round(I(E(e3.height, t3.plotHeight - i3[0] + i3[2]), t3.plotHeight)), n2 = this.top = Math.round(I(E(e3.top, t3.plotTop + i3[0]), t3.plotHeight, t3.plotTop)), a2 = this.left = Math.round(I(E(e3.left, t3.plotLeft + i3[3]), t3.plotWidth, t3.plotLeft));
9905            this.bottom = t3.chartHeight - o2 - n2, this.right = t3.chartWidth - r2 - a2, this.len = Math.max(s2 ? r2 : o2, 0), this.pos = s2 ? a2 : n2;
9906          }
9907          getExtremes() {
9908            let t3 = this.logarithmic;
9909            return {
9910              min: t3 ? x(t3.lin2log(this.min)) : this.min,
9911              max: t3 ? x(t3.lin2log(this.max)) : this.max,
9912              dataMin: this.dataMin,
9913              dataMax: this.dataMax,
9914              userMin: this.userMin,
9915              userMax: this.userMax
9916            };
9917          }
9918          getThreshold(t3) {
9919            let e3 = this.logarithmic, i3 = e3 ? e3.lin2log(this.min) : this.min, s2 = e3 ? e3.lin2log(this.max) : this.max;
9920            return null === t3 || t3 === -1 / 0 ? t3 = i3 : t3 === 1 / 0 ? t3 = s2 : i3 > t3 ? t3 = i3 : s2 < t3 && (t3 = s2), this.translate(t3, 0, 1, 0, 1);
9921          }
9922          autoLabelAlign(t3) {
9923            let e3 = (E(t3, 0) - 90 * this.side + 720) % 360, i3 = {
9924              align: "center"
9925            };
9926            return k(this, "autoLabelAlign", i3, function(t4) {
9927              e3 > 15 && e3 < 165 ? t4.align = "right" : e3 > 195 && e3 < 345 && (t4.align = "left");
9928            }), i3.align;
9929          }
9930          tickSize(t3) {
9931            let e3 = this.options, i3 = E(e3["tick" === t3 ? "tickWidth" : "minorTickWidth"], "tick" === t3 && this.isXAxis && !this.categories ? 1 : 0), s2 = e3["tick" === t3 ? "tickLength" : "minorTickLength"], r2;
9932            i3 && s2 && ("inside" === e3[t3 + "Position"] && (s2 = -s2), r2 = [s2, i3]);
9933            let o2 = {
9934              tickSize: r2
9935            };
9936            return k(this, "afterTickSize", o2), o2.tickSize;
9937          }
9938          labelMetrics() {
9939            let t3 = this.chart.renderer, e3 = this.ticks, i3 = e3[Object.keys(e3)[0]] || {};
9940            return this.chart.renderer.fontMetrics(i3.label || i3.movedLabel || t3.box);
9941          }
9942          unsquish() {
9943            let t3 = this.options.labels, e3 = t3.padding || 0, i3 = this.horiz, s2 = this.tickInterval, r2 = this.len / (((this.categories ? 1 : 0) + this.max - this.min) / s2), o2 = t3.rotation, n2 = x(0.8 * this.labelMetrics().h), a2 = Math.max(this.max - this.min, 0), h2 = function(t4) {
9944              let i4 = (t4 + 2 * e3) / (r2 || 1);
9945              return (i4 = i4 > 1 ? Math.ceil(i4) : 1) * s2 > a2 && t4 !== 1 / 0 && r2 !== 1 / 0 && a2 && (i4 = Math.ceil(a2 / s2)), x(i4 * s2);
9946            }, l2 = s2, d2, c2 = Number.MAX_VALUE, p2;
9947            if (i3) {
9948              if (!t3.staggerLines && (A(o2) ? p2 = [o2] : r2 < t3.autoRotationLimit && (p2 = t3.autoRotation)), p2) {
9949                let t4, e4;
9950                for (let i4 of p2) (i4 === o2 || i4 && i4 >= -90 && i4 <= 90) && (e4 = (t4 = h2(Math.abs(n2 / Math.sin(u11 * i4)))) + Math.abs(i4 / 360)) < c2 && (c2 = e4, d2 = i4, l2 = t4);
9951              }
9952            } else l2 = h2(0.75 * n2);
9953            return this.autoRotation = p2, this.labelRotation = E(d2, A(o2) ? o2 : 0), t3.step ? s2 : l2;
9954          }
9955          getSlotWidth(t3) {
9956            let e3 = this.chart, i3 = this.horiz, s2 = this.options.labels, r2 = Math.max(this.tickPositions.length - (this.categories ? 0 : 1), 1), o2 = e3.margin[3];
9957            if (t3 && A(t3.slotWidth)) return t3.slotWidth;
9958            if (i3 && s2.step < 2) return s2.rotation ? 0 : (this.staggerLines || 1) * this.len / r2;
9959            if (!i3) {
9960              let t4 = s2.style.width;
9961              if (void 0 !== t4) return parseInt(String(t4), 10);
9962              if (o2) return o2 - e3.spacing[3];
9963            }
9964            return 0.33 * e3.chartWidth;
9965          }
9966          renderUnsquish() {
9967            let t3 = this.chart, e3 = t3.renderer, i3 = this.tickPositions, s2 = this.ticks, r2 = this.options.labels, o2 = r2.style, n2 = this.horiz, a2 = this.getSlotWidth(), h2 = Math.max(1, Math.round(a2 - (n2 ? 2 * (r2.padding || 0) : r2.distance || 0))), l2 = {}, d2 = this.labelMetrics(), c2 = o2.textOverflow, p2, u12, g2 = 0, f2, m2;
9968            if (P(r2.rotation) || (l2.rotation = r2.rotation || 0), i3.forEach(function(t4) {
9969              let e4 = s2[t4];
9970              e4.movedLabel && e4.replaceMovedLabel(), e4 && e4.label && e4.label.textPxLength > g2 && (g2 = e4.label.textPxLength);
9971            }), this.maxLabelLength = g2, this.autoRotation) g2 > h2 && g2 > d2.h ? l2.rotation = this.labelRotation : this.labelRotation = 0;
9972            else if (a2 && (p2 = h2, !c2)) for (u12 = "clip", m2 = i3.length; !n2 && m2--; ) (f2 = s2[i3[m2]].label) && ("ellipsis" === f2.styles.textOverflow ? f2.css({
9973              textOverflow: "clip"
9974            }) : f2.textPxLength > a2 && f2.css({
9975              width: a2 + "px"
9976            }), f2.getBBox().height > this.len / i3.length - (d2.h - d2.f) && (f2.specificTextOverflow = "ellipsis"));
9977            l2.rotation && (p2 = g2 > 0.5 * t3.chartHeight ? 0.33 * t3.chartHeight : g2, c2 || (u12 = "ellipsis")), this.labelAlign = r2.align || this.autoLabelAlign(this.labelRotation), this.labelAlign && (l2.align = this.labelAlign), i3.forEach(function(t4) {
9978              let e4 = s2[t4], i4 = e4 && e4.label, r3 = o2.width, n3 = {};
9979              i4 && (i4.attr(l2), e4.shortenLabel ? e4.shortenLabel() : p2 && !r3 && "nowrap" !== o2.whiteSpace && (p2 < i4.textPxLength || "SPAN" === i4.element.tagName) ? (n3.width = p2 + "px", c2 || (n3.textOverflow = i4.specificTextOverflow || u12), i4.css(n3)) : !i4.styles.width || n3.width || r3 || i4.css({
9980                width: null
9981              }), delete i4.specificTextOverflow, e4.rotation = l2.rotation);
9982            }, this), this.tickRotCorr = e3.rotCorr(d2.b, this.labelRotation || 0, 0 !== this.side);
9983          }
9984          hasData() {
9985            return this.series.some(function(t3) {
9986              return t3.hasData();
9987            }) || this.options.showEmpty && y(this.min) && y(this.max);
9988          }
9989          addTitle(t3) {
9990            let e3;
9991            let i3 = this.chart.renderer, s2 = this.horiz, r2 = this.opposite, o2 = this.options.title, n2 = this.chart.styledMode;
9992            this.axisTitle || ((e3 = o2.textAlign) || (e3 = (s2 ? {
9993              low: "left",
9994              middle: "center",
9995              high: "right"
9996            } : {
9997              low: r2 ? "right" : "left",
9998              middle: "center",
9999              high: r2 ? "left" : "right"
10000            })[o2.align]), this.axisTitle = i3.text(o2.text || "", 0, 0, o2.useHTML).attr({
10001              zIndex: 7,
10002              rotation: o2.rotation || 0,
10003              align: e3
10004            }).addClass("highcharts-axis-title"), n2 || this.axisTitle.css(L(o2.style)), this.axisTitle.add(this.axisGroup), this.axisTitle.isNew = true), n2 || o2.style.width || this.isRadial || this.axisTitle.css({
10005              width: this.len + "px"
10006            }), this.axisTitle[t3 ? "show" : "hide"](t3);
10007          }
10008          generateTick(t3) {
10009            let e3 = this.ticks;
10010            e3[t3] ? e3[t3].addLabel() : e3[t3] = new n(this, t3);
10011          }
10012          createGroups() {
10013            let {
10014              axisParent: t3,
10015              chart: e3,
10016              coll: i3,
10017              options: s2
10018            } = this, r2 = e3.renderer, o2 = (e4, o3, n2) => r2.g(e4).attr({
10019              zIndex: n2
10020            }).addClass(`highcharts-${i3.toLowerCase()}${o3} ` + (this.isRadial ? `highcharts-radial-axis${o3} ` : "") + (s2.className || "")).add(t3);
10021            this.axisGroup || (this.gridGroup = o2("grid", "-grid", s2.gridZIndex), this.axisGroup = o2("axis", "", s2.zIndex), this.labelGroup = o2("axis-labels", "-labels", s2.labels.zIndex));
10022          }
10023          getOffset() {
10024            let t3 = this, {
10025              chart: e3,
10026              horiz: i3,
10027              options: s2,
10028              side: r2,
10029              ticks: o2,
10030              tickPositions: n2,
10031              coll: a2
10032            } = t3, h2 = e3.inverted && !t3.isZAxis ? [1, 0, 3, 2][r2] : r2, l2 = t3.hasData(), d2 = s2.title, c2 = s2.labels, p2 = A(s2.crossing), u12 = e3.axisOffset, g2 = e3.clipOffset, f2 = [-1, 1, 1, -1][r2], m2, x2 = 0, b2, v2 = 0, S3 = 0, C2, M2;
10033            if (t3.showAxis = m2 = l2 || s2.showEmpty, t3.staggerLines = t3.horiz && c2.staggerLines || void 0, t3.createGroups(), l2 || t3.isLinked ? (n2.forEach(function(e4) {
10034              t3.generateTick(e4);
10035            }), t3.renderUnsquish(), t3.reserveSpaceDefault = 0 === r2 || 2 === r2 || {
10036              1: "left",
10037              3: "right"
10038            }[r2] === t3.labelAlign, E(c2.reserveSpace, !p2 && null, "center" === t3.labelAlign || null, t3.reserveSpaceDefault) && n2.forEach(function(t4) {
10039              S3 = Math.max(o2[t4].getLabelSize(), S3);
10040            }), t3.staggerLines && (S3 *= t3.staggerLines), t3.labelOffset = S3 * (t3.opposite ? -1 : 1)) : D2(o2, function(t4, e4) {
10041              t4.destroy(), delete o2[e4];
10042            }), d2?.text && false !== d2.enabled && (t3.addTitle(m2), m2 && !p2 && false !== d2.reserveSpace && (t3.titleOffset = x2 = t3.axisTitle.getBBox()[i3 ? "height" : "width"], v2 = y(b2 = d2.offset) ? 0 : E(d2.margin, i3 ? 5 : 10))), t3.renderLine(), t3.offset = f2 * E(s2.offset, u12[r2] ? u12[r2] + (s2.margin || 0) : 0), t3.tickRotCorr = t3.tickRotCorr || {
10043              x: 0,
10044              y: 0
10045            }, M2 = 0 === r2 ? -t3.labelMetrics().h : 2 === r2 ? t3.tickRotCorr.y : 0, C2 = Math.abs(S3) + v2, S3 && (C2 -= M2, C2 += f2 * (i3 ? E(c2.y, t3.tickRotCorr.y + f2 * c2.distance) : E(c2.x, f2 * c2.distance))), t3.axisTitleMargin = E(b2, C2), t3.getMaxLabelDimensions && (t3.maxLabelDimensions = t3.getMaxLabelDimensions(o2, n2)), "colorAxis" !== a2 && g2) {
10046              let e4 = this.tickSize("tick");
10047              u12[r2] = Math.max(u12[r2], (t3.axisTitleMargin || 0) + x2 + f2 * t3.offset, C2, n2 && n2.length && e4 ? e4[0] + f2 * t3.offset : 0);
10048              let i4 = !t3.axisLine || s2.offset ? 0 : t3.axisLine.strokeWidth() / 2;
10049              g2[h2] = Math.max(g2[h2], i4);
10050            }
10051            k(this, "afterGetOffset");
10052          }
10053          getLinePath(t3) {
10054            let e3 = this.chart, i3 = this.opposite, s2 = this.offset, r2 = this.horiz, o2 = this.left + (i3 ? this.width : 0) + s2, n2 = e3.chartHeight - this.bottom - (i3 ? this.height : 0) + s2;
10055            return i3 && (t3 *= -1), e3.renderer.crispLine([["M", r2 ? this.left : o2, r2 ? n2 : this.top], ["L", r2 ? e3.chartWidth - this.right : o2, r2 ? n2 : e3.chartHeight - this.bottom]], t3);
10056          }
10057          renderLine() {
10058            this.axisLine || (this.axisLine = this.chart.renderer.path().addClass("highcharts-axis-line").add(this.axisGroup), this.chart.styledMode || this.axisLine.attr({
10059              stroke: this.options.lineColor,
10060              "stroke-width": this.options.lineWidth,
10061              zIndex: 7
10062            }));
10063          }
10064          getTitlePosition(t3) {
10065            let e3 = this.horiz, i3 = this.left, s2 = this.top, r2 = this.len, o2 = this.options.title, n2 = e3 ? i3 : s2, a2 = this.opposite, h2 = this.offset, l2 = o2.x, d2 = o2.y, c2 = this.chart.renderer.fontMetrics(t3), p2 = t3 ? Math.max(t3.getBBox(false, 0).height - c2.h - 1, 0) : 0, u12 = {
10066              low: n2 + (e3 ? 0 : r2),
10067              middle: n2 + r2 / 2,
10068              high: n2 + (e3 ? r2 : 0)
10069            }[o2.align], g2 = (e3 ? s2 + this.height : i3) + (e3 ? 1 : -1) * (a2 ? -1 : 1) * (this.axisTitleMargin || 0) + [-p2, p2, c2.f, -p2][this.side], f2 = {
10070              x: e3 ? u12 + l2 : g2 + (a2 ? this.width : 0) + h2 + l2,
10071              y: e3 ? g2 + d2 - (a2 ? this.height : 0) + h2 : u12 + d2
10072            };
10073            return k(this, "afterGetTitlePosition", {
10074              titlePosition: f2
10075            }), f2;
10076          }
10077          renderMinorTick(t3, e3) {
10078            let i3 = this.minorTicks;
10079            i3[t3] || (i3[t3] = new n(this, t3, "minor")), e3 && i3[t3].isNew && i3[t3].render(null, true), i3[t3].render(null, false, 1);
10080          }
10081          renderTick(t3, e3, i3) {
10082            let s2 = this.isLinked, r2 = this.ticks;
10083            (!s2 || t3 >= this.min && t3 <= this.max || this.grid && this.grid.isColumn) && (r2[t3] || (r2[t3] = new n(this, t3)), i3 && r2[t3].isNew && r2[t3].render(e3, true, -1), r2[t3].render(e3));
10084          }
10085          render() {
10086            let t3, e3;
10087            let i3 = this, s2 = i3.chart, r2 = i3.logarithmic, a2 = s2.renderer, l2 = i3.options, d2 = i3.isLinked, c2 = i3.tickPositions, p2 = i3.axisTitle, u12 = i3.ticks, g2 = i3.minorTicks, f2 = i3.alternateBands, m2 = l2.stackLabels, x2 = l2.alternateGridColor, y2 = l2.crossing, b2 = i3.tickmarkOffset, v2 = i3.axisLine, S3 = i3.showAxis, C2 = h(a2.globalAnimation);
10088            if (i3.labelEdge.length = 0, i3.overlap = false, [u12, g2, f2].forEach(function(t4) {
10089              D2(t4, function(t5) {
10090                t5.isActive = false;
10091              });
10092            }), A(y2)) {
10093              let t4 = this.isXAxis ? s2.yAxis[0] : s2.xAxis[0], e4 = [1, -1, -1, 1][this.side];
10094              if (t4) {
10095                let s3 = t4.toPixels(y2, true);
10096                i3.horiz && (s3 = t4.len - s3), i3.offset = e4 * s3;
10097              }
10098            }
10099            if (i3.hasData() || d2) {
10100              let a3 = i3.chart.hasRendered && i3.old && A(i3.old.min);
10101              i3.minorTickInterval && !i3.categories && i3.getMinorTickPositions().forEach(function(t4) {
10102                i3.renderMinorTick(t4, a3);
10103              }), c2.length && (c2.forEach(function(t4, e4) {
10104                i3.renderTick(t4, e4, a3);
10105              }), b2 && (0 === i3.min || i3.single) && (u12[-1] || (u12[-1] = new n(i3, -1, null, true)), u12[-1].render(-1))), x2 && c2.forEach(function(n2, a4) {
10106                e3 = void 0 !== c2[a4 + 1] ? c2[a4 + 1] + b2 : i3.max - b2, a4 % 2 == 0 && n2 < i3.max && e3 <= i3.max + (s2.polar ? -b2 : b2) && (f2[n2] || (f2[n2] = new o.PlotLineOrBand(i3, {})), t3 = n2 + b2, f2[n2].options = {
10107                  from: r2 ? r2.lin2log(t3) : t3,
10108                  to: r2 ? r2.lin2log(e3) : e3,
10109                  color: x2,
10110                  className: "highcharts-alternate-grid"
10111                }, f2[n2].render(), f2[n2].isActive = true);
10112              }), i3._addedPlotLB || (i3._addedPlotLB = true, (l2.plotLines || []).concat(l2.plotBands || []).forEach(function(t4) {
10113                i3.addPlotBandOrLine(t4);
10114              }));
10115            }
10116            [u12, g2, f2].forEach(function(t4) {
10117              let e4 = [], i4 = C2.duration;
10118              D2(t4, function(t5, i5) {
10119                t5.isActive || (t5.render(i5, false, 0), t5.isActive = false, e4.push(i5));
10120              }), R(function() {
10121                let i5 = e4.length;
10122                for (; i5--; ) t4[e4[i5]] && !t4[e4[i5]].isActive && (t4[e4[i5]].destroy(), delete t4[e4[i5]]);
10123              }, t4 !== f2 && s2.hasRendered && i4 ? i4 : 0);
10124            }), v2 && (v2[v2.isPlaced ? "animate" : "attr"]({
10125              d: this.getLinePath(v2.strokeWidth())
10126            }), v2.isPlaced = true, v2[S3 ? "show" : "hide"](S3)), p2 && S3 && (p2[p2.isNew ? "attr" : "animate"](i3.getTitlePosition(p2)), p2.isNew = false), m2 && m2.enabled && i3.stacking && i3.stacking.renderStackTotals(), i3.old = {
10127              len: i3.len,
10128              max: i3.max,
10129              min: i3.min,
10130              transA: i3.transA,
10131              userMax: i3.userMax,
10132              userMin: i3.userMin
10133            }, i3.isDirty = false, k(this, "afterRender");
10134          }
10135          redraw() {
10136            this.visible && (this.render(), this.plotLinesAndBands.forEach(function(t3) {
10137              t3.render();
10138            })), this.series.forEach(function(t3) {
10139              t3.isDirty = true;
10140            });
10141          }
10142          getKeepProps() {
10143            return this.keepProps || N.keepProps;
10144          }
10145          destroy(t3) {
10146            let e3 = this, i3 = e3.plotLinesAndBands, s2 = this.eventOptions;
10147            if (k(this, "destroy", {
10148              keepEvents: t3
10149            }), t3 || j(e3), [e3.ticks, e3.minorTicks, e3.alternateBands].forEach(function(t4) {
10150              b(t4);
10151            }), i3) {
10152              let t4 = i3.length;
10153              for (; t4--; ) i3[t4].destroy();
10154            }
10155            for (let t4 in ["axisLine", "axisTitle", "axisGroup", "gridGroup", "labelGroup", "cross", "scrollbar"].forEach(function(t5) {
10156              e3[t5] && (e3[t5] = e3[t5].destroy());
10157            }), e3.plotLinesAndBandsGroups) e3.plotLinesAndBandsGroups[t4] = e3.plotLinesAndBandsGroups[t4].destroy();
10158            D2(e3, function(t4, i4) {
10159              -1 === e3.getKeepProps().indexOf(i4) && delete e3[i4];
10160            }), this.eventOptions = s2;
10161          }
10162          drawCrosshair(t3, e3) {
10163            let s2 = this.crosshair, r2 = E(s2 && s2.snap, true), o2 = this.chart, n2, a2, h2, l2 = this.cross, d2;
10164            if (k(this, "drawCrosshair", {
10165              e: t3,
10166              point: e3
10167            }), t3 || (t3 = this.cross && this.cross.e), s2 && false !== (y(e3) || !r2)) {
10168              if (r2 ? y(e3) && (a2 = E("colorAxis" !== this.coll ? e3.crosshairPos : null, this.isXAxis ? e3.plotX : this.len - e3.plotY)) : a2 = t3 && (this.horiz ? t3.chartX - this.pos : this.len - t3.chartY + this.pos), y(a2) && (d2 = {
10169                value: e3 && (this.isXAxis ? e3.x : E(e3.stackY, e3.y)),
10170                translatedValue: a2
10171              }, o2.polar && C(d2, {
10172                isCrosshair: true,
10173                chartX: t3 && t3.chartX,
10174                chartY: t3 && t3.chartY,
10175                point: e3
10176              }), n2 = this.getPlotLinePath(d2) || null), !y(n2)) {
10177                this.hideCrosshair();
10178                return;
10179              }
10180              h2 = this.categories && !this.isRadial, l2 || (this.cross = l2 = o2.renderer.path().addClass("highcharts-crosshair highcharts-crosshair-" + (h2 ? "category " : "thin ") + (s2.className || "")).attr({
10181                zIndex: E(s2.zIndex, 2)
10182              }).add(), !o2.styledMode && (l2.attr({
10183                stroke: s2.color || (h2 ? i2.parse("#ccd3ff").setOpacity(0.25).get() : "#cccccc"),
10184                "stroke-width": E(s2.width, 1)
10185              }).css({
10186                "pointer-events": "none"
10187              }), s2.dashStyle && l2.attr({
10188                dashstyle: s2.dashStyle
10189              }))), l2.show().attr({
10190                d: n2
10191              }), h2 && !s2.width && l2.attr({
10192                "stroke-width": this.transA
10193              }), this.cross.e = t3;
10194            } else this.hideCrosshair();
10195            k(this, "afterDrawCrosshair", {
10196              e: t3,
10197              point: e3
10198            });
10199          }
10200          hideCrosshair() {
10201            this.cross && this.cross.hide(), k(this, "afterHideCrosshair");
10202          }
10203          update(t3, e3) {
10204            let i3 = this.chart;
10205            t3 = L(this.userOptions, t3), this.destroy(true), this.init(i3, t3), i3.isDirtyBox = true, E(e3, true) && i3.redraw();
10206          }
10207          remove(t3) {
10208            let e3 = this.chart, i3 = this.coll, s2 = this.series, r2 = s2.length;
10209            for (; r2--; ) s2[r2] && s2[r2].remove(false);
10210            v(e3.axes, this), v(e3[i3] || [], this), e3.orderItems(i3), this.destroy(), e3.isDirtyBox = true, E(t3, true) && e3.redraw();
10211          }
10212          setTitle(t3, e3) {
10213            this.update({
10214              title: t3
10215            }, e3);
10216          }
10217          setCategories(t3, e3) {
10218            this.update({
10219              categories: t3
10220            }, e3);
10221          }
10222        }
10223        return N.keepProps = ["coll", "extKey", "hcEvents", "len", "names", "series", "userMax", "userMin"], N;
10224      }), i(e, "Core/Axis/DateTimeAxis.js", [e["Core/Utilities.js"]], function(t2) {
10225        var e2;
10226        let {
10227          addEvent: i2,
10228          getMagnitude: s,
10229          normalizeTickInterval: r,
10230          timeUnits: o
10231        } = t2;
10232        return function(t3) {
10233          function e3() {
10234            return this.chart.time.getTimeTicks.apply(this.chart.time, arguments);
10235          }
10236          function n() {
10237            if ("datetime" !== this.type) {
10238              this.dateTime = void 0;
10239              return;
10240            }
10241            this.dateTime || (this.dateTime = new a(this));
10242          }
10243          t3.compose = function(t4) {
10244            return t4.keepProps.includes("dateTime") || (t4.keepProps.push("dateTime"), t4.prototype.getTimeTicks = e3, i2(t4, "afterSetType", n)), t4;
10245          };
10246          class a {
10247            constructor(t4) {
10248              this.axis = t4;
10249            }
10250            normalizeTimeTickInterval(t4, e4) {
10251              let i3 = e4 || [["millisecond", [1, 2, 5, 10, 20, 25, 50, 100, 200, 500]], ["second", [1, 2, 5, 10, 15, 30]], ["minute", [1, 2, 5, 10, 15, 30]], ["hour", [1, 2, 3, 4, 6, 8, 12]], ["day", [1, 2]], ["week", [1, 2]], ["month", [1, 2, 3, 4, 6]], ["year", null]], n2 = i3[i3.length - 1], a2 = o[n2[0]], h = n2[1], l;
10252              for (l = 0; l < i3.length && (a2 = o[(n2 = i3[l])[0]], h = n2[1], !i3[l + 1] || !(t4 <= (a2 * h[h.length - 1] + o[i3[l + 1][0]]) / 2)); l++) ;
10253              a2 === o.year && t4 < 5 * a2 && (h = [1, 2, 5]);
10254              let d = r(t4 / a2, h, "year" === n2[0] ? Math.max(s(t4 / a2), 1) : 1);
10255              return {
10256                unitRange: a2,
10257                count: d,
10258                unitName: n2[0]
10259              };
10260            }
10261            getXDateFormat(t4, e4) {
10262              let {
10263                axis: i3
10264              } = this, s2 = i3.chart.time;
10265              return i3.closestPointRange ? s2.getDateFormat(i3.closestPointRange, t4, i3.options.startOfWeek, e4) || s2.resolveDTLFormat(e4.year).main : s2.resolveDTLFormat(e4.day).main;
10266            }
10267          }
10268          t3.Additions = a;
10269        }(e2 || (e2 = {})), e2;
10270      }), i(e, "Core/Axis/LogarithmicAxis.js", [e["Core/Utilities.js"]], function(t2) {
10271        var e2;
10272        let {
10273          addEvent: i2,
10274          normalizeTickInterval: s,
10275          pick: r
10276        } = t2;
10277        return function(t3) {
10278          function e3() {
10279            "logarithmic" !== this.type ? this.logarithmic = void 0 : this.logarithmic ?? (this.logarithmic = new n(this));
10280          }
10281          function o() {
10282            let t4 = this.logarithmic;
10283            t4 && (this.lin2val = function(e4) {
10284              return t4.lin2log(e4);
10285            }, this.val2lin = function(e4) {
10286              return t4.log2lin(e4);
10287            });
10288          }
10289          t3.compose = function(t4) {
10290            return t4.keepProps.includes("logarithmic") || (t4.keepProps.push("logarithmic"), i2(t4, "afterSetType", e3), i2(t4, "afterInit", o)), t4;
10291          };
10292          class n {
10293            constructor(t4) {
10294              this.axis = t4;
10295            }
10296            getLogTickPositions(t4, e4, i3, o2) {
10297              let n2 = this.axis, a = n2.len, h = n2.options, l = [];
10298              if (o2 || (this.minorAutoInterval = void 0), t4 >= 0.5) t4 = Math.round(t4), l = n2.getLinearTickPositions(t4, e4, i3);
10299              else if (t4 >= 0.08) {
10300                let s2, r2, n3, a2, h2, d, c;
10301                let p = Math.floor(e4);
10302                for (s2 = t4 > 0.3 ? [1, 2, 4] : t4 > 0.15 ? [1, 2, 4, 6, 8] : [1, 2, 3, 4, 5, 6, 7, 8, 9], r2 = p; r2 < i3 + 1 && !c; r2++) for (n3 = 0, a2 = s2.length; n3 < a2 && !c; n3++) (h2 = this.log2lin(this.lin2log(r2) * s2[n3])) > e4 && (!o2 || d <= i3) && void 0 !== d && l.push(d), d > i3 && (c = true), d = h2;
10303              } else {
10304                let d = this.lin2log(e4), c = this.lin2log(i3), p = o2 ? n2.getMinorTickInterval() : h.tickInterval, u11 = h.tickPixelInterval / (o2 ? 5 : 1), g = o2 ? a / n2.tickPositions.length : a;
10305                t4 = s(t4 = r("auto" === p ? null : p, this.minorAutoInterval, (c - d) * u11 / (g || 1))), l = n2.getLinearTickPositions(t4, d, c).map(this.log2lin), o2 || (this.minorAutoInterval = t4 / 5);
10306              }
10307              return o2 || (n2.tickInterval = t4), l;
10308            }
10309            lin2log(t4) {
10310              return Math.pow(10, t4);
10311            }
10312            log2lin(t4) {
10313              return Math.log(t4) / Math.LN10;
10314            }
10315          }
10316          t3.Additions = n;
10317        }(e2 || (e2 = {})), e2;
10318      }), i(e, "Core/Axis/PlotLineOrBand/PlotLineOrBandAxis.js", [e["Core/Utilities.js"]], function(t2) {
10319        var e2;
10320        let {
10321          erase: i2,
10322          extend: s,
10323          isNumber: r
10324        } = t2;
10325        return function(t3) {
10326          let e3;
10327          function o(t4) {
10328            return this.addPlotBandOrLine(t4, "plotBands");
10329          }
10330          function n(t4, i3) {
10331            let s2 = this.userOptions, r2 = new e3(this, t4);
10332            if (this.visible && (r2 = r2.render()), r2) {
10333              if (this._addedPlotLB || (this._addedPlotLB = true, (s2.plotLines || []).concat(s2.plotBands || []).forEach((t5) => {
10334                this.addPlotBandOrLine(t5);
10335              })), i3) {
10336                let e4 = s2[i3] || [];
10337                e4.push(t4), s2[i3] = e4;
10338              }
10339              this.plotLinesAndBands.push(r2);
10340            }
10341            return r2;
10342          }
10343          function a(t4) {
10344            return this.addPlotBandOrLine(t4, "plotLines");
10345          }
10346          function h(t4, e4, i3) {
10347            i3 = i3 || this.options;
10348            let s2 = this.getPlotLinePath({
10349              value: e4,
10350              force: true,
10351              acrossPanes: i3.acrossPanes
10352            }), o2 = [], n2 = this.horiz, a2 = !r(this.min) || !r(this.max) || t4 < this.min && e4 < this.min || t4 > this.max && e4 > this.max, h2 = this.getPlotLinePath({
10353              value: t4,
10354              force: true,
10355              acrossPanes: i3.acrossPanes
10356            }), l2, d2 = 1, c2;
10357            if (h2 && s2) for (a2 && (c2 = h2.toString() === s2.toString(), d2 = 0), l2 = 0; l2 < h2.length; l2 += 2) {
10358              let t5 = h2[l2], e5 = h2[l2 + 1], i4 = s2[l2], r2 = s2[l2 + 1];
10359              ("M" === t5[0] || "L" === t5[0]) && ("M" === e5[0] || "L" === e5[0]) && ("M" === i4[0] || "L" === i4[0]) && ("M" === r2[0] || "L" === r2[0]) && (n2 && i4[1] === t5[1] ? (i4[1] += d2, r2[1] += d2) : n2 || i4[2] !== t5[2] || (i4[2] += d2, r2[2] += d2), o2.push(["M", t5[1], t5[2]], ["L", e5[1], e5[2]], ["L", r2[1], r2[2]], ["L", i4[1], i4[2]], ["Z"])), o2.isFlat = c2;
10360            }
10361            return o2;
10362          }
10363          function l(t4) {
10364            this.removePlotBandOrLine(t4);
10365          }
10366          function d(t4) {
10367            let e4 = this.plotLinesAndBands, s2 = this.options, r2 = this.userOptions;
10368            if (e4) {
10369              let o2 = e4.length;
10370              for (; o2--; ) e4[o2].id === t4 && e4[o2].destroy();
10371              [s2.plotLines || [], r2.plotLines || [], s2.plotBands || [], r2.plotBands || []].forEach(function(e5) {
10372                for (o2 = e5.length; o2--; ) (e5[o2] || {}).id === t4 && i2(e5, e5[o2]);
10373              });
10374            }
10375          }
10376          function c(t4) {
10377            this.removePlotBandOrLine(t4);
10378          }
10379          t3.compose = function(t4, i3) {
10380            let r2 = i3.prototype;
10381            return r2.addPlotBand || (e3 = t4, s(r2, {
10382              addPlotBand: o,
10383              addPlotLine: a,
10384              addPlotBandOrLine: n,
10385              getPlotBandPath: h,
10386              removePlotBand: l,
10387              removePlotLine: c,
10388              removePlotBandOrLine: d
10389            })), i3;
10390          };
10391        }(e2 || (e2 = {})), e2;
10392      }), i(e, "Core/Axis/PlotLineOrBand/PlotLineOrBand.js", [e["Core/Axis/PlotLineOrBand/PlotLineOrBandAxis.js"], e["Core/Utilities.js"]], function(t2, e2) {
10393        let {
10394          addEvent: i2,
10395          arrayMax: s,
10396          arrayMin: r,
10397          defined: o,
10398          destroyObjectProperties: n,
10399          erase: a,
10400          fireEvent: h,
10401          merge: l,
10402          objectEach: d,
10403          pick: c
10404        } = e2;
10405        class p {
10406          static compose(e3, s2) {
10407            return i2(e3, "afterInit", function() {
10408              this.labelCollectors.push(() => {
10409                let t3 = [];
10410                for (let e4 of this.axes) for (let {
10411                  label: i3,
10412                  options: s3
10413                } of e4.plotLinesAndBands) i3 && !s3?.label?.allowOverlap && t3.push(i3);
10414                return t3;
10415              });
10416            }), t2.compose(p, s2);
10417          }
10418          constructor(t3, e3) {
10419            this.axis = t3, this.options = e3, this.id = e3.id;
10420          }
10421          render() {
10422            h(this, "render");
10423            let {
10424              axis: t3,
10425              options: e3
10426            } = this, {
10427              horiz: i3,
10428              logarithmic: s2
10429            } = t3, {
10430              color: r2,
10431              events: n2,
10432              zIndex: a2 = 0
10433            } = e3, p2 = {}, u11 = t3.chart.renderer, g = e3.to, f = e3.from, m = e3.value, x = e3.borderWidth, y = e3.label, {
10434              label: b,
10435              svgElem: v
10436            } = this, S2 = [], C, k = o(f) && o(g), M = o(m), w = !v, T2 = {
10437              class: "highcharts-plot-" + (k ? "band " : "line ") + (e3.className || "")
10438            }, A = k ? "bands" : "lines";
10439            if (!t3.chart.styledMode && (M ? (T2.stroke = r2 || "#999999", T2["stroke-width"] = c(e3.width, 1), e3.dashStyle && (T2.dashstyle = e3.dashStyle)) : k && (T2.fill = r2 || "#e6e9ff", x && (T2.stroke = e3.borderColor, T2["stroke-width"] = x))), p2.zIndex = a2, A += "-" + a2, (C = t3.plotLinesAndBandsGroups[A]) || (t3.plotLinesAndBandsGroups[A] = C = u11.g("plot-" + A).attr(p2).add()), v || (this.svgElem = v = u11.path().attr(T2).add(C)), o(m)) S2 = t3.getPlotLinePath({
10440              value: s2?.log2lin(m) ?? m,
10441              lineWidth: v.strokeWidth(),
10442              acrossPanes: e3.acrossPanes
10443            });
10444            else {
10445              if (!(o(f) && o(g))) return;
10446              S2 = t3.getPlotBandPath(s2?.log2lin(f) ?? f, s2?.log2lin(g) ?? g, e3);
10447            }
10448            return !this.eventsAdded && n2 && (d(n2, (t4, e4) => {
10449              v?.on(e4, (t5) => {
10450                n2[e4].apply(this, [t5]);
10451              });
10452            }), this.eventsAdded = true), (w || !v.d) && S2?.length ? v.attr({
10453              d: S2
10454            }) : v && (S2 ? (v.show(), v.animate({
10455              d: S2
10456            })) : v.d && (v.hide(), b && (this.label = b = b.destroy()))), y && (o(y.text) || o(y.formatter)) && S2?.length && t3.width > 0 && t3.height > 0 && !S2.isFlat ? (y = l(__spreadValues({
10457              align: i3 && k ? "center" : void 0,
10458              x: i3 ? !k && 4 : 10,
10459              verticalAlign: !i3 && k ? "middle" : void 0,
10460              y: i3 ? k ? 16 : 10 : k ? 6 : -4,
10461              rotation: i3 && !k ? 90 : 0
10462            }, k ? {
10463              inside: true
10464            } : {}), y), this.renderLabel(y, S2, k, a2)) : b && b.hide(), this;
10465          }
10466          renderLabel(t3, e3, i3, n2) {
10467            let a2 = this.axis, h2 = a2.chart.renderer, d2 = t3.inside, c2 = this.label;
10468            c2 || (this.label = c2 = h2.text(this.getLabelText(t3), 0, 0, t3.useHTML).attr({
10469              align: t3.textAlign || t3.align,
10470              rotation: t3.rotation,
10471              class: "highcharts-plot-" + (i3 ? "band" : "line") + "-label " + (t3.className || ""),
10472              zIndex: n2
10473            }), a2.chart.styledMode || c2.css(l({
10474              fontSize: "0.8em",
10475              textOverflow: i3 && !d2 ? "" : "ellipsis"
10476            }, t3.style)), c2.add());
10477            let p2 = e3.xBounds || [e3[0][1], e3[1][1], i3 ? e3[2][1] : e3[0][1]], u11 = e3.yBounds || [e3[0][2], e3[1][2], i3 ? e3[2][2] : e3[0][2]], g = r(p2), f = r(u11), m = s(p2) - g;
10478            c2.align(t3, false, {
10479              x: g,
10480              y: f,
10481              width: m,
10482              height: s(u11) - f
10483            }), (!c2.alignValue || "left" === c2.alignValue || o(d2)) && c2.css({
10484              width: (t3.style?.width || (i3 && d2 ? m : 90 === c2.rotation ? a2.height - (c2.alignAttr.y - a2.top) : (t3.clip ? a2.width : a2.chart.chartWidth) - (c2.alignAttr.x - a2.left))) + "px"
10485            }), c2.show(true);
10486          }
10487          getLabelText(t3) {
10488            return o(t3.formatter) ? t3.formatter.call(this) : t3.text;
10489          }
10490          destroy() {
10491            a(this.axis.plotLinesAndBands, this), delete this.axis, n(this);
10492          }
10493        }
10494        return p;
10495      }), i(e, "Core/Tooltip.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Templating.js"], e["Core/Globals.js"], e["Core/Renderer/RendererUtilities.js"], e["Core/Renderer/RendererRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, r, o) {
10496        var n;
10497        let {
10498          animObject: a
10499        } = t2, {
10500          format: h
10501        } = e2, {
10502          composed: l,
10503          doc: d,
10504          isSafari: c
10505        } = i2, {
10506          distribute: p
10507        } = s, {
10508          addEvent: u11,
10509          clamp: g,
10510          css: f,
10511          discardElement: m,
10512          extend: x,
10513          fireEvent: y,
10514          isArray: b,
10515          isNumber: v,
10516          isString: S2,
10517          merge: C,
10518          pick: k,
10519          pushUnique: M,
10520          splat: w,
10521          syncTimeout: T2
10522        } = o;
10523        class A {
10524          constructor(t3, e3, i3) {
10525            this.allowShared = true, this.crosshairs = [], this.distance = 0, this.isHidden = true, this.isSticky = false, this.options = {}, this.outside = false, this.chart = t3, this.init(t3, e3), this.pointer = i3;
10526          }
10527          bodyFormatter(t3) {
10528            return t3.map(function(t4) {
10529              let e3 = t4.series.tooltipOptions;
10530              return (e3[(t4.point.formatPrefix || "point") + "Formatter"] || t4.point.tooltipFormatter).call(t4.point, e3[(t4.point.formatPrefix || "point") + "Format"] || "");
10531            });
10532          }
10533          cleanSplit(t3) {
10534            this.chart.series.forEach(function(e3) {
10535              let i3 = e3 && e3.tt;
10536              i3 && (!i3.isActive || t3 ? e3.tt = i3.destroy() : i3.isActive = false);
10537            });
10538          }
10539          defaultFormatter(t3) {
10540            let e3;
10541            let i3 = this.points || w(this);
10542            return (e3 = (e3 = [t3.tooltipFooterHeaderFormatter(i3[0])]).concat(t3.bodyFormatter(i3))).push(t3.tooltipFooterHeaderFormatter(i3[0], true)), e3;
10543          }
10544          destroy() {
10545            this.label && (this.label = this.label.destroy()), this.split && (this.cleanSplit(true), this.tt && (this.tt = this.tt.destroy())), this.renderer && (this.renderer = this.renderer.destroy(), m(this.container)), o.clearTimeout(this.hideTimer);
10546          }
10547          getAnchor(t3, e3) {
10548            let i3;
10549            let {
10550              chart: s2,
10551              pointer: r2
10552            } = this, o2 = s2.inverted, n2 = s2.plotTop, a2 = s2.plotLeft;
10553            if ((t3 = w(t3))[0].series && t3[0].series.yAxis && !t3[0].series.yAxis.options.reversedStacks && (t3 = t3.slice().reverse()), this.followPointer && e3) void 0 === e3.chartX && (e3 = r2.normalize(e3)), i3 = [e3.chartX - a2, e3.chartY - n2];
10554            else if (t3[0].tooltipPos) i3 = t3[0].tooltipPos;
10555            else {
10556              let s3 = 0, r3 = 0;
10557              t3.forEach(function(t4) {
10558                let e4 = t4.pos(true);
10559                e4 && (s3 += e4[0], r3 += e4[1]);
10560              }), s3 /= t3.length, r3 /= t3.length, this.shared && t3.length > 1 && e3 && (o2 ? s3 = e3.chartX : r3 = e3.chartY), i3 = [s3 - a2, r3 - n2];
10561            }
10562            return i3.map(Math.round);
10563          }
10564          getClassName(t3, e3, i3) {
10565            let s2 = this.options, r2 = t3.series, o2 = r2.options;
10566            return [s2.className, "highcharts-label", i3 && "highcharts-tooltip-header", e3 ? "highcharts-tooltip-box" : "highcharts-tooltip", !i3 && "highcharts-color-" + k(t3.colorIndex, r2.colorIndex), o2 && o2.className].filter(S2).join(" ");
10567          }
10568          getLabel({
10569            anchorX: t3,
10570            anchorY: e3
10571          } = {
10572            anchorX: 0,
10573            anchorY: 0
10574          }) {
10575            let s2 = this, o2 = this.chart.styledMode, n2 = this.options, a2 = this.split && this.allowShared, h2 = this.container, l2 = this.chart.renderer;
10576            if (this.label) {
10577              let t4 = !this.label.hasClass("highcharts-label");
10578              (!a2 && t4 || a2 && !t4) && this.destroy();
10579            }
10580            if (!this.label) {
10581              if (this.outside) {
10582                let t4 = this.chart.options.chart.style, e4 = r.getRendererType();
10583                this.container = h2 = i2.doc.createElement("div"), h2.className = "highcharts-tooltip-container", f(h2, {
10584                  position: "absolute",
10585                  top: "1px",
10586                  pointerEvents: "none",
10587                  zIndex: Math.max(this.options.style.zIndex || 0, (t4 && t4.zIndex || 0) + 3)
10588                }), this.renderer = l2 = new e4(h2, 0, 0, t4, void 0, void 0, l2.styledMode);
10589              }
10590              if (a2 ? this.label = l2.g("tooltip") : (this.label = l2.label("", t3, e3, n2.shape, void 0, void 0, n2.useHTML, void 0, "tooltip").attr({
10591                padding: n2.padding,
10592                r: n2.borderRadius
10593              }), o2 || this.label.attr({
10594                fill: n2.backgroundColor,
10595                "stroke-width": n2.borderWidth || 0
10596              }).css(n2.style).css({
10597                pointerEvents: n2.style.pointerEvents || (this.shouldStickOnContact() ? "auto" : "none")
10598              })), s2.outside) {
10599                let t4 = this.label;
10600                [t4.xSetter, t4.ySetter].forEach((e4, i3) => {
10601                  t4[i3 ? "ySetter" : "xSetter"] = (r2) => {
10602                    e4.call(t4, s2.distance), t4[i3 ? "y" : "x"] = r2, h2 && (h2.style[i3 ? "top" : "left"] = `${r2}px`);
10603                  };
10604                });
10605              }
10606              this.label.attr({
10607                zIndex: 8
10608              }).shadow(n2.shadow).add();
10609            }
10610            return h2 && !h2.parentElement && i2.doc.body.appendChild(h2), this.label;
10611          }
10612          getPlayingField() {
10613            let {
10614              body: t3,
10615              documentElement: e3
10616            } = d, {
10617              chart: i3,
10618              distance: s2,
10619              outside: r2
10620            } = this;
10621            return {
10622              width: r2 ? Math.max(t3.scrollWidth, e3.scrollWidth, t3.offsetWidth, e3.offsetWidth, e3.clientWidth) - 2 * s2 : i3.chartWidth,
10623              height: r2 ? Math.max(t3.scrollHeight, e3.scrollHeight, t3.offsetHeight, e3.offsetHeight, e3.clientHeight) : i3.chartHeight
10624            };
10625          }
10626          getPosition(t3, e3, i3) {
10627            let {
10628              distance: s2,
10629              chart: r2,
10630              outside: o2,
10631              pointer: n2
10632            } = this, {
10633              inverted: a2,
10634              plotLeft: h2,
10635              plotTop: l2,
10636              polar: d2
10637            } = r2, {
10638              plotX: c2 = 0,
10639              plotY: p2 = 0
10640            } = i3, u12 = {}, g2 = a2 && i3.h || 0, {
10641              height: f2,
10642              width: m2
10643            } = this.getPlayingField(), x2 = n2.getChartPosition(), y2 = (t4) => t4 * x2.scaleX, b2 = (t4) => t4 * x2.scaleY, v2 = (i4) => {
10644              let n3 = "x" === i4;
10645              return [i4, n3 ? m2 : f2, n3 ? t3 : e3].concat(o2 ? [n3 ? y2(t3) : b2(e3), n3 ? x2.left - s2 + y2(c2 + h2) : x2.top - s2 + b2(p2 + l2), 0, n3 ? m2 : f2] : [n3 ? t3 : e3, n3 ? c2 + h2 : p2 + l2, n3 ? h2 : l2, n3 ? h2 + r2.plotWidth : l2 + r2.plotHeight]);
10646            }, S3 = v2("y"), C2 = v2("x"), M2, w2 = !!i3.negative;
10647            !d2 && r2.hoverSeries?.yAxis?.reversed && (w2 = !w2);
10648            let T3 = !this.followPointer && k(i3.ttBelow, !d2 && !a2 === w2), A2 = function(t4, e4, i4, r3, n3, a3, h3) {
10649              let l3 = o2 ? "y" === t4 ? b2(s2) : y2(s2) : s2, d3 = (i4 - r3) / 2, c3 = r3 < n3 - s2, p3 = n3 + s2 + r3 < e4, f3 = n3 - l3 - i4 + d3, m3 = n3 + l3 - d3;
10650              if (T3 && p3) u12[t4] = m3;
10651              else if (!T3 && c3) u12[t4] = f3;
10652              else if (c3) u12[t4] = Math.min(h3 - r3, f3 - g2 < 0 ? f3 : f3 - g2);
10653              else {
10654                if (!p3) return false;
10655                u12[t4] = Math.max(a3, m3 + g2 + i4 > e4 ? m3 : m3 + g2);
10656              }
10657            }, P = function(t4, e4, i4, r3, o3) {
10658              if (o3 < s2 || o3 > e4 - s2) return false;
10659              o3 < i4 / 2 ? u12[t4] = 1 : o3 > e4 - r3 / 2 ? u12[t4] = e4 - r3 - 2 : u12[t4] = o3 - i4 / 2;
10660            }, L = function(t4) {
10661              [S3, C2] = [C2, S3], M2 = t4;
10662            }, O = () => {
10663              false !== A2.apply(0, S3) ? false !== P.apply(0, C2) || M2 || (L(true), O()) : M2 ? u12.x = u12.y = 0 : (L(true), O());
10664            };
10665            return (a2 && !d2 || this.len > 1) && L(), O(), u12;
10666          }
10667          hide(t3) {
10668            let e3 = this;
10669            o.clearTimeout(this.hideTimer), t3 = k(t3, this.options.hideDelay), this.isHidden || (this.hideTimer = T2(function() {
10670              let i3 = e3.getLabel();
10671              e3.getLabel().animate({
10672                opacity: 0
10673              }, {
10674                duration: t3 ? 150 : t3,
10675                complete: () => {
10676                  i3.hide(), e3.container && e3.container.remove();
10677                }
10678              }), e3.isHidden = true;
10679            }, t3));
10680          }
10681          init(t3, e3) {
10682            this.chart = t3, this.options = e3, this.crosshairs = [], this.isHidden = true, this.split = e3.split && !t3.inverted && !t3.polar, this.shared = e3.shared || this.split, this.outside = k(e3.outside, !!(t3.scrollablePixelsX || t3.scrollablePixelsY));
10683          }
10684          shouldStickOnContact(t3) {
10685            return !!(!this.followPointer && this.options.stickOnContact && (!t3 || this.pointer.inClass(t3.target, "highcharts-tooltip")));
10686          }
10687          move(t3, e3, i3, s2) {
10688            let r2 = this, o2 = a(!r2.isHidden && r2.options.animation), n2 = r2.followPointer || (r2.len || 0) > 1, h2 = {
10689              x: t3,
10690              y: e3
10691            };
10692            n2 || (h2.anchorX = i3, h2.anchorY = s2), o2.step = () => r2.drawTracker(), r2.getLabel().animate(h2, o2);
10693          }
10694          refresh(t3, e3) {
10695            let {
10696              chart: i3,
10697              options: s2,
10698              pointer: r2,
10699              shared: n2
10700            } = this, a2 = w(t3), l2 = a2[0], d2 = [], c2 = s2.format, p2 = s2.formatter || this.defaultFormatter, u12 = i3.styledMode, f2 = {}, m2 = this.allowShared;
10701            if (!s2.enabled || !l2.series) return;
10702            o.clearTimeout(this.hideTimer), this.allowShared = !(!b(t3) && t3.series && t3.series.noSharedTooltip), m2 = m2 && !this.allowShared, this.followPointer = !this.split && l2.series.tooltipOptions.followPointer;
10703            let x2 = this.getAnchor(t3, e3), v2 = x2[0], C2 = x2[1];
10704            n2 && this.allowShared ? (r2.applyInactiveState(a2), a2.forEach(function(t4) {
10705              t4.setState("hover"), d2.push(t4.getLabelConfig());
10706            }), (f2 = l2.getLabelConfig()).points = d2) : f2 = l2.getLabelConfig(), this.len = d2.length;
10707            let M2 = S2(c2) ? h(c2, f2, i3) : p2.call(f2, this), T3 = l2.series;
10708            if (this.distance = k(T3.tooltipOptions.distance, 16), false === M2) this.hide();
10709            else {
10710              if (this.split && this.allowShared) this.renderSplit(M2, a2);
10711              else {
10712                let t4 = v2, o2 = C2;
10713                if (e3 && r2.isDirectTouch && (t4 = e3.chartX - i3.plotLeft, o2 = e3.chartY - i3.plotTop), i3.polar || false === T3.options.clip || a2.some((e4) => r2.isDirectTouch || e4.series.shouldShowTooltip(t4, o2))) {
10714                  let t5 = this.getLabel(m2 && this.tt || {});
10715                  (!s2.style.width || u12) && t5.css({
10716                    width: (this.outside ? this.getPlayingField() : i3.spacingBox).width + "px"
10717                  }), t5.attr({
10718                    class: this.getClassName(l2),
10719                    text: M2 && M2.join ? M2.join("") : M2
10720                  }), this.outside && t5.attr({
10721                    x: g(t5.x || 0, 0, this.getPlayingField().width - (t5.width || 0))
10722                  }), u12 || t5.attr({
10723                    stroke: s2.borderColor || l2.color || T3.color || "#666666"
10724                  }), this.updatePosition({
10725                    plotX: v2,
10726                    plotY: C2,
10727                    negative: l2.negative,
10728                    ttBelow: l2.ttBelow,
10729                    h: x2[2] || 0
10730                  });
10731                } else {
10732                  this.hide();
10733                  return;
10734                }
10735              }
10736              this.isHidden && this.label && this.label.attr({
10737                opacity: 1
10738              }).show(), this.isHidden = false;
10739            }
10740            y(this, "refresh");
10741          }
10742          renderSplit(t3, e3) {
10743            let i3 = this, {
10744              chart: s2,
10745              chart: {
10746                chartWidth: r2,
10747                chartHeight: o2,
10748                plotHeight: n2,
10749                plotLeft: a2,
10750                plotTop: h2,
10751                scrollablePixelsY: l2 = 0,
10752                scrollablePixelsX: u12,
10753                styledMode: f2
10754              },
10755              distance: m2,
10756              options: y2,
10757              options: {
10758                positioner: b2
10759              },
10760              pointer: v2
10761            } = i3, {
10762              scrollLeft: C2 = 0,
10763              scrollTop: M2 = 0
10764            } = s2.scrollablePlotArea?.scrollingContainer || {}, w2 = i3.outside && "number" != typeof u12 ? d.documentElement.getBoundingClientRect() : {
10765              left: C2,
10766              right: C2 + r2,
10767              top: M2,
10768              bottom: M2 + o2
10769            }, T3 = i3.getLabel(), A2 = this.renderer || s2.renderer, P = !!(s2.xAxis[0] && s2.xAxis[0].opposite), {
10770              left: L,
10771              top: O
10772            } = v2.getChartPosition(), D2 = h2 + M2, E = 0, I = n2 - l2;
10773            function j(t4, e4, s3, r3, o3 = true) {
10774              let n3, a3;
10775              return s3 ? (n3 = P ? 0 : I, a3 = g(t4 - r3 / 2, w2.left, w2.right - r3 - (i3.outside ? L : 0))) : (n3 = e4 - D2, a3 = g(a3 = o3 ? t4 - r3 - m2 : t4 + m2, o3 ? a3 : w2.left, w2.right)), {
10776                x: a3,
10777                y: n3
10778              };
10779            }
10780            S2(t3) && (t3 = [false, t3]);
10781            let B = t3.slice(0, e3.length + 1).reduce(function(t4, s3, r3) {
10782              if (false !== s3 && "" !== s3) {
10783                let o3 = e3[r3 - 1] || {
10784                  isHeader: true,
10785                  plotX: e3[0].plotX,
10786                  plotY: n2,
10787                  series: {}
10788                }, l3 = o3.isHeader, d2 = l3 ? i3 : o3.series, c2 = d2.tt = function(t5, e4, s4) {
10789                  let r4 = t5, {
10790                    isHeader: o4,
10791                    series: n3
10792                  } = e4;
10793                  if (!r4) {
10794                    let t6 = {
10795                      padding: y2.padding,
10796                      r: y2.borderRadius
10797                    };
10798                    f2 || (t6.fill = y2.backgroundColor, t6["stroke-width"] = y2.borderWidth ?? 1), r4 = A2.label("", 0, 0, y2[o4 ? "headerShape" : "shape"], void 0, void 0, y2.useHTML).addClass(i3.getClassName(e4, true, o4)).attr(t6).add(T3);
10799                  }
10800                  return r4.isActive = true, r4.attr({
10801                    text: s4
10802                  }), f2 || r4.css(y2.style).attr({
10803                    stroke: y2.borderColor || e4.color || n3.color || "#333333"
10804                  }), r4;
10805                }(d2.tt, o3, s3.toString()), p2 = c2.getBBox(), u13 = p2.width + c2.strokeWidth();
10806                l3 && (E = p2.height, I += E, P && (D2 -= E));
10807                let {
10808                  anchorX: x2,
10809                  anchorY: v3
10810                } = function(t5) {
10811                  let e4, i4;
10812                  let {
10813                    isHeader: s4,
10814                    plotX: r4 = 0,
10815                    plotY: o4 = 0,
10816                    series: l4
10817                  } = t5;
10818                  if (s4) e4 = Math.max(a2 + r4, a2), i4 = h2 + n2 / 2;
10819                  else {
10820                    let {
10821                      xAxis: t6,
10822                      yAxis: s5
10823                    } = l4;
10824                    e4 = t6.pos + g(r4, -m2, t6.len + m2), l4.shouldShowTooltip(0, s5.pos - h2 + o4, {
10825                      ignoreX: true
10826                    }) && (i4 = s5.pos + o4);
10827                  }
10828                  return {
10829                    anchorX: e4 = g(e4, w2.left - m2, w2.right + m2),
10830                    anchorY: i4
10831                  };
10832                }(o3);
10833                if ("number" == typeof v3) {
10834                  let e4 = p2.height + 1, s4 = b2 ? b2.call(i3, u13, e4, o3) : j(x2, v3, l3, u13);
10835                  t4.push({
10836                    align: b2 ? 0 : void 0,
10837                    anchorX: x2,
10838                    anchorY: v3,
10839                    boxWidth: u13,
10840                    point: o3,
10841                    rank: k(s4.rank, l3 ? 1 : 0),
10842                    size: e4,
10843                    target: s4.y,
10844                    tt: c2,
10845                    x: s4.x
10846                  });
10847                } else c2.isActive = false;
10848              }
10849              return t4;
10850            }, []);
10851            !b2 && B.some((t4) => {
10852              let {
10853                outside: e4
10854              } = i3, s3 = (e4 ? L : 0) + t4.anchorX;
10855              return s3 < w2.left && s3 + t4.boxWidth < w2.right || s3 < L - w2.left + t4.boxWidth && w2.right - s3 > s3;
10856            }) && (B = B.map((t4) => {
10857              let {
10858                x: e4,
10859                y: i4
10860              } = j(t4.anchorX, t4.anchorY, t4.point.isHeader, t4.boxWidth, false);
10861              return x(t4, {
10862                target: i4,
10863                x: e4
10864              });
10865            })), i3.cleanSplit(), p(B, I);
10866            let R = {
10867              left: L,
10868              right: L
10869            };
10870            B.forEach(function(t4) {
10871              let {
10872                x: e4,
10873                boxWidth: s3,
10874                isHeader: r3
10875              } = t4;
10876              !r3 && (i3.outside && L + e4 < R.left && (R.left = L + e4), !r3 && i3.outside && R.left + s3 > R.right && (R.right = L + e4));
10877            }), B.forEach(function(t4) {
10878              let {
10879                x: e4,
10880                anchorX: s3,
10881                anchorY: r3,
10882                pos: o3,
10883                point: {
10884                  isHeader: n3
10885                }
10886              } = t4, a3 = {
10887                visibility: void 0 === o3 ? "hidden" : "inherit",
10888                x: e4,
10889                y: (o3 || 0) + D2,
10890                anchorX: s3,
10891                anchorY: r3
10892              };
10893              if (i3.outside && e4 < s3) {
10894                let t5 = L - R.left;
10895                t5 > 0 && (n3 || (a3.x = e4 + t5, a3.anchorX = s3 + t5), n3 && (a3.x = (R.right - R.left) / 2, a3.anchorX = s3 + t5));
10896              }
10897              t4.tt.attr(a3);
10898            });
10899            let {
10900              container: z,
10901              outside: N,
10902              renderer: W
10903            } = i3;
10904            if (N && z && W) {
10905              let {
10906                width: t4,
10907                height: e4,
10908                x: i4,
10909                y: s3
10910              } = T3.getBBox();
10911              W.setSize(t4 + i4, e4 + s3, false), z.style.left = R.left + "px", z.style.top = O + "px";
10912            }
10913            c && T3.attr({
10914              opacity: 1 === T3.opacity ? 0.999 : 1
10915            });
10916          }
10917          drawTracker() {
10918            if (!this.shouldStickOnContact()) {
10919              this.tracker && (this.tracker = this.tracker.destroy());
10920              return;
10921            }
10922            let t3 = this.chart, e3 = this.label, i3 = this.shared ? t3.hoverPoints : t3.hoverPoint;
10923            if (!e3 || !i3) return;
10924            let s2 = {
10925              x: 0,
10926              y: 0,
10927              width: 0,
10928              height: 0
10929            }, r2 = this.getAnchor(i3), o2 = e3.getBBox();
10930            r2[0] += t3.plotLeft - (e3.translateX || 0), r2[1] += t3.plotTop - (e3.translateY || 0), s2.x = Math.min(0, r2[0]), s2.y = Math.min(0, r2[1]), s2.width = r2[0] < 0 ? Math.max(Math.abs(r2[0]), o2.width - r2[0]) : Math.max(Math.abs(r2[0]), o2.width), s2.height = r2[1] < 0 ? Math.max(Math.abs(r2[1]), o2.height - Math.abs(r2[1])) : Math.max(Math.abs(r2[1]), o2.height), this.tracker ? this.tracker.attr(s2) : (this.tracker = e3.renderer.rect(s2).addClass("highcharts-tracker").add(e3), t3.styledMode || this.tracker.attr({
10931              fill: "rgba(0,0,0,0)"
10932            }));
10933          }
10934          styledModeFormat(t3) {
10935            return t3.replace('style="font-size: 0.8em"', 'class="highcharts-header"').replace(/style="color:{(point|series)\.color}"/g, 'class="highcharts-color-{$1.colorIndex} {series.options.className} {point.options.className}"');
10936          }
10937          tooltipFooterHeaderFormatter(t3, e3) {
10938            let i3 = t3.series, s2 = i3.tooltipOptions, r2 = i3.xAxis, o2 = r2 && r2.dateTime, n2 = {
10939              isFooter: e3,
10940              labelConfig: t3
10941            }, a2 = s2.xDateFormat, l2 = s2[e3 ? "footerFormat" : "headerFormat"];
10942            return y(this, "headerFormatter", n2, function(e4) {
10943              o2 && !a2 && v(t3.key) && (a2 = o2.getXDateFormat(t3.key, s2.dateTimeLabelFormats)), o2 && a2 && (t3.point && t3.point.tooltipDateKeys || ["key"]).forEach(function(t4) {
10944                l2 = l2.replace("{point." + t4 + "}", "{point." + t4 + ":" + a2 + "}");
10945              }), i3.chart.styledMode && (l2 = this.styledModeFormat(l2)), e4.text = h(l2, {
10946                point: t3,
10947                series: i3
10948              }, this.chart);
10949            }), n2.text;
10950          }
10951          update(t3) {
10952            this.destroy(), this.init(this.chart, C(true, this.options, t3));
10953          }
10954          updatePosition(t3) {
10955            let {
10956              chart: e3,
10957              container: i3,
10958              distance: s2,
10959              options: r2,
10960              pointer: o2,
10961              renderer: n2
10962            } = this, {
10963              height: a2 = 0,
10964              width: h2 = 0
10965            } = this.getLabel(), {
10966              left: l2,
10967              top: d2,
10968              scaleX: c2,
10969              scaleY: p2
10970            } = o2.getChartPosition(), u12 = (r2.positioner || this.getPosition).call(this, h2, a2, t3), g2 = (t3.plotX || 0) + e3.plotLeft, m2 = (t3.plotY || 0) + e3.plotTop, x2;
10971            n2 && i3 && (r2.positioner && (u12.x += l2 - s2, u12.y += d2 - s2), x2 = (r2.borderWidth || 0) + 2 * s2 + 2, n2.setSize(h2 + x2, a2 + x2, false), (1 !== c2 || 1 !== p2) && (f(i3, {
10972              transform: `scale(${c2}, ${p2})`
10973            }), g2 *= c2, m2 *= p2), g2 += l2 - u12.x, m2 += d2 - u12.y), this.move(Math.round(u12.x), Math.round(u12.y || 0), g2, m2);
10974          }
10975        }
10976        return (n = A || (A = {})).compose = function(t3) {
10977          M(l, "Core.Tooltip") && u11(t3, "afterInit", function() {
10978            let t4 = this.chart;
10979            t4.options.tooltip && (t4.tooltip = new n(t4, t4.options.tooltip, this));
10980          });
10981        }, A;
10982      }), i(e, "Core/Series/Point.js", [e["Core/Renderer/HTML/AST.js"], e["Core/Animation/AnimationUtilities.js"], e["Core/Defaults.js"], e["Core/Templating.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, r) {
10983        let {
10984          animObject: o
10985        } = e2, {
10986          defaultOptions: n
10987        } = i2, {
10988          format: a
10989        } = s, {
10990          addEvent: h,
10991          crisp: l,
10992          erase: d,
10993          extend: c,
10994          fireEvent: p,
10995          getNestedProperty: u11,
10996          isArray: g,
10997          isFunction: f,
10998          isNumber: m,
10999          isObject: x,
11000          merge: y,
11001          pick: b,
11002          syncTimeout: v,
11003          removeEvent: S2,
11004          uniqueKey: C
11005        } = r;
11006        class k {
11007          animateBeforeDestroy() {
11008            let t3 = this, e3 = {
11009              x: t3.startXPos,
11010              opacity: 0
11011            }, i3 = t3.getGraphicalProps();
11012            i3.singular.forEach(function(i4) {
11013              t3[i4] = t3[i4].animate("dataLabel" === i4 ? {
11014                x: t3[i4].startXPos,
11015                y: t3[i4].startYPos,
11016                opacity: 0
11017              } : e3);
11018            }), i3.plural.forEach(function(e4) {
11019              t3[e4].forEach(function(e5) {
11020                e5.element && e5.animate(c({
11021                  x: t3.startXPos
11022                }, e5.startYPos ? {
11023                  x: e5.startXPos,
11024                  y: e5.startYPos
11025                } : {}));
11026              });
11027            });
11028          }
11029          applyOptions(t3, e3) {
11030            let i3 = this.series, s2 = i3.options.pointValKey || i3.pointValKey;
11031            return c(this, t3 = k.prototype.optionsToObject.call(this, t3)), this.options = this.options ? c(this.options, t3) : t3, t3.group && delete this.group, t3.dataLabels && delete this.dataLabels, s2 && (this.y = k.prototype.getNestedProperty.call(this, s2)), this.selected && (this.state = "select"), "name" in this && void 0 === e3 && i3.xAxis && i3.xAxis.hasNames && (this.x = i3.xAxis.nameToX(this)), void 0 === this.x && i3 ? this.x = e3 ?? i3.autoIncrement() : m(t3.x) && i3.options.relativeXValue && (this.x = i3.autoIncrement(t3.x)), this.isNull = this.isValid && !this.isValid(), this.formatPrefix = this.isNull ? "null" : "point", this;
11032          }
11033          destroy() {
11034            if (!this.destroyed) {
11035              let t3 = this, e3 = t3.series, i3 = e3.chart, s2 = e3.options.dataSorting, r2 = i3.hoverPoints, n2 = o(t3.series.chart.renderer.globalAnimation), a2 = () => {
11036                for (let e4 in (t3.graphic || t3.graphics || t3.dataLabel || t3.dataLabels) && (S2(t3), t3.destroyElements()), t3) delete t3[e4];
11037              };
11038              t3.legendItem && i3.legend.destroyItem(t3), r2 && (t3.setState(), d(r2, t3), r2.length || (i3.hoverPoints = null)), t3 === i3.hoverPoint && t3.onMouseOut(), s2 && s2.enabled ? (this.animateBeforeDestroy(), v(a2, n2.duration)) : a2(), i3.pointCount--;
11039            }
11040            this.destroyed = true;
11041          }
11042          destroyElements(t3) {
11043            let e3 = this, i3 = e3.getGraphicalProps(t3);
11044            i3.singular.forEach(function(t4) {
11045              e3[t4] = e3[t4].destroy();
11046            }), i3.plural.forEach(function(t4) {
11047              e3[t4].forEach(function(t5) {
11048                t5 && t5.element && t5.destroy();
11049              }), delete e3[t4];
11050            });
11051          }
11052          firePointEvent(t3, e3, i3) {
11053            let s2 = this, r2 = this.series.options;
11054            s2.manageEvent(t3), "click" === t3 && r2.allowPointSelect && (i3 = function(t4) {
11055              !s2.destroyed && s2.select && s2.select(null, t4.ctrlKey || t4.metaKey || t4.shiftKey);
11056            }), p(s2, t3, e3, i3);
11057          }
11058          getClassName() {
11059            return "highcharts-point" + (this.selected ? " highcharts-point-select" : "") + (this.negative ? " highcharts-negative" : "") + (this.isNull ? " highcharts-null-point" : "") + (void 0 !== this.colorIndex ? " highcharts-color-" + this.colorIndex : "") + (this.options.className ? " " + this.options.className : "") + (this.zone && this.zone.className ? " " + this.zone.className.replace("highcharts-negative", "") : "");
11060          }
11061          getGraphicalProps(t3) {
11062            let e3, i3;
11063            let s2 = this, r2 = [], o2 = {
11064              singular: [],
11065              plural: []
11066            };
11067            for ((t3 = t3 || {
11068              graphic: 1,
11069              dataLabel: 1
11070            }).graphic && r2.push("graphic", "connector"), t3.dataLabel && r2.push("dataLabel", "dataLabelPath", "dataLabelUpper"), i3 = r2.length; i3--; ) s2[e3 = r2[i3]] && o2.singular.push(e3);
11071            return ["graphic", "dataLabel"].forEach(function(e4) {
11072              let i4 = e4 + "s";
11073              t3[e4] && s2[i4] && o2.plural.push(i4);
11074            }), o2;
11075          }
11076          getLabelConfig() {
11077            return {
11078              x: this.category,
11079              y: this.y,
11080              color: this.color,
11081              colorIndex: this.colorIndex,
11082              key: this.name || this.category,
11083              series: this.series,
11084              point: this,
11085              percentage: this.percentage,
11086              total: this.total || this.stackTotal
11087            };
11088          }
11089          getNestedProperty(t3) {
11090            return t3 ? 0 === t3.indexOf("custom.") ? u11(t3, this.options) : this[t3] : void 0;
11091          }
11092          getZone() {
11093            let t3 = this.series, e3 = t3.zones, i3 = t3.zoneAxis || "y", s2, r2 = 0;
11094            for (s2 = e3[0]; this[i3] >= s2.value; ) s2 = e3[++r2];
11095            return this.nonZonedColor || (this.nonZonedColor = this.color), s2 && s2.color && !this.options.color ? this.color = s2.color : this.color = this.nonZonedColor, s2;
11096          }
11097          hasNewShapeType() {
11098            return (this.graphic && (this.graphic.symbolName || this.graphic.element.nodeName)) !== this.shapeType;
11099          }
11100          constructor(t3, e3, i3) {
11101            this.formatPrefix = "point", this.visible = true, this.series = t3, this.applyOptions(e3, i3), this.id ?? (this.id = C()), this.resolveColor(), t3.chart.pointCount++, p(this, "afterInit");
11102          }
11103          isValid() {
11104            return (m(this.x) || this.x instanceof Date) && m(this.y);
11105          }
11106          optionsToObject(t3) {
11107            let e3 = this.series, i3 = e3.options.keys, s2 = i3 || e3.pointArrayMap || ["y"], r2 = s2.length, o2 = {}, n2, a2 = 0, h2 = 0;
11108            if (m(t3) || null === t3) o2[s2[0]] = t3;
11109            else if (g(t3)) for (!i3 && t3.length > r2 && ("string" == (n2 = typeof t3[0]) ? o2.name = t3[0] : "number" === n2 && (o2.x = t3[0]), a2++); h2 < r2; ) i3 && void 0 === t3[a2] || (s2[h2].indexOf(".") > 0 ? k.prototype.setNestedProperty(o2, t3[a2], s2[h2]) : o2[s2[h2]] = t3[a2]), a2++, h2++;
11110            else "object" == typeof t3 && (o2 = t3, t3.dataLabels && (e3.hasDataLabels = () => true), t3.marker && (e3._hasPointMarkers = true));
11111            return o2;
11112          }
11113          pos(t3, e3 = this.plotY) {
11114            if (!this.destroyed) {
11115              let {
11116                plotX: i3,
11117                series: s2
11118              } = this, {
11119                chart: r2,
11120                xAxis: o2,
11121                yAxis: n2
11122              } = s2, a2 = 0, h2 = 0;
11123              if (m(i3) && m(e3)) return t3 && (a2 = o2 ? o2.pos : r2.plotLeft, h2 = n2 ? n2.pos : r2.plotTop), r2.inverted && o2 && n2 ? [n2.len - e3 + h2, o2.len - i3 + a2] : [i3 + a2, e3 + h2];
11124            }
11125          }
11126          resolveColor() {
11127            let t3 = this.series, e3 = t3.chart.options.chart, i3 = t3.chart.styledMode, s2, r2, o2 = e3.colorCount, n2;
11128            delete this.nonZonedColor, t3.options.colorByPoint ? (i3 || (s2 = (r2 = t3.options.colors || t3.chart.options.colors)[t3.colorCounter], o2 = r2.length), n2 = t3.colorCounter, t3.colorCounter++, t3.colorCounter === o2 && (t3.colorCounter = 0)) : (i3 || (s2 = t3.color), n2 = t3.colorIndex), this.colorIndex = b(this.options.colorIndex, n2), this.color = b(this.options.color, s2);
11129          }
11130          setNestedProperty(t3, e3, i3) {
11131            return i3.split(".").reduce(function(t4, i4, s2, r2) {
11132              let o2 = r2.length - 1 === s2;
11133              return t4[i4] = o2 ? e3 : x(t4[i4], true) ? t4[i4] : {}, t4[i4];
11134            }, t3), t3;
11135          }
11136          shouldDraw() {
11137            return !this.isNull;
11138          }
11139          tooltipFormatter(t3) {
11140            let e3 = this.series, i3 = e3.tooltipOptions, s2 = b(i3.valueDecimals, ""), r2 = i3.valuePrefix || "", o2 = i3.valueSuffix || "";
11141            return e3.chart.styledMode && (t3 = e3.chart.tooltip.styledModeFormat(t3)), (e3.pointArrayMap || ["y"]).forEach(function(e4) {
11142              e4 = "{point." + e4, (r2 || o2) && (t3 = t3.replace(RegExp(e4 + "}", "g"), r2 + e4 + "}" + o2)), t3 = t3.replace(RegExp(e4 + "}", "g"), e4 + ":,." + s2 + "f}");
11143            }), a(t3, {
11144              point: this,
11145              series: this.series
11146            }, e3.chart);
11147          }
11148          update(t3, e3, i3, s2) {
11149            let r2;
11150            let o2 = this, n2 = o2.series, a2 = o2.graphic, h2 = n2.chart, l2 = n2.options;
11151            function d2() {
11152              o2.applyOptions(t3);
11153              let s3 = a2 && o2.hasMockGraphic, d3 = null === o2.y ? !s3 : s3;
11154              a2 && d3 && (o2.graphic = a2.destroy(), delete o2.hasMockGraphic), x(t3, true) && (a2 && a2.element && t3 && t3.marker && void 0 !== t3.marker.symbol && (o2.graphic = a2.destroy()), t3?.dataLabels && o2.dataLabel && (o2.dataLabel = o2.dataLabel.destroy())), r2 = o2.index, n2.updateParallelArrays(o2, r2), l2.data[r2] = x(l2.data[r2], true) || x(t3, true) ? o2.options : b(t3, l2.data[r2]), n2.isDirty = n2.isDirtyData = true, !n2.fixedBox && n2.hasCartesianSeries && (h2.isDirtyBox = true), "point" === l2.legendType && (h2.isDirtyLegend = true), e3 && h2.redraw(i3);
11155            }
11156            e3 = b(e3, true), false === s2 ? d2() : o2.firePointEvent("update", {
11157              options: t3
11158            }, d2);
11159          }
11160          remove(t3, e3) {
11161            this.series.removePoint(this.series.data.indexOf(this), t3, e3);
11162          }
11163          select(t3, e3) {
11164            let i3 = this, s2 = i3.series, r2 = s2.chart;
11165            t3 = b(t3, !i3.selected), this.selectedStaging = t3, i3.firePointEvent(t3 ? "select" : "unselect", {
11166              accumulate: e3
11167            }, function() {
11168              i3.selected = i3.options.selected = t3, s2.options.data[s2.data.indexOf(i3)] = i3.options, i3.setState(t3 && "select"), e3 || r2.getSelectedPoints().forEach(function(t4) {
11169                let e4 = t4.series;
11170                t4.selected && t4 !== i3 && (t4.selected = t4.options.selected = false, e4.options.data[e4.data.indexOf(t4)] = t4.options, t4.setState(r2.hoverPoints && e4.options.inactiveOtherPoints ? "inactive" : ""), t4.firePointEvent("unselect"));
11171              });
11172            }), delete this.selectedStaging;
11173          }
11174          onMouseOver(t3) {
11175            let {
11176              inverted: e3,
11177              pointer: i3
11178            } = this.series.chart;
11179            i3 && (t3 = t3 ? i3.normalize(t3) : i3.getChartCoordinatesFromPoint(this, e3), i3.runPointActions(t3, this));
11180          }
11181          onMouseOut() {
11182            let t3 = this.series.chart;
11183            this.firePointEvent("mouseOut"), this.series.options.inactiveOtherPoints || (t3.hoverPoints || []).forEach(function(t4) {
11184              t4.setState();
11185            }), t3.hoverPoints = t3.hoverPoint = null;
11186          }
11187          manageEvent(t3) {
11188            let e3 = y(this.series.options.point, this.options), i3 = e3.events?.[t3];
11189            f(i3) && (!this.hcEvents?.[t3] || this.hcEvents?.[t3]?.map((t4) => t4.fn).indexOf(i3) === -1) ? (this.importedUserEvent?.(), this.importedUserEvent = h(this, t3, i3)) : this.importedUserEvent && !i3 && this.hcEvents?.[t3] && (S2(this, t3), delete this.hcEvents[t3], Object.keys(this.hcEvents) || delete this.importedUserEvent);
11190          }
11191          setState(e3, i3) {
11192            let s2 = this.series, r2 = this.state, o2 = s2.options.states[e3 || "normal"] || {}, a2 = n.plotOptions[s2.type].marker && s2.options.marker, h2 = a2 && false === a2.enabled, l2 = a2 && a2.states && a2.states[e3 || "normal"] || {}, d2 = false === l2.enabled, u12 = this.marker || {}, g2 = s2.chart, f2 = a2 && s2.markerAttribs, x2 = s2.halo, y2, v2, S3, C2 = s2.stateMarkerGraphic, k2;
11193            if ((e3 = e3 || "") === this.state && !i3 || this.selected && "select" !== e3 || false === o2.enabled || e3 && (d2 || h2 && false === l2.enabled) || e3 && u12.states && u12.states[e3] && false === u12.states[e3].enabled) return;
11194            if (this.state = e3, f2 && (y2 = s2.markerAttribs(this, e3)), this.graphic && !this.hasMockGraphic) {
11195              if (r2 && this.graphic.removeClass("highcharts-point-" + r2), e3 && this.graphic.addClass("highcharts-point-" + e3), !g2.styledMode) {
11196                v2 = s2.pointAttribs(this, e3), S3 = b(g2.options.chart.animation, o2.animation);
11197                let t3 = v2.opacity;
11198                s2.options.inactiveOtherPoints && m(t3) && (this.dataLabels || []).forEach(function(e4) {
11199                  e4 && !e4.hasClass("highcharts-data-label-hidden") && (e4.animate({
11200                    opacity: t3
11201                  }, S3), e4.connector && e4.connector.animate({
11202                    opacity: t3
11203                  }, S3));
11204                }), this.graphic.animate(v2, S3);
11205              }
11206              y2 && this.graphic.animate(y2, b(g2.options.chart.animation, l2.animation, a2.animation)), C2 && C2.hide();
11207            } else e3 && l2 && (k2 = u12.symbol || s2.symbol, C2 && C2.currentSymbol !== k2 && (C2 = C2.destroy()), y2 && (C2 ? C2[i3 ? "animate" : "attr"]({
11208              x: y2.x,
11209              y: y2.y
11210            }) : k2 && (s2.stateMarkerGraphic = C2 = g2.renderer.symbol(k2, y2.x, y2.y, y2.width, y2.height).add(s2.markerGroup), C2.currentSymbol = k2)), !g2.styledMode && C2 && "inactive" !== this.state && C2.attr(s2.pointAttribs(this, e3))), C2 && (C2[e3 && this.isInside ? "show" : "hide"](), C2.element.point = this, C2.addClass(this.getClassName(), true));
11211            let M = o2.halo, w = this.graphic || C2, T2 = w && w.visibility || "inherit";
11212            M && M.size && w && "hidden" !== T2 && !this.isCluster ? (x2 || (s2.halo = x2 = g2.renderer.path().add(w.parentGroup)), x2.show()[i3 ? "animate" : "attr"]({
11213              d: this.haloPath(M.size)
11214            }), x2.attr({
11215              class: "highcharts-halo highcharts-color-" + b(this.colorIndex, s2.colorIndex) + (this.className ? " " + this.className : ""),
11216              visibility: T2,
11217              zIndex: -1
11218            }), x2.point = this, g2.styledMode || x2.attr(c({
11219              fill: this.color || s2.color,
11220              "fill-opacity": M.opacity
11221            }, t2.filterUserAttributes(M.attributes || {})))) : x2?.point?.haloPath && !x2.point.destroyed && x2.animate({
11222              d: x2.point.haloPath(0)
11223            }, null, x2.hide), p(this, "afterSetState", {
11224              state: e3
11225            });
11226          }
11227          haloPath(t3) {
11228            let e3 = this.pos();
11229            return e3 ? this.series.chart.renderer.symbols.circle(l(e3[0], 1) - t3, e3[1] - t3, 2 * t3, 2 * t3) : [];
11230          }
11231        }
11232        return k;
11233      }), i(e, "Core/Pointer.js", [e["Core/Color/Color.js"], e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
11234        var s;
11235        let {
11236          parse: r
11237        } = t2, {
11238          charts: o,
11239          composed: n,
11240          isTouchDevice: a
11241        } = e2, {
11242          addEvent: h,
11243          attr: l,
11244          css: d,
11245          extend: c,
11246          find: p,
11247          fireEvent: u11,
11248          isNumber: g,
11249          isObject: f,
11250          objectEach: m,
11251          offset: x,
11252          pick: y,
11253          pushUnique: b,
11254          splat: v
11255        } = i2;
11256        class S2 {
11257          applyInactiveState(t3) {
11258            let e3 = [], i3;
11259            (t3 || []).forEach(function(t4) {
11260              i3 = t4.series, e3.push(i3), i3.linkedParent && e3.push(i3.linkedParent), i3.linkedSeries && (e3 = e3.concat(i3.linkedSeries)), i3.navigatorSeries && e3.push(i3.navigatorSeries);
11261            }), this.chart.series.forEach(function(t4) {
11262              -1 === e3.indexOf(t4) ? t4.setState("inactive", true) : t4.options.inactiveOtherPoints && t4.setAllPointsToState("inactive");
11263            });
11264          }
11265          destroy() {
11266            let t3 = this;
11267            this.eventsToUnbind.forEach((t4) => t4()), this.eventsToUnbind = [], !e2.chartCount && (S2.unbindDocumentMouseUp && S2.unbindDocumentMouseUp.forEach((t4) => t4()), S2.unbindDocumentTouchEnd && (S2.unbindDocumentTouchEnd = S2.unbindDocumentTouchEnd())), clearInterval(t3.tooltipTimeout), m(t3, function(e3, i3) {
11268              t3[i3] = void 0;
11269            });
11270          }
11271          getSelectionMarkerAttrs(t3, e3) {
11272            let i3 = {
11273              args: {
11274                chartX: t3,
11275                chartY: e3
11276              },
11277              attrs: {},
11278              shapeType: "rect"
11279            };
11280            return u11(this, "getSelectionMarkerAttrs", i3, (i4) => {
11281              let s2;
11282              let {
11283                chart: r2,
11284                zoomHor: o2,
11285                zoomVert: n2
11286              } = this, {
11287                mouseDownX: a2 = 0,
11288                mouseDownY: h2 = 0
11289              } = r2, l2 = i4.attrs;
11290              l2.x = r2.plotLeft, l2.y = r2.plotTop, l2.width = o2 ? 1 : r2.plotWidth, l2.height = n2 ? 1 : r2.plotHeight, o2 && (s2 = t3 - a2, l2.width = Math.max(1, Math.abs(s2)), l2.x = (s2 > 0 ? 0 : s2) + a2), n2 && (s2 = e3 - h2, l2.height = Math.max(1, Math.abs(s2)), l2.y = (s2 > 0 ? 0 : s2) + h2);
11291            }), i3;
11292          }
11293          drag(t3) {
11294            let {
11295              chart: e3
11296            } = this, {
11297              mouseDownX: i3 = 0,
11298              mouseDownY: s2 = 0
11299            } = e3, {
11300              panning: o2,
11301              panKey: n2,
11302              selectionMarkerFill: a2
11303            } = e3.options.chart, h2 = e3.plotLeft, l2 = e3.plotTop, d2 = e3.plotWidth, c2 = e3.plotHeight, p2 = f(o2) ? o2.enabled : o2, u12 = n2 && t3[`${n2}Key`], g2 = t3.chartX, m2 = t3.chartY, x2, y2 = this.selectionMarker;
11304            if ((!y2 || !y2.touch) && (g2 < h2 ? g2 = h2 : g2 > h2 + d2 && (g2 = h2 + d2), m2 < l2 ? m2 = l2 : m2 > l2 + c2 && (m2 = l2 + c2), this.hasDragged = Math.sqrt(Math.pow(i3 - g2, 2) + Math.pow(s2 - m2, 2)), this.hasDragged > 10)) {
11305              x2 = e3.isInsidePlot(i3 - h2, s2 - l2, {
11306                visiblePlotOnly: true
11307              });
11308              let {
11309                shapeType: n3,
11310                attrs: d3
11311              } = this.getSelectionMarkerAttrs(g2, m2);
11312              (e3.hasCartesianSeries || e3.mapView) && this.hasZoom && x2 && !u12 && !y2 && (this.selectionMarker = y2 = e3.renderer[n3](), y2.attr({
11313                class: "highcharts-selection-marker",
11314                zIndex: 7
11315              }).add(), e3.styledMode || y2.attr({
11316                fill: a2 || r("#334eff").setOpacity(0.25).get()
11317              })), y2 && y2.attr(d3), x2 && !y2 && p2 && e3.pan(t3, o2);
11318            }
11319          }
11320          dragStart(t3) {
11321            let e3 = this.chart;
11322            e3.mouseIsDown = t3.type, e3.cancelClick = false, e3.mouseDownX = t3.chartX, e3.mouseDownY = t3.chartY;
11323          }
11324          getSelectionBox(t3) {
11325            let e3 = {
11326              args: {
11327                marker: t3
11328              },
11329              result: t3.getBBox()
11330            };
11331            return u11(this, "getSelectionBox", e3), e3.result;
11332          }
11333          drop(t3) {
11334            let e3;
11335            let {
11336              chart: i3,
11337              selectionMarker: s2
11338            } = this;
11339            for (let t4 of i3.axes) t4.isPanning && (t4.isPanning = false, (t4.options.startOnTick || t4.options.endOnTick || t4.series.some((t5) => t5.boosted)) && (t4.forceRedraw = true, t4.setExtremes(t4.userMin, t4.userMax, false), e3 = true));
11340            if (e3 && i3.redraw(), s2 && t3) {
11341              if (this.hasDragged) {
11342                let e4 = this.getSelectionBox(s2);
11343                i3.transform({
11344                  axes: i3.axes.filter((t4) => t4.zoomEnabled && ("xAxis" === t4.coll && this.zoomX || "yAxis" === t4.coll && this.zoomY)),
11345                  selection: __spreadValues({
11346                    originalEvent: t3,
11347                    xAxis: [],
11348                    yAxis: []
11349                  }, e4),
11350                  from: e4
11351                });
11352              }
11353              g(i3.index) && (this.selectionMarker = s2.destroy());
11354            }
11355            i3 && g(i3.index) && (d(i3.container, {
11356              cursor: i3._cursor
11357            }), i3.cancelClick = this.hasDragged > 10, i3.mouseIsDown = false, this.hasDragged = 0, this.pinchDown = []);
11358          }
11359          findNearestKDPoint(t3, e3, i3) {
11360            let s2;
11361            return t3.forEach(function(t4) {
11362              let r2 = !(t4.noSharedTooltip && e3) && 0 > t4.options.findNearestPointBy.indexOf("y"), o2 = t4.searchPoint(i3, r2);
11363              f(o2, true) && o2.series && (!f(s2, true) || function(t5, i4) {
11364                let s3 = t5.distX - i4.distX, r3 = t5.dist - i4.dist, o3 = i4.series.group?.zIndex - t5.series.group?.zIndex;
11365                return 0 !== s3 && e3 ? s3 : 0 !== r3 ? r3 : 0 !== o3 ? o3 : t5.series.index > i4.series.index ? -1 : 1;
11366              }(s2, o2) > 0) && (s2 = o2);
11367            }), s2;
11368          }
11369          getChartCoordinatesFromPoint(t3, e3) {
11370            let {
11371              xAxis: i3,
11372              yAxis: s2
11373            } = t3.series, r2 = t3.shapeArgs;
11374            if (i3 && s2) {
11375              let o2 = t3.clientX ?? t3.plotX ?? 0, n2 = t3.plotY || 0;
11376              return t3.isNode && r2 && g(r2.x) && g(r2.y) && (o2 = r2.x, n2 = r2.y), e3 ? {
11377                chartX: s2.len + s2.pos - n2,
11378                chartY: i3.len + i3.pos - o2
11379              } : {
11380                chartX: o2 + i3.pos,
11381                chartY: n2 + s2.pos
11382              };
11383            }
11384            if (r2 && r2.x && r2.y) return {
11385              chartX: r2.x,
11386              chartY: r2.y
11387            };
11388          }
11389          getChartPosition() {
11390            if (this.chartPosition) return this.chartPosition;
11391            let {
11392              container: t3
11393            } = this.chart, e3 = x(t3);
11394            this.chartPosition = {
11395              left: e3.left,
11396              top: e3.top,
11397              scaleX: 1,
11398              scaleY: 1
11399            };
11400            let {
11401              offsetHeight: i3,
11402              offsetWidth: s2
11403            } = t3;
11404            return s2 > 2 && i3 > 2 && (this.chartPosition.scaleX = e3.width / s2, this.chartPosition.scaleY = e3.height / i3), this.chartPosition;
11405          }
11406          getCoordinates(t3) {
11407            let e3 = {
11408              xAxis: [],
11409              yAxis: []
11410            };
11411            for (let i3 of this.chart.axes) e3[i3.isXAxis ? "xAxis" : "yAxis"].push({
11412              axis: i3,
11413              value: i3.toValue(t3[i3.horiz ? "chartX" : "chartY"])
11414            });
11415            return e3;
11416          }
11417          getHoverData(t3, e3, i3, s2, r2, o2) {
11418            let n2 = [], a2 = function(t4) {
11419              return t4.visible && !(!r2 && t4.directTouch) && y(t4.options.enableMouseTracking, true);
11420            }, h2 = e3, l2, d2 = {
11421              chartX: o2 ? o2.chartX : void 0,
11422              chartY: o2 ? o2.chartY : void 0,
11423              shared: r2
11424            };
11425            u11(this, "beforeGetHoverData", d2), l2 = h2 && !h2.stickyTracking ? [h2] : i3.filter((t4) => t4.stickyTracking && (d2.filter || a2)(t4));
11426            let c2 = s2 && t3 || !o2 ? t3 : this.findNearestKDPoint(l2, r2, o2);
11427            return h2 = c2 && c2.series, c2 && (r2 && !h2.noSharedTooltip ? (l2 = i3.filter(function(t4) {
11428              return d2.filter ? d2.filter(t4) : a2(t4) && !t4.noSharedTooltip;
11429            })).forEach(function(t4) {
11430              let e4 = p(t4.points, function(t5) {
11431                return t5.x === c2.x && !t5.isNull;
11432              });
11433              f(e4) && (t4.boosted && t4.boost && (e4 = t4.boost.getPoint(e4)), n2.push(e4));
11434            }) : n2.push(c2)), u11(this, "afterGetHoverData", d2 = {
11435              hoverPoint: c2
11436            }), {
11437              hoverPoint: d2.hoverPoint,
11438              hoverSeries: h2,
11439              hoverPoints: n2
11440            };
11441          }
11442          getPointFromEvent(t3) {
11443            let e3 = t3.target, i3;
11444            for (; e3 && !i3; ) i3 = e3.point, e3 = e3.parentNode;
11445            return i3;
11446          }
11447          onTrackerMouseOut(t3) {
11448            let e3 = this.chart, i3 = t3.relatedTarget, s2 = e3.hoverSeries;
11449            this.isDirectTouch = false, !s2 || !i3 || s2.stickyTracking || this.inClass(i3, "highcharts-tooltip") || this.inClass(i3, "highcharts-series-" + s2.index) && this.inClass(i3, "highcharts-tracker") || s2.onMouseOut();
11450          }
11451          inClass(t3, e3) {
11452            let i3 = t3, s2;
11453            for (; i3; ) {
11454              if (s2 = l(i3, "class")) {
11455                if (-1 !== s2.indexOf(e3)) return true;
11456                if (-1 !== s2.indexOf("highcharts-container")) return false;
11457              }
11458              i3 = i3.parentElement;
11459            }
11460          }
11461          constructor(t3, e3) {
11462            this.hasDragged = 0, this.pointerCaptureEventsToUnbind = [], this.eventsToUnbind = [], this.options = e3, this.chart = t3, this.runChartClick = !!e3.chart.events?.click, this.pinchDown = [], this.setDOMEvents(), u11(this, "afterInit");
11463          }
11464          normalize(t3, e3) {
11465            let i3 = t3.touches, s2 = i3 ? i3.length ? i3.item(0) : y(i3.changedTouches, t3.changedTouches)[0] : t3;
11466            e3 || (e3 = this.getChartPosition());
11467            let r2 = s2.pageX - e3.left, o2 = s2.pageY - e3.top;
11468            return c(t3, {
11469              chartX: Math.round(r2 /= e3.scaleX),
11470              chartY: Math.round(o2 /= e3.scaleY)
11471            });
11472          }
11473          onContainerClick(t3) {
11474            let e3 = this.chart, i3 = e3.hoverPoint, s2 = this.normalize(t3), r2 = e3.plotLeft, o2 = e3.plotTop;
11475            !e3.cancelClick && (i3 && this.inClass(s2.target, "highcharts-tracker") ? (u11(i3.series, "click", c(s2, {
11476              point: i3
11477            })), e3.hoverPoint && i3.firePointEvent("click", s2)) : (c(s2, this.getCoordinates(s2)), e3.isInsidePlot(s2.chartX - r2, s2.chartY - o2, {
11478              visiblePlotOnly: true
11479            }) && u11(e3, "click", s2)));
11480          }
11481          onContainerMouseDown(t3) {
11482            let i3 = (1 & (t3.buttons || t3.button)) == 1;
11483            t3 = this.normalize(t3), e2.isFirefox && 0 !== t3.button && this.onContainerMouseMove(t3), (void 0 === t3.button || i3) && (this.zoomOption(t3), i3 && t3.preventDefault?.(), this.dragStart(t3));
11484          }
11485          onContainerMouseLeave(t3) {
11486            let {
11487              pointer: e3
11488            } = o[y(S2.hoverChartIndex, -1)] || {};
11489            t3 = this.normalize(t3), this.onContainerMouseMove(t3), e3 && !this.inClass(t3.relatedTarget, "highcharts-tooltip") && (e3.reset(), e3.chartPosition = void 0);
11490          }
11491          onContainerMouseEnter() {
11492            delete this.chartPosition;
11493          }
11494          onContainerMouseMove(t3) {
11495            let e3 = this.chart, i3 = e3.tooltip, s2 = this.normalize(t3);
11496            this.setHoverChartIndex(t3), ("mousedown" === e3.mouseIsDown || this.touchSelect(s2)) && this.drag(s2), !e3.openMenu && (this.inClass(s2.target, "highcharts-tracker") || e3.isInsidePlot(s2.chartX - e3.plotLeft, s2.chartY - e3.plotTop, {
11497              visiblePlotOnly: true
11498            })) && !(i3 && i3.shouldStickOnContact(s2)) && (this.inClass(s2.target, "highcharts-no-tooltip") ? this.reset(false, 0) : this.runPointActions(s2));
11499          }
11500          onDocumentTouchEnd(t3) {
11501            this.onDocumentMouseUp(t3);
11502          }
11503          onContainerTouchMove(t3) {
11504            this.touchSelect(t3) ? this.onContainerMouseMove(t3) : this.touch(t3);
11505          }
11506          onContainerTouchStart(t3) {
11507            this.touchSelect(t3) ? this.onContainerMouseDown(t3) : (this.zoomOption(t3), this.touch(t3, true));
11508          }
11509          onDocumentMouseMove(t3) {
11510            let e3 = this.chart, i3 = e3.tooltip, s2 = this.chartPosition, r2 = this.normalize(t3, s2);
11511            !s2 || e3.isInsidePlot(r2.chartX - e3.plotLeft, r2.chartY - e3.plotTop, {
11512              visiblePlotOnly: true
11513            }) || i3 && i3.shouldStickOnContact(r2) || r2.target !== e3.container.ownerDocument && this.inClass(r2.target, "highcharts-tracker") || this.reset();
11514          }
11515          onDocumentMouseUp(t3) {
11516            o[y(S2.hoverChartIndex, -1)]?.pointer?.drop(t3);
11517          }
11518          pinch(t3) {
11519            let e3 = this, {
11520              chart: i3,
11521              hasZoom: s2,
11522              lastTouches: r2
11523            } = e3, o2 = [].map.call(t3.touches || [], (t4) => e3.normalize(t4)), n2 = o2.length, a2 = 1 === n2 && (e3.inClass(t3.target, "highcharts-tracker") && i3.runTrackerClick || e3.runChartClick), h2 = i3.tooltip, l2 = 1 === n2 && y(h2?.options.followTouchMove, true);
11524            n2 > 1 ? e3.initiated = true : l2 && (e3.initiated = false), s2 && e3.initiated && !a2 && false !== t3.cancelable && t3.preventDefault(), "touchstart" === t3.type ? (e3.pinchDown = o2, e3.res = true, i3.mouseDownX = t3.chartX) : l2 ? this.runPointActions(e3.normalize(t3)) : r2 && (u11(i3, "touchpan", {
11525              originalEvent: t3,
11526              touches: o2
11527            }, () => {
11528              let e4 = (t4) => {
11529                let e5 = t4[0], i4 = t4[1] || e5;
11530                return {
11531                  x: e5.chartX,
11532                  y: e5.chartY,
11533                  width: i4.chartX - e5.chartX,
11534                  height: i4.chartY - e5.chartY
11535                };
11536              };
11537              i3.transform({
11538                axes: i3.axes.filter((t4) => t4.zoomEnabled && (this.zoomHor && t4.horiz || this.zoomVert && !t4.horiz)),
11539                to: e4(o2),
11540                from: e4(r2),
11541                trigger: t3.type
11542              });
11543            }), e3.res && (e3.res = false, this.reset(false, 0))), e3.lastTouches = o2;
11544          }
11545          reset(t3, e3) {
11546            let i3 = this.chart, s2 = i3.hoverSeries, r2 = i3.hoverPoint, o2 = i3.hoverPoints, n2 = i3.tooltip, a2 = n2 && n2.shared ? o2 : r2;
11547            t3 && a2 && v(a2).forEach(function(e4) {
11548              e4.series.isCartesian && void 0 === e4.plotX && (t3 = false);
11549            }), t3 ? n2 && a2 && v(a2).length && (n2.refresh(a2), n2.shared && o2 ? o2.forEach(function(t4) {
11550              t4.setState(t4.state, true), t4.series.isCartesian && (t4.series.xAxis.crosshair && t4.series.xAxis.drawCrosshair(null, t4), t4.series.yAxis.crosshair && t4.series.yAxis.drawCrosshair(null, t4));
11551            }) : r2 && (r2.setState(r2.state, true), i3.axes.forEach(function(t4) {
11552              t4.crosshair && r2.series[t4.coll] === t4 && t4.drawCrosshair(null, r2);
11553            }))) : (r2 && r2.onMouseOut(), o2 && o2.forEach(function(t4) {
11554              t4.setState();
11555            }), s2 && s2.onMouseOut(), n2 && n2.hide(e3), this.unDocMouseMove && (this.unDocMouseMove = this.unDocMouseMove()), i3.axes.forEach(function(t4) {
11556              t4.hideCrosshair();
11557            }), i3.hoverPoints = i3.hoverPoint = void 0);
11558          }
11559          runPointActions(t3, e3, i3) {
11560            let s2 = this.chart, r2 = s2.series, n2 = s2.tooltip && s2.tooltip.options.enabled ? s2.tooltip : void 0, a2 = !!n2 && n2.shared, l2 = e3 || s2.hoverPoint, d2 = l2 && l2.series || s2.hoverSeries, c2 = (!t3 || "touchmove" !== t3.type) && (!!e3 || d2 && d2.directTouch && this.isDirectTouch), u12 = this.getHoverData(l2, d2, r2, c2, a2, t3);
11561            l2 = u12.hoverPoint, d2 = u12.hoverSeries;
11562            let g2 = u12.hoverPoints, f2 = d2 && d2.tooltipOptions.followPointer && !d2.tooltipOptions.split, m2 = a2 && d2 && !d2.noSharedTooltip;
11563            if (l2 && (i3 || l2 !== s2.hoverPoint || n2 && n2.isHidden)) {
11564              if ((s2.hoverPoints || []).forEach(function(t4) {
11565                -1 === g2.indexOf(t4) && t4.setState();
11566              }), s2.hoverSeries !== d2 && d2.onMouseOver(), this.applyInactiveState(g2), (g2 || []).forEach(function(t4) {
11567                t4.setState("hover");
11568              }), s2.hoverPoint && s2.hoverPoint.firePointEvent("mouseOut"), !l2.series) return;
11569              s2.hoverPoints = g2, s2.hoverPoint = l2, l2.firePointEvent("mouseOver", void 0, () => {
11570                n2 && l2 && n2.refresh(m2 ? g2 : l2, t3);
11571              });
11572            } else if (f2 && n2 && !n2.isHidden) {
11573              let e4 = n2.getAnchor([{}], t3);
11574              s2.isInsidePlot(e4[0], e4[1], {
11575                visiblePlotOnly: true
11576              }) && n2.updatePosition({
11577                plotX: e4[0],
11578                plotY: e4[1]
11579              });
11580            }
11581            this.unDocMouseMove || (this.unDocMouseMove = h(s2.container.ownerDocument, "mousemove", (t4) => o[S2.hoverChartIndex ?? -1]?.pointer?.onDocumentMouseMove(t4)), this.eventsToUnbind.push(this.unDocMouseMove)), s2.axes.forEach(function(e4) {
11582              let i4;
11583              let r3 = y((e4.crosshair || {}).snap, true);
11584              !r3 || (i4 = s2.hoverPoint) && i4.series[e4.coll] === e4 || (i4 = p(g2, (t4) => t4.series && t4.series[e4.coll] === e4)), i4 || !r3 ? e4.drawCrosshair(t3, i4) : e4.hideCrosshair();
11585            });
11586          }
11587          setDOMEvents() {
11588            let t3 = this.chart.container, e3 = t3.ownerDocument;
11589            t3.onmousedown = this.onContainerMouseDown.bind(this), t3.onmousemove = this.onContainerMouseMove.bind(this), t3.onclick = this.onContainerClick.bind(this), this.eventsToUnbind.push(h(t3, "mouseenter", this.onContainerMouseEnter.bind(this)), h(t3, "mouseleave", this.onContainerMouseLeave.bind(this))), S2.unbindDocumentMouseUp || (S2.unbindDocumentMouseUp = []), S2.unbindDocumentMouseUp.push(h(e3, "mouseup", this.onDocumentMouseUp.bind(this)));
11590            let i3 = this.chart.renderTo.parentElement;
11591            for (; i3 && "BODY" !== i3.tagName; ) this.eventsToUnbind.push(h(i3, "scroll", () => {
11592              delete this.chartPosition;
11593            })), i3 = i3.parentElement;
11594            this.eventsToUnbind.push(h(t3, "touchstart", this.onContainerTouchStart.bind(this), {
11595              passive: false
11596            }), h(t3, "touchmove", this.onContainerTouchMove.bind(this), {
11597              passive: false
11598            })), S2.unbindDocumentTouchEnd || (S2.unbindDocumentTouchEnd = h(e3, "touchend", this.onDocumentTouchEnd.bind(this), {
11599              passive: false
11600            })), this.setPointerCapture(), h(this.chart, "redraw", this.setPointerCapture.bind(this));
11601          }
11602          setPointerCapture() {
11603            if (!a) return;
11604            let t3 = this.pointerCaptureEventsToUnbind, e3 = this.chart, i3 = e3.container, s2 = y(e3.options.tooltip?.followTouchMove, true) && e3.series.some((t4) => t4.options.findNearestPointBy.indexOf("y") > -1);
11605            !this.hasPointerCapture && s2 ? (t3.push(h(i3, "pointerdown", (t4) => {
11606              t4.target?.hasPointerCapture(t4.pointerId) && t4.target?.releasePointerCapture(t4.pointerId);
11607            }), h(i3, "pointermove", (t4) => {
11608              e3.pointer?.getPointFromEvent(t4)?.onMouseOver(t4);
11609            })), e3.styledMode || d(i3, {
11610              "touch-action": "none"
11611            }), i3.className += " highcharts-no-touch-action", this.hasPointerCapture = true) : this.hasPointerCapture && !s2 && (t3.forEach((t4) => t4()), t3.length = 0, e3.styledMode || d(i3, {
11612              "touch-action": y(e3.options.chart.style?.["touch-action"], "manipulation")
11613            }), i3.className = i3.className.replace(" highcharts-no-touch-action", ""), this.hasPointerCapture = false);
11614          }
11615          setHoverChartIndex(t3) {
11616            let i3 = this.chart, s2 = e2.charts[y(S2.hoverChartIndex, -1)];
11617            if (s2 && s2 !== i3) {
11618              let e3 = {
11619                relatedTarget: i3.container
11620              };
11621              t3 && !t3?.relatedTarget && (t3 = __spreadValues(__spreadValues({}, e3), t3)), s2.pointer?.onContainerMouseLeave(t3 || e3);
11622            }
11623            s2 && s2.mouseIsDown || (S2.hoverChartIndex = i3.index);
11624          }
11625          touch(t3, e3) {
11626            let i3;
11627            let {
11628              chart: s2,
11629              pinchDown: r2 = []
11630            } = this;
11631            this.setHoverChartIndex(), 1 === (t3 = this.normalize(t3)).touches.length ? s2.isInsidePlot(t3.chartX - s2.plotLeft, t3.chartY - s2.plotTop, {
11632              visiblePlotOnly: true
11633            }) && !s2.openMenu ? (e3 && this.runPointActions(t3), "touchmove" === t3.type && (i3 = !!r2[0] && Math.pow(r2[0].chartX - t3.chartX, 2) + Math.pow(r2[0].chartY - t3.chartY, 2) >= 16), y(i3, true) && this.pinch(t3)) : e3 && this.reset() : 2 === t3.touches.length && this.pinch(t3);
11634          }
11635          touchSelect(t3) {
11636            return !!(this.chart.zooming.singleTouch && t3.touches && 1 === t3.touches.length);
11637          }
11638          zoomOption(t3) {
11639            let e3 = this.chart, i3 = e3.inverted, s2 = e3.zooming.type || "", r2, o2;
11640            /touch/.test(t3.type) && (s2 = y(e3.zooming.pinchType, s2)), this.zoomX = r2 = /x/.test(s2), this.zoomY = o2 = /y/.test(s2), this.zoomHor = r2 && !i3 || o2 && i3, this.zoomVert = o2 && !i3 || r2 && i3, this.hasZoom = r2 || o2;
11641          }
11642        }
11643        return (s = S2 || (S2 = {})).compose = function(t3) {
11644          b(n, "Core.Pointer") && h(t3, "beforeRender", function() {
11645            this.pointer = new s(this, this.options);
11646          });
11647        }, S2;
11648      }), i(e, "Core/Legend/LegendSymbol.js", [e["Core/Utilities.js"]], function(t2) {
11649        var e2;
11650        let {
11651          extend: i2,
11652          merge: s,
11653          pick: r
11654        } = t2;
11655        return function(t3) {
11656          function e3(t4, e4, o) {
11657            let n = this.legendItem = this.legendItem || {}, {
11658              chart: a,
11659              options: h
11660            } = this, {
11661              baseline: l = 0,
11662              symbolWidth: d,
11663              symbolHeight: c
11664            } = t4, p = this.symbol || "circle", u11 = c / 2, g = a.renderer, f = n.group, m = l - Math.round((t4.fontMetrics?.b || c) * (o ? 0.4 : 0.3)), x = {}, y, b = h.marker, v = 0;
11665            if (a.styledMode || (x["stroke-width"] = Math.min(h.lineWidth || 0, 24), h.dashStyle ? x.dashstyle = h.dashStyle : "square" === h.linecap || (x["stroke-linecap"] = "round")), n.line = g.path().addClass("highcharts-graph").attr(x).add(f), o && (n.area = g.path().addClass("highcharts-area").add(f)), x["stroke-linecap"] && (v = Math.min(n.line.strokeWidth(), d) / 2), d) {
11666              let t5 = [["M", v, m], ["L", d - v, m]];
11667              n.line.attr({
11668                d: t5
11669              }), n.area?.attr({
11670                d: [...t5, ["L", d - v, l], ["L", v, l]]
11671              });
11672            }
11673            if (b && false !== b.enabled && d) {
11674              let t5 = Math.min(r(b.radius, u11), u11);
11675              0 === p.indexOf("url") && (b = s(b, {
11676                width: c,
11677                height: c
11678              }), t5 = 0), n.symbol = y = g.symbol(p, d / 2 - t5, m - t5, 2 * t5, 2 * t5, i2({
11679                context: "legend"
11680              }, b)).addClass("highcharts-point").add(f), y.isMarker = true;
11681            }
11682          }
11683          t3.areaMarker = function(t4, i3) {
11684            e3.call(this, t4, i3, true);
11685          }, t3.lineMarker = e3, t3.rectangle = function(t4, e4) {
11686            let i3 = e4.legendItem || {}, s2 = t4.options, o = t4.symbolHeight, n = s2.squareSymbol, a = n ? o : t4.symbolWidth;
11687            i3.symbol = this.chart.renderer.rect(n ? (t4.symbolWidth - o) / 2 : 0, t4.baseline - o + 1, a, o, r(t4.options.symbolRadius, o / 2)).addClass("highcharts-point").attr({
11688              zIndex: 3
11689            }).add(i3.group);
11690          };
11691        }(e2 || (e2 = {})), e2;
11692      }), i(e, "Core/Series/SeriesDefaults.js", [], function() {
11693        return {
11694          lineWidth: 2,
11695          allowPointSelect: false,
11696          crisp: true,
11697          showCheckbox: false,
11698          animation: {
11699            duration: 1e3
11700          },
11701          enableMouseTracking: true,
11702          events: {},
11703          marker: {
11704            enabledThreshold: 2,
11705            lineColor: "#ffffff",
11706            lineWidth: 0,
11707            radius: 4,
11708            states: {
11709              normal: {
11710                animation: true
11711              },
11712              hover: {
11713                animation: {
11714                  duration: 150
11715                },
11716                enabled: true,
11717                radiusPlus: 2,
11718                lineWidthPlus: 1
11719              },
11720              select: {
11721                fillColor: "#cccccc",
11722                lineColor: "#000000",
11723                lineWidth: 2
11724              }
11725            }
11726          },
11727          point: {
11728            events: {}
11729          },
11730          dataLabels: {
11731            animation: {},
11732            align: "center",
11733            borderWidth: 0,
11734            defer: true,
11735            formatter: function() {
11736              let {
11737                numberFormatter: t2
11738              } = this.series.chart;
11739              return "number" != typeof this.y ? "" : t2(this.y, -1);
11740            },
11741            padding: 5,
11742            style: {
11743              fontSize: "0.7em",
11744              fontWeight: "bold",
11745              color: "contrast",
11746              textOutline: "1px contrast"
11747            },
11748            verticalAlign: "bottom",
11749            x: 0,
11750            y: 0
11751          },
11752          cropThreshold: 300,
11753          opacity: 1,
11754          pointRange: 0,
11755          softThreshold: true,
11756          states: {
11757            normal: {
11758              animation: true
11759            },
11760            hover: {
11761              animation: {
11762                duration: 150
11763              },
11764              lineWidthPlus: 1,
11765              marker: {},
11766              halo: {
11767                size: 10,
11768                opacity: 0.25
11769              }
11770            },
11771            select: {
11772              animation: {
11773                duration: 0
11774              }
11775            },
11776            inactive: {
11777              animation: {
11778                duration: 150
11779              },
11780              opacity: 0.2
11781            }
11782          },
11783          stickyTracking: true,
11784          turboThreshold: 1e3,
11785          findNearestPointBy: "x"
11786        };
11787      }), i(e, "Core/Series/SeriesRegistry.js", [e["Core/Globals.js"], e["Core/Defaults.js"], e["Core/Series/Point.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
11788        var r;
11789        let {
11790          defaultOptions: o
11791        } = e2, {
11792          extend: n,
11793          extendClass: a,
11794          merge: h
11795        } = s;
11796        return function(e3) {
11797          function s2(t3, s3) {
11798            let r2 = o.plotOptions || {}, n2 = s3.defaultOptions, a2 = s3.prototype;
11799            return a2.type = t3, a2.pointClass || (a2.pointClass = i2), !e3.seriesTypes[t3] && (n2 && (r2[t3] = n2), e3.seriesTypes[t3] = s3, true);
11800          }
11801          e3.seriesTypes = t2.seriesTypes, e3.registerSeriesType = s2, e3.seriesType = function(t3, r2, l, d, c) {
11802            let p = o.plotOptions || {};
11803            if (r2 = r2 || "", p[t3] = h(p[r2], l), delete e3.seriesTypes[t3], s2(t3, a(e3.seriesTypes[r2] || function() {
11804            }, d)), e3.seriesTypes[t3].prototype.type = t3, c) {
11805              class s3 extends i2 {
11806              }
11807              n(s3.prototype, c), e3.seriesTypes[t3].prototype.pointClass = s3;
11808            }
11809            return e3.seriesTypes[t3];
11810          };
11811        }(r || (r = {})), r;
11812      }), i(e, "Core/Series/Series.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Defaults.js"], e["Core/Foundation.js"], e["Core/Globals.js"], e["Core/Legend/LegendSymbol.js"], e["Core/Series/Point.js"], e["Core/Series/SeriesDefaults.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Renderer/SVG/SVGElement.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, r, o, n, a, h, l) {
11813        let {
11814          animObject: d,
11815          setAnimation: c
11816        } = t2, {
11817          defaultOptions: p
11818        } = e2, {
11819          registerEventOptions: u11
11820        } = i2, {
11821          svg: g,
11822          win: f
11823        } = s, {
11824          seriesTypes: m
11825        } = a, {
11826          arrayMax: x,
11827          arrayMin: y,
11828          clamp: b,
11829          correctFloat: v,
11830          crisp: S2,
11831          defined: C,
11832          destroyObjectProperties: k,
11833          diffObjects: M,
11834          erase: w,
11835          error: T2,
11836          extend: A,
11837          find: P,
11838          fireEvent: L,
11839          getClosestDistance: O,
11840          getNestedProperty: D2,
11841          insertItem: E,
11842          isArray: I,
11843          isNumber: j,
11844          isString: B,
11845          merge: R,
11846          objectEach: z,
11847          pick: N,
11848          removeEvent: W,
11849          splat: G,
11850          syncTimeout: H
11851        } = l;
11852        class X {
11853          constructor() {
11854            this.zoneAxis = "y";
11855          }
11856          init(t3, e3) {
11857            let i3;
11858            L(this, "init", {
11859              options: e3
11860            });
11861            let s2 = this, r2 = t3.series;
11862            this.eventsToUnbind = [], s2.chart = t3, s2.options = s2.setOptions(e3);
11863            let o2 = s2.options, n2 = false !== o2.visible;
11864            s2.linkedSeries = [], s2.bindAxes(), A(s2, {
11865              name: o2.name,
11866              state: "",
11867              visible: n2,
11868              selected: true === o2.selected
11869            }), u11(this, o2);
11870            let a2 = o2.events;
11871            (a2 && a2.click || o2.point && o2.point.events && o2.point.events.click || o2.allowPointSelect) && (t3.runTrackerClick = true), s2.getColor(), s2.getSymbol(), s2.parallelArrays.forEach(function(t4) {
11872              s2[t4 + "Data"] || (s2[t4 + "Data"] = []);
11873            }), s2.isCartesian && (t3.hasCartesianSeries = true), r2.length && (i3 = r2[r2.length - 1]), s2._i = N(i3 && i3._i, -1) + 1, s2.opacity = s2.options.opacity, t3.orderItems("series", E(this, r2)), o2.dataSorting && o2.dataSorting.enabled ? s2.setDataSortingOptions() : s2.points || s2.data || s2.setData(o2.data, false), L(this, "afterInit");
11874          }
11875          is(t3) {
11876            return m[t3] && this instanceof m[t3];
11877          }
11878          bindAxes() {
11879            let t3;
11880            let e3 = this, i3 = e3.options, s2 = e3.chart;
11881            L(this, "bindAxes", null, function() {
11882              (e3.axisTypes || []).forEach(function(r2) {
11883                (s2[r2] || []).forEach(function(s3) {
11884                  t3 = s3.options, (N(i3[r2], 0) === s3.index || void 0 !== i3[r2] && i3[r2] === t3.id) && (E(e3, s3.series), e3[r2] = s3, s3.isDirty = true);
11885                }), e3[r2] || e3.optionalAxis === r2 || T2(18, true, s2);
11886              });
11887            }), L(this, "afterBindAxes");
11888          }
11889          updateParallelArrays(t3, e3, i3) {
11890            let s2 = t3.series, r2 = j(e3) ? function(i4) {
11891              let r3 = "y" === i4 && s2.toYData ? s2.toYData(t3) : t3[i4];
11892              s2[i4 + "Data"][e3] = r3;
11893            } : function(t4) {
11894              Array.prototype[e3].apply(s2[t4 + "Data"], i3);
11895            };
11896            s2.parallelArrays.forEach(r2);
11897          }
11898          hasData() {
11899            return this.visible && void 0 !== this.dataMax && void 0 !== this.dataMin || this.visible && this.yData && this.yData.length > 0;
11900          }
11901          hasMarkerChanged(t3, e3) {
11902            let i3 = t3.marker, s2 = e3.marker || {};
11903            return i3 && (s2.enabled && !i3.enabled || s2.symbol !== i3.symbol || s2.height !== i3.height || s2.width !== i3.width);
11904          }
11905          autoIncrement(t3) {
11906            let e3 = this.options, i3 = e3.pointIntervalUnit, s2 = e3.relativeXValue, r2 = this.chart.time, o2 = this.xIncrement, n2, a2;
11907            return (o2 = N(o2, e3.pointStart, 0), this.pointInterval = a2 = N(this.pointInterval, e3.pointInterval, 1), s2 && j(t3) && (a2 *= t3), i3 && (n2 = new r2.Date(o2), "day" === i3 ? r2.set("Date", n2, r2.get("Date", n2) + a2) : "month" === i3 ? r2.set("Month", n2, r2.get("Month", n2) + a2) : "year" === i3 && r2.set("FullYear", n2, r2.get("FullYear", n2) + a2), a2 = n2.getTime() - o2), s2 && j(t3)) ? o2 + a2 : (this.xIncrement = o2 + a2, o2);
11908          }
11909          setDataSortingOptions() {
11910            let t3 = this.options;
11911            A(this, {
11912              requireSorting: false,
11913              sorted: false,
11914              enabledDataSorting: true,
11915              allowDG: false
11916            }), C(t3.pointRange) || (t3.pointRange = 1);
11917          }
11918          setOptions(t3) {
11919            let e3;
11920            let i3 = this.chart, s2 = i3.options.plotOptions, r2 = i3.userOptions || {}, o2 = R(t3), n2 = i3.styledMode, a2 = {
11921              plotOptions: s2,
11922              userOptions: o2
11923            };
11924            L(this, "setOptions", a2);
11925            let h2 = a2.plotOptions[this.type], l2 = r2.plotOptions || {}, d2 = l2.series || {}, c2 = p.plotOptions[this.type] || {}, u12 = l2[this.type] || {};
11926            this.userOptions = a2.userOptions;
11927            let g2 = R(h2, s2.series, u12, o2);
11928            this.tooltipOptions = R(p.tooltip, p.plotOptions.series?.tooltip, c2?.tooltip, i3.userOptions.tooltip, l2.series?.tooltip, u12.tooltip, o2.tooltip), this.stickyTracking = N(o2.stickyTracking, u12.stickyTracking, d2.stickyTracking, !!this.tooltipOptions.shared && !this.noSharedTooltip || g2.stickyTracking), null === h2.marker && delete g2.marker, this.zoneAxis = g2.zoneAxis || "y";
11929            let f2 = this.zones = (g2.zones || []).map((t4) => __spreadValues({}, t4));
11930            return (g2.negativeColor || g2.negativeFillColor) && !g2.zones && (e3 = {
11931              value: g2[this.zoneAxis + "Threshold"] || g2.threshold || 0,
11932              className: "highcharts-negative"
11933            }, n2 || (e3.color = g2.negativeColor, e3.fillColor = g2.negativeFillColor), f2.push(e3)), f2.length && C(f2[f2.length - 1].value) && f2.push(n2 ? {} : {
11934              color: this.color,
11935              fillColor: this.fillColor
11936            }), L(this, "afterSetOptions", {
11937              options: g2
11938            }), g2;
11939          }
11940          getName() {
11941            return N(this.options.name, "Series " + (this.index + 1));
11942          }
11943          getCyclic(t3, e3, i3) {
11944            let s2, r2;
11945            let o2 = this.chart, n2 = `${t3}Index`, a2 = `${t3}Counter`, h2 = i3?.length || o2.options.chart.colorCount;
11946            !e3 && (C(r2 = N("color" === t3 ? this.options.colorIndex : void 0, this[n2])) ? s2 = r2 : (o2.series.length || (o2[a2] = 0), s2 = o2[a2] % h2, o2[a2] += 1), i3 && (e3 = i3[s2])), void 0 !== s2 && (this[n2] = s2), this[t3] = e3;
11947          }
11948          getColor() {
11949            this.chart.styledMode ? this.getCyclic("color") : this.options.colorByPoint ? this.color = "#cccccc" : this.getCyclic("color", this.options.color || p.plotOptions[this.type].color, this.chart.options.colors);
11950          }
11951          getPointsCollection() {
11952            return (this.hasGroupedData ? this.points : this.data) || [];
11953          }
11954          getSymbol() {
11955            let t3 = this.options.marker;
11956            this.getCyclic("symbol", t3.symbol, this.chart.options.symbols);
11957          }
11958          findPointIndex(t3, e3) {
11959            let i3, s2, r2;
11960            let n2 = t3.id, a2 = t3.x, h2 = this.points, l2 = this.options.dataSorting;
11961            if (n2) {
11962              let t4 = this.chart.get(n2);
11963              t4 instanceof o && (i3 = t4);
11964            } else if (this.linkedParent || this.enabledDataSorting || this.options.relativeXValue) {
11965              let e4 = (e5) => !e5.touched && e5.index === t3.index;
11966              if (l2 && l2.matchByName ? e4 = (e5) => !e5.touched && e5.name === t3.name : this.options.relativeXValue && (e4 = (e5) => !e5.touched && e5.options.x === t3.x), !(i3 = P(h2, e4))) return;
11967            }
11968            return i3 && void 0 !== (r2 = i3 && i3.index) && (s2 = true), void 0 === r2 && j(a2) && (r2 = this.xData.indexOf(a2, e3)), -1 !== r2 && void 0 !== r2 && this.cropped && (r2 = r2 >= this.cropStart ? r2 - this.cropStart : r2), !s2 && j(r2) && h2[r2] && h2[r2].touched && (r2 = void 0), r2;
11969          }
11970          updateData(t3, e3) {
11971            let i3 = this.options, s2 = i3.dataSorting, r2 = this.points, o2 = [], n2 = this.requireSorting, a2 = t3.length === r2.length, h2, l2, d2, c2, p2 = true;
11972            if (this.xIncrement = null, t3.forEach(function(t4, e4) {
11973              let l3;
11974              let d3 = C(t4) && this.pointClass.prototype.optionsToObject.call({
11975                series: this
11976              }, t4) || {}, p3 = d3.x;
11977              d3.id || j(p3) ? (-1 === (l3 = this.findPointIndex(d3, c2)) || void 0 === l3 ? o2.push(t4) : r2[l3] && t4 !== i3.data[l3] ? (r2[l3].update(t4, false, null, false), r2[l3].touched = true, n2 && (c2 = l3 + 1)) : r2[l3] && (r2[l3].touched = true), (!a2 || e4 !== l3 || s2 && s2.enabled || this.hasDerivedData) && (h2 = true)) : o2.push(t4);
11978            }, this), h2) for (l2 = r2.length; l2--; ) (d2 = r2[l2]) && !d2.touched && d2.remove && d2.remove(false, e3);
11979            else !a2 || s2 && s2.enabled ? p2 = false : (t3.forEach(function(t4, e4) {
11980              t4 === r2[e4].y || r2[e4].destroyed || r2[e4].update(t4, false, null, false);
11981            }), o2.length = 0);
11982            return r2.forEach(function(t4) {
11983              t4 && (t4.touched = false);
11984            }), !!p2 && (o2.forEach(function(t4) {
11985              this.addPoint(t4, false, null, null, false);
11986            }, this), null === this.xIncrement && this.xData && this.xData.length && (this.xIncrement = x(this.xData), this.autoIncrement()), true);
11987          }
11988          setData(t3, e3 = true, i3, s2) {
11989            let r2 = this, o2 = r2.points, n2 = o2 && o2.length || 0, a2 = r2.options, h2 = r2.chart, l2 = a2.dataSorting, d2 = r2.xAxis, c2 = a2.turboThreshold, p2 = this.xData, u12 = this.yData, g2 = r2.pointArrayMap, f2 = g2 && g2.length, m2 = a2.keys, x2, y2, b2, v2 = 0, S3 = 1, C2;
11990            h2.options.chart.allowMutatingData || (a2.data && delete r2.options.data, r2.userOptions.data && delete r2.userOptions.data, C2 = R(true, t3));
11991            let k2 = (t3 = C2 || t3 || []).length;
11992            if (l2 && l2.enabled && (t3 = this.sortData(t3)), h2.options.chart.allowMutatingData && false !== s2 && k2 && n2 && !r2.cropped && !r2.hasGroupedData && r2.visible && !r2.boosted && (b2 = this.updateData(t3, i3)), !b2) {
11993              r2.xIncrement = null, r2.colorCounter = 0, this.parallelArrays.forEach(function(t4) {
11994                r2[t4 + "Data"].length = 0;
11995              });
11996              let e4 = c2 && k2 > c2;
11997              if (e4) {
11998                let i4 = r2.getFirstValidPoint(t3), s3 = r2.getFirstValidPoint(t3, k2 - 1, -1), o3 = (t4) => !!(I(t4) && (m2 || j(t4[0])));
11999                if (j(i4) && j(s3)) for (x2 = 0; x2 < k2; x2++) p2[x2] = this.autoIncrement(), u12[x2] = t3[x2];
12000                else if (o3(i4) && o3(s3)) {
12001                  if (f2) {
12002                    if (i4.length === f2) for (x2 = 0; x2 < k2; x2++) p2[x2] = this.autoIncrement(), u12[x2] = t3[x2];
12003                    else for (x2 = 0; x2 < k2; x2++) y2 = t3[x2], p2[x2] = y2[0], u12[x2] = y2.slice(1, f2 + 1);
12004                  } else if (m2 && (v2 = m2.indexOf("x"), S3 = m2.indexOf("y"), v2 = v2 >= 0 ? v2 : 0, S3 = S3 >= 0 ? S3 : 1), 1 === i4.length && (S3 = 0), v2 === S3) for (x2 = 0; x2 < k2; x2++) p2[x2] = this.autoIncrement(), u12[x2] = t3[x2][S3];
12005                  else for (x2 = 0; x2 < k2; x2++) y2 = t3[x2], p2[x2] = y2[v2], u12[x2] = y2[S3];
12006                } else e4 = false;
12007              }
12008              if (!e4) for (x2 = 0; x2 < k2; x2++) y2 = {
12009                series: r2
12010              }, r2.pointClass.prototype.applyOptions.apply(y2, [t3[x2]]), r2.updateParallelArrays(y2, x2);
12011              for (u12 && B(u12[0]) && T2(14, true, h2), r2.data = [], r2.options.data = r2.userOptions.data = t3, x2 = n2; x2--; ) o2[x2]?.destroy();
12012              d2 && (d2.minRange = d2.userMinRange), r2.isDirty = h2.isDirtyBox = true, r2.isDirtyData = !!o2, i3 = false;
12013            }
12014            "point" === a2.legendType && (this.processData(), this.generatePoints()), e3 && h2.redraw(i3);
12015          }
12016          sortData(t3) {
12017            let e3 = this, i3 = e3.options.dataSorting.sortKey || "y", s2 = function(t4, e4) {
12018              return C(e4) && t4.pointClass.prototype.optionsToObject.call({
12019                series: t4
12020              }, e4) || {};
12021            };
12022            return t3.forEach(function(i4, r2) {
12023              t3[r2] = s2(e3, i4), t3[r2].index = r2;
12024            }, this), t3.concat().sort((t4, e4) => {
12025              let s3 = D2(i3, t4), r2 = D2(i3, e4);
12026              return r2 < s3 ? -1 : r2 > s3 ? 1 : 0;
12027            }).forEach(function(t4, e4) {
12028              t4.x = e4;
12029            }, this), e3.linkedSeries && e3.linkedSeries.forEach(function(e4) {
12030              let i4 = e4.options, r2 = i4.data;
12031              i4.dataSorting && i4.dataSorting.enabled || !r2 || (r2.forEach(function(i5, o2) {
12032                r2[o2] = s2(e4, i5), t3[o2] && (r2[o2].x = t3[o2].x, r2[o2].index = o2);
12033              }), e4.setData(r2, false));
12034            }), t3;
12035          }
12036          getProcessedData(t3) {
12037            let e3 = this, i3 = e3.xAxis, s2 = e3.options.cropThreshold, r2 = i3?.logarithmic, o2 = e3.isCartesian, n2, a2, h2 = 0, l2, d2, c2, p2 = e3.xData, u12 = e3.yData, g2 = false, f2 = p2.length;
12038            i3 && (d2 = (l2 = i3.getExtremes()).min, c2 = l2.max, g2 = !!(i3.categories && !i3.names.length)), o2 && e3.sorted && !t3 && (!s2 || f2 > s2 || e3.forceCrop) && (p2[f2 - 1] < d2 || p2[0] > c2 ? (p2 = [], u12 = []) : e3.yData && (p2[0] < d2 || p2[f2 - 1] > c2) && (p2 = (n2 = this.cropData(e3.xData, e3.yData, d2, c2)).xData, u12 = n2.yData, h2 = n2.start, a2 = true));
12039            let m2 = O([r2 ? p2.map(r2.log2lin) : p2], () => e3.requireSorting && !g2 && T2(15, false, e3.chart));
12040            return {
12041              xData: p2,
12042              yData: u12,
12043              cropped: a2,
12044              cropStart: h2,
12045              closestPointRange: m2
12046            };
12047          }
12048          processData(t3) {
12049            let e3 = this.xAxis;
12050            if (this.isCartesian && !this.isDirty && !e3.isDirty && !this.yAxis.isDirty && !t3) return false;
12051            let i3 = this.getProcessedData();
12052            this.cropped = i3.cropped, this.cropStart = i3.cropStart, this.processedXData = i3.xData, this.processedYData = i3.yData, this.closestPointRange = this.basePointRange = i3.closestPointRange, L(this, "afterProcessData");
12053          }
12054          cropData(t3, e3, i3, s2) {
12055            let r2 = t3.length, o2, n2, a2 = 0, h2 = r2;
12056            for (o2 = 0; o2 < r2; o2++) if (t3[o2] >= i3) {
12057              a2 = Math.max(0, o2 - 1);
12058              break;
12059            }
12060            for (n2 = o2; n2 < r2; n2++) if (t3[n2] > s2) {
12061              h2 = n2 + 1;
12062              break;
12063            }
12064            return {
12065              xData: t3.slice(a2, h2),
12066              yData: e3.slice(a2, h2),
12067              start: a2,
12068              end: h2
12069            };
12070          }
12071          generatePoints() {
12072            let t3 = this.options, e3 = this.processedData || t3.data, i3 = this.processedXData, s2 = this.processedYData, r2 = this.pointClass, o2 = i3.length, n2 = this.cropStart || 0, a2 = this.hasGroupedData, h2 = t3.keys, l2 = [], d2 = t3.dataGrouping && t3.dataGrouping.groupAll ? n2 : 0, c2, p2, u12, g2, f2 = this.data;
12073            if (!f2 && !a2) {
12074              let t4 = [];
12075              t4.length = e3.length, f2 = this.data = t4;
12076            }
12077            for (h2 && a2 && (this.options.keys = false), g2 = 0; g2 < o2; g2++) p2 = n2 + g2, a2 ? ((u12 = new r2(this, [i3[g2]].concat(G(s2[g2])))).dataGroup = this.groupMap[d2 + g2], u12.dataGroup.options && (u12.options = u12.dataGroup.options, A(u12, u12.dataGroup.options), delete u12.dataLabels)) : (u12 = f2[p2]) || void 0 === e3[p2] || (f2[p2] = u12 = new r2(this, e3[p2], i3[g2])), u12 && (u12.index = a2 ? d2 + g2 : p2, l2[g2] = u12);
12078            if (this.options.keys = h2, f2 && (o2 !== (c2 = f2.length) || a2)) for (g2 = 0; g2 < c2; g2++) g2 !== n2 || a2 || (g2 += o2), f2[g2] && (f2[g2].destroyElements(), f2[g2].plotX = void 0);
12079            this.data = f2, this.points = l2, L(this, "afterGeneratePoints");
12080          }
12081          getXExtremes(t3) {
12082            return {
12083              min: y(t3),
12084              max: x(t3)
12085            };
12086          }
12087          getExtremes(t3, e3) {
12088            let i3 = this.xAxis, s2 = this.yAxis, r2 = [], o2 = this.requireSorting && !this.is("column") ? 1 : 0, n2 = !!s2 && s2.positiveValuesOnly, a2 = e3 || this.getExtremesFromAll || this.options.getExtremesFromAll, {
12089              processedXData: h2,
12090              processedYData: l2
12091            } = this, d2, c2, p2, u12, g2, f2, m2, b2 = 0, v2 = 0, S3 = 0;
12092            if (this.cropped && a2) {
12093              let t4 = this.getProcessedData(true);
12094              h2 = t4.xData, l2 = t4.yData;
12095            }
12096            let C2 = (t3 = t3 || this.stackedYData || l2 || []).length, k2 = h2 || this.xData;
12097            for (i3 && (b2 = (d2 = i3.getExtremes()).min, v2 = d2.max), f2 = 0; f2 < C2; f2++) if (u12 = k2[f2], c2 = (j(g2 = t3[f2]) || I(g2)) && ((j(g2) ? g2 > 0 : g2.length) || !n2), p2 = e3 || this.getExtremesFromAll || this.options.getExtremesFromAll || this.cropped || !i3 || (k2[f2 + o2] || u12) >= b2 && (k2[f2 - o2] || u12) <= v2, c2 && p2) {
12098              if (m2 = g2.length) for (; m2--; ) j(g2[m2]) && (r2[S3++] = g2[m2]);
12099              else r2[S3++] = g2;
12100            }
12101            let M2 = {
12102              activeYData: r2,
12103              dataMin: y(r2),
12104              dataMax: x(r2)
12105            };
12106            return L(this, "afterGetExtremes", {
12107              dataExtremes: M2
12108            }), M2;
12109          }
12110          applyExtremes() {
12111            let t3 = this.getExtremes();
12112            return this.dataMin = t3.dataMin, this.dataMax = t3.dataMax, t3;
12113          }
12114          getFirstValidPoint(t3, e3 = 0, i3 = 1) {
12115            let s2 = t3.length, r2 = e3;
12116            for (; r2 >= 0 && r2 < s2; ) {
12117              if (C(t3[r2])) return t3[r2];
12118              r2 += i3;
12119            }
12120          }
12121          translate() {
12122            this.processedXData || this.processData(), this.generatePoints();
12123            let t3 = this.options, e3 = t3.stacking, i3 = this.xAxis, s2 = i3.categories, r2 = this.enabledDataSorting, o2 = this.yAxis, n2 = this.points, a2 = n2.length, h2 = this.pointPlacementToXValue(), l2 = !!h2, d2 = t3.threshold, c2 = t3.startFromThreshold ? d2 : 0, p2, u12, g2, f2, m2 = Number.MAX_VALUE;
12124            function x2(t4) {
12125              return b(t4, -1e9, 1e9);
12126            }
12127            for (p2 = 0; p2 < a2; p2++) {
12128              let t4;
12129              let a3 = n2[p2], y2 = a3.x, b2, S3, k2 = a3.y, M2 = a3.low, w2 = e3 && o2.stacking?.stacks[(this.negStacks && k2 < (c2 ? 0 : d2) ? "-" : "") + this.stackKey];
12130              u12 = i3.translate(y2, false, false, false, true, h2), a3.plotX = j(u12) ? v(x2(u12)) : void 0, e3 && this.visible && w2 && w2[y2] && (f2 = this.getStackIndicator(f2, y2, this.index), !a3.isNull && f2.key && (S3 = (b2 = w2[y2]).points[f2.key]), b2 && I(S3) && (M2 = S3[0], k2 = S3[1], M2 === c2 && f2.key === w2[y2].base && (M2 = N(j(d2) ? d2 : o2.min)), o2.positiveValuesOnly && C(M2) && M2 <= 0 && (M2 = void 0), a3.total = a3.stackTotal = N(b2.total), a3.percentage = C(a3.y) && b2.total ? a3.y / b2.total * 100 : void 0, a3.stackY = k2, this.irregularWidths || b2.setOffset(this.pointXOffset || 0, this.barW || 0, void 0, void 0, void 0, this.xAxis))), a3.yBottom = C(M2) ? x2(o2.translate(M2, false, true, false, true)) : void 0, this.dataModify && (k2 = this.dataModify.modifyValue(k2, p2)), j(k2) && void 0 !== a3.plotX && (t4 = j(t4 = o2.translate(k2, false, true, false, true)) ? x2(t4) : void 0), a3.plotY = t4, a3.isInside = this.isPointInside(a3), a3.clientX = l2 ? v(i3.translate(y2, false, false, false, true, h2)) : u12, a3.negative = (a3.y || 0) < (d2 || 0), a3.category = N(s2 && s2[a3.x], a3.x), a3.isNull || false === a3.visible || (void 0 !== g2 && (m2 = Math.min(m2, Math.abs(u12 - g2))), g2 = u12), a3.zone = this.zones.length ? a3.getZone() : void 0, !a3.graphic && this.group && r2 && (a3.isNew = true);
12131            }
12132            this.closestPointRangePx = m2, L(this, "afterTranslate");
12133          }
12134          getValidPoints(t3, e3, i3) {
12135            let s2 = this.chart;
12136            return (t3 || this.points || []).filter(function(t4) {
12137              let {
12138                plotX: r2,
12139                plotY: o2
12140              } = t4;
12141              return !!((i3 || !t4.isNull && j(o2)) && (!e3 || s2.isInsidePlot(r2, o2, {
12142                inverted: s2.inverted
12143              }))) && false !== t4.visible;
12144            });
12145          }
12146          getClipBox() {
12147            let {
12148              chart: t3,
12149              xAxis: e3,
12150              yAxis: i3
12151            } = this, {
12152              x: s2,
12153              y: r2,
12154              width: o2,
12155              height: n2
12156            } = R(t3.clipBox);
12157            return e3 && e3.len !== t3.plotSizeX && (o2 = e3.len), i3 && i3.len !== t3.plotSizeY && (n2 = i3.len), t3.inverted && !this.invertible && ([o2, n2] = [n2, o2]), {
12158              x: s2,
12159              y: r2,
12160              width: o2,
12161              height: n2
12162            };
12163          }
12164          getSharedClipKey() {
12165            return this.sharedClipKey = (this.options.xAxis || 0) + "," + (this.options.yAxis || 0), this.sharedClipKey;
12166          }
12167          setClip() {
12168            let {
12169              chart: t3,
12170              group: e3,
12171              markerGroup: i3
12172            } = this, s2 = t3.sharedClips, r2 = t3.renderer, o2 = this.getClipBox(), n2 = this.getSharedClipKey(), a2 = s2[n2];
12173            a2 ? a2.animate(o2) : s2[n2] = a2 = r2.clipRect(o2), e3 && e3.clip(false === this.options.clip ? void 0 : a2), i3 && i3.clip();
12174          }
12175          animate(t3) {
12176            let {
12177              chart: e3,
12178              group: i3,
12179              markerGroup: s2
12180            } = this, r2 = e3.inverted, o2 = d(this.options.animation), n2 = [this.getSharedClipKey(), o2.duration, o2.easing, o2.defer].join(","), a2 = e3.sharedClips[n2], h2 = e3.sharedClips[n2 + "m"];
12181            if (t3 && i3) {
12182              let t4 = this.getClipBox();
12183              if (a2) a2.attr("height", t4.height);
12184              else {
12185                t4.width = 0, r2 && (t4.x = e3.plotHeight), a2 = e3.renderer.clipRect(t4), e3.sharedClips[n2] = a2;
12186                let i4 = {
12187                  x: -99,
12188                  y: -99,
12189                  width: r2 ? e3.plotWidth + 199 : 99,
12190                  height: r2 ? 99 : e3.plotHeight + 199
12191                };
12192                h2 = e3.renderer.clipRect(i4), e3.sharedClips[n2 + "m"] = h2;
12193              }
12194              i3.clip(a2), s2?.clip(h2);
12195            } else if (a2 && !a2.hasClass("highcharts-animating")) {
12196              let t4 = this.getClipBox(), i4 = o2.step;
12197              (s2?.element.childNodes.length || e3.series.length > 1) && (o2.step = function(t5, e4) {
12198                i4 && i4.apply(e4, arguments), "width" === e4.prop && h2?.element && h2.attr(r2 ? "height" : "width", t5 + 99);
12199              }), a2.addClass("highcharts-animating").animate(t4, o2);
12200            }
12201          }
12202          afterAnimate() {
12203            this.setClip(), z(this.chart.sharedClips, (t3, e3, i3) => {
12204              t3 && !this.chart.container.querySelector(`[clip-path="url(#${t3.id})"]`) && (t3.destroy(), delete i3[e3]);
12205            }), this.finishedAnimating = true, L(this, "afterAnimate");
12206          }
12207          drawPoints(t3 = this.points) {
12208            let e3, i3, s2, r2, o2, n2, a2;
12209            let h2 = this.chart, l2 = h2.styledMode, {
12210              colorAxis: d2,
12211              options: c2
12212            } = this, p2 = c2.marker, u12 = this[this.specialGroup || "markerGroup"], g2 = this.xAxis, f2 = N(p2.enabled, !g2 || !!g2.isRadial || null, this.closestPointRangePx >= p2.enabledThreshold * p2.radius);
12213            if (false !== p2.enabled || this._hasPointMarkers) for (e3 = 0; e3 < t3.length; e3++) if (r2 = (s2 = (i3 = t3[e3]).graphic) ? "animate" : "attr", o2 = i3.marker || {}, n2 = !!i3.marker, (f2 && void 0 === o2.enabled || o2.enabled) && !i3.isNull && false !== i3.visible) {
12214              let t4 = N(o2.symbol, this.symbol, "rect");
12215              a2 = this.markerAttribs(i3, i3.selected && "select"), this.enabledDataSorting && (i3.startXPos = g2.reversed ? -(a2.width || 0) : g2.width);
12216              let e4 = false !== i3.isInside;
12217              if (!s2 && e4 && ((a2.width || 0) > 0 || i3.hasImage) && (i3.graphic = s2 = h2.renderer.symbol(t4, a2.x, a2.y, a2.width, a2.height, n2 ? o2 : p2).add(u12), this.enabledDataSorting && h2.hasRendered && (s2.attr({
12218                x: i3.startXPos
12219              }), r2 = "animate")), s2 && "animate" === r2 && s2[e4 ? "show" : "hide"](e4).animate(a2), s2) {
12220                let t5 = this.pointAttribs(i3, l2 || !i3.selected ? void 0 : "select");
12221                l2 ? d2 && s2.css({
12222                  fill: t5.fill
12223                }) : s2[r2](t5);
12224              }
12225              s2 && s2.addClass(i3.getClassName(), true);
12226            } else s2 && (i3.graphic = s2.destroy());
12227          }
12228          markerAttribs(t3, e3) {
12229            let i3 = this.options, s2 = i3.marker, r2 = t3.marker || {}, o2 = r2.symbol || s2.symbol, n2 = {}, a2, h2, l2 = N(r2.radius, s2 && s2.radius);
12230            e3 && (a2 = s2.states[e3], l2 = N((h2 = r2.states && r2.states[e3]) && h2.radius, a2 && a2.radius, l2 && l2 + (a2 && a2.radiusPlus || 0))), t3.hasImage = o2 && 0 === o2.indexOf("url"), t3.hasImage && (l2 = 0);
12231            let d2 = t3.pos();
12232            return j(l2) && d2 && (i3.crisp && (d2[0] = S2(d2[0], t3.hasImage ? 0 : "rect" === o2 ? s2?.lineWidth || 0 : 1)), n2.x = d2[0] - l2, n2.y = d2[1] - l2), l2 && (n2.width = n2.height = 2 * l2), n2;
12233          }
12234          pointAttribs(t3, e3) {
12235            let i3 = this.options.marker, s2 = t3 && t3.options, r2 = s2 && s2.marker || {}, o2 = s2 && s2.color, n2 = t3 && t3.color, a2 = t3 && t3.zone && t3.zone.color, h2, l2, d2 = this.color, c2, p2, u12 = N(r2.lineWidth, i3.lineWidth), g2 = 1;
12236            return d2 = o2 || a2 || n2 || d2, c2 = r2.fillColor || i3.fillColor || d2, p2 = r2.lineColor || i3.lineColor || d2, e3 = e3 || "normal", h2 = i3.states[e3] || {}, u12 = N((l2 = r2.states && r2.states[e3] || {}).lineWidth, h2.lineWidth, u12 + N(l2.lineWidthPlus, h2.lineWidthPlus, 0)), c2 = l2.fillColor || h2.fillColor || c2, {
12237              stroke: p2 = l2.lineColor || h2.lineColor || p2,
12238              "stroke-width": u12,
12239              fill: c2,
12240              opacity: g2 = N(l2.opacity, h2.opacity, g2)
12241            };
12242          }
12243          destroy(t3) {
12244            let e3, i3, s2;
12245            let r2 = this, o2 = r2.chart, n2 = /AppleWebKit\/533/.test(f.navigator.userAgent), a2 = r2.data || [];
12246            for (L(r2, "destroy", {
12247              keepEventsForUpdate: t3
12248            }), this.removeEvents(t3), (r2.axisTypes || []).forEach(function(t4) {
12249              (s2 = r2[t4]) && s2.series && (w(s2.series, r2), s2.isDirty = s2.forceRedraw = true);
12250            }), r2.legendItem && r2.chart.legend.destroyItem(r2), e3 = a2.length; e3--; ) (i3 = a2[e3]) && i3.destroy && i3.destroy();
12251            for (let t4 of r2.zones) k(t4, void 0, true);
12252            l.clearTimeout(r2.animationTimeout), z(r2, function(t4, e4) {
12253              t4 instanceof h && !t4.survive && t4[n2 && "group" === e4 ? "hide" : "destroy"]();
12254            }), o2.hoverSeries === r2 && (o2.hoverSeries = void 0), w(o2.series, r2), o2.orderItems("series"), z(r2, function(e4, i4) {
12255              t3 && "hcEvents" === i4 || delete r2[i4];
12256            });
12257          }
12258          applyZones() {
12259            let {
12260              area: t3,
12261              chart: e3,
12262              graph: i3,
12263              zones: s2,
12264              points: r2,
12265              xAxis: o2,
12266              yAxis: n2,
12267              zoneAxis: a2
12268            } = this, {
12269              inverted: h2,
12270              renderer: l2
12271            } = e3, d2 = this[`${a2}Axis`], {
12272              isXAxis: c2,
12273              len: p2 = 0
12274            } = d2 || {}, u12 = (i3?.strokeWidth() || 0) / 2 + 1, g2 = (t4, e4 = 0, i4 = 0) => {
12275              h2 && (i4 = p2 - i4);
12276              let {
12277                translated: s3 = 0,
12278                lineClip: r3
12279              } = t4, o3 = i4 - s3;
12280              r3?.push(["L", e4, Math.abs(o3) < u12 ? i4 - u12 * (o3 <= 0 ? -1 : 1) : s3]);
12281            };
12282            if (s2.length && (i3 || t3) && d2 && j(d2.min)) {
12283              let e4 = d2.getExtremes().max, u13 = (t4) => {
12284                t4.forEach((e5, i4) => {
12285                  ("M" === e5[0] || "L" === e5[0]) && (t4[i4] = [e5[0], c2 ? p2 - e5[1] : e5[1], c2 ? e5[2] : p2 - e5[2]]);
12286                });
12287              };
12288              if (s2.forEach((t4) => {
12289                t4.lineClip = [], t4.translated = b(d2.toPixels(N(t4.value, e4), true) || 0, 0, p2);
12290              }), i3 && !this.showLine && i3.hide(), t3 && t3.hide(), "y" === a2 && r2.length < o2.len) for (let t4 of r2) {
12291                let {
12292                  plotX: e5,
12293                  plotY: i4,
12294                  zone: r3
12295                } = t4, o3 = r3 && s2[s2.indexOf(r3) - 1];
12296                r3 && g2(r3, e5, i4), o3 && g2(o3, e5, i4);
12297              }
12298              let f2 = [], m2 = d2.toPixels(d2.getExtremes().min, true);
12299              s2.forEach((e5) => {
12300                let s3 = e5.lineClip || [], r3 = Math.round(e5.translated || 0);
12301                o2.reversed && s3.reverse();
12302                let {
12303                  clip: a3,
12304                  simpleClip: d3
12305                } = e5, p3 = 0, g3 = 0, x2 = o2.len, y2 = n2.len;
12306                c2 ? (p3 = r3, x2 = m2) : (g3 = r3, y2 = m2);
12307                let b2 = [["M", p3, g3], ["L", x2, g3], ["L", x2, y2], ["L", p3, y2], ["Z"]], v2 = [b2[0], ...s3, b2[1], b2[2], ...f2, b2[3], b2[4]];
12308                f2 = s3.reverse(), m2 = r3, h2 && (u13(v2), t3 && u13(b2)), a3 ? (a3.animate({
12309                  d: v2
12310                }), d3?.animate({
12311                  d: b2
12312                })) : (a3 = e5.clip = l2.path(v2), t3 && (d3 = e5.simpleClip = l2.path(b2))), i3 && e5.graph?.clip(a3), t3 && e5.area?.clip(d3);
12313              });
12314            } else this.visible && (i3 && i3.show(), t3 && t3.show());
12315          }
12316          plotGroup(t3, e3, i3, s2, r2) {
12317            let o2 = this[t3], n2 = !o2, a2 = {
12318              visibility: i3,
12319              zIndex: s2 || 0.1
12320            };
12321            return C(this.opacity) && !this.chart.styledMode && "inactive" !== this.state && (a2.opacity = this.opacity), o2 || (this[t3] = o2 = this.chart.renderer.g().add(r2)), o2.addClass("highcharts-" + e3 + " highcharts-series-" + this.index + " highcharts-" + this.type + "-series " + (C(this.colorIndex) ? "highcharts-color-" + this.colorIndex + " " : "") + (this.options.className || "") + (o2.hasClass("highcharts-tracker") ? " highcharts-tracker" : ""), true), o2.attr(a2)[n2 ? "attr" : "animate"](this.getPlotBox(e3)), o2;
12322          }
12323          getPlotBox(t3) {
12324            let e3 = this.xAxis, i3 = this.yAxis, s2 = this.chart, r2 = s2.inverted && !s2.polar && e3 && this.invertible && "series" === t3;
12325            return s2.inverted && (e3 = i3, i3 = this.xAxis), {
12326              translateX: e3 ? e3.left : s2.plotLeft,
12327              translateY: i3 ? i3.top : s2.plotTop,
12328              rotation: r2 ? 90 : 0,
12329              rotationOriginX: r2 ? (e3.len - i3.len) / 2 : 0,
12330              rotationOriginY: r2 ? (e3.len + i3.len) / 2 : 0,
12331              scaleX: r2 ? -1 : 1,
12332              scaleY: 1
12333            };
12334          }
12335          removeEvents(t3) {
12336            let {
12337              eventsToUnbind: e3
12338            } = this;
12339            t3 || W(this), e3.length && (e3.forEach((t4) => {
12340              t4();
12341            }), e3.length = 0);
12342          }
12343          render() {
12344            let t3 = this, {
12345              chart: e3,
12346              options: i3,
12347              hasRendered: s2
12348            } = t3, r2 = d(i3.animation), o2 = t3.visible ? "inherit" : "hidden", n2 = i3.zIndex, a2 = e3.seriesGroup, h2 = t3.finishedAnimating ? 0 : r2.duration;
12349            L(this, "render"), t3.plotGroup("group", "series", o2, n2, a2), t3.markerGroup = t3.plotGroup("markerGroup", "markers", o2, n2, a2), false !== i3.clip && t3.setClip(), h2 && t3.animate?.(true), t3.drawGraph && (t3.drawGraph(), t3.applyZones()), t3.visible && t3.drawPoints(), t3.drawDataLabels?.(), t3.redrawPoints?.(), i3.enableMouseTracking && t3.drawTracker?.(), h2 && t3.animate?.(), s2 || (h2 && r2.defer && (h2 += r2.defer), t3.animationTimeout = H(() => {
12350              t3.afterAnimate();
12351            }, h2 || 0)), t3.isDirty = false, t3.hasRendered = true, L(t3, "afterRender");
12352          }
12353          redraw() {
12354            let t3 = this.isDirty || this.isDirtyData;
12355            this.translate(), this.render(), t3 && delete this.kdTree;
12356          }
12357          reserveSpace() {
12358            return this.visible || !this.chart.options.chart.ignoreHiddenSeries;
12359          }
12360          searchPoint(t3, e3) {
12361            let {
12362              xAxis: i3,
12363              yAxis: s2
12364            } = this, r2 = this.chart.inverted;
12365            return this.searchKDTree({
12366              clientX: r2 ? i3.len - t3.chartY + i3.pos : t3.chartX - i3.pos,
12367              plotY: r2 ? s2.len - t3.chartX + s2.pos : t3.chartY - s2.pos
12368            }, e3, t3);
12369          }
12370          buildKDTree(t3) {
12371            this.buildingKdTree = true;
12372            let e3 = this, i3 = e3.options.findNearestPointBy.indexOf("y") > -1 ? 2 : 1;
12373            delete e3.kdTree, H(function() {
12374              e3.kdTree = function t4(i4, s2, r2) {
12375                let o2, n2;
12376                let a2 = i4?.length;
12377                if (a2) return o2 = e3.kdAxisArray[s2 % r2], i4.sort((t5, e4) => (t5[o2] || 0) - (e4[o2] || 0)), {
12378                  point: i4[n2 = Math.floor(a2 / 2)],
12379                  left: t4(i4.slice(0, n2), s2 + 1, r2),
12380                  right: t4(i4.slice(n2 + 1), s2 + 1, r2)
12381                };
12382              }(e3.getValidPoints(void 0, !e3.directTouch), i3, i3), e3.buildingKdTree = false;
12383            }, e3.options.kdNow || t3?.type === "touchstart" ? 0 : 1);
12384          }
12385          searchKDTree(t3, e3, i3) {
12386            let s2 = this, [r2, o2] = this.kdAxisArray, n2 = e3 ? "distX" : "dist", a2 = (s2.options.findNearestPointBy || "").indexOf("y") > -1 ? 2 : 1, h2 = !!s2.isBubble;
12387            if (this.kdTree || this.buildingKdTree || this.buildKDTree(i3), this.kdTree) return function t4(e4, i4, a3, l2) {
12388              let d2 = i4.point, c2 = s2.kdAxisArray[a3 % l2], p2, u12, g2 = d2;
12389              !function(t5, e5) {
12390                let i5 = t5[r2], s3 = e5[r2], n3 = C(i5) && C(s3) ? i5 - s3 : null, a4 = t5[o2], l3 = e5[o2], d3 = C(a4) && C(l3) ? a4 - l3 : 0, c3 = h2 && e5.marker?.radius || 0;
12391                e5.dist = Math.sqrt((n3 && n3 * n3 || 0) + d3 * d3) - c3, e5.distX = C(n3) ? Math.abs(n3) - c3 : Number.MAX_VALUE;
12392              }(e4, d2);
12393              let f2 = (e4[c2] || 0) - (d2[c2] || 0) + (h2 && d2.marker?.radius || 0), m2 = f2 < 0 ? "left" : "right", x2 = f2 < 0 ? "right" : "left";
12394              return i4[m2] && (g2 = (p2 = t4(e4, i4[m2], a3 + 1, l2))[n2] < g2[n2] ? p2 : d2), i4[x2] && Math.sqrt(f2 * f2) < g2[n2] && (g2 = (u12 = t4(e4, i4[x2], a3 + 1, l2))[n2] < g2[n2] ? u12 : g2), g2;
12395            }(t3, this.kdTree, a2, a2);
12396          }
12397          pointPlacementToXValue() {
12398            let {
12399              options: t3,
12400              xAxis: e3
12401            } = this, i3 = t3.pointPlacement;
12402            return "between" === i3 && (i3 = e3.reversed ? -0.5 : 0.5), j(i3) ? i3 * (t3.pointRange || e3.pointRange) : 0;
12403          }
12404          isPointInside(t3) {
12405            let {
12406              chart: e3,
12407              xAxis: i3,
12408              yAxis: s2
12409            } = this, {
12410              plotX: r2 = -1,
12411              plotY: o2 = -1
12412            } = t3;
12413            return o2 >= 0 && o2 <= (s2 ? s2.len : e3.plotHeight) && r2 >= 0 && r2 <= (i3 ? i3.len : e3.plotWidth);
12414          }
12415          drawTracker() {
12416            let t3 = this, e3 = t3.options, i3 = e3.trackByArea, s2 = [].concat((i3 ? t3.areaPath : t3.graphPath) || []), r2 = t3.chart, o2 = r2.pointer, n2 = r2.renderer, a2 = r2.options.tooltip?.snap || 0, h2 = () => {
12417              e3.enableMouseTracking && r2.hoverSeries !== t3 && t3.onMouseOver();
12418            }, l2 = "rgba(192,192,192," + (g ? 1e-4 : 2e-3) + ")", d2 = t3.tracker;
12419            d2 ? d2.attr({
12420              d: s2
12421            }) : t3.graph && (t3.tracker = d2 = n2.path(s2).attr({
12422              visibility: t3.visible ? "inherit" : "hidden",
12423              zIndex: 2
12424            }).addClass(i3 ? "highcharts-tracker-area" : "highcharts-tracker-line").add(t3.group), r2.styledMode || d2.attr({
12425              "stroke-linecap": "round",
12426              "stroke-linejoin": "round",
12427              stroke: l2,
12428              fill: i3 ? l2 : "none",
12429              "stroke-width": t3.graph.strokeWidth() + (i3 ? 0 : 2 * a2)
12430            }), [t3.tracker, t3.markerGroup, t3.dataLabelsGroup].forEach((t4) => {
12431              t4 && (t4.addClass("highcharts-tracker").on("mouseover", h2).on("mouseout", (t5) => {
12432                o2?.onTrackerMouseOut(t5);
12433              }), e3.cursor && !r2.styledMode && t4.css({
12434                cursor: e3.cursor
12435              }), t4.on("touchstart", h2));
12436            })), L(this, "afterDrawTracker");
12437          }
12438          addPoint(t3, e3, i3, s2, r2) {
12439            let o2, n2;
12440            let a2 = this.options, h2 = this.data, l2 = this.chart, d2 = this.xAxis, c2 = d2 && d2.hasNames && d2.names, p2 = a2.data, u12 = this.xData;
12441            e3 = N(e3, true);
12442            let g2 = {
12443              series: this
12444            };
12445            this.pointClass.prototype.applyOptions.apply(g2, [t3]);
12446            let f2 = g2.x;
12447            if (n2 = u12.length, this.requireSorting && f2 < u12[n2 - 1]) for (o2 = true; n2 && u12[n2 - 1] > f2; ) n2--;
12448            this.updateParallelArrays(g2, "splice", [n2, 0, 0]), this.updateParallelArrays(g2, n2), c2 && g2.name && (c2[f2] = g2.name), p2.splice(n2, 0, t3), (o2 || this.processedData) && (this.data.splice(n2, 0, null), this.processData()), "point" === a2.legendType && this.generatePoints(), i3 && (h2[0] && h2[0].remove ? h2[0].remove(false) : (h2.shift(), this.updateParallelArrays(g2, "shift"), p2.shift())), false !== r2 && L(this, "addPoint", {
12449              point: g2
12450            }), this.isDirty = true, this.isDirtyData = true, e3 && l2.redraw(s2);
12451          }
12452          removePoint(t3, e3, i3) {
12453            let s2 = this, r2 = s2.data, o2 = r2[t3], n2 = s2.points, a2 = s2.chart, h2 = function() {
12454              n2 && n2.length === r2.length && n2.splice(t3, 1), r2.splice(t3, 1), s2.options.data.splice(t3, 1), s2.updateParallelArrays(o2 || {
12455                series: s2
12456              }, "splice", [t3, 1]), o2 && o2.destroy(), s2.isDirty = true, s2.isDirtyData = true, e3 && a2.redraw();
12457            };
12458            c(i3, a2), e3 = N(e3, true), o2 ? o2.firePointEvent("remove", null, h2) : h2();
12459          }
12460          remove(t3, e3, i3, s2) {
12461            let r2 = this, o2 = r2.chart;
12462            function n2() {
12463              r2.destroy(s2), o2.isDirtyLegend = o2.isDirtyBox = true, o2.linkSeries(s2), N(t3, true) && o2.redraw(e3);
12464            }
12465            false !== i3 ? L(r2, "remove", null, n2) : n2();
12466          }
12467          update(t3, e3) {
12468            L(this, "update", {
12469              options: t3 = M(t3, this.userOptions)
12470            });
12471            let i3 = this, s2 = i3.chart, r2 = i3.userOptions, o2 = i3.initialType || i3.type, n2 = s2.options.plotOptions, a2 = m[o2].prototype, h2 = i3.finishedAnimating && {
12472              animation: false
12473            }, l2 = {}, d2, c2, p2 = ["colorIndex", "eventOptions", "navigatorSeries", "symbolIndex", "baseSeries"], u12 = t3.type || r2.type || s2.options.chart.type, g2 = !(this.hasDerivedData || u12 && u12 !== this.type || void 0 !== t3.pointStart || void 0 !== t3.pointInterval || void 0 !== t3.relativeXValue || t3.joinBy || t3.mapData || ["dataGrouping", "pointStart", "pointInterval", "pointIntervalUnit", "keys"].some((t4) => i3.hasOptionChanged(t4)));
12474            u12 = u12 || o2, g2 && (p2.push("data", "isDirtyData", "isDirtyCanvas", "points", "processedData", "processedXData", "processedYData", "xIncrement", "cropped", "_hasPointMarkers", "hasDataLabels", "nodes", "layout", "level", "mapMap", "mapData", "minY", "maxY", "minX", "maxX", "transformGroups"), false !== t3.visible && p2.push("area", "graph"), i3.parallelArrays.forEach(function(t4) {
12475              p2.push(t4 + "Data");
12476            }), t3.data && (t3.dataSorting && A(i3.options.dataSorting, t3.dataSorting), this.setData(t3.data, false))), t3 = R(r2, {
12477              index: void 0 === r2.index ? i3.index : r2.index,
12478              pointStart: n2?.series?.pointStart ?? r2.pointStart ?? i3.xData?.[0]
12479            }, !g2 && {
12480              data: i3.options.data
12481            }, t3, h2), g2 && t3.data && (t3.data = i3.options.data), (p2 = ["group", "markerGroup", "dataLabelsGroup", "transformGroup"].concat(p2)).forEach(function(t4) {
12482              p2[t4] = i3[t4], delete i3[t4];
12483            });
12484            let f2 = false;
12485            if (m[u12]) {
12486              if (f2 = u12 !== i3.type, i3.remove(false, false, false, true), f2) {
12487                if (s2.propFromSeries(), Object.setPrototypeOf) Object.setPrototypeOf(i3, m[u12].prototype);
12488                else {
12489                  let t4 = Object.hasOwnProperty.call(i3, "hcEvents") && i3.hcEvents;
12490                  for (c2 in a2) i3[c2] = void 0;
12491                  A(i3, m[u12].prototype), t4 ? i3.hcEvents = t4 : delete i3.hcEvents;
12492                }
12493              }
12494            } else T2(17, true, s2, {
12495              missingModuleFor: u12
12496            });
12497            if (p2.forEach(function(t4) {
12498              i3[t4] = p2[t4];
12499            }), i3.init(s2, t3), g2 && this.points) for (let t4 of (false === (d2 = i3.options).visible ? (l2.graphic = 1, l2.dataLabel = 1) : (this.hasMarkerChanged(d2, r2) && (l2.graphic = 1), i3.hasDataLabels?.() || (l2.dataLabel = 1)), this.points)) t4 && t4.series && (t4.resolveColor(), Object.keys(l2).length && t4.destroyElements(l2), false === d2.showInLegend && t4.legendItem && s2.legend.destroyItem(t4));
12500            i3.initialType = o2, s2.linkSeries(), s2.setSortedData(), f2 && i3.linkedSeries.length && (i3.isDirtyData = true), L(this, "afterUpdate"), N(e3, true) && s2.redraw(!!g2 && void 0);
12501          }
12502          setName(t3) {
12503            this.name = this.options.name = this.userOptions.name = t3, this.chart.isDirtyLegend = true;
12504          }
12505          hasOptionChanged(t3) {
12506            let e3 = this.chart, i3 = this.options[t3], s2 = e3.options.plotOptions, r2 = this.userOptions[t3], o2 = N(s2?.[this.type]?.[t3], s2?.series?.[t3]);
12507            return r2 && !C(o2) ? i3 !== r2 : i3 !== N(o2, i3);
12508          }
12509          onMouseOver() {
12510            let t3 = this.chart, e3 = t3.hoverSeries, i3 = t3.pointer;
12511            i3?.setHoverChartIndex(), e3 && e3 !== this && e3.onMouseOut(), this.options.events.mouseOver && L(this, "mouseOver"), this.setState("hover"), t3.hoverSeries = this;
12512          }
12513          onMouseOut() {
12514            let t3 = this.options, e3 = this.chart, i3 = e3.tooltip, s2 = e3.hoverPoint;
12515            e3.hoverSeries = null, s2 && s2.onMouseOut(), this && t3.events.mouseOut && L(this, "mouseOut"), i3 && !this.stickyTracking && (!i3.shared || this.noSharedTooltip) && i3.hide(), e3.series.forEach(function(t4) {
12516              t4.setState("", true);
12517            });
12518          }
12519          setState(t3, e3) {
12520            let i3 = this, s2 = i3.options, r2 = i3.graph, o2 = s2.inactiveOtherPoints, n2 = s2.states, a2 = N(n2[t3 || "normal"] && n2[t3 || "normal"].animation, i3.chart.options.chart.animation), h2 = s2.lineWidth, l2 = s2.opacity;
12521            if (t3 = t3 || "", i3.state !== t3 && ([i3.group, i3.markerGroup, i3.dataLabelsGroup].forEach(function(e4) {
12522              e4 && (i3.state && e4.removeClass("highcharts-series-" + i3.state), t3 && e4.addClass("highcharts-series-" + t3));
12523            }), i3.state = t3, !i3.chart.styledMode)) {
12524              if (n2[t3] && false === n2[t3].enabled) return;
12525              if (t3 && (h2 = n2[t3].lineWidth || h2 + (n2[t3].lineWidthPlus || 0), l2 = N(n2[t3].opacity, l2)), r2 && !r2.dashstyle && j(h2)) for (let t4 of [r2, ...this.zones.map((t5) => t5.graph)]) t4?.animate({
12526                "stroke-width": h2
12527              }, a2);
12528              o2 || [i3.group, i3.markerGroup, i3.dataLabelsGroup, i3.labelBySeries].forEach(function(t4) {
12529                t4 && t4.animate({
12530                  opacity: l2
12531                }, a2);
12532              });
12533            }
12534            e3 && o2 && i3.points && i3.setAllPointsToState(t3 || void 0);
12535          }
12536          setAllPointsToState(t3) {
12537            this.points.forEach(function(e3) {
12538              e3.setState && e3.setState(t3);
12539            });
12540          }
12541          setVisible(t3, e3) {
12542            let i3 = this, s2 = i3.chart, r2 = s2.options.chart.ignoreHiddenSeries, o2 = i3.visible;
12543            i3.visible = t3 = i3.options.visible = i3.userOptions.visible = void 0 === t3 ? !o2 : t3;
12544            let n2 = t3 ? "show" : "hide";
12545            ["group", "dataLabelsGroup", "markerGroup", "tracker", "tt"].forEach((t4) => {
12546              i3[t4]?.[n2]();
12547            }), (s2.hoverSeries === i3 || s2.hoverPoint?.series === i3) && i3.onMouseOut(), i3.legendItem && s2.legend.colorizeItem(i3, t3), i3.isDirty = true, i3.options.stacking && s2.series.forEach((t4) => {
12548              t4.options.stacking && t4.visible && (t4.isDirty = true);
12549            }), i3.linkedSeries.forEach((e4) => {
12550              e4.setVisible(t3, false);
12551            }), r2 && (s2.isDirtyBox = true), L(i3, n2), false !== e3 && s2.redraw();
12552          }
12553          show() {
12554            this.setVisible(true);
12555          }
12556          hide() {
12557            this.setVisible(false);
12558          }
12559          select(t3) {
12560            this.selected = t3 = this.options.selected = void 0 === t3 ? !this.selected : t3, this.checkbox && (this.checkbox.checked = t3), L(this, t3 ? "select" : "unselect");
12561          }
12562          shouldShowTooltip(t3, e3, i3 = {}) {
12563            return i3.series = this, i3.visiblePlotOnly = true, this.chart.isInsidePlot(t3, e3, i3);
12564          }
12565          drawLegendSymbol(t3, e3) {
12566            r[this.options.legendSymbol || "rectangle"]?.call(this, t3, e3);
12567          }
12568        }
12569        return X.defaultOptions = n, X.types = a.seriesTypes, X.registerType = a.registerSeriesType, A(X.prototype, {
12570          axisTypes: ["xAxis", "yAxis"],
12571          coll: "series",
12572          colorCounter: 0,
12573          directTouch: false,
12574          invertible: true,
12575          isCartesian: true,
12576          kdAxisArray: ["clientX", "plotY"],
12577          parallelArrays: ["x", "y"],
12578          pointClass: o,
12579          requireSorting: true,
12580          sorted: true
12581        }), a.series = X, X;
12582      }), i(e, "Core/Legend/Legend.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Foundation.js"], e["Core/Globals.js"], e["Core/Series/Series.js"], e["Core/Series/Point.js"], e["Core/Renderer/RendererUtilities.js"], e["Core/Templating.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, r, o, n, a) {
12583        var h;
12584        let {
12585          animObject: l,
12586          setAnimation: d
12587        } = t2, {
12588          registerEventOptions: c
12589        } = e2, {
12590          composed: p,
12591          marginNames: u11
12592        } = i2, {
12593          distribute: g
12594        } = o, {
12595          format: f
12596        } = n, {
12597          addEvent: m,
12598          createElement: x,
12599          css: y,
12600          defined: b,
12601          discardElement: v,
12602          find: S2,
12603          fireEvent: C,
12604          isNumber: k,
12605          merge: M,
12606          pick: w,
12607          pushUnique: T2,
12608          relativeLength: A,
12609          stableSort: P,
12610          syncTimeout: L
12611        } = a;
12612        class O {
12613          constructor(t3, e3) {
12614            this.allItems = [], this.initialItemY = 0, this.itemHeight = 0, this.itemMarginBottom = 0, this.itemMarginTop = 0, this.itemX = 0, this.itemY = 0, this.lastItemY = 0, this.lastLineHeight = 0, this.legendHeight = 0, this.legendWidth = 0, this.maxItemWidth = 0, this.maxLegendWidth = 0, this.offsetWidth = 0, this.padding = 0, this.pages = [], this.symbolHeight = 0, this.symbolWidth = 0, this.titleHeight = 0, this.totalItemWidth = 0, this.widthOption = 0, this.chart = t3, this.setOptions(e3), e3.enabled && (this.render(), c(this, e3), m(this.chart, "endResize", function() {
12615              this.legend.positionCheckboxes();
12616            })), m(this.chart, "render", () => {
12617              this.options.enabled && this.proximate && (this.proximatePositions(), this.positionItems());
12618            });
12619          }
12620          setOptions(t3) {
12621            let e3 = w(t3.padding, 8);
12622            this.options = t3, this.chart.styledMode || (this.itemStyle = t3.itemStyle, this.itemHiddenStyle = M(this.itemStyle, t3.itemHiddenStyle)), this.itemMarginTop = t3.itemMarginTop, this.itemMarginBottom = t3.itemMarginBottom, this.padding = e3, this.initialItemY = e3 - 5, this.symbolWidth = w(t3.symbolWidth, 16), this.pages = [], this.proximate = "proximate" === t3.layout && !this.chart.inverted, this.baseline = void 0;
12623          }
12624          update(t3, e3) {
12625            let i3 = this.chart;
12626            this.setOptions(M(true, this.options, t3)), "events" in this.options && c(this, this.options), this.destroy(), i3.isDirtyLegend = i3.isDirtyBox = true, w(e3, true) && i3.redraw(), C(this, "afterUpdate", {
12627              redraw: e3
12628            });
12629          }
12630          colorizeItem(t3, e3) {
12631            let {
12632              area: i3,
12633              group: s2,
12634              label: r2,
12635              line: o2,
12636              symbol: n2
12637            } = t3.legendItem || {};
12638            if (s2?.[e3 ? "removeClass" : "addClass"]("highcharts-legend-item-hidden"), !this.chart.styledMode) {
12639              let {
12640                itemHiddenStyle: s3 = {}
12641              } = this, a2 = s3.color, {
12642                fillColor: h2,
12643                fillOpacity: l2,
12644                lineColor: d2,
12645                marker: c2
12646              } = t3.options, p2 = (t4) => (!e3 && (t4.fill && (t4.fill = a2), t4.stroke && (t4.stroke = a2)), t4);
12647              r2?.css(M(e3 ? this.itemStyle : s3)), o2?.attr(p2({
12648                stroke: d2 || t3.color
12649              })), n2 && n2.attr(p2(c2 && n2.isMarker ? t3.pointAttribs() : {
12650                fill: t3.color
12651              })), i3?.attr(p2({
12652                fill: h2 || t3.color,
12653                "fill-opacity": h2 ? 1 : l2 ?? 0.75
12654              }));
12655            }
12656            C(this, "afterColorizeItem", {
12657              item: t3,
12658              visible: e3
12659            });
12660          }
12661          positionItems() {
12662            this.allItems.forEach(this.positionItem, this), this.chart.isResizing || this.positionCheckboxes();
12663          }
12664          positionItem(t3) {
12665            let {
12666              group: e3,
12667              x: i3 = 0,
12668              y: s2 = 0
12669            } = t3.legendItem || {}, r2 = this.options, o2 = r2.symbolPadding, n2 = !r2.rtl, a2 = t3.checkbox;
12670            if (e3 && e3.element) {
12671              let r3 = {
12672                translateX: n2 ? i3 : this.legendWidth - i3 - 2 * o2 - 4,
12673                translateY: s2
12674              };
12675              e3[b(e3.translateY) ? "animate" : "attr"](r3, void 0, () => {
12676                C(this, "afterPositionItem", {
12677                  item: t3
12678                });
12679              });
12680            }
12681            a2 && (a2.x = i3, a2.y = s2);
12682          }
12683          destroyItem(t3) {
12684            let e3 = t3.checkbox, i3 = t3.legendItem || {};
12685            for (let t4 of ["group", "label", "line", "symbol"]) i3[t4] && (i3[t4] = i3[t4].destroy());
12686            e3 && v(e3), t3.legendItem = void 0;
12687          }
12688          destroy() {
12689            for (let t3 of this.getAllItems()) this.destroyItem(t3);
12690            for (let t3 of ["clipRect", "up", "down", "pager", "nav", "box", "title", "group"]) this[t3] && (this[t3] = this[t3].destroy());
12691            this.display = null;
12692          }
12693          positionCheckboxes() {
12694            let t3;
12695            let e3 = this.group && this.group.alignAttr, i3 = this.clipHeight || this.legendHeight, s2 = this.titleHeight;
12696            e3 && (t3 = e3.translateY, this.allItems.forEach(function(r2) {
12697              let o2;
12698              let n2 = r2.checkbox;
12699              n2 && (o2 = t3 + s2 + n2.y + (this.scrollOffset || 0) + 3, y(n2, {
12700                left: e3.translateX + r2.checkboxOffset + n2.x - 20 + "px",
12701                top: o2 + "px",
12702                display: this.proximate || o2 > t3 - 6 && o2 < t3 + i3 - 6 ? "" : "none"
12703              }));
12704            }, this));
12705          }
12706          renderTitle() {
12707            let t3 = this.options, e3 = this.padding, i3 = t3.title, s2, r2 = 0;
12708            i3.text && (this.title || (this.title = this.chart.renderer.label(i3.text, e3 - 3, e3 - 4, void 0, void 0, void 0, t3.useHTML, void 0, "legend-title").attr({
12709              zIndex: 1
12710            }), this.chart.styledMode || this.title.css(i3.style), this.title.add(this.group)), i3.width || this.title.css({
12711              width: this.maxLegendWidth + "px"
12712            }), r2 = (s2 = this.title.getBBox()).height, this.offsetWidth = s2.width, this.contentGroup.attr({
12713              translateY: r2
12714            })), this.titleHeight = r2;
12715          }
12716          setText(t3) {
12717            let e3 = this.options;
12718            t3.legendItem.label.attr({
12719              text: e3.labelFormat ? f(e3.labelFormat, t3, this.chart) : e3.labelFormatter.call(t3)
12720            });
12721          }
12722          renderItem(t3) {
12723            let e3 = t3.legendItem = t3.legendItem || {}, i3 = this.chart, s2 = i3.renderer, r2 = this.options, o2 = "horizontal" === r2.layout, n2 = this.symbolWidth, a2 = r2.symbolPadding || 0, h2 = this.itemStyle, l2 = this.itemHiddenStyle, d2 = o2 ? w(r2.itemDistance, 20) : 0, c2 = !r2.rtl, p2 = !t3.series, u12 = !p2 && t3.series.drawLegendSymbol ? t3.series : t3, g2 = u12.options, f2 = !!this.createCheckboxForItem && g2 && g2.showCheckbox, m2 = r2.useHTML, x2 = t3.options.className, y2 = e3.label, b2 = n2 + a2 + d2 + (f2 ? 20 : 0);
12724            !y2 && (e3.group = s2.g("legend-item").addClass("highcharts-" + u12.type + "-series highcharts-color-" + t3.colorIndex + (x2 ? " " + x2 : "") + (p2 ? " highcharts-series-" + t3.index : "")).attr({
12725              zIndex: 1
12726            }).add(this.scrollGroup), e3.label = y2 = s2.text("", c2 ? n2 + a2 : -a2, this.baseline || 0, m2), i3.styledMode || y2.css(M(t3.visible ? h2 : l2)), y2.attr({
12727              align: c2 ? "left" : "right",
12728              zIndex: 2
12729            }).add(e3.group), !this.baseline && (this.fontMetrics = s2.fontMetrics(y2), this.baseline = this.fontMetrics.f + 3 + this.itemMarginTop, y2.attr("y", this.baseline), this.symbolHeight = w(r2.symbolHeight, this.fontMetrics.f), r2.squareSymbol && (this.symbolWidth = w(r2.symbolWidth, Math.max(this.symbolHeight, 16)), b2 = this.symbolWidth + a2 + d2 + (f2 ? 20 : 0), c2 && y2.attr("x", this.symbolWidth + a2))), u12.drawLegendSymbol(this, t3), this.setItemEvents && this.setItemEvents(t3, y2, m2)), f2 && !t3.checkbox && this.createCheckboxForItem && this.createCheckboxForItem(t3), this.colorizeItem(t3, t3.visible), (i3.styledMode || !h2.width) && y2.css({
12730              width: (r2.itemWidth || this.widthOption || i3.spacingBox.width) - b2 + "px"
12731            }), this.setText(t3);
12732            let v2 = y2.getBBox(), S3 = this.fontMetrics && this.fontMetrics.h || 0;
12733            t3.itemWidth = t3.checkboxOffset = r2.itemWidth || e3.labelWidth || v2.width + b2, this.maxItemWidth = Math.max(this.maxItemWidth, t3.itemWidth), this.totalItemWidth += t3.itemWidth, this.itemHeight = t3.itemHeight = Math.round(e3.labelHeight || (v2.height > 1.5 * S3 ? v2.height : S3));
12734          }
12735          layoutItem(t3) {
12736            let e3 = this.options, i3 = this.padding, s2 = "horizontal" === e3.layout, r2 = t3.itemHeight, o2 = this.itemMarginBottom, n2 = this.itemMarginTop, a2 = s2 ? w(e3.itemDistance, 20) : 0, h2 = this.maxLegendWidth, l2 = e3.alignColumns && this.totalItemWidth > h2 ? this.maxItemWidth : t3.itemWidth, d2 = t3.legendItem || {};
12737            s2 && this.itemX - i3 + l2 > h2 && (this.itemX = i3, this.lastLineHeight && (this.itemY += n2 + this.lastLineHeight + o2), this.lastLineHeight = 0), this.lastItemY = n2 + this.itemY + o2, this.lastLineHeight = Math.max(r2, this.lastLineHeight), d2.x = this.itemX, d2.y = this.itemY, s2 ? this.itemX += l2 : (this.itemY += n2 + r2 + o2, this.lastLineHeight = r2), this.offsetWidth = this.widthOption || Math.max((s2 ? this.itemX - i3 - (t3.checkbox ? 0 : a2) : l2) + i3, this.offsetWidth);
12738          }
12739          getAllItems() {
12740            let t3 = [];
12741            return this.chart.series.forEach(function(e3) {
12742              let i3 = e3 && e3.options;
12743              e3 && w(i3.showInLegend, !b(i3.linkedTo) && void 0, true) && (t3 = t3.concat((e3.legendItem || {}).labels || ("point" === i3.legendType ? e3.data : e3)));
12744            }), C(this, "afterGetAllItems", {
12745              allItems: t3
12746            }), t3;
12747          }
12748          getAlignment() {
12749            let t3 = this.options;
12750            return this.proximate ? t3.align.charAt(0) + "tv" : t3.floating ? "" : t3.align.charAt(0) + t3.verticalAlign.charAt(0) + t3.layout.charAt(0);
12751          }
12752          adjustMargins(t3, e3) {
12753            let i3 = this.chart, s2 = this.options, r2 = this.getAlignment();
12754            r2 && [/(lth|ct|rth)/, /(rtv|rm|rbv)/, /(rbh|cb|lbh)/, /(lbv|lm|ltv)/].forEach(function(o2, n2) {
12755              o2.test(r2) && !b(t3[n2]) && (i3[u11[n2]] = Math.max(i3[u11[n2]], i3.legend[(n2 + 1) % 2 ? "legendHeight" : "legendWidth"] + [1, -1, -1, 1][n2] * s2[n2 % 2 ? "x" : "y"] + w(s2.margin, 12) + e3[n2] + (i3.titleOffset[n2] || 0)));
12756            });
12757          }
12758          proximatePositions() {
12759            let t3;
12760            let e3 = this.chart, i3 = [], s2 = "left" === this.options.align;
12761            for (let r2 of (this.allItems.forEach(function(t4) {
12762              let r3, o2, n2 = s2, a2, h2;
12763              t4.yAxis && (t4.xAxis.options.reversed && (n2 = !n2), t4.points && (r3 = S2(n2 ? t4.points : t4.points.slice(0).reverse(), function(t5) {
12764                return k(t5.plotY);
12765              })), o2 = this.itemMarginTop + t4.legendItem.label.getBBox().height + this.itemMarginBottom, h2 = t4.yAxis.top - e3.plotTop, a2 = t4.visible ? (r3 ? r3.plotY : t4.yAxis.height) + (h2 - 0.3 * o2) : h2 + t4.yAxis.height, i3.push({
12766                target: a2,
12767                size: o2,
12768                item: t4
12769              }));
12770            }, this), g(i3, e3.plotHeight))) t3 = r2.item.legendItem || {}, k(r2.pos) && (t3.y = e3.plotTop - e3.spacing[0] + r2.pos);
12771          }
12772          render() {
12773            let t3 = this.chart, e3 = t3.renderer, i3 = this.options, s2 = this.padding, r2 = this.getAllItems(), o2, n2, a2, h2 = this.group, l2, d2 = this.box;
12774            this.itemX = s2, this.itemY = this.initialItemY, this.offsetWidth = 0, this.lastItemY = 0, this.widthOption = A(i3.width, t3.spacingBox.width - s2), l2 = t3.spacingBox.width - 2 * s2 - i3.x, ["rm", "lm"].indexOf(this.getAlignment().substring(0, 2)) > -1 && (l2 /= 2), this.maxLegendWidth = this.widthOption || l2, h2 || (this.group = h2 = e3.g("legend").addClass(i3.className || "").attr({
12775              zIndex: 7
12776            }).add(), this.contentGroup = e3.g().attr({
12777              zIndex: 1
12778            }).add(h2), this.scrollGroup = e3.g().add(this.contentGroup)), this.renderTitle(), P(r2, (t4, e4) => (t4.options && t4.options.legendIndex || 0) - (e4.options && e4.options.legendIndex || 0)), i3.reversed && r2.reverse(), this.allItems = r2, this.display = o2 = !!r2.length, this.lastLineHeight = 0, this.maxItemWidth = 0, this.totalItemWidth = 0, this.itemHeight = 0, r2.forEach(this.renderItem, this), r2.forEach(this.layoutItem, this), n2 = (this.widthOption || this.offsetWidth) + s2, a2 = this.lastItemY + this.lastLineHeight + this.titleHeight, a2 = this.handleOverflow(a2) + s2, d2 || (this.box = d2 = e3.rect().addClass("highcharts-legend-box").attr({
12779              r: i3.borderRadius
12780            }).add(h2)), t3.styledMode || d2.attr({
12781              stroke: i3.borderColor,
12782              "stroke-width": i3.borderWidth || 0,
12783              fill: i3.backgroundColor || "none"
12784            }).shadow(i3.shadow), n2 > 0 && a2 > 0 && d2[d2.placed ? "animate" : "attr"](d2.crisp.call({}, {
12785              x: 0,
12786              y: 0,
12787              width: n2,
12788              height: a2
12789            }, d2.strokeWidth())), h2[o2 ? "show" : "hide"](), t3.styledMode && "none" === h2.getStyle("display") && (n2 = a2 = 0), this.legendWidth = n2, this.legendHeight = a2, o2 && this.align(), this.proximate || this.positionItems(), C(this, "afterRender");
12790          }
12791          align(t3 = this.chart.spacingBox) {
12792            let e3 = this.chart, i3 = this.options, s2 = t3.y;
12793            /(lth|ct|rth)/.test(this.getAlignment()) && e3.titleOffset[0] > 0 ? s2 += e3.titleOffset[0] : /(lbh|cb|rbh)/.test(this.getAlignment()) && e3.titleOffset[2] > 0 && (s2 -= e3.titleOffset[2]), s2 !== t3.y && (t3 = M(t3, {
12794              y: s2
12795            })), e3.hasRendered || (this.group.placed = false), this.group.align(M(i3, {
12796              width: this.legendWidth,
12797              height: this.legendHeight,
12798              verticalAlign: this.proximate ? "top" : i3.verticalAlign
12799            }), true, t3);
12800          }
12801          handleOverflow(t3) {
12802            let e3 = this, i3 = this.chart, s2 = i3.renderer, r2 = this.options, o2 = r2.y, n2 = "top" === r2.verticalAlign, a2 = this.padding, h2 = r2.maxHeight, l2 = r2.navigation, d2 = w(l2.animation, true), c2 = l2.arrowSize || 12, p2 = this.pages, u12 = this.allItems, g2 = function(t4) {
12803              "number" == typeof t4 ? S3.attr({
12804                height: t4
12805              }) : S3 && (e3.clipRect = S3.destroy(), e3.contentGroup.clip()), e3.contentGroup.div && (e3.contentGroup.div.style.clip = t4 ? "rect(" + a2 + "px,9999px," + (a2 + t4) + "px,0)" : "auto");
12806            }, f2 = function(t4) {
12807              return e3[t4] = s2.circle(0, 0, 1.3 * c2).translate(c2 / 2, c2 / 2).add(v2), i3.styledMode || e3[t4].attr("fill", "rgba(0,0,0,0.0001)"), e3[t4];
12808            }, m2, x2, y2, b2 = i3.spacingBox.height + (n2 ? -o2 : o2) - a2, v2 = this.nav, S3 = this.clipRect;
12809            return "horizontal" !== r2.layout || "middle" === r2.verticalAlign || r2.floating || (b2 /= 2), h2 && (b2 = Math.min(b2, h2)), p2.length = 0, t3 && b2 > 0 && t3 > b2 && false !== l2.enabled ? (this.clipHeight = m2 = Math.max(b2 - 20 - this.titleHeight - a2, 0), this.currentPage = w(this.currentPage, 1), this.fullHeight = t3, u12.forEach((t4, e4) => {
12810              let i4 = (y2 = t4.legendItem || {}).y || 0, s3 = Math.round(y2.label.getBBox().height), r3 = p2.length;
12811              (!r3 || i4 - p2[r3 - 1] > m2 && (x2 || i4) !== p2[r3 - 1]) && (p2.push(x2 || i4), r3++), y2.pageIx = r3 - 1, x2 && ((u12[e4 - 1].legendItem || {}).pageIx = r3 - 1), e4 === u12.length - 1 && i4 + s3 - p2[r3 - 1] > m2 && i4 > p2[r3 - 1] && (p2.push(i4), y2.pageIx = r3), i4 !== x2 && (x2 = i4);
12812            }), S3 || (S3 = e3.clipRect = s2.clipRect(0, a2 - 2, 9999, 0), e3.contentGroup.clip(S3)), g2(m2), v2 || (this.nav = v2 = s2.g().attr({
12813              zIndex: 1
12814            }).add(this.group), this.up = s2.symbol("triangle", 0, 0, c2, c2).add(v2), f2("upTracker").on("click", function() {
12815              e3.scroll(-1, d2);
12816            }), this.pager = s2.text("", 15, 10).addClass("highcharts-legend-navigation"), !i3.styledMode && l2.style && this.pager.css(l2.style), this.pager.add(v2), this.down = s2.symbol("triangle-down", 0, 0, c2, c2).add(v2), f2("downTracker").on("click", function() {
12817              e3.scroll(1, d2);
12818            })), e3.scroll(0), t3 = b2) : v2 && (g2(), this.nav = v2.destroy(), this.scrollGroup.attr({
12819              translateY: 1
12820            }), this.clipHeight = 0), t3;
12821          }
12822          scroll(t3, e3) {
12823            let i3 = this.chart, s2 = this.pages, r2 = s2.length, o2 = this.clipHeight, n2 = this.options.navigation, a2 = this.pager, h2 = this.padding, c2 = this.currentPage + t3;
12824            c2 > r2 && (c2 = r2), c2 > 0 && (void 0 !== e3 && d(e3, i3), this.nav.attr({
12825              translateX: h2,
12826              translateY: o2 + this.padding + 7 + this.titleHeight,
12827              visibility: "inherit"
12828            }), [this.up, this.upTracker].forEach(function(t4) {
12829              t4.attr({
12830                class: 1 === c2 ? "highcharts-legend-nav-inactive" : "highcharts-legend-nav-active"
12831              });
12832            }), a2.attr({
12833              text: c2 + "/" + r2
12834            }), [this.down, this.downTracker].forEach(function(t4) {
12835              t4.attr({
12836                x: 18 + this.pager.getBBox().width,
12837                class: c2 === r2 ? "highcharts-legend-nav-inactive" : "highcharts-legend-nav-active"
12838              });
12839            }, this), i3.styledMode || (this.up.attr({
12840              fill: 1 === c2 ? n2.inactiveColor : n2.activeColor
12841            }), this.upTracker.css({
12842              cursor: 1 === c2 ? "default" : "pointer"
12843            }), this.down.attr({
12844              fill: c2 === r2 ? n2.inactiveColor : n2.activeColor
12845            }), this.downTracker.css({
12846              cursor: c2 === r2 ? "default" : "pointer"
12847            })), this.scrollOffset = -s2[c2 - 1] + this.initialItemY, this.scrollGroup.animate({
12848              translateY: this.scrollOffset
12849            }), this.currentPage = c2, this.positionCheckboxes(), L(() => {
12850              C(this, "afterScroll", {
12851                currentPage: c2
12852              });
12853            }, l(w(e3, i3.renderer.globalAnimation, true)).duration));
12854          }
12855          setItemEvents(t3, e3, i3) {
12856            let o2 = this, n2 = t3.legendItem || {}, a2 = o2.chart.renderer.boxWrapper, h2 = t3 instanceof r, l2 = t3 instanceof s, d2 = "highcharts-legend-" + (h2 ? "point" : "series") + "-active", c2 = o2.chart.styledMode, p2 = i3 ? [e3, n2.symbol] : [n2.group], u12 = (e4) => {
12857              o2.allItems.forEach((i4) => {
12858                t3 !== i4 && [i4].concat(i4.linkedSeries || []).forEach((t4) => {
12859                  t4.setState(e4, !h2);
12860                });
12861              });
12862            };
12863            for (let i4 of p2) i4 && i4.on("mouseover", function() {
12864              t3.visible && u12("inactive"), t3.setState("hover"), t3.visible && a2.addClass(d2), c2 || e3.css(o2.options.itemHoverStyle);
12865            }).on("mouseout", function() {
12866              o2.chart.styledMode || e3.css(M(t3.visible ? o2.itemStyle : o2.itemHiddenStyle)), u12(""), a2.removeClass(d2), t3.setState();
12867            }).on("click", function(e4) {
12868              let i5 = function() {
12869                t3.setVisible && t3.setVisible(), u12(t3.visible ? "inactive" : "");
12870              };
12871              a2.removeClass(d2), C(o2, "itemClick", {
12872                browserEvent: e4,
12873                legendItem: t3
12874              }, i5), h2 ? t3.firePointEvent("legendItemClick", {
12875                browserEvent: e4
12876              }) : l2 && C(t3, "legendItemClick", {
12877                browserEvent: e4
12878              });
12879            });
12880          }
12881          createCheckboxForItem(t3) {
12882            t3.checkbox = x("input", {
12883              type: "checkbox",
12884              className: "highcharts-legend-checkbox",
12885              checked: t3.selected,
12886              defaultChecked: t3.selected
12887            }, this.options.itemCheckboxStyle, this.chart.container), m(t3.checkbox, "click", function(e3) {
12888              let i3 = e3.target;
12889              C(t3.series || t3, "checkboxClick", {
12890                checked: i3.checked,
12891                item: t3
12892              }, function() {
12893                t3.select();
12894              });
12895            });
12896          }
12897        }
12898        return (h = O || (O = {})).compose = function(t3) {
12899          T2(p, "Core.Legend") && m(t3, "beforeMargins", function() {
12900            this.legend = new h(this, this.options.legend);
12901          });
12902        }, O;
12903      }), i(e, "Core/Chart/Chart.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Axis/Axis.js"], e["Core/Defaults.js"], e["Core/Templating.js"], e["Core/Foundation.js"], e["Core/Globals.js"], e["Core/Renderer/RendererRegistry.js"], e["Core/Series/Series.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Renderer/SVG/SVGRenderer.js"], e["Core/Time.js"], e["Core/Utilities.js"], e["Core/Renderer/HTML/AST.js"], e["Core/Axis/Tick.js"]], function(t2, e2, i2, s, r, o, n, a, h, l, d, c, p, u11) {
12904        let {
12905          animate: g,
12906          animObject: f,
12907          setAnimation: m
12908        } = t2, {
12909          defaultOptions: x,
12910          defaultTime: y
12911        } = i2, {
12912          numberFormat: b
12913        } = s, {
12914          registerEventOptions: v
12915        } = r, {
12916          charts: S2,
12917          doc: C,
12918          marginNames: k,
12919          svg: M,
12920          win: w
12921        } = o, {
12922          seriesTypes: T2
12923        } = h, {
12924          addEvent: A,
12925          attr: P,
12926          createElement: L,
12927          css: O,
12928          defined: D2,
12929          diffObjects: E,
12930          discardElement: I,
12931          erase: j,
12932          error: B,
12933          extend: R,
12934          find: z,
12935          fireEvent: N,
12936          getStyle: W,
12937          isArray: G,
12938          isNumber: H,
12939          isObject: X,
12940          isString: F,
12941          merge: Y,
12942          objectEach: U,
12943          pick: V,
12944          pInt: $,
12945          relativeLength: Z,
12946          removeEvent: _2,
12947          splat: q,
12948          syncTimeout: K,
12949          uniqueKey: J
12950        } = c;
12951        class Q {
12952          static chart(t3, e3, i3) {
12953            return new Q(t3, e3, i3);
12954          }
12955          constructor(t3, e3, i3) {
12956            this.sharedClips = {};
12957            let s2 = [...arguments];
12958            (F(t3) || t3.nodeName) && (this.renderTo = s2.shift()), this.init(s2[0], s2[1]);
12959          }
12960          setZoomOptions() {
12961            let t3 = this.options.chart, e3 = t3.zooming;
12962            this.zooming = __spreadProps(__spreadValues({}, e3), {
12963              type: V(t3.zoomType, e3.type),
12964              key: V(t3.zoomKey, e3.key),
12965              pinchType: V(t3.pinchType, e3.pinchType),
12966              singleTouch: V(t3.zoomBySingleTouch, e3.singleTouch, false),
12967              resetButton: Y(e3.resetButton, t3.resetZoomButton)
12968            });
12969          }
12970          init(t3, e3) {
12971            N(this, "init", {
12972              args: arguments
12973            }, function() {
12974              let i3 = Y(x, t3), s2 = i3.chart;
12975              this.userOptions = R({}, t3), this.margin = [], this.spacing = [], this.labelCollectors = [], this.callback = e3, this.isResizing = 0, this.options = i3, this.axes = [], this.series = [], this.time = t3.time && Object.keys(t3.time).length ? new d(t3.time) : o.time, this.numberFormatter = s2.numberFormatter || b, this.styledMode = s2.styledMode, this.hasCartesianSeries = s2.showAxes, this.index = S2.length, S2.push(this), o.chartCount++, v(this, s2), this.xAxis = [], this.yAxis = [], this.pointCount = this.colorCounter = this.symbolCounter = 0, this.setZoomOptions(), N(this, "afterInit"), this.firstRender();
12976            });
12977          }
12978          initSeries(t3) {
12979            let e3 = this.options.chart, i3 = t3.type || e3.type, s2 = T2[i3];
12980            s2 || B(17, true, this, {
12981              missingModuleFor: i3
12982            });
12983            let r2 = new s2();
12984            return "function" == typeof r2.init && r2.init(this, t3), r2;
12985          }
12986          setSortedData() {
12987            this.getSeriesOrderByLinks().forEach(function(t3) {
12988              t3.points || t3.data || !t3.enabledDataSorting || t3.setData(t3.options.data, false);
12989            });
12990          }
12991          getSeriesOrderByLinks() {
12992            return this.series.concat().sort(function(t3, e3) {
12993              return t3.linkedSeries.length || e3.linkedSeries.length ? e3.linkedSeries.length - t3.linkedSeries.length : 0;
12994            });
12995          }
12996          orderItems(t3, e3 = 0) {
12997            let i3 = this[t3], s2 = this.options[t3] = q(this.options[t3]).slice(), r2 = this.userOptions[t3] = this.userOptions[t3] ? q(this.userOptions[t3]).slice() : [];
12998            if (this.hasRendered && (s2.splice(e3), r2.splice(e3)), i3) for (let t4 = e3, o2 = i3.length; t4 < o2; ++t4) {
12999              let e4 = i3[t4];
13000              e4 && (e4.index = t4, e4 instanceof a && (e4.name = e4.getName()), e4.options.isInternal || (s2[t4] = e4.options, r2[t4] = e4.userOptions));
13001            }
13002          }
13003          isInsidePlot(t3, e3, i3 = {}) {
13004            let {
13005              inverted: s2,
13006              plotBox: r2,
13007              plotLeft: o2,
13008              plotTop: n2,
13009              scrollablePlotBox: a2
13010            } = this, {
13011              scrollLeft: h2 = 0,
13012              scrollTop: l2 = 0
13013            } = i3.visiblePlotOnly && this.scrollablePlotArea?.scrollingContainer || {}, d2 = i3.series, c2 = i3.visiblePlotOnly && a2 || r2, p2 = i3.inverted ? e3 : t3, u12 = i3.inverted ? t3 : e3, g2 = {
13014              x: p2,
13015              y: u12,
13016              isInsidePlot: true,
13017              options: i3
13018            };
13019            if (!i3.ignoreX) {
13020              let t4 = d2 && (s2 && !this.polar ? d2.yAxis : d2.xAxis) || {
13021                pos: o2,
13022                len: 1 / 0
13023              }, e4 = i3.paneCoordinates ? t4.pos + p2 : o2 + p2;
13024              e4 >= Math.max(h2 + o2, t4.pos) && e4 <= Math.min(h2 + o2 + c2.width, t4.pos + t4.len) || (g2.isInsidePlot = false);
13025            }
13026            if (!i3.ignoreY && g2.isInsidePlot) {
13027              let t4 = !s2 && i3.axis && !i3.axis.isXAxis && i3.axis || d2 && (s2 ? d2.xAxis : d2.yAxis) || {
13028                pos: n2,
13029                len: 1 / 0
13030              }, e4 = i3.paneCoordinates ? t4.pos + u12 : n2 + u12;
13031              e4 >= Math.max(l2 + n2, t4.pos) && e4 <= Math.min(l2 + n2 + c2.height, t4.pos + t4.len) || (g2.isInsidePlot = false);
13032            }
13033            return N(this, "afterIsInsidePlot", g2), g2.isInsidePlot;
13034          }
13035          redraw(t3) {
13036            N(this, "beforeRedraw");
13037            let e3 = this.hasCartesianSeries ? this.axes : this.colorAxis || [], i3 = this.series, s2 = this.pointer, r2 = this.legend, o2 = this.userOptions.legend, n2 = this.renderer, a2 = n2.isHidden(), h2 = [], l2, d2, c2, p2 = this.isDirtyBox, u12 = this.isDirtyLegend, g2;
13038            for (n2.rootFontSize = n2.boxWrapper.getStyle("font-size"), this.setResponsive && this.setResponsive(false), m(!!this.hasRendered && t3, this), a2 && this.temporaryDisplay(), this.layOutTitles(false), c2 = i3.length; c2--; ) if (((g2 = i3[c2]).options.stacking || g2.options.centerInCategory) && (d2 = true, g2.isDirty)) {
13039              l2 = true;
13040              break;
13041            }
13042            if (l2) for (c2 = i3.length; c2--; ) (g2 = i3[c2]).options.stacking && (g2.isDirty = true);
13043            i3.forEach(function(t4) {
13044              t4.isDirty && ("point" === t4.options.legendType ? ("function" == typeof t4.updateTotals && t4.updateTotals(), u12 = true) : o2 && (o2.labelFormatter || o2.labelFormat) && (u12 = true)), t4.isDirtyData && N(t4, "updatedData");
13045            }), u12 && r2 && r2.options.enabled && (r2.render(), this.isDirtyLegend = false), d2 && this.getStacks(), e3.forEach(function(t4) {
13046              t4.updateNames(), t4.setScale();
13047            }), this.getMargins(), e3.forEach(function(t4) {
13048              t4.isDirty && (p2 = true);
13049            }), e3.forEach(function(t4) {
13050              let e4 = t4.min + "," + t4.max;
13051              t4.extKey !== e4 && (t4.extKey = e4, h2.push(function() {
13052                N(t4, "afterSetExtremes", R(t4.eventArgs, t4.getExtremes())), delete t4.eventArgs;
13053              })), (p2 || d2) && t4.redraw();
13054            }), p2 && this.drawChartBox(), N(this, "predraw"), i3.forEach(function(t4) {
13055              (p2 || t4.isDirty) && t4.visible && t4.redraw(), t4.isDirtyData = false;
13056            }), s2 && s2.reset(true), n2.draw(), N(this, "redraw"), N(this, "render"), a2 && this.temporaryDisplay(true), h2.forEach(function(t4) {
13057              t4.call();
13058            });
13059          }
13060          get(t3) {
13061            let e3 = this.series;
13062            function i3(e4) {
13063              return e4.id === t3 || e4.options && e4.options.id === t3;
13064            }
13065            let s2 = z(this.axes, i3) || z(this.series, i3);
13066            for (let t4 = 0; !s2 && t4 < e3.length; t4++) s2 = z(e3[t4].points || [], i3);
13067            return s2;
13068          }
13069          getAxes() {
13070            let t3 = this.userOptions;
13071            for (let i3 of (N(this, "getAxes"), ["xAxis", "yAxis"])) for (let s2 of t3[i3] = q(t3[i3] || {})) new e2(this, s2, i3);
13072            N(this, "afterGetAxes");
13073          }
13074          getSelectedPoints() {
13075            return this.series.reduce((t3, e3) => (e3.getPointsCollection().forEach((e4) => {
13076              V(e4.selectedStaging, e4.selected) && t3.push(e4);
13077            }), t3), []);
13078          }
13079          getSelectedSeries() {
13080            return this.series.filter(function(t3) {
13081              return t3.selected;
13082            });
13083          }
13084          setTitle(t3, e3, i3) {
13085            this.applyDescription("title", t3), this.applyDescription("subtitle", e3), this.applyDescription("caption", void 0), this.layOutTitles(i3);
13086          }
13087          applyDescription(t3, e3) {
13088            let i3 = this, s2 = this.options[t3] = Y(this.options[t3], e3), r2 = this[t3];
13089            r2 && e3 && (this[t3] = r2 = r2.destroy()), s2 && !r2 && ((r2 = this.renderer.text(s2.text, 0, 0, s2.useHTML).attr({
13090              align: s2.align,
13091              class: "highcharts-" + t3,
13092              zIndex: s2.zIndex || 4
13093            }).add()).update = function(e4, s3) {
13094              i3.applyDescription(t3, e4), i3.layOutTitles(s3);
13095            }, this.styledMode || r2.css(R("title" === t3 ? {
13096              fontSize: this.options.isStock ? "1em" : "1.2em"
13097            } : {}, s2.style)), this[t3] = r2);
13098          }
13099          layOutTitles(t3 = true) {
13100            let e3 = [0, 0, 0], i3 = this.renderer, s2 = this.spacingBox;
13101            ["title", "subtitle", "caption"].forEach(function(t4) {
13102              let r3 = this[t4], o2 = this.options[t4], n2 = o2.verticalAlign || "top", a2 = "title" === t4 ? "top" === n2 ? -3 : 0 : "top" === n2 ? e3[0] + 2 : 0;
13103              if (r3) {
13104                r3.css({
13105                  width: (o2.width || s2.width + (o2.widthAdjust || 0)) + "px"
13106                });
13107                let t5 = i3.fontMetrics(r3).b, h2 = Math.round(r3.getBBox(o2.useHTML).height);
13108                r3.align(R({
13109                  y: "bottom" === n2 ? t5 : a2 + t5,
13110                  height: h2
13111                }, o2), false, "spacingBox"), o2.floating || ("top" === n2 ? e3[0] = Math.ceil(e3[0] + h2) : "bottom" === n2 && (e3[2] = Math.ceil(e3[2] + h2)));
13112              }
13113            }, this), e3[0] && "top" === (this.options.title.verticalAlign || "top") && (e3[0] += this.options.title.margin), e3[2] && "bottom" === this.options.caption.verticalAlign && (e3[2] += this.options.caption.margin);
13114            let r2 = !this.titleOffset || this.titleOffset.join(",") !== e3.join(",");
13115            this.titleOffset = e3, N(this, "afterLayOutTitles"), !this.isDirtyBox && r2 && (this.isDirtyBox = this.isDirtyLegend = r2, this.hasRendered && t3 && this.isDirtyBox && this.redraw());
13116          }
13117          getContainerBox() {
13118            let t3 = [].map.call(this.renderTo.children, (t4) => {
13119              if (t4 !== this.container) {
13120                let e4 = t4.style.display;
13121                return t4.style.display = "none", [t4, e4];
13122              }
13123            }), e3 = {
13124              width: W(this.renderTo, "width", true) || 0,
13125              height: W(this.renderTo, "height", true) || 0
13126            };
13127            return t3.filter(Boolean).forEach(([t4, e4]) => {
13128              t4.style.display = e4;
13129            }), e3;
13130          }
13131          getChartSize() {
13132            let t3 = this.options.chart, e3 = t3.width, i3 = t3.height, s2 = this.getContainerBox(), r2 = s2.height > 1 && !(!this.renderTo.parentElement?.style.height && "100%" === this.renderTo.style.height);
13133            this.chartWidth = Math.max(0, e3 || s2.width || 600), this.chartHeight = Math.max(0, Z(i3, this.chartWidth) || (r2 ? s2.height : 400)), this.containerBox = s2;
13134          }
13135          temporaryDisplay(t3) {
13136            let e3 = this.renderTo, i3;
13137            if (t3) for (; e3 && e3.style; ) e3.hcOrigStyle && (O(e3, e3.hcOrigStyle), delete e3.hcOrigStyle), e3.hcOrigDetached && (C.body.removeChild(e3), e3.hcOrigDetached = false), e3 = e3.parentNode;
13138            else for (; e3 && e3.style && (C.body.contains(e3) || e3.parentNode || (e3.hcOrigDetached = true, C.body.appendChild(e3)), ("none" === W(e3, "display", false) || e3.hcOricDetached) && (e3.hcOrigStyle = {
13139              display: e3.style.display,
13140              height: e3.style.height,
13141              overflow: e3.style.overflow
13142            }, i3 = {
13143              display: "block",
13144              overflow: "hidden"
13145            }, e3 !== this.renderTo && (i3.height = 0), O(e3, i3), e3.offsetWidth || e3.style.setProperty("display", "block", "important")), (e3 = e3.parentNode) !== C.body); ) ;
13146          }
13147          setClassName(t3) {
13148            this.container.className = "highcharts-container " + (t3 || "");
13149          }
13150          getContainer() {
13151            let t3 = this.options, e3 = t3.chart, i3 = "data-highcharts-chart", s2 = J(), r2, o2 = this.renderTo;
13152            o2 || (this.renderTo = o2 = e3.renderTo), F(o2) && (this.renderTo = o2 = C.getElementById(o2)), o2 || B(13, true, this);
13153            let a2 = $(P(o2, i3));
13154            H(a2) && S2[a2] && S2[a2].hasRendered && S2[a2].destroy(), P(o2, i3, this.index), o2.innerHTML = p.emptyHTML, e3.skipClone || o2.offsetWidth || this.temporaryDisplay(), this.getChartSize();
13155            let h2 = this.chartHeight, d2 = this.chartWidth;
13156            O(o2, {
13157              overflow: "hidden"
13158            }), this.styledMode || (r2 = R({
13159              position: "relative",
13160              overflow: "hidden",
13161              width: d2 + "px",
13162              height: h2 + "px",
13163              textAlign: "left",
13164              lineHeight: "normal",
13165              zIndex: 0,
13166              "-webkit-tap-highlight-color": "rgba(0,0,0,0)",
13167              userSelect: "none",
13168              "touch-action": "manipulation",
13169              outline: "none",
13170              padding: "0px"
13171            }, e3.style || {}));
13172            let c2 = L("div", {
13173              id: s2
13174            }, r2, o2);
13175            this.container = c2, this.getChartSize(), d2 === this.chartWidth || (d2 = this.chartWidth, this.styledMode || O(c2, {
13176              width: V(e3.style?.width, d2 + "px")
13177            })), this.containerBox = this.getContainerBox(), this._cursor = c2.style.cursor;
13178            let u12 = e3.renderer || !M ? n.getRendererType(e3.renderer) : l;
13179            if (this.renderer = new u12(c2, d2, h2, void 0, e3.forExport, t3.exporting && t3.exporting.allowHTML, this.styledMode), m(void 0, this), this.setClassName(e3.className), this.styledMode) for (let e4 in t3.defs) this.renderer.definition(t3.defs[e4]);
13180            else this.renderer.setStyle(e3.style);
13181            this.renderer.chartIndex = this.index, N(this, "afterGetContainer");
13182          }
13183          getMargins(t3) {
13184            let {
13185              spacing: e3,
13186              margin: i3,
13187              titleOffset: s2
13188            } = this;
13189            this.resetMargins(), s2[0] && !D2(i3[0]) && (this.plotTop = Math.max(this.plotTop, s2[0] + e3[0])), s2[2] && !D2(i3[2]) && (this.marginBottom = Math.max(this.marginBottom, s2[2] + e3[2])), this.legend && this.legend.display && this.legend.adjustMargins(i3, e3), N(this, "getMargins"), t3 || this.getAxisMargins();
13190          }
13191          getAxisMargins() {
13192            let t3 = this, e3 = t3.axisOffset = [0, 0, 0, 0], i3 = t3.colorAxis, s2 = t3.margin, r2 = function(t4) {
13193              t4.forEach(function(t5) {
13194                t5.visible && t5.getOffset();
13195              });
13196            };
13197            t3.hasCartesianSeries ? r2(t3.axes) : i3 && i3.length && r2(i3), k.forEach(function(i4, r3) {
13198              D2(s2[r3]) || (t3[i4] += e3[r3]);
13199            }), t3.setChartSize();
13200          }
13201          getOptions() {
13202            return E(this.userOptions, x);
13203          }
13204          reflow(t3) {
13205            let e3 = this, i3 = e3.containerBox, s2 = e3.getContainerBox();
13206            delete e3.pointer?.chartPosition, !e3.isPrinting && !e3.isResizing && i3 && s2.width && ((s2.width !== i3.width || s2.height !== i3.height) && (c.clearTimeout(e3.reflowTimeout), e3.reflowTimeout = K(function() {
13207              e3.container && e3.setSize(void 0, void 0, false);
13208            }, t3 ? 100 : 0)), e3.containerBox = s2);
13209          }
13210          setReflow() {
13211            let t3 = this, e3 = (e4) => {
13212              t3.options?.chart.reflow && t3.hasLoaded && t3.reflow(e4);
13213            };
13214            if ("function" == typeof ResizeObserver) new ResizeObserver(e3).observe(t3.renderTo);
13215            else {
13216              let t4 = A(w, "resize", e3);
13217              A(this, "destroy", t4);
13218            }
13219          }
13220          setSize(t3, e3, i3) {
13221            let s2 = this, r2 = s2.renderer;
13222            s2.isResizing += 1, m(i3, s2);
13223            let o2 = r2.globalAnimation;
13224            s2.oldChartHeight = s2.chartHeight, s2.oldChartWidth = s2.chartWidth, void 0 !== t3 && (s2.options.chart.width = t3), void 0 !== e3 && (s2.options.chart.height = e3), s2.getChartSize();
13225            let {
13226              chartWidth: n2,
13227              chartHeight: a2,
13228              scrollablePixelsX: h2 = 0,
13229              scrollablePixelsY: l2 = 0
13230            } = s2;
13231            (s2.isDirtyBox || n2 !== s2.oldChartWidth || a2 !== s2.oldChartHeight) && (s2.styledMode || (o2 ? g : O)(s2.container, {
13232              width: `${n2 + h2}px`,
13233              height: `${a2 + l2}px`
13234            }, o2), s2.setChartSize(true), r2.setSize(n2, a2, o2), s2.axes.forEach(function(t4) {
13235              t4.isDirty = true, t4.setScale();
13236            }), s2.isDirtyLegend = true, s2.isDirtyBox = true, s2.layOutTitles(), s2.getMargins(), s2.redraw(o2), s2.oldChartHeight = void 0, N(s2, "resize"), setTimeout(() => {
13237              s2 && N(s2, "endResize");
13238            }, f(o2).duration)), s2.isResizing -= 1;
13239          }
13240          setChartSize(t3) {
13241            let e3, i3, s2, r2;
13242            let {
13243              chartHeight: o2,
13244              chartWidth: n2,
13245              inverted: a2,
13246              spacing: h2,
13247              renderer: l2
13248            } = this, d2 = this.clipOffset, c2 = Math[a2 ? "floor" : "round"];
13249            this.plotLeft = e3 = Math.round(this.plotLeft), this.plotTop = i3 = Math.round(this.plotTop), this.plotWidth = s2 = Math.max(0, Math.round(n2 - e3 - this.marginRight)), this.plotHeight = r2 = Math.max(0, Math.round(o2 - i3 - this.marginBottom)), this.plotSizeX = a2 ? r2 : s2, this.plotSizeY = a2 ? s2 : r2, this.spacingBox = l2.spacingBox = {
13250              x: h2[3],
13251              y: h2[0],
13252              width: n2 - h2[3] - h2[1],
13253              height: o2 - h2[0] - h2[2]
13254            }, this.plotBox = l2.plotBox = {
13255              x: e3,
13256              y: i3,
13257              width: s2,
13258              height: r2
13259            }, d2 && (this.clipBox = {
13260              x: c2(d2[3]),
13261              y: c2(d2[0]),
13262              width: c2(this.plotSizeX - d2[1] - d2[3]),
13263              height: c2(this.plotSizeY - d2[0] - d2[2])
13264            }), t3 || (this.axes.forEach(function(t4) {
13265              t4.setAxisSize(), t4.setAxisTranslation();
13266            }), l2.alignElements()), N(this, "afterSetChartSize", {
13267              skipAxes: t3
13268            });
13269          }
13270          resetMargins() {
13271            N(this, "resetMargins");
13272            let t3 = this, e3 = t3.options.chart, i3 = e3.plotBorderWidth || 0, s2 = i3 / 2;
13273            ["margin", "spacing"].forEach(function(i4) {
13274              let s3 = e3[i4], r2 = X(s3) ? s3 : [s3, s3, s3, s3];
13275              ["Top", "Right", "Bottom", "Left"].forEach(function(s4, o2) {
13276                t3[i4][o2] = V(e3[i4 + s4], r2[o2]);
13277              });
13278            }), k.forEach(function(e4, i4) {
13279              t3[e4] = V(t3.margin[i4], t3.spacing[i4]);
13280            }), t3.axisOffset = [0, 0, 0, 0], t3.clipOffset = [s2, s2, s2, s2], t3.plotBorderWidth = i3;
13281          }
13282          drawChartBox() {
13283            let t3 = this.options.chart, e3 = this.renderer, i3 = this.chartWidth, s2 = this.chartHeight, r2 = this.styledMode, o2 = this.plotBGImage, n2 = t3.backgroundColor, a2 = t3.plotBackgroundColor, h2 = t3.plotBackgroundImage, l2 = this.plotLeft, d2 = this.plotTop, c2 = this.plotWidth, p2 = this.plotHeight, u12 = this.plotBox, g2 = this.clipRect, f2 = this.clipBox, m2 = this.chartBackground, x2 = this.plotBackground, y2 = this.plotBorder, b2, v2, S3, C2 = "animate";
13284            m2 || (this.chartBackground = m2 = e3.rect().addClass("highcharts-background").add(), C2 = "attr"), r2 ? b2 = v2 = m2.strokeWidth() : (v2 = (b2 = t3.borderWidth || 0) + (t3.shadow ? 8 : 0), S3 = {
13285              fill: n2 || "none"
13286            }, (b2 || m2["stroke-width"]) && (S3.stroke = t3.borderColor, S3["stroke-width"] = b2), m2.attr(S3).shadow(t3.shadow)), m2[C2]({
13287              x: v2 / 2,
13288              y: v2 / 2,
13289              width: i3 - v2 - b2 % 2,
13290              height: s2 - v2 - b2 % 2,
13291              r: t3.borderRadius
13292            }), C2 = "animate", x2 || (C2 = "attr", this.plotBackground = x2 = e3.rect().addClass("highcharts-plot-background").add()), x2[C2](u12), !r2 && (x2.attr({
13293              fill: a2 || "none"
13294            }).shadow(t3.plotShadow), h2 && (o2 ? (h2 !== o2.attr("href") && o2.attr("href", h2), o2.animate(u12)) : this.plotBGImage = e3.image(h2, l2, d2, c2, p2).add())), g2 ? g2.animate({
13295              width: f2.width,
13296              height: f2.height
13297            }) : this.clipRect = e3.clipRect(f2), C2 = "animate", y2 || (C2 = "attr", this.plotBorder = y2 = e3.rect().addClass("highcharts-plot-border").attr({
13298              zIndex: 1
13299            }).add()), r2 || y2.attr({
13300              stroke: t3.plotBorderColor,
13301              "stroke-width": t3.plotBorderWidth || 0,
13302              fill: "none"
13303            }), y2[C2](y2.crisp({
13304              x: l2,
13305              y: d2,
13306              width: c2,
13307              height: p2
13308            }, -y2.strokeWidth())), this.isDirtyBox = false, N(this, "afterDrawChartBox");
13309          }
13310          propFromSeries() {
13311            let t3, e3, i3;
13312            let s2 = this, r2 = s2.options.chart, o2 = s2.options.series;
13313            ["inverted", "angular", "polar"].forEach(function(n2) {
13314              for (e3 = T2[r2.type], i3 = r2[n2] || e3 && e3.prototype[n2], t3 = o2 && o2.length; !i3 && t3--; ) (e3 = T2[o2[t3].type]) && e3.prototype[n2] && (i3 = true);
13315              s2[n2] = i3;
13316            });
13317          }
13318          linkSeries(t3) {
13319            let e3 = this, i3 = e3.series;
13320            i3.forEach(function(t4) {
13321              t4.linkedSeries.length = 0;
13322            }), i3.forEach(function(t4) {
13323              let {
13324                linkedTo: i4
13325              } = t4.options;
13326              if (F(i4)) {
13327                let s2;
13328                (s2 = ":previous" === i4 ? e3.series[t4.index - 1] : e3.get(i4)) && s2.linkedParent !== t4 && (s2.linkedSeries.push(t4), t4.linkedParent = s2, s2.enabledDataSorting && t4.setDataSortingOptions(), t4.visible = V(t4.options.visible, s2.options.visible, t4.visible));
13329              }
13330            }), N(this, "afterLinkSeries", {
13331              isUpdating: t3
13332            });
13333          }
13334          renderSeries() {
13335            this.series.forEach(function(t3) {
13336              t3.translate(), t3.render();
13337            });
13338          }
13339          render() {
13340            let t3 = this.axes, e3 = this.colorAxis, i3 = this.renderer, s2 = this.options.chart.axisLayoutRuns || 2, r2 = (t4) => {
13341              t4.forEach((t5) => {
13342                t5.visible && t5.render();
13343              });
13344            }, o2 = 0, n2 = true, a2, h2 = 0;
13345            for (let e4 of (this.setTitle(), N(this, "beforeMargins"), this.getStacks?.(), this.getMargins(true), this.setChartSize(), t3)) {
13346              let {
13347                options: t4
13348              } = e4, {
13349                labels: i4
13350              } = t4;
13351              if (this.hasCartesianSeries && e4.horiz && e4.visible && i4.enabled && e4.series.length && "colorAxis" !== e4.coll && !this.polar) {
13352                o2 = t4.tickLength, e4.createGroups();
13353                let s3 = new u11(e4, 0, "", true), r3 = s3.createLabel("x", i4);
13354                if (s3.destroy(), r3 && V(i4.reserveSpace, !H(t4.crossing)) && (o2 = r3.getBBox().height + i4.distance + Math.max(t4.offset || 0, 0)), o2) {
13355                  r3?.destroy();
13356                  break;
13357                }
13358              }
13359            }
13360            for (this.plotHeight = Math.max(this.plotHeight - o2, 0); (n2 || a2 || s2 > 1) && h2 < s2; ) {
13361              let e4 = this.plotWidth, i4 = this.plotHeight;
13362              for (let e5 of t3) 0 === h2 ? e5.setScale() : (e5.horiz && n2 || !e5.horiz && a2) && e5.setTickInterval(true);
13363              0 === h2 ? this.getAxisMargins() : this.getMargins(), n2 = e4 / this.plotWidth > (h2 ? 1 : 1.1), a2 = i4 / this.plotHeight > (h2 ? 1 : 1.05), h2++;
13364            }
13365            this.drawChartBox(), this.hasCartesianSeries ? r2(t3) : e3 && e3.length && r2(e3), this.seriesGroup || (this.seriesGroup = i3.g("series-group").attr({
13366              zIndex: 3
13367            }).shadow(this.options.chart.seriesGroupShadow).add()), this.renderSeries(), this.addCredits(), this.setResponsive && this.setResponsive(), this.hasRendered = true;
13368          }
13369          addCredits(t3) {
13370            let e3 = this, i3 = Y(true, this.options.credits, t3);
13371            i3.enabled && !this.credits && (this.credits = this.renderer.text(i3.text + (this.mapCredits || ""), 0, 0).addClass("highcharts-credits").on("click", function() {
13372              i3.href && (w.location.href = i3.href);
13373            }).attr({
13374              align: i3.position.align,
13375              zIndex: 8
13376            }), e3.styledMode || this.credits.css(i3.style), this.credits.add().align(i3.position), this.credits.update = function(t4) {
13377              e3.credits = e3.credits.destroy(), e3.addCredits(t4);
13378            });
13379          }
13380          destroy() {
13381            let t3;
13382            let e3 = this, i3 = e3.axes, s2 = e3.series, r2 = e3.container, n2 = r2 && r2.parentNode;
13383            for (N(e3, "destroy"), e3.renderer.forExport ? j(S2, e3) : S2[e3.index] = void 0, o.chartCount--, e3.renderTo.removeAttribute("data-highcharts-chart"), _2(e3), t3 = i3.length; t3--; ) i3[t3] = i3[t3].destroy();
13384            for (this.scroller && this.scroller.destroy && this.scroller.destroy(), t3 = s2.length; t3--; ) s2[t3] = s2[t3].destroy();
13385            ["title", "subtitle", "chartBackground", "plotBackground", "plotBGImage", "plotBorder", "seriesGroup", "clipRect", "credits", "pointer", "rangeSelector", "legend", "resetZoomButton", "tooltip", "renderer"].forEach(function(t4) {
13386              let i4 = e3[t4];
13387              i4 && i4.destroy && (e3[t4] = i4.destroy());
13388            }), r2 && (r2.innerHTML = p.emptyHTML, _2(r2), n2 && I(r2)), U(e3, function(t4, i4) {
13389              delete e3[i4];
13390            });
13391          }
13392          firstRender() {
13393            let t3 = this, e3 = t3.options;
13394            t3.getContainer(), t3.resetMargins(), t3.setChartSize(), t3.propFromSeries(), t3.getAxes();
13395            let i3 = G(e3.series) ? e3.series : [];
13396            e3.series = [], i3.forEach(function(e4) {
13397              t3.initSeries(e4);
13398            }), t3.linkSeries(), t3.setSortedData(), N(t3, "beforeRender"), t3.render(), t3.pointer?.getChartPosition(), t3.renderer.imgCount || t3.hasLoaded || t3.onload(), t3.temporaryDisplay(true);
13399          }
13400          onload() {
13401            this.callbacks.concat([this.callback]).forEach(function(t3) {
13402              t3 && void 0 !== this.index && t3.apply(this, [this]);
13403            }, this), N(this, "load"), N(this, "render"), D2(this.index) && this.setReflow(), this.warnIfA11yModuleNotLoaded(), this.hasLoaded = true;
13404          }
13405          warnIfA11yModuleNotLoaded() {
13406            let {
13407              options: t3,
13408              title: e3
13409            } = this;
13410            !t3 || this.accessibility || (this.renderer.boxWrapper.attr({
13411              role: "img",
13412              "aria-label": (e3 && e3.element.textContent || "").replace(/</g, "&lt;")
13413            }), t3.accessibility && false === t3.accessibility.enabled || B('Highcharts warning: Consider including the "accessibility.js" module to make your chart more usable for people with disabilities. Set the "accessibility.enabled" option to false to remove this warning. See https://www.highcharts.com/docs/accessibility/accessibility-module.', false, this));
13414          }
13415          addSeries(t3, e3, i3) {
13416            let s2;
13417            let r2 = this;
13418            return t3 && (e3 = V(e3, true), N(r2, "addSeries", {
13419              options: t3
13420            }, function() {
13421              s2 = r2.initSeries(t3), r2.isDirtyLegend = true, r2.linkSeries(), s2.enabledDataSorting && s2.setData(t3.data, false), N(r2, "afterAddSeries", {
13422                series: s2
13423              }), e3 && r2.redraw(i3);
13424            })), s2;
13425          }
13426          addAxis(t3, e3, i3, s2) {
13427            return this.createAxis(e3 ? "xAxis" : "yAxis", {
13428              axis: t3,
13429              redraw: i3,
13430              animation: s2
13431            });
13432          }
13433          addColorAxis(t3, e3, i3) {
13434            return this.createAxis("colorAxis", {
13435              axis: t3,
13436              redraw: e3,
13437              animation: i3
13438            });
13439          }
13440          createAxis(t3, i3) {
13441            let s2 = new e2(this, i3.axis, t3);
13442            return V(i3.redraw, true) && this.redraw(i3.animation), s2;
13443          }
13444          showLoading(t3) {
13445            let e3 = this, i3 = e3.options, s2 = i3.loading, r2 = function() {
13446              o2 && O(o2, {
13447                left: e3.plotLeft + "px",
13448                top: e3.plotTop + "px",
13449                width: e3.plotWidth + "px",
13450                height: e3.plotHeight + "px"
13451              });
13452            }, o2 = e3.loadingDiv, n2 = e3.loadingSpan;
13453            o2 || (e3.loadingDiv = o2 = L("div", {
13454              className: "highcharts-loading highcharts-loading-hidden"
13455            }, null, e3.container)), n2 || (e3.loadingSpan = n2 = L("span", {
13456              className: "highcharts-loading-inner"
13457            }, null, o2), A(e3, "redraw", r2)), o2.className = "highcharts-loading", p.setElementHTML(n2, V(t3, i3.lang.loading, "")), e3.styledMode || (O(o2, R(s2.style, {
13458              zIndex: 10
13459            })), O(n2, s2.labelStyle), e3.loadingShown || (O(o2, {
13460              opacity: 0,
13461              display: ""
13462            }), g(o2, {
13463              opacity: s2.style.opacity || 0.5
13464            }, {
13465              duration: s2.showDuration || 0
13466            }))), e3.loadingShown = true, r2();
13467          }
13468          hideLoading() {
13469            let t3 = this.options, e3 = this.loadingDiv;
13470            e3 && (e3.className = "highcharts-loading highcharts-loading-hidden", this.styledMode || g(e3, {
13471              opacity: 0
13472            }, {
13473              duration: t3.loading.hideDuration || 100,
13474              complete: function() {
13475                O(e3, {
13476                  display: "none"
13477                });
13478              }
13479            })), this.loadingShown = false;
13480          }
13481          update(t3, e3, i3, s2) {
13482            let r2, o2, n2;
13483            let a2 = this, h2 = {
13484              credits: "addCredits",
13485              title: "setTitle",
13486              subtitle: "setSubtitle",
13487              caption: "setCaption"
13488            }, l2 = t3.isResponsiveOptions, c2 = [];
13489            N(a2, "update", {
13490              options: t3
13491            }), l2 || a2.setResponsive(false, true), t3 = E(t3, a2.options), a2.userOptions = Y(a2.userOptions, t3);
13492            let p2 = t3.chart;
13493            p2 && (Y(true, a2.options.chart, p2), this.setZoomOptions(), "className" in p2 && a2.setClassName(p2.className), ("inverted" in p2 || "polar" in p2 || "type" in p2) && (a2.propFromSeries(), r2 = true), "alignTicks" in p2 && (r2 = true), "events" in p2 && v(this, p2), U(p2, function(t4, e4) {
13494              -1 !== a2.propsRequireUpdateSeries.indexOf("chart." + e4) && (o2 = true), -1 !== a2.propsRequireDirtyBox.indexOf(e4) && (a2.isDirtyBox = true), -1 === a2.propsRequireReflow.indexOf(e4) || (a2.isDirtyBox = true, l2 || (n2 = true));
13495            }), !a2.styledMode && p2.style && a2.renderer.setStyle(a2.options.chart.style || {})), !a2.styledMode && t3.colors && (this.options.colors = t3.colors), t3.time && (this.time === y && (this.time = new d(t3.time)), Y(true, a2.options.time, t3.time)), U(t3, function(e4, i4) {
13496              a2[i4] && "function" == typeof a2[i4].update ? a2[i4].update(e4, false) : "function" == typeof a2[h2[i4]] ? a2[h2[i4]](e4) : "colors" !== i4 && -1 === a2.collectionsWithUpdate.indexOf(i4) && Y(true, a2.options[i4], t3[i4]), "chart" !== i4 && -1 !== a2.propsRequireUpdateSeries.indexOf(i4) && (o2 = true);
13497            }), this.collectionsWithUpdate.forEach(function(e4) {
13498              t3[e4] && (q(t3[e4]).forEach(function(t4, s3) {
13499                let r3;
13500                let o3 = D2(t4.id);
13501                o3 && (r3 = a2.get(t4.id)), !r3 && a2[e4] && (r3 = a2[e4][V(t4.index, s3)]) && (o3 && D2(r3.options.id) || r3.options.isInternal) && (r3 = void 0), r3 && r3.coll === e4 && (r3.update(t4, false), i3 && (r3.touched = true)), !r3 && i3 && a2.collectionsWithInit[e4] && (a2.collectionsWithInit[e4][0].apply(a2, [t4].concat(a2.collectionsWithInit[e4][1] || []).concat([false])).touched = true);
13502              }), i3 && a2[e4].forEach(function(t4) {
13503                t4.touched || t4.options.isInternal ? delete t4.touched : c2.push(t4);
13504              }));
13505            }), c2.forEach(function(t4) {
13506              t4.chart && t4.remove && t4.remove(false);
13507            }), r2 && a2.axes.forEach(function(t4) {
13508              t4.update({}, false);
13509            }), o2 && a2.getSeriesOrderByLinks().forEach(function(t4) {
13510              t4.chart && t4.update({}, false);
13511            }, this);
13512            let u12 = p2 && p2.width, g2 = p2 && (F(p2.height) ? Z(p2.height, u12 || a2.chartWidth) : p2.height);
13513            n2 || H(u12) && u12 !== a2.chartWidth || H(g2) && g2 !== a2.chartHeight ? a2.setSize(u12, g2, s2) : V(e3, true) && a2.redraw(s2), N(a2, "afterUpdate", {
13514              options: t3,
13515              redraw: e3,
13516              animation: s2
13517            });
13518          }
13519          setSubtitle(t3, e3) {
13520            this.applyDescription("subtitle", t3), this.layOutTitles(e3);
13521          }
13522          setCaption(t3, e3) {
13523            this.applyDescription("caption", t3), this.layOutTitles(e3);
13524          }
13525          showResetZoom() {
13526            let t3 = this, e3 = x.lang, i3 = t3.zooming.resetButton, s2 = i3.theme, r2 = "chart" === i3.relativeTo || "spacingBox" === i3.relativeTo ? null : "plotBox";
13527            function o2() {
13528              t3.zoomOut();
13529            }
13530            N(this, "beforeShowResetZoom", null, function() {
13531              t3.resetZoomButton = t3.renderer.button(e3.resetZoom, null, null, o2, s2).attr({
13532                align: i3.position.align,
13533                title: e3.resetZoomTitle
13534              }).addClass("highcharts-reset-zoom").add().align(i3.position, false, r2);
13535            }), N(this, "afterShowResetZoom");
13536          }
13537          zoomOut() {
13538            N(this, "selection", {
13539              resetSelection: true
13540            }, () => this.transform({
13541              reset: true,
13542              trigger: "zoom"
13543            }));
13544          }
13545          pan(t3, e3) {
13546            let i3 = this, s2 = "object" == typeof e3 ? e3 : {
13547              enabled: e3,
13548              type: "x"
13549            }, r2 = s2.type, o2 = r2 && i3[{
13550              x: "xAxis",
13551              xy: "axes",
13552              y: "yAxis"
13553            }[r2]].filter((t4) => t4.options.panningEnabled && !t4.options.isInternal), n2 = i3.options.chart;
13554            n2?.panning && (n2.panning = s2), N(this, "pan", {
13555              originalEvent: t3
13556            }, () => {
13557              i3.transform({
13558                axes: o2,
13559                event: t3,
13560                to: {
13561                  x: t3.chartX - (i3.mouseDownX || 0),
13562                  y: t3.chartY - (i3.mouseDownY || 0)
13563                },
13564                trigger: "pan"
13565              }), O(i3.container, {
13566                cursor: "move"
13567              });
13568            });
13569          }
13570          transform(t3) {
13571            let {
13572              axes: e3 = this.axes,
13573              event: i3,
13574              from: s2 = {},
13575              reset: r2,
13576              selection: o2,
13577              to: n2 = {},
13578              trigger: a2
13579            } = t3, {
13580              inverted: h2
13581            } = this, l2 = false, d2, c2;
13582            for (let t4 of (this.hoverPoints?.forEach((t5) => t5.setState()), e3)) {
13583              let {
13584                horiz: e4,
13585                len: p2,
13586                minPointOffset: u12 = 0,
13587                options: g2,
13588                reversed: f2
13589              } = t4, m2 = e4 ? "width" : "height", x2 = e4 ? "x" : "y", y2 = V(n2[m2], t4.len), b2 = V(s2[m2], t4.len), v2 = 10 > Math.abs(y2) ? 1 : y2 / b2, S3 = (s2[x2] || 0) + b2 / 2 - t4.pos, C2 = S3 - ((n2[x2] ?? t4.pos) + y2 / 2 - t4.pos) / v2, k2 = f2 && !h2 || !f2 && h2 ? -1 : 1;
13590              if (!r2 && (S3 < 0 || S3 > t4.len)) continue;
13591              let M2 = t4.toValue(C2, true) + (o2 || t4.isOrdinal ? 0 : u12 * k2), w2 = t4.toValue(C2 + p2 / v2, true) - (o2 || t4.isOrdinal ? 0 : u12 * k2 || 0), T3 = t4.allExtremes;
13592              if (M2 > w2 && ([M2, w2] = [w2, M2]), 1 === v2 && !r2 && "yAxis" === t4.coll && !T3) {
13593                for (let e5 of t4.series) {
13594                  let t5 = e5.getExtremes(e5.getProcessedData(true).yData, true);
13595                  T3 ?? (T3 = {
13596                    dataMin: Number.MAX_VALUE,
13597                    dataMax: -Number.MAX_VALUE
13598                  }), H(t5.dataMin) && H(t5.dataMax) && (T3.dataMin = Math.min(t5.dataMin, T3.dataMin), T3.dataMax = Math.max(t5.dataMax, T3.dataMax));
13599                }
13600                t4.allExtremes = T3;
13601              }
13602              let {
13603                dataMin: A2,
13604                dataMax: P2,
13605                min: L2,
13606                max: O2
13607              } = R(t4.getExtremes(), T3 || {}), E2 = A2 ?? g2.min, I2 = P2 ?? g2.max, j2 = w2 - M2, B2 = t4.categories ? 0 : Math.min(j2, I2 - E2), z2 = E2 - B2 * (D2(g2.min) ? 0 : g2.minPadding), N2 = I2 + B2 * (D2(g2.max) ? 0 : g2.maxPadding), W2 = t4.allowZoomOutside || 1 === v2 || "zoom" !== a2 && v2 > 1, G2 = Math.min(g2.min ?? z2, z2, W2 ? L2 : z2), X2 = Math.max(g2.max ?? N2, N2, W2 ? O2 : N2);
13608              (!t4.isOrdinal || t4.options.overscroll || 1 !== v2 || r2) && (M2 < G2 && (M2 = G2, v2 >= 1 && (w2 = M2 + j2)), w2 > X2 && (w2 = X2, v2 >= 1 && (M2 = w2 - j2)), (r2 || t4.series.length && (M2 !== L2 || w2 !== O2) && M2 >= G2 && w2 <= X2) && (o2 ? o2[t4.coll].push({
13609                axis: t4,
13610                min: M2,
13611                max: w2
13612              }) : (t4.isPanning = "zoom" !== a2, t4.isPanning && (c2 = true), t4.setExtremes(r2 ? void 0 : M2, r2 ? void 0 : w2, false, false, {
13613                move: C2,
13614                trigger: a2,
13615                scale: v2
13616              }), !r2 && (M2 > G2 || w2 < X2) && "mousewheel" !== a2 && (d2 = true)), l2 = true), i3 && (this[e4 ? "mouseDownX" : "mouseDownY"] = i3[e4 ? "chartX" : "chartY"]));
13617            }
13618            return l2 && (o2 ? N(this, "selection", o2, () => {
13619              delete t3.selection, t3.trigger = "zoom", this.transform(t3);
13620            }) : (!d2 || c2 || this.resetZoomButton ? !d2 && this.resetZoomButton && (this.resetZoomButton = this.resetZoomButton.destroy()) : this.showResetZoom(), this.redraw("zoom" === a2 && (this.options.chart.animation ?? this.pointCount < 100)))), l2;
13621          }
13622        }
13623        return R(Q.prototype, {
13624          callbacks: [],
13625          collectionsWithInit: {
13626            xAxis: [Q.prototype.addAxis, [true]],
13627            yAxis: [Q.prototype.addAxis, [false]],
13628            series: [Q.prototype.addSeries]
13629          },
13630          collectionsWithUpdate: ["xAxis", "yAxis", "series"],
13631          propsRequireDirtyBox: ["backgroundColor", "borderColor", "borderWidth", "borderRadius", "plotBackgroundColor", "plotBackgroundImage", "plotBorderColor", "plotBorderWidth", "plotShadow", "shadow"],
13632          propsRequireReflow: ["margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "spacing", "spacingTop", "spacingRight", "spacingBottom", "spacingLeft"],
13633          propsRequireUpdateSeries: ["chart.inverted", "chart.polar", "chart.ignoreHiddenSeries", "chart.type", "colors", "plotOptions", "time", "tooltip"]
13634        }), Q;
13635      }), i(e, "Extensions/ScrollablePlotArea.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Globals.js"], e["Core/Renderer/RendererRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
13636        let {
13637          stop: r
13638        } = t2, {
13639          composed: o
13640        } = e2, {
13641          addEvent: n,
13642          createElement: a,
13643          css: h,
13644          defined: l,
13645          merge: d,
13646          pushUnique: c
13647        } = s;
13648        function p() {
13649          let t3 = this.scrollablePlotArea;
13650          (this.scrollablePixelsX || this.scrollablePixelsY) && !t3 && (this.scrollablePlotArea = t3 = new g(this)), t3?.applyFixed();
13651        }
13652        function u11() {
13653          this.chart.scrollablePlotArea && (this.chart.scrollablePlotArea.isDirty = true);
13654        }
13655        class g {
13656          static compose(t3, e3, i3) {
13657            c(o, this.compose) && (n(t3, "afterInit", u11), n(e3, "afterSetChartSize", (t4) => this.afterSetSize(t4.target, t4)), n(e3, "render", p), n(i3, "show", u11));
13658          }
13659          static afterSetSize(t3, e3) {
13660            let i3, s2, r2;
13661            let {
13662              minWidth: o2,
13663              minHeight: n2
13664            } = t3.options.chart.scrollablePlotArea || {}, {
13665              clipBox: a2,
13666              plotBox: h2,
13667              inverted: c2,
13668              renderer: p2
13669            } = t3;
13670            if (!p2.forExport && (o2 ? (t3.scrollablePixelsX = i3 = Math.max(0, o2 - t3.chartWidth), i3 && (t3.scrollablePlotBox = d(t3.plotBox), h2.width = t3.plotWidth += i3, a2[c2 ? "height" : "width"] += i3, r2 = true)) : n2 && (t3.scrollablePixelsY = s2 = Math.max(0, n2 - t3.chartHeight), l(s2) && (t3.scrollablePlotBox = d(t3.plotBox), h2.height = t3.plotHeight += s2, a2[c2 ? "width" : "height"] += s2, r2 = false)), l(r2) && !e3.skipAxes)) for (let e4 of t3.axes) e4.horiz === r2 && (e4.setAxisSize(), e4.setAxisTranslation());
13671          }
13672          constructor(t3) {
13673            let e3;
13674            let s2 = t3.options.chart, r2 = i2.getRendererType(), o2 = s2.scrollablePlotArea || {}, l2 = this.moveFixedElements.bind(this), d2 = {
13675              WebkitOverflowScrolling: "touch",
13676              overflowX: "hidden",
13677              overflowY: "hidden"
13678            };
13679            t3.scrollablePixelsX && (d2.overflowX = "auto"), t3.scrollablePixelsY && (d2.overflowY = "auto"), this.chart = t3;
13680            let c2 = this.parentDiv = a("div", {
13681              className: "highcharts-scrolling-parent"
13682            }, {
13683              position: "relative"
13684            }, t3.renderTo), p2 = this.scrollingContainer = a("div", {
13685              className: "highcharts-scrolling"
13686            }, d2, c2), u12 = this.innerContainer = a("div", {
13687              className: "highcharts-inner-container"
13688            }, void 0, p2), g2 = this.fixedDiv = a("div", {
13689              className: "highcharts-fixed"
13690            }, {
13691              position: "absolute",
13692              overflow: "hidden",
13693              pointerEvents: "none",
13694              zIndex: (s2.style?.zIndex || 0) + 2,
13695              top: 0
13696            }, void 0, true), f = this.fixedRenderer = new r2(g2, t3.chartWidth, t3.chartHeight, s2.style);
13697            this.mask = f.path().attr({
13698              fill: s2.backgroundColor || "#fff",
13699              "fill-opacity": o2.opacity ?? 0.85,
13700              zIndex: -1
13701            }).addClass("highcharts-scrollable-mask").add(), p2.parentNode.insertBefore(g2, p2), h(t3.renderTo, {
13702              overflow: "visible"
13703            }), n(t3, "afterShowResetZoom", l2), n(t3, "afterApplyDrilldown", l2), n(t3, "afterLayOutTitles", l2), n(p2, "scroll", () => {
13704              let {
13705                pointer: i3,
13706                hoverPoint: s3
13707              } = t3;
13708              i3 && (delete i3.chartPosition, s3 && (e3 = s3), i3.runPointActions(void 0, e3, true));
13709            }), u12.appendChild(t3.container);
13710          }
13711          applyFixed() {
13712            let {
13713              chart: t3,
13714              fixedRenderer: e3,
13715              isDirty: i3,
13716              scrollingContainer: s2
13717            } = this, {
13718              axisOffset: o2,
13719              chartWidth: n2,
13720              chartHeight: a2,
13721              container: d2,
13722              plotHeight: c2,
13723              plotLeft: p2,
13724              plotTop: u12,
13725              plotWidth: g2,
13726              scrollablePixelsX: f = 0,
13727              scrollablePixelsY: m = 0
13728            } = t3, {
13729              scrollPositionX: x = 0,
13730              scrollPositionY: y = 0
13731            } = t3.options.chart.scrollablePlotArea || {}, b = n2 + f, v = a2 + m;
13732            e3.setSize(n2, a2), (i3 ?? true) && (this.isDirty = false, this.moveFixedElements()), r(t3.container), h(d2, {
13733              width: `${b}px`,
13734              height: `${v}px`
13735            }), t3.renderer.boxWrapper.attr({
13736              width: b,
13737              height: v,
13738              viewBox: [0, 0, b, v].join(" ")
13739            }), t3.chartBackground?.attr({
13740              width: b,
13741              height: v
13742            }), h(s2, {
13743              width: `${n2}px`,
13744              height: `${a2}px`
13745            }), l(i3) || (s2.scrollLeft = f * x, s2.scrollTop = m * y);
13746            let S2 = u12 - o2[0] - 1, C = p2 - o2[3] - 1, k = u12 + c2 + o2[2] + 1, M = p2 + g2 + o2[1] + 1, w = p2 + g2 - f, T2 = u12 + c2 - m, A = [["M", 0, 0]];
13747            f ? A = [["M", 0, S2], ["L", p2 - 1, S2], ["L", p2 - 1, k], ["L", 0, k], ["Z"], ["M", w, S2], ["L", n2, S2], ["L", n2, k], ["L", w, k], ["Z"]] : m && (A = [["M", C, 0], ["L", C, u12 - 1], ["L", M, u12 - 1], ["L", M, 0], ["Z"], ["M", C, T2], ["L", C, a2], ["L", M, a2], ["L", M, T2], ["Z"]]), "adjustHeight" !== t3.redrawTrigger && this.mask.attr({
13748              d: A
13749            });
13750          }
13751          moveFixedElements() {
13752            let t3;
13753            let {
13754              container: e3,
13755              inverted: i3,
13756              scrollablePixelsX: s2,
13757              scrollablePixelsY: r2
13758            } = this.chart, o2 = this.fixedRenderer, n2 = g.fixedSelectors;
13759            for (let a2 of (s2 && !i3 ? t3 = ".highcharts-yaxis" : s2 && i3 ? t3 = ".highcharts-xaxis" : r2 && !i3 ? t3 = ".highcharts-xaxis" : r2 && i3 && (t3 = ".highcharts-yaxis"), t3 && n2.push(`${t3}:not(.highcharts-radial-axis)`, `${t3}-labels:not(.highcharts-radial-axis-labels)`), n2)) [].forEach.call(e3.querySelectorAll(a2), (t4) => {
13760              (t4.namespaceURI === o2.SVG_NS ? o2.box : o2.box.parentNode).appendChild(t4), t4.style.pointerEvents = "auto";
13761            });
13762          }
13763        }
13764        return g.fixedSelectors = [".highcharts-breadcrumbs-group", ".highcharts-contextbutton", ".highcharts-caption", ".highcharts-credits", ".highcharts-drillup-button", ".highcharts-legend", ".highcharts-legend-checkbox", ".highcharts-navigator-series", ".highcharts-navigator-xaxis", ".highcharts-navigator-yaxis", ".highcharts-navigator", ".highcharts-range-selector-group", ".highcharts-reset-zoom", ".highcharts-scrollbar", ".highcharts-subtitle", ".highcharts-title"], g;
13765      }), i(e, "Core/Axis/Stacking/StackItem.js", [e["Core/Templating.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
13766        let {
13767          format: s
13768        } = t2, {
13769          series: r
13770        } = e2, {
13771          destroyObjectProperties: o,
13772          fireEvent: n,
13773          isNumber: a,
13774          pick: h
13775        } = i2;
13776        return class {
13777          constructor(t3, e3, i3, s2, r2) {
13778            let o2 = t3.chart.inverted, n2 = t3.reversed;
13779            this.axis = t3;
13780            let a2 = this.isNegative = !!i3 != !!n2;
13781            this.options = e3 = e3 || {}, this.x = s2, this.total = null, this.cumulative = null, this.points = {}, this.hasValidPoints = false, this.stack = r2, this.leftCliff = 0, this.rightCliff = 0, this.alignOptions = {
13782              align: e3.align || (o2 ? a2 ? "left" : "right" : "center"),
13783              verticalAlign: e3.verticalAlign || (o2 ? "middle" : a2 ? "bottom" : "top"),
13784              y: e3.y,
13785              x: e3.x
13786            }, this.textAlign = e3.textAlign || (o2 ? a2 ? "right" : "left" : "center");
13787          }
13788          destroy() {
13789            o(this, this.axis);
13790          }
13791          render(t3) {
13792            let e3 = this.axis.chart, i3 = this.options, r2 = i3.format, o2 = r2 ? s(r2, this, e3) : i3.formatter.call(this);
13793            if (this.label) this.label.attr({
13794              text: o2,
13795              visibility: "hidden"
13796            });
13797            else {
13798              this.label = e3.renderer.label(o2, null, void 0, i3.shape, void 0, void 0, i3.useHTML, false, "stack-labels");
13799              let s2 = {
13800                r: i3.borderRadius || 0,
13801                text: o2,
13802                padding: h(i3.padding, 5),
13803                visibility: "hidden"
13804              };
13805              e3.styledMode || (s2.fill = i3.backgroundColor, s2.stroke = i3.borderColor, s2["stroke-width"] = i3.borderWidth, this.label.css(i3.style || {})), this.label.attr(s2), this.label.added || this.label.add(t3);
13806            }
13807            this.label.labelrank = e3.plotSizeY, n(this, "afterRender");
13808          }
13809          setOffset(t3, e3, i3, s2, o2, l) {
13810            let {
13811              alignOptions: d,
13812              axis: c,
13813              label: p,
13814              options: u11,
13815              textAlign: g
13816            } = this, f = c.chart, m = this.getStackBox({
13817              xOffset: t3,
13818              width: e3,
13819              boxBottom: i3,
13820              boxTop: s2,
13821              defaultX: o2,
13822              xAxis: l
13823            }), {
13824              verticalAlign: x
13825            } = d;
13826            if (p && m) {
13827              let t4 = p.getBBox(void 0, 0), e4 = p.padding, i4 = "justify" === h(u11.overflow, "justify"), s3;
13828              d.x = u11.x || 0, d.y = u11.y || 0;
13829              let {
13830                x: o3,
13831                y: n2
13832              } = this.adjustStackPosition({
13833                labelBox: t4,
13834                verticalAlign: x,
13835                textAlign: g
13836              });
13837              m.x -= o3, m.y -= n2, p.align(d, false, m), (s3 = f.isInsidePlot(p.alignAttr.x + d.x + o3, p.alignAttr.y + d.y + n2)) || (i4 = false), i4 && r.prototype.justifyDataLabel.call(c, p, d, p.alignAttr, t4, m), p.attr({
13838                x: p.alignAttr.x,
13839                y: p.alignAttr.y,
13840                rotation: u11.rotation,
13841                rotationOriginX: t4.width * {
13842                  left: 0,
13843                  center: 0.5,
13844                  right: 1
13845                }[u11.textAlign || "center"],
13846                rotationOriginY: t4.height / 2
13847              }), h(!i4 && u11.crop, true) && (s3 = a(p.x) && a(p.y) && f.isInsidePlot(p.x - e4 + (p.width || 0), p.y) && f.isInsidePlot(p.x + e4, p.y)), p[s3 ? "show" : "hide"]();
13848            }
13849            n(this, "afterSetOffset", {
13850              xOffset: t3,
13851              width: e3
13852            });
13853          }
13854          adjustStackPosition({
13855            labelBox: t3,
13856            verticalAlign: e3,
13857            textAlign: i3
13858          }) {
13859            let s2 = {
13860              bottom: 0,
13861              middle: 1,
13862              top: 2,
13863              right: 1,
13864              center: 0,
13865              left: -1
13866            }, r2 = s2[e3], o2 = s2[i3];
13867            return {
13868              x: t3.width / 2 + t3.width / 2 * o2,
13869              y: t3.height / 2 * r2
13870            };
13871          }
13872          getStackBox(t3) {
13873            let e3 = this.axis, i3 = e3.chart, {
13874              boxTop: s2,
13875              defaultX: r2,
13876              xOffset: o2,
13877              width: n2,
13878              boxBottom: l
13879            } = t3, d = e3.stacking.usePercentage ? 100 : h(s2, this.total, 0), c = e3.toPixels(d), p = t3.xAxis || i3.xAxis[0], u11 = h(r2, p.translate(this.x)) + o2, g = Math.abs(c - e3.toPixels(l || a(e3.min) && e3.logarithmic && e3.logarithmic.lin2log(e3.min) || 0)), f = i3.inverted, m = this.isNegative;
13880            return f ? {
13881              x: (m ? c : c - g) - i3.plotLeft,
13882              y: p.height - u11 - n2 + p.top - i3.plotTop,
13883              width: g,
13884              height: n2
13885            } : {
13886              x: u11 + p.transB - i3.plotLeft,
13887              y: (m ? c - g : c) - i3.plotTop,
13888              width: n2,
13889              height: g
13890            };
13891          }
13892        };
13893      }), i(e, "Core/Axis/Stacking/StackingAxis.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Axis/Axis.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Axis/Stacking/StackItem.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, r) {
13894        var o;
13895        let {
13896          getDeferredAnimation: n
13897        } = t2, {
13898          series: {
13899            prototype: a
13900          }
13901        } = i2, {
13902          addEvent: h,
13903          correctFloat: l,
13904          defined: d,
13905          destroyObjectProperties: c,
13906          fireEvent: p,
13907          isArray: u11,
13908          isNumber: g,
13909          objectEach: f,
13910          pick: m
13911        } = r;
13912        function x() {
13913          let t3 = this.inverted;
13914          this.axes.forEach((t4) => {
13915            t4.stacking && t4.stacking.stacks && t4.hasVisibleSeries && (t4.stacking.oldStacks = t4.stacking.stacks);
13916          }), this.series.forEach((e3) => {
13917            let i3 = e3.xAxis && e3.xAxis.options || {};
13918            e3.options.stacking && e3.reserveSpace() && (e3.stackKey = [e3.type, m(e3.options.stack, ""), t3 ? i3.top : i3.left, t3 ? i3.height : i3.width].join(","));
13919          });
13920        }
13921        function y() {
13922          let t3 = this.stacking;
13923          if (t3) {
13924            let e3 = t3.stacks;
13925            f(e3, (t4, i3) => {
13926              c(t4), delete e3[i3];
13927            }), t3.stackTotalGroup?.destroy();
13928          }
13929        }
13930        function b() {
13931          this.stacking || (this.stacking = new w(this));
13932        }
13933        function v(t3, e3, i3, s2) {
13934          return !d(t3) || t3.x !== e3 || s2 && t3.stackKey !== s2 ? t3 = {
13935            x: e3,
13936            index: 0,
13937            key: s2,
13938            stackKey: s2
13939          } : t3.index++, t3.key = [i3, e3, t3.index].join(","), t3;
13940        }
13941        function S2() {
13942          let t3;
13943          let e3 = this, i3 = e3.yAxis, s2 = e3.stackKey || "", r2 = i3.stacking.stacks, o2 = e3.processedXData, n2 = e3.options.stacking, a2 = e3[n2 + "Stacker"];
13944          a2 && [s2, "-" + s2].forEach((i4) => {
13945            let s3 = o2.length, n3, h2, l2;
13946            for (; s3--; ) n3 = o2[s3], t3 = e3.getStackIndicator(t3, n3, e3.index, i4), h2 = r2[i4]?.[n3], (l2 = h2?.points[t3.key || ""]) && a2.call(e3, l2, h2, s3);
13947          });
13948        }
13949        function C(t3, e3, i3) {
13950          let s2 = e3.total ? 100 / e3.total : 0;
13951          t3[0] = l(t3[0] * s2), t3[1] = l(t3[1] * s2), this.stackedYData[i3] = t3[1];
13952        }
13953        function k(t3) {
13954          (this.is("column") || this.is("columnrange")) && (this.options.centerInCategory && !this.options.stacking && this.chart.series.length > 1 ? a.setStackedPoints.call(this, t3, "group") : t3.stacking.resetStacks());
13955        }
13956        function M(t3, e3) {
13957          let i3, r2, o2, n2, a2, h2, c2, p2, g2;
13958          let f2 = e3 || this.options.stacking;
13959          if (!f2 || !this.reserveSpace() || ({
13960            group: "xAxis"
13961          }[f2] || "yAxis") !== t3.coll) return;
13962          let x2 = this.processedXData, y2 = this.processedYData, b2 = [], v2 = y2.length, S3 = this.options, C2 = S3.threshold || 0, k2 = S3.startFromThreshold ? C2 : 0, M2 = S3.stack, w2 = e3 ? `${this.type},${f2}` : this.stackKey || "", T2 = "-" + w2, A = this.negStacks, P = t3.stacking, L = P.stacks, O = P.oldStacks;
13963          for (P.stacksTouched += 1, c2 = 0; c2 < v2; c2++) {
13964            p2 = x2[c2], g2 = y2[c2], h2 = (i3 = this.getStackIndicator(i3, p2, this.index)).key || "", L[a2 = (r2 = A && g2 < (k2 ? 0 : C2)) ? T2 : w2] || (L[a2] = {}), L[a2][p2] || (O[a2]?.[p2] ? (L[a2][p2] = O[a2][p2], L[a2][p2].total = null) : L[a2][p2] = new s(t3, t3.options.stackLabels, !!r2, p2, M2)), o2 = L[a2][p2], null !== g2 ? (o2.points[h2] = o2.points[this.index] = [m(o2.cumulative, k2)], d(o2.cumulative) || (o2.base = h2), o2.touched = P.stacksTouched, i3.index > 0 && false === this.singleStacks && (o2.points[h2][0] = o2.points[this.index + "," + p2 + ",0"][0])) : (delete o2.points[h2], delete o2.points[this.index]);
13965            let e4 = o2.total || 0;
13966            "percent" === f2 ? (n2 = r2 ? w2 : T2, e4 = A && L[n2]?.[p2] ? (n2 = L[n2][p2]).total = Math.max(n2.total || 0, e4) + Math.abs(g2) || 0 : l(e4 + (Math.abs(g2) || 0))) : "group" === f2 ? (u11(g2) && (g2 = g2[0]), null !== g2 && e4++) : e4 = l(e4 + (g2 || 0)), "group" === f2 ? o2.cumulative = (e4 || 1) - 1 : o2.cumulative = l(m(o2.cumulative, k2) + (g2 || 0)), o2.total = e4, null !== g2 && (o2.points[h2].push(o2.cumulative), b2[c2] = o2.cumulative, o2.hasValidPoints = true);
13967          }
13968          "percent" === f2 && (P.usePercentage = true), "group" !== f2 && (this.stackedYData = b2), P.oldStacks = {};
13969        }
13970        class w {
13971          constructor(t3) {
13972            this.oldStacks = {}, this.stacks = {}, this.stacksTouched = 0, this.axis = t3;
13973          }
13974          buildStacks() {
13975            let t3, e3;
13976            let i3 = this.axis, s2 = i3.series, r2 = "xAxis" === i3.coll, o2 = i3.options.reversedStacks, n2 = s2.length;
13977            for (this.resetStacks(), this.usePercentage = false, e3 = n2; e3--; ) t3 = s2[o2 ? e3 : n2 - e3 - 1], r2 && t3.setGroupedPoints(i3), t3.setStackedPoints(i3);
13978            if (!r2) for (e3 = 0; e3 < n2; e3++) s2[e3].modifyStacks();
13979            p(i3, "afterBuildStacks");
13980          }
13981          cleanStacks() {
13982            this.oldStacks && (this.stacks = this.oldStacks, f(this.stacks, (t3) => {
13983              f(t3, (t4) => {
13984                t4.cumulative = t4.total;
13985              });
13986            }));
13987          }
13988          resetStacks() {
13989            f(this.stacks, (t3) => {
13990              f(t3, (e3, i3) => {
13991                g(e3.touched) && e3.touched < this.stacksTouched ? (e3.destroy(), delete t3[i3]) : (e3.total = null, e3.cumulative = null);
13992              });
13993            });
13994          }
13995          renderStackTotals() {
13996            let t3 = this.axis, e3 = t3.chart, i3 = e3.renderer, s2 = this.stacks, r2 = n(e3, t3.options.stackLabels?.animation || false), o2 = this.stackTotalGroup = this.stackTotalGroup || i3.g("stack-labels").attr({
13997              zIndex: 6,
13998              opacity: 0
13999            }).add();
14000            o2.translate(e3.plotLeft, e3.plotTop), f(s2, (t4) => {
14001              f(t4, (t5) => {
14002                t5.render(o2);
14003              });
14004            }), o2.animate({
14005              opacity: 1
14006            }, r2);
14007          }
14008        }
14009        return (o || (o = {})).compose = function(t3, e3, i3) {
14010          let s2 = e3.prototype, r2 = i3.prototype;
14011          s2.getStacks || (h(t3, "init", b), h(t3, "destroy", y), s2.getStacks = x, r2.getStackIndicator = v, r2.modifyStacks = S2, r2.percentStacker = C, r2.setGroupedPoints = k, r2.setStackedPoints = M);
14012        }, o;
14013      }), i(e, "Series/Line/LineSeries.js", [e["Core/Series/Series.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
14014        let {
14015          defined: s,
14016          merge: r,
14017          isObject: o
14018        } = i2;
14019        class n extends t2 {
14020          drawGraph() {
14021            let t3 = this.options, e3 = (this.gappedPath || this.getGraphPath).call(this), i3 = this.chart.styledMode;
14022            [this, ...this.zones].forEach((s2, n2) => {
14023              let a, h = s2.graph, l = h ? "animate" : "attr", d = s2.dashStyle || t3.dashStyle;
14024              h ? (h.endX = this.preventGraphAnimation ? null : e3.xMap, h.animate({
14025                d: e3
14026              })) : e3.length && (s2.graph = h = this.chart.renderer.path(e3).addClass("highcharts-graph" + (n2 ? ` highcharts-zone-graph-${n2 - 1} ` : " ") + (n2 && s2.className || "")).attr({
14027                zIndex: 1
14028              }).add(this.group)), h && !i3 && (a = {
14029                stroke: !n2 && t3.lineColor || s2.color || this.color || "#cccccc",
14030                "stroke-width": t3.lineWidth || 0,
14031                fill: this.fillGraph && this.color || "none"
14032              }, d ? a.dashstyle = d : "square" !== t3.linecap && (a["stroke-linecap"] = a["stroke-linejoin"] = "round"), h[l](a).shadow(n2 < 2 && t3.shadow && r({
14033                filterUnits: "userSpaceOnUse"
14034              }, o(t3.shadow) ? t3.shadow : {}))), h && (h.startX = e3.xMap, h.isArea = e3.isArea);
14035            });
14036          }
14037          getGraphPath(t3, e3, i3) {
14038            let r2 = this, o2 = r2.options, n2 = [], a = [], h, l = o2.step, d = (t3 = t3 || r2.points).reversed;
14039            return d && t3.reverse(), (l = {
14040              right: 1,
14041              center: 2
14042            }[l] || l && 3) && d && (l = 4 - l), (t3 = this.getValidPoints(t3, false, !(o2.connectNulls && !e3 && !i3))).forEach(function(d2, c) {
14043              let p;
14044              let u11 = d2.plotX, g = d2.plotY, f = t3[c - 1], m = d2.isNull || "number" != typeof g;
14045              (d2.leftCliff || f && f.rightCliff) && !i3 && (h = true), m && !s(e3) && c > 0 ? h = !o2.connectNulls : m && !e3 ? h = true : (0 === c || h ? p = [["M", d2.plotX, d2.plotY]] : r2.getPointSpline ? p = [r2.getPointSpline(t3, d2, c)] : l ? (p = 1 === l ? [["L", f.plotX, g]] : 2 === l ? [["L", (f.plotX + u11) / 2, f.plotY], ["L", (f.plotX + u11) / 2, g]] : [["L", u11, f.plotY]]).push(["L", u11, g]) : p = [["L", u11, g]], a.push(d2.x), l && (a.push(d2.x), 2 === l && a.push(d2.x)), n2.push.apply(n2, p), h = false);
14046            }), n2.xMap = a, r2.graphPath = n2, n2;
14047          }
14048        }
14049        return n.defaultOptions = r(t2.defaultOptions, {
14050          legendSymbol: "lineMarker"
14051        }), e2.registerSeriesType("line", n), n;
14052      }), i(e, "Series/Area/AreaSeriesDefaults.js", [], function() {
14053        return {
14054          threshold: 0,
14055          legendSymbol: "areaMarker"
14056        };
14057      }), i(e, "Series/Area/AreaSeries.js", [e["Series/Area/AreaSeriesDefaults.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
14058        let {
14059          seriesTypes: {
14060            line: s
14061          }
14062        } = e2, {
14063          extend: r,
14064          merge: o,
14065          objectEach: n,
14066          pick: a
14067        } = i2;
14068        class h extends s {
14069          drawGraph() {
14070            this.areaPath = [], super.drawGraph.apply(this);
14071            let {
14072              areaPath: t3,
14073              options: e3
14074            } = this;
14075            [this, ...this.zones].forEach((i3, s2) => {
14076              let r2 = {}, o2 = i3.fillColor || e3.fillColor, n2 = i3.area, a2 = n2 ? "animate" : "attr";
14077              n2 ? (n2.endX = this.preventGraphAnimation ? null : t3.xMap, n2.animate({
14078                d: t3
14079              })) : (r2.zIndex = 0, (n2 = i3.area = this.chart.renderer.path(t3).addClass("highcharts-area" + (s2 ? ` highcharts-zone-area-${s2 - 1} ` : " ") + (s2 && i3.className || "")).add(this.group)).isArea = true), this.chart.styledMode || (r2.fill = o2 || i3.color || this.color, r2["fill-opacity"] = o2 ? 1 : e3.fillOpacity ?? 0.75, n2.css({
14080                pointerEvents: this.stickyTracking ? "none" : "auto"
14081              })), n2[a2](r2), n2.startX = t3.xMap, n2.shiftUnit = e3.step ? 2 : 1;
14082            });
14083          }
14084          getGraphPath(t3) {
14085            let e3, i3, r2;
14086            let o2 = s.prototype.getGraphPath, n2 = this.options, h2 = n2.stacking, l = this.yAxis, d = [], c = [], p = this.index, u11 = l.stacking.stacks[this.stackKey], g = n2.threshold, f = Math.round(l.getThreshold(n2.threshold)), m = a(n2.connectNulls, "percent" === h2), x = function(i4, s2, r3) {
14087              let o3 = t3[i4], n3 = h2 && u11[o3.x].points[p], a2 = o3[r3 + "Null"] || 0, m2 = o3[r3 + "Cliff"] || 0, x2, y2, b2 = true;
14088              m2 || a2 ? (x2 = (a2 ? n3[0] : n3[1]) + m2, y2 = n3[0] + m2, b2 = !!a2) : !h2 && t3[s2] && t3[s2].isNull && (x2 = y2 = g), void 0 !== x2 && (c.push({
14089                plotX: e3,
14090                plotY: null === x2 ? f : l.getThreshold(x2),
14091                isNull: b2,
14092                isCliff: true
14093              }), d.push({
14094                plotX: e3,
14095                plotY: null === y2 ? f : l.getThreshold(y2),
14096                doCurve: false
14097              }));
14098            };
14099            t3 = t3 || this.points, h2 && (t3 = this.getStackPoints(t3));
14100            for (let s2 = 0, o3 = t3.length; s2 < o3; ++s2) h2 || (t3[s2].leftCliff = t3[s2].rightCliff = t3[s2].leftNull = t3[s2].rightNull = void 0), i3 = t3[s2].isNull, e3 = a(t3[s2].rectPlotX, t3[s2].plotX), r2 = h2 ? a(t3[s2].yBottom, f) : f, i3 && !m || (m || x(s2, s2 - 1, "left"), i3 && !h2 && m || (c.push(t3[s2]), d.push({
14101              x: s2,
14102              plotX: e3,
14103              plotY: r2
14104            })), m || x(s2, s2 + 1, "right"));
14105            let y = o2.call(this, c, true, true);
14106            d.reversed = true;
14107            let b = o2.call(this, d, true, true), v = b[0];
14108            v && "M" === v[0] && (b[0] = ["L", v[1], v[2]]);
14109            let S2 = y.concat(b);
14110            S2.length && S2.push(["Z"]);
14111            let C = o2.call(this, c, false, m);
14112            return this.chart.series.length > 1 && h2 && c.some((t4) => t4.isCliff) && (S2.hasStackedCliffs = C.hasStackedCliffs = true), S2.xMap = y.xMap, this.areaPath = S2, C;
14113          }
14114          getStackPoints(t3) {
14115            let e3 = this, i3 = [], s2 = [], r2 = this.xAxis, o2 = this.yAxis, h2 = o2.stacking.stacks[this.stackKey], l = {}, d = o2.series, c = d.length, p = o2.options.reversedStacks ? 1 : -1, u11 = d.indexOf(e3);
14116            if (t3 = t3 || this.points, this.options.stacking) {
14117              for (let e4 = 0; e4 < t3.length; e4++) t3[e4].leftNull = t3[e4].rightNull = void 0, l[t3[e4].x] = t3[e4];
14118              n(h2, function(t4, e4) {
14119                null !== t4.total && s2.push(e4);
14120              }), s2.sort(function(t4, e4) {
14121                return t4 - e4;
14122              });
14123              let g = d.map((t4) => t4.visible);
14124              s2.forEach(function(t4, n2) {
14125                let f = 0, m, x;
14126                if (l[t4] && !l[t4].isNull) i3.push(l[t4]), [-1, 1].forEach(function(i4) {
14127                  let r3 = 1 === i4 ? "rightNull" : "leftNull", o3 = h2[s2[n2 + i4]], a2 = 0;
14128                  if (o3) {
14129                    let i5 = u11;
14130                    for (; i5 >= 0 && i5 < c; ) {
14131                      let s3 = d[i5].index;
14132                      !(m = o3.points[s3]) && (s3 === e3.index ? l[t4][r3] = true : g[i5] && (x = h2[t4].points[s3]) && (a2 -= x[1] - x[0])), i5 += p;
14133                    }
14134                  }
14135                  l[t4][1 === i4 ? "rightCliff" : "leftCliff"] = a2;
14136                });
14137                else {
14138                  let e4 = u11;
14139                  for (; e4 >= 0 && e4 < c; ) {
14140                    let i4 = d[e4].index;
14141                    if (m = h2[t4].points[i4]) {
14142                      f = m[1];
14143                      break;
14144                    }
14145                    e4 += p;
14146                  }
14147                  f = a(f, 0), f = o2.translate(f, 0, 1, 0, 1), i3.push({
14148                    isNull: true,
14149                    plotX: r2.translate(t4, 0, 0, 0, 1),
14150                    x: t4,
14151                    plotY: f,
14152                    yBottom: f
14153                  });
14154                }
14155              });
14156            }
14157            return i3;
14158          }
14159        }
14160        return h.defaultOptions = o(s.defaultOptions, t2), r(h.prototype, {
14161          singleStacks: false
14162        }), e2.registerSeriesType("area", h), h;
14163      }), i(e, "Series/Spline/SplineSeries.js", [e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2) {
14164        let {
14165          line: i2
14166        } = t2.seriesTypes, {
14167          merge: s,
14168          pick: r
14169        } = e2;
14170        class o extends i2 {
14171          getPointSpline(t3, e3, i3) {
14172            let s2, o2, n, a;
14173            let h = e3.plotX || 0, l = e3.plotY || 0, d = t3[i3 - 1], c = t3[i3 + 1];
14174            function p(t4) {
14175              return t4 && !t4.isNull && false !== t4.doCurve && !e3.isCliff;
14176            }
14177            if (p(d) && p(c)) {
14178              let t4 = d.plotX || 0, i4 = d.plotY || 0, r2 = c.plotX || 0, p2 = c.plotY || 0, u12 = 0;
14179              s2 = (1.5 * h + t4) / 2.5, o2 = (1.5 * l + i4) / 2.5, n = (1.5 * h + r2) / 2.5, a = (1.5 * l + p2) / 2.5, n !== s2 && (u12 = (a - o2) * (n - h) / (n - s2) + l - a), o2 += u12, a += u12, o2 > i4 && o2 > l ? (o2 = Math.max(i4, l), a = 2 * l - o2) : o2 < i4 && o2 < l && (o2 = Math.min(i4, l), a = 2 * l - o2), a > p2 && a > l ? (a = Math.max(p2, l), o2 = 2 * l - a) : a < p2 && a < l && (a = Math.min(p2, l), o2 = 2 * l - a), e3.rightContX = n, e3.rightContY = a, e3.controlPoints = {
14180                low: [s2, o2],
14181                high: [n, a]
14182              };
14183            }
14184            let u11 = ["C", r(d.rightContX, d.plotX, 0), r(d.rightContY, d.plotY, 0), r(s2, h, 0), r(o2, l, 0), h, l];
14185            return d.rightContX = d.rightContY = void 0, u11;
14186          }
14187        }
14188        return o.defaultOptions = s(i2.defaultOptions), t2.registerSeriesType("spline", o), o;
14189      }), i(e, "Series/AreaSpline/AreaSplineSeries.js", [e["Series/Spline/SplineSeries.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
14190        let {
14191          area: s,
14192          area: {
14193            prototype: r
14194          }
14195        } = e2.seriesTypes, {
14196          extend: o,
14197          merge: n
14198        } = i2;
14199        class a extends t2 {
14200        }
14201        return a.defaultOptions = n(t2.defaultOptions, s.defaultOptions), o(a.prototype, {
14202          getGraphPath: r.getGraphPath,
14203          getStackPoints: r.getStackPoints,
14204          drawGraph: r.drawGraph
14205        }), e2.registerSeriesType("areaspline", a), a;
14206      }), i(e, "Series/Column/ColumnSeriesDefaults.js", [], function() {
14207        return {
14208          borderRadius: 3,
14209          centerInCategory: false,
14210          groupPadding: 0.2,
14211          marker: null,
14212          pointPadding: 0.1,
14213          minPointLength: 0,
14214          cropThreshold: 50,
14215          pointRange: null,
14216          states: {
14217            hover: {
14218              halo: false,
14219              brightness: 0.1
14220            },
14221            select: {
14222              color: "#cccccc",
14223              borderColor: "#000000"
14224            }
14225          },
14226          dataLabels: {
14227            align: void 0,
14228            verticalAlign: void 0,
14229            y: void 0
14230          },
14231          startFromThreshold: true,
14232          stickyTracking: false,
14233          tooltip: {
14234            distance: 6
14235          },
14236          threshold: 0,
14237          borderColor: "#ffffff"
14238        };
14239      }), i(e, "Series/Column/ColumnSeries.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Color/Color.js"], e["Series/Column/ColumnSeriesDefaults.js"], e["Core/Globals.js"], e["Core/Series/Series.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, r, o, n) {
14240        let {
14241          animObject: a
14242        } = t2, {
14243          parse: h
14244        } = e2, {
14245          noop: l
14246        } = s, {
14247          clamp: d,
14248          crisp: c,
14249          defined: p,
14250          extend: u11,
14251          fireEvent: g,
14252          isArray: f,
14253          isNumber: m,
14254          merge: x,
14255          pick: y,
14256          objectEach: b
14257        } = n;
14258        class v extends r {
14259          animate(t3) {
14260            let e3, i3;
14261            let s2 = this, r2 = this.yAxis, o2 = r2.pos, n2 = r2.reversed, h2 = s2.options, {
14262              clipOffset: l2,
14263              inverted: c2
14264            } = this.chart, p2 = {}, g2 = c2 ? "translateX" : "translateY";
14265            t3 && l2 ? (p2.scaleY = 1e-3, i3 = d(r2.toPixels(h2.threshold), o2, o2 + r2.len), c2 ? (i3 += n2 ? -Math.floor(l2[0]) : Math.ceil(l2[2]), p2.translateX = i3 - r2.len) : (i3 += n2 ? Math.ceil(l2[0]) : -Math.floor(l2[2]), p2.translateY = i3), s2.clipBox && s2.setClip(), s2.group.attr(p2)) : (e3 = Number(s2.group.attr(g2)), s2.group.animate({
14266              scaleY: 1
14267            }, u11(a(s2.options.animation), {
14268              step: function(t4, i4) {
14269                s2.group && (p2[g2] = e3 + i4.pos * (o2 - e3), s2.group.attr(p2));
14270              }
14271            })));
14272          }
14273          init(t3, e3) {
14274            super.init.apply(this, arguments);
14275            let i3 = this;
14276            (t3 = i3.chart).hasRendered && t3.series.forEach(function(t4) {
14277              t4.type === i3.type && (t4.isDirty = true);
14278            });
14279          }
14280          getColumnMetrics() {
14281            let t3 = this, e3 = t3.options, i3 = t3.xAxis, s2 = t3.yAxis, r2 = i3.options.reversedStacks, o2 = i3.reversed && !r2 || !i3.reversed && r2, n2 = {}, a2, h2 = 0;
14282            false === e3.grouping ? h2 = 1 : t3.chart.series.forEach(function(e4) {
14283              let i4;
14284              let r3 = e4.yAxis, o3 = e4.options;
14285              e4.type === t3.type && e4.reserveSpace() && s2.len === r3.len && s2.pos === r3.pos && (o3.stacking && "group" !== o3.stacking ? (void 0 === n2[a2 = e4.stackKey] && (n2[a2] = h2++), i4 = n2[a2]) : false !== o3.grouping && (i4 = h2++), e4.columnIndex = i4);
14286            });
14287            let l2 = Math.min(Math.abs(i3.transA) * (!i3.brokenAxis?.hasBreaks && i3.ordinal?.slope || e3.pointRange || i3.closestPointRange || i3.tickInterval || 1), i3.len), d2 = l2 * e3.groupPadding, c2 = (l2 - 2 * d2) / (h2 || 1), p2 = Math.min(e3.maxPointWidth || i3.len, y(e3.pointWidth, c2 * (1 - 2 * e3.pointPadding))), u12 = (t3.columnIndex || 0) + (o2 ? 1 : 0);
14288            return t3.columnMetrics = {
14289              width: p2,
14290              offset: (c2 - p2) / 2 + (d2 + u12 * c2 - l2 / 2) * (o2 ? -1 : 1),
14291              paddedWidth: c2,
14292              columnCount: h2
14293            }, t3.columnMetrics;
14294          }
14295          crispCol(t3, e3, i3, s2) {
14296            let r2 = this.borderWidth, o2 = this.chart.inverted;
14297            return s2 = c(e3 + s2, r2, o2) - (e3 = c(e3, r2, o2)), this.options.crisp && (i3 = c(t3 + i3, r2) - (t3 = c(t3, r2))), {
14298              x: t3,
14299              y: e3,
14300              width: i3,
14301              height: s2
14302            };
14303          }
14304          adjustForMissingColumns(t3, e3, i3, s2) {
14305            if (!i3.isNull && s2.columnCount > 1) {
14306              let r2 = this.xAxis.series.filter((t4) => t4.visible).map((t4) => t4.index), o2 = 0, n2 = 0;
14307              b(this.xAxis.stacking?.stacks, (t4) => {
14308                if ("number" == typeof i3.x) {
14309                  let e4 = t4[i3.x.toString()];
14310                  if (e4 && f(e4.points[this.index])) {
14311                    let t5 = Object.keys(e4.points).filter((t6) => !t6.match(",") && e4.points[t6] && e4.points[t6].length > 1).map(parseFloat).filter((t6) => -1 !== r2.indexOf(t6)).sort((t6, e5) => e5 - t6);
14312                    o2 = t5.indexOf(this.index), n2 = t5.length;
14313                  }
14314                }
14315              }), o2 = this.xAxis.reversed ? n2 - 1 - o2 : o2;
14316              let a2 = (n2 - 1) * s2.paddedWidth + e3;
14317              t3 = (i3.plotX || 0) + a2 / 2 - e3 - o2 * s2.paddedWidth;
14318            }
14319            return t3;
14320          }
14321          translate() {
14322            let t3 = this, e3 = t3.chart, i3 = t3.options, s2 = t3.dense = t3.closestPointRange * t3.xAxis.transA < 2, o2 = t3.borderWidth = y(i3.borderWidth, s2 ? 0 : 1), n2 = t3.xAxis, a2 = t3.yAxis, h2 = i3.threshold, l2 = y(i3.minPointLength, 5), c2 = t3.getColumnMetrics(), u12 = c2.width, f2 = t3.pointXOffset = c2.offset, x2 = t3.dataMin, b2 = t3.dataMax, v2 = t3.translatedThreshold = a2.getThreshold(h2), S2 = t3.barW = Math.max(u12, 1 + 2 * o2);
14323            i3.pointPadding && (S2 = Math.ceil(S2)), r.prototype.translate.apply(t3), t3.points.forEach(function(s3) {
14324              let r2 = y(s3.yBottom, v2), o3 = 999 + Math.abs(r2), g2 = s3.plotX || 0, C = d(s3.plotY, -o3, a2.len + o3), k, M = Math.min(C, r2), w = Math.max(C, r2) - M, T2 = u12, A = g2 + f2, P = S2;
14325              l2 && Math.abs(w) < l2 && (w = l2, k = !a2.reversed && !s3.negative || a2.reversed && s3.negative, m(h2) && m(b2) && s3.y === h2 && b2 <= h2 && (a2.min || 0) < h2 && (x2 !== b2 || (a2.max || 0) <= h2) && (k = !k, s3.negative = !s3.negative), M = Math.abs(M - v2) > l2 ? r2 - l2 : v2 - (k ? l2 : 0)), p(s3.options.pointWidth) && (A -= Math.round(((T2 = P = Math.ceil(s3.options.pointWidth)) - u12) / 2)), i3.centerInCategory && !i3.stacking && (A = t3.adjustForMissingColumns(A, T2, s3, c2)), s3.barX = A, s3.pointWidth = T2, s3.tooltipPos = e3.inverted ? [d(a2.len + a2.pos - e3.plotLeft - C, a2.pos - e3.plotLeft, a2.len + a2.pos - e3.plotLeft), n2.len + n2.pos - e3.plotTop - A - P / 2, w] : [n2.left - e3.plotLeft + A + P / 2, d(C + a2.pos - e3.plotTop, a2.pos - e3.plotTop, a2.len + a2.pos - e3.plotTop), w], s3.shapeType = t3.pointClass.prototype.shapeType || "roundedRect", s3.shapeArgs = t3.crispCol(A, s3.isNull ? v2 : M, P, s3.isNull ? 0 : w);
14326            }), g(this, "afterColumnTranslate");
14327          }
14328          drawGraph() {
14329            this.group[this.dense ? "addClass" : "removeClass"]("highcharts-dense-data");
14330          }
14331          pointAttribs(t3, e3) {
14332            let i3 = this.options, s2 = this.pointAttrToOptions || {}, r2 = s2.stroke || "borderColor", o2 = s2["stroke-width"] || "borderWidth", n2, a2, l2, d2 = t3 && t3.color || this.color, c2 = t3 && t3[r2] || i3[r2] || d2, p2 = t3 && t3.options.dashStyle || i3.dashStyle, u12 = t3 && t3[o2] || i3[o2] || this[o2] || 0, g2 = y(t3 && t3.opacity, i3.opacity, 1);
14333            t3 && this.zones.length && (a2 = t3.getZone(), d2 = t3.options.color || a2 && (a2.color || t3.nonZonedColor) || this.color, a2 && (c2 = a2.borderColor || c2, p2 = a2.dashStyle || p2, u12 = a2.borderWidth || u12)), e3 && t3 && (l2 = (n2 = x(i3.states[e3], t3.options.states && t3.options.states[e3] || {})).brightness, d2 = n2.color || void 0 !== l2 && h(d2).brighten(n2.brightness).get() || d2, c2 = n2[r2] || c2, u12 = n2[o2] || u12, p2 = n2.dashStyle || p2, g2 = y(n2.opacity, g2));
14334            let f2 = {
14335              fill: d2,
14336              stroke: c2,
14337              "stroke-width": u12,
14338              opacity: g2
14339            };
14340            return p2 && (f2.dashstyle = p2), f2;
14341          }
14342          drawPoints(t3 = this.points) {
14343            let e3;
14344            let i3 = this, s2 = this.chart, r2 = i3.options, o2 = s2.renderer, n2 = r2.animationLimit || 250;
14345            t3.forEach(function(t4) {
14346              let a2 = t4.plotY, h2 = t4.graphic, l2 = !!h2, d2 = h2 && s2.pointCount < n2 ? "animate" : "attr";
14347              m(a2) && null !== t4.y ? (e3 = t4.shapeArgs, h2 && t4.hasNewShapeType() && (h2 = h2.destroy()), i3.enabledDataSorting && (t4.startXPos = i3.xAxis.reversed ? -(e3 && e3.width || 0) : i3.xAxis.width), !h2 && (t4.graphic = h2 = o2[t4.shapeType](e3).add(t4.group || i3.group), h2 && i3.enabledDataSorting && s2.hasRendered && s2.pointCount < n2 && (h2.attr({
14348                x: t4.startXPos
14349              }), l2 = true, d2 = "animate")), h2 && l2 && h2[d2](x(e3)), s2.styledMode || h2[d2](i3.pointAttribs(t4, t4.selected && "select")).shadow(false !== t4.allowShadow && r2.shadow), h2 && (h2.addClass(t4.getClassName(), true), h2.attr({
14350                visibility: t4.visible ? "inherit" : "hidden"
14351              }))) : h2 && (t4.graphic = h2.destroy());
14352            });
14353          }
14354          drawTracker(t3 = this.points) {
14355            let e3;
14356            let i3 = this, s2 = i3.chart, r2 = s2.pointer, o2 = function(t4) {
14357              let e4 = r2?.getPointFromEvent(t4);
14358              r2 && e4 && i3.options.enableMouseTracking && (r2.isDirectTouch = true, e4.onMouseOver(t4));
14359            };
14360            t3.forEach(function(t4) {
14361              e3 = f(t4.dataLabels) ? t4.dataLabels : t4.dataLabel ? [t4.dataLabel] : [], t4.graphic && (t4.graphic.element.point = t4), e3.forEach(function(e4) {
14362                (e4.div || e4.element).point = t4;
14363              });
14364            }), i3._hasTracking || (i3.trackerGroups.forEach(function(t4) {
14365              i3[t4] && (i3[t4].addClass("highcharts-tracker").on("mouseover", o2).on("mouseout", function(t5) {
14366                r2?.onTrackerMouseOut(t5);
14367              }).on("touchstart", o2), !s2.styledMode && i3.options.cursor && i3[t4].css({
14368                cursor: i3.options.cursor
14369              }));
14370            }), i3._hasTracking = true), g(this, "afterDrawTracker");
14371          }
14372          remove() {
14373            let t3 = this, e3 = t3.chart;
14374            e3.hasRendered && e3.series.forEach(function(e4) {
14375              e4.type === t3.type && (e4.isDirty = true);
14376            }), r.prototype.remove.apply(t3, arguments);
14377          }
14378        }
14379        return v.defaultOptions = x(r.defaultOptions, i2), u11(v.prototype, {
14380          directTouch: true,
14381          getSymbol: l,
14382          negStacks: true,
14383          trackerGroups: ["group", "dataLabelsGroup"]
14384        }), o.registerSeriesType("column", v), v;
14385      }), i(e, "Core/Series/DataLabel.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Templating.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
14386        var s;
14387        let {
14388          getDeferredAnimation: r
14389        } = t2, {
14390          format: o
14391        } = e2, {
14392          defined: n,
14393          extend: a,
14394          fireEvent: h,
14395          isArray: l,
14396          isString: d,
14397          merge: c,
14398          objectEach: p,
14399          pick: u11,
14400          pInt: g,
14401          splat: f
14402        } = i2;
14403        return function(t3) {
14404          function e3() {
14405            return v(this).some((t4) => t4?.enabled);
14406          }
14407          function i3(t4, e4, i4, s3, r2) {
14408            let {
14409              chart: o2,
14410              enabledDataSorting: h2
14411            } = this, l2 = this.isCartesian && o2.inverted, d2 = t4.plotX, p2 = t4.plotY, g2 = i4.rotation || 0, f2 = n(d2) && n(p2) && o2.isInsidePlot(d2, Math.round(p2), {
14412              inverted: l2,
14413              paneCoordinates: true,
14414              series: this
14415            }), m2 = 0 === g2 && "justify" === u11(i4.overflow, h2 ? "none" : "justify"), x2 = this.visible && false !== t4.visible && n(d2) && (t4.series.forceDL || h2 && !m2 || f2 || u11(i4.inside, !!this.options.stacking) && s3 && o2.isInsidePlot(d2, l2 ? s3.x + 1 : s3.y + s3.height - 1, {
14416              inverted: l2,
14417              paneCoordinates: true,
14418              series: this
14419            })), y2 = t4.pos();
14420            if (x2 && y2) {
14421              var b2;
14422              let n2 = e4.getBBox(), d3 = e4.getBBox(void 0, 0), p3 = {
14423                right: 1,
14424                center: 0.5
14425              }[i4.align || 0] || 0, v2 = {
14426                bottom: 1,
14427                middle: 0.5
14428              }[i4.verticalAlign || 0] || 0;
14429              if (s3 = a({
14430                x: y2[0],
14431                y: Math.round(y2[1]),
14432                width: 0,
14433                height: 0
14434              }, s3 || {}), "plotEdges" === i4.alignTo && this.isCartesian && (s3[l2 ? "x" : "y"] = 0, s3[l2 ? "width" : "height"] = this.yAxis?.len || 0), a(i4, {
14435                width: n2.width,
14436                height: n2.height
14437              }), b2 = s3, h2 && this.xAxis && !m2 && this.setDataLabelStartPos(t4, e4, r2, f2, b2), e4.align(c(i4, {
14438                width: d3.width,
14439                height: d3.height
14440              }), false, s3, false), e4.alignAttr.x += p3 * (d3.width - n2.width), e4.alignAttr.y += v2 * (d3.height - n2.height), e4[e4.placed ? "animate" : "attr"]({
14441                x: e4.alignAttr.x + (n2.width - d3.width) / 2,
14442                y: e4.alignAttr.y + (n2.height - d3.height) / 2,
14443                rotationOriginX: (e4.width || 0) / 2,
14444                rotationOriginY: (e4.height || 0) / 2
14445              }), m2 && s3.height >= 0) this.justifyDataLabel(e4, i4, e4.alignAttr, n2, s3, r2);
14446              else if (u11(i4.crop, true)) {
14447                let {
14448                  x: t5,
14449                  y: i5
14450                } = e4.alignAttr;
14451                x2 = o2.isInsidePlot(t5, i5, {
14452                  paneCoordinates: true,
14453                  series: this
14454                }) && o2.isInsidePlot(t5 + n2.width - 1, i5 + n2.height - 1, {
14455                  paneCoordinates: true,
14456                  series: this
14457                });
14458              }
14459              i4.shape && !g2 && e4[r2 ? "attr" : "animate"]({
14460                anchorX: y2[0],
14461                anchorY: y2[1]
14462              });
14463            }
14464            r2 && h2 && (e4.placed = false), x2 || h2 && !m2 ? (e4.show(), e4.placed = true) : (e4.hide(), e4.placed = false);
14465          }
14466          function s2() {
14467            return this.plotGroup("dataLabelsGroup", "data-labels", this.hasRendered ? "inherit" : "hidden", this.options.dataLabels.zIndex || 6);
14468          }
14469          function m(t4) {
14470            let e4 = this.hasRendered || 0, i4 = this.initDataLabelsGroup().attr({
14471              opacity: +e4
14472            });
14473            return !e4 && i4 && (this.visible && i4.show(), this.options.animation ? i4.animate({
14474              opacity: 1
14475            }, t4) : i4.attr({
14476              opacity: 1
14477            })), i4;
14478          }
14479          function x(t4) {
14480            let e4;
14481            t4 = t4 || this.points;
14482            let i4 = this, s3 = i4.chart, a2 = i4.options, l2 = s3.renderer, {
14483              backgroundColor: c2,
14484              plotBackgroundColor: m2
14485            } = s3.options.chart, x2 = l2.getContrast(d(m2) && m2 || d(c2) && c2 || "#000000"), y2 = v(i4), {
14486              animation: S3,
14487              defer: C
14488            } = y2[0], k = C ? r(s3, S3, i4) : {
14489              defer: 0,
14490              duration: 0
14491            };
14492            h(this, "drawDataLabels"), i4.hasDataLabels?.() && (e4 = this.initDataLabels(k), t4.forEach((t5) => {
14493              let r2 = t5.dataLabels || [];
14494              f(b(y2, t5.dlOptions || t5.options?.dataLabels)).forEach((c4, f2) => {
14495                let m3 = c4.enabled && (t5.visible || t5.dataLabelOnHidden) && (!t5.isNull || t5.dataLabelOnNull) && function(t6, e5) {
14496                  let i5 = e5.filter;
14497                  if (i5) {
14498                    let e6 = i5.operator, s4 = t6[i5.property], r3 = i5.value;
14499                    return ">" === e6 && s4 > r3 || "<" === e6 && s4 < r3 || ">=" === e6 && s4 >= r3 || "<=" === e6 && s4 <= r3 || "==" === e6 && s4 == r3 || "===" === e6 && s4 === r3 || "!=" === e6 && s4 != r3 || "!==" === e6 && s4 !== r3;
14500                  }
14501                  return true;
14502                }(t5, c4), {
14503                  backgroundColor: y3,
14504                  borderColor: b2,
14505                  distance: v2,
14506                  style: S4 = {}
14507                } = c4, C2, k2, M, w, T2 = {}, A = r2[f2], P = !A, L;
14508                m3 && (k2 = u11(c4[t5.formatPrefix + "Format"], c4.format), C2 = t5.getLabelConfig(), M = n(k2) ? o(k2, C2, s3) : (c4[t5.formatPrefix + "Formatter"] || c4.formatter).call(C2, c4), w = c4.rotation, !s3.styledMode && (S4.color = u11(c4.color, S4.color, d(i4.color) ? i4.color : void 0, "#000000"), "contrast" === S4.color ? ("none" !== y3 && (L = y3), t5.contrastColor = l2.getContrast("auto" !== L && L || t5.color || i4.color), S4.color = L || !n(v2) && c4.inside || 0 > g(v2 || 0) || a2.stacking ? t5.contrastColor : x2) : delete t5.contrastColor, a2.cursor && (S4.cursor = a2.cursor)), T2 = {
14509                  r: c4.borderRadius || 0,
14510                  rotation: w,
14511                  padding: c4.padding,
14512                  zIndex: 1
14513                }, s3.styledMode || (T2.fill = "auto" === y3 ? t5.color : y3, T2.stroke = "auto" === b2 ? t5.color : b2, T2["stroke-width"] = c4.borderWidth), p(T2, (t6, e5) => {
14514                  void 0 === t6 && delete T2[e5];
14515                })), !A || m3 && n(M) && !!A.div == !!c4.useHTML && (A.rotation && c4.rotation || A.rotation === c4.rotation) || (A = void 0, P = true), m3 && n(M) && (A ? T2.text = M : (A = l2.label(M, 0, 0, c4.shape, void 0, void 0, c4.useHTML, void 0, "data-label")).addClass(" highcharts-data-label-color-" + t5.colorIndex + " " + (c4.className || "") + (c4.useHTML ? " highcharts-tracker" : "")), A && (A.options = c4, A.attr(T2), s3.styledMode ? S4.width && A.css({
14516                  width: S4.width,
14517                  textOverflow: S4.textOverflow
14518                }) : A.css(S4).shadow(c4.shadow), h(A, "beforeAddingDataLabel", {
14519                  labelOptions: c4,
14520                  point: t5
14521                }), A.added || A.add(e4), i4.alignDataLabel(t5, A, c4, void 0, P), A.isActive = true, r2[f2] && r2[f2] !== A && r2[f2].destroy(), r2[f2] = A));
14522              });
14523              let c3 = r2.length;
14524              for (; c3--; ) r2[c3] && r2[c3].isActive ? r2[c3].isActive = false : (r2[c3]?.destroy(), r2.splice(c3, 1));
14525              t5.dataLabel = r2[0], t5.dataLabels = r2;
14526            })), h(this, "afterDrawDataLabels");
14527          }
14528          function y(t4, e4, i4, s3, r2, o2) {
14529            let n2 = this.chart, a2 = e4.align, h2 = e4.verticalAlign, l2 = t4.box ? 0 : t4.padding || 0, d2 = n2.inverted ? this.yAxis : this.xAxis, c2 = d2 ? d2.left - n2.plotLeft : 0, p2 = n2.inverted ? this.xAxis : this.yAxis, u12 = p2 ? p2.top - n2.plotTop : 0, {
14530              x: g2 = 0,
14531              y: f2 = 0
14532            } = e4, m2, x2;
14533            return (m2 = (i4.x || 0) + l2 + c2) < 0 && ("right" === a2 && g2 >= 0 ? (e4.align = "left", e4.inside = true) : g2 -= m2, x2 = true), (m2 = (i4.x || 0) + s3.width - l2 + c2) > n2.plotWidth && ("left" === a2 && g2 <= 0 ? (e4.align = "right", e4.inside = true) : g2 += n2.plotWidth - m2, x2 = true), (m2 = i4.y + l2 + u12) < 0 && ("bottom" === h2 && f2 >= 0 ? (e4.verticalAlign = "top", e4.inside = true) : f2 -= m2, x2 = true), (m2 = (i4.y || 0) + s3.height - l2 + u12) > n2.plotHeight && ("top" === h2 && f2 <= 0 ? (e4.verticalAlign = "bottom", e4.inside = true) : f2 += n2.plotHeight - m2, x2 = true), x2 && (e4.x = g2, e4.y = f2, t4.placed = !o2, t4.align(e4, void 0, r2)), x2;
14534          }
14535          function b(t4, e4) {
14536            let i4 = [], s3;
14537            if (l(t4) && !l(e4)) i4 = t4.map(function(t5) {
14538              return c(t5, e4);
14539            });
14540            else if (l(e4) && !l(t4)) i4 = e4.map(function(e5) {
14541              return c(t4, e5);
14542            });
14543            else if (l(t4) || l(e4)) {
14544              if (l(t4) && l(e4)) for (s3 = Math.max(t4.length, e4.length); s3--; ) i4[s3] = c(t4[s3], e4[s3]);
14545            } else i4 = c(t4, e4);
14546            return i4;
14547          }
14548          function v(t4) {
14549            let e4 = t4.chart.options.plotOptions;
14550            return f(b(b(e4?.series?.dataLabels, e4?.[t4.type]?.dataLabels), t4.options.dataLabels));
14551          }
14552          function S2(t4, e4, i4, s3, r2) {
14553            let o2 = this.chart, n2 = o2.inverted, a2 = this.xAxis, h2 = a2.reversed, l2 = ((n2 ? e4.height : e4.width) || 0) / 2, d2 = t4.pointWidth, c2 = d2 ? d2 / 2 : 0;
14554            e4.startXPos = n2 ? r2.x : h2 ? -l2 - c2 : a2.width - l2 + c2, e4.startYPos = n2 ? h2 ? this.yAxis.height - l2 + c2 : -l2 - c2 : r2.y, s3 ? "hidden" === e4.visibility && (e4.show(), e4.attr({
14555              opacity: 0
14556            }).animate({
14557              opacity: 1
14558            })) : e4.attr({
14559              opacity: 1
14560            }).animate({
14561              opacity: 0
14562            }, void 0, e4.hide), o2.hasRendered && (i4 && e4.attr({
14563              x: e4.startXPos,
14564              y: e4.startYPos
14565            }), e4.placed = true);
14566          }
14567          t3.compose = function(t4) {
14568            let r2 = t4.prototype;
14569            r2.initDataLabels || (r2.initDataLabels = m, r2.initDataLabelsGroup = s2, r2.alignDataLabel = i3, r2.drawDataLabels = x, r2.justifyDataLabel = y, r2.setDataLabelStartPos = S2, r2.hasDataLabels = e3);
14570          };
14571        }(s || (s = {})), s;
14572      }), i(e, "Series/Column/ColumnDataLabel.js", [e["Core/Series/DataLabel.js"], e["Core/Globals.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
14573        var r;
14574        let {
14575          composed: o
14576        } = e2, {
14577          series: n
14578        } = i2, {
14579          merge: a,
14580          pick: h,
14581          pushUnique: l
14582        } = s;
14583        return function(e3) {
14584          function i3(t3, e4, i4, s2, r2) {
14585            let o2 = this.chart.inverted, l2 = t3.series, d = (l2.xAxis ? l2.xAxis.len : this.chart.plotSizeX) || 0, c = (l2.yAxis ? l2.yAxis.len : this.chart.plotSizeY) || 0, p = t3.dlBox || t3.shapeArgs, u11 = h(t3.below, t3.plotY > h(this.translatedThreshold, c)), g = h(i4.inside, !!this.options.stacking);
14586            if (p) {
14587              if (s2 = a(p), !("allow" === i4.overflow && false === i4.crop)) {
14588                s2.y < 0 && (s2.height += s2.y, s2.y = 0);
14589                let t4 = s2.y + s2.height - c;
14590                t4 > 0 && t4 < s2.height - 1 && (s2.height -= t4);
14591              }
14592              o2 && (s2 = {
14593                x: c - s2.y - s2.height,
14594                y: d - s2.x - s2.width,
14595                width: s2.height,
14596                height: s2.width
14597              }), g || (o2 ? (s2.x += u11 ? 0 : s2.width, s2.width = 0) : (s2.y += u11 ? s2.height : 0, s2.height = 0));
14598            }
14599            i4.align = h(i4.align, !o2 || g ? "center" : u11 ? "right" : "left"), i4.verticalAlign = h(i4.verticalAlign, o2 || g ? "middle" : u11 ? "top" : "bottom"), n.prototype.alignDataLabel.call(this, t3, e4, i4, s2, r2), i4.inside && t3.contrastColor && e4.css({
14600              color: t3.contrastColor
14601            });
14602          }
14603          e3.compose = function(e4) {
14604            t2.compose(n), l(o, "ColumnDataLabel") && (e4.prototype.alignDataLabel = i3);
14605          };
14606        }(r || (r = {})), r;
14607      }), i(e, "Series/Bar/BarSeries.js", [e["Series/Column/ColumnSeries.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
14608        let {
14609          extend: s,
14610          merge: r
14611        } = i2;
14612        class o extends t2 {
14613        }
14614        return o.defaultOptions = r(t2.defaultOptions, {}), s(o.prototype, {
14615          inverted: true
14616        }), e2.registerSeriesType("bar", o), o;
14617      }), i(e, "Series/Scatter/ScatterSeriesDefaults.js", [], function() {
14618        return {
14619          lineWidth: 0,
14620          findNearestPointBy: "xy",
14621          jitter: {
14622            x: 0,
14623            y: 0
14624          },
14625          marker: {
14626            enabled: true
14627          },
14628          tooltip: {
14629            headerFormat: '<span style="color:{point.color}">\u25CF</span> <span style="font-size: 0.8em"> {series.name}</span><br/>',
14630            pointFormat: "x: <b>{point.x}</b><br/>y: <b>{point.y}</b><br/>"
14631          }
14632        };
14633      }), i(e, "Series/Scatter/ScatterSeries.js", [e["Series/Scatter/ScatterSeriesDefaults.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
14634        let {
14635          column: s,
14636          line: r
14637        } = e2.seriesTypes, {
14638          addEvent: o,
14639          extend: n,
14640          merge: a
14641        } = i2;
14642        class h extends r {
14643          applyJitter() {
14644            let t3 = this, e3 = this.options.jitter, i3 = this.points.length;
14645            e3 && this.points.forEach(function(s2, r2) {
14646              ["x", "y"].forEach(function(o2, n2) {
14647                if (e3[o2] && !s2.isNull) {
14648                  let a2 = `plot${o2.toUpperCase()}`, h2 = t3[`${o2}Axis`], l = e3[o2] * h2.transA;
14649                  if (h2 && !h2.logarithmic) {
14650                    let t4 = Math.max(0, (s2[a2] || 0) - l), e4 = Math.min(h2.len, (s2[a2] || 0) + l);
14651                    s2[a2] = t4 + (e4 - t4) * function(t5) {
14652                      let e5 = 1e4 * Math.sin(t5);
14653                      return e5 - Math.floor(e5);
14654                    }(r2 + n2 * i3), "x" === o2 && (s2.clientX = s2.plotX);
14655                  }
14656                }
14657              });
14658            });
14659          }
14660          drawGraph() {
14661            this.options.lineWidth ? super.drawGraph() : this.graph && (this.graph = this.graph.destroy());
14662          }
14663        }
14664        return h.defaultOptions = a(r.defaultOptions, t2), n(h.prototype, {
14665          drawTracker: s.prototype.drawTracker,
14666          sorted: false,
14667          requireSorting: false,
14668          noSharedTooltip: true,
14669          trackerGroups: ["group", "markerGroup", "dataLabelsGroup"]
14670        }), o(h, "afterTranslate", function() {
14671          this.applyJitter();
14672        }), e2.registerSeriesType("scatter", h), h;
14673      }), i(e, "Series/CenteredUtilities.js", [e["Core/Globals.js"], e["Core/Series/Series.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
14674        var s, r;
14675        let {
14676          deg2rad: o
14677        } = t2, {
14678          fireEvent: n,
14679          isNumber: a,
14680          pick: h,
14681          relativeLength: l
14682        } = i2;
14683        return (r = s || (s = {})).getCenter = function() {
14684          let t3 = this.options, i3 = this.chart, s2 = 2 * (t3.slicedOffset || 0), r2 = i3.plotWidth - 2 * s2, o2 = i3.plotHeight - 2 * s2, d = t3.center, c = Math.min(r2, o2), p = t3.thickness, u11, g = t3.size, f = t3.innerSize || 0, m, x;
14685          "string" == typeof g && (g = parseFloat(g)), "string" == typeof f && (f = parseFloat(f));
14686          let y = [h(d[0], "50%"), h(d[1], "50%"), h(g && g < 0 ? void 0 : t3.size, "100%"), h(f && f < 0 ? void 0 : t3.innerSize || 0, "0%")];
14687          for (!i3.angular || this instanceof e2 || (y[3] = 0), m = 0; m < 4; ++m) x = y[m], u11 = m < 2 || 2 === m && /%$/.test(x), y[m] = l(x, [r2, o2, c, y[2]][m]) + (u11 ? s2 : 0);
14688          return y[3] > y[2] && (y[3] = y[2]), a(p) && 2 * p < y[2] && p > 0 && (y[3] = y[2] - 2 * p), n(this, "afterGetCenter", {
14689            positions: y
14690          }), y;
14691        }, r.getStartAndEndRadians = function(t3, e3) {
14692          let i3 = a(t3) ? t3 : 0, s2 = a(e3) && e3 > i3 && e3 - i3 < 360 ? e3 : i3 + 360;
14693          return {
14694            start: o * (i3 + -90),
14695            end: o * (s2 + -90)
14696          };
14697        }, s;
14698      }), i(e, "Series/Pie/PiePoint.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Series/Point.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
14699        let {
14700          setAnimation: s
14701        } = t2, {
14702          addEvent: r,
14703          defined: o,
14704          extend: n,
14705          isNumber: a,
14706          pick: h,
14707          relativeLength: l
14708        } = i2;
14709        class d extends e2 {
14710          getConnectorPath(t3) {
14711            let e3 = t3.dataLabelPosition, i3 = t3.options || {}, s2 = i3.connectorShape, r2 = this.connectorShapes[s2] || s2;
14712            return e3 && r2.call(this, __spreadProps(__spreadValues({}, e3.computed), {
14713              alignment: e3.alignment
14714            }), e3.connectorPosition, i3) || [];
14715          }
14716          getTranslate() {
14717            return this.sliced && this.slicedTranslation || {
14718              translateX: 0,
14719              translateY: 0
14720            };
14721          }
14722          haloPath(t3) {
14723            let e3 = this.shapeArgs;
14724            return this.sliced || !this.visible ? [] : this.series.chart.renderer.symbols.arc(e3.x, e3.y, e3.r + t3, e3.r + t3, {
14725              innerR: e3.r - 1,
14726              start: e3.start,
14727              end: e3.end,
14728              borderRadius: e3.borderRadius
14729            });
14730          }
14731          constructor(t3, e3, i3) {
14732            super(t3, e3, i3), this.half = 0, this.name ?? (this.name = "Slice");
14733            let s2 = (t4) => {
14734              this.slice("select" === t4.type);
14735            };
14736            r(this, "select", s2), r(this, "unselect", s2);
14737          }
14738          isValid() {
14739            return a(this.y) && this.y >= 0;
14740          }
14741          setVisible(t3, e3 = true) {
14742            t3 !== this.visible && this.update({
14743              visible: t3 ?? !this.visible
14744            }, e3, void 0, false);
14745          }
14746          slice(t3, e3, i3) {
14747            let r2 = this.series;
14748            s(i3, r2.chart), e3 = h(e3, true), this.sliced = this.options.sliced = t3 = o(t3) ? t3 : !this.sliced, r2.options.data[r2.data.indexOf(this)] = this.options, this.graphic && this.graphic.animate(this.getTranslate());
14749          }
14750        }
14751        return n(d.prototype, {
14752          connectorShapes: {
14753            fixedOffset: function(t3, e3, i3) {
14754              let s2 = e3.breakAt, r2 = e3.touchingSliceAt, o2 = i3.softConnector ? ["C", t3.x + ("left" === t3.alignment ? -5 : 5), t3.y, 2 * s2.x - r2.x, 2 * s2.y - r2.y, s2.x, s2.y] : ["L", s2.x, s2.y];
14755              return [["M", t3.x, t3.y], o2, ["L", r2.x, r2.y]];
14756            },
14757            straight: function(t3, e3) {
14758              let i3 = e3.touchingSliceAt;
14759              return [["M", t3.x, t3.y], ["L", i3.x, i3.y]];
14760            },
14761            crookedLine: function(t3, e3, i3) {
14762              let {
14763                breakAt: s2,
14764                touchingSliceAt: r2
14765              } = e3, {
14766                series: o2
14767              } = this, [n2, a2, h2] = o2.center, d2 = h2 / 2, {
14768                plotLeft: c,
14769                plotWidth: p
14770              } = o2.chart, u11 = "left" === t3.alignment, {
14771                x: g,
14772                y: f
14773              } = t3, m = s2.x;
14774              if (i3.crookDistance) {
14775                let t4 = l(i3.crookDistance, 1);
14776                m = u11 ? n2 + d2 + (p + c - n2 - d2) * (1 - t4) : c + (n2 - d2) * t4;
14777              } else m = n2 + (a2 - f) * Math.tan((this.angle || 0) - Math.PI / 2);
14778              let x = [["M", g, f]];
14779              return (u11 ? m <= g && m >= s2.x : m >= g && m <= s2.x) && x.push(["L", m, f]), x.push(["L", s2.x, s2.y], ["L", r2.x, r2.y]), x;
14780            }
14781          }
14782        }), d;
14783      }), i(e, "Series/Pie/PieSeriesDefaults.js", [], function() {
14784        return {
14785          borderRadius: 3,
14786          center: [null, null],
14787          clip: false,
14788          colorByPoint: true,
14789          dataLabels: {
14790            connectorPadding: 5,
14791            connectorShape: "crookedLine",
14792            crookDistance: void 0,
14793            distance: 30,
14794            enabled: true,
14795            formatter: function() {
14796              return this.point.isNull ? void 0 : this.point.name;
14797            },
14798            softConnector: true,
14799            x: 0
14800          },
14801          fillColor: void 0,
14802          ignoreHiddenPoint: true,
14803          inactiveOtherPoints: true,
14804          legendType: "point",
14805          marker: null,
14806          size: null,
14807          showInLegend: false,
14808          slicedOffset: 10,
14809          stickyTracking: false,
14810          tooltip: {
14811            followPointer: true
14812          },
14813          borderColor: "#ffffff",
14814          borderWidth: 1,
14815          lineWidth: void 0,
14816          states: {
14817            hover: {
14818              brightness: 0.1
14819            }
14820          }
14821        };
14822      }), i(e, "Series/Pie/PieSeries.js", [e["Series/CenteredUtilities.js"], e["Series/Column/ColumnSeries.js"], e["Core/Globals.js"], e["Series/Pie/PiePoint.js"], e["Series/Pie/PieSeriesDefaults.js"], e["Core/Series/Series.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Renderer/SVG/Symbols.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, r, o, n, a, h) {
14823        let {
14824          getStartAndEndRadians: l
14825        } = t2, {
14826          noop: d
14827        } = i2, {
14828          clamp: c,
14829          extend: p,
14830          fireEvent: u11,
14831          merge: g,
14832          pick: f
14833        } = h;
14834        class m extends o {
14835          animate(t3) {
14836            let e3 = this, i3 = e3.points, s2 = e3.startAngleRad;
14837            t3 || i3.forEach(function(t4) {
14838              let i4 = t4.graphic, r2 = t4.shapeArgs;
14839              i4 && r2 && (i4.attr({
14840                r: f(t4.startR, e3.center && e3.center[3] / 2),
14841                start: s2,
14842                end: s2
14843              }), i4.animate({
14844                r: r2.r,
14845                start: r2.start,
14846                end: r2.end
14847              }, e3.options.animation));
14848            });
14849          }
14850          drawEmpty() {
14851            let t3, e3;
14852            let i3 = this.startAngleRad, s2 = this.endAngleRad, r2 = this.options;
14853            0 === this.total && this.center ? (t3 = this.center[0], e3 = this.center[1], this.graph || (this.graph = this.chart.renderer.arc(t3, e3, this.center[1] / 2, 0, i3, s2).addClass("highcharts-empty-series").add(this.group)), this.graph.attr({
14854              d: a.arc(t3, e3, this.center[2] / 2, 0, {
14855                start: i3,
14856                end: s2,
14857                innerR: this.center[3] / 2
14858              })
14859            }), this.chart.styledMode || this.graph.attr({
14860              "stroke-width": r2.borderWidth,
14861              fill: r2.fillColor || "none",
14862              stroke: r2.color || "#cccccc"
14863            })) : this.graph && (this.graph = this.graph.destroy());
14864          }
14865          drawPoints() {
14866            let t3 = this.chart.renderer;
14867            this.points.forEach(function(e3) {
14868              e3.graphic && e3.hasNewShapeType() && (e3.graphic = e3.graphic.destroy()), e3.graphic || (e3.graphic = t3[e3.shapeType](e3.shapeArgs).add(e3.series.group), e3.delayedRendering = true);
14869            });
14870          }
14871          generatePoints() {
14872            super.generatePoints(), this.updateTotals();
14873          }
14874          getX(t3, e3, i3, s2) {
14875            let r2 = this.center, o2 = this.radii ? this.radii[i3.index] || 0 : r2[2] / 2, n2 = s2.dataLabelPosition, a2 = n2?.distance || 0, h2 = Math.asin(c((t3 - r2[1]) / (o2 + a2), -1, 1));
14876            return r2[0] + Math.cos(h2) * (o2 + a2) * (e3 ? -1 : 1) + (a2 > 0 ? (e3 ? -1 : 1) * (s2.padding || 0) : 0);
14877          }
14878          hasData() {
14879            return !!this.processedXData.length;
14880          }
14881          redrawPoints() {
14882            let t3, e3, i3, s2;
14883            let r2 = this, o2 = r2.chart;
14884            this.drawEmpty(), r2.group && !o2.styledMode && r2.group.shadow(r2.options.shadow), r2.points.forEach(function(n2) {
14885              let a2 = {};
14886              e3 = n2.graphic, !n2.isNull && e3 ? (s2 = n2.shapeArgs, t3 = n2.getTranslate(), o2.styledMode || (i3 = r2.pointAttribs(n2, n2.selected && "select")), n2.delayedRendering ? (e3.setRadialReference(r2.center).attr(s2).attr(t3), o2.styledMode || e3.attr(i3).attr({
14887                "stroke-linejoin": "round"
14888              }), n2.delayedRendering = false) : (e3.setRadialReference(r2.center), o2.styledMode || g(true, a2, i3), g(true, a2, s2, t3), e3.animate(a2)), e3.attr({
14889                visibility: n2.visible ? "inherit" : "hidden"
14890              }), e3.addClass(n2.getClassName(), true)) : e3 && (n2.graphic = e3.destroy());
14891            });
14892          }
14893          sortByAngle(t3, e3) {
14894            t3.sort(function(t4, i3) {
14895              return void 0 !== t4.angle && (i3.angle - t4.angle) * e3;
14896            });
14897          }
14898          translate(t3) {
14899            u11(this, "translate"), this.generatePoints();
14900            let e3 = this.options, i3 = e3.slicedOffset, s2 = l(e3.startAngle, e3.endAngle), r2 = this.startAngleRad = s2.start, o2 = (this.endAngleRad = s2.end) - r2, n2 = this.points, a2 = e3.ignoreHiddenPoint, h2 = n2.length, d2, c2, p2, g2, f2, m2, x, y = 0;
14901            for (t3 || (this.center = t3 = this.getCenter()), m2 = 0; m2 < h2; m2++) {
14902              x = n2[m2], d2 = r2 + y * o2, x.isValid() && (!a2 || x.visible) && (y += x.percentage / 100), c2 = r2 + y * o2;
14903              let e4 = {
14904                x: t3[0],
14905                y: t3[1],
14906                r: t3[2] / 2,
14907                innerR: t3[3] / 2,
14908                start: Math.round(1e3 * d2) / 1e3,
14909                end: Math.round(1e3 * c2) / 1e3
14910              };
14911              x.shapeType = "arc", x.shapeArgs = e4, (p2 = (c2 + d2) / 2) > 1.5 * Math.PI ? p2 -= 2 * Math.PI : p2 < -Math.PI / 2 && (p2 += 2 * Math.PI), x.slicedTranslation = {
14912                translateX: Math.round(Math.cos(p2) * i3),
14913                translateY: Math.round(Math.sin(p2) * i3)
14914              }, g2 = Math.cos(p2) * t3[2] / 2, f2 = Math.sin(p2) * t3[2] / 2, x.tooltipPos = [t3[0] + 0.7 * g2, t3[1] + 0.7 * f2], x.half = p2 < -Math.PI / 2 || p2 > Math.PI / 2 ? 1 : 0, x.angle = p2;
14915            }
14916            u11(this, "afterTranslate");
14917          }
14918          updateTotals() {
14919            let t3 = this.points, e3 = t3.length, i3 = this.options.ignoreHiddenPoint, s2, r2, o2 = 0;
14920            for (s2 = 0; s2 < e3; s2++) (r2 = t3[s2]).isValid() && (!i3 || r2.visible) && (o2 += r2.y);
14921            for (s2 = 0, this.total = o2; s2 < e3; s2++) (r2 = t3[s2]).percentage = o2 > 0 && (r2.visible || !i3) ? r2.y / o2 * 100 : 0, r2.total = o2;
14922          }
14923        }
14924        return m.defaultOptions = g(o.defaultOptions, r), p(m.prototype, {
14925          axisTypes: [],
14926          directTouch: true,
14927          drawGraph: void 0,
14928          drawTracker: e2.prototype.drawTracker,
14929          getCenter: t2.getCenter,
14930          getSymbol: d,
14931          invertible: false,
14932          isCartesian: false,
14933          noSharedTooltip: true,
14934          pointAttribs: e2.prototype.pointAttribs,
14935          pointClass: s,
14936          requireSorting: false,
14937          searchPoint: d,
14938          trackerGroups: ["group", "dataLabelsGroup"]
14939        }), n.registerSeriesType("pie", m), m;
14940      }), i(e, "Series/Pie/PieDataLabel.js", [e["Core/Series/DataLabel.js"], e["Core/Globals.js"], e["Core/Renderer/RendererUtilities.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, r) {
14941        var o;
14942        let {
14943          composed: n,
14944          noop: a
14945        } = e2, {
14946          distribute: h
14947        } = i2, {
14948          series: l
14949        } = s, {
14950          arrayMax: d,
14951          clamp: c,
14952          defined: p,
14953          pick: u11,
14954          pushUnique: g,
14955          relativeLength: f
14956        } = r;
14957        return function(e3) {
14958          let i3 = {
14959            radialDistributionY: function(t3, e4) {
14960              return (e4.dataLabelPosition?.top || 0) + t3.distributeBox.pos;
14961            },
14962            radialDistributionX: function(t3, e4, i4, s3, r3) {
14963              let o3 = r3.dataLabelPosition;
14964              return t3.getX(i4 < (o3?.top || 0) + 2 || i4 > (o3?.bottom || 0) - 2 ? s3 : i4, e4.half, e4, r3);
14965            },
14966            justify: function(t3, e4, i4, s3) {
14967              return s3[0] + (t3.half ? -1 : 1) * (i4 + (e4.dataLabelPosition?.distance || 0));
14968            },
14969            alignToPlotEdges: function(t3, e4, i4, s3) {
14970              let r3 = t3.getBBox().width;
14971              return e4 ? r3 + s3 : i4 - r3 - s3;
14972            },
14973            alignToConnectors: function(t3, e4, i4, s3) {
14974              let r3 = 0, o3;
14975              return t3.forEach(function(t4) {
14976                (o3 = t4.dataLabel.getBBox().width) > r3 && (r3 = o3);
14977              }), e4 ? r3 + s3 : i4 - r3 - s3;
14978            }
14979          };
14980          function s2(t3, e4) {
14981            let {
14982              center: i4,
14983              options: s3
14984            } = this, r3 = i4[2] / 2, o3 = t3.angle || 0, n2 = Math.cos(o3), a2 = Math.sin(o3), h2 = i4[0] + n2 * r3, l2 = i4[1] + a2 * r3, d2 = Math.min((s3.slicedOffset || 0) + (s3.borderWidth || 0), e4 / 5);
14985            return {
14986              natural: {
14987                x: h2 + n2 * e4,
14988                y: l2 + a2 * e4
14989              },
14990              computed: {},
14991              alignment: e4 < 0 ? "center" : t3.half ? "right" : "left",
14992              connectorPosition: {
14993                breakAt: {
14994                  x: h2 + n2 * d2,
14995                  y: l2 + a2 * d2
14996                },
14997                touchingSliceAt: {
14998                  x: h2,
14999                  y: l2
15000                }
15001              },
15002              distance: e4
15003            };
15004          }
15005          function r2() {
15006            let t3 = this, e4 = t3.points, i4 = t3.chart, s3 = i4.plotWidth, r3 = i4.plotHeight, o3 = i4.plotLeft, n2 = Math.round(i4.chartWidth / 3), a2 = t3.center, c2 = a2[2] / 2, g2 = a2[1], m2 = [[], []], x = [0, 0, 0, 0], y = t3.dataLabelPositioners, b, v, S2, C = 0;
15007            t3.visible && t3.hasDataLabels?.() && (e4.forEach((t4) => {
15008              (t4.dataLabels || []).forEach((t5) => {
15009                t5.shortened && (t5.attr({
15010                  width: "auto"
15011                }).css({
15012                  width: "auto",
15013                  textOverflow: "clip"
15014                }), t5.shortened = false);
15015              });
15016            }), l.prototype.drawDataLabels.apply(t3), e4.forEach((t4) => {
15017              (t4.dataLabels || []).forEach((e5, i5) => {
15018                let s4 = a2[2] / 2, r4 = e5.options, o4 = f(r4?.distance || 0, s4);
15019                0 === i5 && m2[t4.half].push(t4), !p(r4?.style?.width) && e5.getBBox().width > n2 && (e5.css({
15020                  width: Math.round(0.7 * n2) + "px"
15021                }), e5.shortened = true), e5.dataLabelPosition = this.getDataLabelPosition(t4, o4), C = Math.max(C, o4);
15022              });
15023            }), m2.forEach((e5, n3) => {
15024              let l2 = e5.length, d2 = [], f2, m3, b2 = 0, k;
15025              l2 && (t3.sortByAngle(e5, n3 - 0.5), C > 0 && (f2 = Math.max(0, g2 - c2 - C), m3 = Math.min(g2 + c2 + C, i4.plotHeight), e5.forEach((t4) => {
15026                (t4.dataLabels || []).forEach((e6) => {
15027                  let s4 = e6.dataLabelPosition;
15028                  s4 && s4.distance > 0 && (s4.top = Math.max(0, g2 - c2 - s4.distance), s4.bottom = Math.min(g2 + c2 + s4.distance, i4.plotHeight), b2 = e6.getBBox().height || 21, e6.lineHeight = i4.renderer.fontMetrics(e6.text || e6).h + 2 * e6.padding, t4.distributeBox = {
15029                    target: (e6.dataLabelPosition?.natural.y || 0) - s4.top + e6.lineHeight / 2,
15030                    size: b2,
15031                    rank: t4.y
15032                  }, d2.push(t4.distributeBox));
15033                });
15034              }), h(d2, k = m3 + b2 - f2, k / 5)), e5.forEach((i5) => {
15035                (i5.dataLabels || []).forEach((h2) => {
15036                  let l3 = h2.options || {}, g3 = i5.distributeBox, f3 = h2.dataLabelPosition, m4 = f3?.natural.y || 0, b3 = l3.connectorPadding || 0, C2 = h2.lineHeight || 21, k2 = (C2 - h2.getBBox().height) / 2, M = 0, w = m4, T2 = "inherit";
15037                  if (f3) {
15038                    if (d2 && p(g3) && f3.distance > 0 && (void 0 === g3.pos ? T2 = "hidden" : (S2 = g3.size, w = y.radialDistributionY(i5, h2))), l3.justify) M = y.justify(i5, h2, c2, a2);
15039                    else switch (l3.alignTo) {
15040                      case "connectors":
15041                        M = y.alignToConnectors(e5, n3, s3, o3);
15042                        break;
15043                      case "plotEdges":
15044                        M = y.alignToPlotEdges(h2, n3, s3, o3);
15045                        break;
15046                      default:
15047                        M = y.radialDistributionX(t3, i5, w - k2, m4, h2);
15048                    }
15049                    if (f3.attribs = {
15050                      visibility: T2,
15051                      align: f3.alignment
15052                    }, f3.posAttribs = {
15053                      x: M + (l3.x || 0) + ({
15054                        left: b3,
15055                        right: -b3
15056                      }[f3.alignment] || 0),
15057                      y: w + (l3.y || 0) - C2 / 2
15058                    }, f3.computed.x = M, f3.computed.y = w - k2, u11(l3.crop, true)) {
15059                      let t4;
15060                      M - (v = h2.getBBox().width) < b3 && 1 === n3 ? (t4 = Math.round(v - M + b3), x[3] = Math.max(t4, x[3])) : M + v > s3 - b3 && 0 === n3 && (t4 = Math.round(M + v - s3 + b3), x[1] = Math.max(t4, x[1])), w - S2 / 2 < 0 ? x[0] = Math.max(Math.round(-w + S2 / 2), x[0]) : w + S2 / 2 > r3 && (x[2] = Math.max(Math.round(w + S2 / 2 - r3), x[2])), f3.sideOverflow = t4;
15061                    }
15062                  }
15063                });
15064              }));
15065            }), (0 === d(x) || this.verifyDataLabelOverflow(x)) && (this.placeDataLabels(), this.points.forEach((e5) => {
15066              (e5.dataLabels || []).forEach((s4) => {
15067                let {
15068                  connectorColor: r4,
15069                  connectorWidth: o4 = 1
15070                } = s4.options || {}, n3 = s4.dataLabelPosition;
15071                if (o4) {
15072                  let a3;
15073                  b = s4.connector, n3 && n3.distance > 0 ? (a3 = !b, b || (s4.connector = b = i4.renderer.path().addClass("highcharts-data-label-connector  highcharts-color-" + e5.colorIndex + (e5.className ? " " + e5.className : "")).add(t3.dataLabelsGroup)), i4.styledMode || b.attr({
15074                    "stroke-width": o4,
15075                    stroke: r4 || e5.color || "#666666"
15076                  }), b[a3 ? "attr" : "animate"]({
15077                    d: e5.getConnectorPath(s4)
15078                  }), b.attr({
15079                    visibility: n3.attribs?.visibility
15080                  })) : b && (s4.connector = b.destroy());
15081                }
15082              });
15083            })));
15084          }
15085          function o2() {
15086            this.points.forEach((t3) => {
15087              (t3.dataLabels || []).forEach((t4) => {
15088                let e4 = t4.dataLabelPosition;
15089                e4 ? (e4.sideOverflow && (t4.css({
15090                  width: Math.max(t4.getBBox().width - e4.sideOverflow, 0) + "px",
15091                  textOverflow: (t4.options?.style || {}).textOverflow || "ellipsis"
15092                }), t4.shortened = true), t4.attr(e4.attribs), t4[t4.moved ? "animate" : "attr"](e4.posAttribs), t4.moved = true) : t4 && t4.attr({
15093                  y: -9999
15094                });
15095              }), delete t3.distributeBox;
15096            }, this);
15097          }
15098          function m(t3) {
15099            let e4 = this.center, i4 = this.options, s3 = i4.center, r3 = i4.minSize || 80, o3 = r3, n2 = null !== i4.size;
15100            return !n2 && (null !== s3[0] ? o3 = Math.max(e4[2] - Math.max(t3[1], t3[3]), r3) : (o3 = Math.max(e4[2] - t3[1] - t3[3], r3), e4[0] += (t3[3] - t3[1]) / 2), null !== s3[1] ? o3 = c(o3, r3, e4[2] - Math.max(t3[0], t3[2])) : (o3 = c(o3, r3, e4[2] - t3[0] - t3[2]), e4[1] += (t3[0] - t3[2]) / 2), o3 < e4[2] ? (e4[2] = o3, e4[3] = Math.min(i4.thickness ? Math.max(0, o3 - 2 * i4.thickness) : Math.max(0, f(i4.innerSize || 0, o3)), o3), this.translate(e4), this.drawDataLabels && this.drawDataLabels()) : n2 = true), n2;
15101          }
15102          e3.compose = function(e4) {
15103            if (t2.compose(l), g(n, "PieDataLabel")) {
15104              let t3 = e4.prototype;
15105              t3.dataLabelPositioners = i3, t3.alignDataLabel = a, t3.drawDataLabels = r2, t3.getDataLabelPosition = s2, t3.placeDataLabels = o2, t3.verifyDataLabelOverflow = m;
15106            }
15107          };
15108        }(o || (o = {})), o;
15109      }), i(e, "Core/Geometry/GeometryUtilities.js", [], function() {
15110        var t2, e2;
15111        return (e2 = t2 || (t2 = {})).getCenterOfPoints = function(t3) {
15112          let e3 = t3.reduce((t4, e4) => (t4.x += e4.x, t4.y += e4.y, t4), {
15113            x: 0,
15114            y: 0
15115          });
15116          return {
15117            x: e3.x / t3.length,
15118            y: e3.y / t3.length
15119          };
15120        }, e2.getDistanceBetweenPoints = function(t3, e3) {
15121          return Math.sqrt(Math.pow(e3.x - t3.x, 2) + Math.pow(e3.y - t3.y, 2));
15122        }, e2.getAngleBetweenPoints = function(t3, e3) {
15123          return Math.atan2(e3.x - t3.x, e3.y - t3.y);
15124        }, e2.pointInPolygon = function({
15125          x: t3,
15126          y: e3
15127        }, i2) {
15128          let s = i2.length, r, o, n = false;
15129          for (r = 0, o = s - 1; r < s; o = r++) {
15130            let [s2, a] = i2[r], [h, l] = i2[o];
15131            a > e3 != l > e3 && t3 < (h - s2) * (e3 - a) / (l - a) + s2 && (n = !n);
15132          }
15133          return n;
15134        }, t2;
15135      }), i(e, "Extensions/OverlappingDataLabels.js", [e["Core/Geometry/GeometryUtilities.js"], e["Core/Utilities.js"]], function(t2, e2) {
15136        let {
15137          pointInPolygon: i2
15138        } = t2, {
15139          addEvent: s,
15140          fireEvent: r,
15141          objectEach: o,
15142          pick: n
15143        } = e2;
15144        function a(t3) {
15145          let e3 = t3.length, s2 = (t4, e4) => !(e4.x >= t4.x + t4.width || e4.x + e4.width <= t4.x || e4.y >= t4.y + t4.height || e4.y + e4.height <= t4.y), o2 = (t4, e4) => {
15146            for (let s3 of t4) if (i2({
15147              x: s3[0],
15148              y: s3[1]
15149            }, e4)) return true;
15150            return false;
15151          }, n2, a2, l2, d, c, p = false;
15152          for (let i3 = 0; i3 < e3; i3++) (n2 = t3[i3]) && (n2.oldOpacity = n2.opacity, n2.newOpacity = 1, n2.absoluteBox = function(t4) {
15153            if (t4 && (!t4.alignAttr || t4.placed)) {
15154              let e4 = t4.box ? 0 : t4.padding || 0, i4 = t4.alignAttr || {
15155                x: t4.attr("x"),
15156                y: t4.attr("y")
15157              }, s3 = t4.getBBox();
15158              return t4.width = s3.width, t4.height = s3.height, {
15159                x: i4.x + (t4.parentGroup?.translateX || 0) + e4,
15160                y: i4.y + (t4.parentGroup?.translateY || 0) + e4,
15161                width: (t4.width || 0) - 2 * e4,
15162                height: (t4.height || 0) - 2 * e4,
15163                polygon: s3?.polygon
15164              };
15165            }
15166          }(n2));
15167          t3.sort((t4, e4) => (e4.labelrank || 0) - (t4.labelrank || 0));
15168          for (let i3 = 0; i3 < e3; ++i3) {
15169            d = (a2 = t3[i3]) && a2.absoluteBox;
15170            let r2 = d?.polygon;
15171            for (let n3 = i3 + 1; n3 < e3; ++n3) {
15172              c = (l2 = t3[n3]) && l2.absoluteBox;
15173              let e4 = false;
15174              if (d && c && a2 !== l2 && 0 !== a2.newOpacity && 0 !== l2.newOpacity && "hidden" !== a2.visibility && "hidden" !== l2.visibility) {
15175                let t4 = c.polygon;
15176                if (r2 && t4 && r2 !== t4 ? o2(r2, t4) && (e4 = true) : s2(d, c) && (e4 = true), e4) {
15177                  let t5 = a2.labelrank < l2.labelrank ? a2 : l2, e5 = t5.text;
15178                  t5.newOpacity = 0, e5?.element.querySelector("textPath") && e5.hide();
15179                }
15180              }
15181            }
15182          }
15183          for (let e4 of t3) h(e4, this) && (p = true);
15184          p && r(this, "afterHideAllOverlappingLabels");
15185        }
15186        function h(t3, e3) {
15187          let i3, s2, o2 = false;
15188          return t3 && (s2 = t3.newOpacity, t3.oldOpacity !== s2 && (t3.hasClass("highcharts-data-label") ? (t3[s2 ? "removeClass" : "addClass"]("highcharts-data-label-hidden"), i3 = function() {
15189            e3.styledMode || t3.css({
15190              pointerEvents: s2 ? "auto" : "none"
15191            });
15192          }, o2 = true, t3[t3.isOld ? "animate" : "attr"]({
15193            opacity: s2
15194          }, void 0, i3), r(e3, "afterHideOverlappingLabel")) : t3.attr({
15195            opacity: s2
15196          })), t3.isOld = true), o2;
15197        }
15198        function l() {
15199          let t3 = this, e3 = [];
15200          for (let i3 of t3.labelCollectors || []) e3 = e3.concat(i3());
15201          for (let i3 of t3.yAxis || []) i3.stacking && i3.options.stackLabels && !i3.options.stackLabels.allowOverlap && o(i3.stacking.stacks, (t4) => {
15202            o(t4, (t5) => {
15203              t5.label && e3.push(t5.label);
15204            });
15205          });
15206          for (let i3 of t3.series || []) if (i3.visible && i3.hasDataLabels?.()) {
15207            let s2 = (i4) => {
15208              for (let s3 of i4) s3.visible && (s3.dataLabels || []).forEach((i5) => {
15209                let r2 = i5.options || {};
15210                i5.labelrank = n(r2.labelrank, s3.labelrank, s3.shapeArgs?.height), r2.allowOverlap ?? Number(r2.distance) > 0 ? (i5.oldOpacity = i5.opacity, i5.newOpacity = 1, h(i5, t3)) : e3.push(i5);
15211              });
15212            };
15213            s2(i3.nodes || []), s2(i3.points);
15214          }
15215          this.hideOverlappingLabels(e3);
15216        }
15217        return {
15218          compose: function(t3) {
15219            let e3 = t3.prototype;
15220            e3.hideOverlappingLabels || (e3.hideOverlappingLabels = a, s(t3, "render", l));
15221          }
15222        };
15223      }), i(e, "Extensions/BorderRadius.js", [e["Core/Defaults.js"], e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
15224        let {
15225          defaultOptions: s
15226        } = t2, {
15227          noop: r
15228        } = e2, {
15229          addEvent: o,
15230          extend: n,
15231          isObject: a,
15232          merge: h,
15233          relativeLength: l
15234        } = i2, d = {
15235          radius: 0,
15236          scope: "stack",
15237          where: void 0
15238        }, c = r, p = r;
15239        function u11(t3, e3, i3, s2, r2 = {}) {
15240          let o2 = c(t3, e3, i3, s2, r2), {
15241            innerR: n2 = 0,
15242            r: a2 = i3,
15243            start: h2 = 0,
15244            end: d2 = 0
15245          } = r2;
15246          if (r2.open || !r2.borderRadius) return o2;
15247          let p2 = d2 - h2, g2 = Math.sin(p2 / 2), f2 = Math.max(Math.min(l(r2.borderRadius || 0, a2 - n2), (a2 - n2) / 2, a2 * g2 / (1 + g2)), 0), m2 = Math.min(f2, p2 / Math.PI * 2 * n2), x2 = o2.length - 1;
15248          for (; x2--; ) !function(t4, e4, i4) {
15249            let s3, r3, o3;
15250            let n3 = t4[e4], a3 = t4[e4 + 1];
15251            if ("Z" === a3[0] && (a3 = t4[0]), ("M" === n3[0] || "L" === n3[0]) && "A" === a3[0] ? (s3 = n3, r3 = a3, o3 = true) : "A" === n3[0] && ("M" === a3[0] || "L" === a3[0]) && (s3 = a3, r3 = n3), s3 && r3 && r3.params) {
15252              let n4 = r3[1], a4 = r3[5], h3 = r3.params, {
15253                start: l2,
15254                end: d3,
15255                cx: c2,
15256                cy: p3
15257              } = h3, u12 = a4 ? n4 - i4 : n4 + i4, g3 = u12 ? Math.asin(i4 / u12) : 0, f3 = a4 ? g3 : -g3, m3 = Math.cos(g3) * u12;
15258              o3 ? (h3.start = l2 + f3, s3[1] = c2 + m3 * Math.cos(l2), s3[2] = p3 + m3 * Math.sin(l2), t4.splice(e4 + 1, 0, ["A", i4, i4, 0, 0, 1, c2 + n4 * Math.cos(h3.start), p3 + n4 * Math.sin(h3.start)])) : (h3.end = d3 - f3, r3[6] = c2 + n4 * Math.cos(h3.end), r3[7] = p3 + n4 * Math.sin(h3.end), t4.splice(e4 + 1, 0, ["A", i4, i4, 0, 0, 1, c2 + m3 * Math.cos(d3), p3 + m3 * Math.sin(d3)])), r3[4] = Math.abs(h3.end - h3.start) < Math.PI ? 0 : 1;
15259            }
15260          }(o2, x2, x2 > 1 ? m2 : f2);
15261          return o2;
15262        }
15263        function g() {
15264          if (this.options.borderRadius && !(this.chart.is3d && this.chart.is3d())) {
15265            let {
15266              options: t3,
15267              yAxis: e3
15268            } = this, i3 = "percent" === t3.stacking, r2 = s.plotOptions?.[this.type]?.borderRadius, o2 = f(t3.borderRadius, a(r2) ? r2 : {}), h2 = e3.options.reversed;
15269            for (let s2 of this.points) {
15270              let {
15271                shapeArgs: r3
15272              } = s2;
15273              if ("roundedRect" === s2.shapeType && r3) {
15274                let {
15275                  width: a2 = 0,
15276                  height: d2 = 0,
15277                  y: c2 = 0
15278                } = r3, p2 = c2, u12 = d2;
15279                if ("stack" === o2.scope && s2.stackTotal) {
15280                  let r4 = e3.translate(i3 ? 100 : s2.stackTotal, false, true, false, true), o3 = e3.translate(t3.threshold || 0, false, true, false, true), n2 = this.crispCol(0, Math.min(r4, o3), 0, Math.abs(r4 - o3));
15281                  p2 = n2.y, u12 = n2.height;
15282                }
15283                let g2 = (s2.negative ? -1 : 1) * (h2 ? -1 : 1) == -1, f2 = o2.where;
15284                !f2 && this.is("waterfall") && Math.abs((s2.yBottom || 0) - (this.translatedThreshold || 0)) > this.borderWidth && (f2 = "all"), f2 || (f2 = "end");
15285                let m2 = Math.min(l(o2.radius, a2), a2 / 2, "all" === f2 ? d2 / 2 : 1 / 0) || 0;
15286                "end" === f2 && (g2 && (p2 -= m2), u12 += m2), n(r3, {
15287                  brBoxHeight: u12,
15288                  brBoxY: p2,
15289                  r: m2
15290                });
15291              }
15292            }
15293          }
15294        }
15295        function f(t3, e3) {
15296          return a(t3) || (t3 = {
15297            radius: t3 || 0
15298          }), h(d, e3, t3);
15299        }
15300        function m() {
15301          let t3 = f(this.options.borderRadius);
15302          for (let e3 of this.points) {
15303            let i3 = e3.shapeArgs;
15304            i3 && (i3.borderRadius = l(t3.radius, (i3.r || 0) - (i3.innerR || 0)));
15305          }
15306        }
15307        function x(t3, e3, i3, s2, r2 = {}) {
15308          let o2 = p(t3, e3, i3, s2, r2), {
15309            r: n2 = 0,
15310            brBoxHeight: a2 = s2,
15311            brBoxY: h2 = e3
15312          } = r2, l2 = e3 - h2, d2 = h2 + a2 - (e3 + s2), c2 = l2 - n2 > -0.1 ? 0 : n2, u12 = d2 - n2 > -0.1 ? 0 : n2, g2 = Math.max(c2 && l2, 0), f2 = Math.max(u12 && d2, 0), m2 = [t3 + c2, e3], y = [t3 + i3 - c2, e3], b = [t3 + i3, e3 + c2], v = [t3 + i3, e3 + s2 - u12], S2 = [t3 + i3 - u12, e3 + s2], C = [t3 + u12, e3 + s2], k = [t3, e3 + s2 - u12], M = [t3, e3 + c2], w = (t4, e4) => Math.sqrt(Math.pow(t4, 2) - Math.pow(e4, 2));
15313          if (g2) {
15314            let t4 = w(c2, c2 - g2);
15315            m2[0] -= t4, y[0] += t4, b[1] = M[1] = e3 + c2 - g2;
15316          }
15317          if (s2 < c2 - g2) {
15318            let r3 = w(c2, c2 - g2 - s2);
15319            b[0] = v[0] = t3 + i3 - c2 + r3, S2[0] = Math.min(b[0], S2[0]), C[0] = Math.max(v[0], C[0]), k[0] = M[0] = t3 + c2 - r3, b[1] = M[1] = e3 + s2;
15320          }
15321          if (f2) {
15322            let t4 = w(u12, u12 - f2);
15323            S2[0] += t4, C[0] -= t4, v[1] = k[1] = e3 + s2 - u12 + f2;
15324          }
15325          if (s2 < u12 - f2) {
15326            let r3 = w(u12, u12 - f2 - s2);
15327            b[0] = v[0] = t3 + i3 - u12 + r3, y[0] = Math.min(b[0], y[0]), m2[0] = Math.max(v[0], m2[0]), k[0] = M[0] = t3 + u12 - r3, v[1] = k[1] = e3;
15328          }
15329          return o2.length = 0, o2.push(["M", ...m2], ["L", ...y], ["A", c2, c2, 0, 0, 1, ...b], ["L", ...v], ["A", u12, u12, 0, 0, 1, ...S2], ["L", ...C], ["A", u12, u12, 0, 0, 1, ...k], ["L", ...M], ["A", c2, c2, 0, 0, 1, ...m2], ["Z"]), o2;
15330        }
15331        return {
15332          compose: function(t3, e3, i3) {
15333            let s2 = t3.types.pie;
15334            if (!e3.symbolCustomAttribs.includes("borderRadius")) {
15335              let r2 = i3.prototype.symbols;
15336              o(t3, "afterColumnTranslate", g, {
15337                order: 9
15338              }), o(s2, "afterTranslate", m), e3.symbolCustomAttribs.push("borderRadius", "brBoxHeight", "brBoxY"), c = r2.arc, p = r2.roundedRect, r2.arc = u11, r2.roundedRect = x;
15339            }
15340          },
15341          optionsToObject: f
15342        };
15343      }), i(e, "Core/Responsive.js", [e["Core/Utilities.js"]], function(t2) {
15344        var e2;
15345        let {
15346          diffObjects: i2,
15347          extend: s,
15348          find: r,
15349          merge: o,
15350          pick: n,
15351          uniqueKey: a
15352        } = t2;
15353        return function(t3) {
15354          function e3(t4, e4) {
15355            let i3 = t4.condition;
15356            (i3.callback || function() {
15357              return this.chartWidth <= n(i3.maxWidth, Number.MAX_VALUE) && this.chartHeight <= n(i3.maxHeight, Number.MAX_VALUE) && this.chartWidth >= n(i3.minWidth, 0) && this.chartHeight >= n(i3.minHeight, 0);
15358            }).call(this) && e4.push(t4._id);
15359          }
15360          function h(t4, e4) {
15361            let s2 = this.options.responsive, n2 = this.currentResponsive, h2 = [], l;
15362            !e4 && s2 && s2.rules && s2.rules.forEach((t5) => {
15363              void 0 === t5._id && (t5._id = a()), this.matchResponsiveRule(t5, h2);
15364            }, this);
15365            let d = o(...h2.map((t5) => r((s2 || {}).rules || [], (e5) => e5._id === t5)).map((t5) => t5 && t5.chartOptions));
15366            d.isResponsiveOptions = true, h2 = h2.toString() || void 0;
15367            let c = n2 && n2.ruleIds;
15368            h2 === c || (n2 && (this.currentResponsive = void 0, this.updatingResponsive = true, this.update(n2.undoOptions, t4, true), this.updatingResponsive = false), h2 ? ((l = i2(d, this.options, true, this.collectionsWithUpdate)).isResponsiveOptions = true, this.currentResponsive = {
15369              ruleIds: h2,
15370              mergedOptions: d,
15371              undoOptions: l
15372            }, this.updatingResponsive || this.update(d, t4, true)) : this.currentResponsive = void 0);
15373          }
15374          t3.compose = function(t4) {
15375            let i3 = t4.prototype;
15376            return i3.matchResponsiveRule || s(i3, {
15377              matchResponsiveRule: e3,
15378              setResponsive: h
15379            }), t4;
15380          };
15381        }(e2 || (e2 = {})), e2;
15382      }), i(e, "masters/highcharts.src.js", [e["Core/Globals.js"], e["Core/Utilities.js"], e["Core/Defaults.js"], e["Core/Animation/Fx.js"], e["Core/Animation/AnimationUtilities.js"], e["Core/Renderer/HTML/AST.js"], e["Core/Templating.js"], e["Core/Renderer/RendererRegistry.js"], e["Core/Renderer/RendererUtilities.js"], e["Core/Renderer/SVG/SVGElement.js"], e["Core/Renderer/SVG/SVGRenderer.js"], e["Core/Renderer/HTML/HTMLElement.js"], e["Core/Axis/Axis.js"], e["Core/Axis/DateTimeAxis.js"], e["Core/Axis/LogarithmicAxis.js"], e["Core/Axis/PlotLineOrBand/PlotLineOrBand.js"], e["Core/Axis/Tick.js"], e["Core/Tooltip.js"], e["Core/Series/Point.js"], e["Core/Pointer.js"], e["Core/Legend/Legend.js"], e["Core/Legend/LegendSymbol.js"], e["Core/Chart/Chart.js"], e["Extensions/ScrollablePlotArea.js"], e["Core/Axis/Stacking/StackingAxis.js"], e["Core/Axis/Stacking/StackItem.js"], e["Core/Series/Series.js"], e["Core/Series/SeriesRegistry.js"], e["Series/Column/ColumnDataLabel.js"], e["Series/Pie/PieDataLabel.js"], e["Core/Series/DataLabel.js"], e["Extensions/OverlappingDataLabels.js"], e["Extensions/BorderRadius.js"], e["Core/Responsive.js"], e["Core/Color/Color.js"], e["Core/Time.js"]], function(t2, e2, i2, s, r, o, n, a, h, l, d, c, p, u11, g, f, m, x, y, b, v, S2, C, k, M, w, T2, A, P, L, O, D2, E, I, j, B) {
15383        return t2.AST = o, t2.Axis = p, t2.Chart = C, t2.Color = j, t2.DataLabel = O, t2.Fx = s, t2.HTMLElement = c, t2.Legend = v, t2.LegendSymbol = S2, t2.OverlappingDataLabels = t2.OverlappingDataLabels || D2, t2.PlotLineOrBand = f, t2.Point = y, t2.Pointer = b, t2.RendererRegistry = a, t2.Series = T2, t2.SeriesRegistry = A, t2.StackItem = w, t2.SVGElement = l, t2.SVGRenderer = d, t2.Templating = n, t2.Tick = m, t2.Time = B, t2.Tooltip = x, t2.animate = r.animate, t2.animObject = r.animObject, t2.chart = C.chart, t2.color = j.parse, t2.dateFormat = n.dateFormat, t2.defaultOptions = i2.defaultOptions, t2.distribute = h.distribute, t2.format = n.format, t2.getDeferredAnimation = r.getDeferredAnimation, t2.getOptions = i2.getOptions, t2.numberFormat = n.numberFormat, t2.seriesType = A.seriesType, t2.setAnimation = r.setAnimation, t2.setOptions = i2.setOptions, t2.stop = r.stop, t2.time = i2.defaultTime, t2.timers = s.timers, E.compose(t2.Series, t2.SVGElement, t2.SVGRenderer), P.compose(t2.Series.types.column), O.compose(t2.Series), u11.compose(t2.Axis), c.compose(t2.SVGRenderer), v.compose(t2.Chart), g.compose(t2.Axis), D2.compose(t2.Chart), L.compose(t2.Series.types.pie), f.compose(t2.Chart, t2.Axis), b.compose(t2.Chart), I.compose(t2.Chart), k.compose(t2.Axis, t2.Chart, t2.Series), M.compose(t2.Axis, t2.Chart, t2.Series), x.compose(t2.Pointer), e2.extend(t2, e2), t2;
15384      }), e["masters/highcharts.src.js"]._modules = e, e["masters/highcharts.src.js"];
15385    });
15386  }
15387});
15388
vendor: 31,911 bytes, lines 15389-16038
15389// node_modules/highcharts/modules/exporting.js
15390var require_exporting = __commonJS({
15391  "node_modules/highcharts/modules/exporting.js"(exports, module) {
15392    "use strict";
15393    !/**
15394    * Highcharts JS v11.4.8 (2024-08-29)
15395    *
15396    * Exporting module
15397    *
15398    * (c) 2010-2024 Torstein Honsi
15399    *
15400    * License: www.highcharts.com/license
15401    */
15402    function(e) {
15403      "object" == typeof module && module.exports ? (e.default = e, module.exports = e) : "function" == typeof define && define.amd ? define("highcharts/modules/exporting", ["highcharts"], function(t) {
15404        return e(t), e.Highcharts = t, e;
15405      }) : e("undefined" != typeof Highcharts ? Highcharts : void 0);
15406    }(function(e) {
15407      "use strict";
15408      var t = e ? e._modules : {};
15409      function n(t2, n2, i, o) {
15410        t2.hasOwnProperty(n2) || (t2[n2] = o.apply(null, i), "function" == typeof CustomEvent && e.win.dispatchEvent(new CustomEvent("HighchartsModuleLoaded", {
15411          detail: {
15412            path: n2,
15413            module: t2[n2]
15414          }
15415        })));
15416      }
15417      n(t, "Core/Chart/ChartNavigationComposition.js", [], function() {
15418        var e2;
15419        return function(e3) {
15420          e3.compose = function(e4) {
15421            return e4.navigation || (e4.navigation = new t2(e4)), e4;
15422          };
15423          class t2 {
15424            constructor(e4) {
15425              this.updates = [], this.chart = e4;
15426            }
15427            addUpdate(e4) {
15428              this.chart.navigation.updates.push(e4);
15429            }
15430            update(e4, t3) {
15431              this.updates.forEach((n2) => {
15432                n2.call(this.chart, e4, t3);
15433              });
15434            }
15435          }
15436          e3.Additions = t2;
15437        }(e2 || (e2 = {})), e2;
15438      }), n(t, "Extensions/Exporting/ExportingDefaults.js", [t["Core/Globals.js"]], function(e2) {
15439        let {
15440          isTouchDevice: t2
15441        } = e2;
15442        return {
15443          exporting: {
15444            allowTableSorting: true,
15445            type: "image/png",
15446            url: "https://export.highcharts.com/",
15447            pdfFont: {
15448              normal: void 0,
15449              bold: void 0,
15450              bolditalic: void 0,
15451              italic: void 0
15452            },
15453            printMaxWidth: 780,
15454            scale: 2,
15455            buttons: {
15456              contextButton: {
15457                className: "highcharts-contextbutton",
15458                menuClassName: "highcharts-contextmenu",
15459                symbol: "menu",
15460                titleKey: "contextButtonTitle",
15461                menuItems: ["viewFullscreen", "printChart", "separator", "downloadPNG", "downloadJPEG", "downloadPDF", "downloadSVG"]
15462              }
15463            },
15464            menuItemDefinitions: {
15465              viewFullscreen: {
15466                textKey: "viewFullscreen",
15467                onclick: function() {
15468                  this.fullscreen && this.fullscreen.toggle();
15469                }
15470              },
15471              printChart: {
15472                textKey: "printChart",
15473                onclick: function() {
15474                  this.print();
15475                }
15476              },
15477              separator: {
15478                separator: true
15479              },
15480              downloadPNG: {
15481                textKey: "downloadPNG",
15482                onclick: function() {
15483                  this.exportChart();
15484                }
15485              },
15486              downloadJPEG: {
15487                textKey: "downloadJPEG",
15488                onclick: function() {
15489                  this.exportChart({
15490                    type: "image/jpeg"
15491                  });
15492                }
15493              },
15494              downloadPDF: {
15495                textKey: "downloadPDF",
15496                onclick: function() {
15497                  this.exportChart({
15498                    type: "application/pdf"
15499                  });
15500                }
15501              },
15502              downloadSVG: {
15503                textKey: "downloadSVG",
15504                onclick: function() {
15505                  this.exportChart({
15506                    type: "image/svg+xml"
15507                  });
15508                }
15509              }
15510            }
15511          },
15512          lang: {
15513            viewFullscreen: "View in full screen",
15514            exitFullscreen: "Exit from full screen",
15515            printChart: "Print chart",
15516            downloadPNG: "Download PNG image",
15517            downloadJPEG: "Download JPEG image",
15518            downloadPDF: "Download PDF document",
15519            downloadSVG: "Download SVG vector image",
15520            contextButtonTitle: "Chart context menu"
15521          },
15522          navigation: {
15523            buttonOptions: {
15524              symbolSize: 14,
15525              symbolX: 14.5,
15526              symbolY: 13.5,
15527              align: "right",
15528              buttonSpacing: 3,
15529              height: 28,
15530              verticalAlign: "top",
15531              width: 28,
15532              symbolFill: "#666666",
15533              symbolStroke: "#666666",
15534              symbolStrokeWidth: 3,
15535              theme: {
15536                fill: "#ffffff",
15537                padding: 5,
15538                stroke: "none",
15539                "stroke-linecap": "round"
15540              }
15541            },
15542            menuStyle: {
15543              border: "none",
15544              borderRadius: "3px",
15545              background: "#ffffff",
15546              padding: "0.5em"
15547            },
15548            menuItemStyle: {
15549              background: "none",
15550              borderRadius: "3px",
15551              color: "#333333",
15552              padding: "0.5em",
15553              fontSize: t2 ? "0.9em" : "0.8em",
15554              transition: "background 250ms, color 250ms"
15555            },
15556            menuItemHoverStyle: {
15557              background: "#f2f2f2"
15558            }
15559          }
15560        };
15561      }), n(t, "Extensions/Exporting/ExportingSymbols.js", [], function() {
15562        var e2;
15563        return function(e3) {
15564          let t2 = [];
15565          function n2(e4, t3, n3, i2) {
15566            return [["M", e4, t3 + 2.5], ["L", e4 + n3, t3 + 2.5], ["M", e4, t3 + i2 / 2 + 0.5], ["L", e4 + n3, t3 + i2 / 2 + 0.5], ["M", e4, t3 + i2 - 1.5], ["L", e4 + n3, t3 + i2 - 1.5]];
15567          }
15568          function i(e4, t3, n3, i2) {
15569            let o = i2 / 3 - 2;
15570            return [].concat(this.circle(n3 - o, t3, o, o), this.circle(n3 - o, t3 + o + 4, o, o), this.circle(n3 - o, t3 + 2 * (o + 4), o, o));
15571          }
15572          e3.compose = function(e4) {
15573            if (-1 === t2.indexOf(e4)) {
15574              t2.push(e4);
15575              let o = e4.prototype.symbols;
15576              o.menu = n2, o.menuball = i.bind(o);
15577            }
15578          };
15579        }(e2 || (e2 = {})), e2;
15580      }), n(t, "Extensions/Exporting/Fullscreen.js", [t["Core/Renderer/HTML/AST.js"], t["Core/Globals.js"], t["Core/Utilities.js"]], function(e2, t2, n2) {
15581        let {
15582          composed: i
15583        } = t2, {
15584          addEvent: o,
15585          fireEvent: r,
15586          pushUnique: s
15587        } = n2;
15588        function l() {
15589          this.fullscreen = new a(this);
15590        }
15591        class a {
15592          static compose(e3) {
15593            s(i, "Fullscreen") && o(e3, "beforeRender", l);
15594          }
15595          constructor(e3) {
15596            this.chart = e3, this.isOpen = false;
15597            let t3 = e3.renderTo;
15598            !this.browserProps && ("function" == typeof t3.requestFullscreen ? this.browserProps = {
15599              fullscreenChange: "fullscreenchange",
15600              requestFullscreen: "requestFullscreen",
15601              exitFullscreen: "exitFullscreen"
15602            } : t3.mozRequestFullScreen ? this.browserProps = {
15603              fullscreenChange: "mozfullscreenchange",
15604              requestFullscreen: "mozRequestFullScreen",
15605              exitFullscreen: "mozCancelFullScreen"
15606            } : t3.webkitRequestFullScreen ? this.browserProps = {
15607              fullscreenChange: "webkitfullscreenchange",
15608              requestFullscreen: "webkitRequestFullScreen",
15609              exitFullscreen: "webkitExitFullscreen"
15610            } : t3.msRequestFullscreen && (this.browserProps = {
15611              fullscreenChange: "MSFullscreenChange",
15612              requestFullscreen: "msRequestFullscreen",
15613              exitFullscreen: "msExitFullscreen"
15614            }));
15615          }
15616          close() {
15617            let e3 = this, t3 = e3.chart, n3 = t3.options.chart;
15618            r(t3, "fullscreenClose", null, function() {
15619              e3.isOpen && e3.browserProps && t3.container.ownerDocument instanceof Document && t3.container.ownerDocument[e3.browserProps.exitFullscreen](), e3.unbindFullscreenEvent && (e3.unbindFullscreenEvent = e3.unbindFullscreenEvent()), t3.setSize(e3.origWidth, e3.origHeight, false), e3.origWidth = void 0, e3.origHeight = void 0, n3.width = e3.origWidthOption, n3.height = e3.origHeightOption, e3.origWidthOption = void 0, e3.origHeightOption = void 0, e3.isOpen = false, e3.setButtonText();
15620            });
15621          }
15622          open() {
15623            let e3 = this, t3 = e3.chart, n3 = t3.options.chart;
15624            r(t3, "fullscreenOpen", null, function() {
15625              if (n3 && (e3.origWidthOption = n3.width, e3.origHeightOption = n3.height), e3.origWidth = t3.chartWidth, e3.origHeight = t3.chartHeight, e3.browserProps) {
15626                let n4 = o(t3.container.ownerDocument, e3.browserProps.fullscreenChange, function() {
15627                  e3.isOpen ? (e3.isOpen = false, e3.close()) : (t3.setSize(null, null, false), e3.isOpen = true, e3.setButtonText());
15628                }), i2 = o(t3, "destroy", n4);
15629                e3.unbindFullscreenEvent = () => {
15630                  n4(), i2();
15631                };
15632                let r2 = t3.renderTo[e3.browserProps.requestFullscreen]();
15633                r2 && r2.catch(function() {
15634                  alert("Full screen is not supported inside a frame.");
15635                });
15636              }
15637            });
15638          }
15639          setButtonText() {
15640            let t3 = this.chart, n3 = t3.exportDivElements, i2 = t3.options.exporting, o2 = i2 && i2.buttons && i2.buttons.contextButton.menuItems, r2 = t3.options.lang;
15641            if (i2 && i2.menuItemDefinitions && r2 && r2.exitFullscreen && r2.viewFullscreen && o2 && n3) {
15642              let t4 = n3[o2.indexOf("viewFullscreen")];
15643              t4 && e2.setElementHTML(t4, this.isOpen ? r2.exitFullscreen : i2.menuItemDefinitions.viewFullscreen.text || r2.viewFullscreen);
15644            }
15645          }
15646          toggle() {
15647            this.isOpen ? this.close() : this.open();
15648          }
15649        }
15650        return a;
15651      }), n(t, "Core/HttpUtilities.js", [t["Core/Globals.js"], t["Core/Utilities.js"]], function(e2, t2) {
15652        let {
15653          win: n2
15654        } = e2, {
15655          discardElement: i,
15656          objectEach: o
15657        } = t2, r = {
15658          ajax: function(e3) {
15659            let t3 = {
15660              json: "application/json",
15661              xml: "application/xml",
15662              text: "text/plain",
15663              octet: "application/octet-stream"
15664            }, n3 = new XMLHttpRequest();
15665            function i2(t4, n4) {
15666              e3.error && e3.error(t4, n4);
15667            }
15668            if (!e3.url) return false;
15669            n3.open((e3.type || "get").toUpperCase(), e3.url, true), e3.headers && e3.headers["Content-Type"] || n3.setRequestHeader("Content-Type", t3[e3.dataType || "json"] || t3.text), o(e3.headers, function(e4, t4) {
15670              n3.setRequestHeader(t4, e4);
15671            }), e3.responseType && (n3.responseType = e3.responseType), n3.onreadystatechange = function() {
15672              let t4;
15673              if (4 === n3.readyState) {
15674                if (200 === n3.status) {
15675                  if ("blob" !== e3.responseType && (t4 = n3.responseText, "json" === e3.dataType)) try {
15676                    t4 = JSON.parse(t4);
15677                  } catch (e4) {
15678                    if (e4 instanceof Error) return i2(n3, e4);
15679                  }
15680                  return e3.success && e3.success(t4, n3);
15681                }
15682                i2(n3, n3.responseText);
15683              }
15684            }, e3.data && "string" != typeof e3.data && (e3.data = JSON.stringify(e3.data)), n3.send(e3.data);
15685          },
15686          getJSON: function(e3, t3) {
15687            r.ajax({
15688              url: e3,
15689              success: t3,
15690              dataType: "json",
15691              headers: {
15692                "Content-Type": "text/plain"
15693              }
15694            });
15695          },
15696          post: function(e3, t3, r2) {
15697            let s = new n2.FormData();
15698            o(t3, function(e4, t4) {
15699              s.append(t4, e4);
15700            }), s.append("b64", "true");
15701            let {
15702              filename: l,
15703              type: a
15704            } = t3;
15705            return n2.fetch(e3, __spreadValues({
15706              method: "POST",
15707              body: s
15708            }, r2)).then((e4) => {
15709              e4.ok && e4.text().then((e5) => {
15710                let t4 = document.createElement("a");
15711                t4.href = `data:${a};base64,${e5}`, t4.download = l, t4.click(), i(t4);
15712              });
15713            });
15714          }
15715        };
15716        return r;
15717      }), n(t, "Extensions/Exporting/Exporting.js", [t["Core/Renderer/HTML/AST.js"], t["Core/Chart/Chart.js"], t["Core/Chart/ChartNavigationComposition.js"], t["Core/Defaults.js"], t["Extensions/Exporting/ExportingDefaults.js"], t["Extensions/Exporting/ExportingSymbols.js"], t["Extensions/Exporting/Fullscreen.js"], t["Core/Globals.js"], t["Core/HttpUtilities.js"], t["Core/Utilities.js"]], function(e2, t2, n2, i, o, r, s, l, a, c) {
15718        var u11;
15719        let {
15720          defaultOptions: p
15721        } = i, {
15722          doc: h,
15723          SVG_NS: d,
15724          win: g
15725        } = l, {
15726          addEvent: f,
15727          css: m,
15728          createElement: x,
15729          discardElement: y,
15730          extend: b,
15731          find: v,
15732          fireEvent: w,
15733          isObject: E,
15734          merge: C,
15735          objectEach: S2,
15736          pick: F,
15737          removeEvent: T2,
15738          uniqueKey: O
15739        } = c;
15740        return function(t3) {
15741          let i2;
15742          let u12 = [/-/, /^(clipPath|cssText|d|height|width)$/, /^font$/, /[lL]ogical(Width|Height)$/, /^parentRule$/, /^(cssRules|ownerRules)$/, /perspective/, /TapHighlightColor/, /^transition/, /^length$/, /^\d+$/], M = ["fill", "stroke", "strokeLinecap", "strokeLinejoin", "strokeWidth", "textAnchor", "x", "y"];
15743          t3.inlineAllowlist = [];
15744          let P = ["clipPath", "defs", "desc"];
15745          function k(e3) {
15746            let t4, n3;
15747            let i3 = this, o2 = i3.renderer, r2 = C(i3.options.navigation.buttonOptions, e3), s2 = r2.onclick, l2 = r2.menuItems, a2 = r2.symbolSize || 12;
15748            if (i3.btnCount || (i3.btnCount = 0), i3.exportDivElements || (i3.exportDivElements = [], i3.exportSVGElements = []), false === r2.enabled || !r2.theme) return;
15749            let c2 = i3.styledMode ? {} : r2.theme;
15750            s2 ? n3 = function(e4) {
15751              e4 && e4.stopPropagation(), s2.call(i3, e4);
15752            } : l2 && (n3 = function(e4) {
15753              e4 && e4.stopPropagation(), i3.contextMenu(u13.menuClassName, l2, u13.translateX || 0, u13.translateY || 0, u13.width || 0, u13.height || 0, u13), u13.setState(2);
15754            }), r2.text && r2.symbol ? c2.paddingLeft = F(c2.paddingLeft, 30) : r2.text || b(c2, {
15755              width: r2.width,
15756              height: r2.height,
15757              padding: 0
15758            });
15759            let u13 = o2.button(r2.text, 0, 0, n3, c2, void 0, void 0, void 0, void 0, r2.useHTML).addClass(e3.className).attr({
15760              title: F(i3.options.lang[r2._titleKey || r2.titleKey], "")
15761            });
15762            u13.menuClassName = e3.menuClassName || "highcharts-menu-" + i3.btnCount++, r2.symbol && (t4 = o2.symbol(r2.symbol, Math.round((r2.symbolX || 0) - a2 / 2), Math.round((r2.symbolY || 0) - a2 / 2), a2, a2, {
15763              width: a2,
15764              height: a2
15765            }).addClass("highcharts-button-symbol").attr({
15766              zIndex: 1
15767            }).add(u13), i3.styledMode || t4.attr({
15768              stroke: r2.symbolStroke,
15769              fill: r2.symbolFill,
15770              "stroke-width": r2.symbolStrokeWidth || 1
15771            })), u13.add(i3.exportingGroup).align(b(r2, {
15772              width: u13.width,
15773              x: F(r2.x, i3.buttonOffset)
15774            }), true, "spacingBox"), i3.buttonOffset += ((u13.width || 0) + r2.buttonSpacing) * ("right" === r2.align ? -1 : 1), i3.exportSVGElements.push(u13, t4);
15775          }
15776          function N() {
15777            if (!this.printReverseInfo) return;
15778            let {
15779              childNodes: e3,
15780              origDisplay: t4,
15781              resetParams: n3
15782            } = this.printReverseInfo;
15783            this.moveContainers(this.renderTo), [].forEach.call(e3, function(e4, n4) {
15784              1 === e4.nodeType && (e4.style.display = t4[n4] || "");
15785            }), this.isPrinting = false, n3 && this.setSize.apply(this, n3), delete this.printReverseInfo, i2 = void 0, w(this, "afterPrint");
15786          }
15787          function H() {
15788            let e3 = h.body, t4 = this.options.exporting.printMaxWidth, n3 = {
15789              childNodes: e3.childNodes,
15790              origDisplay: [],
15791              resetParams: void 0
15792            };
15793            this.isPrinting = true, this.pointer?.reset(void 0, 0), w(this, "beforePrint"), t4 && this.chartWidth > t4 && (n3.resetParams = [this.options.chart.width, void 0, false], this.setSize(t4, void 0, false)), [].forEach.call(n3.childNodes, function(e4, t5) {
15794              1 === e4.nodeType && (n3.origDisplay[t5] = e4.style.display, e4.style.display = "none");
15795            }), this.moveContainers(e3), this.printReverseInfo = n3;
15796          }
15797          function j(e3) {
15798            e3.renderExporting(), f(e3, "redraw", e3.renderExporting), f(e3, "destroy", e3.destroyExport);
15799          }
15800          function G(t4, n3, i3, o2, r2, s2, l2) {
15801            let a2 = this, u13 = a2.options.navigation, p2 = a2.chartWidth, d2 = a2.chartHeight, y2 = "cache-" + t4, v2 = Math.max(r2, s2), C2, S3 = a2[y2];
15802            S3 || (a2.exportContextMenu = a2[y2] = S3 = x("div", {
15803              className: t4
15804            }, __spreadValues({
15805              position: "absolute",
15806              zIndex: 1e3,
15807              padding: v2 + "px",
15808              pointerEvents: "auto"
15809            }, a2.renderer.style), a2.scrollablePlotArea?.fixedDiv || a2.container), C2 = x("ul", {
15810              className: "highcharts-menu"
15811            }, a2.styledMode ? {} : {
15812              listStyle: "none",
15813              margin: 0,
15814              padding: 0
15815            }, S3), a2.styledMode || m(C2, b({
15816              MozBoxShadow: "3px 3px 10px #888",
15817              WebkitBoxShadow: "3px 3px 10px #888",
15818              boxShadow: "3px 3px 10px #888"
15819            }, u13.menuStyle)), S3.hideMenu = function() {
15820              m(S3, {
15821                display: "none"
15822              }), l2 && l2.setState(0), a2.openMenu = false, m(a2.renderTo, {
15823                overflow: "hidden"
15824              }), m(a2.container, {
15825                overflow: "hidden"
15826              }), c.clearTimeout(S3.hideTimer), w(a2, "exportMenuHidden");
15827            }, a2.exportEvents.push(f(S3, "mouseleave", function() {
15828              S3.hideTimer = g.setTimeout(S3.hideMenu, 500);
15829            }), f(S3, "mouseenter", function() {
15830              c.clearTimeout(S3.hideTimer);
15831            }), f(h, "mouseup", function(e3) {
15832              a2.pointer?.inClass(e3.target, t4) || S3.hideMenu();
15833            }), f(S3, "click", function() {
15834              a2.openMenu && S3.hideMenu();
15835            })), n3.forEach(function(t5) {
15836              if ("string" == typeof t5 && (t5 = a2.options.exporting.menuItemDefinitions[t5]), E(t5, true)) {
15837                let n4;
15838                t5.separator ? n4 = x("hr", void 0, void 0, C2) : ("viewData" === t5.textKey && a2.isDataTableVisible && (t5.textKey = "hideData"), n4 = x("li", {
15839                  className: "highcharts-menu-item",
15840                  onclick: function(e3) {
15841                    e3 && e3.stopPropagation(), S3.hideMenu(), "string" != typeof t5 && t5.onclick && t5.onclick.apply(a2, arguments);
15842                  }
15843                }, void 0, C2), e2.setElementHTML(n4, t5.text || a2.options.lang[t5.textKey]), a2.styledMode || (n4.onmouseover = function() {
15844                  m(this, u13.menuItemHoverStyle);
15845                }, n4.onmouseout = function() {
15846                  m(this, u13.menuItemStyle);
15847                }, m(n4, b({
15848                  cursor: "pointer"
15849                }, u13.menuItemStyle || {})))), a2.exportDivElements.push(n4);
15850              }
15851            }), a2.exportDivElements.push(C2, S3), a2.exportMenuWidth = S3.offsetWidth, a2.exportMenuHeight = S3.offsetHeight);
15852            let F2 = {
15853              display: "block"
15854            };
15855            i3 + (a2.exportMenuWidth || 0) > p2 ? F2.right = p2 - i3 - r2 - v2 + "px" : F2.left = i3 - v2 + "px", o2 + s2 + (a2.exportMenuHeight || 0) > d2 && l2.alignOptions?.verticalAlign !== "top" ? F2.bottom = d2 - o2 - v2 + "px" : F2.top = o2 + s2 - v2 + "px", m(S3, F2), m(a2.renderTo, {
15856              overflow: ""
15857            }), m(a2.container, {
15858              overflow: ""
15859            }), a2.openMenu = true, w(a2, "exportMenuShown");
15860          }
15861          function D2(e3) {
15862            let t4;
15863            let n3 = e3 ? e3.target : this, i3 = n3.exportSVGElements, o2 = n3.exportDivElements, r2 = n3.exportEvents;
15864            i3 && (i3.forEach((e4, o3) => {
15865              e4 && (e4.onclick = e4.ontouchstart = null, n3[t4 = "cache-" + e4.menuClassName] && delete n3[t4], i3[o3] = e4.destroy());
15866            }), i3.length = 0), n3.exportingGroup && (n3.exportingGroup.destroy(), delete n3.exportingGroup), o2 && (o2.forEach(function(e4, t5) {
15867              e4 && (c.clearTimeout(e4.hideTimer), T2(e4, "mouseleave"), o2[t5] = e4.onmouseout = e4.onmouseover = e4.ontouchstart = e4.onclick = null, y(e4));
15868            }), o2.length = 0), r2 && (r2.forEach(function(e4) {
15869              e4();
15870            }), r2.length = 0);
15871          }
15872          function I(e3, t4) {
15873            let n3 = this.getSVGForExport(e3, t4);
15874            e3 = C(this.options.exporting, e3), a.post(e3.url, {
15875              filename: e3.filename ? e3.filename.replace(/\//g, "-") : this.getFilename(),
15876              type: e3.type,
15877              width: e3.width,
15878              scale: e3.scale,
15879              svg: n3
15880            }, e3.fetchOptions);
15881          }
15882          function W() {
15883            return this.styledMode && this.inlineStyles(), this.container.innerHTML;
15884          }
15885          function R() {
15886            let e3 = this.userOptions.title && this.userOptions.title.text, t4 = this.options.exporting.filename;
15887            return t4 ? t4.replace(/\//g, "-") : ("string" == typeof e3 && (t4 = e3.toLowerCase().replace(/<\/?[^>]+(>|$)/g, "").replace(/[\s_]+/g, "-").replace(/[^a-z\d\-]/g, "").replace(/^[\-]+/g, "").replace(/[\-]+/g, "-").substr(0, 24).replace(/[\-]+$/g, "")), (!t4 || t4.length < 5) && (t4 = "chart"), t4);
15888          }
15889          function L(e3) {
15890            let t4, n3, i3 = C(this.options, e3);
15891            i3.plotOptions = C(this.userOptions.plotOptions, e3 && e3.plotOptions), i3.time = C(this.userOptions.time, e3 && e3.time);
15892            let o2 = x("div", null, {
15893              position: "absolute",
15894              top: "-9999em",
15895              width: this.chartWidth + "px",
15896              height: this.chartHeight + "px"
15897            }, h.body), r2 = this.renderTo.style.width, s2 = this.renderTo.style.height, l2 = i3.exporting.sourceWidth || i3.chart.width || /px$/.test(r2) && parseInt(r2, 10) || (i3.isGantt ? 800 : 600), a2 = i3.exporting.sourceHeight || i3.chart.height || /px$/.test(s2) && parseInt(s2, 10) || 400;
15898            b(i3.chart, {
15899              animation: false,
15900              renderTo: o2,
15901              forExport: true,
15902              renderer: "SVGRenderer",
15903              width: l2,
15904              height: a2
15905            }), i3.exporting.enabled = false, delete i3.data, i3.series = [], this.series.forEach(function(e4) {
15906              (n3 = C(e4.userOptions, {
15907                animation: false,
15908                enableMouseTracking: false,
15909                showCheckbox: false,
15910                visible: e4.visible
15911              })).isInternal || i3.series.push(n3);
15912            });
15913            let c2 = {};
15914            this.axes.forEach(function(e4) {
15915              e4.userOptions.internalKey || (e4.userOptions.internalKey = O()), e4.options.isInternal || (c2[e4.coll] || (c2[e4.coll] = true, i3[e4.coll] = []), i3[e4.coll].push(C(e4.userOptions, {
15916                visible: e4.visible,
15917                type: e4.type,
15918                uniqueNames: e4.uniqueNames
15919              })));
15920            }), i3.colorAxis = this.userOptions.colorAxis;
15921            let u13 = new this.constructor(i3, this.callback);
15922            return e3 && ["xAxis", "yAxis", "series"].forEach(function(t5) {
15923              let n4 = {};
15924              e3[t5] && (n4[t5] = e3[t5], u13.update(n4));
15925            }), this.axes.forEach(function(e4) {
15926              let t5 = v(u13.axes, function(t6) {
15927                return t6.options.internalKey === e4.userOptions.internalKey;
15928              }), n4 = e4.getExtremes(), i4 = n4.userMin, o3 = n4.userMax;
15929              t5 && (void 0 !== i4 && i4 !== t5.min || void 0 !== o3 && o3 !== t5.max) && t5.setExtremes(i4, o3, true, false);
15930            }), t4 = u13.getChartHTML(), w(this, "getSVG", {
15931              chartCopy: u13
15932            }), t4 = this.sanitizeSVG(t4, i3), i3 = null, u13.destroy(), y(o2), t4;
15933          }
15934          function q(e3, t4) {
15935            let n3 = this.options.exporting;
15936            return this.getSVG(C({
15937              chart: {
15938                borderRadius: 0
15939              }
15940            }, n3.chartOptions, t4, {
15941              exporting: {
15942                sourceWidth: e3 && e3.sourceWidth || n3.sourceWidth,
15943                sourceHeight: e3 && e3.sourceHeight || n3.sourceHeight
15944              }
15945            }));
15946          }
15947          function $() {
15948            let e3;
15949            let n3 = t3.inlineAllowlist, i3 = {}, o2 = h.createElement("iframe");
15950            m(o2, {
15951              width: "1px",
15952              height: "1px",
15953              visibility: "hidden"
15954            }), h.body.appendChild(o2);
15955            let r2 = o2.contentWindow && o2.contentWindow.document;
15956            r2 && r2.body.appendChild(r2.createElementNS(d, "svg")), function t4(o3) {
15957              let s2, a2, c2, p2, h2, d2;
15958              let f2 = {};
15959              if (r2 && 1 === o3.nodeType && -1 === P.indexOf(o3.nodeName)) {
15960                if (s2 = g.getComputedStyle(o3, null), a2 = "svg" === o3.nodeName ? {} : g.getComputedStyle(o3.parentNode, null), !i3[o3.nodeName]) {
15961                  e3 = r2.getElementsByTagName("svg")[0], c2 = r2.createElementNS(o3.namespaceURI, o3.nodeName), e3.appendChild(c2);
15962                  let t5 = g.getComputedStyle(c2, null), n4 = {};
15963                  for (let e4 in t5) e4.length < 1e3 && "string" == typeof t5[e4] && !/^\d+$/.test(e4) && (n4[e4] = t5[e4]);
15964                  i3[o3.nodeName] = n4, "text" === o3.nodeName && delete i3.text.fill, e3.removeChild(c2);
15965                }
15966                for (let e4 in s2) (l.isFirefox || l.isMS || l.isSafari || Object.hasOwnProperty.call(s2, e4)) && function(e5, t5) {
15967                  if (p2 = h2 = false, n3.length) {
15968                    for (d2 = n3.length; d2-- && !h2; ) h2 = n3[d2].test(t5);
15969                    p2 = !h2;
15970                  }
15971                  for ("transform" === t5 && "none" === e5 && (p2 = true), d2 = u12.length; d2-- && !p2; ) {
15972                    if (t5.length > 1e3) throw Error("Input too long");
15973                    p2 = u12[d2].test(t5) || "function" == typeof e5;
15974                  }
15975                  !p2 && (a2[t5] !== e5 || "svg" === o3.nodeName) && i3[o3.nodeName][t5] !== e5 && (M && -1 === M.indexOf(t5) ? f2[t5] = e5 : e5 && o3.setAttribute(t5.replace(/[A-Z]/g, function(e6) {
15976                    return "-" + e6.toLowerCase();
15977                  }), e5));
15978                }(s2[e4], e4);
15979                if (m(o3, f2), "svg" === o3.nodeName && o3.setAttribute("stroke-width", "1px"), "text" === o3.nodeName) return;
15980                [].forEach.call(o3.children || o3.childNodes, t4);
15981              }
15982            }(this.container.querySelector("svg")), e3.parentNode.removeChild(e3), o2.parentNode.removeChild(o2);
15983          }
15984          function z(e3) {
15985            let {
15986              scrollablePlotArea: t4
15987            } = this;
15988            (t4 ? [t4.fixedDiv, t4.scrollingContainer] : [this.container]).forEach(function(t5) {
15989              e3.appendChild(t5);
15990            });
15991          }
15992          function V() {
15993            let e3 = this, t4 = (t5, n3, i3) => {
15994              e3.isDirtyExporting = true, C(true, e3.options[t5], n3), F(i3, true) && e3.redraw();
15995            };
15996            e3.exporting = {
15997              update: function(e4, n3) {
15998                t4("exporting", e4, n3);
15999              }
16000            }, n2.compose(e3).navigation.addUpdate((e4, n3) => {
16001              t4("navigation", e4, n3);
16002            });
16003          }
16004          function A() {
16005            let e3 = this;
16006            e3.isPrinting || (i2 = e3, l.isSafari || e3.beforePrint(), setTimeout(() => {
16007              g.focus(), g.print(), l.isSafari || setTimeout(() => {
16008                e3.afterPrint();
16009              }, 1e3);
16010            }, 1));
16011          }
16012          function K() {
16013            let e3 = this, t4 = e3.options.exporting, n3 = t4.buttons, i3 = e3.isDirtyExporting || !e3.exportSVGElements;
16014            e3.buttonOffset = 0, e3.isDirtyExporting && e3.destroyExport(), i3 && false !== t4.enabled && (e3.exportEvents = [], e3.exportingGroup = e3.exportingGroup || e3.renderer.g("exporting-group").attr({
16015              zIndex: 3
16016            }).add(), S2(n3, function(t5) {
16017              e3.addButton(t5);
16018            }), e3.isDirtyExporting = false);
16019          }
16020          function U(e3, t4) {
16021            let n3 = e3.indexOf("</svg>") + 6, i3 = e3.substr(n3);
16022            return e3 = e3.substr(0, n3), t4 && t4.exporting && t4.exporting.allowHTML && i3 && (i3 = '<foreignObject x="0" y="0" width="' + t4.chart.width + '" height="' + t4.chart.height + '"><body xmlns="http://www.w3.org/1999/xhtml">' + i3.replace(/(<(?:img|br).*?(?=\>))>/g, "$1 />") + "</body></foreignObject>", e3 = e3.replace("</svg>", i3 + "</svg>")), e3 = e3.replace(/zIndex="[^"]+"/g, "").replace(/symbolName="[^"]+"/g, "").replace(/jQuery\d+="[^"]+"/g, "").replace(/url\(("|&quot;)(.*?)("|&quot;)\;?\)/g, "url($2)").replace(/url\([^#]+#/g, "url(#").replace(/<svg /, '<svg xmlns:xlink="http://www.w3.org/1999/xlink" ').replace(/ (NS\d+\:)?href=/g, " xlink:href=").replace(/\n+/g, " ").replace(/(fill|stroke)="rgba\(([ \d]+,[ \d]+,[ \d]+),([ \d\.]+)\)"/g, '$1="rgb($2)" $1-opacity="$3"').replace(/&nbsp;/g, "\xA0").replace(/&shy;/g, "\xAD");
16023          }
16024          t3.compose = function(e3, t4) {
16025            r.compose(t4), s.compose(e3);
16026            let n3 = e3.prototype;
16027            n3.exportChart || (n3.afterPrint = N, n3.exportChart = I, n3.inlineStyles = $, n3.print = A, n3.sanitizeSVG = U, n3.getChartHTML = W, n3.getSVG = L, n3.getSVGForExport = q, n3.getFilename = R, n3.moveContainers = z, n3.beforePrint = H, n3.contextMenu = G, n3.addButton = k, n3.destroyExport = D2, n3.renderExporting = K, n3.callbacks.push(j), f(e3, "init", V), l.isSafari && g.matchMedia("print").addListener(function(e4) {
16028              i2 && (e4.matches ? i2.beforePrint() : i2.afterPrint());
16029            }), p.exporting = C(o.exporting, p.exporting), p.lang = C(o.lang, p.lang), p.navigation = C(o.navigation, p.navigation));
16030          };
16031        }(u11 || (u11 = {})), u11;
16032      }), n(t, "masters/modules/exporting.src.js", [t["Core/Globals.js"], t["Extensions/Exporting/Exporting.js"], t["Core/HttpUtilities.js"]], function(e2, t2, n2) {
16033        return e2.HttpUtilities = e2.HttpUtilities || n2, e2.ajax = e2.HttpUtilities.ajax, e2.getJSON = e2.HttpUtilities.getJSON, e2.post = e2.HttpUtilities.post, t2.compose(e2.Chart, e2.Renderer), e2;
16034      });
16035    });
16036  }
16037});
16038
vendor: 641,597 bytes, lines 16039-28155
16039// node_modules/highcharts/highstock.js
16040var require_highstock = __commonJS({
16041  "node_modules/highcharts/highstock.js"(exports, module) {
16042    "use strict";
16043    !/**
16044    * Highstock JS v11.4.8 (2024-08-29)
16045    *
16046    * (c) 2009-2024 Torstein Honsi
16047    *
16048    * License: www.highcharts.com/license
16049    */
16050    function(t, e) {
16051      "object" == typeof module && module.exports ? (e.default = e, module.exports = t && t.document ? e(t) : e) : "function" == typeof define && define.amd ? define("highcharts/highstock", function() {
16052        return e(t);
16053      }) : (t.Highcharts && t.Highcharts.error(16, true), t.Highcharts = e(t));
16054    }("undefined" != typeof window ? window : exports, function(t) {
16055      "use strict";
16056      var e = {};
16057      function i(e2, i2, s, o) {
16058        !e2.hasOwnProperty(i2) && (e2[i2] = o.apply(null, s), t && "function" == typeof CustomEvent && t.dispatchEvent(new CustomEvent("HighchartsModuleLoaded", {
16059          detail: {
16060            path: i2,
16061            module: e2[i2]
16062          }
16063        })));
16064      }
16065      return i(e, "Core/Globals.js", [], function() {
16066        var e2, i2;
16067        return (i2 = e2 || (e2 = {})).SVG_NS = "http://www.w3.org/2000/svg", i2.product = "Highcharts", i2.version = "11.4.8", i2.win = void 0 !== t ? t : {}, i2.doc = i2.win.document, i2.svg = i2.doc && i2.doc.createElementNS && !!i2.doc.createElementNS(i2.SVG_NS, "svg").createSVGRect, i2.userAgent = i2.win.navigator && i2.win.navigator.userAgent || "", i2.isChrome = i2.win.chrome, i2.isFirefox = -1 !== i2.userAgent.indexOf("Firefox"), i2.isMS = /(edge|msie|trident)/i.test(i2.userAgent) && !i2.win.opera, i2.isSafari = !i2.isChrome && -1 !== i2.userAgent.indexOf("Safari"), i2.isTouchDevice = /(Mobile|Android|Windows Phone)/.test(i2.userAgent), i2.isWebKit = -1 !== i2.userAgent.indexOf("AppleWebKit"), i2.deg2rad = 2 * Math.PI / 360, i2.hasBidiBug = i2.isFirefox && 4 > parseInt(i2.userAgent.split("Firefox/")[1], 10), i2.marginNames = ["plotTop", "marginRight", "marginBottom", "plotLeft"], i2.noop = function() {
16068        }, i2.supportsPassiveEvents = function() {
16069          let t2 = false;
16070          if (!i2.isMS) {
16071            let e3 = Object.defineProperty({}, "passive", {
16072              get: function() {
16073                t2 = true;
16074              }
16075            });
16076            i2.win.addEventListener && i2.win.removeEventListener && (i2.win.addEventListener("testPassive", i2.noop, e3), i2.win.removeEventListener("testPassive", i2.noop, e3));
16077          }
16078          return t2;
16079        }(), i2.charts = [], i2.composed = [], i2.dateFormats = {}, i2.seriesTypes = {}, i2.symbolSizes = {}, i2.chartCount = 0, e2;
16080      }), i(e, "Core/Utilities.js", [e["Core/Globals.js"]], function(t2) {
16081        let e2;
16082        let {
16083          charts: i2,
16084          doc: s,
16085          win: o
16086        } = t2;
16087        function r(e3, i3, s2, a2) {
16088          let n2 = i3 ? "Highcharts error" : "Highcharts warning";
16089          32 === e3 && (e3 = `${n2}: Deprecated member`);
16090          let l2 = p(e3), h2 = l2 ? `${n2} #${e3}: www.highcharts.com/errors/${e3}/` : e3.toString();
16091          if (void 0 !== a2) {
16092            let t3 = "";
16093            l2 && (h2 += "?"), k(a2, function(e4, i4) {
16094              t3 += `
16095 - ${i4}: ${e4}`, l2 && (h2 += encodeURI(i4) + "=" + encodeURI(e4));
16096            }), h2 += t3;
16097          }
16098          C(t2, "displayError", {
16099            chart: s2,
16100            code: e3,
16101            message: h2,
16102            params: a2
16103          }, function() {
16104            if (i3) throw Error(h2);
16105            o.console && -1 === r.messages.indexOf(h2) && console.warn(h2);
16106          }), r.messages.push(h2);
16107        }
16108        function a(t3, e3) {
16109          return parseInt(t3, e3 || 10);
16110        }
16111        function n(t3) {
16112          return "string" == typeof t3;
16113        }
16114        function l(t3) {
16115          let e3 = Object.prototype.toString.call(t3);
16116          return "[object Array]" === e3 || "[object Array Iterator]" === e3;
16117        }
16118        function h(t3, e3) {
16119          return !!t3 && "object" == typeof t3 && (!e3 || !l(t3));
16120        }
16121        function d(t3) {
16122          return h(t3) && "number" == typeof t3.nodeType;
16123        }
16124        function c(t3) {
16125          let e3 = t3 && t3.constructor;
16126          return !!(h(t3, true) && !d(t3) && e3 && e3.name && "Object" !== e3.name);
16127        }
16128        function p(t3) {
16129          return "number" == typeof t3 && !isNaN(t3) && t3 < 1 / 0 && t3 > -1 / 0;
16130        }
16131        function u11(t3) {
16132          return null != t3;
16133        }
16134        function g(t3, e3, i3) {
16135          let s2;
16136          let o2 = n(e3) && !u11(i3), r2 = (e4, i4) => {
16137            u11(e4) ? t3.setAttribute(i4, e4) : o2 ? (s2 = t3.getAttribute(i4)) || "class" !== i4 || (s2 = t3.getAttribute(i4 + "Name")) : t3.removeAttribute(i4);
16138          };
16139          return n(e3) ? r2(i3, e3) : k(e3, r2), s2;
16140        }
16141        function f(t3) {
16142          return l(t3) ? t3 : [t3];
16143        }
16144        function m(t3, e3) {
16145          let i3;
16146          for (i3 in t3 || (t3 = {}), e3) t3[i3] = e3[i3];
16147          return t3;
16148        }
16149        function x() {
16150          let t3 = arguments, e3 = t3.length;
16151          for (let i3 = 0; i3 < e3; i3++) {
16152            let e4 = t3[i3];
16153            if (null != e4) return e4;
16154          }
16155        }
16156        function y(t3, e3) {
16157          m(t3.style, e3);
16158        }
16159        function b(t3) {
16160          return Math.pow(10, Math.floor(Math.log(t3) / Math.LN10));
16161        }
16162        function v(t3, e3) {
16163          return t3 > 1e14 ? t3 : parseFloat(t3.toPrecision(e3 || 14));
16164        }
16165        (r || (r = {})).messages = [], Math.easeInOutSine = function(t3) {
16166          return -0.5 * (Math.cos(Math.PI * t3) - 1);
16167        };
16168        let S2 = Array.prototype.find ? function(t3, e3) {
16169          return t3.find(e3);
16170        } : function(t3, e3) {
16171          let i3;
16172          let s2 = t3.length;
16173          for (i3 = 0; i3 < s2; i3++) if (e3(t3[i3], i3)) return t3[i3];
16174        };
16175        function k(t3, e3, i3) {
16176          for (let s2 in t3) Object.hasOwnProperty.call(t3, s2) && e3.call(i3 || t3[s2], t3[s2], s2, t3);
16177        }
16178        function M(t3, e3, i3) {
16179          function s2(e4, i4) {
16180            let s3 = t3.removeEventListener;
16181            s3 && s3.call(t3, e4, i4, false);
16182          }
16183          function o2(i4) {
16184            let o3, r3;
16185            t3.nodeName && (e3 ? (o3 = {})[e3] = true : o3 = i4, k(o3, function(t4, e4) {
16186              if (i4[e4]) for (r3 = i4[e4].length; r3--; ) s2(e4, i4[e4][r3].fn);
16187            }));
16188          }
16189          let r2 = "function" == typeof t3 && t3.prototype || t3;
16190          if (Object.hasOwnProperty.call(r2, "hcEvents")) {
16191            let t4 = r2.hcEvents;
16192            if (e3) {
16193              let r3 = t4[e3] || [];
16194              i3 ? (t4[e3] = r3.filter(function(t5) {
16195                return i3 !== t5.fn;
16196              }), s2(e3, i3)) : (o2(t4), t4[e3] = []);
16197            } else o2(t4), delete r2.hcEvents;
16198          }
16199        }
16200        function C(e3, i3, o2, r2) {
16201          if (o2 = o2 || {}, s.createEvent && (e3.dispatchEvent || e3.fireEvent && e3 !== t2)) {
16202            let t3 = s.createEvent("Events");
16203            t3.initEvent(i3, true, true), o2 = m(t3, o2), e3.dispatchEvent ? e3.dispatchEvent(o2) : e3.fireEvent(i3, o2);
16204          } else if (e3.hcEvents) {
16205            o2.target || m(o2, {
16206              preventDefault: function() {
16207                o2.defaultPrevented = true;
16208              },
16209              target: e3,
16210              type: i3
16211            });
16212            let t3 = [], s2 = e3, r3 = false;
16213            for (; s2.hcEvents; ) Object.hasOwnProperty.call(s2, "hcEvents") && s2.hcEvents[i3] && (t3.length && (r3 = true), t3.unshift.apply(t3, s2.hcEvents[i3])), s2 = Object.getPrototypeOf(s2);
16214            r3 && t3.sort((t4, e4) => t4.order - e4.order), t3.forEach((t4) => {
16215              false === t4.fn.call(e3, o2) && o2.preventDefault();
16216            });
16217          }
16218          r2 && !o2.defaultPrevented && r2.call(e3, o2);
16219        }
16220        k({
16221          map: "map",
16222          each: "forEach",
16223          grep: "filter",
16224          reduce: "reduce",
16225          some: "some"
16226        }, function(e3, i3) {
16227          t2[i3] = function(t3) {
16228            return r(32, false, void 0, {
16229              [`Highcharts.${i3}`]: `use Array.${e3}`
16230            }), Array.prototype[e3].apply(t3, [].slice.call(arguments, 1));
16231          };
16232        });
16233        let A = function() {
16234          let t3 = Math.random().toString(36).substring(2, 9) + "-", i3 = 0;
16235          return function() {
16236            return "highcharts-" + (e2 ? "" : t3) + i3++;
16237          };
16238        }();
16239        return o.jQuery && (o.jQuery.fn.highcharts = function() {
16240          let e3 = [].slice.call(arguments);
16241          if (this[0]) return e3[0] ? (new t2[n(e3[0]) ? e3.shift() : "Chart"](this[0], e3[0], e3[1]), this) : i2[g(this[0], "data-highcharts-chart")];
16242        }), {
16243          addEvent: function(e3, i3, s2, o2 = {}) {
16244            let r2 = "function" == typeof e3 && e3.prototype || e3;
16245            Object.hasOwnProperty.call(r2, "hcEvents") || (r2.hcEvents = {});
16246            let a2 = r2.hcEvents;
16247            t2.Point && e3 instanceof t2.Point && e3.series && e3.series.chart && (e3.series.chart.runTrackerClick = true);
16248            let n2 = e3.addEventListener;
16249            n2 && n2.call(e3, i3, s2, !!t2.supportsPassiveEvents && {
16250              passive: void 0 === o2.passive ? -1 !== i3.indexOf("touch") : o2.passive,
16251              capture: false
16252            }), a2[i3] || (a2[i3] = []);
16253            let l2 = {
16254              fn: s2,
16255              order: "number" == typeof o2.order ? o2.order : 1 / 0
16256            };
16257            return a2[i3].push(l2), a2[i3].sort((t3, e4) => t3.order - e4.order), function() {
16258              M(e3, i3, s2);
16259            };
16260          },
16261          arrayMax: function(t3) {
16262            let e3 = t3.length, i3 = t3[0];
16263            for (; e3--; ) t3[e3] > i3 && (i3 = t3[e3]);
16264            return i3;
16265          },
16266          arrayMin: function(t3) {
16267            let e3 = t3.length, i3 = t3[0];
16268            for (; e3--; ) t3[e3] < i3 && (i3 = t3[e3]);
16269            return i3;
16270          },
16271          attr: g,
16272          clamp: function(t3, e3, i3) {
16273            return t3 > e3 ? t3 < i3 ? t3 : i3 : e3;
16274          },
16275          clearTimeout: function(t3) {
16276            u11(t3) && clearTimeout(t3);
16277          },
16278          correctFloat: v,
16279          createElement: function(t3, e3, i3, o2, r2) {
16280            let a2 = s.createElement(t3);
16281            return e3 && m(a2, e3), r2 && y(a2, {
16282              padding: "0",
16283              border: "none",
16284              margin: "0"
16285            }), i3 && y(a2, i3), o2 && o2.appendChild(a2), a2;
16286          },
16287          crisp: (t3, e3 = 0, i3) => {
16288            let s2 = e3 % 2 / 2, o2 = i3 ? -1 : 1;
16289            return (Math.round(t3 * o2 - s2) + s2) * o2;
16290          },
16291          css: y,
16292          defined: u11,
16293          destroyObjectProperties: function(t3, e3, i3) {
16294            k(t3, function(s2, o2) {
16295              s2 !== e3 && s2?.destroy && s2.destroy(), (s2?.destroy || !i3) && delete t3[o2];
16296            });
16297          },
16298          diffObjects: function(t3, e3, i3, s2) {
16299            let o2 = {};
16300            return function t4(e4, o3, r2, a2) {
16301              let n2 = i3 ? o3 : e4;
16302              k(e4, function(i4, d2) {
16303                if (!a2 && s2 && s2.indexOf(d2) > -1 && o3[d2]) {
16304                  i4 = f(i4), r2[d2] = [];
16305                  for (let e5 = 0; e5 < Math.max(i4.length, o3[d2].length); e5++) o3[d2][e5] && (void 0 === i4[e5] ? r2[d2][e5] = o3[d2][e5] : (r2[d2][e5] = {}, t4(i4[e5], o3[d2][e5], r2[d2][e5], a2 + 1)));
16306                } else h(i4, true) && !i4.nodeType ? (r2[d2] = l(i4) ? [] : {}, t4(i4, o3[d2] || {}, r2[d2], a2 + 1), 0 !== Object.keys(r2[d2]).length || "colorAxis" === d2 && 0 === a2 || delete r2[d2]) : (e4[d2] !== o3[d2] || d2 in e4 && !(d2 in o3)) && "__proto__" !== d2 && "constructor" !== d2 && (r2[d2] = n2[d2]);
16307              });
16308            }(t3, e3, o2, 0), o2;
16309          },
16310          discardElement: function(t3) {
16311            t3 && t3.parentElement && t3.parentElement.removeChild(t3);
16312          },
16313          erase: function(t3, e3) {
16314            let i3 = t3.length;
16315            for (; i3--; ) if (t3[i3] === e3) {
16316              t3.splice(i3, 1);
16317              break;
16318            }
16319          },
16320          error: r,
16321          extend: m,
16322          extendClass: function(t3, e3) {
16323            let i3 = function() {
16324            };
16325            return i3.prototype = new t3(), m(i3.prototype, e3), i3;
16326          },
16327          find: S2,
16328          fireEvent: C,
16329          getClosestDistance: function(t3, e3) {
16330            let i3, s2, o2, r2;
16331            let a2 = !e3;
16332            return t3.forEach((t4) => {
16333              if (t4.length > 1) for (r2 = s2 = t4.length - 1; r2 > 0; r2--) (o2 = t4[r2] - t4[r2 - 1]) < 0 && !a2 ? (e3?.(), e3 = void 0) : o2 && (void 0 === i3 || o2 < i3) && (i3 = o2);
16334            }), i3;
16335          },
16336          getMagnitude: b,
16337          getNestedProperty: function(t3, e3) {
16338            let i3 = t3.split(".");
16339            for (; i3.length && u11(e3); ) {
16340              let t4 = i3.shift();
16341              if (void 0 === t4 || "__proto__" === t4) return;
16342              if ("this" === t4) {
16343                let t5;
16344                return h(e3) && (t5 = e3["@this"]), t5 ?? e3;
16345              }
16346              let s2 = e3[t4];
16347              if (!u11(s2) || "function" == typeof s2 || "number" == typeof s2.nodeType || s2 === o) return;
16348              e3 = s2;
16349            }
16350            return e3;
16351          },
16352          getStyle: function t3(e3, i3, s2) {
16353            let r2;
16354            if ("width" === i3) {
16355              let i4 = Math.min(e3.offsetWidth, e3.scrollWidth), s3 = e3.getBoundingClientRect && e3.getBoundingClientRect().width;
16356              return s3 < i4 && s3 >= i4 - 1 && (i4 = Math.floor(s3)), Math.max(0, i4 - (t3(e3, "padding-left", true) || 0) - (t3(e3, "padding-right", true) || 0));
16357            }
16358            if ("height" === i3) return Math.max(0, Math.min(e3.offsetHeight, e3.scrollHeight) - (t3(e3, "padding-top", true) || 0) - (t3(e3, "padding-bottom", true) || 0));
16359            let n2 = o.getComputedStyle(e3, void 0);
16360            return n2 && (r2 = n2.getPropertyValue(i3), x(s2, "opacity" !== i3) && (r2 = a(r2))), r2;
16361          },
16362          inArray: function(t3, e3, i3) {
16363            return r(32, false, void 0, {
16364              "Highcharts.inArray": "use Array.indexOf"
16365            }), e3.indexOf(t3, i3);
16366          },
16367          insertItem: function(t3, e3) {
16368            let i3;
16369            let s2 = t3.options.index, o2 = e3.length;
16370            for (i3 = t3.options.isInternal ? o2 : 0; i3 < o2 + 1; i3++) if (!e3[i3] || p(s2) && s2 < x(e3[i3].options.index, e3[i3]._i) || e3[i3].options.isInternal) {
16371              e3.splice(i3, 0, t3);
16372              break;
16373            }
16374            return i3;
16375          },
16376          isArray: l,
16377          isClass: c,
16378          isDOMElement: d,
16379          isFunction: function(t3) {
16380            return "function" == typeof t3;
16381          },
16382          isNumber: p,
16383          isObject: h,
16384          isString: n,
16385          keys: function(t3) {
16386            return r(32, false, void 0, {
16387              "Highcharts.keys": "use Object.keys"
16388            }), Object.keys(t3);
16389          },
16390          merge: function() {
16391            let t3, e3 = arguments, i3 = {}, s2 = function(t4, e4) {
16392              return "object" != typeof t4 && (t4 = {}), k(e4, function(i4, o3) {
16393                "__proto__" !== o3 && "constructor" !== o3 && (!h(i4, true) || c(i4) || d(i4) ? t4[o3] = e4[o3] : t4[o3] = s2(t4[o3] || {}, i4));
16394              }), t4;
16395            };
16396            true === e3[0] && (i3 = e3[1], e3 = Array.prototype.slice.call(e3, 2));
16397            let o2 = e3.length;
16398            for (t3 = 0; t3 < o2; t3++) i3 = s2(i3, e3[t3]);
16399            return i3;
16400          },
16401          normalizeTickInterval: function(t3, e3, i3, s2, o2) {
16402            let r2, a2 = t3;
16403            i3 = x(i3, b(t3));
16404            let n2 = t3 / i3;
16405            for (!e3 && (e3 = o2 ? [1, 1.2, 1.5, 2, 2.5, 3, 4, 5, 6, 8, 10] : [1, 2, 2.5, 5, 10], false === s2 && (1 === i3 ? e3 = e3.filter(function(t4) {
16406              return t4 % 1 == 0;
16407            }) : i3 <= 0.1 && (e3 = [1 / i3]))), r2 = 0; r2 < e3.length && (a2 = e3[r2], (!o2 || !(a2 * i3 >= t3)) && (o2 || !(n2 <= (e3[r2] + (e3[r2 + 1] || e3[r2])) / 2))); r2++) ;
16408            return v(a2 * i3, -Math.round(Math.log(1e-3) / Math.LN10));
16409          },
16410          objectEach: k,
16411          offset: function(t3) {
16412            let e3 = s.documentElement, i3 = t3.parentElement || t3.parentNode ? t3.getBoundingClientRect() : {
16413              top: 0,
16414              left: 0,
16415              width: 0,
16416              height: 0
16417            };
16418            return {
16419              top: i3.top + (o.pageYOffset || e3.scrollTop) - (e3.clientTop || 0),
16420              left: i3.left + (o.pageXOffset || e3.scrollLeft) - (e3.clientLeft || 0),
16421              width: i3.width,
16422              height: i3.height
16423            };
16424          },
16425          pad: function(t3, e3, i3) {
16426            return Array((e3 || 2) + 1 - String(t3).replace("-", "").length).join(i3 || "0") + t3;
16427          },
16428          pick: x,
16429          pInt: a,
16430          pushUnique: function(t3, e3) {
16431            return 0 > t3.indexOf(e3) && !!t3.push(e3);
16432          },
16433          relativeLength: function(t3, e3, i3) {
16434            return /%$/.test(t3) ? e3 * parseFloat(t3) / 100 + (i3 || 0) : parseFloat(t3);
16435          },
16436          removeEvent: M,
16437          replaceNested: function(t3, ...e3) {
16438            let i3, s2;
16439            do
16440              for (s2 of (i3 = t3, e3)) t3 = t3.replace(s2[0], s2[1]);
16441            while (t3 !== i3);
16442            return t3;
16443          },
16444          splat: f,
16445          stableSort: function(t3, e3) {
16446            let i3, s2;
16447            let o2 = t3.length;
16448            for (s2 = 0; s2 < o2; s2++) t3[s2].safeI = s2;
16449            for (t3.sort(function(t4, s3) {
16450              return 0 === (i3 = e3(t4, s3)) ? t4.safeI - s3.safeI : i3;
16451            }), s2 = 0; s2 < o2; s2++) delete t3[s2].safeI;
16452          },
16453          syncTimeout: function(t3, e3, i3) {
16454            return e3 > 0 ? setTimeout(t3, e3, i3) : (t3.call(0, i3), -1);
16455          },
16456          timeUnits: {
16457            millisecond: 1,
16458            second: 1e3,
16459            minute: 6e4,
16460            hour: 36e5,
16461            day: 864e5,
16462            week: 6048e5,
16463            month: 24192e5,
16464            year: 314496e5
16465          },
16466          uniqueKey: A,
16467          useSerialIds: function(t3) {
16468            return e2 = x(t3, e2);
16469          },
16470          wrap: function(t3, e3, i3) {
16471            let s2 = t3[e3];
16472            t3[e3] = function() {
16473              let t4 = arguments, e4 = this;
16474              return i3.apply(this, [function() {
16475                return s2.apply(e4, arguments.length ? arguments : t4);
16476              }].concat([].slice.call(arguments)));
16477            };
16478          }
16479        };
16480      }), i(e, "Core/Chart/ChartDefaults.js", [], function() {
16481        return {
16482          alignThresholds: false,
16483          panning: {
16484            enabled: false,
16485            type: "x"
16486          },
16487          styledMode: false,
16488          borderRadius: 0,
16489          colorCount: 10,
16490          allowMutatingData: true,
16491          ignoreHiddenSeries: true,
16492          spacing: [10, 10, 15, 10],
16493          resetZoomButton: {
16494            theme: {},
16495            position: {}
16496          },
16497          reflow: true,
16498          type: "line",
16499          zooming: {
16500            singleTouch: false,
16501            resetButton: {
16502              theme: {
16503                zIndex: 6
16504              },
16505              position: {
16506                align: "right",
16507                x: -10,
16508                y: 10
16509              }
16510            }
16511          },
16512          width: null,
16513          height: null,
16514          borderColor: "#334eff",
16515          backgroundColor: "#ffffff",
16516          plotBorderColor: "#cccccc"
16517        };
16518      }), i(e, "Core/Color/Palettes.js", [], function() {
16519        return {
16520          colors: ["#2caffe", "#544fc5", "#00e272", "#fe6a35", "#6b8abc", "#d568fb", "#2ee0ca", "#fa4b42", "#feb56a", "#91e8e1"]
16521        };
16522      }), i(e, "Core/Time.js", [e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2) {
16523        let {
16524          win: i2
16525        } = t2, {
16526          defined: s,
16527          error: o,
16528          extend: r,
16529          isNumber: a,
16530          isObject: n,
16531          merge: l,
16532          objectEach: h,
16533          pad: d,
16534          pick: c,
16535          splat: p,
16536          timeUnits: u11
16537        } = e2, g = t2.isSafari && i2.Intl && i2.Intl.DateTimeFormat.prototype.formatRange, f = t2.isSafari && i2.Intl && !i2.Intl.DateTimeFormat.prototype.formatRange;
16538        class m {
16539          constructor(t3) {
16540            this.options = {}, this.useUTC = false, this.variableTimezone = false, this.Date = i2.Date, this.getTimezoneOffset = this.timezoneOffsetFunction(), this.update(t3);
16541          }
16542          get(t3, e3) {
16543            if (this.variableTimezone || this.timezoneOffset) {
16544              let i3 = e3.getTime(), s2 = i3 - this.getTimezoneOffset(e3);
16545              e3.setTime(s2);
16546              let o2 = e3["getUTC" + t3]();
16547              return e3.setTime(i3), o2;
16548            }
16549            return this.useUTC ? e3["getUTC" + t3]() : e3["get" + t3]();
16550          }
16551          set(t3, e3, i3) {
16552            if (this.variableTimezone || this.timezoneOffset) {
16553              if ("Milliseconds" === t3 || "Seconds" === t3 || "Minutes" === t3 && this.getTimezoneOffset(e3) % 36e5 == 0) return e3["setUTC" + t3](i3);
16554              let s2 = this.getTimezoneOffset(e3), o2 = e3.getTime() - s2;
16555              e3.setTime(o2), e3["setUTC" + t3](i3);
16556              let r2 = this.getTimezoneOffset(e3);
16557              return o2 = e3.getTime() + r2, e3.setTime(o2);
16558            }
16559            return this.useUTC || g && "FullYear" === t3 ? e3["setUTC" + t3](i3) : e3["set" + t3](i3);
16560          }
16561          update(t3 = {}) {
16562            let e3 = c(t3.useUTC, true);
16563            this.options = t3 = l(true, this.options, t3), this.Date = t3.Date || i2.Date || Date, this.useUTC = e3, this.timezoneOffset = e3 && t3.timezoneOffset || void 0, this.getTimezoneOffset = this.timezoneOffsetFunction(), this.variableTimezone = e3 && !!(t3.getTimezoneOffset || t3.timezone);
16564          }
16565          makeTime(t3, e3, i3, s2, o2, r2) {
16566            let a2, n2, l2;
16567            return this.useUTC ? (a2 = this.Date.UTC.apply(0, arguments), n2 = this.getTimezoneOffset(a2), a2 += n2, n2 !== (l2 = this.getTimezoneOffset(a2)) ? a2 += l2 - n2 : n2 - 36e5 !== this.getTimezoneOffset(a2 - 36e5) || f || (a2 -= 36e5)) : a2 = new this.Date(t3, e3, c(i3, 1), c(s2, 0), c(o2, 0), c(r2, 0)).getTime(), a2;
16568          }
16569          timezoneOffsetFunction() {
16570            let t3 = this, e3 = this.options, i3 = e3.getTimezoneOffset;
16571            return this.useUTC ? e3.timezone ? (t4) => {
16572              try {
16573                let i4 = `shortOffset,${e3.timezone || ""}`, [s2, o2, r2, n2, l2 = 0] = (m.formatCache[i4] = m.formatCache[i4] || Intl.DateTimeFormat("en", {
16574                  timeZone: e3.timezone,
16575                  timeZoneName: "shortOffset"
16576                })).format(t4).split(/(GMT|:)/).map(Number), h2 = -(36e5 * (r2 + l2 / 60));
16577                if (a(h2)) return h2;
16578              } catch (t5) {
16579                o(34);
16580              }
16581              return 0;
16582            } : this.useUTC && i3 ? (t4) => 6e4 * i3(t4.valueOf()) : () => 6e4 * (t3.timezoneOffset || 0) : (t4) => 6e4 * new Date(t4.toString()).getTimezoneOffset();
16583          }
16584          dateFormat(e3, i3, o2) {
16585            if (!s(i3) || isNaN(i3)) return t2.defaultOptions.lang && t2.defaultOptions.lang.invalidDate || "";
16586            e3 = c(e3, "%Y-%m-%d %H:%M:%S");
16587            let a2 = this, n2 = new this.Date(i3), l2 = this.get("Hours", n2), p2 = this.get("Day", n2), u12 = this.get("Date", n2), g2 = this.get("Month", n2), f2 = this.get("FullYear", n2), m2 = t2.defaultOptions.lang, x = m2 && m2.weekdays, y = m2 && m2.shortWeekdays;
16588            return h(r({
16589              a: y ? y[p2] : x[p2].substr(0, 3),
16590              A: x[p2],
16591              d: d(u12),
16592              e: d(u12, 2, " "),
16593              w: p2,
16594              b: m2.shortMonths[g2],
16595              B: m2.months[g2],
16596              m: d(g2 + 1),
16597              o: g2 + 1,
16598              y: f2.toString().substr(2, 2),
16599              Y: f2,
16600              H: d(l2),
16601              k: l2,
16602              I: d(l2 % 12 || 12),
16603              l: l2 % 12 || 12,
16604              M: d(this.get("Minutes", n2)),
16605              p: l2 < 12 ? "AM" : "PM",
16606              P: l2 < 12 ? "am" : "pm",
16607              S: d(this.get("Seconds", n2)),
16608              L: d(Math.floor(i3 % 1e3), 3)
16609            }, t2.dateFormats), function(t3, s2) {
16610              for (; -1 !== e3.indexOf("%" + s2); ) e3 = e3.replace("%" + s2, "function" == typeof t3 ? t3.call(a2, i3) : t3);
16611            }), o2 ? e3.substr(0, 1).toUpperCase() + e3.substr(1) : e3;
16612          }
16613          resolveDTLFormat(t3) {
16614            return n(t3, true) ? t3 : {
16615              main: (t3 = p(t3))[0],
16616              from: t3[1],
16617              to: t3[2]
16618            };
16619          }
16620          getTimeTicks(t3, e3, i3, o2) {
16621            let a2, n2, l2, h2;
16622            let d2 = this, p2 = d2.Date, g2 = [], f2 = {}, m2 = new p2(e3), x = t3.unitRange, y = t3.count || 1;
16623            if (o2 = c(o2, 1), s(e3)) {
16624              d2.set("Milliseconds", m2, x >= u11.second ? 0 : y * Math.floor(d2.get("Milliseconds", m2) / y)), x >= u11.second && d2.set("Seconds", m2, x >= u11.minute ? 0 : y * Math.floor(d2.get("Seconds", m2) / y)), x >= u11.minute && d2.set("Minutes", m2, x >= u11.hour ? 0 : y * Math.floor(d2.get("Minutes", m2) / y)), x >= u11.hour && d2.set("Hours", m2, x >= u11.day ? 0 : y * Math.floor(d2.get("Hours", m2) / y)), x >= u11.day && d2.set("Date", m2, x >= u11.month ? 1 : Math.max(1, y * Math.floor(d2.get("Date", m2) / y))), x >= u11.month && (d2.set("Month", m2, x >= u11.year ? 0 : y * Math.floor(d2.get("Month", m2) / y)), n2 = d2.get("FullYear", m2)), x >= u11.year && (n2 -= n2 % y, d2.set("FullYear", m2, n2)), x === u11.week && (h2 = d2.get("Day", m2), d2.set("Date", m2, d2.get("Date", m2) - h2 + o2 + (h2 < o2 ? -7 : 0))), n2 = d2.get("FullYear", m2);
16625              let t4 = d2.get("Month", m2), r2 = d2.get("Date", m2), c2 = d2.get("Hours", m2);
16626              e3 = m2.getTime(), (d2.variableTimezone || !d2.useUTC) && s(i3) && (l2 = i3 - e3 > 4 * u11.month || d2.getTimezoneOffset(e3) !== d2.getTimezoneOffset(i3));
16627              let p3 = m2.getTime();
16628              for (a2 = 1; p3 < i3; ) g2.push(p3), x === u11.year ? p3 = d2.makeTime(n2 + a2 * y, 0) : x === u11.month ? p3 = d2.makeTime(n2, t4 + a2 * y) : l2 && (x === u11.day || x === u11.week) ? p3 = d2.makeTime(n2, t4, r2 + a2 * y * (x === u11.day ? 1 : 7)) : l2 && x === u11.hour && y > 1 ? p3 = d2.makeTime(n2, t4, r2, c2 + a2 * y) : p3 += x * y, a2++;
16629              g2.push(p3), x <= u11.hour && g2.length < 1e4 && g2.forEach(function(t5) {
16630                t5 % 18e5 == 0 && "000000000" === d2.dateFormat("%H%M%S%L", t5) && (f2[t5] = "day");
16631              });
16632            }
16633            return g2.info = r(t3, {
16634              higherRanks: f2,
16635              totalRange: x * y
16636            }), g2;
16637          }
16638          getDateFormat(t3, e3, i3, s2) {
16639            let o2 = this.dateFormat("%m-%d %H:%M:%S.%L", e3), r2 = "01-01 00:00:00.000", a2 = {
16640              millisecond: 15,
16641              second: 12,
16642              minute: 9,
16643              hour: 6,
16644              day: 3
16645            }, n2 = "millisecond", l2 = n2;
16646            for (n2 in u11) {
16647              if (t3 === u11.week && +this.dateFormat("%w", e3) === i3 && o2.substr(6) === r2.substr(6)) {
16648                n2 = "week";
16649                break;
16650              }
16651              if (u11[n2] > t3) {
16652                n2 = l2;
16653                break;
16654              }
16655              if (a2[n2] && o2.substr(a2[n2]) !== r2.substr(a2[n2])) break;
16656              "week" !== n2 && (l2 = n2);
16657            }
16658            return this.resolveDTLFormat(s2[n2]).main;
16659          }
16660        }
16661        return m.formatCache = {}, m;
16662      }), i(e, "Core/Defaults.js", [e["Core/Chart/ChartDefaults.js"], e["Core/Globals.js"], e["Core/Color/Palettes.js"], e["Core/Time.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o) {
16663        let {
16664          isTouchDevice: r
16665        } = e2, {
16666          fireEvent: a,
16667          merge: n
16668        } = o, l = {
16669          colors: i2.colors,
16670          symbols: ["circle", "diamond", "square", "triangle", "triangle-down"],
16671          lang: {
16672            loading: "Loading...",
16673            months: ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"],
16674            shortMonths: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"],
16675            weekdays: ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"],
16676            decimalPoint: ".",
16677            numericSymbols: ["k", "M", "G", "T", "P", "E"],
16678            resetZoom: "Reset zoom",
16679            resetZoomTitle: "Reset zoom level 1:1",
16680            thousandsSep: " "
16681          },
16682          global: {
16683            buttonTheme: {
16684              fill: "#f7f7f7",
16685              padding: 8,
16686              r: 2,
16687              stroke: "#cccccc",
16688              "stroke-width": 1,
16689              style: {
16690                color: "#333333",
16691                cursor: "pointer",
16692                fontSize: "0.8em",
16693                fontWeight: "normal"
16694              },
16695              states: {
16696                hover: {
16697                  fill: "#e6e6e6"
16698                },
16699                select: {
16700                  fill: "#e6e9ff",
16701                  style: {
16702                    color: "#000000",
16703                    fontWeight: "bold"
16704                  }
16705                },
16706                disabled: {
16707                  style: {
16708                    color: "#cccccc"
16709                  }
16710                }
16711              }
16712            }
16713          },
16714          time: {
16715            Date: void 0,
16716            getTimezoneOffset: void 0,
16717            timezone: void 0,
16718            timezoneOffset: 0,
16719            useUTC: true
16720          },
16721          chart: t2,
16722          title: {
16723            style: {
16724              color: "#333333",
16725              fontWeight: "bold"
16726            },
16727            text: "Chart title",
16728            align: "center",
16729            margin: 15,
16730            widthAdjust: -44
16731          },
16732          subtitle: {
16733            style: {
16734              color: "#666666",
16735              fontSize: "0.8em"
16736            },
16737            text: "",
16738            align: "center",
16739            widthAdjust: -44
16740          },
16741          caption: {
16742            margin: 15,
16743            style: {
16744              color: "#666666",
16745              fontSize: "0.8em"
16746            },
16747            text: "",
16748            align: "left",
16749            verticalAlign: "bottom"
16750          },
16751          plotOptions: {},
16752          legend: {
16753            enabled: true,
16754            align: "center",
16755            alignColumns: true,
16756            className: "highcharts-no-tooltip",
16757            events: {},
16758            layout: "horizontal",
16759            itemMarginBottom: 2,
16760            itemMarginTop: 2,
16761            labelFormatter: function() {
16762              return this.name;
16763            },
16764            borderColor: "#999999",
16765            borderRadius: 0,
16766            navigation: {
16767              style: {
16768                fontSize: "0.8em"
16769              },
16770              activeColor: "#0022ff",
16771              inactiveColor: "#cccccc"
16772            },
16773            itemStyle: {
16774              color: "#333333",
16775              cursor: "pointer",
16776              fontSize: "0.8em",
16777              textDecoration: "none",
16778              textOverflow: "ellipsis"
16779            },
16780            itemHoverStyle: {
16781              color: "#000000"
16782            },
16783            itemHiddenStyle: {
16784              color: "#666666",
16785              textDecoration: "line-through"
16786            },
16787            shadow: false,
16788            itemCheckboxStyle: {
16789              position: "absolute",
16790              width: "13px",
16791              height: "13px"
16792            },
16793            squareSymbol: true,
16794            symbolPadding: 5,
16795            verticalAlign: "bottom",
16796            x: 0,
16797            y: 0,
16798            title: {
16799              style: {
16800                fontSize: "0.8em",
16801                fontWeight: "bold"
16802              }
16803            }
16804          },
16805          loading: {
16806            labelStyle: {
16807              fontWeight: "bold",
16808              position: "relative",
16809              top: "45%"
16810            },
16811            style: {
16812              position: "absolute",
16813              backgroundColor: "#ffffff",
16814              opacity: 0.5,
16815              textAlign: "center"
16816            }
16817          },
16818          tooltip: {
16819            enabled: true,
16820            animation: {
16821              duration: 300,
16822              easing: (t3) => Math.sqrt(1 - Math.pow(t3 - 1, 2))
16823            },
16824            borderRadius: 3,
16825            dateTimeLabelFormats: {
16826              millisecond: "%A, %e %b, %H:%M:%S.%L",
16827              second: "%A, %e %b, %H:%M:%S",
16828              minute: "%A, %e %b, %H:%M",
16829              hour: "%A, %e %b, %H:%M",
16830              day: "%A, %e %b %Y",
16831              week: "Week from %A, %e %b %Y",
16832              month: "%B %Y",
16833              year: "%Y"
16834            },
16835            footerFormat: "",
16836            headerShape: "callout",
16837            hideDelay: 500,
16838            padding: 8,
16839            shape: "callout",
16840            shared: false,
16841            snap: r ? 25 : 10,
16842            headerFormat: '<span style="font-size: 0.8em">{point.key}</span><br/>',
16843            pointFormat: '<span style="color:{point.color}">\u25CF</span> {series.name}: <b>{point.y}</b><br/>',
16844            backgroundColor: "#ffffff",
16845            borderWidth: void 0,
16846            shadow: true,
16847            stickOnContact: false,
16848            style: {
16849              color: "#333333",
16850              cursor: "default",
16851              fontSize: "0.8em"
16852            },
16853            useHTML: false
16854          },
16855          credits: {
16856            enabled: true,
16857            href: "https://www.highcharts.com?credits",
16858            position: {
16859              align: "right",
16860              x: -10,
16861              verticalAlign: "bottom",
16862              y: -5
16863            },
16864            style: {
16865              cursor: "pointer",
16866              color: "#999999",
16867              fontSize: "0.6em"
16868            },
16869            text: "Highcharts.com"
16870          }
16871        };
16872        l.chart.styledMode = false;
16873        let h = new s(l.time);
16874        return {
16875          defaultOptions: l,
16876          defaultTime: h,
16877          getOptions: function() {
16878            return l;
16879          },
16880          setOptions: function(t3) {
16881            return a(e2, "setOptions", {
16882              options: t3
16883            }), n(true, l, t3), (t3.time || t3.global) && (e2.time ? e2.time.update(n(l.global, l.time, t3.global, t3.time)) : e2.time = h), l;
16884          }
16885        };
16886      }), i(e, "Core/Color/Color.js", [e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2) {
16887        let {
16888          isNumber: i2,
16889          merge: s,
16890          pInt: o
16891        } = e2;
16892        class r {
16893          static parse(t3) {
16894            return t3 ? new r(t3) : r.None;
16895          }
16896          constructor(e3) {
16897            let i3, s2, o2, a;
16898            this.rgba = [NaN, NaN, NaN, NaN], this.input = e3;
16899            let n = t2.Color;
16900            if (n && n !== r) return new n(e3);
16901            if ("object" == typeof e3 && void 0 !== e3.stops) this.stops = e3.stops.map((t3) => new r(t3[1]));
16902            else if ("string" == typeof e3) {
16903              if (this.input = e3 = r.names[e3.toLowerCase()] || e3, "#" === e3.charAt(0)) {
16904                let t3 = e3.length, i4 = parseInt(e3.substr(1), 16);
16905                7 === t3 ? s2 = [(16711680 & i4) >> 16, (65280 & i4) >> 8, 255 & i4, 1] : 4 === t3 && (s2 = [(3840 & i4) >> 4 | (3840 & i4) >> 8, (240 & i4) >> 4 | 240 & i4, (15 & i4) << 4 | 15 & i4, 1]);
16906              }
16907              if (!s2) for (o2 = r.parsers.length; o2-- && !s2; ) (i3 = (a = r.parsers[o2]).regex.exec(e3)) && (s2 = a.parse(i3));
16908            }
16909            s2 && (this.rgba = s2);
16910          }
16911          get(t3) {
16912            let e3 = this.input, o2 = this.rgba;
16913            if ("object" == typeof e3 && void 0 !== this.stops) {
16914              let i3 = s(e3);
16915              return i3.stops = [].slice.call(i3.stops), this.stops.forEach((e4, s2) => {
16916                i3.stops[s2] = [i3.stops[s2][0], e4.get(t3)];
16917              }), i3;
16918            }
16919            return o2 && i2(o2[0]) ? "rgb" !== t3 && (t3 || 1 !== o2[3]) ? "a" === t3 ? `${o2[3]}` : "rgba(" + o2.join(",") + ")" : "rgb(" + o2[0] + "," + o2[1] + "," + o2[2] + ")" : e3;
16920          }
16921          brighten(t3) {
16922            let e3 = this.rgba;
16923            if (this.stops) this.stops.forEach(function(e4) {
16924              e4.brighten(t3);
16925            });
16926            else if (i2(t3) && 0 !== t3) for (let i3 = 0; i3 < 3; i3++) e3[i3] += o(255 * t3), e3[i3] < 0 && (e3[i3] = 0), e3[i3] > 255 && (e3[i3] = 255);
16927            return this;
16928          }
16929          setOpacity(t3) {
16930            return this.rgba[3] = t3, this;
16931          }
16932          tweenTo(t3, e3) {
16933            let s2 = this.rgba, o2 = t3.rgba;
16934            if (!i2(s2[0]) || !i2(o2[0])) return t3.input || "none";
16935            let r2 = 1 !== o2[3] || 1 !== s2[3];
16936            return (r2 ? "rgba(" : "rgb(") + Math.round(o2[0] + (s2[0] - o2[0]) * (1 - e3)) + "," + Math.round(o2[1] + (s2[1] - o2[1]) * (1 - e3)) + "," + Math.round(o2[2] + (s2[2] - o2[2]) * (1 - e3)) + (r2 ? "," + (o2[3] + (s2[3] - o2[3]) * (1 - e3)) : "") + ")";
16937          }
16938        }
16939        return r.names = {
16940          white: "#ffffff",
16941          black: "#000000"
16942        }, r.parsers = [{
16943          regex: /rgba\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d?(?:\.\d+)?)\s*\)/,
16944          parse: function(t3) {
16945            return [o(t3[1]), o(t3[2]), o(t3[3]), parseFloat(t3[4], 10)];
16946          }
16947        }, {
16948          regex: /rgb\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)/,
16949          parse: function(t3) {
16950            return [o(t3[1]), o(t3[2]), o(t3[3]), 1];
16951          }
16952        }], r.None = new r(""), r;
16953      }), i(e, "Core/Animation/Fx.js", [e["Core/Color/Color.js"], e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
16954        let {
16955          parse: s
16956        } = t2, {
16957          win: o
16958        } = e2, {
16959          isNumber: r,
16960          objectEach: a
16961        } = i2;
16962        class n {
16963          constructor(t3, e3, i3) {
16964            this.pos = NaN, this.options = e3, this.elem = t3, this.prop = i3;
16965          }
16966          dSetter() {
16967            let t3 = this.paths, e3 = t3 && t3[0], i3 = t3 && t3[1], s2 = this.now || 0, o2 = [];
16968            if (1 !== s2 && e3 && i3) {
16969              if (e3.length === i3.length && s2 < 1) for (let t4 = 0; t4 < i3.length; t4++) {
16970                let a2 = e3[t4], n2 = i3[t4], l = [];
16971                for (let t5 = 0; t5 < n2.length; t5++) {
16972                  let e4 = a2[t5], i4 = n2[t5];
16973                  r(e4) && r(i4) && !("A" === n2[0] && (4 === t5 || 5 === t5)) ? l[t5] = e4 + s2 * (i4 - e4) : l[t5] = i4;
16974                }
16975                o2.push(l);
16976              }
16977              else o2 = i3;
16978            } else o2 = this.toD || [];
16979            this.elem.attr("d", o2, void 0, true);
16980          }
16981          update() {
16982            let t3 = this.elem, e3 = this.prop, i3 = this.now, s2 = this.options.step;
16983            this[e3 + "Setter"] ? this[e3 + "Setter"]() : t3.attr ? t3.element && t3.attr(e3, i3, null, true) : t3.style[e3] = i3 + this.unit, s2 && s2.call(t3, i3, this);
16984          }
16985          run(t3, e3, i3) {
16986            let s2 = this, r2 = s2.options, a2 = function(t4) {
16987              return !a2.stopped && s2.step(t4);
16988            }, l = o.requestAnimationFrame || function(t4) {
16989              setTimeout(t4, 13);
16990            }, h = function() {
16991              for (let t4 = 0; t4 < n.timers.length; t4++) n.timers[t4]() || n.timers.splice(t4--, 1);
16992              n.timers.length && l(h);
16993            };
16994            t3 !== e3 || this.elem["forceAnimate:" + this.prop] ? (this.startTime = +/* @__PURE__ */ new Date(), this.start = t3, this.end = e3, this.unit = i3, this.now = this.start, this.pos = 0, a2.elem = this.elem, a2.prop = this.prop, a2() && 1 === n.timers.push(a2) && l(h)) : (delete r2.curAnim[this.prop], r2.complete && 0 === Object.keys(r2.curAnim).length && r2.complete.call(this.elem));
16995          }
16996          step(t3) {
16997            let e3, i3;
16998            let s2 = +/* @__PURE__ */ new Date(), o2 = this.options, r2 = this.elem, n2 = o2.complete, l = o2.duration, h = o2.curAnim;
16999            return r2.attr && !r2.element ? e3 = false : t3 || s2 >= l + this.startTime ? (this.now = this.end, this.pos = 1, this.update(), h[this.prop] = true, i3 = true, a(h, function(t4) {
17000              true !== t4 && (i3 = false);
17001            }), i3 && n2 && n2.call(r2), e3 = false) : (this.pos = o2.easing((s2 - this.startTime) / l), this.now = this.start + (this.end - this.start) * this.pos, this.update(), e3 = true), e3;
17002          }
17003          initPath(t3, e3, i3) {
17004            let s2 = t3.startX, o2 = t3.endX, a2 = i3.slice(), n2 = t3.isArea, l = n2 ? 2 : 1, h = e3 && i3.length > e3.length && i3.hasStackedCliffs, d, c, p, u11, g = e3 && e3.slice();
17005            if (!g || h) return [a2, a2];
17006            function f(t4, e4) {
17007              for (; t4.length < c; ) {
17008                let i4 = t4[0], s3 = e4[c - t4.length];
17009                if (s3 && "M" === i4[0] && ("C" === s3[0] ? t4[0] = ["C", i4[1], i4[2], i4[1], i4[2], i4[1], i4[2]] : t4[0] = ["L", i4[1], i4[2]]), t4.unshift(i4), n2) {
17010                  let e5 = t4.pop();
17011                  t4.push(t4[t4.length - 1], e5);
17012                }
17013              }
17014            }
17015            function m(t4) {
17016              for (; t4.length < c; ) {
17017                let e4 = t4[Math.floor(t4.length / l) - 1].slice();
17018                if ("C" === e4[0] && (e4[1] = e4[5], e4[2] = e4[6]), n2) {
17019                  let i4 = t4[Math.floor(t4.length / l)].slice();
17020                  t4.splice(t4.length / 2, 0, e4, i4);
17021                } else t4.push(e4);
17022              }
17023            }
17024            if (s2 && o2 && o2.length) {
17025              for (p = 0; p < s2.length; p++) {
17026                if (s2[p] === o2[0]) {
17027                  d = p;
17028                  break;
17029                }
17030                if (s2[0] === o2[o2.length - s2.length + p]) {
17031                  d = p, u11 = true;
17032                  break;
17033                }
17034                if (s2[s2.length - 1] === o2[o2.length - s2.length + p]) {
17035                  d = s2.length - p;
17036                  break;
17037                }
17038              }
17039              void 0 === d && (g = []);
17040            }
17041            return g.length && r(d) && (c = a2.length + d * l, u11 ? (f(g, a2), m(a2)) : (f(a2, g), m(g))), [g, a2];
17042          }
17043          fillSetter() {
17044            n.prototype.strokeSetter.apply(this, arguments);
17045          }
17046          strokeSetter() {
17047            this.elem.attr(this.prop, s(this.start).tweenTo(s(this.end), this.pos), void 0, true);
17048          }
17049        }
17050        return n.timers = [], n;
17051      }), i(e, "Core/Animation/AnimationUtilities.js", [e["Core/Animation/Fx.js"], e["Core/Utilities.js"]], function(t2, e2) {
17052        let {
17053          defined: i2,
17054          getStyle: s,
17055          isArray: o,
17056          isNumber: r,
17057          isObject: a,
17058          merge: n,
17059          objectEach: l,
17060          pick: h
17061        } = e2;
17062        function d(t3) {
17063          return a(t3) ? n({
17064            duration: 500,
17065            defer: 0
17066          }, t3) : {
17067            duration: t3 ? 500 : 0,
17068            defer: 0
17069          };
17070        }
17071        function c(e3, i3) {
17072          let s2 = t2.timers.length;
17073          for (; s2--; ) t2.timers[s2].elem !== e3 || i3 && i3 !== t2.timers[s2].prop || (t2.timers[s2].stopped = true);
17074        }
17075        return {
17076          animate: function(e3, i3, h2) {
17077            let d2, p = "", u11, g, f;
17078            a(h2) || (f = arguments, h2 = {
17079              duration: f[2],
17080              easing: f[3],
17081              complete: f[4]
17082            }), r(h2.duration) || (h2.duration = 400), h2.easing = "function" == typeof h2.easing ? h2.easing : Math[h2.easing] || Math.easeInOutSine, h2.curAnim = n(i3), l(i3, function(r2, a2) {
17083              c(e3, a2), g = new t2(e3, h2, a2), u11 = void 0, "d" === a2 && o(i3.d) ? (g.paths = g.initPath(e3, e3.pathArray, i3.d), g.toD = i3.d, d2 = 0, u11 = 1) : e3.attr ? d2 = e3.attr(a2) : (d2 = parseFloat(s(e3, a2)) || 0, "opacity" !== a2 && (p = "px")), u11 || (u11 = r2), "string" == typeof u11 && u11.match("px") && (u11 = u11.replace(/px/g, "")), g.run(d2, u11, p);
17084            });
17085          },
17086          animObject: d,
17087          getDeferredAnimation: function(t3, e3, s2) {
17088            let o2 = d(e3), r2 = s2 ? [s2] : t3.series, n2 = 0, l2 = 0;
17089            return r2.forEach((t4) => {
17090              let s3 = d(t4.options.animation);
17091              n2 = a(e3) && i2(e3.defer) ? o2.defer : Math.max(n2, s3.duration + s3.defer), l2 = Math.min(o2.duration, s3.duration);
17092            }), t3.renderer.forExport && (n2 = 0), {
17093              defer: Math.max(0, n2 - l2),
17094              duration: Math.min(n2, l2)
17095            };
17096          },
17097          setAnimation: function(t3, e3) {
17098            e3.renderer.globalAnimation = h(t3, e3.options.chart.animation, true);
17099          },
17100          stop: c
17101        };
17102      }), i(e, "Core/Renderer/HTML/AST.js", [e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2) {
17103        let {
17104          SVG_NS: i2,
17105          win: s
17106        } = t2, {
17107          attr: o,
17108          createElement: r,
17109          css: a,
17110          error: n,
17111          isFunction: l,
17112          isString: h,
17113          objectEach: d,
17114          splat: c
17115        } = e2, {
17116          trustedTypes: p
17117        } = s, u11 = p && l(p.createPolicy) && p.createPolicy("highcharts", {
17118          createHTML: (t3) => t3
17119        }), g = u11 ? u11.createHTML("") : "", f = function() {
17120          try {
17121            return !!new DOMParser().parseFromString(g, "text/html");
17122          } catch (t3) {
17123            return false;
17124          }
17125        }();
17126        class m {
17127          static filterUserAttributes(t3) {
17128            return d(t3, (e3, i3) => {
17129              let s2 = true;
17130              -1 === m.allowedAttributes.indexOf(i3) && (s2 = false), -1 !== ["background", "dynsrc", "href", "lowsrc", "src"].indexOf(i3) && (s2 = h(e3) && m.allowedReferences.some((t4) => 0 === e3.indexOf(t4))), s2 || (n(33, false, void 0, {
17131                "Invalid attribute in config": `${i3}`
17132              }), delete t3[i3]), h(e3) && t3[i3] && (t3[i3] = e3.replace(/</g, "&lt;"));
17133            }), t3;
17134          }
17135          static parseStyle(t3) {
17136            return t3.split(";").reduce((t4, e3) => {
17137              let i3 = e3.split(":").map((t5) => t5.trim()), s2 = i3.shift();
17138              return s2 && i3.length && (t4[s2.replace(/-([a-z])/g, (t5) => t5[1].toUpperCase())] = i3.join(":")), t4;
17139            }, {});
17140          }
17141          static setElementHTML(t3, e3) {
17142            t3.innerHTML = m.emptyHTML, e3 && new m(e3).addToDOM(t3);
17143          }
17144          constructor(t3) {
17145            this.nodes = "string" == typeof t3 ? this.parseMarkup(t3) : t3;
17146          }
17147          addToDOM(e3) {
17148            return function e4(s2, r2) {
17149              let l2;
17150              return c(s2).forEach(function(s3) {
17151                let h2;
17152                let c2 = s3.tagName, p2 = s3.textContent ? t2.doc.createTextNode(s3.textContent) : void 0, u12 = m.bypassHTMLFiltering;
17153                if (c2) {
17154                  if ("#text" === c2) h2 = p2;
17155                  else if (-1 !== m.allowedTags.indexOf(c2) || u12) {
17156                    let n2 = "svg" === c2 ? i2 : r2.namespaceURI || i2, l3 = t2.doc.createElementNS(n2, c2), g2 = s3.attributes || {};
17157                    d(s3, function(t3, e5) {
17158                      "tagName" !== e5 && "attributes" !== e5 && "children" !== e5 && "style" !== e5 && "textContent" !== e5 && (g2[e5] = t3);
17159                    }), o(l3, u12 ? g2 : m.filterUserAttributes(g2)), s3.style && a(l3, s3.style), p2 && l3.appendChild(p2), e4(s3.children || [], l3), h2 = l3;
17160                  } else n(33, false, void 0, {
17161                    "Invalid tagName in config": c2
17162                  });
17163                }
17164                h2 && r2.appendChild(h2), l2 = h2;
17165              }), l2;
17166            }(this.nodes, e3);
17167          }
17168          parseMarkup(t3) {
17169            let e3;
17170            let i3 = [];
17171            if (t3 = t3.trim().replace(/ style=(["'])/g, " data-style=$1"), f) e3 = new DOMParser().parseFromString(u11 ? u11.createHTML(t3) : t3, "text/html");
17172            else {
17173              let i4 = r("div");
17174              i4.innerHTML = t3, e3 = {
17175                body: i4
17176              };
17177            }
17178            let s2 = (t4, e4) => {
17179              let i4 = t4.nodeName.toLowerCase(), o2 = {
17180                tagName: i4
17181              };
17182              "#text" === i4 && (o2.textContent = t4.textContent || "");
17183              let r2 = t4.attributes;
17184              if (r2) {
17185                let t5 = {};
17186                [].forEach.call(r2, (e5) => {
17187                  "data-style" === e5.name ? o2.style = m.parseStyle(e5.value) : t5[e5.name] = e5.value;
17188                }), o2.attributes = t5;
17189              }
17190              if (t4.childNodes.length) {
17191                let e5 = [];
17192                [].forEach.call(t4.childNodes, (t5) => {
17193                  s2(t5, e5);
17194                }), e5.length && (o2.children = e5);
17195              }
17196              e4.push(o2);
17197            };
17198            return [].forEach.call(e3.body.childNodes, (t4) => s2(t4, i3)), i3;
17199          }
17200        }
17201        return m.allowedAttributes = ["alt", "aria-controls", "aria-describedby", "aria-expanded", "aria-haspopup", "aria-hidden", "aria-label", "aria-labelledby", "aria-live", "aria-pressed", "aria-readonly", "aria-roledescription", "aria-selected", "class", "clip-path", "color", "colspan", "cx", "cy", "d", "dx", "dy", "disabled", "fill", "filterUnits", "flood-color", "flood-opacity", "height", "href", "id", "in", "in2", "markerHeight", "markerWidth", "offset", "opacity", "operator", "orient", "padding", "paddingLeft", "paddingRight", "patternUnits", "r", "radius", "refX", "refY", "role", "scope", "slope", "src", "startOffset", "stdDeviation", "stroke", "stroke-linecap", "stroke-width", "style", "tableValues", "result", "rowspan", "summary", "target", "tabindex", "text-align", "text-anchor", "textAnchor", "textLength", "title", "type", "valign", "width", "x", "x1", "x2", "xlink:href", "y", "y1", "y2", "zIndex"], m.allowedReferences = ["https://", "http://", "mailto:", "/", "../", "./", "#"], m.allowedTags = ["a", "abbr", "b", "br", "button", "caption", "circle", "clipPath", "code", "dd", "defs", "div", "dl", "dt", "em", "feComponentTransfer", "feComposite", "feDropShadow", "feFlood", "feFuncA", "feFuncB", "feFuncG", "feFuncR", "feGaussianBlur", "feMorphology", "feOffset", "feMerge", "feMergeNode", "filter", "h1", "h2", "h3", "h4", "h5", "h6", "hr", "i", "img", "li", "linearGradient", "marker", "ol", "p", "path", "pattern", "pre", "rect", "small", "span", "stop", "strong", "style", "sub", "sup", "svg", "table", "text", "textPath", "thead", "title", "tbody", "tspan", "td", "th", "tr", "u", "ul", "#text"], m.emptyHTML = g, m.bypassHTMLFiltering = false, m;
17202      }), i(e, "Core/Templating.js", [e["Core/Defaults.js"], e["Core/Utilities.js"]], function(t2, e2) {
17203        let {
17204          defaultOptions: i2,
17205          defaultTime: s
17206        } = t2, {
17207          extend: o,
17208          getNestedProperty: r,
17209          isArray: a,
17210          isNumber: n,
17211          isObject: l,
17212          pick: h,
17213          pInt: d
17214        } = e2, c = {
17215          add: (t3, e3) => t3 + e3,
17216          divide: (t3, e3) => 0 !== e3 ? t3 / e3 : "",
17217          eq: (t3, e3) => t3 == e3,
17218          each: function(t3) {
17219            let e3 = arguments[arguments.length - 1];
17220            return !!a(t3) && t3.map((i3, s2) => p(e3.body, o(l(i3) ? i3 : {
17221              "@this": i3
17222            }, {
17223              "@index": s2,
17224              "@first": 0 === s2,
17225              "@last": s2 === t3.length - 1
17226            }))).join("");
17227          },
17228          ge: (t3, e3) => t3 >= e3,
17229          gt: (t3, e3) => t3 > e3,
17230          if: (t3) => !!t3,
17231          le: (t3, e3) => t3 <= e3,
17232          lt: (t3, e3) => t3 < e3,
17233          multiply: (t3, e3) => t3 * e3,
17234          ne: (t3, e3) => t3 != e3,
17235          subtract: (t3, e3) => t3 - e3,
17236          unless: (t3) => !t3
17237        };
17238        function p(t3 = "", e3, o2) {
17239          let a2 = /\{([\w\:\.\,;\-\/<>%@"'’= #\(\)]+)\}/g, n2 = /\(([\w\:\.\,;\-\/<>%@"'= ]+)\)/g, l2 = [], d2 = /f$/, g = /\.(\d)/, f = i2.lang, m = o2 && o2.time || s, x = o2 && o2.numberFormatter || u11, y = (t4 = "") => {
17240            let i3;
17241            return "true" === t4 || "false" !== t4 && ((i3 = Number(t4)).toString() === t4 ? i3 : r(t4, e3));
17242          }, b, v, S2 = 0, k;
17243          for (; null !== (b = a2.exec(t3)); ) {
17244            let i3 = n2.exec(b[1]);
17245            i3 && (b = i3, k = true), v && v.isBlock || (v = {
17246              ctx: e3,
17247              expression: b[1],
17248              find: b[0],
17249              isBlock: "#" === b[1].charAt(0),
17250              start: b.index,
17251              startInner: b.index + b[0].length,
17252              length: b[0].length
17253            });
17254            let s2 = b[1].split(" ")[0].replace("#", "");
17255            c[s2] && (v.isBlock && s2 === v.fn && S2++, v.fn || (v.fn = s2));
17256            let o3 = "else" === b[1];
17257            if (v.isBlock && v.fn && (b[1] === `/${v.fn}` || o3)) {
17258              if (S2) !o3 && S2--;
17259              else {
17260                let e4 = v.startInner, i4 = t3.substr(e4, b.index - e4);
17261                void 0 === v.body ? (v.body = i4, v.startInner = b.index + b[0].length) : v.elseBody = i4, v.find += i4 + b[0], o3 || (l2.push(v), v = void 0);
17262              }
17263            } else v.isBlock || l2.push(v);
17264            if (i3 && !v?.isBlock) break;
17265          }
17266          return l2.forEach((i3) => {
17267            let s2, r2;
17268            let {
17269              body: a3,
17270              elseBody: n3,
17271              expression: l3,
17272              fn: u12
17273            } = i3;
17274            if (u12) {
17275              let t4 = [i3], h2 = l3.split(" ");
17276              for (r2 = c[u12].length; r2--; ) t4.unshift(y(h2[r2 + 1]));
17277              s2 = c[u12].apply(e3, t4), i3.isBlock && "boolean" == typeof s2 && (s2 = p(s2 ? a3 : n3, e3, o2));
17278            } else {
17279              let t4 = l3.split(":");
17280              if (s2 = y(t4.shift() || ""), t4.length && "number" == typeof s2) {
17281                let e4 = t4.join(":");
17282                if (d2.test(e4)) {
17283                  let t5 = parseInt((e4.match(g) || ["", "-1"])[1], 10);
17284                  null !== s2 && (s2 = x(s2, t5, f.decimalPoint, e4.indexOf(",") > -1 ? f.thousandsSep : ""));
17285                } else s2 = m.dateFormat(e4, s2);
17286              }
17287            }
17288            t3 = t3.replace(i3.find, h(s2, ""));
17289          }), k ? p(t3, e3, o2) : t3;
17290        }
17291        function u11(t3, e3, s2, o2) {
17292          let r2, a2;
17293          t3 = +t3 || 0, e3 = +e3;
17294          let l2 = i2.lang, c2 = (t3.toString().split(".")[1] || "").split("e")[0].length, p2 = t3.toString().split("e"), u12 = e3;
17295          -1 === e3 ? e3 = Math.min(c2, 20) : n(e3) ? e3 && p2[1] && p2[1] < 0 && ((a2 = e3 + +p2[1]) >= 0 ? (p2[0] = (+p2[0]).toExponential(a2).split("e")[0], e3 = a2) : (p2[0] = p2[0].split(".")[0] || 0, t3 = e3 < 20 ? (p2[0] * Math.pow(10, p2[1])).toFixed(e3) : 0, p2[1] = 0)) : e3 = 2;
17296          let g = (Math.abs(p2[1] ? p2[0] : t3) + Math.pow(10, -Math.max(e3, c2) - 1)).toFixed(e3), f = String(d(g)), m = f.length > 3 ? f.length % 3 : 0;
17297          return s2 = h(s2, l2.decimalPoint), o2 = h(o2, l2.thousandsSep), r2 = (t3 < 0 ? "-" : "") + (m ? f.substr(0, m) + o2 : ""), 0 > +p2[1] && !u12 ? r2 = "0" : r2 += f.substr(m).replace(/(\d{3})(?=\d)/g, "$1" + o2), e3 ? r2 += s2 + g.slice(-e3) : 0 == +r2 && (r2 = "0"), p2[1] && 0 != +r2 && (r2 += "e" + p2[1]), r2;
17298        }
17299        return {
17300          dateFormat: function(t3, e3, i3) {
17301            return s.dateFormat(t3, e3, i3);
17302          },
17303          format: p,
17304          helpers: c,
17305          numberFormat: u11
17306        };
17307      }), i(e, "Core/Renderer/RendererRegistry.js", [e["Core/Globals.js"]], function(t2) {
17308        var e2, i2;
17309        let s;
17310        return (i2 = e2 || (e2 = {})).rendererTypes = {}, i2.getRendererType = function(t3 = s) {
17311          return i2.rendererTypes[t3] || i2.rendererTypes[s];
17312        }, i2.registerRendererType = function(e3, o, r) {
17313          i2.rendererTypes[e3] = o, (!s || r) && (s = e3, t2.Renderer = o);
17314        }, e2;
17315      }), i(e, "Core/Renderer/RendererUtilities.js", [e["Core/Utilities.js"]], function(t2) {
17316        var e2;
17317        let {
17318          clamp: i2,
17319          pick: s,
17320          pushUnique: o,
17321          stableSort: r
17322        } = t2;
17323        return (e2 || (e2 = {})).distribute = function t3(e3, a, n) {
17324          let l = e3, h = l.reducedLen || a, d = (t4, e4) => t4.target - e4.target, c = [], p = e3.length, u11 = [], g = c.push, f, m, x, y = true, b, v, S2 = 0, k;
17325          for (f = p; f--; ) S2 += e3[f].size;
17326          if (S2 > h) {
17327            for (r(e3, (t4, e4) => (e4.rank || 0) - (t4.rank || 0)), x = (k = e3[0].rank === e3[e3.length - 1].rank) ? p / 2 : -1, m = k ? x : p - 1; x && S2 > h; ) b = e3[f = Math.floor(m)], o(u11, f) && (S2 -= b.size), m += x, k && m >= e3.length && (x /= 2, m = x);
17328            u11.sort((t4, e4) => e4 - t4).forEach((t4) => g.apply(c, e3.splice(t4, 1)));
17329          }
17330          for (r(e3, d), e3 = e3.map((t4) => ({
17331            size: t4.size,
17332            targets: [t4.target],
17333            align: s(t4.align, 0.5)
17334          })); y; ) {
17335            for (f = e3.length; f--; ) b = e3[f], v = (Math.min.apply(0, b.targets) + Math.max.apply(0, b.targets)) / 2, b.pos = i2(v - b.size * b.align, 0, a - b.size);
17336            for (f = e3.length, y = false; f--; ) f > 0 && e3[f - 1].pos + e3[f - 1].size > e3[f].pos && (e3[f - 1].size += e3[f].size, e3[f - 1].targets = e3[f - 1].targets.concat(e3[f].targets), e3[f - 1].align = 0.5, e3[f - 1].pos + e3[f - 1].size > a && (e3[f - 1].pos = a - e3[f - 1].size), e3.splice(f, 1), y = true);
17337          }
17338          return g.apply(l, c), f = 0, e3.some((e4) => {
17339            let i3 = 0;
17340            return (e4.targets || []).some(() => (l[f].pos = e4.pos + i3, void 0 !== n && Math.abs(l[f].pos - l[f].target) > n) ? (l.slice(0, f + 1).forEach((t4) => delete t4.pos), l.reducedLen = (l.reducedLen || a) - 0.1 * a, l.reducedLen > 0.1 * a && t3(l, a, n), true) : (i3 += l[f].size, f++, false));
17341          }), r(l, d), l;
17342        }, e2;
17343      }), i(e, "Core/Renderer/SVG/SVGElement.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Color/Color.js"], e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
17344        let {
17345          animate: o,
17346          animObject: r,
17347          stop: a
17348        } = t2, {
17349          deg2rad: n,
17350          doc: l,
17351          svg: h,
17352          SVG_NS: d,
17353          win: c
17354        } = i2, {
17355          addEvent: p,
17356          attr: u11,
17357          createElement: g,
17358          crisp: f,
17359          css: m,
17360          defined: x,
17361          erase: y,
17362          extend: b,
17363          fireEvent: v,
17364          isArray: S2,
17365          isFunction: k,
17366          isObject: M,
17367          isString: C,
17368          merge: A,
17369          objectEach: w,
17370          pick: T2,
17371          pInt: P,
17372          pushUnique: O,
17373          replaceNested: L,
17374          syncTimeout: D2,
17375          uniqueKey: E
17376        } = s;
17377        class B {
17378          _defaultGetter(t3) {
17379            let e3 = T2(this[t3 + "Value"], this[t3], this.element ? this.element.getAttribute(t3) : null, 0);
17380            return /^-?[\d\.]+$/.test(e3) && (e3 = parseFloat(e3)), e3;
17381          }
17382          _defaultSetter(t3, e3, i3) {
17383            i3.setAttribute(e3, t3);
17384          }
17385          add(t3) {
17386            let e3;
17387            let i3 = this.renderer, s2 = this.element;
17388            return t3 && (this.parentGroup = t3), void 0 !== this.textStr && "text" === this.element.nodeName && i3.buildText(this), this.added = true, (!t3 || t3.handleZ || this.zIndex) && (e3 = this.zIndexSetter()), e3 || (t3 ? t3.element : i3.box).appendChild(s2), this.onAdd && this.onAdd(), this;
17389          }
17390          addClass(t3, e3) {
17391            let i3 = e3 ? "" : this.attr("class") || "";
17392            return (t3 = (t3 || "").split(/ /g).reduce(function(t4, e4) {
17393              return -1 === i3.indexOf(e4) && t4.push(e4), t4;
17394            }, i3 ? [i3] : []).join(" ")) !== i3 && this.attr("class", t3), this;
17395          }
17396          afterSetters() {
17397            this.doTransform && (this.updateTransform(), this.doTransform = false);
17398          }
17399          align(t3, e3, i3, s2 = true) {
17400            let o2, r2, a2, n2;
17401            let l2 = {}, h2 = this.renderer, d2 = h2.alignedObjects, c2 = !!t3;
17402            t3 ? (this.alignOptions = t3, this.alignByTranslate = e3, this.alignTo = i3) : (t3 = this.alignOptions || {}, e3 = this.alignByTranslate, i3 = this.alignTo);
17403            let p2 = !i3 || C(i3) ? i3 || "renderer" : void 0;
17404            p2 && (c2 && O(d2, this), i3 = void 0);
17405            let u12 = T2(i3, h2[p2], h2), g2 = t3.align, f2 = t3.verticalAlign;
17406            return o2 = (u12.x || 0) + (t3.x || 0), r2 = (u12.y || 0) + (t3.y || 0), "right" === g2 ? a2 = 1 : "center" === g2 && (a2 = 2), a2 && (o2 += ((u12.width || 0) - (t3.width || 0)) / a2), l2[e3 ? "translateX" : "x"] = Math.round(o2), "bottom" === f2 ? n2 = 1 : "middle" === f2 && (n2 = 2), n2 && (r2 += ((u12.height || 0) - (t3.height || 0)) / n2), l2[e3 ? "translateY" : "y"] = Math.round(r2), s2 && (this[this.placed ? "animate" : "attr"](l2), this.placed = true), this.alignAttr = l2, this;
17407          }
17408          alignSetter(t3) {
17409            let e3 = {
17410              left: "start",
17411              center: "middle",
17412              right: "end"
17413            };
17414            e3[t3] && (this.alignValue = t3, this.element.setAttribute("text-anchor", e3[t3]));
17415          }
17416          animate(t3, e3, i3) {
17417            let s2 = r(T2(e3, this.renderer.globalAnimation, true)), a2 = s2.defer;
17418            return l.hidden && (s2.duration = 0), 0 !== s2.duration ? (i3 && (s2.complete = i3), D2(() => {
17419              this.element && o(this, t3, s2);
17420            }, a2)) : (this.attr(t3, void 0, i3 || s2.complete), w(t3, function(t4, e4) {
17421              s2.step && s2.step.call(this, t4, {
17422                prop: e4,
17423                pos: 1,
17424                elem: this
17425              });
17426            }, this)), this;
17427          }
17428          applyTextOutline(t3) {
17429            let e3 = this.element;
17430            -1 !== t3.indexOf("contrast") && (t3 = t3.replace(/contrast/g, this.renderer.getContrast(e3.style.fill)));
17431            let s2 = t3.split(" "), o2 = s2[s2.length - 1], r2 = s2[0];
17432            if (r2 && "none" !== r2 && i2.svg) {
17433              this.fakeTS = true, r2 = r2.replace(/(^[\d\.]+)(.*?)$/g, function(t5, e4, i4) {
17434                return 2 * Number(e4) + i4;
17435              }), this.removeTextOutline();
17436              let t4 = l.createElementNS(d, "tspan");
17437              u11(t4, {
17438                class: "highcharts-text-outline",
17439                fill: o2,
17440                stroke: o2,
17441                "stroke-width": r2,
17442                "stroke-linejoin": "round"
17443              });
17444              let i3 = e3.querySelector("textPath") || e3;
17445              [].forEach.call(i3.childNodes, (e4) => {
17446                let i4 = e4.cloneNode(true);
17447                i4.removeAttribute && ["fill", "stroke", "stroke-width", "stroke"].forEach((t5) => i4.removeAttribute(t5)), t4.appendChild(i4);
17448              });
17449              let s3 = 0;
17450              [].forEach.call(i3.querySelectorAll("text tspan"), (t5) => {
17451                s3 += Number(t5.getAttribute("dy"));
17452              });
17453              let a2 = l.createElementNS(d, "tspan");
17454              a2.textContent = "\u200B", u11(a2, {
17455                x: Number(e3.getAttribute("x")),
17456                dy: -s3
17457              }), t4.appendChild(a2), i3.insertBefore(t4, i3.firstChild);
17458            }
17459          }
17460          attr(t3, e3, i3, s2) {
17461            let {
17462              element: o2
17463            } = this, r2 = B.symbolCustomAttribs, n2, l2, h2 = this, d2;
17464            return "string" == typeof t3 && void 0 !== e3 && (n2 = t3, (t3 = {})[n2] = e3), "string" == typeof t3 ? h2 = (this[t3 + "Getter"] || this._defaultGetter).call(this, t3, o2) : (w(t3, function(e4, i4) {
17465              d2 = false, s2 || a(this, i4), this.symbolName && -1 !== r2.indexOf(i4) && (l2 || (this.symbolAttr(t3), l2 = true), d2 = true), this.rotation && ("x" === i4 || "y" === i4) && (this.doTransform = true), d2 || (this[i4 + "Setter"] || this._defaultSetter).call(this, e4, i4, o2);
17466            }, this), this.afterSetters()), i3 && i3.call(this), h2;
17467          }
17468          clip(t3) {
17469            if (t3 && !t3.clipPath) {
17470              let e3 = E() + "-", i3 = this.renderer.createElement("clipPath").attr({
17471                id: e3
17472              }).add(this.renderer.defs);
17473              b(t3, {
17474                clipPath: i3,
17475                id: e3,
17476                count: 0
17477              }), t3.add(i3);
17478            }
17479            return this.attr("clip-path", t3 ? `url(${this.renderer.url}#${t3.id})` : "none");
17480          }
17481          crisp(t3, e3) {
17482            e3 = Math.round(e3 || t3.strokeWidth || 0);
17483            let i3 = t3.x || this.x || 0, s2 = t3.y || this.y || 0, o2 = (t3.width || this.width || 0) + i3, r2 = (t3.height || this.height || 0) + s2, a2 = f(i3, e3), n2 = f(s2, e3);
17484            return b(t3, {
17485              x: a2,
17486              y: n2,
17487              width: f(o2, e3) - a2,
17488              height: f(r2, e3) - n2
17489            }), x(t3.strokeWidth) && (t3.strokeWidth = e3), t3;
17490          }
17491          complexColor(t3, i3, s2) {
17492            let o2 = this.renderer, r2, a2, n2, l2, h2, d2, c2, p2, u12, g2, f2 = [], m2;
17493            v(this.renderer, "complexColor", {
17494              args: arguments
17495            }, function() {
17496              if (t3.radialGradient ? a2 = "radialGradient" : t3.linearGradient && (a2 = "linearGradient"), a2) {
17497                if (n2 = t3[a2], h2 = o2.gradients, d2 = t3.stops, u12 = s2.radialReference, S2(n2) && (t3[a2] = n2 = {
17498                  x1: n2[0],
17499                  y1: n2[1],
17500                  x2: n2[2],
17501                  y2: n2[3],
17502                  gradientUnits: "userSpaceOnUse"
17503                }), "radialGradient" === a2 && u12 && !x(n2.gradientUnits) && (l2 = n2, n2 = A(n2, o2.getRadialAttr(u12, l2), {
17504                  gradientUnits: "userSpaceOnUse"
17505                })), w(n2, function(t4, e3) {
17506                  "id" !== e3 && f2.push(e3, t4);
17507                }), w(d2, function(t4) {
17508                  f2.push(t4);
17509                }), h2[f2 = f2.join(",")]) g2 = h2[f2].attr("id");
17510                else {
17511                  n2.id = g2 = E();
17512                  let t4 = h2[f2] = o2.createElement(a2).attr(n2).add(o2.defs);
17513                  t4.radAttr = l2, t4.stops = [], d2.forEach(function(i4) {
17514                    0 === i4[1].indexOf("rgba") ? (c2 = (r2 = e2.parse(i4[1])).get("rgb"), p2 = r2.get("a")) : (c2 = i4[1], p2 = 1);
17515                    let s3 = o2.createElement("stop").attr({
17516                      offset: i4[0],
17517                      "stop-color": c2,
17518                      "stop-opacity": p2
17519                    }).add(t4);
17520                    t4.stops.push(s3);
17521                  });
17522                }
17523                m2 = "url(" + o2.url + "#" + g2 + ")", s2.setAttribute(i3, m2), s2.gradient = f2, t3.toString = function() {
17524                  return m2;
17525                };
17526              }
17527            });
17528          }
17529          css(t3) {
17530            let e3 = this.styles, i3 = {}, s2 = this.element, o2, r2 = !e3;
17531            if (e3 && w(t3, function(t4, s3) {
17532              e3 && e3[s3] !== t4 && (i3[s3] = t4, r2 = true);
17533            }), r2) {
17534              e3 && (t3 = b(e3, i3)), null === t3.width || "auto" === t3.width ? delete this.textWidth : "text" === s2.nodeName.toLowerCase() && t3.width && (o2 = this.textWidth = P(t3.width)), b(this.styles, t3), o2 && !h && this.renderer.forExport && delete t3.width;
17535              let r3 = A(t3);
17536              s2.namespaceURI === this.SVG_NS && (["textOutline", "textOverflow", "width"].forEach((t4) => r3 && delete r3[t4]), r3.color && (r3.fill = r3.color)), m(s2, r3);
17537            }
17538            return this.added && ("text" === this.element.nodeName && this.renderer.buildText(this), t3.textOutline && this.applyTextOutline(t3.textOutline)), this;
17539          }
17540          dashstyleSetter(t3) {
17541            let e3, i3 = this["stroke-width"];
17542            if ("inherit" === i3 && (i3 = 1), t3 = t3 && t3.toLowerCase()) {
17543              let s2 = t3.replace("shortdashdotdot", "3,1,1,1,1,1,").replace("shortdashdot", "3,1,1,1").replace("shortdot", "1,1,").replace("shortdash", "3,1,").replace("longdash", "8,3,").replace(/dot/g, "1,3,").replace("dash", "4,3,").replace(/,$/, "").split(",");
17544              for (e3 = s2.length; e3--; ) s2[e3] = "" + P(s2[e3]) * T2(i3, NaN);
17545              t3 = s2.join(",").replace(/NaN/g, "none"), this.element.setAttribute("stroke-dasharray", t3);
17546            }
17547          }
17548          destroy() {
17549            let t3 = this, e3 = t3.element || {}, i3 = t3.renderer, s2 = e3.ownerSVGElement, o2 = "SPAN" === e3.nodeName && t3.parentGroup || void 0, r2, n2;
17550            if (e3.onclick = e3.onmouseout = e3.onmouseover = e3.onmousemove = e3.point = null, a(t3), t3.clipPath && s2) {
17551              let e4 = t3.clipPath;
17552              [].forEach.call(s2.querySelectorAll("[clip-path],[CLIP-PATH]"), function(t4) {
17553                t4.getAttribute("clip-path").indexOf(e4.element.id) > -1 && t4.removeAttribute("clip-path");
17554              }), t3.clipPath = e4.destroy();
17555            }
17556            if (t3.connector = t3.connector?.destroy(), t3.stops) {
17557              for (n2 = 0; n2 < t3.stops.length; n2++) t3.stops[n2].destroy();
17558              t3.stops.length = 0, t3.stops = void 0;
17559            }
17560            for (t3.safeRemoveChild(e3); o2 && o2.div && 0 === o2.div.childNodes.length; ) r2 = o2.parentGroup, t3.safeRemoveChild(o2.div), delete o2.div, o2 = r2;
17561            t3.alignOptions && y(i3.alignedObjects, t3), w(t3, function(e4, i4) {
17562              t3[i4] && t3[i4].parentGroup === t3 && t3[i4].destroy && t3[i4].destroy(), delete t3[i4];
17563            });
17564          }
17565          dSetter(t3, e3, i3) {
17566            S2(t3) && ("string" == typeof t3[0] && (t3 = this.renderer.pathToSegments(t3)), this.pathArray = t3, t3 = t3.reduce((t4, e4, i4) => e4 && e4.join ? (i4 ? t4 + " " : "") + e4.join(" ") : (e4 || "").toString(), "")), /(NaN| {2}|^$)/.test(t3) && (t3 = "M 0 0"), this[e3] !== t3 && (i3.setAttribute(e3, t3), this[e3] = t3);
17567          }
17568          fillSetter(t3, e3, i3) {
17569            "string" == typeof t3 ? i3.setAttribute(e3, t3) : t3 && this.complexColor(t3, e3, i3);
17570          }
17571          hrefSetter(t3, e3, i3) {
17572            i3.setAttributeNS("http://www.w3.org/1999/xlink", e3, t3);
17573          }
17574          getBBox(t3, e3) {
17575            let i3, s2, o2, r2;
17576            let {
17577              alignValue: a2,
17578              element: n2,
17579              renderer: l2,
17580              styles: h2,
17581              textStr: d2
17582            } = this, {
17583              cache: c2,
17584              cacheKeys: p2
17585            } = l2, u12 = n2.namespaceURI === this.SVG_NS, g2 = T2(e3, this.rotation, 0), f2 = l2.styledMode ? n2 && B.prototype.getStyle.call(n2, "font-size") : h2.fontSize;
17586            if (x(d2) && (-1 === (r2 = d2.toString()).indexOf("<") && (r2 = r2.replace(/\d/g, "0")), r2 += ["", l2.rootFontSize, f2, g2, this.textWidth, a2, h2.textOverflow, h2.fontWeight].join(",")), r2 && !t3 && (i3 = c2[r2]), !i3 || i3.polygon) {
17587              if (u12 || l2.forExport) {
17588                try {
17589                  o2 = this.fakeTS && function(t5) {
17590                    let e4 = n2.querySelector(".highcharts-text-outline");
17591                    e4 && m(e4, {
17592                      display: t5
17593                    });
17594                  }, k(o2) && o2("none"), i3 = n2.getBBox ? b({}, n2.getBBox()) : {
17595                    width: n2.offsetWidth,
17596                    height: n2.offsetHeight,
17597                    x: 0,
17598                    y: 0
17599                  }, k(o2) && o2("");
17600                } catch (t5) {
17601                }
17602                (!i3 || i3.width < 0) && (i3 = {
17603                  x: 0,
17604                  y: 0,
17605                  width: 0,
17606                  height: 0
17607                });
17608              } else i3 = this.htmlGetBBox();
17609              s2 = i3.height, u12 && (i3.height = s2 = {
17610                "11px,17": 14,
17611                "13px,20": 16
17612              }[`${f2 || ""},${Math.round(s2)}`] || s2), g2 && (i3 = this.getRotatedBox(i3, g2));
17613              let t4 = {
17614                bBox: i3
17615              };
17616              v(this, "afterGetBBox", t4), i3 = t4.bBox;
17617            }
17618            if (r2 && ("" === d2 || i3.height > 0)) {
17619              for (; p2.length > 250; ) delete c2[p2.shift()];
17620              c2[r2] || p2.push(r2), c2[r2] = i3;
17621            }
17622            return i3;
17623          }
17624          getRotatedBox(t3, e3) {
17625            let {
17626              x: i3,
17627              y: s2,
17628              width: o2,
17629              height: r2
17630            } = t3, {
17631              alignValue: a2,
17632              translateY: l2,
17633              rotationOriginX: h2 = 0,
17634              rotationOriginY: d2 = 0
17635            } = this, c2 = {
17636              right: 1,
17637              center: 0.5
17638            }[a2 || 0] || 0, p2 = Number(this.element.getAttribute("y") || 0) - (l2 ? 0 : s2), u12 = e3 * n, g2 = (e3 - 90) * n, f2 = Math.cos(u12), m2 = Math.sin(u12), x2 = o2 * f2, y2 = o2 * m2, b2 = Math.cos(g2), v2 = Math.sin(g2), [[S3, k2], [M2, C2]] = [h2, d2].map((t4) => [t4 - t4 * f2, t4 * m2]), A2 = i3 + c2 * (o2 - x2) + S3 + C2 + p2 * b2, w2 = A2 + x2, T3 = w2 - r2 * b2, P2 = T3 - x2, O2 = s2 + p2 - c2 * y2 - k2 + M2 + p2 * v2, L2 = O2 + y2, D3 = L2 - r2 * v2, E2 = D3 - y2, B2 = Math.min(A2, w2, T3, P2), j = Math.min(O2, L2, D3, E2), R = Math.max(A2, w2, T3, P2) - B2, I = Math.max(O2, L2, D3, E2) - j;
17639            return {
17640              x: B2,
17641              y: j,
17642              width: R,
17643              height: I,
17644              polygon: [[A2, O2], [w2, L2], [T3, D3], [P2, E2]]
17645            };
17646          }
17647          getStyle(t3) {
17648            return c.getComputedStyle(this.element || this, "").getPropertyValue(t3);
17649          }
17650          hasClass(t3) {
17651            return -1 !== ("" + this.attr("class")).split(" ").indexOf(t3);
17652          }
17653          hide() {
17654            return this.attr({
17655              visibility: "hidden"
17656            });
17657          }
17658          htmlGetBBox() {
17659            return {
17660              height: 0,
17661              width: 0,
17662              x: 0,
17663              y: 0
17664            };
17665          }
17666          constructor(t3, e3) {
17667            this.onEvents = {}, this.opacity = 1, this.SVG_NS = d, this.element = "span" === e3 || "body" === e3 ? g(e3) : l.createElementNS(this.SVG_NS, e3), this.renderer = t3, this.styles = {}, v(this, "afterInit");
17668          }
17669          on(t3, e3) {
17670            let {
17671              onEvents: i3
17672            } = this;
17673            return i3[t3] && i3[t3](), i3[t3] = p(this.element, t3, e3), this;
17674          }
17675          opacitySetter(t3, e3, i3) {
17676            let s2 = Number(Number(t3).toFixed(3));
17677            this.opacity = s2, i3.setAttribute(e3, s2);
17678          }
17679          reAlign() {
17680            this.alignOptions?.width && "left" !== this.alignOptions.align && (this.alignOptions.width = this.getBBox().width, this.placed = false, this.align());
17681          }
17682          removeClass(t3) {
17683            return this.attr("class", ("" + this.attr("class")).replace(C(t3) ? RegExp(`(^| )${t3}( |$)`) : t3, " ").replace(/ +/g, " ").trim());
17684          }
17685          removeTextOutline() {
17686            let t3 = this.element.querySelector("tspan.highcharts-text-outline");
17687            t3 && this.safeRemoveChild(t3);
17688          }
17689          safeRemoveChild(t3) {
17690            let e3 = t3.parentNode;
17691            e3 && e3.removeChild(t3);
17692          }
17693          setRadialReference(t3) {
17694            let e3 = this.element.gradient && this.renderer.gradients[this.element.gradient];
17695            return this.element.radialReference = t3, e3 && e3.radAttr && e3.animate(this.renderer.getRadialAttr(t3, e3.radAttr)), this;
17696          }
17697          shadow(t3) {
17698            let {
17699              renderer: e3
17700            } = this, i3 = A(this.parentGroup?.rotation === 90 ? {
17701              offsetX: -1,
17702              offsetY: -1
17703            } : {}, M(t3) ? t3 : {}), s2 = e3.shadowDefinition(i3);
17704            return this.attr({
17705              filter: t3 ? `url(${e3.url}#${s2})` : "none"
17706            });
17707          }
17708          show(t3 = true) {
17709            return this.attr({
17710              visibility: t3 ? "inherit" : "visible"
17711            });
17712          }
17713          "stroke-widthSetter"(t3, e3, i3) {
17714            this[e3] = t3, i3.setAttribute(e3, t3);
17715          }
17716          strokeWidth() {
17717            if (!this.renderer.styledMode) return this["stroke-width"] || 0;
17718            let t3 = this.getStyle("stroke-width"), e3 = 0, i3;
17719            return /px$/.test(t3) ? e3 = P(t3) : "" !== t3 && (u11(i3 = l.createElementNS(d, "rect"), {
17720              width: t3,
17721              "stroke-width": 0
17722            }), this.element.parentNode.appendChild(i3), e3 = i3.getBBox().width, i3.parentNode.removeChild(i3)), e3;
17723          }
17724          symbolAttr(t3) {
17725            let e3 = this;
17726            B.symbolCustomAttribs.forEach(function(i3) {
17727              e3[i3] = T2(t3[i3], e3[i3]);
17728            }), e3.attr({
17729              d: e3.renderer.symbols[e3.symbolName](e3.x, e3.y, e3.width, e3.height, e3)
17730            });
17731          }
17732          textSetter(t3) {
17733            t3 !== this.textStr && (delete this.textPxLength, this.textStr = t3, this.added && this.renderer.buildText(this), this.reAlign());
17734          }
17735          titleSetter(t3) {
17736            let e3 = this.element, i3 = e3.getElementsByTagName("title")[0] || l.createElementNS(this.SVG_NS, "title");
17737            e3.insertBefore ? e3.insertBefore(i3, e3.firstChild) : e3.appendChild(i3), i3.textContent = L(T2(t3, ""), [/<[^>]*>/g, ""]).replace(/&lt;/g, "<").replace(/&gt;/g, ">");
17738          }
17739          toFront() {
17740            let t3 = this.element;
17741            return t3.parentNode.appendChild(t3), this;
17742          }
17743          translate(t3, e3) {
17744            return this.attr({
17745              translateX: t3,
17746              translateY: e3
17747            });
17748          }
17749          updateTransform(t3 = "transform") {
17750            let {
17751              element: e3,
17752              matrix: i3,
17753              rotation: s2 = 0,
17754              rotationOriginX: o2,
17755              rotationOriginY: r2,
17756              scaleX: a2,
17757              scaleY: n2,
17758              translateX: l2 = 0,
17759              translateY: h2 = 0
17760            } = this, d2 = ["translate(" + l2 + "," + h2 + ")"];
17761            x(i3) && d2.push("matrix(" + i3.join(",") + ")"), s2 && (d2.push("rotate(" + s2 + " " + T2(o2, e3.getAttribute("x"), 0) + " " + T2(r2, e3.getAttribute("y") || 0) + ")"), this.text?.element.tagName === "SPAN" && this.text.attr({
17762              rotation: s2,
17763              rotationOriginX: (o2 || 0) - this.padding,
17764              rotationOriginY: (r2 || 0) - this.padding
17765            })), (x(a2) || x(n2)) && d2.push("scale(" + T2(a2, 1) + " " + T2(n2, 1) + ")"), d2.length && !(this.text || this).textPath && e3.setAttribute(t3, d2.join(" "));
17766          }
17767          visibilitySetter(t3, e3, i3) {
17768            "inherit" === t3 ? i3.removeAttribute(e3) : this[e3] !== t3 && i3.setAttribute(e3, t3), this[e3] = t3;
17769          }
17770          xGetter(t3) {
17771            return "circle" === this.element.nodeName && ("x" === t3 ? t3 = "cx" : "y" === t3 && (t3 = "cy")), this._defaultGetter(t3);
17772          }
17773          zIndexSetter(t3, e3) {
17774            let i3 = this.renderer, s2 = this.parentGroup, o2 = (s2 || i3).element || i3.box, r2 = this.element, a2 = o2 === i3.box, n2, l2, h2, d2 = false, c2, p2 = this.added, u12;
17775            if (x(t3) ? (r2.setAttribute("data-z-index", t3), t3 = +t3, this[e3] === t3 && (p2 = false)) : x(this[e3]) && r2.removeAttribute("data-z-index"), this[e3] = t3, p2) {
17776              for ((t3 = this.zIndex) && s2 && (s2.handleZ = true), u12 = (n2 = o2.childNodes).length - 1; u12 >= 0 && !d2; u12--) c2 = !x(h2 = (l2 = n2[u12]).getAttribute("data-z-index")), l2 !== r2 && (t3 < 0 && c2 && !a2 && !u12 ? (o2.insertBefore(r2, n2[u12]), d2 = true) : (P(h2) <= t3 || c2 && (!x(t3) || t3 >= 0)) && (o2.insertBefore(r2, n2[u12 + 1]), d2 = true));
17777              d2 || (o2.insertBefore(r2, n2[a2 ? 3 : 0]), d2 = true);
17778            }
17779            return d2;
17780          }
17781        }
17782        return B.symbolCustomAttribs = ["anchorX", "anchorY", "clockwise", "end", "height", "innerR", "r", "start", "width", "x", "y"], B.prototype.strokeSetter = B.prototype.fillSetter, B.prototype.yGetter = B.prototype.xGetter, B.prototype.matrixSetter = B.prototype.rotationOriginXSetter = B.prototype.rotationOriginYSetter = B.prototype.rotationSetter = B.prototype.scaleXSetter = B.prototype.scaleYSetter = B.prototype.translateXSetter = B.prototype.translateYSetter = B.prototype.verticalAlignSetter = function(t3, e3) {
17783          this[e3] = t3, this.doTransform = true;
17784        }, B;
17785      }), i(e, "Core/Renderer/SVG/SVGLabel.js", [e["Core/Renderer/SVG/SVGElement.js"], e["Core/Utilities.js"]], function(t2, e2) {
17786        let {
17787          defined: i2,
17788          extend: s,
17789          isNumber: o,
17790          merge: r,
17791          pick: a,
17792          removeEvent: n
17793        } = e2;
17794        class l extends t2 {
17795          constructor(t3, e3, i3, s2, o2, r2, a2, n2, h, d) {
17796            let c;
17797            super(t3, "g"), this.paddingLeftSetter = this.paddingSetter, this.paddingRightSetter = this.paddingSetter, this.doUpdate = false, this.textStr = e3, this.x = i3, this.y = s2, this.anchorX = r2, this.anchorY = a2, this.baseline = h, this.className = d, this.addClass("button" === d ? "highcharts-no-tooltip" : "highcharts-label"), d && this.addClass("highcharts-" + d), this.text = t3.text(void 0, 0, 0, n2).attr({
17798              zIndex: 1
17799            }), "string" == typeof o2 && ((c = /^url\((.*?)\)$/.test(o2)) || this.renderer.symbols[o2]) && (this.symbolKey = o2), this.bBox = l.emptyBBox, this.padding = 3, this.baselineOffset = 0, this.needsBox = t3.styledMode || c, this.deferredAttr = {}, this.alignFactor = 0;
17800          }
17801          alignSetter(t3) {
17802            let e3 = {
17803              left: 0,
17804              center: 0.5,
17805              right: 1
17806            }[t3];
17807            e3 !== this.alignFactor && (this.alignFactor = e3, this.bBox && o(this.xSetting) && this.attr({
17808              x: this.xSetting
17809            }));
17810          }
17811          anchorXSetter(t3, e3) {
17812            this.anchorX = t3, this.boxAttr(e3, Math.round(t3) - this.getCrispAdjust() - this.xSetting);
17813          }
17814          anchorYSetter(t3, e3) {
17815            this.anchorY = t3, this.boxAttr(e3, t3 - this.ySetting);
17816          }
17817          boxAttr(t3, e3) {
17818            this.box ? this.box.attr(t3, e3) : this.deferredAttr[t3] = e3;
17819          }
17820          css(e3) {
17821            if (e3) {
17822              let t3 = {};
17823              e3 = r(e3), l.textProps.forEach((i3) => {
17824                void 0 !== e3[i3] && (t3[i3] = e3[i3], delete e3[i3]);
17825              }), this.text.css(t3), "fontSize" in t3 || "fontWeight" in t3 ? this.updateTextPadding() : ("width" in t3 || "textOverflow" in t3) && this.updateBoxSize();
17826            }
17827            return t2.prototype.css.call(this, e3);
17828          }
17829          destroy() {
17830            n(this.element, "mouseenter"), n(this.element, "mouseleave"), this.text && this.text.destroy(), this.box && (this.box = this.box.destroy()), t2.prototype.destroy.call(this);
17831          }
17832          fillSetter(t3, e3) {
17833            t3 && (this.needsBox = true), this.fill = t3, this.boxAttr(e3, t3);
17834          }
17835          getBBox(t3, e3) {
17836            this.textStr && 0 === this.bBox.width && 0 === this.bBox.height && this.updateBoxSize();
17837            let {
17838              padding: i3,
17839              height: s2 = 0,
17840              translateX: o2 = 0,
17841              translateY: r2 = 0,
17842              width: n2 = 0
17843            } = this, l2 = a(this.paddingLeft, i3), h = e3 ?? (this.rotation || 0), d = {
17844              width: n2,
17845              height: s2,
17846              x: o2 + this.bBox.x - l2,
17847              y: r2 + this.bBox.y - i3 + this.baselineOffset
17848            };
17849            return h && (d = this.getRotatedBox(d, h)), d;
17850          }
17851          getCrispAdjust() {
17852            return (this.renderer.styledMode && this.box ? this.box.strokeWidth() : this["stroke-width"] ? parseInt(this["stroke-width"], 10) : 0) % 2 / 2;
17853          }
17854          heightSetter(t3) {
17855            this.heightSetting = t3, this.doUpdate = true;
17856          }
17857          afterSetters() {
17858            super.afterSetters(), this.doUpdate && (this.updateBoxSize(), this.doUpdate = false);
17859          }
17860          onAdd() {
17861            this.text.add(this), this.attr({
17862              text: a(this.textStr, ""),
17863              x: this.x || 0,
17864              y: this.y || 0
17865            }), this.box && i2(this.anchorX) && this.attr({
17866              anchorX: this.anchorX,
17867              anchorY: this.anchorY
17868            });
17869          }
17870          paddingSetter(t3, e3) {
17871            o(t3) ? t3 !== this[e3] && (this[e3] = t3, this.updateTextPadding()) : this[e3] = void 0;
17872          }
17873          rSetter(t3, e3) {
17874            this.boxAttr(e3, t3);
17875          }
17876          strokeSetter(t3, e3) {
17877            this.stroke = t3, this.boxAttr(e3, t3);
17878          }
17879          "stroke-widthSetter"(t3, e3) {
17880            t3 && (this.needsBox = true), this["stroke-width"] = t3, this.boxAttr(e3, t3);
17881          }
17882          "text-alignSetter"(t3) {
17883            this.textAlign = t3;
17884          }
17885          textSetter(t3) {
17886            void 0 !== t3 && this.text.attr({
17887              text: t3
17888            }), this.updateTextPadding(), this.reAlign();
17889          }
17890          updateBoxSize() {
17891            let t3;
17892            let e3 = this.text, r2 = {}, a2 = this.padding, n2 = this.bBox = (!o(this.widthSetting) || !o(this.heightSetting) || this.textAlign) && i2(e3.textStr) ? e3.getBBox(void 0, 0) : l.emptyBBox;
17893            this.width = this.getPaddedWidth(), this.height = (this.heightSetting || n2.height || 0) + 2 * a2;
17894            let h = this.renderer.fontMetrics(e3);
17895            if (this.baselineOffset = a2 + Math.min((this.text.firstLineMetrics || h).b, n2.height || 1 / 0), this.heightSetting && (this.baselineOffset += (this.heightSetting - h.h) / 2), this.needsBox && !e3.textPath) {
17896              if (!this.box) {
17897                let t4 = this.box = this.symbolKey ? this.renderer.symbol(this.symbolKey) : this.renderer.rect();
17898                t4.addClass(("button" === this.className ? "" : "highcharts-label-box") + (this.className ? " highcharts-" + this.className + "-box" : "")), t4.add(this);
17899              }
17900              t3 = this.getCrispAdjust(), r2.x = t3, r2.y = (this.baseline ? -this.baselineOffset : 0) + t3, r2.width = Math.round(this.width), r2.height = Math.round(this.height), this.box.attr(s(r2, this.deferredAttr)), this.deferredAttr = {};
17901            }
17902          }
17903          updateTextPadding() {
17904            let t3 = this.text;
17905            if (!t3.textPath) {
17906              this.updateBoxSize();
17907              let e3 = this.baseline ? 0 : this.baselineOffset, s2 = a(this.paddingLeft, this.padding);
17908              i2(this.widthSetting) && this.bBox && ("center" === this.textAlign || "right" === this.textAlign) && (s2 += {
17909                center: 0.5,
17910                right: 1
17911              }[this.textAlign] * (this.widthSetting - this.bBox.width)), (s2 !== t3.x || e3 !== t3.y) && (t3.attr("x", s2), t3.hasBoxWidthChanged && (this.bBox = t3.getBBox(true)), void 0 !== e3 && t3.attr("y", e3)), t3.x = s2, t3.y = e3;
17912            }
17913          }
17914          widthSetter(t3) {
17915            this.widthSetting = o(t3) ? t3 : void 0, this.doUpdate = true;
17916          }
17917          getPaddedWidth() {
17918            let t3 = this.padding, e3 = a(this.paddingLeft, t3), i3 = a(this.paddingRight, t3);
17919            return (this.widthSetting || this.bBox.width || 0) + e3 + i3;
17920          }
17921          xSetter(t3) {
17922            this.x = t3, this.alignFactor && (t3 -= this.alignFactor * this.getPaddedWidth(), this["forceAnimate:x"] = true), this.xSetting = Math.round(t3), this.attr("translateX", this.xSetting);
17923          }
17924          ySetter(t3) {
17925            this.ySetting = this.y = Math.round(t3), this.attr("translateY", this.ySetting);
17926          }
17927        }
17928        return l.emptyBBox = {
17929          width: 0,
17930          height: 0,
17931          x: 0,
17932          y: 0
17933        }, l.textProps = ["color", "direction", "fontFamily", "fontSize", "fontStyle", "fontWeight", "lineHeight", "textAlign", "textDecoration", "textOutline", "textOverflow", "whiteSpace", "width"], l;
17934      }), i(e, "Core/Renderer/SVG/Symbols.js", [e["Core/Utilities.js"]], function(t2) {
17935        let {
17936          defined: e2,
17937          isNumber: i2,
17938          pick: s
17939        } = t2;
17940        function o(t3, i3, o2, r2, a2) {
17941          let n = [];
17942          if (a2) {
17943            let l = a2.start || 0, h = s(a2.r, o2), d = s(a2.r, r2 || o2), c = 2e-4 / (a2.borderRadius ? 1 : Math.max(h, 1)), p = Math.abs((a2.end || 0) - l - 2 * Math.PI) < c, u11 = (a2.end || 0) - (p ? c : 0), g = a2.innerR, f = s(a2.open, p), m = Math.cos(l), x = Math.sin(l), y = Math.cos(u11), b = Math.sin(u11), v = s(a2.longArc, u11 - l - Math.PI < c ? 0 : 1), S2 = ["A", h, d, 0, v, s(a2.clockwise, 1), t3 + h * y, i3 + d * b];
17944            S2.params = {
17945              start: l,
17946              end: u11,
17947              cx: t3,
17948              cy: i3
17949            }, n.push(["M", t3 + h * m, i3 + d * x], S2), e2(g) && ((S2 = ["A", g, g, 0, v, e2(a2.clockwise) ? 1 - a2.clockwise : 0, t3 + g * m, i3 + g * x]).params = {
17950              start: u11,
17951              end: l,
17952              cx: t3,
17953              cy: i3
17954            }, n.push(f ? ["M", t3 + g * y, i3 + g * b] : ["L", t3 + g * y, i3 + g * b], S2)), f || n.push(["Z"]);
17955          }
17956          return n;
17957        }
17958        function r(t3, e3, i3, s2, o2) {
17959          return o2 && o2.r ? a(t3, e3, i3, s2, o2) : [["M", t3, e3], ["L", t3 + i3, e3], ["L", t3 + i3, e3 + s2], ["L", t3, e3 + s2], ["Z"]];
17960        }
17961        function a(t3, e3, i3, s2, o2) {
17962          let r2 = o2?.r || 0;
17963          return [["M", t3 + r2, e3], ["L", t3 + i3 - r2, e3], ["A", r2, r2, 0, 0, 1, t3 + i3, e3 + r2], ["L", t3 + i3, e3 + s2 - r2], ["A", r2, r2, 0, 0, 1, t3 + i3 - r2, e3 + s2], ["L", t3 + r2, e3 + s2], ["A", r2, r2, 0, 0, 1, t3, e3 + s2 - r2], ["L", t3, e3 + r2], ["A", r2, r2, 0, 0, 1, t3 + r2, e3], ["Z"]];
17964        }
17965        return {
17966          arc: o,
17967          callout: function(t3, e3, s2, o2, r2) {
17968            let n = Math.min(r2 && r2.r || 0, s2, o2), l = n + 6, h = r2 && r2.anchorX, d = r2 && r2.anchorY || 0, c = a(t3, e3, s2, o2, {
17969              r: n
17970            });
17971            if (!i2(h) || h < s2 && h > 0 && d < o2 && d > 0) return c;
17972            if (t3 + h > s2 - l) {
17973              if (d > e3 + l && d < e3 + o2 - l) c.splice(3, 1, ["L", t3 + s2, d - 6], ["L", t3 + s2 + 6, d], ["L", t3 + s2, d + 6], ["L", t3 + s2, e3 + o2 - n]);
17974              else if (h < s2) {
17975                let i3 = d < e3 + l, r3 = i3 ? e3 : e3 + o2;
17976                c.splice(i3 ? 2 : 5, 0, ["L", h, d], ["L", t3 + s2 - n, r3]);
17977              } else c.splice(3, 1, ["L", t3 + s2, o2 / 2], ["L", h, d], ["L", t3 + s2, o2 / 2], ["L", t3 + s2, e3 + o2 - n]);
17978            } else if (t3 + h < l) {
17979              if (d > e3 + l && d < e3 + o2 - l) c.splice(7, 1, ["L", t3, d + 6], ["L", t3 - 6, d], ["L", t3, d - 6], ["L", t3, e3 + n]);
17980              else if (h > 0) {
17981                let i3 = d < e3 + l, s3 = i3 ? e3 : e3 + o2;
17982                c.splice(i3 ? 1 : 6, 0, ["L", h, d], ["L", t3 + n, s3]);
17983              } else c.splice(7, 1, ["L", t3, o2 / 2], ["L", h, d], ["L", t3, o2 / 2], ["L", t3, e3 + n]);
17984            } else d > o2 && h < s2 - l ? c.splice(5, 1, ["L", h + 6, e3 + o2], ["L", h, e3 + o2 + 6], ["L", h - 6, e3 + o2], ["L", t3 + n, e3 + o2]) : d < 0 && h > l && c.splice(1, 1, ["L", h - 6, e3], ["L", h, e3 - 6], ["L", h + 6, e3], ["L", s2 - n, e3]);
17985            return c;
17986          },
17987          circle: function(t3, e3, i3, s2) {
17988            return o(t3 + i3 / 2, e3 + s2 / 2, i3 / 2, s2 / 2, {
17989              start: 0.5 * Math.PI,
17990              end: 2.5 * Math.PI,
17991              open: false
17992            });
17993          },
17994          diamond: function(t3, e3, i3, s2) {
17995            return [["M", t3 + i3 / 2, e3], ["L", t3 + i3, e3 + s2 / 2], ["L", t3 + i3 / 2, e3 + s2], ["L", t3, e3 + s2 / 2], ["Z"]];
17996          },
17997          rect: r,
17998          roundedRect: a,
17999          square: r,
18000          triangle: function(t3, e3, i3, s2) {
18001            return [["M", t3 + i3 / 2, e3], ["L", t3 + i3, e3 + s2], ["L", t3, e3 + s2], ["Z"]];
18002          },
18003          "triangle-down": function(t3, e3, i3, s2) {
18004            return [["M", t3, e3], ["L", t3 + i3, e3], ["L", t3 + i3 / 2, e3 + s2], ["Z"]];
18005          }
18006        };
18007      }), i(e, "Core/Renderer/SVG/TextBuilder.js", [e["Core/Renderer/HTML/AST.js"], e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
18008        let {
18009          doc: s,
18010          SVG_NS: o,
18011          win: r
18012        } = e2, {
18013          attr: a,
18014          extend: n,
18015          fireEvent: l,
18016          isString: h,
18017          objectEach: d,
18018          pick: c
18019        } = i2;
18020        return class {
18021          constructor(t3) {
18022            let e3 = t3.styles;
18023            this.renderer = t3.renderer, this.svgElement = t3, this.width = t3.textWidth, this.textLineHeight = e3 && e3.lineHeight, this.textOutline = e3 && e3.textOutline, this.ellipsis = !!(e3 && "ellipsis" === e3.textOverflow), this.noWrap = !!(e3 && "nowrap" === e3.whiteSpace);
18024          }
18025          buildSVG() {
18026            let e3 = this.svgElement, i3 = e3.element, o2 = e3.renderer, r2 = c(e3.textStr, "").toString(), a2 = -1 !== r2.indexOf("<"), n2 = i3.childNodes, l2 = !e3.added && o2.box, d2 = [r2, this.ellipsis, this.noWrap, this.textLineHeight, this.textOutline, e3.getStyle("font-size"), this.width].join(",");
18027            if (d2 !== e3.textCache) {
18028              e3.textCache = d2, delete e3.actualWidth;
18029              for (let t3 = n2.length; t3--; ) i3.removeChild(n2[t3]);
18030              if (a2 || this.ellipsis || this.width || e3.textPath || -1 !== r2.indexOf(" ") && (!this.noWrap || /<br.*?>/g.test(r2))) {
18031                if ("" !== r2) {
18032                  l2 && l2.appendChild(i3);
18033                  let s2 = new t2(r2);
18034                  this.modifyTree(s2.nodes), s2.addToDOM(i3), this.modifyDOM(), this.ellipsis && -1 !== (i3.textContent || "").indexOf("\u2026") && e3.attr("title", this.unescapeEntities(e3.textStr || "", ["&lt;", "&gt;"])), l2 && l2.removeChild(i3);
18035                }
18036              } else i3.appendChild(s.createTextNode(this.unescapeEntities(r2)));
18037              h(this.textOutline) && e3.applyTextOutline && e3.applyTextOutline(this.textOutline);
18038            }
18039          }
18040          modifyDOM() {
18041            let t3;
18042            let e3 = this.svgElement, i3 = a(e3.element, "x");
18043            for (e3.firstLineMetrics = void 0; t3 = e3.element.firstChild; ) if (/^[\s\u200B]*$/.test(t3.textContent || " ")) e3.element.removeChild(t3);
18044            else break;
18045            [].forEach.call(e3.element.querySelectorAll("tspan.highcharts-br"), (t4, s2) => {
18046              t4.nextSibling && t4.previousSibling && (0 === s2 && 1 === t4.previousSibling.nodeType && (e3.firstLineMetrics = e3.renderer.fontMetrics(t4.previousSibling)), a(t4, {
18047                dy: this.getLineHeight(t4.nextSibling),
18048                x: i3
18049              }));
18050            });
18051            let n2 = this.width || 0;
18052            if (!n2) return;
18053            let l2 = (t4, r2) => {
18054              let l3 = t4.textContent || "", h3 = l3.replace(/([^\^])-/g, "$1- ").split(" "), d2 = !this.noWrap && (h3.length > 1 || e3.element.childNodes.length > 1), c2 = this.getLineHeight(r2), p = 0, u11 = e3.actualWidth;
18055              if (this.ellipsis) l3 && this.truncate(t4, l3, void 0, 0, Math.max(0, n2 - 0.8 * c2), (t5, e4) => t5.substring(0, e4) + "\u2026");
18056              else if (d2) {
18057                let l4 = [], d3 = [];
18058                for (; r2.firstChild && r2.firstChild !== t4; ) d3.push(r2.firstChild), r2.removeChild(r2.firstChild);
18059                for (; h3.length; ) h3.length && !this.noWrap && p > 0 && (l4.push(t4.textContent || ""), t4.textContent = h3.join(" ").replace(/- /g, "-")), this.truncate(t4, void 0, h3, 0 === p && u11 || 0, n2, (t5, e4) => h3.slice(0, e4).join(" ").replace(/- /g, "-")), u11 = e3.actualWidth, p++;
18060                d3.forEach((e4) => {
18061                  r2.insertBefore(e4, t4);
18062                }), l4.forEach((e4) => {
18063                  r2.insertBefore(s.createTextNode(e4), t4);
18064                  let n3 = s.createElementNS(o, "tspan");
18065                  n3.textContent = "\u200B", a(n3, {
18066                    dy: c2,
18067                    x: i3
18068                  }), r2.insertBefore(n3, t4);
18069                });
18070              }
18071            }, h2 = (t4) => {
18072              [].slice.call(t4.childNodes).forEach((i4) => {
18073                i4.nodeType === r.Node.TEXT_NODE ? l2(i4, t4) : (-1 !== i4.className.baseVal.indexOf("highcharts-br") && (e3.actualWidth = 0), h2(i4));
18074              });
18075            };
18076            h2(e3.element);
18077          }
18078          getLineHeight(t3) {
18079            let e3 = t3.nodeType === r.Node.TEXT_NODE ? t3.parentElement : t3;
18080            return this.textLineHeight ? parseInt(this.textLineHeight.toString(), 10) : this.renderer.fontMetrics(e3 || this.svgElement.element).h;
18081          }
18082          modifyTree(t3) {
18083            let e3 = (i3, s2) => {
18084              let {
18085                attributes: o2 = {},
18086                children: r2,
18087                style: a2 = {},
18088                tagName: l2
18089              } = i3, h2 = this.renderer.styledMode;
18090              if ("b" === l2 || "strong" === l2 ? h2 ? o2.class = "highcharts-strong" : a2.fontWeight = "bold" : ("i" === l2 || "em" === l2) && (h2 ? o2.class = "highcharts-emphasized" : a2.fontStyle = "italic"), a2 && a2.color && (a2.fill = a2.color), "br" === l2) {
18091                o2.class = "highcharts-br", i3.textContent = "\u200B";
18092                let e4 = t3[s2 + 1];
18093                e4 && e4.textContent && (e4.textContent = e4.textContent.replace(/^ +/gm, ""));
18094              } else "a" === l2 && r2 && r2.some((t4) => "#text" === t4.tagName) && (i3.children = [{
18095                children: r2,
18096                tagName: "tspan"
18097              }]);
18098              "#text" !== l2 && "a" !== l2 && (i3.tagName = "tspan"), n(i3, {
18099                attributes: o2,
18100                style: a2
18101              }), r2 && r2.filter((t4) => "#text" !== t4.tagName).forEach(e3);
18102            };
18103            t3.forEach(e3), l(this.svgElement, "afterModifyTree", {
18104              nodes: t3
18105            });
18106          }
18107          truncate(t3, e3, i3, s2, o2, r2) {
18108            let a2, n2;
18109            let l2 = this.svgElement, {
18110              rotation: h2
18111            } = l2, d2 = [], c2 = i3 ? 1 : 0, p = (e3 || i3 || "").length, u11 = p, g = function(e4, o3) {
18112              let r3 = o3 || e4, a3 = t3.parentNode;
18113              if (a3 && void 0 === d2[r3] && a3.getSubStringLength) try {
18114                d2[r3] = s2 + a3.getSubStringLength(0, i3 ? r3 + 1 : r3);
18115              } catch (t4) {
18116              }
18117              return d2[r3];
18118            };
18119            if (l2.rotation = 0, s2 + (n2 = g(t3.textContent.length)) > o2) {
18120              for (; c2 <= p; ) u11 = Math.ceil((c2 + p) / 2), i3 && (a2 = r2(i3, u11)), n2 = g(u11, a2 && a2.length - 1), c2 === p ? c2 = p + 1 : n2 > o2 ? p = u11 - 1 : c2 = u11;
18121              0 === p ? t3.textContent = "" : e3 && p === e3.length - 1 || (t3.textContent = a2 || r2(e3 || i3, u11));
18122            }
18123            i3 && i3.splice(0, u11), l2.actualWidth = n2, l2.rotation = h2;
18124          }
18125          unescapeEntities(t3, e3) {
18126            return d(this.renderer.escapes, function(i3, s2) {
18127              e3 && -1 !== e3.indexOf(i3) || (t3 = t3.toString().replace(RegExp(i3, "g"), s2));
18128            }), t3;
18129          }
18130        };
18131      }), i(e, "Core/Renderer/SVG/SVGRenderer.js", [e["Core/Renderer/HTML/AST.js"], e["Core/Defaults.js"], e["Core/Color/Color.js"], e["Core/Globals.js"], e["Core/Renderer/RendererRegistry.js"], e["Core/Renderer/SVG/SVGElement.js"], e["Core/Renderer/SVG/SVGLabel.js"], e["Core/Renderer/SVG/Symbols.js"], e["Core/Renderer/SVG/TextBuilder.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o, r, a, n, l, h) {
18132        let d;
18133        let {
18134          defaultOptions: c
18135        } = e2, {
18136          charts: p,
18137          deg2rad: u11,
18138          doc: g,
18139          isFirefox: f,
18140          isMS: m,
18141          isWebKit: x,
18142          noop: y,
18143          SVG_NS: b,
18144          symbolSizes: v,
18145          win: S2
18146        } = s, {
18147          addEvent: k,
18148          attr: M,
18149          createElement: C,
18150          crisp: A,
18151          css: w,
18152          defined: T2,
18153          destroyObjectProperties: P,
18154          extend: O,
18155          isArray: L,
18156          isNumber: D2,
18157          isObject: E,
18158          isString: B,
18159          merge: j,
18160          pick: R,
18161          pInt: I,
18162          replaceNested: z,
18163          uniqueKey: G
18164        } = h;
18165        class N {
18166          constructor(t3, e3, i3, s2, o2, r2, a2) {
18167            let n2, l2;
18168            let h2 = this.createElement("svg").attr({
18169              version: "1.1",
18170              class: "highcharts-root"
18171            }), d2 = h2.element;
18172            a2 || h2.css(this.getStyle(s2 || {})), t3.appendChild(d2), M(t3, "dir", "ltr"), -1 === t3.innerHTML.indexOf("xmlns") && M(d2, "xmlns", this.SVG_NS), this.box = d2, this.boxWrapper = h2, this.alignedObjects = [], this.url = this.getReferenceURL(), this.createElement("desc").add().element.appendChild(g.createTextNode("Created with Highcharts 11.4.8")), this.defs = this.createElement("defs").add(), this.allowHTML = r2, this.forExport = o2, this.styledMode = a2, this.gradients = {}, this.cache = {}, this.cacheKeys = [], this.imgCount = 0, this.rootFontSize = h2.getStyle("font-size"), this.setSize(e3, i3, false), f && t3.getBoundingClientRect && ((n2 = function() {
18173              w(t3, {
18174                left: 0,
18175                top: 0
18176              }), l2 = t3.getBoundingClientRect(), w(t3, {
18177                left: Math.ceil(l2.left) - l2.left + "px",
18178                top: Math.ceil(l2.top) - l2.top + "px"
18179              });
18180            })(), this.unSubPixelFix = k(S2, "resize", n2));
18181          }
18182          definition(e3) {
18183            return new t2([e3]).addToDOM(this.defs.element);
18184          }
18185          getReferenceURL() {
18186            if ((f || x) && g.getElementsByTagName("base").length) {
18187              if (!T2(d)) {
18188                let e3 = G(), i3 = new t2([{
18189                  tagName: "svg",
18190                  attributes: {
18191                    width: 8,
18192                    height: 8
18193                  },
18194                  children: [{
18195                    tagName: "defs",
18196                    children: [{
18197                      tagName: "clipPath",
18198                      attributes: {
18199                        id: e3
18200                      },
18201                      children: [{
18202                        tagName: "rect",
18203                        attributes: {
18204                          width: 4,
18205                          height: 4
18206                        }
18207                      }]
18208                    }]
18209                  }, {
18210                    tagName: "rect",
18211                    attributes: {
18212                      id: "hitme",
18213                      width: 8,
18214                      height: 8,
18215                      "clip-path": `url(#${e3})`,
18216                      fill: "rgba(0,0,0,0.001)"
18217                    }
18218                  }]
18219                }]).addToDOM(g.body);
18220                w(i3, {
18221                  position: "fixed",
18222                  top: 0,
18223                  left: 0,
18224                  zIndex: 9e5
18225                });
18226                let s2 = g.elementFromPoint(6, 6);
18227                d = "hitme" === (s2 && s2.id), g.body.removeChild(i3);
18228              }
18229              if (d) return z(S2.location.href.split("#")[0], [/<[^>]*>/g, ""], [/([\('\)])/g, "\\$1"], [/ /g, "%20"]);
18230            }
18231            return "";
18232          }
18233          getStyle(t3) {
18234            return this.style = O({
18235              fontFamily: "Helvetica, Arial, sans-serif",
18236              fontSize: "1rem"
18237            }, t3), this.style;
18238          }
18239          setStyle(t3) {
18240            this.boxWrapper.css(this.getStyle(t3));
18241          }
18242          isHidden() {
18243            return !this.boxWrapper.getBBox().width;
18244          }
18245          destroy() {
18246            let t3 = this.defs;
18247            return this.box = null, this.boxWrapper = this.boxWrapper.destroy(), P(this.gradients || {}), this.gradients = null, this.defs = t3.destroy(), this.unSubPixelFix && this.unSubPixelFix(), this.alignedObjects = null, null;
18248          }
18249          createElement(t3) {
18250            return new this.Element(this, t3);
18251          }
18252          getRadialAttr(t3, e3) {
18253            return {
18254              cx: t3[0] - t3[2] / 2 + (e3.cx || 0) * t3[2],
18255              cy: t3[1] - t3[2] / 2 + (e3.cy || 0) * t3[2],
18256              r: (e3.r || 0) * t3[2]
18257            };
18258          }
18259          shadowDefinition(t3) {
18260            let e3 = [`highcharts-drop-shadow-${this.chartIndex}`, ...Object.keys(t3).map((e4) => `${e4}-${t3[e4]}`)].join("-").toLowerCase().replace(/[^a-z\d\-]/g, ""), i3 = j({
18261              color: "#000000",
18262              offsetX: 1,
18263              offsetY: 1,
18264              opacity: 0.15,
18265              width: 5
18266            }, t3);
18267            return this.defs.element.querySelector(`#${e3}`) || this.definition({
18268              tagName: "filter",
18269              attributes: {
18270                id: e3,
18271                filterUnits: i3.filterUnits
18272              },
18273              children: this.getShadowFilterContent(i3)
18274            }), e3;
18275          }
18276          getShadowFilterContent(t3) {
18277            return [{
18278              tagName: "feDropShadow",
18279              attributes: {
18280                dx: t3.offsetX,
18281                dy: t3.offsetY,
18282                "flood-color": t3.color,
18283                "flood-opacity": Math.min(5 * t3.opacity, 1),
18284                stdDeviation: t3.width / 2
18285              }
18286            }];
18287          }
18288          buildText(t3) {
18289            new l(t3).buildSVG();
18290          }
18291          getContrast(t3) {
18292            let e3 = i2.parse(t3).rgba.map((t4) => {
18293              let e4 = t4 / 255;
18294              return e4 <= 0.03928 ? e4 / 12.92 : Math.pow((e4 + 0.055) / 1.055, 2.4);
18295            }), s2 = 0.2126 * e3[0] + 0.7152 * e3[1] + 0.0722 * e3[2];
18296            return 1.05 / (s2 + 0.05) > (s2 + 0.05) / 0.05 ? "#FFFFFF" : "#000000";
18297          }
18298          button(e3, i3, s2, o2, r2 = {}, a2, n2, l2, h2, d2) {
18299            let p2 = this.label(e3, i3, s2, h2, void 0, void 0, d2, void 0, "button"), u12 = this.styledMode, g2 = arguments, f2 = 0;
18300            r2 = j(c.global.buttonTheme, r2), u12 && (delete r2.fill, delete r2.stroke, delete r2["stroke-width"]);
18301            let x2 = r2.states || {}, y2 = r2.style || {};
18302            delete r2.states, delete r2.style;
18303            let b2 = [t2.filterUserAttributes(r2)], v2 = [y2];
18304            return u12 || ["hover", "select", "disabled"].forEach((e4, i4) => {
18305              b2.push(j(b2[0], t2.filterUserAttributes(g2[i4 + 5] || x2[e4] || {}))), v2.push(b2[i4 + 1].style), delete b2[i4 + 1].style;
18306            }), k(p2.element, m ? "mouseover" : "mouseenter", function() {
18307              3 !== f2 && p2.setState(1);
18308            }), k(p2.element, m ? "mouseout" : "mouseleave", function() {
18309              3 !== f2 && p2.setState(f2);
18310            }), p2.setState = (t3 = 0) => {
18311              if (1 !== t3 && (p2.state = f2 = t3), p2.removeClass(/highcharts-button-(normal|hover|pressed|disabled)/).addClass("highcharts-button-" + ["normal", "hover", "pressed", "disabled"][t3]), !u12) {
18312                p2.attr(b2[t3]);
18313                let e4 = v2[t3];
18314                E(e4) && p2.css(e4);
18315              }
18316            }, p2.attr(b2[0]), !u12 && (p2.css(O({
18317              cursor: "default"
18318            }, y2)), d2 && p2.text.css({
18319              pointerEvents: "none"
18320            })), p2.on("touchstart", (t3) => t3.stopPropagation()).on("click", function(t3) {
18321              3 !== f2 && o2.call(p2, t3);
18322            });
18323          }
18324          crispLine(t3, e3) {
18325            let [i3, s2] = t3;
18326            return T2(i3[1]) && i3[1] === s2[1] && (i3[1] = s2[1] = A(i3[1], e3)), T2(i3[2]) && i3[2] === s2[2] && (i3[2] = s2[2] = A(i3[2], e3)), t3;
18327          }
18328          path(t3) {
18329            let e3 = this.styledMode ? {} : {
18330              fill: "none"
18331            };
18332            return L(t3) ? e3.d = t3 : E(t3) && O(e3, t3), this.createElement("path").attr(e3);
18333          }
18334          circle(t3, e3, i3) {
18335            let s2 = E(t3) ? t3 : void 0 === t3 ? {} : {
18336              x: t3,
18337              y: e3,
18338              r: i3
18339            }, o2 = this.createElement("circle");
18340            return o2.xSetter = o2.ySetter = function(t4, e4, i4) {
18341              i4.setAttribute("c" + e4, t4);
18342            }, o2.attr(s2);
18343          }
18344          arc(t3, e3, i3, s2, o2, r2) {
18345            let a2;
18346            E(t3) ? (e3 = (a2 = t3).y, i3 = a2.r, s2 = a2.innerR, o2 = a2.start, r2 = a2.end, t3 = a2.x) : a2 = {
18347              innerR: s2,
18348              start: o2,
18349              end: r2
18350            };
18351            let n2 = this.symbol("arc", t3, e3, i3, i3, a2);
18352            return n2.r = i3, n2;
18353          }
18354          rect(t3, e3, i3, s2, o2, r2) {
18355            let a2 = E(t3) ? t3 : void 0 === t3 ? {} : {
18356              x: t3,
18357              y: e3,
18358              r: o2,
18359              width: Math.max(i3 || 0, 0),
18360              height: Math.max(s2 || 0, 0)
18361            }, n2 = this.createElement("rect");
18362            return this.styledMode || (void 0 !== r2 && (a2["stroke-width"] = r2, O(a2, n2.crisp(a2))), a2.fill = "none"), n2.rSetter = function(t4, e4, i4) {
18363              n2.r = t4, M(i4, {
18364                rx: t4,
18365                ry: t4
18366              });
18367            }, n2.rGetter = function() {
18368              return n2.r || 0;
18369            }, n2.attr(a2);
18370          }
18371          roundedRect(t3) {
18372            return this.symbol("roundedRect").attr(t3);
18373          }
18374          setSize(t3, e3, i3) {
18375            this.width = t3, this.height = e3, this.boxWrapper.animate({
18376              width: t3,
18377              height: e3
18378            }, {
18379              step: function() {
18380                this.attr({
18381                  viewBox: "0 0 " + this.attr("width") + " " + this.attr("height")
18382                });
18383              },
18384              duration: R(i3, true) ? void 0 : 0
18385            }), this.alignElements();
18386          }
18387          g(t3) {
18388            let e3 = this.createElement("g");
18389            return t3 ? e3.attr({
18390              class: "highcharts-" + t3
18391            }) : e3;
18392          }
18393          image(t3, e3, i3, s2, o2, r2) {
18394            let a2 = {
18395              preserveAspectRatio: "none"
18396            };
18397            D2(e3) && (a2.x = e3), D2(i3) && (a2.y = i3), D2(s2) && (a2.width = s2), D2(o2) && (a2.height = o2);
18398            let n2 = this.createElement("image").attr(a2), l2 = function(e4) {
18399              n2.attr({
18400                href: t3
18401              }), r2.call(n2, e4);
18402            };
18403            if (r2) {
18404              n2.attr({
18405                href: "data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw=="
18406              });
18407              let e4 = new S2.Image();
18408              k(e4, "load", l2), e4.src = t3, e4.complete && l2({});
18409            } else n2.attr({
18410              href: t3
18411            });
18412            return n2;
18413          }
18414          symbol(t3, e3, i3, s2, o2, r2) {
18415            let a2, n2, l2, h2;
18416            let d2 = this, c2 = /^url\((.*?)\)$/, u12 = c2.test(t3), f2 = !u12 && (this.symbols[t3] ? t3 : "circle"), m2 = f2 && this.symbols[f2];
18417            if (m2) "number" == typeof e3 && (n2 = m2.call(this.symbols, e3 || 0, i3 || 0, s2 || 0, o2 || 0, r2)), a2 = this.path(n2), d2.styledMode || a2.attr("fill", "none"), O(a2, {
18418              symbolName: f2 || void 0,
18419              x: e3,
18420              y: i3,
18421              width: s2,
18422              height: o2
18423            }), r2 && O(a2, r2);
18424            else if (u12) {
18425              l2 = t3.match(c2)[1];
18426              let s3 = a2 = this.image(l2);
18427              s3.imgwidth = R(r2 && r2.width, v[l2] && v[l2].width), s3.imgheight = R(r2 && r2.height, v[l2] && v[l2].height), h2 = (t4) => t4.attr({
18428                width: t4.width,
18429                height: t4.height
18430              }), ["width", "height"].forEach((t4) => {
18431                s3[`${t4}Setter`] = function(t5, e4) {
18432                  this[e4] = t5;
18433                  let {
18434                    alignByTranslate: i4,
18435                    element: s4,
18436                    width: o3,
18437                    height: a3,
18438                    imgwidth: n3,
18439                    imgheight: l3
18440                  } = this, h3 = "width" === e4 ? n3 : l3, d3 = 1;
18441                  r2 && "within" === r2.backgroundSize && o3 && a3 && n3 && l3 ? (d3 = Math.min(o3 / n3, a3 / l3), M(s4, {
18442                    width: Math.round(n3 * d3),
18443                    height: Math.round(l3 * d3)
18444                  })) : s4 && h3 && s4.setAttribute(e4, h3), !i4 && n3 && l3 && this.translate(((o3 || 0) - n3 * d3) / 2, ((a3 || 0) - l3 * d3) / 2);
18445                };
18446              }), T2(e3) && s3.attr({
18447                x: e3,
18448                y: i3
18449              }), s3.isImg = true, s3.symbolUrl = t3, T2(s3.imgwidth) && T2(s3.imgheight) ? h2(s3) : (s3.attr({
18450                width: 0,
18451                height: 0
18452              }), C("img", {
18453                onload: function() {
18454                  let t4 = p[d2.chartIndex];
18455                  0 === this.width && (w(this, {
18456                    position: "absolute",
18457                    top: "-999em"
18458                  }), g.body.appendChild(this)), v[l2] = {
18459                    width: this.width,
18460                    height: this.height
18461                  }, s3.imgwidth = this.width, s3.imgheight = this.height, s3.element && h2(s3), this.parentNode && this.parentNode.removeChild(this), d2.imgCount--, d2.imgCount || !t4 || t4.hasLoaded || t4.onload();
18462                },
18463                src: l2
18464              }), this.imgCount++);
18465            }
18466            return a2;
18467          }
18468          clipRect(t3, e3, i3, s2) {
18469            return this.rect(t3, e3, i3, s2, 0);
18470          }
18471          text(t3, e3, i3, s2) {
18472            let o2 = {};
18473            if (s2 && (this.allowHTML || !this.forExport)) return this.html(t3, e3, i3);
18474            o2.x = Math.round(e3 || 0), i3 && (o2.y = Math.round(i3)), T2(t3) && (o2.text = t3);
18475            let r2 = this.createElement("text").attr(o2);
18476            return s2 && (!this.forExport || this.allowHTML) || (r2.xSetter = function(t4, e4, i4) {
18477              let s3 = i4.getElementsByTagName("tspan"), o3 = i4.getAttribute(e4);
18478              for (let i5 = 0, r3; i5 < s3.length; i5++) (r3 = s3[i5]).getAttribute(e4) === o3 && r3.setAttribute(e4, t4);
18479              i4.setAttribute(e4, t4);
18480            }), r2;
18481          }
18482          fontMetrics(t3) {
18483            let e3 = I(r.prototype.getStyle.call(t3, "font-size") || 0), i3 = e3 < 24 ? e3 + 3 : Math.round(1.2 * e3), s2 = Math.round(0.8 * i3);
18484            return {
18485              h: i3,
18486              b: s2,
18487              f: e3
18488            };
18489          }
18490          rotCorr(t3, e3, i3) {
18491            let s2 = t3;
18492            return e3 && i3 && (s2 = Math.max(s2 * Math.cos(e3 * u11), 4)), {
18493              x: -t3 / 3 * Math.sin(e3 * u11),
18494              y: s2
18495            };
18496          }
18497          pathToSegments(t3) {
18498            let e3 = [], i3 = [], s2 = {
18499              A: 8,
18500              C: 7,
18501              H: 2,
18502              L: 3,
18503              M: 3,
18504              Q: 5,
18505              S: 5,
18506              T: 3,
18507              V: 2
18508            };
18509            for (let o2 = 0; o2 < t3.length; o2++) B(i3[0]) && D2(t3[o2]) && i3.length === s2[i3[0].toUpperCase()] && t3.splice(o2, 0, i3[0].replace("M", "L").replace("m", "l")), "string" == typeof t3[o2] && (i3.length && e3.push(i3.slice(0)), i3.length = 0), i3.push(t3[o2]);
18510            return e3.push(i3.slice(0)), e3;
18511          }
18512          label(t3, e3, i3, s2, o2, r2, n2, l2, h2) {
18513            return new a(this, t3, e3, i3, s2, o2, r2, n2, l2, h2);
18514          }
18515          alignElements() {
18516            this.alignedObjects.forEach((t3) => t3.align());
18517          }
18518        }
18519        return O(N.prototype, {
18520          Element: r,
18521          SVG_NS: b,
18522          escapes: {
18523            "&": "&amp;",
18524            "<": "&lt;",
18525            ">": "&gt;",
18526            "'": "&#39;",
18527            '"': "&quot;"
18528          },
18529          symbols: n,
18530          draw: y
18531        }), o.registerRendererType("svg", N, true), N;
18532      }), i(e, "Core/Renderer/HTML/HTMLElement.js", [e["Core/Renderer/HTML/AST.js"], e["Core/Globals.js"], e["Core/Renderer/SVG/SVGElement.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
18533        let {
18534          composed: o
18535        } = e2, {
18536          attr: r,
18537          css: a,
18538          createElement: n,
18539          defined: l,
18540          extend: h,
18541          pInt: d,
18542          pushUnique: c
18543        } = s;
18544        function p(t3, e3, s2) {
18545          let o2 = this.div?.style || s2.style;
18546          i2.prototype[`${e3}Setter`].call(this, t3, e3, s2), o2 && (o2[e3] = t3);
18547        }
18548        let u11 = (t3, e3) => {
18549          if (!t3.div) {
18550            let s2 = r(t3.element, "class"), o2 = t3.css, a2 = n("div", s2 ? {
18551              className: s2
18552            } : void 0, __spreadProps(__spreadValues({
18553              position: "absolute",
18554              left: `${t3.translateX || 0}px`,
18555              top: `${t3.translateY || 0}px`
18556            }, t3.styles), {
18557              display: t3.display,
18558              opacity: t3.opacity,
18559              visibility: t3.visibility
18560            }), t3.parentGroup?.div || e3);
18561            t3.classSetter = (t4, e4, i3) => {
18562              i3.setAttribute("class", t4), a2.className = t4;
18563            }, t3.translateXSetter = t3.translateYSetter = (e4, i3) => {
18564              t3[i3] = e4, a2.style["translateX" === i3 ? "left" : "top"] = `${e4}px`, t3.doTransform = true;
18565            }, t3.opacitySetter = t3.visibilitySetter = p, t3.css = (e4) => (o2.call(t3, e4), e4.cursor && (a2.style.cursor = e4.cursor), e4.pointerEvents && (a2.style.pointerEvents = e4.pointerEvents), t3), t3.on = function() {
18566              return i2.prototype.on.apply({
18567                element: a2,
18568                onEvents: t3.onEvents
18569              }, arguments), t3;
18570            }, t3.div = a2;
18571          }
18572          return t3.div;
18573        };
18574        class g extends i2 {
18575          static compose(t3) {
18576            c(o, this.compose) && (t3.prototype.html = function(t4, e3, i3) {
18577              return new g(this, "span").attr({
18578                text: t4,
18579                x: Math.round(e3),
18580                y: Math.round(i3)
18581              });
18582            });
18583          }
18584          constructor(t3, e3) {
18585            super(t3, e3), this.css(__spreadValues({
18586              position: "absolute"
18587            }, t3.styledMode ? {} : {
18588              fontFamily: t3.style.fontFamily,
18589              fontSize: t3.style.fontSize
18590            })), this.element.style.whiteSpace = "nowrap";
18591          }
18592          getSpanCorrection(t3, e3, i3) {
18593            this.xCorr = -t3 * i3, this.yCorr = -e3;
18594          }
18595          css(t3) {
18596            let e3;
18597            let {
18598              element: i3
18599            } = this, s2 = "SPAN" === i3.tagName && t3 && "width" in t3, o2 = s2 && t3.width;
18600            return s2 && (delete t3.width, this.textWidth = d(o2) || void 0, e3 = true), t3?.textOverflow === "ellipsis" && (t3.whiteSpace = "nowrap", t3.overflow = "hidden"), h(this.styles, t3), a(i3, t3), e3 && this.updateTransform(), this;
18601          }
18602          htmlGetBBox() {
18603            let {
18604              element: t3
18605            } = this;
18606            return {
18607              x: t3.offsetLeft,
18608              y: t3.offsetTop,
18609              width: t3.offsetWidth,
18610              height: t3.offsetHeight
18611            };
18612          }
18613          updateTransform() {
18614            if (!this.added) {
18615              this.alignOnAdd = true;
18616              return;
18617            }
18618            let {
18619              element: t3,
18620              renderer: e3,
18621              rotation: i3,
18622              rotationOriginX: s2,
18623              rotationOriginY: o2,
18624              styles: r2,
18625              textAlign: n2 = "left",
18626              textWidth: h2,
18627              translateX: d2 = 0,
18628              translateY: c2 = 0,
18629              x: p2 = 0,
18630              y: u12 = 0
18631            } = this, g2 = {
18632              left: 0,
18633              center: 0.5,
18634              right: 1
18635            }[n2], f2 = r2.whiteSpace;
18636            if (a(t3, {
18637              marginLeft: `${d2}px`,
18638              marginTop: `${c2}px`
18639            }), "SPAN" === t3.tagName) {
18640              let r3 = [i3, n2, t3.innerHTML, h2, this.textAlign].join(","), d3 = -(this.parentGroup?.padding * 1) || 0, c3, m = false;
18641              if (h2 !== this.oldTextWidth) {
18642                let e4 = this.textPxLength ? this.textPxLength : (a(t3, {
18643                  width: "",
18644                  whiteSpace: f2 || "nowrap"
18645                }), t3.offsetWidth), s3 = h2 || 0;
18646                (s3 > this.oldTextWidth || e4 > s3) && (/[ \-]/.test(t3.textContent || t3.innerText) || "ellipsis" === t3.style.textOverflow) && (a(t3, {
18647                  width: e4 > s3 || i3 ? h2 + "px" : "auto",
18648                  display: "block",
18649                  whiteSpace: f2 || "normal"
18650                }), this.oldTextWidth = h2, m = true);
18651              }
18652              this.hasBoxWidthChanged = m, r3 !== this.cTT && (c3 = e3.fontMetrics(t3).b, l(i3) && (i3 !== (this.oldRotation || 0) || n2 !== this.oldAlign) && this.setSpanRotation(i3, d3, d3), this.getSpanCorrection(!l(i3) && this.textPxLength || t3.offsetWidth, c3, g2));
18653              let {
18654                xCorr: x = 0,
18655                yCorr: y = 0
18656              } = this, b = (s2 ?? p2) - x - p2 - d3, v = (o2 ?? u12) - y - u12 - d3;
18657              a(t3, {
18658                left: `${p2 + x}px`,
18659                top: `${u12 + y}px`,
18660                transformOrigin: `${b}px ${v}px`
18661              }), this.cTT = r3, this.oldRotation = i3, this.oldAlign = n2;
18662            }
18663          }
18664          setSpanRotation(t3, e3, i3) {
18665            a(this.element, {
18666              transform: `rotate(${t3}deg)`,
18667              transformOrigin: `${e3}% ${i3}px`
18668            });
18669          }
18670          add(t3) {
18671            let e3;
18672            let i3 = this.renderer.box.parentNode, s2 = [];
18673            if (this.parentGroup = t3, t3 && !(e3 = t3.div)) {
18674              let o2 = t3;
18675              for (; o2; ) s2.push(o2), o2 = o2.parentGroup;
18676              for (let t4 of s2.reverse()) e3 = u11(t4, i3);
18677            }
18678            return (e3 || i3).appendChild(this.element), this.added = true, this.alignOnAdd && this.updateTransform(), this;
18679          }
18680          textSetter(e3) {
18681            e3 !== this.textStr && (delete this.bBox, delete this.oldTextWidth, t2.setElementHTML(this.element, e3 ?? ""), this.textStr = e3, this.doTransform = true);
18682          }
18683          alignSetter(t3) {
18684            this.alignValue = this.textAlign = t3, this.doTransform = true;
18685          }
18686          xSetter(t3, e3) {
18687            this[e3] = t3, this.doTransform = true;
18688          }
18689        }
18690        let f = g.prototype;
18691        return f.visibilitySetter = f.opacitySetter = p, f.ySetter = f.rotationSetter = f.rotationOriginXSetter = f.rotationOriginYSetter = f.xSetter, g;
18692      }), i(e, "Core/Axis/AxisDefaults.js", [], function() {
18693        var t2, e2;
18694        return (e2 = t2 || (t2 = {})).xAxis = {
18695          alignTicks: true,
18696          allowDecimals: void 0,
18697          panningEnabled: true,
18698          zIndex: 2,
18699          zoomEnabled: true,
18700          dateTimeLabelFormats: {
18701            millisecond: {
18702              main: "%H:%M:%S.%L",
18703              range: false
18704            },
18705            second: {
18706              main: "%H:%M:%S",
18707              range: false
18708            },
18709            minute: {
18710              main: "%H:%M",
18711              range: false
18712            },
18713            hour: {
18714              main: "%H:%M",
18715              range: false
18716            },
18717            day: {
18718              main: "%e %b"
18719            },
18720            week: {
18721              main: "%e %b"
18722            },
18723            month: {
18724              main: "%b '%y"
18725            },
18726            year: {
18727              main: "%Y"
18728            }
18729          },
18730          endOnTick: false,
18731          gridLineDashStyle: "Solid",
18732          gridZIndex: 1,
18733          labels: {
18734            autoRotationLimit: 80,
18735            distance: 15,
18736            enabled: true,
18737            indentation: 10,
18738            overflow: "justify",
18739            reserveSpace: void 0,
18740            rotation: void 0,
18741            staggerLines: 0,
18742            step: 0,
18743            useHTML: false,
18744            zIndex: 7,
18745            style: {
18746              color: "#333333",
18747              cursor: "default",
18748              fontSize: "0.8em"
18749            }
18750          },
18751          maxPadding: 0.01,
18752          minorGridLineDashStyle: "Solid",
18753          minorTickLength: 2,
18754          minorTickPosition: "outside",
18755          minorTicksPerMajor: 5,
18756          minPadding: 0.01,
18757          offset: void 0,
18758          reversed: void 0,
18759          reversedStacks: false,
18760          showEmpty: true,
18761          showFirstLabel: true,
18762          showLastLabel: true,
18763          startOfWeek: 1,
18764          startOnTick: false,
18765          tickLength: 10,
18766          tickPixelInterval: 100,
18767          tickmarkPlacement: "between",
18768          tickPosition: "outside",
18769          title: {
18770            align: "middle",
18771            useHTML: false,
18772            x: 0,
18773            y: 0,
18774            style: {
18775              color: "#666666",
18776              fontSize: "0.8em"
18777            }
18778          },
18779          visible: true,
18780          minorGridLineColor: "#f2f2f2",
18781          minorGridLineWidth: 1,
18782          minorTickColor: "#999999",
18783          lineColor: "#333333",
18784          lineWidth: 1,
18785          gridLineColor: "#e6e6e6",
18786          gridLineWidth: void 0,
18787          tickColor: "#333333"
18788        }, e2.yAxis = {
18789          reversedStacks: true,
18790          endOnTick: true,
18791          maxPadding: 0.05,
18792          minPadding: 0.05,
18793          tickPixelInterval: 72,
18794          showLastLabel: true,
18795          labels: {
18796            x: void 0
18797          },
18798          startOnTick: true,
18799          title: {
18800            text: "Values"
18801          },
18802          stackLabels: {
18803            animation: {},
18804            allowOverlap: false,
18805            enabled: false,
18806            crop: true,
18807            overflow: "justify",
18808            formatter: function() {
18809              let {
18810                numberFormatter: t3
18811              } = this.axis.chart;
18812              return t3(this.total || 0, -1);
18813            },
18814            style: {
18815              color: "#000000",
18816              fontSize: "0.7em",
18817              fontWeight: "bold",
18818              textOutline: "1px contrast"
18819            }
18820          },
18821          gridLineWidth: 1,
18822          lineWidth: 0
18823        }, t2;
18824      }), i(e, "Core/Foundation.js", [e["Core/Utilities.js"]], function(t2) {
18825        var e2;
18826        let {
18827          addEvent: i2,
18828          isFunction: s,
18829          objectEach: o,
18830          removeEvent: r
18831        } = t2;
18832        return (e2 || (e2 = {})).registerEventOptions = function(t3, e3) {
18833          t3.eventOptions = t3.eventOptions || {}, o(e3.events, function(e4, o2) {
18834            t3.eventOptions[o2] !== e4 && (t3.eventOptions[o2] && (r(t3, o2, t3.eventOptions[o2]), delete t3.eventOptions[o2]), s(e4) && (t3.eventOptions[o2] = e4, i2(t3, o2, e4, {
18835              order: 0
18836            })));
18837          });
18838        }, e2;
18839      }), i(e, "Core/Axis/Tick.js", [e["Core/Templating.js"], e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
18840        let {
18841          deg2rad: s
18842        } = e2, {
18843          clamp: o,
18844          correctFloat: r,
18845          defined: a,
18846          destroyObjectProperties: n,
18847          extend: l,
18848          fireEvent: h,
18849          isNumber: d,
18850          merge: c,
18851          objectEach: p,
18852          pick: u11
18853        } = i2;
18854        return class {
18855          constructor(t3, e3, i3, s2, o2) {
18856            this.isNew = true, this.isNewLabel = true, this.axis = t3, this.pos = e3, this.type = i3 || "", this.parameters = o2 || {}, this.tickmarkOffset = this.parameters.tickmarkOffset, this.options = this.parameters.options, h(this, "init"), i3 || s2 || this.addLabel();
18857          }
18858          addLabel() {
18859            let e3 = this, i3 = e3.axis, s2 = i3.options, o2 = i3.chart, n2 = i3.categories, c2 = i3.logarithmic, p2 = i3.names, g = e3.pos, f = u11(e3.options && e3.options.labels, s2.labels), m = i3.tickPositions, x = g === m[0], y = g === m[m.length - 1], b = (!f.step || 1 === f.step) && 1 === i3.tickInterval, v = m.info, S2 = e3.label, k, M, C, A = this.parameters.category || (n2 ? u11(n2[g], p2[g], g) : g);
18860            c2 && d(A) && (A = r(c2.lin2log(A))), i3.dateTime && (v ? k = (M = o2.time.resolveDTLFormat(s2.dateTimeLabelFormats[!s2.grid && v.higherRanks[g] || v.unitName])).main : d(A) && (k = i3.dateTime.getXDateFormat(A, s2.dateTimeLabelFormats || {}))), e3.isFirst = x, e3.isLast = y;
18861            let w = {
18862              axis: i3,
18863              chart: o2,
18864              dateTimeLabelFormat: k,
18865              isFirst: x,
18866              isLast: y,
18867              pos: g,
18868              tick: e3,
18869              tickPositionInfo: v,
18870              value: A
18871            };
18872            h(this, "labelFormat", w);
18873            let T2 = (e4) => f.formatter ? f.formatter.call(e4, e4) : f.format ? (e4.text = i3.defaultLabelFormatter.call(e4), t2.format(f.format, e4, o2)) : i3.defaultLabelFormatter.call(e4), P = T2.call(w, w), O = M && M.list;
18874            O ? e3.shortenLabel = function() {
18875              for (C = 0; C < O.length; C++) if (l(w, {
18876                dateTimeLabelFormat: O[C]
18877              }), S2.attr({
18878                text: T2.call(w, w)
18879              }), S2.getBBox().width < i3.getSlotWidth(e3) - 2 * (f.padding || 0)) return;
18880              S2.attr({
18881                text: ""
18882              });
18883            } : e3.shortenLabel = void 0, b && i3._addedPlotLB && e3.moveLabel(P, f), a(S2) || e3.movedLabel ? S2 && S2.textStr !== P && !b && (!S2.textWidth || f.style.width || S2.styles.width || S2.css({
18884              width: null
18885            }), S2.attr({
18886              text: P
18887            }), S2.textPxLength = S2.getBBox().width) : (e3.label = S2 = e3.createLabel(P, f), e3.rotation = 0);
18888          }
18889          createLabel(t3, e3, i3) {
18890            let s2 = this.axis, o2 = s2.chart, r2 = a(t3) && e3.enabled ? o2.renderer.text(t3, i3?.x, i3?.y, e3.useHTML).add(s2.labelGroup) : void 0;
18891            return r2 && (o2.styledMode || r2.css(c(e3.style)), r2.textPxLength = r2.getBBox().width), r2;
18892          }
18893          destroy() {
18894            n(this, this.axis);
18895          }
18896          getPosition(t3, e3, i3, s2) {
18897            let a2 = this.axis, n2 = a2.chart, l2 = s2 && n2.oldChartHeight || n2.chartHeight, d2 = {
18898              x: t3 ? r(a2.translate(e3 + i3, void 0, void 0, s2) + a2.transB) : a2.left + a2.offset + (a2.opposite ? (s2 && n2.oldChartWidth || n2.chartWidth) - a2.right - a2.left : 0),
18899              y: t3 ? l2 - a2.bottom + a2.offset - (a2.opposite ? a2.height : 0) : r(l2 - a2.translate(e3 + i3, void 0, void 0, s2) - a2.transB)
18900            };
18901            return d2.y = o(d2.y, -1e9, 1e9), h(this, "afterGetPosition", {
18902              pos: d2
18903            }), d2;
18904          }
18905          getLabelPosition(t3, e3, i3, o2, r2, n2, l2, d2) {
18906            let c2, p2;
18907            let g = this.axis, f = g.transA, m = g.isLinked && g.linkedParent ? g.linkedParent.reversed : g.reversed, x = g.staggerLines, y = g.tickRotCorr || {
18908              x: 0,
18909              y: 0
18910            }, b = o2 || g.reserveSpaceDefault ? 0 : -g.labelOffset * ("center" === g.labelAlign ? 0.5 : 1), v = r2.distance, S2 = {};
18911            return c2 = 0 === g.side ? i3.rotation ? -v : -i3.getBBox().height : 2 === g.side ? y.y + v : Math.cos(i3.rotation * s) * (y.y - i3.getBBox(false, 0).height / 2), a(r2.y) && (c2 = 0 === g.side && g.horiz ? r2.y + c2 : r2.y), t3 = t3 + u11(r2.x, [0, 1, 0, -1][g.side] * v) + b + y.x - (n2 && o2 ? n2 * f * (m ? -1 : 1) : 0), e3 = e3 + c2 - (n2 && !o2 ? n2 * f * (m ? 1 : -1) : 0), x && (p2 = l2 / (d2 || 1) % x, g.opposite && (p2 = x - p2 - 1), e3 += p2 * (g.labelOffset / x)), S2.x = t3, S2.y = Math.round(e3), h(this, "afterGetLabelPosition", {
18912              pos: S2,
18913              tickmarkOffset: n2,
18914              index: l2
18915            }), S2;
18916          }
18917          getLabelSize() {
18918            return this.label ? this.label.getBBox()[this.axis.horiz ? "height" : "width"] : 0;
18919          }
18920          getMarkPath(t3, e3, i3, s2, o2 = false, r2) {
18921            return r2.crispLine([["M", t3, e3], ["L", t3 + (o2 ? 0 : -i3), e3 + (o2 ? i3 : 0)]], s2);
18922          }
18923          handleOverflow(t3) {
18924            let e3 = this.axis, i3 = e3.options.labels, o2 = t3.x, r2 = e3.chart.chartWidth, a2 = e3.chart.spacing, n2 = u11(e3.labelLeft, Math.min(e3.pos, a2[3])), l2 = u11(e3.labelRight, Math.max(e3.isRadial ? 0 : e3.pos + e3.len, r2 - a2[1])), h2 = this.label, d2 = this.rotation, c2 = {
18925              left: 0,
18926              center: 0.5,
18927              right: 1
18928            }[e3.labelAlign || h2.attr("align")], p2 = h2.getBBox().width, g = e3.getSlotWidth(this), f = {}, m = g, x = 1, y, b, v;
18929            d2 || "justify" !== i3.overflow ? d2 < 0 && o2 - c2 * p2 < n2 ? v = Math.round(o2 / Math.cos(d2 * s) - n2) : d2 > 0 && o2 + c2 * p2 > l2 && (v = Math.round((r2 - o2) / Math.cos(d2 * s))) : (y = o2 - c2 * p2, b = o2 + (1 - c2) * p2, y < n2 ? m = t3.x + m * (1 - c2) - n2 : b > l2 && (m = l2 - t3.x + m * c2, x = -1), (m = Math.min(g, m)) < g && "center" === e3.labelAlign && (t3.x += x * (g - m - c2 * (g - Math.min(p2, m)))), (p2 > m || e3.autoRotation && (h2.styles || {}).width) && (v = m)), v && (this.shortenLabel ? this.shortenLabel() : (f.width = Math.floor(v) + "px", (i3.style || {}).textOverflow || (f.textOverflow = "ellipsis"), h2.css(f)));
18930          }
18931          moveLabel(t3, e3) {
18932            let i3 = this, s2 = i3.label, o2 = i3.axis, r2 = false, a2;
18933            s2 && s2.textStr === t3 ? (i3.movedLabel = s2, r2 = true, delete i3.label) : p(o2.ticks, function(e4) {
18934              r2 || e4.isNew || e4 === i3 || !e4.label || e4.label.textStr !== t3 || (i3.movedLabel = e4.label, r2 = true, e4.labelPos = i3.movedLabel.xy, delete e4.label);
18935            }), !r2 && (i3.labelPos || s2) && (a2 = i3.labelPos || s2.xy, i3.movedLabel = i3.createLabel(t3, e3, a2), i3.movedLabel && i3.movedLabel.attr({
18936              opacity: 0
18937            }));
18938          }
18939          render(t3, e3, i3) {
18940            let s2 = this.axis, o2 = s2.horiz, a2 = this.pos, n2 = u11(this.tickmarkOffset, s2.tickmarkOffset), l2 = this.getPosition(o2, a2, n2, e3), d2 = l2.x, c2 = l2.y, p2 = s2.pos, g = p2 + s2.len, f = o2 ? d2 : c2;
18941            !s2.chart.polar && this.isNew && (r(f) < p2 || f > g) && (i3 = 0);
18942            let m = u11(i3, this.label && this.label.newOpacity, 1);
18943            i3 = u11(i3, 1), this.isActive = true, this.renderGridLine(e3, i3), this.renderMark(l2, i3), this.renderLabel(l2, e3, m, t3), this.isNew = false, h(this, "afterRender");
18944          }
18945          renderGridLine(t3, e3) {
18946            let i3 = this.axis, s2 = i3.options, o2 = {}, r2 = this.pos, a2 = this.type, n2 = u11(this.tickmarkOffset, i3.tickmarkOffset), l2 = i3.chart.renderer, h2 = this.gridLine, d2, c2 = s2.gridLineWidth, p2 = s2.gridLineColor, g = s2.gridLineDashStyle;
18947            "minor" === this.type && (c2 = s2.minorGridLineWidth, p2 = s2.minorGridLineColor, g = s2.minorGridLineDashStyle), h2 || (i3.chart.styledMode || (o2.stroke = p2, o2["stroke-width"] = c2 || 0, o2.dashstyle = g), a2 || (o2.zIndex = 1), t3 && (e3 = 0), this.gridLine = h2 = l2.path().attr(o2).addClass("highcharts-" + (a2 ? a2 + "-" : "") + "grid-line").add(i3.gridGroup)), h2 && (d2 = i3.getPlotLinePath({
18948              value: r2 + n2,
18949              lineWidth: h2.strokeWidth(),
18950              force: "pass",
18951              old: t3,
18952              acrossPanes: false
18953            })) && h2[t3 || this.isNew ? "attr" : "animate"]({
18954              d: d2,
18955              opacity: e3
18956            });
18957          }
18958          renderMark(t3, e3) {
18959            let i3 = this.axis, s2 = i3.options, o2 = i3.chart.renderer, r2 = this.type, a2 = i3.tickSize(r2 ? r2 + "Tick" : "tick"), n2 = t3.x, l2 = t3.y, h2 = u11(s2["minor" !== r2 ? "tickWidth" : "minorTickWidth"], !r2 && i3.isXAxis ? 1 : 0), d2 = s2["minor" !== r2 ? "tickColor" : "minorTickColor"], c2 = this.mark, p2 = !c2;
18960            a2 && (i3.opposite && (a2[0] = -a2[0]), c2 || (this.mark = c2 = o2.path().addClass("highcharts-" + (r2 ? r2 + "-" : "") + "tick").add(i3.axisGroup), i3.chart.styledMode || c2.attr({
18961              stroke: d2,
18962              "stroke-width": h2
18963            })), c2[p2 ? "attr" : "animate"]({
18964              d: this.getMarkPath(n2, l2, a2[0], c2.strokeWidth(), i3.horiz, o2),
18965              opacity: e3
18966            }));
18967          }
18968          renderLabel(t3, e3, i3, s2) {
18969            let o2 = this.axis, r2 = o2.horiz, a2 = o2.options, n2 = this.label, l2 = a2.labels, h2 = l2.step, c2 = u11(this.tickmarkOffset, o2.tickmarkOffset), p2 = t3.x, g = t3.y, f = true;
18970            n2 && d(p2) && (n2.xy = t3 = this.getLabelPosition(p2, g, n2, r2, l2, c2, s2, h2), (!this.isFirst || this.isLast || a2.showFirstLabel) && (!this.isLast || this.isFirst || a2.showLastLabel) ? !r2 || l2.step || l2.rotation || e3 || 0 === i3 || this.handleOverflow(t3) : f = false, h2 && s2 % h2 && (f = false), f && d(t3.y) ? (t3.opacity = i3, n2[this.isNewLabel ? "attr" : "animate"](t3).show(true), this.isNewLabel = false) : (n2.hide(), this.isNewLabel = true));
18971          }
18972          replaceMovedLabel() {
18973            let t3 = this.label, e3 = this.axis;
18974            t3 && !this.isNew && (t3.animate({
18975              opacity: 0
18976            }, void 0, t3.destroy), delete this.label), e3.isDirty = true, this.label = this.movedLabel, delete this.movedLabel;
18977          }
18978        };
18979      }), i(e, "Core/Axis/Axis.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Axis/AxisDefaults.js"], e["Core/Color/Color.js"], e["Core/Defaults.js"], e["Core/Foundation.js"], e["Core/Globals.js"], e["Core/Axis/Tick.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o, r, a, n) {
18980        let {
18981          animObject: l
18982        } = t2, {
18983          xAxis: h,
18984          yAxis: d
18985        } = e2, {
18986          defaultOptions: c
18987        } = s, {
18988          registerEventOptions: p
18989        } = o, {
18990          deg2rad: u11
18991        } = r, {
18992          arrayMax: g,
18993          arrayMin: f,
18994          clamp: m,
18995          correctFloat: x,
18996          defined: y,
18997          destroyObjectProperties: b,
18998          erase: v,
18999          error: S2,
19000          extend: k,
19001          fireEvent: M,
19002          getClosestDistance: C,
19003          insertItem: A,
19004          isArray: w,
19005          isNumber: T2,
19006          isString: P,
19007          merge: O,
19008          normalizeTickInterval: L,
19009          objectEach: D2,
19010          pick: E,
19011          relativeLength: B,
19012          removeEvent: j,
19013          splat: R,
19014          syncTimeout: I
19015        } = n, z = (t3, e3) => L(e3, void 0, void 0, E(t3.options.allowDecimals, e3 < 0.5 || void 0 !== t3.tickAmount), !!t3.tickAmount);
19016        k(c, {
19017          xAxis: h,
19018          yAxis: O(h, d)
19019        });
19020        class G {
19021          constructor(t3, e3, i3) {
19022            this.init(t3, e3, i3);
19023          }
19024          init(t3, e3, i3 = this.coll) {
19025            let s2 = "xAxis" === i3, o2 = this.isZAxis || (t3.inverted ? !s2 : s2);
19026            this.chart = t3, this.horiz = o2, this.isXAxis = s2, this.coll = i3, M(this, "init", {
19027              userOptions: e3
19028            }), this.opposite = E(e3.opposite, this.opposite), this.side = E(e3.side, this.side, o2 ? this.opposite ? 0 : 2 : this.opposite ? 1 : 3), this.setOptions(e3);
19029            let r2 = this.options, a2 = r2.labels;
19030            this.type ?? (this.type = r2.type || "linear"), this.uniqueNames ?? (this.uniqueNames = r2.uniqueNames ?? true), M(this, "afterSetType"), this.userOptions = e3, this.minPixelPadding = 0, this.reversed = E(r2.reversed, this.reversed), this.visible = r2.visible, this.zoomEnabled = r2.zoomEnabled, this.hasNames = "category" === this.type || true === r2.categories, this.categories = w(r2.categories) && r2.categories || (this.hasNames ? [] : void 0), this.names || (this.names = [], this.names.keys = {}), this.plotLinesAndBandsGroups = {}, this.positiveValuesOnly = !!this.logarithmic, this.isLinked = y(r2.linkedTo), this.ticks = {}, this.labelEdge = [], this.minorTicks = {}, this.plotLinesAndBands = [], this.alternateBands = {}, this.len ?? (this.len = 0), this.minRange = this.userMinRange = r2.minRange || r2.maxZoom, this.range = r2.range, this.offset = r2.offset || 0, this.max = void 0, this.min = void 0;
19031            let n2 = E(r2.crosshair, R(t3.options.tooltip.crosshairs)[s2 ? 0 : 1]);
19032            this.crosshair = true === n2 ? {} : n2, -1 === t3.axes.indexOf(this) && (s2 ? t3.axes.splice(t3.xAxis.length, 0, this) : t3.axes.push(this), A(this, t3[this.coll])), t3.orderItems(this.coll), this.series = this.series || [], t3.inverted && !this.isZAxis && s2 && !y(this.reversed) && (this.reversed = true), this.labelRotation = T2(a2.rotation) ? a2.rotation : void 0, p(this, r2), M(this, "afterInit");
19033          }
19034          setOptions(t3) {
19035            let e3 = this.horiz ? {
19036              labels: {
19037                autoRotation: [-45],
19038                padding: 4
19039              },
19040              margin: 15
19041            } : {
19042              labels: {
19043                padding: 1
19044              },
19045              title: {
19046                rotation: 90 * this.side
19047              }
19048            };
19049            this.options = O(e3, c[this.coll], t3), M(this, "afterSetOptions", {
19050              userOptions: t3
19051            });
19052          }
19053          defaultLabelFormatter() {
19054            let t3 = this.axis, {
19055              numberFormatter: e3
19056            } = this.chart, i3 = T2(this.value) ? this.value : NaN, s2 = t3.chart.time, o2 = t3.categories, r2 = this.dateTimeLabelFormat, a2 = c.lang, n2 = a2.numericSymbols, l2 = a2.numericSymbolMagnitude || 1e3, h2 = t3.logarithmic ? Math.abs(i3) : t3.tickInterval, d2 = n2 && n2.length, p2, u12;
19057            if (o2) u12 = `${this.value}`;
19058            else if (r2) u12 = s2.dateFormat(r2, i3);
19059            else if (d2 && n2 && h2 >= 1e3) for (; d2-- && void 0 === u12; ) h2 >= (p2 = Math.pow(l2, d2 + 1)) && 10 * i3 % p2 == 0 && null !== n2[d2] && 0 !== i3 && (u12 = e3(i3 / p2, -1) + n2[d2]);
19060            return void 0 === u12 && (u12 = Math.abs(i3) >= 1e4 ? e3(i3, -1) : e3(i3, -1, void 0, "")), u12;
19061          }
19062          getSeriesExtremes() {
19063            let t3;
19064            let e3 = this;
19065            M(this, "getSeriesExtremes", null, function() {
19066              e3.hasVisibleSeries = false, e3.dataMin = e3.dataMax = e3.threshold = void 0, e3.softThreshold = !e3.isXAxis, e3.series.forEach((i3) => {
19067                if (i3.reserveSpace()) {
19068                  let s2 = i3.options, o2, r2 = s2.threshold, a2, n2;
19069                  if (e3.hasVisibleSeries = true, e3.positiveValuesOnly && 0 >= (r2 || 0) && (r2 = void 0), e3.isXAxis) (o2 = i3.xData) && o2.length && (o2 = e3.logarithmic ? o2.filter((t4) => t4 > 0) : o2, a2 = (t3 = i3.getXExtremes(o2)).min, n2 = t3.max, T2(a2) || a2 instanceof Date || (o2 = o2.filter(T2), a2 = (t3 = i3.getXExtremes(o2)).min, n2 = t3.max), o2.length && (e3.dataMin = Math.min(E(e3.dataMin, a2), a2), e3.dataMax = Math.max(E(e3.dataMax, n2), n2)));
19070                  else {
19071                    let t4 = i3.applyExtremes();
19072                    T2(t4.dataMin) && (a2 = t4.dataMin, e3.dataMin = Math.min(E(e3.dataMin, a2), a2)), T2(t4.dataMax) && (n2 = t4.dataMax, e3.dataMax = Math.max(E(e3.dataMax, n2), n2)), y(r2) && (e3.threshold = r2), (!s2.softThreshold || e3.positiveValuesOnly) && (e3.softThreshold = false);
19073                  }
19074                }
19075              });
19076            }), M(this, "afterGetSeriesExtremes");
19077          }
19078          translate(t3, e3, i3, s2, o2, r2) {
19079            let a2 = this.linkedParent || this, n2 = s2 && a2.old ? a2.old.min : a2.min;
19080            if (!T2(n2)) return NaN;
19081            let l2 = a2.minPixelPadding, h2 = (a2.isOrdinal || a2.brokenAxis?.hasBreaks || a2.logarithmic && o2) && a2.lin2val, d2 = 1, c2 = 0, p2 = s2 && a2.old ? a2.old.transA : a2.transA, u12 = 0;
19082            return p2 || (p2 = a2.transA), i3 && (d2 *= -1, c2 = a2.len), a2.reversed && (d2 *= -1, c2 -= d2 * (a2.sector || a2.len)), e3 ? (u12 = (t3 = t3 * d2 + c2 - l2) / p2 + n2, h2 && (u12 = a2.lin2val(u12))) : (h2 && (t3 = a2.val2lin(t3)), u12 = d2 * (t3 - n2) * p2 + c2 + d2 * l2 + (T2(r2) ? p2 * r2 : 0), a2.isRadial || (u12 = x(u12))), u12;
19083          }
19084          toPixels(t3, e3) {
19085            return this.translate(t3, false, !this.horiz, void 0, true) + (e3 ? 0 : this.pos);
19086          }
19087          toValue(t3, e3) {
19088            return this.translate(t3 - (e3 ? 0 : this.pos), true, !this.horiz, void 0, true);
19089          }
19090          getPlotLinePath(t3) {
19091            let e3 = this, i3 = e3.chart, s2 = e3.left, o2 = e3.top, r2 = t3.old, a2 = t3.value, n2 = t3.lineWidth, l2 = r2 && i3.oldChartHeight || i3.chartHeight, h2 = r2 && i3.oldChartWidth || i3.chartWidth, d2 = e3.transB, c2 = t3.translatedValue, p2 = t3.force, u12, g2, f2, x2, y2;
19092            function b2(t4, e4, i4) {
19093              return "pass" !== p2 && (t4 < e4 || t4 > i4) && (p2 ? t4 = m(t4, e4, i4) : y2 = true), t4;
19094            }
19095            let v2 = {
19096              value: a2,
19097              lineWidth: n2,
19098              old: r2,
19099              force: p2,
19100              acrossPanes: t3.acrossPanes,
19101              translatedValue: c2
19102            };
19103            return M(this, "getPlotLinePath", v2, function(t4) {
19104              u12 = f2 = (c2 = m(c2 = E(c2, e3.translate(a2, void 0, void 0, r2)), -1e9, 1e9)) + d2, g2 = x2 = l2 - c2 - d2, T2(c2) ? e3.horiz ? (g2 = o2, x2 = l2 - e3.bottom + (e3.options.isInternal ? 0 : i3.scrollablePixelsY || 0), u12 = f2 = b2(u12, s2, s2 + e3.width)) : (u12 = s2, f2 = h2 - e3.right + (i3.scrollablePixelsX || 0), g2 = x2 = b2(g2, o2, o2 + e3.height)) : (y2 = true, p2 = false), t4.path = y2 && !p2 ? void 0 : i3.renderer.crispLine([["M", u12, g2], ["L", f2, x2]], n2 || 1);
19105            }), v2.path;
19106          }
19107          getLinearTickPositions(t3, e3, i3) {
19108            let s2, o2, r2;
19109            let a2 = x(Math.floor(e3 / t3) * t3), n2 = x(Math.ceil(i3 / t3) * t3), l2 = [];
19110            if (x(a2 + t3) === a2 && (r2 = 20), this.single) return [e3];
19111            for (s2 = a2; s2 <= n2 && (l2.push(s2), (s2 = x(s2 + t3, r2)) !== o2); ) o2 = s2;
19112            return l2;
19113          }
19114          getMinorTickInterval() {
19115            let {
19116              minorTicks: t3,
19117              minorTickInterval: e3
19118            } = this.options;
19119            return true === t3 ? E(e3, "auto") : false !== t3 ? e3 : void 0;
19120          }
19121          getMinorTickPositions() {
19122            let t3 = this.options, e3 = this.tickPositions, i3 = this.minorTickInterval, s2 = this.pointRangePadding || 0, o2 = (this.min || 0) - s2, r2 = (this.max || 0) + s2, a2 = r2 - o2, n2 = [], l2;
19123            if (a2 && a2 / i3 < this.len / 3) {
19124              let s3 = this.logarithmic;
19125              if (s3) this.paddedTicks.forEach(function(t4, e4, o3) {
19126                e4 && n2.push.apply(n2, s3.getLogTickPositions(i3, o3[e4 - 1], o3[e4], true));
19127              });
19128              else if (this.dateTime && "auto" === this.getMinorTickInterval()) n2 = n2.concat(this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(i3), o2, r2, t3.startOfWeek));
19129              else for (l2 = o2 + (e3[0] - o2) % i3; l2 <= r2 && l2 !== n2[0]; l2 += i3) n2.push(l2);
19130            }
19131            return 0 !== n2.length && this.trimTicks(n2), n2;
19132          }
19133          adjustForMinRange() {
19134            let t3 = this.options, e3 = this.logarithmic, {
19135              max: i3,
19136              min: s2,
19137              minRange: o2
19138            } = this, r2, a2, n2, l2;
19139            this.isXAxis && void 0 === o2 && !e3 && (o2 = y(t3.min) || y(t3.max) || y(t3.floor) || y(t3.ceiling) ? null : Math.min(5 * (C(this.series.map((t4) => (t4.xIncrement ? t4.xData?.slice(0, 2) : t4.xData) || [])) || 0), this.dataMax - this.dataMin)), T2(i3) && T2(s2) && T2(o2) && i3 - s2 < o2 && (a2 = this.dataMax - this.dataMin >= o2, r2 = (o2 - i3 + s2) / 2, n2 = [s2 - r2, E(t3.min, s2 - r2)], a2 && (n2[2] = e3 ? e3.log2lin(this.dataMin) : this.dataMin), l2 = [(s2 = g(n2)) + o2, E(t3.max, s2 + o2)], a2 && (l2[2] = e3 ? e3.log2lin(this.dataMax) : this.dataMax), (i3 = f(l2)) - s2 < o2 && (n2[0] = i3 - o2, n2[1] = E(t3.min, i3 - o2), s2 = g(n2))), this.minRange = o2, this.min = s2, this.max = i3;
19140          }
19141          getClosest() {
19142            let t3, e3;
19143            if (this.categories) e3 = 1;
19144            else {
19145              let i3 = [];
19146              this.series.forEach(function(t4) {
19147                let s2 = t4.closestPointRange;
19148                t4.xData?.length === 1 ? i3.push(t4.xData[0]) : !t4.noSharedTooltip && y(s2) && t4.reserveSpace() && (e3 = y(e3) ? Math.min(e3, s2) : s2);
19149              }), i3.length && (i3.sort((t4, e4) => t4 - e4), t3 = C([i3]));
19150            }
19151            return t3 && e3 ? Math.min(t3, e3) : t3 || e3;
19152          }
19153          nameToX(t3) {
19154            let e3 = w(this.options.categories), i3 = e3 ? this.categories : this.names, s2 = t3.options.x, o2;
19155            return t3.series.requireSorting = false, y(s2) || (s2 = this.uniqueNames && i3 ? e3 ? i3.indexOf(t3.name) : E(i3.keys[t3.name], -1) : t3.series.autoIncrement()), -1 === s2 ? !e3 && i3 && (o2 = i3.length) : o2 = s2, void 0 !== o2 ? (this.names[o2] = t3.name, this.names.keys[t3.name] = o2) : t3.x && (o2 = t3.x), o2;
19156          }
19157          updateNames() {
19158            let t3 = this, e3 = this.names;
19159            e3.length > 0 && (Object.keys(e3.keys).forEach(function(t4) {
19160              delete e3.keys[t4];
19161            }), e3.length = 0, this.minRange = this.userMinRange, (this.series || []).forEach((e4) => {
19162              e4.xIncrement = null, (!e4.points || e4.isDirtyData) && (t3.max = Math.max(t3.max, e4.xData.length - 1), e4.processData(), e4.generatePoints()), e4.data.forEach(function(i3, s2) {
19163                let o2;
19164                i3?.options && void 0 !== i3.name && void 0 !== (o2 = t3.nameToX(i3)) && o2 !== i3.x && (i3.x = o2, e4.xData[s2] = o2);
19165              });
19166            }));
19167          }
19168          setAxisTranslation() {
19169            let t3 = this, e3 = t3.max - t3.min, i3 = t3.linkedParent, s2 = !!t3.categories, o2 = t3.isXAxis, r2 = t3.axisPointRange || 0, a2, n2 = 0, l2 = 0, h2, d2 = t3.transA;
19170            (o2 || s2 || r2) && (a2 = t3.getClosest(), i3 ? (n2 = i3.minPointOffset, l2 = i3.pointRangePadding) : t3.series.forEach(function(e4) {
19171              let i4 = s2 ? 1 : o2 ? E(e4.options.pointRange, a2, 0) : t3.axisPointRange || 0, h3 = e4.options.pointPlacement;
19172              if (r2 = Math.max(r2, i4), !t3.single || s2) {
19173                let t4 = e4.is("xrange") ? !o2 : o2;
19174                n2 = Math.max(n2, t4 && P(h3) ? 0 : i4 / 2), l2 = Math.max(l2, t4 && "on" === h3 ? 0 : i4);
19175              }
19176            }), h2 = t3.ordinal && t3.ordinal.slope && a2 ? t3.ordinal.slope / a2 : 1, t3.minPointOffset = n2 *= h2, t3.pointRangePadding = l2 *= h2, t3.pointRange = Math.min(r2, t3.single && s2 ? 1 : e3), o2 && a2 && (t3.closestPointRange = a2)), t3.translationSlope = t3.transA = d2 = t3.staticScale || t3.len / (e3 + l2 || 1), t3.transB = t3.horiz ? t3.left : t3.bottom, t3.minPixelPadding = d2 * n2, M(this, "afterSetAxisTranslation");
19177          }
19178          minFromRange() {
19179            let {
19180              max: t3,
19181              min: e3
19182            } = this;
19183            return T2(t3) && T2(e3) && t3 - e3 || void 0;
19184          }
19185          setTickInterval(t3) {
19186            let {
19187              categories: e3,
19188              chart: i3,
19189              dataMax: s2,
19190              dataMin: o2,
19191              dateTime: r2,
19192              isXAxis: a2,
19193              logarithmic: n2,
19194              options: l2,
19195              softThreshold: h2
19196            } = this, d2 = T2(this.threshold) ? this.threshold : void 0, c2 = this.minRange || 0, {
19197              ceiling: p2,
19198              floor: u12,
19199              linkedTo: g2,
19200              softMax: f2,
19201              softMin: m2
19202            } = l2, b2 = T2(g2) && i3[this.coll]?.[g2], v2 = l2.tickPixelInterval, k2 = l2.maxPadding, C2 = l2.minPadding, A2 = 0, w2, P2 = T2(l2.tickInterval) && l2.tickInterval >= 0 ? l2.tickInterval : void 0, O2, L2, D3, B2;
19203            if (r2 || e3 || b2 || this.getTickAmount(), D3 = E(this.userMin, l2.min), B2 = E(this.userMax, l2.max), b2 ? (this.linkedParent = b2, w2 = b2.getExtremes(), this.min = E(w2.min, w2.dataMin), this.max = E(w2.max, w2.dataMax), this.type !== b2.type && S2(11, true, i3)) : (h2 && y(d2) && T2(s2) && T2(o2) && (o2 >= d2 ? (O2 = d2, C2 = 0) : s2 <= d2 && (L2 = d2, k2 = 0)), this.min = E(D3, O2, o2), this.max = E(B2, L2, s2)), T2(this.max) && T2(this.min) && (n2 && (this.positiveValuesOnly && !t3 && 0 >= Math.min(this.min, E(o2, this.min)) && S2(10, true, i3), this.min = x(n2.log2lin(this.min), 16), this.max = x(n2.log2lin(this.max), 16)), this.range && T2(o2) && (this.userMin = this.min = D3 = Math.max(o2, this.minFromRange() || 0), this.userMax = B2 = this.max, this.range = void 0)), M(this, "foundExtremes"), this.adjustForMinRange(), T2(this.min) && T2(this.max)) {
19204              if (!T2(this.userMin) && T2(m2) && m2 < this.min && (this.min = D3 = m2), !T2(this.userMax) && T2(f2) && f2 > this.max && (this.max = B2 = f2), e3 || this.axisPointRange || this.stacking?.usePercentage || b2 || !(A2 = this.max - this.min) || (!y(D3) && C2 && (this.min -= A2 * C2), y(B2) || !k2 || (this.max += A2 * k2)), !T2(this.userMin) && T2(u12) && (this.min = Math.max(this.min, u12)), !T2(this.userMax) && T2(p2) && (this.max = Math.min(this.max, p2)), h2 && T2(o2) && T2(s2)) {
19205                let t4 = d2 || 0;
19206                !y(D3) && this.min < t4 && o2 >= t4 ? this.min = l2.minRange ? Math.min(t4, this.max - c2) : t4 : !y(B2) && this.max > t4 && s2 <= t4 && (this.max = l2.minRange ? Math.max(t4, this.min + c2) : t4);
19207              }
19208              !i3.polar && this.min > this.max && (y(l2.min) ? this.max = this.min : y(l2.max) && (this.min = this.max)), A2 = this.max - this.min;
19209            }
19210            if (this.min !== this.max && T2(this.min) && T2(this.max) ? b2 && !P2 && v2 === b2.options.tickPixelInterval ? this.tickInterval = P2 = b2.tickInterval : this.tickInterval = E(P2, this.tickAmount ? A2 / Math.max(this.tickAmount - 1, 1) : void 0, e3 ? 1 : A2 * v2 / Math.max(this.len, v2)) : this.tickInterval = 1, a2 && !t3) {
19211              let t4 = this.min !== this.old?.min || this.max !== this.old?.max;
19212              this.series.forEach(function(e4) {
19213                e4.forceCrop = e4.forceCropping?.(), e4.processData(t4);
19214              }), M(this, "postProcessData", {
19215                hasExtremesChanged: t4
19216              });
19217            }
19218            this.setAxisTranslation(), M(this, "initialAxisTranslation"), this.pointRange && !P2 && (this.tickInterval = Math.max(this.pointRange, this.tickInterval));
19219            let j2 = E(l2.minTickInterval, r2 && !this.series.some((t4) => t4.noSharedTooltip) ? this.closestPointRange : 0);
19220            !P2 && this.tickInterval < j2 && (this.tickInterval = j2), r2 || n2 || P2 || (this.tickInterval = z(this, this.tickInterval)), this.tickAmount || (this.tickInterval = this.unsquish()), this.setTickPositions();
19221          }
19222          setTickPositions() {
19223            let t3 = this.options, e3 = t3.tickPositions, i3 = t3.tickPositioner, s2 = this.getMinorTickInterval(), o2 = !this.isPanning, r2 = o2 && t3.startOnTick, a2 = o2 && t3.endOnTick, n2 = [], l2;
19224            if (this.tickmarkOffset = this.categories && "between" === t3.tickmarkPlacement && 1 === this.tickInterval ? 0.5 : 0, this.single = this.min === this.max && y(this.min) && !this.tickAmount && (this.min % 1 == 0 || false !== t3.allowDecimals), e3) n2 = e3.slice();
19225            else if (T2(this.min) && T2(this.max)) {
19226              if (!this.ordinal?.positions && (this.max - this.min) / this.tickInterval > Math.max(2 * this.len, 200)) n2 = [this.min, this.max], S2(19, false, this.chart);
19227              else if (this.dateTime) n2 = this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(this.tickInterval, t3.units), this.min, this.max, t3.startOfWeek, this.ordinal?.positions, this.closestPointRange, true);
19228              else if (this.logarithmic) n2 = this.logarithmic.getLogTickPositions(this.tickInterval, this.min, this.max);
19229              else {
19230                let t4 = this.tickInterval, e4 = t4;
19231                for (; e4 <= 2 * t4; ) if (n2 = this.getLinearTickPositions(this.tickInterval, this.min, this.max), this.tickAmount && n2.length > this.tickAmount) this.tickInterval = z(this, e4 *= 1.1);
19232                else break;
19233              }
19234              n2.length > this.len && (n2 = [n2[0], n2[n2.length - 1]])[0] === n2[1] && (n2.length = 1), i3 && (this.tickPositions = n2, (l2 = i3.apply(this, [this.min, this.max])) && (n2 = l2));
19235            }
19236            this.tickPositions = n2, this.minorTickInterval = "auto" === s2 && this.tickInterval ? this.tickInterval / t3.minorTicksPerMajor : s2, this.paddedTicks = n2.slice(0), this.trimTicks(n2, r2, a2), !this.isLinked && T2(this.min) && T2(this.max) && (this.single && n2.length < 2 && !this.categories && !this.series.some((t4) => t4.is("heatmap") && "between" === t4.options.pointPlacement) && (this.min -= 0.5, this.max += 0.5), e3 || l2 || this.adjustTickAmount()), M(this, "afterSetTickPositions");
19237          }
19238          trimTicks(t3, e3, i3) {
19239            let s2 = t3[0], o2 = t3[t3.length - 1], r2 = !this.isOrdinal && this.minPointOffset || 0;
19240            if (M(this, "trimTicks"), !this.isLinked) {
19241              if (e3 && s2 !== -1 / 0) this.min = s2;
19242              else for (; this.min - r2 > t3[0]; ) t3.shift();
19243              if (i3) this.max = o2;
19244              else for (; this.max + r2 < t3[t3.length - 1]; ) t3.pop();
19245              0 === t3.length && y(s2) && !this.options.tickPositions && t3.push((o2 + s2) / 2);
19246            }
19247          }
19248          alignToOthers() {
19249            let t3;
19250            let e3 = this, i3 = e3.chart, s2 = [this], o2 = e3.options, r2 = i3.options.chart, a2 = "yAxis" === this.coll && r2.alignThresholds, n2 = [];
19251            if (e3.thresholdAlignment = void 0, (false !== r2.alignTicks && o2.alignTicks || a2) && false !== o2.startOnTick && false !== o2.endOnTick && !e3.logarithmic) {
19252              let o3 = (t4) => {
19253                let {
19254                  horiz: e4,
19255                  options: i4
19256                } = t4;
19257                return [e4 ? i4.left : i4.top, i4.width, i4.height, i4.pane].join(",");
19258              }, r3 = o3(this);
19259              i3[this.coll].forEach(function(i4) {
19260                let {
19261                  series: a3
19262                } = i4;
19263                a3.length && a3.some((t4) => t4.visible) && i4 !== e3 && o3(i4) === r3 && (t3 = true, s2.push(i4));
19264              });
19265            }
19266            if (t3 && a2) {
19267              s2.forEach((t5) => {
19268                let i4 = t5.getThresholdAlignment(e3);
19269                T2(i4) && n2.push(i4);
19270              });
19271              let t4 = n2.length > 1 ? n2.reduce((t5, e4) => t5 += e4, 0) / n2.length : void 0;
19272              s2.forEach((e4) => {
19273                e4.thresholdAlignment = t4;
19274              });
19275            }
19276            return t3;
19277          }
19278          getThresholdAlignment(t3) {
19279            if ((!T2(this.dataMin) || this !== t3 && this.series.some((t4) => t4.isDirty || t4.isDirtyData)) && this.getSeriesExtremes(), T2(this.threshold)) {
19280              let t4 = m((this.threshold - (this.dataMin || 0)) / ((this.dataMax || 0) - (this.dataMin || 0)), 0, 1);
19281              return this.options.reversed && (t4 = 1 - t4), t4;
19282            }
19283          }
19284          getTickAmount() {
19285            let t3 = this.options, e3 = t3.tickPixelInterval, i3 = t3.tickAmount;
19286            y(t3.tickInterval) || i3 || !(this.len < e3) || this.isRadial || this.logarithmic || !t3.startOnTick || !t3.endOnTick || (i3 = 2), !i3 && this.alignToOthers() && (i3 = Math.ceil(this.len / e3) + 1), i3 < 4 && (this.finalTickAmt = i3, i3 = 5), this.tickAmount = i3;
19287          }
19288          adjustTickAmount() {
19289            let t3 = this, {
19290              finalTickAmt: e3,
19291              max: i3,
19292              min: s2,
19293              options: o2,
19294              tickPositions: r2,
19295              tickAmount: a2,
19296              thresholdAlignment: n2
19297            } = t3, l2 = r2?.length, h2 = E(t3.threshold, t3.softThreshold ? 0 : null), d2, c2, p2 = t3.tickInterval, u12, g2 = () => r2.push(x(r2[r2.length - 1] + p2)), f2 = () => r2.unshift(x(r2[0] - p2));
19298            if (T2(n2) && (u12 = n2 < 0.5 ? Math.ceil(n2 * (a2 - 1)) : Math.floor(n2 * (a2 - 1)), o2.reversed && (u12 = a2 - 1 - u12)), t3.hasData() && T2(s2) && T2(i3)) {
19299              let n3 = () => {
19300                t3.transA *= (l2 - 1) / (a2 - 1), t3.min = o2.startOnTick ? r2[0] : Math.min(s2, r2[0]), t3.max = o2.endOnTick ? r2[r2.length - 1] : Math.max(i3, r2[r2.length - 1]);
19301              };
19302              if (T2(u12) && T2(t3.threshold)) {
19303                for (; r2[u12] !== h2 || r2.length !== a2 || r2[0] > s2 || r2[r2.length - 1] < i3; ) {
19304                  for (r2.length = 0, r2.push(t3.threshold); r2.length < a2; ) void 0 === r2[u12] || r2[u12] > t3.threshold ? f2() : g2();
19305                  if (p2 > 8 * t3.tickInterval) break;
19306                  p2 *= 2;
19307                }
19308                n3();
19309              } else if (l2 < a2) {
19310                for (; r2.length < a2; ) r2.length % 2 || s2 === h2 ? g2() : f2();
19311                n3();
19312              }
19313              if (y(e3)) {
19314                for (c2 = d2 = r2.length; c2--; ) (3 === e3 && c2 % 2 == 1 || e3 <= 2 && c2 > 0 && c2 < d2 - 1) && r2.splice(c2, 1);
19315                t3.finalTickAmt = void 0;
19316              }
19317            }
19318          }
19319          setScale() {
19320            let {
19321              coll: t3,
19322              stacking: e3
19323            } = this, i3 = false, s2 = false;
19324            this.series.forEach((t4) => {
19325              i3 = i3 || t4.isDirtyData || t4.isDirty, s2 = s2 || t4.xAxis && t4.xAxis.isDirty || false;
19326            }), this.setAxisSize();
19327            let o2 = this.len !== (this.old && this.old.len);
19328            o2 || i3 || s2 || this.isLinked || this.forceRedraw || this.userMin !== (this.old && this.old.userMin) || this.userMax !== (this.old && this.old.userMax) || this.alignToOthers() ? (e3 && "yAxis" === t3 && e3.buildStacks(), this.forceRedraw = false, this.userMinRange || (this.minRange = void 0), this.getSeriesExtremes(), this.setTickInterval(), e3 && "xAxis" === t3 && e3.buildStacks(), this.isDirty || (this.isDirty = o2 || this.min !== this.old?.min || this.max !== this.old?.max)) : e3 && e3.cleanStacks(), i3 && delete this.allExtremes, M(this, "afterSetScale");
19329          }
19330          setExtremes(t3, e3, i3 = true, s2, o2) {
19331            this.series.forEach((t4) => {
19332              delete t4.kdTree;
19333            }), M(this, "setExtremes", o2 = k(o2, {
19334              min: t3,
19335              max: e3
19336            }), (t4) => {
19337              this.userMin = t4.min, this.userMax = t4.max, this.eventArgs = t4, i3 && this.chart.redraw(s2);
19338            });
19339          }
19340          setAxisSize() {
19341            let t3 = this.chart, e3 = this.options, i3 = e3.offsets || [0, 0, 0, 0], s2 = this.horiz, o2 = this.width = Math.round(B(E(e3.width, t3.plotWidth - i3[3] + i3[1]), t3.plotWidth)), r2 = this.height = Math.round(B(E(e3.height, t3.plotHeight - i3[0] + i3[2]), t3.plotHeight)), a2 = this.top = Math.round(B(E(e3.top, t3.plotTop + i3[0]), t3.plotHeight, t3.plotTop)), n2 = this.left = Math.round(B(E(e3.left, t3.plotLeft + i3[3]), t3.plotWidth, t3.plotLeft));
19342            this.bottom = t3.chartHeight - r2 - a2, this.right = t3.chartWidth - o2 - n2, this.len = Math.max(s2 ? o2 : r2, 0), this.pos = s2 ? n2 : a2;
19343          }
19344          getExtremes() {
19345            let t3 = this.logarithmic;
19346            return {
19347              min: t3 ? x(t3.lin2log(this.min)) : this.min,
19348              max: t3 ? x(t3.lin2log(this.max)) : this.max,
19349              dataMin: this.dataMin,
19350              dataMax: this.dataMax,
19351              userMin: this.userMin,
19352              userMax: this.userMax
19353            };
19354          }
19355          getThreshold(t3) {
19356            let e3 = this.logarithmic, i3 = e3 ? e3.lin2log(this.min) : this.min, s2 = e3 ? e3.lin2log(this.max) : this.max;
19357            return null === t3 || t3 === -1 / 0 ? t3 = i3 : t3 === 1 / 0 ? t3 = s2 : i3 > t3 ? t3 = i3 : s2 < t3 && (t3 = s2), this.translate(t3, 0, 1, 0, 1);
19358          }
19359          autoLabelAlign(t3) {
19360            let e3 = (E(t3, 0) - 90 * this.side + 720) % 360, i3 = {
19361              align: "center"
19362            };
19363            return M(this, "autoLabelAlign", i3, function(t4) {
19364              e3 > 15 && e3 < 165 ? t4.align = "right" : e3 > 195 && e3 < 345 && (t4.align = "left");
19365            }), i3.align;
19366          }
19367          tickSize(t3) {
19368            let e3 = this.options, i3 = E(e3["tick" === t3 ? "tickWidth" : "minorTickWidth"], "tick" === t3 && this.isXAxis && !this.categories ? 1 : 0), s2 = e3["tick" === t3 ? "tickLength" : "minorTickLength"], o2;
19369            i3 && s2 && ("inside" === e3[t3 + "Position"] && (s2 = -s2), o2 = [s2, i3]);
19370            let r2 = {
19371              tickSize: o2
19372            };
19373            return M(this, "afterTickSize", r2), r2.tickSize;
19374          }
19375          labelMetrics() {
19376            let t3 = this.chart.renderer, e3 = this.ticks, i3 = e3[Object.keys(e3)[0]] || {};
19377            return this.chart.renderer.fontMetrics(i3.label || i3.movedLabel || t3.box);
19378          }
19379          unsquish() {
19380            let t3 = this.options.labels, e3 = t3.padding || 0, i3 = this.horiz, s2 = this.tickInterval, o2 = this.len / (((this.categories ? 1 : 0) + this.max - this.min) / s2), r2 = t3.rotation, a2 = x(0.8 * this.labelMetrics().h), n2 = Math.max(this.max - this.min, 0), l2 = function(t4) {
19381              let i4 = (t4 + 2 * e3) / (o2 || 1);
19382              return (i4 = i4 > 1 ? Math.ceil(i4) : 1) * s2 > n2 && t4 !== 1 / 0 && o2 !== 1 / 0 && n2 && (i4 = Math.ceil(n2 / s2)), x(i4 * s2);
19383            }, h2 = s2, d2, c2 = Number.MAX_VALUE, p2;
19384            if (i3) {
19385              if (!t3.staggerLines && (T2(r2) ? p2 = [r2] : o2 < t3.autoRotationLimit && (p2 = t3.autoRotation)), p2) {
19386                let t4, e4;
19387                for (let i4 of p2) (i4 === r2 || i4 && i4 >= -90 && i4 <= 90) && (e4 = (t4 = l2(Math.abs(a2 / Math.sin(u11 * i4)))) + Math.abs(i4 / 360)) < c2 && (c2 = e4, d2 = i4, h2 = t4);
19388              }
19389            } else h2 = l2(0.75 * a2);
19390            return this.autoRotation = p2, this.labelRotation = E(d2, T2(r2) ? r2 : 0), t3.step ? s2 : h2;
19391          }
19392          getSlotWidth(t3) {
19393            let e3 = this.chart, i3 = this.horiz, s2 = this.options.labels, o2 = Math.max(this.tickPositions.length - (this.categories ? 0 : 1), 1), r2 = e3.margin[3];
19394            if (t3 && T2(t3.slotWidth)) return t3.slotWidth;
19395            if (i3 && s2.step < 2) return s2.rotation ? 0 : (this.staggerLines || 1) * this.len / o2;
19396            if (!i3) {
19397              let t4 = s2.style.width;
19398              if (void 0 !== t4) return parseInt(String(t4), 10);
19399              if (r2) return r2 - e3.spacing[3];
19400            }
19401            return 0.33 * e3.chartWidth;
19402          }
19403          renderUnsquish() {
19404            let t3 = this.chart, e3 = t3.renderer, i3 = this.tickPositions, s2 = this.ticks, o2 = this.options.labels, r2 = o2.style, a2 = this.horiz, n2 = this.getSlotWidth(), l2 = Math.max(1, Math.round(n2 - (a2 ? 2 * (o2.padding || 0) : o2.distance || 0))), h2 = {}, d2 = this.labelMetrics(), c2 = r2.textOverflow, p2, u12, g2 = 0, f2, m2;
19405            if (P(o2.rotation) || (h2.rotation = o2.rotation || 0), i3.forEach(function(t4) {
19406              let e4 = s2[t4];
19407              e4.movedLabel && e4.replaceMovedLabel(), e4 && e4.label && e4.label.textPxLength > g2 && (g2 = e4.label.textPxLength);
19408            }), this.maxLabelLength = g2, this.autoRotation) g2 > l2 && g2 > d2.h ? h2.rotation = this.labelRotation : this.labelRotation = 0;
19409            else if (n2 && (p2 = l2, !c2)) for (u12 = "clip", m2 = i3.length; !a2 && m2--; ) (f2 = s2[i3[m2]].label) && ("ellipsis" === f2.styles.textOverflow ? f2.css({
19410              textOverflow: "clip"
19411            }) : f2.textPxLength > n2 && f2.css({
19412              width: n2 + "px"
19413            }), f2.getBBox().height > this.len / i3.length - (d2.h - d2.f) && (f2.specificTextOverflow = "ellipsis"));
19414            h2.rotation && (p2 = g2 > 0.5 * t3.chartHeight ? 0.33 * t3.chartHeight : g2, c2 || (u12 = "ellipsis")), this.labelAlign = o2.align || this.autoLabelAlign(this.labelRotation), this.labelAlign && (h2.align = this.labelAlign), i3.forEach(function(t4) {
19415              let e4 = s2[t4], i4 = e4 && e4.label, o3 = r2.width, a3 = {};
19416              i4 && (i4.attr(h2), e4.shortenLabel ? e4.shortenLabel() : p2 && !o3 && "nowrap" !== r2.whiteSpace && (p2 < i4.textPxLength || "SPAN" === i4.element.tagName) ? (a3.width = p2 + "px", c2 || (a3.textOverflow = i4.specificTextOverflow || u12), i4.css(a3)) : !i4.styles.width || a3.width || o3 || i4.css({
19417                width: null
19418              }), delete i4.specificTextOverflow, e4.rotation = h2.rotation);
19419            }, this), this.tickRotCorr = e3.rotCorr(d2.b, this.labelRotation || 0, 0 !== this.side);
19420          }
19421          hasData() {
19422            return this.series.some(function(t3) {
19423              return t3.hasData();
19424            }) || this.options.showEmpty && y(this.min) && y(this.max);
19425          }
19426          addTitle(t3) {
19427            let e3;
19428            let i3 = this.chart.renderer, s2 = this.horiz, o2 = this.opposite, r2 = this.options.title, a2 = this.chart.styledMode;
19429            this.axisTitle || ((e3 = r2.textAlign) || (e3 = (s2 ? {
19430              low: "left",
19431              middle: "center",
19432              high: "right"
19433            } : {
19434              low: o2 ? "right" : "left",
19435              middle: "center",
19436              high: o2 ? "left" : "right"
19437            })[r2.align]), this.axisTitle = i3.text(r2.text || "", 0, 0, r2.useHTML).attr({
19438              zIndex: 7,
19439              rotation: r2.rotation || 0,
19440              align: e3
19441            }).addClass("highcharts-axis-title"), a2 || this.axisTitle.css(O(r2.style)), this.axisTitle.add(this.axisGroup), this.axisTitle.isNew = true), a2 || r2.style.width || this.isRadial || this.axisTitle.css({
19442              width: this.len + "px"
19443            }), this.axisTitle[t3 ? "show" : "hide"](t3);
19444          }
19445          generateTick(t3) {
19446            let e3 = this.ticks;
19447            e3[t3] ? e3[t3].addLabel() : e3[t3] = new a(this, t3);
19448          }
19449          createGroups() {
19450            let {
19451              axisParent: t3,
19452              chart: e3,
19453              coll: i3,
19454              options: s2
19455            } = this, o2 = e3.renderer, r2 = (e4, r3, a2) => o2.g(e4).attr({
19456              zIndex: a2
19457            }).addClass(`highcharts-${i3.toLowerCase()}${r3} ` + (this.isRadial ? `highcharts-radial-axis${r3} ` : "") + (s2.className || "")).add(t3);
19458            this.axisGroup || (this.gridGroup = r2("grid", "-grid", s2.gridZIndex), this.axisGroup = r2("axis", "", s2.zIndex), this.labelGroup = r2("axis-labels", "-labels", s2.labels.zIndex));
19459          }
19460          getOffset() {
19461            let t3 = this, {
19462              chart: e3,
19463              horiz: i3,
19464              options: s2,
19465              side: o2,
19466              ticks: r2,
19467              tickPositions: a2,
19468              coll: n2
19469            } = t3, l2 = e3.inverted && !t3.isZAxis ? [1, 0, 3, 2][o2] : o2, h2 = t3.hasData(), d2 = s2.title, c2 = s2.labels, p2 = T2(s2.crossing), u12 = e3.axisOffset, g2 = e3.clipOffset, f2 = [-1, 1, 1, -1][o2], m2, x2 = 0, b2, v2 = 0, S3 = 0, k2, C2;
19470            if (t3.showAxis = m2 = h2 || s2.showEmpty, t3.staggerLines = t3.horiz && c2.staggerLines || void 0, t3.createGroups(), h2 || t3.isLinked ? (a2.forEach(function(e4) {
19471              t3.generateTick(e4);
19472            }), t3.renderUnsquish(), t3.reserveSpaceDefault = 0 === o2 || 2 === o2 || {
19473              1: "left",
19474              3: "right"
19475            }[o2] === t3.labelAlign, E(c2.reserveSpace, !p2 && null, "center" === t3.labelAlign || null, t3.reserveSpaceDefault) && a2.forEach(function(t4) {
19476              S3 = Math.max(r2[t4].getLabelSize(), S3);
19477            }), t3.staggerLines && (S3 *= t3.staggerLines), t3.labelOffset = S3 * (t3.opposite ? -1 : 1)) : D2(r2, function(t4, e4) {
19478              t4.destroy(), delete r2[e4];
19479            }), d2?.text && false !== d2.enabled && (t3.addTitle(m2), m2 && !p2 && false !== d2.reserveSpace && (t3.titleOffset = x2 = t3.axisTitle.getBBox()[i3 ? "height" : "width"], v2 = y(b2 = d2.offset) ? 0 : E(d2.margin, i3 ? 5 : 10))), t3.renderLine(), t3.offset = f2 * E(s2.offset, u12[o2] ? u12[o2] + (s2.margin || 0) : 0), t3.tickRotCorr = t3.tickRotCorr || {
19480              x: 0,
19481              y: 0
19482            }, C2 = 0 === o2 ? -t3.labelMetrics().h : 2 === o2 ? t3.tickRotCorr.y : 0, k2 = Math.abs(S3) + v2, S3 && (k2 -= C2, k2 += f2 * (i3 ? E(c2.y, t3.tickRotCorr.y + f2 * c2.distance) : E(c2.x, f2 * c2.distance))), t3.axisTitleMargin = E(b2, k2), t3.getMaxLabelDimensions && (t3.maxLabelDimensions = t3.getMaxLabelDimensions(r2, a2)), "colorAxis" !== n2 && g2) {
19483              let e4 = this.tickSize("tick");
19484              u12[o2] = Math.max(u12[o2], (t3.axisTitleMargin || 0) + x2 + f2 * t3.offset, k2, a2 && a2.length && e4 ? e4[0] + f2 * t3.offset : 0);
19485              let i4 = !t3.axisLine || s2.offset ? 0 : t3.axisLine.strokeWidth() / 2;
19486              g2[l2] = Math.max(g2[l2], i4);
19487            }
19488            M(this, "afterGetOffset");
19489          }
19490          getLinePath(t3) {
19491            let e3 = this.chart, i3 = this.opposite, s2 = this.offset, o2 = this.horiz, r2 = this.left + (i3 ? this.width : 0) + s2, a2 = e3.chartHeight - this.bottom - (i3 ? this.height : 0) + s2;
19492            return i3 && (t3 *= -1), e3.renderer.crispLine([["M", o2 ? this.left : r2, o2 ? a2 : this.top], ["L", o2 ? e3.chartWidth - this.right : r2, o2 ? a2 : e3.chartHeight - this.bottom]], t3);
19493          }
19494          renderLine() {
19495            this.axisLine || (this.axisLine = this.chart.renderer.path().addClass("highcharts-axis-line").add(this.axisGroup), this.chart.styledMode || this.axisLine.attr({
19496              stroke: this.options.lineColor,
19497              "stroke-width": this.options.lineWidth,
19498              zIndex: 7
19499            }));
19500          }
19501          getTitlePosition(t3) {
19502            let e3 = this.horiz, i3 = this.left, s2 = this.top, o2 = this.len, r2 = this.options.title, a2 = e3 ? i3 : s2, n2 = this.opposite, l2 = this.offset, h2 = r2.x, d2 = r2.y, c2 = this.chart.renderer.fontMetrics(t3), p2 = t3 ? Math.max(t3.getBBox(false, 0).height - c2.h - 1, 0) : 0, u12 = {
19503              low: a2 + (e3 ? 0 : o2),
19504              middle: a2 + o2 / 2,
19505              high: a2 + (e3 ? o2 : 0)
19506            }[r2.align], g2 = (e3 ? s2 + this.height : i3) + (e3 ? 1 : -1) * (n2 ? -1 : 1) * (this.axisTitleMargin || 0) + [-p2, p2, c2.f, -p2][this.side], f2 = {
19507              x: e3 ? u12 + h2 : g2 + (n2 ? this.width : 0) + l2 + h2,
19508              y: e3 ? g2 + d2 - (n2 ? this.height : 0) + l2 : u12 + d2
19509            };
19510            return M(this, "afterGetTitlePosition", {
19511              titlePosition: f2
19512            }), f2;
19513          }
19514          renderMinorTick(t3, e3) {
19515            let i3 = this.minorTicks;
19516            i3[t3] || (i3[t3] = new a(this, t3, "minor")), e3 && i3[t3].isNew && i3[t3].render(null, true), i3[t3].render(null, false, 1);
19517          }
19518          renderTick(t3, e3, i3) {
19519            let s2 = this.isLinked, o2 = this.ticks;
19520            (!s2 || t3 >= this.min && t3 <= this.max || this.grid && this.grid.isColumn) && (o2[t3] || (o2[t3] = new a(this, t3)), i3 && o2[t3].isNew && o2[t3].render(e3, true, -1), o2[t3].render(e3));
19521          }
19522          render() {
19523            let t3, e3;
19524            let i3 = this, s2 = i3.chart, o2 = i3.logarithmic, n2 = s2.renderer, h2 = i3.options, d2 = i3.isLinked, c2 = i3.tickPositions, p2 = i3.axisTitle, u12 = i3.ticks, g2 = i3.minorTicks, f2 = i3.alternateBands, m2 = h2.stackLabels, x2 = h2.alternateGridColor, y2 = h2.crossing, b2 = i3.tickmarkOffset, v2 = i3.axisLine, S3 = i3.showAxis, k2 = l(n2.globalAnimation);
19525            if (i3.labelEdge.length = 0, i3.overlap = false, [u12, g2, f2].forEach(function(t4) {
19526              D2(t4, function(t5) {
19527                t5.isActive = false;
19528              });
19529            }), T2(y2)) {
19530              let t4 = this.isXAxis ? s2.yAxis[0] : s2.xAxis[0], e4 = [1, -1, -1, 1][this.side];
19531              if (t4) {
19532                let s3 = t4.toPixels(y2, true);
19533                i3.horiz && (s3 = t4.len - s3), i3.offset = e4 * s3;
19534              }
19535            }
19536            if (i3.hasData() || d2) {
19537              let n3 = i3.chart.hasRendered && i3.old && T2(i3.old.min);
19538              i3.minorTickInterval && !i3.categories && i3.getMinorTickPositions().forEach(function(t4) {
19539                i3.renderMinorTick(t4, n3);
19540              }), c2.length && (c2.forEach(function(t4, e4) {
19541                i3.renderTick(t4, e4, n3);
19542              }), b2 && (0 === i3.min || i3.single) && (u12[-1] || (u12[-1] = new a(i3, -1, null, true)), u12[-1].render(-1))), x2 && c2.forEach(function(a2, n4) {
19543                e3 = void 0 !== c2[n4 + 1] ? c2[n4 + 1] + b2 : i3.max - b2, n4 % 2 == 0 && a2 < i3.max && e3 <= i3.max + (s2.polar ? -b2 : b2) && (f2[a2] || (f2[a2] = new r.PlotLineOrBand(i3, {})), t3 = a2 + b2, f2[a2].options = {
19544                  from: o2 ? o2.lin2log(t3) : t3,
19545                  to: o2 ? o2.lin2log(e3) : e3,
19546                  color: x2,
19547                  className: "highcharts-alternate-grid"
19548                }, f2[a2].render(), f2[a2].isActive = true);
19549              }), i3._addedPlotLB || (i3._addedPlotLB = true, (h2.plotLines || []).concat(h2.plotBands || []).forEach(function(t4) {
19550                i3.addPlotBandOrLine(t4);
19551              }));
19552            }
19553            [u12, g2, f2].forEach(function(t4) {
19554              let e4 = [], i4 = k2.duration;
19555              D2(t4, function(t5, i5) {
19556                t5.isActive || (t5.render(i5, false, 0), t5.isActive = false, e4.push(i5));
19557              }), I(function() {
19558                let i5 = e4.length;
19559                for (; i5--; ) t4[e4[i5]] && !t4[e4[i5]].isActive && (t4[e4[i5]].destroy(), delete t4[e4[i5]]);
19560              }, t4 !== f2 && s2.hasRendered && i4 ? i4 : 0);
19561            }), v2 && (v2[v2.isPlaced ? "animate" : "attr"]({
19562              d: this.getLinePath(v2.strokeWidth())
19563            }), v2.isPlaced = true, v2[S3 ? "show" : "hide"](S3)), p2 && S3 && (p2[p2.isNew ? "attr" : "animate"](i3.getTitlePosition(p2)), p2.isNew = false), m2 && m2.enabled && i3.stacking && i3.stacking.renderStackTotals(), i3.old = {
19564              len: i3.len,
19565              max: i3.max,
19566              min: i3.min,
19567              transA: i3.transA,
19568              userMax: i3.userMax,
19569              userMin: i3.userMin
19570            }, i3.isDirty = false, M(this, "afterRender");
19571          }
19572          redraw() {
19573            this.visible && (this.render(), this.plotLinesAndBands.forEach(function(t3) {
19574              t3.render();
19575            })), this.series.forEach(function(t3) {
19576              t3.isDirty = true;
19577            });
19578          }
19579          getKeepProps() {
19580            return this.keepProps || G.keepProps;
19581          }
19582          destroy(t3) {
19583            let e3 = this, i3 = e3.plotLinesAndBands, s2 = this.eventOptions;
19584            if (M(this, "destroy", {
19585              keepEvents: t3
19586            }), t3 || j(e3), [e3.ticks, e3.minorTicks, e3.alternateBands].forEach(function(t4) {
19587              b(t4);
19588            }), i3) {
19589              let t4 = i3.length;
19590              for (; t4--; ) i3[t4].destroy();
19591            }
19592            for (let t4 in ["axisLine", "axisTitle", "axisGroup", "gridGroup", "labelGroup", "cross", "scrollbar"].forEach(function(t5) {
19593              e3[t5] && (e3[t5] = e3[t5].destroy());
19594            }), e3.plotLinesAndBandsGroups) e3.plotLinesAndBandsGroups[t4] = e3.plotLinesAndBandsGroups[t4].destroy();
19595            D2(e3, function(t4, i4) {
19596              -1 === e3.getKeepProps().indexOf(i4) && delete e3[i4];
19597            }), this.eventOptions = s2;
19598          }
19599          drawCrosshair(t3, e3) {
19600            let s2 = this.crosshair, o2 = E(s2 && s2.snap, true), r2 = this.chart, a2, n2, l2, h2 = this.cross, d2;
19601            if (M(this, "drawCrosshair", {
19602              e: t3,
19603              point: e3
19604            }), t3 || (t3 = this.cross && this.cross.e), s2 && false !== (y(e3) || !o2)) {
19605              if (o2 ? y(e3) && (n2 = E("colorAxis" !== this.coll ? e3.crosshairPos : null, this.isXAxis ? e3.plotX : this.len - e3.plotY)) : n2 = t3 && (this.horiz ? t3.chartX - this.pos : this.len - t3.chartY + this.pos), y(n2) && (d2 = {
19606                value: e3 && (this.isXAxis ? e3.x : E(e3.stackY, e3.y)),
19607                translatedValue: n2
19608              }, r2.polar && k(d2, {
19609                isCrosshair: true,
19610                chartX: t3 && t3.chartX,
19611                chartY: t3 && t3.chartY,
19612                point: e3
19613              }), a2 = this.getPlotLinePath(d2) || null), !y(a2)) {
19614                this.hideCrosshair();
19615                return;
19616              }
19617              l2 = this.categories && !this.isRadial, h2 || (this.cross = h2 = r2.renderer.path().addClass("highcharts-crosshair highcharts-crosshair-" + (l2 ? "category " : "thin ") + (s2.className || "")).attr({
19618                zIndex: E(s2.zIndex, 2)
19619              }).add(), !r2.styledMode && (h2.attr({
19620                stroke: s2.color || (l2 ? i2.parse("#ccd3ff").setOpacity(0.25).get() : "#cccccc"),
19621                "stroke-width": E(s2.width, 1)
19622              }).css({
19623                "pointer-events": "none"
19624              }), s2.dashStyle && h2.attr({
19625                dashstyle: s2.dashStyle
19626              }))), h2.show().attr({
19627                d: a2
19628              }), l2 && !s2.width && h2.attr({
19629                "stroke-width": this.transA
19630              }), this.cross.e = t3;
19631            } else this.hideCrosshair();
19632            M(this, "afterDrawCrosshair", {
19633              e: t3,
19634              point: e3
19635            });
19636          }
19637          hideCrosshair() {
19638            this.cross && this.cross.hide(), M(this, "afterHideCrosshair");
19639          }
19640          update(t3, e3) {
19641            let i3 = this.chart;
19642            t3 = O(this.userOptions, t3), this.destroy(true), this.init(i3, t3), i3.isDirtyBox = true, E(e3, true) && i3.redraw();
19643          }
19644          remove(t3) {
19645            let e3 = this.chart, i3 = this.coll, s2 = this.series, o2 = s2.length;
19646            for (; o2--; ) s2[o2] && s2[o2].remove(false);
19647            v(e3.axes, this), v(e3[i3] || [], this), e3.orderItems(i3), this.destroy(), e3.isDirtyBox = true, E(t3, true) && e3.redraw();
19648          }
19649          setTitle(t3, e3) {
19650            this.update({
19651              title: t3
19652            }, e3);
19653          }
19654          setCategories(t3, e3) {
19655            this.update({
19656              categories: t3
19657            }, e3);
19658          }
19659        }
19660        return G.keepProps = ["coll", "extKey", "hcEvents", "len", "names", "series", "userMax", "userMin"], G;
19661      }), i(e, "Core/Axis/DateTimeAxis.js", [e["Core/Utilities.js"]], function(t2) {
19662        var e2;
19663        let {
19664          addEvent: i2,
19665          getMagnitude: s,
19666          normalizeTickInterval: o,
19667          timeUnits: r
19668        } = t2;
19669        return function(t3) {
19670          function e3() {
19671            return this.chart.time.getTimeTicks.apply(this.chart.time, arguments);
19672          }
19673          function a() {
19674            if ("datetime" !== this.type) {
19675              this.dateTime = void 0;
19676              return;
19677            }
19678            this.dateTime || (this.dateTime = new n(this));
19679          }
19680          t3.compose = function(t4) {
19681            return t4.keepProps.includes("dateTime") || (t4.keepProps.push("dateTime"), t4.prototype.getTimeTicks = e3, i2(t4, "afterSetType", a)), t4;
19682          };
19683          class n {
19684            constructor(t4) {
19685              this.axis = t4;
19686            }
19687            normalizeTimeTickInterval(t4, e4) {
19688              let i3 = e4 || [["millisecond", [1, 2, 5, 10, 20, 25, 50, 100, 200, 500]], ["second", [1, 2, 5, 10, 15, 30]], ["minute", [1, 2, 5, 10, 15, 30]], ["hour", [1, 2, 3, 4, 6, 8, 12]], ["day", [1, 2]], ["week", [1, 2]], ["month", [1, 2, 3, 4, 6]], ["year", null]], a2 = i3[i3.length - 1], n2 = r[a2[0]], l = a2[1], h;
19689              for (h = 0; h < i3.length && (n2 = r[(a2 = i3[h])[0]], l = a2[1], !i3[h + 1] || !(t4 <= (n2 * l[l.length - 1] + r[i3[h + 1][0]]) / 2)); h++) ;
19690              n2 === r.year && t4 < 5 * n2 && (l = [1, 2, 5]);
19691              let d = o(t4 / n2, l, "year" === a2[0] ? Math.max(s(t4 / n2), 1) : 1);
19692              return {
19693                unitRange: n2,
19694                count: d,
19695                unitName: a2[0]
19696              };
19697            }
19698            getXDateFormat(t4, e4) {
19699              let {
19700                axis: i3
19701              } = this, s2 = i3.chart.time;
19702              return i3.closestPointRange ? s2.getDateFormat(i3.closestPointRange, t4, i3.options.startOfWeek, e4) || s2.resolveDTLFormat(e4.year).main : s2.resolveDTLFormat(e4.day).main;
19703            }
19704          }
19705          t3.Additions = n;
19706        }(e2 || (e2 = {})), e2;
19707      }), i(e, "Core/Axis/LogarithmicAxis.js", [e["Core/Utilities.js"]], function(t2) {
19708        var e2;
19709        let {
19710          addEvent: i2,
19711          normalizeTickInterval: s,
19712          pick: o
19713        } = t2;
19714        return function(t3) {
19715          function e3() {
19716            "logarithmic" !== this.type ? this.logarithmic = void 0 : this.logarithmic ?? (this.logarithmic = new a(this));
19717          }
19718          function r() {
19719            let t4 = this.logarithmic;
19720            t4 && (this.lin2val = function(e4) {
19721              return t4.lin2log(e4);
19722            }, this.val2lin = function(e4) {
19723              return t4.log2lin(e4);
19724            });
19725          }
19726          t3.compose = function(t4) {
19727            return t4.keepProps.includes("logarithmic") || (t4.keepProps.push("logarithmic"), i2(t4, "afterSetType", e3), i2(t4, "afterInit", r)), t4;
19728          };
19729          class a {
19730            constructor(t4) {
19731              this.axis = t4;
19732            }
19733            getLogTickPositions(t4, e4, i3, r2) {
19734              let a2 = this.axis, n = a2.len, l = a2.options, h = [];
19735              if (r2 || (this.minorAutoInterval = void 0), t4 >= 0.5) t4 = Math.round(t4), h = a2.getLinearTickPositions(t4, e4, i3);
19736              else if (t4 >= 0.08) {
19737                let s2, o2, a3, n2, l2, d, c;
19738                let p = Math.floor(e4);
19739                for (s2 = t4 > 0.3 ? [1, 2, 4] : t4 > 0.15 ? [1, 2, 4, 6, 8] : [1, 2, 3, 4, 5, 6, 7, 8, 9], o2 = p; o2 < i3 + 1 && !c; o2++) for (a3 = 0, n2 = s2.length; a3 < n2 && !c; a3++) (l2 = this.log2lin(this.lin2log(o2) * s2[a3])) > e4 && (!r2 || d <= i3) && void 0 !== d && h.push(d), d > i3 && (c = true), d = l2;
19740              } else {
19741                let d = this.lin2log(e4), c = this.lin2log(i3), p = r2 ? a2.getMinorTickInterval() : l.tickInterval, u11 = l.tickPixelInterval / (r2 ? 5 : 1), g = r2 ? n / a2.tickPositions.length : n;
19742                t4 = s(t4 = o("auto" === p ? null : p, this.minorAutoInterval, (c - d) * u11 / (g || 1))), h = a2.getLinearTickPositions(t4, d, c).map(this.log2lin), r2 || (this.minorAutoInterval = t4 / 5);
19743              }
19744              return r2 || (a2.tickInterval = t4), h;
19745            }
19746            lin2log(t4) {
19747              return Math.pow(10, t4);
19748            }
19749            log2lin(t4) {
19750              return Math.log(t4) / Math.LN10;
19751            }
19752          }
19753          t3.Additions = a;
19754        }(e2 || (e2 = {})), e2;
19755      }), i(e, "Core/Axis/PlotLineOrBand/PlotLineOrBandAxis.js", [e["Core/Utilities.js"]], function(t2) {
19756        var e2;
19757        let {
19758          erase: i2,
19759          extend: s,
19760          isNumber: o
19761        } = t2;
19762        return function(t3) {
19763          let e3;
19764          function r(t4) {
19765            return this.addPlotBandOrLine(t4, "plotBands");
19766          }
19767          function a(t4, i3) {
19768            let s2 = this.userOptions, o2 = new e3(this, t4);
19769            if (this.visible && (o2 = o2.render()), o2) {
19770              if (this._addedPlotLB || (this._addedPlotLB = true, (s2.plotLines || []).concat(s2.plotBands || []).forEach((t5) => {
19771                this.addPlotBandOrLine(t5);
19772              })), i3) {
19773                let e4 = s2[i3] || [];
19774                e4.push(t4), s2[i3] = e4;
19775              }
19776              this.plotLinesAndBands.push(o2);
19777            }
19778            return o2;
19779          }
19780          function n(t4) {
19781            return this.addPlotBandOrLine(t4, "plotLines");
19782          }
19783          function l(t4, e4, i3) {
19784            i3 = i3 || this.options;
19785            let s2 = this.getPlotLinePath({
19786              value: e4,
19787              force: true,
19788              acrossPanes: i3.acrossPanes
19789            }), r2 = [], a2 = this.horiz, n2 = !o(this.min) || !o(this.max) || t4 < this.min && e4 < this.min || t4 > this.max && e4 > this.max, l2 = this.getPlotLinePath({
19790              value: t4,
19791              force: true,
19792              acrossPanes: i3.acrossPanes
19793            }), h2, d2 = 1, c2;
19794            if (l2 && s2) for (n2 && (c2 = l2.toString() === s2.toString(), d2 = 0), h2 = 0; h2 < l2.length; h2 += 2) {
19795              let t5 = l2[h2], e5 = l2[h2 + 1], i4 = s2[h2], o2 = s2[h2 + 1];
19796              ("M" === t5[0] || "L" === t5[0]) && ("M" === e5[0] || "L" === e5[0]) && ("M" === i4[0] || "L" === i4[0]) && ("M" === o2[0] || "L" === o2[0]) && (a2 && i4[1] === t5[1] ? (i4[1] += d2, o2[1] += d2) : a2 || i4[2] !== t5[2] || (i4[2] += d2, o2[2] += d2), r2.push(["M", t5[1], t5[2]], ["L", e5[1], e5[2]], ["L", o2[1], o2[2]], ["L", i4[1], i4[2]], ["Z"])), r2.isFlat = c2;
19797            }
19798            return r2;
19799          }
19800          function h(t4) {
19801            this.removePlotBandOrLine(t4);
19802          }
19803          function d(t4) {
19804            let e4 = this.plotLinesAndBands, s2 = this.options, o2 = this.userOptions;
19805            if (e4) {
19806              let r2 = e4.length;
19807              for (; r2--; ) e4[r2].id === t4 && e4[r2].destroy();
19808              [s2.plotLines || [], o2.plotLines || [], s2.plotBands || [], o2.plotBands || []].forEach(function(e5) {
19809                for (r2 = e5.length; r2--; ) (e5[r2] || {}).id === t4 && i2(e5, e5[r2]);
19810              });
19811            }
19812          }
19813          function c(t4) {
19814            this.removePlotBandOrLine(t4);
19815          }
19816          t3.compose = function(t4, i3) {
19817            let o2 = i3.prototype;
19818            return o2.addPlotBand || (e3 = t4, s(o2, {
19819              addPlotBand: r,
19820              addPlotLine: n,
19821              addPlotBandOrLine: a,
19822              getPlotBandPath: l,
19823              removePlotBand: h,
19824              removePlotLine: c,
19825              removePlotBandOrLine: d
19826            })), i3;
19827          };
19828        }(e2 || (e2 = {})), e2;
19829      }), i(e, "Core/Axis/PlotLineOrBand/PlotLineOrBand.js", [e["Core/Axis/PlotLineOrBand/PlotLineOrBandAxis.js"], e["Core/Utilities.js"]], function(t2, e2) {
19830        let {
19831          addEvent: i2,
19832          arrayMax: s,
19833          arrayMin: o,
19834          defined: r,
19835          destroyObjectProperties: a,
19836          erase: n,
19837          fireEvent: l,
19838          merge: h,
19839          objectEach: d,
19840          pick: c
19841        } = e2;
19842        class p {
19843          static compose(e3, s2) {
19844            return i2(e3, "afterInit", function() {
19845              this.labelCollectors.push(() => {
19846                let t3 = [];
19847                for (let e4 of this.axes) for (let {
19848                  label: i3,
19849                  options: s3
19850                } of e4.plotLinesAndBands) i3 && !s3?.label?.allowOverlap && t3.push(i3);
19851                return t3;
19852              });
19853            }), t2.compose(p, s2);
19854          }
19855          constructor(t3, e3) {
19856            this.axis = t3, this.options = e3, this.id = e3.id;
19857          }
19858          render() {
19859            l(this, "render");
19860            let {
19861              axis: t3,
19862              options: e3
19863            } = this, {
19864              horiz: i3,
19865              logarithmic: s2
19866            } = t3, {
19867              color: o2,
19868              events: a2,
19869              zIndex: n2 = 0
19870            } = e3, p2 = {}, u11 = t3.chart.renderer, g = e3.to, f = e3.from, m = e3.value, x = e3.borderWidth, y = e3.label, {
19871              label: b,
19872              svgElem: v
19873            } = this, S2 = [], k, M = r(f) && r(g), C = r(m), A = !v, w = {
19874              class: "highcharts-plot-" + (M ? "band " : "line ") + (e3.className || "")
19875            }, T2 = M ? "bands" : "lines";
19876            if (!t3.chart.styledMode && (C ? (w.stroke = o2 || "#999999", w["stroke-width"] = c(e3.width, 1), e3.dashStyle && (w.dashstyle = e3.dashStyle)) : M && (w.fill = o2 || "#e6e9ff", x && (w.stroke = e3.borderColor, w["stroke-width"] = x))), p2.zIndex = n2, T2 += "-" + n2, (k = t3.plotLinesAndBandsGroups[T2]) || (t3.plotLinesAndBandsGroups[T2] = k = u11.g("plot-" + T2).attr(p2).add()), v || (this.svgElem = v = u11.path().attr(w).add(k)), r(m)) S2 = t3.getPlotLinePath({
19877              value: s2?.log2lin(m) ?? m,
19878              lineWidth: v.strokeWidth(),
19879              acrossPanes: e3.acrossPanes
19880            });
19881            else {
19882              if (!(r(f) && r(g))) return;
19883              S2 = t3.getPlotBandPath(s2?.log2lin(f) ?? f, s2?.log2lin(g) ?? g, e3);
19884            }
19885            return !this.eventsAdded && a2 && (d(a2, (t4, e4) => {
19886              v?.on(e4, (t5) => {
19887                a2[e4].apply(this, [t5]);
19888              });
19889            }), this.eventsAdded = true), (A || !v.d) && S2?.length ? v.attr({
19890              d: S2
19891            }) : v && (S2 ? (v.show(), v.animate({
19892              d: S2
19893            })) : v.d && (v.hide(), b && (this.label = b = b.destroy()))), y && (r(y.text) || r(y.formatter)) && S2?.length && t3.width > 0 && t3.height > 0 && !S2.isFlat ? (y = h(__spreadValues({
19894              align: i3 && M ? "center" : void 0,
19895              x: i3 ? !M && 4 : 10,
19896              verticalAlign: !i3 && M ? "middle" : void 0,
19897              y: i3 ? M ? 16 : 10 : M ? 6 : -4,
19898              rotation: i3 && !M ? 90 : 0
19899            }, M ? {
19900              inside: true
19901            } : {}), y), this.renderLabel(y, S2, M, n2)) : b && b.hide(), this;
19902          }
19903          renderLabel(t3, e3, i3, a2) {
19904            let n2 = this.axis, l2 = n2.chart.renderer, d2 = t3.inside, c2 = this.label;
19905            c2 || (this.label = c2 = l2.text(this.getLabelText(t3), 0, 0, t3.useHTML).attr({
19906              align: t3.textAlign || t3.align,
19907              rotation: t3.rotation,
19908              class: "highcharts-plot-" + (i3 ? "band" : "line") + "-label " + (t3.className || ""),
19909              zIndex: a2
19910            }), n2.chart.styledMode || c2.css(h({
19911              fontSize: "0.8em",
19912              textOverflow: i3 && !d2 ? "" : "ellipsis"
19913            }, t3.style)), c2.add());
19914            let p2 = e3.xBounds || [e3[0][1], e3[1][1], i3 ? e3[2][1] : e3[0][1]], u11 = e3.yBounds || [e3[0][2], e3[1][2], i3 ? e3[2][2] : e3[0][2]], g = o(p2), f = o(u11), m = s(p2) - g;
19915            c2.align(t3, false, {
19916              x: g,
19917              y: f,
19918              width: m,
19919              height: s(u11) - f
19920            }), (!c2.alignValue || "left" === c2.alignValue || r(d2)) && c2.css({
19921              width: (t3.style?.width || (i3 && d2 ? m : 90 === c2.rotation ? n2.height - (c2.alignAttr.y - n2.top) : (t3.clip ? n2.width : n2.chart.chartWidth) - (c2.alignAttr.x - n2.left))) + "px"
19922            }), c2.show(true);
19923          }
19924          getLabelText(t3) {
19925            return r(t3.formatter) ? t3.formatter.call(this) : t3.text;
19926          }
19927          destroy() {
19928            n(this.axis.plotLinesAndBands, this), delete this.axis, a(this);
19929          }
19930        }
19931        return p;
19932      }), i(e, "Core/Tooltip.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Templating.js"], e["Core/Globals.js"], e["Core/Renderer/RendererUtilities.js"], e["Core/Renderer/RendererRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o, r) {
19933        var a;
19934        let {
19935          animObject: n
19936        } = t2, {
19937          format: l
19938        } = e2, {
19939          composed: h,
19940          doc: d,
19941          isSafari: c
19942        } = i2, {
19943          distribute: p
19944        } = s, {
19945          addEvent: u11,
19946          clamp: g,
19947          css: f,
19948          discardElement: m,
19949          extend: x,
19950          fireEvent: y,
19951          isArray: b,
19952          isNumber: v,
19953          isString: S2,
19954          merge: k,
19955          pick: M,
19956          pushUnique: C,
19957          splat: A,
19958          syncTimeout: w
19959        } = r;
19960        class T2 {
19961          constructor(t3, e3, i3) {
19962            this.allowShared = true, this.crosshairs = [], this.distance = 0, this.isHidden = true, this.isSticky = false, this.options = {}, this.outside = false, this.chart = t3, this.init(t3, e3), this.pointer = i3;
19963          }
19964          bodyFormatter(t3) {
19965            return t3.map(function(t4) {
19966              let e3 = t4.series.tooltipOptions;
19967              return (e3[(t4.point.formatPrefix || "point") + "Formatter"] || t4.point.tooltipFormatter).call(t4.point, e3[(t4.point.formatPrefix || "point") + "Format"] || "");
19968            });
19969          }
19970          cleanSplit(t3) {
19971            this.chart.series.forEach(function(e3) {
19972              let i3 = e3 && e3.tt;
19973              i3 && (!i3.isActive || t3 ? e3.tt = i3.destroy() : i3.isActive = false);
19974            });
19975          }
19976          defaultFormatter(t3) {
19977            let e3;
19978            let i3 = this.points || A(this);
19979            return (e3 = (e3 = [t3.tooltipFooterHeaderFormatter(i3[0])]).concat(t3.bodyFormatter(i3))).push(t3.tooltipFooterHeaderFormatter(i3[0], true)), e3;
19980          }
19981          destroy() {
19982            this.label && (this.label = this.label.destroy()), this.split && (this.cleanSplit(true), this.tt && (this.tt = this.tt.destroy())), this.renderer && (this.renderer = this.renderer.destroy(), m(this.container)), r.clearTimeout(this.hideTimer);
19983          }
19984          getAnchor(t3, e3) {
19985            let i3;
19986            let {
19987              chart: s2,
19988              pointer: o2
19989            } = this, r2 = s2.inverted, a2 = s2.plotTop, n2 = s2.plotLeft;
19990            if ((t3 = A(t3))[0].series && t3[0].series.yAxis && !t3[0].series.yAxis.options.reversedStacks && (t3 = t3.slice().reverse()), this.followPointer && e3) void 0 === e3.chartX && (e3 = o2.normalize(e3)), i3 = [e3.chartX - n2, e3.chartY - a2];
19991            else if (t3[0].tooltipPos) i3 = t3[0].tooltipPos;
19992            else {
19993              let s3 = 0, o3 = 0;
19994              t3.forEach(function(t4) {
19995                let e4 = t4.pos(true);
19996                e4 && (s3 += e4[0], o3 += e4[1]);
19997              }), s3 /= t3.length, o3 /= t3.length, this.shared && t3.length > 1 && e3 && (r2 ? s3 = e3.chartX : o3 = e3.chartY), i3 = [s3 - n2, o3 - a2];
19998            }
19999            return i3.map(Math.round);
20000          }
20001          getClassName(t3, e3, i3) {
20002            let s2 = this.options, o2 = t3.series, r2 = o2.options;
20003            return [s2.className, "highcharts-label", i3 && "highcharts-tooltip-header", e3 ? "highcharts-tooltip-box" : "highcharts-tooltip", !i3 && "highcharts-color-" + M(t3.colorIndex, o2.colorIndex), r2 && r2.className].filter(S2).join(" ");
20004          }
20005          getLabel({
20006            anchorX: t3,
20007            anchorY: e3
20008          } = {
20009            anchorX: 0,
20010            anchorY: 0
20011          }) {
20012            let s2 = this, r2 = this.chart.styledMode, a2 = this.options, n2 = this.split && this.allowShared, l2 = this.container, h2 = this.chart.renderer;
20013            if (this.label) {
20014              let t4 = !this.label.hasClass("highcharts-label");
20015              (!n2 && t4 || n2 && !t4) && this.destroy();
20016            }
20017            if (!this.label) {
20018              if (this.outside) {
20019                let t4 = this.chart.options.chart.style, e4 = o.getRendererType();
20020                this.container = l2 = i2.doc.createElement("div"), l2.className = "highcharts-tooltip-container", f(l2, {
20021                  position: "absolute",
20022                  top: "1px",
20023                  pointerEvents: "none",
20024                  zIndex: Math.max(this.options.style.zIndex || 0, (t4 && t4.zIndex || 0) + 3)
20025                }), this.renderer = h2 = new e4(l2, 0, 0, t4, void 0, void 0, h2.styledMode);
20026              }
20027              if (n2 ? this.label = h2.g("tooltip") : (this.label = h2.label("", t3, e3, a2.shape, void 0, void 0, a2.useHTML, void 0, "tooltip").attr({
20028                padding: a2.padding,
20029                r: a2.borderRadius
20030              }), r2 || this.label.attr({
20031                fill: a2.backgroundColor,
20032                "stroke-width": a2.borderWidth || 0
20033              }).css(a2.style).css({
20034                pointerEvents: a2.style.pointerEvents || (this.shouldStickOnContact() ? "auto" : "none")
20035              })), s2.outside) {
20036                let t4 = this.label;
20037                [t4.xSetter, t4.ySetter].forEach((e4, i3) => {
20038                  t4[i3 ? "ySetter" : "xSetter"] = (o2) => {
20039                    e4.call(t4, s2.distance), t4[i3 ? "y" : "x"] = o2, l2 && (l2.style[i3 ? "top" : "left"] = `${o2}px`);
20040                  };
20041                });
20042              }
20043              this.label.attr({
20044                zIndex: 8
20045              }).shadow(a2.shadow).add();
20046            }
20047            return l2 && !l2.parentElement && i2.doc.body.appendChild(l2), this.label;
20048          }
20049          getPlayingField() {
20050            let {
20051              body: t3,
20052              documentElement: e3
20053            } = d, {
20054              chart: i3,
20055              distance: s2,
20056              outside: o2
20057            } = this;
20058            return {
20059              width: o2 ? Math.max(t3.scrollWidth, e3.scrollWidth, t3.offsetWidth, e3.offsetWidth, e3.clientWidth) - 2 * s2 : i3.chartWidth,
20060              height: o2 ? Math.max(t3.scrollHeight, e3.scrollHeight, t3.offsetHeight, e3.offsetHeight, e3.clientHeight) : i3.chartHeight
20061            };
20062          }
20063          getPosition(t3, e3, i3) {
20064            let {
20065              distance: s2,
20066              chart: o2,
20067              outside: r2,
20068              pointer: a2
20069            } = this, {
20070              inverted: n2,
20071              plotLeft: l2,
20072              plotTop: h2,
20073              polar: d2
20074            } = o2, {
20075              plotX: c2 = 0,
20076              plotY: p2 = 0
20077            } = i3, u12 = {}, g2 = n2 && i3.h || 0, {
20078              height: f2,
20079              width: m2
20080            } = this.getPlayingField(), x2 = a2.getChartPosition(), y2 = (t4) => t4 * x2.scaleX, b2 = (t4) => t4 * x2.scaleY, v2 = (i4) => {
20081              let a3 = "x" === i4;
20082              return [i4, a3 ? m2 : f2, a3 ? t3 : e3].concat(r2 ? [a3 ? y2(t3) : b2(e3), a3 ? x2.left - s2 + y2(c2 + l2) : x2.top - s2 + b2(p2 + h2), 0, a3 ? m2 : f2] : [a3 ? t3 : e3, a3 ? c2 + l2 : p2 + h2, a3 ? l2 : h2, a3 ? l2 + o2.plotWidth : h2 + o2.plotHeight]);
20083            }, S3 = v2("y"), k2 = v2("x"), C2, A2 = !!i3.negative;
20084            !d2 && o2.hoverSeries?.yAxis?.reversed && (A2 = !A2);
20085            let w2 = !this.followPointer && M(i3.ttBelow, !d2 && !n2 === A2), T3 = function(t4, e4, i4, o3, a3, n3, l3) {
20086              let h3 = r2 ? "y" === t4 ? b2(s2) : y2(s2) : s2, d3 = (i4 - o3) / 2, c3 = o3 < a3 - s2, p3 = a3 + s2 + o3 < e4, f3 = a3 - h3 - i4 + d3, m3 = a3 + h3 - d3;
20087              if (w2 && p3) u12[t4] = m3;
20088              else if (!w2 && c3) u12[t4] = f3;
20089              else if (c3) u12[t4] = Math.min(l3 - o3, f3 - g2 < 0 ? f3 : f3 - g2);
20090              else {
20091                if (!p3) return false;
20092                u12[t4] = Math.max(n3, m3 + g2 + i4 > e4 ? m3 : m3 + g2);
20093              }
20094            }, P = function(t4, e4, i4, o3, r3) {
20095              if (r3 < s2 || r3 > e4 - s2) return false;
20096              r3 < i4 / 2 ? u12[t4] = 1 : r3 > e4 - o3 / 2 ? u12[t4] = e4 - o3 - 2 : u12[t4] = r3 - i4 / 2;
20097            }, O = function(t4) {
20098              [S3, k2] = [k2, S3], C2 = t4;
20099            }, L = () => {
20100              false !== T3.apply(0, S3) ? false !== P.apply(0, k2) || C2 || (O(true), L()) : C2 ? u12.x = u12.y = 0 : (O(true), L());
20101            };
20102            return (n2 && !d2 || this.len > 1) && O(), L(), u12;
20103          }
20104          hide(t3) {
20105            let e3 = this;
20106            r.clearTimeout(this.hideTimer), t3 = M(t3, this.options.hideDelay), this.isHidden || (this.hideTimer = w(function() {
20107              let i3 = e3.getLabel();
20108              e3.getLabel().animate({
20109                opacity: 0
20110              }, {
20111                duration: t3 ? 150 : t3,
20112                complete: () => {
20113                  i3.hide(), e3.container && e3.container.remove();
20114                }
20115              }), e3.isHidden = true;
20116            }, t3));
20117          }
20118          init(t3, e3) {
20119            this.chart = t3, this.options = e3, this.crosshairs = [], this.isHidden = true, this.split = e3.split && !t3.inverted && !t3.polar, this.shared = e3.shared || this.split, this.outside = M(e3.outside, !!(t3.scrollablePixelsX || t3.scrollablePixelsY));
20120          }
20121          shouldStickOnContact(t3) {
20122            return !!(!this.followPointer && this.options.stickOnContact && (!t3 || this.pointer.inClass(t3.target, "highcharts-tooltip")));
20123          }
20124          move(t3, e3, i3, s2) {
20125            let o2 = this, r2 = n(!o2.isHidden && o2.options.animation), a2 = o2.followPointer || (o2.len || 0) > 1, l2 = {
20126              x: t3,
20127              y: e3
20128            };
20129            a2 || (l2.anchorX = i3, l2.anchorY = s2), r2.step = () => o2.drawTracker(), o2.getLabel().animate(l2, r2);
20130          }
20131          refresh(t3, e3) {
20132            let {
20133              chart: i3,
20134              options: s2,
20135              pointer: o2,
20136              shared: a2
20137            } = this, n2 = A(t3), h2 = n2[0], d2 = [], c2 = s2.format, p2 = s2.formatter || this.defaultFormatter, u12 = i3.styledMode, f2 = {}, m2 = this.allowShared;
20138            if (!s2.enabled || !h2.series) return;
20139            r.clearTimeout(this.hideTimer), this.allowShared = !(!b(t3) && t3.series && t3.series.noSharedTooltip), m2 = m2 && !this.allowShared, this.followPointer = !this.split && h2.series.tooltipOptions.followPointer;
20140            let x2 = this.getAnchor(t3, e3), v2 = x2[0], k2 = x2[1];
20141            a2 && this.allowShared ? (o2.applyInactiveState(n2), n2.forEach(function(t4) {
20142              t4.setState("hover"), d2.push(t4.getLabelConfig());
20143            }), (f2 = h2.getLabelConfig()).points = d2) : f2 = h2.getLabelConfig(), this.len = d2.length;
20144            let C2 = S2(c2) ? l(c2, f2, i3) : p2.call(f2, this), w2 = h2.series;
20145            if (this.distance = M(w2.tooltipOptions.distance, 16), false === C2) this.hide();
20146            else {
20147              if (this.split && this.allowShared) this.renderSplit(C2, n2);
20148              else {
20149                let t4 = v2, r2 = k2;
20150                if (e3 && o2.isDirectTouch && (t4 = e3.chartX - i3.plotLeft, r2 = e3.chartY - i3.plotTop), i3.polar || false === w2.options.clip || n2.some((e4) => o2.isDirectTouch || e4.series.shouldShowTooltip(t4, r2))) {
20151                  let t5 = this.getLabel(m2 && this.tt || {});
20152                  (!s2.style.width || u12) && t5.css({
20153                    width: (this.outside ? this.getPlayingField() : i3.spacingBox).width + "px"
20154                  }), t5.attr({
20155                    class: this.getClassName(h2),
20156                    text: C2 && C2.join ? C2.join("") : C2
20157                  }), this.outside && t5.attr({
20158                    x: g(t5.x || 0, 0, this.getPlayingField().width - (t5.width || 0))
20159                  }), u12 || t5.attr({
20160                    stroke: s2.borderColor || h2.color || w2.color || "#666666"
20161                  }), this.updatePosition({
20162                    plotX: v2,
20163                    plotY: k2,
20164                    negative: h2.negative,
20165                    ttBelow: h2.ttBelow,
20166                    h: x2[2] || 0
20167                  });
20168                } else {
20169                  this.hide();
20170                  return;
20171                }
20172              }
20173              this.isHidden && this.label && this.label.attr({
20174                opacity: 1
20175              }).show(), this.isHidden = false;
20176            }
20177            y(this, "refresh");
20178          }
20179          renderSplit(t3, e3) {
20180            let i3 = this, {
20181              chart: s2,
20182              chart: {
20183                chartWidth: o2,
20184                chartHeight: r2,
20185                plotHeight: a2,
20186                plotLeft: n2,
20187                plotTop: l2,
20188                scrollablePixelsY: h2 = 0,
20189                scrollablePixelsX: u12,
20190                styledMode: f2
20191              },
20192              distance: m2,
20193              options: y2,
20194              options: {
20195                positioner: b2
20196              },
20197              pointer: v2
20198            } = i3, {
20199              scrollLeft: k2 = 0,
20200              scrollTop: C2 = 0
20201            } = s2.scrollablePlotArea?.scrollingContainer || {}, A2 = i3.outside && "number" != typeof u12 ? d.documentElement.getBoundingClientRect() : {
20202              left: k2,
20203              right: k2 + o2,
20204              top: C2,
20205              bottom: C2 + r2
20206            }, w2 = i3.getLabel(), T3 = this.renderer || s2.renderer, P = !!(s2.xAxis[0] && s2.xAxis[0].opposite), {
20207              left: O,
20208              top: L
20209            } = v2.getChartPosition(), D2 = l2 + C2, E = 0, B = a2 - h2;
20210            function j(t4, e4, s3, o3, r3 = true) {
20211              let a3, n3;
20212              return s3 ? (a3 = P ? 0 : B, n3 = g(t4 - o3 / 2, A2.left, A2.right - o3 - (i3.outside ? O : 0))) : (a3 = e4 - D2, n3 = g(n3 = r3 ? t4 - o3 - m2 : t4 + m2, r3 ? n3 : A2.left, A2.right)), {
20213                x: n3,
20214                y: a3
20215              };
20216            }
20217            S2(t3) && (t3 = [false, t3]);
20218            let R = t3.slice(0, e3.length + 1).reduce(function(t4, s3, o3) {
20219              if (false !== s3 && "" !== s3) {
20220                let r3 = e3[o3 - 1] || {
20221                  isHeader: true,
20222                  plotX: e3[0].plotX,
20223                  plotY: a2,
20224                  series: {}
20225                }, h3 = r3.isHeader, d2 = h3 ? i3 : r3.series, c2 = d2.tt = function(t5, e4, s4) {
20226                  let o4 = t5, {
20227                    isHeader: r4,
20228                    series: a3
20229                  } = e4;
20230                  if (!o4) {
20231                    let t6 = {
20232                      padding: y2.padding,
20233                      r: y2.borderRadius
20234                    };
20235                    f2 || (t6.fill = y2.backgroundColor, t6["stroke-width"] = y2.borderWidth ?? 1), o4 = T3.label("", 0, 0, y2[r4 ? "headerShape" : "shape"], void 0, void 0, y2.useHTML).addClass(i3.getClassName(e4, true, r4)).attr(t6).add(w2);
20236                  }
20237                  return o4.isActive = true, o4.attr({
20238                    text: s4
20239                  }), f2 || o4.css(y2.style).attr({
20240                    stroke: y2.borderColor || e4.color || a3.color || "#333333"
20241                  }), o4;
20242                }(d2.tt, r3, s3.toString()), p2 = c2.getBBox(), u13 = p2.width + c2.strokeWidth();
20243                h3 && (E = p2.height, B += E, P && (D2 -= E));
20244                let {
20245                  anchorX: x2,
20246                  anchorY: v3
20247                } = function(t5) {
20248                  let e4, i4;
20249                  let {
20250                    isHeader: s4,
20251                    plotX: o4 = 0,
20252                    plotY: r4 = 0,
20253                    series: h4
20254                  } = t5;
20255                  if (s4) e4 = Math.max(n2 + o4, n2), i4 = l2 + a2 / 2;
20256                  else {
20257                    let {
20258                      xAxis: t6,
20259                      yAxis: s5
20260                    } = h4;
20261                    e4 = t6.pos + g(o4, -m2, t6.len + m2), h4.shouldShowTooltip(0, s5.pos - l2 + r4, {
20262                      ignoreX: true
20263                    }) && (i4 = s5.pos + r4);
20264                  }
20265                  return {
20266                    anchorX: e4 = g(e4, A2.left - m2, A2.right + m2),
20267                    anchorY: i4
20268                  };
20269                }(r3);
20270                if ("number" == typeof v3) {
20271                  let e4 = p2.height + 1, s4 = b2 ? b2.call(i3, u13, e4, r3) : j(x2, v3, h3, u13);
20272                  t4.push({
20273                    align: b2 ? 0 : void 0,
20274                    anchorX: x2,
20275                    anchorY: v3,
20276                    boxWidth: u13,
20277                    point: r3,
20278                    rank: M(s4.rank, h3 ? 1 : 0),
20279                    size: e4,
20280                    target: s4.y,
20281                    tt: c2,
20282                    x: s4.x
20283                  });
20284                } else c2.isActive = false;
20285              }
20286              return t4;
20287            }, []);
20288            !b2 && R.some((t4) => {
20289              let {
20290                outside: e4
20291              } = i3, s3 = (e4 ? O : 0) + t4.anchorX;
20292              return s3 < A2.left && s3 + t4.boxWidth < A2.right || s3 < O - A2.left + t4.boxWidth && A2.right - s3 > s3;
20293            }) && (R = R.map((t4) => {
20294              let {
20295                x: e4,
20296                y: i4
20297              } = j(t4.anchorX, t4.anchorY, t4.point.isHeader, t4.boxWidth, false);
20298              return x(t4, {
20299                target: i4,
20300                x: e4
20301              });
20302            })), i3.cleanSplit(), p(R, B);
20303            let I = {
20304              left: O,
20305              right: O
20306            };
20307            R.forEach(function(t4) {
20308              let {
20309                x: e4,
20310                boxWidth: s3,
20311                isHeader: o3
20312              } = t4;
20313              !o3 && (i3.outside && O + e4 < I.left && (I.left = O + e4), !o3 && i3.outside && I.left + s3 > I.right && (I.right = O + e4));
20314            }), R.forEach(function(t4) {
20315              let {
20316                x: e4,
20317                anchorX: s3,
20318                anchorY: o3,
20319                pos: r3,
20320                point: {
20321                  isHeader: a3
20322                }
20323              } = t4, n3 = {
20324                visibility: void 0 === r3 ? "hidden" : "inherit",
20325                x: e4,
20326                y: (r3 || 0) + D2,
20327                anchorX: s3,
20328                anchorY: o3
20329              };
20330              if (i3.outside && e4 < s3) {
20331                let t5 = O - I.left;
20332                t5 > 0 && (a3 || (n3.x = e4 + t5, n3.anchorX = s3 + t5), a3 && (n3.x = (I.right - I.left) / 2, n3.anchorX = s3 + t5));
20333              }
20334              t4.tt.attr(n3);
20335            });
20336            let {
20337              container: z,
20338              outside: G,
20339              renderer: N
20340            } = i3;
20341            if (G && z && N) {
20342              let {
20343                width: t4,
20344                height: e4,
20345                x: i4,
20346                y: s3
20347              } = w2.getBBox();
20348              N.setSize(t4 + i4, e4 + s3, false), z.style.left = I.left + "px", z.style.top = L + "px";
20349            }
20350            c && w2.attr({
20351              opacity: 1 === w2.opacity ? 0.999 : 1
20352            });
20353          }
20354          drawTracker() {
20355            if (!this.shouldStickOnContact()) {
20356              this.tracker && (this.tracker = this.tracker.destroy());
20357              return;
20358            }
20359            let t3 = this.chart, e3 = this.label, i3 = this.shared ? t3.hoverPoints : t3.hoverPoint;
20360            if (!e3 || !i3) return;
20361            let s2 = {
20362              x: 0,
20363              y: 0,
20364              width: 0,
20365              height: 0
20366            }, o2 = this.getAnchor(i3), r2 = e3.getBBox();
20367            o2[0] += t3.plotLeft - (e3.translateX || 0), o2[1] += t3.plotTop - (e3.translateY || 0), s2.x = Math.min(0, o2[0]), s2.y = Math.min(0, o2[1]), s2.width = o2[0] < 0 ? Math.max(Math.abs(o2[0]), r2.width - o2[0]) : Math.max(Math.abs(o2[0]), r2.width), s2.height = o2[1] < 0 ? Math.max(Math.abs(o2[1]), r2.height - Math.abs(o2[1])) : Math.max(Math.abs(o2[1]), r2.height), this.tracker ? this.tracker.attr(s2) : (this.tracker = e3.renderer.rect(s2).addClass("highcharts-tracker").add(e3), t3.styledMode || this.tracker.attr({
20368              fill: "rgba(0,0,0,0)"
20369            }));
20370          }
20371          styledModeFormat(t3) {
20372            return t3.replace('style="font-size: 0.8em"', 'class="highcharts-header"').replace(/style="color:{(point|series)\.color}"/g, 'class="highcharts-color-{$1.colorIndex} {series.options.className} {point.options.className}"');
20373          }
20374          tooltipFooterHeaderFormatter(t3, e3) {
20375            let i3 = t3.series, s2 = i3.tooltipOptions, o2 = i3.xAxis, r2 = o2 && o2.dateTime, a2 = {
20376              isFooter: e3,
20377              labelConfig: t3
20378            }, n2 = s2.xDateFormat, h2 = s2[e3 ? "footerFormat" : "headerFormat"];
20379            return y(this, "headerFormatter", a2, function(e4) {
20380              r2 && !n2 && v(t3.key) && (n2 = r2.getXDateFormat(t3.key, s2.dateTimeLabelFormats)), r2 && n2 && (t3.point && t3.point.tooltipDateKeys || ["key"]).forEach(function(t4) {
20381                h2 = h2.replace("{point." + t4 + "}", "{point." + t4 + ":" + n2 + "}");
20382              }), i3.chart.styledMode && (h2 = this.styledModeFormat(h2)), e4.text = l(h2, {
20383                point: t3,
20384                series: i3
20385              }, this.chart);
20386            }), a2.text;
20387          }
20388          update(t3) {
20389            this.destroy(), this.init(this.chart, k(true, this.options, t3));
20390          }
20391          updatePosition(t3) {
20392            let {
20393              chart: e3,
20394              container: i3,
20395              distance: s2,
20396              options: o2,
20397              pointer: r2,
20398              renderer: a2
20399            } = this, {
20400              height: n2 = 0,
20401              width: l2 = 0
20402            } = this.getLabel(), {
20403              left: h2,
20404              top: d2,
20405              scaleX: c2,
20406              scaleY: p2
20407            } = r2.getChartPosition(), u12 = (o2.positioner || this.getPosition).call(this, l2, n2, t3), g2 = (t3.plotX || 0) + e3.plotLeft, m2 = (t3.plotY || 0) + e3.plotTop, x2;
20408            a2 && i3 && (o2.positioner && (u12.x += h2 - s2, u12.y += d2 - s2), x2 = (o2.borderWidth || 0) + 2 * s2 + 2, a2.setSize(l2 + x2, n2 + x2, false), (1 !== c2 || 1 !== p2) && (f(i3, {
20409              transform: `scale(${c2}, ${p2})`
20410            }), g2 *= c2, m2 *= p2), g2 += h2 - u12.x, m2 += d2 - u12.y), this.move(Math.round(u12.x), Math.round(u12.y || 0), g2, m2);
20411          }
20412        }
20413        return (a = T2 || (T2 = {})).compose = function(t3) {
20414          C(h, "Core.Tooltip") && u11(t3, "afterInit", function() {
20415            let t4 = this.chart;
20416            t4.options.tooltip && (t4.tooltip = new a(t4, t4.options.tooltip, this));
20417          });
20418        }, T2;
20419      }), i(e, "Core/Series/Point.js", [e["Core/Renderer/HTML/AST.js"], e["Core/Animation/AnimationUtilities.js"], e["Core/Defaults.js"], e["Core/Templating.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o) {
20420        let {
20421          animObject: r
20422        } = e2, {
20423          defaultOptions: a
20424        } = i2, {
20425          format: n
20426        } = s, {
20427          addEvent: l,
20428          crisp: h,
20429          erase: d,
20430          extend: c,
20431          fireEvent: p,
20432          getNestedProperty: u11,
20433          isArray: g,
20434          isFunction: f,
20435          isNumber: m,
20436          isObject: x,
20437          merge: y,
20438          pick: b,
20439          syncTimeout: v,
20440          removeEvent: S2,
20441          uniqueKey: k
20442        } = o;
20443        class M {
20444          animateBeforeDestroy() {
20445            let t3 = this, e3 = {
20446              x: t3.startXPos,
20447              opacity: 0
20448            }, i3 = t3.getGraphicalProps();
20449            i3.singular.forEach(function(i4) {
20450              t3[i4] = t3[i4].animate("dataLabel" === i4 ? {
20451                x: t3[i4].startXPos,
20452                y: t3[i4].startYPos,
20453                opacity: 0
20454              } : e3);
20455            }), i3.plural.forEach(function(e4) {
20456              t3[e4].forEach(function(e5) {
20457                e5.element && e5.animate(c({
20458                  x: t3.startXPos
20459                }, e5.startYPos ? {
20460                  x: e5.startXPos,
20461                  y: e5.startYPos
20462                } : {}));
20463              });
20464            });
20465          }
20466          applyOptions(t3, e3) {
20467            let i3 = this.series, s2 = i3.options.pointValKey || i3.pointValKey;
20468            return c(this, t3 = M.prototype.optionsToObject.call(this, t3)), this.options = this.options ? c(this.options, t3) : t3, t3.group && delete this.group, t3.dataLabels && delete this.dataLabels, s2 && (this.y = M.prototype.getNestedProperty.call(this, s2)), this.selected && (this.state = "select"), "name" in this && void 0 === e3 && i3.xAxis && i3.xAxis.hasNames && (this.x = i3.xAxis.nameToX(this)), void 0 === this.x && i3 ? this.x = e3 ?? i3.autoIncrement() : m(t3.x) && i3.options.relativeXValue && (this.x = i3.autoIncrement(t3.x)), this.isNull = this.isValid && !this.isValid(), this.formatPrefix = this.isNull ? "null" : "point", this;
20469          }
20470          destroy() {
20471            if (!this.destroyed) {
20472              let t3 = this, e3 = t3.series, i3 = e3.chart, s2 = e3.options.dataSorting, o2 = i3.hoverPoints, a2 = r(t3.series.chart.renderer.globalAnimation), n2 = () => {
20473                for (let e4 in (t3.graphic || t3.graphics || t3.dataLabel || t3.dataLabels) && (S2(t3), t3.destroyElements()), t3) delete t3[e4];
20474              };
20475              t3.legendItem && i3.legend.destroyItem(t3), o2 && (t3.setState(), d(o2, t3), o2.length || (i3.hoverPoints = null)), t3 === i3.hoverPoint && t3.onMouseOut(), s2 && s2.enabled ? (this.animateBeforeDestroy(), v(n2, a2.duration)) : n2(), i3.pointCount--;
20476            }
20477            this.destroyed = true;
20478          }
20479          destroyElements(t3) {
20480            let e3 = this, i3 = e3.getGraphicalProps(t3);
20481            i3.singular.forEach(function(t4) {
20482              e3[t4] = e3[t4].destroy();
20483            }), i3.plural.forEach(function(t4) {
20484              e3[t4].forEach(function(t5) {
20485                t5 && t5.element && t5.destroy();
20486              }), delete e3[t4];
20487            });
20488          }
20489          firePointEvent(t3, e3, i3) {
20490            let s2 = this, o2 = this.series.options;
20491            s2.manageEvent(t3), "click" === t3 && o2.allowPointSelect && (i3 = function(t4) {
20492              !s2.destroyed && s2.select && s2.select(null, t4.ctrlKey || t4.metaKey || t4.shiftKey);
20493            }), p(s2, t3, e3, i3);
20494          }
20495          getClassName() {
20496            return "highcharts-point" + (this.selected ? " highcharts-point-select" : "") + (this.negative ? " highcharts-negative" : "") + (this.isNull ? " highcharts-null-point" : "") + (void 0 !== this.colorIndex ? " highcharts-color-" + this.colorIndex : "") + (this.options.className ? " " + this.options.className : "") + (this.zone && this.zone.className ? " " + this.zone.className.replace("highcharts-negative", "") : "");
20497          }
20498          getGraphicalProps(t3) {
20499            let e3, i3;
20500            let s2 = this, o2 = [], r2 = {
20501              singular: [],
20502              plural: []
20503            };
20504            for ((t3 = t3 || {
20505              graphic: 1,
20506              dataLabel: 1
20507            }).graphic && o2.push("graphic", "connector"), t3.dataLabel && o2.push("dataLabel", "dataLabelPath", "dataLabelUpper"), i3 = o2.length; i3--; ) s2[e3 = o2[i3]] && r2.singular.push(e3);
20508            return ["graphic", "dataLabel"].forEach(function(e4) {
20509              let i4 = e4 + "s";
20510              t3[e4] && s2[i4] && r2.plural.push(i4);
20511            }), r2;
20512          }
20513          getLabelConfig() {
20514            return {
20515              x: this.category,
20516              y: this.y,
20517              color: this.color,
20518              colorIndex: this.colorIndex,
20519              key: this.name || this.category,
20520              series: this.series,
20521              point: this,
20522              percentage: this.percentage,
20523              total: this.total || this.stackTotal
20524            };
20525          }
20526          getNestedProperty(t3) {
20527            return t3 ? 0 === t3.indexOf("custom.") ? u11(t3, this.options) : this[t3] : void 0;
20528          }
20529          getZone() {
20530            let t3 = this.series, e3 = t3.zones, i3 = t3.zoneAxis || "y", s2, o2 = 0;
20531            for (s2 = e3[0]; this[i3] >= s2.value; ) s2 = e3[++o2];
20532            return this.nonZonedColor || (this.nonZonedColor = this.color), s2 && s2.color && !this.options.color ? this.color = s2.color : this.color = this.nonZonedColor, s2;
20533          }
20534          hasNewShapeType() {
20535            return (this.graphic && (this.graphic.symbolName || this.graphic.element.nodeName)) !== this.shapeType;
20536          }
20537          constructor(t3, e3, i3) {
20538            this.formatPrefix = "point", this.visible = true, this.series = t3, this.applyOptions(e3, i3), this.id ?? (this.id = k()), this.resolveColor(), t3.chart.pointCount++, p(this, "afterInit");
20539          }
20540          isValid() {
20541            return (m(this.x) || this.x instanceof Date) && m(this.y);
20542          }
20543          optionsToObject(t3) {
20544            let e3 = this.series, i3 = e3.options.keys, s2 = i3 || e3.pointArrayMap || ["y"], o2 = s2.length, r2 = {}, a2, n2 = 0, l2 = 0;
20545            if (m(t3) || null === t3) r2[s2[0]] = t3;
20546            else if (g(t3)) for (!i3 && t3.length > o2 && ("string" == (a2 = typeof t3[0]) ? r2.name = t3[0] : "number" === a2 && (r2.x = t3[0]), n2++); l2 < o2; ) i3 && void 0 === t3[n2] || (s2[l2].indexOf(".") > 0 ? M.prototype.setNestedProperty(r2, t3[n2], s2[l2]) : r2[s2[l2]] = t3[n2]), n2++, l2++;
20547            else "object" == typeof t3 && (r2 = t3, t3.dataLabels && (e3.hasDataLabels = () => true), t3.marker && (e3._hasPointMarkers = true));
20548            return r2;
20549          }
20550          pos(t3, e3 = this.plotY) {
20551            if (!this.destroyed) {
20552              let {
20553                plotX: i3,
20554                series: s2
20555              } = this, {
20556                chart: o2,
20557                xAxis: r2,
20558                yAxis: a2
20559              } = s2, n2 = 0, l2 = 0;
20560              if (m(i3) && m(e3)) return t3 && (n2 = r2 ? r2.pos : o2.plotLeft, l2 = a2 ? a2.pos : o2.plotTop), o2.inverted && r2 && a2 ? [a2.len - e3 + l2, r2.len - i3 + n2] : [i3 + n2, e3 + l2];
20561            }
20562          }
20563          resolveColor() {
20564            let t3 = this.series, e3 = t3.chart.options.chart, i3 = t3.chart.styledMode, s2, o2, r2 = e3.colorCount, a2;
20565            delete this.nonZonedColor, t3.options.colorByPoint ? (i3 || (s2 = (o2 = t3.options.colors || t3.chart.options.colors)[t3.colorCounter], r2 = o2.length), a2 = t3.colorCounter, t3.colorCounter++, t3.colorCounter === r2 && (t3.colorCounter = 0)) : (i3 || (s2 = t3.color), a2 = t3.colorIndex), this.colorIndex = b(this.options.colorIndex, a2), this.color = b(this.options.color, s2);
20566          }
20567          setNestedProperty(t3, e3, i3) {
20568            return i3.split(".").reduce(function(t4, i4, s2, o2) {
20569              let r2 = o2.length - 1 === s2;
20570              return t4[i4] = r2 ? e3 : x(t4[i4], true) ? t4[i4] : {}, t4[i4];
20571            }, t3), t3;
20572          }
20573          shouldDraw() {
20574            return !this.isNull;
20575          }
20576          tooltipFormatter(t3) {
20577            let e3 = this.series, i3 = e3.tooltipOptions, s2 = b(i3.valueDecimals, ""), o2 = i3.valuePrefix || "", r2 = i3.valueSuffix || "";
20578            return e3.chart.styledMode && (t3 = e3.chart.tooltip.styledModeFormat(t3)), (e3.pointArrayMap || ["y"]).forEach(function(e4) {
20579              e4 = "{point." + e4, (o2 || r2) && (t3 = t3.replace(RegExp(e4 + "}", "g"), o2 + e4 + "}" + r2)), t3 = t3.replace(RegExp(e4 + "}", "g"), e4 + ":,." + s2 + "f}");
20580            }), n(t3, {
20581              point: this,
20582              series: this.series
20583            }, e3.chart);
20584          }
20585          update(t3, e3, i3, s2) {
20586            let o2;
20587            let r2 = this, a2 = r2.series, n2 = r2.graphic, l2 = a2.chart, h2 = a2.options;
20588            function d2() {
20589              r2.applyOptions(t3);
20590              let s3 = n2 && r2.hasMockGraphic, d3 = null === r2.y ? !s3 : s3;
20591              n2 && d3 && (r2.graphic = n2.destroy(), delete r2.hasMockGraphic), x(t3, true) && (n2 && n2.element && t3 && t3.marker && void 0 !== t3.marker.symbol && (r2.graphic = n2.destroy()), t3?.dataLabels && r2.dataLabel && (r2.dataLabel = r2.dataLabel.destroy())), o2 = r2.index, a2.updateParallelArrays(r2, o2), h2.data[o2] = x(h2.data[o2], true) || x(t3, true) ? r2.options : b(t3, h2.data[o2]), a2.isDirty = a2.isDirtyData = true, !a2.fixedBox && a2.hasCartesianSeries && (l2.isDirtyBox = true), "point" === h2.legendType && (l2.isDirtyLegend = true), e3 && l2.redraw(i3);
20592            }
20593            e3 = b(e3, true), false === s2 ? d2() : r2.firePointEvent("update", {
20594              options: t3
20595            }, d2);
20596          }
20597          remove(t3, e3) {
20598            this.series.removePoint(this.series.data.indexOf(this), t3, e3);
20599          }
20600          select(t3, e3) {
20601            let i3 = this, s2 = i3.series, o2 = s2.chart;
20602            t3 = b(t3, !i3.selected), this.selectedStaging = t3, i3.firePointEvent(t3 ? "select" : "unselect", {
20603              accumulate: e3
20604            }, function() {
20605              i3.selected = i3.options.selected = t3, s2.options.data[s2.data.indexOf(i3)] = i3.options, i3.setState(t3 && "select"), e3 || o2.getSelectedPoints().forEach(function(t4) {
20606                let e4 = t4.series;
20607                t4.selected && t4 !== i3 && (t4.selected = t4.options.selected = false, e4.options.data[e4.data.indexOf(t4)] = t4.options, t4.setState(o2.hoverPoints && e4.options.inactiveOtherPoints ? "inactive" : ""), t4.firePointEvent("unselect"));
20608              });
20609            }), delete this.selectedStaging;
20610          }
20611          onMouseOver(t3) {
20612            let {
20613              inverted: e3,
20614              pointer: i3
20615            } = this.series.chart;
20616            i3 && (t3 = t3 ? i3.normalize(t3) : i3.getChartCoordinatesFromPoint(this, e3), i3.runPointActions(t3, this));
20617          }
20618          onMouseOut() {
20619            let t3 = this.series.chart;
20620            this.firePointEvent("mouseOut"), this.series.options.inactiveOtherPoints || (t3.hoverPoints || []).forEach(function(t4) {
20621              t4.setState();
20622            }), t3.hoverPoints = t3.hoverPoint = null;
20623          }
20624          manageEvent(t3) {
20625            let e3 = y(this.series.options.point, this.options), i3 = e3.events?.[t3];
20626            f(i3) && (!this.hcEvents?.[t3] || this.hcEvents?.[t3]?.map((t4) => t4.fn).indexOf(i3) === -1) ? (this.importedUserEvent?.(), this.importedUserEvent = l(this, t3, i3)) : this.importedUserEvent && !i3 && this.hcEvents?.[t3] && (S2(this, t3), delete this.hcEvents[t3], Object.keys(this.hcEvents) || delete this.importedUserEvent);
20627          }
20628          setState(e3, i3) {
20629            let s2 = this.series, o2 = this.state, r2 = s2.options.states[e3 || "normal"] || {}, n2 = a.plotOptions[s2.type].marker && s2.options.marker, l2 = n2 && false === n2.enabled, h2 = n2 && n2.states && n2.states[e3 || "normal"] || {}, d2 = false === h2.enabled, u12 = this.marker || {}, g2 = s2.chart, f2 = n2 && s2.markerAttribs, x2 = s2.halo, y2, v2, S3, k2 = s2.stateMarkerGraphic, M2;
20630            if ((e3 = e3 || "") === this.state && !i3 || this.selected && "select" !== e3 || false === r2.enabled || e3 && (d2 || l2 && false === h2.enabled) || e3 && u12.states && u12.states[e3] && false === u12.states[e3].enabled) return;
20631            if (this.state = e3, f2 && (y2 = s2.markerAttribs(this, e3)), this.graphic && !this.hasMockGraphic) {
20632              if (o2 && this.graphic.removeClass("highcharts-point-" + o2), e3 && this.graphic.addClass("highcharts-point-" + e3), !g2.styledMode) {
20633                v2 = s2.pointAttribs(this, e3), S3 = b(g2.options.chart.animation, r2.animation);
20634                let t3 = v2.opacity;
20635                s2.options.inactiveOtherPoints && m(t3) && (this.dataLabels || []).forEach(function(e4) {
20636                  e4 && !e4.hasClass("highcharts-data-label-hidden") && (e4.animate({
20637                    opacity: t3
20638                  }, S3), e4.connector && e4.connector.animate({
20639                    opacity: t3
20640                  }, S3));
20641                }), this.graphic.animate(v2, S3);
20642              }
20643              y2 && this.graphic.animate(y2, b(g2.options.chart.animation, h2.animation, n2.animation)), k2 && k2.hide();
20644            } else e3 && h2 && (M2 = u12.symbol || s2.symbol, k2 && k2.currentSymbol !== M2 && (k2 = k2.destroy()), y2 && (k2 ? k2[i3 ? "animate" : "attr"]({
20645              x: y2.x,
20646              y: y2.y
20647            }) : M2 && (s2.stateMarkerGraphic = k2 = g2.renderer.symbol(M2, y2.x, y2.y, y2.width, y2.height).add(s2.markerGroup), k2.currentSymbol = M2)), !g2.styledMode && k2 && "inactive" !== this.state && k2.attr(s2.pointAttribs(this, e3))), k2 && (k2[e3 && this.isInside ? "show" : "hide"](), k2.element.point = this, k2.addClass(this.getClassName(), true));
20648            let C = r2.halo, A = this.graphic || k2, w = A && A.visibility || "inherit";
20649            C && C.size && A && "hidden" !== w && !this.isCluster ? (x2 || (s2.halo = x2 = g2.renderer.path().add(A.parentGroup)), x2.show()[i3 ? "animate" : "attr"]({
20650              d: this.haloPath(C.size)
20651            }), x2.attr({
20652              class: "highcharts-halo highcharts-color-" + b(this.colorIndex, s2.colorIndex) + (this.className ? " " + this.className : ""),
20653              visibility: w,
20654              zIndex: -1
20655            }), x2.point = this, g2.styledMode || x2.attr(c({
20656              fill: this.color || s2.color,
20657              "fill-opacity": C.opacity
20658            }, t2.filterUserAttributes(C.attributes || {})))) : x2?.point?.haloPath && !x2.point.destroyed && x2.animate({
20659              d: x2.point.haloPath(0)
20660            }, null, x2.hide), p(this, "afterSetState", {
20661              state: e3
20662            });
20663          }
20664          haloPath(t3) {
20665            let e3 = this.pos();
20666            return e3 ? this.series.chart.renderer.symbols.circle(h(e3[0], 1) - t3, e3[1] - t3, 2 * t3, 2 * t3) : [];
20667          }
20668        }
20669        return M;
20670      }), i(e, "Core/Pointer.js", [e["Core/Color/Color.js"], e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
20671        var s;
20672        let {
20673          parse: o
20674        } = t2, {
20675          charts: r,
20676          composed: a,
20677          isTouchDevice: n
20678        } = e2, {
20679          addEvent: l,
20680          attr: h,
20681          css: d,
20682          extend: c,
20683          find: p,
20684          fireEvent: u11,
20685          isNumber: g,
20686          isObject: f,
20687          objectEach: m,
20688          offset: x,
20689          pick: y,
20690          pushUnique: b,
20691          splat: v
20692        } = i2;
20693        class S2 {
20694          applyInactiveState(t3) {
20695            let e3 = [], i3;
20696            (t3 || []).forEach(function(t4) {
20697              i3 = t4.series, e3.push(i3), i3.linkedParent && e3.push(i3.linkedParent), i3.linkedSeries && (e3 = e3.concat(i3.linkedSeries)), i3.navigatorSeries && e3.push(i3.navigatorSeries);
20698            }), this.chart.series.forEach(function(t4) {
20699              -1 === e3.indexOf(t4) ? t4.setState("inactive", true) : t4.options.inactiveOtherPoints && t4.setAllPointsToState("inactive");
20700            });
20701          }
20702          destroy() {
20703            let t3 = this;
20704            this.eventsToUnbind.forEach((t4) => t4()), this.eventsToUnbind = [], !e2.chartCount && (S2.unbindDocumentMouseUp && S2.unbindDocumentMouseUp.forEach((t4) => t4()), S2.unbindDocumentTouchEnd && (S2.unbindDocumentTouchEnd = S2.unbindDocumentTouchEnd())), clearInterval(t3.tooltipTimeout), m(t3, function(e3, i3) {
20705              t3[i3] = void 0;
20706            });
20707          }
20708          getSelectionMarkerAttrs(t3, e3) {
20709            let i3 = {
20710              args: {
20711                chartX: t3,
20712                chartY: e3
20713              },
20714              attrs: {},
20715              shapeType: "rect"
20716            };
20717            return u11(this, "getSelectionMarkerAttrs", i3, (i4) => {
20718              let s2;
20719              let {
20720                chart: o2,
20721                zoomHor: r2,
20722                zoomVert: a2
20723              } = this, {
20724                mouseDownX: n2 = 0,
20725                mouseDownY: l2 = 0
20726              } = o2, h2 = i4.attrs;
20727              h2.x = o2.plotLeft, h2.y = o2.plotTop, h2.width = r2 ? 1 : o2.plotWidth, h2.height = a2 ? 1 : o2.plotHeight, r2 && (s2 = t3 - n2, h2.width = Math.max(1, Math.abs(s2)), h2.x = (s2 > 0 ? 0 : s2) + n2), a2 && (s2 = e3 - l2, h2.height = Math.max(1, Math.abs(s2)), h2.y = (s2 > 0 ? 0 : s2) + l2);
20728            }), i3;
20729          }
20730          drag(t3) {
20731            let {
20732              chart: e3
20733            } = this, {
20734              mouseDownX: i3 = 0,
20735              mouseDownY: s2 = 0
20736            } = e3, {
20737              panning: r2,
20738              panKey: a2,
20739              selectionMarkerFill: n2
20740            } = e3.options.chart, l2 = e3.plotLeft, h2 = e3.plotTop, d2 = e3.plotWidth, c2 = e3.plotHeight, p2 = f(r2) ? r2.enabled : r2, u12 = a2 && t3[`${a2}Key`], g2 = t3.chartX, m2 = t3.chartY, x2, y2 = this.selectionMarker;
20741            if ((!y2 || !y2.touch) && (g2 < l2 ? g2 = l2 : g2 > l2 + d2 && (g2 = l2 + d2), m2 < h2 ? m2 = h2 : m2 > h2 + c2 && (m2 = h2 + c2), this.hasDragged = Math.sqrt(Math.pow(i3 - g2, 2) + Math.pow(s2 - m2, 2)), this.hasDragged > 10)) {
20742              x2 = e3.isInsidePlot(i3 - l2, s2 - h2, {
20743                visiblePlotOnly: true
20744              });
20745              let {
20746                shapeType: a3,
20747                attrs: d3
20748              } = this.getSelectionMarkerAttrs(g2, m2);
20749              (e3.hasCartesianSeries || e3.mapView) && this.hasZoom && x2 && !u12 && !y2 && (this.selectionMarker = y2 = e3.renderer[a3](), y2.attr({
20750                class: "highcharts-selection-marker",
20751                zIndex: 7
20752              }).add(), e3.styledMode || y2.attr({
20753                fill: n2 || o("#334eff").setOpacity(0.25).get()
20754              })), y2 && y2.attr(d3), x2 && !y2 && p2 && e3.pan(t3, r2);
20755            }
20756          }
20757          dragStart(t3) {
20758            let e3 = this.chart;
20759            e3.mouseIsDown = t3.type, e3.cancelClick = false, e3.mouseDownX = t3.chartX, e3.mouseDownY = t3.chartY;
20760          }
20761          getSelectionBox(t3) {
20762            let e3 = {
20763              args: {
20764                marker: t3
20765              },
20766              result: t3.getBBox()
20767            };
20768            return u11(this, "getSelectionBox", e3), e3.result;
20769          }
20770          drop(t3) {
20771            let e3;
20772            let {
20773              chart: i3,
20774              selectionMarker: s2
20775            } = this;
20776            for (let t4 of i3.axes) t4.isPanning && (t4.isPanning = false, (t4.options.startOnTick || t4.options.endOnTick || t4.series.some((t5) => t5.boosted)) && (t4.forceRedraw = true, t4.setExtremes(t4.userMin, t4.userMax, false), e3 = true));
20777            if (e3 && i3.redraw(), s2 && t3) {
20778              if (this.hasDragged) {
20779                let e4 = this.getSelectionBox(s2);
20780                i3.transform({
20781                  axes: i3.axes.filter((t4) => t4.zoomEnabled && ("xAxis" === t4.coll && this.zoomX || "yAxis" === t4.coll && this.zoomY)),
20782                  selection: __spreadValues({
20783                    originalEvent: t3,
20784                    xAxis: [],
20785                    yAxis: []
20786                  }, e4),
20787                  from: e4
20788                });
20789              }
20790              g(i3.index) && (this.selectionMarker = s2.destroy());
20791            }
20792            i3 && g(i3.index) && (d(i3.container, {
20793              cursor: i3._cursor
20794            }), i3.cancelClick = this.hasDragged > 10, i3.mouseIsDown = false, this.hasDragged = 0, this.pinchDown = []);
20795          }
20796          findNearestKDPoint(t3, e3, i3) {
20797            let s2;
20798            return t3.forEach(function(t4) {
20799              let o2 = !(t4.noSharedTooltip && e3) && 0 > t4.options.findNearestPointBy.indexOf("y"), r2 = t4.searchPoint(i3, o2);
20800              f(r2, true) && r2.series && (!f(s2, true) || function(t5, i4) {
20801                let s3 = t5.distX - i4.distX, o3 = t5.dist - i4.dist, r3 = i4.series.group?.zIndex - t5.series.group?.zIndex;
20802                return 0 !== s3 && e3 ? s3 : 0 !== o3 ? o3 : 0 !== r3 ? r3 : t5.series.index > i4.series.index ? -1 : 1;
20803              }(s2, r2) > 0) && (s2 = r2);
20804            }), s2;
20805          }
20806          getChartCoordinatesFromPoint(t3, e3) {
20807            let {
20808              xAxis: i3,
20809              yAxis: s2
20810            } = t3.series, o2 = t3.shapeArgs;
20811            if (i3 && s2) {
20812              let r2 = t3.clientX ?? t3.plotX ?? 0, a2 = t3.plotY || 0;
20813              return t3.isNode && o2 && g(o2.x) && g(o2.y) && (r2 = o2.x, a2 = o2.y), e3 ? {
20814                chartX: s2.len + s2.pos - a2,
20815                chartY: i3.len + i3.pos - r2
20816              } : {
20817                chartX: r2 + i3.pos,
20818                chartY: a2 + s2.pos
20819              };
20820            }
20821            if (o2 && o2.x && o2.y) return {
20822              chartX: o2.x,
20823              chartY: o2.y
20824            };
20825          }
20826          getChartPosition() {
20827            if (this.chartPosition) return this.chartPosition;
20828            let {
20829              container: t3
20830            } = this.chart, e3 = x(t3);
20831            this.chartPosition = {
20832              left: e3.left,
20833              top: e3.top,
20834              scaleX: 1,
20835              scaleY: 1
20836            };
20837            let {
20838              offsetHeight: i3,
20839              offsetWidth: s2
20840            } = t3;
20841            return s2 > 2 && i3 > 2 && (this.chartPosition.scaleX = e3.width / s2, this.chartPosition.scaleY = e3.height / i3), this.chartPosition;
20842          }
20843          getCoordinates(t3) {
20844            let e3 = {
20845              xAxis: [],
20846              yAxis: []
20847            };
20848            for (let i3 of this.chart.axes) e3[i3.isXAxis ? "xAxis" : "yAxis"].push({
20849              axis: i3,
20850              value: i3.toValue(t3[i3.horiz ? "chartX" : "chartY"])
20851            });
20852            return e3;
20853          }
20854          getHoverData(t3, e3, i3, s2, o2, r2) {
20855            let a2 = [], n2 = function(t4) {
20856              return t4.visible && !(!o2 && t4.directTouch) && y(t4.options.enableMouseTracking, true);
20857            }, l2 = e3, h2, d2 = {
20858              chartX: r2 ? r2.chartX : void 0,
20859              chartY: r2 ? r2.chartY : void 0,
20860              shared: o2
20861            };
20862            u11(this, "beforeGetHoverData", d2), h2 = l2 && !l2.stickyTracking ? [l2] : i3.filter((t4) => t4.stickyTracking && (d2.filter || n2)(t4));
20863            let c2 = s2 && t3 || !r2 ? t3 : this.findNearestKDPoint(h2, o2, r2);
20864            return l2 = c2 && c2.series, c2 && (o2 && !l2.noSharedTooltip ? (h2 = i3.filter(function(t4) {
20865              return d2.filter ? d2.filter(t4) : n2(t4) && !t4.noSharedTooltip;
20866            })).forEach(function(t4) {
20867              let e4 = p(t4.points, function(t5) {
20868                return t5.x === c2.x && !t5.isNull;
20869              });
20870              f(e4) && (t4.boosted && t4.boost && (e4 = t4.boost.getPoint(e4)), a2.push(e4));
20871            }) : a2.push(c2)), u11(this, "afterGetHoverData", d2 = {
20872              hoverPoint: c2
20873            }), {
20874              hoverPoint: d2.hoverPoint,
20875              hoverSeries: l2,
20876              hoverPoints: a2
20877            };
20878          }
20879          getPointFromEvent(t3) {
20880            let e3 = t3.target, i3;
20881            for (; e3 && !i3; ) i3 = e3.point, e3 = e3.parentNode;
20882            return i3;
20883          }
20884          onTrackerMouseOut(t3) {
20885            let e3 = this.chart, i3 = t3.relatedTarget, s2 = e3.hoverSeries;
20886            this.isDirectTouch = false, !s2 || !i3 || s2.stickyTracking || this.inClass(i3, "highcharts-tooltip") || this.inClass(i3, "highcharts-series-" + s2.index) && this.inClass(i3, "highcharts-tracker") || s2.onMouseOut();
20887          }
20888          inClass(t3, e3) {
20889            let i3 = t3, s2;
20890            for (; i3; ) {
20891              if (s2 = h(i3, "class")) {
20892                if (-1 !== s2.indexOf(e3)) return true;
20893                if (-1 !== s2.indexOf("highcharts-container")) return false;
20894              }
20895              i3 = i3.parentElement;
20896            }
20897          }
20898          constructor(t3, e3) {
20899            this.hasDragged = 0, this.pointerCaptureEventsToUnbind = [], this.eventsToUnbind = [], this.options = e3, this.chart = t3, this.runChartClick = !!e3.chart.events?.click, this.pinchDown = [], this.setDOMEvents(), u11(this, "afterInit");
20900          }
20901          normalize(t3, e3) {
20902            let i3 = t3.touches, s2 = i3 ? i3.length ? i3.item(0) : y(i3.changedTouches, t3.changedTouches)[0] : t3;
20903            e3 || (e3 = this.getChartPosition());
20904            let o2 = s2.pageX - e3.left, r2 = s2.pageY - e3.top;
20905            return c(t3, {
20906              chartX: Math.round(o2 /= e3.scaleX),
20907              chartY: Math.round(r2 /= e3.scaleY)
20908            });
20909          }
20910          onContainerClick(t3) {
20911            let e3 = this.chart, i3 = e3.hoverPoint, s2 = this.normalize(t3), o2 = e3.plotLeft, r2 = e3.plotTop;
20912            !e3.cancelClick && (i3 && this.inClass(s2.target, "highcharts-tracker") ? (u11(i3.series, "click", c(s2, {
20913              point: i3
20914            })), e3.hoverPoint && i3.firePointEvent("click", s2)) : (c(s2, this.getCoordinates(s2)), e3.isInsidePlot(s2.chartX - o2, s2.chartY - r2, {
20915              visiblePlotOnly: true
20916            }) && u11(e3, "click", s2)));
20917          }
20918          onContainerMouseDown(t3) {
20919            let i3 = (1 & (t3.buttons || t3.button)) == 1;
20920            t3 = this.normalize(t3), e2.isFirefox && 0 !== t3.button && this.onContainerMouseMove(t3), (void 0 === t3.button || i3) && (this.zoomOption(t3), i3 && t3.preventDefault?.(), this.dragStart(t3));
20921          }
20922          onContainerMouseLeave(t3) {
20923            let {
20924              pointer: e3
20925            } = r[y(S2.hoverChartIndex, -1)] || {};
20926            t3 = this.normalize(t3), this.onContainerMouseMove(t3), e3 && !this.inClass(t3.relatedTarget, "highcharts-tooltip") && (e3.reset(), e3.chartPosition = void 0);
20927          }
20928          onContainerMouseEnter() {
20929            delete this.chartPosition;
20930          }
20931          onContainerMouseMove(t3) {
20932            let e3 = this.chart, i3 = e3.tooltip, s2 = this.normalize(t3);
20933            this.setHoverChartIndex(t3), ("mousedown" === e3.mouseIsDown || this.touchSelect(s2)) && this.drag(s2), !e3.openMenu && (this.inClass(s2.target, "highcharts-tracker") || e3.isInsidePlot(s2.chartX - e3.plotLeft, s2.chartY - e3.plotTop, {
20934              visiblePlotOnly: true
20935            })) && !(i3 && i3.shouldStickOnContact(s2)) && (this.inClass(s2.target, "highcharts-no-tooltip") ? this.reset(false, 0) : this.runPointActions(s2));
20936          }
20937          onDocumentTouchEnd(t3) {
20938            this.onDocumentMouseUp(t3);
20939          }
20940          onContainerTouchMove(t3) {
20941            this.touchSelect(t3) ? this.onContainerMouseMove(t3) : this.touch(t3);
20942          }
20943          onContainerTouchStart(t3) {
20944            this.touchSelect(t3) ? this.onContainerMouseDown(t3) : (this.zoomOption(t3), this.touch(t3, true));
20945          }
20946          onDocumentMouseMove(t3) {
20947            let e3 = this.chart, i3 = e3.tooltip, s2 = this.chartPosition, o2 = this.normalize(t3, s2);
20948            !s2 || e3.isInsidePlot(o2.chartX - e3.plotLeft, o2.chartY - e3.plotTop, {
20949              visiblePlotOnly: true
20950            }) || i3 && i3.shouldStickOnContact(o2) || o2.target !== e3.container.ownerDocument && this.inClass(o2.target, "highcharts-tracker") || this.reset();
20951          }
20952          onDocumentMouseUp(t3) {
20953            r[y(S2.hoverChartIndex, -1)]?.pointer?.drop(t3);
20954          }
20955          pinch(t3) {
20956            let e3 = this, {
20957              chart: i3,
20958              hasZoom: s2,
20959              lastTouches: o2
20960            } = e3, r2 = [].map.call(t3.touches || [], (t4) => e3.normalize(t4)), a2 = r2.length, n2 = 1 === a2 && (e3.inClass(t3.target, "highcharts-tracker") && i3.runTrackerClick || e3.runChartClick), l2 = i3.tooltip, h2 = 1 === a2 && y(l2?.options.followTouchMove, true);
20961            a2 > 1 ? e3.initiated = true : h2 && (e3.initiated = false), s2 && e3.initiated && !n2 && false !== t3.cancelable && t3.preventDefault(), "touchstart" === t3.type ? (e3.pinchDown = r2, e3.res = true, i3.mouseDownX = t3.chartX) : h2 ? this.runPointActions(e3.normalize(t3)) : o2 && (u11(i3, "touchpan", {
20962              originalEvent: t3,
20963              touches: r2
20964            }, () => {
20965              let e4 = (t4) => {
20966                let e5 = t4[0], i4 = t4[1] || e5;
20967                return {
20968                  x: e5.chartX,
20969                  y: e5.chartY,
20970                  width: i4.chartX - e5.chartX,
20971                  height: i4.chartY - e5.chartY
20972                };
20973              };
20974              i3.transform({
20975                axes: i3.axes.filter((t4) => t4.zoomEnabled && (this.zoomHor && t4.horiz || this.zoomVert && !t4.horiz)),
20976                to: e4(r2),
20977                from: e4(o2),
20978                trigger: t3.type
20979              });
20980            }), e3.res && (e3.res = false, this.reset(false, 0))), e3.lastTouches = r2;
20981          }
20982          reset(t3, e3) {
20983            let i3 = this.chart, s2 = i3.hoverSeries, o2 = i3.hoverPoint, r2 = i3.hoverPoints, a2 = i3.tooltip, n2 = a2 && a2.shared ? r2 : o2;
20984            t3 && n2 && v(n2).forEach(function(e4) {
20985              e4.series.isCartesian && void 0 === e4.plotX && (t3 = false);
20986            }), t3 ? a2 && n2 && v(n2).length && (a2.refresh(n2), a2.shared && r2 ? r2.forEach(function(t4) {
20987              t4.setState(t4.state, true), t4.series.isCartesian && (t4.series.xAxis.crosshair && t4.series.xAxis.drawCrosshair(null, t4), t4.series.yAxis.crosshair && t4.series.yAxis.drawCrosshair(null, t4));
20988            }) : o2 && (o2.setState(o2.state, true), i3.axes.forEach(function(t4) {
20989              t4.crosshair && o2.series[t4.coll] === t4 && t4.drawCrosshair(null, o2);
20990            }))) : (o2 && o2.onMouseOut(), r2 && r2.forEach(function(t4) {
20991              t4.setState();
20992            }), s2 && s2.onMouseOut(), a2 && a2.hide(e3), this.unDocMouseMove && (this.unDocMouseMove = this.unDocMouseMove()), i3.axes.forEach(function(t4) {
20993              t4.hideCrosshair();
20994            }), i3.hoverPoints = i3.hoverPoint = void 0);
20995          }
20996          runPointActions(t3, e3, i3) {
20997            let s2 = this.chart, o2 = s2.series, a2 = s2.tooltip && s2.tooltip.options.enabled ? s2.tooltip : void 0, n2 = !!a2 && a2.shared, h2 = e3 || s2.hoverPoint, d2 = h2 && h2.series || s2.hoverSeries, c2 = (!t3 || "touchmove" !== t3.type) && (!!e3 || d2 && d2.directTouch && this.isDirectTouch), u12 = this.getHoverData(h2, d2, o2, c2, n2, t3);
20998            h2 = u12.hoverPoint, d2 = u12.hoverSeries;
20999            let g2 = u12.hoverPoints, f2 = d2 && d2.tooltipOptions.followPointer && !d2.tooltipOptions.split, m2 = n2 && d2 && !d2.noSharedTooltip;
21000            if (h2 && (i3 || h2 !== s2.hoverPoint || a2 && a2.isHidden)) {
21001              if ((s2.hoverPoints || []).forEach(function(t4) {
21002                -1 === g2.indexOf(t4) && t4.setState();
21003              }), s2.hoverSeries !== d2 && d2.onMouseOver(), this.applyInactiveState(g2), (g2 || []).forEach(function(t4) {
21004                t4.setState("hover");
21005              }), s2.hoverPoint && s2.hoverPoint.firePointEvent("mouseOut"), !h2.series) return;
21006              s2.hoverPoints = g2, s2.hoverPoint = h2, h2.firePointEvent("mouseOver", void 0, () => {
21007                a2 && h2 && a2.refresh(m2 ? g2 : h2, t3);
21008              });
21009            } else if (f2 && a2 && !a2.isHidden) {
21010              let e4 = a2.getAnchor([{}], t3);
21011              s2.isInsidePlot(e4[0], e4[1], {
21012                visiblePlotOnly: true
21013              }) && a2.updatePosition({
21014                plotX: e4[0],
21015                plotY: e4[1]
21016              });
21017            }
21018            this.unDocMouseMove || (this.unDocMouseMove = l(s2.container.ownerDocument, "mousemove", (t4) => r[S2.hoverChartIndex ?? -1]?.pointer?.onDocumentMouseMove(t4)), this.eventsToUnbind.push(this.unDocMouseMove)), s2.axes.forEach(function(e4) {
21019              let i4;
21020              let o3 = y((e4.crosshair || {}).snap, true);
21021              !o3 || (i4 = s2.hoverPoint) && i4.series[e4.coll] === e4 || (i4 = p(g2, (t4) => t4.series && t4.series[e4.coll] === e4)), i4 || !o3 ? e4.drawCrosshair(t3, i4) : e4.hideCrosshair();
21022            });
21023          }
21024          setDOMEvents() {
21025            let t3 = this.chart.container, e3 = t3.ownerDocument;
21026            t3.onmousedown = this.onContainerMouseDown.bind(this), t3.onmousemove = this.onContainerMouseMove.bind(this), t3.onclick = this.onContainerClick.bind(this), this.eventsToUnbind.push(l(t3, "mouseenter", this.onContainerMouseEnter.bind(this)), l(t3, "mouseleave", this.onContainerMouseLeave.bind(this))), S2.unbindDocumentMouseUp || (S2.unbindDocumentMouseUp = []), S2.unbindDocumentMouseUp.push(l(e3, "mouseup", this.onDocumentMouseUp.bind(this)));
21027            let i3 = this.chart.renderTo.parentElement;
21028            for (; i3 && "BODY" !== i3.tagName; ) this.eventsToUnbind.push(l(i3, "scroll", () => {
21029              delete this.chartPosition;
21030            })), i3 = i3.parentElement;
21031            this.eventsToUnbind.push(l(t3, "touchstart", this.onContainerTouchStart.bind(this), {
21032              passive: false
21033            }), l(t3, "touchmove", this.onContainerTouchMove.bind(this), {
21034              passive: false
21035            })), S2.unbindDocumentTouchEnd || (S2.unbindDocumentTouchEnd = l(e3, "touchend", this.onDocumentTouchEnd.bind(this), {
21036              passive: false
21037            })), this.setPointerCapture(), l(this.chart, "redraw", this.setPointerCapture.bind(this));
21038          }
21039          setPointerCapture() {
21040            if (!n) return;
21041            let t3 = this.pointerCaptureEventsToUnbind, e3 = this.chart, i3 = e3.container, s2 = y(e3.options.tooltip?.followTouchMove, true) && e3.series.some((t4) => t4.options.findNearestPointBy.indexOf("y") > -1);
21042            !this.hasPointerCapture && s2 ? (t3.push(l(i3, "pointerdown", (t4) => {
21043              t4.target?.hasPointerCapture(t4.pointerId) && t4.target?.releasePointerCapture(t4.pointerId);
21044            }), l(i3, "pointermove", (t4) => {
21045              e3.pointer?.getPointFromEvent(t4)?.onMouseOver(t4);
21046            })), e3.styledMode || d(i3, {
21047              "touch-action": "none"
21048            }), i3.className += " highcharts-no-touch-action", this.hasPointerCapture = true) : this.hasPointerCapture && !s2 && (t3.forEach((t4) => t4()), t3.length = 0, e3.styledMode || d(i3, {
21049              "touch-action": y(e3.options.chart.style?.["touch-action"], "manipulation")
21050            }), i3.className = i3.className.replace(" highcharts-no-touch-action", ""), this.hasPointerCapture = false);
21051          }
21052          setHoverChartIndex(t3) {
21053            let i3 = this.chart, s2 = e2.charts[y(S2.hoverChartIndex, -1)];
21054            if (s2 && s2 !== i3) {
21055              let e3 = {
21056                relatedTarget: i3.container
21057              };
21058              t3 && !t3?.relatedTarget && (t3 = __spreadValues(__spreadValues({}, e3), t3)), s2.pointer?.onContainerMouseLeave(t3 || e3);
21059            }
21060            s2 && s2.mouseIsDown || (S2.hoverChartIndex = i3.index);
21061          }
21062          touch(t3, e3) {
21063            let i3;
21064            let {
21065              chart: s2,
21066              pinchDown: o2 = []
21067            } = this;
21068            this.setHoverChartIndex(), 1 === (t3 = this.normalize(t3)).touches.length ? s2.isInsidePlot(t3.chartX - s2.plotLeft, t3.chartY - s2.plotTop, {
21069              visiblePlotOnly: true
21070            }) && !s2.openMenu ? (e3 && this.runPointActions(t3), "touchmove" === t3.type && (i3 = !!o2[0] && Math.pow(o2[0].chartX - t3.chartX, 2) + Math.pow(o2[0].chartY - t3.chartY, 2) >= 16), y(i3, true) && this.pinch(t3)) : e3 && this.reset() : 2 === t3.touches.length && this.pinch(t3);
21071          }
21072          touchSelect(t3) {
21073            return !!(this.chart.zooming.singleTouch && t3.touches && 1 === t3.touches.length);
21074          }
21075          zoomOption(t3) {
21076            let e3 = this.chart, i3 = e3.inverted, s2 = e3.zooming.type || "", o2, r2;
21077            /touch/.test(t3.type) && (s2 = y(e3.zooming.pinchType, s2)), this.zoomX = o2 = /x/.test(s2), this.zoomY = r2 = /y/.test(s2), this.zoomHor = o2 && !i3 || r2 && i3, this.zoomVert = r2 && !i3 || o2 && i3, this.hasZoom = o2 || r2;
21078          }
21079        }
21080        return (s = S2 || (S2 = {})).compose = function(t3) {
21081          b(a, "Core.Pointer") && l(t3, "beforeRender", function() {
21082            this.pointer = new s(this, this.options);
21083          });
21084        }, S2;
21085      }), i(e, "Core/Legend/LegendSymbol.js", [e["Core/Utilities.js"]], function(t2) {
21086        var e2;
21087        let {
21088          extend: i2,
21089          merge: s,
21090          pick: o
21091        } = t2;
21092        return function(t3) {
21093          function e3(t4, e4, r) {
21094            let a = this.legendItem = this.legendItem || {}, {
21095              chart: n,
21096              options: l
21097            } = this, {
21098              baseline: h = 0,
21099              symbolWidth: d,
21100              symbolHeight: c
21101            } = t4, p = this.symbol || "circle", u11 = c / 2, g = n.renderer, f = a.group, m = h - Math.round((t4.fontMetrics?.b || c) * (r ? 0.4 : 0.3)), x = {}, y, b = l.marker, v = 0;
21102            if (n.styledMode || (x["stroke-width"] = Math.min(l.lineWidth || 0, 24), l.dashStyle ? x.dashstyle = l.dashStyle : "square" === l.linecap || (x["stroke-linecap"] = "round")), a.line = g.path().addClass("highcharts-graph").attr(x).add(f), r && (a.area = g.path().addClass("highcharts-area").add(f)), x["stroke-linecap"] && (v = Math.min(a.line.strokeWidth(), d) / 2), d) {
21103              let t5 = [["M", v, m], ["L", d - v, m]];
21104              a.line.attr({
21105                d: t5
21106              }), a.area?.attr({
21107                d: [...t5, ["L", d - v, h], ["L", v, h]]
21108              });
21109            }
21110            if (b && false !== b.enabled && d) {
21111              let t5 = Math.min(o(b.radius, u11), u11);
21112              0 === p.indexOf("url") && (b = s(b, {
21113                width: c,
21114                height: c
21115              }), t5 = 0), a.symbol = y = g.symbol(p, d / 2 - t5, m - t5, 2 * t5, 2 * t5, i2({
21116                context: "legend"
21117              }, b)).addClass("highcharts-point").add(f), y.isMarker = true;
21118            }
21119          }
21120          t3.areaMarker = function(t4, i3) {
21121            e3.call(this, t4, i3, true);
21122          }, t3.lineMarker = e3, t3.rectangle = function(t4, e4) {
21123            let i3 = e4.legendItem || {}, s2 = t4.options, r = t4.symbolHeight, a = s2.squareSymbol, n = a ? r : t4.symbolWidth;
21124            i3.symbol = this.chart.renderer.rect(a ? (t4.symbolWidth - r) / 2 : 0, t4.baseline - r + 1, n, r, o(t4.options.symbolRadius, r / 2)).addClass("highcharts-point").attr({
21125              zIndex: 3
21126            }).add(i3.group);
21127          };
21128        }(e2 || (e2 = {})), e2;
21129      }), i(e, "Core/Series/SeriesDefaults.js", [], function() {
21130        return {
21131          lineWidth: 2,
21132          allowPointSelect: false,
21133          crisp: true,
21134          showCheckbox: false,
21135          animation: {
21136            duration: 1e3
21137          },
21138          enableMouseTracking: true,
21139          events: {},
21140          marker: {
21141            enabledThreshold: 2,
21142            lineColor: "#ffffff",
21143            lineWidth: 0,
21144            radius: 4,
21145            states: {
21146              normal: {
21147                animation: true
21148              },
21149              hover: {
21150                animation: {
21151                  duration: 150
21152                },
21153                enabled: true,
21154                radiusPlus: 2,
21155                lineWidthPlus: 1
21156              },
21157              select: {
21158                fillColor: "#cccccc",
21159                lineColor: "#000000",
21160                lineWidth: 2
21161              }
21162            }
21163          },
21164          point: {
21165            events: {}
21166          },
21167          dataLabels: {
21168            animation: {},
21169            align: "center",
21170            borderWidth: 0,
21171            defer: true,
21172            formatter: function() {
21173              let {
21174                numberFormatter: t2
21175              } = this.series.chart;
21176              return "number" != typeof this.y ? "" : t2(this.y, -1);
21177            },
21178            padding: 5,
21179            style: {
21180              fontSize: "0.7em",
21181              fontWeight: "bold",
21182              color: "contrast",
21183              textOutline: "1px contrast"
21184            },
21185            verticalAlign: "bottom",
21186            x: 0,
21187            y: 0
21188          },
21189          cropThreshold: 300,
21190          opacity: 1,
21191          pointRange: 0,
21192          softThreshold: true,
21193          states: {
21194            normal: {
21195              animation: true
21196            },
21197            hover: {
21198              animation: {
21199                duration: 150
21200              },
21201              lineWidthPlus: 1,
21202              marker: {},
21203              halo: {
21204                size: 10,
21205                opacity: 0.25
21206              }
21207            },
21208            select: {
21209              animation: {
21210                duration: 0
21211              }
21212            },
21213            inactive: {
21214              animation: {
21215                duration: 150
21216              },
21217              opacity: 0.2
21218            }
21219          },
21220          stickyTracking: true,
21221          turboThreshold: 1e3,
21222          findNearestPointBy: "x"
21223        };
21224      }), i(e, "Core/Series/SeriesRegistry.js", [e["Core/Globals.js"], e["Core/Defaults.js"], e["Core/Series/Point.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
21225        var o;
21226        let {
21227          defaultOptions: r
21228        } = e2, {
21229          extend: a,
21230          extendClass: n,
21231          merge: l
21232        } = s;
21233        return function(e3) {
21234          function s2(t3, s3) {
21235            let o2 = r.plotOptions || {}, a2 = s3.defaultOptions, n2 = s3.prototype;
21236            return n2.type = t3, n2.pointClass || (n2.pointClass = i2), !e3.seriesTypes[t3] && (a2 && (o2[t3] = a2), e3.seriesTypes[t3] = s3, true);
21237          }
21238          e3.seriesTypes = t2.seriesTypes, e3.registerSeriesType = s2, e3.seriesType = function(t3, o2, h, d, c) {
21239            let p = r.plotOptions || {};
21240            if (o2 = o2 || "", p[t3] = l(p[o2], h), delete e3.seriesTypes[t3], s2(t3, n(e3.seriesTypes[o2] || function() {
21241            }, d)), e3.seriesTypes[t3].prototype.type = t3, c) {
21242              class s3 extends i2 {
21243              }
21244              a(s3.prototype, c), e3.seriesTypes[t3].prototype.pointClass = s3;
21245            }
21246            return e3.seriesTypes[t3];
21247          };
21248        }(o || (o = {})), o;
21249      }), i(e, "Core/Series/Series.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Defaults.js"], e["Core/Foundation.js"], e["Core/Globals.js"], e["Core/Legend/LegendSymbol.js"], e["Core/Series/Point.js"], e["Core/Series/SeriesDefaults.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Renderer/SVG/SVGElement.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o, r, a, n, l, h) {
21250        let {
21251          animObject: d,
21252          setAnimation: c
21253        } = t2, {
21254          defaultOptions: p
21255        } = e2, {
21256          registerEventOptions: u11
21257        } = i2, {
21258          svg: g,
21259          win: f
21260        } = s, {
21261          seriesTypes: m
21262        } = n, {
21263          arrayMax: x,
21264          arrayMin: y,
21265          clamp: b,
21266          correctFloat: v,
21267          crisp: S2,
21268          defined: k,
21269          destroyObjectProperties: M,
21270          diffObjects: C,
21271          erase: A,
21272          error: w,
21273          extend: T2,
21274          find: P,
21275          fireEvent: O,
21276          getClosestDistance: L,
21277          getNestedProperty: D2,
21278          insertItem: E,
21279          isArray: B,
21280          isNumber: j,
21281          isString: R,
21282          merge: I,
21283          objectEach: z,
21284          pick: G,
21285          removeEvent: N,
21286          splat: W,
21287          syncTimeout: H
21288        } = h;
21289        class X {
21290          constructor() {
21291            this.zoneAxis = "y";
21292          }
21293          init(t3, e3) {
21294            let i3;
21295            O(this, "init", {
21296              options: e3
21297            });
21298            let s2 = this, o2 = t3.series;
21299            this.eventsToUnbind = [], s2.chart = t3, s2.options = s2.setOptions(e3);
21300            let r2 = s2.options, a2 = false !== r2.visible;
21301            s2.linkedSeries = [], s2.bindAxes(), T2(s2, {
21302              name: r2.name,
21303              state: "",
21304              visible: a2,
21305              selected: true === r2.selected
21306            }), u11(this, r2);
21307            let n2 = r2.events;
21308            (n2 && n2.click || r2.point && r2.point.events && r2.point.events.click || r2.allowPointSelect) && (t3.runTrackerClick = true), s2.getColor(), s2.getSymbol(), s2.parallelArrays.forEach(function(t4) {
21309              s2[t4 + "Data"] || (s2[t4 + "Data"] = []);
21310            }), s2.isCartesian && (t3.hasCartesianSeries = true), o2.length && (i3 = o2[o2.length - 1]), s2._i = G(i3 && i3._i, -1) + 1, s2.opacity = s2.options.opacity, t3.orderItems("series", E(this, o2)), r2.dataSorting && r2.dataSorting.enabled ? s2.setDataSortingOptions() : s2.points || s2.data || s2.setData(r2.data, false), O(this, "afterInit");
21311          }
21312          is(t3) {
21313            return m[t3] && this instanceof m[t3];
21314          }
21315          bindAxes() {
21316            let t3;
21317            let e3 = this, i3 = e3.options, s2 = e3.chart;
21318            O(this, "bindAxes", null, function() {
21319              (e3.axisTypes || []).forEach(function(o2) {
21320                (s2[o2] || []).forEach(function(s3) {
21321                  t3 = s3.options, (G(i3[o2], 0) === s3.index || void 0 !== i3[o2] && i3[o2] === t3.id) && (E(e3, s3.series), e3[o2] = s3, s3.isDirty = true);
21322                }), e3[o2] || e3.optionalAxis === o2 || w(18, true, s2);
21323              });
21324            }), O(this, "afterBindAxes");
21325          }
21326          updateParallelArrays(t3, e3, i3) {
21327            let s2 = t3.series, o2 = j(e3) ? function(i4) {
21328              let o3 = "y" === i4 && s2.toYData ? s2.toYData(t3) : t3[i4];
21329              s2[i4 + "Data"][e3] = o3;
21330            } : function(t4) {
21331              Array.prototype[e3].apply(s2[t4 + "Data"], i3);
21332            };
21333            s2.parallelArrays.forEach(o2);
21334          }
21335          hasData() {
21336            return this.visible && void 0 !== this.dataMax && void 0 !== this.dataMin || this.visible && this.yData && this.yData.length > 0;
21337          }
21338          hasMarkerChanged(t3, e3) {
21339            let i3 = t3.marker, s2 = e3.marker || {};
21340            return i3 && (s2.enabled && !i3.enabled || s2.symbol !== i3.symbol || s2.height !== i3.height || s2.width !== i3.width);
21341          }
21342          autoIncrement(t3) {
21343            let e3 = this.options, i3 = e3.pointIntervalUnit, s2 = e3.relativeXValue, o2 = this.chart.time, r2 = this.xIncrement, a2, n2;
21344            return (r2 = G(r2, e3.pointStart, 0), this.pointInterval = n2 = G(this.pointInterval, e3.pointInterval, 1), s2 && j(t3) && (n2 *= t3), i3 && (a2 = new o2.Date(r2), "day" === i3 ? o2.set("Date", a2, o2.get("Date", a2) + n2) : "month" === i3 ? o2.set("Month", a2, o2.get("Month", a2) + n2) : "year" === i3 && o2.set("FullYear", a2, o2.get("FullYear", a2) + n2), n2 = a2.getTime() - r2), s2 && j(t3)) ? r2 + n2 : (this.xIncrement = r2 + n2, r2);
21345          }
21346          setDataSortingOptions() {
21347            let t3 = this.options;
21348            T2(this, {
21349              requireSorting: false,
21350              sorted: false,
21351              enabledDataSorting: true,
21352              allowDG: false
21353            }), k(t3.pointRange) || (t3.pointRange = 1);
21354          }
21355          setOptions(t3) {
21356            let e3;
21357            let i3 = this.chart, s2 = i3.options.plotOptions, o2 = i3.userOptions || {}, r2 = I(t3), a2 = i3.styledMode, n2 = {
21358              plotOptions: s2,
21359              userOptions: r2
21360            };
21361            O(this, "setOptions", n2);
21362            let l2 = n2.plotOptions[this.type], h2 = o2.plotOptions || {}, d2 = h2.series || {}, c2 = p.plotOptions[this.type] || {}, u12 = h2[this.type] || {};
21363            this.userOptions = n2.userOptions;
21364            let g2 = I(l2, s2.series, u12, r2);
21365            this.tooltipOptions = I(p.tooltip, p.plotOptions.series?.tooltip, c2?.tooltip, i3.userOptions.tooltip, h2.series?.tooltip, u12.tooltip, r2.tooltip), this.stickyTracking = G(r2.stickyTracking, u12.stickyTracking, d2.stickyTracking, !!this.tooltipOptions.shared && !this.noSharedTooltip || g2.stickyTracking), null === l2.marker && delete g2.marker, this.zoneAxis = g2.zoneAxis || "y";
21366            let f2 = this.zones = (g2.zones || []).map((t4) => __spreadValues({}, t4));
21367            return (g2.negativeColor || g2.negativeFillColor) && !g2.zones && (e3 = {
21368              value: g2[this.zoneAxis + "Threshold"] || g2.threshold || 0,
21369              className: "highcharts-negative"
21370            }, a2 || (e3.color = g2.negativeColor, e3.fillColor = g2.negativeFillColor), f2.push(e3)), f2.length && k(f2[f2.length - 1].value) && f2.push(a2 ? {} : {
21371              color: this.color,
21372              fillColor: this.fillColor
21373            }), O(this, "afterSetOptions", {
21374              options: g2
21375            }), g2;
21376          }
21377          getName() {
21378            return G(this.options.name, "Series " + (this.index + 1));
21379          }
21380          getCyclic(t3, e3, i3) {
21381            let s2, o2;
21382            let r2 = this.chart, a2 = `${t3}Index`, n2 = `${t3}Counter`, l2 = i3?.length || r2.options.chart.colorCount;
21383            !e3 && (k(o2 = G("color" === t3 ? this.options.colorIndex : void 0, this[a2])) ? s2 = o2 : (r2.series.length || (r2[n2] = 0), s2 = r2[n2] % l2, r2[n2] += 1), i3 && (e3 = i3[s2])), void 0 !== s2 && (this[a2] = s2), this[t3] = e3;
21384          }
21385          getColor() {
21386            this.chart.styledMode ? this.getCyclic("color") : this.options.colorByPoint ? this.color = "#cccccc" : this.getCyclic("color", this.options.color || p.plotOptions[this.type].color, this.chart.options.colors);
21387          }
21388          getPointsCollection() {
21389            return (this.hasGroupedData ? this.points : this.data) || [];
21390          }
21391          getSymbol() {
21392            let t3 = this.options.marker;
21393            this.getCyclic("symbol", t3.symbol, this.chart.options.symbols);
21394          }
21395          findPointIndex(t3, e3) {
21396            let i3, s2, o2;
21397            let a2 = t3.id, n2 = t3.x, l2 = this.points, h2 = this.options.dataSorting;
21398            if (a2) {
21399              let t4 = this.chart.get(a2);
21400              t4 instanceof r && (i3 = t4);
21401            } else if (this.linkedParent || this.enabledDataSorting || this.options.relativeXValue) {
21402              let e4 = (e5) => !e5.touched && e5.index === t3.index;
21403              if (h2 && h2.matchByName ? e4 = (e5) => !e5.touched && e5.name === t3.name : this.options.relativeXValue && (e4 = (e5) => !e5.touched && e5.options.x === t3.x), !(i3 = P(l2, e4))) return;
21404            }
21405            return i3 && void 0 !== (o2 = i3 && i3.index) && (s2 = true), void 0 === o2 && j(n2) && (o2 = this.xData.indexOf(n2, e3)), -1 !== o2 && void 0 !== o2 && this.cropped && (o2 = o2 >= this.cropStart ? o2 - this.cropStart : o2), !s2 && j(o2) && l2[o2] && l2[o2].touched && (o2 = void 0), o2;
21406          }
21407          updateData(t3, e3) {
21408            let i3 = this.options, s2 = i3.dataSorting, o2 = this.points, r2 = [], a2 = this.requireSorting, n2 = t3.length === o2.length, l2, h2, d2, c2, p2 = true;
21409            if (this.xIncrement = null, t3.forEach(function(t4, e4) {
21410              let h3;
21411              let d3 = k(t4) && this.pointClass.prototype.optionsToObject.call({
21412                series: this
21413              }, t4) || {}, p3 = d3.x;
21414              d3.id || j(p3) ? (-1 === (h3 = this.findPointIndex(d3, c2)) || void 0 === h3 ? r2.push(t4) : o2[h3] && t4 !== i3.data[h3] ? (o2[h3].update(t4, false, null, false), o2[h3].touched = true, a2 && (c2 = h3 + 1)) : o2[h3] && (o2[h3].touched = true), (!n2 || e4 !== h3 || s2 && s2.enabled || this.hasDerivedData) && (l2 = true)) : r2.push(t4);
21415            }, this), l2) for (h2 = o2.length; h2--; ) (d2 = o2[h2]) && !d2.touched && d2.remove && d2.remove(false, e3);
21416            else !n2 || s2 && s2.enabled ? p2 = false : (t3.forEach(function(t4, e4) {
21417              t4 === o2[e4].y || o2[e4].destroyed || o2[e4].update(t4, false, null, false);
21418            }), r2.length = 0);
21419            return o2.forEach(function(t4) {
21420              t4 && (t4.touched = false);
21421            }), !!p2 && (r2.forEach(function(t4) {
21422              this.addPoint(t4, false, null, null, false);
21423            }, this), null === this.xIncrement && this.xData && this.xData.length && (this.xIncrement = x(this.xData), this.autoIncrement()), true);
21424          }
21425          setData(t3, e3 = true, i3, s2) {
21426            let o2 = this, r2 = o2.points, a2 = r2 && r2.length || 0, n2 = o2.options, l2 = o2.chart, h2 = n2.dataSorting, d2 = o2.xAxis, c2 = n2.turboThreshold, p2 = this.xData, u12 = this.yData, g2 = o2.pointArrayMap, f2 = g2 && g2.length, m2 = n2.keys, x2, y2, b2, v2 = 0, S3 = 1, k2;
21427            l2.options.chart.allowMutatingData || (n2.data && delete o2.options.data, o2.userOptions.data && delete o2.userOptions.data, k2 = I(true, t3));
21428            let M2 = (t3 = k2 || t3 || []).length;
21429            if (h2 && h2.enabled && (t3 = this.sortData(t3)), l2.options.chart.allowMutatingData && false !== s2 && M2 && a2 && !o2.cropped && !o2.hasGroupedData && o2.visible && !o2.boosted && (b2 = this.updateData(t3, i3)), !b2) {
21430              o2.xIncrement = null, o2.colorCounter = 0, this.parallelArrays.forEach(function(t4) {
21431                o2[t4 + "Data"].length = 0;
21432              });
21433              let e4 = c2 && M2 > c2;
21434              if (e4) {
21435                let i4 = o2.getFirstValidPoint(t3), s3 = o2.getFirstValidPoint(t3, M2 - 1, -1), r3 = (t4) => !!(B(t4) && (m2 || j(t4[0])));
21436                if (j(i4) && j(s3)) for (x2 = 0; x2 < M2; x2++) p2[x2] = this.autoIncrement(), u12[x2] = t3[x2];
21437                else if (r3(i4) && r3(s3)) {
21438                  if (f2) {
21439                    if (i4.length === f2) for (x2 = 0; x2 < M2; x2++) p2[x2] = this.autoIncrement(), u12[x2] = t3[x2];
21440                    else for (x2 = 0; x2 < M2; x2++) y2 = t3[x2], p2[x2] = y2[0], u12[x2] = y2.slice(1, f2 + 1);
21441                  } else if (m2 && (v2 = m2.indexOf("x"), S3 = m2.indexOf("y"), v2 = v2 >= 0 ? v2 : 0, S3 = S3 >= 0 ? S3 : 1), 1 === i4.length && (S3 = 0), v2 === S3) for (x2 = 0; x2 < M2; x2++) p2[x2] = this.autoIncrement(), u12[x2] = t3[x2][S3];
21442                  else for (x2 = 0; x2 < M2; x2++) y2 = t3[x2], p2[x2] = y2[v2], u12[x2] = y2[S3];
21443                } else e4 = false;
21444              }
21445              if (!e4) for (x2 = 0; x2 < M2; x2++) y2 = {
21446                series: o2
21447              }, o2.pointClass.prototype.applyOptions.apply(y2, [t3[x2]]), o2.updateParallelArrays(y2, x2);
21448              for (u12 && R(u12[0]) && w(14, true, l2), o2.data = [], o2.options.data = o2.userOptions.data = t3, x2 = a2; x2--; ) r2[x2]?.destroy();
21449              d2 && (d2.minRange = d2.userMinRange), o2.isDirty = l2.isDirtyBox = true, o2.isDirtyData = !!r2, i3 = false;
21450            }
21451            "point" === n2.legendType && (this.processData(), this.generatePoints()), e3 && l2.redraw(i3);
21452          }
21453          sortData(t3) {
21454            let e3 = this, i3 = e3.options.dataSorting.sortKey || "y", s2 = function(t4, e4) {
21455              return k(e4) && t4.pointClass.prototype.optionsToObject.call({
21456                series: t4
21457              }, e4) || {};
21458            };
21459            return t3.forEach(function(i4, o2) {
21460              t3[o2] = s2(e3, i4), t3[o2].index = o2;
21461            }, this), t3.concat().sort((t4, e4) => {
21462              let s3 = D2(i3, t4), o2 = D2(i3, e4);
21463              return o2 < s3 ? -1 : o2 > s3 ? 1 : 0;
21464            }).forEach(function(t4, e4) {
21465              t4.x = e4;
21466            }, this), e3.linkedSeries && e3.linkedSeries.forEach(function(e4) {
21467              let i4 = e4.options, o2 = i4.data;
21468              i4.dataSorting && i4.dataSorting.enabled || !o2 || (o2.forEach(function(i5, r2) {
21469                o2[r2] = s2(e4, i5), t3[r2] && (o2[r2].x = t3[r2].x, o2[r2].index = r2);
21470              }), e4.setData(o2, false));
21471            }), t3;
21472          }
21473          getProcessedData(t3) {
21474            let e3 = this, i3 = e3.xAxis, s2 = e3.options.cropThreshold, o2 = i3?.logarithmic, r2 = e3.isCartesian, a2, n2, l2 = 0, h2, d2, c2, p2 = e3.xData, u12 = e3.yData, g2 = false, f2 = p2.length;
21475            i3 && (d2 = (h2 = i3.getExtremes()).min, c2 = h2.max, g2 = !!(i3.categories && !i3.names.length)), r2 && e3.sorted && !t3 && (!s2 || f2 > s2 || e3.forceCrop) && (p2[f2 - 1] < d2 || p2[0] > c2 ? (p2 = [], u12 = []) : e3.yData && (p2[0] < d2 || p2[f2 - 1] > c2) && (p2 = (a2 = this.cropData(e3.xData, e3.yData, d2, c2)).xData, u12 = a2.yData, l2 = a2.start, n2 = true));
21476            let m2 = L([o2 ? p2.map(o2.log2lin) : p2], () => e3.requireSorting && !g2 && w(15, false, e3.chart));
21477            return {
21478              xData: p2,
21479              yData: u12,
21480              cropped: n2,
21481              cropStart: l2,
21482              closestPointRange: m2
21483            };
21484          }
21485          processData(t3) {
21486            let e3 = this.xAxis;
21487            if (this.isCartesian && !this.isDirty && !e3.isDirty && !this.yAxis.isDirty && !t3) return false;
21488            let i3 = this.getProcessedData();
21489            this.cropped = i3.cropped, this.cropStart = i3.cropStart, this.processedXData = i3.xData, this.processedYData = i3.yData, this.closestPointRange = this.basePointRange = i3.closestPointRange, O(this, "afterProcessData");
21490          }
21491          cropData(t3, e3, i3, s2) {
21492            let o2 = t3.length, r2, a2, n2 = 0, l2 = o2;
21493            for (r2 = 0; r2 < o2; r2++) if (t3[r2] >= i3) {
21494              n2 = Math.max(0, r2 - 1);
21495              break;
21496            }
21497            for (a2 = r2; a2 < o2; a2++) if (t3[a2] > s2) {
21498              l2 = a2 + 1;
21499              break;
21500            }
21501            return {
21502              xData: t3.slice(n2, l2),
21503              yData: e3.slice(n2, l2),
21504              start: n2,
21505              end: l2
21506            };
21507          }
21508          generatePoints() {
21509            let t3 = this.options, e3 = this.processedData || t3.data, i3 = this.processedXData, s2 = this.processedYData, o2 = this.pointClass, r2 = i3.length, a2 = this.cropStart || 0, n2 = this.hasGroupedData, l2 = t3.keys, h2 = [], d2 = t3.dataGrouping && t3.dataGrouping.groupAll ? a2 : 0, c2, p2, u12, g2, f2 = this.data;
21510            if (!f2 && !n2) {
21511              let t4 = [];
21512              t4.length = e3.length, f2 = this.data = t4;
21513            }
21514            for (l2 && n2 && (this.options.keys = false), g2 = 0; g2 < r2; g2++) p2 = a2 + g2, n2 ? ((u12 = new o2(this, [i3[g2]].concat(W(s2[g2])))).dataGroup = this.groupMap[d2 + g2], u12.dataGroup.options && (u12.options = u12.dataGroup.options, T2(u12, u12.dataGroup.options), delete u12.dataLabels)) : (u12 = f2[p2]) || void 0 === e3[p2] || (f2[p2] = u12 = new o2(this, e3[p2], i3[g2])), u12 && (u12.index = n2 ? d2 + g2 : p2, h2[g2] = u12);
21515            if (this.options.keys = l2, f2 && (r2 !== (c2 = f2.length) || n2)) for (g2 = 0; g2 < c2; g2++) g2 !== a2 || n2 || (g2 += r2), f2[g2] && (f2[g2].destroyElements(), f2[g2].plotX = void 0);
21516            this.data = f2, this.points = h2, O(this, "afterGeneratePoints");
21517          }
21518          getXExtremes(t3) {
21519            return {
21520              min: y(t3),
21521              max: x(t3)
21522            };
21523          }
21524          getExtremes(t3, e3) {
21525            let i3 = this.xAxis, s2 = this.yAxis, o2 = [], r2 = this.requireSorting && !this.is("column") ? 1 : 0, a2 = !!s2 && s2.positiveValuesOnly, n2 = e3 || this.getExtremesFromAll || this.options.getExtremesFromAll, {
21526              processedXData: l2,
21527              processedYData: h2
21528            } = this, d2, c2, p2, u12, g2, f2, m2, b2 = 0, v2 = 0, S3 = 0;
21529            if (this.cropped && n2) {
21530              let t4 = this.getProcessedData(true);
21531              l2 = t4.xData, h2 = t4.yData;
21532            }
21533            let k2 = (t3 = t3 || this.stackedYData || h2 || []).length, M2 = l2 || this.xData;
21534            for (i3 && (b2 = (d2 = i3.getExtremes()).min, v2 = d2.max), f2 = 0; f2 < k2; f2++) if (u12 = M2[f2], c2 = (j(g2 = t3[f2]) || B(g2)) && ((j(g2) ? g2 > 0 : g2.length) || !a2), p2 = e3 || this.getExtremesFromAll || this.options.getExtremesFromAll || this.cropped || !i3 || (M2[f2 + r2] || u12) >= b2 && (M2[f2 - r2] || u12) <= v2, c2 && p2) {
21535              if (m2 = g2.length) for (; m2--; ) j(g2[m2]) && (o2[S3++] = g2[m2]);
21536              else o2[S3++] = g2;
21537            }
21538            let C2 = {
21539              activeYData: o2,
21540              dataMin: y(o2),
21541              dataMax: x(o2)
21542            };
21543            return O(this, "afterGetExtremes", {
21544              dataExtremes: C2
21545            }), C2;
21546          }
21547          applyExtremes() {
21548            let t3 = this.getExtremes();
21549            return this.dataMin = t3.dataMin, this.dataMax = t3.dataMax, t3;
21550          }
21551          getFirstValidPoint(t3, e3 = 0, i3 = 1) {
21552            let s2 = t3.length, o2 = e3;
21553            for (; o2 >= 0 && o2 < s2; ) {
21554              if (k(t3[o2])) return t3[o2];
21555              o2 += i3;
21556            }
21557          }
21558          translate() {
21559            this.processedXData || this.processData(), this.generatePoints();
21560            let t3 = this.options, e3 = t3.stacking, i3 = this.xAxis, s2 = i3.categories, o2 = this.enabledDataSorting, r2 = this.yAxis, a2 = this.points, n2 = a2.length, l2 = this.pointPlacementToXValue(), h2 = !!l2, d2 = t3.threshold, c2 = t3.startFromThreshold ? d2 : 0, p2, u12, g2, f2, m2 = Number.MAX_VALUE;
21561            function x2(t4) {
21562              return b(t4, -1e9, 1e9);
21563            }
21564            for (p2 = 0; p2 < n2; p2++) {
21565              let t4;
21566              let n3 = a2[p2], y2 = n3.x, b2, S3, M2 = n3.y, C2 = n3.low, A2 = e3 && r2.stacking?.stacks[(this.negStacks && M2 < (c2 ? 0 : d2) ? "-" : "") + this.stackKey];
21567              u12 = i3.translate(y2, false, false, false, true, l2), n3.plotX = j(u12) ? v(x2(u12)) : void 0, e3 && this.visible && A2 && A2[y2] && (f2 = this.getStackIndicator(f2, y2, this.index), !n3.isNull && f2.key && (S3 = (b2 = A2[y2]).points[f2.key]), b2 && B(S3) && (C2 = S3[0], M2 = S3[1], C2 === c2 && f2.key === A2[y2].base && (C2 = G(j(d2) ? d2 : r2.min)), r2.positiveValuesOnly && k(C2) && C2 <= 0 && (C2 = void 0), n3.total = n3.stackTotal = G(b2.total), n3.percentage = k(n3.y) && b2.total ? n3.y / b2.total * 100 : void 0, n3.stackY = M2, this.irregularWidths || b2.setOffset(this.pointXOffset || 0, this.barW || 0, void 0, void 0, void 0, this.xAxis))), n3.yBottom = k(C2) ? x2(r2.translate(C2, false, true, false, true)) : void 0, this.dataModify && (M2 = this.dataModify.modifyValue(M2, p2)), j(M2) && void 0 !== n3.plotX && (t4 = j(t4 = r2.translate(M2, false, true, false, true)) ? x2(t4) : void 0), n3.plotY = t4, n3.isInside = this.isPointInside(n3), n3.clientX = h2 ? v(i3.translate(y2, false, false, false, true, l2)) : u12, n3.negative = (n3.y || 0) < (d2 || 0), n3.category = G(s2 && s2[n3.x], n3.x), n3.isNull || false === n3.visible || (void 0 !== g2 && (m2 = Math.min(m2, Math.abs(u12 - g2))), g2 = u12), n3.zone = this.zones.length ? n3.getZone() : void 0, !n3.graphic && this.group && o2 && (n3.isNew = true);
21568            }
21569            this.closestPointRangePx = m2, O(this, "afterTranslate");
21570          }
21571          getValidPoints(t3, e3, i3) {
21572            let s2 = this.chart;
21573            return (t3 || this.points || []).filter(function(t4) {
21574              let {
21575                plotX: o2,
21576                plotY: r2
21577              } = t4;
21578              return !!((i3 || !t4.isNull && j(r2)) && (!e3 || s2.isInsidePlot(o2, r2, {
21579                inverted: s2.inverted
21580              }))) && false !== t4.visible;
21581            });
21582          }
21583          getClipBox() {
21584            let {
21585              chart: t3,
21586              xAxis: e3,
21587              yAxis: i3
21588            } = this, {
21589              x: s2,
21590              y: o2,
21591              width: r2,
21592              height: a2
21593            } = I(t3.clipBox);
21594            return e3 && e3.len !== t3.plotSizeX && (r2 = e3.len), i3 && i3.len !== t3.plotSizeY && (a2 = i3.len), t3.inverted && !this.invertible && ([r2, a2] = [a2, r2]), {
21595              x: s2,
21596              y: o2,
21597              width: r2,
21598              height: a2
21599            };
21600          }
21601          getSharedClipKey() {
21602            return this.sharedClipKey = (this.options.xAxis || 0) + "," + (this.options.yAxis || 0), this.sharedClipKey;
21603          }
21604          setClip() {
21605            let {
21606              chart: t3,
21607              group: e3,
21608              markerGroup: i3
21609            } = this, s2 = t3.sharedClips, o2 = t3.renderer, r2 = this.getClipBox(), a2 = this.getSharedClipKey(), n2 = s2[a2];
21610            n2 ? n2.animate(r2) : s2[a2] = n2 = o2.clipRect(r2), e3 && e3.clip(false === this.options.clip ? void 0 : n2), i3 && i3.clip();
21611          }
21612          animate(t3) {
21613            let {
21614              chart: e3,
21615              group: i3,
21616              markerGroup: s2
21617            } = this, o2 = e3.inverted, r2 = d(this.options.animation), a2 = [this.getSharedClipKey(), r2.duration, r2.easing, r2.defer].join(","), n2 = e3.sharedClips[a2], l2 = e3.sharedClips[a2 + "m"];
21618            if (t3 && i3) {
21619              let t4 = this.getClipBox();
21620              if (n2) n2.attr("height", t4.height);
21621              else {
21622                t4.width = 0, o2 && (t4.x = e3.plotHeight), n2 = e3.renderer.clipRect(t4), e3.sharedClips[a2] = n2;
21623                let i4 = {
21624                  x: -99,
21625                  y: -99,
21626                  width: o2 ? e3.plotWidth + 199 : 99,
21627                  height: o2 ? 99 : e3.plotHeight + 199
21628                };
21629                l2 = e3.renderer.clipRect(i4), e3.sharedClips[a2 + "m"] = l2;
21630              }
21631              i3.clip(n2), s2?.clip(l2);
21632            } else if (n2 && !n2.hasClass("highcharts-animating")) {
21633              let t4 = this.getClipBox(), i4 = r2.step;
21634              (s2?.element.childNodes.length || e3.series.length > 1) && (r2.step = function(t5, e4) {
21635                i4 && i4.apply(e4, arguments), "width" === e4.prop && l2?.element && l2.attr(o2 ? "height" : "width", t5 + 99);
21636              }), n2.addClass("highcharts-animating").animate(t4, r2);
21637            }
21638          }
21639          afterAnimate() {
21640            this.setClip(), z(this.chart.sharedClips, (t3, e3, i3) => {
21641              t3 && !this.chart.container.querySelector(`[clip-path="url(#${t3.id})"]`) && (t3.destroy(), delete i3[e3]);
21642            }), this.finishedAnimating = true, O(this, "afterAnimate");
21643          }
21644          drawPoints(t3 = this.points) {
21645            let e3, i3, s2, o2, r2, a2, n2;
21646            let l2 = this.chart, h2 = l2.styledMode, {
21647              colorAxis: d2,
21648              options: c2
21649            } = this, p2 = c2.marker, u12 = this[this.specialGroup || "markerGroup"], g2 = this.xAxis, f2 = G(p2.enabled, !g2 || !!g2.isRadial || null, this.closestPointRangePx >= p2.enabledThreshold * p2.radius);
21650            if (false !== p2.enabled || this._hasPointMarkers) for (e3 = 0; e3 < t3.length; e3++) if (o2 = (s2 = (i3 = t3[e3]).graphic) ? "animate" : "attr", r2 = i3.marker || {}, a2 = !!i3.marker, (f2 && void 0 === r2.enabled || r2.enabled) && !i3.isNull && false !== i3.visible) {
21651              let t4 = G(r2.symbol, this.symbol, "rect");
21652              n2 = this.markerAttribs(i3, i3.selected && "select"), this.enabledDataSorting && (i3.startXPos = g2.reversed ? -(n2.width || 0) : g2.width);
21653              let e4 = false !== i3.isInside;
21654              if (!s2 && e4 && ((n2.width || 0) > 0 || i3.hasImage) && (i3.graphic = s2 = l2.renderer.symbol(t4, n2.x, n2.y, n2.width, n2.height, a2 ? r2 : p2).add(u12), this.enabledDataSorting && l2.hasRendered && (s2.attr({
21655                x: i3.startXPos
21656              }), o2 = "animate")), s2 && "animate" === o2 && s2[e4 ? "show" : "hide"](e4).animate(n2), s2) {
21657                let t5 = this.pointAttribs(i3, h2 || !i3.selected ? void 0 : "select");
21658                h2 ? d2 && s2.css({
21659                  fill: t5.fill
21660                }) : s2[o2](t5);
21661              }
21662              s2 && s2.addClass(i3.getClassName(), true);
21663            } else s2 && (i3.graphic = s2.destroy());
21664          }
21665          markerAttribs(t3, e3) {
21666            let i3 = this.options, s2 = i3.marker, o2 = t3.marker || {}, r2 = o2.symbol || s2.symbol, a2 = {}, n2, l2, h2 = G(o2.radius, s2 && s2.radius);
21667            e3 && (n2 = s2.states[e3], h2 = G((l2 = o2.states && o2.states[e3]) && l2.radius, n2 && n2.radius, h2 && h2 + (n2 && n2.radiusPlus || 0))), t3.hasImage = r2 && 0 === r2.indexOf("url"), t3.hasImage && (h2 = 0);
21668            let d2 = t3.pos();
21669            return j(h2) && d2 && (i3.crisp && (d2[0] = S2(d2[0], t3.hasImage ? 0 : "rect" === r2 ? s2?.lineWidth || 0 : 1)), a2.x = d2[0] - h2, a2.y = d2[1] - h2), h2 && (a2.width = a2.height = 2 * h2), a2;
21670          }
21671          pointAttribs(t3, e3) {
21672            let i3 = this.options.marker, s2 = t3 && t3.options, o2 = s2 && s2.marker || {}, r2 = s2 && s2.color, a2 = t3 && t3.color, n2 = t3 && t3.zone && t3.zone.color, l2, h2, d2 = this.color, c2, p2, u12 = G(o2.lineWidth, i3.lineWidth), g2 = 1;
21673            return d2 = r2 || n2 || a2 || d2, c2 = o2.fillColor || i3.fillColor || d2, p2 = o2.lineColor || i3.lineColor || d2, e3 = e3 || "normal", l2 = i3.states[e3] || {}, u12 = G((h2 = o2.states && o2.states[e3] || {}).lineWidth, l2.lineWidth, u12 + G(h2.lineWidthPlus, l2.lineWidthPlus, 0)), c2 = h2.fillColor || l2.fillColor || c2, {
21674              stroke: p2 = h2.lineColor || l2.lineColor || p2,
21675              "stroke-width": u12,
21676              fill: c2,
21677              opacity: g2 = G(h2.opacity, l2.opacity, g2)
21678            };
21679          }
21680          destroy(t3) {
21681            let e3, i3, s2;
21682            let o2 = this, r2 = o2.chart, a2 = /AppleWebKit\/533/.test(f.navigator.userAgent), n2 = o2.data || [];
21683            for (O(o2, "destroy", {
21684              keepEventsForUpdate: t3
21685            }), this.removeEvents(t3), (o2.axisTypes || []).forEach(function(t4) {
21686              (s2 = o2[t4]) && s2.series && (A(s2.series, o2), s2.isDirty = s2.forceRedraw = true);
21687            }), o2.legendItem && o2.chart.legend.destroyItem(o2), e3 = n2.length; e3--; ) (i3 = n2[e3]) && i3.destroy && i3.destroy();
21688            for (let t4 of o2.zones) M(t4, void 0, true);
21689            h.clearTimeout(o2.animationTimeout), z(o2, function(t4, e4) {
21690              t4 instanceof l && !t4.survive && t4[a2 && "group" === e4 ? "hide" : "destroy"]();
21691            }), r2.hoverSeries === o2 && (r2.hoverSeries = void 0), A(r2.series, o2), r2.orderItems("series"), z(o2, function(e4, i4) {
21692              t3 && "hcEvents" === i4 || delete o2[i4];
21693            });
21694          }
21695          applyZones() {
21696            let {
21697              area: t3,
21698              chart: e3,
21699              graph: i3,
21700              zones: s2,
21701              points: o2,
21702              xAxis: r2,
21703              yAxis: a2,
21704              zoneAxis: n2
21705            } = this, {
21706              inverted: l2,
21707              renderer: h2
21708            } = e3, d2 = this[`${n2}Axis`], {
21709              isXAxis: c2,
21710              len: p2 = 0
21711            } = d2 || {}, u12 = (i3?.strokeWidth() || 0) / 2 + 1, g2 = (t4, e4 = 0, i4 = 0) => {
21712              l2 && (i4 = p2 - i4);
21713              let {
21714                translated: s3 = 0,
21715                lineClip: o3
21716              } = t4, r3 = i4 - s3;
21717              o3?.push(["L", e4, Math.abs(r3) < u12 ? i4 - u12 * (r3 <= 0 ? -1 : 1) : s3]);
21718            };
21719            if (s2.length && (i3 || t3) && d2 && j(d2.min)) {
21720              let e4 = d2.getExtremes().max, u13 = (t4) => {
21721                t4.forEach((e5, i4) => {
21722                  ("M" === e5[0] || "L" === e5[0]) && (t4[i4] = [e5[0], c2 ? p2 - e5[1] : e5[1], c2 ? e5[2] : p2 - e5[2]]);
21723                });
21724              };
21725              if (s2.forEach((t4) => {
21726                t4.lineClip = [], t4.translated = b(d2.toPixels(G(t4.value, e4), true) || 0, 0, p2);
21727              }), i3 && !this.showLine && i3.hide(), t3 && t3.hide(), "y" === n2 && o2.length < r2.len) for (let t4 of o2) {
21728                let {
21729                  plotX: e5,
21730                  plotY: i4,
21731                  zone: o3
21732                } = t4, r3 = o3 && s2[s2.indexOf(o3) - 1];
21733                o3 && g2(o3, e5, i4), r3 && g2(r3, e5, i4);
21734              }
21735              let f2 = [], m2 = d2.toPixels(d2.getExtremes().min, true);
21736              s2.forEach((e5) => {
21737                let s3 = e5.lineClip || [], o3 = Math.round(e5.translated || 0);
21738                r2.reversed && s3.reverse();
21739                let {
21740                  clip: n3,
21741                  simpleClip: d3
21742                } = e5, p3 = 0, g3 = 0, x2 = r2.len, y2 = a2.len;
21743                c2 ? (p3 = o3, x2 = m2) : (g3 = o3, y2 = m2);
21744                let b2 = [["M", p3, g3], ["L", x2, g3], ["L", x2, y2], ["L", p3, y2], ["Z"]], v2 = [b2[0], ...s3, b2[1], b2[2], ...f2, b2[3], b2[4]];
21745                f2 = s3.reverse(), m2 = o3, l2 && (u13(v2), t3 && u13(b2)), n3 ? (n3.animate({
21746                  d: v2
21747                }), d3?.animate({
21748                  d: b2
21749                })) : (n3 = e5.clip = h2.path(v2), t3 && (d3 = e5.simpleClip = h2.path(b2))), i3 && e5.graph?.clip(n3), t3 && e5.area?.clip(d3);
21750              });
21751            } else this.visible && (i3 && i3.show(), t3 && t3.show());
21752          }
21753          plotGroup(t3, e3, i3, s2, o2) {
21754            let r2 = this[t3], a2 = !r2, n2 = {
21755              visibility: i3,
21756              zIndex: s2 || 0.1
21757            };
21758            return k(this.opacity) && !this.chart.styledMode && "inactive" !== this.state && (n2.opacity = this.opacity), r2 || (this[t3] = r2 = this.chart.renderer.g().add(o2)), r2.addClass("highcharts-" + e3 + " highcharts-series-" + this.index + " highcharts-" + this.type + "-series " + (k(this.colorIndex) ? "highcharts-color-" + this.colorIndex + " " : "") + (this.options.className || "") + (r2.hasClass("highcharts-tracker") ? " highcharts-tracker" : ""), true), r2.attr(n2)[a2 ? "attr" : "animate"](this.getPlotBox(e3)), r2;
21759          }
21760          getPlotBox(t3) {
21761            let e3 = this.xAxis, i3 = this.yAxis, s2 = this.chart, o2 = s2.inverted && !s2.polar && e3 && this.invertible && "series" === t3;
21762            return s2.inverted && (e3 = i3, i3 = this.xAxis), {
21763              translateX: e3 ? e3.left : s2.plotLeft,
21764              translateY: i3 ? i3.top : s2.plotTop,
21765              rotation: o2 ? 90 : 0,
21766              rotationOriginX: o2 ? (e3.len - i3.len) / 2 : 0,
21767              rotationOriginY: o2 ? (e3.len + i3.len) / 2 : 0,
21768              scaleX: o2 ? -1 : 1,
21769              scaleY: 1
21770            };
21771          }
21772          removeEvents(t3) {
21773            let {
21774              eventsToUnbind: e3
21775            } = this;
21776            t3 || N(this), e3.length && (e3.forEach((t4) => {
21777              t4();
21778            }), e3.length = 0);
21779          }
21780          render() {
21781            let t3 = this, {
21782              chart: e3,
21783              options: i3,
21784              hasRendered: s2
21785            } = t3, o2 = d(i3.animation), r2 = t3.visible ? "inherit" : "hidden", a2 = i3.zIndex, n2 = e3.seriesGroup, l2 = t3.finishedAnimating ? 0 : o2.duration;
21786            O(this, "render"), t3.plotGroup("group", "series", r2, a2, n2), t3.markerGroup = t3.plotGroup("markerGroup", "markers", r2, a2, n2), false !== i3.clip && t3.setClip(), l2 && t3.animate?.(true), t3.drawGraph && (t3.drawGraph(), t3.applyZones()), t3.visible && t3.drawPoints(), t3.drawDataLabels?.(), t3.redrawPoints?.(), i3.enableMouseTracking && t3.drawTracker?.(), l2 && t3.animate?.(), s2 || (l2 && o2.defer && (l2 += o2.defer), t3.animationTimeout = H(() => {
21787              t3.afterAnimate();
21788            }, l2 || 0)), t3.isDirty = false, t3.hasRendered = true, O(t3, "afterRender");
21789          }
21790          redraw() {
21791            let t3 = this.isDirty || this.isDirtyData;
21792            this.translate(), this.render(), t3 && delete this.kdTree;
21793          }
21794          reserveSpace() {
21795            return this.visible || !this.chart.options.chart.ignoreHiddenSeries;
21796          }
21797          searchPoint(t3, e3) {
21798            let {
21799              xAxis: i3,
21800              yAxis: s2
21801            } = this, o2 = this.chart.inverted;
21802            return this.searchKDTree({
21803              clientX: o2 ? i3.len - t3.chartY + i3.pos : t3.chartX - i3.pos,
21804              plotY: o2 ? s2.len - t3.chartX + s2.pos : t3.chartY - s2.pos
21805            }, e3, t3);
21806          }
21807          buildKDTree(t3) {
21808            this.buildingKdTree = true;
21809            let e3 = this, i3 = e3.options.findNearestPointBy.indexOf("y") > -1 ? 2 : 1;
21810            delete e3.kdTree, H(function() {
21811              e3.kdTree = function t4(i4, s2, o2) {
21812                let r2, a2;
21813                let n2 = i4?.length;
21814                if (n2) return r2 = e3.kdAxisArray[s2 % o2], i4.sort((t5, e4) => (t5[r2] || 0) - (e4[r2] || 0)), {
21815                  point: i4[a2 = Math.floor(n2 / 2)],
21816                  left: t4(i4.slice(0, a2), s2 + 1, o2),
21817                  right: t4(i4.slice(a2 + 1), s2 + 1, o2)
21818                };
21819              }(e3.getValidPoints(void 0, !e3.directTouch), i3, i3), e3.buildingKdTree = false;
21820            }, e3.options.kdNow || t3?.type === "touchstart" ? 0 : 1);
21821          }
21822          searchKDTree(t3, e3, i3) {
21823            let s2 = this, [o2, r2] = this.kdAxisArray, a2 = e3 ? "distX" : "dist", n2 = (s2.options.findNearestPointBy || "").indexOf("y") > -1 ? 2 : 1, l2 = !!s2.isBubble;
21824            if (this.kdTree || this.buildingKdTree || this.buildKDTree(i3), this.kdTree) return function t4(e4, i4, n3, h2) {
21825              let d2 = i4.point, c2 = s2.kdAxisArray[n3 % h2], p2, u12, g2 = d2;
21826              !function(t5, e5) {
21827                let i5 = t5[o2], s3 = e5[o2], a3 = k(i5) && k(s3) ? i5 - s3 : null, n4 = t5[r2], h3 = e5[r2], d3 = k(n4) && k(h3) ? n4 - h3 : 0, c3 = l2 && e5.marker?.radius || 0;
21828                e5.dist = Math.sqrt((a3 && a3 * a3 || 0) + d3 * d3) - c3, e5.distX = k(a3) ? Math.abs(a3) - c3 : Number.MAX_VALUE;
21829              }(e4, d2);
21830              let f2 = (e4[c2] || 0) - (d2[c2] || 0) + (l2 && d2.marker?.radius || 0), m2 = f2 < 0 ? "left" : "right", x2 = f2 < 0 ? "right" : "left";
21831              return i4[m2] && (g2 = (p2 = t4(e4, i4[m2], n3 + 1, h2))[a2] < g2[a2] ? p2 : d2), i4[x2] && Math.sqrt(f2 * f2) < g2[a2] && (g2 = (u12 = t4(e4, i4[x2], n3 + 1, h2))[a2] < g2[a2] ? u12 : g2), g2;
21832            }(t3, this.kdTree, n2, n2);
21833          }
21834          pointPlacementToXValue() {
21835            let {
21836              options: t3,
21837              xAxis: e3
21838            } = this, i3 = t3.pointPlacement;
21839            return "between" === i3 && (i3 = e3.reversed ? -0.5 : 0.5), j(i3) ? i3 * (t3.pointRange || e3.pointRange) : 0;
21840          }
21841          isPointInside(t3) {
21842            let {
21843              chart: e3,
21844              xAxis: i3,
21845              yAxis: s2
21846            } = this, {
21847              plotX: o2 = -1,
21848              plotY: r2 = -1
21849            } = t3;
21850            return r2 >= 0 && r2 <= (s2 ? s2.len : e3.plotHeight) && o2 >= 0 && o2 <= (i3 ? i3.len : e3.plotWidth);
21851          }
21852          drawTracker() {
21853            let t3 = this, e3 = t3.options, i3 = e3.trackByArea, s2 = [].concat((i3 ? t3.areaPath : t3.graphPath) || []), o2 = t3.chart, r2 = o2.pointer, a2 = o2.renderer, n2 = o2.options.tooltip?.snap || 0, l2 = () => {
21854              e3.enableMouseTracking && o2.hoverSeries !== t3 && t3.onMouseOver();
21855            }, h2 = "rgba(192,192,192," + (g ? 1e-4 : 2e-3) + ")", d2 = t3.tracker;
21856            d2 ? d2.attr({
21857              d: s2
21858            }) : t3.graph && (t3.tracker = d2 = a2.path(s2).attr({
21859              visibility: t3.visible ? "inherit" : "hidden",
21860              zIndex: 2
21861            }).addClass(i3 ? "highcharts-tracker-area" : "highcharts-tracker-line").add(t3.group), o2.styledMode || d2.attr({
21862              "stroke-linecap": "round",
21863              "stroke-linejoin": "round",
21864              stroke: h2,
21865              fill: i3 ? h2 : "none",
21866              "stroke-width": t3.graph.strokeWidth() + (i3 ? 0 : 2 * n2)
21867            }), [t3.tracker, t3.markerGroup, t3.dataLabelsGroup].forEach((t4) => {
21868              t4 && (t4.addClass("highcharts-tracker").on("mouseover", l2).on("mouseout", (t5) => {
21869                r2?.onTrackerMouseOut(t5);
21870              }), e3.cursor && !o2.styledMode && t4.css({
21871                cursor: e3.cursor
21872              }), t4.on("touchstart", l2));
21873            })), O(this, "afterDrawTracker");
21874          }
21875          addPoint(t3, e3, i3, s2, o2) {
21876            let r2, a2;
21877            let n2 = this.options, l2 = this.data, h2 = this.chart, d2 = this.xAxis, c2 = d2 && d2.hasNames && d2.names, p2 = n2.data, u12 = this.xData;
21878            e3 = G(e3, true);
21879            let g2 = {
21880              series: this
21881            };
21882            this.pointClass.prototype.applyOptions.apply(g2, [t3]);
21883            let f2 = g2.x;
21884            if (a2 = u12.length, this.requireSorting && f2 < u12[a2 - 1]) for (r2 = true; a2 && u12[a2 - 1] > f2; ) a2--;
21885            this.updateParallelArrays(g2, "splice", [a2, 0, 0]), this.updateParallelArrays(g2, a2), c2 && g2.name && (c2[f2] = g2.name), p2.splice(a2, 0, t3), (r2 || this.processedData) && (this.data.splice(a2, 0, null), this.processData()), "point" === n2.legendType && this.generatePoints(), i3 && (l2[0] && l2[0].remove ? l2[0].remove(false) : (l2.shift(), this.updateParallelArrays(g2, "shift"), p2.shift())), false !== o2 && O(this, "addPoint", {
21886              point: g2
21887            }), this.isDirty = true, this.isDirtyData = true, e3 && h2.redraw(s2);
21888          }
21889          removePoint(t3, e3, i3) {
21890            let s2 = this, o2 = s2.data, r2 = o2[t3], a2 = s2.points, n2 = s2.chart, l2 = function() {
21891              a2 && a2.length === o2.length && a2.splice(t3, 1), o2.splice(t3, 1), s2.options.data.splice(t3, 1), s2.updateParallelArrays(r2 || {
21892                series: s2
21893              }, "splice", [t3, 1]), r2 && r2.destroy(), s2.isDirty = true, s2.isDirtyData = true, e3 && n2.redraw();
21894            };
21895            c(i3, n2), e3 = G(e3, true), r2 ? r2.firePointEvent("remove", null, l2) : l2();
21896          }
21897          remove(t3, e3, i3, s2) {
21898            let o2 = this, r2 = o2.chart;
21899            function a2() {
21900              o2.destroy(s2), r2.isDirtyLegend = r2.isDirtyBox = true, r2.linkSeries(s2), G(t3, true) && r2.redraw(e3);
21901            }
21902            false !== i3 ? O(o2, "remove", null, a2) : a2();
21903          }
21904          update(t3, e3) {
21905            O(this, "update", {
21906              options: t3 = C(t3, this.userOptions)
21907            });
21908            let i3 = this, s2 = i3.chart, o2 = i3.userOptions, r2 = i3.initialType || i3.type, a2 = s2.options.plotOptions, n2 = m[r2].prototype, l2 = i3.finishedAnimating && {
21909              animation: false
21910            }, h2 = {}, d2, c2, p2 = ["colorIndex", "eventOptions", "navigatorSeries", "symbolIndex", "baseSeries"], u12 = t3.type || o2.type || s2.options.chart.type, g2 = !(this.hasDerivedData || u12 && u12 !== this.type || void 0 !== t3.pointStart || void 0 !== t3.pointInterval || void 0 !== t3.relativeXValue || t3.joinBy || t3.mapData || ["dataGrouping", "pointStart", "pointInterval", "pointIntervalUnit", "keys"].some((t4) => i3.hasOptionChanged(t4)));
21911            u12 = u12 || r2, g2 && (p2.push("data", "isDirtyData", "isDirtyCanvas", "points", "processedData", "processedXData", "processedYData", "xIncrement", "cropped", "_hasPointMarkers", "hasDataLabels", "nodes", "layout", "level", "mapMap", "mapData", "minY", "maxY", "minX", "maxX", "transformGroups"), false !== t3.visible && p2.push("area", "graph"), i3.parallelArrays.forEach(function(t4) {
21912              p2.push(t4 + "Data");
21913            }), t3.data && (t3.dataSorting && T2(i3.options.dataSorting, t3.dataSorting), this.setData(t3.data, false))), t3 = I(o2, {
21914              index: void 0 === o2.index ? i3.index : o2.index,
21915              pointStart: a2?.series?.pointStart ?? o2.pointStart ?? i3.xData?.[0]
21916            }, !g2 && {
21917              data: i3.options.data
21918            }, t3, l2), g2 && t3.data && (t3.data = i3.options.data), (p2 = ["group", "markerGroup", "dataLabelsGroup", "transformGroup"].concat(p2)).forEach(function(t4) {
21919              p2[t4] = i3[t4], delete i3[t4];
21920            });
21921            let f2 = false;
21922            if (m[u12]) {
21923              if (f2 = u12 !== i3.type, i3.remove(false, false, false, true), f2) {
21924                if (s2.propFromSeries(), Object.setPrototypeOf) Object.setPrototypeOf(i3, m[u12].prototype);
21925                else {
21926                  let t4 = Object.hasOwnProperty.call(i3, "hcEvents") && i3.hcEvents;
21927                  for (c2 in n2) i3[c2] = void 0;
21928                  T2(i3, m[u12].prototype), t4 ? i3.hcEvents = t4 : delete i3.hcEvents;
21929                }
21930              }
21931            } else w(17, true, s2, {
21932              missingModuleFor: u12
21933            });
21934            if (p2.forEach(function(t4) {
21935              i3[t4] = p2[t4];
21936            }), i3.init(s2, t3), g2 && this.points) for (let t4 of (false === (d2 = i3.options).visible ? (h2.graphic = 1, h2.dataLabel = 1) : (this.hasMarkerChanged(d2, o2) && (h2.graphic = 1), i3.hasDataLabels?.() || (h2.dataLabel = 1)), this.points)) t4 && t4.series && (t4.resolveColor(), Object.keys(h2).length && t4.destroyElements(h2), false === d2.showInLegend && t4.legendItem && s2.legend.destroyItem(t4));
21937            i3.initialType = r2, s2.linkSeries(), s2.setSortedData(), f2 && i3.linkedSeries.length && (i3.isDirtyData = true), O(this, "afterUpdate"), G(e3, true) && s2.redraw(!!g2 && void 0);
21938          }
21939          setName(t3) {
21940            this.name = this.options.name = this.userOptions.name = t3, this.chart.isDirtyLegend = true;
21941          }
21942          hasOptionChanged(t3) {
21943            let e3 = this.chart, i3 = this.options[t3], s2 = e3.options.plotOptions, o2 = this.userOptions[t3], r2 = G(s2?.[this.type]?.[t3], s2?.series?.[t3]);
21944            return o2 && !k(r2) ? i3 !== o2 : i3 !== G(r2, i3);
21945          }
21946          onMouseOver() {
21947            let t3 = this.chart, e3 = t3.hoverSeries, i3 = t3.pointer;
21948            i3?.setHoverChartIndex(), e3 && e3 !== this && e3.onMouseOut(), this.options.events.mouseOver && O(this, "mouseOver"), this.setState("hover"), t3.hoverSeries = this;
21949          }
21950          onMouseOut() {
21951            let t3 = this.options, e3 = this.chart, i3 = e3.tooltip, s2 = e3.hoverPoint;
21952            e3.hoverSeries = null, s2 && s2.onMouseOut(), this && t3.events.mouseOut && O(this, "mouseOut"), i3 && !this.stickyTracking && (!i3.shared || this.noSharedTooltip) && i3.hide(), e3.series.forEach(function(t4) {
21953              t4.setState("", true);
21954            });
21955          }
21956          setState(t3, e3) {
21957            let i3 = this, s2 = i3.options, o2 = i3.graph, r2 = s2.inactiveOtherPoints, a2 = s2.states, n2 = G(a2[t3 || "normal"] && a2[t3 || "normal"].animation, i3.chart.options.chart.animation), l2 = s2.lineWidth, h2 = s2.opacity;
21958            if (t3 = t3 || "", i3.state !== t3 && ([i3.group, i3.markerGroup, i3.dataLabelsGroup].forEach(function(e4) {
21959              e4 && (i3.state && e4.removeClass("highcharts-series-" + i3.state), t3 && e4.addClass("highcharts-series-" + t3));
21960            }), i3.state = t3, !i3.chart.styledMode)) {
21961              if (a2[t3] && false === a2[t3].enabled) return;
21962              if (t3 && (l2 = a2[t3].lineWidth || l2 + (a2[t3].lineWidthPlus || 0), h2 = G(a2[t3].opacity, h2)), o2 && !o2.dashstyle && j(l2)) for (let t4 of [o2, ...this.zones.map((t5) => t5.graph)]) t4?.animate({
21963                "stroke-width": l2
21964              }, n2);
21965              r2 || [i3.group, i3.markerGroup, i3.dataLabelsGroup, i3.labelBySeries].forEach(function(t4) {
21966                t4 && t4.animate({
21967                  opacity: h2
21968                }, n2);
21969              });
21970            }
21971            e3 && r2 && i3.points && i3.setAllPointsToState(t3 || void 0);
21972          }
21973          setAllPointsToState(t3) {
21974            this.points.forEach(function(e3) {
21975              e3.setState && e3.setState(t3);
21976            });
21977          }
21978          setVisible(t3, e3) {
21979            let i3 = this, s2 = i3.chart, o2 = s2.options.chart.ignoreHiddenSeries, r2 = i3.visible;
21980            i3.visible = t3 = i3.options.visible = i3.userOptions.visible = void 0 === t3 ? !r2 : t3;
21981            let a2 = t3 ? "show" : "hide";
21982            ["group", "dataLabelsGroup", "markerGroup", "tracker", "tt"].forEach((t4) => {
21983              i3[t4]?.[a2]();
21984            }), (s2.hoverSeries === i3 || s2.hoverPoint?.series === i3) && i3.onMouseOut(), i3.legendItem && s2.legend.colorizeItem(i3, t3), i3.isDirty = true, i3.options.stacking && s2.series.forEach((t4) => {
21985              t4.options.stacking && t4.visible && (t4.isDirty = true);
21986            }), i3.linkedSeries.forEach((e4) => {
21987              e4.setVisible(t3, false);
21988            }), o2 && (s2.isDirtyBox = true), O(i3, a2), false !== e3 && s2.redraw();
21989          }
21990          show() {
21991            this.setVisible(true);
21992          }
21993          hide() {
21994            this.setVisible(false);
21995          }
21996          select(t3) {
21997            this.selected = t3 = this.options.selected = void 0 === t3 ? !this.selected : t3, this.checkbox && (this.checkbox.checked = t3), O(this, t3 ? "select" : "unselect");
21998          }
21999          shouldShowTooltip(t3, e3, i3 = {}) {
22000            return i3.series = this, i3.visiblePlotOnly = true, this.chart.isInsidePlot(t3, e3, i3);
22001          }
22002          drawLegendSymbol(t3, e3) {
22003            o[this.options.legendSymbol || "rectangle"]?.call(this, t3, e3);
22004          }
22005        }
22006        return X.defaultOptions = a, X.types = n.seriesTypes, X.registerType = n.registerSeriesType, T2(X.prototype, {
22007          axisTypes: ["xAxis", "yAxis"],
22008          coll: "series",
22009          colorCounter: 0,
22010          directTouch: false,
22011          invertible: true,
22012          isCartesian: true,
22013          kdAxisArray: ["clientX", "plotY"],
22014          parallelArrays: ["x", "y"],
22015          pointClass: r,
22016          requireSorting: true,
22017          sorted: true
22018        }), n.series = X, X;
22019      }), i(e, "Core/Legend/Legend.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Foundation.js"], e["Core/Globals.js"], e["Core/Series/Series.js"], e["Core/Series/Point.js"], e["Core/Renderer/RendererUtilities.js"], e["Core/Templating.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o, r, a, n) {
22020        var l;
22021        let {
22022          animObject: h,
22023          setAnimation: d
22024        } = t2, {
22025          registerEventOptions: c
22026        } = e2, {
22027          composed: p,
22028          marginNames: u11
22029        } = i2, {
22030          distribute: g
22031        } = r, {
22032          format: f
22033        } = a, {
22034          addEvent: m,
22035          createElement: x,
22036          css: y,
22037          defined: b,
22038          discardElement: v,
22039          find: S2,
22040          fireEvent: k,
22041          isNumber: M,
22042          merge: C,
22043          pick: A,
22044          pushUnique: w,
22045          relativeLength: T2,
22046          stableSort: P,
22047          syncTimeout: O
22048        } = n;
22049        class L {
22050          constructor(t3, e3) {
22051            this.allItems = [], this.initialItemY = 0, this.itemHeight = 0, this.itemMarginBottom = 0, this.itemMarginTop = 0, this.itemX = 0, this.itemY = 0, this.lastItemY = 0, this.lastLineHeight = 0, this.legendHeight = 0, this.legendWidth = 0, this.maxItemWidth = 0, this.maxLegendWidth = 0, this.offsetWidth = 0, this.padding = 0, this.pages = [], this.symbolHeight = 0, this.symbolWidth = 0, this.titleHeight = 0, this.totalItemWidth = 0, this.widthOption = 0, this.chart = t3, this.setOptions(e3), e3.enabled && (this.render(), c(this, e3), m(this.chart, "endResize", function() {
22052              this.legend.positionCheckboxes();
22053            })), m(this.chart, "render", () => {
22054              this.options.enabled && this.proximate && (this.proximatePositions(), this.positionItems());
22055            });
22056          }
22057          setOptions(t3) {
22058            let e3 = A(t3.padding, 8);
22059            this.options = t3, this.chart.styledMode || (this.itemStyle = t3.itemStyle, this.itemHiddenStyle = C(this.itemStyle, t3.itemHiddenStyle)), this.itemMarginTop = t3.itemMarginTop, this.itemMarginBottom = t3.itemMarginBottom, this.padding = e3, this.initialItemY = e3 - 5, this.symbolWidth = A(t3.symbolWidth, 16), this.pages = [], this.proximate = "proximate" === t3.layout && !this.chart.inverted, this.baseline = void 0;
22060          }
22061          update(t3, e3) {
22062            let i3 = this.chart;
22063            this.setOptions(C(true, this.options, t3)), "events" in this.options && c(this, this.options), this.destroy(), i3.isDirtyLegend = i3.isDirtyBox = true, A(e3, true) && i3.redraw(), k(this, "afterUpdate", {
22064              redraw: e3
22065            });
22066          }
22067          colorizeItem(t3, e3) {
22068            let {
22069              area: i3,
22070              group: s2,
22071              label: o2,
22072              line: r2,
22073              symbol: a2
22074            } = t3.legendItem || {};
22075            if (s2?.[e3 ? "removeClass" : "addClass"]("highcharts-legend-item-hidden"), !this.chart.styledMode) {
22076              let {
22077                itemHiddenStyle: s3 = {}
22078              } = this, n2 = s3.color, {
22079                fillColor: l2,
22080                fillOpacity: h2,
22081                lineColor: d2,
22082                marker: c2
22083              } = t3.options, p2 = (t4) => (!e3 && (t4.fill && (t4.fill = n2), t4.stroke && (t4.stroke = n2)), t4);
22084              o2?.css(C(e3 ? this.itemStyle : s3)), r2?.attr(p2({
22085                stroke: d2 || t3.color
22086              })), a2 && a2.attr(p2(c2 && a2.isMarker ? t3.pointAttribs() : {
22087                fill: t3.color
22088              })), i3?.attr(p2({
22089                fill: l2 || t3.color,
22090                "fill-opacity": l2 ? 1 : h2 ?? 0.75
22091              }));
22092            }
22093            k(this, "afterColorizeItem", {
22094              item: t3,
22095              visible: e3
22096            });
22097          }
22098          positionItems() {
22099            this.allItems.forEach(this.positionItem, this), this.chart.isResizing || this.positionCheckboxes();
22100          }
22101          positionItem(t3) {
22102            let {
22103              group: e3,
22104              x: i3 = 0,
22105              y: s2 = 0
22106            } = t3.legendItem || {}, o2 = this.options, r2 = o2.symbolPadding, a2 = !o2.rtl, n2 = t3.checkbox;
22107            if (e3 && e3.element) {
22108              let o3 = {
22109                translateX: a2 ? i3 : this.legendWidth - i3 - 2 * r2 - 4,
22110                translateY: s2
22111              };
22112              e3[b(e3.translateY) ? "animate" : "attr"](o3, void 0, () => {
22113                k(this, "afterPositionItem", {
22114                  item: t3
22115                });
22116              });
22117            }
22118            n2 && (n2.x = i3, n2.y = s2);
22119          }
22120          destroyItem(t3) {
22121            let e3 = t3.checkbox, i3 = t3.legendItem || {};
22122            for (let t4 of ["group", "label", "line", "symbol"]) i3[t4] && (i3[t4] = i3[t4].destroy());
22123            e3 && v(e3), t3.legendItem = void 0;
22124          }
22125          destroy() {
22126            for (let t3 of this.getAllItems()) this.destroyItem(t3);
22127            for (let t3 of ["clipRect", "up", "down", "pager", "nav", "box", "title", "group"]) this[t3] && (this[t3] = this[t3].destroy());
22128            this.display = null;
22129          }
22130          positionCheckboxes() {
22131            let t3;
22132            let e3 = this.group && this.group.alignAttr, i3 = this.clipHeight || this.legendHeight, s2 = this.titleHeight;
22133            e3 && (t3 = e3.translateY, this.allItems.forEach(function(o2) {
22134              let r2;
22135              let a2 = o2.checkbox;
22136              a2 && (r2 = t3 + s2 + a2.y + (this.scrollOffset || 0) + 3, y(a2, {
22137                left: e3.translateX + o2.checkboxOffset + a2.x - 20 + "px",
22138                top: r2 + "px",
22139                display: this.proximate || r2 > t3 - 6 && r2 < t3 + i3 - 6 ? "" : "none"
22140              }));
22141            }, this));
22142          }
22143          renderTitle() {
22144            let t3 = this.options, e3 = this.padding, i3 = t3.title, s2, o2 = 0;
22145            i3.text && (this.title || (this.title = this.chart.renderer.label(i3.text, e3 - 3, e3 - 4, void 0, void 0, void 0, t3.useHTML, void 0, "legend-title").attr({
22146              zIndex: 1
22147            }), this.chart.styledMode || this.title.css(i3.style), this.title.add(this.group)), i3.width || this.title.css({
22148              width: this.maxLegendWidth + "px"
22149            }), o2 = (s2 = this.title.getBBox()).height, this.offsetWidth = s2.width, this.contentGroup.attr({
22150              translateY: o2
22151            })), this.titleHeight = o2;
22152          }
22153          setText(t3) {
22154            let e3 = this.options;
22155            t3.legendItem.label.attr({
22156              text: e3.labelFormat ? f(e3.labelFormat, t3, this.chart) : e3.labelFormatter.call(t3)
22157            });
22158          }
22159          renderItem(t3) {
22160            let e3 = t3.legendItem = t3.legendItem || {}, i3 = this.chart, s2 = i3.renderer, o2 = this.options, r2 = "horizontal" === o2.layout, a2 = this.symbolWidth, n2 = o2.symbolPadding || 0, l2 = this.itemStyle, h2 = this.itemHiddenStyle, d2 = r2 ? A(o2.itemDistance, 20) : 0, c2 = !o2.rtl, p2 = !t3.series, u12 = !p2 && t3.series.drawLegendSymbol ? t3.series : t3, g2 = u12.options, f2 = !!this.createCheckboxForItem && g2 && g2.showCheckbox, m2 = o2.useHTML, x2 = t3.options.className, y2 = e3.label, b2 = a2 + n2 + d2 + (f2 ? 20 : 0);
22161            !y2 && (e3.group = s2.g("legend-item").addClass("highcharts-" + u12.type + "-series highcharts-color-" + t3.colorIndex + (x2 ? " " + x2 : "") + (p2 ? " highcharts-series-" + t3.index : "")).attr({
22162              zIndex: 1
22163            }).add(this.scrollGroup), e3.label = y2 = s2.text("", c2 ? a2 + n2 : -n2, this.baseline || 0, m2), i3.styledMode || y2.css(C(t3.visible ? l2 : h2)), y2.attr({
22164              align: c2 ? "left" : "right",
22165              zIndex: 2
22166            }).add(e3.group), !this.baseline && (this.fontMetrics = s2.fontMetrics(y2), this.baseline = this.fontMetrics.f + 3 + this.itemMarginTop, y2.attr("y", this.baseline), this.symbolHeight = A(o2.symbolHeight, this.fontMetrics.f), o2.squareSymbol && (this.symbolWidth = A(o2.symbolWidth, Math.max(this.symbolHeight, 16)), b2 = this.symbolWidth + n2 + d2 + (f2 ? 20 : 0), c2 && y2.attr("x", this.symbolWidth + n2))), u12.drawLegendSymbol(this, t3), this.setItemEvents && this.setItemEvents(t3, y2, m2)), f2 && !t3.checkbox && this.createCheckboxForItem && this.createCheckboxForItem(t3), this.colorizeItem(t3, t3.visible), (i3.styledMode || !l2.width) && y2.css({
22167              width: (o2.itemWidth || this.widthOption || i3.spacingBox.width) - b2 + "px"
22168            }), this.setText(t3);
22169            let v2 = y2.getBBox(), S3 = this.fontMetrics && this.fontMetrics.h || 0;
22170            t3.itemWidth = t3.checkboxOffset = o2.itemWidth || e3.labelWidth || v2.width + b2, this.maxItemWidth = Math.max(this.maxItemWidth, t3.itemWidth), this.totalItemWidth += t3.itemWidth, this.itemHeight = t3.itemHeight = Math.round(e3.labelHeight || (v2.height > 1.5 * S3 ? v2.height : S3));
22171          }
22172          layoutItem(t3) {
22173            let e3 = this.options, i3 = this.padding, s2 = "horizontal" === e3.layout, o2 = t3.itemHeight, r2 = this.itemMarginBottom, a2 = this.itemMarginTop, n2 = s2 ? A(e3.itemDistance, 20) : 0, l2 = this.maxLegendWidth, h2 = e3.alignColumns && this.totalItemWidth > l2 ? this.maxItemWidth : t3.itemWidth, d2 = t3.legendItem || {};
22174            s2 && this.itemX - i3 + h2 > l2 && (this.itemX = i3, this.lastLineHeight && (this.itemY += a2 + this.lastLineHeight + r2), this.lastLineHeight = 0), this.lastItemY = a2 + this.itemY + r2, this.lastLineHeight = Math.max(o2, this.lastLineHeight), d2.x = this.itemX, d2.y = this.itemY, s2 ? this.itemX += h2 : (this.itemY += a2 + o2 + r2, this.lastLineHeight = o2), this.offsetWidth = this.widthOption || Math.max((s2 ? this.itemX - i3 - (t3.checkbox ? 0 : n2) : h2) + i3, this.offsetWidth);
22175          }
22176          getAllItems() {
22177            let t3 = [];
22178            return this.chart.series.forEach(function(e3) {
22179              let i3 = e3 && e3.options;
22180              e3 && A(i3.showInLegend, !b(i3.linkedTo) && void 0, true) && (t3 = t3.concat((e3.legendItem || {}).labels || ("point" === i3.legendType ? e3.data : e3)));
22181            }), k(this, "afterGetAllItems", {
22182              allItems: t3
22183            }), t3;
22184          }
22185          getAlignment() {
22186            let t3 = this.options;
22187            return this.proximate ? t3.align.charAt(0) + "tv" : t3.floating ? "" : t3.align.charAt(0) + t3.verticalAlign.charAt(0) + t3.layout.charAt(0);
22188          }
22189          adjustMargins(t3, e3) {
22190            let i3 = this.chart, s2 = this.options, o2 = this.getAlignment();
22191            o2 && [/(lth|ct|rth)/, /(rtv|rm|rbv)/, /(rbh|cb|lbh)/, /(lbv|lm|ltv)/].forEach(function(r2, a2) {
22192              r2.test(o2) && !b(t3[a2]) && (i3[u11[a2]] = Math.max(i3[u11[a2]], i3.legend[(a2 + 1) % 2 ? "legendHeight" : "legendWidth"] + [1, -1, -1, 1][a2] * s2[a2 % 2 ? "x" : "y"] + A(s2.margin, 12) + e3[a2] + (i3.titleOffset[a2] || 0)));
22193            });
22194          }
22195          proximatePositions() {
22196            let t3;
22197            let e3 = this.chart, i3 = [], s2 = "left" === this.options.align;
22198            for (let o2 of (this.allItems.forEach(function(t4) {
22199              let o3, r2, a2 = s2, n2, l2;
22200              t4.yAxis && (t4.xAxis.options.reversed && (a2 = !a2), t4.points && (o3 = S2(a2 ? t4.points : t4.points.slice(0).reverse(), function(t5) {
22201                return M(t5.plotY);
22202              })), r2 = this.itemMarginTop + t4.legendItem.label.getBBox().height + this.itemMarginBottom, l2 = t4.yAxis.top - e3.plotTop, n2 = t4.visible ? (o3 ? o3.plotY : t4.yAxis.height) + (l2 - 0.3 * r2) : l2 + t4.yAxis.height, i3.push({
22203                target: n2,
22204                size: r2,
22205                item: t4
22206              }));
22207            }, this), g(i3, e3.plotHeight))) t3 = o2.item.legendItem || {}, M(o2.pos) && (t3.y = e3.plotTop - e3.spacing[0] + o2.pos);
22208          }
22209          render() {
22210            let t3 = this.chart, e3 = t3.renderer, i3 = this.options, s2 = this.padding, o2 = this.getAllItems(), r2, a2, n2, l2 = this.group, h2, d2 = this.box;
22211            this.itemX = s2, this.itemY = this.initialItemY, this.offsetWidth = 0, this.lastItemY = 0, this.widthOption = T2(i3.width, t3.spacingBox.width - s2), h2 = t3.spacingBox.width - 2 * s2 - i3.x, ["rm", "lm"].indexOf(this.getAlignment().substring(0, 2)) > -1 && (h2 /= 2), this.maxLegendWidth = this.widthOption || h2, l2 || (this.group = l2 = e3.g("legend").addClass(i3.className || "").attr({
22212              zIndex: 7
22213            }).add(), this.contentGroup = e3.g().attr({
22214              zIndex: 1
22215            }).add(l2), this.scrollGroup = e3.g().add(this.contentGroup)), this.renderTitle(), P(o2, (t4, e4) => (t4.options && t4.options.legendIndex || 0) - (e4.options && e4.options.legendIndex || 0)), i3.reversed && o2.reverse(), this.allItems = o2, this.display = r2 = !!o2.length, this.lastLineHeight = 0, this.maxItemWidth = 0, this.totalItemWidth = 0, this.itemHeight = 0, o2.forEach(this.renderItem, this), o2.forEach(this.layoutItem, this), a2 = (this.widthOption || this.offsetWidth) + s2, n2 = this.lastItemY + this.lastLineHeight + this.titleHeight, n2 = this.handleOverflow(n2) + s2, d2 || (this.box = d2 = e3.rect().addClass("highcharts-legend-box").attr({
22216              r: i3.borderRadius
22217            }).add(l2)), t3.styledMode || d2.attr({
22218              stroke: i3.borderColor,
22219              "stroke-width": i3.borderWidth || 0,
22220              fill: i3.backgroundColor || "none"
22221            }).shadow(i3.shadow), a2 > 0 && n2 > 0 && d2[d2.placed ? "animate" : "attr"](d2.crisp.call({}, {
22222              x: 0,
22223              y: 0,
22224              width: a2,
22225              height: n2
22226            }, d2.strokeWidth())), l2[r2 ? "show" : "hide"](), t3.styledMode && "none" === l2.getStyle("display") && (a2 = n2 = 0), this.legendWidth = a2, this.legendHeight = n2, r2 && this.align(), this.proximate || this.positionItems(), k(this, "afterRender");
22227          }
22228          align(t3 = this.chart.spacingBox) {
22229            let e3 = this.chart, i3 = this.options, s2 = t3.y;
22230            /(lth|ct|rth)/.test(this.getAlignment()) && e3.titleOffset[0] > 0 ? s2 += e3.titleOffset[0] : /(lbh|cb|rbh)/.test(this.getAlignment()) && e3.titleOffset[2] > 0 && (s2 -= e3.titleOffset[2]), s2 !== t3.y && (t3 = C(t3, {
22231              y: s2
22232            })), e3.hasRendered || (this.group.placed = false), this.group.align(C(i3, {
22233              width: this.legendWidth,
22234              height: this.legendHeight,
22235              verticalAlign: this.proximate ? "top" : i3.verticalAlign
22236            }), true, t3);
22237          }
22238          handleOverflow(t3) {
22239            let e3 = this, i3 = this.chart, s2 = i3.renderer, o2 = this.options, r2 = o2.y, a2 = "top" === o2.verticalAlign, n2 = this.padding, l2 = o2.maxHeight, h2 = o2.navigation, d2 = A(h2.animation, true), c2 = h2.arrowSize || 12, p2 = this.pages, u12 = this.allItems, g2 = function(t4) {
22240              "number" == typeof t4 ? S3.attr({
22241                height: t4
22242              }) : S3 && (e3.clipRect = S3.destroy(), e3.contentGroup.clip()), e3.contentGroup.div && (e3.contentGroup.div.style.clip = t4 ? "rect(" + n2 + "px,9999px," + (n2 + t4) + "px,0)" : "auto");
22243            }, f2 = function(t4) {
22244              return e3[t4] = s2.circle(0, 0, 1.3 * c2).translate(c2 / 2, c2 / 2).add(v2), i3.styledMode || e3[t4].attr("fill", "rgba(0,0,0,0.0001)"), e3[t4];
22245            }, m2, x2, y2, b2 = i3.spacingBox.height + (a2 ? -r2 : r2) - n2, v2 = this.nav, S3 = this.clipRect;
22246            return "horizontal" !== o2.layout || "middle" === o2.verticalAlign || o2.floating || (b2 /= 2), l2 && (b2 = Math.min(b2, l2)), p2.length = 0, t3 && b2 > 0 && t3 > b2 && false !== h2.enabled ? (this.clipHeight = m2 = Math.max(b2 - 20 - this.titleHeight - n2, 0), this.currentPage = A(this.currentPage, 1), this.fullHeight = t3, u12.forEach((t4, e4) => {
22247              let i4 = (y2 = t4.legendItem || {}).y || 0, s3 = Math.round(y2.label.getBBox().height), o3 = p2.length;
22248              (!o3 || i4 - p2[o3 - 1] > m2 && (x2 || i4) !== p2[o3 - 1]) && (p2.push(x2 || i4), o3++), y2.pageIx = o3 - 1, x2 && ((u12[e4 - 1].legendItem || {}).pageIx = o3 - 1), e4 === u12.length - 1 && i4 + s3 - p2[o3 - 1] > m2 && i4 > p2[o3 - 1] && (p2.push(i4), y2.pageIx = o3), i4 !== x2 && (x2 = i4);
22249            }), S3 || (S3 = e3.clipRect = s2.clipRect(0, n2 - 2, 9999, 0), e3.contentGroup.clip(S3)), g2(m2), v2 || (this.nav = v2 = s2.g().attr({
22250              zIndex: 1
22251            }).add(this.group), this.up = s2.symbol("triangle", 0, 0, c2, c2).add(v2), f2("upTracker").on("click", function() {
22252              e3.scroll(-1, d2);
22253            }), this.pager = s2.text("", 15, 10).addClass("highcharts-legend-navigation"), !i3.styledMode && h2.style && this.pager.css(h2.style), this.pager.add(v2), this.down = s2.symbol("triangle-down", 0, 0, c2, c2).add(v2), f2("downTracker").on("click", function() {
22254              e3.scroll(1, d2);
22255            })), e3.scroll(0), t3 = b2) : v2 && (g2(), this.nav = v2.destroy(), this.scrollGroup.attr({
22256              translateY: 1
22257            }), this.clipHeight = 0), t3;
22258          }
22259          scroll(t3, e3) {
22260            let i3 = this.chart, s2 = this.pages, o2 = s2.length, r2 = this.clipHeight, a2 = this.options.navigation, n2 = this.pager, l2 = this.padding, c2 = this.currentPage + t3;
22261            c2 > o2 && (c2 = o2), c2 > 0 && (void 0 !== e3 && d(e3, i3), this.nav.attr({
22262              translateX: l2,
22263              translateY: r2 + this.padding + 7 + this.titleHeight,
22264              visibility: "inherit"
22265            }), [this.up, this.upTracker].forEach(function(t4) {
22266              t4.attr({
22267                class: 1 === c2 ? "highcharts-legend-nav-inactive" : "highcharts-legend-nav-active"
22268              });
22269            }), n2.attr({
22270              text: c2 + "/" + o2
22271            }), [this.down, this.downTracker].forEach(function(t4) {
22272              t4.attr({
22273                x: 18 + this.pager.getBBox().width,
22274                class: c2 === o2 ? "highcharts-legend-nav-inactive" : "highcharts-legend-nav-active"
22275              });
22276            }, this), i3.styledMode || (this.up.attr({
22277              fill: 1 === c2 ? a2.inactiveColor : a2.activeColor
22278            }), this.upTracker.css({
22279              cursor: 1 === c2 ? "default" : "pointer"
22280            }), this.down.attr({
22281              fill: c2 === o2 ? a2.inactiveColor : a2.activeColor
22282            }), this.downTracker.css({
22283              cursor: c2 === o2 ? "default" : "pointer"
22284            })), this.scrollOffset = -s2[c2 - 1] + this.initialItemY, this.scrollGroup.animate({
22285              translateY: this.scrollOffset
22286            }), this.currentPage = c2, this.positionCheckboxes(), O(() => {
22287              k(this, "afterScroll", {
22288                currentPage: c2
22289              });
22290            }, h(A(e3, i3.renderer.globalAnimation, true)).duration));
22291          }
22292          setItemEvents(t3, e3, i3) {
22293            let r2 = this, a2 = t3.legendItem || {}, n2 = r2.chart.renderer.boxWrapper, l2 = t3 instanceof o, h2 = t3 instanceof s, d2 = "highcharts-legend-" + (l2 ? "point" : "series") + "-active", c2 = r2.chart.styledMode, p2 = i3 ? [e3, a2.symbol] : [a2.group], u12 = (e4) => {
22294              r2.allItems.forEach((i4) => {
22295                t3 !== i4 && [i4].concat(i4.linkedSeries || []).forEach((t4) => {
22296                  t4.setState(e4, !l2);
22297                });
22298              });
22299            };
22300            for (let i4 of p2) i4 && i4.on("mouseover", function() {
22301              t3.visible && u12("inactive"), t3.setState("hover"), t3.visible && n2.addClass(d2), c2 || e3.css(r2.options.itemHoverStyle);
22302            }).on("mouseout", function() {
22303              r2.chart.styledMode || e3.css(C(t3.visible ? r2.itemStyle : r2.itemHiddenStyle)), u12(""), n2.removeClass(d2), t3.setState();
22304            }).on("click", function(e4) {
22305              let i5 = function() {
22306                t3.setVisible && t3.setVisible(), u12(t3.visible ? "inactive" : "");
22307              };
22308              n2.removeClass(d2), k(r2, "itemClick", {
22309                browserEvent: e4,
22310                legendItem: t3
22311              }, i5), l2 ? t3.firePointEvent("legendItemClick", {
22312                browserEvent: e4
22313              }) : h2 && k(t3, "legendItemClick", {
22314                browserEvent: e4
22315              });
22316            });
22317          }
22318          createCheckboxForItem(t3) {
22319            t3.checkbox = x("input", {
22320              type: "checkbox",
22321              className: "highcharts-legend-checkbox",
22322              checked: t3.selected,
22323              defaultChecked: t3.selected
22324            }, this.options.itemCheckboxStyle, this.chart.container), m(t3.checkbox, "click", function(e3) {
22325              let i3 = e3.target;
22326              k(t3.series || t3, "checkboxClick", {
22327                checked: i3.checked,
22328                item: t3
22329              }, function() {
22330                t3.select();
22331              });
22332            });
22333          }
22334        }
22335        return (l = L || (L = {})).compose = function(t3) {
22336          w(p, "Core.Legend") && m(t3, "beforeMargins", function() {
22337            this.legend = new l(this, this.options.legend);
22338          });
22339        }, L;
22340      }), i(e, "Core/Chart/Chart.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Axis/Axis.js"], e["Core/Defaults.js"], e["Core/Templating.js"], e["Core/Foundation.js"], e["Core/Globals.js"], e["Core/Renderer/RendererRegistry.js"], e["Core/Series/Series.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Renderer/SVG/SVGRenderer.js"], e["Core/Time.js"], e["Core/Utilities.js"], e["Core/Renderer/HTML/AST.js"], e["Core/Axis/Tick.js"]], function(t2, e2, i2, s, o, r, a, n, l, h, d, c, p, u11) {
22341        let {
22342          animate: g,
22343          animObject: f,
22344          setAnimation: m
22345        } = t2, {
22346          defaultOptions: x,
22347          defaultTime: y
22348        } = i2, {
22349          numberFormat: b
22350        } = s, {
22351          registerEventOptions: v
22352        } = o, {
22353          charts: S2,
22354          doc: k,
22355          marginNames: M,
22356          svg: C,
22357          win: A
22358        } = r, {
22359          seriesTypes: w
22360        } = l, {
22361          addEvent: T2,
22362          attr: P,
22363          createElement: O,
22364          css: L,
22365          defined: D2,
22366          diffObjects: E,
22367          discardElement: B,
22368          erase: j,
22369          error: R,
22370          extend: I,
22371          find: z,
22372          fireEvent: G,
22373          getStyle: N,
22374          isArray: W,
22375          isNumber: H,
22376          isObject: X,
22377          isString: F,
22378          merge: U,
22379          objectEach: Y,
22380          pick: V,
22381          pInt: _2,
22382          relativeLength: $,
22383          removeEvent: Z,
22384          splat: q,
22385          syncTimeout: K,
22386          uniqueKey: J
22387        } = c;
22388        class Q {
22389          static chart(t3, e3, i3) {
22390            return new Q(t3, e3, i3);
22391          }
22392          constructor(t3, e3, i3) {
22393            this.sharedClips = {};
22394            let s2 = [...arguments];
22395            (F(t3) || t3.nodeName) && (this.renderTo = s2.shift()), this.init(s2[0], s2[1]);
22396          }
22397          setZoomOptions() {
22398            let t3 = this.options.chart, e3 = t3.zooming;
22399            this.zooming = __spreadProps(__spreadValues({}, e3), {
22400              type: V(t3.zoomType, e3.type),
22401              key: V(t3.zoomKey, e3.key),
22402              pinchType: V(t3.pinchType, e3.pinchType),
22403              singleTouch: V(t3.zoomBySingleTouch, e3.singleTouch, false),
22404              resetButton: U(e3.resetButton, t3.resetZoomButton)
22405            });
22406          }
22407          init(t3, e3) {
22408            G(this, "init", {
22409              args: arguments
22410            }, function() {
22411              let i3 = U(x, t3), s2 = i3.chart;
22412              this.userOptions = I({}, t3), this.margin = [], this.spacing = [], this.labelCollectors = [], this.callback = e3, this.isResizing = 0, this.options = i3, this.axes = [], this.series = [], this.time = t3.time && Object.keys(t3.time).length ? new d(t3.time) : r.time, this.numberFormatter = s2.numberFormatter || b, this.styledMode = s2.styledMode, this.hasCartesianSeries = s2.showAxes, this.index = S2.length, S2.push(this), r.chartCount++, v(this, s2), this.xAxis = [], this.yAxis = [], this.pointCount = this.colorCounter = this.symbolCounter = 0, this.setZoomOptions(), G(this, "afterInit"), this.firstRender();
22413            });
22414          }
22415          initSeries(t3) {
22416            let e3 = this.options.chart, i3 = t3.type || e3.type, s2 = w[i3];
22417            s2 || R(17, true, this, {
22418              missingModuleFor: i3
22419            });
22420            let o2 = new s2();
22421            return "function" == typeof o2.init && o2.init(this, t3), o2;
22422          }
22423          setSortedData() {
22424            this.getSeriesOrderByLinks().forEach(function(t3) {
22425              t3.points || t3.data || !t3.enabledDataSorting || t3.setData(t3.options.data, false);
22426            });
22427          }
22428          getSeriesOrderByLinks() {
22429            return this.series.concat().sort(function(t3, e3) {
22430              return t3.linkedSeries.length || e3.linkedSeries.length ? e3.linkedSeries.length - t3.linkedSeries.length : 0;
22431            });
22432          }
22433          orderItems(t3, e3 = 0) {
22434            let i3 = this[t3], s2 = this.options[t3] = q(this.options[t3]).slice(), o2 = this.userOptions[t3] = this.userOptions[t3] ? q(this.userOptions[t3]).slice() : [];
22435            if (this.hasRendered && (s2.splice(e3), o2.splice(e3)), i3) for (let t4 = e3, r2 = i3.length; t4 < r2; ++t4) {
22436              let e4 = i3[t4];
22437              e4 && (e4.index = t4, e4 instanceof n && (e4.name = e4.getName()), e4.options.isInternal || (s2[t4] = e4.options, o2[t4] = e4.userOptions));
22438            }
22439          }
22440          isInsidePlot(t3, e3, i3 = {}) {
22441            let {
22442              inverted: s2,
22443              plotBox: o2,
22444              plotLeft: r2,
22445              plotTop: a2,
22446              scrollablePlotBox: n2
22447            } = this, {
22448              scrollLeft: l2 = 0,
22449              scrollTop: h2 = 0
22450            } = i3.visiblePlotOnly && this.scrollablePlotArea?.scrollingContainer || {}, d2 = i3.series, c2 = i3.visiblePlotOnly && n2 || o2, p2 = i3.inverted ? e3 : t3, u12 = i3.inverted ? t3 : e3, g2 = {
22451              x: p2,
22452              y: u12,
22453              isInsidePlot: true,
22454              options: i3
22455            };
22456            if (!i3.ignoreX) {
22457              let t4 = d2 && (s2 && !this.polar ? d2.yAxis : d2.xAxis) || {
22458                pos: r2,
22459                len: 1 / 0
22460              }, e4 = i3.paneCoordinates ? t4.pos + p2 : r2 + p2;
22461              e4 >= Math.max(l2 + r2, t4.pos) && e4 <= Math.min(l2 + r2 + c2.width, t4.pos + t4.len) || (g2.isInsidePlot = false);
22462            }
22463            if (!i3.ignoreY && g2.isInsidePlot) {
22464              let t4 = !s2 && i3.axis && !i3.axis.isXAxis && i3.axis || d2 && (s2 ? d2.xAxis : d2.yAxis) || {
22465                pos: a2,
22466                len: 1 / 0
22467              }, e4 = i3.paneCoordinates ? t4.pos + u12 : a2 + u12;
22468              e4 >= Math.max(h2 + a2, t4.pos) && e4 <= Math.min(h2 + a2 + c2.height, t4.pos + t4.len) || (g2.isInsidePlot = false);
22469            }
22470            return G(this, "afterIsInsidePlot", g2), g2.isInsidePlot;
22471          }
22472          redraw(t3) {
22473            G(this, "beforeRedraw");
22474            let e3 = this.hasCartesianSeries ? this.axes : this.colorAxis || [], i3 = this.series, s2 = this.pointer, o2 = this.legend, r2 = this.userOptions.legend, a2 = this.renderer, n2 = a2.isHidden(), l2 = [], h2, d2, c2, p2 = this.isDirtyBox, u12 = this.isDirtyLegend, g2;
22475            for (a2.rootFontSize = a2.boxWrapper.getStyle("font-size"), this.setResponsive && this.setResponsive(false), m(!!this.hasRendered && t3, this), n2 && this.temporaryDisplay(), this.layOutTitles(false), c2 = i3.length; c2--; ) if (((g2 = i3[c2]).options.stacking || g2.options.centerInCategory) && (d2 = true, g2.isDirty)) {
22476              h2 = true;
22477              break;
22478            }
22479            if (h2) for (c2 = i3.length; c2--; ) (g2 = i3[c2]).options.stacking && (g2.isDirty = true);
22480            i3.forEach(function(t4) {
22481              t4.isDirty && ("point" === t4.options.legendType ? ("function" == typeof t4.updateTotals && t4.updateTotals(), u12 = true) : r2 && (r2.labelFormatter || r2.labelFormat) && (u12 = true)), t4.isDirtyData && G(t4, "updatedData");
22482            }), u12 && o2 && o2.options.enabled && (o2.render(), this.isDirtyLegend = false), d2 && this.getStacks(), e3.forEach(function(t4) {
22483              t4.updateNames(), t4.setScale();
22484            }), this.getMargins(), e3.forEach(function(t4) {
22485              t4.isDirty && (p2 = true);
22486            }), e3.forEach(function(t4) {
22487              let e4 = t4.min + "," + t4.max;
22488              t4.extKey !== e4 && (t4.extKey = e4, l2.push(function() {
22489                G(t4, "afterSetExtremes", I(t4.eventArgs, t4.getExtremes())), delete t4.eventArgs;
22490              })), (p2 || d2) && t4.redraw();
22491            }), p2 && this.drawChartBox(), G(this, "predraw"), i3.forEach(function(t4) {
22492              (p2 || t4.isDirty) && t4.visible && t4.redraw(), t4.isDirtyData = false;
22493            }), s2 && s2.reset(true), a2.draw(), G(this, "redraw"), G(this, "render"), n2 && this.temporaryDisplay(true), l2.forEach(function(t4) {
22494              t4.call();
22495            });
22496          }
22497          get(t3) {
22498            let e3 = this.series;
22499            function i3(e4) {
22500              return e4.id === t3 || e4.options && e4.options.id === t3;
22501            }
22502            let s2 = z(this.axes, i3) || z(this.series, i3);
22503            for (let t4 = 0; !s2 && t4 < e3.length; t4++) s2 = z(e3[t4].points || [], i3);
22504            return s2;
22505          }
22506          getAxes() {
22507            let t3 = this.userOptions;
22508            for (let i3 of (G(this, "getAxes"), ["xAxis", "yAxis"])) for (let s2 of t3[i3] = q(t3[i3] || {})) new e2(this, s2, i3);
22509            G(this, "afterGetAxes");
22510          }
22511          getSelectedPoints() {
22512            return this.series.reduce((t3, e3) => (e3.getPointsCollection().forEach((e4) => {
22513              V(e4.selectedStaging, e4.selected) && t3.push(e4);
22514            }), t3), []);
22515          }
22516          getSelectedSeries() {
22517            return this.series.filter(function(t3) {
22518              return t3.selected;
22519            });
22520          }
22521          setTitle(t3, e3, i3) {
22522            this.applyDescription("title", t3), this.applyDescription("subtitle", e3), this.applyDescription("caption", void 0), this.layOutTitles(i3);
22523          }
22524          applyDescription(t3, e3) {
22525            let i3 = this, s2 = this.options[t3] = U(this.options[t3], e3), o2 = this[t3];
22526            o2 && e3 && (this[t3] = o2 = o2.destroy()), s2 && !o2 && ((o2 = this.renderer.text(s2.text, 0, 0, s2.useHTML).attr({
22527              align: s2.align,
22528              class: "highcharts-" + t3,
22529              zIndex: s2.zIndex || 4
22530            }).add()).update = function(e4, s3) {
22531              i3.applyDescription(t3, e4), i3.layOutTitles(s3);
22532            }, this.styledMode || o2.css(I("title" === t3 ? {
22533              fontSize: this.options.isStock ? "1em" : "1.2em"
22534            } : {}, s2.style)), this[t3] = o2);
22535          }
22536          layOutTitles(t3 = true) {
22537            let e3 = [0, 0, 0], i3 = this.renderer, s2 = this.spacingBox;
22538            ["title", "subtitle", "caption"].forEach(function(t4) {
22539              let o3 = this[t4], r2 = this.options[t4], a2 = r2.verticalAlign || "top", n2 = "title" === t4 ? "top" === a2 ? -3 : 0 : "top" === a2 ? e3[0] + 2 : 0;
22540              if (o3) {
22541                o3.css({
22542                  width: (r2.width || s2.width + (r2.widthAdjust || 0)) + "px"
22543                });
22544                let t5 = i3.fontMetrics(o3).b, l2 = Math.round(o3.getBBox(r2.useHTML).height);
22545                o3.align(I({
22546                  y: "bottom" === a2 ? t5 : n2 + t5,
22547                  height: l2
22548                }, r2), false, "spacingBox"), r2.floating || ("top" === a2 ? e3[0] = Math.ceil(e3[0] + l2) : "bottom" === a2 && (e3[2] = Math.ceil(e3[2] + l2)));
22549              }
22550            }, this), e3[0] && "top" === (this.options.title.verticalAlign || "top") && (e3[0] += this.options.title.margin), e3[2] && "bottom" === this.options.caption.verticalAlign && (e3[2] += this.options.caption.margin);
22551            let o2 = !this.titleOffset || this.titleOffset.join(",") !== e3.join(",");
22552            this.titleOffset = e3, G(this, "afterLayOutTitles"), !this.isDirtyBox && o2 && (this.isDirtyBox = this.isDirtyLegend = o2, this.hasRendered && t3 && this.isDirtyBox && this.redraw());
22553          }
22554          getContainerBox() {
22555            let t3 = [].map.call(this.renderTo.children, (t4) => {
22556              if (t4 !== this.container) {
22557                let e4 = t4.style.display;
22558                return t4.style.display = "none", [t4, e4];
22559              }
22560            }), e3 = {
22561              width: N(this.renderTo, "width", true) || 0,
22562              height: N(this.renderTo, "height", true) || 0
22563            };
22564            return t3.filter(Boolean).forEach(([t4, e4]) => {
22565              t4.style.display = e4;
22566            }), e3;
22567          }
22568          getChartSize() {
22569            let t3 = this.options.chart, e3 = t3.width, i3 = t3.height, s2 = this.getContainerBox(), o2 = s2.height > 1 && !(!this.renderTo.parentElement?.style.height && "100%" === this.renderTo.style.height);
22570            this.chartWidth = Math.max(0, e3 || s2.width || 600), this.chartHeight = Math.max(0, $(i3, this.chartWidth) || (o2 ? s2.height : 400)), this.containerBox = s2;
22571          }
22572          temporaryDisplay(t3) {
22573            let e3 = this.renderTo, i3;
22574            if (t3) for (; e3 && e3.style; ) e3.hcOrigStyle && (L(e3, e3.hcOrigStyle), delete e3.hcOrigStyle), e3.hcOrigDetached && (k.body.removeChild(e3), e3.hcOrigDetached = false), e3 = e3.parentNode;
22575            else for (; e3 && e3.style && (k.body.contains(e3) || e3.parentNode || (e3.hcOrigDetached = true, k.body.appendChild(e3)), ("none" === N(e3, "display", false) || e3.hcOricDetached) && (e3.hcOrigStyle = {
22576              display: e3.style.display,
22577              height: e3.style.height,
22578              overflow: e3.style.overflow
22579            }, i3 = {
22580              display: "block",
22581              overflow: "hidden"
22582            }, e3 !== this.renderTo && (i3.height = 0), L(e3, i3), e3.offsetWidth || e3.style.setProperty("display", "block", "important")), (e3 = e3.parentNode) !== k.body); ) ;
22583          }
22584          setClassName(t3) {
22585            this.container.className = "highcharts-container " + (t3 || "");
22586          }
22587          getContainer() {
22588            let t3 = this.options, e3 = t3.chart, i3 = "data-highcharts-chart", s2 = J(), o2, r2 = this.renderTo;
22589            r2 || (this.renderTo = r2 = e3.renderTo), F(r2) && (this.renderTo = r2 = k.getElementById(r2)), r2 || R(13, true, this);
22590            let n2 = _2(P(r2, i3));
22591            H(n2) && S2[n2] && S2[n2].hasRendered && S2[n2].destroy(), P(r2, i3, this.index), r2.innerHTML = p.emptyHTML, e3.skipClone || r2.offsetWidth || this.temporaryDisplay(), this.getChartSize();
22592            let l2 = this.chartHeight, d2 = this.chartWidth;
22593            L(r2, {
22594              overflow: "hidden"
22595            }), this.styledMode || (o2 = I({
22596              position: "relative",
22597              overflow: "hidden",
22598              width: d2 + "px",
22599              height: l2 + "px",
22600              textAlign: "left",
22601              lineHeight: "normal",
22602              zIndex: 0,
22603              "-webkit-tap-highlight-color": "rgba(0,0,0,0)",
22604              userSelect: "none",
22605              "touch-action": "manipulation",
22606              outline: "none",
22607              padding: "0px"
22608            }, e3.style || {}));
22609            let c2 = O("div", {
22610              id: s2
22611            }, o2, r2);
22612            this.container = c2, this.getChartSize(), d2 === this.chartWidth || (d2 = this.chartWidth, this.styledMode || L(c2, {
22613              width: V(e3.style?.width, d2 + "px")
22614            })), this.containerBox = this.getContainerBox(), this._cursor = c2.style.cursor;
22615            let u12 = e3.renderer || !C ? a.getRendererType(e3.renderer) : h;
22616            if (this.renderer = new u12(c2, d2, l2, void 0, e3.forExport, t3.exporting && t3.exporting.allowHTML, this.styledMode), m(void 0, this), this.setClassName(e3.className), this.styledMode) for (let e4 in t3.defs) this.renderer.definition(t3.defs[e4]);
22617            else this.renderer.setStyle(e3.style);
22618            this.renderer.chartIndex = this.index, G(this, "afterGetContainer");
22619          }
22620          getMargins(t3) {
22621            let {
22622              spacing: e3,
22623              margin: i3,
22624              titleOffset: s2
22625            } = this;
22626            this.resetMargins(), s2[0] && !D2(i3[0]) && (this.plotTop = Math.max(this.plotTop, s2[0] + e3[0])), s2[2] && !D2(i3[2]) && (this.marginBottom = Math.max(this.marginBottom, s2[2] + e3[2])), this.legend && this.legend.display && this.legend.adjustMargins(i3, e3), G(this, "getMargins"), t3 || this.getAxisMargins();
22627          }
22628          getAxisMargins() {
22629            let t3 = this, e3 = t3.axisOffset = [0, 0, 0, 0], i3 = t3.colorAxis, s2 = t3.margin, o2 = function(t4) {
22630              t4.forEach(function(t5) {
22631                t5.visible && t5.getOffset();
22632              });
22633            };
22634            t3.hasCartesianSeries ? o2(t3.axes) : i3 && i3.length && o2(i3), M.forEach(function(i4, o3) {
22635              D2(s2[o3]) || (t3[i4] += e3[o3]);
22636            }), t3.setChartSize();
22637          }
22638          getOptions() {
22639            return E(this.userOptions, x);
22640          }
22641          reflow(t3) {
22642            let e3 = this, i3 = e3.containerBox, s2 = e3.getContainerBox();
22643            delete e3.pointer?.chartPosition, !e3.isPrinting && !e3.isResizing && i3 && s2.width && ((s2.width !== i3.width || s2.height !== i3.height) && (c.clearTimeout(e3.reflowTimeout), e3.reflowTimeout = K(function() {
22644              e3.container && e3.setSize(void 0, void 0, false);
22645            }, t3 ? 100 : 0)), e3.containerBox = s2);
22646          }
22647          setReflow() {
22648            let t3 = this, e3 = (e4) => {
22649              t3.options?.chart.reflow && t3.hasLoaded && t3.reflow(e4);
22650            };
22651            if ("function" == typeof ResizeObserver) new ResizeObserver(e3).observe(t3.renderTo);
22652            else {
22653              let t4 = T2(A, "resize", e3);
22654              T2(this, "destroy", t4);
22655            }
22656          }
22657          setSize(t3, e3, i3) {
22658            let s2 = this, o2 = s2.renderer;
22659            s2.isResizing += 1, m(i3, s2);
22660            let r2 = o2.globalAnimation;
22661            s2.oldChartHeight = s2.chartHeight, s2.oldChartWidth = s2.chartWidth, void 0 !== t3 && (s2.options.chart.width = t3), void 0 !== e3 && (s2.options.chart.height = e3), s2.getChartSize();
22662            let {
22663              chartWidth: a2,
22664              chartHeight: n2,
22665              scrollablePixelsX: l2 = 0,
22666              scrollablePixelsY: h2 = 0
22667            } = s2;
22668            (s2.isDirtyBox || a2 !== s2.oldChartWidth || n2 !== s2.oldChartHeight) && (s2.styledMode || (r2 ? g : L)(s2.container, {
22669              width: `${a2 + l2}px`,
22670              height: `${n2 + h2}px`
22671            }, r2), s2.setChartSize(true), o2.setSize(a2, n2, r2), s2.axes.forEach(function(t4) {
22672              t4.isDirty = true, t4.setScale();
22673            }), s2.isDirtyLegend = true, s2.isDirtyBox = true, s2.layOutTitles(), s2.getMargins(), s2.redraw(r2), s2.oldChartHeight = void 0, G(s2, "resize"), setTimeout(() => {
22674              s2 && G(s2, "endResize");
22675            }, f(r2).duration)), s2.isResizing -= 1;
22676          }
22677          setChartSize(t3) {
22678            let e3, i3, s2, o2;
22679            let {
22680              chartHeight: r2,
22681              chartWidth: a2,
22682              inverted: n2,
22683              spacing: l2,
22684              renderer: h2
22685            } = this, d2 = this.clipOffset, c2 = Math[n2 ? "floor" : "round"];
22686            this.plotLeft = e3 = Math.round(this.plotLeft), this.plotTop = i3 = Math.round(this.plotTop), this.plotWidth = s2 = Math.max(0, Math.round(a2 - e3 - this.marginRight)), this.plotHeight = o2 = Math.max(0, Math.round(r2 - i3 - this.marginBottom)), this.plotSizeX = n2 ? o2 : s2, this.plotSizeY = n2 ? s2 : o2, this.spacingBox = h2.spacingBox = {
22687              x: l2[3],
22688              y: l2[0],
22689              width: a2 - l2[3] - l2[1],
22690              height: r2 - l2[0] - l2[2]
22691            }, this.plotBox = h2.plotBox = {
22692              x: e3,
22693              y: i3,
22694              width: s2,
22695              height: o2
22696            }, d2 && (this.clipBox = {
22697              x: c2(d2[3]),
22698              y: c2(d2[0]),
22699              width: c2(this.plotSizeX - d2[1] - d2[3]),
22700              height: c2(this.plotSizeY - d2[0] - d2[2])
22701            }), t3 || (this.axes.forEach(function(t4) {
22702              t4.setAxisSize(), t4.setAxisTranslation();
22703            }), h2.alignElements()), G(this, "afterSetChartSize", {
22704              skipAxes: t3
22705            });
22706          }
22707          resetMargins() {
22708            G(this, "resetMargins");
22709            let t3 = this, e3 = t3.options.chart, i3 = e3.plotBorderWidth || 0, s2 = i3 / 2;
22710            ["margin", "spacing"].forEach(function(i4) {
22711              let s3 = e3[i4], o2 = X(s3) ? s3 : [s3, s3, s3, s3];
22712              ["Top", "Right", "Bottom", "Left"].forEach(function(s4, r2) {
22713                t3[i4][r2] = V(e3[i4 + s4], o2[r2]);
22714              });
22715            }), M.forEach(function(e4, i4) {
22716              t3[e4] = V(t3.margin[i4], t3.spacing[i4]);
22717            }), t3.axisOffset = [0, 0, 0, 0], t3.clipOffset = [s2, s2, s2, s2], t3.plotBorderWidth = i3;
22718          }
22719          drawChartBox() {
22720            let t3 = this.options.chart, e3 = this.renderer, i3 = this.chartWidth, s2 = this.chartHeight, o2 = this.styledMode, r2 = this.plotBGImage, a2 = t3.backgroundColor, n2 = t3.plotBackgroundColor, l2 = t3.plotBackgroundImage, h2 = this.plotLeft, d2 = this.plotTop, c2 = this.plotWidth, p2 = this.plotHeight, u12 = this.plotBox, g2 = this.clipRect, f2 = this.clipBox, m2 = this.chartBackground, x2 = this.plotBackground, y2 = this.plotBorder, b2, v2, S3, k2 = "animate";
22721            m2 || (this.chartBackground = m2 = e3.rect().addClass("highcharts-background").add(), k2 = "attr"), o2 ? b2 = v2 = m2.strokeWidth() : (v2 = (b2 = t3.borderWidth || 0) + (t3.shadow ? 8 : 0), S3 = {
22722              fill: a2 || "none"
22723            }, (b2 || m2["stroke-width"]) && (S3.stroke = t3.borderColor, S3["stroke-width"] = b2), m2.attr(S3).shadow(t3.shadow)), m2[k2]({
22724              x: v2 / 2,
22725              y: v2 / 2,
22726              width: i3 - v2 - b2 % 2,
22727              height: s2 - v2 - b2 % 2,
22728              r: t3.borderRadius
22729            }), k2 = "animate", x2 || (k2 = "attr", this.plotBackground = x2 = e3.rect().addClass("highcharts-plot-background").add()), x2[k2](u12), !o2 && (x2.attr({
22730              fill: n2 || "none"
22731            }).shadow(t3.plotShadow), l2 && (r2 ? (l2 !== r2.attr("href") && r2.attr("href", l2), r2.animate(u12)) : this.plotBGImage = e3.image(l2, h2, d2, c2, p2).add())), g2 ? g2.animate({
22732              width: f2.width,
22733              height: f2.height
22734            }) : this.clipRect = e3.clipRect(f2), k2 = "animate", y2 || (k2 = "attr", this.plotBorder = y2 = e3.rect().addClass("highcharts-plot-border").attr({
22735              zIndex: 1
22736            }).add()), o2 || y2.attr({
22737              stroke: t3.plotBorderColor,
22738              "stroke-width": t3.plotBorderWidth || 0,
22739              fill: "none"
22740            }), y2[k2](y2.crisp({
22741              x: h2,
22742              y: d2,
22743              width: c2,
22744              height: p2
22745            }, -y2.strokeWidth())), this.isDirtyBox = false, G(this, "afterDrawChartBox");
22746          }
22747          propFromSeries() {
22748            let t3, e3, i3;
22749            let s2 = this, o2 = s2.options.chart, r2 = s2.options.series;
22750            ["inverted", "angular", "polar"].forEach(function(a2) {
22751              for (e3 = w[o2.type], i3 = o2[a2] || e3 && e3.prototype[a2], t3 = r2 && r2.length; !i3 && t3--; ) (e3 = w[r2[t3].type]) && e3.prototype[a2] && (i3 = true);
22752              s2[a2] = i3;
22753            });
22754          }
22755          linkSeries(t3) {
22756            let e3 = this, i3 = e3.series;
22757            i3.forEach(function(t4) {
22758              t4.linkedSeries.length = 0;
22759            }), i3.forEach(function(t4) {
22760              let {
22761                linkedTo: i4
22762              } = t4.options;
22763              if (F(i4)) {
22764                let s2;
22765                (s2 = ":previous" === i4 ? e3.series[t4.index - 1] : e3.get(i4)) && s2.linkedParent !== t4 && (s2.linkedSeries.push(t4), t4.linkedParent = s2, s2.enabledDataSorting && t4.setDataSortingOptions(), t4.visible = V(t4.options.visible, s2.options.visible, t4.visible));
22766              }
22767            }), G(this, "afterLinkSeries", {
22768              isUpdating: t3
22769            });
22770          }
22771          renderSeries() {
22772            this.series.forEach(function(t3) {
22773              t3.translate(), t3.render();
22774            });
22775          }
22776          render() {
22777            let t3 = this.axes, e3 = this.colorAxis, i3 = this.renderer, s2 = this.options.chart.axisLayoutRuns || 2, o2 = (t4) => {
22778              t4.forEach((t5) => {
22779                t5.visible && t5.render();
22780              });
22781            }, r2 = 0, a2 = true, n2, l2 = 0;
22782            for (let e4 of (this.setTitle(), G(this, "beforeMargins"), this.getStacks?.(), this.getMargins(true), this.setChartSize(), t3)) {
22783              let {
22784                options: t4
22785              } = e4, {
22786                labels: i4
22787              } = t4;
22788              if (this.hasCartesianSeries && e4.horiz && e4.visible && i4.enabled && e4.series.length && "colorAxis" !== e4.coll && !this.polar) {
22789                r2 = t4.tickLength, e4.createGroups();
22790                let s3 = new u11(e4, 0, "", true), o3 = s3.createLabel("x", i4);
22791                if (s3.destroy(), o3 && V(i4.reserveSpace, !H(t4.crossing)) && (r2 = o3.getBBox().height + i4.distance + Math.max(t4.offset || 0, 0)), r2) {
22792                  o3?.destroy();
22793                  break;
22794                }
22795              }
22796            }
22797            for (this.plotHeight = Math.max(this.plotHeight - r2, 0); (a2 || n2 || s2 > 1) && l2 < s2; ) {
22798              let e4 = this.plotWidth, i4 = this.plotHeight;
22799              for (let e5 of t3) 0 === l2 ? e5.setScale() : (e5.horiz && a2 || !e5.horiz && n2) && e5.setTickInterval(true);
22800              0 === l2 ? this.getAxisMargins() : this.getMargins(), a2 = e4 / this.plotWidth > (l2 ? 1 : 1.1), n2 = i4 / this.plotHeight > (l2 ? 1 : 1.05), l2++;
22801            }
22802            this.drawChartBox(), this.hasCartesianSeries ? o2(t3) : e3 && e3.length && o2(e3), this.seriesGroup || (this.seriesGroup = i3.g("series-group").attr({
22803              zIndex: 3
22804            }).shadow(this.options.chart.seriesGroupShadow).add()), this.renderSeries(), this.addCredits(), this.setResponsive && this.setResponsive(), this.hasRendered = true;
22805          }
22806          addCredits(t3) {
22807            let e3 = this, i3 = U(true, this.options.credits, t3);
22808            i3.enabled && !this.credits && (this.credits = this.renderer.text(i3.text + (this.mapCredits || ""), 0, 0).addClass("highcharts-credits").on("click", function() {
22809              i3.href && (A.location.href = i3.href);
22810            }).attr({
22811              align: i3.position.align,
22812              zIndex: 8
22813            }), e3.styledMode || this.credits.css(i3.style), this.credits.add().align(i3.position), this.credits.update = function(t4) {
22814              e3.credits = e3.credits.destroy(), e3.addCredits(t4);
22815            });
22816          }
22817          destroy() {
22818            let t3;
22819            let e3 = this, i3 = e3.axes, s2 = e3.series, o2 = e3.container, a2 = o2 && o2.parentNode;
22820            for (G(e3, "destroy"), e3.renderer.forExport ? j(S2, e3) : S2[e3.index] = void 0, r.chartCount--, e3.renderTo.removeAttribute("data-highcharts-chart"), Z(e3), t3 = i3.length; t3--; ) i3[t3] = i3[t3].destroy();
22821            for (this.scroller && this.scroller.destroy && this.scroller.destroy(), t3 = s2.length; t3--; ) s2[t3] = s2[t3].destroy();
22822            ["title", "subtitle", "chartBackground", "plotBackground", "plotBGImage", "plotBorder", "seriesGroup", "clipRect", "credits", "pointer", "rangeSelector", "legend", "resetZoomButton", "tooltip", "renderer"].forEach(function(t4) {
22823              let i4 = e3[t4];
22824              i4 && i4.destroy && (e3[t4] = i4.destroy());
22825            }), o2 && (o2.innerHTML = p.emptyHTML, Z(o2), a2 && B(o2)), Y(e3, function(t4, i4) {
22826              delete e3[i4];
22827            });
22828          }
22829          firstRender() {
22830            let t3 = this, e3 = t3.options;
22831            t3.getContainer(), t3.resetMargins(), t3.setChartSize(), t3.propFromSeries(), t3.getAxes();
22832            let i3 = W(e3.series) ? e3.series : [];
22833            e3.series = [], i3.forEach(function(e4) {
22834              t3.initSeries(e4);
22835            }), t3.linkSeries(), t3.setSortedData(), G(t3, "beforeRender"), t3.render(), t3.pointer?.getChartPosition(), t3.renderer.imgCount || t3.hasLoaded || t3.onload(), t3.temporaryDisplay(true);
22836          }
22837          onload() {
22838            this.callbacks.concat([this.callback]).forEach(function(t3) {
22839              t3 && void 0 !== this.index && t3.apply(this, [this]);
22840            }, this), G(this, "load"), G(this, "render"), D2(this.index) && this.setReflow(), this.warnIfA11yModuleNotLoaded(), this.hasLoaded = true;
22841          }
22842          warnIfA11yModuleNotLoaded() {
22843            let {
22844              options: t3,
22845              title: e3
22846            } = this;
22847            !t3 || this.accessibility || (this.renderer.boxWrapper.attr({
22848              role: "img",
22849              "aria-label": (e3 && e3.element.textContent || "").replace(/</g, "&lt;")
22850            }), t3.accessibility && false === t3.accessibility.enabled || R('Highcharts warning: Consider including the "accessibility.js" module to make your chart more usable for people with disabilities. Set the "accessibility.enabled" option to false to remove this warning. See https://www.highcharts.com/docs/accessibility/accessibility-module.', false, this));
22851          }
22852          addSeries(t3, e3, i3) {
22853            let s2;
22854            let o2 = this;
22855            return t3 && (e3 = V(e3, true), G(o2, "addSeries", {
22856              options: t3
22857            }, function() {
22858              s2 = o2.initSeries(t3), o2.isDirtyLegend = true, o2.linkSeries(), s2.enabledDataSorting && s2.setData(t3.data, false), G(o2, "afterAddSeries", {
22859                series: s2
22860              }), e3 && o2.redraw(i3);
22861            })), s2;
22862          }
22863          addAxis(t3, e3, i3, s2) {
22864            return this.createAxis(e3 ? "xAxis" : "yAxis", {
22865              axis: t3,
22866              redraw: i3,
22867              animation: s2
22868            });
22869          }
22870          addColorAxis(t3, e3, i3) {
22871            return this.createAxis("colorAxis", {
22872              axis: t3,
22873              redraw: e3,
22874              animation: i3
22875            });
22876          }
22877          createAxis(t3, i3) {
22878            let s2 = new e2(this, i3.axis, t3);
22879            return V(i3.redraw, true) && this.redraw(i3.animation), s2;
22880          }
22881          showLoading(t3) {
22882            let e3 = this, i3 = e3.options, s2 = i3.loading, o2 = function() {
22883              r2 && L(r2, {
22884                left: e3.plotLeft + "px",
22885                top: e3.plotTop + "px",
22886                width: e3.plotWidth + "px",
22887                height: e3.plotHeight + "px"
22888              });
22889            }, r2 = e3.loadingDiv, a2 = e3.loadingSpan;
22890            r2 || (e3.loadingDiv = r2 = O("div", {
22891              className: "highcharts-loading highcharts-loading-hidden"
22892            }, null, e3.container)), a2 || (e3.loadingSpan = a2 = O("span", {
22893              className: "highcharts-loading-inner"
22894            }, null, r2), T2(e3, "redraw", o2)), r2.className = "highcharts-loading", p.setElementHTML(a2, V(t3, i3.lang.loading, "")), e3.styledMode || (L(r2, I(s2.style, {
22895              zIndex: 10
22896            })), L(a2, s2.labelStyle), e3.loadingShown || (L(r2, {
22897              opacity: 0,
22898              display: ""
22899            }), g(r2, {
22900              opacity: s2.style.opacity || 0.5
22901            }, {
22902              duration: s2.showDuration || 0
22903            }))), e3.loadingShown = true, o2();
22904          }
22905          hideLoading() {
22906            let t3 = this.options, e3 = this.loadingDiv;
22907            e3 && (e3.className = "highcharts-loading highcharts-loading-hidden", this.styledMode || g(e3, {
22908              opacity: 0
22909            }, {
22910              duration: t3.loading.hideDuration || 100,
22911              complete: function() {
22912                L(e3, {
22913                  display: "none"
22914                });
22915              }
22916            })), this.loadingShown = false;
22917          }
22918          update(t3, e3, i3, s2) {
22919            let o2, r2, a2;
22920            let n2 = this, l2 = {
22921              credits: "addCredits",
22922              title: "setTitle",
22923              subtitle: "setSubtitle",
22924              caption: "setCaption"
22925            }, h2 = t3.isResponsiveOptions, c2 = [];
22926            G(n2, "update", {
22927              options: t3
22928            }), h2 || n2.setResponsive(false, true), t3 = E(t3, n2.options), n2.userOptions = U(n2.userOptions, t3);
22929            let p2 = t3.chart;
22930            p2 && (U(true, n2.options.chart, p2), this.setZoomOptions(), "className" in p2 && n2.setClassName(p2.className), ("inverted" in p2 || "polar" in p2 || "type" in p2) && (n2.propFromSeries(), o2 = true), "alignTicks" in p2 && (o2 = true), "events" in p2 && v(this, p2), Y(p2, function(t4, e4) {
22931              -1 !== n2.propsRequireUpdateSeries.indexOf("chart." + e4) && (r2 = true), -1 !== n2.propsRequireDirtyBox.indexOf(e4) && (n2.isDirtyBox = true), -1 === n2.propsRequireReflow.indexOf(e4) || (n2.isDirtyBox = true, h2 || (a2 = true));
22932            }), !n2.styledMode && p2.style && n2.renderer.setStyle(n2.options.chart.style || {})), !n2.styledMode && t3.colors && (this.options.colors = t3.colors), t3.time && (this.time === y && (this.time = new d(t3.time)), U(true, n2.options.time, t3.time)), Y(t3, function(e4, i4) {
22933              n2[i4] && "function" == typeof n2[i4].update ? n2[i4].update(e4, false) : "function" == typeof n2[l2[i4]] ? n2[l2[i4]](e4) : "colors" !== i4 && -1 === n2.collectionsWithUpdate.indexOf(i4) && U(true, n2.options[i4], t3[i4]), "chart" !== i4 && -1 !== n2.propsRequireUpdateSeries.indexOf(i4) && (r2 = true);
22934            }), this.collectionsWithUpdate.forEach(function(e4) {
22935              t3[e4] && (q(t3[e4]).forEach(function(t4, s3) {
22936                let o3;
22937                let r3 = D2(t4.id);
22938                r3 && (o3 = n2.get(t4.id)), !o3 && n2[e4] && (o3 = n2[e4][V(t4.index, s3)]) && (r3 && D2(o3.options.id) || o3.options.isInternal) && (o3 = void 0), o3 && o3.coll === e4 && (o3.update(t4, false), i3 && (o3.touched = true)), !o3 && i3 && n2.collectionsWithInit[e4] && (n2.collectionsWithInit[e4][0].apply(n2, [t4].concat(n2.collectionsWithInit[e4][1] || []).concat([false])).touched = true);
22939              }), i3 && n2[e4].forEach(function(t4) {
22940                t4.touched || t4.options.isInternal ? delete t4.touched : c2.push(t4);
22941              }));
22942            }), c2.forEach(function(t4) {
22943              t4.chart && t4.remove && t4.remove(false);
22944            }), o2 && n2.axes.forEach(function(t4) {
22945              t4.update({}, false);
22946            }), r2 && n2.getSeriesOrderByLinks().forEach(function(t4) {
22947              t4.chart && t4.update({}, false);
22948            }, this);
22949            let u12 = p2 && p2.width, g2 = p2 && (F(p2.height) ? $(p2.height, u12 || n2.chartWidth) : p2.height);
22950            a2 || H(u12) && u12 !== n2.chartWidth || H(g2) && g2 !== n2.chartHeight ? n2.setSize(u12, g2, s2) : V(e3, true) && n2.redraw(s2), G(n2, "afterUpdate", {
22951              options: t3,
22952              redraw: e3,
22953              animation: s2
22954            });
22955          }
22956          setSubtitle(t3, e3) {
22957            this.applyDescription("subtitle", t3), this.layOutTitles(e3);
22958          }
22959          setCaption(t3, e3) {
22960            this.applyDescription("caption", t3), this.layOutTitles(e3);
22961          }
22962          showResetZoom() {
22963            let t3 = this, e3 = x.lang, i3 = t3.zooming.resetButton, s2 = i3.theme, o2 = "chart" === i3.relativeTo || "spacingBox" === i3.relativeTo ? null : "plotBox";
22964            function r2() {
22965              t3.zoomOut();
22966            }
22967            G(this, "beforeShowResetZoom", null, function() {
22968              t3.resetZoomButton = t3.renderer.button(e3.resetZoom, null, null, r2, s2).attr({
22969                align: i3.position.align,
22970                title: e3.resetZoomTitle
22971              }).addClass("highcharts-reset-zoom").add().align(i3.position, false, o2);
22972            }), G(this, "afterShowResetZoom");
22973          }
22974          zoomOut() {
22975            G(this, "selection", {
22976              resetSelection: true
22977            }, () => this.transform({
22978              reset: true,
22979              trigger: "zoom"
22980            }));
22981          }
22982          pan(t3, e3) {
22983            let i3 = this, s2 = "object" == typeof e3 ? e3 : {
22984              enabled: e3,
22985              type: "x"
22986            }, o2 = s2.type, r2 = o2 && i3[{
22987              x: "xAxis",
22988              xy: "axes",
22989              y: "yAxis"
22990            }[o2]].filter((t4) => t4.options.panningEnabled && !t4.options.isInternal), a2 = i3.options.chart;
22991            a2?.panning && (a2.panning = s2), G(this, "pan", {
22992              originalEvent: t3
22993            }, () => {
22994              i3.transform({
22995                axes: r2,
22996                event: t3,
22997                to: {
22998                  x: t3.chartX - (i3.mouseDownX || 0),
22999                  y: t3.chartY - (i3.mouseDownY || 0)
23000                },
23001                trigger: "pan"
23002              }), L(i3.container, {
23003                cursor: "move"
23004              });
23005            });
23006          }
23007          transform(t3) {
23008            let {
23009              axes: e3 = this.axes,
23010              event: i3,
23011              from: s2 = {},
23012              reset: o2,
23013              selection: r2,
23014              to: a2 = {},
23015              trigger: n2
23016            } = t3, {
23017              inverted: l2
23018            } = this, h2 = false, d2, c2;
23019            for (let t4 of (this.hoverPoints?.forEach((t5) => t5.setState()), e3)) {
23020              let {
23021                horiz: e4,
23022                len: p2,
23023                minPointOffset: u12 = 0,
23024                options: g2,
23025                reversed: f2
23026              } = t4, m2 = e4 ? "width" : "height", x2 = e4 ? "x" : "y", y2 = V(a2[m2], t4.len), b2 = V(s2[m2], t4.len), v2 = 10 > Math.abs(y2) ? 1 : y2 / b2, S3 = (s2[x2] || 0) + b2 / 2 - t4.pos, k2 = S3 - ((a2[x2] ?? t4.pos) + y2 / 2 - t4.pos) / v2, M2 = f2 && !l2 || !f2 && l2 ? -1 : 1;
23027              if (!o2 && (S3 < 0 || S3 > t4.len)) continue;
23028              let C2 = t4.toValue(k2, true) + (r2 || t4.isOrdinal ? 0 : u12 * M2), A2 = t4.toValue(k2 + p2 / v2, true) - (r2 || t4.isOrdinal ? 0 : u12 * M2 || 0), w2 = t4.allExtremes;
23029              if (C2 > A2 && ([C2, A2] = [A2, C2]), 1 === v2 && !o2 && "yAxis" === t4.coll && !w2) {
23030                for (let e5 of t4.series) {
23031                  let t5 = e5.getExtremes(e5.getProcessedData(true).yData, true);
23032                  w2 ?? (w2 = {
23033                    dataMin: Number.MAX_VALUE,
23034                    dataMax: -Number.MAX_VALUE
23035                  }), H(t5.dataMin) && H(t5.dataMax) && (w2.dataMin = Math.min(t5.dataMin, w2.dataMin), w2.dataMax = Math.max(t5.dataMax, w2.dataMax));
23036                }
23037                t4.allExtremes = w2;
23038              }
23039              let {
23040                dataMin: T3,
23041                dataMax: P2,
23042                min: O2,
23043                max: L2
23044              } = I(t4.getExtremes(), w2 || {}), E2 = T3 ?? g2.min, B2 = P2 ?? g2.max, j2 = A2 - C2, R2 = t4.categories ? 0 : Math.min(j2, B2 - E2), z2 = E2 - R2 * (D2(g2.min) ? 0 : g2.minPadding), G2 = B2 + R2 * (D2(g2.max) ? 0 : g2.maxPadding), N2 = t4.allowZoomOutside || 1 === v2 || "zoom" !== n2 && v2 > 1, W2 = Math.min(g2.min ?? z2, z2, N2 ? O2 : z2), X2 = Math.max(g2.max ?? G2, G2, N2 ? L2 : G2);
23045              (!t4.isOrdinal || t4.options.overscroll || 1 !== v2 || o2) && (C2 < W2 && (C2 = W2, v2 >= 1 && (A2 = C2 + j2)), A2 > X2 && (A2 = X2, v2 >= 1 && (C2 = A2 - j2)), (o2 || t4.series.length && (C2 !== O2 || A2 !== L2) && C2 >= W2 && A2 <= X2) && (r2 ? r2[t4.coll].push({
23046                axis: t4,
23047                min: C2,
23048                max: A2
23049              }) : (t4.isPanning = "zoom" !== n2, t4.isPanning && (c2 = true), t4.setExtremes(o2 ? void 0 : C2, o2 ? void 0 : A2, false, false, {
23050                move: k2,
23051                trigger: n2,
23052                scale: v2
23053              }), !o2 && (C2 > W2 || A2 < X2) && "mousewheel" !== n2 && (d2 = true)), h2 = true), i3 && (this[e4 ? "mouseDownX" : "mouseDownY"] = i3[e4 ? "chartX" : "chartY"]));
23054            }
23055            return h2 && (r2 ? G(this, "selection", r2, () => {
23056              delete t3.selection, t3.trigger = "zoom", this.transform(t3);
23057            }) : (!d2 || c2 || this.resetZoomButton ? !d2 && this.resetZoomButton && (this.resetZoomButton = this.resetZoomButton.destroy()) : this.showResetZoom(), this.redraw("zoom" === n2 && (this.options.chart.animation ?? this.pointCount < 100)))), h2;
23058          }
23059        }
23060        return I(Q.prototype, {
23061          callbacks: [],
23062          collectionsWithInit: {
23063            xAxis: [Q.prototype.addAxis, [true]],
23064            yAxis: [Q.prototype.addAxis, [false]],
23065            series: [Q.prototype.addSeries]
23066          },
23067          collectionsWithUpdate: ["xAxis", "yAxis", "series"],
23068          propsRequireDirtyBox: ["backgroundColor", "borderColor", "borderWidth", "borderRadius", "plotBackgroundColor", "plotBackgroundImage", "plotBorderColor", "plotBorderWidth", "plotShadow", "shadow"],
23069          propsRequireReflow: ["margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "spacing", "spacingTop", "spacingRight", "spacingBottom", "spacingLeft"],
23070          propsRequireUpdateSeries: ["chart.inverted", "chart.polar", "chart.ignoreHiddenSeries", "chart.type", "colors", "plotOptions", "time", "tooltip"]
23071        }), Q;
23072      }), i(e, "Extensions/ScrollablePlotArea.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Globals.js"], e["Core/Renderer/RendererRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
23073        let {
23074          stop: o
23075        } = t2, {
23076          composed: r
23077        } = e2, {
23078          addEvent: a,
23079          createElement: n,
23080          css: l,
23081          defined: h,
23082          merge: d,
23083          pushUnique: c
23084        } = s;
23085        function p() {
23086          let t3 = this.scrollablePlotArea;
23087          (this.scrollablePixelsX || this.scrollablePixelsY) && !t3 && (this.scrollablePlotArea = t3 = new g(this)), t3?.applyFixed();
23088        }
23089        function u11() {
23090          this.chart.scrollablePlotArea && (this.chart.scrollablePlotArea.isDirty = true);
23091        }
23092        class g {
23093          static compose(t3, e3, i3) {
23094            c(r, this.compose) && (a(t3, "afterInit", u11), a(e3, "afterSetChartSize", (t4) => this.afterSetSize(t4.target, t4)), a(e3, "render", p), a(i3, "show", u11));
23095          }
23096          static afterSetSize(t3, e3) {
23097            let i3, s2, o2;
23098            let {
23099              minWidth: r2,
23100              minHeight: a2
23101            } = t3.options.chart.scrollablePlotArea || {}, {
23102              clipBox: n2,
23103              plotBox: l2,
23104              inverted: c2,
23105              renderer: p2
23106            } = t3;
23107            if (!p2.forExport && (r2 ? (t3.scrollablePixelsX = i3 = Math.max(0, r2 - t3.chartWidth), i3 && (t3.scrollablePlotBox = d(t3.plotBox), l2.width = t3.plotWidth += i3, n2[c2 ? "height" : "width"] += i3, o2 = true)) : a2 && (t3.scrollablePixelsY = s2 = Math.max(0, a2 - t3.chartHeight), h(s2) && (t3.scrollablePlotBox = d(t3.plotBox), l2.height = t3.plotHeight += s2, n2[c2 ? "width" : "height"] += s2, o2 = false)), h(o2) && !e3.skipAxes)) for (let e4 of t3.axes) e4.horiz === o2 && (e4.setAxisSize(), e4.setAxisTranslation());
23108          }
23109          constructor(t3) {
23110            let e3;
23111            let s2 = t3.options.chart, o2 = i2.getRendererType(), r2 = s2.scrollablePlotArea || {}, h2 = this.moveFixedElements.bind(this), d2 = {
23112              WebkitOverflowScrolling: "touch",
23113              overflowX: "hidden",
23114              overflowY: "hidden"
23115            };
23116            t3.scrollablePixelsX && (d2.overflowX = "auto"), t3.scrollablePixelsY && (d2.overflowY = "auto"), this.chart = t3;
23117            let c2 = this.parentDiv = n("div", {
23118              className: "highcharts-scrolling-parent"
23119            }, {
23120              position: "relative"
23121            }, t3.renderTo), p2 = this.scrollingContainer = n("div", {
23122              className: "highcharts-scrolling"
23123            }, d2, c2), u12 = this.innerContainer = n("div", {
23124              className: "highcharts-inner-container"
23125            }, void 0, p2), g2 = this.fixedDiv = n("div", {
23126              className: "highcharts-fixed"
23127            }, {
23128              position: "absolute",
23129              overflow: "hidden",
23130              pointerEvents: "none",
23131              zIndex: (s2.style?.zIndex || 0) + 2,
23132              top: 0
23133            }, void 0, true), f = this.fixedRenderer = new o2(g2, t3.chartWidth, t3.chartHeight, s2.style);
23134            this.mask = f.path().attr({
23135              fill: s2.backgroundColor || "#fff",
23136              "fill-opacity": r2.opacity ?? 0.85,
23137              zIndex: -1
23138            }).addClass("highcharts-scrollable-mask").add(), p2.parentNode.insertBefore(g2, p2), l(t3.renderTo, {
23139              overflow: "visible"
23140            }), a(t3, "afterShowResetZoom", h2), a(t3, "afterApplyDrilldown", h2), a(t3, "afterLayOutTitles", h2), a(p2, "scroll", () => {
23141              let {
23142                pointer: i3,
23143                hoverPoint: s3
23144              } = t3;
23145              i3 && (delete i3.chartPosition, s3 && (e3 = s3), i3.runPointActions(void 0, e3, true));
23146            }), u12.appendChild(t3.container);
23147          }
23148          applyFixed() {
23149            let {
23150              chart: t3,
23151              fixedRenderer: e3,
23152              isDirty: i3,
23153              scrollingContainer: s2
23154            } = this, {
23155              axisOffset: r2,
23156              chartWidth: a2,
23157              chartHeight: n2,
23158              container: d2,
23159              plotHeight: c2,
23160              plotLeft: p2,
23161              plotTop: u12,
23162              plotWidth: g2,
23163              scrollablePixelsX: f = 0,
23164              scrollablePixelsY: m = 0
23165            } = t3, {
23166              scrollPositionX: x = 0,
23167              scrollPositionY: y = 0
23168            } = t3.options.chart.scrollablePlotArea || {}, b = a2 + f, v = n2 + m;
23169            e3.setSize(a2, n2), (i3 ?? true) && (this.isDirty = false, this.moveFixedElements()), o(t3.container), l(d2, {
23170              width: `${b}px`,
23171              height: `${v}px`
23172            }), t3.renderer.boxWrapper.attr({
23173              width: b,
23174              height: v,
23175              viewBox: [0, 0, b, v].join(" ")
23176            }), t3.chartBackground?.attr({
23177              width: b,
23178              height: v
23179            }), l(s2, {
23180              width: `${a2}px`,
23181              height: `${n2}px`
23182            }), h(i3) || (s2.scrollLeft = f * x, s2.scrollTop = m * y);
23183            let S2 = u12 - r2[0] - 1, k = p2 - r2[3] - 1, M = u12 + c2 + r2[2] + 1, C = p2 + g2 + r2[1] + 1, A = p2 + g2 - f, w = u12 + c2 - m, T2 = [["M", 0, 0]];
23184            f ? T2 = [["M", 0, S2], ["L", p2 - 1, S2], ["L", p2 - 1, M], ["L", 0, M], ["Z"], ["M", A, S2], ["L", a2, S2], ["L", a2, M], ["L", A, M], ["Z"]] : m && (T2 = [["M", k, 0], ["L", k, u12 - 1], ["L", C, u12 - 1], ["L", C, 0], ["Z"], ["M", k, w], ["L", k, n2], ["L", C, n2], ["L", C, w], ["Z"]]), "adjustHeight" !== t3.redrawTrigger && this.mask.attr({
23185              d: T2
23186            });
23187          }
23188          moveFixedElements() {
23189            let t3;
23190            let {
23191              container: e3,
23192              inverted: i3,
23193              scrollablePixelsX: s2,
23194              scrollablePixelsY: o2
23195            } = this.chart, r2 = this.fixedRenderer, a2 = g.fixedSelectors;
23196            for (let n2 of (s2 && !i3 ? t3 = ".highcharts-yaxis" : s2 && i3 ? t3 = ".highcharts-xaxis" : o2 && !i3 ? t3 = ".highcharts-xaxis" : o2 && i3 && (t3 = ".highcharts-yaxis"), t3 && a2.push(`${t3}:not(.highcharts-radial-axis)`, `${t3}-labels:not(.highcharts-radial-axis-labels)`), a2)) [].forEach.call(e3.querySelectorAll(n2), (t4) => {
23197              (t4.namespaceURI === r2.SVG_NS ? r2.box : r2.box.parentNode).appendChild(t4), t4.style.pointerEvents = "auto";
23198            });
23199          }
23200        }
23201        return g.fixedSelectors = [".highcharts-breadcrumbs-group", ".highcharts-contextbutton", ".highcharts-caption", ".highcharts-credits", ".highcharts-drillup-button", ".highcharts-legend", ".highcharts-legend-checkbox", ".highcharts-navigator-series", ".highcharts-navigator-xaxis", ".highcharts-navigator-yaxis", ".highcharts-navigator", ".highcharts-range-selector-group", ".highcharts-reset-zoom", ".highcharts-scrollbar", ".highcharts-subtitle", ".highcharts-title"], g;
23202      }), i(e, "Core/Axis/Stacking/StackItem.js", [e["Core/Templating.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
23203        let {
23204          format: s
23205        } = t2, {
23206          series: o
23207        } = e2, {
23208          destroyObjectProperties: r,
23209          fireEvent: a,
23210          isNumber: n,
23211          pick: l
23212        } = i2;
23213        return class {
23214          constructor(t3, e3, i3, s2, o2) {
23215            let r2 = t3.chart.inverted, a2 = t3.reversed;
23216            this.axis = t3;
23217            let n2 = this.isNegative = !!i3 != !!a2;
23218            this.options = e3 = e3 || {}, this.x = s2, this.total = null, this.cumulative = null, this.points = {}, this.hasValidPoints = false, this.stack = o2, this.leftCliff = 0, this.rightCliff = 0, this.alignOptions = {
23219              align: e3.align || (r2 ? n2 ? "left" : "right" : "center"),
23220              verticalAlign: e3.verticalAlign || (r2 ? "middle" : n2 ? "bottom" : "top"),
23221              y: e3.y,
23222              x: e3.x
23223            }, this.textAlign = e3.textAlign || (r2 ? n2 ? "right" : "left" : "center");
23224          }
23225          destroy() {
23226            r(this, this.axis);
23227          }
23228          render(t3) {
23229            let e3 = this.axis.chart, i3 = this.options, o2 = i3.format, r2 = o2 ? s(o2, this, e3) : i3.formatter.call(this);
23230            if (this.label) this.label.attr({
23231              text: r2,
23232              visibility: "hidden"
23233            });
23234            else {
23235              this.label = e3.renderer.label(r2, null, void 0, i3.shape, void 0, void 0, i3.useHTML, false, "stack-labels");
23236              let s2 = {
23237                r: i3.borderRadius || 0,
23238                text: r2,
23239                padding: l(i3.padding, 5),
23240                visibility: "hidden"
23241              };
23242              e3.styledMode || (s2.fill = i3.backgroundColor, s2.stroke = i3.borderColor, s2["stroke-width"] = i3.borderWidth, this.label.css(i3.style || {})), this.label.attr(s2), this.label.added || this.label.add(t3);
23243            }
23244            this.label.labelrank = e3.plotSizeY, a(this, "afterRender");
23245          }
23246          setOffset(t3, e3, i3, s2, r2, h) {
23247            let {
23248              alignOptions: d,
23249              axis: c,
23250              label: p,
23251              options: u11,
23252              textAlign: g
23253            } = this, f = c.chart, m = this.getStackBox({
23254              xOffset: t3,
23255              width: e3,
23256              boxBottom: i3,
23257              boxTop: s2,
23258              defaultX: r2,
23259              xAxis: h
23260            }), {
23261              verticalAlign: x
23262            } = d;
23263            if (p && m) {
23264              let t4 = p.getBBox(void 0, 0), e4 = p.padding, i4 = "justify" === l(u11.overflow, "justify"), s3;
23265              d.x = u11.x || 0, d.y = u11.y || 0;
23266              let {
23267                x: r3,
23268                y: a2
23269              } = this.adjustStackPosition({
23270                labelBox: t4,
23271                verticalAlign: x,
23272                textAlign: g
23273              });
23274              m.x -= r3, m.y -= a2, p.align(d, false, m), (s3 = f.isInsidePlot(p.alignAttr.x + d.x + r3, p.alignAttr.y + d.y + a2)) || (i4 = false), i4 && o.prototype.justifyDataLabel.call(c, p, d, p.alignAttr, t4, m), p.attr({
23275                x: p.alignAttr.x,
23276                y: p.alignAttr.y,
23277                rotation: u11.rotation,
23278                rotationOriginX: t4.width * {
23279                  left: 0,
23280                  center: 0.5,
23281                  right: 1
23282                }[u11.textAlign || "center"],
23283                rotationOriginY: t4.height / 2
23284              }), l(!i4 && u11.crop, true) && (s3 = n(p.x) && n(p.y) && f.isInsidePlot(p.x - e4 + (p.width || 0), p.y) && f.isInsidePlot(p.x + e4, p.y)), p[s3 ? "show" : "hide"]();
23285            }
23286            a(this, "afterSetOffset", {
23287              xOffset: t3,
23288              width: e3
23289            });
23290          }
23291          adjustStackPosition({
23292            labelBox: t3,
23293            verticalAlign: e3,
23294            textAlign: i3
23295          }) {
23296            let s2 = {
23297              bottom: 0,
23298              middle: 1,
23299              top: 2,
23300              right: 1,
23301              center: 0,
23302              left: -1
23303            }, o2 = s2[e3], r2 = s2[i3];
23304            return {
23305              x: t3.width / 2 + t3.width / 2 * r2,
23306              y: t3.height / 2 * o2
23307            };
23308          }
23309          getStackBox(t3) {
23310            let e3 = this.axis, i3 = e3.chart, {
23311              boxTop: s2,
23312              defaultX: o2,
23313              xOffset: r2,
23314              width: a2,
23315              boxBottom: h
23316            } = t3, d = e3.stacking.usePercentage ? 100 : l(s2, this.total, 0), c = e3.toPixels(d), p = t3.xAxis || i3.xAxis[0], u11 = l(o2, p.translate(this.x)) + r2, g = Math.abs(c - e3.toPixels(h || n(e3.min) && e3.logarithmic && e3.logarithmic.lin2log(e3.min) || 0)), f = i3.inverted, m = this.isNegative;
23317            return f ? {
23318              x: (m ? c : c - g) - i3.plotLeft,
23319              y: p.height - u11 - a2 + p.top - i3.plotTop,
23320              width: g,
23321              height: a2
23322            } : {
23323              x: u11 + p.transB - i3.plotLeft,
23324              y: (m ? c - g : c) - i3.plotTop,
23325              width: a2,
23326              height: g
23327            };
23328          }
23329        };
23330      }), i(e, "Core/Axis/Stacking/StackingAxis.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Axis/Axis.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Axis/Stacking/StackItem.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o) {
23331        var r;
23332        let {
23333          getDeferredAnimation: a
23334        } = t2, {
23335          series: {
23336            prototype: n
23337          }
23338        } = i2, {
23339          addEvent: l,
23340          correctFloat: h,
23341          defined: d,
23342          destroyObjectProperties: c,
23343          fireEvent: p,
23344          isArray: u11,
23345          isNumber: g,
23346          objectEach: f,
23347          pick: m
23348        } = o;
23349        function x() {
23350          let t3 = this.inverted;
23351          this.axes.forEach((t4) => {
23352            t4.stacking && t4.stacking.stacks && t4.hasVisibleSeries && (t4.stacking.oldStacks = t4.stacking.stacks);
23353          }), this.series.forEach((e3) => {
23354            let i3 = e3.xAxis && e3.xAxis.options || {};
23355            e3.options.stacking && e3.reserveSpace() && (e3.stackKey = [e3.type, m(e3.options.stack, ""), t3 ? i3.top : i3.left, t3 ? i3.height : i3.width].join(","));
23356          });
23357        }
23358        function y() {
23359          let t3 = this.stacking;
23360          if (t3) {
23361            let e3 = t3.stacks;
23362            f(e3, (t4, i3) => {
23363              c(t4), delete e3[i3];
23364            }), t3.stackTotalGroup?.destroy();
23365          }
23366        }
23367        function b() {
23368          this.stacking || (this.stacking = new A(this));
23369        }
23370        function v(t3, e3, i3, s2) {
23371          return !d(t3) || t3.x !== e3 || s2 && t3.stackKey !== s2 ? t3 = {
23372            x: e3,
23373            index: 0,
23374            key: s2,
23375            stackKey: s2
23376          } : t3.index++, t3.key = [i3, e3, t3.index].join(","), t3;
23377        }
23378        function S2() {
23379          let t3;
23380          let e3 = this, i3 = e3.yAxis, s2 = e3.stackKey || "", o2 = i3.stacking.stacks, r2 = e3.processedXData, a2 = e3.options.stacking, n2 = e3[a2 + "Stacker"];
23381          n2 && [s2, "-" + s2].forEach((i4) => {
23382            let s3 = r2.length, a3, l2, h2;
23383            for (; s3--; ) a3 = r2[s3], t3 = e3.getStackIndicator(t3, a3, e3.index, i4), l2 = o2[i4]?.[a3], (h2 = l2?.points[t3.key || ""]) && n2.call(e3, h2, l2, s3);
23384          });
23385        }
23386        function k(t3, e3, i3) {
23387          let s2 = e3.total ? 100 / e3.total : 0;
23388          t3[0] = h(t3[0] * s2), t3[1] = h(t3[1] * s2), this.stackedYData[i3] = t3[1];
23389        }
23390        function M(t3) {
23391          (this.is("column") || this.is("columnrange")) && (this.options.centerInCategory && !this.options.stacking && this.chart.series.length > 1 ? n.setStackedPoints.call(this, t3, "group") : t3.stacking.resetStacks());
23392        }
23393        function C(t3, e3) {
23394          let i3, o2, r2, a2, n2, l2, c2, p2, g2;
23395          let f2 = e3 || this.options.stacking;
23396          if (!f2 || !this.reserveSpace() || ({
23397            group: "xAxis"
23398          }[f2] || "yAxis") !== t3.coll) return;
23399          let x2 = this.processedXData, y2 = this.processedYData, b2 = [], v2 = y2.length, S3 = this.options, k2 = S3.threshold || 0, M2 = S3.startFromThreshold ? k2 : 0, C2 = S3.stack, A2 = e3 ? `${this.type},${f2}` : this.stackKey || "", w = "-" + A2, T2 = this.negStacks, P = t3.stacking, O = P.stacks, L = P.oldStacks;
23400          for (P.stacksTouched += 1, c2 = 0; c2 < v2; c2++) {
23401            p2 = x2[c2], g2 = y2[c2], l2 = (i3 = this.getStackIndicator(i3, p2, this.index)).key || "", O[n2 = (o2 = T2 && g2 < (M2 ? 0 : k2)) ? w : A2] || (O[n2] = {}), O[n2][p2] || (L[n2]?.[p2] ? (O[n2][p2] = L[n2][p2], O[n2][p2].total = null) : O[n2][p2] = new s(t3, t3.options.stackLabels, !!o2, p2, C2)), r2 = O[n2][p2], null !== g2 ? (r2.points[l2] = r2.points[this.index] = [m(r2.cumulative, M2)], d(r2.cumulative) || (r2.base = l2), r2.touched = P.stacksTouched, i3.index > 0 && false === this.singleStacks && (r2.points[l2][0] = r2.points[this.index + "," + p2 + ",0"][0])) : (delete r2.points[l2], delete r2.points[this.index]);
23402            let e4 = r2.total || 0;
23403            "percent" === f2 ? (a2 = o2 ? A2 : w, e4 = T2 && O[a2]?.[p2] ? (a2 = O[a2][p2]).total = Math.max(a2.total || 0, e4) + Math.abs(g2) || 0 : h(e4 + (Math.abs(g2) || 0))) : "group" === f2 ? (u11(g2) && (g2 = g2[0]), null !== g2 && e4++) : e4 = h(e4 + (g2 || 0)), "group" === f2 ? r2.cumulative = (e4 || 1) - 1 : r2.cumulative = h(m(r2.cumulative, M2) + (g2 || 0)), r2.total = e4, null !== g2 && (r2.points[l2].push(r2.cumulative), b2[c2] = r2.cumulative, r2.hasValidPoints = true);
23404          }
23405          "percent" === f2 && (P.usePercentage = true), "group" !== f2 && (this.stackedYData = b2), P.oldStacks = {};
23406        }
23407        class A {
23408          constructor(t3) {
23409            this.oldStacks = {}, this.stacks = {}, this.stacksTouched = 0, this.axis = t3;
23410          }
23411          buildStacks() {
23412            let t3, e3;
23413            let i3 = this.axis, s2 = i3.series, o2 = "xAxis" === i3.coll, r2 = i3.options.reversedStacks, a2 = s2.length;
23414            for (this.resetStacks(), this.usePercentage = false, e3 = a2; e3--; ) t3 = s2[r2 ? e3 : a2 - e3 - 1], o2 && t3.setGroupedPoints(i3), t3.setStackedPoints(i3);
23415            if (!o2) for (e3 = 0; e3 < a2; e3++) s2[e3].modifyStacks();
23416            p(i3, "afterBuildStacks");
23417          }
23418          cleanStacks() {
23419            this.oldStacks && (this.stacks = this.oldStacks, f(this.stacks, (t3) => {
23420              f(t3, (t4) => {
23421                t4.cumulative = t4.total;
23422              });
23423            }));
23424          }
23425          resetStacks() {
23426            f(this.stacks, (t3) => {
23427              f(t3, (e3, i3) => {
23428                g(e3.touched) && e3.touched < this.stacksTouched ? (e3.destroy(), delete t3[i3]) : (e3.total = null, e3.cumulative = null);
23429              });
23430            });
23431          }
23432          renderStackTotals() {
23433            let t3 = this.axis, e3 = t3.chart, i3 = e3.renderer, s2 = this.stacks, o2 = a(e3, t3.options.stackLabels?.animation || false), r2 = this.stackTotalGroup = this.stackTotalGroup || i3.g("stack-labels").attr({
23434              zIndex: 6,
23435              opacity: 0
23436            }).add();
23437            r2.translate(e3.plotLeft, e3.plotTop), f(s2, (t4) => {
23438              f(t4, (t5) => {
23439                t5.render(r2);
23440              });
23441            }), r2.animate({
23442              opacity: 1
23443            }, o2);
23444          }
23445        }
23446        return (r || (r = {})).compose = function(t3, e3, i3) {
23447          let s2 = e3.prototype, o2 = i3.prototype;
23448          s2.getStacks || (l(t3, "init", b), l(t3, "destroy", y), s2.getStacks = x, o2.getStackIndicator = v, o2.modifyStacks = S2, o2.percentStacker = k, o2.setGroupedPoints = M, o2.setStackedPoints = C);
23449        }, r;
23450      }), i(e, "Series/Line/LineSeries.js", [e["Core/Series/Series.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
23451        let {
23452          defined: s,
23453          merge: o,
23454          isObject: r
23455        } = i2;
23456        class a extends t2 {
23457          drawGraph() {
23458            let t3 = this.options, e3 = (this.gappedPath || this.getGraphPath).call(this), i3 = this.chart.styledMode;
23459            [this, ...this.zones].forEach((s2, a2) => {
23460              let n, l = s2.graph, h = l ? "animate" : "attr", d = s2.dashStyle || t3.dashStyle;
23461              l ? (l.endX = this.preventGraphAnimation ? null : e3.xMap, l.animate({
23462                d: e3
23463              })) : e3.length && (s2.graph = l = this.chart.renderer.path(e3).addClass("highcharts-graph" + (a2 ? ` highcharts-zone-graph-${a2 - 1} ` : " ") + (a2 && s2.className || "")).attr({
23464                zIndex: 1
23465              }).add(this.group)), l && !i3 && (n = {
23466                stroke: !a2 && t3.lineColor || s2.color || this.color || "#cccccc",
23467                "stroke-width": t3.lineWidth || 0,
23468                fill: this.fillGraph && this.color || "none"
23469              }, d ? n.dashstyle = d : "square" !== t3.linecap && (n["stroke-linecap"] = n["stroke-linejoin"] = "round"), l[h](n).shadow(a2 < 2 && t3.shadow && o({
23470                filterUnits: "userSpaceOnUse"
23471              }, r(t3.shadow) ? t3.shadow : {}))), l && (l.startX = e3.xMap, l.isArea = e3.isArea);
23472            });
23473          }
23474          getGraphPath(t3, e3, i3) {
23475            let o2 = this, r2 = o2.options, a2 = [], n = [], l, h = r2.step, d = (t3 = t3 || o2.points).reversed;
23476            return d && t3.reverse(), (h = {
23477              right: 1,
23478              center: 2
23479            }[h] || h && 3) && d && (h = 4 - h), (t3 = this.getValidPoints(t3, false, !(r2.connectNulls && !e3 && !i3))).forEach(function(d2, c) {
23480              let p;
23481              let u11 = d2.plotX, g = d2.plotY, f = t3[c - 1], m = d2.isNull || "number" != typeof g;
23482              (d2.leftCliff || f && f.rightCliff) && !i3 && (l = true), m && !s(e3) && c > 0 ? l = !r2.connectNulls : m && !e3 ? l = true : (0 === c || l ? p = [["M", d2.plotX, d2.plotY]] : o2.getPointSpline ? p = [o2.getPointSpline(t3, d2, c)] : h ? (p = 1 === h ? [["L", f.plotX, g]] : 2 === h ? [["L", (f.plotX + u11) / 2, f.plotY], ["L", (f.plotX + u11) / 2, g]] : [["L", u11, f.plotY]]).push(["L", u11, g]) : p = [["L", u11, g]], n.push(d2.x), h && (n.push(d2.x), 2 === h && n.push(d2.x)), a2.push.apply(a2, p), l = false);
23483            }), a2.xMap = n, o2.graphPath = a2, a2;
23484          }
23485        }
23486        return a.defaultOptions = o(t2.defaultOptions, {
23487          legendSymbol: "lineMarker"
23488        }), e2.registerSeriesType("line", a), a;
23489      }), i(e, "Series/Area/AreaSeriesDefaults.js", [], function() {
23490        return {
23491          threshold: 0,
23492          legendSymbol: "areaMarker"
23493        };
23494      }), i(e, "Series/Area/AreaSeries.js", [e["Series/Area/AreaSeriesDefaults.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
23495        let {
23496          seriesTypes: {
23497            line: s
23498          }
23499        } = e2, {
23500          extend: o,
23501          merge: r,
23502          objectEach: a,
23503          pick: n
23504        } = i2;
23505        class l extends s {
23506          drawGraph() {
23507            this.areaPath = [], super.drawGraph.apply(this);
23508            let {
23509              areaPath: t3,
23510              options: e3
23511            } = this;
23512            [this, ...this.zones].forEach((i3, s2) => {
23513              let o2 = {}, r2 = i3.fillColor || e3.fillColor, a2 = i3.area, n2 = a2 ? "animate" : "attr";
23514              a2 ? (a2.endX = this.preventGraphAnimation ? null : t3.xMap, a2.animate({
23515                d: t3
23516              })) : (o2.zIndex = 0, (a2 = i3.area = this.chart.renderer.path(t3).addClass("highcharts-area" + (s2 ? ` highcharts-zone-area-${s2 - 1} ` : " ") + (s2 && i3.className || "")).add(this.group)).isArea = true), this.chart.styledMode || (o2.fill = r2 || i3.color || this.color, o2["fill-opacity"] = r2 ? 1 : e3.fillOpacity ?? 0.75, a2.css({
23517                pointerEvents: this.stickyTracking ? "none" : "auto"
23518              })), a2[n2](o2), a2.startX = t3.xMap, a2.shiftUnit = e3.step ? 2 : 1;
23519            });
23520          }
23521          getGraphPath(t3) {
23522            let e3, i3, o2;
23523            let r2 = s.prototype.getGraphPath, a2 = this.options, l2 = a2.stacking, h = this.yAxis, d = [], c = [], p = this.index, u11 = h.stacking.stacks[this.stackKey], g = a2.threshold, f = Math.round(h.getThreshold(a2.threshold)), m = n(a2.connectNulls, "percent" === l2), x = function(i4, s2, o3) {
23524              let r3 = t3[i4], a3 = l2 && u11[r3.x].points[p], n2 = r3[o3 + "Null"] || 0, m2 = r3[o3 + "Cliff"] || 0, x2, y2, b2 = true;
23525              m2 || n2 ? (x2 = (n2 ? a3[0] : a3[1]) + m2, y2 = a3[0] + m2, b2 = !!n2) : !l2 && t3[s2] && t3[s2].isNull && (x2 = y2 = g), void 0 !== x2 && (c.push({
23526                plotX: e3,
23527                plotY: null === x2 ? f : h.getThreshold(x2),
23528                isNull: b2,
23529                isCliff: true
23530              }), d.push({
23531                plotX: e3,
23532                plotY: null === y2 ? f : h.getThreshold(y2),
23533                doCurve: false
23534              }));
23535            };
23536            t3 = t3 || this.points, l2 && (t3 = this.getStackPoints(t3));
23537            for (let s2 = 0, r3 = t3.length; s2 < r3; ++s2) l2 || (t3[s2].leftCliff = t3[s2].rightCliff = t3[s2].leftNull = t3[s2].rightNull = void 0), i3 = t3[s2].isNull, e3 = n(t3[s2].rectPlotX, t3[s2].plotX), o2 = l2 ? n(t3[s2].yBottom, f) : f, i3 && !m || (m || x(s2, s2 - 1, "left"), i3 && !l2 && m || (c.push(t3[s2]), d.push({
23538              x: s2,
23539              plotX: e3,
23540              plotY: o2
23541            })), m || x(s2, s2 + 1, "right"));
23542            let y = r2.call(this, c, true, true);
23543            d.reversed = true;
23544            let b = r2.call(this, d, true, true), v = b[0];
23545            v && "M" === v[0] && (b[0] = ["L", v[1], v[2]]);
23546            let S2 = y.concat(b);
23547            S2.length && S2.push(["Z"]);
23548            let k = r2.call(this, c, false, m);
23549            return this.chart.series.length > 1 && l2 && c.some((t4) => t4.isCliff) && (S2.hasStackedCliffs = k.hasStackedCliffs = true), S2.xMap = y.xMap, this.areaPath = S2, k;
23550          }
23551          getStackPoints(t3) {
23552            let e3 = this, i3 = [], s2 = [], o2 = this.xAxis, r2 = this.yAxis, l2 = r2.stacking.stacks[this.stackKey], h = {}, d = r2.series, c = d.length, p = r2.options.reversedStacks ? 1 : -1, u11 = d.indexOf(e3);
23553            if (t3 = t3 || this.points, this.options.stacking) {
23554              for (let e4 = 0; e4 < t3.length; e4++) t3[e4].leftNull = t3[e4].rightNull = void 0, h[t3[e4].x] = t3[e4];
23555              a(l2, function(t4, e4) {
23556                null !== t4.total && s2.push(e4);
23557              }), s2.sort(function(t4, e4) {
23558                return t4 - e4;
23559              });
23560              let g = d.map((t4) => t4.visible);
23561              s2.forEach(function(t4, a2) {
23562                let f = 0, m, x;
23563                if (h[t4] && !h[t4].isNull) i3.push(h[t4]), [-1, 1].forEach(function(i4) {
23564                  let o3 = 1 === i4 ? "rightNull" : "leftNull", r3 = l2[s2[a2 + i4]], n2 = 0;
23565                  if (r3) {
23566                    let i5 = u11;
23567                    for (; i5 >= 0 && i5 < c; ) {
23568                      let s3 = d[i5].index;
23569                      !(m = r3.points[s3]) && (s3 === e3.index ? h[t4][o3] = true : g[i5] && (x = l2[t4].points[s3]) && (n2 -= x[1] - x[0])), i5 += p;
23570                    }
23571                  }
23572                  h[t4][1 === i4 ? "rightCliff" : "leftCliff"] = n2;
23573                });
23574                else {
23575                  let e4 = u11;
23576                  for (; e4 >= 0 && e4 < c; ) {
23577                    let i4 = d[e4].index;
23578                    if (m = l2[t4].points[i4]) {
23579                      f = m[1];
23580                      break;
23581                    }
23582                    e4 += p;
23583                  }
23584                  f = n(f, 0), f = r2.translate(f, 0, 1, 0, 1), i3.push({
23585                    isNull: true,
23586                    plotX: o2.translate(t4, 0, 0, 0, 1),
23587                    x: t4,
23588                    plotY: f,
23589                    yBottom: f
23590                  });
23591                }
23592              });
23593            }
23594            return i3;
23595          }
23596        }
23597        return l.defaultOptions = r(s.defaultOptions, t2), o(l.prototype, {
23598          singleStacks: false
23599        }), e2.registerSeriesType("area", l), l;
23600      }), i(e, "Series/Spline/SplineSeries.js", [e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2) {
23601        let {
23602          line: i2
23603        } = t2.seriesTypes, {
23604          merge: s,
23605          pick: o
23606        } = e2;
23607        class r extends i2 {
23608          getPointSpline(t3, e3, i3) {
23609            let s2, r2, a, n;
23610            let l = e3.plotX || 0, h = e3.plotY || 0, d = t3[i3 - 1], c = t3[i3 + 1];
23611            function p(t4) {
23612              return t4 && !t4.isNull && false !== t4.doCurve && !e3.isCliff;
23613            }
23614            if (p(d) && p(c)) {
23615              let t4 = d.plotX || 0, i4 = d.plotY || 0, o2 = c.plotX || 0, p2 = c.plotY || 0, u12 = 0;
23616              s2 = (1.5 * l + t4) / 2.5, r2 = (1.5 * h + i4) / 2.5, a = (1.5 * l + o2) / 2.5, n = (1.5 * h + p2) / 2.5, a !== s2 && (u12 = (n - r2) * (a - l) / (a - s2) + h - n), r2 += u12, n += u12, r2 > i4 && r2 > h ? (r2 = Math.max(i4, h), n = 2 * h - r2) : r2 < i4 && r2 < h && (r2 = Math.min(i4, h), n = 2 * h - r2), n > p2 && n > h ? (n = Math.max(p2, h), r2 = 2 * h - n) : n < p2 && n < h && (n = Math.min(p2, h), r2 = 2 * h - n), e3.rightContX = a, e3.rightContY = n, e3.controlPoints = {
23617                low: [s2, r2],
23618                high: [a, n]
23619              };
23620            }
23621            let u11 = ["C", o(d.rightContX, d.plotX, 0), o(d.rightContY, d.plotY, 0), o(s2, l, 0), o(r2, h, 0), l, h];
23622            return d.rightContX = d.rightContY = void 0, u11;
23623          }
23624        }
23625        return r.defaultOptions = s(i2.defaultOptions), t2.registerSeriesType("spline", r), r;
23626      }), i(e, "Series/AreaSpline/AreaSplineSeries.js", [e["Series/Spline/SplineSeries.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
23627        let {
23628          area: s,
23629          area: {
23630            prototype: o
23631          }
23632        } = e2.seriesTypes, {
23633          extend: r,
23634          merge: a
23635        } = i2;
23636        class n extends t2 {
23637        }
23638        return n.defaultOptions = a(t2.defaultOptions, s.defaultOptions), r(n.prototype, {
23639          getGraphPath: o.getGraphPath,
23640          getStackPoints: o.getStackPoints,
23641          drawGraph: o.drawGraph
23642        }), e2.registerSeriesType("areaspline", n), n;
23643      }), i(e, "Series/Column/ColumnSeriesDefaults.js", [], function() {
23644        return {
23645          borderRadius: 3,
23646          centerInCategory: false,
23647          groupPadding: 0.2,
23648          marker: null,
23649          pointPadding: 0.1,
23650          minPointLength: 0,
23651          cropThreshold: 50,
23652          pointRange: null,
23653          states: {
23654            hover: {
23655              halo: false,
23656              brightness: 0.1
23657            },
23658            select: {
23659              color: "#cccccc",
23660              borderColor: "#000000"
23661            }
23662          },
23663          dataLabels: {
23664            align: void 0,
23665            verticalAlign: void 0,
23666            y: void 0
23667          },
23668          startFromThreshold: true,
23669          stickyTracking: false,
23670          tooltip: {
23671            distance: 6
23672          },
23673          threshold: 0,
23674          borderColor: "#ffffff"
23675        };
23676      }), i(e, "Series/Column/ColumnSeries.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Color/Color.js"], e["Series/Column/ColumnSeriesDefaults.js"], e["Core/Globals.js"], e["Core/Series/Series.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o, r, a) {
23677        let {
23678          animObject: n
23679        } = t2, {
23680          parse: l
23681        } = e2, {
23682          noop: h
23683        } = s, {
23684          clamp: d,
23685          crisp: c,
23686          defined: p,
23687          extend: u11,
23688          fireEvent: g,
23689          isArray: f,
23690          isNumber: m,
23691          merge: x,
23692          pick: y,
23693          objectEach: b
23694        } = a;
23695        class v extends o {
23696          animate(t3) {
23697            let e3, i3;
23698            let s2 = this, o2 = this.yAxis, r2 = o2.pos, a2 = o2.reversed, l2 = s2.options, {
23699              clipOffset: h2,
23700              inverted: c2
23701            } = this.chart, p2 = {}, g2 = c2 ? "translateX" : "translateY";
23702            t3 && h2 ? (p2.scaleY = 1e-3, i3 = d(o2.toPixels(l2.threshold), r2, r2 + o2.len), c2 ? (i3 += a2 ? -Math.floor(h2[0]) : Math.ceil(h2[2]), p2.translateX = i3 - o2.len) : (i3 += a2 ? Math.ceil(h2[0]) : -Math.floor(h2[2]), p2.translateY = i3), s2.clipBox && s2.setClip(), s2.group.attr(p2)) : (e3 = Number(s2.group.attr(g2)), s2.group.animate({
23703              scaleY: 1
23704            }, u11(n(s2.options.animation), {
23705              step: function(t4, i4) {
23706                s2.group && (p2[g2] = e3 + i4.pos * (r2 - e3), s2.group.attr(p2));
23707              }
23708            })));
23709          }
23710          init(t3, e3) {
23711            super.init.apply(this, arguments);
23712            let i3 = this;
23713            (t3 = i3.chart).hasRendered && t3.series.forEach(function(t4) {
23714              t4.type === i3.type && (t4.isDirty = true);
23715            });
23716          }
23717          getColumnMetrics() {
23718            let t3 = this, e3 = t3.options, i3 = t3.xAxis, s2 = t3.yAxis, o2 = i3.options.reversedStacks, r2 = i3.reversed && !o2 || !i3.reversed && o2, a2 = {}, n2, l2 = 0;
23719            false === e3.grouping ? l2 = 1 : t3.chart.series.forEach(function(e4) {
23720              let i4;
23721              let o3 = e4.yAxis, r3 = e4.options;
23722              e4.type === t3.type && e4.reserveSpace() && s2.len === o3.len && s2.pos === o3.pos && (r3.stacking && "group" !== r3.stacking ? (void 0 === a2[n2 = e4.stackKey] && (a2[n2] = l2++), i4 = a2[n2]) : false !== r3.grouping && (i4 = l2++), e4.columnIndex = i4);
23723            });
23724            let h2 = Math.min(Math.abs(i3.transA) * (!i3.brokenAxis?.hasBreaks && i3.ordinal?.slope || e3.pointRange || i3.closestPointRange || i3.tickInterval || 1), i3.len), d2 = h2 * e3.groupPadding, c2 = (h2 - 2 * d2) / (l2 || 1), p2 = Math.min(e3.maxPointWidth || i3.len, y(e3.pointWidth, c2 * (1 - 2 * e3.pointPadding))), u12 = (t3.columnIndex || 0) + (r2 ? 1 : 0);
23725            return t3.columnMetrics = {
23726              width: p2,
23727              offset: (c2 - p2) / 2 + (d2 + u12 * c2 - h2 / 2) * (r2 ? -1 : 1),
23728              paddedWidth: c2,
23729              columnCount: l2
23730            }, t3.columnMetrics;
23731          }
23732          crispCol(t3, e3, i3, s2) {
23733            let o2 = this.borderWidth, r2 = this.chart.inverted;
23734            return s2 = c(e3 + s2, o2, r2) - (e3 = c(e3, o2, r2)), this.options.crisp && (i3 = c(t3 + i3, o2) - (t3 = c(t3, o2))), {
23735              x: t3,
23736              y: e3,
23737              width: i3,
23738              height: s2
23739            };
23740          }
23741          adjustForMissingColumns(t3, e3, i3, s2) {
23742            if (!i3.isNull && s2.columnCount > 1) {
23743              let o2 = this.xAxis.series.filter((t4) => t4.visible).map((t4) => t4.index), r2 = 0, a2 = 0;
23744              b(this.xAxis.stacking?.stacks, (t4) => {
23745                if ("number" == typeof i3.x) {
23746                  let e4 = t4[i3.x.toString()];
23747                  if (e4 && f(e4.points[this.index])) {
23748                    let t5 = Object.keys(e4.points).filter((t6) => !t6.match(",") && e4.points[t6] && e4.points[t6].length > 1).map(parseFloat).filter((t6) => -1 !== o2.indexOf(t6)).sort((t6, e5) => e5 - t6);
23749                    r2 = t5.indexOf(this.index), a2 = t5.length;
23750                  }
23751                }
23752              }), r2 = this.xAxis.reversed ? a2 - 1 - r2 : r2;
23753              let n2 = (a2 - 1) * s2.paddedWidth + e3;
23754              t3 = (i3.plotX || 0) + n2 / 2 - e3 - r2 * s2.paddedWidth;
23755            }
23756            return t3;
23757          }
23758          translate() {
23759            let t3 = this, e3 = t3.chart, i3 = t3.options, s2 = t3.dense = t3.closestPointRange * t3.xAxis.transA < 2, r2 = t3.borderWidth = y(i3.borderWidth, s2 ? 0 : 1), a2 = t3.xAxis, n2 = t3.yAxis, l2 = i3.threshold, h2 = y(i3.minPointLength, 5), c2 = t3.getColumnMetrics(), u12 = c2.width, f2 = t3.pointXOffset = c2.offset, x2 = t3.dataMin, b2 = t3.dataMax, v2 = t3.translatedThreshold = n2.getThreshold(l2), S2 = t3.barW = Math.max(u12, 1 + 2 * r2);
23760            i3.pointPadding && (S2 = Math.ceil(S2)), o.prototype.translate.apply(t3), t3.points.forEach(function(s3) {
23761              let o2 = y(s3.yBottom, v2), r3 = 999 + Math.abs(o2), g2 = s3.plotX || 0, k = d(s3.plotY, -r3, n2.len + r3), M, C = Math.min(k, o2), A = Math.max(k, o2) - C, w = u12, T2 = g2 + f2, P = S2;
23762              h2 && Math.abs(A) < h2 && (A = h2, M = !n2.reversed && !s3.negative || n2.reversed && s3.negative, m(l2) && m(b2) && s3.y === l2 && b2 <= l2 && (n2.min || 0) < l2 && (x2 !== b2 || (n2.max || 0) <= l2) && (M = !M, s3.negative = !s3.negative), C = Math.abs(C - v2) > h2 ? o2 - h2 : v2 - (M ? h2 : 0)), p(s3.options.pointWidth) && (T2 -= Math.round(((w = P = Math.ceil(s3.options.pointWidth)) - u12) / 2)), i3.centerInCategory && !i3.stacking && (T2 = t3.adjustForMissingColumns(T2, w, s3, c2)), s3.barX = T2, s3.pointWidth = w, s3.tooltipPos = e3.inverted ? [d(n2.len + n2.pos - e3.plotLeft - k, n2.pos - e3.plotLeft, n2.len + n2.pos - e3.plotLeft), a2.len + a2.pos - e3.plotTop - T2 - P / 2, A] : [a2.left - e3.plotLeft + T2 + P / 2, d(k + n2.pos - e3.plotTop, n2.pos - e3.plotTop, n2.len + n2.pos - e3.plotTop), A], s3.shapeType = t3.pointClass.prototype.shapeType || "roundedRect", s3.shapeArgs = t3.crispCol(T2, s3.isNull ? v2 : C, P, s3.isNull ? 0 : A);
23763            }), g(this, "afterColumnTranslate");
23764          }
23765          drawGraph() {
23766            this.group[this.dense ? "addClass" : "removeClass"]("highcharts-dense-data");
23767          }
23768          pointAttribs(t3, e3) {
23769            let i3 = this.options, s2 = this.pointAttrToOptions || {}, o2 = s2.stroke || "borderColor", r2 = s2["stroke-width"] || "borderWidth", a2, n2, h2, d2 = t3 && t3.color || this.color, c2 = t3 && t3[o2] || i3[o2] || d2, p2 = t3 && t3.options.dashStyle || i3.dashStyle, u12 = t3 && t3[r2] || i3[r2] || this[r2] || 0, g2 = y(t3 && t3.opacity, i3.opacity, 1);
23770            t3 && this.zones.length && (n2 = t3.getZone(), d2 = t3.options.color || n2 && (n2.color || t3.nonZonedColor) || this.color, n2 && (c2 = n2.borderColor || c2, p2 = n2.dashStyle || p2, u12 = n2.borderWidth || u12)), e3 && t3 && (h2 = (a2 = x(i3.states[e3], t3.options.states && t3.options.states[e3] || {})).brightness, d2 = a2.color || void 0 !== h2 && l(d2).brighten(a2.brightness).get() || d2, c2 = a2[o2] || c2, u12 = a2[r2] || u12, p2 = a2.dashStyle || p2, g2 = y(a2.opacity, g2));
23771            let f2 = {
23772              fill: d2,
23773              stroke: c2,
23774              "stroke-width": u12,
23775              opacity: g2
23776            };
23777            return p2 && (f2.dashstyle = p2), f2;
23778          }
23779          drawPoints(t3 = this.points) {
23780            let e3;
23781            let i3 = this, s2 = this.chart, o2 = i3.options, r2 = s2.renderer, a2 = o2.animationLimit || 250;
23782            t3.forEach(function(t4) {
23783              let n2 = t4.plotY, l2 = t4.graphic, h2 = !!l2, d2 = l2 && s2.pointCount < a2 ? "animate" : "attr";
23784              m(n2) && null !== t4.y ? (e3 = t4.shapeArgs, l2 && t4.hasNewShapeType() && (l2 = l2.destroy()), i3.enabledDataSorting && (t4.startXPos = i3.xAxis.reversed ? -(e3 && e3.width || 0) : i3.xAxis.width), !l2 && (t4.graphic = l2 = r2[t4.shapeType](e3).add(t4.group || i3.group), l2 && i3.enabledDataSorting && s2.hasRendered && s2.pointCount < a2 && (l2.attr({
23785                x: t4.startXPos
23786              }), h2 = true, d2 = "animate")), l2 && h2 && l2[d2](x(e3)), s2.styledMode || l2[d2](i3.pointAttribs(t4, t4.selected && "select")).shadow(false !== t4.allowShadow && o2.shadow), l2 && (l2.addClass(t4.getClassName(), true), l2.attr({
23787                visibility: t4.visible ? "inherit" : "hidden"
23788              }))) : l2 && (t4.graphic = l2.destroy());
23789            });
23790          }
23791          drawTracker(t3 = this.points) {
23792            let e3;
23793            let i3 = this, s2 = i3.chart, o2 = s2.pointer, r2 = function(t4) {
23794              let e4 = o2?.getPointFromEvent(t4);
23795              o2 && e4 && i3.options.enableMouseTracking && (o2.isDirectTouch = true, e4.onMouseOver(t4));
23796            };
23797            t3.forEach(function(t4) {
23798              e3 = f(t4.dataLabels) ? t4.dataLabels : t4.dataLabel ? [t4.dataLabel] : [], t4.graphic && (t4.graphic.element.point = t4), e3.forEach(function(e4) {
23799                (e4.div || e4.element).point = t4;
23800              });
23801            }), i3._hasTracking || (i3.trackerGroups.forEach(function(t4) {
23802              i3[t4] && (i3[t4].addClass("highcharts-tracker").on("mouseover", r2).on("mouseout", function(t5) {
23803                o2?.onTrackerMouseOut(t5);
23804              }).on("touchstart", r2), !s2.styledMode && i3.options.cursor && i3[t4].css({
23805                cursor: i3.options.cursor
23806              }));
23807            }), i3._hasTracking = true), g(this, "afterDrawTracker");
23808          }
23809          remove() {
23810            let t3 = this, e3 = t3.chart;
23811            e3.hasRendered && e3.series.forEach(function(e4) {
23812              e4.type === t3.type && (e4.isDirty = true);
23813            }), o.prototype.remove.apply(t3, arguments);
23814          }
23815        }
23816        return v.defaultOptions = x(o.defaultOptions, i2), u11(v.prototype, {
23817          directTouch: true,
23818          getSymbol: h,
23819          negStacks: true,
23820          trackerGroups: ["group", "dataLabelsGroup"]
23821        }), r.registerSeriesType("column", v), v;
23822      }), i(e, "Core/Series/DataLabel.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Templating.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
23823        var s;
23824        let {
23825          getDeferredAnimation: o
23826        } = t2, {
23827          format: r
23828        } = e2, {
23829          defined: a,
23830          extend: n,
23831          fireEvent: l,
23832          isArray: h,
23833          isString: d,
23834          merge: c,
23835          objectEach: p,
23836          pick: u11,
23837          pInt: g,
23838          splat: f
23839        } = i2;
23840        return function(t3) {
23841          function e3() {
23842            return v(this).some((t4) => t4?.enabled);
23843          }
23844          function i3(t4, e4, i4, s3, o2) {
23845            let {
23846              chart: r2,
23847              enabledDataSorting: l2
23848            } = this, h2 = this.isCartesian && r2.inverted, d2 = t4.plotX, p2 = t4.plotY, g2 = i4.rotation || 0, f2 = a(d2) && a(p2) && r2.isInsidePlot(d2, Math.round(p2), {
23849              inverted: h2,
23850              paneCoordinates: true,
23851              series: this
23852            }), m2 = 0 === g2 && "justify" === u11(i4.overflow, l2 ? "none" : "justify"), x2 = this.visible && false !== t4.visible && a(d2) && (t4.series.forceDL || l2 && !m2 || f2 || u11(i4.inside, !!this.options.stacking) && s3 && r2.isInsidePlot(d2, h2 ? s3.x + 1 : s3.y + s3.height - 1, {
23853              inverted: h2,
23854              paneCoordinates: true,
23855              series: this
23856            })), y2 = t4.pos();
23857            if (x2 && y2) {
23858              var b2;
23859              let a2 = e4.getBBox(), d3 = e4.getBBox(void 0, 0), p3 = {
23860                right: 1,
23861                center: 0.5
23862              }[i4.align || 0] || 0, v2 = {
23863                bottom: 1,
23864                middle: 0.5
23865              }[i4.verticalAlign || 0] || 0;
23866              if (s3 = n({
23867                x: y2[0],
23868                y: Math.round(y2[1]),
23869                width: 0,
23870                height: 0
23871              }, s3 || {}), "plotEdges" === i4.alignTo && this.isCartesian && (s3[h2 ? "x" : "y"] = 0, s3[h2 ? "width" : "height"] = this.yAxis?.len || 0), n(i4, {
23872                width: a2.width,
23873                height: a2.height
23874              }), b2 = s3, l2 && this.xAxis && !m2 && this.setDataLabelStartPos(t4, e4, o2, f2, b2), e4.align(c(i4, {
23875                width: d3.width,
23876                height: d3.height
23877              }), false, s3, false), e4.alignAttr.x += p3 * (d3.width - a2.width), e4.alignAttr.y += v2 * (d3.height - a2.height), e4[e4.placed ? "animate" : "attr"]({
23878                x: e4.alignAttr.x + (a2.width - d3.width) / 2,
23879                y: e4.alignAttr.y + (a2.height - d3.height) / 2,
23880                rotationOriginX: (e4.width || 0) / 2,
23881                rotationOriginY: (e4.height || 0) / 2
23882              }), m2 && s3.height >= 0) this.justifyDataLabel(e4, i4, e4.alignAttr, a2, s3, o2);
23883              else if (u11(i4.crop, true)) {
23884                let {
23885                  x: t5,
23886                  y: i5
23887                } = e4.alignAttr;
23888                x2 = r2.isInsidePlot(t5, i5, {
23889                  paneCoordinates: true,
23890                  series: this
23891                }) && r2.isInsidePlot(t5 + a2.width - 1, i5 + a2.height - 1, {
23892                  paneCoordinates: true,
23893                  series: this
23894                });
23895              }
23896              i4.shape && !g2 && e4[o2 ? "attr" : "animate"]({
23897                anchorX: y2[0],
23898                anchorY: y2[1]
23899              });
23900            }
23901            o2 && l2 && (e4.placed = false), x2 || l2 && !m2 ? (e4.show(), e4.placed = true) : (e4.hide(), e4.placed = false);
23902          }
23903          function s2() {
23904            return this.plotGroup("dataLabelsGroup", "data-labels", this.hasRendered ? "inherit" : "hidden", this.options.dataLabels.zIndex || 6);
23905          }
23906          function m(t4) {
23907            let e4 = this.hasRendered || 0, i4 = this.initDataLabelsGroup().attr({
23908              opacity: +e4
23909            });
23910            return !e4 && i4 && (this.visible && i4.show(), this.options.animation ? i4.animate({
23911              opacity: 1
23912            }, t4) : i4.attr({
23913              opacity: 1
23914            })), i4;
23915          }
23916          function x(t4) {
23917            let e4;
23918            t4 = t4 || this.points;
23919            let i4 = this, s3 = i4.chart, n2 = i4.options, h2 = s3.renderer, {
23920              backgroundColor: c2,
23921              plotBackgroundColor: m2
23922            } = s3.options.chart, x2 = h2.getContrast(d(m2) && m2 || d(c2) && c2 || "#000000"), y2 = v(i4), {
23923              animation: S3,
23924              defer: k
23925            } = y2[0], M = k ? o(s3, S3, i4) : {
23926              defer: 0,
23927              duration: 0
23928            };
23929            l(this, "drawDataLabels"), i4.hasDataLabels?.() && (e4 = this.initDataLabels(M), t4.forEach((t5) => {
23930              let o2 = t5.dataLabels || [];
23931              f(b(y2, t5.dlOptions || t5.options?.dataLabels)).forEach((c4, f2) => {
23932                let m3 = c4.enabled && (t5.visible || t5.dataLabelOnHidden) && (!t5.isNull || t5.dataLabelOnNull) && function(t6, e5) {
23933                  let i5 = e5.filter;
23934                  if (i5) {
23935                    let e6 = i5.operator, s4 = t6[i5.property], o3 = i5.value;
23936                    return ">" === e6 && s4 > o3 || "<" === e6 && s4 < o3 || ">=" === e6 && s4 >= o3 || "<=" === e6 && s4 <= o3 || "==" === e6 && s4 == o3 || "===" === e6 && s4 === o3 || "!=" === e6 && s4 != o3 || "!==" === e6 && s4 !== o3;
23937                  }
23938                  return true;
23939                }(t5, c4), {
23940                  backgroundColor: y3,
23941                  borderColor: b2,
23942                  distance: v2,
23943                  style: S4 = {}
23944                } = c4, k2, M2, C, A, w = {}, T2 = o2[f2], P = !T2, O;
23945                m3 && (M2 = u11(c4[t5.formatPrefix + "Format"], c4.format), k2 = t5.getLabelConfig(), C = a(M2) ? r(M2, k2, s3) : (c4[t5.formatPrefix + "Formatter"] || c4.formatter).call(k2, c4), A = c4.rotation, !s3.styledMode && (S4.color = u11(c4.color, S4.color, d(i4.color) ? i4.color : void 0, "#000000"), "contrast" === S4.color ? ("none" !== y3 && (O = y3), t5.contrastColor = h2.getContrast("auto" !== O && O || t5.color || i4.color), S4.color = O || !a(v2) && c4.inside || 0 > g(v2 || 0) || n2.stacking ? t5.contrastColor : x2) : delete t5.contrastColor, n2.cursor && (S4.cursor = n2.cursor)), w = {
23946                  r: c4.borderRadius || 0,
23947                  rotation: A,
23948                  padding: c4.padding,
23949                  zIndex: 1
23950                }, s3.styledMode || (w.fill = "auto" === y3 ? t5.color : y3, w.stroke = "auto" === b2 ? t5.color : b2, w["stroke-width"] = c4.borderWidth), p(w, (t6, e5) => {
23951                  void 0 === t6 && delete w[e5];
23952                })), !T2 || m3 && a(C) && !!T2.div == !!c4.useHTML && (T2.rotation && c4.rotation || T2.rotation === c4.rotation) || (T2 = void 0, P = true), m3 && a(C) && (T2 ? w.text = C : (T2 = h2.label(C, 0, 0, c4.shape, void 0, void 0, c4.useHTML, void 0, "data-label")).addClass(" highcharts-data-label-color-" + t5.colorIndex + " " + (c4.className || "") + (c4.useHTML ? " highcharts-tracker" : "")), T2 && (T2.options = c4, T2.attr(w), s3.styledMode ? S4.width && T2.css({
23953                  width: S4.width,
23954                  textOverflow: S4.textOverflow
23955                }) : T2.css(S4).shadow(c4.shadow), l(T2, "beforeAddingDataLabel", {
23956                  labelOptions: c4,
23957                  point: t5
23958                }), T2.added || T2.add(e4), i4.alignDataLabel(t5, T2, c4, void 0, P), T2.isActive = true, o2[f2] && o2[f2] !== T2 && o2[f2].destroy(), o2[f2] = T2));
23959              });
23960              let c3 = o2.length;
23961              for (; c3--; ) o2[c3] && o2[c3].isActive ? o2[c3].isActive = false : (o2[c3]?.destroy(), o2.splice(c3, 1));
23962              t5.dataLabel = o2[0], t5.dataLabels = o2;
23963            })), l(this, "afterDrawDataLabels");
23964          }
23965          function y(t4, e4, i4, s3, o2, r2) {
23966            let a2 = this.chart, n2 = e4.align, l2 = e4.verticalAlign, h2 = t4.box ? 0 : t4.padding || 0, d2 = a2.inverted ? this.yAxis : this.xAxis, c2 = d2 ? d2.left - a2.plotLeft : 0, p2 = a2.inverted ? this.xAxis : this.yAxis, u12 = p2 ? p2.top - a2.plotTop : 0, {
23967              x: g2 = 0,
23968              y: f2 = 0
23969            } = e4, m2, x2;
23970            return (m2 = (i4.x || 0) + h2 + c2) < 0 && ("right" === n2 && g2 >= 0 ? (e4.align = "left", e4.inside = true) : g2 -= m2, x2 = true), (m2 = (i4.x || 0) + s3.width - h2 + c2) > a2.plotWidth && ("left" === n2 && g2 <= 0 ? (e4.align = "right", e4.inside = true) : g2 += a2.plotWidth - m2, x2 = true), (m2 = i4.y + h2 + u12) < 0 && ("bottom" === l2 && f2 >= 0 ? (e4.verticalAlign = "top", e4.inside = true) : f2 -= m2, x2 = true), (m2 = (i4.y || 0) + s3.height - h2 + u12) > a2.plotHeight && ("top" === l2 && f2 <= 0 ? (e4.verticalAlign = "bottom", e4.inside = true) : f2 += a2.plotHeight - m2, x2 = true), x2 && (e4.x = g2, e4.y = f2, t4.placed = !r2, t4.align(e4, void 0, o2)), x2;
23971          }
23972          function b(t4, e4) {
23973            let i4 = [], s3;
23974            if (h(t4) && !h(e4)) i4 = t4.map(function(t5) {
23975              return c(t5, e4);
23976            });
23977            else if (h(e4) && !h(t4)) i4 = e4.map(function(e5) {
23978              return c(t4, e5);
23979            });
23980            else if (h(t4) || h(e4)) {
23981              if (h(t4) && h(e4)) for (s3 = Math.max(t4.length, e4.length); s3--; ) i4[s3] = c(t4[s3], e4[s3]);
23982            } else i4 = c(t4, e4);
23983            return i4;
23984          }
23985          function v(t4) {
23986            let e4 = t4.chart.options.plotOptions;
23987            return f(b(b(e4?.series?.dataLabels, e4?.[t4.type]?.dataLabels), t4.options.dataLabels));
23988          }
23989          function S2(t4, e4, i4, s3, o2) {
23990            let r2 = this.chart, a2 = r2.inverted, n2 = this.xAxis, l2 = n2.reversed, h2 = ((a2 ? e4.height : e4.width) || 0) / 2, d2 = t4.pointWidth, c2 = d2 ? d2 / 2 : 0;
23991            e4.startXPos = a2 ? o2.x : l2 ? -h2 - c2 : n2.width - h2 + c2, e4.startYPos = a2 ? l2 ? this.yAxis.height - h2 + c2 : -h2 - c2 : o2.y, s3 ? "hidden" === e4.visibility && (e4.show(), e4.attr({
23992              opacity: 0
23993            }).animate({
23994              opacity: 1
23995            })) : e4.attr({
23996              opacity: 1
23997            }).animate({
23998              opacity: 0
23999            }, void 0, e4.hide), r2.hasRendered && (i4 && e4.attr({
24000              x: e4.startXPos,
24001              y: e4.startYPos
24002            }), e4.placed = true);
24003          }
24004          t3.compose = function(t4) {
24005            let o2 = t4.prototype;
24006            o2.initDataLabels || (o2.initDataLabels = m, o2.initDataLabelsGroup = s2, o2.alignDataLabel = i3, o2.drawDataLabels = x, o2.justifyDataLabel = y, o2.setDataLabelStartPos = S2, o2.hasDataLabels = e3);
24007          };
24008        }(s || (s = {})), s;
24009      }), i(e, "Series/Column/ColumnDataLabel.js", [e["Core/Series/DataLabel.js"], e["Core/Globals.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
24010        var o;
24011        let {
24012          composed: r
24013        } = e2, {
24014          series: a
24015        } = i2, {
24016          merge: n,
24017          pick: l,
24018          pushUnique: h
24019        } = s;
24020        return function(e3) {
24021          function i3(t3, e4, i4, s2, o2) {
24022            let r2 = this.chart.inverted, h2 = t3.series, d = (h2.xAxis ? h2.xAxis.len : this.chart.plotSizeX) || 0, c = (h2.yAxis ? h2.yAxis.len : this.chart.plotSizeY) || 0, p = t3.dlBox || t3.shapeArgs, u11 = l(t3.below, t3.plotY > l(this.translatedThreshold, c)), g = l(i4.inside, !!this.options.stacking);
24023            if (p) {
24024              if (s2 = n(p), !("allow" === i4.overflow && false === i4.crop)) {
24025                s2.y < 0 && (s2.height += s2.y, s2.y = 0);
24026                let t4 = s2.y + s2.height - c;
24027                t4 > 0 && t4 < s2.height - 1 && (s2.height -= t4);
24028              }
24029              r2 && (s2 = {
24030                x: c - s2.y - s2.height,
24031                y: d - s2.x - s2.width,
24032                width: s2.height,
24033                height: s2.width
24034              }), g || (r2 ? (s2.x += u11 ? 0 : s2.width, s2.width = 0) : (s2.y += u11 ? s2.height : 0, s2.height = 0));
24035            }
24036            i4.align = l(i4.align, !r2 || g ? "center" : u11 ? "right" : "left"), i4.verticalAlign = l(i4.verticalAlign, r2 || g ? "middle" : u11 ? "top" : "bottom"), a.prototype.alignDataLabel.call(this, t3, e4, i4, s2, o2), i4.inside && t3.contrastColor && e4.css({
24037              color: t3.contrastColor
24038            });
24039          }
24040          e3.compose = function(e4) {
24041            t2.compose(a), h(r, "ColumnDataLabel") && (e4.prototype.alignDataLabel = i3);
24042          };
24043        }(o || (o = {})), o;
24044      }), i(e, "Series/Bar/BarSeries.js", [e["Series/Column/ColumnSeries.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
24045        let {
24046          extend: s,
24047          merge: o
24048        } = i2;
24049        class r extends t2 {
24050        }
24051        return r.defaultOptions = o(t2.defaultOptions, {}), s(r.prototype, {
24052          inverted: true
24053        }), e2.registerSeriesType("bar", r), r;
24054      }), i(e, "Series/Scatter/ScatterSeriesDefaults.js", [], function() {
24055        return {
24056          lineWidth: 0,
24057          findNearestPointBy: "xy",
24058          jitter: {
24059            x: 0,
24060            y: 0
24061          },
24062          marker: {
24063            enabled: true
24064          },
24065          tooltip: {
24066            headerFormat: '<span style="color:{point.color}">\u25CF</span> <span style="font-size: 0.8em"> {series.name}</span><br/>',
24067            pointFormat: "x: <b>{point.x}</b><br/>y: <b>{point.y}</b><br/>"
24068          }
24069        };
24070      }), i(e, "Series/Scatter/ScatterSeries.js", [e["Series/Scatter/ScatterSeriesDefaults.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
24071        let {
24072          column: s,
24073          line: o
24074        } = e2.seriesTypes, {
24075          addEvent: r,
24076          extend: a,
24077          merge: n
24078        } = i2;
24079        class l extends o {
24080          applyJitter() {
24081            let t3 = this, e3 = this.options.jitter, i3 = this.points.length;
24082            e3 && this.points.forEach(function(s2, o2) {
24083              ["x", "y"].forEach(function(r2, a2) {
24084                if (e3[r2] && !s2.isNull) {
24085                  let n2 = `plot${r2.toUpperCase()}`, l2 = t3[`${r2}Axis`], h = e3[r2] * l2.transA;
24086                  if (l2 && !l2.logarithmic) {
24087                    let t4 = Math.max(0, (s2[n2] || 0) - h), e4 = Math.min(l2.len, (s2[n2] || 0) + h);
24088                    s2[n2] = t4 + (e4 - t4) * function(t5) {
24089                      let e5 = 1e4 * Math.sin(t5);
24090                      return e5 - Math.floor(e5);
24091                    }(o2 + a2 * i3), "x" === r2 && (s2.clientX = s2.plotX);
24092                  }
24093                }
24094              });
24095            });
24096          }
24097          drawGraph() {
24098            this.options.lineWidth ? super.drawGraph() : this.graph && (this.graph = this.graph.destroy());
24099          }
24100        }
24101        return l.defaultOptions = n(o.defaultOptions, t2), a(l.prototype, {
24102          drawTracker: s.prototype.drawTracker,
24103          sorted: false,
24104          requireSorting: false,
24105          noSharedTooltip: true,
24106          trackerGroups: ["group", "markerGroup", "dataLabelsGroup"]
24107        }), r(l, "afterTranslate", function() {
24108          this.applyJitter();
24109        }), e2.registerSeriesType("scatter", l), l;
24110      }), i(e, "Series/CenteredUtilities.js", [e["Core/Globals.js"], e["Core/Series/Series.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
24111        var s, o;
24112        let {
24113          deg2rad: r
24114        } = t2, {
24115          fireEvent: a,
24116          isNumber: n,
24117          pick: l,
24118          relativeLength: h
24119        } = i2;
24120        return (o = s || (s = {})).getCenter = function() {
24121          let t3 = this.options, i3 = this.chart, s2 = 2 * (t3.slicedOffset || 0), o2 = i3.plotWidth - 2 * s2, r2 = i3.plotHeight - 2 * s2, d = t3.center, c = Math.min(o2, r2), p = t3.thickness, u11, g = t3.size, f = t3.innerSize || 0, m, x;
24122          "string" == typeof g && (g = parseFloat(g)), "string" == typeof f && (f = parseFloat(f));
24123          let y = [l(d[0], "50%"), l(d[1], "50%"), l(g && g < 0 ? void 0 : t3.size, "100%"), l(f && f < 0 ? void 0 : t3.innerSize || 0, "0%")];
24124          for (!i3.angular || this instanceof e2 || (y[3] = 0), m = 0; m < 4; ++m) x = y[m], u11 = m < 2 || 2 === m && /%$/.test(x), y[m] = h(x, [o2, r2, c, y[2]][m]) + (u11 ? s2 : 0);
24125          return y[3] > y[2] && (y[3] = y[2]), n(p) && 2 * p < y[2] && p > 0 && (y[3] = y[2] - 2 * p), a(this, "afterGetCenter", {
24126            positions: y
24127          }), y;
24128        }, o.getStartAndEndRadians = function(t3, e3) {
24129          let i3 = n(t3) ? t3 : 0, s2 = n(e3) && e3 > i3 && e3 - i3 < 360 ? e3 : i3 + 360;
24130          return {
24131            start: r * (i3 + -90),
24132            end: r * (s2 + -90)
24133          };
24134        }, s;
24135      }), i(e, "Series/Pie/PiePoint.js", [e["Core/Animation/AnimationUtilities.js"], e["Core/Series/Point.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
24136        let {
24137          setAnimation: s
24138        } = t2, {
24139          addEvent: o,
24140          defined: r,
24141          extend: a,
24142          isNumber: n,
24143          pick: l,
24144          relativeLength: h
24145        } = i2;
24146        class d extends e2 {
24147          getConnectorPath(t3) {
24148            let e3 = t3.dataLabelPosition, i3 = t3.options || {}, s2 = i3.connectorShape, o2 = this.connectorShapes[s2] || s2;
24149            return e3 && o2.call(this, __spreadProps(__spreadValues({}, e3.computed), {
24150              alignment: e3.alignment
24151            }), e3.connectorPosition, i3) || [];
24152          }
24153          getTranslate() {
24154            return this.sliced && this.slicedTranslation || {
24155              translateX: 0,
24156              translateY: 0
24157            };
24158          }
24159          haloPath(t3) {
24160            let e3 = this.shapeArgs;
24161            return this.sliced || !this.visible ? [] : this.series.chart.renderer.symbols.arc(e3.x, e3.y, e3.r + t3, e3.r + t3, {
24162              innerR: e3.r - 1,
24163              start: e3.start,
24164              end: e3.end,
24165              borderRadius: e3.borderRadius
24166            });
24167          }
24168          constructor(t3, e3, i3) {
24169            super(t3, e3, i3), this.half = 0, this.name ?? (this.name = "Slice");
24170            let s2 = (t4) => {
24171              this.slice("select" === t4.type);
24172            };
24173            o(this, "select", s2), o(this, "unselect", s2);
24174          }
24175          isValid() {
24176            return n(this.y) && this.y >= 0;
24177          }
24178          setVisible(t3, e3 = true) {
24179            t3 !== this.visible && this.update({
24180              visible: t3 ?? !this.visible
24181            }, e3, void 0, false);
24182          }
24183          slice(t3, e3, i3) {
24184            let o2 = this.series;
24185            s(i3, o2.chart), e3 = l(e3, true), this.sliced = this.options.sliced = t3 = r(t3) ? t3 : !this.sliced, o2.options.data[o2.data.indexOf(this)] = this.options, this.graphic && this.graphic.animate(this.getTranslate());
24186          }
24187        }
24188        return a(d.prototype, {
24189          connectorShapes: {
24190            fixedOffset: function(t3, e3, i3) {
24191              let s2 = e3.breakAt, o2 = e3.touchingSliceAt, r2 = i3.softConnector ? ["C", t3.x + ("left" === t3.alignment ? -5 : 5), t3.y, 2 * s2.x - o2.x, 2 * s2.y - o2.y, s2.x, s2.y] : ["L", s2.x, s2.y];
24192              return [["M", t3.x, t3.y], r2, ["L", o2.x, o2.y]];
24193            },
24194            straight: function(t3, e3) {
24195              let i3 = e3.touchingSliceAt;
24196              return [["M", t3.x, t3.y], ["L", i3.x, i3.y]];
24197            },
24198            crookedLine: function(t3, e3, i3) {
24199              let {
24200                breakAt: s2,
24201                touchingSliceAt: o2
24202              } = e3, {
24203                series: r2
24204              } = this, [a2, n2, l2] = r2.center, d2 = l2 / 2, {
24205                plotLeft: c,
24206                plotWidth: p
24207              } = r2.chart, u11 = "left" === t3.alignment, {
24208                x: g,
24209                y: f
24210              } = t3, m = s2.x;
24211              if (i3.crookDistance) {
24212                let t4 = h(i3.crookDistance, 1);
24213                m = u11 ? a2 + d2 + (p + c - a2 - d2) * (1 - t4) : c + (a2 - d2) * t4;
24214              } else m = a2 + (n2 - f) * Math.tan((this.angle || 0) - Math.PI / 2);
24215              let x = [["M", g, f]];
24216              return (u11 ? m <= g && m >= s2.x : m >= g && m <= s2.x) && x.push(["L", m, f]), x.push(["L", s2.x, s2.y], ["L", o2.x, o2.y]), x;
24217            }
24218          }
24219        }), d;
24220      }), i(e, "Series/Pie/PieSeriesDefaults.js", [], function() {
24221        return {
24222          borderRadius: 3,
24223          center: [null, null],
24224          clip: false,
24225          colorByPoint: true,
24226          dataLabels: {
24227            connectorPadding: 5,
24228            connectorShape: "crookedLine",
24229            crookDistance: void 0,
24230            distance: 30,
24231            enabled: true,
24232            formatter: function() {
24233              return this.point.isNull ? void 0 : this.point.name;
24234            },
24235            softConnector: true,
24236            x: 0
24237          },
24238          fillColor: void 0,
24239          ignoreHiddenPoint: true,
24240          inactiveOtherPoints: true,
24241          legendType: "point",
24242          marker: null,
24243          size: null,
24244          showInLegend: false,
24245          slicedOffset: 10,
24246          stickyTracking: false,
24247          tooltip: {
24248            followPointer: true
24249          },
24250          borderColor: "#ffffff",
24251          borderWidth: 1,
24252          lineWidth: void 0,
24253          states: {
24254            hover: {
24255              brightness: 0.1
24256            }
24257          }
24258        };
24259      }), i(e, "Series/Pie/PieSeries.js", [e["Series/CenteredUtilities.js"], e["Series/Column/ColumnSeries.js"], e["Core/Globals.js"], e["Series/Pie/PiePoint.js"], e["Series/Pie/PieSeriesDefaults.js"], e["Core/Series/Series.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Renderer/SVG/Symbols.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o, r, a, n, l) {
24260        let {
24261          getStartAndEndRadians: h
24262        } = t2, {
24263          noop: d
24264        } = i2, {
24265          clamp: c,
24266          extend: p,
24267          fireEvent: u11,
24268          merge: g,
24269          pick: f
24270        } = l;
24271        class m extends r {
24272          animate(t3) {
24273            let e3 = this, i3 = e3.points, s2 = e3.startAngleRad;
24274            t3 || i3.forEach(function(t4) {
24275              let i4 = t4.graphic, o2 = t4.shapeArgs;
24276              i4 && o2 && (i4.attr({
24277                r: f(t4.startR, e3.center && e3.center[3] / 2),
24278                start: s2,
24279                end: s2
24280              }), i4.animate({
24281                r: o2.r,
24282                start: o2.start,
24283                end: o2.end
24284              }, e3.options.animation));
24285            });
24286          }
24287          drawEmpty() {
24288            let t3, e3;
24289            let i3 = this.startAngleRad, s2 = this.endAngleRad, o2 = this.options;
24290            0 === this.total && this.center ? (t3 = this.center[0], e3 = this.center[1], this.graph || (this.graph = this.chart.renderer.arc(t3, e3, this.center[1] / 2, 0, i3, s2).addClass("highcharts-empty-series").add(this.group)), this.graph.attr({
24291              d: n.arc(t3, e3, this.center[2] / 2, 0, {
24292                start: i3,
24293                end: s2,
24294                innerR: this.center[3] / 2
24295              })
24296            }), this.chart.styledMode || this.graph.attr({
24297              "stroke-width": o2.borderWidth,
24298              fill: o2.fillColor || "none",
24299              stroke: o2.color || "#cccccc"
24300            })) : this.graph && (this.graph = this.graph.destroy());
24301          }
24302          drawPoints() {
24303            let t3 = this.chart.renderer;
24304            this.points.forEach(function(e3) {
24305              e3.graphic && e3.hasNewShapeType() && (e3.graphic = e3.graphic.destroy()), e3.graphic || (e3.graphic = t3[e3.shapeType](e3.shapeArgs).add(e3.series.group), e3.delayedRendering = true);
24306            });
24307          }
24308          generatePoints() {
24309            super.generatePoints(), this.updateTotals();
24310          }
24311          getX(t3, e3, i3, s2) {
24312            let o2 = this.center, r2 = this.radii ? this.radii[i3.index] || 0 : o2[2] / 2, a2 = s2.dataLabelPosition, n2 = a2?.distance || 0, l2 = Math.asin(c((t3 - o2[1]) / (r2 + n2), -1, 1));
24313            return o2[0] + Math.cos(l2) * (r2 + n2) * (e3 ? -1 : 1) + (n2 > 0 ? (e3 ? -1 : 1) * (s2.padding || 0) : 0);
24314          }
24315          hasData() {
24316            return !!this.processedXData.length;
24317          }
24318          redrawPoints() {
24319            let t3, e3, i3, s2;
24320            let o2 = this, r2 = o2.chart;
24321            this.drawEmpty(), o2.group && !r2.styledMode && o2.group.shadow(o2.options.shadow), o2.points.forEach(function(a2) {
24322              let n2 = {};
24323              e3 = a2.graphic, !a2.isNull && e3 ? (s2 = a2.shapeArgs, t3 = a2.getTranslate(), r2.styledMode || (i3 = o2.pointAttribs(a2, a2.selected && "select")), a2.delayedRendering ? (e3.setRadialReference(o2.center).attr(s2).attr(t3), r2.styledMode || e3.attr(i3).attr({
24324                "stroke-linejoin": "round"
24325              }), a2.delayedRendering = false) : (e3.setRadialReference(o2.center), r2.styledMode || g(true, n2, i3), g(true, n2, s2, t3), e3.animate(n2)), e3.attr({
24326                visibility: a2.visible ? "inherit" : "hidden"
24327              }), e3.addClass(a2.getClassName(), true)) : e3 && (a2.graphic = e3.destroy());
24328            });
24329          }
24330          sortByAngle(t3, e3) {
24331            t3.sort(function(t4, i3) {
24332              return void 0 !== t4.angle && (i3.angle - t4.angle) * e3;
24333            });
24334          }
24335          translate(t3) {
24336            u11(this, "translate"), this.generatePoints();
24337            let e3 = this.options, i3 = e3.slicedOffset, s2 = h(e3.startAngle, e3.endAngle), o2 = this.startAngleRad = s2.start, r2 = (this.endAngleRad = s2.end) - o2, a2 = this.points, n2 = e3.ignoreHiddenPoint, l2 = a2.length, d2, c2, p2, g2, f2, m2, x, y = 0;
24338            for (t3 || (this.center = t3 = this.getCenter()), m2 = 0; m2 < l2; m2++) {
24339              x = a2[m2], d2 = o2 + y * r2, x.isValid() && (!n2 || x.visible) && (y += x.percentage / 100), c2 = o2 + y * r2;
24340              let e4 = {
24341                x: t3[0],
24342                y: t3[1],
24343                r: t3[2] / 2,
24344                innerR: t3[3] / 2,
24345                start: Math.round(1e3 * d2) / 1e3,
24346                end: Math.round(1e3 * c2) / 1e3
24347              };
24348              x.shapeType = "arc", x.shapeArgs = e4, (p2 = (c2 + d2) / 2) > 1.5 * Math.PI ? p2 -= 2 * Math.PI : p2 < -Math.PI / 2 && (p2 += 2 * Math.PI), x.slicedTranslation = {
24349                translateX: Math.round(Math.cos(p2) * i3),
24350                translateY: Math.round(Math.sin(p2) * i3)
24351              }, g2 = Math.cos(p2) * t3[2] / 2, f2 = Math.sin(p2) * t3[2] / 2, x.tooltipPos = [t3[0] + 0.7 * g2, t3[1] + 0.7 * f2], x.half = p2 < -Math.PI / 2 || p2 > Math.PI / 2 ? 1 : 0, x.angle = p2;
24352            }
24353            u11(this, "afterTranslate");
24354          }
24355          updateTotals() {
24356            let t3 = this.points, e3 = t3.length, i3 = this.options.ignoreHiddenPoint, s2, o2, r2 = 0;
24357            for (s2 = 0; s2 < e3; s2++) (o2 = t3[s2]).isValid() && (!i3 || o2.visible) && (r2 += o2.y);
24358            for (s2 = 0, this.total = r2; s2 < e3; s2++) (o2 = t3[s2]).percentage = r2 > 0 && (o2.visible || !i3) ? o2.y / r2 * 100 : 0, o2.total = r2;
24359          }
24360        }
24361        return m.defaultOptions = g(r.defaultOptions, o), p(m.prototype, {
24362          axisTypes: [],
24363          directTouch: true,
24364          drawGraph: void 0,
24365          drawTracker: e2.prototype.drawTracker,
24366          getCenter: t2.getCenter,
24367          getSymbol: d,
24368          invertible: false,
24369          isCartesian: false,
24370          noSharedTooltip: true,
24371          pointAttribs: e2.prototype.pointAttribs,
24372          pointClass: s,
24373          requireSorting: false,
24374          searchPoint: d,
24375          trackerGroups: ["group", "dataLabelsGroup"]
24376        }), a.registerSeriesType("pie", m), m;
24377      }), i(e, "Series/Pie/PieDataLabel.js", [e["Core/Series/DataLabel.js"], e["Core/Globals.js"], e["Core/Renderer/RendererUtilities.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o) {
24378        var r;
24379        let {
24380          composed: a,
24381          noop: n
24382        } = e2, {
24383          distribute: l
24384        } = i2, {
24385          series: h
24386        } = s, {
24387          arrayMax: d,
24388          clamp: c,
24389          defined: p,
24390          pick: u11,
24391          pushUnique: g,
24392          relativeLength: f
24393        } = o;
24394        return function(e3) {
24395          let i3 = {
24396            radialDistributionY: function(t3, e4) {
24397              return (e4.dataLabelPosition?.top || 0) + t3.distributeBox.pos;
24398            },
24399            radialDistributionX: function(t3, e4, i4, s3, o3) {
24400              let r3 = o3.dataLabelPosition;
24401              return t3.getX(i4 < (r3?.top || 0) + 2 || i4 > (r3?.bottom || 0) - 2 ? s3 : i4, e4.half, e4, o3);
24402            },
24403            justify: function(t3, e4, i4, s3) {
24404              return s3[0] + (t3.half ? -1 : 1) * (i4 + (e4.dataLabelPosition?.distance || 0));
24405            },
24406            alignToPlotEdges: function(t3, e4, i4, s3) {
24407              let o3 = t3.getBBox().width;
24408              return e4 ? o3 + s3 : i4 - o3 - s3;
24409            },
24410            alignToConnectors: function(t3, e4, i4, s3) {
24411              let o3 = 0, r3;
24412              return t3.forEach(function(t4) {
24413                (r3 = t4.dataLabel.getBBox().width) > o3 && (o3 = r3);
24414              }), e4 ? o3 + s3 : i4 - o3 - s3;
24415            }
24416          };
24417          function s2(t3, e4) {
24418            let {
24419              center: i4,
24420              options: s3
24421            } = this, o3 = i4[2] / 2, r3 = t3.angle || 0, a2 = Math.cos(r3), n2 = Math.sin(r3), l2 = i4[0] + a2 * o3, h2 = i4[1] + n2 * o3, d2 = Math.min((s3.slicedOffset || 0) + (s3.borderWidth || 0), e4 / 5);
24422            return {
24423              natural: {
24424                x: l2 + a2 * e4,
24425                y: h2 + n2 * e4
24426              },
24427              computed: {},
24428              alignment: e4 < 0 ? "center" : t3.half ? "right" : "left",
24429              connectorPosition: {
24430                breakAt: {
24431                  x: l2 + a2 * d2,
24432                  y: h2 + n2 * d2
24433                },
24434                touchingSliceAt: {
24435                  x: l2,
24436                  y: h2
24437                }
24438              },
24439              distance: e4
24440            };
24441          }
24442          function o2() {
24443            let t3 = this, e4 = t3.points, i4 = t3.chart, s3 = i4.plotWidth, o3 = i4.plotHeight, r3 = i4.plotLeft, a2 = Math.round(i4.chartWidth / 3), n2 = t3.center, c2 = n2[2] / 2, g2 = n2[1], m2 = [[], []], x = [0, 0, 0, 0], y = t3.dataLabelPositioners, b, v, S2, k = 0;
24444            t3.visible && t3.hasDataLabels?.() && (e4.forEach((t4) => {
24445              (t4.dataLabels || []).forEach((t5) => {
24446                t5.shortened && (t5.attr({
24447                  width: "auto"
24448                }).css({
24449                  width: "auto",
24450                  textOverflow: "clip"
24451                }), t5.shortened = false);
24452              });
24453            }), h.prototype.drawDataLabels.apply(t3), e4.forEach((t4) => {
24454              (t4.dataLabels || []).forEach((e5, i5) => {
24455                let s4 = n2[2] / 2, o4 = e5.options, r4 = f(o4?.distance || 0, s4);
24456                0 === i5 && m2[t4.half].push(t4), !p(o4?.style?.width) && e5.getBBox().width > a2 && (e5.css({
24457                  width: Math.round(0.7 * a2) + "px"
24458                }), e5.shortened = true), e5.dataLabelPosition = this.getDataLabelPosition(t4, r4), k = Math.max(k, r4);
24459              });
24460            }), m2.forEach((e5, a3) => {
24461              let h2 = e5.length, d2 = [], f2, m3, b2 = 0, M;
24462              h2 && (t3.sortByAngle(e5, a3 - 0.5), k > 0 && (f2 = Math.max(0, g2 - c2 - k), m3 = Math.min(g2 + c2 + k, i4.plotHeight), e5.forEach((t4) => {
24463                (t4.dataLabels || []).forEach((e6) => {
24464                  let s4 = e6.dataLabelPosition;
24465                  s4 && s4.distance > 0 && (s4.top = Math.max(0, g2 - c2 - s4.distance), s4.bottom = Math.min(g2 + c2 + s4.distance, i4.plotHeight), b2 = e6.getBBox().height || 21, e6.lineHeight = i4.renderer.fontMetrics(e6.text || e6).h + 2 * e6.padding, t4.distributeBox = {
24466                    target: (e6.dataLabelPosition?.natural.y || 0) - s4.top + e6.lineHeight / 2,
24467                    size: b2,
24468                    rank: t4.y
24469                  }, d2.push(t4.distributeBox));
24470                });
24471              }), l(d2, M = m3 + b2 - f2, M / 5)), e5.forEach((i5) => {
24472                (i5.dataLabels || []).forEach((l2) => {
24473                  let h3 = l2.options || {}, g3 = i5.distributeBox, f3 = l2.dataLabelPosition, m4 = f3?.natural.y || 0, b3 = h3.connectorPadding || 0, k2 = l2.lineHeight || 21, M2 = (k2 - l2.getBBox().height) / 2, C = 0, A = m4, w = "inherit";
24474                  if (f3) {
24475                    if (d2 && p(g3) && f3.distance > 0 && (void 0 === g3.pos ? w = "hidden" : (S2 = g3.size, A = y.radialDistributionY(i5, l2))), h3.justify) C = y.justify(i5, l2, c2, n2);
24476                    else switch (h3.alignTo) {
24477                      case "connectors":
24478                        C = y.alignToConnectors(e5, a3, s3, r3);
24479                        break;
24480                      case "plotEdges":
24481                        C = y.alignToPlotEdges(l2, a3, s3, r3);
24482                        break;
24483                      default:
24484                        C = y.radialDistributionX(t3, i5, A - M2, m4, l2);
24485                    }
24486                    if (f3.attribs = {
24487                      visibility: w,
24488                      align: f3.alignment
24489                    }, f3.posAttribs = {
24490                      x: C + (h3.x || 0) + ({
24491                        left: b3,
24492                        right: -b3
24493                      }[f3.alignment] || 0),
24494                      y: A + (h3.y || 0) - k2 / 2
24495                    }, f3.computed.x = C, f3.computed.y = A - M2, u11(h3.crop, true)) {
24496                      let t4;
24497                      C - (v = l2.getBBox().width) < b3 && 1 === a3 ? (t4 = Math.round(v - C + b3), x[3] = Math.max(t4, x[3])) : C + v > s3 - b3 && 0 === a3 && (t4 = Math.round(C + v - s3 + b3), x[1] = Math.max(t4, x[1])), A - S2 / 2 < 0 ? x[0] = Math.max(Math.round(-A + S2 / 2), x[0]) : A + S2 / 2 > o3 && (x[2] = Math.max(Math.round(A + S2 / 2 - o3), x[2])), f3.sideOverflow = t4;
24498                    }
24499                  }
24500                });
24501              }));
24502            }), (0 === d(x) || this.verifyDataLabelOverflow(x)) && (this.placeDataLabels(), this.points.forEach((e5) => {
24503              (e5.dataLabels || []).forEach((s4) => {
24504                let {
24505                  connectorColor: o4,
24506                  connectorWidth: r4 = 1
24507                } = s4.options || {}, a3 = s4.dataLabelPosition;
24508                if (r4) {
24509                  let n3;
24510                  b = s4.connector, a3 && a3.distance > 0 ? (n3 = !b, b || (s4.connector = b = i4.renderer.path().addClass("highcharts-data-label-connector  highcharts-color-" + e5.colorIndex + (e5.className ? " " + e5.className : "")).add(t3.dataLabelsGroup)), i4.styledMode || b.attr({
24511                    "stroke-width": r4,
24512                    stroke: o4 || e5.color || "#666666"
24513                  }), b[n3 ? "attr" : "animate"]({
24514                    d: e5.getConnectorPath(s4)
24515                  }), b.attr({
24516                    visibility: a3.attribs?.visibility
24517                  })) : b && (s4.connector = b.destroy());
24518                }
24519              });
24520            })));
24521          }
24522          function r2() {
24523            this.points.forEach((t3) => {
24524              (t3.dataLabels || []).forEach((t4) => {
24525                let e4 = t4.dataLabelPosition;
24526                e4 ? (e4.sideOverflow && (t4.css({
24527                  width: Math.max(t4.getBBox().width - e4.sideOverflow, 0) + "px",
24528                  textOverflow: (t4.options?.style || {}).textOverflow || "ellipsis"
24529                }), t4.shortened = true), t4.attr(e4.attribs), t4[t4.moved ? "animate" : "attr"](e4.posAttribs), t4.moved = true) : t4 && t4.attr({
24530                  y: -9999
24531                });
24532              }), delete t3.distributeBox;
24533            }, this);
24534          }
24535          function m(t3) {
24536            let e4 = this.center, i4 = this.options, s3 = i4.center, o3 = i4.minSize || 80, r3 = o3, a2 = null !== i4.size;
24537            return !a2 && (null !== s3[0] ? r3 = Math.max(e4[2] - Math.max(t3[1], t3[3]), o3) : (r3 = Math.max(e4[2] - t3[1] - t3[3], o3), e4[0] += (t3[3] - t3[1]) / 2), null !== s3[1] ? r3 = c(r3, o3, e4[2] - Math.max(t3[0], t3[2])) : (r3 = c(r3, o3, e4[2] - t3[0] - t3[2]), e4[1] += (t3[0] - t3[2]) / 2), r3 < e4[2] ? (e4[2] = r3, e4[3] = Math.min(i4.thickness ? Math.max(0, r3 - 2 * i4.thickness) : Math.max(0, f(i4.innerSize || 0, r3)), r3), this.translate(e4), this.drawDataLabels && this.drawDataLabels()) : a2 = true), a2;
24538          }
24539          e3.compose = function(e4) {
24540            if (t2.compose(h), g(a, "PieDataLabel")) {
24541              let t3 = e4.prototype;
24542              t3.dataLabelPositioners = i3, t3.alignDataLabel = n, t3.drawDataLabels = o2, t3.getDataLabelPosition = s2, t3.placeDataLabels = r2, t3.verifyDataLabelOverflow = m;
24543            }
24544          };
24545        }(r || (r = {})), r;
24546      }), i(e, "Core/Geometry/GeometryUtilities.js", [], function() {
24547        var t2, e2;
24548        return (e2 = t2 || (t2 = {})).getCenterOfPoints = function(t3) {
24549          let e3 = t3.reduce((t4, e4) => (t4.x += e4.x, t4.y += e4.y, t4), {
24550            x: 0,
24551            y: 0
24552          });
24553          return {
24554            x: e3.x / t3.length,
24555            y: e3.y / t3.length
24556          };
24557        }, e2.getDistanceBetweenPoints = function(t3, e3) {
24558          return Math.sqrt(Math.pow(e3.x - t3.x, 2) + Math.pow(e3.y - t3.y, 2));
24559        }, e2.getAngleBetweenPoints = function(t3, e3) {
24560          return Math.atan2(e3.x - t3.x, e3.y - t3.y);
24561        }, e2.pointInPolygon = function({
24562          x: t3,
24563          y: e3
24564        }, i2) {
24565          let s = i2.length, o, r, a = false;
24566          for (o = 0, r = s - 1; o < s; r = o++) {
24567            let [s2, n] = i2[o], [l, h] = i2[r];
24568            n > e3 != h > e3 && t3 < (l - s2) * (e3 - n) / (h - n) + s2 && (a = !a);
24569          }
24570          return a;
24571        }, t2;
24572      }), i(e, "Extensions/OverlappingDataLabels.js", [e["Core/Geometry/GeometryUtilities.js"], e["Core/Utilities.js"]], function(t2, e2) {
24573        let {
24574          pointInPolygon: i2
24575        } = t2, {
24576          addEvent: s,
24577          fireEvent: o,
24578          objectEach: r,
24579          pick: a
24580        } = e2;
24581        function n(t3) {
24582          let e3 = t3.length, s2 = (t4, e4) => !(e4.x >= t4.x + t4.width || e4.x + e4.width <= t4.x || e4.y >= t4.y + t4.height || e4.y + e4.height <= t4.y), r2 = (t4, e4) => {
24583            for (let s3 of t4) if (i2({
24584              x: s3[0],
24585              y: s3[1]
24586            }, e4)) return true;
24587            return false;
24588          }, a2, n2, h2, d, c, p = false;
24589          for (let i3 = 0; i3 < e3; i3++) (a2 = t3[i3]) && (a2.oldOpacity = a2.opacity, a2.newOpacity = 1, a2.absoluteBox = function(t4) {
24590            if (t4 && (!t4.alignAttr || t4.placed)) {
24591              let e4 = t4.box ? 0 : t4.padding || 0, i4 = t4.alignAttr || {
24592                x: t4.attr("x"),
24593                y: t4.attr("y")
24594              }, s3 = t4.getBBox();
24595              return t4.width = s3.width, t4.height = s3.height, {
24596                x: i4.x + (t4.parentGroup?.translateX || 0) + e4,
24597                y: i4.y + (t4.parentGroup?.translateY || 0) + e4,
24598                width: (t4.width || 0) - 2 * e4,
24599                height: (t4.height || 0) - 2 * e4,
24600                polygon: s3?.polygon
24601              };
24602            }
24603          }(a2));
24604          t3.sort((t4, e4) => (e4.labelrank || 0) - (t4.labelrank || 0));
24605          for (let i3 = 0; i3 < e3; ++i3) {
24606            d = (n2 = t3[i3]) && n2.absoluteBox;
24607            let o2 = d?.polygon;
24608            for (let a3 = i3 + 1; a3 < e3; ++a3) {
24609              c = (h2 = t3[a3]) && h2.absoluteBox;
24610              let e4 = false;
24611              if (d && c && n2 !== h2 && 0 !== n2.newOpacity && 0 !== h2.newOpacity && "hidden" !== n2.visibility && "hidden" !== h2.visibility) {
24612                let t4 = c.polygon;
24613                if (o2 && t4 && o2 !== t4 ? r2(o2, t4) && (e4 = true) : s2(d, c) && (e4 = true), e4) {
24614                  let t5 = n2.labelrank < h2.labelrank ? n2 : h2, e5 = t5.text;
24615                  t5.newOpacity = 0, e5?.element.querySelector("textPath") && e5.hide();
24616                }
24617              }
24618            }
24619          }
24620          for (let e4 of t3) l(e4, this) && (p = true);
24621          p && o(this, "afterHideAllOverlappingLabels");
24622        }
24623        function l(t3, e3) {
24624          let i3, s2, r2 = false;
24625          return t3 && (s2 = t3.newOpacity, t3.oldOpacity !== s2 && (t3.hasClass("highcharts-data-label") ? (t3[s2 ? "removeClass" : "addClass"]("highcharts-data-label-hidden"), i3 = function() {
24626            e3.styledMode || t3.css({
24627              pointerEvents: s2 ? "auto" : "none"
24628            });
24629          }, r2 = true, t3[t3.isOld ? "animate" : "attr"]({
24630            opacity: s2
24631          }, void 0, i3), o(e3, "afterHideOverlappingLabel")) : t3.attr({
24632            opacity: s2
24633          })), t3.isOld = true), r2;
24634        }
24635        function h() {
24636          let t3 = this, e3 = [];
24637          for (let i3 of t3.labelCollectors || []) e3 = e3.concat(i3());
24638          for (let i3 of t3.yAxis || []) i3.stacking && i3.options.stackLabels && !i3.options.stackLabels.allowOverlap && r(i3.stacking.stacks, (t4) => {
24639            r(t4, (t5) => {
24640              t5.label && e3.push(t5.label);
24641            });
24642          });
24643          for (let i3 of t3.series || []) if (i3.visible && i3.hasDataLabels?.()) {
24644            let s2 = (i4) => {
24645              for (let s3 of i4) s3.visible && (s3.dataLabels || []).forEach((i5) => {
24646                let o2 = i5.options || {};
24647                i5.labelrank = a(o2.labelrank, s3.labelrank, s3.shapeArgs?.height), o2.allowOverlap ?? Number(o2.distance) > 0 ? (i5.oldOpacity = i5.opacity, i5.newOpacity = 1, l(i5, t3)) : e3.push(i5);
24648              });
24649            };
24650            s2(i3.nodes || []), s2(i3.points);
24651          }
24652          this.hideOverlappingLabels(e3);
24653        }
24654        return {
24655          compose: function(t3) {
24656            let e3 = t3.prototype;
24657            e3.hideOverlappingLabels || (e3.hideOverlappingLabels = n, s(t3, "render", h));
24658          }
24659        };
24660      }), i(e, "Extensions/BorderRadius.js", [e["Core/Defaults.js"], e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
24661        let {
24662          defaultOptions: s
24663        } = t2, {
24664          noop: o
24665        } = e2, {
24666          addEvent: r,
24667          extend: a,
24668          isObject: n,
24669          merge: l,
24670          relativeLength: h
24671        } = i2, d = {
24672          radius: 0,
24673          scope: "stack",
24674          where: void 0
24675        }, c = o, p = o;
24676        function u11(t3, e3, i3, s2, o2 = {}) {
24677          let r2 = c(t3, e3, i3, s2, o2), {
24678            innerR: a2 = 0,
24679            r: n2 = i3,
24680            start: l2 = 0,
24681            end: d2 = 0
24682          } = o2;
24683          if (o2.open || !o2.borderRadius) return r2;
24684          let p2 = d2 - l2, g2 = Math.sin(p2 / 2), f2 = Math.max(Math.min(h(o2.borderRadius || 0, n2 - a2), (n2 - a2) / 2, n2 * g2 / (1 + g2)), 0), m2 = Math.min(f2, p2 / Math.PI * 2 * a2), x2 = r2.length - 1;
24685          for (; x2--; ) !function(t4, e4, i4) {
24686            let s3, o3, r3;
24687            let a3 = t4[e4], n3 = t4[e4 + 1];
24688            if ("Z" === n3[0] && (n3 = t4[0]), ("M" === a3[0] || "L" === a3[0]) && "A" === n3[0] ? (s3 = a3, o3 = n3, r3 = true) : "A" === a3[0] && ("M" === n3[0] || "L" === n3[0]) && (s3 = n3, o3 = a3), s3 && o3 && o3.params) {
24689              let a4 = o3[1], n4 = o3[5], l3 = o3.params, {
24690                start: h2,
24691                end: d3,
24692                cx: c2,
24693                cy: p3
24694              } = l3, u12 = n4 ? a4 - i4 : a4 + i4, g3 = u12 ? Math.asin(i4 / u12) : 0, f3 = n4 ? g3 : -g3, m3 = Math.cos(g3) * u12;
24695              r3 ? (l3.start = h2 + f3, s3[1] = c2 + m3 * Math.cos(h2), s3[2] = p3 + m3 * Math.sin(h2), t4.splice(e4 + 1, 0, ["A", i4, i4, 0, 0, 1, c2 + a4 * Math.cos(l3.start), p3 + a4 * Math.sin(l3.start)])) : (l3.end = d3 - f3, o3[6] = c2 + a4 * Math.cos(l3.end), o3[7] = p3 + a4 * Math.sin(l3.end), t4.splice(e4 + 1, 0, ["A", i4, i4, 0, 0, 1, c2 + m3 * Math.cos(d3), p3 + m3 * Math.sin(d3)])), o3[4] = Math.abs(l3.end - l3.start) < Math.PI ? 0 : 1;
24696            }
24697          }(r2, x2, x2 > 1 ? m2 : f2);
24698          return r2;
24699        }
24700        function g() {
24701          if (this.options.borderRadius && !(this.chart.is3d && this.chart.is3d())) {
24702            let {
24703              options: t3,
24704              yAxis: e3
24705            } = this, i3 = "percent" === t3.stacking, o2 = s.plotOptions?.[this.type]?.borderRadius, r2 = f(t3.borderRadius, n(o2) ? o2 : {}), l2 = e3.options.reversed;
24706            for (let s2 of this.points) {
24707              let {
24708                shapeArgs: o3
24709              } = s2;
24710              if ("roundedRect" === s2.shapeType && o3) {
24711                let {
24712                  width: n2 = 0,
24713                  height: d2 = 0,
24714                  y: c2 = 0
24715                } = o3, p2 = c2, u12 = d2;
24716                if ("stack" === r2.scope && s2.stackTotal) {
24717                  let o4 = e3.translate(i3 ? 100 : s2.stackTotal, false, true, false, true), r3 = e3.translate(t3.threshold || 0, false, true, false, true), a2 = this.crispCol(0, Math.min(o4, r3), 0, Math.abs(o4 - r3));
24718                  p2 = a2.y, u12 = a2.height;
24719                }
24720                let g2 = (s2.negative ? -1 : 1) * (l2 ? -1 : 1) == -1, f2 = r2.where;
24721                !f2 && this.is("waterfall") && Math.abs((s2.yBottom || 0) - (this.translatedThreshold || 0)) > this.borderWidth && (f2 = "all"), f2 || (f2 = "end");
24722                let m2 = Math.min(h(r2.radius, n2), n2 / 2, "all" === f2 ? d2 / 2 : 1 / 0) || 0;
24723                "end" === f2 && (g2 && (p2 -= m2), u12 += m2), a(o3, {
24724                  brBoxHeight: u12,
24725                  brBoxY: p2,
24726                  r: m2
24727                });
24728              }
24729            }
24730          }
24731        }
24732        function f(t3, e3) {
24733          return n(t3) || (t3 = {
24734            radius: t3 || 0
24735          }), l(d, e3, t3);
24736        }
24737        function m() {
24738          let t3 = f(this.options.borderRadius);
24739          for (let e3 of this.points) {
24740            let i3 = e3.shapeArgs;
24741            i3 && (i3.borderRadius = h(t3.radius, (i3.r || 0) - (i3.innerR || 0)));
24742          }
24743        }
24744        function x(t3, e3, i3, s2, o2 = {}) {
24745          let r2 = p(t3, e3, i3, s2, o2), {
24746            r: a2 = 0,
24747            brBoxHeight: n2 = s2,
24748            brBoxY: l2 = e3
24749          } = o2, h2 = e3 - l2, d2 = l2 + n2 - (e3 + s2), c2 = h2 - a2 > -0.1 ? 0 : a2, u12 = d2 - a2 > -0.1 ? 0 : a2, g2 = Math.max(c2 && h2, 0), f2 = Math.max(u12 && d2, 0), m2 = [t3 + c2, e3], y = [t3 + i3 - c2, e3], b = [t3 + i3, e3 + c2], v = [t3 + i3, e3 + s2 - u12], S2 = [t3 + i3 - u12, e3 + s2], k = [t3 + u12, e3 + s2], M = [t3, e3 + s2 - u12], C = [t3, e3 + c2], A = (t4, e4) => Math.sqrt(Math.pow(t4, 2) - Math.pow(e4, 2));
24750          if (g2) {
24751            let t4 = A(c2, c2 - g2);
24752            m2[0] -= t4, y[0] += t4, b[1] = C[1] = e3 + c2 - g2;
24753          }
24754          if (s2 < c2 - g2) {
24755            let o3 = A(c2, c2 - g2 - s2);
24756            b[0] = v[0] = t3 + i3 - c2 + o3, S2[0] = Math.min(b[0], S2[0]), k[0] = Math.max(v[0], k[0]), M[0] = C[0] = t3 + c2 - o3, b[1] = C[1] = e3 + s2;
24757          }
24758          if (f2) {
24759            let t4 = A(u12, u12 - f2);
24760            S2[0] += t4, k[0] -= t4, v[1] = M[1] = e3 + s2 - u12 + f2;
24761          }
24762          if (s2 < u12 - f2) {
24763            let o3 = A(u12, u12 - f2 - s2);
24764            b[0] = v[0] = t3 + i3 - u12 + o3, y[0] = Math.min(b[0], y[0]), m2[0] = Math.max(v[0], m2[0]), M[0] = C[0] = t3 + u12 - o3, v[1] = M[1] = e3;
24765          }
24766          return r2.length = 0, r2.push(["M", ...m2], ["L", ...y], ["A", c2, c2, 0, 0, 1, ...b], ["L", ...v], ["A", u12, u12, 0, 0, 1, ...S2], ["L", ...k], ["A", u12, u12, 0, 0, 1, ...M], ["L", ...C], ["A", c2, c2, 0, 0, 1, ...m2], ["Z"]), r2;
24767        }
24768        return {
24769          compose: function(t3, e3, i3) {
24770            let s2 = t3.types.pie;
24771            if (!e3.symbolCustomAttribs.includes("borderRadius")) {
24772              let o2 = i3.prototype.symbols;
24773              r(t3, "afterColumnTranslate", g, {
24774                order: 9
24775              }), r(s2, "afterTranslate", m), e3.symbolCustomAttribs.push("borderRadius", "brBoxHeight", "brBoxY"), c = o2.arc, p = o2.roundedRect, o2.arc = u11, o2.roundedRect = x;
24776            }
24777          },
24778          optionsToObject: f
24779        };
24780      }), i(e, "Core/Responsive.js", [e["Core/Utilities.js"]], function(t2) {
24781        var e2;
24782        let {
24783          diffObjects: i2,
24784          extend: s,
24785          find: o,
24786          merge: r,
24787          pick: a,
24788          uniqueKey: n
24789        } = t2;
24790        return function(t3) {
24791          function e3(t4, e4) {
24792            let i3 = t4.condition;
24793            (i3.callback || function() {
24794              return this.chartWidth <= a(i3.maxWidth, Number.MAX_VALUE) && this.chartHeight <= a(i3.maxHeight, Number.MAX_VALUE) && this.chartWidth >= a(i3.minWidth, 0) && this.chartHeight >= a(i3.minHeight, 0);
24795            }).call(this) && e4.push(t4._id);
24796          }
24797          function l(t4, e4) {
24798            let s2 = this.options.responsive, a2 = this.currentResponsive, l2 = [], h;
24799            !e4 && s2 && s2.rules && s2.rules.forEach((t5) => {
24800              void 0 === t5._id && (t5._id = n()), this.matchResponsiveRule(t5, l2);
24801            }, this);
24802            let d = r(...l2.map((t5) => o((s2 || {}).rules || [], (e5) => e5._id === t5)).map((t5) => t5 && t5.chartOptions));
24803            d.isResponsiveOptions = true, l2 = l2.toString() || void 0;
24804            let c = a2 && a2.ruleIds;
24805            l2 === c || (a2 && (this.currentResponsive = void 0, this.updatingResponsive = true, this.update(a2.undoOptions, t4, true), this.updatingResponsive = false), l2 ? ((h = i2(d, this.options, true, this.collectionsWithUpdate)).isResponsiveOptions = true, this.currentResponsive = {
24806              ruleIds: l2,
24807              mergedOptions: d,
24808              undoOptions: h
24809            }, this.updatingResponsive || this.update(d, t4, true)) : this.currentResponsive = void 0);
24810          }
24811          t3.compose = function(t4) {
24812            let i3 = t4.prototype;
24813            return i3.matchResponsiveRule || s(i3, {
24814              matchResponsiveRule: e3,
24815              setResponsive: l
24816            }), t4;
24817          };
24818        }(e2 || (e2 = {})), e2;
24819      }), i(e, "masters/highcharts.src.js", [e["Core/Globals.js"], e["Core/Utilities.js"], e["Core/Defaults.js"], e["Core/Animation/Fx.js"], e["Core/Animation/AnimationUtilities.js"], e["Core/Renderer/HTML/AST.js"], e["Core/Templating.js"], e["Core/Renderer/RendererRegistry.js"], e["Core/Renderer/RendererUtilities.js"], e["Core/Renderer/SVG/SVGElement.js"], e["Core/Renderer/SVG/SVGRenderer.js"], e["Core/Renderer/HTML/HTMLElement.js"], e["Core/Axis/Axis.js"], e["Core/Axis/DateTimeAxis.js"], e["Core/Axis/LogarithmicAxis.js"], e["Core/Axis/PlotLineOrBand/PlotLineOrBand.js"], e["Core/Axis/Tick.js"], e["Core/Tooltip.js"], e["Core/Series/Point.js"], e["Core/Pointer.js"], e["Core/Legend/Legend.js"], e["Core/Legend/LegendSymbol.js"], e["Core/Chart/Chart.js"], e["Extensions/ScrollablePlotArea.js"], e["Core/Axis/Stacking/StackingAxis.js"], e["Core/Axis/Stacking/StackItem.js"], e["Core/Series/Series.js"], e["Core/Series/SeriesRegistry.js"], e["Series/Column/ColumnDataLabel.js"], e["Series/Pie/PieDataLabel.js"], e["Core/Series/DataLabel.js"], e["Extensions/OverlappingDataLabels.js"], e["Extensions/BorderRadius.js"], e["Core/Responsive.js"], e["Core/Color/Color.js"], e["Core/Time.js"]], function(t2, e2, i2, s, o, r, a, n, l, h, d, c, p, u11, g, f, m, x, y, b, v, S2, k, M, C, A, w, T2, P, O, L, D2, E, B, j, R) {
24820        return t2.AST = r, t2.Axis = p, t2.Chart = k, t2.Color = j, t2.DataLabel = L, t2.Fx = s, t2.HTMLElement = c, t2.Legend = v, t2.LegendSymbol = S2, t2.OverlappingDataLabels = t2.OverlappingDataLabels || D2, t2.PlotLineOrBand = f, t2.Point = y, t2.Pointer = b, t2.RendererRegistry = n, t2.Series = w, t2.SeriesRegistry = T2, t2.StackItem = A, t2.SVGElement = h, t2.SVGRenderer = d, t2.Templating = a, t2.Tick = m, t2.Time = R, t2.Tooltip = x, t2.animate = o.animate, t2.animObject = o.animObject, t2.chart = k.chart, t2.color = j.parse, t2.dateFormat = a.dateFormat, t2.defaultOptions = i2.defaultOptions, t2.distribute = l.distribute, t2.format = a.format, t2.getDeferredAnimation = o.getDeferredAnimation, t2.getOptions = i2.getOptions, t2.numberFormat = a.numberFormat, t2.seriesType = T2.seriesType, t2.setAnimation = o.setAnimation, t2.setOptions = i2.setOptions, t2.stop = o.stop, t2.time = i2.defaultTime, t2.timers = s.timers, E.compose(t2.Series, t2.SVGElement, t2.SVGRenderer), P.compose(t2.Series.types.column), L.compose(t2.Series), u11.compose(t2.Axis), c.compose(t2.SVGRenderer), v.compose(t2.Chart), g.compose(t2.Axis), D2.compose(t2.Chart), O.compose(t2.Series.types.pie), f.compose(t2.Chart, t2.Axis), b.compose(t2.Chart), B.compose(t2.Chart), M.compose(t2.Axis, t2.Chart, t2.Series), C.compose(t2.Axis, t2.Chart, t2.Series), x.compose(t2.Pointer), e2.extend(t2, e2), t2;
24821      }), i(e, "Series/DataModifyComposition.js", [e["Core/Axis/Axis.js"], e["Core/Series/Point.js"], e["Core/Series/Series.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
24822        var o;
24823        let {
24824          tooltipFormatter: r
24825        } = e2.prototype, {
24826          addEvent: a,
24827          arrayMax: n,
24828          arrayMin: l,
24829          correctFloat: h,
24830          defined: d,
24831          isArray: c,
24832          isNumber: p,
24833          isString: u11,
24834          pick: g
24835        } = s;
24836        return function(t3) {
24837          function e3(t4, e4, i4) {
24838            !this.isXAxis && (this.series.forEach(function(i5) {
24839              "compare" === t4 && "boolean" != typeof e4 ? i5.setCompare(e4, false) : "cumulative" !== t4 || u11(e4) || i5.setCumulative(e4, false);
24840            }), g(i4, true) && this.chart.redraw());
24841          }
24842          function i3(t4) {
24843            let e4 = this, {
24844              numberFormatter: i4
24845            } = e4.series.chart, s3 = function(s4) {
24846              t4 = t4.replace("{point." + s4 + "}", (e4[s4] > 0 && "change" === s4 ? "+" : "") + i4(e4[s4], g(e4.series.tooltipOptions.changeDecimals, 2)));
24847            };
24848            return d(e4.change) && s3("change"), d(e4.cumulativeSum) && s3("cumulativeSum"), r.apply(this, [t4]);
24849          }
24850          function s2() {
24851            let t4;
24852            let e4 = this.options.compare;
24853            ("percent" === e4 || "value" === e4 || this.options.cumulative) && (t4 = new v(this), "percent" === e4 || "value" === e4 ? t4.initCompare(e4) : t4.initCumulative()), this.dataModify = t4;
24854          }
24855          function o2(t4) {
24856            let e4 = t4.dataExtremes, i4 = e4.activeYData;
24857            if (this.dataModify && e4) {
24858              let t5;
24859              this.options.compare ? t5 = [this.dataModify.modifyValue(e4.dataMin), this.dataModify.modifyValue(e4.dataMax)] : this.options.cumulative && c(i4) && i4.length >= 2 && (t5 = v.getCumulativeExtremes(i4)), t5 && (e4.dataMin = l(t5), e4.dataMax = n(t5));
24860            }
24861          }
24862          function f(t4, e4) {
24863            this.options.compare = this.userOptions.compare = t4, this.update({}, g(e4, true)), this.dataModify && ("value" === t4 || "percent" === t4) ? this.dataModify.initCompare(t4) : this.points.forEach((t5) => {
24864              delete t5.change;
24865            });
24866          }
24867          function m() {
24868            if (this.xAxis && this.processedYData && this.dataModify) {
24869              let t4 = this.processedXData, e4 = this.processedYData, i4 = e4.length, s3 = true === this.options.compareStart ? 0 : 1, o3 = -1, r2;
24870              for (this.pointArrayMap && (o3 = this.pointArrayMap.indexOf(this.options.pointValKey || this.pointValKey || "y")), r2 = 0; r2 < i4 - s3; r2++) {
24871                let i5 = e4[r2] && o3 > -1 ? e4[r2][o3] : e4[r2];
24872                if (p(i5) && 0 !== i5 && t4[r2 + s3] >= (this.xAxis.min || 0)) {
24873                  this.dataModify.compareValue = i5;
24874                  break;
24875                }
24876              }
24877            }
24878          }
24879          function x(t4, e4) {
24880            this.setModifier("compare", t4, e4);
24881          }
24882          function y(t4, e4) {
24883            t4 = g(t4, false), this.options.cumulative = this.userOptions.cumulative = t4, this.update({}, g(e4, true)), this.dataModify ? this.dataModify.initCumulative() : this.points.forEach((t5) => {
24884              delete t5.cumulativeSum;
24885            });
24886          }
24887          function b(t4, e4) {
24888            this.setModifier("cumulative", t4, e4);
24889          }
24890          t3.compose = function(t4, r2, n2) {
24891            let l2 = r2.prototype, h2 = n2.prototype, d2 = t4.prototype;
24892            return d2.setCompare || (d2.setCompare = f, d2.setCumulative = y, a(t4, "afterInit", s2), a(t4, "afterGetExtremes", o2), a(t4, "afterProcessData", m)), l2.setCompare || (l2.setCompare = x, l2.setModifier = e3, l2.setCumulative = b, h2.tooltipFormatter = i3), t4;
24893          };
24894          class v {
24895            constructor(t4) {
24896              this.series = t4;
24897            }
24898            modifyValue() {
24899              return 0;
24900            }
24901            static getCumulativeExtremes(t4) {
24902              let e4 = 1 / 0, i4 = -1 / 0;
24903              return t4.reduce((t5, s3) => {
24904                let o3 = t5 + s3;
24905                return e4 = Math.min(e4, o3, t5), i4 = Math.max(i4, o3, t5), o3;
24906              }), [e4, i4];
24907            }
24908            initCompare(t4) {
24909              this.modifyValue = function(e4, i4) {
24910                null === e4 && (e4 = 0);
24911                let s3 = this.compareValue;
24912                if (void 0 !== e4 && void 0 !== s3) {
24913                  if ("value" === t4 ? e4 -= s3 : e4 = e4 / s3 * 100 - (100 === this.series.options.compareBase ? 0 : 100), void 0 !== i4) {
24914                    let t5 = this.series.points[i4];
24915                    t5 && (t5.change = e4);
24916                  }
24917                  return e4;
24918                }
24919                return 0;
24920              };
24921            }
24922            initCumulative() {
24923              this.modifyValue = function(t4, e4) {
24924                if (null === t4 && (t4 = 0), void 0 !== t4 && void 0 !== e4) {
24925                  let i4 = e4 > 0 ? this.series.points[e4 - 1] : null;
24926                  i4 && i4.cumulativeSum && (t4 = h(i4.cumulativeSum + t4));
24927                  let s3 = this.series.points[e4], o3 = s3.series.options.cumulativeStart, r2 = s3.x <= this.series.xAxis.max && s3.x >= this.series.xAxis.min;
24928                  return s3 && (!o3 || r2 ? s3.cumulativeSum = t4 : s3.cumulativeSum = void 0), t4;
24929                }
24930                return 0;
24931              };
24932            }
24933          }
24934          t3.Additions = v;
24935        }(o || (o = {})), o;
24936      }), i(e, "Stock/Navigator/ChartNavigatorComposition.js", [e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2) {
24937        let i2;
24938        let {
24939          isTouchDevice: s
24940        } = t2, {
24941          addEvent: o,
24942          merge: r,
24943          pick: a
24944        } = e2, n = [];
24945        function l() {
24946          this.navigator && this.navigator.setBaseSeries(null, false);
24947        }
24948        function h() {
24949          let t3, e3, i3;
24950          let s2 = this.legend, o2 = this.navigator;
24951          if (o2) {
24952            t3 = s2 && s2.options, e3 = o2.xAxis, i3 = o2.yAxis;
24953            let {
24954              scrollbarHeight: r2,
24955              scrollButtonSize: n2
24956            } = o2;
24957            this.inverted ? (o2.left = o2.opposite ? this.chartWidth - r2 - o2.height : this.spacing[3] + r2, o2.top = this.plotTop + n2) : (o2.left = a(e3.left, this.plotLeft + n2), o2.top = o2.navigatorOptions.top || this.chartHeight - o2.height - r2 - (this.scrollbar?.options.margin || 0) - this.spacing[2] - (this.rangeSelector && this.extraBottomMargin ? this.rangeSelector.getHeight() : 0) - (t3 && "bottom" === t3.verticalAlign && "proximate" !== t3.layout && t3.enabled && !t3.floating ? s2.legendHeight + a(t3.margin, 10) : 0) - (this.titleOffset ? this.titleOffset[2] : 0)), e3 && i3 && (this.inverted ? e3.options.left = i3.options.left = o2.left : e3.options.top = i3.options.top = o2.top, e3.setAxisSize(), i3.setAxisSize());
24958          }
24959        }
24960        function d(t3) {
24961          !this.navigator && !this.scroller && (this.options.navigator.enabled || this.options.scrollbar.enabled) && (this.scroller = this.navigator = new i2(this), a(t3.redraw, true) && this.redraw(t3.animation));
24962        }
24963        function c() {
24964          let t3 = this.options;
24965          (t3.navigator.enabled || t3.scrollbar.enabled) && (this.scroller = this.navigator = new i2(this));
24966        }
24967        function p() {
24968          let t3 = this.options, e3 = t3.navigator, i3 = t3.rangeSelector;
24969          if ((e3 && e3.enabled || i3 && i3.enabled) && (!s && "x" === this.zooming.type || s && "x" === this.zooming.pinchType)) return false;
24970        }
24971        function u11(t3) {
24972          let e3 = t3.navigator;
24973          if (e3 && t3.xAxis[0]) {
24974            let i3 = t3.xAxis[0].getExtremes();
24975            e3.render(i3.min, i3.max);
24976          }
24977        }
24978        function g(t3) {
24979          let e3 = t3.options.navigator || {}, i3 = t3.options.scrollbar || {};
24980          !this.navigator && !this.scroller && (e3.enabled || i3.enabled) && (r(true, this.options.navigator, e3), r(true, this.options.scrollbar, i3), delete t3.options.navigator, delete t3.options.scrollbar);
24981        }
24982        return {
24983          compose: function(t3, s2) {
24984            if (e2.pushUnique(n, t3)) {
24985              let e3 = t3.prototype;
24986              i2 = s2, e3.callbacks.push(u11), o(t3, "afterAddSeries", l), o(t3, "afterSetChartSize", h), o(t3, "afterUpdate", d), o(t3, "beforeRender", c), o(t3, "beforeShowResetZoom", p), o(t3, "update", g);
24987            }
24988          }
24989        };
24990      }), i(e, "Core/Axis/NavigatorAxisComposition.js", [e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2) {
24991        let {
24992          isTouchDevice: i2
24993        } = t2, {
24994          addEvent: s,
24995          correctFloat: o,
24996          defined: r,
24997          isNumber: a,
24998          pick: n
24999        } = e2;
25000        function l() {
25001          this.navigatorAxis || (this.navigatorAxis = new d(this));
25002        }
25003        function h(t3) {
25004          let e3;
25005          let s2 = this.chart, o2 = s2.options, a2 = o2.navigator, n2 = this.navigatorAxis, l2 = s2.zooming.pinchType, h2 = o2.rangeSelector, d2 = s2.zooming.type;
25006          if (this.isXAxis && (a2?.enabled || h2?.enabled)) {
25007            if ("y" === d2 && "zoom" === t3.trigger) e3 = false;
25008            else if (("zoom" === t3.trigger && "xy" === d2 || i2 && "xy" === l2) && this.options.range) {
25009              let e4 = n2.previousZoom;
25010              r(t3.min) ? n2.previousZoom = [this.min, this.max] : e4 && (t3.min = e4[0], t3.max = e4[1], n2.previousZoom = void 0);
25011            }
25012          }
25013          void 0 !== e3 && t3.preventDefault();
25014        }
25015        class d {
25016          static compose(t3) {
25017            t3.keepProps.includes("navigatorAxis") || (t3.keepProps.push("navigatorAxis"), s(t3, "init", l), s(t3, "setExtremes", h));
25018          }
25019          constructor(t3) {
25020            this.axis = t3;
25021          }
25022          destroy() {
25023            this.axis = void 0;
25024          }
25025          toFixedRange(t3, e3, i3, s2) {
25026            let l2 = this.axis, h2 = (l2.pointRange || 0) / 2, d2 = n(i3, l2.translate(t3, true, !l2.horiz)), c = n(s2, l2.translate(e3, true, !l2.horiz));
25027            return r(i3) || (d2 = o(d2 + h2)), r(s2) || (c = o(c - h2)), a(d2) && a(c) || (d2 = c = void 0), {
25028              min: d2,
25029              max: c
25030            };
25031          }
25032        }
25033        return d;
25034      }), i(e, "Stock/Navigator/NavigatorDefaults.js", [e["Core/Color/Color.js"], e["Core/Series/SeriesRegistry.js"]], function(t2, e2) {
25035        let {
25036          parse: i2
25037        } = t2, {
25038          seriesTypes: s
25039        } = e2;
25040        return {
25041          height: 40,
25042          margin: 25,
25043          maskInside: true,
25044          handles: {
25045            width: 7,
25046            borderRadius: 0,
25047            height: 15,
25048            symbols: ["navigator-handle", "navigator-handle"],
25049            enabled: true,
25050            lineWidth: 1,
25051            backgroundColor: "#f2f2f2",
25052            borderColor: "#999999"
25053          },
25054          maskFill: i2("#667aff").setOpacity(0.3).get(),
25055          outlineColor: "#999999",
25056          outlineWidth: 1,
25057          series: {
25058            type: void 0 === s.areaspline ? "line" : "areaspline",
25059            fillOpacity: 0.05,
25060            lineWidth: 1,
25061            compare: null,
25062            sonification: {
25063              enabled: false
25064            },
25065            dataGrouping: {
25066              approximation: "average",
25067              enabled: true,
25068              groupPixelWidth: 2,
25069              firstAnchor: "firstPoint",
25070              anchor: "middle",
25071              lastAnchor: "lastPoint",
25072              units: [["millisecond", [1, 2, 5, 10, 20, 25, 50, 100, 200, 500]], ["second", [1, 2, 5, 10, 15, 30]], ["minute", [1, 2, 5, 10, 15, 30]], ["hour", [1, 2, 3, 4, 6, 8, 12]], ["day", [1, 2, 3, 4]], ["week", [1, 2, 3]], ["month", [1, 3, 6]], ["year", null]]
25073            },
25074            dataLabels: {
25075              enabled: false,
25076              zIndex: 2
25077            },
25078            id: "highcharts-navigator-series",
25079            className: "highcharts-navigator-series",
25080            lineColor: null,
25081            marker: {
25082              enabled: false
25083            },
25084            threshold: null
25085          },
25086          xAxis: {
25087            className: "highcharts-navigator-xaxis",
25088            tickLength: 0,
25089            lineWidth: 0,
25090            gridLineColor: "#e6e6e6",
25091            id: "navigator-x-axis",
25092            gridLineWidth: 1,
25093            tickPixelInterval: 200,
25094            labels: {
25095              align: "left",
25096              style: {
25097                color: "#000000",
25098                fontSize: "0.7em",
25099                opacity: 0.6,
25100                textOutline: "2px contrast"
25101              },
25102              x: 3,
25103              y: -4
25104            },
25105            crosshair: false
25106          },
25107          yAxis: {
25108            className: "highcharts-navigator-yaxis",
25109            gridLineWidth: 0,
25110            startOnTick: false,
25111            endOnTick: false,
25112            minPadding: 0.1,
25113            id: "navigator-y-axis",
25114            maxPadding: 0.1,
25115            labels: {
25116              enabled: false
25117            },
25118            crosshair: false,
25119            title: {
25120              text: null
25121            },
25122            tickLength: 0,
25123            tickWidth: 0
25124          }
25125        };
25126      }), i(e, "Stock/Navigator/NavigatorSymbols.js", [e["Core/Renderer/SVG/Symbols.js"], e["Core/Utilities.js"]], function(t2, e2) {
25127        let {
25128          relativeLength: i2
25129        } = e2;
25130        return {
25131          "navigator-handle": function(e3, s, o, r, a = {}) {
25132            let n = a.width ? a.width / 2 : o, l = i2(a.borderRadius || 0, Math.min(2 * n, r));
25133            return [["M", -1.5, (r = a.height || r) / 2 - 3.5], ["L", -1.5, r / 2 + 4.5], ["M", 0.5, r / 2 - 3.5], ["L", 0.5, r / 2 + 4.5], ...t2.rect(-n - 1, 0.5, 2 * n + 1, r, {
25134              r: l
25135            })];
25136          }
25137        };
25138      }), i(e, "Stock/Utilities/StockUtilities.js", [e["Core/Utilities.js"]], function(t2) {
25139        let {
25140          defined: e2
25141        } = t2;
25142        return {
25143          setFixedRange: function(t3) {
25144            let i2 = this.xAxis[0];
25145            e2(i2.dataMax) && e2(i2.dataMin) && t3 ? this.fixedRange = Math.min(t3, i2.dataMax - i2.dataMin) : this.fixedRange = t3;
25146          }
25147        };
25148      }), i(e, "Stock/Navigator/NavigatorComposition.js", [e["Core/Defaults.js"], e["Core/Globals.js"], e["Core/Axis/NavigatorAxisComposition.js"], e["Stock/Navigator/NavigatorDefaults.js"], e["Stock/Navigator/NavigatorSymbols.js"], e["Core/Renderer/RendererRegistry.js"], e["Stock/Utilities/StockUtilities.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o, r, a, n) {
25149        let {
25150          setOptions: l
25151        } = t2, {
25152          composed: h
25153        } = e2, {
25154          getRendererType: d
25155        } = r, {
25156          setFixedRange: c
25157        } = a, {
25158          addEvent: p,
25159          extend: u11,
25160          pushUnique: g
25161        } = n;
25162        function f() {
25163          this.chart.navigator && !this.options.isInternal && this.chart.navigator.setBaseSeries(null, false);
25164        }
25165        return {
25166          compose: function(t3, e3, r2) {
25167            i2.compose(e3), g(h, "Navigator") && (t3.prototype.setFixedRange = c, u11(d().prototype.symbols, o), p(r2, "afterUpdate", f), l({
25168              navigator: s
25169            }));
25170          }
25171        };
25172      }), i(e, "Core/Axis/ScrollbarAxis.js", [e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2) {
25173        var i2;
25174        let {
25175          composed: s
25176        } = t2, {
25177          addEvent: o,
25178          defined: r,
25179          pick: a,
25180          pushUnique: n
25181        } = e2;
25182        return function(t3) {
25183          let e3;
25184          function i3(t4) {
25185            let e4 = a(t4.options && t4.options.min, t4.min), i4 = a(t4.options && t4.options.max, t4.max);
25186            return {
25187              axisMin: e4,
25188              axisMax: i4,
25189              scrollMin: r(t4.dataMin) ? Math.min(e4, t4.min, t4.dataMin, a(t4.threshold, 1 / 0)) : e4,
25190              scrollMax: r(t4.dataMax) ? Math.max(i4, t4.max, t4.dataMax, a(t4.threshold, -1 / 0)) : i4
25191            };
25192          }
25193          function l() {
25194            let t4 = this.scrollbar, e4 = t4 && !t4.options.opposite, i4 = this.horiz ? 2 : e4 ? 3 : 1;
25195            t4 && (this.chart.scrollbarsOffsets = [0, 0], this.chart.axisOffset[i4] += t4.size + (t4.options.margin || 0));
25196          }
25197          function h() {
25198            let t4 = this;
25199            t4.options && t4.options.scrollbar && t4.options.scrollbar.enabled && (t4.options.scrollbar.vertical = !t4.horiz, t4.options.startOnTick = t4.options.endOnTick = false, t4.scrollbar = new e3(t4.chart.renderer, t4.options.scrollbar, t4.chart), o(t4.scrollbar, "changed", function(e4) {
25200              let s2, o2;
25201              let {
25202                axisMin: a2,
25203                axisMax: n2,
25204                scrollMin: l2,
25205                scrollMax: h2
25206              } = i3(t4), d2 = h2 - l2;
25207              if (r(a2) && r(n2)) {
25208                if (t4.horiz && !t4.reversed || !t4.horiz && t4.reversed ? (s2 = l2 + d2 * this.to, o2 = l2 + d2 * this.from) : (s2 = l2 + d2 * (1 - this.from), o2 = l2 + d2 * (1 - this.to)), this.shouldUpdateExtremes(e4.DOMType)) {
25209                  let i4 = "mousemove" !== e4.DOMType && "touchmove" !== e4.DOMType && void 0;
25210                  t4.setExtremes(o2, s2, true, i4, e4);
25211                } else this.setRange(this.from, this.to);
25212              }
25213            }));
25214          }
25215          function d() {
25216            let t4, e4, s2;
25217            let {
25218              scrollMin: o2,
25219              scrollMax: a2
25220            } = i3(this), n2 = this.scrollbar, l2 = this.axisTitleMargin + (this.titleOffset || 0), h2 = this.chart.scrollbarsOffsets, d2 = this.options.margin || 0;
25221            if (n2 && h2) {
25222              if (this.horiz) this.opposite || (h2[1] += l2), n2.position(this.left, this.top + this.height + 2 + h2[1] - (this.opposite ? d2 : 0), this.width, this.height), this.opposite || (h2[1] += d2), t4 = 1;
25223              else {
25224                let e5;
25225                this.opposite && (h2[0] += l2), e5 = n2.options.opposite ? this.left + this.width + 2 + h2[0] - (this.opposite ? 0 : d2) : this.opposite ? 0 : d2, n2.position(e5, this.top, this.width, this.height), this.opposite && (h2[0] += d2), t4 = 0;
25226              }
25227              if (h2[t4] += n2.size + (n2.options.margin || 0), isNaN(o2) || isNaN(a2) || !r(this.min) || !r(this.max) || this.dataMin === this.dataMax) n2.setRange(0, 1);
25228              else if (this.min === this.max) {
25229                let t5 = this.pointRange / (this.dataMax + 1);
25230                e4 = t5 * this.min, s2 = t5 * (this.max + 1), n2.setRange(e4, s2);
25231              } else e4 = (this.min - o2) / (a2 - o2), s2 = (this.max - o2) / (a2 - o2), this.horiz && !this.reversed || !this.horiz && this.reversed ? n2.setRange(e4, s2) : n2.setRange(1 - s2, 1 - e4);
25232            }
25233          }
25234          t3.compose = function(t4, i4) {
25235            n(s, "Axis.Scrollbar") && (e3 = i4, o(t4, "afterGetOffset", l), o(t4, "afterInit", h), o(t4, "afterRender", d));
25236          };
25237        }(i2 || (i2 = {})), i2;
25238      }), i(e, "Stock/Scrollbar/ScrollbarDefaults.js", [], function() {
25239        return {
25240          height: 10,
25241          barBorderRadius: 5,
25242          buttonBorderRadius: 0,
25243          buttonsEnabled: false,
25244          liveRedraw: void 0,
25245          margin: void 0,
25246          minWidth: 6,
25247          opposite: true,
25248          step: 0.2,
25249          zIndex: 3,
25250          barBackgroundColor: "#cccccc",
25251          barBorderWidth: 0,
25252          barBorderColor: "#cccccc",
25253          buttonArrowColor: "#333333",
25254          buttonBackgroundColor: "#e6e6e6",
25255          buttonBorderColor: "#cccccc",
25256          buttonBorderWidth: 1,
25257          rifleColor: "none",
25258          trackBackgroundColor: "rgba(255, 255, 255, 0.001)",
25259          trackBorderColor: "#cccccc",
25260          trackBorderRadius: 5,
25261          trackBorderWidth: 1
25262        };
25263      }), i(e, "Stock/Scrollbar/Scrollbar.js", [e["Core/Defaults.js"], e["Core/Globals.js"], e["Core/Axis/ScrollbarAxis.js"], e["Stock/Scrollbar/ScrollbarDefaults.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o) {
25264        let {
25265          defaultOptions: r
25266        } = t2, {
25267          addEvent: a,
25268          correctFloat: n,
25269          crisp: l,
25270          defined: h,
25271          destroyObjectProperties: d,
25272          fireEvent: c,
25273          merge: p,
25274          pick: u11,
25275          removeEvent: g
25276        } = o;
25277        class f {
25278          static compose(t3) {
25279            i2.compose(t3, f);
25280          }
25281          static swapXY(t3, e3) {
25282            return e3 && t3.forEach((t4) => {
25283              let e4;
25284              let i3 = t4.length;
25285              for (let s2 = 0; s2 < i3; s2 += 2) "number" == typeof (e4 = t4[s2 + 1]) && (t4[s2 + 1] = t4[s2 + 2], t4[s2 + 2] = e4);
25286            }), t3;
25287          }
25288          constructor(t3, e3, i3) {
25289            this._events = [], this.chartX = 0, this.chartY = 0, this.from = 0, this.scrollbarButtons = [], this.scrollbarLeft = 0, this.scrollbarStrokeWidth = 1, this.scrollbarTop = 0, this.size = 0, this.to = 0, this.trackBorderWidth = 1, this.x = 0, this.y = 0, this.init(t3, e3, i3);
25290          }
25291          addEvents() {
25292            let t3 = this.options.inverted ? [1, 0] : [0, 1], e3 = this.scrollbarButtons, i3 = this.scrollbarGroup.element, s2 = this.track.element, o2 = this.mouseDownHandler.bind(this), r2 = this.mouseMoveHandler.bind(this), n2 = this.mouseUpHandler.bind(this), l2 = [[e3[t3[0]].element, "click", this.buttonToMinClick.bind(this)], [e3[t3[1]].element, "click", this.buttonToMaxClick.bind(this)], [s2, "click", this.trackClick.bind(this)], [i3, "mousedown", o2], [i3.ownerDocument, "mousemove", r2], [i3.ownerDocument, "mouseup", n2], [i3, "touchstart", o2], [i3.ownerDocument, "touchmove", r2], [i3.ownerDocument, "touchend", n2]];
25293            l2.forEach(function(t4) {
25294              a.apply(null, t4);
25295            }), this._events = l2;
25296          }
25297          buttonToMaxClick(t3) {
25298            let e3 = (this.to - this.from) * u11(this.options.step, 0.2);
25299            this.updatePosition(this.from + e3, this.to + e3), c(this, "changed", {
25300              from: this.from,
25301              to: this.to,
25302              trigger: "scrollbar",
25303              DOMEvent: t3
25304            });
25305          }
25306          buttonToMinClick(t3) {
25307            let e3 = n(this.to - this.from) * u11(this.options.step, 0.2);
25308            this.updatePosition(n(this.from - e3), n(this.to - e3)), c(this, "changed", {
25309              from: this.from,
25310              to: this.to,
25311              trigger: "scrollbar",
25312              DOMEvent: t3
25313            });
25314          }
25315          cursorToScrollbarPosition(t3) {
25316            let e3 = this.options, i3 = e3.minWidth > this.calculatedWidth ? e3.minWidth : 0;
25317            return {
25318              chartX: (t3.chartX - this.x - this.xOffset) / (this.barWidth - i3),
25319              chartY: (t3.chartY - this.y - this.yOffset) / (this.barWidth - i3)
25320            };
25321          }
25322          destroy() {
25323            let t3 = this, e3 = t3.chart.scroller;
25324            t3.removeEvents(), ["track", "scrollbarRifles", "scrollbar", "scrollbarGroup", "group"].forEach(function(e4) {
25325              t3[e4] && t3[e4].destroy && (t3[e4] = t3[e4].destroy());
25326            }), e3 && t3 === e3.scrollbar && (e3.scrollbar = null, d(e3.scrollbarButtons));
25327          }
25328          drawScrollbarButton(t3) {
25329            let e3 = this.renderer, i3 = this.scrollbarButtons, s2 = this.options, o2 = this.size, r2 = e3.g().add(this.group);
25330            if (i3.push(r2), s2.buttonsEnabled) {
25331              let a2 = e3.rect().addClass("highcharts-scrollbar-button").add(r2);
25332              this.chart.styledMode || a2.attr({
25333                stroke: s2.buttonBorderColor,
25334                "stroke-width": s2.buttonBorderWidth,
25335                fill: s2.buttonBackgroundColor
25336              }), a2.attr(a2.crisp({
25337                x: -0.5,
25338                y: -0.5,
25339                width: o2,
25340                height: o2,
25341                r: s2.buttonBorderRadius
25342              }, a2.strokeWidth()));
25343              let n2 = e3.path(f.swapXY([["M", o2 / 2 + (t3 ? -1 : 1), o2 / 2 - 3], ["L", o2 / 2 + (t3 ? -1 : 1), o2 / 2 + 3], ["L", o2 / 2 + (t3 ? 2 : -2), o2 / 2]], s2.vertical)).addClass("highcharts-scrollbar-arrow").add(i3[t3]);
25344              this.chart.styledMode || n2.attr({
25345                fill: s2.buttonArrowColor
25346              });
25347            }
25348          }
25349          init(t3, e3, i3) {
25350            this.scrollbarButtons = [], this.renderer = t3, this.userOptions = e3, this.options = p(s, r.scrollbar, e3), this.options.margin = u11(this.options.margin, 10), this.chart = i3, this.size = u11(this.options.size, this.options.height), e3.enabled && (this.render(), this.addEvents());
25351          }
25352          mouseDownHandler(t3) {
25353            let e3 = this.chart.pointer?.normalize(t3) || t3, i3 = this.cursorToScrollbarPosition(e3);
25354            this.chartX = i3.chartX, this.chartY = i3.chartY, this.initPositions = [this.from, this.to], this.grabbedCenter = true;
25355          }
25356          mouseMoveHandler(t3) {
25357            let e3;
25358            let i3 = this.chart.pointer?.normalize(t3) || t3, s2 = this.options.vertical ? "chartY" : "chartX", o2 = this.initPositions || [];
25359            this.grabbedCenter && (!t3.touches || 0 !== t3.touches[0][s2]) && (e3 = this.cursorToScrollbarPosition(i3)[s2] - this[s2], this.hasDragged = true, this.updatePosition(o2[0] + e3, o2[1] + e3), this.hasDragged && c(this, "changed", {
25360              from: this.from,
25361              to: this.to,
25362              trigger: "scrollbar",
25363              DOMType: t3.type,
25364              DOMEvent: t3
25365            }));
25366          }
25367          mouseUpHandler(t3) {
25368            this.hasDragged && c(this, "changed", {
25369              from: this.from,
25370              to: this.to,
25371              trigger: "scrollbar",
25372              DOMType: t3.type,
25373              DOMEvent: t3
25374            }), this.grabbedCenter = this.hasDragged = this.chartX = this.chartY = null;
25375          }
25376          position(t3, e3, i3, s2) {
25377            let {
25378              buttonsEnabled: o2,
25379              margin: r2 = 0,
25380              vertical: a2
25381            } = this.options, n2 = this.rendered ? "animate" : "attr", l2 = s2, h2 = 0;
25382            this.group.show(), this.x = t3, this.y = e3 + this.trackBorderWidth, this.width = i3, this.height = s2, this.xOffset = l2, this.yOffset = h2, a2 ? (this.width = this.yOffset = i3 = h2 = this.size, this.xOffset = l2 = 0, this.yOffset = h2 = o2 ? this.size : 0, this.barWidth = s2 - (o2 ? 2 * i3 : 0), this.x = t3 += r2) : (this.height = s2 = this.size, this.xOffset = l2 = o2 ? this.size : 0, this.barWidth = i3 - (o2 ? 2 * s2 : 0), this.y = this.y + r2), this.group[n2]({
25383              translateX: t3,
25384              translateY: this.y
25385            }), this.track[n2]({
25386              width: i3,
25387              height: s2
25388            }), this.scrollbarButtons[1][n2]({
25389              translateX: a2 ? 0 : i3 - l2,
25390              translateY: a2 ? s2 - h2 : 0
25391            });
25392          }
25393          removeEvents() {
25394            this._events.forEach(function(t3) {
25395              g.apply(null, t3);
25396            }), this._events.length = 0;
25397          }
25398          render() {
25399            let t3 = this.renderer, e3 = this.options, i3 = this.size, s2 = this.chart.styledMode, o2 = t3.g("scrollbar").attr({
25400              zIndex: e3.zIndex
25401            }).hide().add();
25402            this.group = o2, this.track = t3.rect().addClass("highcharts-scrollbar-track").attr({
25403              r: e3.trackBorderRadius || 0,
25404              height: i3,
25405              width: i3
25406            }).add(o2), s2 || this.track.attr({
25407              fill: e3.trackBackgroundColor,
25408              stroke: e3.trackBorderColor,
25409              "stroke-width": e3.trackBorderWidth
25410            });
25411            let r2 = this.trackBorderWidth = this.track.strokeWidth();
25412            this.track.attr({
25413              x: -l(0, r2),
25414              y: -l(0, r2)
25415            }), this.scrollbarGroup = t3.g().add(o2), this.scrollbar = t3.rect().addClass("highcharts-scrollbar-thumb").attr({
25416              height: i3 - r2,
25417              width: i3 - r2,
25418              r: e3.barBorderRadius || 0
25419            }).add(this.scrollbarGroup), this.scrollbarRifles = t3.path(f.swapXY([["M", -3, i3 / 4], ["L", -3, 2 * i3 / 3], ["M", 0, i3 / 4], ["L", 0, 2 * i3 / 3], ["M", 3, i3 / 4], ["L", 3, 2 * i3 / 3]], e3.vertical)).addClass("highcharts-scrollbar-rifles").add(this.scrollbarGroup), s2 || (this.scrollbar.attr({
25420              fill: e3.barBackgroundColor,
25421              stroke: e3.barBorderColor,
25422              "stroke-width": e3.barBorderWidth
25423            }), this.scrollbarRifles.attr({
25424              stroke: e3.rifleColor,
25425              "stroke-width": 1
25426            })), this.scrollbarStrokeWidth = this.scrollbar.strokeWidth(), this.scrollbarGroup.translate(-l(0, this.scrollbarStrokeWidth), -l(0, this.scrollbarStrokeWidth)), this.drawScrollbarButton(0), this.drawScrollbarButton(1);
25427          }
25428          setRange(t3, e3) {
25429            let i3, s2;
25430            let o2 = this.options, r2 = o2.vertical, a2 = o2.minWidth, l2 = this.barWidth, d2 = !this.rendered || this.hasDragged || this.chart.navigator && this.chart.navigator.hasDragged ? "attr" : "animate";
25431            if (!h(l2)) return;
25432            let c2 = l2 * Math.min(e3, 1);
25433            i3 = Math.ceil(l2 * (t3 = Math.max(t3, 0))), this.calculatedWidth = s2 = n(c2 - i3), s2 < a2 && (i3 = (l2 - a2 + s2) * t3, s2 = a2);
25434            let p2 = Math.floor(i3 + this.xOffset + this.yOffset), u12 = s2 / 2 - 0.5;
25435            this.from = t3, this.to = e3, r2 ? (this.scrollbarGroup[d2]({
25436              translateY: p2
25437            }), this.scrollbar[d2]({
25438              height: s2
25439            }), this.scrollbarRifles[d2]({
25440              translateY: u12
25441            }), this.scrollbarTop = p2, this.scrollbarLeft = 0) : (this.scrollbarGroup[d2]({
25442              translateX: p2
25443            }), this.scrollbar[d2]({
25444              width: s2
25445            }), this.scrollbarRifles[d2]({
25446              translateX: u12
25447            }), this.scrollbarLeft = p2, this.scrollbarTop = 0), s2 <= 12 ? this.scrollbarRifles.hide() : this.scrollbarRifles.show(), false === o2.showFull && (t3 <= 0 && e3 >= 1 ? this.group.hide() : this.group.show()), this.rendered = true;
25448          }
25449          shouldUpdateExtremes(t3) {
25450            return u11(this.options.liveRedraw, e2.svg && !e2.isTouchDevice && !this.chart.boosted) || "mouseup" === t3 || "touchend" === t3 || !h(t3);
25451          }
25452          trackClick(t3) {
25453            let e3 = this.chart.pointer?.normalize(t3) || t3, i3 = this.to - this.from, s2 = this.y + this.scrollbarTop, o2 = this.x + this.scrollbarLeft;
25454            this.options.vertical && e3.chartY > s2 || !this.options.vertical && e3.chartX > o2 ? this.updatePosition(this.from + i3, this.to + i3) : this.updatePosition(this.from - i3, this.to - i3), c(this, "changed", {
25455              from: this.from,
25456              to: this.to,
25457              trigger: "scrollbar",
25458              DOMEvent: t3
25459            });
25460          }
25461          update(t3) {
25462            this.destroy(), this.init(this.chart.renderer, p(true, this.options, t3), this.chart);
25463          }
25464          updatePosition(t3, e3) {
25465            e3 > 1 && (t3 = n(1 - n(e3 - t3)), e3 = 1), t3 < 0 && (e3 = n(e3 - t3), t3 = 0), this.from = t3, this.to = e3;
25466          }
25467        }
25468        return f.defaultOptions = s, r.scrollbar = p(true, f.defaultOptions, r.scrollbar), f;
25469      }), i(e, "Stock/Navigator/Navigator.js", [e["Core/Axis/Axis.js"], e["Stock/Navigator/ChartNavigatorComposition.js"], e["Core/Defaults.js"], e["Core/Globals.js"], e["Core/Axis/NavigatorAxisComposition.js"], e["Stock/Navigator/NavigatorComposition.js"], e["Stock/Scrollbar/Scrollbar.js"], e["Core/Renderer/SVG/SVGRenderer.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o, r, a, n, l) {
25470        let {
25471          defaultOptions: h
25472        } = i2, {
25473          isTouchDevice: d
25474        } = s, {
25475          prototype: {
25476            symbols: c
25477          }
25478        } = n, {
25479          addEvent: p,
25480          clamp: u11,
25481          correctFloat: g,
25482          defined: f,
25483          destroyObjectProperties: m,
25484          erase: x,
25485          extend: y,
25486          find: b,
25487          fireEvent: v,
25488          isArray: S2,
25489          isNumber: k,
25490          merge: M,
25491          pick: C,
25492          removeEvent: A,
25493          splat: w
25494        } = l;
25495        function T2(t3, ...e3) {
25496          let i3 = [].filter.call(e3, k);
25497          if (i3.length) return Math[t3].apply(0, i3);
25498        }
25499        class P {
25500          static compose(t3, i3, s2) {
25501            e2.compose(t3, P), r.compose(t3, i3, s2);
25502          }
25503          constructor(t3) {
25504            this.isDirty = false, this.scrollbarHeight = 0, this.init(t3);
25505          }
25506          drawHandle(t3, e3, i3, s2) {
25507            let o2 = this.navigatorOptions.handles.height;
25508            this.handles[e3][s2](i3 ? {
25509              translateX: Math.round(this.left + this.height / 2),
25510              translateY: Math.round(this.top + parseInt(t3, 10) + 0.5 - o2)
25511            } : {
25512              translateX: Math.round(this.left + parseInt(t3, 10)),
25513              translateY: Math.round(this.top + this.height / 2 - o2 / 2 - 1)
25514            });
25515          }
25516          drawOutline(t3, e3, i3, s2) {
25517            let o2 = this.navigatorOptions.maskInside, r2 = this.outline.strokeWidth(), a2 = r2 / 2, n2 = r2 % 2 / 2, l2 = this.scrollButtonSize, h2 = this.size, d2 = this.top, c2 = this.height, p2 = d2 - a2, u12 = d2 + c2, g2 = this.left, f2, m2;
25518            i3 ? (f2 = d2 + e3 + n2, e3 = d2 + t3 + n2, m2 = [["M", g2 + c2, d2 - l2 - n2], ["L", g2 + c2, f2], ["L", g2, f2], ["M", g2, e3], ["L", g2 + c2, e3], ["L", g2 + c2, d2 + h2 + l2]], o2 && m2.push(["M", g2 + c2, f2 - a2], ["L", g2 + c2, e3 + a2])) : (g2 -= l2, t3 += g2 + l2 - n2, e3 += g2 + l2 - n2, m2 = [["M", g2, p2], ["L", t3, p2], ["L", t3, u12], ["M", e3, u12], ["L", e3, p2], ["L", g2 + h2 + 2 * l2, p2]], o2 && m2.push(["M", t3 - a2, p2], ["L", e3 + a2, p2])), this.outline[s2]({
25519              d: m2
25520            });
25521          }
25522          drawMasks(t3, e3, i3, s2) {
25523            let o2, r2, a2, n2;
25524            let l2 = this.left, h2 = this.top, d2 = this.height;
25525            i3 ? (a2 = [l2, l2, l2], n2 = [h2, h2 + t3, h2 + e3], r2 = [d2, d2, d2], o2 = [t3, e3 - t3, this.size - e3]) : (a2 = [l2, l2 + t3, l2 + e3], n2 = [h2, h2, h2], r2 = [t3, e3 - t3, this.size - e3], o2 = [d2, d2, d2]), this.shades.forEach((t4, e4) => {
25526              t4[s2]({
25527                x: a2[e4],
25528                y: n2[e4],
25529                width: r2[e4],
25530                height: o2[e4]
25531              });
25532            });
25533          }
25534          renderElements() {
25535            let t3 = this, e3 = t3.navigatorOptions, i3 = e3.maskInside, s2 = t3.chart, o2 = s2.inverted, r2 = s2.renderer, a2 = {
25536              cursor: o2 ? "ns-resize" : "ew-resize"
25537            }, n2 = t3.navigatorGroup ?? (t3.navigatorGroup = r2.g("navigator").attr({
25538              zIndex: 8,
25539              visibility: "hidden"
25540            }).add());
25541            if ([!i3, i3, !i3].forEach((i4, o3) => {
25542              let l2 = t3.shades[o3] ?? (t3.shades[o3] = r2.rect().addClass("highcharts-navigator-mask" + (1 === o3 ? "-inside" : "-outside")).add(n2));
25543              s2.styledMode || (l2.attr({
25544                fill: i4 ? e3.maskFill : "rgba(0,0,0,0)"
25545              }), 1 === o3 && l2.css(a2));
25546            }), t3.outline || (t3.outline = r2.path().addClass("highcharts-navigator-outline").add(n2)), s2.styledMode || t3.outline.attr({
25547              "stroke-width": e3.outlineWidth,
25548              stroke: e3.outlineColor
25549            }), e3.handles?.enabled) {
25550              let i4 = e3.handles, {
25551                height: o3,
25552                width: l2
25553              } = i4;
25554              [0, 1].forEach((e4) => {
25555                let h2 = i4.symbols[e4];
25556                if (t3.handles[e4] && t3.handles[e4].symbolUrl === h2) {
25557                  if (!t3.handles[e4].isImg && t3.handles[e4].symbolName !== h2) {
25558                    let i5 = c[h2].call(c, -l2 / 2 - 1, 0, l2, o3);
25559                    t3.handles[e4].attr({
25560                      d: i5
25561                    }), t3.handles[e4].symbolName = h2;
25562                  }
25563                } else t3.handles[e4]?.destroy(), t3.handles[e4] = r2.symbol(h2, -l2 / 2 - 1, 0, l2, o3, i4), t3.handles[e4].attr({
25564                  zIndex: 7 - e4
25565                }).addClass("highcharts-navigator-handle highcharts-navigator-handle-" + ["left", "right"][e4]).add(n2), t3.addMouseEvents();
25566                s2.inverted && t3.handles[e4].attr({
25567                  rotation: 90,
25568                  rotationOriginX: Math.floor(-l2 / 2),
25569                  rotationOriginY: (o3 + l2) / 2
25570                }), s2.styledMode || t3.handles[e4].attr({
25571                  fill: i4.backgroundColor,
25572                  stroke: i4.borderColor,
25573                  "stroke-width": i4.lineWidth,
25574                  width: i4.width,
25575                  height: i4.height,
25576                  x: -l2 / 2 - 1,
25577                  y: 0
25578                }).css(a2);
25579              });
25580            }
25581          }
25582          update(t3, e3 = false) {
25583            let i3 = this.chart, s2 = i3.options.chart.inverted !== i3.scrollbar?.options.vertical;
25584            if (M(true, i3.options.navigator, t3), this.navigatorOptions = i3.options.navigator || {}, this.setOpposite(), f(t3.enabled) || s2) return this.destroy(), this.navigatorEnabled = t3.enabled || this.navigatorEnabled, this.init(i3);
25585            if (this.navigatorEnabled && (this.isDirty = true, false === t3.adaptToUpdatedData && this.baseSeries.forEach((t4) => {
25586              A(t4, "updatedData", this.updatedDataHandler);
25587            }, this), t3.adaptToUpdatedData && this.baseSeries.forEach((t4) => {
25588              t4.eventsToUnbind.push(p(t4, "updatedData", this.updatedDataHandler));
25589            }, this), (t3.series || t3.baseSeries) && this.setBaseSeries(void 0, false), t3.height || t3.xAxis || t3.yAxis)) {
25590              this.height = t3.height ?? this.height;
25591              let e4 = this.getXAxisOffsets();
25592              this.xAxis.update(__spreadProps(__spreadValues({}, t3.xAxis), {
25593                offsets: e4,
25594                [i3.inverted ? "width" : "height"]: this.height,
25595                [i3.inverted ? "height" : "width"]: void 0
25596              }), false), this.yAxis.update(__spreadProps(__spreadValues({}, t3.yAxis), {
25597                [i3.inverted ? "width" : "height"]: this.height
25598              }), false);
25599            }
25600            e3 && i3.redraw();
25601          }
25602          render(t3, e3, i3, s2) {
25603            let o2 = this.chart, r2 = this.xAxis, a2 = r2.pointRange || 0, n2 = r2.navigatorAxis.fake ? o2.xAxis[0] : r2, l2 = this.navigatorEnabled, h2 = this.rendered, d2 = o2.inverted, c2 = o2.xAxis[0].minRange, p2 = o2.xAxis[0].options.maxRange, m2 = this.scrollButtonSize, x2, y2, b2, S3 = this.scrollbarHeight, M2, A2;
25604            if (this.hasDragged && !f(i3)) return;
25605            if (this.isDirty && this.renderElements(), t3 = g(t3 - a2 / 2), e3 = g(e3 + a2 / 2), !k(t3) || !k(e3)) {
25606              if (!h2) return;
25607              i3 = 0, s2 = C(r2.width, n2.width);
25608            }
25609            this.left = C(r2.left, o2.plotLeft + m2 + (d2 ? o2.plotWidth : 0));
25610            let w2 = this.size = M2 = C(r2.len, (d2 ? o2.plotHeight : o2.plotWidth) - 2 * m2);
25611            x2 = d2 ? S3 : M2 + 2 * m2, i3 = C(i3, r2.toPixels(t3, true)), s2 = C(s2, r2.toPixels(e3, true)), k(i3) && Math.abs(i3) !== 1 / 0 || (i3 = 0, s2 = x2);
25612            let T3 = r2.toValue(i3, true), P2 = r2.toValue(s2, true), O = Math.abs(g(P2 - T3));
25613            O < c2 ? this.grabbedLeft ? i3 = r2.toPixels(P2 - c2 - a2, true) : this.grabbedRight && (s2 = r2.toPixels(T3 + c2 + a2, true)) : f(p2) && g(O - a2) > p2 && (this.grabbedLeft ? i3 = r2.toPixels(P2 - p2 - a2, true) : this.grabbedRight && (s2 = r2.toPixels(T3 + p2 + a2, true))), this.zoomedMax = u11(Math.max(i3, s2), 0, w2), this.zoomedMin = u11(this.fixedWidth ? this.zoomedMax - this.fixedWidth : Math.min(i3, s2), 0, w2), this.range = this.zoomedMax - this.zoomedMin, w2 = Math.round(this.zoomedMax);
25614            let L = Math.round(this.zoomedMin);
25615            l2 && (this.navigatorGroup.attr({
25616              visibility: "inherit"
25617            }), A2 = h2 && !this.hasDragged ? "animate" : "attr", this.drawMasks(L, w2, d2, A2), this.drawOutline(L, w2, d2, A2), this.navigatorOptions.handles.enabled && (this.drawHandle(L, 0, d2, A2), this.drawHandle(w2, 1, d2, A2))), this.scrollbar && (d2 ? (b2 = this.top - m2, y2 = this.left - S3 + (l2 || !n2.opposite ? 0 : (n2.titleOffset || 0) + n2.axisTitleMargin), S3 = M2 + 2 * m2) : (b2 = this.top + (l2 ? this.height : -S3), y2 = this.left - m2), this.scrollbar.position(y2, b2, x2, S3), this.scrollbar.setRange(this.zoomedMin / (M2 || 1), this.zoomedMax / (M2 || 1))), this.rendered = true, this.isDirty = false, v(this, "afterRender");
25618          }
25619          addMouseEvents() {
25620            let t3 = this, e3 = t3.chart, i3 = e3.container, s2 = [], o2, r2;
25621            t3.mouseMoveHandler = o2 = function(e4) {
25622              t3.onMouseMove(e4);
25623            }, t3.mouseUpHandler = r2 = function(e4) {
25624              t3.onMouseUp(e4);
25625            }, (s2 = t3.getPartsEvents("mousedown")).push(p(e3.renderTo, "mousemove", o2), p(i3.ownerDocument, "mouseup", r2), p(e3.renderTo, "touchmove", o2), p(i3.ownerDocument, "touchend", r2)), s2.concat(t3.getPartsEvents("touchstart")), t3.eventsToUnbind = s2, t3.series && t3.series[0] && s2.push(p(t3.series[0].xAxis, "foundExtremes", function() {
25626              e3.navigator.modifyNavigatorAxisExtremes();
25627            }));
25628          }
25629          getPartsEvents(t3) {
25630            let e3 = this, i3 = [];
25631            return ["shades", "handles"].forEach(function(s2) {
25632              e3[s2].forEach(function(o2, r2) {
25633                i3.push(p(o2.element, t3, function(t4) {
25634                  e3[s2 + "Mousedown"](t4, r2);
25635                }));
25636              });
25637            }), i3;
25638          }
25639          shadesMousedown(t3, e3) {
25640            t3 = this.chart.pointer?.normalize(t3) || t3;
25641            let i3 = this.chart, s2 = this.xAxis, o2 = this.zoomedMin, r2 = this.size, a2 = this.range, n2 = this.left, l2 = t3.chartX, h2, d2, c2, p2;
25642            i3.inverted && (l2 = t3.chartY, n2 = this.top), 1 === e3 ? (this.grabbedCenter = l2, this.fixedWidth = a2, this.dragOffset = l2 - o2) : (p2 = l2 - n2 - a2 / 2, 0 === e3 ? p2 = Math.max(0, p2) : 2 === e3 && p2 + a2 >= r2 && (p2 = r2 - a2, this.reversedExtremes ? (p2 -= a2, d2 = this.getUnionExtremes().dataMin) : h2 = this.getUnionExtremes().dataMax), p2 !== o2 && (this.fixedWidth = a2, f((c2 = s2.navigatorAxis.toFixedRange(p2, p2 + a2, d2, h2)).min) && v(this, "setRange", {
25643              min: Math.min(c2.min, c2.max),
25644              max: Math.max(c2.min, c2.max),
25645              redraw: true,
25646              eventArguments: {
25647                trigger: "navigator"
25648              }
25649            })));
25650          }
25651          handlesMousedown(t3, e3) {
25652            t3 = this.chart.pointer?.normalize(t3) || t3;
25653            let i3 = this.chart, s2 = i3.xAxis[0], o2 = this.reversedExtremes;
25654            0 === e3 ? (this.grabbedLeft = true, this.otherHandlePos = this.zoomedMax, this.fixedExtreme = o2 ? s2.min : s2.max) : (this.grabbedRight = true, this.otherHandlePos = this.zoomedMin, this.fixedExtreme = o2 ? s2.max : s2.min), i3.setFixedRange(void 0);
25655          }
25656          onMouseMove(t3) {
25657            let e3 = this, i3 = e3.chart, s2 = e3.navigatorSize, o2 = e3.range, r2 = e3.dragOffset, a2 = i3.inverted, n2 = e3.left, l2;
25658            (!t3.touches || 0 !== t3.touches[0].pageX) && (l2 = (t3 = i3.pointer?.normalize(t3) || t3).chartX, a2 && (n2 = e3.top, l2 = t3.chartY), e3.grabbedLeft ? (e3.hasDragged = true, e3.render(0, 0, l2 - n2, e3.otherHandlePos)) : e3.grabbedRight ? (e3.hasDragged = true, e3.render(0, 0, e3.otherHandlePos, l2 - n2)) : e3.grabbedCenter && (e3.hasDragged = true, l2 < r2 ? l2 = r2 : l2 > s2 + r2 - o2 && (l2 = s2 + r2 - o2), e3.render(0, 0, l2 - r2, l2 - r2 + o2)), e3.hasDragged && e3.scrollbar && C(e3.scrollbar.options.liveRedraw, !d && !this.chart.boosted) && (t3.DOMType = t3.type, setTimeout(function() {
25659              e3.onMouseUp(t3);
25660            }, 0)));
25661          }
25662          onMouseUp(t3) {
25663            let e3, i3, s2, o2, r2, a2;
25664            let n2 = this.chart, l2 = this.xAxis, h2 = this.scrollbar, d2 = t3.DOMEvent || t3, c2 = n2.inverted, p2 = this.rendered && !this.hasDragged ? "animate" : "attr";
25665            (this.hasDragged && (!h2 || !h2.hasDragged) || "scrollbar" === t3.trigger) && (s2 = this.getUnionExtremes(), this.zoomedMin === this.otherHandlePos ? o2 = this.fixedExtreme : this.zoomedMax === this.otherHandlePos && (r2 = this.fixedExtreme), this.zoomedMax === this.size && (r2 = this.reversedExtremes ? s2.dataMin : s2.dataMax), 0 === this.zoomedMin && (o2 = this.reversedExtremes ? s2.dataMax : s2.dataMin), f((a2 = l2.navigatorAxis.toFixedRange(this.zoomedMin, this.zoomedMax, o2, r2)).min) && v(this, "setRange", {
25666              min: Math.min(a2.min, a2.max),
25667              max: Math.max(a2.min, a2.max),
25668              redraw: true,
25669              animation: !this.hasDragged && null,
25670              eventArguments: {
25671                trigger: "navigator",
25672                triggerOp: "navigator-drag",
25673                DOMEvent: d2
25674              }
25675            })), "mousemove" !== t3.DOMType && "touchmove" !== t3.DOMType && (this.grabbedLeft = this.grabbedRight = this.grabbedCenter = this.fixedWidth = this.fixedExtreme = this.otherHandlePos = this.hasDragged = this.dragOffset = null), this.navigatorEnabled && k(this.zoomedMin) && k(this.zoomedMax) && (i3 = Math.round(this.zoomedMin), e3 = Math.round(this.zoomedMax), this.shades && this.drawMasks(i3, e3, c2, p2), this.outline && this.drawOutline(i3, e3, c2, p2), this.navigatorOptions.handles.enabled && Object.keys(this.handles).length === this.handles.length && (this.drawHandle(i3, 0, c2, p2), this.drawHandle(e3, 1, c2, p2)));
25676          }
25677          removeEvents() {
25678            this.eventsToUnbind && (this.eventsToUnbind.forEach(function(t3) {
25679              t3();
25680            }), this.eventsToUnbind = void 0), this.removeBaseSeriesEvents();
25681          }
25682          removeBaseSeriesEvents() {
25683            let t3 = this.baseSeries || [];
25684            this.navigatorEnabled && t3[0] && (false !== this.navigatorOptions.adaptToUpdatedData && t3.forEach(function(t4) {
25685              A(t4, "updatedData", this.updatedDataHandler);
25686            }, this), t3[0].xAxis && A(t3[0].xAxis, "foundExtremes", this.modifyBaseAxisExtremes));
25687          }
25688          getXAxisOffsets() {
25689            return this.chart.inverted ? [this.scrollButtonSize, 0, -this.scrollButtonSize, 0] : [0, -this.scrollButtonSize, 0, this.scrollButtonSize];
25690          }
25691          init(e3) {
25692            let i3 = e3.options, s2 = i3.navigator || {}, r2 = s2.enabled, n2 = i3.scrollbar || {}, l2 = n2.enabled, h2 = r2 && s2.height || 0, d2 = l2 && n2.height || 0, c2 = n2.buttonsEnabled && d2 || 0;
25693            this.handles = [], this.shades = [], this.chart = e3, this.setBaseSeries(), this.height = h2, this.scrollbarHeight = d2, this.scrollButtonSize = c2, this.scrollbarEnabled = l2, this.navigatorEnabled = r2, this.navigatorOptions = s2, this.scrollbarOptions = n2, this.setOpposite();
25694            let u12 = this, g2 = u12.baseSeries, f2 = e3.xAxis.length, m2 = e3.yAxis.length, x2 = g2 && g2[0] && g2[0].xAxis || e3.xAxis[0] || {
25695              options: {}
25696            };
25697            if (e3.isDirtyBox = true, u12.navigatorEnabled) {
25698              let i4 = this.getXAxisOffsets();
25699              u12.xAxis = new t2(e3, M({
25700                breaks: x2.options.breaks,
25701                ordinal: x2.options.ordinal,
25702                overscroll: x2.options.overscroll
25703              }, s2.xAxis, {
25704                type: "datetime",
25705                yAxis: s2.yAxis?.id,
25706                index: f2,
25707                isInternal: true,
25708                offset: 0,
25709                keepOrdinalPadding: true,
25710                startOnTick: false,
25711                endOnTick: false,
25712                minPadding: x2.options.ordinal ? 0 : x2.options.minPadding,
25713                maxPadding: x2.options.ordinal ? 0 : x2.options.maxPadding,
25714                zoomEnabled: false
25715              }, e3.inverted ? {
25716                offsets: i4,
25717                width: h2
25718              } : {
25719                offsets: i4,
25720                height: h2
25721              }), "xAxis"), u12.yAxis = new t2(e3, M(s2.yAxis, {
25722                alignTicks: false,
25723                offset: 0,
25724                index: m2,
25725                isInternal: true,
25726                reversed: C(s2.yAxis && s2.yAxis.reversed, e3.yAxis[0] && e3.yAxis[0].reversed, false),
25727                zoomEnabled: false
25728              }, e3.inverted ? {
25729                width: h2
25730              } : {
25731                height: h2
25732              }), "yAxis"), g2 || s2.series.data ? u12.updateNavigatorSeries(false) : 0 === e3.series.length && (u12.unbindRedraw = p(e3, "beforeRedraw", function() {
25733                e3.series.length > 0 && !u12.series && (u12.setBaseSeries(), u12.unbindRedraw());
25734              })), u12.reversedExtremes = e3.inverted && !u12.xAxis.reversed || !e3.inverted && u12.xAxis.reversed, u12.renderElements(), u12.addMouseEvents();
25735            } else u12.xAxis = {
25736              chart: e3,
25737              navigatorAxis: {
25738                fake: true
25739              },
25740              translate: function(t3, i4) {
25741                let s3 = e3.xAxis[0], o2 = s3.getExtremes(), r3 = s3.len - 2 * c2, a2 = T2("min", s3.options.min, o2.dataMin), n3 = T2("max", s3.options.max, o2.dataMax) - a2;
25742                return i4 ? t3 * n3 / r3 + a2 : r3 * (t3 - a2) / n3;
25743              },
25744              toPixels: function(t3) {
25745                return this.translate(t3);
25746              },
25747              toValue: function(t3) {
25748                return this.translate(t3, true);
25749              }
25750            }, u12.xAxis.navigatorAxis.axis = u12.xAxis, u12.xAxis.navigatorAxis.toFixedRange = o.prototype.toFixedRange.bind(u12.xAxis.navigatorAxis);
25751            if (e3.options.scrollbar.enabled) {
25752              let t3 = M(e3.options.scrollbar, {
25753                vertical: e3.inverted
25754              });
25755              !k(t3.margin) && u12.navigatorEnabled && (t3.margin = e3.inverted ? -3 : 3), e3.scrollbar = u12.scrollbar = new a(e3.renderer, t3, e3), p(u12.scrollbar, "changed", function(t4) {
25756                let e4 = u12.size, i4 = e4 * this.to, s3 = e4 * this.from;
25757                u12.hasDragged = u12.scrollbar.hasDragged, u12.render(0, 0, s3, i4), this.shouldUpdateExtremes(t4.DOMType) && setTimeout(function() {
25758                  u12.onMouseUp(t4);
25759                });
25760              });
25761            }
25762            u12.addBaseSeriesEvents(), u12.addChartEvents();
25763          }
25764          setOpposite() {
25765            let t3 = this.navigatorOptions, e3 = this.navigatorEnabled, i3 = this.chart;
25766            this.opposite = C(t3.opposite, !!(!e3 && i3.inverted));
25767          }
25768          getUnionExtremes(t3) {
25769            let e3;
25770            let i3 = this.chart.xAxis[0], s2 = this.xAxis, o2 = s2.options, r2 = i3.options;
25771            return t3 && null === i3.dataMin || (e3 = {
25772              dataMin: C(o2 && o2.min, T2("min", r2.min, i3.dataMin, s2.dataMin, s2.min)),
25773              dataMax: C(o2 && o2.max, T2("max", r2.max, i3.dataMax, s2.dataMax, s2.max))
25774            }), e3;
25775          }
25776          setBaseSeries(t3, e3) {
25777            let i3 = this.chart, s2 = this.baseSeries = [];
25778            t3 = t3 || i3.options && i3.options.navigator.baseSeries || (i3.series.length ? b(i3.series, (t4) => !t4.options.isInternal).index : 0), (i3.series || []).forEach((e4, i4) => {
25779              !e4.options.isInternal && (e4.options.showInNavigator || (i4 === t3 || e4.options.id === t3) && false !== e4.options.showInNavigator) && s2.push(e4);
25780            }), this.xAxis && !this.xAxis.navigatorAxis.fake && this.updateNavigatorSeries(true, e3);
25781          }
25782          updateNavigatorSeries(t3, e3) {
25783            let i3 = this, s2 = i3.chart, o2 = i3.baseSeries, r2 = {
25784              enableMouseTracking: false,
25785              index: null,
25786              linkedTo: null,
25787              group: "nav",
25788              padXAxis: false,
25789              xAxis: this.navigatorOptions.xAxis?.id,
25790              yAxis: this.navigatorOptions.yAxis?.id,
25791              showInLegend: false,
25792              stacking: void 0,
25793              isInternal: true,
25794              states: {
25795                inactive: {
25796                  opacity: 1
25797                }
25798              }
25799            }, a2 = i3.series = (i3.series || []).filter((t4) => {
25800              let e4 = t4.baseSeries;
25801              return !(0 > o2.indexOf(e4)) || (e4 && (A(e4, "updatedData", i3.updatedDataHandler), delete e4.navigatorSeries), t4.chart && t4.destroy(), false);
25802            }), n2, l2, d2 = i3.navigatorOptions.series, c2;
25803            o2 && o2.length && o2.forEach((t4) => {
25804              let p2 = t4.navigatorSeries, u12 = y({
25805                color: t4.color,
25806                visible: t4.visible
25807              }, S2(d2) ? h.navigator.series : d2);
25808              if (p2 && false === i3.navigatorOptions.adaptToUpdatedData) return;
25809              r2.name = "Navigator " + o2.length, c2 = (n2 = t4.options || {}).navigatorOptions || {}, u12.dataLabels = w(u12.dataLabels), (l2 = M(n2, r2, u12, c2)).pointRange = C(u12.pointRange, c2.pointRange, h.plotOptions[l2.type || "line"].pointRange);
25810              let g2 = c2.data || u12.data;
25811              i3.hasNavigatorData = i3.hasNavigatorData || !!g2, l2.data = g2 || n2.data && n2.data.slice(0), p2 && p2.options ? p2.update(l2, e3) : (t4.navigatorSeries = s2.initSeries(l2), s2.setSortedData(), t4.navigatorSeries.baseSeries = t4, a2.push(t4.navigatorSeries));
25812            }), (d2.data && !(o2 && o2.length) || S2(d2)) && (i3.hasNavigatorData = false, (d2 = w(d2)).forEach((t4, e4) => {
25813              r2.name = "Navigator " + (a2.length + 1), (l2 = M(h.navigator.series, {
25814                color: s2.series[e4] && !s2.series[e4].options.isInternal && s2.series[e4].color || s2.options.colors[e4] || s2.options.colors[0]
25815              }, r2, t4)).data = t4.data, l2.data && (i3.hasNavigatorData = true, a2.push(s2.initSeries(l2)));
25816            })), t3 && this.addBaseSeriesEvents();
25817          }
25818          addBaseSeriesEvents() {
25819            let t3 = this, e3 = t3.baseSeries || [];
25820            e3[0] && e3[0].xAxis && e3[0].eventsToUnbind.push(p(e3[0].xAxis, "foundExtremes", this.modifyBaseAxisExtremes)), e3.forEach((i3) => {
25821              i3.eventsToUnbind.push(p(i3, "show", function() {
25822                this.navigatorSeries && this.navigatorSeries.setVisible(true, false);
25823              })), i3.eventsToUnbind.push(p(i3, "hide", function() {
25824                this.navigatorSeries && this.navigatorSeries.setVisible(false, false);
25825              })), false !== this.navigatorOptions.adaptToUpdatedData && i3.xAxis && i3.eventsToUnbind.push(p(i3, "updatedData", this.updatedDataHandler)), i3.eventsToUnbind.push(p(i3, "remove", function() {
25826                e3 && x(e3, i3), this.navigatorSeries && (x(t3.series, this.navigatorSeries), f(this.navigatorSeries.options) && this.navigatorSeries.remove(false), delete this.navigatorSeries);
25827              }));
25828            });
25829          }
25830          getBaseSeriesMin(t3) {
25831            return this.baseSeries.reduce(function(t4, e3) {
25832              return Math.min(t4, e3.xData && e3.xData.length ? e3.xData[0] : t4);
25833            }, t3);
25834          }
25835          modifyNavigatorAxisExtremes() {
25836            let t3 = this.xAxis;
25837            if (void 0 !== t3.getExtremes) {
25838              let e3 = this.getUnionExtremes(true);
25839              e3 && (e3.dataMin !== t3.min || e3.dataMax !== t3.max) && (t3.min = e3.dataMin, t3.max = e3.dataMax);
25840            }
25841          }
25842          modifyBaseAxisExtremes() {
25843            let t3, e3;
25844            let i3 = this.chart.navigator, s2 = this.getExtremes(), o2 = s2.min, r2 = s2.max, a2 = s2.dataMin, n2 = s2.dataMax, l2 = r2 - o2, h2 = i3.stickToMin, d2 = i3.stickToMax, c2 = C(this.ordinal?.convertOverscroll(this.options.overscroll), 0), p2 = i3.series && i3.series[0], u12 = !!this.setExtremes;
25845            !(this.eventArgs && "rangeSelectorButton" === this.eventArgs.trigger) && (h2 && (t3 = (e3 = a2) + l2), d2 && (t3 = n2 + c2, h2 || (e3 = Math.max(a2, t3 - l2, i3.getBaseSeriesMin(p2 && p2.xData ? p2.xData[0] : -Number.MAX_VALUE)))), u12 && (h2 || d2) && k(e3) && (this.min = this.userMin = e3, this.max = this.userMax = t3)), i3.stickToMin = i3.stickToMax = null;
25846          }
25847          updatedDataHandler() {
25848            let t3 = this.chart.navigator, e3 = this.navigatorSeries, i3 = t3.reversedExtremes ? 0 === Math.round(t3.zoomedMin) : Math.round(t3.zoomedMax) >= Math.round(t3.size);
25849            t3.stickToMax = C(this.chart.options.navigator && this.chart.options.navigator.stickToMax, i3), t3.stickToMin = t3.shouldStickToMin(this, t3), e3 && !t3.hasNavigatorData && (e3.options.pointStart = this.xData[0], e3.setData(this.options.data, false, null, false));
25850          }
25851          shouldStickToMin(t3, e3) {
25852            let i3 = e3.getBaseSeriesMin(t3.xData[0]), s2 = t3.xAxis, o2 = s2.max, r2 = s2.min, a2 = s2.options.range;
25853            return !!(k(o2) && k(r2)) && (a2 && o2 - i3 > 0 ? o2 - i3 < a2 : r2 <= i3);
25854          }
25855          addChartEvents() {
25856            this.eventsToUnbind || (this.eventsToUnbind = []), this.eventsToUnbind.push(p(this.chart, "redraw", function() {
25857              let t3 = this.navigator, e3 = t3 && (t3.baseSeries && t3.baseSeries[0] && t3.baseSeries[0].xAxis || this.xAxis[0]);
25858              e3 && t3.render(e3.min, e3.max);
25859            }), p(this.chart, "getMargins", function() {
25860              let t3 = this.navigator, e3 = t3.opposite ? "plotTop" : "marginBottom";
25861              this.inverted && (e3 = t3.opposite ? "marginRight" : "plotLeft"), this[e3] = (this[e3] || 0) + (t3.navigatorEnabled || !this.inverted ? t3.height + t3.scrollbarHeight : 0) + t3.navigatorOptions.margin;
25862            }), p(P, "setRange", function(t3) {
25863              this.chart.xAxis[0].setExtremes(t3.min, t3.max, t3.redraw, t3.animation, t3.eventArguments);
25864            }));
25865          }
25866          destroy() {
25867            this.removeEvents(), this.xAxis && (x(this.chart.xAxis, this.xAxis), x(this.chart.axes, this.xAxis)), this.yAxis && (x(this.chart.yAxis, this.yAxis), x(this.chart.axes, this.yAxis)), (this.series || []).forEach((t3) => {
25868              t3.destroy && t3.destroy();
25869            }), ["series", "xAxis", "yAxis", "shades", "outline", "scrollbarTrack", "scrollbarRifles", "scrollbarGroup", "scrollbar", "navigatorGroup", "rendered"].forEach((t3) => {
25870              this[t3] && this[t3].destroy && this[t3].destroy(), this[t3] = null;
25871            }), [this.handles].forEach((t3) => {
25872              m(t3);
25873            }), this.navigatorEnabled = false;
25874          }
25875        }
25876        return P;
25877      }), i(e, "Core/Axis/OrdinalAxis.js", [e["Core/Axis/Axis.js"], e["Core/Globals.js"], e["Core/Series/Series.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
25878        var o;
25879        let {
25880          addEvent: r,
25881          correctFloat: a,
25882          css: n,
25883          defined: l,
25884          error: h,
25885          isNumber: d,
25886          pick: c,
25887          timeUnits: p,
25888          isString: u11
25889        } = s;
25890        return function(t3) {
25891          function s2(t4, e3, i3, o3, r2 = [], a2 = 0, n2) {
25892            let d2 = {}, c2 = this.options.tickPixelInterval, u12 = this.chart.time, g2 = [], f2, m2, x2, y2, b2, v2 = 0, S3 = [], k2 = -Number.MAX_VALUE;
25893            if (!this.options.ordinal && !this.options.breaks || !r2 || r2.length < 3 || void 0 === e3) return u12.getTimeTicks.apply(u12, arguments);
25894            let M2 = r2.length;
25895            for (f2 = 0; f2 < M2; f2++) {
25896              if (b2 = f2 && r2[f2 - 1] > i3, r2[f2] < e3 && (v2 = f2), f2 === M2 - 1 || r2[f2 + 1] - r2[f2] > 5 * a2 || b2) {
25897                if (r2[f2] > k2) {
25898                  for (m2 = u12.getTimeTicks(t4, r2[v2], r2[f2], o3); m2.length && m2[0] <= k2; ) m2.shift();
25899                  m2.length && (k2 = m2[m2.length - 1]), g2.push(S3.length), S3 = S3.concat(m2);
25900                }
25901                v2 = f2 + 1;
25902              }
25903              if (b2) break;
25904            }
25905            if (m2) {
25906              if (y2 = m2.info, n2 && y2.unitRange <= p.hour) {
25907                for (v2 = 1, f2 = S3.length - 1; v2 < f2; v2++) u12.dateFormat("%d", S3[v2]) !== u12.dateFormat("%d", S3[v2 - 1]) && (d2[S3[v2]] = "day", x2 = true);
25908                x2 && (d2[S3[0]] = "day"), y2.higherRanks = d2;
25909              }
25910              y2.segmentStarts = g2, S3.info = y2;
25911            } else h(12, false, this.chart);
25912            if (n2 && l(c2)) {
25913              let t5 = S3.length, e4 = [], s3 = [], o4, r3, a3, n3, l2, h2 = t5;
25914              for (; h2--; ) r3 = this.translate(S3[h2]), a3 && (s3[h2] = a3 - r3), e4[h2] = a3 = r3;
25915              for (s3.sort((t6, e5) => t6 - e5), (n3 = s3[Math.floor(s3.length / 2)]) < 0.6 * c2 && (n3 = null), h2 = S3[t5 - 1] > i3 ? t5 - 1 : t5, a3 = void 0; h2--; ) l2 = Math.abs(a3 - (r3 = e4[h2])), a3 && l2 < 0.8 * c2 && (null === n3 || l2 < 0.8 * n3) ? (d2[S3[h2]] && !d2[S3[h2 + 1]] ? (o4 = h2 + 1, a3 = r3) : o4 = h2, S3.splice(o4, 1)) : a3 = r3;
25916            }
25917            return S3;
25918          }
25919          function o2(t4) {
25920            let e3 = this.ordinal.positions;
25921            if (!e3) return t4;
25922            let i3 = e3.length - 1, s3;
25923            return (t4 < 0 ? t4 = e3[0] : t4 > i3 ? t4 = e3[i3] : (i3 = Math.floor(t4), s3 = t4 - i3), void 0 !== s3 && void 0 !== e3[i3]) ? e3[i3] + (s3 ? s3 * (e3[i3 + 1] - e3[i3]) : 0) : t4;
25924          }
25925          function g(t4) {
25926            let e3 = this.ordinal, i3 = this.old ? this.old.min : this.min, s3 = this.old ? this.old.transA : this.transA, o3 = e3.getExtendedPositions();
25927            if (o3 && o3.length) {
25928              let r2 = a((t4 - i3) * s3 + this.minPixelPadding), n2 = a(e3.getIndexOfPoint(r2, o3)), l2 = a(n2 % 1);
25929              if (n2 >= 0 && n2 <= o3.length - 1) {
25930                let t5 = o3[Math.floor(n2)], e4 = o3[Math.ceil(n2)];
25931                return o3[Math.floor(n2)] + l2 * (e4 - t5);
25932              }
25933            }
25934            return t4;
25935          }
25936          function f(e3, i3) {
25937            let s3 = t3.Additions.findIndexOf(e3, i3, true);
25938            if (e3[s3] === i3) return s3;
25939            let o3 = (i3 - e3[s3]) / (e3[s3 + 1] - e3[s3]);
25940            return s3 + o3;
25941          }
25942          function m() {
25943            this.ordinal || (this.ordinal = new t3.Additions(this));
25944          }
25945          function x() {
25946            let {
25947              eventArgs: t4,
25948              options: e3
25949            } = this;
25950            if (this.isXAxis && l(e3.overscroll) && 0 !== e3.overscroll && d(this.max) && d(this.min) && (this.options.ordinal && !this.ordinal.originalOrdinalRange && this.ordinal.getExtendedPositions(false), this.max === this.dataMax && (t4?.trigger !== "pan" || this.isInternal) && t4?.trigger !== "navigator")) {
25951              let i3 = this.ordinal.convertOverscroll(e3.overscroll);
25952              this.max += i3, !this.isInternal && l(this.userMin) && t4?.trigger !== "mousewheel" && (this.min += i3);
25953            }
25954          }
25955          function y() {
25956            this.horiz && !this.isDirty && (this.isDirty = this.isOrdinal && this.chart.navigator && !this.chart.navigator.adaptToUpdatedData);
25957          }
25958          function b() {
25959            this.ordinal && (this.ordinal.beforeSetTickPositions(), this.tickInterval = this.ordinal.postProcessTickInterval(this.tickInterval));
25960          }
25961          function v(t4) {
25962            let e3 = this.xAxis[0], i3 = e3.ordinal.convertOverscroll(e3.options.overscroll), s3 = t4.originalEvent.chartX, o3 = this.options.chart.panning, r2 = false;
25963            if (o3 && "y" !== o3.type && e3.options.ordinal && e3.series.length && (!t4.touches || t4.touches.length <= 1)) {
25964              let t5, o4;
25965              let a2 = this.mouseDownX, l2 = e3.getExtremes(), h2 = l2.dataMin, d2 = l2.dataMax, c2 = l2.min, p2 = l2.max, u12 = this.hoverPoints, g2 = e3.closestPointRange || e3.ordinal && e3.ordinal.overscrollPointsRange, f2 = Math.round((a2 - s3) / (e3.translationSlope * (e3.ordinal.slope || g2))), m2 = e3.ordinal.getExtendedPositions(), x2 = {
25966                ordinal: {
25967                  positions: m2,
25968                  extendedOrdinalPositions: m2
25969                }
25970              }, y2 = e3.index2val, b2 = e3.val2lin;
25971              if (c2 <= h2 && f2 < 0 || p2 + i3 >= d2 && f2 > 0) return;
25972              x2.ordinal.positions ? Math.abs(f2) > 1 && (u12 && u12.forEach(function(t6) {
25973                t6.setState();
25974              }), d2 > (o4 = x2.ordinal.positions)[o4.length - 1] && o4.push(d2), this.setFixedRange(p2 - c2), (t5 = e3.navigatorAxis.toFixedRange(void 0, void 0, y2.apply(x2, [b2.apply(x2, [c2, true]) + f2]), y2.apply(x2, [b2.apply(x2, [p2, true]) + f2]))).min >= Math.min(l2.dataMin, c2) && t5.max <= Math.max(d2, p2) + i3 && e3.setExtremes(t5.min, t5.max, true, false, {
25975                trigger: "pan"
25976              }), this.mouseDownX = s3, n(this.container, {
25977                cursor: "move"
25978              })) : r2 = true;
25979            } else r2 = true;
25980            r2 || o3 && /y/.test(o3.type) ? i3 && (e3.max = e3.dataMax + i3) : t4.preventDefault();
25981          }
25982          function S2() {
25983            let t4 = this.xAxis;
25984            t4 && t4.options.ordinal && (delete t4.ordinal.index, delete t4.ordinal.originalOrdinalRange);
25985          }
25986          function k(t4, e3) {
25987            let i3;
25988            let s3 = this.ordinal, o3 = s3.positions, r2 = s3.slope, a2;
25989            if (!o3) return t4;
25990            let n2 = o3.length;
25991            if (o3[0] <= t4 && o3[n2 - 1] >= t4) i3 = f(o3, t4);
25992            else {
25993              if (!((a2 = s3.getExtendedPositions && s3.getExtendedPositions()) && a2.length)) return t4;
25994              let n3 = a2.length;
25995              r2 || (r2 = (a2[n3 - 1] - a2[0]) / n3);
25996              let l2 = f(a2, o3[0]);
25997              if (t4 >= a2[0] && t4 <= a2[n3 - 1]) i3 = f(a2, t4) - l2;
25998              else {
25999                if (!e3) return t4;
26000                i3 = t4 < a2[0] ? -l2 - (a2[0] - t4) / r2 : (t4 - a2[n3 - 1]) / r2 + n3 - l2;
26001              }
26002            }
26003            return e3 ? i3 : r2 * (i3 || 0) + s3.offset;
26004          }
26005          t3.compose = function(t4, e3, i3) {
26006            let a2 = t4.prototype;
26007            return a2.ordinal2lin || (a2.getTimeTicks = s2, a2.index2val = o2, a2.lin2val = g, a2.val2lin = k, a2.ordinal2lin = a2.val2lin, r(t4, "afterInit", m), r(t4, "foundExtremes", x), r(t4, "afterSetScale", y), r(t4, "initialAxisTranslation", b), r(i3, "pan", v), r(i3, "touchpan", v), r(e3, "updatedData", S2)), t4;
26008          };
26009          class M {
26010            constructor(t4) {
26011              this.index = {}, this.axis = t4;
26012            }
26013            beforeSetTickPositions() {
26014              let t4 = this.axis, e3 = t4.ordinal, i3 = t4.getExtremes(), s3 = i3.min, o3 = i3.max, r2 = t4.brokenAxis?.hasBreaks, a2 = t4.options.ordinal, n2, l2, h2, d2, p2, u12, g2, f2 = [], m2 = Number.MAX_VALUE, x2 = false, y2 = false, b2 = false;
26015              if (a2 || r2) {
26016                let i4 = 0;
26017                if (t4.series.forEach(function(t5, e4) {
26018                  if (l2 = [], e4 > 0 && "highcharts-navigator-series" !== t5.options.id && t5.processedXData.length > 1 && (y2 = i4 !== t5.processedXData[1] - t5.processedXData[0]), i4 = t5.processedXData[1] - t5.processedXData[0], t5.boosted && (b2 = t5.boosted), t5.reserveSpace() && (false !== t5.takeOrdinalPosition || r2) && (n2 = (f2 = f2.concat(t5.processedXData)).length, f2.sort(function(t6, e5) {
26019                    return t6 - e5;
26020                  }), m2 = Math.min(m2, c(t5.closestPointRange, m2)), n2)) {
26021                    for (e4 = 0; e4 < n2 - 1; ) f2[e4] !== f2[e4 + 1] && l2.push(f2[e4 + 1]), e4++;
26022                    l2[0] !== f2[0] && l2.unshift(f2[0]), f2 = l2;
26023                  }
26024                }), t4.ordinal.originalOrdinalRange || (t4.ordinal.originalOrdinalRange = (f2.length - 1) * m2), y2 && b2 && (f2.pop(), f2.shift()), (n2 = f2.length) > 2) {
26025                  for (h2 = f2[1] - f2[0], g2 = n2 - 1; g2-- && !x2; ) f2[g2 + 1] - f2[g2] !== h2 && (x2 = true);
26026                  !t4.options.keepOrdinalPadding && (f2[0] - s3 > h2 || o3 - f2[f2.length - 1] > h2) && (x2 = true);
26027                } else t4.options.overscroll && (2 === n2 ? m2 = f2[1] - f2[0] : 1 === n2 ? (m2 = t4.ordinal.convertOverscroll(t4.options.overscroll), f2 = [f2[0], f2[0] + m2]) : m2 = e3.overscrollPointsRange);
26028                x2 || t4.forceOrdinal ? (t4.options.overscroll && (e3.overscrollPointsRange = m2, f2 = f2.concat(e3.getOverscrollPositions())), e3.positions = f2, d2 = t4.ordinal2lin(Math.max(s3, f2[0]), true), p2 = Math.max(t4.ordinal2lin(Math.min(o3, f2[f2.length - 1]), true), 1), e3.slope = u12 = (o3 - s3) / (p2 - d2), e3.offset = s3 - d2 * u12) : (e3.overscrollPointsRange = c(t4.closestPointRange, e3.overscrollPointsRange), e3.positions = t4.ordinal.slope = e3.offset = void 0);
26029              }
26030              t4.isOrdinal = a2 && x2, e3.groupIntervalFactor = null;
26031            }
26032            static findIndexOf(t4, e3, i3) {
26033              let s3 = 0, o3 = t4.length - 1, r2;
26034              for (; s3 < o3; ) t4[r2 = Math.ceil((s3 + o3) / 2)] <= e3 ? s3 = r2 : o3 = r2 - 1;
26035              return t4[s3] === e3 ? s3 : i3 ? s3 : -1;
26036            }
26037            getExtendedPositions(t4 = true) {
26038              let s3 = this, o3 = s3.axis, r2 = o3.constructor.prototype, a2 = o3.chart, n2 = o3.series[0]?.currentDataGrouping, l2 = n2 ? n2.count + n2.unitName : "raw", h2 = t4 ? o3.ordinal.convertOverscroll(o3.options.overscroll) : 0, d2 = o3.getExtremes(), c2, p2, u12 = s3.index;
26039              return u12 || (u12 = s3.index = {}), u12[l2] || ((c2 = {
26040                series: [],
26041                chart: a2,
26042                forceOrdinal: false,
26043                getExtremes: function() {
26044                  return {
26045                    min: d2.dataMin,
26046                    max: d2.dataMax + h2
26047                  };
26048                },
26049                applyGrouping: r2.applyGrouping,
26050                getGroupPixelWidth: r2.getGroupPixelWidth,
26051                getTimeTicks: r2.getTimeTicks,
26052                options: {
26053                  ordinal: true
26054                },
26055                ordinal: {
26056                  getGroupIntervalFactor: this.getGroupIntervalFactor
26057                },
26058                ordinal2lin: r2.ordinal2lin,
26059                getIndexOfPoint: r2.getIndexOfPoint,
26060                val2lin: r2.val2lin
26061              }).ordinal.axis = c2, o3.series.forEach(function(o4) {
26062                p2 = {
26063                  xAxis: c2,
26064                  xData: o4.xData.slice(),
26065                  chart: a2,
26066                  groupPixelWidth: o4.groupPixelWidth,
26067                  destroyGroupedData: e2.noop,
26068                  getProcessedData: i2.prototype.getProcessedData,
26069                  applyGrouping: i2.prototype.applyGrouping,
26070                  reserveSpace: i2.prototype.reserveSpace,
26071                  visible: o4.visible
26072                }, t4 && (p2.xData = p2.xData.concat(s3.getOverscrollPositions())), p2.options = {
26073                  dataGrouping: n2 ? {
26074                    firstAnchor: o4.options.dataGrouping?.firstAnchor,
26075                    anchor: o4.options.dataGrouping?.anchor,
26076                    lastAnchor: o4.options.dataGrouping?.firstAnchor,
26077                    enabled: true,
26078                    forced: true,
26079                    approximation: "open",
26080                    units: [[n2.unitName, [n2.count]]]
26081                  } : {
26082                    enabled: false
26083                  }
26084                }, c2.series.push(p2), o4.processData.apply(p2);
26085              }), c2.applyGrouping({
26086                hasExtremesChanged: true
26087              }), p2?.closestPointRange !== p2?.basePointRange && p2.currentDataGrouping && (c2.forceOrdinal = true), o3.ordinal.beforeSetTickPositions.apply({
26088                axis: c2
26089              }), !o3.ordinal.originalOrdinalRange && c2.ordinal.originalOrdinalRange && (o3.ordinal.originalOrdinalRange = c2.ordinal.originalOrdinalRange), u12[l2] = c2.ordinal.positions), u12[l2];
26090            }
26091            getGroupIntervalFactor(t4, e3, i3) {
26092              let s3 = i3.processedXData, o3 = s3.length, r2 = [], a2, n2, l2 = this.groupIntervalFactor;
26093              if (!l2) {
26094                for (n2 = 0; n2 < o3 - 1; n2++) r2[n2] = s3[n2 + 1] - s3[n2];
26095                r2.sort(function(t5, e4) {
26096                  return t5 - e4;
26097                }), a2 = r2[Math.floor(o3 / 2)], t4 = Math.max(t4, s3[0]), e3 = Math.min(e3, s3[o3 - 1]), this.groupIntervalFactor = l2 = o3 * a2 / (e3 - t4);
26098              }
26099              return l2;
26100            }
26101            getIndexOfPoint(t4, e3) {
26102              let i3;
26103              let s3 = this.axis, o3 = 0, r2 = function(t5) {
26104                let {
26105                  min: e4,
26106                  max: i4
26107                } = s3;
26108                return !!(l(e4) && l(i4)) && t5.points.some((t6) => t6.x >= e4 && t6.x <= i4);
26109              };
26110              s3.series.forEach((t5) => {
26111                let e4 = t5.points?.[0];
26112                l(e4?.plotX) && (e4.plotX < i3 || !l(i3)) && r2(t5) && (i3 = e4.plotX, o3 = e4.x);
26113              }), i3 ?? (i3 = s3.minPixelPadding);
26114              let n2 = s3.translationSlope * (this.slope || s3.closestPointRange || this.overscrollPointsRange), h2 = a((t4 - i3) / n2);
26115              return M.findIndexOf(e3, o3, true) + h2;
26116            }
26117            getOverscrollPositions() {
26118              let t4 = this.axis, e3 = this.convertOverscroll(t4.options.overscroll), i3 = this.overscrollPointsRange, s3 = [], o3 = t4.dataMax;
26119              if (l(i3)) for (; o3 <= t4.dataMax + e3; ) s3.push(o3 += i3);
26120              return s3;
26121            }
26122            postProcessTickInterval(t4) {
26123              let e3 = this.axis, i3 = this.slope;
26124              return i3 ? e3.options.breaks ? e3.closestPointRange || t4 : t4 / (i3 / e3.closestPointRange) : t4;
26125            }
26126            convertOverscroll(t4 = 0) {
26127              let e3 = this, i3 = e3.axis, s3 = function(t5) {
26128                return c(e3.originalOrdinalRange, l(i3.dataMax) && l(i3.dataMin) ? i3.dataMax - i3.dataMin : 0) * t5;
26129              };
26130              if (u11(t4)) {
26131                let e4 = parseInt(t4, 10);
26132                if (/%$/.test(t4)) return s3(e4 / 100);
26133                if (/px/.test(t4)) {
26134                  let t5 = Math.min(e4, 0.9 * i3.len) / i3.len;
26135                  return s3(t5 / (1 - t5));
26136                }
26137                return 0;
26138              }
26139              return t4;
26140            }
26141          }
26142          t3.Additions = M;
26143        }(o || (o = {})), o;
26144      }), i(e, "Stock/RangeSelector/RangeSelectorDefaults.js", [], function() {
26145        return {
26146          lang: {
26147            rangeSelectorZoom: "Zoom",
26148            rangeSelectorFrom: "",
26149            rangeSelectorTo: "\u2192"
26150          },
26151          rangeSelector: {
26152            allButtonsEnabled: false,
26153            buttons: void 0,
26154            buttonSpacing: 5,
26155            dropdown: "responsive",
26156            enabled: void 0,
26157            verticalAlign: "top",
26158            buttonTheme: {
26159              width: 28,
26160              height: 18,
26161              padding: 2,
26162              zIndex: 7
26163            },
26164            floating: false,
26165            x: 0,
26166            y: 0,
26167            height: void 0,
26168            inputBoxBorderColor: "none",
26169            inputBoxHeight: 17,
26170            inputBoxWidth: void 0,
26171            inputDateFormat: "%e %b %Y",
26172            inputDateParser: void 0,
26173            inputEditDateFormat: "%Y-%m-%d",
26174            inputEnabled: true,
26175            inputPosition: {
26176              align: "right",
26177              x: 0,
26178              y: 0
26179            },
26180            inputSpacing: 5,
26181            selected: void 0,
26182            buttonPosition: {
26183              align: "left",
26184              x: 0,
26185              y: 0
26186            },
26187            inputStyle: {
26188              color: "#334eff",
26189              cursor: "pointer",
26190              fontSize: "0.8em"
26191            },
26192            labelStyle: {
26193              color: "#666666",
26194              fontSize: "0.8em"
26195            }
26196          }
26197        };
26198      }), i(e, "Stock/RangeSelector/RangeSelectorComposition.js", [e["Core/Defaults.js"], e["Core/Globals.js"], e["Stock/RangeSelector/RangeSelectorDefaults.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
26199        let o;
26200        let {
26201          defaultOptions: r
26202        } = t2, {
26203          composed: a
26204        } = e2, {
26205          addEvent: n,
26206          defined: l,
26207          extend: h,
26208          isNumber: d,
26209          merge: c,
26210          pick: p,
26211          pushUnique: u11
26212        } = s, g = [];
26213        function f() {
26214          let t3, e3;
26215          let i3 = this.range, s2 = i3.type, o2 = this.max, r2 = this.chart.time, a2 = function(t4, e4) {
26216            let i4 = "year" === s2 ? "FullYear" : "Month", o3 = new r2.Date(t4), a3 = r2.get(i4, o3);
26217            return r2.set(i4, o3, a3 + e4), a3 === r2.get(i4, o3) && r2.set("Date", o3, 0), o3.getTime() - t4;
26218          };
26219          d(i3) ? (t3 = o2 - i3, e3 = i3) : i3 && (t3 = o2 + a2(o2, -(i3.count || 1)), this.chart && this.chart.setFixedRange(o2 - t3));
26220          let n2 = p(this.dataMin, Number.MIN_VALUE);
26221          return d(t3) || (t3 = n2), t3 <= n2 && (t3 = n2, void 0 === e3 && (e3 = a2(t3, i3.count)), this.newMax = Math.min(t3 + e3, p(this.dataMax, Number.MAX_VALUE))), d(o2) ? !d(i3) && i3 && i3._offsetMin && (t3 += i3._offsetMin) : t3 = void 0, t3;
26222        }
26223        function m() {
26224          this.options.rangeSelector && this.options.rangeSelector.enabled && (this.rangeSelector = new o(this));
26225        }
26226        function x() {
26227          let t3 = this.rangeSelector;
26228          if (t3) {
26229            d(t3.deferredYTDClick) && (t3.clickButton(t3.deferredYTDClick), delete t3.deferredYTDClick);
26230            let e3 = t3.options.verticalAlign;
26231            t3.options.floating || ("bottom" === e3 ? this.extraBottomMargin = true : "middle" === e3 || (this.extraTopMargin = true));
26232          }
26233        }
26234        function y() {
26235          let t3;
26236          let e3 = this.rangeSelector;
26237          if (!e3) return;
26238          let i3 = this.xAxis[0].getExtremes(), s2 = this.legend, o2 = e3 && e3.options.verticalAlign;
26239          d(i3.min) && e3.render(i3.min, i3.max), s2.display && "top" === o2 && o2 === s2.options.verticalAlign && (t3 = c(this.spacingBox), "vertical" === s2.options.layout ? t3.y = this.plotTop : t3.y += e3.getHeight(), s2.group.placed = false, s2.align(t3));
26240        }
26241        function b() {
26242          for (let t3 = 0, e3 = g.length; t3 < e3; ++t3) {
26243            let e4 = g[t3];
26244            if (e4[0] === this) {
26245              e4[1].forEach((t4) => t4()), g.splice(t3, 1);
26246              return;
26247            }
26248          }
26249        }
26250        function v() {
26251          let t3 = this.rangeSelector;
26252          if (t3) {
26253            let e3 = t3.getHeight();
26254            this.extraTopMargin && (this.plotTop += e3), this.extraBottomMargin && (this.marginBottom += e3);
26255          }
26256        }
26257        function S2(t3) {
26258          let e3 = t3.options.rangeSelector, i3 = this.extraBottomMargin, s2 = this.extraTopMargin, r2 = this.rangeSelector;
26259          if (e3 && e3.enabled && !l(r2) && this.options.rangeSelector && (this.options.rangeSelector.enabled = true, this.rangeSelector = r2 = new o(this)), this.extraBottomMargin = false, this.extraTopMargin = false, r2) {
26260            let t4 = e3 && e3.verticalAlign || r2.options && r2.options.verticalAlign;
26261            r2.options.floating || ("bottom" === t4 ? this.extraBottomMargin = true : "middle" === t4 || (this.extraTopMargin = true)), (this.extraBottomMargin !== i3 || this.extraTopMargin !== s2) && (this.isDirtyBox = true);
26262          }
26263        }
26264        return {
26265          compose: function(t3, e3, s2) {
26266            if (o = s2, u11(a, "RangeSelector")) {
26267              let s3 = e3.prototype;
26268              t3.prototype.minFromRange = f, n(e3, "afterGetContainer", m), n(e3, "beforeRender", x), n(e3, "destroy", b), n(e3, "getMargins", v), n(e3, "redraw", y), n(e3, "update", S2), s3.callbacks.push(y), h(r, {
26269                rangeSelector: i2.rangeSelector
26270              }), h(r.lang, i2.lang);
26271            }
26272          }
26273        };
26274      }), i(e, "Stock/RangeSelector/RangeSelector.js", [e["Core/Axis/Axis.js"], e["Core/Defaults.js"], e["Core/Globals.js"], e["Stock/RangeSelector/RangeSelectorComposition.js"], e["Core/Renderer/SVG/SVGElement.js"], e["Core/Utilities.js"], e["Core/Axis/OrdinalAxis.js"]], function(e2, i2, s, o, r, a, n) {
26275        let {
26276          defaultOptions: l
26277        } = i2, {
26278          addEvent: h,
26279          createElement: d,
26280          css: c,
26281          defined: p,
26282          destroyObjectProperties: u11,
26283          discardElement: g,
26284          extend: f,
26285          fireEvent: m,
26286          isNumber: x,
26287          merge: y,
26288          objectEach: b,
26289          pad: v,
26290          pick: S2,
26291          pInt: k,
26292          splat: M
26293        } = a;
26294        class C {
26295          static compose(t2, e3) {
26296            o.compose(t2, e3, C);
26297          }
26298          constructor(t2) {
26299            this.buttonOptions = C.prototype.defaultButtons, this.initialButtonGroupWidth = 0, this.init(t2);
26300          }
26301          clickButton(t2, i3) {
26302            let s2 = this.chart, o2 = this.buttonOptions[t2], r2 = s2.xAxis[0], a2 = s2.scroller && s2.scroller.getUnionExtremes() || r2 || {}, n2 = o2.type, l2 = o2.dataGrouping, d2 = a2.dataMin, c2 = a2.dataMax, u12, g2 = r2 && Math.round(Math.min(r2.max, S2(c2, r2.max))), f2, y2 = o2._range, b2, v2, k2, C2 = true;
26303            if (null !== d2 && null !== c2) {
26304              if (this.setSelected(t2), l2 && (this.forcedDataGrouping = true, e2.prototype.setDataGrouping.call(r2 || {
26305                chart: this.chart
26306              }, l2, false), this.frozenStates = o2.preserveDataGrouping), "month" === n2 || "year" === n2) r2 ? (v2 = {
26307                range: o2,
26308                max: g2,
26309                chart: s2,
26310                dataMin: d2,
26311                dataMax: c2
26312              }, u12 = r2.minFromRange.call(v2), x(v2.newMax) && (g2 = v2.newMax), C2 = false) : y2 = o2;
26313              else if (y2) g2 = Math.min((u12 = Math.max(g2 - y2, d2)) + y2, c2), C2 = false;
26314              else if ("ytd" === n2) {
26315                if (r2) (void 0 === c2 || void 0 === d2) && (d2 = Number.MAX_VALUE, c2 = Number.MIN_VALUE, s2.series.forEach((t3) => {
26316                  let e3 = t3.xData;
26317                  e3 && (d2 = Math.min(e3[0], d2), c2 = Math.max(e3[e3.length - 1], c2));
26318                }), i3 = false), u12 = b2 = (k2 = this.getYTDExtremes(c2, d2, s2.time.useUTC)).min, g2 = k2.max;
26319                else {
26320                  this.deferredYTDClick = t2;
26321                  return;
26322                }
26323              } else "all" === n2 && r2 && (s2.navigator && s2.navigator.baseSeries[0] && (s2.navigator.baseSeries[0].xAxis.options.range = void 0), u12 = d2, g2 = c2);
26324              if (C2 && o2._offsetMin && p(u12) && (u12 += o2._offsetMin), o2._offsetMax && p(g2) && (g2 += o2._offsetMax), this.dropdown && (this.dropdown.selectedIndex = t2 + 1), r2) r2.setExtremes(u12, g2, S2(i3, true), void 0, {
26325                trigger: "rangeSelectorButton",
26326                rangeSelectorButton: o2
26327              }), s2.setFixedRange(o2._range);
26328              else {
26329                f2 = M(s2.options.xAxis)[0];
26330                let t3 = h(s2, "afterGetAxes", function() {
26331                  let t4 = s2.xAxis[0];
26332                  t4.range = t4.options.range = y2, t4.min = t4.options.min = b2;
26333                });
26334                h(s2, "load", function() {
26335                  let e3 = s2.xAxis[0];
26336                  s2.setFixedRange(o2._range), e3.options.range = f2.range, e3.options.min = f2.min, t3();
26337                });
26338              }
26339              m(this, "afterBtnClick");
26340            }
26341          }
26342          setSelected(t2) {
26343            this.selected = this.options.selected = t2;
26344          }
26345          init(t2) {
26346            let e3 = this, i3 = t2.options.rangeSelector, s2 = i3.buttons || e3.defaultButtons.slice(), o2 = i3.selected, r2 = function() {
26347              let t3 = e3.minInput, i4 = e3.maxInput;
26348              t3 && t3.blur && m(t3, "blur"), i4 && i4.blur && m(i4, "blur");
26349            };
26350            e3.chart = t2, e3.options = i3, e3.buttons = [], e3.buttonOptions = s2, this.eventsToUnbind = [], this.eventsToUnbind.push(h(t2.container, "mousedown", r2)), this.eventsToUnbind.push(h(t2, "resize", r2)), s2.forEach(e3.computeButtonRange), void 0 !== o2 && s2[o2] && this.clickButton(o2, false), this.eventsToUnbind.push(h(t2, "load", function() {
26351              t2.xAxis && t2.xAxis[0] && h(t2.xAxis[0], "setExtremes", function(i4) {
26352                x(this.max) && x(this.min) && this.max - this.min !== t2.fixedRange && "rangeSelectorButton" !== i4.trigger && "updatedData" !== i4.trigger && e3.forcedDataGrouping && !e3.frozenStates && this.setDataGrouping(false, false);
26353              });
26354            })), this.createElements();
26355          }
26356          updateButtonStates() {
26357            let t2 = this, e3 = this.chart, i3 = this.dropdown, s2 = this.dropdownLabel, o2 = e3.xAxis[0], r2 = Math.round(o2.max - o2.min), a2 = !o2.hasVisibleSeries, h2 = 24 * 36e5, d2 = e3.scroller && e3.scroller.getUnionExtremes() || o2, p2 = d2.dataMin, u12 = d2.dataMax, g2 = t2.getYTDExtremes(u12, p2, e3.time.useUTC), f2 = g2.min, m2 = g2.max, y2 = t2.selected, b2 = t2.options.allButtonsEnabled, v2 = Array(t2.buttonOptions.length).fill(0), S3 = x(y2), k2 = t2.buttons, M2 = false, C2 = null;
26358            t2.buttonOptions.forEach((e4, i4) => {
26359              let s3 = e4._range, l2 = e4.type, d3 = e4.count || 1, c2 = e4._offsetMax - e4._offsetMin, g3 = i4 === y2, x2 = s3 > u12 - p2, k3 = s3 < o2.minRange, A = false, w = s3 === r2;
26360              if (g3 && x2 && (M2 = true), o2.isOrdinal && o2.ordinal?.positions && s3 && r2 < s3) {
26361                let t3 = o2.ordinal.positions, e5 = n.Additions.findIndexOf(t3, o2.min, true), i5 = Math.min(n.Additions.findIndexOf(t3, o2.max, true) + 1, t3.length - 1);
26362                t3[i5] - t3[e5] > s3 && (w = true);
26363              } else ("month" === l2 || "year" === l2) && r2 + 36e5 >= {
26364                month: 28,
26365                year: 365
26366              }[l2] * h2 * d3 - c2 && r2 - 36e5 <= {
26367                month: 31,
26368                year: 366
26369              }[l2] * h2 * d3 + c2 ? w = true : "ytd" === l2 ? (w = m2 - f2 + c2 === r2, A = !g3) : "all" === l2 && (w = o2.max - o2.min >= u12 - p2);
26370              let T2 = !b2 && !(M2 && "all" === l2) && (x2 || k3 || a2), P = M2 && "all" === l2 || !A && w || g3 && t2.frozenStates;
26371              T2 ? v2[i4] = 3 : P && (!S3 || i4 === y2) && (C2 = i4);
26372            }), null !== C2 ? (v2[C2] = 2, t2.setSelected(C2)) : (t2.setSelected(), s2 && (s2.setState(0), s2.attr({
26373              text: (l.lang.rangeSelectorZoom || "") + " \u25BE"
26374            })));
26375            for (let e4 = 0; e4 < v2.length; e4++) {
26376              let o3 = v2[e4], r3 = k2[e4];
26377              if (r3.state !== o3 && (r3.setState(o3), i3)) {
26378                i3.options[e4 + 1].disabled = 3 === o3, 2 === o3 && (s2 && (s2.setState(2), s2.attr({
26379                  text: t2.buttonOptions[e4].text + " \u25BE"
26380                })), i3.selectedIndex = e4 + 1);
26381                let r4 = s2.getBBox();
26382                c(i3, {
26383                  width: `${r4.width}px`,
26384                  height: `${r4.height}px`
26385                });
26386              }
26387            }
26388          }
26389          computeButtonRange(t2) {
26390            let e3 = t2.type, i3 = t2.count || 1, s2 = {
26391              millisecond: 1,
26392              second: 1e3,
26393              minute: 6e4,
26394              hour: 36e5,
26395              day: 864e5,
26396              week: 6048e5
26397            };
26398            s2[e3] ? t2._range = s2[e3] * i3 : ("month" === e3 || "year" === e3) && (t2._range = 24 * {
26399              month: 30,
26400              year: 365
26401            }[e3] * 36e5 * i3), t2._offsetMin = S2(t2.offsetMin, 0), t2._offsetMax = S2(t2.offsetMax, 0), t2._range += t2._offsetMax - t2._offsetMin;
26402          }
26403          getInputValue(t2) {
26404            let e3 = "min" === t2 ? this.minInput : this.maxInput, i3 = this.chart.options.rangeSelector, s2 = this.chart.time;
26405            return e3 ? ("text" === e3.type && i3.inputDateParser || this.defaultInputDateParser)(e3.value, s2.useUTC, s2) : 0;
26406          }
26407          setInputValue(t2, e3) {
26408            let i3 = this.options, s2 = this.chart.time, o2 = "min" === t2 ? this.minInput : this.maxInput, r2 = "min" === t2 ? this.minDateBox : this.maxDateBox;
26409            if (o2) {
26410              let t3 = o2.getAttribute("data-hc-time"), a2 = p(t3) ? Number(t3) : void 0;
26411              if (p(e3)) {
26412                let t4 = a2;
26413                p(t4) && o2.setAttribute("data-hc-time-previous", t4), o2.setAttribute("data-hc-time", e3), a2 = e3;
26414              }
26415              o2.value = s2.dateFormat(this.inputTypeFormats[o2.type] || i3.inputEditDateFormat, a2), r2 && r2.attr({
26416                text: s2.dateFormat(i3.inputDateFormat, a2)
26417              });
26418            }
26419          }
26420          setInputExtremes(t2, e3, i3) {
26421            let s2 = "min" === t2 ? this.minInput : this.maxInput;
26422            if (s2) {
26423              let t3 = this.inputTypeFormats[s2.type], o2 = this.chart.time;
26424              if (t3) {
26425                let r2 = o2.dateFormat(t3, e3);
26426                s2.min !== r2 && (s2.min = r2);
26427                let a2 = o2.dateFormat(t3, i3);
26428                s2.max !== a2 && (s2.max = a2);
26429              }
26430            }
26431          }
26432          showInput(t2) {
26433            let e3 = "min" === t2 ? this.minDateBox : this.maxDateBox, i3 = "min" === t2 ? this.minInput : this.maxInput;
26434            if (i3 && e3 && this.inputGroup) {
26435              let t3 = "text" === i3.type, {
26436                translateX: s2 = 0,
26437                translateY: o2 = 0
26438              } = this.inputGroup, {
26439                x: r2 = 0,
26440                width: a2 = 0,
26441                height: n2 = 0
26442              } = e3, {
26443                inputBoxWidth: l2
26444              } = this.options;
26445              c(i3, {
26446                width: t3 ? a2 + (l2 ? -2 : 20) + "px" : "auto",
26447                height: n2 - 2 + "px",
26448                border: "2px solid silver"
26449              }), t3 && l2 ? c(i3, {
26450                left: s2 + r2 + "px",
26451                top: o2 + "px"
26452              }) : c(i3, {
26453                left: Math.min(Math.round(r2 + s2 - (i3.offsetWidth - a2) / 2), this.chart.chartWidth - i3.offsetWidth) + "px",
26454                top: o2 - (i3.offsetHeight - n2) / 2 + "px"
26455              });
26456            }
26457          }
26458          hideInput(t2) {
26459            let e3 = "min" === t2 ? this.minInput : this.maxInput;
26460            e3 && c(e3, {
26461              top: "-9999em",
26462              border: 0,
26463              width: "1px",
26464              height: "1px"
26465            });
26466          }
26467          defaultInputDateParser(t2, e3, i3) {
26468            let o2 = t2.split("/").join("-").split(" ").join("T");
26469            if (-1 === o2.indexOf("T") && (o2 += "T00:00"), e3) o2 += "Z";
26470            else {
26471              let t3;
26472              if (s.isSafari && !((t3 = o2).length > 6 && (t3.lastIndexOf("-") === t3.length - 6 || t3.lastIndexOf("+") === t3.length - 6))) {
26473                let t4 = new Date(o2).getTimezoneOffset() / 60;
26474                o2 += t4 <= 0 ? `+${v(-t4)}:00` : `-${v(t4)}:00`;
26475              }
26476            }
26477            let r2 = Date.parse(o2);
26478            if (!x(r2)) {
26479              let e4 = t2.split("-");
26480              r2 = Date.UTC(k(e4[0]), k(e4[1]) - 1, k(e4[2]));
26481            }
26482            return i3 && e3 && x(r2) && (r2 += i3.getTimezoneOffset(r2)), r2;
26483          }
26484          drawInput(t2) {
26485            let {
26486              chart: e3,
26487              div: i3,
26488              inputGroup: o2
26489            } = this, r2 = this, a2 = e3.renderer.style || {}, n2 = e3.renderer, h2 = e3.options.rangeSelector, p2 = l.lang, u12 = "min" === t2;
26490            function g2(t3) {
26491              let {
26492                maxInput: i4,
26493                minInput: s2
26494              } = r2, o3 = e3.xAxis[0], a3 = e3.scroller?.getUnionExtremes() || o3, n3 = a3.dataMin, l2 = a3.dataMax, h3 = e3.xAxis[0].getExtremes()[t3], d2 = r2.getInputValue(t3);
26495              x(d2) && d2 !== h3 && (u12 && i4 && x(n3) ? d2 > Number(i4.getAttribute("data-hc-time")) ? d2 = void 0 : d2 < n3 && (d2 = n3) : s2 && x(l2) && (d2 < Number(s2.getAttribute("data-hc-time")) ? d2 = void 0 : d2 > l2 && (d2 = l2)), void 0 !== d2 && o3.setExtremes(u12 ? d2 : o3.min, u12 ? o3.max : d2, void 0, void 0, {
26496                trigger: "rangeSelectorInput"
26497              }));
26498            }
26499            let m2 = p2[u12 ? "rangeSelectorFrom" : "rangeSelectorTo"] || "", b2 = n2.label(m2, 0).addClass("highcharts-range-label").attr({
26500              padding: m2 ? 2 : 0,
26501              height: m2 ? h2.inputBoxHeight : 0
26502            }).add(o2), v2 = n2.label("", 0).addClass("highcharts-range-input").attr({
26503              padding: 2,
26504              width: h2.inputBoxWidth,
26505              height: h2.inputBoxHeight,
26506              "text-align": "center"
26507            }).on("click", function() {
26508              r2.showInput(t2), r2[t2 + "Input"].focus();
26509            });
26510            e3.styledMode || v2.attr({
26511              stroke: h2.inputBoxBorderColor,
26512              "stroke-width": 1
26513            }), v2.add(o2);
26514            let S3 = d("input", {
26515              name: t2,
26516              className: "highcharts-range-selector"
26517            }, void 0, i3);
26518            S3.setAttribute("type", function(t3) {
26519              if (-1 !== t3.indexOf("%L")) return "text";
26520              let e4 = ["a", "A", "d", "e", "w", "b", "B", "m", "o", "y", "Y"].some((e5) => -1 !== t3.indexOf("%" + e5)), i4 = ["H", "k", "I", "l", "M", "S"].some((e5) => -1 !== t3.indexOf("%" + e5));
26521              return e4 && i4 ? "datetime-local" : e4 ? "date" : i4 ? "time" : "text";
26522            }(h2.inputDateFormat || "%e %b %Y")), e3.styledMode || (b2.css(y(a2, h2.labelStyle)), v2.css(y({
26523              color: "#333333"
26524            }, a2, h2.inputStyle)), c(S3, f({
26525              position: "absolute",
26526              border: 0,
26527              boxShadow: "0 0 15px rgba(0,0,0,0.3)",
26528              width: "1px",
26529              height: "1px",
26530              padding: 0,
26531              textAlign: "center",
26532              fontSize: a2.fontSize,
26533              fontFamily: a2.fontFamily,
26534              top: "-9999em"
26535            }, h2.inputStyle))), S3.onfocus = () => {
26536              r2.showInput(t2);
26537            }, S3.onblur = () => {
26538              S3 === s.doc.activeElement && g2(t2), r2.hideInput(t2), r2.setInputValue(t2), S3.blur();
26539            };
26540            let k2 = false;
26541            return S3.onchange = () => {
26542              k2 || (g2(t2), r2.hideInput(t2), S3.blur());
26543            }, S3.onkeypress = (e4) => {
26544              13 === e4.keyCode && g2(t2);
26545            }, S3.onkeydown = (e4) => {
26546              k2 = true, ("ArrowUp" === e4.key || "ArrowDown" === e4.key || "Tab" === e4.key) && g2(t2);
26547            }, S3.onkeyup = () => {
26548              k2 = false;
26549            }, {
26550              dateBox: v2,
26551              input: S3,
26552              label: b2
26553            };
26554          }
26555          getPosition() {
26556            let t2 = this.chart, e3 = t2.options.rangeSelector, i3 = "top" === e3.verticalAlign ? t2.plotTop - t2.axisOffset[0] : 0;
26557            return {
26558              buttonTop: i3 + e3.buttonPosition.y,
26559              inputTop: i3 + e3.inputPosition.y - 10
26560            };
26561          }
26562          getYTDExtremes(t2, e3, i3) {
26563            let s2 = this.chart.time, o2 = new s2.Date(t2), r2 = s2.get("FullYear", o2), a2 = Math.max(e3, i3 ? s2.Date.UTC(r2, 0, 1) : +new s2.Date(r2, 0, 1)), n2 = o2.getTime();
26564            return {
26565              max: Math.min(t2 || n2, n2),
26566              min: a2
26567            };
26568          }
26569          createElements() {
26570            let t2 = this.chart, e3 = t2.renderer, i3 = t2.container, s2 = t2.options, o2 = s2.rangeSelector, r2 = o2.inputEnabled, a2 = S2(s2.chart.style?.zIndex, 0) + 1;
26571            if (false !== o2.enabled && (this.group = e3.g("range-selector-group").attr({
26572              zIndex: 7
26573            }).add(), this.div = d("div", void 0, {
26574              position: "relative",
26575              height: 0,
26576              zIndex: a2
26577            }), this.buttonOptions.length && this.renderButtons(), i3.parentNode && i3.parentNode.insertBefore(this.div, i3), r2)) {
26578              this.inputGroup = e3.g("input-group").add(this.group);
26579              let t3 = this.drawInput("min");
26580              this.minDateBox = t3.dateBox, this.minLabel = t3.label, this.minInput = t3.input;
26581              let i4 = this.drawInput("max");
26582              this.maxDateBox = i4.dateBox, this.maxLabel = i4.label, this.maxInput = i4.input;
26583            }
26584          }
26585          render(t2, e3) {
26586            let i3 = this.chart, s2 = i3.options.rangeSelector, o2 = s2.inputEnabled;
26587            if (false !== s2.enabled) {
26588              if (o2) {
26589                this.setInputValue("min", t2), this.setInputValue("max", e3);
26590                let o3 = i3.scroller && i3.scroller.getUnionExtremes() || i3.xAxis[0] || {};
26591                if (p(o3.dataMin) && p(o3.dataMax)) {
26592                  let t3 = i3.xAxis[0].minRange || 0;
26593                  this.setInputExtremes("min", o3.dataMin, Math.min(o3.dataMax, this.getInputValue("max")) - t3), this.setInputExtremes("max", Math.max(o3.dataMin, this.getInputValue("min")) + t3, o3.dataMax);
26594                }
26595                if (this.inputGroup) {
26596                  let t3 = 0;
26597                  [this.minLabel, this.minDateBox, this.maxLabel, this.maxDateBox].forEach((e4) => {
26598                    if (e4) {
26599                      let {
26600                        width: i4
26601                      } = e4.getBBox();
26602                      i4 && (e4.attr({
26603                        x: t3
26604                      }), t3 += i4 + s2.inputSpacing);
26605                    }
26606                  });
26607                }
26608              }
26609              this.alignElements(), this.updateButtonStates();
26610            }
26611          }
26612          renderButtons() {
26613            let {
26614              buttons: t2,
26615              chart: e3,
26616              options: i3
26617            } = this, o2 = l.lang, r2 = e3.renderer, a2 = y(i3.buttonTheme), n2 = a2 && a2.states, c2 = a2.width || 28;
26618            delete a2.width, delete a2.states, this.buttonGroup = r2.g("range-selector-buttons").add(this.group);
26619            let p2 = this.dropdown = d("select", void 0, {
26620              position: "absolute",
26621              padding: 0,
26622              border: 0,
26623              cursor: "pointer",
26624              opacity: 1e-4
26625            }, this.div), u12 = e3.userOptions.rangeSelector?.buttonTheme;
26626            this.dropdownLabel = r2.button("", 0, 0, () => {
26627            }, y(a2, {
26628              "stroke-width": S2(a2["stroke-width"], 0),
26629              width: "auto",
26630              paddingLeft: S2(i3.buttonTheme.paddingLeft, u12?.padding, 8),
26631              paddingRight: S2(i3.buttonTheme.paddingRight, u12?.padding, 8)
26632            }), n2 && n2.hover, n2 && n2.select, n2 && n2.disabled).hide().add(this.group), h(p2, "touchstart", () => {
26633              p2.style.fontSize = "16px";
26634            });
26635            let g2 = s.isMS ? "mouseover" : "mouseenter", f2 = s.isMS ? "mouseout" : "mouseleave";
26636            h(p2, g2, () => {
26637              m(this.dropdownLabel.element, g2);
26638            }), h(p2, f2, () => {
26639              m(this.dropdownLabel.element, f2);
26640            }), h(p2, "change", () => {
26641              m(this.buttons[p2.selectedIndex - 1].element, "click");
26642            }), this.zoomText = r2.label(o2.rangeSelectorZoom || "", 0).attr({
26643              padding: i3.buttonTheme.padding,
26644              height: i3.buttonTheme.height,
26645              paddingLeft: 0,
26646              paddingRight: 0
26647            }).add(this.buttonGroup), this.chart.styledMode || (this.zoomText.css(i3.labelStyle), a2["stroke-width"] = S2(a2["stroke-width"], 0)), d("option", {
26648              textContent: this.zoomText.textStr,
26649              disabled: true
26650            }, void 0, p2), this.buttonOptions.forEach((e4, i4) => {
26651              d("option", {
26652                textContent: e4.title || e4.text
26653              }, void 0, p2), t2[i4] = r2.button(e4.text, 0, 0, (t3) => {
26654                let s2;
26655                let o3 = e4.events && e4.events.click;
26656                o3 && (s2 = o3.call(e4, t3)), false !== s2 && this.clickButton(i4), this.isActive = true;
26657              }, a2, n2 && n2.hover, n2 && n2.select, n2 && n2.disabled).attr({
26658                "text-align": "center",
26659                width: c2
26660              }).add(this.buttonGroup), e4.title && t2[i4].attr("title", e4.title);
26661            });
26662          }
26663          alignElements() {
26664            let {
26665              buttonGroup: t2,
26666              buttons: e3,
26667              chart: i3,
26668              group: s2,
26669              inputGroup: o2,
26670              options: r2,
26671              zoomText: a2
26672            } = this, n2 = i3.options, l2 = n2.exporting && false !== n2.exporting.enabled && n2.navigation && n2.navigation.buttonOptions, {
26673              buttonPosition: h2,
26674              inputPosition: d2,
26675              verticalAlign: c2
26676            } = r2, p2 = (t3, e4) => l2 && this.titleCollision(i3) && "top" === c2 && "right" === e4.align && e4.y - t3.getBBox().height - 12 < (l2.y || 0) + (l2.height || 0) + i3.spacing[0] ? -40 : 0, u12 = i3.plotLeft;
26677            if (s2 && h2 && d2) {
26678              let n3 = h2.x - i3.spacing[3];
26679              if (t2) {
26680                if (this.positionButtons(), !this.initialButtonGroupWidth) {
26681                  let t3 = 0;
26682                  a2 && (t3 += a2.getBBox().width + 5), e3.forEach((i4, s3) => {
26683                    t3 += i4.width || 0, s3 !== e3.length - 1 && (t3 += r2.buttonSpacing);
26684                  }), this.initialButtonGroupWidth = t3;
26685                }
26686                u12 -= i3.spacing[3];
26687                let o3 = p2(t2, h2);
26688                this.alignButtonGroup(o3), this.buttonGroup?.translateY && this.dropdownLabel.attr({
26689                  y: this.buttonGroup.translateY
26690                }), s2.placed = t2.placed = i3.hasLoaded;
26691              }
26692              let l3 = 0;
26693              o2 && (l3 = p2(o2, d2), "left" === d2.align ? n3 = u12 : "right" === d2.align && (n3 = -Math.max(i3.axisOffset[1], -l3)), o2.align({
26694                y: d2.y,
26695                width: o2.getBBox().width,
26696                align: d2.align,
26697                x: d2.x + n3 - 2
26698              }, true, i3.spacingBox), o2.placed = i3.hasLoaded), this.handleCollision(l3), s2.align({
26699                verticalAlign: c2
26700              }, true, i3.spacingBox);
26701              let g2 = s2.alignAttr.translateY, f2 = s2.getBBox().height + 20, m2 = 0;
26702              if ("bottom" === c2) {
26703                let t3 = i3.legend && i3.legend.options;
26704                m2 = g2 - (f2 = f2 + (t3 && "bottom" === t3.verticalAlign && t3.enabled && !t3.floating ? i3.legend.legendHeight + S2(t3.margin, 10) : 0) - 20) - (r2.floating ? 0 : r2.y) - (i3.titleOffset ? i3.titleOffset[2] : 0) - 10;
26705              }
26706              "top" === c2 ? (r2.floating && (m2 = 0), i3.titleOffset && i3.titleOffset[0] && (m2 = i3.titleOffset[0]), m2 += i3.margin[0] - i3.spacing[0] || 0) : "middle" === c2 && (d2.y === h2.y ? m2 = g2 : (d2.y || h2.y) && (d2.y < 0 || h2.y < 0 ? m2 -= Math.min(d2.y, h2.y) : m2 = g2 - f2)), s2.translate(r2.x, r2.y + Math.floor(m2));
26707              let {
26708                minInput: x2,
26709                maxInput: y2,
26710                dropdown: b2
26711              } = this;
26712              r2.inputEnabled && x2 && y2 && (x2.style.marginTop = s2.translateY + "px", y2.style.marginTop = s2.translateY + "px"), b2 && (b2.style.marginTop = s2.translateY + "px");
26713            }
26714          }
26715          alignButtonGroup(t2, e3) {
26716            let {
26717              chart: i3,
26718              options: s2,
26719              buttonGroup: o2
26720            } = this, {
26721              buttonPosition: r2
26722            } = s2, a2 = i3.plotLeft - i3.spacing[3], n2 = r2.x - i3.spacing[3];
26723            "right" === r2.align ? n2 += t2 - a2 : "center" === r2.align && (n2 -= a2 / 2), o2 && o2.align({
26724              y: r2.y,
26725              width: S2(e3, this.initialButtonGroupWidth),
26726              align: r2.align,
26727              x: n2
26728            }, true, i3.spacingBox);
26729          }
26730          positionButtons() {
26731            let {
26732              buttons: t2,
26733              chart: e3,
26734              options: i3,
26735              zoomText: s2
26736            } = this, o2 = e3.hasLoaded ? "animate" : "attr", {
26737              buttonPosition: r2
26738            } = i3, a2 = e3.plotLeft, n2 = a2;
26739            s2 && "hidden" !== s2.visibility && (s2[o2]({
26740              x: S2(a2 + r2.x, a2)
26741            }), n2 += r2.x + s2.getBBox().width + 5);
26742            for (let e4 = 0, s3 = this.buttonOptions.length; e4 < s3; ++e4) "hidden" !== t2[e4].visibility ? (t2[e4][o2]({
26743              x: n2
26744            }), n2 += (t2[e4].width || 0) + i3.buttonSpacing) : t2[e4][o2]({
26745              x: a2
26746            });
26747          }
26748          handleCollision(t2) {
26749            let {
26750              chart: e3,
26751              buttonGroup: i3,
26752              inputGroup: s2
26753            } = this, {
26754              buttonPosition: o2,
26755              dropdown: r2,
26756              inputPosition: a2
26757            } = this.options, n2 = () => {
26758              let t3 = 0;
26759              return this.buttons.forEach((e4) => {
26760                let i4 = e4.getBBox();
26761                i4.width > t3 && (t3 = i4.width);
26762              }), t3;
26763            }, l2 = (e4) => {
26764              if (s2?.alignOptions && i3) {
26765                let r3 = s2.alignAttr.translateX + s2.alignOptions.x - t2 + s2.getBBox().x + 2, n3 = s2.alignOptions.width || 0, l3 = i3.alignAttr.translateX + i3.getBBox().x;
26766                return l3 + e4 > r3 && r3 + n3 > l3 && o2.y < a2.y + s2.getBBox().height;
26767              }
26768              return false;
26769            }, h2 = () => {
26770              s2 && i3 && s2.attr({
26771                translateX: s2.alignAttr.translateX + (e3.axisOffset[1] >= -t2 ? 0 : -t2),
26772                translateY: s2.alignAttr.translateY + i3.getBBox().height + 10
26773              });
26774            };
26775            if (i3) {
26776              if ("always" === r2) {
26777                this.collapseButtons(), l2(n2()) && h2();
26778                return;
26779              }
26780              "never" === r2 && this.expandButtons();
26781            }
26782            s2 && i3 ? a2.align === o2.align || l2(this.initialButtonGroupWidth + 20) ? "responsive" === r2 ? (this.collapseButtons(), l2(n2()) && h2()) : h2() : "responsive" === r2 && this.expandButtons() : i3 && "responsive" === r2 && (this.initialButtonGroupWidth > e3.plotWidth ? this.collapseButtons() : this.expandButtons());
26783          }
26784          collapseButtons() {
26785            let {
26786              buttons: t2,
26787              zoomText: e3
26788            } = this;
26789            true !== this.isCollapsed && (this.isCollapsed = true, e3.hide(), t2.forEach((t3) => void t3.hide()), this.showDropdown());
26790          }
26791          expandButtons() {
26792            let {
26793              buttons: t2,
26794              zoomText: e3
26795            } = this;
26796            false !== this.isCollapsed && (this.isCollapsed = false, this.hideDropdown(), e3.show(), t2.forEach((t3) => void t3.show()), this.positionButtons());
26797          }
26798          showDropdown() {
26799            let {
26800              buttonGroup: t2,
26801              chart: e3,
26802              dropdownLabel: i3,
26803              dropdown: s2
26804            } = this;
26805            if (t2 && s2) {
26806              let {
26807                translateX: o2 = 0,
26808                translateY: r2 = 0
26809              } = t2, a2 = e3.plotLeft + o2;
26810              i3.attr({
26811                x: a2,
26812                y: r2
26813              }).show(), c(s2, {
26814                left: a2 + "px",
26815                top: r2 + "px",
26816                visibility: "inherit"
26817              }), this.hasVisibleDropdown = true;
26818            }
26819          }
26820          hideDropdown() {
26821            let {
26822              dropdown: t2
26823            } = this;
26824            t2 && (this.dropdownLabel.hide(), c(t2, {
26825              visibility: "hidden",
26826              width: "1px",
26827              height: "1px"
26828            }), this.hasVisibleDropdown = false);
26829          }
26830          getHeight() {
26831            let t2 = this.options, e3 = this.group, i3 = t2.inputPosition, s2 = t2.buttonPosition, o2 = t2.y, r2 = s2.y, a2 = i3.y, n2 = 0;
26832            if (t2.height) return t2.height;
26833            this.alignElements(), n2 = e3 ? e3.getBBox(true).height + 13 + o2 : 0;
26834            let l2 = Math.min(a2, r2);
26835            return (a2 < 0 && r2 < 0 || a2 > 0 && r2 > 0) && (n2 += Math.abs(l2)), n2;
26836          }
26837          titleCollision(t2) {
26838            return !(t2.options.title.text || t2.options.subtitle.text);
26839          }
26840          update(t2, e3 = true) {
26841            let i3 = this.chart;
26842            y(true, i3.options.rangeSelector, t2), this.destroy(), this.init(i3), e3 && this.render();
26843          }
26844          destroy() {
26845            let e3 = this, i3 = e3.minInput, s2 = e3.maxInput;
26846            e3.eventsToUnbind && (e3.eventsToUnbind.forEach((t2) => t2()), e3.eventsToUnbind = void 0), u11(e3.buttons), i3 && (i3.onfocus = i3.onblur = i3.onchange = null), s2 && (s2.onfocus = s2.onblur = s2.onchange = null), b(e3, function(i4, s3) {
26847              i4 && "chart" !== s3 && (i4 instanceof r ? i4.destroy() : i4 instanceof t.HTMLElement && g(i4)), i4 !== C.prototype[s3] && (e3[s3] = null);
26848            }, this);
26849          }
26850        }
26851        return f(C.prototype, {
26852          defaultButtons: [{
26853            type: "month",
26854            count: 1,
26855            text: "1m",
26856            title: "View 1 month"
26857          }, {
26858            type: "month",
26859            count: 3,
26860            text: "3m",
26861            title: "View 3 months"
26862          }, {
26863            type: "month",
26864            count: 6,
26865            text: "6m",
26866            title: "View 6 months"
26867          }, {
26868            type: "ytd",
26869            text: "YTD",
26870            title: "View year to date"
26871          }, {
26872            type: "year",
26873            count: 1,
26874            text: "1y",
26875            title: "View 1 year"
26876          }, {
26877            type: "all",
26878            text: "All",
26879            title: "View all"
26880          }],
26881          inputTypeFormats: {
26882            "datetime-local": "%Y-%m-%dT%H:%M:%S",
26883            date: "%Y-%m-%d",
26884            time: "%H:%M:%S"
26885          }
26886        }), C;
26887      }), i(e, "Core/Chart/StockChart.js", [e["Core/Chart/Chart.js"], e["Core/Templating.js"], e["Core/Defaults.js"], e["Stock/Navigator/NavigatorDefaults.js"], e["Stock/RangeSelector/RangeSelectorDefaults.js"], e["Stock/Scrollbar/ScrollbarDefaults.js"], e["Stock/Utilities/StockUtilities.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o, r, a, n) {
26888        let {
26889          format: l
26890        } = e2, {
26891          getOptions: h
26892        } = i2, {
26893          setFixedRange: d
26894        } = a, {
26895          addEvent: c,
26896          clamp: p,
26897          crisp: u11,
26898          defined: g,
26899          extend: f,
26900          find: m,
26901          isNumber: x,
26902          isString: y,
26903          merge: b,
26904          pick: v,
26905          splat: S2
26906        } = n;
26907        function k(t3, e3, i3) {
26908          return "xAxis" === t3 ? {
26909            minPadding: 0,
26910            maxPadding: 0,
26911            overscroll: 0,
26912            ordinal: true
26913          } : "yAxis" === t3 ? {
26914            labels: {
26915              y: -2
26916            },
26917            opposite: i3.opposite ?? e3.opposite ?? true,
26918            showLastLabel: !!(e3.categories || "category" === e3.type),
26919            title: {
26920              text: i3.title?.text !== "Values" ? i3.title?.text : null
26921            }
26922          } : {};
26923        }
26924        function M(t3, e3) {
26925          if ("xAxis" === t3) {
26926            let t4 = v(e3.navigator && e3.navigator.enabled, s.enabled, true), i3 = {
26927              type: "datetime",
26928              categories: void 0
26929            };
26930            return t4 && (i3.startOnTick = false, i3.endOnTick = false), i3;
26931          }
26932          return {};
26933        }
26934        class C extends t2 {
26935          init(t3, e3) {
26936            let i3 = h(), a2 = t3.xAxis, n2 = t3.yAxis, l2 = v(t3.navigator && t3.navigator.enabled, s.enabled, true);
26937            t3.xAxis = t3.yAxis = void 0;
26938            let d2 = b({
26939              chart: {
26940                panning: {
26941                  enabled: true,
26942                  type: "x"
26943                },
26944                zooming: {
26945                  pinchType: "x",
26946                  mouseWheel: {
26947                    type: "x"
26948                  }
26949                }
26950              },
26951              navigator: {
26952                enabled: l2
26953              },
26954              scrollbar: {
26955                enabled: v(r.enabled, true)
26956              },
26957              rangeSelector: {
26958                enabled: v(o.rangeSelector.enabled, true)
26959              },
26960              title: {
26961                text: null
26962              },
26963              tooltip: {
26964                split: v(i3.tooltip && i3.tooltip.split, true),
26965                crosshairs: true
26966              },
26967              legend: {
26968                enabled: false
26969              }
26970            }, t3, {
26971              isStock: true
26972            });
26973            t3.xAxis = a2, t3.yAxis = n2, d2.xAxis = S2(t3.xAxis || {}).map((e4) => b(k("xAxis", e4, i3.xAxis), e4, M("xAxis", t3))), d2.yAxis = S2(t3.yAxis || {}).map((t4) => b(k("yAxis", t4, i3.yAxis), t4)), super.init(d2, e3);
26974          }
26975          createAxis(t3, e3) {
26976            return e3.axis = b(k(t3, e3.axis, h()[t3]), e3.axis, M(t3, this.userOptions)), super.createAxis(t3, e3);
26977          }
26978        }
26979        return c(t2, "update", function(t3) {
26980          let e3 = t3.options;
26981          "scrollbar" in e3 && this.navigator && (b(true, this.options.scrollbar, e3.scrollbar), this.navigator.update({
26982            enabled: !!this.navigator.navigatorEnabled
26983          }), delete e3.scrollbar);
26984        }), function(t3) {
26985          function e3(t4) {
26986            if (!this.crosshair || !this.crosshair.label || !this.crosshair.label.enabled || !this.cross || !x(this.min) || !x(this.max)) return;
26987            let e4 = this.chart, i4 = this.logarithmic, s3 = this.crosshair.label, o3 = this.horiz, r3 = this.opposite, a3 = this.left, n3 = this.top, h3 = this.width, d2 = "inside" === this.options.tickPosition, c2 = false !== this.crosshair.snap, p2 = t4.e || this.cross && this.cross.e, u12 = t4.point, g2 = this.crossLabel, m2, y2, b2 = s3.format, S3 = "", k2, M2 = 0, C2 = this.min, A = this.max;
26988            i4 && (C2 = i4.lin2log(this.min), A = i4.lin2log(this.max));
26989            let w = o3 ? "center" : r3 ? "right" === this.labelAlign ? "right" : "left" : "left" === this.labelAlign ? "left" : "center";
26990            g2 || (g2 = this.crossLabel = e4.renderer.label("", 0, void 0, s3.shape || "callout").addClass("highcharts-crosshair-label highcharts-color-" + (u12 && u12.series ? u12.series.colorIndex : this.series[0] && this.series[0].colorIndex)).attr({
26991              align: s3.align || w,
26992              padding: v(s3.padding, 8),
26993              r: v(s3.borderRadius, 3),
26994              zIndex: 2
26995            }).add(this.labelGroup), e4.styledMode || g2.attr({
26996              fill: s3.backgroundColor || u12 && u12.series && u12.series.color || "#666666",
26997              stroke: s3.borderColor || "",
26998              "stroke-width": s3.borderWidth || 0
26999            }).css(f({
27000              color: "#ffffff",
27001              fontWeight: "normal",
27002              fontSize: "0.7em",
27003              textAlign: "center"
27004            }, s3.style || {}))), o3 ? (m2 = c2 ? (u12.plotX || 0) + a3 : p2.chartX, y2 = n3 + (r3 ? 0 : this.height)) : (m2 = a3 + this.offset + (r3 ? h3 : 0), y2 = c2 ? (u12.plotY || 0) + n3 : p2.chartY), b2 || s3.formatter || (this.dateTime && (S3 = "%b %d, %Y"), b2 = "{value" + (S3 ? ":" + S3 : "") + "}");
27005            let T2 = c2 ? this.isXAxis ? u12.x : u12.y : this.toValue(o3 ? p2.chartX : p2.chartY), P = u12 && u12.series ? u12.series.isPointInside(u12) : x(T2) && T2 > C2 && T2 < A, O = "";
27006            b2 ? O = l(b2, {
27007              value: T2
27008            }, e4) : s3.formatter && x(T2) && (O = s3.formatter.call(this, T2)), g2.attr({
27009              text: O,
27010              x: m2,
27011              y: y2,
27012              visibility: P ? "inherit" : "hidden"
27013            });
27014            let L = g2.getBBox();
27015            !x(g2.x) || o3 || r3 || (m2 = g2.x - L.width / 2), x(g2.y) && (o3 ? (d2 && !r3 || !d2 && r3) && (y2 = g2.y - L.height) : y2 = g2.y - L.height / 2), k2 = o3 ? {
27016              left: a3,
27017              right: a3 + this.width
27018            } : {
27019              left: "left" === this.labelAlign ? a3 : 0,
27020              right: "right" === this.labelAlign ? a3 + this.width : e4.chartWidth
27021            };
27022            let D2 = g2.translateX || 0;
27023            D2 < k2.left && (M2 = k2.left - D2), D2 + L.width >= k2.right && (M2 = -(D2 + L.width - k2.right)), g2.attr({
27024              x: m2 + M2,
27025              y: y2,
27026              anchorX: o3 ? m2 : this.opposite ? 0 : e4.chartWidth,
27027              anchorY: o3 ? this.opposite ? e4.chartHeight : 0 : y2 + L.height / 2
27028            });
27029          }
27030          function i3() {
27031            this.crossLabel && (this.crossLabel = this.crossLabel.hide());
27032          }
27033          function s2(t4) {
27034            let e4 = this.chart, i4 = this.options, s3 = e4._labelPanes = e4._labelPanes || {}, o3 = i4.labels;
27035            if (e4.options.isStock && "yAxis" === this.coll) {
27036              let e5 = i4.top + "," + i4.height;
27037              !s3[e5] && o3.enabled && (15 === o3.distance && 1 === this.side && (o3.distance = 0), void 0 === o3.align && (o3.align = "right"), s3[e5] = this, t4.align = "right", t4.preventDefault());
27038            }
27039          }
27040          function o2() {
27041            let t4 = this.chart, e4 = this.options && this.options.top + "," + this.options.height;
27042            e4 && t4._labelPanes && t4._labelPanes[e4] === this && delete t4._labelPanes[e4];
27043          }
27044          function r2(t4) {
27045            let e4 = this, i4 = e4.isLinked && !e4.series && e4.linkedParent ? e4.linkedParent.series : e4.series, s3 = e4.chart, o3 = s3.renderer, r3 = e4.left, a3 = e4.top, n3 = [], l2 = t4.translatedValue, h3 = t4.value, d2 = t4.force, c2, u12, f2, b2, S3 = [], k2, M2;
27046            if (s3.options.isStock && false !== t4.acrossPanes && "xAxis" === e4.coll || "yAxis" === e4.coll) {
27047              for (let o4 of (t4.preventDefault(), S3 = ((t5) => {
27048                let o5 = "xAxis" === t5 ? "yAxis" : "xAxis", r4 = e4.options[o5];
27049                return x(r4) ? [s3[o5][r4]] : y(r4) ? [s3.get(r4)] : i4.map((t6) => t6[o5]);
27050              })(e4.coll), e4.isXAxis ? s3.yAxis : s3.xAxis)) if (!o4.options.isInternal) {
27051                let t5 = o4.isXAxis ? "yAxis" : "xAxis";
27052                e4 === (g(o4.options[t5]) ? s3[t5][o4.options[t5]] : s3[t5][0]) && S3.push(o4);
27053              }
27054              for (let t5 of (k2 = S3.length ? [] : [e4.isXAxis ? s3.yAxis[0] : s3.xAxis[0]], S3)) -1 !== k2.indexOf(t5) || m(k2, (e5) => e5.pos === t5.pos && e5.len === t5.len) || k2.push(t5);
27055              if (x(M2 = v(l2, e4.translate(h3 || 0, void 0, void 0, t4.old)))) {
27056                if (e4.horiz) for (let t5 of k2) {
27057                  let i5;
27058                  b2 = (u12 = t5.pos) + t5.len, c2 = f2 = Math.round(M2 + e4.transB), "pass" !== d2 && (c2 < r3 || c2 > r3 + e4.width) && (d2 ? c2 = f2 = p(c2, r3, r3 + e4.width) : i5 = true), i5 || n3.push(["M", c2, u12], ["L", f2, b2]);
27059                }
27060                else for (let t5 of k2) {
27061                  let i5;
27062                  f2 = (c2 = t5.pos) + t5.len, u12 = b2 = Math.round(a3 + e4.height - M2), "pass" !== d2 && (u12 < a3 || u12 > a3 + e4.height) && (d2 ? u12 = b2 = p(u12, a3, a3 + e4.height) : i5 = true), i5 || n3.push(["M", c2, u12], ["L", f2, b2]);
27063                }
27064              }
27065              t4.path = n3.length > 0 ? o3.crispPolyLine(n3, t4.lineWidth || 1) : void 0;
27066            }
27067          }
27068          function a2(t4) {
27069            if (this.chart.options.isStock) {
27070              let e4;
27071              this.is("column") || this.is("columnrange") ? e4 = {
27072                borderWidth: 0,
27073                shadow: false
27074              } : this.is("scatter") || this.is("sma") || (e4 = {
27075                marker: {
27076                  enabled: false,
27077                  radius: 2
27078                }
27079              }), e4 && (t4.plotOptions[this.type] = b(t4.plotOptions[this.type], e4));
27080            }
27081          }
27082          function n2() {
27083            let t4 = this.chart, e4 = this.options.dataGrouping;
27084            return false !== this.allowDG && e4 && v(e4.enabled, t4.options.isStock);
27085          }
27086          function h2(t4, e4) {
27087            for (let i4 = 0; i4 < t4.length; i4 += 2) {
27088              let s3 = t4[i4], o3 = t4[i4 + 1];
27089              g(s3[1]) && s3[1] === o3[1] && (s3[1] = o3[1] = u11(s3[1], e4)), g(s3[2]) && s3[2] === o3[2] && (s3[2] = o3[2] = u11(s3[2], e4));
27090            }
27091            return t4;
27092          }
27093          t3.compose = function(t4, l2, p2, u12) {
27094            let g2 = p2.prototype;
27095            g2.forceCropping || (c(l2, "afterDrawCrosshair", e3), c(l2, "afterHideCrosshair", i3), c(l2, "autoLabelAlign", s2), c(l2, "destroy", o2), c(l2, "getPlotLinePath", r2), t4.prototype.setFixedRange = d, g2.forceCropping = n2, c(p2, "setOptions", a2), u12.prototype.crispPolyLine = h2);
27096          }, t3.stockChart = function(e4, i4, s3) {
27097            return new t3(e4, i4, s3);
27098          };
27099        }(C || (C = {})), C;
27100      }), i(e, "Series/HLC/HLCPoint.js", [e["Core/Series/SeriesRegistry.js"]], function(t2) {
27101        let {
27102          column: {
27103            prototype: {
27104              pointClass: e2
27105            }
27106          }
27107        } = t2.seriesTypes;
27108        return class extends e2 {
27109        };
27110      }), i(e, "Series/HLC/HLCSeriesDefaults.js", [], function() {
27111        return {
27112          lineWidth: 1,
27113          tooltip: {
27114            pointFormat: '<span style="color:{point.color}">\u25CF</span> <b> {series.name}</b><br/>High: {point.high}<br/>Low: {point.low}<br/>Close: {point.close}<br/>'
27115          },
27116          threshold: null,
27117          states: {
27118            hover: {
27119              lineWidth: 3
27120            }
27121          },
27122          stickyTracking: true
27123        };
27124      }), i(e, "Series/HLC/HLCSeries.js", [e["Series/HLC/HLCPoint.js"], e["Series/HLC/HLCSeriesDefaults.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
27125        let {
27126          column: o
27127        } = i2.seriesTypes, {
27128          crisp: r,
27129          extend: a,
27130          merge: n
27131        } = s;
27132        class l extends o {
27133          extendStem(t3, e3, i3) {
27134            let s2 = t3[0], o2 = t3[1];
27135            "number" == typeof s2[2] && (s2[2] = Math.max(i3 + e3, s2[2])), "number" == typeof o2[2] && (o2[2] = Math.min(i3 - e3, o2[2]));
27136          }
27137          getPointPath(t3, e3) {
27138            let i3 = e3.strokeWidth(), s2 = t3.series, o2 = r(t3.plotX || 0, i3), a2 = Math.round(t3.shapeArgs.width / 2), n2 = [["M", o2, Math.round(t3.yBottom)], ["L", o2, Math.round(t3.plotHigh)]];
27139            if (null !== t3.close) {
27140              let e4 = r(t3.plotClose, i3);
27141              n2.push(["M", o2, e4], ["L", o2 + a2, e4]), s2.extendStem(n2, i3 / 2, e4);
27142            }
27143            return n2;
27144          }
27145          drawSinglePoint(t3) {
27146            let e3 = t3.series, i3 = e3.chart, s2, o2 = t3.graphic;
27147            void 0 !== t3.plotY && (o2 || (t3.graphic = o2 = i3.renderer.path().add(e3.group)), i3.styledMode || o2.attr(e3.pointAttribs(t3, t3.selected && "select")), s2 = e3.getPointPath(t3, o2), o2[o2 ? "animate" : "attr"]({
27148              d: s2
27149            }).addClass(t3.getClassName(), true));
27150          }
27151          drawPoints() {
27152            this.points.forEach(this.drawSinglePoint);
27153          }
27154          init() {
27155            super.init.apply(this, arguments), this.options.stacking = void 0;
27156          }
27157          pointAttribs(t3, e3) {
27158            let i3 = super.pointAttribs.call(this, t3, e3);
27159            return delete i3.fill, i3;
27160          }
27161          toYData(t3) {
27162            return [t3.high, t3.low, t3.close];
27163          }
27164          translate() {
27165            let t3 = this, e3 = t3.yAxis, i3 = this.pointArrayMap && this.pointArrayMap.slice() || [], s2 = i3.map((t4) => `plot${t4.charAt(0).toUpperCase() + t4.slice(1)}`);
27166            s2.push("yBottom"), i3.push("low"), super.translate.apply(t3), t3.points.forEach(function(o2) {
27167              i3.forEach(function(i4, r2) {
27168                let a2 = o2[i4];
27169                null !== a2 && (t3.dataModify && (a2 = t3.dataModify.modifyValue(a2)), o2[s2[r2]] = e3.toPixels(a2, true));
27170              }), o2.tooltipPos[1] = o2.plotHigh + e3.pos - t3.chart.plotTop;
27171            });
27172          }
27173        }
27174        return l.defaultOptions = n(o.defaultOptions, e2), a(l.prototype, {
27175          pointClass: t2,
27176          animate: null,
27177          directTouch: false,
27178          pointArrayMap: ["high", "low", "close"],
27179          pointAttrToOptions: {
27180            stroke: "color",
27181            "stroke-width": "lineWidth"
27182          },
27183          pointValKey: "close"
27184        }), i2.registerSeriesType("hlc", l), l;
27185      }), i(e, "Series/OHLC/OHLCPoint.js", [e["Core/Series/SeriesRegistry.js"]], function(t2) {
27186        let {
27187          seriesTypes: {
27188            hlc: e2
27189          }
27190        } = t2;
27191        class i2 extends e2.prototype.pointClass {
27192          getClassName() {
27193            return super.getClassName.call(this) + (this.open < this.close ? " highcharts-point-up" : " highcharts-point-down");
27194          }
27195          resolveUpColor() {
27196            this.open < this.close && !this.options.color && this.series.options.upColor && (this.color = this.series.options.upColor);
27197          }
27198          resolveColor() {
27199            super.resolveColor(), this.series.is("heikinashi") || this.resolveUpColor();
27200          }
27201          getZone() {
27202            let t3 = super.getZone();
27203            return this.resolveUpColor(), t3;
27204          }
27205          applyOptions() {
27206            return super.applyOptions.apply(this, arguments), this.resolveColor && this.resolveColor(), this;
27207          }
27208        }
27209        return i2;
27210      }), i(e, "Series/OHLC/OHLCSeriesDefaults.js", [], function() {
27211        return {
27212          tooltip: {
27213            pointFormat: '<span style="color:{point.color}">\u25CF</span> <b> {series.name}</b><br/>Open: {point.open}<br/>High: {point.high}<br/>Low: {point.low}<br/>Close: {point.close}<br/>'
27214          }
27215        };
27216      }), i(e, "Series/OHLC/OHLCSeries.js", [e["Core/Globals.js"], e["Series/OHLC/OHLCPoint.js"], e["Series/OHLC/OHLCSeriesDefaults.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o) {
27217        let {
27218          composed: r
27219        } = t2, {
27220          hlc: a
27221        } = s.seriesTypes, {
27222          addEvent: n,
27223          crisp: l,
27224          extend: h,
27225          merge: d,
27226          pushUnique: c
27227        } = o;
27228        function p(t3) {
27229          let e3 = t3.options, i3 = e3.dataGrouping;
27230          i3 && e3.useOhlcData && "highcharts-navigator-series" !== e3.id && (i3.approximation = "ohlc");
27231        }
27232        function u11(t3) {
27233          let e3 = t3.options;
27234          e3.useOhlcData && "highcharts-navigator-series" !== e3.id && h(this, {
27235            pointValKey: g.prototype.pointValKey,
27236            pointArrayMap: g.prototype.pointArrayMap,
27237            toYData: g.prototype.toYData
27238          });
27239        }
27240        class g extends a {
27241          static compose(t3, ...e3) {
27242            c(r, "OHLCSeries") && (n(t3, "afterSetOptions", p), n(t3, "init", u11));
27243          }
27244          getPointPath(t3, e3) {
27245            let i3 = super.getPointPath(t3, e3), s2 = e3.strokeWidth(), o2 = l(t3.plotX || 0, s2), r2 = Math.round(t3.shapeArgs.width / 2);
27246            if (null !== t3.open) {
27247              let e4 = l(t3.plotOpen, s2);
27248              i3.push(["M", o2, e4], ["L", o2 - r2, e4]), super.extendStem(i3, s2 / 2, e4);
27249            }
27250            return i3;
27251          }
27252          pointAttribs(t3, e3) {
27253            let i3 = super.pointAttribs.call(this, t3, e3), s2 = this.options;
27254            return delete i3.fill, !t3.options.color && s2.upColor && t3.open < t3.close && (i3.stroke = s2.upColor), i3;
27255          }
27256          toYData(t3) {
27257            return [t3.open, t3.high, t3.low, t3.close];
27258          }
27259        }
27260        return g.defaultOptions = d(a.defaultOptions, i2), h(g.prototype, {
27261          pointClass: e2,
27262          pointArrayMap: ["open", "high", "low", "close"]
27263        }), s.registerSeriesType("ohlc", g), g;
27264      }), i(e, "Series/Candlestick/CandlestickSeriesDefaults.js", [], function() {
27265        return {
27266          states: {
27267            hover: {
27268              lineWidth: 2
27269            }
27270          },
27271          threshold: null,
27272          lineColor: "#000000",
27273          lineWidth: 1,
27274          upColor: "#ffffff",
27275          stickyTracking: true
27276        };
27277      }), i(e, "Series/Candlestick/CandlestickSeries.js", [e["Series/Candlestick/CandlestickSeriesDefaults.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2) {
27278        let {
27279          column: s,
27280          ohlc: o
27281        } = e2.seriesTypes, {
27282          crisp: r,
27283          merge: a
27284        } = i2;
27285        class n extends o {
27286          pointAttribs(t3, e3) {
27287            let i3 = s.prototype.pointAttribs.call(this, t3, e3), o2 = this.options, r2 = t3.open < t3.close, a2 = o2.lineColor || this.color, n2 = t3.color || this.color;
27288            if (i3["stroke-width"] = o2.lineWidth, i3.fill = t3.options.color || r2 && o2.upColor || n2, i3.stroke = t3.options.lineColor || r2 && o2.upLineColor || a2, e3) {
27289              let t4 = o2.states[e3];
27290              i3.fill = t4.color || i3.fill, i3.stroke = t4.lineColor || i3.stroke, i3["stroke-width"] = t4.lineWidth || i3["stroke-width"];
27291            }
27292            return i3;
27293          }
27294          drawPoints() {
27295            let t3 = this.points, e3 = this.chart, i3 = this.yAxis.reversed;
27296            for (let s2 of t3) {
27297              let t4 = s2.graphic, o2, a2, n2, l, h, d, c, p, u11, g = !t4;
27298              if (void 0 !== s2.plotY) {
27299                t4 || (s2.graphic = t4 = e3.renderer.path().add(this.group)), this.chart.styledMode || t4.attr(this.pointAttribs(s2, s2.selected && "select")).shadow(this.options.shadow);
27300                let f = t4.strokeWidth();
27301                c = r(s2.plotX || 0, f), n2 = Math.min(o2 = s2.plotOpen, a2 = s2.plotClose), l = Math.max(o2, a2), u11 = Math.round(s2.shapeArgs.width / 2), h = i3 ? l !== s2.yBottom : Math.round(n2) !== Math.round(s2.plotHigh || 0), d = i3 ? Math.round(n2) !== Math.round(s2.plotHigh || 0) : l !== s2.yBottom, n2 = r(n2, f), l = r(l, f), (p = []).push(["M", c - u11, l], ["L", c - u11, n2], ["L", c + u11, n2], ["L", c + u11, l], ["Z"], ["M", c, n2], ["L", c, h ? Math.round(i3 ? s2.yBottom : s2.plotHigh) : n2], ["M", c, l], ["L", c, d ? Math.round(i3 ? s2.plotHigh : s2.yBottom) : l]), t4[g ? "attr" : "animate"]({
27302                  d: p
27303                }).addClass(s2.getClassName(), true);
27304              }
27305            }
27306          }
27307        }
27308        return n.defaultOptions = a(o.defaultOptions, {
27309          tooltip: o.defaultOptions.tooltip
27310        }, t2), e2.registerSeriesType("candlestick", n), n;
27311      }), i(e, "Series/Flags/FlagsPoint.js", [e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2) {
27312        let {
27313          column: {
27314            prototype: {
27315              pointClass: i2
27316            }
27317          }
27318        } = t2.seriesTypes, {
27319          isNumber: s
27320        } = e2;
27321        return class extends i2 {
27322          constructor() {
27323            super(...arguments), this.ttBelow = false;
27324          }
27325          isValid() {
27326            return s(this.y) || void 0 === this.y;
27327          }
27328          hasNewShapeType() {
27329            let t3 = this.options.shape || this.series.options.shape;
27330            return this.graphic && t3 && t3 !== this.graphic.symbolKey;
27331          }
27332        };
27333      }), i(e, "Series/Flags/FlagsSeriesDefaults.js", [], function() {
27334        return {
27335          borderRadius: 0,
27336          pointRange: 0,
27337          allowOverlapX: false,
27338          shape: "flag",
27339          stackDistance: 12,
27340          textAlign: "center",
27341          tooltip: {
27342            pointFormat: "{point.text}"
27343          },
27344          threshold: null,
27345          y: -30,
27346          fillColor: "#ffffff",
27347          lineWidth: 1,
27348          states: {
27349            hover: {
27350              lineColor: "#000000",
27351              fillColor: "#ccd3ff"
27352            }
27353          },
27354          style: {
27355            fontSize: "0.7em",
27356            fontWeight: "bold"
27357          }
27358        };
27359      }), i(e, "Series/Flags/FlagsSymbols.js", [e["Core/Renderer/RendererRegistry.js"]], function(t2) {
27360        var e2;
27361        return function(e3) {
27362          let i2 = [];
27363          function s(t3, e4, i3, s2, o2) {
27364            let r = o2 && o2.anchorX || t3, a = o2 && o2.anchorY || e4, n = this.circle(r - 1, a - 1, 2, 2);
27365            return n.push(["M", r, a], ["L", t3, e4 + s2], ["L", t3, e4], ["L", t3 + i3, e4], ["L", t3 + i3, e4 + s2], ["L", t3, e4 + s2], ["Z"]), n;
27366          }
27367          function o(t3, e4) {
27368            t3[e4 + "pin"] = function(i3, s2, o2, r, a) {
27369              let n;
27370              let l = a && a.anchorX, h = a && a.anchorY;
27371              if ("circle" === e4 && r > o2 && (i3 -= Math.round((r - o2) / 2), o2 = r), n = t3[e4](i3, s2, o2, r, a), l && h) {
27372                let a2 = l;
27373                if ("circle" === e4) a2 = i3 + o2 / 2;
27374                else {
27375                  let t4 = n[0], e5 = n[1];
27376                  "M" === t4[0] && "L" === e5[0] && (a2 = (t4[1] + e5[1]) / 2);
27377                }
27378                let d = s2 > h ? s2 : s2 + r;
27379                n.push(["M", a2, d], ["L", l, h]), n = n.concat(t3.circle(l - 1, h - 1, 2, 2));
27380              }
27381              return n;
27382            };
27383          }
27384          e3.compose = function(e4) {
27385            if (-1 === i2.indexOf(e4)) {
27386              i2.push(e4);
27387              let t3 = e4.prototype.symbols;
27388              t3.flag = s, o(t3, "circle"), o(t3, "square");
27389            }
27390            let r = t2.getRendererType();
27391            i2.indexOf(r) && i2.push(r);
27392          };
27393        }(e2 || (e2 = {})), e2;
27394      }), i(e, "Series/OnSeriesComposition.js", [e["Series/Column/ColumnSeries.js"], e["Core/Globals.js"], e["Core/Series/Series.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s) {
27395        var o;
27396        let {
27397          composed: r
27398        } = e2, {
27399          prototype: a
27400        } = t2, {
27401          prototype: n
27402        } = i2, {
27403          defined: l,
27404          pushUnique: h,
27405          stableSort: d
27406        } = s;
27407        return function(t3) {
27408          function e3(t4) {
27409            return n.getPlotBox.call(this.options.onSeries && this.chart.get(this.options.onSeries) || this, t4);
27410          }
27411          function i3() {
27412            a.translate.apply(this);
27413            let t4 = this, e4 = t4.options, i4 = t4.chart, s2 = t4.points, o2 = e4.onSeries, r2 = o2 && i4.get(o2), n2 = r2 && r2.options.step, h2 = r2 && r2.points, c = i4.inverted, p = t4.xAxis, u11 = t4.yAxis, g = s2.length - 1, f, m, x = e4.onKey || "y", y = h2 && h2.length, b = 0, v, S2, k, M, C;
27414            if (r2 && r2.visible && y) {
27415              for (b = (r2.pointXOffset || 0) + (r2.barW || 0) / 2, M = r2.currentDataGrouping, S2 = h2[y - 1].x + (M ? M.totalRange : 0), d(s2, (t5, e5) => t5.x - e5.x), x = "plot" + x[0].toUpperCase() + x.substr(1); y-- && s2[g]; ) if (v = h2[y], (f = s2[g]).y = v.y, v.x <= f.x && void 0 !== v[x]) {
27416                if (f.x <= S2 && (f.plotY = v[x], v.x < f.x && !n2 && (k = h2[y + 1]) && void 0 !== k[x])) {
27417                  if (l(f.plotX) && r2.is("spline")) {
27418                    let t5 = [v.plotX || 0, v.plotY || 0], e5 = [k.plotX || 0, k.plotY || 0], i5 = v.controlPoints?.high || t5, s3 = k.controlPoints?.low || e5, o3 = (o4, r4) => Math.pow(1 - o4, 3) * t5[r4] + 3 * (1 - o4) * (1 - o4) * o4 * i5[r4] + 3 * (1 - o4) * o4 * o4 * s3[r4] + o4 * o4 * o4 * e5[r4], r3 = 0, a2 = 1, n3;
27419                    for (let t6 = 0; t6 < 100; t6++) {
27420                      let t7 = (r3 + a2) / 2, e6 = o3(t7, 0);
27421                      if (null === e6) break;
27422                      if (0.25 > Math.abs(e6 - f.plotX)) {
27423                        n3 = t7;
27424                        break;
27425                      }
27426                      e6 < f.plotX ? r3 = t7 : a2 = t7;
27427                    }
27428                    l(n3) && (f.plotY = o3(n3, 1), f.y = u11.toValue(f.plotY, true));
27429                  } else C = (f.x - v.x) / (k.x - v.x), f.plotY += C * (k[x] - v[x]), f.y += C * (k.y - v.y);
27430                }
27431                if (g--, y++, g < 0) break;
27432              }
27433            }
27434            s2.forEach((e5, i5) => {
27435              let o3;
27436              e5.plotX += b, (void 0 === e5.plotY || c) && (e5.plotX >= 0 && e5.plotX <= p.len ? c ? (e5.plotY = p.translate(e5.x, 0, 1, 0, 1), e5.plotX = l(e5.y) ? u11.translate(e5.y, 0, 0, 0, 1) : 0) : e5.plotY = (p.opposite ? 0 : t4.yAxis.len) + p.offset : e5.shapeArgs = {}), (m = s2[i5 - 1]) && m.plotX === e5.plotX && (void 0 === m.stackIndex && (m.stackIndex = 0), o3 = m.stackIndex + 1), e5.stackIndex = o3;
27437            }), this.onSeries = r2;
27438          }
27439          t3.compose = function(t4) {
27440            if (h(r, "OnSeries")) {
27441              let s2 = t4.prototype;
27442              s2.getPlotBox = e3, s2.translate = i3;
27443            }
27444            return t4;
27445          }, t3.getPlotBox = e3, t3.translate = i3;
27446        }(o || (o = {})), o;
27447      }), i(e, "Series/Flags/FlagsSeries.js", [e["Series/Flags/FlagsPoint.js"], e["Series/Flags/FlagsSeriesDefaults.js"], e["Series/Flags/FlagsSymbols.js"], e["Core/Globals.js"], e["Series/OnSeriesComposition.js"], e["Core/Renderer/RendererUtilities.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Renderer/SVG/SVGElement.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o, r, a, n, l) {
27448        let {
27449          noop: h
27450        } = s, {
27451          distribute: d
27452        } = r, {
27453          series: c,
27454          seriesTypes: {
27455            column: p
27456          }
27457        } = a, {
27458          addEvent: u11,
27459          defined: g,
27460          extend: f,
27461          isNumber: m,
27462          merge: x,
27463          objectEach: y,
27464          wrap: b
27465        } = l;
27466        class v extends p {
27467          animate(t3) {
27468            t3 && this.setClip();
27469          }
27470          drawPoints() {
27471            let t3, e3, i3, s2, o2, r2, a2, l2, h2, c2, p2;
27472            let u12 = this.points, f2 = this.chart, v2 = f2.renderer, S2 = f2.inverted, k = this.options, M = k.y, C = this.yAxis, A = {}, w = [], T2 = m(k.borderRadius) ? k.borderRadius : 0;
27473            for (s2 = u12.length; s2--; ) o2 = u12[s2], c2 = (S2 ? o2.plotY : o2.plotX) > this.xAxis.len, t3 = o2.plotX, a2 = o2.stackIndex, i3 = o2.options.shape || k.shape, void 0 !== (e3 = o2.plotY) && (e3 = o2.plotY + M - (void 0 !== a2 && a2 * k.stackDistance)), o2.anchorX = a2 ? void 0 : o2.plotX, l2 = a2 ? void 0 : o2.plotY, p2 = "flag" !== i3, r2 = o2.graphic, void 0 !== e3 && t3 >= 0 && !c2 ? (r2 && o2.hasNewShapeType() && (r2 = r2.destroy()), r2 || (r2 = o2.graphic = v2.label("", 0, void 0, i3, void 0, void 0, k.useHTML).addClass("highcharts-point").add(this.markerGroup), o2.graphic.div && (o2.graphic.div.point = o2), r2.isNew = true), r2.attr({
27474              align: p2 ? "center" : "left",
27475              width: k.width,
27476              height: k.height,
27477              "text-align": k.textAlign,
27478              r: T2
27479            }), f2.styledMode || r2.attr(this.pointAttribs(o2)).css(x(k.style, o2.style)).shadow(k.shadow), t3 > 0 && (t3 -= r2.strokeWidth() % 2), h2 = {
27480              y: e3,
27481              anchorY: l2
27482            }, k.allowOverlapX && (h2.x = t3, h2.anchorX = o2.anchorX), r2.attr({
27483              text: o2.options.title ?? k.title ?? "A"
27484            })[r2.isNew ? "attr" : "animate"](h2), k.allowOverlapX || (A[o2.plotX] ? A[o2.plotX].size = Math.max(A[o2.plotX].size, r2.width || 0) : A[o2.plotX] = {
27485              align: p2 ? 0.5 : 0,
27486              size: r2.width || 0,
27487              target: t3,
27488              anchorX: t3
27489            }), o2.tooltipPos = [t3, e3 + C.pos - f2.plotTop]) : r2 && (o2.graphic = r2.destroy());
27490            if (!k.allowOverlapX) {
27491              let t4 = 100;
27492              for (let e4 of (y(A, function(e5) {
27493                e5.plotX = e5.anchorX, w.push(e5), t4 = Math.max(e5.size, t4);
27494              }), d(w, S2 ? C.len : this.xAxis.len, t4), u12)) {
27495                let t5 = e4.plotX, i4 = e4.graphic, s3 = i4 && A[t5];
27496                s3 && i4 && (g(s3.pos) ? i4[i4.isNew ? "attr" : "animate"]({
27497                  x: s3.pos + (s3.align || 0) * s3.size,
27498                  anchorX: e4.anchorX
27499                }).show().isNew = false : i4.hide().isNew = true);
27500              }
27501            }
27502            k.useHTML && this.markerGroup && b(this.markerGroup, "on", function(t4) {
27503              return n.prototype.on.apply(t4.apply(this, [].slice.call(arguments, 1)), [].slice.call(arguments, 1));
27504            });
27505          }
27506          drawTracker() {
27507            let t3 = this.points;
27508            for (let e3 of (super.drawTracker(), t3)) {
27509              let i3 = e3.graphic;
27510              i3 && (e3.unbindMouseOver && e3.unbindMouseOver(), e3.unbindMouseOver = u11(i3.element, "mouseover", function() {
27511                for (let s2 of (e3.stackIndex > 0 && !e3.raised && (e3._y = i3.y, i3.attr({
27512                  y: e3._y - 8
27513                }), e3.raised = true), t3)) s2 !== e3 && s2.raised && s2.graphic && (s2.graphic.attr({
27514                  y: s2._y
27515                }), s2.raised = false);
27516              }));
27517            }
27518          }
27519          pointAttribs(t3, e3) {
27520            let i3 = this.options, s2 = t3 && t3.color || this.color, o2 = i3.lineColor, r2 = t3 && t3.lineWidth, a2 = t3 && t3.fillColor || i3.fillColor;
27521            return e3 && (a2 = i3.states[e3].fillColor, o2 = i3.states[e3].lineColor, r2 = i3.states[e3].lineWidth), {
27522              fill: a2 || s2,
27523              stroke: o2 || s2,
27524              "stroke-width": r2 || i3.lineWidth || 0
27525            };
27526          }
27527          setClip() {
27528            c.prototype.setClip.apply(this, arguments), false !== this.options.clip && this.sharedClipKey && this.markerGroup && this.markerGroup.clip(this.chart.sharedClips[this.sharedClipKey]);
27529          }
27530        }
27531        return v.compose = i2.compose, v.defaultOptions = x(p.defaultOptions, e2), o.compose(v), f(v.prototype, {
27532          allowDG: false,
27533          forceCrop: true,
27534          invertible: false,
27535          noSharedTooltip: true,
27536          pointClass: t2,
27537          sorted: false,
27538          takeOrdinalPosition: false,
27539          trackerGroups: ["markerGroup"],
27540          buildKDTree: h,
27541          init: c.prototype.init
27542        }), a.registerSeriesType("flags", v), v;
27543      }), i(e, "Core/Axis/BrokenAxis.js", [e["Core/Axis/Stacking/StackItem.js"], e["Core/Utilities.js"]], function(t2, e2) {
27544        var i2;
27545        let {
27546          addEvent: s,
27547          find: o,
27548          fireEvent: r,
27549          isArray: a,
27550          isNumber: n,
27551          pick: l
27552        } = e2;
27553        return function(e3) {
27554          function i3() {
27555            void 0 !== this.brokenAxis && this.brokenAxis.setBreaks(this.options.breaks, false);
27556          }
27557          function h() {
27558            this.brokenAxis?.hasBreaks && (this.options.ordinal = false);
27559          }
27560          function d() {
27561            let t3 = this.brokenAxis;
27562            if (t3?.hasBreaks) {
27563              let e4 = this.tickPositions, i4 = this.tickPositions.info, s2 = [];
27564              for (let i5 = 0; i5 < e4.length; i5++) t3.isInAnyBreak(e4[i5]) || s2.push(e4[i5]);
27565              this.tickPositions = s2, this.tickPositions.info = i4;
27566            }
27567          }
27568          function c() {
27569            this.brokenAxis || (this.brokenAxis = new m(this));
27570          }
27571          function p() {
27572            let {
27573              isDirty: t3,
27574              options: {
27575                connectNulls: e4
27576              },
27577              points: i4,
27578              xAxis: s2,
27579              yAxis: o2
27580            } = this;
27581            if (t3) {
27582              let t4 = i4.length;
27583              for (; t4--; ) {
27584                let r2 = i4[t4], a2 = !(null === r2.y && false === e4) && (s2?.brokenAxis?.isInAnyBreak(r2.x, true) || o2?.brokenAxis?.isInAnyBreak(r2.y, true));
27585                r2.visible = !a2 && false !== r2.options.visible;
27586              }
27587            }
27588          }
27589          function u11() {
27590            this.drawBreaks(this.xAxis, ["x"]), this.drawBreaks(this.yAxis, l(this.pointArrayMap, ["y"]));
27591          }
27592          function g(t3, e4) {
27593            let i4, s2, o2;
27594            let a2 = this, h2 = a2.points;
27595            if (t3?.brokenAxis?.hasBreaks) {
27596              let d2 = t3.brokenAxis;
27597              e4.forEach(function(e5) {
27598                i4 = d2?.breakArray || [], s2 = t3.isXAxis ? t3.min : l(a2.options.threshold, t3.min);
27599                let c2 = t3?.options?.breaks?.filter(function(t4) {
27600                  let e6 = true;
27601                  for (let s3 = 0; s3 < i4.length; s3++) {
27602                    let o3 = i4[s3];
27603                    if (o3.from === t4.from && o3.to === t4.to) {
27604                      e6 = false;
27605                      break;
27606                    }
27607                  }
27608                  return e6;
27609                });
27610                h2.forEach(function(a3) {
27611                  o2 = l(a3["stack" + e5.toUpperCase()], a3[e5]), i4.forEach(function(e6) {
27612                    if (n(s2) && n(o2)) {
27613                      let i5 = "";
27614                      s2 < e6.from && o2 > e6.to || s2 > e6.from && o2 < e6.from ? i5 = "pointBreak" : (s2 < e6.from && o2 > e6.from && o2 < e6.to || s2 > e6.from && o2 > e6.to && o2 < e6.from) && (i5 = "pointInBreak"), i5 && r(t3, i5, {
27615                        point: a3,
27616                        brk: e6
27617                      });
27618                    }
27619                  }), c2?.forEach(function(e6) {
27620                    r(t3, "pointOutsideOfBreak", {
27621                      point: a3,
27622                      brk: e6
27623                    });
27624                  });
27625                });
27626              });
27627            }
27628          }
27629          function f() {
27630            let e4 = this.currentDataGrouping, i4 = e4?.gapSize, s2 = this.points.slice(), o2 = this.yAxis, r2 = this.options.gapSize, a2 = s2.length - 1;
27631            if (r2 && a2 > 0) {
27632              let e5, n2;
27633              for ("value" !== this.options.gapUnit && (r2 *= this.basePointRange), i4 && i4 > r2 && i4 >= this.basePointRange && (r2 = i4); a2--; ) if (n2 && false !== n2.visible || (n2 = s2[a2 + 1]), e5 = s2[a2], false !== n2.visible && false !== e5.visible) {
27634                if (n2.x - e5.x > r2) {
27635                  let i5 = (e5.x + n2.x) / 2;
27636                  s2.splice(a2 + 1, 0, {
27637                    isNull: true,
27638                    x: i5
27639                  }), o2.stacking && this.options.stacking && ((o2.stacking.stacks[this.stackKey][i5] = new t2(o2, o2.options.stackLabels, false, i5, this.stack)).total = 0);
27640                }
27641                n2 = e5;
27642              }
27643            }
27644            return this.getGraphPath(s2);
27645          }
27646          e3.compose = function(t3, e4) {
27647            if (!t3.keepProps.includes("brokenAxis")) {
27648              t3.keepProps.push("brokenAxis"), s(t3, "init", c), s(t3, "afterInit", i3), s(t3, "afterSetTickPositions", d), s(t3, "afterSetOptions", h);
27649              let o2 = e4.prototype;
27650              o2.drawBreaks = g, o2.gappedPath = f, s(e4, "afterGeneratePoints", p), s(e4, "afterRender", u11);
27651            }
27652            return t3;
27653          };
27654          class m {
27655            static isInBreak(t3, e4) {
27656              let i4 = t3.repeat || 1 / 0, s2 = t3.from, o2 = t3.to - t3.from, r2 = e4 >= s2 ? (e4 - s2) % i4 : i4 - (s2 - e4) % i4;
27657              return t3.inclusive ? r2 <= o2 : r2 < o2 && 0 !== r2;
27658            }
27659            static lin2Val(t3) {
27660              let e4 = this.brokenAxis, i4 = e4 && e4.breakArray;
27661              if (!i4 || !n(t3)) return t3;
27662              let s2 = t3, o2, r2;
27663              for (r2 = 0; r2 < i4.length && !((o2 = i4[r2]).from >= s2); r2++) o2.to < s2 ? s2 += o2.len : m.isInBreak(o2, s2) && (s2 += o2.len);
27664              return s2;
27665            }
27666            static val2Lin(t3) {
27667              let e4 = this.brokenAxis, i4 = e4 && e4.breakArray;
27668              if (!i4 || !n(t3)) return t3;
27669              let s2 = t3, o2, r2;
27670              for (r2 = 0; r2 < i4.length; r2++) if ((o2 = i4[r2]).to <= t3) s2 -= o2.len;
27671              else if (o2.from >= t3) break;
27672              else if (m.isInBreak(o2, t3)) {
27673                s2 -= t3 - o2.from;
27674                break;
27675              }
27676              return s2;
27677            }
27678            constructor(t3) {
27679              this.hasBreaks = false, this.axis = t3;
27680            }
27681            findBreakAt(t3, e4) {
27682              return o(e4, function(e5) {
27683                return e5.from < t3 && t3 < e5.to;
27684              });
27685            }
27686            isInAnyBreak(t3, e4) {
27687              let i4 = this.axis, s2 = i4.options.breaks || [], o2 = s2.length, r2, a2, h2;
27688              if (o2 && n(t3)) {
27689                for (; o2--; ) m.isInBreak(s2[o2], t3) && (r2 = true, a2 || (a2 = l(s2[o2].showPoints, !i4.isXAxis)));
27690                h2 = r2 && e4 ? r2 && !a2 : r2;
27691              }
27692              return h2;
27693            }
27694            setBreaks(t3, e4) {
27695              let i4 = this, s2 = i4.axis, o2 = a(t3) && !!t3.length && !!Object.keys(t3[0]).length;
27696              s2.isDirty = i4.hasBreaks !== o2, i4.hasBreaks = o2, t3 !== s2.options.breaks && (s2.options.breaks = s2.userOptions.breaks = t3), s2.forceRedraw = true, s2.series.forEach(function(t4) {
27697                t4.isDirty = true;
27698              }), o2 || s2.val2lin !== m.val2Lin || (delete s2.val2lin, delete s2.lin2val), o2 && (s2.userOptions.ordinal = false, s2.lin2val = m.lin2Val, s2.val2lin = m.val2Lin, s2.setExtremes = function(t4, e5, o3, r2, a2) {
27699                if (i4.hasBreaks) {
27700                  let s3;
27701                  let o4 = this.options.breaks || [];
27702                  for (; s3 = i4.findBreakAt(t4, o4); ) t4 = s3.to;
27703                  for (; s3 = i4.findBreakAt(e5, o4); ) e5 = s3.from;
27704                  e5 < t4 && (e5 = t4);
27705                }
27706                s2.constructor.prototype.setExtremes.call(this, t4, e5, o3, r2, a2);
27707              }, s2.setAxisTranslation = function() {
27708                if (s2.constructor.prototype.setAxisTranslation.call(this), i4.unitLength = void 0, i4.hasBreaks) {
27709                  let t4 = s2.options.breaks || [], e5 = [], o3 = [], a2 = l(s2.pointRangePadding, 0), h2 = 0, d2, c2, p2 = s2.userMin || s2.min, u12 = s2.userMax || s2.max, g2, f2;
27710                  t4.forEach(function(t5) {
27711                    c2 = t5.repeat || 1 / 0, n(p2) && n(u12) && (m.isInBreak(t5, p2) && (p2 += t5.to % c2 - p2 % c2), m.isInBreak(t5, u12) && (u12 -= u12 % c2 - t5.from % c2));
27712                  }), t4.forEach(function(t5) {
27713                    if (g2 = t5.from, c2 = t5.repeat || 1 / 0, n(p2) && n(u12)) {
27714                      for (; g2 - c2 > p2; ) g2 -= c2;
27715                      for (; g2 < p2; ) g2 += c2;
27716                      for (f2 = g2; f2 < u12; f2 += c2) e5.push({
27717                        value: f2,
27718                        move: "in"
27719                      }), e5.push({
27720                        value: f2 + t5.to - t5.from,
27721                        move: "out",
27722                        size: t5.breakSize
27723                      });
27724                    }
27725                  }), e5.sort(function(t5, e6) {
27726                    return t5.value === e6.value ? ("in" === t5.move ? 0 : 1) - ("in" === e6.move ? 0 : 1) : t5.value - e6.value;
27727                  }), d2 = 0, g2 = p2, e5.forEach(function(t5) {
27728                    1 === (d2 += "in" === t5.move ? 1 : -1) && "in" === t5.move && (g2 = t5.value), 0 === d2 && n(g2) && (o3.push({
27729                      from: g2,
27730                      to: t5.value,
27731                      len: t5.value - g2 - (t5.size || 0)
27732                    }), h2 += t5.value - g2 - (t5.size || 0));
27733                  }), i4.breakArray = o3, n(p2) && n(u12) && n(s2.min) && (i4.unitLength = u12 - p2 - h2 + a2, r(s2, "afterBreaks"), s2.staticScale ? s2.transA = s2.staticScale : i4.unitLength && (s2.transA *= (u12 - s2.min + a2) / i4.unitLength), a2 && (s2.minPixelPadding = s2.transA * (s2.minPointOffset || 0)), s2.min = p2, s2.max = u12);
27734                }
27735              }), l(e4, true) && s2.chart.redraw();
27736            }
27737          }
27738          e3.Additions = m;
27739        }(i2 || (i2 = {})), i2;
27740      }), i(e, "masters/modules/broken-axis.src.js", [e["Core/Globals.js"], e["Core/Axis/BrokenAxis.js"]], function(t2, e2) {
27741        return t2.BrokenAxis = t2.BrokenAxis || e2, t2.BrokenAxis.compose(t2.Axis, t2.Series), t2;
27742      }), i(e, "Extensions/DataGrouping/ApproximationRegistry.js", [], function() {
27743        return {};
27744      }), i(e, "Extensions/DataGrouping/ApproximationDefaults.js", [e["Extensions/DataGrouping/ApproximationRegistry.js"], e["Core/Utilities.js"]], function(t2, e2) {
27745        let {
27746          arrayMax: i2,
27747          arrayMin: s,
27748          correctFloat: o,
27749          extend: r,
27750          isNumber: a
27751        } = e2;
27752        function n(t3) {
27753          let e3 = t3.length, i3 = l(t3);
27754          return a(i3) && e3 && (i3 = o(i3 / e3)), i3;
27755        }
27756        function l(t3) {
27757          let e3 = t3.length, i3;
27758          if (!e3 && t3.hasNulls) i3 = null;
27759          else if (e3) for (i3 = 0; e3--; ) i3 += t3[e3];
27760          return i3;
27761        }
27762        let h = {
27763          average: n,
27764          averages: function() {
27765            let t3 = [];
27766            return [].forEach.call(arguments, function(e3) {
27767              t3.push(n(e3));
27768            }), void 0 === t3[0] ? void 0 : t3;
27769          },
27770          close: function(t3) {
27771            return t3.length ? t3[t3.length - 1] : t3.hasNulls ? null : void 0;
27772          },
27773          high: function(t3) {
27774            return t3.length ? i2(t3) : t3.hasNulls ? null : void 0;
27775          },
27776          hlc: function(e3, i3, s2) {
27777            if (e3 = t2.high(e3), i3 = t2.low(i3), s2 = t2.close(s2), a(e3) || a(i3) || a(s2)) return [e3, i3, s2];
27778          },
27779          low: function(t3) {
27780            return t3.length ? s(t3) : t3.hasNulls ? null : void 0;
27781          },
27782          ohlc: function(e3, i3, s2, o2) {
27783            if (e3 = t2.open(e3), i3 = t2.high(i3), s2 = t2.low(s2), o2 = t2.close(o2), a(e3) || a(i3) || a(s2) || a(o2)) return [e3, i3, s2, o2];
27784          },
27785          open: function(t3) {
27786            return t3.length ? t3[0] : t3.hasNulls ? null : void 0;
27787          },
27788          range: function(e3, i3) {
27789            return (e3 = t2.low(e3), i3 = t2.high(i3), a(e3) || a(i3)) ? [e3, i3] : null === e3 && null === i3 ? null : void 0;
27790          },
27791          sum: l
27792        };
27793        return r(t2, h), h;
27794      }), i(e, "Extensions/DataGrouping/DataGroupingDefaults.js", [], function() {
27795        return {
27796          common: {
27797            groupPixelWidth: 2,
27798            dateTimeLabelFormats: {
27799              millisecond: ["%A, %e %b, %H:%M:%S.%L", "%A, %e %b, %H:%M:%S.%L", "-%H:%M:%S.%L"],
27800              second: ["%A, %e %b, %H:%M:%S", "%A, %e %b, %H:%M:%S", "-%H:%M:%S"],
27801              minute: ["%A, %e %b, %H:%M", "%A, %e %b, %H:%M", "-%H:%M"],
27802              hour: ["%A, %e %b, %H:%M", "%A, %e %b, %H:%M", "-%H:%M"],
27803              day: ["%A, %e %b %Y", "%A, %e %b", "-%A, %e %b %Y"],
27804              week: ["Week from %A, %e %b %Y", "%A, %e %b", "-%A, %e %b %Y"],
27805              month: ["%B %Y", "%B", "-%B %Y"],
27806              year: ["%Y", "%Y", "-%Y"]
27807            }
27808          },
27809          seriesSpecific: {
27810            line: {},
27811            spline: {},
27812            area: {},
27813            areaspline: {},
27814            arearange: {},
27815            column: {
27816              groupPixelWidth: 10
27817            },
27818            columnrange: {
27819              groupPixelWidth: 10
27820            },
27821            candlestick: {
27822              groupPixelWidth: 10
27823            },
27824            ohlc: {
27825              groupPixelWidth: 5
27826            },
27827            hlc: {
27828              groupPixelWidth: 5
27829            },
27830            heikinashi: {
27831              groupPixelWidth: 10
27832            }
27833          },
27834          units: [["millisecond", [1, 2, 5, 10, 20, 25, 50, 100, 200, 500]], ["second", [1, 2, 5, 10, 15, 30]], ["minute", [1, 2, 5, 10, 15, 30]], ["hour", [1, 2, 3, 4, 6, 8, 12]], ["day", [1]], ["week", [1]], ["month", [1, 3, 6]], ["year", null]]
27835        };
27836      }), i(e, "Extensions/DataGrouping/DataGroupingAxisComposition.js", [e["Extensions/DataGrouping/DataGroupingDefaults.js"], e["Core/Utilities.js"]], function(t2, e2) {
27837        let i2;
27838        let {
27839          addEvent: s,
27840          extend: o,
27841          merge: r,
27842          pick: a
27843        } = e2;
27844        function n(t3) {
27845          let e3 = this, i3 = e3.series;
27846          i3.forEach(function(t4) {
27847            t4.groupPixelWidth = void 0;
27848          }), i3.forEach(function(i4) {
27849            i4.groupPixelWidth = e3.getGroupPixelWidth && e3.getGroupPixelWidth(), i4.groupPixelWidth && (i4.hasProcessed = true), i4.applyGrouping(!!t3.hasExtremesChanged);
27850          });
27851        }
27852        function l() {
27853          let e3 = this.series, i3 = e3.length, s2 = 0, o2 = false, r2, n2;
27854          for (; i3--; ) (n2 = e3[i3].options.dataGrouping) && (s2 = Math.max(s2, a(n2.groupPixelWidth, t2.common.groupPixelWidth)), r2 = (e3[i3].processedXData || e3[i3].data).length, (e3[i3].groupPixelWidth || r2 > this.chart.plotSizeX / s2 || r2 && n2.forced) && (o2 = true));
27855          return o2 ? s2 : 0;
27856        }
27857        function h() {
27858          this.series.forEach(function(t3) {
27859            t3.hasProcessed = false;
27860          });
27861        }
27862        function d(t3, e3) {
27863          let s2;
27864          if (e3 = a(e3, true), t3 || (t3 = {
27865            forced: false,
27866            units: null
27867          }), this instanceof i2) for (s2 = this.series.length; s2--; ) this.series[s2].update({
27868            dataGrouping: t3
27869          }, false);
27870          else this.chart.options.series.forEach(function(e4) {
27871            e4.dataGrouping = "boolean" == typeof t3 ? t3 : r(t3, e4.dataGrouping);
27872          });
27873          this.ordinal && (this.ordinal.slope = void 0), e3 && this.chart.redraw();
27874        }
27875        return {
27876          compose: function(t3) {
27877            i2 = t3;
27878            let e3 = t3.prototype;
27879            e3.applyGrouping || (s(t3, "afterSetScale", h), s(t3, "postProcessData", n), o(e3, {
27880              applyGrouping: n,
27881              getGroupPixelWidth: l,
27882              setDataGrouping: d
27883            }));
27884          }
27885        };
27886      }), i(e, "Extensions/DataGrouping/DataGroupingSeriesComposition.js", [e["Extensions/DataGrouping/ApproximationRegistry.js"], e["Extensions/DataGrouping/DataGroupingDefaults.js"], e["Core/Axis/DateTimeAxis.js"], e["Core/Defaults.js"], e["Core/Series/SeriesRegistry.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o, r) {
27887        let {
27888          series: {
27889            prototype: a
27890          }
27891        } = o, {
27892          addEvent: n,
27893          defined: l,
27894          error: h,
27895          extend: d,
27896          isNumber: c,
27897          merge: p,
27898          pick: u11
27899        } = r, g = a.generatePoints;
27900        function f(t3) {
27901          var s2;
27902          let o2, r2;
27903          let n2 = this.chart, d2 = this.options.dataGrouping, p2 = false !== this.allowDG && d2 && u11(d2.enabled, n2.options.isStock), g2 = this.reserveSpace(), f2 = this.currentDataGrouping, m2, x2, y2 = false;
27904          p2 && !this.requireSorting && (this.requireSorting = y2 = true);
27905          let b2 = false == !(this.isCartesian && !this.isDirty && !this.xAxis.isDirty && !this.yAxis.isDirty && !t3) || !p2;
27906          if (y2 && (this.requireSorting = false), b2) return;
27907          this.destroyGroupedData();
27908          let v2 = d2.groupAll ? this.xData : this.processedXData, S2 = d2.groupAll ? this.yData : this.processedYData, k = n2.plotSizeX, M = this.xAxis, C = M.options.ordinal, A = this.groupPixelWidth;
27909          if (A && v2 && v2.length && k) {
27910            r2 = true, this.isDirty = true, this.points = null;
27911            let t4 = M.getExtremes(), p3 = t4.min, u12 = t4.max, f3 = C && M.ordinal && M.ordinal.getGroupIntervalFactor(p3, u12, this) || 1, y3 = A * (u12 - p3) / k * f3, b3 = M.getTimeTicks(i2.Additions.prototype.normalizeTimeTickInterval(y3, d2.units || e2.units), Math.min(p3, v2[0]), Math.max(u12, v2[v2.length - 1]), M.options.startOfWeek, v2, this.closestPointRange), w = a.groupData.apply(this, [v2, S2, b3, d2.approximation]), T2 = w.groupedXData, P = w.groupedYData, O = 0;
27912            for (d2 && d2.smoothed && T2.length && (d2.firstAnchor = "firstPoint", d2.anchor = "middle", d2.lastAnchor = "lastPoint", h(32, false, n2, {
27913              "dataGrouping.smoothed": "use dataGrouping.anchor"
27914            })), o2 = 1; o2 < b3.length; o2++) b3.info.segmentStarts && -1 !== b3.info.segmentStarts.indexOf(o2) || (O = Math.max(b3[o2] - b3[o2 - 1], O));
27915            (m2 = b3.info).gapSize = O, this.closestPointRange = b3.info.totalRange, this.groupMap = w.groupMap, this.currentDataGrouping = m2, function(t5, e3, i3) {
27916              let s3 = t5.options.dataGrouping, o3 = t5.currentDataGrouping && t5.currentDataGrouping.gapSize;
27917              if (!(s3 && t5.xData && o3 && t5.groupMap)) return;
27918              let r3 = e3.length - 1, a2 = s3.anchor, n3 = s3.firstAnchor, l2 = s3.lastAnchor, h2 = e3.length - 1, d3 = 0;
27919              if (n3 && t5.xData[0] >= e3[0]) {
27920                let i4;
27921                d3++;
27922                let s4 = t5.groupMap[0].start, r4 = t5.groupMap[0].length;
27923                c(s4) && c(r4) && (i4 = s4 + (r4 - 1)), e3[0] = {
27924                  start: e3[0],
27925                  middle: e3[0] + 0.5 * o3,
27926                  end: e3[0] + o3,
27927                  firstPoint: t5.xData[0],
27928                  lastPoint: i4 && t5.xData[i4]
27929                }[n3];
27930              }
27931              if (r3 > 0 && l2 && o3 && e3[r3] >= i3 - o3) {
27932                h2--;
27933                let i4 = t5.groupMap[t5.groupMap.length - 1].start;
27934                e3[r3] = {
27935                  start: e3[r3],
27936                  middle: e3[r3] + 0.5 * o3,
27937                  end: e3[r3] + o3,
27938                  firstPoint: i4 && t5.xData[i4],
27939                  lastPoint: t5.xData[t5.xData.length - 1]
27940                }[l2];
27941              }
27942              if (a2 && "start" !== a2) {
27943                let t6 = o3 * {
27944                  middle: 0.5,
27945                  end: 1
27946                }[a2];
27947                for (; h2 >= d3; ) e3[h2] += t6, h2--;
27948              }
27949            }(this, T2, u12), g2 && (l((s2 = T2)[0]) && c(M.min) && c(M.dataMin) && s2[0] < M.min && ((!l(M.options.min) && M.min <= M.dataMin || M.min === M.dataMin) && (M.min = Math.min(s2[0], M.min)), M.dataMin = Math.min(s2[0], M.dataMin)), l(s2[s2.length - 1]) && c(M.max) && c(M.dataMax) && s2[s2.length - 1] > M.max && ((!l(M.options.max) && c(M.dataMax) && M.max >= M.dataMax || M.max === M.dataMax) && (M.max = Math.max(s2[s2.length - 1], M.max)), M.dataMax = Math.max(s2[s2.length - 1], M.dataMax))), d2.groupAll && (this.allGroupedData = P, T2 = (x2 = this.cropData(T2, P, M.min, M.max)).xData, P = x2.yData, this.cropStart = x2.start), this.processedXData = T2, this.processedYData = P;
27950          } else this.groupMap = null, this.currentDataGrouping = void 0;
27951          this.hasGroupedData = r2, this.preventGraphAnimation = (f2 && f2.totalRange) !== (m2 && m2.totalRange);
27952        }
27953        function m() {
27954          this.groupedData && (this.groupedData.forEach(function(t3, e3) {
27955            t3 && (this.groupedData[e3] = t3.destroy ? t3.destroy() : null);
27956          }, this), this.groupedData.length = 0, delete this.allGroupedData);
27957        }
27958        function x() {
27959          g.apply(this), this.destroyGroupedData(), this.groupedData = this.hasGroupedData ? this.points : null;
27960        }
27961        function y() {
27962          return this.is("arearange") ? "range" : this.is("ohlc") ? "ohlc" : this.is("hlc") ? "hlc" : this.is("column") || this.options.cumulative ? "sum" : "average";
27963        }
27964        function b(e3, i3, s2, o2) {
27965          let r2 = this, a2 = r2.data, n2 = r2.options && r2.options.data, h2 = [], d2 = [], u12 = [], g2 = e3.length, f2 = !!i3, m2 = [], x2 = r2.pointArrayMap, y2 = x2 && x2.length, b2 = ["x"].concat(x2 || ["y"]), v2 = this.options.dataGrouping && this.options.dataGrouping.groupAll, S2, k, M, C = 0, A = 0, w = "function" == typeof o2 ? o2 : o2 && t2[o2] ? t2[o2] : t2[r2.getDGApproximation && r2.getDGApproximation() || "average"];
27966          if (y2) {
27967            let t3 = x2.length;
27968            for (; t3--; ) m2.push([]);
27969          } else m2.push([]);
27970          let T2 = y2 || 1;
27971          for (let t3 = 0; t3 <= g2; t3++) if (!(e3[t3] < s2[0])) {
27972            for (; void 0 !== s2[C + 1] && e3[t3] >= s2[C + 1] || t3 === g2; ) {
27973              S2 = s2[C], r2.dataGroupInfo = {
27974                start: v2 ? A : r2.cropStart + A,
27975                length: m2[0].length,
27976                groupStart: S2
27977              }, M = w.apply(r2, m2), r2.pointClass && !l(r2.dataGroupInfo.options) && (r2.dataGroupInfo.options = p(r2.pointClass.prototype.optionsToObject.call({
27978                series: r2
27979              }, r2.options.data[r2.cropStart + A])), b2.forEach(function(t4) {
27980                delete r2.dataGroupInfo.options[t4];
27981              })), void 0 !== M && (h2.push(S2), d2.push(M), u12.push(r2.dataGroupInfo)), A = t3;
27982              for (let t4 = 0; t4 < T2; t4++) m2[t4].length = 0, m2[t4].hasNulls = false;
27983              if (C += 1, t3 === g2) break;
27984            }
27985            if (t3 === g2) break;
27986            if (x2) {
27987              let e4;
27988              let i4 = r2.options.dataGrouping && r2.options.dataGrouping.groupAll ? t3 : r2.cropStart + t3, s3 = a2 && a2[i4] || r2.pointClass.prototype.applyOptions.apply({
27989                series: r2
27990              }, [n2[i4]]);
27991              for (let t4 = 0; t4 < y2; t4++) c(e4 = s3[x2[t4]]) ? m2[t4].push(e4) : null === e4 && (m2[t4].hasNulls = true);
27992            } else c(k = f2 ? i3[t3] : null) ? m2[0].push(k) : null === k && (m2[0].hasNulls = true);
27993          }
27994          return {
27995            groupedXData: h2,
27996            groupedYData: d2,
27997            groupMap: u12
27998          };
27999        }
28000        function v(t3) {
28001          let i3 = t3.options, o2 = this.type, r2 = this.chart.options.plotOptions, a2 = this.useCommonDataGrouping && e2.common, n2 = e2.seriesSpecific, l2 = s.defaultOptions.plotOptions[o2].dataGrouping;
28002          if (r2 && (n2[o2] || a2)) {
28003            let t4 = this.chart.rangeSelector;
28004            l2 || (l2 = p(e2.common, n2[o2])), i3.dataGrouping = p(a2, l2, r2.series && r2.series.dataGrouping, r2[o2].dataGrouping, this.userOptions.dataGrouping, !i3.isInternal && t4 && c(t4.selected) && t4.buttonOptions[t4.selected].dataGrouping);
28005          }
28006        }
28007        return {
28008          compose: function(t3) {
28009            let e3 = t3.prototype;
28010            e3.applyGrouping || (n(t3.prototype.pointClass, "update", function() {
28011              if (this.dataGroup) return h(24, false, this.series.chart), false;
28012            }), n(t3, "afterSetOptions", v), n(t3, "destroy", m), d(e3, {
28013              applyGrouping: f,
28014              destroyGroupedData: m,
28015              generatePoints: x,
28016              getDGApproximation: y,
28017              groupData: b
28018            }));
28019          },
28020          groupData: b
28021        };
28022      }), i(e, "Extensions/DataGrouping/DataGrouping.js", [e["Extensions/DataGrouping/DataGroupingAxisComposition.js"], e["Extensions/DataGrouping/DataGroupingDefaults.js"], e["Extensions/DataGrouping/DataGroupingSeriesComposition.js"], e["Core/Templating.js"], e["Core/Globals.js"], e["Core/Utilities.js"]], function(t2, e2, i2, s, o, r) {
28023        let {
28024          format: a
28025        } = s, {
28026          composed: n
28027        } = o, {
28028          addEvent: l,
28029          extend: h,
28030          isNumber: d,
28031          pick: c,
28032          pushUnique: p
28033        } = r;
28034        function u11(t3) {
28035          let i3 = this.chart, s2 = i3.time, o2 = t3.labelConfig, r2 = o2.series, n2 = o2.point, l2 = r2.options, p2 = r2.tooltipOptions, u12 = l2.dataGrouping, g = r2.xAxis, f = p2.xDateFormat, m, x, y, b, v, S2 = p2[t3.isFooter ? "footerFormat" : "headerFormat"];
28036          if (g && "datetime" === g.options.type && u12 && d(o2.key)) {
28037            x = r2.currentDataGrouping, y = u12.dateTimeLabelFormats || e2.common.dateTimeLabelFormats, x ? (b = y[x.unitName], 1 === x.count ? f = b[0] : (f = b[1], m = b[2])) : !f && y && g.dateTime && (f = g.dateTime.getXDateFormat(o2.x, p2.dateTimeLabelFormats));
28038            let l3 = c(r2.groupMap?.[n2.index].groupStart, o2.key), d2 = l3 + x?.totalRange - 1;
28039            v = s2.dateFormat(f, l3), m && (v += s2.dateFormat(m, d2)), r2.chart.styledMode && (S2 = this.styledModeFormat(S2)), t3.text = a(S2, {
28040              point: h(o2.point, {
28041                key: v
28042              }),
28043              series: r2
28044            }, i3), t3.preventDefault();
28045          }
28046        }
28047        return {
28048          compose: function(e3, s2, o2) {
28049            t2.compose(e3), i2.compose(s2), o2 && p(n, "DataGrouping") && l(o2, "headerFormatter", u11);
28050          },
28051          groupData: i2.groupData
28052        };
28053      }), i(e, "masters/modules/datagrouping.src.js", [e["Core/Globals.js"], e["Extensions/DataGrouping/ApproximationDefaults.js"], e["Extensions/DataGrouping/ApproximationRegistry.js"], e["Extensions/DataGrouping/DataGrouping.js"]], function(t2, e2, i2, s) {
28054        return t2.dataGrouping = t2.dataGrouping || {}, t2.dataGrouping.approximationDefaults = t2.dataGrouping.approximationDefaults || e2, t2.dataGrouping.approximations = t2.dataGrouping.approximations || i2, s.compose(t2.Axis, t2.Series, t2.Tooltip), t2;
28055      }), i(e, "Extensions/Annotations/NavigationBindingsUtilities.js", [e["Core/Utilities.js"]], function(t2) {
28056        let {
28057          defined: e2,
28058          isNumber: i2,
28059          pick: s
28060        } = t2, o = {
28061          backgroundColor: "string",
28062          borderColor: "string",
28063          borderRadius: "string",
28064          color: "string",
28065          fill: "string",
28066          fontSize: "string",
28067          labels: "string",
28068          name: "string",
28069          stroke: "string",
28070          title: "string"
28071        };
28072        return {
28073          annotationsFieldsTypes: o,
28074          getAssignedAxis: function(t3) {
28075            return t3.filter((t4) => {
28076              let e3 = t4.axis.getExtremes(), o2 = e3.min, r = e3.max, a = s(t4.axis.minPointOffset, 0);
28077              return i2(o2) && i2(r) && t4.value >= o2 - a && t4.value <= r + a && !t4.axis.options.isInternal;
28078            })[0];
28079          },
28080          getFieldType: function(t3, i3) {
28081            let s2 = o[t3], r = typeof i3;
28082            return e2(s2) && (r = s2), {
28083              string: "text",
28084              number: "number",
28085              boolean: "checkbox"
28086            }[r];
28087          }
28088        };
28089      }), i(e, "Extensions/MouseWheelZoom/MouseWheelZoom.js", [e["Core/Utilities.js"], e["Extensions/Annotations/NavigationBindingsUtilities.js"]], function(t2, e2) {
28090        let i2;
28091        let {
28092          addEvent: s,
28093          isObject: o,
28094          pick: r,
28095          defined: a,
28096          merge: n
28097        } = t2, {
28098          getAssignedAxis: l
28099        } = e2, h = [], d = {
28100          enabled: true,
28101          sensitivity: 1.1
28102        }, c = (t3) => (o(t3) || (t3 = {
28103          enabled: t3 ?? true
28104        }), n(d, t3)), p = function(t3, e3, s2, o2, n2, l2, h2) {
28105          let d2 = r(h2.type, t3.zooming.type, ""), c2 = [];
28106          "x" === d2 ? c2 = s2 : "y" === d2 ? c2 = o2 : "xy" === d2 && (c2 = t3.axes);
28107          let p2 = t3.transform({
28108            axes: c2,
28109            to: {
28110              x: n2 - 5,
28111              y: l2 - 5,
28112              width: 10,
28113              height: 10
28114            },
28115            from: {
28116              x: n2 - 5 * e3,
28117              y: l2 - 5 * e3,
28118              width: 10 * e3,
28119              height: 10 * e3
28120            },
28121            trigger: "mousewheel"
28122          });
28123          return p2 && (a(i2) && clearTimeout(i2), i2 = setTimeout(() => {
28124            t3.pointer?.drop();
28125          }, 400)), p2;
28126        };
28127        function u11() {
28128          let t3 = c(this.zooming.mouseWheel);
28129          t3.enabled && s(this.container, "wheel", (e3) => {
28130            e3 = this.pointer?.normalize(e3) || e3;
28131            let {
28132              pointer: i3
28133            } = this, s2 = i3 && !i3.inClass(e3.target, "highcharts-no-mousewheel");
28134            if (this.isInsidePlot(e3.chartX - this.plotLeft, e3.chartY - this.plotTop) && s2) {
28135              let s3 = t3.sensitivity || 1.1, o2 = e3.detail || (e3.deltaY || 0) / 120, r2 = l(i3.getCoordinates(e3).xAxis), a2 = l(i3.getCoordinates(e3).yAxis);
28136              p(this, Math.pow(s3, o2), r2 ? [r2.axis] : this.xAxis, a2 ? [a2.axis] : this.yAxis, e3.chartX, e3.chartY, t3) && e3.preventDefault?.();
28137            }
28138          });
28139        }
28140        return {
28141          compose: function(t3) {
28142            -1 === h.indexOf(t3) && (h.push(t3), s(t3, "afterGetContainer", u11));
28143          }
28144        };
28145      }), i(e, "masters/modules/mouse-wheel-zoom.src.js", [e["Core/Globals.js"], e["Extensions/MouseWheelZoom/MouseWheelZoom.js"]], function(t2, e2) {
28146        return t2.MouseWheelZoom = t2.MouseWheelZoom || e2, t2.MouseWheelZoom.compose(t2.Chart), t2;
28147      }), i(e, "masters/modules/stock.src.js", [e["Core/Globals.js"], e["Series/DataModifyComposition.js"], e["Stock/Navigator/Navigator.js"], e["Core/Axis/OrdinalAxis.js"], e["Stock/RangeSelector/RangeSelector.js"], e["Stock/Scrollbar/Scrollbar.js"], e["Core/Chart/StockChart.js"], e["Series/OHLC/OHLCSeries.js"], e["Series/Flags/FlagsSeries.js"]], function(t2, e2, i2, s, o, r, a, n, l) {
28148        return t2.Navigator = t2.Navigator || i2, t2.OrdinalAxis = t2.OrdinalAxis || s, t2.RangeSelector = t2.RangeSelector || o, t2.Scrollbar = t2.Scrollbar || r, t2.stockChart = t2.stockChart || a.stockChart, t2.StockChart = t2.StockChart || t2.stockChart, t2.extend(t2.StockChart, a), e2.compose(t2.Series, t2.Axis, t2.Point), l.compose(t2.Renderer), n.compose(t2.Series), t2.Navigator.compose(t2.Chart, t2.Axis, t2.Series), t2.OrdinalAxis.compose(t2.Axis, t2.Series, t2.Chart), t2.RangeSelector.compose(t2.Axis, t2.Chart), t2.Scrollbar.compose(t2.Axis), t2.StockChart.compose(t2.Chart, t2.Axis, t2.Series, t2.SVGRenderer), t2;
28149      }), i(e, "masters/highstock.src.js", [e["masters/highcharts.src.js"]], function(t2) {
28150        return t2.product = "Highstock", t2;
28151      }), e["masters/highstock.src.js"]._modules = e, e["masters/highstock.src.js"];
28152    });
28153  }
28154});
28155
28156// src/app/messages/message.service.ts
28157var MessageService = class _MessageService {
28158  constructor() {
28159    this.subject = new Subject();
28160  }
28161  /**
28162   * Send Message/Event
28163   * @param channel Channel ID
28164   * @param data Message to send
28165   * @param callerId Caller ID. It's necessary to not allow to send message to myself
28166   */
28167  // @ts-ignore
28168  sendMessage(channel = "1", data, callerId) {
28169    this.subject.next({ channel, type: data.type, callerId, data });
28170  }
28171  clearMessage() {
28172  }
28173  /**
28174   * Get observable to subscribe to get specific Message/Event
28175   * @param channel Channel ID
28176   * @param messageType Message type to read
28177   * @param callerId Caller ID. It's necessary to not allow to send message to myself
28178   */
28179  getMessage(channel = "1", messageType, callerId) {
28180    const messageTypeString = messageType.name;
28181    return this.subject.pipe(filter((m) => m.channel === channel && m.data.type === messageTypeString && m.callerId !== callerId));
28182  }
28183  static {
28184    this.\u0275fac = function MessageService_Factory(__ngFactoryType__) {
28185      return new (__ngFactoryType__ || _MessageService)();
28186    };
28187  }
28188  static {
28189    this.\u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({ token: _MessageService, factory: _MessageService.\u0275fac, providedIn: "root" });
28190  }
28191};
28192
28193// src/app/Utility/generic-util.ts
28194var GenericUtil = class {
28195  /**
28196   * Genera un GUID (UUID v4) con maggiore garanzia di unicità
28197   * Utilizza Web Crypto API quando disponibile, altrimenti fallback su Math.random
28198   * @returns Una stringa GUID nel formato xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx
28199   */
28200  static generateGUID() {
28201    if (typeof window !== "undefined" && window.crypto && window.crypto.getRandomValues) {
28202      const buffer = new Uint8Array(16);
28203      window.crypto.getRandomValues(buffer);
28204      buffer[6] = buffer[6] & 15 | 64;
28205      buffer[8] = buffer[8] & 63 | 128;
28206      return [
28207        buffer.slice(0, 4).reduce((acc, val) => acc + val.toString(16).padStart(2, "0"), ""),
28208        buffer.slice(4, 6).reduce((acc, val) => acc + val.toString(16).padStart(2, "0"), ""),
28209        buffer.slice(6, 8).reduce((acc, val) => acc + val.toString(16).padStart(2, "0"), ""),
28210        buffer.slice(8, 10).reduce((acc, val) => acc + val.toString(16).padStart(2, "0"), ""),
28211        buffer.slice(10).reduce((acc, val) => acc + val.toString(16).padStart(2, "0"), "")
28212      ].join("-");
28213    } else {
28214      const d = (/* @__PURE__ */ new Date()).getTime();
28215      const timestamp = typeof performance !== "undefined" && typeof performance.now === "function" ? performance.now() : 0;
28216      return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (c) => {
28217        const r = Math.random() * 16 | 0;
28218        const v = c === "x" ? r ^ d + timestamp & 15 : r & 3 | 8;
28219        return v.toString(16);
28220      });
28221    }
28222  }
28223  /**
28224   * Verifica che la string sorgente sia vuota.
28225   * Undefined è considerato come vuota
28226   */
28227  static stringIsEmpty(src) {
28228    if (src === void 0 || src === "") {
28229      return true;
28230    }
28231    return false;
28232  }
28233};
28234
28235// src/app/DoraWidget/widget.service.ts
28236var WidgetService = class _WidgetService {
28237  static {
28238    this.TAG_PREFIX = "DAG-";
28239  }
28240  constructor(injector, applicationRef, ngZone) {
28241    this.injector = injector;
28242    this.applicationRef = applicationRef;
28243    this.ngZone = ngZone;
28244    this.widgetsMap = /* @__PURE__ */ new Map();
28245    this.componentList = [];
28246    this.widgetsCreated = [];
28247  }
28248  // Imposta la lista dei componenti disponibili (chiamato da AppComponent)
28249  setComponentList(componentList) {
28250    if (componentList) {
28251      this.componentList = componentList;
28252    }
28253  }
28254  get WidgetsCreated() {
28255    return this.widgetsCreated;
28256  }
28257  getNewEventChannel() {
28258    return GenericUtil.generateGUID();
28259  }
28260  getNewProgressive() {
28261    return GenericUtil.generateGUID();
28262  }
28263  // add widget to map
28264  addWidget(src) {
28265    if (src.widgetName === void 0) {
28266      throw new Error("Widget name is not defined !");
28267    }
28268    if (this.widgetsMap.has(src.widgetName)) {
28269      const errorStr = "Widget [" + src.widgetName + "] alreay defined !";
28270      console.error(errorStr);
28271      alert(errorStr);
28272      return;
28273    }
28274    this.widgetsMap.set(src.widgetName, src);
28275  }
28276  // get widget by name
28277  getWidget(widgetName) {
28278    return this.widgetsMap.get(widgetName);
28279  }
28280  // Restituisce tutti i widget creati
28281  getWidgetsCreated() {
28282    return this.widgetsCreated;
28283  }
28284  /**
28285   * Scopre tutti i widget definiti nel DOM e li crea dinamicamente
28286   * @param selector
28287   */
28288  addWidgetFromDOM(selector = "") {
28289    this.componentList.forEach((componentName) => {
28290      let completeSelector = selector !== "" ? selector + " " : "";
28291      completeSelector += _WidgetService.TAG_PREFIX + componentName.name;
28292      const elementsFound = document.querySelectorAll(completeSelector);
28293      for (let idx = 0; idx < elementsFound.length; idx++) {
28294        const x = elementsFound[idx];
28295        console.log("found [" + _WidgetService.TAG_PREFIX + componentName.name + "]");
28296        const fatherElement = document.createElement(componentName.name);
28297        for (let i = 0; i < x.attributes.length; i++) {
28298          const attribute = x.attributes.item(i);
28299          if (attribute !== null) {
28300            fatherElement.setAttribute(attribute.name, attribute.value);
28301          }
28302        }
28303        const newComponentRef = createComponent(componentName.type, {
28304          environmentInjector: this.injector,
28305          hostElement: fatherElement
28306        });
28307        const widgetCreated = newComponentRef.instance;
28308        if (widgetCreated) {
28309          if (typeof widgetCreated.setExternalTagSelector === "function") {
28310            widgetCreated.setExternalTagSelector(_WidgetService.TAG_PREFIX + componentName.name);
28311          }
28312          this.widgetsCreated.push(widgetCreated);
28313        }
28314        this.applicationRef.attachView(newComponentRef.hostView);
28315        x.appendChild(fatherElement);
28316      }
28317    });
28318  }
28319  static {
28320    this.\u0275fac = function WidgetService_Factory(__ngFactoryType__) {
28321      return new (__ngFactoryType__ || _WidgetService)(\u0275\u0275inject(EnvironmentInjector), \u0275\u0275inject(ApplicationRef), \u0275\u0275inject(NgZone));
28322    };
28323  }
28324  static {
28325    this.\u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({ token: _WidgetService, factory: _WidgetService.\u0275fac, providedIn: "root" });
28326  }
28327};
28328
28329// src/app/Decorators/Decorator.ts
28330var import_reflect_metadata = __toESM(require_Reflect());
28331function DoraPropertyArray(doraType) {
28332  return (target, propertyKey) => {
28333    Reflect.defineMetadata("DoraPropertyArray", doraType, target, propertyKey);
28334  };
28335}
28336function DoraProperty(target, key) {
28337  Reflect.defineMetadata("DoraProperty", true, target, key);
28338  console.log("DoraProperty: ", target, key);
28339}
28340function DoraPropertyDOC(descr, type, values, attribute_dataprovider_values, editable = false, highChartPath = "") {
28341  console.log("DoraPropertyDOC: ", descr);
28342  return function(target, key) {
28343    console.log("function: DoraPropertyDOC");
28344    console.log("target type: ", typeof target);
28345    console.log("target: ", target);
28346    Reflect.defineMetadata("DoraPropertyDOC", true, target, key);
28347    Reflect.defineMetadata("DoraPropertyDOCDescr", descr, target, key);
28348    Reflect.defineMetadata("DoraPropertyDOCType", type.toString(), target, key);
28349    Reflect.defineMetadata("DoraPropertyDOCValues", values, target, key);
28350    Reflect.defineMetadata("DoraPropertyDOCAttributeDataProviderValues", attribute_dataprovider_values, target, key);
28351    Reflect.defineMetadata("DoraPropertyDOCEditable", editable, target, key);
28352    Reflect.defineMetadata("DoraPropertyDOCHighChartPath", highChartPath, target, key);
28353  };
28354}
28355
vendor: 2,413 bytes, lines 28356-28438
28356// node_modules/typedjson/lib/esm/type-descriptor.js
28357var TypeDescriptor = class {
28358  constructor(ctor) {
28359    this.ctor = ctor;
28360  }
28361  getTypes() {
28362    return [this.ctor];
28363  }
28364  hasFriendlyName() {
28365    return this.ctor.name !== "Object";
28366  }
28367};
28368var ConcreteTypeDescriptor = class extends TypeDescriptor {
28369  constructor(ctor) {
28370    super(ctor);
28371  }
28372};
28373var GenericTypeDescriptor = class extends TypeDescriptor {
28374  constructor(ctor) {
28375    super(ctor);
28376  }
28377};
28378var ArrayTypeDescriptor = class extends GenericTypeDescriptor {
28379  constructor(elementType) {
28380    super(Array);
28381    this.elementType = elementType;
28382  }
28383  getTypes() {
28384    return super.getTypes().concat(this.elementType.getTypes());
28385  }
28386};
28387var SetTypeDescriptor = class extends GenericTypeDescriptor {
28388  constructor(elementType) {
28389    super(Set);
28390    this.elementType = elementType;
28391  }
28392  getTypes() {
28393    return super.getTypes().concat(this.elementType.getTypes());
28394  }
28395};
28396function SetT(elementType) {
28397  return new SetTypeDescriptor(ensureTypeDescriptor(elementType));
28398}
28399var MapTypeDescriptor = class extends GenericTypeDescriptor {
28400  constructor(keyType, valueType, options2) {
28401    super(Map);
28402    this.keyType = keyType;
28403    this.valueType = valueType;
28404    this.options = options2;
28405  }
28406  getTypes() {
28407    return super.getTypes().concat(this.keyType.getTypes(), this.valueType.getTypes());
28408  }
28409  getCompleteOptions() {
28410    var _a, _b;
28411    return {
28412      shape: (_b = (_a = this.options) === null || _a === void 0 ? void 0 : _a.shape) !== null && _b !== void 0 ? _b : 0
28413    };
28414  }
28415};
28416function MapT(keyType, valueType, options2) {
28417  return new MapTypeDescriptor(ensureTypeDescriptor(keyType), ensureTypeDescriptor(valueType), options2);
28418}
28419var AnyT = new ConcreteTypeDescriptor(() => void 0);
28420function isTypelike(type) {
28421  return type != null && (typeof type === "function" || type instanceof TypeDescriptor);
28422}
28423function isTypeThunk(candidate) {
28424  return typeof candidate === "function" && candidate.name === "";
28425}
28426function ensureTypeDescriptor(type) {
28427  return type instanceof TypeDescriptor ? type : new ConcreteTypeDescriptor(type);
28428}
28429function ensureTypeThunk(typeThunkOrSerializable, decoratorName) {
28430  if (typeThunkOrSerializable == null) {
28431    throw new Error(`No type given on ${decoratorName}. ${LAZY_TYPE_EXPLANATION}`);
28432  }
28433  if (isTypeThunk(typeThunkOrSerializable)) {
28434    return typeThunkOrSerializable;
28435  }
28436  return () => typeThunkOrSerializable;
28437}
28438
vendor: 2,842 bytes, lines 28439-28510
28439// node_modules/typedjson/lib/esm/helpers.js
28440var LAZY_TYPE_EXPLANATION = `If the type is not yet defined, for example due to circular references, add '() => ' before it. E.g. @jsonMember(() => Foo)`;
28441var MISSING_REFLECT_CONF_MSG = 'Make sure that you have both "experimentalDecorators" and "emitDecoratorMetadata" enabled in your tsconfig.json';
28442function isDirectlySerializableNativeType(type) {
28443  return [Date, Number, String, Boolean].indexOf(type) !== -1;
28444}
28445function isTypeTypedArray(type) {
28446  return [Float32Array, Float64Array, Int8Array, Uint8Array, Uint8ClampedArray, Int16Array, Uint16Array, Int32Array, Uint32Array].indexOf(type) !== -1;
28447}
28448function isObject(value) {
28449  return typeof value === "object";
28450}
28451function shouldOmitParseString(jsonStr, expectedType) {
28452  const expectsTypesSerializedAsStrings = expectedType === String || expectedType === ArrayBuffer || expectedType === DataView;
28453  const hasQuotes = jsonStr.length >= 2 && jsonStr[0] === '"' && jsonStr[jsonStr.length - 1] === '"';
28454  if (expectedType === Date) {
28455    const isNumber = !isNaN(Number(jsonStr.trim()));
28456    return !hasQuotes && !isNumber;
28457  }
28458  return expectsTypesSerializedAsStrings && !hasQuotes;
28459}
28460function parseToJSObject(json, expectedType) {
28461  if (typeof json !== "string" || shouldOmitParseString(json, expectedType)) {
28462    return json;
28463  }
28464  return JSON.parse(json);
28465}
28466function isSubtypeOf(A, B) {
28467  return A === B || A.prototype instanceof B;
28468}
28469function logError(message, ...optionalParams) {
28470  if (typeof console === "object" && typeof console.error === "function") {
28471    console.error(message, ...optionalParams);
28472  } else if (typeof console === "object" && typeof console.log === "function") {
28473    console.log(`ERROR: ${message}`, ...optionalParams);
28474  }
28475}
28476function logWarning(message, ...optionalParams) {
28477  if (typeof console === "object" && typeof console.warn === "function") {
28478    console.warn(message, ...optionalParams);
28479  } else if (typeof console === "object" && typeof console.log === "function") {
28480    console.log(`WARNING: ${message}`, ...optionalParams);
28481  }
28482}
28483function isValueDefined(value) {
28484  return !(typeof value === "undefined" || value === null);
28485}
28486function isInstanceOf(value, constructor) {
28487  if (constructor === AnyT.ctor) {
28488    return true;
28489  } else if (typeof value === "number") {
28490    return constructor === Number;
28491  } else if (typeof value === "string") {
28492    return constructor === String;
28493  } else if (typeof value === "boolean") {
28494    return constructor === Boolean;
28495  } else if (isObject(value)) {
28496    return value instanceof constructor;
28497  }
28498  return false;
28499}
28500var isReflectMetadataSupported = typeof Reflect === "object" && typeof Reflect.getMetadata === "function";
28501function nameof(fn) {
28502  if (typeof fn.name === "string") {
28503    return fn.name;
28504  }
28505  return "undefined";
28506}
28507function identity(arg) {
28508  return arg;
28509}
28510
vendor: 3,719 bytes, lines 28511-28603
28511// node_modules/typedjson/lib/esm/metadata.js
28512var METADATA_FIELD_KEY = "__typedJsonJsonObjectMetadataInformation__";
28513var JsonObjectMetadata = class _JsonObjectMetadata {
28514  constructor(classType) {
28515    this.dataMembers = /* @__PURE__ */ new Map();
28516    this.knownTypes = /* @__PURE__ */ new Set();
28517    this.knownTypesDeferred = [];
28518    this.isExplicitlyMarked = false;
28519    this.isHandledWithoutAnnotation = false;
28520    this.classType = classType;
28521  }
28522  static getJsonObjectName(ctor) {
28523    const metadata = _JsonObjectMetadata.getFromConstructor(ctor);
28524    return metadata === void 0 ? nameof(ctor) : nameof(metadata.classType);
28525  }
28526  static getFromConstructor(ctor) {
28527    const prototype = ctor.prototype;
28528    if (prototype == null) {
28529      return;
28530    }
28531    let metadata;
28532    if (Object.prototype.hasOwnProperty.call(prototype, METADATA_FIELD_KEY)) {
28533      metadata = prototype[METADATA_FIELD_KEY];
28534    }
28535    if ((metadata === null || metadata === void 0 ? void 0 : metadata.isExplicitlyMarked) === true) {
28536      return metadata;
28537    }
28538    if (_JsonObjectMetadata.doesHandleWithoutAnnotation(ctor)) {
28539      const primitiveMeta = new _JsonObjectMetadata(ctor);
28540      primitiveMeta.isExplicitlyMarked = true;
28541      return primitiveMeta;
28542    }
28543  }
28544  static ensurePresentInPrototype(prototype) {
28545    if (Object.prototype.hasOwnProperty.call(prototype, METADATA_FIELD_KEY)) {
28546      return prototype[METADATA_FIELD_KEY];
28547    }
28548    const objectMetadata = new _JsonObjectMetadata(prototype.constructor);
28549    const parentMetadata = prototype[METADATA_FIELD_KEY];
28550    if (parentMetadata !== void 0) {
28551      parentMetadata.dataMembers.forEach((memberMetadata, propKey) => {
28552        objectMetadata.dataMembers.set(propKey, memberMetadata);
28553      });
28554      parentMetadata.knownTypes.forEach((knownType) => {
28555        objectMetadata.knownTypes.add(knownType);
28556      });
28557      objectMetadata.typeResolver = parentMetadata.typeResolver;
28558      objectMetadata.typeHintEmitter = parentMetadata.typeHintEmitter;
28559    }
28560    Object.defineProperty(prototype, METADATA_FIELD_KEY, {
28561      enumerable: false,
28562      configurable: false,
28563      writable: false,
28564      value: objectMetadata
28565    });
28566    return objectMetadata;
28567  }
28568  static getKnownTypeNameFromType(constructor) {
28569    const metadata = _JsonObjectMetadata.getFromConstructor(constructor);
28570    return metadata === void 0 ? nameof(constructor) : nameof(metadata.classType);
28571  }
28572  static doesHandleWithoutAnnotation(ctor) {
28573    return isDirectlySerializableNativeType(ctor) || isTypeTypedArray(ctor) || ctor === DataView || ctor === ArrayBuffer;
28574  }
28575  processDeferredKnownTypes() {
28576    this.knownTypesDeferred.forEach((typeThunk) => {
28577      typeThunk().getTypes().forEach((ctor) => this.knownTypes.add(ctor));
28578    });
28579    this.knownTypesDeferred = [];
28580  }
28581};
28582function injectMetadataInformation(prototype, propKey, metadata) {
28583  const decoratorName = `@jsonMember on ${nameof(prototype.constructor)}.${String(propKey)}`;
28584  if (typeof prototype === "function") {
28585    logError(`${decoratorName}: cannot use a static property.`);
28586    return;
28587  }
28588  if (typeof prototype[propKey] === "function") {
28589    logError(`${decoratorName}: cannot use a method property.`);
28590    return;
28591  }
28592  if (metadata == null || metadata.type === void 0 && metadata.deserializer === void 0) {
28593    logError(`${decoratorName}: JsonMemberMetadata has unknown type.`);
28594    return;
28595  }
28596  const objectMetadata = JsonObjectMetadata.ensurePresentInPrototype(prototype);
28597  if (metadata.deserializer === void 0) {
28598    objectMetadata.knownTypesDeferred.push(metadata.type);
28599  }
28600  Object.keys(metadata).forEach((key) => metadata[key] === void 0 && delete metadata[key]);
28601  objectMetadata.dataMembers.set(metadata.name, metadata);
28602}
28603
vendor: 776 bytes, lines 28604-28629
28604// node_modules/typedjson/lib/esm/options-base.js
28605var kAllOptions = ["preserveNull"];
28606function extractOptionBase(from2) {
28607  const options2 = Object.keys(from2).filter((key) => kAllOptions.indexOf(key) > -1).reduce((obj, key) => {
28608    obj[key] = from2[key];
28609    return obj;
28610  }, {});
28611  return Object.keys(options2).length > 0 ? options2 : void 0;
28612}
28613function getDefaultOptionOf(key) {
28614  switch (key) {
28615    case "preserveNull":
28616      return false;
28617  }
28618  return null;
28619}
28620function getOptionValue(key, options2) {
28621  if (options2 != null && options2[key] != null) {
28622    return options2[key];
28623  }
28624  return getDefaultOptionOf(key);
28625}
28626function mergeOptions(existing, moreSpecific) {
28627  return moreSpecific == null ? existing : Object.assign(Object.assign({}, existing), moreSpecific);
28628}
28629
vendor: 16,463 bytes, lines 28630-28962
28630// node_modules/typedjson/lib/esm/deserializer.js
28631function defaultTypeResolver(sourceObject, knownTypes) {
28632  if (sourceObject.__type != null) {
28633    return knownTypes.get(sourceObject.__type);
28634  }
28635}
28636var Deserializer = class {
28637  constructor() {
28638    this.typeResolver = defaultTypeResolver;
28639    this.errorHandler = logError;
28640    this.deserializationStrategy = /* @__PURE__ */ new Map([[AnyT.ctor, identity], [Number, deserializeDirectly], [String, deserializeDirectly], [Boolean, deserializeDirectly], [Date, deserializeDate], [ArrayBuffer, stringToArrayBuffer], [DataView, stringToDataView], [Array, convertAsArray], [Set, convertAsSet], [Map, convertAsMap], [Float32Array, convertAsFloatArray], [Float64Array, convertAsFloatArray], [Uint8Array, convertAsUintArray], [Uint8ClampedArray, convertAsUintArray], [Uint16Array, convertAsUintArray], [Uint32Array, convertAsUintArray]]);
28641  }
28642  setDeserializationStrategy(type, deserializer) {
28643    this.deserializationStrategy.set(type, deserializer);
28644  }
28645  setNameResolver(nameResolverCallback) {
28646    this.nameResolver = nameResolverCallback;
28647  }
28648  setTypeResolver(typeResolverCallback) {
28649    if (typeof typeResolverCallback !== "function") {
28650      throw new TypeError("'typeResolverCallback' is not a function.");
28651    }
28652    this.typeResolver = typeResolverCallback;
28653  }
28654  getTypeResolver() {
28655    return this.typeResolver;
28656  }
28657  setErrorHandler(errorHandlerCallback) {
28658    if (typeof errorHandlerCallback !== "function") {
28659      throw new TypeError("'errorHandlerCallback' is not a function.");
28660    }
28661    this.errorHandler = errorHandlerCallback;
28662  }
28663  getErrorHandler() {
28664    return this.errorHandler;
28665  }
28666  convertSingleValue(sourceObject, typeDescriptor, knownTypes, memberName = "object", memberOptions) {
28667    if (this.retrievePreserveNull(memberOptions) && sourceObject === null) {
28668      return null;
28669    } else if (!isValueDefined(sourceObject)) {
28670      return;
28671    }
28672    const deserializer = this.deserializationStrategy.get(typeDescriptor.ctor);
28673    if (deserializer !== void 0) {
28674      return deserializer(sourceObject, typeDescriptor, knownTypes, memberName, this, memberOptions);
28675    }
28676    if (typeof sourceObject === "object") {
28677      return convertAsObject(sourceObject, typeDescriptor, knownTypes, memberName, this);
28678    }
28679    let error = `Could not deserialize '${memberName}'; don't know how to deserialize type`;
28680    if (typeDescriptor.hasFriendlyName()) {
28681      error += ` '${typeDescriptor.ctor.name}'`;
28682    }
28683    this.errorHandler(new TypeError(`${error}.`));
28684  }
28685  instantiateType(ctor) {
28686    return new ctor();
28687  }
28688  mergeKnownTypes(...knownTypeMaps) {
28689    const result = /* @__PURE__ */ new Map();
28690    knownTypeMaps.forEach((knownTypes) => {
28691      knownTypes.forEach((ctor, name) => {
28692        if (this.nameResolver === void 0) {
28693          result.set(name, ctor);
28694        } else {
28695          result.set(this.nameResolver(ctor), ctor);
28696        }
28697      });
28698    });
28699    return result;
28700  }
28701  createKnownTypesMap(knowTypes) {
28702    const map2 = /* @__PURE__ */ new Map();
28703    knowTypes.forEach((ctor) => {
28704      if (this.nameResolver === void 0) {
28705        const knownTypeMeta = JsonObjectMetadata.getFromConstructor(ctor);
28706        const customName = (knownTypeMeta === null || knownTypeMeta === void 0 ? void 0 : knownTypeMeta.isExplicitlyMarked) === true ? knownTypeMeta.name : null;
28707        map2.set(customName !== null && customName !== void 0 ? customName : ctor.name, ctor);
28708      } else {
28709        map2.set(this.nameResolver(ctor), ctor);
28710      }
28711    });
28712    return map2;
28713  }
28714  retrievePreserveNull(memberOptions) {
28715    return getOptionValue("preserveNull", mergeOptions(this.options, memberOptions));
28716  }
28717};
28718function throwTypeMismatchError(targetType, expectedSourceType, actualSourceType, memberName) {
28719  throw new TypeError(`Could not deserialize ${memberName} as ${targetType}: expected ${expectedSourceType}, got ${actualSourceType}.`);
28720}
28721function makeTypeErrorMessage(expectedType, actualType, memberName) {
28722  const expectedTypeName = typeof expectedType === "function" ? nameof(expectedType) : expectedType;
28723  const actualTypeName = typeof actualType === "function" ? nameof(actualType) : actualType;
28724  return `Could not deserialize ${memberName}: expected '${expectedTypeName}', got '${actualTypeName}'.`;
28725}
28726function srcTypeNameForDebug(sourceObject) {
28727  return sourceObject == null ? "undefined" : nameof(sourceObject.constructor);
28728}
28729function deserializeDirectly(sourceObject, typeDescriptor, knownTypes, objectName) {
28730  if (sourceObject.constructor !== typeDescriptor.ctor) {
28731    throw new TypeError(makeTypeErrorMessage(nameof(typeDescriptor.ctor), sourceObject.constructor, objectName));
28732  }
28733  return sourceObject;
28734}
28735function convertAsObject(sourceObject, typeDescriptor, knownTypes, memberName, deserializer) {
28736  if (typeof sourceObject !== "object" || sourceObject === null) {
28737    deserializer.getErrorHandler()(new TypeError(`Cannot deserialize ${memberName}: 'sourceObject' must be a defined object.`));
28738    return void 0;
28739  }
28740  let expectedSelfType = typeDescriptor.ctor;
28741  let sourceObjectMetadata = JsonObjectMetadata.getFromConstructor(expectedSelfType);
28742  let knownTypeConstructors = knownTypes;
28743  let typeResolver = deserializer.getTypeResolver();
28744  if (sourceObjectMetadata !== void 0) {
28745    sourceObjectMetadata.processDeferredKnownTypes();
28746    knownTypeConstructors = deserializer.mergeKnownTypes(knownTypeConstructors, deserializer.createKnownTypesMap(sourceObjectMetadata.knownTypes));
28747    if (sourceObjectMetadata.typeResolver != null) {
28748      typeResolver = sourceObjectMetadata.typeResolver;
28749    }
28750  }
28751  const typeFromTypeHint = typeResolver(sourceObject, knownTypeConstructors);
28752  if (typeFromTypeHint != null) {
28753    if (isSubtypeOf(typeFromTypeHint, expectedSelfType)) {
28754      expectedSelfType = typeFromTypeHint;
28755      sourceObjectMetadata = JsonObjectMetadata.getFromConstructor(typeFromTypeHint);
28756      if (sourceObjectMetadata !== void 0) {
28757        knownTypeConstructors = deserializer.mergeKnownTypes(knownTypeConstructors, deserializer.createKnownTypesMap(sourceObjectMetadata.knownTypes));
28758      }
28759    }
28760  }
28761  if ((sourceObjectMetadata === null || sourceObjectMetadata === void 0 ? void 0 : sourceObjectMetadata.isExplicitlyMarked) === true) {
28762    const sourceMetadata = sourceObjectMetadata;
28763    const sourceObjectWithDeserializedProperties = {};
28764    const classOptions = mergeOptions(deserializer.options, sourceMetadata.options);
28765    sourceMetadata.dataMembers.forEach((objMemberMetadata, propKey) => {
28766      const objMemberValue = sourceObject[propKey];
28767      const objMemberDebugName = `${nameof(sourceMetadata.classType)}.${propKey}`;
28768      const objMemberOptions = mergeOptions(classOptions, objMemberMetadata.options);
28769      let revivedValue;
28770      if (objMemberMetadata.deserializer != null) {
28771        revivedValue = objMemberMetadata.deserializer(objMemberValue, {
28772          fallback: (so, td) => deserializer.convertSingleValue(so, ensureTypeDescriptor(td), knownTypes)
28773        });
28774      } else if (objMemberMetadata.type == null) {
28775        throw new TypeError(`Cannot deserialize ${objMemberDebugName} there is no constructor nor deserialization function to use.`);
28776      } else {
28777        revivedValue = deserializer.convertSingleValue(objMemberValue, objMemberMetadata.type(), knownTypeConstructors, objMemberDebugName, objMemberOptions);
28778      }
28779      if (isValueDefined(revivedValue) || deserializer.retrievePreserveNull(objMemberOptions) && revivedValue === null) {
28780        sourceObjectWithDeserializedProperties[objMemberMetadata.key] = revivedValue;
28781      } else if (objMemberMetadata.isRequired === true) {
28782        deserializer.getErrorHandler()(new TypeError(`Missing required member '${objMemberDebugName}'.`));
28783      }
28784    });
28785    let targetObject;
28786    if (typeof sourceObjectMetadata.initializerCallback === "function") {
28787      try {
28788        targetObject = sourceObjectMetadata.initializerCallback(sourceObjectWithDeserializedProperties, sourceObject);
28789        if (targetObject == null) {
28790          throw new TypeError(`Cannot deserialize ${memberName}: 'initializer' function returned undefined/null, but '${nameof(sourceObjectMetadata.classType)}' was expected.`);
28791        } else if (!(targetObject instanceof sourceObjectMetadata.classType)) {
28792          throw new TypeError(`Cannot deserialize ${memberName}:'initializer' returned '${nameof(targetObject.constructor)}', but '${nameof(sourceObjectMetadata.classType)}' was expected, and '${nameof(targetObject.constructor)}' is not a subtype of '${nameof(sourceObjectMetadata.classType)}'`);
28793        }
28794      } catch (e) {
28795        deserializer.getErrorHandler()(e);
28796        return void 0;
28797      }
28798    } else {
28799      targetObject = deserializer.instantiateType(expectedSelfType);
28800    }
28801    Object.assign(targetObject, sourceObjectWithDeserializedProperties);
28802    const methodName = sourceObjectMetadata.onDeserializedMethodName;
28803    if (methodName != null) {
28804      if (typeof targetObject[methodName] === "function") {
28805        targetObject[methodName]();
28806      } else if (typeof targetObject.constructor[methodName] === "function") {
28807        targetObject.constructor[methodName]();
28808      } else {
28809        deserializer.getErrorHandler()(new TypeError(`onDeserialized callback'${nameof(sourceObjectMetadata.classType)}.${methodName}' is not a method.`));
28810      }
28811    }
28812    return targetObject;
28813  } else {
28814    const targetObject = {};
28815    Object.keys(sourceObject).forEach((sourceKey) => {
28816      targetObject[sourceKey] = deserializer.convertSingleValue(sourceObject[sourceKey], new ConcreteTypeDescriptor(sourceObject[sourceKey].constructor), knownTypes, sourceKey);
28817    });
28818    return targetObject;
28819  }
28820}
28821function convertAsArray(sourceObject, typeDescriptor, knownTypes, memberName, deserializer, memberOptions) {
28822  if (!(typeDescriptor instanceof ArrayTypeDescriptor)) {
28823    throw new TypeError(`Could not deserialize ${memberName} as Array: incorrect TypeDescriptor detected, please use proper annotation or function for this type`);
28824  }
28825  if (!Array.isArray(sourceObject)) {
28826    deserializer.getErrorHandler()(new TypeError(makeTypeErrorMessage(Array, sourceObject.constructor, memberName)));
28827    return [];
28828  }
28829  if (typeDescriptor.elementType == null) {
28830    deserializer.getErrorHandler()(new TypeError(`Could not deserialize ${memberName} as Array: missing constructor reference of Array elements.`));
28831    return [];
28832  }
28833  return sourceObject.map((element, i) => {
28834    try {
28835      return deserializer.convertSingleValue(element, typeDescriptor.elementType, knownTypes, `${memberName}[${i}]`, memberOptions);
28836    } catch (e) {
28837      deserializer.getErrorHandler()(e);
28838      return void 0;
28839    }
28840  });
28841}
28842function convertAsSet(sourceObject, typeDescriptor, knownTypes, memberName, deserializer, memberOptions) {
28843  if (!(typeDescriptor instanceof SetTypeDescriptor)) {
28844    throw new TypeError(`Could not deserialize ${memberName} as Set: incorrect TypeDescriptor detected, please use proper annotation or function for this type`);
28845  }
28846  if (!Array.isArray(sourceObject)) {
28847    deserializer.getErrorHandler()(new TypeError(makeTypeErrorMessage(Array, sourceObject.constructor, memberName)));
28848    return /* @__PURE__ */ new Set();
28849  }
28850  if (typeDescriptor.elementType == null) {
28851    deserializer.getErrorHandler()(new TypeError(`Could not deserialize ${memberName} as Set: missing constructor reference of Set elements.`));
28852    return /* @__PURE__ */ new Set();
28853  }
28854  const resultSet = /* @__PURE__ */ new Set();
28855  sourceObject.forEach((element, i) => {
28856    try {
28857      resultSet.add(deserializer.convertSingleValue(element, typeDescriptor.elementType, knownTypes, `${memberName}[${i}]`, memberOptions));
28858    } catch (e) {
28859      deserializer.getErrorHandler()(e);
28860    }
28861  });
28862  return resultSet;
28863}
28864function isExpectedMapShape(source, expectedShape) {
28865  return expectedShape === 0 && Array.isArray(source) || expectedShape === 1 && typeof source === "object";
28866}
28867function convertAsMap(sourceObject, typeDescriptor, knownTypes, memberName, deserializer, memberOptions) {
28868  if (!(typeDescriptor instanceof MapTypeDescriptor)) {
28869    throw new TypeError(`Could not deserialize ${memberName} as Map: incorrect TypeDescriptor detected,please use proper annotation or function for this type`);
28870  }
28871  const expectedShape = typeDescriptor.getCompleteOptions().shape;
28872  if (!isExpectedMapShape(sourceObject, expectedShape)) {
28873    const expectedType = expectedShape === 0 ? Array : Object;
28874    deserializer.getErrorHandler()(new TypeError(makeTypeErrorMessage(expectedType, sourceObject.constructor, memberName)));
28875    return /* @__PURE__ */ new Map();
28876  }
28877  if (typeDescriptor.keyType == null) {
28878    deserializer.getErrorHandler()(new TypeError(`Could not deserialize ${memberName} as Map: missing key constructor.`));
28879    return /* @__PURE__ */ new Map();
28880  }
28881  if (typeDescriptor.valueType == null) {
28882    deserializer.getErrorHandler()(new TypeError(`Could not deserialize ${memberName} as Map: missing value constructor.`));
28883    return /* @__PURE__ */ new Map();
28884  }
28885  const keyMemberName = `${memberName}[].key`;
28886  const valueMemberName = `${memberName}[].value`;
28887  const resultMap = /* @__PURE__ */ new Map();
28888  if (expectedShape === 1) {
28889    Object.keys(sourceObject).forEach((key) => {
28890      try {
28891        const resultKey = deserializer.convertSingleValue(key, typeDescriptor.keyType, knownTypes, keyMemberName, memberOptions);
28892        if (isValueDefined(resultKey)) {
28893          resultMap.set(resultKey, deserializer.convertSingleValue(sourceObject[key], typeDescriptor.valueType, knownTypes, valueMemberName, memberOptions));
28894        }
28895      } catch (e) {
28896        deserializer.getErrorHandler()(e);
28897      }
28898    });
28899  } else {
28900    sourceObject.forEach((element) => {
28901      try {
28902        const key = deserializer.convertSingleValue(element.key, typeDescriptor.keyType, knownTypes, keyMemberName, memberOptions);
28903        if (isValueDefined(key)) {
28904          resultMap.set(key, deserializer.convertSingleValue(element.value, typeDescriptor.valueType, knownTypes, valueMemberName, memberOptions));
28905        }
28906      } catch (e) {
28907        deserializer.getErrorHandler()(e);
28908      }
28909    });
28910  }
28911  return resultMap;
28912}
28913function deserializeDate(sourceObject, typeDescriptor, knownTypes, memberName) {
28914  if (typeof sourceObject === "number") {
28915    const isInteger = sourceObject % 1 === 0;
28916    if (!isInteger) {
28917      throw new TypeError(`Could not deserialize ${memberName} as Date: expected an integer, got a number with decimal places.`);
28918    }
28919    return new Date(sourceObject);
28920  } else if (typeof sourceObject === "string") {
28921    return new Date(sourceObject);
28922  } else if (sourceObject instanceof Date) {
28923    return sourceObject;
28924  } else {
28925    throwTypeMismatchError("Date", "an ISO-8601 string", srcTypeNameForDebug(sourceObject), memberName);
28926  }
28927}
28928function stringToArrayBuffer(sourceObject, typeDescriptor, knownTypes, memberName) {
28929  if (typeof sourceObject !== "string") {
28930    throwTypeMismatchError("ArrayBuffer", "a string source", srcTypeNameForDebug(sourceObject), memberName);
28931  }
28932  return createArrayBufferFromString(sourceObject);
28933}
28934function stringToDataView(sourceObject, typeDescriptor, knownTypes, memberName) {
28935  if (typeof sourceObject !== "string") {
28936    throwTypeMismatchError("DataView", "a string source", srcTypeNameForDebug(sourceObject), memberName);
28937  }
28938  return new DataView(createArrayBufferFromString(sourceObject));
28939}
28940function createArrayBufferFromString(input2) {
28941  const buf = new ArrayBuffer(input2.length * 2);
28942  const bufView = new Uint16Array(buf);
28943  for (let i = 0, strLen = input2.length; i < strLen; i++) {
28944    bufView[i] = input2.charCodeAt(i);
28945  }
28946  return buf;
28947}
28948function convertAsFloatArray(sourceObject, typeDescriptor, knownTypes, memberName) {
28949  const constructor = typeDescriptor.ctor;
28950  if (Array.isArray(sourceObject) && sourceObject.every((elem) => !isNaN(elem))) {
28951    return new constructor(sourceObject);
28952  }
28953  return throwTypeMismatchError(constructor.name, "a numeric source array", srcTypeNameForDebug(sourceObject), memberName);
28954}
28955function convertAsUintArray(sourceObject, typeDescriptor, knownTypes, memberName) {
28956  const constructor = typeDescriptor.ctor;
28957  if (Array.isArray(sourceObject) && sourceObject.every((elem) => !isNaN(elem))) {
28958    return new constructor(sourceObject.map((value) => ~~value));
28959  }
28960  return throwTypeMismatchError(typeDescriptor.ctor.name, "a numeric source array", srcTypeNameForDebug(sourceObject), memberName);
28961}
28962
vendor: 1,548 bytes, lines 28963-28998
28963// node_modules/typedjson/lib/esm/json-array-member.js
28964function jsonArrayMember(maybeTypeThunk, options2 = {}) {
28965  return (target, propKey) => {
28966    var _a;
28967    const decoratorName = `@jsonArrayMember on ${nameof(target.constructor)}.${String(propKey)}`;
28968    const typeThunk = ensureTypeThunk(maybeTypeThunk, decoratorName);
28969    const dimensions = options2.dimensions == null ? 1 : options2.dimensions;
28970    if (!isNaN(dimensions) && dimensions < 1) {
28971      logError(`${decoratorName}: 'dimensions' option must be at least 1.`);
28972      return;
28973    }
28974    const reflectedType = isReflectMetadataSupported ? Reflect.getMetadata("design:type", target, propKey) : null;
28975    if (reflectedType != null && reflectedType !== Array && reflectedType !== Object) {
28976      logError(`${decoratorName}: property is not an Array. ${MISSING_REFLECT_CONF_MSG}`);
28977      return;
28978    }
28979    injectMetadataInformation(target, propKey, {
28980      type: () => createArrayType(ensureTypeDescriptor(typeThunk()), dimensions),
28981      emitDefaultValue: options2.emitDefaultValue,
28982      isRequired: options2.isRequired,
28983      options: extractOptionBase(options2),
28984      key: propKey.toString(),
28985      name: (_a = options2.name) !== null && _a !== void 0 ? _a : propKey.toString(),
28986      deserializer: options2.deserializer,
28987      serializer: options2.serializer
28988    });
28989  };
28990}
28991function createArrayType(elementType, dimensions) {
28992  let type = new ArrayTypeDescriptor(elementType);
28993  for (let i = 1; i < dimensions; ++i) {
28994    type = new ArrayTypeDescriptor(type);
28995  }
28996  return type;
28997}
28998
vendor: 9,607 bytes, lines 28999-29187
28999// node_modules/typedjson/lib/esm/serializer.js
29000function defaultTypeEmitter(targetObject, sourceObject, expectedSourceType, sourceTypeMetadata) {
29001  var _a;
29002  if (sourceObject.constructor !== expectedSourceType) {
29003    targetObject.__type = (_a = sourceTypeMetadata === null || sourceTypeMetadata === void 0 ? void 0 : sourceTypeMetadata.name) !== null && _a !== void 0 ? _a : nameof(sourceObject.constructor);
29004  }
29005}
29006var Serializer = class {
29007  constructor() {
29008    this.typeHintEmitter = defaultTypeEmitter;
29009    this.errorHandler = logError;
29010    this.serializationStrategy = /* @__PURE__ */ new Map([[AnyT.ctor, identity], [Date, identity], [Number, identity], [String, identity], [Boolean, identity], [ArrayBuffer, convertAsArrayBuffer], [DataView, convertAsDataView], [Array, convertAsArray2], [Set, convertAsSet2], [Map, convertAsMap2], [Float32Array, convertAsTypedArray], [Float64Array, convertAsTypedArray], [Int8Array, convertAsTypedArray], [Uint8Array, convertAsTypedArray], [Uint8ClampedArray, convertAsTypedArray], [Int16Array, convertAsTypedArray], [Uint16Array, convertAsTypedArray], [Int32Array, convertAsTypedArray], [Uint32Array, convertAsTypedArray]]);
29011  }
29012  setSerializationStrategy(type, serializer) {
29013    this.serializationStrategy.set(type, serializer);
29014  }
29015  setTypeHintEmitter(typeEmitterCallback) {
29016    if (typeof typeEmitterCallback !== "function") {
29017      throw new TypeError("'typeEmitterCallback' is not a function.");
29018    }
29019    this.typeHintEmitter = typeEmitterCallback;
29020  }
29021  getTypeHintEmitter() {
29022    return this.typeHintEmitter;
29023  }
29024  setErrorHandler(errorHandlerCallback) {
29025    if (typeof errorHandlerCallback !== "function") {
29026      throw new TypeError("'errorHandlerCallback' is not a function.");
29027    }
29028    this.errorHandler = errorHandlerCallback;
29029  }
29030  getErrorHandler() {
29031    return this.errorHandler;
29032  }
29033  retrievePreserveNull(memberOptions) {
29034    return getOptionValue("preserveNull", mergeOptions(this.options, memberOptions));
29035  }
29036  convertSingleValue(sourceObject, typeDescriptor, memberName = "object", memberOptions) {
29037    if (this.retrievePreserveNull(memberOptions) && sourceObject === null) {
29038      return null;
29039    }
29040    if (!isValueDefined(sourceObject)) {
29041      return;
29042    }
29043    if (!isInstanceOf(sourceObject, typeDescriptor.ctor)) {
29044      const expectedName = nameof(typeDescriptor.ctor);
29045      const actualName = nameof(sourceObject.constructor);
29046      this.errorHandler(new TypeError(`Could not serialize '${memberName}': expected '${expectedName}', got '${actualName}'.`));
29047      return;
29048    }
29049    const serializer = this.serializationStrategy.get(typeDescriptor.ctor);
29050    if (serializer !== void 0) {
29051      return serializer(sourceObject, typeDescriptor, memberName, this, memberOptions);
29052    }
29053    if (typeof sourceObject === "object") {
29054      return convertAsObject2(sourceObject, typeDescriptor, memberName, this, memberOptions);
29055    }
29056    let error = `Could not serialize '${memberName}'; don't know how to serialize type`;
29057    if (typeDescriptor.hasFriendlyName()) {
29058      error += ` '${typeDescriptor.ctor.name}'`;
29059    }
29060    this.errorHandler(new TypeError(`${error}.`));
29061  }
29062};
29063function convertAsObject2(sourceObject, typeDescriptor, memberName, serializer, memberOptions) {
29064  let sourceTypeMetadata;
29065  let targetObject;
29066  let typeHintEmitter = serializer.getTypeHintEmitter();
29067  if (sourceObject.constructor !== typeDescriptor.ctor && sourceObject instanceof typeDescriptor.ctor) {
29068    sourceTypeMetadata = JsonObjectMetadata.getFromConstructor(sourceObject.constructor);
29069  } else {
29070    sourceTypeMetadata = JsonObjectMetadata.getFromConstructor(typeDescriptor.ctor);
29071  }
29072  if (sourceTypeMetadata === void 0) {
29073    targetObject = Object.assign({}, sourceObject);
29074  } else {
29075    const beforeSerializationMethodName = sourceTypeMetadata.beforeSerializationMethodName;
29076    if (beforeSerializationMethodName != null) {
29077      if (typeof sourceObject[beforeSerializationMethodName] === "function") {
29078        sourceObject[beforeSerializationMethodName]();
29079      } else if (typeof sourceObject.constructor[beforeSerializationMethodName] === "function") {
29080        sourceObject.constructor[beforeSerializationMethodName]();
29081      } else {
29082        serializer.getErrorHandler()(new TypeError(`beforeSerialization callback '${nameof(sourceTypeMetadata.classType)}.${beforeSerializationMethodName}' is not a method.`));
29083      }
29084    }
29085    const sourceMeta = sourceTypeMetadata;
29086    targetObject = {};
29087    const classOptions = mergeOptions(serializer.options, sourceMeta.options);
29088    if (sourceMeta.typeHintEmitter != null) {
29089      typeHintEmitter = sourceMeta.typeHintEmitter;
29090    }
29091    sourceMeta.dataMembers.forEach((objMemberMetadata) => {
29092      const objMemberOptions = mergeOptions(classOptions, objMemberMetadata.options);
29093      let serialized;
29094      if (objMemberMetadata.serializer != null) {
29095        serialized = objMemberMetadata.serializer(sourceObject[objMemberMetadata.key], {
29096          fallback: (so, td) => serializer.convertSingleValue(so, ensureTypeDescriptor(td))
29097        });
29098      } else if (objMemberMetadata.type == null) {
29099        throw new TypeError(`Could not serialize ${objMemberMetadata.name}, there is no constructor nor serialization function to use.`);
29100      } else {
29101        serialized = serializer.convertSingleValue(sourceObject[objMemberMetadata.key], objMemberMetadata.type(), `${nameof(sourceMeta.classType)}.${objMemberMetadata.key}`, objMemberOptions);
29102      }
29103      if (serializer.retrievePreserveNull(objMemberOptions) && serialized === null || isValueDefined(serialized)) {
29104        targetObject[objMemberMetadata.name] = serialized;
29105      }
29106    });
29107  }
29108  typeHintEmitter(targetObject, sourceObject, typeDescriptor.ctor, sourceTypeMetadata);
29109  return targetObject;
29110}
29111function convertAsArray2(sourceObject, typeDescriptor, memberName, serializer, memberOptions) {
29112  if (!(typeDescriptor instanceof ArrayTypeDescriptor)) {
29113    throw new TypeError(`Could not serialize ${memberName} as Array: incorrect TypeDescriptor detected, please use proper annotation or function for this type`);
29114  }
29115  if (typeDescriptor.elementType == null) {
29116    throw new TypeError(`Could not serialize ${memberName} as Array: missing element type definition.`);
29117  }
29118  sourceObject.forEach((element, i) => {
29119    if (!(serializer.retrievePreserveNull(memberOptions) && element === null) && !isInstanceOf(element, typeDescriptor.elementType.ctor)) {
29120      const expectedTypeName = nameof(typeDescriptor.elementType.ctor);
29121      const actualTypeName = element && nameof(element.constructor);
29122      throw new TypeError(`Could not serialize ${memberName}[${i}]: expected '${expectedTypeName}', got '${actualTypeName}'.`);
29123    }
29124  });
29125  return sourceObject.map((element, i) => {
29126    return serializer.convertSingleValue(element, typeDescriptor.elementType, `${memberName}[${i}]`, memberOptions);
29127  });
29128}
29129function convertAsSet2(sourceObject, typeDescriptor, memberName, serializer, memberOptions) {
29130  if (!(typeDescriptor instanceof SetTypeDescriptor)) {
29131    throw new TypeError(`Could not serialize ${memberName} as Set: incorrect TypeDescriptor detected, please use proper annotation or function for this type`);
29132  }
29133  if (typeDescriptor.elementType == null) {
29134    throw new TypeError(`Could not serialize ${memberName} as Set: missing element type definition.`);
29135  }
29136  memberName += "[]";
29137  const resultArray = [];
29138  sourceObject.forEach((element) => {
29139    const resultElement = serializer.convertSingleValue(element, typeDescriptor.elementType, memberName, memberOptions);
29140    if (!isValueDefined(element) || isValueDefined(resultElement)) {
29141      resultArray.push(resultElement);
29142    }
29143  });
29144  return resultArray;
29145}
29146function convertAsMap2(sourceObject, typeDescriptor, memberName, serializer, memberOptions) {
29147  if (!(typeDescriptor instanceof MapTypeDescriptor)) {
29148    throw new TypeError(`Could not serialize ${memberName} as Map: incorrect TypeDescriptor detected, please use proper annotation or function for this type`);
29149  }
29150  if (typeDescriptor.valueType == null) {
29151    throw new TypeError(`Could not serialize ${memberName} as Map: missing value type definition.`);
29152  }
29153  if (typeDescriptor.keyType == null) {
29154    throw new TypeError(`Could not serialize ${memberName} as Map: missing key type definition.`);
29155  }
29156  const keyMemberName = `${memberName}[].key`;
29157  const valueMemberName = `${memberName}[].value`;
29158  const resultShape = typeDescriptor.getCompleteOptions().shape;
29159  const result = resultShape === 1 ? {} : [];
29160  const preserveNull = serializer.retrievePreserveNull(memberOptions);
29161  sourceObject.forEach((value, key) => {
29162    const resultKeyValuePairObj = {
29163      key: serializer.convertSingleValue(key, typeDescriptor.keyType, keyMemberName, memberOptions),
29164      value: serializer.convertSingleValue(value, typeDescriptor.valueType, valueMemberName, memberOptions)
29165    };
29166    const keyDefined = isValueDefined(resultKeyValuePairObj.key);
29167    const valueDefined = resultKeyValuePairObj.value === null && preserveNull || isValueDefined(resultKeyValuePairObj.value);
29168    if (keyDefined && valueDefined) {
29169      if (resultShape === 1) {
29170        result[resultKeyValuePairObj.key] = resultKeyValuePairObj.value;
29171      } else {
29172        result.push(resultKeyValuePairObj);
29173      }
29174    }
29175  });
29176  return result;
29177}
29178function convertAsTypedArray(sourceObject) {
29179  return Array.from(sourceObject);
29180}
29181function convertAsArrayBuffer(buffer) {
29182  return Array.from(new Uint16Array(buffer)).map((charCode) => String.fromCharCode(charCode)).join("");
29183}
29184function convertAsDataView(dataView) {
29185  return convertAsArrayBuffer(dataView.buffer);
29186}
29187
vendor: 8,276 bytes, lines 29188-29394
29188// node_modules/typedjson/lib/esm/parser.js
29189var TypedJSON = class _TypedJSON {
29190  constructor(rootConstructor, settings) {
29191    this.serializer = new Serializer();
29192    this.deserializer = new Deserializer();
29193    this.globalKnownTypes = [];
29194    this.indent = 0;
29195    const rootMetadata = JsonObjectMetadata.getFromConstructor(rootConstructor);
29196    if (rootMetadata === void 0 || !rootMetadata.isExplicitlyMarked && !rootMetadata.isHandledWithoutAnnotation) {
29197      throw new TypeError("The TypedJSON root data type must have the @jsonObject decorator used.");
29198    }
29199    this.nameResolver = (ctor) => nameof(ctor);
29200    this.rootConstructor = rootConstructor;
29201    this.errorHandler = (error) => logError(error);
29202    this.config(settings);
29203  }
29204  static parse(object, rootType, settings) {
29205    return new _TypedJSON(rootType, settings).parse(object);
29206  }
29207  static parseAsArray(object, elementType, settings, dimensions) {
29208    return new _TypedJSON(elementType, settings).parseAsArray(object, dimensions);
29209  }
29210  static parseAsSet(object, elementType, settings) {
29211    return new _TypedJSON(elementType, settings).parseAsSet(object);
29212  }
29213  static parseAsMap(object, keyType, valueType, settings) {
29214    return new _TypedJSON(valueType, settings).parseAsMap(object, keyType);
29215  }
29216  static toPlainJson(object, rootType, settings) {
29217    return new _TypedJSON(rootType, settings).toPlainJson(object);
29218  }
29219  static toPlainArray(object, elementType, dimensions, settings) {
29220    return new _TypedJSON(elementType, settings).toPlainArray(object, dimensions);
29221  }
29222  static toPlainSet(object, elementType, settings) {
29223    return new _TypedJSON(elementType, settings).toPlainSet(object);
29224  }
29225  static toPlainMap(object, keyCtor, valueCtor, settings) {
29226    return new _TypedJSON(valueCtor, settings).toPlainMap(object, keyCtor);
29227  }
29228  static stringify(object, rootType, settings) {
29229    return new _TypedJSON(rootType, settings).stringify(object);
29230  }
29231  static stringifyAsArray(object, elementType, dimensions, settings) {
29232    return new _TypedJSON(elementType, settings).stringifyAsArray(object, dimensions);
29233  }
29234  static stringifyAsSet(object, elementType, settings) {
29235    return new _TypedJSON(elementType, settings).stringifyAsSet(object);
29236  }
29237  static stringifyAsMap(object, keyCtor, valueCtor, settings) {
29238    return new _TypedJSON(valueCtor, settings).stringifyAsMap(object, keyCtor);
29239  }
29240  static setGlobalConfig(config) {
29241    Object.assign(this._globalConfig, config);
29242  }
29243  static mapType(type, converters) {
29244    if (this._globalConfig.mappedTypes == null) {
29245      this._globalConfig.mappedTypes = /* @__PURE__ */ new Map();
29246    }
29247    this._globalConfig.mappedTypes.set(type, converters);
29248  }
29249  config(settings) {
29250    settings = Object.assign(Object.assign({}, _TypedJSON._globalConfig), settings);
29251    if (settings.knownTypes != null && _TypedJSON._globalConfig.knownTypes != null) {
29252      settings.knownTypes = Array.from(new Set(settings.knownTypes.concat(_TypedJSON._globalConfig.knownTypes)));
29253    }
29254    const options2 = extractOptionBase(settings);
29255    this.serializer.options = options2;
29256    this.deserializer.options = options2;
29257    if (settings.errorHandler != null) {
29258      this.errorHandler = settings.errorHandler;
29259      this.deserializer.setErrorHandler(settings.errorHandler);
29260      this.serializer.setErrorHandler(settings.errorHandler);
29261    }
29262    if (settings.replacer != null) {
29263      this.replacer = settings.replacer;
29264    }
29265    if (settings.typeResolver != null) {
29266      this.deserializer.setTypeResolver(settings.typeResolver);
29267    }
29268    if (settings.typeHintEmitter != null) {
29269      this.serializer.setTypeHintEmitter(settings.typeHintEmitter);
29270    }
29271    if (settings.indent != null) {
29272      this.indent = settings.indent;
29273    }
29274    if (settings.mappedTypes != null) {
29275      settings.mappedTypes.forEach((upDown, type) => {
29276        this.setSerializationStrategies(type, upDown);
29277      });
29278    }
29279    if (settings.nameResolver != null) {
29280      this.nameResolver = settings.nameResolver;
29281      this.deserializer.setNameResolver(settings.nameResolver);
29282    }
29283    if (settings.knownTypes != null) {
29284      settings.knownTypes.forEach((knownType, i) => {
29285        if (typeof knownType === "undefined" || knownType === null) {
29286          logWarning(`TypedJSON.config: 'knownTypes' contains an undefined/null value (element ${i}).`);
29287        }
29288      });
29289      this.globalKnownTypes = settings.knownTypes;
29290    }
29291  }
29292  mapType(type, converters) {
29293    this.setSerializationStrategies(type, converters);
29294  }
29295  parse(object) {
29296    const json = parseToJSObject(object, this.rootConstructor);
29297    let result;
29298    try {
29299      result = this.deserializer.convertSingleValue(json, ensureTypeDescriptor(this.rootConstructor), this.getKnownTypes());
29300    } catch (e) {
29301      this.errorHandler(e);
29302    }
29303    return result;
29304  }
29305  parseAsArray(object, dimensions = 1) {
29306    const json = parseToJSObject(object, Array);
29307    return this.deserializer.convertSingleValue(json, createArrayType(ensureTypeDescriptor(this.rootConstructor), dimensions), this._mapKnownTypes(this.globalKnownTypes));
29308  }
29309  parseAsSet(object) {
29310    const json = parseToJSObject(object, Set);
29311    return this.deserializer.convertSingleValue(json, SetT(this.rootConstructor), this._mapKnownTypes(this.globalKnownTypes));
29312  }
29313  parseAsMap(object, keyConstructor) {
29314    const json = parseToJSObject(object, Map);
29315    return this.deserializer.convertSingleValue(json, MapT(keyConstructor, this.rootConstructor), this._mapKnownTypes(this.globalKnownTypes));
29316  }
29317  toPlainJson(object) {
29318    try {
29319      return this.serializer.convertSingleValue(object, ensureTypeDescriptor(this.rootConstructor));
29320    } catch (e) {
29321      this.errorHandler(e);
29322    }
29323  }
29324  toPlainArray(object, dimensions = 1) {
29325    try {
29326      return this.serializer.convertSingleValue(object, createArrayType(ensureTypeDescriptor(this.rootConstructor), dimensions));
29327    } catch (e) {
29328      this.errorHandler(e);
29329    }
29330  }
29331  toPlainSet(object) {
29332    try {
29333      return this.serializer.convertSingleValue(object, SetT(this.rootConstructor));
29334    } catch (e) {
29335      this.errorHandler(e);
29336    }
29337  }
29338  toPlainMap(object, keyConstructor) {
29339    try {
29340      return this.serializer.convertSingleValue(object, MapT(keyConstructor, this.rootConstructor));
29341    } catch (e) {
29342      this.errorHandler(e);
29343    }
29344  }
29345  stringify(object) {
29346    const result = this.toPlainJson(object);
29347    if (result === void 0) {
29348      return "";
29349    }
29350    return JSON.stringify(result, this.replacer, this.indent);
29351  }
29352  stringifyAsArray(object, dimensions) {
29353    return JSON.stringify(this.toPlainArray(object, dimensions), this.replacer, this.indent);
29354  }
29355  stringifyAsSet(object) {
29356    return JSON.stringify(this.toPlainSet(object), this.replacer, this.indent);
29357  }
29358  stringifyAsMap(object, keyConstructor) {
29359    return JSON.stringify(this.toPlainMap(object, keyConstructor), this.replacer, this.indent);
29360  }
29361  getKnownTypes() {
29362    const rootMetadata = JsonObjectMetadata.getFromConstructor(this.rootConstructor);
29363    const knownTypes = /* @__PURE__ */ new Map();
29364    this.globalKnownTypes.filter((ktc) => ktc).forEach((knownTypeCtor) => {
29365      knownTypes.set(this.nameResolver(knownTypeCtor), knownTypeCtor);
29366    });
29367    if (rootMetadata !== void 0) {
29368      rootMetadata.processDeferredKnownTypes();
29369      rootMetadata.knownTypes.forEach((knownTypeCtor) => {
29370        knownTypes.set(this.nameResolver(knownTypeCtor), knownTypeCtor);
29371      });
29372    }
29373    return knownTypes;
29374  }
29375  _mapKnownTypes(constructors) {
29376    const map2 = /* @__PURE__ */ new Map();
29377    constructors.filter((ctor) => ctor).forEach((ctor) => map2.set(this.nameResolver(ctor), ctor));
29378    return map2;
29379  }
29380  setSerializationStrategies(type, converters) {
29381    if (converters.deserializer != null) {
29382      this.deserializer.setDeserializationStrategy(type, (value) => converters.deserializer(value, {
29383        fallback: (so, td) => this.deserializer.convertSingleValue(so, ensureTypeDescriptor(td), this.getKnownTypes())
29384      }));
29385    }
29386    if (converters.serializer != null) {
29387      this.serializer.setSerializationStrategy(type, (value) => converters.serializer(value, {
29388        fallback: (so, td) => this.serializer.convertSingleValue(so, ensureTypeDescriptor(td))
29389      }));
29390    }
29391  }
29392};
29393TypedJSON._globalConfig = {};
29394
vendor: 1,403 bytes, lines 29395-29432
29395// node_modules/typedjson/lib/esm/json-object.js
29396function jsonObject(optionsOrTarget) {
29397  let options2;
29398  if (typeof optionsOrTarget === "function") {
29399    options2 = {};
29400  } else {
29401    options2 = optionsOrTarget !== null && optionsOrTarget !== void 0 ? optionsOrTarget : {};
29402  }
29403  function decorator(target) {
29404    const objectMetadata = JsonObjectMetadata.ensurePresentInPrototype(target.prototype);
29405    objectMetadata.isExplicitlyMarked = true;
29406    objectMetadata.onDeserializedMethodName = options2.onDeserialized;
29407    objectMetadata.beforeSerializationMethodName = options2.beforeSerialization;
29408    if (options2.typeResolver != null) {
29409      objectMetadata.typeResolver = options2.typeResolver;
29410    }
29411    if (options2.typeHintEmitter != null) {
29412      objectMetadata.typeHintEmitter = options2.typeHintEmitter;
29413    }
29414    objectMetadata.initializerCallback = options2.initializer;
29415    if (options2.name != null) {
29416      objectMetadata.name = options2.name;
29417    }
29418    const optionsBase = extractOptionBase(options2);
29419    if (optionsBase !== void 0) {
29420      objectMetadata.options = optionsBase;
29421    }
29422    if (options2.knownTypes != null) {
29423      options2.knownTypes.filter((knownType) => Boolean(knownType)).forEach((knownType) => objectMetadata.knownTypes.add(knownType));
29424    }
29425  }
29426  if (typeof optionsOrTarget === "function") {
29427    decorator(optionsOrTarget);
29428  } else {
29429    return decorator;
29430  }
29431}
29432
vendor: 4,723 bytes, lines 29433-29533
29433// node_modules/typedjson/lib/esm/json-member.js
29434function jsonMember(optionsOrPrototype, propertyKeyOrOptions) {
29435  if (typeof propertyKeyOrOptions === "string" || typeof propertyKeyOrOptions === "symbol") {
29436    const property = propertyKeyOrOptions;
29437    const prototype = optionsOrPrototype;
29438    const decoratorName = `@jsonMember on ${nameof(prototype.constructor)}.${String(property)}`;
29439    if (!isReflectMetadataSupported) {
29440      logError(`${decoratorName}: ReflectDecorators is required if the type is not explicitly provided with e.g. @jsonMember(Number)`);
29441      return;
29442    }
29443    const reflectPropCtor = Reflect.getMetadata("design:type", prototype, property);
29444    if (reflectPropCtor == null) {
29445      logError(`${decoratorName}: could not resolve detected property constructor at runtime. Potential solutions:
29446 - ${LAZY_TYPE_EXPLANATION}
29447 - ${MISSING_REFLECT_CONF_MSG}`);
29448      return;
29449    }
29450    const typeDescriptor = ensureTypeDescriptor(reflectPropCtor);
29451    if (isSpecialPropertyType(decoratorName, typeDescriptor)) {
29452      return;
29453    }
29454    injectMetadataInformation(prototype, property, {
29455      type: () => typeDescriptor,
29456      key: propertyKeyOrOptions.toString(),
29457      name: propertyKeyOrOptions.toString()
29458    });
29459    return;
29460  }
29461  return jsonMemberDecoratorFactory(optionsOrPrototype, propertyKeyOrOptions);
29462}
29463function jsonMemberDecoratorFactory(optionsOrType, options2) {
29464  return (target, property) => {
29465    var _a;
29466    const decoratorName = `@jsonMember on ${nameof(target.constructor)}.${String(property)}`;
29467    let typeThunk;
29468    if (isTypelike(optionsOrType) || isTypeThunk(optionsOrType)) {
29469      typeThunk = ensureTypeThunk(optionsOrType, decoratorName);
29470    } else {
29471      options2 = optionsOrType;
29472    }
29473    options2 = options2 !== null && options2 !== void 0 ? options2 : {};
29474    if (Object.prototype.hasOwnProperty.call(options2, "constructor")) {
29475      if (typeThunk !== void 0) {
29476        throw new Error("Cannot both define constructor option and type. Only one allowed.");
29477      }
29478      if (!isValueDefined(options2.constructor)) {
29479        logError(`${decoratorName}: cannot resolve specified property constructor at runtime. ${LAZY_TYPE_EXPLANATION}`);
29480        return;
29481      }
29482      const newTypeDescriptor = ensureTypeDescriptor(options2.constructor);
29483      typeThunk = () => newTypeDescriptor;
29484      if (isReflectMetadataSupported && !isSubtypeOf(newTypeDescriptor.ctor, Reflect.getMetadata("design:type", target, property))) {
29485        logWarning(`${decoratorName}: detected property type does not match 'constructor' option.`);
29486      }
29487    } else if (typeThunk !== void 0) {
29488    } else if (isReflectMetadataSupported) {
29489      const reflectCtor = Reflect.getMetadata("design:type", target, property);
29490      if (reflectCtor == null) {
29491        logError(`${decoratorName}: cannot resolve detected property constructor at runtime. ${LAZY_TYPE_EXPLANATION}`);
29492        return;
29493      }
29494      typeThunk = () => ensureTypeDescriptor(reflectCtor);
29495    } else if (options2.deserializer === void 0) {
29496      logError(`${decoratorName}: Cannot determine type`);
29497      return;
29498    }
29499    const typeToTest = typeThunk === null || typeThunk === void 0 ? void 0 : typeThunk();
29500    if (typeToTest !== void 0 && isSpecialPropertyType(decoratorName, typeToTest)) {
29501      return;
29502    }
29503    injectMetadataInformation(target, property, {
29504      type: typeThunk === void 0 ? void 0 : () => ensureTypeDescriptor(typeThunk()),
29505      emitDefaultValue: options2.emitDefaultValue,
29506      isRequired: options2.isRequired,
29507      options: extractOptionBase(options2),
29508      key: property.toString(),
29509      name: (_a = options2.name) !== null && _a !== void 0 ? _a : property.toString(),
29510      deserializer: options2.deserializer,
29511      serializer: options2.serializer
29512    });
29513  };
29514}
29515function isConstructorEqual(type, constructor) {
29516  return type instanceof TypeDescriptor ? type.ctor === constructor : type === constructor;
29517}
29518function isSpecialPropertyType(decoratorName, typeDescriptor) {
29519  if (!(typeDescriptor instanceof ArrayTypeDescriptor) && isConstructorEqual(typeDescriptor, Array)) {
29520    logError(`${decoratorName}: property is an Array. Use the jsonArrayMember decorator to serialize this property.`);
29521    return true;
29522  }
29523  if (!(typeDescriptor instanceof SetTypeDescriptor) && isConstructorEqual(typeDescriptor, Set)) {
29524    logError(`${decoratorName}: property is a Set. Use the jsonSetMember decorator to serialize this property.`);
29525    return true;
29526  }
29527  if (!(typeDescriptor instanceof MapTypeDescriptor) && isConstructorEqual(typeDescriptor, Map)) {
29528    logError(`${decoratorName}: property is a Map. Use the jsonMapMember decorator to serialize this property.`);
29529    return true;
29530  }
29531  return false;
29532}
29533
29534// src/app/MessageContent/single-parameter.ts
29535var PARAM_TYPE;
29536(function(PARAM_TYPE2) {
29537  PARAM_TYPE2[PARAM_TYPE2["STRING"] = 0] = "STRING";
29538  PARAM_TYPE2[PARAM_TYPE2["NUMBER"] = 1] = "NUMBER";
29539  PARAM_TYPE2[PARAM_TYPE2["BOOL"] = 2] = "BOOL";
29540  PARAM_TYPE2[PARAM_TYPE2["x64"] = 3] = "x64";
29541})(PARAM_TYPE || (PARAM_TYPE = {}));
29542var SingleParameter = class SingleParameter2 {
29543  constructor() {
29544    this.name = "";
29545  }
29546  getType() {
29547    return this.type ? PARAM_TYPE[this.type] : PARAM_TYPE.STRING;
29548  }
29549  getValueString() {
29550    switch (this.getType()) {
29551      case PARAM_TYPE.STRING:
29552        return this.value;
29553      case PARAM_TYPE.x64:
29554        return this.value ? atob(this.value) : void 0;
29555      default:
29556        return "";
29557    }
29558  }
29559  getValue() {
29560    switch (this.getType()) {
29561      case PARAM_TYPE.STRING:
29562        return this.value;
29563      case PARAM_TYPE.x64:
29564        return this.value ? this.b64DecodeUnicode(this.value) : void 0;
29565      case PARAM_TYPE.NUMBER:
29566        return Number(this.value);
29567      case PARAM_TYPE.BOOL:
29568        return Boolean(this.value);
29569      default:
29570        return "";
29571    }
29572  }
29573  b64DecodeUnicode(str) {
29574    if (window && "atob" in window && "decodeURIComponent" in window) {
29575      return decodeURIComponent(Array.prototype.map.call(atob(str), (c) => {
29576        return "%" + ("00" + c.charCodeAt(0).toString(16)).slice(-2);
29577      }).join(""));
29578    } else {
29579      console.warn("b64DecodeUnicode requirements: window.atob and window.decodeURIComponent functions");
29580      return null;
29581    }
29582  }
29583  getValueByteByte() {
29584    if (this.getType() !== PARAM_TYPE.x64) {
29585      return new Uint8Array();
29586    }
29587    const raw = this.value ? atob(this.value) : "";
29588    const rawLength = raw.length;
29589    const array = new Uint8Array(new ArrayBuffer(rawLength));
29590    let i;
29591    for (i = 0; i < rawLength; i++) {
29592      array[i] = raw.charCodeAt(i);
29593    }
29594    return array;
29595  }
29596  get Name() {
29597    return this.name;
29598  }
29599};
29600__decorate([
29601  jsonMember,
29602  __metadata("design:type", String)
29603], SingleParameter.prototype, "name", void 0);
29604__decorate([
29605  jsonMember(String),
29606  __metadata("design:type", Object)
29607], SingleParameter.prototype, "type", void 0);
29608__decorate([
29609  jsonMember(String),
29610  __metadata("design:type", Object)
29611], SingleParameter.prototype, "value", void 0);
29612SingleParameter = __decorate([
29613  jsonObject
29614], SingleParameter);
29615
29616// src/app/MessageContent/multiple-parameter.ts
29617var MultipleParameter = class MultipleParameter2 {
29618  constructor() {
29619    this.name = "";
29620  }
29621  getSingleParameter(name) {
29622    return this.singleParameters ? this.singleParameters.find((x) => x.name === name) : void 0;
29623  }
29624  getSingleParameters(name) {
29625    if (this.singleParameters === void 0) {
29626      return [];
29627    }
29628    return this.singleParameters.filter((x) => {
29629      return x.name === name ? true : false;
29630    });
29631  }
29632  getMultipleParameter(name) {
29633    return this.multipleParameters ? this.multipleParameters.find((x) => x.name === name) : void 0;
29634  }
29635  getMultipleParameters(name) {
29636    if (this.multipleParameters === void 0) {
29637      return [];
29638    }
29639    return this.multipleParameters.filter((x) => {
29640      return x.name === name ? true : false;
29641    });
29642  }
29643};
29644__decorate([
29645  jsonMember,
29646  __metadata("design:type", String)
29647], MultipleParameter.prototype, "name", void 0);
29648__decorate([
29649  jsonArrayMember(MultipleParameter),
29650  __metadata("design:type", Object)
29651], MultipleParameter.prototype, "multipleParameters", void 0);
29652__decorate([
29653  jsonArrayMember(SingleParameter),
29654  __metadata("design:type", Object)
29655], MultipleParameter.prototype, "singleParameters", void 0);
29656MultipleParameter = __decorate([
29657  jsonObject
29658], MultipleParameter);
29659
29660// src/app/MessageContent/msg-content.ts
29661var MsgContent = class MsgContent2 {
29662  getSingleParameter(name) {
29663    return this.singleParameters ? this.singleParameters.find((x) => x.name === name) : void 0;
29664  }
29665  getMultipleParameter(name) {
29666    return this.multipleParameters ? this.multipleParameters.find((x) => x.name === name) : void 0;
29667  }
29668  getError(urlRequested = "") {
29669    const statusParameter = this.getSingleParameter("Status");
29670    if (statusParameter == null) {
29671      return "Error [Status parameter not found] on request [" + urlRequested + "]";
29672    }
29673    let x;
29674    x = statusParameter.getValue();
29675    if (x !== "OK") {
29676      const descriptionParameter = this.getSingleParameter("Description");
29677      if (descriptionParameter === null || descriptionParameter === void 0) {
29678        return "Error [Description parameter not found] on request [" + urlRequested + "]";
29679      }
29680      return "Error [" + descriptionParameter.getValue() + "] on request [" + urlRequested + "]";
29681    }
29682    return "";
29683  }
29684};
29685__decorate([
29686  jsonArrayMember(MultipleParameter),
29687  __metadata("design:type", Object)
29688], MsgContent.prototype, "multipleParameters", void 0);
29689__decorate([
29690  jsonArrayMember(SingleParameter),
29691  __metadata("design:type", Object)
29692], MsgContent.prototype, "singleParameters", void 0);
29693MsgContent = __decorate([
29694  jsonObject
29695], MsgContent);
29696
29697// src/app/Configuration/high-charts-parameter.ts
29698var HighChartsParameter = class {
29699  constructor(name, highChartDocElement, value, values, idx, description, options2, isLeaf) {
29700    this.name = "";
29701    this.type = ATTRIBUTE_TYPE.STRING;
29702    this.value = "";
29703    this.values = [];
29704    this.idx = -1;
29705    this.description = "";
29706    this.options = [];
29707    this.isLeaf = false;
29708    this.name = name;
29709    this.type = this.parseType(highChartDocElement);
29710    this.idx = idx;
29711    this.description = description;
29712    this.options = options2;
29713    this.isLeaf = isLeaf;
29714    this.value = isLeaf ? value : "";
29715    this.values = isLeaf ? values : [];
29716  }
29717  setType(highChartDocElement) {
29718    this.type = this.parseType(highChartDocElement);
29719  }
29720  get IsLeaf() {
29721    return this.isLeaf;
29722  }
29723  set IsLeaf(value) {
29724    this.isLeaf = value;
29725  }
29726  get Name() {
29727    return this.name;
29728  }
29729  set Name(value) {
29730    this.name = value;
29731  }
29732  get Type() {
29733    return this.type;
29734  }
29735  set Type(value) {
29736    this.type = value;
29737  }
29738  get Value() {
29739    return this.value;
29740  }
29741  set Value(value) {
29742    switch (this.type) {
29743      case ATTRIBUTE_TYPE.BOOLEAN:
29744        this.value = value.toLowerCase() === "true" || value.toLowerCase() === "on" || value.toLowerCase() === "1" ? "true" : "false";
29745        break;
29746      default:
29747        this.value = value;
29748    }
29749  }
29750  get ValueBoolean() {
29751    return this.value.toLowerCase() === "true";
29752  }
29753  get Values() {
29754    return this.values;
29755  }
29756  set Values(value) {
29757    this.values = value;
29758  }
29759  get Idx() {
29760    return this.idx;
29761  }
29762  set Idx(value) {
29763    this.idx = value;
29764  }
29765  get Description() {
29766    return this.description;
29767  }
29768  set Description(value) {
29769    this.description = value;
29770  }
29771  get Options() {
29772    return this.options;
29773  }
29774  set Options(value) {
29775    this.options = value;
29776  }
29777  get isMultiple() {
29778    return this.idx !== -1;
29779  }
29780  parseType(highChartDocElement) {
29781    let result = ATTRIBUTE_TYPE.STRING;
29782    if (highChartDocElement.doclet.type !== void 0) {
29783      const type = highChartDocElement.doclet.type.names[0];
29784      switch (type) {
29785        case "number":
29786        case "n":
29787          result = ATTRIBUTE_TYPE.FLOAT;
29788          break;
29789        case "boolean":
29790        case "b":
29791          result = ATTRIBUTE_TYPE.BOOLEAN;
29792          break;
29793        case "array":
29794        case "a":
29795          result = ATTRIBUTE_TYPE.ARRAY;
29796          break;
29797        case "string":
29798          if (highChartDocElement.doclet.defaultvalue !== void 0 && highChartDocElement.doclet.defaultvalue.startsWith("#") || highChartDocElement.meta.name === "color") {
29799            result = ATTRIBUTE_TYPE.COLOR;
29800          } else {
29801            result = ATTRIBUTE_TYPE.STRING;
29802          }
29803          break;
29804        default:
29805          result = ATTRIBUTE_TYPE.STRING;
29806      }
29807    }
29808    return result;
29809  }
29810  toString() {
29811    let result = this.getPath();
29812    if (this.isLeaf) {
29813      result += "\xA7";
29814      result += this.getType();
29815      result += "\xA7";
29816      result += this.value;
29817    }
29818    return result;
29819  }
29820  getPath() {
29821    let result = "";
29822    if (this.isMultiple) {
29823      result = "[" + this.idx + "]";
29824    }
29825    result += this.name;
29826    return result;
29827  }
29828  getType() {
29829    switch (this.type) {
29830      case ATTRIBUTE_TYPE.FLOAT:
29831      case ATTRIBUTE_TYPE.INTEGER:
29832        return "n";
29833      case ATTRIBUTE_TYPE.BOOLEAN:
29834        return "b";
29835      default:
29836        return "s";
29837    }
29838  }
29839};
29840
29841// src/app/Configuration/high-charts-parameters.ts
29842var _ = __toESM(require_lodash());
29843
29844// src/app/DoraWidget/dora-chart/Data/chart-option.ts
29845var ChartOption = class _ChartOption {
29846  constructor() {
29847    this.path = "";
29848    this.type = "";
29849    this.value = "";
29850    this.valueArray = null;
29851  }
29852  static create(path2, type, value) {
29853    const result = new _ChartOption();
29854    result.path = path2;
29855    result.type = type;
29856    result.value = value;
29857    return result;
29858  }
29859  static createArray(path2, value) {
29860    const result = new _ChartOption();
29861    result.path = path2;
29862    result.type = "a";
29863    result.valueArray = value;
29864    return result;
29865  }
29866  // tslint:disable-next-line:ban-types
29867  buildRoot(dst, root) {
29868    if (root === null) {
29869      return dst;
29870    }
29871    const path2 = this.path.split("\\");
29872    const idxPart = this.extractRootIdx(path2[0]);
29873    if (idxPart === "") {
29874      if (dst[root] === void 0) {
29875        dst[root] = {};
29876      }
29877      return dst[root];
29878    }
29879    if (dst[root] === void 0) {
29880      dst[root] = [];
29881    }
29882    const idx = Number(idxPart.substring(1, idxPart.length - 1));
29883    if (dst[root][idx] === void 0) {
29884      dst[root][idx] = {};
29885    }
29886    return dst[root][idx];
29887  }
29888  /**
29889   * extract string containing root idx.
29890   * Eg. '[10]myParams'  return '[10]'
29891   * @param path first path
29892   * @return '' if no idx found
29893   */
29894  extractRootIdx(path2) {
29895    if (path2.startsWith("[") === false) {
29896      return "";
29897    }
29898    const end = path2.indexOf("]");
29899    return path2.substring(0, end + 1);
29900  }
29901  // tslint:disable-next-line:ban-types
29902  setOption(dst, root) {
29903    const rootObj = this.buildRoot(dst, root);
29904    const rootIdxPart = this.path ? this.extractRootIdx(this.path) : "";
29905    const myPath = this.path.substring(rootIdxPart.length);
29906    const path2 = myPath.split("\\");
29907    this.setValue(rootObj, path2, 0);
29908  }
29909  // tslint:disable-next-line:ban-types
29910  setValue(dst, path2, idx) {
29911    if (path2.length === idx + 1) {
29912      let value;
29913      switch (this.type.toLowerCase()) {
29914        case "number":
29915        case "n":
29916          value = Number(this.value);
29917          break;
29918        case "boolean":
29919        case "b":
29920          value = this.value.toLowerCase() === "true" ? true : false;
29921          break;
29922        case "array":
29923        case "a":
29924          value = this.valueArray;
29925          break;
29926        default:
29927          value = this.value;
29928      }
29929      const rootIdxPart = this.extractRootIdx(path2[idx]);
29930      const myPath = path2[idx].substring(rootIdxPart.length);
29931      if (rootIdxPart !== "") {
29932        const paramIdx = Number(rootIdxPart.substring(1, rootIdxPart.length - 1));
29933        if (myPath === "") {
29934          if (dst === void 0 || dst === null || dst instanceof Array === false) {
29935            dst = [];
29936          }
29937          dst[paramIdx] = value;
29938        } else {
29939          if (dst[myPath] === void 0) {
29940            dst[myPath] = [];
29941          }
29942          dst[myPath][paramIdx] = value;
29943        }
29944      } else {
29945        dst[myPath] = value;
29946      }
29947    } else {
29948      const newDst = this.getElement(dst, path2[idx], this.isPathArray(path2[idx + 1]));
29949      this.setValue(newDst, path2, idx + 1);
29950    }
29951  }
29952  /**
29953   * Verifica se il path è un array, quindi se è del tipo [idx]
29954   * @param path
29955   * @private
29956   */
29957  isPathArray(path2) {
29958    if (path2.endsWith("]") && path2.startsWith("[")) {
29959      let count = 0;
29960      for (let idx = 0; idx < path2.length; idx++) {
29961        if (path2[idx] === "[") {
29962          count++;
29963        }
29964      }
29965      return count === 1 ? true : false;
29966    }
29967    return false;
29968  }
29969  // tslint:disable-next-line:ban-types
29970  getElement(dst, path2, nextisarray) {
29971    if (dst === null) {
29972      return null;
29973    }
29974    const rootIdxPart = this.extractRootIdx(path2);
29975    const myPath = path2.substring(rootIdxPart.length);
29976    if (myPath.endsWith("]") === false) {
29977      if (dst[myPath] === void 0) {
29978        if (nextisarray) {
29979          dst[myPath] = [];
29980        } else {
29981          dst[myPath] = {};
29982        }
29983      }
29984      return dst[myPath];
29985    }
29986    const parts = myPath.split("[");
29987    if (parts.length !== 2) {
29988      console.log("Invalid parameter: " + myPath);
29989      return null;
29990    }
29991    const arrayIdx = Number(parts[1].substr(0, parts[1].length - 1));
29992    if (dst[parts[0]] === void 0) {
29993      dst[parts[0]] = [];
29994    }
29995    if (dst[parts[0]][arrayIdx] === void 0) {
29996      if (nextisarray) {
29997        dst[parts[0]][arrayIdx] = [];
29998      } else {
29999        dst[parts[0]][arrayIdx] = {};
30000      }
30001    }
30002    return dst[parts[0]][arrayIdx];
30003  }
30004};
30005__decorate([
30006  DoraPropertyDOC("Path del parametro", 0, "", 0, true),
30007  DoraProperty,
30008  __metadata("design:type", String)
30009], ChartOption.prototype, "path", void 0);
30010__decorate([
30011  DoraPropertyDOC("Type (<b>s</b>tring, <b>n</b>umber <b>b</b>oolean", 0, "s\xA7n\xA7b", 0, true),
30012  DoraProperty,
30013  __metadata("design:type", String)
30014], ChartOption.prototype, "type", void 0);
30015__decorate([
30016  DoraPropertyDOC("Value", 0, "", 0, true),
30017  DoraProperty,
30018  __metadata("design:type", String)
30019], ChartOption.prototype, "value", void 0);
30020
30021// src/app/Configuration/high-charts-parameters.ts
30022var HighChartsParameters = class {
30023  constructor() {
30024    this.highChartsParameterList = [];
30025    this.docRoot = "";
30026  }
30027  get HighChartsParameterList() {
30028    return this.highChartsParameterList;
30029  }
30030  get DocRoot() {
30031    return this.docRoot;
30032  }
30033  selectParameter(highChartDoc, idx, value) {
30034    this.highChartsParameterList = this.highChartsParameterList.slice(0, idx + 1);
30035    this.highChartsParameterList[this.highChartsParameterList.length - 1].Name = value;
30036    const highChartDocElement = this.getDocElementOfParameter(highChartDoc);
30037    this.highChartsParameterList[this.highChartsParameterList.length - 1].setType(highChartDocElement);
30038    const isLeaf = this.isLeaf(highChartDocElement);
30039    this.highChartsParameterList[this.highChartsParameterList.length - 1].IsLeaf = isLeaf;
30040    this.highChartsParameterList[this.highChartsParameterList.length - 1].Description = highChartDocElement.doclet.description;
30041    this.highChartsParameterList[this.highChartsParameterList.length - 1].Value = "";
30042    this.highChartsParameterList[this.highChartsParameterList.length - 1].Values = [];
30043    if (!isLeaf) {
30044      const options2 = this.getOptionsFromDoc(highChartDocElement);
30045      const lastChartParameter = new HighChartsParameter("", highChartDocElement, "", [], -1, "", options2, false);
30046      this.highChartsParameterList.push(lastChartParameter);
30047    }
30048  }
30049  setParameterValue(idx, value) {
30050    this.highChartsParameterList[idx].Value = value;
30051  }
30052  setParameterIdx(idx, value) {
30053    this.highChartsParameterList[idx].Idx = value;
30054  }
30055  /**
30056   * get value of parameter in format '§' separated as used in HTML
30057   */
30058  toString() {
30059    let result = "";
30060    this.highChartsParameterList.forEach((element) => {
30061      if (result !== "") {
30062        result += "\xA7";
30063      }
30064      result += element.toString();
30065    });
30066    return result;
30067  }
30068  /**
30069   * Convert to ChartOption
30070   */
30071  toChartOption() {
30072    let path2 = "";
30073    this.highChartsParameterList.forEach((element) => {
30074      if (path2 !== "") {
30075        path2 += "\\";
30076      }
30077      path2 += element.getPath();
30078    });
30079    const chartOption = new ChartOption();
30080    chartOption.path = path2;
30081    chartOption.type = this.highChartsParameterList[this.highChartsParameterList.length - 1].getType();
30082    chartOption.value = this.highChartsParameterList[this.highChartsParameterList.length - 1].Value;
30083    return chartOption;
30084  }
30085  /**
30086   * get doc element of parameter
30087   * @param highChartDoc
30088   * @param paramIdx index of parameter. -1 means last element
30089   * @protected
30090   */
30091  getDocElementOfParameter(highChartDoc, paramIdx = -1) {
30092    let currentIdx = 0;
30093    let highChartDocElement = this.getDocRoot(highChartDoc, this.docRoot);
30094    this.highChartsParameterList.forEach((element) => {
30095      if (paramIdx !== -1 && currentIdx === paramIdx) {
30096        return highChartDocElement;
30097      }
30098      const children = this.getChildren(highChartDocElement, highChartDoc);
30099      highChartDocElement = children[element.Name];
30100    });
30101    return highChartDocElement;
30102  }
30103  parse(highChartDoc, root, path2, value, valueType) {
30104    this.highChartsParameterList = [];
30105    this.docRoot = root;
30106    let highChartDocElement = this.getDocRoot(highChartDoc, this.docRoot);
30107    if (path2 === "") {
30108      const keys = Object.keys(highChartDocElement.children);
30109      if (keys.length > 0) {
30110        path2 = keys[0];
30111      }
30112    }
30113    const paths = path2.split("\\");
30114    paths.forEach((element) => {
30115      let options2 = this.getOptionsFromDoc(highChartDocElement);
30116      const idx = this.extractRootIdx(element);
30117      const purgedElement = element.replace(/\[.*?\]/g, "");
30118      const children = this.getChildren(highChartDocElement, highChartDoc);
30119      highChartDocElement = children[purgedElement];
30120      const description = highChartDocElement.doclet.description;
30121      const isLeaf = this.isLeaf(highChartDocElement);
30122      this.highChartsParameterList.push(new HighChartsParameter(purgedElement, highChartDocElement, value, [], idx, description, options2, isLeaf));
30123    });
30124  }
30125  /**
30126   * get root element from highChartDoc
30127   * @param highChartDoc
30128   * @param root may be in form 'root' or 'root.child1.child2'
30129   * @protected
30130   */
30131  getDocRoot(highChartDoc, root) {
30132    const elements = root.split(".");
30133    let result = highChartDoc[elements[0]];
30134    for (let idx = 1; idx < elements.length; idx++) {
30135      result = result.children[elements[idx]];
30136    }
30137    return result;
30138  }
30139  getOptionsFromDoc(highChartDocElement) {
30140    let options2 = [];
30141    Object.keys(highChartDocElement.children).forEach((key) => {
30142      options2.push(key);
30143    });
30144    return options2;
30145  }
30146  isLeaf(highChartDocElement) {
30147    if (highChartDocElement.children === void 0) {
30148      return true;
30149    }
30150    if (Object.keys(highChartDocElement.children).length === 0) {
30151      return true;
30152    }
30153    return false;
30154  }
30155  getChildren(highChartDocElement, highChartDoc) {
30156    const src = highChartDocElement.children;
30157    let result = _.cloneDeep(src);
30158    const parent = this.getElementFromExtends(highChartDocElement, highChartDoc);
30159    if (parent !== void 0) {
30160      result = _.merge(parent.children, highChartDocElement.children);
30161    }
30162    return result;
30163  }
30164  getElementFromExtends(highChartDocElement, highChartDoc) {
30165    let result = void 0;
30166    if (highChartDocElement.doclet.extends !== void 0) {
30167      const extendList = highChartDocElement.doclet.extends.toString().split(".");
30168      result = highChartDoc[extendList[0]];
30169      for (let idx = 1; idx < extendList.length; idx++) {
30170        result = result.children[extendList[idx]];
30171      }
30172    }
30173    return result;
30174  }
30175  /**
30176   * extract string containing root idx.
30177   * Eg. '[10]myParams'  return 10
30178   * @param path first path
30179   * @return -1 if no idx found
30180   */
30181  extractRootIdx(path2) {
30182    if (path2.startsWith("[") === false) {
30183      return -1;
30184    }
30185    const end = path2.indexOf("]");
30186    return Number.parseInt(path2.substring(1, end));
30187  }
30188};
30189
30190// src/app/Configuration/src-parameter-child.ts
30191var SrcParameterChild = class {
30192  constructor(parent, progressive, instance) {
30193    this.highchartsParameters = void 0;
30194    this.progressive = progressive;
30195    this.instance = instance;
30196    this.parent = parent;
30197  }
30198  get ProgressiveStr() {
30199    return this.progressive.toString();
30200  }
30201  get Progressive() {
30202    return this.progressive;
30203  }
30204  get Instance() {
30205    return this.instance;
30206  }
30207  get DocRoot() {
30208    return this.highchartsParameters?.DocRoot ?? "";
30209  }
30210  getHighChartsParameters(highChartDoc) {
30211    if (this.highchartsParameters === void 0) {
30212      if (!(this.Instance instanceof ChartOption) || this.parent.HighChartPath === "") {
30213        return new HighChartsParameters();
30214      }
30215      const chartOption = this.Instance;
30216      const path2 = chartOption.path;
30217      this.highchartsParameters = new HighChartsParameters();
30218      this.highchartsParameters.parse(highChartDoc, this.parent.HighChartPath, path2, chartOption.value, chartOption.type);
30219    }
30220    return this.highchartsParameters;
30221  }
30222  toString() {
30223    let result = "";
30224    this.highchartsParameters?.HighChartsParameterList.forEach((element) => {
30225      if (result !== "") {
30226        result += "\xA7";
30227      }
30228      result += element.toString();
30229    });
30230    return result;
30231  }
30232  toChartOption() {
30233    if (this.highchartsParameters === void 0) {
30234      console.error("HighChartsParameters is undefined");
30235      return new ChartOption();
30236    }
30237    return this.highchartsParameters.toChartOption();
30238  }
30239};
30240
30241// src/app/Configuration/src-parameter.ts
30242var SrcParameter = class {
30243  constructor(name) {
30244    this.descr = "Generic description";
30245    this.type = ATTRIBUTE_TYPE.STRING;
30246    this.dataProviderValueType = ATTRIBUTE_DATAPROVIDER_VALUES.NONE;
30247    this.values = [];
30248    this.highChartPath = "";
30249    this.name = name;
30250    this.children = null;
30251    this.childrenDefinition = null;
30252    this.constructionObject = null;
30253  }
30254  set HighChartPath(value) {
30255    this.highChartPath = value;
30256  }
30257  get HighChartPath() {
30258    return this.highChartPath;
30259  }
30260  get Children() {
30261    return this.children;
30262  }
30263  isMultiple() {
30264    return this.children === null ? false : true;
30265  }
30266  setMultiple(configurationService) {
30267    this.children = new Array();
30268    this.childrenDefinition = new Array();
30269    this.createChildDefinition(configurationService);
30270  }
30271  emptyChildren() {
30272    this.children = new Array();
30273  }
30274  createChild() {
30275    let result = void 0;
30276    if (this.isMultiple()) {
30277      const instance = new this.constructionObject();
30278      const progressive = this.getLastChildProgressive() + 1;
30279      result = new SrcParameterChild(this, progressive, instance);
30280      this.children.push(result);
30281    }
30282    return result;
30283  }
30284  addChild(instance) {
30285    let result = void 0;
30286    if (this.isMultiple()) {
30287      const progressive = this.getLastChildProgressive() + 1;
30288      result = new SrcParameterChild(this, progressive, instance);
30289      this.children.push(result);
30290    }
30291    return result;
30292  }
30293  removeChild(progressive) {
30294    let idx = -1;
30295    if (this.isMultiple()) {
30296      idx = this.getChildIdx(progressive);
30297      if (idx > -1) {
30298        this.children.splice(idx, 1);
30299      }
30300    }
30301    return idx;
30302  }
30303  createChildDefinition(configurationService) {
30304    const wrkChild = new this.constructionObject();
30305    this.childrenDefinition = configurationService.getParameterFromSource(wrkChild);
30306  }
30307  getChildIdx(progressive) {
30308    let idx = -1;
30309    if (this.isMultiple()) {
30310      idx = this.children.findIndex((child) => child.Progressive === progressive);
30311    }
30312    return idx;
30313  }
30314  getLastChildProgressive() {
30315    let lastProgressive = -1;
30316    if (this.isMultiple()) {
30317      this.children.forEach((child) => {
30318        if (child.Progressive > lastProgressive) {
30319          lastProgressive = child.Progressive;
30320        }
30321      });
30322    }
30323    return lastProgressive;
30324  }
30325  serialize(instance) {
30326    if (this.type === ATTRIBUTE_TYPE.ARRAY || this.type === ATTRIBUTE_TYPE.HIGHCHARTOPTIONS) {
30327      let result = "";
30328      if (this.isMultiple()) {
30329        instance.forEach((instanceElement) => {
30330          this.childrenDefinition.forEach((child) => {
30331            if (result !== "") {
30332              result += "\xA7";
30333            }
30334            result += this.serializeAttribute(instanceElement[child.name], child.type);
30335          });
30336        });
30337      }
30338      return result;
30339    } else {
30340      return this.serializeAttribute(instance, this.type);
30341    }
30342  }
30343  serializeAttribute(attributeInstance, type) {
30344    switch (type) {
30345      case ATTRIBUTE_TYPE.COLOR:
30346      case ATTRIBUTE_TYPE.STRING:
30347        return attributeInstance;
30348      case ATTRIBUTE_TYPE.FLOAT:
30349      case ATTRIBUTE_TYPE.INTEGER:
30350        return attributeInstance.toString();
30351      case ATTRIBUTE_TYPE.BOOLEAN:
30352        return attributeInstance ? "true" : "false";
30353      default:
30354        return "";
30355    }
30356  }
30357  toChartOptions() {
30358    const result = new Array();
30359    if (this.isMultiple()) {
30360      this.children.forEach((child) => {
30361        const chartOption = child.toChartOption();
30362        result.push(chartOption);
30363      });
30364    }
30365    return result;
30366  }
30367};
30368
30369// src/app/publisher/ipublisher.ts
30370var DataType;
30371(function(DataType2) {
30372  DataType2[DataType2["GRID"] = 0] = "GRID";
30373  DataType2[DataType2["GRIDS"] = 1] = "GRIDS";
30374  DataType2[DataType2["ROW"] = 2] = "ROW";
30375  DataType2[DataType2["ROWS"] = 3] = "ROWS";
30376  DataType2[DataType2["INTRADAY"] = 4] = "INTRADAY";
30377  DataType2[DataType2["HISTORICAL"] = 5] = "HISTORICAL";
30378  DataType2[DataType2["FUND_HISTORICAL"] = 6] = "FUND_HISTORICAL";
30379  DataType2[DataType2["DIVIDEND"] = 7] = "DIVIDEND";
30380  DataType2[DataType2["CORRECTION"] = 8] = "CORRECTION";
30381  DataType2[DataType2["LIST_NEWS"] = 9] = "LIST_NEWS";
30382  DataType2[DataType2["NEWS"] = 10] = "NEWS";
30383  DataType2[DataType2["META_LIST_GRIDS"] = 11] = "META_LIST_GRIDS";
30384  DataType2[DataType2["META_EXCEL_LIST"] = 12] = "META_EXCEL_LIST";
30385  DataType2[DataType2["CORPORATE_AGENT_QUERY"] = 13] = "CORPORATE_AGENT_QUERY";
30386  DataType2[DataType2["CORPORATE_AGENT_WIZARD"] = 14] = "CORPORATE_AGENT_WIZARD";
30387  DataType2[DataType2["R_OUTCONF"] = 15] = "R_OUTCONF";
30388  DataType2[DataType2["R_WIDGET"] = 16] = "R_WIDGET";
30389  DataType2[DataType2["R_WIDGET_PART"] = 17] = "R_WIDGET_PART";
30390  DataType2[DataType2["W_WIDGET"] = 18] = "W_WIDGET";
30391  DataType2[DataType2["W_WIDGET_PART"] = 19] = "W_WIDGET_PART";
30392})(DataType || (DataType = {}));
30393
30394// src/app/DoraData/data-base.ts
30395var TUPLA_TYPE;
30396(function(TUPLA_TYPE2) {
30397  TUPLA_TYPE2[TUPLA_TYPE2["STRING"] = 0] = "STRING";
30398  TUPLA_TYPE2[TUPLA_TYPE2["NUMBER"] = 1] = "NUMBER";
30399  TUPLA_TYPE2[TUPLA_TYPE2["PERCENTAGE"] = 2] = "PERCENTAGE";
30400  TUPLA_TYPE2[TUPLA_TYPE2["LINK"] = 3] = "LINK";
30401  TUPLA_TYPE2[TUPLA_TYPE2["BOOLEAN"] = 4] = "BOOLEAN";
30402  TUPLA_TYPE2[TUPLA_TYPE2["DATETIME"] = 5] = "DATETIME";
30403  TUPLA_TYPE2[TUPLA_TYPE2["UNDEFINED"] = 6] = "UNDEFINED";
30404})(TUPLA_TYPE || (TUPLA_TYPE = {}));
30405var DATA_TYPE;
30406(function(DATA_TYPE2) {
30407  DATA_TYPE2[DATA_TYPE2["Grid"] = 0] = "Grid";
30408  DATA_TYPE2[DATA_TYPE2["Row"] = 1] = "Row";
30409  DATA_TYPE2[DATA_TYPE2["Tupla"] = 2] = "Tupla";
30410  DATA_TYPE2[DATA_TYPE2["TuplaDescription"] = 3] = "TuplaDescription";
30411  DATA_TYPE2[DATA_TYPE2["SeriesHistorical"] = 4] = "SeriesHistorical";
30412  DATA_TYPE2[DATA_TYPE2["SeriesIntraday"] = 5] = "SeriesIntraday";
30413  DATA_TYPE2[DATA_TYPE2["SeriesFundHistorical"] = 6] = "SeriesFundHistorical";
30414  DATA_TYPE2[DATA_TYPE2["SeriesDividendCorrection"] = 7] = "SeriesDividendCorrection";
30415  DATA_TYPE2[DATA_TYPE2["Grids"] = 8] = "Grids";
30416  DATA_TYPE2[DATA_TYPE2["NewsList"] = 9] = "NewsList";
30417  DATA_TYPE2[DATA_TYPE2["News"] = 10] = "News";
30418})(DATA_TYPE || (DATA_TYPE = {}));
30419var CHART_TYPE;
30420(function(CHART_TYPE2) {
30421  CHART_TYPE2[CHART_TYPE2["LINEAR"] = 0] = "LINEAR";
30422  CHART_TYPE2[CHART_TYPE2["SPLINE"] = 1] = "SPLINE";
30423  CHART_TYPE2[CHART_TYPE2["CANDLESTICK"] = 2] = "CANDLESTICK";
30424  CHART_TYPE2[CHART_TYPE2["OHLC"] = 3] = "OHLC";
30425  CHART_TYPE2[CHART_TYPE2["AREA"] = 4] = "AREA";
30426  CHART_TYPE2[CHART_TYPE2["COLUMN"] = 5] = "COLUMN";
30427  CHART_TYPE2[CHART_TYPE2["PIE"] = 6] = "PIE";
30428  CHART_TYPE2[CHART_TYPE2["PIE_COLUMNGROUP"] = 7] = "PIE_COLUMNGROUP";
30429  CHART_TYPE2[CHART_TYPE2["COLUMNSTACK"] = 8] = "COLUMNSTACK";
30430  CHART_TYPE2[CHART_TYPE2["BAR"] = 9] = "BAR";
30431  CHART_TYPE2[CHART_TYPE2["STOCKLINEAR"] = 10] = "STOCKLINEAR";
30432  CHART_TYPE2[CHART_TYPE2["STOCKAREA"] = 11] = "STOCKAREA";
30433  CHART_TYPE2[CHART_TYPE2["STOCKAREASPLINE"] = 12] = "STOCKAREASPLINE";
30434})(CHART_TYPE || (CHART_TYPE = {}));
30435var DataBase = class DataBase2 {
30436  constructor() {
30437    this.id = "";
30438  }
30439  get SubscribeId() {
30440    return this.subscribeId;
30441  }
30442  set SubscribeId(value) {
30443    this.subscribeId = value;
30444  }
30445  get DataType() {
30446    return this.dataType;
30447  }
30448  set DataType(value) {
30449    this.dataType = value;
30450  }
30451  get Language() {
30452    return this.language;
30453  }
30454  set Language(value) {
30455    this.language = value;
30456  }
30457  get Id() {
30458    return this.id === void 0 ? " " : this.id;
30459  }
30460  set Id(value) {
30461    this.id = value;
30462  }
30463};
30464__decorate([
30465  jsonMember(String),
30466  __metadata("design:type", Object)
30467], DataBase.prototype, "dataType", void 0);
30468__decorate([
30469  jsonMember(String),
30470  __metadata("design:type", Object)
30471], DataBase.prototype, "language", void 0);
30472__decorate([
30473  jsonMember,
30474  __metadata("design:type", String)
30475], DataBase.prototype, "id", void 0);
30476DataBase = __decorate([
30477  jsonObject
30478], DataBase);
30479
30480// src/app/DoraWidget/dora-row/data/tupla.ts
30481var Tupla = class {
30482  constructor() {
30483    this.unitSx = "";
30484    this.key = "";
30485    this.unitDx = "";
30486    this.format = "";
30487  }
30488};
30489__decorate([
30490  DoraPropertyDOC("Unit\xE0 di misura a sinistra", 0, "", 0, true),
30491  DoraProperty,
30492  __metadata("design:type", String)
30493], Tupla.prototype, "unitSx", void 0);
30494__decorate([
30495  DoraPropertyDOC("Id riga", 0, "", 0, true),
30496  DoraProperty,
30497  __metadata("design:type", String)
30498], Tupla.prototype, "key", void 0);
30499__decorate([
30500  DoraPropertyDOC("Unit\xE0 di misura a destra", 0, "", 0, true),
30501  DoraProperty,
30502  __metadata("design:type", String)
30503], Tupla.prototype, "unitDx", void 0);
30504__decorate([
30505  DoraPropertyDOC("Formato valore", 0, "", 0, true),
30506  DoraProperty,
30507  __metadata("design:type", String)
30508], Tupla.prototype, "format", void 0);
30509
30510// src/app/DoraData/data-tupla-description.ts
30511var DataTuplaDescription_1;
30512var DataTuplaDescription = DataTuplaDescription_1 = class DataTuplaDescription2 extends DataBase {
30513  constructor() {
30514    super(...arguments);
30515    this.name = "";
30516    this.type = PARAM_TYPE.STRING.toString();
30517    this.chartDisabled = true;
30518    this._selected = false;
30519    this._visible = true;
30520    this._tooltipVisible = false;
30521  }
30522  // Getter & Setter
30523  get tooltipVisible() {
30524    return this._tooltipVisible;
30525  }
30526  set tooltipVisible(value) {
30527    this._tooltipVisible = value;
30528  }
30529  get selected() {
30530    return this._selected;
30531  }
30532  set selected(value) {
30533    this._selected = value;
30534  }
30535  get visible() {
30536    return this._visible;
30537  }
30538  set visible(value) {
30539    this._visible = value;
30540  }
30541  switchSelected() {
30542    this.selected = !this.selected;
30543  }
30544  get Type() {
30545    return TUPLA_TYPE[this.type];
30546  }
30547  get Name() {
30548    return this.name;
30549  }
30550  set Name(value) {
30551    this.name = value;
30552  }
30553  get ChartDisabled() {
30554    return this.chartDisabled;
30555  }
30556  /**
30557   * Create Tupla from TuplaDescription
30558   */
30559  createTupla() {
30560    const tupla = new Tupla();
30561    tupla.key = this.Id;
30562    return tupla;
30563  }
30564  // tslint:disable-next-line:member-ordering
30565  static createFromTupla(tupla, useValue = false) {
30566    let dataTuplaDescription;
30567    dataTuplaDescription = new DataTuplaDescription_1();
30568    dataTuplaDescription.Id = tupla.Id;
30569    dataTuplaDescription.Name = useValue ? tupla.Value : tupla.Id;
30570    dataTuplaDescription.type = tupla.Type.toString();
30571    dataTuplaDescription.visible = true;
30572    dataTuplaDescription.Language = "en";
30573    dataTuplaDescription.chartDisabled = false;
30574    return dataTuplaDescription;
30575  }
30576};
30577__decorate([
30578  jsonMember,
30579  __metadata("design:type", String)
30580], DataTuplaDescription.prototype, "name", void 0);
30581__decorate([
30582  jsonMember,
30583  __metadata("design:type", String)
30584], DataTuplaDescription.prototype, "type", void 0);
30585__decorate([
30586  jsonMember,
30587  __metadata("design:type", Boolean)
30588], DataTuplaDescription.prototype, "chartDisabled", void 0);
30589DataTuplaDescription = DataTuplaDescription_1 = __decorate([
30590  jsonObject
30591], DataTuplaDescription);
30592
30593// src/app/Utility/dora-number.ts
30594var DoraNumber = class {
30595  static formatNumber(value, locale, format) {
30596    if (format === void 0 || format === null) {
30597      format = "#.#";
30598    }
30599    if (locale === void 0 || locale === null) {
30600      locale = DoraGetLocale();
30601    }
30602    const posNegFormat = format.split(";");
30603    const flNegative = value < 0;
30604    const formatToUse = flNegative && posNegFormat.length > 1 ? posNegFormat[1] : posNegFormat[0];
30605    const intDecFormat = formatToUse.split(".");
30606    const flThousandSeparator = intDecFormat[0].search(",") < 0 ? false : true;
30607    let mainFormat = "1";
30608    if (intDecFormat.length > 1) {
30609      mainFormat += "." + this.countDigit(intDecFormat[1], /[#0]/g).toString();
30610      const fixedDecimal = this.countDigit(intDecFormat[1], /[0]/g);
30611      if (fixedDecimal > 0) {
30612        mainFormat += "-" + this.countDigit(intDecFormat[1], /[0]/g).toString();
30613      }
30614    } else {
30615      mainFormat += ".0-0";
30616    }
30617    let result = formatNumber(value, locale === null ? DoraGetLocale() : locale, mainFormat);
30618    if (flThousandSeparator === false) {
30619      result = result.replace(this.getThousandSeparator(locale), "");
30620    }
30621    if (formatToUse.charAt(0) === "(") {
30622      result = "(" + result.substring(1, result.length) + ")";
30623    }
30624    return result;
30625  }
30626  static countDigit(src, pattern) {
30627    const regExResult = src.match(pattern);
30628    return regExResult === null ? 0 : regExResult.length;
30629  }
30630  static getThousandSeparator(locale) {
30631    switch (locale === null ? DoraGetLocale() : locale) {
30632      case "de":
30633      case "fr":
30634      case "it":
30635        return ".";
30636      default:
30637        return ",";
30638    }
30639  }
30640};
30641
30642// src/app/DoraData/data-tupla.ts
30643var DataTupla_1;
30644var DataTupla = DataTupla_1 = class DataTupla2 extends DataBase {
30645  constructor() {
30646    super(...arguments);
30647    this.value = "";
30648    this.type = TUPLA_TYPE.UNDEFINED.toString();
30649    this.outputFormat = "";
30650    this.rowspan = 0;
30651  }
30652  get Rowspan() {
30653    return this.rowspan;
30654  }
30655  set Type(value) {
30656    this.type = TUPLA_TYPE[value];
30657  }
30658  get Type() {
30659    return TUPLA_TYPE[this.type];
30660  }
30661  get OutputFormat() {
30662    return this.outputFormat;
30663  }
30664  set OutputFormat(value) {
30665    this.outputFormat = value;
30666  }
30667  set Value(value) {
30668    this.value = value.toString();
30669  }
30670  get Value() {
30671    switch (this.Type) {
30672      case TUPLA_TYPE.BOOLEAN:
30673        return Boolean(this.value);
30674      case TUPLA_TYPE.NUMBER:
30675        return Number(this.value);
30676      case TUPLA_TYPE.STRING:
30677        return this.value;
30678      case TUPLA_TYPE.DATETIME:
30679        if (this.value === void 0) {
30680          return void 0;
30681        }
30682        return new Date(this.value);
30683      case TUPLA_TYPE.PERCENTAGE:
30684        return Number(this.value);
30685      // todo mancano altri casi
30686      default:
30687        return this.value;
30688    }
30689  }
30690  setValue(value, type) {
30691    this.Value = value;
30692    this.Type = type;
30693  }
30694  /**
30695   * get value formatted. If type == STRING trim value for blank and ", translate value
30696   * @param zeroValue value to return if value is 0
30697   * @param defaultFormat default format to use if outputFormat is not defined
30698   * @param translationService translation service to use
30699   */
30700  getTrimmedValue(zeroValue, defaultFormat, translationService = null) {
30701    let result = this.getFormattedValue(zeroValue, defaultFormat);
30702    if (this.Type === TUPLA_TYPE.STRING) {
30703      result = result.trim();
30704      if (result.startsWith('"')) {
30705        result = result.substring(1);
30706      }
30707      if (result.endsWith('"')) {
30708        result = result.substring(0, result.length - 1);
30709      }
30710      if (translationService !== null && translationService.keyExist(this.Id + "_" + result) === true) {
30711        result = translationService.get(this.Id + "_" + result);
30712      }
30713    }
30714    return result;
30715  }
30716  getFormattedValue(zeroValue, defaultFormat) {
30717    switch (this.Type) {
30718      case TUPLA_TYPE.NUMBER:
30719        if (this.Value === 0) {
30720          return zeroValue;
30721        }
30722        return DoraNumber.formatNumber(this.Value, null, this.outputFormat === void 0 || this.outputFormat === "" ? defaultFormat : this.outputFormat);
30723      // return formatNumber(this.Value, 'en', '1.1-3');
30724      case TUPLA_TYPE.PERCENTAGE:
30725        if (this.Value === 0) {
30726          return zeroValue;
30727        }
30728        return DoraNumber.formatNumber(this.Value * 100, null, this.outputFormat === void 0 || this.outputFormat === "" ? defaultFormat : this.outputFormat);
30729      case TUPLA_TYPE.DATETIME:
30730        const localDate = formatDate(this.Value, "shortDate", DoraGetLocale());
30731        return localDate;
30732      default:
30733        return this.Value;
30734    }
30735  }
30736  clone() {
30737    const result = new DataTupla_1();
30738    result.setValue(this.Value, this.Type);
30739    result.outputFormat = this.outputFormat;
30740    result.Id = this.Id;
30741    result.Language = this.Language;
30742    return result;
30743  }
30744};
30745__decorate([
30746  jsonMember(String),
30747  __metadata("design:type", String)
30748], DataTupla.prototype, "value", void 0);
30749__decorate([
30750  jsonMember,
30751  __metadata("design:type", String)
30752], DataTupla.prototype, "type", void 0);
30753__decorate([
30754  jsonMember(String),
30755  __metadata("design:type", Object)
30756], DataTupla.prototype, "inputFormat", void 0);
30757__decorate([
30758  jsonMember(String),
30759  __metadata("design:type", String)
30760], DataTupla.prototype, "outputFormat", void 0);
30761__decorate([
30762  jsonMember(String),
30763  __metadata("design:type", Object)
30764], DataTupla.prototype, "url", void 0);
30765__decorate([
30766  jsonMember(Number),
30767  __metadata("design:type", Number)
30768], DataTupla.prototype, "rowspan", void 0);
30769__decorate([
30770  jsonMember(String),
30771  __metadata("design:type", Object)
30772], DataTupla.prototype, "customClass", void 0);
30773DataTupla = DataTupla_1 = __decorate([
30774  jsonObject
30775], DataTupla);
30776
30777// src/app/DoraData/data-row.ts
30778var DataRow_1;
30779var DataRow = DataRow_1 = class DataRow2 extends DataBase {
30780  constructor() {
30781    super(...arguments);
30782    this.gwtTuplas = [];
30783    this.level = 0;
30784    this.note = "";
30785    this.units = "";
30786    this.selectable = false;
30787    this.rangeMin = void 0;
30788    this.rangeMax = void 0;
30789    this.gridId = void 0;
30790    this.gridId2 = void 0;
30791    this.tooltipLink = void 0;
30792    this.tooltipLinkDescription = void 0;
30793    this.cssFormat = "";
30794    this.defaultChartType = CHART_TYPE.LINEAR.toString();
30795    this._selected = false;
30796  }
30797  // Getter and setter
30798  get Note() {
30799    return this.note;
30800  }
30801  get DefaultChartType() {
30802    return this.defaultChartType === void 0 ? CHART_TYPE.LINEAR : CHART_TYPE[this.defaultChartType];
30803  }
30804  get DataTuplas() {
30805    return this.gwtTuplas;
30806  }
30807  set DataTuplas(value) {
30808    this.gwtTuplas = value;
30809  }
30810  get GridId() {
30811    return this.gridId;
30812  }
30813  get GridId2() {
30814    return this.gridId2;
30815  }
30816  get CssFormat() {
30817    return this.cssFormat;
30818  }
30819  set CssFormat(value) {
30820    this.cssFormat = value;
30821  }
30822  addCssClass(cssClass) {
30823    if (this.cssFormat === null || this.cssFormat === void 0 || this.CssFormat === "") {
30824      this.CssFormat = cssClass;
30825    } else {
30826      this.CssFormat += " " + cssClass;
30827    }
30828  }
30829  removeCssClass(cssClass) {
30830    if (this.cssFormat === null || this.cssFormat === void 0 || this.CssFormat === "") {
30831      return;
30832    } else {
30833      this.CssFormat = this.CssFormat.replace(cssClass, "");
30834    }
30835  }
30836  get Selectable() {
30837    return this.selectable;
30838  }
30839  set Selectable(value) {
30840    this.selectable = value;
30841  }
30842  getDataTupla(tuplaId) {
30843    return this.DataTuplas.find((x) => x.Id === tuplaId);
30844  }
30845  getTuplaValue(tuplaId, defaultValue) {
30846    const tupla = this.getDataTupla(tuplaId);
30847    if (tupla === void 0) {
30848      return defaultValue;
30849    } else {
30850      return tupla.Value;
30851    }
30852  }
30853  get Units() {
30854    return this.units;
30855  }
30856  get selected() {
30857    return this._selected;
30858  }
30859  set selected(value) {
30860    if (this.Selectable) {
30861      this._selected = value;
30862    }
30863  }
30864  get Description() {
30865    return this.getTuplaValue("Description", this.Id);
30866  }
30867  get Level() {
30868    return this.level;
30869  }
30870  swapSelected() {
30871    if (this.Selectable) {
30872      this._selected = !this.selected;
30873    }
30874  }
30875  get Color() {
30876    return this.color;
30877  }
30878  set Color(value) {
30879    this.color = value;
30880  }
30881  /**
30882   * Return colspan value:
30883   * 0: no collspan
30884   * -1: col to not display
30885   * > 0: colspan to set
30886   */
30887  getColSpan(tuplaIdx) {
30888    if (this.gwtTuplas[tuplaIdx].Rowspan === void 0 || this.gwtTuplas[tuplaIdx].Rowspan !== 1) {
30889      return 0;
30890    }
30891    if (tuplaIdx === 0 || this.gwtTuplas[tuplaIdx - 1].Rowspan !== 1) {
30892      let colspan = 1;
30893      for (let idx = tuplaIdx + 1; idx < this.gwtTuplas.length && this.gwtTuplas[idx].Rowspan === 1; idx++) {
30894        colspan++;
30895      }
30896      return colspan;
30897    }
30898    return -1;
30899  }
30900  /**
30901   * Costruisce TuplasDescription partendo dalle tuplas.
30902   */
30903  buildColumnDescription() {
30904    const result = [];
30905    this.gwtTuplas.forEach((tupla) => {
30906      if (tupla.Id !== "Units") {
30907        const tuplaDescription = DataTuplaDescription.createFromTupla(tupla);
30908        result.push(tuplaDescription);
30909      }
30910    });
30911    return result;
30912  }
30913  /**
30914   * Clone this DataRow
30915   */
30916  clone() {
30917    const result = new DataRow_1();
30918    result.Id = this.Id;
30919    result.DataType = this.DataType;
30920    result.Language = this.Language;
30921    result.level = this.level;
30922    result.note = this.note;
30923    result.units = this.units;
30924    result.unitsLevel = this.unitsLevel;
30925    result.selectable = this.selectable;
30926    result.rangeEnabled = this.rangeEnabled;
30927    result.rangeMin = this.rangeMin;
30928    result.rangeMax = this.rangeMax;
30929    result.color = this.color;
30930    result.gridId = this.gridId;
30931    result.gridId2 = this.gridId2;
30932    result.tooltipLink = this.tooltipLink;
30933    result.tooltipLinkDescription = this.tooltipLinkDescription;
30934    result.cssFormat = this.cssFormat;
30935    result.chartEnabled = this.chartEnabled;
30936    result.hasChildren = this.hasChildren;
30937    result.defaultChartType = this.defaultChartType;
30938    this.gwtTuplas.forEach((tupla) => {
30939      result.DataTuplas.push(tupla.clone());
30940    });
30941    return result;
30942  }
30943};
30944__decorate([
30945  jsonArrayMember(DataTupla),
30946  __metadata("design:type", Array)
30947], DataRow.prototype, "gwtTuplas", void 0);
30948__decorate([
30949  jsonMember,
30950  __metadata("design:type", Number)
30951], DataRow.prototype, "level", void 0);
30952__decorate([
30953  jsonMember,
30954  __metadata("design:type", String)
30955], DataRow.prototype, "note", void 0);
30956__decorate([
30957  jsonMember,
30958  __metadata("design:type", String)
30959], DataRow.prototype, "units", void 0);
30960__decorate([
30961  jsonMember(Number),
30962  __metadata("design:type", Object)
30963], DataRow.prototype, "unitsLevel", void 0);
30964__decorate([
30965  jsonMember,
30966  __metadata("design:type", Boolean)
30967], DataRow.prototype, "selectable", void 0);
30968__decorate([
30969  jsonMember(Boolean),
30970  __metadata("design:type", Object)
30971], DataRow.prototype, "rangeEnabled", void 0);
30972__decorate([
30973  jsonMember(Number),
30974  __metadata("design:type", Object)
30975], DataRow.prototype, "rangeMin", void 0);
30976__decorate([
30977  jsonMember(Number),
30978  __metadata("design:type", Object)
30979], DataRow.prototype, "rangeMax", void 0);
30980__decorate([
30981  jsonMember(String),
30982  __metadata("design:type", Object)
30983], DataRow.prototype, "color", void 0);
30984__decorate([
30985  jsonMember(String),
30986  __metadata("design:type", Object)
30987], DataRow.prototype, "gridId", void 0);
30988__decorate([
30989  jsonMember(String),
30990  __metadata("design:type", Object)
30991], DataRow.prototype, "gridId2", void 0);
30992__decorate([
30993  jsonMember(String),
30994  __metadata("design:type", Object)
30995], DataRow.prototype, "tooltipLink", void 0);
30996__decorate([
30997  jsonMember(String),
30998  __metadata("design:type", Object)
30999], DataRow.prototype, "tooltipLinkDescription", void 0);
31000__decorate([
31001  jsonMember,
31002  __metadata("design:type", String)
31003], DataRow.prototype, "cssFormat", void 0);
31004__decorate([
31005  jsonMember(Boolean),
31006  __metadata("design:type", Object)
31007], DataRow.prototype, "chartEnabled", void 0);
31008__decorate([
31009  jsonMember(Boolean),
31010  __metadata("design:type", Object)
31011], DataRow.prototype, "hasChildren", void 0);
31012__decorate([
31013  jsonMember,
31014  __metadata("design:type", String)
31015], DataRow.prototype, "defaultChartType", void 0);
31016DataRow = DataRow_1 = __decorate([
31017  jsonObject
31018], DataRow);
31019
31020// src/app/DoraData/data-series.ts
31021var DataSeries_1;
31022var DataSeries = DataSeries_1 = class DataSeries2 extends DataBase {
31023  constructor() {
31024    super(...arguments);
31025    this.description = "";
31026    this.unit = "";
31027    this.columnsDescription = [];
31028    this.rows = [];
31029    this.firstValue = void 0;
31030    this.rangeMin = void 0;
31031    this.rangeMax = void 0;
31032    this.fixedSeries = false;
31033    this.color = void 0;
31034    this.idRowsOrigin = void 0;
31035  }
31036  set IdRowsOrigin(value) {
31037    this.idRowsOrigin = value;
31038  }
31039  get IdRowsOrigin() {
31040    return this.idRowsOrigin === void 0 ? [] : this.idRowsOrigin;
31041  }
31042  set FirstValue(value) {
31043    this.firstValue = value;
31044  }
31045  get FirstValue() {
31046    if (this.firstValue !== void 0) {
31047      return this.firstValue;
31048    }
31049    if (this.rows.length === 0) {
31050      return null;
31051    }
31052    const firstRow = this.rows[0];
31053    const firstTupla = firstRow.getDataTupla("Close");
31054    if (firstTupla === void 0) {
31055      return null;
31056    }
31057    return firstTupla.Value;
31058  }
31059  get Color() {
31060    return this.color;
31061  }
31062  set Color(value) {
31063    this.color = value;
31064  }
31065  get FixedSeries() {
31066    return this.fixedSeries;
31067  }
31068  set FixedSeries(value) {
31069    this.fixedSeries = value;
31070  }
31071  get Units() {
31072    return this.unit;
31073  }
31074  set Units(value) {
31075    this.unit = value;
31076  }
31077  get Description() {
31078    return this.description;
31079  }
31080  set Description(value) {
31081    this.description = value;
31082  }
31083  get TuplasDescription() {
31084    return this.columnsDescription;
31085  }
31086  set TuplasDescription(value) {
31087    this.columnsDescription = value;
31088  }
31089  get DataRows() {
31090    return this.rows;
31091  }
31092  set DataRows(value) {
31093    this.rows = value;
31094  }
31095  get RangeMin() {
31096    return this.rangeMin;
31097  }
31098  set RangeMin(value) {
31099    this.rangeMin = value;
31100  }
31101  get RangeMax() {
31102    return this.rangeMax;
31103  }
31104  set RangeMax(value) {
31105    this.rangeMax = value;
31106  }
31107  /**
31108   * Get Tupla Description by Id
31109   * @param id Tupla Id
31110   */
31111  getTuplaDescriptionById(id) {
31112    return this.columnsDescription.find((tupla) => {
31113      return tupla.Id === id;
31114    });
31115  }
31116  filterByDateRange(dateRange) {
31117    const result = new DataSeries_1();
31118    result.Description = this.Description;
31119    result.Units = this.Units;
31120    result.Color = this.Color;
31121    result.TuplasDescription = this.TuplasDescription;
31122    if (this.getTuplaDescriptionById("Timestamp") === void 0 || dateRange === void 0) {
31123      result.DataRows = this.DataRows.filter((row) => {
31124        return true;
31125      });
31126      return result;
31127    }
31128    result.DataRows = this.DataRows.filter((row) => {
31129      const timestampTupla = row.getDataTupla("Timestamp");
31130      if (timestampTupla === void 0) {
31131        return false;
31132      }
31133      return dateRange.isDateInRange(timestampTupla.Value);
31134    });
31135    return result;
31136  }
31137  getMinValue() {
31138    let result = Number.MAX_VALUE;
31139    this.DataRows.forEach((row) => {
31140      const tupla = row.getDataTupla("Close");
31141      if (tupla !== void 0) {
31142        const value = tupla.Value;
31143        if (value < result) {
31144          result = value;
31145        }
31146      }
31147    });
31148    return result;
31149  }
31150  getMaxValue() {
31151    let result = Number.MIN_VALUE;
31152    this.DataRows.forEach((row) => {
31153      const tupla = row.getDataTupla("Close");
31154      if (tupla !== void 0) {
31155        const value = tupla.Value;
31156        if (value > result) {
31157          result = value;
31158        }
31159      }
31160    });
31161    return result;
31162  }
31163};
31164__decorate([
31165  jsonMember,
31166  __metadata("design:type", String)
31167], DataSeries.prototype, "description", void 0);
31168__decorate([
31169  jsonMember,
31170  __metadata("design:type", String)
31171], DataSeries.prototype, "unit", void 0);
31172__decorate([
31173  jsonArrayMember(DataTuplaDescription),
31174  __metadata("design:type", Array)
31175], DataSeries.prototype, "columnsDescription", void 0);
31176__decorate([
31177  jsonArrayMember(DataRow),
31178  __metadata("design:type", Array)
31179], DataSeries.prototype, "rows", void 0);
31180__decorate([
31181  jsonMember(Number),
31182  __metadata("design:type", Object)
31183], DataSeries.prototype, "firstValue", void 0);
31184DataSeries = DataSeries_1 = __decorate([
31185  jsonObject
31186], DataSeries);
31187
31188// src/app/DoraData/data-grid.ts
31189var DataGrid = class DataGrid2 extends DataBase {
31190  constructor() {
31191    super(...arguments);
31192    this.description = "description";
31193  }
31194  get DefaultChartType() {
31195    if (this.defaultChartType === void 0) {
31196      throw new Error("DefaultChartType is undefined");
31197    }
31198    return CHART_TYPE[this.defaultChartType];
31199  }
31200  get DataRows() {
31201    if (this.gwtRows === void 0) {
31202      throw new Error("DataRows is undefined");
31203    }
31204    return this.gwtRows;
31205  }
31206  get Notes() {
31207    if (this.notes === void 0) {
31208      return [];
31209    }
31210    return this.notes;
31211  }
31212  /**
31213   * Get row by id
31214   * @param rowId ror to find
31215   * @return undefined if not found
31216   */
31217  getDataRow(rowId) {
31218    if (this.DataRows === void 0) {
31219      throw new Error("DataRows is undefined");
31220    }
31221    return this.DataRows.find((x) => x.Id === rowId);
31222  }
31223  // Utilities
31224  /**
31225   * Get all visible tuplas from specific row
31226   * @param rowIdx 0 based
31227   */
31228  getRowDataTuplaDescriptionVisible(rowIdx) {
31229    if (rowIdx >= this.DataRows.length) {
31230      console.error("Requested rowIdx " + rowIdx + " in table with " + this.DataRows.length + " rows");
31231      return [];
31232    }
31233    const dataRow = this.DataRows[rowIdx];
31234    const columnsVisible = this.getColumnsVisible();
31235    const result = [];
31236    columnsVisible.forEach((columnId) => {
31237      const dataTupla = dataRow.getDataTupla(columnId);
31238      if (dataTupla !== void 0) {
31239        result.push(dataTupla);
31240      }
31241    });
31242    return result;
31243  }
31244  /**
31245   * Get all tuplas descrition visible
31246   */
31247  getTuplasDescriptionVisible() {
31248    if (this.tuplasDescription === void 0) {
31249      return [];
31250    }
31251    const result = this.tuplasDescription.filter((dataTuplaDescription) => dataTuplaDescription.visible === true);
31252    return result;
31253  }
31254  setAllColumnsInvisible() {
31255    if (this.tuplasDescription === void 0) {
31256      return;
31257    }
31258    this.tuplasDescription.forEach((dataTuplaDescription) => dataTuplaDescription.visible = false);
31259  }
31260  setColumnsVisible(columnIdList) {
31261    if (this.tuplasDescription === void 0) {
31262      return;
31263    }
31264    this.tuplasDescription.forEach((dataTuplaDescription) => {
31265      if (columnIdList.find((x) => x === dataTuplaDescription.Id) === void 0) {
31266        dataTuplaDescription.visible = false;
31267      } else {
31268        dataTuplaDescription.visible = true;
31269      }
31270    });
31271  }
31272  getColumnsVisible() {
31273    const result = [];
31274    if (this.tuplasDescription === void 0) {
31275      return result;
31276    }
31277    this.tuplasDescription.forEach((dataTuplaDescription) => {
31278      if (dataTuplaDescription.visible) {
31279        result.push(dataTuplaDescription.Id);
31280      }
31281    });
31282    return result;
31283  }
31284  /**
31285   * Select a row and unselect others
31286   * @param rowId row id. If doesn't exist nothing append
31287   */
31288  selectRowMutex(rowId) {
31289    if (this.getDataRow(rowId) === void 0) {
31290      console.error("Row " + rowId + "not found in table " + this.Id);
31291      return;
31292    }
31293    for (const dataRow of this.DataRows) {
31294      dataRow.selected = dataRow.Id === rowId ? true : false;
31295    }
31296  }
31297  /**
31298   * Select all rows contained into the list. Id not contained into the list are set to unselected
31299   * @param idsRow list of id row to select
31300   */
31301  selectRows(idsRow) {
31302    this.DataRows.forEach((dataRow) => {
31303      dataRow.selected = idsRow.find((x) => x === dataRow.Id) === void 0 ? false : true;
31304    });
31305  }
31306  selectRowsById(ids) {
31307    this.DataRows.forEach((dataRow) => {
31308      dataRow.selected = ids.find((x) => x.key === dataRow.Id) !== void 0;
31309    });
31310  }
31311  selectRowsByDescription(descriptions) {
31312    if (this.DataRows === void 0) {
31313      return;
31314    }
31315    this.DataRows.forEach((dataRow) => {
31316      const rowValue = dataRow.getDataTupla("Description")?.Value;
31317      const isPresent2 = descriptions.find((x) => typeof x.key === "string" && typeof rowValue === "string" && x.key.toLowerCase() === rowValue.toLowerCase()) !== void 0;
31318      if (isPresent2) {
31319        dataRow.selected = true;
31320      } else {
31321        dataRow.selected = false;
31322      }
31323    });
31324  }
31325  /**
31326   * Unselect rows
31327   */
31328  filterRowsById(ids) {
31329    if (this.gwtRows === void 0)
31330      return;
31331    this.gwtRows = this.gwtRows.filter((row) => ids.includes(row.Id));
31332  }
31333  unselectRows(idsRow) {
31334    this.DataRows.forEach((dataRow) => {
31335      const isPresent2 = idsRow.find((x) => x === dataRow.Id) !== void 0;
31336      if (isPresent2) {
31337        dataRow.selected = false;
31338      }
31339    });
31340  }
31341  /**
31342   * Select all selectable rows
31343   */
31344  selectAllRows() {
31345    this.DataRows.forEach((dataRow) => {
31346      dataRow.selected = true;
31347    });
31348  }
31349  rowsSelected2Series(reverse, columnIds = null, invertColumnsRows = false) {
31350    const rowIds = [];
31351    this.DataRows.forEach((dataRow) => {
31352      if (dataRow.selected) {
31353        rowIds.push(dataRow.Id);
31354      }
31355    });
31356    return this.rows2Series(rowIds, columnIds, reverse, invertColumnsRows);
31357  }
31358  rows2Series(rowIds, columnIds, reverse, invertColumnsRows = false) {
31359    const datasSeries = [];
31360    let rowsFiltered = [];
31361    rowsFiltered = rowIds !== null ? this.DataRows.filter((src) => {
31362      return rowIds.find((value) => value === src.Id) !== void 0 ? true : false;
31363    }) : this.DataRows;
31364    if (this.tuplasDescription === void 0) {
31365      console.error("No tuplas description found in table " + this.Id);
31366      return [];
31367    }
31368    const tuplasDescription = this.tuplasDescription.filter((tuplaSecription) => {
31369      if (tuplaSecription.Type !== TUPLA_TYPE.NUMBER) {
31370        return false;
31371      }
31372      if (columnIds === null || columnIds.length === 0) {
31373        return true;
31374      }
31375      return columnIds.find((value) => value === tuplaSecription.Name) !== void 0 ? true : false;
31376    });
31377    if (invertColumnsRows) {
31378      tuplasDescription.forEach((dataTuplaDescription, index) => {
31379        const dataSeries = new DataSeries();
31380        if (index === 0) {
31381          dataSeries.IdRowsOrigin = rowIds;
31382        }
31383        dataSeries.Description = dataTuplaDescription.Name;
31384        if (rowsFiltered.length > 0) {
31385          dataSeries.TuplasDescription = [];
31386          rowsFiltered.forEach((row) => {
31387            let dataTupla = row.getDataTupla("Description");
31388            if (dataTupla !== void 0) {
31389              dataSeries.TuplasDescription.push(DataTuplaDescription.createFromTupla(dataTupla, true));
31390            }
31391          });
31392        }
31393        rowsFiltered.forEach((dataRowSrc) => {
31394          dataSeries.Units = dataRowSrc.Units;
31395          const tupla = dataRowSrc.getDataTupla(dataTuplaDescription.Name);
31396          if (tupla === void 0) {
31397            console.error("Tupla " + dataTuplaDescription.Name + " not found in row " + dataRowSrc.Id);
31398          } else {
31399            const dataRowNew = new DataRow();
31400            let tuplaNew;
31401            tuplaNew = new DataTupla();
31402            tuplaNew.setValue(dataRowSrc.Description, TUPLA_TYPE.STRING);
31403            dataRowNew.DataTuplas.push(tuplaNew);
31404            tuplaNew = new DataTupla();
31405            tuplaNew.setValue(tupla.Value, TUPLA_TYPE.NUMBER);
31406            tuplaNew.OutputFormat = tupla.OutputFormat;
31407            dataRowNew.DataTuplas.push(tuplaNew);
31408            dataSeries.DataRows.push(dataRowNew);
31409          }
31410        });
31411        datasSeries.push(dataSeries);
31412      });
31413    } else {
31414      rowsFiltered.forEach((dataRowSrc, index) => {
31415        const dataSeries = new DataSeries();
31416        if (index === 0) {
31417          dataSeries.IdRowsOrigin = rowIds;
31418        }
31419        dataSeries.Description = dataRowSrc.Description;
31420        dataSeries.Units = dataRowSrc.Units;
31421        dataSeries.TuplasDescription = reverse ? tuplasDescription.reverse() : tuplasDescription;
31422        dataSeries.TuplasDescription.forEach((tuplaDescription) => {
31423          const tupla = dataRowSrc.getDataTupla(tuplaDescription.Name);
31424          if (tupla === void 0) {
31425            console.error("Tupla " + tuplaDescription.Name + " not found in row " + dataRowSrc.Id);
31426          } else {
31427            const dataRowNew = new DataRow();
31428            let tuplaNew;
31429            tuplaNew = new DataTupla();
31430            tuplaNew.setValue(tuplaDescription.Name, TUPLA_TYPE.STRING);
31431            dataRowNew.DataTuplas.push(tuplaNew);
31432            tuplaNew = new DataTupla();
31433            tuplaNew.setValue(tupla.Value, TUPLA_TYPE.NUMBER);
31434            tuplaNew.OutputFormat = tupla.OutputFormat;
31435            dataRowNew.DataTuplas.push(tuplaNew);
31436            dataSeries.DataRows.push(dataRowNew);
31437          }
31438        });
31439        datasSeries.push(dataSeries);
31440      });
31441    }
31442    return datasSeries;
31443  }
31444  selectColumnsByType(columnType) {
31445    if (this.tuplasDescription === void 0) {
31446      return;
31447    }
31448    this.tuplasDescription.forEach((tuplaDescription) => {
31449      if (tuplaDescription.Type === columnType) {
31450        tuplaDescription.selected = true;
31451      }
31452    });
31453  }
31454  selectColumnById(columnsId) {
31455    if (this.tuplasDescription === void 0) {
31456      return;
31457    }
31458    this.tuplasDescription.forEach((tuplaDescription) => {
31459      if (columnsId.find((x) => x.key === tuplaDescription.Id) !== void 0) {
31460        tuplaDescription.selected = true;
31461      } else {
31462        tuplaDescription.selected = false;
31463      }
31464    });
31465  }
31466  getSelectedColumns() {
31467    if (this.tuplasDescription === void 0) {
31468      return [];
31469    }
31470    return this.tuplasDescription.filter((tuplaDescription) => {
31471      return tuplaDescription.selected;
31472    });
31473  }
31474  /**
31475   * Get all selected columns Id
31476   */
31477  getIdSelectedColumns() {
31478    const result = [];
31479    this.getSelectedColumns().forEach((dataTuplaDescription) => {
31480      result.push(dataTuplaDescription.Id);
31481    });
31482    return result;
31483  }
31484  /**
31485   * get all selected row
31486   */
31487  getSelectedRows() {
31488    return this.DataRows.filter((row) => {
31489      return row.selected;
31490    });
31491  }
31492  /**
31493   * get all Ids of selected row
31494   */
31495  getIdSelectedRows() {
31496    const result = [];
31497    this.getSelectedRows().forEach((dataRow) => {
31498      result.push(dataRow.Id);
31499    });
31500    return result;
31501  }
31502  getTuplaDescription(id) {
31503    if (this.tuplasDescription === void 0) {
31504      throw new Error("TuplaDescription is undefined");
31505    }
31506    const dataTuplaDescription = this.tuplasDescription.find((x) => x.Id === id);
31507    if (dataTuplaDescription === void 0) {
31508      throw new Error("TuplaDescription " + id + " not found");
31509    }
31510    return dataTuplaDescription;
31511  }
31512  /**
31513   * Flag select attribut
31514   * @param columnIds List of column to enable
31515   */
31516  selectTuplaDescription(columnIds) {
31517    if (this.tuplasDescription === void 0) {
31518      return;
31519    }
31520    this.tuplasDescription.forEach((tuplaDescription) => {
31521      if (columnIds.find((x) => x === tuplaDescription.Id) === void 0) {
31522        tuplaDescription.selected = false;
31523      } else {
31524        tuplaDescription.selected = true;
31525      }
31526    });
31527  }
31528};
31529__decorate([
31530  jsonMember(String),
31531  __metadata("design:type", Object)
31532], DataGrid.prototype, "description", void 0);
31533__decorate([
31534  jsonArrayMember(DataTuplaDescription),
31535  __metadata("design:type", Object)
31536], DataGrid.prototype, "tuplasDescription", void 0);
31537__decorate([
31538  jsonArrayMember(DataRow),
31539  __metadata("design:type", Object)
31540], DataGrid.prototype, "gwtRows", void 0);
31541__decorate([
31542  jsonArrayMember(String),
31543  __metadata("design:type", Object)
31544], DataGrid.prototype, "notes", void 0);
31545__decorate([
31546  jsonMember(String),
31547  __metadata("design:type", Object)
31548], DataGrid.prototype, "defaultChartType", void 0);
31549DataGrid = __decorate([
31550  jsonObject
31551], DataGrid);
31552
31553// src/app/Configuration/component-type.enum.ts
31554var ComponentType;
31555(function(ComponentType2) {
31556  ComponentType2[ComponentType2["Widgets"] = 0] = "Widgets";
31557  ComponentType2[ComponentType2["Publishers"] = 1] = "Publishers";
31558})(ComponentType || (ComponentType = {}));
31559
31560// src/app/publisher/data/read-result.ts
31561var ReadResult = class {
31562  // tslint:disable-next-line:ban-types
31563  constructor(callerData, data) {
31564    this.callerData = callerData;
31565    this.data = data;
31566  }
31567  // tslint:disable-next-line:ban-types
31568  get CallerData() {
31569    return this.callerData;
31570  }
31571  get Data() {
31572    return this.data;
31573  }
31574};
31575
31576// src/app/publisher/DataManagement/publisher-data-management.ts
31577var PublisherDataManagement = class {
31578  constructor(http, progressive) {
31579    this.http = http;
31580    this.baseUrl = "";
31581    this.project = "";
31582    this.language = "it";
31583    this.xlsxid = "";
31584    this.progressive = "1";
31585    this.initializer = void 0;
31586    this.progressive = progressive;
31587    this.language = DoraGetLocale();
31588  }
31589  reset() {
31590    ;
31591  }
31592  // tslint:disable-next-line:ban-types
31593  read(publisherParameters, subscribeObjInfo, dataType, callerData) {
31594    let completeUrl = this.baseUrl;
31595    switch (dataType) {
31596      case DataType.GRID:
31597      case DataType.GRIDS:
31598      case DataType.ROW:
31599      case DataType.ROWS:
31600      case DataType.INTRADAY:
31601      case DataType.HISTORICAL:
31602      case DataType.FUND_HISTORICAL:
31603      case DataType.DIVIDEND:
31604      case DataType.CORRECTION:
31605      case DataType.LIST_NEWS:
31606      case DataType.NEWS:
31607        completeUrl += "/getdataout" + this.getParameterForUrl(publisherParameters) + "&dataId=" + subscribeObjInfo[0] + "&dataType=" + this.dataType2String(dataType);
31608        break;
31609      case DataType.META_LIST_GRIDS:
31610        completeUrl += "/listdataout" + this.getParameterForUrl(publisherParameters) + "&dataType=Grid";
31611        break;
31612      case DataType.META_EXCEL_LIST:
31613        completeUrl += "/getxlsxlist" + this.getParameterForUrl(publisherParameters) + "&dataId=" + subscribeObjInfo[0] + "&dataType=Grids";
31614        break;
31615      default:
31616        console.error("DataType not supported: " + dataType);
31617        break;
31618    }
31619    console.log("Call URL: " + completeUrl);
31620    return this.http.jsonp(completeUrl, "callback").pipe(map((data) => {
31621      let msgContent;
31622      let serialized = new TypedJSON(MsgContent);
31623      msgContent = serialized.parse(data);
31624      if (msgContent === void 0 || msgContent.getError() !== "") {
31625        return null;
31626      }
31627      let readResult;
31628      let valueJson = "";
31629      if (dataType === DataType.GRID || dataType === DataType.ROW || dataType === DataType.HISTORICAL) {
31630        const multipleParameter = msgContent.getMultipleParameter("DataOut");
31631        if (multipleParameter === void 0) {
31632          return null;
31633        }
31634        const singleParameter = multipleParameter.getSingleParameter("value");
31635        if (singleParameter === void 0) {
31636          return null;
31637        }
31638        valueJson = singleParameter.getValue();
31639      }
31640      switch (dataType) {
31641        case DataType.GRID: {
31642          let dataGrid;
31643          const dataGridSerialized = new TypedJSON(DataGrid);
31644          dataGrid = dataGridSerialized.parse(valueJson);
31645          readResult = new ReadResult(callerData, dataGrid);
31646          return readResult;
31647        }
31648        case DataType.ROW: {
31649          let dataRow;
31650          const dataRowSerialized = new TypedJSON(DataRow);
31651          dataRow = dataRowSerialized.parse(valueJson);
31652          readResult = new ReadResult(callerData, dataRow);
31653          return readResult;
31654        }
31655        case DataType.HISTORICAL: {
31656          let dataSeries;
31657          const dataSeriesSerialized = new TypedJSON(DataSeries);
31658          dataSeries = dataSeriesSerialized.parse(valueJson);
31659          readResult = new ReadResult(callerData, dataSeries);
31660          return readResult;
31661        }
31662        case DataType.META_LIST_GRIDS: {
31663          const grids = [];
31664          const multipleParameter = msgContent.getMultipleParameter("idList");
31665          if (multipleParameter === void 0) {
31666            return null;
31667          }
31668          multipleParameter.getSingleParameters("id").forEach((singleParameter) => {
31669            grids.push(singleParameter.getValue());
31670          });
31671          readResult = new ReadResult(callerData, grids);
31672          return readResult;
31673        }
31674      }
31675      readResult = new ReadResult(callerData, "");
31676      return readResult;
31677    }), catchError((error) => {
31678      return "";
31679    }));
31680  }
31681  dataType2String(dataType) {
31682    switch (dataType) {
31683      case DataType.GRID:
31684        return "Grid";
31685      case DataType.ROW:
31686        return "Row";
31687      case DataType.HISTORICAL:
31688        return "SeriesHistorical";
31689      default:
31690        return "Type Undefined";
31691    }
31692  }
31693  // IConfigurationCaller methods
31694  // TODO bisogna costruire un servizio che istanzia queste classi e rendere parametrica questi parametri
31695  get CallerName() {
31696    return "DataManager1";
31697  }
31698  get CallerProgressive() {
31699    return this.progressive;
31700  }
31701  get CallerSubType() {
31702    return "DataManager";
31703  }
31704  get CallerType() {
31705    return ComponentType.Publishers;
31706  }
31707  setCallerProgressive(progressive) {
31708    this.progressive = progressive;
31709  }
31710  initialize(initializer, configuration) {
31711    this.initializer = initializer;
31712    configuration.injectParametersToComponent(this);
31713  }
31714  getRewritableParameterMap() {
31715    const result = /* @__PURE__ */ new Map();
31716    result.set("project", this.project);
31717    result.set("language", this.language);
31718    result.set("xlsxid", this.xlsxid);
31719    return result;
31720  }
31721  getParameterForUrl(parameters) {
31722    let result = "";
31723    let first = true;
31724    parameters.forEach((value, key) => {
31725      if (first) {
31726        first = false;
31727        result += "?";
31728      } else {
31729        result += "&";
31730      }
31731      result += key + "=" + value;
31732    });
31733    return result;
31734  }
31735  onParameterInjectedFinished() {
31736    if (this.initializer === void 0) {
31737      throw new Error("Initializer not set");
31738    }
31739    if (this.baseUrl.endsWith("/getdataout")) {
31740      this.baseUrl = this.baseUrl.substring(0, this.baseUrl.length - "/getdataout".length);
31741    }
31742    const externalProject = DoraGetProject();
31743    if (externalProject !== "") {
31744      this.project = externalProject;
31745    }
31746    this.initializer.onPublisherInitialized();
31747  }
31748};
31749__decorate([
31750  DoraProperty,
31751  __metadata("design:type", String)
31752], PublisherDataManagement.prototype, "baseUrl", void 0);
31753__decorate([
31754  DoraProperty,
31755  __metadata("design:type", String)
31756], PublisherDataManagement.prototype, "project", void 0);
31757__decorate([
31758  DoraProperty,
31759  __metadata("design:type", String)
31760], PublisherDataManagement.prototype, "xlsxid", void 0);
31761__decorate([
31762  DoraProperty,
31763  __metadata("design:type", String)
31764], PublisherDataManagement.prototype, "progressive", void 0);
31765
31766// src/app/publisher/DoraServer/publisher-dora-server.ts
31767var PublisherDoraServer = class {
31768  constructor(http, progressive) {
31769    this.http = http;
31770    this.baseUrl = "";
31771    this.language = "it";
31772    this.progressive = "1";
31773    this.isinSearch = false;
31774    this.initializer = void 0;
31775    this.progressive = progressive;
31776    this.language = DoraGetLocale();
31777  }
31778  reset() {
31779    ;
31780  }
31781  // tslint:disable-next-line:ban-types max-line-length
31782  read(publisherParameters, subscribeObjInfo, dataType, callerData) {
31783    switch (dataType) {
31784      case DataType.ROW:
31785      case DataType.HISTORICAL:
31786        const completeUrl = this.baseUrl + "sections/" + subscribeObjInfo[0] + "/" + this.dataType2String(dataType) + this.getParameterForUrl(publisherParameters);
31787        console.log("Call URL: " + completeUrl);
31788        return this.readSingleContent(subscribeObjInfo[0], completeUrl, dataType, callerData);
31789      case DataType.ROWS:
31790        return this.readRows(publisherParameters, subscribeObjInfo, callerData);
31791      default:
31792        let empty;
31793        empty = "";
31794        return empty;
31795    }
31796  }
31797  // tslint:disable-next-line:ban-types
31798  readSingleContent(subscribeId, completeUrl, dataType, callerData) {
31799    return this.http.jsonp(completeUrl, "callback").pipe(map((data) => {
31800      switch (dataType) {
31801        case DataType.ROW: {
31802          let dataRow;
31803          const dataRowSerialized = new TypedJSON(DataRow);
31804          dataRow = dataRowSerialized.parse(data);
31805          return new ReadResult(callerData, dataRow);
31806        }
31807        case DataType.GRID: {
31808          let dataGrid;
31809          const dataRowSerialized = new TypedJSON(DataGrid);
31810          dataGrid = dataRowSerialized.parse(data);
31811          return new ReadResult(callerData, dataGrid);
31812        }
31813        case DataType.HISTORICAL: {
31814          let dataSeries;
31815          const dataSeriesSerialized = new TypedJSON(DataSeries);
31816          dataSeries = dataSeriesSerialized.parse(data);
31817          if (dataSeries !== void 0) {
31818            dataSeries.SubscribeId = subscribeId;
31819            return new ReadResult(callerData, dataSeries);
31820          }
31821        }
31822      }
31823      return new ReadResult(callerData, "");
31824    }), catchError((error) => {
31825      return "";
31826    }));
31827  }
31828  dataType2String(dataType) {
31829    switch (dataType) {
31830      case DataType.ROW:
31831        return "TUPLAS";
31832      case DataType.HISTORICAL:
31833        return "HISTORICAL";
31834      default:
31835        return "Type Undefined";
31836    }
31837  }
31838  /**
31839   * Read rows and build a unique grid
31840   */
31841  // @ts-ignore
31842  // tslint:disable-next-line:ban-types
31843  readRows(publisherParameters, subscribeObjInfo, callerData) {
31844    let idSectionsParameter = "";
31845    subscribeObjInfo.forEach((value) => {
31846      if (idSectionsParameter !== "") {
31847        idSectionsParameter += ",";
31848      }
31849      idSectionsParameter += value;
31850    });
31851    publisherParameters.set("idsections", idSectionsParameter);
31852    const completeUrl = this.baseUrl + "multipleSections" + this.getParameterForUrl(publisherParameters);
31853    console.log("Call URL: " + completeUrl);
31854    let readResult;
31855    readResult = this.readSingleContent("-", completeUrl, DataType.GRID, callerData);
31856    return readResult;
31857  }
31858  // IConfigurationCaller methods
31859  // TODO bisogna costruire un servizio che istanzia queste classi e rendere parametrica questi parametri
31860  get CallerName() {
31861    return "DataManager1";
31862  }
31863  get CallerProgressive() {
31864    return this.progressive;
31865  }
31866  get CallerSubType() {
31867    return "DoraServer";
31868  }
31869  get CallerType() {
31870    return ComponentType.Publishers;
31871  }
31872  setCallerProgressive(progressive) {
31873    this.progressive = progressive;
31874  }
31875  initialize(initializer, configuration) {
31876    this.initializer = initializer;
31877    configuration.injectParametersToComponent(this);
31878  }
31879  getRewritableParameterMap() {
31880    const result = /* @__PURE__ */ new Map();
31881    result.set("language", this.language);
31882    result.set("format", "json");
31883    if (this.isinSearch) {
31884      result.set("flIsin", "true");
31885    }
31886    return result;
31887  }
31888  getParameterForUrl(parameters) {
31889    let result = "";
31890    let first = true;
31891    parameters.forEach((value, key) => {
31892      if (first) {
31893        first = false;
31894        result += "?";
31895      } else {
31896        result += "&";
31897      }
31898      result += key + "=" + value;
31899    });
31900    return result;
31901  }
31902  onParameterInjectedFinished() {
31903    if (this.initializer === void 0) {
31904      throw new Error("Initializer not set");
31905    }
31906    this.initializer.onPublisherInitialized();
31907  }
31908};
31909__decorate([
31910  DoraProperty,
31911  __metadata("design:type", Object)
31912], PublisherDoraServer.prototype, "baseUrl", void 0);
31913__decorate([
31914  DoraProperty,
31915  __metadata("design:type", Object)
31916], PublisherDoraServer.prototype, "progressive", void 0);
31917__decorate([
31918  DoraProperty,
31919  __metadata("design:type", Object)
31920], PublisherDoraServer.prototype, "isinSearch", void 0);
31921
31922// src/app/DoraData/document-metadata.ts
31923var DocumentMetadata = class DocumentMetadata2 extends DataBase {
31924  get DocumentType() {
31925    return this.documentType;
31926  }
31927  set DocumentType(value) {
31928    this.documentType = value;
31929  }
31930  /**
31931   * Ritorna il content type per il web sulla base di documentType.
31932   */
31933  getMimeType() {
31934    if (!this.documentType) {
31935      return void 0;
31936    }
31937    switch (this.documentType.toUpperCase()) {
31938      case "PDF":
31939        return "application/pdf";
31940      case "XLSX":
31941        return "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";
31942      default:
31943        return void 0;
31944    }
31945  }
31946  get Url() {
31947    let result = this.URL || "";
31948    if (this.page) {
31949      if (this.getMimeType() === "application/pdf") {
31950        result += `#page=${this.page}`;
31951      }
31952    }
31953    return result;
31954  }
31955  set Url(value) {
31956    this.URL = value;
31957  }
31958  /**
31959   * Ritorna l'URL del documento privato del frammento (es. #page=12).
31960   * Usato come chiave per aggregare i documenti che puntano allo stesso file.
31961   */
31962  get UrlBase() {
31963    if (!this.URL) {
31964      return void 0;
31965    }
31966    const fragmentIndex = this.URL.indexOf("#");
31967    return fragmentIndex >= 0 ? this.URL.substring(0, fragmentIndex) : this.URL;
31968  }
31969  get Filename() {
31970    return this.filename;
31971  }
31972  set Filename(value) {
31973    this.filename = value;
31974  }
31975  get Page() {
31976    return this.page;
31977  }
31978  set Page(value) {
31979    this.page = value;
31980  }
31981  get Score() {
31982    return this.score;
31983  }
31984  set Score(value) {
31985    this.score = value;
31986  }
31987  get Timestamp() {
31988    return this.timestamp;
31989  }
31990  set Timestamp(value) {
31991    this.timestamp = value;
31992  }
31993  get Title() {
31994    if (this.title) {
31995      return this.title;
31996    }
31997    return this.documentTitle;
31998  }
31999  set Title(value) {
32000    this.title = value;
32001  }
32002};
32003__decorate([
32004  jsonMember(String),
32005  __metadata("design:type", Object)
32006], DocumentMetadata.prototype, "filename", void 0);
32007__decorate([
32008  jsonMember(Number),
32009  __metadata("design:type", Object)
32010], DocumentMetadata.prototype, "page", void 0);
32011__decorate([
32012  jsonMember(Number),
32013  __metadata("design:type", Object)
32014], DocumentMetadata.prototype, "score", void 0);
32015__decorate([
32016  jsonMember(String),
32017  __metadata("design:type", Object)
32018], DocumentMetadata.prototype, "timestamp", void 0);
32019__decorate([
32020  jsonMember(String),
32021  __metadata("design:type", Object)
32022], DocumentMetadata.prototype, "title", void 0);
32023__decorate([
32024  jsonMember(String),
32025  __metadata("design:type", Object)
32026], DocumentMetadata.prototype, "documentTitle", void 0);
32027__decorate([
32028  jsonMember(String),
32029  __metadata("design:type", Object)
32030], DocumentMetadata.prototype, "URL", void 0);
32031__decorate([
32032  jsonMember(String),
32033  __metadata("design:type", Object)
32034], DocumentMetadata.prototype, "documentType", void 0);
32035DocumentMetadata = __decorate([
32036  jsonObject
32037], DocumentMetadata);
32038
32039// src/app/DoraData/data-corporate-agent-document.ts
32040var CorporateAgentDocument = class CorporateAgentDocument2 {
32041  get Content() {
32042    return this.content;
32043  }
32044  set Content(value) {
32045    this.content = value;
32046  }
32047  get Metadata() {
32048    return this.metadata;
32049  }
32050  set Metadata(value) {
32051    this.metadata = value;
32052  }
32053};
32054__decorate([
32055  jsonMember(String),
32056  __metadata("design:type", Object)
32057], CorporateAgentDocument.prototype, "content", void 0);
32058__decorate([
32059  jsonMember(DocumentMetadata),
32060  __metadata("design:type", Object)
32061], CorporateAgentDocument.prototype, "metadata", void 0);
32062CorporateAgentDocument = __decorate([
32063  jsonObject
32064], CorporateAgentDocument);
32065
32066// src/app/DoraData/table-data-content.ts
32067var GRID_CHART_TYPES = [
32068  CHART_TYPE[CHART_TYPE.LINEAR],
32069  CHART_TYPE[CHART_TYPE.SPLINE],
32070  CHART_TYPE[CHART_TYPE.COLUMN],
32071  CHART_TYPE[CHART_TYPE.COLUMNSTACK],
32072  CHART_TYPE[CHART_TYPE.BAR],
32073  CHART_TYPE[CHART_TYPE.PIE]
32074];
32075var DEFAULT_GRID_CHART_TYPE = CHART_TYPE[CHART_TYPE.COLUMN];
32076var TableDataContent = class TableDataContent2 {
32077  constructor() {
32078    this.showTable = false;
32079  }
32080  get ShowTable() {
32081    return this.showTable;
32082  }
32083  set ShowTable(value) {
32084    this.showTable = value;
32085  }
32086  get DataId() {
32087    return this.dataId;
32088  }
32089  set DataId(value) {
32090    this.dataId = value;
32091  }
32092  get SelectedColumns() {
32093    return this.selected_columns;
32094  }
32095  set SelectedColumns(value) {
32096    this.selected_columns = value;
32097  }
32098  get SelectedRows() {
32099    return this.selected_rows;
32100  }
32101  set SelectedRows(value) {
32102    this.selected_rows = value;
32103  }
32104  get XlsxId() {
32105    return this.xlsxid;
32106  }
32107  set XlsxId(value) {
32108    this.xlsxid = value;
32109  }
32110  get Language() {
32111    return this.language;
32112  }
32113  set Language(value) {
32114    this.language = value;
32115  }
32116  get DefaultChartType() {
32117    return this.defaultChartType;
32118  }
32119  set DefaultChartType(value) {
32120    this.defaultChartType = value;
32121  }
32122  /**
32123   * Restituisce il tipo di grafico normalizzato e validato contro la whitelist dei tipi
32124   * supportati dai dati di griglia. Se il valore è assente, vuoto o non ammesso ritorna COLUMN.
32125   * La validazione è necessaria anche perché il valore viene interpolato in un tag HTML.
32126   */
32127  resolvedChartType() {
32128    const normalized = (this.defaultChartType || "").trim().toUpperCase();
32129    if (normalized === "") {
32130      return DEFAULT_GRID_CHART_TYPE;
32131    }
32132    if (!GRID_CHART_TYPES.includes(normalized)) {
32133      console.warn("CHARTTYPE " + this.defaultChartType + " not allowed, fallback to " + DEFAULT_GRID_CHART_TYPE);
32134      return DEFAULT_GRID_CHART_TYPE;
32135    }
32136    return normalized;
32137  }
32138};
32139__decorate([
32140  jsonMember(String),
32141  __metadata("design:type", Object)
32142], TableDataContent.prototype, "dataId", void 0);
32143__decorate([
32144  jsonMember(String),
32145  __metadata("design:type", Object)
32146], TableDataContent.prototype, "language", void 0);
32147__decorate([
32148  jsonArrayMember(String),
32149  __metadata("design:type", Object)
32150], TableDataContent.prototype, "selected_columns", void 0);
32151__decorate([
32152  jsonArrayMember(String),
32153  __metadata("design:type", Object)
32154], TableDataContent.prototype, "selected_rows", void 0);
32155__decorate([
32156  jsonMember(String),
32157  __metadata("design:type", Object)
32158], TableDataContent.prototype, "xlsxid", void 0);
32159__decorate([
32160  jsonMember(Boolean),
32161  __metadata("design:type", Object)
32162], TableDataContent.prototype, "showTable", void 0);
32163__decorate([
32164  jsonMember(String),
32165  __metadata("design:type", Object)
32166], TableDataContent.prototype, "defaultChartType", void 0);
32167TableDataContent = __decorate([
32168  jsonObject
32169], TableDataContent);
32170
32171// src/app/DoraData/carousel-element.ts
32172var CarouselElement = class CarouselElement2 {
32173  constructor() {
32174    this.htmlContent = "";
32175    this.title = "";
32176    this.cssClass = "";
32177  }
32178  get HtmlContent() {
32179    return this.htmlContent;
32180  }
32181  get Title() {
32182    return this.title;
32183  }
32184  get CssClass() {
32185    return this.cssClass;
32186  }
32187  toParameter() {
32188    return this.htmlContent + "\xA7" + this.title + "\xA7" + this.cssClass;
32189  }
32190};
32191__decorate([
32192  jsonMember(String),
32193  __metadata("design:type", Object)
32194], CarouselElement.prototype, "htmlContent", void 0);
32195__decorate([
32196  jsonMember(String),
32197  __metadata("design:type", Object)
32198], CarouselElement.prototype, "title", void 0);
32199__decorate([
32200  jsonMember(String),
32201  __metadata("design:type", Object)
32202], CarouselElement.prototype, "cssClass", void 0);
32203CarouselElement = __decorate([
32204  jsonObject
32205], CarouselElement);
32206
32207// src/app/DoraData/carousel-data-content.ts
32208var CarouselDataContent = class CarouselDataContent2 {
32209  constructor() {
32210    this.autoplay = false;
32211    this.autoplayDelay = 3e3;
32212    this.loop = true;
32213    this.navigation = true;
32214    this.pagination = true;
32215    this.slidesPerView = 1;
32216    this.spaceBetween = 30;
32217    this.carouselHeight = 400;
32218    this.items = [];
32219  }
32220  items2Parameters() {
32221    let result = "";
32222    if (this.items && this.items.length > 0) {
32223      this.items.forEach((item, index) => {
32224        if (index > 0) {
32225          result += "\xA7";
32226        }
32227        result += item.toParameter();
32228      });
32229      return result;
32230    }
32231    return void 0;
32232  }
32233};
32234__decorate([
32235  jsonMember(Boolean),
32236  __metadata("design:type", Object)
32237], CarouselDataContent.prototype, "autoplay", void 0);
32238__decorate([
32239  jsonMember(Number),
32240  __metadata("design:type", Object)
32241], CarouselDataContent.prototype, "autoplayDelay", void 0);
32242__decorate([
32243  jsonMember(Boolean),
32244  __metadata("design:type", Object)
32245], CarouselDataContent.prototype, "loop", void 0);
32246__decorate([
32247  jsonMember(Boolean),
32248  __metadata("design:type", Object)
32249], CarouselDataContent.prototype, "navigation", void 0);
32250__decorate([
32251  jsonMember(Boolean),
32252  __metadata("design:type", Object)
32253], CarouselDataContent.prototype, "pagination", void 0);
32254__decorate([
32255  jsonMember(Number),
32256  __metadata("design:type", Object)
32257], CarouselDataContent.prototype, "slidesPerView", void 0);
32258__decorate([
32259  jsonMember(Number),
32260  __metadata("design:type", Object)
32261], CarouselDataContent.prototype, "spaceBetween", void 0);
32262__decorate([
32263  jsonMember(Number),
32264  __metadata("design:type", Object)
32265], CarouselDataContent.prototype, "carouselHeight", void 0);
32266__decorate([
32267  jsonArrayMember(CarouselElement),
32268  __metadata("design:type", Object)
32269], CarouselDataContent.prototype, "items", void 0);
32270CarouselDataContent = __decorate([
32271  jsonObject
32272], CarouselDataContent);
32273
32274// src/app/DoraData/data-corporate-agent-data.ts
32275var CorporateAgentDataType;
32276(function(CorporateAgentDataType2) {
32277  CorporateAgentDataType2["TABLE_DATA"] = "TABLE_DATA";
32278  CorporateAgentDataType2["CAROUSEL_DATA"] = "CAROUSEL_DATA";
32279})(CorporateAgentDataType || (CorporateAgentDataType = {}));
32280var CorporateAgentData = class CorporateAgentData2 {
32281  get Type() {
32282    return this.type;
32283  }
32284  set Type(value) {
32285    this.type = value;
32286  }
32287  get TableDataContent() {
32288    return this.tableDataContent;
32289  }
32290  set TableDataContent(value) {
32291    this.tableDataContent = value;
32292  }
32293  get CarouselDataContent() {
32294    return this.carouselDataContent;
32295  }
32296  set CarouselDataContent(value) {
32297    this.carouselDataContent = value;
32298  }
32299  // Metodi di utilità per verificare il tipo
32300  isTableData() {
32301    return this.type === CorporateAgentDataType.TABLE_DATA;
32302  }
32303  isCarouselData() {
32304    return this.type === CorporateAgentDataType.CAROUSEL_DATA;
32305  }
32306  // Getter generico che restituisce il contenuto appropriato basato sul tipo
32307  get Content() {
32308    switch (this.type) {
32309      case CorporateAgentDataType.TABLE_DATA:
32310        return this.tableDataContent;
32311      case CorporateAgentDataType.CAROUSEL_DATA:
32312        return this.carouselDataContent;
32313      default:
32314        return void 0;
32315    }
32316  }
32317};
32318__decorate([
32319  jsonMember(String),
32320  __metadata("design:type", Object)
32321], CorporateAgentData.prototype, "type", void 0);
32322__decorate([
32323  jsonMember(TableDataContent),
32324  __metadata("design:type", Object)
32325], CorporateAgentData.prototype, "tableDataContent", void 0);
32326__decorate([
32327  jsonMember(CarouselDataContent),
32328  __metadata("design:type", Object)
32329], CorporateAgentData.prototype, "carouselDataContent", void 0);
32330CorporateAgentData = __decorate([
32331  jsonObject
32332], CorporateAgentData);
32333
32334// src/app/DoraData/data-corporate-agent.ts
32335var DataCorporateAgent = class DataCorporateAgent2 {
32336  constructor() {
32337    this.answerTimestamp = null;
32338    this.data = null;
32339    this.documents = null;
32340    this.related_documents = null;
32341    this.questionTimestamp = null;
32342    this.id = 0;
32343  }
32344  get TechnicalAnswer() {
32345    return this.technical_answer;
32346  }
32347  set TechnicalAnswer(value) {
32348    this.technical_answer = value;
32349  }
32350  get AnswerTimestamp() {
32351    return this.answerTimestamp;
32352  }
32353  set AnswerTimestamp(value) {
32354    this.answerTimestamp = value;
32355  }
32356  get QuestionTimestamp() {
32357    return this.questionTimestamp;
32358  }
32359  set QuestionTimestamp(value) {
32360    this.questionTimestamp = value;
32361  }
32362  get Answer() {
32363    return this.answer;
32364  }
32365  set Answer(value) {
32366    this.answer = value;
32367  }
32368  get ConversationId() {
32369    return this.conversation_id;
32370  }
32371  set ConversationId(value) {
32372    this.conversation_id = value;
32373  }
32374  get Data() {
32375    return this.data;
32376  }
32377  set Data(value) {
32378    this.data = value;
32379  }
32380  get Documents() {
32381    return this.documents;
32382  }
32383  set Documents(value) {
32384    this.documents = value;
32385  }
32386  get Related_documents() {
32387    return this.related_documents;
32388  }
32389  set Related_documents(value) {
32390    this.related_documents = value;
32391  }
32392  get Intent() {
32393    return this.intent;
32394  }
32395  set Intent(value) {
32396    this.intent = value;
32397  }
32398  get Question() {
32399    return this.question;
32400  }
32401  set Question(value) {
32402    this.question = value;
32403  }
32404  // Metodo di utilità per verificare se la risposta contiene documenti
32405  hasDocuments() {
32406    return this.documents !== null && this.documents.length > 0;
32407  }
32408  // Metodo di utilità per verificare se la risposta contiene documenti relativi
32409  hasRelatedDocuments() {
32410    return this.related_documents !== null && this.related_documents.length > 0;
32411  }
32412  // Metodo di utilità per ottenere l'ID della conversazione
32413  get Id() {
32414    if (this.answerTimestamp) {
32415      this.id = this.answerTimestamp.getTime();
32416    }
32417    this.id = this.questionTimestamp?.getTime() || 0;
32418    return this.id;
32419  }
32420};
32421__decorate([
32422  jsonMember(String),
32423  __metadata("design:type", Object)
32424], DataCorporateAgent.prototype, "answer", void 0);
32425__decorate([
32426  jsonMember(String),
32427  __metadata("design:type", Object)
32428], DataCorporateAgent.prototype, "technical_answer", void 0);
32429__decorate([
32430  jsonMember(String),
32431  __metadata("design:type", Object)
32432], DataCorporateAgent.prototype, "conversation_id", void 0);
32433__decorate([
32434  jsonMember(CorporateAgentData),
32435  __metadata("design:type", Object)
32436], DataCorporateAgent.prototype, "data", void 0);
32437__decorate([
32438  jsonArrayMember(CorporateAgentDocument),
32439  __metadata("design:type", Object)
32440], DataCorporateAgent.prototype, "documents", void 0);
32441__decorate([
32442  jsonArrayMember(CorporateAgentDocument),
32443  __metadata("design:type", Object)
32444], DataCorporateAgent.prototype, "related_documents", void 0);
32445__decorate([
32446  jsonMember(String),
32447  __metadata("design:type", Object)
32448], DataCorporateAgent.prototype, "intent", void 0);
32449__decorate([
32450  jsonMember(String),
32451  __metadata("design:type", Object)
32452], DataCorporateAgent.prototype, "question", void 0);
32453DataCorporateAgent = __decorate([
32454  jsonObject
32455], DataCorporateAgent);
32456
32457// src/app/DoraData/data-corporate-agent-wizard-question.ts
32458var DataCorporateAgentWizardQuestion = class DataCorporateAgentWizardQuestion2 {
32459  get Title() {
32460    return this.title;
32461  }
32462  set Title(value) {
32463    this.title = value;
32464  }
32465};
32466__decorate([
32467  jsonMember(String),
32468  __metadata("design:type", Object)
32469], DataCorporateAgentWizardQuestion.prototype, "title", void 0);
32470DataCorporateAgentWizardQuestion = __decorate([
32471  jsonObject
32472], DataCorporateAgentWizardQuestion);
32473
32474// src/app/DoraData/data-corporate-agent-wizard.ts
32475var DataCorporateAgentWizard = class DataCorporateAgentWizard2 {
32476  constructor() {
32477    this.questions = null;
32478  }
32479  get Description() {
32480    return this.description;
32481  }
32482  set Description(value) {
32483    this.description = value;
32484  }
32485  get Questions() {
32486    return this.questions;
32487  }
32488  set Questions(value) {
32489    this.questions = value;
32490  }
32491  get CssClassName() {
32492    return this.cssclassname;
32493  }
32494  set CssClassName(value) {
32495    this.cssclassname = value;
32496  }
32497};
32498__decorate([
32499  jsonMember(String),
32500  __metadata("design:type", Object)
32501], DataCorporateAgentWizard.prototype, "description", void 0);
32502__decorate([
32503  jsonArrayMember(DataCorporateAgentWizardQuestion),
32504  __metadata("design:type", Object)
32505], DataCorporateAgentWizard.prototype, "questions", void 0);
32506__decorate([
32507  jsonMember(String),
32508  __metadata("design:type", Object)
32509], DataCorporateAgentWizard.prototype, "cssclassname", void 0);
32510DataCorporateAgentWizard = __decorate([
32511  jsonObject
32512], DataCorporateAgentWizard);
32513
vendor: 212,009 bytes, lines 32514-38963
32514// node_modules/@angular/forms/fesm2022/forms.mjs
32515var BaseControlValueAccessor = class _BaseControlValueAccessor {
32516  _renderer;
32517  _elementRef;
32518  /**
32519   * The registered callback function called when a change or input event occurs on the input
32520   * element.
32521   * @nodoc
32522   */
32523  onChange = (_2) => {
32524  };
32525  /**
32526   * The registered callback function called when a blur event occurs on the input element.
32527   * @nodoc
32528   */
32529  onTouched = () => {
32530  };
32531  constructor(_renderer, _elementRef) {
32532    this._renderer = _renderer;
32533    this._elementRef = _elementRef;
32534  }
32535  /**
32536   * Helper method that sets a property on a target element using the current Renderer
32537   * implementation.
32538   * @nodoc
32539   */
32540  setProperty(key, value) {
32541    this._renderer.setProperty(this._elementRef.nativeElement, key, value);
32542  }
32543  /**
32544   * Registers a function called when the control is touched.
32545   * @nodoc
32546   */
32547  registerOnTouched(fn) {
32548    this.onTouched = fn;
32549  }
32550  /**
32551   * Registers a function called when the control value changes.
32552   * @nodoc
32553   */
32554  registerOnChange(fn) {
32555    this.onChange = fn;
32556  }
32557  /**
32558   * Sets the "disabled" property on the range input element.
32559   * @nodoc
32560   */
32561  setDisabledState(isDisabled) {
32562    this.setProperty("disabled", isDisabled);
32563  }
32564  static \u0275fac = function BaseControlValueAccessor_Factory(__ngFactoryType__) {
32565    return new (__ngFactoryType__ || _BaseControlValueAccessor)(\u0275\u0275directiveInject(Renderer2), \u0275\u0275directiveInject(ElementRef));
32566  };
32567  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
32568    type: _BaseControlValueAccessor
32569  });
32570};
32571(() => {
32572  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(BaseControlValueAccessor, [{
32573    type: Directive
32574  }], () => [{
32575    type: Renderer2
32576  }, {
32577    type: ElementRef
32578  }], null);
32579})();
32580var BuiltInControlValueAccessor = class _BuiltInControlValueAccessor extends BaseControlValueAccessor {
32581  static \u0275fac = /* @__PURE__ */ (() => {
32582    let \u0275BuiltInControlValueAccessor_BaseFactory;
32583    return function BuiltInControlValueAccessor_Factory(__ngFactoryType__) {
32584      return (\u0275BuiltInControlValueAccessor_BaseFactory || (\u0275BuiltInControlValueAccessor_BaseFactory = \u0275\u0275getInheritedFactory(_BuiltInControlValueAccessor)))(__ngFactoryType__ || _BuiltInControlValueAccessor);
32585    };
32586  })();
32587  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
32588    type: _BuiltInControlValueAccessor,
32589    features: [\u0275\u0275InheritDefinitionFeature]
32590  });
32591};
32592(() => {
32593  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(BuiltInControlValueAccessor, [{
32594    type: Directive
32595  }], null, null);
32596})();
32597var NG_VALUE_ACCESSOR = new InjectionToken(ngDevMode ? "NgValueAccessor" : "");
32598var CHECKBOX_VALUE_ACCESSOR = {
32599  provide: NG_VALUE_ACCESSOR,
32600  useExisting: forwardRef(() => CheckboxControlValueAccessor),
32601  multi: true
32602};
32603var CheckboxControlValueAccessor = class _CheckboxControlValueAccessor extends BuiltInControlValueAccessor {
32604  /**
32605   * Sets the "checked" property on the input element.
32606   * @nodoc
32607   */
32608  writeValue(value) {
32609    this.setProperty("checked", value);
32610  }
32611  static \u0275fac = /* @__PURE__ */ (() => {
32612    let \u0275CheckboxControlValueAccessor_BaseFactory;
32613    return function CheckboxControlValueAccessor_Factory(__ngFactoryType__) {
32614      return (\u0275CheckboxControlValueAccessor_BaseFactory || (\u0275CheckboxControlValueAccessor_BaseFactory = \u0275\u0275getInheritedFactory(_CheckboxControlValueAccessor)))(__ngFactoryType__ || _CheckboxControlValueAccessor);
32615    };
32616  })();
32617  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
32618    type: _CheckboxControlValueAccessor,
32619    selectors: [["input", "type", "checkbox", "formControlName", ""], ["input", "type", "checkbox", "formControl", ""], ["input", "type", "checkbox", "ngModel", ""]],
32620    hostBindings: function CheckboxControlValueAccessor_HostBindings(rf, ctx) {
32621      if (rf & 1) {
32622        \u0275\u0275listener("change", function CheckboxControlValueAccessor_change_HostBindingHandler($event) {
32623          return ctx.onChange($event.target.checked);
32624        })("blur", function CheckboxControlValueAccessor_blur_HostBindingHandler() {
32625          return ctx.onTouched();
32626        });
32627      }
32628    },
32629    standalone: false,
32630    features: [\u0275\u0275ProvidersFeature([CHECKBOX_VALUE_ACCESSOR]), \u0275\u0275InheritDefinitionFeature]
32631  });
32632};
32633(() => {
32634  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(CheckboxControlValueAccessor, [{
32635    type: Directive,
32636    args: [{
32637      selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]",
32638      host: {
32639        "(change)": "onChange($event.target.checked)",
32640        "(blur)": "onTouched()"
32641      },
32642      providers: [CHECKBOX_VALUE_ACCESSOR],
32643      standalone: false
32644    }]
32645  }], null, null);
32646})();
32647var DEFAULT_VALUE_ACCESSOR = {
32648  provide: NG_VALUE_ACCESSOR,
32649  useExisting: forwardRef(() => DefaultValueAccessor),
32650  multi: true
32651};
32652function _isAndroid() {
32653  const userAgent = getDOM() ? getDOM().getUserAgent() : "";
32654  return /android (\d+)/.test(userAgent.toLowerCase());
32655}
32656var COMPOSITION_BUFFER_MODE = new InjectionToken(ngDevMode ? "CompositionEventMode" : "");
32657var DefaultValueAccessor = class _DefaultValueAccessor extends BaseControlValueAccessor {
32658  _compositionMode;
32659  /** Whether the user is creating a composition string (IME events). */
32660  _composing = false;
32661  constructor(renderer, elementRef, _compositionMode) {
32662    super(renderer, elementRef);
32663    this._compositionMode = _compositionMode;
32664    if (this._compositionMode == null) {
32665      this._compositionMode = !_isAndroid();
32666    }
32667  }
32668  /**
32669   * Sets the "value" property on the input element.
32670   * @nodoc
32671   */
32672  writeValue(value) {
32673    const normalizedValue = value == null ? "" : value;
32674    this.setProperty("value", normalizedValue);
32675  }
32676  /** @internal */
32677  _handleInput(value) {
32678    if (!this._compositionMode || this._compositionMode && !this._composing) {
32679      this.onChange(value);
32680    }
32681  }
32682  /** @internal */
32683  _compositionStart() {
32684    this._composing = true;
32685  }
32686  /** @internal */
32687  _compositionEnd(value) {
32688    this._composing = false;
32689    this._compositionMode && this.onChange(value);
32690  }
32691  static \u0275fac = function DefaultValueAccessor_Factory(__ngFactoryType__) {
32692    return new (__ngFactoryType__ || _DefaultValueAccessor)(\u0275\u0275directiveInject(Renderer2), \u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(COMPOSITION_BUFFER_MODE, 8));
32693  };
32694  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
32695    type: _DefaultValueAccessor,
32696    selectors: [["input", "formControlName", "", 3, "type", "checkbox"], ["textarea", "formControlName", ""], ["input", "formControl", "", 3, "type", "checkbox"], ["textarea", "formControl", ""], ["input", "ngModel", "", 3, "type", "checkbox"], ["textarea", "ngModel", ""], ["", "ngDefaultControl", ""]],
32697    hostBindings: function DefaultValueAccessor_HostBindings(rf, ctx) {
32698      if (rf & 1) {
32699        \u0275\u0275listener("input", function DefaultValueAccessor_input_HostBindingHandler($event) {
32700          return ctx._handleInput($event.target.value);
32701        })("blur", function DefaultValueAccessor_blur_HostBindingHandler() {
32702          return ctx.onTouched();
32703        })("compositionstart", function DefaultValueAccessor_compositionstart_HostBindingHandler() {
32704          return ctx._compositionStart();
32705        })("compositionend", function DefaultValueAccessor_compositionend_HostBindingHandler($event) {
32706          return ctx._compositionEnd($event.target.value);
32707        });
32708      }
32709    },
32710    standalone: false,
32711    features: [\u0275\u0275ProvidersFeature([DEFAULT_VALUE_ACCESSOR]), \u0275\u0275InheritDefinitionFeature]
32712  });
32713};
32714(() => {
32715  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(DefaultValueAccessor, [{
32716    type: Directive,
32717    args: [{
32718      selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]",
32719      // TODO: vsavkin replace the above selector with the one below it once
32720      // https://github.com/angular/angular/issues/3011 is implemented
32721      // selector: '[ngModel],[formControl],[formControlName]',
32722      host: {
32723        "(input)": "$any(this)._handleInput($event.target.value)",
32724        "(blur)": "onTouched()",
32725        "(compositionstart)": "$any(this)._compositionStart()",
32726        "(compositionend)": "$any(this)._compositionEnd($event.target.value)"
32727      },
32728      providers: [DEFAULT_VALUE_ACCESSOR],
32729      standalone: false
32730    }]
32731  }], () => [{
32732    type: Renderer2
32733  }, {
32734    type: ElementRef
32735  }, {
32736    type: void 0,
32737    decorators: [{
32738      type: Optional
32739    }, {
32740      type: Inject,
32741      args: [COMPOSITION_BUFFER_MODE]
32742    }]
32743  }], null);
32744})();
32745function isEmptyInputValue(value) {
32746  return value == null || (typeof value === "string" || Array.isArray(value)) && value.length === 0;
32747}
32748function hasValidLength(value) {
32749  return value != null && typeof value.length === "number";
32750}
32751var NG_VALIDATORS = new InjectionToken(ngDevMode ? "NgValidators" : "");
32752var NG_ASYNC_VALIDATORS = new InjectionToken(ngDevMode ? "NgAsyncValidators" : "");
32753var EMAIL_REGEXP = /^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;
32754function minValidator(min) {
32755  return (control) => {
32756    if (isEmptyInputValue(control.value) || isEmptyInputValue(min)) {
32757      return null;
32758    }
32759    const value = parseFloat(control.value);
32760    return !isNaN(value) && value < min ? {
32761      "min": {
32762        "min": min,
32763        "actual": control.value
32764      }
32765    } : null;
32766  };
32767}
32768function maxValidator(max) {
32769  return (control) => {
32770    if (isEmptyInputValue(control.value) || isEmptyInputValue(max)) {
32771      return null;
32772    }
32773    const value = parseFloat(control.value);
32774    return !isNaN(value) && value > max ? {
32775      "max": {
32776        "max": max,
32777        "actual": control.value
32778      }
32779    } : null;
32780  };
32781}
32782function requiredValidator(control) {
32783  return isEmptyInputValue(control.value) ? {
32784    "required": true
32785  } : null;
32786}
32787function requiredTrueValidator(control) {
32788  return control.value === true ? null : {
32789    "required": true
32790  };
32791}
32792function emailValidator(control) {
32793  if (isEmptyInputValue(control.value)) {
32794    return null;
32795  }
32796  return EMAIL_REGEXP.test(control.value) ? null : {
32797    "email": true
32798  };
32799}
32800function minLengthValidator(minLength) {
32801  return (control) => {
32802    if (isEmptyInputValue(control.value) || !hasValidLength(control.value)) {
32803      return null;
32804    }
32805    return control.value.length < minLength ? {
32806      "minlength": {
32807        "requiredLength": minLength,
32808        "actualLength": control.value.length
32809      }
32810    } : null;
32811  };
32812}
32813function maxLengthValidator(maxLength) {
32814  return (control) => {
32815    return hasValidLength(control.value) && control.value.length > maxLength ? {
32816      "maxlength": {
32817        "requiredLength": maxLength,
32818        "actualLength": control.value.length
32819      }
32820    } : null;
32821  };
32822}
32823function patternValidator(pattern) {
32824  if (!pattern) return nullValidator;
32825  let regex;
32826  let regexStr;
32827  if (typeof pattern === "string") {
32828    regexStr = "";
32829    if (pattern.charAt(0) !== "^") regexStr += "^";
32830    regexStr += pattern;
32831    if (pattern.charAt(pattern.length - 1) !== "$") regexStr += "$";
32832    regex = new RegExp(regexStr);
32833  } else {
32834    regexStr = pattern.toString();
32835    regex = pattern;
32836  }
32837  return (control) => {
32838    if (isEmptyInputValue(control.value)) {
32839      return null;
32840    }
32841    const value = control.value;
32842    return regex.test(value) ? null : {
32843      "pattern": {
32844        "requiredPattern": regexStr,
32845        "actualValue": value
32846      }
32847    };
32848  };
32849}
32850function nullValidator(control) {
32851  return null;
32852}
32853function isPresent(o) {
32854  return o != null;
32855}
32856function toObservable(value) {
32857  const obs = isPromise(value) ? from(value) : value;
32858  if ((typeof ngDevMode === "undefined" || ngDevMode) && !isSubscribable(obs)) {
32859    let errorMessage = `Expected async validator to return Promise or Observable.`;
32860    if (typeof value === "object") {
32861      errorMessage += " Are you using a synchronous validator where an async validator is expected?";
32862    }
32863    throw new RuntimeError(-1101, errorMessage);
32864  }
32865  return obs;
32866}
32867function mergeErrors(arrayOfErrors) {
32868  let res = {};
32869  arrayOfErrors.forEach((errors) => {
32870    res = errors != null ? __spreadValues(__spreadValues({}, res), errors) : res;
32871  });
32872  return Object.keys(res).length === 0 ? null : res;
32873}
32874function executeValidators(control, validators) {
32875  return validators.map((validator) => validator(control));
32876}
32877function isValidatorFn(validator) {
32878  return !validator.validate;
32879}
32880function normalizeValidators(validators) {
32881  return validators.map((validator) => {
32882    return isValidatorFn(validator) ? validator : (c) => validator.validate(c);
32883  });
32884}
32885function compose(validators) {
32886  if (!validators) return null;
32887  const presentValidators = validators.filter(isPresent);
32888  if (presentValidators.length == 0) return null;
32889  return function(control) {
32890    return mergeErrors(executeValidators(control, presentValidators));
32891  };
32892}
32893function composeValidators(validators) {
32894  return validators != null ? compose(normalizeValidators(validators)) : null;
32895}
32896function composeAsync(validators) {
32897  if (!validators) return null;
32898  const presentValidators = validators.filter(isPresent);
32899  if (presentValidators.length == 0) return null;
32900  return function(control) {
32901    const observables = executeValidators(control, presentValidators).map(toObservable);
32902    return forkJoin(observables).pipe(map(mergeErrors));
32903  };
32904}
32905function composeAsyncValidators(validators) {
32906  return validators != null ? composeAsync(normalizeValidators(validators)) : null;
32907}
32908function mergeValidators(controlValidators, dirValidator) {
32909  if (controlValidators === null) return [dirValidator];
32910  return Array.isArray(controlValidators) ? [...controlValidators, dirValidator] : [controlValidators, dirValidator];
32911}
32912function getControlValidators(control) {
32913  return control._rawValidators;
32914}
32915function getControlAsyncValidators(control) {
32916  return control._rawAsyncValidators;
32917}
32918function makeValidatorsArray(validators) {
32919  if (!validators) return [];
32920  return Array.isArray(validators) ? validators : [validators];
32921}
32922function hasValidator(validators, validator) {
32923  return Array.isArray(validators) ? validators.includes(validator) : validators === validator;
32924}
32925function addValidators(validators, currentValidators) {
32926  const current = makeValidatorsArray(currentValidators);
32927  const validatorsToAdd = makeValidatorsArray(validators);
32928  validatorsToAdd.forEach((v) => {
32929    if (!hasValidator(current, v)) {
32930      current.push(v);
32931    }
32932  });
32933  return current;
32934}
32935function removeValidators(validators, currentValidators) {
32936  return makeValidatorsArray(currentValidators).filter((v) => !hasValidator(validators, v));
32937}
32938var AbstractControlDirective = class {
32939  /**
32940   * @description
32941   * Reports the value of the control if it is present, otherwise null.
32942   */
32943  get value() {
32944    return this.control ? this.control.value : null;
32945  }
32946  /**
32947   * @description
32948   * Reports whether the control is valid. A control is considered valid if no
32949   * validation errors exist with the current value.
32950   * If the control is not present, null is returned.
32951   */
32952  get valid() {
32953    return this.control ? this.control.valid : null;
32954  }
32955  /**
32956   * @description
32957   * Reports whether the control is invalid, meaning that an error exists in the input value.
32958   * If the control is not present, null is returned.
32959   */
32960  get invalid() {
32961    return this.control ? this.control.invalid : null;
32962  }
32963  /**
32964   * @description
32965   * Reports whether a control is pending, meaning that async validation is occurring and
32966   * errors are not yet available for the input value. If the control is not present, null is
32967   * returned.
32968   */
32969  get pending() {
32970    return this.control ? this.control.pending : null;
32971  }
32972  /**
32973   * @description
32974   * Reports whether the control is disabled, meaning that the control is disabled
32975   * in the UI and is exempt from validation checks and excluded from aggregate
32976   * values of ancestor controls. If the control is not present, null is returned.
32977   */
32978  get disabled() {
32979    return this.control ? this.control.disabled : null;
32980  }
32981  /**
32982   * @description
32983   * Reports whether the control is enabled, meaning that the control is included in ancestor
32984   * calculations of validity or value. If the control is not present, null is returned.
32985   */
32986  get enabled() {
32987    return this.control ? this.control.enabled : null;
32988  }
32989  /**
32990   * @description
32991   * Reports the control's validation errors. If the control is not present, null is returned.
32992   */
32993  get errors() {
32994    return this.control ? this.control.errors : null;
32995  }
32996  /**
32997   * @description
32998   * Reports whether the control is pristine, meaning that the user has not yet changed
32999   * the value in the UI. If the control is not present, null is returned.
33000   */
33001  get pristine() {
33002    return this.control ? this.control.pristine : null;
33003  }
33004  /**
33005   * @description
33006   * Reports whether the control is dirty, meaning that the user has changed
33007   * the value in the UI. If the control is not present, null is returned.
33008   */
33009  get dirty() {
33010    return this.control ? this.control.dirty : null;
33011  }
33012  /**
33013   * @description
33014   * Reports whether the control is touched, meaning that the user has triggered
33015   * a `blur` event on it. If the control is not present, null is returned.
33016   */
33017  get touched() {
33018    return this.control ? this.control.touched : null;
33019  }
33020  /**
33021   * @description
33022   * Reports the validation status of the control. Possible values include:
33023   * 'VALID', 'INVALID', 'DISABLED', and 'PENDING'.
33024   * If the control is not present, null is returned.
33025   */
33026  get status() {
33027    return this.control ? this.control.status : null;
33028  }
33029  /**
33030   * @description
33031   * Reports whether the control is untouched, meaning that the user has not yet triggered
33032   * a `blur` event on it. If the control is not present, null is returned.
33033   */
33034  get untouched() {
33035    return this.control ? this.control.untouched : null;
33036  }
33037  /**
33038   * @description
33039   * Returns a multicasting observable that emits a validation status whenever it is
33040   * calculated for the control. If the control is not present, null is returned.
33041   */
33042  get statusChanges() {
33043    return this.control ? this.control.statusChanges : null;
33044  }
33045  /**
33046   * @description
33047   * Returns a multicasting observable of value changes for the control that emits every time the
33048   * value of the control changes in the UI or programmatically.
33049   * If the control is not present, null is returned.
33050   */
33051  get valueChanges() {
33052    return this.control ? this.control.valueChanges : null;
33053  }
33054  /**
33055   * @description
33056   * Returns an array that represents the path from the top-level form to this control.
33057   * Each index is the string name of the control on that level.
33058   */
33059  get path() {
33060    return null;
33061  }
33062  /**
33063   * Contains the result of merging synchronous validators into a single validator function
33064   * (combined using `Validators.compose`).
33065   */
33066  _composedValidatorFn;
33067  /**
33068   * Contains the result of merging asynchronous validators into a single validator function
33069   * (combined using `Validators.composeAsync`).
33070   */
33071  _composedAsyncValidatorFn;
33072  /**
33073   * Set of synchronous validators as they were provided while calling `setValidators` function.
33074   * @internal
33075   */
33076  _rawValidators = [];
33077  /**
33078   * Set of asynchronous validators as they were provided while calling `setAsyncValidators`
33079   * function.
33080   * @internal
33081   */
33082  _rawAsyncValidators = [];
33083  /**
33084   * Sets synchronous validators for this directive.
33085   * @internal
33086   */
33087  _setValidators(validators) {
33088    this._rawValidators = validators || [];
33089    this._composedValidatorFn = composeValidators(this._rawValidators);
33090  }
33091  /**
33092   * Sets asynchronous validators for this directive.
33093   * @internal
33094   */
33095  _setAsyncValidators(validators) {
33096    this._rawAsyncValidators = validators || [];
33097    this._composedAsyncValidatorFn = composeAsyncValidators(this._rawAsyncValidators);
33098  }
33099  /**
33100   * @description
33101   * Synchronous validator function composed of all the synchronous validators registered with this
33102   * directive.
33103   */
33104  get validator() {
33105    return this._composedValidatorFn || null;
33106  }
33107  /**
33108   * @description
33109   * Asynchronous validator function composed of all the asynchronous validators registered with
33110   * this directive.
33111   */
33112  get asyncValidator() {
33113    return this._composedAsyncValidatorFn || null;
33114  }
33115  /*
33116   * The set of callbacks to be invoked when directive instance is being destroyed.
33117   */
33118  _onDestroyCallbacks = [];
33119  /**
33120   * Internal function to register callbacks that should be invoked
33121   * when directive instance is being destroyed.
33122   * @internal
33123   */
33124  _registerOnDestroy(fn) {
33125    this._onDestroyCallbacks.push(fn);
33126  }
33127  /**
33128   * Internal function to invoke all registered "on destroy" callbacks.
33129   * Note: calling this function also clears the list of callbacks.
33130   * @internal
33131   */
33132  _invokeOnDestroyCallbacks() {
33133    this._onDestroyCallbacks.forEach((fn) => fn());
33134    this._onDestroyCallbacks = [];
33135  }
33136  /**
33137   * @description
33138   * Resets the control with the provided value if the control is present.
33139   */
33140  reset(value = void 0) {
33141    if (this.control) this.control.reset(value);
33142  }
33143  /**
33144   * @description
33145   * Reports whether the control with the given path has the error specified.
33146   *
33147   * @param errorCode The code of the error to check
33148   * @param path A list of control names that designates how to move from the current control
33149   * to the control that should be queried for errors.
33150   *
33151   * @usageNotes
33152   * For example, for the following `FormGroup`:
33153   *
33154   * ```ts
33155   * form = new FormGroup({
33156   *   address: new FormGroup({ street: new FormControl() })
33157   * });
33158   * ```
33159   *
33160   * The path to the 'street' control from the root form would be 'address' -> 'street'.
33161   *
33162   * It can be provided to this method in one of two formats:
33163   *
33164   * 1. An array of string control names, e.g. `['address', 'street']`
33165   * 1. A period-delimited list of control names in one string, e.g. `'address.street'`
33166   *
33167   * If no path is given, this method checks for the error on the current control.
33168   *
33169   * @returns whether the given error is present in the control at the given path.
33170   *
33171   * If the control is not present, false is returned.
33172   */
33173  hasError(errorCode, path2) {
33174    return this.control ? this.control.hasError(errorCode, path2) : false;
33175  }
33176  /**
33177   * @description
33178   * Reports error data for the control with the given path.
33179   *
33180   * @param errorCode The code of the error to check
33181   * @param path A list of control names that designates how to move from the current control
33182   * to the control that should be queried for errors.
33183   *
33184   * @usageNotes
33185   * For example, for the following `FormGroup`:
33186   *
33187   * ```ts
33188   * form = new FormGroup({
33189   *   address: new FormGroup({ street: new FormControl() })
33190   * });
33191   * ```
33192   *
33193   * The path to the 'street' control from the root form would be 'address' -> 'street'.
33194   *
33195   * It can be provided to this method in one of two formats:
33196   *
33197   * 1. An array of string control names, e.g. `['address', 'street']`
33198   * 1. A period-delimited list of control names in one string, e.g. `'address.street'`
33199   *
33200   * @returns error data for that particular error. If the control or error is not present,
33201   * null is returned.
33202   */
33203  getError(errorCode, path2) {
33204    return this.control ? this.control.getError(errorCode, path2) : null;
33205  }
33206};
33207var ControlContainer = class extends AbstractControlDirective {
33208  /**
33209   * @description
33210   * The name for the control
33211   */
33212  // TODO(issue/24571): remove '!'.
33213  name;
33214  /**
33215   * @description
33216   * The top-level form directive for the control.
33217   */
33218  get formDirective() {
33219    return null;
33220  }
33221  /**
33222   * @description
33223   * The path to this group.
33224   */
33225  get path() {
33226    return null;
33227  }
33228};
33229var NgControl = class extends AbstractControlDirective {
33230  /**
33231   * @description
33232   * The parent form for the control.
33233   *
33234   * @internal
33235   */
33236  _parent = null;
33237  /**
33238   * @description
33239   * The name for the control
33240   */
33241  name = null;
33242  /**
33243   * @description
33244   * The value accessor for the control
33245   */
33246  valueAccessor = null;
33247};
33248var AbstractControlStatus = class {
33249  _cd;
33250  constructor(cd) {
33251    this._cd = cd;
33252  }
33253  get isTouched() {
33254    this._cd?.control?._touched?.();
33255    return !!this._cd?.control?.touched;
33256  }
33257  get isUntouched() {
33258    return !!this._cd?.control?.untouched;
33259  }
33260  get isPristine() {
33261    this._cd?.control?._pristine?.();
33262    return !!this._cd?.control?.pristine;
33263  }
33264  get isDirty() {
33265    return !!this._cd?.control?.dirty;
33266  }
33267  get isValid() {
33268    this._cd?.control?._status?.();
33269    return !!this._cd?.control?.valid;
33270  }
33271  get isInvalid() {
33272    return !!this._cd?.control?.invalid;
33273  }
33274  get isPending() {
33275    return !!this._cd?.control?.pending;
33276  }
33277  get isSubmitted() {
33278    this._cd?._submitted?.();
33279    return !!this._cd?.submitted;
33280  }
33281};
33282var ngControlStatusHost = {
33283  "[class.ng-untouched]": "isUntouched",
33284  "[class.ng-touched]": "isTouched",
33285  "[class.ng-pristine]": "isPristine",
33286  "[class.ng-dirty]": "isDirty",
33287  "[class.ng-valid]": "isValid",
33288  "[class.ng-invalid]": "isInvalid",
33289  "[class.ng-pending]": "isPending"
33290};
33291var ngGroupStatusHost = __spreadProps(__spreadValues({}, ngControlStatusHost), {
33292  "[class.ng-submitted]": "isSubmitted"
33293});
33294var NgControlStatus = class _NgControlStatus extends AbstractControlStatus {
33295  constructor(cd) {
33296    super(cd);
33297  }
33298  static \u0275fac = function NgControlStatus_Factory(__ngFactoryType__) {
33299    return new (__ngFactoryType__ || _NgControlStatus)(\u0275\u0275directiveInject(NgControl, 2));
33300  };
33301  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
33302    type: _NgControlStatus,
33303    selectors: [["", "formControlName", ""], ["", "ngModel", ""], ["", "formControl", ""]],
33304    hostVars: 14,
33305    hostBindings: function NgControlStatus_HostBindings(rf, ctx) {
33306      if (rf & 2) {
33307        \u0275\u0275classProp("ng-untouched", ctx.isUntouched)("ng-touched", ctx.isTouched)("ng-pristine", ctx.isPristine)("ng-dirty", ctx.isDirty)("ng-valid", ctx.isValid)("ng-invalid", ctx.isInvalid)("ng-pending", ctx.isPending);
33308      }
33309    },
33310    standalone: false,
33311    features: [\u0275\u0275InheritDefinitionFeature]
33312  });
33313};
33314(() => {
33315  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgControlStatus, [{
33316    type: Directive,
33317    args: [{
33318      selector: "[formControlName],[ngModel],[formControl]",
33319      host: ngControlStatusHost,
33320      standalone: false
33321    }]
33322  }], () => [{
33323    type: NgControl,
33324    decorators: [{
33325      type: Self
33326    }]
33327  }], null);
33328})();
33329var NgControlStatusGroup = class _NgControlStatusGroup extends AbstractControlStatus {
33330  constructor(cd) {
33331    super(cd);
33332  }
33333  static \u0275fac = function NgControlStatusGroup_Factory(__ngFactoryType__) {
33334    return new (__ngFactoryType__ || _NgControlStatusGroup)(\u0275\u0275directiveInject(ControlContainer, 10));
33335  };
33336  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
33337    type: _NgControlStatusGroup,
33338    selectors: [["", "formGroupName", ""], ["", "formArrayName", ""], ["", "ngModelGroup", ""], ["", "formGroup", ""], ["form", 3, "ngNoForm", ""], ["", "ngForm", ""]],
33339    hostVars: 16,
33340    hostBindings: function NgControlStatusGroup_HostBindings(rf, ctx) {
33341      if (rf & 2) {
33342        \u0275\u0275classProp("ng-untouched", ctx.isUntouched)("ng-touched", ctx.isTouched)("ng-pristine", ctx.isPristine)("ng-dirty", ctx.isDirty)("ng-valid", ctx.isValid)("ng-invalid", ctx.isInvalid)("ng-pending", ctx.isPending)("ng-submitted", ctx.isSubmitted);
33343      }
33344    },
33345    standalone: false,
33346    features: [\u0275\u0275InheritDefinitionFeature]
33347  });
33348};
33349(() => {
33350  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgControlStatusGroup, [{
33351    type: Directive,
33352    args: [{
33353      selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]",
33354      host: ngGroupStatusHost,
33355      standalone: false
33356    }]
33357  }], () => [{
33358    type: ControlContainer,
33359    decorators: [{
33360      type: Optional
33361    }, {
33362      type: Self
33363    }]
33364  }], null);
33365})();
33366var formControlNameExample = `
33367  <div [formGroup]="myGroup">
33368    <input formControlName="firstName">
33369  </div>
33370
33371  In your class:
33372
33373  this.myGroup = new FormGroup({
33374      firstName: new FormControl()
33375  });`;
33376var formGroupNameExample = `
33377  <div [formGroup]="myGroup">
33378      <div formGroupName="person">
33379        <input formControlName="firstName">
33380      </div>
33381  </div>
33382
33383  In your class:
33384
33385  this.myGroup = new FormGroup({
33386      person: new FormGroup({ firstName: new FormControl() })
33387  });`;
33388var formArrayNameExample = `
33389  <div [formGroup]="myGroup">
33390    <div formArrayName="cities">
33391      <div *ngFor="let city of cityArray.controls; index as i">
33392        <input [formControlName]="i">
33393      </div>
33394    </div>
33395  </div>
33396
33397  In your class:
33398
33399  this.cityArray = new FormArray([new FormControl('SF')]);
33400  this.myGroup = new FormGroup({
33401    cities: this.cityArray
33402  });`;
33403var ngModelGroupExample = `
33404  <form>
33405      <div ngModelGroup="person">
33406        <input [(ngModel)]="person.name" name="firstName">
33407      </div>
33408  </form>`;
33409var ngModelWithFormGroupExample = `
33410  <div [formGroup]="myGroup">
33411      <input formControlName="firstName">
33412      <input [(ngModel)]="showMoreControls" [ngModelOptions]="{standalone: true}">
33413  </div>
33414`;
33415function controlParentException(nameOrIndex) {
33416  return new RuntimeError(1050, `formControlName must be used with a parent formGroup directive. You'll want to add a formGroup
33417      directive and pass it an existing FormGroup instance (you can create one in your class).
33418
33419      ${describeFormControl(nameOrIndex)}
33420
33421    Example:
33422
33423    ${formControlNameExample}`);
33424}
33425function describeFormControl(nameOrIndex) {
33426  if (nameOrIndex == null || nameOrIndex === "") {
33427    return "";
33428  }
33429  const valueType = typeof nameOrIndex === "string" ? "name" : "index";
33430  return `Affected Form Control ${valueType}: "${nameOrIndex}"`;
33431}
33432function ngModelGroupException() {
33433  return new RuntimeError(1051, `formControlName cannot be used with an ngModelGroup parent. It is only compatible with parents
33434      that also have a "form" prefix: formGroupName, formArrayName, or formGroup.
33435
33436      Option 1:  Update the parent to be formGroupName (reactive form strategy)
33437
33438      ${formGroupNameExample}
33439
33440      Option 2: Use ngModel instead of formControlName (template-driven strategy)
33441
33442      ${ngModelGroupExample}`);
33443}
33444function missingFormException() {
33445  return new RuntimeError(1052, `formGroup expects a FormGroup instance. Please pass one in.
33446
33447      Example:
33448
33449      ${formControlNameExample}`);
33450}
33451function groupParentException() {
33452  return new RuntimeError(1053, `formGroupName must be used with a parent formGroup directive.  You'll want to add a formGroup
33453    directive and pass it an existing FormGroup instance (you can create one in your class).
33454
33455    Example:
33456
33457    ${formGroupNameExample}`);
33458}
33459function arrayParentException() {
33460  return new RuntimeError(1054, `formArrayName must be used with a parent formGroup directive.  You'll want to add a formGroup
33461      directive and pass it an existing FormGroup instance (you can create one in your class).
33462
33463      Example:
33464
33465      ${formArrayNameExample}`);
33466}
33467var disabledAttrWarning = `
33468  It looks like you're using the disabled attribute with a reactive form directive. If you set disabled to true
33469  when you set up this control in your component class, the disabled attribute will actually be set in the DOM for
33470  you. We recommend using this approach to avoid 'changed after checked' errors.
33471
33472  Example:
33473  // Specify the \`disabled\` property at control creation time:
33474  form = new FormGroup({
33475    first: new FormControl({value: 'Nancy', disabled: true}, Validators.required),
33476    last: new FormControl('Drew', Validators.required)
33477  });
33478
33479  // Controls can also be enabled/disabled after creation:
33480  form.get('first')?.enable();
33481  form.get('last')?.disable();
33482`;
33483var asyncValidatorsDroppedWithOptsWarning = `
33484  It looks like you're constructing using a FormControl with both an options argument and an
33485  async validators argument. Mixing these arguments will cause your async validators to be dropped.
33486  You should either put all your validators in the options object, or in separate validators
33487  arguments. For example:
33488
33489  // Using validators arguments
33490  fc = new FormControl(42, Validators.required, myAsyncValidator);
33491
33492  // Using AbstractControlOptions
33493  fc = new FormControl(42, {validators: Validators.required, asyncValidators: myAV});
33494
33495  // Do NOT mix them: async validators will be dropped!
33496  fc = new FormControl(42, {validators: Validators.required}, /* Oops! */ myAsyncValidator);
33497`;
33498function ngModelWarning(directiveName) {
33499  return `
33500  It looks like you're using ngModel on the same form field as ${directiveName}.
33501  Support for using the ngModel input property and ngModelChange event with
33502  reactive form directives has been deprecated in Angular v6 and will be removed
33503  in a future version of Angular.
33504
33505  For more information on this, see our API docs here:
33506  https://angular.io/api/forms/${directiveName === "formControl" ? "FormControlDirective" : "FormControlName"}#use-with-ngmodel
33507  `;
33508}
33509function describeKey(isFormGroup, key) {
33510  return isFormGroup ? `with name: '${key}'` : `at index: ${key}`;
33511}
33512function noControlsError(isFormGroup) {
33513  return `
33514    There are no form controls registered with this ${isFormGroup ? "group" : "array"} yet. If you're using ngModel,
33515    you may want to check next tick (e.g. use setTimeout).
33516  `;
33517}
33518function missingControlError(isFormGroup, key) {
33519  return `Cannot find form control ${describeKey(isFormGroup, key)}`;
33520}
33521function missingControlValueError(isFormGroup, key) {
33522  return `Must supply a value for form control ${describeKey(isFormGroup, key)}`;
33523}
33524var VALID = "VALID";
33525var INVALID = "INVALID";
33526var PENDING = "PENDING";
33527var DISABLED = "DISABLED";
33528var ControlEvent = class {
33529};
33530var ValueChangeEvent = class extends ControlEvent {
33531  value;
33532  source;
33533  constructor(value, source) {
33534    super();
33535    this.value = value;
33536    this.source = source;
33537  }
33538};
33539var PristineChangeEvent = class extends ControlEvent {
33540  pristine;
33541  source;
33542  constructor(pristine, source) {
33543    super();
33544    this.pristine = pristine;
33545    this.source = source;
33546  }
33547};
33548var TouchedChangeEvent = class extends ControlEvent {
33549  touched;
33550  source;
33551  constructor(touched, source) {
33552    super();
33553    this.touched = touched;
33554    this.source = source;
33555  }
33556};
33557var StatusChangeEvent = class extends ControlEvent {
33558  status;
33559  source;
33560  constructor(status, source) {
33561    super();
33562    this.status = status;
33563    this.source = source;
33564  }
33565};
33566var FormSubmittedEvent = class extends ControlEvent {
33567  source;
33568  constructor(source) {
33569    super();
33570    this.source = source;
33571  }
33572};
33573var FormResetEvent = class extends ControlEvent {
33574  source;
33575  constructor(source) {
33576    super();
33577    this.source = source;
33578  }
33579};
33580function pickValidators(validatorOrOpts) {
33581  return (isOptionsObj(validatorOrOpts) ? validatorOrOpts.validators : validatorOrOpts) || null;
33582}
33583function coerceToValidator(validator) {
33584  return Array.isArray(validator) ? composeValidators(validator) : validator || null;
33585}
33586function pickAsyncValidators(asyncValidator, validatorOrOpts) {
33587  if (typeof ngDevMode === "undefined" || ngDevMode) {
33588    if (isOptionsObj(validatorOrOpts) && asyncValidator) {
33589      console.warn(asyncValidatorsDroppedWithOptsWarning);
33590    }
33591  }
33592  return (isOptionsObj(validatorOrOpts) ? validatorOrOpts.asyncValidators : asyncValidator) || null;
33593}
33594function coerceToAsyncValidator(asyncValidator) {
33595  return Array.isArray(asyncValidator) ? composeAsyncValidators(asyncValidator) : asyncValidator || null;
33596}
33597function isOptionsObj(validatorOrOpts) {
33598  return validatorOrOpts != null && !Array.isArray(validatorOrOpts) && typeof validatorOrOpts === "object";
33599}
33600function assertControlPresent(parent, isGroup, key) {
33601  const controls = parent.controls;
33602  const collection = isGroup ? Object.keys(controls) : controls;
33603  if (!collection.length) {
33604    throw new RuntimeError(1e3, typeof ngDevMode === "undefined" || ngDevMode ? noControlsError(isGroup) : "");
33605  }
33606  if (!controls[key]) {
33607    throw new RuntimeError(1001, typeof ngDevMode === "undefined" || ngDevMode ? missingControlError(isGroup, key) : "");
33608  }
33609}
33610function assertAllValuesPresent(control, isGroup, value) {
33611  control._forEachChild((_2, key) => {
33612    if (value[key] === void 0) {
33613      throw new RuntimeError(1002, typeof ngDevMode === "undefined" || ngDevMode ? missingControlValueError(isGroup, key) : "");
33614    }
33615  });
33616}
33617var AbstractControl = class {
33618  /** @internal */
33619  _pendingDirty = false;
33620  /**
33621   * Indicates that a control has its own pending asynchronous validation in progress.
33622   * It also stores if the control should emit events when the validation status changes.
33623   *
33624   * @internal
33625   */
33626  _hasOwnPendingAsyncValidator = null;
33627  /** @internal */
33628  _pendingTouched = false;
33629  /** @internal */
33630  _onCollectionChange = () => {
33631  };
33632  /** @internal */
33633  _updateOn;
33634  _parent = null;
33635  _asyncValidationSubscription;
33636  /**
33637   * Contains the result of merging synchronous validators into a single validator function
33638   * (combined using `Validators.compose`).
33639   *
33640   * @internal
33641   */
33642  _composedValidatorFn;
33643  /**
33644   * Contains the result of merging asynchronous validators into a single validator function
33645   * (combined using `Validators.composeAsync`).
33646   *
33647   * @internal
33648   */
33649  _composedAsyncValidatorFn;
33650  /**
33651   * Synchronous validators as they were provided:
33652   *  - in `AbstractControl` constructor
33653   *  - as an argument while calling `setValidators` function
33654   *  - while calling the setter on the `validator` field (e.g. `control.validator = validatorFn`)
33655   *
33656   * @internal
33657   */
33658  _rawValidators;
33659  /**
33660   * Asynchronous validators as they were provided:
33661   *  - in `AbstractControl` constructor
33662   *  - as an argument while calling `setAsyncValidators` function
33663   *  - while calling the setter on the `asyncValidator` field (e.g. `control.asyncValidator =
33664   * asyncValidatorFn`)
33665   *
33666   * @internal
33667   */
33668  _rawAsyncValidators;
33669  /**
33670   * The current value of the control.
33671   *
33672   * * For a `FormControl`, the current value.
33673   * * For an enabled `FormGroup`, the values of enabled controls as an object
33674   * with a key-value pair for each member of the group.
33675   * * For a disabled `FormGroup`, the values of all controls as an object
33676   * with a key-value pair for each member of the group.
33677   * * For a `FormArray`, the values of enabled controls as an array.
33678   *
33679   */
33680  value;
33681  /**
33682   * Initialize the AbstractControl instance.
33683   *
33684   * @param validators The function or array of functions that is used to determine the validity of
33685   *     this control synchronously.
33686   * @param asyncValidators The function or array of functions that is used to determine validity of
33687   *     this control asynchronously.
33688   */
33689  constructor(validators, asyncValidators) {
33690    this._assignValidators(validators);
33691    this._assignAsyncValidators(asyncValidators);
33692  }
33693  /**
33694   * Returns the function that is used to determine the validity of this control synchronously.
33695   * If multiple validators have been added, this will be a single composed function.
33696   * See `Validators.compose()` for additional information.
33697   */
33698  get validator() {
33699    return this._composedValidatorFn;
33700  }
33701  set validator(validatorFn) {
33702    this._rawValidators = this._composedValidatorFn = validatorFn;
33703  }
33704  /**
33705   * Returns the function that is used to determine the validity of this control asynchronously.
33706   * If multiple validators have been added, this will be a single composed function.
33707   * See `Validators.compose()` for additional information.
33708   */
33709  get asyncValidator() {
33710    return this._composedAsyncValidatorFn;
33711  }
33712  set asyncValidator(asyncValidatorFn) {
33713    this._rawAsyncValidators = this._composedAsyncValidatorFn = asyncValidatorFn;
33714  }
33715  /**
33716   * The parent control.
33717   */
33718  get parent() {
33719    return this._parent;
33720  }
33721  /**
33722   * The validation status of the control.
33723   *
33724   * @see {@link FormControlStatus}
33725   *
33726   * These status values are mutually exclusive, so a control cannot be
33727   * both valid AND invalid or invalid AND disabled.
33728   */
33729  get status() {
33730    return untracked(this.statusReactive);
33731  }
33732  set status(v) {
33733    untracked(() => this.statusReactive.set(v));
33734  }
33735  /** @internal */
33736  _status = computed(() => this.statusReactive());
33737  statusReactive = signal(void 0);
33738  /**
33739   * A control is `valid` when its `status` is `VALID`.
33740   *
33741   * @see {@link AbstractControl.status}
33742   *
33743   * @returns True if the control has passed all of its validation tests,
33744   * false otherwise.
33745   */
33746  get valid() {
33747    return this.status === VALID;
33748  }
33749  /**
33750   * A control is `invalid` when its `status` is `INVALID`.
33751   *
33752   * @see {@link AbstractControl.status}
33753   *
33754   * @returns True if this control has failed one or more of its validation checks,
33755   * false otherwise.
33756   */
33757  get invalid() {
33758    return this.status === INVALID;
33759  }
33760  /**
33761   * A control is `pending` when its `status` is `PENDING`.
33762   *
33763   * @see {@link AbstractControl.status}
33764   *
33765   * @returns True if this control is in the process of conducting a validation check,
33766   * false otherwise.
33767   */
33768  get pending() {
33769    return this.status == PENDING;
33770  }
33771  /**
33772   * A control is `disabled` when its `status` is `DISABLED`.
33773   *
33774   * Disabled controls are exempt from validation checks and
33775   * are not included in the aggregate value of their ancestor
33776   * controls.
33777   *
33778   * @see {@link AbstractControl.status}
33779   *
33780   * @returns True if the control is disabled, false otherwise.
33781   */
33782  get disabled() {
33783    return this.status === DISABLED;
33784  }
33785  /**
33786   * A control is `enabled` as long as its `status` is not `DISABLED`.
33787   *
33788   * @returns True if the control has any status other than 'DISABLED',
33789   * false if the status is 'DISABLED'.
33790   *
33791   * @see {@link AbstractControl.status}
33792   *
33793   */
33794  get enabled() {
33795    return this.status !== DISABLED;
33796  }
33797  /**
33798   * An object containing any errors generated by failing validation,
33799   * or null if there are no errors.
33800   */
33801  errors;
33802  /**
33803   * A control is `pristine` if the user has not yet changed
33804   * the value in the UI.
33805   *
33806   * @returns True if the user has not yet changed the value in the UI; compare `dirty`.
33807   * Programmatic changes to a control's value do not mark it dirty.
33808   */
33809  get pristine() {
33810    return untracked(this.pristineReactive);
33811  }
33812  set pristine(v) {
33813    untracked(() => this.pristineReactive.set(v));
33814  }
33815  /** @internal */
33816  _pristine = computed(() => this.pristineReactive());
33817  pristineReactive = signal(true);
33818  /**
33819   * A control is `dirty` if the user has changed the value
33820   * in the UI.
33821   *
33822   * @returns True if the user has changed the value of this control in the UI; compare `pristine`.
33823   * Programmatic changes to a control's value do not mark it dirty.
33824   */
33825  get dirty() {
33826    return !this.pristine;
33827  }
33828  /**
33829   * True if the control is marked as `touched`.
33830   *
33831   * A control is marked `touched` once the user has triggered
33832   * a `blur` event on it.
33833   */
33834  get touched() {
33835    return untracked(this.touchedReactive);
33836  }
33837  set touched(v) {
33838    untracked(() => this.touchedReactive.set(v));
33839  }
33840  /** @internal */
33841  _touched = computed(() => this.touchedReactive());
33842  touchedReactive = signal(false);
33843  /**
33844   * True if the control has not been marked as touched
33845   *
33846   * A control is `untouched` if the user has not yet triggered
33847   * a `blur` event on it.
33848   */
33849  get untouched() {
33850    return !this.touched;
33851  }
33852  /**
33853   * Exposed as observable, see below.
33854   *
33855   * @internal
33856   */
33857  _events = new Subject();
33858  /**
33859   * A multicasting observable that emits an event every time the state of the control changes.
33860   * It emits for value, status, pristine or touched changes.
33861   *
33862   * **Note**: On value change, the emit happens right after a value of this control is updated. The
33863   * value of a parent control (for example if this FormControl is a part of a FormGroup) is updated
33864   * later, so accessing a value of a parent control (using the `value` property) from the callback
33865   * of this event might result in getting a value that has not been updated yet. Subscribe to the
33866   * `events` of the parent control instead.
33867   * For other event types, the events are emitted after the parent control has been updated.
33868   *
33869   */
33870  events = this._events.asObservable();
33871  /**
33872   * A multicasting observable that emits an event every time the value of the control changes, in
33873   * the UI or programmatically. It also emits an event each time you call enable() or disable()
33874   * without passing along {emitEvent: false} as a function argument.
33875   *
33876   * **Note**: the emit happens right after a value of this control is updated. The value of a
33877   * parent control (for example if this FormControl is a part of a FormGroup) is updated later, so
33878   * accessing a value of a parent control (using the `value` property) from the callback of this
33879   * event might result in getting a value that has not been updated yet. Subscribe to the
33880   * `valueChanges` event of the parent control instead.
33881   *
33882   * TODO: this should be piped from events() but is breaking in G3
33883   */
33884  valueChanges;
33885  /**
33886   * A multicasting observable that emits an event every time the validation `status` of the control
33887   * recalculates.
33888   *
33889   * @see {@link FormControlStatus}
33890   * @see {@link AbstractControl.status}
33891   *
33892   * TODO: this should be piped from events() but is breaking in G3
33893   */
33894  statusChanges;
33895  /**
33896   * Reports the update strategy of the `AbstractControl` (meaning
33897   * the event on which the control updates itself).
33898   * Possible values: `'change'` | `'blur'` | `'submit'`
33899   * Default value: `'change'`
33900   */
33901  get updateOn() {
33902    return this._updateOn ? this._updateOn : this.parent ? this.parent.updateOn : "change";
33903  }
33904  /**
33905   * Sets the synchronous validators that are active on this control.  Calling
33906   * this overwrites any existing synchronous validators.
33907   *
33908   * When you add or remove a validator at run time, you must call
33909   * `updateValueAndValidity()` for the new validation to take effect.
33910   *
33911   * If you want to add a new validator without affecting existing ones, consider
33912   * using `addValidators()` method instead.
33913   */
33914  setValidators(validators) {
33915    this._assignValidators(validators);
33916  }
33917  /**
33918   * Sets the asynchronous validators that are active on this control. Calling this
33919   * overwrites any existing asynchronous validators.
33920   *
33921   * When you add or remove a validator at run time, you must call
33922   * `updateValueAndValidity()` for the new validation to take effect.
33923   *
33924   * If you want to add a new validator without affecting existing ones, consider
33925   * using `addAsyncValidators()` method instead.
33926   */
33927  setAsyncValidators(validators) {
33928    this._assignAsyncValidators(validators);
33929  }
33930  /**
33931   * Add a synchronous validator or validators to this control, without affecting other validators.
33932   *
33933   * When you add or remove a validator at run time, you must call
33934   * `updateValueAndValidity()` for the new validation to take effect.
33935   *
33936   * Adding a validator that already exists will have no effect. If duplicate validator functions
33937   * are present in the `validators` array, only the first instance would be added to a form
33938   * control.
33939   *
33940   * @param validators The new validator function or functions to add to this control.
33941   */
33942  addValidators(validators) {
33943    this.setValidators(addValidators(validators, this._rawValidators));
33944  }
33945  /**
33946   * Add an asynchronous validator or validators to this control, without affecting other
33947   * validators.
33948   *
33949   * When you add or remove a validator at run time, you must call
33950   * `updateValueAndValidity()` for the new validation to take effect.
33951   *
33952   * Adding a validator that already exists will have no effect.
33953   *
33954   * @param validators The new asynchronous validator function or functions to add to this control.
33955   */
33956  addAsyncValidators(validators) {
33957    this.setAsyncValidators(addValidators(validators, this._rawAsyncValidators));
33958  }
33959  /**
33960   * Remove a synchronous validator from this control, without affecting other validators.
33961   * Validators are compared by function reference; you must pass a reference to the exact same
33962   * validator function as the one that was originally set. If a provided validator is not found,
33963   * it is ignored.
33964   *
33965   * @usageNotes
33966   *
33967   * ### Reference to a ValidatorFn
33968   *
33969   * ```
33970   * // Reference to the RequiredValidator
33971   * const ctrl = new FormControl<string | null>('', Validators.required);
33972   * ctrl.removeValidators(Validators.required);
33973   *
33974   * // Reference to anonymous function inside MinValidator
33975   * const minValidator = Validators.min(3);
33976   * const ctrl = new FormControl<string | null>('', minValidator);
33977   * expect(ctrl.hasValidator(minValidator)).toEqual(true)
33978   * expect(ctrl.hasValidator(Validators.min(3))).toEqual(false)
33979   *
33980   * ctrl.removeValidators(minValidator);
33981   * ```
33982   *
33983   * When you add or remove a validator at run time, you must call
33984   * `updateValueAndValidity()` for the new validation to take effect.
33985   *
33986   * @param validators The validator or validators to remove.
33987   */
33988  removeValidators(validators) {
33989    this.setValidators(removeValidators(validators, this._rawValidators));
33990  }
33991  /**
33992   * Remove an asynchronous validator from this control, without affecting other validators.
33993   * Validators are compared by function reference; you must pass a reference to the exact same
33994   * validator function as the one that was originally set. If a provided validator is not found, it
33995   * is ignored.
33996   *
33997   * When you add or remove a validator at run time, you must call
33998   * `updateValueAndValidity()` for the new validation to take effect.
33999   *
34000   * @param validators The asynchronous validator or validators to remove.
34001   */
34002  removeAsyncValidators(validators) {
34003    this.setAsyncValidators(removeValidators(validators, this._rawAsyncValidators));
34004  }
34005  /**
34006   * Check whether a synchronous validator function is present on this control. The provided
34007   * validator must be a reference to the exact same function that was provided.
34008   *
34009   * @usageNotes
34010   *
34011   * ### Reference to a ValidatorFn
34012   *
34013   * ```
34014   * // Reference to the RequiredValidator
34015   * const ctrl = new FormControl<number | null>(0, Validators.required);
34016   * expect(ctrl.hasValidator(Validators.required)).toEqual(true)
34017   *
34018   * // Reference to anonymous function inside MinValidator
34019   * const minValidator = Validators.min(3);
34020   * const ctrl = new FormControl<number | null>(0, minValidator);
34021   * expect(ctrl.hasValidator(minValidator)).toEqual(true)
34022   * expect(ctrl.hasValidator(Validators.min(3))).toEqual(false)
34023   * ```
34024   *
34025   * @param validator The validator to check for presence. Compared by function reference.
34026   * @returns Whether the provided validator was found on this control.
34027   */
34028  hasValidator(validator) {
34029    return hasValidator(this._rawValidators, validator);
34030  }
34031  /**
34032   * Check whether an asynchronous validator function is present on this control. The provided
34033   * validator must be a reference to the exact same function that was provided.
34034   *
34035   * @param validator The asynchronous validator to check for presence. Compared by function
34036   *     reference.
34037   * @returns Whether the provided asynchronous validator was found on this control.
34038   */
34039  hasAsyncValidator(validator) {
34040    return hasValidator(this._rawAsyncValidators, validator);
34041  }
34042  /**
34043   * Empties out the synchronous validator list.
34044   *
34045   * When you add or remove a validator at run time, you must call
34046   * `updateValueAndValidity()` for the new validation to take effect.
34047   *
34048   */
34049  clearValidators() {
34050    this.validator = null;
34051  }
34052  /**
34053   * Empties out the async validator list.
34054   *
34055   * When you add or remove a validator at run time, you must call
34056   * `updateValueAndValidity()` for the new validation to take effect.
34057   *
34058   */
34059  clearAsyncValidators() {
34060    this.asyncValidator = null;
34061  }
34062  markAsTouched(opts = {}) {
34063    const changed = this.touched === false;
34064    this.touched = true;
34065    const sourceControl = opts.sourceControl ?? this;
34066    if (this._parent && !opts.onlySelf) {
34067      this._parent.markAsTouched(__spreadProps(__spreadValues({}, opts), {
34068        sourceControl
34069      }));
34070    }
34071    if (changed && opts.emitEvent !== false) {
34072      this._events.next(new TouchedChangeEvent(true, sourceControl));
34073    }
34074  }
34075  /**
34076   * Marks the control and all its descendant controls as `touched`.
34077   * @see {@link markAsTouched()}
34078   *
34079   * @param opts Configuration options that determine how the control propagates changes
34080   * and emits events after marking is applied.
34081   * * `emitEvent`: When true or not supplied (the default), the `events`
34082   * observable emits a `TouchedChangeEvent` with the `touched` property being `true`.
34083   * When false, no events are emitted.
34084   */
34085  markAllAsTouched(opts = {}) {
34086    this.markAsTouched({
34087      onlySelf: true,
34088      emitEvent: opts.emitEvent,
34089      sourceControl: this
34090    });
34091    this._forEachChild((control) => control.markAllAsTouched(opts));
34092  }
34093  markAsUntouched(opts = {}) {
34094    const changed = this.touched === true;
34095    this.touched = false;
34096    this._pendingTouched = false;
34097    const sourceControl = opts.sourceControl ?? this;
34098    this._forEachChild((control) => {
34099      control.markAsUntouched({
34100        onlySelf: true,
34101        emitEvent: opts.emitEvent,
34102        sourceControl
34103      });
34104    });
34105    if (this._parent && !opts.onlySelf) {
34106      this._parent._updateTouched(opts, sourceControl);
34107    }
34108    if (changed && opts.emitEvent !== false) {
34109      this._events.next(new TouchedChangeEvent(false, sourceControl));
34110    }
34111  }
34112  markAsDirty(opts = {}) {
34113    const changed = this.pristine === true;
34114    this.pristine = false;
34115    const sourceControl = opts.sourceControl ?? this;
34116    if (this._parent && !opts.onlySelf) {
34117      this._parent.markAsDirty(__spreadProps(__spreadValues({}, opts), {
34118        sourceControl
34119      }));
34120    }
34121    if (changed && opts.emitEvent !== false) {
34122      this._events.next(new PristineChangeEvent(false, sourceControl));
34123    }
34124  }
34125  markAsPristine(opts = {}) {
34126    const changed = this.pristine === false;
34127    this.pristine = true;
34128    this._pendingDirty = false;
34129    const sourceControl = opts.sourceControl ?? this;
34130    this._forEachChild((control) => {
34131      control.markAsPristine({
34132        onlySelf: true,
34133        emitEvent: opts.emitEvent
34134      });
34135    });
34136    if (this._parent && !opts.onlySelf) {
34137      this._parent._updatePristine(opts, sourceControl);
34138    }
34139    if (changed && opts.emitEvent !== false) {
34140      this._events.next(new PristineChangeEvent(true, sourceControl));
34141    }
34142  }
34143  markAsPending(opts = {}) {
34144    this.status = PENDING;
34145    const sourceControl = opts.sourceControl ?? this;
34146    if (opts.emitEvent !== false) {
34147      this._events.next(new StatusChangeEvent(this.status, sourceControl));
34148      this.statusChanges.emit(this.status);
34149    }
34150    if (this._parent && !opts.onlySelf) {
34151      this._parent.markAsPending(__spreadProps(__spreadValues({}, opts), {
34152        sourceControl
34153      }));
34154    }
34155  }
34156  disable(opts = {}) {
34157    const skipPristineCheck = this._parentMarkedDirty(opts.onlySelf);
34158    this.status = DISABLED;
34159    this.errors = null;
34160    this._forEachChild((control) => {
34161      control.disable(__spreadProps(__spreadValues({}, opts), {
34162        onlySelf: true
34163      }));
34164    });
34165    this._updateValue();
34166    const sourceControl = opts.sourceControl ?? this;
34167    if (opts.emitEvent !== false) {
34168      this._events.next(new ValueChangeEvent(this.value, sourceControl));
34169      this._events.next(new StatusChangeEvent(this.status, sourceControl));
34170      this.valueChanges.emit(this.value);
34171      this.statusChanges.emit(this.status);
34172    }
34173    this._updateAncestors(__spreadProps(__spreadValues({}, opts), {
34174      skipPristineCheck
34175    }), this);
34176    this._onDisabledChange.forEach((changeFn) => changeFn(true));
34177  }
34178  /**
34179   * Enables the control. This means the control is included in validation checks and
34180   * the aggregate value of its parent. Its status recalculates based on its value and
34181   * its validators.
34182   *
34183   * By default, if the control has children, all children are enabled.
34184   *
34185   * @see {@link AbstractControl.status}
34186   *
34187   * @param opts Configure options that control how the control propagates changes and
34188   * emits events when marked as untouched
34189   * * `onlySelf`: When true, mark only this control. When false or not supplied,
34190   * marks all direct ancestors. Default is false.
34191   * * `emitEvent`: When true or not supplied (the default), the `statusChanges`,
34192   * `valueChanges` and `events`
34193   * observables emit events with the latest status and value when the control is enabled.
34194   * When false, no events are emitted.
34195   */
34196  enable(opts = {}) {
34197    const skipPristineCheck = this._parentMarkedDirty(opts.onlySelf);
34198    this.status = VALID;
34199    this._forEachChild((control) => {
34200      control.enable(__spreadProps(__spreadValues({}, opts), {
34201        onlySelf: true
34202      }));
34203    });
34204    this.updateValueAndValidity({
34205      onlySelf: true,
34206      emitEvent: opts.emitEvent
34207    });
34208    this._updateAncestors(__spreadProps(__spreadValues({}, opts), {
34209      skipPristineCheck
34210    }), this);
34211    this._onDisabledChange.forEach((changeFn) => changeFn(false));
34212  }
34213  _updateAncestors(opts, sourceControl) {
34214    if (this._parent && !opts.onlySelf) {
34215      this._parent.updateValueAndValidity(opts);
34216      if (!opts.skipPristineCheck) {
34217        this._parent._updatePristine({}, sourceControl);
34218      }
34219      this._parent._updateTouched({}, sourceControl);
34220    }
34221  }
34222  /**
34223   * Sets the parent of the control
34224   *
34225   * @param parent The new parent.
34226   */
34227  setParent(parent) {
34228    this._parent = parent;
34229  }
34230  /**
34231   * The raw value of this control. For most control implementations, the raw value will include
34232   * disabled children.
34233   */
34234  getRawValue() {
34235    return this.value;
34236  }
34237  updateValueAndValidity(opts = {}) {
34238    this._setInitialStatus();
34239    this._updateValue();
34240    if (this.enabled) {
34241      const shouldHaveEmitted = this._cancelExistingSubscription();
34242      this.errors = this._runValidator();
34243      this.status = this._calculateStatus();
34244      if (this.status === VALID || this.status === PENDING) {
34245        this._runAsyncValidator(shouldHaveEmitted, opts.emitEvent);
34246      }
34247    }
34248    const sourceControl = opts.sourceControl ?? this;
34249    if (opts.emitEvent !== false) {
34250      this._events.next(new ValueChangeEvent(this.value, sourceControl));
34251      this._events.next(new StatusChangeEvent(this.status, sourceControl));
34252      this.valueChanges.emit(this.value);
34253      this.statusChanges.emit(this.status);
34254    }
34255    if (this._parent && !opts.onlySelf) {
34256      this._parent.updateValueAndValidity(__spreadProps(__spreadValues({}, opts), {
34257        sourceControl
34258      }));
34259    }
34260  }
34261  /** @internal */
34262  _updateTreeValidity(opts = {
34263    emitEvent: true
34264  }) {
34265    this._forEachChild((ctrl) => ctrl._updateTreeValidity(opts));
34266    this.updateValueAndValidity({
34267      onlySelf: true,
34268      emitEvent: opts.emitEvent
34269    });
34270  }
34271  _setInitialStatus() {
34272    this.status = this._allControlsDisabled() ? DISABLED : VALID;
34273  }
34274  _runValidator() {
34275    return this.validator ? this.validator(this) : null;
34276  }
34277  _runAsyncValidator(shouldHaveEmitted, emitEvent) {
34278    if (this.asyncValidator) {
34279      this.status = PENDING;
34280      this._hasOwnPendingAsyncValidator = {
34281        emitEvent: emitEvent !== false
34282      };
34283      const obs = toObservable(this.asyncValidator(this));
34284      this._asyncValidationSubscription = obs.subscribe((errors) => {
34285        this._hasOwnPendingAsyncValidator = null;
34286        this.setErrors(errors, {
34287          emitEvent,
34288          shouldHaveEmitted
34289        });
34290      });
34291    }
34292  }
34293  _cancelExistingSubscription() {
34294    if (this._asyncValidationSubscription) {
34295      this._asyncValidationSubscription.unsubscribe();
34296      const shouldHaveEmitted = this._hasOwnPendingAsyncValidator?.emitEvent ?? false;
34297      this._hasOwnPendingAsyncValidator = null;
34298      return shouldHaveEmitted;
34299    }
34300    return false;
34301  }
34302  setErrors(errors, opts = {}) {
34303    this.errors = errors;
34304    this._updateControlsErrors(opts.emitEvent !== false, this, opts.shouldHaveEmitted);
34305  }
34306  /**
34307   * Retrieves a child control given the control's name or path.
34308   *
34309   * @param path A dot-delimited string or array of string/number values that define the path to the
34310   * control. If a string is provided, passing it as a string literal will result in improved type
34311   * information. Likewise, if an array is provided, passing it `as const` will cause improved type
34312   * information to be available.
34313   *
34314   * @usageNotes
34315   * ### Retrieve a nested control
34316   *
34317   * For example, to get a `name` control nested within a `person` sub-group:
34318   *
34319   * * `this.form.get('person.name');`
34320   *
34321   * -OR-
34322   *
34323   * * `this.form.get(['person', 'name'] as const);` // `as const` gives improved typings
34324   *
34325   * ### Retrieve a control in a FormArray
34326   *
34327   * When accessing an element inside a FormArray, you can use an element index.
34328   * For example, to get a `price` control from the first element in an `items` array you can use:
34329   *
34330   * * `this.form.get('items.0.price');`
34331   *
34332   * -OR-
34333   *
34334   * * `this.form.get(['items', 0, 'price']);`
34335   */
34336  get(path2) {
34337    let currPath = path2;
34338    if (currPath == null) return null;
34339    if (!Array.isArray(currPath)) currPath = currPath.split(".");
34340    if (currPath.length === 0) return null;
34341    return currPath.reduce((control, name) => control && control._find(name), this);
34342  }
34343  /**
34344   * @description
34345   * Reports error data for the control with the given path.
34346   *
34347   * @param errorCode The code of the error to check
34348   * @param path A list of control names that designates how to move from the current control
34349   * to the control that should be queried for errors.
34350   *
34351   * @usageNotes
34352   * For example, for the following `FormGroup`:
34353   *
34354   * ```ts
34355   * form = new FormGroup({
34356   *   address: new FormGroup({ street: new FormControl() })
34357   * });
34358   * ```
34359   *
34360   * The path to the 'street' control from the root form would be 'address' -> 'street'.
34361   *
34362   * It can be provided to this method in one of two formats:
34363   *
34364   * 1. An array of string control names, e.g. `['address', 'street']`
34365   * 1. A period-delimited list of control names in one string, e.g. `'address.street'`
34366   *
34367   * @returns error data for that particular error. If the control or error is not present,
34368   * null is returned.
34369   */
34370  getError(errorCode, path2) {
34371    const control = path2 ? this.get(path2) : this;
34372    return control && control.errors ? control.errors[errorCode] : null;
34373  }
34374  /**
34375   * @description
34376   * Reports whether the control with the given path has the error specified.
34377   *
34378   * @param errorCode The code of the error to check
34379   * @param path A list of control names that designates how to move from the current control
34380   * to the control that should be queried for errors.
34381   *
34382   * @usageNotes
34383   * For example, for the following `FormGroup`:
34384   *
34385   * ```ts
34386   * form = new FormGroup({
34387   *   address: new FormGroup({ street: new FormControl() })
34388   * });
34389   * ```
34390   *
34391   * The path to the 'street' control from the root form would be 'address' -> 'street'.
34392   *
34393   * It can be provided to this method in one of two formats:
34394   *
34395   * 1. An array of string control names, e.g. `['address', 'street']`
34396   * 1. A period-delimited list of control names in one string, e.g. `'address.street'`
34397   *
34398   * If no path is given, this method checks for the error on the current control.
34399   *
34400   * @returns whether the given error is present in the control at the given path.
34401   *
34402   * If the control is not present, false is returned.
34403   */
34404  hasError(errorCode, path2) {
34405    return !!this.getError(errorCode, path2);
34406  }
34407  /**
34408   * Retrieves the top-level ancestor of this control.
34409   */
34410  get root() {
34411    let x = this;
34412    while (x._parent) {
34413      x = x._parent;
34414    }
34415    return x;
34416  }
34417  /** @internal */
34418  _updateControlsErrors(emitEvent, changedControl, shouldHaveEmitted) {
34419    this.status = this._calculateStatus();
34420    if (emitEvent) {
34421      this.statusChanges.emit(this.status);
34422    }
34423    if (emitEvent || shouldHaveEmitted) {
34424      this._events.next(new StatusChangeEvent(this.status, changedControl));
34425    }
34426    if (this._parent) {
34427      this._parent._updateControlsErrors(emitEvent, changedControl, shouldHaveEmitted);
34428    }
34429  }
34430  /** @internal */
34431  _initObservables() {
34432    this.valueChanges = new EventEmitter();
34433    this.statusChanges = new EventEmitter();
34434  }
34435  _calculateStatus() {
34436    if (this._allControlsDisabled()) return DISABLED;
34437    if (this.errors) return INVALID;
34438    if (this._hasOwnPendingAsyncValidator || this._anyControlsHaveStatus(PENDING)) return PENDING;
34439    if (this._anyControlsHaveStatus(INVALID)) return INVALID;
34440    return VALID;
34441  }
34442  /** @internal */
34443  _anyControlsHaveStatus(status) {
34444    return this._anyControls((control) => control.status === status);
34445  }
34446  /** @internal */
34447  _anyControlsDirty() {
34448    return this._anyControls((control) => control.dirty);
34449  }
34450  /** @internal */
34451  _anyControlsTouched() {
34452    return this._anyControls((control) => control.touched);
34453  }
34454  /** @internal */
34455  _updatePristine(opts, changedControl) {
34456    const newPristine = !this._anyControlsDirty();
34457    const changed = this.pristine !== newPristine;
34458    this.pristine = newPristine;
34459    if (this._parent && !opts.onlySelf) {
34460      this._parent._updatePristine(opts, changedControl);
34461    }
34462    if (changed) {
34463      this._events.next(new PristineChangeEvent(this.pristine, changedControl));
34464    }
34465  }
34466  /** @internal */
34467  _updateTouched(opts = {}, changedControl) {
34468    this.touched = this._anyControlsTouched();
34469    this._events.next(new TouchedChangeEvent(this.touched, changedControl));
34470    if (this._parent && !opts.onlySelf) {
34471      this._parent._updateTouched(opts, changedControl);
34472    }
34473  }
34474  /** @internal */
34475  _onDisabledChange = [];
34476  /** @internal */
34477  _registerOnCollectionChange(fn) {
34478    this._onCollectionChange = fn;
34479  }
34480  /** @internal */
34481  _setUpdateStrategy(opts) {
34482    if (isOptionsObj(opts) && opts.updateOn != null) {
34483      this._updateOn = opts.updateOn;
34484    }
34485  }
34486  /**
34487   * Check to see if parent has been marked artificially dirty.
34488   *
34489   * @internal
34490   */
34491  _parentMarkedDirty(onlySelf) {
34492    const parentDirty = this._parent && this._parent.dirty;
34493    return !onlySelf && !!parentDirty && !this._parent._anyControlsDirty();
34494  }
34495  /** @internal */
34496  _find(name) {
34497    return null;
34498  }
34499  /**
34500   * Internal implementation of the `setValidators` method. Needs to be separated out into a
34501   * different method, because it is called in the constructor and it can break cases where
34502   * a control is extended.
34503   */
34504  _assignValidators(validators) {
34505    this._rawValidators = Array.isArray(validators) ? validators.slice() : validators;
34506    this._composedValidatorFn = coerceToValidator(this._rawValidators);
34507  }
34508  /**
34509   * Internal implementation of the `setAsyncValidators` method. Needs to be separated out into a
34510   * different method, because it is called in the constructor and it can break cases where
34511   * a control is extended.
34512   */
34513  _assignAsyncValidators(validators) {
34514    this._rawAsyncValidators = Array.isArray(validators) ? validators.slice() : validators;
34515    this._composedAsyncValidatorFn = coerceToAsyncValidator(this._rawAsyncValidators);
34516  }
34517};
34518var FormGroup = class extends AbstractControl {
34519  /**
34520   * Creates a new `FormGroup` instance.
34521   *
34522   * @param controls A collection of child controls. The key for each child is the name
34523   * under which it is registered.
34524   *
34525   * @param validatorOrOpts A synchronous validator function, or an array of
34526   * such functions, or an `AbstractControlOptions` object that contains validation functions
34527   * and a validation trigger.
34528   *
34529   * @param asyncValidator A single async validator or array of async validator functions
34530   *
34531   */
34532  constructor(controls, validatorOrOpts, asyncValidator) {
34533    super(pickValidators(validatorOrOpts), pickAsyncValidators(asyncValidator, validatorOrOpts));
34534    (typeof ngDevMode === "undefined" || ngDevMode) && validateFormGroupControls(controls);
34535    this.controls = controls;
34536    this._initObservables();
34537    this._setUpdateStrategy(validatorOrOpts);
34538    this._setUpControls();
34539    this.updateValueAndValidity({
34540      onlySelf: true,
34541      // If `asyncValidator` is present, it will trigger control status change from `PENDING` to
34542      // `VALID` or `INVALID`. The status should be broadcasted via the `statusChanges` observable,
34543      // so we set `emitEvent` to `true` to allow that during the control creation process.
34544      emitEvent: !!this.asyncValidator
34545    });
34546  }
34547  controls;
34548  registerControl(name, control) {
34549    if (this.controls[name]) return this.controls[name];
34550    this.controls[name] = control;
34551    control.setParent(this);
34552    control._registerOnCollectionChange(this._onCollectionChange);
34553    return control;
34554  }
34555  addControl(name, control, options2 = {}) {
34556    this.registerControl(name, control);
34557    this.updateValueAndValidity({
34558      emitEvent: options2.emitEvent
34559    });
34560    this._onCollectionChange();
34561  }
34562  /**
34563   * Remove a control from this group. In a strongly-typed group, required controls cannot be
34564   * removed.
34565   *
34566   * This method also updates the value and validity of the control.
34567   *
34568   * @param name The control name to remove from the collection
34569   * @param options Specifies whether this FormGroup instance should emit events after a
34570   *     control is removed.
34571   * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
34572   * `valueChanges` observables emit events with the latest status and value when the control is
34573   * removed. When false, no events are emitted.
34574   */
34575  removeControl(name, options2 = {}) {
34576    if (this.controls[name]) this.controls[name]._registerOnCollectionChange(() => {
34577    });
34578    delete this.controls[name];
34579    this.updateValueAndValidity({
34580      emitEvent: options2.emitEvent
34581    });
34582    this._onCollectionChange();
34583  }
34584  setControl(name, control, options2 = {}) {
34585    if (this.controls[name]) this.controls[name]._registerOnCollectionChange(() => {
34586    });
34587    delete this.controls[name];
34588    if (control) this.registerControl(name, control);
34589    this.updateValueAndValidity({
34590      emitEvent: options2.emitEvent
34591    });
34592    this._onCollectionChange();
34593  }
34594  contains(controlName) {
34595    return this.controls.hasOwnProperty(controlName) && this.controls[controlName].enabled;
34596  }
34597  /**
34598   * Sets the value of the `FormGroup`. It accepts an object that matches
34599   * the structure of the group, with control names as keys.
34600   *
34601   * @usageNotes
34602   * ### Set the complete value for the form group
34603   *
34604   * ```ts
34605   * const form = new FormGroup({
34606   *   first: new FormControl(),
34607   *   last: new FormControl()
34608   * });
34609   *
34610   * console.log(form.value);   // {first: null, last: null}
34611   *
34612   * form.setValue({first: 'Nancy', last: 'Drew'});
34613   * console.log(form.value);   // {first: 'Nancy', last: 'Drew'}
34614   * ```
34615   *
34616   * @throws When strict checks fail, such as setting the value of a control
34617   * that doesn't exist or if you exclude a value of a control that does exist.
34618   *
34619   * @param value The new value for the control that matches the structure of the group.
34620   * @param options Configuration options that determine how the control propagates changes
34621   * and emits events after the value changes.
34622   * The configuration options are passed to the {@link AbstractControl#updateValueAndValidity
34623   * updateValueAndValidity} method.
34624   *
34625   * * `onlySelf`: When true, each change only affects this control, and not its parent. Default is
34626   * false.
34627   * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
34628   * `valueChanges`
34629   * observables emit events with the latest status and value when the control value is updated.
34630   * When false, no events are emitted.
34631   */
34632  setValue(value, options2 = {}) {
34633    assertAllValuesPresent(this, true, value);
34634    Object.keys(value).forEach((name) => {
34635      assertControlPresent(this, true, name);
34636      this.controls[name].setValue(value[name], {
34637        onlySelf: true,
34638        emitEvent: options2.emitEvent
34639      });
34640    });
34641    this.updateValueAndValidity(options2);
34642  }
34643  /**
34644   * Patches the value of the `FormGroup`. It accepts an object with control
34645   * names as keys, and does its best to match the values to the correct controls
34646   * in the group.
34647   *
34648   * It accepts both super-sets and sub-sets of the group without throwing an error.
34649   *
34650   * @usageNotes
34651   * ### Patch the value for a form group
34652   *
34653   * ```ts
34654   * const form = new FormGroup({
34655   *    first: new FormControl(),
34656   *    last: new FormControl()
34657   * });
34658   * console.log(form.value);   // {first: null, last: null}
34659   *
34660   * form.patchValue({first: 'Nancy'});
34661   * console.log(form.value);   // {first: 'Nancy', last: null}
34662   * ```
34663   *
34664   * @param value The object that matches the structure of the group.
34665   * @param options Configuration options that determine how the control propagates changes and
34666   * emits events after the value is patched.
34667   * * `onlySelf`: When true, each change only affects this control and not its parent. Default is
34668   * true.
34669   * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
34670   * `valueChanges` observables emit events with the latest status and value when the control value
34671   * is updated. When false, no events are emitted. The configuration options are passed to
34672   * the {@link AbstractControl#updateValueAndValidity updateValueAndValidity} method.
34673   */
34674  patchValue(value, options2 = {}) {
34675    if (value == null) return;
34676    Object.keys(value).forEach((name) => {
34677      const control = this.controls[name];
34678      if (control) {
34679        control.patchValue(
34680          /* Guaranteed to be present, due to the outer forEach. */
34681          value[name],
34682          {
34683            onlySelf: true,
34684            emitEvent: options2.emitEvent
34685          }
34686        );
34687      }
34688    });
34689    this.updateValueAndValidity(options2);
34690  }
34691  /**
34692   * Resets the `FormGroup`, marks all descendants `pristine` and `untouched` and sets
34693   * the value of all descendants to their default values, or null if no defaults were provided.
34694   *
34695   * You reset to a specific form state by passing in a map of states
34696   * that matches the structure of your form, with control names as keys. The state
34697   * is a standalone value or a form state object with both a value and a disabled
34698   * status.
34699   *
34700   * @param value Resets the control with an initial value,
34701   * or an object that defines the initial value and disabled state.
34702   *
34703   * @param options Configuration options that determine how the control propagates changes
34704   * and emits events when the group is reset.
34705   * * `onlySelf`: When true, each change only affects this control, and not its parent. Default is
34706   * false.
34707   * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
34708   * `valueChanges`
34709   * observables emit events with the latest status and value when the control is reset.
34710   * When false, no events are emitted.
34711   * The configuration options are passed to the {@link AbstractControl#updateValueAndValidity
34712   * updateValueAndValidity} method.
34713   *
34714   * @usageNotes
34715   *
34716   * ### Reset the form group values
34717   *
34718   * ```ts
34719   * const form = new FormGroup({
34720   *   first: new FormControl('first name'),
34721   *   last: new FormControl('last name')
34722   * });
34723   *
34724   * console.log(form.value);  // {first: 'first name', last: 'last name'}
34725   *
34726   * form.reset({ first: 'name', last: 'last name' });
34727   *
34728   * console.log(form.value);  // {first: 'name', last: 'last name'}
34729   * ```
34730   *
34731   * ### Reset the form group values and disabled status
34732   *
34733   * ```ts
34734   * const form = new FormGroup({
34735   *   first: new FormControl('first name'),
34736   *   last: new FormControl('last name')
34737   * });
34738   *
34739   * form.reset({
34740   *   first: {value: 'name', disabled: true},
34741   *   last: 'last'
34742   * });
34743   *
34744   * console.log(form.value);  // {last: 'last'}
34745   * console.log(form.get('first').status);  // 'DISABLED'
34746   * ```
34747   */
34748  reset(value = {}, options2 = {}) {
34749    this._forEachChild((control, name) => {
34750      control.reset(value ? value[name] : null, {
34751        onlySelf: true,
34752        emitEvent: options2.emitEvent
34753      });
34754    });
34755    this._updatePristine(options2, this);
34756    this._updateTouched(options2, this);
34757    this.updateValueAndValidity(options2);
34758  }
34759  /**
34760   * The aggregate value of the `FormGroup`, including any disabled controls.
34761   *
34762   * Retrieves all values regardless of disabled status.
34763   */
34764  getRawValue() {
34765    return this._reduceChildren({}, (acc, control, name) => {
34766      acc[name] = control.getRawValue();
34767      return acc;
34768    });
34769  }
34770  /** @internal */
34771  _syncPendingControls() {
34772    let subtreeUpdated = this._reduceChildren(false, (updated, child) => {
34773      return child._syncPendingControls() ? true : updated;
34774    });
34775    if (subtreeUpdated) this.updateValueAndValidity({
34776      onlySelf: true
34777    });
34778    return subtreeUpdated;
34779  }
34780  /** @internal */
34781  _forEachChild(cb) {
34782    Object.keys(this.controls).forEach((key) => {
34783      const control = this.controls[key];
34784      control && cb(control, key);
34785    });
34786  }
34787  /** @internal */
34788  _setUpControls() {
34789    this._forEachChild((control) => {
34790      control.setParent(this);
34791      control._registerOnCollectionChange(this._onCollectionChange);
34792    });
34793  }
34794  /** @internal */
34795  _updateValue() {
34796    this.value = this._reduceValue();
34797  }
34798  /** @internal */
34799  _anyControls(condition) {
34800    for (const [controlName, control] of Object.entries(this.controls)) {
34801      if (this.contains(controlName) && condition(control)) {
34802        return true;
34803      }
34804    }
34805    return false;
34806  }
34807  /** @internal */
34808  _reduceValue() {
34809    let acc = {};
34810    return this._reduceChildren(acc, (acc2, control, name) => {
34811      if (control.enabled || this.disabled) {
34812        acc2[name] = control.value;
34813      }
34814      return acc2;
34815    });
34816  }
34817  /** @internal */
34818  _reduceChildren(initValue, fn) {
34819    let res = initValue;
34820    this._forEachChild((control, name) => {
34821      res = fn(res, control, name);
34822    });
34823    return res;
34824  }
34825  /** @internal */
34826  _allControlsDisabled() {
34827    for (const controlName of Object.keys(this.controls)) {
34828      if (this.controls[controlName].enabled) {
34829        return false;
34830      }
34831    }
34832    return Object.keys(this.controls).length > 0 || this.disabled;
34833  }
34834  /** @internal */
34835  _find(name) {
34836    return this.controls.hasOwnProperty(name) ? this.controls[name] : null;
34837  }
34838};
34839function validateFormGroupControls(controls) {
34840  const invalidKeys = Object.keys(controls).filter((key) => key.includes("."));
34841  if (invalidKeys.length > 0) {
34842    console.warn(`FormGroup keys cannot include \`.\`, please replace the keys for: ${invalidKeys.join(",")}.`);
34843  }
34844}
34845var FormRecord = class extends FormGroup {
34846};
34847var CALL_SET_DISABLED_STATE = new InjectionToken(typeof ngDevMode === "undefined" || ngDevMode ? "CallSetDisabledState" : "", {
34848  providedIn: "root",
34849  factory: () => setDisabledStateDefault
34850});
34851var setDisabledStateDefault = "always";
34852function controlPath(name, parent) {
34853  return [...parent.path, name];
34854}
34855function setUpControl(control, dir, callSetDisabledState = setDisabledStateDefault) {
34856  if (typeof ngDevMode === "undefined" || ngDevMode) {
34857    if (!control) _throwError(dir, "Cannot find control with");
34858    if (!dir.valueAccessor) _throwMissingValueAccessorError(dir);
34859  }
34860  setUpValidators(control, dir);
34861  dir.valueAccessor.writeValue(control.value);
34862  if (control.disabled || callSetDisabledState === "always") {
34863    dir.valueAccessor.setDisabledState?.(control.disabled);
34864  }
34865  setUpViewChangePipeline(control, dir);
34866  setUpModelChangePipeline(control, dir);
34867  setUpBlurPipeline(control, dir);
34868  setUpDisabledChangeHandler(control, dir);
34869}
34870function cleanUpControl(control, dir, validateControlPresenceOnChange = true) {
34871  const noop = () => {
34872    if (validateControlPresenceOnChange && (typeof ngDevMode === "undefined" || ngDevMode)) {
34873      _noControlError(dir);
34874    }
34875  };
34876  if (dir.valueAccessor) {
34877    dir.valueAccessor.registerOnChange(noop);
34878    dir.valueAccessor.registerOnTouched(noop);
34879  }
34880  cleanUpValidators(control, dir);
34881  if (control) {
34882    dir._invokeOnDestroyCallbacks();
34883    control._registerOnCollectionChange(() => {
34884    });
34885  }
34886}
34887function registerOnValidatorChange(validators, onChange) {
34888  validators.forEach((validator) => {
34889    if (validator.registerOnValidatorChange) validator.registerOnValidatorChange(onChange);
34890  });
34891}
34892function setUpDisabledChangeHandler(control, dir) {
34893  if (dir.valueAccessor.setDisabledState) {
34894    const onDisabledChange = (isDisabled) => {
34895      dir.valueAccessor.setDisabledState(isDisabled);
34896    };
34897    control.registerOnDisabledChange(onDisabledChange);
34898    dir._registerOnDestroy(() => {
34899      control._unregisterOnDisabledChange(onDisabledChange);
34900    });
34901  }
34902}
34903function setUpValidators(control, dir) {
34904  const validators = getControlValidators(control);
34905  if (dir.validator !== null) {
34906    control.setValidators(mergeValidators(validators, dir.validator));
34907  } else if (typeof validators === "function") {
34908    control.setValidators([validators]);
34909  }
34910  const asyncValidators = getControlAsyncValidators(control);
34911  if (dir.asyncValidator !== null) {
34912    control.setAsyncValidators(mergeValidators(asyncValidators, dir.asyncValidator));
34913  } else if (typeof asyncValidators === "function") {
34914    control.setAsyncValidators([asyncValidators]);
34915  }
34916  const onValidatorChange = () => control.updateValueAndValidity();
34917  registerOnValidatorChange(dir._rawValidators, onValidatorChange);
34918  registerOnValidatorChange(dir._rawAsyncValidators, onValidatorChange);
34919}
34920function cleanUpValidators(control, dir) {
34921  let isControlUpdated = false;
34922  if (control !== null) {
34923    if (dir.validator !== null) {
34924      const validators = getControlValidators(control);
34925      if (Array.isArray(validators) && validators.length > 0) {
34926        const updatedValidators = validators.filter((validator) => validator !== dir.validator);
34927        if (updatedValidators.length !== validators.length) {
34928          isControlUpdated = true;
34929          control.setValidators(updatedValidators);
34930        }
34931      }
34932    }
34933    if (dir.asyncValidator !== null) {
34934      const asyncValidators = getControlAsyncValidators(control);
34935      if (Array.isArray(asyncValidators) && asyncValidators.length > 0) {
34936        const updatedAsyncValidators = asyncValidators.filter((asyncValidator) => asyncValidator !== dir.asyncValidator);
34937        if (updatedAsyncValidators.length !== asyncValidators.length) {
34938          isControlUpdated = true;
34939          control.setAsyncValidators(updatedAsyncValidators);
34940        }
34941      }
34942    }
34943  }
34944  const noop = () => {
34945  };
34946  registerOnValidatorChange(dir._rawValidators, noop);
34947  registerOnValidatorChange(dir._rawAsyncValidators, noop);
34948  return isControlUpdated;
34949}
34950function setUpViewChangePipeline(control, dir) {
34951  dir.valueAccessor.registerOnChange((newValue) => {
34952    control._pendingValue = newValue;
34953    control._pendingChange = true;
34954    control._pendingDirty = true;
34955    if (control.updateOn === "change") updateControl(control, dir);
34956  });
34957}
34958function setUpBlurPipeline(control, dir) {
34959  dir.valueAccessor.registerOnTouched(() => {
34960    control._pendingTouched = true;
34961    if (control.updateOn === "blur" && control._pendingChange) updateControl(control, dir);
34962    if (control.updateOn !== "submit") control.markAsTouched();
34963  });
34964}
34965function updateControl(control, dir) {
34966  if (control._pendingDirty) control.markAsDirty();
34967  control.setValue(control._pendingValue, {
34968    emitModelToViewChange: false
34969  });
34970  dir.viewToModelUpdate(control._pendingValue);
34971  control._pendingChange = false;
34972}
34973function setUpModelChangePipeline(control, dir) {
34974  const onChange = (newValue, emitModelEvent) => {
34975    dir.valueAccessor.writeValue(newValue);
34976    if (emitModelEvent) dir.viewToModelUpdate(newValue);
34977  };
34978  control.registerOnChange(onChange);
34979  dir._registerOnDestroy(() => {
34980    control._unregisterOnChange(onChange);
34981  });
34982}
34983function setUpFormContainer(control, dir) {
34984  if (control == null && (typeof ngDevMode === "undefined" || ngDevMode)) _throwError(dir, "Cannot find control with");
34985  setUpValidators(control, dir);
34986}
34987function cleanUpFormContainer(control, dir) {
34988  return cleanUpValidators(control, dir);
34989}
34990function _noControlError(dir) {
34991  return _throwError(dir, "There is no FormControl instance attached to form control element with");
34992}
34993function _throwError(dir, message) {
34994  const messageEnd = _describeControlLocation(dir);
34995  throw new Error(`${message} ${messageEnd}`);
34996}
34997function _describeControlLocation(dir) {
34998  const path2 = dir.path;
34999  if (path2 && path2.length > 1) return `path: '${path2.join(" -> ")}'`;
35000  if (path2?.[0]) return `name: '${path2}'`;
35001  return "unspecified name attribute";
35002}
35003function _throwMissingValueAccessorError(dir) {
35004  const loc = _describeControlLocation(dir);
35005  throw new RuntimeError(-1203, `No value accessor for form control ${loc}.`);
35006}
35007function _throwInvalidValueAccessorError(dir) {
35008  const loc = _describeControlLocation(dir);
35009  throw new RuntimeError(1200, `Value accessor was not provided as an array for form control with ${loc}. Check that the \`NG_VALUE_ACCESSOR\` token is configured as a \`multi: true\` provider.`);
35010}
35011function isPropertyUpdated(changes, viewModel) {
35012  if (!changes.hasOwnProperty("model")) return false;
35013  const change = changes["model"];
35014  if (change.isFirstChange()) return true;
35015  return !Object.is(viewModel, change.currentValue);
35016}
35017function isBuiltInAccessor(valueAccessor) {
35018  return Object.getPrototypeOf(valueAccessor.constructor) === BuiltInControlValueAccessor;
35019}
35020function syncPendingControls(form, directives) {
35021  form._syncPendingControls();
35022  directives.forEach((dir) => {
35023    const control = dir.control;
35024    if (control.updateOn === "submit" && control._pendingChange) {
35025      dir.viewToModelUpdate(control._pendingValue);
35026      control._pendingChange = false;
35027    }
35028  });
35029}
35030function selectValueAccessor(dir, valueAccessors) {
35031  if (!valueAccessors) return null;
35032  if (!Array.isArray(valueAccessors) && (typeof ngDevMode === "undefined" || ngDevMode)) _throwInvalidValueAccessorError(dir);
35033  let defaultAccessor = void 0;
35034  let builtinAccessor = void 0;
35035  let customAccessor = void 0;
35036  valueAccessors.forEach((v) => {
35037    if (v.constructor === DefaultValueAccessor) {
35038      defaultAccessor = v;
35039    } else if (isBuiltInAccessor(v)) {
35040      if (builtinAccessor && (typeof ngDevMode === "undefined" || ngDevMode)) _throwError(dir, "More than one built-in value accessor matches form control with");
35041      builtinAccessor = v;
35042    } else {
35043      if (customAccessor && (typeof ngDevMode === "undefined" || ngDevMode)) _throwError(dir, "More than one custom value accessor matches form control with");
35044      customAccessor = v;
35045    }
35046  });
35047  if (customAccessor) return customAccessor;
35048  if (builtinAccessor) return builtinAccessor;
35049  if (defaultAccessor) return defaultAccessor;
35050  if (typeof ngDevMode === "undefined" || ngDevMode) {
35051    _throwError(dir, "No valid value accessor for form control with");
35052  }
35053  return null;
35054}
35055function removeListItem$1(list2, el) {
35056  const index = list2.indexOf(el);
35057  if (index > -1) list2.splice(index, 1);
35058}
35059function _ngModelWarning(name, type, instance, warningConfig) {
35060  if (warningConfig === "never") return;
35061  if ((warningConfig === null || warningConfig === "once") && !type._ngModelWarningSentOnce || warningConfig === "always" && !instance._ngModelWarningSent) {
35062    console.warn(ngModelWarning(name));
35063    type._ngModelWarningSentOnce = true;
35064    instance._ngModelWarningSent = true;
35065  }
35066}
35067var formDirectiveProvider$1 = {
35068  provide: ControlContainer,
35069  useExisting: forwardRef(() => NgForm)
35070};
35071var resolvedPromise$1 = (() => Promise.resolve())();
35072var NgForm = class _NgForm extends ControlContainer {
35073  callSetDisabledState;
35074  /**
35075   * @description
35076   * Returns whether the form submission has been triggered.
35077   */
35078  get submitted() {
35079    return untracked(this.submittedReactive);
35080  }
35081  /** @internal */
35082  _submitted = computed(() => this.submittedReactive());
35083  submittedReactive = signal(false);
35084  _directives = /* @__PURE__ */ new Set();
35085  /**
35086   * @description
35087   * The `FormGroup` instance created for this form.
35088   */
35089  form;
35090  /**
35091   * @description
35092   * Event emitter for the "ngSubmit" event
35093   */
35094  ngSubmit = new EventEmitter();
35095  /**
35096   * @description
35097   * Tracks options for the `NgForm` instance.
35098   *
35099   * **updateOn**: Sets the default `updateOn` value for all child `NgModels` below it
35100   * unless explicitly set by a child `NgModel` using `ngModelOptions`). Defaults to 'change'.
35101   * Possible values: `'change'` | `'blur'` | `'submit'`.
35102   *
35103   */
35104  // TODO(issue/24571): remove '!'.
35105  options;
35106  constructor(validators, asyncValidators, callSetDisabledState) {
35107    super();
35108    this.callSetDisabledState = callSetDisabledState;
35109    this.form = new FormGroup({}, composeValidators(validators), composeAsyncValidators(asyncValidators));
35110  }
35111  /** @nodoc */
35112  ngAfterViewInit() {
35113    this._setUpdateStrategy();
35114  }
35115  /**
35116   * @description
35117   * The directive instance.
35118   */
35119  get formDirective() {
35120    return this;
35121  }
35122  /**
35123   * @description
35124   * The internal `FormGroup` instance.
35125   */
35126  get control() {
35127    return this.form;
35128  }
35129  /**
35130   * @description
35131   * Returns an array representing the path to this group. Because this directive
35132   * always lives at the top level of a form, it is always an empty array.
35133   */
35134  get path() {
35135    return [];
35136  }
35137  /**
35138   * @description
35139   * Returns a map of the controls in this group.
35140   */
35141  get controls() {
35142    return this.form.controls;
35143  }
35144  /**
35145   * @description
35146   * Method that sets up the control directive in this group, re-calculates its value
35147   * and validity, and adds the instance to the internal list of directives.
35148   *
35149   * @param dir The `NgModel` directive instance.
35150   */
35151  addControl(dir) {
35152    resolvedPromise$1.then(() => {
35153      const container = this._findContainer(dir.path);
35154      dir.control = container.registerControl(dir.name, dir.control);
35155      setUpControl(dir.control, dir, this.callSetDisabledState);
35156      dir.control.updateValueAndValidity({
35157        emitEvent: false
35158      });
35159      this._directives.add(dir);
35160    });
35161  }
35162  /**
35163   * @description
35164   * Retrieves the `FormControl` instance from the provided `NgModel` directive.
35165   *
35166   * @param dir The `NgModel` directive instance.
35167   */
35168  getControl(dir) {
35169    return this.form.get(dir.path);
35170  }
35171  /**
35172   * @description
35173   * Removes the `NgModel` instance from the internal list of directives
35174   *
35175   * @param dir The `NgModel` directive instance.
35176   */
35177  removeControl(dir) {
35178    resolvedPromise$1.then(() => {
35179      const container = this._findContainer(dir.path);
35180      if (container) {
35181        container.removeControl(dir.name);
35182      }
35183      this._directives.delete(dir);
35184    });
35185  }
35186  /**
35187   * @description
35188   * Adds a new `NgModelGroup` directive instance to the form.
35189   *
35190   * @param dir The `NgModelGroup` directive instance.
35191   */
35192  addFormGroup(dir) {
35193    resolvedPromise$1.then(() => {
35194      const container = this._findContainer(dir.path);
35195      const group = new FormGroup({});
35196      setUpFormContainer(group, dir);
35197      container.registerControl(dir.name, group);
35198      group.updateValueAndValidity({
35199        emitEvent: false
35200      });
35201    });
35202  }
35203  /**
35204   * @description
35205   * Removes the `NgModelGroup` directive instance from the form.
35206   *
35207   * @param dir The `NgModelGroup` directive instance.
35208   */
35209  removeFormGroup(dir) {
35210    resolvedPromise$1.then(() => {
35211      const container = this._findContainer(dir.path);
35212      if (container) {
35213        container.removeControl(dir.name);
35214      }
35215    });
35216  }
35217  /**
35218   * @description
35219   * Retrieves the `FormGroup` for a provided `NgModelGroup` directive instance
35220   *
35221   * @param dir The `NgModelGroup` directive instance.
35222   */
35223  getFormGroup(dir) {
35224    return this.form.get(dir.path);
35225  }
35226  /**
35227   * Sets the new value for the provided `NgControl` directive.
35228   *
35229   * @param dir The `NgControl` directive instance.
35230   * @param value The new value for the directive's control.
35231   */
35232  updateModel(dir, value) {
35233    resolvedPromise$1.then(() => {
35234      const ctrl = this.form.get(dir.path);
35235      ctrl.setValue(value);
35236    });
35237  }
35238  /**
35239   * @description
35240   * Sets the value for this `FormGroup`.
35241   *
35242   * @param value The new value
35243   */
35244  setValue(value) {
35245    this.control.setValue(value);
35246  }
35247  /**
35248   * @description
35249   * Method called when the "submit" event is triggered on the form.
35250   * Triggers the `ngSubmit` emitter to emit the "submit" event as its payload.
35251   *
35252   * @param $event The "submit" event object
35253   */
35254  onSubmit($event) {
35255    this.submittedReactive.set(true);
35256    syncPendingControls(this.form, this._directives);
35257    this.ngSubmit.emit($event);
35258    return $event?.target?.method === "dialog";
35259  }
35260  /**
35261   * @description
35262   * Method called when the "reset" event is triggered on the form.
35263   */
35264  onReset() {
35265    this.resetForm();
35266  }
35267  /**
35268   * @description
35269   * Resets the form to an initial value and resets its submitted status.
35270   *
35271   * @param value The new value for the form.
35272   */
35273  resetForm(value = void 0) {
35274    this.form.reset(value);
35275    this.submittedReactive.set(false);
35276  }
35277  _setUpdateStrategy() {
35278    if (this.options && this.options.updateOn != null) {
35279      this.form._updateOn = this.options.updateOn;
35280    }
35281  }
35282  _findContainer(path2) {
35283    path2.pop();
35284    return path2.length ? this.form.get(path2) : this.form;
35285  }
35286  static \u0275fac = function NgForm_Factory(__ngFactoryType__) {
35287    return new (__ngFactoryType__ || _NgForm)(\u0275\u0275directiveInject(NG_VALIDATORS, 10), \u0275\u0275directiveInject(NG_ASYNC_VALIDATORS, 10), \u0275\u0275directiveInject(CALL_SET_DISABLED_STATE, 8));
35288  };
35289  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
35290    type: _NgForm,
35291    selectors: [["form", 3, "ngNoForm", "", 3, "formGroup", ""], ["ng-form"], ["", "ngForm", ""]],
35292    hostBindings: function NgForm_HostBindings(rf, ctx) {
35293      if (rf & 1) {
35294        \u0275\u0275listener("submit", function NgForm_submit_HostBindingHandler($event) {
35295          return ctx.onSubmit($event);
35296        })("reset", function NgForm_reset_HostBindingHandler() {
35297          return ctx.onReset();
35298        });
35299      }
35300    },
35301    inputs: {
35302      options: [0, "ngFormOptions", "options"]
35303    },
35304    outputs: {
35305      ngSubmit: "ngSubmit"
35306    },
35307    exportAs: ["ngForm"],
35308    standalone: false,
35309    features: [\u0275\u0275ProvidersFeature([formDirectiveProvider$1]), \u0275\u0275InheritDefinitionFeature]
35310  });
35311};
35312(() => {
35313  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgForm, [{
35314    type: Directive,
35315    args: [{
35316      selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]",
35317      providers: [formDirectiveProvider$1],
35318      host: {
35319        "(submit)": "onSubmit($event)",
35320        "(reset)": "onReset()"
35321      },
35322      outputs: ["ngSubmit"],
35323      exportAs: "ngForm",
35324      standalone: false
35325    }]
35326  }], () => [{
35327    type: void 0,
35328    decorators: [{
35329      type: Optional
35330    }, {
35331      type: Self
35332    }, {
35333      type: Inject,
35334      args: [NG_VALIDATORS]
35335    }]
35336  }, {
35337    type: void 0,
35338    decorators: [{
35339      type: Optional
35340    }, {
35341      type: Self
35342    }, {
35343      type: Inject,
35344      args: [NG_ASYNC_VALIDATORS]
35345    }]
35346  }, {
35347    type: void 0,
35348    decorators: [{
35349      type: Optional
35350    }, {
35351      type: Inject,
35352      args: [CALL_SET_DISABLED_STATE]
35353    }]
35354  }], {
35355    options: [{
35356      type: Input,
35357      args: ["ngFormOptions"]
35358    }]
35359  });
35360})();
35361function removeListItem(list2, el) {
35362  const index = list2.indexOf(el);
35363  if (index > -1) list2.splice(index, 1);
35364}
35365function isFormControlState(formState) {
35366  return typeof formState === "object" && formState !== null && Object.keys(formState).length === 2 && "value" in formState && "disabled" in formState;
35367}
35368var FormControl = class FormControl2 extends AbstractControl {
35369  /** @publicApi */
35370  defaultValue = null;
35371  /** @internal */
35372  _onChange = [];
35373  /** @internal */
35374  _pendingValue;
35375  /** @internal */
35376  _pendingChange = false;
35377  constructor(formState = null, validatorOrOpts, asyncValidator) {
35378    super(pickValidators(validatorOrOpts), pickAsyncValidators(asyncValidator, validatorOrOpts));
35379    this._applyFormState(formState);
35380    this._setUpdateStrategy(validatorOrOpts);
35381    this._initObservables();
35382    this.updateValueAndValidity({
35383      onlySelf: true,
35384      // If `asyncValidator` is present, it will trigger control status change from `PENDING` to
35385      // `VALID` or `INVALID`.
35386      // The status should be broadcasted via the `statusChanges` observable, so we set
35387      // `emitEvent` to `true` to allow that during the control creation process.
35388      emitEvent: !!this.asyncValidator
35389    });
35390    if (isOptionsObj(validatorOrOpts) && (validatorOrOpts.nonNullable || validatorOrOpts.initialValueIsDefault)) {
35391      if (isFormControlState(formState)) {
35392        this.defaultValue = formState.value;
35393      } else {
35394        this.defaultValue = formState;
35395      }
35396    }
35397  }
35398  setValue(value, options2 = {}) {
35399    this.value = this._pendingValue = value;
35400    if (this._onChange.length && options2.emitModelToViewChange !== false) {
35401      this._onChange.forEach((changeFn) => changeFn(this.value, options2.emitViewToModelChange !== false));
35402    }
35403    this.updateValueAndValidity(options2);
35404  }
35405  patchValue(value, options2 = {}) {
35406    this.setValue(value, options2);
35407  }
35408  reset(formState = this.defaultValue, options2 = {}) {
35409    this._applyFormState(formState);
35410    this.markAsPristine(options2);
35411    this.markAsUntouched(options2);
35412    this.setValue(this.value, options2);
35413    this._pendingChange = false;
35414  }
35415  /**  @internal */
35416  _updateValue() {
35417  }
35418  /**  @internal */
35419  _anyControls(condition) {
35420    return false;
35421  }
35422  /**  @internal */
35423  _allControlsDisabled() {
35424    return this.disabled;
35425  }
35426  registerOnChange(fn) {
35427    this._onChange.push(fn);
35428  }
35429  /** @internal */
35430  _unregisterOnChange(fn) {
35431    removeListItem(this._onChange, fn);
35432  }
35433  registerOnDisabledChange(fn) {
35434    this._onDisabledChange.push(fn);
35435  }
35436  /** @internal */
35437  _unregisterOnDisabledChange(fn) {
35438    removeListItem(this._onDisabledChange, fn);
35439  }
35440  /** @internal */
35441  _forEachChild(cb) {
35442  }
35443  /** @internal */
35444  _syncPendingControls() {
35445    if (this.updateOn === "submit") {
35446      if (this._pendingDirty) this.markAsDirty();
35447      if (this._pendingTouched) this.markAsTouched();
35448      if (this._pendingChange) {
35449        this.setValue(this._pendingValue, {
35450          onlySelf: true,
35451          emitModelToViewChange: false
35452        });
35453        return true;
35454      }
35455    }
35456    return false;
35457  }
35458  _applyFormState(formState) {
35459    if (isFormControlState(formState)) {
35460      this.value = this._pendingValue = formState.value;
35461      formState.disabled ? this.disable({
35462        onlySelf: true,
35463        emitEvent: false
35464      }) : this.enable({
35465        onlySelf: true,
35466        emitEvent: false
35467      });
35468    } else {
35469      this.value = this._pendingValue = formState;
35470    }
35471  }
35472};
35473var isFormControl = (control) => control instanceof FormControl;
35474var AbstractFormGroupDirective = class _AbstractFormGroupDirective extends ControlContainer {
35475  /**
35476   * @description
35477   * The parent control for the group
35478   *
35479   * @internal
35480   */
35481  // TODO(issue/24571): remove '!'.
35482  _parent;
35483  /** @nodoc */
35484  ngOnInit() {
35485    this._checkParentType();
35486    this.formDirective.addFormGroup(this);
35487  }
35488  /** @nodoc */
35489  ngOnDestroy() {
35490    if (this.formDirective) {
35491      this.formDirective.removeFormGroup(this);
35492    }
35493  }
35494  /**
35495   * @description
35496   * The `FormGroup` bound to this directive.
35497   */
35498  get control() {
35499    return this.formDirective.getFormGroup(this);
35500  }
35501  /**
35502   * @description
35503   * The path to this group from the top-level directive.
35504   */
35505  get path() {
35506    return controlPath(this.name == null ? this.name : this.name.toString(), this._parent);
35507  }
35508  /**
35509   * @description
35510   * The top-level directive for this group if present, otherwise null.
35511   */
35512  get formDirective() {
35513    return this._parent ? this._parent.formDirective : null;
35514  }
35515  /** @internal */
35516  _checkParentType() {
35517  }
35518  static \u0275fac = /* @__PURE__ */ (() => {
35519    let \u0275AbstractFormGroupDirective_BaseFactory;
35520    return function AbstractFormGroupDirective_Factory(__ngFactoryType__) {
35521      return (\u0275AbstractFormGroupDirective_BaseFactory || (\u0275AbstractFormGroupDirective_BaseFactory = \u0275\u0275getInheritedFactory(_AbstractFormGroupDirective)))(__ngFactoryType__ || _AbstractFormGroupDirective);
35522    };
35523  })();
35524  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
35525    type: _AbstractFormGroupDirective,
35526    standalone: false,
35527    features: [\u0275\u0275InheritDefinitionFeature]
35528  });
35529};
35530(() => {
35531  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(AbstractFormGroupDirective, [{
35532    type: Directive,
35533    args: [{
35534      standalone: false
35535    }]
35536  }], null, null);
35537})();
35538function modelParentException() {
35539  return new RuntimeError(1350, `
35540    ngModel cannot be used to register form controls with a parent formGroup directive.  Try using
35541    formGroup's partner directive "formControlName" instead.  Example:
35542
35543    ${formControlNameExample}
35544
35545    Or, if you'd like to avoid registering this form control, indicate that it's standalone in ngModelOptions:
35546
35547    Example:
35548
35549    ${ngModelWithFormGroupExample}`);
35550}
35551function formGroupNameException() {
35552  return new RuntimeError(1351, `
35553    ngModel cannot be used to register form controls with a parent formGroupName or formArrayName directive.
35554
35555    Option 1: Use formControlName instead of ngModel (reactive strategy):
35556
35557    ${formGroupNameExample}
35558
35559    Option 2:  Update ngModel's parent be ngModelGroup (template-driven strategy):
35560
35561    ${ngModelGroupExample}`);
35562}
35563function missingNameException() {
35564  return new RuntimeError(1352, `If ngModel is used within a form tag, either the name attribute must be set or the form
35565    control must be defined as 'standalone' in ngModelOptions.
35566
35567    Example 1: <input [(ngModel)]="person.firstName" name="first">
35568    Example 2: <input [(ngModel)]="person.firstName" [ngModelOptions]="{standalone: true}">`);
35569}
35570function modelGroupParentException() {
35571  return new RuntimeError(1353, `
35572    ngModelGroup cannot be used with a parent formGroup directive.
35573
35574    Option 1: Use formGroupName instead of ngModelGroup (reactive strategy):
35575
35576    ${formGroupNameExample}
35577
35578    Option 2:  Use a regular form tag instead of the formGroup directive (template-driven strategy):
35579
35580    ${ngModelGroupExample}`);
35581}
35582var modelGroupProvider = {
35583  provide: ControlContainer,
35584  useExisting: forwardRef(() => NgModelGroup)
35585};
35586var NgModelGroup = class _NgModelGroup extends AbstractFormGroupDirective {
35587  /**
35588   * @description
35589   * Tracks the name of the `NgModelGroup` bound to the directive. The name corresponds
35590   * to a key in the parent `NgForm`.
35591   */
35592  name = "";
35593  constructor(parent, validators, asyncValidators) {
35594    super();
35595    this._parent = parent;
35596    this._setValidators(validators);
35597    this._setAsyncValidators(asyncValidators);
35598  }
35599  /** @internal */
35600  _checkParentType() {
35601    if (!(this._parent instanceof _NgModelGroup) && !(this._parent instanceof NgForm) && (typeof ngDevMode === "undefined" || ngDevMode)) {
35602      throw modelGroupParentException();
35603    }
35604  }
35605  static \u0275fac = function NgModelGroup_Factory(__ngFactoryType__) {
35606    return new (__ngFactoryType__ || _NgModelGroup)(\u0275\u0275directiveInject(ControlContainer, 5), \u0275\u0275directiveInject(NG_VALIDATORS, 10), \u0275\u0275directiveInject(NG_ASYNC_VALIDATORS, 10));
35607  };
35608  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
35609    type: _NgModelGroup,
35610    selectors: [["", "ngModelGroup", ""]],
35611    inputs: {
35612      name: [0, "ngModelGroup", "name"]
35613    },
35614    exportAs: ["ngModelGroup"],
35615    standalone: false,
35616    features: [\u0275\u0275ProvidersFeature([modelGroupProvider]), \u0275\u0275InheritDefinitionFeature]
35617  });
35618};
35619(() => {
35620  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgModelGroup, [{
35621    type: Directive,
35622    args: [{
35623      selector: "[ngModelGroup]",
35624      providers: [modelGroupProvider],
35625      exportAs: "ngModelGroup",
35626      standalone: false
35627    }]
35628  }], () => [{
35629    type: ControlContainer,
35630    decorators: [{
35631      type: Host
35632    }, {
35633      type: SkipSelf
35634    }]
35635  }, {
35636    type: void 0,
35637    decorators: [{
35638      type: Optional
35639    }, {
35640      type: Self
35641    }, {
35642      type: Inject,
35643      args: [NG_VALIDATORS]
35644    }]
35645  }, {
35646    type: void 0,
35647    decorators: [{
35648      type: Optional
35649    }, {
35650      type: Self
35651    }, {
35652      type: Inject,
35653      args: [NG_ASYNC_VALIDATORS]
35654    }]
35655  }], {
35656    name: [{
35657      type: Input,
35658      args: ["ngModelGroup"]
35659    }]
35660  });
35661})();
35662var formControlBinding$1 = {
35663  provide: NgControl,
35664  useExisting: forwardRef(() => NgModel)
35665};
35666var resolvedPromise = (() => Promise.resolve())();
35667var NgModel = class _NgModel extends NgControl {
35668  _changeDetectorRef;
35669  callSetDisabledState;
35670  control = new FormControl();
35671  // At runtime we coerce arbitrary values assigned to the "disabled" input to a "boolean".
35672  // This is not reflected in the type of the property because outside of templates, consumers
35673  // should only deal with booleans. In templates, a string is allowed for convenience and to
35674  // match the native "disabled attribute" semantics which can be observed on input elements.
35675  // This static member tells the compiler that values of type "string" can also be assigned
35676  // to the input in a template.
35677  /** @nodoc */
35678  static ngAcceptInputType_isDisabled;
35679  /** @internal */
35680  _registered = false;
35681  /**
35682   * Internal reference to the view model value.
35683   * @nodoc
35684   */
35685  viewModel;
35686  /**
35687   * @description
35688   * Tracks the name bound to the directive. If a parent form exists, it
35689   * uses this name as a key to retrieve this control's value.
35690   */
35691  name = "";
35692  /**
35693   * @description
35694   * Tracks whether the control is disabled.
35695   */
35696  // TODO(issue/24571): remove '!'.
35697  isDisabled;
35698  /**
35699   * @description
35700   * Tracks the value bound to this directive.
35701   */
35702  model;
35703  /**
35704   * @description
35705   * Tracks the configuration options for this `ngModel` instance.
35706   *
35707   * **name**: An alternative to setting the name attribute on the form control element. See
35708   * the [example](api/forms/NgModel#using-ngmodel-on-a-standalone-control) for using `NgModel`
35709   * as a standalone control.
35710   *
35711   * **standalone**: When set to true, the `ngModel` will not register itself with its parent form,
35712   * and acts as if it's not in the form. Defaults to false. If no parent form exists, this option
35713   * has no effect.
35714   *
35715   * **updateOn**: Defines the event upon which the form control value and validity update.
35716   * Defaults to 'change'. Possible values: `'change'` | `'blur'` | `'submit'`.
35717   *
35718   */
35719  // TODO(issue/24571): remove '!'.
35720  options;
35721  /**
35722   * @description
35723   * Event emitter for producing the `ngModelChange` event after
35724   * the view model updates.
35725   */
35726  update = new EventEmitter();
35727  constructor(parent, validators, asyncValidators, valueAccessors, _changeDetectorRef, callSetDisabledState) {
35728    super();
35729    this._changeDetectorRef = _changeDetectorRef;
35730    this.callSetDisabledState = callSetDisabledState;
35731    this._parent = parent;
35732    this._setValidators(validators);
35733    this._setAsyncValidators(asyncValidators);
35734    this.valueAccessor = selectValueAccessor(this, valueAccessors);
35735  }
35736  /** @nodoc */
35737  ngOnChanges(changes) {
35738    this._checkForErrors();
35739    if (!this._registered || "name" in changes) {
35740      if (this._registered) {
35741        this._checkName();
35742        if (this.formDirective) {
35743          const oldName = changes["name"].previousValue;
35744          this.formDirective.removeControl({
35745            name: oldName,
35746            path: this._getPath(oldName)
35747          });
35748        }
35749      }
35750      this._setUpControl();
35751    }
35752    if ("isDisabled" in changes) {
35753      this._updateDisabled(changes);
35754    }
35755    if (isPropertyUpdated(changes, this.viewModel)) {
35756      this._updateValue(this.model);
35757      this.viewModel = this.model;
35758    }
35759  }
35760  /** @nodoc */
35761  ngOnDestroy() {
35762    this.formDirective && this.formDirective.removeControl(this);
35763  }
35764  /**
35765   * @description
35766   * Returns an array that represents the path from the top-level form to this control.
35767   * Each index is the string name of the control on that level.
35768   */
35769  get path() {
35770    return this._getPath(this.name);
35771  }
35772  /**
35773   * @description
35774   * The top-level directive for this control if present, otherwise null.
35775   */
35776  get formDirective() {
35777    return this._parent ? this._parent.formDirective : null;
35778  }
35779  /**
35780   * @description
35781   * Sets the new value for the view model and emits an `ngModelChange` event.
35782   *
35783   * @param newValue The new value emitted by `ngModelChange`.
35784   */
35785  viewToModelUpdate(newValue) {
35786    this.viewModel = newValue;
35787    this.update.emit(newValue);
35788  }
35789  _setUpControl() {
35790    this._setUpdateStrategy();
35791    this._isStandalone() ? this._setUpStandalone() : this.formDirective.addControl(this);
35792    this._registered = true;
35793  }
35794  _setUpdateStrategy() {
35795    if (this.options && this.options.updateOn != null) {
35796      this.control._updateOn = this.options.updateOn;
35797    }
35798  }
35799  _isStandalone() {
35800    return !this._parent || !!(this.options && this.options.standalone);
35801  }
35802  _setUpStandalone() {
35803    setUpControl(this.control, this, this.callSetDisabledState);
35804    this.control.updateValueAndValidity({
35805      emitEvent: false
35806    });
35807  }
35808  _checkForErrors() {
35809    if ((typeof ngDevMode === "undefined" || ngDevMode) && !this._isStandalone()) {
35810      checkParentType$1(this._parent);
35811    }
35812    this._checkName();
35813  }
35814  _checkName() {
35815    if (this.options && this.options.name) this.name = this.options.name;
35816    if (!this._isStandalone() && !this.name && (typeof ngDevMode === "undefined" || ngDevMode)) {
35817      throw missingNameException();
35818    }
35819  }
35820  _updateValue(value) {
35821    resolvedPromise.then(() => {
35822      this.control.setValue(value, {
35823        emitViewToModelChange: false
35824      });
35825      this._changeDetectorRef?.markForCheck();
35826    });
35827  }
35828  _updateDisabled(changes) {
35829    const disabledValue = changes["isDisabled"].currentValue;
35830    const isDisabled = disabledValue !== 0 && booleanAttribute(disabledValue);
35831    resolvedPromise.then(() => {
35832      if (isDisabled && !this.control.disabled) {
35833        this.control.disable();
35834      } else if (!isDisabled && this.control.disabled) {
35835        this.control.enable();
35836      }
35837      this._changeDetectorRef?.markForCheck();
35838    });
35839  }
35840  _getPath(controlName) {
35841    return this._parent ? controlPath(controlName, this._parent) : [controlName];
35842  }
35843  static \u0275fac = function NgModel_Factory(__ngFactoryType__) {
35844    return new (__ngFactoryType__ || _NgModel)(\u0275\u0275directiveInject(ControlContainer, 9), \u0275\u0275directiveInject(NG_VALIDATORS, 10), \u0275\u0275directiveInject(NG_ASYNC_VALIDATORS, 10), \u0275\u0275directiveInject(NG_VALUE_ACCESSOR, 10), \u0275\u0275directiveInject(ChangeDetectorRef, 8), \u0275\u0275directiveInject(CALL_SET_DISABLED_STATE, 8));
35845  };
35846  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
35847    type: _NgModel,
35848    selectors: [["", "ngModel", "", 3, "formControlName", "", 3, "formControl", ""]],
35849    inputs: {
35850      name: "name",
35851      isDisabled: [0, "disabled", "isDisabled"],
35852      model: [0, "ngModel", "model"],
35853      options: [0, "ngModelOptions", "options"]
35854    },
35855    outputs: {
35856      update: "ngModelChange"
35857    },
35858    exportAs: ["ngModel"],
35859    standalone: false,
35860    features: [\u0275\u0275ProvidersFeature([formControlBinding$1]), \u0275\u0275InheritDefinitionFeature, \u0275\u0275NgOnChangesFeature]
35861  });
35862};
35863(() => {
35864  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgModel, [{
35865    type: Directive,
35866    args: [{
35867      selector: "[ngModel]:not([formControlName]):not([formControl])",
35868      providers: [formControlBinding$1],
35869      exportAs: "ngModel",
35870      standalone: false
35871    }]
35872  }], () => [{
35873    type: ControlContainer,
35874    decorators: [{
35875      type: Optional
35876    }, {
35877      type: Host
35878    }]
35879  }, {
35880    type: void 0,
35881    decorators: [{
35882      type: Optional
35883    }, {
35884      type: Self
35885    }, {
35886      type: Inject,
35887      args: [NG_VALIDATORS]
35888    }]
35889  }, {
35890    type: void 0,
35891    decorators: [{
35892      type: Optional
35893    }, {
35894      type: Self
35895    }, {
35896      type: Inject,
35897      args: [NG_ASYNC_VALIDATORS]
35898    }]
35899  }, {
35900    type: void 0,
35901    decorators: [{
35902      type: Optional
35903    }, {
35904      type: Self
35905    }, {
35906      type: Inject,
35907      args: [NG_VALUE_ACCESSOR]
35908    }]
35909  }, {
35910    type: ChangeDetectorRef,
35911    decorators: [{
35912      type: Optional
35913    }, {
35914      type: Inject,
35915      args: [ChangeDetectorRef]
35916    }]
35917  }, {
35918    type: void 0,
35919    decorators: [{
35920      type: Optional
35921    }, {
35922      type: Inject,
35923      args: [CALL_SET_DISABLED_STATE]
35924    }]
35925  }], {
35926    name: [{
35927      type: Input
35928    }],
35929    isDisabled: [{
35930      type: Input,
35931      args: ["disabled"]
35932    }],
35933    model: [{
35934      type: Input,
35935      args: ["ngModel"]
35936    }],
35937    options: [{
35938      type: Input,
35939      args: ["ngModelOptions"]
35940    }],
35941    update: [{
35942      type: Output,
35943      args: ["ngModelChange"]
35944    }]
35945  });
35946})();
35947function checkParentType$1(parent) {
35948  if (!(parent instanceof NgModelGroup) && parent instanceof AbstractFormGroupDirective) {
35949    throw formGroupNameException();
35950  } else if (!(parent instanceof NgModelGroup) && !(parent instanceof NgForm)) {
35951    throw modelParentException();
35952  }
35953}
35954var \u0275NgNoValidate = class _\u0275NgNoValidate {
35955  static \u0275fac = function \u0275NgNoValidate_Factory(__ngFactoryType__) {
35956    return new (__ngFactoryType__ || _\u0275NgNoValidate)();
35957  };
35958  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
35959    type: _\u0275NgNoValidate,
35960    selectors: [["form", 3, "ngNoForm", "", 3, "ngNativeValidate", ""]],
35961    hostAttrs: ["novalidate", ""],
35962    standalone: false
35963  });
35964};
35965(() => {
35966  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(\u0275NgNoValidate, [{
35967    type: Directive,
35968    args: [{
35969      selector: "form:not([ngNoForm]):not([ngNativeValidate])",
35970      host: {
35971        "novalidate": ""
35972      },
35973      standalone: false
35974    }]
35975  }], null, null);
35976})();
35977var NUMBER_VALUE_ACCESSOR = {
35978  provide: NG_VALUE_ACCESSOR,
35979  useExisting: forwardRef(() => NumberValueAccessor),
35980  multi: true
35981};
35982var NumberValueAccessor = class _NumberValueAccessor extends BuiltInControlValueAccessor {
35983  /**
35984   * Sets the "value" property on the input element.
35985   * @nodoc
35986   */
35987  writeValue(value) {
35988    const normalizedValue = value == null ? "" : value;
35989    this.setProperty("value", normalizedValue);
35990  }
35991  /**
35992   * Registers a function called when the control value changes.
35993   * @nodoc
35994   */
35995  registerOnChange(fn) {
35996    this.onChange = (value) => {
35997      fn(value == "" ? null : parseFloat(value));
35998    };
35999  }
36000  static \u0275fac = /* @__PURE__ */ (() => {
36001    let \u0275NumberValueAccessor_BaseFactory;
36002    return function NumberValueAccessor_Factory(__ngFactoryType__) {
36003      return (\u0275NumberValueAccessor_BaseFactory || (\u0275NumberValueAccessor_BaseFactory = \u0275\u0275getInheritedFactory(_NumberValueAccessor)))(__ngFactoryType__ || _NumberValueAccessor);
36004    };
36005  })();
36006  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
36007    type: _NumberValueAccessor,
36008    selectors: [["input", "type", "number", "formControlName", ""], ["input", "type", "number", "formControl", ""], ["input", "type", "number", "ngModel", ""]],
36009    hostBindings: function NumberValueAccessor_HostBindings(rf, ctx) {
36010      if (rf & 1) {
36011        \u0275\u0275listener("input", function NumberValueAccessor_input_HostBindingHandler($event) {
36012          return ctx.onChange($event.target.value);
36013        })("blur", function NumberValueAccessor_blur_HostBindingHandler() {
36014          return ctx.onTouched();
36015        });
36016      }
36017    },
36018    standalone: false,
36019    features: [\u0275\u0275ProvidersFeature([NUMBER_VALUE_ACCESSOR]), \u0275\u0275InheritDefinitionFeature]
36020  });
36021};
36022(() => {
36023  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NumberValueAccessor, [{
36024    type: Directive,
36025    args: [{
36026      selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]",
36027      host: {
36028        "(input)": "onChange($event.target.value)",
36029        "(blur)": "onTouched()"
36030      },
36031      providers: [NUMBER_VALUE_ACCESSOR],
36032      standalone: false
36033    }]
36034  }], null, null);
36035})();
36036var RADIO_VALUE_ACCESSOR = {
36037  provide: NG_VALUE_ACCESSOR,
36038  useExisting: forwardRef(() => RadioControlValueAccessor),
36039  multi: true
36040};
36041function throwNameError() {
36042  throw new RuntimeError(1202, `
36043      If you define both a name and a formControlName attribute on your radio button, their values
36044      must match. Ex: <input type="radio" formControlName="food" name="food">
36045    `);
36046}
36047var RadioControlRegistry = class _RadioControlRegistry {
36048  _accessors = [];
36049  /**
36050   * @description
36051   * Adds a control to the internal registry. For internal use only.
36052   */
36053  add(control, accessor) {
36054    this._accessors.push([control, accessor]);
36055  }
36056  /**
36057   * @description
36058   * Removes a control from the internal registry. For internal use only.
36059   */
36060  remove(accessor) {
36061    for (let i = this._accessors.length - 1; i >= 0; --i) {
36062      if (this._accessors[i][1] === accessor) {
36063        this._accessors.splice(i, 1);
36064        return;
36065      }
36066    }
36067  }
36068  /**
36069   * @description
36070   * Selects a radio button. For internal use only.
36071   */
36072  select(accessor) {
36073    this._accessors.forEach((c) => {
36074      if (this._isSameGroup(c, accessor) && c[1] !== accessor) {
36075        c[1].fireUncheck(accessor.value);
36076      }
36077    });
36078  }
36079  _isSameGroup(controlPair, accessor) {
36080    if (!controlPair[0].control) return false;
36081    return controlPair[0]._parent === accessor._control._parent && controlPair[1].name === accessor.name;
36082  }
36083  static \u0275fac = function RadioControlRegistry_Factory(__ngFactoryType__) {
36084    return new (__ngFactoryType__ || _RadioControlRegistry)();
36085  };
36086  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
36087    token: _RadioControlRegistry,
36088    factory: _RadioControlRegistry.\u0275fac,
36089    providedIn: "root"
36090  });
36091};
36092(() => {
36093  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(RadioControlRegistry, [{
36094    type: Injectable,
36095    args: [{
36096      providedIn: "root"
36097    }]
36098  }], null, null);
36099})();
36100var RadioControlValueAccessor = class _RadioControlValueAccessor extends BuiltInControlValueAccessor {
36101  _registry;
36102  _injector;
36103  /** @internal */
36104  // TODO(issue/24571): remove '!'.
36105  _state;
36106  /** @internal */
36107  // TODO(issue/24571): remove '!'.
36108  _control;
36109  /** @internal */
36110  // TODO(issue/24571): remove '!'.
36111  _fn;
36112  setDisabledStateFired = false;
36113  /**
36114   * The registered callback function called when a change event occurs on the input element.
36115   * Note: we declare `onChange` here (also used as host listener) as a function with no arguments
36116   * to override the `onChange` function (which expects 1 argument) in the parent
36117   * `BaseControlValueAccessor` class.
36118   * @nodoc
36119   */
36120  onChange = () => {
36121  };
36122  /**
36123   * @description
36124   * Tracks the name of the radio input element.
36125   */
36126  // TODO(issue/24571): remove '!'.
36127  name;
36128  /**
36129   * @description
36130   * Tracks the name of the `FormControl` bound to the directive. The name corresponds
36131   * to a key in the parent `FormGroup` or `FormArray`.
36132   */
36133  // TODO(issue/24571): remove '!'.
36134  formControlName;
36135  /**
36136   * @description
36137   * Tracks the value of the radio input element
36138   */
36139  value;
36140  callSetDisabledState = inject(CALL_SET_DISABLED_STATE, {
36141    optional: true
36142  }) ?? setDisabledStateDefault;
36143  constructor(renderer, elementRef, _registry, _injector) {
36144    super(renderer, elementRef);
36145    this._registry = _registry;
36146    this._injector = _injector;
36147  }
36148  /** @nodoc */
36149  ngOnInit() {
36150    this._control = this._injector.get(NgControl);
36151    this._checkName();
36152    this._registry.add(this._control, this);
36153  }
36154  /** @nodoc */
36155  ngOnDestroy() {
36156    this._registry.remove(this);
36157  }
36158  /**
36159   * Sets the "checked" property value on the radio input element.
36160   * @nodoc
36161   */
36162  writeValue(value) {
36163    this._state = value === this.value;
36164    this.setProperty("checked", this._state);
36165  }
36166  /**
36167   * Registers a function called when the control value changes.
36168   * @nodoc
36169   */
36170  registerOnChange(fn) {
36171    this._fn = fn;
36172    this.onChange = () => {
36173      fn(this.value);
36174      this._registry.select(this);
36175    };
36176  }
36177  /** @nodoc */
36178  setDisabledState(isDisabled) {
36179    if (this.setDisabledStateFired || isDisabled || this.callSetDisabledState === "whenDisabledForLegacyCode") {
36180      this.setProperty("disabled", isDisabled);
36181    }
36182    this.setDisabledStateFired = true;
36183  }
36184  /**
36185   * Sets the "value" on the radio input element and unchecks it.
36186   *
36187   * @param value
36188   */
36189  fireUncheck(value) {
36190    this.writeValue(value);
36191  }
36192  _checkName() {
36193    if (this.name && this.formControlName && this.name !== this.formControlName && (typeof ngDevMode === "undefined" || ngDevMode)) {
36194      throwNameError();
36195    }
36196    if (!this.name && this.formControlName) this.name = this.formControlName;
36197  }
36198  static \u0275fac = function RadioControlValueAccessor_Factory(__ngFactoryType__) {
36199    return new (__ngFactoryType__ || _RadioControlValueAccessor)(\u0275\u0275directiveInject(Renderer2), \u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(RadioControlRegistry), \u0275\u0275directiveInject(Injector));
36200  };
36201  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
36202    type: _RadioControlValueAccessor,
36203    selectors: [["input", "type", "radio", "formControlName", ""], ["input", "type", "radio", "formControl", ""], ["input", "type", "radio", "ngModel", ""]],
36204    hostBindings: function RadioControlValueAccessor_HostBindings(rf, ctx) {
36205      if (rf & 1) {
36206        \u0275\u0275listener("change", function RadioControlValueAccessor_change_HostBindingHandler() {
36207          return ctx.onChange();
36208        })("blur", function RadioControlValueAccessor_blur_HostBindingHandler() {
36209          return ctx.onTouched();
36210        });
36211      }
36212    },
36213    inputs: {
36214      name: "name",
36215      formControlName: "formControlName",
36216      value: "value"
36217    },
36218    standalone: false,
36219    features: [\u0275\u0275ProvidersFeature([RADIO_VALUE_ACCESSOR]), \u0275\u0275InheritDefinitionFeature]
36220  });
36221};
36222(() => {
36223  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(RadioControlValueAccessor, [{
36224    type: Directive,
36225    args: [{
36226      selector: "input[type=radio][formControlName],input[type=radio][formControl],input[type=radio][ngModel]",
36227      host: {
36228        "(change)": "onChange()",
36229        "(blur)": "onTouched()"
36230      },
36231      providers: [RADIO_VALUE_ACCESSOR],
36232      standalone: false
36233    }]
36234  }], () => [{
36235    type: Renderer2
36236  }, {
36237    type: ElementRef
36238  }, {
36239    type: RadioControlRegistry
36240  }, {
36241    type: Injector
36242  }], {
36243    name: [{
36244      type: Input
36245    }],
36246    formControlName: [{
36247      type: Input
36248    }],
36249    value: [{
36250      type: Input
36251    }]
36252  });
36253})();
36254var RANGE_VALUE_ACCESSOR = {
36255  provide: NG_VALUE_ACCESSOR,
36256  useExisting: forwardRef(() => RangeValueAccessor),
36257  multi: true
36258};
36259var RangeValueAccessor = class _RangeValueAccessor extends BuiltInControlValueAccessor {
36260  /**
36261   * Sets the "value" property on the input element.
36262   * @nodoc
36263   */
36264  writeValue(value) {
36265    this.setProperty("value", parseFloat(value));
36266  }
36267  /**
36268   * Registers a function called when the control value changes.
36269   * @nodoc
36270   */
36271  registerOnChange(fn) {
36272    this.onChange = (value) => {
36273      fn(value == "" ? null : parseFloat(value));
36274    };
36275  }
36276  static \u0275fac = /* @__PURE__ */ (() => {
36277    let \u0275RangeValueAccessor_BaseFactory;
36278    return function RangeValueAccessor_Factory(__ngFactoryType__) {
36279      return (\u0275RangeValueAccessor_BaseFactory || (\u0275RangeValueAccessor_BaseFactory = \u0275\u0275getInheritedFactory(_RangeValueAccessor)))(__ngFactoryType__ || _RangeValueAccessor);
36280    };
36281  })();
36282  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
36283    type: _RangeValueAccessor,
36284    selectors: [["input", "type", "range", "formControlName", ""], ["input", "type", "range", "formControl", ""], ["input", "type", "range", "ngModel", ""]],
36285    hostBindings: function RangeValueAccessor_HostBindings(rf, ctx) {
36286      if (rf & 1) {
36287        \u0275\u0275listener("change", function RangeValueAccessor_change_HostBindingHandler($event) {
36288          return ctx.onChange($event.target.value);
36289        })("input", function RangeValueAccessor_input_HostBindingHandler($event) {
36290          return ctx.onChange($event.target.value);
36291        })("blur", function RangeValueAccessor_blur_HostBindingHandler() {
36292          return ctx.onTouched();
36293        });
36294      }
36295    },
36296    standalone: false,
36297    features: [\u0275\u0275ProvidersFeature([RANGE_VALUE_ACCESSOR]), \u0275\u0275InheritDefinitionFeature]
36298  });
36299};
36300(() => {
36301  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(RangeValueAccessor, [{
36302    type: Directive,
36303    args: [{
36304      selector: "input[type=range][formControlName],input[type=range][formControl],input[type=range][ngModel]",
36305      host: {
36306        "(change)": "onChange($event.target.value)",
36307        "(input)": "onChange($event.target.value)",
36308        "(blur)": "onTouched()"
36309      },
36310      providers: [RANGE_VALUE_ACCESSOR],
36311      standalone: false
36312    }]
36313  }], null, null);
36314})();
36315var NG_MODEL_WITH_FORM_CONTROL_WARNING = new InjectionToken(ngDevMode ? "NgModelWithFormControlWarning" : "");
36316var formControlBinding = {
36317  provide: NgControl,
36318  useExisting: forwardRef(() => FormControlDirective)
36319};
36320var FormControlDirective = class _FormControlDirective extends NgControl {
36321  _ngModelWarningConfig;
36322  callSetDisabledState;
36323  /**
36324   * Internal reference to the view model value.
36325   * @nodoc
36326   */
36327  viewModel;
36328  /**
36329   * @description
36330   * Tracks the `FormControl` instance bound to the directive.
36331   */
36332  // TODO(issue/24571): remove '!'.
36333  form;
36334  /**
36335   * @description
36336   * Triggers a warning in dev mode that this input should not be used with reactive forms.
36337   */
36338  set isDisabled(isDisabled) {
36339    if (typeof ngDevMode === "undefined" || ngDevMode) {
36340      console.warn(disabledAttrWarning);
36341    }
36342  }
36343  // TODO(kara): remove next 4 properties once deprecation period is over
36344  /** @deprecated as of v6 */
36345  model;
36346  /** @deprecated as of v6 */
36347  update = new EventEmitter();
36348  /**
36349   * @description
36350   * Static property used to track whether any ngModel warnings have been sent across
36351   * all instances of FormControlDirective. Used to support warning config of "once".
36352   *
36353   * @internal
36354   */
36355  static _ngModelWarningSentOnce = false;
36356  /**
36357   * @description
36358   * Instance property used to track whether an ngModel warning has been sent out for this
36359   * particular `FormControlDirective` instance. Used to support warning config of "always".
36360   *
36361   * @internal
36362   */
36363  _ngModelWarningSent = false;
36364  constructor(validators, asyncValidators, valueAccessors, _ngModelWarningConfig, callSetDisabledState) {
36365    super();
36366    this._ngModelWarningConfig = _ngModelWarningConfig;
36367    this.callSetDisabledState = callSetDisabledState;
36368    this._setValidators(validators);
36369    this._setAsyncValidators(asyncValidators);
36370    this.valueAccessor = selectValueAccessor(this, valueAccessors);
36371  }
36372  /** @nodoc */
36373  ngOnChanges(changes) {
36374    if (this._isControlChanged(changes)) {
36375      const previousForm = changes["form"].previousValue;
36376      if (previousForm) {
36377        cleanUpControl(
36378          previousForm,
36379          this,
36380          /* validateControlPresenceOnChange */
36381          false
36382        );
36383      }
36384      setUpControl(this.form, this, this.callSetDisabledState);
36385      this.form.updateValueAndValidity({
36386        emitEvent: false
36387      });
36388    }
36389    if (isPropertyUpdated(changes, this.viewModel)) {
36390      if (typeof ngDevMode === "undefined" || ngDevMode) {
36391        _ngModelWarning("formControl", _FormControlDirective, this, this._ngModelWarningConfig);
36392      }
36393      this.form.setValue(this.model);
36394      this.viewModel = this.model;
36395    }
36396  }
36397  /** @nodoc */
36398  ngOnDestroy() {
36399    if (this.form) {
36400      cleanUpControl(
36401        this.form,
36402        this,
36403        /* validateControlPresenceOnChange */
36404        false
36405      );
36406    }
36407  }
36408  /**
36409   * @description
36410   * Returns an array that represents the path from the top-level form to this control.
36411   * Each index is the string name of the control on that level.
36412   */
36413  get path() {
36414    return [];
36415  }
36416  /**
36417   * @description
36418   * The `FormControl` bound to this directive.
36419   */
36420  get control() {
36421    return this.form;
36422  }
36423  /**
36424   * @description
36425   * Sets the new value for the view model and emits an `ngModelChange` event.
36426   *
36427   * @param newValue The new value for the view model.
36428   */
36429  viewToModelUpdate(newValue) {
36430    this.viewModel = newValue;
36431    this.update.emit(newValue);
36432  }
36433  _isControlChanged(changes) {
36434    return changes.hasOwnProperty("form");
36435  }
36436  static \u0275fac = function FormControlDirective_Factory(__ngFactoryType__) {
36437    return new (__ngFactoryType__ || _FormControlDirective)(\u0275\u0275directiveInject(NG_VALIDATORS, 10), \u0275\u0275directiveInject(NG_ASYNC_VALIDATORS, 10), \u0275\u0275directiveInject(NG_VALUE_ACCESSOR, 10), \u0275\u0275directiveInject(NG_MODEL_WITH_FORM_CONTROL_WARNING, 8), \u0275\u0275directiveInject(CALL_SET_DISABLED_STATE, 8));
36438  };
36439  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
36440    type: _FormControlDirective,
36441    selectors: [["", "formControl", ""]],
36442    inputs: {
36443      form: [0, "formControl", "form"],
36444      isDisabled: [0, "disabled", "isDisabled"],
36445      model: [0, "ngModel", "model"]
36446    },
36447    outputs: {
36448      update: "ngModelChange"
36449    },
36450    exportAs: ["ngForm"],
36451    standalone: false,
36452    features: [\u0275\u0275ProvidersFeature([formControlBinding]), \u0275\u0275InheritDefinitionFeature, \u0275\u0275NgOnChangesFeature]
36453  });
36454};
36455(() => {
36456  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(FormControlDirective, [{
36457    type: Directive,
36458    args: [{
36459      selector: "[formControl]",
36460      providers: [formControlBinding],
36461      exportAs: "ngForm",
36462      standalone: false
36463    }]
36464  }], () => [{
36465    type: void 0,
36466    decorators: [{
36467      type: Optional
36468    }, {
36469      type: Self
36470    }, {
36471      type: Inject,
36472      args: [NG_VALIDATORS]
36473    }]
36474  }, {
36475    type: void 0,
36476    decorators: [{
36477      type: Optional
36478    }, {
36479      type: Self
36480    }, {
36481      type: Inject,
36482      args: [NG_ASYNC_VALIDATORS]
36483    }]
36484  }, {
36485    type: void 0,
36486    decorators: [{
36487      type: Optional
36488    }, {
36489      type: Self
36490    }, {
36491      type: Inject,
36492      args: [NG_VALUE_ACCESSOR]
36493    }]
36494  }, {
36495    type: void 0,
36496    decorators: [{
36497      type: Optional
36498    }, {
36499      type: Inject,
36500      args: [NG_MODEL_WITH_FORM_CONTROL_WARNING]
36501    }]
36502  }, {
36503    type: void 0,
36504    decorators: [{
36505      type: Optional
36506    }, {
36507      type: Inject,
36508      args: [CALL_SET_DISABLED_STATE]
36509    }]
36510  }], {
36511    form: [{
36512      type: Input,
36513      args: ["formControl"]
36514    }],
36515    isDisabled: [{
36516      type: Input,
36517      args: ["disabled"]
36518    }],
36519    model: [{
36520      type: Input,
36521      args: ["ngModel"]
36522    }],
36523    update: [{
36524      type: Output,
36525      args: ["ngModelChange"]
36526    }]
36527  });
36528})();
36529var formDirectiveProvider = {
36530  provide: ControlContainer,
36531  useExisting: forwardRef(() => FormGroupDirective)
36532};
36533var FormGroupDirective = class _FormGroupDirective extends ControlContainer {
36534  callSetDisabledState;
36535  /**
36536   * @description
36537   * Reports whether the form submission has been triggered.
36538   */
36539  get submitted() {
36540    return untracked(this._submittedReactive);
36541  }
36542  // TODO(atscott): Remove once invalid API usage is cleaned up internally
36543  set submitted(value) {
36544    this._submittedReactive.set(value);
36545  }
36546  /** @internal */
36547  _submitted = computed(() => this._submittedReactive());
36548  _submittedReactive = signal(false);
36549  /**
36550   * Reference to an old form group input value, which is needed to cleanup
36551   * old instance in case it was replaced with a new one.
36552   */
36553  _oldForm;
36554  /**
36555   * Callback that should be invoked when controls in FormGroup or FormArray collection change
36556   * (added or removed). This callback triggers corresponding DOM updates.
36557   */
36558  _onCollectionChange = () => this._updateDomValue();
36559  /**
36560   * @description
36561   * Tracks the list of added `FormControlName` instances
36562   */
36563  directives = [];
36564  /**
36565   * @description
36566   * Tracks the `FormGroup` bound to this directive.
36567   */
36568  form = null;
36569  /**
36570   * @description
36571   * Emits an event when the form submission has been triggered.
36572   */
36573  ngSubmit = new EventEmitter();
36574  constructor(validators, asyncValidators, callSetDisabledState) {
36575    super();
36576    this.callSetDisabledState = callSetDisabledState;
36577    this._setValidators(validators);
36578    this._setAsyncValidators(asyncValidators);
36579  }
36580  /** @nodoc */
36581  ngOnChanges(changes) {
36582    if ((typeof ngDevMode === "undefined" || ngDevMode) && !this.form) {
36583      throw missingFormException();
36584    }
36585    if (changes.hasOwnProperty("form")) {
36586      this._updateValidators();
36587      this._updateDomValue();
36588      this._updateRegistrations();
36589      this._oldForm = this.form;
36590    }
36591  }
36592  /** @nodoc */
36593  ngOnDestroy() {
36594    if (this.form) {
36595      cleanUpValidators(this.form, this);
36596      if (this.form._onCollectionChange === this._onCollectionChange) {
36597        this.form._registerOnCollectionChange(() => {
36598        });
36599      }
36600    }
36601  }
36602  /**
36603   * @description
36604   * Returns this directive's instance.
36605   */
36606  get formDirective() {
36607    return this;
36608  }
36609  /**
36610   * @description
36611   * Returns the `FormGroup` bound to this directive.
36612   */
36613  get control() {
36614    return this.form;
36615  }
36616  /**
36617   * @description
36618   * Returns an array representing the path to this group. Because this directive
36619   * always lives at the top level of a form, it always an empty array.
36620   */
36621  get path() {
36622    return [];
36623  }
36624  /**
36625   * @description
36626   * Method that sets up the control directive in this group, re-calculates its value
36627   * and validity, and adds the instance to the internal list of directives.
36628   *
36629   * @param dir The `FormControlName` directive instance.
36630   */
36631  addControl(dir) {
36632    const ctrl = this.form.get(dir.path);
36633    setUpControl(ctrl, dir, this.callSetDisabledState);
36634    ctrl.updateValueAndValidity({
36635      emitEvent: false
36636    });
36637    this.directives.push(dir);
36638    return ctrl;
36639  }
36640  /**
36641   * @description
36642   * Retrieves the `FormControl` instance from the provided `FormControlName` directive
36643   *
36644   * @param dir The `FormControlName` directive instance.
36645   */
36646  getControl(dir) {
36647    return this.form.get(dir.path);
36648  }
36649  /**
36650   * @description
36651   * Removes the `FormControlName` instance from the internal list of directives
36652   *
36653   * @param dir The `FormControlName` directive instance.
36654   */
36655  removeControl(dir) {
36656    cleanUpControl(
36657      dir.control || null,
36658      dir,
36659      /* validateControlPresenceOnChange */
36660      false
36661    );
36662    removeListItem$1(this.directives, dir);
36663  }
36664  /**
36665   * Adds a new `FormGroupName` directive instance to the form.
36666   *
36667   * @param dir The `FormGroupName` directive instance.
36668   */
36669  addFormGroup(dir) {
36670    this._setUpFormContainer(dir);
36671  }
36672  /**
36673   * Performs the necessary cleanup when a `FormGroupName` directive instance is removed from the
36674   * view.
36675   *
36676   * @param dir The `FormGroupName` directive instance.
36677   */
36678  removeFormGroup(dir) {
36679    this._cleanUpFormContainer(dir);
36680  }
36681  /**
36682   * @description
36683   * Retrieves the `FormGroup` for a provided `FormGroupName` directive instance
36684   *
36685   * @param dir The `FormGroupName` directive instance.
36686   */
36687  getFormGroup(dir) {
36688    return this.form.get(dir.path);
36689  }
36690  /**
36691   * Performs the necessary setup when a `FormArrayName` directive instance is added to the view.
36692   *
36693   * @param dir The `FormArrayName` directive instance.
36694   */
36695  addFormArray(dir) {
36696    this._setUpFormContainer(dir);
36697  }
36698  /**
36699   * Performs the necessary cleanup when a `FormArrayName` directive instance is removed from the
36700   * view.
36701   *
36702   * @param dir The `FormArrayName` directive instance.
36703   */
36704  removeFormArray(dir) {
36705    this._cleanUpFormContainer(dir);
36706  }
36707  /**
36708   * @description
36709   * Retrieves the `FormArray` for a provided `FormArrayName` directive instance.
36710   *
36711   * @param dir The `FormArrayName` directive instance.
36712   */
36713  getFormArray(dir) {
36714    return this.form.get(dir.path);
36715  }
36716  /**
36717   * Sets the new value for the provided `FormControlName` directive.
36718   *
36719   * @param dir The `FormControlName` directive instance.
36720   * @param value The new value for the directive's control.
36721   */
36722  updateModel(dir, value) {
36723    const ctrl = this.form.get(dir.path);
36724    ctrl.setValue(value);
36725  }
36726  /**
36727   * @description
36728   * Method called with the "submit" event is triggered on the form.
36729   * Triggers the `ngSubmit` emitter to emit the "submit" event as its payload.
36730   *
36731   * @param $event The "submit" event object
36732   */
36733  onSubmit($event) {
36734    this._submittedReactive.set(true);
36735    syncPendingControls(this.form, this.directives);
36736    this.ngSubmit.emit($event);
36737    this.form._events.next(new FormSubmittedEvent(this.control));
36738    return $event?.target?.method === "dialog";
36739  }
36740  /**
36741   * @description
36742   * Method called when the "reset" event is triggered on the form.
36743   */
36744  onReset() {
36745    this.resetForm();
36746  }
36747  /**
36748   * @description
36749   * Resets the form to an initial value and resets its submitted status.
36750   *
36751   * @param value The new value for the form.
36752   */
36753  resetForm(value = void 0) {
36754    this.form.reset(value);
36755    this._submittedReactive.set(false);
36756    this.form._events.next(new FormResetEvent(this.form));
36757  }
36758  /** @internal */
36759  _updateDomValue() {
36760    this.directives.forEach((dir) => {
36761      const oldCtrl = dir.control;
36762      const newCtrl = this.form.get(dir.path);
36763      if (oldCtrl !== newCtrl) {
36764        cleanUpControl(oldCtrl || null, dir);
36765        if (isFormControl(newCtrl)) {
36766          setUpControl(newCtrl, dir, this.callSetDisabledState);
36767          dir.control = newCtrl;
36768        }
36769      }
36770    });
36771    this.form._updateTreeValidity({
36772      emitEvent: false
36773    });
36774  }
36775  _setUpFormContainer(dir) {
36776    const ctrl = this.form.get(dir.path);
36777    setUpFormContainer(ctrl, dir);
36778    ctrl.updateValueAndValidity({
36779      emitEvent: false
36780    });
36781  }
36782  _cleanUpFormContainer(dir) {
36783    if (this.form) {
36784      const ctrl = this.form.get(dir.path);
36785      if (ctrl) {
36786        const isControlUpdated = cleanUpFormContainer(ctrl, dir);
36787        if (isControlUpdated) {
36788          ctrl.updateValueAndValidity({
36789            emitEvent: false
36790          });
36791        }
36792      }
36793    }
36794  }
36795  _updateRegistrations() {
36796    this.form._registerOnCollectionChange(this._onCollectionChange);
36797    if (this._oldForm) {
36798      this._oldForm._registerOnCollectionChange(() => {
36799      });
36800    }
36801  }
36802  _updateValidators() {
36803    setUpValidators(this.form, this);
36804    if (this._oldForm) {
36805      cleanUpValidators(this._oldForm, this);
36806    }
36807  }
36808  static \u0275fac = function FormGroupDirective_Factory(__ngFactoryType__) {
36809    return new (__ngFactoryType__ || _FormGroupDirective)(\u0275\u0275directiveInject(NG_VALIDATORS, 10), \u0275\u0275directiveInject(NG_ASYNC_VALIDATORS, 10), \u0275\u0275directiveInject(CALL_SET_DISABLED_STATE, 8));
36810  };
36811  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
36812    type: _FormGroupDirective,
36813    selectors: [["", "formGroup", ""]],
36814    hostBindings: function FormGroupDirective_HostBindings(rf, ctx) {
36815      if (rf & 1) {
36816        \u0275\u0275listener("submit", function FormGroupDirective_submit_HostBindingHandler($event) {
36817          return ctx.onSubmit($event);
36818        })("reset", function FormGroupDirective_reset_HostBindingHandler() {
36819          return ctx.onReset();
36820        });
36821      }
36822    },
36823    inputs: {
36824      form: [0, "formGroup", "form"]
36825    },
36826    outputs: {
36827      ngSubmit: "ngSubmit"
36828    },
36829    exportAs: ["ngForm"],
36830    standalone: false,
36831    features: [\u0275\u0275ProvidersFeature([formDirectiveProvider]), \u0275\u0275InheritDefinitionFeature, \u0275\u0275NgOnChangesFeature]
36832  });
36833};
36834(() => {
36835  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(FormGroupDirective, [{
36836    type: Directive,
36837    args: [{
36838      selector: "[formGroup]",
36839      providers: [formDirectiveProvider],
36840      host: {
36841        "(submit)": "onSubmit($event)",
36842        "(reset)": "onReset()"
36843      },
36844      exportAs: "ngForm",
36845      standalone: false
36846    }]
36847  }], () => [{
36848    type: void 0,
36849    decorators: [{
36850      type: Optional
36851    }, {
36852      type: Self
36853    }, {
36854      type: Inject,
36855      args: [NG_VALIDATORS]
36856    }]
36857  }, {
36858    type: void 0,
36859    decorators: [{
36860      type: Optional
36861    }, {
36862      type: Self
36863    }, {
36864      type: Inject,
36865      args: [NG_ASYNC_VALIDATORS]
36866    }]
36867  }, {
36868    type: void 0,
36869    decorators: [{
36870      type: Optional
36871    }, {
36872      type: Inject,
36873      args: [CALL_SET_DISABLED_STATE]
36874    }]
36875  }], {
36876    form: [{
36877      type: Input,
36878      args: ["formGroup"]
36879    }],
36880    ngSubmit: [{
36881      type: Output
36882    }]
36883  });
36884})();
36885var formGroupNameProvider = {
36886  provide: ControlContainer,
36887  useExisting: forwardRef(() => FormGroupName)
36888};
36889var FormGroupName = class _FormGroupName extends AbstractFormGroupDirective {
36890  /**
36891   * @description
36892   * Tracks the name of the `FormGroup` bound to the directive. The name corresponds
36893   * to a key in the parent `FormGroup` or `FormArray`.
36894   * Accepts a name as a string or a number.
36895   * The name in the form of a string is useful for individual forms,
36896   * while the numerical form allows for form groups to be bound
36897   * to indices when iterating over groups in a `FormArray`.
36898   */
36899  name = null;
36900  constructor(parent, validators, asyncValidators) {
36901    super();
36902    this._parent = parent;
36903    this._setValidators(validators);
36904    this._setAsyncValidators(asyncValidators);
36905  }
36906  /** @internal */
36907  _checkParentType() {
36908    if (hasInvalidParent(this._parent) && (typeof ngDevMode === "undefined" || ngDevMode)) {
36909      throw groupParentException();
36910    }
36911  }
36912  static \u0275fac = function FormGroupName_Factory(__ngFactoryType__) {
36913    return new (__ngFactoryType__ || _FormGroupName)(\u0275\u0275directiveInject(ControlContainer, 13), \u0275\u0275directiveInject(NG_VALIDATORS, 10), \u0275\u0275directiveInject(NG_ASYNC_VALIDATORS, 10));
36914  };
36915  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
36916    type: _FormGroupName,
36917    selectors: [["", "formGroupName", ""]],
36918    inputs: {
36919      name: [0, "formGroupName", "name"]
36920    },
36921    standalone: false,
36922    features: [\u0275\u0275ProvidersFeature([formGroupNameProvider]), \u0275\u0275InheritDefinitionFeature]
36923  });
36924};
36925(() => {
36926  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(FormGroupName, [{
36927    type: Directive,
36928    args: [{
36929      selector: "[formGroupName]",
36930      providers: [formGroupNameProvider],
36931      standalone: false
36932    }]
36933  }], () => [{
36934    type: ControlContainer,
36935    decorators: [{
36936      type: Optional
36937    }, {
36938      type: Host
36939    }, {
36940      type: SkipSelf
36941    }]
36942  }, {
36943    type: void 0,
36944    decorators: [{
36945      type: Optional
36946    }, {
36947      type: Self
36948    }, {
36949      type: Inject,
36950      args: [NG_VALIDATORS]
36951    }]
36952  }, {
36953    type: void 0,
36954    decorators: [{
36955      type: Optional
36956    }, {
36957      type: Self
36958    }, {
36959      type: Inject,
36960      args: [NG_ASYNC_VALIDATORS]
36961    }]
36962  }], {
36963    name: [{
36964      type: Input,
36965      args: ["formGroupName"]
36966    }]
36967  });
36968})();
36969var formArrayNameProvider = {
36970  provide: ControlContainer,
36971  useExisting: forwardRef(() => FormArrayName)
36972};
36973var FormArrayName = class _FormArrayName extends ControlContainer {
36974  /** @internal */
36975  _parent;
36976  /**
36977   * @description
36978   * Tracks the name of the `FormArray` bound to the directive. The name corresponds
36979   * to a key in the parent `FormGroup` or `FormArray`.
36980   * Accepts a name as a string or a number.
36981   * The name in the form of a string is useful for individual forms,
36982   * while the numerical form allows for form arrays to be bound
36983   * to indices when iterating over arrays in a `FormArray`.
36984   */
36985  name = null;
36986  constructor(parent, validators, asyncValidators) {
36987    super();
36988    this._parent = parent;
36989    this._setValidators(validators);
36990    this._setAsyncValidators(asyncValidators);
36991  }
36992  /**
36993   * A lifecycle method called when the directive's inputs are initialized. For internal use only.
36994   * @throws If the directive does not have a valid parent.
36995   * @nodoc
36996   */
36997  ngOnInit() {
36998    if (hasInvalidParent(this._parent) && (typeof ngDevMode === "undefined" || ngDevMode)) {
36999      throw arrayParentException();
37000    }
37001    this.formDirective.addFormArray(this);
37002  }
37003  /**
37004   * A lifecycle method called before the directive's instance is destroyed. For internal use only.
37005   * @nodoc
37006   */
37007  ngOnDestroy() {
37008    this.formDirective?.removeFormArray(this);
37009  }
37010  /**
37011   * @description
37012   * The `FormArray` bound to this directive.
37013   */
37014  get control() {
37015    return this.formDirective.getFormArray(this);
37016  }
37017  /**
37018   * @description
37019   * The top-level directive for this group if present, otherwise null.
37020   */
37021  get formDirective() {
37022    return this._parent ? this._parent.formDirective : null;
37023  }
37024  /**
37025   * @description
37026   * Returns an array that represents the path from the top-level form to this control.
37027   * Each index is the string name of the control on that level.
37028   */
37029  get path() {
37030    return controlPath(this.name == null ? this.name : this.name.toString(), this._parent);
37031  }
37032  static \u0275fac = function FormArrayName_Factory(__ngFactoryType__) {
37033    return new (__ngFactoryType__ || _FormArrayName)(\u0275\u0275directiveInject(ControlContainer, 13), \u0275\u0275directiveInject(NG_VALIDATORS, 10), \u0275\u0275directiveInject(NG_ASYNC_VALIDATORS, 10));
37034  };
37035  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
37036    type: _FormArrayName,
37037    selectors: [["", "formArrayName", ""]],
37038    inputs: {
37039      name: [0, "formArrayName", "name"]
37040    },
37041    standalone: false,
37042    features: [\u0275\u0275ProvidersFeature([formArrayNameProvider]), \u0275\u0275InheritDefinitionFeature]
37043  });
37044};
37045(() => {
37046  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(FormArrayName, [{
37047    type: Directive,
37048    args: [{
37049      selector: "[formArrayName]",
37050      providers: [formArrayNameProvider],
37051      standalone: false
37052    }]
37053  }], () => [{
37054    type: ControlContainer,
37055    decorators: [{
37056      type: Optional
37057    }, {
37058      type: Host
37059    }, {
37060      type: SkipSelf
37061    }]
37062  }, {
37063    type: void 0,
37064    decorators: [{
37065      type: Optional
37066    }, {
37067      type: Self
37068    }, {
37069      type: Inject,
37070      args: [NG_VALIDATORS]
37071    }]
37072  }, {
37073    type: void 0,
37074    decorators: [{
37075      type: Optional
37076    }, {
37077      type: Self
37078    }, {
37079      type: Inject,
37080      args: [NG_ASYNC_VALIDATORS]
37081    }]
37082  }], {
37083    name: [{
37084      type: Input,
37085      args: ["formArrayName"]
37086    }]
37087  });
37088})();
37089function hasInvalidParent(parent) {
37090  return !(parent instanceof FormGroupName) && !(parent instanceof FormGroupDirective) && !(parent instanceof FormArrayName);
37091}
37092var controlNameBinding = {
37093  provide: NgControl,
37094  useExisting: forwardRef(() => FormControlName)
37095};
37096var FormControlName = class _FormControlName extends NgControl {
37097  _ngModelWarningConfig;
37098  _added = false;
37099  /**
37100   * Internal reference to the view model value.
37101   * @internal
37102   */
37103  viewModel;
37104  /**
37105   * @description
37106   * Tracks the `FormControl` instance bound to the directive.
37107   */
37108  // TODO(issue/24571): remove '!'.
37109  control;
37110  /**
37111   * @description
37112   * Tracks the name of the `FormControl` bound to the directive. The name corresponds
37113   * to a key in the parent `FormGroup` or `FormArray`.
37114   * Accepts a name as a string or a number.
37115   * The name in the form of a string is useful for individual forms,
37116   * while the numerical form allows for form controls to be bound
37117   * to indices when iterating over controls in a `FormArray`.
37118   */
37119  name = null;
37120  /**
37121   * @description
37122   * Triggers a warning in dev mode that this input should not be used with reactive forms.
37123   */
37124  set isDisabled(isDisabled) {
37125    if (typeof ngDevMode === "undefined" || ngDevMode) {
37126      console.warn(disabledAttrWarning);
37127    }
37128  }
37129  // TODO(kara): remove next 4 properties once deprecation period is over
37130  /** @deprecated as of v6 */
37131  model;
37132  /** @deprecated as of v6 */
37133  update = new EventEmitter();
37134  /**
37135   * @description
37136   * Static property used to track whether any ngModel warnings have been sent across
37137   * all instances of FormControlName. Used to support warning config of "once".
37138   *
37139   * @internal
37140   */
37141  static _ngModelWarningSentOnce = false;
37142  /**
37143   * @description
37144   * Instance property used to track whether an ngModel warning has been sent out for this
37145   * particular FormControlName instance. Used to support warning config of "always".
37146   *
37147   * @internal
37148   */
37149  _ngModelWarningSent = false;
37150  constructor(parent, validators, asyncValidators, valueAccessors, _ngModelWarningConfig) {
37151    super();
37152    this._ngModelWarningConfig = _ngModelWarningConfig;
37153    this._parent = parent;
37154    this._setValidators(validators);
37155    this._setAsyncValidators(asyncValidators);
37156    this.valueAccessor = selectValueAccessor(this, valueAccessors);
37157  }
37158  /** @nodoc */
37159  ngOnChanges(changes) {
37160    if (!this._added) this._setUpControl();
37161    if (isPropertyUpdated(changes, this.viewModel)) {
37162      if (typeof ngDevMode === "undefined" || ngDevMode) {
37163        _ngModelWarning("formControlName", _FormControlName, this, this._ngModelWarningConfig);
37164      }
37165      this.viewModel = this.model;
37166      this.formDirective.updateModel(this, this.model);
37167    }
37168  }
37169  /** @nodoc */
37170  ngOnDestroy() {
37171    if (this.formDirective) {
37172      this.formDirective.removeControl(this);
37173    }
37174  }
37175  /**
37176   * @description
37177   * Sets the new value for the view model and emits an `ngModelChange` event.
37178   *
37179   * @param newValue The new value for the view model.
37180   */
37181  viewToModelUpdate(newValue) {
37182    this.viewModel = newValue;
37183    this.update.emit(newValue);
37184  }
37185  /**
37186   * @description
37187   * Returns an array that represents the path from the top-level form to this control.
37188   * Each index is the string name of the control on that level.
37189   */
37190  get path() {
37191    return controlPath(this.name == null ? this.name : this.name.toString(), this._parent);
37192  }
37193  /**
37194   * @description
37195   * The top-level directive for this group if present, otherwise null.
37196   */
37197  get formDirective() {
37198    return this._parent ? this._parent.formDirective : null;
37199  }
37200  _setUpControl() {
37201    if (typeof ngDevMode === "undefined" || ngDevMode) {
37202      checkParentType(this._parent, this.name);
37203    }
37204    this.control = this.formDirective.addControl(this);
37205    this._added = true;
37206  }
37207  static \u0275fac = function FormControlName_Factory(__ngFactoryType__) {
37208    return new (__ngFactoryType__ || _FormControlName)(\u0275\u0275directiveInject(ControlContainer, 13), \u0275\u0275directiveInject(NG_VALIDATORS, 10), \u0275\u0275directiveInject(NG_ASYNC_VALIDATORS, 10), \u0275\u0275directiveInject(NG_VALUE_ACCESSOR, 10), \u0275\u0275directiveInject(NG_MODEL_WITH_FORM_CONTROL_WARNING, 8));
37209  };
37210  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
37211    type: _FormControlName,
37212    selectors: [["", "formControlName", ""]],
37213    inputs: {
37214      name: [0, "formControlName", "name"],
37215      isDisabled: [0, "disabled", "isDisabled"],
37216      model: [0, "ngModel", "model"]
37217    },
37218    outputs: {
37219      update: "ngModelChange"
37220    },
37221    standalone: false,
37222    features: [\u0275\u0275ProvidersFeature([controlNameBinding]), \u0275\u0275InheritDefinitionFeature, \u0275\u0275NgOnChangesFeature]
37223  });
37224};
37225(() => {
37226  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(FormControlName, [{
37227    type: Directive,
37228    args: [{
37229      selector: "[formControlName]",
37230      providers: [controlNameBinding],
37231      standalone: false
37232    }]
37233  }], () => [{
37234    type: ControlContainer,
37235    decorators: [{
37236      type: Optional
37237    }, {
37238      type: Host
37239    }, {
37240      type: SkipSelf
37241    }]
37242  }, {
37243    type: void 0,
37244    decorators: [{
37245      type: Optional
37246    }, {
37247      type: Self
37248    }, {
37249      type: Inject,
37250      args: [NG_VALIDATORS]
37251    }]
37252  }, {
37253    type: void 0,
37254    decorators: [{
37255      type: Optional
37256    }, {
37257      type: Self
37258    }, {
37259      type: Inject,
37260      args: [NG_ASYNC_VALIDATORS]
37261    }]
37262  }, {
37263    type: void 0,
37264    decorators: [{
37265      type: Optional
37266    }, {
37267      type: Self
37268    }, {
37269      type: Inject,
37270      args: [NG_VALUE_ACCESSOR]
37271    }]
37272  }, {
37273    type: void 0,
37274    decorators: [{
37275      type: Optional
37276    }, {
37277      type: Inject,
37278      args: [NG_MODEL_WITH_FORM_CONTROL_WARNING]
37279    }]
37280  }], {
37281    name: [{
37282      type: Input,
37283      args: ["formControlName"]
37284    }],
37285    isDisabled: [{
37286      type: Input,
37287      args: ["disabled"]
37288    }],
37289    model: [{
37290      type: Input,
37291      args: ["ngModel"]
37292    }],
37293    update: [{
37294      type: Output,
37295      args: ["ngModelChange"]
37296    }]
37297  });
37298})();
37299function checkParentType(parent, name) {
37300  if (!(parent instanceof FormGroupName) && parent instanceof AbstractFormGroupDirective) {
37301    throw ngModelGroupException();
37302  } else if (!(parent instanceof FormGroupName) && !(parent instanceof FormGroupDirective) && !(parent instanceof FormArrayName)) {
37303    throw controlParentException(name);
37304  }
37305}
37306var SELECT_VALUE_ACCESSOR = {
37307  provide: NG_VALUE_ACCESSOR,
37308  useExisting: forwardRef(() => SelectControlValueAccessor),
37309  multi: true
37310};
37311function _buildValueString$1(id, value) {
37312  if (id == null) return `${value}`;
37313  if (value && typeof value === "object") value = "Object";
37314  return `${id}: ${value}`.slice(0, 50);
37315}
37316function _extractId$1(valueString) {
37317  return valueString.split(":")[0];
37318}
37319var SelectControlValueAccessor = class _SelectControlValueAccessor extends BuiltInControlValueAccessor {
37320  /** @nodoc */
37321  value;
37322  /** @internal */
37323  _optionMap = /* @__PURE__ */ new Map();
37324  /** @internal */
37325  _idCounter = 0;
37326  /**
37327   * @description
37328   * Tracks the option comparison algorithm for tracking identities when
37329   * checking for changes.
37330   */
37331  set compareWith(fn) {
37332    if (typeof fn !== "function" && (typeof ngDevMode === "undefined" || ngDevMode)) {
37333      throw new RuntimeError(1201, `compareWith must be a function, but received ${JSON.stringify(fn)}`);
37334    }
37335    this._compareWith = fn;
37336  }
37337  _compareWith = Object.is;
37338  /**
37339   * Sets the "value" property on the select element.
37340   * @nodoc
37341   */
37342  writeValue(value) {
37343    this.value = value;
37344    const id = this._getOptionId(value);
37345    const valueString = _buildValueString$1(id, value);
37346    this.setProperty("value", valueString);
37347  }
37348  /**
37349   * Registers a function called when the control value changes.
37350   * @nodoc
37351   */
37352  registerOnChange(fn) {
37353    this.onChange = (valueString) => {
37354      this.value = this._getOptionValue(valueString);
37355      fn(this.value);
37356    };
37357  }
37358  /** @internal */
37359  _registerOption() {
37360    return (this._idCounter++).toString();
37361  }
37362  /** @internal */
37363  _getOptionId(value) {
37364    for (const id of this._optionMap.keys()) {
37365      if (this._compareWith(this._optionMap.get(id), value)) return id;
37366    }
37367    return null;
37368  }
37369  /** @internal */
37370  _getOptionValue(valueString) {
37371    const id = _extractId$1(valueString);
37372    return this._optionMap.has(id) ? this._optionMap.get(id) : valueString;
37373  }
37374  static \u0275fac = /* @__PURE__ */ (() => {
37375    let \u0275SelectControlValueAccessor_BaseFactory;
37376    return function SelectControlValueAccessor_Factory(__ngFactoryType__) {
37377      return (\u0275SelectControlValueAccessor_BaseFactory || (\u0275SelectControlValueAccessor_BaseFactory = \u0275\u0275getInheritedFactory(_SelectControlValueAccessor)))(__ngFactoryType__ || _SelectControlValueAccessor);
37378    };
37379  })();
37380  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
37381    type: _SelectControlValueAccessor,
37382    selectors: [["select", "formControlName", "", 3, "multiple", ""], ["select", "formControl", "", 3, "multiple", ""], ["select", "ngModel", "", 3, "multiple", ""]],
37383    hostBindings: function SelectControlValueAccessor_HostBindings(rf, ctx) {
37384      if (rf & 1) {
37385        \u0275\u0275listener("change", function SelectControlValueAccessor_change_HostBindingHandler($event) {
37386          return ctx.onChange($event.target.value);
37387        })("blur", function SelectControlValueAccessor_blur_HostBindingHandler() {
37388          return ctx.onTouched();
37389        });
37390      }
37391    },
37392    inputs: {
37393      compareWith: "compareWith"
37394    },
37395    standalone: false,
37396    features: [\u0275\u0275ProvidersFeature([SELECT_VALUE_ACCESSOR]), \u0275\u0275InheritDefinitionFeature]
37397  });
37398};
37399(() => {
37400  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(SelectControlValueAccessor, [{
37401    type: Directive,
37402    args: [{
37403      selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]",
37404      host: {
37405        "(change)": "onChange($event.target.value)",
37406        "(blur)": "onTouched()"
37407      },
37408      providers: [SELECT_VALUE_ACCESSOR],
37409      standalone: false
37410    }]
37411  }], null, {
37412    compareWith: [{
37413      type: Input
37414    }]
37415  });
37416})();
37417var NgSelectOption = class _NgSelectOption {
37418  _element;
37419  _renderer;
37420  _select;
37421  /**
37422   * @description
37423   * ID of the option element
37424   */
37425  // TODO(issue/24571): remove '!'.
37426  id;
37427  constructor(_element, _renderer, _select) {
37428    this._element = _element;
37429    this._renderer = _renderer;
37430    this._select = _select;
37431    if (this._select) this.id = this._select._registerOption();
37432  }
37433  /**
37434   * @description
37435   * Tracks the value bound to the option element. Unlike the value binding,
37436   * ngValue supports binding to objects.
37437   */
37438  set ngValue(value) {
37439    if (this._select == null) return;
37440    this._select._optionMap.set(this.id, value);
37441    this._setElementValue(_buildValueString$1(this.id, value));
37442    this._select.writeValue(this._select.value);
37443  }
37444  /**
37445   * @description
37446   * Tracks simple string values bound to the option element.
37447   * For objects, use the `ngValue` input binding.
37448   */
37449  set value(value) {
37450    this._setElementValue(value);
37451    if (this._select) this._select.writeValue(this._select.value);
37452  }
37453  /** @internal */
37454  _setElementValue(value) {
37455    this._renderer.setProperty(this._element.nativeElement, "value", value);
37456  }
37457  /** @nodoc */
37458  ngOnDestroy() {
37459    if (this._select) {
37460      this._select._optionMap.delete(this.id);
37461      this._select.writeValue(this._select.value);
37462    }
37463  }
37464  static \u0275fac = function NgSelectOption_Factory(__ngFactoryType__) {
37465    return new (__ngFactoryType__ || _NgSelectOption)(\u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(Renderer2), \u0275\u0275directiveInject(SelectControlValueAccessor, 9));
37466  };
37467  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
37468    type: _NgSelectOption,
37469    selectors: [["option"]],
37470    inputs: {
37471      ngValue: "ngValue",
37472      value: "value"
37473    },
37474    standalone: false
37475  });
37476};
37477(() => {
37478  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgSelectOption, [{
37479    type: Directive,
37480    args: [{
37481      selector: "option",
37482      standalone: false
37483    }]
37484  }], () => [{
37485    type: ElementRef
37486  }, {
37487    type: Renderer2
37488  }, {
37489    type: SelectControlValueAccessor,
37490    decorators: [{
37491      type: Optional
37492    }, {
37493      type: Host
37494    }]
37495  }], {
37496    ngValue: [{
37497      type: Input,
37498      args: ["ngValue"]
37499    }],
37500    value: [{
37501      type: Input,
37502      args: ["value"]
37503    }]
37504  });
37505})();
37506var SELECT_MULTIPLE_VALUE_ACCESSOR = {
37507  provide: NG_VALUE_ACCESSOR,
37508  useExisting: forwardRef(() => SelectMultipleControlValueAccessor),
37509  multi: true
37510};
37511function _buildValueString(id, value) {
37512  if (id == null) return `${value}`;
37513  if (typeof value === "string") value = `'${value}'`;
37514  if (value && typeof value === "object") value = "Object";
37515  return `${id}: ${value}`.slice(0, 50);
37516}
37517function _extractId(valueString) {
37518  return valueString.split(":")[0];
37519}
37520var SelectMultipleControlValueAccessor = class _SelectMultipleControlValueAccessor extends BuiltInControlValueAccessor {
37521  /**
37522   * The current value.
37523   * @nodoc
37524   */
37525  value;
37526  /** @internal */
37527  _optionMap = /* @__PURE__ */ new Map();
37528  /** @internal */
37529  _idCounter = 0;
37530  /**
37531   * @description
37532   * Tracks the option comparison algorithm for tracking identities when
37533   * checking for changes.
37534   */
37535  set compareWith(fn) {
37536    if (typeof fn !== "function" && (typeof ngDevMode === "undefined" || ngDevMode)) {
37537      throw new RuntimeError(1201, `compareWith must be a function, but received ${JSON.stringify(fn)}`);
37538    }
37539    this._compareWith = fn;
37540  }
37541  _compareWith = Object.is;
37542  /**
37543   * Sets the "value" property on one or of more of the select's options.
37544   * @nodoc
37545   */
37546  writeValue(value) {
37547    this.value = value;
37548    let optionSelectedStateSetter;
37549    if (Array.isArray(value)) {
37550      const ids = value.map((v) => this._getOptionId(v));
37551      optionSelectedStateSetter = (opt, o) => {
37552        opt._setSelected(ids.indexOf(o.toString()) > -1);
37553      };
37554    } else {
37555      optionSelectedStateSetter = (opt, o) => {
37556        opt._setSelected(false);
37557      };
37558    }
37559    this._optionMap.forEach(optionSelectedStateSetter);
37560  }
37561  /**
37562   * Registers a function called when the control value changes
37563   * and writes an array of the selected options.
37564   * @nodoc
37565   */
37566  registerOnChange(fn) {
37567    this.onChange = (element) => {
37568      const selected = [];
37569      const selectedOptions = element.selectedOptions;
37570      if (selectedOptions !== void 0) {
37571        const options2 = selectedOptions;
37572        for (let i = 0; i < options2.length; i++) {
37573          const opt = options2[i];
37574          const val = this._getOptionValue(opt.value);
37575          selected.push(val);
37576        }
37577      } else {
37578        const options2 = element.options;
37579        for (let i = 0; i < options2.length; i++) {
37580          const opt = options2[i];
37581          if (opt.selected) {
37582            const val = this._getOptionValue(opt.value);
37583            selected.push(val);
37584          }
37585        }
37586      }
37587      this.value = selected;
37588      fn(selected);
37589    };
37590  }
37591  /** @internal */
37592  _registerOption(value) {
37593    const id = (this._idCounter++).toString();
37594    this._optionMap.set(id, value);
37595    return id;
37596  }
37597  /** @internal */
37598  _getOptionId(value) {
37599    for (const id of this._optionMap.keys()) {
37600      if (this._compareWith(this._optionMap.get(id)._value, value)) return id;
37601    }
37602    return null;
37603  }
37604  /** @internal */
37605  _getOptionValue(valueString) {
37606    const id = _extractId(valueString);
37607    return this._optionMap.has(id) ? this._optionMap.get(id)._value : valueString;
37608  }
37609  static \u0275fac = /* @__PURE__ */ (() => {
37610    let \u0275SelectMultipleControlValueAccessor_BaseFactory;
37611    return function SelectMultipleControlValueAccessor_Factory(__ngFactoryType__) {
37612      return (\u0275SelectMultipleControlValueAccessor_BaseFactory || (\u0275SelectMultipleControlValueAccessor_BaseFactory = \u0275\u0275getInheritedFactory(_SelectMultipleControlValueAccessor)))(__ngFactoryType__ || _SelectMultipleControlValueAccessor);
37613    };
37614  })();
37615  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
37616    type: _SelectMultipleControlValueAccessor,
37617    selectors: [["select", "multiple", "", "formControlName", ""], ["select", "multiple", "", "formControl", ""], ["select", "multiple", "", "ngModel", ""]],
37618    hostBindings: function SelectMultipleControlValueAccessor_HostBindings(rf, ctx) {
37619      if (rf & 1) {
37620        \u0275\u0275listener("change", function SelectMultipleControlValueAccessor_change_HostBindingHandler($event) {
37621          return ctx.onChange($event.target);
37622        })("blur", function SelectMultipleControlValueAccessor_blur_HostBindingHandler() {
37623          return ctx.onTouched();
37624        });
37625      }
37626    },
37627    inputs: {
37628      compareWith: "compareWith"
37629    },
37630    standalone: false,
37631    features: [\u0275\u0275ProvidersFeature([SELECT_MULTIPLE_VALUE_ACCESSOR]), \u0275\u0275InheritDefinitionFeature]
37632  });
37633};
37634(() => {
37635  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(SelectMultipleControlValueAccessor, [{
37636    type: Directive,
37637    args: [{
37638      selector: "select[multiple][formControlName],select[multiple][formControl],select[multiple][ngModel]",
37639      host: {
37640        "(change)": "onChange($event.target)",
37641        "(blur)": "onTouched()"
37642      },
37643      providers: [SELECT_MULTIPLE_VALUE_ACCESSOR],
37644      standalone: false
37645    }]
37646  }], null, {
37647    compareWith: [{
37648      type: Input
37649    }]
37650  });
37651})();
37652var \u0275NgSelectMultipleOption = class _\u0275NgSelectMultipleOption {
37653  _element;
37654  _renderer;
37655  _select;
37656  // TODO(issue/24571): remove '!'.
37657  id;
37658  /** @internal */
37659  _value;
37660  constructor(_element, _renderer, _select) {
37661    this._element = _element;
37662    this._renderer = _renderer;
37663    this._select = _select;
37664    if (this._select) {
37665      this.id = this._select._registerOption(this);
37666    }
37667  }
37668  /**
37669   * @description
37670   * Tracks the value bound to the option element. Unlike the value binding,
37671   * ngValue supports binding to objects.
37672   */
37673  set ngValue(value) {
37674    if (this._select == null) return;
37675    this._value = value;
37676    this._setElementValue(_buildValueString(this.id, value));
37677    this._select.writeValue(this._select.value);
37678  }
37679  /**
37680   * @description
37681   * Tracks simple string values bound to the option element.
37682   * For objects, use the `ngValue` input binding.
37683   */
37684  set value(value) {
37685    if (this._select) {
37686      this._value = value;
37687      this._setElementValue(_buildValueString(this.id, value));
37688      this._select.writeValue(this._select.value);
37689    } else {
37690      this._setElementValue(value);
37691    }
37692  }
37693  /** @internal */
37694  _setElementValue(value) {
37695    this._renderer.setProperty(this._element.nativeElement, "value", value);
37696  }
37697  /** @internal */
37698  _setSelected(selected) {
37699    this._renderer.setProperty(this._element.nativeElement, "selected", selected);
37700  }
37701  /** @nodoc */
37702  ngOnDestroy() {
37703    if (this._select) {
37704      this._select._optionMap.delete(this.id);
37705      this._select.writeValue(this._select.value);
37706    }
37707  }
37708  static \u0275fac = function \u0275NgSelectMultipleOption_Factory(__ngFactoryType__) {
37709    return new (__ngFactoryType__ || _\u0275NgSelectMultipleOption)(\u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(Renderer2), \u0275\u0275directiveInject(SelectMultipleControlValueAccessor, 9));
37710  };
37711  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
37712    type: _\u0275NgSelectMultipleOption,
37713    selectors: [["option"]],
37714    inputs: {
37715      ngValue: "ngValue",
37716      value: "value"
37717    },
37718    standalone: false
37719  });
37720};
37721(() => {
37722  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(\u0275NgSelectMultipleOption, [{
37723    type: Directive,
37724    args: [{
37725      selector: "option",
37726      standalone: false
37727    }]
37728  }], () => [{
37729    type: ElementRef
37730  }, {
37731    type: Renderer2
37732  }, {
37733    type: SelectMultipleControlValueAccessor,
37734    decorators: [{
37735      type: Optional
37736    }, {
37737      type: Host
37738    }]
37739  }], {
37740    ngValue: [{
37741      type: Input,
37742      args: ["ngValue"]
37743    }],
37744    value: [{
37745      type: Input,
37746      args: ["value"]
37747    }]
37748  });
37749})();
37750function toInteger(value) {
37751  return typeof value === "number" ? value : parseInt(value, 10);
37752}
37753function toFloat(value) {
37754  return typeof value === "number" ? value : parseFloat(value);
37755}
37756var AbstractValidatorDirective = class _AbstractValidatorDirective {
37757  _validator = nullValidator;
37758  _onChange;
37759  /**
37760   * A flag that tracks whether this validator is enabled.
37761   *
37762   * Marking it `internal` (vs `protected`), so that this flag can be used in host bindings of
37763   * directive classes that extend this base class.
37764   * @internal
37765   */
37766  _enabled;
37767  /** @nodoc */
37768  ngOnChanges(changes) {
37769    if (this.inputName in changes) {
37770      const input2 = this.normalizeInput(changes[this.inputName].currentValue);
37771      this._enabled = this.enabled(input2);
37772      this._validator = this._enabled ? this.createValidator(input2) : nullValidator;
37773      if (this._onChange) {
37774        this._onChange();
37775      }
37776    }
37777  }
37778  /** @nodoc */
37779  validate(control) {
37780    return this._validator(control);
37781  }
37782  /** @nodoc */
37783  registerOnValidatorChange(fn) {
37784    this._onChange = fn;
37785  }
37786  /**
37787   * @description
37788   * Determines whether this validator should be active or not based on an input.
37789   * Base class implementation checks whether an input is defined (if the value is different from
37790   * `null` and `undefined`). Validator classes that extend this base class can override this
37791   * function with the logic specific to a particular validator directive.
37792   */
37793  enabled(input2) {
37794    return input2 != null;
37795  }
37796  static \u0275fac = function AbstractValidatorDirective_Factory(__ngFactoryType__) {
37797    return new (__ngFactoryType__ || _AbstractValidatorDirective)();
37798  };
37799  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
37800    type: _AbstractValidatorDirective,
37801    features: [\u0275\u0275NgOnChangesFeature]
37802  });
37803};
37804(() => {
37805  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(AbstractValidatorDirective, [{
37806    type: Directive
37807  }], null, null);
37808})();
37809var MAX_VALIDATOR = {
37810  provide: NG_VALIDATORS,
37811  useExisting: forwardRef(() => MaxValidator),
37812  multi: true
37813};
37814var MaxValidator = class _MaxValidator extends AbstractValidatorDirective {
37815  /**
37816   * @description
37817   * Tracks changes to the max bound to this directive.
37818   */
37819  max;
37820  /** @internal */
37821  inputName = "max";
37822  /** @internal */
37823  normalizeInput = (input2) => toFloat(input2);
37824  /** @internal */
37825  createValidator = (max) => maxValidator(max);
37826  static \u0275fac = /* @__PURE__ */ (() => {
37827    let \u0275MaxValidator_BaseFactory;
37828    return function MaxValidator_Factory(__ngFactoryType__) {
37829      return (\u0275MaxValidator_BaseFactory || (\u0275MaxValidator_BaseFactory = \u0275\u0275getInheritedFactory(_MaxValidator)))(__ngFactoryType__ || _MaxValidator);
37830    };
37831  })();
37832  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
37833    type: _MaxValidator,
37834    selectors: [["input", "type", "number", "max", "", "formControlName", ""], ["input", "type", "number", "max", "", "formControl", ""], ["input", "type", "number", "max", "", "ngModel", ""]],
37835    hostVars: 1,
37836    hostBindings: function MaxValidator_HostBindings(rf, ctx) {
37837      if (rf & 2) {
37838        \u0275\u0275attribute("max", ctx._enabled ? ctx.max : null);
37839      }
37840    },
37841    inputs: {
37842      max: "max"
37843    },
37844    standalone: false,
37845    features: [\u0275\u0275ProvidersFeature([MAX_VALIDATOR]), \u0275\u0275InheritDefinitionFeature]
37846  });
37847};
37848(() => {
37849  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(MaxValidator, [{
37850    type: Directive,
37851    args: [{
37852      selector: "input[type=number][max][formControlName],input[type=number][max][formControl],input[type=number][max][ngModel]",
37853      providers: [MAX_VALIDATOR],
37854      host: {
37855        "[attr.max]": "_enabled ? max : null"
37856      },
37857      standalone: false
37858    }]
37859  }], null, {
37860    max: [{
37861      type: Input
37862    }]
37863  });
37864})();
37865var MIN_VALIDATOR = {
37866  provide: NG_VALIDATORS,
37867  useExisting: forwardRef(() => MinValidator),
37868  multi: true
37869};
37870var MinValidator = class _MinValidator extends AbstractValidatorDirective {
37871  /**
37872   * @description
37873   * Tracks changes to the min bound to this directive.
37874   */
37875  min;
37876  /** @internal */
37877  inputName = "min";
37878  /** @internal */
37879  normalizeInput = (input2) => toFloat(input2);
37880  /** @internal */
37881  createValidator = (min) => minValidator(min);
37882  static \u0275fac = /* @__PURE__ */ (() => {
37883    let \u0275MinValidator_BaseFactory;
37884    return function MinValidator_Factory(__ngFactoryType__) {
37885      return (\u0275MinValidator_BaseFactory || (\u0275MinValidator_BaseFactory = \u0275\u0275getInheritedFactory(_MinValidator)))(__ngFactoryType__ || _MinValidator);
37886    };
37887  })();
37888  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
37889    type: _MinValidator,
37890    selectors: [["input", "type", "number", "min", "", "formControlName", ""], ["input", "type", "number", "min", "", "formControl", ""], ["input", "type", "number", "min", "", "ngModel", ""]],
37891    hostVars: 1,
37892    hostBindings: function MinValidator_HostBindings(rf, ctx) {
37893      if (rf & 2) {
37894        \u0275\u0275attribute("min", ctx._enabled ? ctx.min : null);
37895      }
37896    },
37897    inputs: {
37898      min: "min"
37899    },
37900    standalone: false,
37901    features: [\u0275\u0275ProvidersFeature([MIN_VALIDATOR]), \u0275\u0275InheritDefinitionFeature]
37902  });
37903};
37904(() => {
37905  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(MinValidator, [{
37906    type: Directive,
37907    args: [{
37908      selector: "input[type=number][min][formControlName],input[type=number][min][formControl],input[type=number][min][ngModel]",
37909      providers: [MIN_VALIDATOR],
37910      host: {
37911        "[attr.min]": "_enabled ? min : null"
37912      },
37913      standalone: false
37914    }]
37915  }], null, {
37916    min: [{
37917      type: Input
37918    }]
37919  });
37920})();
37921var REQUIRED_VALIDATOR = {
37922  provide: NG_VALIDATORS,
37923  useExisting: forwardRef(() => RequiredValidator),
37924  multi: true
37925};
37926var CHECKBOX_REQUIRED_VALIDATOR = {
37927  provide: NG_VALIDATORS,
37928  useExisting: forwardRef(() => CheckboxRequiredValidator),
37929  multi: true
37930};
37931var RequiredValidator = class _RequiredValidator extends AbstractValidatorDirective {
37932  /**
37933   * @description
37934   * Tracks changes to the required attribute bound to this directive.
37935   */
37936  required;
37937  /** @internal */
37938  inputName = "required";
37939  /** @internal */
37940  normalizeInput = booleanAttribute;
37941  /** @internal */
37942  createValidator = (input2) => requiredValidator;
37943  /** @nodoc */
37944  enabled(input2) {
37945    return input2;
37946  }
37947  static \u0275fac = /* @__PURE__ */ (() => {
37948    let \u0275RequiredValidator_BaseFactory;
37949    return function RequiredValidator_Factory(__ngFactoryType__) {
37950      return (\u0275RequiredValidator_BaseFactory || (\u0275RequiredValidator_BaseFactory = \u0275\u0275getInheritedFactory(_RequiredValidator)))(__ngFactoryType__ || _RequiredValidator);
37951    };
37952  })();
37953  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
37954    type: _RequiredValidator,
37955    selectors: [["", "required", "", "formControlName", "", 3, "type", "checkbox"], ["", "required", "", "formControl", "", 3, "type", "checkbox"], ["", "required", "", "ngModel", "", 3, "type", "checkbox"]],
37956    hostVars: 1,
37957    hostBindings: function RequiredValidator_HostBindings(rf, ctx) {
37958      if (rf & 2) {
37959        \u0275\u0275attribute("required", ctx._enabled ? "" : null);
37960      }
37961    },
37962    inputs: {
37963      required: "required"
37964    },
37965    standalone: false,
37966    features: [\u0275\u0275ProvidersFeature([REQUIRED_VALIDATOR]), \u0275\u0275InheritDefinitionFeature]
37967  });
37968};
37969(() => {
37970  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(RequiredValidator, [{
37971    type: Directive,
37972    args: [{
37973      selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]",
37974      providers: [REQUIRED_VALIDATOR],
37975      host: {
37976        "[attr.required]": '_enabled ? "" : null'
37977      },
37978      standalone: false
37979    }]
37980  }], null, {
37981    required: [{
37982      type: Input
37983    }]
37984  });
37985})();
37986var CheckboxRequiredValidator = class _CheckboxRequiredValidator extends RequiredValidator {
37987  /** @internal */
37988  createValidator = (input2) => requiredTrueValidator;
37989  static \u0275fac = /* @__PURE__ */ (() => {
37990    let \u0275CheckboxRequiredValidator_BaseFactory;
37991    return function CheckboxRequiredValidator_Factory(__ngFactoryType__) {
37992      return (\u0275CheckboxRequiredValidator_BaseFactory || (\u0275CheckboxRequiredValidator_BaseFactory = \u0275\u0275getInheritedFactory(_CheckboxRequiredValidator)))(__ngFactoryType__ || _CheckboxRequiredValidator);
37993    };
37994  })();
37995  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
37996    type: _CheckboxRequiredValidator,
37997    selectors: [["input", "type", "checkbox", "required", "", "formControlName", ""], ["input", "type", "checkbox", "required", "", "formControl", ""], ["input", "type", "checkbox", "required", "", "ngModel", ""]],
37998    hostVars: 1,
37999    hostBindings: function CheckboxRequiredValidator_HostBindings(rf, ctx) {
38000      if (rf & 2) {
38001        \u0275\u0275attribute("required", ctx._enabled ? "" : null);
38002      }
38003    },
38004    standalone: false,
38005    features: [\u0275\u0275ProvidersFeature([CHECKBOX_REQUIRED_VALIDATOR]), \u0275\u0275InheritDefinitionFeature]
38006  });
38007};
38008(() => {
38009  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(CheckboxRequiredValidator, [{
38010    type: Directive,
38011    args: [{
38012      selector: "input[type=checkbox][required][formControlName],input[type=checkbox][required][formControl],input[type=checkbox][required][ngModel]",
38013      providers: [CHECKBOX_REQUIRED_VALIDATOR],
38014      host: {
38015        "[attr.required]": '_enabled ? "" : null'
38016      },
38017      standalone: false
38018    }]
38019  }], null, null);
38020})();
38021var EMAIL_VALIDATOR = {
38022  provide: NG_VALIDATORS,
38023  useExisting: forwardRef(() => EmailValidator),
38024  multi: true
38025};
38026var EmailValidator = class _EmailValidator extends AbstractValidatorDirective {
38027  /**
38028   * @description
38029   * Tracks changes to the email attribute bound to this directive.
38030   */
38031  email;
38032  /** @internal */
38033  inputName = "email";
38034  /** @internal */
38035  normalizeInput = booleanAttribute;
38036  /** @internal */
38037  createValidator = (input2) => emailValidator;
38038  /** @nodoc */
38039  enabled(input2) {
38040    return input2;
38041  }
38042  static \u0275fac = /* @__PURE__ */ (() => {
38043    let \u0275EmailValidator_BaseFactory;
38044    return function EmailValidator_Factory(__ngFactoryType__) {
38045      return (\u0275EmailValidator_BaseFactory || (\u0275EmailValidator_BaseFactory = \u0275\u0275getInheritedFactory(_EmailValidator)))(__ngFactoryType__ || _EmailValidator);
38046    };
38047  })();
38048  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
38049    type: _EmailValidator,
38050    selectors: [["", "email", "", "formControlName", ""], ["", "email", "", "formControl", ""], ["", "email", "", "ngModel", ""]],
38051    inputs: {
38052      email: "email"
38053    },
38054    standalone: false,
38055    features: [\u0275\u0275ProvidersFeature([EMAIL_VALIDATOR]), \u0275\u0275InheritDefinitionFeature]
38056  });
38057};
38058(() => {
38059  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(EmailValidator, [{
38060    type: Directive,
38061    args: [{
38062      selector: "[email][formControlName],[email][formControl],[email][ngModel]",
38063      providers: [EMAIL_VALIDATOR],
38064      standalone: false
38065    }]
38066  }], null, {
38067    email: [{
38068      type: Input
38069    }]
38070  });
38071})();
38072var MIN_LENGTH_VALIDATOR = {
38073  provide: NG_VALIDATORS,
38074  useExisting: forwardRef(() => MinLengthValidator),
38075  multi: true
38076};
38077var MinLengthValidator = class _MinLengthValidator extends AbstractValidatorDirective {
38078  /**
38079   * @description
38080   * Tracks changes to the minimum length bound to this directive.
38081   */
38082  minlength;
38083  /** @internal */
38084  inputName = "minlength";
38085  /** @internal */
38086  normalizeInput = (input2) => toInteger(input2);
38087  /** @internal */
38088  createValidator = (minlength) => minLengthValidator(minlength);
38089  static \u0275fac = /* @__PURE__ */ (() => {
38090    let \u0275MinLengthValidator_BaseFactory;
38091    return function MinLengthValidator_Factory(__ngFactoryType__) {
38092      return (\u0275MinLengthValidator_BaseFactory || (\u0275MinLengthValidator_BaseFactory = \u0275\u0275getInheritedFactory(_MinLengthValidator)))(__ngFactoryType__ || _MinLengthValidator);
38093    };
38094  })();
38095  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
38096    type: _MinLengthValidator,
38097    selectors: [["", "minlength", "", "formControlName", ""], ["", "minlength", "", "formControl", ""], ["", "minlength", "", "ngModel", ""]],
38098    hostVars: 1,
38099    hostBindings: function MinLengthValidator_HostBindings(rf, ctx) {
38100      if (rf & 2) {
38101        \u0275\u0275attribute("minlength", ctx._enabled ? ctx.minlength : null);
38102      }
38103    },
38104    inputs: {
38105      minlength: "minlength"
38106    },
38107    standalone: false,
38108    features: [\u0275\u0275ProvidersFeature([MIN_LENGTH_VALIDATOR]), \u0275\u0275InheritDefinitionFeature]
38109  });
38110};
38111(() => {
38112  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(MinLengthValidator, [{
38113    type: Directive,
38114    args: [{
38115      selector: "[minlength][formControlName],[minlength][formControl],[minlength][ngModel]",
38116      providers: [MIN_LENGTH_VALIDATOR],
38117      host: {
38118        "[attr.minlength]": "_enabled ? minlength : null"
38119      },
38120      standalone: false
38121    }]
38122  }], null, {
38123    minlength: [{
38124      type: Input
38125    }]
38126  });
38127})();
38128var MAX_LENGTH_VALIDATOR = {
38129  provide: NG_VALIDATORS,
38130  useExisting: forwardRef(() => MaxLengthValidator),
38131  multi: true
38132};
38133var MaxLengthValidator = class _MaxLengthValidator extends AbstractValidatorDirective {
38134  /**
38135   * @description
38136   * Tracks changes to the maximum length bound to this directive.
38137   */
38138  maxlength;
38139  /** @internal */
38140  inputName = "maxlength";
38141  /** @internal */
38142  normalizeInput = (input2) => toInteger(input2);
38143  /** @internal */
38144  createValidator = (maxlength) => maxLengthValidator(maxlength);
38145  static \u0275fac = /* @__PURE__ */ (() => {
38146    let \u0275MaxLengthValidator_BaseFactory;
38147    return function MaxLengthValidator_Factory(__ngFactoryType__) {
38148      return (\u0275MaxLengthValidator_BaseFactory || (\u0275MaxLengthValidator_BaseFactory = \u0275\u0275getInheritedFactory(_MaxLengthValidator)))(__ngFactoryType__ || _MaxLengthValidator);
38149    };
38150  })();
38151  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
38152    type: _MaxLengthValidator,
38153    selectors: [["", "maxlength", "", "formControlName", ""], ["", "maxlength", "", "formControl", ""], ["", "maxlength", "", "ngModel", ""]],
38154    hostVars: 1,
38155    hostBindings: function MaxLengthValidator_HostBindings(rf, ctx) {
38156      if (rf & 2) {
38157        \u0275\u0275attribute("maxlength", ctx._enabled ? ctx.maxlength : null);
38158      }
38159    },
38160    inputs: {
38161      maxlength: "maxlength"
38162    },
38163    standalone: false,
38164    features: [\u0275\u0275ProvidersFeature([MAX_LENGTH_VALIDATOR]), \u0275\u0275InheritDefinitionFeature]
38165  });
38166};
38167(() => {
38168  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(MaxLengthValidator, [{
38169    type: Directive,
38170    args: [{
38171      selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]",
38172      providers: [MAX_LENGTH_VALIDATOR],
38173      host: {
38174        "[attr.maxlength]": "_enabled ? maxlength : null"
38175      },
38176      standalone: false
38177    }]
38178  }], null, {
38179    maxlength: [{
38180      type: Input
38181    }]
38182  });
38183})();
38184var PATTERN_VALIDATOR = {
38185  provide: NG_VALIDATORS,
38186  useExisting: forwardRef(() => PatternValidator),
38187  multi: true
38188};
38189var PatternValidator = class _PatternValidator extends AbstractValidatorDirective {
38190  /**
38191   * @description
38192   * Tracks changes to the pattern bound to this directive.
38193   */
38194  pattern;
38195  // This input is always defined, since the name matches selector.
38196  /** @internal */
38197  inputName = "pattern";
38198  /** @internal */
38199  normalizeInput = (input2) => input2;
38200  /** @internal */
38201  createValidator = (input2) => patternValidator(input2);
38202  static \u0275fac = /* @__PURE__ */ (() => {
38203    let \u0275PatternValidator_BaseFactory;
38204    return function PatternValidator_Factory(__ngFactoryType__) {
38205      return (\u0275PatternValidator_BaseFactory || (\u0275PatternValidator_BaseFactory = \u0275\u0275getInheritedFactory(_PatternValidator)))(__ngFactoryType__ || _PatternValidator);
38206    };
38207  })();
38208  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
38209    type: _PatternValidator,
38210    selectors: [["", "pattern", "", "formControlName", ""], ["", "pattern", "", "formControl", ""], ["", "pattern", "", "ngModel", ""]],
38211    hostVars: 1,
38212    hostBindings: function PatternValidator_HostBindings(rf, ctx) {
38213      if (rf & 2) {
38214        \u0275\u0275attribute("pattern", ctx._enabled ? ctx.pattern : null);
38215      }
38216    },
38217    inputs: {
38218      pattern: "pattern"
38219    },
38220    standalone: false,
38221    features: [\u0275\u0275ProvidersFeature([PATTERN_VALIDATOR]), \u0275\u0275InheritDefinitionFeature]
38222  });
38223};
38224(() => {
38225  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(PatternValidator, [{
38226    type: Directive,
38227    args: [{
38228      selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]",
38229      providers: [PATTERN_VALIDATOR],
38230      host: {
38231        "[attr.pattern]": "_enabled ? pattern : null"
38232      },
38233      standalone: false
38234    }]
38235  }], null, {
38236    pattern: [{
38237      type: Input
38238    }]
38239  });
38240})();
38241var SHARED_FORM_DIRECTIVES = [\u0275NgNoValidate, NgSelectOption, \u0275NgSelectMultipleOption, DefaultValueAccessor, NumberValueAccessor, RangeValueAccessor, CheckboxControlValueAccessor, SelectControlValueAccessor, SelectMultipleControlValueAccessor, RadioControlValueAccessor, NgControlStatus, NgControlStatusGroup, RequiredValidator, MinLengthValidator, MaxLengthValidator, PatternValidator, CheckboxRequiredValidator, EmailValidator, MinValidator, MaxValidator];
38242var TEMPLATE_DRIVEN_DIRECTIVES = [NgModel, NgModelGroup, NgForm];
38243var REACTIVE_DRIVEN_DIRECTIVES = [FormControlDirective, FormGroupDirective, FormControlName, FormGroupName, FormArrayName];
38244var \u0275InternalFormsSharedModule = class _\u0275InternalFormsSharedModule {
38245  static \u0275fac = function \u0275InternalFormsSharedModule_Factory(__ngFactoryType__) {
38246    return new (__ngFactoryType__ || _\u0275InternalFormsSharedModule)();
38247  };
38248  static \u0275mod = /* @__PURE__ */ \u0275\u0275defineNgModule({
38249    type: _\u0275InternalFormsSharedModule
38250  });
38251  static \u0275inj = /* @__PURE__ */ \u0275\u0275defineInjector({});
38252};
38253(() => {
38254  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(\u0275InternalFormsSharedModule, [{
38255    type: NgModule,
38256    args: [{
38257      declarations: SHARED_FORM_DIRECTIVES,
38258      exports: SHARED_FORM_DIRECTIVES
38259    }]
38260  }], null, null);
38261})();
38262var FormArray = class extends AbstractControl {
38263  /**
38264   * Creates a new `FormArray` instance.
38265   *
38266   * @param controls An array of child controls. Each child control is given an index
38267   * where it is registered.
38268   *
38269   * @param validatorOrOpts A synchronous validator function, or an array of
38270   * such functions, or an `AbstractControlOptions` object that contains validation functions
38271   * and a validation trigger.
38272   *
38273   * @param asyncValidator A single async validator or array of async validator functions
38274   *
38275   */
38276  constructor(controls, validatorOrOpts, asyncValidator) {
38277    super(pickValidators(validatorOrOpts), pickAsyncValidators(asyncValidator, validatorOrOpts));
38278    this.controls = controls;
38279    this._initObservables();
38280    this._setUpdateStrategy(validatorOrOpts);
38281    this._setUpControls();
38282    this.updateValueAndValidity({
38283      onlySelf: true,
38284      // If `asyncValidator` is present, it will trigger control status change from `PENDING` to
38285      // `VALID` or `INVALID`.
38286      // The status should be broadcasted via the `statusChanges` observable, so we set `emitEvent`
38287      // to `true` to allow that during the control creation process.
38288      emitEvent: !!this.asyncValidator
38289    });
38290  }
38291  controls;
38292  /**
38293   * Get the `AbstractControl` at the given `index` in the array.
38294   *
38295   * @param index Index in the array to retrieve the control. If `index` is negative, it will wrap
38296   *     around from the back, and if index is greatly negative (less than `-length`), the result is
38297   * undefined. This behavior is the same as `Array.at(index)`.
38298   */
38299  at(index) {
38300    return this.controls[this._adjustIndex(index)];
38301  }
38302  /**
38303   * Insert a new `AbstractControl` at the end of the array.
38304   *
38305   * @param control Form control to be inserted
38306   * @param options Specifies whether this FormArray instance should emit events after a new
38307   *     control is added.
38308   * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
38309   * `valueChanges` observables emit events with the latest status and value when the control is
38310   * inserted. When false, no events are emitted.
38311   */
38312  push(control, options2 = {}) {
38313    this.controls.push(control);
38314    this._registerControl(control);
38315    this.updateValueAndValidity({
38316      emitEvent: options2.emitEvent
38317    });
38318    this._onCollectionChange();
38319  }
38320  /**
38321   * Insert a new `AbstractControl` at the given `index` in the array.
38322   *
38323   * @param index Index in the array to insert the control. If `index` is negative, wraps around
38324   *     from the back. If `index` is greatly negative (less than `-length`), prepends to the array.
38325   * This behavior is the same as `Array.splice(index, 0, control)`.
38326   * @param control Form control to be inserted
38327   * @param options Specifies whether this FormArray instance should emit events after a new
38328   *     control is inserted.
38329   * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
38330   * `valueChanges` observables emit events with the latest status and value when the control is
38331   * inserted. When false, no events are emitted.
38332   */
38333  insert(index, control, options2 = {}) {
38334    this.controls.splice(index, 0, control);
38335    this._registerControl(control);
38336    this.updateValueAndValidity({
38337      emitEvent: options2.emitEvent
38338    });
38339  }
38340  /**
38341   * Remove the control at the given `index` in the array.
38342   *
38343   * @param index Index in the array to remove the control.  If `index` is negative, wraps around
38344   *     from the back. If `index` is greatly negative (less than `-length`), removes the first
38345   *     element. This behavior is the same as `Array.splice(index, 1)`.
38346   * @param options Specifies whether this FormArray instance should emit events after a
38347   *     control is removed.
38348   * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
38349   * `valueChanges` observables emit events with the latest status and value when the control is
38350   * removed. When false, no events are emitted.
38351   */
38352  removeAt(index, options2 = {}) {
38353    let adjustedIndex = this._adjustIndex(index);
38354    if (adjustedIndex < 0) adjustedIndex = 0;
38355    if (this.controls[adjustedIndex]) this.controls[adjustedIndex]._registerOnCollectionChange(() => {
38356    });
38357    this.controls.splice(adjustedIndex, 1);
38358    this.updateValueAndValidity({
38359      emitEvent: options2.emitEvent
38360    });
38361  }
38362  /**
38363   * Replace an existing control.
38364   *
38365   * @param index Index in the array to replace the control. If `index` is negative, wraps around
38366   *     from the back. If `index` is greatly negative (less than `-length`), replaces the first
38367   *     element. This behavior is the same as `Array.splice(index, 1, control)`.
38368   * @param control The `AbstractControl` control to replace the existing control
38369   * @param options Specifies whether this FormArray instance should emit events after an
38370   *     existing control is replaced with a new one.
38371   * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
38372   * `valueChanges` observables emit events with the latest status and value when the control is
38373   * replaced with a new one. When false, no events are emitted.
38374   */
38375  setControl(index, control, options2 = {}) {
38376    let adjustedIndex = this._adjustIndex(index);
38377    if (adjustedIndex < 0) adjustedIndex = 0;
38378    if (this.controls[adjustedIndex]) this.controls[adjustedIndex]._registerOnCollectionChange(() => {
38379    });
38380    this.controls.splice(adjustedIndex, 1);
38381    if (control) {
38382      this.controls.splice(adjustedIndex, 0, control);
38383      this._registerControl(control);
38384    }
38385    this.updateValueAndValidity({
38386      emitEvent: options2.emitEvent
38387    });
38388    this._onCollectionChange();
38389  }
38390  /**
38391   * Length of the control array.
38392   */
38393  get length() {
38394    return this.controls.length;
38395  }
38396  /**
38397   * Sets the value of the `FormArray`. It accepts an array that matches
38398   * the structure of the control.
38399   *
38400   * This method performs strict checks, and throws an error if you try
38401   * to set the value of a control that doesn't exist or if you exclude the
38402   * value of a control.
38403   *
38404   * @usageNotes
38405   * ### Set the values for the controls in the form array
38406   *
38407   * ```ts
38408   * const arr = new FormArray([
38409   *   new FormControl(),
38410   *   new FormControl()
38411   * ]);
38412   * console.log(arr.value);   // [null, null]
38413   *
38414   * arr.setValue(['Nancy', 'Drew']);
38415   * console.log(arr.value);   // ['Nancy', 'Drew']
38416   * ```
38417   *
38418   * @param value Array of values for the controls
38419   * @param options Configure options that determine how the control propagates changes and
38420   * emits events after the value changes
38421   *
38422   * * `onlySelf`: When true, each change only affects this control, and not its parent. Default
38423   * is false.
38424   * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
38425   * `valueChanges`
38426   * observables emit events with the latest status and value when the control value is updated.
38427   * When false, no events are emitted.
38428   * The configuration options are passed to the {@link AbstractControl#updateValueAndValidity
38429   * updateValueAndValidity} method.
38430   */
38431  setValue(value, options2 = {}) {
38432    assertAllValuesPresent(this, false, value);
38433    value.forEach((newValue, index) => {
38434      assertControlPresent(this, false, index);
38435      this.at(index).setValue(newValue, {
38436        onlySelf: true,
38437        emitEvent: options2.emitEvent
38438      });
38439    });
38440    this.updateValueAndValidity(options2);
38441  }
38442  /**
38443   * Patches the value of the `FormArray`. It accepts an array that matches the
38444   * structure of the control, and does its best to match the values to the correct
38445   * controls in the group.
38446   *
38447   * It accepts both super-sets and sub-sets of the array without throwing an error.
38448   *
38449   * @usageNotes
38450   * ### Patch the values for controls in a form array
38451   *
38452   * ```ts
38453   * const arr = new FormArray([
38454   *    new FormControl(),
38455   *    new FormControl()
38456   * ]);
38457   * console.log(arr.value);   // [null, null]
38458   *
38459   * arr.patchValue(['Nancy']);
38460   * console.log(arr.value);   // ['Nancy', null]
38461   * ```
38462   *
38463   * @param value Array of latest values for the controls
38464   * @param options Configure options that determine how the control propagates changes and
38465   * emits events after the value changes
38466   *
38467   * * `onlySelf`: When true, each change only affects this control, and not its parent. Default
38468   * is false.
38469   * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
38470   * `valueChanges` observables emit events with the latest status and value when the control
38471   * value is updated. When false, no events are emitted. The configuration options are passed to
38472   * the {@link AbstractControl#updateValueAndValidity updateValueAndValidity} method.
38473   */
38474  patchValue(value, options2 = {}) {
38475    if (value == null) return;
38476    value.forEach((newValue, index) => {
38477      if (this.at(index)) {
38478        this.at(index).patchValue(newValue, {
38479          onlySelf: true,
38480          emitEvent: options2.emitEvent
38481        });
38482      }
38483    });
38484    this.updateValueAndValidity(options2);
38485  }
38486  /**
38487   * Resets the `FormArray` and all descendants are marked `pristine` and `untouched`, and the
38488   * value of all descendants to null or null maps.
38489   *
38490   * You reset to a specific form state by passing in an array of states
38491   * that matches the structure of the control. The state is a standalone value
38492   * or a form state object with both a value and a disabled status.
38493   *
38494   * @usageNotes
38495   * ### Reset the values in a form array
38496   *
38497   * ```ts
38498   * const arr = new FormArray([
38499   *    new FormControl(),
38500   *    new FormControl()
38501   * ]);
38502   * arr.reset(['name', 'last name']);
38503   *
38504   * console.log(arr.value);  // ['name', 'last name']
38505   * ```
38506   *
38507   * ### Reset the values in a form array and the disabled status for the first control
38508   *
38509   * ```ts
38510   * arr.reset([
38511   *   {value: 'name', disabled: true},
38512   *   'last'
38513   * ]);
38514   *
38515   * console.log(arr.value);  // ['last']
38516   * console.log(arr.at(0).status);  // 'DISABLED'
38517   * ```
38518   *
38519   * @param value Array of values for the controls
38520   * @param options Configure options that determine how the control propagates changes and
38521   * emits events after the value changes
38522   *
38523   * * `onlySelf`: When true, each change only affects this control, and not its parent. Default
38524   * is false.
38525   * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
38526   * `valueChanges`
38527   * observables emit events with the latest status and value when the control is reset.
38528   * When false, no events are emitted.
38529   * The configuration options are passed to the {@link AbstractControl#updateValueAndValidity
38530   * updateValueAndValidity} method.
38531   */
38532  reset(value = [], options2 = {}) {
38533    this._forEachChild((control, index) => {
38534      control.reset(value[index], {
38535        onlySelf: true,
38536        emitEvent: options2.emitEvent
38537      });
38538    });
38539    this._updatePristine(options2, this);
38540    this._updateTouched(options2, this);
38541    this.updateValueAndValidity(options2);
38542  }
38543  /**
38544   * The aggregate value of the array, including any disabled controls.
38545   *
38546   * Reports all values regardless of disabled status.
38547   */
38548  getRawValue() {
38549    return this.controls.map((control) => control.getRawValue());
38550  }
38551  /**
38552   * Remove all controls in the `FormArray`.
38553   *
38554   * @param options Specifies whether this FormArray instance should emit events after all
38555   *     controls are removed.
38556   * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
38557   * `valueChanges` observables emit events with the latest status and value when all controls
38558   * in this FormArray instance are removed. When false, no events are emitted.
38559   *
38560   * @usageNotes
38561   * ### Remove all elements from a FormArray
38562   *
38563   * ```ts
38564   * const arr = new FormArray([
38565   *    new FormControl(),
38566   *    new FormControl()
38567   * ]);
38568   * console.log(arr.length);  // 2
38569   *
38570   * arr.clear();
38571   * console.log(arr.length);  // 0
38572   * ```
38573   *
38574   * It's a simpler and more efficient alternative to removing all elements one by one:
38575   *
38576   * ```ts
38577   * const arr = new FormArray([
38578   *    new FormControl(),
38579   *    new FormControl()
38580   * ]);
38581   *
38582   * while (arr.length) {
38583   *    arr.removeAt(0);
38584   * }
38585   * ```
38586   */
38587  clear(options2 = {}) {
38588    if (this.controls.length < 1) return;
38589    this._forEachChild((control) => control._registerOnCollectionChange(() => {
38590    }));
38591    this.controls.splice(0);
38592    this.updateValueAndValidity({
38593      emitEvent: options2.emitEvent
38594    });
38595  }
38596  /**
38597   * Adjusts a negative index by summing it with the length of the array. For very negative
38598   * indices, the result may remain negative.
38599   * @internal
38600   */
38601  _adjustIndex(index) {
38602    return index < 0 ? index + this.length : index;
38603  }
38604  /** @internal */
38605  _syncPendingControls() {
38606    let subtreeUpdated = this.controls.reduce((updated, child) => {
38607      return child._syncPendingControls() ? true : updated;
38608    }, false);
38609    if (subtreeUpdated) this.updateValueAndValidity({
38610      onlySelf: true
38611    });
38612    return subtreeUpdated;
38613  }
38614  /** @internal */
38615  _forEachChild(cb) {
38616    this.controls.forEach((control, index) => {
38617      cb(control, index);
38618    });
38619  }
38620  /** @internal */
38621  _updateValue() {
38622    this.value = this.controls.filter((control) => control.enabled || this.disabled).map((control) => control.value);
38623  }
38624  /** @internal */
38625  _anyControls(condition) {
38626    return this.controls.some((control) => control.enabled && condition(control));
38627  }
38628  /** @internal */
38629  _setUpControls() {
38630    this._forEachChild((control) => this._registerControl(control));
38631  }
38632  /** @internal */
38633  _allControlsDisabled() {
38634    for (const control of this.controls) {
38635      if (control.enabled) return false;
38636    }
38637    return this.controls.length > 0 || this.disabled;
38638  }
38639  _registerControl(control) {
38640    control.setParent(this);
38641    control._registerOnCollectionChange(this._onCollectionChange);
38642  }
38643  /** @internal */
38644  _find(name) {
38645    return this.at(name) ?? null;
38646  }
38647};
38648function isAbstractControlOptions(options2) {
38649  return !!options2 && (options2.asyncValidators !== void 0 || options2.validators !== void 0 || options2.updateOn !== void 0);
38650}
38651var FormBuilder = class _FormBuilder {
38652  useNonNullable = false;
38653  /**
38654   * @description
38655   * Returns a FormBuilder in which automatically constructed `FormControl` elements
38656   * have `{nonNullable: true}` and are non-nullable.
38657   *
38658   * **Constructing non-nullable controls**
38659   *
38660   * When constructing a control, it will be non-nullable, and will reset to its initial value.
38661   *
38662   * ```ts
38663   * let nnfb = new FormBuilder().nonNullable;
38664   * let name = nnfb.control('Alex'); // FormControl<string>
38665   * name.reset();
38666   * console.log(name); // 'Alex'
38667   * ```
38668   *
38669   * **Constructing non-nullable groups or arrays**
38670   *
38671   * When constructing a group or array, all automatically created inner controls will be
38672   * non-nullable, and will reset to their initial values.
38673   *
38674   * ```ts
38675   * let nnfb = new FormBuilder().nonNullable;
38676   * let name = nnfb.group({who: 'Alex'}); // FormGroup<{who: FormControl<string>}>
38677   * name.reset();
38678   * console.log(name); // {who: 'Alex'}
38679   * ```
38680   * **Constructing *nullable* fields on groups or arrays**
38681   *
38682   * It is still possible to have a nullable field. In particular, any `FormControl` which is
38683   * *already* constructed will not be altered. For example:
38684   *
38685   * ```ts
38686   * let nnfb = new FormBuilder().nonNullable;
38687   * // FormGroup<{who: FormControl<string|null>}>
38688   * let name = nnfb.group({who: new FormControl('Alex')});
38689   * name.reset(); console.log(name); // {who: null}
38690   * ```
38691   *
38692   * Because the inner control is constructed explicitly by the caller, the builder has
38693   * no control over how it is created, and cannot exclude the `null`.
38694   */
38695  get nonNullable() {
38696    const nnfb = new _FormBuilder();
38697    nnfb.useNonNullable = true;
38698    return nnfb;
38699  }
38700  group(controls, options2 = null) {
38701    const reducedControls = this._reduceControls(controls);
38702    let newOptions = {};
38703    if (isAbstractControlOptions(options2)) {
38704      newOptions = options2;
38705    } else if (options2 !== null) {
38706      newOptions.validators = options2.validator;
38707      newOptions.asyncValidators = options2.asyncValidator;
38708    }
38709    return new FormGroup(reducedControls, newOptions);
38710  }
38711  /**
38712   * @description
38713   * Constructs a new `FormRecord` instance. Accepts a single generic argument, which is an object
38714   * containing all the keys and corresponding inner control types.
38715   *
38716   * @param controls A collection of child controls. The key for each child is the name
38717   * under which it is registered.
38718   *
38719   * @param options Configuration options object for the `FormRecord`. The object should have the
38720   * `AbstractControlOptions` type and might contain the following fields:
38721   * * `validators`: A synchronous validator function, or an array of validator functions.
38722   * * `asyncValidators`: A single async validator or array of async validator functions.
38723   * * `updateOn`: The event upon which the control should be updated (options: 'change' | 'blur'
38724   * | submit').
38725   */
38726  record(controls, options2 = null) {
38727    const reducedControls = this._reduceControls(controls);
38728    return new FormRecord(reducedControls, options2);
38729  }
38730  /**
38731   * @description
38732   * Constructs a new `FormControl` with the given state, validators and options. Sets
38733   * `{nonNullable: true}` in the options to get a non-nullable control. Otherwise, the
38734   * control will be nullable. Accepts a single generic argument, which is the type  of the
38735   * control's value.
38736   *
38737   * @param formState Initializes the control with an initial state value, or
38738   * with an object that contains both a value and a disabled status.
38739   *
38740   * @param validatorOrOpts A synchronous validator function, or an array of
38741   * such functions, or a `FormControlOptions` object that contains
38742   * validation functions and a validation trigger.
38743   *
38744   * @param asyncValidator A single async validator or array of async validator
38745   * functions.
38746   *
38747   * @usageNotes
38748   *
38749   * ### Initialize a control as disabled
38750   *
38751   * The following example returns a control with an initial value in a disabled state.
38752   *
38753   * {@example forms/ts/formBuilder/form_builder_example.ts region='disabled-control'}
38754   */
38755  control(formState, validatorOrOpts, asyncValidator) {
38756    let newOptions = {};
38757    if (!this.useNonNullable) {
38758      return new FormControl(formState, validatorOrOpts, asyncValidator);
38759    }
38760    if (isAbstractControlOptions(validatorOrOpts)) {
38761      newOptions = validatorOrOpts;
38762    } else {
38763      newOptions.validators = validatorOrOpts;
38764      newOptions.asyncValidators = asyncValidator;
38765    }
38766    return new FormControl(formState, __spreadProps(__spreadValues({}, newOptions), {
38767      nonNullable: true
38768    }));
38769  }
38770  /**
38771   * Constructs a new `FormArray` from the given array of configurations,
38772   * validators and options. Accepts a single generic argument, which is the type of each control
38773   * inside the array.
38774   *
38775   * @param controls An array of child controls or control configs. Each child control is given an
38776   *     index when it is registered.
38777   *
38778   * @param validatorOrOpts A synchronous validator function, or an array of such functions, or an
38779   *     `AbstractControlOptions` object that contains
38780   * validation functions and a validation trigger.
38781   *
38782   * @param asyncValidator A single async validator or array of async validator functions.
38783   */
38784  array(controls, validatorOrOpts, asyncValidator) {
38785    const createdControls = controls.map((c) => this._createControl(c));
38786    return new FormArray(createdControls, validatorOrOpts, asyncValidator);
38787  }
38788  /** @internal */
38789  _reduceControls(controls) {
38790    const createdControls = {};
38791    Object.keys(controls).forEach((controlName) => {
38792      createdControls[controlName] = this._createControl(controls[controlName]);
38793    });
38794    return createdControls;
38795  }
38796  /** @internal */
38797  _createControl(controls) {
38798    if (controls instanceof FormControl) {
38799      return controls;
38800    } else if (controls instanceof AbstractControl) {
38801      return controls;
38802    } else if (Array.isArray(controls)) {
38803      const value = controls[0];
38804      const validator = controls.length > 1 ? controls[1] : null;
38805      const asyncValidator = controls.length > 2 ? controls[2] : null;
38806      return this.control(value, validator, asyncValidator);
38807    } else {
38808      return this.control(controls);
38809    }
38810  }
38811  static \u0275fac = function FormBuilder_Factory(__ngFactoryType__) {
38812    return new (__ngFactoryType__ || _FormBuilder)();
38813  };
38814  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
38815    token: _FormBuilder,
38816    factory: _FormBuilder.\u0275fac,
38817    providedIn: "root"
38818  });
38819};
38820(() => {
38821  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(FormBuilder, [{
38822    type: Injectable,
38823    args: [{
38824      providedIn: "root"
38825    }]
38826  }], null, null);
38827})();
38828var NonNullableFormBuilder = class _NonNullableFormBuilder {
38829  static \u0275fac = function NonNullableFormBuilder_Factory(__ngFactoryType__) {
38830    return new (__ngFactoryType__ || _NonNullableFormBuilder)();
38831  };
38832  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
38833    token: _NonNullableFormBuilder,
38834    factory: () => (() => inject(FormBuilder).nonNullable)(),
38835    providedIn: "root"
38836  });
38837};
38838(() => {
38839  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NonNullableFormBuilder, [{
38840    type: Injectable,
38841    args: [{
38842      providedIn: "root",
38843      useFactory: () => inject(FormBuilder).nonNullable
38844    }]
38845  }], null, null);
38846})();
38847var UntypedFormBuilder = class _UntypedFormBuilder extends FormBuilder {
38848  group(controlsConfig, options2 = null) {
38849    return super.group(controlsConfig, options2);
38850  }
38851  /**
38852   * Like `FormBuilder#control`, except the resulting control is untyped.
38853   */
38854  control(formState, validatorOrOpts, asyncValidator) {
38855    return super.control(formState, validatorOrOpts, asyncValidator);
38856  }
38857  /**
38858   * Like `FormBuilder#array`, except the resulting array is untyped.
38859   */
38860  array(controlsConfig, validatorOrOpts, asyncValidator) {
38861    return super.array(controlsConfig, validatorOrOpts, asyncValidator);
38862  }
38863  static \u0275fac = /* @__PURE__ */ (() => {
38864    let \u0275UntypedFormBuilder_BaseFactory;
38865    return function UntypedFormBuilder_Factory(__ngFactoryType__) {
38866      return (\u0275UntypedFormBuilder_BaseFactory || (\u0275UntypedFormBuilder_BaseFactory = \u0275\u0275getInheritedFactory(_UntypedFormBuilder)))(__ngFactoryType__ || _UntypedFormBuilder);
38867    };
38868  })();
38869  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
38870    token: _UntypedFormBuilder,
38871    factory: _UntypedFormBuilder.\u0275fac,
38872    providedIn: "root"
38873  });
38874};
38875(() => {
38876  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(UntypedFormBuilder, [{
38877    type: Injectable,
38878    args: [{
38879      providedIn: "root"
38880    }]
38881  }], null, null);
38882})();
38883var VERSION = new Version("19.1.8");
38884var FormsModule = class _FormsModule {
38885  /**
38886   * @description
38887   * Provides options for configuring the forms module.
38888   *
38889   * @param opts An object of configuration options
38890   * * `callSetDisabledState` Configures whether to `always` call `setDisabledState`, which is more
38891   * correct, or to only call it `whenDisabled`, which is the legacy behavior.
38892   */
38893  static withConfig(opts) {
38894    return {
38895      ngModule: _FormsModule,
38896      providers: [{
38897        provide: CALL_SET_DISABLED_STATE,
38898        useValue: opts.callSetDisabledState ?? setDisabledStateDefault
38899      }]
38900    };
38901  }
38902  static \u0275fac = function FormsModule_Factory(__ngFactoryType__) {
38903    return new (__ngFactoryType__ || _FormsModule)();
38904  };
38905  static \u0275mod = /* @__PURE__ */ \u0275\u0275defineNgModule({
38906    type: _FormsModule
38907  });
38908  static \u0275inj = /* @__PURE__ */ \u0275\u0275defineInjector({
38909    imports: [\u0275InternalFormsSharedModule]
38910  });
38911};
38912(() => {
38913  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(FormsModule, [{
38914    type: NgModule,
38915    args: [{
38916      declarations: TEMPLATE_DRIVEN_DIRECTIVES,
38917      exports: [\u0275InternalFormsSharedModule, TEMPLATE_DRIVEN_DIRECTIVES]
38918    }]
38919  }], null, null);
38920})();
38921var ReactiveFormsModule = class _ReactiveFormsModule {
38922  /**
38923   * @description
38924   * Provides options for configuring the reactive forms module.
38925   *
38926   * @param opts An object of configuration options
38927   * * `warnOnNgModelWithFormControl` Configures when to emit a warning when an `ngModel`
38928   * binding is used with reactive form directives.
38929   * * `callSetDisabledState` Configures whether to `always` call `setDisabledState`, which is more
38930   * correct, or to only call it `whenDisabled`, which is the legacy behavior.
38931   */
38932  static withConfig(opts) {
38933    return {
38934      ngModule: _ReactiveFormsModule,
38935      providers: [{
38936        provide: NG_MODEL_WITH_FORM_CONTROL_WARNING,
38937        useValue: opts.warnOnNgModelWithFormControl ?? "always"
38938      }, {
38939        provide: CALL_SET_DISABLED_STATE,
38940        useValue: opts.callSetDisabledState ?? setDisabledStateDefault
38941      }]
38942    };
38943  }
38944  static \u0275fac = function ReactiveFormsModule_Factory(__ngFactoryType__) {
38945    return new (__ngFactoryType__ || _ReactiveFormsModule)();
38946  };
38947  static \u0275mod = /* @__PURE__ */ \u0275\u0275defineNgModule({
38948    type: _ReactiveFormsModule
38949  });
38950  static \u0275inj = /* @__PURE__ */ \u0275\u0275defineInjector({
38951    imports: [\u0275InternalFormsSharedModule]
38952  });
38953};
38954(() => {
38955  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(ReactiveFormsModule, [{
38956    type: NgModule,
38957    args: [{
38958      declarations: [REACTIVE_DRIVEN_DIRECTIVES],
38959      exports: [\u0275InternalFormsSharedModule, REACTIVE_DRIVEN_DIRECTIVES]
38960    }]
38961  }], null, null);
38962})();
38963
vendor: 13,863 bytes, lines 38964-39418
38964// node_modules/@semantic-components/re-captcha/fesm2022/semantic-components-re-captcha.mjs
38965var SC_RE_CAPTCHA_V2_SITE_KEY = new InjectionToken("SC_RE_CAPTCHA_V2_SITE_KEY");
38966var SC_RE_CAPTCHA_V3_SITE_KEY = new InjectionToken("SC_RE_CAPTCHA_V3_SITE_KEY");
38967var SC_RE_CAPTCHA_LANGUAGE_CODE = new InjectionToken("SC_RE_CAPTCHA_LANGUAGE_CODE");
38968function provideScReCaptchaSettings(settings) {
38969  const providers = [];
38970  if (settings.v2SiteKey) {
38971    providers.push({
38972      provide: SC_RE_CAPTCHA_V2_SITE_KEY,
38973      useValue: settings.v2SiteKey
38974    });
38975  }
38976  if (settings.v3SiteKey) {
38977    providers.push({
38978      provide: SC_RE_CAPTCHA_V3_SITE_KEY,
38979      useValue: settings.v3SiteKey
38980    });
38981  }
38982  if (settings.languageCode) {
38983    providers.push({
38984      provide: SC_RE_CAPTCHA_LANGUAGE_CODE,
38985      useValue: settings.languageCode
38986    });
38987  }
38988  return makeEnvironmentProviders(providers);
38989}
38990var ScReCaptchaService = class _ScReCaptchaService {
38991  v3SiteKey = inject(SC_RE_CAPTCHA_V3_SITE_KEY, {
38992    optional: true
38993  });
38994  languageCode = inject(SC_RE_CAPTCHA_LANGUAGE_CODE, {
38995    optional: true
38996  });
38997  scriptId = "recaptcha-script";
38998  apiUrl = "https://www.google.com/recaptcha/api.js";
38999  scriptStatus = signal(null);
39000  loadPromise = null;
39001  /**
39002   * Check if the script already exists in the document
39003   */
39004  checkScriptExists() {
39005    const existingScript = document.getElementById(this.scriptId);
39006    if (existingScript) {
39007      if (window["grecaptcha"] && typeof window["grecaptcha"].render === "function") {
39008        this.scriptStatus.set(true);
39009      }
39010    }
39011  }
39012  /**
39013   * Load the reCAPTCHA script dynamically
39014   * @returns Promise that resolves to true when script is loaded
39015   */
39016  loadScript() {
39017    this.checkScriptExists();
39018    if (this.scriptStatus() === true) {
39019      return Promise.resolve(true);
39020    }
39021    if (this.loadPromise) {
39022      return this.loadPromise;
39023    }
39024    this.loadPromise = new Promise((resolve, reject) => {
39025      const callbackName = `onRecaptchaLoaded_${Date.now()}`;
39026      window[callbackName] = () => {
39027        this.checkGrecaptchaAvailability(3, resolve, reject);
39028      };
39029      let url = this.apiUrl;
39030      const params = [];
39031      if (this.v3SiteKey) {
39032        params.push(`render=${this.v3SiteKey}`);
39033      } else {
39034        params.push(`render=explicit`);
39035      }
39036      if (this.languageCode) {
39037        params.push(`hl=${this.languageCode}`);
39038      }
39039      params.push(`onload=${callbackName}`);
39040      if (params.length > 0) {
39041        url = `${url}?${params.join("&")}`;
39042      }
39043      const script = document.createElement("script");
39044      script.id = this.scriptId;
39045      script.src = url;
39046      script.async = true;
39047      script.defer = true;
39048      script.onerror = () => {
39049        this.loadPromise = null;
39050        console.error("Error loading reCAPTCHA script");
39051        this.scriptStatus.set(false);
39052        reject(new Error("Failed to load reCAPTCHA script"));
39053      };
39054      document.head.appendChild(script);
39055    });
39056    return this.loadPromise;
39057  }
39058  /**
39059   * Check repeatedly if grecaptcha is available
39060   * @param attempts Number of attempts to check
39061   * @param resolve Promise resolve function
39062   * @param reject Promise reject function
39063   */
39064  checkGrecaptchaAvailability(attempts, resolve, reject) {
39065    if (window["grecaptcha"] && typeof window["grecaptcha"].render === "function") {
39066      this.scriptStatus.set(true);
39067      this.loadPromise = null;
39068      resolve(true);
39069      return;
39070    }
39071    if (attempts <= 0) {
39072      this.loadPromise = null;
39073      console.error("reCAPTCHA script loaded but grecaptcha object not available");
39074      this.scriptStatus.set(false);
39075      reject(new Error("reCAPTCHA script loaded but grecaptcha object not available"));
39076      return;
39077    }
39078    setTimeout(() => this.checkGrecaptchaAvailability(attempts - 1, resolve, reject), 200);
39079  }
39080  /**
39081   * Remove the reCAPTCHA script from the DOM
39082   */
39083  removeScript() {
39084    const script = document.getElementById(this.scriptId);
39085    if (script) {
39086      script.remove();
39087      delete window["grecaptcha"];
39088      this.scriptStatus.set(null);
39089      this.loadPromise = null;
39090    }
39091  }
39092  /**
39093   * Reset all reCAPTCHA instances on the page
39094   */
39095  resetAll() {
39096    if (this.scriptStatus() === true && window["grecaptcha"]) {
39097      try {
39098        window["grecaptcha"].reset();
39099      } catch (e) {
39100        console.warn("Error resetting reCAPTCHA:", e);
39101      }
39102    }
39103  }
39104  static \u0275fac = function ScReCaptchaService_Factory(__ngFactoryType__) {
39105    return new (__ngFactoryType__ || _ScReCaptchaService)();
39106  };
39107  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
39108    token: _ScReCaptchaService,
39109    factory: _ScReCaptchaService.\u0275fac,
39110    providedIn: "root"
39111  });
39112};
39113(() => {
39114  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(ScReCaptchaService, [{
39115    type: Injectable,
39116    args: [{
39117      providedIn: "root"
39118    }]
39119  }], null, null);
39120})();
39121var ScScoreReCaptcha = class _ScScoreReCaptcha {
39122  v3SiteKey = inject(SC_RE_CAPTCHA_V3_SITE_KEY);
39123  scReCaptchaService = inject(ScReCaptchaService);
39124  constructor() {
39125    afterNextRender(() => __async(this, null, function* () {
39126      yield this.scReCaptchaService.loadScript();
39127    }));
39128  }
39129  execute(actionName) {
39130    return __async(this, null, function* () {
39131      return new Promise((resolve) => {
39132        grecaptcha.ready(() => {
39133          grecaptcha.execute(this.v3SiteKey, {
39134            action: actionName
39135          }).then((token) => {
39136            resolve(token);
39137          });
39138        });
39139      });
39140    });
39141  }
39142  static \u0275fac = function ScScoreReCaptcha_Factory(__ngFactoryType__) {
39143    return new (__ngFactoryType__ || _ScScoreReCaptcha)();
39144  };
39145  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
39146    token: _ScScoreReCaptcha,
39147    factory: _ScScoreReCaptcha.\u0275fac,
39148    providedIn: "root"
39149  });
39150};
39151(() => {
39152  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(ScScoreReCaptcha, [{
39153    type: Injectable,
39154    args: [{
39155      providedIn: "root"
39156    }]
39157  }], () => [], null);
39158})();
39159var counters = {};
39160var IdGenerator = class _IdGenerator {
39161  appId = inject(APP_ID);
39162  /**
39163   * Generates a unique ID with a specific prefix.
39164   * @param prefix Prefix to add to the ID.
39165   */
39166  getId(prefix) {
39167    if (this.appId !== "ng") {
39168      prefix += this.appId;
39169    }
39170    if (!counters.hasOwnProperty(prefix)) {
39171      counters[prefix] = 0;
39172    }
39173    return `${prefix}${counters[prefix]++}`;
39174  }
39175  static \u0275fac = function IdGenerator_Factory(__ngFactoryType__) {
39176    return new (__ngFactoryType__ || _IdGenerator)();
39177  };
39178  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
39179    token: _IdGenerator,
39180    factory: _IdGenerator.\u0275fac,
39181    providedIn: "root"
39182  });
39183};
39184(() => {
39185  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(IdGenerator, [{
39186    type: Injectable,
39187    args: [{
39188      providedIn: "root"
39189    }]
39190  }], null, null);
39191})();
39192var ScReCaptchaBase = class _ScReCaptchaBase {
39193  id = inject(IdGenerator).getId("sc-re-captcha-");
39194  widgetId = "";
39195  changeDetectorRef = inject(ChangeDetectorRef);
39196  scReCaptchaService = inject(ScReCaptchaService);
39197  v2SiteKey = inject(SC_RE_CAPTCHA_V2_SITE_KEY, {
39198    optional: true
39199  });
39200  siteKeyInput = input("", {
39201    alias: "siteKey"
39202  });
39203  siteKey = computed(() => {
39204    if (this.siteKeyInput()) {
39205      return this.siteKeyInput();
39206    }
39207    return this.v2SiteKey ?? "";
39208  });
39209  tabindex = input("0");
39210  callback = input(void 0);
39211  expiredCallback = input(void 0, {
39212    alias: "expired-callback"
39213  });
39214  errorCallback = input(void 0, {
39215    alias: "error-callback"
39216  });
39217  value = signal(null);
39218  constructor() {
39219    afterNextRender(() => __async(this, null, function* () {
39220      yield this.scReCaptchaService.loadScript();
39221      this.render();
39222    }));
39223  }
39224  // eslint-disable-next-line @typescript-eslint/no-empty-function
39225  render() {
39226  }
39227  renderWidget(themeOrBadge, themeOrBadgeValue, sizeOrInvisible) {
39228    this.widgetId = grecaptcha.render(this.id, {
39229      sitekey: this.siteKey(),
39230      [themeOrBadge]: themeOrBadgeValue,
39231      size: sizeOrInvisible,
39232      tabindex: this.tabindex(),
39233      callback: this.callback() ? this.callback() : this.defaultCallback.bind(this),
39234      "expired-callback": this.expiredCallback() ? this.expiredCallback() : this.defaultExpiredCallback.bind(this),
39235      "error-callback": this.errorCallback() ? this.errorCallback() : this.defaultErrorCallback.bind(this)
39236    }, true);
39237  }
39238  defaultCallback(token) {
39239    this.setValue(token);
39240  }
39241  defaultExpiredCallback() {
39242    this.setValue(null);
39243  }
39244  defaultErrorCallback() {
39245    console.error("error");
39246    this.setValue(null);
39247  }
39248  getResponse() {
39249    grecaptcha.getResponse(this.widgetId);
39250  }
39251  reset() {
39252    grecaptcha.reset(this.widgetId);
39253  }
39254  setValue(newValue) {
39255    this.value.set(newValue);
39256    this.onChange(newValue);
39257    this.changeDetectorRef.markForCheck();
39258  }
39259  writeValue(obj) {
39260    this.value.set(obj);
39261  }
39262  // eslint-disable-next-line @typescript-eslint/no-empty-function
39263  onChange = () => {
39264  };
39265  // eslint-disable-next-line @typescript-eslint/no-empty-function
39266  onTouch = () => {
39267  };
39268  registerOnChange(fn) {
39269    this.onChange = fn;
39270  }
39271  registerOnTouched(fn) {
39272    this.onTouch = fn;
39273  }
39274  static \u0275fac = function ScReCaptchaBase_Factory(__ngFactoryType__) {
39275    return new (__ngFactoryType__ || _ScReCaptchaBase)();
39276  };
39277  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
39278    type: _ScReCaptchaBase,
39279    hostVars: 3,
39280    hostBindings: function ScReCaptchaBase_HostBindings(rf, ctx) {
39281      if (rf & 2) {
39282        \u0275\u0275hostProperty("id", ctx.id);
39283        \u0275\u0275classProp("g-recaptcha", true);
39284      }
39285    },
39286    inputs: {
39287      siteKeyInput: [1, "siteKey", "siteKeyInput"],
39288      tabindex: [1, "tabindex"],
39289      callback: [1, "callback"],
39290      expiredCallback: [1, "expired-callback", "expiredCallback"],
39291      errorCallback: [1, "error-callback", "errorCallback"]
39292    }
39293  });
39294};
39295(() => {
39296  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(ScReCaptchaBase, [{
39297    type: Directive,
39298    args: [{
39299      host: {
39300        "[id]": "id",
39301        "[class.g-recaptcha]": "true"
39302      }
39303    }]
39304  }], () => [], null);
39305})();
39306var ScCheckboxReCaptcha = class _ScCheckboxReCaptcha extends ScReCaptchaBase {
39307  host = inject(ElementRef);
39308  theme = input("light");
39309  size = input("normal");
39310  render() {
39311    this.renderWidget("theme", this.theme(), this.size());
39312  }
39313  isFirstRun = true;
39314  firstTheme;
39315  constructor() {
39316    super();
39317    effect(() => {
39318      this.updateRecaptchaTheme(this.theme());
39319    });
39320  }
39321  reset() {
39322    super.reset();
39323    if (this.firstTheme !== this.theme()) {
39324      this.updateRecaptchaTheme(this.theme());
39325    }
39326  }
39327  updateRecaptchaTheme(newTheme) {
39328    if (this.isFirstRun) {
39329      this.firstTheme = newTheme;
39330      this.isFirstRun = false;
39331      return;
39332    }
39333    const recaptchaFrame = this.host.nativeElement.querySelector('iframe[src*="recaptcha"]');
39334    if (recaptchaFrame) {
39335      let frameSource = recaptchaFrame.src;
39336      if (frameSource.includes("theme=")) {
39337        frameSource = frameSource.replace(/theme=(light|dark)/, `theme=${newTheme}`);
39338      } else {
39339        frameSource += `&theme=${newTheme}`;
39340      }
39341      recaptchaFrame.src = frameSource;
39342    }
39343  }
39344  static \u0275fac = function ScCheckboxReCaptcha_Factory(__ngFactoryType__) {
39345    return new (__ngFactoryType__ || _ScCheckboxReCaptcha)();
39346  };
39347  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
39348    type: _ScCheckboxReCaptcha,
39349    selectors: [["div", "sc-checkbox-re-captcha", ""]],
39350    inputs: {
39351      theme: [1, "theme"],
39352      size: [1, "size"]
39353    },
39354    exportAs: ["scCheckboxReCaptcha"],
39355    features: [\u0275\u0275ProvidersFeature([{
39356      provide: NG_VALUE_ACCESSOR,
39357      useExisting: forwardRef(() => _ScCheckboxReCaptcha),
39358      multi: true
39359    }]), \u0275\u0275InheritDefinitionFeature]
39360  });
39361};
39362(() => {
39363  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(ScCheckboxReCaptcha, [{
39364    type: Directive,
39365    args: [{
39366      selector: "div[sc-checkbox-re-captcha]",
39367      exportAs: "scCheckboxReCaptcha",
39368      providers: [{
39369        provide: NG_VALUE_ACCESSOR,
39370        useExisting: forwardRef(() => ScCheckboxReCaptcha),
39371        multi: true
39372      }]
39373    }]
39374  }], () => [], null);
39375})();
39376var ScInvisibleReCaptcha = class _ScInvisibleReCaptcha extends ScReCaptchaBase {
39377  badge = input("bottomright");
39378  render() {
39379    this.renderWidget("badge", this.badge(), "invisible");
39380  }
39381  execute() {
39382    grecaptcha.execute(this.widgetId);
39383  }
39384  static \u0275fac = /* @__PURE__ */ (() => {
39385    let \u0275ScInvisibleReCaptcha_BaseFactory;
39386    return function ScInvisibleReCaptcha_Factory(__ngFactoryType__) {
39387      return (\u0275ScInvisibleReCaptcha_BaseFactory || (\u0275ScInvisibleReCaptcha_BaseFactory = \u0275\u0275getInheritedFactory(_ScInvisibleReCaptcha)))(__ngFactoryType__ || _ScInvisibleReCaptcha);
39388    };
39389  })();
39390  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
39391    type: _ScInvisibleReCaptcha,
39392    selectors: [["div", "sc-invisible-re-captcha", ""], ["button", "sc-invisible-re-captcha", ""]],
39393    inputs: {
39394      badge: [1, "badge"]
39395    },
39396    exportAs: ["scInvisibleReCaptcha"],
39397    features: [\u0275\u0275ProvidersFeature([{
39398      provide: NG_VALUE_ACCESSOR,
39399      useExisting: forwardRef(() => _ScInvisibleReCaptcha),
39400      multi: true
39401    }]), \u0275\u0275InheritDefinitionFeature]
39402  });
39403};
39404(() => {
39405  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(ScInvisibleReCaptcha, [{
39406    type: Directive,
39407    args: [{
39408      selector: "div[sc-invisible-re-captcha], button[sc-invisible-re-captcha]",
39409      exportAs: "scInvisibleReCaptcha",
39410      providers: [{
39411        provide: NG_VALUE_ACCESSOR,
39412        useExisting: forwardRef(() => ScInvisibleReCaptcha),
39413        multi: true
39414      }]
39415    }]
39416  }], null, null);
39417})();
39418
39419// src/app/publisher/CorporateAgent/publisher-corporate-agent.ts
39420var PublisherCorporateAgent = class PublisherCorporateAgent2 {
39421  constructor(http, progressive, recaptchaService) {
39422    this.http = http;
39423    this.recaptchaService = recaptchaService;
39424    this.baseUrl = "http://localhost:5000/api/";
39425    this.progressive = "1";
39426    this.conversationId = "";
39427    this.conversationIdMap = /* @__PURE__ */ new Map();
39428    this.initializer = void 0;
39429    this.progressive = progressive;
39430  }
39431  reset() {
39432    this.conversationId = "";
39433    this.conversationIdMap.clear();
39434  }
39435  // IConfigurationCaller methods
39436  // TODO bisogna costruire un servizio che istanzia queste classi e rendere parametrica questi parametri
39437  get CallerName() {
39438    return "CorporateAgent1";
39439  }
39440  get CallerProgressive() {
39441    return this.progressive;
39442  }
39443  get CallerSubType() {
39444    return "CorporateAgent";
39445  }
39446  get CallerType() {
39447    return ComponentType.Publishers;
39448  }
39449  setCallerProgressive(progressive) {
39450    throw new Error("Method not implemented.");
39451  }
39452  onParameterInjectedFinished() {
39453    if (this.initializer === void 0) {
39454      throw new Error("Initializer not set");
39455    }
39456    if (!this.baseUrl.endsWith("/")) {
39457      this.baseUrl += "/";
39458    }
39459    this.initializer.onPublisherInitialized();
39460  }
39461  // Inizializzazione del publisher
39462  initialize(initializer, configuration) {
39463    this.initializer = initializer;
39464    configuration.injectParametersToComponent(this);
39465  }
39466  // Restituisce la mappa dei parametri riscrivibili
39467  getRewritableParameterMap() {
39468    const parameters = /* @__PURE__ */ new Map();
39469    parameters.set("baseUrl", this.baseUrl);
39470    parameters.set("progressive", this.progressive);
39471    return parameters;
39472  }
39473  // Implementazione dell'interfaccia IPublisher
39474  read(publisherParameters, subscribeObjInfo, dataType, callerData) {
39475    if (dataType !== DataType.CORPORATE_AGENT_QUERY && dataType !== DataType.CORPORATE_AGENT_WIZARD) {
39476      console.error("PublisherCorporateAgent supports only CORPORATE_AGENT_QUERY and CORPORATE_AGENT_WIZARD data types");
39477      return of(new ReadResult(callerData, null));
39478    }
39479    const language = DoraGetLocale();
39480    if (dataType === DataType.CORPORATE_AGENT_WIZARD) {
39481      const wizardUrl = `${this.baseUrl}wizard/${language}`;
39482      const httpOptions = {
39483        headers: new HttpHeaders({
39484          "Content-Type": "application/json"
39485        }),
39486        withCredentials: false
39487      };
39488      console.log(`CorporateAgent Wizard calling: ${wizardUrl}`);
39489      return this.http.get(wizardUrl, httpOptions).pipe(map((response) => {
39490        console.log("CorporateAgent Wizard response received:", response);
39491        try {
39492          if (Array.isArray(response)) {
39493            const serializer = new TypedJSON(DataCorporateAgentWizard);
39494            const wizardConfigurations = [];
39495            for (const item of response) {
39496              const wizardConfig = serializer.parse(item);
39497              if (wizardConfig) {
39498                wizardConfigurations.push(wizardConfig);
39499              }
39500            }
39501            return new ReadResult(callerData, wizardConfigurations);
39502          } else {
39503            console.error("Expected array response for wizard configurations");
39504            return new ReadResult(callerData, null);
39505          }
39506        } catch (error) {
39507          console.error("Error parsing CorporateAgent Wizard response:", error);
39508          return new ReadResult(callerData, null);
39509        }
39510      }), catchError((error) => {
39511        console.error("CorporateAgent Wizard API error:", error);
39512        return of(new ReadResult(callerData, null));
39513      }));
39514    }
39515    const question = subscribeObjInfo[0];
39516    let conversationId = this.conversationIdMap.get(question);
39517    if (!conversationId && this.conversationId) {
39518      conversationId = this.conversationId;
39519    }
39520    const questionTimestamp = /* @__PURE__ */ new Date();
39521    const tokenSource$ = !conversationId ? from(this.recaptchaService.execute("corporate_agent_query")) : of(null);
39522    return tokenSource$.pipe(switchMap((recaptchaToken) => this.executeQuery(question, language, recaptchaToken, conversationId, questionTimestamp, callerData)));
39523  }
39524  // Metodo privato per eseguire la query HTTP
39525  executeQuery(question, language, recaptchaToken, conversationId, questionTimestamp, callerData) {
39526    const payload = {
39527      question,
39528      language,
39529      page_url: this.getPageUrl()
39530    };
39531    if (recaptchaToken) {
39532      payload.recaptcha_token = recaptchaToken;
39533    }
39534    if (conversationId) {
39535      payload.conversation_id = conversationId;
39536    }
39537    const httpOptions = {
39538      headers: new HttpHeaders({
39539        "Content-Type": "application/json"
39540      }),
39541      withCredentials: false
39542      // Non inviare credenziali (cookie, etc.) con la richiesta cross-domain
39543    };
39544    console.log(`CorporateAgent Query calling: ${this.baseUrl}query`, payload);
39545    return this.http.post(this.baseUrl + "query", payload, httpOptions).pipe(map((response) => {
39546      console.log("CorporateAgent Query response received:", response);
39547      try {
39548        const serializer = new TypedJSON(DataCorporateAgent);
39549        const dataCorporateAgent = serializer.parse(response);
39550        if (dataCorporateAgent) {
39551          dataCorporateAgent.AnswerTimestamp = /* @__PURE__ */ new Date();
39552          dataCorporateAgent.QuestionTimestamp = questionTimestamp;
39553          if (dataCorporateAgent.ConversationId) {
39554            this.conversationId = dataCorporateAgent.ConversationId;
39555            this.conversationIdMap.set(question, dataCorporateAgent.ConversationId);
39556          }
39557        }
39558        return new ReadResult(callerData, dataCorporateAgent);
39559      } catch (error) {
39560        console.error("Error parsing CorporateAgent Query response:", error);
39561        return new ReadResult(callerData, null);
39562      }
39563    }), catchError((error) => {
39564      console.error("CorporateAgent Query API error:", error);
39565      return of(new ReadResult(callerData, null));
39566    }));
39567  }
39568  // Restituisce l'url della pagina chiamante, usato dal server per la tracciatura.
39569  // DoraGetPageUrl() è una aggiunta recente a DoraUtility.js: se l'integrazione ospita una
39570  // copia non aggiornata del file la funzione non esiste, quindi si verifica prima di
39571  // chiamarla per non far fallire la query con un ReferenceError.
39572  getPageUrl() {
39573    try {
39574      if (typeof DoraGetPageUrl === "function") {
39575        return DoraGetPageUrl();
39576      }
39577    } catch (error) {
39578      console.error("Error calling DoraGetPageUrl:", error);
39579    }
39580    return typeof window !== "undefined" ? window.location.origin + window.location.pathname : "";
39581  }
39582};
39583__decorate([
39584  DoraProperty,
39585  __metadata("design:type", Object)
39586], PublisherCorporateAgent.prototype, "baseUrl", void 0);
39587__decorate([
39588  DoraProperty,
39589  __metadata("design:type", Object)
39590], PublisherCorporateAgent.prototype, "progressive", void 0);
39591PublisherCorporateAgent = __decorate([
39592  jsonObject,
39593  __metadata("design:paramtypes", [HttpClient, String, ScScoreReCaptcha])
39594], PublisherCorporateAgent);
39595
39596// src/app/Configuration/configuration-service.ts
39597var ATTRIBUTE_TYPE;
39598(function(ATTRIBUTE_TYPE2) {
39599  ATTRIBUTE_TYPE2[ATTRIBUTE_TYPE2["STRING"] = 0] = "STRING";
39600  ATTRIBUTE_TYPE2[ATTRIBUTE_TYPE2["INTEGER"] = 1] = "INTEGER";
39601  ATTRIBUTE_TYPE2[ATTRIBUTE_TYPE2["FLOAT"] = 2] = "FLOAT";
39602  ATTRIBUTE_TYPE2[ATTRIBUTE_TYPE2["BOOLEAN"] = 3] = "BOOLEAN";
39603  ATTRIBUTE_TYPE2[ATTRIBUTE_TYPE2["DATE"] = 4] = "DATE";
39604  ATTRIBUTE_TYPE2[ATTRIBUTE_TYPE2["TIME"] = 5] = "TIME";
39605  ATTRIBUTE_TYPE2[ATTRIBUTE_TYPE2["DATETIME"] = 6] = "DATETIME";
39606  ATTRIBUTE_TYPE2[ATTRIBUTE_TYPE2["COLOR"] = 7] = "COLOR";
39607  ATTRIBUTE_TYPE2[ATTRIBUTE_TYPE2["ARRAY"] = 8] = "ARRAY";
39608  ATTRIBUTE_TYPE2[ATTRIBUTE_TYPE2["HIGHCHARTOPTIONS"] = 9] = "HIGHCHARTOPTIONS";
39609})(ATTRIBUTE_TYPE || (ATTRIBUTE_TYPE = {}));
39610var ATTRIBUTE_DATAPROVIDER_VALUES;
39611(function(ATTRIBUTE_DATAPROVIDER_VALUES2) {
39612  ATTRIBUTE_DATAPROVIDER_VALUES2[ATTRIBUTE_DATAPROVIDER_VALUES2["NONE"] = 0] = "NONE";
39613  ATTRIBUTE_DATAPROVIDER_VALUES2[ATTRIBUTE_DATAPROVIDER_VALUES2["EXCEL_LIST"] = 1] = "EXCEL_LIST";
39614  ATTRIBUTE_DATAPROVIDER_VALUES2[ATTRIBUTE_DATAPROVIDER_VALUES2["TABLE_LIST"] = 2] = "TABLE_LIST";
39615  ATTRIBUTE_DATAPROVIDER_VALUES2[ATTRIBUTE_DATAPROVIDER_VALUES2["ROW_LIST"] = 3] = "ROW_LIST";
39616  ATTRIBUTE_DATAPROVIDER_VALUES2[ATTRIBUTE_DATAPROVIDER_VALUES2["DATAPROVIDER_ATTRIBUTE_LIST"] = 4] = "DATAPROVIDER_ATTRIBUTE_LIST";
39617})(ATTRIBUTE_DATAPROVIDER_VALUES || (ATTRIBUTE_DATAPROVIDER_VALUES = {}));
39618var ConfigurationService = class _ConfigurationService {
39619  // @ts-ignore
39620  constructor(http, recaptchaService) {
39621    this.http = http;
39622    this.recaptchaService = recaptchaService;
39623    this.read();
39624    this.readHighChartDoc().subscribe((response) => {
39625      this.highChartDoc = response;
39626    });
39627    console.log("Configuration service: finito costruttore");
39628  }
39629  get HighChartDoc() {
39630    return this.highChartDoc;
39631  }
39632  read() {
39633    const preFetched = window.__DORAG_CONFIG__;
39634    if (preFetched) {
39635      console.log("Using pre-bootstrap AppConfiguration.json");
39636      this.parametersPromise = Promise.resolve().then(() => {
39637        const msgContent = new TypedJSON(MsgContent).parse(preFetched);
39638        if (msgContent === void 0) {
39639          console.error("Error parsing pre-bootstrap configuration");
39640          throw new Error("Error parsing pre-bootstrap configuration");
39641        }
39642        return msgContent;
39643      });
39644      console.log("Configuration service: finito read");
39645      return;
39646    }
39647    const completePath = extGetAppConfigurationPath() + "/AppConfiguration.json";
39648    console.log("Reading AppConfiguration.json from ", completePath);
39649    this.parametersPromise = firstValueFrom(this.http.get(completePath)).then((response) => {
39650      const msgContent = new TypedJSON(MsgContent).parse(response);
39651      if (msgContent === void 0) {
39652        console.error("Error reading configuration");
39653        throw new Error("Error reading configuration");
39654      }
39655      console.log("Received configuration");
39656      return msgContent;
39657    });
39658    console.log("Configuration service: finito read");
39659  }
39660  loadPublisher(caller) {
39661    this.parametersPromise.then((parameters) => {
39662      const msgContent = parameters;
39663      const publishersConfig = msgContent.getMultipleParameter("Publishers");
39664      if (publishersConfig === void 0) {
39665        console.error("Publisher section not present in AppConfiguration");
39666        return;
39667      }
39668      const publishers = [];
39669      publishersConfig.multipleParameters.forEach((publisherConfig) => {
39670        switch (publisherConfig.name) {
39671          case "DataManager":
39672            try {
39673              const newPublisher = new PublisherDataManagement(this.http, publisherConfig.getSingleParameter("Progressive").value);
39674              publishers.push(newPublisher);
39675            } catch (e) {
39676              console.error("Progressive not found in publisher " + publishersConfig.name);
39677            }
39678            break;
39679          case "DoraServer":
39680            try {
39681              const newPublisher = new PublisherDoraServer(this.http, publisherConfig.getSingleParameter("Progressive").value);
39682              publishers.push(newPublisher);
39683            } catch (e) {
39684              console.error("Progressive not found in publisher " + publishersConfig.name);
39685            }
39686            break;
39687          case "CorporateAgent":
39688            try {
39689              const newPublisher = new PublisherCorporateAgent(this.http, publisherConfig.getSingleParameter("Progressive").value, this.recaptchaService);
39690              publishers.push(newPublisher);
39691            } catch (e) {
39692              console.error("Progressive not found in publisher " + publishersConfig.name);
39693            }
39694            break;
39695          default:
39696            console.error("Unable to handle Publisher " + publisherConfig.name);
39697        }
39698      });
39699      caller.onPublisherLoaded(publishers);
39700    });
39701  }
39702  /**
39703   * Inject parameters from json configuration to widget
39704   * @param src Widget to inject
39705   */
39706  injectParametersToComponent(src, attributes = null) {
39707    this.parametersPromise.then((parameters) => {
39708      this.setProgressive(src, attributes);
39709      const mySrcParameters = this.getParameterFromSource(src);
39710      const widgetConfiguration = this.getComponentConfiguration(src, parameters);
39711      if (widgetConfiguration && widgetConfiguration !== null) {
39712        for (const singleParameter of widgetConfiguration.singleParameters) {
39713          if (singleParameter.Name !== "CallerName") {
39714            const srcParameter = mySrcParameters.find((data) => data.name.toLowerCase() === singleParameter.Name.toLowerCase());
39715            if (srcParameter !== void 0) {
39716              if (!srcParameter.isMultiple()) {
39717                src[singleParameter.Name] = singleParameter.getValue();
39718              }
39719            } else {
39720              console.log("Wigdet [" + src.CallerName + "], parameter [" + singleParameter.Name + "] found in configuration, but not present in attribute list");
39721            }
39722          }
39723        }
39724        mySrcParameters.forEach((srcParameter) => {
39725          if (!srcParameter.isMultiple()) {
39726            return;
39727          }
39728          for (const multipleParameter of widgetConfiguration.getMultipleParameters(srcParameter.name)) {
39729            const newParam = srcParameter.createChild();
39730            if (multipleParameter.singleParameters !== void 0 && newParam !== void 0) {
39731              multipleParameter.singleParameters.forEach((singleParameter) => {
39732                const res = Reflect.getMetadata("design:type", newParam.Instance, singleParameter.Name);
39733                if (res !== void 0 && res.name !== "Array") {
39734                  this.setAttributeValue(newParam.Instance, singleParameter.name, singleParameter.value);
39735                  return;
39736                }
39737              });
39738            }
39739          }
39740          src[srcParameter.name] = [];
39741          srcParameter.Children.forEach((child) => {
39742            src[srcParameter.name].push(child.Instance);
39743          });
39744        });
39745      }
39746      if (attributes !== null) {
39747        for (let i = 0; i < attributes.length; i++) {
39748          const attribute = attributes.item(i);
39749          if (attribute === null) {
39750            continue;
39751          }
39752          const srcAttributeName = mySrcParameters.find((data) => data.name.toLowerCase() === attribute.name.toLowerCase());
39753          if (srcAttributeName !== void 0) {
39754            if (srcAttributeName.isMultiple()) {
39755              this.createMultipleAttributeFromHTML(srcAttributeName, attribute.value);
39756              src[srcAttributeName.name] = [];
39757              srcAttributeName.Children.forEach((child) => {
39758                src[srcAttributeName.name].push(child.Instance);
39759              });
39760            } else {
39761              this.setAttributeValue(src, srcAttributeName.name, attribute.value);
39762            }
39763          } else {
39764            console.log("Wigdet [" + src.CallerName + "], parameter [" + attribute.name + "] found in HTML, but not present in attribute list");
39765          }
39766        }
39767      }
39768      src.onParameterInjectedFinished();
39769    });
39770  }
39771  createMultipleAttributeFromHTML(srcParameter, value) {
39772    if (value === null || value === void 0 || value === "") {
39773      return;
39774    }
39775    const parametersStr = value.split("\xA7");
39776    const child = new srcParameter.constructionObject();
39777    const elementParameters = this.getParameterFromSource(child);
39778    if (parametersStr.length % elementParameters.length !== 0) {
39779      console.error("Parameter " + srcParameter.name + " must contain " + parametersStr.length + " values or a multiple");
39780      return;
39781    }
39782    const n = parametersStr.length / elementParameters.length;
39783    srcParameter.emptyChildren();
39784    let valueCounter = 0;
39785    for (let i = 0; i < n; i++) {
39786      const newElement = srcParameter.createChild();
39787      elementParameters.forEach((srcParameterChild) => {
39788        this.setAttributeValue(newElement?.Instance, srcParameterChild.name, parametersStr[valueCounter]);
39789        valueCounter++;
39790      });
39791    }
39792  }
39793  /**
39794   * Get all decorated attributes from source
39795   * @param src Source object containing docorated attribute
39796   */
39797  getParameterFromSource(src, editableOnly = false) {
39798    const srcParameters = [];
39799    Object.getOwnPropertyNames(src).forEach((paramName) => {
39800      let isDoc = Reflect.getMetadata("DoraPropertyDOC", src, paramName);
39801      if (isDoc !== void 0 && isDoc == true) {
39802        if (editableOnly) {
39803          const editable = Reflect.getMetadata("DoraPropertyDOCEditable", src, paramName);
39804          if (!editable) {
39805            return;
39806          }
39807        }
39808      }
39809      let res = Reflect.getMetadata("DoraProperty", src, paramName);
39810      if (res !== void 0 && res == true) {
39811        const srcParameter = new SrcParameter(paramName);
39812        const descr = Reflect.getMetadata("DoraPropertyDOCDescr", src, paramName);
39813        srcParameter.descr = descr !== void 0 ? descr : "Generic description";
39814        const type = Reflect.getMetadata("DoraPropertyDOCType", src, paramName);
39815        srcParameter.type = type !== void 0 ? Number.parseInt(type) : ATTRIBUTE_TYPE.STRING;
39816        const values = Reflect.getMetadata("DoraPropertyDOCValues", src, paramName);
39817        srcParameter.values = values !== void 0 && values !== "" ? values.split("\xA7") : [];
39818        const attributeDataProviderValues = Reflect.getMetadata("DoraPropertyDOCAttributeDataProviderValues", src, paramName);
39819        srcParameter.dataProviderValueType = attributeDataProviderValues !== void 0 ? Number.parseInt(attributeDataProviderValues) : ATTRIBUTE_DATAPROVIDER_VALUES.NONE;
39820        const highChartPath = Reflect.getMetadata("DoraPropertyDOCHighChartPath", src, paramName);
39821        srcParameter.HighChartPath = highChartPath !== void 0 ? highChartPath : "";
39822        srcParameters.push(srcParameter);
39823        return;
39824      }
39825      res = Reflect.getMetadata("DoraPropertyArray", src, paramName);
39826      if (res !== void 0) {
39827        const srcParameter = new SrcParameter(paramName);
39828        srcParameter.constructionObject = res;
39829        srcParameter.setMultiple(this);
39830        srcParameters.push(srcParameter);
39831        const type = Reflect.getMetadata("DoraPropertyDOCType", src, paramName);
39832        srcParameter.type = type !== void 0 ? Number.parseInt(type) : ATTRIBUTE_TYPE.ARRAY;
39833        if (isDoc !== void 0 && isDoc == true) {
39834          const descr = Reflect.getMetadata("DoraPropertyDOCDescr", src, paramName);
39835          srcParameter.descr = descr !== void 0 ? descr : "Generic description";
39836          const highChartPath = Reflect.getMetadata("DoraPropertyDOCHighChartPath", src, paramName);
39837          srcParameter.HighChartPath = highChartPath !== void 0 ? highChartPath : "";
39838        }
39839      }
39840    });
39841    return srcParameters;
39842  }
39843  setAttributeValue(src, attributeName, attributeValue) {
39844    if (attributeName !== null && attributeName !== void 0 && attributeValue !== void 0) {
39845      switch (typeof src[attributeName]) {
39846        case "number":
39847          src[attributeName] = Number(attributeValue);
39848          break;
39849        case "boolean":
39850          src[attributeName] = attributeValue.toLowerCase() === "true" ? true : false;
39851          break;
39852        case "string":
39853          src[attributeName] = attributeValue;
39854          break;
39855        default:
39856          console.log("Attribute type not handled: " + typeof src[attributeName] + " Attribute: " + attributeName);
39857      }
39858    }
39859  }
39860  /**
39861   * Read Component configuration widget or publisher
39862   * @param src widget component
39863   * @param compType component type eg. Widgets, Publishers
39864   * @param parameters complete parameters
39865   */
39866  getComponentConfiguration(src, parameters) {
39867    const multipleParameters = parameters.getMultipleParameter(ComponentType[src.CallerType]);
39868    if (multipleParameters === void 0 || multipleParameters.multipleParameters == null) {
39869      console.error("Component type " + ComponentType[src.CallerType] + " not found in AppConfiguration");
39870      return new MultipleParameter();
39871    }
39872    return multipleParameters.multipleParameters.find((x) => {
39873      if (x.name === src.CallerSubType) {
39874        const progressiveParameter = x.getSingleParameter("Progressive");
39875        if (progressiveParameter != null && progressiveParameter.getValueString() === src.CallerProgressive) {
39876          return true;
39877        }
39878      }
39879      return false;
39880    });
39881  }
39882  setProgressive(src, attributes) {
39883    if (attributes !== null) {
39884      for (let i = 0; i < attributes.length; i++) {
39885        const attribute = attributes.item(i);
39886        if (attribute === null) {
39887          continue;
39888        }
39889        if (attribute.name.toLowerCase() === "progressive") {
39890          src.setCallerProgressive(attribute.value);
39891        }
39892      }
39893    }
39894  }
39895  readHighChartDoc() {
39896    return this.http.get(extGetAppConfigurationPath() + "/HighChartDoc.json").pipe(map((response) => {
39897      return response;
39898    }), catchError((error) => {
39899      console.error("Error reading HighChartDoc");
39900      return of(null);
39901    }));
39902  }
39903  static {
39904    this.\u0275fac = function ConfigurationService_Factory(__ngFactoryType__) {
39905      return new (__ngFactoryType__ || _ConfigurationService)(\u0275\u0275inject(HttpClient), \u0275\u0275inject(ScScoreReCaptcha));
39906    };
39907  }
39908  static {
39909    this.\u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({ token: _ConfigurationService, factory: _ConfigurationService.\u0275fac, providedIn: "root" });
39910  }
39911};
39912
39913// src/app/publisher/publisher.service.ts
39914var PublisherService = class _PublisherService {
39915  constructor(configurationService) {
39916    this.configurationService = configurationService;
39917    this.publisherToInitialize = 0;
39918  }
39919  initialize(caller) {
39920    this.caller = caller;
39921    this.configurationService.loadPublisher(this);
39922  }
39923  /**
39924   * Publishers loaded
39925   * @param publishers array of publishers. Already initialized
39926   */
39927  onPublisherLoaded(publishers) {
39928    this.publishers = publishers;
39929    this.publisherToInitialize = this.publishers.length;
39930    this.publishers.forEach((publisher) => {
39931      publisher.initialize(this, this.configurationService);
39932    });
39933  }
39934  onPublisherInitialized() {
39935    this.publisherToInitialize--;
39936    if (this.publisherToInitialize === 0) {
39937      if (this.caller === void 0) {
39938        throw new Error("Caller not set");
39939      }
39940      this.caller.onPublisherServiceInitialized();
39941    }
39942  }
39943  getPublisher(publisherNumber = 0) {
39944    if (this.publishers === void 0) {
39945      throw new Error("Publishers not loaded");
39946    }
39947    if (this.publishers.length > publisherNumber + 1) {
39948      publisherNumber = 0;
39949    }
39950    return this.publishers[publisherNumber];
39951  }
39952  static {
39953    this.\u0275fac = function PublisherService_Factory(__ngFactoryType__) {
39954      return new (__ngFactoryType__ || _PublisherService)(\u0275\u0275inject(ConfigurationService));
39955    };
39956  }
39957  static {
39958    this.\u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({ token: _PublisherService, factory: _PublisherService.\u0275fac, providedIn: "root" });
39959  }
39960};
39961
39962// src/app/DoraWidget/widget-base/data/publisher-parameter.ts
39963var PublisherParameter = class {
39964  constructor() {
39965    this.name = "";
39966    this.value = "";
39967  }
39968};
39969__decorate([
39970  DoraPropertyDOC("Nome attributo specifico del publisher", ATTRIBUTE_TYPE.STRING, "xlsxid", ATTRIBUTE_DATAPROVIDER_VALUES.NONE),
39971  DoraProperty,
39972  __metadata("design:type", String)
39973], PublisherParameter.prototype, "name", void 0);
39974__decorate([
39975  DoraPropertyDOC("Valore ", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.EXCEL_LIST),
39976  DoraProperty,
39977  __metadata("design:type", String)
39978], PublisherParameter.prototype, "value", void 0);
39979
vendor: 34,653 bytes, lines 39980-41095
39980// node_modules/@ngx-translate/core/fesm2022/ngx-translate-core.mjs
39981var TranslateLoader = class {
39982};
39983var TranslateFakeLoader = class _TranslateFakeLoader extends TranslateLoader {
39984  getTranslation(lang) {
39985    return of({});
39986  }
39987  static \u0275fac = /* @__PURE__ */ (() => {
39988    let \u0275TranslateFakeLoader_BaseFactory;
39989    return function TranslateFakeLoader_Factory(__ngFactoryType__) {
39990      return (\u0275TranslateFakeLoader_BaseFactory || (\u0275TranslateFakeLoader_BaseFactory = \u0275\u0275getInheritedFactory(_TranslateFakeLoader)))(__ngFactoryType__ || _TranslateFakeLoader);
39991    };
39992  })();
39993  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
39994    token: _TranslateFakeLoader,
39995    factory: _TranslateFakeLoader.\u0275fac
39996  });
39997};
39998(() => {
39999  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(TranslateFakeLoader, [{
40000    type: Injectable
40001  }], null, null);
40002})();
40003var MissingTranslationHandler = class {
40004};
40005var FakeMissingTranslationHandler = class _FakeMissingTranslationHandler {
40006  handle(params) {
40007    return params.key;
40008  }
40009  static \u0275fac = function FakeMissingTranslationHandler_Factory(__ngFactoryType__) {
40010    return new (__ngFactoryType__ || _FakeMissingTranslationHandler)();
40011  };
40012  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
40013    token: _FakeMissingTranslationHandler,
40014    factory: _FakeMissingTranslationHandler.\u0275fac
40015  });
40016};
40017(() => {
40018  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(FakeMissingTranslationHandler, [{
40019    type: Injectable
40020  }], null, null);
40021})();
40022function equals(o1, o2) {
40023  if (o1 === o2) return true;
40024  if (o1 === null || o2 === null) return false;
40025  if (o1 !== o1 && o2 !== o2) return true;
40026  const t1 = typeof o1, t2 = typeof o2;
40027  let length, key, keySet;
40028  if (t1 == t2 && t1 == "object") {
40029    if (Array.isArray(o1)) {
40030      if (!Array.isArray(o2)) return false;
40031      if ((length = o1.length) == o2.length) {
40032        for (key = 0; key < length; key++) {
40033          if (!equals(o1[key], o2[key])) return false;
40034        }
40035        return true;
40036      }
40037    } else {
40038      if (Array.isArray(o2)) {
40039        return false;
40040      }
40041      keySet = /* @__PURE__ */ Object.create(null);
40042      for (key in o1) {
40043        if (!equals(o1[key], o2[key])) {
40044          return false;
40045        }
40046        keySet[key] = true;
40047      }
40048      for (key in o2) {
40049        if (!(key in keySet) && typeof o2[key] !== "undefined") {
40050          return false;
40051        }
40052      }
40053      return true;
40054    }
40055  }
40056  return false;
40057}
40058function isDefined(value) {
40059  return typeof value !== "undefined" && value !== null;
40060}
40061function isDict(value) {
40062  return isObject2(value) && !isArray(value) && value !== null;
40063}
40064function isObject2(value) {
40065  return typeof value === "object";
40066}
40067function isArray(value) {
40068  return Array.isArray(value);
40069}
40070function isString(value) {
40071  return typeof value === "string";
40072}
40073function isFunction(value) {
40074  return typeof value === "function";
40075}
40076function mergeDeep(target, source) {
40077  const output = Object.assign({}, target);
40078  if (!isObject2(target)) {
40079    return mergeDeep({}, source);
40080  }
40081  if (isObject2(target) && isObject2(source)) {
40082    Object.keys(source).forEach((key) => {
40083      if (isDict(source[key])) {
40084        if (key in target) {
40085          output[key] = mergeDeep(target[key], source[key]);
40086        } else {
40087          Object.assign(output, {
40088            [key]: source[key]
40089          });
40090        }
40091      } else {
40092        Object.assign(output, {
40093          [key]: source[key]
40094        });
40095      }
40096    });
40097  }
40098  return output;
40099}
40100function getValue(target, key) {
40101  const keys = key.split(".");
40102  key = "";
40103  do {
40104    key += keys.shift();
40105    if (isDefined(target) && isDefined(target[key]) && (isDict(target[key]) || isArray(target[key]) || !keys.length)) {
40106      target = target[key];
40107      key = "";
40108    } else if (!keys.length) {
40109      target = void 0;
40110    } else {
40111      key += ".";
40112    }
40113  } while (keys.length);
40114  return target;
40115}
40116function setValue(target, key, value) {
40117  const keys = key.split(".");
40118  let current = target;
40119  for (let i = 0; i < keys.length; i++) {
40120    const key2 = keys[i];
40121    if (i === keys.length - 1) {
40122      current[key2] = value;
40123    } else {
40124      if (!current[key2] || !isDict(current[key2])) {
40125        current[key2] = {};
40126      }
40127      current = current[key2];
40128    }
40129  }
40130}
40131var TranslateParser = class {
40132};
40133var TranslateDefaultParser = class _TranslateDefaultParser extends TranslateParser {
40134  templateMatcher = /{{\s?([^{}\s]*)\s?}}/g;
40135  interpolate(expr, params) {
40136    if (isString(expr)) {
40137      return this.interpolateString(expr, params);
40138    } else if (isFunction(expr)) {
40139      return this.interpolateFunction(expr, params);
40140    }
40141    return void 0;
40142  }
40143  interpolateFunction(fn, params) {
40144    return fn(params);
40145  }
40146  interpolateString(expr, params) {
40147    if (!params) {
40148      return expr;
40149    }
40150    return expr.replace(this.templateMatcher, (substring, b) => {
40151      const r = getValue(params, b);
40152      return isDefined(r) ? r : substring;
40153    });
40154  }
40155  static \u0275fac = /* @__PURE__ */ (() => {
40156    let \u0275TranslateDefaultParser_BaseFactory;
40157    return function TranslateDefaultParser_Factory(__ngFactoryType__) {
40158      return (\u0275TranslateDefaultParser_BaseFactory || (\u0275TranslateDefaultParser_BaseFactory = \u0275\u0275getInheritedFactory(_TranslateDefaultParser)))(__ngFactoryType__ || _TranslateDefaultParser);
40159    };
40160  })();
40161  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
40162    token: _TranslateDefaultParser,
40163    factory: _TranslateDefaultParser.\u0275fac
40164  });
40165};
40166(() => {
40167  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(TranslateDefaultParser, [{
40168    type: Injectable
40169  }], null, null);
40170})();
40171var TranslateCompiler = class {
40172};
40173var TranslateFakeCompiler = class _TranslateFakeCompiler extends TranslateCompiler {
40174  compile(value, lang) {
40175    return value;
40176  }
40177  compileTranslations(translations, lang) {
40178    return translations;
40179  }
40180  static \u0275fac = /* @__PURE__ */ (() => {
40181    let \u0275TranslateFakeCompiler_BaseFactory;
40182    return function TranslateFakeCompiler_Factory(__ngFactoryType__) {
40183      return (\u0275TranslateFakeCompiler_BaseFactory || (\u0275TranslateFakeCompiler_BaseFactory = \u0275\u0275getInheritedFactory(_TranslateFakeCompiler)))(__ngFactoryType__ || _TranslateFakeCompiler);
40184    };
40185  })();
40186  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
40187    token: _TranslateFakeCompiler,
40188    factory: _TranslateFakeCompiler.\u0275fac
40189  });
40190};
40191(() => {
40192  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(TranslateFakeCompiler, [{
40193    type: Injectable
40194  }], null, null);
40195})();
40196var TranslateStore = class {
40197  /**
40198   * The default lang to fallback when translations are missing on the current lang
40199   */
40200  defaultLang;
40201  /**
40202   * The lang currently used
40203   */
40204  currentLang = this.defaultLang;
40205  /**
40206   * a list of translations per lang
40207   */
40208  translations = {};
40209  /**
40210   * an array of langs
40211   */
40212  langs = [];
40213  /**
40214   * An EventEmitter to listen to translation change events
40215   * onTranslationChange.subscribe((params: TranslationChangeEvent) => {
40216     *     // do something
40217     * });
40218   */
40219  onTranslationChange = new EventEmitter();
40220  /**
40221   * An EventEmitter to listen to lang change events
40222   * onLangChange.subscribe((params: LangChangeEvent) => {
40223     *     // do something
40224     * });
40225   */
40226  onLangChange = new EventEmitter();
40227  /**
40228   * An EventEmitter to listen to default lang change events
40229   * onDefaultLangChange.subscribe((params: DefaultLangChangeEvent) => {
40230     *     // do something
40231     * });
40232   */
40233  onDefaultLangChange = new EventEmitter();
40234};
40235var ISOLATE_TRANSLATE_SERVICE = new InjectionToken("ISOLATE_TRANSLATE_SERVICE");
40236var USE_DEFAULT_LANG = new InjectionToken("USE_DEFAULT_LANG");
40237var DEFAULT_LANGUAGE = new InjectionToken("DEFAULT_LANGUAGE");
40238var USE_EXTEND = new InjectionToken("USE_EXTEND");
40239var makeObservable = (value) => {
40240  return isObservable(value) ? value : of(value);
40241};
40242var TranslateService = class _TranslateService {
40243  store;
40244  currentLoader;
40245  compiler;
40246  parser;
40247  missingTranslationHandler;
40248  useDefaultLang;
40249  extend;
40250  loadingTranslations;
40251  pending = false;
40252  _translationRequests = {};
40253  lastUseLanguage = null;
40254  /**
40255   * An EventEmitter to listen to translation change events
40256   * onTranslationChange.subscribe((params: TranslationChangeEvent) => {
40257     *     // do something
40258     * });
40259   */
40260  get onTranslationChange() {
40261    return this.store.onTranslationChange;
40262  }
40263  /**
40264   * An EventEmitter to listen to lang change events
40265   * onLangChange.subscribe((params: LangChangeEvent) => {
40266     *     // do something
40267     * });
40268   */
40269  get onLangChange() {
40270    return this.store.onLangChange;
40271  }
40272  /**
40273   * An EventEmitter to listen to default lang change events
40274   * onDefaultLangChange.subscribe((params: DefaultLangChangeEvent) => {
40275     *     // do something
40276     * });
40277   */
40278  get onDefaultLangChange() {
40279    return this.store.onDefaultLangChange;
40280  }
40281  /**
40282   * The default lang to fallback when translations are missing on the current lang
40283   */
40284  get defaultLang() {
40285    return this.store.defaultLang;
40286  }
40287  set defaultLang(defaultLang) {
40288    this.store.defaultLang = defaultLang;
40289  }
40290  /**
40291   * The lang currently used
40292   */
40293  get currentLang() {
40294    return this.store.currentLang;
40295  }
40296  set currentLang(currentLang) {
40297    this.store.currentLang = currentLang;
40298  }
40299  /**
40300   * an array of langs
40301   */
40302  get langs() {
40303    return this.store.langs;
40304  }
40305  set langs(langs) {
40306    this.store.langs = langs;
40307  }
40308  /**
40309   * a list of translations per lang
40310   */
40311  get translations() {
40312    return this.store.translations;
40313  }
40314  set translations(translations) {
40315    this.store.translations = translations;
40316  }
40317  /**
40318   *
40319   * @param store an instance of the store (that is supposed to be unique)
40320   * @param currentLoader An instance of the loader currently used
40321   * @param compiler An instance of the compiler currently used
40322   * @param parser An instance of the parser currently used
40323   * @param missingTranslationHandler A handler for missing translations.
40324   * @param useDefaultLang whether we should use default language translation when current language translation is missing.
40325   * @param isolate whether this service should use the store or not
40326   * @param extend To make a child module extend (and use) translations from parent modules.
40327   * @param defaultLanguage Set the default language using configuration
40328   */
40329  constructor(store, currentLoader, compiler, parser2, missingTranslationHandler, useDefaultLang = true, isolate = false, extend4 = false, defaultLanguage) {
40330    this.store = store;
40331    this.currentLoader = currentLoader;
40332    this.compiler = compiler;
40333    this.parser = parser2;
40334    this.missingTranslationHandler = missingTranslationHandler;
40335    this.useDefaultLang = useDefaultLang;
40336    this.extend = extend4;
40337    if (isolate) {
40338      this.store = new TranslateStore();
40339    }
40340    if (defaultLanguage) {
40341      this.setDefaultLang(defaultLanguage);
40342    }
40343  }
40344  /**
40345   * Sets the default language to use as a fallback
40346   */
40347  setDefaultLang(lang) {
40348    if (lang === this.defaultLang) {
40349      return;
40350    }
40351    const pending = this.retrieveTranslations(lang);
40352    if (typeof pending !== "undefined") {
40353      if (this.defaultLang == null) {
40354        this.defaultLang = lang;
40355      }
40356      pending.pipe(take(1)).subscribe(() => {
40357        this.changeDefaultLang(lang);
40358      });
40359    } else {
40360      this.changeDefaultLang(lang);
40361    }
40362  }
40363  /**
40364   * Gets the default language used
40365   */
40366  getDefaultLang() {
40367    return this.defaultLang;
40368  }
40369  /**
40370   * Changes the lang currently used
40371   */
40372  use(lang) {
40373    this.lastUseLanguage = lang;
40374    if (lang === this.currentLang) {
40375      return of(this.translations[lang]);
40376    }
40377    if (!this.currentLang) {
40378      this.currentLang = lang;
40379    }
40380    const pending = this.retrieveTranslations(lang);
40381    if (isObservable(pending)) {
40382      pending.pipe(take(1)).subscribe(() => {
40383        this.changeLang(lang);
40384      });
40385      return pending;
40386    } else {
40387      this.changeLang(lang);
40388      return of(this.translations[lang]);
40389    }
40390  }
40391  /**
40392   * Changes the current lang
40393   */
40394  changeLang(lang) {
40395    if (lang !== this.lastUseLanguage) {
40396      return;
40397    }
40398    this.currentLang = lang;
40399    this.onLangChange.emit({
40400      lang,
40401      translations: this.translations[lang]
40402    });
40403    if (this.defaultLang == null) {
40404      this.changeDefaultLang(lang);
40405    }
40406  }
40407  /**
40408   * Retrieves the given translations
40409   */
40410  retrieveTranslations(lang) {
40411    if (typeof this.translations[lang] === "undefined" || this.extend) {
40412      this._translationRequests[lang] = this._translationRequests[lang] || this.loadAndCompileTranslations(lang);
40413      return this._translationRequests[lang];
40414    }
40415    return void 0;
40416  }
40417  /**
40418   * Gets an object of translations for a given language with the current loader
40419   * and passes it through the compiler
40420   *
40421   * @deprecated This function is meant for internal use. There should
40422   * be no reason to use outside this service. You can plug into this
40423   * functionality by using a customer TranslateLoader or TranslateCompiler.
40424   * To load a new language use setDefaultLang() and/or use()
40425   */
40426  getTranslation(lang) {
40427    return this.loadAndCompileTranslations(lang);
40428  }
40429  loadAndCompileTranslations(lang) {
40430    this.pending = true;
40431    const loadingTranslations = this.currentLoader.getTranslation(lang).pipe(shareReplay(1), take(1));
40432    this.loadingTranslations = loadingTranslations.pipe(map((res) => this.compiler.compileTranslations(res, lang)), shareReplay(1), take(1));
40433    this.loadingTranslations.subscribe({
40434      next: (res) => {
40435        this.translations[lang] = this.extend && this.translations[lang] ? __spreadValues(__spreadValues({}, res), this.translations[lang]) : res;
40436        this.updateLangs();
40437        this.pending = false;
40438      },
40439      error: (err) => {
40440        this.pending = false;
40441      }
40442    });
40443    return loadingTranslations;
40444  }
40445  /**
40446   * Manually sets an object of translations for a given language
40447   * after passing it through the compiler
40448   */
40449  setTranslation(lang, translations, shouldMerge = false) {
40450    const interpolatableTranslations = this.compiler.compileTranslations(translations, lang);
40451    if ((shouldMerge || this.extend) && this.translations[lang]) {
40452      this.translations[lang] = mergeDeep(this.translations[lang], interpolatableTranslations);
40453    } else {
40454      this.translations[lang] = interpolatableTranslations;
40455    }
40456    this.updateLangs();
40457    this.onTranslationChange.emit({
40458      lang,
40459      translations: this.translations[lang]
40460    });
40461  }
40462  /**
40463   * Returns an array of currently available langs
40464   */
40465  getLangs() {
40466    return this.langs;
40467  }
40468  /**
40469   * Add available languages
40470   */
40471  addLangs(langs) {
40472    const newLangs = langs.filter((lang) => !this.langs.includes(lang));
40473    if (newLangs.length > 0) {
40474      this.langs = [...this.langs, ...newLangs];
40475    }
40476  }
40477  /**
40478   * Update the list of available languages
40479   */
40480  updateLangs() {
40481    this.addLangs(Object.keys(this.translations));
40482  }
40483  getParsedResultForKey(translations, key, interpolateParams) {
40484    let res;
40485    if (translations) {
40486      res = this.runInterpolation(getValue(translations, key), interpolateParams);
40487    }
40488    if (res === void 0 && this.defaultLang != null && this.defaultLang !== this.currentLang && this.useDefaultLang) {
40489      res = this.runInterpolation(getValue(this.translations[this.defaultLang], key), interpolateParams);
40490    }
40491    if (res === void 0) {
40492      const params = {
40493        key,
40494        translateService: this
40495      };
40496      if (typeof interpolateParams !== "undefined") {
40497        params.interpolateParams = interpolateParams;
40498      }
40499      res = this.missingTranslationHandler.handle(params);
40500    }
40501    return res !== void 0 ? res : key;
40502  }
40503  runInterpolation(translations, interpolateParams) {
40504    if (isArray(translations)) {
40505      return translations.map((translation) => this.runInterpolation(translation, interpolateParams));
40506    } else if (isDict(translations)) {
40507      const result = {};
40508      for (const key in translations) {
40509        const res = this.runInterpolation(translations[key], interpolateParams);
40510        if (res !== void 0) {
40511          result[key] = res;
40512        }
40513      }
40514      return result;
40515    } else {
40516      return this.parser.interpolate(translations, interpolateParams);
40517    }
40518  }
40519  /**
40520   * Returns the parsed result of the translations
40521   */
40522  getParsedResult(translations, key, interpolateParams) {
40523    if (key instanceof Array) {
40524      const result = {};
40525      let observables = false;
40526      for (const k of key) {
40527        result[k] = this.getParsedResultForKey(translations, k, interpolateParams);
40528        observables = observables || isObservable(result[k]);
40529      }
40530      if (!observables) {
40531        return result;
40532      }
40533      const sources = key.map((k) => makeObservable(result[k]));
40534      return forkJoin(sources).pipe(map((arr) => {
40535        const obj = {};
40536        arr.forEach((value, index) => {
40537          obj[key[index]] = value;
40538        });
40539        return obj;
40540      }));
40541    }
40542    return this.getParsedResultForKey(translations, key, interpolateParams);
40543  }
40544  /**
40545   * Gets the translated value of a key (or an array of keys)
40546   * @returns the translated key, or an object of translated keys
40547   */
40548  get(key, interpolateParams) {
40549    if (!isDefined(key) || !key.length) {
40550      throw new Error(`Parameter "key" is required and cannot be empty`);
40551    }
40552    if (this.pending) {
40553      return this.loadingTranslations.pipe(concatMap((res) => {
40554        return makeObservable(this.getParsedResult(res, key, interpolateParams));
40555      }));
40556    }
40557    return makeObservable(this.getParsedResult(this.translations[this.currentLang], key, interpolateParams));
40558  }
40559  /**
40560   * Returns a stream of translated values of a key (or an array of keys) which updates
40561   * whenever the translation changes.
40562   * @returns A stream of the translated key, or an object of translated keys
40563   */
40564  getStreamOnTranslationChange(key, interpolateParams) {
40565    if (!isDefined(key) || !key.length) {
40566      throw new Error(`Parameter "key" is required and cannot be empty`);
40567    }
40568    return concat(defer(() => this.get(key, interpolateParams)), this.onTranslationChange.pipe(switchMap((event2) => {
40569      const res = this.getParsedResult(event2.translations, key, interpolateParams);
40570      return makeObservable(res);
40571    })));
40572  }
40573  /**
40574   * Returns a stream of translated values of a key (or an array of keys) which updates
40575   * whenever the language changes.
40576   * @returns A stream of the translated key, or an object of translated keys
40577   */
40578  stream(key, interpolateParams) {
40579    if (!isDefined(key) || !key.length) {
40580      throw new Error(`Parameter "key" required`);
40581    }
40582    return concat(defer(() => this.get(key, interpolateParams)), this.onLangChange.pipe(switchMap((event2) => {
40583      const res = this.getParsedResult(event2.translations, key, interpolateParams);
40584      return makeObservable(res);
40585    })));
40586  }
40587  /**
40588   * Returns a translation instantly from the internal state of loaded translation.
40589   * All rules regarding the current language, the preferred language of even fallback languages
40590   * will be used except any promise handling.
40591   */
40592  instant(key, interpolateParams) {
40593    if (!isDefined(key) || key.length === 0) {
40594      throw new Error('Parameter "key" is required and cannot be empty');
40595    }
40596    const result = this.getParsedResult(this.translations[this.currentLang], key, interpolateParams);
40597    if (isObservable(result)) {
40598      if (Array.isArray(key)) {
40599        return key.reduce((acc, currKey) => {
40600          acc[currKey] = currKey;
40601          return acc;
40602        }, {});
40603      }
40604      return key;
40605    }
40606    return result;
40607  }
40608  /**
40609   * Sets the translated value of a key, after compiling it
40610   */
40611  set(key, translation, lang = this.currentLang) {
40612    setValue(this.translations[lang], key, isString(translation) ? this.compiler.compile(translation, lang) : this.compiler.compileTranslations(translation, lang));
40613    this.updateLangs();
40614    this.onTranslationChange.emit({
40615      lang,
40616      translations: this.translations[lang]
40617    });
40618  }
40619  /**
40620   * Changes the default lang
40621   */
40622  changeDefaultLang(lang) {
40623    this.defaultLang = lang;
40624    this.onDefaultLangChange.emit({
40625      lang,
40626      translations: this.translations[lang]
40627    });
40628  }
40629  /**
40630   * Allows to reload the lang file from the file
40631   */
40632  reloadLang(lang) {
40633    this.resetLang(lang);
40634    return this.loadAndCompileTranslations(lang);
40635  }
40636  /**
40637   * Deletes inner translation
40638   */
40639  resetLang(lang) {
40640    delete this._translationRequests[lang];
40641    delete this.translations[lang];
40642  }
40643  /**
40644   * Returns the language code name from the browser, e.g. "de"
40645   */
40646  getBrowserLang() {
40647    if (typeof window === "undefined" || !window.navigator) {
40648      return void 0;
40649    }
40650    const browserLang = this.getBrowserCultureLang();
40651    return browserLang ? browserLang.split(/[-_]/)[0] : void 0;
40652  }
40653  /**
40654   * Returns the culture language code name from the browser, e.g. "de-DE"
40655   */
40656  getBrowserCultureLang() {
40657    if (typeof window === "undefined" || typeof window.navigator === "undefined") {
40658      return void 0;
40659    }
40660    return window.navigator.languages ? window.navigator.languages[0] : window.navigator.language || window.navigator.browserLanguage || window.navigator.userLanguage;
40661  }
40662  static \u0275fac = function TranslateService_Factory(__ngFactoryType__) {
40663    return new (__ngFactoryType__ || _TranslateService)(\u0275\u0275inject(TranslateStore), \u0275\u0275inject(TranslateLoader), \u0275\u0275inject(TranslateCompiler), \u0275\u0275inject(TranslateParser), \u0275\u0275inject(MissingTranslationHandler), \u0275\u0275inject(USE_DEFAULT_LANG), \u0275\u0275inject(ISOLATE_TRANSLATE_SERVICE), \u0275\u0275inject(USE_EXTEND), \u0275\u0275inject(DEFAULT_LANGUAGE));
40664  };
40665  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
40666    token: _TranslateService,
40667    factory: _TranslateService.\u0275fac,
40668    providedIn: "root"
40669  });
40670};
40671(() => {
40672  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(TranslateService, [{
40673    type: Injectable,
40674    args: [{
40675      providedIn: "root"
40676    }]
40677  }], () => [{
40678    type: TranslateStore
40679  }, {
40680    type: TranslateLoader
40681  }, {
40682    type: TranslateCompiler
40683  }, {
40684    type: TranslateParser
40685  }, {
40686    type: MissingTranslationHandler
40687  }, {
40688    type: void 0,
40689    decorators: [{
40690      type: Inject,
40691      args: [USE_DEFAULT_LANG]
40692    }]
40693  }, {
40694    type: void 0,
40695    decorators: [{
40696      type: Inject,
40697      args: [ISOLATE_TRANSLATE_SERVICE]
40698    }]
40699  }, {
40700    type: void 0,
40701    decorators: [{
40702      type: Inject,
40703      args: [USE_EXTEND]
40704    }]
40705  }, {
40706    type: void 0,
40707    decorators: [{
40708      type: Inject,
40709      args: [DEFAULT_LANGUAGE]
40710    }]
40711  }], null);
40712})();
40713var TranslateDirective = class _TranslateDirective {
40714  translateService;
40715  element;
40716  _ref;
40717  key;
40718  lastParams;
40719  currentParams;
40720  onLangChangeSub;
40721  onDefaultLangChangeSub;
40722  onTranslationChangeSub;
40723  set translate(key) {
40724    if (key) {
40725      this.key = key;
40726      this.checkNodes();
40727    }
40728  }
40729  set translateParams(params) {
40730    if (!equals(this.currentParams, params)) {
40731      this.currentParams = params;
40732      this.checkNodes(true);
40733    }
40734  }
40735  constructor(translateService, element, _ref) {
40736    this.translateService = translateService;
40737    this.element = element;
40738    this._ref = _ref;
40739    if (!this.onTranslationChangeSub) {
40740      this.onTranslationChangeSub = this.translateService.onTranslationChange.subscribe((event2) => {
40741        if (event2.lang === this.translateService.currentLang) {
40742          this.checkNodes(true, event2.translations);
40743        }
40744      });
40745    }
40746    if (!this.onLangChangeSub) {
40747      this.onLangChangeSub = this.translateService.onLangChange.subscribe((event2) => {
40748        this.checkNodes(true, event2.translations);
40749      });
40750    }
40751    if (!this.onDefaultLangChangeSub) {
40752      this.onDefaultLangChangeSub = this.translateService.onDefaultLangChange.subscribe((event2) => {
40753        this.checkNodes(true);
40754      });
40755    }
40756  }
40757  ngAfterViewChecked() {
40758    this.checkNodes();
40759  }
40760  checkNodes(forceUpdate = false, translations) {
40761    let nodes = this.element.nativeElement.childNodes;
40762    if (!nodes.length) {
40763      this.setContent(this.element.nativeElement, this.key);
40764      nodes = this.element.nativeElement.childNodes;
40765    }
40766    nodes.forEach((n) => {
40767      const node = n;
40768      if (node.nodeType === 3) {
40769        let key;
40770        if (forceUpdate) {
40771          node.lastKey = null;
40772        }
40773        if (isDefined(node.lookupKey)) {
40774          key = node.lookupKey;
40775        } else if (this.key) {
40776          key = this.key;
40777        } else {
40778          const content = this.getContent(node);
40779          const trimmedContent = content.trim();
40780          if (trimmedContent.length) {
40781            node.lookupKey = trimmedContent;
40782            if (content !== node.currentValue) {
40783              key = trimmedContent;
40784              node.originalContent = content || node.originalContent;
40785            } else if (node.originalContent) {
40786              key = node.originalContent.trim();
40787            }
40788          }
40789        }
40790        this.updateValue(key, node, translations);
40791      }
40792    });
40793  }
40794  updateValue(key, node, translations) {
40795    if (key) {
40796      if (node.lastKey === key && this.lastParams === this.currentParams) {
40797        return;
40798      }
40799      this.lastParams = this.currentParams;
40800      const onTranslation = (res) => {
40801        if (res !== key || !node.lastKey) {
40802          node.lastKey = key;
40803        }
40804        if (!node.originalContent) {
40805          node.originalContent = this.getContent(node);
40806        }
40807        node.currentValue = isDefined(res) ? res : node.originalContent || key;
40808        this.setContent(node, this.key ? node.currentValue : node.originalContent.replace(key, node.currentValue));
40809        this._ref.markForCheck();
40810      };
40811      if (isDefined(translations)) {
40812        const res = this.translateService.getParsedResult(translations, key, this.currentParams);
40813        if (isObservable(res)) {
40814          res.subscribe({
40815            next: onTranslation
40816          });
40817        } else {
40818          onTranslation(res);
40819        }
40820      } else {
40821        this.translateService.get(key, this.currentParams).subscribe(onTranslation);
40822      }
40823    }
40824  }
40825  getContent(node) {
40826    return isDefined(node.textContent) ? node.textContent : node.data;
40827  }
40828  setContent(node, content) {
40829    if (isDefined(node.textContent)) {
40830      node.textContent = content;
40831    } else {
40832      node.data = content;
40833    }
40834  }
40835  ngOnDestroy() {
40836    if (this.onLangChangeSub) {
40837      this.onLangChangeSub.unsubscribe();
40838    }
40839    if (this.onDefaultLangChangeSub) {
40840      this.onDefaultLangChangeSub.unsubscribe();
40841    }
40842    if (this.onTranslationChangeSub) {
40843      this.onTranslationChangeSub.unsubscribe();
40844    }
40845  }
40846  static \u0275fac = function TranslateDirective_Factory(__ngFactoryType__) {
40847    return new (__ngFactoryType__ || _TranslateDirective)(\u0275\u0275directiveInject(TranslateService), \u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(ChangeDetectorRef));
40848  };
40849  static \u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
40850    type: _TranslateDirective,
40851    selectors: [["", "translate", ""], ["", "ngx-translate", ""]],
40852    inputs: {
40853      translate: "translate",
40854      translateParams: "translateParams"
40855    }
40856  });
40857};
40858(() => {
40859  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(TranslateDirective, [{
40860    type: Directive,
40861    args: [{
40862      // eslint-disable-next-line @angular-eslint/directive-selector
40863      selector: "[translate],[ngx-translate]",
40864      standalone: true
40865    }]
40866  }], () => [{
40867    type: TranslateService
40868  }, {
40869    type: ElementRef
40870  }, {
40871    type: ChangeDetectorRef
40872  }], {
40873    translate: [{
40874      type: Input
40875    }],
40876    translateParams: [{
40877      type: Input
40878    }]
40879  });
40880})();
40881var TranslatePipe = class _TranslatePipe {
40882  translate;
40883  _ref;
40884  value = "";
40885  lastKey = null;
40886  lastParams = [];
40887  onTranslationChange;
40888  onLangChange;
40889  onDefaultLangChange;
40890  constructor(translate2, _ref) {
40891    this.translate = translate2;
40892    this._ref = _ref;
40893  }
40894  updateValue(key, interpolateParams, translations) {
40895    const onTranslation = (res) => {
40896      this.value = res !== void 0 ? res : key;
40897      this.lastKey = key;
40898      this._ref.markForCheck();
40899    };
40900    if (translations) {
40901      const res = this.translate.getParsedResult(translations, key, interpolateParams);
40902      if (isObservable(res)) {
40903        res.subscribe(onTranslation);
40904      } else {
40905        onTranslation(res);
40906      }
40907    }
40908    this.translate.get(key, interpolateParams).subscribe(onTranslation);
40909  }
40910  /* eslint-disable-next-line @typescript-eslint/no-explicit-any */
40911  transform(query, ...args) {
40912    if (!query || !query.length) {
40913      return query;
40914    }
40915    if (equals(query, this.lastKey) && equals(args, this.lastParams)) {
40916      return this.value;
40917    }
40918    let interpolateParams = void 0;
40919    if (isDefined(args[0]) && args.length) {
40920      if (isString(args[0]) && args[0].length) {
40921        const validArgs = args[0].replace(/(')?([a-zA-Z0-9_]+)(')?(\s)?:/g, '"$2":').replace(/:(\s)?(')(.*?)(')/g, ':"$3"');
40922        try {
40923          interpolateParams = JSON.parse(validArgs);
40924        } catch (e) {
40925          throw new SyntaxError(`Wrong parameter in TranslatePipe. Expected a valid Object, received: ${args[0]}`);
40926        }
40927      } else if (isDict(args[0])) {
40928        interpolateParams = args[0];
40929      }
40930    }
40931    this.lastKey = query;
40932    this.lastParams = args;
40933    this.updateValue(query, interpolateParams);
40934    this._dispose();
40935    if (!this.onTranslationChange) {
40936      this.onTranslationChange = this.translate.onTranslationChange.subscribe((event2) => {
40937        if (this.lastKey && event2.lang === this.translate.currentLang) {
40938          this.lastKey = null;
40939          this.updateValue(query, interpolateParams, event2.translations);
40940        }
40941      });
40942    }
40943    if (!this.onLangChange) {
40944      this.onLangChange = this.translate.onLangChange.subscribe((event2) => {
40945        if (this.lastKey) {
40946          this.lastKey = null;
40947          this.updateValue(query, interpolateParams, event2.translations);
40948        }
40949      });
40950    }
40951    if (!this.onDefaultLangChange) {
40952      this.onDefaultLangChange = this.translate.onDefaultLangChange.subscribe(() => {
40953        if (this.lastKey) {
40954          this.lastKey = null;
40955          this.updateValue(query, interpolateParams);
40956        }
40957      });
40958    }
40959    return this.value;
40960  }
40961  /**
40962   * Clean any existing subscription to change events
40963   */
40964  _dispose() {
40965    if (typeof this.onTranslationChange !== "undefined") {
40966      this.onTranslationChange.unsubscribe();
40967      this.onTranslationChange = void 0;
40968    }
40969    if (typeof this.onLangChange !== "undefined") {
40970      this.onLangChange.unsubscribe();
40971      this.onLangChange = void 0;
40972    }
40973    if (typeof this.onDefaultLangChange !== "undefined") {
40974      this.onDefaultLangChange.unsubscribe();
40975      this.onDefaultLangChange = void 0;
40976    }
40977  }
40978  ngOnDestroy() {
40979    this._dispose();
40980  }
40981  static \u0275fac = function TranslatePipe_Factory(__ngFactoryType__) {
40982    return new (__ngFactoryType__ || _TranslatePipe)(\u0275\u0275directiveInject(TranslateService, 16), \u0275\u0275directiveInject(ChangeDetectorRef, 16));
40983  };
40984  static \u0275pipe = /* @__PURE__ */ \u0275\u0275definePipe({
40985    name: "translate",
40986    type: _TranslatePipe,
40987    pure: false
40988  });
40989  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
40990    token: _TranslatePipe,
40991    factory: _TranslatePipe.\u0275fac
40992  });
40993};
40994(() => {
40995  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(TranslatePipe, [{
40996    type: Injectable
40997  }, {
40998    type: Pipe,
40999    args: [{
41000      name: "translate",
41001      standalone: true,
41002      pure: false
41003      // required to update the value when the promise is resolved
41004    }]
41005  }], () => [{
41006    type: TranslateService
41007  }, {
41008    type: ChangeDetectorRef
41009  }], null);
41010})();
41011var TranslateModule = class _TranslateModule {
41012  /**
41013   * Use this method in your root module to provide the TranslateService
41014   */
41015  static forRoot(config = {}) {
41016    return {
41017      ngModule: _TranslateModule,
41018      providers: [config.loader || {
41019        provide: TranslateLoader,
41020        useClass: TranslateFakeLoader
41021      }, config.compiler || {
41022        provide: TranslateCompiler,
41023        useClass: TranslateFakeCompiler
41024      }, config.parser || {
41025        provide: TranslateParser,
41026        useClass: TranslateDefaultParser
41027      }, config.missingTranslationHandler || {
41028        provide: MissingTranslationHandler,
41029        useClass: FakeMissingTranslationHandler
41030      }, TranslateStore, {
41031        provide: ISOLATE_TRANSLATE_SERVICE,
41032        useValue: config.isolate
41033      }, {
41034        provide: USE_DEFAULT_LANG,
41035        useValue: config.useDefaultLang
41036      }, {
41037        provide: USE_EXTEND,
41038        useValue: config.extend
41039      }, {
41040        provide: DEFAULT_LANGUAGE,
41041        useValue: config.defaultLanguage
41042      }, TranslateService]
41043    };
41044  }
41045  /**
41046   * Use this method in your other (non-root) modules to import the directive/pipe
41047   */
41048  static forChild(config = {}) {
41049    return {
41050      ngModule: _TranslateModule,
41051      providers: [config.loader || {
41052        provide: TranslateLoader,
41053        useClass: TranslateFakeLoader
41054      }, config.compiler || {
41055        provide: TranslateCompiler,
41056        useClass: TranslateFakeCompiler
41057      }, config.parser || {
41058        provide: TranslateParser,
41059        useClass: TranslateDefaultParser
41060      }, config.missingTranslationHandler || {
41061        provide: MissingTranslationHandler,
41062        useClass: FakeMissingTranslationHandler
41063      }, {
41064        provide: ISOLATE_TRANSLATE_SERVICE,
41065        useValue: config.isolate
41066      }, {
41067        provide: USE_DEFAULT_LANG,
41068        useValue: config.useDefaultLang
41069      }, {
41070        provide: USE_EXTEND,
41071        useValue: config.extend
41072      }, {
41073        provide: DEFAULT_LANGUAGE,
41074        useValue: config.defaultLanguage
41075      }, TranslateService]
41076    };
41077  }
41078  static \u0275fac = function TranslateModule_Factory(__ngFactoryType__) {
41079    return new (__ngFactoryType__ || _TranslateModule)();
41080  };
41081  static \u0275mod = /* @__PURE__ */ \u0275\u0275defineNgModule({
41082    type: _TranslateModule
41083  });
41084  static \u0275inj = /* @__PURE__ */ \u0275\u0275defineInjector({});
41085};
41086(() => {
41087  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(TranslateModule, [{
41088    type: NgModule,
41089    args: [{
41090      imports: [TranslatePipe, TranslateDirective],
41091      exports: [TranslatePipe, TranslateDirective]
41092    }]
41093  }], null, null);
41094})();
41095
41096// src/app/TranslationMarkers/translation.service.ts
41097var TranslationService = class _TranslationService {
41098  constructor(translate2) {
41099    this.translate = translate2;
41100    this.vocabolary = null;
41101    this.locale = DoraGetLocale();
41102    this.translate.setDefaultLang(this.locale);
41103  }
41104  initialize(caller) {
41105    this.caller = caller;
41106    this.translate.getTranslation(this.locale).subscribe((res) => {
41107      this.vocabolary = res;
41108      this.caller.onTranslationInitialized();
41109    });
41110  }
41111  /**
41112   * Get the translation of a key. If not exist return the key.
41113   * @param key string to translate
41114   */
41115  get(key) {
41116    const result = this.vocabolary[key];
41117    if (result === void 0) {
41118      return key;
41119    }
41120    return result;
41121  }
41122  /**
41123   * Get the translation of a key. If not exist return the default value.
41124   */
41125  getWithDefault(key, defaultValue) {
41126    const result = this.vocabolary[key];
41127    if (result === void 0) {
41128      return defaultValue;
41129    }
41130    return result;
41131  }
41132  /**
41133   * Check if the key exist in the translation file
41134   */
41135  keyExist(key) {
41136    return this.vocabolary[key] !== void 0;
41137  }
41138  /**
41139   * Get the translation of a key and replace %ph% placeholder with the provided value
41140   * @param key string to translate
41141   * @param placeHolderValue value to replace %ph% with
41142   */
41143  translateWithPlaceHolder(key, placeHolderValue) {
41144    let result = this.get(key);
41145    if (placeHolderValue !== null && placeHolderValue !== void 0) {
41146      result = result.replace(/%ph%/g, String(placeHolderValue));
41147    }
41148    return result;
41149  }
41150  static {
41151    this.\u0275fac = function TranslationService_Factory(__ngFactoryType__) {
41152      return new (__ngFactoryType__ || _TranslationService)(\u0275\u0275inject(TranslateService));
41153    };
41154  }
41155  static {
41156    this.\u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({ token: _TranslationService, factory: _TranslationService.\u0275fac, providedIn: "root" });
41157  }
41158};
41159
41160// src/app/DoraWidget/widget-base/widget-base.component.ts
41161var WidgetBaseComponent = class _WidgetBaseComponent {
41162  constructor(elementRef, messageService, configurationService, publisher, widgetService, http, translationService) {
41163    this.elementRef = elementRef;
41164    this.messageService = messageService;
41165    this.configurationService = configurationService;
41166    this.publisher = publisher;
41167    this.widgetService = widgetService;
41168    this.http = http;
41169    this.translationService = translationService;
41170    this.progressive = "1";
41171    this.EventChannel = "1";
41172    this.publischerNumber = 0;
41173    this.publisherParameters = [];
41174    this.settingEnabled = false;
41175    this._widgetName = "WIDGET UNDEFINED";
41176    this.appComponent = void 0;
41177    this.externalTagSelector = "";
41178    this.locale = DoraGetLocale();
41179  }
41180  ngOnInit() {
41181    this._widgetType = this.constructor.name;
41182    this.configurationService.injectParametersToComponent(this, this.elementRef.nativeElement.parentElement.attributes);
41183  }
41184  onParameterInjectedFinished() {
41185    this._widgetName = this._widgetType + this.progressive;
41186    this.widgetService.addWidget(this);
41187    this.elementRef.nativeElement.parentElement.setAttribute("id", this._widgetName);
41188    console.log("Init: Base. Widget: " + this._widgetName);
41189  }
41190  onEnableSetting() {
41191    if (this.appComponent !== void 0) {
41192      this.appComponent.runConfiguration(this._widgetName);
41193    }
41194  }
41195  onRefresh() {
41196    this._widgetName = this._widgetType + this.progressive;
41197  }
41198  get widgetType() {
41199    return this._widgetType;
41200  }
41201  get widgetName() {
41202    return this._widgetName;
41203  }
41204  // IConfigurationCaller methods
41205  // @ts-ignore
41206  get CallerSubType() {
41207    return this._widgetType;
41208  }
41209  // @ts-ignore
41210  get CallerName() {
41211    return this._widgetName;
41212  }
41213  get CallerProgressive() {
41214    return this.progressive;
41215  }
41216  get CallerType() {
41217    return ComponentType.Widgets;
41218  }
41219  get PublisherParameters() {
41220    return this.publisherParameters;
41221  }
41222  setCallerProgressive(progressive) {
41223    this.progressive = progressive;
41224    this._widgetName = this._widgetType + this.progressive;
41225  }
41226  /**
41227   * Build unique element id
41228   * @param elementId
41229   * @returns
41230   */
41231  buildUniqueElementId(elementId) {
41232    let uniqueElementId = this._widgetName + "-" + elementId;
41233    return uniqueElementId;
41234  }
41235  // Publisher operations
41236  /**
41237   * Resetta il publisher configurato
41238   */
41239  publisherReset() {
41240    const publisher = this.publisher.getPublisher(this.publischerNumber);
41241    publisher.reset();
41242  }
41243  /**
41244   *
41245   * @param subscribeObjInfo
41246   * @param dataType
41247   * @param publisherParameters
41248   * @param callerData
41249   */
41250  // tslint:disable-next-line:ban-types max-line-length
41251  // @ts-ignore
41252  read(subscribeObjInfo, dataType, publisherParameters = null, callerData = null) {
41253    const publisher = this.publisher.getPublisher(this.publischerNumber);
41254    const attributesHtml = this.elementRef.nativeElement.parentElement.attributes;
41255    const rewritableParameters = publisher.getRewritableParameterMap();
41256    const keys = [];
41257    rewritableParameters.forEach((value, key) => {
41258      keys.push(key);
41259    });
41260    keys.forEach((key) => {
41261      const attribute = attributesHtml.getNamedItem(key.toLowerCase());
41262      if (attribute !== null) {
41263        rewritableParameters.set(key, attribute.value);
41264      }
41265    });
41266    if (publisherParameters !== null) {
41267      publisherParameters.forEach((value, key) => {
41268        rewritableParameters.set(key, value);
41269      });
41270    } else {
41271      this.publisherParameters.forEach((value) => {
41272        rewritableParameters.set(value.name, value.value);
41273      });
41274    }
41275    return publisher.read(rewritableParameters, subscribeObjInfo, dataType, callerData);
41276  }
41277  setAppComponent(appComponent) {
41278    this.appComponent = appComponent;
41279  }
41280  setExternalTagSelector(tagSelector) {
41281    this.externalTagSelector = tagSelector;
41282  }
41283  get ExternalTagSelector() {
41284    return this.externalTagSelector;
41285  }
41286  /**
41287   * Read publisher parameters in Map format
41288   */
41289  getPublisherParameters(publisherParameters) {
41290    const result = /* @__PURE__ */ new Map();
41291    publisherParameters.forEach((value) => {
41292      result.set(value.name, value.value);
41293    });
41294    return result;
41295  }
41296  static {
41297    this.\u0275fac = function WidgetBaseComponent_Factory(__ngFactoryType__) {
41298      return new (__ngFactoryType__ || _WidgetBaseComponent)(\u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(MessageService), \u0275\u0275directiveInject(ConfigurationService), \u0275\u0275directiveInject(PublisherService), \u0275\u0275directiveInject(WidgetService), \u0275\u0275directiveInject(HttpClient), \u0275\u0275directiveInject(TranslationService));
41299    };
41300  }
41301  static {
41302    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _WidgetBaseComponent, selectors: [["dora-widget-base"]], standalone: false, decls: 0, vars: 0, template: function WidgetBaseComponent_Template(rf, ctx) {
41303    }, encapsulation: 2 });
41304  }
41305};
41306__decorate([
41307  DoraPropertyDOC("Progessivo del widget. TipoWidget+Progessivo rappresenta l'ID", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
41308  DoraProperty,
41309  __metadata("design:type", String)
41310], WidgetBaseComponent.prototype, "progressive", void 0);
41311__decorate([
41312  DoraPropertyDOC("ID canale di comunicazione per inviare/ricevere messaggi", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
41313  DoraProperty,
41314  __metadata("design:type", String)
41315], WidgetBaseComponent.prototype, "EventChannel", void 0);
41316__decorate([
41317  DoraPropertyDOC("Numero del publisher (rispetto a AppConfiguration.json)", ATTRIBUTE_TYPE.INTEGER, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE),
41318  DoraProperty,
41319  __metadata("design:type", Number)
41320], WidgetBaseComponent.prototype, "publischerNumber", void 0);
41321__decorate([
41322  DoraPropertyDOC("Parametri del publisher", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
41323  DoraPropertyArray(PublisherParameter),
41324  __metadata("design:type", Array)
41325], WidgetBaseComponent.prototype, "publisherParameters", void 0);
41326__decorate([
41327  DoraPropertyDOC("Abilita/disabilita il setting dei parametri del widget", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE),
41328  DoraProperty,
41329  __metadata("design:type", Boolean)
41330], WidgetBaseComponent.prototype, "settingEnabled", void 0);
41331(() => {
41332  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(WidgetBaseComponent, { className: "WidgetBaseComponent", filePath: "src/app/dorawidget/widget-base/widget-base.component.ts", lineNumber: 29 });
41333})();
41334
41335// src/app/TranslationMarkers/TranslationMarkers.ts
41336function _TRANSLATE(src) {
41337  return src;
41338}
41339
41340// src/app/DoraWidget/dora-label/data/label-link.ts
41341var LabelLink = class {
41342  constructor() {
41343    this.language = "";
41344    this.linkWithPlaceholder = "";
41345    this.placeholders = /* @__PURE__ */ new Map();
41346  }
41347  get link() {
41348    if (this._link === void 0) {
41349      this._link = this.linkWithPlaceholder;
41350    }
41351    return this._link;
41352  }
41353  setPlaceholder(name, value) {
41354    this.placeholders.set(name, value);
41355    this.rebuildLink();
41356  }
41357  rebuildLink() {
41358    this._link = this.linkWithPlaceholder;
41359    this.placeholders.forEach((value, key) => {
41360      if (this._link === void 0) {
41361        return;
41362      }
41363      this._link = this._link.replace(key, value);
41364    });
41365  }
41366};
41367__decorate([
41368  DoraProperty,
41369  __metadata("design:type", String)
41370], LabelLink.prototype, "language", void 0);
41371__decorate([
41372  DoraProperty,
41373  __metadata("design:type", String)
41374], LabelLink.prototype, "linkWithPlaceholder", void 0);
41375
41376// src/app/messages/message-base.ts
41377var MessageBase = class {
41378  constructor(messageType) {
41379    this._type = messageType.name;
41380  }
41381  get type() {
41382    return this._type;
41383  }
41384};
41385
41386// src/app/messages/message-grid-selected.ts
41387var MessageGridSelected = class _MessageGridSelected extends MessageBase {
41388  constructor(idGrid, description) {
41389    super(_MessageGridSelected);
41390    this._idGrid = idGrid;
41391    this._description = description;
41392  }
41393  get idGrid() {
41394    return this._idGrid;
41395  }
41396  get description() {
41397    return this._description;
41398  }
41399};
41400
41401// src/app/messages/message-rows-selected.ts
41402var MessageRowsSelected = class _MessageRowsSelected extends MessageBase {
41403  constructor(dataRows, fixedSeriesInfos = [], publisherParameters = []) {
41404    super(_MessageRowsSelected);
41405    this.fixedSeriesInfos = [];
41406    this.publisherParameters = [];
41407    this.dataRows = dataRows;
41408    this.fixedSeriesInfos = fixedSeriesInfos;
41409    this.publisherParameters = publisherParameters;
41410  }
41411  get DataRows() {
41412    return this.dataRows;
41413  }
41414  get PublisherParameters() {
41415    return this.publisherParameters;
41416  }
41417  get FixedSeriesInfos() {
41418    return this.fixedSeriesInfos;
41419  }
41420};
41421
41422// src/app/DoraWidget/dora-label/dora-label.component.ts
41423var DoraLabelComponent = class _DoraLabelComponent extends WidgetBaseComponent {
41424  constructor() {
41425    super(...arguments);
41426    this.textId = _TRANSLATE("label_text");
41427    this.text = "";
41428    this.labelLinks = [];
41429  }
41430  onParameterInjectedFinished() {
41431    super.onParameterInjectedFinished();
41432    this.text = this.translationService.get(this.textId);
41433    this.labelLink = this.labelLinks.find((labelLink) => labelLink.language === this.locale);
41434    if (this.labelLink !== void 0 && this.CallerName !== void 0) {
41435      this.messageService.getMessage(this.EventChannel, MessageGridSelected, this.CallerName).subscribe((doraMessage) => {
41436        this.labelLink.setPlaceholder("[GRID]", doraMessage.data.idGrid);
41437      });
41438      this.messageService.getMessage(this.EventChannel, MessageRowsSelected, this.CallerName).subscribe((doraMessage) => {
41439        let flFirst = true;
41440        let value = "";
41441        doraMessage.data.DataRows.forEach((dataRow) => {
41442          if (flFirst) {
41443            flFirst = false;
41444          } else {
41445            value += "%2f%2f";
41446          }
41447          value += dataRow.Id;
41448        });
41449        this.labelLink.setPlaceholder("[ROWS]", value);
41450      });
41451    }
41452  }
41453  getClass() {
41454    let cssClass = "text-container";
41455    if (this.labelLink !== void 0) {
41456      cssClass += " link";
41457    }
41458    return cssClass;
41459  }
41460  onClick() {
41461    if (this.labelLink !== void 0) {
41462      if (typeof window !== "undefined" && window.open && typeof window.open === "function") {
41463        window.open(this.labelLink.link, "_blank");
41464      } else {
41465        const link2 = document.createElement("a");
41466        link2.href = this.labelLink.link;
41467        link2.target = "_blank";
41468        link2.rel = "noopener noreferrer";
41469        document.body.appendChild(link2);
41470        link2.click();
41471        document.body.removeChild(link2);
41472      }
41473    }
41474  }
41475  static {
41476    this.\u0275fac = /* @__PURE__ */ (() => {
41477      let \u0275DoraLabelComponent_BaseFactory;
41478      return function DoraLabelComponent_Factory(__ngFactoryType__) {
41479        return (\u0275DoraLabelComponent_BaseFactory || (\u0275DoraLabelComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraLabelComponent)))(__ngFactoryType__ || _DoraLabelComponent);
41480      };
41481    })();
41482  }
41483  static {
41484    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraLabelComponent, selectors: [["dora-label"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 2, vars: 3, consts: [[1, "DAG-Label"], [3, "click", "innerHTML"]], template: function DoraLabelComponent_Template(rf, ctx) {
41485      if (rf & 1) {
41486        \u0275\u0275elementStart(0, "div", 0)(1, "div", 1);
41487        \u0275\u0275listener("click", function DoraLabelComponent_Template_div_click_1_listener() {
41488          return ctx.onClick();
41489        });
41490        \u0275\u0275elementEnd()();
41491      }
41492      if (rf & 2) {
41493        \u0275\u0275advance();
41494        \u0275\u0275classMap(ctx.getClass());
41495        \u0275\u0275property("innerHTML", ctx.text, \u0275\u0275sanitizeHtml);
41496      }
41497    }, styles: ["\n\np[_ngcontent-%COMP%] {\n  color: lime;\n}"] });
41498  }
41499};
41500__decorate([
41501  DoraProperty,
41502  __metadata("design:type", String)
41503], DoraLabelComponent.prototype, "textId", void 0);
41504__decorate([
41505  DoraPropertyArray(LabelLink),
41506  __metadata("design:type", Array)
41507], DoraLabelComponent.prototype, "labelLinks", void 0);
41508(() => {
41509  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraLabelComponent, { className: "DoraLabelComponent", filePath: "src/app/dorawidget/dora-label/dora-label.component.ts", lineNumber: 15 });
41510})();
41511
41512// src/app/DoraWidget/dora-row/data/column.ts
41513var Column = class {
41514  constructor() {
41515    this.unitSx = "";
41516    this.name = "";
41517    this.unitDx = "";
41518    this.numberFormatter = "###,###,###,###.#";
41519    this._valueStr = "";
41520    this._finalValueNumber = 0;
41521    this._currentValue = null;
41522    this._numberOfSteps = 10;
41523    this.step = 100;
41524    this._translationService = null;
41525    this._tooltipVisible = false;
41526  }
41527  get tooltipVisible() {
41528    return this._tooltipVisible;
41529  }
41530  set tooltipVisible(value) {
41531    this._tooltipVisible = value;
41532  }
41533  set translationService(value) {
41534    this._translationService = value;
41535  }
41536  get numberOfSteps() {
41537    return this._numberOfSteps;
41538  }
41539  set numberOfSteps(value) {
41540    this._numberOfSteps = value;
41541    if (this.finalValueNumber !== 0) {
41542      this.step = Math.abs(this.finalValueNumber) / value;
41543    }
41544  }
41545  get Name() {
41546    return this.name;
41547  }
41548  get TranslatedName() {
41549    if (this._translationService !== null) {
41550      return this._translationService.get(this.name);
41551    }
41552    return this.name;
41553  }
41554  get valueStr() {
41555    return this._valueStr;
41556  }
41557  set valueStr(value) {
41558    this._valueStr = value;
41559  }
41560  get finalValueNumber() {
41561    return this._finalValueNumber;
41562  }
41563  set finalValueNumber(value) {
41564    this._finalValueNumber = value;
41565  }
41566  get currentValue() {
41567    return this._currentValue;
41568  }
41569  set currentValue(value) {
41570    this._currentValue = value;
41571    if (this.currentValue && this.currentValue.Type === TUPLA_TYPE.NUMBER) {
41572      this.finalValueNumber = this.currentValue.Value;
41573      this.currentValue.Value = 0;
41574    }
41575    this.valueStr = this.currentValue ? this.currentValue.getTrimmedValue("-", this.numberFormatter, this._translationService) : "";
41576  }
41577  /**
41578   * Increment value if necessary
41579   * @return true = reached the value;
41580   */
41581  incrementValue() {
41582    if (!this.currentValue) {
41583      return true;
41584    }
41585    if (this.currentValue.Type !== TUPLA_TYPE.NUMBER) {
41586      return true;
41587    }
41588    let flReachedEnd = false;
41589    if (this.finalValueNumber < 0) {
41590      this.currentValue.Value -= this.step;
41591      if (this.currentValue.Value < this.finalValueNumber) {
41592        this.currentValue.Value = this.finalValueNumber;
41593        flReachedEnd = true;
41594      }
41595    } else {
41596      this.currentValue.Value += this.step;
41597      if (this.currentValue.Value > this.finalValueNumber) {
41598        this.currentValue.Value = this.finalValueNumber;
41599        flReachedEnd = true;
41600      }
41601    }
41602    this.valueStr = this.currentValue.getFormattedValue("-", this.numberFormatter);
41603    return flReachedEnd;
41604  }
41605  get UnitSx() {
41606    return this.unitSx;
41607  }
41608  get UnitDx() {
41609    return this.unitDx;
41610  }
41611};
41612__decorate([
41613  DoraProperty,
41614  __metadata("design:type", String)
41615], Column.prototype, "unitSx", void 0);
41616__decorate([
41617  DoraProperty,
41618  __metadata("design:type", String)
41619], Column.prototype, "name", void 0);
41620__decorate([
41621  DoraProperty,
41622  __metadata("design:type", String)
41623], Column.prototype, "unitDx", void 0);
41624__decorate([
41625  DoraProperty,
41626  __metadata("design:type", String)
41627], Column.prototype, "numberFormatter", void 0);
41628
41629// src/app/DoraWidget/dora-row/dora-row.component.ts
41630function DoraRowComponent_div_0_div_1_div_2_div_1_Template(rf, ctx) {
41631  if (rf & 1) {
41632    \u0275\u0275element(0, "div", 15);
41633  }
41634  if (rf & 2) {
41635    const column_r1 = \u0275\u0275nextContext().$implicit;
41636    const ctx_r1 = \u0275\u0275nextContext(3);
41637    \u0275\u0275styleProp("visibility", ctx_r1.getToolTipVisibility(column_r1));
41638    \u0275\u0275property("innerHTML", ctx_r1.getToolTip(column_r1), \u0275\u0275sanitizeHtml);
41639  }
41640}
41641function DoraRowComponent_div_0_div_1_div_2_div_2_Template(rf, ctx) {
41642  if (rf & 1) {
41643    const _r3 = \u0275\u0275getCurrentView();
41644    \u0275\u0275elementStart(0, "div", 16);
41645    \u0275\u0275listener("mouseenter", function DoraRowComponent_div_0_div_1_div_2_div_2_Template_div_mouseenter_0_listener() {
41646      \u0275\u0275restoreView(_r3);
41647      const column_r1 = \u0275\u0275nextContext().$implicit;
41648      const ctx_r1 = \u0275\u0275nextContext(3);
41649      return \u0275\u0275resetView(ctx_r1.onHeaderTooltipMouseEnter(column_r1));
41650    })("mouseleave", function DoraRowComponent_div_0_div_1_div_2_div_2_Template_div_mouseleave_0_listener() {
41651      \u0275\u0275restoreView(_r3);
41652      const column_r1 = \u0275\u0275nextContext().$implicit;
41653      const ctx_r1 = \u0275\u0275nextContext(3);
41654      return \u0275\u0275resetView(ctx_r1.onHeaderTooltipMouseLeave(column_r1));
41655    });
41656    \u0275\u0275elementEnd();
41657  }
41658}
41659function DoraRowComponent_div_0_div_1_div_2_div_4_Template(rf, ctx) {
41660  if (rf & 1) {
41661    \u0275\u0275elementStart(0, "div", 17);
41662    \u0275\u0275text(1, " > ");
41663    \u0275\u0275elementEnd();
41664  }
41665  if (rf & 2) {
41666    const column_r1 = \u0275\u0275nextContext().$implicit;
41667    \u0275\u0275property("innerHTML", column_r1.TranslatedName, \u0275\u0275sanitizeHtml);
41668  }
41669}
41670function DoraRowComponent_div_0_div_1_div_2_Template(rf, ctx) {
41671  if (rf & 1) {
41672    \u0275\u0275elementStart(0, "div");
41673    \u0275\u0275template(1, DoraRowComponent_div_0_div_1_div_2_div_1_Template, 1, 3, "div", 8)(2, DoraRowComponent_div_0_div_1_div_2_div_2_Template, 1, 0, "div", 9);
41674    \u0275\u0275elementStart(3, "div", 10);
41675    \u0275\u0275template(4, DoraRowComponent_div_0_div_1_div_2_div_4_Template, 2, 1, "div", 11);
41676    \u0275\u0275element(5, "div", 12)(6, "div", 13)(7, "div", 14);
41677    \u0275\u0275elementEnd()();
41678  }
41679  if (rf & 2) {
41680    const column_r1 = ctx.$implicit;
41681    const columnIdx_r4 = ctx.index;
41682    const ctx_r1 = \u0275\u0275nextContext(3);
41683    \u0275\u0275classMap(ctx_r1.getColumnCssClass(column_r1, columnIdx_r4));
41684    \u0275\u0275advance();
41685    \u0275\u0275property("ngIf", ctx_r1.toolTipEnabled);
41686    \u0275\u0275advance();
41687    \u0275\u0275property("ngIf", ctx_r1.isToolTipEnabled(column_r1));
41688    \u0275\u0275advance(2);
41689    \u0275\u0275property("ngIf", ctx_r1.fl_show_name);
41690    \u0275\u0275advance();
41691    \u0275\u0275property("innerHTML", ctx_r1.getColumnUnitSx(column_r1, columnIdx_r4), \u0275\u0275sanitizeHtml);
41692    \u0275\u0275advance();
41693    \u0275\u0275property("innerHTML", column_r1.valueStr, \u0275\u0275sanitizeHtml);
41694    \u0275\u0275advance();
41695    \u0275\u0275property("innerHTML", ctx_r1.getColumnUnitDx(column_r1, columnIdx_r4), \u0275\u0275sanitizeHtml);
41696  }
41697}
41698function DoraRowComponent_div_0_div_1_Template(rf, ctx) {
41699  if (rf & 1) {
41700    \u0275\u0275elementStart(0, "div", 5)(1, "div", 6);
41701    \u0275\u0275template(2, DoraRowComponent_div_0_div_1_div_2_Template, 8, 8, "div", 7);
41702    \u0275\u0275elementEnd()();
41703  }
41704  if (rf & 2) {
41705    const ctx_r1 = \u0275\u0275nextContext(2);
41706    \u0275\u0275advance(2);
41707    \u0275\u0275property("ngForOf", ctx_r1.columns_a);
41708  }
41709}
41710function DoraRowComponent_div_0_div_2_div_2_div_1_Template(rf, ctx) {
41711  if (rf & 1) {
41712    \u0275\u0275element(0, "div", 15);
41713  }
41714  if (rf & 2) {
41715    const column_r5 = \u0275\u0275nextContext().$implicit;
41716    const ctx_r1 = \u0275\u0275nextContext(3);
41717    \u0275\u0275styleProp("visibility", ctx_r1.getToolTipVisibility(column_r5));
41718    \u0275\u0275property("innerHTML", ctx_r1.getToolTip(column_r5), \u0275\u0275sanitizeHtml);
41719  }
41720}
41721function DoraRowComponent_div_0_div_2_div_2_div_2_Template(rf, ctx) {
41722  if (rf & 1) {
41723    const _r6 = \u0275\u0275getCurrentView();
41724    \u0275\u0275elementStart(0, "div", 16);
41725    \u0275\u0275listener("mouseenter", function DoraRowComponent_div_0_div_2_div_2_div_2_Template_div_mouseenter_0_listener() {
41726      \u0275\u0275restoreView(_r6);
41727      const column_r5 = \u0275\u0275nextContext().$implicit;
41728      const ctx_r1 = \u0275\u0275nextContext(3);
41729      return \u0275\u0275resetView(ctx_r1.onHeaderTooltipMouseEnter(column_r5));
41730    })("mouseleave", function DoraRowComponent_div_0_div_2_div_2_div_2_Template_div_mouseleave_0_listener() {
41731      \u0275\u0275restoreView(_r6);
41732      const column_r5 = \u0275\u0275nextContext().$implicit;
41733      const ctx_r1 = \u0275\u0275nextContext(3);
41734      return \u0275\u0275resetView(ctx_r1.onHeaderTooltipMouseLeave(column_r5));
41735    });
41736    \u0275\u0275elementEnd();
41737  }
41738}
41739function DoraRowComponent_div_0_div_2_div_2_div_4_Template(rf, ctx) {
41740  if (rf & 1) {
41741    \u0275\u0275elementStart(0, "div", 17);
41742    \u0275\u0275text(1, " > ");
41743    \u0275\u0275elementEnd();
41744  }
41745  if (rf & 2) {
41746    const column_r5 = \u0275\u0275nextContext().$implicit;
41747    \u0275\u0275property("innerHTML", column_r5.TranslatedName, \u0275\u0275sanitizeHtml);
41748  }
41749}
41750function DoraRowComponent_div_0_div_2_div_2_Template(rf, ctx) {
41751  if (rf & 1) {
41752    \u0275\u0275elementStart(0, "div");
41753    \u0275\u0275template(1, DoraRowComponent_div_0_div_2_div_2_div_1_Template, 1, 3, "div", 8)(2, DoraRowComponent_div_0_div_2_div_2_div_2_Template, 1, 0, "div", 9);
41754    \u0275\u0275elementStart(3, "div", 10);
41755    \u0275\u0275template(4, DoraRowComponent_div_0_div_2_div_2_div_4_Template, 2, 1, "div", 11);
41756    \u0275\u0275element(5, "div", 12)(6, "div", 13)(7, "div", 14);
41757    \u0275\u0275elementEnd()();
41758  }
41759  if (rf & 2) {
41760    const column_r5 = ctx.$implicit;
41761    const columnIdx_r7 = ctx.index;
41762    const ctx_r1 = \u0275\u0275nextContext(3);
41763    \u0275\u0275classMap(ctx_r1.getColumnCssClass(column_r5, columnIdx_r7));
41764    \u0275\u0275advance();
41765    \u0275\u0275property("ngIf", ctx_r1.toolTipEnabled);
41766    \u0275\u0275advance();
41767    \u0275\u0275property("ngIf", ctx_r1.isToolTipEnabled(column_r5));
41768    \u0275\u0275advance(2);
41769    \u0275\u0275property("ngIf", ctx_r1.fl_show_name);
41770    \u0275\u0275advance();
41771    \u0275\u0275property("innerHTML", ctx_r1.getColumnUnitSx(column_r5, columnIdx_r7), \u0275\u0275sanitizeHtml);
41772    \u0275\u0275advance();
41773    \u0275\u0275property("innerHTML", column_r5.valueStr, \u0275\u0275sanitizeHtml);
41774    \u0275\u0275advance();
41775    \u0275\u0275property("innerHTML", ctx_r1.getColumnUnitDx(column_r5, columnIdx_r7), \u0275\u0275sanitizeHtml);
41776  }
41777}
41778function DoraRowComponent_div_0_div_2_Template(rf, ctx) {
41779  if (rf & 1) {
41780    \u0275\u0275elementStart(0, "div", 18)(1, "div", 6);
41781    \u0275\u0275template(2, DoraRowComponent_div_0_div_2_div_2_Template, 8, 8, "div", 7);
41782    \u0275\u0275elementEnd()();
41783  }
41784  if (rf & 2) {
41785    const ctx_r1 = \u0275\u0275nextContext(2);
41786    \u0275\u0275advance(2);
41787    \u0275\u0275property("ngForOf", ctx_r1.columns_b);
41788  }
41789}
41790function DoraRowComponent_div_0_div_3_div_2_div_1_Template(rf, ctx) {
41791  if (rf & 1) {
41792    \u0275\u0275element(0, "div", 15);
41793  }
41794  if (rf & 2) {
41795    const column_r8 = \u0275\u0275nextContext().$implicit;
41796    const ctx_r1 = \u0275\u0275nextContext(3);
41797    \u0275\u0275styleProp("visibility", ctx_r1.getToolTipVisibility(column_r8));
41798    \u0275\u0275property("innerHTML", ctx_r1.getToolTip(column_r8), \u0275\u0275sanitizeHtml);
41799  }
41800}
41801function DoraRowComponent_div_0_div_3_div_2_div_2_Template(rf, ctx) {
41802  if (rf & 1) {
41803    const _r9 = \u0275\u0275getCurrentView();
41804    \u0275\u0275elementStart(0, "div", 16);
41805    \u0275\u0275listener("mouseenter", function DoraRowComponent_div_0_div_3_div_2_div_2_Template_div_mouseenter_0_listener() {
41806      \u0275\u0275restoreView(_r9);
41807      const column_r8 = \u0275\u0275nextContext().$implicit;
41808      const ctx_r1 = \u0275\u0275nextContext(3);
41809      return \u0275\u0275resetView(ctx_r1.onHeaderTooltipMouseEnter(column_r8));
41810    })("mouseleave", function DoraRowComponent_div_0_div_3_div_2_div_2_Template_div_mouseleave_0_listener() {
41811      \u0275\u0275restoreView(_r9);
41812      const column_r8 = \u0275\u0275nextContext().$implicit;
41813      const ctx_r1 = \u0275\u0275nextContext(3);
41814      return \u0275\u0275resetView(ctx_r1.onHeaderTooltipMouseLeave(column_r8));
41815    });
41816    \u0275\u0275elementEnd();
41817  }
41818}
41819function DoraRowComponent_div_0_div_3_div_2_div_4_Template(rf, ctx) {
41820  if (rf & 1) {
41821    \u0275\u0275elementStart(0, "div", 17);
41822    \u0275\u0275text(1, " > ");
41823    \u0275\u0275elementEnd();
41824  }
41825  if (rf & 2) {
41826    const column_r8 = \u0275\u0275nextContext().$implicit;
41827    \u0275\u0275property("innerHTML", column_r8.TranslatedName, \u
418270275\u0275sanitizeHtml);
41828  }
41829}
41830function DoraRowComponent_div_0_div_3_div_2_Template(rf, ctx) {
41831  if (rf & 1) {
41832    \u0275\u0275elementStart(0, "div");
41833    \u0275\u0275template(1, DoraRowComponent_div_0_div_3_div_2_div_1_Template, 1, 3, "div", 8)(2, DoraRowComponent_div_0_div_3_div_2_div_2_Template, 1, 0, "div", 9);
41834    \u0275\u0275elementStart(3, "div", 10);
41835    \u0275\u0275template(4, DoraRowComponent_div_0_div_3_div_2_div_4_Template, 2, 1, "div", 11);
41836    \u0275\u0275element(5, "div", 12)(6, "div", 13)(7, "div", 14);
41837    \u0275\u0275elementEnd()();
41838  }
41839  if (rf & 2) {
41840    const column_r8 = ctx.$implicit;
41841    const columnIdx_r10 = ctx.index;
41842    const ctx_r1 = \u0275\u0275nextContext(3);
41843    \u0275\u0275classMap(ctx_r1.getColumnCssClass(column_r8, columnIdx_r10));
41844    \u0275\u0275advance();
41845    \u0275\u0275property("ngIf", ctx_r1.toolTipEnabled);
41846    \u0275\u0275advance();
41847    \u0275\u0275property("ngIf", ctx_r1.isToolTipEnabled(column_r8));
41848    \u0275\u0275advance(2);
41849    \u0275\u0275property("ngIf", ctx_r1.fl_show_name);
41850    \u0275\u0275advance();
41851    \u0275\u0275property("innerHTML", ctx_r1.getColumnUnitSx(column_r8, columnIdx_r10), \u0275\u0275sanitizeHtml);
41852    \u0275\u0275advance();
41853    \u0275\u0275property("innerHTML", column_r8.valueStr, \u0275\u0275sanitizeHtml);
41854    \u0275\u0275advance();
41855    \u0275\u0275property("innerHTML", ctx_r1.getColumnUnitDx(column_r8, columnIdx_r10), \u0275\u0275sanitizeHtml);
41856  }
41857}
41858function DoraRowComponent_div_0_div_3_Template(rf, ctx) {
41859  if (rf & 1) {
41860    \u0275\u0275elementStart(0, "div", 19)(1, "div", 6);
41861    \u0275\u0275template(2, DoraRowComponent_div_0_div_3_div_2_Template, 8, 8, "div", 7);
41862    \u0275\u0275elementEnd()();
41863  }
41864  if (rf & 2) {
41865    const ctx_r1 = \u0275\u0275nextContext(2);
41866    \u0275\u0275advance(2);
41867    \u0275\u0275property("ngForOf", ctx_r1.columns_c);
41868  }
41869}
41870function DoraRowComponent_div_0_Template(rf, ctx) {
41871  if (rf & 1) {
41872    \u0275\u0275elementStart(0, "div", 1);
41873    \u0275\u0275template(1, DoraRowComponent_div_0_div_1_Template, 3, 1, "div", 2)(2, DoraRowComponent_div_0_div_2_Template, 3, 1, "div", 3)(3, DoraRowComponent_div_0_div_3_Template, 3, 1, "div", 4);
41874    \u0275\u0275elementEnd();
41875  }
41876  if (rf & 2) {
41877    const ctx_r1 = \u0275\u0275nextContext();
41878    \u0275\u0275advance();
41879    \u0275\u0275property("ngIf", ctx_r1.columns_a.length > 0);
41880    \u0275\u0275advance();
41881    \u0275\u0275property("ngIf", ctx_r1.columns_b.length > 0);
41882    \u0275\u0275advance();
41883    \u0275\u0275property("ngIf", ctx_r1.columns_c.length > 0);
41884  }
41885}
41886var DoraRowComponent = class _DoraRowComponent extends WidgetBaseComponent {
41887  constructor() {
41888    super(...arguments);
41889    this.idrow = "";
41890    this.fl_show_name = false;
41891    this.animation_steps = 20;
41892    this.animation_time = 100;
41893    this.columns_a = [];
41894    this.columns_b = [];
41895    this.columns_c = [];
41896    this.toolTipEnabled = false;
41897    this.dataRow = null;
41898    this.flAllIncremented = false;
41899    this.flTimerStarted = false;
41900  }
41901  onParameterInjectedFinished() {
41902    super.onParameterInjectedFinished();
41903    this.setTraslationOnClumns(this.columns_a);
41904    this.setTraslationOnClumns(this.columns_b);
41905    this.setTraslationOnClumns(this.columns_c);
41906    this.readData();
41907  }
41908  readData() {
41909    if (this.idrow === "") {
41910      return;
41911    }
41912    const publisherParameters = this.getPublisherParameters(this.publisherParameters);
41913    this.read([this.idrow], DataType.ROW, publisherParameters).subscribe((data) => {
41914      console.log("received");
41915      this.dataRow = data.Data;
41916      this.onNewData();
41917    });
41918  }
41919  onNewData() {
41920    if (this.dataRow === null) {
41921      return;
41922    }
41923    this.flAllIncremented = false;
41924    this.flTimerStarted = false;
41925    this.initValues(this.columns_a);
41926    this.initValues(this.columns_b);
41927    this.initValues(this.columns_c);
41928    this.checkScroll();
41929  }
41930  setTraslationOnClumns(columns) {
41931    columns.forEach((column) => {
41932      column.translationService = this.translationService;
41933    });
41934  }
41935  initValues(columns) {
41936    columns.forEach((column) => {
41937      const dataTupla = this.dataRow ? this.dataRow.getDataTupla(column.Name) : void 0;
41938      if (dataTupla === void 0) {
41939        console.log("Column [" + column.Name + "] not found in data");
41940        return;
41941      }
41942      column.currentValue = dataTupla.clone();
41943      column.numberOfSteps = this.animation_steps;
41944    });
41945  }
41946  checkScroll() {
41947    if (this.flTimerStarted === true) {
41948      return;
41949    }
41950    const elemTop = this.elementRef.nativeElement.getBoundingClientRect().top;
41951    const elemBottom = this.elementRef.nativeElement.getBoundingClientRect().bottom;
41952    console.log("Component pos [" + this.elementRef.nativeElement.offsetTop + "]");
41953    console.log("Component clientRect [" + elemTop + "] [" + elemBottom + "]");
41954    console.log("window.pageYOffset [" + window.pageYOffset + "]");
41955    console.log("window.innerHeight [" + window.innerHeight + "]");
41956    if (elemTop >= 0 && elemBottom <= window.innerHeight) {
41957      this.checkTimer();
41958    }
41959  }
41960  checkTimer() {
41961    this.flTimerStarted = true;
41962    const myTime = timer(this.animation_time);
41963    myTime.subscribe((value) => {
41964      this.incrementAllValues();
41965      if (this.flAllIncremented === false) {
41966        this.checkTimer();
41967      }
41968    });
41969  }
41970  /**
41971   * Increment all values.
41972   * If all values reached the end set flAllIncremented
41973   */
41974  incrementAllValues() {
41975    if (this.flAllIncremented === true) {
41976      return;
41977    }
41978    this.flAllIncremented = true;
41979    if (this.incrementValues(this.columns_a) === false) {
41980      this.flAllIncremented = false;
41981    }
41982    if (this.incrementValues(this.columns_b) === false) {
41983      this.flAllIncremented = false;
41984    }
41985    if (this.incrementValues(this.columns_c) === false) {
41986      this.flAllIncremented = false;
41987    }
41988  }
41989  /**
41990   * Increment all number values for a specific set of columns.
41991   * If all number ok set flAllIncremented
41992   */
41993  incrementValues(columns) {
41994    let result = true;
41995    columns.forEach((column) => {
41996      if (column.incrementValue() === false) {
41997        result = false;
41998      }
41999    });
42000    return result;
42001  }
42002  getColumnCssClass(column, index) {
42003    let cssClass = "column-container column-container-" + index + " " + column.Name;
42004    if (column.currentValue !== void 0 && column.currentValue !== null) {
42005      if (column.currentValue.Type === TUPLA_TYPE.NUMBER || column.currentValue.Type === TUPLA_TYPE.PERCENTAGE) {
42006        if (column.finalValueNumber > 0) {
42007          cssClass += " positive";
42008        } else if (column.finalValueNumber < 0) {
42009          cssClass += " negative";
42010        } else {
42011          cssClass += " equal";
42012        }
42013      }
42014    }
42015    return cssClass;
42016  }
42017  getColumnUnitDx(column, index) {
42018    return column.valueStr === "" ? "" : this.decodeUnit(column.UnitDx);
42019  }
42020  getColumnUnitSx(column, index) {
42021    return column.valueStr === "" ? "" : this.decodeUnit(column.UnitSx);
42022  }
42023  decodeUnit(unit) {
42024    if (this.dataRow === null) {
42025      return unit;
42026    }
42027    return unit.replace("[UNIT]", this.dataRow.Units);
42028  }
42029  getToolTip(column) {
42030    if (this.toolTipEnabled === true) {
42031      return this.translationService.getWithDefault(column.Name + "_TOOLTIP", "");
42032    }
42033    return "";
42034  }
42035  /**
42036   * Return true if the tooltip is enabled
42037   */
42038  isToolTipEnabled(column) {
42039    if (this.toolTipEnabled === true) {
42040      if (this.getToolTip(column) !== "") {
42041        return true;
42042      } else {
42043        return false;
42044      }
42045    }
42046    return false;
42047  }
42048  getToolTipVisibility(column) {
42049    return column.tooltipVisible === true ? "visible" : "hidden";
42050  }
42051  onHeaderTooltipMouseEnter(column) {
42052    column.tooltipVisible = true;
42053  }
42054  onHeaderTooltipMouseLeave(column) {
42055    column.tooltipVisible = false;
42056  }
42057  static {
42058    this.\u0275fac = /* @__PURE__ */ (() => {
42059      let \u0275DoraRowComponent_BaseFactory;
42060      return function DoraRowComponent_Factory(__ngFactoryType__) {
42061        return (\u0275DoraRowComponent_BaseFactory || (\u0275DoraRowComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraRowComponent)))(__ngFactoryType__ || _DoraRowComponent);
42062      };
42063    })();
42064  }
42065  static {
42066    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraRowComponent, selectors: [["dora-row"]], hostBindings: function DoraRowComponent_HostBindings(rf, ctx) {
42067      if (rf & 1) {
42068        \u0275\u0275listener("scroll", function DoraRowComponent_scroll_HostBindingHandler($event) {
42069          return ctx.checkScroll($event);
42070        }, false, \u0275\u0275resolveWindow);
42071      }
42072    }, standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "DAG-Row", 4, "ngIf"], [1, "DAG-Row"], ["class", "row-container row-container-a", 4, "ngIf"], ["class", "row-container row-container-b", 4, "ngIf"], ["class", "row-container row-container-c", 4, "ngIf"], [1, "row-container", "row-container-a"], [1, "row-sub-container"], [3, "class", 4, "ngFor", "ngForOf"], ["class", "column-tooltip", 3, "visibility", "innerHTML", 4, "ngIf"], ["class", "tooltip-command", 3, "mouseenter", "mouseleave", 4, "ngIf"], [1, "column-value-container"], ["class", "name", 3, "innerHTML", 4, "ngIf"], [1, "unit-sx", 3, "innerHTML"], [1, "value", 3, "innerHTML"], [1, "unit-dx", 3, "innerHTML"], [1, "column-tooltip", 3, "innerHTML"], [1, "tooltip-command", 3, "mouseenter", "mouseleave"], [1, "name", 3, "innerHTML"], [1, "row-container", "row-container-b"], [1, "row-container", "row-container-c"]], template: function DoraRowComponent_Template(rf, ctx) {
42073      if (rf & 1) {
42074        \u0275\u0275template(0, DoraRowComponent_div_0_Template, 4, 3, "div", 0);
42075      }
42076      if (rf & 2) {
42077        \u0275\u0275property("ngIf", ctx.dataRow);
42078      }
42079    }, dependencies: [NgForOf, NgIf], styles: ["\n\n.DAG-Row[_ngcontent-%COMP%] {\n  width: 100%;\n  display: block;\n  overflow: hidden;\n}\n.DAG-Row[_ngcontent-%COMP%]   .row-container[_ngcontent-%COMP%] {\n  width: 100%;\n  display: block;\n  overflow: hidden;\n}\n.DAG-Row[_ngcontent-%COMP%]   .row-container[_ngcontent-%COMP%]   .column-container[_ngcontent-%COMP%] {\n  float: left;\n  position: relative;\n}\n.DAG-Row[_ngcontent-%COMP%]   .row-container[_ngcontent-%COMP%]   .column-container[_ngcontent-%COMP%]   .column-tooltip[_ngcontent-%COMP%] {\n  display: block;\n  background: lightgray;\n  z-index: 4000;\n  position: absolute;\n  top: -30px;\n}\n.DAG-Row[_ngcontent-%COMP%]   .row-container[_ngcontent-%COMP%]   .column-container[_ngcontent-%COMP%]   .tooltip-command[_ngcontent-%COMP%] {\n  width: 10px;\n  height: 10px;\n  background-color: darkgray;\n}"] });
42080  }
42081};
42082__decorate([
42083  DoraProperty,
42084  __metadata("design:type", String)
42085], DoraRowComponent.prototype, "idrow", void 0);
42086__decorate([
42087  DoraProperty,
42088  __metadata("design:type", Boolean)
42089], DoraRowComponent.prototype, "fl_show_name", void 0);
42090__decorate([
42091  DoraProperty,
42092  __metadata("design:type", Number)
42093], DoraRowComponent.prototype, "animation_steps", void 0);
42094__decorate([
42095  DoraProperty,
42096  __metadata("design:type", Number)
42097], DoraRowComponent.prototype, "animation_time", void 0);
42098__decorate([
42099  DoraPropertyArray(Column),
42100  __metadata("design:type", Array)
42101], DoraRowComponent.prototype, "columns_a", void 0);
42102__decorate([
42103  DoraPropertyArray(Column),
42104  __metadata("design:type", Array)
42105], DoraRowComponent.prototype, "columns_b", void 0);
42106__decorate([
42107  DoraPropertyArray(Column),
42108  __metadata("design:type", Array)
42109], DoraRowComponent.prototype, "columns_c", void 0);
42110__decorate([
42111  DoraProperty,
42112  __metadata("design:type", Boolean)
42113], DoraRowComponent.prototype, "toolTipEnabled", void 0);
42114(() => {
42115  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraRowComponent, { className: "DoraRowComponent", filePath: "src/app/dorawidget/dora-row/dora-row.component.ts", lineNumber: 21 });
42116})();
42117
42118// src/app/DoraWidget/widget-base/widget-base-grid.component.ts
42119var WidgetBaseGridComponent = class _WidgetBaseGridComponent extends WidgetBaseComponent {
42120  constructor() {
42121    super(...arguments);
42122    this.gridId = "";
42123    this.disableMessageGridSelected = false;
42124    this.gridIdPostfix = "";
42125    this.flSelectFirstRow = true;
42126  }
42127  onParameterInjectedFinished() {
42128    super.onParameterInjectedFinished();
42129    this.readData();
42130    if (this.disableMessageGridSelected === false) {
42131      this.messageService.getMessage(this.EventChannel, MessageGridSelected, this.CallerName).subscribe((message) => {
42132        this.gridId = message.data.idGrid + this.gridIdPostfix;
42133        this.readData();
42134      });
42135    }
42136  }
42137  readData() {
42138    if (this.gridId === null || this.gridId === "") {
42139      return;
42140    }
42141    this.read([this.gridId], DataType.GRID).subscribe((data) => {
42142      if (data !== null) {
42143        const readResult = data;
42144        if (readResult.Data !== null) {
42145          this.dataGrid = readResult.Data;
42146          this.onNewData();
42147        }
42148      }
42149    });
42150  }
42151  /**
42152   * Received new <b>data</b>
42153   */
42154  onNewData() {
42155    if (this.flSelectFirstRow) {
42156      if (this.dataGrid !== void 0 && this.dataGrid.DataRows.length > 0) {
42157        this.selectedGrid(this.dataGrid.DataRows[0].Id);
42158      }
42159    }
42160  }
42161  selectedGrid(rowId) {
42162  }
42163  static {
42164    this.\u0275fac = /* @__PURE__ */ (() => {
42165      let \u0275WidgetBaseGridComponent_BaseFactory;
42166      return function WidgetBaseGridComponent_Factory(__ngFactoryType__) {
42167        return (\u0275WidgetBaseGridComponent_BaseFactory || (\u0275WidgetBaseGridComponent_BaseFactory = \u0275\u0275getInheritedFactory(_WidgetBaseGridComponent)))(__ngFactoryType__ || _WidgetBaseGridComponent);
42168      };
42169    })();
42170  }
42171  static {
42172    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _WidgetBaseGridComponent, selectors: [["dora-widget-base-grid"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 0, vars: 0, template: function WidgetBaseGridComponent_Template(rf, ctx) {
42173    }, encapsulation: 2 });
42174  }
42175};
42176__decorate([
42177  DoraPropertyDOC("Tabella da utilizzare", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.TABLE_LIST, true),
42178  DoraProperty,
42179  __metadata("design:type", String)
42180], WidgetBaseGridComponent.prototype, "gridId", void 0);
42181__decorate([
42182  DoraPropertyDOC("Disabilita l'invio del messaggio MessageGridSelected", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
42183  DoraProperty,
42184  __metadata("design:type", Boolean)
42185], WidgetBaseGridComponent.prototype, "disableMessageGridSelected", void 0);
42186(() => {
42187  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(WidgetBaseGridComponent, { className: "WidgetBaseGridComponent", filePath: "src/app/dorawidget/widget-base/widget-base-grid.component.ts", lineNumber: 23 });
42188})();
42189
42190// src/app/messages/message-level-selected.ts
42191var MessageLevelSelected = class _MessageLevelSelected extends MessageBase {
42192  constructor(dataRow) {
42193    super(_MessageLevelSelected);
42194    this._dataRow = dataRow;
42195  }
42196  get dataRow() {
42197    return this._dataRow;
42198  }
42199};
42200
42201// src/app/DoraWidget/dora-data-grid-selector/dora-data-grid-selector.component.ts
42202var DoraDataGridSelectorComponent = class _DoraDataGridSelectorComponent extends WidgetBaseGridComponent {
42203  constructor(elementRef, messageService, configurationService, publisher, widgetService, http, translationService) {
42204    super(elementRef, messageService, configurationService, publisher, widgetService, http, translationService);
42205    this.levelToManage = 0;
42206    this.dataRows = [];
42207    this.fatherDataRow = void 0;
42208    this.disableMessageGridSelected = true;
42209  }
42210  onParameterInjectedFinished() {
42211    super.onParameterInjectedFinished();
42212    if (this.levelToManage > 1) {
42213      this.messageService.getMessage(this.EventChannel, MessageLevelSelected, this.CallerName).subscribe((message) => {
42214        const dataRow = message.data.dataRow;
42215        if (dataRow.Level === this.levelToManage - 1) {
42216          this.fatherDataRow = dataRow;
42217          this.onNewData();
42218        }
42219      });
42220    }
42221  }
42222  selectedGrid(rowId) {
42223    if (this.dataGrid === void 0) {
42224      console.error("dataGrid undefined");
42225      return;
42226    }
42227    let dataRow;
42228    dataRow = this.dataGrid.getDataRow(rowId);
42229    if (dataRow === null || dataRow === void 0) {
42230      console.error("Row not found. Id: " + rowId);
42231      return;
42232    }
42233    if (this.levelToManage !== 0 && this.levelToManage !== dataRow.Level) {
42234      return;
42235    }
42236    this.dataGrid.selectRowMutex(dataRow.Id);
42237    if (dataRow.GridId === "") {
42238      this.messageService.sendMessage(this.EventChannel, new MessageLevelSelected(dataRow), this.CallerName);
42239    } else {
42240      if (dataRow.GridId === void 0) {
42241        console.error("dataGrid undefined");
42242        return;
42243      }
42244      this.messageService.sendMessage(this.EventChannel, new MessageGridSelected(dataRow.GridId, dataRow.Description), this.CallerName);
42245    }
42246  }
42247  /**
42248   * received new data or something is changed: rebuild list
42249   */
42250  onNewData() {
42251    super.onNewData();
42252    if (this.dataGrid === void 0) {
42253      return;
42254    }
42255    if (this.levelToManage === 0) {
42256      this.dataRows = this.dataGrid.DataRows;
42257    }
42258    if (this.levelToManage === 1) {
42259      this.dataRows = this.dataGrid.DataRows.filter((value) => {
42260        return value.Level === 1 ? true : false;
42261      });
42262      return;
42263    }
42264    if (this.fatherDataRow === void 0) {
42265      return;
42266    }
42267    this.dataRows = [];
42268    let flFatherFound = false;
42269    for (const dataRow of this.dataGrid.DataRows) {
42270      if (flFatherFound === false) {
42271        if (dataRow.Id === this.fatherDataRow.Id) {
42272          flFatherFound = true;
42273        }
42274      } else {
42275        if (dataRow.Level === this.levelToManage) {
42276          this.dataRows.push(dataRow);
42277        } else {
42278          break;
42279        }
42280      }
42281    }
42282    if (this.dataRows.length > 0) {
42283      this.selectedGrid(this.dataRows[0].Id);
42284    }
42285  }
42286  static {
42287    this.\u0275fac = function DoraDataGridSelectorComponent_Factory(__ngFactoryType__) {
42288      return new (__ngFactoryType__ || _DoraDataGridSelectorComponent)(\u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(MessageService), \u0275\u0275directiveInject(ConfigurationService), \u0275\u0275directiveInject(PublisherService), \u0275\u0275directiveInject(WidgetService), \u0275\u0275directiveInject(HttpClient), \u0275\u0275directiveInject(TranslationService));
42289    };
42290  }
42291  static {
42292    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraDataGridSelectorComponent, selectors: [["dora-data-grid-selector"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 0, vars: 0, template: function DoraDataGridSelectorComponent_Template(rf, ctx) {
42293    }, encapsulation: 2 });
42294  }
42295};
42296__decorate([
42297  DoraPropertyDOC("Livello da gestiro (il primo \xE8 0)", ATTRIBUTE_TYPE.INTEGER, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
42298  DoraProperty,
42299  __metadata("design:type", Number)
42300], DoraDataGridSelectorComponent.prototype, "levelToManage", void 0);
42301(() => {
42302  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraDataGridSelectorComponent, { className: "DoraDataGridSelectorComponent", filePath: "src/app/dorawidget/dora-data-grid-selector/dora-data-grid-selector.component.ts", lineNumber: 27 });
42303})();
42304
42305// src/app/DoraWidget/dora-data-grid-selector/dora-data-grid-selector-tab-scroll/dora-data-grid-selector-tab-scroll.component.ts
42306function DoraDataGridSelectorTabScrollComponent_div_0_div_4_Template(rf, ctx) {
42307  if (rf & 1) {
42308    const _r3 = \u0275\u0275getCurrentView();
42309    \u0275\u0275elementStart(0, "div", 6)(1, "div", 2);
42310    \u0275\u0275listener("click", function DoraDataGridSelectorTabScrollComponent_div_0_div_4_Template_div_click_1_listener() {
42311      const ctx_r3 = \u0275\u0275restoreView(_r3);
42312      const row_r5 = ctx_r3.$implicit;
42313      const rowIdx_r6 = ctx_r3.index;
42314      const ctx_r1 = \u0275\u0275nextContext(2);
42315      return \u0275\u0275resetView(ctx_r1.onSelect(rowIdx_r6, row_r5));
42316    });
42317    \u0275\u0275element(2, "div", 7);
42318    \u0275\u0275elementEnd()();
42319  }
42320  if (rf & 2) {
42321    const row_r5 = ctx.$implicit;
42322    const rowIdx_r6 = ctx.index;
42323    const ctx_r1 = \u0275\u0275nextContext(2);
42324    \u0275\u0275advance();
42325    \u0275\u0275classMap(ctx_r1.getElementContainerCssClass(rowIdx_r6, row_r5));
42326    \u0275\u0275advance();
42327    \u0275\u0275classMap(ctx_r1.getElementContentCssClass(rowIdx_r6, row_r5));
42328    \u0275\u0275property("innerHTML", ctx_r1.getElementContent(rowIdx_r6, row_r5), \u0275\u0275sanitizeHtml);
42329  }
42330}
42331function DoraDataGridSelectorTabScrollComponent_div_0_Template(rf, ctx) {
42332  if (rf & 1) {
42333    const _r1 = \u0275\u0275getCurrentView();
42334    \u0275\u0275elementStart(0, "div", 1)(1, "div", 2);
42335    \u0275\u0275listener("click", function DoraDataGridSelectorTabScrollComponent_div_0_Template_div_click_1_listener() {
42336      \u0275\u0275restoreView(_r1);
42337      const ctx_r1 = \u0275\u0275nextContext();
42338      return \u0275\u0275resetView(ctx_r1.onLeft());
42339    });
42340    \u0275\u0275elementEnd();
42341    \u0275\u0275elementStart(2, "div", 3)(3, "div", 4);
42342    \u0275\u0275template(4, DoraDataGridSelectorTabScrollComponent_div_0_div_4_Template, 3, 5, "div", 5);
42343    \u0275\u0275elementEnd()();
42344    \u0275\u0275elementStart(5, "div", 2);
42345    \u0275\u0275listener("click", function DoraDataGridSelectorTabScrollComponent_div_0_Template_div_click_5_listener() {
42346      \u0275\u0275restoreView(_r1);
42347      const ctx_r1 = \u0275\u0275nextContext();
42348      return \u0275\u0275resetView(ctx_r1.onRight());
42349    });
42350    \u0275\u0275elementEnd()();
42351  }
42352  if (rf & 2) {
42353    const ctx_r1 = \u0275\u0275nextContext();
42354    \u0275\u0275advance();
42355    \u0275\u0275classMap(ctx_r1.getBtnLeftCssClass());
42356    \u0275\u0275advance(2);
42357    \u0275\u0275styleProp("left", ctx_r1.setOffsetToInternal());
42358    \u0275\u0275advance();
42359    \u0275\u0275property("ngForOf", ctx_r1.dataRows);
42360    \u0275\u0275advance();
42361    \u0275\u0275classMap(ctx_r1.getBtnRightCssClass());
42362  }
42363}
42364var DoraDataGridSelectorTabScrollComponent = class _DoraDataGridSelectorTabScrollComponent extends DoraDataGridSelectorComponent {
42365  constructor() {
42366    super(...arguments);
42367    this.startTab = 0;
42368  }
42369  onNewData() {
42370    super.onNewData();
42371    this.startTab = 0;
42372  }
42373  onSelect(rowIndex, dataRow) {
42374    this.selectedGrid(dataRow.Id);
42375  }
42376  // Methods for Css Class
42377  getElementContainerCssClass(rowIndex, dataRow) {
42378    let result;
42379    result = "tab-element-container " + dataRow.CssFormat;
42380    result += dataRow.selected ? " on" : " off";
42381    return result;
42382  }
42383  getElementContentCssClass(rowIndex, dataRow) {
42384    return "tab-element-content";
42385  }
42386  getElementContent(rowIndex, dataRow) {
42387    let result = "";
42388    const descriptionTupla = dataRow.getDataTupla("Description");
42389    if (descriptionTupla !== void 0) {
42390      result = descriptionTupla.Value;
42391    }
42392    return result;
42393  }
42394  getBtnLeftCssClass() {
42395    let result = "";
42396    result = "DAG-btn DAG-btn-left " + (this.startTab === 0 ? "off" : "on");
42397    return result;
42398  }
42399  getBtnRightCssClass() {
42400    let result = "";
42401    result = "DAG-btn DAG-btn-right " + (this.startTab === this.getHtmlTabs().length - 1 ? "off" : "on");
42402    return result;
42403  }
42404  onRight() {
42405    if (this.startTab < this.getHtmlTabs().length - 1) {
42406      this.startTab++;
42407    }
42408  }
42409  onLeft() {
42410    if (this.startTab > 0) {
42411      this.startTab--;
42412    }
42413  }
42414  setOffsetToInternal() {
42415    const myLeft = this.getHtmlTabOffset(this.startTab);
42416    return myLeft;
42417  }
42418  getHtmlTabs() {
42419    return this.elementRef.nativeElement.getElementsByClassName("tab-element-container-external");
42420  }
42421  getHtmlTabOffset(idx) {
42422    const htmlTabs = this.getHtmlTabs();
42423    if (idx >= htmlTabs.length) {
42424      return "0px";
42425    }
42426    let myWidth = 0;
42427    for (let i = 0; i < idx; i++) {
42428      if (htmlTabs.item !== null && htmlTabs.item(i) !== null && null !== htmlTabs.item(i).clientWidth) {
42429        myWidth += htmlTabs.item(i).clientWidth;
42430      }
42431    }
42432    const result = "-" + myWidth.toString() + "px";
42433    return result;
42434  }
42435  static {
42436    this.\u0275fac = /* @__PURE__ */ (() => {
42437      let \u0275DoraDataGridSelectorTabScrollComponent_BaseFactory;
42438      return function DoraDataGridSelectorTabScrollComponent_Factory(__ngFactoryType__) {
42439        return (\u0275DoraDataGridSelectorTabScrollComponent_BaseFactory || (\u0275DoraDataGridSelectorTabScrollComponent_BaseFactory = \u0275\u0275getIn
42439heritedFactory(_DoraDataGridSelectorTabScrollComponent)))(__ngFactoryType__ || _DoraDataGridSelectorTabScrollComponent);
42440      };
42441    })();
42442  }
42443  static {
42444    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraDataGridSelectorTabScrollComponent, selectors: [["dora-data-grid-selector-tab-scroll"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "DAG-data-grid-selector-tab-scroll", 4, "ngIf"], [1, "DAG-data-grid-selector-tab-scroll"], [3, "click"], [1, "DAG-scroll-container-external"], [1, "DAG-scroll-container-internal"], ["class", "tab-element-container-external", 4, "ngFor", "ngForOf"], [1, "tab-element-container-external"], [3, "innerHTML"]], template: function DoraDataGridSelectorTabScrollComponent_Template(rf, ctx) {
42445      if (rf & 1) {
42446        \u0275\u0275template(0, DoraDataGridSelectorTabScrollComponent_div_0_Template, 6, 7, "div", 0);
42447      }
42448      if (rf & 2) {
42449        \u0275\u0275property("ngIf", ctx.dataGrid);
42450      }
42451    }, dependencies: [NgForOf, NgIf], encapsulation: 2 });
42452  }
42453};
42454(() => {
42455  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraDataGridSelectorTabScrollComponent, { className: "DoraDataGridSelectorTabScrollComponent", filePath: "src/app/dorawidget/dora-data-grid-selector/dora-data-grid-selector-tab-scroll/dora-data-grid-selector-tab-scroll.component.ts", lineNumber: 12 });
42456})();
42457
42458// src/app/DoraWidget/dora-data-grid-selector/dora-data-grid-selector-tab/dora-data-grid-selector-tab.component.ts
42459function DoraDataGridSelectorTabComponent_div_0_Template(rf, ctx) {
42460  if (rf & 1) {
42461    const _r1 = \u0275\u0275getCurrentView();
42462    \u0275\u0275elementStart(0, "div", 2);
42463    \u0275\u0275listener("click", function DoraDataGridSelectorTabComponent_div_0_Template_div_click_0_listener() {
42464      \u0275\u0275restoreView(_r1);
42465      const ctx_r1 = \u0275\u0275nextContext();
42466      return \u0275\u0275resetView(ctx_r1.onEnableSetting());
42467    });
42468    \u0275\u0275elementEnd();
42469  }
42470}
42471function DoraDataGridSelectorTabComponent_div_1_div_1_Template(rf, ctx) {
42472  if (rf & 1) {
42473    const _r3 = \u0275\u0275getCurrentView();
42474    \u0275\u0275elementStart(0, "div", 5);
42475    \u0275\u0275listener("click", function DoraDataGridSelectorTabComponent_div_1_div_1_Template_div_click_0_listener() {
42476      const ctx_r3 = \u0275\u0275restoreView(_r3);
42477      const row_r5 = ctx_r3.$implicit;
42478      const rowIdx_r6 = ctx_r3.index;
42479      const ctx_r1 = \u0275\u0275nextContext(2);
42480      return \u0275\u0275resetView(ctx_r1.onSelect(rowIdx_r6, row_r5));
42481    });
42482    \u0275\u0275element(1, "div", 6);
42483    \u0275\u0275elementEnd();
42484  }
42485  if (rf & 2) {
42486    const row_r5 = ctx.$implicit;
42487    const rowIdx_r6 = ctx.index;
42488    const ctx_r1 = \u0275\u0275nextContext(2);
42489    \u0275\u0275classMap(ctx_r1.getElementContainerCssClass(rowIdx_r6, row_r5));
42490    \u0275\u0275advance();
42491    \u0275\u0275classMap(ctx_r1.getElementContentCssClass(rowIdx_r6, row_r5));
42492    \u0275\u0275property("innerHTML", ctx_r1.getElementContent(rowIdx_r6, row_r5), \u0275\u0275sanitizeHtml);
42493  }
42494}
42495function DoraDataGridSelectorTabComponent_div_1_Template(rf, ctx) {
42496  if (rf & 1) {
42497    \u0275\u0275elementStart(0, "div", 3);
42498    \u0275\u0275template(1, DoraDataGridSelectorTabComponent_div_1_div_1_Template, 2, 5, "div", 4);
42499    \u0275\u0275elementEnd();
42500  }
42501  if (rf & 2) {
42502    const ctx_r1 = \u0275\u0275nextContext();
42503    \u0275\u0275advance();
42504    \u0275\u0275property("ngForOf", ctx_r1.dataRows);
42505  }
42506}
42507var DoraDataGridSelectorTabComponent = class _DoraDataGridSelectorTabComponent extends DoraDataGridSelectorComponent {
42508  onSelect(rowIndex, dataRow) {
42509    this.selectedGrid(dataRow.Id);
42510  }
42511  // Methods for Css Class
42512  getElementContainerCssClass(rowIndex, dataRow) {
42513    let result;
42514    result = "tab-element-container " + dataRow.CssFormat;
42515    result += dataRow.selected ? " on" : " off";
42516    return result;
42517  }
42518  getElementContentCssClass(rowIndex, dataRow) {
42519    return "tab-element-content";
42520  }
42521  getElementContent(rowIndex, dataRow) {
42522    let result = "";
42523    const descriptionTupla = dataRow.getDataTupla("Description");
42524    if (descriptionTupla !== void 0) {
42525      result = descriptionTupla.Value;
42526    }
42527    return result;
42528  }
42529  static {
42530    this.\u0275fac = /* @__PURE__ */ (() => {
42531      let \u0275DoraDataGridSelectorTabComponent_BaseFactory;
42532      return function DoraDataGridSelectorTabComponent_Factory(__ngFactoryType__) {
42533        return (\u0275DoraDataGridSelectorTabComponent_BaseFactory || (\u0275DoraDataGridSelectorTabComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraDataGridSelectorTabComponent)))(__ngFactoryType__ || _DoraDataGridSelectorTabComponent);
42534      };
42535    })();
42536  }
42537  static {
42538    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraDataGridSelectorTabComponent, selectors: [["dora-data-grid-selector-tab"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 2, vars: 2, consts: [["class", "setting-command", 3, "click", 4, "ngIf"], ["class", "DAG-data-grid-selector-tab", 4, "ngIf"], [1, "setting-command", 3, "click"], [1, "DAG-data-grid-selector-tab"], [3, "class", "click", 4, "ngFor", "ngForOf"], [3, "click"], [3, "innerHTML"]], template: function DoraDataGridSelectorTabComponent_Template(rf, ctx) {
42539      if (rf & 1) {
42540        \u0275\u0275template(0, DoraDataGridSelectorTabComponent_div_0_Template, 1, 0, "div", 0)(1, DoraDataGridSelectorTabComponent_div_1_Template, 2, 1, "div", 1);
42541      }
42542      if (rf & 2) {
42543        \u0275\u0275property("ngIf", ctx.settingEnabled);
42544        \u0275\u0275advance();
42545        \u0275\u0275property("ngIf", ctx.dataGrid);
42546      }
42547    }, dependencies: [NgForOf, NgIf], styles: ["\n\n.DAG-data-grid-selector-tab[_ngcontent-%COMP%]   .tab-element-container[_ngcontent-%COMP%] {\n  float: left;\n  width: auto;\n  cursor: pointer;\n}\n.DAG-data-grid-selector-tab[_ngcontent-%COMP%]   .tab-element-container.on[_ngcontent-%COMP%]   .tab-element-content[_ngcontent-%COMP%], \n.DAG-data-grid-selector-tab[_ngcontent-%COMP%]   .tab-element-container.off[_ngcontent-%COMP%]:hover   .tab-element-content[_ngcontent-%COMP%] {\n  background-color: cornflowerblue;\n  color: white;\n}\n.DAG-data-grid-selector-tab[_ngcontent-%COMP%]   .tab-element-container[_ngcontent-%COMP%]   .tab-element-content[_ngcontent-%COMP%] {\n  width: auto;\n  cursor: pointer;\n  padding-right: 5px;\n  padding-left: 5px;\n}"] });
42548  }
42549};
42550(() => {
42551  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraDataGridSelectorTabComponent, { className: "DoraDataGridSelectorTabComponent", filePath: "src/app/dorawidget/dora-data-grid-selector/dora-data-grid-selector-tab/dora-data-grid-selector-tab.component.ts", lineNumber: 12 });
42552})();
42553
42554// src/app/messages/message-series-selected.ts
42555var MessageSeriesSelected = class _MessageSeriesSelected extends MessageBase {
42556  constructor(dataSeries, callerPosition) {
42557    super(_MessageSeriesSelected);
42558    this.datasSeries = [];
42559    this.callerPosition = null;
42560    this.datasSeries = dataSeries;
42561    this.callerPosition = callerPosition;
42562  }
42563  get DatasSeries() {
42564    return this.datasSeries;
42565  }
42566  get CallerPosition() {
42567    return this.callerPosition;
42568  }
42569};
42570
42571// src/app/messages/message-columns-selected.ts
42572var MessageColumnsSelected = class _MessageColumnsSelected extends MessageBase {
42573  constructor(idRows) {
42574    super(_MessageColumnsSelected);
42575    this._idColumns = idRows;
42576  }
42577  get idColumns() {
42578    return this._idColumns;
42579  }
42580};
42581
42582// src/app/messages/message-columns-visible.ts
42583var MessageColumnsVisible = class _MessageColumnsVisible extends MessageBase {
42584  constructor(idRows) {
42585    super(_MessageColumnsVisible);
42586    this._idColumns = idRows;
42587  }
42588  get idColumns() {
42589    return this._idColumns;
42590  }
42591};
42592
42593// src/app/DoraWidget/dora-row/data/id.ts
42594var Id = class {
42595  constructor() {
42596    this.key = "";
42597  }
42598};
42599__decorate([
42600  DoraPropertyDOC("Generic parameter", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
42601  DoraProperty,
42602  __metadata("design:type", String)
42603], Id.prototype, "key", void 0);
42604
42605// src/app/messages/data/fixed-series-info.ts
42606var FixedSeriesInfo = class {
42607};
42608
42609// src/app/messages/message-last-date.ts
42610var MessageLastDate = class _MessageLastDate extends MessageBase {
42611  constructor(lastDate) {
42612    super(_MessageLastDate);
42613    this.lastDate = lastDate;
42614  }
42615  get LastDate() {
42616    return this.lastDate;
42617  }
42618};
42619
42620// src/app/Utility/position-element.ts
42621var PositionElement = class {
42622  constructor(element) {
42623    const parentPosition = this.getElementPosition(element);
42624    const parentTopPosition = parentPosition === null ? 0 : parentPosition.top;
42625    const rect = element.getBoundingClientRect();
42626    this.x = rect.x;
42627    this.y = rect.y + window.scrollY;
42628    this.width = rect.width;
42629    this.height = rect.height;
42630    this.top = rect.top - parentTopPosition;
42631    this.left = rect.left;
42632    this.right = rect.right;
42633    this.bottom = rect.bottom;
42634    console.log("PositionElement x:[" + this.x + "] y:[" + this.y + "] width:[" + this.width + "] height:[" + this.height + "] top:[" + this.top + "] left:[" + this.left + "] right:[" + this.right + "] bottom:[" + this.bottom + "]");
42635  }
42636  /**
42637   * Get the position of parent the element with display = relative
42638   */
42639  getElementPosition(element) {
42640    const parent = element.parentElement;
42641    if (parent === null) {
42642      return null;
42643    }
42644    const displayType = window.getComputedStyle(parent, null).position;
42645    if (displayType === "relative") {
42646      return parent.getBoundingClientRect();
42647    } else {
42648      return this.getElementPosition(parent);
42649    }
42650  }
42651  get X() {
42652    return this.x;
42653  }
42654  get Y() {
42655    return this.y;
42656  }
42657  get Width() {
42658    return this.width;
42659  }
42660  get Height() {
42661    return this.height;
42662  }
42663  get Top() {
42664    return this.top;
42665  }
42666  get Left() {
42667    return this.left;
42668  }
42669  get Right() {
42670    return this.right;
42671  }
42672  get Bottom() {
42673    return this.bottom;
42674  }
42675};
42676
42677// src/app/messages/message-rows-unselected.ts
42678var MessageRowsUnselected = class _MessageRowsUnselected extends MessageBase {
42679  constructor(idRows) {
42680    super(_MessageRowsUnselected);
42681    this.idRows = idRows;
42682  }
42683  get DataRows() {
42684    return this.idRows;
42685  }
42686};
42687
42688// src/app/DoraWidget/dora-data-grid/data/row-config.ts
42689var RowConfig = class {
42690  constructor() {
42691    this.idRow = "";
42692    this.hasHistorical = false;
42693    this.initialFixing = 0;
42694  }
42695};
42696__decorate([
42697  DoraPropertyDOC("Id riga", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
42698  DoraProperty,
42699  __metadata("design:type", String)
42700], RowConfig.prototype, "idRow", void 0);
42701__decorate([
42702  DoraPropertyDOC("Indica se mostrare lo storico", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
42703  DoraProperty,
42704  __metadata("design:type", Boolean)
42705], RowConfig.prototype, "hasHistorical", void 0);
42706__decorate([
42707  DoraPropertyDOC("Fixing iniziale", ATTRIBUTE_TYPE.FLOAT, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
42708  DoraProperty,
42709  __metadata("design:type", Number)
42710], RowConfig.prototype, "initialFixing", void 0);
42711
42712// src/app/messages/message-series-fixed-enabled.ts
42713var MessageSeriesFixedEnabled = class _MessageSeriesFixedEnabled extends MessageBase {
42714  constructor(isEnabled) {
42715    super(_MessageSeriesFixedEnabled);
42716    this._isEnabled = isEnabled;
42717  }
42718  get isEnabled() {
42719    return this._isEnabled;
42720  }
42721};
42722
42723// src/app/messages/message-data-fixed-avaiable.ts
42724var MessageDataFixedAvaiable = class _MessageDataFixedAvaiable extends MessageBase {
42725  constructor(isEnabled) {
42726    super(_MessageDataFixedAvaiable);
42727    this._isAvaiable = isEnabled;
42728  }
42729  get isAvaiable() {
42730    return this._isAvaiable;
42731  }
42732};
42733
42734// src/app/DoraWidget/dora-row/data/color.ts
42735var ColorAttribute = class {
42736  constructor() {
42737    this.color = "";
42738  }
42739};
42740__decorate([
42741  DoraPropertyDOC("Value", ATTRIBUTE_TYPE.COLOR, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
42742  DoraProperty,
42743  __metadata("design:type", String)
42744], ColorAttribute.prototype, "color", void 0);
42745
42746// src/app/DoraWidget/dora-data-grid/dora-data-grid.component.ts
42747var _c0 = ["innerWrapper"];
42748var _c1 = ["shadowLeft"];
42749var _c2 = ["shadowRight"];
42750var _c3 = ["dagTable"];
42751function DoraDataGridComponent_div_0_Template(rf, ctx) {
42752  if (rf & 1) {
42753    const _r1 = \u0275\u0275getCurrentView();
42754    \u0275\u0275elementStart(0, "div", 6);
42755    \u0275\u0275listener("click", function DoraDataGridComponent_div_0_Template_div_click_0_listener() {
42756      \u0275\u0275restoreView(_r1);
42757      const ctx_r1 = \u0275\u0275nextContext();
42758      return \u0275\u0275resetView(ctx_r1.onEnableSetting());
42759    });
42760    \u0275\u0275elementEnd();
42761  }
42762}
42763function DoraDataGridComponent_div_1_th_9_Template(rf, ctx) {
42764  if (rf & 1) {
42765    \u0275\u0275element(0, "th", 15);
42766  }
42767}
42768function DoraDataGridComponent_div_1_th_10_div_1_Template(rf, ctx) {
42769  if (rf & 1) {
42770    \u0275\u0275element(0, "div", 20);
42771  }
42772  if (rf & 2) {
42773    const singleTuplaDescription_r5 = \u0275\u0275nextContext().$implicit;
42774    const ctx_r1 = \u0275\u0275nextContext(2);
42775    \u0275\u0275styleProp("visibility", ctx_r1.getToolTipVisibility(singleTuplaDescription_r5));
42776    \u0275\u0275property("innerHTML", ctx_r1.getToolTip(singleTuplaDescription_r5), \u0275\u0275sanitizeHtml);
42777  }
42778}
42779function DoraDataGridComponent_div_1_th_10_div_2_Template(rf, ctx) {
42780  if (rf & 1) {
42781    const _r6 = \u0275\u0275getCurrentView();
42782    \u0275\u0275elementStart(0, "div", 21);
42783    \u0275\u0275listener("mouseenter", function DoraDataGridComponent_div_1_th_10_div_2_Template_div_mouseenter_0_listener() {
42784      \u0275\u0275restoreView(_r6);
42785      const singleTuplaDescription_r5 = \u0275\u0275nextContext().$implicit;
42786      const ctx_r1 = \u0275\u0275nextContext(2);
42787      return \u0275\u0275resetView(ctx_r1.onHeaderTooltipMouseEnter(singleTuplaDescription_r5));
42788    })("mouseleave", function DoraDataGridComponent_div_1_th_10_div_2_Template_div_mouseleave_0_listener() {
42789      \u0275\u0275restoreView(_r6);
42790      const singleTuplaDescription_r5 = \u0275\u0275nextContext().$implicit;
42791      const ctx_r1 = \u0275\u0275nextContext(2);
42792      return \u0275\u0275resetView(ctx_r1.onHeaderTooltipMouseLeave(singleTuplaDescription_r5));
42793    });
42794    \u0275\u0275elementEnd();
42795  }
42796}
42797function DoraDataGridComponent_div_1_th_10_Template(rf, ctx) {
42798  if (rf & 1) {
42799    const _r4 = \u0275\u0275getCurrentView();
42800    \u0275\u0275elementStart(0, "th", 16);
42801    \u0275\u0275listener("click", function DoraDataGridComponent_div_1_th_10_Template_th_click_0_listener() {
42802      const singleTuplaDescription_r5 = \u0275\u0275restoreView(_r4).$implicit;
42803      const ctx_r1 = \u0275\u0275nextContext(2);
42804      return \u0275\u0275resetView(ctx_r1.onHeaderClick(singleTuplaDescription_r5));
42805    });
42806    \u0275\u0275template(1, DoraDataGridComponent_div_1_th_10_div_1_Template, 1, 3, "div", 17)(2, DoraDataGridComponent_div_1_th_10_div_2_Template, 1, 0, "div", 18);
42807    \u0275\u0275element(3, "div", 19);
42808    \u0275\u0275elementEnd();
42809  }
42810  if (rf & 2) {
42811    const singleTuplaDescription_r5 = ctx.$implicit;
42812    const columnIdx_r7 = ctx.index;
42813    const ctx_r1 = \u0275\u0275nextContext(2);
42814    \u0275\u0275classMap(ctx_r1.getHeaderCssClass(columnIdx_r7, "Head", singleTuplaDescription_r5));
42815    \u0275\u0275advance();
42816    \u0275\u0275property("ngIf", ctx_r1.toolTipEnabled);
42817    \u0275\u0275advance();
42818    \u0275\u0275property("ngIf", ctx_r1.isToolTipEnabled(singleTuplaDescription_r5));
42819    \u0275\u0275advance();
42820    \u0275\u0275property("innerHTML", ctx_r1.getColumnName(singleTuplaDescription_r5), \u0275\u0275sanitizeHtml);
42821  }
42822}
42823function DoraDataGridComponent_div_1_tr_12_td_1_div_2_Template(rf, ctx) {
42824  if (rf & 1) {
42825    const _r8 = \u0275\u0275getCurrentView();
42826    \u0275\u0275elementStart(0, "div", 16);
42827    \u0275\u0275listener("click", function DoraDataGridComponent_div_1_tr_12_td_1_div_2_Template_div_click_0_listener($event) {
42828      \u0275\u0275restoreView(_r8);
42829      const row_r9 = \u0275\u0275nextContext(2).$implicit;
42830      const ctx_r1 = \u0275\u0275nextContext(2);
42831      return \u0275\u0275resetView(ctx_r1.onRowClick(row_r9, $event));
42832    });
42833    \u0275\u0275elementEnd();
42834  }
42835  if (rf & 2) {
42836    const row_r9 = \u0275\u0275nextContext(2).$implicit;
42837    \u0275\u0275classMap(row_r9.selected ? "dag-checkbox on" : "dag-checkbox off");
42838  }
42839}
42840function DoraDataGridComponent_div_1_tr_12_td_1_input_3_Template(rf, ctx) {
42841  if (rf & 1) {
42842    const _r10 = \u0275\u0275getCurrentView();
42843    \u0275\u0275elementStart(0, "input", 28);
42844    \u0275\u0275listener("change", function DoraDataGridComponent_div_1_tr_12_td_1_input_3_Template_input_change_0_listener($event) {
42845      \u0275\u0275restoreView(_r10);
42846      const row_r9 = \u0275\u0275nextContext(2).$implicit;
42847      const ctx_r1 = \u0275\u0275nextContext(2);
42848      return \u0275\u0275resetView(ctx_r1.onRowClick(row_r9, $event));
42849    });
42850    \u0275\u0275elementEnd();
42851  }
42852  if (rf & 2) {
42853    const row_r9 = \u0275\u0275nextContext(2).$implicit;
42854    const ctx_r1 = \u0275\u0275nextContext(2);
42855    \u0275\u0275property("checked", row_r9.selected);
42856    \u0275\u0275attribute("aria-label", ctx_r1.getCellValue(row_r9.getDataTupla("Description")));
42857  }
42858}
42859function DoraDataGridComponent_div_1_tr_12_td_1_Template(rf, ctx) {
42860  if (rf & 1) {
42861    \u0275\u0275elementStart(0, "td", 24)(1, "div", 25);
42862    \u0275\u0275template(2, DoraDataGridComponent_div_1_tr_12_td_1_div_2_Template, 1, 2, "div", 26)(3, DoraDataGridComponent_div_1_tr_12_td_1_input_3_Template, 1, 2, "input", 27);
42863    \u0275\u0275elementEnd()();
42864  }
42865  if (rf & 2) {
42866    const row_r9 = \u0275\u0275nextContext().$implicit;
42867    const ctx_r1 = \u0275\u0275nextContext(2);
42868    \u0275\u0275advance(2);
42869    \u0275\u0275property("ngIf", row_r9.Selectable && ctx_r1.checkBoxAsDiv);
42870    \u0275\u0275advance();
42871    \u0275\u0275property("ngIf", row_r9.Selectable && !ctx_r1.checkBoxAsDiv);
42872  }
42873}
42874function DoraDataGridComponent_div_1_tr_12_ng_container_2_td_1_div_4_Template(rf, ctx) {
42875  if (rf & 1) {
42876    \u0275\u0275element(0, "div", 34);
42877  }
42878  if (rf & 2) {
42879    const row_r9 = \u0275\u0275nextContext(3).$implicit;
42880    \u0275\u0275property("innerHTML", row_r9.Note, \u0275\u0275sanitizeHtml);
42881  }
42882}
42883function DoraDataGridComponent_div_1_tr_12_ng_container_2_td_1_Template(rf, ctx) {
42884  if (rf & 1) {
42885    \u0275\u0275elementStart(0, "td");
42886    \u0275\u0275element(1, "div", 30)(2, "div", 31)(3, "div", 32);
42887    \u0275\u0275template(4, DoraDataGridComponent_div_1_tr_12_ng_container_2_td_1_div_4_Template, 1, 1, "div", 33);
42888    \u0275\u0275elementEnd();
42889  }
42890  if (rf & 2) {
42891    const ctx_r10 = \u0275\u0275nextContext();
42892    const tupla_r12 = ctx_r10.$implicit;
42893    const columnIdx_r13 = ctx_r10.index;
42894    const row_r9 = \u0275\u0275nextContext().$implicit;
42895    const ctx_r1 = \u0275\u0275nextContext(2);
42896    \u0275\u0275classMap(ctx_r1.getCellCssClass(columnIdx_r13, "Cell", tupla_r12));
42897    \u0275\u0275attribute("colspan", ctx_r1.getColSpan(row_r9, columnIdx_r13, tupla_r12));
42898    \u0275\u0275advance();
42899    \u0275\u0275property("innerHTML", ctx_r1.getCellUnitSx(tupla_r12, row_r9), \u0275\u0275sanitizeHtml);
42900    \u0275\u0275advance();
42901    \u0275\u0275property("innerHTML", ctx_r1.getCellValue(tupla_r12), \u0275\u0275sanitizeHtml);
42902    \u0275\u0275advance();
42903    \u0275\u0275property("innerHTML", ctx_r1.getCellUnitDx(tupla_r12, row_r9), \u0275\u0275sanitizeHtml);
42904    \u0275\u0275advance();
42905    \u0275\u0275property("ngIf", columnIdx_r13 === 0 && row_r9.Note !== "");
42906  }
42907}
42908function DoraDataGridComponent_div_1_tr_12_ng_container_2_Template(rf, ctx) {
42909  if (rf & 1) {
42910    \u0275\u0275elementContainerStart(0);
42911    \u0275\u0275template(1, DoraDataGridComponent_div_1_tr_12_ng_container_2_td_1_Template, 5, 7, "td", 29);
42912    \u0275\u0275elementContainerEnd();
42913  }
42914  if (rf & 2) {
42915    const tupla_r12 = ctx.$implicit;
42916    const columnIdx_r13 = ctx.index;
42917    const row_r9 = \u0275\u0275nextContext().$implicit;
42918    const ctx_r1 = \u0275\u0275nextContext(2);
42919    \u0275\u0275advance();
42920    \u0275\u0275property("ngIf", ctx_r1.getColSpan(row_r9, columnIdx_r13, tupla_r12) >= 0);
42921  }
42922}
42923function DoraDataGridComponent_div_1_tr_12_Template(rf, ctx) {
42924  if (rf & 1) {
42925    \u0275\u0275elementStart(0, "tr");
42926    \u0275\u0275template(1, DoraDataGridComponent_div_1_tr_12_td_1_Template, 4, 2, "td", 22)(2, DoraDataGridComponent_div_1_tr_12_ng_container_2_Template, 2, 1, "ng-container", 23);
42927    \u0275\u0275elementEnd();
42928  }
42929  if (rf & 2) {
42930    const row_r9 = ctx.$implicit;
42931    const rowIdx_r14 = ctx.index;
42932    const ctx_r1 = \u0275\u0275nextContext(2);
42933    \u0275\u0275classMap(ctx_r1.getRowCssClass(rowIdx_r14, row_r9));
42934    \u0275\u0275advance();
42935    \u0275\u0275property("ngIf", ctx_r1.checkBoxDisabled === false);
42936    \u0275\u0275advance();
42937    \u0275\u0275property("ngForOf", ctx_r1.dataGrid.getRowDataTuplaDescriptionVisible(rowIdx_r14));
42938  }
42939}
42940function DoraDataGridComponent_div_1_Template(rf, ctx) {
42941  if (rf & 1) {
42942    const _r3 = \u0275\u0275getCurrentView();
42943    \u0275\u0275elementStart(0, "div", 7);
42944    \u0275\u0275element(1, "div", 8, 0);
42945    \u0275\u0275elementStart(3, "div", 9, 1);
42946    \u0275\u0275listener("scroll", function DoraDataGridComponent_div_1_Template_div_scroll_3_listener() {
42947      \u0275\u0275restoreView(_r3);
42948      const ctx_r1 = \u0275\u0275nextContext();
42949      return \u0275\u0275resetView(ctx_r1.onScroll());
42950    });
42951    \u0275\u0275elementStart(5, "table", 10, 2)(7, "thead")(8, "tr");
42952    \u0275\u0275template(9, DoraDataGridComponent_div_1_th_9_Template, 1, 0, "th", 11)(10, DoraDataGridComponent_div_1_th_10_Template, 4, 5, "th", 12);
42953    \u0275\u0275elementEnd()();
42954    \u0275\u0275elementStart(11, "tbody");
42955    \u0275\u0275template(12, DoraDataGridComponent_div_1_tr_12_Template, 3, 4, "tr", 13);
42956    \u0275\u0275elementEnd()()();
42957    \u0275\u0275element(13, "div", 14, 3);
42958    \u0275\u0275elementEnd();
42959  }
42960  if (rf & 2) {
42961    const ctx_r1 = \u0275\u0275nextContext();
42962    \u0275\u0275advance();
42963    \u0275\u0275styleProp("opacity", ctx_r1.opacityLeft);
42964    \u0275\u0275advance(8);
42965    \u0275\u0275property("ngIf", ctx_r1.checkBoxDisabled === false);
42966    \u0275\u0275advance();
42967    \u0275\u0275property("ngForOf", ctx_r1.dataGrid.getTuplasDescriptionVisible());
42968    \u0275\u0275advance(2);
42969    \u0275\u0275property("ngForOf", ctx_r1.dataGrid.DataRows);
42970    \u0275\u0275advance();
42971    \u0275\u0275styleProp("opacity", ctx_r1.opacityRight);
42972  }
42973}
42974var DoraDataGridComponent = class _DoraDataGridComponent extends WidgetBaseComponent {
42975  constructor() {
42976    super(...arguments);
42977    this.idgrid = "";
42978    this.checkBoxDisabled = false;
42979    this.checkBoxAsDiv = true;
42980    this.singleRowSelection = false;
42981    this.toolTipEnabled = false;
42982    this.columnsSelectable = true;
42983    this.seriesReverseOrder = false;
42984    this.numberFormat = "#.#";
42985    this.stockContent = false;
42986    this.fixedSeriesGeneric = true;
42987    this.fixedSeriesField = "";
42988    this.fixedSeriesColor = "";
42989    this.idrows = [];
42990    this.rowsConfig = [];
42991    this.tuplafilter = [];
42992    this.idrowsInitial = [];
42993    this.descriptiondrowsInitial = [];
42994    this.idcolumnsInitial = [];
42995    this.idrowsFilter = [];
42996    this.tuplafilterWrk = [];
42997    this.colors = [];
42998    this.idtuplaForStatus = "";
42999    this.lastDate = null;
43000    this.dataGrid = null;
43001    this.columnsSelected = [];
43002    this.columnsVisible = [];
43003    this.fixedSeriesEnabled = true;
43004    this.opacityLeft = 0;
43005    this.opacityRight = 0;
43006    this.forbiddenData = false;
43007    this.PositionElement = PositionElement;
43008    this.ATTRIBUTE_TYPE = ATTRIBUTE_TYPE;
43009  }
43010  onParameterInjectedFinished() {
43011    super.onParameterInjectedFinished();
43012    this.setForbiddenDataPresent();
43013    this.setInitialFixing2PublisherParameters();
43014    this.readData();
43015    this.messageService.getMessage(this.EventChannel, MessageSeriesFixedEnabled, this.CallerName).subscribe((message) => {
43016      this.fixedSeriesEnabled = message.data.isEnabled;
43017      this.sendEventsForSelectedRows(void 0);
43018    });
43019    this.messageService.getMessage(this.EventChannel, MessageColumnsVisible, this.CallerName).subscribe((message) => {
43020      this.columnsVisible = message.data.idColumns;
43021      this.rebuildVisibleColumns();
43022    });
43023    this.messageService.getMessage(this.EventChannel, MessageGridSelected, this.CallerName).subscribe((message) => {
43024      this.idgrid = message.data.idGrid;
43025      this.readData();
43026    });
43027    this.messageService.getMessage(this.EventChannel, MessageRowsUnselected, this.CallerName).subscribe((message) => {
43028      if (this.dataGrid === null) {
43029        console.warn("DataGrid not set");
43030        return;
43031      }
43032      const idRows = message.data.DataRows;
43033      this.dataGrid.unselectRows(idRows);
43034      this.messageService.sendMessage(this.EventChannel, new MessageRowsSelected(this.dataGrid.getSelectedRows(), this.getFixedSeriesInfos(), this.publisherParameters), this.CallerName);
43035    });
43036    this.messageService.getMessage(this.EventChannel, MessageRowsSelected, this.CallerName).subscribe((message) => {
43037      const idRows = [];
43038      message.data.DataRows.forEach((dataRow) => {
43039        idRows.push(dataRow.Id);
43040      });
43041      if (this.dataGrid === null) {
43042        console.warn("DataGrid not set");
43043        return;
43044      }
43045      this.dataGrid.selectRows(idRows);
43046      if (!this.stockContent) {
43047        this.messageService.sendMessage(this.EventChannel, new MessageSeriesSelected(this.dataGrid.rowsSelected2Series(this.seriesReverseOrder, this.columnsSelected), null), this.CallerName);
43048      }
43049    });
43050    this.messageService.getMessage(this.EventChannel, MessageColumnsSelected, this.CallerName).subscribe((message) => {
43051      this.columnsSelected = message.data.idColumns;
43052      if (this.dataGrid === null) {
43053        console.warn("DataGrid not set");
43054        return;
43055      }
43056      this.dataGrid.selectTuplaDescription(this.columnsSelected);
43057      if (!this.stockContent) {
43058        this.messageService.sendMessage(this.EventChannel, new MessageSeriesSelected(this.dataGrid.rowsSelected2Series(this.seriesReverseOrder, this.columnsSelected), null), this.CallerName);
43059      }
43060    });
43061    this.messageService.getMessage(this.EventChannel, MessageLastDate, this.CallerName).subscribe((message) => {
43062      this.lastDate = message.data.LastDate;
43063      this.readData();
43064    });
43065  }
43066  /**
43067   * Set the initial fixing to publisher parameters analyzing the rowsConfig
43068   */
43069  setInitialFixing2PublisherParameters() {
43070    const initialFixingParameter = new PublisherParameter();
43071    initialFixingParameter.name = "initialFixing";
43072    this.rowsConfig.forEach((rowConfig) => {
43073      if (initialFixingParameter.value !== "") {
43074        initialFixingParameter.value += ",";
43075      }
43076      if (rowConfig.initialFixing !== 0) {
43077        initialFixingParameter.value += rowConfig.idRow + ":" + rowConfig.initialFixing;
43078      }
43079    });
43080    if (initialFixingParameter.value !== "") {
43081      this.publisherParameters.push(initialFixingParameter);
43082    }
43083  }
43084  readData() {
43085    if (this.idgrid === "" && this.idrows.length < 1) {
43086      return;
43087    }
43088    if (this.idgrid !== "") {
43089      this.read([this.idgrid], DataType.GRID).subscribe((data) => {
43090        this.dataGrid = data.Data;
43091        this.onNewData();
43092      });
43093    } else if (this.idrows.length >= 1) {
43094      const rows2Subscribe = [];
43095      this.idrows.forEach((value) => {
43096        rows2Subscribe.push(value.key);
43097      });
43098      const publisherParameters = this.getPublisherParameters(this.publisherParameters);
43099      if (this.lastDate !== null) {
43100        const lastDate = formatDate(this.lastDate, "yyyyMMdd", "en");
43101        publisherParameters.set("enddate", lastDate);
43102      }
43103      this.read(rows2Subscribe, DataType.ROWS, publisherParameters).subscribe((data) => {
43104        this.dataGrid = data.Data;
43105        this.onNewData();
43106      });
43107    }
43108  }
43109  onRefresh() {
43110    super.onRefresh();
43111    this.readData();
43112  }
43113  onNewData() {
43114    this.setRowSelectable();
43115    this.filterDataGrid();
43116    this.setColorsToDataGrid();
43117    this.selectInitialRowsAndColumns();
43118    this.rebuildSelectedColumns();
43119    this.rebuildVisibleColumns();
43120    if (this.dataGrid !== null && this.dataGrid.getSelectedRows().length > 0) {
43121      this.messageService.sendMessage(this.EventChannel, new MessageSeriesSelected(this.dataGrid.rowsSelected2Series(this.seriesReverseOrder, this.columnsSelected), null), this.CallerName);
43122      this.messageService.sendMessage(this.EventChannel, new MessageRowsSelected(this.dataGrid.getSelectedRows(), this.getFixedSeriesInfos(), this.publisherParameters), this.CallerName);
43123    }
43124    this.setWorstBestDataRows();
43125    this.sendFixedDataAvaiable();
43126    const myTime = timer(1e3);
43127    myTime.subscribe((value) => {
43128      this.onScroll();
43129    });
43130  }
43131  selectInitialRowsAndColumns() {
43132    if (this.dataGrid == null) {
43133      return;
43134    }
43135    if (this.idcolumnsInitial.length > 0) {
43136      this.dataGrid.selectColumnById(this.idcolumnsInitial);
43137    } else {
43138      this.dataGrid.selectColumnsByType(TUPLA_TYPE.NUMBER);
43139    }
43140    if (this.idrowsInitial.length > 0) {
43141      this.dataGrid.selectRowsById(this.idrowsInitial);
43142    } else if (this.descriptiondrowsInitial.length > 0) {
43143      this.dataGrid.selectRowsByDescription(this.descriptiondrowsInitial);
43144    }
43145  }
43146  setRowSelectable() {
43147    if (this.dataGrid === null) {
43148      console.warn("DataGrid not set");
43149      return;
43150    }
43151    this.rowsConfig.forEach((rowConfig) => {
43152      const dataRow = this.dataGrid.getDataRow(rowConfig.idRow);
43153      if (dataRow !== void 0) {
43154        dataRow.Selectable = rowConfig.hasHistorical ? true : false;
43155      }
43156    });
43157  }
43158  setColorsToDataGrid() {
43159    if (this.colors.length === 0) {
43160      return;
43161    }
43162    if (this.dataGrid === null) {
43163      console.warn("DataGrid not set");
43164      return;
43165    }
43166    this.dataGrid.DataRows.forEach((dataRow, index) => {
43167      const idColor = this.colors[index % this.colors.length].color;
43168      dataRow.Color = idColor;
43169    });
43170  }
43171  filterDataGrid() {
43172    if (this.dataGrid === null || this.dataGrid.tuplasDescription === void 0) {
43173      console.warn("DataGrid not set");
43174      return;
43175    }
43176    if (this.idtuplaForStatus !== "") {
43177      const tupla = new DataTupla();
43178      tupla.Id = "STATUS";
43179      tupla.Type = TUPLA_TYPE.STRING;
43180      tupla.Value = "";
43181      const dataTuplaDescription = DataTuplaDescription.createFromTupla(tupla);
43182      this.dataGrid.tuplasDescription.push(dataTuplaDescription);
43183      this.dataGrid.DataRows.forEach((dataRow) => {
43184        const dataTupla = new DataTupla();
43185        dataTupla.Id = "STATUS";
43186        dataTupla.Type = TUPLA_TYPE.STRING;
43187        dataTupla.Value = "";
43188        dataTupla.DataType = "Tupla";
43189        dataTupla.Language = "en";
43190        dataRow.DataTuplas.push(dataTupla);
43191      });
43192    }
43193    this.tuplafilterWrk = [];
43194    if (this.tuplafilter.length !== 0) {
43195      this.tuplafilterWrk = this.tuplafilter;
43196      const tuplaDescriptionFiltered = [];
43197      this.tuplafilter.forEach((tupla) => {
43198        const dataTuplaDescription = this.dataGrid.tuplasDescription.find((dataTuplaDescription2) => {
43199          return dataTuplaDescription2.Id === tupla.key;
43200        });
43201        if (dataTuplaDescription !== void 0) {
43202          tuplaDescriptionFiltered.push(dataTuplaDescription);
43203        }
43204      });
43205      this.dataGrid.tuplasDescription = tuplaDescriptionFiltered;
43206      this.dataGrid.DataRows.forEach((dataRow) => {
43207        dataRow.DataTuplas = dataRow.DataTuplas.filter((dataTupla) => {
43208          return this.tuplafilter.find((id) => {
43209            return id.key === dataTupla.Id ? true : false;
43210          }) === void 0 ? false : true;
43211        });
43212      });
43213    } else {
43214      this.dataGrid.tuplasDescription.forEach((dataTuplaDescription) => {
43215        this.tuplafilterWrk.push(dataTuplaDescription.createTupla());
43216      });
43217    }
43218    if (this.idrowsFilter.length > 0) {
43219      const ids = this.idrowsFilter.map((id) => id.key);
43220      this.dataGrid.filterRowsById(ids);
43221    }
43222  }
43223  /**
43224   * Return the css class for the row
43225   */
43226  getRowCssClass(rowIndex, dataRow) {
43227    let result;
43228    result = dataRow.CssFormat;
43229    if (rowIndex % 2) {
43230      result += " odd";
43231    } else {
43232      result += " even";
43233    }
43234    if (dataRow.Selectable) {
43235      result += " selectable";
43236    } else {
43237      result += " unselectable";
43238    }
43239    if (dataRow.selected) {
43240      result += " selected";
43241    }
43242    if (this.idtuplaForStatus !== "") {
43243      const tuplasForTest = dataRow.getDataTupla(this.idtuplaForStatus);
43244      if (tuplasForTest !== void 0 && tuplasForTest.Type === TUPLA_TYPE.NUMBER) {
43245        if (tuplasForTest.Value > 0) {
43246          result += " pos";
43247        } else if (tuplasForTest.Value < 0) {
43248          result += " neg";
43249        } else {
43250          result += " equ";
43251        }
43252      }
43253    }
43254    return result;
43255  }
43256  getHeaderCssClass(cellIndex, baseName, dataTuplaDescription) {
43257    let result = baseName;
43258    result += " " + baseName + cellIndex.toString();
43259    if (!cellIndex) {
43260      result += " " + baseName + "First";
43261    }
43262    if (this.dataGrid !== null && this.dataGrid.tuplasDescription !== void 0 && cellIndex === this.dataGrid.tuplasDescription.length - 1) {
43263      result += " " + baseName + "Last";
43264    }
43265    if (dataTuplaDescription.Type === TUPLA_TYPE.NUMBER && this.columnsSelectable === true) {
43266      result += " " + baseName + (dataTuplaDescription.selected === true ? "selected" : "unselected");
43267    }
43268    result += " id-" + dataTuplaDescription.Id.replace(" ", "-");
43269    return result;
43270  }
43271  getColSpan(dataRow, cellIndex, dataTupla) {
43272    if (dataTupla === null || dataTupla === void 0) {
43273      return 0;
43274    }
43275    const colSpan = dataRow.getColSpan(cellIndex);
43276    return colSpan;
43277  }
43278  getCellCssClass(cellIndex, baseName, dataTupla) {
43279    let result = baseName;
43280    let idx = void 0;
43281    if (this.dataGrid !== null && this.dataGrid.tuplasDescription !== void 0) {
43282      idx = this.dataGrid.tuplasDescription.findIndex((tuplaDescription) => dataTupla !== void 0 && tuplaDescription.Id === dataTupla.Id);
43283    }
43284    if (idx === void 0) {
43285      idx = cellIndex;
43286    }
43287    result += " " + baseName + idx.toString();
43288    if (idx === 0) {
43289      result += " " + baseName + "First";
43290    }
43291    if (this.dataGrid !== null && this.dataGrid.tuplasDescription !== void 0) {
43292      const tuplaDescription = this.dataGrid.tuplasDescription[idx];
43293      if (tuplaDescription.Type === TUPLA_TYPE.NUMBER && this.columnsSelectable === true) {
43294        result += " " + baseName + (tuplaDescription.selected === true ? "selected" : "unselected");
43295      }
43296    }
43297    if (this.dataGrid !== null && this.dataGrid.tuplasDescription !== void 0 && idx === this.dataGrid.tuplasDescription.length - 1) {
43298      result += " " + baseName + "Last";
43299    }
43300    if (dataTupla != null) {
43301      result += " type-" + TUPLA_TYPE[dataTupla.Type];
43302      if (dataTupla.Value === "") {
43303        result += " empty";
43304      } else {
43305        result += " no-empty";
43306      }
43307      if (dataTupla.Type === TUPLA_TYPE.NUMBER) {
43308        if (dataTupla.Value > 0) {
43309          result += " pos";
43310        } else if (dataTupla.Value < 0) {
43311          result += " neg";
43312        } else {
43313          result += " equ";
43314        }
43315      }
43316    }
43317    if (dataTupla !== void 0) {
43318      result += " id-" + dataTupla.Id.replace(" ", "-");
43319    }
43320    return result;
43321  }
43322  getCellUnitSx(dataTupla, row) {
43323    if (this.isForbiddenData(row.Id)) {
43324      return "";
43325    }
43326    const tupla = this.tuplafilterWrk.find((tuplaElement) => {
43327      return tuplaElement.key === dataTupla.Id;
43328    });
43329    return tupla === void 0 ? "" : this.decodeUnit(tupla.unitSx, row);
43330  }
43331  getCellUnitDx(dataTupla, row) {
43332    if (this.isForbiddenData(row.Id)) {
43333      return "";
43334    }
43335    const tupla = this.tuplafilterWrk.find((tuplaElement) => {
43336      return tuplaElement.key === dataTupla.Id;
43337    });
43338    return tupla === void 0 ? "" : this.decodeUnit(tupla.unitDx, row);
43339  }
43340  getCellValue(dataTupla) {
43341    if (dataTupla == void 0) {
43342      return "";
43343    }
43344    const dataTuplaDescription = this.getTuplaFiltered(dataTupla.Id);
43345    let format = "";
43346    if (dataTupla.OutputFormat !== void 0 && dataTupla.OutputFormat !== "") {
43347      format = dataTupla.OutputFormat;
43348    } else {
43349      if (dataTuplaDescription !== void 0) {
43350        format = dataTuplaDescription.format === void 0 || dataTuplaDescription.format === "" ? this.numberFormat : dataTuplaDescription.format;
43351      }
43352    }
43353    return dataTupla.getTrimmedValue("-", format, this.translationService);
43354  }
43355  /**
43356   * Return the tupla description for the id
43357   */
43358  getTuplaFiltered(id) {
43359    return this.tuplafilterWrk.find((tupla) => {
43360      return tupla.key === id;
43361    });
43362  }
43363  decodeUnit(unit, row) {
43364    return unit.replace("[UNIT]", row.Units);
43365  }
43366  getColumnName(dataTuplaDescription) {
43367    return this.translationService.get(dataTuplaDescription.Name);
43368  }
43369  getToolTip(dataTuplaDescription) {
43370    if (this.toolTipEnabled === true) {
43371      return this.translationService.getWithDefault(dataTuplaDescription.Name + "_TOOLTIP", "");
43372    }
43373    return "";
43374  }
43375  /**
43376   * Return true if the tooltip is enabled
43377   */
43378  isToolTipEnabled(dataTuplaDescription) {
43379    if (this.toolTipEnabled === true) {
43380      if (this.getToolTip(dataTuplaDescription) !== "") {
43381        return true;
43382      } else {
43383        return false;
43384      }
43385    }
43386    return false;
43387  }
43388  getToolTipVisibility(dataTuplaDescription) {
43389    return dataTuplaDescription.tooltipVisible === true ? "visible" : "hidden";
43390  }
43391  onHeaderTooltipMouseEnter(dataTuplaDescription) {
43392    dataTuplaDescription.tooltipVisible = true;
43393  }
43394  onHeaderTooltipMouseLeave(dataTuplaDescription) {
43395    dataTuplaDescription.tooltipVisible = false;
43396  }
43397  rebuildSelectedColumns() {
43398    this.columnsSelected = [];
43399    if (this.dataGrid !== null && this.dataGrid.tuplasDescription !== void 0) {
43400      this.dataGrid.tuplasDescription.forEach((x) => {
43401        if (x.selected) {
43402          this.columnsSelected.push(x.Id);
43403        }
43404      });
43405    }
43406  }
43407  setWorstBestDataRows() {
43408    if (this.idtuplaForStatus === "") {
43409      return;
43410    }
43411    if (this.dataGrid === null) {
43412      return;
43413    }
43414    if (this.forbiddenData) {
43415      this.setValuesForForbiddenData();
43416      return;
43417    }
43418    if (this.dataGrid.DataRows.length === 1) {
43419      this.dataGrid.DataRows[0].addCssClass("best");
43420      return;
43421    }
43422    const dataRowMax = this.dataGrid.DataRows.reduce((prev, current) => {
43423      const tuplaPrev = prev.getDataTupla(this.idtuplaForStatus);
43424      const tuplaCurrent = current.getDataTupla(this.idtuplaForStatus);
43425      if (tuplaPrev === void 0 || tuplaCurrent === void 0) {
43426        return prev;
43427      }
43428      if (tuplaPrev.Value > tuplaCurrent.Value) {
43429        return prev;
43430      } else {
43431        return current;
43432      }
43433    });
43434    let tuplaStatus = dataRowMax.getDataTupla("STATUS");
43435    if (tuplaStatus !== void 0) {
43436      tuplaStatus.Value = "BEST";
43437    }
43438    dataRowMax.addCssClass("best");
43439    const dataRowMin = this.dataGrid.DataRows.reduce((prev, current) => {
43440      const tuplaPrev = prev.getDataTupla(this.idtuplaForStatus);
43441      const tuplaCurrent = current.getDataTupla(this.idtuplaForStatus);
43442      if (tuplaPrev !== void 0 && tuplaCurrent !== void 0 && tuplaPrev.Value < tuplaCurrent.Value) {
43443        return prev;
43444      } else {
43445        return current;
43446      }
43447    });
43448    tuplaStatus = dataRowMin.getDataTupla("STATUS");
43449    if (tuplaStatus !== void 0) {
43450      tuplaStatus.Value = "WORST";
43451    }
43452    dataRowMin.addCssClass("worst");
43453  }
43454  rebuildVisibleColumns() {
43455    if (this.columnsVisible.length === 0 || this.dataGrid === null) {
43456      return;
43457    }
43458    this.dataGrid.setColumnsVisible(this.columnsVisible);
43459  }
43460  // User Events
43461  onRowClick(dataRow, event2) {
43462    if (this.dataGrid === null) {
43463      console.error("DataGrid not set");
43464      return;
43465    }
43466    dataRow.swapSelected();
43467    if (this.singleRowSelection === true && dataRow.selected === true) {
43468      this.dataGrid.selectRowMutex(dataRow.Id);
43469    }
43470    this.sendEventsForSelectedRows(event2);
43471    this.sendFixedDataAvaiable();
43472  }
43473  sendEventsForSelectedRows(event2) {
43474    if (this.dataGrid === null) {
43475      return;
43476    }
43477    if (!this.stockContent && event2 !== void 0 && event2.target !== null) {
43478      const targetPosition = new PositionElement(event2.target);
43479      this.messageService.sendMessage(this.EventChannel, new MessageSeriesSelected(this.dataGrid.rowsSelected2Series(this.seriesReverseOrder, this.columnsSelected), targetPosition), this.CallerName);
43480    }
43481    this.messageService.sendMessage(this.EventChannel, new MessageRowsSelected(this.dataGrid.getSelectedRows(), this.getFixedSeriesInfos(), this.publisherParameters), this.CallerName);
43482  }
43483  /**
43484   * Return the fixed series info
43485   */
43486  getFixedSeriesInfos() {
43487    const fixedSeriesInfos = [];
43488    if (this.dataGrid === null) {
43489      console.warn("DataGrid not set");
43490      return fixedSeriesInfos;
43491    }
43492    if (this.fixedSeriesField !== "" && this.fixedSeriesEnabled) {
43493      if (this.fixedSeriesGeneric === true) {
43494        const selectedRows = this.dataGrid.getSelectedRows();
43495        if (selectedRows.length > 0) {
43496          const dataTupla = selectedRows[0].getDataTupla(this.fixedSeriesField);
43497          if (dataTupla !== void 0) {
43498            const fixedSeriesInfo = new FixedSeriesInfo();
43499            fixedSeriesInfo.name = this.getColumnName(this.dataGrid.getTuplaDescription(this.fixedSeriesField));
43500            fixedSeriesInfo.value = dataTupla.Value;
43501            fixedSeriesInfo.type = dataTupla.Type;
43502            fixedSeriesInfo.color = this.fixedSeriesColor;
43503            fixedSeriesInfos.push(fixedSeriesInfo);
43504          }
43505        }
43506      } else {
43507        this.dataGrid.getSelectedRows().forEach((dataRow) => {
43508          const dataTupla = dataRow.getDataTupla(this.fixedSeriesField);
43509          if (dataTupla !== void 0) {
43510            const fixedSeriesInfo = new FixedSeriesInfo();
43511            fixedSeriesInfo.name = this.getColumnName(this.dataGrid.getTuplaDescription(this.fixedSeriesField));
43512            fixedSeriesInfo.value = dataTupla.Value;
43513            fixedSeriesInfo.type = dataTupla.Type;
43514            fixedSeriesInfo.color = this.fixedSeriesColor;
43515            fixedSeriesInfos.push(fixedSeriesInfo);
43516          }
43517        });
43518      }
43519    }
43520    return fixedSeriesInfos;
43521  }
43522  /**
43523   * Send message MessageDataFixedAvaiable
43524   */
43525  sendFixedDataAvaiable() {
43526    let dataFixedAvaiable = false;
43527    if (this.fixedSeriesField !== "" && this.dataGrid != null) {
43528      const selectedRows = this.dataGrid.getSelectedRows();
43529      if (selectedRows.length > 0) {
43530        const dataTupla = selectedRows[0].getDataTupla(this.fixedSeriesField);
43531        if (dataTupla !== void 0) {
43532          dataFixedAvaiable = true;
43533        }
43534      }
43535    }
43536    this.messageService.sendMessage(this.EventChannel, new MessageDataFixedAvaiable(dataFixedAvaiable), this.CallerName);
43537  }
43538  onHeaderClick(tuplaDescription) {
43539    if (tuplaDescription.Type === TUPLA_TYPE.NUMBER && this.columnsSelectable === true) {
43540      tuplaDescription.switchSelected();
43541      this.rebuildSelectedColumns();
43542      if (!this.stockContent) {
43543        if (this.dataGrid === null) {
43544          console.warn("DataGrid not set");
43545        } else {
43546          this.messageService.sendMessage(this.EventChannel, new MessageSeriesSelected(this.dataGrid.rowsSelected2Series(this.seriesReverseOrder, this.columnsSelected), null), this.CallerName);
43547        }
43548      }
43549    }
43550  }
43551  onScroll() {
43552    if (this.innerWrapper === void 0) {
43553      return;
43554    }
43555    if (this.shadowLeft === void 0 || this.shadowRight === void 0 || this.dagTable === void 0) {
43556      return;
43557    }
43558    const tableScrollLeft = this.innerWrapper.nativeElement.scrollLeft;
43559    const tableScrollRight = this.dagTable.nativeElement.offsetWidth - this.innerWrapper.nativeElement.offsetWidth - this.innerWrapper.nativeElement.scrollLeft;
43560    this.opacityLeft = this.getScrollOpacity(this.shadowLeft.nativeElement, tableScrollLeft);
43561    this.opacityRight = this.getScrollOpacity(this.shadowRight.nativeElement, tableScrollRight);
43562  }
43563  getScrollOpacity(shadowElement, scrollPosition) {
43564    const shadowElemWidth = shadowElement.offsetWidth;
43565    if (scrollPosition / shadowElemWidth <= 0) {
43566      return 0;
43567    } else if (scrollPosition <= shadowElemWidth) {
43568      return scrollPosition / shadowElemWidth;
43569    }
43570    return 1;
43571  }
43572  // region: forbidden data
43573  setForbiddenDataPresent() {
43574    this.forbiddenData = false;
43575    this.rowsConfig.forEach((rowConfig) => {
43576      if (rowConfig.hasHistorical === false) {
43577        this.forbiddenData = true;
43578      }
43579    });
43580  }
43581  isForbiddenData(idrow) {
43582    const rowConfig = this.rowsConfig.find((rowConfig2) => {
43583      return rowConfig2.idRow === idrow;
43584    });
43585    if (rowConfig === void 0) {
43586      return false;
43587    }
43588    return rowConfig.hasHistorical === true ? false : true;
43589  }
43590  setValuesForForbiddenData() {
43591    if (this.dataGrid === null) {
43592      console.warn("DataGrid not set");
43593      return;
43594    }
43595    if (this.dataGrid.DataRows === null) {
43596      console.warn("DataGrid.DataRows not set");
43597      return;
43598    }
43599    this.dataGrid.DataRows.forEach((dataRow) => {
43600      if (this.isForbiddenData(dataRow.Id)) {
43601        dataRow.Selectable = false;
43602        dataRow.addCssClass("forbidden");
43603        dataRow.DataTuplas.forEach((dataTupla) => {
43604          if (dataTupla.Id === "STATUS") {
43605            dataTupla.Value = this.translationService.get("FORBIDDEN");
43606          } else if (dataTupla.Type !== TUPLA_TYPE.STRING) {
43607            dataTupla.Value = "";
43608          }
43609        });
43610      }
43611    });
43612  }
43613  static {
43614    this.\u0275fac = /* @__PURE__ */ (() => {
43615      let \u0275DoraDataGridComponent_BaseFactory;
43616      return function DoraDataGridComponent_Factory(__ngFactoryType__) {
43617        return (\u0275DoraDataGridComponent_BaseFactory || (\u0275DoraDataGridComponent_BaseFactory = \u0275\u0275getIn
43617heritedFactory(_DoraDataGridComponent)))(__ngFactoryType__ || _DoraDataGridComponent);
43618      };
43619    })();
43620  }
43621  static {
43622    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraDataGridComponent, selectors: [["dora-data-grid"]], viewQuery: function DoraDataGridComponent_Query(rf, ctx) {
43623      if (rf & 1) {
43624        \u0275\u0275viewQuery(_c0, 5);
43625        \u0275\u0275viewQuery(_c1, 5);
43626        \u0275\u0275viewQuery(_c2, 5);
43627        \u0275\u0275viewQuery(_c3, 5);
43628      }
43629      if (rf & 2) {
43630        let _t;
43631        \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.innerWrapper = _t.first);
43632        \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.shadowLeft = _t.first);
43633        \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.shadowRight = _t.first);
43634        \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.dagTable = _t.first);
43635      }
43636    }, standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 2, vars: 2, consts: [["shadowLeft", ""], ["innerWrapper", ""], ["dagTable", ""], ["shadowRight", ""], ["class", "setting-command", 3, "click", 4, "ngIf"], ["class", "DAG-Table-wrapper", 4, "ngIf"], [1, "setting-command", 3, "click"], [1, "DAG-Table-wrapper"], [1, "table-shadow", "shadow-left"], [1, "table-inner-wrapper", 3, "scroll"], [1, "DAG-Table"], ["class", "Head selector", 4, "ngIf"], [3, "class", "click", 4, "ngFor", "ngForOf"], [3, "class", 4, "ngFor", "ngForOf"], [1, "table-shadow", "shadow-right"], [1, "Head", "selector"], [3, "click"], ["class", "header-tooltip", 3, "visibility", "innerHTML", 4, "ngIf"], ["class", "tooltip-command", 3, "mouseenter", "mouseleave", 4, "ngIf"], ["role", "button", "tabindex", "0", 1, "content", 3, "innerHTML"], [1, "header-tooltip", 3, "innerHTML"], [1, "tooltip-command", 3, "mouseenter", "mouseleave"], ["class", "Cell selector", 4, "ngIf"], [4, "ngFor", "ngForOf"], [1, "Cell", "selector"], [1, "selector-container"], [3, "class", "click", 4, "ngIf"], ["type", "checkbox", 3, "checked", "change", 4, "ngIf"], ["type", "checkbox", 3, "change", "checked"], [3, "class", 4, "ngIf"], [1, "unit-sx", 3, "innerHTML"], [1, "content", 3, "innerHTML"], [1, "unit-dx", 3, "innerHTML"], ["class", "dagNote", 3, "innerHTML", 4, "ngIf"], [1, "dagNote", 3, "innerHTML"]], template: function DoraDataGridComponent_Template(rf, ctx) {
43637      if (rf & 1) {
43638        \u0275\u0275template(0, DoraDataGridComponent_div_0_Template, 1, 0, "div", 4)(1, DoraDataGridComponent_div_1_Template, 15, 7, "div", 5);
43639      }
43640      if (rf & 2) {
43641        \u0275\u0275property("ngIf", ctx.settingEnabled);
43642        \u0275\u0275advance();
43643        \u0275\u0275property("ngIf", ctx.dataGrid);
43644      }
43645    }, dependencies: [NgForOf, NgIf], styles: ["\n\n.DAG-Table[_ngcontent-%COMP%] {\n  width: 100%;\n}\n.DAG-Table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   .Head[_ngcontent-%COMP%] {\n  position: relative;\n}\n.DAG-Table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   .Head.selector[_ngcontent-%COMP%] {\n  width: 10px;\n}\n.DAG-Table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   .Head.Headselected[_ngcontent-%COMP%] {\n  color: red;\n  cursor: pointer;\n}\n.DAG-Table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   .Head.Headunselected[_ngcontent-%COMP%] {\n  color: grey;\n  cursor: pointer;\n}\n.DAG-Table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   .Head[_ngcontent-%COMP%]   .header-tooltip[_ngcontent-%COMP%] {\n  display: block;\n  background: #eaeaea;\n  z-index: 4000;\n  position: absolute;\n  top: -30px;\n}\n.DAG-Table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   .Head[_ngcontent-%COMP%]   .tooltip-command[_ngcontent-%COMP%] {\n  display: block;\n  overflow: hidden;\n  background: #eaeaea;\n  width: 10px;\n  height: 10px;\n}\n.DAG-Table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]   td.Cell.selector[_ngcontent-%COMP%] {\n  width: 10px;\n  height: 10px;\n}\n.DAG-Table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]   td.Cell.selector[_ngcontent-%COMP%]   .selector-container[_ngcontent-%COMP%]   .dag-checkbox[_ngcontent-%COMP%] {\n  cursor: pointer;\n  width: 10px;\n  height: 10px;\n  display: block;\n  overflow: hidden;\n  border: 1px solid black;\n}\n.DAG-Table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]   td.Cell.selector[_ngcontent-%COMP%]   .selector-container[_ngcontent-%COMP%]   .dag-checkbox.on[_ngcontent-%COMP%] {\n  background-color: black;\n}\n.DAG-Table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]   td.Cell.selector[_ngcontent-%COMP%]   .selector-container[_ngcontent-%COMP%]   .dag-checkbox.off[_ngcontent-%COMP%] {\n  background-color: white;\n}\n.DAG-Table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]   td.Cell.type-NUMBER[_ngcontent-%COMP%], \n.DAG-Table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]   td.Cell.type-DATETIME[_ngcontent-%COMP%], \n.DAG-Table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]   td.Cell.type-PERCENTAGE[_ngcontent-%COMP%] {\n  text-align: right;\n}\n.DAG-Table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]   td.Cell.type-NUMBER.neg[_ngcontent-%COMP%], \n.DAG-Table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]   td.Cell.type-DATETIME.neg[_ngcontent-%COMP%], \n.DAG-Table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]   td.Cell.type-PERCENTAGE.neg[_ngcontent-%COMP%] {\n  color: red;\n}\n.DAG-Table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]   td.Cellunselected[_ngcontent-%COMP%] {\n  opacity: 0.3;\n}"] });
43646  }
43647};
43648__decorate([
43649  DoraPropertyDOC("Id griglia da utilizzare. Questa informazione pu\xF2 essere sovrascritta da altri widged che selezionano le tabelle (es. dora-data-grid-selector-tab)", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.TABLE_LIST, true),
43650  DoraProperty,
43651  __metadata("design:type", String)
43652], DoraDataGridComponent.prototype, "idgrid", void 0);
43653__decorate([
43654  DoraPropertyDOC("Abilita o disabilita la checkbox per selezionare le singole", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43655  DoraProperty,
43656  __metadata("design:type", Boolean)
43657], DoraDataGridComponent.prototype, "checkBoxDisabled", void 0);
43658__decorate([
43659  DoraPropertyDOC("Nel caso checkBoxDisabled indica se la check box deve essere rappresentato come div", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43660  DoraProperty,
43661  __metadata("design:type", Boolean)
43662], DoraDataGridComponent.prototype, "checkBoxAsDiv", void 0);
43663__decorate([
43664  DoraPropertyDOC("Abilita o disabilita la checkbox per selezionare le singole", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43665  DoraProperty,
43666  __metadata("design:type", Boolean)
43667], DoraDataGridComponent.prototype, "singleRowSelection", void 0);
43668__decorate([
43669  DoraPropertyDOC("Abilita o disabilita il tooltip nell'intestazione delle colonne", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43670  DoraProperty,
43671  __metadata("design:type", Boolean)
43672], DoraDataGridComponent.prototype, "toolTipEnabled", void 0);
43673__decorate([
43674  DoraPropertyDOC("Colonne selezionabili (per costruire le series da inviare al grafico)", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43675  DoraProperty,
43676  __metadata("design:type", Boolean)
43677], DoraDataGridComponent.prototype, "columnsSelectable", void 0);
43678__decorate([
43679  DoraPropertyDOC("Inverte righe/colonne nella costruizione delle series da inviare al grafico", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43680  DoraProperty,
43681  __metadata("design:type", Boolean)
43682], DoraDataGridComponent.prototype, "seriesReverseOrder", void 0);
43683__decorate([
43684  DoraPropertyDOC("Formato dei numeri nel caso non sia contenuto nella fonte dati (DataManagement)", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43685  DoraProperty,
43686  __metadata("design:type", String)
43687], DoraDataGridComponent.prototype, "numberFormat", void 0);
43688__decorate([
43689  DoraPropertyDOC("Indica se la tabella \xE8 una lista si azioni di borsa", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43690  DoraProperty,
43691  __metadata("design:type", Boolean)
43692], DoraDataGridComponent.prototype, "stockContent", void 0);
43693__decorate([
43694  DoraPropertyDOC("Generic field (true) or specific field (false). If true the fixedSeriesField is the same for all rows, so it take the value from the first row", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43695  DoraProperty,
43696  __metadata("design:type", Boolean)
43697], DoraDataGridComponent.prototype, "fixedSeriesGeneric", void 0);
43698__decorate([
43699  DoraPropertyDOC("Se valorizzato costruisce una serie storica mettendo in X il valore del campo indicato. Le Y vengono calcolate analizzando le altre series", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43700  DoraProperty,
43701  __metadata("design:type", String)
43702], DoraDataGridComponent.prototype, "fixedSeriesField", void 0);
43703__decorate([
43704  DoraPropertyDOC("Colore della serie fixed", ATTRIBUTE_TYPE.COLOR, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43705  DoraProperty,
43706  __metadata("design:type", String)
43707], DoraDataGridComponent.prototype, "fixedSeriesColor", void 0);
43708__decorate([
43709  DoraPropertyDOC("Elenco delle righe da visualizzare", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43710  DoraPropertyArray(Id),
43711  __metadata("design:type", Array)
43712], DoraDataGridComponent.prototype, "idrows", void 0);
43713__decorate([
43714  DoraPropertyDOC("Configurazione delle righe", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43715  DoraPropertyArray(RowConfig),
43716  __metadata("design:type", Array)
43717], DoraDataGridComponent.prototype, "rowsConfig", void 0);
43718__decorate([
43719  DoraPropertyDOC("Elenco dei campi (TUPLA) da mostrare", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43720  DoraPropertyArray(Tupla),
43721  __metadata("design:type", Array)
43722], DoraDataGridComponent.prototype, "tuplafilter", void 0);
43723__decorate([
43724  DoraPropertyDOC("Elenco delle righe da visualizzare inizialmente (per Id)", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43725  DoraPropertyArray(Id),
43726  __metadata("design:type", Array)
43727], DoraDataGridComponent.prototype, "idrowsInitial", void 0);
43728__decorate([
43729  DoraPropertyDOC("Elenco delle righe da visualizzare inizialmente (per descrizione)", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43730  DoraPropertyArray(Id),
43731  __metadata("design:type", Array)
43732], DoraDataGridComponent.prototype, "descriptiondrowsInitial", void 0);
43733__decorate([
43734  DoraPropertyDOC("Elenco delle colonne da visualizzare inizialmente", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43735  DoraPropertyArray(Id),
43736  __metadata("design:type", Array)
43737], DoraDataGridComponent.prototype, "idcolumnsInitial", void 0);
43738__decorate([
43739  DoraPropertyDOC("Elenco degli Id di riga da visualizzare (filtro post-caricamento, usato con idgrid)", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43740  DoraPropertyArray(Id),
43741  __metadata("design:type", Array)
43742], DoraDataGridComponent.prototype, "idrowsFilter", void 0);
43743__decorate([
43744  DoraPropertyDOC("if present is the list of colors to use for the rows. If colors are less than rows, the colors are repeated", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43745  DoraPropertyArray(ColorAttribute),
43746  __metadata("design:type", Array)
43747], DoraDataGridComponent.prototype, "colors", void 0);
43748__decorate([
43749  DoraPropertyDOC("if present is the tupla id to check to determine if the row is positive or negative", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
43750  DoraProperty,
43751  __metadata("design:type", String)
43752], DoraDataGridComponent.prototype, "idtuplaForStatus", void 0);
43753(() => {
43754  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraDataGridComponent, { className: "DoraDataGridComponent", filePath: "src/app/dorawidget/dora-data-grid/dora-data-grid.component.ts", lineNumber: 38 });
43755})();
43756
43757// src/app/DoraWidget/dora-grid-data-notes/dora-grid-notes.component.ts
43758function DoraGridNotesComponent_div_0_div_1_Template(rf, ctx) {
43759  if (rf & 1) {
43760    \u0275\u0275element(0, "div", 3);
43761  }
43762  if (rf & 2) {
43763    const note_r1 = ctx.$implicit;
43764    \u0275\u0275property("innerHTML", note_r1, \u0275\u0275sanitizeHtml);
43765  }
43766}
43767function DoraGridNotesComponent_div_0_Template(rf, ctx) {
43768  if (rf & 1) {
43769    \u0275\u0275elementStart(0, "div", 1);
43770    \u0275\u0275template(1, DoraGridNotesComponent_div_0_div_1_Template, 1, 1, "div", 2);
43771    \u0275\u0275elementEnd();
43772  }
43773  if (rf & 2) {
43774    const ctx_r1 = \u0275\u0275nextContext();
43775    \u0275\u0275advance();
43776    \u0275\u0275property("ngForOf", ctx_r1.dataGrid == null ? null : ctx_r1.dataGrid.notes);
43777  }
43778}
43779var DoraGridNotesComponent = class _DoraGridNotesComponent extends WidgetBaseGridComponent {
43780  constructor(elementRef, messageService, configurationService, publisher, widgetService, http, translationService) {
43781    super(elementRef, messageService, configurationService, publisher, widgetService, http, translationService);
43782    this.flSelectFirstRow = false;
43783  }
43784  static {
43785    this.\u0275fac = function DoraGridNotesComponent_Factory(__ngFactoryType__) {
43786      return new (__ngFactoryType__ || _DoraGridNotesComponent)(\u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(MessageService), \u0275\u0275directiveInject(ConfigurationService), \u0275\u0275directiveInject(PublisherService), \u0275\u0275directiveInject(WidgetService), \u0275\u0275directiveInject(HttpClient), \u0275\u0275directiveInject(TranslationService));
43787    };
43788  }
43789  static {
43790    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraGridNotesComponent, selectors: [["dora-grid-data-notes"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "DAG-dora-grid-notes", 4, "ngIf"], [1, "DAG-dora-grid-notes"], ["class", "DAG-note", 3, "innerHTML", 4, "ngFor", "ngForOf"], [1, "DAG-note", 3, "innerHTML"]], template: function DoraGridNotesComponent_Template(rf, ctx) {
43791      if (rf & 1) {
43792        \u0275\u0275template(0, DoraGridNotesComponent_div_0_Template, 2, 1, "div", 0);
43793      }
43794      if (rf & 2) {
43795        \u0275\u0275property("ngIf", ctx.dataGrid);
43796      }
43797    }, dependencies: [NgForOf, NgIf], encapsulation: 2 });
43798  }
43799};
43800(() => {
43801  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraGridNotesComponent, { className: "DoraGridNotesComponent", filePath: "src/app/dorawidget/dora-grid-data-notes/dora-grid-notes.component.ts", lineNumber: 17 });
43802})();
43803
43804// src/app/DoraWidget/dora-chart/dora-chart.component.ts
43805var Highcharts3 = __toESM(require_highcharts());
43806var import_exporting2 = __toESM(require_exporting());
43807
43808// src/app/messages/message-chart-type.ts
43809var MessageChartType = class _MessageChartType extends MessageBase {
43810  constructor(type) {
43811    super(_MessageChartType);
43812    this._chartType = type;
43813  }
43814  get chartType() {
43815    return this._chartType;
43816  }
43817};
43818
43819// src/app/DoraWidget/dora-chart/chart-builder-base.ts
43820var ChartBuilderBase = class {
43821  constructor(locale, legendClickEnabled = true) {
43822    this.locale = locale;
43823    this.legendClickEnabled = legendClickEnabled;
43824  }
43825  /**
43826   * Set language constants
43827   */
43828  // tslint:disable-next-line:ban-types
43829  setLanguage(chartOptions) {
43830    switch (this.locale) {
43831      case "it":
43832        this.setOption(chartOptions, "lang", ChartOption.create("thousandsSep", "s", "."));
43833        this.setOption(chartOptions, "lang", ChartOption.create("decimalPoint", "s", ","));
43834        this.setOption(chartOptions, "lang", ChartOption.createArray("weekdays", ["Domenica", "Luned\xEC", "Marted\xEC", "Mercoled\xEC", "Gioved\xEC", "Venerd\xEC", "Sabato"]));
43835        this.setOption(chartOptions, "lang", ChartOption.createArray("months", ["Gennaio", "Febbraio", "Marzo", "Aprile", "Maggio", "Giugno", "Luglio", "Agosto", "Settembre", "Ottobre", "Novembre", "Dicembre"]));
43836        this.setOption(chartOptions, "lang", ChartOption.createArray("shortMonths", ["Gen", "Feb", "Mar", "Apr", "Mag", "Giu", "Lug", "Ago", "Set", "Ott", "Nov", "Dic"]));
43837        break;
43838      case "de":
43839        this.setOption(chartOptions, "lang", ChartOption.create("thousandsSep", "s", "."));
43840        this.setOption(chartOptions, "lang", ChartOption.create("decimalPoint", "s", ","));
43841        this.setOption(chartOptions, "lang", ChartOption.createArray("weekdays", ["Sonntag", "Montag", "Dienstag", "Mittwoch", "Donnerstag", "Freitag", "Samstag"]));
43842        this.setOption(chartOptions, "lang", ChartOption.createArray("months", ["Januar", "Februar", "M\xE4rz", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember"]));
43843        this.setOption(chartOptions, "lang", ChartOption.createArray("shortMonths", ["Jan", "Feb", "M\xE4r", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dez"]));
43844        break;
43845      case "fr":
43846        this.setOption(chartOptions, "lang", ChartOption.create("thousandsSep", "s", "."));
43847        this.setOption(chartOptions, "lang", ChartOption.create("decimalPoint", "s", ","));
43848        this.setOption(chartOptions, "lang", ChartOption.createArray("weekdays", ["Dimanche", "Lundi", "Mardi", "Mercredi", "Jeudi", "Vendredi", "Samedi"]));
43849        this.setOption(chartOptions, "lang", ChartOption.createArray("months", ["Janvier", "F\xE9vrier", "Mars", "Avril", "Mai", "Juin", "Juillet", "Ao\xFBt", "Septembre", "Octobre", "Novembre", "D\xE9cembre"]));
43850        this.setOption(chartOptions, "lang", ChartOption.createArray("shortMonths", ["Jan", "F\xE9v", "Mar", "Avr", "Mai", "Juin", "Juil", "Ao\xFBt", "Sep", "Oct", "Nov", "D\xE9c"]));
43851        break;
43852      case "en":
43853      default:
43854    }
43855  }
43856  // tslint:disable-next-line:ban-types no-shadowed-variable
43857  setOption(dst, root, option) {
43858    option.setOption(dst, root);
43859  }
43860};
43861
43862// src/app/DoraWidget/dora-chart/chart-builder.ts
43863var import_exporting = __toESM(require_exporting());
43864var import_highcharts = __toESM(require_highcharts());
43865import_exporting.default.default(import_highcharts.default);
43866var ChartBuilder = class extends ChartBuilderBase {
43867  constructor(chartType, graphSkinConfiguration, seriesList, chart, legend, tooltip, locale, xAxis, yAxis, plotOptionsForType, title, customToolTip, outputFormat, outputFormatFromData, legendClickEnabled = true) {
43868    super(locale, legendClickEnabled);
43869    this.chartType = CHART_TYPE.LINEAR;
43870    this.chart = import_highcharts.default;
43871    this.chartOptions = {};
43872    this.xAxis = [];
43873    this.yAxis = [];
43874    this.legend = [];
43875    this.tooltip = [];
43876    this.seriesList = [];
43877    this.title = "";
43878    this.customToolTip = false;
43879    this.chartType = chartType;
43880    this.chartOptions = JSON.parse(graphSkinConfiguration);
43881    this.xAxis = xAxis;
43882    this.yAxis = yAxis;
43883    this.legend = legend;
43884    this.tooltip = tooltip;
43885    this.title = title;
43886    this.customToolTip = customToolTip;
43887    this.outputFormat = outputFormat;
43888    this.outputFormatFromData = outputFormatFromData;
43889    if (this.chartOptions.chart === void 0) {
43890      console.error("chart options not defined");
43891      return;
43892    }
43893    switch (this.chartType) {
43894      case CHART_TYPE.COLUMNSTACK:
43895        this.chartOptions.chart.type = "column";
43896        this.chartOptions.plotOptions = { column: { stacking: "normal" } };
43897        this.setOptions(this.chartOptions.plotOptions, "column", plotOptionsForType);
43898        break;
43899      case CHART_TYPE.COLUMN:
43900        this.chartOptions.chart.type = "column";
43901        this.chartOptions.plotOptions = { column: { stacking: void 0 } };
43902        this.setOptions(this.chartOptions.plotOptions, "column", plotOptionsForType);
43903        break;
43904      case CHART_TYPE.BAR:
43905        this.chartOptions.chart.type = "bar";
43906        this.chartOptions.plotOptions = { bar: {} };
43907        this.setOptions(this.chartOptions.plotOptions, "bar", plotOptionsForType);
43908        break;
43909      case CHART_TYPE.LINEAR:
43910        this.chartOptions.chart.type = "line";
43911        this.chartOptions.plotOptions = { line: {} };
43912        this.setOptions(this.chartOptions.plotOptions, "line", plotOptionsForType);
43913        break;
43914      case CHART_TYPE.SPLINE:
43915        this.chartOptions.chart.type = "spline";
43916        this.chartOptions.plotOptions = { spline: {} };
43917        this.setOptions(this.chartOptions.plotOptions, "spline", plotOptionsForType);
43918        break;
43919      case CHART_TYPE.PIE:
43920        this.chartOptions.chart.type = "pie";
43921        if (this.chartOptions.plotOptions === void 0) {
43922          console.error("plot options not defined");
43923          return;
43924        }
43925        this.setOptions(this.chartOptions.plotOptions, "pie", plotOptionsForType);
43926        break;
43927    }
43928    this.setOptions(this.chartOptions, "chart", chart);
43929    this.createSingleChart(seriesList);
43930  }
43931  getSVG(chartIdx) {
43932    if (this.chart.charts === void 0) {
43933      console.error("chart not defined");
43934      return "";
43935    }
43936    let filtered = this.chart.charts.filter((chart) => chart !== void 0);
43937    if (filtered === void 0) {
43938      return "";
43939    }
43940    return filtered[chartIdx].getSVG();
43941  }
43942  export(outputType) {
43943    this.chart.charts.forEach((chartToPrint) => {
43944      if (chartToPrint !== void 0) {
43945        const exportingOptions = this.chart.getOptions().exporting;
43946        exportingOptions.type = outputType;
43947        chartToPrint.exportChart(exportingOptions, this.chart.getOptions());
43948        console.log("Print finished");
43949      }
43950    });
43951  }
43952  createSingleChart(seriesList) {
43953    this.seriesList = seriesList;
43954    const chartOptions = this.chartOptions;
43955    this.setOption(chartOptions, "title", ChartOption.create("text", "s", this.title));
43956    const xAxisOption = {};
43957    xAxisOption.categories = [];
43958    if (seriesList.length > 0) {
43959      seriesList[0].TuplasDescription.forEach((tuplaDescription) => {
43960        if (xAxisOption.categories !== void 0) {
43961          xAxisOption.categories.push(tuplaDescription.Name);
43962        }
43963      });
43964    }
43965    chartOptions.xAxis = xAxisOption;
43966    let firstUnit = "";
43967    seriesList.forEach((dataSeries) => {
43968      if (firstUnit === "") {
43969        firstUnit = dataSeries.Units;
43970      }
43971      let secondSeries = false;
43972      let chartType = this.chartType;
43973      if (dataSeries.Units !== firstUnit) {
43974        chartType = CHART_TYPE.LINEAR;
43975        secondSeries = true;
43976      }
43977      const chartSeriesElement = this.getSeriesOptions(chartType);
43978      chartSeriesElement.name = dataSeries.Description;
43979      chartSeriesElement.yAxis = secondSeries === true ? 1 : 0;
43980      chartSeriesElement.tooltip = { valueSuffix: " " + dataSeries.Units };
43981      chartSeriesElement.data = [];
43982      dataSeries.DataRows.forEach((dataRow) => {
43983        const data = [];
43984        data.push(dataRow.DataTuplas[0].Value);
43985        data.push(dataRow.DataTuplas[1].Value);
43986        if (this.chartType === CHART_TYPE.PIE) {
43987          data["name"] = dataRow.DataTuplas[0].Value;
43988        }
43989        data["className"] = dataRow.DataTuplas[1].OutputFormat === void 0 ? this.outputFormat : dataRow.DataTuplas[1].OutputFormat;
43990        if ("data" in chartSeriesElement) {
43991          chartSeriesElement.data.push(data);
43992        }
43993      });
43994      chartOptions.series.push(chartSeriesElement);
43995    });
43996    this.setOptions(chartOptions, "xAxis", this.xAxis);
43997    this.setOptions(chartOptions, "yAxis", this.yAxis);
43998    chartOptions.yAxis[0].labels.formatter = this.yAxisFormatterLeft;
43999    if (chartOptions.yAxis.length > 1) {
44000      chartOptions.yAxis[1].labels.formatter = this.yAxisFormatterRight;
44001      chartOptions.yAxis[1].opposite = true;
44002    }
44003    this.setOptions(chartOptions, "legend", this.legend);
44004    if (this.legendClickEnabled === false) {
44005      if (chartOptions.legend) {
44006        if (!chartOptions.legend.events) {
44007          chartOptions.legend.events = {};
44008        }
44009        chartOptions.legend.events.itemClick = this.legendClickDisabled;
44010      }
44011    }
44012    this.setOptions(chartOptions, "tooltip", this.tooltip);
44013    if (chartOptions.tooltip === void 0) {
44014      chartOptions.tooltip = {};
44015    }
44016    if (this.customToolTip) {
44017      chartOptions.tooltip.useHTML = true;
44018      chartOptions.tooltip.formatter = this.toolTipFormatter;
44019    }
44020    this.chartOptions = chartOptions;
44021  }
44022  // tslint:disable-next-line:comment-format
44023  //<editor-fold desc="Formatters">
44024  yAxisFormatterLeft() {
44025    let result = "";
44026    const numberFormat = this.chart.userOptions.yAxis[0].labels.format;
44027    result += DoraNumber.formatNumber(this.value, null, numberFormat) + " ";
44028    result += this.axis.series[0].userOptions.tooltip.valueSuffix;
44029    return result;
44030  }
44031  yAxisFormatterRight() {
44032    let result = "";
44033    const numberFormat = this.chart.userOptions.yAxis[1].labels.format;
44034    result += DoraNumber.formatNumber(this.value, null, numberFormat) + " ";
44035    result += this.axis.series[0].userOptions.tooltip.valueSuffix;
44036    return result;
44037  }
44038  legendClickDisabled() {
44039    return false;
44040  }
44041  toolTipFormatter() {
44042    const serieName = this.series.getName();
44043    let result = '<div class="tooltip-container">';
44044    result += '<div class="column-name">' + this.point.name + "</div>";
44045    result += '<div class="name" style="color:' + this.color + ';">' + serieName + "</div>";
44046    result += '<div class="value-container">';
44047    if (this.series.tooltipOptions.valuePrefix !== void 0) {
44048      result += '<span class="valuePrefix">' + this.series.tooltipOptions.valuePrefix + "</span>";
44049    }
44050    let outputFormat = "###,###,###.##";
44051    for (let i = 0; i < this.series.options.data.length; i++) {
44052      if (this.series.options.data[i][0] === this.point.name) {
44053        outputFormat = this.series.options.data[i].className;
44054        break;
44055      }
44056    }
44057    result += '<span class="value">' + // @ts-ignore
44058    DoraNumber.formatNumber(this.y, null, outputFormat) + "</span>";
44059    if (this.series.tooltipOptions.valueSuffix !== void 0) {
44060      result += '<span class="valueSuffix">' + this.series.tooltipOptions.valueSuffix + "</span>";
44061    }
44062    result += "</div>";
44063    result += "</div>";
44064    return result;
44065  }
44066  // tslint:disable-next-line:comment-format
44067  //</editor-fold>
44068  getUnit(seriesName) {
44069    return "ciao";
44070  }
44071  /**
44072   * Get specific chartoptions depending on chartType
44073   * @param chartType type of chart
44074   */
44075  getSeriesOptions(chartType) {
44076    switch (chartType) {
44077      case CHART_TYPE.COLUMN:
44078      case CHART_TYPE.COLUMNSTACK:
44079        return { type: "column" };
44080      case CHART_TYPE.LINEAR:
44081        return { type: "line" };
44082      case CHART_TYPE.SPLINE:
44083        return { type: "spline" };
44084      case CHART_TYPE.BAR:
44085        return { type: "bar" };
44086      case CHART_TYPE.PIE:
44087        return { type: "pie" };
44088      default:
44089        return { type: "line" };
44090    }
44091  }
44092  // tslint:disable-next-line:ban-types
44093  testyAxis(dst) {
44094    dst["chart"]["marginRight"] = 200;
44095    dst["yAxis"] = [];
44096    dst["yAxis"][0] = {};
44097    dst["yAxis"][1] = {};
44098    dst["yAxis"][0]["gridLineColor"] = "#197F07";
44099    dst["yAxis"][1]["opposite"] = true;
44100    dst["yAxis"][1]["title"] = {};
44101    dst["yAxis"][1]["title"]["text"] = "secondo valore";
44102    dst["yAxis"][1]["labels"] = {};
44103    dst["yAxis"][1]["labels"]["enabled"] = true;
44104    dst["yAxis"][1]["labels"]["padding"] = 20;
44105    dst["yAxis"][1]["labels"]["margin"] = 20;
44106  }
44107  // tslint:disable-next-line:ban-types
44108  setOptions(dst, root, options2) {
44109    options2.forEach((option) => {
44110      option.setOption(dst, root);
44111    });
44112  }
44113};
44114
44115// src/app/messages/message-chart-print.ts
44116var MessageChartPrint = class _MessageChartPrint extends MessageBase {
44117  constructor(outputType) {
44118    super(_MessageChartPrint);
44119    this._outputType = outputType;
44120  }
44121  get outputType() {
44122    return this._outputType;
44123  }
44124};
44125
44126// src/app/DoraWidget/dora-chart/chart-stock-builder.ts
44127var Highstock = __toESM(require_highstock());
44128var ChartStockBuilder = class extends ChartBuilderBase {
44129  constructor(chartType, graphSkinConfiguration, seriesList, chart, legend, tooltip, scrollbar, navigator, rangeSelector, locale, xAxis, yAxis, yRangeMaxPercentage, yRangeMinPercentage, plotOptionsForType, seriesPlotOptions, title, customToolTip, customToolTipShowPercentageFromFirst, outputFormat, outputFormatFromData, legendClickEnabled = true) {
44130    super(locale, legendClickEnabled);
44131    this.chartType = CHART_TYPE.STOCKLINEAR;
44132    this.chart = Highstock;
44133    this.chartOptions = {};
44134    this.xAxis = [];
44135    this.yAxis = [];
44136    this.legend = [];
44137    this.tooltip = [];
44138    this.scrollbar = [];
44139    this.navigator = [];
44140    this.rangeSelector = [];
44141    this.seriesPlotOptions = [];
44142    this.seriesList = [];
44143    this.title = "";
44144    this.customToolTip = false;
44145    this.outputFormat = void 0;
44146    this.outputFormatFromData = false;
44147    this.customToolTipShowPercentageFromFirst = false;
44148    this.yRangeMaxPercentage = 100;
44149    this.yRangeMinPercentage = 0;
44150    if (seriesList.length === 0) {
44151      return;
44152    }
44153    this.chartType = chartType;
44154    this.chartOptions = JSON.parse(graphSkinConfiguration);
44155    this.xAxis = xAxis;
44156    this.yAxis = yAxis;
44157    this.yRangeMaxPercentage = yRangeMaxPercentage;
44158    this.yRangeMinPercentage = yRangeMinPercentage;
44159    this.legend = legend;
44160    this.tooltip = tooltip;
44161    this.scrollbar = scrollbar;
44162    this.navigator = navigator;
44163    this.rangeSelector = rangeSelector;
44164    this.title = title;
44165    this.customToolTip = customToolTip;
44166    this.customToolTipShowPercentageFromFirst = customToolTipShowPercentageFromFirst;
44167    this.outputFormat = outputFormat;
44168    this.outputFormatFromData = outputFormatFromData;
44169    this.seriesPlotOptions = seriesPlotOptions;
44170    if (this.chartOptions.chart === void 0) {
44171      console.error("chart options not defined");
44172      return;
44173    }
44174    switch (this.chartType) {
44175      case CHART_TYPE.STOCKLINEAR:
44176        this.chartOptions.chart.type = "line";
44177        this.chartOptions.plotOptions = { column: { stacking: "normal" } };
44178        this.setOptions(this.chartOptions, "plotOptions", plotOptionsForType);
44179        break;
44180      case CHART_TYPE.STOCKAREASPLINE:
44181        this.chartOptions.chart.type = "areaspline";
44182        this.chartOptions.plotOptions = { column: { stacking: "normal" } };
44183        this.setOptions(this.chartOptions, "plotOptions", plotOptionsForType);
44184        break;
44185      case CHART_TYPE.STOCKAREA:
44186        this.chartOptions.chart.type = "area";
44187        this.chartOptions.plotOptions = { column: { stacking: "normal" } };
44188        this.setOptions(this.chartOptions, "plotOptions", plotOptionsForType);
44189        break;
44190    }
44191    this.setOptions(this.chartOptions, "chart", chart);
44192    this.createSingleChart(seriesList);
44193  }
44194  getSVG(chartIdx) {
44195    if (this.chart.charts === void 0) {
44196      console.error("chart not defined");
44197      return "";
44198    }
44199    let filtered = this.chart.charts.filter((chart) => chart !== void 0);
44200    if (filtered === void 0) {
44201      return "";
44202    }
44203    return filtered[chartIdx].getSVG();
44204  }
44205  export(outputType) {
44206    this.chart.charts.forEach((chartToPrint) => {
44207      if (chartToPrint !== void 0) {
44208        const exportingOptions = this.chart.getOptions().exporting;
44209        exportingOptions.type = outputType;
44210        chartToPrint.exportChart(exportingOptions, this.chart.getOptions());
44211        console.log("Print finished");
44212      }
44213    });
44214  }
44215  setYAxisMinMax(seriesList, rangeMaxPercentage, rangeMinPercentage) {
44216    let min = void 0;
44217    let max = void 0;
44218    if (seriesList.length == 1) {
44219      if (seriesList[0].RangeMin !== null && seriesList[0].RangeMin !== void 0 && seriesList[0].RangeMax !== null && seriesList[0].RangeMax !== void 0) {
44220        min = seriesList[0].RangeMin;
44221        max = seriesList[0].RangeMax;
44222      } else {
44223        min = seriesList[0].getMinValue();
44224        max = seriesList[0].getMaxValue();
44225        if (rangeMaxPercentage !== null && rangeMinPercentage !== null) {
44226          min -= min * rangeMinPercentage / 100;
44227          max += max * rangeMaxPercentage / 100;
44228        }
44229      }
44230    } else {
44231      seriesList.forEach((series) => {
44232        if (series.DataRows.length === 0) {
44233          console.warn("Series vuota");
44234          return;
44235        }
44236        let minValue = series.getMinValue();
44237        let maxValue = series.getMaxValue();
44238        if (minValue === 0) {
44239          console.warn("Series contiene almeno un valore a 0");
44240        }
44241        if (!series.FixedSeries) {
44242          let firstValue = series.DataRows[0].DataTuplas[1].Value;
44243          if (firstValue === 0) {
44244            console.warn("Primo elemento della series a 0");
44245          }
44246          if (firstValue === 0) {
44247            maxValue = 200;
44248            minValue = 0;
44249          } else {
44250            minValue = 100 + (100 - minValue * 100 / firstValue) * -1;
44251            maxValue = 100 + (100 - maxValue * 100 / firstValue) * -1;
44252            if (rangeMaxPercentage !== null && rangeMinPercentage !== null) {
44253              minValue -= rangeMinPercentage;
44254              maxValue += rangeMaxPercentage;
44255            }
44256          }
44257        } else {
44258          minValue -= rangeMinPercentage;
44259          maxValue += rangeMaxPercentage;
44260        }
44261        if (min === void 0 || minValue < min) {
44262          min = minValue;
44263        }
44264        if (max === void 0 || maxValue > max) {
44265          max = maxValue;
44266        }
44267      });
44268    }
44269  }
44270  createSingleChart(seriesList) {
44271    this.seriesList = seriesList;
44272    const chartOptions = this.chartOptions;
44273    this.setLanguage(chartOptions);
44274    const compareChart = this.seriesList.length > 1;
44275    this.setYAxisMinMax(seriesList, this.yRangeMaxPercentage, this.yRangeMinPercentage);
44276    this.setOption(chartOptions, "plotOptions", ChartOption.create("series\\compare", "s", ""));
44277    this.setOption(chartOptions, "title", ChartOption.create("text", "s", this.title));
44278    const xAxisOption = {};
44279    xAxisOption.categories = [];
44280    seriesList[0].TuplasDescription.forEach((tuplaDescription) => {
44281      if (xAxisOption.categories !== void 0) {
44282        xAxisOption.categories.push(tuplaDescription.Name);
44283      }
44284    });
44285    chartOptions.xAxis = xAxisOption;
44286    let firstUnit = "";
44287    let firstSeries = true;
44288    seriesList.forEach((dataSeries, index) => {
44289      if (firstUnit === "") {
44290        firstUnit = dataSeries.Units;
44291      }
44292      let secondSeries = false;
44293      let chartType = this.chartType;
44294      if (index > 0) {
44295        if (this.chartType == CHART_TYPE.STOCKAREASPLINE) {
44296          chartType = CHART_TYPE.SPLINE;
44297        } else {
44298          chartType = CHART_TYPE.LINEAR;
44299        }
44300      }
44301      const chartSeriesElement = this.getSeriesOptions(chartType);
44302      if (chartType === CHART_TYPE.STOCKAREA || chartType === CHART_TYPE.STOCKAREASPLINE) {
44303        this.setOptions(chartSeriesElement, null, this.seriesPlotOptions);
44304      }
44305      chartSeriesElement.name = dataSeries.Description;
44306      chartSeriesElement.yAxis = secondSeries === true ? 1 : 0;
44307      chartSeriesElement.tooltip = { valueSuffix: " " + dataSeries.Units };
44308      chartSeriesElement.data = [];
44309      chartSeriesElement["customFixedSeries"] = dataSeries.FixedSeries;
44310      chartSeriesElement["customCompareChart"] = compareChart;
44311      chartSeriesElement["customToolTipShowPercentageFromFirst"] = this.customToolTipShowPercentageFromFirst;
44312      chartSeriesElement["customFirstValue"] = dataSeries.FirstValue;
44313      if (dataSeries.Color !== void 0 && dataSeries.Color !== null) {
44314        chartSeriesElement.color = dataSeries.Color;
44315      }
44316      if (dataSeries.DataRows.length > 0 && dataSeries.FirstValue !== null) {
44317        const firstValue = dataSeries.FirstValue;
44318        dataSeries.DataRows.forEach((dataRow) => {
44319          const data = [];
44320          let date = dataRow.DataTuplas[0].Value;
44321          data.push(date.getTime());
44322          if (compareChart) {
44323            const percentage = dataSeries.FixedSeries ? dataRow.DataTuplas[1].Value : 100 + (100 - dataRow.DataTuplas[1].Value * 100 / firstValue) * -1;
44324            data.push(percentage);
44325          } else {
44326            data.push(dataRow.DataTuplas[1].Value);
44327          }
44328          data["className"] = GenericUtil.stringIsEmpty(dataRow.DataTuplas[1].OutputFormat) ? this.outputFormat : dataRow.DataTuplas[1].OutputFormat;
44329          chartSeriesElement.data.push(data);
44330          data["customOriginalValue"] = dataRow.DataTuplas[1].Value;
44331        });
44332        chartOptions.series.push(chartSeriesElement);
44333      }
44334    });
44335    this.setOptions(chartOptions, "xAxis", this.xAxis);
44336    this.setOptions(chartOptions, "yAxis", this.yAxis);
44337    this.chartOptions.yAxis[0].labels.formatter = this.yAxisFormatter;
44338    this.setOptions(chartOptions, "legend", this.legend);
44339    this.setOptions(chartOptions, "tooltip", this.tooltip);
44340    if (chartOptions.tooltip === void 0) {
44341      chartOptions.tooltip = {};
44342    }
44343    if (this.customToolTip) {
44344      this.chartOptions.tooltip.useHTML = true;
44345      this.chartOptions.tooltip.formatter = this.toolTipFormatter;
44346    }
44347    this.setOptions(chartOptions, "scrollbar", this.scrollbar);
44348    this.setOptions(chartOptions, "navigator", this.navigator);
44349    this.setOptions(chartOptions, "rangeSelector", this.rangeSelector);
44350  }
44351  //<editor-fold desc="Formatters">
44352  yAxisFormatter() {
44353    let result = "";
44354    if (this.axis.series.length > 1) {
44355      const numberFormat = this.chart.userOptions.yAxis[0].labels.formatCompare;
44356      result += DoraNumber.formatNumber(this.value, null, numberFormat) + " ";
44357      result += "%";
44358    } else {
44359      const numberFormat = this.chart.userOptions.yAxis[0].labels.format;
44360      result += DoraNumber.formatNumber(this.value, null, numberFormat) + " ";
44361      result += this.axis.series[0].userOptions.tooltip.valueSuffix;
44362    }
44363    return result;
44364  }
44365  toolTipFormatter() {
44366    let result = '<div class="tooltip-container">';
44367    const firstPoint = this.points[0];
44368    const date = new Date(this.x);
44369    result += '<div class="date">' + formatDate(date, "shortDate", DoraGetLocale());
44370    if (firstPoint.series.currentDataGrouping !== void 0 && firstPoint.series.currentDataGrouping.unitName !== "day") {
44371      const endDate = new Date(this.x + firstPoint.series.currentDataGrouping.totalRange - 864e5);
44372      result += " - " + formatDate(endDate, "shortDate", DoraGetLocale());
44373    }
44374    result += "</div>";
44375    this.points.forEach((point) => {
44376      const flCompare = point.point.series.options.customCompareChart;
44377      const flFixedSeries = point.point.series.options.customFixedSeries;
44378      const firstValue = point.point.series.options.customFirstValue;
44379      let outputFormat = point.series.options.data[point.point.index].className;
44380      let firstPoint2 = point.series.options.data[0].customOriginalValue;
44381      result += '<div class="name" style="color:' + point.color + ';">' + point.series.getName() + "</div>";
44382      result += '<div class="value-container">';
44383      if (point.series.tooltipOptions.valuePrefix !== void 0) {
44384        result += '<span class="valuePrefix">' + point.series.tooltipOptions.valuePrefix + "</span>";
44385      }
44386      if (!flCompare) {
44387        result += '<span class="value">' + // @ts-ignore
44388        DoraNumber.formatNumber(point.y, null, outputFormat) + "</span>";
44389        if (point.series.tooltipOptions.valueSuffix !== void 0) {
44390          result += '<span class="valueSuffix">' + point.series.tooltipOptions.valueSuffix + "</span>";
44391        }
44392        if (point.point.series.options.customToolTipShowPercentageFromFirst === true) {
44393          let percentageFromFirstPoint = (point.y - firstValue) * 100 / firstValue;
44394          result += '<span class="compare-value ' + (percentageFromFirstPoint >= 0 ? "pos" : "neg") + '">' + // @ts-ignore
44395          DoraNumber.formatNumber(percentageFromFirstPoint, null, outputFormat) + "</span>";
44396          result += '<span class="compare-value-suffix ' + (percentageFromFirstPoint >= 0 ? "pos" : "neg") + '">%</span>';
44397        }
44398      } else {
44399        if (!flFixedSeries) {
44400          result += '<span class="value">' + // @ts-ignore
44401          DoraNumber.formatNumber(point.series.options.data[point.point.index].customOriginalValue, null, outputFormat) + "</span>";
44402          if (point.series.tooltipOptions.valueSuffix !== void 0) {
44403            result += '<span class="valueSuffix">' + point.series.tooltipOptions.valueSuffix + "</span>";
44404          }
44405        }
44406        const percentage = point.y;
44407        const percentageClass = percentage >= 100 ? "pos" : "neg";
44408        result += '<span class="compare-value ' + percentageClass + '">' + // @ts-ignore
44409        DoraNumber.formatNumber(percentage - 100, null, outputFormat) + "</span>";
44410        result += '<span class="compare-value-suffix ' + percentageClass + '">%</span>';
44411      }
44412      result += "</div>";
44413    });
44414    result += "</div>";
44415    return result;
44416  }
44417  //</editor-fold>
44418  getUnit(seriesName) {
44419    return "ciao";
44420  }
44421  /**
44422   * Get specific chartoptions depending on chartType
44423   * @param chartType type of chart
44424   */
44425  getSeriesOptions(chartType) {
44426    switch (chartType) {
44427      case CHART_TYPE.COLUMN:
44428      case CHART_TYPE.COLUMNSTACK:
44429        return { type: "column" };
44430      case CHART_TYPE.LINEAR:
44431        return { type: "line" };
44432      case CHART_TYPE.SPLINE:
44433        return { type: "spline" };
44434      case CHART_TYPE.BAR:
44435        return { type: "bar" };
44436      case CHART_TYPE.PIE:
44437        return { type: "pie" };
44438      case CHART_TYPE.STOCKLINEAR:
44439        return { type: "line" };
44440      case CHART_TYPE.STOCKAREA:
44441        return { type: "area" };
44442      case CHART_TYPE.STOCKAREASPLINE:
44443        return { type: "areaspline" };
44444      default:
44445        return { type: "line" };
44446    }
44447  }
44448  // tslint:disable-next-line:ban-types
44449  testyAxis(dst) {
44450    dst["chart"]["marginRight"] = 200;
44451    dst["yAxis"] = [];
44452    dst["yAxis"][0] = {};
44453    dst["yAxis"][1] = {};
44454    dst["yAxis"][0]["gridLineColor"] = "#197F07";
44455    dst["yAxis"][1]["opposite"] = true;
44456    dst["yAxis"][1]["title"] = {};
44457    dst["yAxis"][1]["title"]["text"] = "secondo valore";
44458    dst["yAxis"][1]["labels"] = {};
44459    dst["yAxis"][1]["labels"]["enabled"] = true;
44460    dst["yAxis"][1]["labels"]["padding"] = 20;
44461    dst["yAxis"][1]["labels"]["margin"] = 20;
44462  }
44463  // tslint:disable-next-line:ban-types
44464  setOptions(dst, root, options2) {
44465    options2.forEach((option) => {
44466      option.setOption(dst, root);
44467    });
44468  }
44469};
44470
44471// src/app/messages/message-series-type-selected.ts
44472var MessageSeriesTypeSelected = class _MessageSeriesTypeSelected extends MessageBase {
44473  constructor(seriesSelectorType) {
44474    super(_MessageSeriesTypeSelected);
44475    this._seriesSelectorType = seriesSelectorType;
44476  }
44477  get seriesSelectorType() {
44478    return this._seriesSelectorType;
44479  }
44480};
44481
vendor: 3,667 bytes, lines 44482-44622
44482// node_modules/highcharts-angular/fesm2022/highcharts-angular.mjs
44483var HighchartsChartComponent = class _HighchartsChartComponent {
44484  constructor(el, _zone) {
44485    this.el = el;
44486    this._zone = _zone;
44487    this.updateChange = new EventEmitter(true);
44488    this.chartInstance = new EventEmitter();
44489  }
44490  ngOnChanges(changes) {
44491    const update2 = changes.update?.currentValue;
44492    if (changes.options || update2) {
44493      this.wrappedUpdateOrCreateChart();
44494      if (update2) {
44495        this.updateChange.emit(false);
44496      }
44497    }
44498  }
44499  wrappedUpdateOrCreateChart() {
44500    if (this.runOutsideAngular) {
44501      this._zone.runOutsideAngular(() => {
44502        this.updateOrCreateChart();
44503      });
44504    } else {
44505      this.updateOrCreateChart();
44506    }
44507  }
44508  updateOrCreateChart() {
44509    if (this.chart?.update) {
44510      this.chart.update(this.options, true, this.oneToOne || false);
44511    } else {
44512      this.chart = this.Highcharts[this.constructorType || "chart"](this.el.nativeElement, this.options, this.callbackFunction || null);
44513      this.chartInstance.emit(this.chart);
44514    }
44515  }
44516  ngOnDestroy() {
44517    if (this.chart) {
44518      this.chart.destroy();
44519      this.chart = null;
44520      this.chartInstance.emit(this.chart);
44521    }
44522  }
44523  static {
44524    this.\u0275fac = function HighchartsChartComponent_Factory(__ngFactoryType__) {
44525      return new (__ngFactoryType__ || _HighchartsChartComponent)(\u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(NgZone));
44526    };
44527  }
44528  static {
44529    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({
44530      type: _HighchartsChartComponent,
44531      selectors: [["highcharts-chart"]],
44532      inputs: {
44533        Highcharts: "Highcharts",
44534        constructorType: "constructorType",
44535        callbackFunction: "callbackFunction",
44536        oneToOne: "oneToOne",
44537        runOutsideAngular: "runOutsideAngular",
44538        options: "options",
44539        update: "update"
44540      },
44541      outputs: {
44542        updateChange: "updateChange",
44543        chartInstance: "chartInstance"
44544      },
44545      standalone: false,
44546      features: [\u0275\u0275NgOnChangesFeature],
44547      decls: 0,
44548      vars: 0,
44549      template: function HighchartsChartComponent_Template(rf, ctx) {
44550      },
44551      encapsulation: 2
44552    });
44553  }
44554};
44555(() => {
44556  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(HighchartsChartComponent, [{
44557    type: Component,
44558    args: [{
44559      selector: "highcharts-chart",
44560      template: ""
44561    }]
44562  }], function() {
44563    return [{
44564      type: ElementRef
44565    }, {
44566      type: NgZone
44567    }];
44568  }, {
44569    Highcharts: [{
44570      type: Input
44571    }],
44572    constructorType: [{
44573      type: Input
44574    }],
44575    callbackFunction: [{
44576      type: Input
44577    }],
44578    oneToOne: [{
44579      type: Input
44580    }],
44581    runOutsideAngular: [{
44582      type: Input
44583    }],
44584    options: [{
44585      type: Input
44586    }],
44587    update: [{
44588      type: Input
44589    }],
44590    updateChange: [{
44591      type: Output
44592    }],
44593    chartInstance: [{
44594      type: Output
44595    }]
44596  });
44597})();
44598var HighchartsChartModule = class _HighchartsChartModule {
44599  static {
44600    this.\u0275fac = function HighchartsChartModule_Factory(__ngFactoryType__) {
44601      return new (__ngFactoryType__ || _HighchartsChartModule)();
44602    };
44603  }
44604  static {
44605    this.\u0275mod = /* @__PURE__ */ \u0275\u0275defineNgModule({
44606      type: _HighchartsChartModule
44607    });
44608  }
44609  static {
44610    this.\u0275inj = /* @__PURE__ */ \u0275\u0275defineInjector({});
44611  }
44612};
44613(() => {
44614  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(HighchartsChartModule, [{
44615    type: NgModule,
44616    args: [{
44617      declarations: [HighchartsChartComponent],
44618      exports: [HighchartsChartComponent]
44619    }]
44620  }], null, null);
44621})();
44622
44623// src/app/DoraWidget/dora-chart/dora-chart.component.ts
44624function DoraChartComponent_div_0_Template(rf, ctx) {
44625  if (rf & 1) {
44626    const _r1 = \u0275\u0275getCurrentView();
44627    \u0275\u0275elementStart(0, "div", 3);
44628    \u0275\u0275listener("click", function DoraChartComponent_div_0_Template_div_click_0_listener() {
44629      \u0275\u0275restoreView(_r1);
44630      const ctx_r1 = \u0275\u0275nextContext();
44631      return \u0275\u0275resetView(ctx_r1.onEnableSetting());
44632    });
44633    \u0275\u0275elementEnd();
44634  }
44635}
44636function DoraChartComponent_div_1_highcharts_chart_2_Template(rf, ctx) {
44637  if (rf & 1) {
44638    const _r4 = \u0275\u0275getCurrentView();
44639    \u0275\u0275elementStart(0, "highcharts-chart", 8);
44640    \u0275\u0275twoWayListener("updateChange", function DoraChartComponent_div_1_highcharts_chart_2_Template_highcharts_chart_updateChange_0_listener($event) {
44641      \u0275\u0275restoreView(_r4);
44642      const ctx_r1 = \u0275\u0275nextContext(2);
44643      \u0275\u0275twoWayBindingSet(ctx_r1.updateFromInput, $event) || (ctx_r1.updateFromInput = $event);
44644      return \u0275\u0275resetView($event);
44645    });
44646    \u0275\u0275elementEnd();
44647  }
44648  if (rf & 2) {
44649    const chartBuilder_r5 = ctx.$implicit;
44650    const ctx_r1 = \u0275\u0275nextContext(2);
44651    \u0275\u0275property("Highcharts", chartBuilder_r5.chart)("options", chartBuilder_r5.chartOptions)("oneToOne", true);
44652    \u0275\u0275twoWayProperty("update", ctx_r1.updateFromInput);
44653  }
44654}
44655function DoraChartComponent_div_1_div_3_col_5_Template(rf, ctx) {
44656  if (rf & 1) {
44657    \u0275\u0275element(0, "col");
44658  }
44659}
44660function DoraChartComponent_div_1_div_3_th_12_Template(rf, ctx) {
44661  if (rf & 1) {
44662    \u0275\u0275elementStart(0, "th", 15);
44663    \u0275\u0275text(1);
44664    \u0275\u0275elementEnd();
44665  }
44666  if (rf & 2) {
44667    const colDesc_r6 = ctx.$implicit;
44668    \u0275\u0275advance();
44669    \u0275\u0275textInterpolate1(" ", colDesc_r6.Name, " ");
44670  }
44671}
44672function DoraChartComponent_div_1_div_3_tr_14_td_5_Template(rf, ctx) {
44673  if (rf & 1) {
44674    \u0275\u0275elementStart(0, "td", 18);
44675    \u0275\u0275text(1);
44676    \u0275\u0275elementEnd();
44677  }
44678  if (rf & 2) {
44679    const dataRow_r7 = ctx.$implicit;
44680    const chartBuilder_r8 = \u0275\u0275nextContext(2).$implicit;
44681    \u0275\u0275advance();
44682    \u0275\u0275textInterpolate1(" ", dataRow_r7.DataTuplas[1].getFormattedValue("-", chartBuilder_r8.outputFormat || "#.#"), " ");
44683  }
44684}
44685function DoraChartComponent_div_1_div_3_tr_14_Template(rf, ctx) {
44686  if (rf & 1) {
44687    \u0275\u0275elementStart(0, "tr", 16)(1, "td");
44688    \u0275\u0275text(2);
44689    \u0275\u0275elementEnd();
44690    \u0275\u0275elementStart(3, "td");
44691    \u0275\u0275text(4);
44692    \u0275\u0275elementEnd();
44693    \u0275\u0275template(5, DoraChartComponent_div_1_div_3_tr_14_td_5_Template, 2, 1, "td", 17);
44694    \u0275\u0275elementEnd();
44695  }
44696  if (rf & 2) {
44697    const dataSerie_r9 = ctx.$implicit;
44698    const i_r10 = ctx.index;
44699    \u0275\u0275property("ngClass", i_r10 % 2 === 0 ? "cellTableEvenRow" : "cellTableOddRow");
44700    \u0275\u0275advance(2);
44701    \u0275\u0275textInterpolate(dataSerie_r9.Description);
44702    \u0275\u0275advance(2);
44703    \u0275\u0275textInterpolate(dataSerie_r9.Units);
44704    \u0275\u0275advance();
44705    \u0275\u0275property("ngForOf", dataSerie_r9.DataRows);
44706  }
44707}
44708function DoraChartComponent_div_1_div_3_Template(rf, ctx) {
44709  if (rf & 1) {
44710    \u0275\u0275elementStart(0, "div", 9)(1, "table", 10)(2, "caption");
44711    \u0275\u0275text(3);
44712    \u0275\u0275elementEnd();
44713    \u0275\u0275elementStart(4, "colgroup");
44714    \u0275\u0275template(5, DoraChartComponent_div_1_div_3_col_5_Template, 1, 0, "col", 11);
44715    \u0275\u0275elementEnd();
44716    \u0275\u0275elementStart(6, "thead", 12)(7, "tr")(8, "th");
44717    \u0275\u0275text(9);
44718    \u0275\u0275elementEnd();
44719    \u0275\u0275elementStart(10, "th");
44720    \u0275\u0275text(11);
44721    \u0275\u0275elementEnd();
44722    \u0275\u0275template(12, DoraChartComponent_div_1_div_3_th_12_Template, 2, 1, "th", 13);
44723    \u0275\u0275elementEnd()();
44724    \u0275\u0275elementStart(13, "tbody");
44725    \u0275\u0275template(14, DoraChartComponent_div_1_div_3_tr_14_Template, 6, 4, "tr", 14);
44726    \u0275\u0275elementEnd()()();
44727  }
44728  if (rf & 2) {
44729    const chartBuilder_r8 = ctx.$implicit;
44730    const ctx_r1 = \u0275\u0275nextContext(2);
44731    \u0275\u0275advance(3);
44732    \u0275\u0275textInterpolate(chartBuilder_r8.title);
44733    \u0275\u0275advance(2);
44734    \u0275\u0275property("ngForOf", chartBuilder_r8.seriesList[0] == null ? null : chartBuilder_r8.seriesList[0].TuplasDescription);
44735    \u0275\u0275advance(4);
44736    \u0275\u0275textInterpolate(ctx_r1.translationService.get("Description"));
44737    \u0275\u0275advance(2);
44738    \u0275\u0275textInterpolate(ctx_r1.translationService.get("Unit"));
44739    \u0275\u0275advance();
44740    \u0275\u0275property("ngForOf", chartBuilder_r8.seriesList[0] == null ? null : chartBuilder_r8.seriesList[0].TuplasDescription);
44741    \u0275\u0275advance(2);
44742    \u0275\u0275property("ngForOf", chartBuilder_r8.seriesList);
44743  }
44744}
44745function DoraChartComponent_div_1_Template(rf, ctx) {
44746  if (rf & 1) {
44747    const _r3 = \u0275\u0275getCurrentView();
44748    \u0275\u0275elementStart(0, "div", 4)(1, "div", 5);
44749    \u0275\u0275listener("click", function DoraChartComponent_div_1_Template_div_click_1_listener() {
44750      \u0275\u0275restoreView(_r3);
44751      const ctx_r1 = \u0275\u0275nextContext();
44752      return \u0275\u0275resetView(ctx_r1.onPopupClose());
44753    });
44754    \u0275\u0275elementEnd();
44755    \u0275\u0275template(2, DoraChartComponent_div_1_highcharts_chart_2_Template, 1, 4, "highcharts-chart", 6)(3, DoraChartComponent_div_1_div_3_Template, 15, 6, "div", 7);
44756    \u0275\u0275elementEnd();
44757  }
44758  if (rf & 2) {
44759    const ctx_r1 = \u0275\u0275nextContext();
44760    \u0275\u0275styleProp("visibility", ctx_r1.getPopupVisibility())("top", ctx_r1.getPositionTop())("left", ctx_r1.getPositionLeft());
44761    \u0275\u0275advance(2);
44762    \u0275\u0275property("ngForOf", ctx_r1.chartBuilders);
44763    \u0275\u0275advance();
44764    \u0275\u0275property("ngForOf", ctx_r1.chartBuilders);
44765  }
44766}
44767function DoraChartComponent_div_2_highcharts_chart_1_Template(rf, ctx) {
44768  if (rf & 1) {
44769    const _r11 = \u0275\u0275getCurrentView();
44770    \u0275\u0275elementStart(0, "highcharts-chart", 8);
44771    \u0275\u0275twoWayListener("updateChange", function DoraChartComponent_div_2_highcharts_chart_1_Template_highcharts_chart_updateChange_0_listener($event) {
44772      \u0275\u0275restoreView(_r11);
44773      const ctx_r1 = \u0275\u0275nextContext(2);
44774      \u0275\u0275twoWayBindingSet(ctx_r1.updateFromInput, $event) || (ctx_r1.updateFromInput = $event);
44775      return \u0275\u0275resetView($event);
44776    });
44777    \u0275\u0275elementEnd();
44778  }
44779  if (rf & 2) {
44780    const chartBuilder_r12 = ctx.$implicit;
44781    const ctx_r1 = \u0275\u0275nextContext(2);
44782    \u0275\u0275property("Highcharts", chartBuilder_r12.chart)("options", chartBuilder_r12.chartOptions)("oneToOne", true);
44783    \u0275\u0275twoWayProperty("update", ctx_r1.updateFromInput);
44784    \u0275\u0275attribute("aria-hidden", true);
44785  }
44786}
44787function DoraChartComponent_div_2_div_2_col_5_Template(rf, ctx) {
44788  if (rf & 1) {
44789    \u0275\u0275element(0, "col");
44790  }
44791}
44792function DoraChartComponent_div_2_div_2_th_12_Template(rf, ctx) {
44793  if (rf & 1) {
44794    \u0275\u0275elementStart(0, "th", 15);
44795    \u0275\u0275text(1);
44796    \u0275\u0275elementEnd();
44797  }
44798  if (rf & 2) {
44799    const colDesc_r13 = ctx.$implicit;
44800    \u0275\u0275advance();
44801    \u0275\u0275textInterpolate1(" ", colDesc_r13.Name, " ");
44802  }
44803}
44804function DoraChartComponent_div_2_div_2_tr_14_td_5_Template(rf, ctx) {
44805  if (rf & 1) {
44806    \u0275\u0275elementStart(0, "td", 18);
44807    \u0275\u0275text(1);
44808    \u0275\u0275elementEnd();
44809  }
44810  if (rf & 2) {
44811    const dataRow_r14 = ctx.$implicit;
44812    const chartBuilder_r15 = \u0275\u0275nextContext(2).$implicit;
44813    \u0275\u0275advance();
44814    \u0275\u0275textInterpolate1(" ", dataRow_r14.DataTuplas[1].getFormattedValue("-", chartBuilder_r15.outputFormat || "#.#"), " ");
44815  }
44816}
44817function DoraChartComponent_div_2_div_2_tr_14_Template(rf, ctx) {
44818  if (rf & 1) {
44819    \u0275\u0275elementStart(0, "tr", 16)(1, "td");
44820    \u0275\u0275text(2);
44821    \u0275\u0275elementEnd();
44822    \u0275\u0275elementStart(3, "td");
44823    \u0275\u0275text(4);
44824    \u0275\u0275elementEnd();
44825    \u0275\u0275template(5, DoraChartComponent_div_2_div_2_tr_14_td_5_Template, 2, 1, "td", 17);
44826    \u0275\u0275elementEnd();
44827  }
44828  if (rf & 2) {
44829    const dataSerie_r16 = ctx.$implicit;
44830    const i_r17 = ctx.index;
44831    \u0275\u0275property("ngClass", i_r17 % 2 === 0 ? "cellTableEvenRow" : "cellTableOddRow");
44832    \u0275\u0275advance(2);
44833    \u0275\u0275textInterpolate(dataSerie_r16.Description);
44834    \u0275\u0275advance(2);
44835    \u0275\u0275textInterpolate(dataSerie_r16.Units);
44836    \u0275\u0275advance();
44837    \u0275\u0275property("ngForOf", dataSerie_r16.DataRows);
44838  }
44839}
44840function DoraChartComponent_div_2_div_2_Template(rf, ctx) {
44841  if (rf & 1) {
44842    \u0275\u0275elementStart(0, "div", 9)(1, "table", 10)(2, "caption");
44843    \u0275\u0275text(3);
44844    \u0275\u0275elementEnd();
44845    \u0275\u0275elementStart(4, "colgroup");
44846    \u0275\u0275template(5, DoraChartComponent_div_2_div_2_col_5_Template, 1, 0, "col", 11);
44847    \u0275\u0275elementEnd();
44848    \u0275\u0275elementStart(6, "thead", 12)(7, "tr")(8, "th");
44849    \u0275\u0275text(9);
44850    \u0275\u0275elementEnd();
44851    \u0275\u0275elementStart(10, "th");
44852    \u0275\u0275text(11);
44853    \u0275\u0275elementEnd();
44854    \u0275\u0275template(12, DoraChartComponent_div_2_div_2_th_12_Template, 2, 1, "th", 13);
44855    \u0275\u0275elementEnd()();
44856    \u0275\u0275elementStart(13, "tbody");
44857    \u0275\u0275template(14, DoraChartComponent_div_2_div_2_tr_14_Template, 6, 4, "tr", 14);
44858    \u0275\u0275elementEnd()()();
44859  }
44860  if (rf & 2) {
44861    const chartBuilder_r15 = ctx.$implicit;
44862    const ctx_r1 = \u0275\u0275nextContext(2);
44863    \u0275\u0275advance(3);
44864    \u0275\u0275textInterpolate(chartBuilder_r15.title);
44865    \u0275\u0275advance(2);
44866    \u0275\u0275property("ngForOf", chartBuilder_r15.seriesList[0] == null ? null : chartBuilder_r15.seriesList[0].TuplasDescription);
44867    \u0275\u0275advance(4);
44868    \u0275\u0275textInterpolate(ctx_r1.translationService.get("Description"));
44869    \u0275\u0275advance(2);
44870    \u0275\u0275textInterpolate(ctx_r1.translationService.get("Unit"));
44871    \u0275\u0275advance();
44872    \u0275\u0275property("ngForOf", chartBuilder_r15.seriesList[0] == null ? null : chartBuilder_r15.seriesList[0].TuplasDescription);
44873    \u0275\u0275advance(2);
44874    \u0275\u0275property("ngForOf", chartBuilder_r15.seriesList);
44875  }
44876}
44877function DoraChartComponent_div_2_highcharts_chart_3_Template(rf, ctx) {
44878  if (rf & 1) {
44879    const _r18 = \u0275\u0275getCurrentView();
44880    \u0275\u0275elementStart(0, "highcharts-chart", 21);
44881    \u0275\u0275twoWayListener("updateChange", function DoraChartComponent_div_2_highcharts_chart_3_Template_highcharts_chart_updateChange_0_listener($event) {
44882      \u0275\u0275restoreView(_r18);
44883      const ctx_r1 = \u0275\u0275nextContext(2);
44884      \u0275\u0275twoWayBindingSet(ctx_r1.updateFromInput, $event) || (ctx_r1.updateFromInput = $event);
44885      return \u0275\u0275resetView($event);
44886    });
44887    \u0275\u0275elementEnd();
44888  }
44889  if (rf & 2) {
44890    const chartStockBuilder_r19 = ctx.$implicit;
44891    const ctx_r1 = \u0275\u0275nextContext(2);
44892    \u0275\u0275property("Highcharts", chartStockBuilder_r19.chart)("constructorType", "stockChart")("options", chartStockBuilder_r19.chartOptions)("oneToOne", true);
44893    \u0275\u0275twoWayProperty("update", ctx_r1.updateFromInput);
44894  }
44895}
44896function DoraChartComponent_div_2_div_4_col_5_Template(rf, ctx) {
44897  if (rf & 1) {
44898    \u0275\u0275element(0, "col");
44899  }
44900}
44901function DoraChartComponent_div_2_div_4_th_8_Template(rf, ctx) {
44902  if (rf & 1) {
44903    \u0275\u0275elementStart(0, "th", 23);
44904    \u0275\u0275text(1);
44905    \u0275\u0275elementEnd();
44906  }
44907  if (rf & 2) {
44908    const colDesc_r20 = ctx.$implicit;
44909    \u0275\u0275advance();
44910    \u0275\u0275textInterpolate1(" ", colDesc_r20.Name, " ");
44911  }
44912}
44913function DoraChartComponent_div_2_div_4_tr_10_td_1_Template(rf, ctx) {
44914  if (rf & 1) {
44915    \u0275\u0275elementStart(0, "td", 18)(1, "div", 24);
44916    \u0275\u0275text(2);
44917    \u0275\u0275elementEnd()();
44918  }
44919  if (rf & 2) {
44920    const tupla_r21 = ctx.$implicit;
44921    const chartStockBuilder_r22 = \u0275\u0275nextContext(2).$implicit;
44922    \u0275\u0275advance(2);
44923    \u0275\u0275textInterpolate1(" ", tupla_r21.getFormattedValue("-", chartStockBuilder_r22.outputFormat || "#.#"), " ");
44924  }
44925}
44926function DoraChartComponent_div_2_div_4_tr_10_Template(rf, ctx) {
44927  if (rf & 1) {
44928    \u0275\u0275elementStart(0, "tr", 16);
44929    \u0275\u0275template(1, DoraChartComponent_div_2_div_4_tr_10_td_1_Template, 3, 1, "td", 17);
44930    \u0275\u0275elementEnd();
44931  }
44932  if (rf & 2) {
44933    const row_r23 = ctx.$implicit;
44934    const i_r24 = ctx.index;
44935    \u0275\u0275property("ngClass", i_r24 % 2 === 0 ? "cellTableEvenRow" : "cellTableOddRow");
44936    \u0275\u0275advance();
44937    \u0275\u0275property("ngForOf", row_r23.DataTuplas);
44938  }
44939}
44940function DoraChartComponent_div_2_div_4_Template(rf, ctx) {
44941  if (rf & 1) {
44942    \u0275\u0275elementStart(0, "div", 9)(1, "table", 10)(2, "caption");
44943    \u0275\u0275text(3);
44944    \u0275\u0275elementEnd();
44945    \u0275\u0275elementStart(4, "colgroup");
44946    \u0275\u0275template(5, DoraChartComponent_div_2_div_4_col_5_Template, 1, 0, "col", 11);
44947    \u0275\u0275elementEnd();
44948    \u0275\u0275elementStart(6, "thead", 12)(7, "tr");
44949    \u0275\u0275template(8, DoraChartComponent_div_2_div_4_th_8_Template, 2, 1, "th", 22);
44950    \u0275\u0275elementEnd()();
44951    \u0275\u0275elementStart(9, "tbody");
44952    \u0275\u0275template(10, DoraChartComponent_div_2_div_4_tr_10_Template, 2, 2, "tr", 14);
44953    \u0275\u0275elementEnd()()();
44954  }
44955  if (rf & 2) {
44956    const chartStockBuilder_r22 = ctx.$implicit;
44957    \u0275\u0275advance(3);
44958    \u0275\u0275textInterpolate(chartStockBuilder_r22.title);
44959    \u0275\u0275advance(2);
44960    \u0275\u0275property("ngForOf", chartStockBuilder_r22.seriesList[0] == null ? null : chartStockBuilder_r22.seriesList[0].TuplasDescription);
44961    \u0275\u0275advance(3);
44962    \u0275\u0275property("ngForOf", chartStockBuilder_r22.seriesList[0] == null ? null : chartStockBuilder_r22.seriesList[0].TuplasDescription);
44963    \u0275\u0275advance(2);
44964    \u0275\u0275property("ngForOf", chartStockBuilder_r22.seriesList[0] == null ? null : chartStockBuilder_r22.seriesList[0].DataRows);
44965  }
44966}
44967function DoraChartComponent_div_2_Template(rf, ctx) {
44968  if (rf & 1) {
44969    \u0275\u0275elementStart(0, "div", 19);
44970    \u0275\u0275template(1, DoraChartComponent_div_2_highcharts_chart_1_Template, 1, 5, "highcharts-chart", 6)(2, DoraChartComponent_div_2_div_2_Template, 15, 6, "div", 7)(3, DoraChartComponent_div_2_highcharts_chart_3_Template, 1, 5, "highcharts-chart", 20)(4, DoraChartComponent_div_2_div_4_Template, 11, 4, "div", 7);
44971    \u0275\u0275elementEnd();
44972  }
44973  if (rf & 2) {
44974    const ctx_r1 = \u0275\u0275nextContext();
44975    \u0275\u0275advance();
44976    \u0275\u0275property("ngForOf", ctx_r1.chartBuilders);
44977    \u0275\u0275advance();
44978    \u0275\u0275property("ngForOf", ctx_r1.chartBuilders);
44979    \u0275\u0275advance();
44980    \u0275\u0275property("ngForOf", ctx_r1.chartStockBuilders);
44981    \u0275\u0275advance();
44982    \u0275\u0275property("ngForOf", ctx_r1.chartStockBuilders);
44983  }
44984}
44985(0, import_exporting2.default)(Highcharts3);
44986var DoraChartComponent = class _DoraChartComponent extends WidgetBaseComponent {
44987  constructor() {
44988    super(...arguments);
44989    this.defaultType = "LINEAR";
44990    this.title = "";
44991    this.useSeriesTitle = false;
44992    this.widthBreak = 0;
44993    this.showTitle = true;
44994    this.customToolTip = true;
44995    this.customToolTipShowPercentageFromFirst = false;
44996    this.outputFormat = "#.#";
44997    this.outputFormatFromData = true;
44998    this.chart = [];
44999    this.Wp_chart = [];
45000    this.legend = [];
45001    this.Wp_legend = [];
45002    this.tooltip = [];
45003    this.piePlotOptions = [];
45004    this.Wp_piePlotOptions = [];
45005    this.columnPlotOptions = [];
45006    this.columnStackPlotOptions = [];
45007    this.linearPlotOptions = [];
45008    this.splinePlotOptions = [];
45009    this.barPlotOptions = [];
45010    this.stockPlotOptions = [];
45011    this.navigator = [];
45012    this.scrollbar = [];
45013    this.rangeSelector = [];
45014    this.xAxis = [];
45015    this.yAxis = [];
45016    this.yRangeMaxPercentage = 0;
45017    this.yRangeMinPercentage = 0;
45018    this.seriesPlotOptions = [];
45019    this.hideEmptyChart = false;
45020    this.graphSkinConfiguration = void 0;
45021    this.chartType = CHART_TYPE.LINEAR;
45022    this.seriesSelectorType = void 0;
45023    this.chartBuilders = [];
45024    this.chartStockBuilders = [];
45025    this.updateFromInput = false;
45026    this.showOnPopup = false;
45027    this.popupVisible = false;
45028    this.callerPosition = null;
45029    this.legendClickEnabled = true;
45030    this.chartOptions = {
45031      chart: {
45032        type: "column",
45033        marginRight: 200
45034      },
45035      credits: {
45036        enabled: false
45037      },
45038      title: {
45039        text: "primo chart"
45040      },
45041      series: [
45042        {
45043          data: [1, 2, 3],
45044          type: "column",
45045          name: "test"
45046        },
45047        {
45048          data: [2, 3, 4],
45049          type: "column",
45050          name: "test2"
45051        }
45052      ]
45053    };
45054    this.seriesList = [];
45055  }
45056  onParameterInjectedFinished() {
45057    super.onParameterInjectedFinished();
45058    this.setChartTypeFromString(this.defaultType);
45059    this.http.get(extGetAppConfigurationPath() + "/GraphSkin.json").subscribe((data) => {
45060      this.graphSkinConfiguration = data;
45061      this.readData();
45062    });
45063    this.setEvents();
45064  }
45065  onRefresh() {
45066    super.onRefresh();
45067    this.setChartTypeFromString(this.defaultType);
45068    this.readData();
45069  }
45070  /**
45071   * Set all events listening
45072   */
45073  setEvents() {
45074    this.messageService.getMessage(this.EventChannel, MessageSeriesSelected, this.CallerName).subscribe((message) => {
45075      this.seriesList = message.data.DatasSeries;
45076      if (this.showOnPopup) {
45077        if (this.seriesList.length === 0) {
45078          this.popupVisible = false;
45079          return;
45080        }
45081        this.callerPosition = message.data.CallerPosition;
45082        this.popupVisible = true;
45083      }
45084      this.readData();
45085    });
45086    this.messageService.getMessage(this.EventChannel, MessageChartType, this.CallerName).subscribe((message) => {
45087      this.chartType = message.data.chartType;
45088      this.readData();
45089    });
45090    this.messageService.getMessage(this.EventChannel, MessageSeriesTypeSelected, this.CallerName).subscribe((message) => {
45091      this.seriesSelectorType = message.data.seriesSelectorType;
45092      this.readData();
45093    });
45094    this.messageService.getMessage(this.EventChannel, MessageChartPrint, this.CallerName).subscribe((message) => {
45095      this.onPrint(message.data.outputType);
45096    });
45097  }
45098  setChartTypeFromString(src) {
45099    if (src === null || src === void 0 || src === "") {
45100      this.chartType = CHART_TYPE.LINEAR;
45101      return;
45102    }
45103    this.chartType = CHART_TYPE[src.toUpperCase()];
45104    if (this.chartType === void 0) {
45105      console.error("CHARTTYPE " + src + " not allowed");
45106      return;
45107    }
45108  }
45109  readData() {
45110    if (this.chartType === null || this.chartType === void 0 || this.seriesList === null || this.seriesList === void 0 || //  this.seriesList.length === 0 ||
45111    this.graphSkinConfiguration === void 0) {
45112      return;
45113    }
45114    this.chartOptions = this.graphSkinConfiguration;
45115    this.chartOptions.series = [];
45116    const seriesLists = [];
45117    if (this.chartOptions.plotOptions === void 0) {
45118      this.chartOptions.plotOptions = {};
45119    }
45120    let plotOptionsForType = [];
45121    let flUseWp = false;
45122    if (this.widthBreak !== 0 && window.innerWidth < this.widthBreak) {
45123      flUseWp = true;
45124    }
45125    switch (this.chartType) {
45126      case CHART_TYPE.STOCKLINEAR:
45127      case CHART_TYPE.STOCKAREA:
45128      case CHART_TYPE.STOCKAREASPLINE:
45129        seriesLists.push(this.seriesList);
45130        break;
45131      case CHART_TYPE.COLUMNSTACK:
45132        plotOptionsForType = this.columnStackPlotOptions;
45133        seriesLists.push(this.seriesList);
45134        break;
45135      case CHART_TYPE.COLUMN:
45136        plotOptionsForType = this.columnPlotOptions;
45137        seriesLists.push(this.seriesList);
45138        break;
45139      case CHART_TYPE.BAR:
45140        plotOptionsForType = this.barPlotOptions;
45141        seriesLists.push(this.seriesList);
45142        break;
45143      case CHART_TYPE.LINEAR:
45144        plotOptionsForType = this.linearPlotOptions;
45145        seriesLists.push(this.seriesList);
45146        break;
45147      case CHART_TYPE.SPLINE:
45148        plotOptionsForType = this.splinePlotOptions;
45149        seriesLists.push(this.seriesList);
45150        break;
45151      case CHART_TYPE.PIE:
45152        plotOptionsForType = flUseWp ? this.Wp_piePlotOptions : this.piePlotOptions;
45153        this.useSeriesTitle = true;
45154        this.seriesList.forEach((series) => {
45155          const seriesList = [];
45156          seriesList.push(series);
45157          seriesLists.push(seriesList);
45158        });
45159        break;
45160    }
45161    this.chartBuilders = [];
45162    this.chartStockBuilders = [];
45163    if (this.chartType === CHART_TYPE.STOCKLINEAR || this.chartType === CHART_TYPE.STOCKAREA || this.chartType === CHART_TYPE.STOCKAREASPLINE) {
45164      plotOptionsForType = this.stockPlotOptions;
45165      seriesLists.forEach((seriesList) => {
45166        if (seriesList.length > 0 || !this.hideEmptyChart) {
45167          let myTitle;
45168          if (this.showTitle === false) {
45169            myTitle = "";
45170          } else if (this.useSeriesTitle) {
45171            myTitle = seriesList[0].Description;
45172          } else {
45173            myTitle = this.title;
45174          }
45175          this.chartStockBuilders.push(new ChartStockBuilder(this.chartType, JSON.stringify(this.graphSkinConfiguration), this.filterDataBySeriesSelectorType(seriesList), flUseWp ? this.Wp_chart : this.chart, flUseWp ? this.Wp_legend : this.legend, this.tooltip, this.scrollbar, this.navigator, this.rangeSelector, this.locale, this.xAxis, this.yAxis, this.yRangeMaxPercentage, this.yRangeMinPercentage, plotOptionsForType, this.seriesPlotOptions, myTitle, this.customToolTip, this.customToolTipShowPercentageFromFirst, this.outputFormat, this.outputFormatFromData, this.legendClickEnabled));
45176        }
45177      });
45178      this.updateFromInput = true;
45179    } else {
45180      seriesLists.forEach((seriesList) => {
45181        if (seriesList.length > 0 || !this.hideEmptyChart) {
45182          let myTitle;
45183          if (this.showTitle === false) {
45184            myTitle = "";
45185          } else if (this.useSeriesTitle) {
45186            myTitle = seriesList[0].Description;
45187          } else {
45188            myTitle = this.title;
45189          }
45190          this.chartBuilders.push(new ChartBuilder(this.chartType, JSON.stringify(this.graphSkinConfiguration), seriesList, flUseWp ? this.Wp_chart : this.chart, flUseWp ? this.Wp_legend : this.legend, this.tooltip, this.locale, this.xAxis, this.yAxis, plotOptionsForType, myTitle, this.customToolTip, this.outputFormat, this.outputFormatFromData, this.legendClickEnabled));
45191        }
45192      });
45193      this.updateFromInput = true;
45194    }
45195  }
45196  filterDataBySeriesSelectorType(seriesList) {
45197    if (this.seriesSelectorType === null || this.seriesSelectorType === void 0 || this.seriesSelectorType.dateRange === null || this.seriesSelectorType.dateRange === void 0) {
45198      return seriesList;
45199    }
45200    const result = [];
45201    seriesList.forEach((series) => {
45202      if (series.FixedSeries) {
45203        return;
45204      }
45205      if (this.seriesSelectorType === void 0 || this.seriesSelectorType.dateRange === void 0) {
45206        return;
45207      }
45208      const seriesFiltered = series.filterByDateRange(this.seriesSelectorType.dateRange);
45209      if (this.seriesSelectorType.dateRange === null || this.seriesSelectorType.dateRange === void 0) {
45210        if (series.FirstValue !== null && series.FirstValue !== void 0) {
45211          seriesFiltered.FirstValue = series.FirstValue;
45212        }
45213      }
45214      result.push(seriesFiltered);
45215    });
45216    return result;
45217  }
45218  toolTipFormatter() {
45219    return "ciao";
45220  }
45221  onPrint(outputType) {
45222    console.log("print");
45223    const svgArr = [];
45224    let top = 0;
45225    let chartWidth = 0;
45226    let chartIdx = 0;
45227    this.chartBuilders.reverse().forEach((chartBuilder) => {
45228      let svg = chartBuilder.getSVG(chartIdx);
45229      chartIdx++;
45230      const svgWidth = +svg.match(/^<svg[^>]*width\s*=\s*\"?(\d+)\"?[^>]*>/)[1];
45231      const svgHeight = +svg.match(/^<svg[^>]*height\s*=\s*\"?(\d+)\"?[^>]*>/)[1];
45232      svg = svg.replace("<svg", '<g transform="translate(0,' + top + ')" ');
45233      svg = svg.replace("</svg>", "</g>");
45234      top += svgHeight;
45235      chartWidth = Math.max(chartWidth, svgWidth);
45236      svgArr.push(svg);
45237    });
45238    const completeSVG = '<svg height="' + top + '" width="' + chartWidth + '" version="1.1" xmlns="http://www.w3.org/2000/svg">' + svgArr.join("") + "</svg>";
45239    const options2 = Highcharts3.getOptions().exporting;
45240    if (options2 === void 0 || options2.url === void 0) {
45241      return;
45242    }
45243    const myHeaders = new HttpHeaders();
45244    myHeaders.set("Content-Type", outputType);
45245    myHeaders.set("Accept", "text/plain, */*");
45246    myHeaders.set("Cache-Control", "no-cache");
45247    this.http.post(options2.url, {
45248      filename: options2.filename || "chart",
45249      type: outputType,
45250      width: chartWidth,
45251      svg: completeSVG
45252    }, { headers: myHeaders, responseType: "blob" }).subscribe((value) => {
45253      this.downLoadFile(value, outputType);
45254      console.log("chiamata effettuata");
45255    }, (err) => {
45256      console.log("errore");
45257      this.downLoadFile(err.error.text, outputType);
45258    });
45259  }
45260  downLoadFile(data, type) {
45261    const blob = new Blob([data], { type });
45262    const url = window.URL.createObjectURL(blob);
45263    console.log("Open url " + url.toString());
45264    const pwa = window.open(url);
45265    if (!pwa || pwa.closed || typeof pwa.closed == "undefined") {
45266      alert("Please disable your Pop-up blocker and try again.");
45267    }
45268  }
45269  getPopupVisibility() {
45270    return this.popupVisible ? "visible" : "hidden";
45271  }
45272  onPopupClose() {
45273    this.popupVisible = false;
45274    const idRows = [];
45275    this.seriesList.forEach((series) => {
45276      if (series.IdRowsOrigin !== null) {
45277        idRows.push(...series.IdRowsOrigin);
45278      }
45279    });
45280    this.messageService.sendMessage(this.EventChannel, new MessageRowsUnselected(idRows), this.CallerName);
45281  }
45282  getPositionTop() {
45283    if (this.callerPosition === null) {
45284      return "100px";
45285    } else {
45286      return this.callerPosition.Top + "px";
45287    }
45288  }
45289  getPositionLeft() {
45290    if (this.callerPosition === null) {
45291      return "100px";
45292    } else {
45293      return this.callerPosition.Left + 100 + "px";
45294    }
45295  }
45296  static {
45297    this.\u0275fac = /* @__PURE__ */ (() => {
45298      let \u0275DoraChartComponent_BaseFactory;
45299      return function DoraChartComponent_Factory(__ngFactoryType__) {
45300        return (\u0275DoraChartComponent_BaseFactory || (\u0275DoraChartComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraChartComponent)))(__ngFactoryType__ || _DoraChartComponent);
45301      };
45302    })();
45303  }
45304  static {
45305    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraChartComponent, selectors: [["dora-chart"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 3, vars: 3, consts: [["class", "setting-command", 3, "click", 4, "ngIf"], ["class", "highcharts-chart-container-popup", 3, "visibility", "top", "left", 4, "ngIf"], ["class", "highcharts-chart-container-normal", 4, "ngIf"], [1, "setting-command", 3, "click"], [1, "highcharts-chart-container-popup"], [1, "popup-close", 3, "click"], ["class", "DAG-Chart", 3, "Highcharts", "options", "oneToOne", "update", "updateChange", 4, "ngFor", "ngForOf"], ["class", "accessible-chart", "aria-hidden", "false", 4, "ngFor", "ngForOf"], [1, "DAG-Chart", 3, "updateChange", "Highcharts", "options", "oneToOne", "update"], ["aria-hidden", "false", 1, "accessible-chart"], ["cellspacing", "0", 1, "cellTableWidget"], [4, "ngFor", "ngForOf"], ["aria-hidden", "false"], ["scope", "col", "colspan", "1", "class", "cellTableHeader", 4, "ngFor", "ngForOf"], [3, "ngClass", 4, "ngFor", "ngForOf"], ["scope", "col", "colspan", "1", 1, "cellTableHeader"], [3, "ngClass"], ["class", "cellTableCell", 4, "ngFor", "ngForOf"], [1, "cellTableCell"], [1, "highcharts-chart-container-normal"], ["class", "DAG-Chart", 3, "Highcharts", "constructorType", "options", "oneToOne", "update", "updateChange", 4, "ngFor", "ngForOf"], [1, "DAG-Chart", 3, "updateChange", "Highcharts", "constructorType", "options", "oneToOne", "update"], ["colspan", "1", "class", "cellTableHeader", 4, "ngFor", "ngForOf"], ["colspan", "1", 1, "cellTableHeader"], [2, "outline-style", "none"]], template: function DoraChartComponent_Template(rf, ctx) {
45306      if (rf & 1) {
45307        \u0275\u0275template(0, DoraChartComponent_div_0_Template, 1, 0, "div", 0)(1, DoraChartComponent_div_1_Template, 4, 8, "div", 1)(2, DoraChartComponent_div_2_Template, 5, 4, "div", 2);
45308      }
45309      if (rf & 2) {
45310        \u0275\u0275property("ngIf", ctx.settingEnabled);
45311        \u0275\u0275advance();
45312        \u0275\u0275property("ngIf", ctx.showOnPopup);
45313        \u0275\u0275advance();
45314        \u0275\u0275property("ngIf", !ctx.showOnPopup);
45315      }
45316    }, dependencies: [NgClass, NgForOf, NgIf, HighchartsChartComponent], styles: ["\n\n.highcharts-chart-container-popup[_ngcontent-%COMP%] {\n  width: 600px;\n  height: 300px;\n  position: absolute;\n  z-index: 1000;\n}\n.highcharts-chart-container-popup[_ngcontent-%COMP%]   .popup-close[_ngcontent-%COMP%] {\n  display: block;\n  overflow: hidden;\n  width: 10px;\n  height: 10px;\n  float: right;\n  background-color: blue;\n}\n.DAG-Chart[_ngcontent-%COMP%] {\n  width: 100%;\n  display: block;\n}\n.highcharts-chart-container-normal[_ngcontent-%COMP%]   .accessible-chart[_ngcontent-%COMP%] {\n  position: absolute;\n  clip: rect(1px, 1px, 1px, 1px);\n  word-wrap: normal;\n  width: 1px;\n  height: 1px;\n  overflow: hidden;\n}"] });
45317  }
45318};
45319__decorate([
45320  DoraPropertyDOC("Chart type", ATTRIBUTE_TYPE.STRING, "LINEAR\xA7SPLINE\xA7CANDLESTICK\xA7OHLC\xA7AREA\xA7COLUMN\xA7PIE\xA7PIE_COLUMNGROUP\xA7COLUMNSTACK\xA7BAR\xA7STOCKLINEAR\xA7STOCKAREA\xA7STOCKAREASPLINE", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45321  DoraProperty,
45322  __metadata("design:type", String)
45323], DoraChartComponent.prototype, "defaultType", void 0);
45324__decorate([
45325  DoraPropertyDOC("Title of the chart", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45326  DoraProperty,
45327  __metadata("design:type", String)
45328], DoraChartComponent.prototype, "title", void 0);
45329__decorate([
45330  DoraPropertyDOC("Use Series Title", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45331  DoraProperty,
45332  __metadata("design:type", Boolean)
45333], DoraChartComponent.prototype, "useSeriesTitle", void 0);
45334__decorate([
45335  DoraPropertyDOC("Graphical width break. Below use Wp* parameters", ATTRIBUTE_TYPE.INTEGER, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45336  DoraProperty,
45337  __metadata("design:type", Number)
45338], DoraChartComponent.prototype, "widthBreak", void 0);
45339__decorate([
45340  DoraPropertyDOC("Show title", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45341  DoraProperty,
45342  __metadata("design:type", Boolean)
45343], DoraChartComponent.prototype, "showTitle", void 0);
45344__decorate([
45345  DoraPropertyDOC("Use custom tooltip", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45346  DoraProperty,
45347  __metadata("design:type", Boolean)
45348], DoraChartComponent.prototype, "customToolTip", void 0);
45349__decorate([
45350  DoraPropertyDOC("customToolTipShowPercentageFromFirst", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45351  DoraProperty,
45352  __metadata("design:type", Boolean)
45353], DoraChartComponent.prototype, "customToolTipShowPercentageFromFirst", void 0);
45354__decorate([
45355  DoraPropertyDOC("Format for numbers", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45356  DoraProperty,
45357  __metadata("design:type", String)
45358], DoraChartComponent.prototype, "outputFormat", void 0);
45359__decorate([
45360  DoraPropertyDOC("Use format number from received series", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45361  DoraProperty,
45362  __metadata("design:type", Boolean)
45363], DoraChartComponent.prototype, "outputFormatFromData", void 0);
45364__decorate([
45365  DoraPropertyDOC("Highcharts.chart parameter", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "chart"),
45366  DoraPropertyArray(ChartOption),
45367  __metadata("design:type", Array)
45368], DoraChartComponent.prototype, "chart", void 0);
45369__decorate([
45370  DoraPropertyDOC("Highcharts.chart parameter (dimensione < WidthBreak)", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "chart"),
45371  DoraPropertyArray(ChartOption),
45372  __metadata("design:type", Array)
45373], DoraChartComponent.prototype, "Wp_chart", void 0);
45374__decorate([
45375  DoraPropertyDOC("Highcharts.legend parameter", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "legend"),
45376  DoraPropertyArray(ChartOption),
45377  __metadata("design:type", Array)
45378], DoraChartComponent.prototype, "legend", void 0);
45379__decorate([
45380  DoraPropertyDOC("Highcharts.legend parameter (dimensione < WidthBreak)", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "legend"),
45381  DoraPropertyArray(ChartOption),
45382  __metadata("design:type", Array)
45383], DoraChartComponent.prototype, "Wp_legend", void 0);
45384__decorate([
45385  DoraPropertyDOC("Highcharts.tooltip parameter", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "tooltip"),
45386  DoraPropertyArray(ChartOption),
45387  __metadata("design:type", Array)
45388], DoraChartComponent.prototype, "tooltip", void 0);
45389__decorate([
45390  DoraPropertyDOC("Highcharts.plotOptions.pie parameter", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "plotOptions.pie"),
45391  DoraPropertyArray(ChartOption),
45392  __metadata("design:type", Array)
45393], DoraChartComponent.prototype, "piePlotOptions", void 0);
45394__decorate([
45395  DoraPropertyDOC("Highcharts.plotOptions.pie parameter (dimensione < WidthBreak)", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "plotOptions.pie"),
45396  DoraPropertyArray(ChartOption),
45397  __metadata("design:type", Array)
45398], DoraChartComponent.prototype, "Wp_piePlotOptions", void 0);
45399__decorate([
45400  DoraPropertyDOC("Highcharts.plotOptions.column parameter (solo con CHartType = COLUMN)", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "plotOptions.column"),
45401  DoraPropertyArray(ChartOption),
45402  __metadata("design:type", Array)
45403], DoraChartComponent.prototype, "columnPlotOptions", void 0);
45404__decorate([
45405  DoraPropertyDOC("Highcharts.plotOptions.column parameter (solo con ChartType = COLUMNSTACK)", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "plotOptions.column"),
45406  DoraPropertyArray(ChartOption),
45407  __metadata("design:type", Array)
45408], DoraChartComponent.prototype, "columnStackPlotOptions", void 0);
45409__decorate([
45410  DoraPropertyDOC("Highcharts.plotOptions.line parameter", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "plotOptions.line"),
45411  DoraPropertyArray(ChartOption),
45412  __metadata("design:type", Array)
45413], DoraChartComponent.prototype, "linearPlotOptions", void 0);
45414__decorate([
45415  DoraPropertyDOC("Highcharts.plotOptions.spline parameter", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "plotOptions.spline"),
45416  DoraPropertyArray(ChartOption),
45417  __metadata("design:type", Array)
45418], DoraChartComponent.prototype, "splinePlotOptions", void 0);
45419__decorate([
45420  DoraPropertyDOC("Highcharts.plotOptions.bar parameter", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "plotOptions.bar"),
45421  DoraPropertyArray(ChartOption),
45422  __metadata("design:type", Array)
45423], DoraChartComponent.prototype, "barPlotOptions", void 0);
45424__decorate([
45425  DoraPropertyDOC("Highcharts.plotOptions parameter (solo un chart type 'stock')", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "plotOptions"),
45426  DoraPropertyArray(ChartOption),
45427  __metadata("design:type", Array)
45428], DoraChartComponent.prototype, "stockPlotOptions", void 0);
45429__decorate([
45430  DoraPropertyDOC("Highcharts.stockChart.navigation parameter", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "navigator"),
45431  DoraPropertyArray(ChartOption),
45432  __metadata("design:type", Array)
45433], DoraChartComponent.prototype, "navigator", void 0);
45434__decorate([
45435  DoraPropertyDOC("Highcharts.stockChart.scrollbar parameter", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "scrollbar"),
45436  DoraPropertyArray(ChartOption),
45437  __metadata("design:type", Array)
45438], DoraChartComponent.prototype, "scrollbar", void 0);
45439__decorate([
45440  DoraPropertyDOC("Highcharts.stockChart.rangeSelector parameter", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "rangeSelector"),
45441  DoraPropertyArray(ChartOption),
45442  __metadata("design:type", Array)
45443], DoraChartComponent.prototype, "rangeSelector", void 0);
45444__decorate([
45445  DoraPropertyDOC("Highcharts.xAxis parameter", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "xAxis"),
45446  DoraPropertyArray(ChartOption),
45447  __metadata("design:type", Array)
45448], DoraChartComponent.prototype, "xAxis", void 0);
45449__decorate([
45450  DoraPropertyDOC("Highcharts.yAxis parameter", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "yAxis"),
45451  DoraPropertyArray(ChartOption),
45452  __metadata("design:type", Array)
45453], DoraChartComponent.prototype, "yAxis", void 0);
45454__decorate([
45455  DoraPropertyDOC("yrange Max in percentage", ATTRIBUTE_TYPE.INTEGER, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45456  DoraProperty,
45457  __metadata("design:type", Number)
45458], DoraChartComponent.prototype, "yRangeMaxPercentage", void 0);
45459__decorate([
45460  DoraPropertyDOC("yrange Min in percentage", ATTRIBUTE_TYPE.INTEGER, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45461  DoraProperty,
45462  __metadata("design:type", Number)
45463], DoraChartComponent.prototype, "yRangeMinPercentage", void 0);
45464__decorate([
45465  DoraPropertyDOC("Highcharts.chart.series parameter", ATTRIBUTE_TYPE.HIGHCHARTOPTIONS, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true, "series"),
45466  DoraPropertyArray(ChartOption),
45467  __metadata("design:type", Array)
45468], DoraChartComponent.prototype, "seriesPlotOptions", void 0);
45469__decorate([
45470  DoraPropertyDOC("Non mostra il grafico senza dati", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45471  DoraProperty,
45472  __metadata("design:type", Boolean)
45473], DoraChartComponent.prototype, "hideEmptyChart", void 0);
45474__decorate([
45475  DoraProperty,
45476  DoraPropertyDOC("True = show charts on popoup: it receives PositionElement from series", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45477  __metadata("design:type", Object)
45478], DoraChartComponent.prototype, "showOnPopup", void 0);
45479__decorate([
45480  DoraProperty,
45481  DoraPropertyDOC("True = enable click on legend", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
45482  __metadata("design:type", Boolean)
45483], DoraChartComponent.prototype, "legendClickEnabled", void 0);
45484(() => {
45485  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraChartComponent, { className: "DoraChartComponent", filePath: "src/app/dorawidget/dora-chart/dora-chart.component.ts", lineNumber: 35 });
45486})();
45487
45488// src/app/Utility/date-range.ts
45489var DateRange = class {
45490  constructor(from2, to) {
45491    if (from2 > to) {
45492      throw new Error("from is greater than to");
45493    }
45494    this._from = from2;
45495    this._to = to;
45496  }
45497  get from() {
45498    return this._from;
45499  }
45500  get to() {
45501    return this._to;
45502  }
45503  isDateInRange(date) {
45504    if (this._from === null || this._to === null) {
45505      return true;
45506    }
45507    return date >= this._from && date <= this._to;
45508  }
45509};
45510
45511// src/app/DoraWidget/dora-series-selector/data/series-selector-type.ts
45512var SERIES_SELECTOR_TYPE;
45513(function(SERIES_SELECTOR_TYPE2) {
45514  SERIES_SELECTOR_TYPE2[SERIES_SELECTOR_TYPE2["INTRADAY"] = 0] = "INTRADAY";
45515  SERIES_SELECTOR_TYPE2[SERIES_SELECTOR_TYPE2["HISTORICAL"] = 1] = "HISTORICAL";
45516  SERIES_SELECTOR_TYPE2[SERIES_SELECTOR_TYPE2["CORRECTION"] = 2] = "CORRECTION";
45517  SERIES_SELECTOR_TYPE2[SERIES_SELECTOR_TYPE2["DIVIDEND"] = 3] = "DIVIDEND";
45518})(SERIES_SELECTOR_TYPE || (SERIES_SELECTOR_TYPE = {}));
45519var SeriesSelectorType = class {
45520  constructor(type = "") {
45521    this.type = "";
45522    this._dateRange = void 0;
45523    this._description = "";
45524    this._selected = false;
45525    this.type = type;
45526  }
45527  set selected(value) {
45528    this._selected = value;
45529  }
45530  get selected() {
45531    return this._selected;
45532  }
45533  get description() {
45534    if (this._description === "") {
45535      return this.type;
45536    } else {
45537      return this._description;
45538    }
45539  }
45540  setType(value) {
45541    this.type = value;
45542  }
45543  get Type() {
45544    return SERIES_SELECTOR_TYPE[this.type];
45545  }
45546  get dateRange() {
45547    return this._dateRange;
45548  }
45549  set dateRange(value) {
45550    this._dateRange = value;
45551  }
45552  setDay(day) {
45553    const to = /* @__PURE__ */ new Date();
45554    const from2 = /* @__PURE__ */ new Date();
45555    from2.setDate(from2.getDate() - day);
45556    this._dateRange = new DateRange(from2, to);
45557    this._description = "EXT_" + day + "D";
45558  }
45559  setMonth(month) {
45560    const to = /* @__PURE__ */ new Date();
45561    const from2 = /* @__PURE__ */ new Date();
45562    from2.setMonth(from2.getMonth() - month);
45563    this._dateRange = new DateRange(from2, to);
45564    this._description = "EXT_" + month + "M";
45565  }
45566  setYear(year) {
45567    const to = /* @__PURE__ */ new Date();
45568    const from2 = /* @__PURE__ */ new Date();
45569    from2.setFullYear(from2.getFullYear() - year);
45570    this._dateRange = new DateRange(from2, to);
45571    this._description = "EXT_" + year + "Y";
45572  }
45573  setStartOfYear() {
45574    const to = /* @__PURE__ */ new Date();
45575    const from2 = /* @__PURE__ */ new Date();
45576    from2.setDate(1);
45577    from2.setMonth(0);
45578    this._dateRange = new DateRange(from2, to);
45579    this._description = "EXT_BEG_Y";
45580  }
45581};
45582__decorate([
45583  DoraProperty,
45584  __metadata("design:type", String)
45585], SeriesSelectorType.prototype, "type", void 0);
45586
45587// src/app/DoraWidget/dora-series-selector/dora-series-selector.component.ts
45588function DoraSeriesSelectorComponent_div_1_Template(rf, ctx) {
45589  if (rf & 1) {
45590    const _r1 = \u0275\u0275getCurrentView();
45591    \u0275\u0275elementStart(0, "div", 2);
45592    \u0275\u0275listener("click", function DoraSeriesSelectorComponent_div_1_Template_div_click_0_listener() {
45593      const seriesSelectorType_r2 = \u0275\u0275restoreView(_r1).$implicit;
45594      const ctx_r2 = \u0275\u0275nextContext();
45595      return \u0275\u0275resetView(ctx_r2.onSeriesSelectorTypeClick(seriesSelectorType_r2));
45596    });
45597    \u0275\u0275elementEnd();
45598  }
45599  if (rf & 2) {
45600    const seriesSelectorType_r2 = ctx.$implicit;
45601    const ctx_r2 = \u0275\u0275nextContext();
45602    \u0275\u0275classMap(ctx_r2.getSeriesTypeClass(seriesSelectorType_r2));
45603    \u0275\u0275property("innerHTML", ctx_r2.getSeriesDescription(seriesSelectorType_r2), \u0275\u0275sanitizeHtml);
45604  }
45605}
45606var DoraSeriesSelectorComponent = class _DoraSeriesSelectorComponent extends WidgetBaseComponent {
45607  constructor() {
45608    super(...arguments);
45609    this.extendedHistorical = true;
45610    this.extended7D = false;
45611    this.extended1M = true;
45612    this.extended2M = false;
45613    this.extended3M = true;
45614    this.extended6M = true;
45615    this.extended9M = false;
45616    this.extended1Y = true;
45617    this.extended2Y = false;
45618    this.extended3Y = true;
45619    this.extended5Y = true;
45620    this.extendedBeginY = false;
45621    this.seriesSelectorTypes = [];
45622    this.defaultSeriesSelectorType = "HISTORICAL";
45623    this.lastDate = void 0;
45624  }
45625  onParameterInjectedFinished() {
45626    super.onParameterInjectedFinished();
45627    this.enableButtons();
45628    this.messageService.getMessage(this.EventChannel, MessageLastDate, this.CallerName).subscribe((message) => {
45629      this.lastDate = message.data.LastDate;
45630      this.enableButtons();
45631    });
45632  }
45633  enableButtons() {
45634    this.seriesSelectorTypes = [];
45635    this.seriesSelectorTypes.push(new SeriesSelectorType("HISTORICAL"));
45636    const now2 = /* @__PURE__ */ new Date();
45637    if (this.extendedHistorical === true) {
45638      if (this.extended7D) {
45639        if (this.lastDate === void 0 || this.lastDate.getTime() > now2.getTime() - 7 * 24 * 60 * 60 * 1e3) {
45640          const seriesSelectorType = new SeriesSelectorType("HISTORICAL");
45641          seriesSelectorType.setDay(7);
45642          this.seriesSelectorTypes.push(seriesSelectorType);
45643        }
45644      }
45645      if (this.extended1M) {
45646        if (this.lastDate === void 0 || this.lastDate.getTime() > now2.getTime() - 30 * 24 * 60 * 60 * 1e3) {
45647          const seriesSelectorType = new SeriesSelectorType("HISTORICAL");
45648          seriesSelectorType.setMonth(1);
45649          this.seriesSelectorTypes.push(seriesSelectorType);
45650        }
45651      }
45652      if (this.extended2M) {
45653        if (this.lastDate === void 0 || this.lastDate.getTime() > now2.getTime() - 60 * 24 * 60 * 60 * 1e3) {
45654          const seriesSelectorType = new SeriesSelectorType("HISTORICAL");
45655          seriesSelectorType.setMonth(2);
45656          this.seriesSelectorTypes.push(seriesSelectorType);
45657        }
45658      }
45659      if (this.extended3M) {
45660        if (this.lastDate === void 0 || this.lastDate.getTime() > now2.getTime() - 90 * 24 * 60 * 60 * 1e3) {
45661          const seriesSelectorType = new SeriesSelectorType("HISTORICAL");
45662          seriesSelectorType.setMonth(3);
45663          this.seriesSelectorTypes.push(seriesSelectorType);
45664        }
45665      }
45666      if (this.extended6M) {
45667        if (this.lastDate === void 0 || this.lastDate.getTime() > now2.getTime() - 180 * 24 * 60 * 60 * 1e3) {
45668          const seriesSelectorType = new SeriesSelectorType("HISTORICAL");
45669          seriesSelectorType.setMonth(6);
45670          this.seriesSelectorTypes.push(seriesSelectorType);
45671        }
45672      }
45673      if (this.extended9M) {
45674        if (this.lastDate === void 0 || this.lastDate.getTime() > now2.getTime() - 270 * 24 * 60 * 60 * 1e3) {
45675          const seriesSelectorType = new SeriesSelectorType("HISTORICAL");
45676          seriesSelectorType.setMonth(9);
45677          this.seriesSelectorTypes.push(seriesSelectorType);
45678        }
45679      }
45680      if (this.extended1Y) {
45681        if (this.lastDate === void 0 || this.lastDate.getTime() > now2.getTime() - 365 * 24 * 60 * 60 * 1e3) {
45682          const seriesSelectorType = new SeriesSelectorType("HISTORICAL");
45683          seriesSelectorType.setYear(1);
45684          this.seriesSelectorTypes.push(seriesSelectorType);
45685        }
45686      }
45687      if (this.extended2Y) {
45688        if (this.lastDate === void 0 || this.lastDate.getTime() > now2.getTime() - 2 * 365 * 24 * 60 * 60 * 1e3) {
45689          const seriesSelectorType = new SeriesSelectorType("HISTORICAL");
45690          seriesSelectorType.setYear(2);
45691          this.seriesSelectorTypes.push(seriesSelectorType);
45692        }
45693      }
45694      if (this.extended3Y) {
45695        if (this.lastDate === void 0 || this.lastDate.getTime() > now2.getTime() - 3 * 365 * 24 * 60 * 60 * 1e3) {
45696          const seriesSelectorType = new SeriesSelectorType("HISTORICAL");
45697          seriesSelectorType.setYear(3);
45698          this.seriesSelectorTypes.push(seriesSelectorType);
45699        }
45700      }
45701      if (this.extended5Y) {
45702        if (this.lastDate === void 0 || this.lastDate.getTime() > now2.getTime() - 5 * 365 * 24 * 60 * 60 * 1e3) {
45703          const seriesSelectorType = new SeriesSelectorType("HISTORICAL");
45704          seriesSelectorType.setYear(5);
45705          this.seriesSelectorTypes.push(seriesSelectorType);
45706        }
45707      }
45708      if (this.extendedBeginY) {
45709        if (this.lastDate === void 0 || this.lastDate.getTime() > new Date(now2.getFullYear(), 0, 1).getTime()) {
45710          const seriesSelectorType = new SeriesSelectorType("HISTORICAL");
45711          seriesSelectorType.setStartOfYear();
45712          this.seriesSelectorTypes.push(seriesSelectorType);
45713        }
45714      }
45715      this.seriesSelectorTypes.forEach((x) => {
45716        if (x.description === this.defaultSeriesSelectorType) {
45717          x.selected = true;
45718        }
45719      });
45720    }
45721  }
45722  getSeriesDescription(seriesSelectorType) {
45723    return this.translationService.get(seriesSelectorType.description);
45724  }
45725  getSeriesTypeClass(seriesSelectorType) {
45726    return "SeriesSelectorType " + seriesSelectorType.description + (seriesSelectorType.selected ? " selected" : "");
45727  }
45728  onSeriesSelectorTypeClick(seriesSelectorType) {
45729    this.seriesSelectorTypes.forEach((x) => {
45730      x.selected = false;
45731    });
45732    seriesSelectorType.selected = true;
45733    this.messageService.sendMessage(this.EventChannel, new MessageSeriesTypeSelected(seriesSelectorType), this.CallerName);
45734  }
45735  static {
45736    this.\u0275fac = /* @__PURE__ */ (() => {
45737      let \u0275DoraSeriesSelectorComponent_BaseFactory;
45738      return function DoraSeriesSelectorComponent_Factory(__ngFactoryType__) {
45739        return (\u0275DoraSeriesSelectorComponent_BaseFactory || (\u0275DoraSeriesSelectorComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraSeriesSelectorComponent)))(__ngFactoryType__ || _DoraSeriesSelectorComponent);
45740      };
45741    })();
45742  }
45743  static {
45744    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraSeriesSelectorComponent, selectors: [["dora-series-selector"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 2, vars: 1, consts: [[1, "DAG-Series-selector"], [3, "class", "innerHTML", "click", 4, "ngFor", "ngForOf"], [3, "click", "innerHTML"]], template: function DoraSeriesSelectorComponent_Template(rf, ctx) {
45745      if (rf & 1) {
45746        \u0275\u0275elementStart(0, "div", 0);
45747        \u0275\u0275template(1, DoraSeriesSelectorComponent_div_1_Template, 1, 3, "div", 1);
45748        \u0275\u0275elementEnd();
45749      }
45750      if (rf & 2) {
45751        \u0275\u0275advance();
45752        \u0275\u0275property("ngForOf", ctx.seriesSelectorTypes);
45753      }
45754    }, dependencies: [NgForOf], styles: ["\n\n.DAG-Series-selector[_ngcontent-%COMP%] {\n  display: flex;\n  justify-content: space-around;\n}\n.DAG-Series-selector[_ngcontent-%COMP%]   .SeriesSelectorType[_ngcontent-%COMP%] {\n  cursor: pointer;\n}\n.DAG-Series-selector[_ngcontent-%COMP%]   .SeriesSelectorType.selected[_ngcontent-%COMP%] {\n  color: #fff;\n  background-color: #007bff;\n}"] });
45755  }
45756};
45757__decorate([
45758  DoraProperty,
45759  __metadata("design:type", Boolean)
45760], DoraSeriesSelectorComponent.prototype, "extendedHistorical", void 0);
45761__decorate([
45762  DoraProperty,
45763  __metadata("design:type", Boolean)
45764], DoraSeriesSelectorComponent.prototype, "extended7D", void 0);
45765__decorate([
45766  DoraProperty,
45767  __metadata("design:type", Boolean)
45768], DoraSeriesSelectorComponent.prototype, "extended1M", void 0);
45769__decorate([
45770  DoraProperty,
45771  __metadata("design:type", Boolean)
45772], DoraSeriesSelectorComponent.prototype, "extended2M", void 0);
45773__decorate([
45774  DoraProperty,
45775  __metadata("design:type", Boolean)
45776], DoraSeriesSelectorComponent.prototype, "extended3M", void 0);
45777__decorate([
45778  DoraProperty,
45779  __metadata("design:type", Boolean)
45780], DoraSeriesSelectorComponent.prototype, "extended6M", void 0);
45781__decorate([
45782  DoraProperty,
45783  __metadata("design:type", Boolean)
45784], DoraSeriesSelectorComponent.prototype, "extended9M", void 0);
45785__decorate([
45786  DoraProperty,
45787  __metadata("design:type", Boolean)
45788], DoraSeriesSelectorComponent.prototype, "extended1Y", void 0);
45789__decorate([
45790  DoraProperty,
45791  __metadata("design:type", Boolean)
45792], DoraSeriesSelectorComponent.prototype, "extended2Y", void 0);
45793__decorate([
45794  DoraProperty,
45795  __metadata("design:type", Boolean)
45796], DoraSeriesSelectorComponent.prototype, "extended3Y", void 0);
45797__decorate([
45798  DoraProperty,
45799  __metadata("design:type", Boolean)
45800], DoraSeriesSelectorComponent.prototype, "extended5Y", void 0);
45801__decorate([
45802  DoraProperty,
45803  __metadata("design:type", Boolean)
45804], DoraSeriesSelectorComponent.prototype, "extendedBeginY", void 0);
45805__decorate([
45806  DoraPropertyArray(SeriesSelectorType),
45807  __metadata("design:type", Array)
45808], DoraSeriesSelectorComponent.prototype, "seriesSelectorTypes", void 0);
45809__decorate([
45810  DoraProperty,
45811  __metadata("design:type", String)
45812], DoraSeriesSelectorComponent.prototype, "defaultSeriesSelectorType", void 0);
45813(() => {
45814  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraSeriesSelectorComponent, { className: "DoraSeriesSelectorComponent", filePath: "src/app/dorawidget/dora-series-selector/dora-series-selector.component.ts", lineNumber: 15 });
45815})();
45816
45817// src/app/DoraWidget/dora-data-grid-selector/dora-data-grid-selector-cb/dora-data-grid-selector-cb.component.ts
45818function DoraDataGridSelectorCbComponent_div_0_Template(rf, ctx) {
45819  if (rf & 1) {
45820    const _r1 = \u0275\u0275getCurrentView();
45821    \u0275\u0275elementStart(0, "div", 2);
45822    \u0275\u0275listener("click", function DoraDataGridSelectorCbComponent_div_0_Template_div_click_0_listener() {
45823      \u0275\u0275restoreView(_r1);
45824      const ctx_r1 = \u0275\u0275nextContext();
45825      return \u0275\u0275resetView(ctx_r1.onEnableSetting());
45826    });
45827    \u0275\u0275elementEnd();
45828  }
45829}
45830function DoraDataGridSelectorCbComponent_div_1_div_1_Template(rf, ctx) {
45831  if (rf & 1) {
45832    const _r3 = \u0275\u0275getCurrentView();
45833    \u0275\u0275elementStart(0, "div", 5);
45834    \u0275\u0275listener("click", function DoraDataGridSelectorCbComponent_div_1_div_1_Template_div_click_0_listener() {
45835      const ctx_r3 = \u0275\u0275restoreView(_r3);
45836      const row_r5 = ctx_r3.$implicit;
45837      const rowIdx_r6 = ctx_r3.index;
45838      const ctx_r1 = \u0275\u0275nextContext(2);
45839      return \u0275\u0275resetView(ctx_r1.onSelect(rowIdx_r6, row_r5));
45840    });
45841    \u0275\u0275elementStart(1, "div", 6);
45842    \u0275\u0275element(2, "div");
45843    \u0275\u0275elementEnd();
45844    \u0275\u0275element(3, "div", 7);
45845    \u0275\u0275elementEnd();
45846  }
45847  if (rf & 2) {
45848    const row_r5 = ctx.$implicit;
45849    const rowIdx_r6 = ctx.index;
45850    const ctx_r1 = \u0275\u0275nextContext(2);
45851    \u0275\u0275classMap(ctx_r1.getElementContentCssClass(rowIdx_r6, row_r5));
45852    \u0275\u0275advance(2);
45853    \u0275\u0275classMap(ctx_r1.getElementContainerCssClass(rowIdx_r6, row_r5));
45854    \u0275\u0275advance();
45855    \u0275\u0275property("innerHTML", ctx_r1.getElementContent(rowIdx_r6, row_r5), \u0275\u0275sanitizeHtml);
45856  }
45857}
45858function DoraDataGridSelectorCbComponent_div_1_Template(rf, ctx) {
45859  if (rf & 1) {
45860    \u0275\u0275elementStart(0, "div", 3);
45861    \u0275\u0275template(1, DoraDataGridSelectorCbComponent_div_1_div_1_Template, 4, 5, "div", 4);
45862    \u0275\u0275elementEnd();
45863  }
45864  if (rf & 2) {
45865    const ctx_r1 = \u0275\u0275nextContext();
45866    \u0275\u0275advance();
45867    \u0275\u0275property("ngForOf", ctx_r1.dataRows);
45868  }
45869}
45870var DoraDataGridSelectorCbComponent = class _DoraDataGridSelectorCbComponent extends DoraDataGridSelectorComponent {
45871  onSelect(rowIndex, dataRow) {
45872    this.selectedGrid(dataRow.Id);
45873  }
45874  // Methods for Css Class
45875  getElementContainerCssClass(rowIndex, dataRow) {
45876    let result;
45877    result = "dag-checkbox " + dataRow.CssFormat;
45878    result += dataRow.selected ? " on" : " off";
45879    return result;
45880  }
45881  getElementContentCssClass(rowIndex, dataRow) {
45882    let result = "cb-element-content ";
45883    result += dataRow.selected ? " on" : " off";
45884    return result;
45885  }
45886  getElementContent(rowIndex, dataRow) {
45887    let result = "";
45888    const descriptionTupla = dataRow.getDataTupla("Description");
45889    if (descriptionTupla !== void 0) {
45890      result = descriptionTupla.Value;
45891    }
45892    return result;
45893  }
45894  static {
45895    this.\u0275fac = /* @__PURE__ */ (() => {
45896      let \u0275DoraDataGridSelectorCbComponent_BaseFactory;
45897      return function DoraDataGridSelectorCbComponent_Factory(__ngFactoryType__) {
45898        return (\u0275DoraDataGridSelectorCbComponent_BaseFactory || (\u0275DoraDataGridSelectorCbComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraDataGridSelectorCbComponent)))(__ngFactoryType__ || _DoraDataGridSelectorCbComponent);
45899      };
45900    })();
45901  }
45902  static {
45903    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraDataGridSelectorCbComponent, selectors: [["dora-data-grid-selector-tab"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 2, vars: 2, consts: [["class", "setting-command", 3, "click", 4, "ngIf"], ["class", "DAG-data-grid-selector-cb", 4, "ngIf"], [1, "setting-command", 3, "click"], [1, "DAG-data-grid-selector-cb"], [3, "class", "click", 4, "ngFor", "ngForOf"], [3, "click"], [1, "selector-container"], [1, "description", 3, "innerHTML"]], template: function DoraDataGridSelectorCbComponent_Template(rf, ctx) {
45904      if (rf & 1) {
45905        \u0275\u0275template(0, DoraDataGridSelectorCbComponent_div_0_Template, 1, 0, "div", 0)(1, DoraDataGridSelectorCbComponent_div_1_Template, 2, 1, "div", 1);
45906      }
45907      if (rf & 2) {
45908        \u0275\u0275property("ngIf", ctx.settingEnabled);
45909        \u0275\u0275advance();
45910        \u0275\u0275property("ngIf", ctx.dataGrid);
45911      }
45912    }, dependencies: [NgForOf, NgIf], styles: ["\n\n.DAG-data-grid-selector-cb[_ngcontent-%COMP%]   .cb-element-content[_ngcontent-%COMP%] {\n  cursor: pointer;\n  display: flex;\n  gap: 10px;\n}\n.DAG-data-grid-selector-cb[_ngcontent-%COMP%]   .cb-element-content.on[_ngcontent-%COMP%] {\n  font-weight: bold;\n}\n.DAG-data-grid-selector-cb[_ngcontent-%COMP%]   .cb-element-content[_ngcontent-%COMP%]   .selector-container[_ngcontent-%COMP%]   .dag-checkbox[_ngcontent-%COMP%] {\n  width: 10px;\n  height: 10px;\n  display: block;\n  overflow: hidden;\n  border: 1px solid black;\n}\n.DAG-data-grid-selector-cb[_ngcontent-%COMP%]   .cb-element-content[_ngcontent-%COMP%]   .selector-container[_ngcontent-%COMP%]   .dag-checkbox.on[_ngcontent-%COMP%] {\n  background-color: black;\n}\n.DAG-data-grid-selector-cb[_ngcontent-%COMP%]   .cb-element-content[_ngcontent-%COMP%]   .selector-container[_ngcontent-%COMP%]   .dag-checkbox.off[_ngcontent-%COMP%] {\n  background-color: white;\n}"] });
45913  }
45914};
45915(() => {
45916  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraDataGridSelectorCbComponent, { className: "DoraDataGridSelectorCbComponent", filePath: "src/app/dorawidget/dora-data-grid-selector/dora-data-grid-selector-cb/dora-data-grid-selector-cb.component.ts", lineNumber: 12 });
45917})();
45918
45919// src/app/DoraWidget/dora-series-from-grid/data/row-to-subscribe.ts
45920var RowToSubscribe = class {
45921  constructor(dataRow, publisherParameters) {
45922    this.publisherParameters = [];
45923    this.dataRow = dataRow;
45924    this.publisherParameters = publisherParameters;
45925  }
45926  get DataRow() {
45927    return this.dataRow;
45928  }
45929  get PublisherParameters() {
45930    return this.publisherParameters;
45931  }
45932};
45933
45934// src/app/DoraWidget/dora-series-from-row/dora-series-from-row.component.ts
45935var DoraSeriesFromRowComponent = class _DoraSeriesFromRowComponent extends WidgetBaseComponent {
45936  constructor() {
45937    super(...arguments);
45938    this.idrows = [];
45939    this.colors = [];
45940    this.seriesStartPointAligned = false;
45941    this.calculateLastDate = false;
45942    this.lastDate = null;
45943    this.idrowsSelected = [];
45944    this.fixedSeriesInfos = [];
45945    this.series = [];
45946  }
45947  onParameterInjectedFinished() {
45948    super.onParameterInjectedFinished();
45949    this.insertIdRows();
45950    this.readData(true);
45951    this.messageService.getMessage(this.EventChannel, MessageRowsSelected, this.CallerName).subscribe((message) => {
45952      const dataRows = [];
45953      message.data.DataRows.forEach((dataRow) => {
45954        dataRows.push(dataRow);
45955      });
45956      this.fixedSeriesInfos = message.data.FixedSeriesInfos;
45957      this.insertIdRows();
45958      dataRows.forEach((dataRow) => {
45959        const rowToSubscribe = new RowToSubscribe(dataRow, message.data.PublisherParameters);
45960        this.idrowsSelected.push(rowToSubscribe);
45961      });
45962      this.readData(false);
45963    });
45964  }
45965  readData(calculateEndDate) {
45966    this.series = [];
45967    this.idrowsSelected.forEach((rowToSubscribe) => {
45968      this.read([rowToSubscribe.DataRow.Id], DataType.HISTORICAL, this.getPublisherParameters(rowToSubscribe.PublisherParameters), rowToSubscribe.DataRow.Color).subscribe((data) => {
45969        if (data !== null) {
45970          const readResult = data;
45971          if (readResult.Data !== null) {
45972            const dataSeries = readResult.Data;
45973            if (readResult.CallerData !== null) {
45974              dataSeries.Color = readResult.CallerData;
45975            }
45976            this.series.push(dataSeries);
45977            this.onNewData(calculateEndDate);
45978          }
45979        }
45980      });
45981    });
45982  }
45983  onNewData(calculateEndDate) {
45984    if (this.series.length === this.idrowsSelected.length) {
45985      const seriesOrdered = [];
45986      this.allignSeriesStartEndPoint();
45987      this.idrowsSelected.forEach((rowToSubscribe) => {
45988        seriesOrdered.push(this.series.find((series) => series.SubscribeId === rowToSubscribe.DataRow.Id));
45989      });
45990      const fixedSeries = this.buildFixedSeries();
45991      fixedSeries.forEach((series) => {
45992        seriesOrdered.push(series);
45993      });
45994      this.messageService.sendMessage(this.EventChannel, new MessageSeriesSelected(seriesOrdered, null), this.CallerName);
45995      if (calculateEndDate) {
45996        this.calculateEndDate();
45997      }
45998    }
45999  }
46000  calculateEndDate() {
46001    if (this.calculateLastDate) {
46002      let highEndDate = null;
46003      const series = this.series.filter((serie) => {
46004        return this.idrowsSelected.find((idrow) => {
46005          return idrow.DataRow.Id === serie.SubscribeId;
46006        }) !== void 0;
46007      });
46008      series.forEach((serie) => {
46009        const tupla = serie.DataRows[serie.DataRows.length - 1].getDataTupla("Timestamp");
46010        if (tupla === void 0) {
46011          return;
46012        }
46013        const tuplaTimestamp = tupla.Value;
46014        if (highEndDate === null || tuplaTimestamp > highEndDate) {
46015          highEndDate = tuplaTimestamp;
46016        }
46017      });
46018      this.lastDate = highEndDate;
46019      if (highEndDate !== null) {
46020        this.messageService.sendMessage(this.EventChannel, new MessageLastDate(highEndDate), this.CallerName);
46021      }
46022    }
46023  }
46024  allignSeriesStartEndPoint() {
46025    if (this.seriesStartPointAligned && this.series.length > 1) {
46026      let highStartDate = null;
46027      this.series.forEach((series) => {
46028        let tupla = series.DataRows[0].getDataTupla("Timestamp");
46029        if (tupla === void 0) {
46030          return;
46031        }
46032        const tuplaTimestamp = tupla.Value;
46033        if (highStartDate === null || tuplaTimestamp > highStartDate) {
46034          highStartDate = tuplaTimestamp;
46035        }
46036      });
46037      this.series.forEach((series) => {
46038        let tupla = series.DataRows[0].getDataTupla("Timestamp");
46039        if (tupla === void 0 || highStartDate === null) {
46040          return;
46041        }
46042        while (series.DataRows.length > 0 && tupla.Value < highStartDate) {
46043          series.DataRows.shift();
46044          tupla = series.DataRows[0].getDataTupla("Timestamp");
46045          if (tupla === void 0 || this.lastDate === null) {
46046            return;
46047          }
46048        }
46049      });
46050    }
46051    if (this.lastDate !== null) {
46052      this.series.forEach((series) => {
46053        let tupla = series.DataRows[series.DataRows.length - 1].getDataTupla("Timestamp");
46054        if (tupla === void 0 || this.lastDate === null) {
46055          return;
46056        }
46057        while (series.DataRows.length > 0 && tupla.Value > this.lastDate) {
46058          series.DataRows.pop();
46059          tupla = series.DataRows[series.DataRows.length - 1].getDataTupla("Timestamp");
46060          if (tupla === void 0 || this.lastDate === null) {
46061            return;
46062          }
46063        }
46064      });
46065    }
46066  }
46067  isCompareChart() {
46068    return this.series.length > 1;
46069  }
46070  /**
46071   * Build fixed series. They are series with fixed value or percentage value. Dates are kept from first stockSeries
46072   */
46073  buildFixedSeries() {
46074    const result = [];
46075    const firstRowOrg = this.series[0].DataRows[0];
46076    this.fixedSeriesInfos.forEach((fixedSeriesInfo) => {
46077      const fixedSeries = new DataSeries();
46078      fixedSeries.DataType = "Row";
46079      fixedSeries.Description = fixedSeriesInfo.name === void 0 ? "" : fixedSeriesInfo.name;
46080      fixedSeries.Id = fixedSeriesInfo.name === void 0 ? "" : fixedSeriesInfo.name;
46081      fixedSeries.Language = this.series[0].Language;
46082      fixedSeries.Units = this.series[0].Units;
46083      fixedSeries.TuplasDescription = this.series[0].TuplasDescription;
46084      fixedSeries.Color = fixedSeriesInfo.color;
46085      fixedSeries.FixedSeries = true;
46086      let fixedValue = 0;
46087      if (fixedSeriesInfo.type === TUPLA_TYPE.NUMBER) {
46088        fixedValue = fixedSeriesInfo.value === void 0 ? 0 : fixedSeriesInfo.value;
46089      } else {
46090        const tuplaClose = firstRowOrg.getDataTupla("Close");
46091        if (fixedSeriesInfo.value !== void 0 && tuplaClose !== void 0) {
46092          fixedValue = this.isCompareChart() ? fixedSeriesInfo.value * 100 : tuplaClose.Value * fixedSeriesInfo.value / 100;
46093        }
46094      }
46095      this.series[0].DataRows.forEach((dataRow) => {
46096        const newRow = dataRow.clone();
46097        const tuplaClose = newRow.getDataTupla("Close");
46098        if (tuplaClose !== void 0) {
46099          tuplaClose.Value = fixedValue;
46100        }
46101        fixedSeries.DataRows.push(newRow);
46102      });
46103      result.push(fixedSeries);
46104    });
46105    return result;
46106  }
46107  /**
46108   * Insert all idrows in idrowsSelected
46109   */
46110  insertIdRows() {
46111    this.idrowsSelected = [];
46112    this.idrows.forEach((idrow, index) => {
46113      const dataRow = new DataRow();
46114      dataRow.Id = idrow.key;
46115      if (this.colors.length > 0) {
46116        dataRow.Color = this.colors[index % this.colors.length].key;
46117      }
46118      const rowToSubscribe = new RowToSubscribe(dataRow, this.publisherParameters);
46119      this.idrowsSelected.push(rowToSubscribe);
46120    });
46121  }
46122  static {
46123    this.\u0275fac = /* @__PURE__ */ (() => {
46124      let \u0275DoraSeriesFromRowComponent_BaseFactory;
46125      return function DoraSeriesFromRowComponent_Factory(__ngFactoryType__) {
46126        return (\u0275DoraSeriesFromRowComponent_BaseFactory || (\u0275DoraSeriesFromRowComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraSeriesFromRowComponent)))(__ngFactoryType__ || _DoraSeriesFromRowComponent);
46127      };
46128    })();
46129  }
46130  static {
46131    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraSeriesFromRowComponent, selectors: [["dora-series-from-row"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 0, vars: 0, template: function DoraSeriesFromRowComponent_Template(rf, ctx) {
46132    }, encapsulation: 2 });
46133  }
46134};
46135__decorate([
46136  DoraPropertyArray(Id),
46137  __metadata("design:type", Array)
46138], DoraSeriesFromRowComponent.prototype, "idrows", void 0);
46139__decorate([
46140  DoraPropertyArray(Id),
46141  __metadata("design:type", Array)
46142], DoraSeriesFromRowComponent.prototype, "colors", void 0);
46143__decorate([
46144  DoraProperty,
46145  __metadata("design:type", Boolean)
46146], DoraSeriesFromRowComponent.prototype, "seriesStartPointAligned", void 0);
46147__decorate([
46148  DoraProperty,
46149  __metadata("design:type", Boolean)
46150], DoraSeriesFromRowComponent.prototype, "calculateLastDate", void 0);
46151(() => {
46152  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraSeriesFromRowComponent, { className: "DoraSeriesFromRowComponent", filePath: "src/app/dorawidget/dora-series-from-row/dora-series-from-row.component.ts", lineNumber: 24 });
46153})();
46154
46155// src/app/DoraWidget/dora-series-from-grid/dora-series-from-grid.component.ts
46156var DoraSeriesFromGridComponent = class _DoraSeriesFromGridComponent extends WidgetBaseGridComponent {
46157  constructor() {
46158    super(...arguments);
46159    this.reverseSeries = false;
46160    this.invertColumnsRows = false;
46161    this.selectAllRowsOnStart = true;
46162    this.idrowsInitial = [];
46163    this.descriptiondrowsInitial = [];
46164    this.idcolumnsInitial = [];
46165  }
46166  onParameterInjectedFinished() {
46167    super.onParameterInjectedFinished();
46168    this.messageService.getMessage(this.EventChannel, MessageRowsSelected, this.CallerName).subscribe((message) => {
46169      const idRows = [];
46170      message.data.DataRows.forEach((dataRow) => {
46171        idRows.push(dataRow.Id);
46172      });
46173      if (this.dataGrid == null) {
46174        return;
46175      }
46176      this.dataGrid.selectRows(idRows);
46177      this.messageService.sendMessage(this.EventChannel, new MessageSeriesSelected(this.dataGrid.rowsSelected2Series(this.reverseSeries, null, this.invertColumnsRows), null), this.CallerName);
46178    });
46179  }
46180  onNewData() {
46181    super.onNewData();
46182    if (this.dataGrid == null) {
46183      return;
46184    }
46185    if (this.idcolumnsInitial.length > 0) {
46186      this.dataGrid.selectColumnById(this.idcolumnsInitial);
46187    } else {
46188      this.dataGrid.selectColumnsByType(TUPLA_TYPE.NUMBER);
46189    }
46190    let selected = false;
46191    if (this.idrowsInitial.length > 0) {
46192      this.dataGrid.selectRowsById(this.idrowsInitial);
46193      selected = true;
46194    } else if (this.descriptiondrowsInitial.length > 0) {
46195      this.dataGrid.selectRowsByDescription(this.descriptiondrowsInitial);
46196      selected = true;
46197    } else if (this.selectAllRowsOnStart) {
46198      this.dataGrid.selectAllRows();
46199      selected = true;
46200    }
46201    if (selected) {
46202      this.messageService.sendMessage(this.EventChannel, new MessageSeriesSelected(this.dataGrid.rowsSelected2Series(this.reverseSeries, this.dataGrid.getIdSelectedColumns(), this.invertColumnsRows), null), this.CallerName);
46203    }
46204  }
46205  static {
46206    this.\u0275fac = /* @__PURE__ */ (() => {
46207      let \u0275DoraSeriesFromGridComponent_BaseFactory;
46208      return function DoraSeriesFromGridComponent_Factory(__ngFactoryType__) {
46209        return (\u0275DoraSeriesFromGridComponent_BaseFactory || (\u0275DoraSeriesFromGridComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraSeriesFromGridComponent)))(__ngFactoryType__ || _DoraSeriesFromGridComponent);
46210      };
46211    })();
46212  }
46213  static {
46214    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraSeriesFromGridComponent, selectors: [["dora-series-from-grid"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 0, vars: 0, template: function DoraSeriesFromGridComponent_Template(rf, ctx) {
46215    }, encapsulation: 2 });
46216  }
46217};
46218__decorate([
46219  DoraProperty,
46220  __metadata("design:type", Boolean)
46221], DoraSeriesFromGridComponent.prototype, "reverseSeries", void 0);
46222__decorate([
46223  DoraProperty,
46224  __metadata("design:type", Boolean)
46225], DoraSeriesFromGridComponent.prototype, "invertColumnsRows", void 0);
46226__decorate([
46227  DoraProperty,
46228  __metadata("design:type", Boolean)
46229], DoraSeriesFromGridComponent.prototype, "selectAllRowsOnStart", void 0);
46230__decorate([
46231  DoraPropertyDOC("Elenco delle righe da visualizzare inizialmente", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
46232  DoraPropertyArray(Id),
46233  __metadata("design:type", Array)
46234], DoraSeriesFromGridComponent.prototype, "idrowsInitial", void 0);
46235__decorate([
46236  DoraPropertyDOC("Elenco delle righe da visualizzare inizialmente (per descrizione)", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
46237  DoraPropertyArray(Id),
46238  __metadata("design:type", Array)
46239], DoraSeriesFromGridComponent.prototype, "descriptiondrowsInitial", void 0);
46240__decorate([
46241  DoraPropertyDOC("Elenco delle colonne da visualizzare inizialmente", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
46242  DoraPropertyArray(Id),
46243  __metadata("design:type", Array)
46244], DoraSeriesFromGridComponent.prototype, "idcolumnsInitial", void 0);
46245(() => {
46246  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraSeriesFromGridComponent, { className: "DoraSeriesFromGridComponent", filePath: "src/app/dorawidget/dora-series-from-grid/dora-series-from-grid.component.ts", lineNumber: 15 });
46247})();
46248
46249// src/app/Utility/enabled-object.ts
46250var EnabledObject = class {
46251  constructor(defaultStatus = false) {
46252    this.objectNames = {};
46253    this.defaultStatus = false;
46254    this.defaultStatus = defaultStatus;
46255  }
46256  setStatus(name, status) {
46257    this.objectNames[name] = status;
46258  }
46259  getStatus(name) {
46260    return this.objectNames[name] ?? this.defaultStatus;
46261  }
46262  invertStatus(name) {
46263    this.setStatus(name, !this.getStatus(name));
46264  }
46265};
46266
46267// src/app/DoraWidget/dora-configurator/dora-configurator.component.ts
46268var _c02 = ["dialogContainer"];
46269function DoraConfiguratorComponent_div_0_div_12_div_3_Template(rf, ctx) {
46270  if (rf & 1) {
46271    \u0275\u0275element(0, "div", 25);
46272  }
46273  if (rf & 2) {
46274    const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46275    const ctx_r1 = \u0275\u0275nextContext(2);
46276    \u0275\u0275property("innerHTML", ctx_r1.getEditControlValue(srcParameter_r3.name), \u0275\u0275sanitizeHtml);
46277  }
46278}
46279function DoraConfiguratorComponent_div_0_div_12_div_5_Template(rf, ctx) {
46280  if (rf & 1) {
46281    const _r4 = \u0275\u0275getCurrentView();
46282    \u0275\u0275elementStart(0, "div", 26);
46283    \u0275\u0275listener("click", function DoraConfiguratorComponent_div_0_div_12_div_5_Template_div_click_0_listener() {
46284      \u0275\u0275restoreView(_r4);
46285      const parameterIdx_r5 = \u0275\u0275nextContext().index;
46286      const ctx_r1 = \u0275\u0275nextContext(2);
46287      return \u0275\u0275resetView(ctx_r1.setAccordionClass("array-parameter-container", parameterIdx_r5));
46288    });
46289    \u0275\u0275elementEnd();
46290  }
46291  if (rf & 2) {
46292    const parameterIdx_r5 = \u0275\u0275nextContext().index;
46293    const ctx_r1 = \u0275\u0275nextContext(2);
46294    \u0275\u0275classMap("accordion-status-" + ctx_r1.getAccordionStatusClass("array-parameter-container", parameterIdx_r5));
46295  }
46296}
46297function DoraConfiguratorComponent_div_0_div_12_div_6_Template(rf, ctx) {
46298  if (rf & 1) {
46299    const _r6 = \u0275\u0275getCurrentView();
46300    \u0275\u0275elementStart(0, "div", 27);
46301    \u0275\u0275listener("click", function DoraConfiguratorComponent_div_0_div_12_div_6_Template_div_click_0_listener() {
46302      \u0275\u0275restoreView(_r6);
46303      const parameterIdx_r5 = \u0275\u0275nextContext().index;
46304      const ctx_r1 = \u0275\u0275nextContext(2);
46305      return \u0275\u0275resetView(ctx_r1.setAccordionClass("array-parameter-container", parameterIdx_r5));
46306    });
46307    \u0275\u0275elementEnd();
46308  }
46309  if (rf & 2) {
46310    const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46311    const ctx_r1 = \u0275\u0275nextContext(2);
46312    \u0275\u0275property("innerHTML", ctx_r1.ATTRIBUTE_TYPE[srcParameter_r3.type], \u0275\u0275sanitizeHtml);
46313  }
46314}
46315function DoraConfiguratorComponent_div_0_div_12_div_7_Template(rf, ctx) {
46316  if (rf & 1) {
46317    \u0275\u0275element(0, "div", 28);
46318  }
46319  if (rf & 2) {
46320    const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46321    const ctx_r1 = \u0275\u0275nextContext(2);
46322    \u0275\u0275property("innerHTML", ctx_r1.ATTRIBUTE_TYPE[srcParameter_r3.type], \u0275\u0275sanitizeHtml);
46323  }
46324}
46325function DoraConfiguratorComponent_div_0_div_12_select_8_option_1_Template(rf, ctx) {
46326  if (rf & 1) {
46327    \u0275\u0275elementStart(0, "option", 31);
46328    \u0275\u0275text(1);
46329    \u0275\u0275elementEnd();
46330  }
46331  if (rf & 2) {
46332    const option_r8 = ctx.$implicit;
46333    const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46334    const ctx_r1 = \u0275\u0275nextContext(2);
46335    \u0275\u0275property("value", option_r8)("selected", option_r8 === ctx_r1.getEditControlValue(srcParameter_r3.name));
46336    \u0275\u0275advance();
46337    \u0275\u0275textInterpolate(option_r8);
46338  }
46339}
46340function DoraConfiguratorComponent_div_0_div_12_select_8_Template(rf, ctx) {
46341  if (rf & 1) {
46342    const _r7 = \u0275\u0275getCurrentView();
46343    \u0275\u0275elementStart(0, "select", 29);
46344    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_select_8_Template_select_change_0_listener($event) {
46345      \u0275\u0275restoreView(_r7);
46346      const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46347      const ctx_r1 = \u0275\u0275nextContext(2);
46348      return \u0275\u0275resetView(ctx_r1.onValueChange($event, srcParameter_r3.name));
46349    });
46350    \u0275\u0275template(1, DoraConfiguratorComponent_div_0_div_12_select_8_option_1_Template, 2, 3, "option", 30);
46351    \u0275\u0275elementEnd();
46352  }
46353  if (rf & 2) {
46354    const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46355    \u0275\u0275property("formControlName", srcParameter_r3.name);
46356    \u0275\u0275advance();
46357    \u0275\u0275property("ngForOf", srcParameter_r3.values);
46358  }
46359}
46360function DoraConfiguratorComponent_div_0_div_12_input_9_Template(rf, ctx) {
46361  if (rf & 1) {
46362    const _r9 = \u0275\u0275getCurrentView();
46363    \u0275\u0275elementStart(0, "input", 32);
46364    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_input_9_Template_input_change_0_listener($event) {
46365      \u0275\u0275restoreView(_r9);
46366      const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46367      const ctx_r1 = \u0275\u0275nextContext(2);
46368      return \u0275\u0275resetView(ctx_r1.onValueChange($event, srcParameter_r3.name));
46369    });
46370    \u0275\u0275elementEnd();
46371  }
46372  if (rf & 2) {
46373    const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46374    \u0275\u0275property("formControlName", srcParameter_r3.name);
46375  }
46376}
46377function DoraConfiguratorComponent_div_0_div_12_input_10_Template(rf, ctx) {
46378  if (rf & 1) {
46379    const _r10 = \u0275\u0275getCurrentView();
46380    \u0275\u0275elementStart(0, "input", 33);
46381    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_input_10_Template_input_change_0_listener($event) {
46382      \u0275\u0275restoreView(_r10);
46383      const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46384      const ctx_r1 = \u0275\u0275nextContext(2);
46385      return \u0275\u0275resetView(ctx_r1.onValueChange($event, srcParameter_r3.name));
46386    });
46387    \u0275\u0275elementEnd();
46388  }
46389  if (rf & 2) {
46390    const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46391    \u0275\u0275property("formControlName", srcParameter_r3.name);
46392  }
46393}
46394function DoraConfiguratorComponent_div_0_div_12_input_11_Template(rf, ctx) {
46395  if (rf & 1) {
46396    const _r11 = \u0275\u0275getCurrentView();
46397    \u0275\u0275elementStart(0, "input", 34);
46398    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_input_11_Template_input_change_0_listener($event) {
46399      \u0275\u0275restoreView(_r11);
46400      const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46401      const ctx_r1 = \u0275\u0275nextContext(2);
46402      return \u0275\u0275resetView(ctx_r1.onValueChange($event, srcParameter_r3.name));
46403    });
46404    \u0275\u0275elementEnd();
46405  }
46406  if (rf & 2) {
46407    const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46408    \u0275\u0275property("formControlName", srcParameter_r3.name);
46409  }
46410}
46411function DoraConfiguratorComponent_div_0_div_12_input_12_Template(rf, ctx) {
46412  if (rf & 1) {
46413    const _r12 = \u0275\u0275getCurrentView();
46414    \u0275\u0275elementStart(0, "input", 35);
46415    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_input_12_Template_input_change_0_listener($event) {
46416      \u0275\u0275restoreView(_r12);
46417      const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46418      const ctx_r1 = \u0275\u0275nextContext(2);
46419      return \u0275\u0275resetView(ctx_r1.onValueChange($event, srcParameter_r3.name));
46420    });
46421    \u0275\u0275elementEnd();
46422  }
46423  if (rf & 2) {
46424    const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46425    \u0275\u0275property("formControlName", srcParameter_r3.name);
46426  }
46427}
46428function DoraConfiguratorComponent_div_0_div_12_input_13_Template(rf, ctx) {
46429  if (rf & 1) {
46430    const _r13 = \u0275\u0275getCurrentView();
46431    \u0275\u0275elementStart(0, "input", 36);
46432    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_input_13_Template_input_change_0_listener($event) {
46433      \u0275\u0275restoreView(_r13);
46434      const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46435      const ctx_r1 = \u0275\u0275nextContext(2);
46436      return \u0275\u0275resetView(ctx_r1.onValueChange($event, srcParameter_r3.name));
46437    });
46438    \u0275\u0275elementEnd();
46439  }
46440  if (rf & 2) {
46441    const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46442    \u0275\u0275property("formControlName", srcParameter_r3.name);
46443  }
46444}
46445function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_select_4_option_1_Template(rf, ctx) {
46446  if (rf & 1) {
46447    \u0275\u0275elementStart(0, "option", 31);
46448    \u0275\u0275text(1);
46449    \u0275\u0275elementEnd();
46450  }
46451  if (rf & 2) {
46452    const option_r19 = ctx.$implicit;
46453    const srcParameterChildDefinition_r18 = \u0275\u0275nextContext(2).$implicit;
46454    const srcParameterChild_r16 = \u0275\u0275nextContext().$implicit;
46455    const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46456    const ctx_r1 = \u0275\u0275nextContext(2);
46457    \u0275\u0275property("value", option_r19)("selected", option_r19 === ctx_r1.getEditControlValue(srcParameter_r3.name + "." + srcParameterChildDefinition_r18.name + "." + srcParameterChild_r16.Progressive));
46458    \u0275\u0275advance();
46459    \u0275\u0275textInterpolate(option_r19);
46460  }
46461}
46462function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_select_4_Template(rf, ctx) {
46463  if (rf & 1) {
46464    const _r17 = \u0275\u0275getCurrentView();
46465    \u0275\u0275elementStart(0, "select", 32);
46466    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_select_4_Template_select_change_0_listener($event) {
46467      \u0275\u0275restoreView(_r17);
46468      const srcParameterChildDefinition_r18 = \u0275\u0275nextContext().$implicit;
46469      const srcParameterChild_r16 = \u0275\u0275nextContext().$implicit;
46470      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46471      const ctx_r1 = \u0275\u0275nextContext(2);
46472      return \u0275\u0275resetView(ctx_r1.onValueChangeArray($event, srcParameter_r3, srcParameterChildDefinition_r18, srcParameterChild_r16));
46473    });
46474    \u0275\u0275template(1, DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_select_4_option_1_Template, 2, 3, "option", 30);
46475    \u0275\u0275elementEnd();
46476  }
46477  if (rf & 2) {
46478    const srcParameterChildDefinition_r18 = \u0275\u0275nextContext().$implicit;
46479    const srcParameterChild_r16 = \u0275\u0275nextContext().$implicit;
46480    const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46481    \u0275\u0275property("formControlName", srcParameter_r3.name + "." + srcParameterChildDefinition_r18.name + "." + srcParameterChild_r16.Progressive);
46482    \u0275\u0275advance();
46483    \u0275\u0275property("ngForOf", srcParameterChildDefinition_r18.values);
46484  }
46485}
46486function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_5_Template(rf, ctx) {
46487  if (rf & 1) {
46488    const _r20 = \u0275\u0275getCurrentView();
46489    \u0275\u0275elementStart(0, "input", 32);
46490    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_5_Template_input_change_0_listener($event) {
46491      \u0275\u0275restoreView(_r20);
46492      const srcParameterChildDefinition_r18 = \u0275\u0275nextContext().$implicit;
46493      const srcParameterChild_r16 = \u0275\u0275nextContext().$implicit;
46494      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46495      const ctx_r1 = \u0275\u0275nextContext(2);
46496      return \u0275\u0275resetView(ctx_r1.onValueChangeArray($event, srcParameter_r3, srcParameterChildDefinition_r18, srcParameterChild_r16));
46497    });
46498    \u0275\u0275elementEnd();
46499  }
46500  if (rf & 2) {
46501    const srcParameterChildDefinition_r18 = \u0275\u0275nextContext().$implicit;
46502    const srcParameterChild_r16 = \u0275\u0275nextContext().$implicit;
46503    const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46504    \u0275\u0275property("formControlName", srcParameter_r3.name + "." + srcParameterChildDefinition_r18.name + "." + srcParameterChild_r16.Progressive);
46505  }
46506}
46507function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_6_Template(rf, ctx) {
46508  if (rf & 1) {
46509    const _r21 = \u0275\u0275getCurrentView();
46510    \u0275\u0275elementStart(0, "input", 33);
46511    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_6_Template_input_change_0_listener($event) {
46512      \u0275\u0275restoreView(_r21);
46513      const srcParameterChildDefinition_r18 = \u0275\u0275nextContext().$implicit;
46514      const srcParameterChild_r16 = \u0275\u0275nextContext().$implicit;
46515      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46516      const ctx_r1 = \u0275\u0275nextContext(2);
46517      return \u0275\u0275resetView(ctx_r1.onValueChangeArray($event, srcParameter_r3, srcParameterChildDefinition_r18, srcParameterChild_r16));
46518    });
46519    \u0275\u0275elementEnd();
46520  }
46521  if (rf & 2) {
46522    const srcParameterChildDefinition_r18 = \u0275\u0275nextContext().$implicit;
46523    const srcParameterChild_r16 = \u0275\u0275nextContext().$implicit;
46524    const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46525    \u0275\u0275property("formControlName", srcParameter_r3.name + "." + srcParameterChildDefinition_r18.name + "." + srcParameterChild_r16.Progressive);
46526  }
46527}
46528function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_7_Template(rf, ctx) {
46529  if (rf & 1) {
46530    const _r22 = \u0275\u0275getCurrentView();
46531    \u0275\u0275elementStart(0, "input", 34);
46532    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_7_Template_input_change_0_listener($event) {
46533      \u0275\u0275restoreView(_r22);
46534      const srcParameterChildDefinition_r18 = \u0275\u0275nextContext().$implicit;
46535      const srcParameterChild_r16 = \u0275\u0275nextContext().$implicit;
46536      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46537      const ctx_r1 = \u0275\u0275nextContext(2);
46538      return \u0275\u0275resetView(ctx_r1.onValueChangeArray($event, srcParameter_r3, srcParameterChildDefinition_r18, srcParameterChild_r16));
46539    });
46540    \u0275\u0275elementEnd();
46541  }
46542  if (rf & 2) {
46543    const srcParameterChildDefinition_r18 = \u0275\u0275nextContext().$implicit;
46544    const srcParameterChild_r16 = \u0275\u0275nextContext().$implicit;
46545    const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46546    \u0275\u0275property("formControlName", srcParameter_r3.name + "." + srcParameterChildDefinition_r18.name + "." + srcParameterChild_r16.Progressive);
46547  }
46548}
46549function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_8_Template(rf, ctx) {
46550  if (rf & 1) {
46551    const _r23 = \u0275\u0275getCurrentView();
46552    \u0275\u0275elementStart(0, "input", 35);
46553    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_8_Template_input_change_0_listener($event) {
46554      \u0275\u0275restoreView(_r23);
46555      const srcParameterChildDefinition_r18 = \u0275\u0275nextContext().$implicit;
46556      const srcParameterChild_r16 = \u0275\u0275nextContext().$implicit;
46557      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46558      const ctx_r1 = \u0275\u0275nextContext(2);
46559      return \u0275\u0275resetView(ctx_r1.onValueChangeArray($event, srcParameter_r3, srcParameterChildDefinition_r18, srcParameterChild_r16));
46560    });
46561    \u0275\u0275elementEnd();
46562  }
46563  if (rf & 2) {
46564    const srcParameterChildDefinition_r18 = \u0275\u0275nextContext().$implicit;
46565    const srcParameterChild_r16 = \u0275\u0275nextContext().$implicit;
46566    const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46567    \u0275\u0275property("formControlName", srcParameter_r3.name + "." + srcParameterChildDefinition_r18.name + "." + srcParameterChild_r16.Progressive);
46568  }
46569}
46570function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_9_Template(rf, ctx) {
46571  if (rf & 1) {
46572    const _r24 = \u0275\u0275getCurrentView();
46573    \u0275\u0275elementStart(0, "input", 36);
46574    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_9_Template_input_change_0_listener($event) {
46575      \u0275\u0275restoreView(_r24);
46576      const srcParameterChildDefinition_r18 = \u0275\u0275nextContext().$implicit;
46577      const srcParameterChild_r16 = \u0275\u0275nextContext().$implicit;
46578      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46579      const ctx_r1 = \u0275\u0275nextContext(2);
46580      return \u0275\u0275resetView(ctx_r1.onValueChangeArray($event, srcParameter_r3, srcParameterChildDefinition_r18, srcParameterChild_r16));
46581    });
46582    \u0275\u0275elementEnd();
46583  }
46584  if (rf & 2) {
46585    const srcParameterChildDefinition_r18 = \u0275\u0275nextContext().$implicit;
46586    const srcParameterChild_r16 = \u0275\u0275nextContext().$implicit;
46587    const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46588    \u0275\u0275property("formControlName", srcParameter_r3.name + "." + srcParameterChildDefinition_r18.name + "." + srcParameterChild_r16.Progressive);
46589  }
46590}
46591function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_Template(rf, ctx) {
46592  if (rf & 1) {
46593    \u0275\u0275elementStart(0, "div", 10);
46594    \u0275\u0275element(1, "div", 11)(2, "div", 12)(3, "div", 28);
46595    \u0275\u0275template(4, DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_select_4_Template, 2, 2, "select", 19)(
465955, DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_5_Template, 1, 1, "input", 19)(6, DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_6_Template, 1, 1, "input", 20)(7, DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_7_Template, 1, 1, "input", 21)(8, DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_8_Template, 1, 1, "input", 22)(9, DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_input_9_Template, 1, 1, "input", 23);
46596    \u0275\u0275elementEnd();
46597  }
46598  if (rf & 2) {
46599    const srcParameterChildDefinition_r18 = ctx.$implicit;
46600    const ctx_r1 = \u0275\u0275nextContext(5);
46601    \u0275\u0275advance();
46602    \u0275\u0275property("innerHTML", srcParameterChildDefinition_r18.name, \u0275\u0275sanitizeHtml);
46603    \u0275\u0275advance();
46604    \u0275\u0275property("innerHTML", srcParameterChildDefinition_r18.descr, \u0275\u0275sanitizeHtml);
46605    \u0275\u0275advance();
46606    \u0275\u0275property("innerHTML", ctx_r1.ATTRIBUTE_TYPE[srcParameterChildDefinition_r18.type], \u0275\u0275sanitizeHtml);
46607    \u0275\u0275advance();
46608    \u0275\u0275property("ngIf", srcParameterChildDefinition_r18.type === ctx_r1.ATTRIBUTE_TYPE.STRING && srcParameterChildDefinition_r18.values.length > 0);
46609    \u0275\u0275advance();
46610    \u0275\u0275property("ngIf", srcParameterChildDefinition_r18.type === ctx_r1.ATTRIBUTE_TYPE.STRING && srcParameterChildDefinition_r18.values.length == 0);
46611    \u0275\u0275advance();
46612    \u0275\u0275property("ngIf", srcParameterChildDefinition_r18.type === ctx_r1.ATTRIBUTE_TYPE.COLOR);
46613    \u0275\u0275advance();
46614    \u0275\u0275property("ngIf", srcParameterChildDefinition_r18.type === ctx_r1.ATTRIBUTE_TYPE.INTEGER);
46615    \u0275\u0275advance();
46616    \u0275\u0275property("ngIf", srcParameterChildDefinition_r18.type === ctx_r1.ATTRIBUTE_TYPE.FLOAT);
46617    \u0275\u0275advance();
46618    \u0275\u0275property("ngIf", srcParameterChildDefinition_r18.type === ctx_r1.ATTRIBUTE_TYPE.BOOLEAN);
46619  }
46620}
46621function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_Template(rf, ctx) {
46622  if (rf & 1) {
46623    const _r15 = \u0275\u0275getCurrentView();
46624    \u0275\u0275elementStart(0, "div")(1, "div", 40);
46625    \u0275\u0275listener("click", function DoraConfiguratorComponent_div_0_div_12_div_14_div_3_Template_div_click_1_listener() {
46626      const srcParameterChild_r16 = \u0275\u0275restoreView(_r15).$implicit;
46627      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46628      const ctx_r1 = \u0275\u0275nextContext(2);
46629      return \u0275\u0275resetView(ctx_r1.onArrayRemove(srcParameter_r3, srcParameterChild_r16.Progressive));
46630    });
46631    \u0275\u0275elementEnd();
46632    \u0275\u0275elementStart(2, "div");
46633    \u0275\u0275text(3);
46634    \u0275\u0275elementEnd();
46635    \u0275\u0275template(4, DoraConfiguratorComponent_div_0_div_12_div_14_div_3_div_4_Template, 10, 9, "div", 9);
46636    \u0275\u0275elementEnd();
46637  }
46638  if (rf & 2) {
46639    const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46640    \u0275\u0275advance(3);
46641    \u0275\u0275textInterpolate1("Numero elementi: ", srcParameter_r3.childrenDefinition.length, "");
46642    \u0275\u0275advance();
46643    \u0275\u0275property("ngForOf", srcParameter_r3.childrenDefinition);
46644  }
46645}
46646function DoraConfiguratorComponent_div_0_div_12_div_14_Template(rf, ctx) {
46647  if (rf & 1) {
46648    const _r14 = \u0275\u0275getCurrentView();
46649    \u0275\u0275elementStart(0, "div", 37)(1, "div")(2, "div", 38);
46650    \u0275\u0275listener("click", function DoraConfiguratorComponent_div_0_div_12_div_14_Template_div_click_2_listener() {
46651      \u0275\u0275restoreView(_r14);
46652      const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46653      const ctx_r1 = \u0275\u0275nextContext(2);
46654      return \u0275\u0275resetView(ctx_r1.onArrayAdd(srcParameter_r3));
46655    });
46656    \u0275\u0275elementEnd();
46657    \u0275\u0275template(3, DoraConfiguratorComponent_div_0_div_12_div_14_div_3_Template, 5, 2, "div", 39);
46658    \u0275\u0275elementEnd()();
46659  }
46660  if (rf & 2) {
46661    const ctx_r24 = \u0275\u0275nextContext();
46662    const srcParameter_r3 = ctx_r24.$implicit;
46663    const parameterIdx_r5 = ctx_r24.index;
46664    const ctx_r1 = \u0275\u0275nextContext(2);
46665    \u0275\u0275advance();
46666    \u0275\u0275classMap(ctx_r1.getAccordionClass("array-parameter-container", parameterIdx_r5));
46667    \u0275\u0275advance(2);
46668    \u0275\u0275property("ngForOf", srcParameter_r3.Children);
46669  }
46670}
46671function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_25_Template(rf, ctx) {
46672  if (rf & 1) {
46673    const _r31 = \u0275\u0275getCurrentView();
46674    \u0275\u0275elementStart(0, "div", 51)(1, "input", 52);
46675    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_25_Template_input_change_1_listener($event) {
46676      \u0275\u0275restoreView(_r31);
46677      const highChartsParameterIdx_r30 = \u0275\u0275nextContext().index;
46678      const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46679      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46680      const ctx_r1 = \u0275\u0275nextContext(2);
46681      return \u0275\u0275resetView(ctx_r1.onHighChartsParameterIdxChanged($event, srcParameter_r3, srcParameterChild_r28, highChartsParameterIdx_r30));
46682    });
46683    \u0275\u0275elementEnd()();
46684  }
46685  if (rf & 2) {
46686    const highChartsParameter_r32 = \u0275\u0275nextContext().$implicit;
46687    \u0275\u0275advance();
46688    \u0275\u0275property("value", highChartsParameter_r32.Idx);
46689  }
46690}
46691function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_option_28_Template(rf, ctx) {
46692  if (rf & 1) {
46693    \u0275\u0275elementStart(0, "option", 31);
46694    \u0275\u0275text(1);
46695    \u0275\u0275elementEnd();
46696  }
46697  if (rf & 2) {
46698    const option_r33 = ctx.$implicit;
46699    const highChartsParameter_r32 = \u0275\u0275nextContext().$implicit;
46700    \u0275\u0275property("value", option_r33)("selected", option_r33 === highChartsParameter_r32.Name);
46701    \u0275\u0275advance();
46702    \u0275\u0275textInterpolate(option_r33);
46703  }
46704}
46705function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_1_Template(rf, ctx) {
46706  if (rf & 1) {
46707    const _r34 = \u0275\u0275getCurrentView();
46708    \u0275\u0275elementStart(0, "input", 58);
46709    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_1_Template_input_change_0_listener($event) {
46710      \u0275\u0275restoreView(_r34);
46711      const highChartsParameterIdx_r30 = \u0275\u0275nextContext(2).index;
46712      const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46713      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46714      const ctx_r1 = \u0275\u0275nextContext(2);
46715      return \u0275\u0275resetView(ctx_r1.onHighChartsParameterValueChanged($event, srcParameter_r3, srcParameterChild_r28, highChartsParameterIdx_r30));
46716    });
46717    \u0275\u0275elementEnd();
46718  }
46719  if (rf & 2) {
46720    const highChartsParameter_r32 = \u0275\u0275nextContext(2).$implicit;
46721    \u0275\u0275property("value", highChartsParameter_r32.Value);
46722  }
46723}
46724function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_2_Template(rf, ctx) {
46725  if (rf & 1) {
46726    const _r35 = \u0275\u0275getCurrentView();
46727    \u0275\u0275elementStart(0, "input", 59);
46728    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_2_Template_input_change_0_listener($event) {
46729      \u0275\u0275restoreView(_r35);
46730      const highChartsParameterIdx_r30 = \u0275\u0275nextContext(2).index;
46731      const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46732      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46733      const ctx_r1 = \u0275\u0275nextContext(2);
46734      return \u0275\u0275resetView(ctx_r1.onHighChartsParameterValueChanged($event, srcParameter_r3, srcParameterChild_r28, highChartsParameterIdx_r30));
46735    });
46736    \u0275\u0275elementEnd();
46737  }
46738  if (rf & 2) {
46739    const highChartsParameter_r32 = \u0275\u0275nextContext(2).$implicit;
46740    \u0275\u0275property("value", highChartsParameter_r32.Value);
46741  }
46742}
46743function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_3_Template(rf, ctx) {
46744  if (rf & 1) {
46745    const _r36 = \u0275\u0275getCurrentView();
46746    \u0275\u0275elementStart(0, "input", 52);
46747    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_3_Template_input_change_0_listener($event) {
46748      \u0275\u0275restoreView(_r36);
46749      const highChartsParameterIdx_r30 = \u0275\u0275nextContext(2).index;
46750      const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46751      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46752      const ctx_r1 = \u0275\u0275nextContext(2);
46753      return \u0275\u0275resetView(ctx_r1.onHighChartsParameterValueChanged($event, srcParameter_r3, srcParameterChild_r28, highChartsParameterIdx_r30));
46754    });
46755    \u0275\u0275elementEnd();
46756  }
46757  if (rf & 2) {
46758    const highChartsParameter_r32 = \u0275\u0275nextContext(2).$implicit;
46759    \u0275\u0275property("value", highChartsParameter_r32.Value);
46760  }
46761}
46762function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_4_Template(rf, ctx) {
46763  if (rf & 1) {
46764    const _r37 = \u0275\u0275getCurrentView();
46765    \u0275\u0275elementStart(0, "input", 60);
46766    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_4_Template_input_change_0_listener($event) {
46767      \u0275\u0275restoreView(_r37);
46768      const highChartsParameterIdx_r30 = \u0275\u0275nextContext(2).index;
46769      const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46770      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46771      const ctx_r1 = \u0275\u0275nextContext(2);
46772      return \u0275\u0275resetView(ctx_r1.onHighChartsParameterValueChanged($event, srcParameter_r3, srcParameterChild_r28, highChartsParameterIdx_r30));
46773    });
46774    \u0275\u0275elementEnd();
46775  }
46776  if (rf & 2) {
46777    const highChartsParameter_r32 = \u0275\u0275nextContext(2).$implicit;
46778    \u0275\u0275property("checked", highChartsParameter_r32.ValueBoolean);
46779  }
46780}
46781function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_5_Template(rf, ctx) {
46782  if (rf & 1) {
46783    const _r38 = \u0275\u0275getCurrentView();
46784    \u0275\u0275elementStart(0, "input", 61);
46785    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_5_Template_input_change_0_listener($event) {
46786      \u0275\u0275restoreView(_r38);
46787      const highChartsParameterIdx_r30 = \u0275\u0275nextContext(2).index;
46788      const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46789      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46790      const ctx_r1 = \u0275\u0275nextContext(2);
46791      return \u0275\u0275resetView(ctx_r1.onHighChartsParameterValueChanged($event, srcParameter_r3, srcParameterChild_r28, highChartsParameterIdx_r30));
46792    });
46793    \u0275\u0275elementEnd();
46794  }
46795  if (rf & 2) {
46796    const highChartsParameter_r32 = \u0275\u0275nextContext(2).$implicit;
46797    \u0275\u0275property("checked", highChartsParameter_r32.ValueBoolean);
46798  }
46799}
46800function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_Template(rf, ctx) {
46801  if (rf & 1) {
46802    \u0275\u0275elementStart(0, "div");
46803    \u0275\u0275template(1, DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_1_Template, 1, 1, "input", 53)(2, DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_2_Template, 1, 1, "input", 54)(3, DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_3_Template, 1, 1, "input", 55)(4, DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_4_Template, 1, 1, "input", 56)(5, DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_input_5_Template, 1, 1, "input", 57);
46804    \u0275\u0275elementEnd();
46805  }
46806  if (rf & 2) {
46807    const highChartsParameter_r32 = \u0275\u0275nextContext().$implicit;
46808    const ctx_r1 = \u0275\u0275nextContext(5);
46809    \u0275\u0275advance();
46810    \u0275\u0275property("ngIf", highChartsParameter_r32.Type === ctx_r1.ATTRIBUTE_TYPE.STRING);
46811    \u0275\u0275advance();
46812    \u0275\u0275property("ngIf", highChartsParameter_r32.Type === ctx_r1.ATTRIBUTE_TYPE.FLOAT);
46813    \u0275\u0275advance();
46814    \u0275\u0275property("ngIf", highChartsParameter_r32.Type === ctx_r1.ATTRIBUTE_TYPE.INTEGER);
46815    \u0275\u0275advance();
46816    \u0275\u0275property("ngIf", highChartsParameter_r32.Type === ctx_r1.ATTRIBUTE_TYPE.BOOLEAN);
46817    \u0275\u0275advance();
46818    \u0275\u0275property("ngIf", highChartsParameter_r32.Type === ctx_r1.ATTRIBUTE_TYPE.COLOR);
46819  }
46820}
46821function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_Template(rf, ctx) {
46822  if (rf & 1) {
46823    const _r29 = \u0275\u0275getCurrentView();
46824    \u0275\u0275elementStart(0, "div", 44);
46825    \u0275\u0275element(1, "div", 45);
46826    \u0275\u0275elementStart(2, "table")(3, "thead")(4, "tr")(5, "th")(6, "div", 46);
46827    \u0275\u0275listener("mouseenter", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_Template_div_mouseenter_6_listener() {
46828      const highChartsParameterIdx_r30 = \u0275\u0275restoreView(_r29).index;
46829      const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46830      const ctx_r1 = \u0275\u0275nextContext(4);
46831      return \u0275\u0275resetView(ctx_r1.setTooltipClass("idx-" + ctx_r1.buildHighChartsParameterCssClassUID(srcParameterChild_r28, highChartsParameterIdx_r30), true));
46832    })("mouseleave", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_Template_div_mouseleave_6_listener() {
46833      const highChartsParameterIdx_r30 = \u0275\u0275restoreView(_r29).index;
46834      const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46835      const ctx_r1 = \u0275\u0275nextContext(4);
46836      return \u0275\u0275resetView(ctx_r1.setTooltipClass("idx-" + ctx_r1.buildHighChartsParameterCssClassUID(srcParameterChild_r28, highChartsParameterIdx_r30), false));
46837    });
46838    \u0275\u0275text(7, " Idx");
46839    \u0275\u0275elementEnd();
46840    \u0275\u0275elementStart(8, "div", 47)(9, "div");
46841    \u0275\u0275text(10, " Presente solo per parametri multipli. Indicare elemento (vuoto lo tratta come non-multiplo) ");
46842    \u0275\u0275elementEnd()()();
46843    \u0275\u0275elementStart(11, "th")(12, "div", 46);
46844    \u0275\u0275listener("mouseenter", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_Template_div_mouseenter_12_listener() {
46845      const highChartsParameterIdx_r30 = \u0275\u0275restoreView(_r29).index;
46846      const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46847      const ctx_r1 = \u0275\u0275nextContext(4);
46848      return \u0275\u0275resetView(ctx_r1.setTooltipClass("name-" + ctx_r1.buildHighChartsParameterCssClassUID(srcParameterChild_r28, highChartsParameterIdx_r30), true));
46849    })("mouseleave", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_Template_div_mouseleave_12_listener() {
46850      const highChartsParameterIdx_r30 = \u0275\u0275restoreView(_r29).index;
46851      const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46852      const ctx_r1 = \u0275\u0275nextContext(4);
46853      return \u0275\u0275resetView(ctx_r1.setTooltipClass("name-" + ctx_r1.buildHighChartsParameterCssClassUID(srcParameterChild_r28, highChartsParameterIdx_r30), false));
46854    });
46855    \u0275\u0275text(13, " Nome");
46856    \u0275\u0275elementEnd();
46857    \u0275\u0275elementStart(14, "div", 47)(15, "div");
46858    \u0275\u0275text(16, " Nome del parametro preso direttamente dalla documentazione di HighCharts ");
46859    \u0275\u0275elementEnd()()();
46860    \u0275\u0275elementStart(17, "th")(18, "div", 46);
46861    \u0275\u0275listener("mouseenter", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_Template_div_mouseenter_18_listener() {
46862      const highChartsParameterIdx_r30 = \u0275\u0275restoreView(_r29).index;
46863      const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46864      const ctx_r1 = \u0275\u0275nextContext(4);
46865      return \u0275\u0275resetView(ctx_r1.setTooltipClass("value-" + ctx_r1.buildHighChartsParameterCssClassUID(srcParameterChild_r28, highChartsParameterIdx_r30), true));
46866    })("mouseleave", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_Template_div_mouseleave_18_listener() {
46867      const highChartsParameterIdx_r30 = \u0275\u0275restoreView(_r29).index;
46868      const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46869      const ctx_r1 = \u0275\u0275nextContext(4);
46870      return \u0275\u0275resetView(ctx_r1.setTooltipClass("value-" + ctx_r1.buildHighChartsParameterCssClassUID(srcParameterChild_r28, highChartsParameterIdx_r30), false));
46871    });
46872    \u0275\u0275text(19, " Valore");
46873    \u0275\u0275elementEnd();
46874    \u0275\u0275elementStart(20, "div", 47)(21, "div");
46875    \u0275\u0275text(22, " Valore del parametro. Solo per parametri foglia ");
46876    \u0275\u0275elementEnd()()()()();
46877    \u0275\u0275elementStart(23, "tr")(24, "td");
46878    \u0275\u0275template(25, DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_25_Template, 2, 1, "div", 48);
46879    \u0275\u0275elementEnd();
46880    \u0275\u0275elementStart(26, "td")(27, "select", 49);
46881    \u0275\u0275listener("change", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_Template_select_change_27_listener($event) {
46882      const highChartsParameterIdx_r30 = \u0275\u0275restoreView(_r29).index;
46883      const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46884      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46885      const ctx_r1 = \u0275\u0275nextContext(2);
46886      return \u0275\u0275resetView(ctx_r1.onHighChartsParameterSelectChanged($event, srcParameter_r3, srcParameterChild_r28, highChartsParameterIdx_r30));
46887    });
46888    \u0275\u0275template(28, DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_option_28_Template, 2, 3, "option", 30);
46889    \u0275\u0275elementEnd()();
46890    \u0275\u0275elementStart(29, "td");
46891    \u0275\u0275template(30, DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_div_30_Template, 6, 5, "div", 50);
46892    \u0275\u0275elementEnd()()()();
46893  }
46894  if (rf & 2) {
46895    const highChartsParameter_r32 = ctx.$implicit;
46896    const highChartsParameterIdx_r30 = ctx.index;
46897    const srcParameterChild_r28 = \u0275\u0275nextContext().$implicit;
46898    const ctx_r1 = \u0275\u0275nextContext(4);
46899    \u0275\u0275advance();
46900    \u0275\u0275property("innerHTML", highChartsParameter_r32.Description, \u0275\u0275sanitizeHtml);
46901    \u0275\u0275advance(8);
46902    \u0275\u0275classMap(ctx_r1.getTooltipClass("idx-" + ctx_r1.buildHighCh
46902artsParameterCssClassUID(srcParameterChild_r28, highChartsParameterIdx_r30)));
46903    \u0275\u0275advance(6);
46904    \u0275\u0275classMap(ctx_r1.getTooltipClass("name-" + ctx_r1.buildHighChartsParameterCssClassUID(srcParameterChild_r28, highChartsParameterIdx_r30)));
46905    \u0275\u0275advance(6);
46906    \u0275\u0275classMap(ctx_r1.getTooltipClass("value-" + ctx_r1.buildHighChartsParameterCssClassUID(srcParameterChild_r28, highChartsParameterIdx_r30)));
46907    \u0275\u0275advance(4);
46908    \u0275\u0275property("ngIf", highChartsParameter_r32.isMultiple);
46909    \u0275\u0275advance(3);
46910    \u0275\u0275property("ngForOf", highChartsParameter_r32.Options);
46911    \u0275\u0275advance(2);
46912    \u0275\u0275property("ngIf", highChartsParameter_r32.IsLeaf);
46913  }
46914}
46915function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_Template(rf, ctx) {
46916  if (rf & 1) {
46917    const _r27 = \u0275\u0275getCurrentView();
46918    \u0275\u0275elementStart(0, "div", 42)(1, "div", 40);
46919    \u0275\u0275listener("click", function DoraConfiguratorComponent_div_0_div_12_div_15_div_3_Template_div_click_1_listener() {
46920      const srcParameterChild_r28 = \u0275\u0275restoreView(_r27).$implicit;
46921      const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46922      const ctx_r1 = \u0275\u0275nextContext(2);
46923      return \u0275\u0275resetView(ctx_r1.onArrayRemove(srcParameter_r3, srcParameterChild_r28.Progressive));
46924    });
46925    \u0275\u0275elementEnd();
46926    \u0275\u0275elementStart(2, "div");
46927    \u0275\u0275text(3);
46928    \u0275\u0275elementEnd();
46929    \u0275\u0275template(4, DoraConfiguratorComponent_div_0_div_12_div_15_div_3_div_4_Template, 31, 10, "div", 43);
46930    \u0275\u0275elementEnd();
46931  }
46932  if (rf & 2) {
46933    const srcParameterChild_r28 = ctx.$implicit;
46934    const srcParameter_r3 = \u0275\u0275nextContext(2).$implicit;
46935    const ctx_r1 = \u0275\u0275nextContext(2);
46936    \u0275\u0275advance(3);
46937    \u0275\u0275textInterpolate(ctx_r1.getChartOptionPath(srcParameter_r3, srcParameterChild_r28));
46938    \u0275\u0275advance();
46939    \u0275\u0275property("ngForOf", ctx_r1.getHighChartsParameters(srcParameter_r3, srcParameterChild_r28).HighChartsParameterList);
46940  }
46941}
46942function DoraConfiguratorComponent_div_0_div_12_div_15_Template(rf, ctx) {
46943  if (rf & 1) {
46944    const _r26 = \u0275\u0275getCurrentView();
46945    \u0275\u0275elementStart(0, "div", 37)(1, "div")(2, "div", 38);
46946    \u0275\u0275listener("click", function DoraConfiguratorComponent_div_0_div_12_div_15_Template_div_click_2_listener() {
46947      \u0275\u0275restoreView(_r26);
46948      const srcParameter_r3 = \u0275\u0275nextContext().$implicit;
46949      const ctx_r1 = \u0275\u0275nextContext(2);
46950      return \u0275\u0275resetView(ctx_r1.onArrayAdd(srcParameter_r3));
46951    });
46952    \u0275\u0275elementEnd();
46953    \u0275\u0275template(3, DoraConfiguratorComponent_div_0_div_12_div_15_div_3_Template, 5, 2, "div", 41);
46954    \u0275\u0275elementEnd()();
46955  }
46956  if (rf & 2) {
46957    const ctx_r24 = \u0275\u0275nextContext();
46958    const srcParameter_r3 = ctx_r24.$implicit;
46959    const parameterIdx_r5 = ctx_r24.index;
46960    const ctx_r1 = \u0275\u0275nextContext(2);
46961    \u0275\u0275advance();
46962    \u0275\u0275classMap(ctx_r1.getAccordionClass("array-parameter-container", parameterIdx_r5));
46963    \u0275\u0275advance(2);
46964    \u0275\u0275property("ngForOf", srcParameter_r3.Children);
46965  }
46966}
46967function DoraConfiguratorComponent_div_0_div_12_Template(rf, ctx) {
46968  if (rf & 1) {
46969    \u0275\u0275elementStart(0, "div", 10);
46970    \u0275\u0275element(1, "div", 11)(2, "div", 12);
46971    \u0275\u0275template(3, DoraConfiguratorComponent_div_0_div_12_div_3_Template, 1, 1, "div", 13);
46972    \u0275\u0275elementStart(4, "div", 14);
46973    \u0275\u0275template(5, DoraConfiguratorComponent_div_0_div_12_div_5_Template, 1, 2, "div", 15)(6, DoraConfiguratorComponent_div_0_div_12_div_6_Template, 1, 1, "div", 16)(7, DoraConfiguratorComponent_div_0_div_12_div_7_Template, 1, 1, "div", 17);
46974    \u0275\u0275elementEnd();
46975    \u0275\u0275template(8, DoraConfiguratorComponent_div_0_div_12_select_8_Template, 2, 2, "select", 18)(9, DoraConfiguratorComponent_div_0_div_12_input_9_Template, 1, 1, "input", 19)(10, DoraConfiguratorComponent_div_0_div_12_input_10_Template, 1, 1, "input", 20)(11, DoraConfiguratorComponent_div_0_div_12_input_11_Template, 1, 1, "input", 21)(12, DoraConfiguratorComponent_div_0_div_12_input_12_Template, 1, 1, "input", 22)(13, DoraConfiguratorComponent_div_0_div_12_input_13_Template, 1, 1, "input", 23)(14, DoraConfiguratorComponent_div_0_div_12_div_14_Template, 4, 3, "div", 24)(15, DoraConfiguratorComponent_div_0_div_12_div_15_Template, 4, 3, "div", 24);
46976    \u0275\u0275elementEnd();
46977  }
46978  if (rf & 2) {
46979    const srcParameter_r3 = ctx.$implicit;
46980    const ctx_r1 = \u0275\u0275nextContext(2);
46981    \u0275\u0275advance();
46982    \u0275\u0275property("innerHTML", srcParameter_r3.name, \u0275\u0275sanitizeHtml);
46983    \u0275\u0275advance();
46984    \u0275\u0275property("innerHTML", srcParameter_r3.descr, \u0275\u0275sanitizeHtml);
46985    \u0275\u0275advance();
46986    \u0275\u0275property("ngIf", srcParameter_r3.type !== ctx_r1.ATTRIBUTE_TYPE.ARRAY && srcParameter_r3.type !== ctx_r1.ATTRIBUTE_TYPE.HIGHCHARTOPTIONS);
46987    \u0275\u0275advance(2);
46988    \u0275\u0275property("ngIf", srcParameter_r3.type === ctx_r1.ATTRIBUTE_TYPE.HIGHCHARTOPTIONS || srcParameter_r3.type === ctx_r1.ATTRIBUTE_TYPE.ARRAY);
46989    \u0275\u0275advance();
46990    \u0275\u0275property("ngIf", srcParameter_r3.type === ctx_r1.ATTRIBUTE_TYPE.HIGHCHARTOPTIONS || srcParameter_r3.type === ctx_r1.ATTRIBUTE_TYPE.ARRAY);
46991    \u0275\u0275advance();
46992    \u0275\u0275property("ngIf", srcParameter_r3.type !== ctx_r1.ATTRIBUTE_TYPE.HIGHCHARTOPTIONS && srcParameter_r3.type !== ctx_r1.ATTRIBUTE_TYPE.ARRAY);
46993    \u0275\u0275advance();
46994    \u0275\u0275property("ngIf", srcParameter_r3.type === ctx_r1.ATTRIBUTE_TYPE.STRING && srcParameter_r3.values.length > 0);
46995    \u0275\u0275advance();
46996    \u0275\u0275property("ngIf", srcParameter_r3.type === ctx_r1.ATTRIBUTE_TYPE.STRING && srcParameter_r3.values.length === 0);
46997    \u0275\u0275advance();
46998    \u0275\u0275property("ngIf", srcParameter_r3.type === ctx_r1.ATTRIBUTE_TYPE.COLOR);
46999    \u0275\u0275advance();
47000    \u0275\u0275property("ngIf", srcParameter_r3.type === ctx_r1.ATTRIBUTE_TYPE.INTEGER
47000);
47001    \u0275\u0275advance();
47002    \u0275\u0275property("ngIf", srcParameter_r3.type === ctx_r1.ATTRIBUTE_TYPE.FLOAT);
47003    \u0275\u0275advance();
47004    \u0275\u0275property("ngIf", srcParameter_r3.type === ctx_r1.ATTRIBUTE_TYPE.BOOLEAN);
47005    \u0275\u0275advance();
47006    \u0275\u0275property("ngIf", srcParameter_r3.type === ctx_r1.ATTRIBUTE_TYPE.ARRAY);
47007    \u0275\u0275advance();
47008    \u0275\u0275property("ngIf", srcParameter_r3.type === ctx_r1.ATTRIBUTE_TYPE.HIGHCHARTOPTIONS);
47009  }
47010}
47011function DoraConfiguratorComponent_div_0_Template(rf, ctx) {
47012  if (rf & 1) {
47013    const _r1 = \u0275\u0275getCurrentView();
47014    \u0275\u0275elementStart(0, "div", 2, 0)(2, "div", 3);
47015    \u0275\u0275listener("click", function DoraConfiguratorComponent_div_0_Template_div_click_2_listener($event) {
47016      \u0275\u0275restoreView(_r1);
47017      return \u0275\u0275resetView($event.stopPropagation());
47018    });
47019    \u0275\u0275elementStart(3, "div", 4);
47020    \u0275\u0275listener("mousedown", function DoraConfiguratorComponent_div_0_Template_div_mousedown_3_listener($event) {
47021      \u0275\u0275restoreView(_r1);
47022      const ctx_r1 = \u0275\u0275nextContext();
47023      return \u0275\u0275resetView(ctx_r1.onMouseDown($event));
47024    });
47025    \u0275\u0275elementStart(4, "div")(5, "h2");
47026    \u0275\u0275text(6);
47027    \u0275\u0275elementEnd()();
47028    \u0275\u0275elementStart(7, "div", 5);
47029    \u0275\u0275listener("click", function DoraConfiguratorComponent_div_0_Template_div_click_7_listener() {
47030      \u0275\u0275restoreView(_r1);
47031      const ctx_r1 = \u0275\u0275nextContext();
47032      return \u0275\u0275resetView(ctx_r1.onSubmit());
47033    });
47034    \u0275\u0275elementEnd();
47035    \u0275\u0275elementStart(8, "div", 6);
47036    \u0275\u0275listener("click", function DoraConfiguratorComponent_div_0_Template_div_click_8_listener() {
47037      \u0275\u0275restoreView(_r1);
47038      const ctx_r1 = \u0275\u0275nextContext();
47039      return \u0275\u0275resetView(ctx_r1.onClose());
47040    });
47041    \u0275\u0275text(9, "X");
47042    \u0275\u0275elementEnd()();
47043    \u0275\u0275elementStart(10, "div", 7)(11, "form", 8);
47044    \u0275\u0275listener("ngSubmit", function DoraConfiguratorComponent_div_0_Template_form_ngSubmit_11_listener() {
47045      \u0275\u0275restoreView(_r1);
47046      const ctx_r1 = \u0275\u0275nextContext();
47047      return \u0275\u0275resetView(ctx_r1.onSubmit());
47048    });
47049    \u0275\u0275template(12, DoraConfiguratorComponent_div_0_div_12_Template, 16, 14, "div", 9);
47050    \u0275\u0275elementEnd()()()();
47051  }
47052  if (rf & 2) {
47053    const ctx_r1 = \u0275\u0275nextContext();
47054    \u0275\u0275advance(6);
47055    \u0275\u0275textInterpolate(ctx_r1.title);
47056    \u0275\u0275advance(5);
47057    \u0275\u0275property("formGroup", ctx_r1.editingForm);
47058    \u0275\u0275advance();
47059    \u0275\u0275property("ngForOf", ctx_r1.editingParameters);
47060  }
47061}
47062var DoraConfiguratorComponent = class _DoraConfiguratorComponent extends WidgetBaseComponent {
47063  constructor(elementRef, messageService, configurationService, publisher, widgetService, http, translationService, renderer) {
47064    super(elementRef, messageService, configurationService, publisher, widgetService, http, translationService);
47065    this.elementRef = elementRef;
47066    this.messageService = messageService;
47067    this.configurationService = configurationService;
47068    this.publisher = publisher;
47069    this.widgetService = widgetService;
47070    this.http = http;
47071    this.translationService = translationService;
47072    this.renderer = renderer;
47073    this.widgetSrcName = "";
47074    this.editingFormEnabled = false;
47075    this.editingParameters = [];
47076    this.title = "Configuratore";
47077    this.isDragging = false;
47078    this.currentX = 0;
47079    this.currentY = 0;
47080    this.initialX = 0;
47081    this.initialY = 0;
47082    this.xOffset = 0;
47083    this.yOffset = 0;
47084    this.accordionStatus = new EnabledObject(false);
47085    this.tooltipStatus = new EnabledObject(false);
47086    this.ATTRIBUTE_TYPE = ATTRIBUTE_TYPE;
47087    this.editingForm = new FormGroup({});
47088  }
47089  onParameterInjectedFinished() {
47090    super.onParameterInjectedFinished();
47091    this.srcWidget = this.widgetService.getWidget(this.widgetSrcName);
47092    if (this.srcWidget === void 0) {
47093      console.error("Widget [" + this.widgetSrcName + "] not found !");
47094      return;
47095    }
47096    this.title = this.srcWidget.widgetName + " - Configuratore";
47097    this.addControlsToForm();
47098    console.log("onParameterInjectedFinished");
47099  }
47100  ngAfterViewInit() {
47101    if (this.dialogContainer !== void 0) {
47102      this.renderer.setStyle(this.dialogContainer.nativeElement, "transform", `translate3d(${this.currentX}px, ${this.currentY}px, 0)`);
47103    }
47104  }
47105  ngAfterViewChecked() {
47106    if (this.dialogContainer !== void 0) {
47107      this.renderer.setStyle(this.dialogContainer.nativeElement, "transform", `translate3d(${this.currentX}px, ${this.currentY}px, 0)`);
47108    }
47109  }
47110  // region Form operations
47111  onSubmit() {
47112    let serializedAttributes = {};
47113    this.editingParameters.forEach((parameter) => {
47114      serializedAttributes[parameter.name] = parameter.serialize(this.srcWidget[parameter.name]);
47115    });
47116    if (this.srcWidget instanceof WidgetBaseComponent) {
47117      console.info("Save configuration");
47118      console.info("Widget: " + this.srcWidget.ExternalTagSelector);
47119      console.info("Progressive: " + this.srcWidget["progressive"]);
47120      console.info(serializedAttributes);
47121      DoraWidgetConfigurationChanged(this.srcWidget.ExternalTagSelector, this.srcWidget["progressive"], serializedAttributes);
47122    }
47123  }
47124  addControlsToForm() {
47125    const parameters = this.getEditAttributes();
47126    parameters.forEach((parameter) => {
47127      if (parameter.isMultiple()) {
47128        this.srcWidget[parameter.name].forEach((instance) => {
47129          const srcParameterChild = parameter.addChild(instance);
47130          if (srcParameterChild === void 0) {
47131            return;
47132          }
47133          parameter.childrenDefinition.forEach((child) => {
47134            this.editingForm.addControl(parameter.name + "." + child.name + "." + srcParameterChild.ProgressiveStr, new FormControl(instance[child.name]));
47135          });
47136        });
47137      } else {
47138        this.editingForm.addControl(parameter.name, new FormControl(this.srcWidget[parameter.name]));
47139      }
47140    });
47141    this.editingParameters = parameters;
47142    this.editingFormEnabled = true;
47143  }
47144  getWigetSrcName() {
47145    return this.widgetSrcName;
47146  }
47147  setEditingFormEnabled(status) {
47148    this.editingFormEnabled = status;
47149    this.addControlsToForm();
47150  }
47151  getEditControlValue(name) {
47152    const srcParameter = this.editingParameters.find((value) => value.name === name);
47153    if (srcParameter !== void 0 && srcParameter.type !== ATTRIBUTE_TYPE.ARRAY) {
47154      return this.srcWidget[name];
47155    }
47156    return "undefined";
47157  }
47158  getArrayAttribute(name) {
47159    const result = this.srcWidget[name];
47160    return result;
47161  }
47162  getEditAttributes() {
47163    const parameters = this.configurationService.getParameterFromSource(this.srcWidget, true);
47164    this.publisherParameters = [];
47165    if (this.srcWidget instanceof WidgetBaseComponent) {
47166      this.publisherParameters.push(...this.srcWidget.PublisherParameters);
47167    }
47168    parameters.forEach((parameter) => {
47169      switch (parameter.dataProviderValueType) {
47170        case ATTRIBUTE_DATAPROVIDER_VALUES.TABLE_LIST:
47171          this.read([], DataType.META_LIST_GRIDS).subscribe((data) => {
47172            parameter.values = data.Data;
47173          });
47174      }
47175    });
47176    return parameters;
47177  }
47178  onValueChange($event, name, chartOptions = []) {
47179    const srcParameter = this.editingParameters.find((value) => value.name === name);
47180    if (srcParameter === void 0) {
47181      return;
47182    }
47183    "";
47184    switch (srcParameter.type) {
47185      case ATTRIBUTE_TYPE.STRING:
47186      case ATTRIBUTE_TYPE.COLOR:
47187        this.srcWidget[name] = $event.target.value;
47188        break;
47189      case ATTRIBUTE_TYPE.INTEGER:
47190      case ATTRIBUTE_TYPE.FLOAT:
47191        this.srcWidget[name] = Number($event.target.value);
47192        break;
47193      case ATTRIBUTE_TYPE.BOOLEAN:
47194        this.srcWidget[name] = $event.target.checked;
47195        break;
47196      case ATTRIBUTE_TYPE.HIGHCHARTOPTIONS:
47197        this.srcWidget[name] = chartOptions;
47198        break;
47199      default:
47200        console.error("Type not managed");
47201    }
47202    this.srcWidget.onRefresh();
47203  }
47204  /**
47205   * Manage array value change
47206   * @param $event
47207   * @param srcParameter
47208   * @param srcParameterChildDefinition
47209   * @param srcParameterChild
47210   * @protected
47211   */
47212  onValueChangeArray($event, srcParameter, srcParameterChildDefinition, srcParameterChild) {
47213    const idx = srcParameter.getChildIdx(srcParameterChild.Progressive);
47214    if (idx < 0) {
47215      console.warn("Progressive not found " + srcParameterChild.Progressive + " in " + srcParameter.name);
47216      return;
47217    }
47218    switch (srcParameterChildDefinition.type) {
47219      case ATTRIBUTE_TYPE.STRING:
47220      case ATTRIBUTE_TYPE.COLOR:
47221        this.srcWidget[srcParameter.name][idx][srcParameterChildDefinition.name] = $event.target.value;
47222        break;
47223      case ATTRIBUTE_TYPE.INTEGER:
47224      case ATTRIBUTE_TYPE.FLOAT:
47225        this.srcWidget[srcParameter.name][idx][srcParameterChildDefinition.name] = Number($event.target.value);
47226        break;
47227      case ATTRIBUTE_TYPE.BOOLEAN:
47228        this.srcWidget[srcParameter.name][idx][srcParameterChildDefinition.name] = $event.target.checked;
47229        break;
47230      default:
47231        console.error("Type not managed");
47232    }
47233    this.srcWidget.onRefresh();
47234  }
47235  onMouseDown(event2) {
47236    this.initialX = event2.clientX - this.xOffset;
47237    this.initialY = event2.clientY - this.yOffset;
47238    if (event2.target === this.elementRef.nativeElement.querySelector(".dialog-header")) {
47239      this.isDragging = true;
47240    }
47241    document.onmousemove = this.onMouseMove.bind(this);
47242    document.onmouseup = this.onMouseUp.bind(this);
47243  }
47244  onMouseMove(event2) {
47245    if (this.isDragging) {
47246      event2.preventDefault();
47247      this.currentX = event2.clientX - this.initialX;
47248      this.currentY = event2.clientY - this.initialY;
47249      this.xOffset = this.currentX;
47250      this.yOffset = this.currentY;
47251      this.renderer.setStyle(this.dialogContainer.nativeElement, "transform", `translate3d(${this.currentX}px, ${this.currentY}px, 0)`);
47252    }
47253  }
47254  onMouseUp() {
47255    this.initialX = this.currentX;
47256    this.initialY = this.currentY;
47257    this.isDragging = false;
47258    document.onmousemove = null;
47259    document.onmouseup = null;
47260  }
47261  onArrayAdd(srcParameter) {
47262    const newChild = srcParameter.createChild();
47263    if (newChild === void 0) {
47264      return;
47265    }
47266    this.srcWidget[srcParameter.name].push(newChild.Instance);
47267    const idx = srcParameter.getChildIdx(newChild.Progressive);
47268    if (idx < 0) {
47269      return;
47270    }
47271    srcParameter.childrenDefinition.forEach((child) => {
47272      this.editingForm.addControl(srcParameter.name + "." + child.name + "." + newChild.ProgressiveStr, new FormControl(this.srcWidget[srcParameter.name][idx][child.name]));
47273    });
47274  }
47275  onArrayRemove(srcParameter, progressive) {
47276    const idx = srcParameter.removeChild(progressive);
47277    if (idx < 0) {
47278      return;
47279    }
47280    this.srcWidget[srcParameter.name].splice(idx, 1);
47281    srcParameter.childrenDefinition.forEach((child) => {
47282      this.editingForm.removeControl(srcParameter.name + "." + child.name + "." + progressive);
47283    });
47284    if (srcParameter.type === ATTRIBUTE_TYPE.HIGHCHARTOPTIONS) {
47285      this.onValueChange(void 0, srcParameter.name, srcParameter.toChartOptions());
47286    }
47287  }
47288  /**
47289   * Disable form it instance is still alive
47290   * @protected
47291   */
47292  onClose() {
47293    this.editingFormEnabled = false;
47294  }
47295  getChartOptionPath(srcParameter, srcParameterChild) {
47296    if (!(srcParameterChild.Instance instanceof ChartOption)) {
47297      return "Invalid";
47298    }
47299    const chartOption = srcParameterChild.Instance;
47300    return chartOption.path;
47301  }
47302  getChartOptionDescription(srcParameter, srcParameterChild) {
47303    if (!(srcParameterChild.Instance instanceof ChartOption)) {
47304      return "Invalid";
47305    }
47306    const chartOption = srcParameterChild.Instance;
47307    const HighChartsParameters2 = srcParameterChild.getHighChartsParameters(this.configurationService.HighChartDoc);
47308    return "test";
47309  }
47310  getHighChartsParameters(srcParameter, srcParameterChild) {
47311    if (!(srcParameterChild.Instance instanceof ChartOption)) {
47312      return new HighChartsParameters();
47313    }
47314    const chartOption = srcParameterChild.Instance;
47315    const highChartsParameters = srcParameterChild.getHighChartsParameters(this.configurationService.HighChartDoc);
47316    return highChartsParameters;
47317  }
47318  onHighChartsParameterSelectChanged($event, srcParameter, srcParameterChild, highChartsParameterIdx) {
47319    const highChartsParameters = srcParameterChild.getHighChartsParameters(this.configurationService.HighChartDoc);
47320    highChartsParameters.selectParameter(this.configurationService.HighChartDoc, highChartsParameterIdx, $event.target.value);
47321    console.debug("onHighChartsParameterChanged: " + $event.target.value);
47322  }
47323  onHighChartsParameterValueChanged($event, srcParameter, srcParameterChild, highChartsParameterIdx) {
47324    const highChartsParameters = srcParameterChild.getHighChartsParameters(this.configurationService.HighChartDoc);
47325    let value = $event.target.value;
47326    switch ($event.target.type) {
47327      case "checkbox":
47328        value = $event.target.checked ? "true" : "false";
47329        break;
47330    }
47331    highChartsParameters.setParameterValue(highChartsParameterIdx, value);
47332    this.setHighchartParameterValue($event, srcParameter);
47333  }
47334  /**
47335   * Build UID for css class for highcharts parameter
47336   * @param srcParameterChild
47337   * @param highChartsParameterIdx
47338   * @protected
47339   */
47340  buildHighChartsParameterCssClassUID(srcParameterChild, highChartsParameterIdx) {
47341    let result = srcParameterChild.DocRoot + "-" + srcParameterChild.getHighChartsParameters(this.configurationService.HighChartDoc).HighChartsParameterList[highChartsParameterIdx].Name;
47342    return result;
47343  }
47344  onHighChartsParameterIdxChanged($event, srcParameter, srcParameterChild, highChartsParameterIdx) {
47345    const highChartsParameters = srcParameterChild.getHighChartsParameters(this.configurationService.HighChartDoc);
47346    let value = $event.target.valueAsNumber;
47347    highChartsParameters.setParameterIdx(highChartsParameterIdx, value);
47348  }
47349  setHighchartParameterValue($event, srcParameter) {
47350    let chartOptions = srcParameter.toChartOptions();
47351    this.onValueChange($event, srcParameter.name, chartOptions);
47352    console.debug("setHighchartParameterValue");
47353  }
47354  // region Accordion
47355  getAccordionClass(className, parameterIdx) {
47356    const key = className + parameterIdx;
47357    return this.accordionStatus.getStatus(key) ? "accordion-show" : "accordion-hide";
47358  }
47359  getAccordionStatusClass(className, parameterIdx) {
47360    const key = className + parameterIdx;
47361    return this.accordionStatus.getStatus(key) ? "open" : "close";
47362  }
47363  setAccordionClass(className, parameterIdx) {
47364    const key = className + parameterIdx;
47365    this.accordionStatus.invertStatus(key);
47366  }
47367  // endregion
47368  // region Tooltip
47369  getTooltipClass(key) {
47370    return this.tooltipStatus.getStatus(key) ? "tooltip-show" : "tooltip-hide";
47371  }
47372  setTooltipClass(key, value) {
47373    this.tooltipStatus.setStatus(key, value);
47374  }
47375  static {
47376    this.\u0275fac = function DoraConfiguratorComponent_Factory(__ngFactoryType__) {
47377      return new (__ngFactoryType__ || _DoraConfiguratorComponent)(\u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(MessageService), \u0275\u0275directiveInject(ConfigurationService), \u0275\u0275directiveInject(PublisherService), \u0275\u0275directiveInject(WidgetService), \u0275\u0275directiveInject(HttpClient), \u0275\u0275directiveInject(TranslationService), \u0275\u0275directiveInject(Renderer2));
47378    };
47379  }
47380  static {
47381    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraConfiguratorComponent, selectors: [["dora-configurator"]], viewQuery: function DoraConfiguratorComponent_Query(rf, ctx) {
47382      if (rf & 1) {
47383        \u0275\u0275viewQuery(_c02, 5);
47384      }
47385      if (rf & 2) {
47386        let _t;
47387        \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.dialogContainer = _t.first);
47388      }
47389    }, standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["dialogContainer", ""], ["class", "dora-configurator-container", 4, "ngIf"], [1, "dora-configurator-container"], [1, "dialog-container", 3, "click"], [1, "dialog-header", 3, "mousedown"], [1, "dialog-save", 3, "click"], [1, "dialog-close", 3, "click"], [1, "form-container"], [3, "ngSubmit", "formGroup"], ["class", "edit-attribute", "style", "border: 1px solid;", 4, "ngFor", "ngForOf"], [1, "edit-attribute", 2, "border", "1px solid"], [1, "edit-attribute-name", 3, "innerHTML"], [1, "edit-attribute-descr", 3, "innerHTML"], ["class", "edit-attribute-value", 3, "innerHTML", 4, "ngIf"], [1, "expand-container"], [3, "class", "click", 4, "ngIf"], ["class", "cursor-pointer", 3, "innerHTML", "click", 4, "ngIf"], [3, "innerHTML", 4, "ngIf"], [3, "formControlName", "change", 4, "ngIf"], ["type", "text", 3, "formControlName", "change", 4, "ngIf"], ["type", "color", 3, "formControlName", "change", 4, "ngIf"], ["type", "number", 3, "formControlName", "change", 4, "ngIf"], ["type", "number", "step", "0.01", 3, "formControlName", "change", 4, "ngIf"], ["type", "checkbox", 3, "formControlName", "change", 4, "ngIf"], ["class", "edit-attribute-array-container", 4, "ngIf"], [1, "edit-attribute-value", 3, "innerHTML"], [3, "click"], [1, "curs
47389or-pointer", 3, "click", "innerHTML"], [3, "innerHTML"], [3, "change", "formControlName"], [3, "value", "selected", 4, "ngFor", "ngForOf"], [3, "value", "selected"], ["type", "text", 3, "change", "formControlName"], ["type", "color", 3, "change", "formControlName"], ["type", "number", 3, "change", "formControlName"], ["type", "number", "step", "0.01", 3, "change", "formControlName"], ["type", "checkbox", 3, "change", "formControlName"], [1, "edit-attribute-array-container"], [1, "add-command", 3, "click"], [4, "ngFor", "ngForOf"], [1, "remove-command", 3, "click"], ["class", "attribute-highchartoption-element", 4, "ngFor", "ngForOf"], [1, "attribute-highchartoption-element"], ["class", "attribute-highchartoption-sub-element", 4, "ngFor", "ngForOf"], [1, "attribute-highchartoption-sub-element"], [1, "description", 3, "innerHTML"], [3, "mouseenter", "mouseleave"], [1, "tootip-container"], ["class", "attribute-highchartoption-multiple", 4, "ngIf"], ["type", "text", 3, "change"], [4, "ngIf"], [1, "attribute-highchartoption-multiple"], ["type", "number", 3, "change", "value"], ["type", "text", 3, "value", "change", 4, "ngIf"], ["type", "number", "step", "0.01", 3, "value", "change", 4, "ngIf"], ["type", "number", 3, "value", "change", 4, "ngIf"], ["type", "checkbox", 3, "checked", "change", 4, "ngIf"], ["type", "color", 3, "checked", "change", 4, "ngIf"], ["type", "text", 3, "change", "value"], ["type", "number", "step", "0.01", 3, "change", "value"], ["type", "checkbox", 3, "change", "checked"], ["type", "color", 3, "change", "checked"]], template: function DoraConfiguratorComponent_Template(rf, ctx) {
47390      if (rf & 1) {
47391        \u0275\u0275template(0, DoraConfiguratorComponent_div_0_Template, 13, 3, "div", 1);
47392      }
47393      if (rf & 2) {
47394        \u0275\u0275property("ngIf", ctx.editingFormEnabled);
47395      }
47396    }, dependencies: [NgForOf, NgIf, \u0275NgNoValidate, NgSelectOption, \u0275NgSelectMultipleOption, DefaultValueAccessor, NumberValueAccessor, CheckboxControlValueAccessor, SelectControlValueAccessor, NgControlStatus, NgControlStatusGroup, FormGroupDirective, FormControlName], styles: ['@charset "UTF-8";\n\n\n\n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .add-command.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .remove-command.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .accordion-status-close.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .accordion-status-open.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open.accordion-status-close[_ngcontent-%COMP%]:before, \n[data-icon][_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   [data-icon].add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   [data-icon].remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   [data-icon].accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   [data-icon].accordion-status-open[_ngcontent-%COMP%]:before, \n[class^=icon-][_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   [class^=icon-].add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   [class^=icon-].remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   [class^=icon-].accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   [class^=icon-].accordion-status-open[_ngcontent-%COMP%]:before, \n[class*=" icon-"][_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   [class*=" icon-"].add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   [class*=" icon-"].remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   [class*=" icon-"].accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   [class*=" icon-"].accordion-status-open[_ngcontent-%COMP%]:before {\n  font-family: "icons" !important;\n  font-style: normal !important;\n  font-weight: normal !important;\n  font-variant: normal !important;\n  text-transform: none !important;\n  speak: none;\n  line-height: 1;\n  -webkit-font-smoothing: antialiased;\n  -moz-osx-font-smoothing: grayscale;\n}\n@font-face {\n  font-family: "icons";\n  src: url("./media/icons.eot?1");\n  src:\n    url("./media/icons.eot?1#iefix") format("embedded-opentype"),\n    url("./media/icons.woff2?1") format("woff2"),\n    url("./media/icons.woff?1") format("woff"),\n    url("./media/icons.ttf?1") format("truetype"),\n    url("./media/icons.svg?1#icons") format("svg");\n  font-weight: normal;\n  font-style: normal;\n}\n.icon-settings[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-settings.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-settings.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-settings.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-settings.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ng
47396content-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-settings.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-settings.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .icon-settings.dialog-save[_ngcontent-%COMP%]:before {\n  content: "\\f800";\n}\n.icon-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-close.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-close.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-close.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-close.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-close.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-close.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .icon-close.dialog-save[_ngcontent-%COMP%]:before {\n  content: "\\f801";\n}\n.icon-add[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-add.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-add.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-add.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-add.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .add-command.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ng
47396content-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-add.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-add.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .icon-add.dialog-save[_ngcontent-%COMP%]:before {\n  content: "\\f802";\n}\n.icon-remove[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-remove.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-remove.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-remove.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .remove-command.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-remove.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-remove.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-remove.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .icon-remove.dialog-save[_ngcontent-%COMP%]:before {\n  content: "\\f803";\n}\n.icon-reduce[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-reduce.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .accordion-status-open.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-reduce.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-reduce.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-reduce.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ng
47396content-%COMP%]   .expand-container[_ngcontent-%COMP%]   .accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-reduce.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .icon-reduce.dialog-save[_ngcontent-%COMP%]:before {\n  content: "\\f804";\n}\n.icon-expand[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-expand.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-expand.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .accordion-status-close.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-expand.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-expand.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-expand.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .icon-expand.dialog-save[_ngcontent-%COMP%]:before {\n  content: "\\f805";\n}\n.icon-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-save.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-save.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-save.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-save.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ng
47396content-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-save.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-save.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-save.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-save.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-save.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-save.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .dialog-save.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .dialog-save.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save.accordion-status-close[_ngcontent-%COMP%]:before {\n  content: "\\f806";\n}\n.icon-check-off[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-check-off.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-check-off.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-check-off.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-check-off.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ng
47396content-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-check-off.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-check-off.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .icon-check-off.dialog-save[_ngcontent-%COMP%]:before {\n  content: "\\f807";\n}\n.icon-check-on[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-check-on.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-check-on.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-check-on.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .icon-check-on.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-check-on.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .icon-check-on.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .icon-check-on.dialog-save[_ngcontent-%COMP%]:before {\n  content: "\\f808";\n}\n.dora-configurator-container[_ngcontent-%COMP%] {\n  font-family: monospace;\n  max-width: 400px;\n  z-index: 9999;\n  position: fixed;\n  background-color: aliceblue;\n  top: 0;\n  right: 0;\n  border: 5px solid olivedrab;\n  background-color: antiquewhite;\n  padding: 5px;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .cursor-pointer[_ngcontent-%COMP%] {\n  cursor: pointer;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%] {\n  padding: 10px;\n  background-color: #f0f0f0;\n  margin-bottom: 10px;\n  border-top-left-radius: 5px;\n  border-top-right-radius: 5px;\n  cursor: all-scroll;\n  display: flex;\n  gap: 5px;\n  justify-content: space-between;\n  align-items: center;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%] {\n  font-size: medium;\n  cursor: default;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save[_ngcontent-%COMP%], \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-close[_ngcontent-%COMP%] {\n  width: 10px;\n  height: 10px;\n  color: white;\n  cursor: pointer;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save[_ngcontent-%COMP%] {\n  background-color: #2aa55b;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-save.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-save.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-save.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-save.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ng
47396content-%COMP%]   .expand-container[_ngcontent-%COMP%]   .dialog-save.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .dialog-save.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-save.accordion-status-close[_ngcontent-%COMP%]:before {\n  height: auto;\n  line-height: auto;\n  width: auto;\n  font-size: 10px;\n  cursor: pointer;\n  color: black;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .dialog-close[_ngcontent-%COMP%] {\n  background-color: black;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%] {\n  overflow-y: scroll;\n  height: 300px;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%] {\n  display: flex;\n  gap: 8px;\n  flex-direction: column;\n  align-items: flex-start;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%] {\n  display: flex;\n  align-items: center;\n  gap: 5px;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .accordion-status-close[_ngcontent-%COMP%]:before {\n  height: auto;\n  line-height: auto;\n  width: auto;\n  font-size: 10px;\n  cursor: pointer;\n  color: black;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .accordion-status-open[_ngcontent-%COMP%]:before {\n  height: auto;\n  line-height: auto;\n  width: auto;\n  font-size: 10px;\n  cursor: pointer;\n  color: black;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-name[_ngcontent-%COMP%] {\n  font-weight: bold;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .attribute-highchartoption-element[_ngcontent-%COMP%] {\n  border: 1px solid chocolate;\n  margin-left: 10px;\n  background-color: beige;\n  margin-bottom: 5px;\n  display: flex;\n  flex-direction: column;\n  gap: 8px;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .attribute-highchartoption-element[_ngcontent-%COMP%]   .attribute-highchartoption-sub-element[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  gap: 5px;\n  border-top: 1px solid chocolate;\n  padding-top: 5px;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .attribute-highchartoption-element[_ngcontent-%COMP%]   .attribute-highchartoption-sub-element[_ngcontent-%COMP%]   .attribute-highchartoption-multiple[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .attribute-highchartoption-element[_ngcontent-%COMP%]   .attribute-highchartoption-sub-element[_ngcontent-%COMP%]   .attribute-highchartoption-multiple[_ngcontent-%COMP%]   input[_ngcontent-%COMP%] {\n  max-width: 30px;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .attribute-highchartoption-element[_ngcontent-%COMP%]   .attribute-highchartoption-sub-element[_ngcontent-%COMP%]   .tooltip-hide[_ngcontent-%COMP%] {\n  display: none;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .attribute-highchartoption-element[_ngcontent-%COMP%]   .attribute-highchartoption-sub-element[_ngcontent-%COMP%]   .tootip-container[_ngcontent-%COMP%] {\n  position: relative;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .attribute-highchartoption-element[_ngcontent-%COMP%]   .attribute-highchartoption-sub-element[_ngcontent-%COMP%]   .tootip-container[_ngcontent-%COMP%]   .tooltip-show[_ngcontent-%COMP%] {\n  display: block;\n  position: absolute;\n  z-index: 1;\n  width: 200px;\n  background-color: aliceblue;\n  border: 1px solid;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-close[_ngcontent-%COMP%] {\n  cursor: pointer;
47396\n  color: white;\n  width: 15px;\n  height: 15px;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .add-command.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .add-command.dialog-save[_ngcontent-%COMP%]:before {\n  height: auto;\n  line-height: auto;\n  width: auto;\n  font-size: 20px;\n  cursor: pointer;\n  color: olivedrab;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command.accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .remove-command.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .remove-command.add-command[_ngcontent-%COMP%]:before {\n  height: auto;\n  line-height: auto;\n  width: auto;\n  font-size: 20px;\n  cursor: pointer;\n  color: red;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close.accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .accordion-status-close.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .edit-attribute[_ng
47396content-%COMP%]   .expand-container[_ngcontent-%COMP%]   .accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-close.remove-command[_ngcontent-%COMP%]:before {\n  height: auto;\n  line-height: auto;\n  width: auto;\n  font-size: 20px;\n  cursor: pointer;\n  color: black;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .accordion-status-open.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .dialog-header[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open.dialog-save[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute[_ngcontent-%COMP%]   .expand-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open.add-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open.remove-command[_ngcontent-%COMP%]:before, \n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-status-open.accordion-status-close[_ngcontent-%COMP%]:before {\n  height: auto;\n  line-height: auto;\n  width: auto;\n  font-size: 20px;\n  cursor: pointer;\n  color: black;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-show[_ngcontent-%COMP%] {\n  display: block;\n}\n.dora-configurator-container[_ngcontent-%COMP%]   .form-container[_ngcontent-%COMP%]   .edit-attribute-array-container[_ngcontent-%COMP%]   .accordion-hide[_ngcontent-%COMP%] {\n  display: none;\n}'] });
47397  }
47398};
47399__decorate([
47400  DoraPropertyDOC("Widget sorgente da configurare", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE),
47401  DoraProperty,
47402  __metadata("design:type", String)
47403], DoraConfiguratorComponent.prototype, "widgetSrcName", void 0);
47404(() => {
47405  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraConfiguratorComponent, { className: "DoraConfiguratorComponent", filePath: "src/app/dorawidget/dora-configurator/dora-configurator.component.ts", lineNumber: 32 });
47406})();
47407
vendor: 144,306 bytes, lines 47408-51810
47408// node_modules/@ng-select/ng-select/fesm2022/ng-select-ng-select.mjs
47409var _c03 = ["content"];
47410var _c12 = ["scroll"];
47411var _c22 = ["padding"];
47412var _c32 = ["*"];
47413var _c4 = (a0) => ({
47414  searchTerm: a0
47415});
47416function NgDropdownPanelComponent_Conditional_0_Template(rf, ctx) {
47417  if (rf & 1) {
47418    \u0275\u0275elementStart(0, "div", 3);
47419    \u0275\u0275elementContainer(1, 6);
47420    \u0275\u0275elementEnd();
47421  }
47422  if (rf & 2) {
47423    const ctx_r0 = \u0275\u0275nextContext();
47424    \u0275\u0275advance();
47425    \u0275\u0275property("ngTemplateOutlet", ctx_r0.headerTemplate)("ngTemplateOutletContext", \u0275\u0275pureFunction1(2, _c4, ctx_r0.filterValue));
47426  }
47427}
47428function NgDropdownPanelComponent_Conditional_8_Template(rf, ctx) {
47429  if (rf & 1) {
47430    \u0275\u0275elementStart(0, "div", 5);
47431    \u0275\u0275elementContainer(1, 6);
47432    \u0275\u0275elementEnd();
47433  }
47434  if (rf & 2) {
47435    const ctx_r0 = \u0275\u0275nextContext();
47436    \u0275\u0275advance();
47437    \u0275\u0275property("ngTemplateOutlet", ctx_r0.footerTemplate)("ngTemplateOutletContext", \u0275\u0275pureFunction1(2, _c4, ctx_r0.filterValue));
47438  }
47439}
47440var _c5 = ["searchInput"];
47441var _c6 = ["clearButton"];
47442var _c7 = (a0, a1, a2) => ({
47443  item: a0,
47444  clear: a1,
47445  label: a2
47446});
47447var _c8 = (a0, a1) => ({
47448  items: a0,
47449  clear: a1
47450});
47451var _c9 = (a0, a1, a2, a3) => ({
47452  item: a0,
47453  item$: a1,
47454  index: a2,
47455  searchTerm: a3
47456});
47457function NgSelectComponent_Conditional_2_ng_template_0_Template(rf, ctx) {
47458  if (rf & 1) {
47459    \u0275\u0275elementStart(0, "div", 19);
47460    \u0275\u0275text(1);
47461    \u0275\u0275elementEnd();
47462  }
47463  if (rf & 2) {
47464    const ctx_r1 = \u0275\u0275nextContext(2);
47465    \u0275\u0275advance();
47466    \u0275\u0275textInterpolate(ctx_r1.placeholder);
47467  }
47468}
47469function NgSelectComponent_Conditional_2_ng_template_2_Template(rf, ctx) {
47470}
47471function NgSelectComponent_Conditional_2_Template(rf, ctx) {
47472  if (rf & 1) {
47473    \u0275\u0275template(0, NgSelectComponent_Conditional_2_ng_template_0_Template, 2, 1, "ng-template", null, 1, \u0275\u0275templateRefExtractor)(2, NgSelectComponent_Conditional_2_ng_template_2_Template, 0, 0, "ng-template", 18);
47474  }
47475  if (rf & 2) {
47476    const defaultPlaceholderTemplate_r3 = \u0275\u0275reference(1);
47477    const ctx_r1 = \u0275\u0275nextContext();
47478    \u0275\u0275advance(2);
47479    \u0275\u0275property("ngTemplateOutlet", ctx_r1.placeholderTemplate || defaultPlaceholderTemplate_r3);
47480  }
47481}
47482function NgSelectComponent_Conditional_3_For_1_ng_template_1_Template(rf, ctx) {
47483  if (rf & 1) {
47484    const _r4 = \u0275\u0275getCurrentView();
47485    \u0275\u0275elementStart(0, "span", 22);
47486    \u0275\u0275listener("click", function NgSelectComponent_Conditional_3_For_1_ng_template_1_Template_span_click_0_listener() {
47487      \u0275\u0275restoreView(_r4);
47488      const item_r5 = \u0275\u0275nextContext().$implicit;
47489      const ctx_r1 = \u0275\u0275nextContext(2);
47490      return \u0275\u0275resetView(ctx_r1.unselect(item_r5));
47491    });
47492    \u0275\u0275text(1, "\xD7");
47493    \u0275\u0275elementEnd();
47494    \u0275\u0275element(2, "span", 23);
47495  }
47496  if (rf & 2) {
47497    const item_r5 = \u0275\u0275nextContext().$implicit;
47498    const ctx_r1 = \u0275\u0275nextContext(2);
47499    \u0275\u0275advance(2);
47500    \u0275\u0275property("ngItemLabel", item_r5.label)("escape", ctx_r1.escapeHTML);
47501  }
47502}
47503function NgSelectComponent_Conditional_3_For_1_ng_template_3_Template(rf, ctx) {
47504}
47505function NgSelectComponent_Conditional_3_For_1_Template(rf, ctx) {
47506  if (rf & 1) {
47507    \u0275\u0275elementStart(0, "div", 21);
47508    \u0275\u0275template(1, NgSelectComponent_Conditional_3_For_1_ng_template_1_Template, 3, 2, "ng-template", null, 2, \u0275\u0275templateRefExtractor)(3, NgSelectComponent_Conditional_3_For_1_ng_template_3_Template, 0, 0, "ng-template", 12);
47509    \u0275\u0275elementEnd();
47510  }
47511  if (rf & 2) {
47512    const item_r5 = ctx.$implicit;
47513    const defaultLabelTemplate_r6 = \u0275\u0275reference(2);
47514    const ctx_r1 = \u0275\u0275nextContext(2);
47515    \u0275\u0275classProp("ng-value-disabled", item_r5.disabled);
47516    \u0275\u0275advance(3);
47517    \u0275\u0275property("ngTemplateOutlet", ctx_r1.labelTemplate || defaultLabelTemplate_r6)("ngTemplateOutletContext", \u0275\u0275pureFunction3(4, _c7, item_r5.value, ctx_r1.clearItem, item_r5.label));
47518  }
47519}
47520function NgSelectComponent_Conditional_3_Template(rf, ctx) {
47521  if (rf & 1) {
47522    \u0275\u0275repeaterCreate(0, NgSelectComponent_Conditional_3_For_1_Template, 4, 8, "div", 20, \u0275\u0275componentInstance().trackByOption, true);
47523  }
47524  if (rf & 2) {
47525    const ctx_r1 = \u0275\u0275nextContext();
47526    \u0275\u0275repeater(ctx_r1.selectedItems);
47527  }
47528}
47529function NgSelectComponent_Conditional_4_ng_template_0_Template(rf, ctx) {
47530}
47531function NgSelectComponent_Conditional_4_Template(rf, ctx) {
47532  if (rf & 1) {
47533    \u0275\u0275template(0, NgSelectComponent_Conditional_4_ng_template_0_Template, 0, 0, "ng-template", 12);
47534  }
47535  if (rf & 2) {
47536    const ctx_r1 = \u0275\u0275nextContext();
47537    \u0275\u0275property("ngTemplateOutlet", ctx_r1.multiLabelTemplate)("ngTemplateOutletContext", \u0275\u0275pureFunction2(2, _c8, ctx_r1.selectedValues, ctx_r1.clearItem));
47538  }
47539}
47540function NgSelectComponent_Conditional_8_ng_template_0_Template(rf, ctx) {
47541  if (rf & 1) {
47542    \u0275\u0275element(0, "div", 24);
47543  }
47544}
47545function NgSelectComponent_Conditional_8_ng_template_2_Template(rf, ctx) {
47546}
47547function NgSelectComponent_Conditional_8_Template(rf, ctx) {
47548  if (rf & 1) {
47549    \u0275\u0275template(0, NgSelectComponent_Conditional_8_ng_template_0_Template, 1, 0, "ng-template", null, 3, \u0275\u0275templateRefExtractor)(2, NgSelectComponent_Conditional_8_ng_template_2_Template, 0, 0, "ng-template", 18);
47550  }
47551  if (rf & 2) {
47552    const defaultLoadingSpinnerTemplate_r8 = \u0275\u0275reference(1);
47553    const ctx_r1 = \u0275\u0275nextContext();
47554    \u0275\u0275advance(2);
47555    \u0275\u0275property("ngTemplateOutlet", ctx_r1.loadingSpinnerTemplate || defaultLoadingSpinnerTemplate_r8);
47556  }
47557}
47558function NgSelectComponent_Conditional_9_Conditional_0_Template(rf, ctx) {
47559  if (rf & 1) {
47560    \u0275\u0275elementContainer(0, 18);
47561  }
47562  if (rf & 2) {
47563    const ctx_r1 = \u0275\u0275nextContext(2);
47564    \u0275\u0275property("ngTemplateOutlet", ctx_r1.clearButtonTemplate);
47565  }
47566}
47567function NgSelectComponent_Conditional_9_Conditional_1_Template(rf, ctx) {
47568  if (rf & 1) {
47569    \u0275\u0275elementStart(0, "span", 25, 4)(2, "span", 26);
47570    \u0275\u0275text(3, "\xD7");
47571    \u0275\u0275elementEnd()();
47572  }
47573  if (rf & 2) {
47574    const ctx_r1 = \u0275\u0275nextContext(2);
47575    \u0275\u0275propertyInterpolate("title", ctx_r1.clearAllText);
47576  }
47577}
47578function NgSelectComponent_Conditional_9_Template(rf, ctx) {
47579  if (rf & 1) {
47580    \u0275\u0275template(0, NgSelectComponent_Conditional_9_Conditional_0_Template, 1, 1, "ng-container", 18)(1, NgSelectComponent_Conditional_9_Conditional_1_Template, 4, 1, "span", 25);
47581  }
47582  if (rf & 2) {
47583    const ctx_r1 = \u0275\u0275nextContext();
47584    \u0275\u0275conditional(ctx_r1.clearButtonTemplate ? 0 : 1);
47585  }
47586}
47587function NgSelectComponent_Conditional_12_For_3_ng_template_1_Template(rf, ctx) {
47588  if (rf & 1) {
47589    \u0275\u0275element(0, "span", 31);
47590  }
47591  if (rf & 2) {
47592    const item_r11 = \u0275\u0275nextContext().$implicit;
47593    const ctx_r1 = \u0275\u0275nextContext(2);
47594    \u0275\u0275property("ngItemLabel", item_r11.label)("escape", ctx_r1.escapeHTML);
47595  }
47596}
47597function NgSelectComponent_Conditional_12_For_3_ng_template_3_Template(rf, ctx) {
47598}
47599function NgSelectComponent_Conditional_12_For_3_Template(rf, ctx) {
47600  if (rf & 1) {
47601    const _r10 = \u0275\u0275getCurrentView();
47602    \u0275\u0275elementStart(0, "div", 30);
47603    \u0275\u0275listener("click", function NgSelectComponent_Conditional_12_For_3_Template_div_click_0_listener() {
47604      const item_r11 = \u0275\u0275restoreView(_r10).$implicit;
47605      const ctx_r1 = \u0275\u0275nextContext(2);
47606      return \u0275\u0275resetView(ctx_r1.toggleItem(item_r11));
47607    })("mouseover", function NgSelectComponent_Conditional_12_For_3_Template_div_mouseover_0_listener() {
47608      const item_r11 = \u0275\u0275restoreView(_r10).$implicit;
47609      const ctx_r1 = \u0275\u0275nextContext(2);
47610      return \u0275\u0275resetView(ctx_r1.onItemHover(item_r11));
47611    });
47612    \u0275\u0275template(1, NgSelectComponent_Conditional_12_For_3_ng_template_1_Template, 1, 2, "ng-template", null, 5, \u0275\u0275templateRefExtractor)(3, NgSelectComponent_Conditional_12_For_3_ng_template_3_Template, 0, 0, "ng-template", 12);
47613    \u0275\u0275elementEnd();
47614  }
47615  if (rf & 2) {
47616    const item_r11 = ctx.$implicit;
47617    const defaultOptionTemplate_r12 = \u0275\u0275reference(2);
47618    const ctx_r1 = \u0275\u0275nextContext(2);
47619    \u0275\u0275classProp("ng-option-disabled", item_r11.disabled)("ng-option-selected", item_r11.selected)("ng-optgroup", item_r11.children)("ng-option", !item_r11.children)("ng-option-child", !!item_r11.parent)("ng-option-marked", item_r11 === ctx_r1.itemsList.markedItem);
47620    \u0275\u0275attribute("role", item_r11.children ? "group" : "option")("aria-selected", item_r11.selected)("id", item_r11 == null ? null : item_r11.htmlId);
47621    \u0275\u0275advance(3);
47622    \u0275\u0275property("ngTemplateOutlet", item_r11.children ? ctx_r1.optgroupTemplate || defaultOptionTemplate_r12 : ctx_r1.optionTemplate || defaultOptionTemplate_r12)("ngTemplateOutletContext", \u0275\u0275pureFunction4(17, _c9, item_r11.value, item_r11, item_r11.index, ctx_r1.searchTerm));
47623  }
47624}
47625function NgSelectComponent_Conditional_12_Conditional_4_ng_template_1_Template(rf, ctx) {
47626  if (rf & 1) {
47627    \u0275\u0275elementStart(0, "span")(1, "span", 33);
47628    \u0275\u0275text(2);
47629    \u0275\u0275elementEnd();
47630    \u0275\u0275text(3);
47631    \u0275\u0275elementEnd();
47632  }
47633  if (rf & 2) {
47634    const ctx_r1 = \u0275\u0275nextContext(3);
47635    \u0275\u0275advance(2);
47636    \u0275\u0275textInterpolate(ctx_r1.addTagText);
47637    \u0275\u0275advance();
47638    \u0275\u0275textInterpolate1('"', ctx_r1.searchTerm, '"');
47639  }
47640}
47641function NgSelectComponent_Conditional_12_Conditional_4_ng_template_3_Template(rf, ctx) {
47642}
47643function NgSelectComponent_Conditional_12_Conditional_4_Template(rf, ctx) {
47644  if (rf & 1) {
47645    const _r13 = \u0275\u0275getCurrentView();
47646    \u0275\u0275elementStart(0, "div", 32);
47647    \u0275\u0275listener("mouseover", function NgSelectComponent_Conditional_12_Conditional_4_Template_div_mouseover_0_listener() {
47648      \u0275\u0275restoreView(_r13);
47649      const ctx_r1 = \u0275\u0275nextContext(2);
47650      return \u0275\u0275resetView(ctx_r1.itemsList.unmarkItem());
47651    })("click", function NgSelectComponent_Conditional_12_Conditional_4_Template_div_click_0_listener() {
47652      \u0275\u0275restoreView(_r13);
47653      const ctx_r1 = \u0275\u0275nextContext(2);
47654      return \u0275\u0275resetView(ctx_r1.selectTag());
47655    });
47656    \u0275\u0275template(1, NgSelectComponent_Conditional_12_Conditional_4_ng_template_1_Template, 4, 2, "ng-template", null, 6, \u0275\u0275templateRefExtractor)(3, NgSelectComponent_Conditional_12_Conditional_4_ng_template_3_Template, 0, 0, "ng-template", 12);
47657    \u0275\u0275elementEnd();
47658  }
47659  if (rf & 2) {
47660    const defaultTagTemplate_r14 = \u0275\u0275reference(2);
47661    const ctx_r1 = \u0275\u0275nextContext(2);
47662    \u0275\u0275classProp("ng-option-marked", !ctx_r1.itemsList.markedItem);
47663    \u0275\u0275advance(3);
47664    \u0275\u0275property("ngTemplateOutlet", ctx_r1.tagTemplate || defaultTagTemplate_r14)("ngTemplateOutletContext", \u0275\u0275pureFunction1(4, _c4, ctx_r1.searchTerm));
47665  }
47666}
47667function NgSelectComponent_Conditional_12_Conditional_5_ng_template_0_Template(rf, ctx) {
47668  if (rf & 1) {
47669    \u0275\u0275elementStart(0, "div", 34);
47670    \u0275\u0275text(1);
47671    \u0275\u0275elementEnd();
47672  }
47673  if (rf & 2) {
47674    const ctx_r1 = \u0275\u0275nextContext(3);
47675    \u0275\u0275advance();
47676    \u0275\u0275textInterpolate(ctx_r1.notFoundText);
47677  }
47678}
47679function NgSelectComponent_Conditional_12_Conditional_5_ng_template_2_Template(rf, ctx) {
47680}
47681function NgSelectComponent_Conditional_12_Conditional_5_Template(rf, ctx) {
47682  if (rf & 1) {
47683    \u0275\u0275template(0, NgSelectComponent_Conditional_12_Conditional_5_ng_template_0_Template, 2, 1, "ng-template", null, 7, \u0275\u0275templateRefExtractor)(2, NgSelectComponent_Conditional_12_Conditional_5_ng_template_2_Template, 0, 0, "ng-template", 12);
47684  }
47685  if (rf & 2) {
47686    const defaultNotFoundTemplate_r15 = \u0275\u0275reference(1);
47687    const ctx_r1 = \u0275\u0275nextContext(2);
47688    \u0275\u0275advance(2);
47689    \u0275\u0275property("ngTemplateOutlet", ctx_r1.notFoundTemplate || defaultNotFoundTemplate_r15)("ngTemplateOutletContext", \u0275\u0275pureFunction1(2, _c4, ctx_r1.searchTerm));
47690  }
47691}
47692function NgSelectComponent_Conditional_12_Conditional_6_ng_template_0_Template(rf, ctx) {
47693  if (rf & 1) {
47694    \u0275\u0275elementStart(0, "div", 34);
47695    \u0275\u0275text(1);
47696    \u0275\u0275elementEnd();
47697  }
47698  if (rf & 2) {
47699    const ctx_r1 = \u0275\u0275nextContext(3);
47700    \u0275\u0275advance();
47701    \u0275\u0275textInterpolate(ctx_r1.typeToSearchText);
47702  }
47703}
47704function NgSelectComponent_Conditional_12_Conditional_6_ng_template_2_Template(rf, ctx) {
47705}
47706function NgSelectComponent_Conditional_12_Conditional_6_Template(rf, ctx) {
47707  if (rf & 1) {
47708    \u0275\u0275template(0, NgSelectComponent_Conditional_12_Conditional_6_ng_template_0_Template, 2, 1, "ng-template", null, 8, \u0275\u0275templateRefExtractor)(2, NgSelectComponent_Conditional_12_Conditional_6_ng_template_2_Template, 0, 0, "ng-template", 18);
47709  }
47710  if (rf & 2) {
47711    const defaultTypeToSearchTemplate_r16 = \u0275\u0275reference(1);
47712    const ctx_r1 = \u0275\u0275nextContext(2);
47713    \u0275\u0275advance(2);
47714    \u0275\u0275property("ngTemplateOutlet", ctx_r1.typeToSearchTemplate || defaultTypeToSearchTemplate_r16);
47715  }
47716}
47717function NgSelectComponent_Conditional_12_Conditional_7_ng_template_0_Template(rf, ctx) {
47718  if (rf & 1) {
47719    \u0275\u0275elementStart(0, "div", 34);
47720    \u0275\u0275text(1);
47721    \u0275\u0275elementEnd();
47722  }
47723  if (rf & 2) {
47724    const ctx_r1 = \u0275\u0275nextContext(3);
47725    \u0275\u0275advance();
47726    \u0275\u0275textInterpolate(ctx_r1.loadingText);
47727  }
47728}
47729function NgSelectComponent_Conditional_12_Conditional_7_ng_template_2_Template(rf, ctx) {
47730}
47731function NgSelectComponent_Conditional_12_Conditional_7_Template(rf, ctx) {
47732  if (rf & 1) {
47733    \u0275\u0275template(0, NgSelectComponent_Conditional_12_Conditional_7_ng_template_0_Template, 2, 1, "ng-template", null, 9, \u0275\u0275templateRefExtractor)(2, NgSelectComponent_Conditional_12_Conditional_7_ng_template_2_Template, 0, 0, "ng-template", 12);
47734  }
47735  if (rf & 2) {
47736    const defaultLoadingTextTemplate_r17 = \u0275\u0275reference(1);
47737    const ctx_r1 = \u0275\u0275nextContext(2);
47738    \u0275\u0275advance(2);
47739    \u0275\u0275property("ngTemplateOutlet", ctx_r1.loadingTextTemplate || defaultLoadingTextTemplate_r17)("ngTemplateOutletContext", \u0275\u0275pureFunction1(2, _c4, ctx_r1.searchTerm));
47740  }
47741}
47742function NgSelectComponent_Conditional_12_Template(rf, ctx) {
47743  if (rf & 1) {
47744    const _r9 = \u0275\u0275getCurrentView();
47745    \u0275\u0275elementStart(0, "ng-dropdown-panel", 27);
47746    \u0275\u0275listener("update", function NgSelectComponent_Conditional_12_Template_ng_dropdown_panel_update_0_listener($event) {
47747      \u0275\u0275restoreView(_r9);
47748      const ctx_r1 = \u0275\u0275nextContext();
47749      return \u0275\u0275resetView(ctx_r1.viewPortItems = $event);
47750    })("scroll", function NgSelectComponent_Conditional_12_Template_ng_dropdown_panel_scroll_0_listener($event) {
47751      \u0275\u0275restoreView(_r9);
47752      const ctx_r1 = \u0275\u0275nextContext();
47753      return \u0275\u0275resetView(ctx_r1.scroll.emit($event));
47754    })("scrollToEnd", function NgSelectComponent_Conditional_12_Template_ng_dropdown_panel_scrollToEnd_0_listener($event) {
47755      \u0275\u0275restoreView(_r9);
47756      const ctx_r1 = \u0275\u0275nextContext();
47757      return \u0275\u0275resetView(ctx_r1.scrollToEnd.emit($event));
47758    })("outsideClick", function NgSelectComponent_Conditional_12_Template_ng_dropdown_panel_outsideClick_0_listener() {
47759      \u0275\u0275restoreView(_r9);
47760      const ctx_r1 = \u0275\u0275nextContext();
47761      return \u0275\u0275resetView(ctx_r1.close());
47762    });
47763    \u0275\u0275elementContainerStart(1);
47764    \u0275\u0275repeaterCreate(2, NgSelectComponent_Conditional_12_For_3_Template, 4, 22, "div", 28, \u0275\u0275componentInstance().trackByOption, true);
47765    \u0275\u0275template(4, NgSelectComponent_Conditional_12_Conditional_4_Template, 4, 6, "div", 29);
47766    \u0275\u0275elementContainerEnd();
47767    \u0275\u0275template(5, NgSelectComponent_Conditional_12_Conditional_5_Template, 3, 4)(6, NgSelectComponent_Conditional_12_Conditional_6_Template, 3, 1)(7, NgSelectComponent_Conditional_12_Conditional_7_Template, 3, 4);
47768    \u0275\u0275elementEnd();
47769  }
47770  if (rf & 2) {
47771    const ctx_r1 = \u0275\u0275nextContext();
47772    \u0275\u0275classProp("ng-select-multiple", ctx_r1.multiple);
47773    \u0275\u0275property("virtualScroll", ctx_r1.virtualScroll)("bufferAmount", ctx_r1.bufferAmount)("appendTo", ctx_r1.appendTo)("position", ctx_r1.dropdownPosition)("headerTemplate", ctx_r1.headerTemplate)("footerTemplate", ctx_r1.footerTemplate)("filterValue", ctx_r1.searchTerm)("items", ctx_r1.itemsList.filteredItems)("markedItem", ctx_r1.itemsList.markedItem)("ngClass", ctx_r1.appendTo ? ctx_r1.ngClass ? ctx_r1.ngClass : ctx_r1.classes : null)("id", ctx_r1.dropdownId);
47774    \u0275\u0275attribute("aria-label", ctx_r1.ariaLabelDropdown);
47775    \u0275\u0275advance(2);
47776    \u0275\u0275repeater(ctx_r1.viewPortItems);
47777    \u0275\u0275advance(2);
47778    \u0275\u0275conditional(ctx_r1.showAddTag ? 4 : -1);
47779    \u0275\u0275advance();
47780    \u0275\u0275conditional(ctx_r1.showNoItemsFound() ? 5 : -1);
47781    \u0275\u0275advance();
47782    \u0275\u0275conditional(ctx_r1.showTypeToSearch() ? 6 : -1);
47783    \u0275\u0275advance();
47784    \u0275\u0275conditional(ctx_r1.loading && ctx_r1.itemsList.filteredItems.length === 0 ? 7 : -1);
47785  }
47786}
47787var unescapedHTMLExp = /[&<>"']/g;
47788var hasUnescapedHTMLExp = RegExp(unescapedHTMLExp.source);
47789var htmlEscapes = {
47790  "&": "&amp;",
47791  "<": "&lt;",
47792  ">": "&gt;",
47793  '"': "&quot;",
47794  "'": "&#39;"
47795};
47796function escapeHTML(value) {
47797  return value && hasUnescapedHTMLExp.test(value) ? value.replace(unescapedHTMLExp, (chr) => htmlEscapes[chr]) : value;
47798}
47799function isDefined2(value) {
47800  return value !== void 0 && value !== null;
47801}
47802function isObject3(value) {
47803  return typeof value === "object" && isDefined2(value);
47804}
47805function isPromise2(value) {
47806  return value instanceof Promise;
47807}
47808function isFunction2(value) {
47809  return value instanceof Function;
47810}
47811var NgItemLabelDirective = class _NgItemLabelDirective {
47812  constructor(element) {
47813    this.element = element;
47814    this.escape = true;
47815  }
47816  ngOnChanges(changes) {
47817    this.element.nativeElement.innerHTML = this.escape ? escapeHTML(this.ngItemLabel) : this.ngItemLabel;
47818  }
47819  static {
47820    this.\u0275fac = function NgItemLabelDirective_Factory(__ngFactoryType__) {
47821      return new (__ngFactoryType__ || _NgItemLabelDirective)(\u0275\u0275directiveInject(ElementRef));
47822    };
47823  }
47824  static {
47825    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
47826      type: _NgItemLabelDirective,
47827      selectors: [["", "ngItemLabel", ""]],
47828      inputs: {
47829        ngItemLabel: "ngItemLabel",
47830        escape: "escape"
47831      },
47832      features: [\u0275\u0275NgOnChangesFeature]
47833    });
47834  }
47835};
47836(() => {
47837  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgItemLabelDirective, [{
47838    type: Directive,
47839    args: [{
47840      selector: "[ngItemLabel]",
47841      standalone: true
47842    }]
47843  }], () => [{
47844    type: ElementRef
47845  }], {
47846    ngItemLabel: [{
47847      type: Input
47848    }],
47849    escape: [{
47850      type: Input
47851    }]
47852  });
47853})();
47854var NgOptionTemplateDirective = class _NgOptionTemplateDirective {
47855  constructor(template) {
47856    this.template = template;
47857  }
47858  static {
47859    this.\u0275fac = function NgOptionTemplateDirective_Factory(__ngFactoryType__) {
47860      return new (__ngFactoryType__ || _NgOptionTemplateDirective)(\u0275\u0275directiveInject(TemplateRef));
47861    };
47862  }
47863  static {
47864    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
47865      type: _NgOptionTemplateDirective,
47866      selectors: [["", "ng-option-tmp", ""]]
47867    });
47868  }
47869};
47870(() => {
47871  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgOptionTemplateDirective, [{
47872    type: Directive,
47873    args: [{
47874      // eslint-disable-next-line @angular-eslint/directive-selector
47875      selector: "[ng-option-tmp]",
47876      standalone: true
47877    }]
47878  }], () => [{
47879    type: TemplateRef
47880  }], null);
47881})();
47882var NgOptgroupTemplateDirective = class _NgOptgroupTemplateDirective {
47883  constructor(template) {
47884    this.template = template;
47885  }
47886  static {
47887    this.\u0275fac = function NgOptgroupTemplateDirective_Factory(__ngFactoryType__) {
47888      return new (__ngFactoryType__ || _NgOptgroupTemplateDirective)(\u0275\u0275directiveInject(TemplateRef));
47889    };
47890  }
47891  static {
47892    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
47893      type: _NgOptgroupTemplateDirective,
47894      selectors: [["", "ng-optgroup-tmp", ""]]
47895    });
47896  }
47897};
47898(() => {
47899  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgOptgroupTemplateDirective, [{
47900    type: Directive,
47901    args: [{
47902      // eslint-disable-next-line @angular-eslint/directive-selector
47903      selector: "[ng-optgroup-tmp]",
47904      standalone: true
47905    }]
47906  }], () => [{
47907    type: TemplateRef
47908  }], null);
47909})();
47910var NgLabelTemplateDirective = class _NgLabelTemplateDirective {
47911  constructor(template) {
47912    this.template = template;
47913  }
47914  static {
47915    this.\u0275fac = function NgLabelTemplateDirective_Factory(__ngFactoryType__) {
47916      return new (__ngFactoryType__ || _NgLabelTemplateDirective)(\u0275\u0275directiveInject(TemplateRef));
47917    };
47918  }
47919  static {
47920    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
47921      type: _NgLabelTemplateDirective,
47922      selectors: [["", "ng-label-tmp", ""]]
47923    });
47924  }
47925};
47926(() => {
47927  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgLabelTemplateDirective, [{
47928    type: Directive,
47929    args: [{
47930      // eslint-disable-next-line @angular-eslint/directive-selector
47931      selector: "[ng-label-tmp]",
47932      standalone: true
47933    }]
47934  }], () => [{
47935    type: TemplateRef
47936  }], null);
47937})();
47938var NgMultiLabelTemplateDirective = class _NgMultiLabelTemplateDirective {
47939  constructor(template) {
47940    this.template = template;
47941  }
47942  static {
47943    this.\u0275fac = function NgMultiLabelTemplateDirective_Factory(__ngFactoryType__) {
47944      return new (__ngFactoryType__ || _NgMultiLabelTemplateDirective)(\u0275\u0275directiveInject(TemplateRef));
47945    };
47946  }
47947  static {
47948    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
47949      type: _NgMultiLabelTemplateDirective,
47950      selectors: [["", "ng-multi-label-tmp", ""]]
47951    });
47952  }
47953};
47954(() => {
47955  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgMultiLabelTemplateDirective, [{
47956    type: Directive,
47957    args: [{
47958      // eslint-disable-next-line @angular-eslint/directive-selector
47959      selector: "[ng-multi-label-tmp]",
47960      standalone: true
47961    }]
47962  }], () => [{
47963    type: TemplateRef
47964  }], null);
47965})();
47966var NgHeaderTemplateDirective = class _NgHeaderTemplateDirective {
47967  constructor(template) {
47968    this.template = template;
47969  }
47970  static {
47971    this.\u0275fac = function NgHeaderTemplateDirective_Factory(__ngFactoryType__) {
47972      return new (__ngFactoryType__ || _NgHeaderTemplateDirective)(\u0275\u0275directiveInject(TemplateRef));
47973    };
47974  }
47975  static {
47976    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
47977      type: _NgHeaderTemplateDirective,
47978      selectors: [["", "ng-header-tmp", ""]]
47979    });
47980  }
47981};
47982(() => {
47983  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgHeaderTemplateDirective, [{
47984    type: Directive,
47985    args: [{
47986      // eslint-disable-next-line @angular-eslint/directive-selector
47987      selector: "[ng-header-tmp]",
47988      standalone: true
47989    }]
47990  }], () => [{
47991    type: TemplateRef
47992  }], null);
47993})();
47994var NgFooterTemplateDirective = class _NgFooterTemplateDirective {
47995  constructor(template) {
47996    this.template = template;
47997  }
47998  static {
47999    this.\u0275fac = function NgFooterTemplateDirective_Factory(__ngFactoryType__) {
48000      return new (__ngFactoryType__ || _NgFooterTemplateDirective)(\u0275\u0275directiveInject(TemplateRef));
48001    };
48002  }
48003  static {
48004    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
48005      type: _NgFooterTemplateDirective,
48006      selectors: [["", "ng-footer-tmp", ""]]
48007    });
48008  }
48009};
48010(() => {
48011  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgFooterTemplateDirective, [{
48012    type: Directive,
48013    args: [{
48014      // eslint-disable-next-line @angular-eslint/directive-selector
48015      selector: "[ng-footer-tmp]",
48016      standalone: true
48017    }]
48018  }], () => [{
48019    type: TemplateRef
48020  }], null);
48021})();
48022var NgNotFoundTemplateDirective = class _NgNotFoundTemplateDirective {
48023  constructor(template) {
48024    this.template = template;
48025  }
48026  static {
48027    this.\u0275fac = function NgNotFoundTemplateDirective_Factory(__ngFactoryType__) {
48028      return new (__ngFactoryType__ || _NgNotFoundTemplateDirective)(\u0275\u0275directiveInject(TemplateRef));
48029    };
48030  }
48031  static {
48032    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
48033      type: _NgNotFoundTemplateDirective,
48034      selectors: [["", "ng-notfound-tmp", ""]]
48035    });
48036  }
48037};
48038(() => {
48039  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgNotFoundTemplateDirective, [{
48040    type: Directive,
48041    args: [{
48042      // eslint-disable-next-line @angular-eslint/directive-selector
48043      selector: "[ng-notfound-tmp]",
48044      standalone: true
48045    }]
48046  }], () => [{
48047    type: TemplateRef
48048  }], null);
48049})();
48050var NgPlaceholderTemplateDirective = class _NgPlaceholderTemplateDirective {
48051  constructor(template) {
48052    this.template = template;
48053  }
48054  static {
48055    this.\u0275fac = function NgPlaceholderTemplateDirective_Factory(__ngFactoryType__) {
48056      return new (__ngFactoryType__ || _NgPlaceholderTemplateDirective)(\u0275\u0275directiveInject(TemplateRef));
48057    };
48058  }
48059  static {
48060    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
48061      type: _NgPlaceholderTemplateDirective,
48062      selectors: [["", "ng-placeholder-tmp", ""]]
48063    });
48064  }
48065};
48066(() => {
48067  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgPlaceholderTemplateDirective, [{
48068    type: Directive,
48069    args: [{
48070      // eslint-disable-next-line @angular-eslint/directive-selector
48071      selector: "[ng-placeholder-tmp]",
48072      standalone: true
48073    }]
48074  }], () => [{
48075    type: TemplateRef
48076  }], null);
48077})();
48078var NgTypeToSearchTemplateDirective = class _NgTypeToSearchTemplateDirective {
48079  constructor(template) {
48080    this.template = template;
48081  }
48082  static {
48083    this.\u0275fac = function NgTypeToSearchTemplateDirective_Factory(__ngFactoryType__) {
48084      return new (__ngFactoryType__ || _NgTypeToSearchTemplateDirective)(\u0275\u0275directiveInject(TemplateRef));
48085    };
48086  }
48087  static {
48088    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
48089      type: _NgTypeToSearchTemplateDirective,
48090      selectors: [["", "ng-typetosearch-tmp", ""]]
48091    });
48092  }
48093};
48094(() => {
48095  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgTypeToSearchTemplateDirective, [{
48096    type: Directive,
48097    args: [{
48098      // eslint-disable-next-line @angular-eslint/directive-selector
48099      selector: "[ng-typetosearch-tmp]",
48100      standalone: true
48101    }]
48102  }], () => [{
48103    type: TemplateRef
48104  }], null);
48105})();
48106var NgLoadingTextTemplateDirective = class _NgLoadingTextTemplateDirective {
48107  constructor(template) {
48108    this.template = template;
48109  }
48110  static {
48111    this.\u0275fac = function NgLoadingTextTemplateDirective_Factory(__ngFactoryType__) {
48112      return new (__ngFactoryType__ || _NgLoadingTextTemplateDirective)(\u0275\u0275directiveInject(TemplateRef));
48113    };
48114  }
48115  static {
48116    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
48117      type: _NgLoadingTextTemplateDirective,
48118      selectors: [["", "ng-loadingtext-tmp", ""]]
48119    });
48120  }
48121};
48122(() => {
48123  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgLoadingTextTemplateDirective, [{
48124    type: Directive,
48125    args: [{
48126      // eslint-disable-next-line @angular-eslint/directive-selector
48127      selector: "[ng-loadingtext-tmp]",
48128      standalone: true
48129    }]
48130  }], () => [{
48131    type: TemplateRef
48132  }], null);
48133})();
48134var NgTagTemplateDirective = class _NgTagTemplateDirective {
48135  constructor(template) {
48136    this.template = template;
48137  }
48138  static {
48139    this.\u0275fac = function NgTagTemplateDirective_Factory(__ngFactoryType__) {
48140      return new (__ngFactoryType__ || _NgTagTemplateDirective)(\u0275\u0275directiveInject(TemplateRef));
48141    };
48142  }
48143  static {
48144    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
48145      type: _NgTagTemplateDirective,
48146      selectors: [["", "ng-tag-tmp", ""]]
48147    });
48148  }
48149};
48150(() => {
48151  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgTagTemplateDirective, [{
48152    type: Directive,
48153    args: [{
48154      // eslint-disable-next-line @angular-eslint/directive-selector
48155      selector: "[ng-tag-tmp]",
48156      standalone: true
48157    }]
48158  }], () => [{
48159    type: TemplateRef
48160  }], null);
48161})();
48162var NgLoadingSpinnerTemplateDirective = class _NgLoadingSpinnerTemplateDirective {
48163  constructor(template) {
48164    this.template = template;
48165  }
48166  static {
48167    this.\u0275fac = function NgLoadingSpinnerTemplateDirective_Factory(__ngFactoryType__) {
48168      return new (__ngFactoryType__ || _NgLoadingSpinnerTemplateDirective)(\u0275\u0275directiveInject(TemplateRef));
48169    };
48170  }
48171  static {
48172    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
48173      type: _NgLoadingSpinnerTemplateDirective,
48174      selectors: [["", "ng-loadingspinner-tmp", ""]]
48175    });
48176  }
48177};
48178(() => {
48179  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgLoadingSpinnerTemplateDirective, [{
48180    type: Directive,
48181    args: [{
48182      // eslint-disable-next-line @angular-eslint/directive-selector
48183      selector: "[ng-loadingspinner-tmp]",
48184      standalone: true
48185    }]
48186  }], () => [{
48187    type: TemplateRef
48188  }], null);
48189})();
48190var NgClearButtonTemplateDirective = class _NgClearButtonTemplateDirective {
48191  constructor(template) {
48192    this.template = template;
48193  }
48194  static {
48195    this.\u0275fac = function NgClearButtonTemplateDirective_Factory(__ngFactoryType__) {
48196      return new (__ngFactoryType__ || _NgClearButtonTemplateDirective)(\u0275\u0275directiveInject(TemplateRef));
48197    };
48198  }
48199  static {
48200    this.\u0275dir = /* @__PURE__ */ \u0275\u0275defineDirective({
48201      type: _NgClearButtonTemplateDirective,
48202      selectors: [["", "ng-clearbutton-tmp", ""]]
48203    });
48204  }
48205};
48206(() => {
48207  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgClearButtonTemplateDirective, [{
48208    type: Directive,
48209    args: [{
48210      selector: "[ng-clearbutton-tmp]",
48211      standalone: true
48212    }]
48213  }], () => [{
48214    type: TemplateRef
48215  }], null);
48216})();
48217function newId() {
48218  return "axxxxxxxxxxx".replace(/[x]/g, () => {
48219    const val = Math.random() * 16 | 0;
48220    return val.toString(16);
48221  });
48222}
48223var diacritics = {
48224  "\u24B6": "A",
48225  "\uFF21": "A",
48226  "\xC0": "A",
48227  "\xC1": "A",
48228  "\xC2": "A",
48229  "\u1EA6": "A",
48230  "\u1EA4": "A",
48231  "\u1EAA": "A",
48232  "\u1EA8": "A",
48233  "\xC3": "A",
48234  "\u0100": "A",
48235  "\u0102": "A",
48236  "\u1EB0": "A",
48237  "\u1EAE": "A",
48238  "\u1EB4": "A",
48239  "\u1EB2": "A",
48240  "\u0226": "A",
48241  "\u01E0": "A",
48242  "\xC4": "A",
48243  "\u01DE": "A",
48244  "\u1EA2": "A",
48245  "\xC5": "A",
48246  "\u01FA": "A",
48247  "\u01CD": "A",
48248  "\u0200": "A",
48249  "\u0202": "A",
48250  "\u1EA0": "A",
48251  "\u1EAC": "A",
48252  "\u1EB6": "A",
48253  "\u1E00": "A",
48254  "\u0104": "A",
48255  "\u023A": "A",
48256  "\u2C6F": "A",
48257  "\uA732": "AA",
48258  "\xC6": "AE",
48259  "\u01FC": "AE",
48260  "\u01E2": "AE",
48261  "\uA734": "AO",
48262  "\uA736": "AU",
48263  "\uA738": "AV",
48264  "\uA73A": "AV",
48265  "\uA73C": "AY",
48266  "\u24B7": "B",
48267  "\uFF22": "B",
48268  "\u1E02": "B",
48269  "\u1E04": "B",
48270  "\u1E06": "B",
48271  "\u0243": "B",
48272  "\u0182": "B",
48273  "\u0181": "B",
48274  "\u24B8": "C",
48275  "\uFF23": "C",
48276  "\u0106": "C",
48277  "\u0108": "C",
48278  "\u010A": "C",
48279  "\u010C": "C",
48280  "\xC7": "C",
48281  "\u1E08": "C",
48282  "\u0187": "C",
48283  "\u023B": "C",
48284  "\uA73E": "C",
48285  "\u24B9": "D",
48286  "\uFF24": "D",
48287  "\u1E0A": "D",
48288  "\u010E": "D",
48289  "\u1E0C": "D",
48290  "\u1E10": "D",
48291  "\u1E12": "D",
48292  "\u1E0E": "D",
48293  "\u0110": "D",
48294  "\u018B": "D",
48295  "\u018A": "D",
48296  "\u0189": "D",
48297  "\uA779": "D",
48298  "\u01F1": "DZ",
48299  "\u01C4": "DZ",
48300  "\u01F2": "Dz",
48301  "\u01C5": "Dz",
48302  "\u24BA": "E",
48303  "\uFF25": "E",
48304  "\xC8": "E",
48305  "\xC9": "E",
48306  "\xCA": "E",
48307  "\u1EC0": "E",
48308  "\u1EBE": "E",
48309  "\u1EC4": "E",
48310  "\u1EC2": "E",
48311  "\u1EBC": "E",
48312  "\u0112": "E",
48313  "\u1E14": "E",
48314  "\u1E16": "E",
48315  "\u0114": "E",
48316  "\u0116": "E",
48317  "\xCB": "E",
48318  "\u1EBA": "E",
48319  "\u011A": "E",
48320  "\u0204": "E",
48321  "\u0206": "E",
48322  "\u1EB8": "E",
48323  "\u1EC6": "E",
48324  "\u0228": "E",
48325  "\u1E1C": "E",
48326  "\u0118": "E",
48327  "\u1E18": "E",
48328  "\u1E1A": "E",
48329  "\u0190": "E",
48330  "\u018E": "E",
48331  "\u24BB": "F",
48332  "\uFF26": "F",
48333  "\u1E1E": "F",
48334  "\u0191": "F",
48335  "\uA77B": "F",
48336  "\u24BC": "G",
48337  "\uFF27": "G",
48338  "\u01F4": "G",
48339  "\u011C": "G",
48340  "\u1E20": "G",
48341  "\u011E": "G",
48342  "\u0120": "G",
48343  "\u01E6": "G",
48344  "\u0122": "G",
48345  "\u01E4": "G",
48346  "\u0193": "G",
48347  "\uA7A0": "G",
48348  "\uA77D": "G",
48349  "\uA77E": "G",
48350  "\u24BD": "H",
48351  "\uFF28": "H",
48352  "\u0124": "H",
48353  "\u1E22": "H",
48354  "\u1E26": "H",
48355  "\u021E": "H",
48356  "\u1E24": "H",
48357  "\u1E28": "H",
48358  "\u1E2A": "H",
48359  "\u0126": "H",
48360  "\u2C67": "H",
48361  "\u2C75": "H",
48362  "\uA78D": "H",
48363  "\u24BE": "I",
48364  "\uFF29": "I",
48365  "\xCC": "I",
48366  "\xCD": "I",
48367  "\xCE": "I",
48368  "\u0128": "I",
48369  "\u012A": "I",
48370  "\u012C": "I",
48371  "\u0130": "I",
48372  "\xCF": "I",
48373  "\u1E2E": "I",
48374  "\u1EC8": "I",
48375  "\u01CF": "I",
48376  "\u0208": "I",
48377  "\u020A": "I",
48378  "\u1ECA": "I",
48379  "\u012E": "I",
48380  "\u1E2C": "I",
48381  "\u0197": "I",
48382  "\u24BF": "J",
48383  "\uFF2A": "J",
48384  "\u0134": "J",
48385  "\u0248": "J",
48386  "\u24C0": "K",
48387  "\uFF2B": "K",
48388  "\u1E30": "K",
48389  "\u01E8": "K",
48390  "\u1E32": "K",
48391  "\u0136": "K",
48392  "\u1E34": "K",
48393  "\u0198": "K",
48394  "\u2C69": "K",
48395  "\uA740": "K",
48396  "\uA742": "K",
48397  "\uA744": "K",
48398  "\uA7A2": "K",
48399  "\u24C1": "L",
48400  "\uFF2C": "L",
48401  "\u013F": "L",
48402  "\u0139": "L",
48403  "\u013D": "L",
48404  "\u1E36": "L",
48405  "\u1E38": "L",
48406  "\u013B": "L",
48407  "\u1E3C": "L",
48408  "\u1E3A": "L",
48409  "\u0141": "L",
48410  "\u023D": "L",
48411  "\u2C62": "L",
48412  "\u2C60": "L",
48413  "\uA748": "L",
48414  "\uA746": "L",
48415  "\uA780": "L",
48416  "\u01C7": "LJ",
48417  "\u01C8": "Lj",
48418  "\u24C2": "M",
48419  "\uFF2D": "M",
48420  "\u1E3E": "M",
48421  "\u1E40": "M",
48422  "\u1E42": "M",
48423  "\u2C6E": "M",
48424  "\u019C": "M",
48425  "\u24C3": "N",
48426  "\uFF2E": "N",
48427  "\u01F8": "N",
48428  "\u0143": "N",
48429  "\xD1": "N",
48430  "\u1E44": "N",
48431  "\u0147": "N",
48432  "\u1E46": "N",
48433  "\u0145": "N",
48434  "\u1E4A": "N",
48435  "\u1E48": "N",
48436  "\u0220": "N",
48437  "\u019D": "N",
48438  "\uA790": "N",
48439  "\uA7A4": "N",
48440  "\u01CA": "NJ",
48441  "\u01CB": "Nj",
48442  "\u24C4": "O",
48443  "\uFF2F": "O",
48444  "\xD2": "O",
48445  "\xD3": "O",
48446  "\xD4": "O",
48447  "\u1ED2": "O",
48448  "\u1ED0": "O",
48449  "\u1ED6": "O",
48450  "\u1ED4": "O",
48451  "\xD5": "O",
48452  "\u1E4C": "O",
48453  "\u022C": "O",
48454  "\u1E4E": "O",
48455  "\u014C": "O",
48456  "\u1E50": "O",
48457  "\u1E52": "O",
48458  "\u014E": "O",
48459  "\u022E": "O",
48460  "\u0230": "O",
48461  "\xD6": "O",
48462  "\u022A": "O",
48463  "\u1ECE": "O",
48464  "\u0150": "O",
48465  "\u01D1": "O",
48466  "\u020C": "O",
48467  "\u020E": "O",
48468  "\u01A0": "O",
48469  "\u1EDC": "O",
48470  "\u1EDA": "O",
48471  "\u1EE0": "O",
48472  "\u1EDE": "O",
48473  "\u1EE2": "O",
48474  "\u1ECC": "O",
48475  "\u1ED8": "O",
48476  "\u01EA": "O",
48477  "\u01EC": "O",
48478  "\xD8": "O",
48479  "\u01FE": "O",
48480  "\u0186": "O",
48481  "\u019F": "O",
48482  "\uA74A": "O",
48483  "\uA74C": "O",
48484  "\u01A2": "OI",
48485  "\uA74E": "OO",
48486  "\u0222": "OU",
48487  "\u24C5": "P",
48488  "\uFF30": "P",
48489  "\u1E54": "P",
48490  "\u1E56": "P",
48491  "\u01A4": "P",
48492  "\u2C63": "P",
48493  "\uA750": "P",
48494  "\uA752": "P",
48495  "\uA754": "P",
48496  "\u24C6": "Q",
48497  "\uFF31": "Q",
48498  "\uA756": "Q",
48499  "\uA758": "Q",
48500  "\u024A": "Q",
48501  "\u24C7": "R",
48502  "\uFF32": "R",
48503  "\u0154": "R",
48504  "\u1E58": "R",
48505  "\u0158": "R",
48506  "\u0210": "R",
48507  "\u0212": "R",
48508  "\u1E5A": "R",
48509  "\u1E5C": "R",
48510  "\u0156": "R",
48511  "\u1E5E": "R",
48512  "\u024C": "R",
48513  "\u2C64": "R",
48514  "\uA75A": "R",
48515  "\uA7A6": "R",
48516  "\uA782": "R",
48517  "\u24C8": "S",
48518  "\uFF33": "S",
48519  "\u1E9E": "S",
48520  "\u015A": "S",
48521  "\u1E64": "S",
48522  "\u015C": "S",
48523  "\u1E60": "S",
48524  "\u0160": "S",
48525  "\u1E66": "S",
48526  "\u1E62": "S",
48527  "\u1E68": "S",
48528  "\u0218": "S",
48529  "\u015E": "S",
48530  "\u2C7E": "S",
48531  "\uA7A8": "S",
48532  "\uA784": "S",
48533  "\u24C9": "T",
48534  "\uFF34": "T",
48535  "\u1E6A": "T",
48536  "\u0164": "T",
48537  "\u1E6C": "T",
48538  "\u021A": "T",
48539  "\u0162": "T",
48540  "\u1E70": "T",
48541  "\u1E6E": "T",
48542  "\u0166": "T",
48543  "\u01AC": "T",
48544  "\u01AE": "T",
48545  "\u023E": "T",
48546  "\uA786": "T",
48547  "\uA728": "TZ",
48548  "\u24CA": "U",
48549  "\uFF35": "U",
48550  "\xD9": "U",
48551  "\xDA": "U",
48552  "\xDB": "U",
48553  "\u0168": "U",
48554  "\u1E78": "U",
48555  "\u016A": "U",
48556  "\u1E7A": "U",
48557  "\u016C": "U",
48558  "\xDC": "U",
48559  "\u01DB": "U",
48560  "\u01D7": "U",
48561  "\u01D5": "U",
48562  "\u01D9": "U",
48563  "\u1EE6": "U",
48564  "\u016E": "U",
48565  "\u0170": "U",
48566  "\u01D3": "U",
48567  "\u0214": "U",
48568  "\u0216": "U",
48569  "\u01AF": "U",
48570  "\u1EEA": "U",
48571  "\u1EE8": "U",
48572  "\u1EEE": "U",
48573  "\u1EEC": "U",
48574  "\u1EF0": "U",
48575  "\u1EE4": "U",
48576  "\u1E72": "U",
48577  "\u0172": "U",
48578  "\u1E76": "U",
48579  "\u1E74": "U",
48580  "\u0244": "U",
48581  "\u24CB": "V",
48582  "\uFF36": "V",
48583  "\u1E7C": "V",
48584  "\u1E7E": "V",
48585  "\u01B2": "V",
48586  "\uA75E": "V",
48587  "\u0245": "V",
48588  "\uA760": "VY",
48589  "\u24CC": "W",
48590  "\uFF37": "W",
48591  "\u1E80": "W",
48592  "\u1E82": "W",
48593  "\u0174": "W",
48594  "\u1E86": "W",
48595  "\u1E84": "W",
48596  "\u1E88": "W",
48597  "\u2C72": "W",
48598  "\u24CD": "X",
48599  "\uFF38": "X",
48600  "\u1E8A": "X",
48601  "\u1E8C": "X",
48602  "\u24CE": "Y",
48603  "\uFF39": "Y",
48604  "\u1EF2": "Y",
48605  "\xDD": "Y",
48606  "\u0176": "Y",
48607  "\u1EF8": "Y",
48608  "\u0232": "Y",
48609  "\u1E8E": "Y",
48610  "\u0178": "Y",
48611  "\u1EF6": "Y",
48612  "\u1EF4": "Y",
48613  "\u01B3": "Y",
48614  "\u024E": "Y",
48615  "\u1EFE": "Y",
48616  "\u24CF": "Z",
48617  "\uFF3A": "Z",
48618  "\u0179": "Z",
48619  "\u1E90": "Z",
48620  "\u017B": "Z",
48621  "\u017D": "Z",
48622  "\u1E92": "Z",
48623  "\u1E94": "Z",
48624  "\u01B5": "Z",
48625  "\u0224": "Z",
48626  "\u2C7F": "Z",
48627  "\u2C6B": "Z",
48628  "\uA762": "Z",
48629  "\u24D0": "a",
48630  "\uFF41": "a",
48631  "\u1E9A": "a",
48632  "\xE0": "a",
48633  "\xE1": "a",
48634  "\xE2": "a",
48635  "\u1EA7": "a",
48636  "\u1EA5": "a",
48637  "\u1EAB": "a",
48638  "\u1EA9": "a",
48639  "\xE3": "a",
48640  "\u0101": "a",
48641  "\u0103": "a",
48642  "\u1EB1": "a",
48643  "\u1EAF": "a",
48644  "\u1EB5": "a",
48645  "\u1EB3": "a",
48646  "\u0227": "a",
48647  "\u01E1": "a",
48648  "\xE4": "a",
48649  "\u01DF": "a",
48650  "\u1EA3": "a",
48651  "\xE5": "a",
48652  "\u01FB": "a",
48653  "\u01CE": "a",
48654  "\u0201": "a",
48655  "\u0203": "a",
48656  "\u1EA1": "a",
48657  "\u1EAD": "a",
48658  "\u1EB7": "a",
48659  "\u1E01": "a",
48660  "\u0105": "a",
48661  "\u2C65": "a",
48662  "\u0250": "a",
48663  "\uA733": "aa",
48664  "\xE6": "ae",
48665  "\u01FD": "ae",
48666  "\u01E3": "ae",
48667  "\uA735": "ao",
48668  "\uA737": "au",
48669  "\uA739": "av",
48670  "\uA73B": "av",
48671  "\uA73D": "ay",
48672  "\u24D1": "b",
48673  "\uFF42": "b",
48674  "\u1E03": "b",
48675  "\u1E05": "b",
48676  "\u1E07": "b",
48677  "\u0180": "b",
48678  "\u0183": "b",
48679  "\u0253": "b",
48680  "\u24D2": "c",
48681  "\uFF43": "c",
48682  "\u0107": "c",
48683  "\u0109": "c",
48684  "\u010B": "c",
48685  "\u010D": "c",
48686  "\xE7": "c",
48687  "\u1E09": "c",
48688  "\u0188": "c",
48689  "\u023C": "c",
48690  "\uA73F": "c",
48691  "\u2184": "c",
48692  "\u24D3": "d",
48693  "\uFF44": "d",
48694  "\u1E0B": "d",
48695  "\u010F": "d",
48696  "\u1E0D": "d",
48697  "\u1E11": "d",
48698  "\u1E13": "d",
48699  "\u1E0F": "d",
48700  "\u0111": "d",
48701  "\u018C": "d",
48702  "\u0256": "d",
48703  "\u0257": "d",
48704  "\uA77A": "d",
48705  "\u01F3": "dz",
48706  "\u01C6": "dz",
48707  "\u24D4": "e",
48708  "\uFF45": "e",
48709  "\xE8": "e",
48710  "\xE9": "e",
48711  "\xEA": "e",
48712  "\u1EC1": "e",
48713  "\u1EBF": "e",
48714  "\u1EC5": "e",
48715  "\u1EC3": "e",
48716  "\u1EBD": "e",
48717  "\u0113": "e",
48718  "\u1E15": "e",
48719  "\u1E17": "e",
48720  "\u0115": "e",
48721  "\u0117": "e",
48722  "\xEB": "e",
48723  "\u1EBB": "e",
48724  "\u011B": "e",
48725  "\u0205": "e",
48726  "\u0207": "e",
48727  "\u1EB9": "e",
48728  "\u1EC7": "e",
48729  "\u0229": "e",
48730  "\u1E1D": "e",
48731  "\u0119": "e",
48732  "\u1E19": "e",
48733  "\u1E1B": "e",
48734  "\u0247": "e",
48735  "\u025B": "e",
48736  "\u01DD": "e",
48737  "\u24D5": "f",
48738  "\uFF46": "f",
48739  "\u1E1F": "f",
48740  "\u0192": "f",
48741  "\uA77C": "f",
48742  "\u24D6": "g",
48743  "\uFF47": "g",
48744  "\u01F5": "g",
48745  "\u011D": "g",
48746  "\u1E21": "g",
48747  "\u011F": "g",
48748  "\u0121": "g",
48749  "\u01E7": "g",
48750  "\u0123": "g",
48751  "\u01E5": "g",
48752  "\u0260": "g",
48753  "\uA7A1": "g",
48754  "\u1D79": "g",
48755  "\uA77F": "g",
48756  "\u24D7": "h",
48757  "\uFF48": "h",
48758  "\u0125": "h",
48759  "\u1E23": "h",
48760  "\u1E27": "h",
48761  "\u021F": "h",
48762  "\u1E25": "h",
48763  "\u1E29": "h",
48764  "\u1E2B": "h",
48765  "\u1E96": "h",
48766  "\u0127": "h",
48767  "\u2C68": "h",
48768  "\u2C76": "h",
48769  "\u0265": "h",
48770  "\u0195": "hv",
48771  "\u24D8": "i",
48772  "\uFF49": "i",
48773  "\xEC": "i",
48774  "\xED": "i",
48775  "\xEE": "i",
48776  "\u0129": "i",
48777  "\u012B": "i",
48778  "\u012D": "i",
48779  "\xEF": "i",
48780  "\u1E2F": "i",
48781  "\u1EC9": "i",
48782  "\u01D0": "i",
48783  "\u0209": "i",
48784  "\u020B": "i",
48785  "\u1ECB": "i",
48786  "\u012F": "i",
48787  "\u1E2D": "i",
48788  "\u0268": "i",
48789  "\u0131": "i",
48790  "\u24D9": "j",
48791  "\uFF4A": "j",
48792  "\u0135": "j",
48793  "\u01F0": "j",
48794  "\u0249": "j",
48795  "\u24DA": "k",
48796  "\uFF4B": "k",
48797  "\u1E31": "k",
48798  "\u01E9": "k",
48799  "\u1E33": "k",
48800  "\u0137": "k",
48801  "\u1E35": "k",
48802  "\u0199": "k",
48803  "\u2C6A": "k",
48804  "\uA741": "k",
48805  "\uA743": "k",
48806  "\uA745": "k",
48807  "\uA7A3": "k",
48808  "\u24DB": "l",
48809  "\uFF4C": "l",
48810  "\u0140": "l",
48811  "\u013A": "l",
48812  "\u013E": "l",
48813  "\u1E37": "l",
48814  "\u1E39": "l",
48815  "\u013C": "l",
48816  "\u1E3D": "l",
48817  "\u1E3B": "l",
48818  "\u017F": "l",
48819  "\u0142": "l",
48820  "\u019A": "l",
48821  "\u026B": "l",
48822  "\u2C61": "l",
48823  "\uA749": "l",
48824  "\uA781": "l",
48825  "\uA747": "l",
48826  "\u01C9": "lj",
48827  "\u24DC": "m",
48828  "\uFF4D": "m",
48829  "\u1E3F": "m",
48830  "\u1E41": "m",
48831  "\u1E43": "m",
48832  "\u0271": "m",
48833  "\u026F": "m",
48834  "\u24DD": "n",
48835  "\uFF4E": "n",
48836  "\u01F9": "n",
48837  "\u0144": "n",
48838  "\xF1": "n",
48839  "\u1E45": "n",
48840  "\u0148": "n",
48841  "\u1E47": "n",
48842  "\u0146": "n",
48843  "\u1E4B": "n",
48844  "\u1E49": "n",
48845  "\u019E": "n",
48846  "\u0272": "n",
48847  "\u0149": "n",
48848  "\uA791": "n",
48849  "\uA7A5": "n",
48850  "\u01CC": "nj",
48851  "\u24DE": "o",
48852  "\uFF4F": "o",
48853  "\xF2": "o",
48854  "\xF3": "o",
48855  "\xF4": "o",
48856  "\u1ED3": "o",
48857  "\u1ED1": "o",
48858  "\u1ED7": "o",
48859  "\u1ED5": "o",
48860  "\xF5": "o",
48861  "\u1E4D": "o",
48862  "\u022D": "o",
48863  "\u1E4F": "o",
48864  "\u014D": "o",
48865  "\u1E51": "o",
48866  "\u1E53": "o",
48867  "\u014F": "o",
48868  "\u022F": "o",
48869  "\u0231": "o",
48870  "\xF6": "o",
48871  "\u022B": "o",
48872  "\u1ECF": "o",
48873  "\u0151": "o",
48874  "\u01D2": "o",
48875  "\u020D": "o",
48876  "\u020F": "o",
48877  "\u01A1": "o",
48878  "\u1EDD": "o",
48879  "\u1EDB": "o",
48880  "\u1EE1": "o",
48881  "\u1EDF": "o",
48882  "\u1EE3": "o",
48883  "\u1ECD": "o",
48884  "\u1ED9": "o",
48885  "\u01EB": "o",
48886  "\u01ED": "o",
48887  "\xF8": "o",
48888  "\u01FF": "o",
48889  "\u0254": "o",
48890  "\uA74B": "o",
48891  "\uA74D": "o",
48892  "\u0275": "o",
48893  "\u01A3": "oi",
48894  "\u0223": "ou",
48895  "\uA74F": "oo",
48896  "\u24DF": "p",
48897  "\uFF50": "p",
48898  "\u1E55": "p",
48899  "\u1E57": "p",
48900  "\u01A5": "p",
48901  "\u1D7D": "p",
48902  "\uA751": "p",
48903  "\uA753": "p",
48904  "\uA755": "p",
48905  "\u24E0": "q",
48906  "\uFF51": "q",
48907  "\u024B": "q",
48908  "\uA757": "q",
48909  "\uA759": "q",
48910  "\u24E1": "r",
48911  "\uFF52": "r",
48912  "\u0155": "r",
48913  "\u1E59": "r",
48914  "\u0159": "r",
48915  "\u0211": "r",
48916  "\u0213": "r",
48917  "\u1E5B": "r",
48918  "\u1E5D": "r",
48919  "\u0157": "r",
48920  "\u1E5F": "r",
48921  "\u024D": "r",
48922  "\u027D": "r",
48923  "\uA75B": "r",
48924  "\uA7A7": "r",
48925  "\uA783": "r",
48926  "\u24E2": "s",
48927  "\uFF53": "s",
48928  "\xDF": "s",
48929  "\u015B": "s",
48930  "\u1E65": "s",
48931  "\u015D": "s",
48932  "\u1E61": "s",
48933  "\u0161": "s",
48934  "\u1E67": "s",
48935  "\u1E63": "s",
48936  "\u1E69": "s",
48937  "\u0219": "s",
48938  "\u015F": "s",
48939  "\u023F": "s",
48940  "\uA7A9": "s",
48941  "\uA785": "s",
48942  "\u1E9B": "s",
48943  "\u24E3": "t",
48944  "\uFF54": "t",
48945  "\u1E6B": "t",
48946  "\u1E97": "t",
48947  "\u0165": "t",
48948  "\u1E6D": "t",
48949  "\u021B": "t",
48950  "\u0163": "t",
48951  "\u1E71": "t",
48952  "\u1E6F": "t",
48953  "\u0167": "t",
48954  "\u01AD": "t",
48955  "\u0288": "t",
48956  "\u2C66": "t",
48957  "\uA787": "t",
48958  "\uA729": "tz",
48959  "\u24E4": "u",
48960  "\uFF55": "u",
48961  "\xF9": "u",
48962  "\xFA": "u",
48963  "\xFB": "u",
48964  "\u0169": "u",
48965  "\u1E79": "u",
48966  "\u016B": "u",
48967  "\u1E7B": "u",
48968  "\u016D": "u",
48969  "\xFC": "u",
48970  "\u01DC": "u",
48971  "\u01D8": "u",
48972  "\u01D6": "u",
48973  "\u01DA": "u",
48974  "\u1EE7": "u",
48975  "\u016F": "u",
48976  "\u0171": "u",
48977  "\u01D4": "u",
48978  "\u0215": "u",
48979  "\u0217": "u",
48980  "\u01B0": "u",
48981  "\u1EEB": "u",
48982  "\u1EE9": "u",
48983  "\u1EEF": "u",
48984  "\u1EED": "u",
48985  "\u1EF1": "u",
48986  "\u1EE5": "u",
48987  "\u1E73": "u",
48988  "\u0173": "u",
48989  "\u1E77": "u",
48990  "\u1E75": "u",
48991  "\u0289": "u",
48992  "\u24E5": "v",
48993  "\uFF56": "v",
48994  "\u1E7D": "v",
48995  "\u1E7F": "v",
48996  "\u028B": "v",
48997  "\uA75F": "v",
48998  "\u028C": "v",
48999  "\uA761": "vy",
49000  "\u24E6": "w",
49001  "\uFF57": "w",
49002  "\u1E81": "w",
49003  "\u1E83": "w",
49004  "\u0175": "w",
49005  "\u1E87": "w",
49006  "\u1E85": "w",
49007  "\u1E98": "w",
49008  "\u1E89": "w",
49009  "\u2C73": "w",
49010  "\u24E7": "x",
49011  "\uFF58": "x",
49012  "\u1E8B": "x",
49013  "\u1E8D": "x",
49014  "\u24E8": "y",
49015  "\uFF59": "y",
49016  "\u1EF3": "y",
49017  "\xFD": "y",
49018  "\u0177": "y",
49019  "\u1EF9": "y",
49020  "\u0233": "y",
49021  "\u1E8F": "y",
49022  "\xFF": "y",
49023  "\u1EF7": "y",
49024  "\u1E99": "y",
49025  "\u1EF5": "y",
49026  "\u01B4": "y",
49027  "\u024F": "y",
49028  "\u1EFF": "y",
49029  "\u24E9": "z",
49030  "\uFF5A": "z",
49031  "\u017A": "z",
49032  "\u1E91": "z",
49033  "\u017C": "z",
49034  "\u017E": "z",
49035  "\u1E93": "z",
49036  "\u1E95": "z",
49037  "\u01B6": "z",
49038  "\u0225": "z",
49039  "\u0240": "z",
49040  "\u2C6C": "z",
49041  "\uA763": "z",
49042  "\u0386": "\u0391",
49043  "\u0388": "\u0395",
49044  "\u0389": "\u0397",
49045  "\u038A": "\u0399",
49046  "\u03AA": "\u0399",
49047  "\u038C": "\u039F",
49048  "\u038E": "\u03A5",
49049  "\u03AB": "\u03A5",
49050  "\u038F": "\u03A9",
49051  "\u03AC": "\u03B1",
49052  "\u03AD": "\u03B5",
49053  "\u03AE": "\u03B7",
49054  "\u03AF": "\u03B9",
49055  "\u03CA": "\u03B9",
49056  "\u0390": "\u03B9",
49057  "\u03CC": "\u03BF",
49058  "\u03CD": "\u03C5",
49059  "\u03CB": "\u03C5",
49060  "\u03B0": "\u03C5",
49061  "\u03C9": "\u03C9",
49062  "\u03C2": "\u03C3"
49063};
49064function stripSpecialChars(text2) {
49065  const match = (a) => diacritics[a] || a;
49066  return text2.replace(/[^\u0000-\u007E]/g, match);
49067}
49068var ItemsList = class {
49069  constructor(_ngSelect, _selectionModel) {
49070    this._ngSelect = _ngSelect;
49071    this._selectionModel = _selectionModel;
49072    this._items = [];
49073    this._filteredItems = [];
49074    this._markedIndex = -1;
49075  }
49076  get items() {
49077    return this._items;
49078  }
49079  get filteredItems() {
49080    return this._filteredItems;
49081  }
49082  get markedIndex() {
49083    return this._markedIndex;
49084  }
49085  get selectedItems() {
49086    return this._selectionModel.value;
49087  }
49088  get markedItem() {
49089    return this._filteredItems[this._markedIndex];
49090  }
49091  get noItemsToSelect() {
49092    return this._ngSelect.hideSelected && this._items.length === this.selectedItems.length;
49093  }
49094  get maxItemsSelected() {
49095    return this._ngSelect.multiple && this._ngSelect.maxSelectedItems <= this.selectedItems.length;
49096  }
49097  get lastSelectedItem() {
49098    let i = this.selectedItems.length - 1;
49099    for (; i >= 0; i--) {
49100      const item = this.selectedItems[i];
49101      if (!item.disabled) {
49102        return item;
49103      }
49104    }
49105    return null;
49106  }
49107  setItems(items) {
49108    this._items = items.map((item, index) => this.mapItem(item, index));
49109    if (this._ngSelect.groupBy) {
49110      this._groups = this._groupBy(this._items, this._ngSelect.groupBy);
49111      this._items = this._flatten(this._groups);
49112    } else {
49113      this._groups = /* @__PURE__ */ new Map();
49114      this._groups.set(void 0, this._items);
49115    }
49116    this._filteredItems = [...this._items];
49117  }
49118  select(item) {
49119    if (item.selected || this.maxItemsSelected) {
49120      return;
49121    }
49122    const multiple = this._ngSelect.multiple;
49123    if (!multiple) {
49124      this.clearSelected();
49125    }
49126    this._selectionModel.select(item, multiple, this._ngSelect.selectableGroupAsModel);
49127    if (this._ngSelect.hideSelected) {
49128      this._hideSelected(item);
49129    }
49130  }
49131  unselect(item) {
49132    if (!item.selected) {
49133      return;
49134    }
49135    this._selectionModel.unselect(item, this._ngSelect.multiple);
49136    if (this._ngSelect.hideSelected && isDefined2(item.index) && this._ngSelect.multiple) {
49137      this._showSelected(item);
49138    }
49139  }
49140  findItem(value) {
49141    let findBy;
49142    if (this._ngSelect.compareWith) {
49143      findBy = (item) => this._ngSelect.compareWith(item.value, value);
49144    } else if (this._ngSelect.bindValue) {
49145      findBy = (item) => !item.children && this.resolveNested(item.value, this._ngSelect.bindValue) === value;
49146    } else {
49147      findBy = (item) => item.value === value || !item.children && item.label && item.label === this.resolveNested(value, this._ngSelect.bindLabel);
49148    }
49149    return this._items.find((item) => findBy(item));
49150  }
49151  addItem(item) {
49152    const option = this.mapItem(item, this._items.length);
49153    this._items.push(option);
49154    this._filteredItems.push(option);
49155    return option;
49156  }
49157  clearSelected(keepDisabled = false) {
49158    this._selectionModel.clear(keepDisabled);
49159    this._items.forEach((item) => {
49160      item.selected = keepDisabled && item.selected && item.disabled;
49161      item.marked = false;
49162    });
49163    if (this._ngSelect.hideSelected) {
49164      this.resetFilteredItems();
49165    }
49166  }
49167  findByLabel(term) {
49168    term = stripSpecialChars(term).toLocaleLowerCase();
49169    return this.filteredItems.find((item) => {
49170      const label = stripSpecialChars(item.label).toLocaleLowerCase();
49171      return label.substr(0, term.length) === term;
49172    });
49173  }
49174  filter(term) {
49175    if (!term) {
49176      this.resetFilteredItems();
49177      return;
49178    }
49179    this._filteredItems = [];
49180    term = this._ngSelect.searchFn ? term : stripSpecialChars(term).toLocaleLowerCase();
49181    const match = this._ngSelect.searchFn || this._defaultSearchFn;
49182    const hideSelected = this._ngSelect.hideSelected;
49183    for (const key of Array.from(this._groups.keys())) {
49184      const matchedItems = [];
49185      for (const item of this._groups.get(key)) {
49186        if (hideSelected && (item.parent && item.parent.selected || item.selected)) {
49187          continue;
49188        }
49189        const searchItem = this._ngSelect.searchFn ? item.value : item;
49190        if (match(term, searchItem)) {
49191          matchedItems.push(item);
49192        }
49193      }
49194      if (matchedItems.length > 0) {
49195        const [last] = matchedItems.slice(-1);
49196        if (last.parent) {
49197          const head = this._items.find((x) => x === last.parent);
49198          this._filteredItems.push(head);
49199        }
49200        this._filteredItems.push(...matchedItems);
49201      }
49202    }
49203  }
49204  resetFilteredItems() {
49205    if (this._filteredItems.length === this._items.length) {
49206      return;
49207    }
49208    if (this._ngSelect.hideSelected && this.selectedItems.length > 0) {
49209      this._filteredItems = this._items.filter((x) => !x.selected);
49210    } else {
49211      this._filteredItems = this._items;
49212    }
49213  }
49214  unmarkItem() {
49215    this._markedIndex = -1;
49216  }
49217  markNextItem() {
49218    this._stepToItem(1);
49219  }
49220  markPreviousItem() {
49221    this._stepToItem(-1);
49222  }
49223  markItem(item) {
49224    this._markedIndex = this._filteredItems.indexOf(item);
49225  }
49226  markSelectedOrDefault(markDefault) {
49227    if (this._filteredItems.length === 0) {
49228      return;
49229    }
49230    const lastMarkedIndex = this._getLastMarkedIndex();
49231    if (lastMarkedIndex > -1) {
49232      this._markedIndex = lastMarkedIndex;
49233    } else {
49234      this._markedIndex = markDefault ? this.filteredItems.findIndex((x) => !x.disabled) : -1;
49235    }
49236  }
49237  resolveNested(option, key) {
49238    if (!isObject3(option)) {
49239      return option;
49240    }
49241    if (key.indexOf(".") === -1) {
49242      return option[key];
49243    } else {
49244      const keys = key.split(".");
49245      let value = option;
49246      for (let i = 0, len = keys.length; i < len; ++i) {
49247        if (value == null) {
49248          return null;
49249        }
49250        value = value[keys[i]];
49251      }
49252      return value;
49253    }
49254  }
49255  mapItem(item, index) {
49256    const label = isDefined2(item.$ngOptionLabel) ? item.$ngOptionLabel : this.resolveNested(item, this._ngSelect.bindLabel);
49257    const value = isDefined2(item.$ngOptionValue) ? item.$ngOptionValue : item;
49258    return {
49259      index,
49260      label: isDefined2(label) ? label.toString() : "",
49261      value,
49262      disabled: item.disabled,
49263      htmlId: `${this._ngSelect.dropdownId}-${index}`
49264    };
49265  }
49266  mapSelectedItems() {
49267    const multiple = this._ngSelect.multiple;
49268    for (const selected of this.selectedItems) {
49269      const value = this._ngSelect.bindValue ? this.resolveNested(selected.value, this._ngSelect.bindValue) : selected.value;
49270      const item = isDefined2(value) ? this.findItem(value) : null;
49271      this._selectionModel.unselect(selected, multiple);
49272      this._selectionModel.select(item || selected, multiple, this._ngSelect.selectableGroupAsModel);
49273    }
49274    if (this._ngSelect.hideSelected) {
49275      this._filteredItems = this.filteredItems.filter((x) => this.selectedItems.indexOf(x) === -1);
49276    }
49277  }
49278  _showSelected(item) {
49279    this._filteredItems.push(item);
49280    if (item.parent) {
49281      const parent = item.parent;
49282      const parentExists = this._filteredItems.find((x) => x === parent);
49283      if (!parentExists) {
49284        this._filteredItems.push(parent);
49285      }
49286    } else if (item.children) {
49287      for (const child of item.children) {
49288        child.selected = false;
49289        this._filteredItems.push(child);
49290      }
49291    }
49292    this._filteredItems = [...this._filteredItems.sort((a, b) => a.index - b.index)];
49293  }
49294  _hideSelected(item) {
49295    this._filteredItems = this._filteredItems.filter((x) => x !== item);
49296    if (item.parent) {
49297      const children = item.parent.children;
49298      if (children.every((x) => x.selected)) {
49299        this._filteredItems = this._filteredItems.filter((x) => x !== item.parent);
49300      }
49301    } else if (item.children) {
49302      this._filteredItems = this.filteredItems.filter((x) => x.parent !== item);
49303    }
49304  }
49305  _defaultSearchFn(search, opt) {
49306    const label = stripSpecialChars(opt.label).toLocaleLowerCase();
49307    return label.indexOf(search) > -1;
49308  }
49309  _getNextItemIndex(steps) {
49310    if (steps > 0) {
49311      return this._markedIndex >= this._filteredItems.length - 1 ? 0 : this._markedIndex + 1;
49312    }
49313    return this._markedIndex <= 0 ? this._filteredItems.length - 1 : this._markedIndex - 1;
49314  }
49315  _stepToItem(steps) {
49316    if (this._filteredItems.length === 0 || this._filteredItems.every((x) => x.disabled)) {
49317      return;
49318    }
49319    this._markedIndex = this._getNextItemIndex(steps);
49320    if (this.markedItem.disabled) {
49321      this._stepToItem(steps);
49322    }
49323  }
49324  _getLastMarkedIndex() {
49325    if (this._ngSelect.hideSelected) {
49326      return -1;
49327    }
49328    if (this._markedIndex > -1 && this.markedItem === void 0) {
49329      return -1;
49330    }
49331    const selectedIndex = this._filteredItems.indexOf(this.lastSelectedItem);
49332    if (this.lastSelectedItem && selectedIndex < 0) {
49333      return -1;
49334    }
49335    return Math.max(this.markedIndex, selectedIndex);
49336  }
49337  _groupBy(items, prop) {
49338    const groups = /* @__PURE__ */ new Map();
49339    if (items.length === 0) {
49340      return groups;
49341    }
49342    if (Array.isArray(items[0].value[prop])) {
49343      for (const item of items) {
49344        const children = (item.value[prop] || []).map((x, index) => this.mapItem(x, index));
49345        groups.set(item, children);
49346      }
49347      return groups;
49348    }
49349    const isFnKey = isFunction2(this._ngSelect.groupBy);
49350    const keyFn = (item) => {
49351      const key = isFnKey ? prop(item.value) : item.value[prop];
49352      return isDefined2(key) ? key : void 0;
49353    };
49354    for (const item of items) {
49355      const key = keyFn(item);
49356      const group = groups.get(key);
49357      if (group) {
49358        group.push(item);
49359      } else {
49360        groups.set(key, [item]);
49361      }
49362    }
49363    return groups;
49364  }
49365  _flatten(groups) {
49366    const isGroupByFn = isFunction2(this._ngSelect.groupBy);
49367    const items = [];
49368    for (const key of Array.from(groups.keys())) {
49369      let i = items.length;
49370      if (key === void 0) {
49371        const withoutGroup = groups.get(void 0) || [];
49372        items.push(...withoutGroup.map((x) => {
49373          x.index = i++;
49374          return x;
49375        }));
49376        continue;
49377      }
49378      const isObjectKey = isObject3(key);
49379      const parent = {
49380        label: isObjectKey ? "" : String(key),
49381        children: void 0,
49382        parent: null,
49383        index: i++,
49384        disabled: !this._ngSelect.selectableGroup,
49385        htmlId: newId()
49386      };
49387      const groupKey = isGroupByFn ? this._ngSelect.bindLabel : this._ngSelect.groupBy;
49388      const groupValue = this._ngSelect.groupValue || (() => {
49389        if (isObjectKey) {
49390          return key.value;
49391        }
49392        return {
49393          [groupKey]: key
49394        };
49395      });
49396      const children = groups.get(key).map((x) => {
49397        x.parent = parent;
49398        x.children = void 0;
49399        x.index = i++;
49400        return x;
49401      });
49402      parent.children = children;
49403      parent.value = groupValue(key, children.map((x) => x.value));
49404      items.push(parent);
49405      items.push(...children);
49406    }
49407    return items;
49408  }
49409};
49410var NgDropdownPanelService = class _NgDropdownPanelService {
49411  constructor() {
49412    this._dimensions = {
49413      itemHeight: 0,
49414      panelHeight: 0,
49415      itemsPerViewport: 0
49416    };
49417  }
49418  get dimensions() {
49419    return this._dimensions;
49420  }
49421  calculateItems(scrollPos, itemsLength, buffer) {
49422    const d = this._dimensions;
49423    const scrollHeight = d.itemHeight * itemsLength;
49424    const scrollTop = Math.max(0, scrollPos);
49425    const indexByScrollTop = scrollTop / scrollHeight * itemsLength;
49426    let end = Math.min(itemsLength, Math.ceil(indexByScrollTop) + (d.itemsPerViewport + 1));
49427    const maxStartEnd = end;
49428    const maxStart = Math.max(0, maxStartEnd - d.itemsPerViewport);
49429    let start = Math.min(maxStart, Math.floor(indexByScrollTop));
49430    let topPadding = d.itemHeight * Math.ceil(start) - d.itemHeight * Math.min(start, buffer);
49431    topPadding = !isNaN(topPadding) ? topPadding : 0;
49432    start = !isNaN(start) ? start : -1;
49433    end = !isNaN(end) ? end : -1;
49434    start -= buffer;
49435    start = Math.max(0, start);
49436    end += buffer;
49437    end = Math.min(itemsLength, end);
49438    return {
49439      topPadding,
49440      scrollHeight,
49441      start,
49442      end
49443    };
49444  }
49445  setDimensions(itemHeight, panelHeight) {
49446    const itemsPerViewport = Math.max(1, Math.floor(panelHeight / itemHeight));
49447    this._dimensions = {
49448      itemHeight,
49449      panelHeight,
49450      itemsPerViewport
49451    };
49452  }
49453  getScrollTo(itemTop, itemHeight, lastScroll) {
49454    const {
49455      panelHeight
49456    } = this.dimensions;
49457    const itemBottom = itemTop + itemHeight;
49458    const top = lastScroll;
49459    const bottom = top + panelHeight;
49460    if (panelHeight >= itemBottom && lastScroll === itemTop) {
49461      return null;
49462    }
49463    if (itemBottom > bottom) {
49464      return top + itemBottom - bottom;
49465    } else if (itemTop <= top) {
49466      return itemTop;
49467    }
49468    return null;
49469  }
49470  static {
49471    this.\u0275fac = function NgDropdownPanelService_Factory(__ngFactoryType__) {
49472      return new (__ngFactoryType__ || _NgDropdownPanelService)();
49473    };
49474  }
49475  static {
49476    this.\u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
49477      token: _NgDropdownPanelService,
49478      factory: _NgDropdownPanelService.\u0275fac
49479    });
49480  }
49481};
49482(() => {
49483  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgDropdownPanelService, [{
49484    type: Injectable
49485  }], null, null);
49486})();
49487var CSS_POSITIONS = ["top", "right", "bottom", "left"];
49488var SCROLL_SCHEDULER = typeof requestAnimationFrame !== "undefined" ? animationFrameScheduler : asapScheduler;
49489var NgDropdownPanelComponent = class _NgDropdownPanelComponent {
49490  constructor(_renderer, _zone, _panelService, _elementRef, _document) {
49491    this._renderer = _renderer;
49492    this._zone = _zone;
49493    this._panelService = _panelService;
49494    this._document = _document;
49495    this.items = [];
49496    this.position = "auto";
49497    this.virtualScroll = false;
49498    this.filterValue = null;
49499    this.update = new EventEmitter();
49500    this.scroll = new EventEmitter();
49501    this.scrollToEnd = new EventEmitter();
49502    this.outsideClick = new EventEmitter();
49503    this._destroy$ = new Subject();
49504    this._scrollToEndFired = false;
49505    this._updateScrollHeight = false;
49506    this._lastScrollPosition = 0;
49507    this._dropdown = _elementRef.nativeElement;
49508  }
49509  get currentPosition() {
49510    return this._currentPosition;
49511  }
49512  get itemsLength() {
49513    return this._itemsLength;
49514  }
49515  set itemsLength(value) {
49516    if (value !== this._itemsLength) {
49517      this._itemsLength = value;
49518      this._onItemsLengthChanged();
49519    }
49520  }
49521  get _startOffset() {
49522    if (this.markedItem) {
49523      const {
49524        itemHeight,
49525        panelHeight
49526      } = this._panelService.dimensions;
49527      const offset = this.markedItem.index * itemHeight;
49528      return panelHeight > offset ? 0 : offset;
49529    }
49530    return 0;
49531  }
49532  ngOnInit() {
49533    this._select = this._dropdown.parentElement;
49534    this._virtualPadding = this.paddingElementRef.nativeElement;
49535    this._scrollablePanel = this.scrollElementRef.nativeElement;
49536    this._contentPanel = this.contentElementRef.nativeElement;
49537    this._handleScroll();
49538    this._handleOutsideClick();
49539    this._appendDropdown();
49540    this._setupMousedownListener();
49541  }
49542  ngOnChanges(changes) {
49543    if (changes.items) {
49544      const change = changes.items;
49545      this._onItemsChange(change.currentValue, change.firstChange);
49546    }
49547  }
49548  ngOnDestroy() {
49549    this._destroy$.next();
49550    this._destroy$.complete();
49551    this._destroy$.unsubscribe();
49552    if (this.appendTo) {
49553      this._renderer.removeChild(this._dropdown.parentNode, this._dropdown);
49554    }
49555  }
49556  scrollTo(option, startFromOption = false) {
49557    if (!option) {
49558      return;
49559    }
49560    const index = this.items.indexOf(option);
49561    if (index < 0 || index >= this.itemsLength) {
49562      return;
49563    }
49564    let scrollTo;
49565    if (this.virtualScroll) {
49566      const itemHeight = this._panelService.dimensions.itemHeight;
49567      scrollTo = this._panelService.getScrollTo(index * itemHeight, itemHeight, this._lastScrollPosition);
49568    } else {
49569      const item = this._dropdown.querySelector(`#${option.htmlId}`);
49570      const lastScroll = startFromOption ? item.offsetTop : this._lastScrollPosition;
49571      scrollTo = this._panelService.getScrollTo(item.offsetTop, item.clientHeight, lastScroll);
49572    }
49573    if (isDefined2(scrollTo)) {
49574      this._scrollablePanel.scrollTop = scrollTo;
49575    }
49576  }
49577  scrollToTag() {
49578    const panel = this._scrollablePanel;
49579    panel.scrollTop = panel.scrollHeight - panel.clientHeight;
49580  }
49581  adjustPosition() {
49582    this._updateYPosition();
49583  }
49584  _handleDropdownPosition() {
49585    this._currentPosition = this._calculateCurrentPosition(this._dropdown);
49586    if (CSS_POSITIONS.includes(this._currentPosition)) {
49587      this._updateDropdownClass(this._currentPosition);
49588    } else {
49589      this._updateDropdownClass("bottom");
49590    }
49591    if (this.appendTo) {
49592      this._updateYPosition();
49593    }
49594    this._dropdown.style.opacity = "1";
49595  }
49596  _updateDropdownClass(currentPosition) {
49597    CSS_POSITIONS.forEach((position) => {
49598      const REMOVE_CSS_CLASS = `ng-select-${position}`;
49599      this._renderer.removeClass(this._dropdown, REMOVE_CSS_CLASS);
49600      this._renderer.removeClass(this._select, REMOVE_CSS_CLASS);
49601    });
49602    const ADD_CSS_CLASS = `ng-select-${currentPosition}`;
49603    this._renderer.addClass(this._dropdown, ADD_CSS_CLASS);
49604    this._renderer.addClass(this._select, ADD_CSS_CLASS);
49605  }
49606  _handleScroll() {
49607    this._zone.runOutsideAngular(() => {
49608      fromEvent(this.scrollElementRef.nativeElement, "scroll").pipe(takeUntil(this._destroy$), auditTime(0, SCROLL_SCHEDULER)).subscribe((e) => {
49609        const path2 = e.path || e.composedPath && e.composedPath();
49610        if (!path2 || path2.length === 0 && !e.target) {
49611          return;
49612        }
49613        const scrollTop = !path2 || path2.length === 0 ? e.target.scrollTop : path2[0].scrollTop;
49614        this._onContentScrolled(scrollTop);
49615      });
49616    });
49617  }
49618  _handleOutsideClick() {
49619    if (!this._document) {
49620      return;
49621    }
49622    this._zone.runOutsideAngular(() => {
49623      merge(fromEvent(this._document, "touchstart", {
49624        capture: true
49625      }), fromEvent(this._document, "click", {
49626        capture: true
49627      })).pipe(takeUntil(this._destroy$)).subscribe(($event) => this._checkToClose($event));
49628    });
49629  }
49630  _checkToClose($event) {
49631    if (this._select.contains($event.target) || this._dropdown.contains($event.target)) {
49632      return;
49633    }
49634    const path2 = $event.path || $event.composedPath && $event.composedPath();
49635    if ($event.target && $event.target.shadowRoot && path2 && path2[0] && this._select.contains(path2[0])) {
49636      return;
49637    }
49638    this._zone.run(() => this.outsideClick.emit());
49639  }
49640  _onItemsChange(items, firstChange) {
49641    this.items = items || [];
49642    this._scrollToEndFired = false;
49643    this.itemsLength = items.length;
49644    if (this.virtualScroll) {
49645      this._updateItemsRange(firstChange);
49646    } else {
49647      this._setVirtualHeight();
49648      this._updateItems(firstChange);
49649    }
49650  }
49651  _updateItems(firstChange) {
49652    this.update.emit(this.items);
49653    if (firstChange === false) {
49654      return;
49655    }
49656    this._zone.runOutsideAngular(() => {
49657      Promise.resolve().then(() => {
49658        const panelHeight = this._scrollablePanel.clientHeight;
49659        this._panelService.setDimensions(0, panelHeight);
49660        this._handleDropdownPosition();
49661        this.scrollTo(this.markedItem, firstChange);
49662      });
49663    });
49664  }
49665  _updateItemsRange(firstChange) {
49666    this._zone.runOutsideAngular(() => {
49667      this._measureDimensions().then(() => {
49668        if (firstChange) {
49669          this._renderItemsRange(this._startOffset);
49670          this._handleDropdownPosition();
49671        } else {
49672          this._renderItemsRange();
49673        }
49674      });
49675    });
49676  }
49677  _onContentScrolled(scrollTop) {
49678    if (this.virtualScroll) {
49679      this._renderItemsRange(scrollTop);
49680    }
49681    this._lastScrollPosition = scrollTop;
49682    this._fireScrollToEnd(scrollTop);
49683  }
49684  _updateVirtualHeight(height) {
49685    if (this._updateScrollHeight) {
49686      this._virtualPadding.style.height = `${height}px`;
49687      this._updateScrollHeight = false;
49688    }
49689  }
49690  _setVirtualHeight() {
49691    if (!this._virtualPadding) {
49692      return;
49693    }
49694    this._virtualPadding.style.height = `0px`;
49695  }
49696  _onItemsLengthChanged() {
49697    this._updateScrollHeight = true;
49698  }
49699  _renderItemsRange(scrollTop = null) {
49700    if (scrollTop && this._lastScrollPosition === scrollTop) {
49701      return;
49702    }
49703    scrollTop = scrollTop || this._scrollablePanel.scrollTop;
49704    const range = this._panelService.calculateItems(scrollTop, this.itemsLength, this.bufferAmount);
49705    this._updateVirtualHeight(range.scrollHeight);
49706    this._contentPanel.style.transform = `translateY(${range.topPadding}px)`;
49707    this._zone.run(() => {
49708      this.update.emit(this.items.slice(range.start, range.end));
49709      this.scroll.emit({
49710        start: range.start,
49711        end: range.end
49712      });
49713    });
49714    if (isDefined2(scrollTop) && this._lastScrollPosition === 0) {
49715      this._scrollablePanel.scrollTop = scrollTop;
49716      this._lastScrollPosition = scrollTop;
49717    }
49718  }
49719  _measureDimensions() {
49720    if (this._panelService.dimensions.itemHeight > 0 || this.itemsLength === 0) {
49721      return Promise.resolve(this._panelService.dimensions);
49722    }
49723    const [first] = this.items;
49724    this.update.emit([first]);
49725    return Promise.resolve().then(() => {
49726      const option = this._dropdown.querySelector(`#${first.htmlId}`);
49727      const optionHeight = option.clientHeight;
49728      this._virtualPadding.style.height = `${optionHeight * this.itemsLength}px`;
49729      const panelHeight = this._scrollablePanel.clientHeight;
49730      this._panelService.setDimensions(optionHeight, panelHeight);
49731      return this._panelService.dimensions;
49732    });
49733  }
49734  _fireScrollToEnd(scrollTop) {
49735    if (this._scrollToEndFired || scrollTop === 0) {
49736      return;
49737    }
49738    const padding = this.virtualScroll ? this._virtualPadding : this._contentPanel;
49739    if (scrollTop + this._dropdown.clientHeight >= padding.clientHeight - 1) {
49740      this._zone.run(() => this.scrollToEnd.emit());
49741      this._scrollToEndFired = true;
49742    }
49743  }
49744  _calculateCurrentPosition(dropdownEl) {
49745    if (this.position !== "auto") {
49746      return this.position;
49747    }
49748    const selectRect = this._select.getBoundingClientRect();
49749    const scrollTop = document.documentElement.scrollTop || document.body.scrollTop;
49750    const offsetTop = selectRect.top + window.pageYOffset;
49751    const height = selectRect.height;
49752    const dropdownHeight = dropdownEl.getBoundingClientRect().height;
49753    if (offsetTop + height + dropdownHeight > scrollTop + document.documentElement.clientHeight) {
49754      return "top";
49755    } else {
49756      return "bottom";
49757    }
49758  }
49759  _appendDropdown() {
49760    if (!this.appendTo) {
49761      return;
49762    }
49763    this._parent = document.querySelector(this.appendTo);
49764    if (!this._parent) {
49765      throw new Error(`appendTo selector ${this.appendTo} did not found any parent element`);
49766    }
49767    this._updateXPosition();
49768    this._parent.appendChild(this._dropdown);
49769  }
49770  _updateXPosition() {
49771    const select = this._select.getBoundingClientRect();
49772    const parent = this._parent.getBoundingClientRect();
49773    const offsetLeft = select.left - parent.left;
49774    this._dropdown.style.left = offsetLeft + "px";
49775    this._dropdown.style.width = select.width + "px";
49776    this._dropdown.style.minWidth = select.width + "px";
49777  }
49778  _updateYPosition() {
49779    const select = this._select.getBoundingClientRect();
49780    const parent = this._parent.getBoundingClientRect();
49781    const delta = select.height;
49782    if (this._currentPosition === "top") {
49783      const offsetBottom = parent.bottom - select.bottom;
49784      this._dropdown.style.bottom = offsetBottom + delta + "px";
49785      this._dropdown.style.top = "auto";
49786    } else if (this._currentPosition === "bottom") {
49787      const offsetTop = select.top - parent.top;
49788      this._dropdown.style.top = offsetTop + delta + "px";
49789      this._dropdown.style.bottom = "auto";
49790    }
49791  }
49792  _setupMousedownListener() {
49793    this._zone.runOutsideAngular(() => {
49794      fromEvent(this._dropdown, "mousedown").pipe(takeUntil(this._destroy$)).subscribe((event2) => {
49795        const target = event2.target;
49796        if (target.tagName === "INPUT") {
49797          return;
49798        }
49799        event2.preventDefault();
49800      });
49801    });
49802  }
49803  static {
49804    this.\u0275fac = function NgDropdownPanelComponent_Factory(__ngFactoryType__) {
49805      return new (__ngFactoryType__ || _NgDropdownPanelComponent)(\u0275\u0275directiveInject(Renderer2), \u0275\u0275directiveInject(NgZone), \u0275\u0275directiveInject(NgDropdownPanelService), \u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(DOCUMENT, 8));
49806    };
49807  }
49808  static {
49809    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({
49810      type: _NgDropdownPanelComponent,
49811      selectors: [["ng-dropdown-panel"]],
49812      viewQuery: function NgDropdownPanelComponent_Query(rf, ctx) {
49813        if (rf & 1) {
49814          \u0275\u0275viewQuery(_c03, 7, ElementRef);
49815          \u0275\u0275viewQuery(_c12, 7, ElementRef);
49816          \u0275\u0275viewQuery(_c22, 7, ElementRef);
49817        }
49818        if (rf & 2) {
49819          let _t;
49820          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.contentElementRef = _t.first);
49821          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.scrollElementRef = _t.first);
49822          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.paddingElementRef = _t.first);
49823        }
49824      },
49825      inputs: {
49826        items: "items",
49827        markedItem: "markedItem",
49828        position: "position",
49829        appendTo: "appendTo",
49830        bufferAmount: "bufferAmount",
49831        virtualScroll: [2, "virtualScroll", "virtualScroll", booleanAttribute],
49832        headerTemplate: "headerTemplate",
49833        footerTemplate: "footerTemplate",
49834        filterValue: "filterValue"
49835      },
49836      outputs: {
49837        update: "update",
49838        scroll: "scroll",
49839        scrollToEnd: "scrollToEnd",
49840        outsideClick: "outsideClick"
49841      },
49842      features: [\u0275\u0275NgOnChangesFeature],
49843      ngContentSelectors: _c32,
49844      decls: 9,
49845      vars: 6,
49846      consts: [["scroll", ""], ["padding", ""], ["content", ""], [1, "ng-dropdown-header"], ["role", "listbox", 1, "ng-dropdown-panel-items", "scroll-host"], [1, "ng-dropdown-footer"], [3, "ngTemplateOutlet", "ngTemplateOutletContext"]],
49847      template: function NgDropdownPanelComponent_Template(rf, ctx) {
49848        if (rf & 1) {
49849          \u0275\u0275projectionDef();
49850          \u0275\u0275template(0, NgDropdownPanelComponent_Conditional_0_Template, 2, 4, "div", 3);
49851          \u0275\u0275elementStart(1, "div", 4, 0);
49852          \u0275\u0275element(3, "div", null, 1);
49853          \u0275\u0275elementStart(5, "div", null, 2);
49854          \u0275\u0275projection(7);
49855          \u0275\u0275elementEnd()();
49856          \u0275\u0275template(8, NgDropdownPanelComponent_Conditional_8_Template, 2, 4, "div", 5);
49857        }
49858        if (rf & 2) {
49859          \u0275\u0275conditional(ctx.headerTemplate ? 0 : -1);
49860          \u0275\u0275advance(3);
49861          \u0275\u0275classProp("total-padding", ctx.virtualScroll);
49862          \u0275\u0275advance(2);
49863          \u0275\u0275classProp("scrollable-content", ctx.virtualScroll && ctx.items.length);
49864          \u0275\u0275advance(3);
49865          \u0275\u0275conditional(ctx.footerTemplate ? 8 : -1);
49866        }
49867      },
49868      dependencies: [NgTemplateOutlet],
49869      encapsulation: 2,
49870      changeDetection: 0
49871    });
49872  }
49873};
49874(() => {
49875  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgDropdownPanelComponent, [{
49876    type: Component,
49877    args: [{
49878      changeDetection: ChangeDetectionStrategy.OnPush,
49879      encapsulation: ViewEncapsulation.None,
49880      selector: "ng-dropdown-panel",
49881      template: `
49882		@if (headerTemplate) {
49883			<div class="ng-dropdown-header">
49884				<ng-container [ngTemplateOutlet]="headerTemplate" [ngTemplateOutletContext]="{ searchTerm: filterValue }" />
49885			</div>
49886		}
49887		<div #scroll role="listbox" class="ng-dropdown-panel-items scroll-host">
49888			<div #padding [class.total-padding]="virtualScroll"></div>
49889			<div #content [class.scrollable-content]="virtualScroll && items.length">
49890				<ng-content />
49891			</div>
49892		</div>
49893		@if (footerTemplate) {
49894			<div class="ng-dropdown-footer">
49895				<ng-container [ngTemplateOutlet]="footerTemplate" [ngTemplateOutletContext]="{ searchTerm: filterValue }" />
49896			</div>
49897		}
49898	`,
49899      imports: [NgTemplateOutlet]
49900    }]
49901  }], () => [{
49902    type: Renderer2
49903  }, {
49904    type: NgZone
49905  }, {
49906    type: NgDropdownPanelService
49907  }, {
49908    type: ElementRef
49909  }, {
49910    type: void 0,
49911    decorators: [{
49912      type: Optional
49913    }, {
49914      type: Inject,
49915      args: [DOCUMENT]
49916    }]
49917  }], {
49918    items: [{
49919      type: Input
49920    }],
49921    markedItem: [{
49922      type: Input
49923    }],
49924    position: [{
49925      type: Input
49926    }],
49927    appendTo: [{
49928      type: Input
49929    }],
49930    bufferAmount: [{
49931      type: Input
49932    }],
49933    virtualScroll: [{
49934      type: Input,
49935      args: [{
49936        transform: booleanAttribute
49937      }]
49938    }],
49939    headerTemplate: [{
49940      type: Input
49941    }],
49942    footerTemplate: [{
49943      type: Input
49944    }],
49945    filterValue: [{
49946      type: Input
49947    }],
49948    update: [{
49949      type: Output
49950    }],
49951    scroll: [{
49952      type: Output
49953    }],
49954    scrollToEnd: [{
49955      type: Output
49956    }],
49957    outsideClick: [{
49958      type: Output
49959    }],
49960    contentElementRef: [{
49961      type: ViewChild,
49962      args: ["content", {
49963        read: ElementRef,
49964        static: true
49965      }]
49966    }],
49967    scrollElementRef: [{
49968      type: ViewChild,
49969      args: ["scroll", {
49970        read: ElementRef,
49971        static: true
49972      }]
49973    }],
49974    paddingElementRef: [{
49975      type: ViewChild,
49976      args: ["padding", {
49977        read: ElementRef,
49978        static: true
49979      }]
49980    }]
49981  });
49982})();
49983var NgOptionComponent = class _NgOptionComponent {
49984  constructor(elementRef) {
49985    this.elementRef = elementRef;
49986    this.disabled = false;
49987    this.stateChange$ = new Subject();
49988  }
49989  get label() {
49990    return (this.elementRef.nativeElement.textContent || "").trim();
49991  }
49992  ngOnChanges(changes) {
49993    if (changes.disabled) {
49994      this.stateChange$.next({
49995        value: this.value,
49996        disabled: this.disabled
49997      });
49998    }
49999  }
50000  ngAfterViewChecked() {
50001    if (this.label !== this._previousLabel) {
50002      this._previousLabel = this.label;
50003      this.stateChange$.next({
50004        value: this.value,
50005        disabled: this.disabled,
50006        label: this.elementRef.nativeElement.innerHTML
50007      });
50008    }
50009  }
50010  ngOnDestroy() {
50011    this.stateChange$.complete();
50012  }
50013  static {
50014    this.\u0275fac = function NgOptionComponent_Factory(__ngFactoryType__) {
50015      return new (__ngFactoryType__ || _NgOptionComponent)(\u0275\u0275directiveInject(ElementRef));
50016    };
50017  }
50018  static {
50019    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({
50020      type: _NgOptionComponent,
50021      selectors: [["ng-option"]],
50022      inputs: {
50023        value: "value",
50024        disabled: [2, "disabled", "disabled", booleanAttribute]
50025      },
50026      features: [\u0275\u0275NgOnChangesFeature],
50027      ngContentSelectors: _c32,
50028      decls: 1,
50029      vars: 0,
50030      template: function NgOptionComponent_Template(rf, ctx) {
50031        if (rf & 1) {
50032          \u0275\u0275projectionDef();
50033          \u0275\u0275projection(0);
50034        }
50035      },
50036      encapsulation: 2,
50037      changeDetection: 0
50038    });
50039  }
50040};
50041(() => {
50042  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgOptionComponent, [{
50043    type: Component,
50044    args: [{
50045      selector: "ng-option",
50046      standalone: true,
50047      changeDetection: ChangeDetectionStrategy.OnPush,
50048      template: `<ng-content />`
50049    }]
50050  }], () => [{
50051    type: ElementRef
50052  }], {
50053    value: [{
50054      type: Input
50055    }],
50056    disabled: [{
50057      type: Input,
50058      args: [{
50059        transform: booleanAttribute
50060      }]
50061    }]
50062  });
50063})();
50064var KeyCode;
50065(function(KeyCode2) {
50066  KeyCode2[KeyCode2["Tab"] = 9] = "Tab";
50067  KeyCode2[KeyCode2["Enter"] = 13] = "Enter";
50068  KeyCode2[KeyCode2["Esc"] = 27] = "Esc";
50069  KeyCode2[KeyCode2["Space"] = 32] = "Space";
50070  KeyCode2[KeyCode2["ArrowUp"] = 38] = "ArrowUp";
50071  KeyCode2[KeyCode2["ArrowDown"] = 40] = "ArrowDown";
50072  KeyCode2[KeyCode2["Backspace"] = 8] = "Backspace";
50073})(KeyCode || (KeyCode = {}));
50074function DefaultSelectionModelFactory() {
50075  return new DefaultSelectionModel();
50076}
50077var DefaultSelectionModel = class {
50078  constructor() {
50079    this._selected = [];
50080  }
50081  get value() {
50082    return this._selected;
50083  }
50084  select(item, multiple, groupAsModel) {
50085    item.selected = true;
50086    if (!item.children || !multiple && groupAsModel) {
50087      this._selected.push(item);
50088    }
50089    if (multiple) {
50090      if (item.parent) {
50091        const childrenCount = item.parent.children.length;
50092        const selectedCount = item.parent.children.filter((x) => x.selected).length;
50093        item.parent.selected = childrenCount === selectedCount;
50094      } else if (item.children) {
50095        this._setChildrenSelectedState(item.children, true);
50096        this._removeChildren(item);
50097        if (groupAsModel && this._activeChildren(item)) {
50098          this._selected = [...this._selected.filter((x) => x.parent !== item), item];
50099        } else {
50100          this._selected = [...this._selected, ...item.children.filter((x) => !x.disabled)];
50101        }
50102      }
50103    }
50104  }
50105  unselect(item, multiple) {
50106    this._selected = this._selected.filter((x) => x !== item);
50107    item.selected = false;
50108    if (multiple) {
50109      if (item.parent && item.parent.selected) {
50110        const children = item.parent.children;
50111        this._removeParent(item.parent);
50112        this._removeChildren(item.parent);
50113        this._selected.push(...children.filter((x) => x !== item && !x.disabled));
50114        item.parent.selected = false;
50115      } else if (item.children) {
50116        this._setChildrenSelectedState(item.children, false);
50117        this._removeChildren(item);
50118      }
50119    }
50120  }
50121  clear(keepDisabled) {
50122    this._selected = keepDisabled ? this._selected.filter((x) => x.disabled) : [];
50123  }
50124  _setChildrenSelectedState(children, selected) {
50125    for (const child of children) {
50126      if (child.disabled) {
50127        continue;
50128      }
50129      child.selected = selected;
50130    }
50131  }
50132  _removeChildren(parent) {
50133    this._selected = [...this._selected.filter((x) => x.parent !== parent), ...parent.children.filter((x) => x.parent === parent && x.disabled && x.selected)];
50134  }
50135  _removeParent(parent) {
50136    this._selected = this._selected.filter((x) => x !== parent);
50137  }
50138  _activeChildren(item) {
50139    return item.children.every((x) => !x.disabled || x.selected);
50140  }
50141};
50142var NgSelectConfig = class _NgSelectConfig {
50143  constructor() {
50144    this.fixedPlaceholder = false;
50145    this.notFoundText = "No items found";
50146    this.typeToSearchText = "Type to search";
50147    this.addTagText = "Add item";
50148    this.loadingText = "Loading...";
50149    this.clearAllText = "Clear all";
50150    this.disableVirtualScroll = true;
50151    this.openOnEnter = true;
50152    this.appearance = "underline";
50153  }
50154  static {
50155    this.\u0275fac = function NgSelectConfig_Factory(__ngFactoryType__) {
50156      return new (__ngFactoryType__ || _NgSelectConfig)();
50157    };
50158  }
50159  static {
50160    this.\u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
50161      token: _NgSelectConfig,
50162      factory: _NgSelectConfig.\u0275fac,
50163      providedIn: "root"
50164    });
50165  }
50166};
50167(() => {
50168  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgSelectConfig, [{
50169    type: Injectable,
50170    args: [{
50171      providedIn: "root"
50172    }]
50173  }], null, null);
50174})();
50175var ConsoleService = class _ConsoleService {
50176  warn(message) {
50177    console.warn(message);
50178  }
50179  static {
50180    this.\u0275fac = function ConsoleService_Factory(__ngFactoryType__) {
50181      return new (__ngFactoryType__ || _ConsoleService)();
50182    };
50183  }
50184  static {
50185    this.\u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
50186      token: _ConsoleService,
50187      factory: _ConsoleService.\u0275fac,
50188      providedIn: "root"
50189    });
50190  }
50191};
50192(() => {
50193  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(ConsoleService, [{
50194    type: Injectable,
50195    args: [{
50196      providedIn: "root"
50197    }]
50198  }], null, null);
50199})();
50200var SELECTION_MODEL_FACTORY = new InjectionToken("ng-select-selection-model");
50201var NgSelectComponent = class _NgSelectComponent {
50202  constructor(classes2, autoFocus, config, newSelectionModel, _elementRef, _cd, _console) {
50203    this.classes = classes2;
50204    this.autoFocus = autoFocus;
50205    this.config = config;
50206    this._cd = _cd;
50207    this._console = _console;
50208    this.ariaLabelDropdown = "Options List";
50209    this.markFirst = true;
50210    this.fixedPlaceholder = false;
50211    this.preventToggleOnRightClick = false;
50212    this.dropdownPosition = "auto";
50213    this.loading = false;
50214    this.closeOnSelect = true;
50215    this.hideSelected = false;
50216    this.selectOnTab = false;
50217    this.bufferAmount = 4;
50218    this.selectableGroup = false;
50219    this.selectableGroupAsModel = true;
50220    this.searchFn = null;
50221    this.trackByFn = null;
50222    this.clearOnBackspace = true;
50223    this.labelForId = null;
50224    this.inputAttrs = {};
50225    this.readonly = false;
50226    this.searchWhileComposing = true;
50227    this.minTermLength = 0;
50228    this.editableSearchTerm = false;
50229    this.ngClass = null;
50230    this.multiple = false;
50231    this.addTag = false;
50232    this.searchable = true;
50233    this.clearable = true;
50234    this.isOpen = false;
50235    this.blurEvent = new EventEmitter();
50236    this.focusEvent = new EventEmitter();
50237    this.changeEvent = new EventEmitter();
50238    this.openEvent = new EventEmitter();
50239    this.closeEvent = new EventEmitter();
50240    this.searchEvent = new EventEmitter();
50241    this.clearEvent = new EventEmitter();
50242    this.addEvent = new EventEmitter();
50243    this.removeEvent = new EventEmitter();
50244    this.scroll = new EventEmitter();
50245    this.scrollToEnd = new EventEmitter();
50246    this.useDefaultClass = true;
50247    this.viewPortItems = [];
50248    this.searchTerm = null;
50249    this.dropdownId = newId();
50250    this.escapeHTML = true;
50251    this._defaultLabel = "label";
50252    this._pressedKeys = [];
50253    this._isComposing = false;
50254    this._destroy$ = new Subject();
50255    this._keyPress$ = new Subject();
50256    this._items = [];
50257    this.keyDownFn = (_2) => true;
50258    this.clearItem = (item) => {
50259      const option = this.selectedItems.find((x) => x.value === item);
50260      this.unselect(option);
50261    };
50262    this.trackByOption = (_2, item) => {
50263      if (this.trackByFn) {
50264        return this.trackByFn(item.value);
50265      }
50266      return item;
50267    };
50268    this._onChange = (_2) => {
50269    };
50270    this._onTouched = () => {
50271    };
50272    this._mergeGlobalConfig(config);
50273    this.itemsList = new ItemsList(this, newSelectionModel ? newSelectionModel() : DefaultSelectionModelFactory());
50274    this.element = _elementRef.nativeElement;
50275  }
50276  get filtered() {
50277    return !!this.searchTerm && this.searchable || this._isComposing;
50278  }
50279  get single() {
50280    return !this.multiple;
50281  }
50282  get items() {
50283    return this._items;
50284  }
50285  set items(value) {
50286    this._itemsAreUsed = true;
50287    this._items = value ?? [];
50288  }
50289  get disabled() {
50290    return this.readonly || this._disabled;
50291  }
50292  get compareWith() {
50293    return this._compareWith;
50294  }
50295  set compareWith(fn) {
50296    if (fn !== void 0 && fn !== null && !isFunction2(fn)) {
50297      throw Error("`compareWith` must be a function.");
50298    }
50299    this._compareWith = fn;
50300  }
50301  get clearSearchOnAdd() {
50302    if (isDefined2(this._clearSearchOnAdd)) {
50303      return this._clearSearchOnAdd;
50304    } else if (isDefined2(this.config.clearSearchOnAdd)) {
50305      return this.config.clearSearchOnAdd;
50306    }
50307    return this.closeOnSelect;
50308  }
50309  set clearSearchOnAdd(value) {
50310    this._clearSearchOnAdd = value;
50311  }
50312  get deselectOnClick() {
50313    if (isDefined2(this._deselectOnClick)) {
50314      return this._deselectOnClick;
50315    } else if (isDefined2(this.config.deselectOnClick)) {
50316      return this.config.deselectOnClick;
50317    }
50318    return this.multiple;
50319  }
50320  set deselectOnClick(value) {
50321    this._deselectOnClick = value;
50322  }
50323  get selectedItems() {
50324    return this.itemsList.selectedItems;
50325  }
50326  get selectedValues() {
50327    return this.selectedItems.map((x) => x.value);
50328  }
50329  get hasValue() {
50330    return this.selectedItems.length > 0;
50331  }
50332  get currentPanelPosition() {
50333    if (this.dropdownPanel) {
50334      return this.dropdownPanel.currentPosition;
50335    }
50336    return void 0;
50337  }
50338  get showAddTag() {
50339    if (!this._validTerm) {
50340      return false;
50341    }
50342    const term = this.searchTerm.toLowerCase().trim();
50343    return this.addTag && !this.itemsList.filteredItems.some((x) => x.label.toLowerCase() === term) && (!this.hideSelected && this.isOpen || !this.selectedItems.some((x) => x.label.toLowerCase() === term)) && !this.loading;
50344  }
50345  get _editableSearchTerm() {
50346    return this.editableSearchTerm && !this.multiple;
50347  }
50348  get _isTypeahead() {
50349    return this.typeahead && this.typeahead.observers.length > 0;
50350  }
50351  get _validTerm() {
50352    const term = this.searchTerm && this.searchTerm.trim();
50353    return term && term.length >= this.minTermLength;
50354  }
50355  ngOnInit() {
50356    this._handleKeyPresses();
50357    this._setInputAttributes();
50358  }
50359  ngOnChanges(changes) {
50360    if (changes.multiple) {
50361      this.itemsList.clearSelected();
50362    }
50363    if (changes.items) {
50364      this._setItems(changes.items.currentValue || []);
50365    }
50366    if (changes.isOpen) {
50367      this._manualOpen = isDefined2(changes.isOpen.currentValue);
50368    }
50369  }
50370  ngAfterViewInit() {
50371    if (!this._itemsAreUsed) {
50372      this.escapeHTML = false;
50373      this._setItemsFromNgOptions();
50374    }
50375    if (isDefined2(this.autoFocus)) {
50376      this.focus();
50377    }
50378  }
50379  ngOnDestroy() {
50380    this._destroy$.next();
50381    this._destroy$.complete();
50382  }
50383  handleKeyDown($event) {
50384    const keyCode = KeyCode[$event.which];
50385    if (keyCode) {
50386      if (this.keyDownFn($event) === false) {
50387        return;
50388      }
50389      this.handleKeyCode($event);
50390    } else if ($event.key && $event.key.length === 1) {
50391      this._keyPress$.next($event.key.toLocaleLowerCase());
50392    }
50393  }
50394  handleKeyCode($event) {
50395    const target = $event.target;
50396    if (this.clearButton && this.clearButton.nativeElement === target) {
50397      this.handleKeyCodeClear($event);
50398    } else {
50399      this.handleKeyCodeInput($event);
50400    }
50401  }
50402  handleKeyCodeInput($event) {
50403    switch ($event.which) {
50404      case KeyCode.ArrowDown:
50405        this._handleArrowDown($event);
50406        break;
50407      case KeyCode.ArrowUp:
50408        this._handleArrowUp($event);
50409        break;
50410      case KeyCode.Space:
50411        this._handleSpace($event);
50412        break;
50413      case KeyCode.Enter:
50414        this._handleEnter($event);
50415        break;
50416      case KeyCode.Tab:
50417        this._handleTab($event);
50418        break;
50419      case KeyCode.Esc:
50420        this.close();
50421        $event.preventDefault();
50422        break;
50423      case KeyCode.Backspace:
50424        this._handleBackspace();
50425        break;
50426    }
50427  }
50428  handleKeyCodeClear($event) {
50429    switch ($event.which) {
50430      case KeyCode.Enter:
50431        this.handleClearClick();
50432        $event.preventDefault();
50433        break;
50434    }
50435  }
50436  handleMousedown($event) {
50437    if (this.preventToggleOnRightClick && $event.button === 2) {
50438      return false;
50439    }
50440    const target = $event.target;
50441    if (target.tagName !== "INPUT") {
50442      $event.preventDefault();
50443    }
50444    if (target.classList.contains("ng-clear-wrapper")) {
50445      this.handleClearClick();
50446      return;
50447    }
50448    if (target.classList.contains("ng-arrow-wrapper")) {
50449      this.handleArrowClick();
50450      return;
50451    }
50452    if (target.classList.contains("ng-value-icon")) {
50453      return;
50454    }
50455    if (!this.focused) {
50456      this.focus();
50457    }
50458    if (this.searchable) {
50459      this.open();
50460    } else {
50461      this.toggle();
50462    }
50463  }
50464  handleArrowClick() {
50465    if (this.isOpen) {
50466      this.close();
50467    } else {
50468      this.open();
50469    }
50470  }
50471  handleClearClick() {
50472    if (this.hasValue) {
50473      this.itemsList.clearSelected(true);
50474      this._updateNgModel();
50475    }
50476    this._clearSearch();
50477    this.focus();
50478    this.clearEvent.emit();
50479    this._onSelectionChanged();
50480  }
50481  clearModel() {
50482    if (!this.clearable) {
50483      return;
50484    }
50485    this.itemsList.clearSelected();
50486    this._updateNgModel();
50487  }
50488  writeValue(value) {
50489    this.itemsList.clearSelected();
50490    this._handleWriteValue(value);
50491    this._cd.markForCheck();
50492  }
50493  registerOnChange(fn) {
50494    this._onChange = fn;
50495  }
50496  registerOnTouched(fn) {
50497    this._onTouched = fn;
50498  }
50499  setDisabledState(state) {
50500    this._disabled = state;
50501    this._cd.markForCheck();
50502  }
50503  toggle() {
50504    if (!this.isOpen) {
50505      this.open();
50506    } else {
50507      this.close();
50508    }
50509  }
50510  open() {
50511    if (this.disabled || this.isOpen || this._manualOpen) {
50512      return;
50513    }
50514    if (!this._isTypeahead && !this.addTag && this.itemsList.noItemsToSelect) {
50515      return;
50516    }
50517    this.isOpen = true;
50518    this.itemsList.markSelectedOrDefault(this.markFirst);
50519    this.openEvent.emit();
50520    if (!this.searchTerm) {
50521      this.focus();
50522    }
50523    this.detectChanges();
50524  }
50525  close() {
50526    if (!this.isOpen || this._manualOpen) {
50527      return;
50528    }
50529    this.isOpen = false;
50530    this._isComposing = false;
50531    if (!this._editableSearchTerm) {
50532      this._clearSearch();
50533    } else {
50534      this.itemsList.resetFilteredItems();
50535    }
50536    this.itemsList.unmarkItem();
50537    this._onTouched();
50538    this.closeEvent.emit();
50539    this._cd.markForCheck();
50540  }
50541  toggleItem(item) {
50542    if (!item || item.disabled || this.disabled) {
50543      return;
50544    }
50545    if (this.deselectOnClick && item.selected) {
50546      this.unselect(item);
50547    } else {
50548      this.select(item);
50549    }
50550    if (this._editableSearchTerm) {
50551      this._setSearchTermFromItems();
50552    }
50553  }
50554  select(item) {
50555    if (!item.selected) {
50556      this.itemsList.select(item);
50557      if (this.clearSearchOnAdd && !this._editableSearchTerm) {
50558        this._clearSearch();
50559      }
50560      this._updateNgModel();
50561      if (this.multiple) {
50562        this.addEvent.emit(item.value);
50563      }
50564    }
50565    if (this.closeOnSelect || this.itemsList.noItemsToSelect) {
50566      this.close();
50567    }
50568    this._onSelectionChanged();
50569  }
50570  focus() {
50571    this.searchInput.nativeElement.focus();
50572  }
50573  blur() {
50574    this.searchInput.nativeElement.blur();
50575  }
50576  unselect(item) {
50577    if (!item) {
50578      return;
50579    }
50580    this.itemsList.unselect(item);
50581    this.focus();
50582    this._updateNgModel();
50583    this.removeEvent.emit(item.value);
50584    this._onSelectionChanged();
50585  }
50586  selectTag() {
50587    let tag2;
50588    if (isFunction2(this.addTag)) {
50589      tag2 = this.addTag(this.searchTerm);
50590    } else {
50591      tag2 = this._primitive ? this.searchTerm : {
50592        [this.bindLabel]: this.searchTerm
50593      };
50594    }
50595    const handleTag = (item) => this._isTypeahead || !this.isOpen ? this.itemsList.mapItem(item, null) : this.itemsList.addItem(item);
50596    if (isPromise2(tag2)) {
50597      tag2.then((item) => this.select(handleTag(item))).catch(() => {
50598      });
50599    } else if (tag2) {
50600      this.select(handleTag(tag2));
50601    }
50602  }
50603  showClear() {
50604    return this.clearable && (this.hasValue || this.searchTerm) && !this.disabled;
50605  }
50606  focusOnClear() {
50607    this.blur();
50608    if (this.clearButton) {
50609      this.clearButton.nativeElement.focus();
50610    }
50611  }
50612  showNoItemsFound() {
50613    const empty = this.itemsList.filteredItems.length === 0;
50614    return (empty && !this._isTypeahead && !this.loading || empty && this._isTypeahead && this._validTerm && !this.loading) && !this.showAddTag;
50615  }
50616  showTypeToSearch() {
50617    const empty = this.itemsList.filteredItems.length === 0;
50618    return empty && this._isTypeahead && !this._validTerm && !this.loading;
50619  }
50620  onCompositionStart() {
50621    this._isComposing = true;
50622  }
50623  onCompositionEnd(term) {
50624    this._isComposing = false;
50625    if (this.searchWhileComposing) {
50626      return;
50627    }
50628    this.filter(term);
50629  }
50630  filter(term) {
50631    if (this._isComposing && !this.searchWhileComposing) {
50632      return;
50633    }
50634    this.searchTerm = term;
50635    if (this._isTypeahead && (this._validTerm || this.minTermLength === 0)) {
50636      this.typeahead.next(term);
50637    }
50638    if (!this._isTypeahead) {
50639      this.itemsList.filter(this.searchTerm);
50640      if (this.isOpen) {
50641        this.itemsList.markSelectedOrDefault(this.markFirst);
50642      }
50643    }
50644    this.searchEvent.emit({
50645      term,
50646      items: this.itemsList.filteredItems.map((x) => x.value)
50647    });
50648    this.open();
50649  }
50650  onInputFocus($event) {
50651    if (this.focused) {
50652      return;
50653    }
50654    if (this._editableSearchTerm) {
50655      this._setSearchTermFromItems();
50656    }
50657    this.element.classList.add("ng-select-focused");
50658    this.focusEvent.emit($event);
50659    this.focused = true;
50660  }
50661  onInputBlur($event) {
50662    this.element.classList.remove("ng-select-focused");
50663    this.blurEvent.emit($event);
50664    if (!this.isOpen && !this.disabled) {
50665      this._onTouched();
50666    }
50667    if (this._editableSearchTerm) {
50668      this._setSearchTermFromItems();
50669    }
50670    this.focused = false;
50671  }
50672  onItemHover(item) {
50673    if (item.disabled) {
50674      return;
50675    }
50676    this.itemsList.markItem(item);
50677  }
50678  detectChanges() {
50679    if (!this._cd.destroyed) {
50680      this._cd.detectChanges();
50681    }
50682  }
50683  _setSearchTermFromItems() {
50684    const selected = this.selectedItems && this.selectedItems[0];
50685    this.searchTerm = selected && selected.label || null;
50686  }
50687  _setItems(items) {
50688    const firstItem = items[0];
50689    this.bindLabel = this.bindLabel || this._defaultLabel;
50690    this._primitive = isDefined2(firstItem) ? !isObject3(firstItem) : this._primitive || this.bindLabel === this._defaultLabel;
50691    this.itemsList.setItems(items);
50692    if (items.length > 0 && this.hasValue) {
50693      this.itemsList.mapSelectedItems();
50694    }
50695    if (this.isOpen && isDefined2(this.searchTerm) && !this._isTypeahead) {
50696      this.itemsList.filter(this.searchTerm);
50697    }
50698    if (this._isTypeahead || this.isOpen) {
50699      this.itemsList.markSelectedOrDefault(this.markFirst);
50700    }
50701  }
50702  _setItemsFromNgOptions() {
50703    const mapNgOptions = (options2) => {
50704      this.items = options2.map((option) => ({
50705        $ngOptionValue: option.value,
50706        $ngOptionLabel: option.elementRef.nativeElement.innerHTML,
50707        disabled: option.disabled
50708      }));
50709      this.itemsList.setItems(this.items);
50710      if (this.hasValue) {
50711        this.itemsList.mapSelectedItems();
50712      }
50713      this.detectChanges();
50714    };
50715    const handleOptionChange = () => {
50716      const changedOrDestroyed = merge(this.ngOptions.changes, this._destroy$);
50717      merge(...this.ngOptions.map((option) => option.stateChange$)).pipe(takeUntil(changedOrDestroyed)).subscribe((option) => {
50718        const item = this.itemsList.findItem(option.value);
50719        item.disabled = option.disabled;
50720        item.label = option.label || item.label;
50721        this._cd.detectChanges();
50722      });
50723    };
50724    this.ngOptions.changes.pipe(startWith(this.ngOptions), takeUntil(this._destroy$)).subscribe((options2) => {
50725      this.bindLabel = this._defaultLabel;
50726      mapNgOptions(options2);
50727      handleOptionChange();
50728    });
50729  }
50730  _isValidWriteValue(value) {
50731    if (!isDefined2(value) || this.multiple && value === "" || Array.isArray(value) && value.length === 0) {
50732      return false;
50733    }
50734    const validateBinding = (item) => {
50735      if (!isDefined2(this.compareWith) && isObject3(item) && this.bindValue) {
50736        this._console.warn(`Setting object(${JSON.stringify(item)}) as your model with bindValue is not allowed unless [compareWith] is used.`);
50737        return false;
50738      }
50739      return true;
50740    };
50741    if (this.multiple) {
50742      if (!Array.isArray(value)) {
50743        this._console.warn("Multiple select ngModel should be array.");
50744        return false;
50745      }
50746      return value.every((item) => validateBinding(item));
50747    } else {
50748      return validateBinding(value);
50749    }
50750  }
50751  _handleWriteValue(ngModel) {
50752    if (!this._isValidWriteValue(ngModel)) {
50753      return;
50754    }
50755    const select = (val) => {
50756      let item = this.itemsList.findItem(val);
50757      if (item) {
50758        this.itemsList.select(item);
50759      } else {
50760        const isValObject = isObject3(val);
50761        const isPrimitive = !isValObject && !this.bindValue;
50762        if (isValObject || isPrimitive) {
50763          this.itemsList.select(this.itemsList.mapItem(val, null));
50764        } else if (this.bindValue) {
50765          item = {
50766            [this.bindLabel]: null,
50767            [this.bindValue]: val
50768          };
50769          this.itemsList.select(this.itemsList.mapItem(item, null));
50770        }
50771      }
50772    };
50773    if (this.multiple) {
50774      ngModel.forEach((item) => select(item));
50775    } else {
50776      select(ngModel);
50777    }
50778  }
50779  _handleKeyPresses() {
50780    if (this.searchable) {
50781      return;
50782    }
50783    this._keyPress$.pipe(takeUntil(this._destroy$), tap((letter) => this._pressedKeys.push(letter)), debounceTime(200), filter(() => this._pressedKeys.length > 0), map(() => this._pressedKeys.join(""))).subscribe((term) => {
50784      const item = this.itemsList.findByLabel(term);
50785      if (item) {
50786        if (this.isOpen) {
50787          this.itemsList.markItem(item);
50788          this._scrollToMarked();
50789          this._cd.markForCheck();
50790        } else {
50791          this.select(item);
50792        }
50793      }
50794      this._pressedKeys = [];
50795    });
50796  }
50797  _setInputAttributes() {
50798    const input2 = this.searchInput.nativeElement;
50799    const attributes = __spreadValues({
50800      type: "text",
50801      autocorrect: "off",
50802      autocapitalize: "off",
50803      autocomplete: this.labelForId ? "off" : this.dropdownId
50804    }, this.inputAttrs);
50805    for (const key of Object.keys(attributes)) {
50806      input2.setAttribute(key, attributes[key]);
50807    }
50808  }
50809  _updateNgModel() {
50810    const model = [];
50811    for (const item of this.selectedItems) {
50812      if (this.bindValue) {
50813        let value = null;
50814        if (item.children) {
50815          const groupKey = this.groupValue ? this.bindValue : this.groupBy;
50816          value = item.value[groupKey || this.groupBy];
50817        } else {
50818          value = this.itemsList.resolveNested(item.value, this.bindValue);
50819        }
50820        model.push(value);
50821      } else {
50822        model.push(item.value);
50823      }
50824    }
50825    const selected = this.selectedItems.map((x) => x.value);
50826    if (this.multiple) {
50827      this._onChange(model);
50828      this.changeEvent.emit(selected);
50829    } else {
50830      this._onChange(isDefined2(model[0]) ? model[0] : null);
50831      this.changeEvent.emit(selected[0]);
50832    }
50833    this._cd.markForCheck();
50834  }
50835  _clearSearch() {
50836    if (!this.searchTerm) {
50837      return;
50838    }
50839    this._changeSearch(null);
50840    this.itemsList.resetFilteredItems();
50841  }
50842  _changeSearch(searchTerm) {
50843    this.searchTerm = searchTerm;
50844    if (this._isTypeahead) {
50845      this.typeahead.next(searchTerm);
50846    }
50847  }
50848  _scrollToMarked() {
50849    if (!this.isOpen || !this.dropdownPanel) {
50850      return;
50851    }
50852    this.dropdownPanel.scrollTo(this.itemsList.markedItem);
50853  }
50854  _scrollToTag() {
50855    if (!this.isOpen || !this.dropdownPanel) {
50856      return;
50857    }
50858    this.dropdownPanel.scrollToTag();
50859  }
50860  _onSelectionChanged() {
50861    if (this.isOpen && this.deselectOnClick && this.appendTo) {
50862      this._cd.detectChanges();
50863      this.dropdownPanel.adjustPosition();
50864    }
50865  }
50866  _handleTab($event) {
50867    if (this.isOpen === false) {
50868      if (this.showClear() && !$event.shiftKey) {
50869        this.focusOnClear();
50870        $event.preventDefault();
50871      } else if (!this.addTag) {
50872        return;
50873      }
50874    }
50875    if (this.selectOnTab) {
50876      if (this.itemsList.markedItem) {
50877        this.toggleItem(this.itemsList.markedItem);
50878        $event.preventDefault();
50879      } else if (this.showAddTag) {
50880        this.selectTag();
50881        $event.preventDefault();
50882      } else {
50883        this.close();
50884      }
50885    } else {
50886      this.close();
50887    }
50888  }
50889  _handleEnter($event) {
50890    if (this.isOpen || this._manualOpen) {
50891      if (this.itemsList.markedItem) {
50892        this.toggleItem(this.itemsList.markedItem);
50893      } else if (this.showAddTag) {
50894        this.selectTag();
50895      }
50896    } else if (this.openOnEnter) {
50897      this.open();
50898    } else {
50899      return;
50900    }
50901    $event.preventDefault();
50902  }
50903  _handleSpace($event) {
50904    if (this.isOpen || this._manualOpen) {
50905      return;
50906    }
50907    this.open();
50908    $event.preventDefault();
50909  }
50910  _handleArrowDown($event) {
50911    if (this._nextItemIsTag(1)) {
50912      this.itemsList.unmarkItem();
50913      this._scrollToTag();
50914    } else {
50915      this.itemsList.markNextItem();
50916      this._scrollToMarked();
50917    }
50918    this.open();
50919    $event.preventDefault();
50920  }
50921  _handleArrowUp($event) {
50922    if (!this.isOpen) {
50923      return;
50924    }
50925    if (this._nextItemIsTag(-1)) {
50926      this.itemsList.unmarkItem();
50927      this._scrollToTag();
50928    } else {
50929      this.itemsList.markPreviousItem();
50930      this._scrollToMarked();
50931    }
50932    $event.preventDefault();
50933  }
50934  _nextItemIsTag(nextStep) {
50935    const nextIndex = this.itemsList.markedIndex + nextStep;
50936    return this.addTag && this.searchTerm && this.itemsList.markedItem && (nextIndex < 0 || nextIndex === this.itemsList.filteredItems.length);
50937  }
50938  _handleBackspace() {
50939    if (this.searchTerm || !this.clearable || !this.clearOnBackspace || !this.hasValue) {
50940      return;
50941    }
50942    if (this.multiple) {
50943      this.unselect(this.itemsList.lastSelectedItem);
50944    } else {
50945      this.clearModel();
50946    }
50947  }
50948  _mergeGlobalConfig(config) {
50949    this.placeholder = this.placeholder || config.placeholder;
50950    this.fixedPlaceholder = this.fixedPlaceholder || config.fixedPlaceholder;
50951    this.notFoundText = this.notFoundText || config.notFoundText;
50952    this.typeToSearchText = this.typeToSearchText || config.typeToSearchText;
50953    this.addTagText = this.addTagText || config.addTagText;
50954    this.loadingText = this.loadingText || config.loadingText;
50955    this.clearAllText = this.clearAllText || config.clearAllText;
50956    this.virtualScroll = isDefined2(this.virtualScroll) ? this.virtualScroll : isDefined2(config.disableVirtualScroll) ? !config.disableVirtualScroll : false;
50957    this.openOnEnter = isDefined2(this.openOnEnter) ? this.openOnEnter : config.openOnEnter;
50958    this.appendTo = this.appendTo || config.appendTo;
50959    this.bindValue = this.bindValue || config.bindValue;
50960    this.bindLabel = this.bindLabel || config.bindLabel;
50961    this.appearance = this.appearance || config.appearance;
50962  }
50963  static {
50964    this.\u0275fac = function NgSelectComponent_Factory(__ngFactoryType__) {
50965      return new (__ngFactoryType__ || _NgSelectComponent)(\u0275\u0275injectAttribute("class"), \u0275\u0275injectAttribute("autofocus"), \u0275\u0275directiveInject(NgSelectConfig), \u0275\u0275directiveInject(SELECTION_MODEL_FACTORY, 8), \u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(ChangeDetectorRef), \u0275\u0275directiveInject(ConsoleService));
50966    };
50967  }
50968  static {
50969    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({
50970      type: _NgSelectComponent,
50971      selectors: [["ng-select"]],
50972      contentQueries: function NgSelectComponent_ContentQueries(rf, ctx, dirIndex) {
50973        if (rf & 1) {
50974          \u0275\u0275contentQuery(dirIndex, NgOptionTemplateDirective, 5, TemplateRef);
50975          \u0275\u0275contentQuery(dirIndex, NgOptgroupTemplateDirective, 5, TemplateRef);
50976          \u0275\u0275contentQuery(dirIndex, NgLabelTemplateDirective, 5, TemplateRef);
50977          \u0275\u0275contentQuery(dirIndex, NgMultiLabelTemplateDirective, 5, TemplateRef);
50978          \u0275\u0275contentQuery(dirIndex, NgHeaderTemplateDirective, 5, TemplateRef);
50979          \u0275\u0275contentQuery(dirIndex, NgFooterTemplateDirective, 5, TemplateRef);
50980          \u0275\u0275contentQuery(dirIndex, NgNotFoundTemplateDirective, 5, TemplateRef);
50981          \u0275\u0275contentQuery(dirIndex, NgPlaceholderTemplateDirective, 5, TemplateRef);
50982          \u0275\u0275contentQuery(dirIndex, NgTypeToSearchTemplateDirective, 5, TemplateRef);
50983          \u0275\u0275contentQuery(dirIndex, NgLoadingTextTemplateDirective, 5, TemplateRef);
50984          \u0275\u0275contentQuery(dirIndex, NgTagTemplateDirective, 5, TemplateRef);
50985          \u0275\u0275contentQuery(dirIndex, NgLoadingSpinnerTemplateDirective, 5, TemplateRef);
50986          \u0275\u0275contentQuery(dirIndex, NgClearButtonTemplateDirective, 5, TemplateRef);
50987          \u0275\u0275contentQuery(dirIndex, NgOptionComponent, 5);
50988        }
50989        if (rf & 2) {
50990          let _t;
50991          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.optionTemplate = _t.first);
50992          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.optgroupTemplate = _t.first);
50993          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.labelTemplate = _t.first);
50994          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.multiLabelTemplate = _t.first);
50995          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.headerTemplate = _t.first);
50996          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.footerTemplate = _t.first);
50997          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.notFoundTemplate = _t.first);
50998          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.placeholderTemplate = _t.first);
50999          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.typeToSearchTemplate = _t.first);
51000          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.loadingTextTemplate = _t.first);
51001          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.tagTemplate = _t.first);
51002          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.loadingSpinnerTemplate = _t.first);
51003          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.clearButtonTemplate = _t.first);
51004          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.ngOptions = _t);
51005        }
51006      },
51007      viewQuery: function NgSelectComponent_Query(rf, ctx) {
51008        if (rf & 1) {
51009          \u0275\u0275viewQuery(NgDropdownPanelComponent, 5);
51010          \u0275\u0275viewQuery(_c5, 7);
51011          \u0275\u0275viewQuery(_c6, 5);
51012        }
51013        if (rf & 2) {
51014          let _t;
51015          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.dropdownPanel = _t.first);
51016          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.searchInput = _t.first);
51017          \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.clearButton = _t.first);
51018        }
51019      },
51020      hostVars: 20,
51021      hostBindings: function NgSelectComponent_HostBindings(rf, ctx) {
51022        if (rf & 1) {
51023          \u0275\u0275listener("keydown", function NgSelectComponent_keydown_HostBindingHandler($event) {
51024            return ctx.handleKeyDown($event);
51025          });
51026        }
51027        if (rf & 2) {
51028          \u0275\u0275classProp("ng-select-typeahead", ctx.typeahead)("ng-select-multiple", ctx.multiple)("ng-select-taggable", ctx.addTag)("ng-select-searchable", ctx.searchable)("ng-select-clearable", ctx.clearable)("ng-select-opened", ctx.isOpen)("ng-select", ctx.useDefaultClass)("ng-select-filtered", ctx.filtered)("ng-select-single", ctx.single)("ng-select-disabled", ctx.disabled);
51029        }
51030      },
51031      inputs: {
51032        ariaLabelDropdown: "ariaLabelDropdown",
51033        bindLabel: "bindLabel",
51034        bindValue: "bindValue",
51035        ariaLabel: "ariaLabel",
51036        markFirst: [2, "markFirst", "markFirst", booleanAttribute],
51037        placeholder: "placeholder",
51038        fixedPlaceholder: "fixedPlaceholder",
51039        notFoundText: "notFoundText",
51040        typeToSearchText: "typeToSearchText",
51041        preventToggleOnRightClick: "preventToggleOnRightClick",
51042        addTagText: "addTagText",
51043        loadingText: "loadingText",
51044        clearAllText: "clearAllText",
51045        appearance: "appearance",
51046        dropdownPosition: "dropdownPosition",
51047        appendTo: "appendTo",
51048        loading: [2, "loading", "loading", booleanAttribute],
51049        closeOnSelect: [2, "closeOnSelect", "closeOnSelect", booleanAttribute],
51050        hideSelected: [2, "hideSelected", "hideSelected", booleanAttribute],
51051        selectOnTab: [2, "selectOnTab", "selectOnTab", booleanAttribute],
51052        openOnEnter: [2, "openOnEnter", "openOnEnter", booleanAttribute],
51053        maxSelectedItems: [2, "maxSelectedItems", "maxSelectedItems", numberAttribute],
51054        groupBy: "groupBy",
51055        groupValue: "groupValue",
51056        bufferAmount: [2, "bufferAmount", "bufferAmount", numberAttribute],
51057        virtualScroll: [2, "virtualScroll", "virtualScroll", booleanAttribute],
51058        selectableGroup: [2, "selectableGroup", "selectableGroup", booleanAttribute],
51059        selectableGroupAsModel: [2, "selectableGroupAsModel", "selectableGroupAsModel", booleanAttribute],
51060        searchFn: "searchFn",
51061        trackByFn: "trackByFn",
51062        clearOnBackspace: [2, "clearOnBackspace", "clearOnBackspace", booleanAttribute],
51063        labelForId: "labelForId",
51064        inputAttrs: "inputAttrs",
51065        tabIndex: [2, "tabIndex", "tabIndex", numberAttribute],
51066        readonly: [2, "readonly", "readonly", booleanAttribute],
51067        searchWhileComposing: [2, "searchWhileComposing", "searchWhileComposing", booleanAttribute],
51068        minTermLength: [2, "minTermLength", "minTermLength", numberAttribute],
51069        editableSearchTerm: [2, "editableSearchTerm", "editableSearchTerm", booleanAttribute],
51070        ngClass: "ngClass",
51071        typeahead: "typeahead",
51072        multiple: [2, "multiple", "multiple", booleanAttribute],
51073        addTag: "addTag",
51074        searchable: [2, "searchable", "searchable", booleanAttribute],
51075        clearable: [2, "clearable", "clearable", booleanAttribute],
51076        isOpen: "isOpen",
51077        items: "items",
51078        compareWith: "compareWith",
51079        clearSearchOnAdd: "clearSearchOnAdd",
51080        deselectOnClick: "deselectOnClick",
51081        keyDownFn: "keyDownFn"
51082      },
51083      outputs: {
51084        blurEvent: "blur",
51085        focusEvent: "focus",
51086        changeEvent: "change",
51087        openEvent: "open",
51088        closeEvent: "close",
51089        searchEvent: "search",
51090        clearEvent: "clear",
51091        addEvent: "add",
51092        removeEvent: "remove",
51093        scroll: "scroll",
51094        scrollToEnd: "scrollToEnd"
51095      },
51096      features: [\u0275\u0275ProvidersFeature([{
51097        provide: NG_VALUE_ACCESSOR,
51098        useExisting: forwardRef(() => _NgSelectComponent),
51099        multi: true
51100      }, NgDropdownPanelService]), \u0275\u0275NgOnChangesFeature],
51101      decls: 13,
51102      vars: 20,
51103      consts: [["searchInput", ""], ["defaultPlaceholderTemplate", ""], ["defaultLabelTemplate", ""], ["defaultLoadingSpinnerTemplate", ""], ["clearButton", ""], ["defaultOptionTemplate", ""], ["defaultTagTemplate", ""], ["defaultNotFoundTemplate", ""], ["defaultTypeToSearchTemplate", ""], ["defaultLoadingTextTemplate", ""], [1, "ng-select-container", 3, "mousedown"], [1, "ng-value-container"], [3, "ngTemplateOutlet", "ngTemplateOutletContext"], [1, "ng-input"], ["aria-autocomplete", "list", "role", "combobox", 3, "blur", "change", "compositionend", "compositionstart", "focus", "input", "disabled", "readOnly", "value"], [1, "ng-arrow-wrapper"], [1, "ng-arrow"], [1, "ng-dropdown-panel", 3, "virtualScroll", "bufferAmount", "appendTo", "position", "headerTemplate", "footerTemplate", "filterValue", "items", "markedItem", "ng-select-multiple", "ngClass", "id"], [3, "ngTemplateOutlet"], [1, "ng-placeholder"], [1, "ng-value", 3, "ng-value-disabled"], [1, "ng-value"], ["aria-hidden", "true", 1, "ng-value-icon", "left", 3, "click"], [1, "ng-value-label", 3, "ngItemLabel", "escape"], [1, "ng-spinner-loader"], ["role", "button", "tabindex", "0", 1, "ng-clear-wrapper", 3, "title"], ["aria-hidden", "true", 1, "ng-clear"], [1, "ng-dropdown-panel", 3, "update", "scroll", "scrollToEnd", "outsideClick", "virtualScroll", "bufferAmount", "appendTo", "position", "headerTemplate", "footerTemplate", "filterValue", "items", "markedItem", "ngClass", "id"], [1, "ng-option", 3, "ng-option-disabled", "ng-option-selected", "ng-optgroup", "ng-option", "ng-option-child", "ng-option-marked"], ["role", "option", 1, "ng-option", 3, "ng-option-marked"], [1, "ng-option", 3, "click", "mouseover"], [1, "ng-option-label", 3, "ngItemLabel", "escape"], ["role", "option", 1, "ng-option", 3, "mouseover", "click"], [1, "ng-tag-label"], [1, "ng-option", "ng-option-disabled"]],
51104      template: function NgSelectComponent_Template(rf, ctx) {
51105        if (rf & 1) {
51106          const _r1 = \u0275\u0275getCurrentView();
51107          \u0275\u0275elementStart(0, "div", 10);
51108          \u0275\u0275listener("mousedown", function NgSelectComponent_Template_div_mousedown_0_listener($event) {
51109            \u0275\u0275restoreView(_r1);
51110            return \u0275\u0275resetView(ctx.handleMousedown($event));
51111          });
51112          \u0275\u0275elementStart(1, "div", 11);
51113          \u0275\u0275template(2, NgSelectComponent_Conditional_2_Template, 3, 1)(3, NgSelectComponent_Conditional_3_Template, 2, 0)(4, NgSelectComponent_Conditional_4_Template, 1, 5, null, 12);
51114          \u0275\u0275elementStart(5, "div", 13)(6, "input", 14, 0);
51115          \u0275\u0275listener("blur", function NgSelectComponent_Template_input_blur_6_listener($event) {
51116            \u0275\u0275restoreView(_r1);
51117            return \u0275\u0275resetView(ctx.onInputBlur($event));
51118          })("change", function NgSelectComponent_Template_input_change_6_listener($event) {
51119            \u0275\u0275restoreView(_r1);
51120            return \u0275\u0275resetView($event.stopPropagation());
51121          })("compositionend", function NgSelectComponent_Template_input_compositionend_6_listener() {
51122            \u0275\u0275restoreView(_r1);
51123            const searchInput_r7 = \u0275\u0275reference(7);
51124            return \u0275\u0275resetView(ctx.onCompositionEnd(searchInput_r7.value));
51125          })("compositionstart", function NgSelectComponent_Template_input_compositionstart_6_listener() {
51126            \u0275\u0275restoreView(_r1);
51127            return \u0275\u0275resetView(ctx.onCompositionStart());
51128          })("focus", function NgSelectComponent_Template_input_focus_6_listener($event) {
51129            \u0275\u0275restoreView(_r1);
51130            return \u0275\u0275resetView(ctx.onInputFocus($event));
51131          })("input", function NgSelectComponent_Template_input_input_6_listener() {
51132            \u0275\u0275restoreView(_r1);
51133            const searchInput_r7 = \u0275\u0275reference(7);
51134            return \u0275\u0275resetView(ctx.filter(searchInput_r7.value));
51135          });
51136          \u0275\u0275elementEnd()()();
51137          \u0275\u0275template(8, NgSelectComponent_Conditional_8_Template, 3, 1)(9, NgSelectComponent_Conditional_9_Template, 2, 1);
51138          \u0275\u0275elementStart(10, "span", 15);
51139          \u0275\u0275element(11, "span", 16);
51140          \u0275\u0275elementEnd()();
51141          \u0275\u0275template(12, NgSelectComponent_Conditional_12_Template, 8, 18, "ng-dropdown-panel", 17);
51142        }
51143        if (rf & 2) {
51144          \u0275\u0275classProp("ng-appearance-outline", ctx.appearance === "outline")("ng-has-value", ctx.hasValue);
51145          \u0275\u0275advance(2);
51146          \u0275\u0275conditional(ctx.selectedItems.length === 0 && !ctx.searchTerm || ctx.fixedPlaceholder ? 2 : -1);
51147          \u0275\u0275advance();
51148          \u0275\u0275conditional((!ctx.multiLabelTemplate || !ctx.multiple) && ctx.selectedItems.length > 0 ? 3 : -1);
51149          \u0275\u0275advance();
51150          \u0275\u0275conditional(ctx.multiple && ctx.multiLabelTemplate && ctx.selectedValues.length > 0 ? 4 : -1);
51151          \u0275\u0275advance(2);
51152          \u0275\u0275property("disabled", ctx.disabled)("readOnly", !ctx.searchable || ctx.itemsList.maxItemsSelected)("value", ctx.searchTerm ? ctx.searchTerm : "");
51153          \u0275\u0275attribute("aria-activedescendant", ctx.isOpen ? ctx.itemsList == null ? null : ctx.itemsList.markedItem == null ? null : ctx.itemsList.markedItem.htmlId : null)("aria-controls", ctx.isOpen ? ctx.dropdownId : null)("aria-expanded", ctx.isOpen)("aria-label", ctx.ariaLabel)("aria-placeholder", ctx.placeholderTemplate ? null : ctx.placeholder)("id", ctx.labelForId)("tabindex", ctx.tabIndex);
51154          \u0275\u0275advance(2);
51155          \u0275\u0275conditional(ctx.loading ? 8 : -1);
51156          \u0275\u0275advance();
51157          \u0275\u0275conditional(ctx.showClear() ? 9 : -1);
51158          \u0275\u0275advance(3);
51159          \u0275\u0275conditional(ctx.isOpen ? 12 : -1);
51160        }
51161      },
51162      dependencies: [NgTemplateOutlet, NgItemLabelDirective, NgDropdownPanelComponent, NgClass],
51163      styles: ['@charset "UTF-8";.ng-select{position:relative;display:block;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.ng-select div,.ng-select input,.ng-select span{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.ng-select [hidden]{display:none}.ng-select.ng-select-searchable .ng-select-container .ng-value-container .ng-input{opacity:1}.ng-select.ng-select-opened .ng-select-container{z-index:1001}.ng-select.ng-select-disabled .ng-select-container .ng-value-container .ng-placeholder,.ng-select.ng-select-disabled .ng-select-container .ng-value-container .ng-value{-webkit-user-select:none;user-select:none;cursor:default}.ng-select.ng-select-disabled .ng-arrow-wrapper{cursor:default}.ng-select.ng-select-filtered .ng-placeholder{display:none}.ng-select .ng-select-container{cursor:default;display:flex;outline:none;overflow:hidden;position:relative;width:100%}.ng-select .ng-select-container .ng-value-container{display:flex;flex:1}.ng-select .ng-select-container .ng-value-container .ng-input{opacity:0}.ng-select .ng-select-container .ng-value-container .ng-input>input{box-sizing:content-box;background:none transparent;border:0 none;box-shadow:none;outline:none;padding:0;cursor:default;width:100%}.ng-select .ng-select-container .ng-value-container .ng-input>input::-ms-clear{display:none}.ng-select .ng-select-container .ng-value-container .ng-input>input[readonly]{-webkit-user-select:unset;user-select:unset;width:0;padding:0}.ng-select.ng-select-single.ng-select-filtered .ng-select-container .ng-value-container .ng-value{visibility:hidden}.ng-select.ng-select-single .ng-select-container .ng-value-container,.ng-select.ng-select-single .ng-select-container .ng-value-container .ng-value{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ng-select.ng-select-single .ng-select-container .ng-value-container .ng-value .ng-value-icon{display:none}.ng-select.ng-select-single .ng-select-container .ng-value-container .ng-input{position:absolute;left:0;width:100%}.ng-select.ng-select-multiple.ng-select-disabled>.ng-select-container .ng-value-container .ng-value .ng-value-icon{display:none}.ng-select.ng-select-multiple .ng-select-container .ng-value-container{flex-wrap:wrap}.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-placeholder{position:absolute}.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value{white-space:nowrap}.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value.ng-value-disabled .ng-value-icon{display:none}.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value .ng-value-icon{cursor:pointer}.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-input{flex:1;z-index:2}.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-placeholder{z-index:1}.ng-select .ng-clear-wrapper{cursor:pointer;position:relative;width:17px;-webkit-user-select:none;user-select:none}.ng-select .ng-clear-wrapper .ng-clear{display:inline-block;font-size:18px;line-height:1;pointer-events:none}.ng-select .ng-spinner-loader{border-radius:50%;width:17px;height:17px;margin-right:5px;font-size:10px;position:relative;text-indent:-9999em;border-top:2px solid rgba(66,66,66,.2);border-right:2px solid rgba(66,66,66,.2);border-bottom:2px solid rgba(66,66,66,.2);border-left:2px solid #424242;transform:translateZ(0);animation:load8 .8s infinite linear}.ng-select .ng-spinner-loader:after{border-radius:50%;width:17px;height:17px}@-webkit-keyframes load8{0%{-webkit-transform:rotate(0deg);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes load8{0%{-webkit-transform:rotate(0deg);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}.ng-select .ng-arrow-wrapper{cursor:pointer;position:relative;text-align:center;-webkit-user-select:none;user-select:none}.ng-select .ng-arrow-wrapper .ng-arrow{pointer-events:none;display:inline-block;height:0;width:0;position:relative}.ng-dropdown-panel{box-sizing:border-box;position:absolute;opacity:0;width:100%;z-index:1050;-webkit-overflow-scrolling:touch}.ng-dropdown-panel .ng-dropdown-panel-items{display:block;height:auto;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;max-height:240px;overflow-y:auto}.ng-dropdown-panel .ng-dropdown-panel-items .ng-optgroup{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ng-dropdown-panel .ng-dropdown-panel-items .ng-option{box-sizing:border-box;cursor:pointer;display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ng-dropdown-panel .ng-dropdown-panel-items .ng-option .ng-option-label:empty:before{content:"\\200b"}.ng-dropdown-panel .ng-dropdown-panel-items .ng-option .highlighted{font-weight:700;text-decoration:underline}.ng-dropdown-panel .ng-dropdown-panel-items .ng-option.disabled{cursor:default}.ng-dropdown-panel .scroll-host{overflow:hidden;overflow-y:auto;position:relative;display:block;-webkit-overflow-scrolling:touch}.ng-dropdown-panel .scrollable-content{top:0;left:0;width:100%;height:100%;position:absolute}.ng-dropdown-panel .total-padding{width:1px;opacity:0}\n'],
51164      encapsulation: 2,
51165      changeDetection: 0
51166    });
51167  }
51168};
51169(() => {
51170  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgSelectComponent, [{
51171    type: Component,
51172    args: [{
51173      selector: "ng-select",
51174      providers: [{
51175        provide: NG_VALUE_ACCESSOR,
51176        useExisting: forwardRef(() => NgSelectComponent),
51177        multi: true
51178      }, NgDropdownPanelService],
51179      encapsulation: ViewEncapsulation.None,
51180      changeDetection: ChangeDetectionStrategy.OnPush,
51181      imports: [NgTemplateOutlet, NgItemLabelDirective, NgDropdownPanelComponent, NgClass],
51182      template: `<div
51183	(mousedown)="handleMousedown($event)"
51184	[class.ng-appearance-outline]="appearance === 'outline'"
51185	[class.ng-has-value]="hasValue"
51186	class="ng-select-container">
51187	<div class="ng-value-container">
51188		@if ((selectedItems.length === 0 && !searchTerm) || fixedPlaceholder) {
51189			<ng-template #defaultPlaceholderTemplate>
51190				<div class="ng-placeholder">{{ placeholder }}</div>
51191			</ng-template>
51192			<ng-template [ngTemplateOutlet]="placeholderTemplate || defaultPlaceholderTemplate"> </ng-template>
51193		}
51194
51195		@if ((!multiLabelTemplate || !multiple) && selectedItems.length > 0) {
51196			@for (item of selectedItems; track trackByOption($index, item)) {
51197				<div [class.ng-value-disabled]="item.disabled" class="ng-value">
51198					<ng-template #defaultLabelTemplate>
51199						<span class="ng-value-icon left" (click)="unselect(item)" aria-hidden="true">\xD7</span>
51200						<span class="ng-value-label" [ngItemLabel]="item.label" [escape]="escapeHTML"></span>
51201					</ng-template>
51202					<ng-template
51203						[ngTemplateOutlet]="labelTemplate || defaultLabelTemplate"
51204						[ngTemplateOutletContext]="{ item: item.value, clear: clearItem, label: item.label }">
51205					</ng-template>
51206				</div>
51207			}
51208		}
51209
51210		@if (multiple && multiLabelTemplate && selectedValues.length > 0) {
51211			<ng-template [ngTemplateOutlet]="multiLabelTemplate" [ngTemplateOutletContext]="{ items: selectedValues, clear: clearItem }">
51212			</ng-template>
51213		}
51214
51215		<div class="ng-input">
51216			<input
51217				#searchInput
51218				(blur)="onInputBlur($event)"
51219				(change)="$event.stopPropagation()"
51220				(compositionend)="onCompositionEnd(searchInput.value)"
51221				(compositionstart)="onCompositionStart()"
51222				(focus)="onInputFocus($event)"
51223				(input)="filter(searchInput.value)"
51224				[attr.aria-activedescendant]="isOpen ? itemsList?.markedItem?.htmlId : null"
51225				[attr.aria-controls]="isOpen ? dropdownId : null"
51226				[attr.aria-expanded]="isOpen"
51227				[attr.aria-label]="ariaLabel"
51228				[attr.aria-placeholder]="placeholderTemplate ? null : placeholder"
51229				[attr.id]="labelForId"
51230				[attr.tabindex]="tabIndex"
51231				[disabled]="disabled"
51232				[readOnly]="!searchable || itemsList.maxItemsSelected"
51233				[value]="searchTerm ? searchTerm : ''"
51234				aria-autocomplete="list"
51235				role="combobox" />
51236		</div>
51237	</div>
51238
51239	@if (loading) {
51240		<ng-template #defaultLoadingSpinnerTemplate>
51241			<div class="ng-spinner-loader"></div>
51242		</ng-template>
51243		<ng-template [ngTemplateOutlet]="loadingSpinnerTemplate || defaultLoadingSpinnerTemplate"></ng-template>
51244	}
51245
51246	@if (showClear()) {
51247		@if (clearButtonTemplate) {
51248			<ng-container [ngTemplateOutlet]="clearButtonTemplate"></ng-container>
51249		} @else {
51250			<span class="ng-clear-wrapper" role="button" tabindex="0" title="{{ clearAllText }}" #clearButton>
51251				<span class="ng-clear" aria-hidden="true">\xD7</span>
51252			</span>
51253		}
51254	}
51255
51256	<span class="ng-arrow-wrapper">
51257		<span class="ng-arrow"></span>
51258	</span>
51259</div>
51260
51261@if (isOpen) {
51262	<ng-dropdown-panel
51263		class="ng-dropdown-panel"
51264		[virtualScroll]="virtualScroll"
51265		[bufferAmount]="bufferAmount"
51266		[appendTo]="appendTo"
51267		[position]="dropdownPosition"
51268		[headerTemplate]="headerTemplate"
51269		[footerTemplate]="footerTemplate"
51270		[filterValue]="searchTerm"
51271		[items]="itemsList.filteredItems"
51272		[markedItem]="itemsList.markedItem"
51273		(update)="viewPortItems = $event"
51274		(scroll)="scroll.emit($event)"
51275		(scrollToEnd)="scrollToEnd.emit($event)"
51276		(outsideClick)="close()"
51277		[class.ng-select-multiple]="multiple"
51278		[ngClass]="appendTo ? (ngClass ? ngClass : classes) : null"
51279		[id]="dropdownId"
51280		[attr.aria-label]="ariaLabelDropdown">
51281		<ng-container>
51282			@for (item of viewPortItems; track trackByOption($index, item)) {
51283				<div
51284					class="ng-option"
51285					[attr.role]="item.children ? 'group' : 'option'"
51286					(click)="toggleItem(item)"
51287					(mouseover)="onItemHover(item)"
51288					[class.ng-option-disabled]="item.disabled"
51289					[class.ng-option-selected]="item.selected"
51290					[class.ng-optgroup]="item.children"
51291					[class.ng-option]="!item.children"
51292					[class.ng-option-child]="!!item.parent"
51293					[class.ng-option-marked]="item === itemsList.markedItem"
51294					[attr.aria-selected]="item.selected"
51295					[attr.id]="item?.htmlId">
51296					<ng-template #defaultOptionTemplate>
51297						<span class="ng-option-label" [ngItemLabel]="item.label" [escape]="escapeHTML"></span>
51298					</ng-template>
51299					<ng-template
51300						[ngTemplateOutlet]="
51301							item.children ? optgroupTemplate || defaultOptionTemplate : optionTemplate || defaultOptionTemplate
51302						"
51303						[ngTemplateOutletContext]="{ item: item.value, item$: item, index: item.index, searchTerm: searchTerm }">
51304					</ng-template>
51305				</div>
51306			}
51307			@if (showAddTag) {
51308				<div
51309					class="ng-option"
51310					[class.ng-option-marked]="!itemsList.markedItem"
51311					(mouseover)="itemsList.unmarkItem()"
51312					role="option"
51313					(click)="selectTag()">
51314					<ng-template #defaultTagTemplate>
51315						<span
51316							><span class="ng-tag-label">{{ addTagText }}</span
51317							>"{{ searchTerm }}"</span
51318						>
51319					</ng-template>
51320					<ng-template
51321						[ngTemplateOutlet]="tagTemplate || defaultTagTemplate"
51322						[ngTemplateOutletContext]="{ searchTerm: searchTerm }">
51323					</ng-template>
51324				</div>
51325			}
51326		</ng-container>
51327		@if (showNoItemsFound()) {
51328			<ng-template #defaultNotFoundTemplate>
51329				<div class="ng-option ng-option-disabled">{{ notFoundText }}</div>
51330			</ng-template>
51331			<ng-template
51332				[ngTemplateOutlet]="notFoundTemplate || defaultNotFoundTemplate"
51333				[ngTemplateOutletContext]="{ searchTerm: searchTerm }">
51334			</ng-template>
51335		}
51336		@if (showTypeToSearch()) {
51337			<ng-template #defaultTypeToSearchTemplate>
51338				<div class="ng-option ng-option-disabled">{{ typeToSearchText }}</div>
51339			</ng-template>
51340			<ng-template [ngTemplateOutlet]="typeToSearchTemplate || defaultTypeToSearchTemplate"></ng-template>
51341		}
51342		@if (loading && itemsList.filteredItems.length === 0) {
51343			<ng-template #defaultLoadingTextTemplate>
51344				<div class="ng-option ng-option-disabled">{{ loadingText }}</div>
51345			</ng-template>
51346			<ng-template
51347				[ngTemplateOutlet]="loadingTextTemplate || defaultLoadingTextTemplate"
51348				[ngTemplateOutletContext]="{ searchTerm: searchTerm }">
51349			</ng-template>
51350		}
51351	</ng-dropdown-panel>
51352}
51353`,
51354      styles: ['@charset "UTF-8";.ng-select{position:relative;display:block;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.ng-select div,.ng-select input,.ng-select span{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.ng-select [hidden]{display:none}.ng-select.ng-select-searchable .ng-select-container .ng-value-container .ng-input{opacity:1}.ng-select.ng-select-opened .ng-select-container{z-index:1001}.ng-select.ng-select-disabled .ng-select-container .ng-value-container .ng-placeholder,.ng-select.ng-select-disabled .ng-select-container .ng-value-container .ng-value{-webkit-user-select:none;user-select:none;cursor:default}.ng-select.ng-select-disabled .ng-arrow-wrapper{cursor:default}.ng-select.ng-select-filtered .ng-placeholder{display:none}.ng-select .ng-select-container{cursor:default;display:flex;outline:none;overflow:hidden;position:relative;width:100%}.ng-select .ng-select-container .ng-value-container{display:flex;flex:1}.ng-select .ng-select-container .ng-value-container .ng-input{opacity:0}.ng-select .ng-select-container .ng-value-container .ng-input>input{box-sizing:content-box;background:none transparent;border:0 none;box-shadow:none;outline:none;padding:0;cursor:default;width:100%}.ng-select .ng-select-container .ng-value-container .ng-input>input::-ms-clear{display:none}.ng-select .ng-select-container .ng-value-container .ng-input>input[readonly]{-webkit-user-select:unset;user-select:unset;width:0;padding:0}.ng-select.ng-select-single.ng-select-filtered .ng-select-container .ng-value-container .ng-value{visibility:hidden}.ng-select.ng-select-single .ng-select-container .ng-value-container,.ng-select.ng-select-single .ng-select-container .ng-value-container .ng-value{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ng-select.ng-select-single .ng-select-container .ng-value-container .ng-value .ng-value-icon{display:none}.ng-select.ng-select-single .ng-select-container .ng-value-container .ng-input{position:absolute;left:0;width:100%}.ng-select.ng-select-multiple.ng-select-disabled>.ng-select-container .ng-value-container .ng-value .ng-value-icon{display:none}.ng-select.ng-select-multiple .ng-select-container .ng-value-container{flex-wrap:wrap}.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-placeholder{position:absolute}.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value{white-space:nowrap}.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value.ng-value-disabled .ng-value-icon{display:none}.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value .ng-value-icon{cursor:pointer}.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-input{flex:1;z-index:2}.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-placeholder{z-index:1}.ng-select .ng-clear-wrapper{cursor:pointer;position:relative;width:17px;-webkit-user-select:none;user-select:none}.ng-select .ng-clear-wrapper .ng-clear{display:inline-block;font-size:18px;line-height:1;pointer-events:none}.ng-select .ng-spinner-loader{border-radius:50%;width:17px;height:17px;margin-right:5px;font-size:10px;position:relative;text-indent:-9999em;border-top:2px solid rgba(66,66,66,.2);border-right:2px solid rgba(66,66,66,.2);border-bottom:2px solid rgba(66,66,66,.2);border-left:2px solid #424242;transform:translateZ(0);animation:load8 .8s infinite linear}.ng-select .ng-spinner-loader:after{border-radius:50%;width:17px;height:17px}@-webkit-keyframes load8{0%{-webkit-transform:rotate(0deg);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes load8{0%{-webkit-transform:rotate(0deg);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}.ng-select .ng-arrow-wrapper{cursor:pointer;position:relative;text-align:center;-webkit-user-select:none;user-select:none}.ng-select .ng-arrow-wrapper .ng-arrow{pointer-events:none;display:inline-block;height:0;width:0;position:relative}.ng-dropdown-panel{box-sizing:border-box;position:absolute;opacity:0;width:100%;z-index:1050;-webkit-overflow-scrolling:touch}.ng-dropdown-panel .ng-dropdown-panel-items{display:block;height:auto;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;max-height:240px;overflow-y:auto}.ng-dropdown-panel .ng-dropdown-panel-items .ng-optgroup{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ng-dropdown-panel .ng-dropdown-panel-items .ng-option{box-sizing:border-box;cursor:pointer;display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ng-dropdown-panel .ng-dropdown-panel-items .ng-option .ng-option-label:empty:before{content:"\\200b"}.ng-dropdown-panel .ng-dropdown-panel-items .ng-option .highlighted{font-weight:700;text-decoration:underline}.ng-dropdown-panel .ng-dropdown-panel-items .ng-option.disabled{cursor:default}.ng-dropdown-panel .scroll-host{overflow:hidden;overflow-y:auto;position:relative;display:block;-webkit-overflow-scrolling:touch}.ng-dropdown-panel .scrollable-content{top:0;left:0;width:100%;height:100%;position:absolute}.ng-dropdown-panel .total-padding{width:1px;opacity:0}\n']
51355    }]
51356  }], () => [{
51357    type: void 0,
51358    decorators: [{
51359      type: Attribute,
51360      args: ["class"]
51361    }]
51362  }, {
51363    type: void 0,
51364    decorators: [{
51365      type: Attribute,
51366      args: ["autofocus"]
51367    }]
51368  }, {
51369    type: NgSelectConfig
51370  }, {
51371    type: void 0,
51372    decorators: [{
51373      type: Inject,
51374      args: [SELECTION_MODEL_FACTORY]
51375    }, {
51376      type: Optional
51377    }]
51378  }, {
51379    type: ElementRef
51380  }, {
51381    type: ChangeDetectorRef
51382  }, {
51383    type: ConsoleService
51384  }], {
51385    ariaLabelDropdown: [{
51386      type: Input
51387    }],
51388    bindLabel: [{
51389      type: Input
51390    }],
51391    bindValue: [{
51392      type: Input
51393    }],
51394    ariaLabel: [{
51395      type: Input
51396    }],
51397    markFirst: [{
51398      type: Input,
51399      args: [{
51400        transform: booleanAttribute
51401      }]
51402    }],
51403    placeholder: [{
51404      type: Input
51405    }],
51406    fixedPlaceholder: [{
51407      type: Input
51408    }],
51409    notFoundText: [{
51410      type: Input
51411    }],
51412    typeToSearchText: [{
51413      type: Input
51414    }],
51415    preventToggleOnRightClick: [{
51416      type: Input
51417    }],
51418    addTagText: [{
51419      type: Input
51420    }],
51421    loadingText: [{
51422      type: Input
51423    }],
51424    clearAllText: [{
51425      type: Input
51426    }],
51427    appearance: [{
51428      type: Input
51429    }],
51430    dropdownPosition: [{
51431      type: Input
51432    }],
51433    appendTo: [{
51434      type: Input
51435    }],
51436    loading: [{
51437      type: Input,
51438      args: [{
51439        transform: booleanAttribute
51440      }]
51441    }],
51442    closeOnSelect: [{
51443      type: Input,
51444      args: [{
51445        transform: booleanAttribute
51446      }]
51447    }],
51448    hideSelected: [{
51449      type: Input,
51450      args: [{
51451        transform: booleanAttribute
51452      }]
51453    }],
51454    selectOnTab: [{
51455      type: Input,
51456      args: [{
51457        transform: booleanAttribute
51458      }]
51459    }],
51460    openOnEnter: [{
51461      type: Input,
51462      args: [{
51463        transform: booleanAttribute
51464      }]
51465    }],
51466    maxSelectedItems: [{
51467      type: Input,
51468      args: [{
51469        transform: numberAttribute
51470      }]
51471    }],
51472    groupBy: [{
51473      type: Input
51474    }],
51475    groupValue: [{
51476      type: Input
51477    }],
51478    bufferAmount: [{
51479      type: Input,
51480      args: [{
51481        transform: numberAttribute
51482      }]
51483    }],
51484    virtualScroll: [{
51485      type: Input,
51486      args: [{
51487        transform: booleanAttribute
51488      }]
51489    }],
51490    selectableGroup: [{
51491      type: Input,
51492      args: [{
51493        transform: booleanAttribute
51494      }]
51495    }],
51496    selectableGroupAsModel: [{
51497      type: Input,
51498      args: [{
51499        transform: booleanAttribute
51500      }]
51501    }],
51502    searchFn: [{
51503      type: Input
51504    }],
51505    trackByFn: [{
51506      type: Input
51507    }],
51508    clearOnBackspace: [{
51509      type: Input,
51510      args: [{
51511        transform: booleanAttribute
51512      }]
51513    }],
51514    labelForId: [{
51515      type: Input
51516    }],
51517    inputAttrs: [{
51518      type: Input
51519    }],
51520    tabIndex: [{
51521      type: Input,
51522      args: [{
51523        transform: numberAttribute
51524      }]
51525    }],
51526    readonly: [{
51527      type: Input,
51528      args: [{
51529        transform: booleanAttribute
51530      }]
51531    }],
51532    searchWhileComposing: [{
51533      type: Input,
51534      args: [{
51535        transform: booleanAttribute
51536      }]
51537    }],
51538    minTermLength: [{
51539      type: Input,
51540      args: [{
51541        transform: numberAttribute
51542      }]
51543    }],
51544    editableSearchTerm: [{
51545      type: Input,
51546      args: [{
51547        transform: booleanAttribute
51548      }]
51549    }],
51550    ngClass: [{
51551      type: Input
51552    }],
51553    typeahead: [{
51554      type: Input
51555    }, {
51556      type: HostBinding,
51557      args: ["class.ng-select-typeahead"]
51558    }],
51559    multiple: [{
51560      type: Input,
51561      args: [{
51562        transform: booleanAttribute
51563      }]
51564    }, {
51565      type: HostBinding,
51566      args: ["class.ng-select-multiple"]
51567    }],
51568    addTag: [{
51569      type: Input
51570    }, {
51571      type: HostBinding,
51572      args: ["class.ng-select-taggable"]
51573    }],
51574    searchable: [{
51575      type: Input,
51576      args: [{
51577        transform: booleanAttribute
51578      }]
51579    }, {
51580      type: HostBinding,
51581      args: ["class.ng-select-searchable"]
51582    }],
51583    clearable: [{
51584      type: Input,
51585      args: [{
51586        transform: booleanAttribute
51587      }]
51588    }, {
51589      type: HostBinding,
51590      args: ["class.ng-select-clearable"]
51591    }],
51592    isOpen: [{
51593      type: Input
51594    }, {
51595      type: HostBinding,
51596      args: ["class.ng-select-opened"]
51597    }],
51598    blurEvent: [{
51599      type: Output,
51600      args: ["blur"]
51601    }],
51602    focusEvent: [{
51603      type: Output,
51604      args: ["focus"]
51605    }],
51606    changeEvent: [{
51607      type: Output,
51608      args: ["change"]
51609    }],
51610    openEvent: [{
51611      type: Output,
51612      args: ["open"]
51613    }],
51614    closeEvent: [{
51615      type: Output,
51616      args: ["close"]
51617    }],
51618    searchEvent: [{
51619      type: Output,
51620      args: ["search"]
51621    }],
51622    clearEvent: [{
51623      type: Output,
51624      args: ["clear"]
51625    }],
51626    addEvent: [{
51627      type: Output,
51628      args: ["add"]
51629    }],
51630    removeEvent: [{
51631      type: Output,
51632      args: ["remove"]
51633    }],
51634    scroll: [{
51635      type: Output,
51636      args: ["scroll"]
51637    }],
51638    scrollToEnd: [{
51639      type: Output,
51640      args: ["scrollToEnd"]
51641    }],
51642    optionTemplate: [{
51643      type: ContentChild,
51644      args: [NgOptionTemplateDirective, {
51645        read: TemplateRef
51646      }]
51647    }],
51648    optgroupTemplate: [{
51649      type: ContentChild,
51650      args: [NgOptgroupTemplateDirective, {
51651        read: TemplateRef
51652      }]
51653    }],
51654    labelTemplate: [{
51655      type: ContentChild,
51656      args: [NgLabelTemplateDirective, {
51657        read: TemplateRef
51658      }]
51659    }],
51660    multiLabelTemplate: [{
51661      type: ContentChild,
51662      args: [NgMultiLabelTemplateDirective, {
51663        read: TemplateRef
51664      }]
51665    }],
51666    headerTemplate: [{
51667      type: ContentChild,
51668      args: [NgHeaderTemplateDirective, {
51669        read: TemplateRef
51670      }]
51671    }],
51672    footerTemplate: [{
51673      type: ContentChild,
51674      args: [NgFooterTemplateDirective, {
51675        read: TemplateRef
51676      }]
51677    }],
51678    notFoundTemplate: [{
51679      type: ContentChild,
51680      args: [NgNotFoundTemplateDirective, {
51681        read: TemplateRef
51682      }]
51683    }],
51684    placeholderTemplate: [{
51685      type: ContentChild,
51686      args: [NgPlaceholderTemplateDirective, {
51687        read: TemplateRef
51688      }]
51689    }],
51690    typeToSearchTemplate: [{
51691      type: ContentChild,
51692      args: [NgTypeToSearchTemplateDirective, {
51693        read: TemplateRef
51694      }]
51695    }],
51696    loadingTextTemplate: [{
51697      type: ContentChild,
51698      args: [NgLoadingTextTemplateDirective, {
51699        read: TemplateRef
51700      }]
51701    }],
51702    tagTemplate: [{
51703      type: ContentChild,
51704      args: [NgTagTemplateDirective, {
51705        read: TemplateRef
51706      }]
51707    }],
51708    loadingSpinnerTemplate: [{
51709      type: ContentChild,
51710      args: [NgLoadingSpinnerTemplateDirective, {
51711        read: TemplateRef
51712      }]
51713    }],
51714    clearButtonTemplate: [{
51715      type: ContentChild,
51716      args: [NgClearButtonTemplateDirective, {
51717        read: TemplateRef
51718      }]
51719    }],
51720    dropdownPanel: [{
51721      type: ViewChild,
51722      args: [forwardRef(() => NgDropdownPanelComponent)]
51723    }],
51724    searchInput: [{
51725      type: ViewChild,
51726      args: ["searchInput", {
51727        static: true
51728      }]
51729    }],
51730    clearButton: [{
51731      type: ViewChild,
51732      args: ["clearButton"]
51733    }],
51734    ngOptions: [{
51735      type: ContentChildren,
51736      args: [NgOptionComponent, {
51737        descendants: true
51738      }]
51739    }],
51740    useDefaultClass: [{
51741      type: HostBinding,
51742      args: ["class.ng-select"]
51743    }],
51744    filtered: [{
51745      type: HostBinding,
51746      args: ["class.ng-select-filtered"]
51747    }],
51748    single: [{
51749      type: HostBinding,
51750      args: ["class.ng-select-single"]
51751    }],
51752    items: [{
51753      type: Input
51754    }],
51755    disabled: [{
51756      type: HostBinding,
51757      args: ["class.ng-select-disabled"]
51758    }],
51759    compareWith: [{
51760      type: Input
51761    }],
51762    clearSearchOnAdd: [{
51763      type: Input
51764    }],
51765    deselectOnClick: [{
51766      type: Input
51767    }],
51768    keyDownFn: [{
51769      type: Input
51770    }],
51771    handleKeyDown: [{
51772      type: HostListener,
51773      args: ["keydown", ["$event"]]
51774    }]
51775  });
51776})();
51777var NgSelectModule = class _NgSelectModule {
51778  static {
51779    this.\u0275fac = function NgSelectModule_Factory(__ngFactoryType__) {
51780      return new (__ngFactoryType__ || _NgSelectModule)();
51781    };
51782  }
51783  static {
51784    this.\u0275mod = /* @__PURE__ */ \u0275\u0275defineNgModule({
51785      type: _NgSelectModule
51786    });
51787  }
51788  static {
51789    this.\u0275inj = /* @__PURE__ */ \u0275\u0275defineInjector({
51790      providers: [{
51791        provide: SELECTION_MODEL_FACTORY,
51792        useValue: DefaultSelectionModelFactory
51793      }]
51794    });
51795  }
51796};
51797(() => {
51798  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(NgSelectModule, [{
51799    type: NgModule,
51800    args: [{
51801      imports: [NgDropdownPanelComponent, NgOptionComponent, NgSelectComponent, NgOptgroupTemplateDirective, NgOptionTemplateDirective, NgLabelTemplateDirective, NgMultiLabelTemplateDirective, NgHeaderTemplateDirective, NgFooterTemplateDirective, NgPlaceholderTemplateDirective, NgClearButtonTemplateDirective, NgNotFoundTemplateDirective, NgTypeToSearchTemplateDirective, NgLoadingTextTemplateDirective, NgTagTemplateDirective, NgLoadingSpinnerTemplateDirective, NgItemLabelDirective],
51802      exports: [NgSelectComponent, NgOptionComponent, NgOptgroupTemplateDirective, NgOptionTemplateDirective, NgLabelTemplateDirective, NgMultiLabelTemplateDirective, NgHeaderTemplateDirective, NgFooterTemplateDirective, NgPlaceholderTemplateDirective, NgNotFoundTemplateDirective, NgTypeToSearchTemplateDirective, NgLoadingTextTemplateDirective, NgTagTemplateDirective, NgLoadingSpinnerTemplateDirective, NgClearButtonTemplateDirective],
51803      providers: [{
51804        provide: SELECTION_MODEL_FACTORY,
51805        useValue: DefaultSelectionModelFactory
51806      }]
51807    }]
51808  }], null, null);
51809})();
51810
51811// src/app/DoraWidget/dora-data-grid-selector/dora-data-grid-selector-lb/dora-data-grid-selector-lb.component.ts
51812function DoraDataGridSelectorLbComponent_div_0_Template(rf, ctx) {
51813  if (rf & 1) {
51814    const _r1 = \u0275\u0275getCurrentView();
51815    \u0275\u0275elementStart(0, "div", 3);
51816    \u0275\u0275listener("click", function DoraDataGridSelectorLbComponent_div_0_Template_div_click_0_listener() {
51817      \u0275\u0275restoreView(_r1);
51818      const ctx_r1 = \u0275\u0275nextContext();
51819      return \u0275\u0275resetView(ctx_r1.onEnableSetting());
51820    });
51821    \u0275\u0275elementEnd();
51822  }
51823}
51824var DoraDataGridSelectorLbComponent = class _DoraDataGridSelectorLbComponent extends DoraDataGridSelectorComponent {
51825  constructor() {
51826    super(...arguments);
51827    this.selectedStr = "";
51828    this.gridList = [];
51829    this.placeholder = "ng2-select-placeholder";
51830  }
51831  /**
51832   * Received new data
51833   */
51834  onNewData() {
51835    super.onNewData();
51836    this.gridList = [];
51837    for (const dataRow of this.dataRows) {
51838      const descriptionTupla = dataRow.getDataTupla("Description");
51839      if (descriptionTupla !== void 0) {
51840        this.gridList.push({ value: dataRow.Id, label: descriptionTupla.Value });
51841      }
51842    }
51843  }
51844  selected(value) {
51845    console.log("Selected value is: ", value);
51846    this.selectedGrid(value.value);
51847  }
51848  removed(value) {
51849    console.log("Removed value is: ", value);
51850  }
51851  typed(value) {
51852    console.log("New search input: ", value);
51853  }
51854  refreshValue(value) {
51855    this.selectedStr = value;
51856  }
51857  /**
51858   * Get placeholder for empty value.
51859   * It is translated
51860   */
51861  getPlaceholer() {
51862    if (this.flSelectFirstRow) {
51863      try {
51864        return this.dataGrid?.DataRows[0].getDataTupla("Description")?.DataType ?? "";
51865      } catch (e) {
51866        return "";
51867      }
51868    }
51869    return this.translationService.getWithDefault(this.placeholder, "");
51870  }
51871  static {
51872    this.\u0275fac = /* @__PURE__ */ (() => {
51873      let \u0275DoraDataGridSelectorLbComponent_BaseFactory;
51874      return function DoraDataGridSelectorLbComponent_Factory(__ngFactoryType__) {
51875        return (\u0275DoraDataGridSelectorLbComponent_BaseFactory || (\u0275DoraDataGridSelectorLbComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraDataGridSelectorLbComponent)))(__ngFactoryType__ || _DoraDataGridSelectorLbComponent);
51876      };
51877    })();
51878  }
51879  static {
51880    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraDataGridSelectorLbComponent, selectors: [["dora-data-grid-selector-lb"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 3, vars: 5, consts: [["class", "setting-command", 3, "click", 4, "ngIf"], [1, "DAG-data-grid-selector-lb"], [3, "ngModelChange", "change", "add", "remove", "search", "clearable", "items", "ngModel", "placeholder"], [1, "setting-command", 3, "click"]], template: function DoraDataGridSelectorLbComponent_Template(rf, ctx) {
51881      if (rf & 1) {
51882        \u0275\u0275template(0, DoraDataGridSelectorLbComponent_div_0_Template, 1, 0, "div", 0);
51883        \u0275\u0275elementStart(1, "div", 1)(2, "ng-select", 2);
51884        \u0275\u0275twoWayListener("ngModelChange", function DoraDataGridSelectorLbComponent_Template_ng_select_ngModelChange_2_listener($event) {
51885          \u0275\u0275twoWayBindingSet(ctx.gridList[0], $event) || (ctx.gridList[0] = $event);
51886          return $event;
51887        });
51888        \u0275\u0275listener("change", function DoraDataGridSelectorLbComponent_Template_ng_select_change_2_listener($event) {
51889          return ctx.selected($event);
51890        })("add", function DoraDataGridSelectorLbComponent_Template_ng_select_add_2_listener($event) {
51891          return ctx.selected($event);
51892        })("remove", function DoraDataGridSelectorLbComponent_Template_ng_select_remove_2_listener($event) {
51893          return ctx.removed($event);
51894        })("search", function DoraDataGridSelectorLbComponent_Template_ng_select_search_2_listener($event) {
51895          return ctx.typed($event);
51896        });
51897        \u0275\u0275elementEnd()();
51898      }
51899      if (rf & 2) {
51900        \u0275\u0275property("ngIf", ctx.settingEnabled);
51901        \u0275\u0275advance(2);
51902        \u0275\u0275property("clearable", true)("items", ctx.gridList);
51903        \u0275\u0275twoWayProperty("ngModel", ctx.gridList[0]);
51904        \u0275\u0275property("placeholder", ctx.getPlaceholer());
51905      }
51906    }, dependencies: [NgIf, NgControlStatus, NgSelectComponent, NgModel], encapsulation: 2 });
51907  }
51908};
51909__decorate([
51910  DoraProperty,
51911  __metadata("design:type", String)
51912], DoraDataGridSelectorLbComponent.prototype, "placeholder", void 0);
51913(() => {
51914  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraDataGridSelectorLbComponent, { className: "DoraDataGridSelectorLbComponent", filePath: "src/app/dorawidget/dora-data-grid-selector/dora-data-grid-selector-lb/dora-data-grid-selector-lb.component.ts", lineNumber: 12 });
51915})();
51916
51917// src/app/DoraWidget/dora-column-selector/dora-column-selector.component.ts
51918var DoraColumnSelectorComponent = class _DoraColumnSelectorComponent extends WidgetBaseGridComponent {
51919  onNewData() {
51920    super.onNewData();
51921    if (this.dataGrid) {
51922      this.dataGrid.selectColumnsByType(TUPLA_TYPE.NUMBER);
51923    }
51924    this.sendMessage();
51925  }
51926  selectionChanged(columnId, selected) {
51927    let dataTuplaDescription;
51928    if (this.dataGrid) {
51929      dataTuplaDescription = this.dataGrid.getTuplaDescription(columnId);
51930      if (dataTuplaDescription === void 0) {
51931        console.error("Column not found. Id: " + columnId);
51932        return;
51933      }
51934      dataTuplaDescription.selected = selected;
51935      this.sendMessage();
51936    }
51937  }
51938  sendMessage() {
51939    const ids = [];
51940    if (this.dataGrid) {
51941      this.dataGrid.getSelectedColumns().forEach((tuplaDescription) => {
51942        ids.push(tuplaDescription.Id);
51943      });
51944      this.messageService.sendMessage(this.EventChannel, new MessageColumnsSelected(ids), this.CallerName);
51945    }
51946  }
51947  static {
51948    this.\u0275fac = /* @__PURE__ */ (() => {
51949      let \u0275DoraColumnSelectorComponent_BaseFactory;
51950      return function DoraColumnSelectorComponent_Factory(__ngFactoryType__) {
51951        return (\u0275DoraColumnSelectorComponent_BaseFactory || (\u0275DoraColumnSelectorComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraColumnSelectorComponent)))(__ngFactoryType__ || _DoraColumnSelectorComponent);
51952      };
51953    })();
51954  }
51955  static {
51956    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraColumnSelectorComponent, selectors: [["dora-column-selector"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 0, vars: 0, template: function DoraColumnSelectorComponent_Template(rf, ctx) {
51957    }, encapsulation: 2 });
51958  }
51959};
51960(() => {
51961  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraColumnSelectorComponent, { className: "DoraColumnSelectorComponent", filePath: "src/app/dorawidget/dora-column-selector/dora-column-selector.component.ts", lineNumber: 17 });
51962})();
51963
51964// src/app/DoraWidget/dora-column-selector/dora-column-selector-lb/dora-column-selector-lb.component.ts
51965var DoraColumnSelectorLbComponent = class _DoraColumnSelectorLbComponent extends DoraColumnSelectorComponent {
51966  constructor() {
51967    super(...arguments);
51968    this.columnList = [];
51969    this.selectedItem = [];
51970  }
51971  onNewData() {
51972    super.onNewData();
51973    this.columnList = [];
51974    this.selectedItem = [];
51975    if (this.dataGrid && this.dataGrid.tuplasDescription) {
51976      this.dataGrid.tuplasDescription.filter((x) => x.Type === TUPLA_TYPE.NUMBER).forEach((tuplaDescription) => {
51977        const selectElement = { id: `${tuplaDescription.Id}`, text: `<div class="DAG-img-select" style="width: 10px; height: 10px; background-color: red; display: inline-block;"></div>${tuplaDescription.Name}` };
51978        this.columnList.push(selectElement);
51979        this.selectedItem.push(selectElement);
51980        tuplaDescription.selected = true;
51981      });
51982    }
51983  }
51984  selected(value) {
51985    console.log("Selected value is: ", value);
51986    this.selectionChanged(value.id, true);
51987  }
51988  removed(value) {
51989    console.log("Removed value is: ", value);
51990    this.selectionChanged(value.id, false);
51991  }
51992  typed(value) {
51993    console.log("New search input: ", value);
51994  }
51995  refreshValue(value) {
51996    console.log("Typed: ", value);
51997  }
51998  static {
51999    this.\u0275fac = /* @__PURE__ */ (() => {
52000      let \u0275DoraColumnSelectorLbComponent_BaseFactory;
52001      return function DoraColumnSelectorLbComponent_Factory(__ngFactoryType__) {
52002        return (\u0275DoraColumnSelectorLbComponent_BaseFactory || (\u0275DoraColumnSelectorLbComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraColumnSelectorLbComponent)))(__ngFactoryType__ || _DoraColumnSelectorLbComponent);
52003      };
52004    })();
52005  }
52006  static {
52007    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraColumnSelectorLbComponent, selectors: [["dora-column-selector-lb"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 2, vars: 4, consts: [[1, "DAG-dora-column-selector-lb"], ["placeholder", "Columns", 3, "ngModelChange", "change", "clear", "clearable", "items", "ngModel", "multiple"]], template: function DoraColumnSelectorLbComponent_Template(rf, ctx) {
52008      if (rf & 1) {
52009        \u0275\u0275elementStart(0, "div", 0)(1, "ng-select", 1);
52010        \u0275\u0275twoWayListener("ngModelChange", function DoraColumnSelectorLbComponent_Template_ng_select_ngModelChange_1_listener($event) {
52011          \u0275\u0275twoWayBindingSet(ctx.selectedItem, $event) || (ctx.selectedItem = $event);
52012          return $event;
52013        });
52014        \u0275\u0275listener("change", function DoraColumnSelectorLbComponent_Template_ng_select_change_1_listener($event) {
52015          return ctx.selected($event);
52016        })("clear", function DoraColumnSelectorLbComponent_Template_ng_select_clear_1_listener($event) {
52017          return ctx.removed($event);
52018        });
52019        \u0275\u0275elementEnd()();
52020      }
52021      if (rf & 2) {
52022        \u0275\u0275advance();
52023        \u0275\u0275property("clearable", true)("items", ctx.columnList);
52024        \u0275\u0275twoWayProperty("ngModel", ctx.selectedItem);
52025        \u0275\u0275property("multiple", true);
52026      }
52027    }, dependencies: [NgControlStatus, NgSelectComponent, NgModel], encapsulation: 2 });
52028  }
52029};
52030(() => {
52031  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraColumnSelectorLbComponent, { className: "DoraColumnSelectorLbComponent", filePath: "src/app/dorawidget/dora-column-selector/dora-column-selector-lb/dora-column-selector-lb.component.ts", lineNumber: 11 });
52032})();
52033
52034// src/app/DoraWidget/dora-column-paginator/dora-column-paginator.component.ts
52035function DoraColumnPaginatorComponent_div_0_div_1_Template(rf, ctx) {
52036  if (rf & 1) {
52037    const _r1 = \u0275\u0275getCurrentView();
52038    \u0275\u0275elementStart(0, "div", 3);
52039    \u0275\u0275listener("click", function DoraColumnPaginatorComponent_div_0_div_1_Template_div_click_0_listener() {
52040      const i_r2 = \u0275\u0275restoreView(_r1).index;
52041      const ctx_r2 = \u0275\u0275nextContext(2);
52042      return \u0275\u0275resetView(ctx_r2.onPageSelected(i_r2));
52043    });
52044    \u0275\u0275text(1);
52045    \u0275\u0275elementEnd();
52046  }
52047  if (rf & 2) {
52048    const i_r2 = ctx.index;
52049    const ctx_r2 = \u0275\u0275nextContext(2);
52050    \u0275\u0275classMap(ctx_r2.getPageClass(i_r2));
52051    \u0275\u0275advance();
52052    \u0275\u0275textInterpolate1(" ", i_r2 + 1, " ");
52053  }
52054}
52055function DoraColumnPaginatorComponent_div_0_Template(rf, ctx) {
52056  if (rf & 1) {
52057    \u0275\u0275elementStart(0, "div", 1);
52058    \u0275\u0275template(1, DoraColumnPaginatorComponent_div_0_div_1_Template, 2, 3, "div", 2);
52059    \u0275\u0275elementEnd();
52060  }
52061  if (rf & 2) {
52062    const ctx_r2 = \u0275\u0275nextContext();
52063    \u0275\u0275advance();
52064    \u0275\u0275property("ngForOf", ctx_r2.getPagesIdx());
52065  }
52066}
52067var DoraColumnPaginatorComponent = class _DoraColumnPaginatorComponent extends WidgetBaseGridComponent {
52068  constructor() {
52069    super(...arguments);
52070    this.fixedColumn = 2;
52071    this.floatColumn = 4;
52072    this.flInitialPositionOnLast = false;
52073    this.pagesNumber = 0;
52074    this.currentPage = 0;
52075  }
52076  onNewData() {
52077    super.onNewData();
52078    if (this.dataGrid && this.dataGrid.tuplasDescription) {
52079      this.pagesNumber = Math.ceil((this.dataGrid.tuplasDescription.length - this.fixedColumn) / this.floatColumn);
52080      this.currentPage = this.flInitialPositionOnLast ? this.pagesNumber - 1 : 0;
52081      this.setActiveColumns();
52082    }
52083  }
52084  getPagesIdx() {
52085    return new Array(this.pagesNumber);
52086  }
52087  setActiveColumns() {
52088    if (this.dataGrid) {
52089      this.dataGrid.setAllColumnsInvisible();
52090      if (this.dataGrid.tuplasDescription) {
52091        let idx = 0;
52092        for (idx = 0; idx < this.fixedColumn; idx++) {
52093          this.dataGrid.tuplasDescription[idx].visible = true;
52094        }
52095        const start = this.fixedColumn + this.currentPage * this.floatColumn;
52096        let end = start + this.floatColumn;
52097        if (end > this.dataGrid.tuplasDescription.length) {
52098          end = this.dataGrid.tuplasDescription.length;
52099        }
52100        for (idx = start; idx < end; idx++) {
52101          this.dataGrid.tuplasDescription[idx].visible = true;
52102        }
52103        this.messageService.sendMessage(this.EventChannel, new MessageColumnsVisible(this.dataGrid.getColumnsVisible()), this.CallerName);
52104      }
52105    }
52106  }
52107  getPageClass(pageNumber) {
52108    let result = "DAG-page-element";
52109    if (pageNumber === this.currentPage) {
52110      result += " selected";
52111    } else {
52112      result += " unselected";
52113    }
52114    return result;
52115  }
52116  onPageSelected(pageNumber) {
52117    this.currentPage = pageNumber;
52118    this.setActiveColumns();
52119  }
52120  static {
52121    this.\u0275fac = /* @__PURE__ */ (() => {
52122      let \u0275DoraColumnPaginatorComponent_BaseFactory;
52123      return function DoraColumnPaginatorComponent_Factory(__ngFactoryType__) {
52124        return (\u0275DoraColumnPaginatorComponent_BaseFactory || (\u0275DoraColumnPaginatorComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraColumnPaginatorComponent)))(__ngFactoryType__ || _DoraColumnPaginatorComponent);
52125      };
52126    })();
52127  }
52128  static {
52129    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraColumnPaginatorComponent, selectors: [["dora-column-paginator"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "DAG-column-paginator", 4, "ngIf"], [1, "DAG-column-paginator"], [3, "class", "click", 4, "ngFor", "ngForOf"], [3, "click"]], template: function DoraColumnPaginatorComponent_Template(rf, ctx) {
52130      if (rf & 1) {
52131        \u0275\u0275template(0, DoraColumnPaginatorComponent_div_0_Template, 2, 1, "div", 0);
52132      }
52133      if (rf & 2) {
52134        \u0275\u0275property("ngIf", ctx.dataGrid);
52135      }
52136    }
52136, dependencies: [NgForOf, NgIf], styles: ["\n\n.DAG-column-paginator[_ngcontent-%COMP%]   .DAG-page-element[_ngcontent-%COMP%] {\n  float: left;\n  color: black;\n}\n.DAG-column-paginator[_ngcontent-%COMP%]   .DAG-page-element.selected[_ngcontent-%COMP%] {\n  pointer-events: none;\n  color: red;\n}\n.DAG-column-paginator[_ngcontent-%COMP%]   .DAG-page-element.unselected[_ngcontent-%COMP%] {\n  cursor: pointer;\n}"] });
52137  }
52138};
52139__decorate([
52140  DoraProperty,
52141  __metadata("design:type", Number)
52142], DoraColumnPaginatorComponent.prototype, "fixedColumn", void 0);
52143__decorate([
52144  DoraProperty,
52145  __metadata("design:type", Number)
52146], DoraColumnPaginatorComponent.prototype, "floatColumn", void 0);
52147__decorate([
52148  DoraProperty,
52149  __metadata("design:type", Boolean)
52150], DoraColumnPaginatorComponent.prototype, "flInitialPositionOnLast", void 0);
52151(() => {
52152  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraColumnPaginatorComponent, { className: "DoraColumnPaginatorComponent", filePath: "src/app/dorawidget/dora-column-paginator/dora-column-paginator.component.ts", lineNumber: 12 });
52153})();
52154
52155// src/app/DoraWidget/dora-rows-notes/dora-rows-notes.component.ts
52156function DoraRowsNotesComponent_div_0_div_1_Template(rf, ctx) {
52157  if (rf & 1) {
52158    \u0275\u0275element(0, "div", 3);
52159  }
52160  if (rf & 2) {
52161    const note_r1 = ctx.$implicit;
52162    \u0275\u0275property("innerHTML", note_r1, \u0275\u0275sanitizeHtml);
52163  }
52164}
52165function DoraRowsNotesComponent_div_0_Template(rf, ctx) {
52166  if (rf & 1) {
52167    \u0275\u0275elementStart(0, "div", 1);
52168    \u0275\u0275template(1, DoraRowsNotesComponent_div_0_div_1_Template, 1, 1, "div", 2);
52169    \u0275\u0275elementEnd();
52170  }
52171  if (rf & 2) {
52172    const ctx_r1 = \u0275\u0275nextContext();
52173    \u0275\u0275advance();
52174    \u0275\u0275property("ngForOf", ctx_r1.notes);
52175  }
52176}
52177var DoraRowsNotesComponent = class _DoraRowsNotesComponent extends WidgetBaseGridComponent {
52178  constructor(elementRef, messageService, configurationService, publisher, widgetService, http, translationService) {
52179    super(elementRef, messageService, configurationService, publisher, widgetService, http, translationService);
52180    this.notes = [];
52181    this.flSelectFirstRow = false;
52182  }
52183  onParameterInjectedFinished() {
52184    super.onParameterInjectedFinished();
52185    this.messageService.getMessage(this.EventChannel, MessageRowsSelected, this.CallerName).subscribe((message) => {
52186      const idRows = [];
52187      message.data.DataRows.forEach((dataRow) => {
52188        idRows.push(dataRow.Id);
52189      });
52190      if (this.dataGrid) {
52191        this.dataGrid.selectRows(idRows);
52192      }
52193      this.buildNotes();
52194    });
52195  }
52196  buildNotes() {
52197    this.notes = [];
52198    if (this.dataGrid) {
52199      this.dataGrid.getSelectedRows().forEach((dataRow) => {
52200        if (dataRow.Note === void 0 || dataRow.Note === "") {
52201          return;
52202        }
52203        if (this.notes.find((note) => note === dataRow.Note) === void 0) {
52204          this.notes.push(dataRow.Note);
52205        }
52206      });
52207    }
52208  }
52209  static {
52210    this.\u0275fac = function DoraRowsNotesComponent_Factory(__ngFactoryType__) {
52211      return new (__ngFactoryType__ || _DoraRowsNotesComponent)(\u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(MessageService), \u0275\u0275directiveInject(ConfigurationService), \u0275\u0275directiveInject(PublisherService), \u0275\u0275directiveInject(WidgetService), \u0275\u0275directiveInject(HttpClient), \u0275\u0275directiveInject(TranslationService));
52212    };
52213  }
52214  static {
52215    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraRowsNotesComponent, selectors: [["dora-rows-notes"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "DAG-dora-rows-notes", 4, "ngIf"], [1, "DAG-dora-rows-notes"], ["class", "DAG-note", 3, "innerHTML", 4, "ngFor", "ngForOf"], [1, "DAG-note", 3, "innerHTML"]], template: function DoraRowsNotesComponent_Template(rf, ctx) {
52216      if (rf & 1) {
52217        \u0275\u0275template(0, DoraRowsNotesComponent_div_0_Template, 2, 1, "div", 0);
52218      }
52219      if (rf & 2) {
52220        \u0275\u0275property("ngIf", ctx.dataGrid);
52221      }
52222    }, dependencies: [NgForOf, NgIf], encapsulation: 2 });
52223  }
52224};
52225(() => {
52226  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraRowsNotesComponent, { className: "DoraRowsNotesComponent", filePath: "src/app/dorawidget/dora-rows-notes/dora-rows-notes.component.ts", lineNumber: 19 });
52227})();
52228
52229// src/app/DoraWidget/dora-chart-print/dora-chart-print.component.ts
52230function DoraChartPrintComponent_div_0_Template(rf, ctx) {
52231  if (rf & 1) {
52232    const _r1 = \u0275\u0275getCurrentView();
52233    \u0275\u0275elementStart(0, "div", 1);
52234    \u0275\u0275listener("click", function DoraChartPrintComponent_div_0_Template_div_click_0_listener() {
52235      \u0275\u0275restoreView(_r1);
52236      const ctx_r1 = \u0275\u0275nextContext();
52237      return \u0275\u0275resetView(ctx_r1.onClick());
52238    });
52239    \u0275\u0275text(1);
52240    \u0275\u0275elementEnd();
52241  }
52242  if (rf & 2) {
52243    const ctx_r1 = \u0275\u0275nextContext();
52244    \u0275\u0275advance();
52245    \u0275\u0275textInterpolate1("\n", ctx_r1.text, "\n");
52246  }
52247}
52248var DoraChartPrintComponent = class _DoraChartPrintComponent extends WidgetBaseComponent {
52249  constructor() {
52250    super(...arguments);
52251    this.textId = "PNG";
52252    this.text = "";
52253    this.outputType = "image/png";
52254  }
52255  onParameterInjectedFinished() {
52256    super.onParameterInjectedFinished();
52257    this.text = this.translationService.get(this.textId);
52258  }
52259  onClick() {
52260    this.messageService.sendMessage(this.EventChannel, new MessageChartPrint(this.outputType), this.CallerName);
52261  }
52262  static {
52263    this.\u0275fac = /* @__PURE__ */ (() => {
52264      let \u0275DoraChartPrintComponent_BaseFactory;
52265      return function DoraChartPrintComponent_Factory(__ngFactoryType__) {
52266        return (\u0275DoraChartPrintComponent_BaseFactory || (\u0275DoraChartPrintComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraChartPrintComponent)))(__ngFactoryType__ || _DoraChartPrintComponent);
52267      };
52268    })();
52269  }
52270  static {
52271    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraChartPrintComponent, selectors: [["dora-chart-print"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "DAG-chart-print", 3, "click", 4, "ngIf"], [1, "DAG-chart-print", 3, "click"]], template: function DoraChartPrintComponent_Template(rf, ctx) {
52272      if (rf & 1) {
52273        \u0275\u0275template(0, DoraChartPrintComponent_div_0_Template, 2, 1, "div", 0);
52274      }
52275      if (rf & 2) {
52276        \u0275\u0275property("ngIf", ctx.text);
52277      }
52278    }, dependencies: [NgIf], encapsulation: 2 });
52279  }
52280};
52281__decorate([
52282  DoraProperty,
52283  __metadata("design:type", String)
52284], DoraChartPrintComponent.prototype, "textId", void 0);
52285__decorate([
52286  DoraProperty,
52287  __metadata("design:type", String)
52288], DoraChartPrintComponent.prototype, "outputType", void 0);
52289(() => {
52290  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraChartPrintComponent, { className: "DoraChartPrintComponent", filePath: "src/app/dorawidget/dora-chart-print/dora-chart-print.component.ts", lineNumber: 12 });
52291})();
52292
52293// src/app/DoraWidget/dora-collapse-expand/dora-collapse-expand.component.ts
52294function DoraCollapseExpandComponent_div_0_Template(rf, ctx) {
52295  if (rf & 1) {
52296    const _r1 = \u0275\u0275getCurrentView();
52297    \u0275\u0275elementStart(0, "div", 1)(1, "div", 2);
52298    \u0275\u0275listener("click", function DoraCollapseExpandComponent_div_0_Template_div_click_1_listener() {
52299      \u0275\u0275restoreView(_r1);
52300      const ctx_r1 = \u0275\u0275nextContext();
52301      return \u0275\u0275resetView(ctx_r1.onSelect());
52302    });
52303    \u0275\u0275elementStart(2, "div");
52304    \u0275\u0275text(3);
52305    \u0275\u0275elementEnd()()();
52306  }
52307  if (rf & 2) {
52308    const ctx_r1 = \u0275\u0275nextContext();
52309    \u0275\u0275advance();
52310    \u0275\u0275classMap(ctx_r1.getContainerCssClass());
52311    \u0275\u0275advance();
52312    \u0275\u0275classMap(ctx_r1.getContentCssClass());
52313    \u0275\u0275advance();
52314    \u0275\u0275textInterpolate1(" ", ctx_r1.text, " ");
52315  }
52316}
52317var DoraCollapseExpandComponent = class _DoraCollapseExpandComponent extends WidgetBaseComponent {
52318  constructor() {
52319    super(...arguments);
52320    this.text = "";
52321    this.currentStatusExpanded = false;
52322    this.textExpanded = "";
52323    this.textCollapsed = "";
52324    this.initialStatusExpanded = true;
52325    this.elementReferenceId = "";
52326  }
52327  onParameterInjectedFinished() {
52328    super.onParameterInjectedFinished();
52329    this.currentStatusExpanded = this.initialStatusExpanded;
52330    this.updateValues();
52331  }
52332  getContainerCssClass() {
52333    const result = "DAG-container " + (this.currentStatusExpanded === true ? "expanded" : "collapsed");
52334    return result;
52335  }
52336  getContentCssClass() {
52337    const result = "DAG-content " + (this.currentStatusExpanded === true ? "expanded" : "collapsed");
52338    return result;
52339  }
52340  onSelect() {
52341    this.currentStatusExpanded = !this.currentStatusExpanded;
52342    this.updateValues();
52343  }
52344  updateValues() {
52345    if (this.currentStatusExpanded) {
52346      this.text = this.translationService.get(this.textExpanded);
52347      const element = document.getElementById(this.elementReferenceId);
52348      if (element) {
52349        element.classList.remove("DAG-hide");
52350        element.classList.add("DAG-show");
52351      }
52352    } else {
52353      this.text = this.translationService.get(this.textCollapsed);
52354      const element = document.getElementById(this.elementReferenceId);
52355      if (element) {
52356        element.classList.remove("DAG-show");
52357        element.classList.add("DAG-hide");
52358      }
52359    }
52360  }
52361  static {
52362    this.\u0275fac = /* @__PURE__ */ (() => {
52363      let \u0275DoraCollapseExpandComponent_BaseFactory;
52364      return function DoraCollapseExpandComponent_Factory(__ngFactoryType__) {
52365        return (\u0275DoraCollapseExpandComponent_BaseFactory || (\u0275DoraCollapseExpandComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraCollapseExpandComponent)))(__ngFactoryType__ || _DoraCollapseExpandComponent);
52366      };
52367    })();
52368  }
52369  static {
52370    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraCollapseExpandComponent, selectors: [["dora-collapse-expand"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "DAG-collapse-expand", 4, "ngIf"], [1, "DAG-collapse-expand"], [3, "click"]], template: function DoraCollapseExpandComponent_Template(rf, ctx) {
52371      if (rf & 1) {
52372        \u0275\u0275template(0, DoraCollapseExpandComponent_div_0_Template, 4, 5, "div", 0);
52373      }
52374      if (rf & 2) {
52375        \u0275\u0275property("ngIf", ctx.text);
52376      }
52377    }, dependencies: [NgIf], encapsulation: 2 });
52378  }
52379};
52380__decorate([
52381  DoraProperty,
52382  __metadata("design:type", String)
52383], DoraCollapseExpandComponent.prototype, "textExpanded", void 0);
52384__decorate([
52385  DoraProperty,
52386  __metadata("design:type", String)
52387], DoraCollapseExpandComponent.prototype, "textCollapsed", void 0);
52388__decorate([
52389  DoraProperty,
52390  __metadata("design:type", Boolean)
52391], DoraCollapseExpandComponent.prototype, "initialStatusExpanded", void 0);
52392__decorate([
52393  DoraProperty,
52394  __metadata("design:type", String)
52395], DoraCollapseExpandComponent.prototype, "elementReferenceId", void 0);
52396(() => {
52397  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraCollapseExpandComponent, { className: "DoraCollapseExpandComponent", filePath: "src/app/dorawidget/dora-collapse-expand/dora-collapse-expand.component.ts", lineNumber: 11 });
52398})();
52399
52400// src/app/DoraWidget/dora-grid-title/dora-grid-title.component.ts
52401function DoraGridTitleComponent_div_0_Template(rf, ctx) {
52402  if (rf & 1) {
52403    \u0275\u0275element(0, "div", 1);
52404  }
52405  if (rf & 2) {
52406    const ctx_r0 = \u0275\u0275nextContext();
52407    \u0275\u0275property("innerHTML", ctx_r0.text, \u0275\u0275sanitizeHtml);
52408  }
52409}
52410var DoraGridTitleComponent = class _DoraGridTitleComponent extends WidgetBaseComponent {
52411  constructor() {
52412    super(...arguments);
52413    this.text = "";
52414  }
52415  onParameterInjectedFinished() {
52416    super.onParameterInjectedFinished();
52417    this.messageService.getMessage(this.EventChannel, MessageGridSelected, this.CallerName).subscribe((message) => {
52418      this.text = message.data.description;
52419    });
52420  }
52421  static {
52422    this.\u0275fac = /* @__PURE__ */ (() => {
52423      let \u0275DoraGridTitleComponent_BaseFactory;
52424      return function DoraGridTitleComponent_Factory(__ngFactoryType__) {
52425        return (\u0275DoraGridTitleComponent_BaseFactory || (\u0275DoraGridTitleComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraGridTitleComponent)))(__ngFactoryType__ || _DoraGridTitleComponent);
52426      };
52427    })();
52428  }
52429  static {
52430    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraGridTitleComponent, selectors: [["dora-grid-title"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "DAG-dora-grid-title", 3, "innerHTML", 4, "ngIf"], [1, "DAG-dora-grid-title", 3, "innerHTML"]], template: function DoraGridTitleComponent_Template(rf, ctx) {
52431      if (rf & 1) {
52432        \u0275\u0275template(0, DoraGridTitleComponent_div_0_Template, 1, 1, "div", 0);
52433      }
52434      if (rf & 2) {
52435        \u0275\u0275property("ngIf", ctx.text);
52436      }
52437    }, dependencies: [NgIf], encapsulation: 2 });
52438  }
52439};
52440(() => {
52441  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraGridTitleComponent, { className: "DoraGridTitleComponent", filePath: "src/app/dorawidget/dora-grid-title/dora-grid-title.component.ts", lineNumber: 12 });
52442})();
52443
52444// src/app/DoraWidget/dora-rows-preselect/data/preselect-element.ts
52445var PreselectElement = class {
52446  constructor(dataRow) {
52447    this._description = "";
52448    this._img = "";
52449    this._gridIdRowList = "";
52450    this._level = 1;
52451    this._id = "";
52452    this._children = [];
52453    this._selected = false;
52454    this._description = dataRow.Description;
52455    this._level = dataRow.Level;
52456    this._gridIdRowList = dataRow.GridId;
52457    this._img = dataRow.getTuplaValue("Img", "");
52458    this._id = dataRow.Id;
52459  }
52460  get id() {
52461    return this._id;
52462  }
52463  get description() {
52464    return this._description;
52465  }
52466  get img() {
52467    return this._img;
52468  }
52469  get gridIdRowList() {
52470    return this._gridIdRowList;
52471  }
52472  get level() {
52473    return this._level;
52474  }
52475  get selected() {
52476    return this._selected;
52477  }
52478  set selected(value) {
52479    this._selected = value;
52480  }
52481  get children() {
52482    return this._children;
52483  }
52484  /**
52485   * Deselect preselect and children
52486   */
52487  deselect() {
52488    this._selected = false;
52489    this.children.forEach((x) => x.deselect());
52490  }
52491  findElement(id) {
52492    if (this.id === id) {
52493      return this;
52494    }
52495    for (const child of this.children) {
52496      const found = child.findElement(id);
52497      if (found !== null) {
52498        return found;
52499      }
52500    }
52501    return null;
52502  }
52503};
52504
52505// src/app/DoraWidget/dora-rows-preselect/data/preselect-elements.ts
52506var PreselectElements = class {
52507  constructor(levelMin, levelMax) {
52508    this.preselectElements = [];
52509    this.levelMin = 1;
52510    this.levelMax = 1;
52511    this.levelMin = levelMin;
52512    this.levelMax = levelMax;
52513  }
52514  /**
52515   * Load preselectElements tree from datagrid
52516   */
52517  loadPreselectElements(dataRows) {
52518    this.preselectElements = [];
52519    this.loadPreselectElementsLevel(dataRows, 1, 0, this.preselectElements);
52520  }
52521  loadPreselectElementsLevel(dataRows, level, rowIdx, preselectElementsTarget) {
52522    for (let idx = rowIdx; idx < dataRows.length; idx++) {
52523      const dataRow = dataRows[idx];
52524      if (dataRow.Level === level) {
52525        preselectElementsTarget.push(new PreselectElement(dataRow));
52526      } else if (dataRow.Level === level + 1) {
52527        idx = this.loadPreselectElementsLevel(dataRows, dataRow.Level, idx, preselectElementsTarget[preselectElementsTarget.length - 1].children);
52528      } else if (dataRow.Level === level - 1) {
52529        return idx - 1;
52530      } else {
52531        console.error("Preselect idx error");
52532        break;
52533      }
52534    }
52535    return dataRows.length;
52536  }
52537  onSelect(preselectId) {
52538    this.preselectElements.forEach((x) => x.deselect());
52539    const preselectedElementSelected = this.findElement(preselectId);
52540    if (preselectedElementSelected === null) {
52541      console.error("PreselectElement " + preselectId + " not found");
52542      return void 0;
52543    }
52544    if (preselectedElementSelected.level >= this.levelMin - 1 && preselectedElementSelected.level < this.levelMax) {
52545      preselectedElementSelected.children[0].selected = true;
52546      return preselectedElementSelected.children[0];
52547    }
52548    return void 0;
52549  }
52550  findElement(id) {
52551    for (const x of this.preselectElements) {
52552      const found = x.findElement(id);
52553      if (found !== null) {
52554        return found;
52555      }
52556    }
52557    return null;
52558  }
52559};
52560
52561// src/app/DoraWidget/dora-rows-preselect/dora-rows-preselect.component.ts
52562var DoraRowsPreselectComponent = class _DoraRowsPreselectComponent extends WidgetBaseGridComponent {
52563  constructor() {
52564    super(...arguments);
52565    this.preselectElements = void 0;
52566    this.levelMin = 1;
52567    this.levelMax = 1;
52568  }
52569  // tslint:disable-next-line:use-life-cycle-interface
52570  ngOnInit() {
52571    super.ngOnInit();
52572    this.gridIdPostfix = "_Preselect";
52573    this.flSelectFirstRow = true;
52574  }
52575  onParameterInjectedFinished() {
52576    super.onParameterInjectedFinished();
52577    this.preselectElements = new PreselectElements(this.levelMin, this.levelMax);
52578  }
52579  onRefresh() {
52580    super.onRefresh();
52581    this.readData();
52582  }
52583  onNewData() {
52584    super.onNewData();
52585    if (this.dataGrid && this.preselectElements) {
52586      this.preselectElements.loadPreselectElements(this.dataGrid.DataRows);
52587    }
52588  }
52589  selectedGrid(rowId) {
52590    super.selectedGrid(rowId);
52591    let dataRow;
52592    if (this.dataGrid) {
52593      dataRow = this.dataGrid.getDataRow(rowId);
52594      if (!dataRow) {
52595        console.error("Row not found. Id: " + rowId);
52596        return;
52597      }
52598      this.dataGrid.selectRowMutex(dataRow.Id);
52599      const prelesectTableTupla = dataRow.getDataTupla("GridIdRowList");
52600      let preselectTableName = "";
52601      if (prelesectTableTupla === void 0) {
52602        preselectTableName = this.gridId + "_" + rowId + "_RowList";
52603      } else {
52604        preselectTableName = prelesectTableTupla.Value;
52605      }
52606      this.read([preselectTableName], DataType.GRID).subscribe((data) => {
52607        const dataGrid = data.Data;
52608        this.messageService.sendMessage(this.EventChannel, new MessageRowsSelected(dataGrid.DataRows), this.CallerName);
52609      });
52610    }
52611  }
52612  static {
52613    this.\u0275fac = /* @__PURE__ */ (() => {
52614      let \u0275DoraRowsPreselectComponent_BaseFactory;
52615      return function DoraRowsPreselectComponent_Factory(__ngFactoryType__) {
52616        return (\u0275DoraRowsPreselectComponent_BaseFactory || (\u0275DoraRowsPreselectComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraRowsPreselectComponent)))(__ngFactoryType__ || _DoraRowsPreselectComponent);
52617      };
52618    })();
52619  }
52620  static {
52621    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraRowsPreselectComponent, selectors: [["dora-rows-preselect"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 0, vars: 0, template: function DoraRowsPreselectComponent_Template(rf, ctx) {
52622    }, encapsulation: 2 });
52623  }
52624};
52625__decorate([
52626  DoraProperty,
52627  __metadata("design:type", Number)
52628], DoraRowsPreselectComponent.prototype, "levelMin", void 0);
52629__decorate([
52630  DoraProperty,
52631  __metadata("design:type", Number)
52632], DoraRowsPreselectComponent.prototype, "levelMax", void 0);
52633(() => {
52634  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraRowsPreselectComponent, { className: "DoraRowsPreselectComponent", filePath: "src/app/dorawidget/dora-rows-preselect/dora-rows-preselect.component.ts", lineNumber: 20 });
52635})();
52636
52637// src/app/DoraWidget/dora-rows-preselect/dora-rows-preselect-lb/dora-rows-preselect-lb.component.ts
52638function DoraRowsPreselectLbComponent_div_0_Template(rf, ctx) {
52639  if (rf & 1) {
52640    const _r1 = \u0275\u0275getCurrentView();
52641    \u0275\u0275elementStart(0, "div", 1)(1, "ng-select", 2);
52642    \u0275\u0275twoWayListener("ngModelChange", function DoraRowsPreselectLbComponent_div_0_Template_ng_select_ngModelChange_1_listener($event) {
52643      \u0275\u0275restoreView(_r1);
52644      const ctx_r1 = \u0275\u0275nextContext();
52645      \u0275\u0275twoWayBindingSet(ctx_r1.selectedItem, $event) || (ctx_r1.selectedItem = $event);
52646      return \u0275\u0275resetView($event);
52647    });
52648    \u0275\u0275listener("change", function DoraRowsPreselectLbComponent_div_0_Template_ng_select_change_1_listener($event) {
52649      \u0275\u0275restoreView(_r1);
52650      const ctx_r1 = \u0275\u0275nextContext();
52651      return \u0275\u0275resetView(ctx_r1.selected($event));
52652    });
52653    \u0275\u0275elementEnd()();
52654  }
52655  if (rf & 2) {
52656    const ctx_r1 = \u0275\u0275nextContext();
52657    \u0275\u0275advance();
52658    \u0275\u0275property("clearable", false)("items", ctx_r1.gridList);
52659    \u0275\u0275twoWayProperty("ngModel", ctx_r1.selectedItem);
52660  }
52661}
52662var DoraRowsPreselectLbComponent = class _DoraRowsPreselectLbComponent extends DoraRowsPreselectComponent {
52663  constructor() {
52664    super(...arguments);
52665    this.selectedItem = [];
52666    this.gridList = [];
52667  }
52668  /**
52669   * Received new data
52670   */
52671  onNewData() {
52672    super.onNewData();
52673    this.gridList = [];
52674    this.selectedItem = [];
52675    for (const dataRow of this.dataGrid.DataRows) {
52676      const descriptionTupla = dataRow.getDataTupla("Description");
52677      if (descriptionTupla) {
52678        const selectElement = { id: dataRow.Id, text: `<div class="DAG-img-select" style="width: 10px; height: 10px; display: inline-block;"></div>${descriptionTupla.Value}` };
52679        this.gridList.push(selectElement);
52680        if (dataRow.selected) {
52681          this.selectedItem.push(selectElement);
52682        }
52683      }
52684    }
52685  }
52686  selected(value) {
52687    console.log("Selected value is: ", value);
52688    this.selectedGrid(value.id);
52689  }
52690  static {
52691    this.\u0275fac = /* @__PURE__ */ (() => {
52692      let \u0275DoraRowsPreselectLbComponent_BaseFactory;
52693      return function DoraRowsPreselectLbComponent_Factory(__ngFactoryType__) {
52694        return (\u0275DoraRowsPreselectLbComponent_BaseFactory || (\u0275DoraRowsPreselectLbComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraRowsPreselectLbComponent)))(__ngFactoryType__ || _DoraRowsPreselectLbComponent);
52695      };
52696    })();
52697  }
52698  static {
52699    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraRowsPreselectLbComponent, selectors: [["dora-rows-preselect-lb"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "DAG-rows-preselect-lb", 4, "ngIf"], [1, "DAG-rows-preselect-lb"], ["placeholder", "Grid", 3, "ngModelChange", "change", "clearable", "items", "ngModel"]], template: function DoraRowsPreselectLbComponent_Template(rf, ctx) {
52700      if (rf & 1) {
52701        \u0275\u0275template(0, DoraRowsPreselectLbComponent_div_0_Template, 2, 3, "div", 0);
52702      }
52703      if (rf & 2) {
52704        \u0275\u0275property("ngIf", ctx.dataGrid);
52705      }
52706    }, dependencies: [NgIf, NgControlStatus, NgSelectComponent, NgModel], encapsulation: 2 });
52707  }
52708};
52709(() => {
52710  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraRowsPreselectLbComponent, { className: "DoraRowsPreselectLbComponent", filePath: "src/app/dorawidget/dora-rows-preselect/dora-rows-preselect-lb/dora-rows-preselect-lb.component.ts", lineNumber: 12 });
52711})();
52712
52713// src/app/DoraWidget/dora-rows-preselect/dora-rows-preselect-tab/dora-rows-preselect-tab.component.ts
52714function DoraRowsPreselectTabComponent_div_0_div_1_Template(rf, ctx) {
52715  if (rf & 1) {
52716    const _r1 = \u0275\u0275getCurrentView();
52717    \u0275\u0275elementStart(0, "div", 3);
52718    \u0275\u0275listener("click", function DoraRowsPreselectTabComponent_div_0_div_1_Template_div_click_0_listener() {
52719      const ctx_r1 = \u0275\u0275restoreView(_r1);
52720      const row_r3 = ctx_r1.$implicit;
52721      const rowIdx_r4 = ctx_r1.index;
52722      const ctx_r4 = \u0275\u0275nextContext(2);
52723      return \u0275\u0275resetView(ctx_r4.onSelect(rowIdx_r4, row_r3));
52724    });
52725    \u0275\u0275elementStart(1, "div");
52726    \u0275\u0275text(2);
52727    \u0275\u0275elementEnd()();
52728  }
52729  if (rf & 2) {
52730    const row_r3 = ctx.$implicit;
52731    const rowIdx_r4 = ctx.index;
52732    const ctx_r4 = \u0275\u0275nextContext(2);
52733    \u0275\u0275classMap(ctx_r4.getElementContainerCssClass(rowIdx_r4, row_r3));
52734    \u0275\u0275advance();
52735    \u0275\u0275classMap(ctx_r4.getElementContentCssClass(rowIdx_r4, row_r3));
52736    \u0275\u0275advance();
52737    \u0275\u0275textInterpolate1(" ", ctx_r4.getElementContent(rowIdx_r4, row_r3), " ");
52738  }
52739}
52740function DoraRowsPreselectTabComponent_div_0_Template(rf, ctx) {
52741  if (rf & 1) {
52742    \u0275\u0275elementStart(0, "div", 1);
52743    \u0275\u0275template(1, DoraRowsPreselectTabComponent_div_0_div_1_Template, 3, 5, "div", 2);
52744    \u0275\u0275elementEnd();
52745  }
52746  if (rf & 2) {
52747    const ctx_r4 = \u0275\u0275nextContext();
52748    \u0275\u0275advance();
52749    \u0275\u0275property("ngForOf", ctx_r4.dataGrid.DataRows);
52750  }
52751}
52752var DoraRowsPreselectTabComponent = class _DoraRowsPreselectTabComponent extends DoraRowsPreselectComponent {
52753  onSelect(rowIndex, dataRow) {
52754    this.selectedGrid(dataRow.Id);
52755  }
52756  // Methods for Css Class
52757  getElementContainerCssClass(rowIndex, dataRow) {
52758    let result;
52759    result = "tab-element-container " + dataRow.CssFormat;
52760    result += dataRow.selected ? " on" : " off";
52761    if (rowIndex === 0) {
52762      result = " first";
52763    } else if (this.dataGrid && rowIndex === this.dataGrid.DataRows.length - 1) {
52764      result = " last";
52765    }
52766    return result;
52767  }
52768  getElementContentCssClass(rowIndex, dataRow) {
52769    return "tab-element-content";
52770  }
52771  getElementContent(rowIndex, dataRow) {
52772    let result = "";
52773    const descriptionTupla = dataRow.getDataTupla("Description");
52774    if (descriptionTupla) {
52775      result = descriptionTupla.Value;
52776    }
52777    return result;
52778  }
52779  static {
52780    this.\u0275fac = /* @__PURE__ */ (() => {
52781      let \u0275DoraRowsPreselectTabComponent_BaseFactory;
52782      return function DoraRowsPreselectTabComponent_Factory(__ngFactoryType__) {
52783        return (\u0275DoraRowsPreselectTabComponent_BaseFactory || (\u0275DoraRowsPreselectTabComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraRowsPreselectTabComponent)))(__ngFactoryType__ || _DoraRowsPreselectTabComponent);
52784      };
52785    })();
52786  }
52787  static {
52788    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraRowsPreselectTabComponent, selectors: [["dora-rows-preselect-tab"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "DAG-rows-preselect-tab", 4, "ngIf"], [1, "DAG-rows-preselect-tab"], [3, "class", "click", 4, "ngFor", "ngForOf"], [3, "click"]], template: function DoraRowsPreselectTabComponent_Template(rf, ctx) {
52789      if (rf & 1) {
52790        \u0275\u0275template(0, DoraRowsPreselectTabComponent_div_0_Template, 2, 1, "div", 0);
52791      }
52792      if (rf & 2) {
52793        \u0275\u0275property("ngIf", ctx.dataGrid);
52794      }
52795    }, dependencies: [NgForOf, NgIf], encapsulation: 2 });
52796  }
52797};
52798(() => {
52799  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraRowsPreselectTabComponent, { className: "DoraRowsPreselectTabComponent", filePath: "src/app/dorawidget/dora-rows-preselect/dora-rows-preselect-tab/dora-rows-preselect-tab.component.ts", lineNumber: 12 });
52800})();
52801
52802// src/app/DoraWidget/dora-series-fixed/dora-series-fixed.component.ts
52803var DoraSeriesFixedComponent = class _DoraSeriesFixedComponent extends WidgetBaseComponent {
52804  constructor() {
52805    super(...arguments);
52806    this.label = "FIXED_SERIES";
52807    this.chekBoxSelected = false;
52808    this.fixedDataAvaiable = false;
52809    this.dateRangeFull = true;
52810  }
52811  onParameterInjectedFinished() {
52812    super.onParameterInjectedFinished();
52813    this.messageService.getMessage(this.EventChannel, MessageDataFixedAvaiable, this.CallerName).subscribe((doraMessage) => {
52814      this.fixedDataAvaiable = doraMessage.data.isAvaiable;
52815    });
52816    this.messageService.getMessage(this.EventChannel, MessageSeriesTypeSelected, this.CallerName).subscribe((doraMessage) => {
52817      const dateRange = doraMessage.data.seriesSelectorType.dateRange;
52818      if (dateRange === null || dateRange === void 0) {
52819        this.dateRangeFull = true;
52820      } else {
52821        this.dateRangeFull = false;
52822      }
52823    });
52824    this.sendEvent();
52825  }
52826  onSelectorChange() {
52827    this.chekBoxSelected = !this.chekBoxSelected;
52828    this.sendEvent();
52829  }
52830  getLabel() {
52831    return this.translationService.get(this.label);
52832  }
52833  sendEvent() {
52834    this.messageService.sendMessage(this.EventChannel, new MessageSeriesFixedEnabled(this.chekBoxSelected), this.CallerName);
52835  }
52836  getGlobalCssClass() {
52837    let cssClass = "DAG-Series-Fixed";
52838    if (this.fixedDataAvaiable && this.dateRangeFull) {
52839      cssClass += " enabled";
52840    } else {
52841      cssClass += " disabled";
52842    }
52843    return cssClass;
52844  }
52845  static {
52846    this.\u0275fac = /* @__PURE__ */ (() => {
52847      let \u0275DoraSeriesFixedComponent_BaseFactory;
52848      return function DoraSeriesFixedComponent_Factory(__ngFactoryType__) {
52849        return (\u0275DoraSeriesFixedComponent_BaseFactory || (\u0275DoraSeriesFixedComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraSeriesFixedComponent)))(__ngFactoryType__ || _DoraSeriesFixedComponent);
52850      };
52851    })();
52852  }
52853  static {
52854    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraSeriesFixedComponent, selectors: [["dora-series-fixed"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 4, vars: 5, consts: [[1, "selector-container"], [3, "click"], [1, "dag-label", 3, "innerHTML"]], template: function DoraSeriesFixedComponent_Template(rf, ctx) {
52855      if (rf & 1) {
52856        \u0275\u0275elementStart(0, "div")(1, "div", 0)(2, "div", 1);
52857        \u0275\u0275listener("click", function DoraSeriesFixedComponent_Template_div_click_2_listener() {
52858          return ctx.onSelectorChange();
52859        });
52860        \u0275\u0275elementEnd()();
52861        \u0275\u0275element(3, "div", 2);
52862        \u0275\u0275elementEnd();
52863      }
52864      if (rf & 2) {
52865        \u0275\u0275classMap(ctx.getGlobalCssClass());
52866        \u0275\u0275advance(2);
52867        \u0275\u0275classMap(ctx.chekBoxSelected ? "dag-checkbox on" : "dag-checkbox off");
52868        \u0275\u0275advance();
52869        \u0275\u0275property("innerHTML", ctx.getLabel(), \u0275\u0275sanitizeHtml);
52870      }
52871    }, styles: ["\n\n.DAG-Series-Fixed[_ngcontent-%COMP%] {\n  color: black;\n  display: flex;\n  gap: 10px;\n}\n.DAG-Series-Fixed.disabled[_ngcontent-%COMP%] {\n  pointer-events: none;\n  opacity: 0.4;\n}\n.DAG-Series-Fixed.disabled[_ngcontent-%COMP%]   .dag-label[_ngcontent-%COMP%] {\n  opacity: 0.4;\n}\n.DAG-Series-Fixed[_ngcontent-%COMP%]   .selector-container[_ngcontent-%COMP%]   .dag-checkbox[_ngcontent-%COMP%] {\n  cursor: pointer;\n  width: 10px;\n  height: 10px;\n  display: block;\n  overflow: hidden;\n  border: 1px solid black;\n}\n.DAG-Series-Fixed[_ngcontent-%COMP%]   .selector-container[_ngcontent-%COMP%]   .dag-checkbox.on[_ngcontent-%COMP%] {\n  background-color: black;\n}\n.DAG-Series-Fixed[_ngcontent-%COMP%]   .selector-container[_ngcontent-%COMP%]   .dag-checkbox.off[_ngcontent-%COMP%] {\n  background-color: white;\n}"] });
52872  }
52873};
52874__decorate([
52875  DoraProperty,
52876  __metadata("design:type", String)
52877], DoraSeriesFixedComponent.prototype, "label", void 0);
52878(() => {
52879  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraSeriesFixedComponent, { className: "DoraSeriesFixedComponent", filePath: "src/app/dorawidget/dora-series-fixed/dora-series-fixed.component.ts", lineNumber: 14 });
52880})();
52881
52882// src/app/DoraWidget/dora-series-value/dora-series-value.component.ts
52883function DoraSeriesValueComponent_div_0_div_2_Template(rf, ctx) {
52884  if (rf & 1) {
52885    \u0275\u0275element(0, "div", 5);
52886  }
52887  if (rf & 2) {
52888    const ctx_r0 = \u0275\u0275nextContext(2);
52889    \u0275\u0275property("innerHTML", ctx_r0.dataSeries.Units, \u0275\u0275sanitizeHtml);
52890  }
52891}
52892function DoraSeriesValueComponent_div_0_div_4_Template(rf, ctx) {
52893  if (rf & 1) {
52894    \u0275\u0275element(0, "div", 5);
52895  }
52896  if (rf & 2) {
52897    const ctx_r0 = \u0275\u0275nextContext(2);
52898    \u0275\u0275property("innerHTML", ctx_r0.dataSeries.Units, \u0275\u0275sanitizeHtml);
52899  }
52900}
52901function DoraSeriesValueComponent_div_0_Template(rf, ctx) {
52902  if (rf & 1) {
52903    \u0275\u0275elementStart(0, "div", 1)(1, "div", 2);
52904    \u0275\u0275template(2, DoraSeriesValueComponent_div_0_div_2_Template, 1, 1, "div", 3);
52905    \u0275\u0275element(3, "div", 4);
52906    \u0275\u0275template(4, DoraSeriesValueComponent_div_0_div_4_Template, 1, 1, "div", 3);
52907    \u0275\u0275elementEnd()();
52908  }
52909  if (rf & 2) {
52910    const ctx_r0 = \u0275\u0275nextContext();
52911    \u0275\u0275advance(2);
52912    \u0275\u0275property("ngIf", !ctx_r0.unitOnRight && ctx_r0.dataSeries.Units !== null);
52913    \u0275\u0275advance();
52914    \u0275\u0275property("innerHTML", ctx_r0.currentValue, \u0275\u0275sanitizeHtml);
52915    \u0275\u0275advance();
52916    \u0275\u0275property("ngIf", ctx_r0.unitOnRight && ctx_r0.dataSeries.Units !== null);
52917  }
52918}
52919var DoraSeriesValueComponent = class _DoraSeriesValueComponent extends WidgetBaseComponent {
52920  constructor() {
52921    super(...arguments);
52922    this.seriesId = "";
52923    this.animation_time = 2e3;
52924    this.outputFormat = "###,###";
52925    this.unitOnRight = true;
52926    this.dataSeries = void 0;
52927    this.startDate = void 0;
52928    this.startValue = 0;
52929    this.endDate = void 0;
52930    this.endValue = 0;
52931    this.currentValue = "";
52932    this.dateGap = 0;
52933  }
52934  onParameterInjectedFinished() {
52935    super.onParameterInjectedFinished();
52936    this.readData();
52937  }
52938  readData() {
52939    if (this.seriesId === null || this.seriesId === "") {
52940      return;
52941    }
52942    this.read([this.seriesId], DataType.HISTORICAL).subscribe((data) => {
52943      if (data !== null) {
52944        const readResult = data;
52945        if (readResult.Data !== null) {
52946          this.dataSeries = readResult.Data;
52947          this.onNewData();
52948        }
52949      }
52950    });
52951  }
52952  onNewData() {
52953    const now2 = /* @__PURE__ */ new Date();
52954    this.startDate = this.endDate = void 0;
52955    let i;
52956    if (this.dataSeries) {
52957      for (i = 0; i < this.dataSeries.DataRows.length; i++) {
52958        const dataRow = this.dataSeries.DataRows[i];
52959        const rowTimestamp = dataRow.getTuplaValue("Timestamp", "");
52960        if (rowTimestamp === null) {
52961          return;
52962        }
52963        if (rowTimestamp >= now2) {
52964          this.endDate = rowTimestamp;
52965          this.endValue = dataRow.getTuplaValue("Close", "");
52966          break;
52967        }
52968        if (rowTimestamp <= now2) {
52969          this.startDate = rowTimestamp;
52970          this.startValue = dataRow.getTuplaValue("Close", "");
52971        }
52972      }
52973    }
52974    if (this.startValue !== 0 && this.endValue !== 0 && this.startDate && this.endDate) {
52975      this.dateGap = this.endDate.getTime() - this.startDate.getTime();
52976      this.buildData();
52977      this.checkTimer();
52978    }
52979  }
52980  buildData() {
52981    let currentValueNumber = 0;
52982    if (this.startValue !== 0 && this.endValue !== 0 && this.startDate) {
52983      const now2 = (/* @__PURE__ */ new Date()).getTime();
52984      const diffValue = this.endValue - this.startValue;
52985      currentValueNumber = this.startValue + diffValue * (now2 - this.startDate.getTime()) / this.dateGap;
52986    } else {
52987      currentValueNumber = 0;
52988    }
52989    this.currentValue = DoraNumber.formatNumber(currentValueNumber, null, this.outputFormat);
52990  }
52991  checkTimer() {
52992    const myTime = timer(this.animation_time);
52993    myTime.subscribe((value) => {
52994      this.buildData();
52995      this.checkTimer();
52996    });
52997  }
52998  static {
52999    this.\u0275fac = /* @__PURE__ */ (() => {
53000      let \u0275DoraSeriesValueComponent_BaseFactory;
53001      return function DoraSeriesValueComponent_Factory(__ngFactoryType__) {
53002        return (\u0275DoraSeriesValueComponent_BaseFactory || (\u0275DoraSeriesValueComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraSeriesValueComponent)))(__ngFactoryType__ || _DoraSeriesValueComponent);
53003      };
53004    })();
53005  }
53006  static {
53007    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraSeriesValueComponent, selectors: [["dora-series-value"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "DAG-dora-series-value", 4, "ngIf"], [1, "DAG-dora-series-value"], [1, "container"], ["class", "units", 3, "innerHTML", 4, "ngIf"], [1, "value", 3, "innerHTML"], [1, "units", 3, "innerHTML"]], template: function DoraSeriesValueComponent_Template(rf, ctx) {
53008      if (rf & 1) {
53009        \u0275\u0275template(0, DoraSeriesValueComponent_div_0_Template, 5, 3, "div", 0);
53010      }
53011      if (rf & 2) {
53012        \u0275\u0275property("ngIf", ctx.seriesId && ctx.dataSeries);
53013      }
53014    }, dependencies: [NgIf], encapsulation: 2 });
53015  }
53016};
53017__decorate([
53018  DoraProperty,
53019  __metadata("design:type", String)
53020], DoraSeriesValueComponent.prototype, "seriesId", void 0);
53021__decorate([
53022  DoraProperty,
53023  __metadata("design:type", Number)
53024], DoraSeriesValueComponent.prototype, "animation_time", void 0);
53025__decorate([
53026  DoraProperty,
53027  __metadata("design:type", String)
53028], DoraSeriesValueComponent.prototype, "outputFormat", void 0);
53029__decorate([
53030  DoraProperty,
53031  __metadata("design:type", Boolean)
53032], DoraSeriesValueComponent.prototype, "unitOnRight", void 0);
53033(() => {
53034  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraSeriesValueComponent, { className: "DoraSeriesValueComponent", filePath: "src/app/dorawidget/dora-series-value/dora-series-value.component.ts", lineNumber: 19 });
53035})();
53036
53037// src/app/DoraWidget/dora-chart-type-setting/Data/chart-type-element.ts
53038var ChartTypeElement = class {
53039  constructor(type, description) {
53040    this.flActive = false;
53041    this._description = "";
53042    this.type = type;
53043    this._description = description;
53044  }
53045  get FlActive() {
53046    return this.flActive;
53047  }
53048  set FlActive(value) {
53049    this.flActive = value;
53050  }
53051  get Type() {
53052    return this.type;
53053  }
53054  get description() {
53055    return this._description;
53056  }
53057};
53058
53059// src/app/DoraWidget/dora-chart-type-setting/dora-chart-type-setting.component.ts
53060var DoraChartTypeSettingComponent = class _DoraChartTypeSettingComponent extends WidgetBaseComponent {
53061  constructor() {
53062    super(...arguments);
53063    this.flLinearEnabled = true;
53064    this.flSpinEnabled = false;
53065    this.flColumnEnabled = true;
53066    this.flColumnStackEnabled = true;
53067    this.flBarEnabled = true;
53068    this.flPieEnabled = true;
53069    this.chartTypeElements = [];
53070    this.defaultType = "LINEAR";
53071  }
53072  onParameterInjectedFinished() {
53073    super.onParameterInjectedFinished();
53074    if (this.flLinearEnabled) {
53075      this.chartTypeElements.push(new ChartTypeElement(CHART_TYPE.LINEAR, CHART_TYPE[CHART_TYPE.LINEAR]));
53076    }
53077    if (this.flSpinEnabled) {
53078      this.chartTypeElements.push(new ChartTypeElement(CHART_TYPE.SPLINE, CHART_TYPE[CHART_TYPE.SPLINE]));
53079    }
53080    if (this.flColumnEnabled) {
53081      this.chartTypeElements.push(new ChartTypeElement(CHART_TYPE.COLUMN, CHART_TYPE[CHART_TYPE.COLUMN]));
53082    }
53083    if (this.flColumnStackEnabled) {
53084      this.chartTypeElements.push(new ChartTypeElement(CHART_TYPE.COLUMNSTACK, CHART_TYPE[CHART_TYPE.COLUMNSTACK]));
53085    }
53086    if (this.flBarEnabled) {
53087      this.chartTypeElements.push(new ChartTypeElement(CHART_TYPE.BAR, CHART_TYPE[CHART_TYPE.BAR]));
53088    }
53089    if (this.flPieEnabled) {
53090      this.chartTypeElements.push(new ChartTypeElement(CHART_TYPE.PIE, CHART_TYPE[CHART_TYPE.PIE]));
53091    }
53092    const typedDefaultChartType = CHART_TYPE[this.defaultType.toUpperCase()];
53093    if (typedDefaultChartType === void 0) {
53094      console.error("CHART_TYPE " + this.defaultType + " not allowed");
53095      return;
53096    }
53097    this.activeChartType(typedDefaultChartType);
53098  }
53099  activeChartType(type2activate) {
53100    this.chartTypeElements.forEach((chartTypeElement) => {
53101      if (chartTypeElement.Type === type2activate) {
53102        chartTypeElement.FlActive = true;
53103        this.messageService.sendMessage(this.EventChannel, new MessageChartType(type2activate), this.CallerName);
53104      } else {
53105        chartTypeElement.FlActive = false;
53106      }
53107    });
53108  }
53109  static {
53110    this.\u0275fac = /* @__PURE__ */ (() => {
53111      let \u0275DoraChartTypeSettingComponent_BaseFactory;
53112      return function DoraChartTypeSettingComponent_Factory(__ngFactoryType__) {
53113        return (\u0275DoraChartTypeSettingComponent_BaseFactory || (\u0275DoraChartTypeSettingComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraChartTypeSettingComponent)))(__ngFactoryType__ || _DoraChartTypeSettingComponent);
53114      };
53115    })();
53116  }
53117  static {
53118    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraChartTypeSettingComponent, selectors: [["dora-chart-type-setting"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 0, vars: 0, template: function DoraChartTypeSettingComponent_Template(rf, ctx) {
53119    }, encapsulation: 2 });
53120  }
53121};
53122__decorate([
53123  DoraPropertyDOC("Abilita Opzione LINEAR", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
53124  DoraProperty,
53125  __metadata("design:type", Boolean)
53126], DoraChartTypeSettingComponent.prototype, "flLinearEnabled", void 0);
53127__decorate([
53128  DoraPropertyDOC("Abilita Opzione SPIN", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
53129  DoraProperty,
53130  __metadata("design:type", Boolean)
53131], DoraChartTypeSettingComponent.prototype, "flSpinEnabled", void 0);
53132__decorate([
53133  DoraPropertyDOC("Abilita Opzione COLUMN", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
53134  DoraProperty,
53135  __metadata("design:type", Boolean)
53136], DoraChartTypeSettingComponent.prototype, "flColumnEnabled", void 0);
53137__decorate([
53138  DoraPropertyDOC("Abilita Opzione COLUMNSTACK", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
53139  DoraProperty,
53140  __metadata("design:type", Boolean)
53141], DoraChartTypeSettingComponent.prototype, "flColumnStackEnabled", void 0);
53142__decorate([
53143  DoraPropertyDOC("Abilita Opzione BAR", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
53144  DoraProperty,
53145  __metadata("design:type", Boolean)
53146], DoraChartTypeSettingComponent.prototype, "flBarEnabled", void 0);
53147__decorate([
53148  DoraPropertyDOC("Abilita Opzione PIE", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
53149  DoraProperty,
53150  __metadata("design:type", Boolean)
53151], DoraChartTypeSettingComponent.prototype, "flPieEnabled", void 0);
53152__decorate([
53153  DoraPropertyDOC("Default chart type", ATTRIBUTE_TYPE.STRING, "LINEAR\xA7SPLINE\xA7COLUMN\xA7PIE\xA7\xA7COLUMNSTACK\xA7BAR", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
53154  DoraProperty,
53155  __metadata("design:type", String)
53156], DoraChartTypeSettingComponent.prototype, "defaultType", void 0);
53157(() => {
53158  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraChartTypeSettingComponent, { className: "DoraChartTypeSettingComponent", filePath: "src/app/dorawidget/dora-chart-type-setting/dora-chart-type-setting.component.ts", lineNumber: 17 });
53159})();
53160
53161// src/app/DoraWidget/dora-chart-type-setting/dora-chart-type-setting-lb/dora-chart-type-setting-lb.component.ts
53162function DoraChartTypeSettingLbComponent_div_0_Template(rf, ctx) {
53163  if (rf & 1) {
53164    const _r1 = \u0275\u0275getCurrentView();
53165    \u0275\u0275elementStart(0, "div", 3);
53166    \u0275\u0275listener("click", function DoraChartTypeSettingLbComponent_div_0_Template_div_click_0_listener() {
53167      \u0275\u0275restoreView(_r1);
53168      const ctx_r1 = \u0275\u0275nextContext();
53169      return \u0275\u0275resetView(ctx_r1.onEnableSetting());
53170    });
53171    \u0275\u0275elementEnd();
53172  }
53173}
53174var DoraChartTypeSettingLbComponent = class _DoraChartTypeSettingLbComponent extends DoraChartTypeSettingComponent {
53175  constructor() {
53176    super(...arguments);
53177    this.chartTypeLista = [];
53178    this.selectedItem = [];
53179  }
53180  onParameterInjectedFinished() {
53181    super.onParameterInjectedFinished();
53182    this.chartTypeLista = [];
53183    this.selectedItem = [];
53184    this.chartTypeElements.forEach((chartTypeElement) => {
53185      const selectElement = { id: `${chartTypeElement.Type}`, text: `<div class="DAG-img-select ${CHART_TYPE[chartTypeElement.Type]}" ></div>${chartTypeElement.description}` };
53186      this.chartTypeLista.push(selectElement);
53187      if (chartTypeElement.FlActive) {
53188        this.selectedItem.push(selectElement);
53189      }
53190    });
53191  }
53192  selected(value) {
53193    console.log("Selected value is: ", value);
53194    const chartTypeSelected = Number(value.id);
53195    this.activeChartType(chartTypeSelected);
53196  }
53197  removed(value) {
53198    console.log("Removed value is: ", value);
53199  }
53200  typed(value) {
53201    console.log("New search input: ", value);
53202  }
53203  refreshValue(value) {
53204    console.log("Typed: ", value);
53205  }
53206  static {
53207    this.\u0275fac = /* @__PURE__ */ (() => {
53208      let \u0275DoraChartTypeSettingLbComponent_BaseFactory;
53209      return function DoraChartTypeSettingLbComponent_Factory(__ngFactoryType__) {
53210        return (\u0275DoraChartTypeSettingLbComponent_BaseFactory || (\u0275DoraChartTypeSettingLbComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraChartTypeSettingLbComponent)))(__ngFactoryType__ || _DoraChartTypeSettingLbComponent);
53211      };
53212    })();
53213  }
53214  static {
53215    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraChartTypeSettingLbComponent, selectors: [["dora-chart-type-setting-lb"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 3, vars: 4, consts: [["class", "setting-command", 3, "click", 4, "ngIf"], [1, "DAG-dora-chart-type-setting-lb"], ["placeholder", "Chart type", 3, "ngModelChange", "change", "clearable", "items", "ngModel"], [1, "setting-command", 3, "click"]], template: function DoraChartTypeSettingLbComponent_Template(rf, ctx) {
53216      if (rf & 1) {
53217        \u0275\u0275template(0, DoraChartTypeSettingLbComponent_div_0_Template, 1, 0, "div", 0);
53218        \u0275\u0275elementStart(1, "div", 1)(2, "ng-select", 2);
53219        \u0275\u0275twoWayListener("ngModelChange", function DoraChartTypeSettingLbComponent_Template_ng_select_ngModelChange_2_listener($event) {
53220          \u0275\u0275twoWayBindingSet(ctx.selectedItem, $event) || (ctx.selectedItem = $event);
53221          return $event;
53222        });
53223        \u0275\u0275listener("change", function DoraChartTypeSettingLbComponent_Template_ng_select_change_2_listener($event) {
53224          return ctx.selected($event);
53225        });
53226        \u0275\u0275elementEnd()();
53227      }
53228      if (rf & 2) {
53229        \u0275\u0275property("ngIf", ctx.settingEnabled);
53230        \u0275\u0275advance(2);
53231        \u0275\u0275property("clearable", false)("items", ctx.chartTypeLista);
53232        \u0275\u0275twoWayProperty("ngModel", ctx.selectedItem);
53233      }
53234    }, dependencies: [NgIf, NgControlStatus, NgSelectComponent, NgModel], styles: ["\n\n.DAG-dora-chart-type-setting-lb[_ngcontent-%COMP%] {\n  width: 300px;\n  margin-bottom: 20px;\n}"] });
53235  }
53236};
53237(() => {
53238  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraChartTypeSettingLbComponent, { className: "DoraChartTypeSettingLbComponent", filePath: "src/app/dorawidget/dora-chart-type-setting/dora-chart-type-setting-lb/dora-chart-type-setting-lb.component.ts", lineNumber: 12 });
53239})();
53240
53241// src/app/DoraWidget/dora-tab/Data/tab-element.ts
53242var TabElement = class {
53243  constructor(name = "", elementReferenceId = "", active = false) {
53244    this._active = false;
53245    this.name = name;
53246    this.elementReferenceId = elementReferenceId;
53247    this._active = active;
53248  }
53249  get active() {
53250    return this._active;
53251  }
53252  set active(value) {
53253    this._active = value;
53254  }
53255};
53256__decorate([
53257  DoraProperty,
53258  __metadata("design:type", String)
53259], TabElement.prototype, "name", void 0);
53260__decorate([
53261  DoraProperty,
53262  __metadata("design:type", String)
53263], TabElement.prototype, "elementReferenceId", void 0);
53264
53265// src/app/DoraWidget/dora-tab/dora-tab.component.ts
53266function DoraTabComponent_div_0_div_1_Template(rf, ctx) {
53267  if (rf & 1) {
53268    const _r1 = \u0275\u0275getCurrentView();
53269    \u0275\u0275elementStart(0, "div", 3);
53270    \u0275\u0275listener("click", function DoraTabComponent_div_0_div_1_Template_div_click_0_listener() {
53271      const ctx_r1 = \u0275\u0275restoreView(_r1);
53272      const tabElement_r3 = ctx_r1.$implicit;
53273      const tabIdx_r4 = ctx_r1.index;
53274      const ctx_r4 = \u0275\u0275nextContext(2);
53275      return \u0275\u0275resetView(ctx_r4.onSelect(tabIdx_r4, tabElement_r3));
53276    });
53277    \u0275\u0275elementStart(1, "div");
53278    \u0275\u0275text(2);
53279    \u0275\u0275elementEnd()();
53280  }
53281  if (rf & 2) {
53282    const tabElement_r3 = ctx.$implicit;
53283    const tabIdx_r4 = ctx.index;
53284    const ctx_r4 = \u0275\u0275nextContext(2);
53285    \u0275\u0275classMap(ctx_r4.getTabContainerCssClass(tabIdx_r4, tabElement_r3));
53286    \u0275\u0275advance();
53287    \u0275\u0275classMap(ctx_r4.getElementContentCssClass(tabIdx_r4, tabElement_r3));
53288    \u0275\u0275advance();
53289    \u0275\u0275textInterpolate1(" ", ctx_r4.getElementContent(tabIdx_r4, tabElement_r3), " ");
53290  }
53291}
53292function DoraTabComponent_div_0_Template(rf, ctx) {
53293  if (rf & 1) {
53294    \u0275\u0275elementStart(0, "div", 1);
53295    \u0275\u0275template(1, DoraTabComponent_div_0_div_1_Template, 3, 5, "div", 2);
53296    \u0275\u0275elementEnd();
53297  }
53298  if (rf & 2) {
53299    const ctx_r4 = \u0275\u0275nextContext();
53300    \u0275\u0275advance();
53301    \u0275\u0275property("ngForOf", ctx_r4.tabElements);
53302  }
53303}
53304var DoraTabComponent = class _DoraTabComponent extends WidgetBaseComponent {
53305  constructor() {
53306    super(...arguments);
53307    this.defaultTabIdx = 0;
53308    this.tabElements = [];
53309  }
53310  onParameterInjectedFinished() {
53311    super.onParameterInjectedFinished();
53312    if (this.defaultTabIdx < this.tabElements.length) {
53313      this.onSelect(this.defaultTabIdx, this.tabElements[this.defaultTabIdx]);
53314    }
53315  }
53316  // CSS
53317  getTabContainerCssClass(tabIdx, tabElement) {
53318    let result = "DAG-container";
53319    if (tabElement.active) {
53320      result += " DAG-active";
53321    }
53322    return result;
53323  }
53324  getElementContentCssClass(tabIdx, tabElement) {
53325    return "DAG-content";
53326  }
53327  // Content
53328  getElementContent(tabIdx, tabElement) {
53329    return tabElement.name;
53330  }
53331  // User interaction
53332  onSelect(tabIdx, tabElement) {
53333    this.tabElements.forEach((x) => {
53334      const element = document.getElementById(x.elementReferenceId);
53335      if (x.elementReferenceId === tabElement.elementReferenceId) {
53336        x.active = true;
53337        if (element) {
53338          element.classList.remove("DAG-hide");
53339          element.classList.add("DAG-show");
53340        }
53341      } else {
53342        x.active = false;
53343        if (element) {
53344          element.classList.remove("DAG-show");
53345          element.classList.add("DAG-hide");
53346        }
53347      }
53348    });
53349  }
53350  static {
53351    this.\u0275fac = /* @__PURE__ */ (() => {
53352      let \u0275DoraTabComponent_BaseFactory;
53353      return function DoraTabComponent_Factory(__ngFactoryType__) {
53354        return (\u0275DoraTabComponent_BaseFactory || (\u0275DoraTabComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraTabComponent)))(__ngFactoryType__ || _DoraTabComponent);
53355      };
53356    })();
53357  }
53358  static {
53359    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraTabComponent, selectors: [["dora-tab"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "DAG-tab", 4, "ngIf"], [1, "DAG-tab"], [3, "class", "click", 4, "ngFor", "ngForOf"], [3, "click"]], template: function DoraTabComponent_Template(rf, ctx) {
53360      if (rf & 1) {
53361        \u0275\u0275template(0, DoraTabComponent_div_0_Template, 2, 1, "div", 0);
53362      }
53363      if (rf & 2) {
53364        \u0275\u0275property("ngIf", ctx.tabElements);
53365      }
53366    }, dependencies: [NgForOf, NgIf], styles: ["\n\n.DAG-tab[_ngcontent-%COMP%]   .DAG-container[_ngcontent-%COMP%] {\n  float: left;\n  cursor: pointer;\n}\n.DAG-tab[_ngcontent-%COMP%]   .DAG-container[_ngcontent-%COMP%]:hover, \n.DAG-tab[_ngcontent-%COMP%]   .DAG-container.DAG-active[_ngcontent-%COMP%] {\n  background-color: cornflowerblue;\n  color: white;\n}\n.DAG-tab[_ngcontent-%COMP%]   .DAG-container[_ngcontent-%COMP%]   .DAG-content[_ngcontent-%COMP%] {\n  padding-left: 10px;\n  padding-right: 10px;\n}"] });
53367  }
53368};
53369__decorate([
53370  DoraPropertyArray(TabElement),
53371  __metadata("design:type", Array)
53372], DoraTabComponent.prototype, "tabElements", void 0);
53373(() => {
53374  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraTabComponent, { className: "DoraTabComponent", filePath: "src/app/dorawidget/dora-tab/dora-tab.component.ts", lineNumber: 12 });
53375})();
53376
53377// src/app/messages/message-corporate-agent-user-input.ts
53378var MessageCorporateAgentUserInput = class _MessageCorporateAgentUserInput extends MessageBase {
53379  constructor(question, conversationId) {
53380    super(_MessageCorporateAgentUserInput);
53381    this.question = question;
53382    this.conversationId = conversationId;
53383  }
53384};
53385
53386// src/app/messages/message-corporate-agent-wizard-input.ts
53387var MessageCorporateAgentWizardInput = class _MessageCorporateAgentWizardInput extends MessageBase {
53388  constructor(question) {
53389    super(_MessageCorporateAgentWizardInput);
53390    this.question = question;
53391  }
53392};
53393
53394// src/app/messages/message-corporate-agent-wizard-visible.ts
53395var MessageCorporateAgentWizardVisible = class _MessageCorporateAgentWizardVisible extends MessageBase {
53396  constructor(visible = true) {
53397    super(_MessageCorporateAgentWizardVisible);
53398    this.visible = true;
53399    this.visible = visible;
53400  }
53401};
53402
53403// src/app/messages/message-corporate-agent-history-length.ts
53404var MessageCorporateAgentHistoryLength = class _MessageCorporateAgentHistoryLength extends MessageBase {
53405  constructor(length = 0) {
53406    super(_MessageCorporateAgentHistoryLength);
53407    this.length = 0;
53408    this.length = length;
53409  }
53410};
53411
53412// src/app/DoraWidget/dora-corp-agent-user-input/dora-corp-agent-user-input.component.ts
53413var DoraCorpAgentUserInputComponent = class _DoraCorpAgentUserInputComponent extends WidgetBaseComponent {
53414  constructor(elementRef, messageService, configurationService, publisher, widgetService, http, translationService, cdr, recaptchaService) {
53415    super(elementRef, messageService, configurationService, publisher, widgetService, http, translationService);
53416    this.cdr = cdr;
53417    this.recaptchaService = recaptchaService;
53418    this.buttonText = _TRANSLATE("submit");
53419    this.placeholderText = _TRANSLATE("ask_something");
53420    this.loadingText = _TRANSLATE("loading");
53421    this.textAreaRowMax = 3;
53422    this.userInput = "";
53423    this.isLoading = false;
53424    this.isRecording = false;
53425    this.speechRecognition = null;
53426    this.manualStop = false;
53427    this.lastSpeechTimestamp = 0;
53428    this.SILENCE_TIMEOUT = 1e3;
53429    this.historyLength = 0;
53430    this.textAreaRow = 1;
53431    this._TRANSLATE = _TRANSLATE;
53432  }
53433  ngOnInit() {
53434    super.ngOnInit();
53435    this.initSpeechRecognition();
53436  }
53437  ngOnDestroy() {
53438    this.stopSpeechRecognition();
53439  }
53440  onParameterInjectedFinished() {
53441    super.onParameterInjectedFinished();
53442    this.buttonText = this.translationService.get(this.buttonText);
53443    this.placeholderText = this.translationService.get(this.placeholderText);
53444    this.loadingText = this.translationService.get(this.loadingText);
53445    this.messageService.getMessage(this.EventChannel, MessageCorporateAgentWizardInput, this.CallerName).subscribe((message) => {
53446      if (message && message.data) {
53447        const messageCorporateAgentWizardInput = message.data;
53448        this.userInput = messageCorporateAgentWizardInput.question;
53449        this.sendQuestion();
53450      }
53451    });
53452    this.messageService.getMessage(this.EventChannel, MessageCorporateAgentHistoryLength, this.CallerName).subscribe((message) => {
53453      if (message && message.data) {
53454        const messageCorporateAgentHistoryLength = message.data;
53455        this.historyLength = messageCorporateAgentHistoryLength.length;
53456      }
53457    });
53458  }
53459  // Inizializzazione del riconoscimento vocale
53460  initSpeechRecognition() {
53461    try {
53462      if (typeof window !== "undefined" && "webkitSpeechRecognition" in window) {
53463        this.speechRecognition = new webkitSpeechRecognition();
53464        if (this.speechRecognition) {
53465          this.speechRecognition.continuous = false;
53466          this.speechRecognition.interimResults = true;
53467          this.speechRecognition.lang = this.locale;
53468          this.speechRecognition.maxAlternatives = 1;
53469          this.speechRecognition.onstart = () => {
53470            this.isRecording = true;
53471            this.manualStop = false;
53472            this.lastSpeechTimestamp = Date.now();
53473            this.cdr.detectChanges();
53474          };
53475          this.speechRecognition.onresult = (event2) => {
53476            if (event2 && event2.results && event2.resultIndex >= 0 && event2.results[event2.resultIndex] && event2.results[event2.resultIndex][0]) {
53477              const transcript = event2.results[event2.resultIndex][0].transcript;
53478              this.userInput = transcript;
53479              this.lastSpeechTimestamp = Date.now();
53480              this.cdr.detectChanges();
53481            }
53482          };
53483          this.speechRecognition.onerror = (event2) => {
53484            console.error("Errore nel riconoscimento vocale:", event2);
53485            this.isRecording = false;
53486            this.cdr.detectChanges();
53487          };
53488          this.speechRecognition.onend = () => {
53489            const silenceTime = Date.now() - this.lastSpeechTimestamp;
53490            if (!this.manualStop && silenceTime < this.SILENCE_TIMEOUT) {
53491              try {
53492                this.speechRecognition?.start();
53493                return;
53494              } catch (error) {
53495                console.error("Errore nel riavvio del riconoscimento vocale:", error);
53496              }
53497            }
53498            this.isRecording = false;
53499            this.cdr.detectChanges();
53500          };
53501        }
53502      }
53503    } catch (error) {
53504      console.error("Errore durante l'inizializzazione del riconoscimento vocale:", error);
53505    }
53506  }
53507  // Attiva/disattiva il riconoscimento vocale
53508  toggleVoiceRecognition() {
53509    if (this.isLoading) {
53510      return;
53511    }
53512    if (!this.speechRecognition) {
53513      this.initSpeechRecognition();
53514      if (!this.speechRecognition) {
53515        console.error("Il riconoscimento vocale non \xE8 supportato da questo browser.");
53516        return;
53517      }
53518    }
53519    if (this.isRecording) {
53520      this.manualStop = true;
53521      this.stopSpeechRecognition();
53522    } else {
53523      this.startSpeechRecognition();
53524    }
53525  }
53526  // Avvia il riconoscimento vocale
53527  startSpeechRecognition() {
53528    if (this.speechRecognition && !this.isRecording) {
53529      try {
53530        this.speechRecognition.start();
53531      } catch (error) {
53532        console.error("Errore durante l'avvio del riconoscimento vocale:", error);
53533        this.isRecording = false;
53534      }
53535    }
53536  }
53537  // Ferma il riconoscimento vocale
53538  stopSpeechRecognition() {
53539    if (this.speechRecognition && this.isRecording) {
53540      try {
53541        this.speechRecognition.stop();
53542      } catch (error) {
53543        console.error("Errore durante l'arresto del riconoscimento vocale:", error);
53544        this.isRecording = false;
53545      }
53546    }
53547  }
53548  // Metodo per inviare la domanda
53549  sendQuestion() {
53550    return __async(this, null, function* () {
53551      if (!this.userInput || this.isLoading) {
53552        return;
53553      }
53554      if (this.isRecording) {
53555        this.manualStop = true;
53556        this.stopSpeechRecognition();
53557      }
53558      this.isLoading = true;
53559      const question = this.userInput;
53560      const conversationId = this.generateUUID();
53561      this.messageService.sendMessage(this.EventChannel, new MessageCorporateAgentUserInput(question, conversationId), this.CallerName);
53562      this.userInput = "";
53563      this.textAreaRow = 1;
53564      this.isLoading = false;
53565      this.messageService.sendMessage(this.EventChannel, new MessageCorporateAgentWizardVisible(false), this.CallerName);
53566      if (this.historyLength == 0) {
53567        if (typeof window !== "undefined" && typeof window.onDoraCorpAgentFirstQuery === "function") {
53568          try {
53569            window.onDoraCorpAgentFirstQuery();
53570          } catch (error) {
53571            console.error("Error calling onDoraCorpAgentFirstQuery:", error);
53572          }
53573        }
53574      }
53575    });
53576  }
53577  // Metodo per gestire il tasto Enter nell'input
53578  onKeyDown(event2) {
53579    if (event2.key === "Enter" && !event2.shiftKey) {
53580      event2.preventDefault();
53581      this.sendQuestion();
53582    }
53583  }
53584  onInputChange(event2) {
53585    const textarea = event2.target;
53586    const actualHeight = textarea.scrollHeight;
53587    let lineHeight = parseInt(getComputedStyle(textarea).lineHeight);
53588    if (isNaN(lineHeight)) {
53589      lineHeight = parseInt(getComputedStyle(textarea).fontSize);
53590    }
53591    const paddingTop = parseInt(getComputedStyle(textarea).paddingTop);
53592    const paddingBottom = parseInt(getComputedStyle(textarea).paddingBottom);
53593    const availableHeight = actualHeight - paddingTop - paddingBottom;
53594    const actualLines = Math.floor(availableHeight / lineHeight);
53595    if (actualLines < 1) {
53596      this.textAreaRow = 1;
53597    } else if (actualLines > this.textAreaRowMax) {
53598      this.textAreaRow = this.textAreaRowMax;
53599    } else {
53600      this.textAreaRow = actualLines;
53601    }
53602  }
53603  /**
53604   * Genera un UUID univoco per identificare la conversazione
53605   * Fornisce un'implementazione di fallback per i browser che non supportano crypto.randomUUID()
53606   */
53607  generateUUID() {
53608    if (typeof crypto !== "undefined" && typeof crypto.randomUUID === "function") {
53609      return crypto.randomUUID();
53610    }
53611    const getRandomHex = (c) => {
53612      const r = Math.random() * 16 | 0;
53613      const v = c === "x" ? r : r & 3 | 8;
53614      return v.toString(16);
53615    };
53616    return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, getRandomHex);
53617  }
53618  static {
53619    this.\u0275fac = function DoraCorpAgentUserInputComponent_Factory(__ngFactoryType__) {
53620      return new (__ngFactoryType__ || _DoraCorpAgentUserInputComponent)(\u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(MessageService), \u0275\u0275directiveInject(ConfigurationService), \u0275\u0275directiveInject(PublisherService), \u0275\u0275directiveInject(WidgetService), \u0275\u0275directiveInject(HttpClient), \u0275\u0275directiveInject(TranslationService), \u0275\u0275directiveInject(ChangeDetectorRef), \u0275\u0275directiveInject(ScScoreReCaptcha));
53621    };
53622  }
53623  static {
53624    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraCorpAgentUserInputComponent, selectors: [["dora-corp-agent-user-input"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 8, vars: 20, consts: [["role", "region", 1, "corp-agent-container"], [1, "input-container"], [1, "visually-hidden", 3, "for"], [1, "question-input", 3, "ngModelChange", "keydown", "input", "id", "ngModel", "placeholder", "disabled", "rows"], ["type", "button", 1, "voice-indicator", 3, "click", "disabled"], [1, "send-button", 3, "click", "disabled"]], template: function DoraCorpAgentUserInputComponent_Template(rf, ctx) {
53625      if (rf & 1) {
53626        \u0275\u0275elementStart(0, "div", 0)(1, "div", 1)(2, "label", 2);
53627        \u0275\u0275text(3);
53628        \u0275\u0275elementEnd();
53629        \u0275\u0275elementStart(4, "textarea", 3);
53630        \u0275\u0275twoWayListener("ngModelChange", function DoraCorpAgentUserInputComponent_Template_textarea_ngModelChange_4_listener($event) {
53631          \u0275\u0275twoWayBindingSet(ctx.userInput, $event) || (ctx.userInput = $event);
53632          return $event;
53633        });
53634        \u0275\u0275listener("keydown", function DoraCorpAgentUserInputComponent_Template_textarea_keydown_4_listener($event) {
53635          return ctx.onKeyDown($event);
53636        })("input", function DoraCorpAgentUserInputComponent_Template_textarea_input_4_listener($event) {
53637          return ctx.onInputChange($event);
53638        });
53639        \u0275\u0275elementEnd();
53640        \u0275\u0275elementStart(5, "button", 4);
53641        \u0275\u0275listener("click", function DoraCorpAgentUserInputComponent_Template_button_click_5_listener() {
53642          return ctx.toggleVoiceRecognition();
53643        });
53644        \u0275\u0275elementEnd();
53645        \u0275\u0275elementStart(6, "button", 5);
53646        \u0275\u0275listener("click", function DoraCorpAgentUserInputComponent_Template_button_click_6_listener() {
53647          return ctx.sendQuestion();
53648        });
53649        \u0275\u0275text(7);
53650        \u0275\u0275elementEnd()()();
53651      }
53652      if (rf & 2) {
53653        \u0275\u0275attribute("aria-label", ctx.translationService.get("
53653corp_agent_container_aria_label"));
53654        \u0275\u0275advance(2);
53655        \u0275\u0275propertyInterpolate("for", ctx.buildUniqueElementId("question-input"));
53656        \u0275\u0275advance();
53657        \u0275\u0275textInterpolate(ctx.translationService.get("label_query_input"));
53658        \u0275\u0275advance();
53659        \u0275\u0275propertyInterpolate("id", ctx.buildUniqueElementId("question-input"));
53660        \u0275\u0275twoWayProperty("ngModel", ctx.userInput);
53661        \u0275\u0275property("placeholder", ctx.placeholderText)("disabled", ctx.isLoading)("rows", ctx.textAreaRow);
53662        \u0275\u0275attribute("name", ctx.translationService.get("query_input_name"));
53663        \u0275\u0275advance();
53664        \u0275\u0275classProp("recording", ctx.isRecording)("disabled", ctx.isLoading);
53665        \u0275\u0275property("disabled", ctx.isLoading);
53666        \u0275\u0275attribute("name", ctx.translationService.get("voice_input_name"))("aria-label", ctx.translationService.get("voice_Input_Label"));
53667        \u0275\u0275advance();
53668        \u0275\u0275property("disabled", ctx.isLoading || !ctx.userInput);
53669        \u0275\u0275attribute("name", ctx.translationService.get("submit_input_name"))("aria-label", ctx.translationService.get("submit_Input_Label"));
53670        \u0275\u0275advance();
53671        \u0275\u0275textInterpolate1(" ", ctx.buttonText, " ");
53672      }
53673    }, dependencies: [DefaultValueAccessor, NgControlStatus, NgModel], styles: ["\n\n.corp-agent-container[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  width: 100%;\n  padding: 10px;\n  font-family: Arial, sans-serif;\n  box-sizing: border-box;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .input-container[_ngcontent-%COMP%] {\n  display: flex;\n  margin-bottom: 10px;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .input-container[_ngcontent-%COMP%]   .question-input[_ngcontent-%COMP%] {\n  flex: 1;\n  padding: 10px;\n  border: 1px solid #ccc;\n  border-radius: 4px;\n  margin-right: 5px;\n  font-size: 14px;\n  line-height: 1;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .input-container[_ngcontent-%COMP%]   .voice-indicator[_ngcontent-%COMP%] {\n  width: 15px;\n  height: 15px;\n  background-color: #6c757d;\n  border-radius: 50%;\n  margin-right: 10px;\n  cursor: pointer;\n  align-self: center;\n  transition: background-color 0.3s ease;\n  border: none;\n  padding: 0;\n  display: inline-block;\n  outline: none;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .input-container[_ngcontent-%COMP%]   .voice-indicator[_ngcontent-%COMP%]:hover {\n  background-color: #5a6268;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .input-container[_ngcontent-%COMP%]   .voice-indicator.re
53673cording[_ngcontent-%COMP%] {\n  background-color: #dc3545;\n  animation: _ngcontent-%COMP%_pulse 1.5s infinite;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .input-container[_ngcontent-%COMP%]   .voice-indicator.disabled[_ngcontent-%COMP%] {\n  background-color: #cccccc;\n  cursor: not-allowed;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .input-container[_ngcontent-%COMP%]   .voice-indicator[_ngcontent-%COMP%]:focus-visible {\n  box-shadow: 0 0 0 2px #007bff;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .input-container[_ngcontent-%COMP%]   .send-button[_ngcontent-%COMP%] {\n  padding: 10px 15px;\n  background-color: #007bff;\n  color: white;\n  border: none;\n  border-radius: 4px;\n  cursor: pointer;\n  font-weight: bold;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .input-container[_ngcontent-%COMP%]   .send-button[_ngcontent-%COMP%]:hover {\n  background-color: #0069d9;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .input-container[_ngcontent-%COMP%]   .send-button[_ngcontent-%COMP%]:disabled {\n  background-color: #cccccc;\n  cursor: not-allowed;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .input-container[_ngcontent-%COMP%]   .send-button[_ngcontent-%COMP%]:focus-visible {\n  box-shadow: 0 0 0 2px #007bff;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .response-container[_ngcontent-%COMP%] {\n  margin-top: 15px;\n  border-top: 1px solid #eee;\n  padding-top: 15px;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .loading-indicator[_ngcontent-%COMP%] {\n  display: flex;\n  align-items: center;\n  color: #666;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .spinner[_ngcontent-%COMP%] {\n  width: 20px;\n  height: 20px;\n  border: 2px solid rgba(0, 123, 255, 0.3);\n  border-radius: 50%;\n  border-top-color: #007bff;\n  animation: _ngcontent-%COMP%_spin 1s ease-in-out infinite;\n  margin-left: 10px;\n}\n.corp-agent-container[_ngcontent-%COMP%]   .response-text[_ngcontent-%COMP%] {\n  background-color: #f9f9f9;\n  border-radius: 4px;\n  padding: 15px;\n  margin-top: 10px;\n  line-height: 1.5;\n}\n@keyframes _ngcontent-%COMP%_pulse {\n  0% {\n    opacity: 1;\n  }\n  50% {\n    opacity: 0.7;\n  }\n  100% {\n    opacity: 1;\n  }\n}\n@keyframes _ngcontent-%COMP%_spin {\n  to {\n    transform: rotate(360deg);\n  }\n}"] });
53674  }
53675};
53676__decorate([
53677  DoraPropertyDOC("Testo del pulsante di invio", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, false),
53678  DoraProperty,
53679  __metadata("design:type", String)
53680], DoraCorpAgentUserInputComponent.prototype, "buttonText", void 0);
53681__decorate([
53682  DoraPropertyDOC("Placeholder dell'input", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, false),
53683  DoraProperty,
53684  __metadata("design:type", String)
53685], DoraCorpAgentUserInputComponent.prototype, "placeholderText", void 0);
53686__decorate([
53687  DoraPropertyDOC("Messaggio di caricamento", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, false),
53688  DoraProperty,
53689  __metadata("design:type", String)
53690], DoraCorpAgentUserInputComponent.prototype, "loadingText", void 0);
53691__decorate([
53692  DoraPropertyDOC("Numero massimo di righe nella text area", ATTRIBUTE_TYPE.INTEGER, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
53693  DoraProperty,
53694  __metadata("design:type", Number)
53695], DoraCorpAgentUserInputComponent.prototype, "textAreaRowMax", void 0);
53696(() => {
53697  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraCorpAgentUserInputComponent, { className: "DoraCorpAgentUserInputComponent", filePath: "src/app/dorawidget/dora-corp-agent-user-input/dora-corp-agent-user-input.component.ts", lineNumber: 67 });
53698})();
53699
53700// src/app/DoraWidget/dora-corp-agent-user-history/data/conversation-entry.ts
53701var ConversationEntryType;
53702(function(ConversationEntryType2) {
53703  ConversationEntryType2["Question"] = "question";
53704  ConversationEntryType2["Answer"] = "answer";
53705})(ConversationEntryType || (ConversationEntryType = {}));
53706
53707// src/app/messages/message-url-content.ts
53708var MessageUrlContent = class _MessageUrlContent extends MessageBase {
53709  /**
53710   * Costruttore
53711   * @param url URL da visualizzare
53712   * @param title Titolo opzionale per il contenuto
53713   * @param contentType Tipo MIME del contenuto (es. 'application/pdf', 'image/jpeg')
53714   * @param documentName Nome del documento
53715   * @param documentType Tipo del documento
53716   */
53717  constructor(url, title, contentType, documentName, documentType) {
53718    super(_MessageUrlContent);
53719    this.url = url;
53720    this.title = title;
53721    this.contentType = contentType;
53722    this.documentName = documentName;
53723    this.documentType = documentType;
53724  }
53725};
53726
53727// src/app/messages/message-corporate-agent-history-clear.ts
53728var MessageCorporateAgentHistoryClear = class _MessageCorporateAgentHistoryClear extends MessageBase {
53729  constructor() {
53730    super(_MessageCorporateAgentHistoryClear);
53731  }
53732};
53733
vendor: 493,444 bytes, lines 53734-68146
53734// node_modules/katex/dist/katex.mjs
53735var SourceLocation = class _SourceLocation {
53736  // The + prefix indicates that these fields aren't writeable
53737  // Lexer holding the input string.
53738  // Start offset, zero-based inclusive.
53739  // End offset, zero-based exclusive.
53740  constructor(lexer2, start, end) {
53741    this.lexer = void 0;
53742    this.start = void 0;
53743    this.end = void 0;
53744    this.lexer = lexer2;
53745    this.start = start;
53746    this.end = end;
53747  }
53748  /**
53749   * Merges two `SourceLocation`s from location providers, given they are
53750   * provided in order of appearance.
53751   * - Returns the first one's location if only the first is provided.
53752   * - Returns a merged range of the first and the last if both are provided
53753   *   and their lexers match.
53754   * - Otherwise, returns null.
53755   */
53756  static range(first, second) {
53757    if (!second) {
53758      return first && first.loc;
53759    } else if (!first || !first.loc || !second.loc || first.loc.lexer !== second.loc.lexer) {
53760      return null;
53761    } else {
53762      return new _SourceLocation(first.loc.lexer, first.loc.start, second.loc.end);
53763    }
53764  }
53765};
53766var Token = class _Token {
53767  // don't expand the token
53768  // used in \noexpand
53769  constructor(text2, loc) {
53770    this.text = void 0;
53771    this.loc = void 0;
53772    this.noexpand = void 0;
53773    this.treatAsRelax = void 0;
53774    this.text = text2;
53775    this.loc = loc;
53776  }
53777  /**
53778   * Given a pair of tokens (this and endToken), compute a `Token` encompassing
53779   * the whole input range enclosed by these two.
53780   */
53781  range(endToken, text2) {
53782    return new _Token(text2, SourceLocation.range(this, endToken));
53783  }
53784};
53785var ParseError = class _ParseError {
53786  // Error start position based on passed-in Token or ParseNode.
53787  // Length of affected text based on passed-in Token or ParseNode.
53788  // The underlying error message without any context added.
53789  constructor(message, token) {
53790    this.name = void 0;
53791    this.position = void 0;
53792    this.length = void 0;
53793    this.rawMessage = void 0;
53794    var error = "KaTeX parse error: " + message;
53795    var start;
53796    var end;
53797    var loc = token && token.loc;
53798    if (loc && loc.start <= loc.end) {
53799      var input2 = loc.lexer.input;
53800      start = loc.start;
53801      end = loc.end;
53802      if (start === input2.length) {
53803        error += " at end of input: ";
53804      } else {
53805        error += " at position " + (start + 1) + ": ";
53806      }
53807      var underlined = input2.slice(start, end).replace(/[^]/g, "$&\u0332");
53808      var left;
53809      if (start > 15) {
53810        left = "\u2026" + input2.slice(start - 15, start);
53811      } else {
53812        left = input2.slice(0, start);
53813      }
53814      var right;
53815      if (end + 15 < input2.length) {
53816        right = input2.slice(end, end + 15) + "\u2026";
53817      } else {
53818        right = input2.slice(end);
53819      }
53820      error += left + underlined + right;
53821    }
53822    var self2 = new Error(error);
53823    self2.name = "ParseError";
53824    self2.__proto__ = _ParseError.prototype;
53825    self2.position = start;
53826    if (start != null && end != null) {
53827      self2.length = end - start;
53828    }
53829    self2.rawMessage = message;
53830    return self2;
53831  }
53832};
53833ParseError.prototype.__proto__ = Error.prototype;
53834var contains = function contains2(list2, elem) {
53835  return list2.indexOf(elem) !== -1;
53836};
53837var deflt = function deflt2(setting, defaultIfUndefined) {
53838  return setting === void 0 ? defaultIfUndefined : setting;
53839};
53840var uppercase = /([A-Z])/g;
53841var hyphenate = function hyphenate2(str) {
53842  return str.replace(uppercase, "-$1").toLowerCase();
53843};
53844var ESCAPE_LOOKUP = {
53845  "&": "&amp;",
53846  ">": "&gt;",
53847  "<": "&lt;",
53848  '"': "&quot;",
53849  "'": "&#x27;"
53850};
53851var ESCAPE_REGEX = /[&><"']/g;
53852function escape(text2) {
53853  return String(text2).replace(ESCAPE_REGEX, (match) => ESCAPE_LOOKUP[match]);
53854}
53855var getBaseElem = function getBaseElem2(group) {
53856  if (group.type === "ordgroup") {
53857    if (group.body.length === 1) {
53858      return getBaseElem2(group.body[0]);
53859    } else {
53860      return group;
53861    }
53862  } else if (group.type === "color") {
53863    if (group.body.length === 1) {
53864      return getBaseElem2(group.body[0]);
53865    } else {
53866      return group;
53867    }
53868  } else if (group.type === "font") {
53869    return getBaseElem2(group.body);
53870  } else {
53871    return group;
53872  }
53873};
53874var isCharacterBox = function isCharacterBox2(group) {
53875  var baseElem = getBaseElem(group);
53876  return baseElem.type === "mathord" || baseElem.type === "textord" || baseElem.type === "atom";
53877};
53878var assert = function assert2(value) {
53879  if (!value) {
53880    throw new Error("Expected non-null, but got " + String(value));
53881  }
53882  return value;
53883};
53884var protocolFromUrl = function protocolFromUrl2(url) {
53885  var protocol = /^[\x00-\x20]*([^\\/#?]*?)(:|&#0*58|&#x0*3a|&colon)/i.exec(url);
53886  if (!protocol) {
53887    return "_relative";
53888  }
53889  if (protocol[2] !== ":") {
53890    return null;
53891  }
53892  if (!/^[a-zA-Z][a-zA-Z0-9+\-.]*$/.test(protocol[1])) {
53893    return null;
53894  }
53895  return protocol[1].toLowerCase();
53896};
53897var utils = {
53898  contains,
53899  deflt,
53900  escape,
53901  hyphenate,
53902  getBaseElem,
53903  isCharacterBox,
53904  protocolFromUrl
53905};
53906var SETTINGS_SCHEMA = {
53907  displayMode: {
53908    type: "boolean",
53909    description: "Render math in display mode, which puts the math in display style (so \\int and \\sum are large, for example), and centers the math on the page on its own line.",
53910    cli: "-d, --display-mode"
53911  },
53912  output: {
53913    type: {
53914      enum: ["htmlAndMathml", "html", "mathml"]
53915    },
53916    description: "Determines the markup language of the output.",
53917    cli: "-F, --format <type>"
53918  },
53919  leqno: {
53920    type: "boolean",
53921    description: "Render display math in leqno style (left-justified tags)."
53922  },
53923  fleqn: {
53924    type: "boolean",
53925    description: "Render display math flush left."
53926  },
53927  throwOnError: {
53928    type: "boolean",
53929    default: true,
53930    cli: "-t, --no-throw-on-error",
53931    cliDescription: "Render errors (in the color given by --error-color) instead of throwing a ParseError exception when encountering an error."
53932  },
53933  errorColor: {
53934    type: "string",
53935    default: "#cc0000",
53936    cli: "-c, --error-color <color>",
53937    cliDescription: "A color string given in the format 'rgb' or 'rrggbb' (no #). This option determines the color of errors rendered by the -t option.",
53938    cliProcessor: (color) => "#" + color
53939  },
53940  macros: {
53941    type: "object",
53942    cli: "-m, --macro <def>",
53943    cliDescription: "Define custom macro of the form '\\foo:expansion' (use multiple -m arguments for multiple macros).",
53944    cliDefault: [],
53945    cliProcessor: (def2, defs) => {
53946      defs.push(def2);
53947      return defs;
53948    }
53949  },
53950  minRuleThickness: {
53951    type: "number",
53952    description: "Specifies a minimum thickness, in ems, for fraction lines, `\\sqrt` top lines, `{array}` vertical lines, `\\hline`, `\\hdashline`, `\\underline`, `\\overline`, and the borders of `\\fbox`, `\\boxed`, and `\\fcolorbox`.",
53953    processor: (t) => Math.max(0, t),
53954    cli: "--min-rule-thickness <size>",
53955    cliProcessor: parseFloat
53956  },
53957  colorIsTextColor: {
53958    type: "boolean",
53959    description: "Makes \\color behave like LaTeX's 2-argument \\textcolor, instead of LaTeX's one-argument \\color mode change.",
53960    cli: "-b, --color-is-text-color"
53961  },
53962  strict: {
53963    type: [{
53964      enum: ["warn", "ignore", "error"]
53965    }, "boolean", "function"],
53966    description: "Turn on strict / LaTeX faithfulness mode, which throws an error if the input uses features that are not supported by LaTeX.",
53967    cli: "-S, --strict",
53968    cliDefault: false
53969  },
53970  trust: {
53971    type: ["boolean", "function"],
53972    description: "Trust the input, enabling all HTML features such as \\url.",
53973    cli: "-T, --trust"
53974  },
53975  maxSize: {
53976    type: "number",
53977    default: Infinity,
53978    description: "If non-zero, all user-specified sizes, e.g. in \\rule{500em}{500em}, will be capped to maxSize ems. Otherwise, elements and spaces can be arbitrarily large",
53979    processor: (s) => Math.max(0, s),
53980    cli: "-s, --max-size <n>",
53981    cliProcessor: parseInt
53982  },
53983  maxExpand: {
53984    type: "number",
53985    default: 1e3,
53986    description: "Limit the number of macro expansions to the specified number, to prevent e.g. infinite macro loops. If set to Infinity, the macro expander will try to fully expand as in LaTeX.",
53987    processor: (n) => Math.max(0, n),
53988    cli: "-e, --max-expand <n>",
53989    cliProcessor: (n) => n === "Infinity" ? Infinity : parseInt(n)
53990  },
53991  globalGroup: {
53992    type: "boolean",
53993    cli: false
53994  }
53995};
53996function getDefaultValue(schema) {
53997  if (schema.default) {
53998    return schema.default;
53999  }
54000  var type = schema.type;
54001  var defaultType = Array.isArray(type) ? type[0] : type;
54002  if (typeof defaultType !== "string") {
54003    return defaultType.enum[0];
54004  }
54005  switch (defaultType) {
54006    case "boolean":
54007      return false;
54008    case "string":
54009      return "";
54010    case "number":
54011      return 0;
54012    case "object":
54013      return {};
54014  }
54015}
54016var Settings = class {
54017  constructor(options2) {
54018    this.displayMode = void 0;
54019    this.output = void 0;
54020    this.leqno = void 0;
54021    this.fleqn = void 0;
54022    this.throwOnError = void 0;
54023    this.errorColor = void 0;
54024    this.macros = void 0;
54025    this.minRuleThickness = void 0;
54026    this.colorIsTextColor = void 0;
54027    this.strict = void 0;
54028    this.trust = void 0;
54029    this.maxSize = void 0;
54030    this.maxExpand = void 0;
54031    this.globalGroup = void 0;
54032    options2 = options2 || {};
54033    for (var prop in SETTINGS_SCHEMA) {
54034      if (SETTINGS_SCHEMA.hasOwnProperty(prop)) {
54035        var schema = SETTINGS_SCHEMA[prop];
54036        this[prop] = options2[prop] !== void 0 ? schema.processor ? schema.processor(options2[prop]) : options2[prop] : getDefaultValue(schema);
54037      }
54038    }
54039  }
54040  /**
54041   * Report nonstrict (non-LaTeX-compatible) input.
54042   * Can safely not be called if `this.strict` is false in JavaScript.
54043   */
54044  reportNonstrict(errorCode, errorMsg, token) {
54045    var strict = this.strict;
54046    if (typeof strict === "function") {
54047      strict = strict(errorCode, errorMsg, token);
54048    }
54049    if (!strict || strict === "ignore") {
54050      return;
54051    } else if (strict === true || strict === "error") {
54052      throw new ParseError("LaTeX-incompatible input and strict mode is set to 'error': " + (errorMsg + " [" + errorCode + "]"), token);
54053    } else if (strict === "warn") {
54054      typeof console !== "undefined" && console.warn("LaTeX-incompatible input and strict mode is set to 'warn': " + (errorMsg + " [" + errorCode + "]"));
54055    } else {
54056      typeof console !== "undefined" && console.warn("LaTeX-incompatible input and strict mode is set to " + ("unrecognized '" + strict + "': " + errorMsg + " [" + errorCode + "]"));
54057    }
54058  }
54059  /**
54060   * Check whether to apply strict (LaTeX-adhering) behavior for unusual
54061   * input (like `\\`).  Unlike `nonstrict`, will not throw an error;
54062   * instead, "error" translates to a return value of `true`, while "ignore"
54063   * translates to a return value of `false`.  May still print a warning:
54064   * "warn" prints a warning and returns `false`.
54065   * This is for the second category of `errorCode`s listed in the README.
54066   */
54067  useStrictBehavior(errorCode, errorMsg, token) {
54068    var strict = this.strict;
54069    if (typeof strict === "function") {
54070      try {
54071        strict = strict(errorCode, errorMsg, token);
54072      } catch (error) {
54073        strict = "error";
54074      }
54075    }
54076    if (!strict || strict === "ignore") {
54077      return false;
54078    } else if (strict === true || strict === "error") {
54079      return true;
54080    } else if (strict === "warn") {
54081      typeof console !== "undefined" && console.warn("LaTeX-incompatible input and strict mode is set to 'warn': " + (errorMsg + " [" + errorCode + "]"));
54082      return false;
54083    } else {
54084      typeof console !== "undefined" && console.warn("LaTeX-incompatible input and strict mode is set to " + ("unrecognized '" + strict + "': " + errorMsg + " [" + errorCode + "]"));
54085      return false;
54086    }
54087  }
54088  /**
54089   * Check whether to test potentially dangerous input, and return
54090   * `true` (trusted) or `false` (untrusted).  The sole argument `context`
54091   * should be an object with `command` field specifying the relevant LaTeX
54092   * command (as a string starting with `\`), and any other arguments, etc.
54093   * If `context` has a `url` field, a `protocol` field will automatically
54094   * get added by this function (changing the specified object).
54095   */
54096  isTrusted(context) {
54097    if (context.url && !context.protocol) {
54098      var protocol = utils.protocolFromUrl(context.url);
54099      if (protocol == null) {
54100        return false;
54101      }
54102      context.protocol = protocol;
54103    }
54104    var trust = typeof this.trust === "function" ? this.trust(context) : this.trust;
54105    return Boolean(trust);
54106  }
54107};
54108var Style = class {
54109  constructor(id, size, cramped) {
54110    this.id = void 0;
54111    this.size = void 0;
54112    this.cramped = void 0;
54113    this.id = id;
54114    this.size = size;
54115    this.cramped = cramped;
54116  }
54117  /**
54118   * Get the style of a superscript given a base in the current style.
54119   */
54120  sup() {
54121    return styles[sup[this.id]];
54122  }
54123  /**
54124   * Get the style of a subscript given a base in the current style.
54125   */
54126  sub() {
54127    return styles[sub[this.id]];
54128  }
54129  /**
54130   * Get the style of a fraction numerator given the fraction in the current
54131   * style.
54132   */
54133  fracNum() {
54134    return styles[fracNum[this.id]];
54135  }
54136  /**
54137   * Get the style of a fraction denominator given the fraction in the current
54138   * style.
54139   */
54140  fracDen() {
54141    return styles[fracDen[this.id]];
54142  }
54143  /**
54144   * Get the cramped version of a style (in particular, cramping a cramped style
54145   * doesn't change the style).
54146   */
54147  cramp() {
54148    return styles[cramp[this.id]];
54149  }
54150  /**
54151   * Get a text or display version of this style.
54152   */
54153  text() {
54154    return styles[text$1[this.id]];
54155  }
54156  /**
54157   * Return true if this style is tightly spaced (scriptstyle/scriptscriptstyle)
54158   */
54159  isTight() {
54160    return this.size >= 2;
54161  }
54162};
54163var D = 0;
54164var Dc = 1;
54165var T = 2;
54166var Tc = 3;
54167var S = 4;
54168var Sc = 5;
54169var SS = 6;
54170var SSc = 7;
54171var styles = [new Style(D, 0, false), new Style(Dc, 0, true), new Style(T, 1, false), new Style(Tc, 1, true), new Style(S, 2, false), new Style(Sc, 2, true), new Style(SS, 3, false), new Style(SSc, 3, true)];
54172var sup = [S, Sc, S, Sc, SS, SSc, SS, SSc];
54173var sub = [Sc, Sc, Sc, Sc, SSc, SSc, SSc, SSc];
54174var fracNum = [T, Tc, S, Sc, SS, SSc, SS, SSc];
54175var fracDen = [Tc, Tc, Sc, Sc, SSc, SSc, SSc, SSc];
54176var cramp = [Dc, Dc, Tc, Tc, Sc, Sc, SSc, SSc];
54177var text$1 = [D, Dc, T, Tc, T, Tc, T, Tc];
54178var Style$1 = {
54179  DISPLAY: styles[D],
54180  TEXT: styles[T],
54181  SCRIPT: styles[S],
54182  SCRIPTSCRIPT: styles[SS]
54183};
54184var scriptData = [{
54185  // Latin characters beyond the Latin-1 characters we have metrics for.
54186  // Needed for Czech, Hungarian and Turkish text, for example.
54187  name: "latin",
54188  blocks: [
54189    [256, 591],
54190    // Latin Extended-A and Latin Extended-B
54191    [768, 879]
54192    // Combining Diacritical marks
54193  ]
54194}, {
54195  // The Cyrillic script used by Russian and related languages.
54196  // A Cyrillic subset used to be supported as explicitly defined
54197  // symbols in symbols.js
54198  name: "cyrillic",
54199  blocks: [[1024, 1279]]
54200}, {
54201  // Armenian
54202  name: "armenian",
54203  blocks: [[1328, 1423]]
54204}, {
54205  // The Brahmic scripts of South and Southeast Asia
54206  // Devanagari (0900–097F)
54207  // Bengali (0980–09FF)
54208  // Gurmukhi (0A00–0A7F)
54209  // Gujarati (0A80–0AFF)
54210  // Oriya (0B00–0B7F)
54211  // Tamil (0B80–0BFF)
54212  // Telugu (0C00–0C7F)
54213  // Kannada (0C80–0CFF)
54214  // Malayalam (0D00–0D7F)
54215  // Sinhala (0D80–0DFF)
54216  // Thai (0E00–0E7F)
54217  // Lao (0E80–0EFF)
54218  // Tibetan (0F00–0FFF)
54219  // Myanmar (1000–109F)
54220  name: "brahmic",
54221  blocks: [[2304, 4255]]
54222}, {
54223  name: "georgian",
54224  blocks: [[4256, 4351]]
54225}, {
54226  // Chinese and Japanese.
54227  // The "k" in cjk is for Korean, but we've separated Korean out
54228  name: "cjk",
54229  blocks: [
54230    [12288, 12543],
54231    // CJK symbols and punctuation, Hiragana, Katakana
54232    [19968, 40879],
54233    // CJK ideograms
54234    [65280, 65376]
54235    // Fullwidth punctuation
54236    // TODO: add halfwidth Katakana and Romanji glyphs
54237  ]
54238}, {
54239  // Korean
54240  name: "hangul",
54241  blocks: [[44032, 55215]]
54242}];
54243function scriptFromCodepoint(codepoint) {
54244  for (var i = 0; i < scriptData.length; i++) {
54245    var script = scriptData[i];
54246    for (var _i = 0; _i < script.blocks.length; _i++) {
54247      var block2 = script.blocks[_i];
54248      if (codepoint >= block2[0] && codepoint <= block2[1]) {
54249        return script.name;
54250      }
54251    }
54252  }
54253  return null;
54254}
54255var allBlocks = [];
54256scriptData.forEach((s) => s.blocks.forEach((b) => allBlocks.push(...b)));
54257function supportedCodepoint(codepoint) {
54258  for (var i = 0; i < allBlocks.length; i += 2) {
54259    if (codepoint >= allBlocks[i] && codepoint <= allBlocks[i + 1]) {
54260      return true;
54261    }
54262  }
54263  return false;
54264}
54265var hLinePad = 80;
54266var sqrtMain = function sqrtMain2(extraVinculum, hLinePad2) {
54267  return "M95," + (622 + extraVinculum + hLinePad2) + "\nc-2.7,0,-7.17,-2.7,-13.5,-8c-5.8,-5.3,-9.5,-10,-9.5,-14\nc0,-2,0.3,-3.3,1,-4c1.3,-2.7,23.83,-20.7,67.5,-54\nc44.2,-33.3,65.8,-50.3,66.5,-51c1.3,-1.3,3,-2,5,-2c4.7,0,8.7,3.3,12,10\ns173,378,173,378c0.7,0,35.3,-71,104,-213c68.7,-142,137.5,-285,206.5,-429\nc69,-144,104.5,-217.7,106.5,-221\nl" + extraVinculum / 2.075 + " -" + extraVinculum + "\nc5.3,-9.3,12,-14,20,-14\nH400000v" + (40 + extraVinculum) + "H845.2724\ns-225.272,467,-225.272,467s-235,486,-235,486c-2.7,4.7,-9,7,-19,7\nc-6,0,-10,-1,-12,-3s-194,-422,-194,-422s-65,47,-65,47z\nM" + (834 + extraVinculum) + " " + hLinePad2 + "h400000v" + (40 + extraVinculum) + "h-400000z";
54268};
54269var sqrtSize1 = function sqrtSize12(extraVinculum, hLinePad2) {
54270  return "M263," + (601 + extraVinculum + hLinePad2) + "c0.7,0,18,39.7,52,119\nc34,79.3,68.167,158.7,102.5,238c34.3,79.3,51.8,119.3,52.5,120\nc340,-704.7,510.7,-1060.3,512,-1067\nl" + extraVinculum / 2.084 + " -" + extraVinculum + "\nc4.7,-7.3,11,-11,19,-11\nH40000v" + (40 + extraVinculum) + "H1012.3\ns-271.3,567,-271.3,567c-38.7,80.7,-84,175,-136,283c-52,108,-89.167,185.3,-111.5,232\nc-22.3,46.7,-33.8,70.3,-34.5,71c-4.7,4.7,-12.3,7,-23,7s-12,-1,-12,-1\ns-109,-253,-109,-253c-72.7,-168,-109.3,-252,-110,-252c-10.7,8,-22,16.7,-34,26\nc-22,17.3,-33.3,26,-34,26s-26,-26,-26,-26s76,-59,76,-59s76,-60,76,-60z\nM" + (1001 + extraVinculum) + " " + hLinePad2 + "h400000v" + (40 + extraVinculum) + "h-400000z";
54271};
54272var sqrtSize2 = function sqrtSize22(extraVinculum, hLinePad2) {
54273  return "M983 " + (10 + extraVinculum + hLinePad2) + "\nl" + extraVinculum / 3.13 + " -" + extraVinculum + "\nc4,-6.7,10,-10,18,-10 H400000v" + (40 + extraVinculum) + "\nH1013.1s-83.4,268,-264.1,840c-180.7,572,-277,876.3,-289,913c-4.7,4.7,-12.7,7,-24,7\ns-12,0,-12,0c-1.3,-3.3,-3.7,-11.7,-7,-25c-35.3,-125.3,-106.7,-373.3,-214,-744\nc-10,12,-21,25,-33,39s-32,39,-32,39c-6,-5.3,-15,-14,-27,-26s25,-30,25,-30\nc26.7,-32.7,52,-63,76,-91s52,-60,52,-60s208,722,208,722\nc56,-175.3,126.3,-397.3,211,-666c84.7,-268.7,153.8,-488.2,207.5,-658.5\nc53.7,-170.3,84.5,-266.8,92.5,-289.5z\nM" + (1001 + extraVinculum) + " " + hLinePad2 + "h400000v" + (40 + extraVinculum) + "h-400000z";
54274};
54275var sqrtSize3 = function sqrtSize32(extraVinculum, hLinePad2) {
54276  return "M424," + (2398 + extraVinculum + hLinePad2) + "\nc-1.3,-0.7,-38.5,-172,-111.5,-514c-73,-342,-109.8,-513.3,-110.5,-514\nc0,-2,-10.7,14.3,-32,49c-4.7,7.3,-9.8,15.7,-15.5,25c-5.7,9.3,-9.8,16,-12.5,20\ns-5,7,-5,7c-4,-3.3,-8.3,-7.7,-13,-13s-13,-13,-13,-13s76,-122,76,-122s77,-121,77,-121\ns209,968,209,968c0,-2,84.7,-361.7,254,-1079c169.3,-717.3,254.7,-1077.7,256,-1081\nl" + extraVinculum / 4.223 + " -" + extraVinculum + "c4,-6.7,10,-10,18,-10 H400000\nv" + (40 + extraVinculum) + "H1014.6\ns-87.3,378.7,-272.6,1166c-185.3,787.3,-279.3,1182.3,-282,1185\nc-2,6,-10,9,-24,9\nc-8,0,-12,-0.7,-12,-2z M" + (1001 + extraVinculum) + " " + hLinePad2 + "\nh400000v" + (40 + extraVinculum) + "h-400000z";
54277};
54278var sqrtSize4 = function sqrtSize42(extraVinculum, hLinePad2) {
54279  return "M473," + (2713 + extraVinculum + hLinePad2) + "\nc339.3,-1799.3,509.3,-2700,510,-2702 l" + extraVinculum / 5.298 + " -" + extraVinculum + "\nc3.3,-7.3,9.3,-11,18,-11 H400000v" + (40 + extraVinculum) + "H1017.7\ns-90.5,478,-276.2,1466c-185.7,988,-279.5,1483,-281.5,1485c-2,6,-10,9,-24,9\nc-8,0,-12,-0.7,-12,-2c0,-1.3,-5.3,-32,-16,-92c-50.7,-293.3,-119.7,-693.3,-207,-1200\nc0,-1.3,-5.3,8.7,-16,30c-10.7,21.3,-21.3,42.7,-32,64s-16,33,-16,33s-26,-26,-26,-26\ns76,-153,76,-153s77,-151,77,-151c0.7,0.7,35.7,202,105,604c67.3,400.7,102,602.7,104,\n606zM" + (1001 + extraVinculum) + " " + hLinePad2 + "h400000v" + (40 + extraVinculum) + "H1017.7z";
54280};
54281var phasePath = function phasePath2(y) {
54282  var x = y / 2;
54283  return "M400000 " + y + " H0 L" + x + " 0 l65 45 L145 " + (y - 80) + " H400000z";
54284};
54285var sqrtTall = function sqrtTall2(extraVinculum, hLinePad2, viewBoxHeight) {
54286  var vertSegment = viewBoxHeight - 54 - hLinePad2 - extraVinculum;
54287  return "M702 " + (extraVinculum + hLinePad2) + "H400000" + (40 + extraVinculum) + "\nH742v" + vertSegment + "l-4 4-4 4c-.667.7 -2 1.5-4 2.5s-4.167 1.833-6.5 2.5-5.5 1-9.5 1\nh-12l-28-84c-16.667-52-96.667 -294.333-240-727l-212 -643 -85 170\nc-4-3.333-8.333-7.667-13 -13l-13-13l77-155 77-156c66 199.333 139 419.667\n219 661 l218 661zM702 " + hLinePad2 + "H400000v" + (40 + extraVinculum) + "H742z";
54288};
54289var sqrtPath = function sqrtPath2(size, extraVinculum, viewBoxHeight) {
54290  extraVinculum = 1e3 * extraVinculum;
54291  var path2 = "";
54292  switch (size) {
54293    case "sqrtMain":
54294      path2 = sqrtMain(extraVinculum, hLinePad);
54295      break;
54296    case "sqrtSize1":
54297      path2 = sqrtSize1(extraVinculum, hLinePad);
54298      break;
54299    case "sqrtSize2":
54300      path2 = sqrtSize2(extraVinculum, hLinePad);
54301      break;
54302    case "sqrtSize3":
54303      path2 = sqrtSize3(extraVinculum, hLinePad);
54304      break;
54305    case "sqrtSize4":
54306      path2 = sqrtSize4(extraVinculum, hLinePad);
54307      break;
54308    case "sqrtTall":
54309      path2 = sqrtTall(extraVinculum, hLinePad, viewBoxHeight);
54310  }
54311  return path2;
54312};
54313var innerPath = function innerPath2(name, height) {
54314  switch (name) {
54315    case "\u239C":
54316      return "M291 0 H417 V" + height + " H291z M291 0 H417 V" + height + " H291z";
54317    case "\u2223":
54318      return "M145 0 H188 V" + height + " H145z M145 0 H188 V" + height + " H145z";
54319    case "\u2225":
54320      return "M145 0 H188 V" + height + " H145z M145 0 H188 V" + height + " H145z" + ("M367 0 H410 V" + height + " H367z M367 0 H410 V" + height + " H367z");
54321    case "\u239F":
54322      return "M457 0 H583 V" + height + " H457z M457 0 H583 V" + height + " H457z";
54323    case "\u23A2":
54324      return "M319 0 H403 V" + height + " H319z M319 0 H403 V" + height + " H319z";
54325    case "\u23A5":
54326      return "M263 0 H347 V" + height + " H263z M263 0 H347 V" + height + " H263z";
54327    case "\u23AA":
54328      return "M384 0 H504 V" + height + " H384z M384 0 H504 V" + height + " H384z";
54329    case "\u23D0":
54330      return "M312 0 H355 V" + height + " H312z M312 0 H355 V" + height + " H312z";
54331    case "\u2016":
54332      return "M257 0 H300 V" + height + " H257z M257 0 H300 V" + height + " H257z" + ("M478 0 H521 V" + height + " H478z M478 0 H521 V" + height + " H478z");
54333    default:
54334      return "";
54335  }
54336};
54337var path = {
54338  // The doubleleftarrow geometry is from glyph U+21D0 in the font KaTeX Main
54339  doubleleftarrow: "M262 157\nl10-10c34-36 62.7-77 86-123 3.3-8 5-13.3 5-16 0-5.3-6.7-8-20-8-7.3\n 0-12.2.5-14.5 1.5-2.3 1-4.8 4.5-7.5 10.5-49.3 97.3-121.7 169.3-217 216-28\n 14-57.3 25-88 33-6.7 2-11 3.8-13 5.5-2 1.7-3 4.2-3 7.5s1 5.8 3 7.5\nc2 1.7 6.3 3.5 13 5.5 68 17.3 128.2 47.8 180.5 91.5 52.3 43.7 93.8 96.2 124.5\n 157.5 9.3 8 15.3 12.3 18 13h6c12-.7 18-4 18-10 0-2-1.7-7-5-15-23.3-46-52-87\n-86-123l-10-10h399738v-40H218c328 0 0 0 0 0l-10-8c-26.7-20-65.7-43-117-69 2.7\n-2 6-3.7 10-5 36.7-16 72.3-37.3 107-64l10-8h399782v-40z\nm8 0v40h399730v-40zm0 194v40h399730v-40z",
54340  // doublerightarrow is from glyph U+21D2 in font KaTeX Main
54341  doublerightarrow: "M399738 392l\n-10 10c-34 36-62.7 77-86 123-3.3 8-5 13.3-5 16 0 5.3 6.7 8 20 8 7.3 0 12.2-.5\n 14.5-1.5 2.3-1 4.8-4.5 7.5-10.5 49.3-97.3 121.7-169.3 217-216 28-14 57.3-25 88\n-33 6.7-2 11-3.8 13-5.5 2-1.7 3-4.2 3-7.5s-1-5.8-3-7.5c-2-1.7-6.3-3.5-13-5.5-68\n-17.3-128.2-47.8-180.5-91.5-52.3-43.7-93.8-96.2-124.5-157.5-9.3-8-15.3-12.3-18\n-13h-6c-12 .7-18 4-18 10 0 2 1.7 7 5 15 23.3 46 52 87 86 123l10 10H0v40h399782\nc-328 0 0 0 0 0l10 8c26.7 20 65.7 43 117 69-2.7 2-6 3.7-10 5-36.7 16-72.3 37.3\n-107 64l-10 8H0v40zM0 157v40h399730v-40zm0 194v40h399730v-40z",
54342  // leftarrow is from glyph U+2190 in font KaTeX Main
54343  leftarrow: "M400000 241H110l3-3c68.7-52.7 113.7-120\n 135-202 4-14.7 6-23 6-25 0-7.3-7-11-21-11-8 0-13.2.8-15.5 2.5-2.3 1.7-4.2 5.8\n-5.5 12.5-1.3 4.7-2.7 10.3-4 17-12 48.7-34.8 92-68.5 130S65.3 228.3 18 247\nc-10 4-16 7.7-18 11 0 8.7 6 14.3 18 17 47.3 18.7 87.8 47 121.5 85S196 441.3 208\n 490c.7 2 1.3 5 2 9s1.2 6.7 1.5 8c.3 1.3 1 3.3 2 6s2.2 4.5 3.5 5.5c1.3 1 3.3\n 1.8 6 2.5s6 1 10 1c14 0 21-3.7 21-11 0-2-2-10.3-6-25-20-79.3-65-146.7-135-202\n l-3-3h399890zM100 241v40h399900v-40z",
54344  // overbrace is from glyphs U+23A9/23A8/23A7 in font KaTeX_Size4-Regular
54345  leftbrace: "M6 548l-6-6v-35l6-11c56-104 135.3-181.3 238-232 57.3-28.7 117\n-45 179-50h399577v120H403c-43.3 7-81 15-113 26-100.7 33-179.7 91-237 174-2.7\n 5-6 9-10 13-.7 1-7.3 1-20 1H6z",
54346  leftbraceunder: "M0 6l6-6h17c12.688 0 19.313.3 20 1 4 4 7.313 8.3 10 13\n 35.313 51.3 80.813 93.8 136.5 127.5 55.688 33.7 117.188 55.8 184.5 66.5.688\n 0 2 .3 4 1 18.688 2.7 76 4.3 172 5h399450v120H429l-6-1c-124.688-8-235-61.7\n-331-161C60.687 138.7 32.312 99.3 7 54L0 41V6z",
54347  // overgroup is from the MnSymbol package (public domain)
54348  leftgroup: "M400000 80\nH435C64 80 168.3 229.4 21 260c-5.9 1.2-18 0-18 0-2 0-3-1-3-3v-38C76 61 257 0\n 435 0h399565z",
54349  leftgroupunder: "M400000 262\nH435C64 262 168.3 112.6 21 82c-5.9-1.2-18 0-18 0-2 0-3 1-3 3v38c76 158 257 219\n 435 219h399565z",
54350  // Harpoons are from glyph U+21BD in font KaTeX Main
54351  leftharpoon: "M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3\n-3.3 10.2-9.5 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5\n-18.3 3-21-1.3-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7\n-196 228-6.7 4.7-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40z",
54352  leftharpoonplus: "M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3-3.3 10.2-9.5\n 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5-18.3 3-21-1.3\n-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7-196 228-6.7 4.7\n-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40zM0 435v40h400000v-40z\nm0 0v40h400000v-40z",
54353  leftharpoondown: "M7 241c-4 4-6.333 8.667-7 14 0 5.333.667 9 2 11s5.333\n 5.333 12 10c90.667 54 156 130 196 228 3.333 10.667 6.333 16.333 9 17 2 .667 5\n 1 9 1h5c10.667 0 16.667-2 18-6 2-2.667 1-9.667-3-21-32-87.333-82.667-157.667\n-152-211l-3-3h399907v-40zM93 281 H400000 v-40L7 241z",
54354  leftharpoondownplus: "M7 435c-4 4-6.3 8.7-7 14 0 5.3.7 9 2 11s5.3 5.3 12\n 10c90.7 54 156 130 196 228 3.3 10.7 6.3 16.3 9 17 2 .7 5 1 9 1h5c10.7 0 16.7\n-2 18-6 2-2.7 1-9.7-3-21-32-87.3-82.7-157.7-152-211l-3-3h399907v-40H7zm93 0\nv40h399900v-40zM0 241v40h399900v-40zm0 0v40h399900v-40z",
54355  // hook is from glyph U+21A9 in font KaTeX Main
54356  lefthook: "M400000 281 H103s-33-11.2-61-33.5S0 197.3 0 164s14.2-61.2 42.5\n-83.5C70.8 58.2 104 47 142 47 c16.7 0 25 6.7 25 20 0 12-8.7 18.7-26 20-40 3.3\n-68.7 15.7-86 37-10 12-15 25.3-15 40 0 22.7 9.8 40.7 29.5 54 19.7 13.3 43.5 21\n 71.5 23h399859zM103 281v-40h399897v40z",
54357  leftlinesegment: "M40 281 V428 H0 V94 H40 V241 H400000 v40z\nM40 281 V428 H0 V94 H40 V241 H400000 v40z",
54358  leftmapsto: "M40 281 V448H0V74H40V241H400000v40z\nM40 281 V448H0V74H40V241H400000v40z",
54359  // tofrom is from glyph U+21C4 in font KaTeX AMS Regular
54360  leftToFrom: "M0 147h400000v40H0zm0 214c68 40 115.7 95.7 143 167h22c15.3 0 23\n-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69-70-101l-7-8h399905v-40H95l7-8\nc28.7-32 52-65.7 70-101 10.7-23.3 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 265.3\n 68 321 0 361zm0-174v-40h399900v40zm100 154v40h399900v-40z",
54361  longequal: "M0 50 h400000 v40H0z m0 194h40000v40H0z\nM0 50 h400000 v40H0z m0 194h40000v40H0z",
54362  midbrace: "M200428 334\nc-100.7-8.3-195.3-44-280-108-55.3-42-101.7-93-139-153l-9-14c-2.7 4-5.7 8.7-9 14\n-53.3 86.7-123.7 153-211 199-66.7 36-137.3 56.3-212 62H0V214h199568c178.3-11.7\n 311.7-78.3 403-201 6-8 9.7-12 11-12 .7-.7 6.7-1 18-1s17.3.3 18 1c1.3 0 5 4 11\n 12 44.7 59.3 101.3 106.3 170 141s145.3 54.3 229 60h199572v120z",
54363  midbraceunder: "M199572 214\nc100.7 8.3 195.3 44 280 108 55.3 42 101.7 93 139 153l9 14c2.7-4 5.7-8.7 9-14\n 53.3-86.7 123.7-153 211-199 66.7-36 137.3-56.3 212-62h199568v120H200432c-178.3\n 11.7-311.7 78.3-403 201-6 8-9.7 12-11 12-.7.7-6.7 1-18 1s-17.3-.3-18-1c-1.3 0\n-5-4-11-12-44.7-59.3-101.3-106.3-170-141s-145.3-54.3-229-60H0V214z",
54364  oiintSize1: "M512.6 71.6c272.6 0 320.3 106.8 320.3 178.2 0 70.8-47.7 177.6\n-320.3 177.6S193.1 320.6 193.1 249.8c0-71.4 46.9-178.2 319.5-178.2z\nm368.1 178.2c0-86.4-60.9-215.4-368.1-215.4-306.4 0-367.3 129-367.3 215.4 0 85.8\n60.9 214.8 367.3 214.8 307.2 0 368.1-129 368.1-214.8z",
54365  oiintSize2: "M757.8 100.1c384.7 0 451.1 137.6 451.1 230 0 91.3-66.4 228.8\n-451.1 228.8-386.3 0-452.7-137.5-452.7-228.8 0-92.4 66.4-230 452.7-230z\nm502.4 230c0-111.2-82.4-277.2-502.4-277.2s-504 166-504 277.2\nc0 110 84 276 504 276s502.4-166 502.4-276z",
54366  oiiintSize1: "M681.4 71.6c408.9 0 480.5 106.8 480.5 178.2 0 70.8-71.6 177.6\n-480.5 177.6S202.1 320.6 202.1 249.8c0-71.4 70.5-178.2 479.3-178.2z\nm525.8 178.2c0-86.4-86.8-215.4-525.7-215.4-437.9 0-524.7 129-524.7 215.4 0\n85.8 86.8 214.8 524.7 214.8 438.9 0 525.7-129 525.7-214.8z",
54367  oiiintSize2: "M1021.2 53c603.6 0 707.8 165.8 707.8 277.2 0 110-104.2 275.8\n-707.8 275.8-606 0-710.2-165.8-710.2-275.8C311 218.8 415.2 53 1021.2 53z\nm770.4 277.1c0-131.2-126.4-327.6-770.5-327.6S248.4 198.9 248.4 330.1\nc0 130 128.8 326.4 772.7 326.4s770.5-196.4 770.5-326.4z",
54368  rightarrow: "M0 241v40h399891c-47.3 35.3-84 78-110 128\n-16.7 32-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20\n 11 8 0 13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7\n 39-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85\n-40.5-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5\n-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67\n 151.7 139 205zm0 0v40h399900v-40z",
54369  rightbrace: "M400000 542l\n-6 6h-17c-12.7 0-19.3-.3-20-1-4-4-7.3-8.3-10-13-35.3-51.3-80.8-93.8-136.5-127.5\ns-117.2-55.8-184.5-66.5c-.7 0-2-.3-4-1-18.7-2.7-76-4.3-172-5H0V214h399571l6 1\nc124.7 8 235 61.7 331 161 31.3 33.3 59.7 72.7 85 118l7 13v35z",
54370  rightbraceunder: "M399994 0l6 6v35l-6 11c-56 104-135.3 181.3-238 232-57.3\n 28.7-117 45-179 50H-300V214h399897c43.3-7 81-15 113-26 100.7-33 179.7-91 237\n-174 2.7-5 6-9 10-13 .7-1 7.3-1 20-1h17z",
54371  rightgroup: "M0 80h399565c371 0 266.7 149.4 414 180 5.9 1.2 18 0 18 0 2 0\n 3-1 3-3v-38c-76-158-257-219-435-219H0z",
54372  rightgroupunder: "M0 262h399565c371 0 266.7-149.4 414-180 5.9-1.2 18 0 18\n 0 2 0 3 1 3 3v38c-76 158-257 219-435 219H0z",
54373  rightharpoon: "M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3\n-3.7-15.3-11-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2\n-10.7 0-16.7 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58\n 69.2 92 94.5zm0 0v40h399900v-40z",
54374  rightharpoonplus: "M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3-3.7-15.3-11\n-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2-10.7 0-16.7\n 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58 69.2 92 94.5z\nm0 0v40h399900v-40z m100 194v40h399900v-40zm0 0v40h399900v-40z",
54375  rightharpoondown: "M399747 511c0 7.3 6.7 11 20 11 8 0 13-.8 15-2.5s4.7-6.8\n 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3 8.5-5.8 9.5\n-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3-64.7 57-92 95\n-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 241v40h399900v-40z",
54376  rightharpoondownplus: "M399747 705c0 7.3 6.7 11 20 11 8 0 13-.8\n 15-2.5s4.7-6.8 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3\n 8.5-5.8 9.5-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3\n-64.7 57-92 95-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 435v40h399900v-40z\nm0-194v40h400000v-40zm0 0v40h400000v-40z",
54377  righthook: "M399859 241c-764 0 0 0 0 0 40-3.3 68.7-15.7 86-37 10-12 15-25.3\n 15-40 0-22.7-9.8-40.7-29.5-54-19.7-13.3-43.5-21-71.5-23-17.3-1.3-26-8-26-20 0\n-13.3 8.7-20 26-20 38 0 71 11.2 99 33.5 0 0 7 5.6 21 16.7 14 11.2 21 33.5 21\n 66.8s-14 61.2-42 83.5c-28 22.3-61 33.5-99 33.5L0 241z M0 281v-40h399859v40z",
54378  rightlinesegment: "M399960 241 V94 h40 V428 h-40 V281 H0 v-40z\nM399960 241 V94 h40 V428 h-40 V281 H0 v-40z",
54379  rightToFrom: "M400000 167c-70.7-42-118-97.7-142-167h-23c-15.3 0-23 .3-23\n 1 0 1.3 5.3 13.7 16 37 18 35.3 41.3 69 70 101l7 8H0v40h399905l-7 8c-28.7 32\n-52 65.7-70 101-10.7 23.3-16 35.7-16 37 0 .7 7.7 1 23 1h23c24-69.3 71.3-125 142\n-167z M100 147v40h399900v-40zM0 341v40h399900v-40z",
54380  // twoheadleftarrow is from glyph U+219E in font KaTeX AMS Regular
54381  twoheadleftarrow: "M0 167c68 40\n 115.7 95.7 143 167h22c15.3 0 23-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69\n-70-101l-7-8h125l9 7c50.7 39.3 85 86 103 140h46c0-4.7-6.3-18.7-19-42-18-35.3\n-40-67.3-66-96l-9-9h399716v-40H284l9-9c26-28.7 48-60.7 66-96 12.7-23.333 19\n-37.333 19-42h-46c-18 54-52.3 100.7-103 140l-9 7H95l7-8c28.7-32 52-65.7 70-101\n 10.7-23.333 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 71.3 68 127 0 167z",
54382  twoheadrightarrow: "M400000 167\nc-68-40-115.7-95.7-143-167h-22c-15.3 0-23 .3-23 1 0 1.3 5.3 13.7 16 37 18 35.3\n 41.3 69 70 101l7 8h-125l-9-7c-50.7-39.3-85-86-103-140h-46c0 4.7 6.3 18.7 19 42\n 18 35.3 40 67.3 66 96l9 9H0v40h399716l-9 9c-26 28.7-48 60.7-66 96-12.7 23.333\n-19 37.333-19 42h46c18-54 52.3-100.7 103-140l9-7h125l-7 8c-28.7 32-52 65.7-70\n 101-10.7 23.333-16 35.7-16 37 0 .7 7.7 1 23 1h22c27.3-71.3 75-127 143-167z",
54383  // tilde1 is a modified version of a glyph from the MnSymbol package
54384  tilde1: "M200 55.538c-77 0-168 73.953-177 73.953-3 0-7\n-2.175-9-5.437L2 97c-1-2-2-4-2-6 0-4 2-7 5-9l20-12C116 12 171 0 207 0c86 0\n 114 68 191 68 78 0 168-68 177-68 4 0 7 2 9 5l12 19c1 2.175 2 4.35 2 6.525 0\n 4.35-2 7.613-5 9.788l-19 13.05c-92 63.077-116.937 75.308-183 76.128\n-68.267.847-113-73.952-191-73.952z",
54385  // ditto tilde2, tilde3, & tilde4
54386  tilde2: "M344 55.266c-142 0-300.638 81.316-311.5 86.418\n-8.01 3.762-22.5 10.91-23.5 5.562L1 120c-1-2-1-3-1-4 0-5 3-9 8-10l18.4-9C160.9\n 31.9 283 0 358 0c148 0 188 122 331 122s314-97 326-97c4 0 8 2 10 7l7 21.114\nc1 2.14 1 3.21 1 4.28 0 5.347-3 9.626-7 10.696l-22.3 12.622C852.6 158.372 751\n 181.476 676 181.476c-149 0-189-126.21-332-126.21z",
54387  tilde3: "M786 59C457 59 32 175.242 13 175.242c-6 0-10-3.457\n-11-10.37L.15 138c-1-7 3-12 10-13l19.2-6.4C378.4 40.7 634.3 0 804.3 0c337 0\n 411.8 157 746.8 157 328 0 754-112 773-112 5 0 10 3 11 9l1 14.075c1 8.066-.697\n 16.595-6.697 17.492l-21.052 7.31c-367.9 98.146-609.15 122.696-778.15 122.696\n -338 0-409-156.573-744-156.573z",
54388  tilde4: "M786 58C457 58 32 177.487 13 177.487c-6 0-10-3.345\n-11-10.035L.15 143c-1-7 3-12 10-13l22-6.7C381.2 35 637.15 0 807.15 0c337 0 409\n 177 744 177 328 0 754-127 773-127 5 0 10 3 11 9l1 14.794c1 7.805-3 13.38-9\n 14.495l-20.7 5.574c-366.85 99.79-607.3 139.372-776.3 139.372-338 0-409\n -175.236-744-175.236z",
54389  // vec is from glyph U+20D7 in font KaTeX Main
54390  vec: "M377 20c0-5.333 1.833-10 5.5-14S391 0 397 0c4.667 0 8.667 1.667 12 5\n3.333 2.667 6.667 9 10 19 6.667 24.667 20.333 43.667 41 57 7.333 4.667 11\n10.667 11 18 0 6-1 10-3 12s-6.667 5-14 9c-28.667 14.667-53.667 35.667-75 63\n-1.333 1.333-3.167 3.5-5.5 6.5s-4 4.833-5 5.5c-1 .667-2.5 1.333-4.5 2s-4.333 1\n-7 1c-4.667 0-9.167-1.833-13.5-5.5S337 184 337 178c0-12.667 15.667-32.333 47-59\nH213l-171-1c-8.667-6-13-12.333-13-19 0-4.667 4.333-11.333 13-20h359\nc-16-25.333-24-45-24-59z",
54391  // widehat1 is a modified version of a glyph from the MnSymbol package
54392  widehat1: "M529 0h5l519 115c5 1 9 5 9 10 0 1-1 2-1 3l-4 22\nc-1 5-5 9-11 9h-2L532 67 19 159h-2c-5 0-9-4-11-9l-5-22c-1-6 2-12 8-13z",
54393  // ditto widehat2, widehat3, & widehat4
54394  widehat2: "M1181 0h2l1171 176c6 0 10 5 10 11l-2 23c-1 6-5 10\n-11 10h-1L1182 67 15 220h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z",
54395  widehat3: "M1181 0h2l1171 236c6 0 10 5 10 11l-2 23c-1 6-5 10\n-11 10h-1L1182 67 15 280h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z",
54396  widehat4: "M1181 0h2l1171 296c6 0 10 5 10 11l-2 23c-1 6-5 10\n-11 10h-1L1182 67 15 340h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z",
54397  // widecheck paths are all inverted versions of widehat
54398  widecheck1: "M529,159h5l519,-115c5,-1,9,-5,9,-10c0,-1,-1,-2,-1,-3l-4,-22c-1,\n-5,-5,-9,-11,-9h-2l-512,92l-513,-92h-2c-5,0,-9,4,-11,9l-5,22c-1,6,2,12,8,13z",
54399  widecheck2: "M1181,220h2l1171,-176c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10,\n-11,-10h-1l-1168,153l-1167,-153h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z",
54400  widecheck3: "M1181,280h2l1171,-236c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10,\n-11,-10h-1l-1168,213l-1167,-213h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z",
54401  widecheck4: "M1181,340h2l1171,-296c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10,\n-11,-10h-1l-1168,273l-1167,-273h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z",
54402  // The next ten paths support reaction arrows from the mhchem package.
54403  // Arrows for \ce{<-->} are offset from xAxis by 0.22ex, per mhchem in LaTeX
54404  // baraboveleftarrow is mostly from glyph U+2190 in font KaTeX Main
54405  baraboveleftarrow: "M400000 620h-399890l3 -3c68.7 -52.7 113.7 -120 135 -202\nc4 -14.7 6 -23 6 -25c0 -7.3 -7 -11 -21 -11c-8 0 -13.2 0.8 -15.5 2.5\nc-2.3 1.7 -4.2 5.8 -5.5 12.5c-1.3 4.7 -2.7 10.3 -4 17c-12 48.7 -34.8 92 -68.5 130\ns-74.2 66.3 -121.5 85c-10 4 -16 7.7 -18 11c0 8.7 6 14.3 18 17c47.3 18.7 87.8 47\n121.5 85s56.5 81.3 68.5 130c0.7 2 1.3 5 2 9s1.2 6.7 1.5 8c0.3 1.3 1 3.3 2 6\ns2.2 4.5 3.5 5.5c1.3 1 3.3 1.8 6 2.5s6 1 10 1c14 0 21 -3.7 21 -11\nc0 -2 -2 -10.3 -6 -25c-20 -79.3 -65 -146.7 -135 -202l-3 -3h399890z\nM100 620v40h399900v-40z M0 241v40h399900v-40zM0 241v40h399900v-40z",
54406  // rightarrowabovebar is mostly from glyph U+2192, KaTeX Main
54407  rightarrowabovebar: "M0 241v40h399891c-47.3 35.3-84 78-110 128-16.7 32\n-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20 11 8 0\n13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7 39\n-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85-40.5\n-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5\n-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67\n151.7 139 205zm96 379h399894v40H0zm0 0h399904v40H0z",
54408  // The short left harpoon has 0.5em (i.e. 500 units) kern on the left end.
54409  // Ref from mhchem.sty: \rlap{\raisebox{-.22ex}{$\kern0.5em
54410  baraboveshortleftharpoon: "M507,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11\nc1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17\nc2,0.7,5,1,9,1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21\nc-32,-87.3,-82.7,-157.7,-152,-211c0,0,-3,-3,-3,-3l399351,0l0,-40\nc-398570,0,-399437,0,-399437,0z M593 435 v40 H399500 v-40z\nM0 281 v-40 H399908 v40z M0 281 v-40 H399908 v40z",
54411  rightharpoonaboveshortbar: "M0,241 l0,40c399126,0,399993,0,399993,0\nc4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199,\n-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6\nc-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z\nM0 241 v40 H399908 v-40z M0 475 v-40 H399500 v40z M0 475 v-40 H399500 v40z",
54412  shortbaraboveleftharpoon: "M7,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11\nc1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17c2,0.7,5,1,9,\n1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21c-32,-87.3,-82.7,-157.7,\n-152,-211c0,0,-3,-3,-3,-3l399907,0l0,-40c-399126,0,-399993,0,-399993,0z\nM93 435 v40 H400000 v-40z M500 241 v40 H400000 v-40z M500 241 v40 H400000 v-40z",
54413  shortrightharpoonabovebar: "M53,241l0,40c398570,0,399437,0,399437,0\nc4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199,\n-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6\nc-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z\nM500 241 v40 H399408 v-40z M500 435 v40 H400000 v-40z"
54414};
54415var tallDelim = function tallDelim2(label, midHeight) {
54416  switch (label) {
54417    case "lbrack":
54418      return "M403 1759 V84 H666 V0 H319 V1759 v" + midHeight + " v1759 h347 v-84\nH403z M403 1759 V0 H319 V1759 v" + midHeight + " v1759 h84z";
54419    case "rbrack":
54420      return "M347 1759 V0 H0 V84 H263 V1759 v" + midHeight + " v1759 H0 v84 H347z\nM347 1759 V0 H263 V1759 v" + midHeight + " v1759 h84z";
54421    case "vert":
54422      return "M145 15 v585 v" + midHeight + " v585 c2.667,10,9.667,15,21,15\nc10,0,16.667,-5,20,-15 v-585 v" + -midHeight + " v-585 c-2.667,-10,-9.667,-15,-21,-15\nc-10,0,-16.667,5,-20,15z M188 15 H145 v585 v" + midHeight + " v585 h43z";
54423    case "doublevert":
54424      return "M145 15 v585 v" + midHeight + " v585 c2.667,10,9.667,15,21,15\nc10,0,16.667,-5,20,-15 v-585 v" + -midHeight + " v-585 c-2.667,-10,-9.667,-15,-21,-15\nc-10,0,-16.667,5,-20,15z M188 15 H145 v585 v" + midHeight + " v585 h43z\nM367 15 v585 v" + midHeight + " v585 c2.667,10,9.667,15,21,15\nc10,0,16.667,-5,20,-15 v-585 v" + -midHeight + " v-585 c-2.667,-10,-9.667,-15,-21,-15\nc-10,0,-16.667,5,-20,15z M410 15 H367 v585 v" + midHeight + " v585 h43z";
54425    case "lfloor":
54426      return "M319 602 V0 H403 V602 v" + midHeight + " v1715 h263 v84 H319z\nMM319 602 V0 H403 V602 v" + midHeight + " v1715 H319z";
54427    case "rfloor":
54428      return "M319 602 V0 H403 V602 v" + midHeight + " v1799 H0 v-84 H319z\nMM319 602 V0 H403 V602 v" + midHeight + " v1715 H319z";
54429    case "lceil":
54430      return "M403 1759 V84 H666 V0 H319 V1759 v" + midHeight + " v602 h84z\nM403 1759 V0 H319 V1759 v" + midHeight + " v602 h84z";
54431    case "rceil":
54432      return "M347 1759 V0 H0 V84 H263 V1759 v" + midHeight + " v602 h84z\nM347 1759 V0 h-84 V1759 v" + midHeight + " v602 h84z";
54433    case "lparen":
54434      return "M863,9c0,-2,-2,-5,-6,-9c0,0,-17,0,-17,0c-12.7,0,-19.3,0.3,-20,1\nc-5.3,5.3,-10.3,11,-15,17c-242.7,294.7,-395.3,682,-458,1162c-21.3,163.3,-33.3,349,\n-36,557 l0," + (midHeight + 84) + "c0.2,6,0,26,0,60c2,159.3,10,310.7,24,454c53.3,528,210,\n949.7,470,1265c4.7,6,9.7,11.7,15,17c0.7,0.7,7,1,19,1c0,0,18,0,18,0c4,-4,6,-7,6,-9\nc0,-2.7,-3.3,-8.7,-10,-18c-135.3,-192.7,-235.5,-414.3,-300.5,-665c-65,-250.7,-102.5,\n-544.7,-112.5,-882c-2,-104,-3,-167,-3,-189\nl0,-" + (midHeight + 92) + "c0,-162.7,5.7,-314,17,-454c20.7,-272,63.7,-513,129,-723c65.3,\n-210,155.3,-396.3,270,-559c6.7,-9.3,10,-15.3,10,-18z";
54435    case "rparen":
54436      return "M76,0c-16.7,0,-25,3,-25,9c0,2,2,6.3,6,13c21.3,28.7,42.3,60.3,\n63,95c96.7,156.7,172.8,332.5,228.5,527.5c55.7,195,92.8,416.5,111.5,664.5\nc11.3,139.3,17,290.7,17,454c0,28,1.7,43,3.3,45l0," + (midHeight + 9) + "\nc-3,4,-3.3,16.7,-3.3,38c0,162,-5.7,313.7,-17,455c-18.7,248,-55.8,469.3,-111.5,664\nc-55.7,194.7,-131.8,370.3,-228.5,527c-20.7,34.7,-41.7,66.3,-63,95c-2,3.3,-4,7,-6,11\nc0,7.3,5.7,11,17,11c0,0,11,0,11,0c9.3,0,14.3,-0.3,15,-1c5.3,-5.3,10.3,-11,15,-17\nc242.7,-294.7,395.3,-681.7,458,-1161c21.3,-164.7,33.3,-350.7,36,-558\nl0,-" + (midHeight + 144) + "c-2,-159.3,-10,-310.7,-24,-454c-53.3,-528,-210,-949.7,\n-470,-1265c-4.7,-6,-9.7,-11.7,-15,-17c-0.7,-0.7,-6.7,-1,-18,-1z";
54437    default:
54438      throw new Error("Unknown stretchy delimiter.");
54439  }
54440};
54441var DocumentFragment = class {
54442  // HtmlDomNode
54443  // Never used; needed for satisfying interface.
54444  constructor(children) {
54445    this.children = void 0;
54446    this.classes = void 0;
54447    this.height = void 0;
54448    this.depth = void 0;
54449    this.maxFontSize = void 0;
54450    this.style = void 0;
54451    this.children = children;
54452    this.classes = [];
54453    this.height = 0;
54454    this.depth = 0;
54455    this.maxFontSize = 0;
54456    this.style = {};
54457  }
54458  hasClass(className) {
54459    return utils.contains(this.classes, className);
54460  }
54461  /** Convert the fragment into a node. */
54462  toNode() {
54463    var frag = document.createDocumentFragment();
54464    for (var i = 0; i < this.children.length; i++) {
54465      frag.appendChild(this.children[i].toNode());
54466    }
54467    return frag;
54468  }
54469  /** Convert the fragment into HTML markup. */
54470  toMarkup() {
54471    var markup = "";
54472    for (var i = 0; i < this.children.length; i++) {
54473      markup += this.children[i].toMarkup();
54474    }
54475    return markup;
54476  }
54477  /**
54478   * Converts the math node into a string, similar to innerText. Applies to
54479   * MathDomNode's only.
54480   */
54481  toText() {
54482    var toText = (child) => child.toText();
54483    return this.children.map(toText).join("");
54484  }
54485};
54486var fontMetricsData = {
54487  "AMS-Regular": {
54488    "32": [0, 0, 0, 0, 0.25],
54489    "65": [0, 0.68889, 0, 0, 0.72222],
54490    "66": [0, 0.68889, 0, 0, 0.66667],
54491    "67": [0, 0.68889, 0, 0, 0.72222],
54492    "68": [0, 0.68889, 0, 0, 0.72222],
54493    "69": [0, 0.68889, 0, 0, 0.66667],
54494    "70": [0, 0.68889, 0, 0, 0.61111],
54495    "71": [0, 0.68889, 0, 0, 0.77778],
54496    "72": [0, 0.68889, 0, 0, 0.77778],
54497    "73": [0, 0.68889, 0, 0, 0.38889],
54498    "74": [0.16667, 0.68889, 0, 0, 0.5],
54499    "75": [0, 0.68889, 0, 0, 0.77778],
54500    "76": [0, 0.68889, 0, 0, 0.66667],
54501    "77": [0, 0.68889, 0, 0, 0.94445],
54502    "78": [0, 0.68889, 0, 0, 0.72222],
54503    "79": [0.16667, 0.68889, 0, 0, 0.77778],
54504    "80": [0, 0.68889, 0, 0, 0.61111],
54505    "81": [0.16667, 0.68889, 0, 0, 0.77778],
54506    "82": [0, 0.68889, 0, 0, 0.72222],
54507    "83": [0, 0.68889, 0, 0, 0.55556],
54508    "84": [0, 0.68889, 0, 0, 0.66667],
54509    "85": [0, 0.68889, 0, 0, 0.72222],
54510    "86": [0, 0.68889, 0, 0, 0.72222],
54511    "87": [0, 0.68889, 0, 0, 1],
54512    "88": [0, 0.68889, 0, 0, 0.72222],
54513    "89": [0, 0.68889, 0, 0, 0.72222],
54514    "90": [0, 0.68889, 0, 0, 0.66667],
54515    "107": [0, 0.68889, 0, 0, 0.55556],
54516    "160": [0, 0, 0, 0, 0.25],
54517    "165": [0, 0.675, 0.025, 0, 0.75],
54518    "174": [0.15559, 0.69224, 0, 0, 0.94666],
54519    "240": [0, 0.68889, 0, 0, 0.55556],
54520    "295": [0, 0.68889, 0, 0, 0.54028],
54521    "710": [0, 0.825, 0, 0, 2.33334],
54522    "732": [0, 0.9, 0, 0, 2.33334],
54523    "770": [0, 0.825, 0, 0, 2.33334],
54524    "771": [0, 0.9, 0, 0, 2.33334],
54525    "989": [0.08167, 0.58167, 0, 0, 0.77778],
54526    "1008": [0, 0.43056, 0.04028, 0, 0.66667],
54527    "8245": [0, 0.54986, 0, 0, 0.275],
54528    "8463": [0, 0.68889, 0, 0, 0.54028],
54529    "8487": [0, 0.68889, 0, 0, 0.72222],
54530    "8498": [0, 0.68889, 0, 0, 0.55556],
54531    "8502": [0, 0.68889, 0, 0, 0.66667],
54532    "8503": [0, 0.68889, 0, 0, 0.44445],
54533    "8504": [0, 0.68889, 0, 0, 0.66667],
54534    "8513": [0, 0.68889, 0, 0, 0.63889],
54535    "8592": [-0.03598, 0.46402, 0, 0, 0.5],
54536    "8594": [-0.03598, 0.46402, 0, 0, 0.5],
54537    "8602": [-0.13313, 0.36687, 0, 0, 1],
54538    "8603": [-0.13313, 0.36687, 0, 0, 1],
54539    "8606": [0.01354, 0.52239, 0, 0, 1],
54540    "8608": [0.01354, 0.52239, 0, 0, 1],
54541    "8610": [0.01354, 0.52239, 0, 0, 1.11111],
54542    "8611": [0.01354, 0.52239, 0, 0, 1.11111],
54543    "8619": [0, 0.54986, 0, 0, 1],
54544    "8620": [0, 0.54986, 0, 0, 1],
54545    "8621": [-0.13313, 0.37788, 0, 0, 1.38889],
54546    "8622": [-0.13313, 0.36687, 0, 0, 1],
54547    "8624": [0, 0.69224, 0, 0, 0.5],
54548    "8625": [0, 0.69224, 0, 0, 0.5],
54549    "8630": [0, 0.43056, 0, 0, 1],
54550    "8631": [0, 0.43056, 0, 0, 1],
54551    "8634": [0.08198, 0.58198, 0, 0, 0.77778],
54552    "8635": [0.08198, 0.58198, 0, 0, 0.77778],
54553    "8638": [0.19444, 0.69224, 0, 0, 0.41667],
54554    "8639": [0.19444, 0.69224, 0, 0, 0.41667],
54555    "8642": [0.19444, 0.69224, 0, 0, 0.41667],
54556    "8643": [0.19444, 0.69224, 0, 0, 0.41667],
54557    "8644": [0.1808, 0.675, 0, 0, 1],
54558    "8646": [0.1808, 0.675, 0, 0, 1],
54559    "8647": [0.1808, 0.675, 0, 0, 1],
54560    "8648": [0.19444, 0.69224, 0, 0, 0.83334],
54561    "8649": [0.1808, 0.675, 0, 0, 1],
54562    "8650": [0.19444, 0.69224, 0, 0, 0.83334],
54563    "8651": [0.01354, 0.52239, 0, 0, 1],
54564    "8652": [0.01354, 0.52239, 0, 0, 1],
54565    "8653": [-0.13313, 0.36687, 0, 0, 1],
54566    "8654": [-0.13313, 0.36687, 0, 0, 1],
54567    "8655": [-0.13313, 0.36687, 0, 0, 1],
54568    "8666": [0.13667, 0.63667, 0, 0, 1],
54569    "8667": [0.13667, 0.63667, 0, 0, 1],
54570    "8669": [-0.13313, 0.37788, 0, 0, 1],
54571    "8672": [-0.064, 0.437, 0, 0, 1.334],
54572    "8674": [-0.064, 0.437, 0, 0, 1.334],
54573    "8705": [0, 0.825, 0, 0, 0.5],
54574    "8708": [0, 0.68889, 0, 0, 0.55556],
54575    "8709": [0.08167, 0.58167, 0, 0, 0.77778],
54576    "8717": [0, 0.43056, 0, 0, 0.42917],
54577    "8722": [-0.03598, 0.46402, 0, 0, 0.5],
54578    "8724": [0.08198, 0.69224, 0, 0, 0.77778],
54579    "8726": [0.08167, 0.58167, 0, 0, 0.77778],
54580    "8733": [0, 0.69224, 0, 0, 0.77778],
54581    "8736": [0, 0.69224, 0, 0, 0.72222],
54582    "8737": [0, 0.69224, 0, 0, 0.72222],
54583    "8738": [0.03517, 0.52239, 0, 0, 0.72222],
54584    "8739": [0.08167, 0.58167, 0, 0, 0.22222],
54585    "8740": [0.25142, 0.74111, 0, 0, 0.27778],
54586    "8741": [0.08167, 0.58167, 0, 0, 0.38889],
54587    "8742": [0.25142, 0.74111, 0, 0, 0.5],
54588    "8756": [0, 0.69224, 0, 0, 0.66667],
54589    "8757": [0, 0.69224, 0, 0, 0.66667],
54590    "8764": [-0.13313, 0.36687, 0, 0, 0.77778],
54591    "8765": [-0.13313, 0.37788, 0, 0, 0.77778],
54592    "8769": [-0.13313, 0.36687, 0, 0, 0.77778],
54593    "8770": [-0.03625, 0.46375, 0, 0, 0.77778],
54594    "8774": [0.30274, 0.79383, 0, 0, 0.77778],
54595    "8776": [-0.01688, 0.48312, 0, 0, 0.77778],
54596    "8778": [0.08167, 0.58167, 0, 0, 0.77778],
54597    "8782": [0.06062, 0.54986, 0, 0, 0.77778],
54598    "8783": [0.06062, 0.54986, 0, 0, 0.77778],
54599    "8785": [0.08198, 0.58198, 0, 0, 0.77778],
54600    "8786": [0.08198, 0.58198, 0, 0, 0.77778],
54601    "8787": [0.08198, 0.58198, 0, 0, 0.77778],
54602    "8790": [0, 0.69224, 0, 0, 0.77778],
54603    "8791": [0.22958, 0.72958, 0, 0, 0.77778],
54604    "8796": [0.08198, 0.91667, 0, 0, 0.77778],
54605    "8806": [0.25583, 0.75583, 0, 0, 0.77778],
54606    "8807": [0.25583, 0.75583, 0, 0, 0.77778],
54607    "8808": [0.25142, 0.75726, 0, 0, 0.77778],
54608    "8809": [0.25142, 0.75726, 0, 0, 0.77778],
54609    "8812": [0.25583, 0.75583, 0, 0, 0.5],
54610    "8814": [0.20576, 0.70576, 0, 0, 0.77778],
54611    "8815": [0.20576, 0.70576, 0, 0, 0.77778],
54612    "8816": [0.30274, 0.79383, 0, 0, 0.77778],
54613    "8817": [0.30274, 0.79383, 0, 0, 0.77778],
54614    "8818": [0.22958, 0.72958, 0, 0, 0.77778],
54615    "8819": [0.22958, 0.72958, 0, 0, 0.77778],
54616    "8822": [0.1808, 0.675, 0, 0, 0.77778],
54617    "8823": [0.1808, 0.675, 0, 0, 0.77778],
54618    "8828": [0.13667, 0.63667, 0, 0, 0.77778],
54619    "8829": [0.13667, 0.63667, 0, 0, 0.77778],
54620    "8830": [0.22958, 0.72958, 0, 0, 0.77778],
54621    "8831": [0.22958, 0.72958, 0, 0, 0.77778],
54622    "8832": [0.20576, 0.70576, 0, 0, 0.77778],
54623    "8833": [0.20576, 0.70576, 0, 0, 0.77778],
54624    "8840": [0.30274, 0.79383, 0, 0, 0.77778],
54625    "8841": [0.30274, 0.79383, 0, 0, 0.77778],
54626    "8842": [0.13597, 0.63597, 0, 0, 0.77778],
54627    "8843": [0.13597, 0.63597, 0, 0, 0.77778],
54628    "8847": [0.03517, 0.54986, 0, 0, 0.77778],
54629    "8848": [0.03517, 0.54986, 0, 0, 0.77778],
54630    "8858": [0.08198, 0.58198, 0, 0, 0.77778],
54631    "8859": [0.08198, 0.58198, 0, 0, 0.77778],
54632    "8861": [0.08198, 0.58198, 0, 0, 0.77778],
54633    "8862": [0, 0.675, 0, 0, 0.77778],
54634    "8863": [0, 0.675, 0, 0, 0.77778],
54635    "8864": [0, 0.675, 0, 0, 0.77778],
54636    "8865": [0, 0.675, 0, 0, 0.77778],
54637    "8872": [0, 0.69224, 0, 0, 0.61111],
54638    "8873": [0, 0.69224, 0, 0, 0.72222],
54639    "8874": [0, 0.69224, 0, 0, 0.88889],
54640    "8876": [0, 0.68889, 0, 0, 0.61111],
54641    "8877": [0, 0.68889, 0, 0, 0.61111],
54642    "8878": [0, 0.68889, 0, 0, 0.72222],
54643    "8879": [0, 0.68889, 0, 0, 0.72222],
54644    "8882": [0.03517, 0.54986, 0, 0, 0.77778],
54645    "8883": [0.03517, 0.54986, 0, 0, 0.77778],
54646    "8884": [0.13667, 0.63667, 0, 0, 0.77778],
54647    "8885": [0.13667, 0.63667, 0, 0, 0.77778],
54648    "8888": [0, 0.54986, 0, 0, 1.11111],
54649    "8890": [0.19444, 0.43056, 0, 0, 0.55556],
54650    "8891": [0.19444, 0.69224, 0, 0, 0.61111],
54651    "8892": [0.19444, 0.69224, 0, 0, 0.61111],
54652    "8901": [0, 0.54986, 0, 0, 0.27778],
54653    "8903": [0.08167, 0.58167, 0, 0, 0.77778],
54654    "8905": [0.08167, 0.58167, 0, 0, 0.77778],
54655    "8906": [0.08167, 0.58167, 0, 0, 0.77778],
54656    "8907": [0, 0.69224, 0, 0, 0.77778],
54657    "8908": [0, 0.69224, 0, 0, 0.77778],
54658    "8909": [-0.03598, 0.46402, 0, 0, 0.77778],
54659    "8910": [0, 0.54986, 0, 0, 0.76042],
54660    "8911": [0, 0.54986, 0, 0, 0.76042],
54661    "8912": [0.03517, 0.54986, 0, 0, 0.77778],
54662    "8913": [0.03517, 0.54986, 0, 0, 0.77778],
54663    "8914": [0, 0.54986, 0, 0, 0.66667],
54664    "8915": [0, 0.54986, 0, 0, 0.66667],
54665    "8916": [0, 0.69224, 0, 0, 0.66667],
54666    "8918": [0.0391, 0.5391, 0, 0, 0.77778],
54667    "8919": [0.0391, 0.5391, 0, 0, 0.77778],
54668    "8920": [0.03517, 0.54986, 0, 0, 1.33334],
54669    "8921": [0.03517, 0.54986, 0, 0, 1.33334],
54670    "8922": [0.38569, 0.88569, 0, 0, 0.77778],
54671    "8923": [0.38569, 0.88569, 0, 0, 0.77778],
54672    "8926": [0.13667, 0.63667, 0, 0, 0.77778],
54673    "8927": [0.13667, 0.63667, 0, 0, 0.77778],
54674    "8928": [0.30274, 0.79383, 0, 0, 0.77778],
54675    "8929": [0.30274, 0.79383, 0, 0, 0.77778],
54676    "8934": [0.23222, 0.74111, 0, 0, 0.77778],
54677    "8935": [0.23222, 0.74111, 0, 0, 0.77778],
54678    "8936": [0.23222, 0.74111, 0, 0, 0.77778],
54679    "8937": [0.23222, 0.74111, 0, 0, 0.77778],
54680    "8938": [0.20576, 0.70576, 0, 0, 0.77778],
54681    "8939": [0.20576, 0.70576, 0, 0, 0.77778],
54682    "8940": [0.30274, 0.79383, 0, 0, 0.77778],
54683    "8941": [0.30274, 0.79383, 0, 0, 0.77778],
54684    "8994": [0.19444, 0.69224, 0, 0, 0.77778],
54685    "8995": [0.19444, 0.69224, 0, 0, 0.77778],
54686    "9416": [0.15559, 0.69224, 0, 0, 0.90222],
54687    "9484": [0, 0.69224, 0, 0, 0.5],
54688    "9488": [0, 0.69224, 0, 0, 0.5],
54689    "9492": [0, 0.37788, 0, 0, 0.5],
54690    "9496": [0, 0.37788, 0, 0, 0.5],
54691    "9585": [0.19444, 0.68889, 0, 0, 0.88889],
54692    "9586": [0.19444, 0.74111, 0, 0, 0.88889],
54693    "9632": [0, 0.675, 0, 0, 0.77778],
54694    "9633": [0, 0.675, 0, 0, 0.77778],
54695    "9650": [0, 0.54986, 0, 0, 0.72222],
54696    "9651": [0, 0.54986, 0, 0, 0.72222],
54697    "9654": [0.03517, 0.54986, 0, 0, 0.77778],
54698    "9660": [0, 0.54986, 0, 0, 0.72222],
54699    "9661": [0, 0.54986, 0, 0, 0.72222],
54700    "9664": [0.03517, 0.54986, 0, 0, 0.77778],
54701    "9674": [0.11111, 0.69224, 0, 0, 0.66667],
54702    "9733": [0.19444, 0.69224, 0, 0, 0.94445],
54703    "10003": [0, 0.69224, 0, 0, 0.83334],
54704    "10016": [0, 0.69224, 0, 0, 0.83334],
54705    "10731": [0.11111, 0.69224, 0, 0, 0.66667],
54706    "10846": [0.19444, 0.75583, 0, 0, 0.61111],
54707    "10877": [0.13667, 0.63667, 0, 0, 0.77778],
54708    "10878": [0.13667, 0.63667, 0, 0, 0.77778],
54709    "10885": [0.25583, 0.75583, 0, 0, 0.77778],
54710    "10886": [0.25583, 0.75583, 0, 0, 0.77778],
54711    "10887": [0.13597, 0.63597, 0, 0, 0.77778],
54712    "10888": [0.13597, 0.63597, 0, 0, 0.77778],
54713    "10889": [0.26167, 0.75726, 0, 0, 0.77778],
54714    "10890": [0.26167, 0.75726, 0, 0, 0.77778],
54715    "10891": [0.48256, 0.98256, 0, 0, 0.77778],
54716    "10892": [0.48256, 0.98256, 0, 0, 0.77778],
54717    "10901": [0.13667, 0.63667, 0, 0, 0.77778],
54718    "10902": [0.13667, 0.63667, 0, 0, 0.77778],
54719    "10933": [0.25142, 0.75726, 0, 0, 0.77778],
54720    "10934": [0.25142, 0.75726, 0, 0, 0.77778],
54721    "10935": [0.26167, 0.75726, 0, 0, 0.77778],
54722    "10936": [0.26167, 0.75726, 0, 0, 0.77778],
54723    "10937": [0.26167, 0.75726, 0, 0, 0.77778],
54724    "10938": [0.26167, 0.75726, 0, 0, 0.77778],
54725    "10949": [0.25583, 0.75583, 0, 0, 0.77778],
54726    "10950": [0.25583, 0.75583, 0, 0, 0.77778],
54727    "10955": [0.28481, 0.79383, 0, 0, 0.77778],
54728    "10956": [0.28481, 0.79383, 0, 0, 0.77778],
54729    "57350": [0.08167, 0.58167, 0, 0, 0.22222],
54730    "57351": [0.08167, 0.58167, 0, 0, 0.38889],
54731    "57352": [0.08167, 0.58167, 0, 0, 0.77778],
54732    "57353": [0, 0.43056, 0.04028, 0, 0.66667],
54733    "57356": [0.25142, 0.75726, 0, 0, 0.77778],
54734    "57357": [0.25142, 0.75726, 0, 0, 0.77778],
54735    "57358": [0.41951, 0.91951, 0, 0, 0.77778],
54736    "57359": [0.30274, 0.79383, 0, 0, 0.77778],
54737    "57360": [0.30274, 0.79383, 0, 0, 0.77778],
54738    "57361": [0.41951, 0.91951, 0, 0, 0.77778],
54739    "57366": [0.25142, 0.75726, 0, 0, 0.77778],
54740    "57367": [0.25142, 0.75726, 0, 0, 0.77778],
54741    "57368": [0.25142, 0.75726, 0, 0, 0.77778],
54742    "57369": [0.25142, 0.75726, 0, 0, 0.77778],
54743    "57370": [0.13597, 0.63597, 0, 0, 0.77778],
54744    "57371": [0.13597, 0.63597, 0, 0, 0.77778]
54745  },
54746  "Caligraphic-Regular": {
54747    "32": [0, 0, 0, 0, 0.25],
54748    "65": [0, 0.68333, 0, 0.19445, 0.79847],
54749    "66": [0, 0.68333, 0.03041, 0.13889, 0.65681],
54750    "67": [0, 0.68333, 0.05834, 0.13889, 0.52653],
54751    "68": [0, 0.68333, 0.02778, 0.08334, 0.77139],
54752    "69": [0, 0.68333, 0.08944, 0.11111, 0.52778],
54753    "70": [0, 0.68333, 0.09931, 0.11111, 0.71875],
54754    "71": [0.09722, 0.68333, 0.0593, 0.11111, 0.59487],
54755    "72": [0, 0.68333, 965e-5, 0.11111, 0.84452],
54756    "73": [0, 0.68333, 0.07382, 0, 0.54452],
54757    "74": [0.09722, 0.68333, 0.18472, 0.16667, 0.67778],
54758    "75": [0, 0.68333, 0.01445, 0.05556, 0.76195],
54759    "76": [0, 0.68333, 0, 0.13889, 0.68972],
54760    "77": [0, 0.68333, 0, 0.13889, 1.2009],
54761    "78": [0, 0.68333, 0.14736, 0.08334, 0.82049],
54762    "79": [0, 0.68333, 0.02778, 0.11111, 0.79611],
54763    "80": [0, 0.68333, 0.08222, 0.08334, 0.69556],
54764    "81": [0.09722, 0.68333, 0, 0.11111, 0.81667],
54765    "82": [0, 0.68333, 0, 0.08334, 0.8475],
54766    "83": [0, 0.68333, 0.075, 0.13889, 0.60556],
54767    "84": [0, 0.68333, 0.25417, 0, 0.54464],
54768    "85": [0, 0.68333, 0.09931, 0.08334, 0.62583],
54769    "86": [0, 0.68333, 0.08222, 0, 0.61278],
54770    "87": [0, 0.68333, 0.08222, 0.08334, 0.98778],
54771    "88": [0, 0.68333, 0.14643, 0.13889, 0.7133],
54772    "89": [0.09722, 0.68333, 0.08222, 0.08334, 0.66834],
54773    "90": [0, 0.68333, 0.07944, 0.13889, 0.72473],
54774    "160": [0, 0, 0, 0, 0.25]
54775  },
54776  "Fraktur-Regular": {
54777    "32": [0, 0, 0, 0, 0.25],
54778    "33": [0, 0.69141, 0, 0, 0.29574],
54779    "34": [0, 0.69141, 0, 0, 0.21471],
54780    "38": [0, 0.69141, 0, 0, 0.73786],
54781    "39": [0, 0.69141, 0, 0, 0.21201],
54782    "40": [0.24982, 0.74947, 0, 0, 0.38865],
54783    "41": [0.24982, 0.74947, 0, 0, 0.38865],
54784    "42": [0, 0.62119, 0, 0, 0.27764],
54785    "43": [0.08319, 0.58283, 0, 0, 0.75623],
54786    "44": [0, 0.10803, 0, 0, 0.27764],
54787    "45": [0.08319, 0.58283, 0, 0, 0.75623],
54788    "46": [0, 0.10803, 0, 0, 0.27764],
54789    "47": [0.24982, 0.74947, 0, 0, 0.50181],
54790    "48": [0, 0.47534, 0, 0, 0.50181],
54791    "49": [0, 0.47534, 0, 0, 0.50181],
54792    "50": [0, 0.47534, 0, 0, 0.50181],
54793    "51": [0.18906, 0.47534, 0, 0, 0.50181],
54794    "52": [0.18906, 0.47534, 0, 0, 0.50181],
54795    "53": [0.18906, 0.47534, 0, 0, 0.50181],
54796    "54": [0, 0.69141, 0, 0, 0.50181],
54797    "55": [0.18906, 0.47534, 0, 0, 0.50181],
54798    "56": [0, 0.69141, 0, 0, 0.50181],
54799    "57": [0.18906, 0.47534, 0, 0, 0.50181],
54800    "58": [0, 0.47534, 0, 0, 0.21606],
54801    "59": [0.12604, 0.47534, 0, 0, 0.21606],
54802    "61": [-0.13099, 0.36866, 0, 0, 0.75623],
54803    "63": [0, 0.69141, 0, 0, 0.36245],
54804    "65": [0, 0.69141, 0, 0, 0.7176],
54805    "66": [0, 0.69141, 0, 0, 0.88397],
54806    "67": [0, 0.69141, 0, 0, 0.61254],
54807    "68": [0, 0.69141, 0, 0, 0.83158],
54808    "69": [0, 0.69141, 0, 0, 0.66278],
54809    "70": [0.12604, 0.69141, 0, 0, 0.61119],
54810    "71": [0, 0.69141, 0, 0, 0.78539],
54811    "72": [0.06302, 0.69141, 0, 0, 0.7203],
54812    "73": [0, 0.69141, 0, 0, 0.55448],
54813    "74": [0.12604, 0.69141, 0, 0, 0.55231],
54814    "75": [0, 0.69141, 0, 0, 0.66845],
54815    "76": [0, 0.69141, 0, 0, 0.66602],
54816    "77": [0, 0.69141, 0, 0, 1.04953],
54817    "78": [0, 0.69141, 0, 0, 0.83212],
54818    "79": [0, 0.69141, 0, 0, 0.82699],
54819    "80": [0.18906, 0.69141, 0, 0, 0.82753],
54820    "81": [0.03781, 0.69141, 0, 0, 0.82699],
54821    "82": [0, 0.69141, 0, 0, 0.82807],
54822    "83": [0, 0.69141, 0, 0, 0.82861],
54823    "84": [0, 0.69141, 0, 0, 0.66899],
54824    "85": [0, 0.69141, 0, 0, 0.64576],
54825    "86": [0, 0.69141, 0, 0, 0.83131],
54826    "87": [0, 0.69141, 0, 0, 1.04602],
54827    "88": [0, 0.69141, 0, 0, 0.71922],
54828    "89": [0.18906, 0.69141, 0, 0, 0.83293],
54829    "90": [0.12604, 0.69141, 0, 0, 0.60201],
54830    "91": [0.24982, 0.74947, 0, 0, 0.27764],
54831    "93": [0.24982, 0.74947, 0, 0, 0.27764],
54832    "94": [0, 0.69141, 0, 0, 0.49965],
54833    "97": [0, 0.47534, 0, 0, 0.50046],
54834    "98": [0, 0.69141, 0, 0, 0.51315],
54835    "99": [0, 0.47534, 0, 0, 0.38946],
54836    "100": [0, 0.62119, 0, 0, 0.49857],
54837    "101": [0, 0.47534, 0, 0, 0.40053],
54838    "102": [0.18906, 0.69141, 0, 0, 0.32626],
54839    "103": [0.18906, 0.47534, 0, 0, 0.5037],
54840    "104": [0.18906, 0.69141, 0, 0, 0.52126],
54841    "105": [0, 0.69141, 0, 0, 0.27899],
54842    "106": [0, 0.69141, 0, 0, 0.28088],
54843    "107": [0, 0.69141, 0, 0, 0.38946],
54844    "108": [0, 0.69141, 0, 0, 0.27953],
54845    "109": [0, 0.47534, 0, 0, 0.76676],
54846    "110": [0, 0.47534, 0, 0, 0.52666],
54847    "111": [0, 0.47534, 0, 0, 0.48885],
54848    "112": [0.18906, 0.52396, 0, 0, 0.50046],
54849    "113": [0.18906, 0.47534, 0, 0, 0.48912],
54850    "114": [0, 0.47534, 0, 0, 0.38919],
54851    "115": [0, 0.47534, 0, 0, 0.44266],
54852    "116": [0, 0.62119, 0, 0, 0.33301],
54853    "117": [0, 0.47534, 0, 0, 0.5172],
54854    "118": [0, 0.52396, 0, 0, 0.5118],
54855    "119": [0, 0.52396, 0, 0, 0.77351],
54856    "120": [0.18906, 0.47534, 0, 0, 0.38865],
54857    "121": [0.18906, 0.47534, 0, 0, 0.49884],
54858    "122": [0.18906, 0.47534, 0, 0, 0.39054],
54859    "160": [0, 0, 0, 0, 0.25],
54860    "8216": [0, 0.69141, 0, 0, 0.21471],
54861    "8217": [0, 0.69141, 0, 0, 0.21471],
54862    "58112": [0, 0.62119, 0, 0, 0.49749],
54863    "58113": [0, 0.62119, 0, 0, 0.4983],
54864    "58114": [0.18906, 0.69141, 0, 0, 0.33328],
54865    "58115": [0.18906, 0.69141, 0, 0, 0.32923],
54866    "58116": [0.18906, 0.47534, 0, 0, 0.50343],
54867    "58117": [0, 0.69141, 0, 0, 0.33301],
54868    "58118": [0, 0.62119, 0, 0, 0.33409],
54869    "58119": [0, 0.47534, 0, 0, 0.50073]
54870  },
54871  "Main-Bold": {
54872    "32": [0, 0, 0, 0, 0.25],
54873    "33": [0, 0.69444, 0, 0, 0.35],
54874    "34": [0, 0.69444, 0, 0, 0.60278],
54875    "35": [0.19444, 0.69444, 0, 0, 0.95833],
54876    "36": [0.05556, 0.75, 0, 0, 0.575],
54877    "37": [0.05556, 0.75, 0, 0, 0.95833],
54878    "38": [0, 0.69444, 0, 0, 0.89444],
54879    "39": [0, 0.69444, 0, 0, 0.31944],
54880    "40": [0.25, 0.75, 0, 0, 0.44722],
54881    "41": [0.25, 0.75, 0, 0, 0.44722],
54882    "42": [0, 0.75, 0, 0, 0.575],
54883    "43": [0.13333, 0.63333, 0, 0, 0.89444],
54884    "44": [0.19444, 0.15556, 0, 0, 0.31944],
54885    "45": [0, 0.44444, 0, 0, 0.38333],
54886    "46": [0, 0.15556, 0, 0, 0.31944],
54887    "47": [0.25, 0.75, 0, 0, 0.575],
54888    "48": [0, 0.64444, 0, 0, 0.575],
54889    "49": [0, 0.64444, 0, 0, 0.575],
54890    "50": [0, 0.64444, 0, 0, 0.575],
54891    "51": [0, 0.64444, 0, 0, 0.575],
54892    "52": [0, 0.64444, 0, 0, 0.575],
54893    "53": [0, 0.64444, 0, 0, 0.575],
54894    "54": [0, 0.64444, 0, 0, 0.575],
54895    "55": [0, 0.64444, 0, 0, 0.575],
54896    "56": [0, 0.64444, 0, 0, 0.575],
54897    "57": [0, 0.64444, 0, 0, 0.575],
54898    "58": [0, 0.44444, 0, 0, 0.31944],
54899    "59": [0.19444, 0.44444, 0, 0, 0.31944],
54900    "60": [0.08556, 0.58556, 0, 0, 0.89444],
54901    "61": [-0.10889, 0.39111, 0, 0, 0.89444],
54902    "62": [0.08556, 0.58556, 0, 0, 0.89444],
54903    "63": [0, 0.69444, 0, 0, 0.54305],
54904    "64": [0, 0.69444, 0, 0, 0.89444],
54905    "65": [0, 0.68611, 0, 0, 0.86944],
54906    "66": [0, 0.68611, 0, 0, 0.81805],
54907    "67": [0, 0.68611, 0, 0, 0.83055],
54908    "68": [0, 0.68611, 0, 0, 0.88194],
54909    "69": [0, 0.68611, 0, 0, 0.75555],
54910    "70": [0, 0.68611, 0, 0, 0.72361],
54911    "71": [0, 0.68611, 0, 0, 0.90416],
54912    "72": [0, 0.68611, 0, 0, 0.9],
54913    "73": [0, 0.68611, 0, 0, 0.43611],
54914    "74": [0, 0.68611, 0, 0, 0.59444],
54915    "75": [0, 0.68611, 0, 0, 0.90138],
54916    "76": [0, 0.68611, 0, 0, 0.69166],
54917    "77": [0, 0.68611, 0, 0, 1.09166],
54918    "78": [0, 0.68611, 0, 0, 0.9],
54919    "79": [0, 0.68611, 0, 0, 0.86388],
54920    "80": [0, 0.68611, 0, 0, 0.78611],
54921    "81": [0.19444, 0.68611, 0, 0, 0.86388],
54922    "82": [0, 0.68611, 0, 0, 0.8625],
54923    "83": [0, 0.68611, 0, 0, 0.63889],
54924    "84": [0, 0.68611, 0, 0, 0.8],
54925    "85": [0, 0.68611, 0, 0, 0.88472],
54926    "86": [0, 0.68611, 0.01597, 0, 0.86944],
54927    "87": [0, 0.68611, 0.01597, 0, 1.18888],
54928    "88": [0, 0.68611, 0, 0, 0.86944],
54929    "89": [0, 0.68611, 0.02875, 0, 0.86944],
54930    "90": [0, 0.68611, 0, 0, 0.70277],
54931    "91": [0.25, 0.75, 0, 0, 0.31944],
54932    "92": [0.25, 0.75, 0, 0, 0.575],
54933    "93": [0.25, 0.75, 0, 0, 0.31944],
54934    "94": [0, 0.69444, 0, 0, 0.575],
54935    "95": [0.31, 0.13444, 0.03194, 0, 0.575],
54936    "97": [0, 0.44444, 0, 0, 0.55902],
54937    "98": [0, 0.69444, 0, 0, 0.63889],
54938    "99": [0, 0.44444, 0, 0, 0.51111],
54939    "100": [0, 0.69444, 0, 0, 0.63889],
54940    "101": [0, 0.44444, 0, 0, 0.52708],
54941    "102": [0, 0.69444, 0.10903, 0, 0.35139],
54942    "103": [0.19444, 0.44444, 0.01597, 0, 0.575],
54943    "104": [0, 0.69444, 0, 0, 0.63889],
54944    "105": [0, 0.69444, 0, 0, 0.31944],
54945    "106": [0.19444, 0.69444, 0, 0, 0.35139],
54946    "107": [0, 0.69444, 0, 0, 0.60694],
54947    "108": [0, 0.69444, 0, 0, 0.31944],
54948    "109": [0, 0.44444, 0, 0, 0.95833],
54949    "110": [0, 0.44444, 0, 0, 0.63889],
54950    "111": [0, 0.44444, 0, 0, 0.575],
54951    "112": [0.19444, 0.44444, 0, 0, 0.63889],
54952    "113": [0.19444, 0.44444, 0, 0, 0.60694],
54953    "114": [0, 0.44444, 0, 0, 0.47361],
54954    "115": [0, 0.44444, 0, 0, 0.45361],
54955    "116": [0, 0.63492, 0, 0, 0.44722],
54956    "117": [0, 0.44444, 0, 0, 0.63889],
54957    "118": [0, 0.44444, 0.01597, 0, 0.60694],
54958    "119": [0, 0.44444, 0.01597, 0, 0.83055],
54959    "120": [0, 0.44444, 0, 0, 0.60694],
54960    "121": [0.19444, 0.44444, 0.01597, 0, 0.60694],
54961    "122": [0, 0.44444, 0, 0, 0.51111],
54962    "123": [0.25, 0.75, 0, 0, 0.575],
54963    "124": [0.25, 0.75, 0, 0, 0.31944],
54964    "125": [0.25, 0.75, 0, 0, 0.575],
54965    "126": [0.35, 0.34444, 0, 0, 0.575],
54966    "160": [0, 0, 0, 0, 0.25],
54967    "163": [0, 0.69444, 0, 0, 0.86853],
54968    "168": [0, 0.69444, 0, 0, 0.575],
54969    "172": [0, 0.44444, 0, 0, 0.76666],
54970    "176": [0, 0.69444, 0, 0, 0.86944],
54971    "177": [0.13333, 0.63333, 0, 0, 0.89444],
54972    "184": [0.17014, 0, 0, 0, 0.51111],
54973    "198": [0, 0.68611, 0, 0, 1.04166],
54974    "215": [0.13333, 0.63333, 0, 0, 0.89444],
54975    "216": [0.04861, 0.73472, 0, 0, 0.89444],
54976    "223": [0, 0.69444, 0, 0, 0.59722],
54977    "230": [0, 0.44444, 0, 0, 0.83055],
54978    "247": [0.13333, 0.63333, 0, 0, 0.89444],
54979    "248": [0.09722, 0.54167, 0, 0, 0.575],
54980    "305": [0, 0.44444, 0, 0, 0.31944],
54981    "338": [0, 0.68611, 0, 0, 1.16944],
54982    "339": [0, 0.44444, 0, 0, 0.89444],
54983    "567": [0.19444, 0.44444, 0, 0, 0.35139],
54984    "710": [0, 0.69444, 0, 0, 0.575],
54985    "711": [0, 0.63194, 0, 0, 0.575],
54986    "713": [0, 0.59611, 0, 0, 0.575],
54987    "714": [0, 0.69444, 0, 0, 0.575],
54988    "715": [0, 0.69444, 0, 0, 0.575],
54989    "728": [0, 0.69444, 0, 0, 0.575],
54990    "729": [0, 0.69444, 0, 0, 0.31944],
54991    "730": [0, 0.69444, 0, 0, 0.86944],
54992    "732": [0, 0.69444, 0, 0, 0.575],
54993    "733": [0, 0.69444, 0, 0, 0.575],
54994    "915": [0, 0.68611, 0, 0, 0.69166],
54995    "916": [0, 0.68611, 0, 0, 0.95833],
54996    "920": [0, 0.68611, 0, 0, 0.89444],
54997    "923": [0, 0.68611, 0, 0, 0.80555],
54998    "926": [0, 0.68611, 0, 0, 0.76666],
54999    "928": [0, 0.68611, 0, 0, 0.9],
55000    "931": [0, 0.68611, 0, 0, 0.83055],
55001    "933": [0, 0.68611, 0, 0, 0.89444],
55002    "934": [0, 0.68611, 0, 0, 0.83055],
55003    "936": [0, 0.68611, 0, 0, 0.89444],
55004    "937": [0, 0.68611, 0, 0, 0.83055],
55005    "8211": [0, 0.44444, 0.03194, 0, 0.575],
55006    "8212": [0, 0.44444, 0.03194, 0, 1.14999],
55007    "8216": [0, 0.69444, 0, 0, 0.31944],
55008    "8217": [0, 0.69444, 0, 0, 0.31944],
55009    "8220": [0, 0.69444, 0, 0, 0.60278],
55010    "8221": [0, 0.69444, 0, 0, 0.60278],
55011    "8224": [0.19444, 0.69444, 0, 0, 0.51111],
55012    "8225": [0.19444, 0.69444, 0, 0, 0.51111],
55013    "8242": [0, 0.55556, 0, 0, 0.34444],
55014    "8407": [0, 0.72444, 0.15486, 0, 0.575],
55015    "8463": [0, 0.69444, 0, 0, 0.66759],
55016    "8465": [0, 0.69444, 0, 0, 0.83055],
55017    "8467": [0, 0.69444, 0, 0, 0.47361],
55018    "8472": [0.19444, 0.44444, 0, 0, 0.74027],
55019    "8476": [0, 0.69444, 0, 0, 0.83055],
55020    "8501": [0, 0.69444, 0, 0, 0.70277],
55021    "8592": [-0.10889, 0.39111, 0, 0, 1.14999],
55022    "8593": [0.19444, 0.69444, 0, 0, 0.575],
55023    "8594": [-0.10889, 0.39111, 0, 0, 1.14999],
55024    "8595": [0.19444, 0.69444, 0, 0, 0.575],
55025    "8596": [-0.10889, 0.39111, 0, 0, 1.14999],
55026    "8597": [0.25, 0.75, 0, 0, 0.575],
55027    "8598": [0.19444, 0.69444, 0, 0, 1.14999],
55028    "8599": [0.19444, 0.69444, 0, 0, 1.14999],
55029    "8600": [0.19444, 0.69444, 0, 0, 1.14999],
55030    "8601": [0.19444, 0.69444, 0, 0, 1.14999],
55031    "8636": [-0.10889, 0.39111, 0, 0, 1.14999],
55032    "8637": [-0.10889, 0.39111, 0, 0, 1.14999],
55033    "8640": [-0.10889, 0.39111, 0, 0, 1.14999],
55034    "8641": [-0.10889, 0.39111, 0, 0, 1.14999],
55035    "8656": [-0.10889, 0.39111, 0, 0, 1.14999],
55036    "8657": [0.19444, 0.69444, 0, 0, 0.70277],
55037    "8658": [-0.10889, 0.39111, 0, 0, 1.14999],
55038    "8659": [0.19444, 0.69444, 0, 0, 0.70277],
55039    "8660": [-0.10889, 0.39111, 0, 0, 1.14999],
55040    "8661": [0.25, 0.75, 0, 0, 0.70277],
55041    "8704": [0, 0.69444, 0, 0, 0.63889],
55042    "8706": [0, 0.69444, 0.06389, 0, 0.62847],
55043    "8707": [0, 0.69444, 0, 0, 0.63889],
55044    "8709": [0.05556, 0.75, 0, 0, 0.575],
55045    "8711": [0, 0.68611, 0, 0, 0.95833],
55046    "8712": [0.08556, 0.58556, 0, 0, 0.76666],
55047    "8715": [0.08556, 0.58556, 0, 0, 0.76666],
55048    "8722": [0.13333, 0.63333, 0, 0, 0.89444],
55049    "8723": [0.13333, 0.63333, 0, 0, 0.89444],
55050    "8725": [0.25, 0.75, 0, 0, 0.575],
55051    "8726": [0.25, 0.75, 0, 0, 0.575],
55052    "8727": [-0.02778, 0.47222, 0, 0, 0.575],
55053    "8728": [-0.02639, 0.47361, 0, 0, 0.575],
55054    "8729": [-0.02639, 0.47361, 0, 0, 0.575],
55055    "8730": [0.18, 0.82, 0, 0, 0.95833],
55056    "8733": [0, 0.44444, 0, 0, 0.89444],
55057    "8734": [0, 0.44444, 0, 0, 1.14999],
55058    "8736": [0, 0.69224, 0, 0, 0.72222],
55059    "8739": [0.25, 0.75, 0, 0, 0.31944],
55060    "8741": [0.25, 0.75, 0, 0, 0.575],
55061    "8743": [0, 0.55556, 0, 0, 0.76666],
55062    "8744": [0, 0.55556, 0, 0, 0.76666],
55063    "8745": [0, 0.55556, 0, 0, 0.76666],
55064    "8746": [0, 0.55556, 0, 0, 0.76666],
55065    "8747": [0.19444, 0.69444, 0.12778, 0, 0.56875],
55066    "8764": [-0.10889, 0.39111, 0, 0, 0.89444],
55067    "8768": [0.19444, 0.69444, 0, 0, 0.31944],
55068    "8771": [222e-5, 0.50222, 0, 0, 0.89444],
55069    "8773": [0.027, 0.638, 0, 0, 0.894],
55070    "8776": [0.02444, 0.52444, 0, 0, 0.89444],
55071    "8781": [222e-5, 0.50222, 0, 0, 0.89444],
55072    "8801": [222e-5, 0.50222, 0, 0, 0.89444],
55073    "8804": [0.19667, 0.69667, 0, 0, 0.89444],
55074    "8805": [0.19667, 0.69667, 0, 0, 0.89444],
55075    "8810": [0.08556, 0.58556, 0, 0, 1.14999],
55076    "8811": [0.08556, 0.58556, 0, 0, 1.14999],
55077    "8826": [0.08556, 0.58556, 0, 0, 0.89444],
55078    "8827": [0.08556, 0.58556, 0, 0, 0.89444],
55079    "8834": [0.08556, 0.58556, 0, 0, 0.89444],
55080    "8835": [0.08556, 0.58556, 0, 0, 0.89444],
55081    "8838": [0.19667, 0.69667, 0, 0, 0.89444],
55082    "8839": [0.19667, 0.69667, 0, 0, 0.89444],
55083    "8846": [0, 0.55556, 0, 0, 0.76666],
55084    "8849": [0.19667, 0.69667, 0, 0, 0.89444],
55085    "8850": [0.19667, 0.69667, 0, 0, 0.89444],
55086    "8851": [0, 0.55556, 0, 0, 0.76666],
55087    "8852": [0, 0.55556, 0, 0, 0.76666],
55088    "8853": [0.13333, 0.63333, 0, 0, 0.89444],
55089    "8854": [0.13333, 0.63333, 0, 0, 0.89444],
55090    "8855": [0.13333, 0.63333, 0, 0, 0.89444],
55091    "8856": [0.13333, 0.63333, 0, 0, 0.89444],
55092    "8857": [0.13333, 0.63333, 0, 0, 0.89444],
55093    "8866": [0, 0.69444, 0, 0, 0.70277],
55094    "8867": [0, 0.69444, 0, 0, 0.70277],
55095    "8868": [0, 0.69444, 0, 0, 0.89444],
55096    "8869": [0, 0.69444, 0, 0, 0.89444],
55097    "8900": [-0.02639, 0.47361, 0, 0, 0.575],
55098    "8901": [-0.02639, 0.47361, 0, 0, 0.31944],
55099    "8902": [-0.02778, 0.47222, 0, 0, 0.575],
55100    "8968": [0.25, 0.75, 0, 0, 0.51111],
55101    "8969": [0.25, 0.75, 0, 0, 0.51111],
55102    "8970": [0.25, 0.75, 0, 0, 0.51111],
55103    "8971": [0.25, 0.75, 0, 0, 0.51111],
55104    "8994": [-0.13889, 0.36111, 0, 0, 1.14999],
55105    "8995": [-0.13889, 0.36111, 0, 0, 1.14999],
55106    "9651": [0.19444, 0.69444, 0, 0, 1.02222],
55107    "9657": [-0.02778, 0.47222, 0, 0, 0.575],
55108    "9661": [0.19444, 0.69444, 0, 0, 1.02222],
55109    "9667": [-0.02778, 0.47222, 0, 0, 0.575],
55110    "9711": [0.19444, 0.69444, 0, 0, 1.14999],
55111    "9824": [0.12963, 0.69444, 0, 0, 0.89444],
55112    "9825": [0.12963, 0.69444, 0, 0, 0.89444],
55113    "9826": [0.12963, 0.69444, 0, 0, 0.89444],
55114    "9827": [0.12963, 0.69444, 0, 0, 0.89444],
55115    "9837": [0, 0.75, 0, 0, 0.44722],
55116    "9838": [0.19444, 0.69444, 0, 0, 0.44722],
55117    "9839": [0.19444, 0.69444, 0, 0, 0.44722],
55118    "10216": [0.25, 0.75, 0, 0, 0.44722],
55119    "10217": [0.25, 0.75, 0, 0, 0.44722],
55120    "10815": [0, 0.68611, 0, 0, 0.9],
55121    "10927": [0.19667, 0.69667, 0, 0, 0.89444],
55122    "10928": [0.19667, 0.69667, 0, 0, 0.89444],
55123    "57376": [0.19444, 0.69444, 0, 0, 0]
55124  },
55125  "Main-BoldItalic": {
55126    "32": [0, 0, 0, 0, 0.25],
55127    "33": [0, 0.69444, 0.11417, 0, 0.38611],
55128    "34": [0, 0.69444, 0.07939, 0, 0.62055],
55129    "35": [0.19444, 0.69444, 0.06833, 0, 0.94444],
55130    "37": [0.05556, 0.75, 0.12861, 0, 0.94444],
55131    "38": [0, 0.69444, 0.08528, 0, 0.88555],
55132    "39": [0, 0.69444, 0.12945, 0, 0.35555],
55133    "40": [0.25, 0.75, 0.15806, 0, 0.47333],
55134    "41": [0.25, 0.75, 0.03306, 0, 0.47333],
55135    "42": [0, 0.75, 0.14333, 0, 0.59111],
55136    "43": [0.10333, 0.60333, 0.03306, 0, 0.88555],
55137    "44": [0.19444, 0.14722, 0, 0, 0.35555],
55138    "45": [0, 0.44444, 0.02611, 0, 0.41444],
55139    "46": [0, 0.14722, 0, 0, 0.35555],
55140    "47": [0.25, 0.75, 0.15806, 0, 0.59111],
55141    "48": [0, 0.64444, 0.13167, 0, 0.59111],
55142    "49": [0, 0.64444, 0.13167, 0, 0.59111],
55143    "50": [0, 0.64444, 0.13167, 0, 0.59111],
55144    "51": [0, 0.64444, 0.13167, 0, 0.59111],
55145    "52": [0.19444, 0.64444, 0.13167, 0, 0.59111],
55146    "53": [0, 0.64444, 0.13167, 0, 0.59111],
55147    "54": [0, 0.64444, 0.13167, 0, 0.59111],
55148    "55": [0.19444, 0.64444, 0.13167, 0, 0.59111],
55149    "56": [0, 0.64444, 0.13167, 0, 0.59111],
55150    "57": [0, 0.64444, 0.13167, 0, 0.59111],
55151    "58": [0, 0.44444, 0.06695, 0, 0.35555],
55152    "59": [0.19444, 0.44444, 0.06695, 0, 0.35555],
55153    "61": [-0.10889, 0.39111, 0.06833, 0, 0.88555],
55154    "63": [0, 0.69444, 0.11472, 0, 0.59111],
55155    "64": [0, 0.69444, 0.09208, 0, 0.88555],
55156    "65": [0, 0.68611, 0, 0, 0.86555],
55157    "66": [0, 0.68611, 0.0992, 0, 0.81666],
55158    "67": [0, 0.68611, 0.14208, 0, 0.82666],
55159    "68": [0, 0.68611, 0.09062, 0, 0.87555],
55160    "69": [0, 0.68611, 0.11431, 0, 0.75666],
55161    "70": [0, 0.68611, 0.12903, 0, 0.72722],
55162    "71": [0, 0.68611, 0.07347, 0, 0.89527],
55163    "72": [0, 0.68611, 0.17208, 0, 0.8961],
55164    "73": [0, 0.68611, 0.15681, 0, 0.47166],
55165    "74": [0, 0.68611, 0.145, 0, 0.61055],
55166    "75": [0, 0.68611, 0.14208, 0, 0.89499],
55167    "76": [0, 0.68611, 0, 0, 0.69777],
55168    "77": [0, 0.68611, 0.17208, 0, 1.07277],
55169    "78": [0, 0.68611, 0.17208, 0, 0.8961],
55170    "79": [0, 0.68611, 0.09062, 0, 0.85499],
55171    "80": [0, 0.68611, 0.0992, 0, 0.78721],
55172    "81": [0.19444, 0.68611, 0.09062, 0, 0.85499],
55173    "82": [0, 0.68611, 0.02559, 0, 0.85944],
55174    "83": [0, 0.68611, 0.11264, 0, 0.64999],
55175    "84": [0, 0.68611, 0.12903, 0, 0.7961],
55176    "85": [0, 0.68611, 0.17208, 0, 0.88083],
55177    "86": [0, 0.68611, 0.18625, 0, 0.86555],
55178    "87": [0, 0.68611, 0.18625, 0, 1.15999],
55179    "88": [0, 0.68611, 0.15681, 0, 0.86555],
55180    "89": [0, 0.68611, 0.19803, 0, 0.86555],
55181    "90": [0, 0.68611, 0.14208, 0, 0.70888],
55182    "91": [0.25, 0.75, 0.1875, 0, 0.35611],
55183    "93": [0.25, 0.75, 0.09972, 0, 0.35611],
55184    "94": [0, 0.69444, 0.06709, 0, 0.59111],
55185    "95": [0.31, 0.13444, 0.09811, 0, 0.59111],
55186    "97": [0, 0.44444, 0.09426, 0, 0.59111],
55187    "98": [0, 0.69444, 0.07861, 0, 0.53222],
55188    "99": [0, 0.44444, 0.05222, 0, 0.53222],
55189    "100": [0, 0.69444, 0.10861, 0, 0.59111],
55190    "101": [0, 0.44444, 0.085, 0, 0.53222],
55191    "102": [0.19444, 0.69444, 0.21778, 0, 0.4],
55192    "103": [0.19444, 0.44444, 0.105, 0, 0.53222],
55193    "104": [0, 0.69444, 0.09426, 0, 0.59111],
55194    "105": [0, 0.69326, 0.11387, 0, 0.35555],
55195    "106": [0.19444, 0.69326, 0.1672, 0, 0.35555],
55196    "107": [0, 0.69444, 0.11111, 0, 0.53222],
55197    "108": [0, 0.69444, 0.10861, 0, 0.29666],
55198    "109": [0, 0.44444, 0.09426, 0, 0.94444],
55199    "110": [0, 0.44444, 0.09426, 0, 0.64999],
55200    "111": [0, 0.44444, 0.07861, 0, 0.59111],
55201    "112": [0.19444, 0.44444, 0.07861, 0, 0.59111],
55202    "113": [0.19444, 0.44444, 0.105, 0, 0.53222],
55203    "114": [0, 0.44444, 0.11111, 0, 0.50167],
55204    "115": [0, 0.44444, 0.08167, 0, 0.48694],
55205    "116": [0, 0.63492, 0.09639, 0, 0.385],
55206    "117": [0, 0.44444, 0.09426, 0, 0.62055],
55207    "118": [0, 0.44444, 0.11111, 0, 0.53222],
55208    "119": [0, 0.44444, 0.11111, 0, 0.76777],
55209    "120": [0, 0.44444, 0.12583, 0, 0.56055],
55210    "121": [0.19444, 0.44444, 0.105, 0, 0.56166],
55211    "122": [0, 0.44444, 0.13889, 0, 0.49055],
55212    "126": [0.35, 0.34444, 0.11472, 0, 0.59111],
55213    "160": [0, 0, 0, 0, 0.25],
55214    "168": [0, 0.69444, 0.11473, 0, 0.59111],
55215    "176": [0, 0.69444, 0, 0, 0.94888],
55216    "184": [0.17014, 0, 0, 0, 0.53222],
55217    "198": [0, 0.68611, 0.11431, 0, 1.02277],
55218    "216": [0.04861, 0.73472, 0.09062, 0, 0.88555],
55219    "223": [0.19444, 0.69444, 0.09736, 0, 0.665],
55220    "230": [0, 0.44444, 0.085, 0, 0.82666],
55221    "248": [0.09722, 0.54167, 0.09458, 0, 0.59111],
55222    "305": [0, 0.44444, 0.09426, 0, 0.35555],
55223    "338": [0, 0.68611, 0.11431, 0, 1.14054],
55224    "339": [0, 0.44444, 0.085, 0, 0.82666],
55225    "567": [0.19444, 0.44444, 0.04611, 0, 0.385],
55226    "710": [0, 0.69444, 0.06709, 0, 0.59111],
55227    "711": [0, 0.63194, 0.08271, 0, 0.59111],
55228    "713": [0, 0.59444, 0.10444, 0, 0.59111],
55229    "714": [0, 0.69444, 0.08528, 0, 0.59111],
55230    "715": [0, 0.69444, 0, 0, 0.59111],
55231    "728": [0, 0.69444, 0.10333, 0, 0.59111],
55232    "729": [0, 0.69444, 0.12945, 0, 0.35555],
55233    "730": [0, 0.69444, 0, 0, 0.94888],
55234    "732": [0, 0.69444, 0.11472, 0, 0.59111],
55235    "733": [0, 0.69444, 0.11472, 0, 0.59111],
55236    "915": [0, 0.68611, 0.12903, 0, 0.69777],
55237    "916": [0, 0.68611, 0, 0, 0.94444],
55238    "920": [0, 0.68611, 0.09062, 0, 0.88555],
55239    "923": [0, 0.68611, 0, 0, 0.80666],
55240    "926": [0, 0.68611, 0.15092, 0, 0.76777],
55241    "928": [0, 0.68611, 0.17208, 0, 0.8961],
55242    "931": [0, 0.68611, 0.11431, 0, 0.82666],
55243    "933": [0, 0.68611, 0.10778, 0, 0.88555],
55244    "934": [0, 0.68611, 0.05632, 0, 0.82666],
55245    "936": [0, 0.68611, 0.10778, 0, 0.88555],
55246    "937": [0, 0.68611, 0.0992, 0, 0.82666],
55247    "8211": [0, 0.44444, 0.09811, 0, 0.59111],
55248    "8212": [0, 0.44444, 0.09811, 0, 1.18221],
55249    "8216": [0, 0.69444, 0.12945, 0, 0.35555],
55250    "8217": [0, 0.69444, 0.12945, 0, 0.35555],
55251    "8220": [0, 0.69444, 0.16772, 0, 0.62055],
55252    "8221": [0, 0.69444, 0.07939, 0, 0.62055]
55253  },
55254  "Main-Italic": {
55255    "32": [0, 0, 0, 0, 0.25],
55256    "33": [0, 0.69444, 0.12417, 0, 0.30667],
55257    "34": [0, 0.69444, 0.06961, 0, 0.51444],
55258    "35": [0.19444, 0.69444, 0.06616, 0, 0.81777],
55259    "37": [0.05556, 0.75, 0.13639, 0, 0.81777],
55260    "38": [0, 0.69444, 0.09694, 0, 0.76666],
55261    "39": [0, 0.69444, 0.12417, 0, 0.30667],
55262    "40": [0.25, 0.75, 0.16194, 0, 0.40889],
55263    "41": [0.25, 0.75, 0.03694, 0, 0.40889],
55264    "42": [0, 0.75, 0.14917, 0, 0.51111],
55265    "43": [0.05667, 0.56167, 0.03694, 0, 0.76666],
55266    "44": [0.19444, 0.10556, 0, 0, 0.30667],
55267    "45": [0, 0.43056, 0.02826, 0, 0.35778],
55268    "46": [0, 0.10556, 0, 0, 0.30667],
55269    "47": [0.25, 0.75, 0.16194, 0, 0.51111],
55270    "48": [0, 0.64444, 0.13556, 0, 0.51111],
55271    "49": [0, 0.64444, 0.13556, 0, 0.51111],
55272    "50": [0, 0.64444, 0.13556, 0, 0.51111],
55273    "51": [0, 0.64444, 0.13556, 0, 0.51111],
55274    "52": [0.19444, 0.64444, 0.13556, 0, 0.51111],
55275    "53": [0, 0.64444, 0.13556, 0, 0.51111],
55276    "54": [0, 0.64444, 0.13556, 0, 0.51111],
55277    "55": [0.19444, 0.64444, 0.13556, 0, 0.51111],
55278    "56": [0, 0.64444, 0.13556, 0, 0.51111],
55279    "57": [0, 0.64444, 0.13556, 0, 0.51111],
55280    "58": [0, 0.43056, 0.0582, 0, 0.30667],
55281    "59": [0.19444, 0.43056, 0.0582, 0, 0.30667],
55282    "61": [-0.13313, 0.36687, 0.06616, 0, 0.76666],
55283    "63": [0, 0.69444, 0.1225, 0, 0.51111],
55284    "64": [0, 0.69444, 0.09597, 0, 0.76666],
55285    "65": [0, 0.68333, 0, 0, 0.74333],
55286    "66": [0, 0.68333, 0.10257, 0, 0.70389],
55287    "67": [0, 0.68333, 0.14528, 0, 0.71555],
55288    "68": [0, 0.68333, 0.09403, 0, 0.755],
55289    "69": [0, 0.68333, 0.12028, 0, 0.67833],
55290    "70": [0, 0.68333, 0.13305, 0, 0.65277],
55291    "71": [0, 0.68333, 0.08722, 0, 0.77361],
55292    "72": [0, 0.68333, 0.16389, 0, 0.74333],
55293    "73": [0, 0.68333, 0.15806, 0, 0.38555],
55294    "74": [0, 0.68333, 0.14028, 0, 0.525],
55295    "75": [0, 0.68333, 0.14528, 0, 0.76888],
55296    "76": [0, 0.68333, 0, 0, 0.62722],
55297    "77": [0, 0.68333, 0.16389, 0, 0.89666],
55298    "78": [0, 0.68333, 0.16389, 0, 0.74333],
55299    "79": [0, 0.68333, 0.09403, 0, 0.76666],
55300    "80": [0, 0.68333, 0.10257, 0, 0.67833],
55301    "81": [0.19444, 0.68333, 0.09403, 0, 0.76666],
55302    "82": [0, 0.68333, 0.03868, 0, 0.72944],
55303    "83": [0, 0.68333, 0.11972, 0, 0.56222],
55304    "84": [0, 0.68333, 0.13305, 0, 0.71555],
55305    "85": [0, 0.68333, 0.16389, 0, 0.74333],
55306    "86": [0, 0.68333, 0.18361, 0, 0.74333],
55307    "87": [0, 0.68333, 0.18361, 0, 0.99888],
55308    "88": [0, 0.68333, 0.15806, 0, 0.74333],
55309    "89": [0, 0.68333, 0.19383, 0, 0.74333],
55310    "90": [0, 0.68333, 0.14528, 0, 0.61333],
55311    "91": [0.25, 0.75, 0.1875, 0, 0.30667],
55312    "93": [0.25, 0.75, 0.10528, 0, 0.30667],
55313    "94": [0, 0.69444, 0.06646, 0, 0.51111],
55314    "95": [0.31, 0.12056, 0.09208, 0, 0.51111],
55315    "97": [0, 0.43056, 0.07671, 0, 0.51111],
55316    "98": [0, 0.69444, 0.06312, 0, 0.46],
55317    "99": [0, 0.43056, 0.05653, 0, 0.46],
55318    "100": [0, 0.69444, 0.10333, 0, 0.51111],
55319    "101": [0, 0.43056, 0.07514, 0, 0.46],
55320    "102": [0.19444, 0.69444, 0.21194, 0, 0.30667],
55321    "103": [0.19444, 0.43056, 0.08847, 0, 0.46],
55322    "104": [0, 0.69444, 0.07671, 0, 0.51111],
55323    "105": [0, 0.65536, 0.1019, 0, 0.30667],
55324    "106": [0.19444, 0.65536, 0.14467, 0, 0.30667],
55325    "107": [0, 0.69444, 0.10764, 0, 0.46],
55326    "108": [0, 0.69444, 0.10333, 0, 0.25555],
55327    "109": [0, 0.43056, 0.07671, 0, 0.81777],
55328    "110": [0, 0.43056, 0.07671, 0, 0.56222],
55329    "111": [0, 0.43056, 0.06312, 0, 0.51111],
55330    "112": [0.19444, 0.43056, 0.06312, 0, 0.51111],
55331    "113": [0.19444, 0.43056, 0.08847, 0, 0.46],
55332    "114": [0, 0.43056, 0.10764, 0, 0.42166],
55333    "115": [0, 0.43056, 0.08208, 0, 0.40889],
55334    "116": [0, 0.61508, 0.09486, 0, 0.33222],
55335    "117": [0, 0.43056, 0.07671, 0, 0.53666],
55336    "118": [0, 0.43056, 0.10764, 0, 0.46],
55337    "119": [0, 0.43056, 0.10764, 0, 0.66444],
55338    "120": [0, 0.43056, 0.12042, 0, 0.46389],
55339    "121": [0.19444, 0.43056, 0.08847, 0, 0.48555],
55340    "122": [0, 0.43056, 0.12292, 0, 0.40889],
55341    "126": [0.35, 0.31786, 0.11585, 0, 0.51111],
55342    "160": [0, 0, 0, 0, 0.25],
55343    "168": [0, 0.66786, 0.10474, 0, 0.51111],
55344    "176": [0, 0.69444, 0, 0, 0.83129],
55345    "184": [0.17014, 0, 0, 0, 0.46],
55346    "198": [0, 0.68333, 0.12028, 0, 0.88277],
55347    "216": [0.04861, 0.73194, 0.09403, 0, 0.76666],
55348    "223": [0.19444, 0.69444, 0.10514, 0, 0.53666],
55349    "230": [0, 0.43056, 0.07514, 0, 0.71555],
55350    "248": [0.09722, 0.52778, 0.09194, 0, 0.51111],
55351    "338": [0, 0.68333, 0.12028, 0, 0.98499],
55352    "339": [0, 0.43056, 0.07514, 0, 0.71555],
55353    "710": [0, 0.69444, 0.06646, 0, 0.51111],
55354    "711": [0, 0.62847, 0.08295, 0, 0.51111],
55355    "713": [0, 0.56167, 0.10333, 0, 0.51111],
55356    "714": [0, 0.69444, 0.09694, 0, 0.51111],
55357    "715": [0, 0.69444, 0, 0, 0.51111],
55358    "728": [0, 0.69444, 0.10806, 0, 0.51111],
55359    "729": [0, 0.66786, 0.11752, 0, 0.30667],
55360    "730": [0, 0.69444, 0, 0, 0.83129],
55361    "732": [0, 0.66786, 0.11585, 0, 0.51111],
55362    "733": [0, 0.69444, 0.1225, 0, 0.51111],
55363    "915": [0, 0.68333, 0.13305, 0, 0.62722],
55364    "916": [0, 0.68333, 0, 0, 0.81777],
55365    "920": [0, 0.68333, 0.09403, 0, 0.76666],
55366    "923": [0, 0.68333, 0, 0, 0.69222],
55367    "926": [0, 0.68333, 0.15294, 0, 0.66444],
55368    "928": [0, 0.68333, 0.16389, 0, 0.74333],
55369    "931": [0, 0.68333, 0.12028, 0, 0.71555],
55370    "933": [0, 0.68333, 0.11111, 0, 0.76666],
55371    "934": [0, 0.68333, 0.05986, 0, 0.71555],
55372    "936": [0, 0.68333, 0.11111, 0, 0.76666],
55373    "937": [0, 0.68333, 0.10257, 0, 0.71555],
55374    "8211": [0, 0.43056, 0.09208, 0, 0.51111],
55375    "8212": [0, 0.43056, 0.09208, 0, 1.02222],
55376    "8216": [0, 0.69444, 0.12417, 0, 0.30667],
55377    "8217": [0, 0.69444, 0.12417, 0, 0.30667],
55378    "8220": [0, 0.69444, 0.1685, 0, 0.51444],
55379    "8221": [0, 0.69444, 0.06961, 0, 0.51444],
55380    "8463": [0, 0.68889, 0, 0, 0.54028]
55381  },
55382  "Main-Regular": {
55383    "32": [0, 0, 0, 0, 0.25],
55384    "33": [0, 0.69444, 0, 0, 0.27778],
55385    "34": [0, 0.69444, 0, 0, 0.5],
55386    "35": [0.19444, 0.69444, 0, 0, 0.83334],
55387    "36": [0.05556, 0.75, 0, 0, 0.5],
55388    "37": [0.05556, 0.75, 0, 0, 0.83334],
55389    "38": [0, 0.69444, 0, 0, 0.77778],
55390    "39": [0, 0.69444, 0, 0, 0.27778],
55391    "40": [0.25, 0.75, 0, 0, 0.38889],
55392    "41": [0.25, 0.75, 0, 0, 0.38889],
55393    "42": [0, 0.75, 0, 0, 0.5],
55394    "43": [0.08333, 0.58333, 0, 0, 0.77778],
55395    "44": [0.19444, 0.10556, 0, 0, 0.27778],
55396    "45": [0, 0.43056, 0, 0, 0.33333],
55397    "46": [0, 0.10556, 0, 0, 0.27778],
55398    "47": [0.25, 0.75, 0, 0, 0.5],
55399    "48": [0, 0.64444, 0, 0, 0.5],
55400    "49": [0, 0.64444, 0, 0, 0.5],
55401    "50": [0, 0.64444, 0, 0, 0.5],
55402    "51": [0, 0.64444, 0, 0, 0.5],
55403    "52": [0, 0.64444, 0, 0, 0.5],
55404    "53": [0, 0.64444, 0, 0, 0.5],
55405    "54": [0, 0.64444, 0, 0, 0.5],
55406    "55": [0, 0.64444, 0, 0, 0.5],
55407    "56": [0, 0.64444, 0, 0, 0.5],
55408    "57": [0, 0.64444, 0, 0, 0.5],
55409    "58": [0, 0.43056, 0, 0, 0.27778],
55410    "59": [0.19444, 0.43056, 0, 0, 0.27778],
55411    "60": [0.0391, 0.5391, 0, 0, 0.77778],
55412    "61": [-0.13313, 0.36687, 0, 0, 0.77778],
55413    "62": [0.0391, 0.5391, 0, 0, 0.77778],
55414    "63": [0, 0.69444, 0, 0, 0.47222],
55415    "64": [0, 0.69444, 0, 0, 0.77778],
55416    "65": [0, 0.68333, 0, 0, 0.75],
55417    "66": [0, 0.68333, 0, 0, 0.70834],
55418    "67": [0, 0.68333, 0, 0, 0.72222],
55419    "68": [0, 0.68333, 0, 0, 0.76389],
55420    "69": [0, 0.68333, 0, 0, 0.68056],
55421    "70": [0, 0.68333, 0, 0, 0.65278],
55422    "71": [0, 0.68333, 0, 0, 0.78472],
55423    "72": [0, 0.68333, 0, 0, 0.75],
55424    "73": [0, 0.68333, 0, 0, 0.36111],
55425    "74": [0, 0.68333, 0, 0, 0.51389],
55426    "75": [0, 0.68333, 0, 0, 0.77778],
55427    "76": [0, 0.68333, 0, 0, 0.625],
55428    "77": [0, 0.68333, 0, 0, 0.91667],
55429    "78": [0, 0.68333, 0, 0, 0.75],
55430    "79": [0, 0.68333, 0, 0, 0.77778],
55431    "80": [0, 0.68333, 0, 0, 0.68056],
55432    "81": [0.19444, 0.68333, 0, 0, 0.77778],
55433    "82": [0, 0.68333, 0, 0, 0.73611],
55434    "83": [0, 0.68333, 0, 0, 0.55556],
55435    "84": [0, 0.68333, 0, 0, 0.72222],
55436    "85": [0, 0.68333, 0, 0, 0.75],
55437    "86": [0, 0.68333, 0.01389, 0, 0.75],
55438    "87": [0, 0.68333, 0.01389, 0, 1.02778],
55439    "88": [0, 0.68333, 0, 0, 0.75],
55440    "89": [0, 0.68333, 0.025, 0, 0.75],
55441    "90": [0, 0.68333, 0, 0, 0.61111],
55442    "91": [0.25, 0.75, 0, 0, 0.27778],
55443    "92": [0.25, 0.75, 0, 0, 0.5],
55444    "93": [0.25, 0.75, 0, 0, 0.27778],
55445    "94": [0, 0.69444, 0, 0, 0.5],
55446    "95": [0.31, 0.12056, 0.02778, 0, 0.5],
55447    "97": [0, 0.43056, 0, 0, 0.5],
55448    "98": [0, 0.69444, 0, 0, 0.55556],
55449    "99": [0, 0.43056, 0, 0, 0.44445],
55450    "100": [0, 0.69444, 0, 0, 0.55556],
55451    "101": [0, 0.43056, 0, 0, 0.44445],
55452    "102": [0, 0.69444, 0.07778, 0, 0.30556],
55453    "103": [0.19444, 0.43056, 0.01389, 0, 0.5],
55454    "104": [0, 0.69444, 0, 0, 0.55556],
55455    "105": [0, 0.66786, 0, 0, 0.27778],
55456    "106": [0.19444, 0.66786, 0, 0, 0.30556],
55457    "107": [0, 0.69444, 0, 0, 0.52778],
55458    "108": [0, 0.69444, 0, 0, 0.27778],
55459    "109": [0, 0.43056, 0, 0, 0.83334],
55460    "110": [0, 0.43056, 0, 0, 0.55556],
55461    "111": [0, 0.43056, 0, 0, 0.5],
55462    "112": [0.19444, 0.43056, 0, 0, 0.55556],
55463    "113": [0.19444, 0.43056, 0, 0, 0.52778],
55464    "114": [0, 0.43056, 0, 0, 0.39167],
55465    "115": [0, 0.43056, 0, 0, 0.39445],
55466    "116": [0, 0.61508, 0, 0, 0.38889],
55467    "117": [0, 0.43056, 0, 0, 0.55556],
55468    "118": [0, 0.43056, 0.01389, 0, 0.52778],
55469    "119": [0, 0.43056, 0.01389, 0, 0.72222],
55470    "120": [0, 0.43056, 0, 0, 0.52778],
55471    "121": [0.19444, 0.43056, 0.01389, 0, 0.52778],
55472    "122": [0, 0.43056, 0, 0, 0.44445],
55473    "123": [0.25, 0.75, 0, 0, 0.5],
55474    "124": [0.25, 0.75, 0, 0, 0.27778],
55475    "125": [0.25, 0.75, 0, 0, 0.5],
55476    "126": [0.35, 0.31786, 0, 0, 0.5],
55477    "160": [0, 0, 0, 0, 0.25],
55478    "163": [0, 0.69444, 0, 0, 0.76909],
55479    "167": [0.19444, 0.69444, 0, 0, 0.44445],
55480    "168": [0, 0.66786, 0, 0, 0.5],
55481    "172": [0, 0.43056, 0, 0, 0.66667],
55482    "176": [0, 0.69444, 0, 0, 0.75],
55483    "177": [0.08333, 0.58333, 0, 0, 0.77778],
55484    "182": [0.19444, 0.69444, 0, 0, 0.61111],
55485    "184": [0.17014, 0, 0, 0, 0.44445],
55486    "198": [0, 0.68333, 0, 0, 0.90278],
55487    "215": [0.08333, 0.58333, 0, 0, 0.77778],
55488    "216": [0.04861, 0.73194, 0, 0, 0.77778],
55489    "223": [0, 0.69444, 0, 0, 0.5],
55490    "230": [0, 0.43056, 0, 0, 0.72222],
55491    "247": [0.08333, 0.58333, 0, 0, 0.77778],
55492    "248": [0.09722, 0.52778, 0, 0, 0.5],
55493    "305": [0, 0.43056, 0, 0, 0.27778],
55494    "338": [0, 0.68333, 0, 0, 1.01389],
55495    "339": [0, 0.43056, 0, 0, 0.77778],
55496    "567": [0.19444, 0.43056, 0, 0, 0.30556],
55497    "710": [0, 0.69444, 0, 0, 0.5],
55498    "711": [0, 0.62847, 0, 0, 0.5],
55499    "713": [0, 0.56778, 0, 0, 0.5],
55500    "714": [0, 0.69444, 0, 0, 0.5],
55501    "715": [0, 0.69444, 0, 0, 0.5],
55502    "728": [0, 0.69444, 0, 0, 0.5],
55503    "729": [0, 0.66786, 0, 0, 0.27778],
55504    "730": [0, 0.69444, 0, 0, 0.75],
55505    "732": [0, 0.66786, 0, 0, 0.5],
55506    "733": [0, 0.69444, 0, 0, 0.5],
55507    "915": [0, 0.68333, 0, 0, 0.625],
55508    "916": [0, 0.68333, 0, 0, 0.83334],
55509    "920": [0, 0.68333, 0, 0, 0.77778],
55510    "923": [0, 0.68333, 0, 0, 0.69445],
55511    "926": [0, 0.68333, 0, 0, 0.66667],
55512    "928": [0, 0.68333, 0, 0, 0.75],
55513    "931": [0, 0.68333, 0, 0, 0.72222],
55514    "933": [0, 0.68333, 0, 0, 0.77778],
55515    "934": [0, 0.68333, 0, 0, 0.72222],
55516    "936": [0, 0.68333, 0, 0, 0.77778],
55517    "937": [0, 0.68333, 0, 0, 0.72222],
55518    "8211": [0, 0.43056, 0.02778, 0, 0.5],
55519    "8212": [0, 0.43056, 0.02778, 0, 1],
55520    "8216": [0, 0.69444, 0, 0, 0.27778],
55521    "8217": [0, 0.69444, 0, 0, 0.27778],
55522    "8220": [0, 0.69444, 0, 0, 0.5],
55523    "8221": [0, 0.69444, 0, 0, 0.5],
55524    "8224": [0.19444, 0.69444, 0, 0, 0.44445],
55525    "8225": [0.19444, 0.69444, 0, 0, 0.44445],
55526    "8230": [0, 0.123, 0, 0, 1.172],
55527    "8242": [0, 0.55556, 0, 0, 0.275],
55528    "8407": [0, 0.71444, 0.15382, 0, 0.5],
55529    "8463": [0, 0.68889, 0, 0, 0.54028],
55530    "8465": [0, 0.69444, 0, 0, 0.72222],
55531    "8467": [0, 0.69444, 0, 0.11111, 0.41667],
55532    "8472": [0.19444, 0.43056, 0, 0.11111, 0.63646],
55533    "8476": [0, 0.69444, 0, 0, 0.72222],
55534    "8501": [0, 0.69444, 0, 0, 0.61111],
55535    "8592": [-0.13313, 0.36687, 0, 0, 1],
55536    "8593": [0.19444, 0.69444, 0, 0, 0.5],
55537    "8594": [-0.13313, 0.36687, 0, 0, 1],
55538    "8595": [0.19444, 0.69444, 0, 0, 0.5],
55539    "8596": [-0.13313, 0.36687, 0, 0, 1],
55540    "8597": [0.25, 0.75, 0, 0, 0.5],
55541    "8598": [0.19444, 0.69444, 0, 0, 1],
55542    "8599": [0.19444, 0.69444, 0, 0, 1],
55543    "8600": [0.19444, 0.69444, 0, 0, 1],
55544    "8601": [0.19444, 0.69444, 0, 0, 1],
55545    "8614": [0.011, 0.511, 0, 0, 1],
55546    "8617": [0.011, 0.511, 0, 0, 1.126],
55547    "8618": [0.011, 0.511, 0, 0, 1.126],
55548    "8636": [-0.13313, 0.36687, 0, 0, 1],
55549    "8637": [-0.13313, 0.36687, 0, 0, 1],
55550    "8640": [-0.13313, 0.36687, 0, 0, 1],
55551    "8641": [-0.13313, 0.36687, 0, 0, 1],
55552    "8652": [0.011, 0.671, 0, 0, 1],
55553    "8656": [-0.13313, 0.36687, 0, 0, 1],
55554    "8657": [0.19444, 0.69444, 0, 0, 0.61111],
55555    "8658": [-0.13313, 0.36687, 0, 0, 1],
55556    "8659": [0.19444, 0.69444, 0, 0, 0.61111],
55557    "8660": [-0.13313, 0.36687, 0, 0, 1],
55558    "8661": [0.25, 0.75, 0, 0, 0.61111],
55559    "8704": [0, 0.69444, 0, 0, 0.55556],
55560    "8706": [0, 0.69444, 0.05556, 0.08334, 0.5309],
55561    "8707": [0, 0.69444, 0, 0, 0.55556],
55562    "8709": [0.05556, 0.75, 0, 0, 0.5],
55563    "8711": [0, 0.68333, 0, 0, 0.83334],
55564    "8712": [0.0391, 0.5391, 0, 0, 0.66667],
55565    "8715": [0.0391, 0.5391, 0, 0, 0.66667],
55566    "8722": [0.08333, 0.58333, 0, 0, 0.77778],
55567    "8723": [0.08333, 0.58333, 0, 0, 0.77778],
55568    "8725": [0.25, 0.75, 0, 0, 0.5],
55569    "8726": [0.25, 0.75, 0, 0, 0.5],
55570    "8727": [-0.03472, 0.46528, 0, 0, 0.5],
55571    "8728": [-0.05555, 0.44445, 0, 0, 0.5],
55572    "8729": [-0.05555, 0.44445, 0, 0, 0.5],
55573    "8730": [0.2, 0.8, 0, 0, 0.83334],
55574    "8733": [0, 0.43056, 0, 0, 0.77778],
55575    "8734": [0, 0.43056, 0, 0, 1],
55576    "8736": [0, 0.69224, 0, 0, 0.72222],
55577    "8739": [0.25, 0.75, 0, 0, 0.27778],
55578    "8741": [0.25, 0.75, 0, 0, 0.5],
55579    "8743": [0, 0.55556, 0, 0, 0.66667],
55580    "8744": [0, 0.55556, 0, 0, 0.66667],
55581    "8745": [0, 0.55556, 0, 0, 0.66667],
55582    "8746": [0, 0.55556, 0, 0, 0.66667],
55583    "8747": [0.19444, 0.69444, 0.11111, 0, 0.41667],
55584    "8764": [-0.13313, 0.36687, 0, 0, 0.77778],
55585    "8768": [0.19444, 0.69444, 0, 0, 0.27778],
55586    "8771": [-0.03625, 0.46375, 0, 0, 0.77778],
55587    "8773": [-0.022, 0.589, 0, 0, 0.778],
55588    "8776": [-0.01688, 0.48312, 0, 0, 0.77778],
55589    "8781": [-0.03625, 0.46375, 0, 0, 0.77778],
55590    "8784": [-0.133, 0.673, 0, 0, 0.778],
55591    "8801": [-0.03625, 0.46375, 0, 0, 0.77778],
55592    "8804": [0.13597, 0.63597, 0, 0, 0.77778],
55593    "8805": [0.13597, 0.63597, 0, 0, 0.77778],
55594    "8810": [0.0391, 0.5391, 0, 0, 1],
55595    "8811": [0.0391, 0.5391, 0, 0, 1],
55596    "8826": [0.0391, 0.5391, 0, 0, 0.77778],
55597    "8827": [0.0391, 0.5391, 0, 0, 0.77778],
55598    "8834": [0.0391, 0.5391, 0, 0, 0.77778],
55599    "8835": [0.0391, 0.5391, 0, 0, 0.77778],
55600    "8838": [0.13597, 0.63597, 0, 0, 0.77778],
55601    "8839": [0.13597, 0.63597, 0, 0, 0.77778],
55602    "8846": [0, 0.55556, 0, 0, 0.66667],
55603    "8849": [0.13597, 0.63597, 0, 0, 0.77778],
55604    "8850": [0.13597, 0.63597, 0, 0, 0.77778],
55605    "8851": [0, 0.55556, 0, 0, 0.66667],
55606    "8852": [0, 0.55556, 0, 0, 0.66667],
55607    "8853": [0.08333, 0.58333, 0, 0, 0.77778],
55608    "8854": [0.08333, 0.58333, 0, 0, 0.77778],
55609    "8855": [0.08333, 0.58333, 0, 0, 0.77778],
55610    "8856": [0.08333, 0.58333, 0, 0, 0.77778],
55611    "8857": [0.08333, 0.58333, 0, 0, 0.77778],
55612    "8866": [0, 0.69444, 0, 0, 0.61111],
55613    "8867": [0, 0.69444, 0, 0, 0.61111],
55614    "8868": [0, 0.69444, 0, 0, 0.77778],
55615    "8869": [0, 0.69444, 0, 0, 0.77778],
55616    "8872": [0.249, 0.75, 0, 0, 0.867],
55617    "8900": [-0.05555, 0.44445, 0, 0, 0.5],
55618    "8901": [-0.05555, 0.44445, 0, 0, 0.27778],
55619    "8902": [-0.03472, 0.46528, 0, 0, 0.5],
55620    "8904": [5e-3, 0.505, 0, 0, 0.9],
55621    "8942": [0.03, 0.903, 0, 0, 0.278],
55622    "8943": [-0.19, 0.313, 0, 0, 1.172],
55623    "8945": [-0.1, 0.823, 0, 0, 1.282],
55624    "8968": [0.25, 0.75, 0, 0, 0.44445],
55625    "8969": [0.25, 0.75, 0, 0, 0.44445],
55626    "8970": [0.25, 0.75, 0, 0, 0.44445],
55627    "8971": [0.25, 0.75, 0, 0, 0.44445],
55628    "8994": [-0.14236, 0.35764, 0, 0, 1],
55629    "8995": [-0.14236, 0.35764, 0, 0, 1],
55630    "9136": [0.244, 0.744, 0, 0, 0.412],
55631    "9137": [0.244, 0.745, 0, 0, 0.412],
55632    "9651": [0.19444, 0.69444, 0, 0, 0.88889],
55633    "9657": [-0.03472, 0.46528, 0, 0, 0.5],
55634    "9661": [0.19444, 0.69444, 0, 0, 0.88889],
55635    "9667": [-0.03472, 0.46528, 0, 0, 0.5],
55636    "9711": [0.19444, 0.69444, 0, 0, 1],
55637    "9824": [0.12963, 0.69444, 0, 0, 0.77778],
55638    "9825": [0.12963, 0.69444, 0, 0, 0.77778],
55639    "9826": [0.12963, 0.69444, 0, 0, 0.77778],
55640    "9827": [0.12963, 0.69444, 0, 0, 0.77778],
55641    "9837": [0, 0.75, 0, 0, 0.38889],
55642    "9838": [0.19444, 0.69444, 0, 0, 0.38889],
55643    "9839": [0.19444, 0.69444, 0, 0, 0.38889],
55644    "10216": [0.25, 0.75, 0, 0, 0.38889],
55645    "10217": [0.25, 0.75, 0, 0, 0.38889],
55646    "10222": [0.244, 0.744, 0, 0, 0.412],
55647    "10223": [0.244, 0.745, 0, 0, 0.412],
55648    "10229": [0.011, 0.511, 0, 0, 1.609],
55649    "10230": [0.011, 0.511, 0, 0, 1.638],
55650    "10231": [0.011, 0.511, 0, 0, 1.859],
55651    "10232": [0.024, 0.525, 0, 0, 1.609],
55652    "10233": [0.024, 0.525, 0, 0, 1.638],
55653    "10234": [0.024, 0.525, 0, 0, 1.858],
55654    "10236": [0.011, 0.511, 0, 0, 1.638],
55655    "10815": [0, 0.68333, 0, 0, 0.75],
55656    "10927": [0.13597, 0.63597, 0, 0, 0.77778],
55657    "10928": [0.13597, 0.63597, 0, 0, 0.77778],
55658    "57376": [0.19444, 0.69444, 0, 0, 0]
55659  },
55660  "Math-BoldItalic": {
55661    "32": [0, 0, 0, 0, 0.25],
55662    "48": [0, 0.44444, 0, 0, 0.575],
55663    "49": [0, 0.44444, 0, 0, 0.575],
55664    "50": [0, 0.44444, 0, 0, 0.575],
55665    "51": [0.19444, 0.44444, 0, 0, 0.575],
55666    "52": [0.19444, 0.44444, 0, 0, 0.575],
55667    "53": [0.19444, 0.44444, 0, 0, 0.575],
55668    "54": [0, 0.64444, 0, 0, 0.575],
55669    "55": [0.19444, 0.44444, 0, 0, 0.575],
55670    "56": [0, 0.64444, 0, 0, 0.575],
55671    "57": [0.19444, 0.44444, 0, 0, 0.575],
55672    "65": [0, 0.68611, 0, 0, 0.86944],
55673    "66": [0, 0.68611, 0.04835, 0, 0.8664],
55674    "67": [0, 0.68611, 0.06979, 0, 0.81694],
55675    "68": [0, 0.68611, 0.03194, 0, 0.93812],
55676    "69": [0, 0.68611, 0.05451, 0, 0.81007],
55677    "70": [0, 0.68611, 0.15972, 0, 0.68889],
55678    "71": [0, 0.68611, 0, 0, 0.88673],
55679    "72": [0, 0.68611, 0.08229, 0, 0.98229],
55680    "73": [0, 0.68611, 0.07778, 0, 0.51111],
55681    "74": [0, 0.68611, 0.10069, 0, 0.63125],
55682    "75": [0, 0.68611, 0.06979, 0, 0.97118],
55683    "76": [0, 0.68611, 0, 0, 0.75555],
55684    "77": [0, 0.68611, 0.11424, 0, 1.14201],
55685    "78": [0, 0.68611, 0.11424, 0, 0.95034],
55686    "79": [0, 0.68611, 0.03194, 0, 0.83666],
55687    "80": [0, 0.68611, 0.15972, 0, 0.72309],
55688    "81": [0.19444, 0.68611, 0, 0, 0.86861],
55689    "82": [0, 0.68611, 421e-5, 0, 0.87235],
55690    "83": [0, 0.68611, 0.05382, 0, 0.69271],
55691    "84": [0, 0.68611, 0.15972, 0, 0.63663],
55692    "85": [0, 0.68611, 0.11424, 0, 0.80027],
55693    "86": [0, 0.68611, 0.25555, 0, 0.67778],
55694    "87": [0, 0.68611, 0.15972, 0, 1.09305],
55695    "88": [0, 0.68611, 0.07778, 0, 0.94722],
55696    "89": [0, 0.68611, 0.25555, 0, 0.67458],
55697    "90": [0, 0.68611, 0.06979, 0, 0.77257],
55698    "97": [0, 0.44444, 0, 0, 0.63287],
55699    "98": [0, 0.69444, 0, 0, 0.52083],
55700    "99": [0, 0.44444, 0, 0, 0.51342],
55701    "100": [0, 0.69444, 0, 0, 0.60972],
55702    "101": [0, 0.44444, 0, 0, 0.55361],
55703    "102": [0.19444, 0.69444, 0.11042, 0, 0.56806],
55704    "103": [0.19444, 0.44444, 0.03704, 0, 0.5449],
55705    "104": [0, 0.69444, 0, 0, 0.66759],
55706    "105": [0, 0.69326, 0, 0, 0.4048],
55707    "106": [0.19444, 0.69326, 0.0622, 0, 0.47083],
55708    "107": [0, 0.69444, 0.01852, 0, 0.6037],
55709    "108": [0, 0.69444, 88e-4, 0, 0.34815],
55710    "109": [0, 0.44444, 0, 0, 1.0324],
55711    "110": [0, 0.44444, 0, 0, 0.71296],
55712    "111": [0, 0.44444, 0, 0, 0.58472],
55713    "112": [0.19444, 0.44444, 0, 0, 0.60092],
55714    "113": [0.19444, 0.44444, 0.03704, 0, 0.54213],
55715    "114": [0, 0.44444, 0.03194, 0, 0.5287],
55716    "115": [0, 0.44444, 0, 0, 0.53125],
55717    "116": [0, 0.63492, 0, 0, 0.41528],
55718    "117": [0, 0.44444, 0, 0, 0.68102],
55719    "118": [0, 0.44444, 0.03704, 0, 0.56666],
55720    "119": [0, 0.44444, 0.02778, 0, 0.83148],
55721    "120": [0, 0.44444, 0, 0, 0.65903],
55722    "121": [0.19444, 0.44444, 0.03704, 0, 0.59028],
55723    "122": [0, 0.44444, 0.04213, 0, 0.55509],
55724    "160": [0, 0, 0, 0, 0.25],
55725    "915": [0, 0.68611, 0.15972, 0, 0.65694],
55726    "916": [0, 0.68611, 0, 0, 0.95833],
55727    "920": [0, 0.68611, 0.03194, 0, 0.86722],
55728    "923": [0, 0.68611, 0, 0, 0.80555],
55729    "926": [0, 0.68611, 0.07458, 0, 0.84125],
55730    "928": [0, 0.68611, 0.08229, 0, 0.98229],
55731    "931": [0, 0.68611, 0.05451, 0, 0.88507],
55732    "933": [0, 0.68611, 0.15972, 0, 0.67083],
55733    "934": [0, 0.68611, 0, 0, 0.76666],
55734    "936": [0, 0.68611, 0.11653, 0, 0.71402],
55735    "937": [0, 0.68611, 0.04835, 0, 0.8789],
55736    "945": [0, 0.44444, 0, 0, 0.76064],
55737    "946": [0.19444, 0.69444, 0.03403, 0, 0.65972],
55738    "947": [0.19444, 0.44444, 0.06389, 0, 0.59003],
55739    "948": [0, 0.69444, 0.03819, 0, 0.52222],
55740    "949": [0, 0.44444, 0, 0, 0.52882],
55741    "950": [0.19444, 0.69444, 0.06215, 0, 0.50833],
55742    "951": [0.19444, 0.44444, 0.03704, 0, 0.6],
55743    "952": [0, 0.69444, 0.03194, 0, 0.5618],
55744    "953": [0, 0.44444, 0, 0, 0.41204],
55745    "954": [0, 0.44444, 0, 0, 0.66759],
55746    "955": [0, 0.69444, 0, 0, 0.67083],
55747    "956": [0.19444, 0.44444, 0, 0, 0.70787],
55748    "957": [0, 0.44444, 0.06898, 0, 0.57685],
55749    "958": [0.19444, 0.69444, 0.03021, 0, 0.50833],
55750    "959": [0, 0.44444, 0, 0, 0.58472],
55751    "960": [0, 0.44444, 0.03704, 0, 0.68241],
55752    "961": [0.19444, 0.44444, 0, 0, 0.6118],
55753    "962": [0.09722, 0.44444, 0.07917, 0, 0.42361],
55754    "963": [0, 0.44444, 0.03704, 0, 0.68588],
55755    "964": [0, 0.44444, 0.13472, 0, 0.52083],
55756    "965": [0, 0.44444, 0.03704, 0, 0.63055],
55757    "966": [0.19444, 0.44444, 0, 0, 0.74722],
55758    "967": [0.19444, 0.44444, 0, 0, 0.71805],
55759    "968": [0.19444, 0.69444, 0.03704, 0, 0.75833],
55760    "969": [0, 0.44444, 0.03704, 0, 0.71782],
55761    "977": [0, 0.69444, 0, 0, 0.69155],
55762    "981": [0.19444, 0.69444, 0, 0, 0.7125],
55763    "982": [0, 0.44444, 0.03194, 0, 0.975],
55764    "1009": [0.19444, 0.44444, 0, 0, 0.6118],
55765    "1013": [0, 0.44444, 0, 0, 0.48333],
55766    "57649": [0, 0.44444, 0, 0, 0.39352],
55767    "57911": [0.19444, 0.44444, 0, 0, 0.43889]
55768  },
55769  "Math-Italic": {
55770    "32": [0, 0, 0, 0, 0.25],
55771    "48": [0, 0.43056, 0, 0, 0.5],
55772    "49": [0, 0.43056, 0, 0, 0.5],
55773    "50": [0, 0.43056, 0, 0, 0.5],
55774    "51": [0.19444, 0.43056, 0, 0, 0.5],
55775    "52": [0.19444, 0.43056, 0, 0, 0.5],
55776    "53": [0.19444, 0.43056, 0, 0, 0.5],
55777    "54": [0, 0.64444, 0, 0, 0.5],
55778    "55": [0.19444, 0.43056, 0, 0, 0.5],
55779    "56": [0, 0.64444, 0, 0, 0.5],
55780    "57": [0.19444, 0.43056, 0, 0, 0.5],
55781    "65": [0, 0.68333, 0, 0.13889, 0.75],
55782    "66": [0, 0.68333, 0.05017, 0.08334, 0.75851],
55783    "67": [0, 0.68333, 0.07153, 0.08334, 0.71472],
55784    "68": [0, 0.68333, 0.02778, 0.05556, 0.82792],
55785    "69": [0, 0.68333, 0.05764, 0.08334, 0.7382],
55786    "70": [0, 0.68333, 0.13889, 0.08334, 0.64306],
55787    "71": [0, 0.68333, 0, 0.08334, 0.78625],
55788    "72": [0, 0.68333, 0.08125, 0.05556, 0.83125],
55789    "73": [0, 0.68333, 0.07847, 0.11111, 0.43958],
55790    "74": [0, 0.68333, 0.09618, 0.16667, 0.55451],
55791    "75": [0, 0.68333, 0.07153, 0.05556, 0.84931],
55792    "76": [0, 0.68333, 0, 0.02778, 0.68056],
55793    "77": [0, 0.68333, 0.10903, 0.08334, 0.97014],
55794    "78": [0, 0.68333, 0.10903, 0.08334, 0.80347],
55795    "79": [0, 0.68333, 0.02778, 0.08334, 0.76278],
55796    "80": [0, 0.68333, 0.13889, 0.08334, 0.64201],
55797    "81": [0.19444, 0.68333, 0, 0.08334, 0.79056],
55798    "82": [0, 0.68333, 773e-5, 0.08334, 0.75929],
55799    "83": [0, 0.68333, 0.05764, 0.08334, 0.6132],
55800    "84": [0, 0.68333, 0.13889, 0.08334, 0.58438],
55801    "85": [0, 0.68333, 0.10903, 0.02778, 0.68278],
55802    "86": [0, 0.68333, 0.22222, 0, 0.58333],
55803    "87": [0, 0.68333, 0.13889, 0, 0.94445],
55804    "88": [0, 0.68333, 0.07847, 0.08334, 0.82847],
55805    "89": [0, 0.68333, 0.22222, 0, 0.58056],
55806    "90": [0, 0.68333, 0.07153, 0.08334, 0.68264],
55807    "97": [0, 0.43056, 0, 0, 0.52859],
55808    "98": [0, 0.69444, 0, 0, 0.42917],
55809    "99": [0, 0.43056, 0, 0.05556, 0.43276],
55810    "100": [0, 0.69444, 0, 0.16667, 0.52049],
55811    "101": [0, 0.43056, 0, 0.05556, 0.46563],
55812    "102": [0.19444, 0.69444, 0.10764, 0.16667, 0.48959],
55813    "103": [0.19444, 0.43056, 0.03588, 0.02778, 0.47697],
55814    "104": [0, 0.69444, 0, 0, 0.57616],
55815    "105": [0, 0.65952, 0, 0, 0.34451],
55816    "106": [0.19444, 0.65952, 0.05724, 0, 0.41181],
55817    "107": [0, 0.69444, 0.03148, 0, 0.5206],
55818    "108": [0, 0.69444, 0.01968, 0.08334, 0.29838],
55819    "109": [0, 0.43056, 0, 0, 0.87801],
55820    "110": [0, 0.43056, 0, 0, 0.60023],
55821    "111": [0, 0.43056, 0, 0.05556, 0.48472],
55822    "112": [0.19444, 0.43056, 0, 0.08334, 0.50313],
55823    "113": [0.19444, 0.43056, 0.03588, 0.08334, 0.44641],
55824    "114": [0, 0.43056, 0.02778, 0.05556, 0.45116],
55825    "115": [0, 0.43056, 0, 0.05556, 0.46875],
55826    "116": [0, 0.61508, 0, 0.08334, 0.36111],
55827    "117": [0, 0.43056, 0, 0.02778, 0.57246],
55828    "118": [0, 0.43056, 0.03588, 0.02778, 0.48472],
55829    "119": [0, 0.43056, 0.02691, 0.08334, 0.71592],
55830    "120": [0, 0.43056, 0, 0.02778, 0.57153],
55831    "121": [0.19444, 0.43056, 0.03588, 0.05556, 0.49028],
55832    "122": [0, 0.43056, 0.04398, 0.05556, 0.46505],
55833    "160": [0, 0, 0, 0, 0.25],
55834    "915": [0, 0.68333, 0.13889, 0.08334, 0.61528],
55835    "916": [0, 0.68333, 0, 0.16667, 0.83334],
55836    "920": [0, 0.68333, 0.02778, 0.08334, 0.76278],
55837    "923": [0, 0.68333, 0, 0.16667, 0.69445],
55838    "926": [0, 0.68333, 0.07569, 0.08334, 0.74236],
55839    "928": [0, 0.68333, 0.08125, 0.05556, 0.83125],
55840    "931": [0, 0.68333, 0.05764, 0.08334, 0.77986],
55841    "933": [0, 0.68333, 0.13889, 0.05556, 0.58333],
55842    "934": [0, 0.68333, 0, 0.08334, 0.66667],
55843    "936": [0, 0.68333, 0.11, 0.05556, 0.61222],
55844    "937": [0, 0.68333, 0.05017, 0.08334, 0.7724],
55845    "945": [0, 0.43056, 37e-4, 0.02778, 0.6397],
55846    "946": [0.19444, 0.69444, 0.05278, 0.08334, 0.56563],
55847    "947": [0.19444, 0.43056, 0.05556, 0, 0.51773],
55848    "948": [0, 0.69444, 0.03785, 0.05556, 0.44444],
55849    "949": [0, 0.43056, 0, 0.08334, 0.46632],
55850    "950": [0.19444, 0.69444, 0.07378, 0.08334, 0.4375],
55851    "951": [0.19444, 0.43056, 0.03588, 0.05556, 0.49653],
55852    "952": [0, 0.69444, 0.02778, 0.08334, 0.46944],
55853    "953": [0, 0.43056, 0, 0.05556, 0.35394],
55854    "954": [0, 0.43056, 0, 0, 0.57616],
55855    "955": [0, 0.69444, 0, 0, 0.58334],
55856    "956": [0.19444, 0.43056, 0, 0.02778, 0.60255],
55857    "957": [0, 0.43056, 0.06366, 0.02778, 0.49398],
55858    "958": [0.19444, 0.69444, 0.04601, 0.11111, 0.4375],
55859    "959": [0, 0.43056, 0, 0.05556, 0.48472],
55860    "960": [0, 0.43056, 0.03588, 0, 0.57003],
55861    "961": [0.19444, 0.43056, 0, 0.08334, 0.51702],
55862    "962": [0.09722, 0.43056, 0.07986, 0.08334, 0.36285],
55863    "963": [0, 0.43056, 0.03588, 0, 0.57141],
55864    "964": [0, 0.43056, 0.1132, 0.02778, 0.43715],
55865    "965": [0, 0.43056, 0.03588, 0.02778, 0.54028],
55866    "966": [0.19444, 0.43056, 0, 0.08334, 0.65417],
55867    "967": [0.19444, 0.43056, 0, 0.05556, 0.62569],
55868    "968": [0.19444, 0.69444, 0.03588, 0.11111, 0.65139],
55869    "969": [0, 0.43056, 0.03588, 0, 0.62245],
55870    "977": [0, 0.69444, 0, 0.08334, 0.59144],
55871    "981": [0.19444, 0.69444, 0, 0.08334, 0.59583],
55872    "982": [0, 0.43056, 0.02778, 0, 0.82813],
55873    "1009": [0.19444, 0.43056, 0, 0.08334, 0.51702],
55874    "1013": [0, 0.43056, 0, 0.05556, 0.4059],
55875    "57649": [0, 0.43056, 0, 0.02778, 0.32246],
55876    "57911": [0.19444, 0.43056, 0, 0.08334, 0.38403]
55877  },
55878  "SansSerif-Bold": {
55879    "32": [0, 0, 0, 0, 0.25],
55880    "33": [0, 0.69444, 0, 0, 0.36667],
55881    "34": [0, 0.69444, 0, 0, 0.55834],
55882    "35": [0.19444, 0.69444, 0, 0, 0.91667],
55883    "36": [0.05556, 0.75, 0, 0, 0.55],
55884    "37": [0.05556, 0.75, 0, 0, 1.02912],
55885    "38": [0, 0.69444, 0, 0, 0.83056],
55886    "39": [0, 0.69444, 0, 0, 0.30556],
55887    "40": [0.25, 0.75, 0, 0, 0.42778],
55888    "41": [0.25, 0.75, 0, 0, 0.42778],
55889    "42": [0, 0.75, 0, 0, 0.55],
55890    "43": [0.11667, 0.61667, 0, 0, 0.85556],
55891    "44": [0.10556, 0.13056, 0, 0, 0.30556],
55892    "45": [0, 0.45833, 0, 0, 0.36667],
55893    "46": [0, 0.13056, 0, 0, 0.30556],
55894    "47": [0.25, 0.75, 0, 0, 0.55],
55895    "48": [0, 0.69444, 0, 0, 0.55],
55896    "49": [0, 0.69444, 0, 0, 0.55],
55897    "50": [0, 0.69444, 0, 0, 0.55],
55898    "51": [0, 0.69444, 0, 0, 0.55],
55899    "52": [0, 0.69444, 0, 0, 0.55],
55900    "53": [0, 0.69444, 0, 0, 0.55],
55901    "54": [0, 0.69444, 0, 0, 0.55],
55902    "55": [0, 0.69444, 0, 0, 0.55],
55903    "56": [0, 0.69444, 0, 0, 0.55],
55904    "57": [0, 0.69444, 0, 0, 0.55],
55905    "58": [0, 0.45833, 0, 0, 0.30556],
55906    "59": [0.10556, 0.45833, 0, 0, 0.30556],
55907    "61": [-0.09375, 0.40625, 0, 0, 0.85556],
55908    "63": [0, 0.69444, 0, 0, 0.51945],
55909    "64": [0, 0.69444, 0, 0, 0.73334],
55910    "65": [0, 0.69444, 0, 0, 0.73334],
55911    "66": [0, 0.69444, 0, 0, 0.73334],
55912    "67": [0, 0.69444, 0, 0, 0.70278],
55913    "68": [0, 0.69444, 0, 0, 0.79445],
55914    "69": [0, 0.69444, 0, 0, 0.64167],
55915    "70": [0, 0.69444, 0, 0, 0.61111],
55916    "71": [0, 0.69444, 0, 0, 0.73334],
55917    "72": [0, 0.69444, 0, 0, 0.79445],
55918    "73": [0, 0.69444, 0, 0, 0.33056],
55919    "74": [0, 0.69444, 0, 0, 0.51945],
55920    "75": [0, 0.69444, 0, 0, 0.76389],
55921    "76": [0, 0.69444, 0, 0, 0.58056],
55922    "77": [0, 0.69444, 0, 0, 0.97778],
55923    "78": [0, 0.69444, 0, 0, 0.79445],
55924    "79": [0, 0.69444, 0, 0, 0.79445],
55925    "80": [0, 0.69444, 0, 0, 0.70278],
55926    "81": [0.10556, 0.69444, 0, 0, 0.79445],
55927    "82": [0, 0.69444, 0, 0, 0.70278],
55928    "83": [0, 0.69444, 0, 0, 0.61111],
55929    "84": [0, 0.69444, 0, 0, 0.73334],
55930    "85": [0, 0.69444, 0, 0, 0.76389],
55931    "86": [0, 0.69444, 0.01528, 0, 0.73334],
55932    "87": [0, 0.69444, 0.01528, 0, 1.03889],
55933    "88": [0, 0.69444, 0, 0, 0.73334],
55934    "89": [0, 0.69444, 0.0275, 0, 0.73334],
55935    "90": [0, 0.69444, 0, 0, 0.67223],
55936    "91": [0.25, 0.75, 0, 0, 0.34306],
55937    "93": [0.25, 0.75, 0, 0, 0.34306],
55938    "94": [0, 0.69444, 0, 0, 0.55],
55939    "95": [0.35, 0.10833, 0.03056, 0, 0.55],
55940    "97": [0, 0.45833, 0, 0, 0.525],
55941    "98": [0, 0.69444, 0, 0, 0.56111],
55942    "99": [0, 0.45833, 0, 0, 0.48889],
55943    "100": [0, 0.69444, 0, 0, 0.56111],
55944    "101": [0, 0.45833, 0, 0, 0.51111],
55945    "102": [0, 0.69444, 0.07639, 0, 0.33611],
55946    "103": [0.19444, 0.45833, 0.01528, 0, 0.55],
55947    "104": [0, 0.69444, 0, 0, 0.56111],
55948    "105": [0, 0.69444, 0, 0, 0.25556],
55949    "106": [0.19444, 0.69444, 0, 0, 0.28611],
55950    "107": [0, 0.69444, 0, 0, 0.53056],
55951    "108": [0, 0.69444, 0, 0, 0.25556],
55952    "109": [0, 0.45833, 0, 0, 0.86667],
55953    "110": [0, 0.45833, 0, 0, 0.56111],
55954    "111": [0, 0.45833, 0, 0, 0.55],
55955    "112": [0.19444, 0.45833, 0, 0, 0.56111],
55956    "113": [0.19444, 0.45833, 0, 0, 0.56111],
55957    "114": [0, 0.45833, 0.01528, 0, 0.37222],
55958    "115": [0, 0.45833, 0, 0, 0.42167],
55959    "116": [0, 0.58929, 0, 0, 0.40417],
55960    "117": [0, 0.45833, 0, 0, 0.56111],
55961    "118": [0, 0.45833, 0.01528, 0, 0.5],
55962    "119": [0, 0.45833, 0.01528, 0, 0.74445],
55963    "120": [0, 0.45833, 0, 0, 0.5],
55964    "121": [0.19444, 0.45833, 0.01528, 0, 0.5],
55965    "122": [0, 0.45833, 0, 0, 0.47639],
55966    "126": [0.35, 0.34444, 0, 0, 0.55],
55967    "160": [0, 0, 0, 0, 0.25],
55968    "168": [0, 0.69444, 0, 0, 0.55],
55969    "176": [0, 0.69444, 0, 0, 0.73334],
55970    "180": [0, 0.69444, 0, 0, 0.55],
55971    "184": [0.17014, 0, 0, 0, 0.48889],
55972    "305": [0, 0.45833, 0, 0, 0.25556],
55973    "567": [0.19444, 0.45833, 0, 0, 0.28611],
55974    "710": [0, 0.69444, 0, 0, 0.55],
55975    "711": [0, 0.63542, 0, 0, 0.55],
55976    "713": [0, 0.63778, 0, 0, 0.55],
55977    "728": [0, 0.69444, 0, 0, 0.55],
55978    "729": [0, 0.69444, 0, 0, 0.30556],
55979    "730": [0, 0.69444, 0, 0, 0.73334],
55980    "732": [0, 0.69444, 0, 0, 0.55],
55981    "733": [0, 0.69444, 0, 0, 0.55],
55982    "915": [0, 0.69444, 0, 0, 0.58056],
55983    "916": [0, 0.69444, 0, 0, 0.91667],
55984    "920": [0, 0.69444, 0, 0, 0.85556],
55985    "923": [0, 0.69444, 0, 0, 0.67223],
55986    "926": [0, 0.69444, 0, 0, 0.73334],
55987    "928": [0, 0.69444, 0, 0, 0.79445],
55988    "931": [0, 0.69444, 0, 0, 0.79445],
55989    "933": [0, 0.69444, 0, 0, 0.85556],
55990    "934": [0, 0.69444, 0, 0, 0.79445],
55991    "936": [0, 0.69444, 0, 0, 0.85556],
55992    "937": [0, 0.69444, 0, 0, 0.79445],
55993    "8211": [0, 0.45833, 0.03056, 0, 0.55],
55994    "8212": [0, 0.45833, 0.03056, 0, 1.10001],
55995    "8216": [0, 0.69444, 0, 0, 0.30556],
55996    "8217": [0, 0.69444, 0, 0, 0.30556],
55997    "8220": [0, 0.69444, 0, 0, 0.55834],
55998    "8221": [0, 0.69444, 0, 0, 0.55834]
55999  },
56000  "SansSerif-Italic": {
56001    "32": [0, 0, 0, 0, 0.25],
56002    "33": [0, 0.69444, 0.05733, 0, 0.31945],
56003    "34": [0, 0.69444, 316e-5, 0, 0.5],
56004    "35": [0.19444, 0.69444, 0.05087, 0, 0.83334],
56005    "36": [0.05556, 0.75, 0.11156, 0, 0.5],
56006    "37": [0.05556, 0.75, 0.03126, 0, 0.83334],
56007    "38": [0, 0.69444, 0.03058, 0, 0.75834],
56008    "39": [0, 0.69444, 0.07816, 0, 0.27778],
56009    "40": [0.25, 0.75, 0.13164, 0, 0.38889],
56010    "41": [0.25, 0.75, 0.02536, 0, 0.38889],
56011    "42": [0, 0.75, 0.11775, 0, 0.5],
56012    "43": [0.08333, 0.58333, 0.02536, 0, 0.77778],
56013    "44": [0.125, 0.08333, 0, 0, 0.27778],
56014    "45": [0, 0.44444, 0.01946, 0, 0.33333],
56015    "46": [0, 0.08333, 0, 0, 0.27778],
56016    "47": [0.25, 0.75, 0.13164, 0, 0.5],
56017    "48": [0, 0.65556, 0.11156, 0, 0.5],
56018    "49": [0, 0.65556, 0.11156, 0, 0.5],
56019    "50": [0, 0.65556, 0.11156, 0, 0.5],
56020    "51": [0, 0.65556, 0.11156, 0, 0.5],
56021    "52": [0, 0.65556, 0.11156, 0, 0.5],
56022    "53": [0, 0.65556, 0.11156, 0, 0.5],
56023    "54": [0, 0.65556, 0.11156, 0, 0.5],
56024    "55": [0, 0.65556, 0.11156, 0, 0.5],
56025    "56": [0, 0.65556, 0.11156, 0, 0.5],
56026    "57": [0, 0.65556, 0.11156, 0, 0.5],
56027    "58": [0, 0.44444, 0.02502, 0, 0.27778],
56028    "59": [0.125, 0.44444, 0.02502, 0, 0.27778],
56029    "61": [-0.13, 0.37, 0.05087, 0, 0.77778],
56030    "63": [0, 0.69444, 0.11809, 0, 0.47222],
56031    "64": [0, 0.69444, 0.07555, 0, 0.66667],
56032    "65": [0, 0.69444, 0, 0, 0.66667],
56033    "66": [0, 0.69444, 0.08293, 0, 0.66667],
56034    "67": [0, 0.69444, 0.11983, 0, 0.63889],
56035    "68": [0, 0.69444, 0.07555, 0, 0.72223],
56036    "69": [0, 0.69444, 0.11983, 0, 0.59722],
56037    "70": [0, 0.69444, 0.13372, 0, 0.56945],
56038    "71": [0, 0.69444, 0.11983, 0, 0.66667],
56039    "72": [0, 0.69444, 0.08094, 0, 0.70834],
56040    "73": [0, 0.69444, 0.13372, 0, 0.27778],
56041    "74": [0, 0.69444, 0.08094, 0, 0.47222],
56042    "75": [0, 0.69444, 0.11983, 0, 0.69445],
56043    "76": [0, 0.69444, 0, 0, 0.54167],
56044    "77": [0, 0.69444, 0.08094, 0, 0.875],
56045    "78": [0, 0.69444, 0.08094, 0, 0.70834],
56046    "79": [0, 0.69444, 0.07555, 0, 0.73611],
56047    "80": [0, 0.69444, 0.08293, 0, 0.63889],
56048    "81": [0.125, 0.69444, 0.07555, 0, 0.73611],
56049    "82": [0, 0.69444, 0.08293, 0, 0.64584],
56050    "83": [0, 0.69444, 0.09205, 0, 0.55556],
56051    "84": [0, 0.69444, 0.13372, 0, 0.68056],
56052    "85": [0, 0.69444, 0.08094, 0, 0.6875],
56053    "86": [0, 0.69444, 0.1615, 0, 0.66667],
56054    "87": [0, 0.69444, 0.1615, 0, 0.94445],
56055    "88": [0, 0.69444, 0.13372, 0, 0.66667],
56056    "89": [0, 0.69444, 0.17261, 0, 0.66667],
56057    "90": [0, 0.69444, 0.11983, 0, 0.61111],
56058    "91": [0.25, 0.75, 0.15942, 0, 0.28889],
56059    "93": [0.25, 0.75, 0.08719, 0, 0.28889],
56060    "94": [0, 0.69444, 0.0799, 0, 0.5],
56061    "95": [0.35, 0.09444, 0.08616, 0, 0.5],
56062    "97": [0, 0.44444, 981e-5, 0, 0.48056],
56063    "98": [0, 0.69444, 0.03057, 0, 0.51667],
56064    "99": [0, 0.44444, 0.08336, 0, 0.44445],
56065    "100": [0, 0.69444, 0.09483, 0, 0.51667],
56066    "101": [0, 0.44444, 0.06778, 0, 0.44445],
56067    "102": [0, 0.69444, 0.21705, 0, 0.30556],
56068    "103": [0.19444, 0.44444, 0.10836, 0, 0.5],
56069    "104": [0, 0.69444, 0.01778, 0, 0.51667],
56070    "105": [0, 0.67937, 0.09718, 0, 0.23889],
56071    "106": [0.19444, 0.67937, 0.09162, 0, 0.26667],
56072    "107": [0, 0.69444, 0.08336, 0, 0.48889],
56073    "108": [0, 0.69444, 0.09483, 0, 0.23889],
56074    "109": [0, 0.44444, 0.01778, 0, 0.79445],
56075    "110": [0, 0.44444, 0.01778, 0, 0.51667],
56076    "111": [0, 0.44444, 0.06613, 0, 0.5],
56077    "112": [0.19444, 0.44444, 0.0389, 0, 0.51667],
56078    "113": [0.19444, 0.44444, 0.04169, 0, 0.51667],
56079    "114": [0, 0.44444, 0.10836, 0, 0.34167],
56080    "115": [0, 0.44444, 0.0778, 0, 0.38333],
56081    "116": [0, 0.57143, 0.07225, 0, 0.36111],
56082    "117": [0, 0.44444, 0.04169, 0, 0.51667],
56083    "118": [0, 0.44444, 0.10836, 0, 0.46111],
56084    "119": [0, 0.44444, 0.10836, 0, 0.68334],
56085    "120": [0, 0.44444, 0.09169, 0, 0.46111],
56086    "121": [0.19444, 0.44444, 0.10836, 0, 0.46111],
56087    "122": [0, 0.44444, 0.08752, 0, 0.43472],
56088    "126": [0.35, 0.32659, 0.08826, 0, 0.5],
56089    "160": [0, 0, 0, 0, 0.25],
56090    "168": [0, 0.67937, 0.06385, 0, 0.5],
56091    "176": [0, 0.69444, 0, 0, 0.73752],
56092    "184": [0.17014, 0, 0, 0, 0.44445],
56093    "305": [0, 0.44444, 0.04169, 0, 0.23889],
56094    "567": [0.19444, 0.44444, 0.04169, 0, 0.26667],
56095    "710": [0, 0.69444, 0.0799, 0, 0.5],
56096    "711": [0, 0.63194, 0.08432, 0, 0.5],
56097    "713": [0, 0.60889, 0.08776, 0, 0.5],
56098    "714": [0, 0.69444, 0.09205, 0, 0.5],
56099    "715": [0, 0.69444, 0, 0, 0.5],
56100    "728": [0, 0.69444, 0.09483, 0, 0.5],
56101    "729": [0, 0.67937, 0.07774, 0, 0.27778],
56102    "730": [0, 0.69444, 0, 0, 0.73752],
56103    "732": [0, 0.67659, 0.08826, 0, 0.5],
56104    "733": [0, 0.69444, 0.09205, 0, 0.5],
56105    "915": [0, 0.69444, 0.13372, 0, 0.54167],
56106    "916": [0, 0.69444, 0, 0, 0.83334],
56107    "920": [0, 0.69444, 0.07555, 0, 0.77778],
56108    "923": [0, 0.69444, 0, 0, 0.61111],
56109    "926": [0, 0.69444, 0.12816, 0, 0.66667],
56110    "928": [0, 0.69444, 0.08094, 0, 0.70834],
56111    "931": [0, 0.69444, 0.11983, 0, 0.72222],
56112    "933": [0, 0.69444, 0.09031, 0, 0.77778],
56113    "934": [0, 0.69444, 0.04603, 0, 0.72222],
56114    "936": [0, 0.69444, 0.09031, 0, 0.77778],
56115    "937": [0, 0.69444, 0.08293, 0, 0.72222],
56116    "8211": [0, 0.44444, 0.08616, 0, 0.5],
56117    "8212": [0, 0.44444, 0.08616, 0, 1],
56118    "8216": [0, 0.69444, 0.07816, 0, 0.27778],
56119    "8217": [0, 0.69444, 0.07816, 0, 0.27778],
56120    "8220": [0, 0.69444, 0.14205, 0, 0.5],
56121    "8221": [0, 0.69444, 316e-5, 0, 0.5]
56122  },
56123  "SansSerif-Regular": {
56124    "32": [0, 0, 0, 0, 0.25],
56125    "33": [0, 0.69444, 0, 0, 0.31945],
56126    "34": [0, 0.69444, 0, 0, 0.5],
56127    "35": [0.19444, 0.69444, 0, 0, 0.83334],
56128    "36": [0.05556, 0.75, 0, 0, 0.5],
56129    "37": [0.05556, 0.75, 0, 0, 0.83334],
56130    "38": [0, 0.69444, 0, 0, 0.75834],
56131    "39": [0, 0.69444, 0, 0, 0.27778],
56132    "40": [0.25, 0.75, 0, 0, 0.38889],
56133    "41": [0.25, 0.75, 0, 0, 0.38889],
56134    "42": [0, 0.75, 0, 0, 0.5],
56135    "43": [0.08333, 0.58333, 0, 0, 0.77778],
56136    "44": [0.125, 0.08333, 0, 0, 0.27778],
56137    "45": [0, 0.44444, 0, 0, 0.33333],
56138    "46": [0, 0.08333, 0, 0, 0.27778],
56139    "47": [0.25, 0.75, 0, 0, 0.5],
56140    "48": [0, 0.65556, 0, 0, 0.5],
56141    "49": [0, 0.65556, 0, 0, 0.5],
56142    "50": [0, 0.65556, 0, 0, 0.5],
56143    "51": [0, 0.65556, 0, 0, 0.5],
56144    "52": [0, 0.65556, 0, 0, 0.5],
56145    "53": [0, 0.65556, 0, 0, 0.5],
56146    "54": [0, 0.65556, 0, 0, 0.5],
56147    "55": [0, 0.65556, 0, 0, 0.5],
56148    "56": [0, 0.65556, 0, 0, 0.5],
56149    "57": [0, 0.65556, 0, 0, 0.5],
56150    "58": [0, 0.44444, 0, 0, 0.27778],
56151    "59": [0.125, 0.44444, 0, 0, 0.27778],
56152    "61": [-0.13, 0.37, 0, 0, 0.77778],
56153    "63": [0, 0.69444, 0, 0, 0.47222],
56154    "64": [0, 0.69444, 0, 0, 0.66667],
56155    "65": [0, 0.69444, 0, 0, 0.66667],
56156    "66": [0, 0.69444, 0, 0, 0.66667],
56157    "67": [0, 0.69444, 0, 0, 0.63889],
56158    "68": [0, 0.69444, 0, 0, 0.72223],
56159    "69": [0, 0.69444, 0, 0, 0.59722],
56160    "70": [0, 0.69444, 0, 0, 0.56945],
56161    "71": [0, 0.69444, 0, 0, 0.66667],
56162    "72": [0, 0.69444, 0, 0, 0.70834],
56163    "73": [0, 0.69444, 0, 0, 0.27778],
56164    "74": [0, 0.69444, 0, 0, 0.47222],
56165    "75": [0, 0.69444, 0, 0, 0.69445],
56166    "76": [0, 0.69444, 0, 0, 0.54167],
56167    "77": [0, 0.69444, 0, 0, 0.875],
56168    "78": [0, 0.69444, 0, 0, 0.70834],
56169    "79": [0, 0.69444, 0, 0, 0.73611],
56170    "80": [0, 0.69444, 0, 0, 0.63889],
56171    "81": [0.125, 0.69444, 0, 0, 0.73611],
56172    "82": [0, 0.69444, 0, 0, 0.64584],
56173    "83": [0, 0.69444, 0, 0, 0.55556],
56174    "84": [0, 0.69444, 0, 0, 0.68056],
56175    "85": [0, 0.69444, 0, 0, 0.6875],
56176    "86": [0, 0.69444, 0.01389, 0, 0.66667],
56177    "87": [0, 0.69444, 0.01389, 0, 0.94445],
56178    "88": [0, 0.69444, 0, 0, 0.66667],
56179    "89": [0, 0.69444, 0.025, 0, 0.66667],
56180    "90": [0, 0.69444, 0, 0, 0.61111],
56181    "91": [0.25, 0.75, 0, 0, 0.28889],
56182    "93": [0.25, 0.75, 0, 0, 0.28889],
56183    "94": [0, 0.69444, 0, 0, 0.5],
56184    "95": [0.35, 0.09444, 0.02778, 0, 0.5],
56185    "97": [0, 0.44444, 0, 0, 0.48056],
56186    "98": [0, 0.69444, 0, 0, 0.51667],
56187    "99": [0, 0.44444, 0, 0, 0.44445],
56188    "100": [0, 0.69444, 0, 0, 0.51667],
56189    "101": [0, 0.44444, 0, 0, 0.44445],
56190    "102": [0, 0.69444, 0.06944, 0, 0.30556],
56191    "103": [0.19444, 0.44444, 0.01389, 0, 0.5],
56192    "104": [0, 0.69444, 0, 0, 0.51667],
56193    "105": [0, 0.67937, 0, 0, 0.23889],
56194    "106": [0.19444, 0.67937, 0, 0, 0.26667],
56195    "107": [0, 0.69444, 0, 0, 0.48889],
56196    "108": [0, 0.69444, 0, 0, 0.23889],
56197    "109": [0, 0.44444, 0, 0, 0.79445],
56198    "110": [0, 0.44444, 0, 0, 0.51667],
56199    "111": [0, 0.44444, 0, 0, 0.5],
56200    "112": [0.19444, 0.44444, 0, 0, 0.51667],
56201    "113": [0.19444, 0.44444, 0, 0, 0.51667],
56202    "114": [0, 0.44444, 0.01389, 0, 0.34167],
56203    "115": [0, 0.44444, 0, 0, 0.38333],
56204    "116": [0, 0.57143, 0, 0, 0.36111],
56205    "117": [0, 0.44444, 0, 0, 0.51667],
56206    "118": [0, 0.44444, 0.01389, 0, 0.46111],
56207    "119": [0, 0.44444, 0.01389, 0, 0.68334],
56208    "120": [0, 0.44444, 0, 0, 0.46111],
56209    "121": [0.19444, 0.44444, 0.01389, 0, 0.46111],
56210    "122": [0, 0.44444, 0, 0, 0.43472],
56211    "126": [0.35, 0.32659, 0, 0, 0.5],
56212    "160": [0, 0, 0, 0, 0.25],
56213    "168": [0, 0.67937, 0, 0, 0.5],
56214    "176": [0, 0.69444, 0, 0, 0.66667],
56215    "184": [0.17014, 0, 0, 0, 0.44445],
56216    "305": [0, 0.44444, 0, 0, 0.23889],
56217    "567": [0.19444, 0.44444, 0, 0, 0.26667],
56218    "710": [0, 0.69444, 0, 0, 0.5],
56219    "711": [0, 0.63194, 0, 0, 0.5],
56220    "713": [0, 0.60889, 0, 0, 0.5],
56221    "714": [0, 0.69444, 0, 0, 0.5],
56222    "715": [0, 0.69444, 0, 0, 0.5],
56223    "728": [0, 0.69444, 0, 0, 0.5],
56224    "729": [0, 0.67937, 0, 0, 0.27778],
56225    "730": [0, 0.69444, 0, 0, 0.66667],
56226    "732": [0, 0.67659, 0, 0, 0.5],
56227    "733": [0, 0.69444, 0, 0, 0.5],
56228    "915": [0, 0.69444, 0, 0, 0.54167],
56229    "916": [0, 0.69444, 0, 0, 0.83334],
56230    "920": [0, 0.69444, 0, 0, 0.77778],
56231    "923": [0, 0.69444, 0, 0, 0.61111],
56232    "926": [0, 0.69444, 0, 0, 0.66667],
56233    "928": [0, 0.69444, 0, 0, 0.70834],
56234    "931": [0, 0.69444, 0, 0, 0.72222],
56235    "933": [0, 0.69444, 0, 0, 0.77778],
56236    "934": [0, 0.69444, 0, 0, 0.72222],
56237    "936": [0, 0.69444, 0, 0, 0.77778],
56238    "937": [0, 0.69444, 0, 0, 0.72222],
56239    "8211": [0, 0.44444, 0.02778, 0, 0.5],
56240    "8212": [0, 0.44444, 0.02778, 0, 1],
56241    "8216": [0, 0.69444, 0, 0, 0.27778],
56242    "8217": [0, 0.69444, 0, 0, 0.27778],
56243    "8220": [0, 0.69444, 0, 0, 0.5],
56244    "8221": [0, 0.69444, 0, 0, 0.5]
56245  },
56246  "Script-Regular": {
56247    "32": [0, 0, 0, 0, 0.25],
56248    "65": [0, 0.7, 0.22925, 0, 0.80253],
56249    "66": [0, 0.7, 0.04087, 0, 0.90757],
56250    "67": [0, 0.7, 0.1689, 0, 0.66619],
56251    "68": [0, 0.7, 0.09371, 0, 0.77443],
56252    "69": [0, 0.7, 0.18583, 0, 0.56162],
56253    "70": [0, 0.7, 0.13634, 0, 0.89544],
56254    "71": [0, 0.7, 0.17322, 0, 0.60961],
56255    "72": [0, 0.7, 0.29694, 0, 0.96919],
56256    "73": [0, 0.7, 0.19189, 0, 0.80907],
56257    "74": [0.27778, 0.7, 0.19189, 0, 1.05159],
56258    "75": [0, 0.7, 0.31259, 0, 0.91364],
56259    "76": [0, 0.7, 0.19189, 0, 0.87373],
56260    "77": [0, 0.7, 0.15981, 0, 1.08031],
56261    "78": [0, 0.7, 0.3525, 0, 0.9015],
56262    "79": [0, 0.7, 0.08078, 0, 0.73787],
56263    "80": [0, 0.7, 0.08078, 0, 1.01262],
56264    "81": [0, 0.7, 0.03305, 0, 0.88282],
56265    "82": [0, 0.7, 0.06259, 0, 0.85],
56266    "83": [0, 0.7, 0.19189, 0, 0.86767],
56267    "84": [0, 0.7, 0.29087, 0, 0.74697],
56268    "85": [0, 0.7, 0.25815, 0, 0.79996],
56269    "86": [0, 0.7, 0.27523, 0, 0.62204],
56270    "87": [0, 0.7, 0.27523, 0, 0.80532],
56271    "88": [0, 0.7, 0.26006, 0, 0.94445],
56272    "89": [0, 0.7, 0.2939, 0, 0.70961],
56273    "90": [0, 0.7, 0.24037, 0, 0.8212],
56274    "160": [0, 0, 0, 0, 0.25]
56275  },
56276  "Size1-Regular": {
56277    "32": [0, 0, 0, 0, 0.25],
56278    "40": [0.35001, 0.85, 0, 0, 0.45834],
56279    "41": [0.35001, 0.85, 0, 0, 0.45834],
56280    "47": [0.35001, 0.85, 0, 0, 0.57778],
56281    "91": [0.35001, 0.85, 0, 0, 0.41667],
56282    "92": [0.35001, 0.85, 0, 0, 0.57778],
56283    "93": [0.35001, 0.85, 0, 0, 0.41667],
56284    "123": [0.35001, 0.85, 0, 0, 0.58334],
56285    "125": [0.35001, 0.85, 0, 0, 0.58334],
56286    "160": [0, 0, 0, 0, 0.25],
56287    "710": [0, 0.72222, 0, 0, 0.55556],
56288    "732": [0, 0.72222, 0, 0, 0.55556],
56289    "770": [0, 0.72222, 0, 0, 0.55556],
56290    "771": [0, 0.72222, 0, 0, 0.55556],
56291    "8214": [-99e-5, 0.601, 0, 0, 0.77778],
56292    "8593": [1e-5, 0.6, 0, 0, 0.66667],
56293    "8595": [1e-5, 0.6, 0, 0, 0.66667],
56294    "8657": [1e-5, 0.6, 0, 0, 0.77778],
56295    "8659": [1e-5, 0.6, 0, 0, 0.77778],
56296    "8719": [0.25001, 0.75, 0, 0, 0.94445],
56297    "8720": [0.25001, 0.75, 0, 0, 0.94445],
56298    "8721": [0.25001, 0.75, 0, 0, 1.05556],
56299    "8730": [0.35001, 0.85, 0, 0, 1],
56300    "8739": [-599e-5, 0.606, 0, 0, 0.33333],
56301    "8741": [-599e-5, 0.606, 0, 0, 0.55556],
56302    "8747": [0.30612, 0.805, 0.19445, 0, 0.47222],
56303    "8748": [0.306, 0.805, 0.19445, 0, 0.47222],
56304    "8749": [0.306, 0.805, 0.19445, 0, 0.47222],
56305    "8750": [0.30612, 0.805, 0.19445, 0, 0.47222],
56306    "8896": [0.25001, 0.75, 0, 0, 0.83334],
56307    "8897": [0.25001, 0.75, 0, 0, 0.83334],
56308    "8898": [0.25001, 0.75, 0, 0, 0.83334],
56309    "8899": [0.25001, 0.75, 0, 0, 0.83334],
56310    "8968": [0.35001, 0.85, 0, 0, 0.47222],
56311    "8969": [0.35001, 0.85, 0, 0, 0.47222],
56312    "8970": [0.35001, 0.85, 0, 0, 0.47222],
56313    "8971": [0.35001, 0.85, 0, 0, 0.47222],
56314    "9168": [-99e-5, 0.601, 0, 0, 0.66667],
56315    "10216": [0.35001, 0.85, 0, 0, 0.47222],
56316    "10217": [0.35001, 0.85, 0, 0, 0.47222],
56317    "10752": [0.25001, 0.75, 0, 0, 1.11111],
56318    "10753": [0.25001, 0.75, 0, 0, 1.11111],
56319    "10754": [0.25001, 0.75, 0, 0, 1.11111],
56320    "10756": [0.25001, 0.75, 0, 0, 0.83334],
56321    "10758": [0.25001, 0.75, 0, 0, 0.83334]
56322  },
56323  "Size2-Regular": {
56324    "32": [0, 0, 0, 0, 0.25],
56325    "40": [0.65002, 1.15, 0, 0, 0.59722],
56326    "41": [0.65002, 1.15, 0, 0, 0.59722],
56327    "47": [0.65002, 1.15, 0, 0, 0.81111],
56328    "91": [0.65002, 1.15, 0, 0, 0.47222],
56329    "92": [0.65002, 1.15, 0, 0, 0.81111],
56330    "93": [0.65002, 1.15, 0, 0, 0.47222],
56331    "123": [0.65002, 1.15, 0, 0, 0.66667],
56332    "125": [0.65002, 1.15, 0, 0, 0.66667],
56333    "160": [0, 0, 0, 0, 0.25],
56334    "710": [0, 0.75, 0, 0, 1],
56335    "732": [0, 0.75, 0, 0, 1],
56336    "770": [0, 0.75, 0, 0, 1],
56337    "771": [0, 0.75, 0, 0, 1],
56338    "8719": [0.55001, 1.05, 0, 0, 1.27778],
56339    "8720": [0.55001, 1.05, 0, 0, 1.27778],
56340    "8721": [0.55001, 1.05, 0, 0, 1.44445],
56341    "8730": [0.65002, 1.15, 0, 0, 1],
56342    "8747": [0.86225, 1.36, 0.44445, 0, 0.55556],
56343    "8748": [0.862, 1.36, 0.44445, 0, 0.55556],
56344    "8749": [0.862, 1.36, 0.44445, 0, 0.55556],
56345    "8750": [0.86225, 1.36, 0.44445, 0, 0.55556],
56346    "8896": [0.55001, 1.05, 0, 0, 1.11111],
56347    "8897": [0.55001, 1.05, 0, 0, 1.11111],
56348    "8898": [0.55001, 1.05, 0, 0, 1.11111],
56349    "8899": [0.55001, 1.05, 0, 0, 1.11111],
56350    "8968": [0.65002, 1.15, 0, 0, 0.52778],
56351    "8969": [0.65002, 1.15, 0, 0, 0.52778],
56352    "8970": [0.65002, 1.15, 0, 0, 0.52778],
56353    "8971": [0.65002, 1.15, 0, 0, 0.52778],
56354    "10216": [0.65002, 1.15, 0, 0, 0.61111],
56355    "10217": [0.65002, 1.15, 0, 0, 0.61111],
56356    "10752": [0.55001, 1.05, 0, 0, 1.51112],
56357    "10753": [0.55001, 1.05, 0, 0, 1.51112],
56358    "10754": [0.55001, 1.05, 0, 0, 1.51112],
56359    "10756": [0.55001, 1.05, 0, 0, 1.11111],
56360    "10758": [0.55001, 1.05, 0, 0, 1.11111]
56361  },
56362  "Size3-Regular": {
56363    "32": [0, 0, 0, 0, 0.25],
56364    "40": [0.95003, 1.45, 0, 0, 0.73611],
56365    "41": [0.95003, 1.45, 0, 0, 0.73611],
56366    "47": [0.95003, 1.45, 0, 0, 1.04445],
56367    "91": [0.95003, 1.45, 0, 0, 0.52778],
56368    "92": [0.95003, 1.45, 0, 0, 1.04445],
56369    "93": [0.95003, 1.45, 0, 0, 0.52778],
56370    "123": [0.95003, 1.45, 0, 0, 0.75],
56371    "125": [0.95003, 1.45, 0, 0, 0.75],
56372    "160": [0, 0, 0, 0, 0.25],
56373    "710": [0, 0.75, 0, 0, 1.44445],
56374    "732": [0, 0.75, 0, 0, 1.44445],
56375    "770": [0, 0.75, 0, 0, 1.44445],
56376    "771": [0, 0.75, 0, 0, 1.44445],
56377    "8730": [0.95003, 1.45, 0, 0, 1],
56378    "8968": [0.95003, 1.45, 0, 0, 0.58334],
56379    "8969": [0.95003, 1.45, 0, 0, 0.58334],
56380    "8970": [0.95003, 1.45, 0, 0, 0.58334],
56381    "8971": [0.95003, 1.45, 0, 0, 0.58334],
56382    "10216": [0.95003, 1.45, 0, 0, 0.75],
56383    "10217": [0.95003, 1.45, 0, 0, 0.75]
56384  },
56385  "Size4-Regular": {
56386    "32": [0, 0, 0, 0, 0.25],
56387    "40": [1.25003, 1.75, 0, 0, 0.79167],
56388    "41": [1.25003, 1.75, 0, 0, 0.79167],
56389    "47": [1.25003, 1.75, 0, 0, 1.27778],
56390    "91": [1.25003, 1.75, 0, 0, 0.58334],
56391    "92": [1.25003, 1.75, 0, 0, 1.27778],
56392    "93": [1.25003, 1.75, 0, 0, 0.58334],
56393    "123": [1.25003, 1.75, 0, 0, 0.80556],
56394    "125": [1.25003, 1.75, 0, 0, 0.80556],
56395    "160": [0, 0, 0, 0, 0.25],
56396    "710": [0, 0.825, 0, 0, 1.8889],
56397    "732": [0, 0.825, 0, 0, 1.8889],
56398    "770": [0, 0.825, 0, 0, 1.8889],
56399    "771": [0, 0.825, 0, 0, 1.8889],
56400    "8730": [1.25003, 1.75, 0, 0, 1],
56401    "8968": [1.25003, 1.75, 0, 0, 0.63889],
56402    "8969": [1.25003, 1.75, 0, 0, 0.63889],
56403    "8970": [1.25003, 1.75, 0, 0, 0.63889],
56404    "8971": [1.25003, 1.75, 0, 0, 0.63889],
56405    "9115": [0.64502, 1.155, 0, 0, 0.875],
56406    "9116": [1e-5, 0.6, 0, 0, 0.875],
56407    "9117": [0.64502, 1.155, 0, 0, 0.875],
56408    "9118": [0.64502, 1.155, 0, 0, 0.875],
56409    "9119": [1e-5, 0.6, 0, 0, 0.875],
56410    "9120": [0.64502, 1.155, 0, 0, 0.875],
56411    "9121": [0.64502, 1.155, 0, 0, 0.66667],
56412    "9122": [-99e-5, 0.601, 0, 0, 0.66667],
56413    "9123": [0.64502, 1.155, 0, 0, 0.66667],
56414    "9124": [0.64502, 1.155, 0, 0, 0.66667],
56415    "9125": [-99e-5, 0.601, 0, 0, 0.66667],
56416    "9126": [0.64502, 1.155, 0, 0, 0.66667],
56417    "9127": [1e-5, 0.9, 0, 0, 0.88889],
56418    "9128": [0.65002, 1.15, 0, 0, 0.88889],
56419    "9129": [0.90001, 0, 0, 0, 0.88889],
56420    "9130": [0, 0.3, 0, 0, 0.88889],
56421    "9131": [1e-5, 0.9, 0, 0, 0.88889],
56422    "9132": [0.65002, 1.15, 0, 0, 0.88889],
56423    "9133": [0.90001, 0, 0, 0, 0.88889],
56424    "9143": [0.88502, 0.915, 0, 0, 1.05556],
56425    "10216": [1.25003, 1.75, 0, 0, 0.80556],
56426    "10217": [1.25003, 1.75, 0, 0, 0.80556],
56427    "57344": [-499e-5, 0.605, 0, 0, 1.05556],
56428    "57345": [-499e-5, 0.605, 0, 0, 1.05556],
56429    "57680": [0, 0.12, 0, 0, 0.45],
56430    "57681": [0, 0.12, 0, 0, 0.45],
56431    "57682": [0, 0.12, 0, 0, 0.45],
56432    "57683": [0, 0.12, 0, 0, 0.45]
56433  },
56434  "Typewriter-Regular": {
56435    "32": [0, 0, 0, 0, 0.525],
56436    "33": [0, 0.61111, 0, 0, 0.525],
56437    "34": [0, 0.61111, 0, 0, 0.525],
56438    "35": [0, 0.61111, 0, 0, 0.525],
56439    "36": [0.08333, 0.69444, 0, 0, 0.525],
56440    "37": [0.08333, 0.69444, 0, 0, 0.525],
56441    "38": [0, 0.61111, 0, 0, 0.525],
56442    "39": [0, 0.61111, 0, 0, 0.525],
56443    "40": [0.08333, 0.69444, 0, 0, 0.525],
56444    "41": [0.08333, 0.69444, 0, 0, 0.525],
56445    "42": [0, 0.52083, 0, 0, 0.525],
56446    "43": [-0.08056, 0.53055, 0, 0, 0.525],
56447    "44": [0.13889, 0.125, 0, 0, 0.525],
56448    "45": [-0.08056, 0.53055, 0, 0, 0.525],
56449    "46": [0, 0.125, 0, 0, 0.525],
56450    "47": [0.08333, 0.69444, 0, 0, 0.525],
56451    "48": [0, 0.61111, 0, 0, 0.525],
56452    "49": [0, 0.61111, 0, 0, 0.525],
56453    "50": [0, 0.61111, 0, 0, 0.525],
56454    "51": [0, 0.61111, 0, 0, 0.525],
56455    "52": [0, 0.61111, 0, 0, 0.525],
56456    "53": [0, 0.61111, 0, 0, 0.525],
56457    "54": [0, 0.61111, 0, 0, 0.525],
56458    "55": [0, 0.61111, 0, 0, 0.525],
56459    "56": [0, 0.61111, 0, 0, 0.525],
56460    "57": [0, 0.61111, 0, 0, 0.525],
56461    "58": [0, 0.43056, 0, 0, 0.525],
56462    "59": [0.13889, 0.43056, 0, 0, 0.525],
56463    "60": [-0.05556, 0.55556, 0, 0, 0.525],
56464    "61": [-0.19549, 0.41562, 0, 0, 0.525],
56465    "62": [-0.05556, 0.55556, 0, 0, 0.525],
56466    "63": [0, 0.61111, 0, 0, 0.525],
56467    "64": [0, 0.61111, 0, 0, 0.525],
56468    "65": [0, 0.61111, 0, 0, 0.525],
56469    "66": [0, 0.61111, 0, 0, 0.525],
56470    "67": [0, 0.61111, 0, 0, 0.525],
56471    "68": [0, 0.61111, 0, 0, 0.525],
56472    "69": [0, 0.61111, 0, 0, 0.525],
56473    "70": [0, 0.61111, 0, 0, 0.525],
56474    "71": [0, 0.61111, 0, 0, 0.525],
56475    "72": [0, 0.61111, 0, 0, 0.525],
56476    "73": [0, 0.61111, 0, 0, 0.525],
56477    "74": [0, 0.61111, 0, 0, 0.525],
56478    "75": [0, 0.61111, 0, 0, 0.525],
56479    "76": [0, 0.61111, 0, 0, 0.525],
56480    "77": [0, 0.61111, 0, 0, 0.525],
56481    "78": [0, 0.61111, 0, 0, 0.525],
56482    "79": [0, 0.61111, 0, 0, 0.525],
56483    "80": [0, 0.61111, 0, 0, 0.525],
56484    "81": [0.13889, 0.61111, 0, 0, 0.525],
56485    "82": [0, 0.61111, 0, 0, 0.525],
56486    "83": [0, 0.61111, 0, 0, 0.525],
56487    "84": [0, 0.61111, 0, 0, 0.525],
56488    "85": [0, 0.61111, 0, 0, 0.525],
56489    "86": [0, 0.61111, 0, 0, 0.525],
56490    "87": [0, 0.61111, 0, 0, 0.525],
56491    "88": [0, 0.61111, 0, 0, 0.525],
56492    "89": [0, 0.61111, 0, 0, 0.525],
56493    "90": [0, 0.61111, 0, 0, 0.525],
56494    "91": [0.08333, 0.69444, 0, 0, 0.525],
56495    "92": [0.08333, 0.69444, 0, 0, 0.525],
56496    "93": [0.08333, 0.69444, 0, 0, 0.525],
56497    "94": [0, 0.61111, 0, 0, 0.525],
56498    "95": [0.09514, 0, 0, 0, 0.525],
56499    "96": [0, 0.61111, 0, 0, 0.525],
56500    "97": [0, 0.43056, 0, 0, 0.525],
56501    "98": [0, 0.61111, 0, 0, 0.525],
56502    "99": [0, 0.43056, 0, 0, 0.525],
56503    "100": [0, 0.61111, 0, 0, 0.525],
56504    "101": [0, 0.43056, 0, 0, 0.525],
56505    "102": [0, 0.61111, 0, 0, 0.525],
56506    "103": [0.22222, 0.43056, 0, 0, 0.525],
56507    "104": [0, 0.61111, 0, 0, 0.525],
56508    "105": [0, 0.61111, 0, 0, 0.525],
56509    "106": [0.22222, 0.61111, 0, 0, 0.525],
56510    "107": [0, 0.61111, 0, 0, 0.525],
56511    "108": [0, 0.61111, 0, 0, 0.525],
56512    "109": [0, 0.43056, 0, 0, 0.525],
56513    "110": [0, 0.43056, 0, 0, 0.525],
56514    "111": [0, 0.43056, 0, 0, 0.525],
56515    "112": [0.22222, 0.43056, 0, 0, 0.525],
56516    "113": [0.22222, 0.43056, 0, 0, 0.525],
56517    "114": [0, 0.43056, 0, 0, 0.525],
56518    "115": [0, 0.43056, 0, 0, 0.525],
56519    "116": [0, 0.55358, 0, 0, 0.525],
56520    "117": [0, 0.43056, 0, 0, 0.525],
56521    "118": [0, 0.43056, 0, 0, 0.525],
56522    "119": [0, 0.43056, 0, 0, 0.525],
56523    "120": [0, 0.43056, 0, 0, 0.525],
56524    "121": [0.22222, 0.43056, 0, 0, 0.525],
56525    "122": [0, 0.43056, 0, 0, 0.525],
56526    "123": [0.08333, 0.69444, 0, 0, 0.525],
56527    "124": [0.08333, 0.69444, 0, 0, 0.525],
56528    "125": [0.08333, 0.69444, 0, 0, 0.525],
56529    "126": [0, 0.61111, 0, 0, 0.525],
56530    "127": [0, 0.61111, 0, 0, 0.525],
56531    "160": [0, 0, 0, 0, 0.525],
56532    "176": [0, 0.61111, 0, 0, 0.525],
56533    "184": [0.19445, 0, 0, 0, 0.525],
56534    "305": [0, 0.43056, 0, 0, 0.525],
56535    "567": [0.22222, 0.43056, 0, 0, 0.525],
56536    "711": [0, 0.56597, 0, 0, 0.525],
56537    "713": [0, 0.56555, 0, 0, 0.525],
56538    "714": [0, 0.61111, 0, 0, 0.525],
56539    "715": [0, 0.61111, 0, 0, 0.525],
56540    "728": [0, 0.61111, 0, 0, 0.525],
56541    "730": [0, 0.61111, 0, 0, 0.525],
56542    "770": [0, 0.61111, 0, 0, 0.525],
56543    "771": [0, 0.61111, 0, 0, 0.525],
56544    "776": [0, 0.61111, 0, 0, 0.525],
56545    "915": [0, 0.61111, 0, 0, 0.525],
56546    "916": [0, 0.61111, 0, 0, 0.525],
56547    "920": [0, 0.61111, 0, 0, 0.525],
56548    "923": [0, 0.61111, 0, 0, 0.525],
56549    "926": [0, 0.61111, 0, 0, 0.525],
56550    "928": [0, 0.61111, 0, 0, 0.525],
56551    "931": [0, 0.61111, 0, 0, 0.525],
56552    "933": [0, 0.61111, 0, 0, 0.525],
56553    "934": [0, 0.61111, 0, 0, 0.525],
56554    "936": [0, 0.61111, 0, 0, 0.525],
56555    "937": [0, 0.61111, 0, 0, 0.525],
56556    "8216": [0, 0.61111, 0, 0, 0.525],
56557    "8217": [0, 0.61111, 0, 0, 0.525],
56558    "8242": [0, 0.61111, 0, 0, 0.525],
56559    "9251": [0.11111, 0.21944, 0, 0, 0.525]
56560  }
56561};
56562var sigmasAndXis = {
56563  slant: [0.25, 0.25, 0.25],
56564  // sigma1
56565  space: [0, 0, 0],
56566  // sigma2
56567  stretch: [0, 0, 0],
56568  // sigma3
56569  shrink: [0, 0, 0],
56570  // sigma4
56571  xHeight: [0.431, 0.431, 0.431],
56572  // sigma5
56573  quad: [1, 1.171, 1.472],
56574  // sigma6
56575  extraSpace: [0, 0, 0],
56576  // sigma7
56577  num1: [0.677, 0.732, 0.925],
56578  // sigma8
56579  num2: [0.394, 0.384, 0.387],
56580  // sigma9
56581  num3: [0.444, 0.471, 0.504],
56582  // sigma10
56583  denom1: [0.686, 0.752, 1.025],
56584  // sigma11
56585  denom2: [0.345, 0.344, 0.532],
56586  // sigma12
56587  sup1: [0.413, 0.503, 0.504],
56588  // sigma13
56589  sup2: [0.363, 0.431, 0.404],
56590  // sigma14
56591  sup3: [0.289, 0.286, 0.294],
56592  // sigma15
56593  sub1: [0.15, 0.143, 0.2],
56594  // sigma16
56595  sub2: [0.247, 0.286, 0.4],
56596  // sigma17
56597  supDrop: [0.386, 0.353, 0.494],
56598  // sigma18
56599  subDrop: [0.05, 0.071, 0.1],
56600  // sigma19
56601  delim1: [2.39, 1.7, 1.98],
56602  // sigma20
56603  delim2: [1.01, 1.157, 1.42],
56604  // sigma21
56605  axisHeight: [0.25, 0.25, 0.25],
56606  // sigma22
56607  // These font metrics are extracted from TeX by using tftopl on cmex10.tfm;
56608  // they correspond to the font parameters of the extension fonts (family 3).
56609  // See the TeXbook, page 441. In AMSTeX, the extension fonts scale; to
56610  // match cmex7, we'd use cmex7.tfm values for script and scriptscript
56611  // values.
56612  defaultRuleThickness: [0.04, 0.049, 0.049],
56613  // xi8; cmex7: 0.049
56614  bigOpSpacing1: [0.111, 0.111, 0.111],
56615  // xi9
56616  bigOpSpacing2: [0.166, 0.166, 0.166],
56617  // xi10
56618  bigOpSpacing3: [0.2, 0.2, 0.2],
56619  // xi11
56620  bigOpSpacing4: [0.6, 0.611, 0.611],
56621  // xi12; cmex7: 0.611
56622  bigOpSpacing5: [0.1, 0.143, 0.143],
56623  // xi13; cmex7: 0.143
56624  // The \sqrt rule width is taken from the height of the surd character.
56625  // Since we use the same font at all sizes, this thickness doesn't scale.
56626  sqrtRuleThickness: [0.04, 0.04, 0.04],
56627  // This value determines how large a pt is, for metrics which are defined
56628  // in terms of pts.
56629  // This value is also used in katex.scss; if you change it make sure the
56630  // values match.
56631  ptPerEm: [10, 10, 10],
56632  // The space between adjacent `|` columns in an array definition. From
56633  // `\showthe\doublerulesep` in LaTeX. Equals 2.0 / ptPerEm.
56634  doubleRuleSep: [0.2, 0.2, 0.2],
56635  // The width of separator lines in {array} environments. From
56636  // `\showthe\arrayrulewidth` in LaTeX. Equals 0.4 / ptPerEm.
56637  arrayRuleWidth: [0.04, 0.04, 0.04],
56638  // Two values from LaTeX source2e:
56639  fboxsep: [0.3, 0.3, 0.3],
56640  //        3 pt / ptPerEm
56641  fboxrule: [0.04, 0.04, 0.04]
56642  // 0.4 pt / ptPerEm
56643};
56644var extraCharacterMap = {
56645  // Latin-1
56646  "\xC5": "A",
56647  "\xD0": "D",
56648  "\xDE": "o",
56649  "\xE5": "a",
56650  "\xF0": "d",
56651  "\xFE": "o",
56652  // Cyrillic
56653  "\u0410": "A",
56654  "\u0411": "B",
56655  "\u0412": "B",
56656  "\u0413": "F",
56657  "\u0414": "A",
56658  "\u0415": "E",
56659  "\u0416": "K",
56660  "\u0417": "3",
56661  "\u0418": "N",
56662  "\u0419": "N",
56663  "\u041A": "K",
56664  "\u041B": "N",
56665  "\u041C": "M",
56666  "\u041D": "H",
56667  "\u041E": "O",
56668  "\u041F": "N",
56669  "\u0420": "P",
56670  "\u0421": "C",
56671  "\u0422": "T",
56672  "\u0423": "y",
56673  "\u0424": "O",
56674  "\u0425": "X",
56675  "\u0426": "U",
56676  "\u0427": "h",
56677  "\u0428": "W",
56678  "\u0429": "W",
56679  "\u042A": "B",
56680  "\u042B": "X",
56681  "\u042C": "B",
56682  "\u042D": "3",
56683  "\u042E": "X",
56684  "\u042F": "R",
56685  "\u0430": "a",
56686  "\u0431": "b",
56687  "\u0432": "a",
56688  "\u0433": "r",
56689  "\u0434": "y",
56690  "\u0435": "e",
56691  "\u0436": "m",
56692  "\u0437": "e",
56693  "\u0438": "n",
56694  "\u0439": "n",
56695  "\u043A": "n",
56696  "\u043B": "n",
56697  "\u043C": "m",
56698  "\u043D": "n",
56699  "\u043E": "o",
56700  "\u043F": "n",
56701  "\u0440": "p",
56702  "\u0441": "c",
56703  "\u0442": "o",
56704  "\u0443": "y",
56705  "\u0444": "b",
56706  "\u0445": "x",
56707  "\u0446": "n",
56708  "\u0447": "n",
56709  "\u0448": "w",
56710  "\u0449": "w",
56711  "\u044A": "a",
56712  "\u044B": "m",
56713  "\u044C": "a",
56714  "\u044D": "e",
56715  "\u044E": "m",
56716  "\u044F": "r"
56717};
56718function getCharacterMetrics(character, font, mode) {
56719  if (!fontMetricsData[font]) {
56720    throw new Error("Font metrics not found for font: " + font + ".");
56721  }
56722  var ch = character.charCodeAt(0);
56723  var metrics = fontMetricsData[font][ch];
56724  if (!metrics && character[0] in extraCharacterMap) {
56725    ch = extraCharacterMap[character[0]].charCodeAt(0);
56726    metrics = fontMetricsData[font][ch];
56727  }
56728  if (!metrics && mode === "text") {
56729    if (supportedCodepoint(ch)) {
56730      metrics = fontMetricsData[font][77];
56731    }
56732  }
56733  if (metrics) {
56734    return {
56735      depth: metrics[0],
56736      height: metrics[1],
56737      italic: metrics[2],
56738      skew: metrics[3],
56739      width: metrics[4]
56740    };
56741  }
56742}
56743var fontMetricsBySizeIndex = {};
56744function getGlobalMetrics(size) {
56745  var sizeIndex;
56746  if (size >= 5) {
56747    sizeIndex = 0;
56748  } else if (size >= 3) {
56749    sizeIndex = 1;
56750  } else {
56751    sizeIndex = 2;
56752  }
56753  if (!fontMetricsBySizeIndex[sizeIndex]) {
56754    var metrics = fontMetricsBySizeIndex[sizeIndex] = {
56755      cssEmPerMu: sigmasAndXis.quad[sizeIndex] / 18
56756    };
56757    for (var key in sigmasAndXis) {
56758      if (sigmasAndXis.hasOwnProperty(key)) {
56759        metrics[key] = sigmasAndXis[key][sizeIndex];
56760      }
56761    }
56762  }
56763  return fontMetricsBySizeIndex[sizeIndex];
56764}
56765var sizeStyleMap = [
56766  // Each element contains [textsize, scriptsize, scriptscriptsize].
56767  // The size mappings are taken from TeX with \normalsize=10pt.
56768  [1, 1, 1],
56769  // size1: [5, 5, 5]              \tiny
56770  [2, 1, 1],
56771  // size2: [6, 5, 5]
56772  [3, 1, 1],
56773  // size3: [7, 5, 5]              \scriptsize
56774  [4, 2, 1],
56775  // size4: [8, 6, 5]              \footnotesize
56776  [5, 2, 1],
56777  // size5: [9, 6, 5]              \small
56778  [6, 3, 1],
56779  // size6: [10, 7, 5]             \normalsize
56780  [7, 4, 2],
56781  // size7: [12, 8, 6]             \large
56782  [8, 6, 3],
56783  // size8: [14.4, 10, 7]          \Large
56784  [9, 7, 6],
56785  // size9: [17.28, 12, 10]        \LARGE
56786  [10, 8, 7],
56787  // size10: [20.74, 14.4, 12]     \huge
56788  [11, 10, 9]
56789  // size11: [24.88, 20.74, 17.28] \HUGE
56790];
56791var sizeMultipliers = [
56792  // fontMetrics.js:getGlobalMetrics also uses size indexes, so if
56793  // you change size indexes, change that function.
56794  0.5,
56795  0.6,
56796  0.7,
56797  0.8,
56798  0.9,
56799  1,
56800  1.2,
56801  1.44,
56802  1.728,
56803  2.074,
56804  2.488
56805];
56806var sizeAtStyle = function sizeAtStyle2(size, style) {
56807  return style.size < 2 ? size : sizeStyleMap[size - 1][style.size - 1];
56808};
56809var Options = class _Options {
56810  // A font family applies to a group of fonts (i.e. SansSerif), while a font
56811  // represents a specific font (i.e. SansSerif Bold).
56812  // See: https://tex.stackexchange.com/questions/22350/difference-between-textrm-and-mathrm
56813  /**
56814   * The base size index.
56815   */
56816  constructor(data) {
56817    this.style = void 0;
56818    this.color = void 0;
56819    this.size = void 0;
56820    this.textSize = void 0;
56821    this.phantom = void 0;
56822    this.font = void 0;
56823    this.fontFamily = void 0;
56824    this.fontWeight = void 0;
56825    this.fontShape = void 0;
56826    this.sizeMultiplier = void 0;
56827    this.maxSize = void 0;
56828    this.minRuleThickness = void 0;
56829    this._fontMetrics = void 0;
56830    this.style = data.style;
56831    this.color = data.color;
56832    this.size = data.size || _Options.BASESIZE;
56833    this.textSize = data.textSize || this.size;
56834    this.phantom = !!data.phantom;
56835    this.font = data.font || "";
56836    this.fontFamily = data.fontFamily || "";
56837    this.fontWeight = data.fontWeight || "";
56838    this.fontShape = data.fontShape || "";
56839    this.sizeMultiplier = sizeMultipliers[this.size - 1];
56840    this.maxSize = data.maxSize;
56841    this.minRuleThickness = data.minRuleThickness;
56842    this._fontMetrics = void 0;
56843  }
56844  /**
56845   * Returns a new options object with the same properties as "this".  Properties
56846   * from "extension" will be copied to the new options object.
56847   */
56848  extend(extension) {
56849    var data = {
56850      style: this.style,
56851      size: this.size,
56852      textSize: this.textSize,
56853      color: this.color,
56854      phantom: this.phantom,
56855      font: this.font,
56856      fontFamily: this.fontFamily,
56857      fontWeight: this.fontWeight,
56858      fontShape: this.fontShape,
56859      maxSize: this.maxSize,
56860      minRuleThickness: this.minRuleThickness
56861    };
56862    for (var key in extension) {
56863      if (extension.hasOwnProperty(key)) {
56864        data[key] = extension[key];
56865      }
56866    }
56867    return new _Options(data);
56868  }
56869  /**
56870   * Return an options object with the given style. If `this.style === style`,
56871   * returns `this`.
56872   */
56873  havingStyle(style) {
56874    if (this.style === style) {
56875      return this;
56876    } else {
56877      return this.extend({
56878        style,
56879        size: sizeAtStyle(this.textSize, style)
56880      });
56881    }
56882  }
56883  /**
56884   * Return an options object with a cramped version of the current style. If
56885   * the current style is cramped, returns `this`.
56886   */
56887  havingCrampedStyle() {
56888    return this.havingStyle(this.style.cramp());
56889  }
56890  /**
56891   * Return an options object with the given size and in at least `\textstyle`.
56892   * Returns `this` if appropriate.
56893   */
56894  havingSize(size) {
56895    if (this.size === size && this.textSize === size) {
56896      return this;
56897    } else {
56898      return this.extend({
56899        style: this.style.text(),
56900        size,
56901        textSize: size,
56902        sizeMultiplier: sizeMultipliers[size - 1]
56903      });
56904    }
56905  }
56906  /**
56907   * Like `this.havingSize(BASESIZE).havingStyle(style)`. If `style` is omitted,
56908   * changes to at least `\textstyle`.
56909   */
56910  havingBaseStyle(style) {
56911    style = style || this.style.text();
56912    var wantSize = sizeAtStyle(_Options.BASESIZE, style);
56913    if (this.size === wantSize && this.textSize === _Options.BASESIZE && this.style === style) {
56914      return this;
56915    } else {
56916      return this.extend({
56917        style,
56918        size: wantSize
56919      });
56920    }
56921  }
56922  /**
56923   * Remove the effect of sizing changes such as \Huge.
56924   * Keep the effect of the current style, such as \scriptstyle.
56925   */
56926  havingBaseSizing() {
56927    var size;
56928    switch (this.style.id) {
56929      case 4:
56930      case 5:
56931        size = 3;
56932        break;
56933      case 6:
56934      case 7:
56935        size = 1;
56936        break;
56937      default:
56938        size = 6;
56939    }
56940    return this.extend({
56941      style: this.style.text(),
56942      size
56943    });
56944  }
56945  /**
56946   * Create a new options object with the given color.
56947   */
56948  withColor(color) {
56949    return this.extend({
56950      color
56951    });
56952  }
56953  /**
56954   * Create a new options object with "phantom" set to true.
56955   */
56956  withPhantom() {
56957    return this.extend({
56958      phantom: true
56959    });
56960  }
56961  /**
56962   * Creates a new options object with the given math font or old text font.
56963   * @type {[type]}
56964   */
56965  withFont(font) {
56966    return this.extend({
56967      font
56968    });
56969  }
56970  /**
56971   * Create a new options objects with the given fontFamily.
56972   */
56973  withTextFontFamily(fontFamily) {
56974    return this.extend({
56975      fontFamily,
56976      font: ""
56977    });
56978  }
56979  /**
56980   * Creates a new options object with the given font weight
56981   */
56982  withTextFontWeight(fontWeight) {
56983    return this.extend({
56984      fontWeight,
56985      font: ""
56986    });
56987  }
56988  /**
56989   * Creates a new options object with the given font weight
56990   */
56991  withTextFontShape(fontShape) {
56992    return this.extend({
56993      fontShape,
56994      font: ""
56995    });
56996  }
56997  /**
56998   * Return the CSS sizing classes required to switch from enclosing options
56999   * `oldOptions` to `this`. Returns an array of classes.
57000   */
57001  sizingClasses(oldOptions) {
57002    if (oldOptions.size !== this.size) {
57003      return ["sizing", "reset-size" + oldOptions.size, "size" + this.size];
57004    } else {
57005      return [];
57006    }
57007  }
57008  /**
57009   * Return the CSS sizing classes required to switch to the base size. Like
57010   * `this.havingSize(BASESIZE).sizingClasses(this)`.
57011   */
57012  baseSizingClasses() {
57013    if (this.size !== _Options.BASESIZE) {
57014      return ["sizing", "reset-size" + this.size, "size" + _Options.BASESIZE];
57015    } else {
57016      return [];
57017    }
57018  }
57019  /**
57020   * Return the font metrics for this size.
57021   */
57022  fontMetrics() {
57023    if (!this._fontMetrics) {
57024      this._fontMetrics = getGlobalMetrics(this.size);
57025    }
57026    return this._fontMetrics;
57027  }
57028  /**
57029   * Gets the CSS color of the current options object
57030   */
57031  getColor() {
57032    if (this.phantom) {
57033      return "transparent";
57034    } else {
57035      return this.color;
57036    }
57037  }
57038};
57039Options.BASESIZE = 6;
57040var ptPerUnit = {
57041  // https://en.wikibooks.org/wiki/LaTeX/Lengths and
57042  // https://tex.stackexchange.com/a/8263
57043  "pt": 1,
57044  // TeX point
57045  "mm": 7227 / 2540,
57046  // millimeter
57047  "cm": 7227 / 254,
57048  // centimeter
57049  "in": 72.27,
57050  // inch
57051  "bp": 803 / 800,
57052  // big (PostScript) points
57053  "pc": 12,
57054  // pica
57055  "dd": 1238 / 1157,
57056  // didot
57057  "cc": 14856 / 1157,
57058  // cicero (12 didot)
57059  "nd": 685 / 642,
57060  // new didot
57061  "nc": 1370 / 107,
57062  // new cicero (12 new didot)
57063  "sp": 1 / 65536,
57064  // scaled point (TeX's internal smallest unit)
57065  // https://tex.stackexchange.com/a/41371
57066  "px": 803 / 800
57067  // \pdfpxdimen defaults to 1 bp in pdfTeX and LuaTeX
57068};
57069var relativeUnit = {
57070  "ex": true,
57071  "em": true,
57072  "mu": true
57073};
57074var validUnit = function validUnit2(unit) {
57075  if (typeof unit !== "string") {
57076    unit = unit.unit;
57077  }
57078  return unit in ptPerUnit || unit in relativeUnit || unit === "ex";
57079};
57080var calculateSize = function calculateSize2(sizeValue, options2) {
57081  var scale;
57082  if (sizeValue.unit in ptPerUnit) {
57083    scale = ptPerUnit[sizeValue.unit] / options2.fontMetrics().ptPerEm / options2.sizeMultiplier;
57084  } else if (sizeValue.unit === "mu") {
57085    scale = options2.fontMetrics().cssEmPerMu;
57086  } else {
57087    var unitOptions;
57088    if (options2.style.isTight()) {
57089      unitOptions = options2.havingStyle(options2.style.text());
57090    } else {
57091      unitOptions = options2;
57092    }
57093    if (sizeValue.unit === "ex") {
57094      scale = unitOptions.fontMetrics().xHeight;
57095    } else if (sizeValue.unit === "em") {
57096      scale = unitOptions.fontMetrics().quad;
57097    } else {
57098      throw new ParseError("Invalid unit: '" + sizeValue.unit + "'");
57099    }
57100    if (unitOptions !== options2) {
57101      scale *= unitOptions.sizeMultiplier / options2.sizeMultiplier;
57102    }
57103  }
57104  return Math.min(sizeValue.number * scale, options2.maxSize);
57105};
57106var makeEm = function makeEm2(n) {
57107  return +n.toFixed(4) + "em";
57108};
57109var createClass = function createClass2(classes2) {
57110  return classes2.filter((cls) => cls).join(" ");
57111};
57112var initNode = function initNode2(classes2, options2, style) {
57113  this.classes = classes2 || [];
57114  this.attributes = {};
57115  this.height = 0;
57116  this.depth = 0;
57117  this.maxFontSize = 0;
57118  this.style = style || {};
57119  if (options2) {
57120    if (options2.style.isTight()) {
57121      this.classes.push("mtight");
57122    }
57123    var color = options2.getColor();
57124    if (color) {
57125      this.style.color = color;
57126    }
57127  }
57128};
57129var toNode = function toNode2(tagName) {
57130  var node = document.createElement(tagName);
57131  node.className = createClass(this.classes);
57132  for (var style in this.style) {
57133    if (this.style.hasOwnProperty(style)) {
57134      node.style[style] = this.style[style];
57135    }
57136  }
57137  for (var attr in this.attributes) {
57138    if (this.attributes.hasOwnProperty(attr)) {
57139      node.setAttribute(attr, this.attributes[attr]);
57140    }
57141  }
57142  for (var i = 0; i < this.children.length; i++) {
57143    node.appendChild(this.children[i].toNode());
57144  }
57145  return node;
57146};
57147var invalidAttributeNameRegex = /[\s"'>/=\x00-\x1f]/;
57148var toMarkup = function toMarkup2(tagName) {
57149  var markup = "<" + tagName;
57150  if (this.classes.length) {
57151    markup += ' class="' + utils.escape(createClass(this.classes)) + '"';
57152  }
57153  var styles2 = "";
57154  for (var style in this.style) {
57155    if (this.style.hasOwnProperty(style)) {
57156      styles2 += utils.hyphenate(style) + ":" + this.style[style] + ";";
57157    }
57158  }
57159  if (styles2) {
57160    markup += ' style="' + utils.escape(styles2) + '"';
57161  }
57162  for (var attr in this.attributes) {
57163    if (this.attributes.hasOwnProperty(attr)) {
57164      if (invalidAttributeNameRegex.test(attr)) {
57165        throw new ParseError("Invalid attribute name '" + attr + "'");
57166      }
57167      markup += " " + attr + '="' + utils.escape(this.attributes[attr]) + '"';
57168    }
57169  }
57170  markup += ">";
57171  for (var i = 0; i < this.children.length; i++) {
57172    markup += this.children[i].toMarkup();
57173  }
57174  markup += "</" + tagName + ">";
57175  return markup;
57176};
57177var Span = class {
57178  constructor(classes2, children, options2, style) {
57179    this.children = void 0;
57180    this.attributes = void 0;
57181    this.classes = void 0;
57182    this.height = void 0;
57183    this.depth = void 0;
57184    this.width = void 0;
57185    this.maxFontSize = void 0;
57186    this.style = void 0;
57187    initNode.call(this, classes2, options2, style);
57188    this.children = children || [];
57189  }
57190  /**
57191   * Sets an arbitrary attribute on the span. Warning: use this wisely. Not
57192   * all browsers support attributes the same, and having too many custom
57193   * attributes is probably bad.
57194   */
57195  setAttribute(attribute, value) {
57196    this.attributes[attribute] = value;
57197  }
57198  hasClass(className) {
57199    return utils.contains(this.classes, className);
57200  }
57201  toNode() {
57202    return toNode.call(this, "span");
57203  }
57204  toMarkup() {
57205    return toMarkup.call(this, "span");
57206  }
57207};
57208var Anchor = class {
57209  constructor(href, classes2, children, options2) {
57210    this.children = void 0;
57211    this.attributes = void 0;
57212    this.classes = void 0;
57213    this.height = void 0;
57214    this.depth = void 0;
57215    this.maxFontSize = void 0;
57216    this.style = void 0;
57217    initNode.call(this, classes2, options2);
57218    this.children = children || [];
57219    this.setAttribute("href", href);
57220  }
57221  setAttribute(attribute, value) {
57222    this.attributes[attribute] = value;
57223  }
57224  hasClass(className) {
57225    return utils.contains(this.classes, className);
57226  }
57227  toNode() {
57228    return toNode.call(this, "a");
57229  }
57230  toMarkup() {
57231    return toMarkup.call(this, "a");
57232  }
57233};
57234var Img = class {
57235  constructor(src, alt, style) {
57236    this.src = void 0;
57237    this.alt = void 0;
57238    this.classes = void 0;
57239    this.height = void 0;
57240    this.depth = void 0;
57241    this.maxFontSize = void 0;
57242    this.style = void 0;
57243    this.alt = alt;
57244    this.src = src;
57245    this.classes = ["mord"];
57246    this.style = style;
57247  }
57248  hasClass(className) {
57249    return utils.contains(this.classes, className);
57250  }
57251  toNode() {
57252    var node = document.createElement("img");
57253    node.src = this.src;
57254    node.alt = this.alt;
57255    node.className = "mord";
57256    for (var style in this.style) {
57257      if (this.style.hasOwnProperty(style)) {
57258        node.style[style] = this.style[style];
57259      }
57260    }
57261    return node;
57262  }
57263  toMarkup() {
57264    var markup = '<img src="' + utils.escape(this.src) + '"' + (' alt="' + utils.escape(this.alt) + '"');
57265    var styles2 = "";
57266    for (var style in this.style) {
57267      if (this.style.hasOwnProperty(style)) {
57268        styles2 += utils.hyphenate(style) + ":" + this.style[style] + ";";
57269      }
57270    }
57271    if (styles2) {
57272      markup += ' style="' + utils.escape(styles2) + '"';
57273    }
57274    markup += "'/>";
57275    return markup;
57276  }
57277};
57278var iCombinations = {
57279  "\xEE": "\u0131\u0302",
57280  "\xEF": "\u0131\u0308",
57281  "\xED": "\u0131\u0301",
57282  // 'Ä«': '\u0131\u0304', // enable when we add Extended Latin
57283  "\xEC": "\u0131\u0300"
57284};
57285var SymbolNode = class {
57286  constructor(text2, height, depth, italic, skew, width, classes2, style) {
57287    this.text = void 0;
57288    this.height = void 0;
57289    this.depth = void 0;
57290    this.italic = void 0;
57291    this.skew = void 0;
57292    this.width = void 0;
57293    this.maxFontSize = void 0;
57294    this.classes = void 0;
57295    this.style = void 0;
57296    this.text = text2;
57297    this.height = height || 0;
57298    this.depth = depth || 0;
57299    this.italic = italic || 0;
57300    this.skew = skew || 0;
57301    this.width = width || 0;
57302    this.classes = classes2 || [];
57303    this.style = style || {};
57304    this.maxFontSize = 0;
57305    var script = scriptFromCodepoint(this.text.charCodeAt(0));
57306    if (script) {
57307      this.classes.push(script + "_fallback");
57308    }
57309    if (/[îïíì]/.test(this.text)) {
57310      this.text = iCombinations[this.text];
57311    }
57312  }
57313  hasClass(className) {
57314    return utils.contains(this.classes, className);
57315  }
57316  /**
57317   * Creates a text node or span from a symbol node. Note that a span is only
57318   * created if it is needed.
57319   */
57320  toNode() {
57321    var node = document.createTextNode(this.text);
57322    var span = null;
57323    if (this.italic > 0) {
57324      span = document.createElement("span");
57325      span.style.marginRight = makeEm(this.italic);
57326    }
57327    if (this.classes.length > 0) {
57328      span = span || document.createElement("span");
57329      span.className = createClass(this.classes);
57330    }
57331    for (var style in this.style) {
57332      if (this.style.hasOwnProperty(style)) {
57333        span = span || document.createElement("span");
57334        span.style[style] = this.style[style];
57335      }
57336    }
57337    if (span) {
57338      span.appendChild(node);
57339      return span;
57340    } else {
57341      return node;
57342    }
57343  }
57344  /**
57345   * Creates markup for a symbol node.
57346   */
57347  toMarkup() {
57348    var needsSpan = false;
57349    var markup = "<span";
57350    if (this.classes.length) {
57351      needsSpan = true;
57352      markup += ' class="';
57353      markup += utils.escape(createClass(this.classes));
57354      markup += '"';
57355    }
57356    var styles2 = "";
57357    if (this.italic > 0) {
57358      styles2 += "margin-right:" + this.italic + "em;";
57359    }
57360    for (var style in this.style) {
57361      if (this.style.hasOwnProperty(style)) {
57362        styles2 += utils.hyphenate(style) + ":" + this.style[style] + ";";
57363      }
57364    }
57365    if (styles2) {
57366      needsSpan = true;
57367      markup += ' style="' + utils.escape(styles2) + '"';
57368    }
57369    var escaped = utils.escape(this.text);
57370    if (needsSpan) {
57371      markup += ">";
57372      markup += escaped;
57373      markup += "</span>";
57374      return markup;
57375    } else {
57376      return escaped;
57377    }
57378  }
57379};
57380var SvgNode = class {
57381  constructor(children, attributes) {
57382    this.children = void 0;
57383    this.attributes = void 0;
57384    this.children = children || [];
57385    this.attributes = attributes || {};
57386  }
57387  toNode() {
57388    var svgNS = "http://www.w3.org/2000/svg";
57389    var node = document.createElementNS(svgNS, "svg");
57390    for (var attr in this.attributes) {
57391      if (Object.prototype.hasOwnProperty.call(this.attributes, attr)) {
57392        node.setAttribute(attr, this.attributes[attr]);
57393      }
57394    }
57395    for (var i = 0; i < this.children.length; i++) {
57396      node.appendChild(this.children[i].toNode());
57397    }
57398    return node;
57399  }
57400  toMarkup() {
57401    var markup = '<svg xmlns="http://www.w3.org/2000/svg"';
57402    for (var attr in this.attributes) {
57403      if (Object.prototype.hasOwnProperty.call(this.attributes, attr)) {
57404        markup += " " + attr + '="' + utils.escape(this.attributes[attr]) + '"';
57405      }
57406    }
57407    markup += ">";
57408    for (var i = 0; i < this.children.length; i++) {
57409      markup += this.children[i].toMarkup();
57410    }
57411    markup += "</svg>";
57412    return markup;
57413  }
57414};
57415var PathNode = class {
57416  constructor(pathName, alternate) {
57417    this.pathName = void 0;
57418    this.alternate = void 0;
57419    this.pathName = pathName;
57420    this.alternate = alternate;
57421  }
57422  toNode() {
57423    var svgNS = "http://www.w3.org/2000/svg";
57424    var node = document.createElementNS(svgNS, "path");
57425    if (this.alternate) {
57426      node.setAttribute("d", this.alternate);
57427    } else {
57428      node.setAttribute("d", path[this.pathName]);
57429    }
57430    return node;
57431  }
57432  toMarkup() {
57433    if (this.alternate) {
57434      return '<path d="' + utils.escape(this.alternate) + '"/>';
57435    } else {
57436      return '<path d="' + utils.escape(path[this.pathName]) + '"/>';
57437    }
57438  }
57439};
57440var LineNode = class {
57441  constructor(attributes) {
57442    this.attributes = void 0;
57443    this.attributes = attributes || {};
57444  }
57445  toNode() {
57446    var svgNS = "http://www.w3.org/2000/svg";
57447    var node = document.createElementNS(svgNS, "line");
57448    for (var attr in this.attributes) {
57449      if (Object.prototype.hasOwnProperty.call(this.attributes, attr)) {
57450        node.setAttribute(attr, this.attributes[attr]);
57451      }
57452    }
57453    return node;
57454  }
57455  toMarkup() {
57456    var markup = "<line";
57457    for (var attr in this.attributes) {
57458      if (Object.prototype.hasOwnProperty.call(this.attributes, attr)) {
57459        markup += " " + attr + '="' + utils.escape(this.attributes[attr]) + '"';
57460      }
57461    }
57462    markup += "/>";
57463    return markup;
57464  }
57465};
57466function assertSymbolDomNode(group) {
57467  if (group instanceof SymbolNode) {
57468    return group;
57469  } else {
57470    throw new Error("Expected symbolNode but got " + String(group) + ".");
57471  }
57472}
57473function assertSpan(group) {
57474  if (group instanceof Span) {
57475    return group;
57476  } else {
57477    throw new Error("Expected span<HtmlDomNode> but got " + String(group) + ".");
57478  }
57479}
57480var ATOMS = {
57481  "bin": 1,
57482  "close": 1,
57483  "inner": 1,
57484  "open": 1,
57485  "punct": 1,
57486  "rel": 1
57487};
57488var NON_ATOMS = {
57489  "accent-token": 1,
57490  "mathord": 1,
57491  "op-token": 1,
57492  "spacing": 1,
57493  "textord": 1
57494};
57495var symbols = {
57496  "math": {},
57497  "text": {}
57498};
57499function defineSymbol(mode, font, group, replace, name, acceptUnicodeChar) {
57500  symbols[mode][name] = {
57501    font,
57502    group,
57503    replace
57504  };
57505  if (acceptUnicodeChar && replace) {
57506    symbols[mode][replace] = symbols[mode][name];
57507  }
57508}
57509var math = "math";
57510var text = "text";
57511var main = "main";
57512var ams = "ams";
57513var accent = "accent-token";
57514var bin = "bin";
57515var close = "close";
57516var inner = "inner";
57517var mathord = "mathord";
57518var op = "op-token";
57519var open = "open";
57520var punct = "punct";
57521var rel = "rel";
57522var spacing = "spacing";
57523var textord = "textord";
57524defineSymbol(math, main, rel, "\u2261", "\\equiv", true);
57525defineSymbol(math, main, rel, "\u227A", "\\prec", true);
57526defineSymbol(math, main, rel, "\u227B", "\\succ", true);
57527defineSymbol(math, main, rel, "\u223C", "\\sim", true);
57528defineSymbol(math, main, rel, "\u22A5", "\\perp");
57529defineSymbol(math, main, rel, "\u2AAF", "\\preceq", true);
57530defineSymbol(math, main, rel, "\u2AB0", "\\succeq", true);
57531defineSymbol(math, main, rel, "\u2243", "\\simeq", true);
57532defineSymbol(math, main, rel, "\u2223", "\\mid", true);
57533defineSymbol(math, main, rel, "\u226A", "\\ll", true);
57534defineSymbol(math, main, rel, "\u226B", "\\gg", true);
57535defineSymbol(math, main, rel, "\u224D", "\\asymp", true);
57536defineSymbol(math, main, rel, "\u2225", "\\parallel");
57537defineSymbol(math, main, rel, "\u22C8", "\\bowtie", true);
57538defineSymbol(math, main, rel, "\u2323", "\\smile", true);
57539defineSymbol(math, main, rel, "\u2291", "\\sqsubseteq", true);
57540defineSymbol(math, main, rel, "\u2292", "\\sqsupseteq", true);
57541defineSymbol(math, main, rel, "\u2250", "\\doteq", true);
57542defineSymbol(math, main, rel, "\u2322", "\\frown", true);
57543defineSymbol(math, main, rel, "\u220B", "\\ni", true);
57544defineSymbol(math, main, rel, "\u221D", "\\propto", true);
57545defineSymbol(math, main, rel, "\u22A2", "\\vdash", true);
57546defineSymbol(math, main, rel, "\u22A3", "\\dashv", true);
57547defineSymbol(math, main, rel, "\u220B", "\\owns");
57548defineSymbol(math, main, punct, ".", "\\ldotp");
57549defineSymbol(math, main, punct, "\u22C5", "\\cdotp");
57550defineSymbol(math, main, textord, "#", "\\#");
57551defineSymbol(text, main, textord, "#", "\\#");
57552defineSymbol(math, main, textord, "&", "\\&");
57553defineSymbol(text, main, textord, "&", "\\&");
57554defineSymbol(math, main, textord, "\u2135", "\\aleph", true);
57555defineSymbol(math, main, textord, "\u2200", "\\forall", true);
57556defineSymbol(math, main, textord, "\u210F", "\\hbar", true);
57557defineSymbol(math, main, textord, "\u2203", "\\exists", true);
57558defineSymbol(math, main, textord, "\u2207", "\\nabla", true);
57559defineSymbol(math, main, textord, "\u266D", "\\flat", true);
57560defineSymbol(math, main, textord, "\u2113", "\\ell", true);
57561defineSymbol(math, main, textord, "\u266E", "\\natural", true);
57562defineSymbol(math, main, textord, "\u2663", "\\clubsuit", true);
57563defineSymbol(math, main, textord, "\u2118", "\\wp", true);
57564defineSymbol(math, main, textord, "\u266F", "\\sharp", true);
57565defineSymbol(math, main, textord, "\u2662", "\\diamondsuit", true);
57566defineSymbol(math, main, textord, "\u211C", "\\Re", true);
57567defineSymbol(math, main, textord, "\u2661", "\\heartsuit", true);
57568defineSymbol(math, main, textord, "\u2111", "\\Im", true);
57569defineSymbol(math, main, textord, "\u2660", "\\spadesuit", true);
57570defineSymbol(math, main, textord, "\xA7", "\\S", true);
57571defineSymbol(text, main, textord, "\xA7", "\\S");
57572defineSymbol(math, main, textord, "\xB6", "\\P", true);
57573defineSymbol(text, main, textord, "\xB6", "\\P");
57574defineSymbol(math, main, textord, "\u2020", "\\dag");
57575defineSymbol(text, main, textord, "\u2020", "\\dag");
57576defineSymbol(text, main, textord, "\u2020", "\\textdagger");
57577defineSymbol(math, main, textord, "\u2021", "\\ddag");
57578defineSymbol(text, main, textord, "\u2021", "\\ddag");
57579defineSymbol(text, main, textord, "\u2021", "\\textdaggerdbl");
57580defineSymbol(math, main, close, "\u23B1", "\\rmoustache", true);
57581defineSymbol(math, main, open, "\u23B0", "\\lmoustache", true);
57582defineSymbol(math, main, close, "\u27EF", "\\rgroup", true);
57583defineSymbol(math, main, open, "\u27EE", "\\lgroup", true);
57584defineSymbol(math, main, bin, "\u2213", "\\mp", true);
57585defineSymbol(math, main, bin, "\u2296", "\\ominus", true);
57586defineSymbol(math, main, bin, "\u228E", "\\uplus", true);
57587defineSymbol(math, main, bin, "\u2293", "\\sqcap", true);
57588defineSymbol(math, main, bin, "\u2217", "\\ast");
57589defineSymbol(math, main, bin, "\u2294", "\\sqcup", true);
57590defineSymbol(math, main, bin, "\u25EF", "\\bigcirc", true);
57591defineSymbol(math, main, bin, "\u2219", "\\bullet", true);
57592defineSymbol(math, main, bin, "\u2021", "\\ddagger");
57593defineSymbol(math, main, bin, "\u2240", "\\wr", true);
57594defineSymbol(math, main, bin, "\u2A3F", "\\amalg");
57595defineSymbol(math, main, bin, "&", "\\And");
57596defineSymbol(math, main, rel, "\u27F5", "\\longleftarrow", true);
57597defineSymbol(math, main, rel, "\u21D0", "\\Leftarrow", true);
57598defineSymbol(math, main, rel, "\u27F8", "\\Longleftarrow", true);
57599defineSymbol(math, main, rel, "\u27F6", "\\longrightarrow", true);
57600defineSymbol(math, main, rel, "\u21D2", "\\Rightarrow", true);
57601defineSymbol(math, main, rel, "\u27F9", "\\Longrightarrow", true);
57602defineSymbol(math, main, rel, "\u2194", "\\leftrightarrow", true);
57603defineSymbol(math, main, rel, "\u27F7", "\\longleftrightarrow", true);
57604defineSymbol(math, main, rel, "\u21D4", "\\Leftrightarrow", true);
57605defineSymbol(math, main, rel, "\u27FA", "\\Longleftrightarrow", true);
57606defineSymbol(math, main, rel, "\u21A6", "\\mapsto", true);
57607defineSymbol(math, main, rel, "\u27FC", "\\longmapsto", true);
57608defineSymbol(math, main, rel, "\u2197", "\\nearrow", true);
57609defineSymbol(math, main, rel, "\u21A9", "\\hookleftarrow", true);
57610defineSymbol(math, main, rel, "\u21AA", "\\hookrightarrow", true);
57611defineSymbol(math, main, rel, "\u2198", "\\searrow", true);
57612defineSymbol(math, main, rel, "\u21BC", "\\leftharpoonup", true);
57613defineSymbol(math, main, rel, "\u21C0", "\\rightharpoonup", true);
57614defineSymbol(math, main, rel, "\u2199", "\\swarrow", true);
57615defineSymbol(math, main, rel, "\u21BD", "\\leftharpoondown", true);
57616defineSymbol(math, main, rel, "\u21C1", "\\rightharpoondown", true);
57617defineSymbol(math, main, rel, "\u2196", "\\nwarrow", true);
57618defineSymbol(math, main, rel, "\u21CC", "\\rightleftharpoons", true);
57619defineSymbol(math, ams, rel, "\u226E", "\\nless", true);
57620defineSymbol(math, ams, rel, "\uE010", "\\@nleqslant");
57621defineSymbol(math, ams, rel, "\uE011", "\\@nleqq");
57622defineSymbol(math, ams, rel, "\u2A87", "\\lneq", true);
57623defineSymbol(math, ams, rel, "\u2268", "\\lneqq", true);
57624defineSymbol(math, ams, rel, "\uE00C", "\\@lvertneqq");
57625defineSymbol(math, ams, rel, "\u22E6", "\\lnsim", true);
57626defineSymbol(math, ams, rel, "\u2A89", "\\lnapprox", true);
57627defineSymbol(math, ams, rel, "\u2280", "\\nprec", true);
57628defineSymbol(math, ams, rel, "\u22E0", "\\npreceq", true);
57629defineSymbol(math, ams, rel, "\u22E8", "\\precnsim", true);
57630defineSymbol(math, ams, rel, "\u2AB9", "\\precnapprox", true);
57631defineSymbol(math, ams, rel, "\u2241", "\\nsim", true);
57632defineSymbol(math, ams, rel, "\uE006", "\\@nshortmid");
57633defineSymbol(math, ams, rel, "\u2224", "\\nmid", true);
57634defineSymbol(math, ams, rel, "\u22AC", "\\nvdash", true);
57635defineSymbol(math, ams, rel, "\u22AD", "\\nvDash", true);
57636defineSymbol(math, ams, rel, "\u22EA", "\\ntriangleleft");
57637defineSymbol(math, ams, rel, "\u22EC", "\\ntrianglelefteq", true);
57638defineSymbol(math, ams, rel, "\u228A", "\\subsetneq", true);
57639defineSymbol(math, ams, rel, "\uE01A", "\\@varsubsetneq");
57640defineSymbol(math, ams, rel, "\u2ACB", "\\subsetneqq", true);
57641defineSymbol(math, ams, rel, "\uE017", "\\@varsubsetneqq");
57642defineSymbol(math, ams, rel, "\u226F", "\\ngtr", true);
57643defineSymbol(math, ams, rel, "\uE00F", "\\@ngeqslant");
57644defineSymbol(math, ams, rel, "\uE00E", "\\@ngeqq");
57645defineSymbol(math, ams, rel, "\u2A88", "\\gneq", true);
57646defineSymbol(math, ams, rel, "\u2269", "\\gneqq", true);
57647defineSymbol(math, ams, rel, "\uE00D", "\\@gvertneqq");
57648defineSymbol(math, ams, rel, "\u22E7", "\\gnsim", true);
57649defineSymbol(math, ams, rel, "\u2A8A", "\\gnapprox", true);
57650defineSymbol(math, ams, rel, "\u2281", "\\nsucc", true);
57651defineSymbol(math, ams, rel, "\u22E1", "\\nsucceq", true);
57652defineSymbol(math, ams, rel, "\u22E9", "\\succnsim", true);
57653defineSymbol(math, ams, rel, "\u2ABA", "\\succnapprox", true);
57654defineSymbol(math, ams, rel, "\u2246", "\\ncong", true);
57655defineSymbol(math, ams, rel, "\uE007", "\\@nshortparallel");
57656defineSymbol(math, ams, rel, "\u2226", "\\nparallel", true);
57657defineSymbol(math, ams, rel, "\u22AF", "\\nVDash", true);
57658defineSymbol(math, ams, rel, "\u22EB", "\\ntriangleright");
57659defineSymbol(math, ams, rel, "\u22ED", "\\ntrianglerighteq", true);
57660defineSymbol(math, ams, rel, "\uE018", "\\@nsupseteqq");
57661defineSymbol(math, ams, rel, "\u228B", "\\supsetneq", true);
57662defineSymbol(math, ams, rel, "\uE01B", "\\@varsupsetneq");
57663defineSymbol(math, ams, rel, "\u2ACC", "\\supsetneqq", true);
57664defineSymbol(math, ams, rel, "\uE019", "\\@varsupsetneqq");
57665defineSymbol(math, ams, rel, "\u22AE", "\\nVdash", true);
57666defineSymbol(math, ams, rel, "\u2AB5", "\\precneqq", true);
57667defineSymbol(math, ams, rel, "\u2AB6", "\\succneqq", true);
57668defineSymbol(math, ams, rel, "\uE016", "\\@nsubseteqq");
57669defineSymbol(math, ams, bin, "\u22B4", "\\unlhd");
57670defineSymbol(math, ams, bin, "\u22B5", "\\unrhd");
57671defineSymbol(math, ams, rel, "\u219A", "\\nleftarrow", true);
57672defineSymbol(math, ams, rel, "\u219B", "\\nrightarrow", true);
57673defineSymbol(math, ams, rel, "\u21CD", "\\nLeftarrow", true);
57674defineSymbol(math, ams, rel, "\u21CF", "\\nRightarrow", true);
57675defineSymbol(math, ams, rel, "\u21AE", "\\nleftrightarrow", true);
57676defineSymbol(math, ams, rel, "\u21CE", "\\nLeftrightarrow", true);
57677defineSymbol(math, ams, rel, "\u25B3", "\\vartriangle");
57678defineSymbol(math, ams, textord, "\u210F", "\\hslash");
57679defineSymbol(math, ams, textord, "\u25BD", "\\triangledown");
57680defineSymbol(math, ams, textord, "\u25CA", "\\lozenge");
57681defineSymbol(math, ams, textord, "\u24C8", "\\circledS");
57682defineSymbol(math, ams, textord, "\xAE", "\\circledR");
57683defineSymbol(text, ams, textord, "\xAE", "\\circledR");
57684defineSymbol(math, ams, textord, "\u2221", "\\measuredangle", true);
57685defineSymbol(math, ams, textord, "\u2204", "\\nexists");
57686defineSymbol(math, ams, textord, "\u2127", "\\mho");
57687defineSymbol(math, ams, textord, "\u2132", "\\Finv", true);
57688defineSymbol(math, ams, textord, "\u2141", "\\Game", true);
57689defineSymbol(math, ams, textord, "\u2035", "\\backprime");
57690defineSymbol(math, ams, textord, "\u25B2", "\\blacktriangle");
57691defineSymbol(math, ams, textord, "\u25BC", "\\blacktriangledown");
57692defineSymbol(math, ams, textord, "\u25A0", "\\blacksquare");
57693defineSymbol(math, ams, textord, "\u29EB", "\\blacklozenge");
57694defineSymbol(math, ams, textord, "\u2605", "\\bigstar");
57695defineSymbol(math, ams, textord, "\u2222", "\\sphericalangle", true);
57696defineSymbol(math, ams, textord, "\u2201", "\\complement", true);
57697defineSymbol(math, ams, textord, "\xF0", "\\eth", true);
57698defineSymbol(text, main, textord, "\xF0", "\xF0");
57699defineSymbol(math, ams, textord, "\u2571", "\\diagup");
57700defineSymbol(math, ams, textord, "\u2572", "\\diagdown");
57701defineSymbol(math, ams, textord, "\u25A1", "\\square");
57702defineSymbol(math, ams, textord, "\u25A1", "\\Box");
57703defineSymbol(math, ams, textord, "\u25CA", "\\Diamond");
57704defineSymbol(math, ams, textord, "\xA5", "\\yen", true);
57705defineSymbol(text, ams, textord, "\xA5", "\\yen", true);
57706defineSymbol(math, ams, textord, "\u2713", "\\checkmark", true);
57707defineSymbol(text, ams, textord, "\u2713", "\\checkmark");
57708defineSymbol(math, ams, textord, "\u2136", "\\beth", true);
57709defineSymbol(math, ams, textord, "\u2138", "\\daleth", true);
57710defineSymbol(math, ams, textord, "\u2137", "\\gimel", true);
57711defineSymbol(math, ams, textord, "\u03DD", "\\digamma", true);
57712defineSymbol(math, ams, textord, "\u03F0", "\\varkappa");
57713defineSymbol(math, ams, open, "\u250C", "\\@ulcorner", true);
57714defineSymbol(math, ams, close, "\u2510", "\\@urcorner", true);
57715defineSymbol(math, ams, open, "\u2514", "\\@llcorner", true);
57716defineSymbol(math, ams, close, "\u2518", "\\@lrcorner", true);
57717defineSymbol(math, ams, rel, "\u2266", "\\leqq", true);
57718defineSymbol(math, ams, rel, "\u2A7D", "\\leqslant", true);
57719defineSymbol(math, ams, rel, "\u2A95", "\\eqslantless", true);
57720defineSymbol(math, ams, rel, "\u2272", "\\lesssim", true);
57721defineSymbol(math, ams, rel, "\u2A85", "\\lessapprox", true);
57722defineSymbol(math, ams, rel, "\u224A", "\\approxeq", true);
57723defineSymbol(math, ams, bin, "\u22D6", "\\lessdot");
57724defineSymbol(math, ams, rel, "\u22D8", "\\lll", true);
57725defineSymbol(math, ams, rel, "\u2276", "\\lessgtr", true);
57726defineSymbol(math, ams, rel, "\u22DA", "\\lesseqgtr", true);
57727defineSymbol(math, ams, rel, "\u2A8B", "\\lesseqqgtr", true);
57728defineSymbol(math, ams, rel, "\u2251", "\\doteqdot");
57729defineSymbol(math, ams, rel, "\u2253", "\\risingdotseq", true);
57730defineSymbol(math, ams, rel, "\u2252", "\\fallingdotseq", true);
57731defineSymbol(math, ams, rel, "\u223D", "\\backsim", true);
57732defineSymbol(math, ams, rel, "\u22CD", "\\backsimeq", true);
57733defineSymbol(math, ams, rel, "\u2AC5", "\\subseteqq", true);
57734defineSymbol(math, ams, rel, "\u22D0", "\\Subset", true);
57735defineSymbol(math, ams, rel, "\u228F", "\\sqsubset", true);
57736defineSymbol(math, ams, rel, "\u227C", "\\preccurlyeq", true);
57737defineSymbol(math, ams, rel, "\u22DE", "\\curlyeqprec", true);
57738defineSymbol(math, ams, rel, "\u227E", "\\precsim", true);
57739defineSymbol(math, ams, rel, "\u2AB7", "\\precapprox", true);
57740defineSymbol(math, ams, rel, "\u22B2", "\\vartriangleleft");
57741defineSymbol(math, ams, rel, "\u22B4", "\\trianglelefteq");
57742defineSymbol(math, ams, rel, "\u22A8", "\\vDash", true);
57743defineSymbol(math, ams, rel, "\u22AA", "\\Vvdash", true);
57744defineSymbol(math, ams, rel, "\u2323", "\\smallsmile");
57745defineSymbol(math, ams, rel, "\u2322", "\\smallfrown");
57746defineSymbol(math, ams, rel, "\u224F", "\\bumpeq", true);
57747defineSymbol(math, ams, rel, "\u224E", "\\Bumpeq", true);
57748defineSymbol(math, ams, rel, "\u2267", "\\geqq", true);
57749defineSymbol(math, ams, rel, "\u2A7E", "\\geqslant", true);
57750defineSymbol(math, ams, rel, "\u2A96", "\\eqslantgtr", true);
57751defineSymbol(math, ams, rel, "\u2273", "\\gtrsim", true);
57752defineSymbol(math, ams, rel, "\u2A86", "\\gtrapprox", true);
57753defineSymbol(math, ams, bin, "\u22D7", "\\gtrdot");
57754defineSymbol(math, ams, rel, "\u22D9", "\\ggg", true);
57755defineSymbol(math, ams, rel, "\u2277", "\\gtrless", true);
57756defineSymbol(math, ams, rel, "\u22DB", "\\gtreqless", true);
57757defineSymbol(math, ams, rel, "\u2A8C", "\\gtreqqless", true);
57758defineSymbol(math, ams, rel, "\u2256", "\\eqcirc", true);
57759defineSymbol(math, ams, rel, "\u2257", "\\circeq", true);
57760defineSymbol(math, ams, rel, "\u225C", "\\triangleq", true);
57761defineSymbol(math, ams, rel, "\u223C", "\\thicksim");
57762defineSymbol(math, ams, rel, "\u2248", "\\thickapprox");
57763defineSymbol(math, ams, rel, "\u2AC6", "\\supseteqq", true);
57764defineSymbol(math, ams, rel, "\u22D1", "\\Supset", true);
57765defineSymbol(math, ams, rel, "\u2290", "\\sqsupset", true);
57766defineSymbol(math, ams, rel, "\u227D", "\\succcurlyeq", true);
57767defineSymbol(math, ams, rel, "\u22DF", "\\curlyeqsucc", true);
57768defineSymbol(math, ams, rel, "\u227F", "\\succsim", true);
57769defineSymbol(math, ams, rel, "\u2AB8", "\\succapprox", true);
57770defineSymbol(math, ams, rel, "\u22B3", "\\vartriangleright");
57771defineSymbol(math, ams, rel, "\u22B5", "\\trianglerighteq");
57772defineSymbol(math, ams, rel, "\u22A9", "\\Vdash", true);
57773defineSymbol(math, ams, rel, "\u2223", "\\shortmid");
57774defineSymbol(math, ams, rel, "\u2225", "\\shortparallel");
57775defineSymbol(math, ams, rel, "\u226C", "\\between", true);
57776defineSymbol(math, ams, rel, "\u22D4", "\\pitchfork", true);
57777defineSymbol(math, ams, rel, "\u221D", "\\varpropto");
57778defineSymbol(math, ams, rel, "\u25C0", "\\blacktriangleleft");
57779defineSymbol(math, ams, rel, "\u2234", "\\therefore", true);
57780defineSymbol(math, ams, rel, "\u220D", "\\backepsilon");
57781defineSymbol(math, ams, rel, "\u25B6", "\\blacktriangleright");
57782defineSymbol(math, ams, rel, "\u2235", "\\because", true);
57783defineSymbol(math, ams, rel, "\u22D8", "\\llless");
57784defineSymbol(math, ams, rel, "\u22D9", "\\gggtr");
57785defineSymbol(math, ams, bin, "\u22B2", "\\lhd");
57786defineSymbol(math, ams, bin, "\u22B3", "\\rhd");
57787defineSymbol(math, ams, rel, "\u2242", "\\eqsim", true);
57788defineSymbol(math, main, rel, "\u22C8", "\\Join");
57789defineSymbol(math, ams, rel, "\u2251", "\\Doteq", true);
57790defineSymbol(math, ams, bin, "\u2214", "\\dotplus", true);
57791defineSymbol(math, ams, bin, "\u2216", "\\smallsetminus");
57792defineSymbol(math, ams, bin, "\u22D2", "\\Cap", true);
57793defineSymbol(math, ams, bin, "\u22D3", "\\Cup", true);
57794defineSymbol(math, ams, bin, "\u2A5E", "\\doublebarwedge", true);
57795defineSymbol(math, ams, bin, "\u229F", "\\boxminus", true);
57796defineSymbol(math, ams, bin, "\u229E", "\\boxplus", true);
57797defineSymbol(math, ams, bin, "\u22C7", "\\divideontimes", true);
57798defineSymbol(math, ams, bin, "\u22C9", "\\ltimes", true);
57799defineSymbol(math, ams, bin, "\u22CA", "\\rtimes", true);
57800defineSymbol(math, ams, bin, "\u22CB", "\\leftthreetimes", true);
57801defineSymbol(math, ams, bin, "\u22CC", "\\rightthreetimes", true);
57802defineSymbol(math, ams, bin, "\u22CF", "\\curlywedge", true);
57803defineSymbol(math, ams, bin, "\u22CE", "\\curlyvee", true);
57804defineSymbol(math, ams, bin, "\u229D", "\\circleddash", true);
57805defineSymbol(math, ams, bin, "\u229B", "\\circledast", true);
57806defineSymbol(math, ams, bin, "\u22C5", "\\centerdot");
57807defineSymbol(math, ams, bin, "\u22BA", "\\intercal", true);
57808defineSymbol(math, ams, bin, "\u22D2", "\\doublecap");
57809defineSymbol(math, ams, bin, "\u22D3", "\\doublecup");
57810defineSymbol(math, ams, bin, "\u22A0", "\\boxtimes", true);
57811defineSymbol(math, ams, rel, "\u21E2", "\\dashrightarrow", true);
57812defineSymbol(math, ams, rel, "\u21E0", "\\dashleftarrow", true);
57813defineSymbol(math, ams, rel, "\u21C7", "\\leftleftarrows", true);
57814defineSymbol(math, ams, rel, "\u21C6", "\\leftrightarrows", true);
57815defineSymbol(math, ams, rel, "\u21DA", "\\Lleftarrow", true);
57816defineSymbol(math, ams, rel, "\u219E", "\\twoheadleftarrow", true);
57817defineSymbol(math, ams, rel, "\u21A2", "\\leftarrowtail", true);
57818defineSymbol(math, ams, rel, "\u21AB", "\\looparrowleft", true);
57819defineSymbol(math, ams, rel, "\u21CB", "\\leftrightharpoons", true);
57820defineSymbol(math, ams, rel, "\u21B6", "\\curvearrowleft", true);
57821defineSymbol(math, ams, rel, "\u21BA", "\\circlearrowleft", true);
57822defineSymbol(math, ams, rel, "\u21B0", "\\Lsh", true);
57823defineSymbol(math, ams, rel, "\u21C8", "\\upuparrows", true);
57824defineSymbol(math, ams, rel, "\u21BF", "\\upharpoonleft", true);
57825defineSymbol(math, ams, rel, "\u21C3", "\\downharpoonleft", true);
57826defineSymbol(math, main, rel, "\u22B6", "\\origof", true);
57827defineSymbol(math, main, rel, "\u22B7", "\\imageof", true);
57828defineSymbol(math, ams, rel, "\u22B8", "\\multimap", true);
57829defineSymbol(math, ams, rel, "\u21AD", "\\leftrightsquigarrow", true);
57830defineSymbol(math, ams, rel, "\u21C9", "\\rightrightarrows", true);
57831defineSymbol(math, ams, rel, "\u21C4", "\\rightleftarrows", true);
57832defineSymbol(math, ams, rel, "\u21A0", "\\twoheadrightarrow", true);
57833defineSymbol(math, ams, rel, "\u21A3", "\\rightarrowtail", true);
57834defineSymbol(math, ams, rel, "\u21AC", "\\looparrowright", true);
57835defineSymbol(math, ams, rel, "\u21B7", "\\curvearrowright", true);
57836defineSymbol(math, ams, rel, "\u21BB", "\\circlearrowright", true);
57837defineSymbol(math, ams, rel, "\u21B1", "\\Rsh", true);
57838defineSymbol(math, ams, rel, "\u21CA", "\\downdownarrows", true);
57839defineSymbol(math, ams, rel, "\u21BE", "\\upharpoonright", true);
57840defineSymbol(math, ams, rel, "\u21C2", "\\downharpoonright", true);
57841defineSymbol(math, ams, rel, "\u21DD", "\\rightsquigarrow", true);
57842defineSymbol(math, ams, rel, "\u21DD", "\\leadsto");
57843defineSymbol(math, ams, rel, "\u21DB", "\\Rrightarrow", true);
57844defineSymbol(math, ams, rel, "\u21BE", "\\restriction");
57845defineSymbol(math, main, textord, "\u2018", "`");
57846defineSymbol(math, main, textord, "$", "\\$");
57847defineSymbol(text, main, textord, "$", "\\$");
57848defineSymbol(text, main, textord, "$", "\\textdollar");
57849defineSymbol(math, main, textord, "%", "\\%");
57850defineSymbol(text, main, textord, "%", "\\%");
57851defineSymbol(math, main, textord, "_", "\\_");
57852defineSymbol(text, main, textord, "_", "\\_");
57853defineSymbol(text, main, textord, "_", "\\textunderscore");
57854defineSymbol(math, main, textord, "\u2220", "\\angle", true);
57855defineSymbol(math, main, textord, "\u221E", "\\infty", true);
57856defineSymbol(math, main, textord, "\u2032", "\\prime");
57857defineSymbol(math, main, textord, "\u25B3", "\\triangle");
57858defineSymbol(math, main, textord, "\u0393", "\\Gamma", true);
57859defineSymbol(math, main, textord, "\u0394", "\\Delta", true);
57860defineSymbol(math, main, textord, "\u0398", "\\Theta", true);
57861defineSymbol(math, main, textord, "\u039B", "\\Lambda", true);
57862defineSymbol(math, main, textord, "\u039E", "\\Xi", true);
57863defineSymbol(math, main, textord, "\u03A0", "\\Pi", true);
57864defineSymbol(math, main, textord, "\u03A3", "\\Sigma", true);
57865defineSymbol(math, main, textord, "\u03A5", "\\Upsilon", true);
57866defineSymbol(math, main, textord, "\u03A6", "\\Phi", true);
57867defineSymbol(math, main, textord, "\u03A8", "\\Psi", true);
57868defineSymbol(math, main, textord, "\u03A9", "\\Omega", true);
57869defineSymbol(math, main, textord, "A", "\u0391");
57870defineSymbol(math, main, textord, "B", "\u0392");
57871defineSymbol(math, main, textord, "E", "\u0395");
57872defineSymbol(math, main, textord, "Z", "\u0396");
57873defineSymbol(math, main, textord, "H", "\u0397");
57874defineSymbol(math, main, textord, "I", "\u0399");
57875defineSymbol(math, main, textord, "K", "\u039A");
57876defineSymbol(math, main, textord, "M", "\u039C");
57877defineSymbol(math, main, textord, "N", "\u039D");
57878defineSymbol(math, main, textord, "O", "\u039F");
57879defineSymbol(math, main, textord, "P", "\u03A1");
57880defineSymbol(math, main, textord, "T", "\u03A4");
57881defineSymbol(math, main, textord, "X", "\u03A7");
57882defineSymbol(math, main, textord, "\xAC", "\\neg", true);
57883defineSymbol(math, main, textord, "\xAC", "\\lnot");
57884defineSymbol(math, main, textord, "\u22A4", "\\top");
57885defineSymbol(math, main, textord, "\u22A5", "\\bot");
57886defineSymbol(math, main, textord, "\u2205", "\\emptyset");
57887defineSymbol(math, ams, textord, "\u2205", "\\varnothing");
57888defineSymbol(math, main, mathord, "\u03B1", "\\alpha", true);
57889defineSymbol(math, main, mathord, "\u03B2", "\\beta", true);
57890defineSymbol(math, main, mathord, "\u03B3", "\\gamma", true);
57891defineSymbol(math, main, mathord, "\u03B4", "\\delta", true);
57892defineSymbol(math, main, mathord, "\u03F5", "\\epsilon", true);
57893defineSymbol(math, main, mathord, "\u03B6", "\\zeta", true);
57894defineSymbol(math, main, mathord, "\u03B7", "\\eta", true);
57895defineSymbol(math, main, mathord, "\u03B8", "\\theta", true);
57896defineSymbol(math, main, mathord, "\u03B9", "\\iota", true);
57897defineSymbol(math, main, mathord, "\u03BA", "\\kappa", true);
57898defineSymbol(math, main, mathord, "\u03BB", "\\lambda", true);
57899defineSymbol(math, main, mathord, "\u03BC", "\\mu", true);
57900defineSymbol(math, main, mathord, "\u03BD", "\\nu", true);
57901defineSymbol(math, main, mathord, "\u03BE", "\\xi", true);
57902defineSymbol(math, main, mathord, "\u03BF", "\\omicron", true);
57903defineSymbol(math, main, mathord, "\u03C0", "\\pi", true);
57904defineSymbol(math, main, mathord, "\u03C1", "\\rho", true);
57905defineSymbol(math, main, mathord, "\u03C3", "\\sigma", true);
57906defineSymbol(math, main, mathord, "\u03C4", "\\tau", true);
57907defineSymbol(math, main, mathord, "\u03C5", "\\upsilon", true);
57908defineSymbol(math, main, mathord, "\u03D5", "\\phi", true);
57909defineSymbol(math, main, mathord, "\u03C7", "\\chi", true);
57910defineSymbol(math, main, mathord, "\u03C8", "\\psi", true);
57911defineSymbol(math, main, mathord, "\u03C9", "\\omega", true);
57912defineSymbol(math, main, mathord, "\u03B5", "\\varepsilon", true);
57913defineSymbol(math, main, mathord, "\u03D1", "\\vartheta", true);
57914defineSymbol(math, main, mathord, "\u03D6", "\\varpi", true);
57915defineSymbol(math, main, mathord, "\u03F1", "\\varrho", true);
57916defineSymbol(math, main, mathord, "\u03C2", "\\varsigma", true);
57917defineSymbol(math, main, mathord, "\u03C6", "\\varphi", true);
57918defineSymbol(math, main, bin, "\u2217", "*", true);
57919defineSymbol(math, main, bin, "+", "+");
57920defineSymbol(math, main, bin, "\u2212", "-", true);
57921defineSymbol(math, main, bin, "\u22C5", "\\cdot", true);
57922defineSymbol(math, main, bin, "\u2218", "\\circ", true);
57923defineSymbol(math, main, bin, "\xF7", "\\div", true);
57924defineSymbol(math, main, bin, "\xB1", "\\pm", true);
57925defineSymbol(math, main, bin, "\xD7", "\\times", true);
57926defineSymbol(math, main, bin, "\u2229", "\\cap", true);
57927defineSymbol(math, main, bin, "\u222A", "\\cup", true);
57928defineSymbol(math, main, bin, "\u2216", "\\setminus", true);
57929defineSymbol(math, main, bin, "\u2227", "\\land");
57930defineSymbol(math, main, bin, "\u2228", "\\lor");
57931defineSymbol(math, main, bin, "\u2227", "\\wedge", true);
57932defineSymbol(math, main, bin, "\u2228", "\\vee", true);
57933defineSymbol(math, main, textord, "\u221A", "\\surd");
57934defineSymbol(math, main, open, "\u27E8", "\\langle", true);
57935defineSymbol(math, main, open, "\u2223", "\\lvert");
57936defineSymbol(math, main, open, "\u2225", "\\lVert");
57937defineSymbol(math, main, close, "?", "?");
57938defineSymbol(math, main, close, "!", "!");
57939defineSymbol(math, main, close, "\u27E9", "\\rangle", true);
57940defineSymbol(math, main, close, "\u2223", "\\rvert");
57941defineSymbol(math, main, close, "\u2225", "\\rVert");
57942defineSymbol(math, main, rel, "=", "=");
57943defineSymbol(math, main, rel, ":", ":");
57944defineSymbol(math, main, rel, "\u2248", "\\approx", true);
57945defineSymbol(math, main, rel, "\u2245", "\\cong", true);
57946defineSymbol(math, main, rel, "\u2265", "\\ge");
57947defineSymbol(math, main, rel, "\u2265", "\\geq", true);
57948defineSymbol(math, main, rel, "\u2190", "\\gets");
57949defineSymbol(math, main, rel, ">", "\\gt", true);
57950defineSymbol(math, main, rel, "\u2208", "\\in", true);
57951defineSymbol(math, main, rel, "\uE020", "\\@not");
57952defineSymbol(math, main, rel, "\u2282", "\\subset", true);
57953defineSymbol(math, main, rel, "\u2283", "\\supset", true);
57954defineSymbol(math, main, rel, "\u2286", "\\subseteq", true);
57955defineSymbol(math, main, rel, "\u2287", "\\supseteq", true);
57956defineSymbol(math, ams, rel, "\u2288", "\\nsubseteq", true);
57957defineSymbol(math, ams, rel, "\u2289", "\\nsupseteq", true);
57958defineSymbol(math, main, rel, "\u22A8", "\\models");
57959defineSymbol(math, main, rel, "\u2190", "\\leftarrow", true);
57960defineSymbol(math, main, rel, "\u2264", "\\le");
57961defineSymbol(math, main, rel, "\u2264", "\\leq", true);
57962defineSymbol(math, main, rel, "<", "\\lt", true);
57963defineSymbol(math, main, rel, "\u2192", "\\rightarrow", true);
57964defineSymbol(math, main, rel, "\u2192", "\\to");
57965defineSymbol(math, ams, rel, "\u2271", "\\ngeq", true);
57966defineSymbol(math, ams, rel, "\u2270", "\\nleq", true);
57967defineSymbol(math, main, spacing, "\xA0", "\\ ");
57968defineSymbol(math, main, spacing, "\xA0", "\\space");
57969defineSymbol(math, main, spacing, "\xA0", "\\nobreakspace");
57970defineSymbol(text, main, spacing, "\xA0", "\\ ");
57971defineSymbol(text, main, spacing, "\xA0", " ");
57972defineSymbol(text, main, spacing, "\xA0", "\\space");
57973defineSymbol(text, main, spacing, "\xA0", "\\nobreakspace");
57974defineSymbol(math, main, spacing, null, "\\nobreak");
57975defineSymbol(math, main, spacing, null, "\\allowbreak");
57976defineSymbol(math, main, punct, ",", ",");
57977defineSymbol(math, main, punct, ";", ";");
57978defineSymbol(math, ams, bin, "\u22BC", "\\barwedge", true);
57979defineSymbol(math, ams, bin, "\u22BB", "\\veebar", true);
57980defineSymbol(math, main, bin, "\u2299", "\\odot", true);
57981defineSymbol(math, main, bin, "\u2295", "\\oplus", true);
57982defineSymbol(math, main, bin, "\u2297", "\\otimes", true);
57983defineSymbol(math, main, textord, "\u2202", "\\partial", true);
57984defineSymbol(math, main, bin, "\u2298", "\\oslash", true);
57985defineSymbol(math, ams, bin, "\u229A", "\\circledcirc", true);
57986defineSymbol(math, ams, bin, "\u22A1", "\\boxdot", true);
57987defineSymbol(math, main, bin, "\u25B3", "\\bigtriangleup");
57988defineSymbol(math, main, bin, "\u25BD", "\\bigtriangledown");
57989defineSymbol(math, main, bin, "\u2020", "\\dagger");
57990defineSymbol(math, main, bin, "\u22C4", "\\diamond");
57991defineSymbol(math, main, bin, "\u22C6", "\\star");
57992defineSymbol(math, main, bin, "\u25C3", "\\triangleleft");
57993defineSymbol(math, main, bin, "\u25B9", "\\triangleright");
57994defineSymbol(math, main, open, "{", "\\{");
57995defineSymbol(text, main, textord, "{", "\\{");
57996defineSymbol(text, main, textord, "{", "\\textbraceleft");
57997defineSymbol(math, main, close, "}", "\\}");
57998defineSymbol(text, main, textord, "}", "\\}");
57999defineSymbol(text, main, textord, "}", "\\textbraceright");
58000defineSymbol(math, main, open, "{", "\\lbrace");
58001defineSymbol(math, main, close, "}", "\\rbrace");
58002defineSymbol(math, main, open, "[", "\\lbrack", true);
58003defineSymbol(text, main, textord, "[", "\\lbrack", true);
58004defineSymbol(math, main, close, "]", "\\rbrack", true);
58005defineSymbol(text, main, textord, "]", "\\rbrack", true);
58006defineSymbol(math, main, open, "(", "\\lparen", true);
58007defineSymbol(math, main, close, ")", "\\rparen", true);
58008defineSymbol(text, main, textord, "<", "\\textless", true);
58009defineSymbol(text, main, textord, ">", "\\textgreater", true);
58010defineSymbol(math, main, open, "\u230A", "\\lfloor", true);
58011defineSymbol(math, main, close, "\u230B", "\\rfloor", true);
58012defineSymbol(math, main, open, "\u2308", "\\lceil", true);
58013defineSymbol(math, main, close, "\u2309", "\\rceil", true);
58014defineSymbol(math, main, textord, "\\", "\\backslash");
58015defineSymbol(math, main, textord, "\u2223", "|");
58016defineSymbol(math, main, textord, "\u2223", "\\vert");
58017defineSymbol(text, main, textord, "|", "\\textbar", true);
58018defineSymbol(math, main, textord, "\u2225", "\\|");
58019defineSymbol(math, main, textord, "\u2225", "\\Vert");
58020defineSymbol(text, main, textord, "\u2225", "\\textbardbl");
58021defineSymbol(text, main, textord, "~", "\\textasciitilde");
58022defineSymbol(text, main, textord, "\\", "\\textbackslash");
58023defineSymbol(text, main, textord, "^", "\\textasciicircum");
58024defineSymbol(math, main, rel, "\u2191", "\\uparrow", true);
58025defineSymbol(math, main, rel, "\u21D1", "\\Uparrow", true);
58026defineSymbol(math, main, rel, "\u2193", "\\downarrow", true);
58027defineSymbol(math, main, rel, "\u21D3", "\\Downarrow", true);
58028defineSymbol(math, main, rel, "\u2195", "\\updownarrow", true);
58029defineSymbol(math, main, rel, "\u21D5", "\\Updownarrow", true);
58030defineSymbol(math, main, op, "\u2210", "\\coprod");
58031defineSymbol(math, main, op, "\u22C1", "\\bigvee");
58032defineSymbol(math, main, op, "\u22C0", "\\bigwedge");
58033defineSymbol(math, main, op, "\u2A04", "\\biguplus");
58034defineSymbol(math, main, op, "\u22C2", "\\bigcap");
58035defineSymbol(math, main, op, "\u22C3", "\\bigcup");
58036defineSymbol(math, main, op, "\u222B", "\\int");
58037defineSymbol(math, main, op, "\u222B", "\\intop");
58038defineSymbol(math, main, op, "\u222C", "\\iint");
58039defineSymbol(math, main, op, "\u222D", "\\iiint");
58040defineSymbol(math, main, op, "\u220F", "\\prod");
58041defineSymbol(math, main, op, "\u2211", "\\sum");
58042defineSymbol(math, main, op, "\u2A02", "\\bigotimes");
58043defineSymbol(math, main, op, "\u2A01", "\\bigoplus");
58044defineSymbol(math, main, op, "\u2A00", "\\bigodot");
58045defineSymbol(math, main, op, "\u222E", "\\oint");
58046defineSymbol(math, main, op, "\u222F", "\\oiint");
58047defineSymbol(math, main, op, "\u2230", "\\oiiint");
58048defineSymbol(math, main, op, "\u2A06", "\\bigsqcup");
58049defineSymbol(math, main, op, "\u222B", "\\smallint");
58050defineSymbol(text, main, inner, "\u2026", "\\textellipsis");
58051defineSymbol(math, main, inner, "\u2026", "\\mathellipsis");
58052defineSymbol(text, main, inner, "\u2026", "\\ldots", true);
58053defineSymbol(math, main, inner, "\u2026", "\\ldots", true);
58054defineSymbol(math, main, inner, "\u22EF", "\\@cdots", true);
58055defineSymbol(math, main, inner, "\u22F1", "\\ddots", true);
58056defineSymbol(math, main, textord, "\u22EE", "\\varvdots");
58057defineSymbol(text, main, textord, "\u22EE", "\\varvdots");
58058defineSymbol(math, main, accent, "\u02CA", "\\acute");
58059defineSymbol(math, main, accent, "\u02CB", "\\grave");
58060defineSymbol(math, main, accent, "\xA8", "\\ddot");
58061defineSymbol(math, main, accent, "~", "\\tilde");
58062defineSymbol(math, main, accent, "\u02C9", "\\bar");
58063defineSymbol(math, main, accent, "\u02D8", "\\breve");
58064defineSymbol(math, main, accent, "\u02C7", "\\check");
58065defineSymbol(math, main, accent, "^", "\\hat");
58066defineSymbol(math, main, accent, "\u20D7", "\\vec");
58067defineSymbol(math, main, accent, "\u02D9", "\\dot");
58068defineSymbol(math, main, accent, "\u02DA", "\\mathring");
58069defineSymbol(math, main, mathord, "\uE131", "\\@imath");
58070defineSymbol(math, main, mathord, "\uE237", "\\@jmath");
58071defineSymbol(math, main, textord, "\u0131", "\u0131");
58072defineSymbol(math, main, textord, "\u0237", "\u0237");
58073defineSymbol(text, main, textord, "\u0131", "\\i", true);
58074defineSymbol(text, main, textord, "\u0237", "\\j", true);
58075defineSymbol(text, main, textord, "\xDF", "\\ss", true);
58076defineSymbol(text, main, textord, "\xE6", "\\ae", true);
58077defineSymbol(text, main, textord, "\u0153", "\\oe", true);
58078defineSymbol(text, main, textord, "\xF8", "\\o", true);
58079defineSymbol(text, main, textord, "\xC6", "\\AE", true);
58080defineSymbol(text, main, textord, "\u0152", "\\OE", true);
58081defineSymbol(text, main, textord, "\xD8", "\\O", true);
58082defineSymbol(text, main, accent, "\u02CA", "\\'");
58083defineSymbol(text, main, accent, "\u02CB", "\\`");
58084defineSymbol(text, main, accent, "\u02C6", "\\^");
58085defineSymbol(text, main, accent, "\u02DC", "\\~");
58086defineSymbol(text, main, accent, "\u02C9", "\\=");
58087defineSymbol(text, main, accent, "\u02D8", "\\u");
58088defineSymbol(text, main, accent, "\u02D9", "\\.");
58089defineSymbol(text, main, accent, "\xB8", "\\c");
58090defineSymbol(text, main, accent, "\u02DA", "\\r");
58091defineSymbol(text, main, accent, "\u02C7", "\\v");
58092defineSymbol(text, main, accent, "\xA8", '\\"');
58093defineSymbol(text, main, accent, "\u02DD", "\\H");
58094defineSymbol(text, main, accent, "\u25EF", "\\textcircled");
58095var ligatures = {
58096  "--": true,
58097  "---": true,
58098  "``": true,
58099  "''": true
58100};
58101defineSymbol(text, main, textord, "\u2013", "--", true);
58102defineSymbol(text, main, textord, "\u2013", "\\textendash");
58103defineSymbol(text, main, textord, "\u2014", "---", true);
58104defineSymbol(text, main, textord, "\u2014", "\\textemdash");
58105defineSymbol(text, main, textord, "\u2018", "`", true);
58106defineSymbol(text, main, textord, "\u2018", "\\textquoteleft");
58107defineSymbol(text, main, textord, "\u2019", "'", true);
58108defineSymbol(text, main, textord, "\u2019", "\\textquoteright");
58109defineSymbol(text, main, textord, "\u201C", "``", true);
58110defineSymbol(text, main, textord, "\u201C", "\\textquotedblleft");
58111defineSymbol(text, main, textord, "\u201D", "''", true);
58112defineSymbol(text, main, textord, "\u201D", "\\textquotedblright");
58113defineSymbol(math, main, textord, "\xB0", "\\degree", true);
58114defineSymbol(text, main, textord, "\xB0", "\\degree");
58115defineSymbol(text, main, textord, "\xB0", "\\textdegree", true);
58116defineSymbol(math, main, textord, "\xA3", "\\pounds");
58117defineSymbol(math, main, textord, "\xA3", "\\mathsterling", true);
58118defineSymbol(text, main, textord, "\xA3", "\\pounds");
58119defineSymbol(text, main, textord, "\xA3", "\\textsterling", true);
58120defineSymbol(math, ams, textord, "\u2720", "\\maltese");
58121defineSymbol(text, ams, textord, "\u2720", "\\maltese");
58122var mathTextSymbols = '0123456789/@."';
58123for (i = 0; i < mathTextSymbols.length; i++) {
58124  ch = mathTextSymbols.charAt(i);
58125  defineSymbol(math, main, textord, ch, ch);
58126}
58127var ch;
58128var i;
58129var textSymbols = '0123456789!@*()-=+";:?/.,';
58130for (_i = 0; _i < textSymbols.length; _i++) {
58131  _ch = textSymbols.charAt(_i);
58132  defineSymbol(text, main, textord, _ch, _ch);
58133}
58134var _ch;
58135var _i;
58136var letters = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";
58137for (_i2 = 0; _i2 < letters.length; _i2++) {
58138  _ch2 = letters.charAt(_i2);
58139  defineSymbol(math, main, mathord, _ch2, _ch2);
58140  defineSymbol(text, main, textord, _ch2, _ch2);
58141}
58142var _ch2;
58143var _i2;
58144defineSymbol(math, ams, textord, "C", "\u2102");
58145defineSymbol(text, ams, textord, "C", "\u2102");
58146defineSymbol(math, ams, textord, "H", "\u210D");
58147defineSymbol(text, ams, textord, "H", "\u210D");
58148defineSymbol(math, ams, textord, "N", "\u2115");
58149defineSymbol(text, ams, textord, "N", "\u2115");
58150defineSymbol(math, ams, textord, "P", "\u2119");
58151defineSymbol(text, ams, textord, "P", "\u2119");
58152defineSymbol(math, ams, textord, "Q", "\u211A");
58153defineSymbol(text, ams, textord, "Q", "\u211A");
58154defineSymbol(math, ams, textord, "R", "\u211D");
58155defineSymbol(text, ams, textord, "R", "\u211D");
58156defineSymbol(math, ams, textord, "Z", "\u2124");
58157defineSymbol(text, ams, textord, "Z", "\u2124");
58158defineSymbol(math, main, mathord, "h", "\u210E");
58159defineSymbol(text, main, mathord, "h", "\u210E");
58160var wideChar = "";
58161for (_i3 = 0; _i3 < letters.length; _i3++) {
58162  _ch3 = letters.charAt(_i3);
58163  wideChar = String.fromCharCode(55349, 56320 + _i3);
58164  defineSymbol(math, main, mathord, _ch3, wideChar);
58165  defineSymbol(text, main, textord, _ch3, wideChar);
58166  wideChar = String.fromCharCode(55349, 56372 + _i3);
58167  defineSymbol(math, main, mathord, _ch3, wideChar);
58168  defineSymbol(text, main, textord, _ch3, wideChar);
58169  wideChar = String.fromCharCode(55349, 56424 + _i3);
58170  defineSymbol(math, main, mathord, _ch3, wideChar);
58171  defineSymbol(text, main, textord, _ch3, wideChar);
58172  wideChar = String.fromCharCode(55349, 56580 + _i3);
58173  defineSymbol(math, main, mathord, _ch3, wideChar);
58174  defineSymbol(text, main, textord, _ch3, wideChar);
58175  wideChar = String.fromCharCode(55349, 56684 + _i3);
58176  defineSymbol(math, main, mathord, _ch3, wideChar);
58177  defineSymbol(text, main, textord, _ch3, wideChar);
58178  wideChar = String.fromCharCode(55349, 56736 + _i3);
58179  defineSymbol(math, main, mathord, _ch3, wideChar);
58180  defineSymbol(text, main, textord, _ch3, wideChar);
58181  wideChar = String.fromCharCode(55349, 56788 + _i3);
58182  defineSymbol(math, main, mathord, _ch3, wideChar);
58183  defineSymbol(text, main, textord, _ch3, wideChar);
58184  wideChar = String.fromCharCode(55349, 56840 + _i3);
58185  defineSymbol(math, main, mathord, _ch3, wideChar);
58186  defineSymbol(text, main, textord, _ch3, wideChar);
58187  wideChar = String.fromCharCode(55349, 56944 + _i3);
58188  defineSymbol(math, main, mathord, _ch3, wideChar);
58189  defineSymbol(text, main, textord, _ch3, wideChar);
58190  if (_i3 < 26) {
58191    wideChar = String.fromCharCode(55349, 56632 + _i3);
58192    defineSymbol(math, main, mathord, _ch3, wideChar);
58193    defineSymbol(text, main, textord, _ch3, wideChar);
58194    wideChar = String.fromCharCode(55349, 56476 + _i3);
58195    defineSymbol(math, main, mathord, _ch3, wideChar);
58196    defineSymbol(text, main, textord, _ch3, wideChar);
58197  }
58198}
58199var _ch3;
58200var _i3;
58201wideChar = String.fromCharCode(55349, 56668);
58202defineSymbol(math, main, mathord, "k", wideChar);
58203defineSymbol(text, main, textord, "k", wideChar);
58204for (_i4 = 0; _i4 < 10; _i4++) {
58205  _ch4 = _i4.toString();
58206  wideChar = String.fromCharCode(55349, 57294 + _i4);
58207  defineSymbol(math, main, mathord, _ch4, wideChar);
58208  defineSymbol(text, main, textord, _ch4, wideChar);
58209  wideChar = String.fromCharCode(55349, 57314 + _i4);
58210  defineSymbol(math, main, mathord, _ch4, wideChar);
58211  defineSymbol(text, main, textord, _ch4, wideChar);
58212  wideChar = String.fromCharCode(55349, 57324 + _i4);
58213  defineSymbol(math, main, mathord, _ch4, wideChar);
58214  defineSymbol(text, main, textord, _ch4, wideChar);
58215  wideChar = String.fromCharCode(55349, 57334 + _i4);
58216  defineSymbol(math, main, mathord, _ch4, wideChar);
58217  defineSymbol(text, main, textord, _ch4, wideChar);
58218}
58219var _ch4;
58220var _i4;
58221var extraLatin = "\xD0\xDE\xFE";
58222for (_i5 = 0; _i5 < extraLatin.length; _i5++) {
58223  _ch5 = extraLatin.charAt(_i5);
58224  defineSymbol(math, main, mathord, _ch5, _ch5);
58225  defineSymbol(text, main, textord, _ch5, _ch5);
58226}
58227var _ch5;
58228var _i5;
58229var wideLatinLetterData = [
58230  ["mathbf", "textbf", "Main-Bold"],
58231  // A-Z bold upright
58232  ["mathbf", "textbf", "Main-Bold"],
58233  // a-z bold upright
58234  ["mathnormal", "textit", "Math-Italic"],
58235  // A-Z italic
58236  ["mathnormal", "textit", "Math-Italic"],
58237  // a-z italic
58238  ["boldsymbol", "boldsymbol", "Main-BoldItalic"],
58239  // A-Z bold italic
58240  ["boldsymbol", "boldsymbol", "Main-BoldItalic"],
58241  // a-z bold italic
58242  // Map fancy A-Z letters to script, not calligraphic.
58243  // This aligns with unicode-math and math fonts (except Cambria Math).
58244  ["mathscr", "textscr", "Script-Regular"],
58245  // A-Z script
58246  ["", "", ""],
58247  // a-z script.  No font
58248  ["", "", ""],
58249  // A-Z bold script. No font
58250  ["", "", ""],
58251  // a-z bold script. No font
58252  ["mathfrak", "textfrak", "Fraktur-Regular"],
58253  // A-Z Fraktur
58254  ["mathfrak", "textfrak", "Fraktur-Regular"],
58255  // a-z Fraktur
58256  ["mathbb", "textbb", "AMS-Regular"],
58257  // A-Z double-struck
58258  ["mathbb", "textbb", "AMS-Regular"],
58259  // k double-struck
58260  // Note that we are using a bold font, but font metrics for regular Fraktur.
58261  ["mathboldfrak", "textboldfrak", "Fraktur-Regular"],
58262  // A-Z bold Fraktur
58263  ["mathboldfrak", "textboldfrak", "Fraktur-Regular"],
58264  // a-z bold Fraktur
58265  ["mathsf", "textsf", "SansSerif-Regular"],
58266  // A-Z sans-serif
58267  ["mathsf", "textsf", "SansSerif-Regular"],
58268  // a-z sans-serif
58269  ["mathboldsf", "textboldsf", "SansSerif-Bold"],
58270  // A-Z bold sans-serif
58271  ["mathboldsf", "textboldsf", "SansSerif-Bold"],
58272  // a-z bold sans-serif
58273  ["mathitsf", "textitsf", "SansSerif-Italic"],
58274  // A-Z italic sans-serif
58275  ["mathitsf", "textitsf", "SansSerif-Italic"],
58276  // a-z italic sans-serif
58277  ["", "", ""],
58278  // A-Z bold italic sans. No font
58279  ["", "", ""],
58280  // a-z bold italic sans. No font
58281  ["mathtt", "texttt", "Typewriter-Regular"],
58282  // A-Z monospace
58283  ["mathtt", "texttt", "Typewriter-Regular"]
58284  // a-z monospace
58285];
58286var wideNumeralData = [
58287  ["mathbf", "textbf", "Main-Bold"],
58288  // 0-9 bold
58289  ["", "", ""],
58290  // 0-9 double-struck. No KaTeX font.
58291  ["mathsf", "textsf", "SansSerif-Regular"],
58292  // 0-9 sans-serif
58293  ["mathboldsf", "textboldsf", "SansSerif-Bold"],
58294  // 0-9 bold sans-serif
58295  ["mathtt", "texttt", "Typewriter-Regular"]
58296  // 0-9 monospace
58297];
58298var wideCharacterFont = function wideCharacterFont2(wideChar2, mode) {
58299  var H = wideChar2.charCodeAt(0);
58300  var L = wideChar2.charCodeAt(1);
58301  var codePoint = (H - 55296) * 1024 + (L - 56320) + 65536;
58302  var j = mode === "math" ? 0 : 1;
58303  if (119808 <= codePoint && codePoint < 120484) {
58304    var i = Math.floor((codePoint - 119808) / 26);
58305    return [wideLatinLetterData[i][2], wideLatinLetterData[i][j]];
58306  } else if (120782 <= codePoint && codePoint <= 120831) {
58307    var _i = Math.floor((codePoint - 120782) / 10);
58308    return [wideNumeralData[_i][2], wideNumeralData[_i][j]];
58309  } else if (codePoint === 120485 || codePoint === 120486) {
58310    return [wideLatinLetterData[0][2], wideLatinLetterData[0][j]];
58311  } else if (120486 < codePoint && codePoint < 120782) {
58312    return ["", ""];
58313  } else {
58314    throw new ParseError("Unsupported character: " + wideChar2);
58315  }
58316};
58317var lookupSymbol = function lookupSymbol2(value, fontName, mode) {
58318  if (symbols[mode][value] && symbols[mode][value].replace) {
58319    value = symbols[mode][value].replace;
58320  }
58321  return {
58322    value,
58323    metrics: getCharacterMetrics(value, fontName, mode)
58324  };
58325};
58326var makeSymbol = function makeSymbol2(value, fontName, mode, options2, classes2) {
58327  var lookup = lookupSymbol(value, fontName, mode);
58328  var metrics = lookup.metrics;
58329  value = lookup.value;
58330  var symbolNode;
58331  if (metrics) {
58332    var italic = metrics.italic;
58333    if (mode === "text" || options2 && options2.font === "mathit") {
58334      italic = 0;
58335    }
58336    symbolNode = new SymbolNode(value, metrics.height, metrics.depth, italic, metrics.skew, metrics.width, classes2);
58337  } else {
58338    typeof console !== "undefined" && console.warn("No character metrics " + ("for '" + value + "' in style '" + fontName + "' and mode '" + mode + "'"));
58339    symbolNode = new SymbolNode(value, 0, 0, 0, 0, 0, classes2);
58340  }
58341  if (options2) {
58342    symbolNode.maxFontSize = options2.sizeMultiplier;
58343    if (options2.style.isTight()) {
58344      symbolNode.classes.push("mtight");
58345    }
58346    var color = options2.getColor();
58347    if (color) {
58348      symbolNode.style.color = color;
58349    }
58350  }
58351  return symbolNode;
58352};
58353var mathsym = function mathsym2(value, mode, options2, classes2) {
58354  if (classes2 === void 0) {
58355    classes2 = [];
58356  }
58357  if (options2.font === "boldsymbol" && lookupSymbol(value, "Main-Bold", mode).metrics) {
58358    return makeSymbol(value, "Main-Bold", mode, options2, classes2.concat(["mathbf"]));
58359  } else if (value === "\\" || symbols[mode][value].font === "main") {
58360    return makeSymbol(value, "Main-Regular", mode, options2, classes2);
58361  } else {
58362    return makeSymbol(value, "AMS-Regular", mode, options2, classes2.concat(["amsrm"]));
58363  }
58364};
58365var boldsymbol = function boldsymbol2(value, mode, options2, classes2, type) {
58366  if (type !== "textord" && lookupSymbol(value, "Math-BoldItalic", mode).metrics) {
58367    return {
58368      fontName: "Math-BoldItalic",
58369      fontClass: "boldsymbol"
58370    };
58371  } else {
58372    return {
58373      fontName: "Main-Bold",
58374      fontClass: "mathbf"
58375    };
58376  }
58377};
58378var makeOrd = function makeOrd2(group, options2, type) {
58379  var mode = group.mode;
58380  var text2 = group.text;
58381  var classes2 = ["mord"];
58382  var isFont = mode === "math" || mode === "text" && options2.font;
58383  var fontOrFamily = isFont ? options2.font : options2.fontFamily;
58384  var wideFontName = "";
58385  var wideFontClass = "";
58386  if (text2.charCodeAt(0) === 55349) {
58387    [wideFontName, wideFontClass] = wideCharacterFont(text2, mode);
58388  }
58389  if (wideFontName.length > 0) {
58390    return makeSymbol(text2, wideFontName, mode, options2, classes2.concat(wideFontClass));
58391  } else if (fontOrFamily) {
58392    var fontName;
58393    var fontClasses;
58394    if (fontOrFamily === "boldsymbol") {
58395      var fontData = boldsymbol(text2, mode, options2, classes2, type);
58396      fontName = fontData.fontName;
58397      fontClasses = [fontData.fontClass];
58398    } else if (isFont) {
58399      fontName = fontMap[fontOrFamily].fontName;
58400      fontClasses = [fontOrFamily];
58401    } else {
58402      fontName = retrieveTextFontName(fontOrFamily, options2.fontWeight, options2.fontShape);
58403      fontClasses = [fontOrFamily, options2.fontWeight, options2.fontShape];
58404    }
58405    if (lookupSymbol(text2, fontName, mode).metrics) {
58406      return makeSymbol(text2, fontName, mode, options2, classes2.concat(fontClasses));
58407    } else if (ligatures.hasOwnProperty(text2) && fontName.slice(0, 10) === "Typewriter") {
58408      var parts = [];
58409      for (var i = 0; i < text2.length; i++) {
58410        parts.push(makeSymbol(text2[i], fontName, mode, options2, classes2.concat(fontClasses)));
58411      }
58412      return makeFragment(parts);
58413    }
58414  }
58415  if (type === "mathord") {
58416    return makeSymbol(text2, "Math-Italic", mode, options2, classes2.concat(["mathnormal"]));
58417  } else if (type === "textord") {
58418    var font = symbols[mode][text2] && symbols[mode][text2].font;
58419    if (font === "ams") {
58420      var _fontName = retrieveTextFontName("amsrm", options2.fontWeight, options2.fontShape);
58421      return makeSymbol(text2, _fontName, mode, options2, classes2.concat("amsrm", options2.fontWeight, options2.fontShape));
58422    } else if (font === "main" || !font) {
58423      var _fontName2 = retrieveTextFontName("textrm", options2.fontWeight, options2.fontShape);
58424      return makeSymbol(text2, _fontName2, mode, options2, classes2.concat(options2.fontWeight, options2.fontShape));
58425    } else {
58426      var _fontName3 = retrieveTextFontName(font, options2.fontWeight, options2.fontShape);
58427      return makeSymbol(text2, _fontName3, mode, options2, classes2.concat(_fontName3, options2.fontWeight, options2.fontShape));
58428    }
58429  } else {
58430    throw new Error("unexpected type: " + type + " in makeOrd");
58431  }
58432};
58433var canCombine = (prev, next) => {
58434  if (createClass(prev.classes) !== createClass(next.classes) || prev.skew !== next.skew || prev.maxFontSize !== next.maxFontSize) {
58435    return false;
58436  }
58437  if (prev.classes.length === 1) {
58438    var cls = prev.classes[0];
58439    if (cls === "mbin" || cls === "mord") {
58440      return false;
58441    }
58442  }
58443  for (var style in prev.style) {
58444    if (prev.style.hasOwnProperty(style) && prev.style[style] !== next.style[style]) {
58445      return false;
58446    }
58447  }
58448  for (var _style in next.style) {
58449    if (next.style.hasOwnProperty(_style) && prev.style[_style] !== next.style[_style]) {
58450      return false;
58451    }
58452  }
58453  return true;
58454};
58455var tryCombineChars = (chars) => {
58456  for (var i = 0; i < chars.length - 1; i++) {
58457    var prev = chars[i];
58458    var next = chars[i + 1];
58459    if (prev instanceof SymbolNode && next instanceof SymbolNode && canCombine(prev, next)) {
58460      prev.text += next.text;
58461      prev.height = Math.max(prev.height, next.height);
58462      prev.depth = Math.max(prev.depth, next.depth);
58463      prev.italic = next.italic;
58464      chars.splice(i + 1, 1);
58465      i--;
58466    }
58467  }
58468  return chars;
58469};
58470var sizeElementFromChildren = function sizeElementFromChildren2(elem) {
58471  var height = 0;
58472  var depth = 0;
58473  var maxFontSize = 0;
58474  for (var i = 0; i < elem.children.length; i++) {
58475    var child = elem.children[i];
58476    if (child.height > height) {
58477      height = child.height;
58478    }
58479    if (child.depth > depth) {
58480      depth = child.depth;
58481    }
58482    if (child.maxFontSize > maxFontSize) {
58483      maxFontSize = child.maxFontSize;
58484    }
58485  }
58486  elem.height = height;
58487  elem.depth = depth;
58488  elem.maxFontSize = maxFontSize;
58489};
58490var makeSpan$2 = function makeSpan(classes2, children, options2, style) {
58491  var span = new Span(classes2, children, options2, style);
58492  sizeElementFromChildren(span);
58493  return span;
58494};
58495var makeSvgSpan = (classes2, children, options2, style) => new Span(classes2, children, options2, style);
58496var makeLineSpan = function makeLineSpan2(className, options2, thickness) {
58497  var line = makeSpan$2([className], [], options2);
58498  line.height = Math.max(thickness || options2.fontMetrics().defaultRuleThickness, options2.minRuleThickness);
58499  line.style.borderBottomWidth = makeEm(line.height);
58500  line.maxFontSize = 1;
58501  return line;
58502};
58503var makeAnchor = function makeAnchor2(href, classes2, children, options2) {
58504  var anchor = new Anchor(href, classes2, children, options2);
58505  sizeElementFromChildren(anchor);
58506  return anchor;
58507};
58508var makeFragment = function makeFragment2(children) {
58509  var fragment = new DocumentFragment(children);
58510  sizeElementFromChildren(fragment);
58511  return fragment;
58512};
58513var wrapFragment = function wrapFragment2(group, options2) {
58514  if (group instanceof DocumentFragment) {
58515    return makeSpan$2([], [group], options2);
58516  }
58517  return group;
58518};
58519var getVListChildrenAndDepth = function getVListChildrenAndDepth2(params) {
58520  if (params.positionType === "individualShift") {
58521    var oldChildren = params.children;
58522    var children = [oldChildren[0]];
58523    var _depth = -oldChildren[0].shift - oldChildren[0].elem.depth;
58524    var currPos = _depth;
58525    for (var i = 1; i < oldChildren.length; i++) {
58526      var diff = -oldChildren[i].shift - currPos - oldChildren[i].elem.depth;
58527      var size = diff - (oldChildren[i - 1].elem.height + oldChildren[i - 1].elem.depth);
58528      currPos = currPos + diff;
58529      children.push({
58530        type: "kern",
58531        size
58532      });
58533      children.push(oldChildren[i]);
58534    }
58535    return {
58536      children,
58537      depth: _depth
58538    };
58539  }
58540  var depth;
58541  if (params.positionType === "top") {
58542    var bottom = params.positionData;
58543    for (var _i = 0; _i < params.children.length; _i++) {
58544      var child = params.children[_i];
58545      bottom -= child.type === "kern" ? child.size : child.elem.height + child.elem.depth;
58546    }
58547    depth = bottom;
58548  } else if (params.positionType === "bottom") {
58549    depth = -params.positionData;
58550  } else {
58551    var firstChild = params.children[0];
58552    if (firstChild.type !== "elem") {
58553      throw new Error('First child must have type "elem".');
58554    }
58555    if (params.positionType === "shift") {
58556      depth = -firstChild.elem.depth - params.positionData;
58557    } else if (params.positionType === "firstBaseline") {
58558      depth = -firstChild.elem.depth;
58559    } else {
58560      throw new Error("Invalid positionType " + params.positionType + ".");
58561    }
58562  }
58563  return {
58564    children: params.children,
58565    depth
58566  };
58567};
58568var makeVList = function makeVList2(params, options2) {
58569  var {
58570    children,
58571    depth
58572  } = getVListChildrenAndDepth(params);
58573  var pstrutSize = 0;
58574  for (var i = 0; i < children.length; i++) {
58575    var child = children[i];
58576    if (child.type === "elem") {
58577      var elem = child.elem;
58578      pstrutSize = Math.max(pstrutSize, elem.maxFontSize, elem.height);
58579    }
58580  }
58581  pstrutSize += 2;
58582  var pstrut = makeSpan$2(["pstrut"], []);
58583  pstrut.style.height = makeEm(pstrutSize);
58584  var realChildren = [];
58585  var minPos = depth;
58586  var maxPos = depth;
58587  var currPos = depth;
58588  for (var _i2 = 0; _i2 < children.length; _i2++) {
58589    var _child = children[_i2];
58590    if (_child.type === "kern") {
58591      currPos += _child.size;
58592    } else {
58593      var _elem = _child.elem;
58594      var classes2 = _child.wrapperClasses || [];
58595      var style = _child.wrapperStyle || {};
58596      var childWrap = makeSpan$2(classes2, [pstrut, _elem], void 0, style);
58597      childWrap.style.top = makeEm(-pstrutSize - currPos - _elem.depth);
58598      if (_child.marginLeft) {
58599        childWrap.style.marginLeft = _child.marginLeft;
58600      }
58601      if (_child.marginRight) {
58602        childWrap.style.marginRight = _child.marginRight;
58603      }
58604      realChildren.push(childWrap);
58605      currPos += _elem.height + _elem.depth;
58606    }
58607    minPos = Math.min(minPos, currPos);
58608    maxPos = Math.max(maxPos, currPos);
58609  }
58610  var vlist = makeSpan$2(["vlist"], realChildren);
58611  vlist.style.height = makeEm(maxPos);
58612  var rows;
58613  if (minPos < 0) {
58614    var emptySpan = makeSpan$2([], []);
58615    var depthStrut = makeSpan$2(["vlist"], [emptySpan]);
58616    depthStrut.style.height = makeEm(-minPos);
58617    var topStrut = makeSpan$2(["vlist-s"], [new SymbolNode("\u200B")]);
58618    rows = [makeSpan$2(["vlist-r"], [vlist, topStrut]), makeSpan$2(["vlist-r"], [depthStrut])];
58619  } else {
58620    rows = [makeSpan$2(["vlist-r"], [vlist])];
58621  }
58622  var vtable = makeSpan$2(["vlist-t"], rows);
58623  if (rows.length === 2) {
58624    vtable.classes.push("vlist-t2");
58625  }
58626  vtable.height = maxPos;
58627  vtable.depth = -minPos;
58628  return vtable;
58629};
58630var makeGlue = (measurement, options2) => {
58631  var rule = makeSpan$2(["mspace"], [], options2);
58632  var size = calculateSize(measurement, options2);
58633  rule.style.marginRight = makeEm(size);
58634  return rule;
58635};
58636var retrieveTextFontName = function retrieveTextFontName2(fontFamily, fontWeight, fontShape) {
58637  var baseFontName = "";
58638  switch (fontFamily) {
58639    case "amsrm":
58640      baseFontName = "AMS";
58641      break;
58642    case "textrm":
58643      baseFontName = "Main";
58644      break;
58645    case "textsf":
58646      baseFontName = "SansSerif";
58647      break;
58648    case "texttt":
58649      baseFontName = "Typewriter";
58650      break;
58651    default:
58652      baseFontName = fontFamily;
58653  }
58654  var fontStylesName;
58655  if (fontWeight === "textbf" && fontShape === "textit") {
58656    fontStylesName = "BoldItalic";
58657  } else if (fontWeight === "textbf") {
58658    fontStylesName = "Bold";
58659  } else if (fontWeight === "textit") {
58660    fontStylesName = "Italic";
58661  } else {
58662    fontStylesName = "Regular";
58663  }
58664  return baseFontName + "-" + fontStylesName;
58665};
58666var fontMap = {
58667  // styles
58668  "mathbf": {
58669    variant: "bold",
58670    fontName: "Main-Bold"
58671  },
58672  "mathrm": {
58673    variant: "normal",
58674    fontName: "Main-Regular"
58675  },
58676  "textit": {
58677    variant: "italic",
58678    fontName: "Main-Italic"
58679  },
58680  "mathit": {
58681    variant: "italic",
58682    fontName: "Main-Italic"
58683  },
58684  "mathnormal": {
58685    variant: "italic",
58686    fontName: "Math-Italic"
58687  },
58688  "mathsfit": {
58689    variant: "sans-serif-italic",
58690    fontName: "SansSerif-Italic"
58691  },
58692  // "boldsymbol" is missing because they require the use of multiple fonts:
58693  // Math-BoldItalic and Main-Bold.  This is handled by a special case in
58694  // makeOrd which ends up calling boldsymbol.
58695  // families
58696  "mathbb": {
58697    variant: "double-struck",
58698    fontName: "AMS-Regular"
58699  },
58700  "mathcal": {
58701    variant: "script",
58702    fontName: "Caligraphic-Regular"
58703  },
58704  "mathfrak": {
58705    variant: "fraktur",
58706    fontName: "Fraktur-Regular"
58707  },
58708  "mathscr": {
58709    variant: "script",
58710    fontName: "Script-Regular"
58711  },
58712  "mathsf": {
58713    variant: "sans-serif",
58714    fontName: "SansSerif-Regular"
58715  },
58716  "mathtt": {
58717    variant: "monospace",
58718    fontName: "Typewriter-Regular"
58719  }
58720};
58721var svgData = {
58722  //   path, width, height
58723  vec: ["vec", 0.471, 0.714],
58724  // values from the font glyph
58725  oiintSize1: ["oiintSize1", 0.957, 0.499],
58726  // oval to overlay the integrand
58727  oiintSize2: ["oiintSize2", 1.472, 0.659],
58728  oiiintSize1: ["oiiintSize1", 1.304, 0.499],
58729  oiiintSize2: ["oiiintSize2", 1.98, 0.659]
58730};
58731var staticSvg = function staticSvg2(value, options2) {
58732  var [pathName, width, height] = svgData[value];
58733  var path2 = new PathNode(pathName);
58734  var svgNode = new SvgNode([path2], {
58735    "width": makeEm(width),
58736    "height": makeEm(height),
58737    // Override CSS rule `.katex svg { width: 100% }`
58738    "style": "width:" + makeEm(width),
58739    "viewBox": "0 0 " + 1e3 * width + " " + 1e3 * height,
58740    "preserveAspectRatio": "xMinYMin"
58741  });
58742  var span = makeSvgSpan(["overlay"], [svgNode], options2);
58743  span.height = height;
58744  span.style.height = makeEm(height);
58745  span.style.width = makeEm(width);
58746  return span;
58747};
58748var buildCommon = {
58749  fontMap,
58750  makeSymbol,
58751  mathsym,
58752  makeSpan: makeSpan$2,
58753  makeSvgSpan,
58754  makeLineSpan,
58755  makeAnchor,
58756  makeFragment,
58757  wrapFragment,
58758  makeVList,
58759  makeOrd,
58760  makeGlue,
58761  staticSvg,
58762  svgData,
58763  tryCombineChars
58764};
58765var thinspace = {
58766  number: 3,
58767  unit: "mu"
58768};
58769var mediumspace = {
58770  number: 4,
58771  unit: "mu"
58772};
58773var thickspace = {
58774  number: 5,
58775  unit: "mu"
58776};
58777var spacings = {
58778  mord: {
58779    mop: thinspace,
58780    mbin: mediumspace,
58781    mrel: thickspace,
58782    minner: thinspace
58783  },
58784  mop: {
58785    mord: thinspace,
58786    mop: thinspace,
58787    mrel: thickspace,
58788    minner: thinspace
58789  },
58790  mbin: {
58791    mord: mediumspace,
58792    mop: mediumspace,
58793    mopen: mediumspace,
58794    minner: mediumspace
58795  },
58796  mrel: {
58797    mord: thickspace,
58798    mop: thickspace,
58799    mopen: thickspace,
58800    minner: thickspace
58801  },
58802  mopen: {},
58803  mclose: {
58804    mop: thinspace,
58805    mbin: mediumspace,
58806    mrel: thickspace,
58807    minner: thinspace
58808  },
58809  mpunct: {
58810    mord: thinspace,
58811    mop: thinspace,
58812    mrel: thickspace,
58813    mopen: thinspace,
58814    mclose: thinspace,
58815    mpunct: thinspace,
58816    minner: thinspace
58817  },
58818  minner: {
58819    mord: thinspace,
58820    mop: thinspace,
58821    mbin: mediumspace,
58822    mrel: thickspace,
58823    mopen: thinspace,
58824    mpunct: thinspace,
58825    minner: thinspace
58826  }
58827};
58828var tightSpacings = {
58829  mord: {
58830    mop: thinspace
58831  },
58832  mop: {
58833    mord: thinspace,
58834    mop: thinspace
58835  },
58836  mbin: {},
58837  mrel: {},
58838  mopen: {},
58839  mclose: {
58840    mop: thinspace
58841  },
58842  mpunct: {},
58843  minner: {
58844    mop: thinspace
58845  }
58846};
58847var _functions = {};
58848var _htmlGroupBuilders = {};
58849var _mathmlGroupBuilders = {};
58850function defineFunction(_ref) {
58851  var {
58852    type,
58853    names,
58854    props,
58855    handler,
58856    htmlBuilder: htmlBuilder3,
58857    mathmlBuilder: mathmlBuilder3
58858  } = _ref;
58859  var data = {
58860    type,
58861    numArgs: props.numArgs,
58862    argTypes: props.argTypes,
58863    allowedInArgument: !!props.allowedInArgument,
58864    allowedInText: !!props.allowedInText,
58865    allowedInMath: props.allowedInMath === void 0 ? true : props.allowedInMath,
58866    numOptionalArgs: props.numOptionalArgs || 0,
58867    infix: !!props.infix,
58868    primitive: !!props.primitive,
58869    handler
58870  };
58871  for (var i = 0; i < names.length; ++i) {
58872    _functions[names[i]] = data;
58873  }
58874  if (type) {
58875    if (htmlBuilder3) {
58876      _htmlGroupBuilders[type] = htmlBuilder3;
58877    }
58878    if (mathmlBuilder3) {
58879      _mathmlGroupBuilders[type] = mathmlBuilder3;
58880    }
58881  }
58882}
58883function defineFunctionBuilders(_ref2) {
58884  var {
58885    type,
58886    htmlBuilder: htmlBuilder3,
58887    mathmlBuilder: mathmlBuilder3
58888  } = _ref2;
58889  defineFunction({
58890    type,
58891    names: [],
58892    props: {
58893      numArgs: 0
58894    },
58895    handler() {
58896      throw new Error("Should never be called.");
58897    },
58898    htmlBuilder: htmlBuilder3,
58899    mathmlBuilder: mathmlBuilder3
58900  });
58901}
58902var normalizeArgument = function normalizeArgument2(arg) {
58903  return arg.type === "ordgroup" && arg.body.length === 1 ? arg.body[0] : arg;
58904};
58905var ordargument = function ordargument2(arg) {
58906  return arg.type === "ordgroup" ? arg.body : [arg];
58907};
58908var makeSpan$1 = buildCommon.makeSpan;
58909var binLeftCanceller = ["leftmost", "mbin", "mopen", "mrel", "mop", "mpunct"];
58910var binRightCanceller = ["rightmost", "mrel", "mclose", "mpunct"];
58911var styleMap$1 = {
58912  "display": Style$1.DISPLAY,
58913  "text": Style$1.TEXT,
58914  "script": Style$1.SCRIPT,
58915  "scriptscript": Style$1.SCRIPTSCRIPT
58916};
58917var DomEnum = {
58918  mord: "mord",
58919  mop: "mop",
58920  mbin: "mbin",
58921  mrel: "mrel",
58922  mopen: "mopen",
58923  mclose: "mclose",
58924  mpunct: "mpunct",
58925  minner: "minner"
58926};
58927var buildExpression$1 = function buildExpression(expression, options2, isRealGroup, surrounding) {
58928  if (surrounding === void 0) {
58929    surrounding = [null, null];
58930  }
58931  var groups = [];
58932  for (var i = 0; i < expression.length; i++) {
58933    var output = buildGroup$1(expression[i], options2);
58934    if (output instanceof DocumentFragment) {
58935      var children = output.children;
58936      groups.push(...children);
58937    } else {
58938      groups.push(output);
58939    }
58940  }
58941  buildCommon.tryCombineChars(groups);
58942  if (!isRealGroup) {
58943    return groups;
58944  }
58945  var glueOptions = options2;
58946  if (expression.length === 1) {
58947    var node = expression[0];
58948    if (node.type === "sizing") {
58949      glueOptions = options2.havingSize(node.size);
58950    } else if (node.type === "styling") {
58951      glueOptions = options2.havingStyle(styleMap$1[node.style]);
58952    }
58953  }
58954  var dummyPrev = makeSpan$1([surrounding[0] || "leftmost"], [], options2);
58955  var dummyNext = makeSpan$1([surrounding[1] || "rightmost"], [], options2);
58956  var isRoot = isRealGroup === "root";
58957  traverseNonSpaceNodes(groups, (node2, prev) => {
58958    var prevType = prev.classes[0];
58959    var type = node2.classes[0];
58960    if (prevType === "mbin" && utils.contains(binRightCanceller, type)) {
58961      prev.classes[0] = "mord";
58962    } else if (type === "mbin" && utils.contains(binLeftCanceller, prevType)) {
58963      node2.classes[0] = "mord";
58964    }
58965  }, {
58966    node: dummyPrev
58967  }, dummyNext, isRoot);
58968  traverseNonSpaceNodes(groups, (node2, prev) => {
58969    var prevType = getTypeOfDomTree(prev);
58970    var type = getTypeOfDomTree(node2);
58971    var space = prevType && type ? node2.hasClass("mtight") ? tightSpacings[prevType][type] : spacings[prevType][type] : null;
58972    if (space) {
58973      return buildCommon.makeGlue(space, glueOptions);
58974    }
58975  }, {
58976    node: dummyPrev
58977  }, dummyNext, isRoot);
58978  return groups;
58979};
58980var traverseNonSpaceNodes = function traverseNonSpaceNodes2(nodes, callback, prev, next, isRoot) {
58981  if (next) {
58982    nodes.push(next);
58983  }
58984  var i = 0;
58985  for (; i < nodes.length; i++) {
58986    var node = nodes[i];
58987    var partialGroup = checkPartialGroup(node);
58988    if (partialGroup) {
58989      traverseNonSpaceNodes2(partialGroup.children, callback, prev, null, isRoot);
58990      continue;
58991    }
58992    var nonspace = !node.hasClass("mspace");
58993    if (nonspace) {
58994      var result = callback(node, prev.node);
58995      if (result) {
58996        if (prev.insertAfter) {
58997          prev.insertAfter(result);
58998        } else {
58999          nodes.unshift(result);
59000          i++;
59001        }
59002      }
59003    }
59004    if (nonspace) {
59005      prev.node = node;
59006    } else if (isRoot && node.hasClass("newline")) {
59007      prev.node = makeSpan$1(["leftmost"]);
59008    }
59009    prev.insertAfter = /* @__PURE__ */ ((index) => (n) => {
59010      nodes.splice(index + 1, 0, n);
59011      i++;
59012    })(i);
59013  }
59014  if (next) {
59015    nodes.pop();
59016  }
59017};
59018var checkPartialGroup = function checkPartialGroup2(node) {
59019  if (node instanceof DocumentFragment || node instanceof Anchor || node instanceof Span && node.hasClass("enclosing")) {
59020    return node;
59021  }
59022  return null;
59023};
59024var getOutermostNode = function getOutermostNode2(node, side) {
59025  var partialGroup = checkPartialGroup(node);
59026  if (partialGroup) {
59027    var children = partialGroup.children;
59028    if (children.length) {
59029      if (side === "right") {
59030        return getOutermostNode2(children[children.length - 1], "right");
59031      } else if (side === "left") {
59032        return getOutermostNode2(children[0], "left");
59033      }
59034    }
59035  }
59036  return node;
59037};
59038var getTypeOfDomTree = function getTypeOfDomTree2(node, side) {
59039  if (!node) {
59040    return null;
59041  }
59042  if (side) {
59043    node = getOutermostNode(node, side);
59044  }
59045  return DomEnum[node.classes[0]] || null;
59046};
59047var makeNullDelimiter = function makeNullDelimiter2(options2, classes2) {
59048  var moreClasses = ["nulldelimiter"].concat(options2.baseSizingClasses());
59049  return makeSpan$1(classes2.concat(moreClasses));
59050};
59051var buildGroup$1 = function buildGroup(group, options2, baseOptions) {
59052  if (!group) {
59053    return makeSpan$1();
59054  }
59055  if (_htmlGroupBuilders[group.type]) {
59056    var groupNode = _htmlGroupBuilders[group.type](group, options2);
59057    if (baseOptions && options2.size !== baseOptions.size) {
59058      groupNode = makeSpan$1(options2.sizingClasses(baseOptions), [groupNode], options2);
59059      var multiplier = options2.sizeMultiplier / baseOptions.sizeMultiplier;
59060      groupNode.height *= multiplier;
59061      groupNode.depth *= multiplier;
59062    }
59063    return groupNode;
59064  } else {
59065    throw new ParseError("Got group of unknown type: '" + group.type + "'");
59066  }
59067};
59068function buildHTMLUnbreakable(children, options2) {
59069  var body = makeSpan$1(["base"], children, options2);
59070  var strut = makeSpan$1(["strut"]);
59071  strut.style.height = makeEm(body.height + body.depth);
59072  if (body.depth) {
59073    strut.style.verticalAlign = makeEm(-body.depth);
59074  }
59075  body.children.unshift(strut);
59076  return body;
59077}
59078function buildHTML(tree, options2) {
59079  var tag2 = null;
59080  if (tree.length === 1 && tree[0].type === "tag") {
59081    tag2 = tree[0].tag;
59082    tree = tree[0].body;
59083  }
59084  var expression = buildExpression$1(tree, options2, "root");
59085  var eqnNum;
59086  if (expression.length === 2 && expression[1].hasClass("tag")) {
59087    eqnNum = expression.pop();
59088  }
59089  var children = [];
59090  var parts = [];
59091  for (var i = 0; i < expression.length; i++) {
59092    parts.push(expression[i]);
59093    if (expression[i].hasClass("mbin") || expression[i].hasClass("mrel") || expression[i].hasClass("allowbreak")) {
59094      var nobreak = false;
59095      while (i < expression.length - 1 && expression[i + 1].hasClass("mspace") && !expression[i + 1].hasClass("newline")) {
59096        i++;
59097        parts.push(expression[i]);
59098        if (expression[i].hasClass("nobreak")) {
59099          nobreak = true;
59100        }
59101      }
59102      if (!nobreak) {
59103        children.push(buildHTMLUnbreakable(parts, options2));
59104        parts = [];
59105      }
59106    } else if (expression[i].hasClass("newline")) {
59107      parts.pop();
59108      if (parts.length > 0) {
59109        children.push(buildHTMLUnbreakable(parts, options2));
59110        parts = [];
59111      }
59112      children.push(expression[i]);
59113    }
59114  }
59115  if (parts.length > 0) {
59116    children.push(buildHTMLUnbreakable(parts, options2));
59117  }
59118  var tagChild;
59119  if (tag2) {
59120    tagChild = buildHTMLUnbreakable(buildExpression$1(tag2, options2, true));
59121    tagChild.classes = ["tag"];
59122    children.push(tagChild);
59123  } else if (eqnNum) {
59124    children.push(eqnNum);
59125  }
59126  var htmlNode = makeSpan$1(["katex-html"], children);
59127  htmlNode.setAttribute("aria-hidden", "true");
59128  if (tagChild) {
59129    var strut = tagChild.children[0];
59130    strut.style.height = makeEm(htmlNode.height + htmlNode.depth);
59131    if (htmlNode.depth) {
59132      strut.style.verticalAlign = makeEm(-htmlNode.depth);
59133    }
59134  }
59135  return htmlNode;
59136}
59137function newDocumentFragment(children) {
59138  return new DocumentFragment(children);
59139}
59140var MathNode = class {
59141  constructor(type, children, classes2) {
59142    this.type = void 0;
59143    this.attributes = void 0;
59144    this.children = void 0;
59145    this.classes = void 0;
59146    this.type = type;
59147    this.attributes = {};
59148    this.children = children || [];
59149    this.classes = classes2 || [];
59150  }
59151  /**
59152   * Sets an attribute on a MathML node. MathML depends on attributes to convey a
59153   * semantic content, so this is used heavily.
59154   */
59155  setAttribute(name, value) {
59156    this.attributes[name] = value;
59157  }
59158  /**
59159   * Gets an attribute on a MathML node.
59160   */
59161  getAttribute(name) {
59162    return this.attributes[name];
59163  }
59164  /**
59165   * Converts the math node into a MathML-namespaced DOM element.
59166   */
59167  toNode() {
59168    var node = document.createElementNS("http://www.w3.org/1998/Math/MathML", this.type);
59169    for (var attr in this.attributes) {
59170      if (Object.prototype.hasOwnProperty.call(this.attributes, attr)) {
59171        node.setAttribute(attr, this.attributes[attr]);
59172      }
59173    }
59174    if (this.classes.length > 0) {
59175      node.className = createClass(this.classes);
59176    }
59177    for (var i = 0; i < this.children.length; i++) {
59178      if (this.children[i] instanceof TextNode && this.children[i + 1] instanceof TextNode) {
59179        var text2 = this.children[i].toText() + this.children[++i].toText();
59180        while (this.children[i + 1] instanceof TextNode) {
59181          text2 += this.children[++i].toText();
59182        }
59183        node.appendChild(new TextNode(text2).toNode());
59184      } else {
59185        node.appendChild(this.children[i].toNode());
59186      }
59187    }
59188    return node;
59189  }
59190  /**
59191   * Converts the math node into an HTML markup string.
59192   */
59193  toMarkup() {
59194    var markup = "<" + this.type;
59195    for (var attr in this.attributes) {
59196      if (Object.prototype.hasOwnProperty.call(this.attributes, attr)) {
59197        markup += " " + attr + '="';
59198        markup += utils.escape(this.attributes[attr]);
59199        markup += '"';
59200      }
59201    }
59202    if (this.classes.length > 0) {
59203      markup += ' class ="' + utils.escape(createClass(this.classes)) + '"';
59204    }
59205    markup += ">";
59206    for (var i = 0; i < this.children.length; i++) {
59207      markup += this.children[i].toMarkup();
59208    }
59209    markup += "</" + this.type + ">";
59210    return markup;
59211  }
59212  /**
59213   * Converts the math node into a string, similar to innerText, but escaped.
59214   */
59215  toText() {
59216    return this.children.map((child) => child.toText()).join("");
59217  }
59218};
59219var TextNode = class {
59220  constructor(text2) {
59221    this.text = void 0;
59222    this.text = text2;
59223  }
59224  /**
59225   * Converts the text node into a DOM text node.
59226   */
59227  toNode() {
59228    return document.createTextNode(this.text);
59229  }
59230  /**
59231   * Converts the text node into escaped HTML markup
59232   * (representing the text itself).
59233   */
59234  toMarkup() {
59235    return utils.escape(this.toText());
59236  }
59237  /**
59238   * Converts the text node into a string
59239   * (representing the text itself).
59240   */
59241  toText() {
59242    return this.text;
59243  }
59244};
59245var SpaceNode = class {
59246  /**
59247   * Create a Space node with width given in CSS ems.
59248   */
59249  constructor(width) {
59250    this.width = void 0;
59251    this.character = void 0;
59252    this.width = width;
59253    if (width >= 0.05555 && width <= 0.05556) {
59254      this.character = "\u200A";
59255    } else if (width >= 0.1666 && width <= 0.1667) {
59256      this.character = "\u2009";
59257    } else if (width >= 0.2222 && width <= 0.2223) {
59258      this.character = "\u2005";
59259    } else if (width >= 0.2777 && width <= 0.2778) {
59260      this.character = "\u2005\u200A";
59261    } else if (width >= -0.05556 && width <= -0.05555) {
59262      this.character = "\u200A\u2063";
59263    } else if (width >= -0.1667 && width <= -0.1666) {
59264      this.character = "\u2009\u2063";
59265    } else if (width >= -0.2223 && width <= -0.2222) {
59266      this.character = "\u205F\u2063";
59267    } else if (width >= -0.2778 && width <= -0.2777) {
59268      this.character = "\u2005\u2063";
59269    } else {
59270      this.character = null;
59271    }
59272  }
59273  /**
59274   * Converts the math node into a MathML-namespaced DOM element.
59275   */
59276  toNode() {
59277    if (this.character) {
59278      return document.createTextNode(this.character);
59279    } else {
59280      var node = document.createElementNS("http://www.w3.org/1998/Math/MathML", "mspace");
59281      node.setAttribute("width", makeEm(this.width));
59282      return node;
59283    }
59284  }
59285  /**
59286   * Converts the math node into an HTML markup string.
59287   */
59288  toMarkup() {
59289    if (this.character) {
59290      return "<mtext>" + this.character + "</mtext>";
59291    } else {
59292      return '<mspace width="' + makeEm(this.width) + '"/>';
59293    }
59294  }
59295  /**
59296   * Converts the math node into a string, similar to innerText.
59297   */
59298  toText() {
59299    if (this.character) {
59300      return this.character;
59301    } else {
59302      return " ";
59303    }
59304  }
59305};
59306var mathMLTree = {
59307  MathNode,
59308  TextNode,
59309  SpaceNode,
59310  newDocumentFragment
59311};
59312var makeText = function makeText2(text2, mode, options2) {
59313  if (symbols[mode][text2] && symbols[mode][text2].replace && text2.charCodeAt(0) !== 55349 && !(ligatures.hasOwnProperty(text2) && options2 && (options2.fontFamily && options2.fontFamily.slice(4, 6) === "tt" || options2.font && options2.font.slice(4, 6) === "tt"))) {
59314    text2 = symbols[mode][text2].replace;
59315  }
59316  return new mathMLTree.TextNode(text2);
59317};
59318var makeRow = function makeRow2(body) {
59319  if (body.length === 1) {
59320    return body[0];
59321  } else {
59322    return new mathMLTree.MathNode("mrow", body);
59323  }
59324};
59325var getVariant = function getVariant2(group, options2) {
59326  if (options2.fontFamily === "texttt") {
59327    return "monospace";
59328  } else if (options2.fontFamily === "textsf") {
59329    if (options2.fontShape === "textit" && options2.fontWeight === "textbf") {
59330      return "sans-serif-bold-italic";
59331    } else if (options2.fontShape === "textit") {
59332      return "sans-serif-italic";
59333    } else if (options2.fontWeight === "textbf") {
59334      return "bold-sans-serif";
59335    } else {
59336      return "sans-serif";
59337    }
59338  } else if (options2.fontShape === "textit" && options2.fontWeight === "textbf") {
59339    return "bold-italic";
59340  } else if (options2.fontShape === "textit") {
59341    return "italic";
59342  } else if (options2.fontWeight === "textbf") {
59343    return "bold";
59344  }
59345  var font = options2.font;
59346  if (!font || font === "mathnormal") {
59347    return null;
59348  }
59349  var mode = group.mode;
59350  if (font === "mathit") {
59351    return "italic";
59352  } else if (font === "boldsymbol") {
59353    return group.type === "textord" ? "bold" : "bold-italic";
59354  } else if (font === "mathbf") {
59355    return "bold";
59356  } else if (font === "mathbb") {
59357    return "double-struck";
59358  } else if (font === "mathsfit") {
59359    return "sans-serif-italic";
59360  } else if (font === "mathfrak") {
59361    return "fraktur";
59362  } else if (font === "mathscr" || font === "mathcal") {
59363    return "script";
59364  } else if (font === "mathsf") {
59365    return "sans-serif";
59366  } else if (font === "mathtt") {
59367    return "monospace";
59368  }
59369  var text2 = group.text;
59370  if (utils.contains(["\\imath", "\\jmath"], text2)) {
59371    return null;
59372  }
59373  if (symbols[mode][text2] && symbols[mode][text2].replace) {
59374    text2 = symbols[mode][text2].replace;
59375  }
59376  var fontName = buildCommon.fontMap[font].fontName;
59377  if (getCharacterMetrics(text2, fontName, mode)) {
59378    return buildCommon.fontMap[font].variant;
59379  }
59380  return null;
59381};
59382function isNumberPunctuation(group) {
59383  if (!group) {
59384    return false;
59385  }
59386  if (group.type === "mi" && group.children.length === 1) {
59387    var child = group.children[0];
59388    return child instanceof TextNode && child.text === ".";
59389  } else if (group.type === "mo" && group.children.length === 1 && group.getAttribute("separator") === "true" && group.getAttribute("lspace") === "0em" && group.getAttribute("rspace") === "0em") {
59390    var _child = group.children[0];
59391    return _child instanceof TextNode && _child.text === ",";
59392  } else {
59393    return false;
59394  }
59395}
59396var buildExpression2 = function buildExpression3(expression, options2, isOrdgroup) {
59397  if (expression.length === 1) {
59398    var group = buildGroup2(expression[0], options2);
59399    if (isOrdgroup && group instanceof MathNode && group.type === "mo") {
59400      group.setAttribute("lspace", "0em");
59401      group.setAttribute("rspace", "0em");
59402    }
59403    return [group];
59404  }
59405  var groups = [];
59406  var lastGroup;
59407  for (var i = 0; i < expression.length; i++) {
59408    var _group = buildGroup2(expression[i], options2);
59409    if (_group instanceof MathNode && lastGroup instanceof MathNode) {
59410      if (_group.type === "mtext" && lastGroup.type === "mtext" && _group.getAttribute("mathvariant") === lastGroup.getAttribute("mathvariant")) {
59411        lastGroup.children.push(..._group.children);
59412        continue;
59413      } else if (_group.type === "mn" && lastGroup.type === "mn") {
59414        lastGroup.children.push(..._group.children);
59415        continue;
59416      } else if (isNumberPunctuation(_group) && lastGroup.type === "mn") {
59417        lastGroup.children.push(..._group.children);
59418        continue;
59419      } else if (_group.type === "mn" && isNumberPunctuation(lastGroup)) {
59420        _group.children = [...lastGroup.children, ..._group.children];
59421        groups.pop();
59422      } else if ((_group.type === "msup" || _group.type === "msub") && _group.children.length >= 1 && (lastGroup.type === "mn" || isNumberPunctuation(lastGroup))) {
59423        var base = _group.children[0];
59424        if (base instanceof MathNode && base.type === "mn") {
59425          base.children = [...lastGroup.children, ...base.children];
59426          groups.pop();
59427        }
59428      } else if (lastGroup.type === "mi" && lastGroup.children.length === 1) {
59429        var lastChild = lastGroup.children[0];
59430        if (lastChild instanceof TextNode && lastChild.text === "\u0338" && (_group.type === "mo" || _group.type === "mi" || _group.type === "mn")) {
59431          var child = _group.children[0];
59432          if (child instanceof TextNode && child.text.length > 0) {
59433            child.text = child.text.slice(0, 1) + "\u0338" + child.text.slice(1);
59434            groups.pop();
59435          }
59436        }
59437      }
59438    }
59439    groups.push(_group);
59440    lastGroup = _group;
59441  }
59442  return groups;
59443};
59444var buildExpressionRow = function buildExpressionRow2(expression, options2, isOrdgroup) {
59445  return makeRow(buildExpression2(expression, options2, isOrdgroup));
59446};
59447var buildGroup2 = function buildGroup3(group, options2) {
59448  if (!group) {
59449    return new mathMLTree.MathNode("mrow");
59450  }
59451  if (_mathmlGroupBuilders[group.type]) {
59452    var result = _mathmlGroupBuilders[group.type](group, options2);
59453    return result;
59454  } else {
59455    throw new ParseError("Got group of unknown type: '" + group.type + "'");
59456  }
59457};
59458function buildMathML(tree, texExpression, options2, isDisplayMode, forMathmlOnly) {
59459  var expression = buildExpression2(tree, options2);
59460  var wrapper;
59461  if (expression.length === 1 && expression[0] instanceof MathNode && utils.contains(["mrow", "mtable"], expression[0].type)) {
59462    wrapper = expression[0];
59463  } else {
59464    wrapper = new mathMLTree.MathNode("mrow", expression);
59465  }
59466  var annotation = new mathMLTree.MathNode("annotation", [new mathMLTree.TextNode(texExpression)]);
59467  annotation.setAttribute("encoding", "application/x-tex");
59468  var semantics = new mathMLTree.MathNode("semantics", [wrapper, annotation]);
59469  var math2 = new mathMLTree.MathNode("math", [semantics]);
59470  math2.setAttribute("xmlns", "http://www.w3.org/1998/Math/MathML");
59471  if (isDisplayMode) {
59472    math2.setAttribute("display", "block");
59473  }
59474  var wrapperClass = forMathmlOnly ? "katex" : "katex-mathml";
59475  return buildCommon.makeSpan([wrapperClass], [math2]);
59476}
59477var optionsFromSettings = function optionsFromSettings2(settings) {
59478  return new Options({
59479    style: settings.displayMode ? Style$1.DISPLAY : Style$1.TEXT,
59480    maxSize: settings.maxSize,
59481    minRuleThickness: settings.minRuleThickness
59482  });
59483};
59484var displayWrap = function displayWrap2(node, settings) {
59485  if (settings.displayMode) {
59486    var classes2 = ["katex-display"];
59487    if (settings.leqno) {
59488      classes2.push("leqno");
59489    }
59490    if (settings.fleqn) {
59491      classes2.push("fleqn");
59492    }
59493    node = buildCommon.makeSpan(classes2, [node]);
59494  }
59495  return node;
59496};
59497var buildTree = function buildTree2(tree, expression, settings) {
59498  var options2 = optionsFromSettings(settings);
59499  var katexNode;
59500  if (settings.output === "mathml") {
59501    return buildMathML(tree, expression, options2, settings.displayMode, true);
59502  } else if (settings.output === "html") {
59503    var htmlNode = buildHTML(tree, options2);
59504    katexNode = buildCommon.makeSpan(["katex"], [htmlNode]);
59505  } else {
59506    var mathMLNode = buildMathML(tree, expression, options2, settings.displayMode, false);
59507    var _htmlNode = buildHTML(tree, options2);
59508    katexNode = buildCommon.makeSpan(["katex"], [mathMLNode, _htmlNode]);
59509  }
59510  return displayWrap(katexNode, settings);
59511};
59512var stretchyCodePoint = {
59513  widehat: "^",
59514  widecheck: "\u02C7",
59515  widetilde: "~",
59516  utilde: "~",
59517  overleftarrow: "\u2190",
59518  underleftarrow: "\u2190",
59519  xleftarrow: "\u2190",
59520  overrightarrow: "\u2192",
59521  underrightarrow: "\u2192",
59522  xrightarrow: "\u2192",
59523  underbrace: "\u23DF",
59524  overbrace: "\u23DE",
59525  overgroup: "\u23E0",
59526  undergroup: "\u23E1",
59527  overleftrightarrow: "\u2194",
59528  underleftrightarrow: "\u2194",
59529  xleftrightarrow: "\u2194",
59530  Overrightarrow: "\u21D2",
59531  xRightarrow: "\u21D2",
59532  overleftharpoon: "\u21BC",
59533  xleftharpoonup: "\u21BC",
59534  overrightharpoon: "\u21C0",
59535  xrightharpoonup: "\u21C0",
59536  xLeftarrow: "\u21D0",
59537  xLeftrightarrow: "\u21D4",
59538  xhookleftarrow: "\u21A9",
59539  xhookrightarrow: "\u21AA",
59540  xmapsto: "\u21A6",
59541  xrightharpoondown: "\u21C1",
59542  xleftharpoondown: "\u21BD",
59543  xrightleftharpoons: "\u21CC",
59544  xleftrightharpoons: "\u21CB",
59545  xtwoheadleftarrow: "\u219E",
59546  xtwoheadrightarrow: "\u21A0",
59547  xlongequal: "=",
59548  xtofrom: "\u21C4",
59549  xrightleftarrows: "\u21C4",
59550  xrightequilibrium: "\u21CC",
59551  // Not a perfect match.
59552  xleftequilibrium: "\u21CB",
59553  // None better available.
59554  "\\cdrightarrow": "\u2192",
59555  "\\cdleftarrow": "\u2190",
59556  "\\cdlongequal": "="
59557};
59558var mathMLnode = function mathMLnode2(label) {
59559  var node = new mathMLTree.MathNode("mo", [new mathMLTree.TextNode(stretchyCodePoint[label.replace(/^\\/, "")])]);
59560  node.setAttribute("stretchy", "true");
59561  return node;
59562};
59563var katexImagesData = {
59564  //   path(s), minWidth, height, align
59565  overrightarrow: [["rightarrow"], 0.888, 522, "xMaxYMin"],
59566  overleftarrow: [["leftarrow"], 0.888, 522, "xMinYMin"],
59567  underrightarrow: [["rightarrow"], 0.888, 522, "xMaxYMin"],
59568  underleftarrow: [["leftarrow"], 0.888, 522, "xMinYMin"],
59569  xrightarrow: [["rightarrow"], 1.469, 522, "xMaxYMin"],
59570  "\\cdrightarrow": [["rightarrow"], 3, 522, "xMaxYMin"],
59571  // CD minwwidth2.5pc
59572  xleftarrow: [["leftarrow"], 1.469, 522, "xMinYMin"],
59573  "\\cdleftarrow": [["leftarrow"], 3, 522, "xMinYMin"],
59574  Overrightarrow: [["doublerightarrow"], 0.888, 560, "xMaxYMin"],
59575  xRightarrow: [["doublerightarrow"], 1.526, 560, "xMaxYMin"],
59576  xLeftarrow: [["doubleleftarrow"], 1.526, 560, "xMinYMin"],
59577  overleftharpoon: [["leftharpoon"], 0.888, 522, "xMinYMin"],
59578  xleftharpoonup: [["leftharpoon"], 0.888, 522, "xMinYMin"],
59579  xleftharpoondown: [["leftharpoondown"], 0.888, 522, "xMinYMin"],
59580  overrightharpoon: [["rightharpoon"], 0.888, 522, "xMaxYMin"],
59581  xrightharpoonup: [["rightharpoon"], 0.888, 522, "xMaxYMin"],
59582  xrightharpoondown: [["rightharpoondown"], 0.888, 522, "xMaxYMin"],
59583  xlongequal: [["longequal"], 0.888, 334, "xMinYMin"],
59584  "\\cdlongequal": [["longequal"], 3, 334, "xMinYMin"],
59585  xtwoheadleftarrow: [["twoheadleftarrow"], 0.888, 334, "xMinYMin"],
59586  xtwoheadrightarrow: [["twoheadrightarrow"], 0.888, 334, "xMaxYMin"],
59587  overleftrightarrow: [["leftarrow", "rightarrow"], 0.888, 522],
59588  overbrace: [["leftbrace", "midbrace", "rightbrace"], 1.6, 548],
59589  underbrace: [["leftbraceunder", "midbraceunder", "rightbraceunder"], 1.6, 548],
59590  underleftrightarrow: [["leftarrow", "rightarrow"], 0.888, 522],
59591  xleftrightarrow: [["leftarrow", "rightarrow"], 1.75, 522],
59592  xLeftrightarrow: [["doubleleftarrow", "doublerightarrow"], 1.75, 560],
59593  xrightleftharpoons: [["leftharpoondownplus", "rightharpoonplus"], 1.75, 716],
59594  xleftrightharpoons: [["leftharpoonplus", "rightharpoondownplus"], 1.75, 716],
59595  xhookleftarrow: [["leftarrow", "righthook"], 1.08, 522],
59596  xhookrightarrow: [["lefthook", "rightarrow"], 1.08, 522],
59597  overlinesegment: [["leftlinesegment", "rightlinesegment"], 0.888, 522],
59598  underlinesegment: [["leftlinesegment", "rightlinesegment"], 0.888, 522],
59599  overgroup: [["leftgroup", "rightgroup"], 0.888, 342],
59600  undergroup: [["leftgroupunder", "rightgroupunder"], 0.888, 342],
59601  xmapsto: [["leftmapsto", "rightarrow"], 1.5, 522],
59602  xtofrom: [["leftToFrom", "rightToFrom"], 1.75, 528],
59603  // The next three arrows are from the mhchem package.
59604  // In mhchem.sty, min-length is 2.0em. But these arrows might appear in the
59605  // document as \xrightarrow or \xrightleftharpoons. Those have
59606  // min-length = 1.75em, so we set min-length on these next three to match.
59607  xrightleftarrows: [["baraboveleftarrow", "rightarrowabovebar"], 1.75, 901],
59608  xrightequilibrium: [["baraboveshortleftharpoon", "rightharpoonaboveshortbar"], 1.75, 716],
59609  xleftequilibrium: [["shortbaraboveleftharpoon", "shortrightharpoonabovebar"], 1.75, 716]
59610};
59611var groupLength = function groupLength2(arg) {
59612  if (arg.type === "ordgroup") {
59613    return arg.body.length;
59614  } else {
59615    return 1;
59616  }
59617};
59618var svgSpan = function svgSpan2(group, options2) {
59619  function buildSvgSpan_() {
59620    var viewBoxWidth = 4e5;
59621    var label = group.label.slice(1);
59622    if (utils.contains(["widehat", "widecheck", "widetilde", "utilde"], label)) {
59623      var grp = group;
59624      var numChars = groupLength(grp.base);
59625      var viewBoxHeight;
59626      var pathName;
59627      var _height;
59628      if (numChars > 5) {
59629        if (label === "widehat" || label === "widecheck") {
59630          viewBoxHeight = 420;
59631          viewBoxWidth = 2364;
59632          _height = 0.42;
59633          pathName = label + "4";
59634        } else {
59635          viewBoxHeight = 312;
59636          viewBoxWidth = 2340;
59637          _height = 0.34;
59638          pathName = "tilde4";
59639        }
59640      } else {
59641        var imgIndex = [1, 1, 2, 2, 3, 3][numChars];
59642        if (label === "widehat" || label === "widecheck") {
59643          viewBoxWidth = [0, 1062, 2364, 2364, 2364][imgIndex];
59644          viewBoxHeight = [0, 239, 300, 360, 420][imgIndex];
59645          _height = [0, 0.24, 0.3, 0.3, 0.36, 0.42][imgIndex];
59646          pathName = label + imgIndex;
59647        } else {
59648          viewBoxWidth = [0, 600, 1033, 2339, 2340][imgIndex];
59649          viewBoxHeight = [0, 260, 286, 306, 312][imgIndex];
59650          _height = [0, 0.26, 0.286, 0.3, 0.306, 0.34][imgIndex];
59651          pathName = "tilde" + imgIndex;
59652        }
59653      }
59654      var path2 = new PathNode(pathName);
59655      var svgNode = new SvgNode([path2], {
59656        "width": "100%",
59657        "height": makeEm(_height),
59658        "viewBox": "0 0 " + viewBoxWidth + " " + viewBoxHeight,
59659        "preserveAspectRatio": "none"
59660      });
59661      return {
59662        span: buildCommon.makeSvgSpan([], [svgNode], options2),
59663        minWidth: 0,
59664        height: _height
59665      };
59666    } else {
59667      var spans = [];
59668      var data = katexImagesData[label];
59669      var [paths, _minWidth, _viewBoxHeight] = data;
59670      var _height2 = _viewBoxHeight / 1e3;
59671      var numSvgChildren = paths.length;
59672      var widthClasses;
59673      var aligns;
59674      if (numSvgChildren === 1) {
59675        var align1 = data[3];
59676        widthClasses = ["hide-tail"];
59677        aligns = [align1];
59678      } else if (numSvgChildren === 2) {
59679        widthClasses = ["halfarrow-left", "halfarrow-right"];
59680        aligns = ["xMinYMin", "xMaxYMin"];
59681      } else if (numSvgChildren === 3) {
59682        widthClasses = ["brace-left", "brace-center", "brace-right"];
59683        aligns = ["xMinYMin", "xMidYMin", "xMaxYMin"];
59684      } else {
59685        throw new Error("Correct katexImagesData or update code here to support\n                    " + numSvgChildren + " children.");
59686      }
59687      for (var i = 0; i < numSvgChildren; i++) {
59688        var _path = new PathNode(paths[i]);
59689        var _svgNode = new SvgNode([_path], {
59690          "width": "400em",
59691          "height": makeEm(_height2),
59692          "viewBox": "0 0 " + viewBoxWidth + " " + _viewBoxHeight,
59693          "preserveAspectRatio": aligns[i] + " slice"
59694        });
59695        var _span = buildCommon.makeSvgSpan([widthClasses[i]], [_svgNode], options2);
59696        if (numSvgChildren === 1) {
59697          return {
59698            span: _span,
59699            minWidth: _minWidth,
59700            height: _height2
59701          };
59702        } else {
59703          _span.style.height = makeEm(_height2);
59704          spans.push(_span);
59705        }
59706      }
59707      return {
59708        span: buildCommon.makeSpan(["stretchy"], spans, options2),
59709        minWidth: _minWidth,
59710        height: _height2
59711      };
59712    }
59713  }
59714  var {
59715    span,
59716    minWidth,
59717    height
59718  } = buildSvgSpan_();
59719  span.height = height;
59720  span.style.height = makeEm(height);
59721  if (minWidth > 0) {
59722    span.style.minWidth = makeEm(minWidth);
59723  }
59724  return span;
59725};
59726var encloseSpan = function encloseSpan2(inner2, label, topPad, bottomPad, options2) {
59727  var img;
59728  var totalHeight = inner2.height + inner2.depth + topPad + bottomPad;
59729  if (/fbox|color|angl/.test(label)) {
59730    img = buildCommon.makeSpan(["stretchy", label], [], options2);
59731    if (label === "fbox") {
59732      var color = options2.color && options2.getColor();
59733      if (color) {
59734        img.style.borderColor = color;
59735      }
59736    }
59737  } else {
59738    var lines = [];
59739    if (/^[bx]cancel$/.test(label)) {
59740      lines.push(new LineNode({
59741        "x1": "0",
59742        "y1": "0",
59743        "x2": "100%",
59744        "y2": "100%",
59745        "stroke-width": "0.046em"
59746      }));
59747    }
59748    if (/^x?cancel$/.test(label)) {
59749      lines.push(new LineNode({
59750        "x1": "0",
59751        "y1": "100%",
59752        "x2": "100%",
59753        "y2": "0",
59754        "stroke-width": "0.046em"
59755      }));
59756    }
59757    var svgNode = new SvgNode(lines, {
59758      "width": "100%",
59759      "height": makeEm(totalHeight)
59760    });
59761    img = buildCommon.makeSvgSpan([], [svgNode], options2);
59762  }
59763  img.height = totalHeight;
59764  img.style.height = makeEm(totalHeight);
59765  return img;
59766};
59767var stretchy = {
59768  encloseSpan,
59769  mathMLnode,
59770  svgSpan
59771};
59772function assertNodeType(node, type) {
59773  if (!node || node.type !== type) {
59774    throw new Error("Expected node of type " + type + ", but got " + (node ? "node of type " + node.type : String(node)));
59775  }
59776  return node;
59777}
59778function assertSymbolNodeType(node) {
59779  var typedNode = checkSymbolNodeType(node);
59780  if (!typedNode) {
59781    throw new Error("Expected node of symbol group type, but got " + (node ? "node of type " + node.type : String(node)));
59782  }
59783  return typedNode;
59784}
59785function checkSymbolNodeType(node) {
59786  if (node && (node.type === "atom" || NON_ATOMS.hasOwnProperty(node.type))) {
59787    return node;
59788  }
59789  return null;
59790}
59791var htmlBuilder$a = (grp, options2) => {
59792  var base;
59793  var group;
59794  var supSubGroup;
59795  if (grp && grp.type === "supsub") {
59796    group = assertNodeType(grp.base, "accent");
59797    base = group.base;
59798    grp.base = base;
59799    supSubGroup = assertSpan(buildGroup$1(grp, options2));
59800    grp.base = group;
59801  } else {
59802    group = assertNodeType(grp, "accent");
59803    base = group.base;
59804  }
59805  var body = buildGroup$1(base, options2.havingCrampedStyle());
59806  var mustShift = group.isShifty && utils.isCharacterBox(base);
59807  var skew = 0;
59808  if (mustShift) {
59809    var baseChar = utils.getBaseElem(base);
59810    var baseGroup = buildGroup$1(baseChar, options2.havingCrampedStyle());
59811    skew = assertSymbolDomNode(baseGroup).skew;
59812  }
59813  var accentBelow = group.label === "\\c";
59814  var clearance = accentBelow ? body.height + body.depth : Math.min(body.height, options2.fontMetrics().xHeight);
59815  var accentBody;
59816  if (!group.isStretchy) {
59817    var accent2;
59818    var width;
59819    if (group.label === "\\vec") {
59820      accent2 = buildCommon.staticSvg("vec", options2);
59821      width = buildCommon.svgData.vec[1];
59822    } else {
59823      accent2 = buildCommon.makeOrd({
59824        mode: group.mode,
59825        text: group.label
59826      }, options2, "textord");
59827      accent2 = assertSymbolDomNode(accent2);
59828      accent2.italic = 0;
59829      width = accent2.width;
59830      if (accentBelow) {
59831        clearance += accent2.depth;
59832      }
59833    }
59834    accentBody = buildCommon.makeSpan(["accent-body"], [accent2]);
59835    var accentFull = group.label === "\\textcircled";
59836    if (accentFull) {
59837      accentBody.classes.push("accent-full");
59838      clearance = body.height;
59839    }
59840    var left = skew;
59841    if (!accentFull) {
59842      left -= width / 2;
59843    }
59844    accentBody.style.left = makeEm(left);
59845    if (group.label === "\\textcircled") {
59846      accentBody.style.top = ".2em";
59847    }
59848    accentBody = buildCommon.makeVList({
59849      positionType: "firstBaseline",
59850      children: [{
59851        type: "elem",
59852        elem: body
59853      }, {
59854        type: "kern",
59855        size: -clearance
59856      }, {
59857        type: "elem",
59858        elem: accentBody
59859      }]
59860    }, options2);
59861  } else {
59862    accentBody = stretchy.svgSpan(group, options2);
59863    accentBody = buildCommon.makeVList({
59864      positionType: "firstBaseline",
59865      children: [{
59866        type: "elem",
59867        elem: body
59868      }, {
59869        type: "elem",
59870        elem: accentBody,
59871        wrapperClasses: ["svg-align"],
59872        wrapperStyle: skew > 0 ? {
59873          width: "calc(100% - " + makeEm(2 * skew) + ")",
59874          marginLeft: makeEm(2 * skew)
59875        } : void 0
59876      }]
59877    }, options2);
59878  }
59879  var accentWrap = buildCommon.makeSpan(["mord", "accent"], [accentBody], options2);
59880  if (supSubGroup) {
59881    supSubGroup.children[0] = accentWrap;
59882    supSubGroup.height = Math.max(accentWrap.height, supSubGroup.height);
59883    supSubGroup.classes[0] = "mord";
59884    return supSubGroup;
59885  } else {
59886    return accentWrap;
59887  }
59888};
59889var mathmlBuilder$9 = (group, options2) => {
59890  var accentNode = group.isStretchy ? stretchy.mathMLnode(group.label) : new mathMLTree.MathNode("mo", [makeText(group.label, group.mode)]);
59891  var node = new mathMLTree.MathNode("mover", [buildGroup2(group.base, options2), accentNode]);
59892  node.setAttribute("accent", "true");
59893  return node;
59894};
59895var NON_STRETCHY_ACCENT_REGEX = new RegExp(["\\acute", "\\grave", "\\ddot", "\\tilde", "\\bar", "\\breve", "\\check", "\\hat", "\\vec", "\\dot", "\\mathring"].map((accent2) => "\\" + accent2).join("|"));
59896defineFunction({
59897  type: "accent",
59898  names: ["\\acute", "\\grave", "\\ddot", "\\tilde", "\\bar", "\\breve", "\\check", "\\hat", "\\vec", "\\dot", "\\mathring", "\\widecheck", "\\widehat", "\\widetilde", "\\overrightarrow", "\\overleftarrow", "\\Overrightarrow", "\\overleftrightarrow", "\\overgroup", "\\overlinesegment", "\\overleftharpoon", "\\overrightharpoon"],
59899  props: {
59900    numArgs: 1
59901  },
59902  handler: (context, args) => {
59903    var base = normalizeArgument(args[0]);
59904    var isStretchy = !NON_STRETCHY_ACCENT_REGEX.test(context.funcName);
59905    var isShifty = !isStretchy || context.funcName === "\\widehat" || context.funcName === "\\widetilde" || context.funcName === "\\widecheck";
59906    return {
59907      type: "accent",
59908      mode: context.parser.mode,
59909      label: context.funcName,
59910      isStretchy,
59911      isShifty,
59912      base
59913    };
59914  },
59915  htmlBuilder: htmlBuilder$a,
59916  mathmlBuilder: mathmlBuilder$9
59917});
59918defineFunction({
59919  type: "accent",
59920  names: ["\\'", "\\`", "\\^", "\\~", "\\=", "\\u", "\\.", '\\"', "\\c", "\\r", "\\H", "\\v", "\\textcircled"],
59921  props: {
59922    numArgs: 1,
59923    allowedInText: true,
59924    allowedInMath: true,
59925    // unless in strict mode
59926    argTypes: ["primitive"]
59927  },
59928  handler: (context, args) => {
59929    var base = args[0];
59930    var mode = context.parser.mode;
59931    if (mode === "math") {
59932      context.parser.settings.reportNonstrict("mathVsTextAccents", "LaTeX's accent " + context.funcName + " works only in text mode");
59933      mode = "text";
59934    }
59935    return {
59936      type: "accent",
59937      mode,
59938      label: context.funcName,
59939      isStretchy: false,
59940      isShifty: true,
59941      base
59942    };
59943  },
59944  htmlBuilder: htmlBuilder$a,
59945  mathmlBuilder: mathmlBuilder$9
59946});
59947defineFunction({
59948  type: "accentUnder",
59949  names: ["\\underleftarrow", "\\underrightarrow", "\\underleftrightarrow", "\\undergroup", "\\underlinesegment", "\\utilde"],
59950  props: {
59951    numArgs: 1
59952  },
59953  handler: (_ref, args) => {
59954    var {
59955      parser: parser2,
59956      funcName
59957    } = _ref;
59958    var base = args[0];
59959    return {
59960      type: "accentUnder",
59961      mode: parser2.mode,
59962      label: funcName,
59963      base
59964    };
59965  },
59966  htmlBuilder: (group, options2) => {
59967    var innerGroup = buildGroup$1(group.base, options2);
59968    var accentBody = stretchy.svgSpan(group, options2);
59969    var kern = group.label === "\\utilde" ? 0.12 : 0;
59970    var vlist = buildCommon.makeVList({
59971      positionType: "top",
59972      positionData: innerGroup.height,
59973      children: [{
59974        type: "elem",
59975        elem: accentBody,
59976        wrapperClasses: ["svg-align"]
59977      }, {
59978        type: "kern",
59979        size: kern
59980      }, {
59981        type: "elem",
59982        elem: innerGroup
59983      }]
59984    }, options2);
59985    return buildCommon.makeSpan(["mord", "accentunder"], [vlist], options2);
59986  },
59987  mathmlBuilder: (group, options2) => {
59988    var accentNode = stretchy.mathMLnode(group.label);
59989    var node = new mathMLTree.MathNode("munder", [buildGroup2(group.base, options2), accentNode]);
59990    node.setAttribute("accentunder", "true");
59991    return node;
59992  }
59993});
59994var paddedNode = (group) => {
59995  var node = new mathMLTree.MathNode("mpadded", group ? [group] : []);
59996  node.setAttribute("width", "+0.6em");
59997  node.setAttribute("lspace", "0.3em");
59998  return node;
59999};
60000defineFunction({
60001  type: "xArrow",
60002  names: [
60003    "\\xleftarrow",
60004    "\\xrightarrow",
60005    "\\xLeftarrow",
60006    "\\xRightarrow",
60007    "\\xleftrightarrow",
60008    "\\xLeftrightarrow",
60009    "\\xhookleftarrow",
60010    "\\xhookrightarrow",
60011    "\\xmapsto",
60012    "\\xrightharpoondown",
60013    "\\xrightharpoonup",
60014    "\\xleftharpoondown",
60015    "\\xleftharpoonup",
60016    "\\xrightleftharpoons",
60017    "\\xleftrightharpoons",
60018    "\\xlongequal",
60019    "\\xtwoheadrightarrow",
60020    "\\xtwoheadleftarrow",
60021    "\\xtofrom",
60022    // The next 3 functions are here to support the mhchem extension.
60023    // Direct use of these functions is discouraged and may break someday.
60024    "\\xrightleftarrows",
60025    "\\xrightequilibrium",
60026    "\\xleftequilibrium",
60027    // The next 3 functions are here only to support the {CD} environment.
60028    "\\\\cdrightarrow",
60029    "\\\\cdleftarrow",
60030    "\\\\cdlongequal"
60031  ],
60032  props: {
60033    numArgs: 1,
60034    numOptionalArgs: 1
60035  },
60036  handler(_ref, args, optArgs) {
60037    var {
60038      parser: parser2,
60039      funcName
60040    } = _ref;
60041    return {
60042      type: "xArrow",
60043      mode: parser2.mode,
60044      label: funcName,
60045      body: args[0],
60046      below: optArgs[0]
60047    };
60048  },
60049  // Flow is unable to correctly infer the type of `group`, even though it's
60050  // unambiguously determined from the passed-in `type` above.
60051  htmlBuilder(group, options2) {
60052    var style = options2.style;
60053    var newOptions = options2.havingStyle(style.sup());
60054    var upperGroup = buildCommon.wrapFragment(buildGroup$1(group.body, newOptions, options2), options2);
60055    var arrowPrefix = group.label.slice(0, 2) === "\\x" ? "x" : "cd";
60056    upperGroup.classes.push(arrowPrefix + "-arrow-pad");
60057    var lowerGroup;
60058    if (group.below) {
60059      newOptions = options2.havingStyle(style.sub());
60060      lowerGroup = buildCommon.wrapFragment(buildGroup$1(group.below, newOptions, options2), options2);
60061      lowerGroup.classes.push(arrowPrefix + "-arrow-pad");
60062    }
60063    var arrowBody = stretchy.svgSpan(group, options2);
60064    var arrowShift = -options2.fontMetrics().axisHeight + 0.5 * arrowBody.height;
60065    var upperShift = -options2.fontMetrics().axisHeight - 0.5 * arrowBody.height - 0.111;
60066    if (upperGroup.depth > 0.25 || group.label === "\\xleftequilibrium") {
60067      upperShift -= upperGroup.depth;
60068    }
60069    var vlist;
60070    if (lowerGroup) {
60071      var lowerShift = -options2.fontMetrics().axisHeight + lowerGroup.height + 0.5 * arrowBody.height + 0.111;
60072      vlist = buildCommon.makeVList({
60073        positionType: "individualShift",
60074        children: [{
60075          type: "elem",
60076          elem: upperGroup,
60077          shift: upperShift
60078        }, {
60079          type: "elem",
60080          elem: arrowBody,
60081          shift: arrowShift
60082        }, {
60083          type: "elem",
60084          elem: lowerGroup,
60085          shift: lowerShift
60086        }]
60087      }, options2);
60088    } else {
60089      vlist = buildCommon.makeVList({
60090        positionType: "individualShift",
60091        children: [{
60092          type: "elem",
60093          elem: upperGroup,
60094          shift: upperShift
60095        }, {
60096          type: "elem",
60097          elem: arrowBody,
60098          shift: arrowShift
60099        }]
60100      }, options2);
60101    }
60102    vlist.children[0].children[0].children[1].classes.push("svg-align");
60103    return buildCommon.makeSpan(["mrel", "x-arrow"], [vlist], options2);
60104  },
60105  mathmlBuilder(group, options2) {
60106    var arrowNode = stretchy.mathMLnode(group.label);
60107    arrowNode.setAttribute("minsize", group.label.charAt(0) === "x" ? "1.75em" : "3.0em");
60108    var node;
60109    if (group.body) {
60110      var upperNode = paddedNode(buildGroup2(group.body, options2));
60111      if (group.below) {
60112        var lowerNode = paddedNode(buildGroup2(group.below, options2));
60113        node = new mathMLTree.MathNode("munderover", [arrowNode, lowerNode, upperNode]);
60114      } else {
60115        node = new mathMLTree.MathNode("mover", [arrowNode, upperNode]);
60116      }
60117    } else if (group.below) {
60118      var _lowerNode = paddedNode(buildGroup2(group.below, options2));
60119      node = new mathMLTree.MathNode("munder", [arrowNode, _lowerNode]);
60120    } else {
60121      node = paddedNode();
60122      node = new mathMLTree.MathNode("mover", [arrowNode, node]);
60123    }
60124    return node;
60125  }
60126});
60127var makeSpan2 = buildCommon.makeSpan;
60128function htmlBuilder$9(group, options2) {
60129  var elements = buildExpression$1(group.body, options2, true);
60130  return makeSpan2([group.mclass], elements, options2);
60131}
60132function mathmlBuilder$8(group, options2) {
60133  var node;
60134  var inner2 = buildExpression2(group.body, options2);
60135  if (group.mclass === "minner") {
60136    node = new mathMLTree.MathNode("mpadded", inner2);
60137  } else if (group.mclass === "mord") {
60138    if (group.isCharacterBox) {
60139      node = inner2[0];
60140      node.type = "mi";
60141    } else {
60142      node = new mathMLTree.MathNode("mi", inner2);
60143    }
60144  } else {
60145    if (group.isCharacterBox) {
60146      node = inner2[0];
60147      node.type = "mo";
60148    } else {
60149      node = new mathMLTree.MathNode("mo", inner2);
60150    }
60151    if (group.mclass === "mbin") {
60152      node.attributes.lspace = "0.22em";
60153      node.attributes.rspace = "0.22em";
60154    } else if (group.mclass === "mpunct") {
60155      node.attributes.lspace = "0em";
60156      node.attributes.rspace = "0.17em";
60157    } else if (group.mclass === "mopen" || group.mclass === "mclose") {
60158      node.attributes.lspace = "0em";
60159      node.attributes.rspace = "0em";
60160    } else if (group.mclass === "minner") {
60161      node.attributes.lspace = "0.0556em";
60162      node.attributes.width = "+0.1111em";
60163    }
60164  }
60165  return node;
60166}
60167defineFunction({
60168  type: "mclass",
60169  names: ["\\mathord", "\\mathbin", "\\mathrel", "\\mathopen", "\\mathclose", "\\mathpunct", "\\mathinner"],
60170  props: {
60171    numArgs: 1,
60172    primitive: true
60173  },
60174  handler(_ref, args) {
60175    var {
60176      parser: parser2,
60177      funcName
60178    } = _ref;
60179    var body = args[0];
60180    return {
60181      type: "mclass",
60182      mode: parser2.mode,
60183      mclass: "m" + funcName.slice(5),
60184      // TODO(kevinb): don't prefix with 'm'
60185      body: ordargument(body),
60186      isCharacterBox: utils.isCharacterBox(body)
60187    };
60188  },
60189  htmlBuilder: htmlBuilder$9,
60190  mathmlBuilder: mathmlBuilder$8
60191});
60192var binrelClass = (arg) => {
60193  var atom = arg.type === "ordgroup" && arg.body.length ? arg.body[0] : arg;
60194  if (atom.type === "atom" && (atom.family === "bin" || atom.family === "rel")) {
60195    return "m" + atom.family;
60196  } else {
60197    return "mord";
60198  }
60199};
60200defineFunction({
60201  type: "mclass",
60202  names: ["\\@binrel"],
60203  props: {
60204    numArgs: 2
60205  },
60206  handler(_ref2, args) {
60207    var {
60208      parser: parser2
60209    } = _ref2;
60210    return {
60211      type: "mclass",
60212      mode: parser2.mode,
60213      mclass: binrelClass(args[0]),
60214      body: ordargument(args[1]),
60215      isCharacterBox: utils.isCharacterBox(args[1])
60216    };
60217  }
60218});
60219defineFunction({
60220  type: "mclass",
60221  names: ["\\stackrel", "\\overset", "\\underset"],
60222  props: {
60223    numArgs: 2
60224  },
60225  handler(_ref3, args) {
60226    var {
60227      parser: parser2,
60228      funcName
60229    } = _ref3;
60230    var baseArg = args[1];
60231    var shiftedArg = args[0];
60232    var mclass;
60233    if (funcName !== "\\stackrel") {
60234      mclass = binrelClass(baseArg);
60235    } else {
60236      mclass = "mrel";
60237    }
60238    var baseOp = {
60239      type: "op",
60240      mode: baseArg.mode,
60241      limits: true,
60242      alwaysHandleSupSub: true,
60243      parentIsSupSub: false,
60244      symbol: false,
60245      suppressBaseShift: funcName !== "\\stackrel",
60246      body: ordargument(baseArg)
60247    };
60248    var supsub = {
60249      type: "supsub",
60250      mode: shiftedArg.mode,
60251      base: baseOp,
60252      sup: funcName === "\\underset" ? null : shiftedArg,
60253      sub: funcName === "\\underset" ? shiftedArg : null
60254    };
60255    return {
60256      type: "mclass",
60257      mode: parser2.mode,
60258      mclass,
60259      body: [supsub],
60260      isCharacterBox: utils.isCharacterBox(supsub)
60261    };
60262  },
60263  htmlBuilder: htmlBuilder$9,
60264  mathmlBuilder: mathmlBuilder$8
60265});
60266defineFunction({
60267  type: "pmb",
60268  names: ["\\pmb"],
60269  props: {
60270    numArgs: 1,
60271    allowedInText: true
60272  },
60273  handler(_ref, args) {
60274    var {
60275      parser: parser2
60276    } = _ref;
60277    return {
60278      type: "pmb",
60279      mode: parser2.mode,
60280      mclass: binrelClass(args[0]),
60281      body: ordargument(args[0])
60282    };
60283  },
60284  htmlBuilder(group, options2) {
60285    var elements = buildExpression$1(group.body, options2, true);
60286    var node = buildCommon.makeSpan([group.mclass], elements, options2);
60287    node.style.textShadow = "0.02em 0.01em 0.04px";
60288    return node;
60289  },
60290  mathmlBuilder(group, style) {
60291    var inner2 = buildExpression2(group.body, style);
60292    var node = new mathMLTree.MathNode("mstyle", inner2);
60293    node.setAttribute("style", "text-shadow: 0.02em 0.01em 0.04px");
60294    return node;
60295  }
60296});
60297var cdArrowFunctionName = {
60298  ">": "\\\\cdrightarrow",
60299  "<": "\\\\cdleftarrow",
60300  "=": "\\\\cdlongequal",
60301  "A": "\\uparrow",
60302  "V": "\\downarrow",
60303  "|": "\\Vert",
60304  ".": "no arrow"
60305};
60306var newCell = () => {
60307  return {
60308    type: "styling",
60309    body: [],
60310    mode: "math",
60311    style: "display"
60312  };
60313};
60314var isStartOfArrow = (node) => {
60315  return node.type === "textord" && node.text === "@";
60316};
60317var isLabelEnd = (node, endChar) => {
60318  return (node.type === "mathord" || node.type === "atom") && node.text === endChar;
60319};
60320function cdArrow(arrowChar, labels, parser2) {
60321  var funcName = cdArrowFunctionName[arrowChar];
60322  switch (funcName) {
60323    case "\\\\cdrightarrow":
60324    case "\\\\cdleftarrow":
60325      return parser2.callFunction(funcName, [labels[0]], [labels[1]]);
60326    case "\\uparrow":
60327    case "\\downarrow": {
60328      var leftLabel = parser2.callFunction("\\\\cdleft", [labels[0]], []);
60329      var bareArrow = {
60330        type: "atom",
60331        text: funcName,
60332        mode: "math",
60333        family: "rel"
60334      };
60335      var sizedArrow = parser2.callFunction("\\Big", [bareArrow], []);
60336      var rightLabel = parser2.callFunction("\\\\cdright", [labels[1]], []);
60337      var arrowGroup = {
60338        type: "ordgroup",
60339        mode: "math",
60340        body: [leftLabel, sizedArrow, rightLabel]
60341      };
60342      return parser2.callFunction("\\\\cdparent", [arrowGroup], []);
60343    }
60344    case "\\\\cdlongequal":
60345      return parser2.callFunction("\\\\cdlongequal", [], []);
60346    case "\\Vert": {
60347      var arrow = {
60348        type: "textord",
60349        text: "\\Vert",
60350        mode: "math"
60351      };
60352      return parser2.callFunction("\\Big", [arrow], []);
60353    }
60354    default:
60355      return {
60356        type: "textord",
60357        text: " ",
60358        mode: "math"
60359      };
60360  }
60361}
60362function parseCD(parser2) {
60363  var parsedRows = [];
60364  parser2.gullet.beginGroup();
60365  parser2.gullet.macros.set("\\cr", "\\\\\\relax");
60366  parser2.gullet.beginGroup();
60367  while (true) {
60368    parsedRows.push(parser2.parseExpression(false, "\\\\"));
60369    parser2.gullet.endGroup();
60370    parser2.gullet.beginGroup();
60371    var next = parser2.fetch().text;
60372    if (next === "&" || next === "\\\\") {
60373      parser2.consume();
60374    } else if (next === "\\end") {
60375      if (parsedRows[parsedRows.length - 1].length === 0) {
60376        parsedRows.pop();
60377      }
60378      break;
60379    } else {
60380      throw new ParseError("Expected \\\\ or \\cr or \\end", parser2.nextToken);
60381    }
60382  }
60383  var row = [];
60384  var body = [row];
60385  for (var i = 0; i < parsedRows.length; i++) {
60386    var rowNodes = parsedRows[i];
60387    var cell = newCell();
60388    for (var j = 0; j < rowNodes.length; j++) {
60389      if (!isStartOfArrow(rowNodes[j])) {
60390        cell.body.push(rowNodes[j]);
60391      } else {
60392        row.push(cell);
60393        j += 1;
60394        var arrowChar = assertSymbolNodeType(rowNodes[j]).text;
60395        var labels = new Array(2);
60396        labels[0] = {
60397          type: "ordgroup",
60398          mode: "math",
60399          body: []
60400        };
60401        labels[1] = {
60402          type: "ordgroup",
60403          mode: "math",
60404          body: []
60405        };
60406        if ("=|.".indexOf(arrowChar) > -1) ;
60407        else if ("<>AV".indexOf(arrowChar) > -1) {
60408          for (var labelNum = 0; labelNum < 2; labelNum++) {
60409            var inLabel = true;
60410            for (var k = j + 1; k < rowNodes.length; k++) {
60411              if (isLabelEnd(rowNodes[k], arrowChar)) {
60412                inLabel = false;
60413                j = k;
60414                break;
60415              }
60416              if (isStartOfArrow(rowNodes[k])) {
60417                throw new ParseError("Missing a " + arrowChar + " character to complete a CD arrow.", rowNodes[k]);
60418              }
60419              labels[labelNum].body.push(rowNodes[k]);
60420            }
60421            if (inLabel) {
60422              throw new ParseError("Missing a " + arrowChar + " character to complete a CD arrow.", rowNodes[j]);
60423            }
60424          }
60425        } else {
60426          throw new ParseError('Expected one of "<>AV=|." after @', rowNodes[j]);
60427        }
60428        var arrow = cdArrow(arrowChar, labels, parser2);
60429        var wrappedArrow = {
60430          type: "styling",
60431          body: [arrow],
60432          mode: "math",
60433          style: "display"
60434          // CD is always displaystyle.
60435        };
60436        row.push(wrappedArrow);
60437        cell = newCell();
60438      }
60439    }
60440    if (i % 2 === 0) {
60441      row.push(cell);
60442    } else {
60443      row.shift();
60444    }
60445    row = [];
60446    body.push(row);
60447  }
60448  parser2.gullet.endGroup();
60449  parser2.gullet.endGroup();
60450  var cols = new Array(body[0].length).fill({
60451    type: "align",
60452    align: "c",
60453    pregap: 0.25,
60454    // CD package sets \enskip between columns.
60455    postgap: 0.25
60456    // So pre and post each get half an \enskip, i.e. 0.25em.
60457  });
60458  return {
60459    type: "array",
60460    mode: "math",
60461    body,
60462    arraystretch: 1,
60463    addJot: true,
60464    rowGaps: [null],
60465    cols,
60466    colSeparationType: "CD",
60467    hLinesBeforeRow: new Array(body.length + 1).fill([])
60468  };
60469}
60470defineFunction({
60471  type: "cdlabel",
60472  names: ["\\\\cdleft", "\\\\cdright"],
60473  props: {
60474    numArgs: 1
60475  },
60476  handler(_ref, args) {
60477    var {
60478      parser: parser2,
60479      funcName
60480    } = _ref;
60481    return {
60482      type: "cdlabel",
60483      mode: parser2.mode,
60484      side: funcName.slice(4),
60485      label: args[0]
60486    };
60487  },
60488  htmlBuilder(group, options2) {
60489    var newOptions = options2.havingStyle(options2.style.sup());
60490    var label = buildCommon.wrapFragment(buildGroup$1(group.label, newOptions, options2), options2);
60491    label.classes.push("cd-label-" + group.side);
60492    label.style.bottom = makeEm(0.8 - label.depth);
60493    label.height = 0;
60494    label.depth = 0;
60495    return label;
60496  },
60497  mathmlBuilder(group, options2) {
60498    var label = new mathMLTree.MathNode("mrow", [buildGroup2(group.label, options2)]);
60499    label = new mathMLTree.MathNode("mpadded", [label]);
60500    label.setAttribute("width", "0");
60501    if (group.side === "left") {
60502      label.setAttribute("lspace", "-1width");
60503    }
60504    label.setAttribute("voffset", "0.7em");
60505    label = new mathMLTree.MathNode("mstyle", [label]);
60506    label.setAttribute("displaystyle", "false");
60507    label.setAttribute("scriptlevel", "1");
60508    return label;
60509  }
60510});
60511defineFunction({
60512  type: "cdlabelparent",
60513  names: ["\\\\cdparent"],
60514  props: {
60515    numArgs: 1
60516  },
60517  handler(_ref2, args) {
60518    var {
60519      parser: parser2
60520    } = _ref2;
60521    return {
60522      type: "cdlabelparent",
60523      mode: parser2.mode,
60524      fragment: args[0]
60525    };
60526  },
60527  htmlBuilder(group, options2) {
60528    var parent = buildCommon.wrapFragment(buildGroup$1(group.fragment, options2), options2);
60529    parent.classes.push("cd-vert-arrow");
60530    return parent;
60531  },
60532  mathmlBuilder(group, options2) {
60533    return new mathMLTree.MathNode("mrow", [buildGroup2(group.fragment, options2)]);
60534  }
60535});
60536defineFunction({
60537  type: "textord",
60538  names: ["\\@char"],
60539  props: {
60540    numArgs: 1,
60541    allowedInText: true
60542  },
60543  handler(_ref, args) {
60544    var {
60545      parser: parser2
60546    } = _ref;
60547    var arg = assertNodeType(args[0], "ordgroup");
60548    var group = arg.body;
60549    var number = "";
60550    for (var i = 0; i < group.length; i++) {
60551      var node = assertNodeType(group[i], "textord");
60552      number += node.text;
60553    }
60554    var code = parseInt(number);
60555    var text2;
60556    if (isNaN(code)) {
60557      throw new ParseError("\\@char has non-numeric argument " + number);
60558    } else if (code < 0 || code >= 1114111) {
60559      throw new ParseError("\\@char with invalid code point " + number);
60560    } else if (code <= 65535) {
60561      text2 = String.fromCharCode(code);
60562    } else {
60563      code -= 65536;
60564      text2 = String.fromCharCode((code >> 10) + 55296, (code & 1023) + 56320);
60565    }
60566    return {
60567      type: "textord",
60568      mode: parser2.mode,
60569      text: text2
60570    };
60571  }
60572});
60573var htmlBuilder$8 = (group, options2) => {
60574  var elements = buildExpression$1(group.body, options2.withColor(group.color), false);
60575  return buildCommon.makeFragment(elements);
60576};
60577var mathmlBuilder$7 = (group, options2) => {
60578  var inner2 = buildExpression2(group.body, options2.withColor(group.color));
60579  var node = new mathMLTree.MathNode("mstyle", inner2);
60580  node.setAttribute("mathcolor", group.color);
60581  return node;
60582};
60583defineFunction({
60584  type: "color",
60585  names: ["\\textcolor"],
60586  props: {
60587    numArgs: 2,
60588    allowedInText: true,
60589    argTypes: ["color", "original"]
60590  },
60591  handler(_ref, args) {
60592    var {
60593      parser: parser2
60594    } = _ref;
60595    var color = assertNodeType(args[0], "color-token").color;
60596    var body = args[1];
60597    return {
60598      type: "color",
60599      mode: parser2.mode,
60600      color,
60601      body: ordargument(body)
60602    };
60603  },
60604  htmlBuilder: htmlBuilder$8,
60605  mathmlBuilder: mathmlBuilder$7
60606});
60607defineFunction({
60608  type: "color",
60609  names: ["\\color"],
60610  props: {
60611    numArgs: 1,
60612    allowedInText: true,
60613    argTypes: ["color"]
60614  },
60615  handler(_ref2, args) {
60616    var {
60617      parser: parser2,
60618      breakOnTokenText
60619    } = _ref2;
60620    var color = assertNodeType(args[0], "color-token").color;
60621    parser2.gullet.macros.set("\\current@color", color);
60622    var body = parser2.parseExpression(true, breakOnTokenText);
60623    return {
60624      type: "color",
60625      mode: parser2.mode,
60626      color,
60627      body
60628    };
60629  },
60630  htmlBuilder: htmlBuilder$8,
60631  mathmlBuilder: mathmlBuilder$7
60632});
60633defineFunction({
60634  type: "cr",
60635  names: ["\\\\"],
60636  props: {
60637    numArgs: 0,
60638    numOptionalArgs: 0,
60639    allowedInText: true
60640  },
60641  handler(_ref, args, optArgs) {
60642    var {
60643      parser: parser2
60644    } = _ref;
60645    var size = parser2.gullet.future().text === "[" ? parser2.parseSizeGroup(true) : null;
60646    var newLine = !parser2.settings.displayMode || !parser2.settings.useStrictBehavior("newLineInDisplayMode", "In LaTeX, \\\\ or \\newline does nothing in display mode");
60647    return {
60648      type: "cr",
60649      mode: parser2.mode,
60650      newLine,
60651      size: size && assertNodeType(size, "size").value
60652    };
60653  },
60654  // The following builders are called only at the top level,
60655  // not within tabular/array environments.
60656  htmlBuilder(group, options2) {
60657    var span = buildCommon.makeSpan(["mspace"], [], options2);
60658    if (group.newLine) {
60659      span.classes.push("newline");
60660      if (group.size) {
60661        span.style.marginTop = makeEm(calculateSize(group.size, options2));
60662      }
60663    }
60664    return span;
60665  },
60666  mathmlBuilder(group, options2) {
60667    var node = new mathMLTree.MathNode("mspace");
60668    if (group.newLine) {
60669      node.setAttribute("linebreak", "newline");
60670      if (group.size) {
60671        node.setAttribute("height", makeEm(calculateSize(group.size, options2)));
60672      }
60673    }
60674    return node;
60675  }
60676});
60677var globalMap = {
60678  "\\global": "\\global",
60679  "\\long": "\\\\globallong",
60680  "\\\\globallong": "\\\\globallong",
60681  "\\def": "\\gdef",
60682  "\\gdef": "\\gdef",
60683  "\\edef": "\\xdef",
60684  "\\xdef": "\\xdef",
60685  "\\let": "\\\\globallet",
60686  "\\futurelet": "\\\\globalfuture"
60687};
60688var checkControlSequence = (tok) => {
60689  var name = tok.text;
60690  if (/^(?:[\\{}$&#^_]|EOF)$/.test(name)) {
60691    throw new ParseError("Expected a control sequence", tok);
60692  }
60693  return name;
60694};
60695var getRHS = (parser2) => {
60696  var tok = parser2.gullet.popToken();
60697  if (tok.text === "=") {
60698    tok = parser2.gullet.popToken();
60699    if (tok.text === " ") {
60700      tok = parser2.gullet.popToken();
60701    }
60702  }
60703  return tok;
60704};
60705var letCommand = (parser2, name, tok, global2) => {
60706  var macro = parser2.gullet.macros.get(tok.text);
60707  if (macro == null) {
60708    tok.noexpand = true;
60709    macro = {
60710      tokens: [tok],
60711      numArgs: 0,
60712      // reproduce the same behavior in expansion
60713      unexpandable: !parser2.gullet.isExpandable(tok.text)
60714    };
60715  }
60716  parser2.gullet.macros.set(name, macro, global2);
60717};
60718defineFunction({
60719  type: "internal",
60720  names: [
60721    "\\global",
60722    "\\long",
60723    "\\\\globallong"
60724    // can’t be entered directly
60725  ],
60726  props: {
60727    numArgs: 0,
60728    allowedInText: true
60729  },
60730  handler(_ref) {
60731    var {
60732      parser: parser2,
60733      funcName
60734    } = _ref;
60735    parser2.consumeSpaces();
60736    var token = parser2.fetch();
60737    if (globalMap[token.text]) {
60738      if (funcName === "\\global" || funcName === "\\\\globallong") {
60739        token.text = globalMap[token.text];
60740      }
60741      return assertNodeType(parser2.parseFunction(), "internal");
60742    }
60743    throw new ParseError("Invalid token after macro prefix", token);
60744  }
60745});
60746defineFunction({
60747  type: "internal",
60748  names: ["\\def", "\\gdef", "\\edef", "\\xdef"],
60749  props: {
60750    numArgs: 0,
60751    allowedInText: true,
60752    primitive: true
60753  },
60754  handler(_ref2) {
60755    var {
60756      parser: parser2,
60757      funcName
60758    } = _ref2;
60759    var tok = parser2.gullet.popToken();
60760    var name = tok.text;
60761    if (/^(?:[\\{}$&#^_]|EOF)$/.test(name)) {
60762      throw new ParseError("Expected a control sequence", tok);
60763    }
60764    var numArgs = 0;
60765    var insert;
60766    var delimiters2 = [[]];
60767    while (parser2.gullet.future().text !== "{") {
60768      tok = parser2.gullet.popToken();
60769      if (tok.text === "#") {
60770        if (parser2.gullet.future().text === "{") {
60771          insert = parser2.gullet.future();
60772          delimiters2[numArgs].push("{");
60773          break;
60774        }
60775        tok = parser2.gullet.popToken();
60776        if (!/^[1-9]$/.test(tok.text)) {
60777          throw new ParseError('Invalid argument number "' + tok.text + '"');
60778        }
60779        if (parseInt(tok.text) !== numArgs + 1) {
60780          throw new ParseError('Argument number "' + tok.text + '" out of order');
60781        }
60782        numArgs++;
60783        delimiters2.push([]);
60784      } else if (tok.text === "EOF") {
60785        throw new ParseError("Expected a macro definition");
60786      } else {
60787        delimiters2[numArgs].push(tok.text);
60788      }
60789    }
60790    var {
60791      tokens
60792    } = parser2.gullet.consumeArg();
60793    if (insert) {
60794      tokens.unshift(insert);
60795    }
60796    if (funcName === "\\edef" || funcName === "\\xdef") {
60797      tokens = parser2.gullet.expandTokens(tokens);
60798      tokens.reverse();
60799    }
60800    parser2.gullet.macros.set(name, {
60801      tokens,
60802      numArgs,
60803      delimiters: delimiters2
60804    }, funcName === globalMap[funcName]);
60805    return {
60806      type: "internal",
60807      mode: parser2.mode
60808    };
60809  }
60810});
60811defineFunction({
60812  type: "internal",
60813  names: [
60814    "\\let",
60815    "\\\\globallet"
60816    // can’t be entered directly
60817  ],
60818  props: {
60819    numArgs: 0,
60820    allowedInText: true,
60821    primitive: true
60822  },
60823  handler(_ref3) {
60824    var {
60825      parser: parser2,
60826      funcName
60827    } = _ref3;
60828    var name = checkControlSequence(parser2.gullet.popToken());
60829    parser2.gullet.consumeSpaces();
60830    var tok = getRHS(parser2);
60831    letCommand(parser2, name, tok, funcName === "\\\\globallet");
60832    return {
60833      type: "internal",
60834      mode: parser2.mode
60835    };
60836  }
60837});
60838defineFunction({
60839  type: "internal",
60840  names: [
60841    "\\futurelet",
60842    "\\\\globalfuture"
60843    // can’t be entered directly
60844  ],
60845  props: {
60846    numArgs: 0,
60847    allowedInText: true,
60848    primitive: true
60849  },
60850  handler(_ref4) {
60851    var {
60852      parser: parser2,
60853      funcName
60854    } = _ref4;
60855    var name = checkControlSequence(parser2.gullet.popToken());
60856    var middle = parser2.gullet.popToken();
60857    var tok = parser2.gullet.popToken();
60858    letCommand(parser2, name, tok, funcName === "\\\\globalfuture");
60859    parser2.gullet.pushToken(tok);
60860    parser2.gullet.pushToken(middle);
60861    return {
60862      type: "internal",
60863      mode: parser2.mode
60864    };
60865  }
60866});
60867var getMetrics = function getMetrics2(symbol, font, mode) {
60868  var replace = symbols.math[symbol] && symbols.math[symbol].replace;
60869  var metrics = getCharacterMetrics(replace || symbol, font, mode);
60870  if (!metrics) {
60871    throw new Error("Unsupported symbol " + symbol + " and font size " + font + ".");
60872  }
60873  return metrics;
60874};
60875var styleWrap = function styleWrap2(delim, toStyle, options2, classes2) {
60876  var newOptions = options2.havingBaseStyle(toStyle);
60877  var span = buildCommon.makeSpan(classes2.concat(newOptions.sizingClasses(options2)), [delim], options2);
60878  var delimSizeMultiplier = newOptions.sizeMultiplier / options2.sizeMultiplier;
60879  span.height *= delimSizeMultiplier;
60880  span.depth *= delimSizeMultiplier;
60881  span.maxFontSize = newOptions.sizeMultiplier;
60882  return span;
60883};
60884var centerSpan = function centerSpan2(span, options2, style) {
60885  var newOptions = options2.havingBaseStyle(style);
60886  var shift = (1 - options2.sizeMultiplier / newOptions.sizeMultiplier) * options2.fontMetrics().axisHeight;
60887  span.classes.push("delimcenter");
60888  span.style.top = makeEm(shift);
60889  span.height -= shift;
60890  span.depth += shift;
60891};
60892var makeSmallDelim = function makeSmallDelim2(delim, style, center, options2, mode, classes2) {
60893  var text2 = buildCommon.makeSymbol(delim, "Main-Regular", mode, options2);
60894  var span = styleWrap(text2, style, options2, classes2);
60895  if (center) {
60896    centerSpan(span, options2, style);
60897  }
60898  return span;
60899};
60900var mathrmSize = function mathrmSize2(value, size, mode, options2) {
60901  return buildCommon.makeSymbol(value, "Size" + size + "-Regular", mode, options2);
60902};
60903var makeLargeDelim = function makeLargeDelim2(delim, size, center, options2, mode, classes2) {
60904  var inner2 = mathrmSize(delim, size, mode, options2);
60905  var span = styleWrap(buildCommon.makeSpan(["delimsizing", "size" + size], [inner2], options2), Style$1.TEXT, options2, classes2);
60906  if (center) {
60907    centerSpan(span, options2, Style$1.TEXT);
60908  }
60909  return span;
60910};
60911var makeGlyphSpan = function makeGlyphSpan2(symbol, font, mode) {
60912  var sizeClass;
60913  if (font === "Size1-Regular") {
60914    sizeClass = "delim-size1";
60915  } else {
60916    sizeClass = "delim-size4";
60917  }
60918  var corner = buildCommon.makeSpan(["delimsizinginner", sizeClass], [buildCommon.makeSpan([], [buildCommon.makeSymbol(symbol, font, mode)])]);
60919  return {
60920    type: "elem",
60921    elem: corner
60922  };
60923};
60924var makeInner = function makeInner2(ch, height, options2) {
60925  var width = fontMetricsData["Size4-Regular"][ch.charCodeAt(0)] ? fontMetricsData["Size4-Regular"][ch.charCodeAt(0)][4] : fontMetricsData["Size1-Regular"][ch.charCodeAt(0)][4];
60926  var path2 = new PathNode("inner", innerPath(ch, Math.round(1e3 * height)));
60927  var svgNode = new SvgNode([path2], {
60928    "width": makeEm(width),
60929    "height": makeEm(height),
60930    // Override CSS rule `.katex svg { width: 100% }`
60931    "style": "width:" + makeEm(width),
60932    "viewBox": "0 0 " + 1e3 * width + " " + Math.round(1e3 * height),
60933    "preserveAspectRatio": "xMinYMin"
60934  });
60935  var span = buildCommon.makeSvgSpan([], [svgNode], options2);
60936  span.height = height;
60937  span.style.height = makeEm(height);
60938  span.style.width = makeEm(width);
60939  return {
60940    type: "elem",
60941    elem: span
60942  };
60943};
60944var lapInEms = 8e-3;
60945var lap = {
60946  type: "kern",
60947  size: -1 * lapInEms
60948};
60949var verts = ["|", "\\lvert", "\\rvert", "\\vert"];
60950var doubleVerts = ["\\|", "\\lVert", "\\rVert", "\\Vert"];
60951var makeStackedDelim = function makeStackedDelim2(delim, heightTotal, center, options2, mode, classes2) {
60952  var top;
60953  var middle;
60954  var repeat;
60955  var bottom;
60956  var svgLabel = "";
60957  var viewBoxWidth = 0;
60958  top = repeat = bottom = delim;
60959  middle = null;
60960  var font = "Size1-Regular";
60961  if (delim === "\\uparrow") {
60962    repeat = bottom = "\u23D0";
60963  } else if (delim === "\\Uparrow") {
60964    repeat = bottom = "\u2016";
60965  } else if (delim === "\\downarrow") {
60966    top = repeat = "\u23D0";
60967  } else if (delim === "\\Downarrow") {
60968    top = repeat = "\u2016";
60969  } else if (delim === "\\updownarrow") {
60970    top = "\\uparrow";
60971    repeat = "\u23D0";
60972    bottom = "\\downarrow";
60973  } else if (delim === "\\Updownarrow") {
60974    top = "\\Uparrow";
60975    repeat = "\u2016";
60976    bottom = "\\Downarrow";
60977  } else if (utils.contains(verts, delim)) {
60978    repeat = "\u2223";
60979    svgLabel = "vert";
60980    viewBoxWidth = 333;
60981  } else if (utils.contains(doubleVerts, delim)) {
60982    repeat = "\u2225";
60983    svgLabel = "doublevert";
60984    viewBoxWidth = 556;
60985  } else if (delim === "[" || delim === "\\lbrack") {
60986    top = "\u23A1";
60987    repeat = "\u23A2";
60988    bottom = "\u23A3";
60989    font = "Size4-Regular";
60990    svgLabel = "lbrack";
60991    viewBoxWidth = 667;
60992  } else if (delim === "]" || delim === "\\rbrack") {
60993    top = "\u23A4";
60994    repeat = "\u23A5";
60995    bottom = "\u23A6";
60996    font = "Size4-Regular";
60997    svgLabel = "rbrack";
60998    viewBoxWidth = 667;
60999  } else if (delim === "\\lfloor" || delim === "\u230A") {
61000    repeat = top = "\u23A2";
61001    bottom = "\u23A3";
61002    font = "Size4-Regular";
61003    svgLabel = "lfloor";
61004    viewBoxWidth = 667;
61005  } else if (delim === "\\lceil" || delim === "\u2308") {
61006    top = "\u23A1";
61007    repeat = bottom = "\u23A2";
61008    font = "Size4-Regular";
61009    svgLabel = "lceil";
61010    viewBoxWidth = 667;
61011  } else if (delim === "\\rfloor" || delim === "\u230B") {
61012    repeat = top = "\u23A5";
61013    bottom = "\u23A6";
61014    font = "Size4-Regular";
61015    svgLabel = "rfloor";
61016    viewBoxWidth = 667;
61017  } else if (delim === "\\rceil" || delim === "\u2309") {
61018    top = "\u23A4";
61019    repeat = bottom = "\u23A5";
61020    font = "Size4-Regular";
61021    svgLabel = "rceil";
61022    viewBoxWidth = 667;
61023  } else if (delim === "(" || delim === "\\lparen") {
61024    top = "\u239B";
61025    repeat = "\u239C";
61026    bottom = "\u239D";
61027    font = "Size4-Regular";
61028    svgLabel = "lparen";
61029    viewBoxWidth = 875;
61030  } else if (delim === ")" || delim === "\\rparen") {
61031    top = "\u239E";
61032    repeat = "\u239F";
61033    bottom = "\u23A0";
61034    font = "Size4-Regular";
61035    svgLabel = "rparen";
61036    viewBoxWidth = 875;
61037  } else if (delim === "\\{" || delim === "\\lbrace") {
61038    top = "\u23A7";
61039    middle = "\u23A8";
61040    bottom = "\u23A9";
61041    repeat = "\u23AA";
61042    font = "Size4-Regular";
61043  } else if (delim === "\\}" || delim === "\\rbrace") {
61044    top = "\u23AB";
61045    middle = "\u23AC";
61046    bottom = "\u23AD";
61047    repeat = "\u23AA";
61048    font = "Size4-Regular";
61049  } else if (delim === "\\lgroup" || delim === "\u27EE") {
61050    top = "\u23A7";
61051    bottom = "\u23A9";
61052    repeat = "\u23AA";
61053    font = "Size4-Regular";
61054  } else if (delim === "\\rgroup" || delim === "\u27EF") {
61055    top = "\u23AB";
61056    bottom = "\u23AD";
61057    repeat = "\u23AA";
61058    font = "Size4-Regular";
61059  } else if (delim === "\\lmoustache" || delim === "\u23B0") {
61060    top = "\u23A7";
61061    bottom = "\u23AD";
61062    repeat = "\u23AA";
61063    font = "Size4-Regular";
61064  } else if (delim === "\\rmoustache" || delim === "\u23B1") {
61065    top = "\u23AB";
61066    bottom = "\u23A9";
61067    repeat = "\u23AA";
61068    font = "Size4-Regular";
61069  }
61070  var topMetrics = getMetrics(top, font, mode);
61071  var topHeightTotal = topMetrics.height + topMetrics.depth;
61072  var repeatMetrics = getMetrics(repeat, font, mode);
61073  var repeatHeightTotal = repeatMetrics.height + repeatMetrics.depth;
61074  var bottomMetrics = getMetrics(bottom, font, mode);
61075  var bottomHeightTotal = bottomMetrics.height + bottomMetrics.depth;
61076  var middleHeightTotal = 0;
61077  var middleFactor = 1;
61078  if (middle !== null) {
61079    var middleMetrics = getMetrics(middle, font, mode);
61080    middleHeightTotal = middleMetrics.height + middleMetrics.depth;
61081    middleFactor = 2;
61082  }
61083  var minHeight = topHeightTotal + bottomHeightTotal + middleHeightTotal;
61084  var repeatCount = Math.max(0, Math.ceil((heightTotal - minHeight) / (middleFactor * repeatHeightTotal)));
61085  var realHeightTotal = minHeight + repeatCount * middleFactor * repeatHeightTotal;
61086  var axisHeight = options2.fontMetrics().axisHeight;
61087  if (center) {
61088    axisHeight *= options2.sizeMultiplier;
61089  }
61090  var depth = realHeightTotal / 2 - axisHeight;
61091  var stack = [];
61092  if (svgLabel.length > 0) {
61093    var midHeight = realHeightTotal - topHeightTotal - bottomHeightTotal;
61094    var viewBoxHeight = Math.round(realHeightTotal * 1e3);
61095    var pathStr = tallDelim(svgLabel, Math.round(midHeight * 1e3));
61096    var path2 = new PathNode(svgLabel, pathStr);
61097    var width = (viewBoxWidth / 1e3).toFixed(3) + "em";
61098    var height = (viewBoxHeight / 1e3).toFixed(3) + "em";
61099    var svg = new SvgNode([path2], {
61100      "width": width,
61101      "height": height,
61102      "viewBox": "0 0 " + viewBoxWidth + " " + viewBoxHeight
61103    });
61104    var wrapper = buildCommon.makeSvgSpan([], [svg], options2);
61105    wrapper.height = viewBoxHeight / 1e3;
61106    wrapper.style.width = width;
61107    wrapper.style.height = height;
61108    stack.push({
61109      type: "elem",
61110      elem: wrapper
61111    });
61112  } else {
61113    stack.push(makeGlyphSpan(bottom, font, mode));
61114    stack.push(lap);
61115    if (middle === null) {
61116      var innerHeight = realHeightTotal - topHeightTotal - bottomHeightTotal + 2 * lapInEms;
61117      stack.push(makeInner(repeat, innerHeight, options2));
61118    } else {
61119      var _innerHeight = (realHeightTotal - topHeightTotal - bottomHeightTotal - middleHeightTotal) / 2 + 2 * lapInEms;
61120      stack.push(makeInner(repeat, _innerHeight, options2));
61121      stack.push(lap);
61122      stack.push(makeGlyphSpan(middle, font, mode));
61123      stack.push(lap);
61124      stack.push(makeInner(repeat, _innerHeight, options2));
61125    }
61126    stack.push(lap);
61127    stack.push(makeGlyphSpan(top, font, mode));
61128  }
61129  var newOptions = options2.havingBaseStyle(Style$1.TEXT);
61130  var inner2 = buildCommon.makeVList({
61131    positionType: "bottom",
61132    positionData: depth,
61133    children: stack
61134  }, newOptions);
61135  return styleWrap(buildCommon.makeSpan(["delimsizing", "mult"], [inner2], newOptions), Style$1.TEXT, options2, classes2);
61136};
61137var vbPad = 80;
61138var emPad = 0.08;
61139var sqrtSvg = function sqrtSvg2(sqrtName, height, viewBoxHeight, extraVinculum, options2) {
61140  var path2 = sqrtPath(sqrtName, extraVinculum, viewBoxHeight);
61141  var pathNode = new PathNode(sqrtName, path2);
61142  var svg = new SvgNode([pathNode], {
61143    // Note: 1000:1 ratio of viewBox to document em width.
61144    "width": "400em",
61145    "height": makeEm(height),
61146    "viewBox": "0 0 400000 " + viewBoxHeight,
61147    "preserveAspectRatio": "xMinYMin slice"
61148  });
61149  return buildCommon.makeSvgSpan(["hide-tail"], [svg], options2);
61150};
61151var makeSqrtImage = function makeSqrtImage2(height, options2) {
61152  var newOptions = options2.havingBaseSizing();
61153  var delim = traverseSequence("\\surd", height * newOptions.sizeMultiplier, stackLargeDelimiterSequence, newOptions);
61154  var sizeMultiplier = newOptions.sizeMultiplier;
61155  var extraVinculum = Math.max(0, options2.minRuleThickness - options2.fontMetrics().sqrtRuleThickness);
61156  var span;
61157  var spanHeight = 0;
61158  var texHeight = 0;
61159  var viewBoxHeight = 0;
61160  var advanceWidth;
61161  if (delim.type === "small") {
61162    viewBoxHeight = 1e3 + 1e3 * extraVinculum + vbPad;
61163    if (height < 1) {
61164      sizeMultiplier = 1;
61165    } else if (height < 1.4) {
61166      sizeMultiplier = 0.7;
61167    }
61168    spanHeight = (1 + extraVinculum + emPad) / sizeMultiplier;
61169    texHeight = (1 + extraVinculum) / sizeMultiplier;
61170    span = sqrtSvg("sqrtMain", spanHeight, viewBoxHeight, extraVinculum, options2);
61171    span.style.minWidth = "0.853em";
61172    advanceWidth = 0.833 / sizeMultiplier;
61173  } else if (delim.type === "large") {
61174    viewBoxHeight = (1e3 + vbPad) * sizeToMaxHeight[delim.size];
61175    texHeight = (sizeToMaxHeight[delim.size] + extraVinculum) / sizeMultiplier;
61176    spanHeight = (sizeToMaxHeight[delim.size] + extraVinculum + emPad) / sizeMultiplier;
61177    span = sqrtSvg("sqrtSize" + delim.size, spanHeight, viewBoxHeight, extraVinculum, options2);
61178    span.style.minWidth = "1.02em";
61179    advanceWidth = 1 / sizeMultiplier;
61180  } else {
61181    spanHeight = height + extraVinculum + emPad;
61182    texHeight = height + extraVinculum;
61183    viewBoxHeight = Math.floor(1e3 * height + extraVinculum) + vbPad;
61184    span = sqrtSvg("sqrtTall", spanHeight, viewBoxHeight, extraVinculum, options2);
61185    span.style.minWidth = "0.742em";
61186    advanceWidth = 1.056;
61187  }
61188  span.height = texHeight;
61189  span.style.height = makeEm(spanHeight);
61190  return {
61191    span,
61192    advanceWidth,
61193    // Calculate the actual line width.
61194    // This actually should depend on the chosen font -- e.g. \boldmath
61195    // should use the thicker surd symbols from e.g. KaTeX_Main-Bold, and
61196    // have thicker rules.
61197    ruleWidth: (options2.fontMetrics().sqrtRuleThickness + extraVinculum) * sizeMultiplier
61198  };
61199};
61200var stackLargeDelimiters = ["(", "\\lparen", ")", "\\rparen", "[", "\\lbrack", "]", "\\rbrack", "\\{", "\\lbrace", "\\}", "\\rbrace", "\\lfloor", "\\rfloor", "\u230A", "\u230B", "\\lceil", "\\rceil", "\u2308", "\u2309", "\\surd"];
61201var stackAlwaysDelimiters = ["\\uparrow", "\\downarrow", "\\updownarrow", "\\Uparrow", "\\Downarrow", "\\Updownarrow", "|", "\\|", "\\vert", "\\Vert", "\\lvert", "\\rvert", "\\lVert", "\\rVert", "\\lgroup", "\\rgroup", "\u27EE", "\u27EF", "\\lmoustache", "\\rmoustache", "\u23B0", "\u23B1"];
61202var stackNeverDelimiters = ["<", ">", "\\langle", "\\rangle", "/", "\\backslash", "\\lt", "\\gt"];
61203var sizeToMaxHeight = [0, 1.2, 1.8, 2.4, 3];
61204var makeSizedDelim = function makeSizedDelim2(delim, size, options2, mode, classes2) {
61205  if (delim === "<" || delim === "\\lt" || delim === "\u27E8") {
61206    delim = "\\langle";
61207  } else if (delim === ">" || delim === "\\gt" || delim === "\u27E9") {
61208    delim = "\\rangle";
61209  }
61210  if (utils.contains(stackLargeDelimiters, delim) || utils.contains(stackNeverDelimiters, delim)) {
61211    return makeLargeDelim(delim, size, false, options2, mode, classes2);
61212  } else if (utils.contains(stackAlwaysDelimiters, delim)) {
61213    return makeStackedDelim(delim, sizeToMaxHeight[size], false, options2, mode, classes2);
61214  } else {
61215    throw new ParseError("Illegal delimiter: '" + delim + "'");
61216  }
61217};
61218var stackNeverDelimiterSequence = [{
61219  type: "small",
61220  style: Style$1.SCRIPTSCRIPT
61221}, {
61222  type: "small",
61223  style: Style$1.SCRIPT
61224}, {
61225  type: "small",
61226  style: Style$1.TEXT
61227}, {
61228  type: "large",
61229  size: 1
61230}, {
61231  type: "large",
61232  size: 2
61233}, {
61234  type: "large",
61235  size: 3
61236}, {
61237  type: "large",
61238  size: 4
61239}];
61240var stackAlwaysDelimiterSequence = [{
61241  type: "small",
61242  style: Style$1.SCRIPTSCRIPT
61243}, {
61244  type: "small",
61245  style: Style$1.SCRIPT
61246}, {
61247  type: "small",
61248  style: Style$1.TEXT
61249}, {
61250  type: "stack"
61251}];
61252var stackLargeDelimiterSequence = [{
61253  type: "small",
61254  style: Style$1.SCRIPTSCRIPT
61255}, {
61256  type: "small",
61257  style: Style$1.SCRIPT
61258}, {
61259  type: "small",
61260  style: Style$1.TEXT
61261}, {
61262  type: "large",
61263  size: 1
61264}, {
61265  type: "large",
61266  size: 2
61267}, {
61268  type: "large",
61269  size: 3
61270}, {
61271  type: "large",
61272  size: 4
61273}, {
61274  type: "stack"
61275}];
61276var delimTypeToFont = function delimTypeToFont2(type) {
61277  if (type.type === "small") {
61278    return "Main-Regular";
61279  } else if (type.type === "large") {
61280    return "Size" + type.size + "-Regular";
61281  } else if (type.type === "stack") {
61282    return "Size4-Regular";
61283  } else {
61284    throw new Error("Add support for delim type '" + type.type + "' here.");
61285  }
61286};
61287var traverseSequence = function traverseSequence2(delim, height, sequence, options2) {
61288  var start = Math.min(2, 3 - options2.style.size);
61289  for (var i = start; i < sequence.length; i++) {
61290    if (sequence[i].type === "stack") {
61291      break;
61292    }
61293    var metrics = getMetrics(delim, delimTypeToFont(sequence[i]), "math");
61294    var heightDepth = metrics.height + metrics.depth;
61295    if (sequence[i].type === "small") {
61296      var newOptions = options2.havingBaseStyle(sequence[i].style);
61297      heightDepth *= newOptions.sizeMultiplier;
61298    }
61299    if (heightDepth > height) {
61300      return sequence[i];
61301    }
61302  }
61303  return sequence[sequence.length - 1];
61304};
61305var makeCustomSizedDelim = function makeCustomSizedDelim2(delim, height, center, options2, mode, classes2) {
61306  if (delim === "<" || delim === "\\lt" || delim === "\u27E8") {
61307    delim = "\\langle";
61308  } else if (delim === ">" || delim === "\\gt" || delim === "\u27E9") {
61309    delim = "\\rangle";
61310  }
61311  var sequence;
61312  if (utils.contains(stackNeverDelimiters, delim)) {
61313    sequence = stackNeverDelimiterSequence;
61314  } else if (utils.contains(stackLargeDelimiters, delim)) {
61315    sequence = stackLargeDelimiterSequence;
61316  } else {
61317    sequence = stackAlwaysDelimiterSequence;
61318  }
61319  var delimType = traverseSequence(delim, height, sequence, options2);
61320  if (delimType.type === "small") {
61321    return makeSmallDelim(delim, delimType.style, center, options2, mode, classes2);
61322  } else if (delimType.type === "large") {
61323    return makeLargeDelim(delim, delimType.size, center, options2, mode, classes2);
61324  } else {
61325    return makeStackedDelim(delim, height, center, options2, mode, classes2);
61326  }
61327};
61328var makeLeftRightDelim = function makeLeftRightDelim2(delim, height, depth, options2, mode, classes2) {
61329  var axisHeight = options2.fontMetrics().axisHeight * options2.sizeMultiplier;
61330  var delimiterFactor = 901;
61331  var delimiterExtend = 5 / options2.fontMetrics().ptPerEm;
61332  var maxDistFromAxis = Math.max(height - axisHeight, depth + axisHeight);
61333  var totalHeight = Math.max(
61334    // In real TeX, calculations are done using integral values which are
61335    // 65536 per pt, or 655360 per em. So, the division here truncates in
61336    // TeX but doesn't here, producing different results. If we wanted to
61337    // exactly match TeX's calculation, we could do
61338    //   Math.floor(655360 * maxDistFromAxis / 500) *
61339    //    delimiterFactor / 655360
61340    // (To see the difference, compare
61341    //    x^{x^{\left(\rule{0.1em}{0.68em}\right)}}
61342    // in TeX and KaTeX)
61343    maxDistFromAxis / 500 * delimiterFactor,
61344    2 * maxDistFromAxis - delimiterExtend
61345  );
61346  return makeCustomSizedDelim(delim, totalHeight, true, options2, mode, classes2);
61347};
61348var delimiter = {
61349  sqrtImage: makeSqrtImage,
61350  sizedDelim: makeSizedDelim,
61351  sizeToMaxHeight,
61352  customSizedDelim: makeCustomSizedDelim,
61353  leftRightDelim: makeLeftRightDelim
61354};
61355var delimiterSizes = {
61356  "\\bigl": {
61357    mclass: "mopen",
61358    size: 1
61359  },
61360  "\\Bigl": {
61361    mclass: "mopen",
61362    size: 2
61363  },
61364  "\\biggl": {
61365    mclass: "mopen",
61366    size: 3
61367  },
61368  "\\Biggl": {
61369    mclass: "mopen",
61370    size: 4
61371  },
61372  "\\bigr": {
61373    mclass: "mclose",
61374    size: 1
61375  },
61376  "\\Bigr": {
61377    mclass: "mclose",
61378    size: 2
61379  },
61380  "\\biggr": {
61381    mclass: "mclose",
61382    size: 3
61383  },
61384  "\\Biggr": {
61385    mclass: "mclose",
61386    size: 4
61387  },
61388  "\\bigm": {
61389    mclass: "mrel",
61390    size: 1
61391  },
61392  "\\Bigm": {
61393    mclass: "mrel",
61394    size: 2
61395  },
61396  "\\biggm": {
61397    mclass: "mrel",
61398    size: 3
61399  },
61400  "\\Biggm": {
61401    mclass: "mrel",
61402    size: 4
61403  },
61404  "\\big": {
61405    mclass: "mord",
61406    size: 1
61407  },
61408  "\\Big": {
61409    mclass: "mord",
61410    size: 2
61411  },
61412  "\\bigg": {
61413    mclass: "mord",
61414    size: 3
61415  },
61416  "\\Bigg": {
61417    mclass: "mord",
61418    size: 4
61419  }
61420};
61421var delimiters = ["(", "\\lparen", ")", "\\rparen", "[", "\\lbrack", "]", "\\rbrack", "\\{", "\\lbrace", "\\}", "\\rbrace", "\\lfloor", "\\rfloor", "\u230A", "\u230B", "\\lceil", "\\rceil", "\u2308", "\u2309", "<", ">", "\\langle", "\u27E8", "\\rangle", "\u27E9", "\\lt", "\\gt", "\\lvert", "\\rvert", "\\lVert", "\\rVert", "\\lgroup", "\\rgroup", "\u27EE", "\u27EF", "\\lmoustache", "\\rmoustache", "\u23B0", "\u23B1", "/", "\\backslash", "|", "\\vert", "\\|", "\\Vert", "\\uparrow", "\\Uparrow", "\\downarrow", "\\Downarrow", "\\updownarrow", "\\Updownarrow", "."];
61422function checkDelimiter(delim, context) {
61423  var symDelim = checkSymbolNodeType(delim);
61424  if (symDelim && utils.contains(delimiters, symDelim.text)) {
61425    return symDelim;
61426  } else if (symDelim) {
61427    throw new ParseError("Invalid delimiter '" + symDelim.text + "' after '" + context.funcName + "'", delim);
61428  } else {
61429    throw new ParseError("Invalid delimiter type '" + delim.type + "'", delim);
61430  }
61431}
61432defineFunction({
61433  type: "delimsizing",
61434  names: ["\\bigl", "\\Bigl", "\\biggl", "\\Biggl", "\\bigr", "\\Bigr", "\\biggr", "\\Biggr", "\\bigm", "\\Bigm", "\\biggm", "\\Biggm", "\\big", "\\Big", "\\bigg", "\\Bigg"],
61435  props: {
61436    numArgs: 1,
61437    argTypes: ["primitive"]
61438  },
61439  handler: (context, args) => {
61440    var delim = checkDelimiter(args[0], context);
61441    return {
61442      type: "delimsizing",
61443      mode: context.parser.mode,
61444      size: delimiterSizes[context.funcName].size,
61445      mclass: delimiterSizes[context.funcName].mclass,
61446      delim: delim.text
61447    };
61448  },
61449  htmlBuilder: (group, options2) => {
61450    if (group.delim === ".") {
61451      return buildCommon.makeSpan([group.mclass]);
61452    }
61453    return delimiter.sizedDelim(group.delim, group.size, options2, group.mode, [group.mclass]);
61454  },
61455  mathmlBuilder: (group) => {
61456    var children = [];
61457    if (group.delim !== ".") {
61458      children.push(makeText(group.delim, group.mode));
61459    }
61460    var node = new mathMLTree.MathNode("mo", children);
61461    if (group.mclass === "mopen" || group.mclass === "mclose") {
61462      node.setAttribute("fence", "true");
61463    } else {
61464      node.setAttribute("fence", "false");
61465    }
61466    node.setAttribute("stretchy", "true");
61467    var size = makeEm(delimiter.sizeToMaxHeight[group.size]);
61468    node.setAttribute("minsize", size);
61469    node.setAttribute("maxsize", size);
61470    return node;
61471  }
61472});
61473function assertParsed(group) {
61474  if (!group.body) {
61475    throw new Error("Bug: The leftright ParseNode wasn't fully parsed.");
61476  }
61477}
61478defineFunction({
61479  type: "leftright-right",
61480  names: ["\\right"],
61481  props: {
61482    numArgs: 1,
61483    primitive: true
61484  },
61485  handler: (context, args) => {
61486    var color = context.parser.gullet.macros.get("\\current@color");
61487    if (color && typeof color !== "string") {
61488      throw new ParseError("\\current@color set to non-string in \\right");
61489    }
61490    return {
61491      type: "leftright-right",
61492      mode: context.parser.mode,
61493      delim: checkDelimiter(args[0], context).text,
61494      color
61495      // undefined if not set via \color
61496    };
61497  }
61498});
61499defineFunction({
61500  type: "leftright",
61501  names: ["\\left"],
61502  props: {
61503    numArgs: 1,
61504    primitive: true
61505  },
61506  handler: (context, args) => {
61507    var delim = checkDelimiter(args[0], context);
61508    var parser2 = context.parser;
61509    ++parser2.leftrightDepth;
61510    var body = parser2.parseExpression(false);
61511    --parser2.leftrightDepth;
61512    parser2.expect("\\right", false);
61513    var right = assertNodeType(parser2.parseFunction(), "leftright-right");
61514    return {
61515      type: "leftright",
61516      mode: parser2.mode,
61517      body,
61518      left: delim.text,
61519      right: right.delim,
61520      rightColor: right.color
61521    };
61522  },
61523  htmlBuilder: (group, options2) => {
61524    assertParsed(group);
61525    var inner2 = buildExpression$1(group.body, options2, true, ["mopen", "mclose"]);
61526    var innerHeight = 0;
61527    var innerDepth = 0;
61528    var hadMiddle = false;
61529    for (var i = 0; i < inner2.length; i++) {
61530      if (inner2[i].isMiddle) {
61531        hadMiddle = true;
61532      } else {
61533        innerHeight = Math.max(inner2[i].height, innerHeight);
61534        innerDepth = Math.max(inner2[i].depth, innerDepth);
61535      }
61536    }
61537    innerHeight *= options2.sizeMultiplier;
61538    innerDepth *= options2.sizeMultiplier;
61539    var leftDelim;
61540    if (group.left === ".") {
61541      leftDelim = makeNullDelimiter(options2, ["mopen"]);
61542    } else {
61543      leftDelim = delimiter.leftRightDelim(group.left, innerHeight, innerDepth, options2, group.mode, ["mopen"]);
61544    }
61545    inner2.unshift(leftDelim);
61546    if (hadMiddle) {
61547      for (var _i = 1; _i < inner2.length; _i++) {
61548        var middleDelim = inner2[_i];
61549        var isMiddle = middleDelim.isMiddle;
61550        if (isMiddle) {
61551          inner2[_i] = delimiter.leftRightDelim(isMiddle.delim, innerHeight, innerDepth, isMiddle.options, group.mode, []);
61552        }
61553      }
61554    }
61555    var rightDelim;
61556    if (group.right === ".") {
61557      rightDelim = makeNullDelimiter(options2, ["mclose"]);
61558    } else {
61559      var colorOptions = group.rightColor ? options2.withColor(group.rightColor) : options2;
61560      rightDelim = delimiter.leftRightDelim(group.right, innerHeight, innerDepth, colorOptions, group.mode, ["mclose"]);
61561    }
61562    inner2.push(rightDelim);
61563    return buildCommon.makeSpan(["minner"], inner2, options2);
61564  },
61565  mathmlBuilder: (group, options2) => {
61566    assertParsed(group);
61567    var inner2 = buildExpression2(group.body, options2);
61568    if (group.left !== ".") {
61569      var leftNode = new mathMLTree.MathNode("mo", [makeText(group.left, group.mode)]);
61570      leftNode.setAttribute("fence", "true");
61571      inner2.unshift(leftNode);
61572    }
61573    if (group.right !== ".") {
61574      var rightNode = new mathMLTree.MathNode("mo", [makeText(group.right, group.mode)]);
61575      rightNode.setAttribute("fence", "true");
61576      if (group.rightColor) {
61577        rightNode.setAttribute("mathcolor", group.rightColor);
61578      }
61579      inner2.push(rightNode);
61580    }
61581    return makeRow(inner2);
61582  }
61583});
61584defineFunction({
61585  type: "middle",
61586  names: ["\\middle"],
61587  props: {
61588    numArgs: 1,
61589    primitive: true
61590  },
61591  handler: (context, args) => {
61592    var delim = checkDelimiter(args[0], context);
61593    if (!context.parser.leftrightDepth) {
61594      throw new ParseError("\\middle without preceding \\left", delim);
61595    }
61596    return {
61597      type: "middle",
61598      mode: context.parser.mode,
61599      delim: delim.text
61600    };
61601  },
61602  htmlBuilder: (group, options2) => {
61603    var middleDelim;
61604    if (group.delim === ".") {
61605      middleDelim = makeNullDelimiter(options2, []);
61606    } else {
61607      middleDelim = delimiter.sizedDelim(group.delim, 1, options2, group.mode, []);
61608      var isMiddle = {
61609        delim: group.delim,
61610        options: options2
61611      };
61612      middleDelim.isMiddle = isMiddle;
61613    }
61614    return middleDelim;
61615  },
61616  mathmlBuilder: (group, options2) => {
61617    var textNode = group.delim === "\\vert" || group.delim === "|" ? makeText("|", "text") : makeText(group.delim, group.mode);
61618    var middleNode = new mathMLTree.MathNode("mo", [textNode]);
61619    middleNode.setAttribute("fence", "true");
61620    middleNode.setAttribute("lspace", "0.05em");
61621    middleNode.setAttribute("rspace", "0.05em");
61622    return middleNode;
61623  }
61624});
61625var htmlBuilder$7 = (group, options2) => {
61626  var inner2 = buildCommon.wrapFragment(buildGroup$1(group.body, options2), options2);
61627  var label = group.label.slice(1);
61628  var scale = options2.sizeMultiplier;
61629  var img;
61630  var imgShift = 0;
61631  var isSingleChar = utils.isCharacterBox(group.body);
61632  if (label === "sout") {
61633    img = buildCommon.makeSpan(["stretchy", "sout"]);
61634    img.height = options2.fontMetrics().defaultRuleThickness / scale;
61635    imgShift = -0.5 * options2.fontMetrics().xHeight;
61636  } else if (label === "phase") {
61637    var lineWeight = calculateSize({
61638      number: 0.6,
61639      unit: "pt"
61640    }, options2);
61641    var clearance = calculateSize({
61642      number: 0.35,
61643      unit: "ex"
61644    }, options2);
61645    var newOptions = options2.havingBaseSizing();
61646    scale = scale / newOptions.sizeMultiplier;
61647    var angleHeight = inner2.height + inner2.depth + lineWeight + clearance;
61648    inner2.style.paddingLeft = makeEm(angleHeight / 2 + lineWeight);
61649    var viewBoxHeight = Math.floor(1e3 * angleHeight * scale);
61650    var path2 = phasePath(viewBoxHeight);
61651    var svgNode = new SvgNode([new PathNode("phase", path2)], {
61652      "width": "400em",
61653      "height": makeEm(viewBoxHeight / 1e3),
61654      "viewBox": "0 0 400000 " + viewBoxHeight,
61655      "preserveAspectRatio": "xMinYMin slice"
61656    });
61657    img = buildCommon.makeSvgSpan(["hide-tail"], [svgNode], options2);
61658    img.style.height = makeEm(angleHeight);
61659    imgShift = inner2.depth + lineWeight + clearance;
61660  } else {
61661    if (/cancel/.test(label)) {
61662      if (!isSingleChar) {
61663        inner2.classes.push("cancel-pad");
61664      }
61665    } else if (label === "angl") {
61666      inner2.classes.push("anglpad");
61667    } else {
61668      inner2.classes.push("boxpad");
61669    }
61670    var topPad = 0;
61671    var bottomPad = 0;
61672    var ruleThickness = 0;
61673    if (/box/.test(label)) {
61674      ruleThickness = Math.max(
61675        options2.fontMetrics().fboxrule,
61676        // default
61677        options2.minRuleThickness
61678        // User override.
61679      );
61680      topPad = options2.fontMetrics().fboxsep + (label === "colorbox" ? 0 : ruleThickness);
61681      bottomPad = topPad;
61682    } else if (label === "angl") {
61683      ruleThickness = Math.max(options2.fontMetrics().defaultRuleThickness, options2.minRuleThickness);
61684      topPad = 4 * ruleThickness;
61685      bottomPad = Math.max(0, 0.25 - inner2.depth);
61686    } else {
61687      topPad = isSingleChar ? 0.2 : 0;
61688      bottomPad = topPad;
61689    }
61690    img = stretchy.encloseSpan(inner2, label, topPad, bottomPad, options2);
61691    if (/fbox|boxed|fcolorbox/.test(label)) {
61692      img.style.borderStyle = "solid";
61693      img.style.borderWidth = makeEm(ruleThickness);
61694    } else if (label === "angl" && ruleThickness !== 0.049) {
61695      img.style.borderTopWidth = makeEm(ruleThickness);
61696      img.style.borderRightWidth = makeEm(ruleThickness);
61697    }
61698    imgShift = inner2.depth + bottomPad;
61699    if (group.backgroundColor) {
61700      img.style.backgroundColor = group.backgroundColor;
61701      if (group.borderColor) {
61702        img.style.borderColor = group.borderColor;
61703      }
61704    }
61705  }
61706  var vlist;
61707  if (group.backgroundColor) {
61708    vlist = buildCommon.makeVList({
61709      positionType: "individualShift",
61710      children: [
61711        // Put the color background behind inner;
61712        {
61713          type: "elem",
61714          elem: img,
61715          shift: imgShift
61716        },
61717        {
61718          type: "elem",
61719          elem: inner2,
61720          shift: 0
61721        }
61722      ]
61723    }, options2);
61724  } else {
61725    var classes2 = /cancel|phase/.test(label) ? ["svg-align"] : [];
61726    vlist = buildCommon.makeVList({
61727      positionType: "individualShift",
61728      children: [
61729        // Write the \cancel stroke on top of inner.
61730        {
61731          type: "elem",
61732          elem: inner2,
61733          shift: 0
61734        },
61735        {
61736          type: "elem",
61737          elem: img,
61738          shift: imgShift,
61739          wrapperClasses: classes2
61740        }
61741      ]
61742    }, options2);
61743  }
61744  if (/cancel/.test(label)) {
61745    vlist.height = inner2.height;
61746    vlist.depth = inner2.depth;
61747  }
61748  if (/cancel/.test(label) && !isSingleChar) {
61749    return buildCommon.makeSpan(["mord", "cancel-lap"], [vlist], options2);
61750  } else {
61751    return buildCommon.makeSpan(["mord"], [vlist], options2);
61752  }
61753};
61754var mathmlBuilder$6 = (group, options2) => {
61755  var fboxsep = 0;
61756  var node = new mathMLTree.MathNode(group.label.indexOf("colorbox") > -1 ? "mpadded" : "menclose", [buildGroup2(group.body, options2)]);
61757  switch (group.label) {
61758    case "\\cancel":
61759      node.setAttribute("notation", "updiagonalstrike");
61760      break;
61761    case "\\bcancel":
61762      node.setAttribute("notation", "downdiagonalstrike");
61763      break;
61764    case "\\phase":
61765      node.setAttribute("notation", "phasorangle");
61766      break;
61767    case "\\sout":
61768      node.setAttribute("notation", "horizontalstrike");
61769      break;
61770    case "\\fbox":
61771      node.setAttribute("notation", "box");
61772      break;
61773    case "\\angl":
61774      node.setAttribute("notation", "actuarial");
61775      break;
61776    case "\\fcolorbox":
61777    case "\\colorbox":
61778      fboxsep = options2.fontMetrics().fboxsep * options2.fontMetrics().ptPerEm;
61779      node.setAttribute("width", "+" + 2 * fboxsep + "pt");
61780      node.setAttribute("height", "+" + 2 * fboxsep + "pt");
61781      node.setAttribute("lspace", fboxsep + "pt");
61782      node.setAttribute("voffset", fboxsep + "pt");
61783      if (group.label === "\\fcolorbox") {
61784        var thk = Math.max(
61785          options2.fontMetrics().fboxrule,
61786          // default
61787          options2.minRuleThickness
61788          // user override
61789        );
61790        node.setAttribute("style", "border: " + thk + "em solid " + String(group.borderColor));
61791      }
61792      break;
61793    case "\\xcancel":
61794      node.setAttribute("notation", "updiagonalstrike downdiagonalstrike");
61795      break;
61796  }
61797  if (group.backgroundColor) {
61798    node.setAttribute("mathbackground", group.backgroundColor);
61799  }
61800  return node;
61801};
61802defineFunction({
61803  type: "enclose",
61804  names: ["\\colorbox"],
61805  props: {
61806    numArgs: 2,
61807    allowedInText: true,
61808    argTypes: ["color", "text"]
61809  },
61810  handler(_ref, args, optArgs) {
61811    var {
61812      parser: parser2,
61813      funcName
61814    } = _ref;
61815    var color = assertNodeType(args[0], "color-token").color;
61816    var body = args[1];
61817    return {
61818      type: "enclose",
61819      mode: parser2.mode,
61820      label: funcName,
61821      backgroundColor: color,
61822      body
61823    };
61824  },
61825  htmlBuilder: htmlBuilder$7,
61826  mathmlBuilder: mathmlBuilder$6
61827});
61828defineFunction({
61829  type: "enclose",
61830  names: ["\\fcolorbox"],
61831  props: {
61832    numArgs: 3,
61833    allowedInText: true,
61834    argTypes: ["color", "color", "text"]
61835  },
61836  handler(_ref2, args, optArgs) {
61837    var {
61838      parser: parser2,
61839      funcName
61840    } = _ref2;
61841    var borderColor = assertNodeType(args[0], "color-token").color;
61842    var backgroundColor = assertNodeType(args[1], "color-token").color;
61843    var body = args[2];
61844    return {
61845      type: "enclose",
61846      mode: parser2.mode,
61847      label: funcName,
61848      backgroundColor,
61849      borderColor,
61850      body
61851    };
61852  },
61853  htmlBuilder: htmlBuilder$7,
61854  mathmlBuilder: mathmlBuilder$6
61855});
61856defineFunction({
61857  type: "enclose",
61858  names: ["\\fbox"],
61859  props: {
61860    numArgs: 1,
61861    argTypes: ["hbox"],
61862    allowedInText: true
61863  },
61864  handler(_ref3, args) {
61865    var {
61866      parser: parser2
61867    } = _ref3;
61868    return {
61869      type: "enclose",
61870      mode: parser2.mode,
61871      label: "\\fbox",
61872      body: args[0]
61873    };
61874  }
61875});
61876defineFunction({
61877  type: "enclose",
61878  names: ["\\cancel", "\\bcancel", "\\xcancel", "\\sout", "\\phase"],
61879  props: {
61880    numArgs: 1
61881  },
61882  handler(_ref4, args) {
61883    var {
61884      parser: parser2,
61885      funcName
61886    } = _ref4;
61887    var body = args[0];
61888    return {
61889      type: "enclose",
61890      mode: parser2.mode,
61891      label: funcName,
61892      body
61893    };
61894  },
61895  htmlBuilder: htmlBuilder$7,
61896  mathmlBuilder: mathmlBuilder$6
61897});
61898defineFunction({
61899  type: "enclose",
61900  names: ["\\angl"],
61901  props: {
61902    numArgs: 1,
61903    argTypes: ["hbox"],
61904    allowedInText: false
61905  },
61906  handler(_ref5, args) {
61907    var {
61908      parser: parser2
61909    } = _ref5;
61910    return {
61911      type: "enclose",
61912      mode: parser2.mode,
61913      label: "\\angl",
61914      body: args[0]
61915    };
61916  }
61917});
61918var _environments = {};
61919function defineEnvironment(_ref) {
61920  var {
61921    type,
61922    names,
61923    props,
61924    handler,
61925    htmlBuilder: htmlBuilder3,
61926    mathmlBuilder: mathmlBuilder3
61927  } = _ref;
61928  var data = {
61929    type,
61930    numArgs: props.numArgs || 0,
61931    allowedInText: false,
61932    numOptionalArgs: 0,
61933    handler
61934  };
61935  for (var i = 0; i < names.length; ++i) {
61936    _environments[names[i]] = data;
61937  }
61938  if (htmlBuilder3) {
61939    _htmlGroupBuilders[type] = htmlBuilder3;
61940  }
61941  if (mathmlBuilder3) {
61942    _mathmlGroupBuilders[type] = mathmlBuilder3;
61943  }
61944}
61945var _macros = {};
61946function defineMacro(name, body) {
61947  _macros[name] = body;
61948}
61949function getHLines(parser2) {
61950  var hlineInfo = [];
61951  parser2.consumeSpaces();
61952  var nxt = parser2.fetch().text;
61953  if (nxt === "\\relax") {
61954    parser2.consume();
61955    parser2.consumeSpaces();
61956    nxt = parser2.fetch().text;
61957  }
61958  while (nxt === "\\hline" || nxt === "\\hdashline") {
61959    parser2.consume();
61960    hlineInfo.push(nxt === "\\hdashline");
61961    parser2.consumeSpaces();
61962    nxt = parser2.fetch().text;
61963  }
61964  return hlineInfo;
61965}
61966var validateAmsEnvironmentContext = (context) => {
61967  var settings = context.parser.settings;
61968  if (!settings.displayMode) {
61969    throw new ParseError("{" + context.envName + "} can be used only in display mode.");
61970  }
61971};
61972function getAutoTag(name) {
61973  if (name.indexOf("ed") === -1) {
61974    return name.indexOf("*") === -1;
61975  }
61976}
61977function parseArray(parser2, _ref, style) {
61978  var {
61979    hskipBeforeAndAfter,
61980    addJot,
61981    cols,
61982    arraystretch,
61983    colSeparationType,
61984    autoTag,
61985    singleRow,
61986    emptySingleRow,
61987    maxNumCols,
61988    leqno
61989  } = _ref;
61990  parser2.gullet.beginGroup();
61991  if (!singleRow) {
61992    parser2.gullet.macros.set("\\cr", "\\\\\\relax");
61993  }
61994  if (!arraystretch) {
61995    var stretch = parser2.gullet.expandMacroAsText("\\arraystretch");
61996    if (stretch == null) {
61997      arraystretch = 1;
61998    } else {
61999      arraystretch = parseFloat(stretch);
62000      if (!arraystretch || arraystretch < 0) {
62001        throw new ParseError("Invalid \\arraystretch: " + stretch);
62002      }
62003    }
62004  }
62005  parser2.gullet.beginGroup();
62006  var row = [];
62007  var body = [row];
62008  var rowGaps = [];
62009  var hLinesBeforeRow = [];
62010  var tags = autoTag != null ? [] : void 0;
62011  function beginRow() {
62012    if (autoTag) {
62013      parser2.gullet.macros.set("\\@eqnsw", "1", true);
62014    }
62015  }
62016  function endRow() {
62017    if (tags) {
62018      if (parser2.gullet.macros.get("\\df@tag")) {
62019        tags.push(parser2.subparse([new Token("\\df@tag")]));
62020        parser2.gullet.macros.set("\\df@tag", void 0, true);
62021      } else {
62022        tags.push(Boolean(autoTag) && parser2.gullet.macros.get("\\@eqnsw") === "1");
62023      }
62024    }
62025  }
62026  beginRow();
62027  hLinesBeforeRow.push(getHLines(parser2));
62028  while (true) {
62029    var cell = parser2.parseExpression(false, singleRow ? "\\end" : "\\\\");
62030    parser2.gullet.endGroup();
62031    parser2.gullet.beginGroup();
62032    cell = {
62033      type: "ordgroup",
62034      mode: parser2.mode,
62035      body: cell
62036    };
62037    if (style) {
62038      cell = {
62039        type: "styling",
62040        mode: parser2.mode,
62041        style,
62042        body: [cell]
62043      };
62044    }
62045    row.push(cell);
62046    var next = parser2.fetch().text;
62047    if (next === "&") {
62048      if (maxNumCols && row.length === maxNumCols) {
62049        if (singleRow || colSeparationType) {
62050          throw new ParseError("Too many tab characters: &", parser2.nextToken);
62051        } else {
62052          parser2.settings.reportNonstrict("textEnv", "Too few columns specified in the {array} column argument.");
62053        }
62054      }
62055      parser2.consume();
62056    } else if (next === "\\end") {
62057      endRow();
62058      if (row.length === 1 && cell.type === "styling" && cell.body[0].body.length === 0 && (body.length > 1 || !emptySingleRow)) {
62059        body.pop();
62060      }
62061      if (hLinesBeforeRow.length < body.length + 1) {
62062        hLinesBeforeRow.push([]);
62063      }
62064      break;
62065    } else if (next === "\\\\") {
62066      parser2.consume();
62067      var size = void 0;
62068      if (parser2.gullet.future().text !== " ") {
62069        size = parser2.parseSizeGroup(true);
62070      }
62071      rowGaps.push(size ? size.value : null);
62072      endRow();
62073      hLinesBeforeRow.push(getHLines(parser2));
62074      row = [];
62075      body.push(row);
62076      beginRow();
62077    } else {
62078      throw new ParseError("Expected & or \\\\ or \\cr or \\end", parser2.nextToken);
62079    }
62080  }
62081  parser2.gullet.endGroup();
62082  parser2.gullet.endGroup();
62083  return {
62084    type: "array",
62085    mode: parser2.mode,
62086    addJot,
62087    arraystretch,
62088    body,
62089    cols,
62090    rowGaps,
62091    hskipBeforeAndAfter,
62092    hLinesBeforeRow,
62093    colSeparationType,
62094    tags,
62095    leqno
62096  };
62097}
62098function dCellStyle(envName) {
62099  if (envName.slice(0, 1) === "d") {
62100    return "display";
62101  } else {
62102    return "text";
62103  }
62104}
62105var htmlBuilder$6 = function htmlBuilder(group, options2) {
62106  var r;
62107  var c;
62108  var nr = group.body.length;
62109  var hLinesBeforeRow = group.hLinesBeforeRow;
62110  var nc = 0;
62111  var body = new Array(nr);
62112  var hlines = [];
62113  var ruleThickness = Math.max(
62114    // From LaTeX \showthe\arrayrulewidth. Equals 0.04 em.
62115    options2.fontMetrics().arrayRuleWidth,
62116    options2.minRuleThickness
62117    // User override.
62118  );
62119  var pt = 1 / options2.fontMetrics().ptPerEm;
62120  var arraycolsep = 5 * pt;
62121  if (group.colSeparationType && group.colSeparationType === "small") {
62122    var localMultiplier = options2.havingStyle(Style$1.SCRIPT).sizeMultiplier;
62123    arraycolsep = 0.2778 * (localMultiplier / options2.sizeMultiplier);
62124  }
62125  var baselineskip = group.colSeparationType === "CD" ? calculateSize({
62126    number: 3,
62127    unit: "ex"
62128  }, options2) : 12 * pt;
62129  var jot = 3 * pt;
62130  var arrayskip = group.arraystretch * baselineskip;
62131  var arstrutHeight = 0.7 * arrayskip;
62132  var arstrutDepth = 0.3 * arrayskip;
62133  var totalHeight = 0;
62134  function setHLinePos(hlinesInGap) {
62135    for (var i = 0; i < hlinesInGap.length; ++i) {
62136      if (i > 0) {
62137        totalHeight += 0.25;
62138      }
62139      hlines.push({
62140        pos: totalHeight,
62141        isDashed: hlinesInGap[i]
62142      });
62143    }
62144  }
62145  setHLinePos(hLinesBeforeRow[0]);
62146  for (r = 0; r < group.body.length; ++r) {
62147    var inrow = group.body[r];
62148    var height = arstrutHeight;
62149    var depth = arstrutDepth;
62150    if (nc < inrow.length) {
62151      nc = inrow.length;
62152    }
62153    var outrow = new Array(inrow.length);
62154    for (c = 0; c < inrow.length; ++c) {
62155      var elt = buildGroup$1(inrow[c], options2);
62156      if (depth < elt.depth) {
62157        depth = elt.depth;
62158      }
62159      if (height < elt.height) {
62160        height = elt.height;
62161      }
62162      outrow[c] = elt;
62163    }
62164    var rowGap = group.rowGaps[r];
62165    var gap = 0;
62166    if (rowGap) {
62167      gap = calculateSize(rowGap, options2);
62168      if (gap > 0) {
62169        gap += arstrutDepth;
62170        if (depth < gap) {
62171          depth = gap;
62172        }
62173        gap = 0;
62174      }
62175    }
62176    if (group.addJot) {
62177      depth += jot;
62178    }
62179    outrow.height = height;
62180    outrow.depth = depth;
62181    totalHeight += height;
62182    outrow.pos = totalHeight;
62183    totalHeight += depth + gap;
62184    body[r] = outrow;
62185    setHLinePos(hLinesBeforeRow[r + 1]);
62186  }
62187  var offset = totalHeight / 2 + options2.fontMetrics().axisHeight;
62188  var colDescriptions = group.cols || [];
62189  var cols = [];
62190  var colSep;
62191  var colDescrNum;
62192  var tagSpans = [];
62193  if (group.tags && group.tags.some((tag3) => tag3)) {
62194    for (r = 0; r < nr; ++r) {
62195      var rw = body[r];
62196      var shift = rw.pos - offset;
62197      var tag2 = group.tags[r];
62198      var tagSpan = void 0;
62199      if (tag2 === true) {
62200        tagSpan = buildCommon.makeSpan(["eqn-num"], [], options2);
62201      } else if (tag2 === false) {
62202        tagSpan = buildCommon.makeSpan([], [], options2);
62203      } else {
62204        tagSpan = buildCommon.makeSpan([], buildExpression$1(tag2, options2, true), options2);
62205      }
62206      tagSpan.depth = rw.depth;
62207      tagSpan.height = rw.height;
62208      tagSpans.push({
62209        type: "elem",
62210        elem: tagSpan,
62211        shift
62212      });
62213    }
62214  }
62215  for (
62216    c = 0, colDescrNum = 0;
62217    // Continue while either there are more columns or more column
62218    // descriptions, so trailing separators don't get lost.
62219    c < nc || colDescrNum < colDescriptions.length;
62220    ++c, ++colDescrNum
62221  ) {
62222    var colDescr = colDescriptions[colDescrNum] || {};
62223    var firstSeparator = true;
62224    while (colDescr.type === "separator") {
62225      if (!firstSeparator) {
62226        colSep = buildCommon.makeSpan(["arraycolsep"], []);
62227        colSep.style.width = makeEm(options2.fontMetrics().doubleRuleSep);
62228        cols.push(colSep);
62229      }
62230      if (colDescr.separator === "|" || colDescr.separator === ":") {
62231        var lineType = colDescr.separator === "|" ? "solid" : "dashed";
62232        var separator = buildCommon.makeSpan(["vertical-separator"], [], options2);
62233        separator.style.height = makeEm(totalHeight);
62234        separator.style.borderRightWidth = makeEm(ruleThickness);
62235        separator.style.borderRightStyle = lineType;
62236        separator.style.margin = "0 " + makeEm(-ruleThickness / 2);
62237        var _shift = totalHeight - offset;
62238        if (_shift) {
62239          separator.style.verticalAlign = makeEm(-_shift);
62240        }
62241        cols.push(separator);
62242      } else {
62243        throw new ParseError("Invalid separator type: " + colDescr.separator);
62244      }
62245      colDescrNum++;
62246      colDescr = colDescriptions[colDescrNum] || {};
62247      firstSeparator = false;
62248    }
62249    if (c >= nc) {
62250      continue;
62251    }
62252    var sepwidth = void 0;
62253    if (c > 0 || group.hskipBeforeAndAfter) {
62254      sepwidth = utils.deflt(colDescr.pregap, arraycolsep);
62255      if (sepwidth !== 0) {
62256        colSep = buildCommon.makeSpan(["arraycolsep"], []);
62257        colSep.style.width = makeEm(sepwidth);
62258        cols.push(colSep);
62259      }
62260    }
62261    var col = [];
62262    for (r = 0; r < nr; ++r) {
62263      var row = body[r];
62264      var elem = row[c];
62265      if (!elem) {
62266        continue;
62267      }
62268      var _shift2 = row.pos - offset;
62269      elem.depth = row.depth;
62270      elem.height = row.height;
62271      col.push({
62272        type: "elem",
62273        elem,
62274        shift: _shift2
62275      });
62276    }
62277    col = buildCommon.makeVList({
62278      positionType: "individualShift",
62279      children: col
62280    }, options2);
62281    col = buildCommon.makeSpan(["col-align-" + (colDescr.align || "c")], [col]);
62282    cols.push(col);
62283    if (c < nc - 1 || group.hskipBeforeAndAfter) {
62284      sepwidth = utils.deflt(colDescr.postgap, arraycolsep);
62285      if (sepwidth !== 0) {
62286        colSep = buildCommon.makeSpan(["arraycolsep"], []);
62287        colSep.style.width = makeEm(sepwidth);
62288        cols.push(colSep);
62289      }
62290    }
62291  }
62292  body = buildCommon.makeSpan(["mtable"], cols);
62293  if (hlines.length > 0) {
62294    var line = buildCommon.makeLineSpan("hline", options2, ruleThickness);
62295    var dashes = buildCommon.makeLineSpan("hdashline", options2, ruleThickness);
62296    var vListElems = [{
62297      type: "elem",
62298      elem: body,
62299      shift: 0
62300    }];
62301    while (hlines.length > 0) {
62302      var hline = hlines.pop();
62303      var lineShift = hline.pos - offset;
62304      if (hline.isDashed) {
62305        vListElems.push({
62306          type: "elem",
62307          elem: dashes,
62308          shift: lineShift
62309        });
62310      } else {
62311        vListElems.push({
62312          type: "elem",
62313          elem: line,
62314          shift: lineShift
62315        });
62316      }
62317    }
62318    body = buildCommon.makeVList({
62319      positionType: "individualShift",
62320      children: vListElems
62321    }, options2);
62322  }
62323  if (tagSpans.length === 0) {
62324    return buildCommon.makeSpan(["mord"], [body], options2);
62325  } else {
62326    var eqnNumCol = buildCommon.makeVList({
62327      positionType: "individualShift",
62328      children: tagSpans
62329    }, options2);
62330    eqnNumCol = buildCommon.makeSpan(["tag"], [eqnNumCol], options2);
62331    return buildCommon.makeFragment([body, eqnNumCol]);
62332  }
62333};
62334var alignMap = {
62335  c: "center ",
62336  l: "left ",
62337  r: "right "
62338};
62339var mathmlBuilder$5 = function mathmlBuilder(group, options2) {
62340  var tbl = [];
62341  var glue = new mathMLTree.MathNode("mtd", [], ["mtr-glue"]);
62342  var tag2 = new mathMLTree.MathNode("mtd", [], ["mml-eqn-num"]);
62343  for (var i = 0; i < group.body.length; i++) {
62344    var rw = group.body[i];
62345    var row = [];
62346    for (var j = 0; j < rw.length; j++) {
62347      row.push(new mathMLTree.MathNode("mtd", [buildGroup2(rw[j], options2)]));
62348    }
62349    if (group.tags && group.tags[i]) {
62350      row.unshift(glue);
62351      row.push(glue);
62352      if (group.leqno) {
62353        row.unshift(tag2);
62354      } else {
62355        row.push(tag2);
62356      }
62357    }
62358    tbl.push(new mathMLTree.MathNode("mtr", row));
62359  }
62360  var table = new mathMLTree.MathNode("mtable", tbl);
62361  var gap = group.arraystretch === 0.5 ? 0.1 : 0.16 + group.arraystretch - 1 + (group.addJot ? 0.09 : 0);
62362  table.setAttribute("rowspacing", makeEm(gap));
62363  var menclose = "";
62364  var align = "";
62365  if (group.cols && group.cols.length > 0) {
62366    var cols = group.cols;
62367    var columnLines = "";
62368    var prevTypeWasAlign = false;
62369    var iStart = 0;
62370    var iEnd = cols.length;
62371    if (cols[0].type === "separator") {
62372      menclose += "top ";
62373      iStart = 1;
62374    }
62375    if (cols[cols.length - 1].type === "separator") {
62376      menclose += "bottom ";
62377      iEnd -= 1;
62378    }
62379    for (var _i = iStart; _i < iEnd; _i++) {
62380      if (cols[_i].type === "align") {
62381        align += alignMap[cols[_i].align];
62382        if (prevTypeWasAlign) {
62383          columnLines += "none ";
62384        }
62385        prevTypeWasAlign = true;
62386      } else if (cols[_i].type === "separator") {
62387        if (prevTypeWasAlign) {
62388          columnLines += cols[_i].separator === "|" ? "solid " : "dashed ";
62389          prevTypeWasAlign = false;
62390        }
62391      }
62392    }
62393    table.setAttribute("columnalign", align.trim());
62394    if (/[sd]/.test(columnLines)) {
62395      table.setAttribute("columnlines", columnLines.trim());
62396    }
62397  }
62398  if (group.colSeparationType === "align") {
62399    var _cols = group.cols || [];
62400    var spacing2 = "";
62401    for (var _i2 = 1; _i2 < _cols.length; _i2++) {
62402      spacing2 += _i2 % 2 ? "0em " : "1em ";
62403    }
62404    table.setAttribute("columnspacing", spacing2.trim());
62405  } else if (group.colSeparationType === "alignat" || group.colSeparationType === "gather") {
62406    table.setAttribute("columnspacing", "0em");
62407  } else if (group.colSeparationType === "small") {
62408    table.setAttribute("columnspacing", "0.2778em");
62409  } else if (group.colSeparationType === "CD") {
62410    table.setAttribute("columnspacing", "0.5em");
62411  } else {
62412    table.setAttribute("columnspacing", "1em");
62413  }
62414  var rowLines = "";
62415  var hlines = group.hLinesBeforeRow;
62416  menclose += hlines[0].length > 0 ? "left " : "";
62417  menclose += hlines[hlines.length - 1].length > 0 ? "right " : "";
62418  for (var _i3 = 1; _i3 < hlines.length - 1; _i3++) {
62419    rowLines += hlines[_i3].length === 0 ? "none " : hlines[_i3][0] ? "dashed " : "solid ";
62420  }
62421  if (/[sd]/.test(rowLines)) {
62422    table.setAttribute("rowlines", rowLines.trim());
62423  }
62424  if (menclose !== "") {
62425    table = new mathMLTree.MathNode("menclose", [table]);
62426    table.setAttribute("notation", menclose.trim());
62427  }
62428  if (group.arraystretch && group.arraystretch < 1) {
62429    table = new mathMLTree.MathNode("mstyle", [table]);
62430    table.setAttribute("scriptlevel", "1");
62431  }
62432  return table;
62433};
62434var alignedHandler = function alignedHandler2(context, args) {
62435  if (context.envName.indexOf("ed") === -1) {
62436    validateAmsEnvironmentContext(context);
62437  }
62438  var cols = [];
62439  var separationType = context.envName.indexOf("at") > -1 ? "alignat" : "align";
62440  var isSplit = context.envName === "split";
62441  var res = parseArray(context.parser, {
62442    cols,
62443    addJot: true,
62444    autoTag: isSplit ? void 0 : getAutoTag(context.envName),
62445    emptySingleRow: true,
62446    colSeparationType: separationType,
62447    maxNumCols: isSplit ? 2 : void 0,
62448    leqno: context.parser.settings.leqno
62449  }, "display");
62450  var numMaths;
62451  var numCols = 0;
62452  var emptyGroup = {
62453    type: "ordgroup",
62454    mode: context.mode,
62455    body: []
62456  };
62457  if (args[0] && args[0].type === "ordgroup") {
62458    var arg0 = "";
62459    for (var i = 0; i < args[0].body.length; i++) {
62460      var textord2 = assertNodeType(args[0].body[i], "textord");
62461      arg0 += textord2.text;
62462    }
62463    numMaths = Number(arg0);
62464    numCols = numMaths * 2;
62465  }
62466  var isAligned = !numCols;
62467  res.body.forEach(function(row) {
62468    for (var _i4 = 1; _i4 < row.length; _i4 += 2) {
62469      var styling = assertNodeType(row[_i4], "styling");
62470      var ordgroup = assertNodeType(styling.body[0], "ordgroup");
62471      ordgroup.body.unshift(emptyGroup);
62472    }
62473    if (!isAligned) {
62474      var curMaths = row.length / 2;
62475      if (numMaths < curMaths) {
62476        throw new ParseError("Too many math in a row: " + ("expected " + numMaths + ", but got " + curMaths), row[0]);
62477      }
62478    } else if (numCols < row.length) {
62479      numCols = row.length;
62480    }
62481  });
62482  for (var _i5 = 0; _i5 < numCols; ++_i5) {
62483    var align = "r";
62484    var pregap = 0;
62485    if (_i5 % 2 === 1) {
62486      align = "l";
62487    } else if (_i5 > 0 && isAligned) {
62488      pregap = 1;
62489    }
62490    cols[_i5] = {
62491      type: "align",
62492      align,
62493      pregap,
62494      postgap: 0
62495    };
62496  }
62497  res.colSeparationType = isAligned ? "align" : "alignat";
62498  return res;
62499};
62500defineEnvironment({
62501  type: "array",
62502  names: ["array", "darray"],
62503  props: {
62504    numArgs: 1
62505  },
62506  handler(context, args) {
62507    var symNode = checkSymbolNodeType(args[0]);
62508    var colalign = symNode ? [args[0]] : assertNodeType(args[0], "ordgroup").body;
62509    var cols = colalign.map(function(nde) {
62510      var node = assertSymbolNodeType(nde);
62511      var ca = node.text;
62512      if ("lcr".indexOf(ca) !== -1) {
62513        return {
62514          type: "align",
62515          align: ca
62516        };
62517      } else if (ca === "|") {
62518        return {
62519          type: "separator",
62520          separator: "|"
62521        };
62522      } else if (ca === ":") {
62523        return {
62524          type: "separator",
62525          separator: ":"
62526        };
62527      }
62528      throw new ParseError("Unknown column alignment: " + ca, nde);
62529    });
62530    var res = {
62531      cols,
62532      hskipBeforeAndAfter: true,
62533      // \@preamble in lttab.dtx
62534      maxNumCols: cols.length
62535    };
62536    return parseArray(context.parser, res, dCellStyle(context.envName));
62537  },
62538  htmlBuilder: htmlBuilder$6,
62539  mathmlBuilder: mathmlBuilder$5
62540});
62541defineEnvironment({
62542  type: "array",
62543  names: ["matrix", "pmatrix", "bmatrix", "Bmatrix", "vmatrix", "Vmatrix", "matrix*", "pmatrix*", "bmatrix*", "Bmatrix*", "vmatrix*", "Vmatrix*"],
62544  props: {
62545    numArgs: 0
62546  },
62547  handler(context) {
62548    var delimiters2 = {
62549      "matrix": null,
62550      "pmatrix": ["(", ")"],
62551      "bmatrix": ["[", "]"],
62552      "Bmatrix": ["\\{", "\\}"],
62553      "vmatrix": ["|", "|"],
62554      "Vmatrix": ["\\Vert", "\\Vert"]
62555    }[context.envName.replace("*", "")];
62556    var colAlign = "c";
62557    var payload = {
62558      hskipBeforeAndAfter: false,
62559      cols: [{
62560        type: "align",
62561        align: colAlign
62562      }]
62563    };
62564    if (context.envName.charAt(context.envName.length - 1) === "*") {
62565      var parser2 = context.parser;
62566      parser2.consumeSpaces();
62567      if (parser2.fetch().text === "[") {
62568        parser2.consume();
62569        parser2.consumeSpaces();
62570        colAlign = parser2.fetch().text;
62571        if ("lcr".indexOf(colAlign) === -1) {
62572          throw new ParseError("Expected l or c or r", parser2.nextToken);
62573        }
62574        parser2.consume();
62575        parser2.consumeSpaces();
62576        parser2.expect("]");
62577        parser2.consume();
62578        payload.cols = [{
62579          type: "align",
62580          align: colAlign
62581        }];
62582      }
62583    }
62584    var res = parseArray(context.parser, payload, dCellStyle(context.envName));
62585    var numCols = Math.max(0, ...res.body.map((row) => row.length));
62586    res.cols = new Array(numCols).fill({
62587      type: "align",
62588      align: colAlign
62589    });
62590    return delimiters2 ? {
62591      type: "leftright",
62592      mode: context.mode,
62593      body: [res],
62594      left: delimiters2[0],
62595      right: delimiters2[1],
62596      rightColor: void 0
62597      // \right uninfluenced by \color in array
62598    } : res;
62599  },
62600  htmlBuilder: htmlBuilder$6,
62601  mathmlBuilder: mathmlBuilder$5
62602});
62603defineEnvironment({
62604  type: "array",
62605  names: ["smallmatrix"],
62606  props: {
62607    numArgs: 0
62608  },
62609  handler(context) {
62610    var payload = {
62611      arraystretch: 0.5
62612    };
62613    var res = parseArray(context.parser, payload, "script");
62614    res.colSeparationType = "small";
62615    return res;
62616  },
62617  htmlBuilder: htmlBuilder$6,
62618  mathmlBuilder: mathmlBuilder$5
62619});
62620defineEnvironment({
62621  type: "array",
62622  names: ["subarray"],
62623  props: {
62624    numArgs: 1
62625  },
62626  handler(context, args) {
62627    var symNode = checkSymbolNodeType(args[0]);
62628    var colalign = symNode ? [args[0]] : assertNodeType(args[0], "ordgroup").body;
62629    var cols = colalign.map(function(nde) {
62630      var node = assertSymbolNodeType(nde);
62631      var ca = node.text;
62632      if ("lc".indexOf(ca) !== -1) {
62633        return {
62634          type: "align",
62635          align: ca
62636        };
62637      }
62638      throw new ParseError("Unknown column alignment: " + ca, nde);
62639    });
62640    if (cols.length > 1) {
62641      throw new ParseError("{subarray} can contain only one column");
62642    }
62643    var res = {
62644      cols,
62645      hskipBeforeAndAfter: false,
62646      arraystretch: 0.5
62647    };
62648    res = parseArray(context.parser, res, "script");
62649    if (res.body.length > 0 && res.body[0].length > 1) {
62650      throw new ParseError("{subarray} can contain only one column");
62651    }
62652    return res;
62653  },
62654  htmlBuilder: htmlBuilder$6,
62655  mathmlBuilder: mathmlBuilder$5
62656});
62657defineEnvironment({
62658  type: "array",
62659  names: ["cases", "dcases", "rcases", "drcases"],
62660  props: {
62661    numArgs: 0
62662  },
62663  handler(context) {
62664    var payload = {
62665      arraystretch: 1.2,
62666      cols: [{
62667        type: "align",
62668        align: "l",
62669        pregap: 0,
62670        // TODO(kevinb) get the current style.
62671        // For now we use the metrics for TEXT style which is what we were
62672        // doing before.  Before attempting to get the current style we
62673        // should look at TeX's behavior especially for \over and matrices.
62674        postgap: 1
62675        /* 1em quad */
62676      }, {
62677        type: "align",
62678        align: "l",
62679        pregap: 0,
62680        postgap: 0
62681      }]
62682    };
62683    var res = parseArray(context.parser, payload, dCellStyle(context.envName));
62684    return {
62685      type: "leftright",
62686      mode: context.mode,
62687      body: [res],
62688      left: context.envName.indexOf("r") > -1 ? "." : "\\{",
62689      right: context.envName.indexOf("r") > -1 ? "\\}" : ".",
62690      rightColor: void 0
62691    };
62692  },
62693  htmlBuilder: htmlBuilder$6,
62694  mathmlBuilder: mathmlBuilder$5
62695});
62696defineEnvironment({
62697  type: "array",
62698  names: ["align", "align*", "aligned", "split"],
62699  props: {
62700    numArgs: 0
62701  },
62702  handler: alignedHandler,
62703  htmlBuilder: htmlBuilder$6,
62704  mathmlBuilder: mathmlBuilder$5
62705});
62706defineEnvironment({
62707  type: "array",
62708  names: ["gathered", "gather", "gather*"],
62709  props: {
62710    numArgs: 0
62711  },
62712  handler(context) {
62713    if (utils.contains(["gather", "gather*"], context.envName)) {
62714      validateAmsEnvironmentContext(context);
62715    }
62716    var res = {
62717      cols: [{
62718        type: "align",
62719        align: "c"
62720      }],
62721      addJot: true,
62722      colSeparationType: "gather",
62723      autoTag: getAutoTag(context.envName),
62724      emptySingleRow: true,
62725      leqno: context.parser.settings.leqno
62726    };
62727    return parseArray(context.parser, res, "display");
62728  },
62729  htmlBuilder: htmlBuilder$6,
62730  mathmlBuilder: mathmlBuilder$5
62731});
62732defineEnvironment({
62733  type: "array",
62734  names: ["alignat", "alignat*", "alignedat"],
62735  props: {
62736    numArgs: 1
62737  },
62738  handler: alignedHandler,
62739  htmlBuilder: htmlBuilder$6,
62740  mathmlBuilder: mathmlBuilder$5
62741});
62742defineEnvironment({
62743  type: "array",
62744  names: ["equation", "equation*"],
62745  props: {
62746    numArgs: 0
62747  },
62748  handler(context) {
62749    validateAmsEnvironmentContext(context);
62750    var res = {
62751      autoTag: getAutoTag(context.envName),
62752      emptySingleRow: true,
62753      singleRow: true,
62754      maxNumCols: 1,
62755      leqno: context.parser.settings.leqno
62756    };
62757    return parseArray(context.parser, res, "display");
62758  },
62759  htmlBuilder: htmlBuilder$6,
62760  mathmlBuilder: mathmlBuilder$5
62761});
62762defineEnvironment({
62763  type: "array",
62764  names: ["CD"],
62765  props: {
62766    numArgs: 0
62767  },
62768  handler(context) {
62769    validateAmsEnvironmentContext(context);
62770    return parseCD(context.parser);
62771  },
62772  htmlBuilder: htmlBuilder$6,
62773  mathmlBuilder: mathmlBuilder$5
62774});
62775defineMacro("\\nonumber", "\\gdef\\@eqnsw{0}");
62776defineMacro("\\notag", "\\nonumber");
62777defineFunction({
62778  type: "text",
62779  // Doesn't matter what this is.
62780  names: ["\\hline", "\\hdashline"],
62781  props: {
62782    numArgs: 0,
62783    allowedInText: true,
62784    allowedInMath: true
62785  },
62786  handler(context, args) {
62787    throw new ParseError(context.funcName + " valid only within array environment");
62788  }
62789});
62790var environments = _environments;
62791defineFunction({
62792  type: "environment",
62793  names: ["\\begin", "\\end"],
62794  props: {
62795    numArgs: 1,
62796    argTypes: ["text"]
62797  },
62798  handler(_ref, args) {
62799    var {
62800      parser: parser2,
62801      funcName
62802    } = _ref;
62803    var nameGroup = args[0];
62804    if (nameGroup.type !== "ordgroup") {
62805      throw new ParseError("Invalid environment name", nameGroup);
62806    }
62807    var envName = "";
62808    for (var i = 0; i < nameGroup.body.length; ++i) {
62809      envName += assertNodeType(nameGroup.body[i], "textord").text;
62810    }
62811    if (funcName === "\\begin") {
62812      if (!environments.hasOwnProperty(envName)) {
62813        throw new ParseError("No such environment: " + envName, nameGroup);
62814      }
62815      var env = environments[envName];
62816      var {
62817        args: _args,
62818        optArgs
62819      } = parser2.parseArguments("\\begin{" + envName + "}", env);
62820      var context = {
62821        mode: parser2.mode,
62822        envName,
62823        parser: parser2
62824      };
62825      var result = env.handler(context, _args, optArgs);
62826      parser2.expect("\\end", false);
62827      var endNameToken = parser2.nextToken;
62828      var end = assertNodeType(parser2.parseFunction(), "environment");
62829      if (end.name !== envName) {
62830        throw new ParseError("Mismatch: \\begin{" + envName + "} matched by \\end{" + end.name + "}", endNameToken);
62831      }
62832      return result;
62833    }
62834    return {
62835      type: "environment",
62836      mode: parser2.mode,
62837      name: envName,
62838      nameGroup
62839    };
62840  }
62841});
62842var htmlBuilder$5 = (group, options2) => {
62843  var font = group.font;
62844  var newOptions = options2.withFont(font);
62845  return buildGroup$1(group.body, newOptions);
62846};
62847var mathmlBuilder$4 = (group, options2) => {
62848  var font = group.font;
62849  var newOptions = options2.withFont(font);
62850  return buildGroup2(group.body, newOptions);
62851};
62852var fontAliases = {
62853  "\\Bbb": "\\mathbb",
62854  "\\bold": "\\mathbf",
62855  "\\frak": "\\mathfrak",
62856  "\\bm": "\\boldsymbol"
62857};
62858defineFunction({
62859  type: "font",
62860  names: [
62861    // styles, except \boldsymbol defined below
62862    "\\mathrm",
62863    "\\mathit",
62864    "\\mathbf",
62865    "\\mathnormal",
62866    "\\mathsfit",
62867    // families
62868    "\\mathbb",
62869    "\\mathcal",
62870    "\\mathfrak",
62871    "\\mathscr",
62872    "\\mathsf",
62873    "\\mathtt",
62874    // aliases, except \bm defined below
62875    "\\Bbb",
62876    "\\bold",
62877    "\\frak"
62878  ],
62879  props: {
62880    numArgs: 1,
62881    allowedInArgument: true
62882  },
62883  handler: (_ref, args) => {
62884    var {
62885      parser: parser2,
62886      funcName
62887    } = _ref;
62888    var body = normalizeArgument(args[0]);
62889    var func = funcName;
62890    if (func in fontAliases) {
62891      func = fontAliases[func];
62892    }
62893    return {
62894      type: "font",
62895      mode: parser2.mode,
62896      font: func.slice(1),
62897      body
62898    };
62899  },
62900  htmlBuilder: htmlBuilder$5,
62901  mathmlBuilder: mathmlBuilder$4
62902});
62903defineFunction({
62904  type: "mclass",
62905  names: ["\\boldsymbol", "\\bm"],
62906  props: {
62907    numArgs: 1
62908  },
62909  handler: (_ref2, args) => {
62910    var {
62911      parser: parser2
62912    } = _ref2;
62913    var body = args[0];
62914    var isCharacterBox3 = utils.isCharacterBox(body);
62915    return {
62916      type: "mclass",
62917      mode: parser2.mode,
62918      mclass: binrelClass(body),
62919      body: [{
62920        type: "font",
62921        mode: parser2.mode,
62922        font: "boldsymbol",
62923        body
62924      }],
62925      isCharacterBox: isCharacterBox3
62926    };
62927  }
62928});
62929defineFunction({
62930  type: "font",
62931  names: ["\\rm", "\\sf", "\\tt", "\\bf", "\\it", "\\cal"],
62932  props: {
62933    numArgs: 0,
62934    allowedInText: true
62935  },
62936  handler: (_ref3, args) => {
62937    var {
62938      parser: parser2,
62939      funcName,
62940      breakOnTokenText
62941    } = _ref3;
62942    var {
62943      mode
62944    } = parser2;
62945    var body = parser2.parseExpression(true, breakOnTokenText);
62946    var style = "math" + funcName.slice(1);
62947    return {
62948      type: "font",
62949      mode,
62950      font: style,
62951      body: {
62952        type: "ordgroup",
62953        mode: parser2.mode,
62954        body
62955      }
62956    };
62957  },
62958  htmlBuilder: htmlBuilder$5,
62959  mathmlBuilder: mathmlBuilder$4
62960});
62961var adjustStyle = (size, originalStyle) => {
62962  var style = originalStyle;
62963  if (size === "display") {
62964    style = style.id >= Style$1.SCRIPT.id ? style.text() : Style$1.DISPLAY;
62965  } else if (size === "text" && style.size === Style$1.DISPLAY.size) {
62966    style = Style$1.TEXT;
62967  } else if (size === "script") {
62968    style = Style$1.SCRIPT;
62969  } else if (size === "scriptscript") {
62970    style = Style$1.SCRIPTSCRIPT;
62971  }
62972  return style;
62973};
62974var htmlBuilder$4 = (group, options2) => {
62975  var style = adjustStyle(group.size, options2.style);
62976  var nstyle = style.fracNum();
62977  var dstyle = style.fracDen();
62978  var newOptions;
62979  newOptions = options2.havingStyle(nstyle);
62980  var numerm = buildGroup$1(group.numer, newOptions, options2);
62981  if (group.continued) {
62982    var hStrut = 8.5 / options2.fontMetrics().ptPerEm;
62983    var dStrut = 3.5 / options2.fontMetrics().ptPerEm;
62984    numerm.height = numerm.height < hStrut ? hStrut : numerm.height;
62985    numerm.depth = numerm.depth < dStrut ? dStrut : numerm.depth;
62986  }
62987  newOptions = options2.havingStyle(dstyle);
62988  var denomm = buildGroup$1(group.denom, newOptions, options2);
62989  var rule;
62990  var ruleWidth;
62991  var ruleSpacing;
62992  if (group.hasBarLine) {
62993    if (group.barSize) {
62994      ruleWidth = calculateSize(group.barSize, options2);
62995      rule = buildCommon.makeLineSpan("frac-line", options2, ruleWidth);
62996    } else {
62997      rule = buildCommon.makeLineSpan("frac-line", options2);
62998    }
62999    ruleWidth = rule.height;
63000    ruleSpacing = rule.height;
63001  } else {
63002    rule = null;
63003    ruleWidth = 0;
63004    ruleSpacing = options2.fontMetrics().defaultRuleThickness;
63005  }
63006  var numShift;
63007  var clearance;
63008  var denomShift;
63009  if (style.size === Style$1.DISPLAY.size || group.size === "display") {
63010    numShift = options2.fontMetrics().num1;
63011    if (ruleWidth > 0) {
63012      clearance = 3 * ruleSpacing;
63013    } else {
63014      clearance = 7 * ruleSpacing;
63015    }
63016    denomShift = options2.fontMetrics().denom1;
63017  } else {
63018    if (ruleWidth > 0) {
63019      numShift = options2.fontMetrics().num2;
63020      clearance = ruleSpacing;
63021    } else {
63022      numShift = options2.fontMetrics().num3;
63023      clearance = 3 * ruleSpacing;
63024    }
63025    denomShift = options2.fontMetrics().denom2;
63026  }
63027  var frac;
63028  if (!rule) {
63029    var candidateClearance = numShift - numerm.depth - (denomm.height - denomShift);
63030    if (candidateClearance < clearance) {
63031      numShift += 0.5 * (clearance - candidateClearance);
63032      denomShift += 0.5 * (clearance - candidateClearance);
63033    }
63034    frac = buildCommon.makeVList({
63035      positionType: "individualShift",
63036      children: [{
63037        type: "elem",
63038        elem: denomm,
63039        shift: denomShift
63040      }, {
63041        type: "elem",
63042        elem: numerm,
63043        shift: -numShift
63044      }]
63045    }, options2);
63046  } else {
63047    var axisHeight = options2.fontMetrics().axisHeight;
63048    if (numShift - numerm.depth - (axisHeight + 0.5 * ruleWidth) < clearance) {
63049      numShift += clearance - (numShift - numerm.depth - (axisHeight + 0.5 * ruleWidth));
63050    }
63051    if (axisHeight - 0.5 * ruleWidth - (denomm.height - denomShift) < clearance) {
63052      denomShift += clearance - (axisHeight - 0.5 * ruleWidth - (denomm.height - denomShift));
63053    }
63054    var midShift = -(axisHeight - 0.5 * ruleWidth);
63055    frac = buildCommon.makeVList({
63056      positionType: "individualShift",
63057      children: [{
63058        type: "elem",
63059        elem: denomm,
63060        shift: denomShift
63061      }, {
63062        type: "elem",
63063        elem: rule,
63064        shift: midShift
63065      }, {
63066        type: "elem",
63067        elem: numerm,
63068        shift: -numShift
63069      }]
63070    }, options2);
63071  }
63072  newOptions = options2.havingStyle(style);
63073  frac.height *= newOptions.sizeMultiplier / options2.sizeMultiplier;
63074  frac.depth *= newOptions.sizeMultiplier / options2.sizeMultiplier;
63075  var delimSize;
63076  if (style.size === Style$1.DISPLAY.size) {
63077    delimSize = options2.fontMetrics().delim1;
63078  } else if (style.size === Style$1.SCRIPTSCRIPT.size) {
63079    delimSize = options2.havingStyle(Style$1.SCRIPT).fontMetrics().delim2;
63080  } else {
63081    delimSize = options2.fontMetrics().delim2;
63082  }
63083  var leftDelim;
63084  var rightDelim;
63085  if (group.leftDelim == null) {
63086    leftDelim = makeNullDelimiter(options2, ["mopen"]);
63087  } else {
63088    leftDelim = delimiter.customSizedDelim(group.leftDelim, delimSize, true, options2.havingStyle(style), group.mode, ["mopen"]);
63089  }
63090  if (group.continued) {
63091    rightDelim = buildCommon.makeSpan([]);
63092  } else if (group.rightDelim == null) {
63093    rightDelim = makeNullDelimiter(options2, ["mclose"]);
63094  } else {
63095    rightDelim = delimiter.customSizedDelim(group.rightDelim, delimSize, true, options2.havingStyle(style), group.mode, ["mclose"]);
63096  }
63097  return buildCommon.makeSpan(["mord"].concat(newOptions.sizingClasses(options2)), [leftDelim, buildCommon.makeSpan(["mfrac"], [frac]), rightDelim], options2);
63098};
63099var mathmlBuilder$3 = (group, options2) => {
63100  var node = new mathMLTree.MathNode("mfrac", [buildGroup2(group.numer, options2), buildGroup2(group.denom, options2)]);
63101  if (!group.hasBarLine) {
63102    node.setAttribute("linethickness", "0px");
63103  } else if (group.barSize) {
63104    var ruleWidth = calculateSize(group.barSize, options2);
63105    node.setAttribute("linethickness", makeEm(ruleWidth));
63106  }
63107  var style = adjustStyle(group.size, options2.style);
63108  if (style.size !== options2.style.size) {
63109    node = new mathMLTree.MathNode("mstyle", [node]);
63110    var isDisplay = style.size === Style$1.DISPLAY.size ? "true" : "false";
63111    node.setAttribute("displaystyle", isDisplay);
63112    node.setAttribute("scriptlevel", "0");
63113  }
63114  if (group.leftDelim != null || group.rightDelim != null) {
63115    var withDelims = [];
63116    if (group.leftDelim != null) {
63117      var leftOp = new mathMLTree.MathNode("mo", [new mathMLTree.TextNode(group.leftDelim.replace("\\", ""))]);
63118      leftOp.setAttribute("fence", "true");
63119      withDelims.push(leftOp);
63120    }
63121    withDelims.push(node);
63122    if (group.rightDelim != null) {
63123      var rightOp = new mathMLTree.MathNode("mo", [new mathMLTree.TextNode(group.rightDelim.replace("\\", ""))]);
63124      rightOp.setAttribute("fence", "true");
63125      withDelims.push(rightOp);
63126    }
63127    return makeRow(withDelims);
63128  }
63129  return node;
63130};
63131defineFunction({
63132  type: "genfrac",
63133  names: [
63134    "\\dfrac",
63135    "\\frac",
63136    "\\tfrac",
63137    "\\dbinom",
63138    "\\binom",
63139    "\\tbinom",
63140    "\\\\atopfrac",
63141    // can’t be entered directly
63142    "\\\\bracefrac",
63143    "\\\\brackfrac"
63144    // ditto
63145  ],
63146  props: {
63147    numArgs: 2,
63148    allowedInArgument: true
63149  },
63150  handler: (_ref, args) => {
63151    var {
63152      parser: parser2,
63153      funcName
63154    } = _ref;
63155    var numer = args[0];
63156    var denom = args[1];
63157    var hasBarLine;
63158    var leftDelim = null;
63159    var rightDelim = null;
63160    var size = "auto";
63161    switch (funcName) {
63162      case "\\dfrac":
63163      case "\\frac":
63164      case "\\tfrac":
63165        hasBarLine = true;
63166        break;
63167      case "\\\\atopfrac":
63168        hasBarLine = false;
63169        break;
63170      case "\\dbinom":
63171      case "\\binom":
63172      case "\\tbinom":
63173        hasBarLine = false;
63174        leftDelim = "(";
63175        rightDelim = ")";
63176        break;
63177      case "\\\\bracefrac":
63178        hasBarLine = false;
63179        leftDelim = "\\{";
63180        rightDelim = "\\}";
63181        break;
63182      case "\\\\brackfrac":
63183        hasBarLine = false;
63184        leftDelim = "[";
63185        rightDelim = "]";
63186        break;
63187      default:
63188        throw new Error("Unrecognized genfrac command");
63189    }
63190    switch (funcName) {
63191      case "\\dfrac":
63192      case "\\dbinom":
63193        size = "display";
63194        break;
63195      case "\\tfrac":
63196      case "\\tbinom":
63197        size = "text";
63198        break;
63199    }
63200    return {
63201      type: "genfrac",
63202      mode: parser2.mode,
63203      continued: false,
63204      numer,
63205      denom,
63206      hasBarLine,
63207      leftDelim,
63208      rightDelim,
63209      size,
63210      barSize: null
63211    };
63212  },
63213  htmlBuilder: htmlBuilder$4,
63214  mathmlBuilder: mathmlBuilder$3
63215});
63216defineFunction({
63217  type: "genfrac",
63218  names: ["\\cfrac"],
63219  props: {
63220    numArgs: 2
63221  },
63222  handler: (_ref2, args) => {
63223    var {
63224      parser: parser2,
63225      funcName
63226    } = _ref2;
63227    var numer = args[0];
63228    var denom = args[1];
63229    return {
63230      type: "genfrac",
63231      mode: parser2.mode,
63232      continued: true,
63233      numer,
63234      denom,
63235      hasBarLine: true,
63236      leftDelim: null,
63237      rightDelim: null,
63238      size: "display",
63239      barSize: null
63240    };
63241  }
63242});
63243defineFunction({
63244  type: "infix",
63245  names: ["\\over", "\\choose", "\\atop", "\\brace", "\\brack"],
63246  props: {
63247    numArgs: 0,
63248    infix: true
63249  },
63250  handler(_ref3) {
63251    var {
63252      parser: parser2,
63253      funcName,
63254      token
63255    } = _ref3;
63256    var replaceWith;
63257    switch (funcName) {
63258      case "\\over":
63259        replaceWith = "\\frac";
63260        break;
63261      case "\\choose":
63262        replaceWith = "\\binom";
63263        break;
63264      case "\\atop":
63265        replaceWith = "\\\\atopfrac";
63266        break;
63267      case "\\brace":
63268        replaceWith = "\\\\bracefrac";
63269        break;
63270      case "\\brack":
63271        replaceWith = "\\\\brackfrac";
63272        break;
63273      default:
63274        throw new Error("Unrecognized infix genfrac command");
63275    }
63276    return {
63277      type: "infix",
63278      mode: parser2.mode,
63279      replaceWith,
63280      token
63281    };
63282  }
63283});
63284var stylArray = ["display", "text", "script", "scriptscript"];
63285var delimFromValue = function delimFromValue2(delimString) {
63286  var delim = null;
63287  if (delimString.length > 0) {
63288    delim = delimString;
63289    delim = delim === "." ? null : delim;
63290  }
63291  return delim;
63292};
63293defineFunction({
63294  type: "genfrac",
63295  names: ["\\genfrac"],
63296  props: {
63297    numArgs: 6,
63298    allowedInArgument: true,
63299    argTypes: ["math", "math", "size", "text", "math", "math"]
63300  },
63301  handler(_ref4, args) {
63302    var {
63303      parser: parser2
63304    } = _ref4;
63305    var numer = args[4];
63306    var denom = args[5];
63307    var leftNode = normalizeArgument(args[0]);
63308    var leftDelim = leftNode.type === "atom" && leftNode.family === "open" ? delimFromValue(leftNode.text) : null;
63309    var rightNode = normalizeArgument(args[1]);
63310    var rightDelim = rightNode.type === "atom" && rightNode.family === "close" ? delimFromValue(rightNode.text) : null;
63311    var barNode = assertNodeType(args[2], "size");
63312    var hasBarLine;
63313    var barSize = null;
63314    if (barNode.isBlank) {
63315      hasBarLine = true;
63316    } else {
63317      barSize = barNode.value;
63318      hasBarLine = barSize.number > 0;
63319    }
63320    var size = "auto";
63321    var styl = args[3];
63322    if (styl.type === "ordgroup") {
63323      if (styl.body.length > 0) {
63324        var textOrd = assertNodeType(styl.body[0], "textord");
63325        size = stylArray[Number(textOrd.text)];
63326      }
63327    } else {
63328      styl = assertNodeType(styl, "textord");
63329      size = stylArray[Number(styl.text)];
63330    }
63331    return {
63332      type: "genfrac",
63333      mode: parser2.mode,
63334      numer,
63335      denom,
63336      continued: false,
63337      hasBarLine,
63338      barSize,
63339      leftDelim,
63340      rightDelim,
63341      size
63342    };
63343  },
63344  htmlBuilder: htmlBuilder$4,
63345  mathmlBuilder: mathmlBuilder$3
63346});
63347defineFunction({
63348  type: "infix",
63349  names: ["\\above"],
63350  props: {
63351    numArgs: 1,
63352    argTypes: ["size"],
63353    infix: true
63354  },
63355  handler(_ref5, args) {
63356    var {
63357      parser: parser2,
63358      funcName,
63359      token
63360    } = _ref5;
63361    return {
63362      type: "infix",
63363      mode: parser2.mode,
63364      replaceWith: "\\\\abovefrac",
63365      size: assertNodeType(args[0], "size").value,
63366      token
63367    };
63368  }
63369});
63370defineFunction({
63371  type: "genfrac",
63372  names: ["\\\\abovefrac"],
63373  props: {
63374    numArgs: 3,
63375    argTypes: ["math", "size", "math"]
63376  },
63377  handler: (_ref6, args) => {
63378    var {
63379      parser: parser2,
63380      funcName
63381    } = _ref6;
63382    var numer = args[0];
63383    var barSize = assert(assertNodeType(args[1], "infix").size);
63384    var denom = args[2];
63385    var hasBarLine = barSize.number > 0;
63386    return {
63387      type: "genfrac",
63388      mode: parser2.mode,
63389      numer,
63390      denom,
63391      continued: false,
63392      hasBarLine,
63393      barSize,
63394      leftDelim: null,
63395      rightDelim: null,
63396      size: "auto"
63397    };
63398  },
63399  htmlBuilder: htmlBuilder$4,
63400  mathmlBuilder: mathmlBuilder$3
63401});
63402var htmlBuilder$3 = (grp, options2) => {
63403  var style = options2.style;
63404  var supSubGroup;
63405  var group;
63406  if (grp.type === "supsub") {
63407    supSubGroup = grp.sup ? buildGroup$1(grp.sup, options2.havingStyle(style.sup()), options2) : buildGroup$1(grp.sub, options2.havingStyle(style.sub()), options2);
63408    group = assertNodeType(grp.base, "horizBrace");
63409  } else {
63410    group = assertNodeType(grp, "horizBrace");
63411  }
63412  var body = buildGroup$1(group.base, options2.havingBaseStyle(Style$1.DISPLAY));
63413  var braceBody = stretchy.svgSpan(group, options2);
63414  var vlist;
63415  if (group.isOver) {
63416    vlist = buildCommon.makeVList({
63417      positionType: "firstBaseline",
63418      children: [{
63419        type: "elem",
63420        elem: body
63421      }, {
63422        type: "kern",
63423        size: 0.1
63424      }, {
63425        type: "elem",
63426        elem: braceBody
63427      }]
63428    }, options2);
63429    vlist.children[0].children[0].children[1].classes.push("svg-align");
63430  } else {
63431    vlist = buildCommon.makeVList({
63432      positionType: "bottom",
63433      positionData: body.depth + 0.1 + braceBody.height,
63434      children: [{
63435        type: "elem",
63436        elem: braceBody
63437      }, {
63438        type: "kern",
63439        size: 0.1
63440      }, {
63441        type: "elem",
63442        elem: body
63443      }]
63444    }, options2);
63445    vlist.children[0].children[0].children[0].classes.push("svg-align");
63446  }
63447  if (supSubGroup) {
63448    var vSpan = buildCommon.makeSpan(["mord", group.isOver ? "mover" : "munder"], [vlist], options2);
63449    if (group.isOver) {
63450      vlist = buildCommon.makeVList({
63451        positionType: "firstBaseline",
63452        children: [{
63453          type: "elem",
63454          elem: vSpan
63455        }, {
63456          type: "kern",
63457          size: 0.2
63458        }, {
63459          type: "elem",
63460          elem: supSubGroup
63461        }]
63462      }, options2);
63463    } else {
63464      vlist = buildCommon.makeVList({
63465        positionType: "bottom",
63466        positionData: vSpan.depth + 0.2 + supSubGroup.height + supSubGroup.depth,
63467        children: [{
63468          type: "elem",
63469          elem: supSubGroup
63470        }, {
63471          type: "kern",
63472          size: 0.2
63473        }, {
63474          type: "elem",
63475          elem: vSpan
63476        }]
63477      }, options2);
63478    }
63479  }
63480  return buildCommon.makeSpan(["mord", group.isOver ? "mover" : "munder"], [vlist], options2);
63481};
63482var mathmlBuilder$2 = (group, options2) => {
63483  var accentNode = stretchy.mathMLnode(group.label);
63484  return new mathMLTree.MathNode(group.isOver ? "mover" : "munder", [buildGroup2(group.base, options2), accentNode]);
63485};
63486defineFunction({
63487  type: "horizBrace",
63488  names: ["\\overbrace", "\\underbrace"],
63489  props: {
63490    numArgs: 1
63491  },
63492  handler(_ref, args) {
63493    var {
63494      parser: parser2,
63495      funcName
63496    } = _ref;
63497    return {
63498      type: "horizBrace",
63499      mode: parser2.mode,
63500      label: funcName,
63501      isOver: /^\\over/.test(funcName),
63502      base: args[0]
63503    };
63504  },
63505  htmlBuilder: htmlBuilder$3,
63506  mathmlBuilder: mathmlBuilder$2
63507});
63508defineFunction({
63509  type: "href",
63510  names: ["\\href"],
63511  props: {
63512    numArgs: 2,
63513    argTypes: ["url", "original"],
63514    allowedInText: true
63515  },
63516  handler: (_ref, args) => {
63517    var {
63518      parser: parser2
63519    } = _ref;
63520    var body = args[1];
63521    var href = assertNodeType(args[0], "url").url;
63522    if (!parser2.settings.isTrusted({
63523      command: "\\href",
63524      url: href
63525    })) {
63526      return parser2.formatUnsupportedCmd("\\href");
63527    }
63528    return {
63529      type: "href",
63530      mode: parser2.mode,
63531      href,
63532      body: ordargument(body)
63533    };
63534  },
63535  htmlBuilder: (group, options2) => {
63536    var elements = buildExpression$1(group.body, options2, false);
63537    return buildCommon.makeAnchor(group.href, [], elements, options2);
63538  },
63539  mathmlBuilder: (group, options2) => {
63540    var math2 = buildExpressionRow(group.body, options2);
63541    if (!(math2 instanceof MathNode)) {
63542      math2 = new MathNode("mrow", [math2]);
63543    }
63544    math2.setAttribute("href", group.href);
63545    return math2;
63546  }
63547});
63548defineFunction({
63549  type: "href",
63550  names: ["\\url"],
63551  props: {
63552    numArgs: 1,
63553    argTypes: ["url"],
63554    allowedInText: true
63555  },
63556  handler: (_ref2, args) => {
63557    var {
63558      parser: parser2
63559    } = _ref2;
63560    var href = assertNodeType(args[0], "url").url;
63561    if (!parser2.settings.isTrusted({
63562      command: "\\url",
63563      url: href
63564    })) {
63565      return parser2.formatUnsupportedCmd("\\url");
63566    }
63567    var chars = [];
63568    for (var i = 0; i < href.length; i++) {
63569      var c = href[i];
63570      if (c === "~") {
63571        c = "\\textasciitilde";
63572      }
63573      chars.push({
63574        type: "textord",
63575        mode: "text",
63576        text: c
63577      });
63578    }
63579    var body = {
63580      type: "text",
63581      mode: parser2.mode,
63582      font: "\\texttt",
63583      body: chars
63584    };
63585    return {
63586      type: "href",
63587      mode: parser2.mode,
63588      href,
63589      body: ordargument(body)
63590    };
63591  }
63592});
63593defineFunction({
63594  type: "hbox",
63595  names: ["\\hbox"],
63596  props: {
63597    numArgs: 1,
63598    argTypes: ["text"],
63599    allowedInText: true,
63600    primitive: true
63601  },
63602  handler(_ref, args) {
63603    var {
63604      parser: parser2
63605    } = _ref;
63606    return {
63607      type: "hbox",
63608      mode: parser2.mode,
63609      body: ordargument(args[0])
63610    };
63611  },
63612  htmlBuilder(group, options2) {
63613    var elements = buildExpression$1(group.body, options2, false);
63614    return buildCommon.makeFragment(elements);
63615  },
63616  mathmlBuilder(group, options2) {
63617    return new mathMLTree.MathNode("mrow", buildExpression2(group.body, options2));
63618  }
63619});
63620defineFunction({
63621  type: "html",
63622  names: ["\\htmlClass", "\\htmlId", "\\htmlStyle", "\\htmlData"],
63623  props: {
63624    numArgs: 2,
63625    argTypes: ["raw", "original"],
63626    allowedInText: true
63627  },
63628  handler: (_ref, args) => {
63629    var {
63630      parser: parser2,
63631      funcName,
63632      token
63633    } = _ref;
63634    var value = assertNodeType(args[0], "raw").string;
63635    var body = args[1];
63636    if (parser2.settings.strict) {
63637      parser2.settings.reportNonstrict("htmlExtension", "HTML extension is disabled on strict mode");
63638    }
63639    var trustContext;
63640    var attributes = {};
63641    switch (funcName) {
63642      case "\\htmlClass":
63643        attributes.class = value;
63644        trustContext = {
63645          command: "\\htmlClass",
63646          class: value
63647        };
63648        break;
63649      case "\\htmlId":
63650        attributes.id = value;
63651        trustContext = {
63652          command: "\\htmlId",
63653          id: value
63654        };
63655        break;
63656      case "\\htmlStyle":
63657        attributes.style = value;
63658        trustContext = {
63659          command: "\\htmlStyle",
63660          style: value
63661        };
63662        break;
63663      case "\\htmlData": {
63664        var data = value.split(",");
63665        for (var i = 0; i < data.length; i++) {
63666          var keyVal = data[i].split("=");
63667          if (keyVal.length !== 2) {
63668            throw new ParseError("Error parsing key-value for \\htmlData");
63669          }
63670          attributes["data-" + keyVal[0].trim()] = keyVal[1].trim();
63671        }
63672        trustContext = {
63673          command: "\\htmlData",
63674          attributes
63675        };
63676        break;
63677      }
63678      default:
63679        throw new Error("Unrecognized html command");
63680    }
63681    if (!parser2.settings.isTrusted(trustContext)) {
63682      return parser2.formatUnsupportedCmd(funcName);
63683    }
63684    return {
63685      type: "html",
63686      mode: parser2.mode,
63687      attributes,
63688      body: ordargument(body)
63689    };
63690  },
63691  htmlBuilder: (group, options2) => {
63692    var elements = buildExpression$1(group.body, options2, false);
63693    var classes2 = ["enclosing"];
63694    if (group.attributes.class) {
63695      classes2.push(...group.attributes.class.trim().split(/\s+/));
63696    }
63697    var span = buildCommon.makeSpan(classes2, elements, options2);
63698    for (var attr in group.attributes) {
63699      if (attr !== "class" && group.attributes.hasOwnProperty(attr)) {
63700        span.setAttribute(attr, group.attributes[attr]);
63701      }
63702    }
63703    return span;
63704  },
63705  mathmlBuilder: (group, options2) => {
63706    return buildExpressionRow(group.body, options2);
63707  }
63708});
63709defineFunction({
63710  type: "htmlmathml",
63711  names: ["\\html@mathml"],
63712  props: {
63713    numArgs: 2,
63714    allowedInText: true
63715  },
63716  handler: (_ref, args) => {
63717    var {
63718      parser: parser2
63719    } = _ref;
63720    return {
63721      type: "htmlmathml",
63722      mode: parser2.mode,
63723      html: ordargument(args[0]),
63724      mathml: ordargument(args[1])
63725    };
63726  },
63727  htmlBuilder: (group, options2) => {
63728    var elements = buildExpression$1(group.html, options2, false);
63729    return buildCommon.makeFragment(elements);
63730  },
63731  mathmlBuilder: (group, options2) => {
63732    return buildExpressionRow(group.mathml, options2);
63733  }
63734});
63735var sizeData = function sizeData2(str) {
63736  if (/^[-+]? *(\d+(\.\d*)?|\.\d+)$/.test(str)) {
63737    return {
63738      number: +str,
63739      unit: "bp"
63740    };
63741  } else {
63742    var match = /([-+]?) *(\d+(?:\.\d*)?|\.\d+) *([a-z]{2})/.exec(str);
63743    if (!match) {
63744      throw new ParseError("Invalid size: '" + str + "' in \\includegraphics");
63745    }
63746    var data = {
63747      number: +(match[1] + match[2]),
63748      // sign + magnitude, cast to number
63749      unit: match[3]
63750    };
63751    if (!validUnit(data)) {
63752      throw new ParseError("Invalid unit: '" + data.unit + "' in \\includegraphics.");
63753    }
63754    return data;
63755  }
63756};
63757defineFunction({
63758  type: "includegraphics",
63759  names: ["\\includegraphics"],
63760  props: {
63761    numArgs: 1,
63762    numOptionalArgs: 1,
63763    argTypes: ["raw", "url"],
63764    allowedInText: false
63765  },
63766  handler: (_ref, args, optArgs) => {
63767    var {
63768      parser: parser2
63769    } = _ref;
63770    var width = {
63771      number: 0,
63772      unit: "em"
63773    };
63774    var height = {
63775      number: 0.9,
63776      unit: "em"
63777    };
63778    var totalheight = {
63779      number: 0,
63780      unit: "em"
63781    };
63782    var alt = "";
63783    if (optArgs[0]) {
63784      var attributeStr = assertNodeType(optArgs[0], "raw").string;
63785      var attributes = attributeStr.split(",");
63786      for (var i = 0; i < attributes.length; i++) {
63787        var keyVal = attributes[i].split("=");
63788        if (keyVal.length === 2) {
63789          var str = keyVal[1].trim();
63790          switch (keyVal[0].trim()) {
63791            case "alt":
63792              alt = str;
63793              break;
63794            case "width":
63795              width = sizeData(str);
63796              break;
63797            case "height":
63798              height = sizeData(str);
63799              break;
63800            case "totalheight":
63801              totalheight = sizeData(str);
63802              break;
63803            default:
63804              throw new ParseError("Invalid key: '" + keyVal[0] + "' in \\includegraphics.");
63805          }
63806        }
63807      }
63808    }
63809    var src = assertNodeType(args[0], "url").url;
63810    if (alt === "") {
63811      alt = src;
63812      alt = alt.replace(/^.*[\\/]/, "");
63813      alt = alt.substring(0, alt.lastIndexOf("."));
63814    }
63815    if (!parser2.settings.isTrusted({
63816      command: "\\includegraphics",
63817      url: src
63818    })) {
63819      return parser2.formatUnsupportedCmd("\\includegraphics");
63820    }
63821    return {
63822      type: "includegraphics",
63823      mode: parser2.mode,
63824      alt,
63825      width,
63826      height,
63827      totalheight,
63828      src
63829    };
63830  },
63831  htmlBuilder: (group, options2) => {
63832    var height = calculateSize(group.height, options2);
63833    var depth = 0;
63834    if (group.totalheight.number > 0) {
63835      depth = calculateSize(group.totalheight, options2) - height;
63836    }
63837    var width = 0;
63838    if (group.width.number > 0) {
63839      width = calculateSize(group.width, options2);
63840    }
63841    var style = {
63842      height: makeEm(height + depth)
63843    };
63844    if (width > 0) {
63845      style.width = makeEm(width);
63846    }
63847    if (depth > 0) {
63848      style.verticalAlign = makeEm(-depth);
63849    }
63850    var node = new Img(group.src, group.alt, style);
63851    node.height = height;
63852    node.depth = depth;
63853    return node;
63854  },
63855  mathmlBuilder: (group, options2) => {
63856    var node = new mathMLTree.MathNode("mglyph", []);
63857    node.setAttribute("alt", group.alt);
63858    var height = calculateSize(group.height, options2);
63859    var depth = 0;
63860    if (group.totalheight.number > 0) {
63861      depth = calculateSize(group.totalheight, options2) - height;
63862      node.setAttribute("valign", makeEm(-depth));
63863    }
63864    node.setAttribute("height", makeEm(height + depth));
63865    if (group.width.number > 0) {
63866      var width = calculateSize(group.width, options2);
63867      node.setAttribute("width", makeEm(width));
63868    }
63869    node.setAttribute("src", group.src);
63870    return node;
63871  }
63872});
63873defineFunction({
63874  type: "kern",
63875  names: ["\\kern", "\\mkern", "\\hskip", "\\mskip"],
63876  props: {
63877    numArgs: 1,
63878    argTypes: ["size"],
63879    primitive: true,
63880    allowedInText: true
63881  },
63882  handler(_ref, args) {
63883    var {
63884      parser: parser2,
63885      funcName
63886    } = _ref;
63887    var size = assertNodeType(args[0], "size");
63888    if (parser2.settings.strict) {
63889      var mathFunction = funcName[1] === "m";
63890      var muUnit = size.value.unit === "mu";
63891      if (mathFunction) {
63892        if (!muUnit) {
63893          parser2.settings.reportNonstrict("mathVsTextUnits", "LaTeX's " + funcName + " supports only mu units, " + ("not " + size.value.unit + " units"));
63894        }
63895        if (parser2.mode !== "math") {
63896          parser2.settings.reportNonstrict("mathVsTextUnits", "LaTeX's " + funcName + " works only in math mode");
63897        }
63898      } else {
63899        if (muUnit) {
63900          parser2.settings.reportNonstrict("mathVsTextUnits", "LaTeX's " + funcName + " doesn't support mu units");
63901        }
63902      }
63903    }
63904    return {
63905      type: "kern",
63906      mode: parser2.mode,
63907      dimension: size.value
63908    };
63909  },
63910  htmlBuilder(group, options2) {
63911    return buildCommon.makeGlue(group.dimension, options2);
63912  },
63913  mathmlBuilder(group, options2) {
63914    var dimension = calculateSize(group.dimension, options2);
63915    return new mathMLTree.SpaceNode(dimension);
63916  }
63917});
63918defineFunction({
63919  type: "lap",
63920  names: ["\\mathllap", "\\mathrlap", "\\mathclap"],
63921  props: {
63922    numArgs: 1,
63923    allowedInText: true
63924  },
63925  handler: (_ref, args) => {
63926    var {
63927      parser: parser2,
63928      funcName
63929    } = _ref;
63930    var body = args[0];
63931    return {
63932      type: "lap",
63933      mode: parser2.mode,
63934      alignment: funcName.slice(5),
63935      body
63936    };
63937  },
63938  htmlBuilder: (group, options2) => {
63939    var inner2;
63940    if (group.alignment === "clap") {
63941      inner2 = buildCommon.makeSpan([], [buildGroup$1(group.body, options2)]);
63942      inner2 = buildCommon.makeSpan(["inner"], [inner2], options2);
63943    } else {
63944      inner2 = buildCommon.makeSpan(["inner"], [buildGroup$1(group.body, options2)]);
63945    }
63946    var fix = buildCommon.makeSpan(["fix"], []);
63947    var node = buildCommon.makeSpan([group.alignment], [inner2, fix], options2);
63948    var strut = buildCommon.makeSpan(["strut"]);
63949    strut.style.height = makeEm(node.height + node.depth);
63950    if (node.depth) {
63951      strut.style.verticalAlign = makeEm(-node.depth);
63952    }
63953    node.children.unshift(strut);
63954    node = buildCommon.makeSpan(["thinbox"], [node], options2);
63955    return buildCommon.makeSpan(["mord", "vbox"], [node], options2);
63956  },
63957  mathmlBuilder: (group, options2) => {
63958    var node = new mathMLTree.MathNode("mpadded", [buildGroup2(group.body, options2)]);
63959    if (group.alignment !== "rlap") {
63960      var offset = group.alignment === "llap" ? "-1" : "-0.5";
63961      node.setAttribute("lspace", offset + "width");
63962    }
63963    node.setAttribute("width", "0px");
63964    return node;
63965  }
63966});
63967defineFunction({
63968  type: "styling",
63969  names: ["\\(", "$"],
63970  props: {
63971    numArgs: 0,
63972    allowedInText: true,
63973    allowedInMath: false
63974  },
63975  handler(_ref, args) {
63976    var {
63977      funcName,
63978      parser: parser2
63979    } = _ref;
63980    var outerMode = parser2.mode;
63981    parser2.switchMode("math");
63982    var close2 = funcName === "\\(" ? "\\)" : "$";
63983    var body = parser2.parseExpression(false, close2);
63984    parser2.expect(close2);
63985    parser2.switchMode(outerMode);
63986    return {
63987      type: "styling",
63988      mode: parser2.mode,
63989      style: "text",
63990      body
63991    };
63992  }
63993});
63994defineFunction({
63995  type: "text",
63996  // Doesn't matter what this is.
63997  names: ["\\)", "\\]"],
63998  props: {
63999    numArgs: 0,
64000    allowedInText: true,
64001    allowedInMath: false
64002  },
64003  handler(context, args) {
64004    throw new ParseError("Mismatched " + context.funcName);
64005  }
64006});
64007var chooseMathStyle = (group, options2) => {
64008  switch (options2.style.size) {
64009    case Style$1.DISPLAY.size:
64010      return group.display;
64011    case Style$1.TEXT.size:
64012      return group.text;
64013    case Style$1.SCRIPT.size:
64014      return group.script;
64015    case Style$1.SCRIPTSCRIPT.size:
64016      return group.scriptscript;
64017    default:
64018      return group.text;
64019  }
64020};
64021defineFunction({
64022  type: "mathchoice",
64023  names: ["\\mathchoice"],
64024  props: {
64025    numArgs: 4,
64026    primitive: true
64027  },
64028  handler: (_ref, args) => {
64029    var {
64030      parser: parser2
64031    } = _ref;
64032    return {
64033      type: "mathchoice",
64034      mode: parser2.mode,
64035      display: ordargument(args[0]),
64036      text: ordargument(args[1]),
64037      script: ordargument(args[2]),
64038      scriptscript: ordargument(args[3])
64039    };
64040  },
64041  htmlBuilder: (group, options2) => {
64042    var body = chooseMathStyle(group, options2);
64043    var elements = buildExpression$1(body, options2, false);
64044    return buildCommon.makeFragment(elements);
64045  },
64046  mathmlBuilder: (group, options2) => {
64047    var body = chooseMathStyle(group, options2);
64048    return buildExpressionRow(body, options2);
64049  }
64050});
64051var assembleSupSub = (base, supGroup, subGroup, options2, style, slant, baseShift) => {
64052  base = buildCommon.makeSpan([], [base]);
64053  var subIsSingleCharacter = subGroup && utils.isCharacterBox(subGroup);
64054  var sub2;
64055  var sup2;
64056  if (supGroup) {
64057    var elem = buildGroup$1(supGroup, options2.havingStyle(style.sup()), options2);
64058    sup2 = {
64059      elem,
64060      kern: Math.max(options2.fontMetrics().bigOpSpacing1, options2.fontMetrics().bigOpSpacing3 - elem.depth)
64061    };
64062  }
64063  if (subGroup) {
64064    var _elem = buildGroup$1(subGroup, options2.havingStyle(style.sub()), options2);
64065    sub2 = {
64066      elem: _elem,
64067      kern: Math.max(options2.fontMetrics().bigOpSpacing2, options2.fontMetrics().bigOpSpacing4 - _elem.height)
64068    };
64069  }
64070  var finalGroup;
64071  if (sup2 && sub2) {
64072    var bottom = options2.fontMetrics().bigOpSpacing5 + sub2.elem.height + sub2.elem.depth + sub2.kern + base.depth + baseShift;
64073    finalGroup = buildCommon.makeVList({
64074      positionType: "bottom",
64075      positionData: bottom,
64076      children: [{
64077        type: "kern",
64078        size: options2.fontMetrics().bigOpSpacing5
64079      }, {
64080        type: "elem",
64081        elem: sub2.elem,
64082        marginLeft: makeEm(-slant)
64083      }, {
64084        type: "kern",
64085        size: sub2.kern
64086      }, {
64087        type: "elem",
64088        elem: base
64089      }, {
64090        type: "kern",
64091        size: sup2.kern
64092      }, {
64093        type: "elem",
64094        elem: sup2.elem,
64095        marginLeft: makeEm(slant)
64096      }, {
64097        type: "kern",
64098        size: options2.fontMetrics().bigOpSpacing5
64099      }]
64100    }, options2);
64101  } else if (sub2) {
64102    var top = base.height - baseShift;
64103    finalGroup = buildCommon.makeVList({
64104      positionType: "top",
64105      positionData: top,
64106      children: [{
64107        type: "kern",
64108        size: options2.fontMetrics().bigOpSpacing5
64109      }, {
64110        type: "elem",
64111        elem: sub2.elem,
64112        marginLeft: makeEm(-slant)
64113      }, {
64114        type: "kern",
64115        size: sub2.kern
64116      }, {
64117        type: "elem",
64118        elem: base
64119      }]
64120    }, options2);
64121  } else if (sup2) {
64122    var _bottom = base.depth + baseShift;
64123    finalGroup = buildCommon.makeVList({
64124      positionType: "bottom",
64125      positionData: _bottom,
64126      children: [{
64127        type: "elem",
64128        elem: base
64129      }, {
64130        type: "kern",
64131        size: sup2.kern
64132      }, {
64133        type: "elem",
64134        elem: sup2.elem,
64135        marginLeft: makeEm(slant)
64136      }, {
64137        type: "kern",
64138        size: options2.fontMetrics().bigOpSpacing5
64139      }]
64140    }, options2);
64141  } else {
64142    return base;
64143  }
64144  var parts = [finalGroup];
64145  if (sub2 && slant !== 0 && !subIsSingleCharacter) {
64146    var spacer = buildCommon.makeSpan(["mspace"], [], options2);
64147    spacer.style.marginRight = makeEm(slant);
64148    parts.unshift(spacer);
64149  }
64150  return buildCommon.makeSpan(["mop", "op-limits"], parts, options2);
64151};
64152var noSuccessor = ["\\smallint"];
64153var htmlBuilder$2 = (grp, options2) => {
64154  var supGroup;
64155  var subGroup;
64156  var hasLimits = false;
64157  var group;
64158  if (grp.type === "supsub") {
64159    supGroup = grp.sup;
64160    subGroup = grp.sub;
64161    group = assertNodeType(grp.base, "op");
64162    hasLimits = true;
64163  } else {
64164    group = assertNodeType(grp, "op");
64165  }
64166  var style = options2.style;
64167  var large = false;
64168  if (style.size === Style$1.DISPLAY.size && group.symbol && !utils.contains(noSuccessor, group.name)) {
64169    large = true;
64170  }
64171  var base;
64172  if (group.symbol) {
64173    var fontName = large ? "Size2-Regular" : "Size1-Regular";
64174    var stash = "";
64175    if (group.name === "\\oiint" || group.name === "\\oiiint") {
64176      stash = group.name.slice(1);
64177      group.name = stash === "oiint" ? "\\iint" : "\\iiint";
64178    }
64179    base = buildCommon.makeSymbol(group.name, fontName, "math", options2, ["mop", "op-symbol", large ? "large-op" : "small-op"]);
64180    if (stash.length > 0) {
64181      var italic = base.italic;
64182      var oval = buildCommon.staticSvg(stash + "Size" + (large ? "2" : "1"), options2);
64183      base = buildCommon.makeVList({
64184        positionType: "individualShift",
64185        children: [{
64186          type: "elem",
64187          elem: base,
64188          shift: 0
64189        }, {
64190          type: "elem",
64191          elem: oval,
64192          shift: large ? 0.08 : 0
64193        }]
64194      }, options2);
64195      group.name = "\\" + stash;
64196      base.classes.unshift("mop");
64197      base.italic = italic;
64198    }
64199  } else if (group.body) {
64200    var inner2 = buildExpression$1(group.body, options2, true);
64201    if (inner2.length === 1 && inner2[0] instanceof SymbolNode) {
64202      base = inner2[0];
64203      base.classes[0] = "mop";
64204    } else {
64205      base = buildCommon.makeSpan(["mop"], inner2, options2);
64206    }
64207  } else {
64208    var output = [];
64209    for (var i = 1; i < group.name.length; i++) {
64210      output.push(buildCommon.mathsym(group.name[i], group.mode, options2));
64211    }
64212    base = buildCommon.makeSpan(["mop"], output, options2);
64213  }
64214  var baseShift = 0;
64215  var slant = 0;
64216  if ((base instanceof SymbolNode || group.name === "\\oiint" || group.name === "\\oiiint") && !group.suppressBaseShift) {
64217    baseShift = (base.height - base.depth) / 2 - options2.fontMetrics().axisHeight;
64218    slant = base.italic;
64219  }
64220  if (hasLimits) {
64221    return assembleSupSub(base, supGroup, subGroup, options2, style, slant, baseShift);
64222  } else {
64223    if (baseShift) {
64224      base.style.position = "relative";
64225      base.style.top = makeEm(baseShift);
64226    }
64227    return base;
64228  }
64229};
64230var mathmlBuilder$1 = (group, options2) => {
64231  var node;
64232  if (group.symbol) {
64233    node = new MathNode("mo", [makeText(group.name, group.mode)]);
64234    if (utils.contains(noSuccessor, group.name)) {
64235      node.setAttribute("largeop", "false");
64236    }
64237  } else if (group.body) {
64238    node = new MathNode("mo", buildExpression2(group.body, options2));
64239  } else {
64240    node = new MathNode("mi", [new TextNode(group.name.slice(1))]);
64241    var operator = new MathNode("mo", [makeText("\u2061", "text")]);
64242    if (group.parentIsSupSub) {
64243      node = new MathNode("mrow", [node, operator]);
64244    } else {
64245      node = newDocumentFragment([node, operator]);
64246    }
64247  }
64248  return node;
64249};
64250var singleCharBigOps = {
64251  "\u220F": "\\prod",
64252  "\u2210": "\\coprod",
64253  "\u2211": "\\sum",
64254  "\u22C0": "\\bigwedge",
64255  "\u22C1": "\\bigvee",
64256  "\u22C2": "\\bigcap",
64257  "\u22C3": "\\bigcup",
64258  "\u2A00": "\\bigodot",
64259  "\u2A01": "\\bigoplus",
64260  "\u2A02": "\\bigotimes",
64261  "\u2A04": "\\biguplus",
64262  "\u2A06": "\\bigsqcup"
64263};
64264defineFunction({
64265  type: "op",
64266  names: ["\\coprod", "\\bigvee", "\\bigwedge", "\\biguplus", "\\bigcap", "\\bigcup", "\\intop", "\\prod", "\\sum", "\\bigotimes", "\\bigoplus", "\\bigodot", "\\bigsqcup", "\\smallint", "\u220F", "\u2210", "\u2211", "\u22C0", "\u22C1", "\u22C2", "\u22C3", "\u2A00", "\u2A01", "\u2A02", "\u2A04", "\u2A06"],
64267  props: {
64268    numArgs: 0
64269  },
64270  handler: (_ref, args) => {
64271    var {
64272      parser: parser2,
64273      funcName
64274    } = _ref;
64275    var fName = funcName;
64276    if (fName.length === 1) {
64277      fName = singleCharBigOps[fName];
64278    }
64279    return {
64280      type: "op",
64281      mode: parser2.mode,
64282      limits: true,
64283      parentIsSupSub: false,
64284      symbol: true,
64285      name: fName
64286    };
64287  },
64288  htmlBuilder: htmlBuilder$2,
64289  mathmlBuilder: mathmlBuilder$1
64290});
64291defineFunction({
64292  type: "op",
64293  names: ["\\mathop"],
64294  props: {
64295    numArgs: 1,
64296    primitive: true
64297  },
64298  handler: (_ref2, args) => {
64299    var {
64300      parser: parser2
64301    } = _ref2;
64302    var body = args[0];
64303    return {
64304      type: "op",
64305      mode: parser2.mode,
64306      limits: false,
64307      parentIsSupSub: false,
64308      symbol: false,
64309      body: ordargument(body)
64310    };
64311  },
64312  htmlBuilder: htmlBuilder$2,
64313  mathmlBuilder: mathmlBuilder$1
64314});
64315var singleCharIntegrals = {
64316  "\u222B": "\\int",
64317  "\u222C": "\\iint",
64318  "\u222D": "\\iiint",
64319  "\u222E": "\\oint",
64320  "\u222F": "\\oiint",
64321  "\u2230": "\\oiiint"
64322};
64323defineFunction({
64324  type: "op",
64325  names: ["\\arcsin", "\\arccos", "\\arctan", "\\arctg", "\\arcctg", "\\arg", "\\ch", "\\cos", "\\cosec", "\\cosh", "\\cot", "\\cotg", "\\coth", "\\csc", "\\ctg", "\\cth", "\\deg", "\\dim", "\\exp", "\\hom", "\\ker", "\\lg", "\\ln", "\\log", "\\sec", "\\sin", "\\sinh", "\\sh", "\\tan", "\\tanh", "\\tg", "\\th"],
64326  props: {
64327    numArgs: 0
64328  },
64329  handler(_ref3) {
64330    var {
64331      parser: parser2,
64332      funcName
64333    } = _ref3;
64334    return {
64335      type: "op",
64336      mode: parser2.mode,
64337      limits: false,
64338      parentIsSupSub: false,
64339      symbol: false,
64340      name: funcName
64341    };
64342  },
64343  htmlBuilder: htmlBuilder$2,
64344  mathmlBuilder: mathmlBuilder$1
64345});
64346defineFunction({
64347  type: "op",
64348  names: ["\\det", "\\gcd", "\\inf", "\\lim", "\\max", "\\min", "\\Pr", "\\sup"],
64349  props: {
64350    numArgs: 0
64351  },
64352  handler(_ref4) {
64353    var {
64354      parser: parser2,
64355      funcName
64356    } = _ref4;
64357    return {
64358      type: "op",
64359      mode: parser2.mode,
64360      limits: true,
64361      parentIsSupSub: false,
64362      symbol: false,
64363      name: funcName
64364    };
64365  },
64366  htmlBuilder: htmlBuilder$2,
64367  mathmlBuilder: mathmlBuilder$1
64368});
64369defineFunction({
64370  type: "op",
64371  names: ["\\int", "\\iint", "\\iiint", "\\oint", "\\oiint", "\\oiiint", "\u222B", "\u222C", "\u222D", "\u222E", "\u222F", "\u2230"],
64372  props: {
64373    numArgs: 0
64374  },
64375  handler(_ref5) {
64376    var {
64377      parser: parser2,
64378      funcName
64379    } = _ref5;
64380    var fName = funcName;
64381    if (fName.length === 1) {
64382      fName = singleCharIntegrals[fName];
64383    }
64384    return {
64385      type: "op",
64386      mode: parser2.mode,
64387      limits: false,
64388      parentIsSupSub: false,
64389      symbol: true,
64390      name: fName
64391    };
64392  },
64393  htmlBuilder: htmlBuilder$2,
64394  mathmlBuilder: mathmlBuilder$1
64395});
64396var htmlBuilder$1 = (grp, options2) => {
64397  var supGroup;
64398  var subGroup;
64399  var hasLimits = false;
64400  var group;
64401  if (grp.type === "supsub") {
64402    supGroup = grp.sup;
64403    subGroup = grp.sub;
64404    group = assertNodeType(grp.base, "operatorname");
64405    hasLimits = true;
64406  } else {
64407    group = assertNodeType(grp, "operatorname");
64408  }
64409  var base;
64410  if (group.body.length > 0) {
64411    var body = group.body.map((child2) => {
64412      var childText = child2.text;
64413      if (typeof childText === "string") {
64414        return {
64415          type: "textord",
64416          mode: child2.mode,
64417          text: childText
64418        };
64419      } else {
64420        return child2;
64421      }
64422    });
64423    var expression = buildExpression$1(body, options2.withFont("mathrm"), true);
64424    for (var i = 0; i < expression.length; i++) {
64425      var child = expression[i];
64426      if (child instanceof SymbolNode) {
64427        child.text = child.text.replace(/\u2212/, "-").replace(/\u2217/, "*");
64428      }
64429    }
64430    base = buildCommon.makeSpan(["mop"], expression, options2);
64431  } else {
64432    base = buildCommon.makeSpan(["mop"], [], options2);
64433  }
64434  if (hasLimits) {
64435    return assembleSupSub(base, supGroup, subGroup, options2, options2.style, 0, 0);
64436  } else {
64437    return base;
64438  }
64439};
64440var mathmlBuilder2 = (group, options2) => {
64441  var expression = buildExpression2(group.body, options2.withFont("mathrm"));
64442  var isAllString = true;
64443  for (var i = 0; i < expression.length; i++) {
64444    var node = expression[i];
64445    if (node instanceof mathMLTree.SpaceNode) ;
64446    else if (node instanceof mathMLTree.MathNode) {
64447      switch (node.type) {
64448        case "mi":
64449        case "mn":
64450        case "ms":
64451        case "mspace":
64452        case "mtext":
64453          break;
64454        // Do nothing yet.
64455        case "mo": {
64456          var child = node.children[0];
64457          if (node.children.length === 1 && child instanceof mathMLTree.TextNode) {
64458            child.text = child.text.replace(/\u2212/, "-").replace(/\u2217/, "*");
64459          } else {
64460            isAllString = false;
64461          }
64462          break;
64463        }
64464        default:
64465          isAllString = false;
64466      }
64467    } else {
64468      isAllString = false;
64469    }
64470  }
64471  if (isAllString) {
64472    var word = expression.map((node2) => node2.toText()).join("");
64473    expression = [new mathMLTree.TextNode(word)];
64474  }
64475  var identifier = new mathMLTree.MathNode("mi", expression);
64476  identifier.setAttribute("mathvariant", "normal");
64477  var operator = new mathMLTree.MathNode("mo", [makeText("\u2061", "text")]);
64478  if (group.parentIsSupSub) {
64479    return new mathMLTree.MathNode("mrow", [identifier, operator]);
64480  } else {
64481    return mathMLTree.newDocumentFragment([identifier, operator]);
64482  }
64483};
64484defineFunction({
64485  type: "operatorname",
64486  names: ["\\operatorname@", "\\operatornamewithlimits"],
64487  props: {
64488    numArgs: 1
64489  },
64490  handler: (_ref, args) => {
64491    var {
64492      parser: parser2,
64493      funcName
64494    } = _ref;
64495    var body = args[0];
64496    return {
64497      type: "operatorname",
64498      mode: parser2.mode,
64499      body: ordargument(body),
64500      alwaysHandleSupSub: funcName === "\\operatornamewithlimits",
64501      limits: false,
64502      parentIsSupSub: false
64503    };
64504  },
64505  htmlBuilder: htmlBuilder$1,
64506  mathmlBuilder: mathmlBuilder2
64507});
64508defineMacro("\\operatorname", "\\@ifstar\\operatornamewithlimits\\operatorname@");
64509defineFunctionBuilders({
64510  type: "ordgroup",
64511  htmlBuilder(group, options2) {
64512    if (group.semisimple) {
64513      return buildCommon.makeFragment(buildExpression$1(group.body, options2, false));
64514    }
64515    return buildCommon.makeSpan(["mord"], buildExpression$1(group.body, options2, true), options2);
64516  },
64517  mathmlBuilder(group, options2) {
64518    return buildExpressionRow(group.body, options2, true);
64519  }
64520});
64521defineFunction({
64522  type: "overline",
64523  names: ["\\overline"],
64524  props: {
64525    numArgs: 1
64526  },
64527  handler(_ref, args) {
64528    var {
64529      parser: parser2
64530    } = _ref;
64531    var body = args[0];
64532    return {
64533      type: "overline",
64534      mode: parser2.mode,
64535      body
64536    };
64537  },
64538  htmlBuilder(group, options2) {
64539    var innerGroup = buildGroup$1(group.body, options2.havingCrampedStyle());
64540    var line = buildCommon.makeLineSpan("overline-line", options2);
64541    var defaultRuleThickness = options2.fontMetrics().defaultRuleThickness;
64542    var vlist = buildCommon.makeVList({
64543      positionType: "firstBaseline",
64544      children: [{
64545        type: "elem",
64546        elem: innerGroup
64547      }, {
64548        type: "kern",
64549        size: 3 * defaultRuleThickness
64550      }, {
64551        type: "elem",
64552        elem: line
64553      }, {
64554        type: "kern",
64555        size: defaultRuleThickness
64556      }]
64557    }, options2);
64558    return buildCommon.makeSpan(["mord", "overline"], [vlist], options2);
64559  },
64560  mathmlBuilder(group, options2) {
64561    var operator = new mathMLTree.MathNode("mo", [new mathMLTree.TextNode("\u203E")]);
64562    operator.setAttribute("stretchy", "true");
64563    var node = new mathMLTree.MathNode("mover", [buildGroup2(group.body, options2), operator]);
64564    node.setAttribute("accent", "true");
64565    return node;
64566  }
64567});
64568defineFunction({
64569  type: "phantom",
64570  names: ["\\phantom"],
64571  props: {
64572    numArgs: 1,
64573    allowedInText: true
64574  },
64575  handler: (_ref, args) => {
64576    var {
64577      parser: parser2
64578    } = _ref;
64579    var body = args[0];
64580    return {
64581      type: "phantom",
64582      mode: parser2.mode,
64583      body: ordargument(body)
64584    };
64585  },
64586  htmlBuilder: (group, options2) => {
64587    var elements = buildExpression$1(group.body, options2.withPhantom(), false);
64588    return buildCommon.makeFragment(elements);
64589  },
64590  mathmlBuilder: (group, options2) => {
64591    var inner2 = buildExpression2(group.body, options2);
64592    return new mathMLTree.MathNode("mphantom", inner2);
64593  }
64594});
64595defineFunction({
64596  type: "hphantom",
64597  names: ["\\hphantom"],
64598  props: {
64599    numArgs: 1,
64600    allowedInText: true
64601  },
64602  handler: (_ref2, args) => {
64603    var {
64604      parser: parser2
64605    } = _ref2;
64606    var body = args[0];
64607    return {
64608      type: "hphantom",
64609      mode: parser2.mode,
64610      body
64611    };
64612  },
64613  htmlBuilder: (group, options2) => {
64614    var node = buildCommon.makeSpan([], [buildGroup$1(group.body, options2.withPhantom())]);
64615    node.height = 0;
64616    node.depth = 0;
64617    if (node.children) {
64618      for (var i = 0; i < node.children.length; i++) {
64619        node.children[i].height = 0;
64620        node.children[i].depth = 0;
64621      }
64622    }
64623    node = buildCommon.makeVList({
64624      positionType: "firstBaseline",
64625      children: [{
64626        type: "elem",
64627        elem: node
64628      }]
64629    }, options2);
64630    return buildCommon.makeSpan(["mord"], [node], options2);
64631  },
64632  mathmlBuilder: (group, options2) => {
64633    var inner2 = buildExpression2(ordargument(group.body), options2);
64634    var phantom = new mathMLTree.MathNode("mphantom", inner2);
64635    var node = new mathMLTree.MathNode("mpadded", [phantom]);
64636    node.setAttribute("height", "0px");
64637    node.setAttribute("depth", "0px");
64638    return node;
64639  }
64640});
64641defineFunction({
64642  type: "vphantom",
64643  names: ["\\vphantom"],
64644  props: {
64645    numArgs: 1,
64646    allowedInText: true
64647  },
64648  handler: (_ref3, args) => {
64649    var {
64650      parser: parser2
64651    } = _ref3;
64652    var body = args[0];
64653    return {
64654      type: "vphantom",
64655      mode: parser2.mode,
64656      body
64657    };
64658  },
64659  htmlBuilder: (group, options2) => {
64660    var inner2 = buildCommon.makeSpan(["inner"], [buildGroup$1(group.body, options2.withPhantom())]);
64661    var fix = buildCommon.makeSpan(["fix"], []);
64662    return buildCommon.makeSpan(["mord", "rlap"], [inner2, fix], options2);
64663  },
64664  mathmlBuilder: (group, options2) => {
64665    var inner2 = buildExpression2(ordargument(group.body), options2);
64666    var phantom = new mathMLTree.MathNode("mphantom", inner2);
64667    var node = new mathMLTree.MathNode("mpadded", [phantom]);
64668    node.setAttribute("width", "0px");
64669    return node;
64670  }
64671});
64672defineFunction({
64673  type: "raisebox",
64674  names: ["\\raisebox"],
64675  props: {
64676    numArgs: 2,
64677    argTypes: ["size", "hbox"],
64678    allowedInText: true
64679  },
64680  handler(_ref, args) {
64681    var {
64682      parser: parser2
64683    } = _ref;
64684    var amount = assertNodeType(args[0], "size").value;
64685    var body = args[1];
64686    return {
64687      type: "raisebox",
64688      mode: parser2.mode,
64689      dy: amount,
64690      body
64691    };
64692  },
64693  htmlBuilder(group, options2) {
64694    var body = buildGroup$1(group.body, options2);
64695    var dy = calculateSize(group.dy, options2);
64696    return buildCommon.makeVList({
64697      positionType: "shift",
64698      positionData: -dy,
64699      children: [{
64700        type: "elem",
64701        elem: body
64702      }]
64703    }, options2);
64704  },
64705  mathmlBuilder(group, options2) {
64706    var node = new mathMLTree.MathNode("mpadded", [buildGroup2(group.body, options2)]);
64707    var dy = group.dy.number + group.dy.unit;
64708    node.setAttribute("voffset", dy);
64709    return node;
64710  }
64711});
64712defineFunction({
64713  type: "internal",
64714  names: ["\\relax"],
64715  props: {
64716    numArgs: 0,
64717    allowedInText: true,
64718    allowedInArgument: true
64719  },
64720  handler(_ref) {
64721    var {
64722      parser: parser2
64723    } = _ref;
64724    return {
64725      type: "internal",
64726      mode: parser2.mode
64727    };
64728  }
64729});
64730defineFunction({
64731  type: "rule",
64732  names: ["\\rule"],
64733  props: {
64734    numArgs: 2,
64735    numOptionalArgs: 1,
64736    allowedInText: true,
64737    allowedInMath: true,
64738    argTypes: ["size", "size", "size"]
64739  },
64740  handler(_ref, args, optArgs) {
64741    var {
64742      parser: parser2
64743    } = _ref;
64744    var shift = optArgs[0];
64745    var width = assertNodeType(args[0], "size");
64746    var height = assertNodeType(args[1], "size");
64747    return {
64748      type: "rule",
64749      mode: parser2.mode,
64750      shift: shift && assertNodeType(shift, "size").value,
64751      width: width.value,
64752      height: height.value
64753    };
64754  },
64755  htmlBuilder(group, options2) {
64756    var rule = buildCommon.makeSpan(["mord", "rule"], [], options2);
64757    var width = calculateSize(group.width, options2);
64758    var height = calculateSize(group.height, options2);
64759    var shift = group.shift ? calculateSize(group.shift, options2) : 0;
64760    rule.style.borderRightWidth = makeEm(width);
64761    rule.style.borderTopWidth = makeEm(height);
64762    rule.style.bottom = makeEm(shift);
64763    rule.width = width;
64764    rule.height = height + shift;
64765    rule.depth = -shift;
64766    rule.maxFontSize = height * 1.125 * options2.sizeMultiplier;
64767    return rule;
64768  },
64769  mathmlBuilder(group, options2) {
64770    var width = calculateSize(group.width, options2);
64771    var height = calculateSize(group.height, options2);
64772    var shift = group.shift ? calculateSize(group.shift, options2) : 0;
64773    var color = options2.color && options2.getColor() || "black";
64774    var rule = new mathMLTree.MathNode("mspace");
64775    rule.setAttribute("mathbackground", color);
64776    rule.setAttribute("width", makeEm(width));
64777    rule.setAttribute("height", makeEm(height));
64778    var wrapper = new mathMLTree.MathNode("mpadded", [rule]);
64779    if (shift >= 0) {
64780      wrapper.setAttribute("height", makeEm(shift));
64781    } else {
64782      wrapper.setAttribute("height", makeEm(shift));
64783      wrapper.setAttribute("depth", makeEm(-shift));
64784    }
64785    wrapper.setAttribute("voffset", makeEm(shift));
64786    return wrapper;
64787  }
64788});
64789function sizingGroup(value, options2, baseOptions) {
64790  var inner2 = buildExpression$1(value, options2, false);
64791  var multiplier = options2.sizeMultiplier / baseOptions.sizeMultiplier;
64792  for (var i = 0; i < inner2.length; i++) {
64793    var pos = inner2[i].classes.indexOf("sizing");
64794    if (pos < 0) {
64795      Array.prototype.push.apply(inner2[i].classes, options2.sizingClasses(baseOptions));
64796    } else if (inner2[i].classes[pos + 1] === "reset-size" + options2.size) {
64797      inner2[i].classes[pos + 1] = "reset-size" + baseOptions.size;
64798    }
64799    inner2[i].height *= multiplier;
64800    inner2[i].depth *= multiplier;
64801  }
64802  return buildCommon.makeFragment(inner2);
64803}
64804var sizeFuncs = ["\\tiny", "\\sixptsize", "\\scriptsize", "\\footnotesize", "\\small", "\\normalsize", "\\large", "\\Large", "\\LARGE", "\\huge", "\\Huge"];
64805var htmlBuilder2 = (group, options2) => {
64806  var newOptions = options2.havingSize(group.size);
64807  return sizingGroup(group.body, newOptions, options2);
64808};
64809defineFunction({
64810  type: "sizing",
64811  names: sizeFuncs,
64812  props: {
64813    numArgs: 0,
64814    allowedInText: true
64815  },
64816  handler: (_ref, args) => {
64817    var {
64818      breakOnTokenText,
64819      funcName,
64820      parser: parser2
64821    } = _ref;
64822    var body = parser2.parseExpression(false, breakOnTokenText);
64823    return {
64824      type: "sizing",
64825      mode: parser2.mode,
64826      // Figure out what size to use based on the list of functions above
64827      size: sizeFuncs.indexOf(funcName) + 1,
64828      body
64829    };
64830  },
64831  htmlBuilder: htmlBuilder2,
64832  mathmlBuilder: (group, options2) => {
64833    var newOptions = options2.havingSize(group.size);
64834    var inner2 = buildExpression2(group.body, newOptions);
64835    var node = new mathMLTree.MathNode("mstyle", inner2);
64836    node.setAttribute("mathsize", makeEm(newOptions.sizeMultiplier));
64837    return node;
64838  }
64839});
64840defineFunction({
64841  type: "smash",
64842  names: ["\\smash"],
64843  props: {
64844    numArgs: 1,
64845    numOptionalArgs: 1,
64846    allowedInText: true
64847  },
64848  handler: (_ref, args, optArgs) => {
64849    var {
64850      parser: parser2
64851    } = _ref;
64852    var smashHeight = false;
64853    var smashDepth = false;
64854    var tbArg = optArgs[0] && assertNodeType(optArgs[0], "ordgroup");
64855    if (tbArg) {
64856      var letter = "";
64857      for (var i = 0; i < tbArg.body.length; ++i) {
64858        var node = tbArg.body[i];
64859        letter = node.text;
64860        if (letter === "t") {
64861          smashHeight = true;
64862        } else if (letter === "b") {
64863          smashDepth = true;
64864        } else {
64865          smashHeight = false;
64866          smashDepth = false;
64867          break;
64868        }
64869      }
64870    } else {
64871      smashHeight = true;
64872      smashDepth = true;
64873    }
64874    var body = args[0];
64875    return {
64876      type: "smash",
64877      mode: parser2.mode,
64878      body,
64879      smashHeight,
64880      smashDepth
64881    };
64882  },
64883  htmlBuilder: (group, options2) => {
64884    var node = buildCommon.makeSpan([], [buildGroup$1(group.body, options2)]);
64885    if (!group.smashHeight && !group.smashDepth) {
64886      return node;
64887    }
64888    if (group.smashHeight) {
64889      node.height = 0;
64890      if (node.children) {
64891        for (var i = 0; i < node.children.length; i++) {
64892          node.children[i].height = 0;
64893        }
64894      }
64895    }
64896    if (group.smashDepth) {
64897      node.depth = 0;
64898      if (node.children) {
64899        for (var _i = 0; _i < node.children.length; _i++) {
64900          node.children[_i].depth = 0;
64901        }
64902      }
64903    }
64904    var smashedNode = buildCommon.makeVList({
64905      positionType: "firstBaseline",
64906      children: [{
64907        type: "elem",
64908        elem: node
64909      }]
64910    }, options2);
64911    return buildCommon.makeSpan(["mord"], [smashedNode], options2);
64912  },
64913  mathmlBuilder: (group, options2) => {
64914    var node = new mathMLTree.MathNode("mpadded", [buildGroup2(group.body, options2)]);
64915    if (group.smashHeight) {
64916      node.setAttribute("height", "0px");
64917    }
64918    if (group.smashDepth) {
64919      node.setAttribute("depth", "0px");
64920    }
64921    return node;
64922  }
64923});
64924defineFunction({
64925  type: "sqrt",
64926  names: ["\\sqrt"],
64927  props: {
64928    numArgs: 1,
64929    numOptionalArgs: 1
64930  },
64931  handler(_ref, args, optArgs) {
64932    var {
64933      parser: parser2
64934    } = _ref;
64935    var index = optArgs[0];
64936    var body = args[0];
64937    return {
64938      type: "sqrt",
64939      mode: parser2.mode,
64940      body,
64941      index
64942    };
64943  },
64944  htmlBuilder(group, options2) {
64945    var inner2 = buildGroup$1(group.body, options2.havingCrampedStyle());
64946    if (inner2.height === 0) {
64947      inner2.height = options2.fontMetrics().xHeight;
64948    }
64949    inner2 = buildCommon.wrapFragment(inner2, options2);
64950    var metrics = options2.fontMetrics();
64951    var theta = metrics.defaultRuleThickness;
64952    var phi = theta;
64953    if (options2.style.id < Style$1.TEXT.id) {
64954      phi = options2.fontMetrics().xHeight;
64955    }
64956    var lineClearance = theta + phi / 4;
64957    var minDelimiterHeight = inner2.height + inner2.depth + lineClearance + theta;
64958    var {
64959      span: img,
64960      ruleWidth,
64961      advanceWidth
64962    } = delimiter.sqrtImage(minDelimiterHeight, options2);
64963    var delimDepth = img.height - ruleWidth;
64964    if (delimDepth > inner2.height + inner2.depth + lineClearance) {
64965      lineClearance = (lineClearance + delimDepth - inner2.height - inner2.depth) / 2;
64966    }
64967    var imgShift = img.height - inner2.height - lineClearance - ruleWidth;
64968    inner2.style.paddingLeft = makeEm(advanceWidth);
64969    var body = buildCommon.makeVList({
64970      positionType: "firstBaseline",
64971      children: [{
64972        type: "elem",
64973        elem: inner2,
64974        wrapperClasses: ["svg-align"]
64975      }, {
64976        type: "kern",
64977        size: -(inner2.height + imgShift)
64978      }, {
64979        type: "elem",
64980        elem: img
64981      }, {
64982        type: "kern",
64983        size: ruleWidth
64984      }]
64985    }, options2);
64986    if (!group.index) {
64987      return buildCommon.makeSpan(["mord", "sqrt"], [body], options2);
64988    } else {
64989      var newOptions = options2.havingStyle(Style$1.SCRIPTSCRIPT);
64990      var rootm = buildGroup$1(group.index, newOptions, options2);
64991      var toShift = 0.6 * (body.height - body.depth);
64992      var rootVList = buildCommon.makeVList({
64993        positionType: "shift",
64994        positionData: -toShift,
64995        children: [{
64996          type: "elem",
64997          elem: rootm
64998        }]
64999      }, options2);
65000      var rootVListWrap = buildCommon.makeSpan(["root"], [rootVList]);
65001      return buildCommon.makeSpan(["mord", "sqrt"], [rootVListWrap, body], options2);
65002    }
65003  },
65004  mathmlBuilder(group, options2) {
65005    var {
65006      body,
65007      index
65008    } = group;
65009    return index ? new mathMLTree.MathNode("mroot", [buildGroup2(body, options2), buildGroup2(index, options2)]) : new mathMLTree.MathNode("msqrt", [buildGroup2(body, options2)]);
65010  }
65011});
65012var styleMap = {
65013  "display": Style$1.DISPLAY,
65014  "text": Style$1.TEXT,
65015  "script": Style$1.SCRIPT,
65016  "scriptscript": Style$1.SCRIPTSCRIPT
65017};
65018defineFunction({
65019  type: "styling",
65020  names: ["\\displaystyle", "\\textstyle", "\\scriptstyle", "\\scriptscriptstyle"],
65021  props: {
65022    numArgs: 0,
65023    allowedInText: true,
65024    primitive: true
65025  },
65026  handler(_ref, args) {
65027    var {
65028      breakOnTokenText,
65029      funcName,
65030      parser: parser2
65031    } = _ref;
65032    var body = parser2.parseExpression(true, breakOnTokenText);
65033    var style = funcName.slice(1, funcName.length - 5);
65034    return {
65035      type: "styling",
65036      mode: parser2.mode,
65037      // Figure out what style to use by pulling out the style from
65038      // the function name
65039      style,
65040      body
65041    };
65042  },
65043  htmlBuilder(group, options2) {
65044    var newStyle = styleMap[group.style];
65045    var newOptions = options2.havingStyle(newStyle).withFont("");
65046    return sizingGroup(group.body, newOptions, options2);
65047  },
65048  mathmlBuilder(group, options2) {
65049    var newStyle = styleMap[group.style];
65050    var newOptions = options2.havingStyle(newStyle);
65051    var inner2 = buildExpression2(group.body, newOptions);
65052    var node = new mathMLTree.MathNode("mstyle", inner2);
65053    var styleAttributes = {
65054      "display": ["0", "true"],
65055      "text": ["0", "false"],
65056      "script": ["1", "false"],
65057      "scriptscript": ["2", "false"]
65058    };
65059    var attr = styleAttributes[group.style];
65060    node.setAttribute("scriptlevel", attr[0]);
65061    node.setAttribute("displaystyle", attr[1]);
65062    return node;
65063  }
65064});
65065var htmlBuilderDelegate = function htmlBuilderDelegate2(group, options2) {
65066  var base = group.base;
65067  if (!base) {
65068    return null;
65069  } else if (base.type === "op") {
65070    var delegate = base.limits && (options2.style.size === Style$1.DISPLAY.size || base.alwaysHandleSupSub);
65071    return delegate ? htmlBuilder$2 : null;
65072  } else if (base.type === "operatorname") {
65073    var _delegate = base.alwaysHandleSupSub && (options2.style.size === Style$1.DISPLAY.size || base.limits);
65074    return _delegate ? htmlBuilder$1 : null;
65075  } else if (base.type === "accent") {
65076    return utils.isCharacterBox(base.base) ? htmlBuilder$a : null;
65077  } else if (base.type === "horizBrace") {
65078    var isSup = !group.sub;
65079    return isSup === base.isOver ? htmlBuilder$3 : null;
65080  } else {
65081    return null;
65082  }
65083};
65084defineFunctionBuilders({
65085  type: "supsub",
65086  htmlBuilder(group, options2) {
65087    var builderDelegate = htmlBuilderDelegate(group, options2);
65088    if (builderDelegate) {
65089      return builderDelegate(group, options2);
65090    }
65091    var {
65092      base: valueBase,
65093      sup: valueSup,
65094      sub: valueSub
65095    } = group;
65096    var base = buildGroup$1(valueBase, options2);
65097    var supm;
65098    var subm;
65099    var metrics = options2.fontMetrics();
65100    var supShift = 0;
65101    var subShift = 0;
65102    var isCharacterBox3 = valueBase && utils.isCharacterBox(valueBase);
65103    if (valueSup) {
65104      var newOptions = options2.havingStyle(options2.style.sup());
65105      supm = buildGroup$1(valueSup, newOptions, options2);
65106      if (!isCharacterBox3) {
65107        supShift = base.height - newOptions.fontMetrics().supDrop * newOptions.sizeMultiplier / options2.sizeMultiplier;
65108      }
65109    }
65110    if (valueSub) {
65111      var _newOptions = options2.havingStyle(options2.style.sub());
65112      subm = buildGroup$1(valueSub, _newOptions, options2);
65113      if (!isCharacterBox3) {
65114        subShift = base.depth + _newOptions.fontMetrics().subDrop * _newOptions.sizeMultiplier / options2.sizeMultiplier;
65115      }
65116    }
65117    var minSupShift;
65118    if (options2.style === Style$1.DISPLAY) {
65119      minSupShift = metrics.sup1;
65120    } else if (options2.style.cramped) {
65121      minSupShift = metrics.sup3;
65122    } else {
65123      minSupShift = metrics.sup2;
65124    }
65125    var multiplier = options2.sizeMultiplier;
65126    var marginRight = makeEm(0.5 / metrics.ptPerEm / multiplier);
65127    var marginLeft = null;
65128    if (subm) {
65129      var isOiint = group.base && group.base.type === "op" && group.base.name && (group.base.name === "\\oiint" || group.base.name === "\\oiiint");
65130      if (base instanceof SymbolNode || isOiint) {
65131        marginLeft = makeEm(-base.italic);
65132      }
65133    }
65134    var supsub;
65135    if (supm && subm) {
65136      supShift = Math.max(supShift, minSupShift, supm.depth + 0.25 * metrics.xHeight);
65137      subShift = Math.max(subShift, metrics.sub2);
65138      var ruleWidth = metrics.defaultRuleThickness;
65139      var maxWidth = 4 * ruleWidth;
65140      if (supShift - supm.depth - (subm.height - subShift) < maxWidth) {
65141        subShift = maxWidth - (supShift - supm.depth) + subm.height;
65142        var psi = 0.8 * metrics.xHeight - (supShift - supm.depth);
65143        if (psi > 0) {
65144          supShift += psi;
65145          subShift -= psi;
65146        }
65147      }
65148      var vlistElem = [{
65149        type: "elem",
65150        elem: subm,
65151        shift: subShift,
65152        marginRight,
65153        marginLeft
65154      }, {
65155        type: "elem",
65156        elem: supm,
65157        shift: -supShift,
65158        marginRight
65159      }];
65160      supsub = buildCommon.makeVList({
65161        positionType: "individualShift",
65162        children: vlistElem
65163      }, options2);
65164    } else if (subm) {
65165      subShift = Math.max(subShift, metrics.sub1, subm.height - 0.8 * metrics.xHeight);
65166      var _vlistElem = [{
65167        type: "elem",
65168        elem: subm,
65169        marginLeft,
65170        marginRight
65171      }];
65172      supsub = buildCommon.makeVList({
65173        positionType: "shift",
65174        positionData: subShift,
65175        children: _vlistElem
65176      }, options2);
65177    } else if (supm) {
65178      supShift = Math.max(supShift, minSupShift, supm.depth + 0.25 * metrics.xHeight);
65179      supsub = buildCommon.makeVList({
65180        positionType: "shift",
65181        positionData: -supShift,
65182        children: [{
65183          type: "elem",
65184          elem: supm,
65185          marginRight
65186        }]
65187      }, options2);
65188    } else {
65189      throw new Error("supsub must have either sup or sub.");
65190    }
65191    var mclass = getTypeOfDomTree(base, "right") || "mord";
65192    return buildCommon.makeSpan([mclass], [base, buildCommon.makeSpan(["msupsub"], [supsub])], options2);
65193  },
65194  mathmlBuilder(group, options2) {
65195    var isBrace = false;
65196    var isOver;
65197    var isSup;
65198    if (group.base && group.base.type === "horizBrace") {
65199      isSup = !!group.sup;
65200      if (isSup === group.base.isOver) {
65201        isBrace = true;
65202        isOver = group.base.isOver;
65203      }
65204    }
65205    if (group.base && (group.base.type === "op" || group.base.type === "operatorname")) {
65206      group.base.parentIsSupSub = true;
65207    }
65208    var children = [buildGroup2(group.base, options2)];
65209    if (group.sub) {
65210      children.push(buildGroup2(group.sub, options2));
65211    }
65212    if (group.sup) {
65213      children.push(buildGroup2(group.sup, options2));
65214    }
65215    var nodeType;
65216    if (isBrace) {
65217      nodeType = isOver ? "mover" : "munder";
65218    } else if (!group.sub) {
65219      var base = group.base;
65220      if (base && base.type === "op" && base.limits && (options2.style === Style$1.DISPLAY || base.alwaysHandleSupSub)) {
65221        nodeType = "mover";
65222      } else if (base && base.type === "operatorname" && base.alwaysHandleSupSub && (base.limits || options2.style === Style$1.DISPLAY)) {
65223        nodeType = "mover";
65224      } else {
65225        nodeType = "msup";
65226      }
65227    } else if (!group.sup) {
65228      var _base = group.base;
65229      if (_base && _base.type === "op" && _base.limits && (options2.style === Style$1.DISPLAY || _base.alwaysHandleSupSub)) {
65230        nodeType = "munder";
65231      } else if (_base && _base.type === "operatorname" && _base.alwaysHandleSupSub && (_base.limits || options2.style === Style$1.DISPLAY)) {
65232        nodeType = "munder";
65233      } else {
65234        nodeType = "msub";
65235      }
65236    } else {
65237      var _base2 = group.base;
65238      if (_base2 && _base2.type === "op" && _base2.limits && options2.style === Style$1.DISPLAY) {
65239        nodeType = "munderover";
65240      } else if (_base2 && _base2.type === "operatorname" && _base2.alwaysHandleSupSub && (options2.style === Style$1.DISPLAY || _base2.limits)) {
65241        nodeType = "munderover";
65242      } else {
65243        nodeType = "msubsup";
65244      }
65245    }
65246    return new mathMLTree.MathNode(nodeType, children);
65247  }
65248});
65249defineFunctionBuilders({
65250  type: "atom",
65251  htmlBuilder(group, options2) {
65252    return buildCommon.mathsym(group.text, group.mode, options2, ["m" + group.family]);
65253  },
65254  mathmlBuilder(group, options2) {
65255    var node = new mathMLTree.MathNode("mo", [makeText(group.text, group.mode)]);
65256    if (group.family === "bin") {
65257      var variant = getVariant(group, options2);
65258      if (variant === "bold-italic") {
65259        node.setAttribute("mathvariant", variant);
65260      }
65261    } else if (group.family === "punct") {
65262      node.setAttribute("separator", "true");
65263    } else if (group.family === "open" || group.family === "close") {
65264      node.setAttribute("stretchy", "false");
65265    }
65266    return node;
65267  }
65268});
65269var defaultVariant = {
65270  "mi": "italic",
65271  "mn": "normal",
65272  "mtext": "normal"
65273};
65274defineFunctionBuilders({
65275  type: "mathord",
65276  htmlBuilder(group, options2) {
65277    return buildCommon.makeOrd(group, options2, "mathord");
65278  },
65279  mathmlBuilder(group, options2) {
65280    var node = new mathMLTree.MathNode("mi", [makeText(group.text, group.mode, options2)]);
65281    var variant = getVariant(group, options2) || "italic";
65282    if (variant !== defaultVariant[node.type]) {
65283      node.setAttribute("mathvariant", variant);
65284    }
65285    return node;
65286  }
65287});
65288defineFunctionBuilders({
65289  type: "textord",
65290  htmlBuilder(group, options2) {
65291    return buildCommon.makeOrd(group, options2, "textord");
65292  },
65293  mathmlBuilder(group, options2) {
65294    var text2 = makeText(group.text, group.mode, options2);
65295    var variant = getVariant(group, options2) || "normal";
65296    var node;
65297    if (group.mode === "text") {
65298      node = new mathMLTree.MathNode("mtext", [text2]);
65299    } else if (/[0-9]/.test(group.text)) {
65300      node = new mathMLTree.MathNode("mn", [text2]);
65301    } else if (group.text === "\\prime") {
65302      node = new mathMLTree.MathNode("mo", [text2]);
65303    } else {
65304      node = new mathMLTree.MathNode("mi", [text2]);
65305    }
65306    if (variant !== defaultVariant[node.type]) {
65307      node.setAttribute("mathvariant", variant);
65308    }
65309    return node;
65310  }
65311});
65312var cssSpace = {
65313  "\\nobreak": "nobreak",
65314  "\\allowbreak": "allowbreak"
65315};
65316var regularSpace = {
65317  " ": {},
65318  "\\ ": {},
65319  "~": {
65320    className: "nobreak"
65321  },
65322  "\\space": {},
65323  "\\nobreakspace": {
65324    className: "nobreak"
65325  }
65326};
65327defineFunctionBuilders({
65328  type: "spacing",
65329  htmlBuilder(group, options2) {
65330    if (regularSpace.hasOwnProperty(group.text)) {
65331      var className = regularSpace[group.text].className || "";
65332      if (group.mode === "text") {
65333        var ord = buildCommon.makeOrd(group, options2, "textord");
65334        ord.classes.push(className);
65335        return ord;
65336      } else {
65337        return buildCommon.makeSpan(["mspace", className], [buildCommon.mathsym(group.text, group.mode, options2)], options2);
65338      }
65339    } else if (cssSpace.hasOwnProperty(group.text)) {
65340      return buildCommon.makeSpan(["mspace", cssSpace[group.text]], [], options2);
65341    } else {
65342      throw new ParseError('Unknown type of space "' + group.text + '"');
65343    }
65344  },
65345  mathmlBuilder(group, options2) {
65346    var node;
65347    if (regularSpace.hasOwnProperty(group.text)) {
65348      node = new mathMLTree.MathNode("mtext", [new mathMLTree.TextNode("\xA0")]);
65349    } else if (cssSpace.hasOwnProperty(group.text)) {
65350      return new mathMLTree.MathNode("mspace");
65351    } else {
65352      throw new ParseError('Unknown type of space "' + group.text + '"');
65353    }
65354    return node;
65355  }
65356});
65357var pad = () => {
65358  var padNode = new mathMLTree.MathNode("mtd", []);
65359  padNode.setAttribute("width", "50%");
65360  return padNode;
65361};
65362defineFunctionBuilders({
65363  type: "tag",
65364  mathmlBuilder(group, options2) {
65365    var table = new mathMLTree.MathNode("mtable", [new mathMLTree.MathNode("mtr", [pad(), new mathMLTree.MathNode("mtd", [buildExpressionRow(group.body, options2)]), pad(), new mathMLTree.MathNode("mtd", [buildExpressionRow(group.tag, options2)])])]);
65366    table.setAttribute("width", "100%");
65367    return table;
65368  }
65369});
65370var textFontFamilies = {
65371  "\\text": void 0,
65372  "\\textrm": "textrm",
65373  "\\textsf": "textsf",
65374  "\\texttt": "texttt",
65375  "\\textnormal": "textrm"
65376};
65377var textFontWeights = {
65378  "\\textbf": "textbf",
65379  "\\textmd": "textmd"
65380};
65381var textFontShapes = {
65382  "\\textit": "textit",
65383  "\\textup": "textup"
65384};
65385var optionsWithFont = (group, options2) => {
65386  var font = group.font;
65387  if (!font) {
65388    return options2;
65389  } else if (textFontFamilies[font]) {
65390    return options2.withTextFontFamily(textFontFamilies[font]);
65391  } else if (textFontWeights[font]) {
65392    return options2.withTextFontWeight(textFontWeights[font]);
65393  } else if (font === "\\emph") {
65394    return options2.fontShape === "textit" ? options2.withTextFontShape("textup") : options2.withTextFontShape("textit");
65395  }
65396  return options2.withTextFontShape(textFontShapes[font]);
65397};
65398defineFunction({
65399  type: "text",
65400  names: [
65401    // Font families
65402    "\\text",
65403    "\\textrm",
65404    "\\textsf",
65405    "\\texttt",
65406    "\\textnormal",
65407    // Font weights
65408    "\\textbf",
65409    "\\textmd",
65410    // Font Shapes
65411    "\\textit",
65412    "\\textup",
65413    "\\emph"
65414  ],
65415  props: {
65416    numArgs: 1,
65417    argTypes: ["text"],
65418    allowedInArgument: true,
65419    allowedInText: true
65420  },
65421  handler(_ref, args) {
65422    var {
65423      parser: parser2,
65424      funcName
65425    } = _ref;
65426    var body = args[0];
65427    return {
65428      type: "text",
65429      mode: parser2.mode,
65430      body: ordargument(body),
65431      font: funcName
65432    };
65433  },
65434  htmlBuilder(group, options2) {
65435    var newOptions = optionsWithFont(group, options2);
65436    var inner2 = buildExpression$1(group.body, newOptions, true);
65437    return buildCommon.makeSpan(["mord", "text"], inner2, newOptions);
65438  },
65439  mathmlBuilder(group, options2) {
65440    var newOptions = optionsWithFont(group, options2);
65441    return buildExpressionRow(group.body, newOptions);
65442  }
65443});
65444defineFunction({
65445  type: "underline",
65446  names: ["\\underline"],
65447  props: {
65448    numArgs: 1,
65449    allowedInText: true
65450  },
65451  handler(_ref, args) {
65452    var {
65453      parser: parser2
65454    } = _ref;
65455    return {
65456      type: "underline",
65457      mode: parser2.mode,
65458      body: args[0]
65459    };
65460  },
65461  htmlBuilder(group, options2) {
65462    var innerGroup = buildGroup$1(group.body, options2);
65463    var line = buildCommon.makeLineSpan("underline-line", options2);
65464    var defaultRuleThickness = options2.fontMetrics().defaultRuleThickness;
65465    var vlist = buildCommon.makeVList({
65466      positionType: "top",
65467      positionData: innerGroup.height,
65468      children: [{
65469        type: "kern",
65470        size: defaultRuleThickness
65471      }, {
65472        type: "elem",
65473        elem: line
65474      }, {
65475        type: "kern",
65476        size: 3 * defaultRuleThickness
65477      }, {
65478        type: "elem",
65479        elem: innerGroup
65480      }]
65481    }, options2);
65482    return buildCommon.makeSpan(["mord", "underline"], [vlist], options2);
65483  },
65484  mathmlBuilder(group, options2) {
65485    var operator = new mathMLTree.MathNode("mo", [new mathMLTree.TextNode("\u203E")]);
65486    operator.setAttribute("stretchy", "true");
65487    var node = new mathMLTree.MathNode("munder", [buildGroup2(group.body, options2), operator]);
65488    node.setAttribute("accentunder", "true");
65489    return node;
65490  }
65491});
65492defineFunction({
65493  type: "vcenter",
65494  names: ["\\vcenter"],
65495  props: {
65496    numArgs: 1,
65497    argTypes: ["original"],
65498    // In LaTeX, \vcenter can act only on a box.
65499    allowedInText: false
65500  },
65501  handler(_ref, args) {
65502    var {
65503      parser: parser2
65504    } = _ref;
65505    return {
65506      type: "vcenter",
65507      mode: parser2.mode,
65508      body: args[0]
65509    };
65510  },
65511  htmlBuilder(group, options2) {
65512    var body = buildGroup$1(group.body, options2);
65513    var axisHeight = options2.fontMetrics().axisHeight;
65514    var dy = 0.5 * (body.height - axisHeight - (body.depth + axisHeight));
65515    return buildCommon.makeVList({
65516      positionType: "shift",
65517      positionData: dy,
65518      children: [{
65519        type: "elem",
65520        elem: body
65521      }]
65522    }, options2);
65523  },
65524  mathmlBuilder(group, options2) {
65525    return new mathMLTree.MathNode("mpadded", [buildGroup2(group.body, options2)], ["vcenter"]);
65526  }
65527});
65528defineFunction({
65529  type: "verb",
65530  names: ["\\verb"],
65531  props: {
65532    numArgs: 0,
65533    allowedInText: true
65534  },
65535  handler(context, args, optArgs) {
65536    throw new ParseError("\\verb ended by end of line instead of matching delimiter");
65537  },
65538  htmlBuilder(group, options2) {
65539    var text2 = makeVerb(group);
65540    var body = [];
65541    var newOptions = options2.havingStyle(options2.style.text());
65542    for (var i = 0; i < text2.length; i++) {
65543      var c = text2[i];
65544      if (c === "~") {
65545        c = "\\textasciitilde";
65546      }
65547      body.push(buildCommon.makeSymbol(c, "Typewriter-Regular", group.mode, newOptions, ["mord", "texttt"]));
65548    }
65549    return buildCommon.makeSpan(["mord", "text"].concat(newOptions.sizingClasses(options2)), buildCommon.tryCombineChars(body), newOptions);
65550  },
65551  mathmlBuilder(group, options2) {
65552    var text2 = new mathMLTree.TextNode(makeVerb(group));
65553    var node = new mathMLTree.MathNode("mtext", [text2]);
65554    node.setAttribute("mathvariant", "monospace");
65555    return node;
65556  }
65557});
65558var makeVerb = (group) => group.body.replace(/ /g, group.star ? "\u2423" : "\xA0");
65559var functions = _functions;
65560var spaceRegexString = "[ \r\n	]";
65561var controlWordRegexString = "\\\\[a-zA-Z@]+";
65562var controlSymbolRegexString = "\\\\[^\uD800-\uDFFF]";
65563var controlWordWhitespaceRegexString = "(" + controlWordRegexString + ")" + spaceRegexString + "*";
65564var controlSpaceRegexString = "\\\\(\n|[ \r	]+\n?)[ \r	]*";
65565var combiningDiacriticalMarkString = "[\u0300-\u036F]";
65566var combiningDiacriticalMarksEndRegex = new RegExp(combiningDiacriticalMarkString + "+$");
65567var tokenRegexString = "(" + spaceRegexString + "+)|" + // whitespace
65568(controlSpaceRegexString + "|") + // \whitespace
65569"([!-\\[\\]-\u2027\u202A-\uD7FF\uF900-\uFFFF]" + // single codepoint
65570(combiningDiacriticalMarkString + "*") + // ...plus accents
65571"|[\uD800-\uDBFF][\uDC00-\uDFFF]" + // surrogate pair
65572(combiningDiacriticalMarkString + "*") + // ...plus accents
65573"|\\\\verb\\*([^]).*?\\4|\\\\verb([^*a-zA-Z]).*?\\5" + // \verb unstarred
65574("|" + controlWordWhitespaceRegexString) + // \macroName + spaces
65575("|" + controlSymbolRegexString + ")");
65576var Lexer = class {
65577  // Category codes. The lexer only supports comment characters (14) for now.
65578  // MacroExpander additionally distinguishes active (13).
65579  constructor(input2, settings) {
65580    this.input = void 0;
65581    this.settings = void 0;
65582    this.tokenRegex = void 0;
65583    this.catcodes = void 0;
65584    this.input = input2;
65585    this.settings = settings;
65586    this.tokenRegex = new RegExp(tokenRegexString, "g");
65587    this.catcodes = {
65588      "%": 14,
65589      // comment character
65590      "~": 13
65591      // active character
65592    };
65593  }
65594  setCatcode(char, code) {
65595    this.catcodes[char] = code;
65596  }
65597  /**
65598   * This function lexes a single token.
65599   */
65600  lex() {
65601    var input2 = this.input;
65602    var pos = this.tokenRegex.lastIndex;
65603    if (pos === input2.length) {
65604      return new Token("EOF", new SourceLocation(this, pos, pos));
65605    }
65606    var match = this.tokenRegex.exec(input2);
65607    if (match === null || match.index !== pos) {
65608      throw new ParseError("Unexpected character: '" + input2[pos] + "'", new Token(input2[pos], new SourceLocation(this, pos, pos + 1)));
65609    }
65610    var text2 = match[6] || match[3] || (match[2] ? "\\ " : " ");
65611    if (this.catcodes[text2] === 14) {
65612      var nlIndex = input2.indexOf("\n", this.tokenRegex.lastIndex);
65613      if (nlIndex === -1) {
65614        this.tokenRegex.lastIndex = input2.length;
65615        this.settings.reportNonstrict("commentAtEnd", "% comment has no terminating newline; LaTeX would fail because of commenting the end of math mode (e.g. $)");
65616      } else {
65617        this.tokenRegex.lastIndex = nlIndex + 1;
65618      }
65619      return this.lex();
65620    }
65621    return new Token(text2, new SourceLocation(this, pos, this.tokenRegex.lastIndex));
65622  }
65623};
65624var Namespace = class {
65625  /**
65626   * Both arguments are optional.  The first argument is an object of
65627   * built-in mappings which never change.  The second argument is an object
65628   * of initial (global-level) mappings, which will constantly change
65629   * according to any global/top-level `set`s done.
65630   */
65631  constructor(builtins, globalMacros) {
65632    if (builtins === void 0) {
65633      builtins = {};
65634    }
65635    if (globalMacros === void 0) {
65636      globalMacros = {};
65637    }
65638    this.current = void 0;
65639    this.builtins = void 0;
65640    this.undefStack = void 0;
65641    this.current = globalMacros;
65642    this.builtins = builtins;
65643    this.undefStack = [];
65644  }
65645  /**
65646   * Start a new nested group, affecting future local `set`s.
65647   */
65648  beginGroup() {
65649    this.undefStack.push({});
65650  }
65651  /**
65652   * End current nested group, restoring values before the group began.
65653   */
65654  endGroup() {
65655    if (this.undefStack.length === 0) {
65656      throw new ParseError("Unbalanced namespace destruction: attempt to pop global namespace; please report this as a bug");
65657    }
65658    var undefs = this.undefStack.pop();
65659    for (var undef in undefs) {
65660      if (undefs.hasOwnProperty(undef)) {
65661        if (undefs[undef] == null) {
65662          delete this.current[undef];
65663        } else {
65664          this.current[undef] = undefs[undef];
65665        }
65666      }
65667    }
65668  }
65669  /**
65670   * Ends all currently nested groups (if any), restoring values before the
65671   * groups began.  Useful in case of an error in the middle of parsing.
65672   */
65673  endGroups() {
65674    while (this.undefStack.length > 0) {
65675      this.endGroup();
65676    }
65677  }
65678  /**
65679   * Detect whether `name` has a definition.  Equivalent to
65680   * `get(name) != null`.
65681   */
65682  has(name) {
65683    return this.current.hasOwnProperty(name) || this.builtins.hasOwnProperty(name);
65684  }
65685  /**
65686   * Get the current value of a name, or `undefined` if there is no value.
65687   *
65688   * Note: Do not use `if (namespace.get(...))` to detect whether a macro
65689   * is defined, as the definition may be the empty string which evaluates
65690   * to `false` in JavaScript.  Use `if (namespace.get(...) != null)` or
65691   * `if (namespace.has(...))`.
65692   */
65693  get(name) {
65694    if (this.current.hasOwnProperty(name)) {
65695      return this.current[name];
65696    } else {
65697      return this.builtins[name];
65698    }
65699  }
65700  /**
65701   * Set the current value of a name, and optionally set it globally too.
65702   * Local set() sets the current value and (when appropriate) adds an undo
65703   * operation to the undo stack.  Global set() may change the undo
65704   * operation at every level, so takes time linear in their number.
65705   * A value of undefined means to delete existing definitions.
65706   */
65707  set(name, value, global2) {
65708    if (global2 === void 0) {
65709      global2 = false;
65710    }
65711    if (global2) {
65712      for (var i = 0; i < this.undefStack.length; i++) {
65713        delete this.undefStack[i][name];
65714      }
65715      if (this.undefStack.length > 0) {
65716        this.undefStack[this.undefStack.length - 1][name] = value;
65717      }
65718    } else {
65719      var top = this.undefStack[this.undefStack.length - 1];
65720      if (top && !top.hasOwnProperty(name)) {
65721        top[name] = this.current[name];
65722      }
65723    }
65724    if (value == null) {
65725      delete this.current[name];
65726    } else {
65727      this.current[name] = value;
65728    }
65729  }
65730};
65731var macros = _macros;
65732defineMacro("\\noexpand", function(context) {
65733  var t = context.popToken();
65734  if (context.isExpandable(t.text)) {
65735    t.noexpand = true;
65736    t.treatAsRelax = true;
65737  }
65738  return {
65739    tokens: [t],
65740    numArgs: 0
65741  };
65742});
65743defineMacro("\\expandafter", function(context) {
65744  var t = context.popToken();
65745  context.expandOnce(true);
65746  return {
65747    tokens: [t],
65748    numArgs: 0
65749  };
65750});
65751defineMacro("\\@firstoftwo", function(context) {
65752  var args = context.consumeArgs(2);
65753  return {
65754    tokens: args[0],
65755    numArgs: 0
65756  };
65757});
65758defineMacro("\\@secondoftwo", function(context) {
65759  var args = context.consumeArgs(2);
65760  return {
65761    tokens: args[1],
65762    numArgs: 0
65763  };
65764});
65765defineMacro("\\@ifnextchar", function(context) {
65766  var args = context.consumeArgs(3);
65767  context.consumeSpaces();
65768  var nextToken = context.future();
65769  if (args[0].length === 1 && args[0][0].text === nextToken.text) {
65770    return {
65771      tokens: args[1],
65772      numArgs: 0
65773    };
65774  } else {
65775    return {
65776      tokens: args[2],
65777      numArgs: 0
65778    };
65779  }
65780});
65781defineMacro("\\@ifstar", "\\@ifnextchar *{\\@firstoftwo{#1}}");
65782defineMacro("\\TextOrMath", function(context) {
65783  var args = context.consumeArgs(2);
65784  if (context.mode === "text") {
65785    return {
65786      tokens: args[0],
65787      numArgs: 0
65788    };
65789  } else {
65790    return {
65791      tokens: args[1],
65792      numArgs: 0
65793    };
65794  }
65795});
65796var digitToNumber = {
65797  "0": 0,
65798  "1": 1,
65799  "2": 2,
65800  "3": 3,
65801  "4": 4,
65802  "5": 5,
65803  "6": 6,
65804  "7": 7,
65805  "8": 8,
65806  "9": 9,
65807  "a": 10,
65808  "A": 10,
65809  "b": 11,
65810  "B": 11,
65811  "c": 12,
65812  "C": 12,
65813  "d": 13,
65814  "D": 13,
65815  "e": 14,
65816  "E": 14,
65817  "f": 15,
65818  "F": 15
65819};
65820defineMacro("\\char", function(context) {
65821  var token = context.popToken();
65822  var base;
65823  var number = "";
65824  if (token.text === "'") {
65825    base = 8;
65826    token = context.popToken();
65827  } else if (token.text === '"') {
65828    base = 16;
65829    token = context.popToken();
65830  } else if (token.text === "`") {
65831    token = context.popToken();
65832    if (token.text[0] === "\\") {
65833      number = token.text.charCodeAt(1);
65834    } else if (token.text === "EOF") {
65835      throw new ParseError("\\char` missing argument");
65836    } else {
65837      number = token.text.charCodeAt(0);
65838    }
65839  } else {
65840    base = 10;
65841  }
65842  if (base) {
65843    number = digitToNumber[token.text];
65844    if (number == null || number >= base) {
65845      throw new ParseError("Invalid base-" + base + " digit " + token.text);
65846    }
65847    var digit;
65848    while ((digit = digitToNumber[context.future().text]) != null && digit < base) {
65849      number *= base;
65850      number += digit;
65851      context.popToken();
65852    }
65853  }
65854  return "\\@char{" + number + "}";
65855});
65856var newcommand = (context, existsOK, nonexistsOK, skipIfExists) => {
65857  var arg = context.consumeArg().tokens;
65858  if (arg.length !== 1) {
65859    throw new ParseError("\\newcommand's first argument must be a macro name");
65860  }
65861  var name = arg[0].text;
65862  var exists = context.isDefined(name);
65863  if (exists && !existsOK) {
65864    throw new ParseError("\\newcommand{" + name + "} attempting to redefine " + (name + "; use \\renewcommand"));
65865  }
65866  if (!exists && !nonexistsOK) {
65867    throw new ParseError("\\renewcommand{" + name + "} when command " + name + " does not yet exist; use \\newcommand");
65868  }
65869  var numArgs = 0;
65870  arg = context.consumeArg().tokens;
65871  if (arg.length === 1 && arg[0].text === "[") {
65872    var argText = "";
65873    var token = context.expandNextToken();
65874    while (token.text !== "]" && token.text !== "EOF") {
65875      argText += token.text;
65876      token = context.expandNextToken();
65877    }
65878    if (!argText.match(/^\s*[0-9]+\s*$/)) {
65879      throw new ParseError("Invalid number of arguments: " + argText);
65880    }
65881    numArgs = parseInt(argText);
65882    arg = context.consumeArg().tokens;
65883  }
65884  if (!(exists && skipIfExists)) {
65885    context.macros.set(name, {
65886      tokens: arg,
65887      numArgs
65888    });
65889  }
65890  return "";
65891};
65892defineMacro("\\newcommand", (context) => newcommand(context, false, true, false));
65893defineMacro("\\renewcommand", (context) => newcommand(context, true, false, false));
65894defineMacro("\\providecommand", (context) => newcommand(context, true, true, true));
65895defineMacro("\\message", (context) => {
65896  var arg = context.consumeArgs(1)[0];
65897  console.log(arg.reverse().map((token) => token.text).join(""));
65898  return "";
65899});
65900defineMacro("\\errmessage", (context) => {
65901  var arg = context.consumeArgs(1)[0];
65902  console.error(arg.reverse().map((token) => token.text).join(""));
65903  return "";
65904});
65905defineMacro("\\show", (context) => {
65906  var tok = context.popToken();
65907  var name = tok.text;
65908  console.log(tok, context.macros.get(name), functions[name], symbols.math[name], symbols.text[name]);
65909  return "";
65910});
65911defineMacro("\\bgroup", "{");
65912defineMacro("\\egroup", "}");
65913defineMacro("~", "\\nobreakspace");
65914defineMacro("\\lq", "`");
65915defineMacro("\\rq", "'");
65916defineMacro("\\aa", "\\r a");
65917defineMacro("\\AA", "\\r A");
65918defineMacro("\\textcopyright", "\\html@mathml{\\textcircled{c}}{\\char`\xA9}");
65919defineMacro("\\copyright", "\\TextOrMath{\\textcopyright}{\\text{\\textcopyright}}");
65920defineMacro("\\textregistered", "\\html@mathml{\\textcircled{\\scriptsize R}}{\\char`\xAE}");
65921defineMacro("\u212C", "\\mathscr{B}");
65922defineMacro("\u2130", "\\mathscr{E}");
65923defineMacro("\u2131", "\\mathscr{F}");
65924defineMacro("\u210B", "\\mathscr{H}");
65925defineMacro("\u2110", "\\mathscr{I}");
65926defineMacro("\u2112", "\\mathscr{L}");
65927defineMacro("\u2133", "\\mathscr{M}");
65928defineMacro("\u211B", "\\mathscr{R}");
65929defineMacro("\u212D", "\\mathfrak{C}");
65930defineMacro("\u210C", "\\mathfrak{H}");
65931defineMacro("\u2128", "\\mathfrak{Z}");
65932defineMacro("\\Bbbk", "\\Bbb{k}");
65933defineMacro("\xB7", "\\cdotp");
65934defineMacro("\\llap", "\\mathllap{\\textrm{#1}}");
65935defineMacro("\\rlap", "\\mathrlap{\\textrm{#1}}");
65936defineMacro("\\clap", "\\mathclap{\\textrm{#1}}");
65937defineMacro("\\mathstrut", "\\vphantom{(}");
65938defineMacro("\\underbar", "\\underline{\\text{#1}}");
65939defineMacro("\\not", '\\html@mathml{\\mathrel{\\mathrlap\\@not}}{\\char"338}');
65940defineMacro("\\neq", "\\html@mathml{\\mathrel{\\not=}}{\\mathrel{\\char`\u2260}}");
65941defineMacro("\\ne", "\\neq");
65942defineMacro("\u2260", "\\neq");
65943defineMacro("\\notin", "\\html@mathml{\\mathrel{{\\in}\\mathllap{/\\mskip1mu}}}{\\mathrel{\\char`\u2209}}");
65944defineMacro("\u2209", "\\notin");
65945defineMacro("\u2258", "\\html@mathml{\\mathrel{=\\kern{-1em}\\raisebox{0.4em}{$\\scriptsize\\frown$}}}{\\mathrel{\\char`\u2258}}");
65946defineMacro("\u2259", "\\html@mathml{\\stackrel{\\tiny\\wedge}{=}}{\\mathrel{\\char`\u2258}}");
65947defineMacro("\u225A", "\\html@mathml{\\stackrel{\\tiny\\vee}{=}}{\\mathrel{\\char`\u225A}}");
65948defineMacro("\u225B", "\\html@mathml{\\stackrel{\\scriptsize\\star}{=}}{\\mathrel{\\char`\u225B}}");
65949defineMacro("\u225D", "\\html@mathml{\\stackrel{\\tiny\\mathrm{def}}{=}}{\\mathrel{\\char`\u225D}}");
65950defineMacro("\u225E", "\\html@mathml{\\stackrel{\\tiny\\mathrm{m}}{=}}{\\mathrel{\\char`\u225E}}");
65951defineMacro("\u225F", "\\html@mathml{\\stackrel{\\tiny?}{=}}{\\mathrel{\\char`\u225F}}");
65952defineMacro("\u27C2", "\\perp");
65953defineMacro("\u203C", "\\mathclose{!\\mkern-0.8mu!}");
65954defineMacro("\u220C", "\\notni");
65955defineMacro("\u231C", "\\ulcorner");
65956defineMacro("\u231D", "\\urcorner");
65957defineMacro("\u231E", "\\llcorner");
65958defineMacro("\u231F", "\\lrcorner");
65959defineMacro("\xA9", "\\copyright");
65960defineMacro("\xAE", "\\textregistered");
65961defineMacro("\uFE0F", "\\textregistered");
65962defineMacro("\\ulcorner", '\\html@mathml{\\@ulcorner}{\\mathop{\\char"231c}}');
65963defineMacro("\\urcorner", '\\html@mathml{\\@urcorner}{\\mathop{\\char"231d}}');
65964defineMacro("\\llcorner", '\\html@mathml{\\@llcorner}{\\mathop{\\char"231e}}');
65965defineMacro("\\lrcorner", '\\html@mathml{\\@lrcorner}{\\mathop{\\char"231f}}');
65966defineMacro("\\vdots", "{\\varvdots\\rule{0pt}{15pt}}");
65967defineMacro("\u22EE", "\\vdots");
65968defineMacro("\\varGamma", "\\mathit{\\Gamma}");
65969defineMacro("\\varDelta", "\\mathit{\\Delta}");
65970defineMacro("\\varTheta", "\\mathit{\\Theta}");
65971defineMacro("\\varLambda", "\\mathit{\\Lambda}");
65972defineMacro("\\varXi", "\\mathit{\\Xi}");
65973defineMacro("\\varPi", "\\mathit{\\Pi}");
65974defineMacro("\\varSigma", "\\mathit{\\Sigma}");
65975defineMacro("\\varUpsilon", "\\mathit{\\Upsilon}");
65976defineMacro("\\varPhi", "\\mathit{\\Phi}");
65977defineMacro("\\varPsi", "\\mathit{\\Psi}");
65978defineMacro("\\varOmega", "\\mathit{\\Omega}");
65979defineMacro("\\substack", "\\begin{subarray}{c}#1\\end{subarray}");
65980defineMacro("\\colon", "\\nobreak\\mskip2mu\\mathpunct{}\\mathchoice{\\mkern-3mu}{\\mkern-3mu}{}{}{:}\\mskip6mu\\relax");
65981defineMacro("\\boxed", "\\fbox{$\\displaystyle{#1}$}");
65982defineMacro("\\iff", "\\DOTSB\\;\\Longleftrightarrow\\;");
65983defineMacro("\\implies", "\\DOTSB\\;\\Longrightarrow\\;");
65984defineMacro("\\impliedby", "\\DOTSB\\;\\Longleftarrow\\;");
65985defineMacro("\\dddot", "{\\overset{\\raisebox{-0.1ex}{\\normalsize ...}}{#1}}");
65986defineMacro("\\ddddot", "{\\overset{\\raisebox{-0.1ex}{\\normalsize ....}}{#1}}");
65987var dotsByToken = {
65988  ",": "\\dotsc",
65989  "\\not": "\\dotsb",
65990  // \keybin@ checks for the following:
65991  "+": "\\dotsb",
65992  "=": "\\dotsb",
65993  "<": "\\dotsb",
65994  ">": "\\dotsb",
65995  "-": "\\dotsb",
65996  "*": "\\dotsb",
65997  ":": "\\dotsb",
65998  // Symbols whose definition starts with \DOTSB:
65999  "\\DOTSB": "\\dotsb",
66000  "\\coprod": "\\dotsb",
66001  "\\bigvee": "\\dotsb",
66002  "\\bigwedge": "\\dotsb",
66003  "\\biguplus": "\\dotsb",
66004  "\\bigcap": "\\dotsb",
66005  "\\bigcup": "\\dotsb",
66006  "\\prod": "\\dotsb",
66007  "\\sum": "\\dotsb",
66008  "\\bigotimes": "\\dotsb",
66009  "\\bigoplus": "\\dotsb",
66010  "\\bigodot": "\\dotsb",
66011  "\\bigsqcup": "\\dotsb",
66012  "\\And": "\\dotsb",
66013  "\\longrightarrow": "\\dotsb",
66014  "\\Longrightarrow": "\\dotsb",
66015  "\\longleftarrow": "\\dotsb",
66016  "\\Longleftarrow": "\\dotsb",
66017  "\\longleftrightarrow": "\\dotsb",
66018  "\\Longleftrightarrow": "\\dotsb",
66019  "\\mapsto": "\\dotsb",
66020  "\\longmapsto": "\\dotsb",
66021  "\\hookrightarrow": "\\dotsb",
66022  "\\doteq": "\\dotsb",
66023  // Symbols whose definition starts with \mathbin:
66024  "\\mathbin": "\\dotsb",
66025  // Symbols whose definition starts with \mathrel:
66026  "\\mathrel": "\\dotsb",
66027  "\\relbar": "\\dotsb",
66028  "\\Relbar": "\\dotsb",
66029  "\\xrightarrow": "\\dotsb",
66030  "\\xleftarrow": "\\dotsb",
66031  // Symbols whose definition starts with \DOTSI:
66032  "\\DOTSI": "\\dotsi",
66033  "\\int": "\\dotsi",
66034  "\\oint": "\\dotsi",
66035  "\\iint": "\\dotsi",
66036  "\\iiint": "\\dotsi",
66037  "\\iiiint": "\\dotsi",
66038  "\\idotsint": "\\dotsi",
66039  // Symbols whose definition starts with \DOTSX:
66040  "\\DOTSX": "\\dotsx"
66041};
66042defineMacro("\\dots", function(context) {
66043  var thedots = "\\dotso";
66044  var next = context.expandAfterFuture().text;
66045  if (next in dotsByToken) {
66046    thedots = dotsByToken[next];
66047  } else if (next.slice(0, 4) === "\\not") {
66048    thedots = "\\dotsb";
66049  } else if (next in symbols.math) {
66050    if (utils.contains(["bin", "rel"], symbols.math[next].group)) {
66051      thedots = "\\dotsb";
66052    }
66053  }
66054  return thedots;
66055});
66056var spaceAfterDots = {
66057  // \rightdelim@ checks for the following:
66058  ")": true,
66059  "]": true,
66060  "\\rbrack": true,
66061  "\\}": true,
66062  "\\rbrace": true,
66063  "\\rangle": true,
66064  "\\rceil": true,
66065  "\\rfloor": true,
66066  "\\rgroup": true,
66067  "\\rmoustache": true,
66068  "\\right": true,
66069  "\\bigr": true,
66070  "\\biggr": true,
66071  "\\Bigr": true,
66072  "\\Biggr": true,
66073  // \extra@ also tests for the following:
66074  "$": true,
66075  // \extrap@ checks for the following:
66076  ";": true,
66077  ".": true,
66078  ",": true
66079};
66080defineMacro("\\dotso", function(context) {
66081  var next = context.future().text;
66082  if (next in spaceAfterDots) {
66083    return "\\ldots\\,";
66084  } else {
66085    return "\\ldots";
66086  }
66087});
66088defineMacro("\\dotsc", function(context) {
66089  var next = context.future().text;
66090  if (next in spaceAfterDots && next !== ",") {
66091    return "\\ldots\\,";
66092  } else {
66093    return "\\ldots";
66094  }
66095});
66096defineMacro("\\cdots", function(context) {
66097  var next = context.future().text;
66098  if (next in spaceAfterDots) {
66099    return "\\@cdots\\,";
66100  } else {
66101    return "\\@cdots";
66102  }
66103});
66104defineMacro("\\dotsb", "\\cdots");
66105defineMacro("\\dotsm", "\\cdots");
66106defineMacro("\\dotsi", "\\!\\cdots");
66107defineMacro("\\dotsx", "\\ldots\\,");
66108defineMacro("\\DOTSI", "\\relax");
66109defineMacro("\\DOTSB", "\\relax");
66110defineMacro("\\DOTSX", "\\relax");
66111defineMacro("\\tmspace", "\\TextOrMath{\\kern#1#3}{\\mskip#1#2}\\relax");
66112defineMacro("\\,", "\\tmspace+{3mu}{.1667em}");
66113defineMacro("\\thinspace", "\\,");
66114defineMacro("\\>", "\\mskip{4mu}");
66115defineMacro("\\:", "\\tmspace+{4mu}{.2222em}");
66116defineMacro("\\medspace", "\\:");
66117defineMacro("\\;", "\\tmspace+{5mu}{.2777em}");
66118defineMacro("\\thickspace", "\\;");
66119defineMacro("\\!", "\\tmspace-{3mu}{.1667em}");
66120defineMacro("\\negthinspace", "\\!");
66121defineMacro("\\negmedspace", "\\tmspace-{4mu}{.2222em}");
66122defineMacro("\\negthickspace", "\\tmspace-{5mu}{.277em}");
66123defineMacro("\\enspace", "\\kern.5em ");
66124defineMacro("\\enskip", "\\hskip.5em\\relax");
66125defineMacro("\\quad", "\\hskip1em\\relax");
66126defineMacro("\\qquad", "\\hskip2em\\relax");
66127defineMacro("\\tag", "\\@ifstar\\tag@literal\\tag@paren");
66128defineMacro("\\tag@paren", "\\tag@literal{({#1})}");
66129defineMacro("\\tag@literal", (context) => {
66130  if (context.macros.get("\\df@tag")) {
66131    throw new ParseError("Multiple \\tag");
66132  }
66133  return "\\gdef\\df@tag{\\text{#1}}";
66134});
66135defineMacro("\\bmod", "\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}\\mathbin{\\rm mod}\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}");
66136defineMacro("\\pod", "\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern8mu}{\\mkern8mu}{\\mkern8mu}(#1)");
66137defineMacro("\\pmod", "\\pod{{\\rm mod}\\mkern6mu#1}");
66138defineMacro("\\mod", "\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern12mu}{\\mkern12mu}{\\mkern12mu}{\\rm mod}\\,\\,#1");
66139defineMacro("\\newline", "\\\\\\relax");
66140defineMacro("\\TeX", "\\textrm{\\html@mathml{T\\kern-.1667em\\raisebox{-.5ex}{E}\\kern-.125emX}{TeX}}");
66141var latexRaiseA = makeEm(fontMetricsData["Main-Regular"]["T".charCodeAt(0)][1] - 0.7 * fontMetricsData["Main-Regular"]["A".charCodeAt(0)][1]);
66142defineMacro("\\LaTeX", "\\textrm{\\html@mathml{" + ("L\\kern-.36em\\raisebox{" + latexRaiseA + "}{\\scriptstyle A}") + "\\kern-.15em\\TeX}{LaTeX}}");
66143defineMacro("\\KaTeX", "\\textrm{\\html@mathml{" + ("K\\kern-.17em\\raisebox{" + latexRaiseA + "}{\\scriptstyle A}") + "\\kern-.15em\\TeX}{KaTeX}}");
66144defineMacro("\\hspace", "\\@ifstar\\@hspacer\\@hspace");
66145defineMacro("\\@hspace", "\\hskip #1\\relax");
66146defineMacro("\\@hspacer", "\\rule{0pt}{0pt}\\hskip #1\\relax");
66147defineMacro("\\ordinarycolon", ":");
66148defineMacro("\\vcentcolon", "\\mathrel{\\mathop\\ordinarycolon}");
66149defineMacro("\\dblcolon", '\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-.9mu}\\vcentcolon}}{\\mathop{\\char"2237}}');
66150defineMacro("\\coloneqq", '\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2254}}');
66151defineMacro("\\Coloneqq", '\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2237\\char"3d}}');
66152defineMacro("\\coloneq", '\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"3a\\char"2212}}');
66153defineMacro("\\Coloneq", '\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"2237\\char"2212}}');
66154defineMacro("\\eqqcolon", '\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2255}}');
66155defineMacro("\\Eqqcolon", '\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"3d\\char"2237}}');
66156defineMacro("\\eqcolon", '\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2239}}');
66157defineMacro("\\Eqcolon", '\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"2212\\char"2237}}');
66158defineMacro("\\colonapprox", '\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"3a\\char"2248}}');
66159defineMacro("\\Colonapprox", '\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"2237\\char"2248}}');
66160defineMacro("\\colonsim", '\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"3a\\char"223c}}');
66161defineMacro("\\Colonsim", '\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"2237\\char"223c}}');
66162defineMacro("\u2237", "\\dblcolon");
66163defineMacro("\u2239", "\\eqcolon");
66164defineMacro("\u2254", "\\coloneqq");
66165defineMacro("\u2255", "\\eqqcolon");
66166defineMacro("\u2A74", "\\Coloneqq");
66167defineMacro("\\ratio", "\\vcentcolon");
66168defineMacro("\\coloncolon", "\\dblcolon");
66169defineMacro("\\colonequals", "\\coloneqq");
66170defineMacro("\\coloncolonequals", "\\Coloneqq");
66171defineMacro("\\equalscolon", "\\eqqcolon");
66172defineMacro("\\equalscoloncolon", "\\Eqqcolon");
66173defineMacro("\\colonminus", "\\coloneq");
66174defineMacro("\\coloncolonminus", "\\Coloneq");
66175defineMacro("\\minuscolon", "\\eqcolon");
66176defineMacro("\\minuscoloncolon", "\\Eqcolon");
66177defineMacro("\\coloncolonapprox", "\\Colonapprox");
66178defineMacro("\\coloncolonsim", "\\Colonsim");
66179defineMacro("\\simcolon", "\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\vcentcolon}");
66180defineMacro("\\simcoloncolon", "\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\dblcolon}");
66181defineMacro("\\approxcolon", "\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\vcentcolon}");
66182defineMacro("\\approxcoloncolon", "\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\dblcolon}");
66183defineMacro("\\notni", "\\html@mathml{\\not\\ni}{\\mathrel{\\char`\u220C}}");
66184defineMacro("\\limsup", "\\DOTSB\\operatorname*{lim\\,sup}");
66185defineMacro("\\liminf", "\\DOTSB\\operatorname*{lim\\,inf}");
66186defineMacro("\\injlim", "\\DOTSB\\operatorname*{inj\\,lim}");
66187defineMacro("\\projlim", "\\DOTSB\\operatorname*{proj\\,lim}");
66188defineMacro("\\varlimsup", "\\DOTSB\\operatorname*{\\overline{lim}}");
66189defineMacro("\\varliminf", "\\DOTSB\\operatorname*{\\underline{lim}}");
66190defineMacro("\\varinjlim", "\\DOTSB\\operatorname*{\\underrightarrow{lim}}");
66191defineMacro("\\varprojlim", "\\DOTSB\\operatorname*{\\underleftarrow{lim}}");
66192defineMacro("\\gvertneqq", "\\html@mathml{\\@gvertneqq}{\u2269}");
66193defineMacro("\\lvertneqq", "\\html@mathml{\\@lvertneqq}{\u2268}");
66194defineMacro("\\ngeqq", "\\html@mathml{\\@ngeqq}{\u2271}");
66195defineMacro("\\ngeqslant", "\\html@mathml{\\@ngeqslant}{\u2271}");
66196defineMacro("\\nleqq", "\\html@mathml{\\@nleqq}{\u2270}");
66197defineMacro("\\nleqslant", "\\html@mathml{\\@nleqslant}{\u2270}");
66198defineMacro("\\nshortmid", "\\html@mathml{\\@nshortmid}{\u2224}");
66199defineMacro("\\nshortparallel", "\\html@mathml{\\@nshortparallel}{\u2226}");
66200defineMacro("\\nsubseteqq", "\\html@mathml{\\@nsubseteqq}{\u2288}");
66201defineMacro("\\nsupseteqq", "\\html@mathml{\\@nsupseteqq}{\u2289}");
66202defineMacro("\\varsubsetneq", "\\html@mathml{\\@varsubsetneq}{\u228A}");
66203defineMacro("\\varsubsetneqq", "\\html@mathml{\\@varsubsetneqq}{\u2ACB}");
66204defineMacro("\\varsupsetneq", "\\html@mathml{\\@varsupsetneq}{\u228B}");
66205defineMacro("\\varsupsetneqq", "\\html@mathml{\\@varsupsetneqq}{\u2ACC}");
66206defineMacro("\\imath", "\\html@mathml{\\@imath}{\u0131}");
66207defineMacro("\\jmath", "\\html@mathml{\\@jmath}{\u0237}");
66208defineMacro("\\llbracket", "\\html@mathml{\\mathopen{[\\mkern-3.2mu[}}{\\mathopen{\\char`\u27E6}}");
66209defineMacro("\\rrbracket", "\\html@mathml{\\mathclose{]\\mkern-3.2mu]}}{\\mathclose{\\char`\u27E7}}");
66210defineMacro("\u27E6", "\\llbracket");
66211defineMacro("\u27E7", "\\rrbracket");
66212defineMacro("\\lBrace", "\\html@mathml{\\mathopen{\\{\\mkern-3.2mu[}}{\\mathopen{\\char`\u2983}}");
66213defineMacro("\\rBrace", "\\html@mathml{\\mathclose{]\\mkern-3.2mu\\}}}{\\mathclose{\\char`\u2984}}");
66214defineMacro("\u2983", "\\lBrace");
66215defineMacro("\u2984", "\\rBrace");
66216defineMacro("\\minuso", "\\mathbin{\\html@mathml{{\\mathrlap{\\mathchoice{\\kern{0.145em}}{\\kern{0.145em}}{\\kern{0.1015em}}{\\kern{0.0725em}}\\circ}{-}}}{\\char`\u29B5}}");
66217defineMacro("\u29B5", "\\minuso");
66218defineMacro("\\darr", "\\downarrow");
66219defineMacro("\\dArr", "\\Downarrow");
66220defineMacro("\\Darr", "\\Downarrow");
66221defineMacro("\\lang", "\\langle");
66222defineMacro("\\rang", "\\rangle");
66223defineMacro("\\uarr", "\\uparrow");
66224defineMacro("\\uArr", "\\Uparrow");
66225defineMacro("\\Uarr", "\\Uparrow");
66226defineMacro("\\N", "\\mathbb{N}");
66227defineMacro("\\R", "\\mathbb{R}");
66228defineMacro("\\Z", "\\mathbb{Z}");
66229defineMacro("\\alef", "\\aleph");
66230defineMacro("\\alefsym", "\\aleph");
66231defineMacro("\\Alpha", "\\mathrm{A}");
66232defineMacro("\\Beta", "\\mathrm{B}");
66233defineMacro("\\bull", "\\bullet");
66234defineMacro("\\Chi", "\\mathrm{X}");
66235defineMacro("\\clubs", "\\clubsuit");
66236defineMacro("\\cnums", "\\mathbb{C}");
66237defineMacro("\\Complex", "\\mathbb{C}");
66238defineMacro("\\Dagger", "\\ddagger");
66239defineMacro("\\diamonds", "\\diamondsuit");
66240defineMacro("\\empty", "\\emptyset");
66241defineMacro("\\Epsilon", "\\mathrm{E}");
66242defineMacro("\\Eta", "\\mathrm{H}");
66243defineMacro("\\exist", "\\exists");
66244defineMacro("\\harr", "\\leftrightarrow");
66245defineMacro("\\hArr", "\\Leftrightarrow");
66246defineMacro("\\Harr", "\\Leftrightarrow");
66247defineMacro("\\hearts", "\\heartsuit");
66248defineMacro("\\image", "\\Im");
66249defineMacro("\\infin", "\\infty");
66250defineMacro("\\Iota", "\\mathrm{I}");
66251defineMacro("\\isin", "\\in");
66252defineMacro("\\Kappa", "\\mathrm{K}");
66253defineMacro("\\larr", "\\leftarrow");
66254defineMacro("\\lArr", "\\Leftarrow");
66255defineMacro("\\Larr", "\\Leftarrow");
66256defineMacro("\\lrarr", "\\leftrightarrow");
66257defineMacro("\\lrArr", "\\Leftrightarrow");
66258defineMacro("\\Lrarr", "\\Leftrightarrow");
66259defineMacro("\\Mu", "\\mathrm{M}");
66260defineMacro("\\natnums", "\\mathbb{N}");
66261defineMacro("\\Nu", "\\mathrm{N}");
66262defineMacro("\\Omicron", "\\mathrm{O}");
66263defineMacro("\\plusmn", "\\pm");
66264defineMacro("\\rarr", "\\rightarrow");
66265defineMacro("\\rArr", "\\Rightarrow");
66266defineMacro("\\Rarr", "\\Rightarrow");
66267defineMacro("\\real", "\\Re");
66268defineMacro("\\reals", "\\mathbb{R}");
66269defineMacro("\\Reals", "\\mathbb{R}");
66270defineMacro("\\Rho", "\\mathrm{P}");
66271defineMacro("\\sdot", "\\cdot");
66272defineMacro("\\sect", "\\S");
66273defineMacro("\\spades", "\\spadesuit");
66274defineMacro("\\sub", "\\subset");
66275defineMacro("\\sube", "\\subseteq");
66276defineMacro("\\supe", "\\supseteq");
66277defineMacro("\\Tau", "\\mathrm{T}");
66278defineMacro("\\thetasym", "\\vartheta");
66279defineMacro("\\weierp", "\\wp");
66280defineMacro("\\Zeta", "\\mathrm{Z}");
66281defineMacro("\\argmin", "\\DOTSB\\operatorname*{arg\\,min}");
66282defineMacro("\\argmax", "\\DOTSB\\operatorname*{arg\\,max}");
66283defineMacro("\\plim", "\\DOTSB\\mathop{\\operatorname{plim}}\\limits");
66284defineMacro("\\bra", "\\mathinner{\\langle{#1}|}");
66285defineMacro("\\ket", "\\mathinner{|{#1}\\rangle}");
66286defineMacro("\\braket", "\\mathinner{\\langle{#1}\\rangle}");
66287defineMacro("\\Bra", "\\left\\langle#1\\right|");
66288defineMacro("\\Ket", "\\left|#1\\right\\rangle");
66289var braketHelper = (one) => (context) => {
66290  var left = context.consumeArg().tokens;
66291  var middle = context.consumeArg().tokens;
66292  var middleDouble = context.consumeArg().tokens;
66293  var right = context.consumeArg().tokens;
66294  var oldMiddle = context.macros.get("|");
66295  var oldMiddleDouble = context.macros.get("\\|");
66296  context.macros.beginGroup();
66297  var midMacro = (double) => (context2) => {
66298    if (one) {
66299      context2.macros.set("|", oldMiddle);
66300      if (middleDouble.length) {
66301        context2.macros.set("\\|", oldMiddleDouble);
66302      }
66303    }
66304    var doubled = double;
66305    if (!double && middleDouble.length) {
66306      var nextToken = context2.future();
66307      if (nextToken.text === "|") {
66308        context2.popToken();
66309        doubled = true;
66310      }
66311    }
66312    return {
66313      tokens: doubled ? middleDouble : middle,
66314      numArgs: 0
66315    };
66316  };
66317  context.macros.set("|", midMacro(false));
66318  if (middleDouble.length) {
66319    context.macros.set("\\|", midMacro(true));
66320  }
66321  var arg = context.consumeArg().tokens;
66322  var expanded = context.expandTokens([
66323    ...right,
66324    ...arg,
66325    ...left
66326    // reversed
66327  ]);
66328  context.macros.endGroup();
66329  return {
66330    tokens: expanded.reverse(),
66331    numArgs: 0
66332  };
66333};
66334defineMacro("\\bra@ket", braketHelper(false));
66335defineMacro("\\bra@set", braketHelper(true));
66336defineMacro("\\Braket", "\\bra@ket{\\left\\langle}{\\,\\middle\\vert\\,}{\\,\\middle\\vert\\,}{\\right\\rangle}");
66337defineMacro("\\Set", "\\bra@set{\\left\\{\\:}{\\;\\middle\\vert\\;}{\\;\\middle\\Vert\\;}{\\:\\right\\}}");
66338defineMacro("\\set", "\\bra@set{\\{\\,}{\\mid}{}{\\,\\}}");
66339defineMacro("\\angln", "{\\angl n}");
66340defineMacro("\\blue", "\\textcolor{##6495ed}{#1}");
66341defineMacro("\\orange", "\\textcolor{##ffa500}{#1}");
66342defineMacro("\\pink", "\\textcolor{##ff00af}{#1}");
66343defineMacro("\\red", "\\textcolor{##df0030}{#1}");
66344defineMacro("\\green", "\\textcolor{##28ae7b}{#1}");
66345defineMacro("\\gray", "\\textcolor{gray}{#1}");
66346defineMacro("\\purple", "\\textcolor{##9d38bd}{#1}");
66347defineMacro("\\blueA", "\\textcolor{##ccfaff}{#1}");
66348defineMacro("\\blueB", "\\textcolor{##80f6ff}{#1}");
66349defineMacro("\\blueC", "\\textcolor{##63d9ea}{#1}");
66350defineMacro("\\blueD", "\\textcolor{##11accd}{#1}");
66351defineMacro("\\blueE", "\\textcolor{##0c7f99}{#1}");
66352defineMacro("\\tealA", "\\textcolor{##94fff5}{#1}");
66353defineMacro("\\tealB", "\\textcolor{##26edd5}{#1}");
66354defineMacro("\\tealC", "\\textcolor{##01d1c1}{#1}");
66355defineMacro("\\tealD", "\\textcolor{##01a995}{#1}");
66356defineMacro("\\tealE", "\\textcolor{##208170}{#1}");
66357defineMacro("\\greenA", "\\textcolor{##b6ffb0}{#1}");
66358defineMacro("\\greenB", "\\textcolor{##8af281}{#1}");
66359defineMacro("\\greenC", "\\textcolor{##74cf70}{#1}");
66360defineMacro("\\greenD", "\\textcolor{##1fab54}{#1}");
66361defineMacro("\\greenE", "\\textcolor{##0d923f}{#1}");
66362defineMacro("\\goldA", "\\textcolor{##ffd0a9}{#1}");
66363defineMacro("\\goldB", "\\textcolor{##ffbb71}{#1}");
66364defineMacro("\\goldC", "\\textcolor{##ff9c39}{#1}");
66365defineMacro("\\goldD", "\\textcolor{##e07d10}{#1}");
66366defineMacro("\\goldE", "\\textcolor{##a75a05}{#1}");
66367defineMacro("\\redA", "\\textcolor{##fca9a9}{#1}");
66368defineMacro("\\redB", "\\textcolor{##ff8482}{#1}");
66369defineMacro("\\redC", "\\textcolor{##f9685d}{#1}");
66370defineMacro("\\redD", "\\textcolor{##e84d39}{#1}");
66371defineMacro("\\redE", "\\textcolor{##bc2612}{#1}");
66372defineMacro("\\maroonA", "\\textcolor{##ffbde0}{#1}");
66373defineMacro("\\maroonB", "\\textcolor{##ff92c6}{#1}");
66374defineMacro("\\maroonC", "\\textcolor{##ed5fa6}{#1}");
66375defineMacro("\\maroonD", "\\textcolor{##ca337c}{#1}");
66376defineMacro("\\maroonE", "\\textcolor{##9e034e}{#1}");
66377defineMacro("\\purpleA", "\\textcolor{##ddd7ff}{#1}");
66378defineMacro("\\purpleB", "\\textcolor{##c6b9fc}{#1}");
66379defineMacro("\\purpleC", "\\textcolor{##aa87ff}{#1}");
66380defineMacro("\\purpleD", "\\textcolor{##7854ab}{#1}");
66381defineMacro("\\purpleE", "\\textcolor{##543b78}{#1}");
66382defineMacro("\\mintA", "\\textcolor{##f5f9e8}{#1}");
66383defineMacro("\\mintB", "\\textcolor{##edf2df}{#1}");
66384defineMacro("\\mintC", "\\textcolor{##e0e5cc}{#1}");
66385defineMacro("\\grayA", "\\textcolor{##f6f7f7}{#1}");
66386defineMacro("\\grayB", "\\textcolor{##f0f1f2}{#1}");
66387defineMacro("\\grayC", "\\textcolor{##e3e5e6}{#1}");
66388defineMacro("\\grayD", "\\textcolor{##d6d8da}{#1}");
66389defineMacro("\\grayE", "\\textcolor{##babec2}{#1}");
66390defineMacro("\\grayF", "\\textcolor{##888d93}{#1}");
66391defineMacro("\\grayG", "\\textcolor{##626569}{#1}");
66392defineMacro("\\grayH", "\\textcolor{##3b3e40}{#1}");
66393defineMacro("\\grayI", "\\textcolor{##21242c}{#1}");
66394defineMacro("\\kaBlue", "\\textcolor{##314453}{#1}");
66395defineMacro("\\kaGreen", "\\textcolor{##71B307}{#1}");
66396var implicitCommands = {
66397  "^": true,
66398  // Parser.js
66399  "_": true,
66400  // Parser.js
66401  "\\limits": true,
66402  // Parser.js
66403  "\\nolimits": true
66404  // Parser.js
66405};
66406var MacroExpander = class {
66407  constructor(input2, settings, mode) {
66408    this.settings = void 0;
66409    this.expansionCount = void 0;
66410    this.lexer = void 0;
66411    this.macros = void 0;
66412    this.stack = void 0;
66413    this.mode = void 0;
66414    this.settings = settings;
66415    this.expansionCount = 0;
66416    this.feed(input2);
66417    this.macros = new Namespace(macros, settings.macros);
66418    this.mode = mode;
66419    this.stack = [];
66420  }
66421  /**
66422   * Feed a new input string to the same MacroExpander
66423   * (with existing macros etc.).
66424   */
66425  feed(input2) {
66426    this.lexer = new Lexer(input2, this.settings);
66427  }
66428  /**
66429   * Switches between "text" and "math" modes.
66430   */
66431  switchMode(newMode) {
66432    this.mode = newMode;
66433  }
66434  /**
66435   * Start a new group nesting within all namespaces.
66436   */
66437  beginGroup() {
66438    this.macros.beginGroup();
66439  }
66440  /**
66441   * End current group nesting within all namespaces.
66442   */
66443  endGroup() {
66444    this.macros.endGroup();
66445  }
66446  /**
66447   * Ends all currently nested groups (if any), restoring values before the
66448   * groups began.  Useful in case of an error in the middle of parsing.
66449   */
66450  endGroups() {
66451    this.macros.endGroups();
66452  }
66453  /**
66454   * Returns the topmost token on the stack, without expanding it.
66455   * Similar in behavior to TeX's `\futurelet`.
66456   */
66457  future() {
66458    if (this.stack.length === 0) {
66459      this.pushToken(this.lexer.lex());
66460    }
66461    return this.stack[this.stack.length - 1];
66462  }
66463  /**
66464   * Remove and return the next unexpanded token.
66465   */
66466  popToken() {
66467    this.future();
66468    return this.stack.pop();
66469  }
66470  /**
66471   * Add a given token to the token stack.  In particular, this get be used
66472   * to put back a token returned from one of the other methods.
66473   */
66474  pushToken(token) {
66475    this.stack.push(token);
66476  }
66477  /**
66478   * Append an array of tokens to the token stack.
66479   */
66480  pushTokens(tokens) {
66481    this.stack.push(...tokens);
66482  }
66483  /**
66484   * Find an macro argument without expanding tokens and append the array of
66485   * tokens to the token stack. Uses Token as a container for the result.
66486   */
66487  scanArgument(isOptional) {
66488    var start;
66489    var end;
66490    var tokens;
66491    if (isOptional) {
66492      this.consumeSpaces();
66493      if (this.future().text !== "[") {
66494        return null;
66495      }
66496      start = this.popToken();
66497      ({
66498        tokens,
66499        end
66500      } = this.consumeArg(["]"]));
66501    } else {
66502      ({
66503        tokens,
66504        start,
66505        end
66506      } = this.consumeArg());
66507    }
66508    this.pushToken(new Token("EOF", end.loc));
66509    this.pushTokens(tokens);
66510    return start.range(end, "");
66511  }
66512  /**
66513   * Consume all following space tokens, without expansion.
66514   */
66515  consumeSpaces() {
66516    for (; ; ) {
66517      var token = this.future();
66518      if (token.text === " ") {
66519        this.stack.pop();
66520      } else {
66521        break;
66522      }
66523    }
66524  }
66525  /**
66526   * Consume an argument from the token stream, and return the resulting array
66527   * of tokens and start/end token.
66528   */
66529  consumeArg(delims) {
66530    var tokens = [];
66531    var isDelimited = delims && delims.length > 0;
66532    if (!isDelimited) {
66533      this.consumeSpaces();
66534    }
66535    var start = this.future();
66536    var tok;
66537    var depth = 0;
66538    var match = 0;
66539    do {
66540      tok = this.popToken();
66541      tokens.push(tok);
66542      if (tok.text === "{") {
66543        ++depth;
66544      } else if (tok.text === "}") {
66545        --depth;
66546        if (depth === -1) {
66547          throw new ParseError("Extra }", tok);
66548        }
66549      } else if (tok.text === "EOF") {
66550        throw new ParseError("Unexpected end of input in a macro argument, expected '" + (delims && isDelimited ? delims[match] : "}") + "'", tok);
66551      }
66552      if (delims && isDelimited) {
66553        if ((depth === 0 || depth === 1 && delims[match] === "{") && tok.text === delims[match]) {
66554          ++match;
66555          if (match === delims.length) {
66556            tokens.splice(-match, match);
66557            break;
66558          }
66559        } else {
66560          match = 0;
66561        }
66562      }
66563    } while (depth !== 0 || isDelimited);
66564    if (start.text === "{" && tokens[tokens.length - 1].text === "}") {
66565      tokens.pop();
66566      tokens.shift();
66567    }
66568    tokens.reverse();
66569    return {
66570      tokens,
66571      start,
66572      end: tok
66573    };
66574  }
66575  /**
66576   * Consume the specified number of (delimited) arguments from the token
66577   * stream and return the resulting array of arguments.
66578   */
66579  consumeArgs(numArgs, delimiters2) {
66580    if (delimiters2) {
66581      if (delimiters2.length !== numArgs + 1) {
66582        throw new ParseError("The length of delimiters doesn't match the number of args!");
66583      }
66584      var delims = delimiters2[0];
66585      for (var i = 0; i < delims.length; i++) {
66586        var tok = this.popToken();
66587        if (delims[i] !== tok.text) {
66588          throw new ParseError("Use of the macro doesn't match its definition", tok);
66589        }
66590      }
66591    }
66592    var args = [];
66593    for (var _i = 0; _i < numArgs; _i++) {
66594      args.push(this.consumeArg(delimiters2 && delimiters2[_i + 1]).tokens);
66595    }
66596    return args;
66597  }
66598  /**
66599   * Increment `expansionCount` by the specified amount.
66600   * Throw an error if it exceeds `maxExpand`.
66601   */
66602  countExpansion(amount) {
66603    this.expansionCount += amount;
66604    if (this.expansionCount > this.settings.maxExpand) {
66605      throw new ParseError("Too many expansions: infinite loop or need to increase maxExpand setting");
66606    }
66607  }
66608  /**
66609   * Expand the next token only once if possible.
66610   *
66611   * If the token is expanded, the resulting tokens will be pushed onto
66612   * the stack in reverse order, and the number of such tokens will be
66613   * returned.  This number might be zero or positive.
66614   *
66615   * If not, the return value is `false`, and the next token remains at the
66616   * top of the stack.
66617   *
66618   * In either case, the next token will be on the top of the stack,
66619   * or the stack will be empty (in case of empty expansion
66620   * and no other tokens).
66621   *
66622   * Used to implement `expandAfterFuture` and `expandNextToken`.
66623   *
66624   * If expandableOnly, only expandable tokens are expanded and
66625   * an undefined control sequence results in an error.
66626   */
66627  expandOnce(expandableOnly) {
66628    var topToken = this.popToken();
66629    var name = topToken.text;
66630    var expansion = !topToken.noexpand ? this._getExpansion(name) : null;
66631    if (expansion == null || expandableOnly && expansion.unexpandable) {
66632      if (expandableOnly && expansion == null && name[0] === "\\" && !this.isDefined(name)) {
66633        throw new ParseError("Undefined control sequence: " + name);
66634      }
66635      this.pushToken(topToken);
66636      return false;
66637    }
66638    this.countExpansion(1);
66639    var tokens = expansion.tokens;
66640    var args = this.consumeArgs(expansion.numArgs, expansion.delimiters);
66641    if (expansion.numArgs) {
66642      tokens = tokens.slice();
66643      for (var i = tokens.length - 1; i >= 0; --i) {
66644        var tok = tokens[i];
66645        if (tok.text === "#") {
66646          if (i === 0) {
66647            throw new ParseError("Incomplete placeholder at end of macro body", tok);
66648          }
66649          tok = tokens[--i];
66650          if (tok.text === "#") {
66651            tokens.splice(i + 1, 1);
66652          } else if (/^[1-9]$/.test(tok.text)) {
66653            tokens.splice(i, 2, ...args[+tok.text - 1]);
66654          } else {
66655            throw new ParseError("Not a valid argument number", tok);
66656          }
66657        }
66658      }
66659    }
66660    this.pushTokens(tokens);
66661    return tokens.length;
66662  }
66663  /**
66664   * Expand the next token only once (if possible), and return the resulting
66665   * top token on the stack (without removing anything from the stack).
66666   * Similar in behavior to TeX's `\expandafter\futurelet`.
66667   * Equivalent to expandOnce() followed by future().
66668   */
66669  expandAfterFuture() {
66670    this.expandOnce();
66671    return this.future();
66672  }
66673  /**
66674   * Recursively expand first token, then return first non-expandable token.
66675   */
66676  expandNextToken() {
66677    for (; ; ) {
66678      if (this.expandOnce() === false) {
66679        var token = this.stack.pop();
66680        if (token.treatAsRelax) {
66681          token.text = "\\relax";
66682        }
66683        return token;
66684      }
66685    }
66686    throw new Error();
66687  }
66688  /**
66689   * Fully expand the given macro name and return the resulting list of
66690   * tokens, or return `undefined` if no such macro is defined.
66691   */
66692  expandMacro(name) {
66693    return this.macros.has(name) ? this.expandTokens([new Token(name)]) : void 0;
66694  }
66695  /**
66696   * Fully expand the given token stream and return the resulting list of
66697   * tokens.  Note that the input tokens are in reverse order, but the
66698   * output tokens are in forward order.
66699   */
66700  expandTokens(tokens) {
66701    var output = [];
66702    var oldStackLength = this.stack.length;
66703    this.pushTokens(tokens);
66704    while (this.stack.length > oldStackLength) {
66705      if (this.expandOnce(true) === false) {
66706        var token = this.stack.pop();
66707        if (token.treatAsRelax) {
66708          token.noexpand = false;
66709          token.treatAsRelax = false;
66710        }
66711        output.push(token);
66712      }
66713    }
66714    this.countExpansion(output.length);
66715    return output;
66716  }
66717  /**
66718   * Fully expand the given macro name and return the result as a string,
66719   * or return `undefined` if no such macro is defined.
66720   */
66721  expandMacroAsText(name) {
66722    var tokens = this.expandMacro(name);
66723    if (tokens) {
66724      return tokens.map((token) => token.text).join("");
66725    } else {
66726      return tokens;
66727    }
66728  }
66729  /**
66730   * Returns the expanded macro as a reversed array of tokens and a macro
66731   * argument count.  Or returns `null` if no such macro.
66732   */
66733  _getExpansion(name) {
66734    var definition = this.macros.get(name);
66735    if (definition == null) {
66736      return definition;
66737    }
66738    if (name.length === 1) {
66739      var catcode = this.lexer.catcodes[name];
66740      if (catcode != null && catcode !== 13) {
66741        return;
66742      }
66743    }
66744    var expansion = typeof definition === "function" ? definition(this) : definition;
66745    if (typeof expansion === "string") {
66746      var numArgs = 0;
66747      if (expansion.indexOf("#") !== -1) {
66748        var stripped = expansion.replace(/##/g, "");
66749        while (stripped.indexOf("#" + (numArgs + 1)) !== -1) {
66750          ++numArgs;
66751        }
66752      }
66753      var bodyLexer = new Lexer(expansion, this.settings);
66754      var tokens = [];
66755      var tok = bodyLexer.lex();
66756      while (tok.text !== "EOF") {
66757        tokens.push(tok);
66758        tok = bodyLexer.lex();
66759      }
66760      tokens.reverse();
66761      var expanded = {
66762        tokens,
66763        numArgs
66764      };
66765      return expanded;
66766    }
66767    return expansion;
66768  }
66769  /**
66770   * Determine whether a command is currently "defined" (has some
66771   * functionality), meaning that it's a macro (in the current group),
66772   * a function, a symbol, or one of the special commands listed in
66773   * `implicitCommands`.
66774   */
66775  isDefined(name) {
66776    return this.macros.has(name) || functions.hasOwnProperty(name) || symbols.math.hasOwnProperty(name) || symbols.text.hasOwnProperty(name) || implicitCommands.hasOwnProperty(name);
66777  }
66778  /**
66779   * Determine whether a command is expandable.
66780   */
66781  isExpandable(name) {
66782    var macro = this.macros.get(name);
66783    return macro != null ? typeof macro === "string" || typeof macro === "function" || !macro.unexpandable : functions.hasOwnProperty(name) && !functions[name].primitive;
66784  }
66785};
66786var unicodeSubRegEx = /^[₊₋₌₍₎₀₁₂₃₄₅₆₇₈₉ₐₑₕᵢⱼₖₗₘₙₒₚᵣₛₜᵤᵥₓᵦᵧᵨᵩᵪ]/;
66787var uSubsAndSups = Object.freeze({
66788  "\u208A": "+",
66789  "\u208B": "-",
66790  "\u208C": "=",
66791  "\u208D": "(",
66792  "\u208E": ")",
66793  "\u2080": "0",
66794  "\u2081": "1",
66795  "\u2082": "2",
66796  "\u2083": "3",
66797  "\u2084": "4",
66798  "\u2085": "5",
66799  "\u2086": "6",
66800  "\u2087": "7",
66801  "\u2088": "8",
66802  "\u2089": "9",
66803  "\u2090": "a",
66804  "\u2091": "e",
66805  "\u2095": "h",
66806  "\u1D62": "i",
66807  "\u2C7C": "j",
66808  "\u2096": "k",
66809  "\u2097": "l",
66810  "\u2098": "m",
66811  "\u2099": "n",
66812  "\u2092": "o",
66813  "\u209A": "p",
66814  "\u1D63": "r",
66815  "\u209B": "s",
66816  "\u209C": "t",
66817  "\u1D64": "u",
66818  "\u1D65": "v",
66819  "\u2093": "x",
66820  "\u1D66": "\u03B2",
66821  "\u1D67": "\u03B3",
66822  "\u1D68": "\u03C1",
66823  "\u1D69": "\u03D5",
66824  "\u1D6A": "\u03C7",
66825  "\u207A": "+",
66826  "\u207B": "-",
66827  "\u207C": "=",
66828  "\u207D": "(",
66829  "\u207E": ")",
66830  "\u2070": "0",
66831  "\xB9": "1",
66832  "\xB2": "2",
66833  "\xB3": "3",
66834  "\u2074": "4",
66835  "\u2075": "5",
66836  "\u2076": "6",
66837  "\u2077": "7",
66838  "\u2078": "8",
66839  "\u2079": "9",
66840  "\u1D2C": "A",
66841  "\u1D2E": "B",
66842  "\u1D30": "D",
66843  "\u1D31": "E",
66844  "\u1D33": "G",
66845  "\u1D34": "H",
66846  "\u1D35": "I",
66847  "\u1D36": "J",
66848  "\u1D37": "K",
66849  "\u1D38": "L",
66850  "\u1D39": "M",
66851  "\u1D3A": "N",
66852  "\u1D3C": "O",
66853  "\u1D3E": "P",
66854  "\u1D3F": "R",
66855  "\u1D40": "T",
66856  "\u1D41": "U",
66857  "\u2C7D": "V",
66858  "\u1D42": "W",
66859  "\u1D43": "a",
66860  "\u1D47": "b",
66861  "\u1D9C": "c",
66862  "\u1D48": "d",
66863  "\u1D49": "e",
66864  "\u1DA0": "f",
66865  "\u1D4D": "g",
66866  "\u02B0": "h",
66867  "\u2071": "i",
66868  "\u02B2": "j",
66869  "\u1D4F": "k",
66870  "\u02E1": "l",
66871  "\u1D50": "m",
66872  "\u207F": "n",
66873  "\u1D52": "o",
66874  "\u1D56": "p",
66875  "\u02B3": "r",
66876  "\u02E2": "s",
66877  "\u1D57": "t",
66878  "\u1D58": "u",
66879  "\u1D5B": "v",
66880  "\u02B7": "w",
66881  "\u02E3": "x",
66882  "\u02B8": "y",
66883  "\u1DBB": "z",
66884  "\u1D5D": "\u03B2",
66885  "\u1D5E": "\u03B3",
66886  "\u1D5F": "\u03B4",
66887  "\u1D60": "\u03D5",
66888  "\u1D61": "\u03C7",
66889  "\u1DBF": "\u03B8"
66890});
66891var unicodeAccents = {
66892  "\u0301": {
66893    "text": "\\'",
66894    "math": "\\acute"
66895  },
66896  "\u0300": {
66897    "text": "\\`",
66898    "math": "\\grave"
66899  },
66900  "\u0308": {
66901    "text": '\\"',
66902    "math": "\\ddot"
66903  },
66904  "\u0303": {
66905    "text": "\\~",
66906    "math": "\\tilde"
66907  },
66908  "\u0304": {
66909    "text": "\\=",
66910    "math": "\\bar"
66911  },
66912  "\u0306": {
66913    "text": "\\u",
66914    "math": "\\breve"
66915  },
66916  "\u030C": {
66917    "text": "\\v",
66918    "math": "\\check"
66919  },
66920  "\u0302": {
66921    "text": "\\^",
66922    "math": "\\hat"
66923  },
66924  "\u0307": {
66925    "text": "\\.",
66926    "math": "\\dot"
66927  },
66928  "\u030A": {
66929    "text": "\\r",
66930    "math": "\\mathring"
66931  },
66932  "\u030B": {
66933    "text": "\\H"
66934  },
66935  "\u0327": {
66936    "text": "\\c"
66937  }
66938};
66939var unicodeSymbols = {
66940  "\xE1": "a\u0301",
66941  "\xE0": "a\u0300",
66942  "\xE4": "a\u0308",
66943  "\u01DF": "a\u0308\u0304",
66944  "\xE3": "a\u0303",
66945  "\u0101": "a\u0304",
66946  "\u0103": "a\u0306",
66947  "\u1EAF": "a\u0306\u0301",
66948  "\u1EB1": "a\u0306\u0300",
66949  "\u1EB5": "a\u0306\u0303",
66950  "\u01CE": "a\u030C",
66951  "\xE2": "a\u0302",
66952  "\u1EA5": "a\u0302\u0301",
66953  "\u1EA7": "a\u0302\u0300",
66954  "\u1EAB": "a\u0302\u0303",
66955  "\u0227": "a\u0307",
66956  "\u01E1": "a\u0307\u0304",
66957  "\xE5": "a\u030A",
66958  "\u01FB": "a\u030A\u0301",
66959  "\u1E03": "b\u0307",
66960  "\u0107": "c\u0301",
66961  "\u1E09": "c\u0327\u0301",
66962  "\u010D": "c\u030C",
66963  "\u0109": "c\u0302",
66964  "\u010B": "c\u0307",
66965  "\xE7": "c\u0327",
66966  "\u010F": "d\u030C",
66967  "\u1E0B": "d\u0307",
66968  "\u1E11": "d\u0327",
66969  "\xE9": "e\u0301",
66970  "\xE8": "e\u0300",
66971  "\xEB": "e\u0308",
66972  "\u1EBD": "e\u0303",
66973  "\u0113": "e\u0304",
66974  "\u1E17": "e\u0304\u0301",
66975  "\u1E15": "e\u0304\u0300",
66976  "\u0115": "e\u0306",
66977  "\u1E1D": "e\u0327\u0306",
66978  "\u011B": "e\u030C",
66979  "\xEA": "e\u0302",
66980  "\u1EBF": "e\u0302\u0301",
66981  "\u1EC1": "e\u0302\u0300",
66982  "\u1EC5": "e\u0302\u0303",
66983  "\u0117": "e\u0307",
66984  "\u0229": "e\u0327",
66985  "\u1E1F": "f\u0307",
66986  "\u01F5": "g\u0301",
66987  "\u1E21": "g\u0304",
66988  "\u011F": "g\u0306",
66989  "\u01E7": "g\u030C",
66990  "\u011D": "g\u0302",
66991  "\u0121": "g\u0307",
66992  "\u0123": "g\u0327",
66993  "\u1E27": "h\u0308",
66994  "\u021F": "h\u030C",
66995  "\u0125": "h\u0302",
66996  "\u1E23": "h\u0307",
66997  "\u1E29": "h\u0327",
66998  "\xED": "i\u0301",
66999  "\xEC": "i\u0300",
67000  "\xEF": "i\u0308",
67001  "\u1E2F": "i\u0308\u0301",
67002  "\u0129": "i\u0303",
67003  "\u012B": "i\u0304",
67004  "\u012D": "i\u0306",
67005  "\u01D0": "i\u030C",
67006  "\xEE": "i\u0302",
67007  "\u01F0": "j\u030C",
67008  "\u0135": "j\u0302",
67009  "\u1E31": "k\u0301",
67010  "\u01E9": "k\u030C",
67011  "\u0137": "k\u0327",
67012  "\u013A": "l\u0301",
67013  "\u013E": "l\u030C",
67014  "\u013C": "l\u0327",
67015  "\u1E3F": "m\u0301",
67016  "\u1E41": "m\u0307",
67017  "\u0144": "n\u0301",
67018  "\u01F9": "n\u0300",
67019  "\xF1": "n\u0303",
67020  "\u0148": "n\u030C",
67021  "\u1E45": "n\u0307",
67022  "\u0146": "n\u0327",
67023  "\xF3": "o\u0301",
67024  "\xF2": "o\u0300",
67025  "\xF6": "o\u0308",
67026  "\u022B": "o\u0308\u0304",
67027  "\xF5": "o\u0303",
67028  "\u1E4D": "o\u0303\u0301",
67029  "\u1E4F": "o\u0303\u0308",
67030  "\u022D": "o\u0303\u0304",
67031  "\u014D": "o\u0304",
67032  "\u1E53": "o\u0304\u0301",
67033  "\u1E51": "o\u0304\u0300",
67034  "\u014F": "o\u0306",
67035  "\u01D2": "o\u030C",
67036  "\xF4": "o\u0302",
67037  "\u1ED1": "o\u0302\u0301",
67038  "\u1ED3": "o\u0302\u0300",
67039  "\u1ED7": "o\u0302\u0303",
67040  "\u022F": "o\u0307",
67041  "\u0231": "o\u0307\u0304",
67042  "\u0151": "o\u030B",
67043  "\u1E55": "p\u0301",
67044  "\u1E57": "p\u0307",
67045  "\u0155": "r\u0301",
67046  "\u0159": "r\u030C",
67047  "\u1E59": "r\u0307",
67048  "\u0157": "r\u0327",
67049  "\u015B": "s\u0301",
67050  "\u1E65": "s\u0301\u0307",
67051  "\u0161": "s\u030C",
67052  "\u1E67": "s\u030C\u0307",
67053  "\u015D": "s\u0302",
67054  "\u1E61": "s\u0307",
67055  "\u015F": "s\u0327",
67056  "\u1E97": "t\u0308",
67057  "\u0165": "t\u030C",
67058  "\u1E6B": "t\u0307",
67059  "\u0163": "t\u0327",
67060  "\xFA": "u\u0301",
67061  "\xF9": "u\u0300",
67062  "\xFC": "u\u0308",
67063  "\u01D8": "u\u0308\u0301",
67064  "\u01DC": "u\u0308\u0300",
67065  "\u01D6": "u\u0308\u0304",
67066  "\u01DA": "u\u0308\u030C",
67067  "\u0169": "u\u0303",
67068  "\u1E79": "u\u0303\u0301",
67069  "\u016B": "u\u0304",
67070  "\u1E7B": "u\u0304\u0308",
67071  "\u016D": "u\u0306",
67072  "\u01D4": "u\u030C",
67073  "\xFB": "u\u0302",
67074  "\u016F": "u\u030A",
67075  "\u0171": "u\u030B",
67076  "\u1E7D": "v\u0303",
67077  "\u1E83": "w\u0301",
67078  "\u1E81": "w\u0300",
67079  "\u1E85": "w\u0308",
67080  "\u0175": "w\u0302",
67081  "\u1E87": "w\u0307",
67082  "\u1E98": "w\u030A",
67083  "\u1E8D": "x\u0308",
67084  "\u1E8B": "x\u0307",
67085  "\xFD": "y\u0301",
67086  "\u1EF3": "y\u0300",
67087  "\xFF": "y\u0308",
67088  "\u1EF9": "y\u0303",
67089  "\u0233": "y\u0304",
67090  "\u0177": "y\u0302",
67091  "\u1E8F": "y\u0307",
67092  "\u1E99": "y\u030A",
67093  "\u017A": "z\u0301",
67094  "\u017E": "z\u030C",
67095  "\u1E91": "z\u0302",
67096  "\u017C": "z\u0307",
67097  "\xC1": "A\u0301",
67098  "\xC0": "A\u0300",
67099  "\xC4": "A\u0308",
67100  "\u01DE": "A\u0308\u0304",
67101  "\xC3": "A\u0303",
67102  "\u0100": "A\u0304",
67103  "\u0102": "A\u0306",
67104  "\u1EAE": "A\u0306\u0301",
67105  "\u1EB0": "A\u0306\u0300",
67106  "\u1EB4": "A\u0306\u0303",
67107  "\u01CD": "A\u030C",
67108  "\xC2": "A\u0302",
67109  "\u1EA4": "A\u0302\u0301",
67110  "\u1EA6": "A\u0302\u0300",
67111  "\u1EAA": "A\u0302\u0303",
67112  "\u0226": "A\u0307",
67113  "\u01E0": "A\u0307\u0304",
67114  "\xC5": "A\u030A",
67115  "\u01FA": "A\u030A\u0301",
67116  "\u1E02": "B\u0307",
67117  "\u0106": "C\u0301",
67118  "\u1E08": "C\u0327\u0301",
67119  "\u010C": "C\u030C",
67120  "\u0108": "C\u0302",
67121  "\u010A": "C\u0307",
67122  "\xC7": "C\u0327",
67123  "\u010E": "D\u030C",
67124  "\u1E0A": "D\u0307",
67125  "\u1E10": "D\u0327",
67126  "\xC9": "E\u0301",
67127  "\xC8": "E\u0300",
67128  "\xCB": "E\u0308",
67129  "\u1EBC": "E\u0303",
67130  "\u0112": "E\u0304",
67131  "\u1E16": "E\u0304\u0301",
67132  "\u1E14": "E\u0304\u0300",
67133  "\u0114": "E\u0306",
67134  "\u1E1C": "E\u0327\u0306",
67135  "\u011A": "E\u030C",
67136  "\xCA": "E\u0302",
67137  "\u1EBE": "E\u0302\u0301",
67138  "\u1EC0": "E\u0302\u0300",
67139  "\u1EC4": "E\u0302\u0303",
67140  "\u0116": "E\u0307",
67141  "\u0228": "E\u0327",
67142  "\u1E1E": "F\u0307",
67143  "\u01F4": "G\u0301",
67144  "\u1E20": "G\u0304",
67145  "\u011E": "G\u0306",
67146  "\u01E6": "G\u030C",
67147  "\u011C": "G\u0302",
67148  "\u0120": "G\u0307",
67149  "\u0122": "G\u0327",
67150  "\u1E26": "H\u0308",
67151  "\u021E": "H\u030C",
67152  "\u0124": "H\u0302",
67153  "\u1E22": "H\u0307",
67154  "\u1E28": "H\u0327",
67155  "\xCD": "I\u0301",
67156  "\xCC": "I\u0300",
67157  "\xCF": "I\u0308",
67158  "\u1E2E": "I\u0308\u0301",
67159  "\u0128": "I\u0303",
67160  "\u012A": "I\u0304",
67161  "\u012C": "I\u0306",
67162  "\u01CF": "I\u030C",
67163  "\xCE": "I\u0302",
67164  "\u0130": "I\u0307",
67165  "\u0134": "J\u0302",
67166  "\u1E30": "K\u0301",
67167  "\u01E8": "K\u030C",
67168  "\u0136": "K\u0327",
67169  "\u0139": "L\u0301",
67170  "\u013D": "L\u030C",
67171  "\u013B": "L\u0327",
67172  "\u1E3E": "M\u0301",
67173  "\u1E40": "M\u0307",
67174  "\u0143": "N\u0301",
67175  "\u01F8": "N\u0300",
67176  "\xD1": "N\u0303",
67177  "\u0147": "N\u030C",
67178  "\u1E44": "N\u0307",
67179  "\u0145": "N\u0327",
67180  "\xD3": "O\u0301",
67181  "\xD2": "O\u0300",
67182  "\xD6": "O\u0308",
67183  "\u022A": "O\u0308\u0304",
67184  "\xD5": "O\u0303",
67185  "\u1E4C": "O\u0303\u0301",
67186  "\u1E4E": "O\u0303\u0308",
67187  "\u022C": "O\u0303\u0304",
67188  "\u014C": "O\u0304",
67189  "\u1E52": "O\u0304\u0301",
67190  "\u1E50": "O\u0304\u0300",
67191  "\u014E": "O\u0306",
67192  "\u01D1": "O\u030C",
67193  "\xD4": "O\u0302",
67194  "\u1ED0": "O\u0302\u0301",
67195  "\u1ED2": "O\u0302\u0300",
67196  "\u1ED6": "O\u0302\u0303",
67197  "\u022E": "O\u0307",
67198  "\u0230": "O\u0307\u0304",
67199  "\u0150": "O\u030B",
67200  "\u1E54": "P\u0301",
67201  "\u1E56": "P\u0307",
67202  "\u0154": "R\u0301",
67203  "\u0158": "R\u030C",
67204  "\u1E58": "R\u0307",
67205  "\u0156": "R\u0327",
67206  "\u015A": "S\u0301",
67207  "\u1E64": "S\u0301\u0307",
67208  "\u0160": "S\u030C",
67209  "\u1E66": "S\u030C\u0307",
67210  "\u015C": "S\u0302",
67211  "\u1E60": "S\u0307",
67212  "\u015E": "S\u0327",
67213  "\u0164": "T\u030C",
67214  "\u1E6A": "T\u0307",
67215  "\u0162": "T\u0327",
67216  "\xDA": "U\u0301",
67217  "\xD9": "U\u0300",
67218  "\xDC": "U\u0308",
67219  "\u01D7": "U\u0308\u0301",
67220  "\u01DB": "U\u0308\u0300",
67221  "\u01D5": "U\u0308\u0304",
67222  "\u01D9": "U\u0308\u030C",
67223  "\u0168": "U\u0303",
67224  "\u1E78": "U\u0303\u0301",
67225  "\u016A": "U\u0304",
67226  "\u1E7A": "U\u0304\u0308",
67227  "\u016C": "U\u0306",
67228  "\u01D3": "U\u030C",
67229  "\xDB": "U\u0302",
67230  "\u016E": "U\u030A",
67231  "\u0170": "U\u030B",
67232  "\u1E7C": "V\u0303",
67233  "\u1E82": "W\u0301",
67234  "\u1E80": "W\u0300",
67235  "\u1E84": "W\u0308",
67236  "\u0174": "W\u0302",
67237  "\u1E86": "W\u0307",
67238  "\u1E8C": "X\u0308",
67239  "\u1E8A": "X\u0307",
67240  "\xDD": "Y\u0301",
67241  "\u1EF2": "Y\u0300",
67242  "\u0178": "Y\u0308",
67243  "\u1EF8": "Y\u0303",
67244  "\u0232": "Y\u0304",
67245  "\u0176": "Y\u0302",
67246  "\u1E8E": "Y\u0307",
67247  "\u0179": "Z\u0301",
67248  "\u017D": "Z\u030C",
67249  "\u1E90": "Z\u0302",
67250  "\u017B": "Z\u0307",
67251  "\u03AC": "\u03B1\u0301",
67252  "\u1F70": "\u03B1\u0300",
67253  "\u1FB1": "\u03B1\u0304",
67254  "\u1FB0": "\u03B1\u0306",
67255  "\u03AD": "\u03B5\u0301",
67256  "\u1F72": "\u03B5\u0300",
67257  "\u03AE": "\u03B7\u0301",
67258  "\u1F74": "\u03B7\u0300",
67259  "\u03AF": "\u03B9\u0301",
67260  "\u1F76": "\u03B9\u0300",
67261  "\u03CA": "\u03B9\u0308",
67262  "\u0390": "\u03B9\u0308\u0301",
67263  "\u1FD2": "\u03B9\u0308\u0300",
67264  "\u1FD1": "\u03B9\u0304",
67265  "\u1FD0": "\u03B9\u0306",
67266  "\u03CC": "\u03BF\u0301",
67267  "\u1F78": "\u03BF\u0300",
67268  "\u03CD": "\u03C5\u0301",
67269  "\u1F7A": "\u03C5\u0300",
67270  "\u03CB": "\u03C5\u0308",
67271  "\u03B0": "\u03C5\u0308\u0301",
67272  "\u1FE2": "\u03C5\u0308\u0300",
67273  "\u1FE1": "\u03C5\u0304",
67274  "\u1FE0": "\u03C5\u0306",
67275  "\u03CE": "\u03C9\u0301",
67276  "\u1F7C": "\u03C9\u0300",
67277  "\u038E": "\u03A5\u0301",
67278  "\u1FEA": "\u03A5\u0300",
67279  "\u03AB": "\u03A5\u0308",
67280  "\u1FE9": "\u03A5\u0304",
67281  "\u1FE8": "\u03A5\u0306",
67282  "\u038F": "\u03A9\u0301",
67283  "\u1FFA": "\u03A9\u0300"
67284};
67285var Parser = class _Parser2 {
67286  constructor(input2, settings) {
67287    this.mode = void 0;
67288    this.gullet = void 0;
67289    this.settings = void 0;
67290    this.leftrightDepth = void 0;
67291    this.nextToken = void 0;
67292    this.mode = "math";
67293    this.gullet = new MacroExpander(input2, settings, this.mode);
67294    this.settings = settings;
67295    this.leftrightDepth = 0;
67296  }
67297  /**
67298   * Checks a result to make sure it has the right type, and throws an
67299   * appropriate error otherwise.
67300   */
67301  expect(text2, consume) {
67302    if (consume === void 0) {
67303      consume = true;
67304    }
67305    if (this.fetch().text !== text2) {
67306      throw new ParseError("Expected '" + text2 + "', got '" + this.fetch().text + "'", this.fetch());
67307    }
67308    if (consume) {
67309      this.consume();
67310    }
67311  }
67312  /**
67313   * Discards the current lookahead token, considering it consumed.
67314   */
67315  consume() {
67316    this.nextToken = null;
67317  }
67318  /**
67319   * Return the current lookahead token, or if there isn't one (at the
67320   * beginning, or if the previous lookahead token was consume()d),
67321   * fetch the next token as the new lookahead token and return it.
67322   */
67323  fetch() {
67324    if (this.nextToken == null) {
67325      this.nextToken = this.gullet.expandNextToken();
67326    }
67327    return this.nextToken;
67328  }
67329  /**
67330   * Switches between "text" and "math" modes.
67331   */
67332  switchMode(newMode) {
67333    this.mode = newMode;
67334    this.gullet.switchMode(newMode);
67335  }
67336  /**
67337   * Main parsing function, which parses an entire input.
67338   */
67339  parse() {
67340    if (!this.settings.globalGroup) {
67341      this.gullet.beginGroup();
67342    }
67343    if (this.settings.colorIsTextColor) {
67344      this.gullet.macros.set("\\color", "\\textcolor");
67345    }
67346    try {
67347      var parse = this.parseExpression(false);
67348      this.expect("EOF");
67349      if (!this.settings.globalGroup) {
67350        this.gullet.endGroup();
67351      }
67352      return parse;
67353    } finally {
67354      this.gullet.endGroups();
67355    }
67356  }
67357  /**
67358   * Fully parse a separate sequence of tokens as a separate job.
67359   * Tokens should be specified in reverse order, as in a MacroDefinition.
67360   */
67361  subparse(tokens) {
67362    var oldToken = this.nextToken;
67363    this.consume();
67364    this.gullet.pushToken(new Token("}"));
67365    this.gullet.pushTokens(tokens);
67366    var parse = this.parseExpression(false);
67367    this.expect("}");
67368    this.nextToken = oldToken;
67369    return parse;
67370  }
67371  /**
67372   * Parses an "expression", which is a list of atoms.
67373   *
67374   * `breakOnInfix`: Should the parsing stop when we hit infix nodes? This
67375   *                 happens when functions have higher precedence han infix
67376   *                 nodes in implicit parses.
67377   *
67378   * `breakOnTokenText`: The text of the token that the expression should end
67379   *                     with, or `null` if something else should end the
67380   *                     expression.
67381   */
67382  parseExpression(breakOnInfix, breakOnTokenText) {
67383    var body = [];
67384    while (true) {
67385      if (this.mode === "math") {
67386        this.consumeSpaces();
67387      }
67388      var lex = this.fetch();
67389      if (_Parser2.endOfExpression.indexOf(lex.text) !== -1) {
67390        break;
67391      }
67392      if (breakOnTokenText && lex.text === breakOnTokenText) {
67393        break;
67394      }
67395      if (breakOnInfix && functions[lex.text] && functions[lex.text].infix) {
67396        break;
67397      }
67398      var atom = this.parseAtom(breakOnTokenText);
67399      if (!atom) {
67400        break;
67401      } else if (atom.type === "internal") {
67402        continue;
67403      }
67404      body.push(atom);
67405    }
67406    if (this.mode === "text") {
67407      this.formLigatures(body);
67408    }
67409    return this.handleInfixNodes(body);
67410  }
67411  /**
67412   * Rewrites infix operators such as \over with corresponding commands such
67413   * as \frac.
67414   *
67415   * There can only be one infix operator per group.  If there's more than one
67416   * then the expression is ambiguous.  This can be resolved by adding {}.
67417   */
67418  handleInfixNodes(body) {
67419    var overIndex = -1;
67420    var funcName;
67421    for (var i = 0; i < body.length; i++) {
67422      if (body[i].type === "infix") {
67423        if (overIndex !== -1) {
67424          throw new ParseError("only one infix operator per group", body[i].token);
67425        }
67426        overIndex = i;
67427        funcName = body[i].replaceWith;
67428      }
67429    }
67430    if (overIndex !== -1 && funcName) {
67431      var numerNode;
67432      var denomNode;
67433      var numerBody = body.slice(0, overIndex);
67434      var denomBody = body.slice(overIndex + 1);
67435      if (numerBody.length === 1 && numerBody[0].type === "ordgroup") {
67436        numerNode = numerBody[0];
67437      } else {
67438        numerNode = {
67439          type: "ordgroup",
67440          mode: this.mode,
67441          body: numerBody
67442        };
67443      }
67444      if (denomBody.length === 1 && denomBody[0].type === "ordgroup") {
67445        denomNode = denomBody[0];
67446      } else {
67447        denomNode = {
67448          type: "ordgroup",
67449          mode: this.mode,
67450          body: denomBody
67451        };
67452      }
67453      var node;
67454      if (funcName === "\\\\abovefrac") {
67455        node = this.callFunction(funcName, [numerNode, body[overIndex], denomNode], []);
67456      } else {
67457        node = this.callFunction(funcName, [numerNode, denomNode], []);
67458      }
67459      return [node];
67460    } else {
67461      return body;
67462    }
67463  }
67464  /**
67465   * Handle a subscript or superscript with nice errors.
67466   */
67467  handleSupSubscript(name) {
67468    var symbolToken = this.fetch();
67469    var symbol = symbolToken.text;
67470    this.consume();
67471    this.consumeSpaces();
67472    var group;
67473    do {
67474      var _group;
67475      group = this.parseGroup(name);
67476    } while (((_group = group) == null ? void 0 : _group.type) === "internal");
67477    if (!group) {
67478      throw new ParseError("Expected group after '" + symbol + "'", symbolToken);
67479    }
67480    return group;
67481  }
67482  /**
67483   * Converts the textual input of an unsupported command into a text node
67484   * contained within a color node whose color is determined by errorColor
67485   */
67486  formatUnsupportedCmd(text2) {
67487    var textordArray = [];
67488    for (var i = 0; i < text2.length; i++) {
67489      textordArray.push({
67490        type: "textord",
67491        mode: "text",
67492        text: text2[i]
67493      });
67494    }
67495    var textNode = {
67496      type: "text",
67497      mode: this.mode,
67498      body: textordArray
67499    };
67500    var colorNode = {
67501      type: "color",
67502      mode: this.mode,
67503      color: this.settings.errorColor,
67504      body: [textNode]
67505    };
67506    return colorNode;
67507  }
67508  /**
67509   * Parses a group with optional super/subscripts.
67510   */
67511  parseAtom(breakOnTokenText) {
67512    var base = this.parseGroup("atom", breakOnTokenText);
67513    if ((base == null ? void 0 : base.type) === "internal") {
67514      return base;
67515    }
67516    if (this.mode === "text") {
67517      return base;
67518    }
67519    var superscript;
67520    var subscript;
67521    while (true) {
67522      this.consumeSpaces();
67523      var lex = this.fetch();
67524      if (lex.text === "\\limits" || lex.text === "\\nolimits") {
67525        if (base && base.type === "op") {
67526          var limits = lex.text === "\\limits";
67527          base.limits = limits;
67528          base.alwaysHandleSupSub = true;
67529        } else if (base && base.type === "operatorname") {
67530          if (base.alwaysHandleSupSub) {
67531            base.limits = lex.text === "\\limits";
67532          }
67533        } else {
67534          throw new ParseError("Limit controls must follow a math operator", lex);
67535        }
67536        this.consume();
67537      } else if (lex.text === "^") {
67538        if (superscript) {
67539          throw new ParseError("Double superscript", lex);
67540        }
67541        superscript = this.handleSupSubscript("superscript");
67542      } else if (lex.text === "_") {
67543        if (subscript) {
67544          throw new ParseError("Double subscript", lex);
67545        }
67546        subscript = this.handleSupSubscript("subscript");
67547      } else if (lex.text === "'") {
67548        if (superscript) {
67549          throw new ParseError("Double superscript", lex);
67550        }
67551        var prime = {
67552          type: "textord",
67553          mode: this.mode,
67554          text: "\\prime"
67555        };
67556        var primes = [prime];
67557        this.consume();
67558        while (this.fetch().text === "'") {
67559          primes.push(prime);
67560          this.consume();
67561        }
67562        if (this.fetch().text === "^") {
67563          primes.push(this.handleSupSubscript("superscript"));
67564        }
67565        superscript = {
67566          type: "ordgroup",
67567          mode: this.mode,
67568          body: primes
67569        };
67570      } else if (uSubsAndSups[lex.text]) {
67571        var isSub = unicodeSubRegEx.test(lex.text);
67572        var subsupTokens = [];
67573        subsupTokens.push(new Token(uSubsAndSups[lex.text]));
67574        this.consume();
67575        while (true) {
67576          var token = this.fetch().text;
67577          if (!uSubsAndSups[token]) {
67578            break;
67579          }
67580          if (unicodeSubRegEx.test(token) !== isSub) {
67581            break;
67582          }
67583          subsupTokens.unshift(new Token(uSubsAndSups[token]));
67584          this.consume();
67585        }
67586        var body = this.subparse(subsupTokens);
67587        if (isSub) {
67588          subscript = {
67589            type: "ordgroup",
67590            mode: "math",
67591            body
67592          };
67593        } else {
67594          superscript = {
67595            type: "ordgroup",
67596            mode: "math",
67597            body
67598          };
67599        }
67600      } else {
67601        break;
67602      }
67603    }
67604    if (superscript || subscript) {
67605      return {
67606        type: "supsub",
67607        mode: this.mode,
67608        base,
67609        sup: superscript,
67610        sub: subscript
67611      };
67612    } else {
67613      return base;
67614    }
67615  }
67616  /**
67617   * Parses an entire function, including its base and all of its arguments.
67618   */
67619  parseFunction(breakOnTokenText, name) {
67620    var token = this.fetch();
67621    var func = token.text;
67622    var funcData = functions[func];
67623    if (!funcData) {
67624      return null;
67625    }
67626    this.consume();
67627    if (name && name !== "atom" && !funcData.allowedInArgument) {
67628      throw new ParseError("Got function '" + func + "' with no arguments" + (name ? " as " + name : ""), token);
67629    } else if (this.mode === "text" && !funcData.allowedInText) {
67630      throw new ParseError("Can't use function '" + func + "' in text mode", token);
67631    } else if (this.mode === "math" && funcData.allowedInMath === false) {
67632      throw new ParseError("Can't use function '" + func + "' in math mode", token);
67633    }
67634    var {
67635      args,
67636      optArgs
67637    } = this.parseArguments(func, funcData);
67638    return this.callFunction(func, args, optArgs, token, breakOnTokenText);
67639  }
67640  /**
67641   * Call a function handler with a suitable context and arguments.
67642   */
67643  callFunction(name, args, optArgs, token, breakOnTokenText) {
67644    var context = {
67645      funcName: name,
67646      parser: this,
67647      token,
67648      breakOnTokenText
67649    };
67650    var func = functions[name];
67651    if (func && func.handler) {
67652      return func.handler(context, args, optArgs);
67653    } else {
67654      throw new ParseError("No function handler for " + name);
67655    }
67656  }
67657  /**
67658   * Parses the arguments of a function or environment
67659   */
67660  parseArguments(func, funcData) {
67661    var totalArgs = funcData.numArgs + funcData.numOptionalArgs;
67662    if (totalArgs === 0) {
67663      return {
67664        args: [],
67665        optArgs: []
67666      };
67667    }
67668    var args = [];
67669    var optArgs = [];
67670    for (var i = 0; i < totalArgs; i++) {
67671      var argType = funcData.argTypes && funcData.argTypes[i];
67672      var isOptional = i < funcData.numOptionalArgs;
67673      if (funcData.primitive && argType == null || // \sqrt expands into primitive if optional argument doesn't exist
67674      funcData.type === "sqrt" && i === 1 && optArgs[0] == null) {
67675        argType = "primitive";
67676      }
67677      var arg = this.parseGroupOfType("argument to '" + func + "'", argType, isOptional);
67678      if (isOptional) {
67679        optArgs.push(arg);
67680      } else if (arg != null) {
67681        args.push(arg);
67682      } else {
67683        throw new ParseError("Null argument, please report this as a bug");
67684      }
67685    }
67686    return {
67687      args,
67688      optArgs
67689    };
67690  }
67691  /**
67692   * Parses a group when the mode is changing.
67693   */
67694  parseGroupOfType(name, type, optional) {
67695    switch (type) {
67696      case "color":
67697        return this.parseColorGroup(optional);
67698      case "size":
67699        return this.parseSizeGroup(optional);
67700      case "url":
67701        return this.parseUrlGroup(optional);
67702      case "math":
67703      case "text":
67704        return this.parseArgumentGroup(optional, type);
67705      case "hbox": {
67706        var group = this.parseArgumentGroup(optional, "text");
67707        return group != null ? {
67708          type: "styling",
67709          mode: group.mode,
67710          body: [group],
67711          style: "text"
67712          // simulate \textstyle
67713        } : null;
67714      }
67715      case "raw": {
67716        var token = this.parseStringGroup("raw", optional);
67717        return token != null ? {
67718          type: "raw",
67719          mode: "text",
67720          string: token.text
67721        } : null;
67722      }
67723      case "primitive": {
67724        if (optional) {
67725          throw new ParseError("A primitive argument cannot be optional");
67726        }
67727        var _group2 = this.parseGroup(name);
67728        if (_group2 == null) {
67729          throw new ParseError("Expected group as " + name, this.fetch());
67730        }
67731        return _group2;
67732      }
67733      case "original":
67734      case null:
67735      case void 0:
67736        return this.parseArgumentGroup(optional);
67737      default:
67738        throw new ParseError("Unknown group type as " + name, this.fetch());
67739    }
67740  }
67741  /**
67742   * Discard any space tokens, fetching the next non-space token.
67743   */
67744  consumeSpaces() {
67745    while (this.fetch().text === " ") {
67746      this.consume();
67747    }
67748  }
67749  /**
67750   * Parses a group, essentially returning the string formed by the
67751   * brace-enclosed tokens plus some position information.
67752   */
67753  parseStringGroup(modeName, optional) {
67754    var argToken = this.gullet.scanArgument(optional);
67755    if (argToken == null) {
67756      return null;
67757    }
67758    var str = "";
67759    var nextToken;
67760    while ((nextToken = this.fetch()).text !== "EOF") {
67761      str += nextToken.text;
67762      this.consume();
67763    }
67764    this.consume();
67765    argToken.text = str;
67766    return argToken;
67767  }
67768  /**
67769   * Parses a regex-delimited group: the largest sequence of tokens
67770   * whose concatenated strings match `regex`. Returns the string
67771   * formed by the tokens plus some position information.
67772   */
67773  parseRegexGroup(regex, modeName) {
67774    var firstToken = this.fetch();
67775    var lastToken = firstToken;
67776    var str = "";
67777    var nextToken;
67778    while ((nextToken = this.fetch()).text !== "EOF" && regex.test(str + nextToken.text)) {
67779      lastToken = nextToken;
67780      str += lastToken.text;
67781      this.consume();
67782    }
67783    if (str === "") {
67784      throw new ParseError("Invalid " + modeName + ": '" + firstToken.text + "'", firstToken);
67785    }
67786    return firstToken.range(lastToken, str);
67787  }
67788  /**
67789   * Parses a color description.
67790   */
67791  parseColorGroup(optional) {
67792    var res = this.parseStringGroup("color", optional);
67793    if (res == null) {
67794      return null;
67795    }
67796    var match = /^(#[a-f0-9]{3}|#?[a-f0-9]{6}|[a-z]+)$/i.exec(res.text);
67797    if (!match) {
67798      throw new ParseError("Invalid color: '" + res.text + "'", res);
67799    }
67800    var color = match[0];
67801    if (/^[0-9a-f]{6}$/i.test(color)) {
67802      color = "#" + color;
67803    }
67804    return {
67805      type: "color-token",
67806      mode: this.mode,
67807      color
67808    };
67809  }
67810  /**
67811   * Parses a size specification, consisting of magnitude and unit.
67812   */
67813  parseSizeGroup(optional) {
67814    var res;
67815    var isBlank = false;
67816    this.gullet.consumeSpaces();
67817    if (!optional && this.gullet.future().text !== "{") {
67818      res = this.parseRegexGroup(/^[-+]? *(?:$|\d+|\d+\.\d*|\.\d*) *[a-z]{0,2} *$/, "size");
67819    } else {
67820      res = this.parseStringGroup("size", optional);
67821    }
67822    if (!res) {
67823      return null;
67824    }
67825    if (!optional && res.text.length === 0) {
67826      res.text = "0pt";
67827      isBlank = true;
67828    }
67829    var match = /([-+]?) *(\d+(?:\.\d*)?|\.\d+) *([a-z]{2})/.exec(res.text);
67830    if (!match) {
67831      throw new ParseError("Invalid size: '" + res.text + "'", res);
67832    }
67833    var data = {
67834      number: +(match[1] + match[2]),
67835      // sign + magnitude, cast to number
67836      unit: match[3]
67837    };
67838    if (!validUnit(data)) {
67839      throw new ParseError("Invalid unit: '" + data.unit + "'", res);
67840    }
67841    return {
67842      type: "size",
67843      mode: this.mode,
67844      value: data,
67845      isBlank
67846    };
67847  }
67848  /**
67849   * Parses an URL, checking escaped letters and allowed protocols,
67850   * and setting the catcode of % as an active character (as in \hyperref).
67851   */
67852  parseUrlGroup(optional) {
67853    this.gullet.lexer.setCatcode("%", 13);
67854    this.gullet.lexer.setCatcode("~", 12);
67855    var res = this.parseStringGroup("url", optional);
67856    this.gullet.lexer.setCatcode("%", 14);
67857    this.gullet.lexer.setCatcode("~", 13);
67858    if (res == null) {
67859      return null;
67860    }
67861    var url = res.text.replace(/\\([#$%&~_^{}])/g, "$1");
67862    return {
67863      type: "url",
67864      mode: this.mode,
67865      url
67866    };
67867  }
67868  /**
67869   * Parses an argument with the mode specified.
67870   */
67871  parseArgumentGroup(optional, mode) {
67872    var argToken = this.gullet.scanArgument(optional);
67873    if (argToken == null) {
67874      return null;
67875    }
67876    var outerMode = this.mode;
67877    if (mode) {
67878      this.switchMode(mode);
67879    }
67880    this.gullet.beginGroup();
67881    var expression = this.parseExpression(false, "EOF");
67882    this.expect("EOF");
67883    this.gullet.endGroup();
67884    var result = {
67885      type: "ordgroup",
67886      mode: this.mode,
67887      loc: argToken.loc,
67888      body: expression
67889    };
67890    if (mode) {
67891      this.switchMode(outerMode);
67892    }
67893    return result;
67894  }
67895  /**
67896   * Parses an ordinary group, which is either a single nucleus (like "x")
67897   * or an expression in braces (like "{x+y}") or an implicit group, a group
67898   * that starts at the current position, and ends right before a higher explicit
67899   * group ends, or at EOF.
67900   */
67901  parseGroup(name, breakOnTokenText) {
67902    var firstToken = this.fetch();
67903    var text2 = firstToken.text;
67904    var result;
67905    if (text2 === "{" || text2 === "\\begingroup") {
67906      this.consume();
67907      var groupEnd = text2 === "{" ? "}" : "\\endgroup";
67908      this.gullet.beginGroup();
67909      var expression = this.parseExpression(false, groupEnd);
67910      var lastToken = this.fetch();
67911      this.expect(groupEnd);
67912      this.gullet.endGroup();
67913      result = {
67914        type: "ordgroup",
67915        mode: this.mode,
67916        loc: SourceLocation.range(firstToken, lastToken),
67917        body: expression,
67918        // A group formed by \begingroup...\endgroup is a semi-simple group
67919        // which doesn't affect spacing in math mode, i.e., is transparent.
67920        // https://tex.stackexchange.com/questions/1930/when-should-one-
67921        // use-begingroup-instead-of-bgroup
67922        semisimple: text2 === "\\begingroup" || void 0
67923      };
67924    } else {
67925      result = this.parseFunction(breakOnTokenText, name) || this.parseSymbol();
67926      if (result == null && text2[0] === "\\" && !implicitCommands.hasOwnProperty(text2)) {
67927        if (this.settings.throwOnError) {
67928          throw new ParseError("Undefined control sequence: " + text2, firstToken);
67929        }
67930        result = this.formatUnsupportedCmd(text2);
67931        this.consume();
67932      }
67933    }
67934    return result;
67935  }
67936  /**
67937   * Form ligature-like combinations of characters for text mode.
67938   * This includes inputs like "--", "---", "``" and "''".
67939   * The result will simply replace multiple textord nodes with a single
67940   * character in each value by a single textord node having multiple
67941   * characters in its value.  The representation is still ASCII source.
67942   * The group will be modified in place.
67943   */
67944  formLigatures(group) {
67945    var n = group.length - 1;
67946    for (var i = 0; i < n; ++i) {
67947      var a = group[i];
67948      var v = a.text;
67949      if (v === "-" && group[i + 1].text === "-") {
67950        if (i + 1 < n && group[i + 2].text === "-") {
67951          group.splice(i, 3, {
67952            type: "textord",
67953            mode: "text",
67954            loc: SourceLocation.range(a, group[i + 2]),
67955            text: "---"
67956          });
67957          n -= 2;
67958        } else {
67959          group.splice(i, 2, {
67960            type: "textord",
67961            mode: "text",
67962            loc: SourceLocation.range(a, group[i + 1]),
67963            text: "--"
67964          });
67965          n -= 1;
67966        }
67967      }
67968      if ((v === "'" || v === "`") && group[i + 1].text === v) {
67969        group.splice(i, 2, {
67970          type: "textord",
67971          mode: "text",
67972          loc: SourceLocation.range(a, group[i + 1]),
67973          text: v + v
67974        });
67975        n -= 1;
67976      }
67977    }
67978  }
67979  /**
67980   * Parse a single symbol out of the string. Here, we handle single character
67981   * symbols and special functions like \verb.
67982   */
67983  parseSymbol() {
67984    var nucleus = this.fetch();
67985    var text2 = nucleus.text;
67986    if (/^\\verb[^a-zA-Z]/.test(text2)) {
67987      this.consume();
67988      var arg = text2.slice(5);
67989      var star = arg.charAt(0) === "*";
67990      if (star) {
67991        arg = arg.slice(1);
67992      }
67993      if (arg.length < 2 || arg.charAt(0) !== arg.slice(-1)) {
67994        throw new ParseError("\\verb assertion failed --\n                    please report what input caused this bug");
67995      }
67996      arg = arg.slice(1, -1);
67997      return {
67998        type: "verb",
67999        mode: "text",
68000        body: arg,
68001        star
68002      };
68003    }
68004    if (unicodeSymbols.hasOwnProperty(text2[0]) && !symbols[this.mode][text2[0]]) {
68005      if (this.settings.strict && this.mode === "math") {
68006        this.settings.reportNonstrict("unicodeTextInMathMode", 'Accented Unicode text character "' + text2[0] + '" used in math mode', nucleus);
68007      }
68008      text2 = unicodeSymbols[text2[0]] + text2.slice(1);
68009    }
68010    var match = combiningDiacriticalMarksEndRegex.exec(text2);
68011    if (match) {
68012      text2 = text2.substring(0, match.index);
68013      if (text2 === "i") {
68014        text2 = "\u0131";
68015      } else if (text2 === "j") {
68016        text2 = "\u0237";
68017      }
68018    }
68019    var symbol;
68020    if (symbols[this.mode][text2]) {
68021      if (this.settings.strict && this.mode === "math" && extraLatin.indexOf(text2) >= 0) {
68022        this.settings.reportNonstrict("unicodeTextInMathMode", 'Latin-1/Unicode text character "' + text2[0] + '" used in math mode', nucleus);
68023      }
68024      var group = symbols[this.mode][text2].group;
68025      var loc = SourceLocation.range(nucleus);
68026      var s;
68027      if (ATOMS.hasOwnProperty(group)) {
68028        var family = group;
68029        s = {
68030          type: "atom",
68031          mode: this.mode,
68032          family,
68033          loc,
68034          text: text2
68035        };
68036      } else {
68037        s = {
68038          type: group,
68039          mode: this.mode,
68040          loc,
68041          text: text2
68042        };
68043      }
68044      symbol = s;
68045    } else if (text2.charCodeAt(0) >= 128) {
68046      if (this.settings.strict) {
68047        if (!supportedCodepoint(text2.charCodeAt(0))) {
68048          this.settings.reportNonstrict("unknownSymbol", 'Unrecognized Unicode character "' + text2[0] + '"' + (" (" + text2.charCodeAt(0) + ")"), nucleus);
68049        } else if (this.mode === "math") {
68050          this.settings.reportNonstrict("unicodeTextInMathMode", 'Unicode text character "' + text2[0] + '" used in math mode', nucleus);
68051        }
68052      }
68053      symbol = {
68054        type: "textord",
68055        mode: "text",
68056        loc: SourceLocation.range(nucleus),
68057        text: text2
68058      };
68059    } else {
68060      return null;
68061    }
68062    this.consume();
68063    if (match) {
68064      for (var i = 0; i < match[0].length; i++) {
68065        var accent2 = match[0][i];
68066        if (!unicodeAccents[accent2]) {
68067          throw new ParseError("Unknown accent ' " + accent2 + "'", nucleus);
68068        }
68069        var command = unicodeAccents[accent2][this.mode] || unicodeAccents[accent2].text;
68070        if (!command) {
68071          throw new ParseError("Accent " + accent2 + " unsupported in " + this.mode + " mode", nucleus);
68072        }
68073        symbol = {
68074          type: "accent",
68075          mode: this.mode,
68076          loc: SourceLocation.range(nucleus),
68077          label: command,
68078          isStretchy: false,
68079          isShifty: true,
68080          // $FlowFixMe
68081          base: symbol
68082        };
68083      }
68084    }
68085    return symbol;
68086  }
68087};
68088Parser.endOfExpression = ["}", "\\endgroup", "\\end", "\\right", "&"];
68089var parseTree = function parseTree2(toParse, settings) {
68090  if (!(typeof toParse === "string" || toParse instanceof String)) {
68091    throw new TypeError("KaTeX can only parse string typed expression");
68092  }
68093  var parser2 = new Parser(toParse, settings);
68094  delete parser2.gullet.macros.current["\\df@tag"];
68095  var tree = parser2.parse();
68096  delete parser2.gullet.macros.current["\\current@color"];
68097  delete parser2.gullet.macros.current["\\color"];
68098  if (parser2.gullet.macros.get("\\df@tag")) {
68099    if (!settings.displayMode) {
68100      throw new ParseError("\\tag works only in display equations");
68101    }
68102    tree = [{
68103      type: "tag",
68104      mode: "text",
68105      body: tree,
68106      tag: parser2.subparse([new Token("\\df@tag")])
68107    }];
68108  }
68109  return tree;
68110};
68111var render = function render2(expression, baseNode, options2) {
68112  baseNode.textContent = "";
68113  var node = renderToDomTree(expression, options2).toNode();
68114  baseNode.appendChild(node);
68115};
68116if (typeof document !== "undefined") {
68117  if (document.compatMode !== "CSS1Compat") {
68118    typeof console !== "undefined" && console.warn("Warning: KaTeX doesn't work in quirks mode. Make sure your website has a suitable doctype.");
68119    render = function render3() {
68120      throw new ParseError("KaTeX doesn't work in quirks mode.");
68121    };
68122  }
68123}
68124var renderToString = function renderToString2(expression, options2) {
68125  var markup = renderToDomTree(expression, options2).toMarkup();
68126  return markup;
68127};
68128var renderError = function renderError2(error, expression, options2) {
68129  if (options2.throwOnError || !(error instanceof ParseError)) {
68130    throw error;
68131  }
68132  var node = buildCommon.makeSpan(["katex-error"], [new SymbolNode(expression)]);
68133  node.setAttribute("title", error.toString());
68134  node.setAttribute("style", "color:" + options2.errorColor);
68135  return node;
68136};
68137var renderToDomTree = function renderToDomTree2(expression, options2) {
68138  var settings = new Settings(options2);
68139  try {
68140    var tree = parseTree(expression, settings);
68141    return buildTree(tree, expression, settings);
68142  } catch (error) {
68143    return renderError(error, expression, settings);
68144  }
68145};
68146
vendor: 71,958 bytes, lines 68147-70338
68147// node_modules/marked/lib/marked.esm.js
68148function _getDefaults() {
68149  return {
68150    async: false,
68151    breaks: false,
68152    extensions: null,
68153    gfm: true,
68154    hooks: null,
68155    pedantic: false,
68156    renderer: null,
68157    silent: false,
68158    tokenizer: null,
68159    walkTokens: null
68160  };
68161}
68162var _defaults = _getDefaults();
68163function changeDefaults(newDefaults) {
68164  _defaults = newDefaults;
68165}
68166var noopTest = {
68167  exec: () => null
68168};
68169function edit(regex, opt = "") {
68170  let source = typeof regex === "string" ? regex : regex.source;
68171  const obj = {
68172    replace: (name, val) => {
68173      let valSource = typeof val === "string" ? val : val.source;
68174      valSource = valSource.replace(other.caret, "$1");
68175      source = source.replace(name, valSource);
68176      return obj;
68177    },
68178    getRegex: () => {
68179      return new RegExp(source, opt);
68180    }
68181  };
68182  return obj;
68183}
68184var other = {
68185  codeRemoveIndent: /^(?: {1,4}| {0,3}\t)/gm,
68186  outputLinkReplace: /\\([\[\]])/g,
68187  indentCodeCompensation: /^(\s+)(?:```)/,
68188  beginningSpace: /^\s+/,
68189  endingHash: /#$/,
68190  startingSpaceChar: /^ /,
68191  endingSpaceChar: / $/,
68192  nonSpaceChar: /[^ ]/,
68193  newLineCharGlobal: /\n/g,
68194  tabCharGlobal: /\t/g,
68195  multipleSpaceGlobal: /\s+/g,
68196  blankLine: /^[ \t]*$/,
68197  doubleBlankLine: /\n[ \t]*\n[ \t]*$/,
68198  blockquoteStart: /^ {0,3}>/,
68199  blockquoteSetextReplace: /\n {0,3}((?:=+|-+) *)(?=\n|$)/g,
68200  blockquoteSetextReplace2: /^ {0,3}>[ \t]?/gm,
68201  listReplaceTabs: /^\t+/,
68202  listReplaceNesting: /^ {1,4}(?=( {4})*[^ ])/g,
68203  listIsTask: /^\[[ xX]\] /,
68204  listReplaceTask: /^\[[ xX]\] +/,
68205  anyLine: /\n.*\n/,
68206  hrefBrackets: /^<(.*)>$/,
68207  tableDelimiter: /[:|]/,
68208  tableAlignChars: /^\||\| *$/g,
68209  tableRowBlankLine: /\n[ \t]*$/,
68210  tableAlignRight: /^ *-+: *$/,
68211  tableAlignCenter: /^ *:-+: *$/,
68212  tableAlignLeft: /^ *:-+ *$/,
68213  startATag: /^<a /i,
68214  endATag: /^<\/a>/i,
68215  startPreScriptTag: /^<(pre|code|kbd|script)(\s|>)/i,
68216  endPreScriptTag: /^<\/(pre|code|kbd|script)(\s|>)/i,
68217  startAngleBracket: /^</,
68218  endAngleBracket: />$/,
68219  pedanticHrefTitle: /^([^'"]*[^\s])\s+(['"])(.*)\2/,
68220  unicodeAlphaNumeric: /[\p{L}\p{N}]/u,
68221  escapeTest: /[&<>"']/,
68222  escapeReplace: /[&<>"']/g,
68223  escapeTestNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,
68224  escapeReplaceNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,
68225  unescapeTest: /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,
68226  caret: /(^|[^\[])\^/g,
68227  percentDecode: /%25/g,
68228  findPipe: /\|/g,
68229  splitPipe: / \|/,
68230  slashPipe: /\\\|/g,
68231  carriageReturn: /\r\n|\r/g,
68232  spaceLine: /^ +$/gm,
68233  notSpaceStart: /^\S*/,
68234  endingNewline: /\n$/,
68235  listItemRegex: (bull) => new RegExp(`^( {0,3}${bull})((?:[	 ][^\\n]*)?(?:\\n|$))`),
68236  nextBulletRegex: (indent) => new RegExp(`^ {0,${Math.min(3, indent - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ 	][^\\n]*)?(?:\\n|$))`),
68237  hrRegex: (indent) => new RegExp(`^ {0,${Math.min(3, indent - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),
68238  fencesBeginRegex: (indent) => new RegExp(`^ {0,${Math.min(3, indent - 1)}}(?:\`\`\`|~~~)`),
68239  headingBeginRegex: (indent) => new RegExp(`^ {0,${Math.min(3, indent - 1)}}#`),
68240  htmlBeginRegex: (indent) => new RegExp(`^ {0,${Math.min(3, indent - 1)}}<(?:[a-z].*>|!--)`, "i")
68241};
68242var newline = /^(?:[ \t]*(?:\n|$))+/;
68243var blockCode = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/;
68244var fences = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/;
68245var hr = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/;
68246var heading = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/;
68247var bullet = /(?:[*+-]|\d{1,9}[.)])/;
68248var lheadingCore = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/;
68249var lheading = edit(lheadingCore).replace(/bull/g, bullet).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/\|table/g, "").getRegex();
68250var lheadingGfm = edit(lheadingCore).replace(/bull/g, bullet).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/table/g, / {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex();
68251var _paragraph = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/;
68252var blockText = /^[^\n]+/;
68253var _blockLabel = /(?!\s*\])(?:\\.|[^\[\]\\])+/;
68254var def = edit(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", _blockLabel).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex();
68255var list = edit(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, bullet).getRegex();
68256var _tag = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul";
68257var _comment = /<!--(?:-?>|[\s\S]*?(?:-->|$))/;
68258var html = edit("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ 	]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ 	]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ 	]*)+\\n|$))", "i").replace("comment", _comment).replace("tag", _tag).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex();
68259var paragraph = edit(_paragraph).replace("hr", hr).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", _tag).getRegex();
68260var blockquote = edit(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", paragraph).getRegex();
68261var blockNormal = {
68262  blockquote,
68263  code: blockCode,
68264  def,
68265  fences,
68266  heading,
68267  hr,
68268  html,
68269  lheading,
68270  list,
68271  newline,
68272  paragraph,
68273  table: noopTest,
68274  text: blockText
68275};
68276var gfmTable = edit("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", hr).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", "(?: {4}| {0,3}	)[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", _tag).getRegex();
68277var blockGfm = __spreadProps(__spreadValues({}, blockNormal), {
68278  lheading: lheadingGfm,
68279  table: gfmTable,
68280  paragraph: edit(_paragraph).replace("hr", hr).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", gfmTable).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", _tag).getRegex()
68281});
68282var blockPedantic = __spreadProps(__spreadValues({}, blockNormal), {
68283  html: edit(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment", _comment).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),
68284  def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
68285  heading: /^(#{1,6})(.*)(?:\n+|$)/,
68286  fences: noopTest,
68287  // fences not supported
68288  lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
68289  paragraph: edit(_paragraph).replace("hr", hr).replace("heading", " *#{1,6} *[^\n]").replace("lheading", lheading).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex()
68290});
68291var escape2 = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/;
68292var inlineCode = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/;
68293var br = /^( {2,}|\\)\n(?!\s*$)/;
68294var inlineText = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/;
68295var _punctuation = /[\p{P}\p{S}]/u;
68296var _punctuationOrSpace = /[\s\p{P}\p{S}]/u;
68297var _notPunctuationOrSpace = /[^\s\p{P}\p{S}]/u;
68298var punctuation = edit(/^((?![*_])punctSpace)/, "u").replace(/punctSpace/g, _punctuationOrSpace).getRegex();
68299var _punctuationGfmStrongEm = /(?!~)[\p{P}\p{S}]/u;
68300var _punctuationOrSpaceGfmStrongEm = /(?!~)[\s\p{P}\p{S}]/u;
68301var _notPunctuationOrSpaceGfmStrongEm = /(?:[^\s\p{P}\p{S}]|~)/u;
68302var blockSkip = /\[[^[\]]*?\]\((?:\\.|[^\\\(\)]|\((?:\\.|[^\\\(\)])*\))*\)|`[^`]*?`|<[^<>]*?>/g;
68303var emStrongLDelimCore = /^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/;
68304var emStrongLDelim = edit(emStrongLDelimCore, "u").replace(/punct/g, _punctuation).getRegex();
68305var emStrongLDelimGfm = edit(emStrongLDelimCore, "u").replace(/punct/g, _punctuationGfmStrongEm).getRegex();
68306var emStrongRDelimAstCore = "^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)";
68307var emStrongRDelimAst = edit(emStrongRDelimAstCore, "gu").replace(/notPunctSpace/g, _notPunctuationOrSpace).replace(/punctSpace/g, _punctuationOrSpace).replace(/punct/g, _punctuation).getRegex();
68308var emStrongRDelimAstGfm = edit(emStrongRDelimAstCore, "gu").replace(/notPunctSpace/g, _notPunctuationOrSpaceGfmStrongEm).replace(/punctSpace/g, _punctuationOrSpaceGfmStrongEm).replace(/punct/g, _punctuationGfmStrongEm).getRegex();
68309var emStrongRDelimUnd = edit("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)", "gu").replace(/notPunctSpace/g, _notPunctuationOrSpace).replace(/punctSpace/g, _punctuationOrSpace).replace(/punct/g, _punctuation).getRegex();
68310var anyPunctuation = edit(/\\(punct)/, "gu").replace(/punct/g, _punctuation).getRegex();
68311var autolink = edit(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme", /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email", /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex();
68312var _inlineComment = edit(_comment).replace("(?:-->|$)", "-->").getRegex();
68313var tag = edit("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment", _inlineComment).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex();
68314var _inlineLabel = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/;
68315var link = edit(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label", _inlineLabel).replace("href", /<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex();
68316var reflink = edit(/^!?\[(label)\]\[(ref)\]/).replace("label", _inlineLabel).replace("ref", _blockLabel).getRegex();
68317var nolink = edit(/^!?\[(ref)\](?:\[\])?/).replace("ref", _blockLabel).getRegex();
68318var reflinkSearch = edit("reflink|nolink(?!\\()", "g").replace("reflink", reflink).replace("nolink", nolink).getRegex();
68319var inlineNormal = {
68320  _backpedal: noopTest,
68321  // only used for GFM url
68322  anyPunctuation,
68323  autolink,
68324  blockSkip,
68325  br,
68326  code: inlineCode,
68327  del: noopTest,
68328  emStrongLDelim,
68329  emStrongRDelimAst,
68330  emStrongRDelimUnd,
68331  escape: escape2,
68332  link,
68333  nolink,
68334  punctuation,
68335  reflink,
68336  reflinkSearch,
68337  tag,
68338  text: inlineText,
68339  url: noopTest
68340};
68341var inlinePedantic = __spreadProps(__spreadValues({}, inlineNormal), {
68342  link: edit(/^!?\[(label)\]\((.*?)\)/).replace("label", _inlineLabel).getRegex(),
68343  reflink: edit(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", _inlineLabel).getRegex()
68344});
68345var inlineGfm = __spreadProps(__spreadValues({}, inlineNormal), {
68346  emStrongRDelimAst: emStrongRDelimAstGfm,
68347  emStrongLDelim: emStrongLDelimGfm,
68348  url: edit(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/, "i").replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),
68349  _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
68350  del: /^(~~?)(?=[^\s~])((?:\\.|[^\\])*?(?:\\.|[^\s~\\]))\1(?=[^~]|$)/,
68351  text: /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/
68352});
68353var inlineBreaks = __spreadProps(__spreadValues({}, inlineGfm), {
68354  br: edit(br).replace("{2,}", "*").getRegex(),
68355  text: edit(inlineGfm.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
68356});
68357var block = {
68358  normal: blockNormal,
68359  gfm: blockGfm,
68360  pedantic: blockPedantic
68361};
68362var inline = {
68363  normal: inlineNormal,
68364  gfm: inlineGfm,
68365  breaks: inlineBreaks,
68366  pedantic: inlinePedantic
68367};
68368var escapeReplacements = {
68369  "&": "&amp;",
68370  "<": "&lt;",
68371  ">": "&gt;",
68372  '"': "&quot;",
68373  "'": "&#39;"
68374};
68375var getEscapeReplacement = (ch) => escapeReplacements[ch];
68376function escape22(html2, encode) {
68377  if (encode) {
68378    if (other.escapeTest.test(html2)) {
68379      return html2.replace(other.escapeReplace, getEscapeReplacement);
68380    }
68381  } else {
68382    if (other.escapeTestNoEncode.test(html2)) {
68383      return html2.replace(other.escapeReplaceNoEncode, getEscapeReplacement);
68384    }
68385  }
68386  return html2;
68387}
68388function cleanUrl(href) {
68389  try {
68390    href = encodeURI(href).replace(other.percentDecode, "%");
68391  } catch {
68392    return null;
68393  }
68394  return href;
68395}
68396function splitCells(tableRow, count) {
68397  const row = tableRow.replace(other.findPipe, (match, offset, str) => {
68398    let escaped = false;
68399    let curr = offset;
68400    while (--curr >= 0 && str[curr] === "\\") escaped = !escaped;
68401    if (escaped) {
68402      return "|";
68403    } else {
68404      return " |";
68405    }
68406  }), cells = row.split(other.splitPipe);
68407  let i = 0;
68408  if (!cells[0].trim()) {
68409    cells.shift();
68410  }
68411  if (cells.length > 0 && !cells.at(-1)?.trim()) {
68412    cells.pop();
68413  }
68414  if (count) {
68415    if (cells.length > count) {
68416      cells.splice(count);
68417    } else {
68418      while (cells.length < count) cells.push("");
68419    }
68420  }
68421  for (; i < cells.length; i++) {
68422    cells[i] = cells[i].trim().replace(other.slashPipe, "|");
68423  }
68424  return cells;
68425}
68426function rtrim(str, c, invert) {
68427  const l = str.length;
68428  if (l === 0) {
68429    return "";
68430  }
68431  let suffLen = 0;
68432  while (suffLen < l) {
68433    const currChar = str.charAt(l - suffLen - 1);
68434    if (currChar === c && !invert) {
68435      suffLen++;
68436    } else if (currChar !== c && invert) {
68437      suffLen++;
68438    } else {
68439      break;
68440    }
68441  }
68442  return str.slice(0, l - suffLen);
68443}
68444function findClosingBracket(str, b) {
68445  if (str.indexOf(b[1]) === -1) {
68446    return -1;
68447  }
68448  let level = 0;
68449  for (let i = 0; i < str.length; i++) {
68450    if (str[i] === "\\") {
68451      i++;
68452    } else if (str[i] === b[0]) {
68453      level++;
68454    } else if (str[i] === b[1]) {
68455      level--;
68456      if (level < 0) {
68457        return i;
68458      }
68459    }
68460  }
68461  if (level > 0) {
68462    return -2;
68463  }
68464  return -1;
68465}
68466function outputLink(cap, link2, raw, lexer2, rules) {
68467  const href = link2.href;
68468  const title = link2.title || null;
68469  const text2 = cap[1].replace(rules.other.outputLinkReplace, "$1");
68470  lexer2.state.inLink = true;
68471  const token = {
68472    type: cap[0].charAt(0) === "!" ? "image" : "link",
68473    raw,
68474    href,
68475    title,
68476    text: text2,
68477    tokens: lexer2.inlineTokens(text2)
68478  };
68479  lexer2.state.inLink = false;
68480  return token;
68481}
68482function indentCodeCompensation(raw, text2, rules) {
68483  const matchIndentToCode = raw.match(rules.other.indentCodeCompensation);
68484  if (matchIndentToCode === null) {
68485    return text2;
68486  }
68487  const indentToCode = matchIndentToCode[1];
68488  return text2.split("\n").map((node) => {
68489    const matchIndentInNode = node.match(rules.other.beginningSpace);
68490    if (matchIndentInNode === null) {
68491      return node;
68492    }
68493    const [indentInNode] = matchIndentInNode;
68494    if (indentInNode.length >= indentToCode.length) {
68495      return node.slice(indentToCode.length);
68496    }
68497    return node;
68498  }).join("\n");
68499}
68500var _Tokenizer = class {
68501  options;
68502  rules;
68503  // set by the lexer
68504  lexer;
68505  // set by the lexer
68506  constructor(options2) {
68507    this.options = options2 || _defaults;
68508  }
68509  space(src) {
68510    const cap = this.rules.block.newline.exec(src);
68511    if (cap && cap[0].length > 0) {
68512      return {
68513        type: "space",
68514        raw: cap[0]
68515      };
68516    }
68517  }
68518  code(src) {
68519    const cap = this.rules.block.code.exec(src);
68520    if (cap) {
68521      const text2 = cap[0].replace(this.rules.other.codeRemoveIndent, "");
68522      return {
68523        type: "code",
68524        raw: cap[0],
68525        codeBlockStyle: "indented",
68526        text: !this.options.pedantic ? rtrim(text2, "\n") : text2
68527      };
68528    }
68529  }
68530  fences(src) {
68531    const cap = this.rules.block.fences.exec(src);
68532    if (cap) {
68533      const raw = cap[0];
68534      const text2 = indentCodeCompensation(raw, cap[3] || "", this.rules);
68535      return {
68536        type: "code",
68537        raw,
68538        lang: cap[2] ? cap[2].trim().replace(this.rules.inline.anyPunctuation, "$1") : cap[2],
68539        text: text2
68540      };
68541    }
68542  }
68543  heading(src) {
68544    const cap = this.rules.block.heading.exec(src);
68545    if (cap) {
68546      let text2 = cap[2].trim();
68547      if (this.rules.other.endingHash.test(text2)) {
68548        const trimmed = rtrim(text2, "#");
68549        if (this.options.pedantic) {
68550          text2 = trimmed.trim();
68551        } else if (!trimmed || this.rules.other.endingSpaceChar.test(trimmed)) {
68552          text2 = trimmed.trim();
68553        }
68554      }
68555      return {
68556        type: "heading",
68557        raw: cap[0],
68558        depth: cap[1].length,
68559        text: text2,
68560        tokens: this.lexer.inline(text2)
68561      };
68562    }
68563  }
68564  hr(src) {
68565    const cap = this.rules.block.hr.exec(src);
68566    if (cap) {
68567      return {
68568        type: "hr",
68569        raw: rtrim(cap[0], "\n")
68570      };
68571    }
68572  }
68573  blockquote(src) {
68574    const cap = this.rules.block.blockquote.exec(src);
68575    if (cap) {
68576      let lines = rtrim(cap[0], "\n").split("\n");
68577      let raw = "";
68578      let text2 = "";
68579      const tokens = [];
68580      while (lines.length > 0) {
68581        let inBlockquote = false;
68582        const currentLines = [];
68583        let i;
68584        for (i = 0; i < lines.length; i++) {
68585          if (this.rules.other.blockquoteStart.test(lines[i])) {
68586            currentLines.push(lines[i]);
68587            inBlockquote = true;
68588          } else if (!inBlockquote) {
68589            currentLines.push(lines[i]);
68590          } else {
68591            break;
68592          }
68593        }
68594        lines = lines.slice(i);
68595        const currentRaw = currentLines.join("\n");
68596        const currentText = currentRaw.replace(this.rules.other.blockquoteSetextReplace, "\n    $1").replace(this.rules.other.blockquoteSetextReplace2, "");
68597        raw = raw ? `${raw}
68598${currentRaw}` : currentRaw;
68599        text2 = text2 ? `${text2}
68600${currentText}` : currentText;
68601        const top = this.lexer.state.top;
68602        this.lexer.state.top = true;
68603        this.lexer.blockTokens(currentText, tokens, true);
68604        this.lexer.state.top = top;
68605        if (lines.length === 0) {
68606          break;
68607        }
68608        const lastToken = tokens.at(-1);
68609        if (lastToken?.type === "code") {
68610          break;
68611        } else if (lastToken?.type === "blockquote") {
68612          const oldToken = lastToken;
68613          const newText = oldToken.raw + "\n" + lines.join("\n");
68614          const newToken = this.blockquote(newText);
68615          tokens[tokens.length - 1] = newToken;
68616          raw = raw.substring(0, raw.length - oldToken.raw.length) + newToken.raw;
68617          text2 = text2.substring(0, text2.length - oldToken.text.length) + newToken.text;
68618          break;
68619        } else if (lastToken?.type === "list") {
68620          const oldToken = lastToken;
68621          const newText = oldToken.raw + "\n" + lines.join("\n");
68622          const newToken = this.list(newText);
68623          tokens[tokens.length - 1] = newToken;
68624          raw = raw.substring(0, raw.length - lastToken.raw.length) + newToken.raw;
68625          text2 = text2.substring(0, text2.length - oldToken.raw.length) + newToken.raw;
68626          lines = newText.substring(tokens.at(-1).raw.length).split("\n");
68627          continue;
68628        }
68629      }
68630      return {
68631        type: "blockquote",
68632        raw,
68633        tokens,
68634        text: text2
68635      };
68636    }
68637  }
68638  list(src) {
68639    let cap = this.rules.block.list.exec(src);
68640    if (cap) {
68641      let bull = cap[1].trim();
68642      const isordered = bull.length > 1;
68643      const list2 = {
68644        type: "list",
68645        raw: "",
68646        ordered: isordered,
68647        start: isordered ? +bull.slice(0, -1) : "",
68648        loose: false,
68649        items: []
68650      };
68651      bull = isordered ? `\\d{1,9}\\${bull.slice(-1)}` : `\\${bull}`;
68652      if (this.options.pedantic) {
68653        bull = isordered ? bull : "[*+-]";
68654      }
68655      const itemRegex = this.rules.other.listItemRegex(bull);
68656      let endsWithBlankLine = false;
68657      while (src) {
68658        let endEarly = false;
68659        let raw = "";
68660        let itemContents = "";
68661        if (!(cap = itemRegex.exec(src))) {
68662          break;
68663        }
68664        if (this.rules.block.hr.test(src)) {
68665          break;
68666        }
68667        raw = cap[0];
68668        src = src.substring(raw.length);
68669        let line = cap[2].split("\n", 1)[0].replace(this.rules.other.listReplaceTabs, (t) => " ".repeat(3 * t.length));
68670        let nextLine = src.split("\n", 1)[0];
68671        let blankLine = !line.trim();
68672        let indent = 0;
68673        if (this.options.pedantic) {
68674          indent = 2;
68675          itemContents = line.trimStart();
68676        } else if (blankLine) {
68677          indent = cap[1].length + 1;
68678        } else {
68679          indent = cap[2].search(this.rules.other.nonSpaceChar);
68680          indent = indent > 4 ? 1 : indent;
68681          itemContents = line.slice(indent);
68682          indent += cap[1].length;
68683        }
68684        if (blankLine && this.rules.other.blankLine.test(nextLine)) {
68685          raw += nextLine + "\n";
68686          src = src.substring(nextLine.length + 1);
68687          endEarly = true;
68688        }
68689        if (!endEarly) {
68690          const nextBulletRegex = this.rules.other.nextBulletRegex(indent);
68691          const hrRegex = this.rules.other.hrRegex(indent);
68692          const fencesBeginRegex = this.rules.other.fencesBeginRegex(indent);
68693          const headingBeginRegex = this.rules.other.headingBeginRegex(indent);
68694          const htmlBeginRegex = this.rules.other.htmlBeginRegex(indent);
68695          while (src) {
68696            const rawLine = src.split("\n", 1)[0];
68697            let nextLineWithoutTabs;
68698            nextLine = rawLine;
68699            if (this.options.pedantic) {
68700              nextLine = nextLine.replace(this.rules.other.listReplaceNesting, "  ");
68701              nextLineWithoutTabs = nextLine;
68702            } else {
68703              nextLineWithoutTabs = nextLine.replace(this.rules.other.tabCharGlobal, "    ");
68704            }
68705            if (fencesBeginRegex.test(nextLine)) {
68706              break;
68707            }
68708            if (headingBeginRegex.test(nextLine)) {
68709              break;
68710            }
68711            if (htmlBeginRegex.test(nextLine)) {
68712              break;
68713            }
68714            if (nextBulletRegex.test(nextLine)) {
68715              break;
68716            }
68717            if (hrRegex.test(nextLine)) {
68718              break;
68719            }
68720            if (nextLineWithoutTabs.search(this.rules.other.nonSpaceChar) >= indent || !nextLine.trim()) {
68721              itemContents += "\n" + nextLineWithoutTabs.slice(indent);
68722            } else {
68723              if (blankLine) {
68724                break;
68725              }
68726              if (line.replace(this.rules.other.tabCharGlobal, "    ").search(this.rules.other.nonSpaceChar) >= 4) {
68727                break;
68728              }
68729              if (fencesBeginRegex.test(line)) {
68730                break;
68731              }
68732              if (headingBeginRegex.test(line)) {
68733                break;
68734              }
68735              if (hrRegex.test(line)) {
68736                break;
68737              }
68738              itemContents += "\n" + nextLine;
68739            }
68740            if (!blankLine && !nextLine.trim()) {
68741              blankLine = true;
68742            }
68743            raw += rawLine + "\n";
68744            src = src.substring(rawLine.length + 1);
68745            line = nextLineWithoutTabs.slice(indent);
68746          }
68747        }
68748        if (!list2.loose) {
68749          if (endsWithBlankLine) {
68750            list2.loose = true;
68751          } else if (this.rules.other.doubleBlankLine.test(raw)) {
68752            endsWithBlankLine = true;
68753          }
68754        }
68755        let istask = null;
68756        let ischecked;
68757        if (this.options.gfm) {
68758          istask = this.rules.other.listIsTask.exec(itemContents);
68759          if (istask) {
68760            ischecked = istask[0] !== "[ ] ";
68761            itemContents = itemContents.replace(this.rules.other.listReplaceTask, "");
68762          }
68763        }
68764        list2.items.push({
68765          type: "list_item",
68766          raw,
68767          task: !!istask,
68768          checked: ischecked,
68769          loose: false,
68770          text: itemContents,
68771          tokens: []
68772        });
68773        list2.raw += raw;
68774      }
68775      const lastItem = list2.items.at(-1);
68776      if (lastItem) {
68777        lastItem.raw = lastItem.raw.trimEnd();
68778        lastItem.text = lastItem.text.trimEnd();
68779      } else {
68780        return;
68781      }
68782      list2.raw = list2.raw.trimEnd();
68783      for (let i = 0; i < list2.items.length; i++) {
68784        this.lexer.state.top = false;
68785        list2.items[i].tokens = this.lexer.blockTokens(list2.items[i].text, []);
68786        if (!list2.loose) {
68787          const spacers = list2.items[i].tokens.filter((t) => t.type === "space");
68788          const hasMultipleLineBreaks = spacers.length > 0 && spacers.some((t) => this.rules.other.anyLine.test(t.raw));
68789          list2.loose = hasMultipleLineBreaks;
68790        }
68791      }
68792      if (list2.loose) {
68793        for (let i = 0; i < list2.items.length; i++) {
68794          list2.items[i].loose = true;
68795        }
68796      }
68797      return list2;
68798    }
68799  }
68800  html(src) {
68801    const cap = this.rules.block.html.exec(src);
68802    if (cap) {
68803      const token = {
68804        type: "html",
68805        block: true,
68806        raw: cap[0],
68807        pre: cap[1] === "pre" || cap[1] === "script" || cap[1] === "style",
68808        text: cap[0]
68809      };
68810      return token;
68811    }
68812  }
68813  def(src) {
68814    const cap = this.rules.block.def.exec(src);
68815    if (cap) {
68816      const tag2 = cap[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal, " ");
68817      const href = cap[2] ? cap[2].replace(this.rules.other.hrefBrackets, "$1").replace(this.rules.inline.anyPunctuation, "$1") : "";
68818      const title = cap[3] ? cap[3].substring(1, cap[3].length - 1).replace(this.rules.inline.anyPunctuation, "$1") : cap[3];
68819      return {
68820        type: "def",
68821        tag: tag2,
68822        raw: cap[0],
68823        href,
68824        title
68825      };
68826    }
68827  }
68828  table(src) {
68829    const cap = this.rules.block.table.exec(src);
68830    if (!cap) {
68831      return;
68832    }
68833    if (!this.rules.other.tableDelimiter.test(cap[2])) {
68834      return;
68835    }
68836    const headers = splitCells(cap[1]);
68837    const aligns = cap[2].replace(this.rules.other.tableAlignChars, "").split("|");
68838    const rows = cap[3]?.trim() ? cap[3].replace(this.rules.other.tableRowBlankLine, "").split("\n") : [];
68839    const item = {
68840      type: "table",
68841      raw: cap[0],
68842      header: [],
68843      align: [],
68844      rows: []
68845    };
68846    if (headers.length !== aligns.length) {
68847      return;
68848    }
68849    for (const align of aligns) {
68850      if (this.rules.other.tableAlignRight.test(align)) {
68851        item.align.push("right");
68852      } else if (this.rules.other.tableAlignCenter.test(align)) {
68853        item.align.push("center");
68854      } else if (this.rules.other.tableAlignLeft.test(align)) {
68855        item.align.push("left");
68856      } else {
68857        item.align.push(null);
68858      }
68859    }
68860    for (let i = 0; i < headers.length; i++) {
68861      item.header.push({
68862        text: headers[i],
68863        tokens: this.lexer.inline(headers[i]),
68864        header: true,
68865        align: item.align[i]
68866      });
68867    }
68868    for (const row of rows) {
68869      item.rows.push(splitCells(row, item.header.length).map((cell, i) => {
68870        return {
68871          text: cell,
68872          tokens: this.lexer.inline(cell),
68873          header: false,
68874          align: item.align[i]
68875        };
68876      }));
68877    }
68878    return item;
68879  }
68880  lheading(src) {
68881    const cap = this.rules.block.lheading.exec(src);
68882    if (cap) {
68883      return {
68884        type: "heading",
68885        raw: cap[0],
68886        depth: cap[2].charAt(0) === "=" ? 1 : 2,
68887        text: cap[1],
68888        tokens: this.lexer.inline(cap[1])
68889      };
68890    }
68891  }
68892  paragraph(src) {
68893    const cap = this.rules.block.paragraph.exec(src);
68894    if (cap) {
68895      const text2 = cap[1].charAt(cap[1].length - 1) === "\n" ? cap[1].slice(0, -1) : cap[1];
68896      return {
68897        type: "paragraph",
68898        raw: cap[0],
68899        text: text2,
68900        tokens: this.lexer.inline(text2)
68901      };
68902    }
68903  }
68904  text(src) {
68905    const cap = this.rules.block.text.exec(src);
68906    if (cap) {
68907      return {
68908        type: "text",
68909        raw: cap[0],
68910        text: cap[0],
68911        tokens: this.lexer.inline(cap[0])
68912      };
68913    }
68914  }
68915  escape(src) {
68916    const cap = this.rules.inline.escape.exec(src);
68917    if (cap) {
68918      return {
68919        type: "escape",
68920        raw: cap[0],
68921        text: cap[1]
68922      };
68923    }
68924  }
68925  tag(src) {
68926    const cap = this.rules.inline.tag.exec(src);
68927    if (cap) {
68928      if (!this.lexer.state.inLink && this.rules.other.startATag.test(cap[0])) {
68929        this.lexer.state.inLink = true;
68930      } else if (this.lexer.state.inLink && this.rules.other.endATag.test(cap[0])) {
68931        this.lexer.state.inLink = false;
68932      }
68933      if (!this.lexer.state.inRawBlock && this.rules.other.startPreScriptTag.test(cap[0])) {
68934        this.lexer.state.inRawBlock = true;
68935      } else if (this.lexer.state.inRawBlock && this.rules.other.endPreScriptTag.test(cap[0])) {
68936        this.lexer.state.inRawBlock = false;
68937      }
68938      return {
68939        type: "html",
68940        raw: cap[0],
68941        inLink: this.lexer.state.inLink,
68942        inRawBlock: this.lexer.state.inRawBlock,
68943        block: false,
68944        text: cap[0]
68945      };
68946    }
68947  }
68948  link(src) {
68949    const cap = this.rules.inline.link.exec(src);
68950    if (cap) {
68951      const trimmedUrl = cap[2].trim();
68952      if (!this.options.pedantic && this.rules.other.startAngleBracket.test(trimmedUrl)) {
68953        if (!this.rules.other.endAngleBracket.test(trimmedUrl)) {
68954          return;
68955        }
68956        const rtrimSlash = rtrim(trimmedUrl.slice(0, -1), "\\");
68957        if ((trimmedUrl.length - rtrimSlash.length) % 2 === 0) {
68958          return;
68959        }
68960      } else {
68961        const lastParenIndex = findClosingBracket(cap[2], "()");
68962        if (lastParenIndex === -2) {
68963          return;
68964        }
68965        if (lastParenIndex > -1) {
68966          const start = cap[0].indexOf("!") === 0 ? 5 : 4;
68967          const linkLen = start + cap[1].length + lastParenIndex;
68968          cap[2] = cap[2].substring(0, lastParenIndex);
68969          cap[0] = cap[0].substring(0, linkLen).trim();
68970          cap[3] = "";
68971        }
68972      }
68973      let href = cap[2];
68974      let title = "";
68975      if (this.options.pedantic) {
68976        const link2 = this.rules.other.pedanticHrefTitle.exec(href);
68977        if (link2) {
68978          href = link2[1];
68979          title = link2[3];
68980        }
68981      } else {
68982        title = cap[3] ? cap[3].slice(1, -1) : "";
68983      }
68984      href = href.trim();
68985      if (this.rules.other.startAngleBracket.test(href)) {
68986        if (this.options.pedantic && !this.rules.other.endAngleBracket.test(trimmedUrl)) {
68987          href = href.slice(1);
68988        } else {
68989          href = href.slice(1, -1);
68990        }
68991      }
68992      return outputLink(cap, {
68993        href: href ? href.replace(this.rules.inline.anyPunctuation, "$1") : href,
68994        title: title ? title.replace(this.rules.inline.anyPunctuation, "$1") : title
68995      }, cap[0], this.lexer, this.rules);
68996    }
68997  }
68998  reflink(src, links) {
68999    let cap;
69000    if ((cap = this.rules.inline.reflink.exec(src)) || (cap = this.rules.inline.nolink.exec(src))) {
69001      const linkString = (cap[2] || cap[1]).replace(this.rules.other.multipleSpaceGlobal, " ");
69002      const link2 = links[linkString.toLowerCase()];
69003      if (!link2) {
69004        const text2 = cap[0].charAt(0);
69005        return {
69006          type: "text",
69007          raw: text2,
69008          text: text2
69009        };
69010      }
69011      return outputLink(cap, link2, cap[0], this.lexer, this.rules);
69012    }
69013  }
69014  emStrong(src, maskedSrc, prevChar = "") {
69015    let match = this.rules.inline.emStrongLDelim.exec(src);
69016    if (!match) return;
69017    if (match[3] && prevChar.match(this.rules.other.unicodeAlphaNumeric)) return;
69018    const nextChar = match[1] || match[2] || "";
69019    if (!nextChar || !prevChar || this.rules.inline.punctuation.exec(prevChar)) {
69020      const lLength = [...match[0]].length - 1;
69021      let rDelim, rLength, delimTotal = lLength, midDelimTotal = 0;
69022      const endReg = match[0][0] === "*" ? this.rules.inline.emStrongRDelimAst : this.rules.inline.emStrongRDelimUnd;
69023      endReg.lastIndex = 0;
69024      maskedSrc = maskedSrc.slice(-1 * src.length + lLength);
69025      while ((match = endReg.exec(maskedSrc)) != null) {
69026        rDelim = match[1] || match[2] || match[3] || match[4] || match[5] || match[6];
69027        if (!rDelim) continue;
69028        rLength = [...rDelim].length;
69029        if (match[3] || match[4]) {
69030          delimTotal += rLength;
69031          continue;
69032        } else if (match[5] || match[6]) {
69033          if (lLength % 3 && !((lLength + rLength) % 3)) {
69034            midDelimTotal += rLength;
69035            continue;
69036          }
69037        }
69038        delimTotal -= rLength;
69039        if (delimTotal > 0) continue;
69040        rLength = Math.min(rLength, rLength + delimTotal + midDelimTotal);
69041        const lastCharLength = [...match[0]][0].length;
69042        const raw = src.slice(0, lLength + match.index + lastCharLength + rLength);
69043        if (Math.min(lLength, rLength) % 2) {
69044          const text22 = raw.slice(1, -1);
69045          return {
69046            type: "em",
69047            raw,
69048            text: text22,
69049            tokens: this.lexer.inlineTokens(text22)
69050          };
69051        }
69052        const text2 = raw.slice(2, -2);
69053        return {
69054          type: "strong",
69055          raw,
69056          text: text2,
69057          tokens: this.lexer.inlineTokens(text2)
69058        };
69059      }
69060    }
69061  }
69062  codespan(src) {
69063    const cap = this.rules.inline.code.exec(src);
69064    if (cap) {
69065      let text2 = cap[2].replace(this.rules.other.newLineCharGlobal, " ");
69066      const hasNonSpaceChars = this.rules.other.nonSpaceChar.test(text2);
69067      const hasSpaceCharsOnBothEnds = this.rules.other.startingSpaceChar.test(text2) && this.rules.other.endingSpaceChar.test(text2);
69068      if (hasNonSpaceChars && hasSpaceCharsOnBothEnds) {
69069        text2 = text2.substring(1, text2.length - 1);
69070      }
69071      return {
69072        type: "codespan",
69073        raw: cap[0],
69074        text: text2
69075      };
69076    }
69077  }
69078  br(src) {
69079    const cap = this.rules.inline.br.exec(src);
69080    if (cap) {
69081      return {
69082        type: "br",
69083        raw: cap[0]
69084      };
69085    }
69086  }
69087  del(src) {
69088    const cap = this.rules.inline.del.exec(src);
69089    if (cap) {
69090      return {
69091        type: "del",
69092        raw: cap[0],
69093        text: cap[2],
69094        tokens: this.lexer.inlineTokens(cap[2])
69095      };
69096    }
69097  }
69098  autolink(src) {
69099    const cap = this.rules.inline.autolink.exec(src);
69100    if (cap) {
69101      let text2, href;
69102      if (cap[2] === "@") {
69103        text2 = cap[1];
69104        href = "mailto:" + text2;
69105      } else {
69106        text2 = cap[1];
69107        href = text2;
69108      }
69109      return {
69110        type: "link",
69111        raw: cap[0],
69112        text: text2,
69113        href,
69114        tokens: [{
69115          type: "text",
69116          raw: text2,
69117          text: text2
69118        }]
69119      };
69120    }
69121  }
69122  url(src) {
69123    let cap;
69124    if (cap = this.rules.inline.url.exec(src)) {
69125      let text2, href;
69126      if (cap[2] === "@") {
69127        text2 = cap[0];
69128        href = "mailto:" + text2;
69129      } else {
69130        let prevCapZero;
69131        do {
69132          prevCapZero = cap[0];
69133          cap[0] = this.rules.inline._backpedal.exec(cap[0])?.[0] ?? "";
69134        } while (prevCapZero !== cap[0]);
69135        text2 = cap[0];
69136        if (cap[1] === "www.") {
69137          href = "http://" + cap[0];
69138        } else {
69139          href = cap[0];
69140        }
69141      }
69142      return {
69143        type: "link",
69144        raw: cap[0],
69145        text: text2,
69146        href,
69147        tokens: [{
69148          type: "text",
69149          raw: text2,
69150          text: text2
69151        }]
69152      };
69153    }
69154  }
69155  inlineText(src) {
69156    const cap = this.rules.inline.text.exec(src);
69157    if (cap) {
69158      const escaped = this.lexer.state.inRawBlock;
69159      return {
69160        type: "text",
69161        raw: cap[0],
69162        text: cap[0],
69163        escaped
69164      };
69165    }
69166  }
69167};
69168var _Lexer = class __Lexer {
69169  tokens;
69170  options;
69171  state;
69172  tokenizer;
69173  inlineQueue;
69174  constructor(options2) {
69175    this.tokens = [];
69176    this.tokens.links = /* @__PURE__ */ Object.create(null);
69177    this.options = options2 || _defaults;
69178    this.options.tokenizer = this.options.tokenizer || new _Tokenizer();
69179    this.tokenizer = this.options.tokenizer;
69180    this.tokenizer.options = this.options;
69181    this.tokenizer.lexer = this;
69182    this.inlineQueue = [];
69183    this.state = {
69184      inLink: false,
69185      inRawBlock: false,
69186      top: true
69187    };
69188    const rules = {
69189      other,
69190      block: block.normal,
69191      inline: inline.normal
69192    };
69193    if (this.options.pedantic) {
69194      rules.block = block.pedantic;
69195      rules.inline = inline.pedantic;
69196    } else if (this.options.gfm) {
69197      rules.block = block.gfm;
69198      if (this.options.breaks) {
69199        rules.inline = inline.breaks;
69200      } else {
69201        rules.inline = inline.gfm;
69202      }
69203    }
69204    this.tokenizer.rules = rules;
69205  }
69206  /**
69207   * Expose Rules
69208   */
69209  static get rules() {
69210    return {
69211      block,
69212      inline
69213    };
69214  }
69215  /**
69216   * Static Lex Method
69217   */
69218  static lex(src, options2) {
69219    const lexer2 = new __Lexer(options2);
69220    return lexer2.lex(src);
69221  }
69222  /**
69223   * Static Lex Inline Method
69224   */
69225  static lexInline(src, options2) {
69226    const lexer2 = new __Lexer(options2);
69227    return lexer2.inlineTokens(src);
69228  }
69229  /**
69230   * Preprocessing
69231   */
69232  lex(src) {
69233    src = src.replace(other.carriageReturn, "\n");
69234    this.blockTokens(src, this.tokens);
69235    for (let i = 0; i < this.inlineQueue.length; i++) {
69236      const next = this.inlineQueue[i];
69237      this.inlineTokens(next.src, next.tokens);
69238    }
69239    this.inlineQueue = [];
69240    return this.tokens;
69241  }
69242  blockTokens(src, tokens = [], lastParagraphClipped = false) {
69243    if (this.options.pedantic) {
69244      src = src.replace(other.tabCharGlobal, "    ").replace(other.spaceLine, "");
69245    }
69246    while (src) {
69247      let token;
69248      if (this.options.extensions?.block?.some((extTokenizer) => {
69249        if (token = extTokenizer.call({
69250          lexer: this
69251        }, src, tokens)) {
69252          src = src.substring(token.raw.length);
69253          tokens.push(token);
69254          return true;
69255        }
69256        return false;
69257      })) {
69258        continue;
69259      }
69260      if (token = this.tokenizer.space(src)) {
69261        src = src.substring(token.raw.length);
69262        const lastToken = tokens.at(-1);
69263        if (token.raw.length === 1 && lastToken !== void 0) {
69264          lastToken.raw += "\n";
69265        } else {
69266          tokens.push(token);
69267        }
69268        continue;
69269      }
69270      if (token = this.tokenizer.code(src)) {
69271        src = src.substring(token.raw.length);
69272        const lastToken = tokens.at(-1);
69273        if (lastToken?.type === "paragraph" || lastToken?.type === "text") {
69274          lastToken.raw += "\n" + token.raw;
69275          lastToken.text += "\n" + token.text;
69276          this.inlineQueue.at(-1).src = lastToken.text;
69277        } else {
69278          tokens.push(token);
69279        }
69280        continue;
69281      }
69282      if (token = this.tokenizer.fences(src)) {
69283        src = src.substring(token.raw.length);
69284        tokens.push(token);
69285        continue;
69286      }
69287      if (token = this.tokenizer.heading(src)) {
69288        src = src.substring(token.raw.length);
69289        tokens.push(token);
69290        continue;
69291      }
69292      if (token = this.tokenizer.hr(src)) {
69293        src = src.substring(token.raw.length);
69294        tokens.push(token);
69295        continue;
69296      }
69297      if (token = this.tokenizer.blockquote(src)) {
69298        src = src.substring(token.raw.length);
69299        tokens.push(token);
69300        continue;
69301      }
69302      if (token = this.tokenizer.list(src)) {
69303        src = src.substring(token.raw.length);
69304        tokens.push(token);
69305        continue;
69306      }
69307      if (token = this.tokenizer.html(src)) {
69308        src = src.substring(token.raw.length);
69309        tokens.push(token);
69310        continue;
69311      }
69312      if (token = this.tokenizer.def(src)) {
69313        src = src.substring(token.raw.length);
69314        const lastToken = tokens.at(-1);
69315        if (lastToken?.type === "paragraph" || lastToken?.type === "text") {
69316          lastToken.raw += "\n" + token.raw;
69317          lastToken.text += "\n" + token.raw;
69318          this.inlineQueue.at(-1).src = lastToken.text;
69319        } else if (!this.tokens.links[token.tag]) {
69320          this.tokens.links[token.tag] = {
69321            href: token.href,
69322            title: token.title
69323          };
69324        }
69325        continue;
69326      }
69327      if (token = this.tokenizer.table(src)) {
69328        src = src.substring(token.raw.length);
69329        tokens.push(token);
69330        continue;
69331      }
69332      if (token = this.tokenizer.lheading(src)) {
69333        src = src.substring(token.raw.length);
69334        tokens.push(token);
69335        continue;
69336      }
69337      let cutSrc = src;
69338      if (this.options.extensions?.startBlock) {
69339        let startIndex = Infinity;
69340        const tempSrc = src.slice(1);
69341        let tempStart;
69342        this.options.extensions.startBlock.forEach((getStartIndex) => {
69343          tempStart = getStartIndex.call({
69344            lexer: this
69345          }, tempSrc);
69346          if (typeof tempStart === "number" && tempStart >= 0) {
69347            startIndex = Math.min(startIndex, tempStart);
69348          }
69349        });
69350        if (startIndex < Infinity && startIndex >= 0) {
69351          cutSrc = src.substring(0, startIndex + 1);
69352        }
69353      }
69354      if (this.state.top && (token = this.tokenizer.paragraph(cutSrc))) {
69355        const lastToken = tokens.at(-1);
69356        if (lastParagraphClipped && lastToken?.type === "paragraph") {
69357          lastToken.raw += "\n" + token.raw;
69358          lastToken.text += "\n" + token.text;
69359          this.inlineQueue.pop();
69360          this.inlineQueue.at(-1).src = lastToken.text;
69361        } else {
69362          tokens.push(token);
69363        }
69364        lastParagraphClipped = cutSrc.length !== src.length;
69365        src = src.substring(token.raw.length);
69366        continue;
69367      }
69368      if (token = this.tokenizer.text(src)) {
69369        src = src.substring(token.raw.length);
69370        const lastToken = tokens.at(-1);
69371        if (lastToken?.type === "text") {
69372          lastToken.raw += "\n" + token.raw;
69373          lastToken.text += "\n" + token.text;
69374          this.inlineQueue.pop();
69375          this.inlineQueue.at(-1).src = lastToken.text;
69376        } else {
69377          tokens.push(token);
69378        }
69379        continue;
69380      }
69381      if (src) {
69382        const errMsg = "Infinite loop on byte: " + src.charCodeAt(0);
69383        if (this.options.silent) {
69384          console.error(errMsg);
69385          break;
69386        } else {
69387          throw new Error(errMsg);
69388        }
69389      }
69390    }
69391    this.state.top = true;
69392    return tokens;
69393  }
69394  inline(src, tokens = []) {
69395    this.inlineQueue.push({
69396      src,
69397      tokens
69398    });
69399    return tokens;
69400  }
69401  /**
69402   * Lexing/Compiling
69403   */
69404  inlineTokens(src, tokens = []) {
69405    let maskedSrc = src;
69406    let match = null;
69407    if (this.tokens.links) {
69408      const links = Object.keys(this.tokens.links);
69409      if (links.length > 0) {
69410        while ((match = this.tokenizer.rules.inline.reflinkSearch.exec(maskedSrc)) != null) {
69411          if (links.includes(match[0].slice(match[0].lastIndexOf("[") + 1, -1))) {
69412            maskedSrc = maskedSrc.slice(0, match.index) + "[" + "a".repeat(match[0].length - 2) + "]" + maskedSrc.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex);
69413          }
69414        }
69415      }
69416    }
69417    while ((match = this.tokenizer.rules.inline.anyPunctuation.exec(maskedSrc)) != null) {
69418      maskedSrc = maskedSrc.slice(0, match.index) + "++" + maskedSrc.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);
69419    }
69420    while ((match = this.tokenizer.rules.inline.blockSkip.exec(maskedSrc)) != null) {
69421      maskedSrc = maskedSrc.slice(0, match.index) + "[" + "a".repeat(match[0].length - 2) + "]" + maskedSrc.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);
69422    }
69423    let keepPrevChar = false;
69424    let prevChar = "";
69425    while (src) {
69426      if (!keepPrevChar) {
69427        prevChar = "";
69428      }
69429      keepPrevChar = false;
69430      let token;
69431      if (this.options.extensions?.inline?.some((extTokenizer) => {
69432        if (token = extTokenizer.call({
69433          lexer: this
69434        }, src, tokens)) {
69435          src = src.substring(token.raw.length);
69436          tokens.push(token);
69437          return true;
69438        }
69439        return false;
69440      })) {
69441        continue;
69442      }
69443      if (token = this.tokenizer.escape(src)) {
69444        src = src.substring(token.raw.length);
69445        tokens.push(token);
69446        continue;
69447      }
69448      if (token = this.tokenizer.tag(src)) {
69449        src = src.substring(token.raw.length);
69450        tokens.push(token);
69451        continue;
69452      }
69453      if (token = this.tokenizer.link(src)) {
69454        src = src.substring(token.raw.length);
69455        tokens.push(token);
69456        continue;
69457      }
69458      if (token = this.tokenizer.reflink(src, this.tokens.links)) {
69459        src = src.substring(token.raw.length);
69460        const lastToken = tokens.at(-1);
69461        if (token.type === "text" && lastToken?.type === "text") {
69462          lastToken.raw += token.raw;
69463          lastToken.text += token.text;
69464        } else {
69465          tokens.push(token);
69466        }
69467        continue;
69468      }
69469      if (token = this.tokenizer.emStrong(src, maskedSrc, prevChar)) {
69470        src = src.substring(token.raw.length);
69471        tokens.push(token);
69472        continue;
69473      }
69474      if (token = this.tokenizer.codespan(src)) {
69475        src = src.substring(token.raw.length);
69476        tokens.push(token);
69477        continue;
69478      }
69479      if (token = this.tokenizer.br(src)) {
69480        src = src.substring(token.raw.length);
69481        tokens.push(token);
69482        continue;
69483      }
69484      if (token = this.tokenizer.del(src)) {
69485        src = src.substring(token.raw.length);
69486        tokens.push(token);
69487        continue;
69488      }
69489      if (token = this.tokenizer.autolink(src)) {
69490        src = src.substring(token.raw.length);
69491        tokens.push(token);
69492        continue;
69493      }
69494      if (!this.state.inLink && (token = this.tokenizer.url(src))) {
69495        src = src.substring(token.raw.length);
69496        tokens.push(token);
69497        continue;
69498      }
69499      let cutSrc = src;
69500      if (this.options.extensions?.startInline) {
69501        let startIndex = Infinity;
69502        const tempSrc = src.slice(1);
69503        let tempStart;
69504        this.options.extensions.startInline.forEach((getStartIndex) => {
69505          tempStart = getStartIndex.call({
69506            lexer: this
69507          }, tempSrc);
69508          if (typeof tempStart === "number" && tempStart >= 0) {
69509            startIndex = Math.min(startIndex, tempStart);
69510          }
69511        });
69512        if (startIndex < Infinity && startIndex >= 0) {
69513          cutSrc = src.substring(0, startIndex + 1);
69514        }
69515      }
69516      if (token = this.tokenizer.inlineText(cutSrc)) {
69517        src = src.substring(token.raw.length);
69518        if (token.raw.slice(-1) !== "_") {
69519          prevChar = token.raw.slice(-1);
69520        }
69521        keepPrevChar = true;
69522        const lastToken = tokens.at(-1);
69523        if (lastToken?.type === "text") {
69524          lastToken.raw += token.raw;
69525          lastToken.text += token.text;
69526        } else {
69527          tokens.push(token);
69528        }
69529        continue;
69530      }
69531      if (src) {
69532        const errMsg = "Infinite loop on byte: " + src.charCodeAt(0);
69533        if (this.options.silent) {
69534          console.error(errMsg);
69535          break;
69536        } else {
69537          throw new Error(errMsg);
69538        }
69539      }
69540    }
69541    return tokens;
69542  }
69543};
69544var _Renderer = class {
69545  options;
69546  parser;
69547  // set by the parser
69548  constructor(options2) {
69549    this.options = options2 || _defaults;
69550  }
69551  space(token) {
69552    return "";
69553  }
69554  code({
69555    text: text2,
69556    lang,
69557    escaped
69558  }) {
69559    const langString = (lang || "").match(other.notSpaceStart)?.[0];
69560    const code = text2.replace(other.endingNewline, "") + "\n";
69561    if (!langString) {
69562      return "<pre><code>" + (escaped ? code : escape22(code, true)) + "</code></pre>\n";
69563    }
69564    return '<pre><code class="language-' + escape22(langString) + '">' + (escaped ? code : escape22(code, true)) + "</code></pre>\n";
69565  }
69566  blockquote({
69567    tokens
69568  }) {
69569    const body = this.parser.parse(tokens);
69570    return `<blockquote>
69571${body}</blockquote>
69572`;
69573  }
69574  html({
69575    text: text2
69576  }) {
69577    return text2;
69578  }
69579  heading({
69580    tokens,
69581    depth
69582  }) {
69583    return `<h${depth}>${this.parser.parseInline(tokens)}</h${depth}>
69584`;
69585  }
69586  hr(token) {
69587    return "<hr>\n";
69588  }
69589  list(token) {
69590    const ordered = token.ordered;
69591    const start = token.start;
69592    let body = "";
69593    for (let j = 0; j < token.items.length; j++) {
69594      const item = token.items[j];
69595      body += this.listitem(item);
69596    }
69597    const type = ordered ? "ol" : "ul";
69598    const startAttr = ordered && start !== 1 ? ' start="' + start + '"' : "";
69599    return "<" + type + startAttr + ">\n" + body + "</" + type + ">\n";
69600  }
69601  listitem(item) {
69602    let itemBody = "";
69603    if (item.task) {
69604      const checkbox = this.checkbox({
69605        checked: !!item.checked
69606      });
69607      if (item.loose) {
69608        if (item.tokens[0]?.type === "paragraph") {
69609          item.tokens[0].text = checkbox + " " + item.tokens[0].text;
69610          if (item.tokens[0].tokens && item.tokens[0].tokens.length > 0 && item.tokens[0].tokens[0].type === "text") {
69611            item.tokens[0].tokens[0].text = checkbox + " " + escape22(item.tokens[0].tokens[0].text);
69612            item.tokens[0].tokens[0].escaped = true;
69613          }
69614        } else {
69615          item.tokens.unshift({
69616            type: "text",
69617            raw: checkbox + " ",
69618            text: checkbox + " ",
69619            escaped: true
69620          });
69621        }
69622      } else {
69623        itemBody += checkbox + " ";
69624      }
69625    }
69626    itemBody += this.parser.parse(item.tokens, !!item.loose);
69627    return `<li>${itemBody}</li>
69628`;
69629  }
69630  checkbox({
69631    checked
69632  }) {
69633    return "<input " + (checked ? 'checked="" ' : "") + 'disabled="" type="checkbox">';
69634  }
69635  paragraph({
69636    tokens
69637  }) {
69638    return `<p>${this.parser.parseInline(tokens)}</p>
69639`;
69640  }
69641  table(token) {
69642    let header = "";
69643    let cell = "";
69644    for (let j = 0; j < token.header.length; j++) {
69645      cell += this.tablecell(token.header[j]);
69646    }
69647    header += this.tablerow({
69648      text: cell
69649    });
69650    let body = "";
69651    for (let j = 0; j < token.rows.length; j++) {
69652      const row = token.rows[j];
69653      cell = "";
69654      for (let k = 0; k < row.length; k++) {
69655        cell += this.tablecell(row[k]);
69656      }
69657      body += this.tablerow({
69658        text: cell
69659      });
69660    }
69661    if (body) body = `<tbody>${body}</tbody>`;
69662    return "<table>\n<thead>\n" + header + "</thead>\n" + body + "</table>\n";
69663  }
69664  tablerow({
69665    text: text2
69666  }) {
69667    return `<tr>
69668${text2}</tr>
69669`;
69670  }
69671  tablecell(token) {
69672    const content = this.parser.parseInline(token.tokens);
69673    const type = token.header ? "th" : "td";
69674    const tag2 = token.align ? `<${type} align="${token.align}">` : `<${type}>`;
69675    return tag2 + content + `</${type}>
69676`;
69677  }
69678  /**
69679   * span level renderer
69680   */
69681  strong({
69682    tokens
69683  }) {
69684    return `<strong>${this.parser.parseInline(tokens)}</strong>`;
69685  }
69686  em({
69687    tokens
69688  }) {
69689    return `<em>${this.parser.parseInline(tokens)}</em>`;
69690  }
69691  codespan({
69692    text: text2
69693  }) {
69694    return `<code>${escape22(text2, true)}</code>`;
69695  }
69696  br(token) {
69697    return "<br>";
69698  }
69699  del({
69700    tokens
69701  }) {
69702    return `<del>${this.parser.parseInline(tokens)}</del>`;
69703  }
69704  link({
69705    href,
69706    title,
69707    tokens
69708  }) {
69709    const text2 = this.parser.parseInline(tokens);
69710    const cleanHref = cleanUrl(href);
69711    if (cleanHref === null) {
69712      return text2;
69713    }
69714    href = cleanHref;
69715    let out = '<a href="' + href + '"';
69716    if (title) {
69717      out += ' title="' + escape22(title) + '"';
69718    }
69719    out += ">" + text2 + "</a>";
69720    return out;
69721  }
69722  image({
69723    href,
69724    title,
69725    text: text2,
69726    tokens
69727  }) {
69728    if (tokens) {
69729      text2 = this.parser.parseInline(tokens, this.parser.textRenderer);
69730    }
69731    const cleanHref = cleanUrl(href);
69732    if (cleanHref === null) {
69733      return escape22(text2);
69734    }
69735    href = cleanHref;
69736    let out = `<img src="${href}" alt="${text2}"`;
69737    if (title) {
69738      out += ` title="${escape22(title)}"`;
69739    }
69740    out += ">";
69741    return out;
69742  }
69743  text(token) {
69744    return "tokens" in token && token.tokens ? this.parser.parseInline(token.tokens) : "escaped" in token && token.escaped ? token.text : escape22(token.text);
69745  }
69746};
69747var _TextRenderer = class {
69748  // no need for block level renderers
69749  strong({
69750    text: text2
69751  }) {
69752    return text2;
69753  }
69754  em({
69755    text: text2
69756  }) {
69757    return text2;
69758  }
69759  codespan({
69760    text: text2
69761  }) {
69762    return text2;
69763  }
69764  del({
69765    text: text2
69766  }) {
69767    return text2;
69768  }
69769  html({
69770    text: text2
69771  }) {
69772    return text2;
69773  }
69774  text({
69775    text: text2
69776  }) {
69777    return text2;
69778  }
69779  link({
69780    text: text2
69781  }) {
69782    return "" + text2;
69783  }
69784  image({
69785    text: text2
69786  }) {
69787    return "" + text2;
69788  }
69789  br() {
69790    return "";
69791  }
69792};
69793var _Parser = class __Parser {
69794  options;
69795  renderer;
69796  textRenderer;
69797  constructor(options2) {
69798    this.options = options2 || _defaults;
69799    this.options.renderer = this.options.renderer || new _Renderer();
69800    this.renderer = this.options.renderer;
69801    this.renderer.options = this.options;
69802    this.renderer.parser = this;
69803    this.textRenderer = new _TextRenderer();
69804  }
69805  /**
69806   * Static Parse Method
69807   */
69808  static parse(tokens, options2) {
69809    const parser2 = new __Parser(options2);
69810    return parser2.parse(tokens);
69811  }
69812  /**
69813   * Static Parse Inline Method
69814   */
69815  static parseInline(tokens, options2) {
69816    const parser2 = new __Parser(options2);
69817    return parser2.parseInline(tokens);
69818  }
69819  /**
69820   * Parse Loop
69821   */
69822  parse(tokens, top = true) {
69823    let out = "";
69824    for (let i = 0; i < tokens.length; i++) {
69825      const anyToken = tokens[i];
69826      if (this.options.extensions?.renderers?.[anyToken.type]) {
69827        const genericToken = anyToken;
69828        const ret = this.options.extensions.renderers[genericToken.type].call({
69829          parser: this
69830        }, genericToken);
69831        if (ret !== false || !["space", "hr", "heading", "code", "table", "blockquote", "list", "html", "paragraph", "text"].includes(genericToken.type)) {
69832          out += ret || "";
69833          continue;
69834        }
69835      }
69836      const token = anyToken;
69837      switch (token.type) {
69838        case "space": {
69839          out += this.renderer.space(token);
69840          continue;
69841        }
69842        case "hr": {
69843          out += this.renderer.hr(token);
69844          continue;
69845        }
69846        case "heading": {
69847          out += this.renderer.heading(token);
69848          continue;
69849        }
69850        case "code": {
69851          out += this.renderer.code(token);
69852          continue;
69853        }
69854        case "table": {
69855          out += this.renderer.table(token);
69856          continue;
69857        }
69858        case "blockquote": {
69859          out += this.renderer.blockquote(token);
69860          continue;
69861        }
69862        case "list": {
69863          out += this.renderer.list(token);
69864          continue;
69865        }
69866        case "html": {
69867          out += this.renderer.html(token);
69868          continue;
69869        }
69870        case "paragraph": {
69871          out += this.renderer.paragraph(token);
69872          continue;
69873        }
69874        case "text": {
69875          let textToken = token;
69876          let body = this.renderer.text(textToken);
69877          while (i + 1 < tokens.length && tokens[i + 1].type === "text") {
69878            textToken = tokens[++i];
69879            body += "\n" + this.renderer.text(textToken);
69880          }
69881          if (top) {
69882            out += this.renderer.paragraph({
69883              type: "paragraph",
69884              raw: body,
69885              text: body,
69886              tokens: [{
69887                type: "text",
69888                raw: body,
69889                text: body,
69890                escaped: true
69891              }]
69892            });
69893          } else {
69894            out += body;
69895          }
69896          continue;
69897        }
69898        default: {
69899          const errMsg = 'Token with "' + token.type + '" type was not found.';
69900          if (this.options.silent) {
69901            console.error(errMsg);
69902            return "";
69903          } else {
69904            throw new Error(errMsg);
69905          }
69906        }
69907      }
69908    }
69909    return out;
69910  }
69911  /**
69912   * Parse Inline Tokens
69913   */
69914  parseInline(tokens, renderer = this.renderer) {
69915    let out = "";
69916    for (let i = 0; i < tokens.length; i++) {
69917      const anyToken = tokens[i];
69918      if (this.options.extensions?.renderers?.[anyToken.type]) {
69919        const ret = this.options.extensions.renderers[anyToken.type].call({
69920          parser: this
69921        }, anyToken);
69922        if (ret !== false || !["escape", "html", "link", "image", "strong", "em", "codespan", "br", "del", "text"].includes(anyToken.type)) {
69923          out += ret || "";
69924          continue;
69925        }
69926      }
69927      const token = anyToken;
69928      switch (token.type) {
69929        case "escape": {
69930          out += renderer.text(token);
69931          break;
69932        }
69933        case "html": {
69934          out += renderer.html(token);
69935          break;
69936        }
69937        case "link": {
69938          out += renderer.link(token);
69939          break;
69940        }
69941        case "image": {
69942          out += renderer.image(token);
69943          break;
69944        }
69945        case "strong": {
69946          out += renderer.strong(token);
69947          break;
69948        }
69949        case "em": {
69950          out += renderer.em(token);
69951          break;
69952        }
69953        case "codespan": {
69954          out += renderer.codespan(token);
69955          break;
69956        }
69957        case "br": {
69958          out += renderer.br(token);
69959          break;
69960        }
69961        case "del": {
69962          out += renderer.del(token);
69963          break;
69964        }
69965        case "text": {
69966          out += renderer.text(token);
69967          break;
69968        }
69969        default: {
69970          const errMsg = 'Token with "' + token.type + '" type was not found.';
69971          if (this.options.silent) {
69972            console.error(errMsg);
69973            return "";
69974          } else {
69975            throw new Error(errMsg);
69976          }
69977        }
69978      }
69979    }
69980    return out;
69981  }
69982};
69983var _Hooks = class {
69984  options;
69985  block;
69986  constructor(options2) {
69987    this.options = options2 || _defaults;
69988  }
69989  static passThroughHooks = /* @__PURE__ */ new Set(["preprocess", "postprocess", "processAllTokens"]);
69990  /**
69991   * Process markdown before marked
69992   */
69993  preprocess(markdown) {
69994    return markdown;
69995  }
69996  /**
69997   * Process HTML after marked is finished
69998   */
69999  postprocess(html2) {
70000    return html2;
70001  }
70002  /**
70003   * Process all tokens before walk tokens
70004   */
70005  processAllTokens(tokens) {
70006    return tokens;
70007  }
70008  /**
70009   * Provide function to tokenize markdown
70010   */
70011  provideLexer() {
70012    return this.block ? _Lexer.lex : _Lexer.lexInline;
70013  }
70014  /**
70015   * Provide function to parse tokens
70016   */
70017  provideParser() {
70018    return this.block ? _Parser.parse : _Parser.parseInline;
70019  }
70020};
70021var Marked = class {
70022  defaults = _getDefaults();
70023  options = this.setOptions;
70024  parse = this.parseMarkdown(true);
70025  parseInline = this.parseMarkdown(false);
70026  Parser = _Parser;
70027  Renderer = _Renderer;
70028  TextRenderer = _TextRenderer;
70029  Lexer = _Lexer;
70030  Tokenizer = _Tokenizer;
70031  Hooks = _Hooks;
70032  constructor(...args) {
70033    this.use(...args);
70034  }
70035  /**
70036   * Run callback for every token
70037   */
70038  walkTokens(tokens, callback) {
70039    let values = [];
70040    for (const token of tokens) {
70041      values = values.concat(callback.call(this, token));
70042      switch (token.type) {
70043        case "table": {
70044          const tableToken = token;
70045          for (const cell of tableToken.header) {
70046            values = values.concat(this.walkTokens(cell.tokens, callback));
70047          }
70048          for (const row of tableToken.rows) {
70049            for (const cell of row) {
70050              values = values.concat(this.walkTokens(cell.tokens, callback));
70051            }
70052          }
70053          break;
70054        }
70055        case "list": {
70056          const listToken = token;
70057          values = values.concat(this.walkTokens(listToken.items, callback));
70058          break;
70059        }
70060        default: {
70061          const genericToken = token;
70062          if (this.defaults.extensions?.childTokens?.[genericToken.type]) {
70063            this.defaults.extensions.childTokens[genericToken.type].forEach((childTokens) => {
70064              const tokens2 = genericToken[childTokens].flat(Infinity);
70065              values = values.concat(this.walkTokens(tokens2, callback));
70066            });
70067          } else if (genericToken.tokens) {
70068            values = values.concat(this.walkTokens(genericToken.tokens, callback));
70069          }
70070        }
70071      }
70072    }
70073    return values;
70074  }
70075  use(...args) {
70076    const extensions = this.defaults.extensions || {
70077      renderers: {},
70078      childTokens: {}
70079    };
70080    args.forEach((pack) => {
70081      const opts = __spreadValues({}, pack);
70082      opts.async = this.defaults.async || opts.async || false;
70083      if (pack.extensions) {
70084        pack.extensions.forEach((ext) => {
70085          if (!ext.name) {
70086            throw new Error("extension name required");
70087          }
70088          if ("renderer" in ext) {
70089            const prevRenderer = extensions.renderers[ext.name];
70090            if (prevRenderer) {
70091              extensions.renderers[ext.name] = function(...args2) {
70092                let ret = ext.renderer.apply(this, args2);
70093                if (ret === false) {
70094                  ret = prevRenderer.apply(this, args2);
70095                }
70096                return ret;
70097              };
70098            } else {
70099              extensions.renderers[ext.name] = ext.renderer;
70100            }
70101          }
70102          if ("tokenizer" in ext) {
70103            if (!ext.level || ext.level !== "block" && ext.level !== "inline") {
70104              throw new Error("extension level must be 'block' or 'inline'");
70105            }
70106            const extLevel = extensions[ext.level];
70107            if (extLevel) {
70108              extLevel.unshift(ext.tokenizer);
70109            } else {
70110              extensions[ext.level] = [ext.tokenizer];
70111            }
70112            if (ext.start) {
70113              if (ext.level === "block") {
70114                if (extensions.startBlock) {
70115                  extensions.startBlock.push(ext.start);
70116                } else {
70117                  extensions.startBlock = [ext.start];
70118                }
70119              } else if (ext.level === "inline") {
70120                if (extensions.startInline) {
70121                  extensions.startInline.push(ext.start);
70122                } else {
70123                  extensions.startInline = [ext.start];
70124                }
70125              }
70126            }
70127          }
70128          if ("childTokens" in ext && ext.childTokens) {
70129            extensions.childTokens[ext.name] = ext.childTokens;
70130          }
70131        });
70132        opts.extensions = extensions;
70133      }
70134      if (pack.renderer) {
70135        const renderer = this.defaults.renderer || new _Renderer(this.defaults);
70136        for (const prop in pack.renderer) {
70137          if (!(prop in renderer)) {
70138            throw new Error(`renderer '${prop}' does not exist`);
70139          }
70140          if (["options", "parser"].includes(prop)) {
70141            continue;
70142          }
70143          const rendererProp = prop;
70144          const rendererFunc = pack.renderer[rendererProp];
70145          const prevRenderer = renderer[rendererProp];
70146          renderer[rendererProp] = (...args2) => {
70147            let ret = rendererFunc.apply(renderer, args2);
70148            if (ret === false) {
70149              ret = prevRenderer.apply(renderer, args2);
70150            }
70151            return ret || "";
70152          };
70153        }
70154        opts.renderer = renderer;
70155      }
70156      if (pack.tokenizer) {
70157        const tokenizer = this.defaults.tokenizer || new _Tokenizer(this.defaults);
70158        for (const prop in pack.tokenizer) {
70159          if (!(prop in tokenizer)) {
70160            throw new Error(`tokenizer '${prop}' does not exist`);
70161          }
70162          if (["options", "rules", "lexer"].includes(prop)) {
70163            continue;
70164          }
70165          const tokenizerProp = prop;
70166          const tokenizerFunc = pack.tokenizer[tokenizerProp];
70167          const prevTokenizer = tokenizer[tokenizerProp];
70168          tokenizer[tokenizerProp] = (...args2) => {
70169            let ret = tokenizerFunc.apply(tokenizer, args2);
70170            if (ret === false) {
70171              ret = prevTokenizer.apply(tokenizer, args2);
70172            }
70173            return ret;
70174          };
70175        }
70176        opts.tokenizer = tokenizer;
70177      }
70178      if (pack.hooks) {
70179        const hooks = this.defaults.hooks || new _Hooks();
70180        for (const prop in pack.hooks) {
70181          if (!(prop in hooks)) {
70182            throw new Error(`hook '${prop}' does not exist`);
70183          }
70184          if (["options", "block"].includes(prop)) {
70185            continue;
70186          }
70187          const hooksProp = prop;
70188          const hooksFunc = pack.hooks[hooksProp];
70189          const prevHook = hooks[hooksProp];
70190          if (_Hooks.passThroughHooks.has(prop)) {
70191            hooks[hooksProp] = (arg) => {
70192              if (this.defaults.async) {
70193                return Promise.resolve(hooksFunc.call(hooks, arg)).then((ret2) => {
70194                  return prevHook.call(hooks, ret2);
70195                });
70196              }
70197              const ret = hooksFunc.call(hooks, arg);
70198              return prevHook.call(hooks, ret);
70199            };
70200          } else {
70201            hooks[hooksProp] = (...args2) => {
70202              let ret = hooksFunc.apply(hooks, args2);
70203              if (ret === false) {
70204                ret = prevHook.apply(hooks, args2);
70205              }
70206              return ret;
70207            };
70208          }
70209        }
70210        opts.hooks = hooks;
70211      }
70212      if (pack.walkTokens) {
70213        const walkTokens2 = this.defaults.walkTokens;
70214        const packWalktokens = pack.walkTokens;
70215        opts.walkTokens = function(token) {
70216          let values = [];
70217          values.push(packWalktokens.call(this, token));
70218          if (walkTokens2) {
70219            values = values.concat(walkTokens2.call(this, token));
70220          }
70221          return values;
70222        };
70223      }
70224      this.defaults = __spreadValues(__spreadValues({}, this.defaults), opts);
70225    });
70226    return this;
70227  }
70228  setOptions(opt) {
70229    this.defaults = __spreadValues(__spreadValues({}, this.defaults), opt);
70230    return this;
70231  }
70232  lexer(src, options2) {
70233    return _Lexer.lex(src, options2 ?? this.defaults);
70234  }
70235  parser(tokens, options2) {
70236    return _Parser.parse(tokens, options2 ?? this.defaults);
70237  }
70238  parseMarkdown(blockType) {
70239    const parse2 = (src, options2) => {
70240      const origOpt = __spreadValues({}, options2);
70241      const opt = __spreadValues(__spreadValues({}, this.defaults), origOpt);
70242      const throwError = this.onError(!!opt.silent, !!opt.async);
70243      if (this.defaults.async === true && origOpt.async === false) {
70244        return throwError(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));
70245      }
70246      if (typeof src === "undefined" || src === null) {
70247        return throwError(new Error("marked(): input parameter is undefined or null"));
70248      }
70249      if (typeof src !== "string") {
70250        return throwError(new Error("marked(): input parameter is of type " + Object.prototype.toString.call(src) + ", string expected"));
70251      }
70252      if (opt.hooks) {
70253        opt.hooks.options = opt;
70254        opt.hooks.block = blockType;
70255      }
70256      const lexer2 = opt.hooks ? opt.hooks.provideLexer() : blockType ? _Lexer.lex : _Lexer.lexInline;
70257      const parser2 = opt.hooks ? opt.hooks.provideParser() : blockType ? _Parser.parse : _Parser.parseInline;
70258      if (opt.async) {
70259        return Promise.resolve(opt.hooks ? opt.hooks.preprocess(src) : src).then((src2) => lexer2(src2, opt)).then((tokens) => opt.hooks ? opt.hooks.processAllTokens(tokens) : tokens).then((tokens) => opt.walkTokens ? Promise.all(this.walkTokens(tokens, opt.walkTokens)).then(() => tokens) : tokens).then((tokens) => parser2(tokens, opt)).then((html2) => opt.hooks ? opt.hooks.postprocess(html2) : html2).catch(throwError);
70260      }
70261      try {
70262        if (opt.hooks) {
70263          src = opt.hooks.preprocess(src);
70264        }
70265        let tokens = lexer2(src, opt);
70266        if (opt.hooks) {
70267          tokens = opt.hooks.processAllTokens(tokens);
70268        }
70269        if (opt.walkTokens) {
70270          this.walkTokens(tokens, opt.walkTokens);
70271        }
70272        let html2 = parser2(tokens, opt);
70273        if (opt.hooks) {
70274          html2 = opt.hooks.postprocess(html2);
70275        }
70276        return html2;
70277      } catch (e) {
70278        return throwError(e);
70279      }
70280    };
70281    return parse2;
70282  }
70283  onError(silent, async) {
70284    return (e) => {
70285      e.message += "\nPlease report this to https://github.com/markedjs/marked.";
70286      if (silent) {
70287        const msg = "<p>An error occurred:</p><pre>" + escape22(e.message + "", true) + "</pre>";
70288        if (async) {
70289          return Promise.resolve(msg);
70290        }
70291        return msg;
70292      }
70293      if (async) {
70294        return Promise.reject(e);
70295      }
70296      throw e;
70297    };
70298  }
70299};
70300var markedInstance = new Marked();
70301function marked(src, opt) {
70302  return markedInstance.parse(src, opt);
70303}
70304marked.options = marked.setOptions = function(options2) {
70305  markedInstance.setOptions(options2);
70306  marked.defaults = markedInstance.defaults;
70307  changeDefaults(marked.defaults);
70308  return marked;
70309};
70310marked.getDefaults = _getDefaults;
70311marked.defaults = _defaults;
70312marked.use = function(...args) {
70313  markedInstance.use(...args);
70314  marked.defaults = markedInstance.defaults;
70315  changeDefaults(marked.defaults);
70316  return marked;
70317};
70318marked.walkTokens = function(tokens, callback) {
70319  return markedInstance.walkTokens(tokens, callback);
70320};
70321marked.parseInline = markedInstance.parseInline;
70322marked.Parser = _Parser;
70323marked.parser = _Parser.parse;
70324marked.Renderer = _Renderer;
70325marked.TextRenderer = _TextRenderer;
70326marked.Lexer = _Lexer;
70327marked.lexer = _Lexer.lex;
70328marked.Tokenizer = _Tokenizer;
70329marked.Hooks = _Hooks;
70330marked.parse = marked;
70331var options = marked.options;
70332var setOptions = marked.setOptions;
70333var use = marked.use;
70334var walkTokens = marked.walkTokens;
70335var parseInline = marked.parseInline;
70336var parser = _Parser.parse;
70337var lexer = _Lexer.lex;
70338
70339// src/app/pipes/latex.pipe.ts
70340var LatexPipe = class _LatexPipe {
70341  constructor(sanitizer) {
70342    this.sanitizer = sanitizer;
70343  }
70344  transform(content) {
70345    if (!content) {
70346      return this.sanitizer.bypassSecurityTrustHtml("");
70347    }
70348    let htmlContent = marked.parse(content, { async: false, breaks: true });
70349    htmlContent = this.renderLatexInHtml(htmlContent);
70350    return this.sanitizer.bypassSecurityTrustHtml(htmlContent);
70351  }
70352  renderLatexInHtml(html2) {
70353    html2 = html2.replace(/\(\(([\s\S]*?)\)\)/g, (match, formula) => {
70354      try {
70355        return renderToString(formula.trim(), {
70356          displayMode: true,
70357          throwOnError: false
70358        });
70359      } catch (error) {
70360        console.error("KaTeX rendering error (display):", error);
70361        return `<span class="katex-error-custom">${match}</span>`;
70362      }
70363    });
70364    html2 = html2.replace(/\[([\s\S]*?)\]/g, (match, formula) => {
70365      try {
70366        if (!/\\[a-zA-Z{}\^_]/.test(formula)) {
70367          return match;
70368        }
70369        return renderToString(formula.trim(), {
70370          displayMode: true,
70371          throwOnError: false
70372        });
70373      } catch (error) {
70374        console.error("KaTeX rendering error (brackets):", error);
70375        return `<span class="katex-error-custom">${match}</span>`;
70376      }
70377    });
70378    html2 = html2.replace(/\(\\([a-zA-Z]+)([\s\S]*?)\)/g, (match, command, rest) => {
70379      try {
70380        const formula = "\\" + command + rest;
70381        return renderToString(formula.trim(), {
70382          displayMode: false,
70383          throwOnError: false
70384        });
70385      } catch (error) {
70386        console.error("KaTeX rendering error (inline):", error);
70387        return `<span class="katex-error-custom">${match}</span>`;
70388      }
70389    });
70390    return html2;
70391  }
70392  static {
70393    this.\u0275fac = function LatexPipe_Factory(__ngFactoryType__) {
70394      return new (__ngFactoryType__ || _LatexPipe)(\u0275\u0275directiveInject(DomSanitizer, 16));
70395    };
70396  }
70397  static {
70398    this.\u0275pipe = /* @__PURE__ */ \u0275\u0275definePipe({ name: "latex", type: _LatexPipe, pure: true, standalone: false });
70399  }
70400};
70401
70402// src/app/DoraWidget/dora-corp-agent-user-history/dora-corp-agent-user-history.component.ts
70403var _c04 = ["scrollContainer"];
70404var _c13 = (a0) => ({ groups: a0 });
70405function DoraCorpAgentUserHistoryComponent_div_0_div_1_Template(rf, ctx) {
70406  if (rf & 1) {
70407    \u0275\u0275elementStart(0, "div", 8);
70408    \u0275\u0275text(1);
70409    \u0275\u0275elementEnd();
70410  }
70411  if (rf & 2) {
70412    const ctx_r0 = \u0275\u0275nextContext(2);
70413    \u0275\u0275advance();
70414    \u0275\u0275textInterpolate(ctx_r0.widgetTitle);
70415  }
70416}
70417function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_1_div_4_Template(rf, ctx) {
70418  if (rf & 1) {
70419    \u0275\u0275elementStart(0, "div", 17)(1, "span", 18);
70420    \u0275\u0275text(2);
70421    \u0275\u0275pipe(3, "translate");
70422    \u0275\u0275elementEnd()();
70423  }
70424  if (rf & 2) {
70425    \u0275\u0275advance(2);
70426    \u0275\u0275textInterpolate(\u0275\u0275pipeBind1(3, 1, "waiting_for_response"));
70427  }
70428}
70429function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_1_div_5_Template(rf, ctx) {
70430  if (rf & 1) {
70431    \u0275\u0275elementStart(0, "div", 19);
70432    \u0275\u0275text(1);
70433    \u0275\u0275pipe(2, "date");
70434    \u0275\u0275elementEnd();
70435  }
70436  if (rf & 2) {
70437    const entry_r2 = \u0275\u0275nextContext(2).$implicit;
70438    \u0275\u0275advance();
70439    \u0275\u0275textInterpolate1(" ", \u0275\u0275pipeBind2(2, 1, entry_r2.corporateAgentData.QuestionTimestamp, "HH:mm:ss"), " ");
70440  }
70441}
70442function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_1_Template(rf, ctx) {
70443  if (rf & 1) {
70444    \u0275\u0275elementStart(0, "div", 12)(1, "div", 13);
70445    \u0275\u0275element(2, "div", 14);
70446    \u0275\u0275pipe(3, "latex");
70447    \u0275\u0275template(4, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_1_div_4_Template, 4, 3, "div", 15);
70448    \u0275\u0275elementEnd();
70449    \u0275\u0275template(5, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_1_div_5_Template, 3, 4, "div", 16);
70450    \u0275\u0275elementEnd();
70451  }
70452  if (rf & 2) {
70453    const entry_r2 = \u0275\u0275nextContext().$implicit;
70454    \u0275\u0275advance();
70455    \u0275\u0275classProp("pending", entry_r2.isPending);
70456    \u0275\u0275advance();
70457    \u0275\u0275property("innerHTML", \u0275\u0275pipeBind1(3, 5, entry_r2.corporateAgentData.Question), \u0275\u0275sanitizeHtml);
70458    \u0275\u0275advance(2);
70459    \u0275\u0275property("ngIf", entry_r2.isPending);
70460    \u0275\u0275advance();
70461    \u0275\u0275property("ngIf", entry_r2.corporateAgentData.QuestionTimestamp);
70462  }
70463}
70464function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_3_Template(rf, ctx) {
70465  if (rf & 1) {
70466    \u0275\u0275element(0, "div", 30);
70467    \u0275\u0275pipe(1, "latex");
70468  }
70469  if (rf & 2) {
70470    const entry_r2 = \u0275\u0275nextContext(2).$implicit;
70471    \u0275\u0275property("innerHTML", \u0275\u0275pipeBind1(1, 1, entry_r2.corporateAgentData.Answer), \u0275\u0275sanitizeHtml);
70472  }
70473}
70474function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_p_4_Template(rf, ctx) {
70475  if (rf & 1) {
70476    \u0275\u0275element(0, "p");
70477  }
70478}
70479function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_5_Template(rf, ctx) {
70480  if (rf & 1) {
70481    \u0275\u0275elementStart(0, "div", 31);
70482    \u0275\u0275element(1, "div", 30);
70483    \u0275\u0275elementEnd();
70484  }
70485  if (rf & 2) {
70486    const entry_r2 = \u0275\u0275nextContext(2).$implicit;
70487    \u0275\u0275advance();
70488    \u0275\u0275property("innerHTML", entry_r2.chartTagsHtml, \u0275\u0275sanitizeHtml);
70489  }
70490}
70491function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_6_Template(rf, ctx) {
70492  if (rf & 1) {
70493    \u0275\u0275elementStart(0, "div", 32);
70494    \u0275\u0275element(1, "div", 30);
70495    \u0275\u0275elementEnd();
70496  }
70497  if (rf & 2) {
70498    const entry_r2 = \u0275\u0275nextContext(2).$implicit;
70499    \u0275\u0275advance();
70500    \u0275\u0275property("innerHTML", entry_r2.carouselTagsHtml, \u0275\u0275sanitizeHtml);
70501  }
70502}
70503function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_7_div_6_Template(rf, ctx) {
70504  if (rf & 1) {
70505    \u0275\u0275elementStart(0, "div", 38);
70506    \u0275\u0275element(1, "div", 30);
70507    \u0275\u0275pipe(2, "latex");
70508    \u0275\u0275elementEnd();
70509  }
70510  if (rf & 2) {
70511    const entry_r2 = \u0275\u0275nextContext(3).$implicit;
70512    const ctx_r0 = \u0275\u0275nextContext(2);
70513    \u0275\u0275property("id", ctx_r0.createHtmlTagId("technical-answer-content", entry_r2));
70514    \u0275\u0275attribute("aria-labelledby", ctx_r0.createHtmlTagId("technical-answer-button", entry_r2))("aria-expanded", entry_r2.isTechnicalAnswerAccordionOpen);
70515    \u0275\u0275advance();
70516    \u0275\u0275property("innerHTML", \u0275\u0275pipeBind1(2, 4, entry_r2.corporateAgentData.TechnicalAnswer), \u0275\u0275sanitizeHtml);
70517  }
70518}
70519function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_7_Template(rf, ctx) {
70520  if (rf & 1) {
70521    const _r3 = \u0275\u0275getCurrentView();
70522    \u0275\u0275elementStart(0, "div", 33)(1, "div", 34)(2, "button", 35);
70523    \u0275\u0275listener("click", function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_7_Template_button_click_2_listener() {
70524      \u0275\u0275restoreView(_r3);
70525      const entry_r2 = \u0275\u0275nextContext(2).$implicit;
70526      const ctx_r0 = \u0275\u0275nextContext(2);
70527      return \u0275\u0275resetView(ctx_r0.toggleTechnicalAnswerAccordion(entry_r2));
70528    });
70529    \u0275\u0275text(3);
70530    \u0275\u0275pipe(4, "translate");
70531    \u0275\u0275element(5, "span", 36);
70532    \u0275\u0275elementEnd()();
70533    \u0275\u0275template(6, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_7_div_6_Template, 3, 6, "div", 37);
70534    \u0275\u0275elementEnd();
70535  }
70536  if (rf & 2) {
70537    const entry_r2 = \u0275\u0275nextContext(2).$implicit;
70538    const ctx_r0 = \u0275\u0275nextContext(2);
70539    \u0275\u0275advance(2);
70540    \u0275\u0275property("id", ctx_r0.createHtmlTagId("technical-answer-button", entry_r2));
70541    \u0275\u0275attribute("aria-expanded", entry_r2.isTechnicalAnswerAccordionOpen)("aria-controls", ctx_r0.createHtmlTagId("technical-answer-content", entry_r2));
70542    \u0275\u0275advance();
70543    \u0275\u0275textInterpolate1(" ", \u0275\u0275pipeBind1(4, 6, "technical_answer"), " ");
70544    \u0275\u0275advance(2);
70545    \u0275\u0275property("ngClass", entry_r2.isTechnicalAnswerAccordionOpen ? "accordion-open" : "accordion-closed");
70546    \u0275\u0275advance();
70547    \u0275\u0275property("ngIf", entry_r2.isTechnicalAnswerAccordionOpen);
70548  }
70549}
70550function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_1_Template(rf, ctx) {
70551  if (rf & 1) {
70552    const _r4 = \u0275\u0275getCurrentView();
70553    \u0275\u0275elementStart(0, "div")(1, "div", 34)(2, "button", 41);
70554    \u0275\u0275listener("click", function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_1_Template_button_click_2_listener() {
70555      \u0275\u0275restoreView(_r4);
70556      const entry_r2 = \u0275\u0275nextContext(3).$implicit;
70557      const ctx_r0 = \u0275\u0275nextContext(2);
70558      return \u0275\u0275resetView(ctx_r0.toggleDocumentsAccordion(entry_r2));
70559    });
70560    \u0275\u0275text(3);
70561    \u0275\u0275pipe(4, "translate");
70562    \u0275\u0275elementStart(5, "span", 42);
70563    \u0275\u0275text(6);
70564    \u0275\u0275elementEnd();
70565    \u0275\u0275element(7, "span", 36);
70566    \u0275\u0275elementEnd()()();
70567  }
70568  if (rf & 2) {
70569    const entry_r2 = \u0275\u0275nextContext(3).$implicit;
70570    const ctx_r0 = \u0275\u0275nextContext(2);
70571    \u0275\u0275advance(2);
70572    \u0275\u0275property("id", ctx_r0.createHtmlTagId("attached-documents-button", entry_r2));
70573    \u0275\u0275attribute("aria-expanded", entry_r2.isDocumentsAccordionOpen)("aria-controls", ctx_r0.createHtmlTagId("attached-documents-list", entry_r2));
70574    \u0275\u0275advance();
70575    \u0275\u0275textInterpolate1(" ", \u0275\u0275pipeBind1(4, 6, "attached_documents"), " ");
70576    \u0275\u0275advance(3);
70577    \u0275\u0275textInterpolate(ctx_r0.aggregateDocuments ? (entry_r2.aggregatedDocuments == null ? null : entry_r2.aggregatedDocuments.length) || 0 : entry_r2.corporateAgentData.Documents.length);
70578    \u0275\u0275advance();
70579    \u0275\u0275property("ngClass", entry_r2.isDocumentsAccordionOpen ? "accordion-open" : "accordion-closed");
70580  }
70581}
70582function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_2_Template(rf, ctx) {
70583  if (rf & 1) {
70584    \u0275\u0275elementStart(0, "div")(1, "div", 43);
70585    \u0275\u0275text(2);
70586    \u0275\u0275pipe(3, "translate");
70587    \u0275\u0275elementStart(4, "span", 42);
70588    \u0275\u0275text(5);
70589    \u0275\u0275elementEnd()()();
70590  }
70591  if (rf & 2) {
70592    const entry_r2 = \u0275\u0275nextContext(3).$implicit;
70593    const ctx_r0 = \u0275\u0275nextContext(2);
70594    \u0275\u0275advance(2);
70595    \u0275\u0275textInterpolate1("", \u0275\u0275pipeBind1(3, 2, "attached_documents"), " ");
70596    \u0275\u0275advance(3);
70597    \u0275\u0275textInterpolate(ctx_r0.aggregateDocuments ? (entry_r2.aggregatedDocuments == null ? null : entry_r2.aggregatedDocuments.length) || 0 : entry_r2.corporateAgentData.Documents.length);
70598  }
70599}
70600function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ng_container_1_Template(rf, ctx) {
70601  if (rf & 1) {
70602    \u0275\u0275elementContainer(0, 46);
70603  }
70604  if (rf & 2) {
70605    const entry_r2 = \u0275\u0275nextContext(4).$implicit;
70606    \u0275\u0275nextContext(2);
70607    const aggregatedDocumentsList_r5 = \u0275\u0275reference(2);
70608    \u0275\u0275property("ngTemplateOutlet", aggregatedDocumentsList_r5)("ngTemplateOutletContext", \u0275\u0275pureFunction1(2, _c13, entry_r2.aggregatedDocuments));
70609  }
70610}
70611function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_li_1_button_1_span_4_Template(rf, ctx) {
70612  if (rf & 1) {
70613    \u0275\u0275elementStart(0, "span", 57);
70614    \u0275\u0275text(1);
70615    \u0275\u0275elementEnd();
70616  }
70617  if (rf & 2) {
70618    const doc_r7 = \u0275\u0275nextContext(2).$implicit;
70619    const ctx_r0 = \u0275\u0275nextContext(7);
70620    \u0275\u0275advance();
70621    \u0275\u0275textInterpolate1(" ", ctx_r0.translationService.translateWithPlaceHolder("document_type_" + doc_r7.Metadata.DocumentType, doc_r7.Metadata.Filename), " ");
70622  }
70623}
70624function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_li_1_button_1_span_5_Template(rf, ctx) {
70625  if (rf & 1) {
70626    \u0275\u0275elementStart(0, "span", 58);
70627    \u0275\u0275text(1);
70628    \u0275\u0275elementEnd();
70629  }
70630  if (rf & 2) {
70631    const doc_r7 = \u0275\u0275nextContext(2).$implicit;
70632    const ctx_r0 = \u0275\u0275nextContext(7);
70633    \u0275\u0275advance();
70634    \u0275\u0275textInterpolate2(" (", ctx_r0.translationService.get("Pagina"), ": ", doc_r7.Metadata.Page, ") ");
70635  }
70636}
70637function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_li_1_button_1_span_6_Template(rf, ctx) {
70638  if (rf & 1) {
70639    \u0275\u0275elementStart(0, "span", 59);
70640    \u0275\u0275text(1);
70641    \u0275\u0275pipe(2, "number");
70642    \u0275\u0275elementEnd();
70643  }
70644  if (rf & 2) {
70645    const doc_r7 = \u0275\u0275nextContext(2).$implicit;
70646    const ctx_r0 = \u0275\u0275nextContext(7);
70647    \u0275\u0275advance();
70648    \u0275\u0275textInterpolate1(" ", ctx_r0.translationService.translateWithPlaceHolder("document_score_" + doc_r7.Metadata.DocumentType, \u0275\u0275pipeBind2(2, 1, doc_r7.Metadata.Score, "1.2-2")), " ");
70649  }
70650}
70651function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_li_1_button_1_span_7_Template(rf, ctx) {
70652  if (rf & 1) {
70653    \u0275\u0275elementStart(0, "span", 60);
70654    \u0275\u0275text(1);
70655    \u0275\u0275elementEnd();
70656  }
70657  if (rf & 2) {
70658    const doc_r7 = \u0275\u0275nextContext(2).$implicit;
70659    const ctx_r0 = \u0275\u0275nextContext(7);
70660    \u0275\u0275advance();
70661    \u0275\u0275textInterpolate1(" ", ctx_r0.translationService.translateWithPlaceHolder("document_action_" + doc_r7.Metadata.DocumentType, doc_r7.Metadata.Filename), " ");
70662  }
70663}
70664function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_li_1_button_1_Template(rf, ctx) {
70665  if (rf & 1) {
70666    const _r6 = \u0275\u0275getCurrentView();
70667    \u0275\u0275elementStart(0, "button", 50);
70668    \u0275\u0275listener("click", function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_li_1_button_1_Template_button_click_0_listener() {
70669      \u0275\u0275restoreView(_r6);
70670      const doc_r7 = \u0275\u0275nextContext().$implicit;
70671      const ctx_r0 = \u0275\u0275nextContext(7);
70672      return \u0275\u0275resetView(doc_r7 ? ctx_r0.onDocumentClick(doc_r7) : null);
70673    });
70674    \u0275\u0275element(1, "span", 51);
70675    \u0275\u0275elementStart(2, "span", 52);
70676    \u0275\u0275text(3);
70677    \u0275\u0275elementEnd();
70678    \u0275\u0275template(4, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_li_1_button_1_span_4_Template, 2, 1, "span", 53)(5, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_li_1_button_1_span_5_Template, 2, 2, "span", 54)(6, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_li_1_button_1_span_6_Template, 3, 4, "span", 55)(7, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_li_1_button_1_span_7_Template, 2, 1, "span", 56);
70679    \u0275\u0275elementEnd();
70680  }
70681  if (rf & 2) {
70682    const ctx_r7 = \u0275\u0275nextContext();
70683    const doc_r7 = ctx_r7.$implicit;
70684    const i_r9 = ctx_r7.index;
70685    const ctx_r0 = \u0275\u0275nextContext(7);
70686    \u0275\u0275property("ngClass", "document-link document-link-" + doc_r7.Metadata.DocumentType)("title", ctx_r0.translationService.translateWithPlaceHolder("button_title_" + doc_r7.Metadata.DocumentType, doc_r7.Metadata.Filename));
70687    \u0275\u0275advance(3);
70688    \u0275\u0275textInterpolate(doc_r7.Metadata.Filename || doc_r7.Metadata.Title || "Documento " + (i_r9 + 1));
70689    \u0275\u0275advance();
70690    \u0275\u0275property("ngIf", doc_r7.Metadata && doc_r7.Metadata.DocumentType !== void 0);
70691    \u0275\u0275advance();
70692    \u0275\u0275property("ngIf", doc_r7.Metadata && doc_r7.Metadata.Page !== void 0);
70693    \u0275\u0275advance();
70694    \u0275\u0275property("ngIf", doc_r7.Metadata && doc_r7.Metadata.Score !== void 0);
70695    \u0275\u0275advance();
70696    \u0275\u0275property("ngIf", doc_r7.Metadata && doc_r7.Metadata.DocumentType !== void 0);
70697  }
70698}
70699function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_li_1_Template(rf, ctx) {
70700  if (rf & 1) {
70701    \u0275\u0275elementStart(0, "li", 48);
70702    \u0275\u0275template(1, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_li_1_button_1_Template, 8, 7, "button", 49);
70703    \u0275\u0275elementEnd();
70704  }
70705  if (rf & 2) {
70706    const doc_r7 = ctx.$implicit;
70707    \u0275\u0275advance();
70708    \u0275\u0275property("ngIf", doc_r7.Metadata != void 0 && doc_r7.Metadata.DocumentType != void 0);
70709  }
70710}
70711function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_Template(rf, ctx) {
70712  if (rf & 1) {
70713    \u0275\u0275elementStart(0, "ul");
70714    \u0275\u0275template(1, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_li_1_Template, 2, 1, "li", 47);
70715    \u0275\u0275elementEnd();
70716  }
70717  if (rf & 2) {
70718    const entry_r2 = \u0275\u0275nextContext(4).$implicit;
70719    \u0275\u0275advance();
70720    \u0275\u0275property("ngForOf", entry_r2.corporateAgentData.Documents);
70721  }
70722}
70723function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_Template(rf, ctx) {
70724  if (rf & 1) {
70725    \u0275\u0275elementStart(0, "div", 44);
70726    \u0275\u0275template(1, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ng_container_1_Template, 1, 4, "ng-container", 45)(2, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_ul_2_Template, 2, 1, "ul", 24);
70727    \u0275\u0275elementEnd();
70728  }
70729  if (rf & 2) {
70730    const entry_r2 = \u0275\u0275nextContext(3).$implicit;
70731    const ctx_r0 = \u0275\u0275nextContext(2);
70732    \u0275\u0275property("id", ctx_r0.createHtmlTagId("attached-documents-list", entry_r2));
70733    \u0275\u0275attribute("aria-labelledby", ctx_r0.createHtmlTagId("attached-documents-button", entry_r2))("aria-expanded", entry_r2.isDocumentsAccordionOpen);
70734    \u0275\u0275advance();
70735    \u0275\u0275property("ngIf", ctx_r0.aggregateDocuments);
70736    \u0275\u0275advance();
70737    \u0275\u0275property("ngIf", !ctx_r0.aggregateDocuments);
70738  }
70739}
70740function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_Template(rf, ctx) {
70741  if (rf & 1) {
70742    \u0275\u0275elementStart(0, "div", 39);
70743    \u0275\u0275template(1, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_1_Template, 8, 8, "div", 24)(2, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_2_Template, 6, 4, "div", 24)(3, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_div_3_Template, 3, 5, "div", 40);
70744    \u0275\u0275elementEnd();
70745  }
70746  if (rf & 2) {
70747    const entry_r2 = \u0275\u0275nextContext(2).$implicit;
70748    const ctx_r0 = \u0275\u0275nextContext(2);
70749    \u0275\u0275advance();
70750    \u0275\u0275property("ngIf", ctx_r0.linkedDocumentsAsAccordion);
70751    \u0275\u0275advance();
70752    \u0275\u0275property("ngIf", !ctx_r0.linkedDocumentsAsAccordion);
70753    \u0275\u0275advance();
70754    \u0275\u0275property("ngIf", entry_r2.isDocumentsAccordionOpen || !ctx_r0.linkedDocumentsAsAccordion);
70755  }
70756}
70757function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_1_Template(rf, ctx) {
70758  if (rf & 1) {
70759    const _r10 = \u0275\u0275getCurrentView();
70760    \u0275\u0275elementStart(0, "div")(1, "div", 34)(2, "button", 41);
70761    \u0275\u0275listener("click", function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_1_Template_button_click_2_listener() {
70762      \u0275\u0275restoreView(_r10);
70763      const entry_r2 = \u0275\u0275nextContext(3).$implicit;
70764      const ctx_r0 = \u0275\u0275nextContext(2);
70765      return \u0275\u0275resetView(ctx_r0.toggleRelatedDocumentsAccordion(entry_r2));
70766    });
70767    \u0275\u0275text(3);
70768    \u0275\u0275pipe(4, "translate");
70769    \u0275\u0275elementStart(5, "span", 42);
70770    \u0275\u0275text(6);
70771    \u0275\u0275elementEnd();
70772    \u0275\u0275element(7, "span", 36);
70773    \u0275\u0275elementEnd()()();
70774  }
70775  if (rf & 2) {
70776    const entry_r2 = \u0275\u0275nextContext(3).$implicit;
70777    const ctx_r0 = \u0275\u0275nextContext(2);
70778    \u0275\u0275advance(2);
70779    \u0275\u0275property("id", ctx_r0.createHtmlTagId("related-documents-button", entry_r2));
70780    \u0275\u0275attribute("aria-expanded", entry_r2.isRelatedDocumentsAccordionOpen)("aria-controls", ctx_r0.createHtmlTagId("related-documents-list", entry_r2));
70781    \u0275\u0275advance();
70782    \u0275\u0275textInterpolate1(" ", \u0275\u0275pipeBind1(4, 6, "related_documents"), " ");
70783    \u0275\u0275advance(3);
70784    \u0275\u0275textInterpolate(ctx_r0.aggregateRelatedDocuments ? (entry_r2.aggregatedRelatedDocuments == null ? null : entry_r2.aggregatedRelatedDocuments.length) || 0 : entry_r2.corporateAgentData.Related_documents.length);
70785    \u0275\u0275advance();
70786    \u0275\u0275property("ngClass", entry_r2.isRelatedDocumentsAccordionOpen ? "accordion-open" : "accordion-closed");
70787  }
70788}
70789function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_2_Template(rf, ctx) {
70790  if (rf & 1) {
70791    \u0275\u0275elementStart(0, "div")(1, "div", 43);
70792    \u0275\u0275text(2);
70793    \u0275\u0275pipe(3, "translate");
70794    \u0275\u0275elementStart(4, "span", 42);
70795    \u0275\u0275text(5);
70796    \u0275\u0275elementEnd()()();
70797  }
70798  if (rf & 2) {
70799    const entry_r2 = \u0275\u0275nextContext(3).$implicit;
70800    const ctx_r0 = \u0275\u0275nextContext(2);
70801    \u0275\u0275advance(2);
70802    \u0275\u0275textInterpolate1("", \u0275\u0275pipeBind1(3, 2, "related_documents"), " ");
70803    \u0275\u0275advance(3);
70804    \u0275\u0275textInterpolate(ctx_r0.aggregateRelatedDocuments ? (entry_r2.aggregatedRelatedDocuments == null ? null : entry_r2.aggregatedRelatedDocuments.length) || 0 : entry_r2.corporateAgentData.Related_documents.length);
70805  }
70806}
70807function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ng_container_1_Template(rf, ctx) {
70808  if (rf & 1) {
70809    \u0275\u0275elementContainer(0, 46);
70810  }
70811  if (rf & 2) {
70812    const entry_r2 = \u0275\u0275nextContext(4).$implicit;
70813    \u0275\u0275nextContext(2);
70814    const aggregatedDocumentsList_r5 = \u0275\u0275reference(2);
70815    \u0275\u0275property("ngTemplateOutlet", aggregatedDocumentsList_r5)("ngTemplateOutletContext", \u0275\u0275pureFunction1(2, _c13, entry_r2.aggregatedRelatedDocuments));
70816  }
70817}
70818function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_li_1_button_1_span_4_Template(rf, ctx) {
70819  if (rf & 1) {
70820    \u0275\u0275elementStart(0, "span", 57);
70821    \u0275\u0275text(1);
70822    \u0275\u0275elementEnd();
70823  }
70824  if (rf & 2) {
70825    const doc_r12 = \u0275\u0275nextContext(2).$implicit;
70826    const ctx_r0 = \u0275\u0275nextContext(7);
70827    \u0275\u0275advance();
70828    \u0275\u0275textInterpolate1(" ", ctx_r0.translationService.translateWithPlaceHolder("document_type_" + doc_r12.Metadata.DocumentType, doc_r12.Metadata.Filename), " ");
70829  }
70830}
70831function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_li_1_button_1_span_5_Template(rf, ctx) {
70832  if (rf & 1) {
70833    \u0275\u0275elementStart(0, "span", 58);
70834    \u0275\u0275text(1);
70835    \u0275\u0275elementEnd();
70836  }
70837  if (rf & 2) {
70838    const doc_r12 = \u0275\u0275nextContext(2).$implicit;
70839    const ctx_r0 = \u0275\u0275nextContext(7);
70840    \u0275\u0275advance();
70841    \u0275\u0275textInterpolate2(" (", ctx_r0.translationService.get("Pagina"), ": ", doc_r12.Metadata.Page, ") ");
70842  }
70843}
70844function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_li_1_button_1_span_6_Template(rf, ctx) {
70845  if (rf & 1) {
70846    \u0275\u0275elementStart(0, "span", 59);
70847    \u0275\u0275text(1);
70848    \u0275\u0275pipe(2, "number");
70849    \u0275\u0275elementEnd();
70850  }
70851  if (rf & 2) {
70852    const doc_r12 = \u0275\u0275nextContext(2).$implicit;
70853    const ctx_r0 = \u0275\u0275nextContext(7);
70854    \u0275\u0275advance();
70855    \u0275\u0275textInterpolate1(" ", ctx_r0.translationService.translateWithPlaceHolder("document_score_" + doc_r12.Metadata.DocumentType, \u0275\u0275pipeBind2(2, 1, doc_r12.Metadata.Score, "1.2-2")), " ");
70856  }
70857}
70858function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_li_1_button_1_span_7_Template(rf, ctx) {
70859  if (rf & 1) {
70860    \u0275\u0275elementStart(0, "span", 60);
70861    \u0275\u0275text(1);
70862    \u0275\u0275elementEnd();
70863  }
70864  if (rf & 2) {
70865    const doc_r12 = \u0275\u0275nextContext(2).$implicit;
70866    const ctx_r0 = \u0275\u0275nextContext(7);
70867    \u0275\u0275advance();
70868    \u0275\u0275textInterpolate1(" ", ctx_r0.translationService.translateWithPlaceHolder("document_action_" + doc_r12.Metadata.DocumentType, doc_r12.Metadata.Filename), " ");
70869  }
70870}
70871function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_li_1_button_1_Template(rf, ctx) {
70872  if (rf & 1) {
70873    const _r11 = \u0275\u0275getCurrentView();
70874    \u0275\u0275elementStart(0, "button", 50);
70875    \u0275\u0275listener("click", function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_li_1_button_1_Template_button_click_0_listener() {
70876      \u0275\u0275restoreView(_r11);
70877      const doc_r12 = \u0275\u0275nextContext().$implicit;
70878      const ctx_r0 = \u0275\u0275nextContext(7);
70879      return \u0275\u0275resetView(doc_r12 ? ctx_r0.onDocumentClick(doc_r12) : null);
70880    });
70881    \u0275\u0275element(1, "span", 51);
70882    \u0275\u0275elementStart(2, "span", 52);
70883    \u0275\u0275text(3);
70884    \u0275\u0275elementEnd();
70885    \u0275\u0275template(4, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_li_1_button_1_span_4_Template, 2, 1, "span", 53)(5, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_li_1_button_1_span_5_Template, 2, 2, "span", 54)(6, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_li_1_button_1_span_6_Template, 3, 4, "span", 55)(7, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_li_1_button_1_span_7_Template, 2, 1, "span", 56);
70886    \u0275\u0275elementEnd();
70887  }
70888  if (rf & 2) {
70889    const ctx_r12 = \u0275\u0275nextContext();
70890    const doc_r12 = ctx_r12.$implicit;
70891    const i_r14 = ctx_r12.index;
70892    const ctx_r0 = \u0275\u0275nextContext(7);
70893    \u0275\u0275property("ngClass", "document-link document-link-" + doc_r12.Metadata.DocumentType)("title", ctx_r0.translationService.translateWithPlaceHolder("button_title_" + doc_r12.Metadata.DocumentType, doc_r12.Metadata.Filename));
70894    \u0275\u0275advance(3);
70895    \u0275\u0275textInterpolate(doc_r12.Metadata.Filename || doc_r12.Metadata.Title || "Documento " + (i_r14 + 1));
70896    \u0275\u0275advance();
70897    \u0275\u0275property("ngIf", doc_r12.Metadata && doc_r12.Metadata.DocumentType !== void 0);
70898    \u0275\u0275advance();
70899    \u0275\u0275property("ngIf", doc_r12.Metadata && doc_r12.Metadata.Page !== void 0);
70900    \u0275\u0275advance();
70901    \u0275\u0275property("ngIf", doc_r12.Metadata && doc_r12.Metadata.Score !== void 0);
70902    \u0275\u0275advance();
70903    \u0275\u0275property("ngIf", doc_r12.Metadata && doc_r12.Metadata.DocumentType !== void 0);
70904  }
70905}
70906function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_li_1_Template(rf, ctx) {
70907  if (rf & 1) {
70908    \u0275\u0275elementStart(0, "li", 48);
70909    \u0275\u0275template(1, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_li_1_button_1_Template, 8, 7, "button", 49);
70910    \u0275\u0275elementEnd();
70911  }
70912  if (rf & 2) {
70913    const doc_r12 = ctx.$implicit;
70914    \u0275\u0275advance();
70915    \u0275\u0275property("ngIf", doc_r12.Metadata != void 0 && doc_r12.Metadata.DocumentType != void 0);
70916  }
70917}
70918function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_Template(rf, ctx) {
70919  if (rf & 1) {
70920    \u0275\u0275elementStart(0, "ul");
70921    \u0275\u0275template(1, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_li_1_Template, 2, 1, "li", 47);
70922    \u0275\u0275elementEnd();
70923  }
70924  if (rf & 2) {
70925    const entry_r2 = \u0275\u0275nextContext(4).$implicit;
70926    \u0275\u0275advance();
70927    \u0275\u0275property("ngForOf", entry_r2.corporateAgentData.Related_documents);
70928  }
70929}
70930function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_Template(rf, ctx) {
70931  if (rf & 1) {
70932    \u0275\u0275elementStart(0, "div", 44);
70933    \u0275\u0275template(1, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ng_container_1_Template, 1, 4, "ng-container", 45)(2, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_ul_2_Template, 2, 1, "ul", 24);
70934    \u0275\u0275elementEnd();
70935  }
70936  if (rf & 2) {
70937    const entry_r2 = \u0275\u0275nextContext(3).$implicit;
70938    const ctx_r0 = \u0275\u0275nextContext(2);
70939    \u0275\u0275property("id", ctx_r0.createHtmlTagId("related-documents-list", entry_r2));
70940    \u0275\u0275attribute("aria-labelledby", ctx_r0.createHtmlTagId("related-documents-button", entry_r2))("aria-expanded", entry_r2.isRelatedDocumentsAccordionOpen);
70941    \u0275\u0275advance();
70942    \u0275\u0275property("ngIf", ctx_r0.aggregateRelatedDocuments);
70943    \u0275\u0275advance();
70944    \u0275\u0275property("ngIf", !ctx_r0.aggregateRelatedDocuments);
70945  }
70946}
70947function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_Template(rf, ctx) {
70948  if (rf & 1) {
70949    \u0275\u0275elementStart(0, "div", 39);
70950    \u0275\u0275template(1, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_1_Template, 8, 8, "div", 24)(2, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_2_Template, 6, 4, "div", 24)(3, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_div_3_Template, 3, 5, "div", 40);
70951    \u0275\u0275elementEnd();
70952  }
70953  if (rf & 2) {
70954    const entry_r2 = \u0275\u0275nextContext(2).$implicit;
70955    const ctx_r0 = \u0275\u0275nextContext(2);
70956    \u0275\u0275advance();
70957    \u0275\u0275property("ngIf", ctx_r0.relatedDocumentsAsAccordion);
70958    \u0275\u0275advance();
70959    \u0275\u0275property("ngIf", !ctx_r0.relatedDocumentsAsAccordion);
70960    \u0275\u0275advance();
70961    \u0275\u0275property("ngIf", entry_r2.isRelatedDocumentsAccordionOpen || !ctx_r0.relatedDocumentsAsAccordion);
70962  }
70963}
70964function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_10_Template(rf, ctx) {
70965  if (rf & 1) {
70966    \u0275\u0275elementStart(0, "div", 61);
70967    \u0275\u0275text(1);
70968    \u0275\u0275pipe(2, "date");
70969    \u0275\u0275elementEnd();
70970  }
70971  if (rf & 2) {
70972    const entry_r2 = \u0275\u0275nextContext(2).$implicit;
70973    \u0275\u0275advance();
70974    \u0275\u0275textInterpolate1(" ", \u0275\u0275pipeBind2(2, 1, entry_r2.corporateAgentData.AnswerTimestamp, "HH:mm:ss"), " ");
70975  }
70976}
70977function DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_Template(rf, ctx) {
70978  if (rf & 1) {
70979    \u0275\u0275elementStart(0, "div", 20)(1, "div", 21)(2, "div", 22);
70980    \u0275\u0275template(3, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_3_Template, 2, 3, "div", 23)(4, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_p_4_Template, 1, 0, "p", 24);
70981    \u0275\u0275elementEnd();
70982    \u0275\u0275template(5, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_5_Template, 2, 1, "div", 25)(6, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_6_Template, 2, 1, "div", 26)(7, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_7_Template, 7, 8, "div", 27)(8, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_8_Template, 4, 3, "div", 28)(9, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_9_Template, 4, 3, "div", 28)(10, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_div_10_Template, 3, 4, "div", 29);
70983    \u0275\u0275elementEnd()();
70984  }
70985  if (rf & 2) {
70986    const entry_r2 = \u0275\u0275nextContext().$implicit;
70987    const ctx_r0 = \u0275\u0275nextContext(2);
70988    \u0275\u0275advance(3);
70989    \u0275\u0275property("ngIf", entry_r2.corporateAgentData && entry_r2.corporateAgentData.Answer);
70990    \u0275\u0275advance();
70991    \u0275\u0275property("ngIf", !entry_r2.corporateAgentData || !entry_r2.corporateAgentData.Answer);
70992    \u0275\u0275advance();
70993    \u0275\u0275property("ngIf", entry_r2.chartTagsHtml);
70994    \u0275\u0275advance();
70995    \u0275\u0275property("ngIf", entry_r2.carouselTagsHtml);
70996    \u0275\u0275advance();
70997    \u0275\u0275property("ngIf", entry_r2.corporateAgentData.TechnicalAnswer);
70998    \u0275\u0275advance();
70999    \u0275\u0275property("ngIf", entry_r2.corporateAgentData.Documents && ctx_r0.arrayUtil.isArray(entry_r2.corporateAgentData.Documents) && entry_r2.corporateAgentData.Documents.length > 0);
71000    \u0275\u0275advance();
71001    \u0275\u0275property("ngIf", entry_r2.corporateAgentData.Related_documents && ctx_r0.arrayUtil.isArray(entry_r2.corporateAgentData.Related_documents) && entry_r2.corporateAgentData.Related_documents.length > 0);
71002    \u0275\u0275advance();
71003    \u0275\u0275property("ngIf", entry_r2.corporateAgentData.AnswerTimestamp);
71004  }
71005}
71006function DoraCorpAgentUserHistoryComponent_div_0_div_4_Template(rf, ctx) {
71007  if (rf & 1) {
71008    \u0275\u0275elementStart(0, "div", 9);
71009    \u0275\u0275template(1, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_1_Template, 6, 7, "div", 10)(2, DoraCorpAgentUserHistoryComponent_div_0_div_4_div_2_Template, 11, 8, "div", 11);
71010    \u0275\u0275elementEnd();
71011  }
71012  if (rf & 2) {
71013    const entry_r2 = ctx.$implicit;
71014    const last_r15 = ctx.last;
71015    const ctx_r0 = \u0275\u0275nextContext(2);
71016    \u0275\u0275attribute("aria-live", last_r15 ? "polite" : null);
71017    \u0275\u0275advance();
71018    \u0275\u0275property("ngIf", entry_r2.type === ctx_r0.ConversationEntryType.Question && entry_r2.corporateAgentData);
71019    \u0275\u0275advance();
71020    \u0275\u0275property("ngIf", entry_r2.type === ctx_r0.ConversationEntryType.Answer && entry_r2.corporateAgentData);
71021  }
71022}
71023function DoraCorpAgentUserHistoryComponent_div_0_div_5_Template(rf, ctx) {
71024  if (rf & 1) {
71025    \u0275\u0275elementStart(0, "div", 62);
71026    \u0275\u0275text(1);
71027    \u0275\u0275pipe(2, "translate");
71028    \u0275\u0275elementEnd();
71029  }
71030  if (rf & 2) {
71031    \u0275\u0275advance();
71032    \u0275\u0275textInterpolate1(" ", \u0275\u0275pipeBind1(2, 1, "no_conversation_history"), " ");
71033  }
71034}
71035function DoraCorpAgentUserHistoryComponent_div_0_Template(rf, ctx) {
71036  if (rf & 1) {
71037    \u0275\u0275elementStart(0, "div", 3);
71038    \u0275\u0275template(1, DoraCorpAgentUserHistoryComponent_div_0_div_1_Template, 2, 1, "div", 4);
71039    \u0275\u0275elementStart(2, "div", 5, 1);
71040    \u0275\u0275template(4, DoraCorpAgentUserHistoryComponent_div_0_div_4_Template, 3, 3, "div", 6)(5, DoraCorpAgentUserHistoryComponent_div_0_div_5_Template, 3, 3, "div", 7);
71041    \u0275\u0275elementEnd()();
71042  }
71043  if (rf & 2) {
71044    const ctx_r0 = \u0275\u0275nextContext();
71045    \u0275\u0275advance();
71046    \u0275\u0275property("ngIf", ctx_r0.widgetTitleEnabled && ctx_r0.widgetTitle);
71047    \u0275\u0275advance(3);
71048    \u0275\u0275property("ngForOf", ctx_r0.conversationHistory);
71049    \u0275\u0275advance();
71050    \u0275\u0275property("ngIf", !ctx_r0.conversationHistory || ctx_r0.conversationHistory.length === 0);
71051  }
71052}
71053function DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_ng_container_1_ng_container_1_span_5_Template(rf, ctx) {
71054  if (rf & 1) {
71055    \u0275\u0275elementStart(0, "span", 57);
71056    \u0275\u0275text(1);
71057    \u0275\u0275elementEnd();
71058  }
71059  if (rf & 2) {
71060    const metadata_r16 = \u0275\u0275nextContext(2).ngIf;
71061    const ctx_r0 = \u0275\u0275nextContext(3);
71062    \u0275\u0275advance();
71063    \u0275\u0275textInterpolate1(" ", ctx_r0.translationService.translateWithPlaceHolder("document_type_" + metadata_r16.DocumentType, metadata_r16.Filename), " ");
71064  }
71065}
71066function DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_ng_container_1_ng_container_1_button_7_Template(rf, ctx) {
71067  if (rf & 1) {
71068    const _r17 = \u0275\u0275getCurrentView();
71069    \u0275\u0275elementStart(0, "button", 69);
71070    \u0275\u0275listener("click", function DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_ng_container_1_ng_container_1_button_7_Template_button_click_0_listener() {
71071      const pageDoc_r18 = \u0275\u0275restoreView(_r17).$implicit;
71072      const ctx_r0 = \u0275\u0275nextContext(5);
71073      return \u0275\u0275resetView(ctx_r0.onDocumentClick(pageDoc_r18));
71074    });
71075    \u0275\u0275elementStart(1, "span", 70);
71076    \u0275\u0275text(2);
71077    \u0275\u0275elementEnd()();
71078  }
71079  if (rf & 2) {
71080    const pageDoc_r18 = ctx.$implicit;
71081    const metadata_r16 = \u0275\u0275nextContext(2).ngIf;
71082    const ctx_r0 = \u0275\u0275nextContext(3);
71083    \u0275\u0275property("ngClass", "document-page-link document-page-link-" + metadata_r16.DocumentType)("title", ctx_r0.documentPageTitle(pageDoc_r18));
71084    \u0275\u0275attribute("aria-label", ctx_r0.documentPageTitle(pageDoc_r18));
71085    \u0275\u0275advance(2);
71086    \u0275\u0275textInterpolate(ctx_r0.documentPageLabel(pageDoc_r18));
71087  }
71088}
71089function DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_ng_container_1_ng_container_1_Template(rf, ctx) {
71090  if (rf & 1) {
71091    \u0275\u0275elementContainerStart(0);
71092    \u0275\u0275elementStart(1, "div", 66);
71093    \u0275\u0275element(2, "span", 51);
71094    \u0275\u0275elementStart(3, "span", 52);
71095    \u0275\u0275text(4);
71096    \u0275\u0275elementEnd();
71097    \u0275\u0275template(5, DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_ng_container_1_ng_container_1_span_5_Template, 2, 1, "span", 53);
71098    \u0275\u0275elementEnd();
71099    \u0275\u0275elementStart(6, "div", 67);
71100    \u0275\u0275template(7, DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_ng_container_1_ng_container_1_button_7_Template, 3, 4, "button", 68);
71101    \u0275\u0275elementEnd();
71102    \u0275\u0275elementContainerEnd();
71103  }
71104  if (rf & 2) {
71105    const metadata_r16 = \u0275\u0275nextContext().ngIf;
71106    const ctx_r18 = \u0275\u0275nextContext();
71107    const group_r20 = ctx_r18.$implicit;
71108    const i_r21 = ctx_r18.index;
71109    const ctx_r0 = \u0275\u0275nextContext(2);
71110    \u0275\u0275advance();
71111    \u0275\u0275property("ngClass", "document-header-" + metadata_r16.DocumentType);
71112    \u0275\u0275advance(3);
71113    \u0275\u0275textInterpolate(ctx_r0.aggregatedDocumentName(group_r20, i_r21));
71114    \u0275\u0275advance();
71115    \u0275\u0275property("ngIf", metadata_r16.DocumentType !== void 0);
71116    \u0275\u0275advance();
71117    \u0275\u0275attribute("aria-label", ctx_r0.aggregatedDocumentName(group_r20, i_r21));
71118    \u0275\u0275advance();
71119    \u0275\u0275property("ngForOf", group_r20.pages);
71120  }
71121}
71122function DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_ng_container_1_button_2_Template(rf, ctx) {
71123  if (rf & 1) {
71124    const _r22 = \u0275\u0275getCurrentView();
71125    \u0275\u0275elementStart(0, "button", 69);
71126    \u0275\u0275listener("click", function DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_ng_container_1_button_2_Template_button_click_0_listener() {
71127      \u0275\u0275restoreView(_r22);
71128      const group_r20 = \u0275\u0275nextContext(2).$implicit;
71129      const ctx_r0 = \u0275\u0275nextContext(2);
71130      return \u0275\u0275resetView(ctx_r0.onDocumentClick(group_r20.document));
71131    });
71132    \u0275\u0275element(1, "span", 51);
71133    \u0275\u0275elementStart(2, "span", 52);
71134    \u0275\u0275text(3);
71135    \u0275\u0275elementEnd();
71136    \u0275\u0275elementStart(4, "span", 57);
71137    \u0275\u0275text(5);
71138    \u0275\u0275elementEnd();
71139    \u0275\u0275elementStart(6, "span", 60);
71140    \u0275\u0275text(7);
71141    \u0275\u0275elementEnd()();
71142  }
71143  if (rf & 2) {
71144    const metadata_r16 = \u0275\u0275nextContext().ngIf;
71145    const ctx_r18 = \u0275\u0275nextContext();
71146    const group_r20 = ctx_r18.$implicit;
71147    const i_r21 = ctx_r18.index;
71148    const ctx_r0 = \u0275\u0275nextContext(2);
71149    \u0275\u0275property("ngClass", "document-link document-link-" + metadata_r16.DocumentType)("title", ctx_r0.translationService.translateWithPlaceHolder("button_title_" + metadata_r16.DocumentType, metadata_r16.Filename));
71150    \u0275\u0275advance(3);
71151    \u0275\u0275textInterpolate(ctx_r0.aggregatedDocumentName(group_r20, i_r21));
71152    \u0275\u0275advance(2);
71153    \u0275\u0275textInterpolate1(" ", ctx_r0.translationService.translateWithPlaceHolder("document_type_" + metadata_r16.DocumentType, metadata_r16.Filename), " ");
71154    \u0275\u0275advance(2);
71155    \u0275\u0275textInterpolate1(" ", ctx_r0.translationService.translateWithPlaceHolder("document_action_" + metadata_r16.DocumentType, metadata_r16.Filename), " ");
71156  }
71157}
71158function DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_ng_container_1_Template(rf, ctx) {
71159  if (rf & 1) {
71160    \u0275\u0275elementContainerStart(0);
71161    \u0275\u0275template(1, DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_ng_container_1_ng_container_1_Template, 8, 5, "ng-container", 24)(2, DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_ng_container_1_button_2_Template, 8, 5, "button", 65);
71162    \u0275\u0275elementContainerEnd();
71163  }
71164  if (rf & 2) {
71165    const metadata_r16 = ctx.ngIf;
71166    const group_r20 = \u0275\u0275nextContext().$implicit;
71167    \u0275\u0275advance();
71168    \u0275\u0275property("ngIf", group_r20.pages.length > 0);
71169    \u0275\u0275advance();
71170    \u0275\u0275property("ngIf", group_r20.pages.length === 0 && metadata_r16.DocumentType != void 0);
71171  }
71172}
71173function DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_Template(rf, ctx) {
71174  if (rf & 1) {
71175    \u0275\u0275elementStart(0, "li", 64);
71176    \u0275\u0275template(1, DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_ng_container_1_Template, 3, 2, "ng-container", 24);
71177    \u0275\u0275elementEnd();
71178  }
71179  if (rf & 2) {
71180    const group_r20 = ctx.$implicit;
71181    \u0275\u0275advance();
71182    \u0275\u0275property("ngIf", group_r20.document.Metadata);
71183  }
71184}
71185function DoraCorpAgentUserHistoryComponent_ng_template_1_Template(rf, ctx) {
71186  if (rf & 1) {
71187    \u0275\u0275elementStart(0, "ul");
71188    \u0275\u0275template(1, DoraCorpAgentUserHistoryComponent_ng_template_1_li_1_Template, 2, 1, "li", 63);
71189    \u0275\u0275elementEnd();
71190  }
71191  if (rf & 2) {
71192    const groups_r23 = ctx.groups;
71193    \u0275\u0275advance();
71194    \u0275\u0275property("ngForOf", groups_r23);
71195  }
71196}
71197var DoraCorpAgentUserHistoryComponent = class _DoraCorpAgentUserHistoryComponent extends WidgetBaseComponent {
71198  constructor(elementRef, messageService, configurationService, publisher, widgetService, http, translationService, sanitizer, cdr) {
71199    super(elementRef, messageService, configurationService, publisher, widgetService, http, translationService);
71200    this.sanitizer = sanitizer;
71201    this.cdr = cdr;
71202    this.widgetTitle = _TRANSLATE("conversation_history");
71203    this.widgetTitleEnabled = false;
71204    this.maxMessages = 10;
71205    this.linkedDocumentsAsAccordion = true;
71206    this.relatedDocumentsAsAccordion = true;
71207    this.hideEmptyChart = false;
71208    this.aggregateDocuments = false;
71209    this.aggregateRelatedDocuments = false;
71210    this.visible = true;
71211    this.conversationHistory = [];
71212    this.pendingWidgetCreation = false;
71213    this.scrollPending = false;
71214    this.arrayUtil = Array;
71215    this.ConversationEntryType = ConversationEntryType;
71216  }
71217  onParameterInjectedFinished() {
71218    super.onParameterInjectedFinished();
71219    this.widgetTitle = this.translationService.get(this.widgetTitle);
71220    this.messageService.getMessage(this.EventChannel, MessageCorporateAgentUserInput, this.CallerName).subscribe((message) => {
71221      if (message && message.data) {
71222        const messageUserInput = message.data;
71223        const questionData = new DataCorporateAgent();
71224        questionData.Question = messageUserInput.question;
71225        questionData.ConversationId = messageUserInput.conversationId;
71226        questionData.QuestionTimestamp = /* @__PURE__ */ new Date();
71227        const questionEntry = {
71228          corporateAgentData: questionData,
71229          type: ConversationEntryType.Question,
71230          isDocumentsAccordionOpen: false,
71231          isRelatedDocumentsAccordionOpen: false,
71232          isTechnicalAnswerAccordionOpen: false,
71233          isPending: true
71234          // Impostato a true mentre attende la risposta
71235        };
71236        this.addConversationHistory(questionEntry);
71237        this.scrollPending = true;
71238        this.read(
71239          [messageUserInput.question],
71240          // SubscribeObjInfo - stringa con il valore di user input
71241          DataType.CORPORATE_AGENT_QUERY
71242        ).subscribe((data) => {
71243          const corporateAgentData = data.data;
71244          if (corporateAgentData) {
71245            const pendingQuestion = this.conversationHistory.find((entry) => entry.type === ConversationEntryType.Question && entry.isPending && entry.corporateAgentData?.ConversationId === messageUserInput.conversationId);
71246            if (pendingQuestion) {
71247              pendingQuestion.isPending = false;
71248            }
71249            const newEntry = {
71250              corporateAgentData,
71251              chartTagsHtml: corporateAgentData && corporateAgentData.Data && corporateAgentData.Data.TableDataContent ? this.buildChartTagsInternal(corporateAgentData) : void 0,
71252              carouselTagsHtml: corporateAgentData && corporateAgentData.Data && corporateAgentData.Data.CarouselDataContent ? this.buildCarouselTagsInternal(corporateAgentData) : void 0,
71253              // I documenti aggregati sono precalcolati qui: valorizzati solo se l'aggregazione è attiva
71254              aggregatedDocuments: this.aggregateDocuments ? this.aggregateDocumentList(corporateAgentData.Documents) : void 0,
71255              aggregatedRelatedDocuments: this.aggregateRelatedDocuments ? this.aggregateDocumentList(corporateAgentData.Related_documents) : void 0,
71256              isDocumentsAccordionOpen: false,
71257              // Imposta l'accordion come chiuso di default
71258              isRelatedDocumentsAccordionOpen: false,
71259              // Imposta l'accordion dei documenti correlati come chiuso di default
71260              isTechnicalAnswerAccordionOpen: false,
71261              // Imposta l'accordion della risposta tecnica come chiuso di default
71262              type: ConversationEntryType.Answer
71263              // Tipo di entry: risposta dell'agente
71264            };
71265            if (this.conversationHistory.length > 0 && this.conversationHistory[this.conversationHistory.length - 1].type === ConversationEntryType.Question) {
71266              this.addConversationHistory(newEntry);
71267            }
71268            this.pendingWidgetCreation = true;
71269            this.scrollPending = true;
71270            if (this.conversationHistory.length > this.maxMessages) {
71271              this.conversationHistory = this.conversationHistory.slice(this.conversationHistory.length - this.maxMessages);
71272            }
71273            this.sendMessageCorporateAgentHistoryLength();
71274          }
71275        });
71276      }
71277    });
71278    this.messageService.getMessage(this.EventChannel, MessageCorporateAgentWizardVisible, this.CallerName).subscribe((message) => {
71279      if (message && message.data) {
71280        const messageCorporateAgentWizardVisible = message.data;
71281        this.setVisible(!messageCorporateAgentWizardVisible.visible);
71282        if (messageCorporateAgentWizardVisible.visible) {
71283          this.conversationHistory = [];
71284          this.sendMessageCorporateAgentHistoryLength();
71285        }
71286      }
71287    });
71288    this.messageService.getMessage(this.EventChannel, MessageCorporateAgentHistoryClear, this.CallerName).subscribe((message) => {
71289      if (message && message.data) {
71290        this.conversationHistory = [];
71291        this.pendingWidgetCreation = false;
71292        this.scrollPending = false;
71293        this.publisherReset();
71294        this.sendMessageCorporateAgentHistoryLength();
71295      }
71296    });
71297  }
71298  /**
71299   * Imposta la visibilità del widget
71300   * @param visible
71301   */
71302  setVisible(visible) {
71303    this.visible = visible;
71304  }
71305  sendMessageCorporateAgentHistoryLength() {
71306    this.messageService.sendMessage(this.EventChannel, new MessageCorporateAgentHistoryLength(this.conversationHistory.length), this.CallerName);
71307  }
71308  /**
71309   * Gestisce il click su un documento allegato
71310   * @param document Il documento selezionato
71311   */
71312  onDocumentClick(doc) {
71313    const metadata = doc.Metadata;
71314    if (!doc || !doc.Metadata || !doc.Metadata.Url) {
71315      console.error("Document or URL is not defined");
71316      return;
71317    }
71318    switch (metadata?.DocumentType) {
71319      case "XLSX":
71320        if (metadata?.Url) {
71321          const link2 = document.createElement("a");
71322          link2.href = metadata.Url;
71323          link2.download = metadata.Filename || "document.xlsx";
71324          document.body.appendChild(link2);
71325          link2.click();
71326          document.body.removeChild(link2);
71327        }
71328        break;
71329      case "PDF":
71330      default:
71331        this.messageService.sendMessage(this.EventChannel, new MessageUrlContent(doc.Metadata?.Url, doc.Metadata?.Title, doc.Metadata?.getMimeType(), doc.Metadata?.Filename, doc.Metadata?.DocumentType), this.CallerName);
71332    }
71333  }
71334  /**
71335   * Aggrega i documenti che puntano allo stesso file: il documento viene esposto una sola volta
71336   * con l'elenco delle occorrenze (una per pagina citata).
71337   * La chiave di raggruppamento è l'URL senza frammento, con fallback su filename/titolo.
71338   * @param docs Elenco dei documenti restituiti dall'agente
71339   * @return Elenco dei documenti distinti, nell'ordine di prima comparsa
71340   */
71341  aggregateDocumentList(docs) {
71342    const aggregated = [];
71343    if (!docs || !Array.isArray(docs)) {
71344      return aggregated;
71345    }
71346    const groupsByKey = /* @__PURE__ */ new Map();
71347    docs.forEach((doc, index) => {
71348      const metadata = doc ? doc.Metadata : void 0;
71349      if (!metadata) {
71350        return;
71351      }
71352      const key = metadata.UrlBase || metadata.Filename || metadata.Title || `document-${index}`;
71353      let group = groupsByKey.get(key);
71354      if (!group) {
71355        group = { document: doc, pages: [] };
71356        groupsByKey.set(key, group);
71357        aggregated.push(group);
71358      }
71359      if (metadata.Page === void 0) {
71360        return;
71361      }
71362      const samePageIndex = group.pages.findIndex((pageDoc) => pageDoc.Metadata?.Page === metadata.Page);
71363      if (samePageIndex < 0) {
71364        group.pages.push(doc);
71365      } else if ((metadata.Score ?? 0) > (group.pages[samePageIndex].Metadata?.Score ?? 0)) {
71366        group.pages[samePageIndex] = doc;
71367      }
71368    });
71369    aggregated.forEach((group) => group.pages.sort((first, second) => (first.Metadata?.Page ?? 0) - (second.Metadata?.Page ?? 0)));
71370    return aggregated;
71371  }
71372  /**
71373   * Etichetta del link a una singola pagina di un documento aggregato (es. "Pag. 169").
71374   * @param pageDoc Occorrenza del documento relativa alla pagina
71375   */
71376  documentPageLabel(pageDoc) {
71377    const template = this.translationService.getWithDefault("document_page_short", "Pag. %ph%");
71378    return template.replace(/%ph%/g, String(pageDoc?.Metadata?.Page ?? ""));
71379  }
71380  /**
71381   * Descrizione accessibile del link a una singola pagina, comprensiva del nome del documento
71382   * (es. "Apri Relazione sulla Gestione 2025 - Pag. 169").
71383   * @param pageDoc Occorrenza del documento relativa alla pagina
71384   */
71385  documentPageTitle(pageDoc) {
71386    const metadata = pageDoc?.Metadata;
71387    const documentName = metadata?.Filename || metadata?.Title || "";
71388    const template = this.translationService.getWithDefault("document_page_action", "Apri %ph%");
71389    return `${template.replace(/%ph%/g, documentName)} - ${this.documentPageLabel(pageDoc)}`;
71390  }
71391  /**
71392   * Nome da visualizzare per un documento aggregato.
71393   * @param group Documento aggregato
71394   * @param index Posizione nella lista, usata come fallback
71395   */
71396  aggregatedDocumentName(group, index) {
71397    const metadata = group?.document?.Metadata;
71398    return metadata?.Filename || metadata?.Title || `${this.translationService.getWithDefault("document", "Documento")} ${index + 1}`;
71399  }
71400  /**
71401   * Inverte lo stato di apertura/chiusura dell'accordion dei documenti per una specifica entry.
71402   * @param entry L'oggetto ConversationEntry per cui cambiare lo stato dell'accordion.
71403   */
71404  toggleDocumentsAccordion(entry) {
71405    if (entry) {
71406      entry.isDocumentsAccordionOpen = !entry.isDocumentsAccordionOpen;
71407    }
71408  }
71409  /**
71410   * Inverte lo stato di apertura/chiusura dell'accordion dei documenti correlati per una specifica entry.
71411   * @param entry L'oggetto ConversationEntry per cui cambiare lo stato dell'accordion.
71412   */
71413  toggleRelatedDocumentsAccordion(entry) {
71414    if (entry) {
71415      entry.isRelatedDocumentsAccordionOpen = !entry.isRelatedDocumentsAccordionOpen;
71416    }
71417  }
71418  /**
71419   * Inverte lo stato di apertura/chiusura dell'accordion della risposta tecnica per una specifica entry.
71420   * @param entry L'oggetto ConversationEntry per cui cambiare lo stato dell'accordion.
71421   */
71422  toggleTechnicalAnswerAccordion(entry) {
71423    if (entry) {
71424      entry.isTechnicalAnswerAccordionOpen = !entry.isTechnicalAnswerAccordionOpen;
71425    }
71426  }
71427  createHtmlTagId(prefix, entry) {
71428    return entry.corporateAgentData ? `${prefix}-${entry.corporateAgentData.Id}` : `${prefix}-undefined`;
71429  }
71430  /**
71431   * Effettua lo scroll automatico all'ultima entry aggiunta
71432   * in modo che sia visibile all'inizio dell'area visibile
71433   */
71434  scrollToLatestEntry() {
71435    if (!this.scrollContainer || !this.scrollContainer.nativeElement) {
71436      return;
71437    }
71438    const container = this.scrollContainer.nativeElement;
71439    if (this.conversationHistory.length > 0) {
71440      const entryElements = container.querySelectorAll(".conversation-entry");
71441      if (entryElements && entryElements.length > 0) {
71442        const lastEntry = entryElements[entryElements.length - 1];
71443        if (lastEntry) {
71444          lastEntry.scrollIntoView({ behavior: "smooth", block: "start" });
71445        }
71446      }
71447    }
71448  }
71449  // Implementa AfterViewChecked per processare i widget dopo il rendering
71450  ngAfterViewChecked() {
71451    if (this.pendingWidgetCreation) {
71452      this.pendingWidgetCreation = false;
71453      setTimeout(() => {
71454        const selector = "dora-corp-agent-user-history .conversation-entry:last-child";
71455        this.widgetService.addWidgetFromDOM(selector);
71456      }, 200);
71457    }
71458    if (this.scrollPending) {
71459      this.scrollPending = false;
71460      setTimeout(() => {
71461        this.scrollToLatestEntry();
71462        this.cdr.detectChanges();
71463      }, 300);
71464    }
71465  }
71466  /**
71467   * Costruisce tag dag-dora-series-from-grid e dag-dora-chart per visualizzare i dati con un grafico
71468   * @param corporateAgentData
71469   * @private
71470   */
71471  buildChartTagsInternal(corporateAgentData) {
71472    const eventChannel = this.widgetService.getNewEventChannel();
71473    const progressive = this.widgetService.getNewProgressive();
71474    const xlsxId = corporateAgentData.Data?.TableDataContent?.XlsxId || "";
71475    const dataId = corporateAgentData.Data?.TableDataContent?.DataId || "";
71476    const showTable = corporateAgentData.Data?.TableDataContent?.ShowTable || false;
71477    const defaultChartType = corporateAgentData.Data?.TableDataContent?.resolvedChartType() || "COLUMN";
71478    let seriesFromGridTag = `<dag-dora-series-from-grid EventChannel="${eventChannel}" progressive="${progressive}" publisherparameters="xlsxid\xA7${xlsxId}" gridid="${dataId}"`;
71479    if (corporateAgentData.Data?.TableDataContent?.SelectedRows && corporateAgentData.Data.TableDataContent.SelectedRows.length > 0) {
71480      seriesFromGridTag += ` descriptiondrowsInitial="${corporateAgentData.Data?.TableDataContent?.SelectedRows.join("\xA7")}"`;
71481    }
71482    if (corporateAgentData.Data?.TableDataContent?.SelectedColumns && corporateAgentData.Data.TableDataContent.SelectedColumns.length > 0) {
71483      seriesFromGridTag += ` idcolumnsInitial="${corporateAgentData.Data?.TableDataContent?.SelectedColumns.join("\xA7")}"`;
71484    }
71485    seriesFromGridTag += `></dag-dora-series-from-grid>`;
71486    let tableTag = "";
71487    let preselectTag = "";
71488    if (showTable) {
71489      tableTag += `<dag-dora-data-grid EventChannel="${eventChannel}" progressive="${progressive}" publisherparameters="xlsxid\xA7${xlsxId}" idgrid="${dataId}" `;
71490      if (corporateAgentData.Data?.TableDataContent?.SelectedRows && corporateAgentData.Data.TableDataContent.SelectedRows.length > 0) {
71491        tableTag += ` descriptiondrowsInitial="${corporateAgentData.Data?.TableDataContent?.SelectedRows.join("\xA7")}"`;
71492      }
71493      if (corporateAgentData.Data?.TableDataContent?.SelectedColumns && corporateAgentData.Data.TableDataContent.SelectedColumns.length > 0) {
71494        tableTag += ` idcolumnsInitial="${corporateAgentData.Data?.TableDataContent?.SelectedColumns.join("\xA7")}"`;
71495      }
71496      tableTag += ` checkBoxAsDiv="false"`;
71497      tableTag += "></dag-dora-data-grid>";
71498      if (!corporateAgentData.Data?.TableDataContent?.SelectedRows || corporateAgentData.Data.TableDataContent.SelectedRows.length === 0) {
71499        preselectTag = `<dag-dora-rows-preselect-tab EventChannel="${eventChannel}" progressive="${progressive}" publisherparameters="xlsxid\xA7${xlsxId}" gridId="${dataId}_Preselect" ></dag-dora-rows-preselect-tab>`;
71500      }
71501    }
71502    const chartTag = `<dag-dora-chart EventChannel="${eventChannel}" progressive="${progressive}" defaulttype="${defaultChartType}" tooltip="enabled\xA7b\xA7true\xA7outside\xA7b\xA7false" hideEmptyChart="${this.hideEmptyChart}" ></dag-dora-chart>`;
71503    return this.sanitizer.bypassSecurityTrustHtml(seriesFromGridTag + chartTag + tableTag + preselectTag);
71504  }
71505  buildCarouselTagsInternal(corporateAgentData) {
71506    const eventChannel = this.widgetService.getNewEventChannel();
71507    const progressive = this.widgetService.getNewProgressive();
71508    const carouselItems = corporateAgentData.Data?.CarouselDataContent?.items2Parameters() || "";
71509    const carouselTag = `<dag-dora-carousel EventChannel="${eventChannel}" progressive="${progressive}" carouselItems="${carouselItems}" autoplay="true"></dag-dora-carousel>`;
71510    return this.sanitizer.bypassSecurityTrustHtml(carouselTag);
71511  }
71512  addConversationHistory(newEntry) {
71513    const corporateAgentData = newEntry.corporateAgentData;
71514    newEntry.corporateAgentData = void 0;
71515    this.conversationHistory.push(newEntry);
71516    setTimeout(() => {
71517      newEntry.corporateAgentData = corporateAgentData;
71518    }, 200);
71519  }
71520  static {
71521    this.\u0275fac = function DoraCorpAgentUserHistoryComponent_Factory(__ngFactoryType__) {
71522      return new (__ngFactoryType__ || _DoraCorpAgentUserHistoryComponent)(\u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(MessageService), \u0275\u0275directiveInject(ConfigurationService), \u0275\u0275directiveInject(PublisherService), \u0275\u0275directiveInject(WidgetService), \u0275\u0275directiveInject(HttpClient), \u0275\u0275directiveInject(TranslationService), \u0275\u0275directiveInject(DomSanitizer), \u0275\u0275directiveInject(ChangeDetectorRef));
71523    };
71524  }
71525  static {
71526    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraCorpAgentUserHistoryComponent, selectors: [["dora-corp-agent-user-history"]], viewQuery: function DoraCorpAgentUserHistoryComponent_Query(rf, ctx) {
71527      if (rf & 1) {
71528        \u0275\u0275viewQuery(_c04, 5);
71529      }
71530      if (rf & 2) {
71531        let _t;
71532        \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.scrollContainer = _t.first);
71533      }
71534    }, standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 3, vars: 1, consts: [["aggregatedDocumentsList", ""], ["scrollC
71534ontainer", ""], ["class", "widget-container", 4, "ngIf"], [1, "widget-container"], ["class", "widget-title", 4, "ngIf"], [1, "conversation-history"], ["class", "conversation-entry", 4, "ngFor", "ngForOf"], ["class", "no-history", 4, "ngIf"], [1, "widget-title"], [1, "conversation-entry"], ["class", "user-message", 4, "ngIf"], ["class", "agent-message", 4, "ngIf"], [1, "user-message"], [1, "user-question"], [1, "question-content", 3, "innerHTML"], ["class", "pending-indicator", 4, "ngIf"], ["class", "question-timestamp timestamp", 4, "ngIf"], [1, "pending-indicator"], [1, "pending-text"], [1, "question-timestamp", "timestamp"], [1, "agent-message"], [1, "agent-answer", 2, "display", "flex", "flex-direction", "column"], [1, "answer-content"], [3, "innerHTML", 4, "ngIf"], [4, "ngIf"], ["class", "charts-container", 4, "ngIf"], ["class", "carousel-container", 4, "ngIf"], ["class", "technical-answer-container", 4, "ngIf"], ["class", "documents-container", 4, "ngIf"], ["class", "answer-timestamp timestamp", 4, "ngIf"], [3, "innerHTML"], [1, "charts-container"], [1, "carousel-container"], [1, "technical-answer-container"], [1, "accordion-header"], ["role", "button", "aria-disabled", "false", 1, "technical-answer-title", 3, "click", "id"], [1, "accordion-icon", 3, "ngClass"], ["class", "technical-answer", "role", "region", 3, "id", 4, "ngIf"], ["role", "region", 1, "technical-answer", 3, "id"], [1, "documents-container"], ["class", "documents-list", "role", "region", 3, "id", 4, "ngIf"], ["role", "button", "aria-disabled", "false", 1, "documents-title", 3, "click", "id"], [1, "doc-number"], [1, "documents-title"], ["role", "region", 1, "documents-list", 3, "id"], [3, "ngTemplateOutlet", "ngTemplateOutletContext", 4, "ngIf"], [3, "ngTemplateOutlet", "ngTemplateOutletContext"], ["class", "document-item", 4, "ngFor", "ngForOf"], [1, "document-item"], [3, "ngClass", "title", "click", 4, "ngIf"], [3, "click", "ngClass", "title"], [1, "document-icon"], [1, "document-title"], ["class", "document-type", 4, "ngIf"], ["class", "document-page", 4, "ngIf"], ["class", "document-score", 4, "ngIf"], ["class", "document-action sr-only", 4, "ngIf"], [1, "document-type"], [1, "document-page"], [1, "document-score"], [1, "document-action", "sr-only"], [1, "answer-timestamp", "timestamp"], [1, "no-history"], ["class", "document-item document-item-aggregated", 4, "ngFor", "ngForOf"], [1, "document-item", "document-item-aggregated"], ["type", "button", 3, "ngClass", "title", "click", 4, "ngIf"], [1, "document-header", 3, "ngClass"], ["role", "group", 1, "document-pages"], ["type", "button", 3, "ngClass", "title", "click", 4, "ngFor", "ngForOf"], ["type", "button", 3, "click", "ngClass", "title"], [1, "document-page-label"]], template: function DoraCorpAgentUserHistoryComponent_Template(rf, ctx) {
71535      if (rf & 1) {
71536        \u0275\u0275template(0, DoraCorpAgentUserHistoryComponent_div_0_Template, 6, 3, "div", 2)(1, DoraCorpAgentUserHistoryComponent_ng_template_1_Template, 2, 1, "ng-template", null, 0, \u0275\u0275templateRefExtractor);
71537      }
71538      if (rf & 2) {
71539        \u0275\u0275property("ngIf", ctx.visible);
71540      }
71541    }, dependencies: [NgClass, NgForOf, NgIf, NgTemplateOutlet, DecimalPipe, DatePipe, TranslatePipe, LatexPipe], styles: ['@charset "UTF-8";\n\n\n\n.widget-container[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  height: 100%;\n  width: 100%;\n  padding: 8px;\n  box-sizing: border-box;\n  position: relative;\n}\n.widget-title[_ngcontent-%COMP%] {\n  font-size: 1.2em;\n  font-weight: bold;\n  margin-bottom: 10px;\n  padding: 4px 0;\n}\n.conversation-history[_ngcontent-%COMP%] {\n  flex: 1;\n  overflow-y: auto;\n  max-height: calc(100% - 30px);\n  padding: 8px 0;\n  display: flex;\n  flex-direction: column;\n  gap: 8px;\n}\n.conversation-entry[_ngcontent-%COMP%] {\n  margin-bottom: 16px;\n  animation: _ngcontent-%COMP%_fadeIn 0.3s ease;\n}\n.timestamps[_ngcontent-%COMP%] {\n  display: flex;\n  justify-content: space-between;\n  font-size: 12px;\n  color: #777;\n  margin-bottom: 4px;\n}\n.timestamp[_ngcontent-%COMP%] {\n  font-size: 12px;\n  color: #777;\n  margin: 4px 0 8px 28px;\n}\n.question-timestamp[_ngcontent-%COMP%] {\n  color: #5a5a8e;\n}\n.answer-timestamp[_ngcontent-%COMP%] {\n  color: #558855;\n}\n.message-container[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  gap: 12px;\n}\n.user-message[_ngcontent-%COMP%], \n.agent-message[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  margin-bottom: 16px;\n}\n.user-question[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  background-color: #f5f8fb;\n  border-radius: 8px;\n  padding: 10px;\n}\n.user-question.pending[_ngcontent-%COMP%] {\n  opacity: 0.8;\n  position: relative;\n}\n.user-question.pending[_ngcontent-%COMP%]   .pending-indicator[_ngcontent-%COMP%] {\n  margin-top: 8px;\n}\n.user-question.pending[_ngcontent-%COMP%]   .pending-indicator[_ngcontent-%COMP%]   .pending-text[_ngcontent-%COMP%] {\n  font-style: italic;\n  color: #888;\n  font-size: 0.9em;\n  display: inline-flex;\n  align-items: center;\n}\n.user-question.pending[_ngcontent-%COMP%]   .pending-indicator[_ngcontent-%COMP%]   .pending-text[_ngcontent-%COMP%]:before {\n  content: "";\n  display: inline-block;\n  width: 10px;\n  height: 10px;\n  margin-right: 6px;\n  border-radius: 50%;\n  background-color: #7ca0c0;\n  animation: _ngcontent-%COMP%_pulse 1.5s infinite ease-in-out;\n}\n.agent-answer[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  background-color: #f0f7f0;\n  border-radius: 8px;\n  padding: 10px;\n}\n.question-content[_ngcontent-%COMP%], \n.answer-content[_ngcontent-%COMP%] {\n  color: #333;\n  word-break: break-word;\n}\n.answer-content[_ngcontent-%COMP%]   p[_ngcontent-%COMP%] {\n  margin-top: 0;\n}\n.documents-container[_ngcontent-%COMP%] {\n  margin: 8px 0 8px 28px;\n  padding: 10px;\n  border-left: 3px solid #7ca0c0;\n  background-color: #f8f9fa;\n  border-radius: 0 4px 4px 0;\n}\n.documents-container[_ngcontent-%COMP%]   .accordion-header[_ngcontent-%COMP%] {\n  cursor: pointer;\n  display: flex;\n  justify-content: space-between;\n  align-items: center;\n  padding: 8px 0;\n  border-bottom: 1px solid #eee;\n}\n.documents-container[_ngcontent-%COMP%]   .accordion-header[_ngcontent-%COMP%]:hover {\n  background-color: #f9f9f9;\n}\n.documents-container[_ngcontent-%COMP%]   .accordion-header[_ngcontent-%COMP%]   .accordion-icon[_ngcontent-%COMP%] {\n  font-size: 1.2em;\n  transition: transform 0.2s ease-in-out;\n  width: 15px;\n  height: 15px;\n}\n.documents-container[_ngcontent-%COMP%]   .accordion-header[_ngcontent-%COMP%]   .accordion-icon.accordion-open[_ngcontent-%COMP%] {\n  background-color: #72bd32;\n}\n.documents-container[_ngcontent-%COMP%]   .accordion-header[_ngcontent-%COMP%]   .accordion-icon.accordion-closed[_ngcontent-%COMP%] {\n  background-color: #cc3434;\n}\n.documents-container[_ngcontent-%COMP%]   .documents-list[_ngcontent-%COMP%] {\n  padding-left: 20px;\n  list-style-type: none;\n  margin-top: 8px;\n}\n.documents-container[_ngcontent-%COMP%]   .document-item[_ngcontent-%COMP%] {\n  padding: 4px 0;\n}\n.documents-title[_ngcontent-%COMP%] {\n  font-weight: 600;\n  font-size: 14px;\n  margin-bottom: 8px;\n  color: #555;\n}\n.document-link[_ngcontent-%COMP%] {\n  display: flex;\n  align-items: center;
71541\n  cursor: pointer;\n  padding: 4px 8px;\n  border-radius: 4px;\n  border: none;\n  transition: background-color 0.2s;\n}\n.document-link[_ngcontent-%COMP%]:hover {\n  background-color: rgba(0, 0, 0, 0.05);\n}\n.document-icon[_ngcontent-%COMP%] {\n  margin-right: 8px;\n  font-size: 16px;\n}\n.document-title[_ngcontent-%COMP%] {\n  font-size: 13px;\n  color: #0066cc;\n}\n.document-score[_ngcontent-%COMP%] {\n  font-size: 12px;\n  color: #666;\n  margin-left: 8px;\n}\n.document-item-aggregated[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n}\n.document-header[_ngcontent-%COMP%] {\n  display: flex;\n  align-items: center;\n}\n.document-pages[_ngcontent-%COMP%] {\n  display: flex;\n  flex-wrap: wrap;\n}\n.document-page-link[_ngcontent-%COMP%] {\n  cursor: pointer;\n}\n.technical-answer-container[_ngcontent-%COMP%] {\n  margin: 8px 0 8px 28px;\n  padding: 10px;\n  border-left: 3px solid #7ca0c0;\n  background-color: #f8f9fa;\n  border-radius: 0 4px 4px 0;\n}\n.technical-answer-container[_ngcontent-%COMP%]   .accordion-header[_ngcontent-%COMP%] {\n  cursor: pointer;\n  display: flex;\n  justify-content: space-between;\n  align-items: center;\n  padding: 8px 0;\n  border-bottom: 1px solid #eee;\n}\n.technical-answer-container[_ngcontent-%COMP%]   .accordion-header[_ngcontent-%COMP%]:hover {\n  background-color: #f9f9f9;\n}\n.technical-answer-container[_ngcontent-%COMP%]   .accordion-header[_ngcontent-%COMP%]   .accordion-icon[_ngcontent-%COMP%] {\n  font-size: 1.2em;\n  transition: transform 0.2s ease-in-out;\n  width: 15px;\n  height: 15px;\n}\n.technical-answer-container[_ngcontent-%COMP%]   .accordion-header[_ngcontent-%COMP%]   .accordion-icon.accordion-open[_ngcontent-%COMP%] {\n  background-color: #72bd32;\n}\n.technical-answer-container[_ngcontent-%COMP%]   .accordion-header[_ngcontent-%COMP%]   .accordion-icon.accordion-closed[_ngcontent-%COMP%] {\n  background-color: #cc3434;\n}\n.technical-answer-container[_ngcontent-%COMP%]   .documents-list[_ngcontent-%COMP%] {\n  padding-left: 20px;\n  list-style-type: none;\n  margin-top: 8px;\n}\n.technical-answer-container[_ngcontent-%COMP%]   .document-item[_ngcontent-%COMP%] {\n  padding: 4px 0;\n}\n.no-history[_ngcontent-%COMP%] {\n  color: #888;\n  font-style: italic;\n  text-align: center;\n  margin-top: 20px;\n}\n@keyframes _ngcontent-%COMP%_fadeIn {\n  from {\n    opacity: 0;\n    transform: translateY(-10px);\n  }\n  to {\n    opacity: 1;\n    transform: translateY(0);\n  }\n}\n@keyframes _ngcontent-%COMP%_pulse {\n  0% {\n    opacity: 0.3;\n    transform: scale(0.8);\n  }\n  50% {\n    opacity: 1;\n    transform: scale(1);\n  }\n  100% {\n    opacity: 0.3;\n    transform: scale(0.8);\n  }\n}'] });
71542  }
71543};
71544__decorate([
71545  DoraPropertyDOC("Titolo del widget", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
71546  DoraProperty,
71547  __metadata("design:type", String)
71548], DoraCorpAgentUserHistoryComponent.prototype, "widgetTitle", void 0);
71549__decorate([
71550  DoraPropertyDOC("Abilita la visualizzazione del titolo del widget", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
71551  DoraProperty,
71552  __metadata("design:type", Boolean)
71553], DoraCorpAgentUserHistoryComponent.prototype, "widgetTitleEnabled", void 0);
71554__decorate([
71555  DoraPropertyDOC("Massimo numero di messaggi da visualizzare", ATTRIBUTE_TYPE.INTEGER, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
71556  DoraProperty,
71557  __metadata("design:type", Number)
71558], DoraCorpAgentUserHistoryComponent.prototype, "maxMessages", void 0);
71559__decorate([
71560  DoraPropertyDOC("Mostra i documenti collegati come accordion", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
71561  DoraProperty,
71562  __metadata("design:type", Boolean)
71563], DoraCorpAgentUserHistoryComponent.prototype, "linkedDocumentsAsAccordion", void 0);
71564__decorate([
71565  DoraPropertyDOC("Mostra i documenti correlati come accordion", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
71566  DoraProperty,
71567  __metadata("design:type", Boolean)
71568], DoraCorpAgentUserHistoryComponent.prototype, "relatedDocumentsAsAccordion", void 0);
71569__decorate([
71570  DoraPropertyDOC("Non mostra il grafico senza dati", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
71571  DoraProperty,
71572  __metadata("design:type", Boolean)
71573], DoraCorpAgentUserHistoryComponent.prototype, "hideEmptyChart", void 0);
71574__decorate([
71575  DoraPropertyDOC("Aggrega i documenti mostrando i link alle pagine", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
71576  DoraProperty,
71577  __metadata("design:type", Boolean)
71578], DoraCorpAgentUserHistoryComponent.prototype, "aggregateDocuments", void 0);
71579__decorate([
71580  DoraPropertyDOC("Aggrega i documenti correlati mostrando i link alle pagine", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
71581  DoraProperty,
71582  __metadata("design:type", Boolean)
71583], DoraCorpAgentUserHistoryComponent.prototype, "aggregateRelatedDocuments", void 0);
71584(() => {
71585  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraCorpAgentUserHistoryComponent, { className: "DoraCorpAgentUserHistoryComponent", filePath: "src/app/dorawidget/dora-corp-agent-user-history/dora-corp-agent-user-history.component.ts", lineNumber: 40 });
71586})();
71587
71588// src/app/DoraWidget/dora-corp-agent-wizard/dora-corp-agent-wizard.component.ts
71589function DoraCorpAgentWizardComponent_div_0_div_1_button_1_Template(rf, ctx) {
71590  if (rf & 1) {
71591    const _r1 = \u0275\u0275getCurrentView();
71592    \u0275\u0275elementStart(0, "button", 6);
71593    \u0275\u0275listener("click", function DoraCorpAgentWizardComponent_div_0_div_1_button_1_Template_button_click_0_listener() {
71594      const i_r2 = \u0275\u0275restoreView(_r1).index;
71595      const ctx_r2 = \u0275\u0275nextContext(3);
71596      return \u0275\u0275resetView(ctx_r2.onSelectWizard(i_r2));
71597    });
71598    \u0275\u0275element(1, "span", 7);
71599    \u0275\u0275elementStart(2, "span", 8);
71600    \u0275\u0275text(3);
71601    \u0275\u0275elementEnd();
71602    \u0275\u0275element(4, "span", 9);
71603    \u0275\u0275elementEnd();
71604  }
71605  if (rf & 2) {
71606    const wizardConfig_r4 = ctx.$implicit;
71607    \u0275\u0275property("ngClass", wizardConfig_r4 && wizardConfig_r4.CssClassName ? "wizard-item-" + wizardConfig_r4.CssClassName : "");
71608    \u0275\u0275advance(3);
71609    \u0275\u0275textInterpolate(wizardConfig_r4.Description);
71610  }
71611}
71612function DoraCorpAgentWizardComponent_div_0_div_1_Template(rf, ctx) {
71613  if (rf & 1) {
71614    \u0275\u0275elementStart(0, "div", 4);
71615    \u0275\u0275template(1, DoraCorpAgentWizardComponent_div_0_div_1_button_1_Template, 5, 2, "button", 5);
71616    \u0275\u0275elementEnd();
71617  }
71618  if (rf & 2) {
71619    const ctx_r2 = \u0275\u0275nextContext(2);
71620    \u0275\u0275advance();
71621    \u0275\u0275property("ngForOf", ctx_r2.dataCorporateAgentWizard);
71622  }
71623}
71624function DoraCorpAgentWizardComponent_div_0_div_2_div_3_Template(rf, ctx) {
71625  if (rf & 1) {
71626    \u0275\u0275elementStart(0, "div", 15);
71627    \u0275\u0275text(1);
71628    \u0275\u0275elementEnd();
71629  }
71630  if (rf & 2) {
71631    const ctx_r2 = \u0275\u0275nextContext(3);
71632    \u0275\u0275advance();
71633    \u0275\u0275textInterpolate1(" ", ctx_r2.dataCorporateAgentWizard[ctx_r2.activeQuestion].Description, " ");
71634  }
71635}
71636function DoraCorpAgentWizardComponent_div_0_div_2_div_4_button_1_Template(rf, ctx) {
71637  if (rf & 1) {
71638    const _r6 = \u0275\u0275getCurrentView();
71639    \u0275\u0275elementStart(0, "button", 18);
71640    \u0275\u0275listener("click", function DoraCorpAgentWizardComponent_div_0_div_2_div_4_button_1_Template_button_click_0_listener() {
71641      const question_r7 = \u0275\u0275restoreView(_r6).$implicit;
71642      const ctx_r2 = \u0275\u0275nextContext(4);
71643      return \u0275\u0275resetView(ctx_r2.sendWizardQuestion(question_r7 && question_r7.Title));
71644    });
71645    \u0275\u0275text(1);
71646    \u0275\u0275elementEnd();
71647  }
71648  if (rf & 2) {
71649    const question_r7 = ctx.$implicit;
71650    \u0275\u0275advance();
71651    \u0275\u0275textInterpolate1(" ", question_r7 && question_r7.Title, " ");
71652  }
71653}
71654function DoraCorpAgentWizardComponent_div_0_div_2_div_4_Template(rf, ctx) {
71655  if (rf & 1) {
71656    \u0275\u0275elementStart(0, "div", 16);
71657    \u0275\u0275template(1, DoraCorpAgentWizardComponent_div_0_div_2_div_4_button_1_Template, 2, 1, "button", 17);
71658    \u0275\u0275elementEnd();
71659  }
71660  if (rf & 2) {
71661    const ctx_r2 = \u0275\u0275nextContext(3);
71662    \u0275\u0275advance();
71663    \u0275\u0275property("ngForOf", ctx_r2.dataCorporateAgentWizard[ctx_r2.activeQuestion].Questions);
71664  }
71665}
71666function DoraCorpAgentWizardComponent_div_0_div_2_Template(rf, ctx) {
71667  if (rf & 1) {
71668    const _r5 = \u0275\u0275getCurrentView();
71669    \u0275\u0275elementStart(0, "div", 10)(1, "div", 11)(2, "button", 12);
71670    \u0275\u0275listener("click", function DoraCorpAgentWizardComponent_div_0_div_2_Template_button_click_2_listener() {
71671      \u0275\u0275restoreView(_r5);
71672      const ctx_r2 = \u0275\u0275nextContext(2);
71673      return \u0275\u0275resetView(ctx_r2.backToList());
71674    });
71675    \u0275\u0275elementEnd();
71676    \u0275\u0275template(3, DoraCorpAgentWizardComponent_div_0_div_2_div_3_Template, 2, 1, "div", 13);
71677    \u0275\u0275elementEnd();
71678    \u0275\u0275template(4, DoraCorpAgentWizardComponent_div_0_div_2_div_4_Template, 2, 1, "div", 14);
71679    \u0275\u0275elementEnd();
71680  }
71681  if (rf & 2) {
71682    const ctx_r2 = \u0275\u0275nextContext(2);
71683    \u0275\u0275advance(2);
71684    \u0275\u0275attribute("aria-label", ctx_r2.translationService.get("wizard-Back-Label"));
71685    \u0275\u0275advance();
71686    \u0275\u0275property("ngIf", ctx_r2.dataCorporateAgentWizard && ctx_r2.dataCorporateAgentWizard[ctx_r2.activeQuestion]);
71687    \u0275\u0275advance();
71688    \u0275\u0275property("ngIf", ctx_r2.dataCorporateAgentWizard && ctx_r2.dataCorporateAgentWizard[ctx_r2.activeQuestion] && ctx_r2.dataCorporateAgentWizard[ctx_r2.activeQuestion].Questions);
71689  }
71690}
71691function DoraCorpAgentWizardComponent_div_0_Template(rf, ctx) {
71692  if (rf & 1) {
71693    \u0275\u0275elementStart(0, "div", 1);
71694    \u0275\u0275template(1, DoraCorpAgentWizardComponent_div_0_div_1_Template, 2, 1, "div", 2)(2, DoraCorpAgentWizardComponent_div_0_div_2_Template, 5, 3, "div", 3);
71695    \u0275\u0275elementEnd();
71696  }
71697  if (rf & 2) {
71698    const ctx_r2 = \u0275\u0275nextContext();
71699    \u0275\u0275advance();
71700    \u0275\u0275property("ngIf", ctx_r2.activeQuestion === -1);
71701    \u0275\u0275advance();
71702    \u0275\u0275property("ngIf", ctx_r2.activeQuestion !== -1);
71703  }
71704}
71705var DoraCorpAgentWizardComponent = class _DoraCorpAgentWizardComponent extends WidgetBaseComponent {
71706  constructor() {
71707    super(...arguments);
71708    this.activeQuestion = -1;
71709    this.visible = true;
71710    this.dataCorporateAgentWizard = [];
71711  }
71712  onParameterInjectedFinished() {
71713    super.onParameterInjectedFinished();
71714    this.read(
71715      [],
71716      // SubscribeObjInfo - stringa con il valore di user input
71717      DataType.CORPORATE_AGENT_WIZARD
71718    ).subscribe((data) => {
71719      const dataCorporateAgentWizard = data.data;
71720      if (dataCorporateAgentWizard) {
71721        this.dataCorporateAgentWizard = dataCorporateAgentWizard;
71722      }
71723    });
71724    this.messageService.getMessage(this.EventChannel, MessageCorporateAgentWizardVisible, this.CallerName).subscribe((message) => {
71725      if (message && message.data) {
71726        const messageCorporateAgentWizardVisible = message.data;
71727        this.setVisible(messageCorporateAgentWizardVisible.visible);
71728      }
71729    });
71730  }
71731  /**
71732   * Torna alla visualizzazione della lista dei wizard
71733   */
71734  backToList() {
71735    this.setVisible(true);
71736  }
71737  /**
71738   * Invia un messaggio quando l'utente seleziona una domanda dal wizard
71739   * @param questionTitle Il titolo della domanda selezionata
71740   */
71741  sendWizardQuestion(questionTitle) {
71742    if (questionTitle) {
71743      this.messageService.sendMessage(this.EventChannel, new MessageCorporateAgentWizardInput(questionTitle), this.CallerName);
71744    }
71745  }
71746  /**
71747   * Gestisce il click su un wizard e mostra le sue domande
71748   * @param index Indice del wizard selezionato
71749   */
71750  onSelectWizard(index) {
71751    if (index >= 0 && this.dataCorporateAgentWizard && index < this.dataCorporateAgentWizard.length) {
71752      this.activeQuestion = index;
71753      if (typeof window !== "undefined" && typeof window.onDoraCorpAgentWizardSelected === "function") {
71754        try {
71755          window.onDoraCorpAgentWizardSelected();
71756        } catch (error) {
71757          console.error("Error calling onDoraCorpAgentWizardSelected:", error);
71758        }
71759      }
71760    }
71761  }
71762  setVisible(visible) {
71763    if (visible) {
71764      this.activeQuestion = -1;
71765      if (typeof window !== "undefined" && typeof window.onDoraCorpAgentWizardVisible === "function") {
71766        try {
71767          window.onDoraCorpAgentWizardVisible();
71768        } catch (error) {
71769          console.error("Error calling onDoraCorpAgentWizardVisible:", error);
71770        }
71771      }
71772      this.publisherReset();
71773    } else {
71774      if (typeof window !== "undefined" && typeof window.onDoraCorpAgentWizardUnvisible === "function") {
71775        try {
71776          window.onDoraCorpAgentWizardUnvisible();
71777        } catch (error) {
71778          console.error("Error calling onDoraCorpAgentWizardUnvisible:", error);
71779        }
71780      }
71781    }
71782    this.visible = visible;
71783  }
71784  static {
71785    this.\u0275fac = /* @__PURE__ */ (() => {
71786      let \u0275DoraCorpAgentWizardComponent_BaseFactory;
71787      return function DoraCorpAgentWizardComponent_Factory(__ngFactoryType__) {
71788        return (\u0275DoraCorpAgentWizardComponent_BaseFactory || (\u0275DoraCorpAgentWizardComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraCorpAgentWizardComponent)))(__ngFactoryType__ || _DoraCorpAgentWizardComponent);
71789      };
71790    })();
71791  }
71792  static {
71793    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraCorpAgentWizardComponent, selectors: [["dora-corp-agent-wizard"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 1, vars: 1, consts: [["class", "wizard-container", 4, "ngIf"], [1, "wizard-container"], ["class", "wizard-list", 4, "ngIf"], ["class", "wizard-detail", 4, "ngIf"], [1, "wizard-list"], ["type", "button", "class", "wizard-item", 3, "ngClass", "click", 4, "ngFor", "ngForOf"], ["type", "button", 1, "wizard-item", 3, "click", "ngClass"], [1, "wizard-first"], [1, "wizard-description"], [1, "wizard-last"], [1, "wizard-detail"], [1, "wizard-detail-header"], [1, "wizard-back-button", 3, "click"], ["class", "wizard-detail-title", 4, "ngIf"], ["class", "wizard-detail-content", 4, "ngIf"], [1, "wizard-detail-title"], [1, "wizard-detail-content"], ["type", "button", "class", "wizard-question", 3, "click", 4, "ngFor", "ngForOf"], ["type", "button", 1, "wizard-question", 3, "click"]], template: function DoraCorpAgentWizardComponent_Template(rf, ctx) {
71794      if (rf & 1) {
71795        \u0275\u0275template(0, DoraCorpAgentWizardComponent_div_0_Template, 3, 2, "div", 0);
71796      }
71797      if (rf & 2) {
71798        \u0275\u0275property("ngIf", ctx.visible);
71799      }
71800    }, dependencies: [NgClass, NgForOf, NgIf], styles: ["\n\n.wizard-container[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  border: 1px solid #e0e0e0;\n  border-radius: 8px;\n  padding: 16px;\n  background-color: #ffffff;\n  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-list[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  gap: 16px;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-list[_ngcontent-%COMP%]   .wizard-item[_ngcontent-%COMP%] {\n  display: flex;\n  align-items: stretch;\n  width: 100%;\n  padding: 16px;
71800\n  border: 1px solid #f0f0f0;\n  border-radius: 6px;\n  background-color: #fafafa;\n  transition: all 0.2s ease-in-out;\n  cursor: pointer;\n  font-family: inherit;\n  font-size: inherit;\n  text-align: left;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-list[_ngcontent-%COMP%]   .wizard-item[_ngcontent-%COMP%]:hover {\n  transform: translateY(-2px);\n  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.08);\n  background-color: #f5f5f5;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-list[_ngcontent-%COMP%]   .wizard-item[_ngcontent-%COMP%]:focus {\n  outline: 2px solid #4285f4;\n  outline-offset: 2px;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-list[_ngcontent-%COMP%]   .wizard-item[_ngcontent-%COMP%]   .wizard-first[_ngcontent-%COMP%], \n.wizard-container[_ngcontent-%COMP%]   .wizard-list[_ngcontent-%COMP%]   .wizard-item[_ngcontent-%COMP%]   .wizard-last[_ngcontent-%COMP%] {\n  width: 40px;\n  min-width: 40px;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-list[_ngcontent-%COMP%]   .wizard-item[_ngcontent-%COMP%]   .wizard-description[_ngcontent-%COMP%] {\n  flex: 1;\n  font-size: 0.9rem;\n  color: #666666;\n  padding: 0 16px;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-list[_ngcontent-%COMP%]   .wizard-item-primary[_ngcontent-%COMP%] {\n  border-left: 4px solid #4285f4;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-list[_ngcontent-%COMP%]   .wizard-item-secondary[_ngcontent-%COMP%] {\n  border-left: 4px solid #34a853;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-list[_ngcontent-%COMP%]   .wizard-item-tertiary[_ngcontent-%COMP%] {\n  border-left: 4px solid #fbbc05;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-detail[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  gap: 20px;\n  margin-top: 10px;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-detail-header[_ngcontent-%COMP%] {\n  display: flex;\n  align-items: center;\n  margin-bottom: 20px;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-detail-header[_ngcontent-%COMP%]   .wizard-back-button[_ngcontent-%COMP%] {\n  width: 15px;\n  height: 15px;\n  background-color: red;\n  border: none;\n  border-radius: 4px;\n  color: #333;\n  font-weight: 500;\n  cursor: pointer;\n  margin-right: 16px;\n  transition: background-color 0.2s;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-detail-header[_ngcontent-%COMP%]   .wizard-back-button[_ngcontent-%COMP%]:hover {\n  background-color: #e0e0e0;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-detail-header[_ngcontent-%COMP%]   .wizard-back-button[_ngcontent-%COMP%]:focus {\n  outline: 2px solid #4285f4;\n  outline-offset: 2px;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-detail-title[_ngcontent-%COMP%] {\n  font-size: 1.2rem;\n  font-weight: 600;\n  color: #333;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-detail-content[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  gap: 12px;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-detail-content[_ngcontent-%COMP%]   .wizard-question[_ngcontent-%COMP%] {\n  width: 100%;\n  padding: 14px;\n  background-color: #f9f9f9;\n  border: none;\n  border-left: 4px solid #4285f4;\n  border-radius: 4px;\n  font-family: inherit;\n  font-size: inherit;\n  font-weight: 500;\n  text-align: left;\n  cursor: pointer;\n  transition: all 0.2s;\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-detail-content[_ngcontent-%COMP%]   .wizard-question[_ngcontent-%COMP%]:hover {\n  background-color: #eef5ff;\n  transform: translateX(4px);\n}\n.wizard-container[_ngcontent-%COMP%]   .wizard-detail-content[_ngcontent-%COMP%]   .wizard-question[_ngcontent-%COMP%]:focus {\n  outline: 2px solid #4285f4;\n  outline-offset: 2px;\n}"] });
71801  }
71802};
71803(() => {
71804  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraCorpAgentWizardComponent, { className: "DoraCorpAgentWizardComponent", filePath: "src/app/dorawidget/dora-corp-agent-wizard/dora-corp-agent-wizard.component.ts", lineNumber: 20 });
71805})();
71806
71807// src/app/DoraWidget/dora-corp-agent-wizard-show/dora-corp-agent-wizard-show.component.ts
71808var DoraCorpAgentWizardShowComponent = class _DoraCorpAgentWizardShowComponent extends WidgetBaseComponent {
71809  constructor() {
71810    super(...arguments);
71811    this.buttonText = _TRANSLATE("show_wizard");
71812    this.buttonLabel = _TRANSLATE("show_wizard_label");
71813  }
71814  onParameterInjectedFinished() {
71815    super.onParameterInjectedFinished();
71816    this.buttonText = this.translationService.get(this.buttonText);
71817    this.buttonLabel = this.translationService.get(this.buttonLabel);
71818  }
71819  /**
71820   * Invia un messaggio per mostrare il wizard
71821   */
71822  showWizard() {
71823    this.messageService.sendMessage(this.EventChannel, new MessageCorporateAgentWizardVisible(true), this.CallerName);
71824  }
71825  static {
71826    this.\u0275fac = /* @__PURE__ */ (() => {
71827      let \u0275DoraCorpAgentWizardShowComponent_BaseFactory;
71828      return function DoraCorpAgentWizardShowComponent_Factory(__ngFactoryType__) {
71829        return (\u0275DoraCorpAgentWizardShowComponent_BaseFactory || (\u0275DoraCorpAgentWizardShowComponent_BaseFactory = \u0275\u0275getInheritedFactory(_DoraCorpAgentWizardShowComponent)))(__ngFactoryType__ || _DoraCorpAgentWizardShowComponent);
71830      };
71831    })();
71832  }
71833  static {
71834    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraCorpAgentWizardShowComponent, selectors: [["dora-corp-agent-wizard-show"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 3, vars: 2, consts: [[1, "wizard-show-container"], [1, "wizard-show-button", 3, "click"]], template: function DoraCorpAgentWizardShowComponent_Template(rf, ctx) {
71835      if (rf & 1) {
71836        \u0275\u0275elementStart(0, "div", 0)(1, "button", 1);
71837        \u0275\u0275listener("click", function DoraCorpAgentWizardShowComponent_Template_button_click_1_listener() {
71838          return ctx.showWizard();
71839        });
71840        \u0275\u0275text(2);
71841        \u0275\u0275elementEnd()();
71842      }
71843      if (rf & 2) {
71844        \u0275\u0275advance();
71845        \u0275\u0275attribute("aria-label", ctx.buttonLabel);
71846        \u0275\u0275advance();
71847        \u0275\u0275textInterpolate1(" ", ctx.buttonText, " ");
71848      }
71849    }, styles: ["\n\n.wizard-show-container[_ngcontent-%COMP%] {\n  display: flex;\n  justify-content: center;\n  padding: 10px;\n}\n.wizard-show-button[_ngcontent-%COMP%] {\n  padding: 8px 16px;\n  background-color: #4285f4;\n  color: white;\n  border: none;\n  border-radius: 4px;\n  font-weight: 500;\n  cursor: pointer;\n  transition: background-color 0.2s;\n}\n.wizard-show-button[_ngcontent-%COMP%]:hover {\n  background-color: #3367d6;\n}"] });
71850  }
71851};
71852__decorate([
71853  DoraPropertyDOC("Testo del pulsante", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, false),
71854  DoraProperty,
71855  __metadata("design:type", String)
71856], DoraCorpAgentWizardShowComponent.prototype, "buttonText", void 0);
71857(() => {
71858  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraCorpAgentWizardShowComponent, { className: "DoraCorpAgentWizardShowComponent", filePath: "src/app/dorawidget/dora-corp-agent-wizard-show/dora-corp-agent-wizard-show.component.ts", lineNumber: 14 });
71859})();
71860
71861// src/app/DoraWidget/dora-corp-agent-close/dora-corp-agent-close.component.ts
71862var DoraCorpAgentCloseComponent = class _DoraCorpAgentCloseComponent extends WidgetBaseComponent {
71863  constructor(elementRef, messageService, configurationService, publisher, widgetService, http, translationService) {
71864    super(elementRef, messageService, configurationService, publisher, widgetService, http, translationService);
71865    this.buttonText = _TRANSLATE("close");
71866  }
71867  ngOnInit() {
71868    super.ngOnInit();
71869  }
71870  onParameterInjectedFinished() {
71871    super.onParameterInjectedFinished();
71872    this.buttonText = this.translationService.get(this.buttonText);
71873  }
71874  onCloseClick() {
71875    this.messageService.sendMessage(this.EventChannel, new MessageCorporateAgentHistoryClear(), this.CallerName);
71876    this.messageService.sendMessage(this.EventChannel, new MessageCorporateAgentWizardVisible(true), this.CallerName);
71877    const w = typeof window !== "undefined" ? window : void 0;
71878    const fn = w?.onDoraCorpAgentClose;
71879    if (typeof fn === "function") {
71880      try {
71881        fn();
71882      } catch (e) {
71883        console.error("onDoraCorpAgentClose failed", e);
71884      }
71885    }
71886  }
71887  static {
71888    this.\u0275fac = function DoraCorpAgentCloseComponent_Factory(__ngFactoryType__) {
71889      return new (__ngFactoryType__ || _DoraCorpAgentCloseComponent)(\u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(MessageService), \u0275\u0275directiveInject(ConfigurationService), \u0275\u0275directiveInject(PublisherService), \u0275\u0275directiveInject(WidgetService), \u0275\u0275directiveInject(HttpClient), \u0275\u0275directiveInject(TranslationService));
71890    };
71891  }
71892  static {
71893    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraCorpAgentCloseComponent, selectors: [["dora-corp-agent-close"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 2, vars: 2, consts: [["type", "button", 1, "corp-agent-close-button", 3, "click"]], template: function DoraCorpAgentCloseComponent_Template(rf, ctx) {
71894      if (rf & 1) {
71895        \u0275\u0275elementStart(0, "button", 0);
71896        \u0275\u0275listener("click", function DoraCorpAgentCloseComponent_Template_button_click_0_listener() {
71897          return ctx.onCloseClick();
71898        });
71899        \u0275\u0275text(1);
71900        \u0275\u0275elementEnd();
71901      }
71902      if (rf & 2) {
71903        \u0275\u0275attribute("aria-label", ctx.translationService.get("agent_Close_Label"));
71904        \u0275\u0275advance();
71905        \u0275\u0275textInterpolate(ctx.buttonText);
71906      }
71907    }, styles: ["\n\n.corp-agent-close-button[_ngcontent-%COMP%] {\n  cursor: pointer;\n}"] });
71908  }
71909};
71910__decorate([
71911  DoraPropertyDOC("Testo del bottone di chiusura", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, false),
71912  DoraProperty,
71913  __metadata("design:type", String)
71914], DoraCorpAgentCloseComponent.prototype, "buttonText", void 0);
71915(() => {
71916  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraCorpAgentCloseComponent, { className: "DoraCorpAgentCloseComponent", filePath: "src/app/dorawidget/dora-corp-agent-close/dora-corp-agent-close.component.ts", lineNumber: 20 });
71917})();
71918
71919// src/app/DoraWidget/dora-url-content/dora-url-content.component.ts
71920var _c05 = ["contentContainer"];
71921var _c14 = ["closeButton"];
71922function DoraUrlContentComponent_div_1_Template(rf, ctx) {
71923  if (rf & 1) {
71924    \u0275\u0275elementStart(0, "div", 11);
71925    \u0275\u0275text(1);
71926    \u0275\u0275elementEnd();
71927  }
71928  if (rf & 2) {
71929    const ctx_r1 = \u0275\u0275nextContext();
71930    \u0275\u0275advance();
71931    \u0275\u0275textInterpolate(ctx_r1.widgetTitle);
71932  }
71933}
71934function DoraUrlContentComponent_div_4_Template(rf, ctx) {
71935  if (rf & 1) {
71936    const _r3 = \u0275\u0275getCurrentView();
71937    \u0275\u0275elementStart(0, "div", 12)(1, "div", 13);
71938    \u0275\u0275text(2);
71939    \u0275\u0275elementEnd();
71940    \u0275\u0275elementStart(3, "button", 14, 1);
71941    \u0275\u0275listener("click", function DoraUrlContentComponent_div_4_Template_button_click_3_listener() {
71942      \u0275\u0275restoreView(_r3);
71943      const ctx_r1 = \u0275\u0275nextContext();
71944      return \u0275\u0275resetView(ctx_r1.closeContent());
71945    });
71946    \u0275\u0275text(5, "\u2715");
71947    \u0275\u0275elementEnd()();
71948  }
71949  if (rf & 2) {
71950    const ctx_r1 = \u0275\u0275nextContext();
71951    \u0275\u0275advance();
71952    \u0275\u0275property("id", "url-content-title-" + ctx_r1.progressive);
71953    \u0275\u0275advance();
71954    \u0275\u0275textInterpolate(ctx_r1.contentTitle);
71955    \u0275\u0275advance();
71956    \u0275\u0275attribute("aria-label", ctx_r1.translationService.get("close_content_button"));
71957  }
71958}
71959function DoraUrlContentComponent_div_5_Template(rf, ctx) {
71960  if (rf & 1) {
71961    \u0275\u0275elementStart(0, "div", 15);
71962    \u0275\u0275element(1, "div", 16);
71963    \u0275\u0275elementStart(2, "div", 17);
71964    \u0275\u0275text(3);
71965    \u0275\u0275pipe(4, "translate");
71966    \u0275\u0275elementEnd()();
71967  }
71968  if (rf & 2) {
71969    \u0275\u0275advance(3);
71970    \u0275\u0275textInterpolate(\u0275\u0275pipeBind1(4, 1, "loading_content"));
71971  }
71972}
71973function DoraUrlContentComponent_div_6_Template(rf, ctx) {
71974  if (rf & 1) {
71975    \u0275\u0275elementStart(0, "div", 18)(1, "div", 19);
71976    \u0275\u0275text(2, "\u26A0\uFE0F");
71977    \u0275\u0275elementEnd();
71978    \u0275\u0275elementStart(3, "div", 20);
71979    \u0275\u0275text(4);
71980    \u0275\u0275pipe(5, "translate");
71981    \u0275\u0275elementEnd()();
71982  }
71983  if (rf & 2) {
71984    const ctx_r1 = \u0275\u0275nextContext();
71985    \u0275\u0275advance(4);
71986    \u0275\u0275textInterpolate(ctx_r1.errorMessage || \u0275\u0275pipeBind1(5, 1, "error_loading_content"));
71987  }
71988}
71989function DoraUrlContentComponent_div_7_Template(rf, ctx) {
71990  if (rf & 1) {
71991    \u0275\u0275elementStart(0, "div", 21)(1, "iframe", 22);
71992    \u0275\u0275text(2);
71993    \u0275\u0275pipe(3, "translate");
71994    \u0275\u0275elementEnd()();
71995  }
71996  if (rf & 2) {
71997    const ctx_r1 = \u0275\u0275nextContext();
71998    \u0275\u0275advance();
71999    \u0275\u0275property("src", ctx_r1.safeUrl, \u0275\u0275sanitizeResourceUrl);
72000    \u0275\u0275advance();
72001    \u0275\u0275textInterpolate1(" ", \u0275\u0275pipeBind1(3, 2, "browser_not_support_pdf"), " ");
72002  }
72003}
72004function DoraUrlContentComponent_div_8_Template(rf, ctx) {
72005  if (rf & 1) {
72006    \u0275\u0275elementStart(0, "div", 23);
72007    \u0275\u0275element(1, "img", 24);
72008    \u0275\u0275elementEnd();
72009  }
72010  if (rf & 2) {
72011    const ctx_r1 = \u0275\u0275nextContext();
72012    \u0275\u0275advance();
72013    \u0275\u0275propertyInterpolate("alt", ctx_r1.contentTitle || "Image content");
72014    \u0275\u0275property("src", ctx_r1.safeUrl, \u0275\u0275sanitizeUrl);
72015  }
72016}
72017function DoraUrlContentComponent_div_9_Template(rf, ctx) {
72018  if (rf & 1) {
72019    \u0275\u0275elementStart(0, "div", 25)(1, "iframe", 26);
72020    \u0275\u0275text(2);
72021    \u0275\u0275pipe(3, "translate");
72022    \u0275\u0275elementEnd()();
72023  }
72024  if (rf & 2) {
72025    const ctx_r1 = \u0275\u0275nextContext();
72026    \u0275\u0275styleProp("height", ctx_r1.viewerHeight, "px");
72027    \u0275\u0275advance();
72028    \u0275\u0275property("src", ctx_r1.safeUrl, \u0275\u0275sanitizeResourceUrl);
72029    \u0275\u0275advance();
72030    \u0275\u0275textInterpolate1(" ", \u0275\u0275pipeBind1(3, 4, "browser_not_support_content"), " ");
72031  }
72032}
72033var DoraUrlContentComponent = class _DoraUrlContentComponent extends WidgetBaseComponent {
72034  get hasContent() {
72035    return !this.isLoading && !this.loadError && !!this.safeUrl;
72036  }
72037  constructor(elementRef, messageService, configurationService, publisher, widgetService, http, translationService, sanitizer) {
72038    super(elementRef, messageService, configurationService, publisher, widgetService, http, translationService);
72039    this.sanitizer = sanitizer;
72040    this.widgetTitle = _TRANSLATE("url_content_viewer");
72041    this.widgetTitleEnabled = true;
72042    this.viewerHeight = 600;
72043    this.currentUrl = null;
72044    this.contentTitle = null;
72045    this.safeUrl = null;
72046    this.contentType = null;
72047    this.documentType = void 0;
72048    this.documentName = void 0;
72049    this.loadError = false;
72050    this.errorMessage = "";
72051    this.isLoading = false;
72052    this._previousFocusElement = null;
72053  }
72054  onParameterInjectedFinished() {
72055    super.onParameterInjectedFinished();
72056    this.widgetTitle = this.translationService.get(this.widgetTitle);
72057    this.messageService.getMessage(this.EventChannel, MessageUrlContent, this.CallerName).subscribe((message) => {
72058      if (message && message.data) {
72059        const urlContentMessage = message.data;
72060        this.loadContent(urlContentMessage.url, urlContentMessage.title, urlContentMessage.contentType, urlContentMessage.documentName, urlContentMessage.documentType);
72061      }
72062    });
72063  }
72064  onDocumentKeydown(event2) {
72065    if (!this.hasContent)
72066      return;
72067    if (event2.key === "Escape") {
72068      event2.preventDefault();
72069      this.closeContent();
72070      return;
72071    }
72072    if (event2.key === "Tab") {
72073      this.trapFocus(event2);
72074    }
72075  }
72076  loadContent(url, title, contentType, documentName, documentType) {
72077    this.loadError = false;
72078    this.errorMessage = "";
72079    this.isLoading = true;
72080    if (!url) {
72081      this.handleError("URL non valido o mancante");
72082      return;
72083    }
72084    this._previousFocusElement = document.activeElement;
72085    this.currentUrl = url;
72086    this.documentType = documentType;
72087    this.documentName = documentName;
72088    if (documentType && documentName) {
72089      this.contentTitle = this.translationService.translateWithPlaceHolder("document_preview_" + documentType, documentName);
72090    } else {
72091      this.contentTitle = title || this.extractFilenameFromUrl(url);
72092    }
72093    this.contentType = contentType || this.determineContentType(url);
72094    try {
72095      this.safeUrl = this.sanitizer.bypassSecurityTrustResourceUrl(url);
72096      this.isLoading = false;
72097      setTimeout(() => {
72098        this.closeButtonRef?.nativeElement?.focus();
72099      }, 50);
72100    } catch (error) {
72101      this.handleError(`Errore durante il caricamento dell'URL: ${error}`);
72102    }
72103  }
72104  closeContent() {
72105    this.safeUrl = null;
72106    this.currentUrl = null;
72107    this.contentTitle = null;
72108    this.contentType = null;
72109    setTimeout(() => {
72110      this._previousFocusElement?.focus();
72111      this._previousFocusElement = null;
72112    }, 0);
72113  }
72114  onBackgroundClick(event2) {
72115    if (event2.target === event2.currentTarget) {
72116      this.closeContent();
72117    }
72118  }
72119  trapFocus(event2) {
72120    const container = this.contentContainerRef?.nativeElement;
72121    if (!container)
72122      return;
72123    const focusableSelectors = 'button:not([disabled]), [href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"]), iframe';
72124    const focusableElements = Array.from(container.querySelectorAll(focusableSelectors));
72125    if (focusableElements.length === 0)
72126      return;
72127    const firstElement = focusableElements[0];
72128    const lastElement = focusableElements[focusableElements.length - 1];
72129    const activeElement = document.activeElement;
72130    if (event2.shiftKey) {
72131      if (activeElement === firstElement || !container.contains(activeElement)) {
72132        event2.preventDefault();
72133        lastElement.focus();
72134      }
72135    } else {
72136      if (activeElement === lastElement || !container.contains(activeElement)) {
72137        event2.preventDefault();
72138        firstElement.focus();
72139      }
72140    }
72141  }
72142  determineContentType(url) {
72143    if (!url)
72144      return "";
72145    const lowerUrl = url.toLowerCase();
72146    if (lowerUrl.endsWith(".pdf")) {
72147      return "application/pdf";
72148    } else if (lowerUrl.endsWith(".jpg") || lowerUrl.endsWith(".jpeg")) {
72149      return "image/jpeg";
72150    } else if (lowerUrl.endsWith(".png")) {
72151      return "image/png";
72152    } else if (lowerUrl.endsWith(".gif")) {
72153      return "image/gif";
72154    } else if (lowerUrl.endsWith(".html") || lowerUrl.endsWith(".htm")) {
72155      return "text/html";
72156    } else if (lowerUrl.endsWith(".txt")) {
72157      return "text/plain";
72158    }
72159    return "application/pdf";
72160  }
72161  extractFilenameFromUrl(url) {
72162    if (!url)
72163      return "";
72164    try {
72165      const urlObj = new URL(url);
72166      const pathname = urlObj.pathname;
72167      const segments = pathname.split("/");
72168      const filename = segments[segments.length - 1];
72169      return filename ? decodeURIComponent(filename) : "";
72170    } catch (e) {
72171      const segments = url.split("/");
72172      return segments[segments.length - 1] || "";
72173    }
72174  }
72175  handleError(message) {
72176    this.loadError = true;
72177    this.errorMessage = message;
72178    this.isLoading = false;
72179    console.error(`DoraUrlContent: ${message}`);
72180  }
72181  static {
72182    this.\u0275fac = function DoraUrlContentComponent_Factory(__ngFactoryType__) {
72183      return new (__ngFactoryType__ || _DoraUrlContentComponent)(\u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(MessageService), \u0275\u0275directiveInject(ConfigurationService), \u0275\u0275directiveInject(PublisherService), \u0275\u0275directiveInject(WidgetService), \u0275\u0275directiveInject(HttpClient), \u0275\u0275directiveInject(TranslationService), \u0275\u0275directiveInject(DomSanitizer));
72184    };
72185  }
72186  static {
72187    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraUrlContentComponent, selectors: [["dora-url-content"]], viewQuery: function DoraUrlContentComponent_Query(rf, ctx) {
72188      if (rf & 1) {
72189        \u0275\u0275viewQuery(_c05, 5);
72190        \u0275\u0275viewQuery(_c14, 5);
72191      }
72192      if (rf & 2) {
72193        let _t;
72194        \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.contentContainerRef = _t.first);
72195        \u0275\u0275queryRefresh(_t = \u0275\u0275loadQuery()) && (ctx.closeButtonRef = _t.first);
72196      }
72197    }, hostBindings: function DoraUrlContentComponent_HostBindings(rf, ctx) {
72198      if (rf & 1) {
72199        \u0275\u0275listener("keydown", function DoraUrlContentComponent_keydown_HostBindingHandler($event) {
72200          return ctx.onDocumentKeydown($event);
72201        }, false, \u0275\u0275resolveDocument);
72202      }
72203    }, standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 10, vars: 10, consts: [["contentContainer", ""], ["closeButton", ""], [1, "widget-container", 3, "click", "ngClass"], ["class", "widget-title", 4, "ngIf"], ["role", "dialog", "aria-modal", "true", "tabindex", "-1", 1, "content-container", 3, "title"], ["class", "content-header", 4, "ngIf"], ["class", "loading-container", 4, "ngIf"], ["class", "error-container", 4, "ngIf"], ["class", "pdf-container", 4, "ngIf"], ["class", "image-container", 4, "ngIf"], ["class", "iframe-container", 3, "height", 4, "ngIf"], [1, "widget-title"], [1, "content-header"], [1, "content-title", 3, "id"], ["type", "button", 1, "content-close-button", 3, "click"], [1, "loading-container"], [1, "spinner"], [1, "loading-text"], [1, "error-container"], [1, "error-icon"], [1, "error-message"], [1, "pdf-container"], ["type", "application/pdf", "frameborder", "0", "allowfullscreen", "", 1, "pdf-iframe", 3, "src"], [1, "image-container"], [1, "content-image", 3, "src", "alt"], [1, "iframe-container"], ["frameborder", "0", "allowfullscreen", "", 1, "content-iframe", 3, "src"]], template: function DoraUrlContentComponent_Template(rf, ctx) {
72204      if (rf & 1) {
72205        const _r1 = \u0275\u0275getCurrentView();
72206        \u0275\u0275elementStart(0, "div", 2);
72207        \u0275\u0275listener("click", function DoraUrlContentComponent_Template_div_click_0_listener($event) {
72208          \u0275\u0275restoreView(_r1);
72209          return \u0275\u0275resetView(ctx.onBackgroundClick($event));
72210        });
72211        \u0275\u0275template(1, DoraUrlContentComponent_div_1_Template, 2, 1, "div", 3);
72212        \u0275\u0275elementStart(2, "div", 4, 0);
72213        \u0275\u0275template(4, DoraUrlContentComponent_div_4_Template, 6, 3, "div", 5)(5, DoraUrlContentComponent_div_5_Template, 5, 3, "div", 6)(6, DoraUrlContentComponent_div_6_Template, 6, 3, "div", 7)(7, DoraUrlContentComponent_div_7_Template, 4, 4, "div", 8)(8, DoraUrlContentComponent_div_8_Template, 2, 2, "div", 9)(9, DoraUrlContentComponent_div_9_Template, 4, 6, "div", 10);
72214        \u0275\u0275elementEnd()();
72215      }
72216      if (rf & 2) {
72217        \u0275\u0275property("ngClass", ctx.hasContent ? "content-present" : "content-not-present");
72218        \u0275\u0275advance();
72219        \u0275\u0275property("ngIf", ctx.widgetTitleEnabled && ctx.widgetTitle);
72220        \u0275\u0275advance();
72221        \u0275\u0275property("title", ctx.translationService.translateWithPlaceHolder("document_title_preview_" + ctx.documentType, ctx.documentName));
72222        \u0275\u0275attribute("aria-labelledby", "url-content-title-" + ctx.progressive);
72223        \u0275\u0275advance(2);
72224        \u0275\u0275property("ngIf", ctx.contentTitle);
72225        \u0275\u0275advance();
72226        \u0275\u0275property("ngIf", ctx.isLoading);
72227        \u0275\u0275advance();
72228        \u0275\u0275property("ngIf", ctx.loadError);
72229        \u0275\u0275advance();
72230        \u0275\u0275property("ngIf", !ctx.isLoading && !ctx.loadError && ctx.contentType === "application/pdf" && ctx.safeUrl);
72231        \u0275\u0275advance();
72232        \u0275\u0275property("ngIf", !ctx.isLoading && !ctx.loadError && ctx.contentType && ctx.contentType.startsWith("image/") && ctx.safeUrl);
72233        \u0275\u0275advance();
72234        \u0275\u0275property("ngIf", !ctx.isLoading && !ctx.loadError && ctx.contentType !== "application/pdf" && ctx.contentType && !ctx.contentType.startsWith("image/") && ctx.safeUrl);
72235      }
72236    }, dependencies: [NgClass, NgIf, TranslatePipe], styles: ['@charset "UTF-8";\n\n\n\n.widget-container[_ngcontent-%COMP%] {\n  position: fixed;\n  top: 0;\n  left: 0;\n  width: 100%;\n  height: 100%;\n  z-index: 9999;\n  background-color: rgba(0, 0, 0, 0.5);\n}\n.widget-container.content-not-present[_ngcontent-%COMP%] {\n  display: none;\n}\n.widget-container[_ngcontent-%COMP%]   .content-container[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  box-sizing: border-box;\n  position: fixed;\n  top: 0;\n  background-color: #fff;\n  padding: 20px;\n  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);\n  overflow: hidden;\n  right: 0;\n  width: 50%;\n  height: 100%;\n}\n.widget-container[_ngcontent-%COMP%]   .content-container[_ngcontent-%COMP%]   .content-header[_ngcontent-%COMP%] {\n  display: flex;\n  justify-content: space-between;\n  align-items: center;\n  margin-bottom: 15px;\n}\n.widget-container[_ngcontent-%COMP%]   .content-container[_ngcontent-%COMP%]   .content-header[_ngcontent-%COMP%]   .content-title[_ngcontent-%COMP%] {\n  font-weight: bold;\n  font-size: 18px;\n  margin-right: 15px;\n  flex: 1;\n}\n.widget-container[_ngcontent-%COMP%]   .content-container[_ngcontent-%COMP%]   .content-header[_ngcontent-%COMP%]   .content-close-button[_ngcontent-%COMP%] {\n  cursor: pointer;\n  font-size: 20px;\n  width: 30px;\n  height: 30px;\n  display: flex;\n  align-items: center;\n  justify-content: center;\n  border-radius: 50%;\n  border: none;\n  background: transparent;\n  transition: background-color 0.2s;\n  flex-shrink: 0;\n}\n.widget-container[_ngcontent-%COMP%]   .content-container[_ngcontent-%COMP%]   .content-header[_ngcontent-%COMP%]   .content-close-button[_ngcontent-%COMP%]:hover {\n  background-color: rgba(0, 0, 0, 0.1);\n}\n.widget-container[_ngcontent-%COMP%]   .content-container[_ngcontent-%COMP%]   .content-header[_ngcontent-%COMP%]   .content-close-button[_ngcontent-%COMP%]:focus-visible {\n  outline: 2px solid #0066cc;\n  outline-offset: 2px;\n}\n.widget-title[_ngcontent-%COMP%] {\n  font-size: 1.2em;\n  font-weight: bold;\n  margin-bottom: 10px;\n  padding: 4px 0;\n}\n.content-title[_ngcontent-%COMP%] {\n  font-size: 1.1em;\n  font-weight: 500;\n  color: #333;\n  margin-bottom: 12px;\n  padding-bottom: 8px;\n  border-bottom: 1px solid #eee;\n  white-space: nowrap;\n  overflow: hidden;\n  text-overflow: ellipsis;\n}\n.loading-container[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n  align-items: center;\n  height: 200px;\n}\n.loading-container[_ngcontent-%COMP%]   .spinner[_ngcontent-%COMP%] {\n  width: 40px;\n  height: 40px;\n  border: 4px solid #f3f3f3;
72236\n  border-top: 4px solid #3498db;\n  border-radius: 50%;\n  animation: _ngcontent-%COMP%_spin 1s linear infinite;\n}\n.loading-container[_ngcontent-%COMP%]   .loading-text[_ngcontent-%COMP%] {\n  margin-top: 16px;\n  color: #666;\n}\n.error-container[_ngcontent-%COMP%] {\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n  align-items: center;\n  padding: 24px;\n  background-color: #fff9f9;\n  border: 1px solid #ffdddd;\n  border-radius: 4px;\n}\n.error-container[_ngcontent-%COMP%]   .error-icon[_ngcontent-%COMP%] {\n  font-size: 32px;\n  margin-bottom: 12px;\n}\n.error-container[_ngcontent-%COMP%]   .error-message[_ngcontent-%COMP%] {\n  color: #d32f2f;\n  text-align: center;\n}\n.pdf-container[_ngcontent-%COMP%] {\n  height: 100%;\n}\n.pdf-container[_ngcontent-%COMP%], \n.iframe-container[_ngcontent-%COMP%] {\n  flex: 1;\n  width: 100%;\n  min-height: 200px;\n  overflow: hidden;\n  border-radius: 4px;\n  border: 1px solid #ddd;\n}\n.pdf-container[_ngcontent-%COMP%]   .pdf-iframe[_ngcontent-%COMP%], \n.pdf-container[_ngcontent-%COMP%]   .content-iframe[_ngcontent-%COMP%], \n.iframe-container[_ngcontent-%COMP%]   .pdf-iframe[_ngcontent-%COMP%], \n.iframe-container[_ngcontent-%COMP%]   .content-iframe[_ngcontent-%COMP%] {\n  width: 100%;\n  height: 100%;\n}\n.image-container[_ngcontent-%COMP%] {\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  margin: 12px 0;\n}\n.image-container[_ngcontent-%COMP%]   .content-image[_ngcontent-%COMP%] {\n  max-width: 100%;\n  max-height: 80vh;\n  object-fit: contain;\n}\n.source-link[_ngcontent-%COMP%] {\n  margin-top: 12px;\n  text-align: right;\n}\n.source-link[_ngcontent-%COMP%]   a[_ngcontent-%COMP%] {\n  color: #0066cc;\n  text-decoration: none;\n  display: inline-flex;\n  align-items: center;\n}\n.source-link[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover {\n  text-decoration: underline;\n}\n.source-link[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]::after {\n  content: "\\2197";\n  margin-left: 4px;\n  font-size: 0.9em;\n}\n@keyframes _ngcontent-%COMP%_spin {\n  0% {\n    transform: rotate(0deg);\n  }\n  100% {\n    transform: rotate(360deg);\n  }\n}'] });
72237  }
72238};
72239__decorate([
72240  DoraPropertyDOC("Titolo del widget", ATTRIBUTE_TYPE.STRING, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
72241  DoraProperty,
72242  __metadata("design:type", String)
72243], DoraUrlContentComponent.prototype, "widgetTitle", void 0);
72244__decorate([
72245  DoraPropertyDOC("Mostra titolo widget", ATTRIBUTE_TYPE.BOOLEAN, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
72246  DoraProperty,
72247  __metadata("design:type", Boolean)
72248], DoraUrlContentComponent.prototype, "widgetTitleEnabled", void 0);
72249__decorate([
72250  DoraPropertyDOC("Altezza del visualizzatore (in pixel)", ATTRIBUTE_TYPE.INTEGER, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE, true),
72251  DoraProperty,
72252  __metadata("design:type", Number)
72253], DoraUrlContentComponent.prototype, "viewerHeight", void 0);
72254(() => {
72255  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraUrlContentComponent, { className: "DoraUrlContentComponent", filePath: "src/app/dorawidget/dora-url-content/dora-url-content.component.ts", lineNumber: 24 });
72256})();
72257
72258// src/app/DoraWidget/dora-carousel/data/carousel-data.ts
72259var CarouselData = class {
72260  constructor(htmlContent = "", title = "", cssClass = "") {
72261    this.htmlContent = "";
72262    this.title = "";
72263    this.cssClass = "";
72264    this.htmlContent = htmlContent;
72265    this.title = title;
72266    this.cssClass = cssClass;
72267  }
72268};
72269__decorate([
72270  DoraProperty,
72271  __metadata("design:type", String)
72272], CarouselData.prototype, "htmlContent", void 0);
72273__decorate([
72274  DoraProperty,
72275  __metadata("design:type", String)
72276], CarouselData.prototype, "title", void 0);
72277__decorate([
72278  DoraProperty,
72279  __metadata("design:type", String)
72280], CarouselData.prototype, "cssClass", void 0);
72281
vendor: 2,670 bytes, lines 72282-72431
72282// node_modules/swiper/shared/ssr-window.esm.mjs
72283function isObject4(obj) {
72284  return obj !== null && typeof obj === "object" && "constructor" in obj && obj.constructor === Object;
72285}
72286function extend(target, src) {
72287  if (target === void 0) {
72288    target = {};
72289  }
72290  if (src === void 0) {
72291    src = {};
72292  }
72293  const noExtend = ["__proto__", "constructor", "prototype"];
72294  Object.keys(src).filter((key) => noExtend.indexOf(key) < 0).forEach((key) => {
72295    if (typeof target[key] === "undefined") target[key] = src[key];
72296    else if (isObject4(src[key]) && isObject4(target[key]) && Object.keys(src[key]).length > 0) {
72297      extend(target[key], src[key]);
72298    }
72299  });
72300}
72301var ssrDocument = {
72302  body: {},
72303  addEventListener() {
72304  },
72305  removeEventListener() {
72306  },
72307  activeElement: {
72308    blur() {
72309    },
72310    nodeName: ""
72311  },
72312  querySelector() {
72313    return null;
72314  },
72315  querySelectorAll() {
72316    return [];
72317  },
72318  getElementById() {
72319    return null;
72320  },
72321  createEvent() {
72322    return {
72323      initEvent() {
72324      }
72325    };
72326  },
72327  createElement() {
72328    return {
72329      children: [],
72330      childNodes: [],
72331      style: {},
72332      setAttribute() {
72333      },
72334      getElementsByTagName() {
72335        return [];
72336      }
72337    };
72338  },
72339  createElementNS() {
72340    return {};
72341  },
72342  importNode() {
72343    return null;
72344  },
72345  location: {
72346    hash: "",
72347    host: "",
72348    hostname: "",
72349    href: "",
72350    origin: "",
72351    pathname: "",
72352    protocol: "",
72353    search: ""
72354  }
72355};
72356function getDocument() {
72357  const doc = typeof document !== "undefined" ? document : {};
72358  extend(doc, ssrDocument);
72359  return doc;
72360}
72361var ssrWindow = {
72362  document: ssrDocument,
72363  navigator: {
72364    userAgent: ""
72365  },
72366  location: {
72367    hash: "",
72368    host: "",
72369    hostname: "",
72370    href: "",
72371    origin: "",
72372    pathname: "",
72373    protocol: "",
72374    search: ""
72375  },
72376  history: {
72377    replaceState() {
72378    },
72379    pushState() {
72380    },
72381    go() {
72382    },
72383    back() {
72384    }
72385  },
72386  CustomEvent: function CustomEvent2() {
72387    return this;
72388  },
72389  addEventListener() {
72390  },
72391  removeEventListener() {
72392  },
72393  getComputedStyle() {
72394    return {
72395      getPropertyValue() {
72396        return "";
72397      }
72398    };
72399  },
72400  Image() {
72401  },
72402  Date() {
72403  },
72404  screen: {},
72405  setTimeout() {
72406  },
72407  clearTimeout() {
72408  },
72409  matchMedia() {
72410    return {};
72411  },
72412  requestAnimationFrame(callback) {
72413    if (typeof setTimeout === "undefined") {
72414      callback();
72415      return null;
72416    }
72417    return setTimeout(callback, 0);
72418  },
72419  cancelAnimationFrame(id) {
72420    if (typeof setTimeout === "undefined") {
72421      return;
72422    }
72423    clearTimeout(id);
72424  }
72425};
72426function getWindow() {
72427  const win = typeof window !== "undefined" ? window : {};
72428  extend(win, ssrWindow);
72429  return win;
72430}
72431
vendor: 10,403 bytes, lines 72432-72757
72432// node_modules/swiper/shared/utils.mjs
72433function classesToTokens(classes2) {
72434  if (classes2 === void 0) {
72435    classes2 = "";
72436  }
72437  return classes2.trim().split(" ").filter((c) => !!c.trim());
72438}
72439function deleteProps(obj) {
72440  const object = obj;
72441  Object.keys(object).forEach((key) => {
72442    try {
72443      object[key] = null;
72444    } catch (e) {
72445    }
72446    try {
72447      delete object[key];
72448    } catch (e) {
72449    }
72450  });
72451}
72452function nextTick(callback, delay) {
72453  if (delay === void 0) {
72454    delay = 0;
72455  }
72456  return setTimeout(callback, delay);
72457}
72458function now() {
72459  return Date.now();
72460}
72461function getComputedStyle2(el) {
72462  const window2 = getWindow();
72463  let style;
72464  if (window2.getComputedStyle) {
72465    style = window2.getComputedStyle(el, null);
72466  }
72467  if (!style && el.currentStyle) {
72468    style = el.currentStyle;
72469  }
72470  if (!style) {
72471    style = el.style;
72472  }
72473  return style;
72474}
72475function getTranslate(el, axis) {
72476  if (axis === void 0) {
72477    axis = "x";
72478  }
72479  const window2 = getWindow();
72480  let matrix;
72481  let curTransform;
72482  let transformMatrix;
72483  const curStyle = getComputedStyle2(el);
72484  if (window2.WebKitCSSMatrix) {
72485    curTransform = curStyle.transform || curStyle.webkitTransform;
72486    if (curTransform.split(",").length > 6) {
72487      curTransform = curTransform.split(", ").map((a) => a.replace(",", ".")).join(", ");
72488    }
72489    transformMatrix = new window2.WebKitCSSMatrix(curTransform === "none" ? "" : curTransform);
72490  } else {
72491    transformMatrix = curStyle.MozTransform || curStyle.OTransform || curStyle.MsTransform || curStyle.msTransform || curStyle.transform || curStyle.getPropertyValue("transform").replace("translate(", "matrix(1, 0, 0, 1,");
72492    matrix = transformMatrix.toString().split(",");
72493  }
72494  if (axis === "x") {
72495    if (window2.WebKitCSSMatrix) curTransform = transformMatrix.m41;
72496    else if (matrix.length === 16) curTransform = parseFloat(matrix[12]);
72497    else curTransform = parseFloat(matrix[4]);
72498  }
72499  if (axis === "y") {
72500    if (window2.WebKitCSSMatrix) curTransform = transformMatrix.m42;
72501    else if (matrix.length === 16) curTransform = parseFloat(matrix[13]);
72502    else curTransform = parseFloat(matrix[5]);
72503  }
72504  return curTransform || 0;
72505}
72506function isObject5(o) {
72507  return typeof o === "object" && o !== null && o.constructor && Object.prototype.toString.call(o).slice(8, -1) === "Object";
72508}
72509function isNode(node) {
72510  if (typeof window !== "undefined" && typeof window.HTMLElement !== "undefined") {
72511    return node instanceof HTMLElement;
72512  }
72513  return node && (node.nodeType === 1 || node.nodeType === 11);
72514}
72515function extend2() {
72516  const to = Object(arguments.length <= 0 ? void 0 : arguments[0]);
72517  const noExtend = ["__proto__", "constructor", "prototype"];
72518  for (let i = 1; i < arguments.length; i += 1) {
72519    const nextSource = i < 0 || arguments.length <= i ? void 0 : arguments[i];
72520    if (nextSource !== void 0 && nextSource !== null && !isNode(nextSource)) {
72521      const keysArray = Object.keys(Object(nextSource)).filter((key) => noExtend.indexOf(key) < 0);
72522      for (let nextIndex = 0, len = keysArray.length; nextIndex < len; nextIndex += 1) {
72523        const nextKey = keysArray[nextIndex];
72524        const desc = Object.getOwnPropertyDescriptor(nextSource, nextKey);
72525        if (desc !== void 0 && desc.enumerable) {
72526          if (isObject5(to[nextKey]) && isObject5(nextSource[nextKey])) {
72527            if (nextSource[nextKey].__swiper__) {
72528              to[nextKey] = nextSource[nextKey];
72529            } else {
72530              extend2(to[nextKey], nextSource[nextKey]);
72531            }
72532          } else if (!isObject5(to[nextKey]) && isObject5(nextSource[nextKey])) {
72533            to[nextKey] = {};
72534            if (nextSource[nextKey].__swiper__) {
72535              to[nextKey] = nextSource[nextKey];
72536            } else {
72537              extend2(to[nextKey], nextSource[nextKey]);
72538            }
72539          } else {
72540            to[nextKey] = nextSource[nextKey];
72541          }
72542        }
72543      }
72544    }
72545  }
72546  return to;
72547}
72548function setCSSProperty(el, varName, varValue) {
72549  el.style.setProperty(varName, varValue);
72550}
72551function animateCSSModeScroll(_ref) {
72552  let {
72553    swiper,
72554    targetPosition,
72555    side
72556  } = _ref;
72557  const window2 = getWindow();
72558  const startPosition = -swiper.translate;
72559  let startTime = null;
72560  let time;
72561  const duration = swiper.params.speed;
72562  swiper.wrapperEl.style.scrollSnapType = "none";
72563  window2.cancelAnimationFrame(swiper.cssModeFrameID);
72564  const dir = targetPosition > startPosition ? "next" : "prev";
72565  const isOutOfBound = (current, target) => {
72566    return dir === "next" && current >= target || dir === "prev" && current <= target;
72567  };
72568  const animate = () => {
72569    time = (/* @__PURE__ */ new Date()).getTime();
72570    if (startTime === null) {
72571      startTime = time;
72572    }
72573    const progress = Math.max(Math.min((time - startTime) / duration, 1), 0);
72574    const easeProgress = 0.5 - Math.cos(progress * Math.PI) / 2;
72575    let currentPosition = startPosition + easeProgress * (targetPosition - startPosition);
72576    if (isOutOfBound(currentPosition, targetPosition)) {
72577      currentPosition = targetPosition;
72578    }
72579    swiper.wrapperEl.scrollTo({
72580      [side]: currentPosition
72581    });
72582    if (isOutOfBound(currentPosition, targetPosition)) {
72583      swiper.wrapperEl.style.overflow = "hidden";
72584      swiper.wrapperEl.style.scrollSnapType = "";
72585      setTimeout(() => {
72586        swiper.wrapperEl.style.overflow = "";
72587        swiper.wrapperEl.scrollTo({
72588          [side]: currentPosition
72589        });
72590      });
72591      window2.cancelAnimationFrame(swiper.cssModeFrameID);
72592      return;
72593    }
72594    swiper.cssModeFrameID = window2.requestAnimationFrame(animate);
72595  };
72596  animate();
72597}
72598function getSlideTransformEl(slideEl) {
72599  return slideEl.querySelector(".swiper-slide-transform") || slideEl.shadowRoot && slideEl.shadowRoot.querySelector(".swiper-slide-transform") || slideEl;
72600}
72601function elementChildren(element, selector) {
72602  if (selector === void 0) {
72603    selector = "";
72604  }
72605  const window2 = getWindow();
72606  const children = [...element.children];
72607  if (window2.HTMLSlotElement && element instanceof HTMLSlotElement) {
72608    children.push(...element.assignedElements());
72609  }
72610  if (!selector) {
72611    return children;
72612  }
72613  return children.filter((el) => el.matches(selector));
72614}
72615function elementIsChildOfSlot(el, slot) {
72616  const elementsQueue = [slot];
72617  while (elementsQueue.length > 0) {
72618    const elementToCheck = elementsQueue.shift();
72619    if (el === elementToCheck) {
72620      return true;
72621    }
72622    elementsQueue.push(...elementToCheck.children, ...elementToCheck.shadowRoot ? elementToCheck.shadowRoot.children : [], ...elementToCheck.assignedElements ? elementToCheck.assignedElements() : []);
72623  }
72624}
72625function elementIsChildOf(el, parent) {
72626  const window2 = getWindow();
72627  let isChild = parent.contains(el);
72628  if (!isChild && window2.HTMLSlotElement && parent instanceof HTMLSlotElement) {
72629    const children = [...parent.assignedElements()];
72630    isChild = children.includes(el);
72631    if (!isChild) {
72632      isChild = elementIsChildOfSlot(el, parent);
72633    }
72634  }
72635  return isChild;
72636}
72637function showWarning(text2) {
72638  try {
72639    console.warn(text2);
72640    return;
72641  } catch (err) {
72642  }
72643}
72644function createElement(tag2, classes2) {
72645  if (classes2 === void 0) {
72646    classes2 = [];
72647  }
72648  const el = document.createElement(tag2);
72649  el.classList.add(...Array.isArray(classes2) ? classes2 : classesToTokens(classes2));
72650  return el;
72651}
72652function elementOffset(el) {
72653  const window2 = getWindow();
72654  const document2 = getDocument();
72655  const box = el.getBoundingClientRect();
72656  const body = document2.body;
72657  const clientTop = el.clientTop || body.clientTop || 0;
72658  const clientLeft = el.clientLeft || body.clientLeft || 0;
72659  const scrollTop = el === window2 ? window2.scrollY : el.scrollTop;
72660  const scrollLeft = el === window2 ? window2.scrollX : el.scrollLeft;
72661  return {
72662    top: box.top + scrollTop - clientTop,
72663    left: box.left + scrollLeft - clientLeft
72664  };
72665}
72666function elementPrevAll(el, selector) {
72667  const prevEls = [];
72668  while (el.previousElementSibling) {
72669    const prev = el.previousElementSibling;
72670    if (selector) {
72671      if (prev.matches(selector)) prevEls.push(prev);
72672    } else prevEls.push(prev);
72673    el = prev;
72674  }
72675  return prevEls;
72676}
72677function elementNextAll(el, selector) {
72678  const nextEls = [];
72679  while (el.nextElementSibling) {
72680    const next = el.nextElementSibling;
72681    if (selector) {
72682      if (next.matches(selector)) nextEls.push(next);
72683    } else nextEls.push(next);
72684    el = next;
72685  }
72686  return nextEls;
72687}
72688function elementStyle(el, prop) {
72689  const window2 = getWindow();
72690  return window2.getComputedStyle(el, null).getPropertyValue(prop);
72691}
72692function elementIndex(el) {
72693  let child = el;
72694  let i;
72695  if (child) {
72696    i = 0;
72697    while ((child = child.previousSibling) !== null) {
72698      if (child.nodeType === 1) i += 1;
72699    }
72700    return i;
72701  }
72702  return void 0;
72703}
72704function elementParents(el, selector) {
72705  const parents = [];
72706  let parent = el.parentElement;
72707  while (parent) {
72708    if (selector) {
72709      if (parent.matches(selector)) parents.push(parent);
72710    } else {
72711      parents.push(parent);
72712    }
72713    parent = parent.parentElement;
72714  }
72715  return parents;
72716}
72717function elementTransitionEnd(el, callback) {
72718  function fireCallBack(e) {
72719    if (e.target !== el) return;
72720    callback.call(el, e);
72721    el.removeEventListener("transitionend", fireCallBack);
72722  }
72723  if (callback) {
72724    el.addEventListener("transitionend", fireCallBack);
72725  }
72726}
72727function elementOuterSize(el, size, includeMargins) {
72728  const window2 = getWindow();
72729  if (includeMargins) {
72730    return el[size === "width" ? "offsetWidth" : "offsetHeight"] + parseFloat(window2.getComputedStyle(el, null).getPropertyValue(size === "width" ? "margin-right" : "margin-top")) + parseFloat(window2.getComputedStyle(el, null).getPropertyValue(size === "width" ? "margin-left" : "margin-bottom"));
72731  }
72732  return el.offsetWidth;
72733}
72734function makeElementsArray(el) {
72735  return (Array.isArray(el) ? el : [el]).filter((e) => !!e);
72736}
72737function getRotateFix(swiper) {
72738  return (v) => {
72739    if (Math.abs(v) > 0 && swiper.browser && swiper.browser.need3dFix && Math.abs(v) % 90 === 0) {
72740      return v + 1e-3;
72741    }
72742    return v;
72743  };
72744}
72745function setInnerHTML(el, html2) {
72746  if (html2 === void 0) {
72747    html2 = "";
72748  }
72749  if (typeof trustedTypes !== "undefined") {
72750    el.innerHTML = trustedTypes.createPolicy("html", {
72751      createHTML: (s) => s
72752    }).createHTML(html2);
72753  } else {
72754    el.innerHTML = html2;
72755  }
72756}
72757
vendor: 128,072 bytes, lines 72758-76470
72758// node_modules/swiper/shared/swiper-core.mjs
72759var support;
72760function calcSupport() {
72761  const window2 = getWindow();
72762  const document2 = getDocument();
72763  return {
72764    smoothScroll: document2.documentElement && document2.documentElement.style && "scrollBehavior" in document2.documentElement.style,
72765    touch: !!("ontouchstart" in window2 || window2.DocumentTouch && document2 instanceof window2.DocumentTouch)
72766  };
72767}
72768function getSupport() {
72769  if (!support) {
72770    support = calcSupport();
72771  }
72772  return support;
72773}
72774var deviceCached;
72775function calcDevice(_temp) {
72776  let {
72777    userAgent
72778  } = _temp === void 0 ? {} : _temp;
72779  const support2 = getSupport();
72780  const window2 = getWindow();
72781  const platform = window2.navigator.platform;
72782  const ua = userAgent || window2.navigator.userAgent;
72783  const device = {
72784    ios: false,
72785    android: false
72786  };
72787  const screenWidth = window2.screen.width;
72788  const screenHeight = window2.screen.height;
72789  const android = ua.match(/(Android);?[\s\/]+([\d.]+)?/);
72790  let ipad = ua.match(/(iPad).*OS\s([\d_]+)/);
72791  const ipod = ua.match(/(iPod)(.*OS\s([\d_]+))?/);
72792  const iphone = !ipad && ua.match(/(iPhone\sOS|iOS)\s([\d_]+)/);
72793  const windows = platform === "Win32";
72794  let macos = platform === "MacIntel";
72795  const iPadScreens = ["1024x1366", "1366x1024", "834x1194", "1194x834", "834x1112", "1112x834", "768x1024", "1024x768", "820x1180", "1180x820", "810x1080", "1080x810"];
72796  if (!ipad && macos && support2.touch && iPadScreens.indexOf(`${screenWidth}x${screenHeight}`) >= 0) {
72797    ipad = ua.match(/(Version)\/([\d.]+)/);
72798    if (!ipad) ipad = [0, 1, "13_0_0"];
72799    macos = false;
72800  }
72801  if (android && !windows) {
72802    device.os = "android";
72803    device.android = true;
72804  }
72805  if (ipad || iphone || ipod) {
72806    device.os = "ios";
72807    device.ios = true;
72808  }
72809  return device;
72810}
72811function getDevice(overrides) {
72812  if (overrides === void 0) {
72813    overrides = {};
72814  }
72815  if (!deviceCached) {
72816    deviceCached = calcDevice(overrides);
72817  }
72818  return deviceCached;
72819}
72820var browser;
72821function calcBrowser() {
72822  const window2 = getWindow();
72823  const device = getDevice();
72824  let needPerspectiveFix = false;
72825  function isSafari() {
72826    const ua = window2.navigator.userAgent.toLowerCase();
72827    return ua.indexOf("safari") >= 0 && ua.indexOf("chrome") < 0 && ua.indexOf("android") < 0;
72828  }
72829  if (isSafari()) {
72830    const ua = String(window2.navigator.userAgent);
72831    if (ua.includes("Version/")) {
72832      const [major, minor] = ua.split("Version/")[1].split(" ")[0].split(".").map((num) => Number(num));
72833      needPerspectiveFix = major < 16 || major === 16 && minor < 2;
72834    }
72835  }
72836  const isWebView = /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(window2.navigator.userAgent);
72837  const isSafariBrowser = isSafari();
72838  const need3dFix = isSafariBrowser || isWebView && device.ios;
72839  return {
72840    isSafari: needPerspectiveFix || isSafariBrowser,
72841    needPerspectiveFix,
72842    need3dFix,
72843    isWebView
72844  };
72845}
72846function getBrowser() {
72847  if (!browser) {
72848    browser = calcBrowser();
72849  }
72850  return browser;
72851}
72852function Resize(_ref) {
72853  let {
72854    swiper,
72855    on,
72856    emit
72857  } = _ref;
72858  const window2 = getWindow();
72859  let observer = null;
72860  let animationFrame = null;
72861  const resizeHandler = () => {
72862    if (!swiper || swiper.destroyed || !swiper.initialized) return;
72863    emit("beforeResize");
72864    emit("resize");
72865  };
72866  const createObserver = () => {
72867    if (!swiper || swiper.destroyed || !swiper.initialized) return;
72868    observer = new ResizeObserver((entries) => {
72869      animationFrame = window2.requestAnimationFrame(() => {
72870        const {
72871          width,
72872          height
72873        } = swiper;
72874        let newWidth = width;
72875        let newHeight = height;
72876        entries.forEach((_ref2) => {
72877          let {
72878            contentBoxSize,
72879            contentRect,
72880            target
72881          } = _ref2;
72882          if (target && target !== swiper.el) return;
72883          newWidth = contentRect ? contentRect.width : (contentBoxSize[0] || contentBoxSize).inlineSize;
72884          newHeight = contentRect ? contentRect.height : (contentBoxSize[0] || contentBoxSize).blockSize;
72885        });
72886        if (newWidth !== width || newHeight !== height) {
72887          resizeHandler();
72888        }
72889      });
72890    });
72891    observer.observe(swiper.el);
72892  };
72893  const removeObserver = () => {
72894    if (animationFrame) {
72895      window2.cancelAnimationFrame(animationFrame);
72896    }
72897    if (observer && observer.unobserve && swiper.el) {
72898      observer.unobserve(swiper.el);
72899      observer = null;
72900    }
72901  };
72902  const orientationChangeHandler = () => {
72903    if (!swiper || swiper.destroyed || !swiper.initialized) return;
72904    emit("orientationchange");
72905  };
72906  on("init", () => {
72907    if (swiper.params.resizeObserver && typeof window2.ResizeObserver !== "undefined") {
72908      createObserver();
72909      return;
72910    }
72911    window2.addEventListener("resize", resizeHandler);
72912    window2.addEventListener("orientationchange", orientationChangeHandler);
72913  });
72914  on("destroy", () => {
72915    removeObserver();
72916    window2.removeEventListener("resize", resizeHandler);
72917    window2.removeEventListener("orientationchange", orientationChangeHandler);
72918  });
72919}
72920function Observer(_ref) {
72921  let {
72922    swiper,
72923    extendParams,
72924    on,
72925    emit
72926  } = _ref;
72927  const observers = [];
72928  const window2 = getWindow();
72929  const attach = function(target, options2) {
72930    if (options2 === void 0) {
72931      options2 = {};
72932    }
72933    const ObserverFunc = window2.MutationObserver || window2.WebkitMutationObserver;
72934    const observer = new ObserverFunc((mutations) => {
72935      if (swiper.__preventObserver__) return;
72936      if (mutations.length === 1) {
72937        emit("observerUpdate", mutations[0]);
72938        return;
72939      }
72940      const observerUpdate = function observerUpdate2() {
72941        emit("observerUpdate", mutations[0]);
72942      };
72943      if (window2.requestAnimationFrame) {
72944        window2.requestAnimationFrame(observerUpdate);
72945      } else {
72946        window2.setTimeout(observerUpdate, 0);
72947      }
72948    });
72949    observer.observe(target, {
72950      attributes: typeof options2.attributes === "undefined" ? true : options2.attributes,
72951      childList: swiper.isElement || (typeof options2.childList === "undefined" ? true : options2).childList,
72952      characterData: typeof options2.characterData === "undefined" ? true : options2.characterData
72953    });
72954    observers.push(observer);
72955  };
72956  const init = () => {
72957    if (!swiper.params.observer) return;
72958    if (swiper.params.observeParents) {
72959      const containerParents = elementParents(swiper.hostEl);
72960      for (let i = 0; i < containerParents.length; i += 1) {
72961        attach(containerParents[i]);
72962      }
72963    }
72964    attach(swiper.hostEl, {
72965      childList: swiper.params.observeSlideChildren
72966    });
72967    attach(swiper.wrapperEl, {
72968      attributes: false
72969    });
72970  };
72971  const destroy = () => {
72972    observers.forEach((observer) => {
72973      observer.disconnect();
72974    });
72975    observers.splice(0, observers.length);
72976  };
72977  extendParams({
72978    observer: false,
72979    observeParents: false,
72980    observeSlideChildren: false
72981  });
72982  on("init", init);
72983  on("destroy", destroy);
72984}
72985var eventsEmitter = {
72986  on(events2, handler, priority) {
72987    const self2 = this;
72988    if (!self2.eventsListeners || self2.destroyed) return self2;
72989    if (typeof handler !== "function") return self2;
72990    const method = priority ? "unshift" : "push";
72991    events2.split(" ").forEach((event2) => {
72992      if (!self2.eventsListeners[event2]) self2.eventsListeners[event2] = [];
72993      self2.eventsListeners[event2][method](handler);
72994    });
72995    return self2;
72996  },
72997  once(events2, handler, priority) {
72998    const self2 = this;
72999    if (!self2.eventsListeners || self2.destroyed) return self2;
73000    if (typeof handler !== "function") return self2;
73001    function onceHandler() {
73002      self2.off(events2, onceHandler);
73003      if (onceHandler.__emitterProxy) {
73004        delete onceHandler.__emitterProxy;
73005      }
73006      for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
73007        args[_key] = arguments[_key];
73008      }
73009      handler.apply(self2, args);
73010    }
73011    onceHandler.__emitterProxy = handler;
73012    return self2.on(events2, onceHandler, priority);
73013  },
73014  onAny(handler, priority) {
73015    const self2 = this;
73016    if (!self2.eventsListeners || self2.destroyed) return self2;
73017    if (typeof handler !== "function") return self2;
73018    const method = priority ? "unshift" : "push";
73019    if (self2.eventsAnyListeners.indexOf(handler) < 0) {
73020      self2.eventsAnyListeners[method](handler);
73021    }
73022    return self2;
73023  },
73024  offAny(handler) {
73025    const self2 = this;
73026    if (!self2.eventsListeners || self2.destroyed) return self2;
73027    if (!self2.eventsAnyListeners) return self2;
73028    const index = self2.eventsAnyListeners.indexOf(handler);
73029    if (index >= 0) {
73030      self2.eventsAnyListeners.splice(index, 1);
73031    }
73032    return self2;
73033  },
73034  off(events2, handler) {
73035    const self2 = this;
73036    if (!self2.eventsListeners || self2.destroyed) return self2;
73037    if (!self2.eventsListeners) return self2;
73038    events2.split(" ").forEach((event2) => {
73039      if (typeof handler === "undefined") {
73040        self2.eventsListeners[event2] = [];
73041      } else if (self2.eventsListeners[event2]) {
73042        self2.eventsListeners[event2].forEach((eventHandler, index) => {
73043          if (eventHandler === handler || eventHandler.__emitterProxy && eventHandler.__emitterProxy === handler) {
73044            self2.eventsListeners[event2].splice(index, 1);
73045          }
73046        });
73047      }
73048    });
73049    return self2;
73050  },
73051  emit() {
73052    const self2 = this;
73053    if (!self2.eventsListeners || self2.destroyed) return self2;
73054    if (!self2.eventsListeners) return self2;
73055    let events2;
73056    let data;
73057    let context;
73058    for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
73059      args[_key2] = arguments[_key2];
73060    }
73061    if (typeof args[0] === "string" || Array.isArray(args[0])) {
73062      events2 = args[0];
73063      data = args.slice(1, args.length);
73064      context = self2;
73065    } else {
73066      events2 = args[0].events;
73067      data = args[0].data;
73068      context = args[0].context || self2;
73069    }
73070    data.unshift(context);
73071    const eventsArray = Array.isArray(events2) ? events2 : events2.split(" ");
73072    eventsArray.forEach((event2) => {
73073      if (self2.eventsAnyListeners && self2.eventsAnyListeners.length) {
73074        self2.eventsAnyListeners.forEach((eventHandler) => {
73075          eventHandler.apply(context, [event2, ...data]);
73076        });
73077      }
73078      if (self2.eventsListeners && self2.eventsListeners[event2]) {
73079        self2.eventsListeners[event2].forEach((eventHandler) => {
73080          eventHandler.apply(context, data);
73081        });
73082      }
73083    });
73084    return self2;
73085  }
73086};
73087function updateSize() {
73088  const swiper = this;
73089  let width;
73090  let height;
73091  const el = swiper.el;
73092  if (typeof swiper.params.width !== "undefined" && swiper.params.width !== null) {
73093    width = swiper.params.width;
73094  } else {
73095    width = el.clientWidth;
73096  }
73097  if (typeof swiper.params.height !== "undefined" && swiper.params.height !== null) {
73098    height = swiper.params.height;
73099  } else {
73100    height = el.clientHeight;
73101  }
73102  if (width === 0 && swiper.isHorizontal() || height === 0 && swiper.isVertical()) {
73103    return;
73104  }
73105  width = width - parseInt(elementStyle(el, "padding-left") || 0, 10) - parseInt(elementStyle(el, "padding-right") || 0, 10);
73106  height = height - parseInt(elementStyle(el, "padding-top") || 0, 10) - parseInt(elementStyle(el, "padding-bottom") || 0, 10);
73107  if (Number.isNaN(width)) width = 0;
73108  if (Number.isNaN(height)) height = 0;
73109  Object.assign(swiper, {
73110    width,
73111    height,
73112    size: swiper.isHorizontal() ? width : height
73113  });
73114}
73115function updateSlides() {
73116  const swiper = this;
73117  function getDirectionPropertyValue(node, label) {
73118    return parseFloat(node.getPropertyValue(swiper.getDirectionLabel(label)) || 0);
73119  }
73120  const params = swiper.params;
73121  const {
73122    wrapperEl,
73123    slidesEl,
73124    size: swiperSize,
73125    rtlTranslate: rtl,
73126    wrongRTL
73127  } = swiper;
73128  const isVirtual = swiper.virtual && params.virtual.enabled;
73129  const previousSlidesLength = isVirtual ? swiper.virtual.slides.length : swiper.slides.length;
73130  const slides = elementChildren(slidesEl, `.${swiper.params.slideClass}, swiper-slide`);
73131  const slidesLength = isVirtual ? swiper.virtual.slides.length : slides.length;
73132  let snapGrid = [];
73133  const slidesGrid = [];
73134  const slidesSizesGrid = [];
73135  let offsetBefore = params.slidesOffsetBefore;
73136  if (typeof offsetBefore === "function") {
73137    offsetBefore = params.slidesOffsetBefore.call(swiper);
73138  }
73139  let offsetAfter = params.slidesOffsetAfter;
73140  if (typeof offsetAfter === "function") {
73141    offsetAfter = params.slidesOffsetAfter.call(swiper);
73142  }
73143  const previousSnapGridLength = swiper.snapGrid.length;
73144  const previousSlidesGridLength = swiper.slidesGrid.length;
73145  let spaceBetween = params.spaceBetween;
73146  let slidePosition = -offsetBefore;
73147  let prevSlideSize = 0;
73148  let index = 0;
73149  if (typeof swiperSize === "undefined") {
73150    return;
73151  }
73152  if (typeof spaceBetween === "string" && spaceBetween.indexOf("%") >= 0) {
73153    spaceBetween = parseFloat(spaceBetween.replace("%", "")) / 100 * swiperSize;
73154  } else if (typeof spaceBetween === "string") {
73155    spaceBetween = parseFloat(spaceBetween);
73156  }
73157  swiper.virtualSize = -spaceBetween;
73158  slides.forEach((slideEl) => {
73159    if (rtl) {
73160      slideEl.style.marginLeft = "";
73161    } else {
73162      slideEl.style.marginRight = "";
73163    }
73164    slideEl.style.marginBottom = "";
73165    slideEl.style.marginTop = "";
73166  });
73167  if (params.centeredSlides && params.cssMode) {
73168    setCSSProperty(wrapperEl, "--swiper-centered-offset-before", "");
73169    setCSSProperty(wrapperEl, "--swiper-centered-offset-after", "");
73170  }
73171  const gridEnabled = params.grid && params.grid.rows > 1 && swiper.grid;
73172  if (gridEnabled) {
73173    swiper.grid.initSlides(slides);
73174  } else if (swiper.grid) {
73175    swiper.grid.unsetSlides();
73176  }
73177  let slideSize;
73178  const shouldResetSlideSize = params.slidesPerView === "auto" && params.breakpoints && Object.keys(params.breakpoints).filter((key) => {
73179    return typeof params.breakpoints[key].slidesPerView !== "undefined";
73180  }).length > 0;
73181  for (let i = 0; i < slidesLength; i += 1) {
73182    slideSize = 0;
73183    let slide2;
73184    if (slides[i]) slide2 = slides[i];
73185    if (gridEnabled) {
73186      swiper.grid.updateSlide(i, slide2, slides);
73187    }
73188    if (slides[i] && elementStyle(slide2, "display") === "none") continue;
73189    if (params.slidesPerView === "auto") {
73190      if (shouldResetSlideSize) {
73191        slides[i].style[swiper.getDirectionLabel("width")] = ``;
73192      }
73193      const slideStyles = getComputedStyle(slide2);
73194      const currentTransform = slide2.style.transform;
73195      const currentWebKitTransform = slide2.style.webkitTransform;
73196      if (currentTransform) {
73197        slide2.style.transform = "none";
73198      }
73199      if (currentWebKitTransform) {
73200        slide2.style.webkitTransform = "none";
73201      }
73202      if (params.roundLengths) {
73203        slideSize = swiper.isHorizontal() ? elementOuterSize(slide2, "width", true) : elementOuterSize(slide2, "height", true);
73204      } else {
73205        const width = getDirectionPropertyValue(slideStyles, "width");
73206        const paddingLeft = getDirectionPropertyValue(slideStyles, "padding-left");
73207        const paddingRight = getDirectionPropertyValue(slideStyles, "padding-right");
73208        const marginLeft = getDirectionPropertyValue(slideStyles, "margin-left");
73209        const marginRight = getDirectionPropertyValue(slideStyles, "margin-right");
73210        const boxSizing = slideStyles.getPropertyValue("box-sizing");
73211        if (boxSizing && boxSizing === "border-box") {
73212          slideSize = width + marginLeft + marginRight;
73213        } else {
73214          const {
73215            clientWidth,
73216            offsetWidth
73217          } = slide2;
73218          slideSize = width + paddingLeft + paddingRight + marginLeft + marginRight + (offsetWidth - clientWidth);
73219        }
73220      }
73221      if (currentTransform) {
73222        slide2.style.transform = currentTransform;
73223      }
73224      if (currentWebKitTransform) {
73225        slide2.style.webkitTransform = currentWebKitTransform;
73226      }
73227      if (params.roundLengths) slideSize = Math.floor(slideSize);
73228    } else {
73229      slideSize = (swiperSize - (params.slidesPerView - 1) * spaceBetween) / params.slidesPerView;
73230      if (params.roundLengths) slideSize = Math.floor(slideSize);
73231      if (slides[i]) {
73232        slides[i].style[swiper.getDirectionLabel("width")] = `${slideSize}px`;
73233      }
73234    }
73235    if (slides[i]) {
73236      slides[i].swiperSlideSize = slideSize;
73237    }
73238    slidesSizesGrid.push(slideSize);
73239    if (params.centeredSlides) {
73240      slidePosition = slidePosition + slideSize / 2 + prevSlideSize / 2 + spaceBetween;
73241      if (prevSlideSize === 0 && i !== 0) slidePosition = slidePosition - swiperSize / 2 - spaceBetween;
73242      if (i === 0) slidePosition = slidePosition - swiperSize / 2 - spaceBetween;
73243      if (Math.abs(slidePosition) < 1 / 1e3) slidePosition = 0;
73244      if (params.roundLengths) slidePosition = Math.floor(slidePosition);
73245      if (index % params.slidesPerGroup === 0) snapGrid.push(slidePosition);
73246      slidesGrid.push(slidePosition);
73247    } else {
73248      if (params.roundLengths) slidePosition = Math.floor(slidePosition);
73249      if ((index - Math.min(swiper.params.slidesPerGroupSkip, index)) % swiper.params.slidesPerGroup === 0) snapGrid.push(slidePosition);
73250      slidesGrid.push(slidePosition);
73251      slidePosition = slidePosition + slideSize + spaceBetween;
73252    }
73253    swiper.virtualSize += slideSize + spaceBetween;
73254    prevSlideSize = slideSize;
73255    index += 1;
73256  }
73257  swiper.virtualSize = Math.max(swiper.virtualSize, swiperSize) + offsetAfter;
73258  if (rtl && wrongRTL && (params.effect === "slide" || params.effect === "coverflow")) {
73259    wrapperEl.style.width = `${swiper.virtualSize + spaceBetween}px`;
73260  }
73261  if (params.setWrapperSize) {
73262    wrapperEl.style[swiper.getDirectionLabel("width")] = `${swiper.virtualSize + spaceBetween}px`;
73263  }
73264  if (gridEnabled) {
73265    swiper.grid.updateWrapperSize(slideSize, snapGrid);
73266  }
73267  if (!params.centeredSlides) {
73268    const newSlidesGrid = [];
73269    for (let i = 0; i < snapGrid.length; i += 1) {
73270      let slidesGridItem = snapGrid[i];
73271      if (params.roundLengths) slidesGridItem = Math.floor(slidesGridItem);
73272      if (snapGrid[i] <= swiper.virtualSize - swiperSize) {
73273        newSlidesGrid.push(slidesGridItem);
73274      }
73275    }
73276    snapGrid = newSlidesGrid;
73277    if (Math.floor(swiper.virtualSize - swiperSize) - Math.floor(snapGrid[snapGrid.length - 1]) > 1) {
73278      snapGrid.push(swiper.virtualSize - swiperSize);
73279    }
73280  }
73281  if (isVirtual && params.loop) {
73282    const size = slidesSizesGrid[0] + spaceBetween;
73283    if (params.slidesPerGroup > 1) {
73284      const groups = Math.ceil((swiper.virtual.slidesBefore + swiper.virtual.slidesAfter) / params.slidesPerGroup);
73285      const groupSize = size * params.slidesPerGroup;
73286      for (let i = 0; i < groups; i += 1) {
73287        snapGrid.push(snapGrid[snapGrid.length - 1] + groupSize);
73288      }
73289    }
73290    for (let i = 0; i < swiper.virtual.slidesBefore + swiper.virtual.slidesAfter; i += 1) {
73291      if (params.slidesPerGroup === 1) {
73292        snapGrid.push(snapGrid[snapGrid.length - 1] + size);
73293      }
73294      slidesGrid.push(slidesGrid[slidesGrid.length - 1] + size);
73295      swiper.virtualSize += size;
73296    }
73297  }
73298  if (snapGrid.length === 0) snapGrid = [0];
73299  if (spaceBetween !== 0) {
73300    const key = swiper.isHorizontal() && rtl ? "marginLeft" : swiper.getDirectionLabel("marginRight");
73301    slides.filter((_2, slideIndex) => {
73302      if (!params.cssMode || params.loop) return true;
73303      if (slideIndex === slides.length - 1) {
73304        return false;
73305      }
73306      return true;
73307    }).forEach((slideEl) => {
73308      slideEl.style[key] = `${spaceBetween}px`;
73309    });
73310  }
73311  if (params.centeredSlides && params.centeredSlidesBounds) {
73312    let allSlidesSize = 0;
73313    slidesSizesGrid.forEach((slideSizeValue) => {
73314      allSlidesSize += slideSizeValue + (spaceBetween || 0);
73315    });
73316    allSlidesSize -= spaceBetween;
73317    const maxSnap = allSlidesSize > swiperSize ? allSlidesSize - swiperSize : 0;
73318    snapGrid = snapGrid.map((snap) => {
73319      if (snap <= 0) return -offsetBefore;
73320      if (snap > maxSnap) return maxSnap + offsetAfter;
73321      return snap;
73322    });
73323  }
73324  if (params.centerInsufficientSlides) {
73325    let allSlidesSize = 0;
73326    slidesSizesGrid.forEach((slideSizeValue) => {
73327      allSlidesSize += slideSizeValue + (spaceBetween || 0);
73328    });
73329    allSlidesSize -= spaceBetween;
73330    const offsetSize = (params.slidesOffsetBefore || 0) + (params.slidesOffsetAfter || 0);
73331    if (allSlidesSize + offsetSize < swiperSize) {
73332      const allSlidesOffset = (swiperSize - allSlidesSize - offsetSize) / 2;
73333      snapGrid.forEach((snap, snapIndex) => {
73334        snapGrid[snapIndex] = snap - allSlidesOffset;
73335      });
73336      slidesGrid.forEach((snap, snapIndex) => {
73337        slidesGrid[snapIndex] = snap + allSlidesOffset;
73338      });
73339    }
73340  }
73341  Object.assign(swiper, {
73342    slides,
73343    snapGrid,
73344    slidesGrid,
73345    slidesSizesGrid
73346  });
73347  if (params.centeredSlides && params.cssMode && !params.centeredSlidesBounds) {
73348    setCSSProperty(wrapperEl, "--swiper-centered-offset-before", `${-snapGrid[0]}px`);
73349    setCSSProperty(wrapperEl, "--swiper-centered-offset-after", `${swiper.size / 2 - slidesSizesGrid[slidesSizesGrid.length - 1] / 2}px`);
73350    const addToSnapGrid = -swiper.snapGrid[0];
73351    const addToSlidesGrid = -swiper.slidesGrid[0];
73352    swiper.snapGrid = swiper.snapGrid.map((v) => v + addToSnapGrid);
73353    swiper.slidesGrid = swiper.slidesGrid.map((v) => v + addToSlidesGrid);
73354  }
73355  if (slidesLength !== previousSlidesLength) {
73356    swiper.emit("slidesLengthChange");
73357  }
73358  if (snapGrid.length !== previousSnapGridLength) {
73359    if (swiper.params.watchOverflow) swiper.checkOverflow();
73360    swiper.emit("snapGridLengthChange");
73361  }
73362  if (slidesGrid.length !== previousSlidesGridLength) {
73363    swiper.emit("slidesGridLengthChange");
73364  }
73365  if (params.watchSlidesProgress) {
73366    swiper.updateSlidesOffset();
73367  }
73368  swiper.emit("slidesUpdated");
73369  if (!isVirtual && !params.cssMode && (params.effect === "slide" || params.effect === "fade")) {
73370    const backFaceHiddenClass = `${params.containerModifierClass}backface-hidden`;
73371    const hasClassBackfaceClassAdded = swiper.el.classList.contains(backFaceHiddenClass);
73372    if (slidesLength <= params.maxBackfaceHiddenSlides) {
73373      if (!hasClassBackfaceClassAdded) swiper.el.classList.add(backFaceHiddenClass);
73374    } else if (hasClassBackfaceClassAdded) {
73375      swiper.el.classList.remove(backFaceHiddenClass);
73376    }
73377  }
73378}
73379function updateAutoHeight(speed) {
73380  const swiper = this;
73381  const activeSlides = [];
73382  const isVirtual = swiper.virtual && swiper.params.virtual.enabled;
73383  let newHeight = 0;
73384  let i;
73385  if (typeof speed === "number") {
73386    swiper.setTransition(speed);
73387  } else if (speed === true) {
73388    swiper.setTransition(swiper.params.speed);
73389  }
73390  const getSlideByIndex = (index) => {
73391    if (isVirtual) {
73392      return swiper.slides[swiper.getSlideIndexByData(index)];
73393    }
73394    return swiper.slides[index];
73395  };
73396  if (swiper.params.slidesPerView !== "auto" && swiper.params.slidesPerView > 1) {
73397    if (swiper.params.centeredSlides) {
73398      (swiper.visibleSlides || []).forEach((slide2) => {
73399        activeSlides.push(slide2);
73400      });
73401    } else {
73402      for (i = 0; i < Math.ceil(swiper.params.slidesPerView); i += 1) {
73403        const index = swiper.activeIndex + i;
73404        if (index > swiper.slides.length && !isVirtual) break;
73405        activeSlides.push(getSlideByIndex(index));
73406      }
73407    }
73408  } else {
73409    activeSlides.push(getSlideByIndex(swiper.activeIndex));
73410  }
73411  for (i = 0; i < activeSlides.length; i += 1) {
73412    if (typeof activeSlides[i] !== "undefined") {
73413      const height = activeSlides[i].offsetHeight;
73414      newHeight = height > newHeight ? height : newHeight;
73415    }
73416  }
73417  if (newHeight || newHeight === 0) swiper.wrapperEl.style.height = `${newHeight}px`;
73418}
73419function updateSlidesOffset() {
73420  const swiper = this;
73421  const slides = swiper.slides;
73422  const minusOffset = swiper.isElement ? swiper.isHorizontal() ? swiper.wrapperEl.offsetLeft : swiper.wrapperEl.offsetTop : 0;
73423  for (let i = 0; i < slides.length; i += 1) {
73424    slides[i].swiperSlideOffset = (swiper.isHorizontal() ? slides[i].offsetLeft : slides[i].offsetTop) - minusOffset - swiper.cssOverflowAdjustment();
73425  }
73426}
73427var toggleSlideClasses$1 = (slideEl, condition, className) => {
73428  if (condition && !slideEl.classList.contains(className)) {
73429    slideEl.classList.add(className);
73430  } else if (!condition && slideEl.classList.contains(className)) {
73431    slideEl.classList.remove(className);
73432  }
73433};
73434function updateSlidesProgress(translate2) {
73435  if (translate2 === void 0) {
73436    translate2 = this && this.translate || 0;
73437  }
73438  const swiper = this;
73439  const params = swiper.params;
73440  const {
73441    slides,
73442    rtlTranslate: rtl,
73443    snapGrid
73444  } = swiper;
73445  if (slides.length === 0) return;
73446  if (typeof slides[0].swiperSlideOffset === "undefined") swiper.updateSlidesOffset();
73447  let offsetCenter = -translate2;
73448  if (rtl) offsetCenter = translate2;
73449  swiper.visibleSlidesIndexes = [];
73450  swiper.visibleSlides = [];
73451  let spaceBetween = params.spaceBetween;
73452  if (typeof spaceBetween === "string" && spaceBetween.indexOf("%") >= 0) {
73453    spaceBetween = parseFloat(spaceBetween.replace("%", "")) / 100 * swiper.size;
73454  } else if (typeof spaceBetween === "string") {
73455    spaceBetween = parseFloat(spaceBetween);
73456  }
73457  for (let i = 0; i < slides.length; i += 1) {
73458    const slide2 = slides[i];
73459    let slideOffset = slide2.swiperSlideOffset;
73460    if (params.cssMode && params.centeredSlides) {
73461      slideOffset -= slides[0].swiperSlideOffset;
73462    }
73463    const slideProgress = (offsetCenter + (params.centeredSlides ? swiper.minTranslate() : 0) - slideOffset) / (slide2.swiperSlideSize + spaceBetween);
73464    const originalSlideProgress = (offsetCenter - snapGrid[0] + (params.centeredSlides ? swiper.minTranslate() : 0) - slideOffset) / (slide2.swiperSlideSize + spaceBetween);
73465    const slideBefore = -(offsetCenter - slideOffset);
73466    const slideAfter = slideBefore + swiper.slidesSizesGrid[i];
73467    const isFullyVisible = slideBefore >= 0 && slideBefore <= swiper.size - swiper.slidesSizesGrid[i];
73468    const isVisible = slideBefore >= 0 && slideBefore < swiper.size - 1 || slideAfter > 1 && slideAfter <= swiper.size || slideBefore <= 0 && slideAfter >= swiper.size;
73469    if (isVisible) {
73470      swiper.visibleSlides.push(slide2);
73471      swiper.visibleSlidesIndexes.push(i);
73472    }
73473    toggleSlideClasses$1(slide2, isVisible, params.slideVisibleClass);
73474    toggleSlideClasses$1(slide2, isFullyVisible, params.slideFullyVisibleClass);
73475    slide2.progress = rtl ? -slideProgress : slideProgress;
73476    slide2.originalProgress = rtl ? -originalSlideProgress : originalSlideProgress;
73477  }
73478}
73479function updateProgress(translate2) {
73480  const swiper = this;
73481  if (typeof translate2 === "undefined") {
73482    const multiplier = swiper.rtlTranslate ? -1 : 1;
73483    translate2 = swiper && swiper.translate && swiper.translate * multiplier || 0;
73484  }
73485  const params = swiper.params;
73486  const translatesDiff = swiper.maxTranslate() - swiper.minTranslate();
73487  let {
73488    progress,
73489    isBeginning,
73490    isEnd,
73491    progressLoop
73492  } = swiper;
73493  const wasBeginning = isBeginning;
73494  const wasEnd = isEnd;
73495  if (translatesDiff === 0) {
73496    progress = 0;
73497    isBeginning = true;
73498    isEnd = true;
73499  } else {
73500    progress = (translate2 - swiper.minTranslate()) / translatesDiff;
73501    const isBeginningRounded = Math.abs(translate2 - swiper.minTranslate()) < 1;
73502    const isEndRounded = Math.abs(translate2 - swiper.maxTranslate()) < 1;
73503    isBeginning = isBeginningRounded || progress <= 0;
73504    isEnd = isEndRounded || progress >= 1;
73505    if (isBeginningRounded) progress = 0;
73506    if (isEndRounded) progress = 1;
73507  }
73508  if (params.loop) {
73509    const firstSlideIndex = swiper.getSlideIndexByData(0);
73510    const lastSlideIndex = swiper.getSlideIndexByData(swiper.slides.length - 1);
73511    const firstSlideTranslate = swiper.slidesGrid[firstSlideIndex];
73512    const lastSlideTranslate = swiper.slidesGrid[lastSlideIndex];
73513    const translateMax = swiper.slidesGrid[swiper.slidesGrid.length - 1];
73514    const translateAbs = Math.abs(translate2);
73515    if (translateAbs >= firstSlideTranslate) {
73516      progressLoop = (translateAbs - firstSlideTranslate) / translateMax;
73517    } else {
73518      progressLoop = (translateAbs + translateMax - lastSlideTranslate) / translateMax;
73519    }
73520    if (progressLoop > 1) progressLoop -= 1;
73521  }
73522  Object.assign(swiper, {
73523    progress,
73524    progressLoop,
73525    isBeginning,
73526    isEnd
73527  });
73528  if (params.watchSlidesProgress || params.centeredSlides && params.autoHeight) swiper.updateSlidesProgress(translate2);
73529  if (isBeginning && !wasBeginning) {
73530    swiper.emit("reachBeginning toEdge");
73531  }
73532  if (isEnd && !wasEnd) {
73533    swiper.emit("reachEnd toEdge");
73534  }
73535  if (wasBeginning && !isBeginning || wasEnd && !isEnd) {
73536    swiper.emit("fromEdge");
73537  }
73538  swiper.emit("progress", progress);
73539}
73540var toggleSlideClasses = (slideEl, condition, className) => {
73541  if (condition && !slideEl.classList.contains(className)) {
73542    slideEl.classList.add(className);
73543  } else if (!condition && slideEl.classList.contains(className)) {
73544    slideEl.classList.remove(className);
73545  }
73546};
73547function updateSlidesClasses() {
73548  const swiper = this;
73549  const {
73550    slides,
73551    params,
73552    slidesEl,
73553    activeIndex
73554  } = swiper;
73555  const isVirtual = swiper.virtual && params.virtual.enabled;
73556  const gridEnabled = swiper.grid && params.grid && params.grid.rows > 1;
73557  const getFilteredSlide = (selector) => {
73558    return elementChildren(slidesEl, `.${params.slideClass}${selector}, swiper-slide${selector}`)[0];
73559  };
73560  let activeSlide;
73561  let prevSlide;
73562  let nextSlide;
73563  if (isVirtual) {
73564    if (params.loop) {
73565      let slideIndex = activeIndex - swiper.virtual.slidesBefore;
73566      if (slideIndex < 0) slideIndex = swiper.virtual.slides.length + slideIndex;
73567      if (slideIndex >= swiper.virtual.slides.length) slideIndex -= swiper.virtual.slides.length;
73568      activeSlide = getFilteredSlide(`[data-swiper-slide-index="${slideIndex}"]`);
73569    } else {
73570      activeSlide = getFilteredSlide(`[data-swiper-slide-index="${activeIndex}"]`);
73571    }
73572  } else {
73573    if (gridEnabled) {
73574      activeSlide = slides.find((slideEl) => slideEl.column === activeIndex);
73575      nextSlide = slides.find((slideEl) => slideEl.column === activeIndex + 1);
73576      prevSlide = slides.find((slideEl) => slideEl.column === activeIndex - 1);
73577    } else {
73578      activeSlide = slides[activeIndex];
73579    }
73580  }
73581  if (activeSlide) {
73582    if (!gridEnabled) {
73583      nextSlide = elementNextAll(activeSlide, `.${params.slideClass}, swiper-slide`)[0];
73584      if (params.loop && !nextSlide) {
73585        nextSlide = slides[0];
73586      }
73587      prevSlide = elementPrevAll(activeSlide, `.${params.slideClass}, swiper-slide`)[0];
73588      if (params.loop && !prevSlide === 0) {
73589        prevSlide = slides[slides.length - 1];
73590      }
73591    }
73592  }
73593  slides.forEach((slideEl) => {
73594    toggleSlideClasses(slideEl, slideEl === activeSlide, params.slideActiveClass);
73595    toggleSlideClasses(slideEl, slideEl === nextSlide, params.slideNextClass);
73596    toggleSlideClasses(slideEl, slideEl === prevSlide, params.slidePrevClass);
73597  });
73598  swiper.emitSlidesClasses();
73599}
73600var processLazyPreloader = (swiper, imageEl) => {
73601  if (!swiper || swiper.destroyed || !swiper.params) return;
73602  const slideSelector = () => swiper.isElement ? `swiper-slide` : `.${swiper.params.slideClass}`;
73603  const slideEl = imageEl.closest(slideSelector());
73604  if (slideEl) {
73605    let lazyEl = slideEl.querySelector(`.${swiper.params.lazyPreloaderClass}`);
73606    if (!lazyEl && swiper.isElement) {
73607      if (slideEl.shadowRoot) {
73608        lazyEl = slideEl.shadowRoot.querySelector(`.${swiper.params.lazyPreloaderClass}`);
73609      } else {
73610        requestAnimationFrame(() => {
73611          if (slideEl.shadowRoot) {
73612            lazyEl = slideEl.shadowRoot.querySelector(`.${swiper.params.lazyPreloaderClass}`);
73613            if (lazyEl) lazyEl.remove();
73614          }
73615        });
73616      }
73617    }
73618    if (lazyEl) lazyEl.remove();
73619  }
73620};
73621var unlazy = (swiper, index) => {
73622  if (!swiper.slides[index]) return;
73623  const imageEl = swiper.slides[index].querySelector('[loading="lazy"]');
73624  if (imageEl) imageEl.removeAttribute("loading");
73625};
73626var preload = (swiper) => {
73627  if (!swiper || swiper.destroyed || !swiper.params) return;
73628  let amount = swiper.params.lazyPreloadPrevNext;
73629  const len = swiper.slides.length;
73630  if (!len || !amount || amount < 0) return;
73631  amount = Math.min(amount, len);
73632  const slidesPerView = swiper.params.slidesPerView === "auto" ? swiper.slidesPerViewDynamic() : Math.ceil(swiper.params.slidesPerView);
73633  const activeIndex = swiper.activeIndex;
73634  if (swiper.params.grid && swiper.params.grid.rows > 1) {
73635    const activeColumn = activeIndex;
73636    const preloadColumns = [activeColumn - amount];
73637    preloadColumns.push(...Array.from({
73638      length: amount
73639    }).map((_2, i) => {
73640      return activeColumn + slidesPerView + i;
73641    }));
73642    swiper.slides.forEach((slideEl, i) => {
73643      if (preloadColumns.includes(slideEl.column)) unlazy(swiper, i);
73644    });
73645    return;
73646  }
73647  const slideIndexLastInView = activeIndex + slidesPerView - 1;
73648  if (swiper.params.rewind || swiper.params.loop) {
73649    for (let i = activeIndex - amount; i <= slideIndexLastInView + amount; i += 1) {
73650      const realIndex = (i % len + len) % len;
73651      if (realIndex < activeIndex || realIndex > slideIndexLastInView) unlazy(swiper, realIndex);
73652    }
73653  } else {
73654    for (let i = Math.max(activeIndex - amount, 0); i <= Math.min(slideIndexLastInView + amount, len - 1); i += 1) {
73655      if (i !== activeIndex && (i > slideIndexLastInView || i < activeIndex)) {
73656        unlazy(swiper, i);
73657      }
73658    }
73659  }
73660};
73661function getActiveIndexByTranslate(swiper) {
73662  const {
73663    slidesGrid,
73664    params
73665  } = swiper;
73666  const translate2 = swiper.rtlTranslate ? swiper.translate : -swiper.translate;
73667  let activeIndex;
73668  for (let i = 0; i < slidesGrid.length; i += 1) {
73669    if (typeof slidesGrid[i + 1] !== "undefined") {
73670      if (translate2 >= slidesGrid[i] && translate2 < slidesGrid[i + 1] - (slidesGrid[i + 1] - slidesGrid[i]) / 2) {
73671        activeIndex = i;
73672      } else if (translate2 >= slidesGrid[i] && translate2 < slidesGrid[i + 1]) {
73673        activeIndex = i + 1;
73674      }
73675    } else if (translate2 >= slidesGrid[i]) {
73676      activeIndex = i;
73677    }
73678  }
73679  if (params.normalizeSlideIndex) {
73680    if (activeIndex < 0 || typeof activeIndex === "undefined") activeIndex = 0;
73681  }
73682  return activeIndex;
73683}
73684function updateActiveIndex(newActiveIndex) {
73685  const swiper = this;
73686  const translate2 = swiper.rtlTranslate ? swiper.translate : -swiper.translate;
73687  const {
73688    snapGrid,
73689    params,
73690    activeIndex: previousIndex,
73691    realIndex: previousRealIndex,
73692    snapIndex: previousSnapIndex
73693  } = swiper;
73694  let activeIndex = newActiveIndex;
73695  let snapIndex;
73696  const getVirtualRealIndex = (aIndex) => {
73697    let realIndex2 = aIndex - swiper.virtual.slidesBefore;
73698    if (realIndex2 < 0) {
73699      realIndex2 = swiper.virtual.slides.length + realIndex2;
73700    }
73701    if (realIndex2 >= swiper.virtual.slides.length) {
73702      realIndex2 -= swiper.virtual.slides.length;
73703    }
73704    return realIndex2;
73705  };
73706  if (typeof activeIndex === "undefined") {
73707    activeIndex = getActiveIndexByTranslate(swiper);
73708  }
73709  if (snapGrid.indexOf(translate2) >= 0) {
73710    snapIndex = snapGrid.indexOf(translate2);
73711  } else {
73712    const skip = Math.min(params.slidesPerGroupSkip, activeIndex);
73713    snapIndex = skip + Math.floor((activeIndex - skip) / params.slidesPerGroup);
73714  }
73715  if (snapIndex >= snapGrid.length) snapIndex = snapGrid.length - 1;
73716  if (activeIndex === previousIndex && !swiper.params.loop) {
73717    if (snapIndex !== previousSnapIndex) {
73718      swiper.snapIndex = snapIndex;
73719      swiper.emit("snapIndexChange");
73720    }
73721    return;
73722  }
73723  if (activeIndex === previousIndex && swiper.params.loop && swiper.virtual && swiper.params.virtual.enabled) {
73724    swiper.realIndex = getVirtualRealIndex(activeIndex);
73725    return;
73726  }
73727  const gridEnabled = swiper.grid && params.grid && params.grid.rows > 1;
73728  let realIndex;
73729  if (swiper.virtual && params.virtual.enabled && params.loop) {
73730    realIndex = getVirtualRealIndex(activeIndex);
73731  } else if (gridEnabled) {
73732    const firstSlideInColumn = swiper.slides.find((slideEl) => slideEl.column === activeIndex);
73733    let activeSlideIndex = parseInt(firstSlideInColumn.getAttribute("data-swiper-slide-index"), 10);
73734    if (Number.isNaN(activeSlideIndex)) {
73735      activeSlideIndex = Math.max(swiper.slides.indexOf(firstSlideInColumn), 0);
73736    }
73737    realIndex = Math.floor(activeSlideIndex / params.grid.rows);
73738  } else if (swiper.slides[activeIndex]) {
73739    const slideIndex = swiper.slides[activeIndex].getAttribute("data-swiper-slide-index");
73740    if (slideIndex) {
73741      realIndex = parseInt(slideIndex, 10);
73742    } else {
73743      realIndex = activeIndex;
73744    }
73745  } else {
73746    realIndex = activeIndex;
73747  }
73748  Object.assign(swiper, {
73749    previousSnapIndex,
73750    snapIndex,
73751    previousRealIndex,
73752    realIndex,
73753    previousIndex,
73754    activeIndex
73755  });
73756  if (swiper.initialized) {
73757    preload(swiper);
73758  }
73759  swiper.emit("activeIndexChange");
73760  swiper.emit("snapIndexChange");
73761  if (swiper.initialized || swiper.params.runCallbacksOnInit) {
73762    if (previousRealIndex !== realIndex) {
73763      swiper.emit("realIndexChange");
73764    }
73765    swiper.emit("slideChange");
73766  }
73767}
73768function updateClickedSlide(el, path2) {
73769  const swiper = this;
73770  const params = swiper.params;
73771  let slide2 = el.closest(`.${params.slideClass}, swiper-slide`);
73772  if (!slide2 && swiper.isElement && path2 && path2.length > 1 && path2.includes(el)) {
73773    [...path2.slice(path2.indexOf(el) + 1, path2.length)].forEach((pathEl) => {
73774      if (!slide2 && pathEl.matches && pathEl.matches(`.${params.slideClass}, swiper-slide`)) {
73775        slide2 = pathEl;
73776      }
73777    });
73778  }
73779  let slideFound = false;
73780  let slideIndex;
73781  if (slide2) {
73782    for (let i = 0; i < swiper.slides.length; i += 1) {
73783      if (swiper.slides[i] === slide2) {
73784        slideFound = true;
73785        slideIndex = i;
73786        break;
73787      }
73788    }
73789  }
73790  if (slide2 && slideFound) {
73791    swiper.clickedSlide = slide2;
73792    if (swiper.virtual && swiper.params.virtual.enabled) {
73793      swiper.clickedIndex = parseInt(slide2.getAttribute("data-swiper-slide-index"), 10);
73794    } else {
73795      swiper.clickedIndex = slideIndex;
73796    }
73797  } else {
73798    swiper.clickedSlide = void 0;
73799    swiper.clickedIndex = void 0;
73800    return;
73801  }
73802  if (params.slideToClickedSlide && swiper.clickedIndex !== void 0 && swiper.clickedIndex !== swiper.activeIndex) {
73803    swiper.slideToClickedSlide();
73804  }
73805}
73806var update = {
73807  updateSize,
73808  updateSlides,
73809  updateAutoHeight,
73810  updateSlidesOffset,
73811  updateSlidesProgress,
73812  updateProgress,
73813  updateSlidesClasses,
73814  updateActiveIndex,
73815  updateClickedSlide
73816};
73817function getSwiperTranslate(axis) {
73818  if (axis === void 0) {
73819    axis = this.isHorizontal() ? "x" : "y";
73820  }
73821  const swiper = this;
73822  const {
73823    params,
73824    rtlTranslate: rtl,
73825    translate: translate2,
73826    wrapperEl
73827  } = swiper;
73828  if (params.virtualTranslate) {
73829    return rtl ? -translate2 : translate2;
73830  }
73831  if (params.cssMode) {
73832    return translate2;
73833  }
73834  let currentTranslate = getTranslate(wrapperEl, axis);
73835  currentTranslate += swiper.cssOverflowAdjustment();
73836  if (rtl) currentTranslate = -currentTranslate;
73837  return currentTranslate || 0;
73838}
73839function setTranslate(translate2, byController) {
73840  const swiper = this;
73841  const {
73842    rtlTranslate: rtl,
73843    params,
73844    wrapperEl,
73845    progress
73846  } = swiper;
73847  let x = 0;
73848  let y = 0;
73849  const z = 0;
73850  if (swiper.isHorizontal()) {
73851    x = rtl ? -translate2 : translate2;
73852  } else {
73853    y = translate2;
73854  }
73855  if (params.roundLengths) {
73856    x = Math.floor(x);
73857    y = Math.floor(y);
73858  }
73859  swiper.previousTranslate = swiper.translate;
73860  swiper.translate = swiper.isHorizontal() ? x : y;
73861  if (params.cssMode) {
73862    wrapperEl[swiper.isHorizontal() ? "scrollLeft" : "scrollTop"] = swiper.isHorizontal() ? -x : -y;
73863  } else if (!params.virtualTranslate) {
73864    if (swiper.isHorizontal()) {
73865      x -= swiper.cssOverflowAdjustment();
73866    } else {
73867      y -= swiper.cssOverflowAdjustment();
73868    }
73869    wrapperEl.style.transform = `translate3d(${x}px, ${y}px, ${z}px)`;
73870  }
73871  let newProgress;
73872  const translatesDiff = swiper.maxTranslate() - swiper.minTranslate();
73873  if (translatesDiff === 0) {
73874    newProgress = 0;
73875  } else {
73876    newProgress = (translate2 - swiper.minTranslate()) / translatesDiff;
73877  }
73878  if (newProgress !== progress) {
73879    swiper.updateProgress(translate2);
73880  }
73881  swiper.emit("setTranslate", swiper.translate, byController);
73882}
73883function minTranslate() {
73884  return -this.snapGrid[0];
73885}
73886function maxTranslate() {
73887  return -this.snapGrid[this.snapGrid.length - 1];
73888}
73889function translateTo(translate2, speed, runCallbacks, translateBounds, internal) {
73890  if (translate2 === void 0) {
73891    translate2 = 0;
73892  }
73893  if (speed === void 0) {
73894    speed = this.params.speed;
73895  }
73896  if (runCallbacks === void 0) {
73897    runCallbacks = true;
73898  }
73899  if (translateBounds === void 0) {
73900    translateBounds = true;
73901  }
73902  const swiper = this;
73903  const {
73904    params,
73905    wrapperEl
73906  } = swiper;
73907  if (swiper.animating && params.preventInteractionOnTransition) {
73908    return false;
73909  }
73910  const minTranslate2 = swiper.minTranslate();
73911  const maxTranslate2 = swiper.maxTranslate();
73912  let newTranslate;
73913  if (translateBounds && translate2 > minTranslate2) newTranslate = minTranslate2;
73914  else if (translateBounds && translate2 < maxTranslate2) newTranslate = maxTranslate2;
73915  else newTranslate = translate2;
73916  swiper.updateProgress(newTranslate);
73917  if (params.cssMode) {
73918    const isH = swiper.isHorizontal();
73919    if (speed === 0) {
73920      wrapperEl[isH ? "scrollLeft" : "scrollTop"] = -newTranslate;
73921    } else {
73922      if (!swiper.support.smoothScroll) {
73923        animateCSSModeScroll({
73924          swiper,
73925          targetPosition: -newTranslate,
73926          side: isH ? "left" : "top"
73927        });
73928        return true;
73929      }
73930      wrapperEl.scrollTo({
73931        [isH ? "left" : "top"]: -newTranslate,
73932        behavior: "smooth"
73933      });
73934    }
73935    return true;
73936  }
73937  if (speed === 0) {
73938    swiper.setTransition(0);
73939    swiper.setTranslate(newTranslate);
73940    if (runCallbacks) {
73941      swiper.emit("beforeTransitionStart", speed, internal);
73942      swiper.emit("transitionEnd");
73943    }
73944  } else {
73945    swiper.setTransition(speed);
73946    swiper.setTranslate(newTranslate);
73947    if (runCallbacks) {
73948      swiper.emit("beforeTransitionStart", speed, internal);
73949      swiper.emit("transitionStart");
73950    }
73951    if (!swiper.animating) {
73952      swiper.animating = true;
73953      if (!swiper.onTranslateToWrapperTransitionEnd) {
73954        swiper.onTranslateToWrapperTransitionEnd = function transitionEnd2(e) {
73955          if (!swiper || swiper.destroyed) return;
73956          if (e.target !== this) return;
73957          swiper.wrapperEl.removeEventListener("transitionend", swiper.onTranslateToWrapperTransitionEnd);
73958          swiper.onTranslateToWrapperTransitionEnd = null;
73959          delete swiper.onTranslateToWrapperTransitionEnd;
73960          swiper.animating = false;
73961          if (runCallbacks) {
73962            swiper.emit("transitionEnd");
73963          }
73964        };
73965      }
73966      swiper.wrapperEl.addEventListener("transitionend", swiper.onTranslateToWrapperTransitionEnd);
73967    }
73968  }
73969  return true;
73970}
73971var translate = {
73972  getTranslate: getSwiperTranslate,
73973  setTranslate,
73974  minTranslate,
73975  maxTranslate,
73976  translateTo
73977};
73978function setTransition(duration, byController) {
73979  const swiper = this;
73980  if (!swiper.params.cssMode) {
73981    swiper.wrapperEl.style.transitionDuration = `${duration}ms`;
73982    swiper.wrapperEl.style.transitionDelay = duration === 0 ? `0ms` : "";
73983  }
73984  swiper.emit("setTransition", duration, byController);
73985}
73986function transitionEmit(_ref) {
73987  let {
73988    swiper,
73989    runCallbacks,
73990    direction,
73991    step
73992  } = _ref;
73993  const {
73994    activeIndex,
73995    previousIndex
73996  } = swiper;
73997  let dir = direction;
73998  if (!dir) {
73999    if (activeIndex > previousIndex) dir = "next";
74000    else if (activeIndex < previousIndex) dir = "prev";
74001    else dir = "reset";
74002  }
74003  swiper.emit(`transition${step}`);
74004  if (runCallbacks && dir === "reset") {
74005    swiper.emit(`slideResetTransition${step}`);
74006  } else if (runCallbacks && activeIndex !== previousIndex) {
74007    swiper.emit(`slideChangeTransition${step}`);
74008    if (dir === "next") {
74009      swiper.emit(`slideNextTransition${step}`);
74010    } else {
74011      swiper.emit(`slidePrevTransition${step}`);
74012    }
74013  }
74014}
74015function transitionStart(runCallbacks, direction) {
74016  if (runCallbacks === void 0) {
74017    runCallbacks = true;
74018  }
74019  const swiper = this;
74020  const {
74021    params
74022  } = swiper;
74023  if (params.cssMode) return;
74024  if (params.autoHeight) {
74025    swiper.updateAutoHeight();
74026  }
74027  transitionEmit({
74028    swiper,
74029    runCallbacks,
74030    direction,
74031    step: "Start"
74032  });
74033}
74034function transitionEnd(runCallbacks, direction) {
74035  if (runCallbacks === void 0) {
74036    runCallbacks = true;
74037  }
74038  const swiper = this;
74039  const {
74040    params
74041  } = swiper;
74042  swiper.animating = false;
74043  if (params.cssMode) return;
74044  swiper.setTransition(0);
74045  transitionEmit({
74046    swiper,
74047    runCallbacks,
74048    direction,
74049    step: "End"
74050  });
74051}
74052var transition = {
74053  setTransition,
74054  transitionStart,
74055  transitionEnd
74056};
74057function slideTo(index, speed, runCallbacks, internal, initial) {
74058  if (index === void 0) {
74059    index = 0;
74060  }
74061  if (runCallbacks === void 0) {
74062    runCallbacks = true;
74063  }
74064  if (typeof index === "string") {
74065    index = parseInt(index, 10);
74066  }
74067  const swiper = this;
74068  let slideIndex = index;
74069  if (slideIndex < 0) slideIndex = 0;
74070  const {
74071    params,
74072    snapGrid,
74073    slidesGrid,
74074    previousIndex,
74075    activeIndex,
74076    rtlTranslate: rtl,
74077    wrapperEl,
74078    enabled
74079  } = swiper;
74080  if (!enabled && !internal && !initial || swiper.destroyed || swiper.animating && params.preventInteractionOnTransition) {
74081    return false;
74082  }
74083  if (typeof speed === "undefined") {
74084    speed = swiper.params.speed;
74085  }
74086  const skip = Math.min(swiper.params.slidesPerGroupSkip, slideIndex);
74087  let snapIndex = skip + Math.floor((slideIndex - skip) / swiper.params.slidesPerGroup);
74088  if (snapIndex >= snapGrid.length) snapIndex = snapGrid.length - 1;
74089  const translate2 = -snapGrid[snapIndex];
74090  if (params.normalizeSlideIndex) {
74091    for (let i = 0; i < slidesGrid.length; i += 1) {
74092      const normalizedTranslate = -Math.floor(translate2 * 100);
74093      const normalizedGrid = Math.floor(slidesGrid[i] * 100);
74094      const normalizedGridNext = Math.floor(slidesGrid[i + 1] * 100);
74095      if (typeof slidesGrid[i + 1] !== "undefined") {
74096        if (normalizedTranslate >= normalizedGrid && normalizedTranslate < normalizedGridNext - (normalizedGridNext - normalizedGrid) / 2) {
74097          slideIndex = i;
74098        } else if (normalizedTranslate >= normalizedGrid && normalizedTranslate < normalizedGridNext) {
74099          slideIndex = i + 1;
74100        }
74101      } else if (normalizedTranslate >= normalizedGrid) {
74102        slideIndex = i;
74103      }
74104    }
74105  }
74106  if (swiper.initialized && slideIndex !== activeIndex) {
74107    if (!swiper.allowSlideNext && (rtl ? translate2 > swiper.translate && translate2 > swiper.minTranslate() : translate2 < swiper.translate && translate2 < swiper.minTranslate())) {
74108      return false;
74109    }
74110    if (!swiper.allowSlidePrev && translate2 > swiper.translate && translate2 > swiper.maxTranslate()) {
74111      if ((activeIndex || 0) !== slideIndex) {
74112        return false;
74113      }
74114    }
74115  }
74116  if (slideIndex !== (previousIndex || 0) && runCallbacks) {
74117    swiper.emit("beforeSlideChangeStart");
74118  }
74119  swiper.updateProgress(translate2);
74120  let direction;
74121  if (slideIndex > activeIndex) direction = "next";
74122  else if (slideIndex < activeIndex) direction = "prev";
74123  else direction = "reset";
74124  const isVirtual = swiper.virtual && swiper.params.virtual.enabled;
74125  const isInitialVirtual = isVirtual && initial;
74126  if (!isInitialVirtual && (rtl && -translate2 === swiper.translate || !rtl && translate2 === swiper.translate)) {
74127    swiper.updateActiveIndex(slideIndex);
74128    if (params.autoHeight) {
74129      swiper.updateAutoHeight();
74130    }
74131    swiper.updateSlidesClasses();
74132    if (params.effect !== "slide") {
74133      swiper.setTranslate(translate2);
74134    }
74135    if (direction !== "reset") {
74136      swiper.transitionStart(runCallbacks, direction);
74137      swiper.transitionEnd(runCallbacks, direction);
74138    }
74139    return false;
74140  }
74141  if (params.cssMode) {
74142    const isH = swiper.isHorizontal();
74143    const t = rtl ? translate2 : -translate2;
74144    if (speed === 0) {
74145      if (isVirtual) {
74146        swiper.wrapperEl.style.scrollSnapType = "none";
74147        swiper._immediateVirtual = true;
74148      }
74149      if (isVirtual && !swiper._cssModeVirtualInitialSet && swiper.params.initialSlide > 0) {
74150        swiper._cssModeVirtualInitialSet = true;
74151        requestAnimationFrame(() => {
74152          wrapperEl[isH ? "scrollLeft" : "scrollTop"] = t;
74153        });
74154      } else {
74155        wrapperEl[isH ? "scrollLeft" : "scrollTop"] = t;
74156      }
74157      if (isVirtual) {
74158        requestAnimationFrame(() => {
74159          swiper.wrapperEl.style.scrollSnapType = "";
74160          swiper._immediateVirtual = false;
74161        });
74162      }
74163    } else {
74164      if (!swiper.support.smoothScroll) {
74165        animateCSSModeScroll({
74166          swiper,
74167          targetPosition: t,
74168          side: isH ? "left" : "top"
74169        });
74170        return true;
74171      }
74172      wrapperEl.scrollTo({
74173        [isH ? "left" : "top"]: t,
74174        behavior: "smooth"
74175      });
74176    }
74177    return true;
74178  }
74179  const browser2 = getBrowser();
74180  const isSafari = browser2.isSafari;
74181  if (isVirtual && !initial && isSafari && swiper.isElement) {
74182    swiper.virtual.update(false, false, slideIndex);
74183  }
74184  swiper.setTransition(speed);
74185  swiper.setTranslate(translate2);
74186  swiper.updateActiveIndex(slideIndex);
74187  swiper.updateSlidesClasses();
74188  swiper.emit("beforeTransitionStart", speed, internal);
74189  swiper.transitionStart(runCallbacks, direction);
74190  if (speed === 0) {
74191    swiper.transitionEnd(runCallbacks, direction);
74192  } else if (!swiper.animating) {
74193    swiper.animating = true;
74194    if (!swiper.onSlideToWrapperTransitionEnd) {
74195      swiper.onSlideToWrapperTransitionEnd = function transitionEnd2(e) {
74196        if (!swiper || swiper.destroyed) return;
74197        if (e.target !== this) return;
74198        swiper.wrapperEl.removeEventListener("transitionend", swiper.onSlideToWrapperTransitionEnd);
74199        swiper.onSlideToWrapperTransitionEnd = null;
74200        delete swiper.onSlideToWrapperTransitionEnd;
74201        swiper.transitionEnd(runCallbacks, direction);
74202      };
74203    }
74204    swiper.wrapperEl.addEventListener("transitionend", swiper.onSlideToWrapperTransitionEnd);
74205  }
74206  return true;
74207}
74208function slideToLoop(index, speed, runCallbacks, internal) {
74209  if (index === void 0) {
74210    index = 0;
74211  }
74212  if (runCallbacks === void 0) {
74213    runCallbacks = true;
74214  }
74215  if (typeof index === "string") {
74216    const indexAsNumber = parseInt(index, 10);
74217    index = indexAsNumber;
74218  }
74219  const swiper = this;
74220  if (swiper.destroyed) return;
74221  if (typeof speed === "undefined") {
74222    speed = swiper.params.speed;
74223  }
74224  const gridEnabled = swiper.grid && swiper.params.grid && swiper.params.grid.rows > 1;
74225  let newIndex = index;
74226  if (swiper.params.loop) {
74227    if (swiper.virtual && swiper.params.virtual.enabled) {
74228      newIndex = newIndex + swiper.virtual.slidesBefore;
74229    } else {
74230      let targetSlideIndex;
74231      if (gridEnabled) {
74232        const slideIndex = newIndex * swiper.params.grid.rows;
74233        targetSlideIndex = swiper.slides.find((slideEl) => slideEl.getAttribute("data-swiper-slide-index") * 1 === slideIndex).column;
74234      } else {
74235        targetSlideIndex = swiper.getSlideIndexByData(newIndex);
74236      }
74237      const cols = gridEnabled ? Math.ceil(swiper.slides.length / swiper.params.grid.rows) : swiper.slides.length;
74238      const {
74239        centeredSlides
74240      } = swiper.params;
74241      let slidesPerView = swiper.params.slidesPerView;
74242      if (slidesPerView === "auto") {
74243        slidesPerView = swiper.slidesPerViewDynamic();
74244      } else {
74245        slidesPerView = Math.ceil(parseFloat(swiper.params.slidesPerView, 10));
74246        if (centeredSlides && slidesPerView % 2 === 0) {
74247          slidesPerView = slidesPerView + 1;
74248        }
74249      }
74250      let needLoopFix = cols - targetSlideIndex < slidesPerView;
74251      if (centeredSlides) {
74252        needLoopFix = needLoopFix || targetSlideIndex < Math.ceil(slidesPerView / 2);
74253      }
74254      if (internal && centeredSlides && swiper.params.slidesPerView !== "auto" && !gridEnabled) {
74255        needLoopFix = false;
74256      }
74257      if (needLoopFix) {
74258        const direction = centeredSlides ? targetSlideIndex < swiper.activeIndex ? "prev" : "next" : targetSlideIndex - swiper.activeIndex - 1 < swiper.params.slidesPerView ? "next" : "prev";
74259        swiper.loopFix({
74260          direction,
74261          slideTo: true,
74262          activeSlideIndex: direction === "next" ? targetSlideIndex + 1 : targetSlideIndex - cols + 1,
74263          slideRealIndex: direction === "next" ? swiper.realIndex : void 0
74264        });
74265      }
74266      if (gridEnabled) {
74267        const slideIndex = newIndex * swiper.params.grid.rows;
74268        newIndex = swiper.slides.find((slideEl) => slideEl.getAttribute("data-swiper-slide-index") * 1 === slideIndex).column;
74269      } else {
74270        newIndex = swiper.getSlideIndexByData(newIndex);
74271      }
74272    }
74273  }
74274  requestAnimationFrame(() => {
74275    swiper.slideTo(newIndex, speed, runCallbacks, internal);
74276  });
74277  return swiper;
74278}
74279function slideNext(speed, runCallbacks, internal) {
74280  if (runCallbacks === void 0) {
74281    runCallbacks = true;
74282  }
74283  const swiper = this;
74284  const {
74285    enabled,
74286    params,
74287    animating
74288  } = swiper;
74289  if (!enabled || swiper.destroyed) return swiper;
74290  if (typeof speed === "undefined") {
74291    speed = swiper.params.speed;
74292  }
74293  let perGroup = params.slidesPerGroup;
74294  if (params.slidesPerView === "auto" && params.slidesPerGroup === 1 && params.slidesPerGroupAuto) {
74295    perGroup = Math.max(swiper.slidesPerViewDynamic("current", true), 1);
74296  }
74297  const increment = swiper.activeIndex < params.slidesPerGroupSkip ? 1 : perGroup;
74298  const isVirtual = swiper.virtual && params.virtual.enabled;
74299  if (params.loop) {
74300    if (animating && !isVirtual && params.loopPreventsSliding) return false;
74301    swiper.loopFix({
74302      direction: "next"
74303    });
74304    swiper._clientLeft = swiper.wrapperEl.clientLeft;
74305    if (swiper.activeIndex === swiper.slides.length - 1 && params.cssMode) {
74306      requestAnimationFrame(() => {
74307        swiper.slideTo(swiper.activeIndex + increment, speed, runCallbacks, internal);
74308      });
74309      return true;
74310    }
74311  }
74312  if (params.rewind && swiper.isEnd) {
74313    return swiper.slideTo(0, speed, runCallbacks, internal);
74314  }
74315  return swiper.slideTo(swiper.activeIndex + increment, speed, runCallbacks, internal);
74316}
74317function slidePrev(speed, runCallbacks, internal) {
74318  if (runCallbacks === void 0) {
74319    runCallbacks = true;
74320  }
74321  const swiper = this;
74322  const {
74323    params,
74324    snapGrid,
74325    slidesGrid,
74326    rtlTranslate,
74327    enabled,
74328    animating
74329  } = swiper;
74330  if (!enabled || swiper.destroyed) return swiper;
74331  if (typeof speed === "undefined") {
74332    speed = swiper.params.speed;
74333  }
74334  const isVirtual = swiper.virtual && params.virtual.enabled;
74335  if (params.loop) {
74336    if (animating && !isVirtual && params.loopPreventsSliding) return false;
74337    swiper.loopFix({
74338      direction: "prev"
74339    });
74340    swiper._clientLeft = swiper.wrapperEl.clientLeft;
74341  }
74342  const translate2 = rtlTranslate ? swiper.translate : -swiper.translate;
74343  function normalize(val) {
74344    if (val < 0) return -Math.floor(Math.abs(val));
74345    return Math.floor(val);
74346  }
74347  const normalizedTranslate = normalize(translate2);
74348  const normalizedSnapGrid = snapGrid.map((val) => normalize(val));
74349  const isFreeMode = params.freeMode && params.freeMode.enabled;
74350  let prevSnap = snapGrid[normalizedSnapGrid.indexOf(normalizedTranslate) - 1];
74351  if (typeof prevSnap === "undefined" && (params.cssMode || isFreeMode)) {
74352    let prevSnapIndex;
74353    snapGrid.forEach((snap, snapIndex) => {
74354      if (normalizedTranslate >= snap) {
74355        prevSnapIndex = snapIndex;
74356      }
74357    });
74358    if (typeof prevSnapIndex !== "undefined") {
74359      prevSnap = isFreeMode ? snapGrid[prevSnapIndex] : snapGrid[prevSnapIndex > 0 ? prevSnapIndex - 1 : prevSnapIndex];
74360    }
74361  }
74362  let prevIndex = 0;
74363  if (typeof prevSnap !== "undefined") {
74364    prevIndex = slidesGrid.indexOf(prevSnap);
74365    if (prevIndex < 0) prevIndex = swiper.activeIndex - 1;
74366    if (params.slidesPerView === "auto" && params.slidesPerGroup === 1 && params.slidesPerGroupAuto) {
74367      prevIndex = prevIndex - swiper.slidesPerViewDynamic("previous", true) + 1;
74368      prevIndex = Math.max(prevIndex, 0);
74369    }
74370  }
74371  if (params.rewind && swiper.isBeginning) {
74372    const lastIndex = swiper.params.virtual && swiper.params.virtual.enabled && swiper.virtual ? swiper.virtual.slides.length - 1 : swiper.slides.length - 1;
74373    return swiper.slideTo(lastIndex, speed, runCallbacks, internal);
74374  } else if (params.loop && swiper.activeIndex === 0 && params.cssMode) {
74375    requestAnimationFrame(() => {
74376      swiper.slideTo(prevIndex, speed, runCallbacks, internal);
74377    });
74378    return true;
74379  }
74380  return swiper.slideTo(prevIndex, speed, runCallbacks, internal);
74381}
74382function slideReset(speed, runCallbacks, internal) {
74383  if (runCallbacks === void 0) {
74384    runCallbacks = true;
74385  }
74386  const swiper = this;
74387  if (swiper.destroyed) return;
74388  if (typeof speed === "undefined") {
74389    speed = swiper.params.speed;
74390  }
74391  return swiper.slideTo(swiper.activeIndex, speed, runCallbacks, internal);
74392}
74393function slideToClosest(speed, runCallbacks, internal, threshold) {
74394  if (runCallbacks === void 0) {
74395    runCallbacks = true;
74396  }
74397  if (threshold === void 0) {
74398    threshold = 0.5;
74399  }
74400  const swiper = this;
74401  if (swiper.destroyed) return;
74402  if (typeof speed === "undefined") {
74403    speed = swiper.params.speed;
74404  }
74405  let index = swiper.activeIndex;
74406  const skip = Math.min(swiper.params.slidesPerGroupSkip, index);
74407  const snapIndex = skip + Math.floor((index - skip) / swiper.params.slidesPerGroup);
74408  const translate2 = swiper.rtlTranslate ? swiper.translate : -swiper.translate;
74409  if (translate2 >= swiper.snapGrid[snapIndex]) {
74410    const currentSnap = swiper.snapGrid[snapIndex];
74411    const nextSnap = swiper.snapGrid[snapIndex + 1];
74412    if (translate2 - currentSnap > (nextSnap - currentSnap) * threshold) {
74413      index += swiper.params.slidesPerGroup;
74414    }
74415  } else {
74416    const prevSnap = swiper.snapGrid[snapIndex - 1];
74417    const currentSnap = swiper.snapGrid[snapIndex];
74418    if (translate2 - prevSnap <= (currentSnap - prevSnap) * threshold) {
74419      index -= swiper.params.slidesPerGroup;
74420    }
74421  }
74422  index = Math.max(index, 0);
74423  index = Math.min(index, swiper.slidesGrid.length - 1);
74424  return swiper.slideTo(index, speed, runCallbacks, internal);
74425}
74426function slideToClickedSlide() {
74427  const swiper = this;
74428  if (swiper.destroyed) return;
74429  const {
74430    params,
74431    slidesEl
74432  } = swiper;
74433  const slidesPerView = params.slidesPerView === "auto" ? swiper.slidesPerViewDynamic() : params.slidesPerView;
74434  let slideToIndex = swiper.getSlideIndexWhenGrid(swiper.clickedIndex);
74435  let realIndex;
74436  const slideSelector = swiper.isElement ? `swiper-slide` : `.${params.slideClass}`;
74437  const isGrid = swiper.grid && swiper.params.grid && swiper.params.grid.rows > 1;
74438  if (params.loop) {
74439    if (swiper.animating) return;
74440    realIndex = parseInt(swiper.clickedSlide.getAttribute("data-swiper-slide-index"), 10);
74441    if (params.centeredSlides) {
74442      swiper.slideToLoop(realIndex);
74443    } else if (slideToIndex > (isGrid ? (swiper.slides.length - slidesPerView) / 2 - (swiper.params.grid.rows - 1) : swiper.slides.length - slidesPerView)) {
74444      swiper.loopFix();
74445      slideToIndex = swiper.getSlideIndex(elementChildren(slidesEl, `${slideSelector}[data-swiper-slide-index="${realIndex}"]`)[0]);
74446      nextTick(() => {
74447        swiper.slideTo(slideToIndex);
74448      });
74449    } else {
74450      swiper.slideTo(slideToIndex);
74451    }
74452  } else {
74453    swiper.slideTo(slideToIndex);
74454  }
74455}
74456var slide = {
74457  slideTo,
74458  slideToLoop,
74459  slideNext,
74460  slidePrev,
74461  slideReset,
74462  slideToClosest,
74463  slideToClickedSlide
74464};
74465function loopCreate(slideRealIndex, initial) {
74466  const swiper = this;
74467  const {
74468    params,
74469    slidesEl
74470  } = swiper;
74471  if (!params.loop || swiper.virtual && swiper.params.virtual.enabled) return;
74472  const initSlides = () => {
74473    const slides = elementChildren(slidesEl, `.${params.slideClass}, swiper-slide`);
74474    slides.forEach((el, index) => {
74475      el.setAttribute("data-swiper-slide-index", index);
74476    });
74477  };
74478  const clearBlankSlides = () => {
74479    const slides = elementChildren(slidesEl, `.${params.slideBlankClass}`);
74480    slides.forEach((el) => {
74481      el.remove();
74482    });
74483    if (slides.length > 0) {
74484      swiper.recalcSlides();
74485      swiper.updateSlides();
74486    }
74487  };
74488  const gridEnabled = swiper.grid && params.grid && params.grid.rows > 1;
74489  if (params.loopAddBlankSlides && (params.slidesPerGroup > 1 || gridEnabled)) {
74490    clearBlankSlides();
74491  }
74492  const slidesPerGroup = params.slidesPerGroup * (gridEnabled ? params.grid.rows : 1);
74493  const shouldFillGroup = swiper.slides.length % slidesPerGroup !== 0;
74494  const shouldFillGrid = gridEnabled && swiper.slides.length % params.grid.rows !== 0;
74495  const addBlankSlides = (amountOfSlides) => {
74496    for (let i = 0; i < amountOfSlides; i += 1) {
74497      const slideEl = swiper.isElement ? createElement("swiper-slide", [params.slideBlankClass]) : createElement("div", [params.slideClass, params.slideBlankClass]);
74498      swiper.slidesEl.append(slideEl);
74499    }
74500  };
74501  if (shouldFillGroup) {
74502    if (params.loopAddBlankSlides) {
74503      const slidesToAdd = slidesPerGroup - swiper.slides.length % slidesPerGroup;
74504      addBlankSlides(slidesToAdd);
74505      swiper.recalcSlides();
74506      swiper.updateSlides();
74507    } else {
74508      showWarning("Swiper Loop Warning: The number of slides is not even to slidesPerGroup, loop mode may not function properly. You need to add more slides (or make duplicates, or empty slides)");
74509    }
74510    initSlides();
74511  } else if (shouldFillGrid) {
74512    if (params.loopAddBlankSlides) {
74513      const slidesToAdd = params.grid.rows - swiper.slides.length % params.grid.rows;
74514      addBlankSlides(slidesToAdd);
74515      swiper.recalcSlides();
74516      swiper.updateSlides();
74517    } else {
74518      showWarning("Swiper Loop Warning: The number of slides is not even to grid.rows, loop mode may not function properly. You need to add more slides (or make duplicates, or empty slides)");
74519    }
74520    initSlides();
74521  } else {
74522    initSlides();
74523  }
74524  swiper.loopFix({
74525    slideRealIndex,
74526    direction: params.centeredSlides ? void 0 : "next",
74527    initial
74528  });
74529}
74530function loopFix(_temp) {
74531  let {
74532    slideRealIndex,
74533    slideTo: slideTo2 = true,
74534    direction,
74535    setTranslate: setTranslate2,
74536    activeSlideIndex,
74537    initial,
74538    byController,
74539    byMousewheel
74540  } = _temp === void 0 ? {} : _temp;
74541  const swiper = this;
74542  if (!swiper.params.loop) return;
74543  swiper.emit("beforeLoopFix");
74544  const {
74545    slides,
74546    allowSlidePrev,
74547    allowSlideNext,
74548    slidesEl,
74549    params
74550  } = swiper;
74551  const {
74552    centeredSlides,
74553    initialSlide
74554  } = params;
74555  swiper.allowSlidePrev = true;
74556  swiper.allowSlideNext = true;
74557  if (swiper.virtual && params.virtual.enabled) {
74558    if (slideTo2) {
74559      if (!params.centeredSlides && swiper.snapIndex === 0) {
74560        swiper.slideTo(swiper.virtual.slides.length, 0, false, true);
74561      } else if (params.centeredSlides && swiper.snapIndex < params.slidesPerView) {
74562        swiper.slideTo(swiper.virtual.slides.length + swiper.snapIndex, 0, false, true);
74563      } else if (swiper.snapIndex === swiper.snapGrid.length - 1) {
74564        swiper.slideTo(swiper.virtual.slidesBefore, 0, false, true);
74565      }
74566    }
74567    swiper.allowSlidePrev = allowSlidePrev;
74568    swiper.allowSlideNext = allowSlideNext;
74569    swiper.emit("loopFix");
74570    return;
74571  }
74572  let slidesPerView = params.slidesPerView;
74573  if (slidesPerView === "auto") {
74574    slidesPerView = swiper.slidesPerViewDynamic();
74575  } else {
74576    slidesPerView = Math.ceil(parseFloat(params.slidesPerView, 10));
74577    if (centeredSlides && slidesPerView % 2 === 0) {
74578      slidesPerView = slidesPerView + 1;
74579    }
74580  }
74581  const slidesPerGroup = params.slidesPerGroupAuto ? slidesPerView : params.slidesPerGroup;
74582  let loopedSlides = centeredSlides ? Math.max(slidesPerGroup, Math.ceil(slidesPerView / 2)) : slidesPerGroup;
74583  if (loopedSlides % slidesPerGroup !== 0) {
74584    loopedSlides += slidesPerGroup - loopedSlides % slidesPerGroup;
74585  }
74586  loopedSlides += params.loopAdditionalSlides;
74587  swiper.loopedSlides = loopedSlides;
74588  const gridEnabled = swiper.grid && params.grid && params.grid.rows > 1;
74589  if (slides.length < slidesPerView + loopedSlides || swiper.params.effect === "cards" && slides.length < slidesPerView + loopedSlides * 2) {
74590    showWarning("Swiper Loop Warning: The number of slides is not enough for loop mode, it will be disabled or not function properly. You need to add more slides (or make duplicates) or lower the values of slidesPerView and slidesPerGroup parameters");
74591  } else if (gridEnabled && params.grid.fill === "row") {
74592    showWarning("Swiper Loop Warning: Loop mode is not compatible with grid.fill = `row`");
74593  }
74594  const prependSlidesIndexes = [];
74595  const appendSlidesIndexes = [];
74596  const cols = gridEnabled ? Math.ceil(slides.length / params.grid.rows) : slides.length;
74597  const isInitialOverflow = initial && cols - initialSlide < slidesPerView && !centeredSlides;
74598  let activeIndex = isInitialOverflow ? initialSlide : swiper.activeIndex;
74599  if (typeof activeSlideIndex === "undefined") {
74600    activeSlideIndex = swiper.getSlideIndex(slides.find((el) => el.classList.contains(params.slideActiveClass)));
74601  } else {
74602    activeIndex = activeSlideIndex;
74603  }
74604  const isNext = direction === "next" || !direction;
74605  const isPrev = direction === "prev" || !direction;
74606  let slidesPrepended = 0;
74607  let slidesAppended = 0;
74608  const activeColIndex = gridEnabled ? slides[activeSlideIndex].column : activeSlideIndex;
74609  const activeColIndexWithShift = activeColIndex + (centeredSlides && typeof setTranslate2 === "undefined" ? -slidesPerView / 2 + 0.5 : 0);
74610  if (activeColIndexWithShift < loopedSlides) {
74611    slidesPrepended = Math.max(loopedSlides - activeColIndexWithShift, slidesPerGroup);
74612    for (let i = 0; i < loopedSlides - activeColIndexWithShift; i += 1) {
74613      const index = i - Math.floor(i / cols) * cols;
74614      if (gridEnabled) {
74615        const colIndexToPrepend = cols - index - 1;
74616        for (let i2 = slides.length - 1; i2 >= 0; i2 -= 1) {
74617          if (slides[i2].column === colIndexToPrepend) prependSlidesIndexes.push(i2);
74618        }
74619      } else {
74620        prependSlidesIndexes.push(cols - index - 1);
74621      }
74622    }
74623  } else if (activeColIndexWithShift + slidesPerView > cols - loopedSlides) {
74624    slidesAppended = Math.max(activeColIndexWithShift - (cols - loopedSlides * 2), slidesPerGroup);
74625    if (isInitialOverflow) {
74626      slidesAppended = Math.max(slidesAppended, slidesPerView - cols + initialSlide + 1);
74627    }
74628    for (let i = 0; i < slidesAppended; i += 1) {
74629      const index = i - Math.floor(i / cols) * cols;
74630      if (gridEnabled) {
74631        slides.forEach((slide2, slideIndex) => {
74632          if (slide2.column === index) appendSlidesIndexes.push(slideIndex);
74633        });
74634      } else {
74635        appendSlidesIndexes.push(index);
74636      }
74637    }
74638  }
74639  swiper.__preventObserver__ = true;
74640  requestAnimationFrame(() => {
74641    swiper.__preventObserver__ = false;
74642  });
74643  if (swiper.params.effect === "cards" && slides.length < slidesPerView + loopedSlides * 2) {
74644    if (appendSlidesIndexes.includes(activeSlideIndex)) {
74645      appendSlidesIndexes.splice(appendSlidesIndexes.indexOf(activeSlideIndex), 1);
74646    }
74647    if (prependSlidesIndexes.includes(activeSlideIndex)) {
74648      prependSlidesIndexes.splice(prependSlidesIndexes.indexOf(activeSlideIndex), 1);
74649    }
74650  }
74651  if (isPrev) {
74652    prependSlidesIndexes.forEach((index) => {
74653      slides[index].swiperLoopMoveDOM = true;
74654      slidesEl.prepend(slides[index]);
74655      slides[index].swiperLoopMoveDOM = false;
74656    });
74657  }
74658  if (isNext) {
74659    appendSlidesIndexes.forEach((index) => {
74660      slides[index].swiperLoopMoveDOM = true;
74661      slidesEl.append(slides[index]);
74662      slides[index].swiperLoopMoveDOM = false;
74663    });
74664  }
74665  swiper.recalcSlides();
74666  if (params.slidesPerView === "auto") {
74667    swiper.updateSlides();
74668  } else if (gridEnabled && (prependSlidesIndexes.length > 0 && isPrev || appendSlidesIndexes.length > 0 && isNext)) {
74669    swiper.slides.forEach((slide2, slideIndex) => {
74670      swiper.grid.updateSlide(slideIndex, slide2, swiper.slides);
74671    });
74672  }
74673  if (params.watchSlidesProgress) {
74674    swiper.updateSlidesOffset();
74675  }
74676  if (slideTo2) {
74677    if (prependSlidesIndexes.length > 0 && isPrev) {
74678      if (typeof slideRealIndex === "undefined") {
74679        const currentSlideTranslate = swiper.slidesGrid[activeIndex];
74680        const newSlideTranslate = swiper.slidesGrid[activeIndex + slidesPrepended];
74681        const diff = newSlideTranslate - currentSlideTranslate;
74682        if (byMousewheel) {
74683          swiper.setTranslate(swiper.translate - diff);
74684        } else {
74685          swiper.slideTo(activeIndex + Math.ceil(slidesPrepended), 0, false, true);
74686          if (setTranslate2) {
74687            swiper.touchEventsData.startTranslate = swiper.touchEventsData.startTranslate - diff;
74688            swiper.touchEventsData.currentTranslate = swiper.touchEventsData.currentTranslate - diff;
74689          }
74690        }
74691      } else {
74692        if (setTranslate2) {
74693          const shift = gridEnabled ? prependSlidesIndexes.length / params.grid.rows : prependSlidesIndexes.length;
74694          swiper.slideTo(swiper.activeIndex + shift, 0, false, true);
74695          swiper.touchEventsData.currentTranslate = swiper.translate;
74696        }
74697      }
74698    } else if (appendSlidesIndexes.length > 0 && isNext) {
74699      if (typeof slideRealIndex === "undefined") {
74700        const currentSlideTranslate = swiper.slidesGrid[activeIndex];
74701        const newSlideTranslate = swiper.slidesGrid[activeIndex - slidesAppended];
74702        const diff = newSlideTranslate - currentSlideTranslate;
74703        if (byMousewheel) {
74704          swiper.setTranslate(swiper.translate - diff);
74705        } else {
74706          swiper.slideTo(activeIndex - slidesAppended, 0, false, true);
74707          if (setTranslate2) {
74708            swiper.touchEventsData.startTranslate = swiper.touchEventsData.startTranslate - diff;
74709            swiper.touchEventsData.currentTranslate = swiper.touchEventsData.currentTranslate - diff;
74710          }
74711        }
74712      } else {
74713        const shift = gridEnabled ? appendSlidesIndexes.length / params.grid.rows : appendSlidesIndexes.length;
74714        swiper.slideTo(swiper.activeIndex - shift, 0, false, true);
74715      }
74716    }
74717  }
74718  swiper.allowSlidePrev = allowSlidePrev;
74719  swiper.allowSlideNext = allowSlideNext;
74720  if (swiper.controller && swiper.controller.control && !byController) {
74721    const loopParams = {
74722      slideRealIndex,
74723      direction,
74724      setTranslate: setTranslate2,
74725      activeSlideIndex,
74726      byController: true
74727    };
74728    if (Array.isArray(swiper.controller.control)) {
74729      swiper.controller.control.forEach((c) => {
74730        if (!c.destroyed && c.params.loop) c.loopFix(__spreadProps(__spreadValues({}, loopParams), {
74731          slideTo: c.params.slidesPerView === params.slidesPerView ? slideTo2 : false
74732        }));
74733      });
74734    } else if (swiper.controller.control instanceof swiper.constructor && swiper.controller.control.params.loop) {
74735      swiper.controller.control.loopFix(__spreadProps(__spreadValues({}, loopParams), {
74736        slideTo: swiper.controller.control.params.slidesPerView === params.slidesPerView ? slideTo2 : false
74737      }));
74738    }
74739  }
74740  swiper.emit("loopFix");
74741}
74742function loopDestroy() {
74743  const swiper = this;
74744  const {
74745    params,
74746    slidesEl
74747  } = swiper;
74748  if (!params.loop || !slidesEl || swiper.virtual && swiper.params.virtual.enabled) return;
74749  swiper.recalcSlides();
74750  const newSlidesOrder = [];
74751  swiper.slides.forEach((slideEl) => {
74752    const index = typeof slideEl.swiperSlideIndex === "undefined" ? slideEl.getAttribute("data-swiper-slide-index") * 1 : slideEl.swiperSlideIndex;
74753    newSlidesOrder[index] = slideEl;
74754  });
74755  swiper.slides.forEach((slideEl) => {
74756    slideEl.removeAttribute("data-swiper-slide-index");
74757  });
74758  newSlidesOrder.forEach((slideEl) => {
74759    slidesEl.append(slideEl);
74760  });
74761  swiper.recalcSlides();
74762  swiper.slideTo(swiper.realIndex, 0);
74763}
74764var loop = {
74765  loopCreate,
74766  loopFix,
74767  loopDestroy
74768};
74769function setGrabCursor(moving) {
74770  const swiper = this;
74771  if (!swiper.params.simulateTouch || swiper.params.watchOverflow && swiper.isLocked || swiper.params.cssMode) return;
74772  const el = swiper.params.touchEventsTarget === "container" ? swiper.el : swiper.wrapperEl;
74773  if (swiper.isElement) {
74774    swiper.__preventObserver__ = true;
74775  }
74776  el.style.cursor = "move";
74777  el.style.cursor = moving ? "grabbing" : "grab";
74778  if (swiper.isElement) {
74779    requestAnimationFrame(() => {
74780      swiper.__preventObserver__ = false;
74781    });
74782  }
74783}
74784function unsetGrabCursor() {
74785  const swiper = this;
74786  if (swiper.params.watchOverflow && swiper.isLocked || swiper.params.cssMode) {
74787    return;
74788  }
74789  if (swiper.isElement) {
74790    swiper.__preventObserver__ = true;
74791  }
74792  swiper[swiper.params.touchEventsTarget === "container" ? "el" : "wrapperEl"].style.cursor = "";
74793  if (swiper.isElement) {
74794    requestAnimationFrame(() => {
74795      swiper.__preventObserver__ = false;
74796    });
74797  }
74798}
74799var grabCursor = {
74800  setGrabCursor,
74801  unsetGrabCursor
74802};
74803function closestElement(selector, base) {
74804  if (base === void 0) {
74805    base = this;
74806  }
74807  function __closestFrom(el) {
74808    if (!el || el === getDocument() || el === getWindow()) return null;
74809    if (el.assignedSlot) el = el.assignedSlot;
74810    const found = el.closest(selector);
74811    if (!found && !el.getRootNode) {
74812      return null;
74813    }
74814    return found || __closestFrom(el.getRootNode().host);
74815  }
74816  return __closestFrom(base);
74817}
74818function preventEdgeSwipe(swiper, event2, startX) {
74819  const window2 = getWindow();
74820  const {
74821    params
74822  } = swiper;
74823  const edgeSwipeDetection = params.edgeSwipeDetection;
74824  const edgeSwipeThreshold = params.edgeSwipeThreshold;
74825  if (edgeSwipeDetection && (startX <= edgeSwipeThreshold || startX >= window2.innerWidth - edgeSwipeThreshold)) {
74826    if (edgeSwipeDetection === "prevent") {
74827      event2.preventDefault();
74828      return true;
74829    }
74830    return false;
74831  }
74832  return true;
74833}
74834function onTouchStart(event2) {
74835  const swiper = this;
74836  const document2 = getDocument();
74837  let e = event2;
74838  if (e.originalEvent) e = e.originalEvent;
74839  const data = swiper.touchEventsData;
74840  if (e.type === "pointerdown") {
74841    if (data.pointerId !== null && data.pointerId !== e.pointerId) {
74842      return;
74843    }
74844    data.pointerId = e.pointerId;
74845  } else if (e.type === "touchstart" && e.targetTouches.length === 1) {
74846    data.touchId = e.targetTouches[0].identifier;
74847  }
74848  if (e.type === "touchstart") {
74849    preventEdgeSwipe(swiper, e, e.targetTouches[0].pageX);
74850    return;
74851  }
74852  const {
74853    params,
74854    touches,
74855    enabled
74856  } = swiper;
74857  if (!enabled) return;
74858  if (!params.simulateTouch && e.pointerType === "mouse") return;
74859  if (swiper.animating && params.preventInteractionOnTransition) {
74860    return;
74861  }
74862  if (!swiper.animating && params.cssMode && params.loop) {
74863    swiper.loopFix();
74864  }
74865  let targetEl = e.target;
74866  if (params.touchEventsTarget === "wrapper") {
74867    if (!elementIsChildOf(targetEl, swiper.wrapperEl)) return;
74868  }
74869  if ("which" in e && e.which === 3) return;
74870  if ("button" in e && e.button > 0) return;
74871  if (data.isTouched && data.isMoved) return;
74872  const swipingClassHasValue = !!params.noSwipingClass && params.noSwipingClass !== "";
74873  const eventPath = e.composedPath ? e.composedPath() : e.path;
74874  if (swipingClassHasValue && e.target && e.target.shadowRoot && eventPath) {
74875    targetEl = eventPath[0];
74876  }
74877  const noSwipingSelector = params.noSwipingSelector ? params.noSwipingSelector : `.${params.noSwipingClass}`;
74878  const isTargetShadow = !!(e.target && e.target.shadowRoot);
74879  if (params.noSwiping && (isTargetShadow ? closestElement(noSwipingSelector, targetEl) : targetEl.closest(noSwipingSelector))) {
74880    swiper.allowClick = true;
74881    return;
74882  }
74883  if (params.swipeHandler) {
74884    if (!targetEl.closest(params.swipeHandler)) return;
74885  }
74886  touches.currentX = e.pageX;
74887  touches.currentY = e.pageY;
74888  const startX = touches.currentX;
74889  const startY = touches.currentY;
74890  if (!preventEdgeSwipe(swiper, e, startX)) {
74891    return;
74892  }
74893  Object.assign(data, {
74894    isTouched: true,
74895    isMoved: false,
74896    allowTouchCallbacks: true,
74897    isScrolling: void 0,
74898    startMoving: void 0
74899  });
74900  touches.startX = startX;
74901  touches.startY = startY;
74902  data.touchStartTime = now();
74903  swiper.allowClick = true;
74904  swiper.updateSize();
74905  swiper.swipeDirection = void 0;
74906  if (params.threshold > 0) data.allowThresholdMove = false;
74907  let preventDefault = true;
74908  if (targetEl.matches(data.focusableElements)) {
74909    preventDefault = false;
74910    if (targetEl.nodeName === "SELECT") {
74911      data.isTouched = false;
74912    }
74913  }
74914  if (document2.activeElement && document2.activeElement.matches(data.focusableElements) && document2.activeElement !== targetEl && (e.pointerType === "mouse" || e.pointerType !== "mouse" && !targetEl.matches(data.focusableElements))) {
74915    document2.activeElement.blur();
74916  }
74917  const shouldPreventDefault = preventDefault && swiper.allowTouchMove && params.touchStartPreventDefault;
74918  if ((params.touchStartForcePreventDefault || shouldPreventDefault) && !targetEl.isContentEditable) {
74919    e.preventDefault();
74920  }
74921  if (params.freeMode && params.freeMode.enabled && swiper.freeMode && swiper.animating && !params.cssMode) {
74922    swiper.freeMode.onTouchStart();
74923  }
74924  swiper.emit("touchStart", e);
74925}
74926function onTouchMove(event2) {
74927  const document2 = getDocument();
74928  const swiper = this;
74929  const data = swiper.touchEventsData;
74930  const {
74931    params,
74932    touches,
74933    rtlTranslate: rtl,
74934    enabled
74935  } = swiper;
74936  if (!enabled) return;
74937  if (!params.simulateTouch && event2.pointerType === "mouse") return;
74938  let e = event2;
74939  if (e.originalEvent) e = e.originalEvent;
74940  if (e.type === "pointermove") {
74941    if (data.touchId !== null) return;
74942    const id = e.pointerId;
74943    if (id !== data.pointerId) return;
74944  }
74945  let targetTouch;
74946  if (e.type === "touchmove") {
74947    targetTouch = [...e.changedTouches].find((t) => t.identifier === data.touchId);
74948    if (!targetTouch || targetTouch.identifier !== data.touchId) return;
74949  } else {
74950    targetTouch = e;
74951  }
74952  if (!data.isTouched) {
74953    if (data.startMoving && data.isScrolling) {
74954      swiper.emit("touchMoveOpposite", e);
74955    }
74956    return;
74957  }
74958  const pageX = targetTouch.pageX;
74959  const pageY = targetTouch.pageY;
74960  if (e.preventedByNestedSwiper) {
74961    touches.startX = pageX;
74962    touches.startY = pageY;
74963    return;
74964  }
74965  if (!swiper.allowTouchMove) {
74966    if (!e.target.matches(data.focusableElements)) {
74967      swiper.allowClick = false;
74968    }
74969    if (data.isTouched) {
74970      Object.assign(touches, {
74971        startX: pageX,
74972        startY: pageY,
74973        currentX: pageX,
74974        currentY: pageY
74975      });
74976      data.touchStartTime = now();
74977    }
74978    return;
74979  }
74980  if (params.touchReleaseOnEdges && !params.loop) {
74981    if (swiper.isVertical()) {
74982      if (pageY < touches.startY && swiper.translate <= swiper.maxTranslate() || pageY > touches.startY && swiper.translate >= swiper.minTranslate()) {
74983        data.isTouched = false;
74984        data.isMoved = false;
74985        return;
74986      }
74987    } else if (rtl && (pageX > touches.startX && -swiper.translate <= swiper.maxTranslate() || pageX < touches.startX && -swiper.translate >= swiper.minTranslate())) {
74988      return;
74989    } else if (!rtl && (pageX < touches.startX && swiper.translate <= swiper.maxTranslate() || pageX > touches.startX && swiper.translate >= swiper.minTranslate())) {
74990      return;
74991    }
74992  }
74993  if (document2.activeElement && document2.activeElement.matches(data.focusableElements) && document2.activeElement !== e.target && e.pointerType !== "mouse") {
74994    document2.activeElement.blur();
74995  }
74996  if (document2.activeElement) {
74997    if (e.target === document2.activeElement && e.target.matches(data.focusableElements)) {
74998      data.isMoved = true;
74999      swiper.allowClick = false;
75000      return;
75001    }
75002  }
75003  if (data.allowTouchCallbacks) {
75004    swiper.emit("touchMove", e);
75005  }
75006  touches.previousX = touches.currentX;
75007  touches.previousY = touches.currentY;
75008  touches.currentX = pageX;
75009  touches.currentY = pageY;
75010  const diffX = touches.currentX - touches.startX;
75011  const diffY = touches.currentY - touches.startY;
75012  if (swiper.params.threshold && Math.sqrt(diffX ** 2 + diffY ** 2) < swiper.params.threshold) return;
75013  if (typeof data.isScrolling === "undefined") {
75014    let touchAngle;
75015    if (swiper.isHorizontal() && touches.currentY === touches.startY || swiper.isVertical() && touches.currentX === touches.startX) {
75016      data.isScrolling = false;
75017    } else {
75018      if (diffX * diffX + diffY * diffY >= 25) {
75019        touchAngle = Math.atan2(Math.abs(diffY), Math.abs(diffX)) * 180 / Math.PI;
75020        data.isScrolling = swiper.isHorizontal() ? touchAngle > params.touchAngle : 90 - touchAngle > params.touchAngle;
75021      }
75022    }
75023  }
75024  if (data.isScrolling) {
75025    swiper.emit("touchMoveOpposite", e);
75026  }
75027  if (typeof data.startMoving === "undefined") {
75028    if (touches.currentX !== touches.startX || touches.currentY !== touches.startY) {
75029      data.startMoving = true;
75030    }
75031  }
75032  if (data.isScrolling || e.type === "touchmove" && data.preventTouchMoveFromPointerMove) {
75033    data.isTouched = false;
75034    return;
75035  }
75036  if (!data.startMoving) {
75037    return;
75038  }
75039  swiper.allowClick = false;
75040  if (!params.cssMode && e.cancelable) {
75041    e.preventDefault();
75042  }
75043  if (params.touchMoveStopPropagation && !params.nested) {
75044    e.stopPropagation();
75045  }
75046  let diff = swiper.isHorizontal() ? diffX : diffY;
75047  let touchesDiff = swiper.isHorizontal() ? touches.currentX - touches.previousX : touches.currentY - touches.previousY;
75048  if (params.oneWayMovement) {
75049    diff = Math.abs(diff) * (rtl ? 1 : -1);
75050    touchesDiff = Math.abs(touchesDiff) * (rtl ? 1 : -1);
75051  }
75052  touches.diff = diff;
75053  diff *= params.touchRatio;
75054  if (rtl) {
75055    diff = -diff;
75056    touchesDiff = -touchesDiff;
75057  }
75058  const prevTouchesDirection = swiper.touchesDirection;
75059  swiper.swipeDirection = diff > 0 ? "prev" : "next";
75060  swiper.touchesDirection = touchesDiff > 0 ? "prev" : "next";
75061  const isLoop = swiper.params.loop && !params.cssMode;
75062  const allowLoopFix = swiper.touchesDirection === "next" && swiper.allowSlideNext || swiper.touchesDirection === "prev" && swiper.allowSlidePrev;
75063  if (!data.isMoved) {
75064    if (isLoop && allowLoopFix) {
75065      swiper.loopFix({
75066        direction: swiper.swipeDirection
75067      });
75068    }
75069    data.startTranslate = swiper.getTranslate();
75070    swiper.setTransition(0);
75071    if (swiper.animating) {
75072      const evt = new window.CustomEvent("transitionend", {
75073        bubbles: true,
75074        cancelable: true,
75075        detail: {
75076          bySwiperTouchMove: true
75077        }
75078      });
75079      swiper.wrapperEl.dispatchEvent(evt);
75080    }
75081    data.allowMomentumBounce = false;
75082    if (params.grabCursor && (swiper.allowSlideNext === true || swiper.allowSlidePrev === true)) {
75083      swiper.setGrabCursor(true);
75084    }
75085    swiper.emit("sliderFirstMove", e);
75086  }
75087  let loopFixed;
75088  (/* @__PURE__ */ new Date()).getTime();
75089  if (params._loopSwapReset !== false && data.isMoved && data.allowThresholdMove && prevTouchesDirection !== swiper.touchesDirection && isLoop && allowLoopFix && Math.abs(diff) >= 1) {
75090    Object.assign(touches, {
75091      startX: pageX,
75092      startY: pageY,
75093      currentX: pageX,
75094      currentY: pageY,
75095      startTranslate: data.currentTranslate
75096    });
75097    data.loopSwapReset = true;
75098    data.startTranslate = data.currentTranslate;
75099    return;
75100  }
75101  swiper.emit("sliderMove", e);
75102  data.isMoved = true;
75103  data.currentTranslate = diff + data.startTranslate;
75104  let disableParentSwiper = true;
75105  let resistanceRatio = params.resistanceRatio;
75106  if (params.touchReleaseOnEdges) {
75107    resistanceRatio = 0;
75108  }
75109  if (diff > 0) {
75110    if (isLoop && allowLoopFix && !loopFixed && data.allowThresholdMove && data.currentTranslate > (params.centeredSlides ? swiper.minTranslate() - swiper.slidesSizesGrid[swiper.activeIndex + 1] - (params.slidesPerView !== "auto" && swiper.slides.length - params.slidesPerView >= 2 ? swiper.slidesSizesGrid[swiper.activeIndex + 1] + swiper.params.spaceBetween : 0) - swiper.params.spaceBetween : swiper.minTranslate())) {
75111      swiper.loopFix({
75112        direction: "prev",
75113        setTranslate: true,
75114        activeSlideIndex: 0
75115      });
75116    }
75117    if (data.currentTranslate > swiper.minTranslate()) {
75118      disableParentSwiper = false;
75119      if (params.resistance) {
75120        data.currentTranslate = swiper.minTranslate() - 1 + (-swiper.minTranslate() + data.startTranslate + diff) ** resistanceRatio;
75121      }
75122    }
75123  } else if (diff < 0) {
75124    if (isLoop && allowLoopFix && !loopFixed && data.allowThresholdMove && data.currentTranslate < (params.centeredSlides ? swiper.maxTranslate() + swiper.slidesSizesGrid[swiper.slidesSizesGrid.length - 1] + swiper.params.spaceBetween + (params.slidesPerView !== "auto" && swiper.slides.length - params.slidesPerView >= 2 ? swiper.slidesSizesGrid[swiper.slidesSizesGrid.length - 1] + swiper.params.spaceBetween : 0) : swiper.maxTranslate())) {
75125      swiper.loopFix({
75126        direction: "next",
75127        setTranslate: true,
75128        activeSlideIndex: swiper.slides.length - (params.slidesPerView === "auto" ? swiper.slidesPerViewDynamic() : Math.ceil(parseFloat(params.slidesPerView, 10)))
75129      });
75130    }
75131    if (data.currentTranslate < swiper.maxTranslate()) {
75132      disableParentSwiper = false;
75133      if (params.resistance) {
75134        data.currentTranslate = swiper.maxTranslate() + 1 - (swiper.maxTranslate() - data.startTranslate - diff) ** resistanceRatio;
75135      }
75136    }
75137  }
75138  if (disableParentSwiper) {
75139    e.preventedByNestedSwiper = true;
75140  }
75141  if (!swiper.allowSlideNext && swiper.swipeDirection === "next" && data.currentTranslate < data.startTranslate) {
75142    data.currentTranslate = data.startTranslate;
75143  }
75144  if (!swiper.allowSlidePrev && swiper.swipeDirection === "prev" && data.currentTranslate > data.startTranslate) {
75145    data.currentTranslate = data.startTranslate;
75146  }
75147  if (!swiper.allowSlidePrev && !swiper.allowSlideNext) {
75148    data.currentTranslate = data.startTranslate;
75149  }
75150  if (params.threshold > 0) {
75151    if (Math.abs(diff) > params.threshold || data.allowThresholdMove) {
75152      if (!data.allowThresholdMove) {
75153        data.allowThresholdMove = true;
75154        touches.startX = touches.currentX;
75155        touches.startY = touches.currentY;
75156        data.currentTranslate = data.startTranslate;
75157        touches.diff = swiper.isHorizontal() ? touches.currentX - touches.startX : touches.currentY - touches.startY;
75158        return;
75159      }
75160    } else {
75161      data.currentTranslate = data.startTranslate;
75162      return;
75163    }
75164  }
75165  if (!params.followFinger || params.cssMode) return;
75166  if (params.freeMode && params.freeMode.enabled && swiper.freeMode || params.watchSlidesProgress) {
75167    swiper.updateActiveIndex();
75168    swiper.updateSlidesClasses();
75169  }
75170  if (params.freeMode && params.freeMode.enabled && swiper.freeMode) {
75171    swiper.freeMode.onTouchMove();
75172  }
75173  swiper.updateProgress(data.currentTranslate);
75174  swiper.setTranslate(data.currentTranslate);
75175}
75176function onTouchEnd(event2) {
75177  const swiper = this;
75178  const data = swiper.touchEventsData;
75179  let e = event2;
75180  if (e.originalEvent) e = e.originalEvent;
75181  let targetTouch;
75182  const isTouchEvent = e.type === "touchend" || e.type === "touchcancel";
75183  if (!isTouchEvent) {
75184    if (data.touchId !== null) return;
75185    if (e.pointerId !== data.pointerId) return;
75186    targetTouch = e;
75187  } else {
75188    targetTouch = [...e.changedTouches].find((t) => t.identifier === data.touchId);
75189    if (!targetTouch || targetTouch.identifier !== data.touchId) return;
75190  }
75191  if (["pointercancel", "pointerout", "pointerleave", "contextmenu"].includes(e.type)) {
75192    const proceed = ["pointercancel", "contextmenu"].includes(e.type) && (swiper.browser.isSafari || swiper.browser.isWebView);
75193    if (!proceed) {
75194      return;
75195    }
75196  }
75197  data.pointerId = null;
75198  data.touchId = null;
75199  const {
75200    params,
75201    touches,
75202    rtlTranslate: rtl,
75203    slidesGrid,
75204    enabled
75205  } = swiper;
75206  if (!enabled) return;
75207  if (!params.simulateTouch && e.pointerType === "mouse") return;
75208  if (data.allowTouchCallbacks) {
75209    swiper.emit("touchEnd", e);
75210  }
75211  data.allowTouchCallbacks = false;
75212  if (!data.isTouched) {
75213    if (data.isMoved && params.grabCursor) {
75214      swiper.setGrabCursor(false);
75215    }
75216    data.isMoved = false;
75217    data.startMoving = false;
75218    return;
75219  }
75220  if (params.grabCursor && data.isMoved && data.isTouched && (swiper.allowSlideNext === true || swiper.allowSlidePrev === true)) {
75221    swiper.setGrabCursor(false);
75222  }
75223  const touchEndTime = now();
75224  const timeDiff = touchEndTime - data.touchStartTime;
75225  if (swiper.allowClick) {
75226    const pathTree = e.path || e.composedPath && e.composedPath();
75227    swiper.updateClickedSlide(pathTree && pathTree[0] || e.target, pathTree);
75228    swiper.emit("tap click", e);
75229    if (timeDiff < 300 && touchEndTime - data.lastClickTime < 300) {
75230      swiper.emit("doubleTap doubleClick", e);
75231    }
75232  }
75233  data.lastClickTime = now();
75234  nextTick(() => {
75235    if (!swiper.destroyed) swiper.allowClick = true;
75236  });
75237  if (!data.isTouched || !data.isMoved || !swiper.swipeDirection || touches.diff === 0 && !data.loopSwapReset || data.currentTranslate === data.startTranslate && !data.loopSwapReset) {
75238    data.isTouched = false;
75239    data.isMoved = false;
75240    data.startMoving = false;
75241    return;
75242  }
75243  data.isTouched = false;
75244  data.isMoved = false;
75245  data.startMoving = false;
75246  let currentPos;
75247  if (params.followFinger) {
75248    currentPos = rtl ? swiper.translate : -swiper.translate;
75249  } else {
75250    currentPos = -data.currentTranslate;
75251  }
75252  if (params.cssMode) {
75253    return;
75254  }
75255  if (params.freeMode && params.freeMode.enabled) {
75256    swiper.freeMode.onTouchEnd({
75257      currentPos
75258    });
75259    return;
75260  }
75261  const swipeToLast = currentPos >= -swiper.maxTranslate() && !swiper.params.loop;
75262  let stopIndex = 0;
75263  let groupSize = swiper.slidesSizesGrid[0];
75264  for (let i = 0; i < slidesGrid.length; i += i < params.slidesPerGroupSkip ? 1 : params.slidesPerGroup) {
75265    const increment2 = i < params.slidesPerGroupSkip - 1 ? 1 : params.slidesPerGroup;
75266    if (typeof slidesGrid[i + increment2] !== "undefined") {
75267      if (swipeToLast || currentPos >= slidesGrid[i] && currentPos < slidesGrid[i + increment2]) {
75268        stopIndex = i;
75269        groupSize = slidesGrid[i + increment2] - slidesGrid[i];
75270      }
75271    } else if (swipeToLast || currentPos >= slidesGrid[i]) {
75272      stopIndex = i;
75273      groupSize = slidesGrid[slidesGrid.length - 1] - slidesGrid[slidesGrid.length - 2];
75274    }
75275  }
75276  let rewindFirstIndex = null;
75277  let rewindLastIndex = null;
75278  if (params.rewind) {
75279    if (swiper.isBeginning) {
75280      rewindLastIndex = params.virtual && params.virtual.enabled && swiper.virtual ? swiper.virtual.slides.length - 1 : swiper.slides.length - 1;
75281    } else if (swiper.isEnd) {
75282      rewindFirstIndex = 0;
75283    }
75284  }
75285  const ratio = (currentPos - slidesGrid[stopIndex]) / groupSize;
75286  const increment = stopIndex < params.slidesPerGroupSkip - 1 ? 1 : params.slidesPerGroup;
75287  if (timeDiff > params.longSwipesMs) {
75288    if (!params.longSwipes) {
75289      swiper.slideTo(swiper.activeIndex);
75290      return;
75291    }
75292    if (swiper.swipeDirection === "next") {
75293      if (ratio >= params.longSwipesRatio) swiper.slideTo(params.rewind && swiper.isEnd ? rewindFirstIndex : stopIndex + increment);
75294      else swiper.slideTo(stopIndex);
75295    }
75296    if (swiper.swipeDirection === "prev") {
75297      if (ratio > 1 - params.longSwipesRatio) {
75298        swiper.slideTo(stopIndex + increment);
75299      } else if (rewindLastIndex !== null && ratio < 0 && Math.abs(ratio) > params.longSwipesRatio) {
75300        swiper.slideTo(rewindLastIndex);
75301      } else {
75302        swiper.slideTo(stopIndex);
75303      }
75304    }
75305  } else {
75306    if (!params.shortSwipes) {
75307      swiper.slideTo(swiper.activeIndex);
75308      return;
75309    }
75310    const isNavButtonTarget = swiper.navigation && (e.target === swiper.navigation.nextEl || e.target === swiper.navigation.prevEl);
75311    if (!isNavButtonTarget) {
75312      if (swiper.swipeDirection === "next") {
75313        swiper.slideTo(rewindFirstIndex !== null ? rewindFirstIndex : stopIndex + increment);
75314      }
75315      if (swiper.swipeDirection === "prev") {
75316        swiper.slideTo(rewindLastIndex !== null ? rewindLastIndex : stopIndex);
75317      }
75318    } else if (e.target === swiper.navigation.nextEl) {
75319      swiper.slideTo(stopIndex + increment);
75320    } else {
75321      swiper.slideTo(stopIndex);
75322    }
75323  }
75324}
75325function onResize() {
75326  const swiper = this;
75327  const {
75328    params,
75329    el
75330  } = swiper;
75331  if (el && el.offsetWidth === 0) return;
75332  if (params.breakpoints) {
75333    swiper.setBreakpoint();
75334  }
75335  const {
75336    allowSlideNext,
75337    allowSlidePrev,
75338    snapGrid
75339  } = swiper;
75340  const isVirtual = swiper.virtual && swiper.params.virtual.enabled;
75341  swiper.allowSlideNext = true;
75342  swiper.allowSlidePrev = true;
75343  swiper.updateSize();
75344  swiper.updateSlides();
75345  swiper.updateSlidesClasses();
75346  const isVirtualLoop = isVirtual && params.loop;
75347  if ((params.slidesPerView === "auto" || params.slidesPerView > 1) && swiper.isEnd && !swiper.isBeginning && !swiper.params.centeredSlides && !isVirtualLoop) {
75348    swiper.slideTo(swiper.slides.length - 1, 0, false, true);
75349  } else {
75350    if (swiper.params.loop && !isVirtual) {
75351      swiper.slideToLoop(swiper.realIndex, 0, false, true);
75352    } else {
75353      swiper.slideTo(swiper.activeIndex, 0, false, true);
75354    }
75355  }
75356  if (swiper.autoplay && swiper.autoplay.running && swiper.autoplay.paused) {
75357    clearTimeout(swiper.autoplay.resizeTimeout);
75358    swiper.autoplay.resizeTimeout = setTimeout(() => {
75359      if (swiper.autoplay && swiper.autoplay.running && swiper.autoplay.paused) {
75360        swiper.autoplay.resume();
75361      }
75362    }, 500);
75363  }
75364  swiper.allowSlidePrev = allowSlidePrev;
75365  swiper.allowSlideNext = allowSlideNext;
75366  if (swiper.params.watchOverflow && snapGrid !== swiper.snapGrid) {
75367    swiper.checkOverflow();
75368  }
75369}
75370function onClick(e) {
75371  const swiper = this;
75372  if (!swiper.enabled) return;
75373  if (!swiper.allowClick) {
75374    if (swiper.params.preventClicks) e.preventDefault();
75375    if (swiper.params.preventClicksPropagation && swiper.animating) {
75376      e.stopPropagation();
75377      e.stopImmediatePropagation();
75378    }
75379  }
75380}
75381function onScroll() {
75382  const swiper = this;
75383  const {
75384    wrapperEl,
75385    rtlTranslate,
75386    enabled
75387  } = swiper;
75388  if (!enabled) return;
75389  swiper.previousTranslate = swiper.translate;
75390  if (swiper.isHorizontal()) {
75391    swiper.translate = -wrapperEl.scrollLeft;
75392  } else {
75393    swiper.translate = -wrapperEl.scrollTop;
75394  }
75395  if (swiper.translate === 0) swiper.translate = 0;
75396  swiper.updateActiveIndex();
75397  swiper.updateSlidesClasses();
75398  let newProgress;
75399  const translatesDiff = swiper.maxTranslate() - swiper.minTranslate();
75400  if (translatesDiff === 0) {
75401    newProgress = 0;
75402  } else {
75403    newProgress = (swiper.translate - swiper.minTranslate()) / translatesDiff;
75404  }
75405  if (newProgress !== swiper.progress) {
75406    swiper.updateProgress(rtlTranslate ? -swiper.translate : swiper.translate);
75407  }
75408  swiper.emit("setTranslate", swiper.translate, false);
75409}
75410function onLoad(e) {
75411  const swiper = this;
75412  processLazyPreloader(swiper, e.target);
75413  if (swiper.params.cssMode || swiper.params.slidesPerView !== "auto" && !swiper.params.autoHeight) {
75414    return;
75415  }
75416  swiper.update();
75417}
75418function onDocumentTouchStart() {
75419  const swiper = this;
75420  if (swiper.documentTouchHandlerProceeded) return;
75421  swiper.documentTouchHandlerProceeded = true;
75422  if (swiper.params.touchReleaseOnEdges) {
75423    swiper.el.style.touchAction = "auto";
75424  }
75425}
75426var events = (swiper, method) => {
75427  const document2 = getDocument();
75428  const {
75429    params,
75430    el,
75431    wrapperEl,
75432    device
75433  } = swiper;
75434  const capture = !!params.nested;
75435  const domMethod = method === "on" ? "addEventListener" : "removeEventListener";
75436  const swiperMethod = method;
75437  if (!el || typeof el === "string") return;
75438  document2[domMethod]("touchstart", swiper.onDocumentTouchStart, {
75439    passive: false,
75440    capture
75441  });
75442  el[domMethod]("touchstart", swiper.onTouchStart, {
75443    passive: false
75444  });
75445  el[domMethod]("pointerdown", swiper.onTouchStart, {
75446    passive: false
75447  });
75448  document2[domMethod]("touchmove", swiper.onTouchMove, {
75449    passive: false,
75450    capture
75451  });
75452  document2[domMethod]("pointermove", swiper.onTouchMove, {
75453    passive: false,
75454    capture
75455  });
75456  document2[domMethod]("touchend", swiper.onTouchEnd, {
75457    passive: true
75458  });
75459  document2[domMethod]("pointerup", swiper.onTouchEnd, {
75460    passive: true
75461  });
75462  document2[domMethod]("pointercancel", swiper.onTouchEnd, {
75463    passive: true
75464  });
75465  document2[domMethod]("touchcancel", swiper.onTouchEnd, {
75466    passive: true
75467  });
75468  document2[domMethod]("pointerout", swiper.onTouchEnd, {
75469    passive: true
75470  });
75471  document2[domMethod]("pointerleave", swiper.onTouchEnd, {
75472    passive: true
75473  });
75474  document2[domMethod]("contextmenu", swiper.onTouchEnd, {
75475    passive: true
75476  });
75477  if (params.preventClicks || params.preventClicksPropagation) {
75478    el[domMethod]("click", swiper.onClick, true);
75479  }
75480  if (params.cssMode) {
75481    wrapperEl[domMethod]("scroll", swiper.onScroll);
75482  }
75483  if (params.updateOnWindowResize) {
75484    swiper[swiperMethod](device.ios || device.android ? "resize orientationchange observerUpdate" : "resize observerUpdate", onResize, true);
75485  } else {
75486    swiper[swiperMethod]("observerUpdate", onResize, true);
75487  }
75488  el[domMethod]("load", swiper.onLoad, {
75489    capture: true
75490  });
75491};
75492function attachEvents() {
75493  const swiper = this;
75494  const {
75495    params
75496  } = swiper;
75497  swiper.onTouchStart = onTouchStart.bind(swiper);
75498  swiper.onTouchMove = onTouchMove.bind(swiper);
75499  swiper.onTouchEnd = onTouchEnd.bind(swiper);
75500  swiper.onDocumentTouchStart = onDocumentTouchStart.bind(swiper);
75501  if (params.cssMode) {
75502    swiper.onScroll = onScroll.bind(swiper);
75503  }
75504  swiper.onClick = onClick.bind(swiper);
75505  swiper.onLoad = onLoad.bind(swiper);
75506  events(swiper, "on");
75507}
75508function detachEvents() {
75509  const swiper = this;
75510  events(swiper, "off");
75511}
75512var events$1 = {
75513  attachEvents,
75514  detachEvents
75515};
75516var isGridEnabled = (swiper, params) => {
75517  return swiper.grid && params.grid && params.grid.rows > 1;
75518};
75519function setBreakpoint() {
75520  const swiper = this;
75521  const {
75522    realIndex,
75523    initialized,
75524    params,
75525    el
75526  } = swiper;
75527  const breakpoints2 = params.breakpoints;
75528  if (!breakpoints2 || breakpoints2 && Object.keys(breakpoints2).length === 0) return;
75529  const document2 = getDocument();
75530  const breakpointsBase = params.breakpointsBase === "window" || !params.breakpointsBase ? params.breakpointsBase : "container";
75531  const breakpointContainer = ["window", "container"].includes(params.breakpointsBase) || !params.breakpointsBase ? swiper.el : document2.querySelector(params.breakpointsBase);
75532  const breakpoint = swiper.getBreakpoint(breakpoints2, breakpointsBase, breakpointContainer);
75533  if (!breakpoint || swiper.currentBreakpoint === breakpoint) return;
75534  const breakpointOnlyParams = breakpoint in breakpoints2 ? breakpoints2[breakpoint] : void 0;
75535  const breakpointParams = breakpointOnlyParams || swiper.originalParams;
75536  const wasMultiRow = isGridEnabled(swiper, params);
75537  const isMultiRow = isGridEnabled(swiper, breakpointParams);
75538  const wasGrabCursor = swiper.params.grabCursor;
75539  const isGrabCursor = breakpointParams.grabCursor;
75540  const wasEnabled = params.enabled;
75541  if (wasMultiRow && !isMultiRow) {
75542    el.classList.remove(`${params.containerModifierClass}grid`, `${params.containerModifierClass}grid-column`);
75543    swiper.emitContainerClasses();
75544  } else if (!wasMultiRow && isMultiRow) {
75545    el.classList.add(`${params.containerModifierClass}grid`);
75546    if (breakpointParams.grid.fill && breakpointParams.grid.fill === "column" || !breakpointParams.grid.fill && params.grid.fill === "column") {
75547      el.classList.add(`${params.containerModifierClass}grid-column`);
75548    }
75549    swiper.emitContainerClasses();
75550  }
75551  if (wasGrabCursor && !isGrabCursor) {
75552    swiper.unsetGrabCursor();
75553  } else if (!wasGrabCursor && isGrabCursor) {
75554    swiper.setGrabCursor();
75555  }
75556  ["navigation", "pagination", "scrollbar"].forEach((prop) => {
75557    if (typeof breakpointParams[prop] === "undefined") return;
75558    const wasModuleEnabled = params[prop] && params[prop].enabled;
75559    const isModuleEnabled = breakpointParams[prop] && breakpointParams[prop].enabled;
75560    if (wasModuleEnabled && !isModuleEnabled) {
75561      swiper[prop].disable();
75562    }
75563    if (!wasModuleEnabled && isModuleEnabled) {
75564      swiper[prop].enable();
75565    }
75566  });
75567  const directionChanged = breakpointParams.direction && breakpointParams.direction !== params.direction;
75568  const needsReLoop = params.loop && (breakpointParams.slidesPerView !== params.slidesPerView || directionChanged);
75569  const wasLoop = params.loop;
75570  if (directionChanged && initialized) {
75571    swiper.changeDirection();
75572  }
75573  extend2(swiper.params, breakpointParams);
75574  const isEnabled = swiper.params.enabled;
75575  const hasLoop = swiper.params.loop;
75576  Object.assign(swiper, {
75577    allowTouchMove: swiper.params.allowTouchMove,
75578    allowSlideNext: swiper.params.allowSlideNext,
75579    allowSlidePrev: swiper.params.allowSlidePrev
75580  });
75581  if (wasEnabled && !isEnabled) {
75582    swiper.disable();
75583  } else if (!wasEnabled && isEnabled) {
75584    swiper.enable();
75585  }
75586  swiper.currentBreakpoint = breakpoint;
75587  swiper.emit("_beforeBreakpoint", breakpointParams);
75588  if (initialized) {
75589    if (needsReLoop) {
75590      swiper.loopDestroy();
75591      swiper.loopCreate(realIndex);
75592      swiper.updateSlides();
75593    } else if (!wasLoop && hasLoop) {
75594      swiper.loopCreate(realIndex);
75595      swiper.updateSlides();
75596    } else if (wasLoop && !hasLoop) {
75597      swiper.loopDestroy();
75598    }
75599  }
75600  swiper.emit("breakpoint", breakpointParams);
75601}
75602function getBreakpoint(breakpoints2, base, containerEl) {
75603  if (base === void 0) {
75604    base = "window";
75605  }
75606  if (!breakpoints2 || base === "container" && !containerEl) return void 0;
75607  let breakpoint = false;
75608  const window2 = getWindow();
75609  const currentHeight = base === "window" ? window2.innerHeight : containerEl.clientHeight;
75610  const points = Object.keys(breakpoints2).map((point) => {
75611    if (typeof point === "string" && point.indexOf("@") === 0) {
75612      const minRatio = parseFloat(point.substr(1));
75613      const value = currentHeight * minRatio;
75614      return {
75615        value,
75616        point
75617      };
75618    }
75619    return {
75620      value: point,
75621      point
75622    };
75623  });
75624  points.sort((a, b) => parseInt(a.value, 10) - parseInt(b.value, 10));
75625  for (let i = 0; i < points.length; i += 1) {
75626    const {
75627      point,
75628      value
75629    } = points[i];
75630    if (base === "window") {
75631      if (window2.matchMedia(`(min-width: ${value}px)`).matches) {
75632        breakpoint = point;
75633      }
75634    } else if (value <= containerEl.clientWidth) {
75635      breakpoint = point;
75636    }
75637  }
75638  return breakpoint || "max";
75639}
75640var breakpoints = {
75641  setBreakpoint,
75642  getBreakpoint
75643};
75644function prepareClasses(entries, prefix) {
75645  const resultClasses = [];
75646  entries.forEach((item) => {
75647    if (typeof item === "object") {
75648      Object.keys(item).forEach((classNames) => {
75649        if (item[classNames]) {
75650          resultClasses.push(prefix + classNames);
75651        }
75652      });
75653    } else if (typeof item === "string") {
75654      resultClasses.push(prefix + item);
75655    }
75656  });
75657  return resultClasses;
75658}
75659function addClasses() {
75660  const swiper = this;
75661  const {
75662    classNames,
75663    params,
75664    rtl,
75665    el,
75666    device
75667  } = swiper;
75668  const suffixes = prepareClasses(["initialized", params.direction, {
75669    "free-mode": swiper.params.freeMode && params.freeMode.enabled
75670  }, {
75671    "autoheight": params.autoHeight
75672  }, {
75673    "rtl": rtl
75674  }, {
75675    "grid": params.grid && params.grid.rows > 1
75676  }, {
75677    "grid-column": params.grid && params.grid.rows > 1 && params.grid.fill === "column"
75678  }, {
75679    "android": device.android
75680  }, {
75681    "ios": device.ios
75682  }, {
75683    "css-mode": params.cssMode
75684  }, {
75685    "centered": params.cssMode && params.centeredSlides
75686  }, {
75687    "watch-progress": params.watchSlidesProgress
75688  }], params.containerModifierClass);
75689  classNames.push(...suffixes);
75690  el.classList.add(...classNames);
75691  swiper.emitContainerClasses();
75692}
75693function removeClasses() {
75694  const swiper = this;
75695  const {
75696    el,
75697    classNames
75698  } = swiper;
75699  if (!el || typeof el === "string") return;
75700  el.classList.remove(...classNames);
75701  swiper.emitContainerClasses();
75702}
75703var classes = {
75704  addClasses,
75705  removeClasses
75706};
75707function checkOverflow() {
75708  const swiper = this;
75709  const {
75710    isLocked: wasLocked,
75711    params
75712  } = swiper;
75713  const {
75714    slidesOffsetBefore
75715  } = params;
75716  if (slidesOffsetBefore) {
75717    const lastSlideIndex = swiper.slides.length - 1;
75718    const lastSlideRightEdge = swiper.slidesGrid[lastSlideIndex] + swiper.slidesSizesGrid[lastSlideIndex] + slidesOffsetBefore * 2;
75719    swiper.isLocked = swiper.size > lastSlideRightEdge;
75720  } else {
75721    swiper.isLocked = swiper.snapGrid.length === 1;
75722  }
75723  if (params.allowSlideNext === true) {
75724    swiper.allowSlideNext = !swiper.isLocked;
75725  }
75726  if (params.allowSlidePrev === true) {
75727    swiper.allowSlidePrev = !swiper.isLocked;
75728  }
75729  if (wasLocked && wasLocked !== swiper.isLocked) {
75730    swiper.isEnd = false;
75731  }
75732  if (wasLocked !== swiper.isLocked) {
75733    swiper.emit(swiper.isLocked ? "lock" : "unlock");
75734  }
75735}
75736var checkOverflow$1 = {
75737  checkOverflow
75738};
75739var defaults = {
75740  init: true,
75741  direction: "horizontal",
75742  oneWayMovement: false,
75743  swiperElementNodeName: "SWIPER-CONTAINER",
75744  touchEventsTarget: "wrapper",
75745  initialSlide: 0,
75746  speed: 300,
75747  cssMode: false,
75748  updateOnWindowResize: true,
75749  resizeObserver: true,
75750  nested: false,
75751  createElements: false,
75752  eventsPrefix: "swiper",
75753  enabled: true,
75754  focusableElements: "input, select, option, textarea, button, video, label",
75755  // Overrides
75756  width: null,
75757  height: null,
75758  //
75759  preventInteractionOnTransition: false,
75760  // ssr
75761  userAgent: null,
75762  url: null,
75763  // To support iOS's swipe-to-go-back gesture (when being used in-app).
75764  edgeSwipeDetection: false,
75765  edgeSwipeThreshold: 20,
75766  // Autoheight
75767  autoHeight: false,
75768  // Set wrapper width
75769  setWrapperSize: false,
75770  // Virtual Translate
75771  virtualTranslate: false,
75772  // Effects
75773  effect: "slide",
75774  // 'slide' or 'fade' or 'cube' or 'coverflow' or 'flip'
75775  // Breakpoints
75776  breakpoints: void 0,
75777  breakpointsBase: "window",
75778  // Slides grid
75779  spaceBetween: 0,
75780  slidesPerView: 1,
75781  slidesPerGroup: 1,
75782  slidesPerGroupSkip: 0,
75783  slidesPerGroupAuto: false,
75784  centeredSlides: false,
75785  centeredSlidesBounds: false,
75786  slidesOffsetBefore: 0,
75787  // in px
75788  slidesOffsetAfter: 0,
75789  // in px
75790  normalizeSlideIndex: true,
75791  centerInsufficientSlides: false,
75792  // Disable swiper and hide navigation when container not overflow
75793  watchOverflow: true,
75794  // Round length
75795  roundLengths: false,
75796  // Touches
75797  touchRatio: 1,
75798  touchAngle: 45,
75799  simulateTouch: true,
75800  shortSwipes: true,
75801  longSwipes: true,
75802  longSwipesRatio: 0.5,
75803  longSwipesMs: 300,
75804  followFinger: true,
75805  allowTouchMove: true,
75806  threshold: 5,
75807  touchMoveStopPropagation: false,
75808  touchStartPreventDefault: true,
75809  touchStartForcePreventDefault: false,
75810  touchReleaseOnEdges: false,
75811  // Unique Navigation Elements
75812  uniqueNavElements: true,
75813  // Resistance
75814  resistance: true,
75815  resistanceRatio: 0.85,
75816  // Progress
75817  watchSlidesProgress: false,
75818  // Cursor
75819  grabCursor: false,
75820  // Clicks
75821  preventClicks: true,
75822  preventClicksPropagation: true,
75823  slideToClickedSlide: false,
75824  // loop
75825  loop: false,
75826  loopAddBlankSlides: true,
75827  loopAdditionalSlides: 0,
75828  loopPreventsSliding: true,
75829  // rewind
75830  rewind: false,
75831  // Swiping/no swiping
75832  allowSlidePrev: true,
75833  allowSlideNext: true,
75834  swipeHandler: null,
75835  // '.swipe-handler',
75836  noSwiping: true,
75837  noSwipingClass: "swiper-no-swiping",
75838  noSwipingSelector: null,
75839  // Passive Listeners
75840  passiveListeners: true,
75841  maxBackfaceHiddenSlides: 10,
75842  // NS
75843  containerModifierClass: "swiper-",
75844  // NEW
75845  slideClass: "swiper-slide",
75846  slideBlankClass: "swiper-slide-blank",
75847  slideActiveClass: "swiper-slide-active",
75848  slideVisibleClass: "swiper-slide-visible",
75849  slideFullyVisibleClass: "swiper-slide-fully-visible",
75850  slideNextClass: "swiper-slide-next",
75851  slidePrevClass: "swiper-slide-prev",
75852  wrapperClass: "swiper-wrapper",
75853  lazyPreloaderClass: "swiper-lazy-preloader",
75854  lazyPreloadPrevNext: 0,
75855  // Callbacks
75856  runCallbacksOnInit: true,
75857  // Internals
75858  _emitClasses: false
75859};
75860function moduleExtendParams(params, allModulesParams) {
75861  return function extendParams(obj) {
75862    if (obj === void 0) {
75863      obj = {};
75864    }
75865    const moduleParamName = Object.keys(obj)[0];
75866    const moduleParams = obj[moduleParamName];
75867    if (typeof moduleParams !== "object" || moduleParams === null) {
75868      extend2(allModulesParams, obj);
75869      return;
75870    }
75871    if (params[moduleParamName] === true) {
75872      params[moduleParamName] = {
75873        enabled: true
75874      };
75875    }
75876    if (moduleParamName === "navigation" && params[moduleParamName] && params[moduleParamName].enabled && !params[moduleParamName].prevEl && !params[moduleParamName].nextEl) {
75877      params[moduleParamName].auto = true;
75878    }
75879    if (["pagination", "scrollbar"].indexOf(moduleParamName) >= 0 && params[moduleParamName] && params[moduleParamName].enabled && !params[moduleParamName].el) {
75880      params[moduleParamName].auto = true;
75881    }
75882    if (!(moduleParamName in params && "enabled" in moduleParams)) {
75883      extend2(allModulesParams, obj);
75884      return;
75885    }
75886    if (typeof params[moduleParamName] === "object" && !("enabled" in params[moduleParamName])) {
75887      params[moduleParamName].enabled = true;
75888    }
75889    if (!params[moduleParamName]) params[moduleParamName] = {
75890      enabled: false
75891    };
75892    extend2(allModulesParams, obj);
75893  };
75894}
75895var prototypes = {
75896  eventsEmitter,
75897  update,
75898  translate,
75899  transition,
75900  slide,
75901  loop,
75902  grabCursor,
75903  events: events$1,
75904  breakpoints,
75905  checkOverflow: checkOverflow$1,
75906  classes
75907};
75908var extendedDefaults = {};
75909var Swiper = class _Swiper {
75910  constructor() {
75911    let el;
75912    let params;
75913    for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
75914      args[_key] = arguments[_key];
75915    }
75916    if (args.length === 1 && args[0].constructor && Object.prototype.toString.call(args[0]).slice(8, -1) === "Object") {
75917      params = args[0];
75918    } else {
75919      [el, params] = args;
75920    }
75921    if (!params) params = {};
75922    params = extend2({}, params);
75923    if (el && !params.el) params.el = el;
75924    const document2 = getDocument();
75925    if (params.el && typeof params.el === "string" && document2.querySelectorAll(params.el).length > 1) {
75926      const swipers = [];
75927      document2.querySelectorAll(params.el).forEach((containerEl) => {
75928        const newParams = extend2({}, params, {
75929          el: containerEl
75930        });
75931        swipers.push(new _Swiper(newParams));
75932      });
75933      return swipers;
75934    }
75935    const swiper = this;
75936    swiper.__swiper__ = true;
75937    swiper.support = getSupport();
75938    swiper.device = getDevice({
75939      userAgent: params.userAgent
75940    });
75941    swiper.browser = getBrowser();
75942    swiper.eventsListeners = {};
75943    swiper.eventsAnyListeners = [];
75944    swiper.modules = [...swiper.__modules__];
75945    if (params.modules && Array.isArray(params.modules)) {
75946      swiper.modules.push(...params.modules);
75947    }
75948    const allModulesParams = {};
75949    swiper.modules.forEach((mod) => {
75950      mod({
75951        params,
75952        swiper,
75953        extendParams: moduleExtendParams(params, allModulesParams),
75954        on: swiper.on.bind(swiper),
75955        once: swiper.once.bind(swiper),
75956        off: swiper.off.bind(swiper),
75957        emit: swiper.emit.bind(swiper)
75958      });
75959    });
75960    const swiperParams = extend2({}, defaults, allModulesParams);
75961    swiper.params = extend2({}, swiperParams, extendedDefaults, params);
75962    swiper.originalParams = extend2({}, swiper.params);
75963    swiper.passedParams = extend2({}, params);
75964    if (swiper.params && swiper.params.on) {
75965      Object.keys(swiper.params.on).forEach((eventName) => {
75966        swiper.on(eventName, swiper.params.on[eventName]);
75967      });
75968    }
75969    if (swiper.params && swiper.params.onAny) {
75970      swiper.onAny(swiper.params.onAny);
75971    }
75972    Object.assign(swiper, {
75973      enabled: swiper.params.enabled,
75974      el,
75975      // Classes
75976      classNames: [],
75977      // Slides
75978      slides: [],
75979      slidesGrid: [],
75980      snapGrid: [],
75981      slidesSizesGrid: [],
75982      // isDirection
75983      isHorizontal() {
75984        return swiper.params.direction === "horizontal";
75985      },
75986      isVertical() {
75987        return swiper.params.direction === "vertical";
75988      },
75989      // Indexes
75990      activeIndex: 0,
75991      realIndex: 0,
75992      //
75993      isBeginning: true,
75994      isEnd: false,
75995      // Props
75996      translate: 0,
75997      previousTranslate: 0,
75998      progress: 0,
75999      velocity: 0,
76000      animating: false,
76001      cssOverflowAdjustment() {
76002        return Math.trunc(this.translate / 2 ** 23) * 2 ** 23;
76003      },
76004      // Locks
76005      allowSlideNext: swiper.params.allowSlideNext,
76006      allowSlidePrev: swiper.params.allowSlidePrev,
76007      // Touch Events
76008      touchEventsData: {
76009        isTouched: void 0,
76010        isMoved: void 0,
76011        allowTouchCallbacks: void 0,
76012        touchStartTime: void 0,
76013        isScrolling: void 0,
76014        currentTranslate: void 0,
76015        startTranslate: void 0,
76016        allowThresholdMove: void 0,
76017        // Form elements to match
76018        focusableElements: swiper.params.focusableElements,
76019        // Last click time
76020        lastClickTime: 0,
76021        clickTimeout: void 0,
76022        // Velocities
76023        velocities: [],
76024        allowMomentumBounce: void 0,
76025        startMoving: void 0,
76026        pointerId: null,
76027        touchId: null
76028      },
76029      // Clicks
76030      allowClick: true,
76031      // Touches
76032      allowTouchMove: swiper.params.allowTouchMove,
76033      touches: {
76034        startX: 0,
76035        startY: 0,
76036        currentX: 0,
76037        currentY: 0,
76038        diff: 0
76039      },
76040      // Images
76041      imagesToLoad: [],
76042      imagesLoaded: 0
76043    });
76044    swiper.emit("_swiper");
76045    if (swiper.params.init) {
76046      swiper.init();
76047    }
76048    return swiper;
76049  }
76050  getDirectionLabel(property) {
76051    if (this.isHorizontal()) {
76052      return property;
76053    }
76054    return {
76055      "width": "height",
76056      "margin-top": "margin-left",
76057      "margin-bottom ": "margin-right",
76058      "margin-left": "margin-top",
76059      "margin-right": "margin-bottom",
76060      "padding-left": "padding-top",
76061      "padding-right": "padding-bottom",
76062      "marginRight": "marginBottom"
76063    }[property];
76064  }
76065  getSlideIndex(slideEl) {
76066    const {
76067      slidesEl,
76068      params
76069    } = this;
76070    const slides = elementChildren(slidesEl, `.${params.slideClass}, swiper-slide`);
76071    const firstSlideIndex = elementIndex(slides[0]);
76072    return elementIndex(slideEl) - firstSlideIndex;
76073  }
76074  getSlideIndexByData(index) {
76075    return this.getSlideIndex(this.slides.find((slideEl) => slideEl.getAttribute("data-swiper-slide-index") * 1 === index));
76076  }
76077  getSlideIndexWhenGrid(index) {
76078    if (this.grid && this.params.grid && this.params.grid.rows > 1) {
76079      if (this.params.grid.fill === "column") {
76080        index = Math.floor(index / this.params.grid.rows);
76081      } else if (this.params.grid.fill === "row") {
76082        index = index % Math.ceil(this.slides.length / this.params.grid.rows);
76083      }
76084    }
76085    return index;
76086  }
76087  recalcSlides() {
76088    const swiper = this;
76089    const {
76090      slidesEl,
76091      params
76092    } = swiper;
76093    swiper.slides = elementChildren(slidesEl, `.${params.slideClass}, swiper-slide`);
76094  }
76095  enable() {
76096    const swiper = this;
76097    if (swiper.enabled) return;
76098    swiper.enabled = true;
76099    if (swiper.params.grabCursor) {
76100      swiper.setGrabCursor();
76101    }
76102    swiper.emit("enable");
76103  }
76104  disable() {
76105    const swiper = this;
76106    if (!swiper.enabled) return;
76107    swiper.enabled = false;
76108    if (swiper.params.grabCursor) {
76109      swiper.unsetGrabCursor();
76110    }
76111    swiper.emit("disable");
76112  }
76113  setProgress(progress, speed) {
76114    const swiper = this;
76115    progress = Math.min(Math.max(progress, 0), 1);
76116    const min = swiper.minTranslate();
76117    const max = swiper.maxTranslate();
76118    const current = (max - min) * progress + min;
76119    swiper.translateTo(current, typeof speed === "undefined" ? 0 : speed);
76120    swiper.updateActiveIndex();
76121    swiper.updateSlidesClasses();
76122  }
76123  emitContainerClasses() {
76124    const swiper = this;
76125    if (!swiper.params._emitClasses || !swiper.el) return;
76126    const cls = swiper.el.className.split(" ").filter((className) => {
76127      return className.indexOf("swiper") === 0 || className.indexOf(swiper.params.containerModifierClass) === 0;
76128    });
76129    swiper.emit("_containerClasses", cls.join(" "));
76130  }
76131  getSlideClasses(slideEl) {
76132    const swiper = this;
76133    if (swiper.destroyed) return "";
76134    return slideEl.className.split(" ").filter((className) => {
76135      return className.indexOf("swiper-slide") === 0 || className.indexOf(swiper.params.slideClass) === 0;
76136    }).join(" ");
76137  }
76138  emitSlidesClasses() {
76139    const swiper = this;
76140    if (!swiper.params._emitClasses || !swiper.el) return;
76141    const updates = [];
76142    swiper.slides.forEach((slideEl) => {
76143      const classNames = swiper.getSlideClasses(slideEl);
76144      updates.push({
76145        slideEl,
76146        classNames
76147      });
76148      swiper.emit("_slideClass", slideEl, classNames);
76149    });
76150    swiper.emit("_slideClasses", updates);
76151  }
76152  slidesPerViewDynamic(view, exact) {
76153    if (view === void 0) {
76154      view = "current";
76155    }
76156    if (exact === void 0) {
76157      exact = false;
76158    }
76159    const swiper = this;
76160    const {
76161      params,
76162      slides,
76163      slidesGrid,
76164      slidesSizesGrid,
76165      size: swiperSize,
76166      activeIndex
76167    } = swiper;
76168    let spv = 1;
76169    if (typeof params.slidesPerView === "number") return params.slidesPerView;
76170    if (params.centeredSlides) {
76171      let slideSize = slides[activeIndex] ? Math.ceil(slides[activeIndex].swiperSlideSize) : 0;
76172      let breakLoop;
76173      for (let i = activeIndex + 1; i < slides.length; i += 1) {
76174        if (slides[i] && !breakLoop) {
76175          slideSize += Math.ceil(slides[i].swiperSlideSize);
76176          spv += 1;
76177          if (slideSize > swiperSize) breakLoop = true;
76178        }
76179      }
76180      for (let i = activeIndex - 1; i >= 0; i -= 1) {
76181        if (slides[i] && !breakLoop) {
76182          slideSize += slides[i].swiperSlideSize;
76183          spv += 1;
76184          if (slideSize > swiperSize) breakLoop = true;
76185        }
76186      }
76187    } else {
76188      if (view === "current") {
76189        for (let i = activeIndex + 1; i < slides.length; i += 1) {
76190          const slideInView = exact ? slidesGrid[i] + slidesSizesGrid[i] - slidesGrid[activeIndex] < swiperSize : slidesGrid[i] - slidesGrid[activeIndex] < swiperSize;
76191          if (slideInView) {
76192            spv += 1;
76193          }
76194        }
76195      } else {
76196        for (let i = activeIndex - 1; i >= 0; i -= 1) {
76197          const slideInView = slidesGrid[activeIndex] - slidesGrid[i] < swiperSize;
76198          if (slideInView) {
76199            spv += 1;
76200          }
76201        }
76202      }
76203    }
76204    return spv;
76205  }
76206  update() {
76207    const swiper = this;
76208    if (!swiper || swiper.destroyed) return;
76209    const {
76210      snapGrid,
76211      params
76212    } = swiper;
76213    if (params.breakpoints) {
76214      swiper.setBreakpoint();
76215    }
76216    [...swiper.el.querySelectorAll('[loading="lazy"]')].forEach((imageEl) => {
76217      if (imageEl.complete) {
76218        processLazyPreloader(swiper, imageEl);
76219      }
76220    });
76221    swiper.updateSize();
76222    swiper.updateSlides();
76223    swiper.updateProgress();
76224    swiper.updateSlidesClasses();
76225    function setTranslate2() {
76226      const translateValue = swiper.rtlTranslate ? swiper.translate * -1 : swiper.translate;
76227      const newTranslate = Math.min(Math.max(translateValue, swiper.maxTranslate()), swiper.minTranslate());
76228      swiper.setTranslate(newTranslate);
76229      swiper.updateActiveIndex();
76230      swiper.updateSlidesClasses();
76231    }
76232    let translated;
76233    if (params.freeMode && params.freeMode.enabled && !params.cssMode) {
76234      setTranslate2();
76235      if (params.autoHeight) {
76236        swiper.updateAutoHeight();
76237      }
76238    } else {
76239      if ((params.slidesPerView === "auto" || params.slidesPerView > 1) && swiper.isEnd && !params.centeredSlides) {
76240        const slides = swiper.virtual && params.virtual.enabled ? swiper.virtual.slides : swiper.slides;
76241        translated = swiper.slideTo(slides.length - 1, 0, false, true);
76242      } else {
76243        translated = swiper.slideTo(swiper.activeIndex, 0, false, true);
76244      }
76245      if (!translated) {
76246        setTranslate2();
76247      }
76248    }
76249    if (params.watchOverflow && snapGrid !== swiper.snapGrid) {
76250      swiper.checkOverflow();
76251    }
76252    swiper.emit("update");
76253  }
76254  changeDirection(newDirection, needUpdate) {
76255    if (needUpdate === void 0) {
76256      needUpdate = true;
76257    }
76258    const swiper = this;
76259    const currentDirection = swiper.params.direction;
76260    if (!newDirection) {
76261      newDirection = currentDirection === "horizontal" ? "vertical" : "horizontal";
76262    }
76263    if (newDirection === currentDirection || newDirection !== "horizontal" && newDirection !== "vertical") {
76264      return swiper;
76265    }
76266    swiper.el.classList.remove(`${swiper.params.containerModifierClass}${currentDirection}`);
76267    swiper.el.classList.add(`${swiper.params.containerModifierClass}${newDirection}`);
76268    swiper.emitContainerClasses();
76269    swiper.params.direction = newDirection;
76270    swiper.slides.forEach((slideEl) => {
76271      if (newDirection === "vertical") {
76272        slideEl.style.width = "";
76273      } else {
76274        slideEl.style.height = "";
76275      }
76276    });
76277    swiper.emit("changeDirection");
76278    if (needUpdate) swiper.update();
76279    return swiper;
76280  }
76281  changeLanguageDirection(direction) {
76282    const swiper = this;
76283    if (swiper.rtl && direction === "rtl" || !swiper.rtl && direction === "ltr") return;
76284    swiper.rtl = direction === "rtl";
76285    swiper.rtlTranslate = swiper.params.direction === "horizontal" && swiper.rtl;
76286    if (swiper.rtl) {
76287      swiper.el.classList.add(`${swiper.params.containerModifierClass}rtl`);
76288      swiper.el.dir = "rtl";
76289    } else {
76290      swiper.el.classList.remove(`${swiper.params.containerModifierClass}rtl`);
76291      swiper.el.dir = "ltr";
76292    }
76293    swiper.update();
76294  }
76295  mount(element) {
76296    const swiper = this;
76297    if (swiper.mounted) return true;
76298    let el = element || swiper.params.el;
76299    if (typeof el === "string") {
76300      el = document.querySelector(el);
76301    }
76302    if (!el) {
76303      return false;
76304    }
76305    el.swiper = swiper;
76306    if (el.parentNode && el.parentNode.host && el.parentNode.host.nodeName === swiper.params.swiperElementNodeName.toUpperCase()) {
76307      swiper.isElement = true;
76308    }
76309    const getWrapperSelector = () => {
76310      return `.${(swiper.params.wrapperClass || "").trim().split(" ").join(".")}`;
76311    };
76312    const getWrapper = () => {
76313      if (el && el.shadowRoot && el.shadowRoot.querySelector) {
76314        const res = el.shadowRoot.querySelector(getWrapperSelector());
76315        return res;
76316      }
76317      return elementChildren(el, getWrapperSelector())[0];
76318    };
76319    let wrapperEl = getWrapper();
76320    if (!wrapperEl && swiper.params.createElements) {
76321      wrapperEl = createElement("div", swiper.params.wrapperClass);
76322      el.append(wrapperEl);
76323      elementChildren(el, `.${swiper.params.slideClass}`).forEach((slideEl) => {
76324        wrapperEl.append(slideEl);
76325      });
76326    }
76327    Object.assign(swiper, {
76328      el,
76329      wrapperEl,
76330      slidesEl: swiper.isElement && !el.parentNode.host.slideSlots ? el.parentNode.host : wrapperEl,
76331      hostEl: swiper.isElement ? el.parentNode.host : el,
76332      mounted: true,
76333      // RTL
76334      rtl: el.dir.toLowerCase() === "rtl" || elementStyle(el, "direction") === "rtl",
76335      rtlTranslate: swiper.params.direction === "horizontal" && (el.dir.toLowerCase() === "rtl" || elementStyle(el, "direction") === "rtl"),
76336      wrongRTL: elementStyle(wrapperEl, "display") === "-webkit-box"
76337    });
76338    return true;
76339  }
76340  init(el) {
76341    const swiper = this;
76342    if (swiper.initialized) return swiper;
76343    const mounted = swiper.mount(el);
76344    if (mounted === false) return swiper;
76345    swiper.emit("beforeInit");
76346    if (swiper.params.breakpoints) {
76347      swiper.setBreakpoint();
76348    }
76349    swiper.addClasses();
76350    swiper.updateSize();
76351    swiper.updateSlides();
76352    if (swiper.params.watchOverflow) {
76353      swiper.checkOverflow();
76354    }
76355    if (swiper.params.grabCursor && swiper.enabled) {
76356      swiper.setGrabCursor();
76357    }
76358    if (swiper.params.loop && swiper.virtual && swiper.params.virtual.enabled) {
76359      swiper.slideTo(swiper.params.initialSlide + swiper.virtual.slidesBefore, 0, swiper.params.runCallbacksOnInit, false, true);
76360    } else {
76361      swiper.slideTo(swiper.params.initialSlide, 0, swiper.params.runCallbacksOnInit, false, true);
76362    }
76363    if (swiper.params.loop) {
76364      swiper.loopCreate(void 0, true);
76365    }
76366    swiper.attachEvents();
76367    const lazyElements = [...swiper.el.querySelectorAll('[loading="lazy"]')];
76368    if (swiper.isElement) {
76369      lazyElements.push(...swiper.hostEl.querySelectorAll('[loading="lazy"]'));
76370    }
76371    lazyElements.forEach((imageEl) => {
76372      if (imageEl.complete) {
76373        processLazyPreloader(swiper, imageEl);
76374      } else {
76375        imageEl.addEventListener("load", (e) => {
76376          processLazyPreloader(swiper, e.target);
76377        });
76378      }
76379    });
76380    preload(swiper);
76381    swiper.initialized = true;
76382    preload(swiper);
76383    swiper.emit("init");
76384    swiper.emit("afterInit");
76385    return swiper;
76386  }
76387  destroy(deleteInstance, cleanStyles) {
76388    if (deleteInstance === void 0) {
76389      deleteInstance = true;
76390    }
76391    if (cleanStyles === void 0) {
76392      cleanStyles = true;
76393    }
76394    const swiper = this;
76395    const {
76396      params,
76397      el,
76398      wrapperEl,
76399      slides
76400    } = swiper;
76401    if (typeof swiper.params === "undefined" || swiper.destroyed) {
76402      return null;
76403    }
76404    swiper.emit("beforeDestroy");
76405    swiper.initialized = false;
76406    swiper.detachEvents();
76407    if (params.loop) {
76408      swiper.loopDestroy();
76409    }
76410    if (cleanStyles) {
76411      swiper.removeClasses();
76412      if (el && typeof el !== "string") {
76413        el.removeAttribute("style");
76414      }
76415      if (wrapperEl) {
76416        wrapperEl.removeAttribute("style");
76417      }
76418      if (slides && slides.length) {
76419        slides.forEach((slideEl) => {
76420          slideEl.classList.remove(params.slideVisibleClass, params.slideFullyVisibleClass, params.slideActiveClass, params.slideNextClass, params.slidePrevClass);
76421          slideEl.removeAttribute("style");
76422          slideEl.removeAttribute("data-swiper-slide-index");
76423        });
76424      }
76425    }
76426    swiper.emit("destroy");
76427    Object.keys(swiper.eventsListeners).forEach((eventName) => {
76428      swiper.off(eventName);
76429    });
76430    if (deleteInstance !== false) {
76431      if (swiper.el && typeof swiper.el !== "string") {
76432        swiper.el.swiper = null;
76433      }
76434      deleteProps(swiper);
76435    }
76436    swiper.destroyed = true;
76437    return null;
76438  }
76439  static extendDefaults(newDefaults) {
76440    extend2(extendedDefaults, newDefaults);
76441  }
76442  static get extendedDefaults() {
76443    return extendedDefaults;
76444  }
76445  static get defaults() {
76446    return defaults;
76447  }
76448  static installModule(mod) {
76449    if (!_Swiper.prototype.__modules__) _Swiper.prototype.__modules__ = [];
76450    const modules2 = _Swiper.prototype.__modules__;
76451    if (typeof mod === "function" && modules2.indexOf(mod) < 0) {
76452      modules2.push(mod);
76453    }
76454  }
76455  static use(module) {
76456    if (Array.isArray(module)) {
76457      module.forEach((m) => _Swiper.installModule(m));
76458      return _Swiper;
76459    }
76460    _Swiper.installModule(module);
76461    return _Swiper;
76462  }
76463};
76464Object.keys(prototypes).forEach((prototypeGroup) => {
76465  Object.keys(prototypes[prototypeGroup]).forEach((protoMethod) => {
76466    Swiper.prototype[protoMethod] = prototypes[prototypeGroup][protoMethod];
76467  });
76468});
76469Swiper.use([Resize, Observer]);
76470
vendor: 11,439 bytes, lines 76471-76813
76471// node_modules/swiper/modules/virtual.mjs
76472function Virtual(_ref) {
76473  let {
76474    swiper,
76475    extendParams,
76476    on,
76477    emit
76478  } = _ref;
76479  extendParams({
76480    virtual: {
76481      enabled: false,
76482      slides: [],
76483      cache: true,
76484      renderSlide: null,
76485      renderExternal: null,
76486      renderExternalUpdate: true,
76487      addSlidesBefore: 0,
76488      addSlidesAfter: 0
76489    }
76490  });
76491  let cssModeTimeout;
76492  const document2 = getDocument();
76493  swiper.virtual = {
76494    cache: {},
76495    from: void 0,
76496    to: void 0,
76497    slides: [],
76498    offset: 0,
76499    slidesGrid: []
76500  };
76501  const tempDOM = document2.createElement("div");
76502  function renderSlide(slide2, index) {
76503    const params = swiper.params.virtual;
76504    if (params.cache && swiper.virtual.cache[index]) {
76505      return swiper.virtual.cache[index];
76506    }
76507    let slideEl;
76508    if (params.renderSlide) {
76509      slideEl = params.renderSlide.call(swiper, slide2, index);
76510      if (typeof slideEl === "string") {
76511        setInnerHTML(tempDOM, slideEl);
76512        slideEl = tempDOM.children[0];
76513      }
76514    } else if (swiper.isElement) {
76515      slideEl = createElement("swiper-slide");
76516    } else {
76517      slideEl = createElement("div", swiper.params.slideClass);
76518    }
76519    slideEl.setAttribute("data-swiper-slide-index", index);
76520    if (!params.renderSlide) {
76521      setInnerHTML(slideEl, slide2);
76522    }
76523    if (params.cache) {
76524      swiper.virtual.cache[index] = slideEl;
76525    }
76526    return slideEl;
76527  }
76528  function update2(force, beforeInit, forceActiveIndex) {
76529    const {
76530      slidesPerView,
76531      slidesPerGroup,
76532      centeredSlides,
76533      loop: isLoop,
76534      initialSlide
76535    } = swiper.params;
76536    if (beforeInit && !isLoop && initialSlide > 0) {
76537      return;
76538    }
76539    const {
76540      addSlidesBefore,
76541      addSlidesAfter
76542    } = swiper.params.virtual;
76543    const {
76544      from: previousFrom,
76545      to: previousTo,
76546      slides,
76547      slidesGrid: previousSlidesGrid,
76548      offset: previousOffset
76549    } = swiper.virtual;
76550    if (!swiper.params.cssMode) {
76551      swiper.updateActiveIndex();
76552    }
76553    const activeIndex = typeof forceActiveIndex === "undefined" ? swiper.activeIndex || 0 : forceActiveIndex;
76554    let offsetProp;
76555    if (swiper.rtlTranslate) offsetProp = "right";
76556    else offsetProp = swiper.isHorizontal() ? "left" : "top";
76557    let slidesAfter;
76558    let slidesBefore;
76559    if (centeredSlides) {
76560      slidesAfter = Math.floor(slidesPerView / 2) + slidesPerGroup + addSlidesAfter;
76561      slidesBefore = Math.floor(slidesPerView / 2) + slidesPerGroup + addSlidesBefore;
76562    } else {
76563      slidesAfter = slidesPerView + (slidesPerGroup - 1) + addSlidesAfter;
76564      slidesBefore = (isLoop ? slidesPerView : slidesPerGroup) + addSlidesBefore;
76565    }
76566    let from2 = activeIndex - slidesBefore;
76567    let to = activeIndex + slidesAfter;
76568    if (!isLoop) {
76569      from2 = Math.max(from2, 0);
76570      to = Math.min(to, slides.length - 1);
76571    }
76572    let offset = (swiper.slidesGrid[from2] || 0) - (swiper.slidesGrid[0] || 0);
76573    if (isLoop && activeIndex >= slidesBefore) {
76574      from2 -= slidesBefore;
76575      if (!centeredSlides) offset += swiper.slidesGrid[0];
76576    } else if (isLoop && activeIndex < slidesBefore) {
76577      from2 = -slidesBefore;
76578      if (centeredSlides) offset += swiper.slidesGrid[0];
76579    }
76580    Object.assign(swiper.virtual, {
76581      from: from2,
76582      to,
76583      offset,
76584      slidesGrid: swiper.slidesGrid,
76585      slidesBefore,
76586      slidesAfter
76587    });
76588    function onRendered() {
76589      swiper.updateSlides();
76590      swiper.updateProgress();
76591      swiper.updateSlidesClasses();
76592      emit("virtualUpdate");
76593    }
76594    if (previousFrom === from2 && previousTo === to && !force) {
76595      if (swiper.slidesGrid !== previousSlidesGrid && offset !== previousOffset) {
76596        swiper.slides.forEach((slideEl) => {
76597          slideEl.style[offsetProp] = `${offset - Math.abs(swiper.cssOverflowAdjustment())}px`;
76598        });
76599      }
76600      swiper.updateProgress();
76601      emit("virtualUpdate");
76602      return;
76603    }
76604    if (swiper.params.virtual.renderExternal) {
76605      swiper.params.virtual.renderExternal.call(swiper, {
76606        offset,
76607        from: from2,
76608        to,
76609        slides: function getSlides() {
76610          const slidesToRender = [];
76611          for (let i = from2; i <= to; i += 1) {
76612            slidesToRender.push(slides[i]);
76613          }
76614          return slidesToRender;
76615        }()
76616      });
76617      if (swiper.params.virtual.renderExternalUpdate) {
76618        onRendered();
76619      } else {
76620        emit("virtualUpdate");
76621      }
76622      return;
76623    }
76624    const prependIndexes = [];
76625    const appendIndexes = [];
76626    const getSlideIndex = (index) => {
76627      let slideIndex = index;
76628      if (index < 0) {
76629        slideIndex = slides.length + index;
76630      } else if (slideIndex >= slides.length) {
76631        slideIndex = slideIndex - slides.length;
76632      }
76633      return slideIndex;
76634    };
76635    if (force) {
76636      swiper.slides.filter((el) => el.matches(`.${swiper.params.slideClass}, swiper-slide`)).forEach((slideEl) => {
76637        slideEl.remove();
76638      });
76639    } else {
76640      for (let i = previousFrom; i <= previousTo; i += 1) {
76641        if (i < from2 || i > to) {
76642          const slideIndex = getSlideIndex(i);
76643          swiper.slides.filter((el) => el.matches(`.${swiper.params.slideClass}[data-swiper-slide-index="${slideIndex}"], swiper-slide[data-swiper-slide-index="${slideIndex}"]`)).forEach((slideEl) => {
76644            slideEl.remove();
76645          });
76646        }
76647      }
76648    }
76649    const loopFrom = isLoop ? -slides.length : 0;
76650    const loopTo = isLoop ? slides.length * 2 : slides.length;
76651    for (let i = loopFrom; i < loopTo; i += 1) {
76652      if (i >= from2 && i <= to) {
76653        const slideIndex = getSlideIndex(i);
76654        if (typeof previousTo === "undefined" || force) {
76655          appendIndexes.push(slideIndex);
76656        } else {
76657          if (i > previousTo) appendIndexes.push(slideIndex);
76658          if (i < previousFrom) prependIndexes.push(slideIndex);
76659        }
76660      }
76661    }
76662    appendIndexes.forEach((index) => {
76663      swiper.slidesEl.append(renderSlide(slides[index], index));
76664    });
76665    if (isLoop) {
76666      for (let i = prependIndexes.length - 1; i >= 0; i -= 1) {
76667        const index = prependIndexes[i];
76668        swiper.slidesEl.prepend(renderSlide(slides[index], index));
76669      }
76670    } else {
76671      prependIndexes.sort((a, b) => b - a);
76672      prependIndexes.forEach((index) => {
76673        swiper.slidesEl.prepend(renderSlide(slides[index], index));
76674      });
76675    }
76676    elementChildren(swiper.slidesEl, ".swiper-slide, swiper-slide").forEach((slideEl) => {
76677      slideEl.style[offsetProp] = `${offset - Math.abs(swiper.cssOverflowAdjustment())}px`;
76678    });
76679    onRendered();
76680  }
76681  function appendSlide2(slides) {
76682    if (typeof slides === "object" && "length" in slides) {
76683      for (let i = 0; i < slides.length; i += 1) {
76684        if (slides[i]) swiper.virtual.slides.push(slides[i]);
76685      }
76686    } else {
76687      swiper.virtual.slides.push(slides);
76688    }
76689    update2(true);
76690  }
76691  function prependSlide2(slides) {
76692    const activeIndex = swiper.activeIndex;
76693    let newActiveIndex = activeIndex + 1;
76694    let numberOfNewSlides = 1;
76695    if (Array.isArray(slides)) {
76696      for (let i = 0; i < slides.length; i += 1) {
76697        if (slides[i]) swiper.virtual.slides.unshift(slides[i]);
76698      }
76699      newActiveIndex = activeIndex + slides.length;
76700      numberOfNewSlides = slides.length;
76701    } else {
76702      swiper.virtual.slides.unshift(slides);
76703    }
76704    if (swiper.params.virtual.cache) {
76705      const cache = swiper.virtual.cache;
76706      const newCache = {};
76707      Object.keys(cache).forEach((cachedIndex) => {
76708        const cachedEl = cache[cachedIndex];
76709        const cachedElIndex = cachedEl.getAttribute("data-swiper-slide-index");
76710        if (cachedElIndex) {
76711          cachedEl.setAttribute("data-swiper-slide-index", parseInt(cachedElIndex, 10) + numberOfNewSlides);
76712        }
76713        newCache[parseInt(cachedIndex, 10) + numberOfNewSlides] = cachedEl;
76714      });
76715      swiper.virtual.cache = newCache;
76716    }
76717    update2(true);
76718    swiper.slideTo(newActiveIndex, 0);
76719  }
76720  function removeSlide2(slidesIndexes) {
76721    if (typeof slidesIndexes === "undefined" || slidesIndexes === null) return;
76722    let activeIndex = swiper.activeIndex;
76723    if (Array.isArray(slidesIndexes)) {
76724      for (let i = slidesIndexes.length - 1; i >= 0; i -= 1) {
76725        if (swiper.params.virtual.cache) {
76726          delete swiper.virtual.cache[slidesIndexes[i]];
76727          Object.keys(swiper.virtual.cache).forEach((key) => {
76728            if (key > slidesIndexes) {
76729              swiper.virtual.cache[key - 1] = swiper.virtual.cache[key];
76730              swiper.virtual.cache[key - 1].setAttribute("data-swiper-slide-index", key - 1);
76731              delete swiper.virtual.cache[key];
76732            }
76733          });
76734        }
76735        swiper.virtual.slides.splice(slidesIndexes[i], 1);
76736        if (slidesIndexes[i] < activeIndex) activeIndex -= 1;
76737        activeIndex = Math.max(activeIndex, 0);
76738      }
76739    } else {
76740      if (swiper.params.virtual.cache) {
76741        delete swiper.virtual.cache[slidesIndexes];
76742        Object.keys(swiper.virtual.cache).forEach((key) => {
76743          if (key > slidesIndexes) {
76744            swiper.virtual.cache[key - 1] = swiper.virtual.cache[key];
76745            swiper.virtual.cache[key - 1].setAttribute("data-swiper-slide-index", key - 1);
76746            delete swiper.virtual.cache[key];
76747          }
76748        });
76749      }
76750      swiper.virtual.slides.splice(slidesIndexes, 1);
76751      if (slidesIndexes < activeIndex) activeIndex -= 1;
76752      activeIndex = Math.max(activeIndex, 0);
76753    }
76754    update2(true);
76755    swiper.slideTo(activeIndex, 0);
76756  }
76757  function removeAllSlides2() {
76758    swiper.virtual.slides = [];
76759    if (swiper.params.virtual.cache) {
76760      swiper.virtual.cache = {};
76761    }
76762    update2(true);
76763    swiper.slideTo(0, 0);
76764  }
76765  on("beforeInit", () => {
76766    if (!swiper.params.virtual.enabled) return;
76767    let domSlidesAssigned;
76768    if (typeof swiper.passedParams.virtual.slides === "undefined") {
76769      const slides = [...swiper.slidesEl.children].filter((el) => el.matches(`.${swiper.params.slideClass}, swiper-slide`));
76770      if (slides && slides.length) {
76771        swiper.virtual.slides = [...slides];
76772        domSlidesAssigned = true;
76773        slides.forEach((slideEl, slideIndex) => {
76774          slideEl.setAttribute("data-swiper-slide-index", slideIndex);
76775          swiper.virtual.cache[slideIndex] = slideEl;
76776          slideEl.remove();
76777        });
76778      }
76779    }
76780    if (!domSlidesAssigned) {
76781      swiper.virtual.slides = swiper.params.virtual.slides;
76782    }
76783    swiper.classNames.push(`${swiper.params.containerModifierClass}virtual`);
76784    swiper.params.watchSlidesProgress = true;
76785    swiper.originalParams.watchSlidesProgress = true;
76786    update2(false, true);
76787  });
76788  on("setTranslate", () => {
76789    if (!swiper.params.virtual.enabled) return;
76790    if (swiper.params.cssMode && !swiper._immediateVirtual) {
76791      clearTimeout(cssModeTimeout);
76792      cssModeTimeout = setTimeout(() => {
76793        update2();
76794      }, 100);
76795    } else {
76796      update2();
76797    }
76798  });
76799  on("init update resize", () => {
76800    if (!swiper.params.virtual.enabled) return;
76801    if (swiper.params.cssMode) {
76802      setCSSProperty(swiper.wrapperEl, "--swiper-virtual-size", `${swiper.virtualSize}px`);
76803    }
76804  });
76805  Object.assign(swiper.virtual, {
76806    appendSlide: appendSlide2,
76807    prependSlide: prependSlide2,
76808    removeSlide: removeSlide2,
76809    removeAllSlides: removeAllSlides2,
76810    update: update2
76811  });
76812}
76813
vendor: 4,094 bytes, lines 76814-76926
76814// node_modules/swiper/modules/keyboard.mjs
76815function Keyboard(_ref) {
76816  let {
76817    swiper,
76818    extendParams,
76819    on,
76820    emit
76821  } = _ref;
76822  const document2 = getDocument();
76823  const window2 = getWindow();
76824  swiper.keyboard = {
76825    enabled: false
76826  };
76827  extendParams({
76828    keyboard: {
76829      enabled: false,
76830      onlyInViewport: true,
76831      pageUpDown: true
76832    }
76833  });
76834  function handle(event2) {
76835    if (!swiper.enabled) return;
76836    const {
76837      rtlTranslate: rtl
76838    } = swiper;
76839    let e = event2;
76840    if (e.originalEvent) e = e.originalEvent;
76841    const kc = e.keyCode || e.charCode;
76842    const pageUpDown = swiper.params.keyboard.pageUpDown;
76843    const isPageUp = pageUpDown && kc === 33;
76844    const isPageDown = pageUpDown && kc === 34;
76845    const isArrowLeft = kc === 37;
76846    const isArrowRight = kc === 39;
76847    const isArrowUp = kc === 38;
76848    const isArrowDown = kc === 40;
76849    if (!swiper.allowSlideNext && (swiper.isHorizontal() && isArrowRight || swiper.isVertical() && isArrowDown || isPageDown)) {
76850      return false;
76851    }
76852    if (!swiper.allowSlidePrev && (swiper.isHorizontal() && isArrowLeft || swiper.isVertical() && isArrowUp || isPageUp)) {
76853      return false;
76854    }
76855    if (e.shiftKey || e.altKey || e.ctrlKey || e.metaKey) {
76856      return void 0;
76857    }
76858    if (document2.activeElement && (document2.activeElement.isContentEditable || document2.activeElement.nodeName && (document2.activeElement.nodeName.toLowerCase() === "input" || document2.activeElement.nodeName.toLowerCase() === "textarea"))) {
76859      return void 0;
76860    }
76861    if (swiper.params.keyboard.onlyInViewport && (isPageUp || isPageDown || isArrowLeft || isArrowRight || isArrowUp || isArrowDown)) {
76862      let inView = false;
76863      if (elementParents(swiper.el, `.${swiper.params.slideClass}, swiper-slide`).length > 0 && elementParents(swiper.el, `.${swiper.params.slideActiveClass}`).length === 0) {
76864        return void 0;
76865      }
76866      const el = swiper.el;
76867      const swiperWidth = el.clientWidth;
76868      const swiperHeight = el.clientHeight;
76869      const windowWidth = window2.innerWidth;
76870      const windowHeight = window2.innerHeight;
76871      const swiperOffset = elementOffset(el);
76872      if (rtl) swiperOffset.left -= el.scrollLeft;
76873      const swiperCoord = [[swiperOffset.left, swiperOffset.top], [swiperOffset.left + swiperWidth, swiperOffset.top], [swiperOffset.left, swiperOffset.top + swiperHeight], [swiperOffset.left + swiperWidth, swiperOffset.top + swiperHeight]];
76874      for (let i = 0; i < swiperCoord.length; i += 1) {
76875        const point = swiperCoord[i];
76876        if (point[0] >= 0 && point[0] <= windowWidth && point[1] >= 0 && point[1] <= windowHeight) {
76877          if (point[0] === 0 && point[1] === 0) continue;
76878          inView = true;
76879        }
76880      }
76881      if (!inView) return void 0;
76882    }
76883    if (swiper.isHorizontal()) {
76884      if (isPageUp || isPageDown || isArrowLeft || isArrowRight) {
76885        if (e.preventDefault) e.preventDefault();
76886        else e.returnValue = false;
76887      }
76888      if ((isPageDown || isArrowRight) && !rtl || (isPageUp || isArrowLeft) && rtl) swiper.slideNext();
76889      if ((isPageUp || isArrowLeft) && !rtl || (isPageDown || isArrowRight) && rtl) swiper.slidePrev();
76890    } else {
76891      if (isPageUp || isPageDown || isArrowUp || isArrowDown) {
76892        if (e.preventDefault) e.preventDefault();
76893        else e.returnValue = false;
76894      }
76895      if (isPageDown || isArrowDown) swiper.slideNext();
76896      if (isPageUp || isArrowUp) swiper.slidePrev();
76897    }
76898    emit("keyPress", kc);
76899    return void 0;
76900  }
76901  function enable() {
76902    if (swiper.keyboard.enabled) return;
76903    document2.addEventListener("keydown", handle);
76904    swiper.keyboard.enabled = true;
76905  }
76906  function disable() {
76907    if (!swiper.keyboard.enabled) return;
76908    document2.removeEventListener("keydown", handle);
76909    swiper.keyboard.enabled = false;
76910  }
76911  on("init", () => {
76912    if (swiper.params.keyboard.enabled) {
76913      enable();
76914    }
76915  });
76916  on("destroy", () => {
76917    if (swiper.keyboard.enabled) {
76918      disable();
76919    }
76920  });
76921  Object.assign(swiper.keyboard, {
76922    enable,
76923    disable
76924  });
76925}
76926
vendor: 10,078 bytes, lines 76927-77227
76927// node_modules/swiper/modules/mousewheel.mjs
76928function Mousewheel(_ref) {
76929  let {
76930    swiper,
76931    extendParams,
76932    on,
76933    emit
76934  } = _ref;
76935  const window2 = getWindow();
76936  extendParams({
76937    mousewheel: {
76938      enabled: false,
76939      releaseOnEdges: false,
76940      invert: false,
76941      forceToAxis: false,
76942      sensitivity: 1,
76943      eventsTarget: "container",
76944      thresholdDelta: null,
76945      thresholdTime: null,
76946      noMousewheelClass: "swiper-no-mousewheel"
76947    }
76948  });
76949  swiper.mousewheel = {
76950    enabled: false
76951  };
76952  let timeout;
76953  let lastScrollTime = now();
76954  let lastEventBeforeSnap;
76955  const recentWheelEvents = [];
76956  function normalize(e) {
76957    const PIXEL_STEP = 10;
76958    const LINE_HEIGHT = 40;
76959    const PAGE_HEIGHT = 800;
76960    let sX = 0;
76961    let sY = 0;
76962    let pX = 0;
76963    let pY = 0;
76964    if ("detail" in e) {
76965      sY = e.detail;
76966    }
76967    if ("wheelDelta" in e) {
76968      sY = -e.wheelDelta / 120;
76969    }
76970    if ("wheelDeltaY" in e) {
76971      sY = -e.wheelDeltaY / 120;
76972    }
76973    if ("wheelDeltaX" in e) {
76974      sX = -e.wheelDeltaX / 120;
76975    }
76976    if ("axis" in e && e.axis === e.HORIZONTAL_AXIS) {
76977      sX = sY;
76978      sY = 0;
76979    }
76980    pX = sX * PIXEL_STEP;
76981    pY = sY * PIXEL_STEP;
76982    if ("deltaY" in e) {
76983      pY = e.deltaY;
76984    }
76985    if ("deltaX" in e) {
76986      pX = e.deltaX;
76987    }
76988    if (e.shiftKey && !pX) {
76989      pX = pY;
76990      pY = 0;
76991    }
76992    if ((pX || pY) && e.deltaMode) {
76993      if (e.deltaMode === 1) {
76994        pX *= LINE_HEIGHT;
76995        pY *= LINE_HEIGHT;
76996      } else {
76997        pX *= PAGE_HEIGHT;
76998        pY *= PAGE_HEIGHT;
76999      }
77000    }
77001    if (pX && !sX) {
77002      sX = pX < 1 ? -1 : 1;
77003    }
77004    if (pY && !sY) {
77005      sY = pY < 1 ? -1 : 1;
77006    }
77007    return {
77008      spinX: sX,
77009      spinY: sY,
77010      pixelX: pX,
77011      pixelY: pY
77012    };
77013  }
77014  function handleMouseEnter() {
77015    if (!swiper.enabled) return;
77016    swiper.mouseEntered = true;
77017  }
77018  function handleMouseLeave() {
77019    if (!swiper.enabled) return;
77020    swiper.mouseEntered = false;
77021  }
77022  function animateSlider(newEvent) {
77023    if (swiper.params.mousewheel.thresholdDelta && newEvent.delta < swiper.params.mousewheel.thresholdDelta) {
77024      return false;
77025    }
77026    if (swiper.params.mousewheel.thresholdTime && now() - lastScrollTime < swiper.params.mousewheel.thresholdTime) {
77027      return false;
77028    }
77029    if (newEvent.delta >= 6 && now() - lastScrollTime < 60) {
77030      return true;
77031    }
77032    if (newEvent.direction < 0) {
77033      if ((!swiper.isEnd || swiper.params.loop) && !swiper.animating) {
77034        swiper.slideNext();
77035        emit("scroll", newEvent.raw);
77036      }
77037    } else if ((!swiper.isBeginning || swiper.params.loop) && !swiper.animating) {
77038      swiper.slidePrev();
77039      emit("scroll", newEvent.raw);
77040    }
77041    lastScrollTime = new window2.Date().getTime();
77042    return false;
77043  }
77044  function releaseScroll(newEvent) {
77045    const params = swiper.params.mousewheel;
77046    if (newEvent.direction < 0) {
77047      if (swiper.isEnd && !swiper.params.loop && params.releaseOnEdges) {
77048        return true;
77049      }
77050    } else if (swiper.isBeginning && !swiper.params.loop && params.releaseOnEdges) {
77051      return true;
77052    }
77053    return false;
77054  }
77055  function handle(event2) {
77056    let e = event2;
77057    let disableParentSwiper = true;
77058    if (!swiper.enabled) return;
77059    if (event2.target.closest(`.${swiper.params.mousewheel.noMousewheelClass}`)) return;
77060    const params = swiper.params.mousewheel;
77061    if (swiper.params.cssMode) {
77062      e.preventDefault();
77063    }
77064    let targetEl = swiper.el;
77065    if (swiper.params.mousewheel.eventsTarget !== "container") {
77066      targetEl = document.querySelector(swiper.params.mousewheel.eventsTarget);
77067    }
77068    const targetElContainsTarget = targetEl && targetEl.contains(e.target);
77069    if (!swiper.mouseEntered && !targetElContainsTarget && !params.releaseOnEdges) return true;
77070    if (e.originalEvent) e = e.originalEvent;
77071    let delta = 0;
77072    const rtlFactor = swiper.rtlTranslate ? -1 : 1;
77073    const data = normalize(e);
77074    if (params.forceToAxis) {
77075      if (swiper.isHorizontal()) {
77076        if (Math.abs(data.pixelX) > Math.abs(data.pixelY)) delta = -data.pixelX * rtlFactor;
77077        else return true;
77078      } else if (Math.abs(data.pixelY) > Math.abs(data.pixelX)) delta = -data.pixelY;
77079      else return true;
77080    } else {
77081      delta = Math.abs(data.pixelX) > Math.abs(data.pixelY) ? -data.pixelX * rtlFactor : -data.pixelY;
77082    }
77083    if (delta === 0) return true;
77084    if (params.invert) delta = -delta;
77085    let positions = swiper.getTranslate() + delta * params.sensitivity;
77086    if (positions >= swiper.minTranslate()) positions = swiper.minTranslate();
77087    if (positions <= swiper.maxTranslate()) positions = swiper.maxTranslate();
77088    disableParentSwiper = swiper.params.loop ? true : !(positions === swiper.minTranslate() || positions === swiper.maxTranslate());
77089    if (disableParentSwiper && swiper.params.nested) e.stopPropagation();
77090    if (!swiper.params.freeMode || !swiper.params.freeMode.enabled) {
77091      const newEvent = {
77092        time: now(),
77093        delta: Math.abs(delta),
77094        direction: Math.sign(delta),
77095        raw: event2
77096      };
77097      if (recentWheelEvents.length >= 2) {
77098        recentWheelEvents.shift();
77099      }
77100      const prevEvent = recentWheelEvents.length ? recentWheelEvents[recentWheelEvents.length - 1] : void 0;
77101      recentWheelEvents.push(newEvent);
77102      if (prevEvent) {
77103        if (newEvent.direction !== prevEvent.direction || newEvent.delta > prevEvent.delta || newEvent.time > prevEvent.time + 150) {
77104          animateSlider(newEvent);
77105        }
77106      } else {
77107        animateSlider(newEvent);
77108      }
77109      if (releaseScroll(newEvent)) {
77110        return true;
77111      }
77112    } else {
77113      const newEvent = {
77114        time: now(),
77115        delta: Math.abs(delta),
77116        direction: Math.sign(delta)
77117      };
77118      const ignoreWheelEvents = lastEventBeforeSnap && newEvent.time < lastEventBeforeSnap.time + 500 && newEvent.delta <= lastEventBeforeSnap.delta && newEvent.direction === lastEventBeforeSnap.direction;
77119      if (!ignoreWheelEvents) {
77120        lastEventBeforeSnap = void 0;
77121        let position = swiper.getTranslate() + delta * params.sensitivity;
77122        const wasBeginning = swiper.isBeginning;
77123        const wasEnd = swiper.isEnd;
77124        if (position >= swiper.minTranslate()) position = swiper.minTranslate();
77125        if (position <= swiper.maxTranslate()) position = swiper.maxTranslate();
77126        swiper.setTransition(0);
77127        swiper.setTranslate(position);
77128        swiper.updateProgress();
77129        swiper.updateActiveIndex();
77130        swiper.updateSlidesClasses();
77131        if (!wasBeginning && swiper.isBeginning || !wasEnd && swiper.isEnd) {
77132          swiper.updateSlidesClasses();
77133        }
77134        if (swiper.params.loop) {
77135          swiper.loopFix({
77136            direction: newEvent.direction < 0 ? "next" : "prev",
77137            byMousewheel: true
77138          });
77139        }
77140        if (swiper.params.freeMode.sticky) {
77141          clearTimeout(timeout);
77142          timeout = void 0;
77143          if (recentWheelEvents.length >= 15) {
77144            recentWheelEvents.shift();
77145          }
77146          const prevEvent = recentWheelEvents.length ? recentWheelEvents[recentWheelEvents.length - 1] : void 0;
77147          const firstEvent = recentWheelEvents[0];
77148          recentWheelEvents.push(newEvent);
77149          if (prevEvent && (newEvent.delta > prevEvent.delta || newEvent.direction !== prevEvent.direction)) {
77150            recentWheelEvents.splice(0);
77151          } else if (recentWheelEvents.length >= 15 && newEvent.time - firstEvent.time < 500 && firstEvent.delta - newEvent.delta >= 1 && newEvent.delta <= 6) {
77152            const snapToThreshold = delta > 0 ? 0.8 : 0.2;
77153            lastEventBeforeSnap = newEvent;
77154            recentWheelEvents.splice(0);
77155            timeout = nextTick(() => {
77156              if (swiper.destroyed || !swiper.params) return;
77157              swiper.slideToClosest(swiper.params.speed, true, void 0, snapToThreshold);
77158            }, 0);
77159          }
77160          if (!timeout) {
77161            timeout = nextTick(() => {
77162              if (swiper.destroyed || !swiper.params) return;
77163              const snapToThreshold = 0.5;
77164              lastEventBeforeSnap = newEvent;
77165              recentWheelEvents.splice(0);
77166              swiper.slideToClosest(swiper.params.speed, true, void 0, snapToThreshold);
77167            }, 500);
77168          }
77169        }
77170        if (!ignoreWheelEvents) emit("scroll", e);
77171        if (swiper.params.autoplay && swiper.params.autoplay.disableOnInteraction) swiper.autoplay.stop();
77172        if (params.releaseOnEdges && (position === swiper.minTranslate() || position === swiper.maxTranslate())) {
77173          return true;
77174        }
77175      }
77176    }
77177    if (e.preventDefault) e.preventDefault();
77178    else e.returnValue = false;
77179    return false;
77180  }
77181  function events2(method) {
77182    let targetEl = swiper.el;
77183    if (swiper.params.mousewheel.eventsTarget !== "container") {
77184      targetEl = document.querySelector(swiper.params.mousewheel.eventsTarget);
77185    }
77186    targetEl[method]("mouseenter", handleMouseEnter);
77187    targetEl[method]("mouseleave", handleMouseLeave);
77188    targetEl[method]("wheel", handle);
77189  }
77190  function enable() {
77191    if (swiper.params.cssMode) {
77192      swiper.wrapperEl.removeEventListener("wheel", handle);
77193      return true;
77194    }
77195    if (swiper.mousewheel.enabled) return false;
77196    events2("addEventListener");
77197    swiper.mousewheel.enabled = true;
77198    return true;
77199  }
77200  function disable() {
77201    if (swiper.params.cssMode) {
77202      swiper.wrapperEl.addEventListener(event, handle);
77203      return true;
77204    }
77205    if (!swiper.mousewheel.enabled) return false;
77206    events2("removeEventListener");
77207    swiper.mousewheel.enabled = false;
77208    return true;
77209  }
77210  on("init", () => {
77211    if (!swiper.params.mousewheel.enabled && swiper.params.cssMode) {
77212      disable();
77213    }
77214    if (swiper.params.mousewheel.enabled) enable();
77215  });
77216  on("destroy", () => {
77217    if (swiper.params.cssMode) {
77218      enable();
77219    }
77220    if (swiper.mousewheel.enabled) disable();
77221  });
77222  Object.assign(swiper.mousewheel, {
77223    enable,
77224    disable
77225  });
77226}
77227
vendor: 643 bytes, lines 77228-77246
77228// node_modules/swiper/shared/create-element-if-not-defined.mjs
77229function createElementIfNotDefined(swiper, originalParams, params, checkProps) {
77230  if (swiper.params.createElements) {
77231    Object.keys(checkProps).forEach((key) => {
77232      if (!params[key] && params.auto === true) {
77233        let element = elementChildren(swiper.el, `.${checkProps[key]}`)[0];
77234        if (!element) {
77235          element = createElement("div", checkProps[key]);
77236          element.className = checkProps[key];
77237          swiper.el.append(element);
77238        }
77239        params[key] = element;
77240        originalParams[key] = element;
77241      }
77242    });
77243  }
77244  return params;
77245}
77246
vendor: 6,054 bytes, lines 77247-77440
77247// node_modules/swiper/modules/navigation.mjs
77248function Navigation(_ref) {
77249  let {
77250    swiper,
77251    extendParams,
77252    on,
77253    emit
77254  } = _ref;
77255  extendParams({
77256    navigation: {
77257      nextEl: null,
77258      prevEl: null,
77259      hideOnClick: false,
77260      disabledClass: "swiper-button-disabled",
77261      hiddenClass: "swiper-button-hidden",
77262      lockClass: "swiper-button-lock",
77263      navigationDisabledClass: "swiper-navigation-disabled"
77264    }
77265  });
77266  swiper.navigation = {
77267    nextEl: null,
77268    prevEl: null
77269  };
77270  function getEl(el) {
77271    let res;
77272    if (el && typeof el === "string" && swiper.isElement) {
77273      res = swiper.el.querySelector(el) || swiper.hostEl.querySelector(el);
77274      if (res) return res;
77275    }
77276    if (el) {
77277      if (typeof el === "string") res = [...document.querySelectorAll(el)];
77278      if (swiper.params.uniqueNavElements && typeof el === "string" && res && res.length > 1 && swiper.el.querySelectorAll(el).length === 1) {
77279        res = swiper.el.querySelector(el);
77280      } else if (res && res.length === 1) {
77281        res = res[0];
77282      }
77283    }
77284    if (el && !res) return el;
77285    return res;
77286  }
77287  function toggleEl(el, disabled) {
77288    const params = swiper.params.navigation;
77289    el = makeElementsArray(el);
77290    el.forEach((subEl) => {
77291      if (subEl) {
77292        subEl.classList[disabled ? "add" : "remove"](...params.disabledClass.split(" "));
77293        if (subEl.tagName === "BUTTON") subEl.disabled = disabled;
77294        if (swiper.params.watchOverflow && swiper.enabled) {
77295          subEl.classList[swiper.isLocked ? "add" : "remove"](params.lockClass);
77296        }
77297      }
77298    });
77299  }
77300  function update2() {
77301    const {
77302      nextEl,
77303      prevEl
77304    } = swiper.navigation;
77305    if (swiper.params.loop) {
77306      toggleEl(prevEl, false);
77307      toggleEl(nextEl, false);
77308      return;
77309    }
77310    toggleEl(prevEl, swiper.isBeginning && !swiper.params.rewind);
77311    toggleEl(nextEl, swiper.isEnd && !swiper.params.rewind);
77312  }
77313  function onPrevClick(e) {
77314    e.preventDefault();
77315    if (swiper.isBeginning && !swiper.params.loop && !swiper.params.rewind) return;
77316    swiper.slidePrev();
77317    emit("navigationPrev");
77318  }
77319  function onNextClick(e) {
77320    e.preventDefault();
77321    if (swiper.isEnd && !swiper.params.loop && !swiper.params.rewind) return;
77322    swiper.slideNext();
77323    emit("navigationNext");
77324  }
77325  function init() {
77326    const params = swiper.params.navigation;
77327    swiper.params.navigation = createElementIfNotDefined(swiper, swiper.originalParams.navigation, swiper.params.navigation, {
77328      nextEl: "swiper-button-next",
77329      prevEl: "swiper-button-prev"
77330    });
77331    if (!(params.nextEl || params.prevEl)) return;
77332    let nextEl = getEl(params.nextEl);
77333    let prevEl = getEl(params.prevEl);
77334    Object.assign(swiper.navigation, {
77335      nextEl,
77336      prevEl
77337    });
77338    nextEl = makeElementsArray(nextEl);
77339    prevEl = makeElementsArray(prevEl);
77340    const initButton = (el, dir) => {
77341      if (el) {
77342        el.addEventListener("click", dir === "next" ? onNextClick : onPrevClick);
77343      }
77344      if (!swiper.enabled && el) {
77345        el.classList.add(...params.lockClass.split(" "));
77346      }
77347    };
77348    nextEl.forEach((el) => initButton(el, "next"));
77349    prevEl.forEach((el) => initButton(el, "prev"));
77350  }
77351  function destroy() {
77352    let {
77353      nextEl,
77354      prevEl
77355    } = swiper.navigation;
77356    nextEl = makeElementsArray(nextEl);
77357    prevEl = makeElementsArray(prevEl);
77358    const destroyButton = (el, dir) => {
77359      el.removeEventListener("click", dir === "next" ? onNextClick : onPrevClick);
77360      el.classList.remove(...swiper.params.navigation.disabledClass.split(" "));
77361    };
77362    nextEl.forEach((el) => destroyButton(el, "next"));
77363    prevEl.forEach((el) => destroyButton(el, "prev"));
77364  }
77365  on("init", () => {
77366    if (swiper.params.navigation.enabled === false) {
77367      disable();
77368    } else {
77369      init();
77370      update2();
77371    }
77372  });
77373  on("toEdge fromEdge lock unlock", () => {
77374    update2();
77375  });
77376  on("destroy", () => {
77377    destroy();
77378  });
77379  on("enable disable", () => {
77380    let {
77381      nextEl,
77382      prevEl
77383    } = swiper.navigation;
77384    nextEl = makeElementsArray(nextEl);
77385    prevEl = makeElementsArray(prevEl);
77386    if (swiper.enabled) {
77387      update2();
77388      return;
77389    }
77390    [...nextEl, ...prevEl].filter((el) => !!el).forEach((el) => el.classList.add(swiper.params.navigation.lockClass));
77391  });
77392  on("click", (_s, e) => {
77393    let {
77394      nextEl,
77395      prevEl
77396    } = swiper.navigation;
77397    nextEl = makeElementsArray(nextEl);
77398    prevEl = makeElementsArray(prevEl);
77399    const targetEl = e.target;
77400    let targetIsButton = prevEl.includes(targetEl) || nextEl.includes(targetEl);
77401    if (swiper.isElement && !targetIsButton) {
77402      const path2 = e.path || e.composedPath && e.composedPath();
77403      if (path2) {
77404        targetIsButton = path2.find((pathEl) => nextEl.includes(pathEl) || prevEl.includes(pathEl));
77405      }
77406    }
77407    if (swiper.params.navigation.hideOnClick && !targetIsButton) {
77408      if (swiper.pagination && swiper.params.pagination && swiper.params.pagination.clickable && (swiper.pagination.el === targetEl || swiper.pagination.el.contains(targetEl))) return;
77409      let isHidden;
77410      if (nextEl.length) {
77411        isHidden = nextEl[0].classList.contains(swiper.params.navigation.hiddenClass);
77412      } else if (prevEl.length) {
77413        isHidden = prevEl[0].classList.contains(swiper.params.navigation.hiddenClass);
77414      }
77415      if (isHidden === true) {
77416        emit("navigationShow");
77417      } else {
77418        emit("navigationHide");
77419      }
77420      [...nextEl, ...prevEl].filter((el) => !!el).forEach((el) => el.classList.toggle(swiper.params.navigation.hiddenClass));
77421    }
77422  });
77423  const enable = () => {
77424    swiper.el.classList.remove(...swiper.params.navigation.navigationDisabledClass.split(" "));
77425    init();
77426    update2();
77427  };
77428  const disable = () => {
77429    swiper.el.classList.add(...swiper.params.navigation.navigationDisabledClass.split(" "));
77430    destroy();
77431  };
77432  Object.assign(swiper.navigation, {
77433    enable,
77434    disable,
77435    update: update2,
77436    init,
77437    destroy
77438  });
77439}
77440
vendor: 236 bytes, lines 77441-77448
77441// node_modules/swiper/shared/classes-to-selector.mjs
77442function classesToSelector(classes2) {
77443  if (classes2 === void 0) {
77444    classes2 = "";
77445  }
77446  return `.${classes2.trim().replace(/([\.:!+\/()[\]])/g, "\\$1").replace(/ /g, ".")}`;
77447}
77448
vendor: 17,022 bytes, lines 77449-77897
77449// node_modules/swiper/modules/pagination.mjs
77450function Pagination(_ref) {
77451  let {
77452    swiper,
77453    extendParams,
77454    on,
77455    emit
77456  } = _ref;
77457  const pfx = "swiper-pagination";
77458  extendParams({
77459    pagination: {
77460      el: null,
77461      bulletElement: "span",
77462      clickable: false,
77463      hideOnClick: false,
77464      renderBullet: null,
77465      renderProgressbar: null,
77466      renderFraction: null,
77467      renderCustom: null,
77468      progressbarOpposite: false,
77469      type: "bullets",
77470      // 'bullets' or 'progressbar' or 'fraction' or 'custom'
77471      dynamicBullets: false,
77472      dynamicMainBullets: 1,
77473      formatFractionCurrent: (number) => number,
77474      formatFractionTotal: (number) => number,
77475      bulletClass: `${pfx}-bullet`,
77476      bulletActiveClass: `${pfx}-bullet-active`,
77477      modifierClass: `${pfx}-`,
77478      currentClass: `${pfx}-current`,
77479      totalClass: `${pfx}-total`,
77480      hiddenClass: `${pfx}-hidden`,
77481      progressbarFillClass: `${pfx}-progressbar-fill`,
77482      progressbarOppositeClass: `${pfx}-progressbar-opposite`,
77483      clickableClass: `${pfx}-clickable`,
77484      lockClass: `${pfx}-lock`,
77485      horizontalClass: `${pfx}-horizontal`,
77486      verticalClass: `${pfx}-vertical`,
77487      paginationDisabledClass: `${pfx}-disabled`
77488    }
77489  });
77490  swiper.pagination = {
77491    el: null,
77492    bullets: []
77493  };
77494  let bulletSize;
77495  let dynamicBulletIndex = 0;
77496  function isPaginationDisabled() {
77497    return !swiper.params.pagination.el || !swiper.pagination.el || Array.isArray(swiper.pagination.el) && swiper.pagination.el.length === 0;
77498  }
77499  function setSideBullets(bulletEl, position) {
77500    const {
77501      bulletActiveClass
77502    } = swiper.params.pagination;
77503    if (!bulletEl) return;
77504    bulletEl = bulletEl[`${position === "prev" ? "previous" : "next"}ElementSibling`];
77505    if (bulletEl) {
77506      bulletEl.classList.add(`${bulletActiveClass}-${position}`);
77507      bulletEl = bulletEl[`${position === "prev" ? "previous" : "next"}ElementSibling`];
77508      if (bulletEl) {
77509        bulletEl.classList.add(`${bulletActiveClass}-${position}-${position}`);
77510      }
77511    }
77512  }
77513  function getMoveDirection(prevIndex, nextIndex, length) {
77514    prevIndex = prevIndex % length;
77515    nextIndex = nextIndex % length;
77516    if (nextIndex === prevIndex + 1) {
77517      return "next";
77518    } else if (nextIndex === prevIndex - 1) {
77519      return "previous";
77520    }
77521    return;
77522  }
77523  function onBulletClick(e) {
77524    const bulletEl = e.target.closest(classesToSelector(swiper.params.pagination.bulletClass));
77525    if (!bulletEl) {
77526      return;
77527    }
77528    e.preventDefault();
77529    const index = elementIndex(bulletEl) * swiper.params.slidesPerGroup;
77530    if (swiper.params.loop) {
77531      if (swiper.realIndex === index) return;
77532      const moveDirection = getMoveDirection(swiper.realIndex, index, swiper.slides.length);
77533      if (moveDirection === "next") {
77534        swiper.slideNext();
77535      } else if (moveDirection === "previous") {
77536        swiper.slidePrev();
77537      } else {
77538        swiper.slideToLoop(index);
77539      }
77540    } else {
77541      swiper.slideTo(index);
77542    }
77543  }
77544  function update2() {
77545    const rtl = swiper.rtl;
77546    const params = swiper.params.pagination;
77547    if (isPaginationDisabled()) return;
77548    let el = swiper.pagination.el;
77549    el = makeElementsArray(el);
77550    let current;
77551    let previousIndex;
77552    const slidesLength = swiper.virtual && swiper.params.virtual.enabled ? swiper.virtual.slides.length : swiper.slides.length;
77553    const total = swiper.params.loop ? Math.ceil(slidesLength / swiper.params.slidesPerGroup) : swiper.snapGrid.length;
77554    if (swiper.params.loop) {
77555      previousIndex = swiper.previousRealIndex || 0;
77556      current = swiper.params.slidesPerGroup > 1 ? Math.floor(swiper.realIndex / swiper.params.slidesPerGroup) : swiper.realIndex;
77557    } else if (typeof swiper.snapIndex !== "undefined") {
77558      current = swiper.snapIndex;
77559      previousIndex = swiper.previousSnapIndex;
77560    } else {
77561      previousIndex = swiper.previousIndex || 0;
77562      current = swiper.activeIndex || 0;
77563    }
77564    if (params.type === "bullets" && swiper.pagination.bullets && swiper.pagination.bullets.length > 0) {
77565      const bullets = swiper.pagination.bullets;
77566      let firstIndex;
77567      let lastIndex;
77568      let midIndex;
77569      if (params.dynamicBullets) {
77570        bulletSize = elementOuterSize(bullets[0], swiper.isHorizontal() ? "width" : "height", true);
77571        el.forEach((subEl) => {
77572          subEl.style[swiper.isHorizontal() ? "width" : "height"] = `${bulletSize * (params.dynamicMainBullets + 4)}px`;
77573        });
77574        if (params.dynamicMainBullets > 1 && previousIndex !== void 0) {
77575          dynamicBulletIndex += current - (previousIndex || 0);
77576          if (dynamicBulletIndex > params.dynamicMainBullets - 1) {
77577            dynamicBulletIndex = params.dynamicMainBullets - 1;
77578          } else if (dynamicBulletIndex < 0) {
77579            dynamicBulletIndex = 0;
77580          }
77581        }
77582        firstIndex = Math.max(current - dynamicBulletIndex, 0);
77583        lastIndex = firstIndex + (Math.min(bullets.length, params.dynamicMainBullets) - 1);
77584        midIndex = (lastIndex + firstIndex) / 2;
77585      }
77586      bullets.forEach((bulletEl) => {
77587        const classesToRemove = [...["", "-next", "-next-next", "-prev", "-prev-prev", "-main"].map((suffix) => `${params.bulletActiveClass}${suffix}`)].map((s) => typeof s === "string" && s.includes(" ") ? s.split(" ") : s).flat();
77588        bulletEl.classList.remove(...classesToRemove);
77589      });
77590      if (el.length > 1) {
77591        bullets.forEach((bullet2) => {
77592          const bulletIndex = elementIndex(bullet2);
77593          if (bulletIndex === current) {
77594            bullet2.classList.add(...params.bulletActiveClass.split(" "));
77595          } else if (swiper.isElement) {
77596            bullet2.setAttribute("part", "bullet");
77597          }
77598          if (params.dynamicBullets) {
77599            if (bulletIndex >= firstIndex && bulletIndex <= lastIndex) {
77600              bullet2.classList.add(...`${params.bulletActiveClass}-main`.split(" "));
77601            }
77602            if (bulletIndex === firstIndex) {
77603              setSideBullets(bullet2, "prev");
77604            }
77605            if (bulletIndex === lastIndex) {
77606              setSideBullets(bullet2, "next");
77607            }
77608          }
77609        });
77610      } else {
77611        const bullet2 = bullets[current];
77612        if (bullet2) {
77613          bullet2.classList.add(...params.bulletActiveClass.split(" "));
77614        }
77615        if (swiper.isElement) {
77616          bullets.forEach((bulletEl, bulletIndex) => {
77617            bulletEl.setAttribute("part", bulletIndex === current ? "bullet-active" : "bullet");
77618          });
77619        }
77620        if (params.dynamicBullets) {
77621          const firstDisplayedBullet = bullets[firstIndex];
77622          const lastDisplayedBullet = bullets[lastIndex];
77623          for (let i = firstIndex; i <= lastIndex; i += 1) {
77624            if (bullets[i]) {
77625              bullets[i].classList.add(...`${params.bulletActiveClass}-main`.split(" "));
77626            }
77627          }
77628          setSideBullets(firstDisplayedBullet, "prev");
77629          setSideBullets(lastDisplayedBullet, "next");
77630        }
77631      }
77632      if (params.dynamicBullets) {
77633        const dynamicBulletsLength = Math.min(bullets.length, params.dynamicMainBullets + 4);
77634        const bulletsOffset = (bulletSize * dynamicBulletsLength - bulletSize) / 2 - midIndex * bulletSize;
77635        const offsetProp = rtl ? "right" : "left";
77636        bullets.forEach((bullet2) => {
77637          bullet2.style[swiper.isHorizontal() ? offsetProp : "top"] = `${bulletsOffset}px`;
77638        });
77639      }
77640    }
77641    el.forEach((subEl, subElIndex) => {
77642      if (params.type === "fraction") {
77643        subEl.querySelectorAll(classesToSelector(params.currentClass)).forEach((fractionEl) => {
77644          fractionEl.textContent = params.formatFractionCurrent(current + 1);
77645        });
77646        subEl.querySelectorAll(classesToSelector(params.totalClass)).forEach((totalEl) => {
77647          totalEl.textContent = params.formatFractionTotal(total);
77648        });
77649      }
77650      if (params.type === "progressbar") {
77651        let progressbarDirection;
77652        if (params.progressbarOpposite) {
77653          progressbarDirection = swiper.isHorizontal() ? "vertical" : "horizontal";
77654        } else {
77655          progressbarDirection = swiper.isHorizontal() ? "horizontal" : "vertical";
77656        }
77657        const scale = (current + 1) / total;
77658        let scaleX = 1;
77659        let scaleY = 1;
77660        if (progressbarDirection === "horizontal") {
77661          scaleX = scale;
77662        } else {
77663          scaleY = scale;
77664        }
77665        subEl.querySelectorAll(classesToSelector(params.progressbarFillClass)).forEach((progressEl) => {
77666          progressEl.style.transform = `translate3d(0,0,0) scaleX(${scaleX}) scaleY(${scaleY})`;
77667          progressEl.style.transitionDuration = `${swiper.params.speed}ms`;
77668        });
77669      }
77670      if (params.type === "custom" && params.renderCustom) {
77671        setInnerHTML(subEl, params.renderCustom(swiper, current + 1, total));
77672        if (subElIndex === 0) emit("paginationRender", subEl);
77673      } else {
77674        if (subElIndex === 0) emit("paginationRender", subEl);
77675        emit("paginationUpdate", subEl);
77676      }
77677      if (swiper.params.watchOverflow && swiper.enabled) {
77678        subEl.classList[swiper.isLocked ? "add" : "remove"](params.lockClass);
77679      }
77680    });
77681  }
77682  function render3() {
77683    const params = swiper.params.pagination;
77684    if (isPaginationDisabled()) return;
77685    const slidesLength = swiper.virtual && swiper.params.virtual.enabled ? swiper.virtual.slides.length : swiper.grid && swiper.params.grid.rows > 1 ? swiper.slides.length / Math.ceil(swiper.params.grid.rows) : swiper.slides.length;
77686    let el = swiper.pagination.el;
77687    el = makeElementsArray(el);
77688    let paginationHTML = "";
77689    if (params.type === "bullets") {
77690      let numberOfBullets = swiper.params.loop ? Math.ceil(slidesLength / swiper.params.slidesPerGroup) : swiper.snapGrid.length;
77691      if (swiper.params.freeMode && swiper.params.freeMode.enabled && numberOfBullets > slidesLength) {
77692        numberOfBullets = slidesLength;
77693      }
77694      for (let i = 0; i < numberOfBullets; i += 1) {
77695        if (params.renderBullet) {
77696          paginationHTML += params.renderBullet.call(swiper, i, params.bulletClass);
77697        } else {
77698          paginationHTML += `<${params.bulletElement} ${swiper.isElement ? 'part="bullet"' : ""} class="${params.bulletClass}"></${params.bulletElement}>`;
77699        }
77700      }
77701    }
77702    if (params.type === "fraction") {
77703      if (params.renderFraction) {
77704        paginationHTML = params.renderFraction.call(swiper, params.currentClass, params.totalClass);
77705      } else {
77706        paginationHTML = `<span class="${params.currentClass}"></span> / <span class="${params.totalClass}"></span>`;
77707      }
77708    }
77709    if (params.type === "progressbar") {
77710      if (params.renderProgressbar) {
77711        paginationHTML = params.renderProgressbar.call(swiper, params.progressbarFillClass);
77712      } else {
77713        paginationHTML = `<span class="${params.progressbarFillClass}"></span>`;
77714      }
77715    }
77716    swiper.pagination.bullets = [];
77717    el.forEach((subEl) => {
77718      if (params.type !== "custom") {
77719        setInnerHTML(subEl, paginationHTML || "");
77720      }
77721      if (params.type === "bullets") {
77722        swiper.pagination.bullets.push(...subEl.querySelectorAll(classesToSelector(params.bulletClass)));
77723      }
77724    });
77725    if (params.type !== "custom") {
77726      emit("paginationRender", el[0]);
77727    }
77728  }
77729  function init() {
77730    swiper.params.pagination = createElementIfNotDefined(swiper, swiper.originalParams.pagination, swiper.params.pagination, {
77731      el: "swiper-pagination"
77732    });
77733    const params = swiper.params.pagination;
77734    if (!params.el) return;
77735    let el;
77736    if (typeof params.el === "string" && swiper.isElement) {
77737      el = swiper.el.querySelector(params.el);
77738    }
77739    if (!el && typeof params.el === "string") {
77740      el = [...document.querySelectorAll(params.el)];
77741    }
77742    if (!el) {
77743      el = params.el;
77744    }
77745    if (!el || el.length === 0) return;
77746    if (swiper.params.uniqueNavElements && typeof params.el === "string" && Array.isArray(el) && el.length > 1) {
77747      el = [...swiper.el.querySelectorAll(params.el)];
77748      if (el.length > 1) {
77749        el = el.find((subEl) => {
77750          if (elementParents(subEl, ".swiper")[0] !== swiper.el) return false;
77751          return true;
77752        });
77753      }
77754    }
77755    if (Array.isArray(el) && el.length === 1) el = el[0];
77756    Object.assign(swiper.pagination, {
77757      el
77758    });
77759    el = makeElementsArray(el);
77760    el.forEach((subEl) => {
77761      if (params.type === "bullets" && params.clickable) {
77762        subEl.classList.add(...(params.clickableClass || "").split(" "));
77763      }
77764      subEl.classList.add(params.modifierClass + params.type);
77765      subEl.classList.add(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass);
77766      if (params.type === "bullets" && params.dynamicBullets) {
77767        subEl.classList.add(`${params.modifierClass}${params.type}-dynamic`);
77768        dynamicBulletIndex = 0;
77769        if (params.dynamicMainBullets < 1) {
77770          params.dynamicMainBullets = 1;
77771        }
77772      }
77773      if (params.type === "progressbar" && params.progressbarOpposite) {
77774        subEl.classList.add(params.progressbarOppositeClass);
77775      }
77776      if (params.clickable) {
77777        subEl.addEventListener("click", onBulletClick);
77778      }
77779      if (!swiper.enabled) {
77780        subEl.classList.add(params.lockClass);
77781      }
77782    });
77783  }
77784  function destroy() {
77785    const params = swiper.params.pagination;
77786    if (isPaginationDisabled()) return;
77787    let el = swiper.pagination.el;
77788    if (el) {
77789      el = makeElementsArray(el);
77790      el.forEach((subEl) => {
77791        subEl.classList.remove(params.hiddenClass);
77792        subEl.classList.remove(params.modifierClass + params.type);
77793        subEl.classList.remove(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass);
77794        if (params.clickable) {
77795          subEl.classList.remove(...(params.clickableClass || "").split(" "));
77796          subEl.removeEventListener("click", onBulletClick);
77797        }
77798      });
77799    }
77800    if (swiper.pagination.bullets) swiper.pagination.bullets.forEach((subEl) => subEl.classList.remove(...params.bulletActiveClass.split(" ")));
77801  }
77802  on("changeDirection", () => {
77803    if (!swiper.pagination || !swiper.pagination.el) return;
77804    const params = swiper.params.pagination;
77805    let {
77806      el
77807    } = swiper.pagination;
77808    el = makeElementsArray(el);
77809    el.forEach((subEl) => {
77810      subEl.classList.remove(params.horizontalClass, params.verticalClass);
77811      subEl.classList.add(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass);
77812    });
77813  });
77814  on("init", () => {
77815    if (swiper.params.pagination.enabled === false) {
77816      disable();
77817    } else {
77818      init();
77819      render3();
77820      update2();
77821    }
77822  });
77823  on("activeIndexChange", () => {
77824    if (typeof swiper.snapIndex === "undefined") {
77825      update2();
77826    }
77827  });
77828  on("snapIndexChange", () => {
77829    update2();
77830  });
77831  on("snapGridLengthChange", () => {
77832    render3();
77833    update2();
77834  });
77835  on("destroy", () => {
77836    destroy();
77837  });
77838  on("enable disable", () => {
77839    let {
77840      el
77841    } = swiper.pagination;
77842    if (el) {
77843      el = makeElementsArray(el);
77844      el.forEach((subEl) => subEl.classList[swiper.enabled ? "remove" : "add"](swiper.params.pagination.lockClass));
77845    }
77846  });
77847  on("lock unlock", () => {
77848    update2();
77849  });
77850  on("click", (_s, e) => {
77851    const targetEl = e.target;
77852    const el = makeElementsArray(swiper.pagination.el);
77853    if (swiper.params.pagination.el && swiper.params.pagination.hideOnClick && el && el.length > 0 && !targetEl.classList.contains(swiper.params.pagination.bulletClass)) {
77854      if (swiper.navigation && (swiper.navigation.nextEl && targetEl === swiper.navigation.nextEl || swiper.navigation.prevEl && targetEl === swiper.navigation.prevEl)) return;
77855      const isHidden = el[0].classList.contains(swiper.params.pagination.hiddenClass);
77856      if (isHidden === true) {
77857        emit("paginationShow");
77858      } else {
77859        emit("paginationHide");
77860      }
77861      el.forEach((subEl) => subEl.classList.toggle(swiper.params.pagination.hiddenClass));
77862    }
77863  });
77864  const enable = () => {
77865    swiper.el.classList.remove(swiper.params.pagination.paginationDisabledClass);
77866    let {
77867      el
77868    } = swiper.pagination;
77869    if (el) {
77870      el = makeElementsArray(el);
77871      el.forEach((subEl) => subEl.classList.remove(swiper.params.pagination.paginationDisabledClass));
77872    }
77873    init();
77874    render3();
77875    update2();
77876  };
77877  const disable = () => {
77878    swiper.el.classList.add(swiper.params.pagination.paginationDisabledClass);
77879    let {
77880      el
77881    } = swiper.pagination;
77882    if (el) {
77883      el = makeElementsArray(el);
77884      el.forEach((subEl) => subEl.classList.add(swiper.params.pagination.paginationDisabledClass));
77885    }
77886    destroy();
77887  };
77888  Object.assign(swiper.pagination, {
77889    enable,
77890    disable,
77891    render: render3,
77892    update: update2,
77893    init,
77894    destroy
77895  });
77896}
77897
vendor: 10,679 bytes, lines 77898-78258
77898// node_modules/swiper/modules/scrollbar.mjs
77899function Scrollbar(_ref) {
77900  let {
77901    swiper,
77902    extendParams,
77903    on,
77904    emit
77905  } = _ref;
77906  const document2 = getDocument();
77907  let isTouched = false;
77908  let timeout = null;
77909  let dragTimeout = null;
77910  let dragStartPos;
77911  let dragSize;
77912  let trackSize;
77913  let divider;
77914  extendParams({
77915    scrollbar: {
77916      el: null,
77917      dragSize: "auto",
77918      hide: false,
77919      draggable: false,
77920      snapOnRelease: true,
77921      lockClass: "swiper-scrollbar-lock",
77922      dragClass: "swiper-scrollbar-drag",
77923      scrollbarDisabledClass: "swiper-scrollbar-disabled",
77924      horizontalClass: `swiper-scrollbar-horizontal`,
77925      verticalClass: `swiper-scrollbar-vertical`
77926    }
77927  });
77928  swiper.scrollbar = {
77929    el: null,
77930    dragEl: null
77931  };
77932  function setTranslate2() {
77933    if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) return;
77934    const {
77935      scrollbar,
77936      rtlTranslate: rtl
77937    } = swiper;
77938    const {
77939      dragEl,
77940      el
77941    } = scrollbar;
77942    const params = swiper.params.scrollbar;
77943    const progress = swiper.params.loop ? swiper.progressLoop : swiper.progress;
77944    let newSize = dragSize;
77945    let newPos = (trackSize - dragSize) * progress;
77946    if (rtl) {
77947      newPos = -newPos;
77948      if (newPos > 0) {
77949        newSize = dragSize - newPos;
77950        newPos = 0;
77951      } else if (-newPos + dragSize > trackSize) {
77952        newSize = trackSize + newPos;
77953      }
77954    } else if (newPos < 0) {
77955      newSize = dragSize + newPos;
77956      newPos = 0;
77957    } else if (newPos + dragSize > trackSize) {
77958      newSize = trackSize - newPos;
77959    }
77960    if (swiper.isHorizontal()) {
77961      dragEl.style.transform = `translate3d(${newPos}px, 0, 0)`;
77962      dragEl.style.width = `${newSize}px`;
77963    } else {
77964      dragEl.style.transform = `translate3d(0px, ${newPos}px, 0)`;
77965      dragEl.style.height = `${newSize}px`;
77966    }
77967    if (params.hide) {
77968      clearTimeout(timeout);
77969      el.style.opacity = 1;
77970      timeout = setTimeout(() => {
77971        el.style.opacity = 0;
77972        el.style.transitionDuration = "400ms";
77973      }, 1e3);
77974    }
77975  }
77976  function setTransition2(duration) {
77977    if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) return;
77978    swiper.scrollbar.dragEl.style.transitionDuration = `${duration}ms`;
77979  }
77980  function updateSize2() {
77981    if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) return;
77982    const {
77983      scrollbar
77984    } = swiper;
77985    const {
77986      dragEl,
77987      el
77988    } = scrollbar;
77989    dragEl.style.width = "";
77990    dragEl.style.height = "";
77991    trackSize = swiper.isHorizontal() ? el.offsetWidth : el.offsetHeight;
77992    divider = swiper.size / (swiper.virtualSize + swiper.params.slidesOffsetBefore - (swiper.params.centeredSlides ? swiper.snapGrid[0] : 0));
77993    if (swiper.params.scrollbar.dragSize === "auto") {
77994      dragSize = trackSize * divider;
77995    } else {
77996      dragSize = parseInt(swiper.params.scrollbar.dragSize, 10);
77997    }
77998    if (swiper.isHorizontal()) {
77999      dragEl.style.width = `${dragSize}px`;
78000    } else {
78001      dragEl.style.height = `${dragSize}px`;
78002    }
78003    if (divider >= 1) {
78004      el.style.display = "none";
78005    } else {
78006      el.style.display = "";
78007    }
78008    if (swiper.params.scrollbar.hide) {
78009      el.style.opacity = 0;
78010    }
78011    if (swiper.params.watchOverflow && swiper.enabled) {
78012      scrollbar.el.classList[swiper.isLocked ? "add" : "remove"](swiper.params.scrollbar.lockClass);
78013    }
78014  }
78015  function getPointerPosition(e) {
78016    return swiper.isHorizontal() ? e.clientX : e.clientY;
78017  }
78018  function setDragPosition(e) {
78019    const {
78020      scrollbar,
78021      rtlTranslate: rtl
78022    } = swiper;
78023    const {
78024      el
78025    } = scrollbar;
78026    let positionRatio;
78027    positionRatio = (getPointerPosition(e) - elementOffset(el)[swiper.isHorizontal() ? "left" : "top"] - (dragStartPos !== null ? dragStartPos : dragSize / 2)) / (trackSize - dragSize);
78028    positionRatio = Math.max(Math.min(positionRatio, 1), 0);
78029    if (rtl) {
78030      positionRatio = 1 - positionRatio;
78031    }
78032    const position = swiper.minTranslate() + (swiper.maxTranslate() - swiper.minTranslate()) * positionRatio;
78033    swiper.updateProgress(position);
78034    swiper.setTranslate(position);
78035    swiper.updateActiveIndex();
78036    swiper.updateSlidesClasses();
78037  }
78038  function onDragStart(e) {
78039    const params = swiper.params.scrollbar;
78040    const {
78041      scrollbar,
78042      wrapperEl
78043    } = swiper;
78044    const {
78045      el,
78046      dragEl
78047    } = scrollbar;
78048    isTouched = true;
78049    dragStartPos = e.target === dragEl ? getPointerPosition(e) - e.target.getBoundingClientRect()[swiper.isHorizontal() ? "left" : "top"] : null;
78050    e.preventDefault();
78051    e.stopPropagation();
78052    wrapperEl.style.transitionDuration = "100ms";
78053    dragEl.style.transitionDuration = "100ms";
78054    setDragPosition(e);
78055    clearTimeout(dragTimeout);
78056    el.style.transitionDuration = "0ms";
78057    if (params.hide) {
78058      el.style.opacity = 1;
78059    }
78060    if (swiper.params.cssMode) {
78061      swiper.wrapperEl.style["scroll-snap-type"] = "none";
78062    }
78063    emit("scrollbarDragStart", e);
78064  }
78065  function onDragMove(e) {
78066    const {
78067      scrollbar,
78068      wrapperEl
78069    } = swiper;
78070    const {
78071      el,
78072      dragEl
78073    } = scrollbar;
78074    if (!isTouched) return;
78075    if (e.preventDefault && e.cancelable) e.preventDefault();
78076    else e.returnValue = false;
78077    setDragPosition(e);
78078    wrapperEl.style.transitionDuration = "0ms";
78079    el.style.transitionDuration = "0ms";
78080    dragEl.style.transitionDuration = "0ms";
78081    emit("scrollbarDragMove", e);
78082  }
78083  function onDragEnd(e) {
78084    const params = swiper.params.scrollbar;
78085    const {
78086      scrollbar,
78087      wrapperEl
78088    } = swiper;
78089    const {
78090      el
78091    } = scrollbar;
78092    if (!isTouched) return;
78093    isTouched = false;
78094    if (swiper.params.cssMode) {
78095      swiper.wrapperEl.style["scroll-snap-type"] = "";
78096      wrapperEl.style.transitionDuration = "";
78097    }
78098    if (params.hide) {
78099      clearTimeout(dragTimeout);
78100      dragTimeout = nextTick(() => {
78101        el.style.opacity = 0;
78102        el.style.transitionDuration = "400ms";
78103      }, 1e3);
78104    }
78105    emit("scrollbarDragEnd", e);
78106    if (params.snapOnRelease) {
78107      swiper.slideToClosest();
78108    }
78109  }
78110  function events2(method) {
78111    const {
78112      scrollbar,
78113      params
78114    } = swiper;
78115    const el = scrollbar.el;
78116    if (!el) return;
78117    const target = el;
78118    const activeListener = params.passiveListeners ? {
78119      passive: false,
78120      capture: false
78121    } : false;
78122    const passiveListener = params.passiveListeners ? {
78123      passive: true,
78124      capture: false
78125    } : false;
78126    if (!target) return;
78127    const eventMethod = method === "on" ? "addEventListener" : "removeEventListener";
78128    target[eventMethod]("pointerdown", onDragStart, activeListener);
78129    document2[eventMethod]("pointermove", onDragMove, activeListener);
78130    document2[eventMethod]("pointerup", onDragEnd, passiveListener);
78131  }
78132  function enableDraggable() {
78133    if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) return;
78134    events2("on");
78135  }
78136  function disableDraggable() {
78137    if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) return;
78138    events2("off");
78139  }
78140  function init() {
78141    const {
78142      scrollbar,
78143      el: swiperEl
78144    } = swiper;
78145    swiper.params.scrollbar = createElementIfNotDefined(swiper, swiper.originalParams.scrollbar, swiper.params.scrollbar, {
78146      el: "swiper-scrollbar"
78147    });
78148    const params = swiper.params.scrollbar;
78149    if (!params.el) return;
78150    let el;
78151    if (typeof params.el === "string" && swiper.isElement) {
78152      el = swiper.el.querySelector(params.el);
78153    }
78154    if (!el && typeof params.el === "string") {
78155      el = document2.querySelectorAll(params.el);
78156      if (!el.length) return;
78157    } else if (!el) {
78158      el = params.el;
78159    }
78160    if (swiper.params.uniqueNavElements && typeof params.el === "string" && el.length > 1 && swiperEl.querySelectorAll(params.el).length === 1) {
78161      el = swiperEl.querySelector(params.el);
78162    }
78163    if (el.length > 0) el = el[0];
78164    el.classList.add(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass);
78165    let dragEl;
78166    if (el) {
78167      dragEl = el.querySelector(classesToSelector(swiper.params.scrollbar.dragClass));
78168      if (!dragEl) {
78169        dragEl = createElement("div", swiper.params.scrollbar.dragClass);
78170        el.append(dragEl);
78171      }
78172    }
78173    Object.assign(scrollbar, {
78174      el,
78175      dragEl
78176    });
78177    if (params.draggable) {
78178      enableDraggable();
78179    }
78180    if (el) {
78181      el.classList[swiper.enabled ? "remove" : "add"](...classesToTokens(swiper.params.scrollbar.lockClass));
78182    }
78183  }
78184  function destroy() {
78185    const params = swiper.params.scrollbar;
78186    const el = swiper.scrollbar.el;
78187    if (el) {
78188      el.classList.remove(...classesToTokens(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass));
78189    }
78190    disableDraggable();
78191  }
78192  on("changeDirection", () => {
78193    if (!swiper.scrollbar || !swiper.scrollbar.el) return;
78194    const params = swiper.params.scrollbar;
78195    let {
78196      el
78197    } = swiper.scrollbar;
78198    el = makeElementsArray(el);
78199    el.forEach((subEl) => {
78200      subEl.classList.remove(params.horizontalClass, params.verticalClass);
78201      subEl.classList.add(swiper.isHorizontal() ? params.horizontalClass : params.verticalClass);
78202    });
78203  });
78204  on("init", () => {
78205    if (swiper.params.scrollbar.enabled === false) {
78206      disable();
78207    } else {
78208      init();
78209      updateSize2();
78210      setTranslate2();
78211    }
78212  });
78213  on("update resize observerUpdate lock unlock changeDirection", () => {
78214    updateSize2();
78215  });
78216  on("setTranslate", () => {
78217    setTranslate2();
78218  });
78219  on("setTransition", (_s, duration) => {
78220    setTransition2(duration);
78221  });
78222  on("enable disable", () => {
78223    const {
78224      el
78225    } = swiper.scrollbar;
78226    if (el) {
78227      el.classList[swiper.enabled ? "remove" : "add"](...classesToTokens(swiper.params.scrollbar.lockClass));
78228    }
78229  });
78230  on("destroy", () => {
78231    destroy();
78232  });
78233  const enable = () => {
78234    swiper.el.classList.remove(...classesToTokens(swiper.params.scrollbar.scrollbarDisabledClass));
78235    if (swiper.scrollbar.el) {
78236      swiper.scrollbar.el.classList.remove(...classesToTokens(swiper.params.scrollbar.scrollbarDisabledClass));
78237    }
78238    init();
78239    updateSize2();
78240    setTranslate2();
78241  };
78242  const disable = () => {
78243    swiper.el.classList.add(...classesToTokens(swiper.params.scrollbar.scrollbarDisabledClass));
78244    if (swiper.scrollbar.el) {
78245      swiper.scrollbar.el.classList.add(...classesToTokens(swiper.params.scrollbar.scrollbarDisabledClass));
78246    }
78247    destroy();
78248  };
78249  Object.assign(swiper.scrollbar, {
78250    enable,
78251    disable,
78252    updateSize: updateSize2,
78253    setTranslate: setTranslate2,
78254    init,
78255    destroy
78256  });
78257}
78258
vendor: 3,972 bytes, lines 78259-78380
78259// node_modules/swiper/modules/parallax.mjs
78260function Parallax(_ref) {
78261  let {
78262    swiper,
78263    extendParams,
78264    on
78265  } = _ref;
78266  extendParams({
78267    parallax: {
78268      enabled: false
78269    }
78270  });
78271  const elementsSelector = "[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]";
78272  const setTransform = (el, progress) => {
78273    const {
78274      rtl
78275    } = swiper;
78276    const rtlFactor = rtl ? -1 : 1;
78277    const p = el.getAttribute("data-swiper-parallax") || "0";
78278    let x = el.getAttribute("data-swiper-parallax-x");
78279    let y = el.getAttribute("data-swiper-parallax-y");
78280    const scale = el.getAttribute("data-swiper-parallax-scale");
78281    const opacity = el.getAttribute("data-swiper-parallax-opacity");
78282    const rotate = el.getAttribute("data-swiper-parallax-rotate");
78283    if (x || y) {
78284      x = x || "0";
78285      y = y || "0";
78286    } else if (swiper.isHorizontal()) {
78287      x = p;
78288      y = "0";
78289    } else {
78290      y = p;
78291      x = "0";
78292    }
78293    if (x.indexOf("%") >= 0) {
78294      x = `${parseInt(x, 10) * progress * rtlFactor}%`;
78295    } else {
78296      x = `${x * progress * rtlFactor}px`;
78297    }
78298    if (y.indexOf("%") >= 0) {
78299      y = `${parseInt(y, 10) * progress}%`;
78300    } else {
78301      y = `${y * progress}px`;
78302    }
78303    if (typeof opacity !== "undefined" && opacity !== null) {
78304      const currentOpacity = opacity - (opacity - 1) * (1 - Math.abs(progress));
78305      el.style.opacity = currentOpacity;
78306    }
78307    let transform = `translate3d(${x}, ${y}, 0px)`;
78308    if (typeof scale !== "undefined" && scale !== null) {
78309      const currentScale = scale - (scale - 1) * (1 - Math.abs(progress));
78310      transform += ` scale(${currentScale})`;
78311    }
78312    if (rotate && typeof rotate !== "undefined" && rotate !== null) {
78313      const currentRotate = rotate * progress * -1;
78314      transform += ` rotate(${currentRotate}deg)`;
78315    }
78316    el.style.transform = transform;
78317  };
78318  const setTranslate2 = () => {
78319    const {
78320      el,
78321      slides,
78322      progress,
78323      snapGrid,
78324      isElement
78325    } = swiper;
78326    const elements = elementChildren(el, elementsSelector);
78327    if (swiper.isElement) {
78328      elements.push(...elementChildren(swiper.hostEl, elementsSelector));
78329    }
78330    elements.forEach((subEl) => {
78331      setTransform(subEl, progress);
78332    });
78333    slides.forEach((slideEl, slideIndex) => {
78334      let slideProgress = slideEl.progress;
78335      if (swiper.params.slidesPerGroup > 1 && swiper.params.slidesPerView !== "auto") {
78336        slideProgress += Math.ceil(slideIndex / 2) - progress * (snapGrid.length - 1);
78337      }
78338      slideProgress = Math.min(Math.max(slideProgress, -1), 1);
78339      slideEl.querySelectorAll(`${elementsSelector}, [data-swiper-parallax-rotate]`).forEach((subEl) => {
78340        setTransform(subEl, slideProgress);
78341      });
78342    });
78343  };
78344  const setTransition2 = function(duration) {
78345    if (duration === void 0) {
78346      duration = swiper.params.speed;
78347    }
78348    const {
78349      el,
78350      hostEl
78351    } = swiper;
78352    const elements = [...el.querySelectorAll(elementsSelector)];
78353    if (swiper.isElement) {
78354      elements.push(...hostEl.querySelectorAll(elementsSelector));
78355    }
78356    elements.forEach((parallaxEl) => {
78357      let parallaxDuration = parseInt(parallaxEl.getAttribute("data-swiper-parallax-duration"), 10) || duration;
78358      if (duration === 0) parallaxDuration = 0;
78359      parallaxEl.style.transitionDuration = `${parallaxDuration}ms`;
78360    });
78361  };
78362  on("beforeInit", () => {
78363    if (!swiper.params.parallax.enabled) return;
78364    swiper.params.watchSlidesProgress = true;
78365    swiper.originalParams.watchSlidesProgress = true;
78366  });
78367  on("init", () => {
78368    if (!swiper.params.parallax.enabled) return;
78369    setTranslate2();
78370  });
78371  on("setTranslate", () => {
78372    if (!swiper.params.parallax.enabled) return;
78373    setTranslate2();
78374  });
78375  on("setTransition", (_swiper, duration) => {
78376    if (!swiper.params.parallax.enabled) return;
78377    setTransition2(duration);
78378  });
78379}
78380
vendor: 24,802 bytes, lines 78381-79055
78381// node_modules/swiper/modules/zoom.mjs
78382function Zoom(_ref) {
78383  let {
78384    swiper,
78385    extendParams,
78386    on,
78387    emit
78388  } = _ref;
78389  const window2 = getWindow();
78390  extendParams({
78391    zoom: {
78392      enabled: false,
78393      limitToOriginalSize: false,
78394      maxRatio: 3,
78395      minRatio: 1,
78396      panOnMouseMove: false,
78397      toggle: true,
78398      containerClass: "swiper-zoom-container",
78399      zoomedSlideClass: "swiper-slide-zoomed"
78400    }
78401  });
78402  swiper.zoom = {
78403    enabled: false
78404  };
78405  let currentScale = 1;
78406  let isScaling = false;
78407  let isPanningWithMouse = false;
78408  let mousePanStart = {
78409    x: 0,
78410    y: 0
78411  };
78412  const mousePanSensitivity = -3;
78413  let fakeGestureTouched;
78414  let fakeGestureMoved;
78415  const evCache = [];
78416  const gesture = {
78417    originX: 0,
78418    originY: 0,
78419    slideEl: void 0,
78420    slideWidth: void 0,
78421    slideHeight: void 0,
78422    imageEl: void 0,
78423    imageWrapEl: void 0,
78424    maxRatio: 3
78425  };
78426  const image = {
78427    isTouched: void 0,
78428    isMoved: void 0,
78429    currentX: void 0,
78430    currentY: void 0,
78431    minX: void 0,
78432    minY: void 0,
78433    maxX: void 0,
78434    maxY: void 0,
78435    width: void 0,
78436    height: void 0,
78437    startX: void 0,
78438    startY: void 0,
78439    touchesStart: {},
78440    touchesCurrent: {}
78441  };
78442  const velocity = {
78443    x: void 0,
78444    y: void 0,
78445    prevPositionX: void 0,
78446    prevPositionY: void 0,
78447    prevTime: void 0
78448  };
78449  let scale = 1;
78450  Object.defineProperty(swiper.zoom, "scale", {
78451    get() {
78452      return scale;
78453    },
78454    set(value) {
78455      if (scale !== value) {
78456        const imageEl = gesture.imageEl;
78457        const slideEl = gesture.slideEl;
78458        emit("zoomChange", value, imageEl, slideEl);
78459      }
78460      scale = value;
78461    }
78462  });
78463  function getDistanceBetweenTouches() {
78464    if (evCache.length < 2) return 1;
78465    const x1 = evCache[0].pageX;
78466    const y1 = evCache[0].pageY;
78467    const x2 = evCache[1].pageX;
78468    const y2 = evCache[1].pageY;
78469    const distance = Math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2);
78470    return distance;
78471  }
78472  function getMaxRatio() {
78473    const params = swiper.params.zoom;
78474    const maxRatio = gesture.imageWrapEl.getAttribute("data-swiper-zoom") || params.maxRatio;
78475    if (params.limitToOriginalSize && gesture.imageEl && gesture.imageEl.naturalWidth) {
78476      const imageMaxRatio = gesture.imageEl.naturalWidth / gesture.imageEl.offsetWidth;
78477      return Math.min(imageMaxRatio, maxRatio);
78478    }
78479    return maxRatio;
78480  }
78481  function getScaleOrigin() {
78482    if (evCache.length < 2) return {
78483      x: null,
78484      y: null
78485    };
78486    const box = gesture.imageEl.getBoundingClientRect();
78487    return [(evCache[0].pageX + (evCache[1].pageX - evCache[0].pageX) / 2 - box.x - window2.scrollX) / currentScale, (evCache[0].pageY + (evCache[1].pageY - evCache[0].pageY) / 2 - box.y - window2.scrollY) / currentScale];
78488  }
78489  function getSlideSelector() {
78490    return swiper.isElement ? `swiper-slide` : `.${swiper.params.slideClass}`;
78491  }
78492  function eventWithinSlide(e) {
78493    const slideSelector = getSlideSelector();
78494    if (e.target.matches(slideSelector)) return true;
78495    if (swiper.slides.filter((slideEl) => slideEl.contains(e.target)).length > 0) return true;
78496    return false;
78497  }
78498  function eventWithinZoomContainer(e) {
78499    const selector = `.${swiper.params.zoom.containerClass}`;
78500    if (e.target.matches(selector)) return true;
78501    if ([...swiper.hostEl.querySelectorAll(selector)].filter((containerEl) => containerEl.contains(e.target)).length > 0) return true;
78502    return false;
78503  }
78504  function onGestureStart(e) {
78505    if (e.pointerType === "mouse") {
78506      evCache.splice(0, evCache.length);
78507    }
78508    if (!eventWithinSlide(e)) return;
78509    const params = swiper.params.zoom;
78510    fakeGestureTouched = false;
78511    fakeGestureMoved = false;
78512    evCache.push(e);
78513    if (evCache.length < 2) {
78514      return;
78515    }
78516    fakeGestureTouched = true;
78517    gesture.scaleStart = getDistanceBetweenTouches();
78518    if (!gesture.slideEl) {
78519      gesture.slideEl = e.target.closest(`.${swiper.params.slideClass}, swiper-slide`);
78520      if (!gesture.slideEl) gesture.slideEl = swiper.slides[swiper.activeIndex];
78521      let imageEl = gesture.slideEl.querySelector(`.${params.containerClass}`);
78522      if (imageEl) {
78523        imageEl = imageEl.querySelectorAll("picture, img, svg, canvas, .swiper-zoom-target")[0];
78524      }
78525      gesture.imageEl = imageEl;
78526      if (imageEl) {
78527        gesture.imageWrapEl = elementParents(gesture.imageEl, `.${params.containerClass}`)[0];
78528      } else {
78529        gesture.imageWrapEl = void 0;
78530      }
78531      if (!gesture.imageWrapEl) {
78532        gesture.imageEl = void 0;
78533        return;
78534      }
78535      gesture.maxRatio = getMaxRatio();
78536    }
78537    if (gesture.imageEl) {
78538      const [originX, originY] = getScaleOrigin();
78539      gesture.originX = originX;
78540      gesture.originY = originY;
78541      gesture.imageEl.style.transitionDuration = "0ms";
78542    }
78543    isScaling = true;
78544  }
78545  function onGestureChange(e) {
78546    if (!eventWithinSlide(e)) return;
78547    const params = swiper.params.zoom;
78548    const zoom = swiper.zoom;
78549    const pointerIndex = evCache.findIndex((cachedEv) => cachedEv.pointerId === e.pointerId);
78550    if (pointerIndex >= 0) evCache[pointerIndex] = e;
78551    if (evCache.length < 2) {
78552      return;
78553    }
78554    fakeGestureMoved = true;
78555    gesture.scaleMove = getDistanceBetweenTouches();
78556    if (!gesture.imageEl) {
78557      return;
78558    }
78559    zoom.scale = gesture.scaleMove / gesture.scaleStart * currentScale;
78560    if (zoom.scale > gesture.maxRatio) {
78561      zoom.scale = gesture.maxRatio - 1 + (zoom.scale - gesture.maxRatio + 1) ** 0.5;
78562    }
78563    if (zoom.scale < params.minRatio) {
78564      zoom.scale = params.minRatio + 1 - (params.minRatio - zoom.scale + 1) ** 0.5;
78565    }
78566    gesture.imageEl.style.transform = `translate3d(0,0,0) scale(${zoom.scale})`;
78567  }
78568  function onGestureEnd(e) {
78569    if (!eventWithinSlide(e)) return;
78570    if (e.pointerType === "mouse" && e.type === "pointerout") return;
78571    const params = swiper.params.zoom;
78572    const zoom = swiper.zoom;
78573    const pointerIndex = evCache.findIndex((cachedEv) => cachedEv.pointerId === e.pointerId);
78574    if (pointerIndex >= 0) evCache.splice(pointerIndex, 1);
78575    if (!fakeGestureTouched || !fakeGestureMoved) {
78576      return;
78577    }
78578    fakeGestureTouched = false;
78579    fakeGestureMoved = false;
78580    if (!gesture.imageEl) return;
78581    zoom.scale = Math.max(Math.min(zoom.scale, gesture.maxRatio), params.minRatio);
78582    gesture.imageEl.style.transitionDuration = `${swiper.params.speed}ms`;
78583    gesture.imageEl.style.transform = `translate3d(0,0,0) scale(${zoom.scale})`;
78584    currentScale = zoom.scale;
78585    isScaling = false;
78586    if (zoom.scale > 1 && gesture.slideEl) {
78587      gesture.slideEl.classList.add(`${params.zoomedSlideClass}`);
78588    } else if (zoom.scale <= 1 && gesture.slideEl) {
78589      gesture.slideEl.classList.remove(`${params.zoomedSlideClass}`);
78590    }
78591    if (zoom.scale === 1) {
78592      gesture.originX = 0;
78593      gesture.originY = 0;
78594      gesture.slideEl = void 0;
78595    }
78596  }
78597  let allowTouchMoveTimeout;
78598  function allowTouchMove() {
78599    swiper.touchEventsData.preventTouchMoveFromPointerMove = false;
78600  }
78601  function preventTouchMove() {
78602    clearTimeout(allowTouchMoveTimeout);
78603    swiper.touchEventsData.preventTouchMoveFromPointerMove = true;
78604    allowTouchMoveTimeout = setTimeout(() => {
78605      if (swiper.destroyed) return;
78606      allowTouchMove();
78607    });
78608  }
78609  function onTouchStart2(e) {
78610    const device = swiper.device;
78611    if (!gesture.imageEl) return;
78612    if (image.isTouched) return;
78613    if (device.android && e.cancelable) e.preventDefault();
78614    image.isTouched = true;
78615    const event2 = evCache.length > 0 ? evCache[0] : e;
78616    image.touchesStart.x = event2.pageX;
78617    image.touchesStart.y = event2.pageY;
78618  }
78619  function onTouchMove2(e) {
78620    const isMouseEvent = e.pointerType === "mouse";
78621    const isMousePan = isMouseEvent && swiper.params.zoom.panOnMouseMove;
78622    if (!eventWithinSlide(e) || !eventWithinZoomContainer(e)) {
78623      return;
78624    }
78625    const zoom = swiper.zoom;
78626    if (!gesture.imageEl) {
78627      return;
78628    }
78629    if (!image.isTouched || !gesture.slideEl) {
78630      if (isMousePan) onMouseMove(e);
78631      return;
78632    }
78633    if (isMousePan) {
78634      onMouseMove(e);
78635      return;
78636    }
78637    if (!image.isMoved) {
78638      image.width = gesture.imageEl.offsetWidth || gesture.imageEl.clientWidth;
78639      image.height = gesture.imageEl.offsetHeight || gesture.imageEl.clientHeight;
78640      image.startX = getTranslate(gesture.imageWrapEl, "x") || 0;
78641      image.startY = getTranslate(gesture.imageWrapEl, "y") || 0;
78642      gesture.slideWidth = gesture.slideEl.offsetWidth;
78643      gesture.slideHeight = gesture.slideEl.offsetHeight;
78644      gesture.imageWrapEl.style.transitionDuration = "0ms";
78645    }
78646    const scaledWidth = image.width * zoom.scale;
78647    const scaledHeight = image.height * zoom.scale;
78648    image.minX = Math.min(gesture.slideWidth / 2 - scaledWidth / 2, 0);
78649    image.maxX = -image.minX;
78650    image.minY = Math.min(gesture.slideHeight / 2 - scaledHeight / 2, 0);
78651    image.maxY = -image.minY;
78652    image.touchesCurrent.x = evCache.length > 0 ? evCache[0].pageX : e.pageX;
78653    image.touchesCurrent.y = evCache.length > 0 ? evCache[0].pageY : e.pageY;
78654    const touchesDiff = Math.max(Math.abs(image.touchesCurrent.x - image.touchesStart.x), Math.abs(image.touchesCurrent.y - image.touchesStart.y));
78655    if (touchesDiff > 5) {
78656      swiper.allowClick = false;
78657    }
78658    if (!image.isMoved && !isScaling) {
78659      if (swiper.isHorizontal() && (Math.floor(image.minX) === Math.floor(image.startX) && image.touchesCurrent.x < image.touchesStart.x || Math.floor(image.maxX) === Math.floor(image.startX) && image.touchesCurrent.x > image.touchesStart.x)) {
78660        image.isTouched = false;
78661        allowTouchMove();
78662        return;
78663      }
78664      if (!swiper.isHorizontal() && (Math.floor(image.minY) === Math.floor(image.startY) && image.touchesCurrent.y < image.touchesStart.y || Math.floor(image.maxY) === Math.floor(image.startY) && image.touchesCurrent.y > image.touchesStart.y)) {
78665        image.isTouched = false;
78666        allowTouchMove();
78667        return;
78668      }
78669    }
78670    if (e.cancelable) {
78671      e.preventDefault();
78672    }
78673    e.stopPropagation();
78674    preventTouchMove();
78675    image.isMoved = true;
78676    const scaleRatio = (zoom.scale - currentScale) / (gesture.maxRatio - swiper.params.zoom.minRatio);
78677    const {
78678      originX,
78679      originY
78680    } = gesture;
78681    image.currentX = image.touchesCurrent.x - image.touchesStart.x + image.startX + scaleRatio * (image.width - originX * 2);
78682    image.currentY = image.touchesCurrent.y - image.touchesStart.y + image.startY + scaleRatio * (image.height - originY * 2);
78683    if (image.currentX < image.minX) {
78684      image.currentX = image.minX + 1 - (image.minX - image.currentX + 1) ** 0.8;
78685    }
78686    if (image.currentX > image.maxX) {
78687      image.currentX = image.maxX - 1 + (image.currentX - image.maxX + 1) ** 0.8;
78688    }
78689    if (image.currentY < image.minY) {
78690      image.currentY = image.minY + 1 - (image.minY - image.currentY + 1) ** 0.8;
78691    }
78692    if (image.currentY > image.maxY) {
78693      image.currentY = image.maxY - 1 + (image.currentY - image.maxY + 1) ** 0.8;
78694    }
78695    if (!velocity.prevPositionX) velocity.prevPositionX = image.touchesCurrent.x;
78696    if (!velocity.prevPositionY) velocity.prevPositionY = image.touchesCurrent.y;
78697    if (!velocity.prevTime) velocity.prevTime = Date.now();
78698    velocity.x = (image.touchesCurrent.x - velocity.prevPositionX) / (Date.now() - velocity.prevTime) / 2;
78699    velocity.y = (image.touchesCurrent.y - velocity.prevPositionY) / (Date.now() - velocity.prevTime) / 2;
78700    if (Math.abs(image.touchesCurrent.x - velocity.prevPositionX) < 2) velocity.x = 0;
78701    if (Math.abs(image.touchesCurrent.y - velocity.prevPositionY) < 2) velocity.y = 0;
78702    velocity.prevPositionX = image.touchesCurrent.x;
78703    velocity.prevPositionY = image.touchesCurrent.y;
78704    velocity.prevTime = Date.now();
78705    gesture.imageWrapEl.style.transform = `translate3d(${image.currentX}px, ${image.currentY}px,0)`;
78706  }
78707  function onTouchEnd2() {
78708    const zoom = swiper.zoom;
78709    evCache.length = 0;
78710    if (!gesture.imageEl) return;
78711    if (!image.isTouched || !image.isMoved) {
78712      image.isTouched = false;
78713      image.isMoved = false;
78714      return;
78715    }
78716    image.isTouched = false;
78717    image.isMoved = false;
78718    let momentumDurationX = 300;
78719    let momentumDurationY = 300;
78720    const momentumDistanceX = velocity.x * momentumDurationX;
78721    const newPositionX = image.currentX + momentumDistanceX;
78722    const momentumDistanceY = velocity.y * momentumDurationY;
78723    const newPositionY = image.currentY + momentumDistanceY;
78724    if (velocity.x !== 0) momentumDurationX = Math.abs((newPositionX - image.currentX) / velocity.x);
78725    if (velocity.y !== 0) momentumDurationY = Math.abs((newPositionY - image.currentY) / velocity.y);
78726    const momentumDuration = Math.max(momentumDurationX, momentumDurationY);
78727    image.currentX = newPositionX;
78728    image.currentY = newPositionY;
78729    const scaledWidth = image.width * zoom.scale;
78730    const scaledHeight = image.height * zoom.scale;
78731    image.minX = Math.min(gesture.slideWidth / 2 - scaledWidth / 2, 0);
78732    image.maxX = -image.minX;
78733    image.minY = Math.min(gesture.slideHeight / 2 - scaledHeight / 2, 0);
78734    image.maxY = -image.minY;
78735    image.currentX = Math.max(Math.min(image.currentX, image.maxX), image.minX);
78736    image.currentY = Math.max(Math.min(image.currentY, image.maxY), image.minY);
78737    gesture.imageWrapEl.style.transitionDuration = `${momentumDuration}ms`;
78738    gesture.imageWrapEl.style.transform = `translate3d(${image.currentX}px, ${image.currentY}px,0)`;
78739  }
78740  function onTransitionEnd() {
78741    const zoom = swiper.zoom;
78742    if (gesture.slideEl && swiper.activeIndex !== swiper.slides.indexOf(gesture.slideEl)) {
78743      if (gesture.imageEl) {
78744        gesture.imageEl.style.transform = "translate3d(0,0,0) scale(1)";
78745      }
78746      if (gesture.imageWrapEl) {
78747        gesture.imageWrapEl.style.transform = "translate3d(0,0,0)";
78748      }
78749      gesture.slideEl.classList.remove(`${swiper.params.zoom.zoomedSlideClass}`);
78750      zoom.scale = 1;
78751      currentScale = 1;
78752      gesture.slideEl = void 0;
78753      gesture.imageEl = void 0;
78754      gesture.imageWrapEl = void 0;
78755      gesture.originX = 0;
78756      gesture.originY = 0;
78757    }
78758  }
78759  function onMouseMove(e) {
78760    if (currentScale <= 1 || !gesture.imageWrapEl) return;
78761    if (!eventWithinSlide(e) || !eventWithinZoomContainer(e)) return;
78762    const currentTransform = window2.getComputedStyle(gesture.imageWrapEl).transform;
78763    const matrix = new window2.DOMMatrix(currentTransform);
78764    if (!isPanningWithMouse) {
78765      isPanningWithMouse = true;
78766      mousePanStart.x = e.clientX;
78767      mousePanStart.y = e.clientY;
78768      image.startX = matrix.e;
78769      image.startY = matrix.f;
78770      image.width = gesture.imageEl.offsetWidth || gesture.imageEl.clientWidth;
78771      image.height = gesture.imageEl.offsetHeight || gesture.imageEl.clientHeight;
78772      gesture.slideWidth = gesture.slideEl.offsetWidth;
78773      gesture.slideHeight = gesture.slideEl.offsetHeight;
78774      return;
78775    }
78776    const deltaX = (e.clientX - mousePanStart.x) * mousePanSensitivity;
78777    const deltaY = (e.clientY - mousePanStart.y) * mousePanSensitivity;
78778    const scaledWidth = image.width * currentScale;
78779    const scaledHeight = image.height * currentScale;
78780    const slideWidth = gesture.slideWidth;
78781    const slideHeight = gesture.slideHeight;
78782    const minX = Math.min(slideWidth / 2 - scaledWidth / 2, 0);
78783    const maxX = -minX;
78784    const minY = Math.min(slideHeight / 2 - scaledHeight / 2, 0);
78785    const maxY = -minY;
78786    const newX = Math.max(Math.min(image.startX + deltaX, maxX), minX);
78787    const newY = Math.max(Math.min(image.startY + deltaY, maxY), minY);
78788    gesture.imageWrapEl.style.transitionDuration = "0ms";
78789    gesture.imageWrapEl.style.transform = `translate3d(${newX}px, ${newY}px, 0)`;
78790    mousePanStart.x = e.clientX;
78791    mousePanStart.y = e.clientY;
78792    image.startX = newX;
78793    image.startY = newY;
78794    image.currentX = newX;
78795    image.currentY = newY;
78796  }
78797  function zoomIn(e) {
78798    const zoom = swiper.zoom;
78799    const params = swiper.params.zoom;
78800    if (!gesture.slideEl) {
78801      if (e && e.target) {
78802        gesture.slideEl = e.target.closest(`.${swiper.params.slideClass}, swiper-slide`);
78803      }
78804      if (!gesture.slideEl) {
78805        if (swiper.params.virtual && swiper.params.virtual.enabled && swiper.virtual) {
78806          gesture.slideEl = elementChildren(swiper.slidesEl, `.${swiper.params.slideActiveClass}`)[0];
78807        } else {
78808          gesture.slideEl = swiper.slides[swiper.activeIndex];
78809        }
78810      }
78811      let imageEl = gesture.slideEl.querySelector(`.${params.containerClass}`);
78812      if (imageEl) {
78813        imageEl = imageEl.querySelectorAll("picture, img, svg, canvas, .swiper-zoom-target")[0];
78814      }
78815      gesture.imageEl = imageEl;
78816      if (imageEl) {
78817        gesture.imageWrapEl = elementParents(gesture.imageEl, `.${params.containerClass}`)[0];
78818      } else {
78819        gesture.imageWrapEl = void 0;
78820      }
78821    }
78822    if (!gesture.imageEl || !gesture.imageWrapEl) return;
78823    if (swiper.params.cssMode) {
78824      swiper.wrapperEl.style.overflow = "hidden";
78825      swiper.wrapperEl.style.touchAction = "none";
78826    }
78827    gesture.slideEl.classList.add(`${params.zoomedSlideClass}`);
78828    let touchX;
78829    let touchY;
78830    let offsetX;
78831    let offsetY;
78832    let diffX;
78833    let diffY;
78834    let translateX;
78835    let translateY;
78836    let imageWidth;
78837    let imageHeight;
78838    let scaledWidth;
78839    let scaledHeight;
78840    let translateMinX;
78841    let translateMinY;
78842    let translateMaxX;
78843    let translateMaxY;
78844    let slideWidth;
78845    let slideHeight;
78846    if (typeof image.touchesStart.x === "undefined" && e) {
78847      touchX = e.pageX;
78848      touchY = e.pageY;
78849    } else {
78850      touchX = image.touchesStart.x;
78851      touchY = image.touchesStart.y;
78852    }
78853    const prevScale = currentScale;
78854    const forceZoomRatio = typeof e === "number" ? e : null;
78855    if (currentScale === 1 && forceZoomRatio) {
78856      touchX = void 0;
78857      touchY = void 0;
78858      image.touchesStart.x = void 0;
78859      image.touchesStart.y = void 0;
78860    }
78861    const maxRatio = getMaxRatio();
78862    zoom.scale = forceZoomRatio || maxRatio;
78863    currentScale = forceZoomRatio || maxRatio;
78864    if (e && !(currentScale === 1 && forceZoomRatio)) {
78865      slideWidth = gesture.slideEl.offsetWidth;
78866      slideHeight = gesture.slideEl.offsetHeight;
78867      offsetX = elementOffset(gesture.slideEl).left + window2.scrollX;
78868      offsetY = elementOffset(gesture.slideEl).top + window2.scrollY;
78869      diffX = offsetX + slideWidth / 2 - touchX;
78870      diffY = offsetY + slideHeight / 2 - touchY;
78871      imageWidth = gesture.imageEl.offsetWidth || gesture.imageEl.clientWidth;
78872      imageHeight = gesture.imageEl.offsetHeight || gesture.imageEl.clientHeight;
78873      scaledWidth = imageWidth * zoom.scale;
78874      scaledHeight = imageHeight * zoom.scale;
78875      translateMinX = Math.min(slideWidth / 2 - scaledWidth / 2, 0);
78876      translateMinY = Math.min(slideHeight / 2 - scaledHeight / 2, 0);
78877      translateMaxX = -translateMinX;
78878      translateMaxY = -translateMinY;
78879      if (prevScale > 0 && forceZoomRatio && typeof image.currentX === "number" && typeof image.currentY === "number") {
78880        translateX = image.currentX * zoom.scale / prevScale;
78881        translateY = image.currentY * zoom.scale / prevScale;
78882      } else {
78883        translateX = diffX * zoom.scale;
78884        translateY = diffY * zoom.scale;
78885      }
78886      if (translateX < translateMinX) {
78887        translateX = translateMinX;
78888      }
78889      if (translateX > translateMaxX) {
78890        translateX = translateMaxX;
78891      }
78892      if (translateY < translateMinY) {
78893        translateY = translateMinY;
78894      }
78895      if (translateY > translateMaxY) {
78896        translateY = translateMaxY;
78897      }
78898    } else {
78899      translateX = 0;
78900      translateY = 0;
78901    }
78902    if (forceZoomRatio && zoom.scale === 1) {
78903      gesture.originX = 0;
78904      gesture.originY = 0;
78905    }
78906    image.currentX = translateX;
78907    image.currentY = translateY;
78908    gesture.imageWrapEl.style.transitionDuration = "300ms";
78909    gesture.imageWrapEl.style.transform = `translate3d(${translateX}px, ${translateY}px,0)`;
78910    gesture.imageEl.style.transitionDuration = "300ms";
78911    gesture.imageEl.style.transform = `translate3d(0,0,0) scale(${zoom.scale})`;
78912  }
78913  function zoomOut() {
78914    const zoom = swiper.zoom;
78915    const params = swiper.params.zoom;
78916    if (!gesture.slideEl) {
78917      if (swiper.params.virtual && swiper.params.virtual.enabled && swiper.virtual) {
78918        gesture.slideEl = elementChildren(swiper.slidesEl, `.${swiper.params.slideActiveClass}`)[0];
78919      } else {
78920        gesture.slideEl = swiper.slides[swiper.activeIndex];
78921      }
78922      let imageEl = gesture.slideEl.querySelector(`.${params.containerClass}`);
78923      if (imageEl) {
78924        imageEl = imageEl.querySelectorAll("picture, img, svg, canvas, .swiper-zoom-target")[0];
78925      }
78926      gesture.imageEl = imageEl;
78927      if (imageEl) {
78928        gesture.imageWrapEl = elementParents(gesture.imageEl, `.${params.containerClass}`)[0];
78929      } else {
78930        gesture.imageWrapEl = void 0;
78931      }
78932    }
78933    if (!gesture.imageEl || !gesture.imageWrapEl) return;
78934    if (swiper.params.cssMode) {
78935      swiper.wrapperEl.style.overflow = "";
78936      swiper.wrapperEl.style.touchAction = "";
78937    }
78938    zoom.scale = 1;
78939    currentScale = 1;
78940    image.currentX = void 0;
78941    image.currentY = void 0;
78942    image.touchesStart.x = void 0;
78943    image.touchesStart.y = void 0;
78944    gesture.imageWrapEl.style.transitionDuration = "300ms";
78945    gesture.imageWrapEl.style.transform = "translate3d(0,0,0)";
78946    gesture.imageEl.style.transitionDuration = "300ms";
78947    gesture.imageEl.style.transform = "translate3d(0,0,0) scale(1)";
78948    gesture.slideEl.classList.remove(`${params.zoomedSlideClass}`);
78949    gesture.slideEl = void 0;
78950    gesture.originX = 0;
78951    gesture.originY = 0;
78952    if (swiper.params.zoom.panOnMouseMove) {
78953      mousePanStart = {
78954        x: 0,
78955        y: 0
78956      };
78957      if (isPanningWithMouse) {
78958        isPanningWithMouse = false;
78959        image.startX = 0;
78960        image.startY = 0;
78961      }
78962    }
78963  }
78964  function zoomToggle(e) {
78965    const zoom = swiper.zoom;
78966    if (zoom.scale && zoom.scale !== 1) {
78967      zoomOut();
78968    } else {
78969      zoomIn(e);
78970    }
78971  }
78972  function getListeners() {
78973    const passiveListener = swiper.params.passiveListeners ? {
78974      passive: true,
78975      capture: false
78976    } : false;
78977    const activeListenerWithCapture = swiper.params.passiveListeners ? {
78978      passive: false,
78979      capture: true
78980    } : true;
78981    return {
78982      passiveListener,
78983      activeListenerWithCapture
78984    };
78985  }
78986  function enable() {
78987    const zoom = swiper.zoom;
78988    if (zoom.enabled) return;
78989    zoom.enabled = true;
78990    const {
78991      passiveListener,
78992      activeListenerWithCapture
78993    } = getListeners();
78994    swiper.wrapperEl.addEventListener("pointerdown", onGestureStart, passiveListener);
78995    swiper.wrapperEl.addEventListener("pointermove", onGestureChange, activeListenerWithCapture);
78996    ["pointerup", "pointercancel", "pointerout"].forEach((eventName) => {
78997      swiper.wrapperEl.addEventListener(eventName, onGestureEnd, passiveListener);
78998    });
78999    swiper.wrapperEl.addEventListener("pointermove", onTouchMove2, activeListenerWithCapture);
79000  }
79001  function disable() {
79002    const zoom = swiper.zoom;
79003    if (!zoom.enabled) return;
79004    zoom.enabled = false;
79005    const {
79006      passiveListener,
79007      activeListenerWithCapture
79008    } = getListeners();
79009    swiper.wrapperEl.removeEventListener("pointerdown", onGestureStart, passiveListener);
79010    swiper.wrapperEl.removeEventListener("pointermove", onGestureChange, activeListenerWithCapture);
79011    ["pointerup", "pointercancel", "pointerout"].forEach((eventName) => {
79012      swiper.wrapperEl.removeEventListener(eventName, onGestureEnd, passiveListener);
79013    });
79014    swiper.wrapperEl.removeEventListener("pointermove", onTouchMove2, activeListenerWithCapture);
79015  }
79016  on("init", () => {
79017    if (swiper.params.zoom.enabled) {
79018      enable();
79019    }
79020  });
79021  on("destroy", () => {
79022    disable();
79023  });
79024  on("touchStart", (_s, e) => {
79025    if (!swiper.zoom.enabled) return;
79026    onTouchStart2(e);
79027  });
79028  on("touchEnd", (_s, e) => {
79029    if (!swiper.zoom.enabled) return;
79030    onTouchEnd2();
79031  });
79032  on("doubleTap", (_s, e) => {
79033    if (!swiper.animating && swiper.params.zoom.enabled && swiper.zoom.enabled && swiper.params.zoom.toggle) {
79034      zoomToggle(e);
79035    }
79036  });
79037  on("transitionEnd", () => {
79038    if (swiper.zoom.enabled && swiper.params.zoom.enabled) {
79039      onTransitionEnd();
79040    }
79041  });
79042  on("slideChange", () => {
79043    if (swiper.zoom.enabled && swiper.params.zoom.enabled && swiper.params.cssMode) {
79044      onTransitionEnd();
79045    }
79046  });
79047  Object.assign(swiper.zoom, {
79048    enable,
79049    disable,
79050    in: zoomIn,
79051    out: zoomOut,
79052    toggle: zoomToggle
79053  });
79054}
79055
vendor: 5,937 bytes, lines 79056-79227
79056// node_modules/swiper/modules/controller.mjs
79057function Controller(_ref) {
79058  let {
79059    swiper,
79060    extendParams,
79061    on
79062  } = _ref;
79063  extendParams({
79064    controller: {
79065      control: void 0,
79066      inverse: false,
79067      by: "slide"
79068      // or 'container'
79069    }
79070  });
79071  swiper.controller = {
79072    control: void 0
79073  };
79074  function LinearSpline(x, y) {
79075    const binarySearch = /* @__PURE__ */ function search() {
79076      let maxIndex;
79077      let minIndex;
79078      let guess;
79079      return (array, val) => {
79080        minIndex = -1;
79081        maxIndex = array.length;
79082        while (maxIndex - minIndex > 1) {
79083          guess = maxIndex + minIndex >> 1;
79084          if (array[guess] <= val) {
79085            minIndex = guess;
79086          } else {
79087            maxIndex = guess;
79088          }
79089        }
79090        return maxIndex;
79091      };
79092    }();
79093    this.x = x;
79094    this.y = y;
79095    this.lastIndex = x.length - 1;
79096    let i1;
79097    let i3;
79098    this.interpolate = function interpolate(x2) {
79099      if (!x2) return 0;
79100      i3 = binarySearch(this.x, x2);
79101      i1 = i3 - 1;
79102      return (x2 - this.x[i1]) * (this.y[i3] - this.y[i1]) / (this.x[i3] - this.x[i1]) + this.y[i1];
79103    };
79104    return this;
79105  }
79106  function getInterpolateFunction(c) {
79107    swiper.controller.spline = swiper.params.loop ? new LinearSpline(swiper.slidesGrid, c.slidesGrid) : new LinearSpline(swiper.snapGrid, c.snapGrid);
79108  }
79109  function setTranslate2(_t, byController) {
79110    const controlled = swiper.controller.control;
79111    let multiplier;
79112    let controlledTranslate;
79113    const Swiper2 = swiper.constructor;
79114    function setControlledTranslate(c) {
79115      if (c.destroyed) return;
79116      const translate2 = swiper.rtlTranslate ? -swiper.translate : swiper.translate;
79117      if (swiper.params.controller.by === "slide") {
79118        getInterpolateFunction(c);
79119        controlledTranslate = -swiper.controller.spline.interpolate(-translate2);
79120      }
79121      if (!controlledTranslate || swiper.params.controller.by === "container") {
79122        multiplier = (c.maxTranslate() - c.minTranslate()) / (swiper.maxTranslate() - swiper.minTranslate());
79123        if (Number.isNaN(multiplier) || !Number.isFinite(multiplier)) {
79124          multiplier = 1;
79125        }
79126        controlledTranslate = (translate2 - swiper.minTranslate()) * multiplier + c.minTranslate();
79127      }
79128      if (swiper.params.controller.inverse) {
79129        controlledTranslate = c.maxTranslate() - controlledTranslate;
79130      }
79131      c.updateProgress(controlledTranslate);
79132      c.setTranslate(controlledTranslate, swiper);
79133      c.updateActiveIndex();
79134      c.updateSlidesClasses();
79135    }
79136    if (Array.isArray(controlled)) {
79137      for (let i = 0; i < controlled.length; i += 1) {
79138        if (controlled[i] !== byController && controlled[i] instanceof Swiper2) {
79139          setControlledTranslate(controlled[i]);
79140        }
79141      }
79142    } else if (controlled instanceof Swiper2 && byController !== controlled) {
79143      setControlledTranslate(controlled);
79144    }
79145  }
79146  function setTransition2(duration, byController) {
79147    const Swiper2 = swiper.constructor;
79148    const controlled = swiper.controller.control;
79149    let i;
79150    function setControlledTransition(c) {
79151      if (c.destroyed) return;
79152      c.setTransition(duration, swiper);
79153      if (duration !== 0) {
79154        c.transitionStart();
79155        if (c.params.autoHeight) {
79156          nextTick(() => {
79157            c.updateAutoHeight();
79158          });
79159        }
79160        elementTransitionEnd(c.wrapperEl, () => {
79161          if (!controlled) return;
79162          c.transitionEnd();
79163        });
79164      }
79165    }
79166    if (Array.isArray(controlled)) {
79167      for (i = 0; i < controlled.length; i += 1) {
79168        if (controlled[i] !== byController && controlled[i] instanceof Swiper2) {
79169          setControlledTransition(controlled[i]);
79170        }
79171      }
79172    } else if (controlled instanceof Swiper2 && byController !== controlled) {
79173      setControlledTransition(controlled);
79174    }
79175  }
79176  function removeSpline() {
79177    if (!swiper.controller.control) return;
79178    if (swiper.controller.spline) {
79179      swiper.controller.spline = void 0;
79180      delete swiper.controller.spline;
79181    }
79182  }
79183  on("beforeInit", () => {
79184    if (typeof window !== "undefined" && // eslint-disable-line
79185    (typeof swiper.params.controller.control === "string" || swiper.params.controller.control instanceof HTMLElement)) {
79186      const controlElements = typeof swiper.params.controller.control === "string" ? [...document.querySelectorAll(swiper.params.controller.control)] : [swiper.params.controller.control];
79187      controlElements.forEach((controlElement) => {
79188        if (!swiper.controller.control) swiper.controller.control = [];
79189        if (controlElement && controlElement.swiper) {
79190          swiper.controller.control.push(controlElement.swiper);
79191        } else if (controlElement) {
79192          const eventName = `${swiper.params.eventsPrefix}init`;
79193          const onControllerSwiper = (e) => {
79194            swiper.controller.control.push(e.detail[0]);
79195            swiper.update();
79196            controlElement.removeEventListener(eventName, onControllerSwiper);
79197          };
79198          controlElement.addEventListener(eventName, onControllerSwiper);
79199        }
79200      });
79201      return;
79202    }
79203    swiper.controller.control = swiper.params.controller.control;
79204  });
79205  on("update", () => {
79206    removeSpline();
79207  });
79208  on("resize", () => {
79209    removeSpline();
79210  });
79211  on("observerUpdate", () => {
79212    removeSpline();
79213  });
79214  on("setTranslate", (_s, translate2, byController) => {
79215    if (!swiper.controller.control || swiper.controller.control.destroyed) return;
79216    swiper.controller.setTranslate(translate2, byController);
79217  });
79218  on("setTransition", (_s, duration, byController) => {
79219    if (!swiper.controller.control || swiper.controller.control.destroyed) return;
79220    swiper.controller.setTransition(duration, byController);
79221  });
79222  Object.assign(swiper.controller, {
79223    setTranslate: setTranslate2,
79224    setTransition: setTransition2
79225  });
79226}
79227
vendor: 12,079 bytes, lines 79228-79585
79228// node_modules/swiper/modules/a11y.mjs
79229function A11y(_ref) {
79230  let {
79231    swiper,
79232    extendParams,
79233    on
79234  } = _ref;
79235  extendParams({
79236    a11y: {
79237      enabled: true,
79238      notificationClass: "swiper-notification",
79239      prevSlideMessage: "Previous slide",
79240      nextSlideMessage: "Next slide",
79241      firstSlideMessage: "This is the first slide",
79242      lastSlideMessage: "This is the last slide",
79243      paginationBulletMessage: "Go to slide {{index}}",
79244      slideLabelMessage: "{{index}} / {{slidesLength}}",
79245      containerMessage: null,
79246      containerRoleDescriptionMessage: null,
79247      containerRole: null,
79248      itemRoleDescriptionMessage: null,
79249      slideRole: "group",
79250      id: null,
79251      scrollOnFocus: true
79252    }
79253  });
79254  swiper.a11y = {
79255    clicked: false
79256  };
79257  let liveRegion = null;
79258  let preventFocusHandler;
79259  let focusTargetSlideEl;
79260  let visibilityChangedTimestamp = (/* @__PURE__ */ new Date()).getTime();
79261  function notify(message) {
79262    const notification = liveRegion;
79263    if (notification.length === 0) return;
79264    setInnerHTML(notification, message);
79265  }
79266  function getRandomNumber(size) {
79267    if (size === void 0) {
79268      size = 16;
79269    }
79270    const randomChar = () => Math.round(16 * Math.random()).toString(16);
79271    return "x".repeat(size).replace(/x/g, randomChar);
79272  }
79273  function makeElFocusable(el) {
79274    el = makeElementsArray(el);
79275    el.forEach((subEl) => {
79276      subEl.setAttribute("tabIndex", "0");
79277    });
79278  }
79279  function makeElNotFocusable(el) {
79280    el = makeElementsArray(el);
79281    el.forEach((subEl) => {
79282      subEl.setAttribute("tabIndex", "-1");
79283    });
79284  }
79285  function addElRole(el, role) {
79286    el = makeElementsArray(el);
79287    el.forEach((subEl) => {
79288      subEl.setAttribute("role", role);
79289    });
79290  }
79291  function addElRoleDescription(el, description) {
79292    el = makeElementsArray(el);
79293    el.forEach((subEl) => {
79294      subEl.setAttribute("aria-roledescription", description);
79295    });
79296  }
79297  function addElControls(el, controls) {
79298    el = makeElementsArray(el);
79299    el.forEach((subEl) => {
79300      subEl.setAttribute("aria-controls", controls);
79301    });
79302  }
79303  function addElLabel(el, label) {
79304    el = makeElementsArray(el);
79305    el.forEach((subEl) => {
79306      subEl.setAttribute("aria-label", label);
79307    });
79308  }
79309  function addElId(el, id) {
79310    el = makeElementsArray(el);
79311    el.forEach((subEl) => {
79312      subEl.setAttribute("id", id);
79313    });
79314  }
79315  function addElLive(el, live) {
79316    el = makeElementsArray(el);
79317    el.forEach((subEl) => {
79318      subEl.setAttribute("aria-live", live);
79319    });
79320  }
79321  function disableEl(el) {
79322    el = makeElementsArray(el);
79323    el.forEach((subEl) => {
79324      subEl.setAttribute("aria-disabled", true);
79325    });
79326  }
79327  function enableEl(el) {
79328    el = makeElementsArray(el);
79329    el.forEach((subEl) => {
79330      subEl.setAttribute("aria-disabled", false);
79331    });
79332  }
79333  function onEnterOrSpaceKey(e) {
79334    if (e.keyCode !== 13 && e.keyCode !== 32) return;
79335    const params = swiper.params.a11y;
79336    const targetEl = e.target;
79337    if (swiper.pagination && swiper.pagination.el && (targetEl === swiper.pagination.el || swiper.pagination.el.contains(e.target))) {
79338      if (!e.target.matches(classesToSelector(swiper.params.pagination.bulletClass))) return;
79339    }
79340    if (swiper.navigation && swiper.navigation.prevEl && swiper.navigation.nextEl) {
79341      const prevEls = makeElementsArray(swiper.navigation.prevEl);
79342      const nextEls = makeElementsArray(swiper.navigation.nextEl);
79343      if (nextEls.includes(targetEl)) {
79344        if (!(swiper.isEnd && !swiper.params.loop)) {
79345          swiper.slideNext();
79346        }
79347        if (swiper.isEnd) {
79348          notify(params.lastSlideMessage);
79349        } else {
79350          notify(params.nextSlideMessage);
79351        }
79352      }
79353      if (prevEls.includes(targetEl)) {
79354        if (!(swiper.isBeginning && !swiper.params.loop)) {
79355          swiper.slidePrev();
79356        }
79357        if (swiper.isBeginning) {
79358          notify(params.firstSlideMessage);
79359        } else {
79360          notify(params.prevSlideMessage);
79361        }
79362      }
79363    }
79364    if (swiper.pagination && targetEl.matches(classesToSelector(swiper.params.pagination.bulletClass))) {
79365      targetEl.click();
79366    }
79367  }
79368  function updateNavigation() {
79369    if (swiper.params.loop || swiper.params.rewind || !swiper.navigation) return;
79370    const {
79371      nextEl,
79372      prevEl
79373    } = swiper.navigation;
79374    if (prevEl) {
79375      if (swiper.isBeginning) {
79376        disableEl(prevEl);
79377        makeElNotFocusable(prevEl);
79378      } else {
79379        enableEl(prevEl);
79380        makeElFocusable(prevEl);
79381      }
79382    }
79383    if (nextEl) {
79384      if (swiper.isEnd) {
79385        disableEl(nextEl);
79386        makeElNotFocusable(nextEl);
79387      } else {
79388        enableEl(nextEl);
79389        makeElFocusable(nextEl);
79390      }
79391    }
79392  }
79393  function hasPagination() {
79394    return swiper.pagination && swiper.pagination.bullets && swiper.pagination.bullets.length;
79395  }
79396  function hasClickablePagination() {
79397    return hasPagination() && swiper.params.pagination.clickable;
79398  }
79399  function updatePagination() {
79400    const params = swiper.params.a11y;
79401    if (!hasPagination()) return;
79402    swiper.pagination.bullets.forEach((bulletEl) => {
79403      if (swiper.params.pagination.clickable) {
79404        makeElFocusable(bulletEl);
79405        if (!swiper.params.pagination.renderBullet) {
79406          addElRole(bulletEl, "button");
79407          addElLabel(bulletEl, params.paginationBulletMessage.replace(/\{\{index\}\}/, elementIndex(bulletEl) + 1));
79408        }
79409      }
79410      if (bulletEl.matches(classesToSelector(swiper.params.pagination.bulletActiveClass))) {
79411        bulletEl.setAttribute("aria-current", "true");
79412      } else {
79413        bulletEl.removeAttribute("aria-current");
79414      }
79415    });
79416  }
79417  const initNavEl = (el, wrapperId, message) => {
79418    makeElFocusable(el);
79419    if (el.tagName !== "BUTTON") {
79420      addElRole(el, "button");
79421      el.addEventListener("keydown", onEnterOrSpaceKey);
79422    }
79423    addElLabel(el, message);
79424    addElControls(el, wrapperId);
79425  };
79426  const handlePointerDown = (e) => {
79427    if (focusTargetSlideEl && focusTargetSlideEl !== e.target && !focusTargetSlideEl.contains(e.target)) {
79428      preventFocusHandler = true;
79429    }
79430    swiper.a11y.clicked = true;
79431  };
79432  const handlePointerUp = () => {
79433    preventFocusHandler = false;
79434    requestAnimationFrame(() => {
79435      requestAnimationFrame(() => {
79436        if (!swiper.destroyed) {
79437          swiper.a11y.clicked = false;
79438        }
79439      });
79440    });
79441  };
79442  const onVisibilityChange = (e) => {
79443    visibilityChangedTimestamp = (/* @__PURE__ */ new Date()).getTime();
79444  };
79445  const handleFocus = (e) => {
79446    if (swiper.a11y.clicked || !swiper.params.a11y.scrollOnFocus) return;
79447    if ((/* @__PURE__ */ new Date()).getTime() - visibilityChangedTimestamp < 100) return;
79448    const slideEl = e.target.closest(`.${swiper.params.slideClass}, swiper-slide`);
79449    if (!slideEl || !swiper.slides.includes(slideEl)) return;
79450    focusTargetSlideEl = slideEl;
79451    const isActive = swiper.slides.indexOf(slideEl) === swiper.activeIndex;
79452    const isVisible = swiper.params.watchSlidesProgress && swiper.visibleSlides && swiper.visibleSlides.includes(slideEl);
79453    if (isActive || isVisible) return;
79454    if (e.sourceCapabilities && e.sourceCapabilities.firesTouchEvents) return;
79455    if (swiper.isHorizontal()) {
79456      swiper.el.scrollLeft = 0;
79457    } else {
79458      swiper.el.scrollTop = 0;
79459    }
79460    requestAnimationFrame(() => {
79461      if (preventFocusHandler) return;
79462      if (swiper.params.loop) {
79463        swiper.slideToLoop(swiper.getSlideIndexWhenGrid(parseInt(slideEl.getAttribute("data-swiper-slide-index"))), 0);
79464      } else {
79465        swiper.slideTo(swiper.getSlideIndexWhenGrid(swiper.slides.indexOf(slideEl)), 0);
79466      }
79467      preventFocusHandler = false;
79468    });
79469  };
79470  const initSlides = () => {
79471    const params = swiper.params.a11y;
79472    if (params.itemRoleDescriptionMessage) {
79473      addElRoleDescription(swiper.slides, params.itemRoleDescriptionMessage);
79474    }
79475    if (params.slideRole) {
79476      addElRole(swiper.slides, params.slideRole);
79477    }
79478    const slidesLength = swiper.slides.length;
79479    if (params.slideLabelMessage) {
79480      swiper.slides.forEach((slideEl, index) => {
79481        const slideIndex = swiper.params.loop ? parseInt(slideEl.getAttribute("data-swiper-slide-index"), 10) : index;
79482        const ariaLabelMessage = params.slideLabelMessage.replace(/\{\{index\}\}/, slideIndex + 1).replace(/\{\{slidesLength\}\}/, slidesLength);
79483        addElLabel(slideEl, ariaLabelMessage);
79484      });
79485    }
79486  };
79487  const init = () => {
79488    const params = swiper.params.a11y;
79489    swiper.el.append(liveRegion);
79490    const containerEl = swiper.el;
79491    if (params.containerRoleDescriptionMessage) {
79492      addElRoleDescription(containerEl, params.containerRoleDescriptionMessage);
79493    }
79494    if (params.containerMessage) {
79495      addElLabel(containerEl, params.containerMessage);
79496    }
79497    if (params.containerRole) {
79498      addElRole(containerEl, params.containerRole);
79499    }
79500    const wrapperEl = swiper.wrapperEl;
79501    const wrapperId = params.id || wrapperEl.getAttribute("id") || `swiper-wrapper-${getRandomNumber(16)}`;
79502    const live = swiper.params.autoplay && swiper.params.autoplay.enabled ? "off" : "polite";
79503    addElId(wrapperEl, wrapperId);
79504    addElLive(wrapperEl, live);
79505    initSlides();
79506    let {
79507      nextEl,
79508      prevEl
79509    } = swiper.navigation ? swiper.navigation : {};
79510    nextEl = makeElementsArray(nextEl);
79511    prevEl = makeElementsArray(prevEl);
79512    if (nextEl) {
79513      nextEl.forEach((el) => initNavEl(el, wrapperId, params.nextSlideMessage));
79514    }
79515    if (prevEl) {
79516      prevEl.forEach((el) => initNavEl(el, wrapperId, params.prevSlideMessage));
79517    }
79518    if (hasClickablePagination()) {
79519      const paginationEl = makeElementsArray(swiper.pagination.el);
79520      paginationEl.forEach((el) => {
79521        el.addEventListener("keydown", onEnterOrSpaceKey);
79522      });
79523    }
79524    const document2 = getDocument();
79525    document2.addEventListener("visibilitychange", onVisibilityChange);
79526    swiper.el.addEventListener("focus", handleFocus, true);
79527    swiper.el.addEventListener("focus", handleFocus, true);
79528    swiper.el.addEventListener("pointerdown", handlePointerDown, true);
79529    swiper.el.addEventListener("pointerup", handlePointerUp, true);
79530  };
79531  function destroy() {
79532    if (liveRegion) liveRegion.remove();
79533    let {
79534      nextEl,
79535      prevEl
79536    } = swiper.navigation ? swiper.navigation : {};
79537    nextEl = makeElementsArray(nextEl);
79538    prevEl = makeElementsArray(prevEl);
79539    if (nextEl) {
79540      nextEl.forEach((el) => el.removeEventListener("keydown", onEnterOrSpaceKey));
79541    }
79542    if (prevEl) {
79543      prevEl.forEach((el) => el.removeEventListener("keydown", onEnterOrSpaceKey));
79544    }
79545    if (hasClickablePagination()) {
79546      const paginationEl = makeElementsArray(swiper.pagination.el);
79547      paginationEl.forEach((el) => {
79548        el.removeEventListener("keydown", onEnterOrSpaceKey);
79549      });
79550    }
79551    const document2 = getDocument();
79552    document2.removeEventListener("visibilitychange", onVisibilityChange);
79553    if (swiper.el && typeof swiper.el !== "string") {
79554      swiper.el.removeEventListener("focus", handleFocus, true);
79555      swiper.el.removeEventListener("pointerdown", handlePointerDown, true);
79556      swiper.el.removeEventListener("pointerup", handlePointerUp, true);
79557    }
79558  }
79559  on("beforeInit", () => {
79560    liveRegion = createElement("span", swiper.params.a11y.notificationClass);
79561    liveRegion.setAttribute("aria-live", "assertive");
79562    liveRegion.setAttribute("aria-atomic", "true");
79563  });
79564  on("afterInit", () => {
79565    if (!swiper.params.a11y.enabled) return;
79566    init();
79567  });
79568  on("slidesLengthChange snapGridLengthChange slidesGridLengthChange", () => {
79569    if (!swiper.params.a11y.enabled) return;
79570    initSlides();
79571  });
79572  on("fromEdge toEdge afterInit lock unlock", () => {
79573    if (!swiper.params.a11y.enabled) return;
79574    updateNavigation();
79575  });
79576  on("paginationUpdate", () => {
79577    if (!swiper.params.a11y.enabled) return;
79578    updatePagination();
79579  });
79580  on("destroy", () => {
79581    if (!swiper.params.a11y.enabled) return;
79582    destroy();
79583  });
79584}
79585
vendor: 4,258 bytes, lines 79586-79725
79586// node_modules/swiper/modules/history.mjs
79587function History(_ref) {
79588  let {
79589    swiper,
79590    extendParams,
79591    on
79592  } = _ref;
79593  extendParams({
79594    history: {
79595      enabled: false,
79596      root: "",
79597      replaceState: false,
79598      key: "slides",
79599      keepQuery: false
79600    }
79601  });
79602  let initialized = false;
79603  let paths = {};
79604  const slugify = (text2) => {
79605    return text2.toString().replace(/\s+/g, "-").replace(/[^\w-]+/g, "").replace(/--+/g, "-").replace(/^-+/, "").replace(/-+$/, "");
79606  };
79607  const getPathValues = (urlOverride) => {
79608    const window2 = getWindow();
79609    let location;
79610    if (urlOverride) {
79611      location = new URL(urlOverride);
79612    } else {
79613      location = window2.location;
79614    }
79615    const pathArray = location.pathname.slice(1).split("/").filter((part) => part !== "");
79616    const total = pathArray.length;
79617    const key = pathArray[total - 2];
79618    const value = pathArray[total - 1];
79619    return {
79620      key,
79621      value
79622    };
79623  };
79624  const setHistory = (key, index) => {
79625    const window2 = getWindow();
79626    if (!initialized || !swiper.params.history.enabled) return;
79627    let location;
79628    if (swiper.params.url) {
79629      location = new URL(swiper.params.url);
79630    } else {
79631      location = window2.location;
79632    }
79633    const slide2 = swiper.virtual && swiper.params.virtual.enabled ? swiper.slidesEl.querySelector(`[data-swiper-slide-index="${index}"]`) : swiper.slides[index];
79634    let value = slugify(slide2.getAttribute("data-history"));
79635    if (swiper.params.history.root.length > 0) {
79636      let root = swiper.params.history.root;
79637      if (root[root.length - 1] === "/") root = root.slice(0, root.length - 1);
79638      value = `${root}/${key ? `${key}/` : ""}${value}`;
79639    } else if (!location.pathname.includes(key)) {
79640      value = `${key ? `${key}/` : ""}${value}`;
79641    }
79642    if (swiper.params.history.keepQuery) {
79643      value += location.search;
79644    }
79645    const currentState = window2.history.state;
79646    if (currentState && currentState.value === value) {
79647      return;
79648    }
79649    if (swiper.params.history.replaceState) {
79650      window2.history.replaceState({
79651        value
79652      }, null, value);
79653    } else {
79654      window2.history.pushState({
79655        value
79656      }, null, value);
79657    }
79658  };
79659  const scrollToSlide = (speed, value, runCallbacks) => {
79660    if (value) {
79661      for (let i = 0, length = swiper.slides.length; i < length; i += 1) {
79662        const slide2 = swiper.slides[i];
79663        const slideHistory = slugify(slide2.getAttribute("data-history"));
79664        if (slideHistory === value) {
79665          const index = swiper.getSlideIndex(slide2);
79666          swiper.slideTo(index, speed, runCallbacks);
79667        }
79668      }
79669    } else {
79670      swiper.slideTo(0, speed, runCallbacks);
79671    }
79672  };
79673  const setHistoryPopState = () => {
79674    paths = getPathValues(swiper.params.url);
79675    scrollToSlide(swiper.params.speed, paths.value, false);
79676  };
79677  const init = () => {
79678    const window2 = getWindow();
79679    if (!swiper.params.history) return;
79680    if (!window2.history || !window2.history.pushState) {
79681      swiper.params.history.enabled = false;
79682      swiper.params.hashNavigation.enabled = true;
79683      return;
79684    }
79685    initialized = true;
79686    paths = getPathValues(swiper.params.url);
79687    if (!paths.key && !paths.value) {
79688      if (!swiper.params.history.replaceState) {
79689        window2.addEventListener("popstate", setHistoryPopState);
79690      }
79691      return;
79692    }
79693    scrollToSlide(0, paths.value, swiper.params.runCallbacksOnInit);
79694    if (!swiper.params.history.replaceState) {
79695      window2.addEventListener("popstate", setHistoryPopState);
79696    }
79697  };
79698  const destroy = () => {
79699    const window2 = getWindow();
79700    if (!swiper.params.history.replaceState) {
79701      window2.removeEventListener("popstate", setHistoryPopState);
79702    }
79703  };
79704  on("init", () => {
79705    if (swiper.params.history.enabled) {
79706      init();
79707    }
79708  });
79709  on("destroy", () => {
79710    if (swiper.params.history.enabled) {
79711      destroy();
79712    }
79713  });
79714  on("transitionEnd _freeModeNoMomentumRelease", () => {
79715    if (initialized) {
79716      setHistory(swiper.params.history.key, swiper.activeIndex);
79717    }
79718  });
79719  on("slideChange", () => {
79720    if (initialized && swiper.params.cssMode) {
79721      setHistory(swiper.params.history.key, swiper.activeIndex);
79722    }
79723  });
79724}
79725
vendor: 3,399 bytes, lines 79726-79815
79726// node_modules/swiper/modules/hash-navigation.mjs
79727function HashNavigation(_ref) {
79728  let {
79729    swiper,
79730    extendParams,
79731    emit,
79732    on
79733  } = _ref;
79734  let initialized = false;
79735  const document2 = getDocument();
79736  const window2 = getWindow();
79737  extendParams({
79738    hashNavigation: {
79739      enabled: false,
79740      replaceState: false,
79741      watchState: false,
79742      getSlideIndex(_s, hash) {
79743        if (swiper.virtual && swiper.params.virtual.enabled) {
79744          const slideWithHash = swiper.slides.find((slideEl) => slideEl.getAttribute("data-hash") === hash);
79745          if (!slideWithHash) return 0;
79746          const index = parseInt(slideWithHash.getAttribute("data-swiper-slide-index"), 10);
79747          return index;
79748        }
79749        return swiper.getSlideIndex(elementChildren(swiper.slidesEl, `.${swiper.params.slideClass}[data-hash="${hash}"], swiper-slide[data-hash="${hash}"]`)[0]);
79750      }
79751    }
79752  });
79753  const onHashChange = () => {
79754    emit("hashChange");
79755    const newHash = document2.location.hash.replace("#", "");
79756    const activeSlideEl = swiper.virtual && swiper.params.virtual.enabled ? swiper.slidesEl.querySelector(`[data-swiper-slide-index="${swiper.activeIndex}"]`) : swiper.slides[swiper.activeIndex];
79757    const activeSlideHash = activeSlideEl ? activeSlideEl.getAttribute("data-hash") : "";
79758    if (newHash !== activeSlideHash) {
79759      const newIndex = swiper.params.hashNavigation.getSlideIndex(swiper, newHash);
79760      if (typeof newIndex === "undefined" || Number.isNaN(newIndex)) return;
79761      swiper.slideTo(newIndex);
79762    }
79763  };
79764  const setHash = () => {
79765    if (!initialized || !swiper.params.hashNavigation.enabled) return;
79766    const activeSlideEl = swiper.virtual && swiper.params.virtual.enabled ? swiper.slidesEl.querySelector(`[data-swiper-slide-index="${swiper.activeIndex}"]`) : swiper.slides[swiper.activeIndex];
79767    const activeSlideHash = activeSlideEl ? activeSlideEl.getAttribute("data-hash") || activeSlideEl.getAttribute("data-history") : "";
79768    if (swiper.params.hashNavigation.replaceState && window2.history && window2.history.replaceState) {
79769      window2.history.replaceState(null, null, `#${activeSlideHash}` || "");
79770      emit("hashSet");
79771    } else {
79772      document2.location.hash = activeSlideHash || "";
79773      emit("hashSet");
79774    }
79775  };
79776  const init = () => {
79777    if (!swiper.params.hashNavigation.enabled || swiper.params.history && swiper.params.history.enabled) return;
79778    initialized = true;
79779    const hash = document2.location.hash.replace("#", "");
79780    if (hash) {
79781      const speed = 0;
79782      const index = swiper.params.hashNavigation.getSlideIndex(swiper, hash);
79783      swiper.slideTo(index || 0, speed, swiper.params.runCallbacksOnInit, true);
79784    }
79785    if (swiper.params.hashNavigation.watchState) {
79786      window2.addEventListener("hashchange", onHashChange);
79787    }
79788  };
79789  const destroy = () => {
79790    if (swiper.params.hashNavigation.watchState) {
79791      window2.removeEventListener("hashchange", onHashChange);
79792    }
79793  };
79794  on("init", () => {
79795    if (swiper.params.hashNavigation.enabled) {
79796      init();
79797    }
79798  });
79799  on("destroy", () => {
79800    if (swiper.params.hashNavigation.enabled) {
79801      destroy();
79802    }
79803  });
79804  on("transitionEnd _freeModeNoMomentumRelease", () => {
79805    if (initialized) {
79806      setHash();
79807    }
79808  });
79809  on("slideChange", () => {
79810    if (initialized && swiper.params.cssMode) {
79811      setHash();
79812    }
79813  });
79814}
79815
vendor: 9,207 bytes, lines 79816-80113
79816// node_modules/swiper/modules/autoplay.mjs
79817function Autoplay(_ref) {
79818  let {
79819    swiper,
79820    extendParams,
79821    on,
79822    emit,
79823    params
79824  } = _ref;
79825  swiper.autoplay = {
79826    running: false,
79827    paused: false,
79828    timeLeft: 0
79829  };
79830  extendParams({
79831    autoplay: {
79832      enabled: false,
79833      delay: 3e3,
79834      waitForTransition: true,
79835      disableOnInteraction: false,
79836      stopOnLastSlide: false,
79837      reverseDirection: false,
79838      pauseOnMouseEnter: false
79839    }
79840  });
79841  let timeout;
79842  let raf;
79843  let autoplayDelayTotal = params && params.autoplay ? params.autoplay.delay : 3e3;
79844  let autoplayDelayCurrent = params && params.autoplay ? params.autoplay.delay : 3e3;
79845  let autoplayTimeLeft;
79846  let autoplayStartTime = (/* @__PURE__ */ new Date()).getTime();
79847  let wasPaused;
79848  let isTouched;
79849  let pausedByTouch;
79850  let touchStartTimeout;
79851  let slideChanged;
79852  let pausedByInteraction;
79853  let pausedByPointerEnter;
79854  function onTransitionEnd(e) {
79855    if (!swiper || swiper.destroyed || !swiper.wrapperEl) return;
79856    if (e.target !== swiper.wrapperEl) return;
79857    swiper.wrapperEl.removeEventListener("transitionend", onTransitionEnd);
79858    if (pausedByPointerEnter || e.detail && e.detail.bySwiperTouchMove) {
79859      return;
79860    }
79861    resume();
79862  }
79863  const calcTimeLeft = () => {
79864    if (swiper.destroyed || !swiper.autoplay.running) return;
79865    if (swiper.autoplay.paused) {
79866      wasPaused = true;
79867    } else if (wasPaused) {
79868      autoplayDelayCurrent = autoplayTimeLeft;
79869      wasPaused = false;
79870    }
79871    const timeLeft = swiper.autoplay.paused ? autoplayTimeLeft : autoplayStartTime + autoplayDelayCurrent - (/* @__PURE__ */ new Date()).getTime();
79872    swiper.autoplay.timeLeft = timeLeft;
79873    emit("autoplayTimeLeft", timeLeft, timeLeft / autoplayDelayTotal);
79874    raf = requestAnimationFrame(() => {
79875      calcTimeLeft();
79876    });
79877  };
79878  const getSlideDelay = () => {
79879    let activeSlideEl;
79880    if (swiper.virtual && swiper.params.virtual.enabled) {
79881      activeSlideEl = swiper.slides.find((slideEl) => slideEl.classList.contains("swiper-slide-active"));
79882    } else {
79883      activeSlideEl = swiper.slides[swiper.activeIndex];
79884    }
79885    if (!activeSlideEl) return void 0;
79886    const currentSlideDelay = parseInt(activeSlideEl.getAttribute("data-swiper-autoplay"), 10);
79887    return currentSlideDelay;
79888  };
79889  const run = (delayForce) => {
79890    if (swiper.destroyed || !swiper.autoplay.running) return;
79891    cancelAnimationFrame(raf);
79892    calcTimeLeft();
79893    let delay = typeof delayForce === "undefined" ? swiper.params.autoplay.delay : delayForce;
79894    autoplayDelayTotal = swiper.params.autoplay.delay;
79895    autoplayDelayCurrent = swiper.params.autoplay.delay;
79896    const currentSlideDelay = getSlideDelay();
79897    if (!Number.isNaN(currentSlideDelay) && currentSlideDelay > 0 && typeof delayForce === "undefined") {
79898      delay = currentSlideDelay;
79899      autoplayDelayTotal = currentSlideDelay;
79900      autoplayDelayCurrent = currentSlideDelay;
79901    }
79902    autoplayTimeLeft = delay;
79903    const speed = swiper.params.speed;
79904    const proceed = () => {
79905      if (!swiper || swiper.destroyed) return;
79906      if (swiper.params.autoplay.reverseDirection) {
79907        if (!swiper.isBeginning || swiper.params.loop || swiper.params.rewind) {
79908          swiper.slidePrev(speed, true, true);
79909          emit("autoplay");
79910        } else if (!swiper.params.autoplay.stopOnLastSlide) {
79911          swiper.slideTo(swiper.slides.length - 1, speed, true, true);
79912          emit("autoplay");
79913        }
79914      } else {
79915        if (!swiper.isEnd || swiper.params.loop || swiper.params.rewind) {
79916          swiper.slideNext(speed, true, true);
79917          emit("autoplay");
79918        } else if (!swiper.params.autoplay.stopOnLastSlide) {
79919          swiper.slideTo(0, speed, true, true);
79920          emit("autoplay");
79921        }
79922      }
79923      if (swiper.params.cssMode) {
79924        autoplayStartTime = (/* @__PURE__ */ new Date()).getTime();
79925        requestAnimationFrame(() => {
79926          run();
79927        });
79928      }
79929    };
79930    if (delay > 0) {
79931      clearTimeout(timeout);
79932      timeout = setTimeout(() => {
79933        proceed();
79934      }, delay);
79935    } else {
79936      requestAnimationFrame(() => {
79937        proceed();
79938      });
79939    }
79940    return delay;
79941  };
79942  const start = () => {
79943    autoplayStartTime = (/* @__PURE__ */ new Date()).getTime();
79944    swiper.autoplay.running = true;
79945    run();
79946    emit("autoplayStart");
79947  };
79948  const stop = () => {
79949    swiper.autoplay.running = false;
79950    clearTimeout(timeout);
79951    cancelAnimationFrame(raf);
79952    emit("autoplayStop");
79953  };
79954  const pause = (internal, reset) => {
79955    if (swiper.destroyed || !swiper.autoplay.running) return;
79956    clearTimeout(timeout);
79957    if (!internal) {
79958      pausedByInteraction = true;
79959    }
79960    const proceed = () => {
79961      emit("autoplayPause");
79962      if (swiper.params.autoplay.waitForTransition) {
79963        swiper.wrapperEl.addEventListener("transitionend", onTransitionEnd);
79964      } else {
79965        resume();
79966      }
79967    };
79968    swiper.autoplay.paused = true;
79969    if (reset) {
79970      if (slideChanged) {
79971        autoplayTimeLeft = swiper.params.autoplay.delay;
79972      }
79973      slideChanged = false;
79974      proceed();
79975      return;
79976    }
79977    const delay = autoplayTimeLeft || swiper.params.autoplay.delay;
79978    autoplayTimeLeft = delay - ((/* @__PURE__ */ new Date()).getTime() - autoplayStartTime);
79979    if (swiper.isEnd && autoplayTimeLeft < 0 && !swiper.params.loop) return;
79980    if (autoplayTimeLeft < 0) autoplayTimeLeft = 0;
79981    proceed();
79982  };
79983  const resume = () => {
79984    if (swiper.isEnd && autoplayTimeLeft < 0 && !swiper.params.loop || swiper.destroyed || !swiper.autoplay.running) return;
79985    autoplayStartTime = (/* @__PURE__ */ new Date()).getTime();
79986    if (pausedByInteraction) {
79987      pausedByInteraction = false;
79988      run(autoplayTimeLeft);
79989    } else {
79990      run();
79991    }
79992    swiper.autoplay.paused = false;
79993    emit("autoplayResume");
79994  };
79995  const onVisibilityChange = () => {
79996    if (swiper.destroyed || !swiper.autoplay.running) return;
79997    const document2 = getDocument();
79998    if (document2.visibilityState === "hidden") {
79999      pausedByInteraction = true;
80000      pause(true);
80001    }
80002    if (document2.visibilityState === "visible") {
80003      resume();
80004    }
80005  };
80006  const onPointerEnter = (e) => {
80007    if (e.pointerType !== "mouse") return;
80008    pausedByInteraction = true;
80009    pausedByPointerEnter = true;
80010    if (swiper.animating || swiper.autoplay.paused) return;
80011    pause(true);
80012  };
80013  const onPointerLeave = (e) => {
80014    if (e.pointerType !== "mouse") return;
80015    pausedByPointerEnter = false;
80016    if (swiper.autoplay.paused) {
80017      resume();
80018    }
80019  };
80020  const attachMouseEvents = () => {
80021    if (swiper.params.autoplay.pauseOnMouseEnter) {
80022      swiper.el.addEventListener("pointerenter", onPointerEnter);
80023      swiper.el.addEventListener("pointerleave", onPointerLeave);
80024    }
80025  };
80026  const detachMouseEvents = () => {
80027    if (swiper.el && typeof swiper.el !== "string") {
80028      swiper.el.removeEventListener("pointerenter", onPointerEnter);
80029      swiper.el.removeEventListener("pointerleave", onPointerLeave);
80030    }
80031  };
80032  const attachDocumentEvents = () => {
80033    const document2 = getDocument();
80034    document2.addEventListener("visibilitychange", onVisibilityChange);
80035  };
80036  const detachDocumentEvents = () => {
80037    const document2 = getDocument();
80038    document2.removeEventListener("visibilitychange", onVisibilityChange);
80039  };
80040  on("init", () => {
80041    if (swiper.params.autoplay.enabled) {
80042      attachMouseEvents();
80043      attachDocumentEvents();
80044      start();
80045    }
80046  });
80047  on("destroy", () => {
80048    detachMouseEvents();
80049    detachDocumentEvents();
80050    if (swiper.autoplay.running) {
80051      stop();
80052    }
80053  });
80054  on("_freeModeStaticRelease", () => {
80055    if (pausedByTouch || pausedByInteraction) {
80056      resume();
80057    }
80058  });
80059  on("_freeModeNoMomentumRelease", () => {
80060    if (!swiper.params.autoplay.disableOnInteraction) {
80061      pause(true, true);
80062    } else {
80063      stop();
80064    }
80065  });
80066  on("beforeTransitionStart", (_s, speed, internal) => {
80067    if (swiper.destroyed || !swiper.autoplay.running) return;
80068    if (internal || !swiper.params.autoplay.disableOnInteraction) {
80069      pause(true, true);
80070    } else {
80071      stop();
80072    }
80073  });
80074  on("sliderFirstMove", () => {
80075    if (swiper.destroyed || !swiper.autoplay.running) return;
80076    if (swiper.params.autoplay.disableOnInteraction) {
80077      stop();
80078      return;
80079    }
80080    isTouched = true;
80081    pausedByTouch = false;
80082    pausedByInteraction = false;
80083    touchStartTimeout = setTimeout(() => {
80084      pausedByInteraction = true;
80085      pausedByTouch = true;
80086      pause(true);
80087    }, 200);
80088  });
80089  on("touchEnd", () => {
80090    if (swiper.destroyed || !swiper.autoplay.running || !isTouched) return;
80091    clearTimeout(touchStartTimeout);
80092    clearTimeout(timeout);
80093    if (swiper.params.autoplay.disableOnInteraction) {
80094      pausedByTouch = false;
80095      isTouched = false;
80096      return;
80097    }
80098    if (pausedByTouch && swiper.params.cssMode) resume();
80099    pausedByTouch = false;
80100    isTouched = false;
80101  });
80102  on("slideChange", () => {
80103    if (swiper.destroyed || !swiper.autoplay.running) return;
80104    slideChanged = true;
80105  });
80106  Object.assign(swiper.autoplay, {
80107    start,
80108    stop,
80109    pause,
80110    resume
80111  });
80112}
80113
vendor: 7,215 bytes, lines 80114-80305
80114// node_modules/swiper/modules/thumbs.mjs
80115function Thumb(_ref) {
80116  let {
80117    swiper,
80118    extendParams,
80119    on
80120  } = _ref;
80121  extendParams({
80122    thumbs: {
80123      swiper: null,
80124      multipleActiveThumbs: true,
80125      autoScrollOffset: 0,
80126      slideThumbActiveClass: "swiper-slide-thumb-active",
80127      thumbsContainerClass: "swiper-thumbs"
80128    }
80129  });
80130  let initialized = false;
80131  let swiperCreated = false;
80132  swiper.thumbs = {
80133    swiper: null
80134  };
80135  function onThumbClick() {
80136    const thumbsSwiper = swiper.thumbs.swiper;
80137    if (!thumbsSwiper || thumbsSwiper.destroyed) return;
80138    const clickedIndex = thumbsSwiper.clickedIndex;
80139    const clickedSlide = thumbsSwiper.clickedSlide;
80140    if (clickedSlide && clickedSlide.classList.contains(swiper.params.thumbs.slideThumbActiveClass)) return;
80141    if (typeof clickedIndex === "undefined" || clickedIndex === null) return;
80142    let slideToIndex;
80143    if (thumbsSwiper.params.loop) {
80144      slideToIndex = parseInt(thumbsSwiper.clickedSlide.getAttribute("data-swiper-slide-index"), 10);
80145    } else {
80146      slideToIndex = clickedIndex;
80147    }
80148    if (swiper.params.loop) {
80149      swiper.slideToLoop(slideToIndex);
80150    } else {
80151      swiper.slideTo(slideToIndex);
80152    }
80153  }
80154  function init() {
80155    const {
80156      thumbs: thumbsParams
80157    } = swiper.params;
80158    if (initialized) return false;
80159    initialized = true;
80160    const SwiperClass = swiper.constructor;
80161    if (thumbsParams.swiper instanceof SwiperClass) {
80162      if (thumbsParams.swiper.destroyed) {
80163        initialized = false;
80164        return false;
80165      }
80166      swiper.thumbs.swiper = thumbsParams.swiper;
80167      Object.assign(swiper.thumbs.swiper.originalParams, {
80168        watchSlidesProgress: true,
80169        slideToClickedSlide: false
80170      });
80171      Object.assign(swiper.thumbs.swiper.params, {
80172        watchSlidesProgress: true,
80173        slideToClickedSlide: false
80174      });
80175      swiper.thumbs.swiper.update();
80176    } else if (isObject5(thumbsParams.swiper)) {
80177      const thumbsSwiperParams = Object.assign({}, thumbsParams.swiper);
80178      Object.assign(thumbsSwiperParams, {
80179        watchSlidesProgress: true,
80180        slideToClickedSlide: false
80181      });
80182      swiper.thumbs.swiper = new SwiperClass(thumbsSwiperParams);
80183      swiperCreated = true;
80184    }
80185    swiper.thumbs.swiper.el.classList.add(swiper.params.thumbs.thumbsContainerClass);
80186    swiper.thumbs.swiper.on("tap", onThumbClick);
80187    return true;
80188  }
80189  function update2(initial) {
80190    const thumbsSwiper = swiper.thumbs.swiper;
80191    if (!thumbsSwiper || thumbsSwiper.destroyed) return;
80192    const slidesPerView = thumbsSwiper.params.slidesPerView === "auto" ? thumbsSwiper.slidesPerViewDynamic() : thumbsSwiper.params.slidesPerView;
80193    let thumbsToActivate = 1;
80194    const thumbActiveClass = swiper.params.thumbs.slideThumbActiveClass;
80195    if (swiper.params.slidesPerView > 1 && !swiper.params.centeredSlides) {
80196      thumbsToActivate = swiper.params.slidesPerView;
80197    }
80198    if (!swiper.params.thumbs.multipleActiveThumbs) {
80199      thumbsToActivate = 1;
80200    }
80201    thumbsToActivate = Math.floor(thumbsToActivate);
80202    thumbsSwiper.slides.forEach((slideEl) => slideEl.classList.remove(thumbActiveClass));
80203    if (thumbsSwiper.params.loop || thumbsSwiper.params.virtual && thumbsSwiper.params.virtual.enabled) {
80204      for (let i = 0; i < thumbsToActivate; i += 1) {
80205        elementChildren(thumbsSwiper.slidesEl, `[data-swiper-slide-index="${swiper.realIndex + i}"]`).forEach((slideEl) => {
80206          slideEl.classList.add(thumbActiveClass);
80207        });
80208      }
80209    } else {
80210      for (let i = 0; i < thumbsToActivate; i += 1) {
80211        if (thumbsSwiper.slides[swiper.realIndex + i]) {
80212          thumbsSwiper.slides[swiper.realIndex + i].classList.add(thumbActiveClass);
80213        }
80214      }
80215    }
80216    const autoScrollOffset = swiper.params.thumbs.autoScrollOffset;
80217    const useOffset = autoScrollOffset && !thumbsSwiper.params.loop;
80218    if (swiper.realIndex !== thumbsSwiper.realIndex || useOffset) {
80219      const currentThumbsIndex = thumbsSwiper.activeIndex;
80220      let newThumbsIndex;
80221      let direction;
80222      if (thumbsSwiper.params.loop) {
80223        const newThumbsSlide = thumbsSwiper.slides.find((slideEl) => slideEl.getAttribute("data-swiper-slide-index") === `${swiper.realIndex}`);
80224        newThumbsIndex = thumbsSwiper.slides.indexOf(newThumbsSlide);
80225        direction = swiper.activeIndex > swiper.previousIndex ? "next" : "prev";
80226      } else {
80227        newThumbsIndex = swiper.realIndex;
80228        direction = newThumbsIndex > swiper.previousIndex ? "next" : "prev";
80229      }
80230      if (useOffset) {
80231        newThumbsIndex += direction === "next" ? autoScrollOffset : -1 * autoScrollOffset;
80232      }
80233      if (thumbsSwiper.visibleSlidesIndexes && thumbsSwiper.visibleSlidesIndexes.indexOf(newThumbsIndex) < 0) {
80234        if (thumbsSwiper.params.centeredSlides) {
80235          if (newThumbsIndex > currentThumbsIndex) {
80236            newThumbsIndex = newThumbsIndex - Math.floor(slidesPerView / 2) + 1;
80237          } else {
80238            newThumbsIndex = newThumbsIndex + Math.floor(slidesPerView / 2) - 1;
80239          }
80240        } else if (newThumbsIndex > currentThumbsIndex && thumbsSwiper.params.slidesPerGroup === 1) ;
80241        thumbsSwiper.slideTo(newThumbsIndex, initial ? 0 : void 0);
80242      }
80243    }
80244  }
80245  on("beforeInit", () => {
80246    const {
80247      thumbs
80248    } = swiper.params;
80249    if (!thumbs || !thumbs.swiper) return;
80250    if (typeof thumbs.swiper === "string" || thumbs.swiper instanceof HTMLElement) {
80251      const document2 = getDocument();
80252      const getThumbsElementAndInit = () => {
80253        const thumbsElement = typeof thumbs.swiper === "string" ? document2.querySelector(thumbs.swiper) : thumbs.swiper;
80254        if (thumbsElement && thumbsElement.swiper) {
80255          thumbs.swiper = thumbsElement.swiper;
80256          init();
80257          update2(true);
80258        } else if (thumbsElement) {
80259          const eventName = `${swiper.params.eventsPrefix}init`;
80260          const onThumbsSwiper = (e) => {
80261            thumbs.swiper = e.detail[0];
80262            thumbsElement.removeEventListener(eventName, onThumbsSwiper);
80263            init();
80264            update2(true);
80265            thumbs.swiper.update();
80266            swiper.update();
80267          };
80268          thumbsElement.addEventListener(eventName, onThumbsSwiper);
80269        }
80270        return thumbsElement;
80271      };
80272      const watchForThumbsToAppear = () => {
80273        if (swiper.destroyed) return;
80274        const thumbsElement = getThumbsElementAndInit();
80275        if (!thumbsElement) {
80276          requestAnimationFrame(watchForThumbsToAppear);
80277        }
80278      };
80279      requestAnimationFrame(watchForThumbsToAppear);
80280    } else {
80281      init();
80282      update2(true);
80283    }
80284  });
80285  on("slideChange update resize observerUpdate", () => {
80286    update2();
80287  });
80288  on("setTransition", (_s, duration) => {
80289    const thumbsSwiper = swiper.thumbs.swiper;
80290    if (!thumbsSwiper || thumbsSwiper.destroyed) return;
80291    thumbsSwiper.setTransition(duration);
80292  });
80293  on("beforeDestroy", () => {
80294    const thumbsSwiper = swiper.thumbs.swiper;
80295    if (!thumbsSwiper || thumbsSwiper.destroyed) return;
80296    if (swiperCreated) {
80297      thumbsSwiper.destroy();
80298    }
80299  });
80300  Object.assign(swiper.thumbs, {
80301    init,
80302    update: update2
80303  });
80304}
80305
vendor: 7,563 bytes, lines 80306-80528
80306// node_modules/swiper/modules/free-mode.mjs
80307function freeMode(_ref) {
80308  let {
80309    swiper,
80310    extendParams,
80311    emit,
80312    once
80313  } = _ref;
80314  extendParams({
80315    freeMode: {
80316      enabled: false,
80317      momentum: true,
80318      momentumRatio: 1,
80319      momentumBounce: true,
80320      momentumBounceRatio: 1,
80321      momentumVelocityRatio: 1,
80322      sticky: false,
80323      minimumVelocity: 0.02
80324    }
80325  });
80326  function onTouchStart2() {
80327    if (swiper.params.cssMode) return;
80328    const translate2 = swiper.getTranslate();
80329    swiper.setTranslate(translate2);
80330    swiper.setTransition(0);
80331    swiper.touchEventsData.velocities.length = 0;
80332    swiper.freeMode.onTouchEnd({
80333      currentPos: swiper.rtl ? swiper.translate : -swiper.translate
80334    });
80335  }
80336  function onTouchMove2() {
80337    if (swiper.params.cssMode) return;
80338    const {
80339      touchEventsData: data,
80340      touches
80341    } = swiper;
80342    if (data.velocities.length === 0) {
80343      data.velocities.push({
80344        position: touches[swiper.isHorizontal() ? "startX" : "startY"],
80345        time: data.touchStartTime
80346      });
80347    }
80348    data.velocities.push({
80349      position: touches[swiper.isHorizontal() ? "currentX" : "currentY"],
80350      time: now()
80351    });
80352  }
80353  function onTouchEnd2(_ref2) {
80354    let {
80355      currentPos
80356    } = _ref2;
80357    if (swiper.params.cssMode) return;
80358    const {
80359      params,
80360      wrapperEl,
80361      rtlTranslate: rtl,
80362      snapGrid,
80363      touchEventsData: data
80364    } = swiper;
80365    const touchEndTime = now();
80366    const timeDiff = touchEndTime - data.touchStartTime;
80367    if (currentPos < -swiper.minTranslate()) {
80368      swiper.slideTo(swiper.activeIndex);
80369      return;
80370    }
80371    if (currentPos > -swiper.maxTranslate()) {
80372      if (swiper.slides.length < snapGrid.length) {
80373        swiper.slideTo(snapGrid.length - 1);
80374      } else {
80375        swiper.slideTo(swiper.slides.length - 1);
80376      }
80377      return;
80378    }
80379    if (params.freeMode.momentum) {
80380      if (data.velocities.length > 1) {
80381        const lastMoveEvent = data.velocities.pop();
80382        const velocityEvent = data.velocities.pop();
80383        const distance = lastMoveEvent.position - velocityEvent.position;
80384        const time = lastMoveEvent.time - velocityEvent.time;
80385        swiper.velocity = distance / time;
80386        swiper.velocity /= 2;
80387        if (Math.abs(swiper.velocity) < params.freeMode.minimumVelocity) {
80388          swiper.velocity = 0;
80389        }
80390        if (time > 150 || now() - lastMoveEvent.time > 300) {
80391          swiper.velocity = 0;
80392        }
80393      } else {
80394        swiper.velocity = 0;
80395      }
80396      swiper.velocity *= params.freeMode.momentumVelocityRatio;
80397      data.velocities.length = 0;
80398      let momentumDuration = 1e3 * params.freeMode.momentumRatio;
80399      const momentumDistance = swiper.velocity * momentumDuration;
80400      let newPosition = swiper.translate + momentumDistance;
80401      if (rtl) newPosition = -newPosition;
80402      let doBounce = false;
80403      let afterBouncePosition;
80404      const bounceAmount = Math.abs(swiper.velocity) * 20 * params.freeMode.momentumBounceRatio;
80405      let needsLoopFix;
80406      if (newPosition < swiper.maxTranslate()) {
80407        if (params.freeMode.momentumBounce) {
80408          if (newPosition + swiper.maxTranslate() < -bounceAmount) {
80409            newPosition = swiper.maxTranslate() - bounceAmount;
80410          }
80411          afterBouncePosition = swiper.maxTranslate();
80412          doBounce = true;
80413          data.allowMomentumBounce = true;
80414        } else {
80415          newPosition = swiper.maxTranslate();
80416        }
80417        if (params.loop && params.centeredSlides) needsLoopFix = true;
80418      } else if (newPosition > swiper.minTranslate()) {
80419        if (params.freeMode.momentumBounce) {
80420          if (newPosition - swiper.minTranslate() > bounceAmount) {
80421            newPosition = swiper.minTranslate() + bounceAmount;
80422          }
80423          afterBouncePosition = swiper.minTranslate();
80424          doBounce = true;
80425          data.allowMomentumBounce = true;
80426        } else {
80427          newPosition = swiper.minTranslate();
80428        }
80429        if (params.loop && params.centeredSlides) needsLoopFix = true;
80430      } else if (params.freeMode.sticky) {
80431        let nextSlide;
80432        for (let j = 0; j < snapGrid.length; j += 1) {
80433          if (snapGrid[j] > -newPosition) {
80434            nextSlide = j;
80435            break;
80436          }
80437        }
80438        if (Math.abs(snapGrid[nextSlide] - newPosition) < Math.abs(snapGrid[nextSlide - 1] - newPosition) || swiper.swipeDirection === "next") {
80439          newPosition = snapGrid[nextSlide];
80440        } else {
80441          newPosition = snapGrid[nextSlide - 1];
80442        }
80443        newPosition = -newPosition;
80444      }
80445      if (needsLoopFix) {
80446        once("transitionEnd", () => {
80447          swiper.loopFix();
80448        });
80449      }
80450      if (swiper.velocity !== 0) {
80451        if (rtl) {
80452          momentumDuration = Math.abs((-newPosition - swiper.translate) / swiper.velocity);
80453        } else {
80454          momentumDuration = Math.abs((newPosition - swiper.translate) / swiper.velocity);
80455        }
80456        if (params.freeMode.sticky) {
80457          const moveDistance = Math.abs((rtl ? -newPosition : newPosition) - swiper.translate);
80458          const currentSlideSize = swiper.slidesSizesGrid[swiper.activeIndex];
80459          if (moveDistance < currentSlideSize) {
80460            momentumDuration = params.speed;
80461          } else if (moveDistance < 2 * currentSlideSize) {
80462            momentumDuration = params.speed * 1.5;
80463          } else {
80464            momentumDuration = params.speed * 2.5;
80465          }
80466        }
80467      } else if (params.freeMode.sticky) {
80468        swiper.slideToClosest();
80469        return;
80470      }
80471      if (params.freeMode.momentumBounce && doBounce) {
80472        swiper.updateProgress(afterBouncePosition);
80473        swiper.setTransition(momentumDuration);
80474        swiper.setTranslate(newPosition);
80475        swiper.transitionStart(true, swiper.swipeDirection);
80476        swiper.animating = true;
80477        elementTransitionEnd(wrapperEl, () => {
80478          if (!swiper || swiper.destroyed || !data.allowMomentumBounce) return;
80479          emit("momentumBounce");
80480          swiper.setTransition(params.speed);
80481          setTimeout(() => {
80482            swiper.setTranslate(afterBouncePosition);
80483            elementTransitionEnd(wrapperEl, () => {
80484              if (!swiper || swiper.destroyed) return;
80485              swiper.transitionEnd();
80486            });
80487          }, 0);
80488        });
80489      } else if (swiper.velocity) {
80490        emit("_freeModeNoMomentumRelease");
80491        swiper.updateProgress(newPosition);
80492        swiper.setTransition(momentumDuration);
80493        swiper.setTranslate(newPosition);
80494        swiper.transitionStart(true, swiper.swipeDirection);
80495        if (!swiper.animating) {
80496          swiper.animating = true;
80497          elementTransitionEnd(wrapperEl, () => {
80498            if (!swiper || swiper.destroyed) return;
80499            swiper.transitionEnd();
80500          });
80501        }
80502      } else {
80503        swiper.updateProgress(newPosition);
80504      }
80505      swiper.updateActiveIndex();
80506      swiper.updateSlidesClasses();
80507    } else if (params.freeMode.sticky) {
80508      swiper.slideToClosest();
80509      return;
80510    } else if (params.freeMode) {
80511      emit("_freeModeNoMomentumRelease");
80512    }
80513    if (!params.freeMode.momentum || timeDiff >= params.longSwipesMs) {
80514      emit("_freeModeStaticRelease");
80515      swiper.updateProgress();
80516      swiper.updateActiveIndex();
80517      swiper.updateSlidesClasses();
80518    }
80519  }
80520  Object.assign(swiper, {
80521    freeMode: {
80522      onTouchStart: onTouchStart2,
80523      onTouchMove: onTouchMove2,
80524      onTouchEnd: onTouchEnd2
80525    }
80526  });
80527}
80528
vendor: 5,222 bytes, lines 80529-80682
80529// node_modules/swiper/modules/grid.mjs
80530function Grid(_ref) {
80531  let {
80532    swiper,
80533    extendParams,
80534    on
80535  } = _ref;
80536  extendParams({
80537    grid: {
80538      rows: 1,
80539      fill: "column"
80540    }
80541  });
80542  let slidesNumberEvenToRows;
80543  let slidesPerRow;
80544  let numFullColumns;
80545  let wasMultiRow;
80546  const getSpaceBetween = () => {
80547    let spaceBetween = swiper.params.spaceBetween;
80548    if (typeof spaceBetween === "string" && spaceBetween.indexOf("%") >= 0) {
80549      spaceBetween = parseFloat(spaceBetween.replace("%", "")) / 100 * swiper.size;
80550    } else if (typeof spaceBetween === "string") {
80551      spaceBetween = parseFloat(spaceBetween);
80552    }
80553    return spaceBetween;
80554  };
80555  const initSlides = (slides) => {
80556    const {
80557      slidesPerView
80558    } = swiper.params;
80559    const {
80560      rows,
80561      fill
80562    } = swiper.params.grid;
80563    const slidesLength = swiper.virtual && swiper.params.virtual.enabled ? swiper.virtual.slides.length : slides.length;
80564    numFullColumns = Math.floor(slidesLength / rows);
80565    if (Math.floor(slidesLength / rows) === slidesLength / rows) {
80566      slidesNumberEvenToRows = slidesLength;
80567    } else {
80568      slidesNumberEvenToRows = Math.ceil(slidesLength / rows) * rows;
80569    }
80570    if (slidesPerView !== "auto" && fill === "row") {
80571      slidesNumberEvenToRows = Math.max(slidesNumberEvenToRows, slidesPerView * rows);
80572    }
80573    slidesPerRow = slidesNumberEvenToRows / rows;
80574  };
80575  const unsetSlides = () => {
80576    if (swiper.slides) {
80577      swiper.slides.forEach((slide2) => {
80578        if (slide2.swiperSlideGridSet) {
80579          slide2.style.height = "";
80580          slide2.style[swiper.getDirectionLabel("margin-top")] = "";
80581        }
80582      });
80583    }
80584  };
80585  const updateSlide = (i, slide2, slides) => {
80586    const {
80587      slidesPerGroup
80588    } = swiper.params;
80589    const spaceBetween = getSpaceBetween();
80590    const {
80591      rows,
80592      fill
80593    } = swiper.params.grid;
80594    const slidesLength = swiper.virtual && swiper.params.virtual.enabled ? swiper.virtual.slides.length : slides.length;
80595    let newSlideOrderIndex;
80596    let column;
80597    let row;
80598    if (fill === "row" && slidesPerGroup > 1) {
80599      const groupIndex = Math.floor(i / (slidesPerGroup * rows));
80600      const slideIndexInGroup = i - rows * slidesPerGroup * groupIndex;
80601      const columnsInGroup = groupIndex === 0 ? slidesPerGroup : Math.min(Math.ceil((slidesLength - groupIndex * rows * slidesPerGroup) / rows), slidesPerGroup);
80602      row = Math.floor(slideIndexInGroup / columnsInGroup);
80603      column = slideIndexInGroup - row * columnsInGroup + groupIndex * slidesPerGroup;
80604      newSlideOrderIndex = column + row * slidesNumberEvenToRows / rows;
80605      slide2.style.order = newSlideOrderIndex;
80606    } else if (fill === "column") {
80607      column = Math.floor(i / rows);
80608      row = i - column * rows;
80609      if (column > numFullColumns || column === numFullColumns && row === rows - 1) {
80610        row += 1;
80611        if (row >= rows) {
80612          row = 0;
80613          column += 1;
80614        }
80615      }
80616    } else {
80617      row = Math.floor(i / slidesPerRow);
80618      column = i - row * slidesPerRow;
80619    }
80620    slide2.row = row;
80621    slide2.column = column;
80622    slide2.style.height = `calc((100% - ${(rows - 1) * spaceBetween}px) / ${rows})`;
80623    slide2.style[swiper.getDirectionLabel("margin-top")] = row !== 0 ? spaceBetween && `${spaceBetween}px` : "";
80624    slide2.swiperSlideGridSet = true;
80625  };
80626  const updateWrapperSize = (slideSize, snapGrid) => {
80627    const {
80628      centeredSlides,
80629      roundLengths
80630    } = swiper.params;
80631    const spaceBetween = getSpaceBetween();
80632    const {
80633      rows
80634    } = swiper.params.grid;
80635    swiper.virtualSize = (slideSize + spaceBetween) * slidesNumberEvenToRows;
80636    swiper.virtualSize = Math.ceil(swiper.virtualSize / rows) - spaceBetween;
80637    if (!swiper.params.cssMode) {
80638      swiper.wrapperEl.style[swiper.getDirectionLabel("width")] = `${swiper.virtualSize + spaceBetween}px`;
80639    }
80640    if (centeredSlides) {
80641      const newSlidesGrid = [];
80642      for (let i = 0; i < snapGrid.length; i += 1) {
80643        let slidesGridItem = snapGrid[i];
80644        if (roundLengths) slidesGridItem = Math.floor(slidesGridItem);
80645        if (snapGrid[i] < swiper.virtualSize + snapGrid[0]) newSlidesGrid.push(slidesGridItem);
80646      }
80647      snapGrid.splice(0, snapGrid.length);
80648      snapGrid.push(...newSlidesGrid);
80649    }
80650  };
80651  const onInit = () => {
80652    wasMultiRow = swiper.params.grid && swiper.params.grid.rows > 1;
80653  };
80654  const onUpdate = () => {
80655    const {
80656      params,
80657      el
80658    } = swiper;
80659    const isMultiRow = params.grid && params.grid.rows > 1;
80660    if (wasMultiRow && !isMultiRow) {
80661      el.classList.remove(`${params.containerModifierClass}grid`, `${params.containerModifierClass}grid-column`);
80662      numFullColumns = 1;
80663      swiper.emitContainerClasses();
80664    } else if (!wasMultiRow && isMultiRow) {
80665      el.classList.add(`${params.containerModifierClass}grid`);
80666      if (params.grid.fill === "column") {
80667        el.classList.add(`${params.containerModifierClass}grid-column`);
80668      }
80669      swiper.emitContainerClasses();
80670    }
80671    wasMultiRow = isMultiRow;
80672  };
80673  on("init", onInit);
80674  on("update", onUpdate);
80675  swiper.grid = {
80676    initSlides,
80677    unsetSlides,
80678    updateSlide,
80679    updateWrapperSize
80680  };
80681}
80682
vendor: 5,016 bytes, lines 80683-80868
80683// node_modules/swiper/modules/manipulation.mjs
80684function appendSlide(slides) {
80685  const swiper = this;
80686  const {
80687    params,
80688    slidesEl
80689  } = swiper;
80690  if (params.loop) {
80691    swiper.loopDestroy();
80692  }
80693  const appendElement = (slideEl) => {
80694    if (typeof slideEl === "string") {
80695      const tempDOM = document.createElement("div");
80696      setInnerHTML(tempDOM, slideEl);
80697      slidesEl.append(tempDOM.children[0]);
80698      setInnerHTML(tempDOM, "");
80699    } else {
80700      slidesEl.append(slideEl);
80701    }
80702  };
80703  if (typeof slides === "object" && "length" in slides) {
80704    for (let i = 0; i < slides.length; i += 1) {
80705      if (slides[i]) appendElement(slides[i]);
80706    }
80707  } else {
80708    appendElement(slides);
80709  }
80710  swiper.recalcSlides();
80711  if (params.loop) {
80712    swiper.loopCreate();
80713  }
80714  if (!params.observer || swiper.isElement) {
80715    swiper.update();
80716  }
80717}
80718function prependSlide(slides) {
80719  const swiper = this;
80720  const {
80721    params,
80722    activeIndex,
80723    slidesEl
80724  } = swiper;
80725  if (params.loop) {
80726    swiper.loopDestroy();
80727  }
80728  let newActiveIndex = activeIndex + 1;
80729  const prependElement = (slideEl) => {
80730    if (typeof slideEl === "string") {
80731      const tempDOM = document.createElement("div");
80732      setInnerHTML(tempDOM, slideEl);
80733      slidesEl.prepend(tempDOM.children[0]);
80734      setInnerHTML(tempDOM, "");
80735    } else {
80736      slidesEl.prepend(slideEl);
80737    }
80738  };
80739  if (typeof slides === "object" && "length" in slides) {
80740    for (let i = 0; i < slides.length; i += 1) {
80741      if (slides[i]) prependElement(slides[i]);
80742    }
80743    newActiveIndex = activeIndex + slides.length;
80744  } else {
80745    prependElement(slides);
80746  }
80747  swiper.recalcSlides();
80748  if (params.loop) {
80749    swiper.loopCreate();
80750  }
80751  if (!params.observer || swiper.isElement) {
80752    swiper.update();
80753  }
80754  swiper.slideTo(newActiveIndex, 0, false);
80755}
80756function addSlide(index, slides) {
80757  const swiper = this;
80758  const {
80759    params,
80760    activeIndex,
80761    slidesEl
80762  } = swiper;
80763  let activeIndexBuffer = activeIndex;
80764  if (params.loop) {
80765    activeIndexBuffer -= swiper.loopedSlides;
80766    swiper.loopDestroy();
80767    swiper.recalcSlides();
80768  }
80769  const baseLength = swiper.slides.length;
80770  if (index <= 0) {
80771    swiper.prependSlide(slides);
80772    return;
80773  }
80774  if (index >= baseLength) {
80775    swiper.appendSlide(slides);
80776    return;
80777  }
80778  let newActiveIndex = activeIndexBuffer > index ? activeIndexBuffer + 1 : activeIndexBuffer;
80779  const slidesBuffer = [];
80780  for (let i = baseLength - 1; i >= index; i -= 1) {
80781    const currentSlide = swiper.slides[i];
80782    currentSlide.remove();
80783    slidesBuffer.unshift(currentSlide);
80784  }
80785  if (typeof slides === "object" && "length" in slides) {
80786    for (let i = 0; i < slides.length; i += 1) {
80787      if (slides[i]) slidesEl.append(slides[i]);
80788    }
80789    newActiveIndex = activeIndexBuffer > index ? activeIndexBuffer + slides.length : activeIndexBuffer;
80790  } else {
80791    slidesEl.append(slides);
80792  }
80793  for (let i = 0; i < slidesBuffer.length; i += 1) {
80794    slidesEl.append(slidesBuffer[i]);
80795  }
80796  swiper.recalcSlides();
80797  if (params.loop) {
80798    swiper.loopCreate();
80799  }
80800  if (!params.observer || swiper.isElement) {
80801    swiper.update();
80802  }
80803  if (params.loop) {
80804    swiper.slideTo(newActiveIndex + swiper.loopedSlides, 0, false);
80805  } else {
80806    swiper.slideTo(newActiveIndex, 0, false);
80807  }
80808}
80809function removeSlide(slidesIndexes) {
80810  const swiper = this;
80811  const {
80812    params,
80813    activeIndex
80814  } = swiper;
80815  let activeIndexBuffer = activeIndex;
80816  if (params.loop) {
80817    activeIndexBuffer -= swiper.loopedSlides;
80818    swiper.loopDestroy();
80819  }
80820  let newActiveIndex = activeIndexBuffer;
80821  let indexToRemove;
80822  if (typeof slidesIndexes === "object" && "length" in slidesIndexes) {
80823    for (let i = 0; i < slidesIndexes.length; i += 1) {
80824      indexToRemove = slidesIndexes[i];
80825      if (swiper.slides[indexToRemove]) swiper.slides[indexToRemove].remove();
80826      if (indexToRemove < newActiveIndex) newActiveIndex -= 1;
80827    }
80828    newActiveIndex = Math.max(newActiveIndex, 0);
80829  } else {
80830    indexToRemove = slidesIndexes;
80831    if (swiper.slides[indexToRemove]) swiper.slides[indexToRemove].remove();
80832    if (indexToRemove < newActiveIndex) newActiveIndex -= 1;
80833    newActiveIndex = Math.max(newActiveIndex, 0);
80834  }
80835  swiper.recalcSlides();
80836  if (params.loop) {
80837    swiper.loopCreate();
80838  }
80839  if (!params.observer || swiper.isElement) {
80840    swiper.update();
80841  }
80842  if (params.loop) {
80843    swiper.slideTo(newActiveIndex + swiper.loopedSlides, 0, false);
80844  } else {
80845    swiper.slideTo(newActiveIndex, 0, false);
80846  }
80847}
80848function removeAllSlides() {
80849  const swiper = this;
80850  const slidesIndexes = [];
80851  for (let i = 0; i < swiper.slides.length; i += 1) {
80852    slidesIndexes.push(i);
80853  }
80854  swiper.removeSlide(slidesIndexes);
80855}
80856function Manipulation(_ref) {
80857  let {
80858    swiper
80859  } = _ref;
80860  Object.assign(swiper, {
80861    appendSlide: appendSlide.bind(swiper),
80862    prependSlide: prependSlide.bind(swiper),
80863    addSlide: addSlide.bind(swiper),
80864    removeSlide: removeSlide.bind(swiper),
80865    removeAllSlides: removeAllSlides.bind(swiper)
80866  });
80867}
80868
vendor: 1,863 bytes, lines 80869-80924
80869// node_modules/swiper/shared/effect-init.mjs
80870function effectInit(params) {
80871  const {
80872    effect: effect2,
80873    swiper,
80874    on,
80875    setTranslate: setTranslate2,
80876    setTransition: setTransition2,
80877    overwriteParams,
80878    perspective,
80879    recreateShadows,
80880    getEffectParams
80881  } = params;
80882  on("beforeInit", () => {
80883    if (swiper.params.effect !== effect2) return;
80884    swiper.classNames.push(`${swiper.params.containerModifierClass}${effect2}`);
80885    if (perspective && perspective()) {
80886      swiper.classNames.push(`${swiper.params.containerModifierClass}3d`);
80887    }
80888    const overwriteParamsResult = overwriteParams ? overwriteParams() : {};
80889    Object.assign(swiper.params, overwriteParamsResult);
80890    Object.assign(swiper.originalParams, overwriteParamsResult);
80891  });
80892  on("setTranslate _virtualUpdated", () => {
80893    if (swiper.params.effect !== effect2) return;
80894    setTranslate2();
80895  });
80896  on("setTransition", (_s, duration) => {
80897    if (swiper.params.effect !== effect2) return;
80898    setTransition2(duration);
80899  });
80900  on("transitionEnd", () => {
80901    if (swiper.params.effect !== effect2) return;
80902    if (recreateShadows) {
80903      if (!getEffectParams || !getEffectParams().slideShadows) return;
80904      swiper.slides.forEach((slideEl) => {
80905        slideEl.querySelectorAll(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").forEach((shadowEl) => shadowEl.remove());
80906      });
80907      recreateShadows();
80908    }
80909  });
80910  let requireUpdateOnVirtual;
80911  on("virtualUpdate", () => {
80912    if (swiper.params.effect !== effect2) return;
80913    if (!swiper.slides.length) {
80914      requireUpdateOnVirtual = true;
80915    }
80916    requestAnimationFrame(() => {
80917      if (requireUpdateOnVirtual && swiper.slides && swiper.slides.length) {
80918        setTranslate2();
80919        requireUpdateOnVirtual = false;
80920      }
80921    });
80922  });
80923}
80924
vendor: 327 bytes, lines 80925-80934
80925// node_modules/swiper/shared/effect-target.mjs
80926function effectTarget(effectParams, slideEl) {
80927  const transformEl = getSlideTransformEl(slideEl);
80928  if (transformEl !== slideEl) {
80929    transformEl.style.backfaceVisibility = "hidden";
80930    transformEl.style["-webkit-backface-visibility"] = "hidden";
80931  }
80932  return transformEl;
80933}
80934
vendor: 1,351 bytes, lines 80935-80979
80935// node_modules/swiper/shared/effect-virtual-transition-end.mjs
80936function effectVirtualTransitionEnd(_ref) {
80937  let {
80938    swiper,
80939    duration,
80940    transformElements,
80941    allSlides
80942  } = _ref;
80943  const {
80944    activeIndex
80945  } = swiper;
80946  const getSlide = (el) => {
80947    if (!el.parentElement) {
80948      const slide2 = swiper.slides.find((slideEl) => slideEl.shadowRoot && slideEl.shadowRoot === el.parentNode);
80949      return slide2;
80950    }
80951    return el.parentElement;
80952  };
80953  if (swiper.params.virtualTranslate && duration !== 0) {
80954    let eventTriggered = false;
80955    let transitionEndTarget;
80956    if (allSlides) {
80957      transitionEndTarget = transformElements;
80958    } else {
80959      transitionEndTarget = transformElements.filter((transformEl) => {
80960        const el = transformEl.classList.contains("swiper-slide-transform") ? getSlide(transformEl) : transformEl;
80961        return swiper.getSlideIndex(el) === activeIndex;
80962      });
80963    }
80964    transitionEndTarget.forEach((el) => {
80965      elementTransitionEnd(el, () => {
80966        if (eventTriggered) return;
80967        if (!swiper || swiper.destroyed) return;
80968        eventTriggered = true;
80969        swiper.animating = false;
80970        const evt = new window.CustomEvent("transitionend", {
80971          bubbles: true,
80972          cancelable: true
80973        });
80974        swiper.wrapperEl.dispatchEvent(evt);
80975      });
80976    });
80977  }
80978}
80979
vendor: 1,661 bytes, lines 80980-81040
80980// node_modules/swiper/modules/effect-fade.mjs
80981function EffectFade(_ref) {
80982  let {
80983    swiper,
80984    extendParams,
80985    on
80986  } = _ref;
80987  extendParams({
80988    fadeEffect: {
80989      crossFade: false
80990    }
80991  });
80992  const setTranslate2 = () => {
80993    const {
80994      slides
80995    } = swiper;
80996    const params = swiper.params.fadeEffect;
80997    for (let i = 0; i < slides.length; i += 1) {
80998      const slideEl = swiper.slides[i];
80999      const offset = slideEl.swiperSlideOffset;
81000      let tx = -offset;
81001      if (!swiper.params.virtualTranslate) tx -= swiper.translate;
81002      let ty = 0;
81003      if (!swiper.isHorizontal()) {
81004        ty = tx;
81005        tx = 0;
81006      }
81007      const slideOpacity = swiper.params.fadeEffect.crossFade ? Math.max(1 - Math.abs(slideEl.progress), 0) : 1 + Math.min(Math.max(slideEl.progress, -1), 0);
81008      const targetEl = effectTarget(params, slideEl);
81009      targetEl.style.opacity = slideOpacity;
81010      targetEl.style.transform = `translate3d(${tx}px, ${ty}px, 0px)`;
81011    }
81012  };
81013  const setTransition2 = (duration) => {
81014    const transformElements = swiper.slides.map((slideEl) => getSlideTransformEl(slideEl));
81015    transformElements.forEach((el) => {
81016      el.style.transitionDuration = `${duration}ms`;
81017    });
81018    effectVirtualTransitionEnd({
81019      swiper,
81020      duration,
81021      transformElements,
81022      allSlides: true
81023    });
81024  };
81025  effectInit({
81026    effect: "fade",
81027    swiper,
81028    on,
81029    setTranslate: setTranslate2,
81030    setTransition: setTransition2,
81031    overwriteParams: () => ({
81032      slidesPerView: 1,
81033      slidesPerGroup: 1,
81034      watchSlidesProgress: true,
81035      spaceBetween: 0,
81036      virtualTranslate: !swiper.params.cssMode
81037    })
81038  });
81039}
81040
vendor: 6,547 bytes, lines 81041-81210
81041// node_modules/swiper/modules/effect-cube.mjs
81042function EffectCube(_ref) {
81043  let {
81044    swiper,
81045    extendParams,
81046    on
81047  } = _ref;
81048  extendParams({
81049    cubeEffect: {
81050      slideShadows: true,
81051      shadow: true,
81052      shadowOffset: 20,
81053      shadowScale: 0.94
81054    }
81055  });
81056  const createSlideShadows = (slideEl, progress, isHorizontal) => {
81057    let shadowBefore = isHorizontal ? slideEl.querySelector(".swiper-slide-shadow-left") : slideEl.querySelector(".swiper-slide-shadow-top");
81058    let shadowAfter = isHorizontal ? slideEl.querySelector(".swiper-slide-shadow-right") : slideEl.querySelector(".swiper-slide-shadow-bottom");
81059    if (!shadowBefore) {
81060      shadowBefore = createElement("div", `swiper-slide-shadow-cube swiper-slide-shadow-${isHorizontal ? "left" : "top"}`.split(" "));
81061      slideEl.append(shadowBefore);
81062    }
81063    if (!shadowAfter) {
81064      shadowAfter = createElement("div", `swiper-slide-shadow-cube swiper-slide-shadow-${isHorizontal ? "right" : "bottom"}`.split(" "));
81065      slideEl.append(shadowAfter);
81066    }
81067    if (shadowBefore) shadowBefore.style.opacity = Math.max(-progress, 0);
81068    if (shadowAfter) shadowAfter.style.opacity = Math.max(progress, 0);
81069  };
81070  const recreateShadows = () => {
81071    const isHorizontal = swiper.isHorizontal();
81072    swiper.slides.forEach((slideEl) => {
81073      const progress = Math.max(Math.min(slideEl.progress, 1), -1);
81074      createSlideShadows(slideEl, progress, isHorizontal);
81075    });
81076  };
81077  const setTranslate2 = () => {
81078    const {
81079      el,
81080      wrapperEl,
81081      slides,
81082      width: swiperWidth,
81083      height: swiperHeight,
81084      rtlTranslate: rtl,
81085      size: swiperSize,
81086      browser: browser2
81087    } = swiper;
81088    const r = getRotateFix(swiper);
81089    const params = swiper.params.cubeEffect;
81090    const isHorizontal = swiper.isHorizontal();
81091    const isVirtual = swiper.virtual && swiper.params.virtual.enabled;
81092    let wrapperRotate = 0;
81093    let cubeShadowEl;
81094    if (params.shadow) {
81095      if (isHorizontal) {
81096        cubeShadowEl = swiper.wrapperEl.querySelector(".swiper-cube-shadow");
81097        if (!cubeShadowEl) {
81098          cubeShadowEl = createElement("div", "swiper-cube-shadow");
81099          swiper.wrapperEl.append(cubeShadowEl);
81100        }
81101        cubeShadowEl.style.height = `${swiperWidth}px`;
81102      } else {
81103        cubeShadowEl = el.querySelector(".swiper-cube-shadow");
81104        if (!cubeShadowEl) {
81105          cubeShadowEl = createElement("div", "swiper-cube-shadow");
81106          el.append(cubeShadowEl);
81107        }
81108      }
81109    }
81110    for (let i = 0; i < slides.length; i += 1) {
81111      const slideEl = slides[i];
81112      let slideIndex = i;
81113      if (isVirtual) {
81114        slideIndex = parseInt(slideEl.getAttribute("data-swiper-slide-index"), 10);
81115      }
81116      let slideAngle = slideIndex * 90;
81117      let round = Math.floor(slideAngle / 360);
81118      if (rtl) {
81119        slideAngle = -slideAngle;
81120        round = Math.floor(-slideAngle / 360);
81121      }
81122      const progress = Math.max(Math.min(slideEl.progress, 1), -1);
81123      let tx = 0;
81124      let ty = 0;
81125      let tz = 0;
81126      if (slideIndex % 4 === 0) {
81127        tx = -round * 4 * swiperSize;
81128        tz = 0;
81129      } else if ((slideIndex - 1) % 4 === 0) {
81130        tx = 0;
81131        tz = -round * 4 * swiperSize;
81132      } else if ((slideIndex - 2) % 4 === 0) {
81133        tx = swiperSize + round * 4 * swiperSize;
81134        tz = swiperSize;
81135      } else if ((slideIndex - 3) % 4 === 0) {
81136        tx = -swiperSize;
81137        tz = 3 * swiperSize + swiperSize * 4 * round;
81138      }
81139      if (rtl) {
81140        tx = -tx;
81141      }
81142      if (!isHorizontal) {
81143        ty = tx;
81144        tx = 0;
81145      }
81146      const transform = `rotateX(${r(isHorizontal ? 0 : -slideAngle)}deg) rotateY(${r(isHorizontal ? slideAngle : 0)}deg) translate3d(${tx}px, ${ty}px, ${tz}px)`;
81147      if (progress <= 1 && progress > -1) {
81148        wrapperRotate = slideIndex * 90 + progress * 90;
81149        if (rtl) wrapperRotate = -slideIndex * 90 - progress * 90;
81150      }
81151      slideEl.style.transform = transform;
81152      if (params.slideShadows) {
81153        createSlideShadows(slideEl, progress, isHorizontal);
81154      }
81155    }
81156    wrapperEl.style.transformOrigin = `50% 50% -${swiperSize / 2}px`;
81157    wrapperEl.style["-webkit-transform-origin"] = `50% 50% -${swiperSize / 2}px`;
81158    if (params.shadow) {
81159      if (isHorizontal) {
81160        cubeShadowEl.style.transform = `translate3d(0px, ${swiperWidth / 2 + params.shadowOffset}px, ${-swiperWidth / 2}px) rotateX(89.99deg) rotateZ(0deg) scale(${params.shadowScale})`;
81161      } else {
81162        const shadowAngle = Math.abs(wrapperRotate) - Math.floor(Math.abs(wrapperRotate) / 90) * 90;
81163        const multiplier = 1.5 - (Math.sin(shadowAngle * 2 * Math.PI / 360) / 2 + Math.cos(shadowAngle * 2 * Math.PI / 360) / 2);
81164        const scale1 = params.shadowScale;
81165        const scale2 = params.shadowScale / multiplier;
81166        const offset = params.shadowOffset;
81167        cubeShadowEl.style.transform = `scale3d(${scale1}, 1, ${scale2}) translate3d(0px, ${swiperHeight / 2 + offset}px, ${-swiperHeight / 2 / scale2}px) rotateX(-89.99deg)`;
81168      }
81169    }
81170    const zFactor = (browser2.isSafari || browser2.isWebView) && browser2.needPerspectiveFix ? -swiperSize / 2 : 0;
81171    wrapperEl.style.transform = `translate3d(0px,0,${zFactor}px) rotateX(${r(swiper.isHorizontal() ? 0 : wrapperRotate)}deg) rotateY(${r(swiper.isHorizontal() ? -wrapperRotate : 0)}deg)`;
81172    wrapperEl.style.setProperty("--swiper-cube-translate-z", `${zFactor}px`);
81173  };
81174  const setTransition2 = (duration) => {
81175    const {
81176      el,
81177      slides
81178    } = swiper;
81179    slides.forEach((slideEl) => {
81180      slideEl.style.transitionDuration = `${duration}ms`;
81181      slideEl.querySelectorAll(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").forEach((subEl) => {
81182        subEl.style.transitionDuration = `${duration}ms`;
81183      });
81184    });
81185    if (swiper.params.cubeEffect.shadow && !swiper.isHorizontal()) {
81186      const shadowEl = el.querySelector(".swiper-cube-shadow");
81187      if (shadowEl) shadowEl.style.transitionDuration = `${duration}ms`;
81188    }
81189  };
81190  effectInit({
81191    effect: "cube",
81192    swiper,
81193    on,
81194    setTranslate: setTranslate2,
81195    setTransition: setTransition2,
81196    recreateShadows,
81197    getEffectParams: () => swiper.params.cubeEffect,
81198    perspective: () => true,
81199    overwriteParams: () => ({
81200      slidesPerView: 1,
81201      slidesPerGroup: 1,
81202      watchSlidesProgress: true,
81203      resistanceRatio: 0,
81204      spaceBetween: 0,
81205      centeredSlides: false,
81206      virtualTranslate: true
81207    })
81208  });
81209}
81210
vendor: 502 bytes, lines 81211-81222
81211// node_modules/swiper/shared/create-shadow.mjs
81212function createShadow(suffix, slideEl, side) {
81213  const shadowClass = `swiper-slide-shadow${side ? `-${side}` : ""}${suffix ? ` swiper-slide-shadow-${suffix}` : ""}`;
81214  const shadowContainer = getSlideTransformEl(slideEl);
81215  let shadowEl = shadowContainer.querySelector(`.${shadowClass.split(" ").join(".")}`);
81216  if (!shadowEl) {
81217    shadowEl = createElement("div", shadowClass.split(" "));
81218    shadowContainer.append(shadowEl);
81219  }
81220  return shadowEl;
81221}
81222
vendor: 3,554 bytes, lines 81223-81326
81223// node_modules/swiper/modules/effect-flip.mjs
81224function EffectFlip(_ref) {
81225  let {
81226    swiper,
81227    extendParams,
81228    on
81229  } = _ref;
81230  extendParams({
81231    flipEffect: {
81232      slideShadows: true,
81233      limitRotation: true
81234    }
81235  });
81236  const createSlideShadows = (slideEl, progress) => {
81237    let shadowBefore = swiper.isHorizontal() ? slideEl.querySelector(".swiper-slide-shadow-left") : slideEl.querySelector(".swiper-slide-shadow-top");
81238    let shadowAfter = swiper.isHorizontal() ? slideEl.querySelector(".swiper-slide-shadow-right") : slideEl.querySelector(".swiper-slide-shadow-bottom");
81239    if (!shadowBefore) {
81240      shadowBefore = createShadow("flip", slideEl, swiper.isHorizontal() ? "left" : "top");
81241    }
81242    if (!shadowAfter) {
81243      shadowAfter = createShadow("flip", slideEl, swiper.isHorizontal() ? "right" : "bottom");
81244    }
81245    if (shadowBefore) shadowBefore.style.opacity = Math.max(-progress, 0);
81246    if (shadowAfter) shadowAfter.style.opacity = Math.max(progress, 0);
81247  };
81248  const recreateShadows = () => {
81249    swiper.params.flipEffect;
81250    swiper.slides.forEach((slideEl) => {
81251      let progress = slideEl.progress;
81252      if (swiper.params.flipEffect.limitRotation) {
81253        progress = Math.max(Math.min(slideEl.progress, 1), -1);
81254      }
81255      createSlideShadows(slideEl, progress);
81256    });
81257  };
81258  const setTranslate2 = () => {
81259    const {
81260      slides,
81261      rtlTranslate: rtl
81262    } = swiper;
81263    const params = swiper.params.flipEffect;
81264    const rotateFix = getRotateFix(swiper);
81265    for (let i = 0; i < slides.length; i += 1) {
81266      const slideEl = slides[i];
81267      let progress = slideEl.progress;
81268      if (swiper.params.flipEffect.limitRotation) {
81269        progress = Math.max(Math.min(slideEl.progress, 1), -1);
81270      }
81271      const offset = slideEl.swiperSlideOffset;
81272      const rotate = -180 * progress;
81273      let rotateY = rotate;
81274      let rotateX = 0;
81275      let tx = swiper.params.cssMode ? -offset - swiper.translate : -offset;
81276      let ty = 0;
81277      if (!swiper.isHorizontal()) {
81278        ty = tx;
81279        tx = 0;
81280        rotateX = -rotateY;
81281        rotateY = 0;
81282      } else if (rtl) {
81283        rotateY = -rotateY;
81284      }
81285      slideEl.style.zIndex = -Math.abs(Math.round(progress)) + slides.length;
81286      if (params.slideShadows) {
81287        createSlideShadows(slideEl, progress);
81288      }
81289      const transform = `translate3d(${tx}px, ${ty}px, 0px) rotateX(${rotateFix(rotateX)}deg) rotateY(${rotateFix(rotateY)}deg)`;
81290      const targetEl = effectTarget(params, slideEl);
81291      targetEl.style.transform = transform;
81292    }
81293  };
81294  const setTransition2 = (duration) => {
81295    const transformElements = swiper.slides.map((slideEl) => getSlideTransformEl(slideEl));
81296    transformElements.forEach((el) => {
81297      el.style.transitionDuration = `${duration}ms`;
81298      el.querySelectorAll(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").forEach((shadowEl) => {
81299        shadowEl.style.transitionDuration = `${duration}ms`;
81300      });
81301    });
81302    effectVirtualTransitionEnd({
81303      swiper,
81304      duration,
81305      transformElements
81306    });
81307  };
81308  effectInit({
81309    effect: "flip",
81310    swiper,
81311    on,
81312    setTranslate: setTranslate2,
81313    setTransition: setTransition2,
81314    recreateShadows,
81315    getEffectParams: () => swiper.params.flipEffect,
81316    perspective: () => true,
81317    overwriteParams: () => ({
81318      slidesPerView: 1,
81319      slidesPerGroup: 1,
81320      watchSlidesProgress: true,
81321      spaceBetween: 0,
81322      virtualTranslate: !swiper.params.cssMode
81323    })
81324  });
81325}
81326
vendor: 4,014 bytes, lines 81327-81419
81327// node_modules/swiper/modules/effect-coverflow.mjs
81328function EffectCoverflow(_ref) {
81329  let {
81330    swiper,
81331    extendParams,
81332    on
81333  } = _ref;
81334  extendParams({
81335    coverflowEffect: {
81336      rotate: 50,
81337      stretch: 0,
81338      depth: 100,
81339      scale: 1,
81340      modifier: 1,
81341      slideShadows: true
81342    }
81343  });
81344  const setTranslate2 = () => {
81345    const {
81346      width: swiperWidth,
81347      height: swiperHeight,
81348      slides,
81349      slidesSizesGrid
81350    } = swiper;
81351    const params = swiper.params.coverflowEffect;
81352    const isHorizontal = swiper.isHorizontal();
81353    const transform = swiper.translate;
81354    const center = isHorizontal ? -transform + swiperWidth / 2 : -transform + swiperHeight / 2;
81355    const rotate = isHorizontal ? params.rotate : -params.rotate;
81356    const translate2 = params.depth;
81357    const r = getRotateFix(swiper);
81358    for (let i = 0, length = slides.length; i < length; i += 1) {
81359      const slideEl = slides[i];
81360      const slideSize = slidesSizesGrid[i];
81361      const slideOffset = slideEl.swiperSlideOffset;
81362      const centerOffset = (center - slideOffset - slideSize / 2) / slideSize;
81363      const offsetMultiplier = typeof params.modifier === "function" ? params.modifier(centerOffset) : centerOffset * params.modifier;
81364      let rotateY = isHorizontal ? rotate * offsetMultiplier : 0;
81365      let rotateX = isHorizontal ? 0 : rotate * offsetMultiplier;
81366      let translateZ = -translate2 * Math.abs(offsetMultiplier);
81367      let stretch = params.stretch;
81368      if (typeof stretch === "string" && stretch.indexOf("%") !== -1) {
81369        stretch = parseFloat(params.stretch) / 100 * slideSize;
81370      }
81371      let translateY = isHorizontal ? 0 : stretch * offsetMultiplier;
81372      let translateX = isHorizontal ? stretch * offsetMultiplier : 0;
81373      let scale = 1 - (1 - params.scale) * Math.abs(offsetMultiplier);
81374      if (Math.abs(translateX) < 1e-3) translateX = 0;
81375      if (Math.abs(translateY) < 1e-3) translateY = 0;
81376      if (Math.abs(translateZ) < 1e-3) translateZ = 0;
81377      if (Math.abs(rotateY) < 1e-3) rotateY = 0;
81378      if (Math.abs(rotateX) < 1e-3) rotateX = 0;
81379      if (Math.abs(scale) < 1e-3) scale = 0;
81380      const slideTransform = `translate3d(${translateX}px,${translateY}px,${translateZ}px)  rotateX(${r(rotateX)}deg) rotateY(${r(rotateY)}deg) scale(${scale})`;
81381      const targetEl = effectTarget(params, slideEl);
81382      targetEl.style.transform = slideTransform;
81383      slideEl.style.zIndex = -Math.abs(Math.round(offsetMultiplier)) + 1;
81384      if (params.slideShadows) {
81385        let shadowBeforeEl = isHorizontal ? slideEl.querySelector(".swiper-slide-shadow-left") : slideEl.querySelector(".swiper-slide-shadow-top");
81386        let shadowAfterEl = isHorizontal ? slideEl.querySelector(".swiper-slide-shadow-right") : slideEl.querySelector(".swiper-slide-shadow-bottom");
81387        if (!shadowBeforeEl) {
81388          shadowBeforeEl = createShadow("coverflow", slideEl, isHorizontal ? "left" : "top");
81389        }
81390        if (!shadowAfterEl) {
81391          shadowAfterEl = createShadow("coverflow", slideEl, isHorizontal ? "right" : "bottom");
81392        }
81393        if (shadowBeforeEl) shadowBeforeEl.style.opacity = offsetMultiplier > 0 ? offsetMultiplier : 0;
81394        if (shadowAfterEl) shadowAfterEl.style.opacity = -offsetMultiplier > 0 ? -offsetMultiplier : 0;
81395      }
81396    }
81397  };
81398  const setTransition2 = (duration) => {
81399    const transformElements = swiper.slides.map((slideEl) => getSlideTransformEl(slideEl));
81400    transformElements.forEach((el) => {
81401      el.style.transitionDuration = `${duration}ms`;
81402      el.querySelectorAll(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").forEach((shadowEl) => {
81403        shadowEl.style.transitionDuration = `${duration}ms`;
81404      });
81405    });
81406  };
81407  effectInit({
81408    effect: "coverflow",
81409    swiper,
81410    on,
81411    setTranslate: setTranslate2,
81412    setTransition: setTransition2,
81413    perspective: () => true,
81414    overwriteParams: () => ({
81415      watchSlidesProgress: true
81416    })
81417  });
81418}
81419
vendor: 4,686 bytes, lines 81420-81555
81420// node_modules/swiper/modules/effect-creative.mjs
81421function EffectCreative(_ref) {
81422  let {
81423    swiper,
81424    extendParams,
81425    on
81426  } = _ref;
81427  extendParams({
81428    creativeEffect: {
81429      limitProgress: 1,
81430      shadowPerProgress: false,
81431      progressMultiplier: 1,
81432      perspective: true,
81433      prev: {
81434        translate: [0, 0, 0],
81435        rotate: [0, 0, 0],
81436        opacity: 1,
81437        scale: 1
81438      },
81439      next: {
81440        translate: [0, 0, 0],
81441        rotate: [0, 0, 0],
81442        opacity: 1,
81443        scale: 1
81444      }
81445    }
81446  });
81447  const getTranslateValue = (value) => {
81448    if (typeof value === "string") return value;
81449    return `${value}px`;
81450  };
81451  const setTranslate2 = () => {
81452    const {
81453      slides,
81454      wrapperEl,
81455      slidesSizesGrid
81456    } = swiper;
81457    const params = swiper.params.creativeEffect;
81458    const {
81459      progressMultiplier: multiplier
81460    } = params;
81461    const isCenteredSlides = swiper.params.centeredSlides;
81462    const rotateFix = getRotateFix(swiper);
81463    if (isCenteredSlides) {
81464      const margin = slidesSizesGrid[0] / 2 - swiper.params.slidesOffsetBefore || 0;
81465      wrapperEl.style.transform = `translateX(calc(50% - ${margin}px))`;
81466    }
81467    for (let i = 0; i < slides.length; i += 1) {
81468      const slideEl = slides[i];
81469      const slideProgress = slideEl.progress;
81470      const progress = Math.min(Math.max(slideEl.progress, -params.limitProgress), params.limitProgress);
81471      let originalProgress = progress;
81472      if (!isCenteredSlides) {
81473        originalProgress = Math.min(Math.max(slideEl.originalProgress, -params.limitProgress), params.limitProgress);
81474      }
81475      const offset = slideEl.swiperSlideOffset;
81476      const t = [swiper.params.cssMode ? -offset - swiper.translate : -offset, 0, 0];
81477      const r = [0, 0, 0];
81478      let custom = false;
81479      if (!swiper.isHorizontal()) {
81480        t[1] = t[0];
81481        t[0] = 0;
81482      }
81483      let data = {
81484        translate: [0, 0, 0],
81485        rotate: [0, 0, 0],
81486        scale: 1,
81487        opacity: 1
81488      };
81489      if (progress < 0) {
81490        data = params.next;
81491        custom = true;
81492      } else if (progress > 0) {
81493        data = params.prev;
81494        custom = true;
81495      }
81496      t.forEach((value, index) => {
81497        t[index] = `calc(${value}px + (${getTranslateValue(data.translate[index])} * ${Math.abs(progress * multiplier)}))`;
81498      });
81499      r.forEach((value, index) => {
81500        let val = data.rotate[index] * Math.abs(progress * multiplier);
81501        r[index] = val;
81502      });
81503      slideEl.style.zIndex = -Math.abs(Math.round(slideProgress)) + slides.length;
81504      const translateString = t.join(", ");
81505      const rotateString = `rotateX(${rotateFix(r[0])}deg) rotateY(${rotateFix(r[1])}deg) rotateZ(${rotateFix(r[2])}deg)`;
81506      const scaleString = originalProgress < 0 ? `scale(${1 + (1 - data.scale) * originalProgress * multiplier})` : `scale(${1 - (1 - data.scale) * originalProgress * multiplier})`;
81507      const opacityString = originalProgress < 0 ? 1 + (1 - data.opacity) * originalProgress * multiplier : 1 - (1 - data.opacity) * originalProgress * multiplier;
81508      const transform = `translate3d(${translateString}) ${rotateString} ${scaleString}`;
81509      if (custom && data.shadow || !custom) {
81510        let shadowEl = slideEl.querySelector(".swiper-slide-shadow");
81511        if (!shadowEl && data.shadow) {
81512          shadowEl = createShadow("creative", slideEl);
81513        }
81514        if (shadowEl) {
81515          const shadowOpacity = params.shadowPerProgress ? progress * (1 / params.limitProgress) : progress;
81516          shadowEl.style.opacity = Math.min(Math.max(Math.abs(shadowOpacity), 0), 1);
81517        }
81518      }
81519      const targetEl = effectTarget(params, slideEl);
81520      targetEl.style.transform = transform;
81521      targetEl.style.opacity = opacityString;
81522      if (data.origin) {
81523        targetEl.style.transformOrigin = data.origin;
81524      }
81525    }
81526  };
81527  const setTransition2 = (duration) => {
81528    const transformElements = swiper.slides.map((slideEl) => getSlideTransformEl(slideEl));
81529    transformElements.forEach((el) => {
81530      el.style.transitionDuration = `${duration}ms`;
81531      el.querySelectorAll(".swiper-slide-shadow").forEach((shadowEl) => {
81532        shadowEl.style.transitionDuration = `${duration}ms`;
81533      });
81534    });
81535    effectVirtualTransitionEnd({
81536      swiper,
81537      duration,
81538      transformElements,
81539      allSlides: true
81540    });
81541  };
81542  effectInit({
81543    effect: "creative",
81544    swiper,
81545    on,
81546    setTranslate: setTranslate2,
81547    setTransition: setTransition2,
81548    perspective: () => swiper.params.creativeEffect.perspective,
81549    overwriteParams: () => ({
81550      watchSlidesProgress: true,
81551      virtualTranslate: !swiper.params.cssMode
81552    })
81553  });
81554}
81555
vendor: 4,266 bytes, lines 81556-81670
81556// node_modules/swiper/modules/effect-cards.mjs
81557function EffectCards(_ref) {
81558  let {
81559    swiper,
81560    extendParams,
81561    on
81562  } = _ref;
81563  extendParams({
81564    cardsEffect: {
81565      slideShadows: true,
81566      rotate: true,
81567      perSlideRotate: 2,
81568      perSlideOffset: 8
81569    }
81570  });
81571  const setTranslate2 = () => {
81572    const {
81573      slides,
81574      activeIndex,
81575      rtlTranslate: rtl
81576    } = swiper;
81577    const params = swiper.params.cardsEffect;
81578    const {
81579      startTranslate,
81580      isTouched
81581    } = swiper.touchEventsData;
81582    const currentTranslate = rtl ? -swiper.translate : swiper.translate;
81583    for (let i = 0; i < slides.length; i += 1) {
81584      const slideEl = slides[i];
81585      const slideProgress = slideEl.progress;
81586      const progress = Math.min(Math.max(slideProgress, -4), 4);
81587      let offset = slideEl.swiperSlideOffset;
81588      if (swiper.params.centeredSlides && !swiper.params.cssMode) {
81589        swiper.wrapperEl.style.transform = `translateX(${swiper.minTranslate()}px)`;
81590      }
81591      if (swiper.params.centeredSlides && swiper.params.cssMode) {
81592        offset -= slides[0].swiperSlideOffset;
81593      }
81594      let tX = swiper.params.cssMode ? -offset - swiper.translate : -offset;
81595      let tY = 0;
81596      const tZ = -100 * Math.abs(progress);
81597      let scale = 1;
81598      let rotate = -params.perSlideRotate * progress;
81599      let tXAdd = params.perSlideOffset - Math.abs(progress) * 0.75;
81600      const slideIndex = swiper.virtual && swiper.params.virtual.enabled ? swiper.virtual.from + i : i;
81601      const isSwipeToNext = (slideIndex === activeIndex || slideIndex === activeIndex - 1) && progress > 0 && progress < 1 && (isTouched || swiper.params.cssMode) && currentTranslate < startTranslate;
81602      const isSwipeToPrev = (slideIndex === activeIndex || slideIndex === activeIndex + 1) && progress < 0 && progress > -1 && (isTouched || swiper.params.cssMode) && currentTranslate > startTranslate;
81603      if (isSwipeToNext || isSwipeToPrev) {
81604        const subProgress = (1 - Math.abs((Math.abs(progress) - 0.5) / 0.5)) ** 0.5;
81605        rotate += -28 * progress * subProgress;
81606        scale += -0.5 * subProgress;
81607        tXAdd += 96 * subProgress;
81608        tY = `${-25 * subProgress * Math.abs(progress)}%`;
81609      }
81610      if (progress < 0) {
81611        tX = `calc(${tX}px ${rtl ? "-" : "+"} (${tXAdd * Math.abs(progress)}%))`;
81612      } else if (progress > 0) {
81613        tX = `calc(${tX}px ${rtl ? "-" : "+"} (-${tXAdd * Math.abs(progress)}%))`;
81614      } else {
81615        tX = `${tX}px`;
81616      }
81617      if (!swiper.isHorizontal()) {
81618        const prevY = tY;
81619        tY = tX;
81620        tX = prevY;
81621      }
81622      const scaleString = progress < 0 ? `${1 + (1 - scale) * progress}` : `${1 - (1 - scale) * progress}`;
81623      const transform = `
81624        translate3d(${tX}, ${tY}, ${tZ}px)
81625        rotateZ(${params.rotate ? rtl ? -rotate : rotate : 0}deg)
81626        scale(${scaleString})
81627      `;
81628      if (params.slideShadows) {
81629        let shadowEl = slideEl.querySelector(".swiper-slide-shadow");
81630        if (!shadowEl) {
81631          shadowEl = createShadow("cards", slideEl);
81632        }
81633        if (shadowEl) shadowEl.style.opacity = Math.min(Math.max((Math.abs(progress) - 0.5) / 0.5, 0), 1);
81634      }
81635      slideEl.style.zIndex = -Math.abs(Math.round(slideProgress)) + slides.length;
81636      const targetEl = effectTarget(params, slideEl);
81637      targetEl.style.transform = transform;
81638    }
81639  };
81640  const setTransition2 = (duration) => {
81641    const transformElements = swiper.slides.map((slideEl) => getSlideTransformEl(slideEl));
81642    transformElements.forEach((el) => {
81643      el.style.transitionDuration = `${duration}ms`;
81644      el.querySelectorAll(".swiper-slide-shadow").forEach((shadowEl) => {
81645        shadowEl.style.transitionDuration = `${duration}ms`;
81646      });
81647    });
81648    effectVirtualTransitionEnd({
81649      swiper,
81650      duration,
81651      transformElements
81652    });
81653  };
81654  effectInit({
81655    effect: "cards",
81656    swiper,
81657    on,
81658    setTranslate: setTranslate2,
81659    setTransition: setTransition2,
81660    perspective: () => true,
81661    overwriteParams: () => ({
81662      _loopSwapReset: false,
81663      watchSlidesProgress: true,
81664      loopAdditionalSlides: swiper.params.cardsEffect.rotate ? 3 : 2,
81665      centeredSlides: true,
81666      virtualTranslate: !swiper.params.cssMode
81667    })
81668  });
81669}
81670
vendor: 333 bytes, lines 81671-81674
81671// node_modules/swiper/swiper-bundle.mjs
81672var modules = [Virtual, Keyboard, Mousewheel, Navigation, Pagination, Scrollbar, Parallax, Zoom, Controller, A11y, History, HashNavigation, Autoplay, Thumb, freeMode, Grid, Manipulation, EffectFade, EffectCube, EffectFlip, EffectCoverflow, EffectCreative, EffectCards];
81673Swiper.use(modules);
81674
vendor: 10,288 bytes, lines 81675-82006
81675// node_modules/swiper/shared/update-swiper.mjs
81676var paramsList = [
81677  "eventsPrefix",
81678  "injectStyles",
81679  "injectStylesUrls",
81680  "modules",
81681  "init",
81682  "_direction",
81683  "oneWayMovement",
81684  "swiperElementNodeName",
81685  "touchEventsTarget",
81686  "initialSlide",
81687  "_speed",
81688  "cssMode",
81689  "updateOnWindowResize",
81690  "resizeObserver",
81691  "nested",
81692  "focusableElements",
81693  "_enabled",
81694  "_width",
81695  "_height",
81696  "preventInteractionOnTransition",
81697  "userAgent",
81698  "url",
81699  "_edgeSwipeDetection",
81700  "_edgeSwipeThreshold",
81701  "_freeMode",
81702  "_autoHeight",
81703  "setWrapperSize",
81704  "virtualTranslate",
81705  "_effect",
81706  "breakpoints",
81707  "breakpointsBase",
81708  "_spaceBetween",
81709  "_slidesPerView",
81710  "maxBackfaceHiddenSlides",
81711  "_grid",
81712  "_slidesPerGroup",
81713  "_slidesPerGroupSkip",
81714  "_slidesPerGroupAuto",
81715  "_centeredSlides",
81716  "_centeredSlidesBounds",
81717  "_slidesOffsetBefore",
81718  "_slidesOffsetAfter",
81719  "normalizeSlideIndex",
81720  "_centerInsufficientSlides",
81721  "_watchOverflow",
81722  "roundLengths",
81723  "touchRatio",
81724  "touchAngle",
81725  "simulateTouch",
81726  "_shortSwipes",
81727  "_longSwipes",
81728  "longSwipesRatio",
81729  "longSwipesMs",
81730  "_followFinger",
81731  "allowTouchMove",
81732  "_threshold",
81733  "touchMoveStopPropagation",
81734  "touchStartPreventDefault",
81735  "touchStartForcePreventDefault",
81736  "touchReleaseOnEdges",
81737  "uniqueNavElements",
81738  "_resistance",
81739  "_resistanceRatio",
81740  "_watchSlidesProgress",
81741  "_grabCursor",
81742  "preventClicks",
81743  "preventClicksPropagation",
81744  "_slideToClickedSlide",
81745  "_loop",
81746  "loopAdditionalSlides",
81747  "loopAddBlankSlides",
81748  "loopPreventsSliding",
81749  "_rewind",
81750  "_allowSlidePrev",
81751  "_allowSlideNext",
81752  "_swipeHandler",
81753  "_noSwiping",
81754  "noSwipingClass",
81755  "noSwipingSelector",
81756  "passiveListeners",
81757  "containerModifierClass",
81758  "slideClass",
81759  "slideActiveClass",
81760  "slideVisibleClass",
81761  "slideFullyVisibleClass",
81762  "slideNextClass",
81763  "slidePrevClass",
81764  "slideBlankClass",
81765  "wrapperClass",
81766  "lazyPreloaderClass",
81767  "lazyPreloadPrevNext",
81768  "runCallbacksOnInit",
81769  "observer",
81770  "observeParents",
81771  "observeSlideChildren",
81772  // modules
81773  "a11y",
81774  "_autoplay",
81775  "_controller",
81776  "coverflowEffect",
81777  "cubeEffect",
81778  "fadeEffect",
81779  "flipEffect",
81780  "creativeEffect",
81781  "cardsEffect",
81782  "hashNavigation",
81783  "history",
81784  "keyboard",
81785  "mousewheel",
81786  "_navigation",
81787  "_pagination",
81788  "parallax",
81789  "_scrollbar",
81790  "_thumbs",
81791  "virtual",
81792  "zoom",
81793  "control"
81794];
81795function isObject6(o) {
81796  return typeof o === "object" && o !== null && o.constructor && Object.prototype.toString.call(o).slice(8, -1) === "Object" && !o.__swiper__;
81797}
81798function extend3(target, src) {
81799  const noExtend = ["__proto__", "constructor", "prototype"];
81800  Object.keys(src).filter((key) => noExtend.indexOf(key) < 0).forEach((key) => {
81801    if (typeof target[key] === "undefined") target[key] = src[key];
81802    else if (isObject6(src[key]) && isObject6(target[key]) && Object.keys(src[key]).length > 0) {
81803      if (src[key].__swiper__) target[key] = src[key];
81804      else extend3(target[key], src[key]);
81805    } else {
81806      target[key] = src[key];
81807    }
81808  });
81809}
81810function needsNavigation(params) {
81811  if (params === void 0) {
81812    params = {};
81813  }
81814  return params.navigation && typeof params.navigation.nextEl === "undefined" && typeof params.navigation.prevEl === "undefined";
81815}
81816function needsPagination(params) {
81817  if (params === void 0) {
81818    params = {};
81819  }
81820  return params.pagination && typeof params.pagination.el === "undefined";
81821}
81822function needsScrollbar(params) {
81823  if (params === void 0) {
81824    params = {};
81825  }
81826  return params.scrollbar && typeof params.scrollbar.el === "undefined";
81827}
81828function attrToProp(attrName) {
81829  if (attrName === void 0) {
81830    attrName = "";
81831  }
81832  return attrName.replace(/-[a-z]/g, (l) => l.toUpperCase().replace("-", ""));
81833}
81834function updateSwiper(_ref) {
81835  let {
81836    swiper,
81837    slides,
81838    passedParams,
81839    changedParams,
81840    nextEl,
81841    prevEl,
81842    scrollbarEl,
81843    paginationEl
81844  } = _ref;
81845  const updateParams = changedParams.filter((key) => key !== "children" && key !== "direction" && key !== "wrapperClass");
81846  const {
81847    params: currentParams,
81848    pagination,
81849    navigation,
81850    scrollbar,
81851    virtual,
81852    thumbs
81853  } = swiper;
81854  let needThumbsInit;
81855  let needControllerInit;
81856  let needPaginationInit;
81857  let needScrollbarInit;
81858  let needNavigationInit;
81859  let loopNeedDestroy;
81860  let loopNeedEnable;
81861  let loopNeedReloop;
81862  if (changedParams.includes("thumbs") && passedParams.thumbs && passedParams.thumbs.swiper && !passedParams.thumbs.swiper.destroyed && currentParams.thumbs && (!currentParams.thumbs.swiper || currentParams.thumbs.swiper.destroyed)) {
81863    needThumbsInit = true;
81864  }
81865  if (changedParams.includes("controller") && passedParams.controller && passedParams.controller.control && currentParams.controller && !currentParams.controller.control) {
81866    needControllerInit = true;
81867  }
81868  if (changedParams.includes("pagination") && passedParams.pagination && (passedParams.pagination.el || paginationEl) && (currentParams.pagination || currentParams.pagination === false) && pagination && !pagination.el) {
81869    needPaginationInit = true;
81870  }
81871  if (changedParams.includes("scrollbar") && passedParams.scrollbar && (passedParams.scrollbar.el || scrollbarEl) && (currentParams.scrollbar || currentParams.scrollbar === false) && scrollbar && !scrollbar.el) {
81872    needScrollbarInit = true;
81873  }
81874  if (changedParams.includes("navigation") && passedParams.navigation && (passedParams.navigation.prevEl || prevEl) && (passedParams.navigation.nextEl || nextEl) && (currentParams.navigation || currentParams.navigation === false) && navigation && !navigation.prevEl && !navigation.nextEl) {
81875    needNavigationInit = true;
81876  }
81877  const destroyModule = (mod) => {
81878    if (!swiper[mod]) return;
81879    swiper[mod].destroy();
81880    if (mod === "navigation") {
81881      if (swiper.isElement) {
81882        swiper[mod].prevEl.remove();
81883        swiper[mod].nextEl.remove();
81884      }
81885      currentParams[mod].prevEl = void 0;
81886      currentParams[mod].nextEl = void 0;
81887      swiper[mod].prevEl = void 0;
81888      swiper[mod].nextEl = void 0;
81889    } else {
81890      if (swiper.isElement) {
81891        swiper[mod].el.remove();
81892      }
81893      currentParams[mod].el = void 0;
81894      swiper[mod].el = void 0;
81895    }
81896  };
81897  if (changedParams.includes("loop") && swiper.isElement) {
81898    if (currentParams.loop && !passedParams.loop) {
81899      loopNeedDestroy = true;
81900    } else if (!currentParams.loop && passedParams.loop) {
81901      loopNeedEnable = true;
81902    } else {
81903      loopNeedReloop = true;
81904    }
81905  }
81906  updateParams.forEach((key) => {
81907    if (isObject6(currentParams[key]) && isObject6(passedParams[key])) {
81908      Object.assign(currentParams[key], passedParams[key]);
81909      if ((key === "navigation" || key === "pagination" || key === "scrollbar") && "enabled" in passedParams[key] && !passedParams[key].enabled) {
81910        destroyModule(key);
81911      }
81912    } else {
81913      const newValue = passedParams[key];
81914      if ((newValue === true || newValue === false) && (key === "navigation" || key === "pagination" || key === "scrollbar")) {
81915        if (newValue === false) {
81916          destroyModule(key);
81917        }
81918      } else {
81919        currentParams[key] = passedParams[key];
81920      }
81921    }
81922  });
81923  if (updateParams.includes("controller") && !needControllerInit && swiper.controller && swiper.controller.control && currentParams.controller && currentParams.controller.control) {
81924    swiper.controller.control = currentParams.controller.control;
81925  }
81926  if (changedParams.includes("children") && slides && virtual && currentParams.virtual.enabled) {
81927    virtual.slides = slides;
81928    virtual.update(true);
81929  } else if (changedParams.includes("virtual") && virtual && currentParams.virtual.enabled) {
81930    if (slides) virtual.slides = slides;
81931    virtual.update(true);
81932  }
81933  if (changedParams.includes("children") && slides && currentParams.loop) {
81934    loopNeedReloop = true;
81935  }
81936  if (needThumbsInit) {
81937    const initialized = thumbs.init();
81938    if (initialized) thumbs.update(true);
81939  }
81940  if (needControllerInit) {
81941    swiper.controller.control = currentParams.controller.control;
81942  }
81943  if (needPaginationInit) {
81944    if (swiper.isElement && (!paginationEl || typeof paginationEl === "string")) {
81945      paginationEl = document.createElement("div");
81946      paginationEl.classList.add("swiper-pagination");
81947      paginationEl.part.add("pagination");
81948      swiper.el.appendChild(paginationEl);
81949    }
81950    if (paginationEl) currentParams.pagination.el = paginationEl;
81951    pagination.init();
81952    pagination.render();
81953    pagination.update();
81954  }
81955  if (needScrollbarInit) {
81956    if (swiper.isElement && (!scrollbarEl || typeof scrollbarEl === "string")) {
81957      scrollbarEl = document.createElement("div");
81958      scrollbarEl.classList.add("swiper-scrollbar");
81959      scrollbarEl.part.add("scrollbar");
81960      swiper.el.appendChild(scrollbarEl);
81961    }
81962    if (scrollbarEl) currentParams.scrollbar.el = scrollbarEl;
81963    scrollbar.init();
81964    scrollbar.updateSize();
81965    scrollbar.setTranslate();
81966  }
81967  if (needNavigationInit) {
81968    if (swiper.isElement) {
81969      if (!nextEl || typeof nextEl === "string") {
81970        nextEl = document.createElement("div");
81971        nextEl.classList.add("swiper-button-next");
81972        setInnerHTML(nextEl, swiper.hostEl.constructor.nextButtonSvg);
81973        nextEl.part.add("button-next");
81974        swiper.el.appendChild(nextEl);
81975      }
81976      if (!prevEl || typeof prevEl === "string") {
81977        prevEl = document.createElement("div");
81978        prevEl.classList.add("swiper-button-prev");
81979        setInnerHTML(prevEl, swiper.hostEl.constructor.prevButtonSvg);
81980        prevEl.part.add("button-prev");
81981        swiper.el.appendChild(prevEl);
81982      }
81983    }
81984    if (nextEl) currentParams.navigation.nextEl = nextEl;
81985    if (prevEl) currentParams.navigation.prevEl = prevEl;
81986    navigation.init();
81987    navigation.update();
81988  }
81989  if (changedParams.includes("allowSlideNext")) {
81990    swiper.allowSlideNext = passedParams.allowSlideNext;
81991  }
81992  if (changedParams.includes("allowSlidePrev")) {
81993    swiper.allowSlidePrev = passedParams.allowSlidePrev;
81994  }
81995  if (changedParams.includes("direction")) {
81996    swiper.changeDirection(passedParams.direction, false);
81997  }
81998  if (loopNeedDestroy || loopNeedReloop) {
81999    swiper.loopDestroy();
82000  }
82001  if (loopNeedEnable || loopNeedReloop) {
82002    swiper.loopCreate();
82003  }
82004  swiper.update();
82005}
82006
vendor: 3,596 bytes, lines 82007-82107
82007// node_modules/swiper/shared/get-element-params.mjs
82008var formatValue = (val) => {
82009  if (parseFloat(val) === Number(val)) return Number(val);
82010  if (val === "true") return true;
82011  if (val === "") return true;
82012  if (val === "false") return false;
82013  if (val === "null") return null;
82014  if (val === "undefined") return void 0;
82015  if (typeof val === "string" && val.includes("{") && val.includes("}") && val.includes('"')) {
82016    let v;
82017    try {
82018      v = JSON.parse(val);
82019    } catch (err) {
82020      v = val;
82021    }
82022    return v;
82023  }
82024  return val;
82025};
82026var modulesParamsList = ["a11y", "autoplay", "controller", "cards-effect", "coverflow-effect", "creative-effect", "cube-effect", "fade-effect", "flip-effect", "free-mode", "grid", "hash-navigation", "history", "keyboard", "mousewheel", "navigation", "pagination", "parallax", "scrollbar", "thumbs", "virtual", "zoom"];
82027function getParams(element, propName, propValue) {
82028  const params = {};
82029  const passedParams = {};
82030  extend3(params, defaults);
82031  const localParamsList = [...paramsList, "on"];
82032  const allowedParams = localParamsList.map((key) => key.replace(/_/, ""));
82033  localParamsList.forEach((paramName) => {
82034    paramName = paramName.replace("_", "");
82035    if (typeof element[paramName] !== "undefined") {
82036      passedParams[paramName] = element[paramName];
82037    }
82038  });
82039  const attrsList = [...element.attributes];
82040  if (typeof propName === "string" && typeof propValue !== "undefined") {
82041    attrsList.push({
82042      name: propName,
82043      value: isObject6(propValue) ? __spreadValues({}, propValue) : propValue
82044    });
82045  }
82046  attrsList.forEach((attr) => {
82047    const moduleParam = modulesParamsList.find((mParam) => attr.name.startsWith(`${mParam}-`));
82048    if (moduleParam) {
82049      const parentObjName = attrToProp(moduleParam);
82050      const subObjName = attrToProp(attr.name.split(`${moduleParam}-`)[1]);
82051      if (typeof passedParams[parentObjName] === "undefined") {
82052        passedParams[parentObjName] = {};
82053      }
82054      if (passedParams[parentObjName] === true) {
82055        passedParams[parentObjName] = {
82056          enabled: true
82057        };
82058      }
82059      if (passedParams[parentObjName] === false) {
82060        passedParams[parentObjName] = {
82061          enabled: false
82062        };
82063      }
82064      passedParams[parentObjName][subObjName] = formatValue(attr.value);
82065    } else {
82066      const name = attrToProp(attr.name);
82067      if (!allowedParams.includes(name)) return;
82068      const value = formatValue(attr.value);
82069      if (passedParams[name] && modulesParamsList.includes(attr.name) && !isObject6(value)) {
82070        if (passedParams[name].constructor !== Object) {
82071          passedParams[name] = {};
82072        }
82073        passedParams[name].enabled = !!value;
82074      } else {
82075        passedParams[name] = value;
82076      }
82077    }
82078  });
82079  extend3(params, passedParams);
82080  if (params.navigation) {
82081    params.navigation = __spreadValues({
82082      prevEl: ".swiper-button-prev",
82083      nextEl: ".swiper-button-next"
82084    }, params.navigation !== true ? params.navigation : {});
82085  } else if (params.navigation === false) {
82086    delete params.navigation;
82087  }
82088  if (params.scrollbar) {
82089    params.scrollbar = __spreadValues({
82090      el: ".swiper-scrollbar"
82091    }, params.scrollbar !== true ? params.scrollbar : {});
82092  } else if (params.scrollbar === false) {
82093    delete params.scrollbar;
82094  }
82095  if (params.pagination) {
82096    params.pagination = __spreadValues({
82097      el: ".swiper-pagination"
82098    }, params.pagination !== true ? params.pagination : {});
82099  } else if (params.pagination === false) {
82100    delete params.pagination;
82101  }
82102  return {
82103    params,
82104    passedParams
82105  };
82106}
82107
vendor: 24,838 bytes, lines 82108-82362
82108// node_modules/swiper/swiper-element-bundle.mjs
82109var SwiperCSS = `:host{--swiper-theme-color:#007aff}:host{position:relative;display:block;margin-left:auto;margin-right:auto;z-index:1}.swiper{width:100%;height:100%;margin-left:auto;margin-right:auto;position:relative;overflow:hidden;list-style:none;padding:0;z-index:1;display:block}.swiper-vertical>.swiper-wrapper{flex-direction:column}.swiper-wrapper{position:relative;width:100%;height:100%;z-index:1;display:flex;transition-property:transform;transition-timing-function:var(--swiper-wrapper-transition-timing-function,initial);box-sizing:content-box}.swiper-android ::slotted(swiper-slide),.swiper-ios ::slotted(swiper-slide),.swiper-wrapper{transform:translate3d(0px,0,0)}.swiper-horizontal{touch-action:pan-y}.swiper-vertical{touch-action:pan-x}::slotted(swiper-slide){flex-shrink:0;width:100%;height:100%;position:relative;transition-property:transform;display:block}::slotted(.swiper-slide-invisible-blank){visibility:hidden}.swiper-autoheight,.swiper-autoheight ::slotted(swiper-slide){height:auto}.swiper-autoheight .swiper-wrapper{align-items:flex-start;transition-property:transform,height}.swiper-backface-hidden ::slotted(swiper-slide){transform:translateZ(0);-webkit-backface-visibility:hidden;backface-visibility:hidden}.swiper-3d.swiper-css-mode .swiper-wrapper{perspective:1200px}.swiper-3d .swiper-wrapper{transform-style:preserve-3d}.swiper-3d{perspective:1200px}.swiper-3d .swiper-cube-shadow,.swiper-3d ::slotted(swiper-slide){transform-style:preserve-3d}.swiper-css-mode>.swiper-wrapper{overflow:auto;scrollbar-width:none;-ms-overflow-style:none}.swiper-css-mode>.swiper-wrapper::-webkit-scrollbar{display:none}.swiper-css-mode ::slotted(swiper-slide){scroll-snap-align:start start}.swiper-css-mode.swiper-horizontal>.swiper-wrapper{scroll-snap-type:x mandatory}.swiper-css-mode.swiper-vertical>.swiper-wrapper{scroll-snap-type:y mandatory}.swiper-css-mode.swiper-free-mode>.swiper-wrapper{scroll-snap-type:none}.swiper-css-mode.swiper-free-mode ::slotted(swiper-slide){scroll-snap-align:none}.swiper-css-mode.swiper-centered>.swiper-wrapper::before{content:'';flex-shrink:0;order:9999}.swiper-css-mode.swiper-centered ::slotted(swiper-slide){scroll-snap-align:center center;scroll-snap-stop:always}.swiper-css-mode.swiper-centered.swiper-horizontal ::slotted(swiper-slide):first-child{margin-inline-start:var(--swiper-centered-offset-before)}.swiper-css-mode.swiper-centered.swiper-horizontal>.swiper-wrapper::before{height:100%;min-height:1px;width:var(--swiper-centered-offset-after)}.swiper-css-mode.swiper-centered.swiper-vertical ::slotted(swiper-slide):first-child{margin-block-start:var(--swiper-centered-offset-before)}.swiper-css-mode.swiper-centered.swiper-vertical>.swiper-wrapper::before{width:100%;min-width:1px;height:var(--swiper-centered-offset-after)}.swiper-virtual ::slotted(swiper-slide){-webkit-backface-visibility:hidden;transform:translateZ(0)}.swiper-virtual.swiper-css-mode .swiper-wrapper::after{content:'';position:absolute;left:0;top:0;pointer-events:none}.swiper-virtual.swiper-css-mode.swiper-horizontal .swiper-wrapper::after{height:1px;width:var(--swiper-virtual-size)}.swiper-virtual.swiper-css-mode.swiper-vertical .swiper-wrapper::after{width:1px;height:var(--swiper-virtual-size)}:host{--swiper-navigation-size:44px}.swiper-button-next,.swiper-button-prev{position:absolute;top:var(--swiper-navigation-top-offset,50%);width:calc(var(--swiper-navigation-size)/ 44 * 27);height:var(--swiper-navigation-size);margin-top:calc(0px - (var(--swiper-navigation-size)/ 2));z-index:10;cursor:pointer;display:flex;align-items:center;justify-content:center;color:var(--swiper-navigation-color,var(--swiper-theme-color))}.swiper-button-next.swiper-button-disabled,.swiper-button-prev.swiper-button-disabled{opacity:.35;cursor:auto;pointer-events:none}.swiper-button-next.swiper-button-hidden,.swiper-button-prev.swiper-button-hidden{opacity:0;cursor:auto;pointer-events:none}.swiper-navigation-disabled .swiper-button-next,.swiper-navigation-disabled .swiper-button-prev{display:none!important}.swiper-button-next svg,.swiper-button-prev svg{width:100%;height:100%;object-fit:contain;transform-origin:center}.swiper-rtl .swiper-button-next svg,.swiper-rtl .swiper-button-prev svg{transform:rotate(180deg)}.swiper-button-prev,.swiper-rtl .swiper-button-next{left:var(--swiper-navigation-sides-offset,10px);right:auto}.swiper-button-next,.swiper-rtl .swiper-button-prev{right:var(--swiper-navigation-sides-offset,10px);left:auto}.swiper-button-lock{display:none}.swiper-pagination{position:absolute;text-align:center;transition:.3s opacity;transform:translate3d(0,0,0);z-index:10}.swiper-pagination.swiper-pagination-hidden{opacity:0}.swiper-pagination-disabled>.swiper-pagination,.swiper-pagination.swiper-pagination-disabled{display:none!important}.swiper-horizontal>.swiper-pagination-bullets,.swiper-pagination-bullets.swiper-pagination-horizontal,.swiper-pagination-custom,.swiper-pagination-fraction{bottom:var(--swiper-pagination-bottom,8px);top:var(--swiper-pagination-top,auto);left:0;width:100%}.swiper-pagination-bullets-dynamic{overflow:hidden;font-size:0}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet{transform:scale(.33);position:relative}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active{transform:scale(1)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-main{transform:scale(1)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-prev{transform:scale(.66)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-prev-prev{transform:scale(.33)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-next{transform:scale(.66)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-next-next{transform:scale(.33)}.swiper-pagination-bullet{width:var(--swiper-pagination-bullet-width,var(--swiper-pagination-bullet-size,8px));height:var(--swiper-pagination-bullet-height,var(--swiper-pagination-bullet-size,8px));display:inline-block;border-radius:var(--swiper-pagination-bullet-border-radius,50%);background:var(--swiper-pagination-bullet-inactive-color,#000);opacity:var(--swiper-pagination-bullet-inactive-opacity, .2)}button.swiper-pagination-bullet{border:none;margin:0;padding:0;box-shadow:none;-webkit-appearance:none;appearance:none}.swiper-pagination-clickable .swiper-pagination-bullet{cursor:pointer}.swiper-pagination-bullet:only-child{display:none!important}.swiper-pagination-bullet-active{opacity:var(--swiper-pagination-bullet-opacity, 1);background:var(--swiper-pagination-color,var(--swiper-theme-color))}.swiper-pagination-vertical.swiper-pagination-bullets,.swiper-vertical>.swiper-pagination-bullets{right:var(--swiper-pagination-right,8px);left:var(--swiper-pagination-left,auto);top:50%;transform:translate3d(0px,-50%,0)}.swiper-pagination-vertical.swiper-pagination-bullets .swiper-pagination-bullet,.swiper-vertical>.swiper-pagination-bullets .swiper-pagination-bullet{margin:var(--swiper-pagination-bullet-vertical-gap,6px) 0;display:block}.swiper-pagination-vertical.swiper-pagination-bullets.swiper-pagination-bullets-dynamic,.swiper-vertical>.swiper-pagination-bullets.swiper-pagination-bullets-dynamic{top:50%;transform:translateY(-50%);width:8px}.swiper-pagination-vertical.swiper-pagination-bullets.swiper-pagination-bullets-dynamic .swiper-pagination-bullet,.swiper-vertical>.swiper-pagination-bullets.swiper-pagination-bullets-dynamic .swiper-pagination-bullet{display:inline-block;transition:.2s transform,.2s top}.swiper-horizontal>.swiper-pagination-bullets .swiper-pagination-bullet,.swiper-pagination-horizontal.swiper-pagination-bullets .swiper-pagination-bullet{margin:0 var(--swiper-pagination-bullet-horizontal-gap,4px)}.swiper-horizontal>.swiper-pagination-bullets.swiper-pagination-bullets-dynamic,.swiper-pagination-horizontal.swiper-pagination-bullets.swiper-pagination-bullets-dynamic{left:50%;transform:translateX(-50%);white-space:nowrap}.swiper-horizontal>.swiper-pagination-bullets.swiper-pagination-bullets-dynamic .swiper-pagination-bullet,.swiper-pagination-horizontal.swiper-pagination-bullets.swiper-pagination-bullets-dynamic .swiper-pagination-bullet{transition:.2s transform,.2s left}.swiper-horizontal.swiper-rtl>.swiper-pagination-bullets-dynamic .swiper-pagination-bullet{transition:.2s transform,.2s right}.swiper-pagination-fraction{color:var(--swiper-pagination-fraction-color,inherit)}.swiper-pagination-progressbar{background:var(--swiper-pagination-progressbar-bg-color,rgba(0,0,0,.25));position:absolute}.swiper-pagination-progressbar .swiper-pagination-progressbar-fill{background:var(--swiper-pagination-color,var(--swiper-theme-color));position:absolute;left:0;top:0;width:100%;height:100%;transform:scale(0);transform-origin:left top}.swiper-rtl .swiper-pagination-progressbar .swiper-pagination-progressbar-fill{transform-origin:right top}.swiper-horizontal>.swiper-pagination-progressbar,.swiper-pagination-progressbar.swiper-pagination-horizontal,.swiper-pagination-progressbar.swiper-pagination-vertical.swiper-pagination-progressbar-opposite,.swiper-vertical>.swiper-pagination-progressbar.swiper-pagination-progressbar-opposite{width:100%;height:var(--swiper-pagination-progressbar-size,4px);left:0;top:0}.swiper-horizontal>.swiper-pagination-progressbar.swiper-pagination-progressbar-opposite,.swiper-pagination-progressbar.swiper-pagination-horizontal.swiper-pagination-progressbar-opposite,.swiper-pagination-progressbar.swiper-pagination-vertical,.swiper-vertical>.swiper-pagination-progressbar{width:var(--swiper-pagination-progressbar-size,4px);height:100%;left:0;top:0}.swiper-pagination-lock{display:none}.swiper-scrollbar{border-radius:var(--swiper-scrollbar-border-radius,10px);position:relative;touch-action:none;background:var(--swiper-scrollbar-bg-color,rgba(0,0,0,.1))}.swiper-scrollbar-disabled>.swiper-scrollbar,.swiper-scrollbar.swiper-scrollbar-disabled{display:none!important}.swiper-horizontal>.swiper-scrollbar,.swiper-scrollbar.swiper-scrollbar-horizontal{position:absolute;left:var(--swiper-scrollbar-sides-offset,1%);bottom:var(--swiper-scrollbar-bottom,4px);top:var(--swiper-scrollbar-top,auto);z-index:50;height:var(--swiper-scrollbar-size,4px);width:calc(100% - 2 * var(--swiper-scrollbar-sides-offset,1%))}.swiper-scrollbar.swiper-scrollbar-vertical,.swiper-vertical>.swiper-scrollbar{position:absolute;left:var(--swiper-scrollbar-left,auto);right:var(--swiper-scrollbar-right,4px);top:var(--swiper-scrollbar-sides-offset,1%);z-index:50;width:var(--swiper-scrollbar-size,4px);height:calc(100% - 2 * var(--swiper-scrollbar-sides-offset,1%))}.swiper-scrollbar-drag{height:100%;width:100%;position:relative;background:var(--swiper-scrollbar-drag-bg-color,rgba(0,0,0,.5));border-radius:var(--swiper-scrollbar-border-radius,10px);left:0;top:0}.swiper-scrollbar-cursor-drag{cursor:move}.swiper-scrollbar-lock{display:none}::slotted(.swiper-slide-zoomed){cursor:move;touch-action:none}.swiper .swiper-notification{position:absolute;left:0;top:0;pointer-events:none;opacity:0;z-index:-1000}.swiper-free-mode>.swiper-wrapper{transition-timing-function:ease-out;margin:0 auto}.swiper-grid>.swiper-wrapper{flex-wrap:wrap}.swiper-grid-column>.swiper-wrapper{flex-wrap:wrap;flex-direction:column}.swiper-fade.swiper-free-mode ::slotted(swiper-slide){transition-timing-function:ease-out}.swiper-fade ::slotted(swiper-slide){pointer-events:none;transition-property:opacity}.swiper-fade ::slotted(swiper-slide) ::slotted(swiper-slide){pointer-events:none}.swiper-fade ::slotted(.swiper-slide-active){pointer-events:auto}.swiper-fade ::slotted(.swiper-slide-active) ::slotted(.swiper-slide-active){pointer-events:auto}.swiper.swiper-cube{overflow:visible}.swiper-cube ::slotted(swiper-slide){pointer-events:none;-webkit-backface-visibility:hidden;backface-visibility:hidden;z-index:1;visibility:hidden;transform-origin:0 0;width:100%;height:100%}.swiper-cube ::slotted(swiper-slide) ::slotted(swiper-slide){pointer-events:none}.swiper-cube.swiper-rtl ::slotted(swiper-slide){transform-origin:100% 0}.swiper-cube ::slotted(.swiper-slide-active),.swiper-cube ::slotted(.swiper-slide-active) ::slotted(.swiper-slide-active){pointer-events:auto}.swiper-cube ::slotted(.swiper-slide-active),.swiper-cube ::slotted(.swiper-slide-next),.swiper-cube ::slotted(.swiper-slide-prev){pointer-events:auto;visibility:visible}.swiper-cube .swiper-cube-shadow{position:absolute;left:0;bottom:0px;width:100%;height:100%;opacity:.6;z-index:0}.swiper-cube .swiper-cube-shadow:before{content:'';background:#000;position:absolute;left:0;top:0;bottom:0;right:0;filter:blur(50px)}.swiper-cube ::slotted(.swiper-slide-next)+::slotted(swiper-slide){pointer-events:auto;visibility:visible}.swiper.swiper-flip{overflow:visible}.swiper-flip ::slotted(swiper-slide){pointer-events:none;-webkit-backface-visibility:hidden;backface-visibility:hidden;z-index:1}.swiper-flip ::slotted(swiper-slide) ::slotted(swiper-slide){pointer-events:none}.swiper-flip ::slotted(.swiper-slide-active),.swiper-flip ::slotted(.swiper-slide-active) ::slotted(.swiper-slide-active){pointer-events:auto}.swiper-creative ::slotted(swiper-slide){-webkit-backface-visibility:hidden;backface-visibility:hidden;overflow:hidden;transition-property:transform,opacity,height}.swiper.swiper-cards{overflow:visible}.swiper-cards ::slotted(swiper-slide){transform-origin:center bottom;-webkit-backface-visibility:hidden;backface-visibility:hidden;overflow:hidden}`;
82110var SwiperSlideCSS = `::slotted(.swiper-slide-shadow),::slotted(.swiper-slide-shadow-bottom),::slotted(.swiper-slide-shadow-left),::slotted(.swiper-slide-shadow-right),::slotted(.swiper-slide-shadow-top){position:absolute;left:0;top:0;width:100%;height:100%;pointer-events:none;z-index:10}::slotted(.swiper-slide-shadow){background:rgba(0,0,0,.15)}::slotted(.swiper-slide-shadow-left){background-image:linear-gradient(to left,rgba(0,0,0,.5),rgba(0,0,0,0))}::slotted(.swiper-slide-shadow-right){background-image:linear-gradient(to right,rgba(0,0,0,.5),rgba(0,0,0,0))}::slotted(.swiper-slide-shadow-top){background-image:linear-gradient(to top,rgba(0,0,0,.5),rgba(0,0,0,0))}::slotted(.swiper-slide-shadow-bottom){background-image:linear-gradient(to bottom,rgba(0,0,0,.5),rgba(0,0,0,0))}.swiper-lazy-preloader{animation:swiper-preloader-spin 1s infinite linear;width:42px;height:42px;position:absolute;left:50%;top:50%;margin-left:-21px;margin-top:-21px;z-index:10;transform-origin:50%;box-sizing:border-box;border:4px solid var(--swiper-preloader-color,var(--swiper-theme-color));border-radius:50%;border-top-color:transparent}@keyframes swiper-preloader-spin{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}::slotted(.swiper-slide-shadow-cube.swiper-slide-shadow-bottom),::slotted(.swiper-slide-shadow-cube.swiper-slide-shadow-left),::slotted(.swiper-slide-shadow-cube.swiper-slide-shadow-right),::slotted(.swiper-slide-shadow-cube.swiper-slide-shadow-top){z-index:0;-webkit-backface-visibility:hidden;backface-visibility:hidden}::slotted(.swiper-slide-shadow-flip.swiper-slide-shadow-bottom),::slotted(.swiper-slide-shadow-flip.swiper-slide-shadow-left),::slotted(.swiper-slide-shadow-flip.swiper-slide-shadow-right),::slotted(.swiper-slide-shadow-flip.swiper-slide-shadow-top){z-index:0;-webkit-backface-visibility:hidden;backface-visibility:hidden}::slotted(.swiper-zoom-container){width:100%;height:100%;display:flex;justify-content:center;align-items:center;text-align:center}::slotted(.swiper-zoom-container)>canvas,::slotted(.swiper-zoom-container)>img,::slotted(.swiper-zoom-container)>svg{max-width:100%;max-height:100%;object-fit:contain}`;
82111var DummyHTMLElement = class {
82112};
82113var ClassToExtend = typeof window === "undefined" || typeof HTMLElement === "undefined" ? DummyHTMLElement : HTMLElement;
82114var arrowSvg = `<svg width="11" height="20" viewBox="0 0 11 20" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M0.38296 20.0762C0.111788 19.805 0.111788 19.3654 0.38296 19.0942L9.19758 10.2796L0.38296 1.46497C0.111788 1.19379 0.111788 0.754138 0.38296 0.482966C0.654131 0.211794 1.09379 0.211794 1.36496 0.482966L10.4341 9.55214C10.8359 9.9539 10.8359 10.6053 10.4341 11.007L1.36496 20.0762C1.09379 20.3474 0.654131 20.3474 0.38296 20.0762Z" fill="currentColor"/></svg>
82115    `;
82116var addStyle = (shadowRoot, styles2) => {
82117  if (typeof CSSStyleSheet !== "undefined" && shadowRoot.adoptedStyleSheets) {
82118    const styleSheet = new CSSStyleSheet();
82119    styleSheet.replaceSync(styles2);
82120    shadowRoot.adoptedStyleSheets = [styleSheet];
82121  } else {
82122    const style = document.createElement("style");
82123    style.rel = "stylesheet";
82124    style.textContent = styles2;
82125    shadowRoot.appendChild(style);
82126  }
82127};
82128var SwiperContainer = class extends ClassToExtend {
82129  constructor() {
82130    super();
82131    this.attachShadow({
82132      mode: "open"
82133    });
82134  }
82135  static get nextButtonSvg() {
82136    return arrowSvg;
82137  }
82138  static get prevButtonSvg() {
82139    return arrowSvg.replace("/></svg>", ' transform-origin="center" transform="rotate(180)"/></svg>');
82140  }
82141  cssStyles() {
82142    return [
82143      SwiperCSS,
82144      // eslint-disable-line
82145      ...this.injectStyles && Array.isArray(this.injectStyles) ? this.injectStyles : []
82146    ].join("\n");
82147  }
82148  cssLinks() {
82149    return this.injectStylesUrls || [];
82150  }
82151  calcSlideSlots() {
82152    const currentSideSlots = this.slideSlots || 0;
82153    const slideSlotChildren = [...this.querySelectorAll(`[slot^=slide-]`)].map((child) => {
82154      return parseInt(child.getAttribute("slot").split("slide-")[1], 10);
82155    });
82156    this.slideSlots = slideSlotChildren.length ? Math.max(...slideSlotChildren) + 1 : 0;
82157    if (!this.rendered) return;
82158    if (this.slideSlots > currentSideSlots) {
82159      for (let i = currentSideSlots; i < this.slideSlots; i += 1) {
82160        const slideEl = document.createElement("swiper-slide");
82161        slideEl.setAttribute("part", `slide slide-${i + 1}`);
82162        const slotEl = document.createElement("slot");
82163        slotEl.setAttribute("name", `slide-${i + 1}`);
82164        slideEl.appendChild(slotEl);
82165        this.shadowRoot.querySelector(".swiper-wrapper").appendChild(slideEl);
82166      }
82167    } else if (this.slideSlots < currentSideSlots) {
82168      const slides = this.swiper.slides;
82169      for (let i = slides.length - 1; i >= 0; i -= 1) {
82170        if (i > this.slideSlots) {
82171          slides[i].remove();
82172        }
82173      }
82174    }
82175  }
82176  render() {
82177    if (this.rendered) return;
82178    this.calcSlideSlots();
82179    let localStyles = this.cssStyles();
82180    if (this.slideSlots > 0) {
82181      localStyles = localStyles.replace(/::slotted\(([a-z-0-9.]*)\)/g, "$1");
82182    }
82183    if (localStyles.length) {
82184      addStyle(this.shadowRoot, localStyles);
82185    }
82186    this.cssLinks().forEach((url) => {
82187      const linkExists = this.shadowRoot.querySelector(`link[href="${url}"]`);
82188      if (linkExists) return;
82189      const linkEl = document.createElement("link");
82190      linkEl.rel = "stylesheet";
82191      linkEl.href = url;
82192      this.shadowRoot.appendChild(linkEl);
82193    });
82194    const el = document.createElement("div");
82195    el.classList.add("swiper");
82196    el.part = "container";
82197    setInnerHTML(el, `
82198      <slot name="container-start"></slot>
82199      <div class="swiper-wrapper" part="wrapper">
82200        <slot></slot>
82201        ${Array.from({
82202      length: this.slideSlots
82203    }).map((_2, index) => `
82204        <swiper-slide part="slide slide-${index}">
82205          <slot name="slide-${index}"></slot>
82206        </swiper-slide>
82207        `).join("")}
82208      </div>
82209      <slot name="container-end"></slot>
82210      ${needsNavigation(this.passedParams) ? `
82211        <div part="button-prev" class="swiper-button-prev">${this.constructor.prevButtonSvg}</div>
82212        <div part="button-next" class="swiper-button-next">${this.constructor.nextButtonSvg}</div>
82213      ` : ""}
82214      ${needsPagination(this.passedParams) ? `
82215        <div part="pagination" class="swiper-pagination"></div>
82216      ` : ""}
82217      ${needsScrollbar(this.passedParams) ? `
82218        <div part="scrollbar" class="swiper-scrollbar"></div>
82219      ` : ""}
82220    `);
82221    this.shadowRoot.appendChild(el);
82222    this.rendered = true;
82223  }
82224  initialize() {
82225    var _this = this;
82226    if (this.swiper && this.swiper.initialized) return;
82227    const {
82228      params: swiperParams,
82229      passedParams
82230    } = getParams(this);
82231    this.swiperParams = swiperParams;
82232    this.passedParams = passedParams;
82233    delete this.swiperParams.init;
82234    this.render();
82235    this.swiper = new Swiper(this.shadowRoot.querySelector(".swiper"), __spreadProps(__spreadValues(__spreadValues({}, swiperParams.virtual ? {} : {
82236      observer: true
82237    }), swiperParams), {
82238      touchEventsTarget: "container",
82239      onAny: function(name) {
82240        if (name === "observerUpdate") {
82241          _this.calcSlideSlots();
82242        }
82243        const eventName = swiperParams.eventsPrefix ? `${swiperParams.eventsPrefix}${name.toLowerCase()}` : name.toLowerCase();
82244        for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
82245          args[_key - 1] = arguments[_key];
82246        }
82247        const event2 = new CustomEvent(eventName, {
82248          detail: args,
82249          bubbles: name !== "hashChange",
82250          cancelable: true
82251        });
82252        _this.dispatchEvent(event2);
82253      }
82254    }));
82255  }
82256  connectedCallback() {
82257    if (this.swiper && this.swiper.initialized && this.nested && this.closest("swiper-slide") && this.closest("swiper-slide").swiperLoopMoveDOM) {
82258      return;
82259    }
82260    if (this.init === false || this.getAttribute("init") === "false") {
82261      return;
82262    }
82263    this.initialize();
82264  }
82265  disconnectedCallback() {
82266    if (this.nested && this.closest("swiper-slide") && this.closest("swiper-slide").swiperLoopMoveDOM) {
82267      return;
82268    }
82269    if (this.swiper && this.swiper.destroy) {
82270      this.swiper.destroy();
82271    }
82272  }
82273  updateSwiperOnPropChange(propName, propValue) {
82274    const {
82275      params: swiperParams,
82276      passedParams
82277    } = getParams(this, propName, propValue);
82278    this.passedParams = passedParams;
82279    this.swiperParams = swiperParams;
82280    if (this.swiper && this.swiper.params[propName] === propValue) {
82281      return;
82282    }
82283    updateSwiper(__spreadValues(__spreadValues(__spreadValues({
82284      swiper: this.swiper,
82285      passedParams: this.passedParams,
82286      changedParams: [attrToProp(propName)]
82287    }, propName === "navigation" && passedParams[propName] ? {
82288      prevEl: ".swiper-button-prev",
82289      nextEl: ".swiper-button-next"
82290    } : {}), propName === "pagination" && passedParams[propName] ? {
82291      paginationEl: ".swiper-pagination"
82292    } : {}), propName === "scrollbar" && passedParams[propName] ? {
82293      scrollbarEl: ".swiper-scrollbar"
82294    } : {}));
82295  }
82296  attributeChangedCallback(attr, prevValue, newValue) {
82297    if (!(this.swiper && this.swiper.initialized)) return;
82298    if (prevValue === "true" && newValue === null) {
82299      newValue = false;
82300    }
82301    this.updateSwiperOnPropChange(attr, newValue);
82302  }
82303  static get observedAttributes() {
82304    const attrs = paramsList.filter((param) => param.includes("_")).map((param) => param.replace(/[A-Z]/g, (v) => `-${v}`).replace("_", "").toLowerCase());
82305    return attrs;
82306  }
82307};
82308paramsList.forEach((paramName) => {
82309  if (paramName === "init") return;
82310  paramName = paramName.replace("_", "");
82311  Object.defineProperty(SwiperContainer.prototype, paramName, {
82312    configurable: true,
82313    get() {
82314      return (this.passedParams || {})[paramName];
82315    },
82316    set(value) {
82317      if (!this.passedParams) this.passedParams = {};
82318      this.passedParams[paramName] = value;
82319      if (!(this.swiper && this.swiper.initialized)) return;
82320      this.updateSwiperOnPropChange(paramName, value);
82321    }
82322  });
82323});
82324var SwiperSlide = class extends ClassToExtend {
82325  constructor() {
82326    super();
82327    this.attachShadow({
82328      mode: "open"
82329    });
82330  }
82331  render() {
82332    const lazy = this.lazy || this.getAttribute("lazy") === "" || this.getAttribute("lazy") === "true";
82333    addStyle(this.shadowRoot, SwiperSlideCSS);
82334    this.shadowRoot.appendChild(document.createElement("slot"));
82335    if (lazy) {
82336      const lazyDiv = document.createElement("div");
82337      lazyDiv.classList.add("swiper-lazy-preloader");
82338      lazyDiv.part.add("preloader");
82339      this.shadowRoot.appendChild(lazyDiv);
82340    }
82341  }
82342  initialize() {
82343    this.render();
82344  }
82345  connectedCallback() {
82346    if (this.swiperLoopMoveDOM) {
82347      return;
82348    }
82349    this.initialize();
82350  }
82351};
82352var register = () => {
82353  if (typeof window === "undefined") return;
82354  if (!window.customElements.get("swiper-container")) window.customElements.define("swiper-container", SwiperContainer);
82355  if (!window.customElements.get("swiper-slide")) window.customElements.define("swiper-slide", SwiperSlide);
82356};
82357if (typeof window !== "undefined") {
82358  window.SwiperElementRegisterParams = (params) => {
82359    paramsList.push(...params);
82360  };
82361}
82362
82363// src/app/DoraWidget/dora-carousel/dora-carousel.component.ts
82364function DoraCarouselComponent_swiper_slide_2_div_1_Template(rf, ctx) {
82365  if (rf & 1) {
82366    \u0275\u0275element(0, "div", 8);
82367  }
82368  if (rf & 2) {
82369    const item_r1 = \u0275\u0275nextContext().$implicit;
82370    \u0275\u0275property("innerHTML", item_r1.title, \u0275\u0275sanitizeHtml);
82371  }
82372}
82373function DoraCarouselComponent_swiper_slide_2_Template(rf, ctx) {
82374  if (rf & 1) {
82375    \u0275\u0275elementStart(0, "swiper-slide");
82376    \u0275\u0275template(1, DoraCarouselComponent_swiper_slide_2_div_1_Template, 1, 1, "div", 6);
82377    \u0275\u0275element(2, "div", 7);
82378    \u0275\u0275elementEnd();
82379  }
82380  if (rf & 2) {
82381    const item_r1 = ctx.$implicit;
82382    \u0275\u0275classMap(item_r1.cssClass + " carousel-item");
82383    \u0275\u0275advance();
82384    \u0275\u0275property("ngIf", item_r1.title);
82385    \u0275\u0275advance();
82386    \u0275\u0275property("innerHTML", item_r1.htmlContent, \u0275\u0275sanitizeHtml);
82387  }
82388}
82389function DoraCarouselComponent_div_3_Template(rf, ctx) {
82390  if (rf & 1) {
82391    \u0275\u0275element(0, "div", 9);
82392  }
82393}
82394function DoraCarouselComponent_div_4_Template(rf, ctx) {
82395  if (rf & 1) {
82396    \u0275\u0275element(0, "div", 10);
82397  }
82398}
82399function DoraCarouselComponent_div_5_Template(rf, ctx) {
82400  if (rf & 1) {
82401    \u0275\u0275element(0, "div", 11);
82402  }
82403}
82404register();
82405var DoraCarouselComponent = class _DoraCarouselComponent extends WidgetBaseComponent {
82406  constructor(elementRef, messageService, configurationService, publisher, widgetService, http, translationService) {
82407    super(elementRef, messageService, configurationService, publisher, widgetService, http, translationService);
82408    this.carouselItems = [];
82409    this.autoplay = false;
82410    this.autoplayDelay = 3e3;
82411    this.loop = true;
82412    this.navigation = true;
82413    this.pagination = true;
82414    this.slidesPerView = 1;
82415    this.spaceBetween = 30;
82416    this.carouselHeight = 400;
82417  }
82418  ngAfterViewInit() {
82419    setTimeout(() => {
82420      this.initializeSwiper();
82421    }, 100);
82422  }
82423  onParameterInjectedFinished() {
82424    super.onParameterInjectedFinished();
82425    if (this.carouselItems.length === 0) {
82426      this.carouselItems = [
82427        new CarouselData('<div class="default-slide"><h3>Slide 1</h3><p>Contenuto della prima slide</p></div>', "Slide 1"),
82428        new CarouselData('<div class="default-slide"><h3>Slide 2</h3><p>Contenuto della seconda slide</p></div>', "Slide 2"),
82429        new CarouselData('<div class="default-slide"><h3>Slide 3</h3><p>Contenuto della terza slide</p></div>', "Slide 3")
82430      ];
82431    }
82432    setTimeout(() => {
82433      this.initializeSwiper();
82434    }, 200);
82435  }
82436  initializeSwiper() {
82437    this.swiperElement = this.elementRef.nativeElement.querySelector("swiper-container");
82438    if (this.swiperElement) {
82439      const containerElement = this.elementRef.nativeElement.querySelector(".dora-carousel-container");
82440      const prevButton = containerElement?.querySelector(".swiper-button-prev");
82441      const nextButton = containerElement?.querySelector(".swiper-button-next");
82442      const pagination = containerElement?.querySelector(".swiper-pagination");
82443      const swiperParams = {
82444        slidesPerView: this.slidesPerView,
82445        spaceBetween: this.spaceBetween,
82446        loop: this.loop,
82447        autoplay: this.autoplay ? {
82448          delay: this.autoplayDelay,
82449          disableOnInteraction: false
82450        } : false,
82451        navigation: this.navigation && prevButton && nextButton ? {
82452          nextEl: nextButton,
82453          prevEl: prevButton
82454        } : false,
82455        pagination: this.pagination && pagination ? {
82456          el: pagination,
82457          clickable: true
82458        } : false
82459      };
82460      Object.assign(this.swiperElement, swiperParams);
82461      this.swiperElement.initialize();
82462      console.log("Swiper initialized:", this.swiperElement.swiper);
82463      console.log("Navigation enabled:", this.navigation);
82464      console.log("Pagination enabled:", this.pagination);
82465      console.log("Prev button:", prevButton);
82466      console.log("Next button:", nextButton);
82467      console.log("Pagination element:", pagination);
82468    } else {
82469      console.error("Swiper container not found");
82470    }
82471  }
82472  onRefresh() {
82473    super.onRefresh();
82474    if (this.swiperElement && this.swiperElement.swiper) {
82475      this.swiperElement.swiper.update();
82476    }
82477  }
82478  static {
82479    this.\u0275fac = function DoraCarouselComponent_Factory(__ngFactoryType__) {
82480      return new (__ngFactoryType__ || _DoraCarouselComponent)(\u0275\u0275directiveInject(ElementRef), \u0275\u0275directiveInject(MessageService), \u0275\u0275directiveInject(ConfigurationService), \u0275\u0275directiveInject(PublisherService), \u0275\u0275directiveInject(WidgetService), \u0275\u0275directiveInject(HttpClient), \u0275\u0275directiveInject(TranslationService));
82481    };
82482  }
82483  static {
82484    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _DoraCarouselComponent, selectors: [["dora-carousel"]], standalone: false, features: [\u0275\u0275InheritDefinitionFeature], decls: 6, vars: 6, consts: [[1, "dora-carousel-container"], ["init", "false", 1, "dora-swiper"], [3, "class", 4, "ngFor", "ngForOf"], ["class", "swiper-button-prev", 4, "ngIf"], ["class", "swiper-button-next", 4, "ngIf"], ["class", "swiper-pagination", 4, "ngIf"], ["class", "slide-title", 3, "innerHTML", 4, "ngIf"], [1, "slide-content", 3, "innerHTML"], [1, "slide-title", 3, "innerHTML"], [1, "swiper-button-prev"], [1, "swiper-button-next"], [1, "swiper-pagination"]], template: function DoraCarouselComponent_Template(rf, ctx) {
82485      if (rf & 1) {
82486        \u0275\u0275elementStart(0, "div", 0)(1, "swiper-container", 1);
82487        \u0275\u0275template(2, DoraCarouselComponent_swiper_slide_2_Template, 3, 4, "swiper-slide", 2);
82488        \u0275\u0275elementEnd();
82489        \u0275\u0275template(3, DoraCarouselComponent_div_3_Template, 1, 0, "div", 3)(4, DoraCarouselComponent_div_4_Template, 1, 0, "div", 4)(5, DoraCarouselComponent_div_5_Template, 1, 0, "div", 5);
82490        \u0275\u0275elementEnd();
82491      }
82492      if (rf & 2) {
82493        \u0275\u0275styleProp("height", ctx.carouselHeight, "px");
82494        \u0275\u0275advance(2);
82495        \u0275\u0275property("ngForOf", ctx.carouselItems);
82496        \u0275\u0275advance();
82497        \u0275\u0275property("ngIf", ctx.navigation);
82498        \u0275\u0275advance();
82499        \u0275\u0275property("ngIf", ctx.navigation);
82500        \u0275\u0275advance();
82501        \u0275\u0275property("ngIf", ctx.pagination);
82502      }
82503    }, dependencies: [NgForOf, NgIf], styles: ["\n\n.dora-carousel-container[_ngcontent-%COMP%] {\n  width: 100%;\n  position: relative;\n}\n.dora-carousel-container[_ngcontent-%COMP%]   .dora-swiper[_ngcontent-%COMP%] {\n  width: 100%;\n  height: 100%;\n}\n.dora-carousel-container[_ngcontent-%COMP%]   .dora-swiper[_ngcontent-%COMP%]   swiper-slide[_ngcontent-%COMP%] {\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  flex-direction: column;\n}\n.dora-carousel-container[_ngcontent-%COMP%]   .dora-swiper[_ngcontent-%COMP%]   swiper-slide.carousel-item[_ngcontent-%COMP%] {\n  padding: 10px;\n  border-radius: 8px;\n}\n.dora-carousel-container[_ngcontent-%COMP%]   .dora-swiper[_ngcontent-%COMP%]   swiper-slide.carousel-item[_ngcontent-%COMP%]   .slide-title[_ngcontent-%COMP%] {\n  font-size: 18px;\n  font-weight: 600;\n  margin-bottom: 10px;\n  text-align: center;\n  color: #333;\n}\n.dora-carousel-container[_ngcontent-%COMP%]   .dora-swiper[_ngcontent-%COMP%]   swiper-slide[_ngcontent-%COMP%]   .slide-content[_ngcontent-%COMP%] {\n  width: 100%;\n  height: 100%;\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n  align-items: center;\n  padding: 20px;\n  box-sizing: border-box;\n}\n.dora-carousel-container[_ngcontent-%COMP%]   .swiper-button-prev[_ngcontent-%COMP%], \n.dora-carousel-container[_ngcontent-%COMP%]   .swiper-button-next[_ngcontent-%COMP%] {\n  color: #007bff;\n  z-index: 10;\n  position: absolute;\n  top: 50%;\n  transform: translateY(-50%);\n  width: 44px;\n  height: 44px;\n  background: rgba(255, 255, 255, 0.8);\n  border-radius: 50%;\n  display: flex;\n  align-items: center;\n  justify-content: center;\n  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);\n  cursor: pointer;\n}\n.dora-carousel-container[_ngcontent-%COMP%]   .swiper-button-prev[_ngcontent-%COMP%]:after, \n.dora-carousel-container[_ngcontent-%COMP%]   .swiper-button-next[_ngcontent-%COMP%]:after {\n  font-size: 18px;\n  font-weight: bold;\n}\n.dora-carousel-container[_ngcontent-%COMP%]   .swiper-button-prev[_ngcontent-%COMP%]:hover, \n.dora-carousel-container[_ngcontent-%COMP%]   .swiper-button-next[_ngcontent-%COMP%]:hover {\n  
82503color: #0056b3;\n  background: rgba(255, 255, 255, 0.95);\n}\n.dora-carousel-container[_ngcontent-%COMP%]   .swiper-button-prev[_ngcontent-%COMP%] {\n  left: 10px;\n}\n.dora-carousel-container[_ngcontent-%COMP%]   .swiper-button-next[_ngcontent-%COMP%] {\n  right: 10px;\n}\n.dora-carousel-container[_ngcontent-%COMP%]   .swiper-pagination[_ngcontent-%COMP%] {\n  z-index: 10;\n  position: absolute;\n  bottom: 20px;\n  left: 50%;\n  transform: translateX(-50%);\n  display: flex;\n  justify-content: center;\n  align-items: center;\n}\n.dora-carousel-container[_ngcontent-%COMP%]   .swiper-pagination[_ngcontent-%COMP%]   .swiper-pagination-bullet[_ngcontent-%COMP%] {\n  background: #007bff;\n  opacity: 0.5;\n  width: 12px;\n  height: 12px;\n  margin: 0 4px;\n  border-radius: 50%;\n  cursor: pointer;\n  transition: opacity 0.3s ease;\n}\n.dora-carousel-container[_ngcontent-%COMP%]   .swiper-pagination[_ngcontent-%COMP%]   .swiper-pagination-bullet.swiper-pagination-bullet-active[_ngcontent-%COMP%] {\n  opacity: 1;\n  background: #0056b3;\n}\n.default-slide[_ngcontent-%COMP%] {\n  text-align: center;\n  background:\n    linear-gradient(\n      135deg,\n      #667eea 0%,\n      #764ba2 100%);\n  color: white;\n  border-radius: 10px;\n  padding: 40px 20px;\n  width: 100%;\n  height: 100%;\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n  align-items: center;\n}\n.default-slide[_ngcontent-%COMP%]   h3[_ngcontent-%COMP%] {\n  margin: 0 0 15px 0;\n  font-size: 24px;\n  font-weight: 600;\n}\n.default-slide[_ngcontent-%COMP%]   p[_ngcontent-%COMP%] {\n  margin: 0;\n  font-size: 16px;\n  opacity: 0.9;\n}"] });
82504  }
82505};
82506__decorate([
82507  DoraPropertyDOC("Array di dati per le slide del carousel", ATTRIBUTE_TYPE.ARRAY, "", ATTRIBUTE_DATAPROVIDER_VALUES.NONE),
82508  DoraPropertyArray(CarouselData),
82509  __metadata("design:type", Array)
82510], DoraCarouselComponent.prototype, "carouselItems", void 0);
82511__decorate([
82512  DoraPropertyDOC("Abilita autoplay", ATTRIBUTE_TYPE.BOOLEAN, "false", ATTRIBUTE_DATAPROVIDER_VALUES.NONE),
82513  DoraProperty,
82514  __metadata("design:type", Boolean)
82515], DoraCarouselComponent.prototype, "autoplay", void 0);
82516__decorate([
82517  DoraPropertyDOC("Delay autoplay in millisecondi", ATTRIBUTE_TYPE.INTEGER, "3000", ATTRIBUTE_DATAPROVIDER_VALUES.NONE),
82518  DoraProperty,
82519  __metadata("design:type", Number)
82520], DoraCarouselComponent.prototype, "autoplayDelay", void 0);
82521__decorate([
82522  DoraPropertyDOC("Abilita loop infinito", ATTRIBUTE_TYPE.BOOLEAN, "true", ATTRIBUTE_DATAPROVIDER_VALUES.NONE),
82523  DoraProperty,
82524  __metadata("design:type", Boolean)
82525], DoraCarouselComponent.prototype, "loop", void 0);
82526__decorate([
82527  DoraPropertyDOC("Abilita frecce di navigazione", ATTRIBUTE_TYPE.BOOLEAN, "true", ATTRIBUTE_DATAPROVIDER_VALUES.NONE),
82528  DoraProperty,
82529  __metadata("design:type", Boolean)
82530], DoraCarouselComponent.prototype, "navigation", void 0);
82531__decorate([
82532  DoraPropertyDOC("Abilita indicatori di pagina", ATTRIBUTE_TYPE.BOOLEAN, "true", ATTRIBUTE_DATAPROVIDER_VALUES.NONE),
82533  DoraProperty,
82534  __metadata("design:type", Boolean)
82535], DoraCarouselComponent.prototype, "pagination", void 0);
82536__decorate([
82537  DoraPropertyDOC("Numero di slide visibili contemporaneamente", ATTRIBUTE_TYPE.INTEGER, "1", ATTRIBUTE_DATAPROVIDER_VALUES.NONE),
82538  DoraProperty,
82539  __metadata("design:type", Number)
82540], DoraCarouselComponent.prototype, "slidesPerView", void 0);
82541__decorate([
82542  DoraPropertyDOC("Spazio tra le slide in pixel", ATTRIBUTE_TYPE.INTEGER, "30", ATTRIBUTE_DATAPROVIDER_VALUES.NONE),
82543  DoraProperty,
82544  __metadata("design:type", Number)
82545], DoraCarouselComponent.prototype, "spaceBetween", void 0);
82546__decorate([
82547  DoraPropertyDOC("Altezza del carousel in pixel", ATTRIBUTE_TYPE.INTEGER, "400", ATTRIBUTE_DATAPROVIDER_VALUES.NONE),
82548  DoraProperty,
82549  __metadata("design:type", Number)
82550], DoraCarouselComponent.prototype, "carouselHeight", void 0);
82551(() => {
82552  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(DoraCarouselComponent, { className: "DoraCarouselComponent", filePath: "src/app/dorawidget/dora-carousel/dora-carousel.component.ts", lineNumber: 23 });
82553})();
82554
82555// src/app/app.component.ts
82556var AppComponent = class _AppComponent {
82557  static {
82558    this.TAG_PREFIX = "DAG-";
82559  }
82560  constructor(injector, applicationRef, viewContainerRef, publisherService, translationService, widgetService, ngZone) {
82561    this.injector = injector;
82562    this.applicationRef = applicationRef;
82563    this.viewContainerRef = viewContainerRef;
82564    this.publisherService = publisherService;
82565    this.translationService = translationService;
82566    this.widgetService = widgetService;
82567    this.ngZone = ngZone;
82568    this.widgetsConfigurationCreated = [];
82569    this.title = "DoraG";
82570    this.componentList = [
82571      { name: "dora-label", type: DoraLabelComponent },
82572      { name: "dora-data-grid", type: DoraDataGridComponent },
82573      { name: "dora-data-grid-selector-tab", type: DoraDataGridSelectorTabComponent },
82574      { name: "dora-data-grid-selector-tab-scroll", type: DoraDataGridSelectorTabScrollComponent },
82575      { name: "dora-data-grid-selector-lb", type: DoraDataGridSelectorLbComponent },
82576      { name: "dora-data-grid-selector-cb", type: DoraDataGridSelectorCbComponent },
82577      { name: "dora-grid-data-notes", type: DoraGridNotesComponent },
82578      { name: "dora-grid-title", type: DoraGridTitleComponent },
82579      { name: "dora-chart", type: DoraChartComponent },
82580      { name: "dora-chart-print", type: DoraChartPrintComponent },
82581      { name: "dora-chart-type-setting-lb", type: DoraChartTypeSettingLbComponent },
82582      { name: "dora-collapse-expand", type: DoraCollapseExpandComponent },
82583      { name: "dora-column-paginator", type: DoraColumnPaginatorComponent },
82584      { name: "dora-column-selector-lb", type: DoraColumnSelectorLbComponent },
82585      { name: "dora-rows-notes", type: DoraRowsNotesComponent },
82586      { name: "dora-rows-preselect-tab", type: DoraRowsPreselectTabComponent },
82587      { name: "dora-rows-preselect-lb", type: DoraRowsPreselectLbComponent },
82588      { name: "dora-row", type: DoraRowComponent },
82589      { name: "dora-series-from-grid", type: DoraSeriesFromGridComponent },
82590      { name: "dora-series-from-row", type: DoraSeriesFromRowComponent },
82591      { name: "dora-tab", type: DoraTabComponent },
82592      { name: "dora-series-value", type: DoraSeriesValueComponent },
82593      { name: "dora-series-selector", type: DoraSeriesSelectorComponent },
82594      { name: "dora-series-fixed", type: DoraSeriesFixedComponent },
82595      { name: "dora-corp-agent-user-input", type: DoraCorpAgentUserInputComponent },
82596      { name: "dora-corp-agent-user-history", type: DoraCorpAgentUserHistoryComponent },
82597      { name: "dora-corp-agent-close", type: DoraCorpAgentCloseComponent },
82598      { name: "dora-corp-agent-wizard", type: DoraCorpAgentWizardComponent },
82599      { name: "dora-corp-agent-wizard-show", type: DoraCorpAgentWizardShowComponent },
82600      { name: "dora-url-content", type: DoraUrlContentComponent },
82601      { name: "dora-carousel", type: DoraCarouselComponent }
82602    ];
82603    this.translationService.initialize(this);
82604  }
82605  onTranslationInitialized() {
82606    this.publisherService.initialize(this);
82607  }
82608  onPublisherServiceInitialized() {
82609    console.log("Publisher service initialized");
82610    this.widgetService.setComponentList(this.componentList);
82611    this.widgetService.addWidgetFromDOM();
82612    window["DoraGComponentReference"] = {
82613      zone: this.ngZone,
82614      refresh: () => this.runReferesh(),
82615      configuration: (widegetId) => this.runConfiguration(widegetId),
82616      component: this
82617    };
82618  }
82619  /**
82620   * Scopre tutti i widget definiti nel DOM e li crea dinamicamente
82621   * @param selector
82622   */
82623  // addWidgetFromDOM(selector: string = ''): void {
82624  //   this.componentList.forEach((componentName) => {
82625  //
82626  //     // crea selettore
82627  //     let completeSelector = selector !== '' ? selector + ' ': '';
82628  //     completeSelector +=  AppComponent.TAG_PREFIX + componentName.name;
82629  //
82630  //     const elementsFound = document.querySelectorAll(completeSelector);
82631  //
82632  //     // tslint:disable-next-line:prefer-for-of
82633  //     for (let idx = 0; idx < elementsFound.length; idx++ ) {
82634  //       const x = elementsFound[idx];
82635  //
82636  //       console.log('found [' + AppComponent.TAG_PREFIX + componentName.name + ']');
82637  //
82638  //       // Create element
82639  //       const fatherElement = document.createElement(componentName.name);
82640  //
82641  //       // set attributes
82642  //       for (let i = 0; i < x.attributes.length; i++) {
82643  //         const attribute = x.attributes.item(i);
82644  //
82645  //         if (attribute !== null){
82646  //           fatherElement.setAttribute(attribute.name, attribute.value);
82647  //         }
82648  //       }
82649  //
82650  //       // Create the component and wire it up with the element
82651  //       // @ts-ignore
82652  //       const newComponentRef = createComponent(componentName.type, {
82653  //         environmentInjector: this.injector,
82654  //         hostElement: fatherElement
82655  //       });
82656  //
82657  //       const widgetCreated = newComponentRef.instance as WidgetBaseComponent;
82658  //       widgetCreated.setAppComponent(this);
82659  //       widgetCreated.setExternalTagSelector(AppComponent.TAG_PREFIX + componentName.name);
82660  //       this.widgetsCreated.push(widgetCreated);
82661  //
82662  //
82663  //       // Attach to the view so that the change detector knows to run
82664  //       this.applicationRef.attachView(newComponentRef.hostView);
82665  //
82666  //
82667  //
82668  //       // Add to the DOM
82669  //       x.appendChild(fatherElement);
82670  //     }
82671  //
82672  //   });
82673  //
82674  // }
82675  onResize(event2) {
82676    this.runReferesh();
82677  }
82678  runReferesh() {
82679    console.log("Called runReferesh()");
82680    for (let idx = 0; idx < this.widgetService.WidgetsCreated.length; idx++) {
82681      this.widgetService.WidgetsCreated[idx].onRefresh();
82682    }
82683  }
82684  runConfiguration(widgetId) {
82685    console.log("Called runConfiguration(" + widgetId + ")");
82686    const doraConfigurationComponent = this.widgetsConfigurationCreated.find((widget) => widget.getWigetSrcName() === widgetId);
82687    if (doraConfigurationComponent !== void 0) {
82688      doraConfigurationComponent.setEditingFormEnabled(true);
82689      return;
82690    }
82691    const element = document.getElementById(widgetId);
82692    if (element !== null) {
82693      const configuratorFather = document.createElement("dag-dora-configurator");
82694      configuratorFather.setAttribute("widgetSrcName", widgetId);
82695      configuratorFather.setAttribute("progressive", widgetId);
82696      const configurator = document.createElement("dora-configurator");
82697      const newComponentRef = createComponent(DoraConfiguratorComponent, {
82698        environmentInjector: this.injector,
82699        hostElement: configurator
82700      });
82701      const widgetCreated = newComponentRef.instance;
82702      widgetCreated.setAppComponent(this);
82703      this.widgetsConfigurationCreated.push(widgetCreated);
82704      this.applicationRef.attachView(newComponentRef.hostView);
82705      configuratorFather.appendChild(configurator);
82706      element.appendChild(configuratorFather);
82707    }
82708  }
82709  static {
82710    this.\u0275fac = function AppComponent_Factory(__ngFactoryType__) {
82711      return new (__ngFactoryType__ || _AppComponent)(\u0275\u0275directiveInject(EnvironmentInjector), \u0275\u0275directiveInject(ApplicationRef), \u0275\u0275directiveInject(ViewContainerRef), \u0275\u0275directiveInject(PublisherService), \u0275\u0275directiveInject(TranslationService), \u0275\u0275directiveInject(WidgetService), \u0275\u0275directiveInject(NgZone));
82712    };
82713  }
82714  static {
82715    this.\u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _AppComponent, selectors: [["dora-root"]], hostBindings: function AppComponent_HostBindings(rf, ctx) {
82716      if (rf & 1) {
82717        \u0275\u0275listener("resize", function AppComponent_resize_HostBindingHandler($event) {
82718          return ctx.onResize($event);
82719        }, false, \u0275\u0275resolveWindow);
82720      }
82721    }, standalone: false, decls: 0, vars: 0, template: function AppComponent_Template(rf, ctx) {
82722    }, encapsulation: 2 });
82723  }
82724};
82725(() => {
82726  (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(AppComponent, { className: "AppComponent", filePath: "src/app/app.component.ts", lineNumber: 66 });
82727})();
82728
vendor: 1,209 bytes, lines 82729-82772
82729// node_modules/@ngx-translate/http-loader/fesm2022/ngx-translate-http-loader.mjs
82730var TranslateHttpLoader = class _TranslateHttpLoader {
82731  http;
82732  prefix;
82733  suffix;
82734  constructor(http, prefix = "/assets/i18n/", suffix = ".json") {
82735    this.http = http;
82736    this.prefix = prefix;
82737    this.suffix = suffix;
82738  }
82739  /**
82740   * Gets the translations from the server
82741   */
82742  getTranslation(lang) {
82743    return this.http.get(`${this.prefix}${lang}${this.suffix}`);
82744  }
82745  static \u0275fac = function TranslateHttpLoader_Factory(__ngFactoryType__) {
82746    return new (__ngFactoryType__ || _TranslateHttpLoader)(\u0275\u0275inject(HttpClient), \u0275\u0275inject(String), \u0275\u0275inject(String));
82747  };
82748  static \u0275prov = /* @__PURE__ */ \u0275\u0275defineInjectable({
82749    token: _TranslateHttpLoader,
82750    factory: _TranslateHttpLoader.\u0275fac
82751  });
82752};
82753(() => {
82754  (typeof ngDevMode === "undefined" || ngDevMode) && setClassMetadata(TranslateHttpLoader, [{
82755    type: Injectable
82756  }], () => [{
82757    type: HttpClient
82758  }, {
82759    type: void 0,
82760    decorators: [{
82761      type: Inject,
82762      args: [String]
82763    }]
82764  }, {
82765    type: void 0,
82766    decorators: [{
82767      type: Inject,
82768      args: [String]
82769    }]
82770  }], null);
82771})();
82772
vendor: 1,201 bytes, lines 82773-82781
82773// node_modules/@angular/common/locales/en.mjs
82774var u = void 0;
82775function plural(val) {
82776  const n = val, i = Math.floor(Math.abs(val)), v = val.toString().replace(/^[^.]*\.?/, "").length;
82777  if (i === 1 && v === 0) return 1;
82778  return 5;
82779}
82780var en_default = ["en", [["a", "p"], ["AM", "PM"], u], [["AM", "PM"], u, u], [["S", "M", "T", "W", "T", "F", "S"], ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"], ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"]], u, [["J", "F", "M", "A", "M", "J", "J", "A", "S", "O", "N", "D"], ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"]], u, [["B", "A"], ["BC", "AD"], ["Before Christ", "Anno Domini"]], 0, [6, 0], ["M/d/yy", "MMM d, y", "MMMM d, y", "EEEE, MMMM d, y"], ["h:mm a", "h:mm:ss a", "h:mm:ss a z", "h:mm:ss a zzzz"], ["{1}, {0}", u, "{1} 'at' {0}", u], [".", ",", ";", "%", "+", "-", "E", "\xD7", "\u2030", "\u221E", "NaN", ":"], ["#,##0.###", "#,##0%", "\xA4#,##0.00", "#E0"], "USD", "$", "US Dollar", {}, "ltr", plural];
82781
vendor: 444 bytes, lines 82782-82785
82782// node_modules/@angular/common/locales/extra/en.mjs
82783var u2 = void 0;
82784var en_default2 = [[["mi", "n", "in the morning", "in the afternoon", "in the evening", "at night"], ["midnight", "noon", "in the morning", "in the afternoon", "in the evening", "at night"], u2], [["midnight", "noon", "morning", "afternoon", "evening", "night"], u2, u2], ["00:00", "12:00", ["06:00", "12:00"], ["12:00", "18:00"], ["18:00", "21:00"], ["21:00", "06:00"]]];
82785
vendor: 1,674 bytes, lines 82786-82809
82786// node_modules/@angular/common/locales/it.mjs
82787var u3 = void 0;
82788function plural2(val) {
82789  const n = val, i = Math.floor(Math.abs(val)), v = val.toString().replace(/^[^.]*\.?/, "").length, e = parseInt(val.toString().replace(/^[^e]*(e([-+]?\d+))?/, "$2")) || 0;
82790  if (i === 1 && v === 0) return 1;
82791  if (e === 0 && !(i === 0) && i % 1e6 === 0 && v === 0 || !(e >= 0 && e <= 5)) return 4;
82792  return 5;
82793}
82794var it_default = ["it", [["m.", "p."], ["AM", "PM"], u3], u3, [["D", "L", "M", "M", "G", "V", "S"], ["dom", "lun", "mar", "mer", "gio", "ven", "sab"], ["domenica", "luned\xEC", "marted\xEC", "mercoled\xEC", "gioved\xEC", "venerd\xEC", "sabato"], ["dom", "lun", "mar", "mer", "gio", "ven", "sab"]], u3, [["G", "F", "M", "A", "M", "G", "L", "A", "S", "O", "N", "D"], ["gen", "feb", "mar", "apr", "mag", "giu", "lug", "ago", "set", "ott", "nov", "dic"], ["gennaio", "febbraio", "marzo", "aprile", "maggio", "giugno", "luglio", "agosto", "settembre", "ottobre", "novembre", "dicembre"]], u3, [["aC", "dC"], ["a.C.", "d.C."], ["avanti Cristo", "dopo Cristo"]], 1, [6, 0], ["dd/MM/yy", "d MMM y", "d MMMM y", "EEEE d MMMM y"], ["HH:mm", "HH:mm:ss", "HH:mm:ss z", "HH:mm:ss zzzz"], ["{1}, {0}", u3, "{1} {0}", u3], [",", ".", ";", "%", "+", "-", "E", "\xD7", "\u2030", "\u221E", "NaN", ":"], ["#,##0.###", "#,##0%", "#,##0.00\xA0\xA4", "#E0"], "EUR", "\u20AC", "euro", {
82795  "BRL": [u3, "R$"],
82796  "BYN": [u3, "Br"],
82797  "EGP": [u3, "\xA3E"],
82798  "HKD": [u3, "$"],
82799  "INR": [u3, "\u20B9"],
82800  "JPY": [u3, "\xA5"],
82801  "KRW": [u3, "\u20A9"],
82802  "MXN": [u3, "$"],
82803  "NOK": [u3, "NKr"],
82804  "THB": ["\u0E3F"],
82805  "TWD": [u3, "NT$"],
82806  "USD": [u3, "$"],
82807  "VND": [u3, "\u20AB"]
82808}, "ltr", plural2];
82809
vendor: 451 bytes, lines 82810-82813
82810// node_modules/@angular/common/locales/extra/it.mjs
82811var u4 = void 0;
82812var it_default2 = [[["mezzanotte", "mezzogiorno", "di mattina", "di pomeriggio", "di sera", "di notte"], u4, ["mezzanotte", "mezzogiorno", "di mattina", "del pomeriggio", "di sera", "di notte"]], [["mezzanotte", "mezzogiorno", "mattina", "pomeriggio", "sera", "notte"], u4, u4], ["00:00", "12:00", ["06:00", "12:00"], ["12:00", "18:00"], ["18:00", "24:00"], ["00:00", "06:00"]]];
82813
vendor: 555 bytes, lines 82814-82817
82814// node_modules/@angular/common/locales/extra/de.mjs
82815var u5 = void 0;
82816var de_default = [[["Mitternacht", "morgens", "vorm.", "mittags", "nachm.", "abends", "nachts"], u5, ["Mitternacht", "morgens", "vormittags", "mittags", "nachmittags", "abends", "nachts"]], [["Mitternacht", "Morgen", "Vorm.", "Mittag", "Nachm.", "Abend", "Nacht"], u5, ["Mitternacht", "Morgen", "Vormittag", "Mittag", "Nachmittag", "Abend", "Nacht"]], ["00:00", ["05:00", "10:00"], ["10:00", "12:00"], ["12:00", "13:00"], ["13:00", "18:00"], ["18:00", "24:00"], ["00:00", "05:00"]]];
82817
vendor: 2,090 bytes, lines 82818-82847
82818// node_modules/@angular/common/locales/de.mjs
82819var u6 = void 0;
82820function plural3(val) {
82821  const n = val, i = Math.floor(Math.abs(val)), v = val.toString().replace(/^[^.]*\.?/, "").length;
82822  if (i === 1 && v === 0) return 1;
82823  return 5;
82824}
82825var de_default2 = ["de", [["AM", "PM"], u6, u6], u6, [["S", "M", "D", "M", "D", "F", "S"], ["So.", "Mo.", "Di.", "Mi.", "Do.", "Fr.", "Sa."], ["Sonntag", "Montag", "Dienstag", "Mittwoch", "Donnerstag", "Freitag", "Samstag"], ["So.", "Mo.", "Di.", "Mi.", "Do.", "Fr.", "Sa."]], [["S", "M", "D", "M", "D", "F", "S"], ["So", "Mo", "Di", "Mi", "Do", "Fr", "Sa"], ["Sonntag", "Montag", "Dienstag", "Mittwoch", "Donnerstag", "Freitag", "Samstag"], ["So.", "Mo.", "Di.", "Mi.", "Do.", "Fr.", "Sa."]], [["J", "F", "M", "A", "M", "J", "J", "A", "S", "O", "N", "D"], ["Jan.", "Feb.", "M\xE4rz", "Apr.", "Mai", "Juni", "Juli", "Aug.", "Sept.", "Okt.", "Nov.", "Dez."], ["Januar", "Februar", "M\xE4rz", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember"]], [["J", "F", "M", "A", "M", "J", "J", "A", "S", "O", "N", "D"], ["Jan", "Feb", "M\xE4r", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dez"], ["Januar", "Februar", "M\xE4rz", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember"]], [["v. Chr.", "n. Chr."], u6, u6], 1, [6, 0], ["dd.MM.yy", "dd.MM.y", "d. MMMM y", "EEEE, d. MMMM y"], ["HH:mm", "HH:mm:ss", "HH:mm:ss z", "HH:mm:ss zzzz"], ["{1}, {0}", u6, "{1} 'um' {0}", u6], [",", ".", ";", "%", "+", "-", "E", "\xB7", "\u2030", "\u221E", "NaN", ":"], ["#,##0.###", "#,##0\xA0%", "#,##0.00\xA0\xA4", "#E0"], "EUR", "\u20AC", "Euro", {
82826  "ATS": ["\xF6S"],
82827  "AUD": ["AU$", "$"],
82828  "BGM": ["BGK"],
82829  "BGO": ["BGJ"],
82830  "BYN": [u6, "\u0440."],
82831  "CUC": [u6, "Cub$"],
82832  "DEM": ["DM"],
82833  "FKP": [u6, "Fl\xA3"],
82834  "GHS": [u6, "\u20B5"],
82835  "GNF": [u6, "F.G."],
82836  "KMF": [u6, "FC"],
82837  "PHP": [u6, "\u20B1"],
82838  "RON": [u6, "L"],
82839  "RUR": [u6, "\u0440."],
82840  "RWF": [u6, "F.Rw"],
82841  "SYP": [],
82842  "THB": ["\u0E3F"],
82843  "TWD": ["NT$"],
82844  "XXX": [],
82845  "ZMW": [u6, "K"]
82846}, "ltr", plural3];
82847
vendor: 452 bytes, lines 82848-82851
82848// node_modules/@angular/common/locales/extra/fr.mjs
82849var u7 = void 0;
82850var fr_default = [[["minuit", "midi", "mat.", "ap.m.", "soir", "nuit"], u7, ["minuit", "midi", "du matin", "de l\u2019apr\xE8s-midi", "du soir", "du matin"]], [["minuit", "midi", "mat.", "ap.m.", "soir", "nuit"], u7, ["minuit", "midi", "matin", "apr\xE8s-midi", "soir", "nuit"]], ["00:00", "12:00", ["04:00", "12:00"], ["12:00", "18:00"], ["18:00", "24:00"], ["00:00", "04:00"]]];
82851
vendor: 2,457 bytes, lines 82852-82908
82852// node_modules/@angular/common/locales/fr.mjs
82853var u8 = void 0;
82854function plural4(val) {
82855  const n = val, i = Math.floor(Math.abs(val)), v = val.toString().replace(/^[^.]*\.?/, "").length, e = parseInt(val.toString().replace(/^[^e]*(e([-+]?\d+))?/, "$2")) || 0;
82856  if (i === 0 || i === 1) return 1;
82857  if (e === 0 && !(i === 0) && i % 1e6 === 0 && v === 0 || !(e >= 0 && e <= 5)) return 4;
82858  return 5;
82859}
82860var fr_default2 = ["fr", [["AM", "PM"], u8, u8], u8, [["D", "L", "M", "M", "J", "V", "S"], ["dim.", "lun.", "mar.", "mer.", "jeu.", "ven.", "sam."], ["dimanche", "lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi"], ["di", "lu", "ma", "me", "je", "ve", "sa"]], u8, [["J", "F", "M", "A", "M", "J", "J", "A", "S", "O", "N", "D"], ["janv.", "f\xE9vr.", "mars", "avr.", "mai", "juin", "juil.", "ao\xFBt", "sept.", "oct.", "nov.", "d\xE9c."], ["janvier", "f\xE9vrier", "mars", "avril", "mai", "juin", "juillet", "ao\xFBt", "septembre", "octobre", "novembre", "d\xE9cembre"]], u8, [["av. J.-C.", "ap. J.-C."], u8, ["avant J\xE9sus-Christ", "apr\xE8s J\xE9sus-Christ"]], 1, [6, 0], ["dd/MM/y", "d MMM y", "d MMMM y", "EEEE d MMMM y"], ["HH:mm", "HH:mm:ss", "HH:mm:ss z", "HH:mm:ss zzzz"], ["{1} {0}", "{1}, {0}", "{1} '\xE0' {0}", u8], [",", "\u202F", ";", "%", "+", "-", "E", "\xD7", "\u2030", "\u221E", "NaN", ":"], ["#,##0.###", "#,##0\xA0%", "#,##0.00\xA0\xA4", "#E0"], "EUR", "\u20AC", "euro", {
82861  "ARS": ["$AR", "$"],
82862  "AUD": ["$AU", "$"],
82863  "BEF": ["FB"],
82864  "BMD": ["$BM", "$"],
82865  "BND": ["$BN", "$"],
82866  "BYN": [u8, "\u0440."],
82867  "BZD": ["$BZ", "$"],
82868  "CAD": ["$CA", "$"],
82869  "CLP": ["$CL", "$"],
82870  "CNY": [u8, "\xA5"],
82871  "COP": ["$CO", "$"],
82872  "CYP": ["\xA3CY"],
82873  "EGP": [u8, "\xA3E"],
82874  "FJD": ["$FJ", "$"],
82875  "FKP": ["\xA3FK", "\xA3"],
82876  "FRF": ["F"],
82877  "GBP": ["\xA3GB", "\xA3"],
82878  "GIP": ["\xA3GI", "\xA3"],
82879  "HKD": [u8, "$"],
82880  "IEP": ["\xA3IE"],
82881  "ILP": ["\xA3IL"],
82882  "ITL": ["\u20A4IT"],
82883  "JPY": [u8, "\xA5"],
82884  "KMF": [u8, "FC"],
82885  "LBP": ["\xA3LB", "\xA3L"],
82886  "MTP": ["\xA3MT"],
82887  "MXN": ["$MX", "$"],
82888  "NAD": ["$NA", "$"],
82889  "NIO": [u8, "$C"],
82890  "NZD": ["$NZ", "$"],
82891  "PHP": [u8, "\u20B1"],
82892  "RHD": ["$RH"],
82893  "RON": [u8, "L"],
82894  "RWF": [u8, "FR"],
82895  "SBD": ["$SB", "$"],
82896  "SGD": ["$SG", "$"],
82897  "SRD": ["$SR", "$"],
82898  "TOP": [u8, "$T"],
82899  "TTD": ["$TT", "$"],
82900  "TWD": [u8, "NT$"],
82901  "USD": ["$US", "$"],
82902  "UYU": ["$UY", "$"],
82903  "WST": ["$WS"],
82904  "XCD": [u8, "$"],
82905  "XPF": ["FCFP"],
82906  "ZMW": [u8, "Kw"]
82907}, "ltr", plural4];
82908
vendor: 2,624 bytes, lines 82909-82937
82909// node_modules/@angular/common/locales/pl.mjs
82910var u9 = void 0;
82911function plural5(val) {
82912  const n = val, i = Math.floor(Math.abs(val)), v = val.toString().replace(/^[^.]*\.?/, "").length;
82913  if (i === 1 && v === 0) return 1;
82914  if (v === 0 && i % 10 === Math.floor(i % 10) && i % 10 >= 2 && i % 10 <= 4 && !(i % 100 >= 12 && i % 100 <= 14)) return 3;
82915  if (v === 0 && !(i === 1) && i % 10 === Math.floor(i % 10) && i % 10 >= 0 && i % 10 <= 1 || v === 0 && i % 10 === Math.floor(i % 10) && i % 10 >= 5 && i % 10 <= 9 || v === 0 && i % 100 === Math.floor(i % 100) && i % 100 >= 12 && i % 100 <= 14) return 4;
82916  return 5;
82917}
82918var pl_default = ["pl", [["a", "p"], ["AM", "PM"], u9], u9, [["n", "p", "w", "\u015B", "c", "p", "s"], ["niedz.", "pon.", "wt.", "\u015Br.", "czw.", "pt.", "sob."], ["niedziela", "poniedzia\u0142ek", "wtorek", "\u015Broda", "czwartek", "pi\u0105tek", "sobota"], ["nie", "pon", "wto", "\u015Bro", "czw", "pi\u0105", "sob"]], [["N", "P", "W", "\u015A", "C", "P", "S"], ["niedz.", "pon.", "wt.", "\u015Br.", "czw.", "pt.", "sob."], ["niedziela", "poniedzia\u0142ek", "wtorek", "\u015Broda", "czwartek", "pi\u0105tek", "sobota"], ["nie", "pon", "wto", "\u015Bro", "czw", "pi\u0105", "sob"]], [["s", "l", "m", "k", "m", "c", "l", "s", "w", "p", "l", "g"], ["sty", "lut", "mar", "kwi", "maj", "cze", "lip", "sie", "wrz", "pa\u017A", "lis", "gru"], ["stycznia", "lutego", "marca", "kwietnia", "maja", "czerwca", "lipca", "sierpnia", "wrze\u015Bnia", "pa\u017Adziernika", "listopada", "grudnia"]], [["S", "L", "M", "K", "M", "C", "L", "S", "W", "P", "L", "G"], ["sty", "lut", "mar", "kwi", "maj", "cze", "lip", "sie", "wrz", "pa\u017A", "lis", "gru"], ["stycze\u0144", "luty", "marzec", "kwiecie\u0144", "maj", "czerwiec", "lipiec", "sierpie\u0144", "wrzesie\u0144", "pa\u017Adziernik", "listopad", "grudzie\u0144"]], [["p.n.e.", "n.e."], u9, ["przed nasz\u0105 er\u0105", "naszej ery"]], 1, [6, 0], ["d.MM.y", "d MMM y", "d MMMM y", "EEEE, d MMMM y"], ["HH:mm", "HH:mm:ss", "HH:mm:ss z", "HH:mm:ss zzzz"], ["{1}, {0}", u9, "{1} {0}", u9], [",", "\xA0", ";", "%", "+", "-", "E", "\xD7", "\u2030", "\u221E", "NaN", ":"], ["#,##0.###", "#,##0%", "#,##0.00\xA0\xA4", "#E0"], "PLN", "z\u0142", "z\u0142oty polski", {
82919  "AUD": [u9, "$"],
82920  "CAD": [u9, "$"],
82921  "CNY": [u9, "\xA5"],
82922  "GBP": [u9, "\xA3"],
82923  "HKD": [u9, "$"],
82924  "ILS": [u9, "\u20AA"],
82925  "INR": [u9, "\u20B9"],
82926  "JPY": [u9, "\xA5"],
82927  "KRW": [u9, "\u20A9"],
82928  "MXN": [u9, "$"],
82929  "NZD": [u9, "$"],
82930  "PHP": [u9, "\u20B1"],
82931  "PLN": ["z\u0142"],
82932  "RON": [u9, "lej"],
82933  "TWD": [u9, "NT$"],
82934  "USD": [u9, "$"],
82935  "VND": [u9, "\u20AB"]
82936}, "ltr", plural5];
82937
vendor: 639 bytes, lines 82938-82941
82938// node_modules/@angular/common/locales/extra/pl.mjs
82939var u10 = void 0;
82940var pl_default2 = [[["o p\xF3\u0142n.", "w po\u0142.", "rano", "przed po\u0142.", "po po\u0142.", "wiecz.", "w nocy"], ["o p\xF3\u0142nocy", "w po\u0142udnie", "rano", "przed po\u0142udniem", "po po\u0142udniu", "wieczorem", "w nocy"], u10], [["p\xF3\u0142n.", "po\u0142.", "rano", "przedpo\u0142.", "popo\u0142.", "wiecz.", "noc"], ["p\xF3\u0142noc", "po\u0142udnie", "rano", "przedpo\u0142udnie", "popo\u0142udnie", "wiecz\xF3r", "noc"], u10], ["00:00", "12:00", ["06:00", "10:00"], ["10:00", "12:00"], ["12:00", "18:00"], ["18:00", "21:00"], ["21:00", "06:00"]]];
82941
82942// src/app/app.module.ts
82943function getReCaptchaV3SiteKey() {
82944  const cfg = window.__DORAG_CONFIG__;
82945  const param = cfg?.singleParameters?.find((p) => p.name === "ReCaptchaV3SiteKey");
82946  if (!param?.value) {
82947    console.warn("ReCaptchaV3SiteKey not found in AppConfiguration.json");
82948    return "NO-ReCaptcha-KEY";
82949  }
82950  return param.value;
82951}
82952registerLocaleData(en_default, "en", en_default2);
82953registerLocaleData(it_default, "it", it_default2);
82954registerLocaleData(de_default2, "de", de_default);
82955registerLocaleData(fr_default2, "fr", fr_default);
82956registerLocaleData(pl_default, "pl", pl_default2);
82957function HttpLoaderFactory(http) {
82958  return new TranslateHttpLoader(http, extGetAppConfigurationPath() + "/i18n/", ".json");
82959}
82960var AppModule = class _AppModule {
82961  static {
82962    this.\u0275fac = function AppModule_Factory(__ngFactoryType__) {
82963      return new (__ngFactoryType__ || _AppModule)();
82964    };
82965  }
82966  static {
82967    this.\u0275mod = /* @__PURE__ */ \u0275\u0275defineNgModule({ type: _AppModule, bootstrap: [AppComponent] });
82968  }
82969  static {
82970    this.\u0275inj = /* @__PURE__ */ \u0275\u0275defineInjector({ providers: [
82971      provideHttpClient(),
82972      MessageService,
82973      ConfigurationService,
82974      PublisherService,
82975      TranslationService,
82976      provideScReCaptchaSettings({
82977        v3SiteKey: getReCaptchaV3SiteKey()
82978      })
82979    ], imports: [
82980      CommonModule,
82981      BrowserModule,
82982      HttpClientJsonpModule,
82983      HighchartsChartModule,
82984      ReactiveFormsModule,
82985      NgSelectModule,
82986      TranslateModule.forRoot({
82987        loader: {
82988          provide: TranslateLoader,
82989          useFactory: HttpLoaderFactory,
82990          deps: [HttpClient]
82991        }
82992      }),
82993      FormsModule
82994    ] });
82995  }
82996};
82997export {
82998  AppModule,
82999  HttpLoaderFactory
83000};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.